@spothero/ui 22.3.9-beta.1 → 22.3.9-beta.2
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/AccordionActionButton.d.ts +2 -0
- package/dist/index.cjs.js +179 -736
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/index.esm.js +179 -736
- package/dist/index.esm.js.map +1 -1
- package/dist/styles/index.d.ts +68 -0
- package/package.json +17 -14
package/dist/index.cjs.js
CHANGED
|
@@ -1475,31 +1475,6 @@ function getDefaultExportFromCjs (x) {
|
|
|
1475
1475
|
return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
|
|
1476
1476
|
}
|
|
1477
1477
|
|
|
1478
|
-
function getAugmentedNamespace(n) {
|
|
1479
|
-
if (n.__esModule) return n;
|
|
1480
|
-
var f = n.default;
|
|
1481
|
-
if (typeof f == "function") {
|
|
1482
|
-
var a = function a () {
|
|
1483
|
-
if (this instanceof a) {
|
|
1484
|
-
return Reflect.construct(f, arguments, this.constructor);
|
|
1485
|
-
}
|
|
1486
|
-
return f.apply(this, arguments);
|
|
1487
|
-
};
|
|
1488
|
-
a.prototype = f.prototype;
|
|
1489
|
-
} else a = {};
|
|
1490
|
-
Object.defineProperty(a, '__esModule', {value: true});
|
|
1491
|
-
Object.keys(n).forEach(function (k) {
|
|
1492
|
-
var d = Object.getOwnPropertyDescriptor(n, k);
|
|
1493
|
-
Object.defineProperty(a, k, d.get ? d : {
|
|
1494
|
-
enumerable: true,
|
|
1495
|
-
get: function () {
|
|
1496
|
-
return n[k];
|
|
1497
|
-
}
|
|
1498
|
-
});
|
|
1499
|
-
});
|
|
1500
|
-
return a;
|
|
1501
|
-
}
|
|
1502
|
-
|
|
1503
1478
|
var reactIs = {exports: {}};
|
|
1504
1479
|
|
|
1505
1480
|
var reactIs_production_min = {};
|
|
@@ -4795,12 +4770,12 @@ function isUndefined(value) {
|
|
|
4795
4770
|
return typeof value === "undefined" || value === undefined;
|
|
4796
4771
|
} // Object assertions
|
|
4797
4772
|
|
|
4798
|
-
function isObject
|
|
4773
|
+
function isObject(value) {
|
|
4799
4774
|
var type = _typeof$1(value);
|
|
4800
4775
|
return value != null && (type === "object" || type === "function") && !isArray$1(value);
|
|
4801
4776
|
}
|
|
4802
4777
|
function isEmptyObject(value) {
|
|
4803
|
-
return isObject
|
|
4778
|
+
return isObject(value) && Object.keys(value).length === 0;
|
|
4804
4779
|
}
|
|
4805
4780
|
function isNull(value) {
|
|
4806
4781
|
return value == null;
|
|
@@ -4818,7 +4793,7 @@ function isRefObject$1(val) {
|
|
|
4818
4793
|
return "current" in val;
|
|
4819
4794
|
}
|
|
4820
4795
|
function isInputEvent(value) {
|
|
4821
|
-
return value && isObject
|
|
4796
|
+
return value && isObject(value) && isObject(value.target);
|
|
4822
4797
|
}
|
|
4823
4798
|
function omit(object, keys) {
|
|
4824
4799
|
var result = {};
|
|
@@ -5016,7 +4991,7 @@ function analyzeBreakpoints(breakpoints) {
|
|
|
5016
4991
|
return queryString(minW);
|
|
5017
4992
|
}).slice(1)),
|
|
5018
4993
|
toArrayValue: function toArrayValue(test) {
|
|
5019
|
-
if (!isObject
|
|
4994
|
+
if (!isObject(test)) {
|
|
5020
4995
|
throw new Error("toArrayValue: value must be an object");
|
|
5021
4996
|
}
|
|
5022
4997
|
var result = _keysArr.map(function (bp) {
|
|
@@ -5361,13 +5336,13 @@ function flatten(target, maxDepth) {
|
|
|
5361
5336
|
if (maxDepth === void 0) {
|
|
5362
5337
|
maxDepth = Infinity;
|
|
5363
5338
|
}
|
|
5364
|
-
if (!isObject
|
|
5339
|
+
if (!isObject(target) && !Array.isArray(target) || !maxDepth) {
|
|
5365
5340
|
return target;
|
|
5366
5341
|
}
|
|
5367
5342
|
return Object.entries(target).reduce(function (result, _ref) {
|
|
5368
5343
|
var key = _ref[0],
|
|
5369
5344
|
value = _ref[1];
|
|
5370
|
-
if (isObject
|
|
5345
|
+
if (isObject(value) || isArray$1(value)) {
|
|
5371
5346
|
Object.entries(flatten(value, maxDepth - 1)).forEach(function (_ref2) {
|
|
5372
5347
|
var childKey = _ref2[0],
|
|
5373
5348
|
childValue = _ref2[1];
|
|
@@ -5522,7 +5497,7 @@ function mapResponsive(prop, mapper) {
|
|
|
5522
5497
|
return mapper(item);
|
|
5523
5498
|
});
|
|
5524
5499
|
}
|
|
5525
|
-
if (isObject
|
|
5500
|
+
if (isObject(prop)) {
|
|
5526
5501
|
return objectKeys(prop).reduce(function (result, key) {
|
|
5527
5502
|
result[key] = mapper(prop[key]);
|
|
5528
5503
|
return result;
|
|
@@ -6713,7 +6688,7 @@ if (__DEV__) {
|
|
|
6713
6688
|
Portal.displayName = "Portal";
|
|
6714
6689
|
}
|
|
6715
6690
|
|
|
6716
|
-
var doc
|
|
6691
|
+
var doc = {
|
|
6717
6692
|
body: {
|
|
6718
6693
|
classList: {
|
|
6719
6694
|
add: function add() {},
|
|
@@ -6752,10 +6727,10 @@ var doc$1 = {
|
|
|
6752
6727
|
};
|
|
6753
6728
|
}
|
|
6754
6729
|
};
|
|
6755
|
-
var ssrDocument
|
|
6730
|
+
var ssrDocument = doc;
|
|
6756
6731
|
var noop$2 = function noop() {};
|
|
6757
|
-
var win
|
|
6758
|
-
document: ssrDocument
|
|
6732
|
+
var win = {
|
|
6733
|
+
document: ssrDocument,
|
|
6759
6734
|
navigator: {
|
|
6760
6735
|
userAgent: ""
|
|
6761
6736
|
},
|
|
@@ -6798,10 +6773,10 @@ var win$1 = {
|
|
|
6798
6773
|
},
|
|
6799
6774
|
clearInterval: noop$2
|
|
6800
6775
|
};
|
|
6801
|
-
var ssrWindow
|
|
6776
|
+
var ssrWindow = win;
|
|
6802
6777
|
var mockEnv = {
|
|
6803
|
-
window: ssrWindow
|
|
6804
|
-
document: ssrDocument
|
|
6778
|
+
window: ssrWindow,
|
|
6779
|
+
document: ssrDocument
|
|
6805
6780
|
};
|
|
6806
6781
|
var defaultEnv = isBrowser$5 ? {
|
|
6807
6782
|
window: window,
|
|
@@ -7101,7 +7076,7 @@ var tokenToCSSVar = function tokenToCSSVar(scale, value) {
|
|
|
7101
7076
|
return function (theme) {
|
|
7102
7077
|
var valueStr = String(value);
|
|
7103
7078
|
var key = scale ? scale + "." + valueStr : valueStr;
|
|
7104
|
-
return isObject
|
|
7079
|
+
return isObject(theme.__cssMap) && key in theme.__cssMap ? theme.__cssMap[key].varRef : value;
|
|
7105
7080
|
};
|
|
7106
7081
|
};
|
|
7107
7082
|
function createTransform(options) {
|
|
@@ -8459,7 +8434,7 @@ var expandResponsive = function expandResponsive(styles) {
|
|
|
8459
8434
|
var value = runIfFn(styles[key], theme);
|
|
8460
8435
|
if (value == null) continue; // converts the object responsive syntax to array syntax
|
|
8461
8436
|
|
|
8462
|
-
value = isObject
|
|
8437
|
+
value = isObject(value) && isResponsive(value) ? toArrayValue(value) : value;
|
|
8463
8438
|
if (!Array.isArray(value)) {
|
|
8464
8439
|
computedStyles[key] = value;
|
|
8465
8440
|
continue;
|
|
@@ -8550,7 +8525,7 @@ function getCss(options) {
|
|
|
8550
8525
|
property: key
|
|
8551
8526
|
};
|
|
8552
8527
|
}
|
|
8553
|
-
if (isObject
|
|
8528
|
+
if (isObject(value)) {
|
|
8554
8529
|
var _computedStyles$key;
|
|
8555
8530
|
computedStyles[key] = (_computedStyles$key = computedStyles[key]) != null ? _computedStyles$key : {};
|
|
8556
8531
|
computedStyles[key] = mergeWith({}, computedStyles[key], css(value, true));
|
|
@@ -8587,14 +8562,14 @@ function getCss(options) {
|
|
|
8587
8562
|
continue;
|
|
8588
8563
|
}
|
|
8589
8564
|
if (configProperty) {
|
|
8590
|
-
if (configProperty === "&" && isObject
|
|
8565
|
+
if (configProperty === "&" && isObject(rawValue)) {
|
|
8591
8566
|
computedStyles = mergeWith({}, computedStyles, rawValue);
|
|
8592
8567
|
} else {
|
|
8593
8568
|
computedStyles[configProperty] = rawValue;
|
|
8594
8569
|
}
|
|
8595
8570
|
continue;
|
|
8596
8571
|
}
|
|
8597
|
-
if (isObject
|
|
8572
|
+
if (isObject(rawValue)) {
|
|
8598
8573
|
computedStyles = mergeWith({}, computedStyles, rawValue);
|
|
8599
8574
|
continue;
|
|
8600
8575
|
}
|
|
@@ -8620,7 +8595,7 @@ var css$3 = function css(styles) {
|
|
|
8620
8595
|
*/
|
|
8621
8596
|
|
|
8622
8597
|
function resolveReference(operand) {
|
|
8623
|
-
if (isObject
|
|
8598
|
+
if (isObject(operand) && operand.reference) {
|
|
8624
8599
|
return operand.reference;
|
|
8625
8600
|
}
|
|
8626
8601
|
return String(operand);
|
|
@@ -8797,7 +8772,7 @@ function createThemeVars(flatTokens, options) {
|
|
|
8797
8772
|
reference = _tokenToCssVar2.reference;
|
|
8798
8773
|
return reference;
|
|
8799
8774
|
};
|
|
8800
|
-
var normalizedValue = isObject
|
|
8775
|
+
var normalizedValue = isObject(value) ? value : {
|
|
8801
8776
|
"default": value
|
|
8802
8777
|
};
|
|
8803
8778
|
cssVars = mergeWith(cssVars, Object.entries(normalizedValue).reduce(function (acc, _ref) {
|
|
@@ -11294,7 +11269,7 @@ function anatomy$1(name) {
|
|
|
11294
11269
|
return new Anatomy$1(name);
|
|
11295
11270
|
}
|
|
11296
11271
|
function toRef$1(operand) {
|
|
11297
|
-
if (isObject
|
|
11272
|
+
if (isObject(operand) && operand.reference) {
|
|
11298
11273
|
return operand.reference;
|
|
11299
11274
|
}
|
|
11300
11275
|
return String(operand);
|
|
@@ -14495,7 +14470,7 @@ var styles$4 = {
|
|
|
14495
14470
|
var styles$1$2 = styles$4;
|
|
14496
14471
|
var requiredChakraThemeKeys = ["borders", "breakpoints", "colors", "components", "config", "direction", "fonts", "fontSizes", "fontWeights", "letterSpacings", "lineHeights", "radii", "shadows", "sizes", "space", "styles", "transition", "zIndices"];
|
|
14497
14472
|
function isChakraTheme(unit) {
|
|
14498
|
-
if (!isObject
|
|
14473
|
+
if (!isObject(unit)) {
|
|
14499
14474
|
return false;
|
|
14500
14475
|
}
|
|
14501
14476
|
return requiredChakraThemeKeys.every(function (propertyName) {
|
|
@@ -14634,19 +14609,19 @@ function createIcon(options) {
|
|
|
14634
14609
|
return Comp;
|
|
14635
14610
|
}
|
|
14636
14611
|
|
|
14637
|
-
/******************************************************************************
|
|
14638
|
-
Copyright (c) Microsoft Corporation.
|
|
14639
|
-
|
|
14640
|
-
Permission to use, copy, modify, and/or distribute this software for any
|
|
14641
|
-
purpose with or without fee is hereby granted.
|
|
14642
|
-
|
|
14643
|
-
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
14644
|
-
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
14645
|
-
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
14646
|
-
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
14647
|
-
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
14648
|
-
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
14649
|
-
PERFORMANCE OF THIS SOFTWARE.
|
|
14612
|
+
/******************************************************************************
|
|
14613
|
+
Copyright (c) Microsoft Corporation.
|
|
14614
|
+
|
|
14615
|
+
Permission to use, copy, modify, and/or distribute this software for any
|
|
14616
|
+
purpose with or without fee is hereby granted.
|
|
14617
|
+
|
|
14618
|
+
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
14619
|
+
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
14620
|
+
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
14621
|
+
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
14622
|
+
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
14623
|
+
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
14624
|
+
PERFORMANCE OF THIS SOFTWARE.
|
|
14650
14625
|
***************************************************************************** */
|
|
14651
14626
|
/* global Reflect, Promise, SuppressedError, Symbol, Iterator */
|
|
14652
14627
|
|
|
@@ -14668,17 +14643,17 @@ function __extends(d, b) {
|
|
|
14668
14643
|
}
|
|
14669
14644
|
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
14670
14645
|
}
|
|
14671
|
-
var _assign
|
|
14672
|
-
_assign
|
|
14646
|
+
var _assign = function __assign() {
|
|
14647
|
+
_assign = Object.assign || function __assign(t) {
|
|
14673
14648
|
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
14674
14649
|
s = arguments[i];
|
|
14675
14650
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
|
|
14676
14651
|
}
|
|
14677
14652
|
return t;
|
|
14678
14653
|
};
|
|
14679
|
-
return _assign
|
|
14654
|
+
return _assign.apply(this, arguments);
|
|
14680
14655
|
};
|
|
14681
|
-
function __rest
|
|
14656
|
+
function __rest(s, e) {
|
|
14682
14657
|
var t = {};
|
|
14683
14658
|
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];
|
|
14684
14659
|
if (s != null && typeof Object.getOwnPropertySymbols === "function") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
@@ -14795,7 +14770,7 @@ function useFeatures(props, visualElement, preloadedFeatures) {
|
|
|
14795
14770
|
* was producing a lot of duplication amongst bundles.
|
|
14796
14771
|
*/
|
|
14797
14772
|
if (isEnabled(props) && Component) {
|
|
14798
|
-
features.push( /*#__PURE__*/React__namespace.createElement(Component, _assign
|
|
14773
|
+
features.push( /*#__PURE__*/React__namespace.createElement(Component, _assign({
|
|
14799
14774
|
key: name_1
|
|
14800
14775
|
}, props, {
|
|
14801
14776
|
visualElement: visualElement
|
|
@@ -14944,7 +14919,7 @@ function useVisualElement(Component, visualState, props, createVisualElement) {
|
|
|
14944
14919
|
visualElementRef.current = createVisualElement(Component, {
|
|
14945
14920
|
visualState: visualState,
|
|
14946
14921
|
parent: parent,
|
|
14947
|
-
props: _assign
|
|
14922
|
+
props: _assign(_assign({}, props), {
|
|
14948
14923
|
layoutId: layoutId
|
|
14949
14924
|
}),
|
|
14950
14925
|
presenceId: presenceContext === null || presenceContext === void 0 ? void 0 : presenceContext.id,
|
|
@@ -14954,7 +14929,7 @@ function useVisualElement(Component, visualState, props, createVisualElement) {
|
|
|
14954
14929
|
var visualElement = visualElementRef.current;
|
|
14955
14930
|
useIsomorphicLayoutEffect(function () {
|
|
14956
14931
|
if (!visualElement) return;
|
|
14957
|
-
visualElement.setProps(_assign
|
|
14932
|
+
visualElement.setProps(_assign(_assign(_assign({}, config), props), {
|
|
14958
14933
|
layoutId: layoutId
|
|
14959
14934
|
}));
|
|
14960
14935
|
visualElement.isPresent = isPresent(presenceContext);
|
|
@@ -15399,10 +15374,10 @@ var number = {
|
|
|
15399
15374
|
return v;
|
|
15400
15375
|
}
|
|
15401
15376
|
};
|
|
15402
|
-
var alpha = _assign
|
|
15377
|
+
var alpha = _assign(_assign({}, number), {
|
|
15403
15378
|
transform: clamp$1(0, 1)
|
|
15404
15379
|
});
|
|
15405
|
-
var scale$1 = _assign
|
|
15380
|
+
var scale$1 = _assign(_assign({}, number), {
|
|
15406
15381
|
"default": 1
|
|
15407
15382
|
});
|
|
15408
15383
|
|
|
@@ -15422,7 +15397,7 @@ var percent = createUnitType('%');
|
|
|
15422
15397
|
var px = createUnitType('px');
|
|
15423
15398
|
var vh = createUnitType('vh');
|
|
15424
15399
|
var vw = createUnitType('vw');
|
|
15425
|
-
var progressPercentage = _assign
|
|
15400
|
+
var progressPercentage = _assign(_assign({}, percent), {
|
|
15426
15401
|
parse: function parse(v) {
|
|
15427
15402
|
return percent.parse(v) / 100;
|
|
15428
15403
|
},
|
|
@@ -15463,7 +15438,7 @@ var hsla = {
|
|
|
15463
15438
|
};
|
|
15464
15439
|
|
|
15465
15440
|
var clampRgbUnit = clamp$1(0, 255);
|
|
15466
|
-
var rgbUnit = _assign
|
|
15441
|
+
var rgbUnit = _assign(_assign({}, number), {
|
|
15467
15442
|
transform: function transform(v) {
|
|
15468
15443
|
return Math.round(clampRgbUnit(v));
|
|
15469
15444
|
}
|
|
@@ -15604,14 +15579,14 @@ function applyDefaultFilter(v) {
|
|
|
15604
15579
|
return name + '(' + defaultValue + unit + ')';
|
|
15605
15580
|
}
|
|
15606
15581
|
var functionRegex = /([a-z-]*)\(.*?\)/g;
|
|
15607
|
-
var filter = _assign
|
|
15582
|
+
var filter = _assign(_assign({}, complex), {
|
|
15608
15583
|
getAnimatableNone: function getAnimatableNone(v) {
|
|
15609
15584
|
var functions = v.match(functionRegex);
|
|
15610
15585
|
return functions ? functions.map(applyDefaultFilter).join(' ') : v;
|
|
15611
15586
|
}
|
|
15612
15587
|
});
|
|
15613
15588
|
|
|
15614
|
-
var _int = _assign
|
|
15589
|
+
var _int = _assign(_assign({}, number), {
|
|
15615
15590
|
transform: Math.round
|
|
15616
15591
|
});
|
|
15617
15592
|
|
|
@@ -15796,7 +15771,7 @@ function useInitialMotionValues(_a, visualState, isStatic) {
|
|
|
15796
15771
|
}, transformTemplate);
|
|
15797
15772
|
var vars = state.vars,
|
|
15798
15773
|
style = state.style;
|
|
15799
|
-
return _assign
|
|
15774
|
+
return _assign(_assign({}, vars), style);
|
|
15800
15775
|
}, [visualState]);
|
|
15801
15776
|
}
|
|
15802
15777
|
function useStyle(props, visualState, isStatic) {
|
|
@@ -15946,7 +15921,7 @@ function buildSVGAttrs(state, _a, projection, layoutState, options, transformTem
|
|
|
15946
15921
|
_c = _a.pathOffset,
|
|
15947
15922
|
pathOffset = _c === void 0 ? 0 : _c,
|
|
15948
15923
|
// This is object creation, which we try to avoid per-frame.
|
|
15949
|
-
latest = __rest
|
|
15924
|
+
latest = __rest(_a, ["attrX", "attrY", "originX", "originY", "pathLength", "pathSpacing", "pathOffset"]);
|
|
15950
15925
|
buildHTMLStyles(state, latest, projection, layoutState, options, transformTemplate, buildProjectionTransform, buildProjectionTransformOrigin);
|
|
15951
15926
|
state.attrs = state.style;
|
|
15952
15927
|
state.style = {};
|
|
@@ -15976,7 +15951,7 @@ function buildSVGAttrs(state, _a, projection, layoutState, options, transformTem
|
|
|
15976
15951
|
}
|
|
15977
15952
|
|
|
15978
15953
|
var createSvgRenderState = function createSvgRenderState() {
|
|
15979
|
-
return _assign
|
|
15954
|
+
return _assign(_assign({}, createHtmlRenderState()), {
|
|
15980
15955
|
attrs: {}
|
|
15981
15956
|
});
|
|
15982
15957
|
};
|
|
@@ -15987,14 +15962,14 @@ function useSVGProps(props, visualState) {
|
|
|
15987
15962
|
buildSVGAttrs(state, visualState, undefined, undefined, {
|
|
15988
15963
|
enableHardwareAcceleration: false
|
|
15989
15964
|
}, props.transformTemplate);
|
|
15990
|
-
return _assign
|
|
15991
|
-
style: _assign
|
|
15965
|
+
return _assign(_assign({}, state.attrs), {
|
|
15966
|
+
style: _assign({}, state.style)
|
|
15992
15967
|
});
|
|
15993
15968
|
}, [visualState]);
|
|
15994
15969
|
if (props.style) {
|
|
15995
15970
|
var rawStyles = {};
|
|
15996
15971
|
copyRawValuesOnly(rawStyles, props.style, props);
|
|
15997
|
-
visualProps.style = _assign
|
|
15972
|
+
visualProps.style = _assign(_assign({}, rawStyles), visualProps.style);
|
|
15998
15973
|
}
|
|
15999
15974
|
return visualProps;
|
|
16000
15975
|
}
|
|
@@ -16008,7 +15983,7 @@ function createUseRender(forwardMotionProps) {
|
|
|
16008
15983
|
var useVisualProps = isSVGComponent(Component) ? useSVGProps : useHTMLProps;
|
|
16009
15984
|
var visualProps = useVisualProps(props, latestValues, isStatic);
|
|
16010
15985
|
var filteredProps = filterProps(props, typeof Component === "string", forwardMotionProps);
|
|
16011
|
-
var elementProps = _assign
|
|
15986
|
+
var elementProps = _assign(_assign(_assign({}, filteredProps), visualProps), {
|
|
16012
15987
|
ref: ref
|
|
16013
15988
|
});
|
|
16014
15989
|
return /*#__PURE__*/React.createElement(Component, elementProps);
|
|
@@ -16146,7 +16121,7 @@ function makeLatestValues(props, context, presenceContext, scrapeMotionValues) {
|
|
|
16146
16121
|
if (!resolved) return;
|
|
16147
16122
|
var transitionEnd = resolved.transitionEnd;
|
|
16148
16123
|
resolved.transition;
|
|
16149
|
-
var target = __rest
|
|
16124
|
+
var target = __rest(resolved, ["transitionEnd", "transition"]);
|
|
16150
16125
|
for (var key in target) values[key] = target[key];
|
|
16151
16126
|
for (var key in transitionEnd) values[key] = transitionEnd[key];
|
|
16152
16127
|
});
|
|
@@ -16198,7 +16173,7 @@ function createDomMotionConfig(Component, _a, preloadedFeatures, createVisualEle
|
|
|
16198
16173
|
var _b = _a.forwardMotionProps,
|
|
16199
16174
|
forwardMotionProps = _b === void 0 ? false : _b;
|
|
16200
16175
|
var baseConfig = isSVGComponent(Component) ? svgMotionConfig : htmlMotionConfig;
|
|
16201
|
-
return _assign
|
|
16176
|
+
return _assign(_assign({}, baseConfig), {
|
|
16202
16177
|
preloadedFeatures: preloadedFeatures,
|
|
16203
16178
|
useRender: createUseRender(forwardMotionProps),
|
|
16204
16179
|
createVisualElement: createVisualElement,
|
|
@@ -16568,7 +16543,7 @@ function isSpringType(options, keys) {
|
|
|
16568
16543
|
});
|
|
16569
16544
|
}
|
|
16570
16545
|
function getSpringOptions(options) {
|
|
16571
|
-
var springOptions = _assign
|
|
16546
|
+
var springOptions = _assign({
|
|
16572
16547
|
velocity: 0.0,
|
|
16573
16548
|
stiffness: 100,
|
|
16574
16549
|
damping: 10,
|
|
@@ -16577,7 +16552,7 @@ function getSpringOptions(options) {
|
|
|
16577
16552
|
}, options);
|
|
16578
16553
|
if (!isSpringType(options, physicsKeys) && isSpringType(options, durationKeys)) {
|
|
16579
16554
|
var derived = findSpring(options);
|
|
16580
|
-
springOptions = _assign
|
|
16555
|
+
springOptions = _assign(_assign(_assign({}, springOptions), derived), {
|
|
16581
16556
|
velocity: 0.0,
|
|
16582
16557
|
mass: 1.0
|
|
16583
16558
|
});
|
|
@@ -16593,7 +16568,7 @@ function spring(_a) {
|
|
|
16593
16568
|
_d = _a.restSpeed,
|
|
16594
16569
|
restSpeed = _d === void 0 ? 2 : _d,
|
|
16595
16570
|
restDelta = _a.restDelta,
|
|
16596
|
-
options = __rest
|
|
16571
|
+
options = __rest(_a, ["from", "to", "restSpeed", "restDelta"]);
|
|
16597
16572
|
var state = {
|
|
16598
16573
|
done: false,
|
|
16599
16574
|
value: from
|
|
@@ -16697,7 +16672,7 @@ var mixColor = function mixColor(from, to) {
|
|
|
16697
16672
|
invariant(fromColorType.transform === toColorType.transform, "Both colors must be hex/RGBA, OR both must be HSLA.");
|
|
16698
16673
|
var fromColor = fromColorType.parse(from);
|
|
16699
16674
|
var toColor = toColorType.parse(to);
|
|
16700
|
-
var blended = _assign
|
|
16675
|
+
var blended = _assign({}, fromColor);
|
|
16701
16676
|
var mixFunc = fromColorType === hsla ? mix : mixLinearColor;
|
|
16702
16677
|
return function (v) {
|
|
16703
16678
|
for (var key in blended) {
|
|
@@ -16752,7 +16727,7 @@ var mixArray = function mixArray(from, to) {
|
|
|
16752
16727
|
};
|
|
16753
16728
|
};
|
|
16754
16729
|
var mixObject = function mixObject(origin, target) {
|
|
16755
|
-
var output = _assign
|
|
16730
|
+
var output = _assign(_assign({}, origin), target);
|
|
16756
16731
|
var blendValue = {};
|
|
16757
16732
|
for (var key in output) {
|
|
16758
16733
|
if (origin[key] !== undefined && target[key] !== undefined) {
|
|
@@ -17100,7 +17075,7 @@ function animate(_a) {
|
|
|
17100
17075
|
onComplete = _a.onComplete,
|
|
17101
17076
|
onRepeat = _a.onRepeat,
|
|
17102
17077
|
onUpdate = _a.onUpdate,
|
|
17103
|
-
options = __rest
|
|
17078
|
+
options = __rest(_a, ["from", "autoplay", "driver", "elapsed", "repeat", "repeatType", "repeatDelay", "onPlay", "onStop", "onComplete", "onRepeat", "onUpdate"]);
|
|
17104
17079
|
var to = options.to;
|
|
17105
17080
|
var driverControls;
|
|
17106
17081
|
var repeatCount = 0;
|
|
@@ -17117,7 +17092,7 @@ function animate(_a) {
|
|
|
17117
17092
|
from = 0;
|
|
17118
17093
|
to = 100;
|
|
17119
17094
|
}
|
|
17120
|
-
var animation = animator(_assign
|
|
17095
|
+
var animation = animator(_assign(_assign({}, options), {
|
|
17121
17096
|
from: from,
|
|
17122
17097
|
to: to
|
|
17123
17098
|
}));
|
|
@@ -17206,7 +17181,7 @@ function inertia(_a) {
|
|
|
17206
17181
|
}
|
|
17207
17182
|
function startAnimation(options) {
|
|
17208
17183
|
currentAnimation === null || currentAnimation === void 0 ? void 0 : currentAnimation.stop();
|
|
17209
|
-
currentAnimation = animate(_assign
|
|
17184
|
+
currentAnimation = animate(_assign(_assign({}, options), {
|
|
17210
17185
|
driver: driver,
|
|
17211
17186
|
onUpdate: function onUpdate(v) {
|
|
17212
17187
|
var _a;
|
|
@@ -17217,7 +17192,7 @@ function inertia(_a) {
|
|
|
17217
17192
|
}));
|
|
17218
17193
|
}
|
|
17219
17194
|
function startSpring(options) {
|
|
17220
|
-
startAnimation(_assign
|
|
17195
|
+
startAnimation(_assign({
|
|
17221
17196
|
type: "spring",
|
|
17222
17197
|
stiffness: bounceStiffness,
|
|
17223
17198
|
damping: bounceDamping,
|
|
@@ -17568,7 +17543,7 @@ var getDefaultTransition = function getDefaultTransition(valueKey, to) {
|
|
|
17568
17543
|
} else {
|
|
17569
17544
|
transitionFactory = defaultTransitions$1[valueKey] || defaultTransitions$1["default"];
|
|
17570
17545
|
}
|
|
17571
|
-
return _assign
|
|
17546
|
+
return _assign({
|
|
17572
17547
|
to: to
|
|
17573
17548
|
}, transitionFactory(to));
|
|
17574
17549
|
};
|
|
@@ -17576,7 +17551,7 @@ var getDefaultTransition = function getDefaultTransition(valueKey, to) {
|
|
|
17576
17551
|
/**
|
|
17577
17552
|
* A map of default value types for common values
|
|
17578
17553
|
*/
|
|
17579
|
-
var defaultValueTypes = _assign
|
|
17554
|
+
var defaultValueTypes = _assign(_assign({}, numberValueTypes), {
|
|
17580
17555
|
// Color props
|
|
17581
17556
|
color: color,
|
|
17582
17557
|
backgroundColor: color,
|
|
@@ -17622,7 +17597,7 @@ function isTransitionDefined(_a) {
|
|
|
17622
17597
|
_a.repeatType;
|
|
17623
17598
|
_a.repeatDelay;
|
|
17624
17599
|
_a.from;
|
|
17625
|
-
var transition = __rest
|
|
17600
|
+
var transition = __rest(_a, ["when", "delay", "delayChildren", "staggerChildren", "staggerDirection", "repeat", "repeatType", "repeatDelay", "from"]);
|
|
17626
17601
|
return !!Object.keys(transition).length;
|
|
17627
17602
|
}
|
|
17628
17603
|
var legacyRepeatWarning = false;
|
|
@@ -17635,8 +17610,8 @@ function convertTransitionToAnimationOptions(_a) {
|
|
|
17635
17610
|
yoyo = _a.yoyo,
|
|
17636
17611
|
flip = _a.flip,
|
|
17637
17612
|
loop = _a.loop,
|
|
17638
|
-
transition = __rest
|
|
17639
|
-
var options = _assign
|
|
17613
|
+
transition = __rest(_a, ["ease", "times", "yoyo", "flip", "loop"]);
|
|
17614
|
+
var options = _assign({}, transition);
|
|
17640
17615
|
if (times) options["offset"] = times;
|
|
17641
17616
|
/**
|
|
17642
17617
|
* Convert any existing durations from seconds to milliseconds
|
|
@@ -17701,9 +17676,9 @@ function getPopmotionAnimationOptions(transition, options, key) {
|
|
|
17701
17676
|
* Get a default transition if none is determined to be defined.
|
|
17702
17677
|
*/
|
|
17703
17678
|
if (!isTransitionDefined(transition)) {
|
|
17704
|
-
transition = _assign
|
|
17679
|
+
transition = _assign(_assign({}, transition), getDefaultTransition(key, options.to));
|
|
17705
17680
|
}
|
|
17706
|
-
return _assign
|
|
17681
|
+
return _assign(_assign({}, options), convertTransitionToAnimationOptions(transition));
|
|
17707
17682
|
}
|
|
17708
17683
|
/**
|
|
17709
17684
|
*
|
|
@@ -17736,7 +17711,7 @@ function getAnimation(key, value, target, transition, onComplete) {
|
|
|
17736
17711
|
return value.set(v);
|
|
17737
17712
|
}
|
|
17738
17713
|
};
|
|
17739
|
-
return valueTransition.type === "inertia" || valueTransition.type === "decay" ? inertia(_assign
|
|
17714
|
+
return valueTransition.type === "inertia" || valueTransition.type === "decay" ? inertia(_assign(_assign({}, options), valueTransition)) : animate(_assign(_assign({}, getPopmotionAnimationOptions(valueTransition, options, key)), {
|
|
17740
17715
|
onUpdate: function onUpdate(v) {
|
|
17741
17716
|
var _a;
|
|
17742
17717
|
options.onUpdate(v);
|
|
@@ -18253,8 +18228,8 @@ function setTarget(visualElement, definition) {
|
|
|
18253
18228
|
_b = _a.transitionEnd,
|
|
18254
18229
|
transitionEnd = _b === void 0 ? {} : _b;
|
|
18255
18230
|
_a.transition;
|
|
18256
|
-
var target = __rest
|
|
18257
|
-
target = _assign
|
|
18231
|
+
var target = __rest(_a, ["transitionEnd", "transition"]);
|
|
18232
|
+
target = _assign(_assign({}, target), transitionEnd);
|
|
18258
18233
|
for (var key in target) {
|
|
18259
18234
|
var value = resolveFinalValueInKeyframes(target[key]);
|
|
18260
18235
|
setMotionValue(visualElement, key, value);
|
|
@@ -18405,7 +18380,7 @@ function animateTarget(visualElement, definition, _a) {
|
|
|
18405
18380
|
_f = _e.transition,
|
|
18406
18381
|
transition = _f === void 0 ? visualElement.getDefaultTransition() : _f,
|
|
18407
18382
|
transitionEnd = _e.transitionEnd,
|
|
18408
|
-
target = __rest
|
|
18383
|
+
target = __rest(_e, ["transition", "transitionEnd"]);
|
|
18409
18384
|
if (transitionOverride) transition = transitionOverride;
|
|
18410
18385
|
var animations = [];
|
|
18411
18386
|
var animationTypeState = type && ((_b = visualElement.animationState) === null || _b === void 0 ? void 0 : _b.getState()[type]);
|
|
@@ -18415,7 +18390,7 @@ function animateTarget(visualElement, definition, _a) {
|
|
|
18415
18390
|
if (!value || valueTarget === undefined || animationTypeState && shouldBlockAnimation(animationTypeState, key)) {
|
|
18416
18391
|
continue;
|
|
18417
18392
|
}
|
|
18418
|
-
var animation = startAnimation(key, value, valueTarget, _assign
|
|
18393
|
+
var animation = startAnimation(key, value, valueTarget, _assign({
|
|
18419
18394
|
delay: delay
|
|
18420
18395
|
}, transition));
|
|
18421
18396
|
animations.push(animation);
|
|
@@ -18448,7 +18423,7 @@ function animateChildren(visualElement, variant, delayChildren, staggerChildren,
|
|
|
18448
18423
|
return maxStaggerDuration - i * staggerChildren;
|
|
18449
18424
|
};
|
|
18450
18425
|
Array.from(visualElement.variantChildren).sort(sortByTreeOrder).forEach(function (child, i) {
|
|
18451
|
-
animations.push(animateVariant(child, variant, _assign
|
|
18426
|
+
animations.push(animateVariant(child, variant, _assign(_assign({}, options), {
|
|
18452
18427
|
delay: delayChildren + generateStaggerDuration(i)
|
|
18453
18428
|
})).then(function () {
|
|
18454
18429
|
return child.notifyAnimationComplete(variant);
|
|
@@ -18499,8 +18474,8 @@ function createAnimationState(visualElement) {
|
|
|
18499
18474
|
if (resolved) {
|
|
18500
18475
|
resolved.transition;
|
|
18501
18476
|
var transitionEnd = resolved.transitionEnd,
|
|
18502
|
-
target = __rest
|
|
18503
|
-
acc = _assign
|
|
18477
|
+
target = __rest(resolved, ["transition", "transitionEnd"]);
|
|
18478
|
+
acc = _assign(_assign(_assign({}, acc), target), transitionEnd);
|
|
18504
18479
|
}
|
|
18505
18480
|
return acc;
|
|
18506
18481
|
};
|
|
@@ -18577,7 +18552,7 @@ function createAnimationState(visualElement) {
|
|
|
18577
18552
|
* Set all encountered keys so far as the protected keys for this type. This will
|
|
18578
18553
|
* be any key that has been animated or otherwise handled by active, higher-priortiy types.
|
|
18579
18554
|
*/
|
|
18580
|
-
typeState.protectedKeys = _assign
|
|
18555
|
+
typeState.protectedKeys = _assign({}, encounteredKeys);
|
|
18581
18556
|
// Check if we can skip analysing this prop early
|
|
18582
18557
|
if (
|
|
18583
18558
|
// If it isn't active and hasn't *just* been set as inactive
|
|
@@ -18620,7 +18595,7 @@ function createAnimationState(visualElement) {
|
|
|
18620
18595
|
*/
|
|
18621
18596
|
var _b = typeState.prevResolvedValues,
|
|
18622
18597
|
prevResolvedValues = _b === void 0 ? {} : _b;
|
|
18623
|
-
var allKeys = _assign
|
|
18598
|
+
var allKeys = _assign(_assign({}, prevResolvedValues), resolvedValues);
|
|
18624
18599
|
var markToAnimate = function markToAnimate(key) {
|
|
18625
18600
|
shouldAnimateType = true;
|
|
18626
18601
|
removedKeys["delete"](key);
|
|
@@ -18680,7 +18655,7 @@ function createAnimationState(visualElement) {
|
|
|
18680
18655
|
*
|
|
18681
18656
|
*/
|
|
18682
18657
|
if (typeState.isActive) {
|
|
18683
|
-
encounteredKeys = _assign
|
|
18658
|
+
encounteredKeys = _assign(_assign({}, encounteredKeys), resolvedValues);
|
|
18684
18659
|
}
|
|
18685
18660
|
if (isInitialRender && visualElement.blockInitialAnimation) {
|
|
18686
18661
|
shouldAnimateType = false;
|
|
@@ -18694,7 +18669,7 @@ function createAnimationState(visualElement) {
|
|
|
18694
18669
|
animations.push.apply(animations, __spreadArray([], __read(definitionList.map(function (animation) {
|
|
18695
18670
|
return {
|
|
18696
18671
|
animation: animation,
|
|
18697
|
-
options: _assign
|
|
18672
|
+
options: _assign({
|
|
18698
18673
|
type: type
|
|
18699
18674
|
}, options)
|
|
18700
18675
|
};
|
|
@@ -18710,7 +18685,7 @@ function createAnimationState(visualElement) {
|
|
|
18710
18685
|
for (var i = 0; i < numAnimationTypes; i++) {
|
|
18711
18686
|
_loop_1(i);
|
|
18712
18687
|
}
|
|
18713
|
-
allAnimatedKeys = _assign
|
|
18688
|
+
allAnimatedKeys = _assign({}, encounteredKeys);
|
|
18714
18689
|
/**
|
|
18715
18690
|
* If there are some removed value that haven't been dealt with,
|
|
18716
18691
|
* we need to create a new animation that falls back either to the value
|
|
@@ -18858,7 +18833,7 @@ var PanSession = /** @class */function () {
|
|
|
18858
18833
|
if (!isPanStarted && !isDistancePastThreshold) return;
|
|
18859
18834
|
var point = info.point;
|
|
18860
18835
|
var timestamp = getFrameData().timestamp;
|
|
18861
|
-
_this.history.push(_assign
|
|
18836
|
+
_this.history.push(_assign(_assign({}, point), {
|
|
18862
18837
|
timestamp: timestamp
|
|
18863
18838
|
}));
|
|
18864
18839
|
var _a = _this.handlers,
|
|
@@ -18900,7 +18875,7 @@ var PanSession = /** @class */function () {
|
|
|
18900
18875
|
var initialInfo = transformPoint(info, this.transformPagePoint);
|
|
18901
18876
|
var point = initialInfo.point;
|
|
18902
18877
|
var timestamp = getFrameData().timestamp;
|
|
18903
|
-
this.history = [_assign
|
|
18878
|
+
this.history = [_assign(_assign({}, point), {
|
|
18904
18879
|
timestamp: timestamp
|
|
18905
18880
|
})];
|
|
18906
18881
|
var onSessionStart = handlers.onSessionStart;
|
|
@@ -19065,8 +19040,8 @@ function axisBox() {
|
|
|
19065
19040
|
}
|
|
19066
19041
|
function copyAxisBox(box) {
|
|
19067
19042
|
return {
|
|
19068
|
-
x: _assign
|
|
19069
|
-
y: _assign
|
|
19043
|
+
x: _assign({}, box.x),
|
|
19044
|
+
y: _assign({}, box.y)
|
|
19070
19045
|
};
|
|
19071
19046
|
}
|
|
19072
19047
|
/**
|
|
@@ -19080,8 +19055,8 @@ var zeroDelta = {
|
|
|
19080
19055
|
};
|
|
19081
19056
|
function delta() {
|
|
19082
19057
|
return {
|
|
19083
|
-
x: _assign
|
|
19084
|
-
y: _assign
|
|
19058
|
+
x: _assign({}, zeroDelta),
|
|
19059
|
+
y: _assign({}, zeroDelta)
|
|
19085
19060
|
};
|
|
19086
19061
|
}
|
|
19087
19062
|
|
|
@@ -19978,8 +19953,8 @@ var VisualElementDragControls = /** @class */function () {
|
|
|
19978
19953
|
dragElastic = _f === void 0 ? defaultElastic : _f,
|
|
19979
19954
|
_g = _a.dragMomentum,
|
|
19980
19955
|
dragMomentum = _g === void 0 ? true : _g,
|
|
19981
|
-
remainingProps = __rest
|
|
19982
|
-
this.props = _assign
|
|
19956
|
+
remainingProps = __rest(_a, ["drag", "dragDirectionLock", "dragPropagation", "dragConstraints", "dragElastic", "dragMomentum"]);
|
|
19957
|
+
this.props = _assign({
|
|
19983
19958
|
drag: drag,
|
|
19984
19959
|
dragDirectionLock: dragDirectionLock,
|
|
19985
19960
|
dragPropagation: dragPropagation,
|
|
@@ -20062,7 +20037,7 @@ var VisualElementDragControls = /** @class */function () {
|
|
|
20062
20037
|
*/
|
|
20063
20038
|
var bounceStiffness = dragElastic ? 200 : 1000000;
|
|
20064
20039
|
var bounceDamping = dragElastic ? 40 : 10000000;
|
|
20065
|
-
var inertia = _assign
|
|
20040
|
+
var inertia = _assign(_assign({
|
|
20066
20041
|
type: "inertia",
|
|
20067
20042
|
velocity: dragMomentum ? velocity[axis] : 0,
|
|
20068
20043
|
bounceStiffness: bounceStiffness,
|
|
@@ -20246,7 +20221,7 @@ function useDrag(props) {
|
|
|
20246
20221
|
visualElement: visualElement
|
|
20247
20222
|
});
|
|
20248
20223
|
});
|
|
20249
|
-
dragControls.setProps(_assign
|
|
20224
|
+
dragControls.setProps(_assign(_assign({}, props), {
|
|
20250
20225
|
transformPagePoint: transformPagePoint
|
|
20251
20226
|
}));
|
|
20252
20227
|
// If we've been provided a DragControls for manual control over the drag gesture,
|
|
@@ -20379,7 +20354,7 @@ function getVariableValue(current, element, depth) {
|
|
|
20379
20354
|
*/
|
|
20380
20355
|
function resolveCSSVariables(visualElement, _a, transitionEnd) {
|
|
20381
20356
|
var _b;
|
|
20382
|
-
var target = __rest
|
|
20357
|
+
var target = __rest(_a, []);
|
|
20383
20358
|
var element = visualElement.getInstance();
|
|
20384
20359
|
if (!(element instanceof HTMLElement)) return {
|
|
20385
20360
|
target: target,
|
|
@@ -20388,7 +20363,7 @@ function resolveCSSVariables(visualElement, _a, transitionEnd) {
|
|
|
20388
20363
|
// If `transitionEnd` isn't `undefined`, clone it. We could clone `target` and `transitionEnd`
|
|
20389
20364
|
// only if they change but I think this reads clearer and this isn't a performance-critical path.
|
|
20390
20365
|
if (transitionEnd) {
|
|
20391
|
-
transitionEnd = _assign
|
|
20366
|
+
transitionEnd = _assign({}, transitionEnd);
|
|
20392
20367
|
}
|
|
20393
20368
|
// Go through existing `MotionValue`s and ensure any existing CSS variables are resolved
|
|
20394
20369
|
visualElement.forEachValue(function (value) {
|
|
@@ -20500,7 +20475,7 @@ var borderCorrectionDefinition = {
|
|
|
20500
20475
|
process: correctBorderRadius
|
|
20501
20476
|
};
|
|
20502
20477
|
var defaultScaleCorrectors = {
|
|
20503
|
-
borderRadius: _assign
|
|
20478
|
+
borderRadius: _assign(_assign({}, borderCorrectionDefinition), {
|
|
20504
20479
|
applyTo: ["borderTopLeftRadius", "borderTopRightRadius", "borderBottomLeftRadius", "borderBottomRightRadius"]
|
|
20505
20480
|
}),
|
|
20506
20481
|
borderTopLeftRadius: borderCorrectionDefinition,
|
|
@@ -20549,7 +20524,7 @@ var Animate = /** @class */function (_super) {
|
|
|
20549
20524
|
shouldStackAnimate = _a.shouldStackAnimate,
|
|
20550
20525
|
onComplete = _a.onComplete,
|
|
20551
20526
|
prevParent = _a.prevParent,
|
|
20552
|
-
config = __rest
|
|
20527
|
+
config = __rest(_a, ["originBox", "targetBox", "visibilityAction", "shouldStackAnimate", "onComplete", "prevParent"]);
|
|
20553
20528
|
var _b = _this.props,
|
|
20554
20529
|
visualElement = _b.visualElement,
|
|
20555
20530
|
layout = _b.layout;
|
|
@@ -20629,7 +20604,7 @@ var Animate = /** @class */function (_super) {
|
|
|
20629
20604
|
} else if (boxHasMoved) {
|
|
20630
20605
|
// If the box has moved, animate between it's current visual state and its
|
|
20631
20606
|
// final state
|
|
20632
|
-
return _this.animateAxis(axis, target[axis], origin[axis], _assign
|
|
20607
|
+
return _this.animateAxis(axis, target[axis], origin[axis], _assign(_assign({}, config), {
|
|
20633
20608
|
isRelative: isRelative
|
|
20634
20609
|
}));
|
|
20635
20610
|
} else {
|
|
@@ -20740,7 +20715,7 @@ var Animate = /** @class */function (_super) {
|
|
|
20740
20715
|
function AnimateLayoutContextProvider(props) {
|
|
20741
20716
|
var _a = __read(usePresence(), 2),
|
|
20742
20717
|
safeToRemove = _a[1];
|
|
20743
|
-
return /*#__PURE__*/React__namespace.createElement(Animate, _assign
|
|
20718
|
+
return /*#__PURE__*/React__namespace.createElement(Animate, _assign({}, props, {
|
|
20744
20719
|
safeToRemove: safeToRemove
|
|
20745
20720
|
}));
|
|
20746
20721
|
}
|
|
@@ -20915,7 +20890,7 @@ var Measure = /** @class */function (_super) {
|
|
|
20915
20890
|
function MeasureContextProvider(props) {
|
|
20916
20891
|
var syncLayout = React.useContext(SharedLayoutContext);
|
|
20917
20892
|
var framerSyncLayout = React.useContext(FramerTreeLayoutContext);
|
|
20918
|
-
return /*#__PURE__*/React__namespace.default.createElement(Measure, _assign
|
|
20893
|
+
return /*#__PURE__*/React__namespace.default.createElement(Measure, _assign({}, props, {
|
|
20919
20894
|
syncLayout: syncLayout,
|
|
20920
20895
|
framerSyncLayout: framerSyncLayout
|
|
20921
20896
|
}));
|
|
@@ -21232,7 +21207,7 @@ var visualElement = function visualElement(_a) {
|
|
|
21232
21207
|
* When values are removed from all animation props we need to search
|
|
21233
21208
|
* for a fallback value to animate to. These values are tracked in baseTarget.
|
|
21234
21209
|
*/
|
|
21235
|
-
var baseTarget = _assign
|
|
21210
|
+
var baseTarget = _assign({}, latestValues);
|
|
21236
21211
|
// Internal methods ========================
|
|
21237
21212
|
/**
|
|
21238
21213
|
* On mount, this will be hydrated with a callback to disconnect
|
|
@@ -21330,7 +21305,7 @@ var visualElement = function visualElement(_a) {
|
|
|
21330
21305
|
*/
|
|
21331
21306
|
var isControllingVariants = checkIfControllingVariants(props);
|
|
21332
21307
|
var isVariantNode = checkIfVariantNode(props);
|
|
21333
|
-
var element = _assign
|
|
21308
|
+
var element = _assign(_assign({
|
|
21334
21309
|
treeType: treeType,
|
|
21335
21310
|
/**
|
|
21336
21311
|
* This is a mirror of the internal instance prop, which keeps
|
|
@@ -22001,8 +21976,8 @@ var checkAndConvertChangedValueTypes = function checkAndConvertChangedValueTypes
|
|
|
22001
21976
|
if (transitionEnd === void 0) {
|
|
22002
21977
|
transitionEnd = {};
|
|
22003
21978
|
}
|
|
22004
|
-
target = _assign
|
|
22005
|
-
transitionEnd = _assign
|
|
21979
|
+
target = _assign({}, target);
|
|
21980
|
+
transitionEnd = _assign({}, transitionEnd);
|
|
22006
21981
|
var targetPositionalKeys = Object.keys(target).filter(isPositionalKey);
|
|
22007
21982
|
// We want to remove any transform values that could affect the element's bounding box before
|
|
22008
21983
|
// it's measured. We'll reapply these later.
|
|
@@ -22179,7 +22154,7 @@ var htmlConfig = {
|
|
|
22179
22154
|
}
|
|
22180
22155
|
var transition = _a.transition,
|
|
22181
22156
|
transitionEnd = _a.transitionEnd,
|
|
22182
|
-
target = __rest
|
|
22157
|
+
target = __rest(_a, ["transition", "transitionEnd"]);
|
|
22183
22158
|
var origin = getOrigin(target, transition || {}, element);
|
|
22184
22159
|
/**
|
|
22185
22160
|
* If Framer has provided a function to convert `Color` etc value types, convert them
|
|
@@ -22195,7 +22170,7 @@ var htmlConfig = {
|
|
|
22195
22170
|
transitionEnd = parsed.transitionEnd;
|
|
22196
22171
|
target = parsed.target;
|
|
22197
22172
|
}
|
|
22198
|
-
return _assign
|
|
22173
|
+
return _assign({
|
|
22199
22174
|
transition: transition,
|
|
22200
22175
|
transitionEnd: transitionEnd
|
|
22201
22176
|
}, target);
|
|
@@ -22212,7 +22187,7 @@ var htmlConfig = {
|
|
|
22212
22187
|
};
|
|
22213
22188
|
var htmlVisualElement = visualElement(htmlConfig);
|
|
22214
22189
|
|
|
22215
|
-
var svgVisualElement = visualElement(_assign
|
|
22190
|
+
var svgVisualElement = visualElement(_assign(_assign({}, htmlConfig), {
|
|
22216
22191
|
getBaseTarget: function getBaseTarget(props, key) {
|
|
22217
22192
|
return props[key];
|
|
22218
22193
|
},
|
|
@@ -22240,7 +22215,7 @@ var createDomVisualElement = function createDomVisualElement(Component, options)
|
|
|
22240
22215
|
});
|
|
22241
22216
|
};
|
|
22242
22217
|
|
|
22243
|
-
var featureBundle = _assign
|
|
22218
|
+
var featureBundle = _assign(_assign(_assign(_assign({}, animations), gestureAnimations), drag), layoutAnimations);
|
|
22244
22219
|
/**
|
|
22245
22220
|
* HTML & SVG components, optimised for use with gestures and animation. These can be used as
|
|
22246
22221
|
* drop-in replacements for any HTML & SVG component, all CSS & SVG properties are supported.
|
|
@@ -30944,7 +30919,7 @@ function createSidecarMedium(options) {
|
|
|
30944
30919
|
options = {};
|
|
30945
30920
|
}
|
|
30946
30921
|
var medium = innerCreateMedium(null);
|
|
30947
|
-
medium.options = _assign
|
|
30922
|
+
medium.options = _assign({
|
|
30948
30923
|
async: true,
|
|
30949
30924
|
ssr: false
|
|
30950
30925
|
}, options);
|
|
@@ -30953,7 +30928,7 @@ function createSidecarMedium(options) {
|
|
|
30953
30928
|
|
|
30954
30929
|
var SideCar$1 = function SideCar(_a) {
|
|
30955
30930
|
var sideCar = _a.sideCar,
|
|
30956
|
-
rest = __rest
|
|
30931
|
+
rest = __rest(_a, ["sideCar"]);
|
|
30957
30932
|
if (!sideCar) {
|
|
30958
30933
|
throw new Error('Sidecar: please provide `sideCar` property to import the right car');
|
|
30959
30934
|
}
|
|
@@ -30961,7 +30936,7 @@ var SideCar$1 = function SideCar(_a) {
|
|
|
30961
30936
|
if (!Target) {
|
|
30962
30937
|
throw new Error('Sidecar medium not found');
|
|
30963
30938
|
}
|
|
30964
|
-
return /*#__PURE__*/React__namespace.createElement(Target, _assign
|
|
30939
|
+
return /*#__PURE__*/React__namespace.createElement(Target, _assign({}, rest));
|
|
30965
30940
|
};
|
|
30966
30941
|
SideCar$1.isSideCarExport = true;
|
|
30967
30942
|
function exportSidecar(medium, exported) {
|
|
@@ -31945,25 +31920,6 @@ if (__DEV__) {
|
|
|
31945
31920
|
FocusLock.displayName = "FocusLock";
|
|
31946
31921
|
}
|
|
31947
31922
|
|
|
31948
|
-
var _assign = function __assign() {
|
|
31949
|
-
_assign = Object.assign || function __assign(t) {
|
|
31950
|
-
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
31951
|
-
s = arguments[i];
|
|
31952
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p)) t[p] = s[p];
|
|
31953
|
-
}
|
|
31954
|
-
return t;
|
|
31955
|
-
};
|
|
31956
|
-
return _assign.apply(this, arguments);
|
|
31957
|
-
};
|
|
31958
|
-
function __rest(s, e) {
|
|
31959
|
-
var t = {};
|
|
31960
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];
|
|
31961
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
31962
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];
|
|
31963
|
-
}
|
|
31964
|
-
return t;
|
|
31965
|
-
}
|
|
31966
|
-
|
|
31967
31923
|
var zeroRightClassName = 'right-scroll-bar-position';
|
|
31968
31924
|
var fullWidthClassName = 'width-before-scroll-bar';
|
|
31969
31925
|
var noScrollbarsClassName = 'with-scroll-bars-hidden';
|
|
@@ -40447,7 +40403,7 @@ function anatomy(name) {
|
|
|
40447
40403
|
return new Anatomy(name);
|
|
40448
40404
|
}
|
|
40449
40405
|
function toRef(operand) {
|
|
40450
|
-
if (isObject
|
|
40406
|
+
if (isObject(operand) && operand.reference) {
|
|
40451
40407
|
return operand.reference;
|
|
40452
40408
|
}
|
|
40453
40409
|
return String(operand);
|
|
@@ -45249,72 +45205,72 @@ var Link_styles = merge$1(theme.components.Link, {
|
|
|
45249
45205
|
defaultProps: defaultProps$6
|
|
45250
45206
|
});
|
|
45251
45207
|
|
|
45252
|
-
|
|
45253
|
-
|
|
45254
|
-
|
|
45255
|
-
|
|
45256
|
-
button: {
|
|
45257
|
-
display: 'flex',
|
|
45258
|
-
gridGap: 3.5,
|
|
45259
|
-
alignItems: 'center',
|
|
45260
|
-
fontSize: 'sm',
|
|
45261
|
-
fontWeight: 'semibold',
|
|
45262
|
-
_hover: {
|
|
45263
|
-
backgroundColor: 'gray.50'
|
|
45264
|
-
}
|
|
45265
|
-
},
|
|
45266
|
-
container: {
|
|
45267
|
-
borderColor: 'gray.medium'
|
|
45268
|
-
}
|
|
45269
|
-
};
|
|
45270
|
-
var variants$8 = {
|
|
45271
|
-
lined: {
|
|
45208
|
+
const baseStyle$8 = {
|
|
45209
|
+
icon: {
|
|
45210
|
+
color: 'primary.default',
|
|
45211
|
+
},
|
|
45272
45212
|
button: {
|
|
45273
|
-
|
|
45274
|
-
|
|
45213
|
+
display: 'flex',
|
|
45214
|
+
gridGap: 3.5,
|
|
45215
|
+
alignItems: 'center',
|
|
45216
|
+
fontSize: 'sm',
|
|
45217
|
+
fontWeight: 'semibold',
|
|
45218
|
+
_hover: {
|
|
45219
|
+
backgroundColor: 'gray.50',
|
|
45220
|
+
},
|
|
45275
45221
|
},
|
|
45276
45222
|
container: {
|
|
45277
|
-
|
|
45278
|
-
_last: {
|
|
45279
|
-
borderBottomWidth: 1
|
|
45280
|
-
}
|
|
45223
|
+
borderColor: 'gray.medium',
|
|
45281
45224
|
},
|
|
45282
|
-
|
|
45283
|
-
|
|
45284
|
-
|
|
45285
|
-
|
|
45286
|
-
|
|
45287
|
-
|
|
45288
|
-
|
|
45289
|
-
|
|
45290
|
-
|
|
45225
|
+
};
|
|
45226
|
+
const variants$8 = {
|
|
45227
|
+
lined: {
|
|
45228
|
+
button: {
|
|
45229
|
+
px: 2,
|
|
45230
|
+
py: 3,
|
|
45231
|
+
},
|
|
45232
|
+
container: {
|
|
45233
|
+
borderTopWidth: 1,
|
|
45234
|
+
_last: {
|
|
45235
|
+
borderBottomWidth: 1,
|
|
45236
|
+
},
|
|
45237
|
+
},
|
|
45238
|
+
panel: {
|
|
45239
|
+
px: 2,
|
|
45240
|
+
py: 3,
|
|
45241
|
+
},
|
|
45291
45242
|
},
|
|
45292
|
-
|
|
45293
|
-
|
|
45294
|
-
|
|
45295
|
-
|
|
45296
|
-
|
|
45297
|
-
|
|
45298
|
-
|
|
45299
|
-
|
|
45300
|
-
|
|
45301
|
-
|
|
45302
|
-
|
|
45243
|
+
contained: {
|
|
45244
|
+
button: {
|
|
45245
|
+
px: 4,
|
|
45246
|
+
py: 3,
|
|
45247
|
+
},
|
|
45248
|
+
container: {
|
|
45249
|
+
borderLeftWidth: 1,
|
|
45250
|
+
borderRightWidth: 1,
|
|
45251
|
+
_first: {
|
|
45252
|
+
borderTopLeftRadius: 4,
|
|
45253
|
+
borderTopRightRadius: 4,
|
|
45254
|
+
},
|
|
45255
|
+
_last: {
|
|
45256
|
+
borderBottomLeftRadius: 4,
|
|
45257
|
+
borderBottomRightRadius: 4,
|
|
45258
|
+
},
|
|
45259
|
+
},
|
|
45260
|
+
panel: {
|
|
45261
|
+
p: 4,
|
|
45262
|
+
borderColor: 'gray.medium',
|
|
45263
|
+
borderTopWidth: 1,
|
|
45264
|
+
},
|
|
45303
45265
|
},
|
|
45304
|
-
panel: {
|
|
45305
|
-
p: 4,
|
|
45306
|
-
borderColor: 'gray.medium',
|
|
45307
|
-
borderTopWidth: 1
|
|
45308
|
-
}
|
|
45309
|
-
}
|
|
45310
45266
|
};
|
|
45311
|
-
|
|
45312
|
-
|
|
45267
|
+
const defaultProps$5 = {
|
|
45268
|
+
variant: 'lined',
|
|
45313
45269
|
};
|
|
45314
45270
|
var index$a = merge$1(theme.components.Accordion, {
|
|
45315
|
-
|
|
45316
|
-
|
|
45317
|
-
|
|
45271
|
+
variants: variants$8,
|
|
45272
|
+
baseStyle: baseStyle$8,
|
|
45273
|
+
defaultProps: defaultProps$5,
|
|
45318
45274
|
});
|
|
45319
45275
|
|
|
45320
45276
|
var colorScheme = {
|
|
@@ -47222,526 +47178,13 @@ function requireTemplate() {
|
|
|
47222
47178
|
var templateExports = requireTemplate();
|
|
47223
47179
|
var template = /*@__PURE__*/getDefaultExportFromCjs(templateExports);
|
|
47224
47180
|
|
|
47225
|
-
var
|
|
47226
|
-
|
|
47227
|
-
|
|
47228
|
-
|
|
47229
|
-
* Better handling for window object in SSR environment
|
|
47230
|
-
* https://github.com/nolimits4web/ssr-window
|
|
47231
|
-
*
|
|
47232
|
-
* Copyright 2020, Vladimir Kharlampidi
|
|
47233
|
-
*
|
|
47234
|
-
* Licensed under MIT
|
|
47235
|
-
*
|
|
47236
|
-
* Released on: May 12, 2020
|
|
47237
|
-
*/
|
|
47238
|
-
/* eslint-disable no-param-reassign */
|
|
47239
|
-
function isObject(obj) {
|
|
47240
|
-
return obj !== null && _typeof$1(obj) === 'object' && 'constructor' in obj && obj.constructor === Object;
|
|
47241
|
-
}
|
|
47242
|
-
function extend(target, src) {
|
|
47243
|
-
if (target === void 0) {
|
|
47244
|
-
target = {};
|
|
47245
|
-
}
|
|
47246
|
-
if (src === void 0) {
|
|
47247
|
-
src = {};
|
|
47248
|
-
}
|
|
47249
|
-
Object.keys(src).forEach(function (key) {
|
|
47250
|
-
if (typeof target[key] === 'undefined') target[key] = src[key];else if (isObject(src[key]) && isObject(target[key]) && Object.keys(src[key]).length > 0) {
|
|
47251
|
-
extend(target[key], src[key]);
|
|
47252
|
-
}
|
|
47253
|
-
});
|
|
47254
|
-
}
|
|
47255
|
-
var doc = typeof document !== 'undefined' ? document : {};
|
|
47256
|
-
var ssrDocument = {
|
|
47257
|
-
body: {},
|
|
47258
|
-
addEventListener: function addEventListener() {},
|
|
47259
|
-
removeEventListener: function removeEventListener() {},
|
|
47260
|
-
activeElement: {
|
|
47261
|
-
blur: function blur() {},
|
|
47262
|
-
nodeName: ''
|
|
47263
|
-
},
|
|
47264
|
-
querySelector: function querySelector() {
|
|
47265
|
-
return null;
|
|
47266
|
-
},
|
|
47267
|
-
querySelectorAll: function querySelectorAll() {
|
|
47268
|
-
return [];
|
|
47269
|
-
},
|
|
47270
|
-
getElementById: function getElementById() {
|
|
47271
|
-
return null;
|
|
47272
|
-
},
|
|
47273
|
-
createEvent: function createEvent() {
|
|
47274
|
-
return {
|
|
47275
|
-
initEvent: function initEvent() {}
|
|
47276
|
-
};
|
|
47277
|
-
},
|
|
47278
|
-
createElement: function createElement() {
|
|
47279
|
-
return {
|
|
47280
|
-
children: [],
|
|
47281
|
-
childNodes: [],
|
|
47282
|
-
style: {},
|
|
47283
|
-
setAttribute: function setAttribute() {},
|
|
47284
|
-
getElementsByTagName: function getElementsByTagName() {
|
|
47285
|
-
return [];
|
|
47286
|
-
}
|
|
47287
|
-
};
|
|
47288
|
-
},
|
|
47289
|
-
createElementNS: function createElementNS() {
|
|
47290
|
-
return {};
|
|
47291
|
-
},
|
|
47292
|
-
importNode: function importNode() {
|
|
47293
|
-
return null;
|
|
47294
|
-
},
|
|
47295
|
-
location: {
|
|
47296
|
-
hash: '',
|
|
47297
|
-
host: '',
|
|
47298
|
-
hostname: '',
|
|
47299
|
-
href: '',
|
|
47300
|
-
origin: '',
|
|
47301
|
-
pathname: '',
|
|
47302
|
-
protocol: '',
|
|
47303
|
-
search: ''
|
|
47304
|
-
}
|
|
47305
|
-
};
|
|
47306
|
-
extend(doc, ssrDocument);
|
|
47307
|
-
var win = typeof window !== 'undefined' ? window : {};
|
|
47308
|
-
var ssrWindow = {
|
|
47309
|
-
document: ssrDocument,
|
|
47310
|
-
navigator: {
|
|
47311
|
-
userAgent: ''
|
|
47312
|
-
},
|
|
47313
|
-
location: {
|
|
47314
|
-
hash: '',
|
|
47315
|
-
host: '',
|
|
47316
|
-
hostname: '',
|
|
47317
|
-
href: '',
|
|
47318
|
-
origin: '',
|
|
47319
|
-
pathname: '',
|
|
47320
|
-
protocol: '',
|
|
47321
|
-
search: ''
|
|
47322
|
-
},
|
|
47323
|
-
history: {
|
|
47324
|
-
replaceState: function replaceState() {},
|
|
47325
|
-
pushState: function pushState() {},
|
|
47326
|
-
go: function go() {},
|
|
47327
|
-
back: function back() {}
|
|
47328
|
-
},
|
|
47329
|
-
CustomEvent: function CustomEvent() {
|
|
47330
|
-
return this;
|
|
47331
|
-
},
|
|
47332
|
-
addEventListener: function addEventListener() {},
|
|
47333
|
-
removeEventListener: function removeEventListener() {},
|
|
47334
|
-
getComputedStyle: function getComputedStyle() {
|
|
47335
|
-
return {
|
|
47336
|
-
getPropertyValue: function getPropertyValue() {
|
|
47337
|
-
return '';
|
|
47338
|
-
}
|
|
47339
|
-
};
|
|
47340
|
-
},
|
|
47341
|
-
Image: function Image() {},
|
|
47342
|
-
Date: function Date() {},
|
|
47343
|
-
screen: {},
|
|
47344
|
-
setTimeout: function setTimeout() {},
|
|
47345
|
-
clearTimeout: function clearTimeout() {},
|
|
47346
|
-
matchMedia: function matchMedia() {
|
|
47347
|
-
return {};
|
|
47181
|
+
var _excluded$l = ["isSSR", "cloudinaryImageId", "cloudinaryTemplate", "cloudinaryCloudName", "htmlWidth", "htmlHeight", "quality", "lazyLoad"];
|
|
47182
|
+
function isHighDensityDisplay() {
|
|
47183
|
+
if (typeof window === 'undefined') {
|
|
47184
|
+
return false;
|
|
47348
47185
|
}
|
|
47349
|
-
|
|
47350
|
-
extend(win, ssrWindow);
|
|
47351
|
-
|
|
47352
|
-
var ssrWindow_esm = /*#__PURE__*/Object.freeze({
|
|
47353
|
-
__proto__: null,
|
|
47354
|
-
document: doc,
|
|
47355
|
-
extend: extend,
|
|
47356
|
-
window: win
|
|
47357
|
-
});
|
|
47358
|
-
|
|
47359
|
-
var require$$0 = /*@__PURE__*/getAugmentedNamespace(ssrWindow_esm);
|
|
47360
|
-
|
|
47361
|
-
var hasRequiredEnvironment$1;
|
|
47362
|
-
function requireEnvironment$1() {
|
|
47363
|
-
if (hasRequiredEnvironment$1) return environment$1;
|
|
47364
|
-
hasRequiredEnvironment$1 = 1;
|
|
47365
|
-
Object.defineProperty(environment$1, "__esModule", {
|
|
47366
|
-
value: true
|
|
47367
|
-
});
|
|
47368
|
-
environment$1["default"] = void 0;
|
|
47369
|
-
var _ssrWindow = require$$0;
|
|
47370
|
-
// Most of the methods are pulled from https://is.js.org/. That library has many others that we'll never use so they are added here and made to work with SSR.
|
|
47371
|
-
|
|
47372
|
-
var appVersion = (_ssrWindow.window.navigator && _ssrWindow.window.navigator.appVersion || '').toLowerCase();
|
|
47373
|
-
var userAgent = (_ssrWindow.window.navigator && _ssrWindow.window.navigator.userAgent || '').toLowerCase();
|
|
47374
|
-
var vendor = (_ssrWindow.window.navigator && _ssrWindow.window.navigator.vendor || '').toLowerCase();
|
|
47375
|
-
var comparator = {
|
|
47376
|
-
'<': function _(a, b) {
|
|
47377
|
-
return a < b;
|
|
47378
|
-
},
|
|
47379
|
-
'<=': function _(a, b) {
|
|
47380
|
-
return a <= b;
|
|
47381
|
-
},
|
|
47382
|
-
'>': function _(a, b) {
|
|
47383
|
-
return a > b;
|
|
47384
|
-
},
|
|
47385
|
-
'>=': function _(a, b) {
|
|
47386
|
-
return a >= b;
|
|
47387
|
-
}
|
|
47388
|
-
};
|
|
47389
|
-
var compareVersion = function compareVersion(version, range) {
|
|
47390
|
-
var string = String(range);
|
|
47391
|
-
var n = Number(string.match(/\d+/) || NaN);
|
|
47392
|
-
var op = string.match(/^[<>]=?|/)[0];
|
|
47393
|
-
return comparator[op] ? comparator[op](version, n) : version === n || n !== n; // eslint-disable-line no-self-compare
|
|
47394
|
-
};
|
|
47395
|
-
|
|
47396
|
-
/**
|
|
47397
|
-
* Utilities for working with the execution environment.
|
|
47398
|
-
* @module EnvironmentUtils
|
|
47399
|
-
*/
|
|
47400
|
-
var EnvironmentUtils = {
|
|
47401
|
-
/**
|
|
47402
|
-
* Determines whether the code is being executed in the browser.
|
|
47403
|
-
* @static
|
|
47404
|
-
* @function isBrowser
|
|
47405
|
-
* @example
|
|
47406
|
-
* EnvironmentUtils.isBrowser();
|
|
47407
|
-
* @returns {Boolean} - Whether the environment is the browser.
|
|
47408
|
-
*/
|
|
47409
|
-
isBrowser: function isBrowser() {
|
|
47410
|
-
return typeof window !== 'undefined';
|
|
47411
|
-
},
|
|
47412
|
-
/**
|
|
47413
|
-
* Determines whether the code is being executed in Google Chrome.
|
|
47414
|
-
* @static
|
|
47415
|
-
* @function isChrome
|
|
47416
|
-
* @param {Number|String} [range] - The version range to test against.
|
|
47417
|
-
* @param {String} [ua=navigator.userAgent] - The user agent to test against.
|
|
47418
|
-
* @example
|
|
47419
|
-
* EnvironmentUtils.isChrome();
|
|
47420
|
-
* @returns {Boolean} - Whether the environment is Google Chrome.
|
|
47421
|
-
*/
|
|
47422
|
-
isChrome: function isChrome(range) {
|
|
47423
|
-
var ua = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : userAgent;
|
|
47424
|
-
var match = /google inc/.test(vendor) ? ua.match(/(?:chrome|crios)\/(\d+)/) : null;
|
|
47425
|
-
return match !== null && !this.isOpera(range, ua) && compareVersion(match[1], range);
|
|
47426
|
-
},
|
|
47427
|
-
/**
|
|
47428
|
-
* Determines whether the code is being executed in Mozilla Firefox.
|
|
47429
|
-
* @static
|
|
47430
|
-
* @function isFirefox
|
|
47431
|
-
* @param {Number|String} [range] - The version range to test against.
|
|
47432
|
-
* @param {String} [ua=navigator.userAgent] - The user agent to test against.
|
|
47433
|
-
* @example
|
|
47434
|
-
* EnvironmentUtils.isFirefox();
|
|
47435
|
-
* @returns {Boolean} - Whether the environment is Mozilla Firefox.
|
|
47436
|
-
*/
|
|
47437
|
-
isFirefox: function isFirefox(range) {
|
|
47438
|
-
var ua = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : userAgent;
|
|
47439
|
-
var match = ua.match(/(?:firefox|fxios)\/(\d+)/);
|
|
47440
|
-
return match !== null && compareVersion(match[1], range);
|
|
47441
|
-
},
|
|
47442
|
-
/**
|
|
47443
|
-
* Determines whether the code is being executed in Apple Safari.
|
|
47444
|
-
* @static
|
|
47445
|
-
* @function isSafari
|
|
47446
|
-
* @param {Number|String} [range] - The version range to test against.
|
|
47447
|
-
* @param {String} [ua=navigator.userAgent] - The user agent to test against.
|
|
47448
|
-
* @example
|
|
47449
|
-
* EnvironmentUtils.isSafari();
|
|
47450
|
-
* @returns {Boolean} - Whether the environment is Apple Safari.
|
|
47451
|
-
*/
|
|
47452
|
-
isSafari: function isSafari(range) {
|
|
47453
|
-
var ua = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : userAgent;
|
|
47454
|
-
var match = ua.match(/version\/(\d+).+?safari/);
|
|
47455
|
-
return match !== null && compareVersion(match[1], range);
|
|
47456
|
-
},
|
|
47457
|
-
/**
|
|
47458
|
-
* Determines whether the code is being executed in Microsoft Edge.
|
|
47459
|
-
* @static
|
|
47460
|
-
* @function isEdge
|
|
47461
|
-
* @param {Number|String} [range] - The version range to test against.
|
|
47462
|
-
* @param {String} [ua=navigator.userAgent] - The user agent to test against.
|
|
47463
|
-
* @example
|
|
47464
|
-
* EnvironmentUtils.isEdge();
|
|
47465
|
-
* @returns {Boolean} - Whether the environment is Microsoft Edge.
|
|
47466
|
-
*/
|
|
47467
|
-
isEdge: function isEdge(range) {
|
|
47468
|
-
var ua = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : userAgent;
|
|
47469
|
-
var match = ua.match(/edge\/(\d+)/);
|
|
47470
|
-
return match !== null && compareVersion(match[1], range);
|
|
47471
|
-
},
|
|
47472
|
-
/**
|
|
47473
|
-
* Determines whether the code is being executed in Microsoft Internet Explorer.
|
|
47474
|
-
* @static
|
|
47475
|
-
* @function isIE
|
|
47476
|
-
* @param {Number|String} [range] - The version range to test against.
|
|
47477
|
-
* @param {String} [ua=navigator.userAgent] - The user agent to test against.
|
|
47478
|
-
* @example
|
|
47479
|
-
* EnvironmentUtils.isIE();
|
|
47480
|
-
* @returns {Boolean} - Whether the environment is Microsoft Internet Explorer.
|
|
47481
|
-
*/
|
|
47482
|
-
isIE: function isIE(range) {
|
|
47483
|
-
var ua = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : userAgent;
|
|
47484
|
-
var match = ua.match(/(?:msie |trident.+?; rv:)(\d+)/);
|
|
47485
|
-
return match !== null && compareVersion(match[1], range);
|
|
47486
|
-
},
|
|
47487
|
-
/**
|
|
47488
|
-
* Determines whether the code is being executed in Opera.
|
|
47489
|
-
* @static
|
|
47490
|
-
* @function isOpera
|
|
47491
|
-
* @param {Number|String} [range] - The version range to test against.
|
|
47492
|
-
* @param {String} [ua=navigator.userAgent] - The user agent to test against.
|
|
47493
|
-
* @example
|
|
47494
|
-
* EnvironmentUtils.isOpera();
|
|
47495
|
-
* @returns {Boolean} - Whether the environment is Opera.
|
|
47496
|
-
*/
|
|
47497
|
-
isOpera: function isOpera(range) {
|
|
47498
|
-
var ua = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : userAgent;
|
|
47499
|
-
var match = ua.match(/(?:^opera.+?version|opr)\/(\d+)/);
|
|
47500
|
-
return match !== null && compareVersion(match[1], range);
|
|
47501
|
-
},
|
|
47502
|
-
/**
|
|
47503
|
-
* Determines whether the code is being executed in iOS.
|
|
47504
|
-
* @static
|
|
47505
|
-
* @function isiOS
|
|
47506
|
-
* @param {String} [ua=navigator.userAgent] - The user agent to test against.
|
|
47507
|
-
* @example
|
|
47508
|
-
* EnvironmentUtils.isiOS();
|
|
47509
|
-
* @returns {Boolean} - Whether the environment is iOS.
|
|
47510
|
-
*/
|
|
47511
|
-
isiOS: function isiOS() {
|
|
47512
|
-
var ua = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : userAgent;
|
|
47513
|
-
return this.isiPhone(null, ua) || this.isiPad(null, ua) || this.isiPod(null, ua);
|
|
47514
|
-
},
|
|
47515
|
-
/**
|
|
47516
|
-
* Determines whether the code is being executed on an iPhone.
|
|
47517
|
-
* @static
|
|
47518
|
-
* @function isiPhone
|
|
47519
|
-
* @param {Number|String} [range] - The version range to test against.
|
|
47520
|
-
* @param {String} [ua=navigator.userAgent] - The user agent to test against.
|
|
47521
|
-
* @example
|
|
47522
|
-
* EnvironmentUtils.isiPhone();
|
|
47523
|
-
* EnvironmentUtils.isiPhone(9);
|
|
47524
|
-
* EnvironmentUtils.isiPhone('>=7');
|
|
47525
|
-
* EnvironmentUtils.isiPhone('<8');
|
|
47526
|
-
* @returns {Boolean} - Whether the environment is iPhone.
|
|
47527
|
-
*/
|
|
47528
|
-
isiPhone: function isiPhone(range) {
|
|
47529
|
-
var ua = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : userAgent;
|
|
47530
|
-
// avoid false positive for Facebook in-app browser on ipad;
|
|
47531
|
-
// original iphone doesn't have the OS portion of the UA
|
|
47532
|
-
var match = this.isiPad(null, ua) ? null : ua.match(/iphone(?:.+?os (\d+))?/i);
|
|
47533
|
-
return match !== null && compareVersion(match[1] || 1, range);
|
|
47534
|
-
},
|
|
47535
|
-
/**
|
|
47536
|
-
* Determines whether the code is being executed on an iPad.
|
|
47537
|
-
* @static
|
|
47538
|
-
* @function isiPad
|
|
47539
|
-
* @param {Number|String} [range] - The version range to test against.
|
|
47540
|
-
* @param {String} [ua=navigator.userAgent] - The user agent to test against.
|
|
47541
|
-
* @example
|
|
47542
|
-
* EnvironmentUtils.isiPad();
|
|
47543
|
-
* EnvironmentUtils.isiPad(9);
|
|
47544
|
-
* EnvironmentUtils.isiPad('>=7');
|
|
47545
|
-
* EnvironmentUtils.isiPad('<8');
|
|
47546
|
-
* @returns {Boolean} - Whether the environment is iPad.
|
|
47547
|
-
*/
|
|
47548
|
-
isiPad: function isiPad(range) {
|
|
47549
|
-
var ua = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : userAgent;
|
|
47550
|
-
var match = ua.match(/ipad.+?os (\d+)/i);
|
|
47551
|
-
return match !== null && compareVersion(match[1], range);
|
|
47552
|
-
},
|
|
47553
|
-
/**
|
|
47554
|
-
* Determines whether the code is being executed on an iPod.
|
|
47555
|
-
* @static
|
|
47556
|
-
* @function isiPod
|
|
47557
|
-
* @param {Number|String} [range] - The version range to test against.
|
|
47558
|
-
* @param {String} [ua=navigator.userAgent] - The user agent to test against.
|
|
47559
|
-
* @example
|
|
47560
|
-
* EnvironmentUtils.isiPod();
|
|
47561
|
-
* EnvironmentUtils.isiPod(9);
|
|
47562
|
-
* EnvironmentUtils.isiPod('>=7');
|
|
47563
|
-
* EnvironmentUtils.isiPod('<8');
|
|
47564
|
-
* @returns {Boolean} - Whether the environment is iPod.
|
|
47565
|
-
*/
|
|
47566
|
-
isiPod: function isiPod(range) {
|
|
47567
|
-
var ua = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : userAgent;
|
|
47568
|
-
var match = ua.match(/ipod.+?os (\d+)/i);
|
|
47569
|
-
return match !== null && compareVersion(match[1], range);
|
|
47570
|
-
},
|
|
47571
|
-
/**
|
|
47572
|
-
* Determines whether the code is being executed in Android.
|
|
47573
|
-
* @static
|
|
47574
|
-
* @function isAndroid
|
|
47575
|
-
* @param {String} [ua=navigator.userAgent] - The user agent to test against.
|
|
47576
|
-
* @example
|
|
47577
|
-
* EnvironmentUtils.isAndroid();
|
|
47578
|
-
* @returns {Boolean} - Whether the environment is Android.
|
|
47579
|
-
*/
|
|
47580
|
-
isAndroid: function isAndroid() {
|
|
47581
|
-
var ua = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : userAgent;
|
|
47582
|
-
return /android/i.test(ua);
|
|
47583
|
-
},
|
|
47584
|
-
/**
|
|
47585
|
-
* Determines whether the code is being executed on an Android phone.
|
|
47586
|
-
* @static
|
|
47587
|
-
* @function isAndroidPhone
|
|
47588
|
-
* @param {String} [ua=navigator.userAgent] - The user agent to test against.
|
|
47589
|
-
* @example
|
|
47590
|
-
* EnvironmentUtils.isAndroidPhone();
|
|
47591
|
-
* @returns {Boolean} - Whether the environment is Android phone.
|
|
47592
|
-
*/
|
|
47593
|
-
isAndroidPhone: function isAndroidPhone() {
|
|
47594
|
-
var ua = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : userAgent;
|
|
47595
|
-
return /android/i.test(ua) && /mobile/i.test(ua);
|
|
47596
|
-
},
|
|
47597
|
-
/**
|
|
47598
|
-
* Determines whether the code is being executed on an Android tablet.
|
|
47599
|
-
* @static
|
|
47600
|
-
* @function isAndroidTablet
|
|
47601
|
-
* @param {String} [ua=navigator.userAgent] - The user agent to test against.
|
|
47602
|
-
* @example
|
|
47603
|
-
* EnvironmentUtils.isAndroidTablet();
|
|
47604
|
-
* @returns {Boolean} - Whether the environment is Android tablet.
|
|
47605
|
-
*/
|
|
47606
|
-
isAndroidTablet: function isAndroidTablet() {
|
|
47607
|
-
var ua = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : userAgent;
|
|
47608
|
-
return /android/i.test(ua) && !/mobile/i.test(ua);
|
|
47609
|
-
},
|
|
47610
|
-
/**
|
|
47611
|
-
* Determines whether the code is being executed on a Blackberry.
|
|
47612
|
-
* @static
|
|
47613
|
-
* @function isBlackberry
|
|
47614
|
-
* @param {String} [ua=navigator.userAgent] - The user agent to test against.
|
|
47615
|
-
* @example
|
|
47616
|
-
* EnvironmentUtils.isBlackberry();
|
|
47617
|
-
* @returns {Boolean} - Whether the environment is Blackberry.
|
|
47618
|
-
*/
|
|
47619
|
-
isBlackberry: function isBlackberry() {
|
|
47620
|
-
var ua = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : userAgent;
|
|
47621
|
-
return /blackberry/i.test(ua) || /bb10/i.test(ua);
|
|
47622
|
-
},
|
|
47623
|
-
/**
|
|
47624
|
-
* Determines whether the code is being executed on a Windows phone.
|
|
47625
|
-
* @static
|
|
47626
|
-
* @function isWindowsPhone
|
|
47627
|
-
* @param {String} [ua=navigator.userAgent] - The user agent to test against.
|
|
47628
|
-
* @example
|
|
47629
|
-
* EnvironmentUtils.isWindowsPhone();
|
|
47630
|
-
* @returns {Boolean} - Whether the environment is Windows phone.
|
|
47631
|
-
*/
|
|
47632
|
-
isWindowsPhone: function isWindowsPhone() {
|
|
47633
|
-
var ua = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : userAgent;
|
|
47634
|
-
return this.isWindows() && /phone/i.test(ua);
|
|
47635
|
-
},
|
|
47636
|
-
/**
|
|
47637
|
-
* Determines whether the code is being executed on a Windows tablet.
|
|
47638
|
-
* @static
|
|
47639
|
-
* @function isWindowsTablet
|
|
47640
|
-
* @param {String} [ua=navigator.userAgent] - The user agent to test against.
|
|
47641
|
-
* @example
|
|
47642
|
-
* EnvironmentUtils.isWindowsTablet();
|
|
47643
|
-
* @returns {Boolean} - Whether the environment is Windows tablet.
|
|
47644
|
-
*/
|
|
47645
|
-
isWindowsTablet: function isWindowsTablet() {
|
|
47646
|
-
var ua = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : userAgent;
|
|
47647
|
-
return this.isWindows() && !this.isWindowsPhone(ua) && /touch/i.test(ua);
|
|
47648
|
-
},
|
|
47649
|
-
/**
|
|
47650
|
-
* Determines whether the code is being executed on Windows.
|
|
47651
|
-
* @static
|
|
47652
|
-
* @function isWindows
|
|
47653
|
-
* @param {String} [ua=navigator.userAgent] - The user agent to test against.
|
|
47654
|
-
* @example
|
|
47655
|
-
* EnvironmentUtils.isWindows();
|
|
47656
|
-
* @returns {Boolean} - Whether the environment is Windows.
|
|
47657
|
-
*/
|
|
47658
|
-
isWindows: function isWindows() {
|
|
47659
|
-
return /win/i.test(appVersion);
|
|
47660
|
-
},
|
|
47661
|
-
/**
|
|
47662
|
-
* Determines whether the code is being executed on a tablet.
|
|
47663
|
-
* @static
|
|
47664
|
-
* @function isTablet
|
|
47665
|
-
* @param {String} [ua=navigator.userAgent] - The user agent to test against.
|
|
47666
|
-
* @example
|
|
47667
|
-
* EnvironmentUtils.isTablet();
|
|
47668
|
-
* @returns {Boolean} - Whether the environment is a tablet.
|
|
47669
|
-
*/
|
|
47670
|
-
isTablet: function isTablet() {
|
|
47671
|
-
var ua = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : userAgent;
|
|
47672
|
-
return this.isiPad(null, ua) || this.isAndroidTablet(ua) || this.isWindowsTablet(ua);
|
|
47673
|
-
},
|
|
47674
|
-
/**
|
|
47675
|
-
* Determines whether the code is being executed on a mobile device.
|
|
47676
|
-
* @static
|
|
47677
|
-
* @function isMobileDevice
|
|
47678
|
-
* @param {String} [ua=navigator.userAgent] - The user agent to test against.
|
|
47679
|
-
* @example
|
|
47680
|
-
* EnvironmentUtils.isMobileDevice();
|
|
47681
|
-
* @returns {Boolean} - Whether the environment is a mobile device.
|
|
47682
|
-
*/
|
|
47683
|
-
isMobileDevice: function isMobileDevice() {
|
|
47684
|
-
var ua = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : userAgent;
|
|
47685
|
-
return this.isiPhone(null, ua) || this.isiPod(null, ua) || this.isAndroidPhone(ua) || this.isBlackberry(ua) || this.isWindowsPhone(ua);
|
|
47686
|
-
},
|
|
47687
|
-
/**
|
|
47688
|
-
* Determines whether the code is being executed on a touch device.
|
|
47689
|
-
* @static
|
|
47690
|
-
* @function isTouchDevice
|
|
47691
|
-
* @example
|
|
47692
|
-
* EnvironmentUtils.isTouchDevice();
|
|
47693
|
-
* @returns {Boolean} - Whether the environment is a touch device.
|
|
47694
|
-
*/
|
|
47695
|
-
isTouchDevice: function isTouchDevice() {
|
|
47696
|
-
return Boolean(_ssrWindow.document) && ('ontouchstart' in _ssrWindow.document.documentElement || 'DocumentTouch' in _ssrWindow.document.documentElement && _ssrWindow.document instanceof window.DocumentTouch);
|
|
47697
|
-
},
|
|
47698
|
-
/**
|
|
47699
|
-
* Determines whether the display has a high density.
|
|
47700
|
-
* @static
|
|
47701
|
-
* @function isHighDensityDisplay
|
|
47702
|
-
* @example
|
|
47703
|
-
* EnvironmentUtils.isHighDensityDisplay();
|
|
47704
|
-
* @returns {Boolean} - Whether the display is high density.
|
|
47705
|
-
*/
|
|
47706
|
-
isHighDensityDisplay: function isHighDensityDisplay() {
|
|
47707
|
-
return _ssrWindow.window.matchMedia && (_ssrWindow.window.matchMedia('only screen and (min-resolution: 124dpi), only screen and (min-resolution: 1.3dppx), only screen and (min-resolution: 48.8dpcm)').matches || _ssrWindow.window.matchMedia('only screen and (-webkit-min-device-pixel-ratio: 1.3), only screen and (-o-min-device-pixel-ratio: 2.6/2), only screen and (min--moz-device-pixel-ratio: 1.3), only screen and (min-device-pixel-ratio: 1.3)').matches) || _ssrWindow.window.devicePixelRatio && _ssrWindow.window.devicePixelRatio > 1.3;
|
|
47708
|
-
},
|
|
47709
|
-
/**
|
|
47710
|
-
* Returns a string based on browser util booleans, consumed by Segment and Optimizely
|
|
47711
|
-
* @static
|
|
47712
|
-
* @function getBrowserCategory
|
|
47713
|
-
* @returns {String} - The browser string
|
|
47714
|
-
*/
|
|
47715
|
-
getBrowserCategory: function getBrowserCategory() {
|
|
47716
|
-
if (this.isChrome()) {
|
|
47717
|
-
return 'Chrome';
|
|
47718
|
-
} else if (this.isFirefox()) {
|
|
47719
|
-
return 'Firefox';
|
|
47720
|
-
} else if (this.isSafari()) {
|
|
47721
|
-
return 'Safari';
|
|
47722
|
-
} else if (this.isEdge() || this.isIE()) {
|
|
47723
|
-
return 'IE/Edge';
|
|
47724
|
-
}
|
|
47725
|
-
return 'Other';
|
|
47726
|
-
}
|
|
47727
|
-
};
|
|
47728
|
-
environment$1["default"] = EnvironmentUtils;
|
|
47729
|
-
return environment$1;
|
|
47730
|
-
}
|
|
47731
|
-
|
|
47732
|
-
var environment;
|
|
47733
|
-
var hasRequiredEnvironment;
|
|
47734
|
-
function requireEnvironment() {
|
|
47735
|
-
if (hasRequiredEnvironment) return environment;
|
|
47736
|
-
hasRequiredEnvironment = 1;
|
|
47737
|
-
environment = requireEnvironment$1();
|
|
47738
|
-
return environment;
|
|
47186
|
+
return window.matchMedia && (window.matchMedia('only screen and (min-resolution: 124dpi), only screen and (min-resolution: 1.3dppx), only screen and (min-resolution: 48.8dpcm)').matches || window.matchMedia('only screen and (-webkit-min-device-pixel-ratio: 1.3), only screen and (-o-min-device-pixel-ratio: 2.6/2), only screen and (min--moz-device-pixel-ratio: 1.3), only screen and (min-device-pixel-ratio: 1.3)').matches) || window.devicePixelRatio && window.devicePixelRatio > 1.3;
|
|
47739
47187
|
}
|
|
47740
|
-
|
|
47741
|
-
var environmentExports = requireEnvironment();
|
|
47742
|
-
var EnvironmentUtils = /*@__PURE__*/getDefaultExportFromCjs(environmentExports);
|
|
47743
|
-
|
|
47744
|
-
var _excluded$l = ["isSSR", "cloudinaryImageId", "cloudinaryTemplate", "cloudinaryCloudName", "htmlWidth", "htmlHeight", "quality", "lazyLoad"];
|
|
47745
47188
|
var buildCloudinarySrc = function buildCloudinarySrc(_ref) {
|
|
47746
47189
|
var cloudinaryImageId = _ref.cloudinaryImageId,
|
|
47747
47190
|
cloudinaryTemplate = _ref.cloudinaryTemplate,
|
|
@@ -47749,7 +47192,7 @@ var buildCloudinarySrc = function buildCloudinarySrc(_ref) {
|
|
|
47749
47192
|
htmlWidth = _ref.htmlWidth,
|
|
47750
47193
|
htmlHeight = _ref.htmlHeight,
|
|
47751
47194
|
quality = _ref.quality;
|
|
47752
|
-
var defaultTemplate = "https://res.cloudinary.com/".concat(cloudinaryCloudName, "/image/upload/$w_{{WIDTH}},$h_{{HEIGHT}},$q_{{QUALITY}}/c_fill,f_auto,fl_progressive,dpr_").concat(
|
|
47195
|
+
var defaultTemplate = "https://res.cloudinary.com/".concat(cloudinaryCloudName, "/image/upload/$w_{{WIDTH}},$h_{{HEIGHT}},$q_{{QUALITY}}/c_fill,f_auto,fl_progressive,dpr_").concat(isHighDensityDisplay() ? 2 : 1, ",h_$h,q_$q,w_$w/").concat(cloudinaryImageId);
|
|
47753
47196
|
var tmpl = cloudinaryTemplate ? cloudinaryTemplate : defaultTemplate;
|
|
47754
47197
|
return template(tmpl, {
|
|
47755
47198
|
interpolate: /{{([\s\S]+?)}}/g // matches template vars in the format '{{ var }}' or '{{var}}'
|