@measured/puck-plugin-heading-analyzer 0.19.0-canary.de23f9d → 0.19.0-canary.e62832e

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.d.mts CHANGED
@@ -12,6 +12,7 @@ type FieldOption = {
12
12
  type FieldOptions = Array<FieldOption> | ReadonlyArray<FieldOption>;
13
13
  type BaseField = {
14
14
  label?: string;
15
+ labelIcon?: ReactElement;
15
16
  };
16
17
  type TextField = BaseField & {
17
18
  type: "text";
package/dist/index.d.ts CHANGED
@@ -12,6 +12,7 @@ type FieldOption = {
12
12
  type FieldOptions = Array<FieldOption> | ReadonlyArray<FieldOption>;
13
13
  type BaseField = {
14
14
  label?: string;
15
+ labelIcon?: ReactElement;
15
16
  };
16
17
  type TextField = BaseField & {
17
18
  type: "text";
package/dist/index.js CHANGED
@@ -153,6 +153,289 @@ var require_classnames = __commonJS({
153
153
  }
154
154
  });
155
155
 
156
+ // ../../node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.production.js
157
+ var require_use_sync_external_store_shim_production = __commonJS({
158
+ "../../node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.production.js"(exports2) {
159
+ "use strict";
160
+ init_react_import();
161
+ var React2 = require("react");
162
+ function is(x, y) {
163
+ return x === y && (0 !== x || 1 / x === 1 / y) || x !== x && y !== y;
164
+ }
165
+ var objectIs = "function" === typeof Object.is ? Object.is : is;
166
+ var useState2 = React2.useState;
167
+ var useEffect7 = React2.useEffect;
168
+ var useLayoutEffect = React2.useLayoutEffect;
169
+ var useDebugValue2 = React2.useDebugValue;
170
+ function useSyncExternalStore$2(subscribe, getSnapshot) {
171
+ var value = getSnapshot(), _useState = useState2({ inst: { value, getSnapshot } }), inst = _useState[0].inst, forceUpdate = _useState[1];
172
+ useLayoutEffect(
173
+ function() {
174
+ inst.value = value;
175
+ inst.getSnapshot = getSnapshot;
176
+ checkIfSnapshotChanged(inst) && forceUpdate({ inst });
177
+ },
178
+ [subscribe, value, getSnapshot]
179
+ );
180
+ useEffect7(
181
+ function() {
182
+ checkIfSnapshotChanged(inst) && forceUpdate({ inst });
183
+ return subscribe(function() {
184
+ checkIfSnapshotChanged(inst) && forceUpdate({ inst });
185
+ });
186
+ },
187
+ [subscribe]
188
+ );
189
+ useDebugValue2(value);
190
+ return value;
191
+ }
192
+ function checkIfSnapshotChanged(inst) {
193
+ var latestGetSnapshot = inst.getSnapshot;
194
+ inst = inst.value;
195
+ try {
196
+ var nextValue = latestGetSnapshot();
197
+ return !objectIs(inst, nextValue);
198
+ } catch (error) {
199
+ return true;
200
+ }
201
+ }
202
+ function useSyncExternalStore$1(subscribe, getSnapshot) {
203
+ return getSnapshot();
204
+ }
205
+ var shim = "undefined" === typeof window || "undefined" === typeof window.document || "undefined" === typeof window.document.createElement ? useSyncExternalStore$1 : useSyncExternalStore$2;
206
+ exports2.useSyncExternalStore = void 0 !== React2.useSyncExternalStore ? React2.useSyncExternalStore : shim;
207
+ }
208
+ });
209
+
210
+ // ../../node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.development.js
211
+ var require_use_sync_external_store_shim_development = __commonJS({
212
+ "../../node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.development.js"(exports2) {
213
+ "use strict";
214
+ init_react_import();
215
+ "production" !== process.env.NODE_ENV && function() {
216
+ function is(x, y) {
217
+ return x === y && (0 !== x || 1 / x === 1 / y) || x !== x && y !== y;
218
+ }
219
+ function useSyncExternalStore$2(subscribe, getSnapshot) {
220
+ didWarnOld18Alpha || void 0 === React2.startTransition || (didWarnOld18Alpha = true, console.error(
221
+ "You are using an outdated, pre-release alpha of React 18 that does not support useSyncExternalStore. The use-sync-external-store shim will not work correctly. Upgrade to a newer pre-release."
222
+ ));
223
+ var value = getSnapshot();
224
+ if (!didWarnUncachedGetSnapshot) {
225
+ var cachedValue = getSnapshot();
226
+ objectIs(value, cachedValue) || (console.error(
227
+ "The result of getSnapshot should be cached to avoid an infinite loop"
228
+ ), didWarnUncachedGetSnapshot = true);
229
+ }
230
+ cachedValue = useState2({
231
+ inst: { value, getSnapshot }
232
+ });
233
+ var inst = cachedValue[0].inst, forceUpdate = cachedValue[1];
234
+ useLayoutEffect(
235
+ function() {
236
+ inst.value = value;
237
+ inst.getSnapshot = getSnapshot;
238
+ checkIfSnapshotChanged(inst) && forceUpdate({ inst });
239
+ },
240
+ [subscribe, value, getSnapshot]
241
+ );
242
+ useEffect7(
243
+ function() {
244
+ checkIfSnapshotChanged(inst) && forceUpdate({ inst });
245
+ return subscribe(function() {
246
+ checkIfSnapshotChanged(inst) && forceUpdate({ inst });
247
+ });
248
+ },
249
+ [subscribe]
250
+ );
251
+ useDebugValue2(value);
252
+ return value;
253
+ }
254
+ function checkIfSnapshotChanged(inst) {
255
+ var latestGetSnapshot = inst.getSnapshot;
256
+ inst = inst.value;
257
+ try {
258
+ var nextValue = latestGetSnapshot();
259
+ return !objectIs(inst, nextValue);
260
+ } catch (error) {
261
+ return true;
262
+ }
263
+ }
264
+ function useSyncExternalStore$1(subscribe, getSnapshot) {
265
+ return getSnapshot();
266
+ }
267
+ "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());
268
+ var React2 = require("react"), objectIs = "function" === typeof Object.is ? Object.is : is, useState2 = React2.useState, useEffect7 = React2.useEffect, useLayoutEffect = React2.useLayoutEffect, useDebugValue2 = React2.useDebugValue, didWarnOld18Alpha = false, didWarnUncachedGetSnapshot = false, shim = "undefined" === typeof window || "undefined" === typeof window.document || "undefined" === typeof window.document.createElement ? useSyncExternalStore$1 : useSyncExternalStore$2;
269
+ exports2.useSyncExternalStore = void 0 !== React2.useSyncExternalStore ? React2.useSyncExternalStore : shim;
270
+ "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error());
271
+ }();
272
+ }
273
+ });
274
+
275
+ // ../../node_modules/use-sync-external-store/shim/index.js
276
+ var require_shim = __commonJS({
277
+ "../../node_modules/use-sync-external-store/shim/index.js"(exports2, module2) {
278
+ "use strict";
279
+ init_react_import();
280
+ if (process.env.NODE_ENV === "production") {
281
+ module2.exports = require_use_sync_external_store_shim_production();
282
+ } else {
283
+ module2.exports = require_use_sync_external_store_shim_development();
284
+ }
285
+ }
286
+ });
287
+
288
+ // ../../node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.production.js
289
+ var require_with_selector_production = __commonJS({
290
+ "../../node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.production.js"(exports2) {
291
+ "use strict";
292
+ init_react_import();
293
+ var React2 = require("react");
294
+ var shim = require_shim();
295
+ function is(x, y) {
296
+ return x === y && (0 !== x || 1 / x === 1 / y) || x !== x && y !== y;
297
+ }
298
+ var objectIs = "function" === typeof Object.is ? Object.is : is;
299
+ var useSyncExternalStore = shim.useSyncExternalStore;
300
+ var useRef = React2.useRef;
301
+ var useEffect7 = React2.useEffect;
302
+ var useMemo2 = React2.useMemo;
303
+ var useDebugValue2 = React2.useDebugValue;
304
+ exports2.useSyncExternalStoreWithSelector = function(subscribe, getSnapshot, getServerSnapshot, selector, isEqual) {
305
+ var instRef = useRef(null);
306
+ if (null === instRef.current) {
307
+ var inst = { hasValue: false, value: null };
308
+ instRef.current = inst;
309
+ } else inst = instRef.current;
310
+ instRef = useMemo2(
311
+ function() {
312
+ function memoizedSelector(nextSnapshot) {
313
+ if (!hasMemo) {
314
+ hasMemo = true;
315
+ memoizedSnapshot = nextSnapshot;
316
+ nextSnapshot = selector(nextSnapshot);
317
+ if (void 0 !== isEqual && inst.hasValue) {
318
+ var currentSelection = inst.value;
319
+ if (isEqual(currentSelection, nextSnapshot))
320
+ return memoizedSelection = currentSelection;
321
+ }
322
+ return memoizedSelection = nextSnapshot;
323
+ }
324
+ currentSelection = memoizedSelection;
325
+ if (objectIs(memoizedSnapshot, nextSnapshot)) return currentSelection;
326
+ var nextSelection = selector(nextSnapshot);
327
+ if (void 0 !== isEqual && isEqual(currentSelection, nextSelection))
328
+ return memoizedSnapshot = nextSnapshot, currentSelection;
329
+ memoizedSnapshot = nextSnapshot;
330
+ return memoizedSelection = nextSelection;
331
+ }
332
+ var hasMemo = false, memoizedSnapshot, memoizedSelection, maybeGetServerSnapshot = void 0 === getServerSnapshot ? null : getServerSnapshot;
333
+ return [
334
+ function() {
335
+ return memoizedSelector(getSnapshot());
336
+ },
337
+ null === maybeGetServerSnapshot ? void 0 : function() {
338
+ return memoizedSelector(maybeGetServerSnapshot());
339
+ }
340
+ ];
341
+ },
342
+ [getSnapshot, getServerSnapshot, selector, isEqual]
343
+ );
344
+ var value = useSyncExternalStore(subscribe, instRef[0], instRef[1]);
345
+ useEffect7(
346
+ function() {
347
+ inst.hasValue = true;
348
+ inst.value = value;
349
+ },
350
+ [value]
351
+ );
352
+ useDebugValue2(value);
353
+ return value;
354
+ };
355
+ }
356
+ });
357
+
358
+ // ../../node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.development.js
359
+ var require_with_selector_development = __commonJS({
360
+ "../../node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.development.js"(exports2) {
361
+ "use strict";
362
+ init_react_import();
363
+ "production" !== process.env.NODE_ENV && function() {
364
+ function is(x, y) {
365
+ return x === y && (0 !== x || 1 / x === 1 / y) || x !== x && y !== y;
366
+ }
367
+ "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());
368
+ var React2 = require("react"), shim = require_shim(), objectIs = "function" === typeof Object.is ? Object.is : is, useSyncExternalStore = shim.useSyncExternalStore, useRef = React2.useRef, useEffect7 = React2.useEffect, useMemo2 = React2.useMemo, useDebugValue2 = React2.useDebugValue;
369
+ exports2.useSyncExternalStoreWithSelector = function(subscribe, getSnapshot, getServerSnapshot, selector, isEqual) {
370
+ var instRef = useRef(null);
371
+ if (null === instRef.current) {
372
+ var inst = { hasValue: false, value: null };
373
+ instRef.current = inst;
374
+ } else inst = instRef.current;
375
+ instRef = useMemo2(
376
+ function() {
377
+ function memoizedSelector(nextSnapshot) {
378
+ if (!hasMemo) {
379
+ hasMemo = true;
380
+ memoizedSnapshot = nextSnapshot;
381
+ nextSnapshot = selector(nextSnapshot);
382
+ if (void 0 !== isEqual && inst.hasValue) {
383
+ var currentSelection = inst.value;
384
+ if (isEqual(currentSelection, nextSnapshot))
385
+ return memoizedSelection = currentSelection;
386
+ }
387
+ return memoizedSelection = nextSnapshot;
388
+ }
389
+ currentSelection = memoizedSelection;
390
+ if (objectIs(memoizedSnapshot, nextSnapshot))
391
+ return currentSelection;
392
+ var nextSelection = selector(nextSnapshot);
393
+ if (void 0 !== isEqual && isEqual(currentSelection, nextSelection))
394
+ return memoizedSnapshot = nextSnapshot, currentSelection;
395
+ memoizedSnapshot = nextSnapshot;
396
+ return memoizedSelection = nextSelection;
397
+ }
398
+ var hasMemo = false, memoizedSnapshot, memoizedSelection, maybeGetServerSnapshot = void 0 === getServerSnapshot ? null : getServerSnapshot;
399
+ return [
400
+ function() {
401
+ return memoizedSelector(getSnapshot());
402
+ },
403
+ null === maybeGetServerSnapshot ? void 0 : function() {
404
+ return memoizedSelector(maybeGetServerSnapshot());
405
+ }
406
+ ];
407
+ },
408
+ [getSnapshot, getServerSnapshot, selector, isEqual]
409
+ );
410
+ var value = useSyncExternalStore(subscribe, instRef[0], instRef[1]);
411
+ useEffect7(
412
+ function() {
413
+ inst.hasValue = true;
414
+ inst.value = value;
415
+ },
416
+ [value]
417
+ );
418
+ useDebugValue2(value);
419
+ return value;
420
+ };
421
+ "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error());
422
+ }();
423
+ }
424
+ });
425
+
426
+ // ../../node_modules/use-sync-external-store/shim/with-selector.js
427
+ var require_with_selector = __commonJS({
428
+ "../../node_modules/use-sync-external-store/shim/with-selector.js"(exports2, module2) {
429
+ "use strict";
430
+ init_react_import();
431
+ if (process.env.NODE_ENV === "production") {
432
+ module2.exports = require_with_selector_production();
433
+ } else {
434
+ module2.exports = require_with_selector_development();
435
+ }
436
+ }
437
+ });
438
+
156
439
  // ../../node_modules/fast-deep-equal/index.js
157
440
  var require_fast_deep_equal = __commonJS({
158
441
  "../../node_modules/fast-deep-equal/index.js"(exports2, module2) {
@@ -863,8 +1146,12 @@ var defaultViewports = [
863
1146
  { width: 1280, height: "auto", icon: "Monitor", label: "Large" }
864
1147
  ];
865
1148
 
1149
+ // ../../node_modules/zustand/esm/index.mjs
1150
+ init_react_import();
1151
+
866
1152
  // ../../node_modules/zustand/esm/vanilla.mjs
867
1153
  init_react_import();
1154
+ var import_meta = {};
868
1155
  var createStoreImpl = (createState) => {
869
1156
  let state;
870
1157
  const listeners = /* @__PURE__ */ new Set();
@@ -882,28 +1169,53 @@ var createStoreImpl = (createState) => {
882
1169
  listeners.add(listener);
883
1170
  return () => listeners.delete(listener);
884
1171
  };
885
- const api = { setState, getState, getInitialState, subscribe };
1172
+ const destroy = () => {
1173
+ if ((import_meta.env ? import_meta.env.MODE : void 0) !== "production") {
1174
+ console.warn(
1175
+ "[DEPRECATED] The `destroy` method will be unsupported in a future version. Instead use unsubscribe function returned by subscribe. Everything will be garbage-collected if store is garbage-collected."
1176
+ );
1177
+ }
1178
+ listeners.clear();
1179
+ };
1180
+ const api = { setState, getState, getInitialState, subscribe, destroy };
886
1181
  const initialState = state = createState(setState, getState, api);
887
1182
  return api;
888
1183
  };
889
1184
  var createStore = (createState) => createState ? createStoreImpl(createState) : createStoreImpl;
890
1185
 
891
- // ../../node_modules/zustand/esm/react.mjs
892
- init_react_import();
1186
+ // ../../node_modules/zustand/esm/index.mjs
893
1187
  var import_react4 = __toESM(require("react"), 1);
1188
+ var import_with_selector = __toESM(require_with_selector(), 1);
1189
+ var import_meta2 = {};
1190
+ var { useDebugValue } = import_react4.default;
1191
+ var { useSyncExternalStoreWithSelector } = import_with_selector.default;
1192
+ var didWarnAboutEqualityFn = false;
894
1193
  var identity = (arg) => arg;
895
- function useStore(api, selector = identity) {
896
- const slice = import_react4.default.useSyncExternalStore(
1194
+ function useStore(api, selector = identity, equalityFn) {
1195
+ if ((import_meta2.env ? import_meta2.env.MODE : void 0) !== "production" && equalityFn && !didWarnAboutEqualityFn) {
1196
+ console.warn(
1197
+ "[DEPRECATED] Use `createWithEqualityFn` instead of `create` or use `useStoreWithEqualityFn` instead of `useStore`. They can be imported from 'zustand/traditional'. https://github.com/pmndrs/zustand/discussions/1937"
1198
+ );
1199
+ didWarnAboutEqualityFn = true;
1200
+ }
1201
+ const slice = useSyncExternalStoreWithSelector(
897
1202
  api.subscribe,
898
- () => selector(api.getState()),
899
- () => selector(api.getInitialState())
1203
+ api.getState,
1204
+ api.getServerState || api.getInitialState,
1205
+ selector,
1206
+ equalityFn
900
1207
  );
901
- import_react4.default.useDebugValue(slice);
1208
+ useDebugValue(slice);
902
1209
  return slice;
903
1210
  }
904
1211
  var createImpl = (createState) => {
905
- const api = createStore(createState);
906
- const useBoundStore = (selector) => useStore(api, selector);
1212
+ if ((import_meta2.env ? import_meta2.env.MODE : void 0) !== "production" && typeof createState !== "function") {
1213
+ console.warn(
1214
+ "[DEPRECATED] Passing a vanilla store will be unsupported in a future version. Instead use `import { useStore } from 'zustand'`."
1215
+ );
1216
+ }
1217
+ const api = typeof createState === "function" ? createStore(createState) : createState;
1218
+ const useBoundStore = (selector, equalityFn) => useStore(api, selector, equalityFn);
907
1219
  Object.assign(useBoundStore, api);
908
1220
  return useBoundStore;
909
1221
  };
@@ -1885,6 +2197,50 @@ classnames/index.js:
1885
2197
  http://jedwatson.github.io/classnames
1886
2198
  *)
1887
2199
 
2200
+ use-sync-external-store/cjs/use-sync-external-store-shim.production.js:
2201
+ (**
2202
+ * @license React
2203
+ * use-sync-external-store-shim.production.js
2204
+ *
2205
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
2206
+ *
2207
+ * This source code is licensed under the MIT license found in the
2208
+ * LICENSE file in the root directory of this source tree.
2209
+ *)
2210
+
2211
+ use-sync-external-store/cjs/use-sync-external-store-shim.development.js:
2212
+ (**
2213
+ * @license React
2214
+ * use-sync-external-store-shim.development.js
2215
+ *
2216
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
2217
+ *
2218
+ * This source code is licensed under the MIT license found in the
2219
+ * LICENSE file in the root directory of this source tree.
2220
+ *)
2221
+
2222
+ use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.production.js:
2223
+ (**
2224
+ * @license React
2225
+ * use-sync-external-store-shim/with-selector.production.js
2226
+ *
2227
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
2228
+ *
2229
+ * This source code is licensed under the MIT license found in the
2230
+ * LICENSE file in the root directory of this source tree.
2231
+ *)
2232
+
2233
+ use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.development.js:
2234
+ (**
2235
+ * @license React
2236
+ * use-sync-external-store-shim/with-selector.development.js
2237
+ *
2238
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
2239
+ *
2240
+ * This source code is licensed under the MIT license found in the
2241
+ * LICENSE file in the root directory of this source tree.
2242
+ *)
2243
+
1888
2244
  lucide-react/dist/esm/shared/src/utils.js:
1889
2245
  (**
1890
2246
  * @license lucide-react v0.468.0 - ISC
package/dist/index.mjs CHANGED
@@ -21,6 +21,12 @@ var __spreadValues = (a, b) => {
21
21
  return a;
22
22
  };
23
23
  var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
24
+ var __require = /* @__PURE__ */ ((x) => typeof require !== "undefined" ? require : typeof Proxy !== "undefined" ? new Proxy(x, {
25
+ get: (a, b) => (typeof require !== "undefined" ? require : a)[b]
26
+ }) : x)(function(x) {
27
+ if (typeof require !== "undefined") return require.apply(this, arguments);
28
+ throw Error('Dynamic require of "' + x + '" is not supported');
29
+ });
24
30
  var __objRest = (source, exclude) => {
25
31
  var target = {};
26
32
  for (var prop in source)
@@ -36,7 +42,7 @@ var __objRest = (source, exclude) => {
36
42
  var __esm = (fn, res) => function __init() {
37
43
  return fn && (res = (0, fn[__getOwnPropNames(fn)[0]])(fn = 0)), res;
38
44
  };
39
- var __commonJS = (cb, mod) => function __require() {
45
+ var __commonJS = (cb, mod) => function __require2() {
40
46
  return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
41
47
  };
42
48
  var __copyProps = (to, from, except, desc) => {
@@ -146,6 +152,289 @@ var require_classnames = __commonJS({
146
152
  }
147
153
  });
148
154
 
155
+ // ../../node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.production.js
156
+ var require_use_sync_external_store_shim_production = __commonJS({
157
+ "../../node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.production.js"(exports) {
158
+ "use strict";
159
+ init_react_import();
160
+ var React2 = __require("react");
161
+ function is(x, y) {
162
+ return x === y && (0 !== x || 1 / x === 1 / y) || x !== x && y !== y;
163
+ }
164
+ var objectIs = "function" === typeof Object.is ? Object.is : is;
165
+ var useState2 = React2.useState;
166
+ var useEffect7 = React2.useEffect;
167
+ var useLayoutEffect = React2.useLayoutEffect;
168
+ var useDebugValue2 = React2.useDebugValue;
169
+ function useSyncExternalStore$2(subscribe, getSnapshot) {
170
+ var value = getSnapshot(), _useState = useState2({ inst: { value, getSnapshot } }), inst = _useState[0].inst, forceUpdate = _useState[1];
171
+ useLayoutEffect(
172
+ function() {
173
+ inst.value = value;
174
+ inst.getSnapshot = getSnapshot;
175
+ checkIfSnapshotChanged(inst) && forceUpdate({ inst });
176
+ },
177
+ [subscribe, value, getSnapshot]
178
+ );
179
+ useEffect7(
180
+ function() {
181
+ checkIfSnapshotChanged(inst) && forceUpdate({ inst });
182
+ return subscribe(function() {
183
+ checkIfSnapshotChanged(inst) && forceUpdate({ inst });
184
+ });
185
+ },
186
+ [subscribe]
187
+ );
188
+ useDebugValue2(value);
189
+ return value;
190
+ }
191
+ function checkIfSnapshotChanged(inst) {
192
+ var latestGetSnapshot = inst.getSnapshot;
193
+ inst = inst.value;
194
+ try {
195
+ var nextValue = latestGetSnapshot();
196
+ return !objectIs(inst, nextValue);
197
+ } catch (error) {
198
+ return true;
199
+ }
200
+ }
201
+ function useSyncExternalStore$1(subscribe, getSnapshot) {
202
+ return getSnapshot();
203
+ }
204
+ var shim = "undefined" === typeof window || "undefined" === typeof window.document || "undefined" === typeof window.document.createElement ? useSyncExternalStore$1 : useSyncExternalStore$2;
205
+ exports.useSyncExternalStore = void 0 !== React2.useSyncExternalStore ? React2.useSyncExternalStore : shim;
206
+ }
207
+ });
208
+
209
+ // ../../node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.development.js
210
+ var require_use_sync_external_store_shim_development = __commonJS({
211
+ "../../node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.development.js"(exports) {
212
+ "use strict";
213
+ init_react_import();
214
+ "production" !== process.env.NODE_ENV && function() {
215
+ function is(x, y) {
216
+ return x === y && (0 !== x || 1 / x === 1 / y) || x !== x && y !== y;
217
+ }
218
+ function useSyncExternalStore$2(subscribe, getSnapshot) {
219
+ didWarnOld18Alpha || void 0 === React2.startTransition || (didWarnOld18Alpha = true, console.error(
220
+ "You are using an outdated, pre-release alpha of React 18 that does not support useSyncExternalStore. The use-sync-external-store shim will not work correctly. Upgrade to a newer pre-release."
221
+ ));
222
+ var value = getSnapshot();
223
+ if (!didWarnUncachedGetSnapshot) {
224
+ var cachedValue = getSnapshot();
225
+ objectIs(value, cachedValue) || (console.error(
226
+ "The result of getSnapshot should be cached to avoid an infinite loop"
227
+ ), didWarnUncachedGetSnapshot = true);
228
+ }
229
+ cachedValue = useState2({
230
+ inst: { value, getSnapshot }
231
+ });
232
+ var inst = cachedValue[0].inst, forceUpdate = cachedValue[1];
233
+ useLayoutEffect(
234
+ function() {
235
+ inst.value = value;
236
+ inst.getSnapshot = getSnapshot;
237
+ checkIfSnapshotChanged(inst) && forceUpdate({ inst });
238
+ },
239
+ [subscribe, value, getSnapshot]
240
+ );
241
+ useEffect7(
242
+ function() {
243
+ checkIfSnapshotChanged(inst) && forceUpdate({ inst });
244
+ return subscribe(function() {
245
+ checkIfSnapshotChanged(inst) && forceUpdate({ inst });
246
+ });
247
+ },
248
+ [subscribe]
249
+ );
250
+ useDebugValue2(value);
251
+ return value;
252
+ }
253
+ function checkIfSnapshotChanged(inst) {
254
+ var latestGetSnapshot = inst.getSnapshot;
255
+ inst = inst.value;
256
+ try {
257
+ var nextValue = latestGetSnapshot();
258
+ return !objectIs(inst, nextValue);
259
+ } catch (error) {
260
+ return true;
261
+ }
262
+ }
263
+ function useSyncExternalStore$1(subscribe, getSnapshot) {
264
+ return getSnapshot();
265
+ }
266
+ "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());
267
+ var React2 = __require("react"), objectIs = "function" === typeof Object.is ? Object.is : is, useState2 = React2.useState, useEffect7 = React2.useEffect, useLayoutEffect = React2.useLayoutEffect, useDebugValue2 = React2.useDebugValue, didWarnOld18Alpha = false, didWarnUncachedGetSnapshot = false, shim = "undefined" === typeof window || "undefined" === typeof window.document || "undefined" === typeof window.document.createElement ? useSyncExternalStore$1 : useSyncExternalStore$2;
268
+ exports.useSyncExternalStore = void 0 !== React2.useSyncExternalStore ? React2.useSyncExternalStore : shim;
269
+ "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error());
270
+ }();
271
+ }
272
+ });
273
+
274
+ // ../../node_modules/use-sync-external-store/shim/index.js
275
+ var require_shim = __commonJS({
276
+ "../../node_modules/use-sync-external-store/shim/index.js"(exports, module) {
277
+ "use strict";
278
+ init_react_import();
279
+ if (process.env.NODE_ENV === "production") {
280
+ module.exports = require_use_sync_external_store_shim_production();
281
+ } else {
282
+ module.exports = require_use_sync_external_store_shim_development();
283
+ }
284
+ }
285
+ });
286
+
287
+ // ../../node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.production.js
288
+ var require_with_selector_production = __commonJS({
289
+ "../../node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.production.js"(exports) {
290
+ "use strict";
291
+ init_react_import();
292
+ var React2 = __require("react");
293
+ var shim = require_shim();
294
+ function is(x, y) {
295
+ return x === y && (0 !== x || 1 / x === 1 / y) || x !== x && y !== y;
296
+ }
297
+ var objectIs = "function" === typeof Object.is ? Object.is : is;
298
+ var useSyncExternalStore = shim.useSyncExternalStore;
299
+ var useRef = React2.useRef;
300
+ var useEffect7 = React2.useEffect;
301
+ var useMemo2 = React2.useMemo;
302
+ var useDebugValue2 = React2.useDebugValue;
303
+ exports.useSyncExternalStoreWithSelector = function(subscribe, getSnapshot, getServerSnapshot, selector, isEqual) {
304
+ var instRef = useRef(null);
305
+ if (null === instRef.current) {
306
+ var inst = { hasValue: false, value: null };
307
+ instRef.current = inst;
308
+ } else inst = instRef.current;
309
+ instRef = useMemo2(
310
+ function() {
311
+ function memoizedSelector(nextSnapshot) {
312
+ if (!hasMemo) {
313
+ hasMemo = true;
314
+ memoizedSnapshot = nextSnapshot;
315
+ nextSnapshot = selector(nextSnapshot);
316
+ if (void 0 !== isEqual && inst.hasValue) {
317
+ var currentSelection = inst.value;
318
+ if (isEqual(currentSelection, nextSnapshot))
319
+ return memoizedSelection = currentSelection;
320
+ }
321
+ return memoizedSelection = nextSnapshot;
322
+ }
323
+ currentSelection = memoizedSelection;
324
+ if (objectIs(memoizedSnapshot, nextSnapshot)) return currentSelection;
325
+ var nextSelection = selector(nextSnapshot);
326
+ if (void 0 !== isEqual && isEqual(currentSelection, nextSelection))
327
+ return memoizedSnapshot = nextSnapshot, currentSelection;
328
+ memoizedSnapshot = nextSnapshot;
329
+ return memoizedSelection = nextSelection;
330
+ }
331
+ var hasMemo = false, memoizedSnapshot, memoizedSelection, maybeGetServerSnapshot = void 0 === getServerSnapshot ? null : getServerSnapshot;
332
+ return [
333
+ function() {
334
+ return memoizedSelector(getSnapshot());
335
+ },
336
+ null === maybeGetServerSnapshot ? void 0 : function() {
337
+ return memoizedSelector(maybeGetServerSnapshot());
338
+ }
339
+ ];
340
+ },
341
+ [getSnapshot, getServerSnapshot, selector, isEqual]
342
+ );
343
+ var value = useSyncExternalStore(subscribe, instRef[0], instRef[1]);
344
+ useEffect7(
345
+ function() {
346
+ inst.hasValue = true;
347
+ inst.value = value;
348
+ },
349
+ [value]
350
+ );
351
+ useDebugValue2(value);
352
+ return value;
353
+ };
354
+ }
355
+ });
356
+
357
+ // ../../node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.development.js
358
+ var require_with_selector_development = __commonJS({
359
+ "../../node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.development.js"(exports) {
360
+ "use strict";
361
+ init_react_import();
362
+ "production" !== process.env.NODE_ENV && function() {
363
+ function is(x, y) {
364
+ return x === y && (0 !== x || 1 / x === 1 / y) || x !== x && y !== y;
365
+ }
366
+ "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStart(Error());
367
+ var React2 = __require("react"), shim = require_shim(), objectIs = "function" === typeof Object.is ? Object.is : is, useSyncExternalStore = shim.useSyncExternalStore, useRef = React2.useRef, useEffect7 = React2.useEffect, useMemo2 = React2.useMemo, useDebugValue2 = React2.useDebugValue;
368
+ exports.useSyncExternalStoreWithSelector = function(subscribe, getSnapshot, getServerSnapshot, selector, isEqual) {
369
+ var instRef = useRef(null);
370
+ if (null === instRef.current) {
371
+ var inst = { hasValue: false, value: null };
372
+ instRef.current = inst;
373
+ } else inst = instRef.current;
374
+ instRef = useMemo2(
375
+ function() {
376
+ function memoizedSelector(nextSnapshot) {
377
+ if (!hasMemo) {
378
+ hasMemo = true;
379
+ memoizedSnapshot = nextSnapshot;
380
+ nextSnapshot = selector(nextSnapshot);
381
+ if (void 0 !== isEqual && inst.hasValue) {
382
+ var currentSelection = inst.value;
383
+ if (isEqual(currentSelection, nextSnapshot))
384
+ return memoizedSelection = currentSelection;
385
+ }
386
+ return memoizedSelection = nextSnapshot;
387
+ }
388
+ currentSelection = memoizedSelection;
389
+ if (objectIs(memoizedSnapshot, nextSnapshot))
390
+ return currentSelection;
391
+ var nextSelection = selector(nextSnapshot);
392
+ if (void 0 !== isEqual && isEqual(currentSelection, nextSelection))
393
+ return memoizedSnapshot = nextSnapshot, currentSelection;
394
+ memoizedSnapshot = nextSnapshot;
395
+ return memoizedSelection = nextSelection;
396
+ }
397
+ var hasMemo = false, memoizedSnapshot, memoizedSelection, maybeGetServerSnapshot = void 0 === getServerSnapshot ? null : getServerSnapshot;
398
+ return [
399
+ function() {
400
+ return memoizedSelector(getSnapshot());
401
+ },
402
+ null === maybeGetServerSnapshot ? void 0 : function() {
403
+ return memoizedSelector(maybeGetServerSnapshot());
404
+ }
405
+ ];
406
+ },
407
+ [getSnapshot, getServerSnapshot, selector, isEqual]
408
+ );
409
+ var value = useSyncExternalStore(subscribe, instRef[0], instRef[1]);
410
+ useEffect7(
411
+ function() {
412
+ inst.hasValue = true;
413
+ inst.value = value;
414
+ },
415
+ [value]
416
+ );
417
+ useDebugValue2(value);
418
+ return value;
419
+ };
420
+ "undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__ && "function" === typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop && __REACT_DEVTOOLS_GLOBAL_HOOK__.registerInternalModuleStop(Error());
421
+ }();
422
+ }
423
+ });
424
+
425
+ // ../../node_modules/use-sync-external-store/shim/with-selector.js
426
+ var require_with_selector = __commonJS({
427
+ "../../node_modules/use-sync-external-store/shim/with-selector.js"(exports, module) {
428
+ "use strict";
429
+ init_react_import();
430
+ if (process.env.NODE_ENV === "production") {
431
+ module.exports = require_with_selector_production();
432
+ } else {
433
+ module.exports = require_with_selector_development();
434
+ }
435
+ }
436
+ });
437
+
149
438
  // ../../node_modules/fast-deep-equal/index.js
150
439
  var require_fast_deep_equal = __commonJS({
151
440
  "../../node_modules/fast-deep-equal/index.js"(exports, module) {
@@ -851,8 +1140,12 @@ var defaultViewports = [
851
1140
  { width: 1280, height: "auto", icon: "Monitor", label: "Large" }
852
1141
  ];
853
1142
 
1143
+ // ../../node_modules/zustand/esm/index.mjs
1144
+ init_react_import();
1145
+
854
1146
  // ../../node_modules/zustand/esm/vanilla.mjs
855
1147
  init_react_import();
1148
+ var import_meta = {};
856
1149
  var createStoreImpl = (createState) => {
857
1150
  let state;
858
1151
  const listeners = /* @__PURE__ */ new Set();
@@ -870,28 +1163,53 @@ var createStoreImpl = (createState) => {
870
1163
  listeners.add(listener);
871
1164
  return () => listeners.delete(listener);
872
1165
  };
873
- const api = { setState, getState, getInitialState, subscribe };
1166
+ const destroy = () => {
1167
+ if ((import_meta.env ? import_meta.env.MODE : void 0) !== "production") {
1168
+ console.warn(
1169
+ "[DEPRECATED] The `destroy` method will be unsupported in a future version. Instead use unsubscribe function returned by subscribe. Everything will be garbage-collected if store is garbage-collected."
1170
+ );
1171
+ }
1172
+ listeners.clear();
1173
+ };
1174
+ const api = { setState, getState, getInitialState, subscribe, destroy };
874
1175
  const initialState = state = createState(setState, getState, api);
875
1176
  return api;
876
1177
  };
877
1178
  var createStore = (createState) => createState ? createStoreImpl(createState) : createStoreImpl;
878
1179
 
879
- // ../../node_modules/zustand/esm/react.mjs
880
- init_react_import();
881
- import React2 from "react";
1180
+ // ../../node_modules/zustand/esm/index.mjs
1181
+ var import_with_selector = __toESM(require_with_selector(), 1);
1182
+ import ReactExports from "react";
1183
+ var import_meta2 = {};
1184
+ var { useDebugValue } = ReactExports;
1185
+ var { useSyncExternalStoreWithSelector } = import_with_selector.default;
1186
+ var didWarnAboutEqualityFn = false;
882
1187
  var identity = (arg) => arg;
883
- function useStore(api, selector = identity) {
884
- const slice = React2.useSyncExternalStore(
1188
+ function useStore(api, selector = identity, equalityFn) {
1189
+ if ((import_meta2.env ? import_meta2.env.MODE : void 0) !== "production" && equalityFn && !didWarnAboutEqualityFn) {
1190
+ console.warn(
1191
+ "[DEPRECATED] Use `createWithEqualityFn` instead of `create` or use `useStoreWithEqualityFn` instead of `useStore`. They can be imported from 'zustand/traditional'. https://github.com/pmndrs/zustand/discussions/1937"
1192
+ );
1193
+ didWarnAboutEqualityFn = true;
1194
+ }
1195
+ const slice = useSyncExternalStoreWithSelector(
885
1196
  api.subscribe,
886
- () => selector(api.getState()),
887
- () => selector(api.getInitialState())
1197
+ api.getState,
1198
+ api.getServerState || api.getInitialState,
1199
+ selector,
1200
+ equalityFn
888
1201
  );
889
- React2.useDebugValue(slice);
1202
+ useDebugValue(slice);
890
1203
  return slice;
891
1204
  }
892
1205
  var createImpl = (createState) => {
893
- const api = createStore(createState);
894
- const useBoundStore = (selector) => useStore(api, selector);
1206
+ if ((import_meta2.env ? import_meta2.env.MODE : void 0) !== "production" && typeof createState !== "function") {
1207
+ console.warn(
1208
+ "[DEPRECATED] Passing a vanilla store will be unsupported in a future version. Instead use `import { useStore } from 'zustand'`."
1209
+ );
1210
+ }
1211
+ const api = typeof createState === "function" ? createStore(createState) : createState;
1212
+ const useBoundStore = (selector, equalityFn) => useStore(api, selector, equalityFn);
895
1213
  Object.assign(useBoundStore, api);
896
1214
  return useBoundStore;
897
1215
  };
@@ -1876,6 +2194,50 @@ classnames/index.js:
1876
2194
  http://jedwatson.github.io/classnames
1877
2195
  *)
1878
2196
 
2197
+ use-sync-external-store/cjs/use-sync-external-store-shim.production.js:
2198
+ (**
2199
+ * @license React
2200
+ * use-sync-external-store-shim.production.js
2201
+ *
2202
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
2203
+ *
2204
+ * This source code is licensed under the MIT license found in the
2205
+ * LICENSE file in the root directory of this source tree.
2206
+ *)
2207
+
2208
+ use-sync-external-store/cjs/use-sync-external-store-shim.development.js:
2209
+ (**
2210
+ * @license React
2211
+ * use-sync-external-store-shim.development.js
2212
+ *
2213
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
2214
+ *
2215
+ * This source code is licensed under the MIT license found in the
2216
+ * LICENSE file in the root directory of this source tree.
2217
+ *)
2218
+
2219
+ use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.production.js:
2220
+ (**
2221
+ * @license React
2222
+ * use-sync-external-store-shim/with-selector.production.js
2223
+ *
2224
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
2225
+ *
2226
+ * This source code is licensed under the MIT license found in the
2227
+ * LICENSE file in the root directory of this source tree.
2228
+ *)
2229
+
2230
+ use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.development.js:
2231
+ (**
2232
+ * @license React
2233
+ * use-sync-external-store-shim/with-selector.development.js
2234
+ *
2235
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
2236
+ *
2237
+ * This source code is licensed under the MIT license found in the
2238
+ * LICENSE file in the root directory of this source tree.
2239
+ *)
2240
+
1879
2241
  lucide-react/dist/esm/shared/src/utils.js:
1880
2242
  (**
1881
2243
  * @license lucide-react v0.468.0 - ISC
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@measured/puck-plugin-heading-analyzer",
3
- "version": "0.19.0-canary.de23f9d",
3
+ "version": "0.19.0-canary.e62832e",
4
4
  "author": "Measured Corporation Ltd <hello@measured.co>",
5
5
  "repository": "measuredco/puck",
6
6
  "bugs": "https://github.com/measuredco/puck/issues",
@@ -25,7 +25,7 @@
25
25
  "dist"
26
26
  ],
27
27
  "devDependencies": {
28
- "@measured/puck": "^0.19.0-canary.de23f9d",
28
+ "@measured/puck": "^0.19.0-canary.e62832e",
29
29
  "@types/react": "^19.0.1",
30
30
  "@types/react-dom": "^19.0.2",
31
31
  "eslint": "^7.32.0",