App Widget Contents
Schema
Schema defined the app widget settings displayed to merchant in SHOP builder. It also defines the settings format rendered in merchant's storefront.
Schema content
Schema is a JSON object with specific fields defining the behavior and appearance of app widget.
(See the full list of fields definitions here)
Supported Setting Types
Current supported setting types for app widget:
Setting Type |
---|
color_picker |
image_picker |
collection_picker |
product_picker |
products_picker |
video_url |
time_range |
checkbox |
range |
select |
text |
richtext |
tabs |
vertical_align |
text_align |
proportion |
radio |
header |
url |
paragraph |
switch |
group_header |
group_end |
heading |
Changing Setting Types
Changing setting types for specific ID in an app widget is NOT allowed.
The following rules apply:
- For every setting in the same app widget, once a setting ID is used, the corresponding setting type could not be changed.
- For blocks settings, the comparison will be done within every block that has the same block type. Every block is compared separately.
- It doesn’t matter if the setting / block is removed in previous version, as long as it has been added before, and the current version uses a different type with the same id, it will not be allowed.
For example:- Version 1.1 has the setting:
- ID:
original-id
, Type:text
- ID:
- Version 1.2 has removed the setting
- Version 1.3 wants to add back the setting with different type
- ID:
original-id
, Type:color_picker
Error will be thrown when attempting to save version 1.3.
- ID:
- Version 1.1 has the setting:
A setting ID & type pair is considered used once the version has been deployed.
HTML, CSS / SCSS, JS
These assets, if defined, will be rendered to merchant's storefront.
HTML
CSS / SCSS
JS
Updated about 1 month ago