Have your say in Community Polls: What was/is your greatest motivation to start your own business?

How can I add header of settings in preview customize theme

How can I add header of settings in preview customize theme

Le_Linh
Shopify Partner
5 0 0

Screenshot 2024-08-13 134418.png

How can I add header of settings in preview customize theme.I found some app that can do that and I need that.Pleade help me.Thanks you

Reply 1 (1)

Small_Task_Help
Shopify Partner
830 28 75

Hi,

 

You need to Add Custom HTML/CSS header.liquid

Code example

<div class="settings-header">
    <h1>Customize Your Theme</h1>
    <p>Select from the options below to customize your store's appearance.</p>
</div>

<style>
.settings-header {
    background-color: #f5f5f5; /* Adjust the background color */
    padding: 20px; /* Adjust the padding */
    text-align: center; /* Center align the text */
    border-bottom: 1px solid #ddd; /* Add a border */
}

.settings-header h1 {
    margin: 0;
    font-size: 24px; /* Adjust the font size */
    color: #333; /* Adjust the font color */
}

.settings-header p {
    margin: 5px 0 0;
    font-size: 14px; /* Adjust the font size */
    color: #666; /* Adjust the font color */
}
</style>


At config/settings_schema.json edit schema

Code example

{
  "name": "Header",
  "settings": [
    {
      "type": "text",
      "id": "settings_header_title",
      "label": "Settings Header Title",
      "default": "Customize Your Theme"
    },
    {
      "type": "textarea",
      "id": "settings_header_description",
      "label": "Settings Header Description",
      "default": "Select from the options below to customize your store's appearance."
    }
  ]
}

Then modify the header code to use the new setting

To Get Shopify Experts Help, E-mail - hi@ecommercesmalltask.com
About Us - We are Shopify Expert Agency
At Google My Business - Ecommerce Small Task - Hire Shopify Developers Ahmedabad