@elementor/editor-canvas 4.1.0-788 → 4.1.0-790
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/dist/index.js +20 -13
- package/dist/index.mjs +20 -13
- package/package.json +18 -18
- package/src/mcp/resources/widgets-schema-resource.ts +20 -13
package/dist/index.js
CHANGED
|
@@ -110,13 +110,19 @@ var WIDGET_SCHEMA_URI = "elementor://widgets/schema/{widgetType}";
|
|
|
110
110
|
var STYLE_SCHEMA_URI = "elementor://styles/schema/{category}";
|
|
111
111
|
var BEST_PRACTICES_URI = "elementor://styles/best-practices";
|
|
112
112
|
var initWidgetsSchemaResource = (reg) => {
|
|
113
|
-
const {
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
113
|
+
const { resource } = reg;
|
|
114
|
+
resource(
|
|
115
|
+
"styles-best-practices",
|
|
116
|
+
BEST_PRACTICES_URI,
|
|
117
|
+
{
|
|
118
|
+
description: "Styling best practices"
|
|
119
|
+
},
|
|
120
|
+
async () => {
|
|
121
|
+
return {
|
|
122
|
+
contents: [
|
|
123
|
+
{
|
|
124
|
+
uri: BEST_PRACTICES_URI,
|
|
125
|
+
text: `# Styling best practices
|
|
120
126
|
Prefer using "em" and "rem" values for text-related sizes, padding and spacing. Use percentages for dynamic sizing relative to parent containers.
|
|
121
127
|
This flexboxes are by default "flex" with "stretch" alignment. To ensure proper layout, define the "justify-content" and "align-items" as in the schema.
|
|
122
128
|
|
|
@@ -128,11 +134,12 @@ When using global variables, ensure that the variables are defined in the ${"ele
|
|
|
128
134
|
Variables from the user context ARE NOT SUPPORTED AND WILL RESOLVE IN ERROR.
|
|
129
135
|
|
|
130
136
|
`
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
137
|
+
}
|
|
138
|
+
]
|
|
139
|
+
};
|
|
140
|
+
}
|
|
141
|
+
);
|
|
142
|
+
resource(
|
|
136
143
|
"styles-schema",
|
|
137
144
|
new import_editor_mcp.ResourceTemplate(STYLE_SCHEMA_URI, {
|
|
138
145
|
list: () => {
|
|
@@ -168,7 +175,7 @@ Variables from the user context ARE NOT SUPPORTED AND WILL RESOLVE IN ERROR.
|
|
|
168
175
|
};
|
|
169
176
|
}
|
|
170
177
|
);
|
|
171
|
-
|
|
178
|
+
resource(
|
|
172
179
|
"widget-schema-by-type",
|
|
173
180
|
new import_editor_mcp.ResourceTemplate(WIDGET_SCHEMA_URI, {
|
|
174
181
|
list: () => {
|
package/dist/index.mjs
CHANGED
|
@@ -55,13 +55,19 @@ var WIDGET_SCHEMA_URI = "elementor://widgets/schema/{widgetType}";
|
|
|
55
55
|
var STYLE_SCHEMA_URI = "elementor://styles/schema/{category}";
|
|
56
56
|
var BEST_PRACTICES_URI = "elementor://styles/best-practices";
|
|
57
57
|
var initWidgetsSchemaResource = (reg) => {
|
|
58
|
-
const {
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
58
|
+
const { resource } = reg;
|
|
59
|
+
resource(
|
|
60
|
+
"styles-best-practices",
|
|
61
|
+
BEST_PRACTICES_URI,
|
|
62
|
+
{
|
|
63
|
+
description: "Styling best practices"
|
|
64
|
+
},
|
|
65
|
+
async () => {
|
|
66
|
+
return {
|
|
67
|
+
contents: [
|
|
68
|
+
{
|
|
69
|
+
uri: BEST_PRACTICES_URI,
|
|
70
|
+
text: `# Styling best practices
|
|
65
71
|
Prefer using "em" and "rem" values for text-related sizes, padding and spacing. Use percentages for dynamic sizing relative to parent containers.
|
|
66
72
|
This flexboxes are by default "flex" with "stretch" alignment. To ensure proper layout, define the "justify-content" and "align-items" as in the schema.
|
|
67
73
|
|
|
@@ -73,11 +79,12 @@ When using global variables, ensure that the variables are defined in the ${"ele
|
|
|
73
79
|
Variables from the user context ARE NOT SUPPORTED AND WILL RESOLVE IN ERROR.
|
|
74
80
|
|
|
75
81
|
`
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
82
|
+
}
|
|
83
|
+
]
|
|
84
|
+
};
|
|
85
|
+
}
|
|
86
|
+
);
|
|
87
|
+
resource(
|
|
81
88
|
"styles-schema",
|
|
82
89
|
new ResourceTemplate(STYLE_SCHEMA_URI, {
|
|
83
90
|
list: () => {
|
|
@@ -113,7 +120,7 @@ Variables from the user context ARE NOT SUPPORTED AND WILL RESOLVE IN ERROR.
|
|
|
113
120
|
};
|
|
114
121
|
}
|
|
115
122
|
);
|
|
116
|
-
|
|
123
|
+
resource(
|
|
117
124
|
"widget-schema-by-type",
|
|
118
125
|
new ResourceTemplate(WIDGET_SCHEMA_URI, {
|
|
119
126
|
list: () => {
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@elementor/editor-canvas",
|
|
3
3
|
"description": "Elementor Editor Canvas",
|
|
4
|
-
"version": "4.1.0-
|
|
4
|
+
"version": "4.1.0-790",
|
|
5
5
|
"private": false,
|
|
6
6
|
"author": "Elementor Team",
|
|
7
7
|
"homepage": "https://elementor.com/",
|
|
@@ -37,25 +37,25 @@
|
|
|
37
37
|
"react-dom": "^18.3.1"
|
|
38
38
|
},
|
|
39
39
|
"dependencies": {
|
|
40
|
-
"@elementor/editor": "4.1.0-
|
|
40
|
+
"@elementor/editor": "4.1.0-790",
|
|
41
41
|
"dompurify": "^3.2.6",
|
|
42
|
-
"@elementor/editor-controls": "4.1.0-
|
|
43
|
-
"@elementor/editor-documents": "4.1.0-
|
|
44
|
-
"@elementor/editor-elements": "4.1.0-
|
|
45
|
-
"@elementor/editor-interactions": "4.1.0-
|
|
46
|
-
"@elementor/editor-mcp": "4.1.0-
|
|
47
|
-
"@elementor/editor-notifications": "4.1.0-
|
|
48
|
-
"@elementor/editor-props": "4.1.0-
|
|
49
|
-
"@elementor/editor-responsive": "4.1.0-
|
|
50
|
-
"@elementor/editor-styles": "4.1.0-
|
|
51
|
-
"@elementor/editor-styles-repository": "4.1.0-
|
|
52
|
-
"@elementor/editor-ui": "4.1.0-
|
|
53
|
-
"@elementor/editor-v1-adapters": "4.1.0-
|
|
54
|
-
"@elementor/schema": "4.1.0-
|
|
55
|
-
"@elementor/twing": "4.1.0-
|
|
42
|
+
"@elementor/editor-controls": "4.1.0-790",
|
|
43
|
+
"@elementor/editor-documents": "4.1.0-790",
|
|
44
|
+
"@elementor/editor-elements": "4.1.0-790",
|
|
45
|
+
"@elementor/editor-interactions": "4.1.0-790",
|
|
46
|
+
"@elementor/editor-mcp": "4.1.0-790",
|
|
47
|
+
"@elementor/editor-notifications": "4.1.0-790",
|
|
48
|
+
"@elementor/editor-props": "4.1.0-790",
|
|
49
|
+
"@elementor/editor-responsive": "4.1.0-790",
|
|
50
|
+
"@elementor/editor-styles": "4.1.0-790",
|
|
51
|
+
"@elementor/editor-styles-repository": "4.1.0-790",
|
|
52
|
+
"@elementor/editor-ui": "4.1.0-790",
|
|
53
|
+
"@elementor/editor-v1-adapters": "4.1.0-790",
|
|
54
|
+
"@elementor/schema": "4.1.0-790",
|
|
55
|
+
"@elementor/twing": "4.1.0-790",
|
|
56
56
|
"@elementor/ui": "1.37.5",
|
|
57
|
-
"@elementor/utils": "4.1.0-
|
|
58
|
-
"@elementor/wp-media": "4.1.0-
|
|
57
|
+
"@elementor/utils": "4.1.0-790",
|
|
58
|
+
"@elementor/wp-media": "4.1.0-790",
|
|
59
59
|
"@floating-ui/react": "^0.27.5",
|
|
60
60
|
"@wordpress/i18n": "^5.13.0"
|
|
61
61
|
},
|
|
@@ -16,14 +16,20 @@ export const STYLE_SCHEMA_URI = 'elementor://styles/schema/{category}';
|
|
|
16
16
|
export const BEST_PRACTICES_URI = 'elementor://styles/best-practices';
|
|
17
17
|
|
|
18
18
|
export const initWidgetsSchemaResource = ( reg: MCPRegistryEntry ) => {
|
|
19
|
-
const {
|
|
19
|
+
const { resource } = reg;
|
|
20
20
|
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
21
|
+
resource(
|
|
22
|
+
'styles-best-practices',
|
|
23
|
+
BEST_PRACTICES_URI,
|
|
24
|
+
{
|
|
25
|
+
description: 'Styling best practices',
|
|
26
|
+
},
|
|
27
|
+
async () => {
|
|
28
|
+
return {
|
|
29
|
+
contents: [
|
|
30
|
+
{
|
|
31
|
+
uri: BEST_PRACTICES_URI,
|
|
32
|
+
text: `# Styling best practices
|
|
27
33
|
Prefer using "em" and "rem" values for text-related sizes, padding and spacing. Use percentages for dynamic sizing relative to parent containers.
|
|
28
34
|
This flexboxes are by default "flex" with "stretch" alignment. To ensure proper layout, define the "justify-content" and "align-items" as in the schema.
|
|
29
35
|
|
|
@@ -35,12 +41,13 @@ When using global variables, ensure that the variables are defined in the ${ 'el
|
|
|
35
41
|
Variables from the user context ARE NOT SUPPORTED AND WILL RESOLVE IN ERROR.
|
|
36
42
|
|
|
37
43
|
`,
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
44
|
+
},
|
|
45
|
+
],
|
|
46
|
+
};
|
|
47
|
+
}
|
|
48
|
+
);
|
|
42
49
|
|
|
43
|
-
|
|
50
|
+
resource(
|
|
44
51
|
'styles-schema',
|
|
45
52
|
new ResourceTemplate( STYLE_SCHEMA_URI, {
|
|
46
53
|
list: () => {
|
|
@@ -77,7 +84,7 @@ Variables from the user context ARE NOT SUPPORTED AND WILL RESOLVE IN ERROR.
|
|
|
77
84
|
}
|
|
78
85
|
);
|
|
79
86
|
|
|
80
|
-
|
|
87
|
+
resource(
|
|
81
88
|
'widget-schema-by-type',
|
|
82
89
|
new ResourceTemplate( WIDGET_SCHEMA_URI, {
|
|
83
90
|
list: () => {
|