@moda/om 19.4.1 → 19.4.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/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # @moda/om
2
2
 
3
- [![semantic-release](https://img.shields.io/badge/%20%20%F0%9F%93%A6%F0%9F%9A%80-semantic--release-e10079.svg)](https://github.com/semantic-release/semantic-release) [![](https://img.shields.io/npm/v/@moda/om)](https://www.npmjs.com/package/@moda/om) [![](https://img.shields.io/circleci/build/gh/ModaOperandi/om/master)](https://circleci.com/gh/ModaOperandi/om)
3
+ [![semantic-release](https://img.shields.io/badge/%20%20%F0%9F%93%A6%F0%9F%9A%80-semantic--release-e10079.svg)](https://github.com/semantic-release/semantic-release) [![](https://img.shields.io/npm/v/@moda/om)](https://www.npmjs.com/package/@moda/om) [![](https://img.shields.io/circleci/build/gh/ModaOperandi/om/main)](https://circleci.com/gh/ModaOperandi/om)
4
4
 
5
5
  Moda Operandi's design system expressed as React components.
6
6
 
@@ -67,7 +67,7 @@ We are using [semantic release](https://github.com/semantic-release/semantic-rel
67
67
 
68
68
  Once you want to commit something, `git add` it then run the commitizen CLI. If you have it installed globally (`npm install -g commitizen`), you can run `git cz` and it will walk you through the steps.
69
69
 
70
- When you're happy push to a feature branch and once the code is in `master`, semantic release will detect how to version it and automatically publish it to NPM.
70
+ When you're happy push to a feature branch and once the code is in `main`, semantic release will detect how to version it and automatically publish it to NPM.
71
71
 
72
72
  ## Usage
73
73
 
@@ -101,4 +101,3 @@ body {
101
101
  padding: spacing(2, 4);
102
102
  }
103
103
  ```
104
-
package/dist/index.cjs.js CHANGED
@@ -343,6 +343,7 @@ colors.colors = {
343
343
  "teal": "rgb(0, 111, 98)",
344
344
  "ivory": "rgb(242, 233, 219)",
345
345
  "klein-blue": "rgb(38, 48, 120)",
346
+ "persian-blue": "rgb(30, 34, 170)",
346
347
  "brick": "rgb(147, 58, 32)",
347
348
  "goldenrod": "rgb(186, 145, 46)",
348
349
  "seafoam": "rgb(177, 191, 170)",
@@ -368,6 +369,7 @@ colors.colors = {
368
369
  },
369
370
  "global": {
370
371
  "klein-blue": "rgb(38, 48, 120)",
372
+ "persian-blue": "rgb(30, 34, 170)",
371
373
  "brick": "rgb(147, 58, 32)",
372
374
  "goldenrod": "rgb(186, 145, 46)",
373
375
  "seafoam": "rgb(177, 191, 170)",
@@ -1124,12 +1126,11 @@ function _objectDestructuringEmpty(obj) {
1124
1126
  function _objectWithoutPropertiesLoose(source, excluded) {
1125
1127
  if (source == null) return {};
1126
1128
  var target = {};
1127
- var sourceKeys = Object.keys(source);
1128
- var key, i;
1129
- for (i = 0; i < sourceKeys.length; i++) {
1130
- key = sourceKeys[i];
1131
- if (excluded.indexOf(key) >= 0) continue;
1132
- target[key] = source[key];
1129
+ for (var key in source) {
1130
+ if (Object.prototype.hasOwnProperty.call(source, key)) {
1131
+ if (excluded.indexOf(key) >= 0) continue;
1132
+ target[key] = source[key];
1133
+ }
1133
1134
  }
1134
1135
  return target;
1135
1136
  }
@@ -1185,7 +1186,7 @@ function _nonIterableRest() {
1185
1186
  function _createForOfIteratorHelper(o, allowArrayLike) {
1186
1187
  var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"];
1187
1188
  if (!it) {
1188
- if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") {
1189
+ if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike ) {
1189
1190
  if (it) o = it;
1190
1191
  var i = 0;
1191
1192
  var F = function () {};
@@ -1544,6 +1545,7 @@ function useCallbackRef(initialValue, callback) {
1544
1545
  return ref.facade;
1545
1546
  }
1546
1547
 
1548
+ var useIsomorphicLayoutEffect = typeof window !== 'undefined' ? React__namespace.useLayoutEffect : React__namespace.useEffect;
1547
1549
  var currentValues = new WeakMap();
1548
1550
  /**
1549
1551
  * Merges two or more refs together providing a single interface to set their value
@@ -1560,13 +1562,13 @@ var currentValues = new WeakMap();
1560
1562
  * }
1561
1563
  */
1562
1564
  function useMergeRefs(refs, defaultValue) {
1563
- var callbackRef = useCallbackRef(defaultValue || null, function (newValue) {
1565
+ var callbackRef = useCallbackRef(null, function (newValue) {
1564
1566
  return refs.forEach(function (ref) {
1565
1567
  return assignRef(ref, newValue);
1566
1568
  });
1567
1569
  });
1568
1570
  // handle refs changes - added or removed
1569
- React__namespace.useLayoutEffect(function () {
1571
+ useIsomorphicLayoutEffect(function () {
1570
1572
  var oldValue = currentValues.get(callbackRef);
1571
1573
  if (oldValue) {
1572
1574
  var prevRefs_1 = new Set(oldValue);
@@ -3125,7 +3127,6 @@ FocusLock.propTypes = process.env.NODE_ENV !== "production" ? {
3125
3127
  onDeactivation: propTypesExports.func,
3126
3128
  sideCar: propTypesExports.any.isRequired
3127
3129
  } : {};
3128
- var FocusLockUI = FocusLock;
3129
3130
 
3130
3131
  function deferAction(action) {
3131
3132
  setTimeout(action, 1);
@@ -3180,7 +3181,7 @@ var FocusOn$1 = /*#__PURE__*/React__namespace.forwardRef(function (props, parent
3180
3181
  inert: inert,
3181
3182
  enabled: enabled && scrollLock
3182
3183
  });
3183
- return /*#__PURE__*/React__namespace.createElement(React__namespace.Fragment, null, /*#__PURE__*/React__namespace.createElement(FocusLockUI, {
3184
+ return /*#__PURE__*/React__namespace.createElement(React__namespace.Fragment, null, /*#__PURE__*/React__namespace.createElement(FocusLock, {
3184
3185
  ref: parentRef,
3185
3186
  sideCar: sideCar,
3186
3187
  disabled: !(lockProps && enabled && focusLock),
@@ -4067,6 +4068,13 @@ var moveFocusInside = function moveFocusInside(topNode, lastNode, options) {
4067
4068
 
4068
4069
  function weakRef(value) {
4069
4070
  if (!value) return null;
4071
+ // #68 Safari 14.1 dont have it yet
4072
+ // FIXME: remove in 2025
4073
+ if (typeof WeakRef === 'undefined') {
4074
+ return function () {
4075
+ return value || null;
4076
+ };
4077
+ }
4070
4078
  var w = value ? new WeakRef(value) : null;
4071
4079
  return function () {
4072
4080
  return (w === null || w === void 0 ? void 0 : w.deref()) || null;
@@ -4782,9 +4790,9 @@ var handleScroll = function handleScroll(axis, endTarget, event, sourceDelta, no
4782
4790
  // self content
4783
4791
  targetInLock && (endTarget.contains(target) || endTarget === target));
4784
4792
  // handle epsilon around 0 (non standard zoom levels)
4785
- if (isDeltaPositive && (noOverscroll && Math.abs(availableScroll) < 1 || !noOverscroll && delta > availableScroll)) {
4793
+ if (isDeltaPositive && (Math.abs(availableScroll) < 1 || !noOverscroll )) {
4786
4794
  shouldCancelScroll = true;
4787
- } else if (!isDeltaPositive && (noOverscroll && Math.abs(availableScrollTop) < 1 || !noOverscroll && -delta > availableScrollTop)) {
4795
+ } else if (!isDeltaPositive && (Math.abs(availableScrollTop) < 1 || !noOverscroll )) {
4788
4796
  shouldCancelScroll = true;
4789
4797
  }
4790
4798
  return shouldCancelScroll;
@@ -5085,9 +5093,6 @@ var applyAttributeToOthers = function applyAttributeToOthers(originalTarget, par
5085
5093
  * @return {Undo} undo command
5086
5094
  */
5087
5095
  var hideOthers = function hideOthers(originalTarget, parentNode, markerName) {
5088
- if (markerName === void 0) {
5089
- markerName = 'data-aria-hidden';
5090
- }
5091
5096
  var targets = Array.from(Array.isArray(originalTarget) ? originalTarget : [originalTarget]);
5092
5097
  var activeParentNode = parentNode || getDefaultParent(originalTarget);
5093
5098
  if (!activeParentNode) {
@@ -5514,10 +5519,13 @@ var Breadcrumb = function Breadcrumb(_ref) {
5514
5519
  var T = function T() {
5515
5520
  return true;
5516
5521
  };
5517
- var otherwise = T;
5522
+
5523
+ var _placeholder = {
5524
+ '@@functional/placeholder': true
5525
+ };
5518
5526
 
5519
5527
  function _isPlaceholder(a) {
5520
- return a != null && _typeof$1(a) === 'object' && a['@@functional/placeholder'] === true;
5528
+ return a === _placeholder;
5521
5529
  }
5522
5530
 
5523
5531
  /**
@@ -5528,7 +5536,6 @@ function _isPlaceholder(a) {
5528
5536
  * @param {Function} fn The function to curry.
5529
5537
  * @return {Function} The curried function.
5530
5538
  */
5531
-
5532
5539
  function _curry1(fn) {
5533
5540
  return function f1(a) {
5534
5541
  if (arguments.length === 0 || _isPlaceholder(a)) {
@@ -5547,7 +5554,6 @@ function _curry1(fn) {
5547
5554
  * @param {Function} fn The function to curry.
5548
5555
  * @return {Function} The curried function.
5549
5556
  */
5550
-
5551
5557
  function _curry2(fn) {
5552
5558
  return function f2(a, b) {
5553
5559
  switch (arguments.length) {
@@ -5629,7 +5635,6 @@ function _arity(n, fn) {
5629
5635
  * @param {Function} fn The function to curry.
5630
5636
  * @return {Function} The curried function.
5631
5637
  */
5632
-
5633
5638
  function _curryN(length, received, fn) {
5634
5639
  return function () {
5635
5640
  var combined = [];
@@ -5699,9 +5704,7 @@ function _curryN(length, received, fn) {
5699
5704
  * const g = f(3);
5700
5705
  * g(4); //=> 10
5701
5706
  */
5702
-
5703
- var curryN = /*#__PURE__*/
5704
- _curry2(function curryN(length, fn) {
5707
+ var curryN = /*#__PURE__*/_curry2(function curryN(length, fn) {
5705
5708
  if (length === 1) {
5706
5709
  return _curry1(fn);
5707
5710
  }
@@ -5716,7 +5719,6 @@ _curry2(function curryN(length, fn) {
5716
5719
  * @param {Function} fn The function to curry.
5717
5720
  * @return {Function} The curried function.
5718
5721
  */
5719
-
5720
5722
  function _curry3(fn) {
5721
5723
  return function f3(a, b, c) {
5722
5724
  switch (arguments.length) {
@@ -5787,7 +5789,6 @@ function _isTransformer(obj) {
5787
5789
  * @param {Function} fn default ramda implementation
5788
5790
  * @return {Function} A function that dispatches on object in list position
5789
5791
  */
5790
-
5791
5792
  function _dispatchable(methodNames, transducerCreator, fn) {
5792
5793
  return function () {
5793
5794
  if (arguments.length === 0) {
@@ -5866,8 +5867,7 @@ function _objectIs(a, b) {
5866
5867
  var _objectIs$1 = typeof Object.is === 'function' ? Object.is : _objectIs;
5867
5868
 
5868
5869
  var toString$1 = Object.prototype.toString;
5869
- var _isArguments = /*#__PURE__*/
5870
- function () {
5870
+ var _isArguments = /*#__PURE__*/function () {
5871
5871
  return toString$1.call(arguments) === '[object Arguments]' ? function _isArguments(x) {
5872
5872
  return toString$1.call(x) === '[object Arguments]';
5873
5873
  } : function _isArguments(x) {
@@ -5875,14 +5875,13 @@ function () {
5875
5875
  };
5876
5876
  }();
5877
5877
 
5878
- var hasEnumBug = ! /*#__PURE__*/
5879
- {
5878
+ // cover IE < 9 keys issues
5879
+ var hasEnumBug = ! /*#__PURE__*/{
5880
5880
  toString: null
5881
5881
  }.propertyIsEnumerable('toString');
5882
- var nonEnumerableProps = ['constructor', 'valueOf', 'isPrototypeOf', 'toString', 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString']; // Safari bug
5883
-
5884
- var hasArgsEnumBug = /*#__PURE__*/
5885
- function () {
5882
+ var nonEnumerableProps = ['constructor', 'valueOf', 'isPrototypeOf', 'toString', 'propertyIsEnumerable', 'hasOwnProperty', 'toLocaleString'];
5883
+ // Safari bug
5884
+ var hasArgsEnumBug = /*#__PURE__*/function () {
5886
5885
 
5887
5886
  return arguments.propertyIsEnumerable('length');
5888
5887
  }();
@@ -5896,6 +5895,7 @@ var contains = function contains(list, item) {
5896
5895
  }
5897
5896
  return false;
5898
5897
  };
5898
+
5899
5899
  /**
5900
5900
  * Returns a list containing the names of all the enumerable own properties of
5901
5901
  * the supplied object.
@@ -5914,12 +5914,9 @@ var contains = function contains(list, item) {
5914
5914
  *
5915
5915
  * R.keys({a: 1, b: 2, c: 3}); //=> ['a', 'b', 'c']
5916
5916
  */
5917
-
5918
- var keys = typeof Object.keys === 'function' && !hasArgsEnumBug ? /*#__PURE__*/
5919
- _curry1(function keys(obj) {
5917
+ var keys = typeof Object.keys === 'function' && !hasArgsEnumBug ? /*#__PURE__*/_curry1(function keys(obj) {
5920
5918
  return Object(obj) !== obj ? [] : Object.keys(obj);
5921
- }) : /*#__PURE__*/
5922
- _curry1(function keys(obj) {
5919
+ }) : /*#__PURE__*/_curry1(function keys(obj) {
5923
5920
  if (Object(obj) !== obj) {
5924
5921
  return [];
5925
5922
  }
@@ -5969,10 +5966,9 @@ _curry1(function keys(obj) {
5969
5966
  * R.type(() => {}); //=> "Function"
5970
5967
  * R.type(async () => {}); //=> "AsyncFunction"
5971
5968
  * R.type(undefined); //=> "Undefined"
5969
+ * R.type(BigInt(123)); //=> "BigInt"
5972
5970
  */
5973
-
5974
- var type = /*#__PURE__*/
5975
- _curry1(function type(val) {
5971
+ var type = /*#__PURE__*/_curry1(function type(val) {
5976
5972
  return val === null ? 'Null' : val === undefined ? 'Undefined' : Object.prototype.toString.call(val).slice(8, -1);
5977
5973
  });
5978
5974
 
@@ -5992,8 +5988,9 @@ function _uniqContentEquals(aIterator, bIterator, stackA, stackB) {
5992
5988
  var b = _arrayFromIterator(bIterator);
5993
5989
  function eq(_a, _b) {
5994
5990
  return _equals(_a, _b, stackA.slice(), stackB.slice());
5995
- } // if *a* array contains any element that is not included in *b*
5991
+ }
5996
5992
 
5993
+ // if *a* array contains any element that is not included in *b*
5997
5994
  return !_includesWith(function (b, aItem) {
5998
5995
  return !_includesWith(eq, aItem, b);
5999
5996
  }, b, a);
@@ -6124,15 +6121,13 @@ function _equals(a, b, stackA, stackB) {
6124
6121
  * const b = {}; b.v = b;
6125
6122
  * R.equals(a, b); //=> true
6126
6123
  */
6127
-
6128
- var equals = /*#__PURE__*/
6129
- _curry2(function equals(a, b) {
6124
+ var equals = /*#__PURE__*/_curry2(function equals(a, b) {
6130
6125
  return _equals(a, b, [], []);
6131
6126
  });
6132
6127
 
6133
6128
  function _indexOf(list, a, idx) {
6134
- var inf, item; // Array.prototype.indexOf doesn't exist below IE9
6135
-
6129
+ var inf, item;
6130
+ // Array.prototype.indexOf doesn't exist below IE9
6136
6131
  if (typeof list.indexOf === 'function') {
6137
6132
  switch (_typeof$1(a)) {
6138
6133
  case 'number':
@@ -6157,11 +6152,11 @@ function _indexOf(list, a, idx) {
6157
6152
  idx += 1;
6158
6153
  }
6159
6154
  return -1;
6160
- } // non-zero numbers can utilise Set
6161
-
6155
+ }
6156
+ // non-zero numbers can utilise Set
6162
6157
  return list.indexOf(a, idx);
6163
- // all these types can utilise Set
6164
6158
 
6159
+ // all these types can utilise Set
6165
6160
  case 'string':
6166
6161
  case 'boolean':
6167
6162
  case 'function':
@@ -6173,8 +6168,8 @@ function _indexOf(list, a, idx) {
6173
6168
  return list.indexOf(a, idx);
6174
6169
  }
6175
6170
  }
6176
- } // anything else not covered above, defer to R.equals
6177
-
6171
+ }
6172
+ // anything else not covered above, defer to R.equals
6178
6173
  while (idx < list.length) {
6179
6174
  if (equals(list[idx], a)) {
6180
6175
  return idx;
@@ -6250,8 +6245,7 @@ function _isObject(x) {
6250
6245
  return Object.prototype.toString.call(x) === '[object Object]';
6251
6246
  }
6252
6247
 
6253
- var XFilter = /*#__PURE__*/
6254
- function () {
6248
+ var XFilter = /*#__PURE__*/function () {
6255
6249
  function XFilter(f, xf) {
6256
6250
  this.xf = xf;
6257
6251
  this.f = f;
@@ -6297,10 +6291,7 @@ function _xfilter(f) {
6297
6291
  *
6298
6292
  * R.filter(isEven, {a: 1, b: 2, c: 3, d: 4}); //=> {b: 2, d: 4}
6299
6293
  */
6300
-
6301
- var filter = /*#__PURE__*/
6302
- _curry2( /*#__PURE__*/
6303
- _dispatchable(['fantasy-land/filter', 'filter'], _xfilter, function (pred, filterable) {
6294
+ var filter = /*#__PURE__*/_curry2( /*#__PURE__*/_dispatchable(['fantasy-land/filter', 'filter'], _xfilter, function (pred, filterable) {
6304
6295
  return _isObject(filterable) ? _arrayReduce(function (acc, key) {
6305
6296
  if (pred(filterable[key])) {
6306
6297
  acc[key] = filterable[key];
@@ -6335,19 +6326,17 @@ _dispatchable(['fantasy-land/filter', 'filter'], _xfilter, function (pred, filte
6335
6326
  *
6336
6327
  * R.reject(isOdd, {a: 1, b: 2, c: 3, d: 4}); //=> {b: 2, d: 4}
6337
6328
  */
6338
-
6339
- var reject = /*#__PURE__*/
6340
- _curry2(function reject(pred, filterable) {
6329
+ var reject = /*#__PURE__*/_curry2(function reject(pred, filterable) {
6341
6330
  return filter(_complement(pred), filterable);
6342
6331
  });
6343
- var reject$1 = reject;
6344
6332
 
6345
6333
  function _toString(x, seen) {
6346
6334
  var recur = function recur(y) {
6347
6335
  var xs = seen.concat([x]);
6348
6336
  return _includes(y, xs) ? '<Circular>' : _toString(y, xs);
6349
- }; // mapPairs :: (Object, [String]) -> [String]
6337
+ };
6350
6338
 
6339
+ // mapPairs :: (Object, [String]) -> [String]
6351
6340
  var mapPairs = function mapPairs(obj, keys) {
6352
6341
  return _map(function (k) {
6353
6342
  return _quote(k) + ': ' + recur(obj[k]);
@@ -6357,7 +6346,7 @@ function _toString(x, seen) {
6357
6346
  case '[object Arguments]':
6358
6347
  return '(function() { return arguments; }(' + _map(recur, x).join(', ') + '))';
6359
6348
  case '[object Array]':
6360
- return '[' + _map(recur, x).concat(mapPairs(x, reject$1(function (k) {
6349
+ return '[' + _map(recur, x).concat(mapPairs(x, reject(function (k) {
6361
6350
  return /^\d+$/.test(k);
6362
6351
  }, keys(x)))).join(', ') + ']';
6363
6352
  case '[object Boolean]':
@@ -6423,9 +6412,7 @@ function _toString(x, seen) {
6423
6412
  * R.toString({foo: 1, bar: 2, baz: 3}); //=> '{"bar": 2, "baz": 3, "foo": 1}'
6424
6413
  * R.toString(new Date('2001-02-03T04:05:06Z')); //=> 'new Date("2001-02-03T04:05:06.000Z")'
6425
6414
  */
6426
-
6427
- var toString = /*#__PURE__*/
6428
- _curry1(function toString(val) {
6415
+ var toString = /*#__PURE__*/_curry1(function toString(val) {
6429
6416
  return _toString(val, []);
6430
6417
  });
6431
6418
 
@@ -6446,9 +6433,7 @@ _curry1(function toString(val) {
6446
6433
  * R.max(789, 123); //=> 789
6447
6434
  * R.max('a', 'b'); //=> 'b'
6448
6435
  */
6449
-
6450
- var max = /*#__PURE__*/
6451
- _curry2(function max(a, b) {
6436
+ var max = /*#__PURE__*/_curry2(function max(a, b) {
6452
6437
  if (a === b) {
6453
6438
  return b;
6454
6439
  }
@@ -6473,10 +6458,8 @@ _curry2(function max(a, b) {
6473
6458
  }
6474
6459
  return b;
6475
6460
  });
6476
- var max$1 = max;
6477
6461
 
6478
- var XMap = /*#__PURE__*/
6479
- function () {
6462
+ var XMap = /*#__PURE__*/function () {
6480
6463
  function XMap(f, xf) {
6481
6464
  this.xf = xf;
6482
6465
  this.f = f;
@@ -6493,7 +6476,6 @@ var _xmap = function _xmap(f) {
6493
6476
  return new XMap(f, xf);
6494
6477
  };
6495
6478
  };
6496
- var _xmap$1 = _xmap;
6497
6479
 
6498
6480
  /**
6499
6481
  * Takes a function and
@@ -6530,10 +6512,7 @@ var _xmap$1 = _xmap;
6530
6512
  * @symb R.map(f, { x: a, y: b }) = { x: f(a), y: f(b) }
6531
6513
  * @symb R.map(f, functor_o) = functor_o.map(f)
6532
6514
  */
6533
-
6534
- var map = /*#__PURE__*/
6535
- _curry2( /*#__PURE__*/
6536
- _dispatchable(['fantasy-land/map', 'map'], _xmap$1, function map(fn, functor) {
6515
+ var map = /*#__PURE__*/_curry2( /*#__PURE__*/_dispatchable(['fantasy-land/map', 'map'], _xmap, function map(fn, functor) {
6537
6516
  switch (Object.prototype.toString.call(functor)) {
6538
6517
  case '[object Function]':
6539
6518
  return curryN(functor.length, function () {
@@ -6571,9 +6550,7 @@ function _isString(x) {
6571
6550
  * _isArrayLike({0: 'zero', 9: 'nine', length: 10}); //=> true
6572
6551
  * _isArrayLike({nodeType: 1, length: 1}) // => false
6573
6552
  */
6574
-
6575
- var _isArrayLike = /*#__PURE__*/
6576
- _curry1(function isArrayLike(x) {
6553
+ var _isArrayLike = /*#__PURE__*/_curry1(function isArrayLike(x) {
6577
6554
  if (_isArray(x)) {
6578
6555
  return true;
6579
6556
  }
@@ -6656,9 +6633,7 @@ function _xArrayReduce(xf, acc, list) {
6656
6633
  * // logs {a: 2}
6657
6634
  * @symb R.bind(f, o)(a, b) = f.call(o, a, b)
6658
6635
  */
6659
-
6660
- var bind = /*#__PURE__*/
6661
- _curry2(function bind(fn, thisObj) {
6636
+ var bind = /*#__PURE__*/_curry2(function bind(fn, thisObj) {
6662
6637
  return _arity(fn.length, function () {
6663
6638
  return fn.apply(thisObj, arguments);
6664
6639
  });
@@ -6679,11 +6654,9 @@ function _xIterableReduce(xf, acc, iter) {
6679
6654
  function _xMethodReduce(xf, acc, obj, methodName) {
6680
6655
  return xf['@@transducer/result'](obj[methodName](bind(xf['@@transducer/step'], xf), acc));
6681
6656
  }
6682
- var _xReduce = /*#__PURE__*/
6683
- _createReduce(_xArrayReduce, _xMethodReduce, _xIterableReduce);
6657
+ var _xReduce = /*#__PURE__*/_createReduce(_xArrayReduce, _xMethodReduce, _xIterableReduce);
6684
6658
 
6685
- var XWrap = /*#__PURE__*/
6686
- function () {
6659
+ var XWrap = /*#__PURE__*/function () {
6687
6660
  function XWrap(fn) {
6688
6661
  this.f = fn;
6689
6662
  }
@@ -6754,12 +6727,9 @@ function _xwrap(fn) {
6754
6727
  *
6755
6728
  * @symb R.reduce(f, a, [b, c, d]) = f(f(f(a, b), c), d)
6756
6729
  */
6757
-
6758
- var reduce = /*#__PURE__*/
6759
- _curry3(function (xf, acc, list) {
6730
+ var reduce = /*#__PURE__*/_curry3(function (xf, acc, list) {
6760
6731
  return _xReduce(typeof xf === 'function' ? _xwrap(xf) : xf, acc, list);
6761
6732
  });
6762
- var reduce$1 = reduce;
6763
6733
 
6764
6734
  function _identity(x) {
6765
6735
  return x;
@@ -6784,10 +6754,7 @@ function _identity(x) {
6784
6754
  * R.identity(obj) === obj; //=> true
6785
6755
  * @symb R.identity(a) = a
6786
6756
  */
6787
-
6788
- var identity = /*#__PURE__*/
6789
- _curry1(_identity);
6790
- var identity$1 = identity;
6757
+ var identity = /*#__PURE__*/_curry1(_identity);
6791
6758
 
6792
6759
  /**
6793
6760
  * Returns a function, `fn`, which encapsulates `if/else, if/else, ...` logic.
@@ -6820,10 +6787,8 @@ var identity$1 = identity;
6820
6787
  * fn(50); //=> 'nothing special happens at 50°C'
6821
6788
  * fn(100); //=> 'water boils at 100°C'
6822
6789
  */
6823
-
6824
- var cond = /*#__PURE__*/
6825
- _curry1(function cond(pairs) {
6826
- var arity = reduce$1(max$1, 0, map(function (pair) {
6790
+ var cond = /*#__PURE__*/_curry1(function cond(pairs) {
6791
+ var arity = reduce(max, 0, map(function (pair) {
6827
6792
  return pair[0].length;
6828
6793
  }, pairs));
6829
6794
  return _arity(arity, function () {
@@ -6837,28 +6802,29 @@ _curry1(function cond(pairs) {
6837
6802
  });
6838
6803
  });
6839
6804
 
6840
- var _Set = /*#__PURE__*/
6841
- function () {
6805
+ var _Set = /*#__PURE__*/function () {
6842
6806
  function _Set() {
6843
6807
  /* globals Set */
6844
6808
  this._nativeSet = typeof Set === 'function' ? new Set() : null;
6845
6809
  this._items = {};
6846
6810
  }
6847
-
6848
6811
  // until we figure out why jsdoc chokes on this
6849
6812
  // @param item The item to add to the Set
6850
6813
  // @returns {boolean} true if the item did not exist prior, otherwise false
6851
6814
  //
6852
6815
  _Set.prototype.add = function (item) {
6853
6816
  return !hasOrAdd(item, true, this);
6854
- }; //
6817
+ };
6818
+
6819
+ //
6855
6820
  // @param item The item to check for existence in the Set
6856
6821
  // @returns {boolean} true if the item exists in the Set, otherwise false
6857
6822
  //
6858
-
6859
6823
  _Set.prototype.has = function (item) {
6860
6824
  return hasOrAdd(item, false, this);
6861
- }; //
6825
+ };
6826
+
6827
+ //
6862
6828
  // Combines the logic for checking whether an item is a member of the set and
6863
6829
  // for adding a new item to the set.
6864
6830
  //
@@ -6868,7 +6834,6 @@ function () {
6868
6834
  // @param set The set instance to check or add to.
6869
6835
  // @return {boolean} true if the item already existed, otherwise false.
6870
6836
  //
6871
-
6872
6837
  return _Set;
6873
6838
  }();
6874
6839
  function hasOrAdd(item, shouldAdd, set) {
@@ -6887,8 +6852,8 @@ function hasOrAdd(item, shouldAdd, set) {
6887
6852
  }
6888
6853
  return false;
6889
6854
  }
6890
- } // these types can all utilise the native Set
6891
-
6855
+ }
6856
+ // these types can all utilise the native Set
6892
6857
  if (set._nativeSet !== null) {
6893
6858
  if (shouldAdd) {
6894
6859
  prevSize = set._nativeSet.size;
@@ -6978,9 +6943,7 @@ function hasOrAdd(item, shouldAdd, set) {
6978
6943
  }
6979
6944
  return true;
6980
6945
  }
6981
-
6982
6946
  /* falls through */
6983
-
6984
6947
  default:
6985
6948
  // reduce the search size of heterogeneous sets by creating buckets
6986
6949
  // for each type.
@@ -6990,8 +6953,8 @@ function hasOrAdd(item, shouldAdd, set) {
6990
6953
  set._items[type] = [item];
6991
6954
  }
6992
6955
  return false;
6993
- } // scan through all previously applied items
6994
-
6956
+ }
6957
+ // scan through all previously applied items
6995
6958
  if (!_includes(item, set._items[type])) {
6996
6959
  if (shouldAdd) {
6997
6960
  set._items[type].push(item);
@@ -7000,10 +6963,9 @@ function hasOrAdd(item, shouldAdd, set) {
7000
6963
  }
7001
6964
  return true;
7002
6965
  }
7003
- } // A simple Set type that honours R.equals semantics
6966
+ }
7004
6967
 
7005
- var XUniqBy = /*#__PURE__*/
7006
- function () {
6968
+ var XUniqBy = /*#__PURE__*/function () {
7007
6969
  function XUniqBy(f, xf) {
7008
6970
  this.xf = xf;
7009
6971
  this.f = f;
@@ -7042,10 +7004,7 @@ function _xuniqBy(f) {
7042
7004
  *
7043
7005
  * R.uniqBy(Math.abs, [-1, -5, 2, 10, 1, 2]); //=> [-1, -5, 2, 10]
7044
7006
  */
7045
-
7046
- var uniqBy = /*#__PURE__*/
7047
- _curry2( /*#__PURE__*/
7048
- _dispatchable([], _xuniqBy, function (fn, list) {
7007
+ var uniqBy = /*#__PURE__*/_curry2( /*#__PURE__*/_dispatchable([], _xuniqBy, function (fn, list) {
7049
7008
  var set = new _Set();
7050
7009
  var result = [];
7051
7010
  var idx = 0;
@@ -7078,9 +7037,7 @@ _dispatchable([], _xuniqBy, function (fn, list) {
7078
7037
  * R.uniq([1, '1']); //=> [1, '1']
7079
7038
  * R.uniq([[42], [42]]); //=> [[42]]
7080
7039
  */
7081
-
7082
- var uniq = /*#__PURE__*/
7083
- uniqBy(identity$1);
7040
+ var uniq = /*#__PURE__*/uniqBy(identity);
7084
7041
 
7085
7042
  function _isNumber(x) {
7086
7043
  return Object.prototype.toString.call(x) === '[object Number]';
@@ -7102,9 +7059,7 @@ function _isNumber(x) {
7102
7059
  *
7103
7060
  * R.omit(['a', 'd'], {a: 1, b: 2, c: 3, d: 4}); //=> {b: 2, c: 3}
7104
7061
  */
7105
-
7106
- var omit = /*#__PURE__*/
7107
- _curry2(function omit(names, obj) {
7062
+ var omit = /*#__PURE__*/_curry2(function omit(names, obj) {
7108
7063
  var result = {};
7109
7064
  var index = {};
7110
7065
  var idx = 0;
@@ -7137,17 +7092,16 @@ _curry2(function omit(names, obj) {
7137
7092
  * R.range(1, 5); //=> [1, 2, 3, 4]
7138
7093
  * R.range(50, 53); //=> [50, 51, 52]
7139
7094
  */
7140
-
7141
- var range = /*#__PURE__*/
7142
- _curry2(function range(from, to) {
7095
+ var range = /*#__PURE__*/_curry2(function range(from, to) {
7143
7096
  if (!(_isNumber(from) && _isNumber(to))) {
7144
7097
  throw new TypeError('Both arguments to range must be numbers');
7145
7098
  }
7146
- var result = [];
7147
- var n = from;
7148
- while (n < to) {
7149
- result.push(n);
7150
- n += 1;
7099
+ var result = Array(from < to ? to - from : 0);
7100
+ var finish = from < 0 ? to + Math.abs(from) : to - from;
7101
+ var idx = 0;
7102
+ while (idx < finish) {
7103
+ result[idx] = idx + from;
7104
+ idx += 1;
7151
7105
  }
7152
7106
  return result;
7153
7107
  });
@@ -11646,7 +11600,7 @@ var showAGroupOfPagesCenteredOnTheCurrentPage = function showAGroupOfPagesCenter
11646
11600
  var diff = Math.floor((maxPages - 2) / 2);
11647
11601
  return [1].concat(_toConsumableArray(range(page - diff, page + diff + 1)), [totalPages]);
11648
11602
  };
11649
- var determinePagesToShow = cond([[whenThereAreFewerPagesThanWeDisplay, showAllPages], [whenCurrentPageIsLessThanHalfTheTotal, showFirstNPagesAndLastPage], [whenCurrentPageIsGreaterThanHalfTheTotal, showTheLastNPages], [otherwise, showAGroupOfPagesCenteredOnTheCurrentPage]]);
11603
+ var determinePagesToShow = cond([[whenThereAreFewerPagesThanWeDisplay, showAllPages], [whenCurrentPageIsLessThanHalfTheTotal, showFirstNPagesAndLastPage], [whenCurrentPageIsGreaterThanHalfTheTotal, showTheLastNPages], [T, showAGroupOfPagesCenteredOnTheCurrentPage]]);
11650
11604
  var Paginator = function Paginator(_ref) {
11651
11605
  var selectedPage = _ref.selectedPage,
11652
11606
  totalPages = _ref.totalPages,