@measured/puck 0.21.0-canary.3aa27d1d → 0.21.0-canary.56be3202

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.
Files changed (52) hide show
  1. package/dist/Editor-CYTATURR.mjs +204 -0
  2. package/dist/Editor-F2LSS6SE.css +403 -0
  3. package/dist/Render-OFE6QLI2.mjs +55 -0
  4. package/dist/Render-QEMDIDQC.css +101 -0
  5. package/dist/{walk-tree-16XYcbNo.d.mts → actions-tsxxcX1z.d.mts} +29 -40
  6. package/dist/{walk-tree-16XYcbNo.d.ts → actions-tsxxcX1z.d.ts} +29 -40
  7. package/dist/chunk-72SA22GI.mjs +134 -0
  8. package/dist/chunk-CSSRLPHM.mjs +11 -0
  9. package/dist/chunk-M4QBB3JM.mjs +111 -0
  10. package/dist/chunk-M6W7YEVX.mjs +95 -0
  11. package/dist/chunk-MLTVJA2A.mjs +63 -0
  12. package/dist/chunk-MVJKIFF6.mjs +419 -0
  13. package/dist/chunk-NLUHDYVR.mjs +416 -0
  14. package/dist/chunk-NOJQSXRU.mjs +33 -0
  15. package/dist/{chunk-GFIVKP2H.mjs → chunk-PZ4SED7H.mjs} +6848 -9297
  16. package/dist/chunk-QBGM4ELA.mjs +528 -0
  17. package/dist/chunk-UNQOU2OI.mjs +53 -0
  18. package/dist/chunk-UUOBSXZR.mjs +1807 -0
  19. package/dist/chunk-V5I7CVLT.mjs +103 -0
  20. package/dist/chunk-V7333LON.mjs +708 -0
  21. package/dist/chunk-Y2EFNT5P.mjs +108 -0
  22. package/dist/full-2GJTAAZE.css +301 -0
  23. package/dist/full-GZ4L3XCF.mjs +93 -0
  24. package/dist/index-Ca6V6NQD.d.ts +118 -0
  25. package/dist/index-mQvUCH3C.d.mts +118 -0
  26. package/dist/index.css +856 -458
  27. package/dist/index.d.mts +32 -129
  28. package/dist/index.d.ts +32 -129
  29. package/dist/index.js +11790 -9359
  30. package/dist/index.mjs +32 -14
  31. package/dist/internal.d.mts +27 -0
  32. package/dist/internal.d.ts +27 -0
  33. package/dist/internal.js +908 -0
  34. package/dist/internal.mjs +13 -0
  35. package/dist/loaded-2MNXXPJP.mjs +57 -0
  36. package/dist/loaded-6QT4HD2O.mjs +57 -0
  37. package/dist/loaded-RVWBFK7L.css +87 -0
  38. package/dist/loaded-ZVPBQVNE.mjs +60 -0
  39. package/dist/no-external.css +988 -586
  40. package/dist/no-external.d.mts +4 -2
  41. package/dist/no-external.d.ts +4 -2
  42. package/dist/no-external.js +11793 -9359
  43. package/dist/no-external.mjs +34 -11
  44. package/dist/rsc.css +34 -26
  45. package/dist/rsc.d.mts +2 -2
  46. package/dist/rsc.d.ts +2 -2
  47. package/dist/rsc.js +249 -189
  48. package/dist/rsc.mjs +18 -9
  49. package/dist/walk-tree-Bh85NMeo.d.ts +29 -0
  50. package/dist/walk-tree-CDA3K5S3.d.mts +29 -0
  51. package/package.json +9 -4
  52. package/dist/chunk-SRDLYODX.mjs +0 -1245
