@measured/puck 0.16.2-canary.36d53b4 → 0.16.2-canary.51154e9
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/{chunk-YNVK2PUD.mjs → chunk-7IH6SUIT.mjs} +1 -1
- package/dist/index.css +10 -10
- package/dist/index.js +6 -6
- package/dist/index.mjs +6 -6
- package/dist/rsc.js +1 -1
- package/dist/rsc.mjs +1 -1
- package/package.json +1 -1
|
@@ -224,7 +224,7 @@ var setupZone = (data, zoneKey) => {
|
|
|
224
224
|
return data;
|
|
225
225
|
}
|
|
226
226
|
const newData = __spreadProps(__spreadValues({}, data), {
|
|
227
|
-
zones: data.zones
|
|
227
|
+
zones: data.zones ? __spreadValues({}, data.zones) : {}
|
|
228
228
|
});
|
|
229
229
|
newData.zones[zoneKey] = newData.zones[zoneKey] || [];
|
|
230
230
|
return newData;
|
package/dist/index.css
CHANGED
|
@@ -137,7 +137,7 @@
|
|
|
137
137
|
/* styles.css */
|
|
138
138
|
|
|
139
139
|
/* css-module:/home/runner/work/puck/puck/packages/core/components/ActionBar/styles.module.css/#css-module-data */
|
|
140
|
-
.
|
|
140
|
+
._ActionBar_151w5_1 {
|
|
141
141
|
display: flex;
|
|
142
142
|
width: auto;
|
|
143
143
|
padding: 4px;
|
|
@@ -151,7 +151,7 @@
|
|
|
151
151
|
gap: 4px;
|
|
152
152
|
min-height: 26px;
|
|
153
153
|
}
|
|
154
|
-
._ActionBar-
|
|
154
|
+
._ActionBar-actionsLabel_151w5_16 {
|
|
155
155
|
color: var(--puck-color-grey-08);
|
|
156
156
|
display: flex;
|
|
157
157
|
font-size: var(--puck-font-size-xxxs);
|
|
@@ -163,19 +163,19 @@
|
|
|
163
163
|
text-overflow: ellipsis;
|
|
164
164
|
white-space: nowrap;
|
|
165
165
|
}
|
|
166
|
-
._ActionBar-
|
|
167
|
-
border-
|
|
166
|
+
._ActionBar-group_151w5_29 {
|
|
167
|
+
border-inline-start: 0.5px solid var(--puck-color-grey-05);
|
|
168
168
|
display: flex;
|
|
169
169
|
padding-left: 4px;
|
|
170
170
|
padding-right: 4px;
|
|
171
171
|
}
|
|
172
|
-
._ActionBar-
|
|
172
|
+
._ActionBar-group_151w5_29:last-of-type {
|
|
173
173
|
padding-right: 0;
|
|
174
174
|
}
|
|
175
|
-
._ActionBar-
|
|
175
|
+
._ActionBar-group_151w5_29:empty {
|
|
176
176
|
display: none;
|
|
177
177
|
}
|
|
178
|
-
._ActionBar-
|
|
178
|
+
._ActionBar-action_151w5_16 {
|
|
179
179
|
background: transparent;
|
|
180
180
|
border: none;
|
|
181
181
|
color: var(--puck-color-grey-08);
|
|
@@ -188,17 +188,17 @@
|
|
|
188
188
|
justify-content: center;
|
|
189
189
|
transition: color 50ms ease-in;
|
|
190
190
|
}
|
|
191
|
-
._ActionBar-
|
|
191
|
+
._ActionBar-action_151w5_16:focus-visible {
|
|
192
192
|
outline: 2px solid var(--puck-color-azure-05);
|
|
193
193
|
outline-offset: -2px;
|
|
194
194
|
}
|
|
195
195
|
@media (hover: hover) and (pointer: fine) {
|
|
196
|
-
._ActionBar-
|
|
196
|
+
._ActionBar-action_151w5_16:hover {
|
|
197
197
|
color: var(--puck-color-azure-06);
|
|
198
198
|
transition: none;
|
|
199
199
|
}
|
|
200
200
|
}
|
|
201
|
-
._ActionBar-
|
|
201
|
+
._ActionBar-action_151w5_16:active {
|
|
202
202
|
color: var(--puck-color-azure-07);
|
|
203
203
|
transition: none;
|
|
204
204
|
}
|
package/dist/index.js
CHANGED
|
@@ -243,7 +243,7 @@ var get_class_name_factory_default = getClassNameFactory;
|
|
|
243
243
|
|
|
244
244
|
// css-module:/home/runner/work/puck/puck/packages/core/components/ActionBar/styles.module.css#css-module
|
|
245
245
|
init_react_import();
|
|
246
|
-
var styles_module_default = { "ActionBar": "
|
|
246
|
+
var styles_module_default = { "ActionBar": "_ActionBar_151w5_1", "ActionBar-actionsLabel": "_ActionBar-actionsLabel_151w5_16", "ActionBar-group": "_ActionBar-group_151w5_29", "ActionBar-action": "_ActionBar-action_151w5_16" };
|
|
247
247
|
|
|
248
248
|
// components/ActionBar/index.tsx
|
|
249
249
|
var import_jsx_runtime = require("react/jsx-runtime");
|
|
@@ -705,7 +705,7 @@ var setupZone = (data, zoneKey) => {
|
|
|
705
705
|
return data;
|
|
706
706
|
}
|
|
707
707
|
const newData = __spreadProps(__spreadValues({}, data), {
|
|
708
|
-
zones: data.zones
|
|
708
|
+
zones: data.zones ? __spreadValues({}, data.zones) : {}
|
|
709
709
|
});
|
|
710
710
|
newData.zones[zoneKey] = newData.zones[zoneKey] || [];
|
|
711
711
|
return newData;
|
|
@@ -840,12 +840,12 @@ var useResolvedPermissions = (config, appState, globalPermissions, setComponentL
|
|
|
840
840
|
({ item, type, root } = {}) => {
|
|
841
841
|
if (item) {
|
|
842
842
|
const componentConfig = config.components[item.type];
|
|
843
|
-
const initialPermissions = __spreadValues(__spreadValues({}, globalPermissions), componentConfig.permissions);
|
|
843
|
+
const initialPermissions = __spreadValues(__spreadValues({}, globalPermissions), componentConfig == null ? void 0 : componentConfig.permissions);
|
|
844
844
|
const resolvedForItem = resolvedPermissions[item.props.id];
|
|
845
845
|
return resolvedForItem ? __spreadValues(__spreadValues({}, globalPermissions), resolvedForItem) : initialPermissions;
|
|
846
846
|
} else if (type) {
|
|
847
847
|
const componentConfig = config.components[type];
|
|
848
|
-
return __spreadValues(__spreadValues({}, globalPermissions), componentConfig.permissions);
|
|
848
|
+
return __spreadValues(__spreadValues({}, globalPermissions), componentConfig == null ? void 0 : componentConfig.permissions);
|
|
849
849
|
} else if (root) {
|
|
850
850
|
const rootConfig = config.root;
|
|
851
851
|
const initialPermissions = __spreadValues(__spreadValues({}, globalPermissions), rootConfig == null ? void 0 : rootConfig.permissions);
|
|
@@ -3699,10 +3699,10 @@ var useResolvedFields = () => {
|
|
|
3699
3699
|
const { data } = state;
|
|
3700
3700
|
const rootFields = ((_a = config.root) == null ? void 0 : _a.fields) || defaultPageFields;
|
|
3701
3701
|
const componentConfig = selectedItem ? config.components[selectedItem.type] : null;
|
|
3702
|
-
const defaultFields = selectedItem ? componentConfig == null ? void 0 : componentConfig.fields : rootFields;
|
|
3702
|
+
const defaultFields = (selectedItem ? componentConfig == null ? void 0 : componentConfig.fields : rootFields) || {};
|
|
3703
3703
|
const rootProps = data.root.props || data.root;
|
|
3704
3704
|
const [lastSelectedData, setLastSelectedData] = (0, import_react21.useState)({});
|
|
3705
|
-
const [resolvedFields, setResolvedFields] = (0, import_react21.useState)(defaultFields
|
|
3705
|
+
const [resolvedFields, setResolvedFields] = (0, import_react21.useState)(defaultFields);
|
|
3706
3706
|
const [fieldsLoading, setFieldsLoading] = (0, import_react21.useState)(false);
|
|
3707
3707
|
const defaultResolveFields = (_componentData, _params) => defaultFields;
|
|
3708
3708
|
const componentData = selectedItem ? selectedItem : { props: rootProps, readOnly: data.root.readOnly };
|
package/dist/index.mjs
CHANGED
|
@@ -13,7 +13,7 @@ import {
|
|
|
13
13
|
resolveRootData,
|
|
14
14
|
rootDroppableId,
|
|
15
15
|
setupZone
|
|
16
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-7IH6SUIT.mjs";
|
|
17
17
|
|
|
18
18
|
// ../../node_modules/classnames/index.js
|
|
19
19
|
var require_classnames = __commonJS({
|
|
@@ -143,7 +143,7 @@ var get_class_name_factory_default = getClassNameFactory;
|
|
|
143
143
|
|
|
144
144
|
// css-module:/home/runner/work/puck/puck/packages/core/components/ActionBar/styles.module.css#css-module
|
|
145
145
|
init_react_import();
|
|
146
|
-
var styles_module_default = { "ActionBar": "
|
|
146
|
+
var styles_module_default = { "ActionBar": "_ActionBar_151w5_1", "ActionBar-actionsLabel": "_ActionBar-actionsLabel_151w5_16", "ActionBar-group": "_ActionBar-group_151w5_29", "ActionBar-action": "_ActionBar-action_151w5_16" };
|
|
147
147
|
|
|
148
148
|
// components/ActionBar/index.tsx
|
|
149
149
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
@@ -722,12 +722,12 @@ var useResolvedPermissions = (config, appState, globalPermissions, setComponentL
|
|
|
722
722
|
({ item, type, root } = {}) => {
|
|
723
723
|
if (item) {
|
|
724
724
|
const componentConfig = config.components[item.type];
|
|
725
|
-
const initialPermissions = __spreadValues(__spreadValues({}, globalPermissions), componentConfig.permissions);
|
|
725
|
+
const initialPermissions = __spreadValues(__spreadValues({}, globalPermissions), componentConfig == null ? void 0 : componentConfig.permissions);
|
|
726
726
|
const resolvedForItem = resolvedPermissions[item.props.id];
|
|
727
727
|
return resolvedForItem ? __spreadValues(__spreadValues({}, globalPermissions), resolvedForItem) : initialPermissions;
|
|
728
728
|
} else if (type) {
|
|
729
729
|
const componentConfig = config.components[type];
|
|
730
|
-
return __spreadValues(__spreadValues({}, globalPermissions), componentConfig.permissions);
|
|
730
|
+
return __spreadValues(__spreadValues({}, globalPermissions), componentConfig == null ? void 0 : componentConfig.permissions);
|
|
731
731
|
} else if (root) {
|
|
732
732
|
const rootConfig = config.root;
|
|
733
733
|
const initialPermissions = __spreadValues(__spreadValues({}, globalPermissions), rootConfig == null ? void 0 : rootConfig.permissions);
|
|
@@ -3528,10 +3528,10 @@ var useResolvedFields = () => {
|
|
|
3528
3528
|
const { data } = state;
|
|
3529
3529
|
const rootFields = ((_a = config.root) == null ? void 0 : _a.fields) || defaultPageFields;
|
|
3530
3530
|
const componentConfig = selectedItem ? config.components[selectedItem.type] : null;
|
|
3531
|
-
const defaultFields = selectedItem ? componentConfig == null ? void 0 : componentConfig.fields : rootFields;
|
|
3531
|
+
const defaultFields = (selectedItem ? componentConfig == null ? void 0 : componentConfig.fields : rootFields) || {};
|
|
3532
3532
|
const rootProps = data.root.props || data.root;
|
|
3533
3533
|
const [lastSelectedData, setLastSelectedData] = useState15({});
|
|
3534
|
-
const [resolvedFields, setResolvedFields] = useState15(defaultFields
|
|
3534
|
+
const [resolvedFields, setResolvedFields] = useState15(defaultFields);
|
|
3535
3535
|
const [fieldsLoading, setFieldsLoading] = useState15(false);
|
|
3536
3536
|
const defaultResolveFields = (_componentData, _params) => defaultFields;
|
|
3537
3537
|
const componentData = selectedItem ? selectedItem : { props: rootProps, readOnly: data.root.readOnly };
|
package/dist/rsc.js
CHANGED
|
@@ -84,7 +84,7 @@ var setupZone = (data, zoneKey) => {
|
|
|
84
84
|
return data;
|
|
85
85
|
}
|
|
86
86
|
const newData = __spreadProps(__spreadValues({}, data), {
|
|
87
|
-
zones: data.zones
|
|
87
|
+
zones: data.zones ? __spreadValues({}, data.zones) : {}
|
|
88
88
|
});
|
|
89
89
|
newData.zones[zoneKey] = newData.zones[zoneKey] || [];
|
|
90
90
|
return newData;
|
package/dist/rsc.mjs
CHANGED
package/package.json
CHANGED