Skip to content

Commit

Permalink
Bump schema version from 2 to 3 (#2645)
Browse files Browse the repository at this point in the history
* Bump schema version from 2 to 3

Version 3 is now supported in WordPress 6.6.

Reference: https://developer.wordpress.org/block-editor/reference-guides/theme-json-reference/theme-json-living/

* 🧹 chore(minor): Run `build-types`

* 🧹 chore(minor): Bump theme.json schema version

* 🧪 test(minor): Update tests with schema version
  • Loading branch information
joshuafredrickson authored Dec 9, 2024
1 parent 2aa5b63 commit 9fcd1f4
Show file tree
Hide file tree
Showing 7 changed files with 457 additions and 212 deletions.
2 changes: 1 addition & 1 deletion examples/sage-with-stylelint/theme.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"__generated__": "⚠️ This file is generated. Do not edit.",
"$schema": "https://schemas.wp.org/trunk/theme.json",
"version": 2,
"version": 3,
"settings": {
"color": {
"custom": false,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ export class TailwindThemeJSON extends Extension {
palette,
},
},
version: 2,
version: 3,
}
}

Expand All @@ -143,7 +143,7 @@ export class TailwindThemeJSON extends Extension {
fontFamilies,
},
},
version: 2,
version: 3,
}
}

Expand All @@ -167,7 +167,7 @@ export class TailwindThemeJSON extends Extension {
fontSizes,
},
},
version: 2,
version: 3,
}
}

Expand All @@ -191,7 +191,7 @@ export class TailwindThemeJSON extends Extension {
spacingSizes,
},
},
version: 2,
version: 3,
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ export interface Options extends SettingsAndStyles {
*/
__generated__?: false | string
path: string
version: 2
version: 3
}

export {ThemeJsonWebpackPlugin as default} from './plugin.js'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ export class ThemeJsonWebpackPlugin implements WebpackPluginInstance {
public data: Record<string, any> = {
__generated__: `⚠️ This file is generated. Do not edit.`,
$schema: `https://schemas.wp.org/trunk/theme.json`,
version: 2,
version: 3,
}

/**
Expand Down
Loading

0 comments on commit 9fcd1f4

Please sign in to comment.