@@ -1,1245 +0,0 @@
1
- var __create = Object.create;
2
- var __defProp = Object.defineProperty;
3
- var __defProps = Object.defineProperties;
4
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
- var __getOwnPropDescs = Object.getOwnPropertyDescriptors;
6
- var __getOwnPropNames = Object.getOwnPropertyNames;
7
- var __getOwnPropSymbols = Object.getOwnPropertySymbols;
8
- var __getProtoOf = Object.getPrototypeOf;
9
- var __hasOwnProp = Object.prototype.hasOwnProperty;
10
- var __propIsEnum = Object.prototype.propertyIsEnumerable;
11
- var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
12
- var __spreadValues = (a, b) => {
13
- for (var prop in b || (b = {}))
14
- if (__hasOwnProp.call(b, prop))
15
- __defNormalProp(a, prop, b[prop]);
16
- if (__getOwnPropSymbols)
17
- for (var prop of __getOwnPropSymbols(b)) {
18
- if (__propIsEnum.call(b, prop))
19
- __defNormalProp(a, prop, b[prop]);
20
- }
21
- return a;
22
- };
23
- var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
24
- var __objRest = (source, exclude) => {
25
- var target = {};
26
- for (var prop in source)
27
- if (__hasOwnProp.call(source, prop) && exclude.indexOf(prop) < 0)
28
- target[prop] = source[prop];
29
- if (source != null && __getOwnPropSymbols)
30
- for (var prop of __getOwnPropSymbols(source)) {
31
- if (exclude.indexOf(prop) < 0 && __propIsEnum.call(source, prop))
32
- target[prop] = source[prop];
33
- }
34
- return target;
35
- };
36
- var __esm = (fn, res) => function __init() {
37
- return fn && (res = (0, fn[__getOwnPropNames(fn)[0]])(fn = 0)), res;
38
- };
39
- var __commonJS = (cb, mod) => function __require() {
40
- return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
41
- };
42
- var __copyProps = (to, from, except, desc) => {
43
- if (from && typeof from === "object" || typeof from === "function") {
44
- for (let key of __getOwnPropNames(from))
45
- if (!__hasOwnProp.call(to, key) && key !== except)
46
- __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
47
- }
48
- return to;
49
- };
50
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
51
- // If the importer is in node compatibility mode or this is not an ESM
52
- // file that has been converted to a CommonJS file using a Babel-
53
- // compatible transform (i.e. "__esModule" has not been set), then set
54
- // "default" to the CommonJS "module.exports" for node compatibility.
55
- isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
56
- mod
57
- ));
58
- var __async = (__this, __arguments, generator) => {
59
- return new Promise((resolve, reject) => {
60
- var fulfilled = (value) => {
61
- try {
62
- step(generator.next(value));
63
- } catch (e) {
64
- reject(e);
65
- }
66
- };
67
- var rejected = (value) => {
68
- try {
69
- step(generator.throw(value));
70
- } catch (e) {
71
- reject(e);
72
- }
73
- };
74
- var step = (x) => x.done ? resolve(x.value) : Promise.resolve(x.value).then(fulfilled, rejected);
75
- step((generator = generator.apply(__this, __arguments)).next());
76
- });
77
- };
78
-
79
- // ../tsup-config/react-import.js
80
- import React from "react";
81
- var init_react_import = __esm({
82
- "../tsup-config/react-import.js"() {
83
- "use strict";
84
- }
85
- });
86
-
87
- // ../../node_modules/classnames/index.js
88
- var require_classnames = __commonJS({
89
- "../../node_modules/classnames/index.js"(exports, module) {
90
- "use strict";
91
- init_react_import();
92
- (function() {
93
- "use strict";
94
- var hasOwn = {}.hasOwnProperty;
95
- function classNames() {
96
- var classes = "";
97
- for (var i = 0; i < arguments.length; i++) {
98
- var arg = arguments[i];
99
- if (arg) {
100
- classes = appendClass(classes, parseValue(arg));
101
- }
102
- }
103
- return classes;
104
- }
105
- function parseValue(arg) {
106
- if (typeof arg === "string" || typeof arg === "number") {
107
- return arg;
108
- }
109
- if (typeof arg !== "object") {
110
- return "";
111
- }
112
- if (Array.isArray(arg)) {
113
- return classNames.apply(null, arg);
114
- }
115
- if (arg.toString !== Object.prototype.toString && !arg.toString.toString().includes("[native code]")) {
116
- return arg.toString();
117
- }
118
- var classes = "";
119
- for (var key in arg) {
120
- if (hasOwn.call(arg, key) && arg[key]) {
121
- classes = appendClass(classes, key);
122
- }
123
- }
124
- return classes;
125
- }
126
- function appendClass(value, newClass) {
127
- if (!newClass) {
128
- return value;
129
- }
130
- if (value) {
131
- return value + " " + newClass;
132
- }
133
- return value + newClass;
134
- }
135
- if (typeof module !== "undefined" && module.exports) {
136
- classNames.default = classNames;
137
- module.exports = classNames;
138
- } else if (typeof define === "function" && typeof define.amd === "object" && define.amd) {
139
- define("classnames", [], function() {
140
- return classNames;
141
- });
142
- } else {
143
- window.classNames = classNames;
144
- }
145
- })();
146
- }
147
- });
148
-
149
- // lib/data/walk-tree.ts
150
- init_react_import();
151
-
152
- // lib/data/map-fields.ts
153
- init_react_import();
154
-
155
- // lib/data/default-slots.ts
156
- init_react_import();
157
- var defaultSlots = (value, fields) => Object.keys(fields).reduce(
158
- (acc, fieldName) => fields[fieldName].type === "slot" ? __spreadValues({ [fieldName]: [] }, acc) : acc,
159
- value
160
- );
161
-
162
- // lib/data/map-fields.ts
163
- var isPromise = (v) => !!v && typeof v.then === "function";
164
- var flatten = (values) => values.reduce((acc, item) => __spreadValues(__spreadValues({}, acc), item), {});
165
- var containsPromise = (arr) => arr.some(isPromise);
166
- var walkField = ({
167
- value,
168
- fields,
169
- mappers,
170
- propKey = "",
171
- propPath = "",
172
- id = "",
173
- config,
174
- recurseSlots = false
175
- }) => {
176
- var _a, _b, _c;
177
- const fieldType = (_a = fields[propKey]) == null ? void 0 : _a.type;
178
- const map = mappers[fieldType];
179
- if (map && fieldType === "slot") {
180
- const content = value || [];
181
- const mappedContent = recurseSlots ? content.map((el) => {
182
- var _a2;
183
- const componentConfig = config.components[el.type];
184
- if (!componentConfig) {
185
- throw new Error(`Could not find component config for ${el.type}`);
186
- }
187
- const fields2 = (_a2 = componentConfig.fields) != null ? _a2 : {};
188
- return walkField({
189
- value: __spreadProps(__spreadValues({}, el), { props: defaultSlots(el.props, fields2) }),
190
- fields: fields2,
191
- mappers,
192
- id: el.props.id,
193
- config,
194
- recurseSlots
195
- });
196
- }) : content;
197
- if (containsPromise(mappedContent)) {
198
- return Promise.all(mappedContent);
199
- }
200
- return map({
201
- value: mappedContent,
202
- parentId: id,
203
- propName: propPath,
204
- field: fields[propKey],
205
- propPath
206
- });
207
- } else if (map && fields[propKey]) {
208
- return map({
209
- value,
210
- parentId: id,
211
- propName: propKey,
212
- field: fields[propKey],
213
- propPath
214
- });
215
- }
216
- if (value && typeof value === "object") {
217
- if (Array.isArray(value)) {
218
- const arrayFields = ((_b = fields[propKey]) == null ? void 0 : _b.type) === "array" ? fields[propKey].arrayFields : null;
219
- if (!arrayFields) return value;
220
- const newValue = value.map(
221
- (el, idx) => walkField({
222
- value: el,
223
- fields: arrayFields,
224
- mappers,
225
- propKey,
226
- propPath: `${propPath}[${idx}]`,
227
- id,
228
- config,
229
- recurseSlots
230
- })
231
- );
232
- if (containsPromise(newValue)) {
233
- return Promise.all(newValue);
234
- }
235
- return newValue;
236
- } else if ("$$typeof" in value) {
237
- return value;
238
- } else {
239
- const objectFields = ((_c = fields[propKey]) == null ? void 0 : _c.type) === "object" ? fields[propKey].objectFields : fields;
240
- return walkObject({
241
- value,
242
- fields: objectFields,
243
- mappers,
244
- id,
245
- getPropPath: (k) => `${propPath}.${k}`,
246
- config,
247
- recurseSlots
248
- });
249
- }
250
- }
251
- return value;
252
- };
253
- var walkObject = ({
254
- value,
255
- fields,
256
- mappers,
257
- id,
258
- getPropPath,
259
- config,
260
- recurseSlots
261
- }) => {
262
- const newProps = Object.entries(value).map(([k, v]) => {
263
- const opts = {
264
- value: v,
265
- fields,
266
- mappers,
267
- propKey: k,
268
- propPath: getPropPath(k),
269
- id,
270
- config,
271
- recurseSlots
272
- };
273
- const newValue = walkField(opts);
274
- if (isPromise(newValue)) {
275
- return newValue.then((resolvedValue) => ({
276
- [k]: resolvedValue
277
- }));
278
- }
279
- return {
280
- [k]: newValue
281
- };
282
- }, {});
283
- if (containsPromise(newProps)) {
284
- return Promise.all(newProps).then(flatten);
285
- }
286
- return flatten(newProps);
287
- };
288
- function mapFields(item, mappers, config, recurseSlots = false) {
289
- var _a, _b, _c, _d, _e;
290
- const itemType = "type" in item ? item.type : "root";
291
- const componentConfig = itemType === "root" ? config.root : (_a = config.components) == null ? void 0 : _a[itemType];
292
- const newProps = walkObject({
293
- value: defaultSlots((_b = item.props) != null ? _b : {}, (_c = componentConfig == null ? void 0 : componentConfig.fields) != null ? _c : {}),
294
- fields: (_d = componentConfig == null ? void 0 : componentConfig.fields) != null ? _d : {},
295
- mappers,
296
- id: item.props ? (_e = item.props.id) != null ? _e : "root" : "root",
297
- getPropPath: (k) => k,
298
- config,
299
- recurseSlots
300
- });
301
- if (isPromise(newProps)) {
302
- return newProps.then((resolvedProps) => __spreadProps(__spreadValues({}, item), {
303
- props: resolvedProps
304
- }));
305
- }
306
- return __spreadProps(__spreadValues({}, item), {
307
- props: newProps
308
- });
309
- }
310
-
311
- // lib/data/walk-tree.ts
312
- function walkTree(data, config, callbackFn) {
313
- var _a, _b;
314
- const walkItem = (item) => {
315
- return mapFields(
316
- item,
317
- {
318
- slot: ({ value, parentId, propName }) => {
319
- var _a2;
320
- const content = value;
321
- return (_a2 = callbackFn(content, { parentId, propName })) != null ? _a2 : content;
322
- }
323
- },
324
- config,
325
- true
326
- );
327
- };
328
- if ("props" in data) {
329
- return walkItem(data);
330
- }
331
- const _data = data;
332
- const zones = (_a = _data.zones) != null ? _a : {};
333
- const mappedContent = _data.content.map(walkItem);
334
- return {
335
- root: walkItem(_data.root),
336
- content: (_b = callbackFn(mappedContent, {
337
- parentId: "root",
338
- propName: "default-zone"
339
- })) != null ? _b : mappedContent,
340
- zones: Object.keys(zones).reduce(
341
- (acc, zoneCompound) => __spreadProps(__spreadValues({}, acc), {
342
- [zoneCompound]: zones[zoneCompound].map(walkItem)
343
- }),
344
- {}
345
- )
346
- };
347
- }
348
-
349
- // lib/migrate.ts
350
- init_react_import();
351
-
352
- // store/default-app-state.ts
353
- init_react_import();
354
-
355
- // components/ViewportControls/default-viewports.ts
356
- init_react_import();
357
- var defaultViewports = [
358
- { width: 360, height: "auto", icon: "Smartphone", label: "Small" },
359
- { width: 768, height: "auto", icon: "Tablet", label: "Medium" },
360
- { width: 1280, height: "auto", icon: "Monitor", label: "Large" }
361
- ];
362
-
363
- // store/default-app-state.ts
364
- var defaultAppState = {
365
- data: { content: [], root: {}, zones: {} },
366
- ui: {
367
- leftSideBarVisible: true,
368
- rightSideBarVisible: true,
369
- arrayState: {},
370
- itemSelector: null,
371
- componentList: {},
372
- isDragging: false,
373
- previewMode: "edit",
374
- viewports: {
375
- current: {
376
- width: defaultViewports[0].width,
377
- height: defaultViewports[0].height || "auto"
378
- },
379
- options: [],
380
- controlsVisible: true
381
- },
382
- field: { focus: null }
383
- },
384
- indexes: {
385
- nodes: {},
386
- zones: {}
387
- }
388
- };
389
-
390
- // lib/data/walk-app-state.ts
391
- init_react_import();
392
-
393
- // lib/data/for-related-zones.ts
394
- init_react_import();
395
-
396
- // lib/get-zone-id.ts
397
- init_react_import();
398
-
399
- // lib/root-droppable-id.ts
400
- init_react_import();
401
- var rootAreaId = "root";
402
- var rootZone = "default-zone";
403
- var rootDroppableId = `${rootAreaId}:${rootZone}`;
404
-
405
- // lib/get-zone-id.ts
406
- var getZoneId = (zoneCompound) => {
407
- if (!zoneCompound) {
408
- return [];
409
- }
410
- if (zoneCompound && zoneCompound.indexOf(":") > -1) {
411
- return zoneCompound.split(":");
412
- }
413
- return [rootDroppableId, zoneCompound];
414
- };
415
-
416
- // lib/data/for-related-zones.ts
417
- function forRelatedZones(item, data, cb, path = []) {
418
- Object.entries(data.zones || {}).forEach(([zoneCompound, content]) => {
419
- const [parentId] = getZoneId(zoneCompound);
420
- if (parentId === item.props.id) {
421
- cb(path, zoneCompound, content);
422
- }
423
- });
424
- }
425
-
426
- // lib/data/flatten-node.ts
427
- init_react_import();
428
- import flat from "flat";
429
-
430
- // lib/data/strip-slots.ts
431
- init_react_import();
432
- var stripSlots = (data, config) => {
433
- return mapFields(data, { slot: () => null }, config);
434
- };
435
-
436
- // lib/data/flatten-node.ts
437
- var { flatten: flatten2, unflatten } = flat;
438
- var flattenNode = (node, config) => {
439
- return __spreadProps(__spreadValues({}, node), {
440
- props: flatten2(stripSlots(node, config).props)
441
- });
442
- };
443
- var expandNode = (node) => {
444
- const props = unflatten(node.props);
445
- return __spreadProps(__spreadValues({}, node), {
446
- props
447
- });
448
- };
449
-
450
- // lib/data/walk-app-state.ts
451
- function walkAppState(state, config, mapContent = (content) => content, mapNodeOrSkip = (item) => item) {
452
- var _a;
453
- let newZones = {};
454
- const newZoneIndex = {};
455
- const newNodeIndex = {};
456
- const processContent = (path, zoneCompound, content, zoneType, newId) => {
457
- var _a2;
458
- const [parentId] = zoneCompound.split(":");
459
- const mappedContent = ((_a2 = mapContent(content, zoneCompound, zoneType)) != null ? _a2 : content) || [];
460
- const [_2, zone] = zoneCompound.split(":");
461
- const newZoneCompound = `${newId || parentId}:${zone}`;
462
- const newContent2 = mappedContent.map(
463
- (zoneChild, index) => processItem(zoneChild, [...path, newZoneCompound], index)
464
- );
465
- newZoneIndex[newZoneCompound] = {
466
- contentIds: newContent2.map((item) => item.props.id),
467
- type: zoneType
468
- };
469
- return [newZoneCompound, newContent2];
470
- };
471
- const processRelatedZones = (item, newId, initialPath) => {
472
- forRelatedZones(
473
- item,
474
- state.data,
475
- (relatedPath, relatedZoneCompound, relatedContent) => {
476
- const [zoneCompound, newContent2] = processContent(
477
- relatedPath,
478
- relatedZoneCompound,
479
- relatedContent,
480
- "dropzone",
481
- newId
482
- );
483
- newZones[zoneCompound] = newContent2;
484
- },
485
- initialPath
486
- );
487
- };
488
- const processItem = (item, path, index) => {
489
- const mappedItem = mapNodeOrSkip(item, path, index);
490
- if (!mappedItem) return item;
491
- const id = mappedItem.props.id;
492
- const newProps = __spreadProps(__spreadValues({}, mapFields(
493
- mappedItem,
494
- {
495
- slot: ({ value, parentId: parentId2, propPath }) => {
496
- const content = value;
497
- const zoneCompound = `${parentId2}:${propPath}`;
498
- const [_2, newContent2] = processContent(
499
- path,
500
- zoneCompound,
501
- content,
502
- "slot",
503
- parentId2
504
- );
505
- return newContent2;
506
- }
507
- },
508
- config
509
- ).props), {
510
- id
511
- });
512
- processRelatedZones(item, id, path);
513
- const newItem = __spreadProps(__spreadValues({}, item), { props: newProps });
514
- const thisZoneCompound = path[path.length - 1];
515
- const [parentId, zone] = thisZoneCompound ? thisZoneCompound.split(":") : [null, ""];
516
- newNodeIndex[id] = {
517
- data: newItem,
518
- flatData: flattenNode(newItem, config),
519
- path,
520
- parentId,
521
- zone
522
- };
523
- const finalData = __spreadProps(__spreadValues({}, newItem), { props: __spreadValues({}, newItem.props) });
524
- if (newProps.id === "root") {
525
- delete finalData["type"];
526
- delete finalData.props["id"];
527
- }
528
- return finalData;
529
- };
530
- const zones = state.data.zones || {};
531
- const [_, newContent] = processContent(
532
- [],
533
- rootDroppableId,
534
- state.data.content,
535
- "root"
536
- );
537
- const processedContent = newContent;
538
- const zonesAlreadyProcessed = Object.keys(newZones);
539
- Object.keys(zones || {}).forEach((zoneCompound) => {
540
- const [parentId] = zoneCompound.split(":");
541
- if (zonesAlreadyProcessed.includes(zoneCompound)) {
542
- return;
543
- }
544
- const [_2, newContent2] = processContent(
545
- [rootDroppableId],
546
- zoneCompound,
547
- zones[zoneCompound],
548
- "dropzone",
549
- parentId
550
- );
551
- newZones[zoneCompound] = newContent2;
552
- }, newZones);
553
- const processedRoot = processItem(
554
- {
555
- type: "root",
556
- props: __spreadProps(__spreadValues({}, (_a = state.data.root.props) != null ? _a : state.data.root), { id: "root" })
557
- },
558
- [],
559
- -1
560
- );
561
- const root = __spreadProps(__spreadValues({}, state.data.root), {
562
- props: processedRoot.props
563
- });
564
- return __spreadProps(__spreadValues({}, state), {
565
- data: {
566
- root,
567
- content: processedContent,
568
- zones: __spreadValues(__spreadValues({}, state.data.zones), newZones)
569
- },
570
- indexes: {
571
- nodes: __spreadValues(__spreadValues({}, state.indexes.nodes), newNodeIndex),
572
- zones: __spreadValues(__spreadValues({}, state.indexes.zones), newZoneIndex)
573
- }
574
- });
575
- }
576
-
577
- // lib/migrate.ts
578
- var migrations = [
579
- // Migrate root to root.props
580
- (data) => {
581
- const rootProps = data.root.props || data.root;
582
- if (Object.keys(data.root).length > 0 && !data.root.props) {
583
- console.warn(
584
- "Migration applied: Root props moved from `root` to `root.props`."
585
- );
586
- return __spreadProps(__spreadValues({}, data), {
587
- root: {
588
- props: __spreadValues({}, rootProps)
589
- }
590
- });
591
- }
592
- return data;
593
- },
594
- // Migrate zones to slots
595
- (data, config, migrationOptions) => {
596
- var _a, _b;
597
- if (!config) return data;
598
- console.log("Migrating DropZones to slots...");
599
- const updatedItems = {};
600
- const appState = __spreadProps(__spreadValues({}, defaultAppState), { data });
601
- const { indexes } = walkAppState(appState, config);
602
- const deletedCompounds = [];
603
- walkAppState(appState, config, (content, zoneCompound, zoneType) => {
604
- var _a2, _b2, _c;
605
- if (zoneType === "dropzone") {
606
- const [id, slotName] = zoneCompound.split(":");
607
- const nodeData = indexes.nodes[id].data;
608
- const componentType = nodeData.type;
609
- const configForComponent = id === "root" ? config.root : config.components[componentType];
610
- if (((_b2 = (_a2 = configForComponent == null ? void 0 : configForComponent.fields) == null ? void 0 : _a2[slotName]) == null ? void 0 : _b2.type) === "slot") {
611
- updatedItems[id] = __spreadProps(__spreadValues({}, nodeData), {
612
- props: __spreadProps(__spreadValues(__spreadValues({}, nodeData.props), (_c = updatedItems[id]) == null ? void 0 : _c.props), {
613
- [slotName]: content
614
- })
615
- });
616
- deletedCompounds.push(zoneCompound);
617
- }
618
- return content;
619
- }
620
- return content;
621
- });
622
- const updated = walkAppState(
623
- appState,
624
- config,
625
- (content) => content,
626
- (item) => {
627
- var _a2;
628
- return (_a2 = updatedItems[item.props.id]) != null ? _a2 : item;
629
- }
630
- );
631
- deletedCompounds.forEach((zoneCompound) => {
632
- var _a2;
633
- const [_, propName] = zoneCompound.split(":");
634
- console.log(
635
- `\u2713 Success: Migrated "${zoneCompound}" from DropZone to slot field "${propName}"`
636
- );
637
- (_a2 = updated.data.zones) == null ? true : delete _a2[zoneCompound];
638
- });
639
- if (migrationOptions == null ? void 0 : migrationOptions.migrateDynamicZonesForComponent) {
640
- const unmigratedZonesGrouped = {};
641
- Object.keys((_a = updated.data.zones) != null ? _a : {}).forEach((zoneCompound) => {
642
- var _a2;
643
- const [componentId, propName] = zoneCompound.split(":");
644
- const content = (_a2 = updated.data.zones) == null ? void 0 : _a2[zoneCompound];
645
- if (!content) {
646
- return;
647
- }
648
- if (!unmigratedZonesGrouped[componentId]) {
649
- unmigratedZonesGrouped[componentId] = {};
650
- }
651
- if (!unmigratedZonesGrouped[componentId][propName]) {
652
- unmigratedZonesGrouped[componentId][propName] = content;
653
- }
654
- });
655
- Object.keys(unmigratedZonesGrouped).forEach((componentId) => {
656
- updated.data = walkTree(updated.data, config, (content) => {
657
- return content.map((child) => {
658
- var _a2;
659
- if (child.props.id !== componentId) {
660
- return child;
661
- }
662
- const migrateFn = (_a2 = migrationOptions == null ? void 0 : migrationOptions.migrateDynamicZonesForComponent) == null ? void 0 : _a2[child.type];
663
- if (!migrateFn) {
664
- return child;
665
- }
666
- const zones = unmigratedZonesGrouped[componentId];
667
- const migratedProps = migrateFn(child.props, zones);
668
- Object.keys(zones).forEach((propName) => {
669
- var _a3;
670
- const zoneCompound = `${componentId}:${propName}`;
671
- console.log(`\u2713 Success: Migrated "${zoneCompound}" DropZone`);
672
- (_a3 = updated.data.zones) == null ? true : delete _a3[zoneCompound];
673
- });
674
- return __spreadProps(__spreadValues({}, child), {
675
- props: migratedProps
676
- });
677
- });
678
- });
679
- });
680
- }
681
- Object.keys((_b = updated.data.zones) != null ? _b : {}).forEach((zoneCompound) => {
682
- const [_, propName] = zoneCompound.split(":");
683
- throw new Error(
684
- `Could not migrate DropZone "${zoneCompound}" to slot field. No slot exists with the name "${propName}".`
685
- );
686
- });
687
- delete updated.data.zones;
688
- return updated.data;
689
- }
690
- ];
691
- function migrate(data, config, migrationOptions) {
692
- return migrations == null ? void 0 : migrations.reduce(
693
- (acc, migration) => migration(acc, config, migrationOptions),
694
- data
695
- );
696
- }
697
-
698
- // lib/transform-props.ts
699
- init_react_import();
700
-
701
- // lib/data/default-data.ts
702
- init_react_import();
703
- var defaultData = (data) => __spreadProps(__spreadValues({}, data), {
704
- root: data.root || {},
705
- content: data.content || []
706
- });
707
-
708
- // lib/transform-props.ts
709
- function transformProps(data, propTransforms, config = { components: {} }) {
710
- const mapItem = (item) => {
711
- if (propTransforms[item.type]) {
712
- return __spreadProps(__spreadValues({}, item), {
713
- props: __spreadValues({
714
- id: item.props.id
715
- }, propTransforms[item.type](item.props))
716
- });
717
- }
718
- return item;
719
- };
720
- const defaultedData = defaultData(data);
721
- const rootProps = defaultedData.root.props || defaultedData.root;
722
- let newRoot = __spreadValues({}, defaultedData.root);
723
- if (propTransforms["root"]) {
724
- newRoot.props = propTransforms["root"](rootProps);
725
- }
726
- const dataWithUpdatedRoot = __spreadProps(__spreadValues({}, defaultedData), { root: newRoot });
727
- const updatedData = walkTree(
728
- dataWithUpdatedRoot,
729
- config,
730
- (content) => content.map(mapItem)
731
- );
732
- if (!defaultedData.root.props) {
733
- updatedData.root = updatedData.root.props;
734
- }
735
- return updatedData;
736
- }
737
-
738
- // lib/resolve-all-data.ts
739
- init_react_import();
740
-
741
- // lib/resolve-component-data.ts
742
- init_react_import();
743
-
744
- // lib/get-changed.ts
745
- init_react_import();
746
- import { deepEqual } from "fast-equals";
747
- var getChanged = (newItem, oldItem) => {
748
- return newItem ? Object.keys(newItem.props || {}).reduce((acc, item) => {
749
- const newItemProps = (newItem == null ? void 0 : newItem.props) || {};
750
- const oldItemProps = (oldItem == null ? void 0 : oldItem.props) || {};
751
- return __spreadProps(__spreadValues({}, acc), {
752
- [item]: !deepEqual(oldItemProps[item], newItemProps[item])
753
- });
754
- }, {}) : {};
755
- };
756
-
757
- // lib/resolve-component-data.ts
758
- import { deepEqual as deepEqual2 } from "fast-equals";
759
- var cache = { lastChange: {} };
760
- var resolveComponentData = (_0, _1, ..._2) => __async(null, [_0, _1, ..._2], function* (item, config, metadata = {}, onResolveStart, onResolveEnd, trigger = "replace") {
761
- const configForItem = "type" in item && item.type !== "root" ? config.components[item.type] : config.root;
762
- const resolvedItem = __spreadValues({}, item);
763
- const shouldRunResolver = (configForItem == null ? void 0 : configForItem.resolveData) && item.props;
764
- const id = "id" in item.props ? item.props.id : "root";
765
- if (shouldRunResolver) {
766
- const { item: oldItem = null, resolved = {} } = cache.lastChange[id] || {};
767
- if (trigger !== "force" && item && deepEqual2(item, oldItem)) {
768
- return { node: resolved, didChange: false };
769
- }
770
- const changed = getChanged(item, oldItem);
771
- if (onResolveStart) {
772
- onResolveStart(item);
773
- }
774
- const { props: resolvedProps, readOnly = {} } = yield configForItem.resolveData(item, {
775
- changed,
776
- lastData: oldItem,
777
- metadata: __spreadValues(__spreadValues({}, metadata), configForItem.metadata),
778
- trigger
779
- });
780
- resolvedItem.props = __spreadValues(__spreadValues({}, item.props), resolvedProps);
781
- if (Object.keys(readOnly).length) {
782
- resolvedItem.readOnly = readOnly;
783
- }
784
- }
785
- let itemWithResolvedChildren = yield mapFields(
786
- resolvedItem,
787
- {
788
- slot: (_02) => __async(null, [_02], function* ({ value }) {
789
- const content = value;
790
- return yield Promise.all(
791
- content.map(
792
- (childItem) => __async(null, null, function* () {
793
- return (yield resolveComponentData(
794
- childItem,
795
- config,
796
- metadata,
797
- onResolveStart,
798
- onResolveEnd,
799
- trigger
800
- )).node;
801
- })
802
- )
803
- );
804
- })
805
- },
806
- config
807
- );
808
- if (shouldRunResolver && onResolveEnd) {
809
- onResolveEnd(resolvedItem);
810
- }
811
- cache.lastChange[id] = {
812
- item,
813
- resolved: itemWithResolvedChildren
814
- };
815
- return {
816
- node: itemWithResolvedChildren,
817
- didChange: !deepEqual2(item, itemWithResolvedChildren)
818
- };
819
- });
820
-
821
- // lib/data/to-component.ts
822
- init_react_import();
823
- var toComponent = (item) => {
824
- return "type" in item ? item : __spreadProps(__spreadValues({}, item), {
825
- props: __spreadProps(__spreadValues({}, item.props), { id: "root" }),
826
- type: "root"
827
- });
828
- };
829
-
830
- // lib/resolve-all-data.ts
831
- function resolveAllData(_0, _1) {
832
- return __async(this, arguments, function* (data, config, metadata = {}, onResolveStart, onResolveEnd) {
833
- var _a;
834
- const defaultedData = defaultData(data);
835
- const resolveNode = (_node) => __async(null, null, function* () {
836
- const node = toComponent(_node);
837
- onResolveStart == null ? void 0 : onResolveStart(node);
838
- const resolved = (yield resolveComponentData(
839
- node,
840
- config,
841
- metadata,
842
- () => {
843
- },
844
- () => {
845
- },
846
- "force"
847
- )).node;
848
- const resolvedDeep = yield mapFields(
849
- resolved,
850
- { slot: ({ value }) => processContent(value) },
851
- config
852
- );
853
- onResolveEnd == null ? void 0 : onResolveEnd(toComponent(resolvedDeep));
854
- return resolvedDeep;
855
- });
856
- const processContent = (content) => __async(null, null, function* () {
857
- return Promise.all(content.map(resolveNode));
858
- });
859
- const processZones = () => __async(null, null, function* () {
860
- var _a2;
861
- const zones = (_a2 = data.zones) != null ? _a2 : {};
862
- Object.entries(zones).forEach((_02) => __async(null, [_02], function* ([zoneKey, content]) {
863
- zones[zoneKey] = yield Promise.all(content.map(resolveNode));
864
- }));
865
- return zones;
866
- });
867
- const dynamic = {
868
- root: yield resolveNode(defaultedData.root),
869
- content: yield processContent(defaultedData.content),
870
- zones: yield processZones()
871
- };
872
- Object.keys((_a = defaultedData.zones) != null ? _a : {}).forEach((zoneKey) => __async(null, null, function* () {
873
- const content = defaultedData.zones[zoneKey];
874
- dynamic.zones[zoneKey] = yield processContent(content);
875
- }), {});
876
- return dynamic;
877
- });
878
- }
879
-
880
- // lib/get-class-name-factory.ts
881
- init_react_import();
882
- var import_classnames = __toESM(require_classnames());
883
- var getClassNameFactory = (rootClass, styles, config = { baseClass: "" }) => (options = {}) => {
884
- if (typeof options === "string") {
885
- const descendant = options;
886
- const style = styles[`${rootClass}-${descendant}`];
887
- if (style) {
888
- return config.baseClass + styles[`${rootClass}-${descendant}`] || "";
889
- }
890
- return "";
891
- } else if (typeof options === "object") {
892
- const modifiers = options;
893
- const prefixedModifiers = {};
894
- for (let modifier in modifiers) {
895
- prefixedModifiers[styles[`${rootClass}--${modifier}`]] = modifiers[modifier];
896
- }
897
- const c = styles[rootClass];
898
- return config.baseClass + (0, import_classnames.default)(__spreadValues({
899
- [c]: !!c
900
- }, prefixedModifiers));
901
- } else {
902
- return config.baseClass + styles[rootClass] || "";
903
- }
904
- };
905
- var get_class_name_factory_default = getClassNameFactory;
906
-
907
- // lib/data/setup-zone.ts
908
- init_react_import();
909
- var setupZone = (data, zoneKey) => {
910
- if (zoneKey === rootDroppableId) {
911
- return data;
912
- }
913
- const newData = __spreadProps(__spreadValues({}, data), {
914
- zones: data.zones ? __spreadValues({}, data.zones) : {}
915
- });
916
- newData.zones[zoneKey] = newData.zones[zoneKey] || [];
917
- return newData;
918
- };
919
-
920
- // lib/field-transforms/use-field-transforms.tsx
921
- init_react_import();
922
- import { useMemo } from "react";
923
- function useFieldTransforms(config, item, transforms, readOnly, forceReadOnly) {
924
- const mappers = useMemo(() => {
925
- return Object.keys(transforms).reduce((acc, _fieldType) => {
926
- const fieldType = _fieldType;
927
- return __spreadProps(__spreadValues({}, acc), {
928
- [fieldType]: (_a) => {
929
- var _b = _a, {
930
- parentId
931
- } = _b, params = __objRest(_b, [
932
- "parentId"
933
- ]);
934
- const wildcardPath = params.propPath.replace(/\[\d+\]/g, "[*]");
935
- const isReadOnly = (readOnly == null ? void 0 : readOnly[params.propPath]) || (readOnly == null ? void 0 : readOnly[wildcardPath]) || forceReadOnly || false;
936
- const fn = transforms[fieldType];
937
- return fn == null ? void 0 : fn(__spreadProps(__spreadValues({}, params), {
938
- isReadOnly,
939
- componentId: parentId
940
- }));
941
- }
942
- });
943
- }, {});
944
- }, [transforms, readOnly, forceReadOnly]);
945
- const transformedProps = useMemo(() => {
946
- const mapped = mapFields(item, mappers, config).props;
947
- return mapped;
948
- }, [config, item, mappers]);
949
- const mergedProps = useMemo(
950
- () => __spreadValues(__spreadValues({}, item.props), transformedProps),
951
- [item.props, transformedProps]
952
- );
953
- return mergedProps;
954
- }
955
-
956
- // lib/field-transforms/default-transforms/slot-transform.tsx
957
- init_react_import();
958
- var getSlotTransform = (renderSlotEdit, renderSlotRender = renderSlotEdit) => ({
959
- slot: ({ value: content, propName, field, isReadOnly }) => {
960
- const render = isReadOnly ? renderSlotRender : renderSlotEdit;
961
- const Slot = (dzProps) => render(__spreadProps(__spreadValues({
962
- allow: (field == null ? void 0 : field.type) === "slot" ? field.allow : [],
963
- disallow: (field == null ? void 0 : field.type) === "slot" ? field.disallow : []
964
- }, dzProps), {
965
- zone: propName,
966
- content
967
- }));
968
- return Slot;
969
- }
970
- });
971
-
972
- // lib/use-slots.tsx
973
- init_react_import();
974
- function useSlots(config, item, renderSlotEdit, renderSlotRender = renderSlotEdit, readOnly, forceReadOnly) {
975
- return useFieldTransforms(
976
- config,
977
- item,
978
- getSlotTransform(renderSlotEdit, renderSlotRender),
979
- readOnly,
980
- forceReadOnly
981
- );
982
- }
983
-
984
- // components/RichTextEditor/lib/use-richtext-renderer.tsx
985
- init_react_import();
986
- import { useMemo as useMemo3 } from "react";
987
-
988
- // components/RichTextEditor/Render.tsx
989
- init_react_import();
990
- import { generateHTML, generateJSON } from "@tiptap/html";
991
- import { useMemo as useMemo2 } from "react";
992
-
993
- // css-module:/home/runner/work/puck/puck/packages/core/components/RichTextEditor/styles.module.css#css-module
994
- init_react_import();
995
- var styles_module_default = { "RichTextEditor": "_RichTextEditor_1819a_1", "RichTextEditor--editor": "_RichTextEditor--editor_1819a_46", "RichTextEditor--disabled": "_RichTextEditor--disabled_1819a_95", "RichTextEditor--isActive": "_RichTextEditor--isActive_1819a_99", "RichTextEditor-menu": "_RichTextEditor-menu_1819a_105" };
996
-
997
- // components/RichTextEditor/extensions.ts
998
- init_react_import();
999
- import { Extension } from "@tiptap/core";
1000
- import { Blockquote } from "@tiptap/extension-blockquote";
1001
- import { Bold } from "@tiptap/extension-bold";
1002
- import { Code } from "@tiptap/extension-code";
1003
- import { CodeBlock } from "@tiptap/extension-code-block";
1004
- import { Document } from "@tiptap/extension-document";
1005
- import { HardBreak } from "@tiptap/extension-hard-break";
1006
- import { Heading } from "@tiptap/extension-heading";
1007
- import { HorizontalRule } from "@tiptap/extension-horizontal-rule";
1008
- import { Italic } from "@tiptap/extension-italic";
1009
- import { Link } from "@tiptap/extension-link";
1010
- import {
1011
- BulletList,
1012
- ListItem,
1013
- ListKeymap,
1014
- OrderedList
1015
- } from "@tiptap/extension-list";
1016
- import { Paragraph } from "@tiptap/extension-paragraph";
1017
- import { Strike } from "@tiptap/extension-strike";
1018
- import { Text } from "@tiptap/extension-text";
1019
- import TextAlign from "@tiptap/extension-text-align";
1020
- import { Underline } from "@tiptap/extension-underline";
1021
- var defaultPuckRichTextOptions = {
1022
- textAlign: {
1023
- types: ["heading", "paragraph"]
1024
- }
1025
- };
1026
- var PuckRichText = Extension.create({
1027
- name: "puckRichText",
1028
- addExtensions() {
1029
- const extensions = [];
1030
- const options = __spreadValues(__spreadValues({}, this.options), defaultPuckRichTextOptions);
1031
- if (options.bold !== false) {
1032
- extensions.push(Bold.configure(options.bold));
1033
- }
1034
- if (options.blockquote !== false) {
1035
- extensions.push(Blockquote.configure(options.blockquote));
1036
- }
1037
- if (options.bulletList !== false) {
1038
- extensions.push(BulletList.configure(options.bulletList));
1039
- }
1040
- if (options.code !== false) {
1041
- extensions.push(Code.configure(options.code));
1042
- }
1043
- if (options.codeBlock !== false) {
1044
- extensions.push(CodeBlock.configure(options.codeBlock));
1045
- }
1046
- if (options.document !== false) {
1047
- extensions.push(Document.configure(options.document));
1048
- }
1049
- if (options.hardBreak !== false) {
1050
- extensions.push(HardBreak.configure(options.hardBreak));
1051
- }
1052
- if (options.heading !== false) {
1053
- extensions.push(Heading.configure(options.heading));
1054
- }
1055
- if (options.horizontalRule !== false) {
1056
- extensions.push(HorizontalRule.configure(options.horizontalRule));
1057
- }
1058
- if (options.italic !== false) {
1059
- extensions.push(Italic.configure(options.italic));
1060
- }
1061
- if (options.listItem !== false) {
1062
- extensions.push(ListItem.configure(options.listItem));
1063
- }
1064
- if (options.listKeymap !== false) {
1065
- extensions.push(ListKeymap.configure(options == null ? void 0 : options.listKeymap));
1066
- }
1067
- if (options.link !== false) {
1068
- extensions.push(Link.configure(options == null ? void 0 : options.link));
1069
- }
1070
- if (options.orderedList !== false) {
1071
- extensions.push(OrderedList.configure(options.orderedList));
1072
- }
1073
- if (options.paragraph !== false) {
1074
- extensions.push(Paragraph.configure(options.paragraph));
1075
- }
1076
- if (options.strike !== false) {
1077
- extensions.push(Strike.configure(options.strike));
1078
- }
1079
- if (options.text !== false) {
1080
- extensions.push(Text.configure(options.text));
1081
- }
1082
- if (options.textAlign !== false) {
1083
- extensions.push(TextAlign.configure(options.textAlign));
1084
- }
1085
- if (options.underline !== false) {
1086
- extensions.push(Underline.configure(options == null ? void 0 : options.underline));
1087
- }
1088
- return extensions;
1089
- }
1090
- });
1091
-
1092
- // components/RichTextEditor/Render.tsx
1093
- import { jsx } from "react/jsx-runtime";
1094
- var getClassName = get_class_name_factory_default("RichTextEditor", styles_module_default);
1095
- function RichTextRender({
1096
- content,
1097
- field
1098
- }) {
1099
- const { tiptap = {}, options } = field;
1100
- const { extensions = [] } = tiptap;
1101
- const loadedExtensions = useMemo2(
1102
- () => [PuckRichText.configure(options), ...extensions],
1103
- [field, extensions]
1104
- );
1105
- const normalized = useMemo2(() => {
1106
- if (typeof content === "object" && (content == null ? void 0 : content.type) === "doc") {
1107
- return content;
1108
- }
1109
- if (typeof content === "string") {
1110
- const isHtml = /<\/?[a-z][\s\S]*>/i.test(content);
1111
- if (isHtml) {
1112
- return generateJSON(content, loadedExtensions);
1113
- }
1114
- return {
1115
- type: "doc",
1116
- content: [
1117
- { type: "paragraph", content: [{ type: "text", text: content }] }
1118
- ]
1119
- };
1120
- }
1121
- return { type: "doc", content: [] };
1122
- }, [content, loadedExtensions]);
1123
- const html = useMemo2(() => {
1124
- return generateHTML(normalized, loadedExtensions);
1125
- }, [normalized, loadedExtensions]);
1126
- return /* @__PURE__ */ jsx("div", { className: getClassName(), children: /* @__PURE__ */ jsx("div", { className: "rich-text", dangerouslySetInnerHTML: { __html: html } }) });
1127
- }
1128
-
1129
- // components/RichTextEditor/lib/use-richtext-renderer.tsx
1130
- import { jsx as jsx2 } from "react/jsx-runtime";
1131
- function useRichtextRenderer(fields, props) {
1132
- const findAllRichtextKeys = (fields2) => {
1133
- if (!fields2) return [];
1134
- const result = [];
1135
- for (const [key, field] of Object.entries(fields2)) {
1136
- if (field.type === "richtext") {
1137
- result.push(key);
1138
- }
1139
- }
1140
- return result;
1141
- };
1142
- const richtextKeys = useMemo3(() => findAllRichtextKeys(fields), [fields]);
1143
- const richTextRenderer = useMemo3(() => {
1144
- if (!richtextKeys) return {};
1145
- return richtextKeys.reduce((acc, key) => {
1146
- acc[key] = /* @__PURE__ */ jsx2(
1147
- RichTextRender,
1148
- {
1149
- content: props[key],
1150
- field: fields[key]
1151
- }
1152
- );
1153
- return acc;
1154
- }, {});
1155
- }, [richtextKeys, props]);
1156
- return richTextRenderer;
1157
- }
1158
-
1159
- // components/SlotRender/server.tsx
1160
- init_react_import();
1161
- import { forwardRef } from "react";
1162
- import { jsx as jsx3 } from "react/jsx-runtime";
1163
- var SlotRenderPure = (props) => /* @__PURE__ */ jsx3(SlotRender, __spreadValues({}, props));
1164
- var Item = ({
1165
- config,
1166
- item,
1167
- metadata
1168
- }) => {
1169
- const Component = config.components[item.type];
1170
- const props = useSlots(config, item, (slotProps) => /* @__PURE__ */ jsx3(SlotRenderPure, __spreadProps(__spreadValues({}, slotProps), { config, metadata })));
1171
- const richTextRenderer = useRichtextRenderer(Component.fields, props);
1172
- return /* @__PURE__ */ jsx3(
1173
- Component.render,
1174
- __spreadProps(__spreadValues(__spreadValues({}, props), richTextRenderer), {
1175
- puck: __spreadProps(__spreadValues({}, props.puck), {
1176
- metadata: metadata || {}
1177
- })
1178
- })
1179
- );
1180
- };
1181
- var SlotRender = forwardRef(
1182
- function SlotRenderInternal({ className, style, content, config, metadata, as }, ref) {
1183
- const El = as != null ? as : "div";
1184
- return /* @__PURE__ */ jsx3(El, { className, style, ref, children: content.map((item) => {
1185
- if (!config.components[item.type]) {
1186
- return null;
1187
- }
1188
- return /* @__PURE__ */ jsx3(
1189
- Item,
1190
- {
1191
- config,
1192
- item,
1193
- metadata
1194
- },
1195
- item.props.id
1196
- );
1197
- }) });
1198
- }
1199
- );
1200
-
1201
- export {
1202
- __spreadValues,
1203
- __spreadProps,
1204
- __objRest,
1205
- __commonJS,
1206
- __toESM,
1207
- __async,
1208
- init_react_import,
1209
- get_class_name_factory_default,
1210
- rootAreaId,
1211
- rootZone,
1212
- rootDroppableId,
1213
- defaultSlots,
1214
- walkField,
1215
- expandNode,
1216
- walkAppState,
1217
- walkTree,
1218
- setupZone,
1219
- defaultViewports,
1220
- getChanged,
1221
- resolveComponentData,
1222
- defaultAppState,
1223
- PuckRichText,
1224
- styles_module_default,
1225
- useFieldTransforms,
1226
- getSlotTransform,
1227
- useSlots,
1228
- RichTextRender,
1229
- useRichtextRenderer,
1230
- SlotRenderPure,
1231
- SlotRender,
1232
- toComponent,
1233
- migrate,
1234
- transformProps,
1235
- resolveAllData
1236
- };
1237
- /*! Bundled license information:
1238
-
1239
- classnames/index.js:
1240
- (*!
1241
- Copyright (c) 2018 Jed Watson.
1242
- Licensed under the MIT License (MIT), see
1243
- http://jedwatson.github.io/classnames
1244
- *)
1245
- */