Skip to content

Update color palette definition#1644

Merged
NathanPJF merged 4 commits into
mainfrom
update-color-palette-definition
May 12, 2026
Merged

Update color palette definition#1644
NathanPJF merged 4 commits into
mainfrom
update-color-palette-definition

Conversation

@NathanPJF
Copy link
Copy Markdown
Contributor

@NathanPJF NathanPJF commented May 12, 2026

Follow-up to #1565

Update definition for changes to color_palette input. No longer inherit standard input definition; create a new bespoke definition.

Color palette input only supports:

  • id
  • type
  • default

All of which is required, including a default field with initial color palettes.

Updates test cases for color_palette specific considerations. e.g. a color palette name cannot have a - character in it or start with a number.

@NathanPJF NathanPJF requested a review from a team as a code owner May 12, 2026 00:47
@NathanPJF NathanPJF force-pushed the update-color-palette-definition branch 3 times, most recently from fa0f319 to f61732c Compare May 12, 2026 01:03
@NathanPJF NathanPJF force-pushed the update-color-palette-definition branch from f61732c to 597edbb Compare May 12, 2026 01:12
Copy link
Copy Markdown
Contributor

@aswamy aswamy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1 suggestion to make the error more human friendly when seen through an editor

Comment on lines +1119 to +1123
"id": {
"type": "string",
"description": "The unique identifier for the setting, which is used to access the setting value.",
"markdownDescription": "The unique identifier for the setting, which is used to access the setting value.\n\n---\n\n[Shopify reference](https://shopify.dev/docs/themes/architecture/settings/input-settings#standard-attributes)"
}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I noticed this is repeated a lot in the schema; not a problem in this PR since it looks like we did it before as well, but should clean it up in a follow-up PR.

Comment thread schemas/theme/setting.json Outdated
"type": "object",
"minProperties": 1,
"maxProperties": 20,
"propertyNames": { "pattern": "^[a-zA-Z]\\w*$" },
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
"propertyNames": { "pattern": "^[a-zA-Z]\\w*$" },
"propertyNames": {
"pattern": "^[a-zA-Z]\\w*$",
"patternErrorMessage": "Color palette names must start with a letter and contain only letters, digits, and underscores."
},

@NathanPJF NathanPJF merged commit e5bb64d into main May 12, 2026
6 of 7 checks passed
@NathanPJF NathanPJF deleted the update-color-palette-definition branch May 12, 2026 14:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants