@storybook/react-native 8.0.0-alpha.2 → 8.0.0-alpha.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -29,65 +29,2755 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
29
29
  ));
30
30
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
31
31
 
32
- // ../../node_modules/@storybook/types/dist/index.js
33
- var require_dist = __commonJS({
34
- "../../node_modules/@storybook/types/dist/index.js"(exports, module2) {
35
- "use strict";
36
- var __defProp2 = Object.defineProperty;
37
- var __getOwnPropDesc2 = Object.getOwnPropertyDescriptor;
38
- var __getOwnPropNames2 = Object.getOwnPropertyNames;
39
- var __hasOwnProp2 = Object.prototype.hasOwnProperty;
40
- var __export2 = (target, all) => {
41
- for (var name in all)
42
- __defProp2(target, name, { get: all[name], enumerable: true });
32
+ // ../../node_modules/lodash/_freeGlobal.js
33
+ var require_freeGlobal = __commonJS({
34
+ "../../node_modules/lodash/_freeGlobal.js"(exports, module2) {
35
+ var freeGlobal = typeof global == "object" && global && global.Object === Object && global;
36
+ module2.exports = freeGlobal;
37
+ }
38
+ });
39
+
40
+ // ../../node_modules/lodash/_root.js
41
+ var require_root = __commonJS({
42
+ "../../node_modules/lodash/_root.js"(exports, module2) {
43
+ var freeGlobal = require_freeGlobal();
44
+ var freeSelf = typeof self == "object" && self && self.Object === Object && self;
45
+ var root = freeGlobal || freeSelf || Function("return this")();
46
+ module2.exports = root;
47
+ }
48
+ });
49
+
50
+ // ../../node_modules/lodash/_Symbol.js
51
+ var require_Symbol = __commonJS({
52
+ "../../node_modules/lodash/_Symbol.js"(exports, module2) {
53
+ var root = require_root();
54
+ var Symbol2 = root.Symbol;
55
+ module2.exports = Symbol2;
56
+ }
57
+ });
58
+
59
+ // ../../node_modules/lodash/_getRawTag.js
60
+ var require_getRawTag = __commonJS({
61
+ "../../node_modules/lodash/_getRawTag.js"(exports, module2) {
62
+ var Symbol2 = require_Symbol();
63
+ var objectProto = Object.prototype;
64
+ var hasOwnProperty = objectProto.hasOwnProperty;
65
+ var nativeObjectToString = objectProto.toString;
66
+ var symToStringTag = Symbol2 ? Symbol2.toStringTag : void 0;
67
+ function getRawTag(value) {
68
+ var isOwn = hasOwnProperty.call(value, symToStringTag), tag = value[symToStringTag];
69
+ try {
70
+ value[symToStringTag] = void 0;
71
+ var unmasked = true;
72
+ } catch (e) {
73
+ }
74
+ var result = nativeObjectToString.call(value);
75
+ if (unmasked) {
76
+ if (isOwn) {
77
+ value[symToStringTag] = tag;
78
+ } else {
79
+ delete value[symToStringTag];
80
+ }
81
+ }
82
+ return result;
83
+ }
84
+ module2.exports = getRawTag;
85
+ }
86
+ });
87
+
88
+ // ../../node_modules/lodash/_objectToString.js
89
+ var require_objectToString = __commonJS({
90
+ "../../node_modules/lodash/_objectToString.js"(exports, module2) {
91
+ var objectProto = Object.prototype;
92
+ var nativeObjectToString = objectProto.toString;
93
+ function objectToString(value) {
94
+ return nativeObjectToString.call(value);
95
+ }
96
+ module2.exports = objectToString;
97
+ }
98
+ });
99
+
100
+ // ../../node_modules/lodash/_baseGetTag.js
101
+ var require_baseGetTag = __commonJS({
102
+ "../../node_modules/lodash/_baseGetTag.js"(exports, module2) {
103
+ var Symbol2 = require_Symbol();
104
+ var getRawTag = require_getRawTag();
105
+ var objectToString = require_objectToString();
106
+ var nullTag = "[object Null]";
107
+ var undefinedTag = "[object Undefined]";
108
+ var symToStringTag = Symbol2 ? Symbol2.toStringTag : void 0;
109
+ function baseGetTag(value) {
110
+ if (value == null) {
111
+ return value === void 0 ? undefinedTag : nullTag;
112
+ }
113
+ return symToStringTag && symToStringTag in Object(value) ? getRawTag(value) : objectToString(value);
114
+ }
115
+ module2.exports = baseGetTag;
116
+ }
117
+ });
118
+
119
+ // ../../node_modules/lodash/isObject.js
120
+ var require_isObject = __commonJS({
121
+ "../../node_modules/lodash/isObject.js"(exports, module2) {
122
+ function isObject(value) {
123
+ var type = typeof value;
124
+ return value != null && (type == "object" || type == "function");
125
+ }
126
+ module2.exports = isObject;
127
+ }
128
+ });
129
+
130
+ // ../../node_modules/lodash/isFunction.js
131
+ var require_isFunction = __commonJS({
132
+ "../../node_modules/lodash/isFunction.js"(exports, module2) {
133
+ var baseGetTag = require_baseGetTag();
134
+ var isObject = require_isObject();
135
+ var asyncTag = "[object AsyncFunction]";
136
+ var funcTag = "[object Function]";
137
+ var genTag = "[object GeneratorFunction]";
138
+ var proxyTag = "[object Proxy]";
139
+ function isFunction(value) {
140
+ if (!isObject(value)) {
141
+ return false;
142
+ }
143
+ var tag = baseGetTag(value);
144
+ return tag == funcTag || tag == genTag || tag == asyncTag || tag == proxyTag;
145
+ }
146
+ module2.exports = isFunction;
147
+ }
148
+ });
149
+
150
+ // ../../node_modules/lodash/_coreJsData.js
151
+ var require_coreJsData = __commonJS({
152
+ "../../node_modules/lodash/_coreJsData.js"(exports, module2) {
153
+ var root = require_root();
154
+ var coreJsData = root["__core-js_shared__"];
155
+ module2.exports = coreJsData;
156
+ }
157
+ });
158
+
159
+ // ../../node_modules/lodash/_isMasked.js
160
+ var require_isMasked = __commonJS({
161
+ "../../node_modules/lodash/_isMasked.js"(exports, module2) {
162
+ var coreJsData = require_coreJsData();
163
+ var maskSrcKey = function() {
164
+ var uid = /[^.]+$/.exec(coreJsData && coreJsData.keys && coreJsData.keys.IE_PROTO || "");
165
+ return uid ? "Symbol(src)_1." + uid : "";
166
+ }();
167
+ function isMasked(func) {
168
+ return !!maskSrcKey && maskSrcKey in func;
169
+ }
170
+ module2.exports = isMasked;
171
+ }
172
+ });
173
+
174
+ // ../../node_modules/lodash/_toSource.js
175
+ var require_toSource = __commonJS({
176
+ "../../node_modules/lodash/_toSource.js"(exports, module2) {
177
+ var funcProto = Function.prototype;
178
+ var funcToString = funcProto.toString;
179
+ function toSource(func) {
180
+ if (func != null) {
181
+ try {
182
+ return funcToString.call(func);
183
+ } catch (e) {
184
+ }
185
+ try {
186
+ return func + "";
187
+ } catch (e) {
188
+ }
189
+ }
190
+ return "";
191
+ }
192
+ module2.exports = toSource;
193
+ }
194
+ });
195
+
196
+ // ../../node_modules/lodash/_baseIsNative.js
197
+ var require_baseIsNative = __commonJS({
198
+ "../../node_modules/lodash/_baseIsNative.js"(exports, module2) {
199
+ var isFunction = require_isFunction();
200
+ var isMasked = require_isMasked();
201
+ var isObject = require_isObject();
202
+ var toSource = require_toSource();
203
+ var reRegExpChar = /[\\^$.*+?()[\]{}|]/g;
204
+ var reIsHostCtor = /^\[object .+?Constructor\]$/;
205
+ var funcProto = Function.prototype;
206
+ var objectProto = Object.prototype;
207
+ var funcToString = funcProto.toString;
208
+ var hasOwnProperty = objectProto.hasOwnProperty;
209
+ var reIsNative = RegExp(
210
+ "^" + funcToString.call(hasOwnProperty).replace(reRegExpChar, "\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g, "$1.*?") + "$"
211
+ );
212
+ function baseIsNative(value) {
213
+ if (!isObject(value) || isMasked(value)) {
214
+ return false;
215
+ }
216
+ var pattern = isFunction(value) ? reIsNative : reIsHostCtor;
217
+ return pattern.test(toSource(value));
218
+ }
219
+ module2.exports = baseIsNative;
220
+ }
221
+ });
222
+
223
+ // ../../node_modules/lodash/_getValue.js
224
+ var require_getValue = __commonJS({
225
+ "../../node_modules/lodash/_getValue.js"(exports, module2) {
226
+ function getValue(object, key) {
227
+ return object == null ? void 0 : object[key];
228
+ }
229
+ module2.exports = getValue;
230
+ }
231
+ });
232
+
233
+ // ../../node_modules/lodash/_getNative.js
234
+ var require_getNative = __commonJS({
235
+ "../../node_modules/lodash/_getNative.js"(exports, module2) {
236
+ var baseIsNative = require_baseIsNative();
237
+ var getValue = require_getValue();
238
+ function getNative(object, key) {
239
+ var value = getValue(object, key);
240
+ return baseIsNative(value) ? value : void 0;
241
+ }
242
+ module2.exports = getNative;
243
+ }
244
+ });
245
+
246
+ // ../../node_modules/lodash/_defineProperty.js
247
+ var require_defineProperty = __commonJS({
248
+ "../../node_modules/lodash/_defineProperty.js"(exports, module2) {
249
+ var getNative = require_getNative();
250
+ var defineProperty = function() {
251
+ try {
252
+ var func = getNative(Object, "defineProperty");
253
+ func({}, "", {});
254
+ return func;
255
+ } catch (e) {
256
+ }
257
+ }();
258
+ module2.exports = defineProperty;
259
+ }
260
+ });
261
+
262
+ // ../../node_modules/lodash/_baseAssignValue.js
263
+ var require_baseAssignValue = __commonJS({
264
+ "../../node_modules/lodash/_baseAssignValue.js"(exports, module2) {
265
+ var defineProperty = require_defineProperty();
266
+ function baseAssignValue(object, key, value) {
267
+ if (key == "__proto__" && defineProperty) {
268
+ defineProperty(object, key, {
269
+ "configurable": true,
270
+ "enumerable": true,
271
+ "value": value,
272
+ "writable": true
273
+ });
274
+ } else {
275
+ object[key] = value;
276
+ }
277
+ }
278
+ module2.exports = baseAssignValue;
279
+ }
280
+ });
281
+
282
+ // ../../node_modules/lodash/_arrayAggregator.js
283
+ var require_arrayAggregator = __commonJS({
284
+ "../../node_modules/lodash/_arrayAggregator.js"(exports, module2) {
285
+ function arrayAggregator(array, setter, iteratee, accumulator) {
286
+ var index = -1, length = array == null ? 0 : array.length;
287
+ while (++index < length) {
288
+ var value = array[index];
289
+ setter(accumulator, value, iteratee(value), array);
290
+ }
291
+ return accumulator;
292
+ }
293
+ module2.exports = arrayAggregator;
294
+ }
295
+ });
296
+
297
+ // ../../node_modules/lodash/_createBaseFor.js
298
+ var require_createBaseFor = __commonJS({
299
+ "../../node_modules/lodash/_createBaseFor.js"(exports, module2) {
300
+ function createBaseFor(fromRight) {
301
+ return function(object, iteratee, keysFunc) {
302
+ var index = -1, iterable = Object(object), props = keysFunc(object), length = props.length;
303
+ while (length--) {
304
+ var key = props[fromRight ? length : ++index];
305
+ if (iteratee(iterable[key], key, iterable) === false) {
306
+ break;
307
+ }
308
+ }
309
+ return object;
310
+ };
311
+ }
312
+ module2.exports = createBaseFor;
313
+ }
314
+ });
315
+
316
+ // ../../node_modules/lodash/_baseFor.js
317
+ var require_baseFor = __commonJS({
318
+ "../../node_modules/lodash/_baseFor.js"(exports, module2) {
319
+ var createBaseFor = require_createBaseFor();
320
+ var baseFor = createBaseFor();
321
+ module2.exports = baseFor;
322
+ }
323
+ });
324
+
325
+ // ../../node_modules/lodash/_baseTimes.js
326
+ var require_baseTimes = __commonJS({
327
+ "../../node_modules/lodash/_baseTimes.js"(exports, module2) {
328
+ function baseTimes(n, iteratee) {
329
+ var index = -1, result = Array(n);
330
+ while (++index < n) {
331
+ result[index] = iteratee(index);
332
+ }
333
+ return result;
334
+ }
335
+ module2.exports = baseTimes;
336
+ }
337
+ });
338
+
339
+ // ../../node_modules/lodash/isObjectLike.js
340
+ var require_isObjectLike = __commonJS({
341
+ "../../node_modules/lodash/isObjectLike.js"(exports, module2) {
342
+ function isObjectLike(value) {
343
+ return value != null && typeof value == "object";
344
+ }
345
+ module2.exports = isObjectLike;
346
+ }
347
+ });
348
+
349
+ // ../../node_modules/lodash/_baseIsArguments.js
350
+ var require_baseIsArguments = __commonJS({
351
+ "../../node_modules/lodash/_baseIsArguments.js"(exports, module2) {
352
+ var baseGetTag = require_baseGetTag();
353
+ var isObjectLike = require_isObjectLike();
354
+ var argsTag = "[object Arguments]";
355
+ function baseIsArguments(value) {
356
+ return isObjectLike(value) && baseGetTag(value) == argsTag;
357
+ }
358
+ module2.exports = baseIsArguments;
359
+ }
360
+ });
361
+
362
+ // ../../node_modules/lodash/isArguments.js
363
+ var require_isArguments = __commonJS({
364
+ "../../node_modules/lodash/isArguments.js"(exports, module2) {
365
+ var baseIsArguments = require_baseIsArguments();
366
+ var isObjectLike = require_isObjectLike();
367
+ var objectProto = Object.prototype;
368
+ var hasOwnProperty = objectProto.hasOwnProperty;
369
+ var propertyIsEnumerable = objectProto.propertyIsEnumerable;
370
+ var isArguments = baseIsArguments(function() {
371
+ return arguments;
372
+ }()) ? baseIsArguments : function(value) {
373
+ return isObjectLike(value) && hasOwnProperty.call(value, "callee") && !propertyIsEnumerable.call(value, "callee");
374
+ };
375
+ module2.exports = isArguments;
376
+ }
377
+ });
378
+
379
+ // ../../node_modules/lodash/isArray.js
380
+ var require_isArray = __commonJS({
381
+ "../../node_modules/lodash/isArray.js"(exports, module2) {
382
+ var isArray = Array.isArray;
383
+ module2.exports = isArray;
384
+ }
385
+ });
386
+
387
+ // ../../node_modules/lodash/stubFalse.js
388
+ var require_stubFalse = __commonJS({
389
+ "../../node_modules/lodash/stubFalse.js"(exports, module2) {
390
+ function stubFalse() {
391
+ return false;
392
+ }
393
+ module2.exports = stubFalse;
394
+ }
395
+ });
396
+
397
+ // ../../node_modules/lodash/isBuffer.js
398
+ var require_isBuffer = __commonJS({
399
+ "../../node_modules/lodash/isBuffer.js"(exports, module2) {
400
+ var root = require_root();
401
+ var stubFalse = require_stubFalse();
402
+ var freeExports = typeof exports == "object" && exports && !exports.nodeType && exports;
403
+ var freeModule = freeExports && typeof module2 == "object" && module2 && !module2.nodeType && module2;
404
+ var moduleExports = freeModule && freeModule.exports === freeExports;
405
+ var Buffer2 = moduleExports ? root.Buffer : void 0;
406
+ var nativeIsBuffer = Buffer2 ? Buffer2.isBuffer : void 0;
407
+ var isBuffer = nativeIsBuffer || stubFalse;
408
+ module2.exports = isBuffer;
409
+ }
410
+ });
411
+
412
+ // ../../node_modules/lodash/_isIndex.js
413
+ var require_isIndex = __commonJS({
414
+ "../../node_modules/lodash/_isIndex.js"(exports, module2) {
415
+ var MAX_SAFE_INTEGER = 9007199254740991;
416
+ var reIsUint = /^(?:0|[1-9]\d*)$/;
417
+ function isIndex(value, length) {
418
+ var type = typeof value;
419
+ length = length == null ? MAX_SAFE_INTEGER : length;
420
+ return !!length && (type == "number" || type != "symbol" && reIsUint.test(value)) && (value > -1 && value % 1 == 0 && value < length);
421
+ }
422
+ module2.exports = isIndex;
423
+ }
424
+ });
425
+
426
+ // ../../node_modules/lodash/isLength.js
427
+ var require_isLength = __commonJS({
428
+ "../../node_modules/lodash/isLength.js"(exports, module2) {
429
+ var MAX_SAFE_INTEGER = 9007199254740991;
430
+ function isLength(value) {
431
+ return typeof value == "number" && value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER;
432
+ }
433
+ module2.exports = isLength;
434
+ }
435
+ });
436
+
437
+ // ../../node_modules/lodash/_baseIsTypedArray.js
438
+ var require_baseIsTypedArray = __commonJS({
439
+ "../../node_modules/lodash/_baseIsTypedArray.js"(exports, module2) {
440
+ var baseGetTag = require_baseGetTag();
441
+ var isLength = require_isLength();
442
+ var isObjectLike = require_isObjectLike();
443
+ var argsTag = "[object Arguments]";
444
+ var arrayTag = "[object Array]";
445
+ var boolTag = "[object Boolean]";
446
+ var dateTag = "[object Date]";
447
+ var errorTag = "[object Error]";
448
+ var funcTag = "[object Function]";
449
+ var mapTag = "[object Map]";
450
+ var numberTag = "[object Number]";
451
+ var objectTag = "[object Object]";
452
+ var regexpTag = "[object RegExp]";
453
+ var setTag = "[object Set]";
454
+ var stringTag = "[object String]";
455
+ var weakMapTag = "[object WeakMap]";
456
+ var arrayBufferTag = "[object ArrayBuffer]";
457
+ var dataViewTag = "[object DataView]";
458
+ var float32Tag = "[object Float32Array]";
459
+ var float64Tag = "[object Float64Array]";
460
+ var int8Tag = "[object Int8Array]";
461
+ var int16Tag = "[object Int16Array]";
462
+ var int32Tag = "[object Int32Array]";
463
+ var uint8Tag = "[object Uint8Array]";
464
+ var uint8ClampedTag = "[object Uint8ClampedArray]";
465
+ var uint16Tag = "[object Uint16Array]";
466
+ var uint32Tag = "[object Uint32Array]";
467
+ var typedArrayTags = {};
468
+ typedArrayTags[float32Tag] = typedArrayTags[float64Tag] = typedArrayTags[int8Tag] = typedArrayTags[int16Tag] = typedArrayTags[int32Tag] = typedArrayTags[uint8Tag] = typedArrayTags[uint8ClampedTag] = typedArrayTags[uint16Tag] = typedArrayTags[uint32Tag] = true;
469
+ typedArrayTags[argsTag] = typedArrayTags[arrayTag] = typedArrayTags[arrayBufferTag] = typedArrayTags[boolTag] = typedArrayTags[dataViewTag] = typedArrayTags[dateTag] = typedArrayTags[errorTag] = typedArrayTags[funcTag] = typedArrayTags[mapTag] = typedArrayTags[numberTag] = typedArrayTags[objectTag] = typedArrayTags[regexpTag] = typedArrayTags[setTag] = typedArrayTags[stringTag] = typedArrayTags[weakMapTag] = false;
470
+ function baseIsTypedArray(value) {
471
+ return isObjectLike(value) && isLength(value.length) && !!typedArrayTags[baseGetTag(value)];
472
+ }
473
+ module2.exports = baseIsTypedArray;
474
+ }
475
+ });
476
+
477
+ // ../../node_modules/lodash/_baseUnary.js
478
+ var require_baseUnary = __commonJS({
479
+ "../../node_modules/lodash/_baseUnary.js"(exports, module2) {
480
+ function baseUnary(func) {
481
+ return function(value) {
482
+ return func(value);
483
+ };
484
+ }
485
+ module2.exports = baseUnary;
486
+ }
487
+ });
488
+
489
+ // ../../node_modules/lodash/_nodeUtil.js
490
+ var require_nodeUtil = __commonJS({
491
+ "../../node_modules/lodash/_nodeUtil.js"(exports, module2) {
492
+ var freeGlobal = require_freeGlobal();
493
+ var freeExports = typeof exports == "object" && exports && !exports.nodeType && exports;
494
+ var freeModule = freeExports && typeof module2 == "object" && module2 && !module2.nodeType && module2;
495
+ var moduleExports = freeModule && freeModule.exports === freeExports;
496
+ var freeProcess = moduleExports && freeGlobal.process;
497
+ var nodeUtil = function() {
498
+ try {
499
+ var types = freeModule && freeModule.require && freeModule.require("util").types;
500
+ if (types) {
501
+ return types;
502
+ }
503
+ return freeProcess && freeProcess.binding && freeProcess.binding("util");
504
+ } catch (e) {
505
+ }
506
+ }();
507
+ module2.exports = nodeUtil;
508
+ }
509
+ });
510
+
511
+ // ../../node_modules/lodash/isTypedArray.js
512
+ var require_isTypedArray = __commonJS({
513
+ "../../node_modules/lodash/isTypedArray.js"(exports, module2) {
514
+ var baseIsTypedArray = require_baseIsTypedArray();
515
+ var baseUnary = require_baseUnary();
516
+ var nodeUtil = require_nodeUtil();
517
+ var nodeIsTypedArray = nodeUtil && nodeUtil.isTypedArray;
518
+ var isTypedArray = nodeIsTypedArray ? baseUnary(nodeIsTypedArray) : baseIsTypedArray;
519
+ module2.exports = isTypedArray;
520
+ }
521
+ });
522
+
523
+ // ../../node_modules/lodash/_arrayLikeKeys.js
524
+ var require_arrayLikeKeys = __commonJS({
525
+ "../../node_modules/lodash/_arrayLikeKeys.js"(exports, module2) {
526
+ var baseTimes = require_baseTimes();
527
+ var isArguments = require_isArguments();
528
+ var isArray = require_isArray();
529
+ var isBuffer = require_isBuffer();
530
+ var isIndex = require_isIndex();
531
+ var isTypedArray = require_isTypedArray();
532
+ var objectProto = Object.prototype;
533
+ var hasOwnProperty = objectProto.hasOwnProperty;
534
+ function arrayLikeKeys(value, inherited) {
535
+ var isArr = isArray(value), isArg = !isArr && isArguments(value), isBuff = !isArr && !isArg && isBuffer(value), isType = !isArr && !isArg && !isBuff && isTypedArray(value), skipIndexes = isArr || isArg || isBuff || isType, result = skipIndexes ? baseTimes(value.length, String) : [], length = result.length;
536
+ for (var key in value) {
537
+ if ((inherited || hasOwnProperty.call(value, key)) && !(skipIndexes && // Safari 9 has enumerable `arguments.length` in strict mode.
538
+ (key == "length" || // Node.js 0.10 has enumerable non-index properties on buffers.
539
+ isBuff && (key == "offset" || key == "parent") || // PhantomJS 2 has enumerable non-index properties on typed arrays.
540
+ isType && (key == "buffer" || key == "byteLength" || key == "byteOffset") || // Skip index properties.
541
+ isIndex(key, length)))) {
542
+ result.push(key);
543
+ }
544
+ }
545
+ return result;
546
+ }
547
+ module2.exports = arrayLikeKeys;
548
+ }
549
+ });
550
+
551
+ // ../../node_modules/lodash/_isPrototype.js
552
+ var require_isPrototype = __commonJS({
553
+ "../../node_modules/lodash/_isPrototype.js"(exports, module2) {
554
+ var objectProto = Object.prototype;
555
+ function isPrototype(value) {
556
+ var Ctor = value && value.constructor, proto = typeof Ctor == "function" && Ctor.prototype || objectProto;
557
+ return value === proto;
558
+ }
559
+ module2.exports = isPrototype;
560
+ }
561
+ });
562
+
563
+ // ../../node_modules/lodash/_overArg.js
564
+ var require_overArg = __commonJS({
565
+ "../../node_modules/lodash/_overArg.js"(exports, module2) {
566
+ function overArg(func, transform) {
567
+ return function(arg) {
568
+ return func(transform(arg));
569
+ };
570
+ }
571
+ module2.exports = overArg;
572
+ }
573
+ });
574
+
575
+ // ../../node_modules/lodash/_nativeKeys.js
576
+ var require_nativeKeys = __commonJS({
577
+ "../../node_modules/lodash/_nativeKeys.js"(exports, module2) {
578
+ var overArg = require_overArg();
579
+ var nativeKeys = overArg(Object.keys, Object);
580
+ module2.exports = nativeKeys;
581
+ }
582
+ });
583
+
584
+ // ../../node_modules/lodash/_baseKeys.js
585
+ var require_baseKeys = __commonJS({
586
+ "../../node_modules/lodash/_baseKeys.js"(exports, module2) {
587
+ var isPrototype = require_isPrototype();
588
+ var nativeKeys = require_nativeKeys();
589
+ var objectProto = Object.prototype;
590
+ var hasOwnProperty = objectProto.hasOwnProperty;
591
+ function baseKeys(object) {
592
+ if (!isPrototype(object)) {
593
+ return nativeKeys(object);
594
+ }
595
+ var result = [];
596
+ for (var key in Object(object)) {
597
+ if (hasOwnProperty.call(object, key) && key != "constructor") {
598
+ result.push(key);
599
+ }
600
+ }
601
+ return result;
602
+ }
603
+ module2.exports = baseKeys;
604
+ }
605
+ });
606
+
607
+ // ../../node_modules/lodash/isArrayLike.js
608
+ var require_isArrayLike = __commonJS({
609
+ "../../node_modules/lodash/isArrayLike.js"(exports, module2) {
610
+ var isFunction = require_isFunction();
611
+ var isLength = require_isLength();
612
+ function isArrayLike(value) {
613
+ return value != null && isLength(value.length) && !isFunction(value);
614
+ }
615
+ module2.exports = isArrayLike;
616
+ }
617
+ });
618
+
619
+ // ../../node_modules/lodash/keys.js
620
+ var require_keys = __commonJS({
621
+ "../../node_modules/lodash/keys.js"(exports, module2) {
622
+ var arrayLikeKeys = require_arrayLikeKeys();
623
+ var baseKeys = require_baseKeys();
624
+ var isArrayLike = require_isArrayLike();
625
+ function keys(object) {
626
+ return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object);
627
+ }
628
+ module2.exports = keys;
629
+ }
630
+ });
631
+
632
+ // ../../node_modules/lodash/_baseForOwn.js
633
+ var require_baseForOwn = __commonJS({
634
+ "../../node_modules/lodash/_baseForOwn.js"(exports, module2) {
635
+ var baseFor = require_baseFor();
636
+ var keys = require_keys();
637
+ function baseForOwn(object, iteratee) {
638
+ return object && baseFor(object, iteratee, keys);
639
+ }
640
+ module2.exports = baseForOwn;
641
+ }
642
+ });
643
+
644
+ // ../../node_modules/lodash/_createBaseEach.js
645
+ var require_createBaseEach = __commonJS({
646
+ "../../node_modules/lodash/_createBaseEach.js"(exports, module2) {
647
+ var isArrayLike = require_isArrayLike();
648
+ function createBaseEach(eachFunc, fromRight) {
649
+ return function(collection, iteratee) {
650
+ if (collection == null) {
651
+ return collection;
652
+ }
653
+ if (!isArrayLike(collection)) {
654
+ return eachFunc(collection, iteratee);
655
+ }
656
+ var length = collection.length, index = fromRight ? length : -1, iterable = Object(collection);
657
+ while (fromRight ? index-- : ++index < length) {
658
+ if (iteratee(iterable[index], index, iterable) === false) {
659
+ break;
660
+ }
661
+ }
662
+ return collection;
663
+ };
664
+ }
665
+ module2.exports = createBaseEach;
666
+ }
667
+ });
668
+
669
+ // ../../node_modules/lodash/_baseEach.js
670
+ var require_baseEach = __commonJS({
671
+ "../../node_modules/lodash/_baseEach.js"(exports, module2) {
672
+ var baseForOwn = require_baseForOwn();
673
+ var createBaseEach = require_createBaseEach();
674
+ var baseEach = createBaseEach(baseForOwn);
675
+ module2.exports = baseEach;
676
+ }
677
+ });
678
+
679
+ // ../../node_modules/lodash/_baseAggregator.js
680
+ var require_baseAggregator = __commonJS({
681
+ "../../node_modules/lodash/_baseAggregator.js"(exports, module2) {
682
+ var baseEach = require_baseEach();
683
+ function baseAggregator(collection, setter, iteratee, accumulator) {
684
+ baseEach(collection, function(value, key, collection2) {
685
+ setter(accumulator, value, iteratee(value), collection2);
686
+ });
687
+ return accumulator;
688
+ }
689
+ module2.exports = baseAggregator;
690
+ }
691
+ });
692
+
693
+ // ../../node_modules/lodash/_listCacheClear.js
694
+ var require_listCacheClear = __commonJS({
695
+ "../../node_modules/lodash/_listCacheClear.js"(exports, module2) {
696
+ function listCacheClear() {
697
+ this.__data__ = [];
698
+ this.size = 0;
699
+ }
700
+ module2.exports = listCacheClear;
701
+ }
702
+ });
703
+
704
+ // ../../node_modules/lodash/eq.js
705
+ var require_eq = __commonJS({
706
+ "../../node_modules/lodash/eq.js"(exports, module2) {
707
+ function eq(value, other) {
708
+ return value === other || value !== value && other !== other;
709
+ }
710
+ module2.exports = eq;
711
+ }
712
+ });
713
+
714
+ // ../../node_modules/lodash/_assocIndexOf.js
715
+ var require_assocIndexOf = __commonJS({
716
+ "../../node_modules/lodash/_assocIndexOf.js"(exports, module2) {
717
+ var eq = require_eq();
718
+ function assocIndexOf(array, key) {
719
+ var length = array.length;
720
+ while (length--) {
721
+ if (eq(array[length][0], key)) {
722
+ return length;
723
+ }
724
+ }
725
+ return -1;
726
+ }
727
+ module2.exports = assocIndexOf;
728
+ }
729
+ });
730
+
731
+ // ../../node_modules/lodash/_listCacheDelete.js
732
+ var require_listCacheDelete = __commonJS({
733
+ "../../node_modules/lodash/_listCacheDelete.js"(exports, module2) {
734
+ var assocIndexOf = require_assocIndexOf();
735
+ var arrayProto = Array.prototype;
736
+ var splice = arrayProto.splice;
737
+ function listCacheDelete(key) {
738
+ var data = this.__data__, index = assocIndexOf(data, key);
739
+ if (index < 0) {
740
+ return false;
741
+ }
742
+ var lastIndex = data.length - 1;
743
+ if (index == lastIndex) {
744
+ data.pop();
745
+ } else {
746
+ splice.call(data, index, 1);
747
+ }
748
+ --this.size;
749
+ return true;
750
+ }
751
+ module2.exports = listCacheDelete;
752
+ }
753
+ });
754
+
755
+ // ../../node_modules/lodash/_listCacheGet.js
756
+ var require_listCacheGet = __commonJS({
757
+ "../../node_modules/lodash/_listCacheGet.js"(exports, module2) {
758
+ var assocIndexOf = require_assocIndexOf();
759
+ function listCacheGet(key) {
760
+ var data = this.__data__, index = assocIndexOf(data, key);
761
+ return index < 0 ? void 0 : data[index][1];
762
+ }
763
+ module2.exports = listCacheGet;
764
+ }
765
+ });
766
+
767
+ // ../../node_modules/lodash/_listCacheHas.js
768
+ var require_listCacheHas = __commonJS({
769
+ "../../node_modules/lodash/_listCacheHas.js"(exports, module2) {
770
+ var assocIndexOf = require_assocIndexOf();
771
+ function listCacheHas(key) {
772
+ return assocIndexOf(this.__data__, key) > -1;
773
+ }
774
+ module2.exports = listCacheHas;
775
+ }
776
+ });
777
+
778
+ // ../../node_modules/lodash/_listCacheSet.js
779
+ var require_listCacheSet = __commonJS({
780
+ "../../node_modules/lodash/_listCacheSet.js"(exports, module2) {
781
+ var assocIndexOf = require_assocIndexOf();
782
+ function listCacheSet(key, value) {
783
+ var data = this.__data__, index = assocIndexOf(data, key);
784
+ if (index < 0) {
785
+ ++this.size;
786
+ data.push([key, value]);
787
+ } else {
788
+ data[index][1] = value;
789
+ }
790
+ return this;
791
+ }
792
+ module2.exports = listCacheSet;
793
+ }
794
+ });
795
+
796
+ // ../../node_modules/lodash/_ListCache.js
797
+ var require_ListCache = __commonJS({
798
+ "../../node_modules/lodash/_ListCache.js"(exports, module2) {
799
+ var listCacheClear = require_listCacheClear();
800
+ var listCacheDelete = require_listCacheDelete();
801
+ var listCacheGet = require_listCacheGet();
802
+ var listCacheHas = require_listCacheHas();
803
+ var listCacheSet = require_listCacheSet();
804
+ function ListCache(entries) {
805
+ var index = -1, length = entries == null ? 0 : entries.length;
806
+ this.clear();
807
+ while (++index < length) {
808
+ var entry = entries[index];
809
+ this.set(entry[0], entry[1]);
810
+ }
811
+ }
812
+ ListCache.prototype.clear = listCacheClear;
813
+ ListCache.prototype["delete"] = listCacheDelete;
814
+ ListCache.prototype.get = listCacheGet;
815
+ ListCache.prototype.has = listCacheHas;
816
+ ListCache.prototype.set = listCacheSet;
817
+ module2.exports = ListCache;
818
+ }
819
+ });
820
+
821
+ // ../../node_modules/lodash/_stackClear.js
822
+ var require_stackClear = __commonJS({
823
+ "../../node_modules/lodash/_stackClear.js"(exports, module2) {
824
+ var ListCache = require_ListCache();
825
+ function stackClear() {
826
+ this.__data__ = new ListCache();
827
+ this.size = 0;
828
+ }
829
+ module2.exports = stackClear;
830
+ }
831
+ });
832
+
833
+ // ../../node_modules/lodash/_stackDelete.js
834
+ var require_stackDelete = __commonJS({
835
+ "../../node_modules/lodash/_stackDelete.js"(exports, module2) {
836
+ function stackDelete(key) {
837
+ var data = this.__data__, result = data["delete"](key);
838
+ this.size = data.size;
839
+ return result;
840
+ }
841
+ module2.exports = stackDelete;
842
+ }
843
+ });
844
+
845
+ // ../../node_modules/lodash/_stackGet.js
846
+ var require_stackGet = __commonJS({
847
+ "../../node_modules/lodash/_stackGet.js"(exports, module2) {
848
+ function stackGet(key) {
849
+ return this.__data__.get(key);
850
+ }
851
+ module2.exports = stackGet;
852
+ }
853
+ });
854
+
855
+ // ../../node_modules/lodash/_stackHas.js
856
+ var require_stackHas = __commonJS({
857
+ "../../node_modules/lodash/_stackHas.js"(exports, module2) {
858
+ function stackHas(key) {
859
+ return this.__data__.has(key);
860
+ }
861
+ module2.exports = stackHas;
862
+ }
863
+ });
864
+
865
+ // ../../node_modules/lodash/_Map.js
866
+ var require_Map = __commonJS({
867
+ "../../node_modules/lodash/_Map.js"(exports, module2) {
868
+ var getNative = require_getNative();
869
+ var root = require_root();
870
+ var Map2 = getNative(root, "Map");
871
+ module2.exports = Map2;
872
+ }
873
+ });
874
+
875
+ // ../../node_modules/lodash/_nativeCreate.js
876
+ var require_nativeCreate = __commonJS({
877
+ "../../node_modules/lodash/_nativeCreate.js"(exports, module2) {
878
+ var getNative = require_getNative();
879
+ var nativeCreate = getNative(Object, "create");
880
+ module2.exports = nativeCreate;
881
+ }
882
+ });
883
+
884
+ // ../../node_modules/lodash/_hashClear.js
885
+ var require_hashClear = __commonJS({
886
+ "../../node_modules/lodash/_hashClear.js"(exports, module2) {
887
+ var nativeCreate = require_nativeCreate();
888
+ function hashClear() {
889
+ this.__data__ = nativeCreate ? nativeCreate(null) : {};
890
+ this.size = 0;
891
+ }
892
+ module2.exports = hashClear;
893
+ }
894
+ });
895
+
896
+ // ../../node_modules/lodash/_hashDelete.js
897
+ var require_hashDelete = __commonJS({
898
+ "../../node_modules/lodash/_hashDelete.js"(exports, module2) {
899
+ function hashDelete(key) {
900
+ var result = this.has(key) && delete this.__data__[key];
901
+ this.size -= result ? 1 : 0;
902
+ return result;
903
+ }
904
+ module2.exports = hashDelete;
905
+ }
906
+ });
907
+
908
+ // ../../node_modules/lodash/_hashGet.js
909
+ var require_hashGet = __commonJS({
910
+ "../../node_modules/lodash/_hashGet.js"(exports, module2) {
911
+ var nativeCreate = require_nativeCreate();
912
+ var HASH_UNDEFINED = "__lodash_hash_undefined__";
913
+ var objectProto = Object.prototype;
914
+ var hasOwnProperty = objectProto.hasOwnProperty;
915
+ function hashGet(key) {
916
+ var data = this.__data__;
917
+ if (nativeCreate) {
918
+ var result = data[key];
919
+ return result === HASH_UNDEFINED ? void 0 : result;
920
+ }
921
+ return hasOwnProperty.call(data, key) ? data[key] : void 0;
922
+ }
923
+ module2.exports = hashGet;
924
+ }
925
+ });
926
+
927
+ // ../../node_modules/lodash/_hashHas.js
928
+ var require_hashHas = __commonJS({
929
+ "../../node_modules/lodash/_hashHas.js"(exports, module2) {
930
+ var nativeCreate = require_nativeCreate();
931
+ var objectProto = Object.prototype;
932
+ var hasOwnProperty = objectProto.hasOwnProperty;
933
+ function hashHas(key) {
934
+ var data = this.__data__;
935
+ return nativeCreate ? data[key] !== void 0 : hasOwnProperty.call(data, key);
936
+ }
937
+ module2.exports = hashHas;
938
+ }
939
+ });
940
+
941
+ // ../../node_modules/lodash/_hashSet.js
942
+ var require_hashSet = __commonJS({
943
+ "../../node_modules/lodash/_hashSet.js"(exports, module2) {
944
+ var nativeCreate = require_nativeCreate();
945
+ var HASH_UNDEFINED = "__lodash_hash_undefined__";
946
+ function hashSet(key, value) {
947
+ var data = this.__data__;
948
+ this.size += this.has(key) ? 0 : 1;
949
+ data[key] = nativeCreate && value === void 0 ? HASH_UNDEFINED : value;
950
+ return this;
951
+ }
952
+ module2.exports = hashSet;
953
+ }
954
+ });
955
+
956
+ // ../../node_modules/lodash/_Hash.js
957
+ var require_Hash = __commonJS({
958
+ "../../node_modules/lodash/_Hash.js"(exports, module2) {
959
+ var hashClear = require_hashClear();
960
+ var hashDelete = require_hashDelete();
961
+ var hashGet = require_hashGet();
962
+ var hashHas = require_hashHas();
963
+ var hashSet = require_hashSet();
964
+ function Hash(entries) {
965
+ var index = -1, length = entries == null ? 0 : entries.length;
966
+ this.clear();
967
+ while (++index < length) {
968
+ var entry = entries[index];
969
+ this.set(entry[0], entry[1]);
970
+ }
971
+ }
972
+ Hash.prototype.clear = hashClear;
973
+ Hash.prototype["delete"] = hashDelete;
974
+ Hash.prototype.get = hashGet;
975
+ Hash.prototype.has = hashHas;
976
+ Hash.prototype.set = hashSet;
977
+ module2.exports = Hash;
978
+ }
979
+ });
980
+
981
+ // ../../node_modules/lodash/_mapCacheClear.js
982
+ var require_mapCacheClear = __commonJS({
983
+ "../../node_modules/lodash/_mapCacheClear.js"(exports, module2) {
984
+ var Hash = require_Hash();
985
+ var ListCache = require_ListCache();
986
+ var Map2 = require_Map();
987
+ function mapCacheClear() {
988
+ this.size = 0;
989
+ this.__data__ = {
990
+ "hash": new Hash(),
991
+ "map": new (Map2 || ListCache)(),
992
+ "string": new Hash()
993
+ };
994
+ }
995
+ module2.exports = mapCacheClear;
996
+ }
997
+ });
998
+
999
+ // ../../node_modules/lodash/_isKeyable.js
1000
+ var require_isKeyable = __commonJS({
1001
+ "../../node_modules/lodash/_isKeyable.js"(exports, module2) {
1002
+ function isKeyable(value) {
1003
+ var type = typeof value;
1004
+ return type == "string" || type == "number" || type == "symbol" || type == "boolean" ? value !== "__proto__" : value === null;
1005
+ }
1006
+ module2.exports = isKeyable;
1007
+ }
1008
+ });
1009
+
1010
+ // ../../node_modules/lodash/_getMapData.js
1011
+ var require_getMapData = __commonJS({
1012
+ "../../node_modules/lodash/_getMapData.js"(exports, module2) {
1013
+ var isKeyable = require_isKeyable();
1014
+ function getMapData(map, key) {
1015
+ var data = map.__data__;
1016
+ return isKeyable(key) ? data[typeof key == "string" ? "string" : "hash"] : data.map;
1017
+ }
1018
+ module2.exports = getMapData;
1019
+ }
1020
+ });
1021
+
1022
+ // ../../node_modules/lodash/_mapCacheDelete.js
1023
+ var require_mapCacheDelete = __commonJS({
1024
+ "../../node_modules/lodash/_mapCacheDelete.js"(exports, module2) {
1025
+ var getMapData = require_getMapData();
1026
+ function mapCacheDelete(key) {
1027
+ var result = getMapData(this, key)["delete"](key);
1028
+ this.size -= result ? 1 : 0;
1029
+ return result;
1030
+ }
1031
+ module2.exports = mapCacheDelete;
1032
+ }
1033
+ });
1034
+
1035
+ // ../../node_modules/lodash/_mapCacheGet.js
1036
+ var require_mapCacheGet = __commonJS({
1037
+ "../../node_modules/lodash/_mapCacheGet.js"(exports, module2) {
1038
+ var getMapData = require_getMapData();
1039
+ function mapCacheGet(key) {
1040
+ return getMapData(this, key).get(key);
1041
+ }
1042
+ module2.exports = mapCacheGet;
1043
+ }
1044
+ });
1045
+
1046
+ // ../../node_modules/lodash/_mapCacheHas.js
1047
+ var require_mapCacheHas = __commonJS({
1048
+ "../../node_modules/lodash/_mapCacheHas.js"(exports, module2) {
1049
+ var getMapData = require_getMapData();
1050
+ function mapCacheHas(key) {
1051
+ return getMapData(this, key).has(key);
1052
+ }
1053
+ module2.exports = mapCacheHas;
1054
+ }
1055
+ });
1056
+
1057
+ // ../../node_modules/lodash/_mapCacheSet.js
1058
+ var require_mapCacheSet = __commonJS({
1059
+ "../../node_modules/lodash/_mapCacheSet.js"(exports, module2) {
1060
+ var getMapData = require_getMapData();
1061
+ function mapCacheSet(key, value) {
1062
+ var data = getMapData(this, key), size = data.size;
1063
+ data.set(key, value);
1064
+ this.size += data.size == size ? 0 : 1;
1065
+ return this;
1066
+ }
1067
+ module2.exports = mapCacheSet;
1068
+ }
1069
+ });
1070
+
1071
+ // ../../node_modules/lodash/_MapCache.js
1072
+ var require_MapCache = __commonJS({
1073
+ "../../node_modules/lodash/_MapCache.js"(exports, module2) {
1074
+ var mapCacheClear = require_mapCacheClear();
1075
+ var mapCacheDelete = require_mapCacheDelete();
1076
+ var mapCacheGet = require_mapCacheGet();
1077
+ var mapCacheHas = require_mapCacheHas();
1078
+ var mapCacheSet = require_mapCacheSet();
1079
+ function MapCache(entries) {
1080
+ var index = -1, length = entries == null ? 0 : entries.length;
1081
+ this.clear();
1082
+ while (++index < length) {
1083
+ var entry = entries[index];
1084
+ this.set(entry[0], entry[1]);
1085
+ }
1086
+ }
1087
+ MapCache.prototype.clear = mapCacheClear;
1088
+ MapCache.prototype["delete"] = mapCacheDelete;
1089
+ MapCache.prototype.get = mapCacheGet;
1090
+ MapCache.prototype.has = mapCacheHas;
1091
+ MapCache.prototype.set = mapCacheSet;
1092
+ module2.exports = MapCache;
1093
+ }
1094
+ });
1095
+
1096
+ // ../../node_modules/lodash/_stackSet.js
1097
+ var require_stackSet = __commonJS({
1098
+ "../../node_modules/lodash/_stackSet.js"(exports, module2) {
1099
+ var ListCache = require_ListCache();
1100
+ var Map2 = require_Map();
1101
+ var MapCache = require_MapCache();
1102
+ var LARGE_ARRAY_SIZE = 200;
1103
+ function stackSet(key, value) {
1104
+ var data = this.__data__;
1105
+ if (data instanceof ListCache) {
1106
+ var pairs = data.__data__;
1107
+ if (!Map2 || pairs.length < LARGE_ARRAY_SIZE - 1) {
1108
+ pairs.push([key, value]);
1109
+ this.size = ++data.size;
1110
+ return this;
1111
+ }
1112
+ data = this.__data__ = new MapCache(pairs);
1113
+ }
1114
+ data.set(key, value);
1115
+ this.size = data.size;
1116
+ return this;
1117
+ }
1118
+ module2.exports = stackSet;
1119
+ }
1120
+ });
1121
+
1122
+ // ../../node_modules/lodash/_Stack.js
1123
+ var require_Stack = __commonJS({
1124
+ "../../node_modules/lodash/_Stack.js"(exports, module2) {
1125
+ var ListCache = require_ListCache();
1126
+ var stackClear = require_stackClear();
1127
+ var stackDelete = require_stackDelete();
1128
+ var stackGet = require_stackGet();
1129
+ var stackHas = require_stackHas();
1130
+ var stackSet = require_stackSet();
1131
+ function Stack(entries) {
1132
+ var data = this.__data__ = new ListCache(entries);
1133
+ this.size = data.size;
1134
+ }
1135
+ Stack.prototype.clear = stackClear;
1136
+ Stack.prototype["delete"] = stackDelete;
1137
+ Stack.prototype.get = stackGet;
1138
+ Stack.prototype.has = stackHas;
1139
+ Stack.prototype.set = stackSet;
1140
+ module2.exports = Stack;
1141
+ }
1142
+ });
1143
+
1144
+ // ../../node_modules/lodash/_setCacheAdd.js
1145
+ var require_setCacheAdd = __commonJS({
1146
+ "../../node_modules/lodash/_setCacheAdd.js"(exports, module2) {
1147
+ var HASH_UNDEFINED = "__lodash_hash_undefined__";
1148
+ function setCacheAdd(value) {
1149
+ this.__data__.set(value, HASH_UNDEFINED);
1150
+ return this;
1151
+ }
1152
+ module2.exports = setCacheAdd;
1153
+ }
1154
+ });
1155
+
1156
+ // ../../node_modules/lodash/_setCacheHas.js
1157
+ var require_setCacheHas = __commonJS({
1158
+ "../../node_modules/lodash/_setCacheHas.js"(exports, module2) {
1159
+ function setCacheHas(value) {
1160
+ return this.__data__.has(value);
1161
+ }
1162
+ module2.exports = setCacheHas;
1163
+ }
1164
+ });
1165
+
1166
+ // ../../node_modules/lodash/_SetCache.js
1167
+ var require_SetCache = __commonJS({
1168
+ "../../node_modules/lodash/_SetCache.js"(exports, module2) {
1169
+ var MapCache = require_MapCache();
1170
+ var setCacheAdd = require_setCacheAdd();
1171
+ var setCacheHas = require_setCacheHas();
1172
+ function SetCache(values) {
1173
+ var index = -1, length = values == null ? 0 : values.length;
1174
+ this.__data__ = new MapCache();
1175
+ while (++index < length) {
1176
+ this.add(values[index]);
1177
+ }
1178
+ }
1179
+ SetCache.prototype.add = SetCache.prototype.push = setCacheAdd;
1180
+ SetCache.prototype.has = setCacheHas;
1181
+ module2.exports = SetCache;
1182
+ }
1183
+ });
1184
+
1185
+ // ../../node_modules/lodash/_arraySome.js
1186
+ var require_arraySome = __commonJS({
1187
+ "../../node_modules/lodash/_arraySome.js"(exports, module2) {
1188
+ function arraySome(array, predicate) {
1189
+ var index = -1, length = array == null ? 0 : array.length;
1190
+ while (++index < length) {
1191
+ if (predicate(array[index], index, array)) {
1192
+ return true;
1193
+ }
1194
+ }
1195
+ return false;
1196
+ }
1197
+ module2.exports = arraySome;
1198
+ }
1199
+ });
1200
+
1201
+ // ../../node_modules/lodash/_cacheHas.js
1202
+ var require_cacheHas = __commonJS({
1203
+ "../../node_modules/lodash/_cacheHas.js"(exports, module2) {
1204
+ function cacheHas(cache, key) {
1205
+ return cache.has(key);
1206
+ }
1207
+ module2.exports = cacheHas;
1208
+ }
1209
+ });
1210
+
1211
+ // ../../node_modules/lodash/_equalArrays.js
1212
+ var require_equalArrays = __commonJS({
1213
+ "../../node_modules/lodash/_equalArrays.js"(exports, module2) {
1214
+ var SetCache = require_SetCache();
1215
+ var arraySome = require_arraySome();
1216
+ var cacheHas = require_cacheHas();
1217
+ var COMPARE_PARTIAL_FLAG = 1;
1218
+ var COMPARE_UNORDERED_FLAG = 2;
1219
+ function equalArrays(array, other, bitmask, customizer, equalFunc, stack) {
1220
+ var isPartial = bitmask & COMPARE_PARTIAL_FLAG, arrLength = array.length, othLength = other.length;
1221
+ if (arrLength != othLength && !(isPartial && othLength > arrLength)) {
1222
+ return false;
1223
+ }
1224
+ var arrStacked = stack.get(array);
1225
+ var othStacked = stack.get(other);
1226
+ if (arrStacked && othStacked) {
1227
+ return arrStacked == other && othStacked == array;
1228
+ }
1229
+ var index = -1, result = true, seen = bitmask & COMPARE_UNORDERED_FLAG ? new SetCache() : void 0;
1230
+ stack.set(array, other);
1231
+ stack.set(other, array);
1232
+ while (++index < arrLength) {
1233
+ var arrValue = array[index], othValue = other[index];
1234
+ if (customizer) {
1235
+ var compared = isPartial ? customizer(othValue, arrValue, index, other, array, stack) : customizer(arrValue, othValue, index, array, other, stack);
1236
+ }
1237
+ if (compared !== void 0) {
1238
+ if (compared) {
1239
+ continue;
1240
+ }
1241
+ result = false;
1242
+ break;
1243
+ }
1244
+ if (seen) {
1245
+ if (!arraySome(other, function(othValue2, othIndex) {
1246
+ if (!cacheHas(seen, othIndex) && (arrValue === othValue2 || equalFunc(arrValue, othValue2, bitmask, customizer, stack))) {
1247
+ return seen.push(othIndex);
1248
+ }
1249
+ })) {
1250
+ result = false;
1251
+ break;
1252
+ }
1253
+ } else if (!(arrValue === othValue || equalFunc(arrValue, othValue, bitmask, customizer, stack))) {
1254
+ result = false;
1255
+ break;
1256
+ }
1257
+ }
1258
+ stack["delete"](array);
1259
+ stack["delete"](other);
1260
+ return result;
1261
+ }
1262
+ module2.exports = equalArrays;
1263
+ }
1264
+ });
1265
+
1266
+ // ../../node_modules/lodash/_Uint8Array.js
1267
+ var require_Uint8Array = __commonJS({
1268
+ "../../node_modules/lodash/_Uint8Array.js"(exports, module2) {
1269
+ var root = require_root();
1270
+ var Uint8Array2 = root.Uint8Array;
1271
+ module2.exports = Uint8Array2;
1272
+ }
1273
+ });
1274
+
1275
+ // ../../node_modules/lodash/_mapToArray.js
1276
+ var require_mapToArray = __commonJS({
1277
+ "../../node_modules/lodash/_mapToArray.js"(exports, module2) {
1278
+ function mapToArray(map) {
1279
+ var index = -1, result = Array(map.size);
1280
+ map.forEach(function(value, key) {
1281
+ result[++index] = [key, value];
1282
+ });
1283
+ return result;
1284
+ }
1285
+ module2.exports = mapToArray;
1286
+ }
1287
+ });
1288
+
1289
+ // ../../node_modules/lodash/_setToArray.js
1290
+ var require_setToArray = __commonJS({
1291
+ "../../node_modules/lodash/_setToArray.js"(exports, module2) {
1292
+ function setToArray(set) {
1293
+ var index = -1, result = Array(set.size);
1294
+ set.forEach(function(value) {
1295
+ result[++index] = value;
1296
+ });
1297
+ return result;
1298
+ }
1299
+ module2.exports = setToArray;
1300
+ }
1301
+ });
1302
+
1303
+ // ../../node_modules/lodash/_equalByTag.js
1304
+ var require_equalByTag = __commonJS({
1305
+ "../../node_modules/lodash/_equalByTag.js"(exports, module2) {
1306
+ var Symbol2 = require_Symbol();
1307
+ var Uint8Array2 = require_Uint8Array();
1308
+ var eq = require_eq();
1309
+ var equalArrays = require_equalArrays();
1310
+ var mapToArray = require_mapToArray();
1311
+ var setToArray = require_setToArray();
1312
+ var COMPARE_PARTIAL_FLAG = 1;
1313
+ var COMPARE_UNORDERED_FLAG = 2;
1314
+ var boolTag = "[object Boolean]";
1315
+ var dateTag = "[object Date]";
1316
+ var errorTag = "[object Error]";
1317
+ var mapTag = "[object Map]";
1318
+ var numberTag = "[object Number]";
1319
+ var regexpTag = "[object RegExp]";
1320
+ var setTag = "[object Set]";
1321
+ var stringTag = "[object String]";
1322
+ var symbolTag = "[object Symbol]";
1323
+ var arrayBufferTag = "[object ArrayBuffer]";
1324
+ var dataViewTag = "[object DataView]";
1325
+ var symbolProto = Symbol2 ? Symbol2.prototype : void 0;
1326
+ var symbolValueOf = symbolProto ? symbolProto.valueOf : void 0;
1327
+ function equalByTag(object, other, tag, bitmask, customizer, equalFunc, stack) {
1328
+ switch (tag) {
1329
+ case dataViewTag:
1330
+ if (object.byteLength != other.byteLength || object.byteOffset != other.byteOffset) {
1331
+ return false;
1332
+ }
1333
+ object = object.buffer;
1334
+ other = other.buffer;
1335
+ case arrayBufferTag:
1336
+ if (object.byteLength != other.byteLength || !equalFunc(new Uint8Array2(object), new Uint8Array2(other))) {
1337
+ return false;
1338
+ }
1339
+ return true;
1340
+ case boolTag:
1341
+ case dateTag:
1342
+ case numberTag:
1343
+ return eq(+object, +other);
1344
+ case errorTag:
1345
+ return object.name == other.name && object.message == other.message;
1346
+ case regexpTag:
1347
+ case stringTag:
1348
+ return object == other + "";
1349
+ case mapTag:
1350
+ var convert = mapToArray;
1351
+ case setTag:
1352
+ var isPartial = bitmask & COMPARE_PARTIAL_FLAG;
1353
+ convert || (convert = setToArray);
1354
+ if (object.size != other.size && !isPartial) {
1355
+ return false;
1356
+ }
1357
+ var stacked = stack.get(object);
1358
+ if (stacked) {
1359
+ return stacked == other;
1360
+ }
1361
+ bitmask |= COMPARE_UNORDERED_FLAG;
1362
+ stack.set(object, other);
1363
+ var result = equalArrays(convert(object), convert(other), bitmask, customizer, equalFunc, stack);
1364
+ stack["delete"](object);
1365
+ return result;
1366
+ case symbolTag:
1367
+ if (symbolValueOf) {
1368
+ return symbolValueOf.call(object) == symbolValueOf.call(other);
1369
+ }
1370
+ }
1371
+ return false;
1372
+ }
1373
+ module2.exports = equalByTag;
1374
+ }
1375
+ });
1376
+
1377
+ // ../../node_modules/lodash/_arrayPush.js
1378
+ var require_arrayPush = __commonJS({
1379
+ "../../node_modules/lodash/_arrayPush.js"(exports, module2) {
1380
+ function arrayPush(array, values) {
1381
+ var index = -1, length = values.length, offset = array.length;
1382
+ while (++index < length) {
1383
+ array[offset + index] = values[index];
1384
+ }
1385
+ return array;
1386
+ }
1387
+ module2.exports = arrayPush;
1388
+ }
1389
+ });
1390
+
1391
+ // ../../node_modules/lodash/_baseGetAllKeys.js
1392
+ var require_baseGetAllKeys = __commonJS({
1393
+ "../../node_modules/lodash/_baseGetAllKeys.js"(exports, module2) {
1394
+ var arrayPush = require_arrayPush();
1395
+ var isArray = require_isArray();
1396
+ function baseGetAllKeys(object, keysFunc, symbolsFunc) {
1397
+ var result = keysFunc(object);
1398
+ return isArray(object) ? result : arrayPush(result, symbolsFunc(object));
1399
+ }
1400
+ module2.exports = baseGetAllKeys;
1401
+ }
1402
+ });
1403
+
1404
+ // ../../node_modules/lodash/_arrayFilter.js
1405
+ var require_arrayFilter = __commonJS({
1406
+ "../../node_modules/lodash/_arrayFilter.js"(exports, module2) {
1407
+ function arrayFilter(array, predicate) {
1408
+ var index = -1, length = array == null ? 0 : array.length, resIndex = 0, result = [];
1409
+ while (++index < length) {
1410
+ var value = array[index];
1411
+ if (predicate(value, index, array)) {
1412
+ result[resIndex++] = value;
1413
+ }
1414
+ }
1415
+ return result;
1416
+ }
1417
+ module2.exports = arrayFilter;
1418
+ }
1419
+ });
1420
+
1421
+ // ../../node_modules/lodash/stubArray.js
1422
+ var require_stubArray = __commonJS({
1423
+ "../../node_modules/lodash/stubArray.js"(exports, module2) {
1424
+ function stubArray() {
1425
+ return [];
1426
+ }
1427
+ module2.exports = stubArray;
1428
+ }
1429
+ });
1430
+
1431
+ // ../../node_modules/lodash/_getSymbols.js
1432
+ var require_getSymbols = __commonJS({
1433
+ "../../node_modules/lodash/_getSymbols.js"(exports, module2) {
1434
+ var arrayFilter = require_arrayFilter();
1435
+ var stubArray = require_stubArray();
1436
+ var objectProto = Object.prototype;
1437
+ var propertyIsEnumerable = objectProto.propertyIsEnumerable;
1438
+ var nativeGetSymbols = Object.getOwnPropertySymbols;
1439
+ var getSymbols = !nativeGetSymbols ? stubArray : function(object) {
1440
+ if (object == null) {
1441
+ return [];
1442
+ }
1443
+ object = Object(object);
1444
+ return arrayFilter(nativeGetSymbols(object), function(symbol) {
1445
+ return propertyIsEnumerable.call(object, symbol);
1446
+ });
43
1447
  };
44
- var __copyProps2 = (to, from, except, desc) => {
45
- if (from && typeof from == "object" || typeof from == "function")
46
- for (let key of __getOwnPropNames2(from))
47
- !__hasOwnProp2.call(to, key) && key !== except && __defProp2(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc2(from, key)) || desc.enumerable });
48
- return to;
1448
+ module2.exports = getSymbols;
1449
+ }
1450
+ });
1451
+
1452
+ // ../../node_modules/lodash/_getAllKeys.js
1453
+ var require_getAllKeys = __commonJS({
1454
+ "../../node_modules/lodash/_getAllKeys.js"(exports, module2) {
1455
+ var baseGetAllKeys = require_baseGetAllKeys();
1456
+ var getSymbols = require_getSymbols();
1457
+ var keys = require_keys();
1458
+ function getAllKeys(object) {
1459
+ return baseGetAllKeys(object, keys, getSymbols);
1460
+ }
1461
+ module2.exports = getAllKeys;
1462
+ }
1463
+ });
1464
+
1465
+ // ../../node_modules/lodash/_equalObjects.js
1466
+ var require_equalObjects = __commonJS({
1467
+ "../../node_modules/lodash/_equalObjects.js"(exports, module2) {
1468
+ var getAllKeys = require_getAllKeys();
1469
+ var COMPARE_PARTIAL_FLAG = 1;
1470
+ var objectProto = Object.prototype;
1471
+ var hasOwnProperty = objectProto.hasOwnProperty;
1472
+ function equalObjects(object, other, bitmask, customizer, equalFunc, stack) {
1473
+ var isPartial = bitmask & COMPARE_PARTIAL_FLAG, objProps = getAllKeys(object), objLength = objProps.length, othProps = getAllKeys(other), othLength = othProps.length;
1474
+ if (objLength != othLength && !isPartial) {
1475
+ return false;
1476
+ }
1477
+ var index = objLength;
1478
+ while (index--) {
1479
+ var key = objProps[index];
1480
+ if (!(isPartial ? key in other : hasOwnProperty.call(other, key))) {
1481
+ return false;
1482
+ }
1483
+ }
1484
+ var objStacked = stack.get(object);
1485
+ var othStacked = stack.get(other);
1486
+ if (objStacked && othStacked) {
1487
+ return objStacked == other && othStacked == object;
1488
+ }
1489
+ var result = true;
1490
+ stack.set(object, other);
1491
+ stack.set(other, object);
1492
+ var skipCtor = isPartial;
1493
+ while (++index < objLength) {
1494
+ key = objProps[index];
1495
+ var objValue = object[key], othValue = other[key];
1496
+ if (customizer) {
1497
+ var compared = isPartial ? customizer(othValue, objValue, key, other, object, stack) : customizer(objValue, othValue, key, object, other, stack);
1498
+ }
1499
+ if (!(compared === void 0 ? objValue === othValue || equalFunc(objValue, othValue, bitmask, customizer, stack) : compared)) {
1500
+ result = false;
1501
+ break;
1502
+ }
1503
+ skipCtor || (skipCtor = key == "constructor");
1504
+ }
1505
+ if (result && !skipCtor) {
1506
+ var objCtor = object.constructor, othCtor = other.constructor;
1507
+ if (objCtor != othCtor && ("constructor" in object && "constructor" in other) && !(typeof objCtor == "function" && objCtor instanceof objCtor && typeof othCtor == "function" && othCtor instanceof othCtor)) {
1508
+ result = false;
1509
+ }
1510
+ }
1511
+ stack["delete"](object);
1512
+ stack["delete"](other);
1513
+ return result;
1514
+ }
1515
+ module2.exports = equalObjects;
1516
+ }
1517
+ });
1518
+
1519
+ // ../../node_modules/lodash/_DataView.js
1520
+ var require_DataView = __commonJS({
1521
+ "../../node_modules/lodash/_DataView.js"(exports, module2) {
1522
+ var getNative = require_getNative();
1523
+ var root = require_root();
1524
+ var DataView = getNative(root, "DataView");
1525
+ module2.exports = DataView;
1526
+ }
1527
+ });
1528
+
1529
+ // ../../node_modules/lodash/_Promise.js
1530
+ var require_Promise = __commonJS({
1531
+ "../../node_modules/lodash/_Promise.js"(exports, module2) {
1532
+ var getNative = require_getNative();
1533
+ var root = require_root();
1534
+ var Promise2 = getNative(root, "Promise");
1535
+ module2.exports = Promise2;
1536
+ }
1537
+ });
1538
+
1539
+ // ../../node_modules/lodash/_Set.js
1540
+ var require_Set = __commonJS({
1541
+ "../../node_modules/lodash/_Set.js"(exports, module2) {
1542
+ var getNative = require_getNative();
1543
+ var root = require_root();
1544
+ var Set2 = getNative(root, "Set");
1545
+ module2.exports = Set2;
1546
+ }
1547
+ });
1548
+
1549
+ // ../../node_modules/lodash/_WeakMap.js
1550
+ var require_WeakMap = __commonJS({
1551
+ "../../node_modules/lodash/_WeakMap.js"(exports, module2) {
1552
+ var getNative = require_getNative();
1553
+ var root = require_root();
1554
+ var WeakMap2 = getNative(root, "WeakMap");
1555
+ module2.exports = WeakMap2;
1556
+ }
1557
+ });
1558
+
1559
+ // ../../node_modules/lodash/_getTag.js
1560
+ var require_getTag = __commonJS({
1561
+ "../../node_modules/lodash/_getTag.js"(exports, module2) {
1562
+ var DataView = require_DataView();
1563
+ var Map2 = require_Map();
1564
+ var Promise2 = require_Promise();
1565
+ var Set2 = require_Set();
1566
+ var WeakMap2 = require_WeakMap();
1567
+ var baseGetTag = require_baseGetTag();
1568
+ var toSource = require_toSource();
1569
+ var mapTag = "[object Map]";
1570
+ var objectTag = "[object Object]";
1571
+ var promiseTag = "[object Promise]";
1572
+ var setTag = "[object Set]";
1573
+ var weakMapTag = "[object WeakMap]";
1574
+ var dataViewTag = "[object DataView]";
1575
+ var dataViewCtorString = toSource(DataView);
1576
+ var mapCtorString = toSource(Map2);
1577
+ var promiseCtorString = toSource(Promise2);
1578
+ var setCtorString = toSource(Set2);
1579
+ var weakMapCtorString = toSource(WeakMap2);
1580
+ var getTag = baseGetTag;
1581
+ if (DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag || Map2 && getTag(new Map2()) != mapTag || Promise2 && getTag(Promise2.resolve()) != promiseTag || Set2 && getTag(new Set2()) != setTag || WeakMap2 && getTag(new WeakMap2()) != weakMapTag) {
1582
+ getTag = function(value) {
1583
+ var result = baseGetTag(value), Ctor = result == objectTag ? value.constructor : void 0, ctorString = Ctor ? toSource(Ctor) : "";
1584
+ if (ctorString) {
1585
+ switch (ctorString) {
1586
+ case dataViewCtorString:
1587
+ return dataViewTag;
1588
+ case mapCtorString:
1589
+ return mapTag;
1590
+ case promiseCtorString:
1591
+ return promiseTag;
1592
+ case setCtorString:
1593
+ return setTag;
1594
+ case weakMapCtorString:
1595
+ return weakMapTag;
1596
+ }
1597
+ }
1598
+ return result;
1599
+ };
1600
+ }
1601
+ module2.exports = getTag;
1602
+ }
1603
+ });
1604
+
1605
+ // ../../node_modules/lodash/_baseIsEqualDeep.js
1606
+ var require_baseIsEqualDeep = __commonJS({
1607
+ "../../node_modules/lodash/_baseIsEqualDeep.js"(exports, module2) {
1608
+ var Stack = require_Stack();
1609
+ var equalArrays = require_equalArrays();
1610
+ var equalByTag = require_equalByTag();
1611
+ var equalObjects = require_equalObjects();
1612
+ var getTag = require_getTag();
1613
+ var isArray = require_isArray();
1614
+ var isBuffer = require_isBuffer();
1615
+ var isTypedArray = require_isTypedArray();
1616
+ var COMPARE_PARTIAL_FLAG = 1;
1617
+ var argsTag = "[object Arguments]";
1618
+ var arrayTag = "[object Array]";
1619
+ var objectTag = "[object Object]";
1620
+ var objectProto = Object.prototype;
1621
+ var hasOwnProperty = objectProto.hasOwnProperty;
1622
+ function baseIsEqualDeep(object, other, bitmask, customizer, equalFunc, stack) {
1623
+ var objIsArr = isArray(object), othIsArr = isArray(other), objTag = objIsArr ? arrayTag : getTag(object), othTag = othIsArr ? arrayTag : getTag(other);
1624
+ objTag = objTag == argsTag ? objectTag : objTag;
1625
+ othTag = othTag == argsTag ? objectTag : othTag;
1626
+ var objIsObj = objTag == objectTag, othIsObj = othTag == objectTag, isSameTag = objTag == othTag;
1627
+ if (isSameTag && isBuffer(object)) {
1628
+ if (!isBuffer(other)) {
1629
+ return false;
1630
+ }
1631
+ objIsArr = true;
1632
+ objIsObj = false;
1633
+ }
1634
+ if (isSameTag && !objIsObj) {
1635
+ stack || (stack = new Stack());
1636
+ return objIsArr || isTypedArray(object) ? equalArrays(object, other, bitmask, customizer, equalFunc, stack) : equalByTag(object, other, objTag, bitmask, customizer, equalFunc, stack);
1637
+ }
1638
+ if (!(bitmask & COMPARE_PARTIAL_FLAG)) {
1639
+ var objIsWrapped = objIsObj && hasOwnProperty.call(object, "__wrapped__"), othIsWrapped = othIsObj && hasOwnProperty.call(other, "__wrapped__");
1640
+ if (objIsWrapped || othIsWrapped) {
1641
+ var objUnwrapped = objIsWrapped ? object.value() : object, othUnwrapped = othIsWrapped ? other.value() : other;
1642
+ stack || (stack = new Stack());
1643
+ return equalFunc(objUnwrapped, othUnwrapped, bitmask, customizer, stack);
1644
+ }
1645
+ }
1646
+ if (!isSameTag) {
1647
+ return false;
1648
+ }
1649
+ stack || (stack = new Stack());
1650
+ return equalObjects(object, other, bitmask, customizer, equalFunc, stack);
1651
+ }
1652
+ module2.exports = baseIsEqualDeep;
1653
+ }
1654
+ });
1655
+
1656
+ // ../../node_modules/lodash/_baseIsEqual.js
1657
+ var require_baseIsEqual = __commonJS({
1658
+ "../../node_modules/lodash/_baseIsEqual.js"(exports, module2) {
1659
+ var baseIsEqualDeep = require_baseIsEqualDeep();
1660
+ var isObjectLike = require_isObjectLike();
1661
+ function baseIsEqual(value, other, bitmask, customizer, stack) {
1662
+ if (value === other) {
1663
+ return true;
1664
+ }
1665
+ if (value == null || other == null || !isObjectLike(value) && !isObjectLike(other)) {
1666
+ return value !== value && other !== other;
1667
+ }
1668
+ return baseIsEqualDeep(value, other, bitmask, customizer, baseIsEqual, stack);
1669
+ }
1670
+ module2.exports = baseIsEqual;
1671
+ }
1672
+ });
1673
+
1674
+ // ../../node_modules/lodash/_baseIsMatch.js
1675
+ var require_baseIsMatch = __commonJS({
1676
+ "../../node_modules/lodash/_baseIsMatch.js"(exports, module2) {
1677
+ var Stack = require_Stack();
1678
+ var baseIsEqual = require_baseIsEqual();
1679
+ var COMPARE_PARTIAL_FLAG = 1;
1680
+ var COMPARE_UNORDERED_FLAG = 2;
1681
+ function baseIsMatch(object, source, matchData, customizer) {
1682
+ var index = matchData.length, length = index, noCustomizer = !customizer;
1683
+ if (object == null) {
1684
+ return !length;
1685
+ }
1686
+ object = Object(object);
1687
+ while (index--) {
1688
+ var data = matchData[index];
1689
+ if (noCustomizer && data[2] ? data[1] !== object[data[0]] : !(data[0] in object)) {
1690
+ return false;
1691
+ }
1692
+ }
1693
+ while (++index < length) {
1694
+ data = matchData[index];
1695
+ var key = data[0], objValue = object[key], srcValue = data[1];
1696
+ if (noCustomizer && data[2]) {
1697
+ if (objValue === void 0 && !(key in object)) {
1698
+ return false;
1699
+ }
1700
+ } else {
1701
+ var stack = new Stack();
1702
+ if (customizer) {
1703
+ var result = customizer(objValue, srcValue, key, object, source, stack);
1704
+ }
1705
+ if (!(result === void 0 ? baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG, customizer, stack) : result)) {
1706
+ return false;
1707
+ }
1708
+ }
1709
+ }
1710
+ return true;
1711
+ }
1712
+ module2.exports = baseIsMatch;
1713
+ }
1714
+ });
1715
+
1716
+ // ../../node_modules/lodash/_isStrictComparable.js
1717
+ var require_isStrictComparable = __commonJS({
1718
+ "../../node_modules/lodash/_isStrictComparable.js"(exports, module2) {
1719
+ var isObject = require_isObject();
1720
+ function isStrictComparable(value) {
1721
+ return value === value && !isObject(value);
1722
+ }
1723
+ module2.exports = isStrictComparable;
1724
+ }
1725
+ });
1726
+
1727
+ // ../../node_modules/lodash/_getMatchData.js
1728
+ var require_getMatchData = __commonJS({
1729
+ "../../node_modules/lodash/_getMatchData.js"(exports, module2) {
1730
+ var isStrictComparable = require_isStrictComparable();
1731
+ var keys = require_keys();
1732
+ function getMatchData(object) {
1733
+ var result = keys(object), length = result.length;
1734
+ while (length--) {
1735
+ var key = result[length], value = object[key];
1736
+ result[length] = [key, value, isStrictComparable(value)];
1737
+ }
1738
+ return result;
1739
+ }
1740
+ module2.exports = getMatchData;
1741
+ }
1742
+ });
1743
+
1744
+ // ../../node_modules/lodash/_matchesStrictComparable.js
1745
+ var require_matchesStrictComparable = __commonJS({
1746
+ "../../node_modules/lodash/_matchesStrictComparable.js"(exports, module2) {
1747
+ function matchesStrictComparable(key, srcValue) {
1748
+ return function(object) {
1749
+ if (object == null) {
1750
+ return false;
1751
+ }
1752
+ return object[key] === srcValue && (srcValue !== void 0 || key in Object(object));
1753
+ };
1754
+ }
1755
+ module2.exports = matchesStrictComparable;
1756
+ }
1757
+ });
1758
+
1759
+ // ../../node_modules/lodash/_baseMatches.js
1760
+ var require_baseMatches = __commonJS({
1761
+ "../../node_modules/lodash/_baseMatches.js"(exports, module2) {
1762
+ var baseIsMatch = require_baseIsMatch();
1763
+ var getMatchData = require_getMatchData();
1764
+ var matchesStrictComparable = require_matchesStrictComparable();
1765
+ function baseMatches(source) {
1766
+ var matchData = getMatchData(source);
1767
+ if (matchData.length == 1 && matchData[0][2]) {
1768
+ return matchesStrictComparable(matchData[0][0], matchData[0][1]);
1769
+ }
1770
+ return function(object) {
1771
+ return object === source || baseIsMatch(object, source, matchData);
1772
+ };
1773
+ }
1774
+ module2.exports = baseMatches;
1775
+ }
1776
+ });
1777
+
1778
+ // ../../node_modules/lodash/isSymbol.js
1779
+ var require_isSymbol = __commonJS({
1780
+ "../../node_modules/lodash/isSymbol.js"(exports, module2) {
1781
+ var baseGetTag = require_baseGetTag();
1782
+ var isObjectLike = require_isObjectLike();
1783
+ var symbolTag = "[object Symbol]";
1784
+ function isSymbol(value) {
1785
+ return typeof value == "symbol" || isObjectLike(value) && baseGetTag(value) == symbolTag;
1786
+ }
1787
+ module2.exports = isSymbol;
1788
+ }
1789
+ });
1790
+
1791
+ // ../../node_modules/lodash/_isKey.js
1792
+ var require_isKey = __commonJS({
1793
+ "../../node_modules/lodash/_isKey.js"(exports, module2) {
1794
+ var isArray = require_isArray();
1795
+ var isSymbol = require_isSymbol();
1796
+ var reIsDeepProp = /\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/;
1797
+ var reIsPlainProp = /^\w*$/;
1798
+ function isKey(value, object) {
1799
+ if (isArray(value)) {
1800
+ return false;
1801
+ }
1802
+ var type = typeof value;
1803
+ if (type == "number" || type == "symbol" || type == "boolean" || value == null || isSymbol(value)) {
1804
+ return true;
1805
+ }
1806
+ return reIsPlainProp.test(value) || !reIsDeepProp.test(value) || object != null && value in Object(object);
1807
+ }
1808
+ module2.exports = isKey;
1809
+ }
1810
+ });
1811
+
1812
+ // ../../node_modules/lodash/memoize.js
1813
+ var require_memoize = __commonJS({
1814
+ "../../node_modules/lodash/memoize.js"(exports, module2) {
1815
+ var MapCache = require_MapCache();
1816
+ var FUNC_ERROR_TEXT = "Expected a function";
1817
+ function memoize(func, resolver) {
1818
+ if (typeof func != "function" || resolver != null && typeof resolver != "function") {
1819
+ throw new TypeError(FUNC_ERROR_TEXT);
1820
+ }
1821
+ var memoized = function() {
1822
+ var args = arguments, key = resolver ? resolver.apply(this, args) : args[0], cache = memoized.cache;
1823
+ if (cache.has(key)) {
1824
+ return cache.get(key);
1825
+ }
1826
+ var result = func.apply(this, args);
1827
+ memoized.cache = cache.set(key, result) || cache;
1828
+ return result;
1829
+ };
1830
+ memoized.cache = new (memoize.Cache || MapCache)();
1831
+ return memoized;
1832
+ }
1833
+ memoize.Cache = MapCache;
1834
+ module2.exports = memoize;
1835
+ }
1836
+ });
1837
+
1838
+ // ../../node_modules/lodash/_memoizeCapped.js
1839
+ var require_memoizeCapped = __commonJS({
1840
+ "../../node_modules/lodash/_memoizeCapped.js"(exports, module2) {
1841
+ var memoize = require_memoize();
1842
+ var MAX_MEMOIZE_SIZE = 500;
1843
+ function memoizeCapped(func) {
1844
+ var result = memoize(func, function(key) {
1845
+ if (cache.size === MAX_MEMOIZE_SIZE) {
1846
+ cache.clear();
1847
+ }
1848
+ return key;
1849
+ });
1850
+ var cache = result.cache;
1851
+ return result;
1852
+ }
1853
+ module2.exports = memoizeCapped;
1854
+ }
1855
+ });
1856
+
1857
+ // ../../node_modules/lodash/_stringToPath.js
1858
+ var require_stringToPath = __commonJS({
1859
+ "../../node_modules/lodash/_stringToPath.js"(exports, module2) {
1860
+ var memoizeCapped = require_memoizeCapped();
1861
+ var rePropName = /[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g;
1862
+ var reEscapeChar = /\\(\\)?/g;
1863
+ var stringToPath = memoizeCapped(function(string) {
1864
+ var result = [];
1865
+ if (string.charCodeAt(0) === 46) {
1866
+ result.push("");
1867
+ }
1868
+ string.replace(rePropName, function(match, number, quote, subString) {
1869
+ result.push(quote ? subString.replace(reEscapeChar, "$1") : number || match);
1870
+ });
1871
+ return result;
1872
+ });
1873
+ module2.exports = stringToPath;
1874
+ }
1875
+ });
1876
+
1877
+ // ../../node_modules/lodash/_arrayMap.js
1878
+ var require_arrayMap = __commonJS({
1879
+ "../../node_modules/lodash/_arrayMap.js"(exports, module2) {
1880
+ function arrayMap(array, iteratee) {
1881
+ var index = -1, length = array == null ? 0 : array.length, result = Array(length);
1882
+ while (++index < length) {
1883
+ result[index] = iteratee(array[index], index, array);
1884
+ }
1885
+ return result;
1886
+ }
1887
+ module2.exports = arrayMap;
1888
+ }
1889
+ });
1890
+
1891
+ // ../../node_modules/lodash/_baseToString.js
1892
+ var require_baseToString = __commonJS({
1893
+ "../../node_modules/lodash/_baseToString.js"(exports, module2) {
1894
+ var Symbol2 = require_Symbol();
1895
+ var arrayMap = require_arrayMap();
1896
+ var isArray = require_isArray();
1897
+ var isSymbol = require_isSymbol();
1898
+ var INFINITY = 1 / 0;
1899
+ var symbolProto = Symbol2 ? Symbol2.prototype : void 0;
1900
+ var symbolToString = symbolProto ? symbolProto.toString : void 0;
1901
+ function baseToString(value) {
1902
+ if (typeof value == "string") {
1903
+ return value;
1904
+ }
1905
+ if (isArray(value)) {
1906
+ return arrayMap(value, baseToString) + "";
1907
+ }
1908
+ if (isSymbol(value)) {
1909
+ return symbolToString ? symbolToString.call(value) : "";
1910
+ }
1911
+ var result = value + "";
1912
+ return result == "0" && 1 / value == -INFINITY ? "-0" : result;
1913
+ }
1914
+ module2.exports = baseToString;
1915
+ }
1916
+ });
1917
+
1918
+ // ../../node_modules/lodash/toString.js
1919
+ var require_toString = __commonJS({
1920
+ "../../node_modules/lodash/toString.js"(exports, module2) {
1921
+ var baseToString = require_baseToString();
1922
+ function toString(value) {
1923
+ return value == null ? "" : baseToString(value);
1924
+ }
1925
+ module2.exports = toString;
1926
+ }
1927
+ });
1928
+
1929
+ // ../../node_modules/lodash/_castPath.js
1930
+ var require_castPath = __commonJS({
1931
+ "../../node_modules/lodash/_castPath.js"(exports, module2) {
1932
+ var isArray = require_isArray();
1933
+ var isKey = require_isKey();
1934
+ var stringToPath = require_stringToPath();
1935
+ var toString = require_toString();
1936
+ function castPath(value, object) {
1937
+ if (isArray(value)) {
1938
+ return value;
1939
+ }
1940
+ return isKey(value, object) ? [value] : stringToPath(toString(value));
1941
+ }
1942
+ module2.exports = castPath;
1943
+ }
1944
+ });
1945
+
1946
+ // ../../node_modules/lodash/_toKey.js
1947
+ var require_toKey = __commonJS({
1948
+ "../../node_modules/lodash/_toKey.js"(exports, module2) {
1949
+ var isSymbol = require_isSymbol();
1950
+ var INFINITY = 1 / 0;
1951
+ function toKey(value) {
1952
+ if (typeof value == "string" || isSymbol(value)) {
1953
+ return value;
1954
+ }
1955
+ var result = value + "";
1956
+ return result == "0" && 1 / value == -INFINITY ? "-0" : result;
1957
+ }
1958
+ module2.exports = toKey;
1959
+ }
1960
+ });
1961
+
1962
+ // ../../node_modules/lodash/_baseGet.js
1963
+ var require_baseGet = __commonJS({
1964
+ "../../node_modules/lodash/_baseGet.js"(exports, module2) {
1965
+ var castPath = require_castPath();
1966
+ var toKey = require_toKey();
1967
+ function baseGet(object, path) {
1968
+ path = castPath(path, object);
1969
+ var index = 0, length = path.length;
1970
+ while (object != null && index < length) {
1971
+ object = object[toKey(path[index++])];
1972
+ }
1973
+ return index && index == length ? object : void 0;
1974
+ }
1975
+ module2.exports = baseGet;
1976
+ }
1977
+ });
1978
+
1979
+ // ../../node_modules/lodash/get.js
1980
+ var require_get = __commonJS({
1981
+ "../../node_modules/lodash/get.js"(exports, module2) {
1982
+ var baseGet = require_baseGet();
1983
+ function get(object, path, defaultValue) {
1984
+ var result = object == null ? void 0 : baseGet(object, path);
1985
+ return result === void 0 ? defaultValue : result;
1986
+ }
1987
+ module2.exports = get;
1988
+ }
1989
+ });
1990
+
1991
+ // ../../node_modules/lodash/_baseHasIn.js
1992
+ var require_baseHasIn = __commonJS({
1993
+ "../../node_modules/lodash/_baseHasIn.js"(exports, module2) {
1994
+ function baseHasIn(object, key) {
1995
+ return object != null && key in Object(object);
1996
+ }
1997
+ module2.exports = baseHasIn;
1998
+ }
1999
+ });
2000
+
2001
+ // ../../node_modules/lodash/_hasPath.js
2002
+ var require_hasPath = __commonJS({
2003
+ "../../node_modules/lodash/_hasPath.js"(exports, module2) {
2004
+ var castPath = require_castPath();
2005
+ var isArguments = require_isArguments();
2006
+ var isArray = require_isArray();
2007
+ var isIndex = require_isIndex();
2008
+ var isLength = require_isLength();
2009
+ var toKey = require_toKey();
2010
+ function hasPath(object, path, hasFunc) {
2011
+ path = castPath(path, object);
2012
+ var index = -1, length = path.length, result = false;
2013
+ while (++index < length) {
2014
+ var key = toKey(path[index]);
2015
+ if (!(result = object != null && hasFunc(object, key))) {
2016
+ break;
2017
+ }
2018
+ object = object[key];
2019
+ }
2020
+ if (result || ++index != length) {
2021
+ return result;
2022
+ }
2023
+ length = object == null ? 0 : object.length;
2024
+ return !!length && isLength(length) && isIndex(key, length) && (isArray(object) || isArguments(object));
2025
+ }
2026
+ module2.exports = hasPath;
2027
+ }
2028
+ });
2029
+
2030
+ // ../../node_modules/lodash/hasIn.js
2031
+ var require_hasIn = __commonJS({
2032
+ "../../node_modules/lodash/hasIn.js"(exports, module2) {
2033
+ var baseHasIn = require_baseHasIn();
2034
+ var hasPath = require_hasPath();
2035
+ function hasIn(object, path) {
2036
+ return object != null && hasPath(object, path, baseHasIn);
2037
+ }
2038
+ module2.exports = hasIn;
2039
+ }
2040
+ });
2041
+
2042
+ // ../../node_modules/lodash/_baseMatchesProperty.js
2043
+ var require_baseMatchesProperty = __commonJS({
2044
+ "../../node_modules/lodash/_baseMatchesProperty.js"(exports, module2) {
2045
+ var baseIsEqual = require_baseIsEqual();
2046
+ var get = require_get();
2047
+ var hasIn = require_hasIn();
2048
+ var isKey = require_isKey();
2049
+ var isStrictComparable = require_isStrictComparable();
2050
+ var matchesStrictComparable = require_matchesStrictComparable();
2051
+ var toKey = require_toKey();
2052
+ var COMPARE_PARTIAL_FLAG = 1;
2053
+ var COMPARE_UNORDERED_FLAG = 2;
2054
+ function baseMatchesProperty(path, srcValue) {
2055
+ if (isKey(path) && isStrictComparable(srcValue)) {
2056
+ return matchesStrictComparable(toKey(path), srcValue);
2057
+ }
2058
+ return function(object) {
2059
+ var objValue = get(object, path);
2060
+ return objValue === void 0 && objValue === srcValue ? hasIn(object, path) : baseIsEqual(srcValue, objValue, COMPARE_PARTIAL_FLAG | COMPARE_UNORDERED_FLAG);
2061
+ };
2062
+ }
2063
+ module2.exports = baseMatchesProperty;
2064
+ }
2065
+ });
2066
+
2067
+ // ../../node_modules/lodash/identity.js
2068
+ var require_identity = __commonJS({
2069
+ "../../node_modules/lodash/identity.js"(exports, module2) {
2070
+ function identity(value) {
2071
+ return value;
2072
+ }
2073
+ module2.exports = identity;
2074
+ }
2075
+ });
2076
+
2077
+ // ../../node_modules/lodash/_baseProperty.js
2078
+ var require_baseProperty = __commonJS({
2079
+ "../../node_modules/lodash/_baseProperty.js"(exports, module2) {
2080
+ function baseProperty(key) {
2081
+ return function(object) {
2082
+ return object == null ? void 0 : object[key];
2083
+ };
2084
+ }
2085
+ module2.exports = baseProperty;
2086
+ }
2087
+ });
2088
+
2089
+ // ../../node_modules/lodash/_basePropertyDeep.js
2090
+ var require_basePropertyDeep = __commonJS({
2091
+ "../../node_modules/lodash/_basePropertyDeep.js"(exports, module2) {
2092
+ var baseGet = require_baseGet();
2093
+ function basePropertyDeep(path) {
2094
+ return function(object) {
2095
+ return baseGet(object, path);
2096
+ };
2097
+ }
2098
+ module2.exports = basePropertyDeep;
2099
+ }
2100
+ });
2101
+
2102
+ // ../../node_modules/lodash/property.js
2103
+ var require_property = __commonJS({
2104
+ "../../node_modules/lodash/property.js"(exports, module2) {
2105
+ var baseProperty = require_baseProperty();
2106
+ var basePropertyDeep = require_basePropertyDeep();
2107
+ var isKey = require_isKey();
2108
+ var toKey = require_toKey();
2109
+ function property(path) {
2110
+ return isKey(path) ? baseProperty(toKey(path)) : basePropertyDeep(path);
2111
+ }
2112
+ module2.exports = property;
2113
+ }
2114
+ });
2115
+
2116
+ // ../../node_modules/lodash/_baseIteratee.js
2117
+ var require_baseIteratee = __commonJS({
2118
+ "../../node_modules/lodash/_baseIteratee.js"(exports, module2) {
2119
+ var baseMatches = require_baseMatches();
2120
+ var baseMatchesProperty = require_baseMatchesProperty();
2121
+ var identity = require_identity();
2122
+ var isArray = require_isArray();
2123
+ var property = require_property();
2124
+ function baseIteratee(value) {
2125
+ if (typeof value == "function") {
2126
+ return value;
2127
+ }
2128
+ if (value == null) {
2129
+ return identity;
2130
+ }
2131
+ if (typeof value == "object") {
2132
+ return isArray(value) ? baseMatchesProperty(value[0], value[1]) : baseMatches(value);
2133
+ }
2134
+ return property(value);
2135
+ }
2136
+ module2.exports = baseIteratee;
2137
+ }
2138
+ });
2139
+
2140
+ // ../../node_modules/lodash/_createAggregator.js
2141
+ var require_createAggregator = __commonJS({
2142
+ "../../node_modules/lodash/_createAggregator.js"(exports, module2) {
2143
+ var arrayAggregator = require_arrayAggregator();
2144
+ var baseAggregator = require_baseAggregator();
2145
+ var baseIteratee = require_baseIteratee();
2146
+ var isArray = require_isArray();
2147
+ function createAggregator(setter, initializer) {
2148
+ return function(collection, iteratee) {
2149
+ var func = isArray(collection) ? arrayAggregator : baseAggregator, accumulator = initializer ? initializer() : {};
2150
+ return func(collection, setter, baseIteratee(iteratee, 2), accumulator);
2151
+ };
2152
+ }
2153
+ module2.exports = createAggregator;
2154
+ }
2155
+ });
2156
+
2157
+ // ../../node_modules/lodash/countBy.js
2158
+ var require_countBy = __commonJS({
2159
+ "../../node_modules/lodash/countBy.js"(exports, module2) {
2160
+ var baseAssignValue = require_baseAssignValue();
2161
+ var createAggregator = require_createAggregator();
2162
+ var objectProto = Object.prototype;
2163
+ var hasOwnProperty = objectProto.hasOwnProperty;
2164
+ var countBy2 = createAggregator(function(result, value, key) {
2165
+ if (hasOwnProperty.call(result, key)) {
2166
+ ++result[key];
2167
+ } else {
2168
+ baseAssignValue(result, key, 1);
2169
+ }
2170
+ });
2171
+ module2.exports = countBy2;
2172
+ }
2173
+ });
2174
+
2175
+ // ../../node_modules/lodash/isEqual.js
2176
+ var require_isEqual = __commonJS({
2177
+ "../../node_modules/lodash/isEqual.js"(exports, module2) {
2178
+ var baseIsEqual = require_baseIsEqual();
2179
+ function isEqual2(value, other) {
2180
+ return baseIsEqual(value, other);
2181
+ }
2182
+ module2.exports = isEqual2;
2183
+ }
2184
+ });
2185
+
2186
+ // ../../node_modules/lodash/_assignMergeValue.js
2187
+ var require_assignMergeValue = __commonJS({
2188
+ "../../node_modules/lodash/_assignMergeValue.js"(exports, module2) {
2189
+ var baseAssignValue = require_baseAssignValue();
2190
+ var eq = require_eq();
2191
+ function assignMergeValue(object, key, value) {
2192
+ if (value !== void 0 && !eq(object[key], value) || value === void 0 && !(key in object)) {
2193
+ baseAssignValue(object, key, value);
2194
+ }
2195
+ }
2196
+ module2.exports = assignMergeValue;
2197
+ }
2198
+ });
2199
+
2200
+ // ../../node_modules/lodash/_cloneBuffer.js
2201
+ var require_cloneBuffer = __commonJS({
2202
+ "../../node_modules/lodash/_cloneBuffer.js"(exports, module2) {
2203
+ var root = require_root();
2204
+ var freeExports = typeof exports == "object" && exports && !exports.nodeType && exports;
2205
+ var freeModule = freeExports && typeof module2 == "object" && module2 && !module2.nodeType && module2;
2206
+ var moduleExports = freeModule && freeModule.exports === freeExports;
2207
+ var Buffer2 = moduleExports ? root.Buffer : void 0;
2208
+ var allocUnsafe = Buffer2 ? Buffer2.allocUnsafe : void 0;
2209
+ function cloneBuffer(buffer, isDeep) {
2210
+ if (isDeep) {
2211
+ return buffer.slice();
2212
+ }
2213
+ var length = buffer.length, result = allocUnsafe ? allocUnsafe(length) : new buffer.constructor(length);
2214
+ buffer.copy(result);
2215
+ return result;
2216
+ }
2217
+ module2.exports = cloneBuffer;
2218
+ }
2219
+ });
2220
+
2221
+ // ../../node_modules/lodash/_cloneArrayBuffer.js
2222
+ var require_cloneArrayBuffer = __commonJS({
2223
+ "../../node_modules/lodash/_cloneArrayBuffer.js"(exports, module2) {
2224
+ var Uint8Array2 = require_Uint8Array();
2225
+ function cloneArrayBuffer(arrayBuffer) {
2226
+ var result = new arrayBuffer.constructor(arrayBuffer.byteLength);
2227
+ new Uint8Array2(result).set(new Uint8Array2(arrayBuffer));
2228
+ return result;
2229
+ }
2230
+ module2.exports = cloneArrayBuffer;
2231
+ }
2232
+ });
2233
+
2234
+ // ../../node_modules/lodash/_cloneTypedArray.js
2235
+ var require_cloneTypedArray = __commonJS({
2236
+ "../../node_modules/lodash/_cloneTypedArray.js"(exports, module2) {
2237
+ var cloneArrayBuffer = require_cloneArrayBuffer();
2238
+ function cloneTypedArray(typedArray, isDeep) {
2239
+ var buffer = isDeep ? cloneArrayBuffer(typedArray.buffer) : typedArray.buffer;
2240
+ return new typedArray.constructor(buffer, typedArray.byteOffset, typedArray.length);
2241
+ }
2242
+ module2.exports = cloneTypedArray;
2243
+ }
2244
+ });
2245
+
2246
+ // ../../node_modules/lodash/_copyArray.js
2247
+ var require_copyArray = __commonJS({
2248
+ "../../node_modules/lodash/_copyArray.js"(exports, module2) {
2249
+ function copyArray(source, array) {
2250
+ var index = -1, length = source.length;
2251
+ array || (array = Array(length));
2252
+ while (++index < length) {
2253
+ array[index] = source[index];
2254
+ }
2255
+ return array;
2256
+ }
2257
+ module2.exports = copyArray;
2258
+ }
2259
+ });
2260
+
2261
+ // ../../node_modules/lodash/_baseCreate.js
2262
+ var require_baseCreate = __commonJS({
2263
+ "../../node_modules/lodash/_baseCreate.js"(exports, module2) {
2264
+ var isObject = require_isObject();
2265
+ var objectCreate = Object.create;
2266
+ var baseCreate = function() {
2267
+ function object() {
2268
+ }
2269
+ return function(proto) {
2270
+ if (!isObject(proto)) {
2271
+ return {};
2272
+ }
2273
+ if (objectCreate) {
2274
+ return objectCreate(proto);
2275
+ }
2276
+ object.prototype = proto;
2277
+ var result = new object();
2278
+ object.prototype = void 0;
2279
+ return result;
2280
+ };
2281
+ }();
2282
+ module2.exports = baseCreate;
2283
+ }
2284
+ });
2285
+
2286
+ // ../../node_modules/lodash/_getPrototype.js
2287
+ var require_getPrototype = __commonJS({
2288
+ "../../node_modules/lodash/_getPrototype.js"(exports, module2) {
2289
+ var overArg = require_overArg();
2290
+ var getPrototype = overArg(Object.getPrototypeOf, Object);
2291
+ module2.exports = getPrototype;
2292
+ }
2293
+ });
2294
+
2295
+ // ../../node_modules/lodash/_initCloneObject.js
2296
+ var require_initCloneObject = __commonJS({
2297
+ "../../node_modules/lodash/_initCloneObject.js"(exports, module2) {
2298
+ var baseCreate = require_baseCreate();
2299
+ var getPrototype = require_getPrototype();
2300
+ var isPrototype = require_isPrototype();
2301
+ function initCloneObject(object) {
2302
+ return typeof object.constructor == "function" && !isPrototype(object) ? baseCreate(getPrototype(object)) : {};
2303
+ }
2304
+ module2.exports = initCloneObject;
2305
+ }
2306
+ });
2307
+
2308
+ // ../../node_modules/lodash/isArrayLikeObject.js
2309
+ var require_isArrayLikeObject = __commonJS({
2310
+ "../../node_modules/lodash/isArrayLikeObject.js"(exports, module2) {
2311
+ var isArrayLike = require_isArrayLike();
2312
+ var isObjectLike = require_isObjectLike();
2313
+ function isArrayLikeObject(value) {
2314
+ return isObjectLike(value) && isArrayLike(value);
2315
+ }
2316
+ module2.exports = isArrayLikeObject;
2317
+ }
2318
+ });
2319
+
2320
+ // ../../node_modules/lodash/isPlainObject.js
2321
+ var require_isPlainObject = __commonJS({
2322
+ "../../node_modules/lodash/isPlainObject.js"(exports, module2) {
2323
+ var baseGetTag = require_baseGetTag();
2324
+ var getPrototype = require_getPrototype();
2325
+ var isObjectLike = require_isObjectLike();
2326
+ var objectTag = "[object Object]";
2327
+ var funcProto = Function.prototype;
2328
+ var objectProto = Object.prototype;
2329
+ var funcToString = funcProto.toString;
2330
+ var hasOwnProperty = objectProto.hasOwnProperty;
2331
+ var objectCtorString = funcToString.call(Object);
2332
+ function isPlainObject(value) {
2333
+ if (!isObjectLike(value) || baseGetTag(value) != objectTag) {
2334
+ return false;
2335
+ }
2336
+ var proto = getPrototype(value);
2337
+ if (proto === null) {
2338
+ return true;
2339
+ }
2340
+ var Ctor = hasOwnProperty.call(proto, "constructor") && proto.constructor;
2341
+ return typeof Ctor == "function" && Ctor instanceof Ctor && funcToString.call(Ctor) == objectCtorString;
2342
+ }
2343
+ module2.exports = isPlainObject;
2344
+ }
2345
+ });
2346
+
2347
+ // ../../node_modules/lodash/_safeGet.js
2348
+ var require_safeGet = __commonJS({
2349
+ "../../node_modules/lodash/_safeGet.js"(exports, module2) {
2350
+ function safeGet(object, key) {
2351
+ if (key === "constructor" && typeof object[key] === "function") {
2352
+ return;
2353
+ }
2354
+ if (key == "__proto__") {
2355
+ return;
2356
+ }
2357
+ return object[key];
2358
+ }
2359
+ module2.exports = safeGet;
2360
+ }
2361
+ });
2362
+
2363
+ // ../../node_modules/lodash/_assignValue.js
2364
+ var require_assignValue = __commonJS({
2365
+ "../../node_modules/lodash/_assignValue.js"(exports, module2) {
2366
+ var baseAssignValue = require_baseAssignValue();
2367
+ var eq = require_eq();
2368
+ var objectProto = Object.prototype;
2369
+ var hasOwnProperty = objectProto.hasOwnProperty;
2370
+ function assignValue(object, key, value) {
2371
+ var objValue = object[key];
2372
+ if (!(hasOwnProperty.call(object, key) && eq(objValue, value)) || value === void 0 && !(key in object)) {
2373
+ baseAssignValue(object, key, value);
2374
+ }
2375
+ }
2376
+ module2.exports = assignValue;
2377
+ }
2378
+ });
2379
+
2380
+ // ../../node_modules/lodash/_copyObject.js
2381
+ var require_copyObject = __commonJS({
2382
+ "../../node_modules/lodash/_copyObject.js"(exports, module2) {
2383
+ var assignValue = require_assignValue();
2384
+ var baseAssignValue = require_baseAssignValue();
2385
+ function copyObject(source, props, object, customizer) {
2386
+ var isNew = !object;
2387
+ object || (object = {});
2388
+ var index = -1, length = props.length;
2389
+ while (++index < length) {
2390
+ var key = props[index];
2391
+ var newValue = customizer ? customizer(object[key], source[key], key, object, source) : void 0;
2392
+ if (newValue === void 0) {
2393
+ newValue = source[key];
2394
+ }
2395
+ if (isNew) {
2396
+ baseAssignValue(object, key, newValue);
2397
+ } else {
2398
+ assignValue(object, key, newValue);
2399
+ }
2400
+ }
2401
+ return object;
2402
+ }
2403
+ module2.exports = copyObject;
2404
+ }
2405
+ });
2406
+
2407
+ // ../../node_modules/lodash/_nativeKeysIn.js
2408
+ var require_nativeKeysIn = __commonJS({
2409
+ "../../node_modules/lodash/_nativeKeysIn.js"(exports, module2) {
2410
+ function nativeKeysIn(object) {
2411
+ var result = [];
2412
+ if (object != null) {
2413
+ for (var key in Object(object)) {
2414
+ result.push(key);
2415
+ }
2416
+ }
2417
+ return result;
2418
+ }
2419
+ module2.exports = nativeKeysIn;
2420
+ }
2421
+ });
2422
+
2423
+ // ../../node_modules/lodash/_baseKeysIn.js
2424
+ var require_baseKeysIn = __commonJS({
2425
+ "../../node_modules/lodash/_baseKeysIn.js"(exports, module2) {
2426
+ var isObject = require_isObject();
2427
+ var isPrototype = require_isPrototype();
2428
+ var nativeKeysIn = require_nativeKeysIn();
2429
+ var objectProto = Object.prototype;
2430
+ var hasOwnProperty = objectProto.hasOwnProperty;
2431
+ function baseKeysIn(object) {
2432
+ if (!isObject(object)) {
2433
+ return nativeKeysIn(object);
2434
+ }
2435
+ var isProto = isPrototype(object), result = [];
2436
+ for (var key in object) {
2437
+ if (!(key == "constructor" && (isProto || !hasOwnProperty.call(object, key)))) {
2438
+ result.push(key);
2439
+ }
2440
+ }
2441
+ return result;
2442
+ }
2443
+ module2.exports = baseKeysIn;
2444
+ }
2445
+ });
2446
+
2447
+ // ../../node_modules/lodash/keysIn.js
2448
+ var require_keysIn = __commonJS({
2449
+ "../../node_modules/lodash/keysIn.js"(exports, module2) {
2450
+ var arrayLikeKeys = require_arrayLikeKeys();
2451
+ var baseKeysIn = require_baseKeysIn();
2452
+ var isArrayLike = require_isArrayLike();
2453
+ function keysIn(object) {
2454
+ return isArrayLike(object) ? arrayLikeKeys(object, true) : baseKeysIn(object);
2455
+ }
2456
+ module2.exports = keysIn;
2457
+ }
2458
+ });
2459
+
2460
+ // ../../node_modules/lodash/toPlainObject.js
2461
+ var require_toPlainObject = __commonJS({
2462
+ "../../node_modules/lodash/toPlainObject.js"(exports, module2) {
2463
+ var copyObject = require_copyObject();
2464
+ var keysIn = require_keysIn();
2465
+ function toPlainObject(value) {
2466
+ return copyObject(value, keysIn(value));
2467
+ }
2468
+ module2.exports = toPlainObject;
2469
+ }
2470
+ });
2471
+
2472
+ // ../../node_modules/lodash/_baseMergeDeep.js
2473
+ var require_baseMergeDeep = __commonJS({
2474
+ "../../node_modules/lodash/_baseMergeDeep.js"(exports, module2) {
2475
+ var assignMergeValue = require_assignMergeValue();
2476
+ var cloneBuffer = require_cloneBuffer();
2477
+ var cloneTypedArray = require_cloneTypedArray();
2478
+ var copyArray = require_copyArray();
2479
+ var initCloneObject = require_initCloneObject();
2480
+ var isArguments = require_isArguments();
2481
+ var isArray = require_isArray();
2482
+ var isArrayLikeObject = require_isArrayLikeObject();
2483
+ var isBuffer = require_isBuffer();
2484
+ var isFunction = require_isFunction();
2485
+ var isObject = require_isObject();
2486
+ var isPlainObject = require_isPlainObject();
2487
+ var isTypedArray = require_isTypedArray();
2488
+ var safeGet = require_safeGet();
2489
+ var toPlainObject = require_toPlainObject();
2490
+ function baseMergeDeep(object, source, key, srcIndex, mergeFunc, customizer, stack) {
2491
+ var objValue = safeGet(object, key), srcValue = safeGet(source, key), stacked = stack.get(srcValue);
2492
+ if (stacked) {
2493
+ assignMergeValue(object, key, stacked);
2494
+ return;
2495
+ }
2496
+ var newValue = customizer ? customizer(objValue, srcValue, key + "", object, source, stack) : void 0;
2497
+ var isCommon = newValue === void 0;
2498
+ if (isCommon) {
2499
+ var isArr = isArray(srcValue), isBuff = !isArr && isBuffer(srcValue), isTyped = !isArr && !isBuff && isTypedArray(srcValue);
2500
+ newValue = srcValue;
2501
+ if (isArr || isBuff || isTyped) {
2502
+ if (isArray(objValue)) {
2503
+ newValue = objValue;
2504
+ } else if (isArrayLikeObject(objValue)) {
2505
+ newValue = copyArray(objValue);
2506
+ } else if (isBuff) {
2507
+ isCommon = false;
2508
+ newValue = cloneBuffer(srcValue, true);
2509
+ } else if (isTyped) {
2510
+ isCommon = false;
2511
+ newValue = cloneTypedArray(srcValue, true);
2512
+ } else {
2513
+ newValue = [];
2514
+ }
2515
+ } else if (isPlainObject(srcValue) || isArguments(srcValue)) {
2516
+ newValue = objValue;
2517
+ if (isArguments(objValue)) {
2518
+ newValue = toPlainObject(objValue);
2519
+ } else if (!isObject(objValue) || isFunction(objValue)) {
2520
+ newValue = initCloneObject(srcValue);
2521
+ }
2522
+ } else {
2523
+ isCommon = false;
2524
+ }
2525
+ }
2526
+ if (isCommon) {
2527
+ stack.set(srcValue, newValue);
2528
+ mergeFunc(newValue, srcValue, srcIndex, customizer, stack);
2529
+ stack["delete"](srcValue);
2530
+ }
2531
+ assignMergeValue(object, key, newValue);
2532
+ }
2533
+ module2.exports = baseMergeDeep;
2534
+ }
2535
+ });
2536
+
2537
+ // ../../node_modules/lodash/_baseMerge.js
2538
+ var require_baseMerge = __commonJS({
2539
+ "../../node_modules/lodash/_baseMerge.js"(exports, module2) {
2540
+ var Stack = require_Stack();
2541
+ var assignMergeValue = require_assignMergeValue();
2542
+ var baseFor = require_baseFor();
2543
+ var baseMergeDeep = require_baseMergeDeep();
2544
+ var isObject = require_isObject();
2545
+ var keysIn = require_keysIn();
2546
+ var safeGet = require_safeGet();
2547
+ function baseMerge(object, source, srcIndex, customizer, stack) {
2548
+ if (object === source) {
2549
+ return;
2550
+ }
2551
+ baseFor(source, function(srcValue, key) {
2552
+ stack || (stack = new Stack());
2553
+ if (isObject(srcValue)) {
2554
+ baseMergeDeep(object, source, key, srcIndex, baseMerge, customizer, stack);
2555
+ } else {
2556
+ var newValue = customizer ? customizer(safeGet(object, key), srcValue, key + "", object, source, stack) : void 0;
2557
+ if (newValue === void 0) {
2558
+ newValue = srcValue;
2559
+ }
2560
+ assignMergeValue(object, key, newValue);
2561
+ }
2562
+ }, keysIn);
2563
+ }
2564
+ module2.exports = baseMerge;
2565
+ }
2566
+ });
2567
+
2568
+ // ../../node_modules/lodash/_apply.js
2569
+ var require_apply = __commonJS({
2570
+ "../../node_modules/lodash/_apply.js"(exports, module2) {
2571
+ function apply(func, thisArg, args) {
2572
+ switch (args.length) {
2573
+ case 0:
2574
+ return func.call(thisArg);
2575
+ case 1:
2576
+ return func.call(thisArg, args[0]);
2577
+ case 2:
2578
+ return func.call(thisArg, args[0], args[1]);
2579
+ case 3:
2580
+ return func.call(thisArg, args[0], args[1], args[2]);
2581
+ }
2582
+ return func.apply(thisArg, args);
2583
+ }
2584
+ module2.exports = apply;
2585
+ }
2586
+ });
2587
+
2588
+ // ../../node_modules/lodash/_overRest.js
2589
+ var require_overRest = __commonJS({
2590
+ "../../node_modules/lodash/_overRest.js"(exports, module2) {
2591
+ var apply = require_apply();
2592
+ var nativeMax = Math.max;
2593
+ function overRest(func, start2, transform) {
2594
+ start2 = nativeMax(start2 === void 0 ? func.length - 1 : start2, 0);
2595
+ return function() {
2596
+ var args = arguments, index = -1, length = nativeMax(args.length - start2, 0), array = Array(length);
2597
+ while (++index < length) {
2598
+ array[index] = args[start2 + index];
2599
+ }
2600
+ index = -1;
2601
+ var otherArgs = Array(start2 + 1);
2602
+ while (++index < start2) {
2603
+ otherArgs[index] = args[index];
2604
+ }
2605
+ otherArgs[start2] = transform(array);
2606
+ return apply(func, this, otherArgs);
2607
+ };
2608
+ }
2609
+ module2.exports = overRest;
2610
+ }
2611
+ });
2612
+
2613
+ // ../../node_modules/lodash/constant.js
2614
+ var require_constant = __commonJS({
2615
+ "../../node_modules/lodash/constant.js"(exports, module2) {
2616
+ function constant(value) {
2617
+ return function() {
2618
+ return value;
2619
+ };
2620
+ }
2621
+ module2.exports = constant;
2622
+ }
2623
+ });
2624
+
2625
+ // ../../node_modules/lodash/_baseSetToString.js
2626
+ var require_baseSetToString = __commonJS({
2627
+ "../../node_modules/lodash/_baseSetToString.js"(exports, module2) {
2628
+ var constant = require_constant();
2629
+ var defineProperty = require_defineProperty();
2630
+ var identity = require_identity();
2631
+ var baseSetToString = !defineProperty ? identity : function(func, string) {
2632
+ return defineProperty(func, "toString", {
2633
+ "configurable": true,
2634
+ "enumerable": false,
2635
+ "value": constant(string),
2636
+ "writable": true
2637
+ });
49
2638
  };
50
- var __toCommonJS2 = (mod) => __copyProps2(__defProp2({}, "__esModule", { value: true }), mod);
51
- var src_exports2 = {};
52
- __export2(src_exports2, { Addon_TypesEnum: () => Addon_TypesEnum2 });
53
- module2.exports = __toCommonJS2(src_exports2);
54
- var Addon_TypesEnum2 = ((Addon_TypesEnum22) => (Addon_TypesEnum22.TAB = "tab", Addon_TypesEnum22.PANEL = "panel", Addon_TypesEnum22.TOOL = "tool", Addon_TypesEnum22.TOOLEXTRA = "toolextra", Addon_TypesEnum22.PREVIEW = "preview", Addon_TypesEnum22.experimental_PAGE = "page", Addon_TypesEnum22.experimental_SIDEBAR_BOTTOM = "sidebar-bottom", Addon_TypesEnum22.experimental_SIDEBAR_TOP = "sidebar-top", Addon_TypesEnum22))(Addon_TypesEnum2 || {});
2639
+ module2.exports = baseSetToString;
2640
+ }
2641
+ });
2642
+
2643
+ // ../../node_modules/lodash/_shortOut.js
2644
+ var require_shortOut = __commonJS({
2645
+ "../../node_modules/lodash/_shortOut.js"(exports, module2) {
2646
+ var HOT_COUNT = 800;
2647
+ var HOT_SPAN = 16;
2648
+ var nativeNow = Date.now;
2649
+ function shortOut(func) {
2650
+ var count = 0, lastCalled = 0;
2651
+ return function() {
2652
+ var stamp = nativeNow(), remaining = HOT_SPAN - (stamp - lastCalled);
2653
+ lastCalled = stamp;
2654
+ if (remaining > 0) {
2655
+ if (++count >= HOT_COUNT) {
2656
+ return arguments[0];
2657
+ }
2658
+ } else {
2659
+ count = 0;
2660
+ }
2661
+ return func.apply(void 0, arguments);
2662
+ };
2663
+ }
2664
+ module2.exports = shortOut;
2665
+ }
2666
+ });
2667
+
2668
+ // ../../node_modules/lodash/_setToString.js
2669
+ var require_setToString = __commonJS({
2670
+ "../../node_modules/lodash/_setToString.js"(exports, module2) {
2671
+ var baseSetToString = require_baseSetToString();
2672
+ var shortOut = require_shortOut();
2673
+ var setToString = shortOut(baseSetToString);
2674
+ module2.exports = setToString;
2675
+ }
2676
+ });
2677
+
2678
+ // ../../node_modules/lodash/_baseRest.js
2679
+ var require_baseRest = __commonJS({
2680
+ "../../node_modules/lodash/_baseRest.js"(exports, module2) {
2681
+ var identity = require_identity();
2682
+ var overRest = require_overRest();
2683
+ var setToString = require_setToString();
2684
+ function baseRest(func, start2) {
2685
+ return setToString(overRest(func, start2, identity), func + "");
2686
+ }
2687
+ module2.exports = baseRest;
2688
+ }
2689
+ });
2690
+
2691
+ // ../../node_modules/lodash/_isIterateeCall.js
2692
+ var require_isIterateeCall = __commonJS({
2693
+ "../../node_modules/lodash/_isIterateeCall.js"(exports, module2) {
2694
+ var eq = require_eq();
2695
+ var isArrayLike = require_isArrayLike();
2696
+ var isIndex = require_isIndex();
2697
+ var isObject = require_isObject();
2698
+ function isIterateeCall(value, index, object) {
2699
+ if (!isObject(object)) {
2700
+ return false;
2701
+ }
2702
+ var type = typeof index;
2703
+ if (type == "number" ? isArrayLike(object) && isIndex(index, object.length) : type == "string" && index in object) {
2704
+ return eq(object[index], value);
2705
+ }
2706
+ return false;
2707
+ }
2708
+ module2.exports = isIterateeCall;
2709
+ }
2710
+ });
2711
+
2712
+ // ../../node_modules/lodash/_createAssigner.js
2713
+ var require_createAssigner = __commonJS({
2714
+ "../../node_modules/lodash/_createAssigner.js"(exports, module2) {
2715
+ var baseRest = require_baseRest();
2716
+ var isIterateeCall = require_isIterateeCall();
2717
+ function createAssigner(assigner) {
2718
+ return baseRest(function(object, sources) {
2719
+ var index = -1, length = sources.length, customizer = length > 1 ? sources[length - 1] : void 0, guard = length > 2 ? sources[2] : void 0;
2720
+ customizer = assigner.length > 3 && typeof customizer == "function" ? (length--, customizer) : void 0;
2721
+ if (guard && isIterateeCall(sources[0], sources[1], guard)) {
2722
+ customizer = length < 3 ? void 0 : customizer;
2723
+ length = 1;
2724
+ }
2725
+ object = Object(object);
2726
+ while (++index < length) {
2727
+ var source = sources[index];
2728
+ if (source) {
2729
+ assigner(object, source, index, customizer);
2730
+ }
2731
+ }
2732
+ return object;
2733
+ });
2734
+ }
2735
+ module2.exports = createAssigner;
2736
+ }
2737
+ });
2738
+
2739
+ // ../../node_modules/lodash/mergeWith.js
2740
+ var require_mergeWith = __commonJS({
2741
+ "../../node_modules/lodash/mergeWith.js"(exports, module2) {
2742
+ var baseMerge = require_baseMerge();
2743
+ var createAssigner = require_createAssigner();
2744
+ var mergeWith2 = createAssigner(function(object, source, srcIndex, customizer) {
2745
+ baseMerge(object, source, srcIndex, customizer);
2746
+ });
2747
+ module2.exports = mergeWith2;
55
2748
  }
56
2749
  });
57
2750
 
58
2751
  // src/index.ts
59
2752
  var src_exports = {};
60
2753
  __export(src_exports, {
61
- darkTheme: () => import_react_native_theming13.darkTheme,
2754
+ darkTheme: () => import_react_native_theming3.darkTheme,
62
2755
  getProjectAnnotations: () => getProjectAnnotations,
63
2756
  prepareStories: () => prepareStories,
64
2757
  start: () => start,
65
- theme: () => import_react_native_theming13.theme
2758
+ theme: () => import_react_native_theming3.theme,
2759
+ updateView: () => updateView
66
2760
  });
67
2761
  module.exports = __toCommonJS(src_exports);
68
- var import_react_native_theming13 = require("@storybook/react-native-theming");
2762
+ var import_react_native_theming3 = require("@storybook/react-native-theming");
69
2763
 
70
2764
  // src/Start.tsx
71
- var import_csf2 = require("@storybook/csf");
72
- var import_preview_api3 = require("@storybook/preview-api");
73
- var import_manager_api3 = require("@storybook/manager-api");
2765
+ var import_csf3 = require("@storybook/csf");
2766
+ var import_preview_api2 = require("@storybook/preview-api");
2767
+ var import_manager_api2 = require("@storybook/manager-api");
74
2768
  var import_channels2 = require("@storybook/channels");
75
2769
 
76
2770
  // src/View.tsx
77
- var import_csf = require("@storybook/csf");
78
- var import_manager_api2 = require("@storybook/manager-api");
79
- var import_preview_api2 = require("@storybook/preview-api");
80
- var import_react_native_theming12 = require("@storybook/react-native-theming");
81
- var import_react16 = require("react");
82
- var import_react_native_safe_area_context3 = require("react-native-safe-area-context");
83
-
84
- // src/components/OnDeviceUI/OnDeviceUI.tsx
85
- var import_react_native_theming10 = require("@storybook/react-native-theming");
86
- var import_react15 = __toESM(require("react"));
87
- var import_react_native14 = require("react-native");
2771
+ var import_csf2 = require("@storybook/csf");
2772
+ var import_manager_api = require("@storybook/manager-api");
2773
+ var import_preview_api = require("@storybook/preview-api");
2774
+ var import_react_native_theming2 = require("@storybook/react-native-theming");
2775
+ var import_react5 = require("react");
88
2776
 
89
- // src/constants.ts
90
- var ANIMATION_DURATION_TRANSITION = 400;
2777
+ // src/components/StoryView/StoryView.tsx
2778
+ var import_react4 = __toESM(require("react"));
2779
+ var import_react_native_theming = require("@storybook/react-native-theming");
2780
+ var import_react_native2 = require("react-native");
91
2781
 
92
2782
  // src/hooks.tsx
93
2783
  var import_react2 = __toESM(require("react"));
@@ -755,494 +3445,40 @@ function useSetAtom(atom2, options) {
755
3445
  );
756
3446
  return setAtom;
757
3447
  }
758
- function useAtom(atom2, options) {
759
- return [
760
- useAtomValue(atom2, options),
761
- // We do wrong type assertion here, which results in throwing an error.
762
- useSetAtom(atom2, options)
763
- ];
764
- }
765
3448
 
766
3449
  // src/hooks.tsx
767
3450
  var storyContextAtom = atom(null);
768
- function useSetStoryContext() {
769
- return useSetAtom(storyContextAtom);
770
- }
771
- function useStoryContext() {
772
- return useAtomValue(storyContextAtom);
773
- }
774
- function useStoryContextParam(name, defaultValue) {
775
- const paramAtom = (0, import_react2.useMemo)(() => atom((get) => get(storyContextAtom)?.parameters?.[name]), [name]);
776
- return useAtomValue(paramAtom) ?? defaultValue;
777
- }
778
- function useIsStorySelected(storyId) {
779
- return useAtomValue(
780
- (0, import_react2.useMemo)(() => atom((get) => get(storyContextAtom)?.id === storyId), [storyId])
781
- );
782
- }
783
- function useIsStorySectionSelected(title) {
784
- return useAtomValue(
785
- (0, import_react2.useMemo)(
786
- () => atom((get) => {
787
- const contextTitle = get(storyContextAtom)?.title;
788
- return contextTitle === title || contextTitle?.startsWith(`${title}/`);
789
- }),
790
- [title]
791
- )
792
- );
793
- }
794
- function useIsChildSelected(entries) {
795
- return useAtomValue(
796
- (0, import_react2.useMemo)(
797
- () => atom((get) => {
798
- const contextId = get(storyContextAtom)?.id;
799
- return !!entries.find(({ id }) => id === contextId);
800
- }),
801
- [entries]
802
- )
803
- );
804
- }
805
- function useUpdateOnStoryChanged() {
806
- useAtomValue((0, import_react2.useMemo)(() => atom((get) => get(storyContextAtom)?.id), []));
807
- }
808
- function atomWithToggle(initialValue) {
809
- const anAtom = atom(initialValue, (get, set, nextValue) => {
810
- const update = nextValue ?? !get(anAtom);
811
- set(anAtom, update);
812
- });
813
- return anAtom;
814
- }
815
- var isUIVisibleAtom = atomWithToggle(true);
816
- function useIsUIVisible() {
817
- return useAtom(isUIVisibleAtom);
818
- }
819
- var isSplitPanelVisibleAtom = atomWithToggle(false);
820
- function useIsSplitPanelVisible() {
821
- return useAtom(isSplitPanelVisibleAtom);
822
- }
823
- function syncExternalUI({ isUIVisible, isSplitPanelVisible }) {
824
- const jotaiStore = getDefaultStore();
825
- if (isUIVisible !== void 0) {
826
- jotaiStore.set(isUIVisibleAtom, isUIVisible);
827
- }
828
- if (isSplitPanelVisible !== void 0) {
829
- jotaiStore.set(isSplitPanelVisibleAtom, isSplitPanelVisible);
830
- }
831
- }
832
- var selectedAddonAtom = atom(void 0);
833
- function useSelectedAddon(initialValue) {
834
- const result = useAtom(selectedAddonAtom);
835
- const set = result[1];
836
- import_react2.default.useEffect(() => {
837
- const jotaiStore = getDefaultStore();
838
- if (jotaiStore.get(selectedAddonAtom) === void 0) {
839
- set(initialValue);
840
- }
841
- }, []);
842
- return result;
843
- }
844
-
845
- // src/components/StoryListView/StoryListView.tsx
846
- var import_core_events = __toESM(require("@storybook/core-events"));
847
- var import_react_native_theming = require("@storybook/react-native-theming");
848
- var import_react3 = __toESM(require("react"));
849
- var import_react_native2 = require("react-native");
850
-
851
- // src/components/Shared/icons.tsx
852
- var import_react_native = require("react-native");
853
- var import_jsx_runtime = require("react/jsx-runtime");
854
- var iconSources = {
855
- grid: {
856
- uri: "data:image/png;base64,iVBORw0KGg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out-bottom": {
868
- uri: "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAYAAABXAvmHAAAACXBIWXMAABYlAAAWJQFJUiTwAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAEzSURBVHgB7ZjhDYIwEIWfTsAIjOAIHYGNZANwAnQi3KBu4AhYIiYNNHCF0ivxvuR+mHjNe70eyR0gCIKQOspEZUKb6CJFa6IxkWMD2SC8Y45q0OItvgXALd6uiJeJFG7eVQkSuSNZ49sL3qVcSQF3zylKcoOp+FjCbTJMTdSUxPHbL8CHwvQyFxmXjZMMC3pOjqSO8J+YzOo54+CIAW7EADdigBsxwI0Y4EYMcLPWwNXEG+HGxf4s8si4xNI8sOe8XK7Q450Q8uZdlfDS85c9cMN+PBAAypvrtwOhm7jcoGc2gWOlYuPdA6/R7wv4GK90niDQPw/bsUY6i62GkqgwLVt/UKwFVzZo0A4dOfWQGvt969cGaa1o38Kh1+s/EylUosbGHsxN3BG3InoQriAIgpA0H3BBw2jFymiHAAAAAElFTkSuQmCC"
869
- },
870
- "layout-bottom-inverse": {
871
- uri: "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAYAAABXAvmHAAAACXBIWXMAABYlAAAWJQFJUiTwAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAFgSURBVHgB7ZjhcYMwDIXlTEA2YISOYDbIRmSD0AloJ+kIyQbuBskGqnz4R+OYw7jYchN9dzouwYIn2+LgAQiCIFQNImqKE4XBcpwpRooWUqHkxgnnxmpo5nSqOfF0+KJ4gzq4UHRKqZt/YjeT0EM94i1WSx81kma/DSyjwakXGigA3eeA4Z7TMcljQHwR4Z6OJlDEEJN49pIOwIRb9bvJ9MeoQBLeDSCACbfy19//+XqqLsCypGcH/xwpgBspgBspgBspgBspgBspgJukAugFsae44nbYa51gC/wrB87ndCqOa/Ws/h6ws0WHXJ+YN7rdHlboeckeeId8fMJfWdpzbsyA2zfxMUXPYg8Q+5AjVoqUHvj2frM5dPho6VxikgZv1QzWY2yNMYk6sEcNFjK4nHCNYWuxjb3IgPURtBWf0153AzvI+8yPxWrokp+EONntH/ho+ubE4LSNNQiCIFTND53ElQfvR3pDAAAAAElFTkSuQmCC"
872
- },
873
- "layout-split": {
874
- uri: "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAYAAABXAvmHAAAACXBIWXMAABYlAAAWJQFJUiTwAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAADxSURBVHgB7ZjhCcIwFITP4gAdISM4QkZwI0doNqgb1Q3iJjU/Imga5YVK3yveB/ejkJa7vgTCAYQQYh2fNCTFpHkjTUljksMK+mx8VtaQvTSbnwBom3+dSFMIC3++NgkRDlA3+0m+NNtVAlxgl7NkkaW9XyqWZg+VADNs8+a5w85hAG0YQBsG0IYBtNl9gKNgzQG6fL3acAtpwwDaMIA2DKDNXwRorvW2pBbgXjyfoEfZA90gIGDZxWhMoceyER8lL3rUCyVRK/YD+uwhVnw46UcC7LVyAQ3svl5/hrAwiYCVZ9AlXbHtRGI27kEIIaZ5ALildIGPrcQbAAAAAElFTkSuQmCC"
875
- },
876
- "layout-split-inverse": {
877
- uri: "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAYAAABXAvmHAAAACXBIWXMAABYlAAAWJQFJUiTwAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAEaSURBVHgB7ZntDYJADIaLcQBGYARHgAl0I0YQJ8BNdAPZ4BzBDWov8ENrkYuJtJA+SUO4D/K+1yaQAuA4jmMaRCwpjhQB5+NG0VIU8Cu0OR+EaxM15GM6szHxdLlQ7MAGHUWVZdmDT2xGNtRgR3wkaqmliY8MYF93AWwSs3B9HZAyUINdDnxAMmCpdDh7PiCVEIJhqITeNG9g4bgBbdyANm5AGzegzeINbKcW8Ff33Ex92ngJaeMGtHED2rgBbdZv4FtbzwKSgTu7V2uz0OHxPlCXsqlhzdWgkQXsm8uBaWlTNpZChzgIp/EXBuElyu38IvUhDdqjkbSus70+LKwoTqBP1CCKT4KyUVCcsf/tMxcB+zIuwXEcxzRPpfGo9y3IYogAAAAASUVORK5CYII="
878
- },
879
- folder: {
880
- uri: "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADIAAAAyCAYAAAAeP4ixAAAABHNCSVQICAgIfAhkiAAAAAlwSFlzAAAuIwAALiMBeKU/dgAAABl0RVh0U29mdHdhcmUAd3d3Lmlua3NjYXBlLm9yZ5vuPBoAAAHTSURBVGiB7Zk7LwRRGIbf7wwRRIJGlDSEpdmI6Fw6lRWZXiJ0lkZUsn8A2dD5B0MhkS1UepGIXZu4hsKlJASxyZyjoJAx4uzutztjc57yXN58T+Z8M5kZoEKg2R4nSpL6IdCQ72YlhQLh3LLc/dUj+7YUBepC8ciWYshxidSy+1a/tHYx+s6QlzeCKcdSihZEzWtqfsCpZcrMCy6RTwgj8knsBCHDKwIEJsPVI36cKOCGK4ygnkHYbcpkNxJISO98lc+eR4Au9eJVG4DmXyY7CejUrvRPCFCIPUQifTjG1I9ZnyuynTyeiOlEx3udDkixB6CVo1RdXCHb19P21fexonokmbZPIeQQgPuiKssTS1K3d6zoZg9Choh+tATLXSuZtk8tSwyC1B1HXiH4NXtBrByNn8V7nWFIMcmVCVJzAGp0lrKJAF/HDFjkyotHtmagKcL/QAwIIxI2jEjYMCJhw4iEDSMSNoxI2DAiYcOIhI2KEfF71W2c7XGiZa/EDwVLd6mfyCApccBYTlmomKNlRAJFymvv0P8TIRzediHjHRYAMgBK9Y+EkxygUpBybHPTdr2TBADT0Z06K/ek9UUvKFpk9Usia+eCrsNgMBgMBkM5+ADkCHptw04GlAAAAABJRU5ErkJggg=="
881
- }
882
- };
883
- function Icon({ name, ...props }) {
884
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
885
- import_react_native.Image,
886
- {
887
- source: {
888
- ...iconSources[name],
889
- width: 16,
890
- height: 16
891
- },
892
- ...props
893
- }
894
- );
895
- }
896
- function BackgroundIcon({ name, ...props }) {
897
- return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
898
- import_react_native.ImageBackground,
899
- {
900
- source: {
901
- ...iconSources[name],
902
- width: 16,
903
- height: 16
904
- },
905
- ...props
906
- }
907
- );
908
- }
909
-
910
- // src/components/StoryListView/getNestedStories.ts
911
- function getNestedStories(storyIndex) {
912
- const stories = Object.values(storyIndex?.entries ?? {});
913
- const group = [];
914
- stories?.forEach((story) => {
915
- const nameParts = story.title.split("/");
916
- formGroup(nameParts, story, group);
917
- });
918
- return group;
3451
+ function useSetStoryContext() {
3452
+ return useSetAtom(storyContextAtom);
919
3453
  }
920
- function formGroup(nameParts, story, group) {
921
- if (nameParts.length === 1) {
922
- const current = group.find(({ name }) => name === nameParts[0]);
923
- if (current) {
924
- current.stories.push(story);
925
- } else {
926
- group.push({
927
- title: story.title,
928
- name: nameParts[0],
929
- children: [],
930
- stories: [story]
931
- });
932
- }
933
- return;
934
- }
935
- const newParts = nameParts.slice(1);
936
- const currentListPart = group.find(({ name }) => name === nameParts[0]);
937
- if (!currentListPart) {
938
- const toPush = {
939
- name: nameParts[0],
940
- title: story.title,
941
- children: [],
942
- stories: []
943
- };
944
- group.push(toPush);
945
- return formGroup(newParts, story, toPush.children);
946
- } else if (!currentListPart.children) {
947
- currentListPart.children = [];
948
- }
949
- const newGroup = currentListPart.children;
950
- return formGroup(newParts, story, newGroup);
3454
+ function useStoryContext() {
3455
+ return useAtomValue(storyContextAtom);
951
3456
  }
952
- var filterNestedStories = (stories, filter) => {
953
- const filteredStories = [];
954
- stories.forEach((story) => {
955
- const filtered = filterStoryGroup(story, filter);
956
- if (filtered) {
957
- filteredStories.push(filtered);
958
- }
3457
+ function atomWithToggle(initialValue) {
3458
+ const anAtom = atom(initialValue, (get, set, nextValue) => {
3459
+ const update = nextValue ?? !get(anAtom);
3460
+ set(anAtom, update);
959
3461
  });
960
- return filteredStories;
961
- };
962
- var filterStoryGroup = (story, filter) => {
963
- const filteredStories = story.stories.filter(
964
- (item) => item.title.toLowerCase().includes(filter.toLowerCase()) || item.name.toLowerCase().includes(filter.toLowerCase())
965
- );
966
- const filteredChildren = filterNestedStories(story.children, filter);
967
- if (filteredStories.length || filteredChildren.length) {
968
- return {
969
- ...story,
970
- children: filteredChildren,
971
- stories: filteredStories
972
- };
973
- }
974
- };
975
- var findFirstChildStory = (story) => {
976
- if (story.stories.length) {
977
- return story.stories[0];
978
- }
979
- if (story.children.length) {
980
- return findFirstChildStory(story.children[0]);
3462
+ return anAtom;
3463
+ }
3464
+ var isUIVisibleAtom = atomWithToggle(true);
3465
+ var isSplitPanelVisibleAtom = atomWithToggle(false);
3466
+ function syncExternalUI({ isUIVisible, isSplitPanelVisible }) {
3467
+ const jotaiStore = getDefaultStore();
3468
+ if (isUIVisible !== void 0) {
3469
+ jotaiStore.set(isUIVisibleAtom, isUIVisible);
981
3470
  }
982
- };
983
-
984
- // src/components/StoryListView/StoryListView.tsx
985
- var import_preview_api = require("@storybook/preview-api");
986
- var import_jsx_runtime2 = require("react/jsx-runtime");
987
- var SectionHeaderText = import_react_native_theming.styled.Text(({ theme: theme3 }) => ({
988
- fontSize: theme3.storyList.fontSize,
989
- color: theme3.storyList.headerTextColor,
990
- fontWeight: theme3.storyList.headerFontWeight,
991
- flexShrink: 1
992
- }));
993
- var StoryNameText = import_react_native_theming.styled.Text(({ selected, theme: theme3 }) => ({
994
- fontSize: theme3.storyList.fontSize,
995
- fontWeight: selected ? theme3.storyList.storySelectedFontWeight : theme3.storyList.storyFontWeight,
996
- color: selected ? theme3.storyList.storySelectedTextColor : theme3.storyList.storyTextColor
997
- }));
998
- var SEARCH_ICON_SIZE = 24;
999
- var SearchInput = import_react_native_theming.styled.TextInput(
1000
- {
1001
- padding: 0,
1002
- ...import_react_native2.StyleSheet.absoluteFillObject
1003
- },
1004
- ({ theme: theme3 }) => ({
1005
- fontSize: theme3.storyList.search.fontSize,
1006
- paddingStart: theme3.storyList.search.paddingHorizontal + SEARCH_ICON_SIZE,
1007
- color: theme3.storyList.search.textColor
1008
- })
1009
- );
1010
- var SearchContainer = import_react_native_theming.styled.View(({ theme: theme3 }) => ({
1011
- flexDirection: "row",
1012
- alignItems: "center",
1013
- margin: theme3.panel.paddingHorizontal,
1014
- paddingVertical: theme3.storyList.search.paddingVertical,
1015
- paddingStart: theme3.storyList.search.paddingHorizontal,
1016
- borderColor: theme3.storyList.search.borderColor,
1017
- borderWidth: theme3.storyList.search.borderWidth,
1018
- borderRadius: theme3.storyList.search.borderRadius,
1019
- backgroundColor: theme3.storyList.search.backgroundColor
1020
- }));
1021
- var SearchBar = (props) => {
1022
- const theme3 = (0, import_react_native_theming.useTheme)();
1023
- return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(SearchContainer, { children: [
1024
- /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(Icon, { name: "search", style: { opacity: 0.5 } }),
1025
- /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
1026
- SearchInput,
1027
- {
1028
- ...props,
1029
- autoCapitalize: "none",
1030
- autoComplete: "off",
1031
- autoCorrect: false,
1032
- spellCheck: false,
1033
- clearButtonMode: "while-editing",
1034
- disableFullscreenUI: true,
1035
- placeholderTextColor: theme3.storyList.search.placeholderTextColor,
1036
- returnKeyType: "search"
1037
- }
1038
- )
1039
- ] });
1040
- };
1041
- var HeaderContainer = import_react_native_theming.styled.TouchableOpacity(
1042
- {
1043
- flexDirection: "row",
1044
- alignItems: "center"
1045
- },
1046
- ({ selected, theme: theme3, childSelected }) => ({
1047
- marginTop: theme3.storyList.sectionSpacing,
1048
- paddingHorizontal: theme3.storyList.headerPaddingHorizontal,
1049
- paddingVertical: theme3.storyList.headerPaddingVertical,
1050
- backgroundColor: selected ? theme3.storyList.sectionActiveBackgroundColor : void 0,
1051
- borderTopLeftRadius: theme3.storyList.sectionBorderRadius,
1052
- borderTopRightRadius: theme3.storyList.sectionBorderRadius,
1053
- borderBottomLeftRadius: selected && !childSelected ? theme3.storyList.sectionBorderRadius : void 0,
1054
- borderBottomRightRadius: selected && !childSelected ? theme3.storyList.sectionBorderRadius : void 0
1055
- })
1056
- );
1057
- var SectionHeader = import_react3.default.memo(
1058
- ({ name, onPress, isChildSelected, icon = "grid", expanded }) => {
1059
- const selected = useIsStorySectionSelected(name) || isChildSelected;
1060
- return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(
1061
- HeaderContainer,
1062
- {
1063
- selected,
1064
- childSelected: isChildSelected,
1065
- onPress,
1066
- activeOpacity: 0.8,
1067
- children: [
1068
- /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
1069
- import_react_native2.View,
1070
- {
1071
- style: {
1072
- transform: [{ rotate: expanded ? "90deg" : "0deg" }],
1073
- marginRight: 6,
1074
- alignItems: "center",
1075
- justifyContent: "center"
1076
- },
1077
- children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_react_native2.Text, { style: { fontSize: 8, color: "grey", lineHeight: 8 }, children: "\u27A4" })
1078
- }
1079
- ),
1080
- /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(Icon, { name: icon, width: 12, height: 12, style: { marginRight: 6 } }),
1081
- /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(SectionHeaderText, { numberOfLines: 2, selected, children: name })
1082
- ]
1083
- },
1084
- name
1085
- );
3471
+ if (isSplitPanelVisible !== void 0) {
3472
+ jotaiStore.set(isSplitPanelVisibleAtom, isSplitPanelVisible);
1086
3473
  }
1087
- );
1088
- var ItemTouchable = import_react_native_theming.styled.TouchableOpacity(
1089
- {
1090
- flexDirection: "row",
1091
- alignItems: "center"
1092
- },
1093
- ({ selected, sectionSelected, isLastItem, theme: theme3 }) => ({
1094
- padding: theme3.storyList.storyPaddingHorizontal,
1095
- paddingStart: theme3.storyList.storyIndent,
1096
- backgroundColor: selected ? theme3.storyList.storySelectedBackgroundColor : sectionSelected ? theme3.storyList.sectionActiveBackgroundColor : void 0,
1097
- borderBottomLeftRadius: isLastItem ? theme3.storyList.sectionBorderRadius : void 0,
1098
- borderBottomRightRadius: isLastItem ? theme3.storyList.sectionBorderRadius : void 0
1099
- })
1100
- );
1101
- var ListItem = ({
1102
- storyId,
1103
- kind,
1104
- title,
1105
- isLastItem,
1106
- onPress,
1107
- isSiblingSelected
1108
- }) => {
1109
- const selected = useIsStorySelected(storyId);
1110
- const sectionSelected = useIsStorySectionSelected(kind) || isSiblingSelected;
1111
- return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(
1112
- ItemTouchable,
1113
- {
1114
- onPress,
1115
- activeOpacity: 0.8,
1116
- testID: `Storybook.ListItem.${kind}.${title}`,
1117
- accessibilityLabel: `Storybook.ListItem.${title}`,
1118
- selected,
1119
- sectionSelected,
1120
- isLastItem,
1121
- children: [
1122
- /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
1123
- Icon,
1124
- {
1125
- width: 14,
1126
- height: 14,
1127
- name: selected ? "story-white" : "story-blue",
1128
- style: { marginRight: 6 }
1129
- }
1130
- ),
1131
- /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(StoryNameText, { selected, children: title })
1132
- ]
1133
- },
1134
- title
1135
- );
1136
- };
1137
- var styles = import_react_native2.StyleSheet.create({
1138
- sectionList: { flex: 1 },
1139
- sectionListContentContainer: { paddingBottom: 6 }
1140
- });
1141
- function keyExtractor(item, index) {
1142
- return item.name + index;
1143
3474
  }
1144
- var RenderItem = ({
1145
- item,
1146
- changeStory
1147
- }) => {
1148
- const isChildSelected = useIsChildSelected(item.stories);
1149
- const firstChild = findFirstChildStory(item);
1150
- const firstChildSelected = useIsStorySelected(firstChild?.id);
1151
- const [showChildren, setShowChildren] = (0, import_react3.useState)(false);
1152
- return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(import_jsx_runtime2.Fragment, { children: [
1153
- /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
1154
- SectionHeader,
1155
- {
1156
- name: item.name,
1157
- isChildSelected,
1158
- onPress: () => {
1159
- if (firstChildSelected && showChildren) {
1160
- setShowChildren(false);
1161
- } else if (!showChildren && firstChild) {
1162
- setShowChildren(true);
1163
- changeStory(firstChild.id);
1164
- } else if (showChildren && !firstChildSelected && firstChild) {
1165
- changeStory(firstChild.id);
1166
- }
1167
- },
1168
- icon: item.children.length ? "folder" : "grid",
1169
- expanded: showChildren
1170
- }
1171
- ),
1172
- showChildren && item.stories?.map((story, idx) => /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
1173
- ListItem,
1174
- {
1175
- storyId: story.id,
1176
- title: story.name,
1177
- kind: item.name,
1178
- isSiblingSelected: isChildSelected,
1179
- isLastItem: idx === item.stories.length - 1,
1180
- onPress: () => changeStory(story.id)
1181
- },
1182
- story.id
1183
- )),
1184
- showChildren && item.children?.map((child, idx) => /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_react_native2.View, { style: { marginLeft: 16 }, children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(RenderItem, { item: child, changeStory }) }, `${child.title}-${idx}`))
1185
- ] });
1186
- };
1187
- var StoryListView = ({ storyIndex }) => {
1188
- const originalData = (0, import_react3.useMemo)(() => getNestedStories(storyIndex), [storyIndex]);
1189
- const [data, setData] = (0, import_react3.useState)(originalData);
1190
- const theme3 = (0, import_react_native_theming.useTheme)();
1191
- const handleChangeSearchText = (text) => {
1192
- const query = text.trim();
1193
- if (!query) {
1194
- setData(originalData);
1195
- return;
1196
- }
1197
- setData(filterNestedStories(originalData, query));
1198
- };
1199
- const changeStory = (storyId) => {
1200
- const channel = import_preview_api.addons.getChannel();
1201
- channel.emit(import_core_events.default.SET_CURRENT_STORY, { storyId });
1202
- };
1203
- const renderItem = import_react3.default.useCallback(({ item }) => {
1204
- return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(RenderItem, { item, changeStory });
1205
- }, []);
1206
- return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(import_react_native2.View, { style: { flex: 1 }, children: [
1207
- /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
1208
- SearchBar,
1209
- {
1210
- testID: "Storybook.ListView.SearchBar",
1211
- onChangeText: handleChangeSearchText,
1212
- placeholder: "Find by name"
1213
- }
1214
- ),
1215
- /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
1216
- import_react_native2.FlatList,
1217
- {
1218
- style: styles.sectionList,
1219
- contentContainerStyle: [
1220
- styles.sectionListContentContainer,
1221
- {
1222
- paddingVertical: theme3.panel.paddingVertical,
1223
- paddingHorizontal: theme3.panel.paddingHorizontal
1224
- }
1225
- ],
1226
- testID: "Storybook.ListView",
1227
- renderItem,
1228
- keyExtractor,
1229
- data
1230
- }
1231
- )
1232
- ] });
1233
- };
1234
- var StoryListView_default = import_react3.default.memo(StoryListView);
1235
-
1236
- // src/components/StoryView/StoryView.tsx
1237
- var import_react5 = __toESM(require("react"));
1238
- var import_react_native_theming2 = require("@storybook/react-native-theming");
1239
- var import_react_native4 = require("react-native");
3475
+ var selectedAddonAtom = atom(void 0);
1240
3476
 
1241
3477
  // src/components/StoryView/ErrorBoundary.tsx
1242
- var import_react4 = __toESM(require("react"));
1243
- var import_react_native3 = require("react-native");
1244
- var import_jsx_runtime3 = require("react/jsx-runtime");
1245
- var ErrorBoundary = class extends import_react4.default.Component {
3478
+ var import_react3 = __toESM(require("react"));
3479
+ var import_react_native = require("react-native");
3480
+ var import_jsx_runtime = require("react/jsx-runtime");
3481
+ var ErrorBoundary = class extends import_react3.default.Component {
1246
3482
  constructor(props) {
1247
3483
  super(props);
1248
3484
  this.state = { hasError: false };
@@ -1255,8 +3491,8 @@ var ErrorBoundary = class extends import_react4.default.Component {
1255
3491
  }
1256
3492
  render() {
1257
3493
  if (this.state.hasError) {
1258
- return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
1259
- import_react_native3.View,
3494
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
3495
+ import_react_native.View,
1260
3496
  {
1261
3497
  style: {
1262
3498
  margin: 16,
@@ -1267,7 +3503,7 @@ var ErrorBoundary = class extends import_react4.default.Component {
1267
3503
  justifyContent: "center",
1268
3504
  borderRadius: 4
1269
3505
  },
1270
- children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_react_native3.Text, { style: { fontWeight: "bold" }, children: "Something went wrong rendering your story" })
3506
+ children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_react_native.Text, { style: { fontWeight: "bold" }, children: "Something went wrong rendering your story" })
1271
3507
  }
1272
3508
  );
1273
3509
  }
@@ -1276,700 +3512,47 @@ var ErrorBoundary = class extends import_react4.default.Component {
1276
3512
  };
1277
3513
 
1278
3514
  // src/components/StoryView/StoryView.tsx
1279
- var import_jsx_runtime4 = require("react/jsx-runtime");
3515
+ var import_jsx_runtime2 = require("react/jsx-runtime");
1280
3516
  function dismissOnStartResponder() {
1281
- import_react_native4.Keyboard.dismiss();
3517
+ import_react_native2.Keyboard.dismiss();
1282
3518
  return false;
1283
3519
  }
1284
3520
  var StoryView = () => {
1285
3521
  const context = useStoryContext();
1286
3522
  const id = context?.id;
1287
- const { backgroundColor } = (0, import_react_native_theming2.useTheme)();
3523
+ const { backgroundColor } = (0, import_react_native_theming.useTheme)();
1288
3524
  if (context && context.unboundStoryFn) {
1289
3525
  const { unboundStoryFn: StoryComponent } = context;
1290
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
1291
- import_react_native4.View,
3526
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
3527
+ import_react_native2.View,
1292
3528
  {
1293
3529
  style: { flex: 1, backgroundColor },
1294
3530
  testID: id,
1295
3531
  onStartShouldSetResponder: dismissOnStartResponder,
1296
- children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
3532
+ children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
1297
3533
  ErrorBoundary,
1298
3534
  {
1299
3535
  onError: () => {
1300
3536
  console.log(`Error rendering story for ${context.title} ${context.name}`);
1301
3537
  },
1302
- children: StoryComponent && /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(StoryComponent, { ...context })
3538
+ children: StoryComponent && /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(StoryComponent, { ...context })
1303
3539
  }
1304
3540
  )
1305
3541
  },
1306
3542
  id
1307
3543
  );
1308
3544
  }
1309
- return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_react_native4.View, { style: { flex: 1, padding: 16, alignItems: "center", justifyContent: "center" }, children: /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_react_native4.Text, { children: "Please open the sidebar and select a story to preview." }) });
1310
- };
1311
- var StoryView_default = import_react5.default.memo(StoryView);
1312
-
1313
- // src/components/OnDeviceUI/absolute-positioned-keyboard-aware-view.tsx
1314
- var import_react6 = __toESM(require("react"));
1315
- var import_react_native5 = require("react-native");
1316
- var import_jsx_runtime5 = require("react/jsx-runtime");
1317
- var AbsolutePositionedKeyboardAwareView = ({
1318
- onLayout,
1319
- previewDimensions: { width, height },
1320
- children
1321
- }) => {
1322
- const onLayoutHandler = ({ nativeEvent }) => {
1323
- const { height: layoutHeight, width: layoutWidth } = nativeEvent.layout;
1324
- if (layoutHeight !== height || layoutWidth !== width) {
1325
- onLayout({
1326
- height: layoutHeight,
1327
- width: layoutWidth
1328
- });
1329
- }
1330
- };
1331
- return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_react_native5.View, { style: styles2.container, onLayout: onLayoutHandler, children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
1332
- import_react_native5.View,
1333
- {
1334
- style: width === 0 ? styles2.container : [styles2.absolute, { position: "absolute", width, height }],
1335
- children
1336
- }
1337
- ) });
1338
- };
1339
- var styles2 = import_react_native5.StyleSheet.create({
1340
- absolute: { position: "absolute" },
1341
- container: { flex: 1 }
1342
- });
1343
- var absolute_positioned_keyboard_aware_view_default = import_react6.default.memo(AbsolutePositionedKeyboardAwareView);
1344
-
1345
- // src/components/OnDeviceUI/OnDeviceUI.tsx
1346
- var import_react_native_theming11 = require("@storybook/react-native-theming");
1347
- var import_react_native15 = require("react-native");
1348
- var import_react_native_safe_area_context2 = require("react-native-safe-area-context");
1349
-
1350
- // src/components/OnDeviceUI/Panel.tsx
1351
- var import_react7 = __toESM(require("react"));
1352
- var import_react_native6 = require("react-native");
1353
- var import_react_native_theming3 = require("@storybook/react-native-theming");
1354
- var import_jsx_runtime6 = require("react/jsx-runtime");
1355
- var Container = (0, import_react_native_theming3.styled)(import_react_native6.Animated.View)(({ theme: theme3, edge }) => ({
1356
- backgroundColor: theme3.panel.backgroundColor,
1357
- borderTopWidth: edge === "top" ? theme3.panel.borderWidth : void 0,
1358
- borderStartWidth: edge === "left" ? theme3.panel.borderWidth : void 0,
1359
- borderEndWidth: edge === "right" ? theme3.panel.borderWidth : void 0,
1360
- borderColor: theme3.panel.borderColor
1361
- }));
1362
- var Panel = ({ edge, children, style }) => {
1363
- const containerStyle = import_react_native6.StyleSheet.flatten([
1364
- edge === "top" ? void 0 : import_react_native6.StyleSheet.absoluteFillObject,
1365
- style
1366
- ]);
1367
- return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(Container, { edge, style: containerStyle, children });
1368
- };
1369
- var Panel_default = import_react7.default.memo(Panel);
1370
-
1371
- // src/components/OnDeviceUI/addons/Addons.tsx
1372
- var import_manager_api = require("@storybook/manager-api");
1373
- var import_react_native_theming7 = require("@storybook/react-native-theming");
1374
- var import_types = __toESM(require_dist());
1375
- var import_react11 = __toESM(require("react"));
1376
- var import_react_native9 = require("react-native");
1377
-
1378
- // src/components/OnDeviceUI/addons/List.tsx
1379
- var import_react9 = __toESM(require("react"));
1380
-
1381
- // src/components/Shared/tabs.tsx
1382
- var import_react8 = __toESM(require("react"));
1383
- var import_react_native7 = require("react-native");
1384
- var import_react_native_theming4 = require("@storybook/react-native-theming");
1385
- var import_react_native_theming5 = require("@storybook/react-native-theming");
1386
- var import_jsx_runtime7 = require("react/jsx-runtime");
1387
- var TabButtonText = import_react_native_theming4.styled.Text(({ theme: theme3, active }) => ({
1388
- color: active ? theme3.tabs.activeTextColor : theme3.tabs.inactiveTextColor,
1389
- paddingVertical: theme3.tabs.paddingVertical,
1390
- paddingHorizontal: theme3.tabs.paddingHorizontal,
1391
- fontSize: theme3.tabs.fontSize,
1392
- fontWeight: theme3.tabs.fontWeight
1393
- }));
1394
- var hitSlop = { top: 8, left: 0, right: 0, bottom: 20 };
1395
- var TabButtonTouchable = import_react_native_theming4.styled.TouchableOpacity(({ theme: theme3, active }) => ({
1396
- borderWidth: theme3.tabs.borderWidth,
1397
- borderColor: active ? theme3.tabs.activeBorderColor : theme3.tabs.inactiveBorderColor,
1398
- borderRadius: theme3.tabs.borderRadius,
1399
- backgroundColor: active ? theme3.tabs.activeBackgroundColor : theme3.tabs.inactiveBackgroundColor
1400
- }));
1401
- var TabButton = import_react8.default.memo(({ onPress, id, active, children, testID }) => {
1402
- return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
1403
- TabButtonTouchable,
1404
- {
1405
- active,
1406
- testID,
1407
- onPress: () => onPress(id),
1408
- activeOpacity: 0.8,
1409
- hitSlop,
1410
- children: /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(TabButtonText, { active, children })
1411
- }
1412
- );
1413
- });
1414
- var TabBar = import_react8.default.memo(({ scrollable = false, style, children }) => {
1415
- const theme3 = (0, import_react_native_theming5.useTheme)();
1416
- if (scrollable) {
1417
- children = /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
1418
- import_react_native7.ScrollView,
1419
- {
1420
- showsHorizontalScrollIndicator: false,
1421
- horizontal: true,
1422
- contentContainerStyle: { paddingHorizontal: theme3.tokens.spacing2 },
1423
- children
1424
- }
1425
- );
1426
- }
1427
- return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(import_react_native7.View, { style, children: /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(TabBarContainer, { children }) });
1428
- });
1429
- var TabBarContainer = import_react_native_theming4.styled.View(() => ({
1430
- flexDirection: "row",
1431
- paddingVertical: 6,
1432
- justifyItems: "center"
1433
- }));
1434
-
1435
- // src/components/OnDeviceUI/addons/List.tsx
1436
- var import_jsx_runtime8 = require("react/jsx-runtime");
1437
- var AddonList = ({ panels, addonSelected, onPressAddon }) => {
1438
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(TabBar, { scrollable: true, children: Object.values(panels).map(({ id, title }) => {
1439
- let resolvedTitle = typeof title === "function" ? title({}) : title;
1440
- if (typeof resolvedTitle === "string") {
1441
- resolvedTitle = resolvedTitle.toUpperCase();
1442
- }
1443
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
1444
- TabButton,
1445
- {
1446
- active: id === addonSelected,
1447
- id,
1448
- onPress: () => onPressAddon(id),
1449
- children: resolvedTitle
1450
- },
1451
- id
1452
- );
1453
- }) });
1454
- };
1455
- var List_default = import_react9.default.memo(AddonList);
1456
-
1457
- // src/components/OnDeviceUI/addons/Wrapper.tsx
1458
- var import_react_native_theming6 = require("@storybook/react-native-theming");
1459
- var import_react10 = __toESM(require("react"));
1460
- var import_react_native8 = require("react-native");
1461
- var import_jsx_runtime9 = require("react/jsx-runtime");
1462
- var Container2 = import_react_native_theming6.styled.View(({ selected }) => ({
1463
- display: selected ? "flex" : "none",
1464
- flex: 1
1465
- }));
1466
- var Wrapper = ({ panels, addonSelected }) => {
1467
- useUpdateOnStoryChanged();
1468
- const theme3 = (0, import_react_native_theming6.useTheme)();
1469
- const addonKeys = Object.keys(panels);
1470
- const content = addonKeys.map((id) => {
1471
- const selected = addonSelected === id;
1472
- return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(Container2, { selected, children: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_react_native8.ScrollView, { contentContainerStyle: { padding: theme3.panel.paddingHorizontal }, children: panels[id].render({ active: selected }) }) }, id);
1473
- });
1474
- return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_jsx_runtime9.Fragment, { children: content });
1475
- };
1476
- var Wrapper_default = import_react10.default.memo(Wrapper);
1477
-
1478
- // src/components/OnDeviceUI/addons/Addons.tsx
1479
- var import_jsx_runtime10 = require("react/jsx-runtime");
1480
- var Text4 = import_react_native_theming7.styled.Text(({ theme: theme3 }) => ({
1481
- marginTop: theme3.tokens.spacing4
1482
- }));
1483
- var Addons = ({ active }) => {
1484
- const panels = import_manager_api.addons.getElements(import_types.Addon_TypesEnum.PANEL);
1485
- const [addonSelected, setAddonSelected] = useSelectedAddon(Object.keys(panels)[0]);
1486
- const context = useStoryContext();
1487
- const id = context?.id;
1488
- if (!id) {
1489
- return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_react_native9.View, { style: { alignItems: "center", justifyContent: "center" }, children: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(Text4, { children: "No Story Selected" }) });
1490
- }
1491
- if (Object.keys(panels).length === 0) {
1492
- return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_react_native9.View, { style: { alignItems: "center", justifyContent: "center" }, children: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(Text4, { children: "No addons loaded." }) });
1493
- }
1494
- return /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_react_native9.View, { style: { flex: 1 }, children: [
1495
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
1496
- List_default,
1497
- {
1498
- onPressAddon: setAddonSelected,
1499
- panels,
1500
- addonSelected: active ? addonSelected : null
1501
- }
1502
- ),
1503
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(Wrapper_default, { addonSelected: active ? addonSelected : null, panels })
1504
- ] });
1505
- };
1506
- var Addons_default = import_react11.default.memo(Addons);
1507
-
1508
- // src/components/OnDeviceUI/addons/AddonsSkeleton.tsx
1509
- var import_react12 = __toESM(require("react"));
1510
- var import_react_native_theming8 = require("@storybook/react-native-theming");
1511
- var import_react_native10 = require("react-native");
1512
- var import_jsx_runtime11 = require("react/jsx-runtime");
1513
- var AddonsSkeleton = import_react12.default.memo(function AddonsSkeleton2({ visible }) {
1514
- const progress = import_react12.default.useRef(new import_react_native10.Animated.Value(visible ? 1 : 0));
1515
- import_react12.default.useEffect(() => {
1516
- import_react_native10.Animated.timing(progress.current, {
1517
- toValue: visible ? 1 : 0,
1518
- duration: ANIMATION_DURATION_TRANSITION,
1519
- useNativeDriver: true,
1520
- easing: import_react_native10.Easing.inOut(import_react_native10.Easing.cubic)
1521
- }).start();
1522
- }, [visible]);
1523
- return /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(AddonsSkeletonContainer, { pointerEvents: "none", style: { opacity: progress.current }, children: [
1524
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(TabsSkeleton, {}),
1525
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(AddonsContentSkeleton, {})
1526
- ] });
1527
- });
1528
- var TabSkeleton = import_react_native_theming8.styled.View(({ theme: theme3, active }) => ({
1529
- opacity: active ? 1 : 0.5,
1530
- backgroundColor: active ? theme3.tabs.activeBackgroundColor : theme3.tokens.color.grey200,
1531
- borderRadius: theme3.tokens.borderRadius.round,
1532
- width: active ? 100 : 70,
1533
- height: 30,
1534
- marginRight: 12
1535
- }));
1536
- var BoxSkeleton = import_react_native_theming8.styled.View(
1537
- ({ theme: theme3, width, height, marginBottom }) => ({
1538
- backgroundColor: theme3.tokens.color.blue200,
1539
- borderRadius: theme3.tokens.borderRadius.large,
1540
- height,
1541
- marginBottom,
1542
- width
1543
- })
1544
- );
1545
- function AddonsFieldSkeleton({ long = false }) {
1546
- return /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(import_react_native10.View, { style: { marginBottom: 32 }, children: [
1547
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(BoxSkeleton, { width: 75, height: 10, marginBottom: 12 }),
1548
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(BoxSkeleton, { width: long ? 200 : 120, height: 15 })
1549
- ] });
1550
- }
1551
- function AddonsContentSkeleton() {
1552
- return /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(import_jsx_runtime11.Fragment, { children: [
1553
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(AddonsFieldSkeleton, { long: true }),
1554
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(AddonsFieldSkeleton, { long: true }),
1555
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(AddonsFieldSkeleton, {}),
1556
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(AddonsFieldSkeleton, {})
1557
- ] });
1558
- }
1559
- function TabsSkeleton() {
1560
- return /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(import_react_native10.View, { style: { flexDirection: "row", marginBottom: 16 }, children: [
1561
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(TabSkeleton, {}),
1562
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(TabSkeleton, { active: true }),
1563
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(TabSkeleton, {})
1564
- ] });
1565
- }
1566
- var AddonsSkeletonContainer = (0, import_react_native_theming8.styled)(import_react_native10.Animated.View)(
1567
- ({ theme: theme3 }) => ({
1568
- ...import_react_native10.StyleSheet.absoluteFillObject,
1569
- flex: 1,
1570
- backgroundColor: theme3.panel.backgroundColor,
1571
- borderTopWidth: theme3.panel.borderWidth,
1572
- borderColor: theme3.panel.borderColor,
1573
- padding: theme3.panel.paddingHorizontal,
1574
- overflow: "hidden"
1575
- })
1576
- );
1577
-
1578
- // src/components/OnDeviceUI/animation.ts
1579
- var import_react_native11 = require("react-native");
1580
-
1581
- // src/components/OnDeviceUI/navigation/constants.ts
1582
- var SIDEBAR = -1;
1583
- var CANVAS = 0;
1584
- var ADDONS = 1;
1585
-
1586
- // src/components/OnDeviceUI/animation.ts
1587
- var RTL_SCALE = import_react_native11.I18nManager.isRTL ? -1 : 1;
1588
- var PREVIEW_SCALE = 0.3;
1589
- var PREVIEW_SCALE_WIDE = 0.7;
1590
- var PREVIEW_SCALE_SHRINK = 0.9;
1591
- var SCALE_OFFSET = 0.025;
1592
- var TRANSLATE_Y_OFFSET = 12;
1593
- var panelWidth = (width, wide) => {
1594
- const scale = wide ? PREVIEW_SCALE_WIDE : PREVIEW_SCALE;
1595
- return width * (1 - scale - SCALE_OFFSET);
1596
- };
1597
- var getSidebarPanelPosition = (animatedValue, previewWidth, wide) => {
1598
- return [
1599
- {
1600
- transform: [
1601
- {
1602
- translateX: animatedValue.interpolate({
1603
- inputRange: [SIDEBAR, CANVAS],
1604
- outputRange: [0, (-panelWidth(previewWidth, wide) - 1) * RTL_SCALE]
1605
- })
1606
- }
1607
- ],
1608
- width: panelWidth(previewWidth, wide)
1609
- }
1610
- ];
1611
- };
1612
- var getAddonPanelPosition = (animatedValue, previewWidth, wide) => {
1613
- return [
1614
- {
1615
- transform: [
1616
- {
1617
- translateX: animatedValue.interpolate({
1618
- inputRange: [CANVAS, ADDONS],
1619
- outputRange: [
1620
- previewWidth * RTL_SCALE,
1621
- (previewWidth - panelWidth(previewWidth, wide)) * RTL_SCALE
1622
- ]
1623
- })
1624
- }
1625
- ],
1626
- width: panelWidth(previewWidth, wide)
1627
- }
1628
- ];
1629
- };
1630
- var getPreviewStyle = ({
1631
- animatedValue,
1632
- previewDimensions: { width: previewWidth, height: previewHeight },
1633
- wide,
1634
- insets,
1635
- tabOpen,
1636
- lastTabOpen
1637
- }) => {
1638
- const scale = (wide ? PREVIEW_SCALE_WIDE : PREVIEW_SCALE) * PREVIEW_SCALE_SHRINK;
1639
- const scaledPreviewWidth = previewWidth * scale;
1640
- const scaledPreviewHeight = previewHeight * scale;
1641
- const nonPanelWidth = previewWidth - panelWidth(previewWidth, wide);
1642
- const translateXOffset = (nonPanelWidth - scaledPreviewWidth) / 2;
1643
- const translateX = (previewWidth / 2 - previewWidth * scale / 2 - translateXOffset) * RTL_SCALE;
1644
- const translateY = -(previewHeight / 2 - scaledPreviewHeight / 2) + insets.top + TRANSLATE_Y_OFFSET;
1645
- const skipPreview = lastTabOpen !== CANVAS && tabOpen !== CANVAS;
1646
- return {
1647
- transform: [
1648
- {
1649
- translateX: animatedValue.interpolate({
1650
- inputRange: [SIDEBAR, CANVAS, ADDONS],
1651
- outputRange: [translateX, 0, -translateX]
1652
- })
1653
- },
1654
- {
1655
- translateY: animatedValue.interpolate({
1656
- inputRange: [SIDEBAR, CANVAS, ADDONS],
1657
- outputRange: [translateY, skipPreview ? translateY : 0, translateY]
1658
- })
1659
- },
1660
- {
1661
- scale: animatedValue.interpolate({
1662
- inputRange: [SIDEBAR, CANVAS, ADDONS],
1663
- outputRange: [scale, skipPreview ? scale : 1, scale]
1664
- })
1665
- }
1666
- ]
1667
- };
1668
- };
1669
- var getPreviewShadowStyle = (animatedValue) => ({
1670
- elevation: 8,
1671
- shadowColor: "#000",
1672
- shadowOpacity: animatedValue.interpolate({
1673
- inputRange: [SIDEBAR, CANVAS, ADDONS],
1674
- outputRange: [0.25, 0, 0.25]
1675
- }),
1676
- shadowRadius: 8,
1677
- shadowOffset: { width: 0, height: 0 },
1678
- overflow: "visible"
1679
- });
1680
-
1681
- // src/components/OnDeviceUI/navigation/Navigation.tsx
1682
- var import_react14 = __toESM(require("react"));
1683
- var import_react_native13 = require("react-native");
1684
- var import_react_native_safe_area_context = require("react-native-safe-area-context");
1685
- var import_react_native_swipe_gestures = __toESM(require("react-native-swipe-gestures"));
1686
-
1687
- // src/components/OnDeviceUI/navigation/NavigationBar.tsx
1688
- var import_react13 = __toESM(require("react"));
1689
- var import_react_native_theming9 = require("@storybook/react-native-theming");
1690
- var import_jsx_runtime12 = require("react/jsx-runtime");
1691
- var NavigationTabBar = (0, import_react_native_theming9.styled)(TabBar)(({ theme: theme3 }) => ({
1692
- paddingHorizontal: theme3.tokens.spacing2,
1693
- backgroundColor: theme3.navigation.backgroundColor,
1694
- borderColor: theme3.navigation.borderColor,
1695
- borderTopWidth: theme3.navigation.borderWidth
1696
- }));
1697
- var NavigationBar = import_react13.default.memo(({ index, onPress, style }) => /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(NavigationTabBar, { style, children: [
1698
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
1699
- TabButton,
1700
- {
1701
- onPress,
1702
- testID: "BottomMenu.Sidebar",
1703
- id: SIDEBAR,
1704
- active: index === SIDEBAR,
1705
- children: "SIDEBAR"
1706
- }
1707
- ),
1708
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(TabButton, { onPress, testID: "BottomMenu.Canvas", id: CANVAS, active: index === CANVAS, children: "CANVAS" }),
1709
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(TabButton, { onPress, testID: "BottomMenu.Addons", id: ADDONS, active: index === ADDONS, children: "ADDONS" })
1710
- ] }));
1711
-
1712
- // src/components/OnDeviceUI/navigation/NavigationButton.tsx
1713
- var import_react_native12 = require("react-native");
1714
- var import_jsx_runtime13 = require("react/jsx-runtime");
1715
- var hitSlop2 = { top: 5, left: 5, right: 5, bottom: 5 };
1716
- function NavigationButton({ iconName, inverseIconName, active, toggle }) {
1717
- return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_react_native12.TouchableWithoutFeedback, { onPress: toggle, hitSlop: hitSlop2, children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_react_native12.View, { style: { marginHorizontal: 8 }, children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(BackgroundIcon, { style: { flex: 1, opacity: 0.8 }, name: inverseIconName, children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(Icon, { name: iconName, style: { opacity: active ? 0.6 : 0.25 } }) }) }) });
1718
- }
1719
- function VisibilityButton() {
1720
- const [active, toggle] = useIsUIVisible();
1721
- return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
1722
- NavigationButton,
1723
- {
1724
- iconName: "layout-bottom",
1725
- inverseIconName: "layout-bottom-inverse",
1726
- active,
1727
- toggle: () => toggle()
1728
- }
1729
- );
1730
- }
1731
- function AddonsSplitButton() {
1732
- const [active, toggle] = useIsSplitPanelVisible();
1733
- return /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
1734
- NavigationButton,
1735
- {
1736
- iconName: "layout-split",
1737
- inverseIconName: "layout-split-inverse",
1738
- active,
1739
- toggle: () => toggle()
1740
- }
1741
- );
1742
- }
1743
-
1744
- // src/components/OnDeviceUI/navigation/Navigation.tsx
1745
- var import_jsx_runtime14 = require("react/jsx-runtime");
1746
- var SWIPE_CONFIG = {
1747
- velocityThreshold: 0.2,
1748
- directionalOffsetThreshold: 80
1749
- };
1750
- var navStyle = {
1751
- position: "absolute",
1752
- left: 0,
1753
- right: 0,
1754
- bottom: 0
1755
- };
1756
- var Navigation = ({ tabOpen, onChangeTab, onLayout }) => {
1757
- const insets = (0, import_react_native_safe_area_context.useSafeAreaInsets)();
1758
- const handleSwipeLeft = () => {
1759
- if (tabOpen < 1) {
1760
- onChangeTab(tabOpen + 1);
1761
- }
1762
- };
1763
- const handleSwipeRight = () => {
1764
- if (tabOpen > -1) {
1765
- onChangeTab(tabOpen - 1);
1766
- }
1767
- };
1768
- const [isUIVisible] = useIsUIVisible();
1769
- return /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(import_react_native13.View, { style: navStyle, onLayout, children: [
1770
- /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(import_react_native13.View, { children: isUIVisible && /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
1771
- import_react_native_swipe_gestures.default,
1772
- {
1773
- onSwipeLeft: handleSwipeLeft,
1774
- onSwipeRight: handleSwipeRight,
1775
- config: SWIPE_CONFIG,
1776
- children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
1777
- NavigationBar,
1778
- {
1779
- index: tabOpen,
1780
- onPress: onChangeTab,
1781
- style: { paddingBottom: insets.bottom }
1782
- }
1783
- )
1784
- }
1785
- ) }),
1786
- /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)(NavigationShortcuts, { children: [
1787
- /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(VisibilityButton, {}),
1788
- /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(AddonsSplitButton, {})
1789
- ] })
1790
- ] });
1791
- };
1792
- var Navigation_default = import_react14.default.memo(Navigation);
1793
- function NavigationShortcuts({ children }) {
1794
- const insets = (0, import_react_native_safe_area_context.useSafeAreaInsets)();
1795
- return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
1796
- import_react_native13.View,
1797
- {
1798
- style: {
1799
- zIndex: 100,
1800
- alignSelf: "center",
1801
- justifyContent: "center",
1802
- alignItems: "center",
1803
- flexDirection: "row-reverse",
1804
- position: "absolute",
1805
- bottom: insets.bottom + 14,
1806
- right: 8
1807
- },
1808
- children
1809
- }
1810
- );
1811
- }
1812
-
1813
- // src/components/OnDeviceUI/OnDeviceUI.tsx
1814
- var import_jsx_runtime15 = require("react/jsx-runtime");
1815
- var IS_IOS = import_react_native14.Platform.OS === "ios";
1816
- var getExpoRoot = () => global.Expo || global.__expo || global.__exponent;
1817
- var IS_EXPO = getExpoRoot() !== void 0;
1818
- var IS_ANDROID = import_react_native14.Platform.OS === "android";
1819
- var BREAKPOINT = 1024;
1820
- var flex = { flex: 1 };
1821
- function Preview({ animatedValue, style, children }) {
1822
- const theme3 = (0, import_react_native_theming11.useTheme)();
1823
- const containerStyle = {
1824
- backgroundColor: theme3.preview.backgroundColor,
1825
- ...getPreviewShadowStyle(animatedValue)
1826
- };
1827
- return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(import_react_native14.Animated.View, { style: [flex, containerStyle], children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(import_react_native14.View, { style: [flex, style], children }) });
1828
- }
1829
- var styles3 = import_react_native14.StyleSheet.create({
1830
- expoAndroidContainer: { paddingTop: import_react_native14.StatusBar.currentHeight }
1831
- });
1832
- var Container3 = import_react_native_theming10.styled.View(({ theme: theme3 }) => ({
1833
- flex: 1,
1834
- backgroundColor: theme3.preview.containerBackgroundColor,
1835
- ...IS_ANDROID && IS_EXPO ? styles3.expoAndroidContainer : void 0,
1836
- ...import_react_native14.Platform.select({ web: { overflow: "hidden" } })
1837
- }));
1838
- var OnDeviceUI = ({
1839
- storyIndex,
1840
- shouldDisableKeyboardAvoidingView,
1841
- keyboardAvoidingViewVerticalOffset,
1842
- tabOpen: initialTabOpen
1843
- }) => {
1844
- const [tabOpen, setTabOpen] = (0, import_react15.useState)(initialTabOpen || CANVAS);
1845
- const lastTabOpen = import_react15.default.useRef(tabOpen);
1846
- const [previewDimensions, setPreviewDimensions] = (0, import_react15.useState)(() => ({
1847
- width: import_react_native14.Dimensions.get("window").width,
1848
- height: import_react_native14.Dimensions.get("window").height
1849
- }));
1850
- const animatedValue = (0, import_react15.useRef)(new import_react_native14.Animated.Value(tabOpen));
1851
- const wide = (0, import_react_native15.useWindowDimensions)().width >= BREAKPOINT;
1852
- const insets = (0, import_react_native_safe_area_context2.useSafeAreaInsets)();
1853
- const handleToggleTab = import_react15.default.useCallback(
1854
- (newTabOpen) => {
1855
- if (newTabOpen === tabOpen) {
1856
- return;
1857
- }
1858
- lastTabOpen.current = tabOpen;
1859
- import_react_native14.Animated.timing(animatedValue.current, {
1860
- toValue: newTabOpen,
1861
- duration: ANIMATION_DURATION_TRANSITION,
1862
- easing: import_react_native14.Easing.inOut(import_react_native14.Easing.cubic),
1863
- useNativeDriver: true
1864
- }).start();
1865
- setTabOpen(newTabOpen);
1866
- if (newTabOpen === CANVAS) {
1867
- import_react_native14.Keyboard.dismiss();
1868
- }
1869
- },
1870
- [tabOpen]
1871
- );
1872
- const noSafeArea = useStoryContextParam("noSafeArea", false);
1873
- const previewWrapperStyles = [
1874
- flex,
1875
- getPreviewStyle({
1876
- animatedValue: animatedValue.current,
1877
- previewDimensions,
1878
- wide,
1879
- insets,
1880
- tabOpen,
1881
- lastTabOpen: lastTabOpen.current
1882
- })
1883
- ];
1884
- const [isUIVisible] = useIsUIVisible();
1885
- const [navBarHeight, setNavBarHeight] = import_react15.default.useState(insets.bottom + 40);
1886
- const measureNavigation = import_react15.default.useCallback(
1887
- ({ nativeEvent }) => {
1888
- const inset = insets.bottom;
1889
- setNavBarHeight(isUIVisible ? nativeEvent.layout.height - inset : 0);
1890
- },
1891
- [isUIVisible, insets]
1892
- );
1893
- const safeAreaMargins = {
1894
- paddingBottom: isUIVisible ? insets.bottom + navBarHeight : noSafeArea ? 0 : insets.bottom,
1895
- paddingTop: !noSafeArea ? insets.top : 0,
1896
- overflow: "hidden"
1897
- };
1898
- const panelSafeAreaMargins = {
1899
- paddingBottom: insets.bottom + navBarHeight,
1900
- paddingTop: insets.top
1901
- };
1902
- const keyboardVerticalOffset = -panelSafeAreaMargins.paddingBottom + (keyboardAvoidingViewVerticalOffset ?? 0);
1903
- const [isSplitPanelVisible] = useIsSplitPanelVisible();
1904
- const isPreviewInactive = tabOpen !== CANVAS;
1905
- return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(import_jsx_runtime15.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(Container3, { children: [
1906
- /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
1907
- import_react_native14.KeyboardAvoidingView,
1908
- {
1909
- enabled: !shouldDisableKeyboardAvoidingView || isPreviewInactive,
1910
- behavior: IS_IOS ? "padding" : null,
1911
- keyboardVerticalOffset,
1912
- style: flex,
1913
- children: /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(
1914
- absolute_positioned_keyboard_aware_view_default,
1915
- {
1916
- onLayout: setPreviewDimensions,
1917
- previewDimensions,
1918
- children: [
1919
- /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(import_react_native14.Animated.View, { style: previewWrapperStyles, children: [
1920
- /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(Preview, { style: safeAreaMargins, animatedValue: animatedValue.current, children: [
1921
- /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(StoryView_default, {}),
1922
- isSplitPanelVisible ? /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(Panel_default, { edge: "top", style: { flex: 1 }, children: [
1923
- /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(Addons_default, { active: true }),
1924
- /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(AddonsSkeleton, { visible: isPreviewInactive })
1925
- ] }) : null
1926
- ] }),
1927
- isPreviewInactive ? /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
1928
- import_react_native14.TouchableOpacity,
1929
- {
1930
- style: import_react_native14.StyleSheet.absoluteFillObject,
1931
- onPress: () => handleToggleTab(CANVAS)
1932
- }
1933
- ) : null
1934
- ] }),
1935
- /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
1936
- Panel_default,
1937
- {
1938
- edge: "right",
1939
- style: [
1940
- getSidebarPanelPosition(animatedValue.current, previewDimensions.width, wide),
1941
- panelSafeAreaMargins
1942
- ],
1943
- children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(StoryListView_default, { storyIndex })
1944
- }
1945
- ),
1946
- /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
1947
- Panel_default,
1948
- {
1949
- edge: "left",
1950
- style: [
1951
- getAddonPanelPosition(animatedValue.current, previewDimensions.width, wide),
1952
- panelSafeAreaMargins
1953
- ],
1954
- children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(Addons_default, { active: tabOpen === ADDONS })
1955
- }
1956
- )
1957
- ]
1958
- }
1959
- )
1960
- }
1961
- ),
1962
- /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(Navigation_default, { onLayout: measureNavigation, tabOpen, onChangeTab: handleToggleTab })
1963
- ] }) });
3545
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_react_native2.View, { style: { flex: 1, padding: 16, alignItems: "center", justifyContent: "center" }, children: /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(import_react_native2.Text, { children: "Please open the sidebar and select a story to preview." }) });
1964
3546
  };
1965
- var OnDeviceUI_default = import_react15.default.memo(OnDeviceUI);
3547
+ var StoryView_default = import_react4.default.memo(StoryView);
1966
3548
 
1967
3549
  // src/View.tsx
1968
3550
  var import_channels = require("@storybook/channels");
1969
- var import_core_events2 = __toESM(require("@storybook/core-events"));
3551
+ var import_bottom_sheet = require("@gorhom/bottom-sheet");
3552
+ var import_core_events = __toESM(require("@storybook/core-events"));
1970
3553
  var import_dedent = __toESM(require("dedent"));
1971
3554
  var import_deepmerge = __toESM(require("deepmerge"));
1972
- var import_react_native16 = require("react-native");
3555
+ var import_react_native3 = require("react-native");
1973
3556
 
1974
3557
  // src/rn-host-detect.js
1975
3558
  function getByRemoteConfig(hostname) {
@@ -2017,9 +3600,220 @@ function getHost(hostname) {
2017
3600
  }
2018
3601
 
2019
3602
  // src/View.tsx
2020
- var import_jsx_runtime16 = require("react/jsx-runtime");
3603
+ var import_react_native_ui = require("@storybook/react-native-ui");
3604
+
3605
+ // src/components/StoryListView/StoryHash.ts
3606
+ var import_csf = require("@storybook/csf");
3607
+ var import_countBy = __toESM(require_countBy());
3608
+
3609
+ // ../../node_modules/ts-dedent/esm/index.js
3610
+ function dedent(templ) {
3611
+ var values = [];
3612
+ for (var _i = 1; _i < arguments.length; _i++) {
3613
+ values[_i - 1] = arguments[_i];
3614
+ }
3615
+ var strings = Array.from(typeof templ === "string" ? [templ] : templ);
3616
+ strings[strings.length - 1] = strings[strings.length - 1].replace(/\r?\n([\t ]*)$/, "");
3617
+ var indentLengths = strings.reduce(function(arr, str) {
3618
+ var matches = str.match(/\n([\t ]+|(?!\s).)/g);
3619
+ if (matches) {
3620
+ return arr.concat(matches.map(function(match) {
3621
+ var _a, _b;
3622
+ return (_b = (_a = match.match(/[\t ]/g)) === null || _a === void 0 ? void 0 : _a.length) !== null && _b !== void 0 ? _b : 0;
3623
+ }));
3624
+ }
3625
+ return arr;
3626
+ }, []);
3627
+ if (indentLengths.length) {
3628
+ var pattern_1 = new RegExp("\n[ ]{" + Math.min.apply(Math, indentLengths) + "}", "g");
3629
+ strings = strings.map(function(str) {
3630
+ return str.replace(pattern_1, "\n");
3631
+ });
3632
+ }
3633
+ strings[0] = strings[0].replace(/^\r?\n/, "");
3634
+ var string = strings[0];
3635
+ values.forEach(function(value, i) {
3636
+ var endentations = string.match(/(?:^|\n)( *)$/);
3637
+ var endentation = endentations ? endentations[1] : "";
3638
+ var indentedValue = value;
3639
+ if (typeof value === "string" && value.includes("\n")) {
3640
+ indentedValue = String(value).split("\n").map(function(str, i2) {
3641
+ return i2 === 0 ? str : "" + endentation + str;
3642
+ }).join("\n");
3643
+ }
3644
+ string += indentedValue + strings[i + 1];
3645
+ });
3646
+ return string;
3647
+ }
3648
+
3649
+ // src/components/StoryListView/StoryHash.ts
3650
+ var import_isEqual = __toESM(require_isEqual());
3651
+ var import_mergeWith = __toESM(require_mergeWith());
3652
+ var import_client_logger = require("@storybook/client-logger");
3653
+ var merge = (a, b) => (0, import_mergeWith.default)({}, a, b, (objValue, srcValue) => {
3654
+ if (Array.isArray(srcValue) && Array.isArray(objValue)) {
3655
+ srcValue.forEach((s) => {
3656
+ const existing = objValue.find((o) => o === s || (0, import_isEqual.default)(o, s));
3657
+ if (!existing) {
3658
+ objValue.push(s);
3659
+ }
3660
+ });
3661
+ return objValue;
3662
+ }
3663
+ if (Array.isArray(objValue)) {
3664
+ import_client_logger.logger.log(["the types mismatch, picking", objValue]);
3665
+ return objValue;
3666
+ }
3667
+ return void 0;
3668
+ });
3669
+ var TITLE_PATH_SEPARATOR = /\s*\/\s*/;
3670
+ var transformStoryIndexToStoriesHash = (input, { provider, docsOptions, filters, status }) => {
3671
+ if (!input.v) {
3672
+ throw new Error("Composition: Missing stories.json version");
3673
+ }
3674
+ let index = input;
3675
+ index = index.v === 2 ? transformStoryIndexV2toV3(index) : index;
3676
+ index = index.v === 3 ? transformStoryIndexV3toV4(index) : index;
3677
+ index = index;
3678
+ const entryValues = Object.values(index.entries).filter((entry) => {
3679
+ let result = true;
3680
+ Object.values(filters).forEach((filter) => {
3681
+ if (result === false) {
3682
+ return;
3683
+ }
3684
+ result = filter({ ...entry, status: status[entry.id] });
3685
+ });
3686
+ return result;
3687
+ });
3688
+ const { sidebar = {} } = provider.getConfig();
3689
+ const { showRoots, collapsedRoots = [], renderLabel } = sidebar;
3690
+ const setShowRoots = typeof showRoots !== "undefined";
3691
+ const storiesHashOutOfOrder = entryValues.reduce((acc, item) => {
3692
+ if (docsOptions.docsMode && item.type !== "docs") {
3693
+ return acc;
3694
+ }
3695
+ const { title } = item;
3696
+ const groups = title.trim().split(TITLE_PATH_SEPARATOR);
3697
+ const root = (!setShowRoots || showRoots) && groups.length > 1 ? [groups.shift()] : [];
3698
+ const names = [...root, ...groups];
3699
+ const paths = names.reduce((list, name, idx) => {
3700
+ const parent = idx > 0 && list[idx - 1];
3701
+ const id = (0, import_csf.sanitize)(parent ? `${parent}-${name}` : name);
3702
+ if (parent === id) {
3703
+ throw new Error(
3704
+ dedent`
3705
+ Invalid part '${name}', leading to id === parentId ('${id}'), inside title '${title}'
3706
+
3707
+ Did you create a path that uses the separator char accidentally, such as 'Vue <docs/>' where '/' is a separator char? See https://github.com/storybookjs/storybook/issues/6128
3708
+ `
3709
+ );
3710
+ }
3711
+ list.push(id);
3712
+ return list;
3713
+ }, []);
3714
+ paths.forEach((id, idx) => {
3715
+ const childId = paths[idx + 1] || item.id;
3716
+ if (root.length && idx === 0) {
3717
+ acc[id] = merge(acc[id] || {}, {
3718
+ type: "root",
3719
+ id,
3720
+ name: names[idx],
3721
+ depth: idx,
3722
+ renderLabel,
3723
+ startCollapsed: collapsedRoots.includes(id),
3724
+ // Note that this will later get appended to the previous list of children (see below)
3725
+ children: [childId]
3726
+ });
3727
+ } else if ((!acc[id] || acc[id].type === "component") && idx === paths.length - 1) {
3728
+ acc[id] = merge(acc[id] || {}, {
3729
+ type: "component",
3730
+ id,
3731
+ name: names[idx],
3732
+ parent: paths[idx - 1],
3733
+ depth: idx,
3734
+ renderLabel,
3735
+ ...childId && {
3736
+ children: [childId]
3737
+ }
3738
+ });
3739
+ } else {
3740
+ acc[id] = merge(acc[id] || {}, {
3741
+ type: "group",
3742
+ id,
3743
+ name: names[idx],
3744
+ parent: paths[idx - 1],
3745
+ depth: idx,
3746
+ renderLabel,
3747
+ ...childId && {
3748
+ children: [childId]
3749
+ }
3750
+ });
3751
+ }
3752
+ });
3753
+ acc[item.id] = {
3754
+ type: "story",
3755
+ ...item,
3756
+ depth: paths.length,
3757
+ parent: paths[paths.length - 1],
3758
+ renderLabel,
3759
+ prepared: !!item.parameters
3760
+ };
3761
+ return acc;
3762
+ }, {});
3763
+ function addItem(acc, item) {
3764
+ if (acc[item.id]) {
3765
+ return acc;
3766
+ }
3767
+ acc[item.id] = item;
3768
+ if (item.type === "root" || item.type === "group" || item.type === "component") {
3769
+ item.children.forEach((childId) => addItem(acc, storiesHashOutOfOrder[childId]));
3770
+ }
3771
+ return acc;
3772
+ }
3773
+ const orphanHash = Object.values(storiesHashOutOfOrder).filter((i) => i.type !== "root" && !i.parent).reduce(addItem, {});
3774
+ return Object.values(storiesHashOutOfOrder).filter((i) => i.type === "root").reduce(addItem, orphanHash);
3775
+ };
3776
+ var transformStoryIndexV2toV3 = (index) => {
3777
+ return {
3778
+ v: 3,
3779
+ stories: Object.values(index.stories).reduce((acc, entry) => {
3780
+ acc[entry.id] = {
3781
+ ...entry,
3782
+ title: entry.kind,
3783
+ name: entry.name || entry.story,
3784
+ importPath: entry.parameters.fileName || ""
3785
+ };
3786
+ return acc;
3787
+ }, {})
3788
+ };
3789
+ };
3790
+ var transformStoryIndexV3toV4 = (index) => {
3791
+ const countByTitle = (0, import_countBy.default)(Object.values(index.stories), "title");
3792
+ return {
3793
+ v: 4,
3794
+ entries: Object.values(index.stories).reduce((acc, entry) => {
3795
+ let type = "story";
3796
+ if (entry.parameters?.docsOnly || entry.name === "Page" && countByTitle[entry.title] === 1) {
3797
+ type = "docs";
3798
+ }
3799
+ acc[entry.id] = {
3800
+ type,
3801
+ ...type === "docs" && { tags: ["stories-mdx"], storiesImports: [] },
3802
+ ...entry
3803
+ };
3804
+ delete acc[entry.id].story;
3805
+ delete acc[entry.id].kind;
3806
+ return acc;
3807
+ }, {})
3808
+ };
3809
+ };
3810
+
3811
+ // src/View.tsx
3812
+ var import_react_native_gesture_handler = require("react-native-gesture-handler");
3813
+ var import_react_native_safe_area_context = require("react-native-safe-area-context");
3814
+ var import_jsx_runtime3 = require("react/jsx-runtime");
2021
3815
  var STORAGE_KEY = "lastOpenedStory";
2022
- var View11 = class {
3816
+ var View3 = class {
2023
3817
  _storyIndex;
2024
3818
  _setStory = () => {
2025
3819
  };
@@ -2044,7 +3838,7 @@ var View11 = class {
2044
3838
  return { storySpecifier: initialSelection, viewMode: "story" };
2045
3839
  } else {
2046
3840
  return {
2047
- storySpecifier: (0, import_csf.toId)(initialSelection.kind, initialSelection.name),
3841
+ storySpecifier: (0, import_csf2.toId)(initialSelection.kind, initialSelection.name),
2048
3842
  viewMode: "story"
2049
3843
  };
2050
3844
  }
@@ -2102,15 +3896,15 @@ var View11 = class {
2102
3896
  if (enableWebsockets) {
2103
3897
  console.log("websockets enabled");
2104
3898
  const channel = this._getServerChannel(params);
2105
- import_manager_api2.addons.setChannel(channel);
2106
- import_preview_api2.addons.setChannel(channel);
3899
+ import_manager_api.addons.setChannel(channel);
3900
+ import_preview_api.addons.setChannel(channel);
2107
3901
  this._channel = channel;
2108
3902
  this._preview.channel = channel;
2109
3903
  this._preview.setupListeners();
2110
- channel.emit(import_core_events2.default.CHANNEL_CREATED);
3904
+ channel.emit(import_core_events.default.CHANNEL_CREATED);
2111
3905
  this._preview.initializeWithStoryIndex(this._storyIndex);
2112
3906
  }
2113
- import_manager_api2.addons.loadAddons({
3907
+ import_manager_api.addons.loadAddons({
2114
3908
  store: () => ({
2115
3909
  fromId: (id) => {
2116
3910
  if (!this._ready) {
@@ -2124,26 +3918,27 @@ var View11 = class {
2124
3918
  _channel: this._channel
2125
3919
  })
2126
3920
  });
2127
- const self = this;
3921
+ const self2 = this;
2128
3922
  syncExternalUI({
2129
3923
  isUIVisible: params.isUIHidden !== void 0 ? !params.isUIHidden : void 0,
2130
3924
  isSplitPanelVisible: params.isSplitPanelVisible
2131
3925
  });
2132
3926
  return () => {
2133
3927
  const setContext = useSetStoryContext();
2134
- const colorScheme = (0, import_react_native16.useColorScheme)();
2135
- const [, forceUpdate] = (0, import_react16.useReducer)((x) => x + 1, 0);
2136
- const [ready, setReady] = (0, import_react16.useState)(false);
2137
- const appliedTheme = (0, import_react16.useMemo)(
2138
- () => (0, import_deepmerge.default)(colorScheme === "dark" ? import_react_native_theming12.darkTheme : import_react_native_theming12.theme, params.theme ?? {}),
3928
+ const story = useStoryContext();
3929
+ const colorScheme = (0, import_react_native3.useColorScheme)();
3930
+ const [, forceUpdate] = (0, import_react5.useReducer)((x) => x + 1, 0);
3931
+ const [ready, setReady] = (0, import_react5.useState)(false);
3932
+ const appliedTheme = (0, import_react5.useMemo)(
3933
+ () => (0, import_deepmerge.default)(colorScheme === "dark" ? import_react_native_theming2.darkTheme : import_react_native_theming2.theme, params.theme ?? {}),
2139
3934
  [colorScheme]
2140
3935
  );
2141
- (0, import_react16.useEffect)(() => {
3936
+ (0, import_react5.useEffect)(() => {
2142
3937
  this.createPreparedStoryMapping().then(() => {
2143
3938
  this._ready = true;
2144
3939
  setReady(true);
2145
3940
  }).catch((e) => console.error(e));
2146
- self._setStory = (newStory) => {
3941
+ self2._setStory = (newStory) => {
2147
3942
  setContext(newStory);
2148
3943
  if (shouldPersistSelection && !storage) {
2149
3944
  console.warn(import_dedent.default`Please set storage in getStorybookUI like this:
@@ -2161,44 +3956,50 @@ var View11 = class {
2161
3956
  });
2162
3957
  }
2163
3958
  };
2164
- self._forceRerender = () => forceUpdate();
2165
- initialStory.then((story) => {
2166
- self._preview.selectionStore.selectionSpecifier = story;
2167
- self._preview.selectSpecifiedStory();
3959
+ self2._forceRerender = () => forceUpdate();
3960
+ initialStory.then((story2) => {
3961
+ self2._preview.selectionStore.selectionSpecifier = story2;
3962
+ self2._preview.selectSpecifiedStory();
2168
3963
  });
2169
3964
  }, []);
3965
+ const storyHash = (0, import_react5.useMemo)(() => {
3966
+ if (!ready) {
3967
+ return {};
3968
+ }
3969
+ return transformStoryIndexToStoriesHash(this._storyIndex, {
3970
+ docsOptions: { docsMode: false, autodocs: false, defaultName: "" },
3971
+ filters: {},
3972
+ status: {},
3973
+ provider: {
3974
+ handleAPI: () => ({}),
3975
+ getConfig: () => ({})
3976
+ }
3977
+ });
3978
+ }, [ready]);
2170
3979
  if (!ready) {
2171
- return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
2172
- import_react_native16.View,
3980
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
3981
+ import_react_native3.View,
2173
3982
  {
2174
3983
  style: {
2175
- ...import_react_native16.StyleSheet.absoluteFillObject,
3984
+ ...import_react_native3.StyleSheet.absoluteFillObject,
2176
3985
  alignItems: "center",
2177
3986
  justifyContent: "center"
2178
3987
  },
2179
- children: /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_react_native16.ActivityIndicator, { animating: true, size: "large" })
3988
+ children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_react_native3.ActivityIndicator, { animating: true, size: "large" })
2180
3989
  }
2181
3990
  );
2182
3991
  }
2183
3992
  if (onDeviceUI) {
2184
- return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_react_native_safe_area_context3.SafeAreaProvider, { children: /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_react_native_theming12.ThemeProvider, { theme: appliedTheme, children: /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
2185
- OnDeviceUI_default,
2186
- {
2187
- storyIndex: self._storyIndex,
2188
- tabOpen: params.tabOpen,
2189
- shouldDisableKeyboardAvoidingView: params.shouldDisableKeyboardAvoidingView,
2190
- keyboardAvoidingViewVerticalOffset: params.keyboardAvoidingViewVerticalOffset
2191
- }
2192
- ) }) });
3993
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_react_native_theming2.ThemeProvider, { theme: appliedTheme, children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_react_native_safe_area_context.SafeAreaProvider, { children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_react_native_gesture_handler.GestureHandlerRootView, { style: { flex: 1 }, children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_bottom_sheet.BottomSheetModalProvider, { children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_react_native_ui.Layout, { storyHash, story, children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(StoryView_default, {}) }) }) }) }) });
2193
3994
  } else {
2194
- return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(StoryView_default, {});
3995
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(StoryView_default, {});
2195
3996
  }
2196
3997
  };
2197
3998
  };
2198
3999
  };
2199
4000
 
2200
4001
  // src/Start.tsx
2201
- var import_jsx_runtime17 = require("react/jsx-runtime");
4002
+ var import_jsx_runtime4 = require("react/jsx-runtime");
2202
4003
  function prepareStories({
2203
4004
  storyEntries
2204
4005
  }) {
@@ -2208,7 +4009,7 @@ function prepareStories({
2208
4009
  };
2209
4010
  let importMap = {};
2210
4011
  const makeTitle = (fileName, specifier, userTitle) => {
2211
- const title = (0, import_preview_api3.userOrAutoTitleFromSpecifier)(fileName, specifier, userTitle);
4012
+ const title = (0, import_preview_api2.userOrAutoTitleFromSpecifier)(fileName, specifier, userTitle);
2212
4013
  if (title) {
2213
4014
  return title.replace("./", "");
2214
4015
  } else {
@@ -2237,10 +4038,10 @@ function prepareStories({
2237
4038
  const exportValue = fileExports[key];
2238
4039
  if (!exportValue)
2239
4040
  return;
2240
- const name = (0, import_csf2.storyNameFromExport)(key);
4041
+ const name = (0, import_csf3.storyNameFromExport)(key);
2241
4042
  const title = makeTitle(filename, specifier, meta.title);
2242
4043
  if (title) {
2243
- const id = (0, import_csf2.toId)(title, name);
4044
+ const id = (0, import_csf3.toId)(title, name);
2244
4045
  index.entries[id] = {
2245
4046
  type: "story",
2246
4047
  id,
@@ -2264,7 +4065,7 @@ function prepareStories({
2264
4065
  });
2265
4066
  return { index, importMap };
2266
4067
  }
2267
- var getProjectAnnotations = (view, annotations) => async () => (0, import_preview_api3.composeConfigs)([
4068
+ var getProjectAnnotations = (view, annotations) => async () => (0, import_preview_api2.composeConfigs)([
2268
4069
  {
2269
4070
  renderToCanvas: (context) => {
2270
4071
  view._setStory(context.storyContext);
@@ -2276,7 +4077,7 @@ var getProjectAnnotations = (view, annotations) => async () => (0, import_previe
2276
4077
  `Unable to render story ${id} as the component annotation is missing from the default export`
2277
4078
  );
2278
4079
  }
2279
- return /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(Component, { ...args });
4080
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(Component, { ...args });
2280
4081
  }
2281
4082
  },
2282
4083
  ...annotations
@@ -2287,11 +4088,11 @@ function start({
2287
4088
  }) {
2288
4089
  const { index, importMap } = prepareStories({ storyEntries });
2289
4090
  const channel = (0, import_channels2.createBrowserChannel)({ page: "preview" });
2290
- import_manager_api3.addons.setChannel(channel);
2291
- import_preview_api3.addons.setChannel(channel);
4091
+ import_manager_api2.addons.setChannel(channel);
4092
+ import_preview_api2.addons.setChannel(channel);
2292
4093
  const previewView = {
2293
4094
  prepareForStory: () => {
2294
- return /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(import_jsx_runtime17.Fragment, {});
4095
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(import_jsx_runtime4.Fragment, {});
2295
4096
  },
2296
4097
  prepareForDocs: () => {
2297
4098
  },
@@ -2323,7 +4124,7 @@ function start({
2323
4124
  preview.selectionStore.selection = selection;
2324
4125
  }
2325
4126
  };
2326
- const getProjectAnnotationsInitial = async () => (0, import_preview_api3.composeConfigs)([
4127
+ const getProjectAnnotationsInitial = async () => (0, import_preview_api2.composeConfigs)([
2327
4128
  {
2328
4129
  renderToCanvas: (context) => {
2329
4130
  view._setStory(context.storyContext);
@@ -2335,31 +4136,45 @@ function start({
2335
4136
  `Unable to render story ${id} as the component annotation is missing from the default export`
2336
4137
  );
2337
4138
  }
2338
- return /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(Component, { ...args });
4139
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(Component, { ...args });
2339
4140
  }
2340
4141
  },
2341
4142
  ...annotations
2342
4143
  ]);
2343
- const preview = new import_preview_api3.PreviewWithSelection(
4144
+ const preview = new import_preview_api2.PreviewWithSelection(
2344
4145
  async (importPath) => importMap[importPath],
2345
4146
  getProjectAnnotationsInitial,
2346
4147
  selectionStore,
2347
4148
  previewView
2348
4149
  );
2349
- const view = new View11(preview, channel);
4150
+ const view = new View3(preview, channel);
2350
4151
  if (global) {
2351
4152
  global.__STORYBOOK_ADDONS_CHANNEL__ = channel;
2352
4153
  global.__STORYBOOK_PREVIEW__ = preview;
2353
4154
  }
2354
- preview.getStoryIndexFromServer = async () => index;
2355
4155
  view._storyIndex = index;
4156
+ preview.getStoryIndexFromServer = async () => view._storyIndex;
2356
4157
  return view;
2357
4158
  }
4159
+ function updateView(viewInstance, annotations, normalizedStories) {
4160
+ const { importMap, index } = prepareStories({ storyEntries: normalizedStories });
4161
+ viewInstance._preview.onStoriesChanged({
4162
+ importFn: async (importPath) => importMap[importPath]
4163
+ });
4164
+ viewInstance._preview.onGetProjectAnnotationsChanged({
4165
+ getProjectAnnotations: getProjectAnnotations(viewInstance, annotations)
4166
+ });
4167
+ viewInstance._storyIndex = index;
4168
+ viewInstance._preview.onStoryIndexChanged().then(() => {
4169
+ viewInstance.createPreparedStoryMapping().then(() => viewInstance._forceRerender());
4170
+ });
4171
+ }
2358
4172
  // Annotate the CommonJS export names for ESM import in node:
2359
4173
  0 && (module.exports = {
2360
4174
  darkTheme,
2361
4175
  getProjectAnnotations,
2362
4176
  prepareStories,
2363
4177
  start,
2364
- theme
4178
+ theme,
4179
+ updateView
2365
4180
  });