@wordpress/widgets 4.50.1-next.v.202607070741.0 → 4.51.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +7 -0
- package/build/blocks/widget-group/index.cjs +1 -1
- package/build/blocks/widget-group/index.cjs.map +2 -2
- package/build-module/blocks/widget-group/index.mjs +2 -5
- package/build-module/blocks/widget-group/index.mjs.map +2 -2
- package/build-style/style-rtl.css +9 -9
- package/build-style/style.css +9 -9
- package/package.json +16 -16
- package/src/blocks/legacy-widget/editor.scss +4 -5
- package/src/blocks/widget-group/editor.scss +2 -2
- package/src/blocks/widget-group/index.js +2 -5
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,13 @@
|
|
|
2
2
|
|
|
3
3
|
## Unreleased
|
|
4
4
|
|
|
5
|
+
## 4.51.0 (2026-07-14)
|
|
6
|
+
|
|
7
|
+
### Enhancements
|
|
8
|
+
|
|
9
|
+
- Use the emphasis font-weight token for UI emphasis ([#80093](https://github.com/WordPress/gutenberg/pull/80093)).
|
|
10
|
+
- Widen React peer dependency ranges to `^18 || ^19` to support both React 18 and React 19 environments ([#80024](https://github.com/WordPress/gutenberg/pull/80024)).
|
|
11
|
+
|
|
5
12
|
## 4.50.0 (2026-07-01)
|
|
6
13
|
|
|
7
14
|
## 4.49.0 (2026-06-24)
|
|
@@ -64,7 +64,7 @@ var settings = {
|
|
|
64
64
|
},
|
|
65
65
|
__experimentalConvert(blocks) {
|
|
66
66
|
let innerBlocks = blocks.map(
|
|
67
|
-
(block) => (0, import_blocks.
|
|
67
|
+
(block) => (0, import_blocks.cloneSanitizedBlock)(block)
|
|
68
68
|
);
|
|
69
69
|
const firstHeadingBlock = innerBlocks[0].name === "core/heading" ? innerBlocks[0] : null;
|
|
70
70
|
innerBlocks = innerBlocks.filter(
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/blocks/widget-group/index.js"],
|
|
4
|
-
"sourcesContent": ["/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport {
|
|
5
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA,+BAAAA;AAAA,EAAA;AAAA;AAAA;AAAA;AAGA,kBAAmB;AACnB,
|
|
4
|
+
"sourcesContent": ["/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport { createBlock, cloneSanitizedBlock } from '@wordpress/blocks';\nimport { group as icon } from '@wordpress/icons';\n\n/**\n * Internal dependencies\n */\nimport metadata from './block.json';\nimport edit from './edit';\nimport save from './save';\nimport deprecated from './deprecated';\n\nconst { name } = metadata;\nexport { metadata, name };\n\nexport const settings = {\n\ttitle: __( 'Widget Group' ),\n\tdescription: __(\n\t\t'Create a classic widget layout with a title that’s styled by your theme for your widget areas.'\n\t),\n\ticon,\n\t__experimentalLabel: ( { name: label } ) => label,\n\tedit,\n\tsave,\n\ttransforms: {\n\t\tfrom: [\n\t\t\t{\n\t\t\t\ttype: 'block',\n\t\t\t\tisMultiBlock: true,\n\t\t\t\tblocks: [ '*' ],\n\t\t\t\tisMatch( attributes, blocks ) {\n\t\t\t\t\t// Avoid transforming existing `widget-group` blocks.\n\t\t\t\t\treturn ! blocks.some(\n\t\t\t\t\t\t( block ) => block.name === 'core/widget-group'\n\t\t\t\t\t);\n\t\t\t\t},\n\t\t\t\t__experimentalConvert( blocks ) {\n\t\t\t\t\t// Put the selected blocks inside the new Widget Group's innerBlocks.\n\t\t\t\t\tlet innerBlocks = blocks.map( ( block ) =>\n\t\t\t\t\t\tcloneSanitizedBlock( block )\n\t\t\t\t\t);\n\n\t\t\t\t\t// If the first block is a heading then assume this is intended\n\t\t\t\t\t// to be the Widget's \"title\".\n\t\t\t\t\tconst firstHeadingBlock =\n\t\t\t\t\t\tinnerBlocks[ 0 ].name === 'core/heading'\n\t\t\t\t\t\t\t? innerBlocks[ 0 ]\n\t\t\t\t\t\t\t: null;\n\n\t\t\t\t\t// Remove the first heading block as we're copying\n\t\t\t\t\t// it's content into the Widget Group's title attribute.\n\t\t\t\t\tinnerBlocks = innerBlocks.filter(\n\t\t\t\t\t\t( block ) => block !== firstHeadingBlock\n\t\t\t\t\t);\n\n\t\t\t\t\treturn createBlock(\n\t\t\t\t\t\t'core/widget-group',\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t...( firstHeadingBlock && {\n\t\t\t\t\t\t\t\ttitle: firstHeadingBlock.attributes.content,\n\t\t\t\t\t\t\t} ),\n\t\t\t\t\t\t},\n\t\t\t\t\t\tinnerBlocks\n\t\t\t\t\t);\n\t\t\t\t},\n\t\t\t},\n\t\t],\n\t},\n\tdeprecated,\n};\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA,+BAAAA;AAAA,EAAA;AAAA;AAAA;AAAA;AAGA,kBAAmB;AACnB,oBAAiD;AACjD,mBAA8B;AAK9B,mBAAqB;AACrB,kBAAiB;AACjB,kBAAiB;AACjB,wBAAuB;AAEvB,IAAM,EAAE,KAAK,IAAI,aAAAA;AAGV,IAAM,WAAW;AAAA,EACvB,WAAO,gBAAI,cAAe;AAAA,EAC1B,iBAAa;AAAA,IACZ;AAAA,EACD;AAAA,EACA,mBAAAC;AAAA,EACA,qBAAqB,CAAE,EAAE,MAAM,MAAM,MAAO;AAAA,EAC5C,kBAAAC;AAAA,EACA,kBAAAC;AAAA,EACA,YAAY;AAAA,IACX,MAAM;AAAA,MACL;AAAA,QACC,MAAM;AAAA,QACN,cAAc;AAAA,QACd,QAAQ,CAAE,GAAI;AAAA,QACd,QAAS,YAAY,QAAS;AAE7B,iBAAO,CAAE,OAAO;AAAA,YACf,CAAE,UAAW,MAAM,SAAS;AAAA,UAC7B;AAAA,QACD;AAAA,QACA,sBAAuB,QAAS;AAE/B,cAAI,cAAc,OAAO;AAAA,YAAK,CAAE,cAC/B,mCAAqB,KAAM;AAAA,UAC5B;AAIA,gBAAM,oBACL,YAAa,CAAE,EAAE,SAAS,iBACvB,YAAa,CAAE,IACf;AAIJ,wBAAc,YAAY;AAAA,YACzB,CAAE,UAAW,UAAU;AAAA,UACxB;AAEA,qBAAO;AAAA,YACN;AAAA,YACA;AAAA,cACC,GAAK,qBAAqB;AAAA,gBACzB,OAAO,kBAAkB,WAAW;AAAA,cACrC;AAAA,YACD;AAAA,YACA;AAAA,UACD;AAAA,QACD;AAAA,MACD;AAAA,IACD;AAAA,EACD;AAAA,EACA,8BAAAC;AACD;",
|
|
6
6
|
"names": ["metadata", "icon", "edit", "save", "deprecated"]
|
|
7
7
|
}
|
|
@@ -1,9 +1,6 @@
|
|
|
1
1
|
// packages/widgets/src/blocks/widget-group/index.js
|
|
2
2
|
import { __ } from "@wordpress/i18n";
|
|
3
|
-
import {
|
|
4
|
-
createBlock,
|
|
5
|
-
__experimentalCloneSanitizedBlock
|
|
6
|
-
} from "@wordpress/blocks";
|
|
3
|
+
import { createBlock, cloneSanitizedBlock } from "@wordpress/blocks";
|
|
7
4
|
import { group as icon } from "@wordpress/icons";
|
|
8
5
|
import metadata from "./block.json";
|
|
9
6
|
import edit from "./edit.mjs";
|
|
@@ -32,7 +29,7 @@ var settings = {
|
|
|
32
29
|
},
|
|
33
30
|
__experimentalConvert(blocks) {
|
|
34
31
|
let innerBlocks = blocks.map(
|
|
35
|
-
(block) =>
|
|
32
|
+
(block) => cloneSanitizedBlock(block)
|
|
36
33
|
);
|
|
37
34
|
const firstHeadingBlock = innerBlocks[0].name === "core/heading" ? innerBlocks[0] : null;
|
|
38
35
|
innerBlocks = innerBlocks.filter(
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../../src/blocks/widget-group/index.js"],
|
|
4
|
-
"sourcesContent": ["/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport {
|
|
5
|
-
"mappings": ";AAGA,SAAS,UAAU;AACnB
|
|
4
|
+
"sourcesContent": ["/**\n * WordPress dependencies\n */\nimport { __ } from '@wordpress/i18n';\nimport { createBlock, cloneSanitizedBlock } from '@wordpress/blocks';\nimport { group as icon } from '@wordpress/icons';\n\n/**\n * Internal dependencies\n */\nimport metadata from './block.json';\nimport edit from './edit';\nimport save from './save';\nimport deprecated from './deprecated';\n\nconst { name } = metadata;\nexport { metadata, name };\n\nexport const settings = {\n\ttitle: __( 'Widget Group' ),\n\tdescription: __(\n\t\t'Create a classic widget layout with a title that’s styled by your theme for your widget areas.'\n\t),\n\ticon,\n\t__experimentalLabel: ( { name: label } ) => label,\n\tedit,\n\tsave,\n\ttransforms: {\n\t\tfrom: [\n\t\t\t{\n\t\t\t\ttype: 'block',\n\t\t\t\tisMultiBlock: true,\n\t\t\t\tblocks: [ '*' ],\n\t\t\t\tisMatch( attributes, blocks ) {\n\t\t\t\t\t// Avoid transforming existing `widget-group` blocks.\n\t\t\t\t\treturn ! blocks.some(\n\t\t\t\t\t\t( block ) => block.name === 'core/widget-group'\n\t\t\t\t\t);\n\t\t\t\t},\n\t\t\t\t__experimentalConvert( blocks ) {\n\t\t\t\t\t// Put the selected blocks inside the new Widget Group's innerBlocks.\n\t\t\t\t\tlet innerBlocks = blocks.map( ( block ) =>\n\t\t\t\t\t\tcloneSanitizedBlock( block )\n\t\t\t\t\t);\n\n\t\t\t\t\t// If the first block is a heading then assume this is intended\n\t\t\t\t\t// to be the Widget's \"title\".\n\t\t\t\t\tconst firstHeadingBlock =\n\t\t\t\t\t\tinnerBlocks[ 0 ].name === 'core/heading'\n\t\t\t\t\t\t\t? innerBlocks[ 0 ]\n\t\t\t\t\t\t\t: null;\n\n\t\t\t\t\t// Remove the first heading block as we're copying\n\t\t\t\t\t// it's content into the Widget Group's title attribute.\n\t\t\t\t\tinnerBlocks = innerBlocks.filter(\n\t\t\t\t\t\t( block ) => block !== firstHeadingBlock\n\t\t\t\t\t);\n\n\t\t\t\t\treturn createBlock(\n\t\t\t\t\t\t'core/widget-group',\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t...( firstHeadingBlock && {\n\t\t\t\t\t\t\t\ttitle: firstHeadingBlock.attributes.content,\n\t\t\t\t\t\t\t} ),\n\t\t\t\t\t\t},\n\t\t\t\t\t\tinnerBlocks\n\t\t\t\t\t);\n\t\t\t\t},\n\t\t\t},\n\t\t],\n\t},\n\tdeprecated,\n};\n"],
|
|
5
|
+
"mappings": ";AAGA,SAAS,UAAU;AACnB,SAAS,aAAa,2BAA2B;AACjD,SAAS,SAAS,YAAY;AAK9B,OAAO,cAAc;AACrB,OAAO,UAAU;AACjB,OAAO,UAAU;AACjB,OAAO,gBAAgB;AAEvB,IAAM,EAAE,KAAK,IAAI;AAGV,IAAM,WAAW;AAAA,EACvB,OAAO,GAAI,cAAe;AAAA,EAC1B,aAAa;AAAA,IACZ;AAAA,EACD;AAAA,EACA;AAAA,EACA,qBAAqB,CAAE,EAAE,MAAM,MAAM,MAAO;AAAA,EAC5C;AAAA,EACA;AAAA,EACA,YAAY;AAAA,IACX,MAAM;AAAA,MACL;AAAA,QACC,MAAM;AAAA,QACN,cAAc;AAAA,QACd,QAAQ,CAAE,GAAI;AAAA,QACd,QAAS,YAAY,QAAS;AAE7B,iBAAO,CAAE,OAAO;AAAA,YACf,CAAE,UAAW,MAAM,SAAS;AAAA,UAC7B;AAAA,QACD;AAAA,QACA,sBAAuB,QAAS;AAE/B,cAAI,cAAc,OAAO;AAAA,YAAK,CAAE,UAC/B,oBAAqB,KAAM;AAAA,UAC5B;AAIA,gBAAM,oBACL,YAAa,CAAE,EAAE,SAAS,iBACvB,YAAa,CAAE,IACf;AAIJ,wBAAc,YAAY;AAAA,YACzB,CAAE,UAAW,UAAU;AAAA,UACxB;AAEA,iBAAO;AAAA,YACN;AAAA,YACA;AAAA,cACC,GAAK,qBAAqB;AAAA,gBACzB,OAAO,kBAAkB,WAAW;AAAA,cACrC;AAAA,YACD;AAAA,YACA;AAAA,UACD;AAAA,QACD;AAAA,MACD;AAAA,IACD;AAAA,EACD;AAAA,EACA;AACD;",
|
|
6
6
|
"names": []
|
|
7
7
|
}
|
|
@@ -125,16 +125,16 @@
|
|
|
125
125
|
}
|
|
126
126
|
.wp-block-legacy-widget__edit-form .wp-block-legacy-widget__edit-form-title {
|
|
127
127
|
color: #000;
|
|
128
|
-
font-family: -apple-system,
|
|
128
|
+
font-family: -apple-system, system-ui, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
|
|
129
129
|
font-size: 14px;
|
|
130
|
-
font-weight: 600;
|
|
130
|
+
font-weight: var(--wpds-typography-font-weight-emphasis, 600);
|
|
131
131
|
margin: 0 0 12px 0;
|
|
132
132
|
}
|
|
133
133
|
.wp-block-legacy-widget__edit-form .widget-inside.widget-inside {
|
|
134
134
|
border: none;
|
|
135
135
|
box-shadow: none;
|
|
136
136
|
display: block;
|
|
137
|
-
font-family: -apple-system,
|
|
137
|
+
font-family: -apple-system, system-ui, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
|
|
138
138
|
}
|
|
139
139
|
.wp-block-legacy-widget__edit-form .widget-inside.widget-inside p {
|
|
140
140
|
margin: 8px 0;
|
|
@@ -224,7 +224,7 @@
|
|
|
224
224
|
}
|
|
225
225
|
|
|
226
226
|
.wp-block-legacy-widget__edit-no-preview.wp-block-legacy-widget__edit-no-preview.wp-block-legacy-widget__edit-no-preview, .wp-block-legacy-widget__edit-no-preview.wp-block-legacy-widget__edit-no-preview.wp-block-legacy-widget__edit-no-preview h3, .wp-block-legacy-widget__edit-no-preview.wp-block-legacy-widget__edit-no-preview.wp-block-legacy-widget__edit-no-preview p {
|
|
227
|
-
font-family: -apple-system,
|
|
227
|
+
font-family: -apple-system, system-ui, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
|
|
228
228
|
font-size: 13px;
|
|
229
229
|
}
|
|
230
230
|
.wp-block-legacy-widget__edit-no-preview.wp-block-legacy-widget__edit-no-preview.wp-block-legacy-widget__edit-no-preview {
|
|
@@ -233,7 +233,7 @@
|
|
|
233
233
|
}
|
|
234
234
|
.wp-block-legacy-widget__edit-no-preview.wp-block-legacy-widget__edit-no-preview.wp-block-legacy-widget__edit-no-preview h3 {
|
|
235
235
|
font-size: 14px;
|
|
236
|
-
font-weight: 600;
|
|
236
|
+
font-weight: var(--wpds-typography-font-weight-emphasis, 600);
|
|
237
237
|
margin: 4px 0;
|
|
238
238
|
}
|
|
239
239
|
.wp-block-legacy-widget__edit-no-preview.wp-block-legacy-widget__edit-no-preview.wp-block-legacy-widget__edit-no-preview p {
|
|
@@ -246,7 +246,7 @@
|
|
|
246
246
|
|
|
247
247
|
.interface-complementary-area .wp-block-legacy-widget-inspector-card__name {
|
|
248
248
|
margin: 0 0 5px;
|
|
249
|
-
font-weight:
|
|
249
|
+
font-weight: var(--wpds-typography-font-weight-emphasis, 600);
|
|
250
250
|
}
|
|
251
251
|
|
|
252
252
|
.is-selected .wp-block-legacy-widget__container {
|
|
@@ -259,9 +259,9 @@
|
|
|
259
259
|
}
|
|
260
260
|
|
|
261
261
|
.wp-block-widget-group .widget-title {
|
|
262
|
-
font-family: -apple-system,
|
|
262
|
+
font-family: -apple-system, system-ui, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
|
|
263
263
|
font-size: 18px;
|
|
264
|
-
font-weight: 600;
|
|
264
|
+
font-weight: var(--wpds-typography-font-weight-emphasis, 600);
|
|
265
265
|
}
|
|
266
266
|
|
|
267
267
|
.wp-block-widget-group__placeholder .block-editor-inserter {
|
|
@@ -269,6 +269,6 @@
|
|
|
269
269
|
}
|
|
270
270
|
|
|
271
271
|
.is-dark-theme .wp-block-widget-group__placeholder .block-editor-button-block-appender {
|
|
272
|
-
|
|
272
|
+
border-color: currentColor;
|
|
273
273
|
color: #1e1e1e;
|
|
274
274
|
}
|
package/build-style/style.css
CHANGED
|
@@ -125,16 +125,16 @@
|
|
|
125
125
|
}
|
|
126
126
|
.wp-block-legacy-widget__edit-form .wp-block-legacy-widget__edit-form-title {
|
|
127
127
|
color: #000;
|
|
128
|
-
font-family: -apple-system,
|
|
128
|
+
font-family: -apple-system, system-ui, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
|
|
129
129
|
font-size: 14px;
|
|
130
|
-
font-weight: 600;
|
|
130
|
+
font-weight: var(--wpds-typography-font-weight-emphasis, 600);
|
|
131
131
|
margin: 0 0 12px 0;
|
|
132
132
|
}
|
|
133
133
|
.wp-block-legacy-widget__edit-form .widget-inside.widget-inside {
|
|
134
134
|
border: none;
|
|
135
135
|
box-shadow: none;
|
|
136
136
|
display: block;
|
|
137
|
-
font-family: -apple-system,
|
|
137
|
+
font-family: -apple-system, system-ui, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
|
|
138
138
|
}
|
|
139
139
|
.wp-block-legacy-widget__edit-form .widget-inside.widget-inside p {
|
|
140
140
|
margin: 8px 0;
|
|
@@ -224,7 +224,7 @@
|
|
|
224
224
|
}
|
|
225
225
|
|
|
226
226
|
.wp-block-legacy-widget__edit-no-preview.wp-block-legacy-widget__edit-no-preview.wp-block-legacy-widget__edit-no-preview, .wp-block-legacy-widget__edit-no-preview.wp-block-legacy-widget__edit-no-preview.wp-block-legacy-widget__edit-no-preview h3, .wp-block-legacy-widget__edit-no-preview.wp-block-legacy-widget__edit-no-preview.wp-block-legacy-widget__edit-no-preview p {
|
|
227
|
-
font-family: -apple-system,
|
|
227
|
+
font-family: -apple-system, system-ui, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
|
|
228
228
|
font-size: 13px;
|
|
229
229
|
}
|
|
230
230
|
.wp-block-legacy-widget__edit-no-preview.wp-block-legacy-widget__edit-no-preview.wp-block-legacy-widget__edit-no-preview {
|
|
@@ -233,7 +233,7 @@
|
|
|
233
233
|
}
|
|
234
234
|
.wp-block-legacy-widget__edit-no-preview.wp-block-legacy-widget__edit-no-preview.wp-block-legacy-widget__edit-no-preview h3 {
|
|
235
235
|
font-size: 14px;
|
|
236
|
-
font-weight: 600;
|
|
236
|
+
font-weight: var(--wpds-typography-font-weight-emphasis, 600);
|
|
237
237
|
margin: 4px 0;
|
|
238
238
|
}
|
|
239
239
|
.wp-block-legacy-widget__edit-no-preview.wp-block-legacy-widget__edit-no-preview.wp-block-legacy-widget__edit-no-preview p {
|
|
@@ -246,7 +246,7 @@
|
|
|
246
246
|
|
|
247
247
|
.interface-complementary-area .wp-block-legacy-widget-inspector-card__name {
|
|
248
248
|
margin: 0 0 5px;
|
|
249
|
-
font-weight:
|
|
249
|
+
font-weight: var(--wpds-typography-font-weight-emphasis, 600);
|
|
250
250
|
}
|
|
251
251
|
|
|
252
252
|
.is-selected .wp-block-legacy-widget__container {
|
|
@@ -259,9 +259,9 @@
|
|
|
259
259
|
}
|
|
260
260
|
|
|
261
261
|
.wp-block-widget-group .widget-title {
|
|
262
|
-
font-family: -apple-system,
|
|
262
|
+
font-family: -apple-system, system-ui, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
|
|
263
263
|
font-size: 18px;
|
|
264
|
-
font-weight: 600;
|
|
264
|
+
font-weight: var(--wpds-typography-font-weight-emphasis, 600);
|
|
265
265
|
}
|
|
266
266
|
|
|
267
267
|
.wp-block-widget-group__placeholder .block-editor-inserter {
|
|
@@ -269,6 +269,6 @@
|
|
|
269
269
|
}
|
|
270
270
|
|
|
271
271
|
.is-dark-theme .wp-block-widget-group__placeholder .block-editor-button-block-appender {
|
|
272
|
-
|
|
272
|
+
border-color: currentColor;
|
|
273
273
|
color: #1e1e1e;
|
|
274
274
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wordpress/widgets",
|
|
3
|
-
"version": "4.
|
|
3
|
+
"version": "4.51.0",
|
|
4
4
|
"description": "Functionality used by the widgets block editor in the Widgets screen and the Customizer.",
|
|
5
5
|
"author": "The WordPress Contributors",
|
|
6
6
|
"license": "GPL-2.0-or-later",
|
|
@@ -63,26 +63,26 @@
|
|
|
63
63
|
}
|
|
64
64
|
},
|
|
65
65
|
"dependencies": {
|
|
66
|
-
"@wordpress/api-fetch": "^7.
|
|
67
|
-
"@wordpress/base-styles": "^
|
|
68
|
-
"@wordpress/block-editor": "^16.0.
|
|
69
|
-
"@wordpress/blocks": "^15.
|
|
70
|
-
"@wordpress/components": "^37.0.
|
|
71
|
-
"@wordpress/compose": "^8.
|
|
72
|
-
"@wordpress/core-data": "^7.
|
|
73
|
-
"@wordpress/data": "^10.
|
|
74
|
-
"@wordpress/element": "^8.
|
|
75
|
-
"@wordpress/i18n": "^6.
|
|
76
|
-
"@wordpress/icons": "^15.
|
|
77
|
-
"@wordpress/notices": "^5.
|
|
66
|
+
"@wordpress/api-fetch": "^7.51.0",
|
|
67
|
+
"@wordpress/base-styles": "^11.0.0",
|
|
68
|
+
"@wordpress/block-editor": "^16.0.0",
|
|
69
|
+
"@wordpress/blocks": "^15.24.0",
|
|
70
|
+
"@wordpress/components": "^37.0.0",
|
|
71
|
+
"@wordpress/compose": "^8.4.0",
|
|
72
|
+
"@wordpress/core-data": "^7.51.0",
|
|
73
|
+
"@wordpress/data": "^10.51.0",
|
|
74
|
+
"@wordpress/element": "^8.3.0",
|
|
75
|
+
"@wordpress/i18n": "^6.24.0",
|
|
76
|
+
"@wordpress/icons": "^15.2.0",
|
|
77
|
+
"@wordpress/notices": "^5.51.0",
|
|
78
78
|
"clsx": "^2.1.1"
|
|
79
79
|
},
|
|
80
80
|
"peerDependencies": {
|
|
81
|
-
"react": "^18
|
|
82
|
-
"react-dom": "^18
|
|
81
|
+
"react": "^18 || ^19",
|
|
82
|
+
"react-dom": "^18 || ^19"
|
|
83
83
|
},
|
|
84
84
|
"publishConfig": {
|
|
85
85
|
"access": "public"
|
|
86
86
|
},
|
|
87
|
-
"gitHead": "
|
|
87
|
+
"gitHead": "e9a74f9c14095a34398ecd4d1f7a908e55051205"
|
|
88
88
|
}
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
color: $black;
|
|
17
17
|
font-family: $default-font;
|
|
18
18
|
font-size: 14px;
|
|
19
|
-
font-weight:
|
|
19
|
+
font-weight: var(--wpds-typography-font-weight-emphasis);
|
|
20
20
|
margin: 0 0 $grid-unit-15 0;
|
|
21
21
|
}
|
|
22
22
|
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
border: none;
|
|
25
25
|
box-shadow: none;
|
|
26
26
|
display: block;
|
|
27
|
-
font-family: -
|
|
27
|
+
font-family: $font-family-body;
|
|
28
28
|
|
|
29
29
|
p {
|
|
30
30
|
margin: $grid-unit-10 0;
|
|
@@ -134,7 +134,7 @@
|
|
|
134
134
|
|
|
135
135
|
h3 {
|
|
136
136
|
font-size: 14px;
|
|
137
|
-
font-weight:
|
|
137
|
+
font-weight: var(--wpds-typography-font-weight-emphasis);
|
|
138
138
|
margin: $grid-unit-05 0;
|
|
139
139
|
}
|
|
140
140
|
|
|
@@ -150,7 +150,7 @@
|
|
|
150
150
|
|
|
151
151
|
.interface-complementary-area .wp-block-legacy-widget-inspector-card__name {
|
|
152
152
|
margin: 0 0 5px;
|
|
153
|
-
font-weight:
|
|
153
|
+
font-weight: var(--wpds-typography-font-weight-emphasis);
|
|
154
154
|
}
|
|
155
155
|
|
|
156
156
|
// When wide widget is selected it opens in a popover but its container should still have a bit of height.
|
|
@@ -165,4 +165,3 @@
|
|
|
165
165
|
.components-popover__content .wp-block-legacy-widget__edit-form {
|
|
166
166
|
min-width: 400px;
|
|
167
167
|
}
|
|
168
|
-
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
.widget-title {
|
|
6
6
|
font-family: $default-font;
|
|
7
7
|
font-size: 18px;
|
|
8
|
-
font-weight:
|
|
8
|
+
font-weight: var(--wpds-typography-font-weight-emphasis);
|
|
9
9
|
}
|
|
10
10
|
}
|
|
11
11
|
|
|
@@ -18,6 +18,6 @@
|
|
|
18
18
|
// Force the appender to always have "light mode" styling as it appears in a
|
|
19
19
|
// light colored placeholder.
|
|
20
20
|
.is-dark-theme .wp-block-widget-group__placeholder .block-editor-button-block-appender {
|
|
21
|
-
|
|
21
|
+
border-color: currentColor;
|
|
22
22
|
color: $gray-900;
|
|
23
23
|
}
|
|
@@ -2,10 +2,7 @@
|
|
|
2
2
|
* WordPress dependencies
|
|
3
3
|
*/
|
|
4
4
|
import { __ } from '@wordpress/i18n';
|
|
5
|
-
import {
|
|
6
|
-
createBlock,
|
|
7
|
-
__experimentalCloneSanitizedBlock,
|
|
8
|
-
} from '@wordpress/blocks';
|
|
5
|
+
import { createBlock, cloneSanitizedBlock } from '@wordpress/blocks';
|
|
9
6
|
import { group as icon } from '@wordpress/icons';
|
|
10
7
|
|
|
11
8
|
/**
|
|
@@ -43,7 +40,7 @@ export const settings = {
|
|
|
43
40
|
__experimentalConvert( blocks ) {
|
|
44
41
|
// Put the selected blocks inside the new Widget Group's innerBlocks.
|
|
45
42
|
let innerBlocks = blocks.map( ( block ) =>
|
|
46
|
-
|
|
43
|
+
cloneSanitizedBlock( block )
|
|
47
44
|
);
|
|
48
45
|
|
|
49
46
|
// If the first block is a heading then assume this is intended
|