@bolttech/atoms-checkbox 0.17.0 → 0.18.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/index.cjs +56 -61
  2. package/package.json +5 -5
package/index.cjs CHANGED
@@ -20,15 +20,16 @@ var check = function (it) {
20
20
  };
21
21
 
22
22
  // https://github.com/zloirock/core-js/issues/86#issuecomment-115759028
23
- var global$b =
23
+ var global$a =
24
24
  // eslint-disable-next-line es/no-global-this -- safe
25
25
  check(typeof globalThis == 'object' && globalThis) ||
26
26
  check(typeof window == 'object' && window) ||
27
27
  // eslint-disable-next-line no-restricted-globals -- safe
28
28
  check(typeof self == 'object' && self) ||
29
29
  check(typeof commonjsGlobal == 'object' && commonjsGlobal) ||
30
+ check(typeof commonjsGlobal == 'object' && commonjsGlobal) ||
30
31
  // eslint-disable-next-line no-new-func -- fallback
31
- (function () { return this; })() || commonjsGlobal || Function('return this')();
32
+ (function () { return this; })() || Function('return this')();
32
33
 
33
34
  var objectGetOwnPropertyDescriptor = {};
34
35
 
@@ -152,41 +153,25 @@ var toIndexedObject$3 = function (it) {
152
153
  return IndexedObject$1(requireObjectCoercible$1(it));
153
154
  };
154
155
 
155
- var documentAll$2 = typeof document == 'object' && document.all;
156
-
157
156
  // https://tc39.es/ecma262/#sec-IsHTMLDDA-internal-slot
158
- // eslint-disable-next-line unicorn/no-typeof-undefined -- required for testing
159
- var IS_HTMLDDA = typeof documentAll$2 == 'undefined' && documentAll$2 !== undefined;
160
-
161
- var documentAll_1 = {
162
- all: documentAll$2,
163
- IS_HTMLDDA: IS_HTMLDDA
164
- };
165
-
166
- var $documentAll$1 = documentAll_1;
167
-
168
- var documentAll$1 = $documentAll$1.all;
157
+ var documentAll = typeof document == 'object' && document.all;
169
158
 
170
159
  // `IsCallable` abstract operation
171
160
  // https://tc39.es/ecma262/#sec-iscallable
172
- var isCallable$a = $documentAll$1.IS_HTMLDDA ? function (argument) {
173
- return typeof argument == 'function' || argument === documentAll$1;
161
+ // eslint-disable-next-line unicorn/no-typeof-undefined -- required for testing
162
+ var isCallable$a = typeof documentAll == 'undefined' && documentAll !== undefined ? function (argument) {
163
+ return typeof argument == 'function' || argument === documentAll;
174
164
  } : function (argument) {
175
165
  return typeof argument == 'function';
176
166
  };
177
167
 
178
168
  var isCallable$9 = isCallable$a;
179
- var $documentAll = documentAll_1;
180
169
 
181
- var documentAll = $documentAll.all;
182
-
183
- var isObject$5 = $documentAll.IS_HTMLDDA ? function (it) {
184
- return typeof it == 'object' ? it !== null : isCallable$9(it) || it === documentAll;
185
- } : function (it) {
170
+ var isObject$5 = function (it) {
186
171
  return typeof it == 'object' ? it !== null : isCallable$9(it);
187
172
  };
188
173
 
189
- var global$a = global$b;
174
+ var global$9 = global$a;
190
175
  var isCallable$8 = isCallable$a;
191
176
 
192
177
  var aFunction = function (argument) {
@@ -194,7 +179,7 @@ var aFunction = function (argument) {
194
179
  };
195
180
 
196
181
  var getBuiltIn$2 = function (namespace, method) {
197
- return arguments.length < 2 ? aFunction(global$a[namespace]) : global$a[namespace] && global$a[namespace][method];
182
+ return arguments.length < 2 ? aFunction(global$9[namespace]) : global$9[namespace] && global$9[namespace][method];
198
183
  };
199
184
 
200
185
  var uncurryThis$7 = functionUncurryThis;
@@ -203,11 +188,11 @@ var objectIsPrototypeOf = uncurryThis$7({}.isPrototypeOf);
203
188
 
204
189
  var engineUserAgent = typeof navigator != 'undefined' && String(navigator.userAgent) || '';
205
190
 
206
- var global$9 = global$b;
191
+ var global$8 = global$a;
207
192
  var userAgent = engineUserAgent;
208
193
 
209
- var process = global$9.process;
210
- var Deno = global$9.Deno;
194
+ var process = global$8.process;
195
+ var Deno = global$8.Deno;
211
196
  var versions = process && process.versions || Deno && Deno.version;
212
197
  var v8 = versions && versions.v8;
213
198
  var match, version;
@@ -234,9 +219,9 @@ var engineV8Version = version;
234
219
  /* eslint-disable es/no-symbol -- required for testing */
235
220
  var V8_VERSION = engineV8Version;
236
221
  var fails$5 = fails$9;
237
- var global$8 = global$b;
222
+ var global$7 = global$a;
238
223
 
239
- var $String$3 = global$8.String;
224
+ var $String$3 = global$7.String;
240
225
 
241
226
  // eslint-disable-next-line es/no-object-getownpropertysymbols -- required for testing
242
227
  var symbolConstructorDetection = !!Object.getOwnPropertySymbols && !fails$5(function () {
@@ -318,41 +303,41 @@ var ordinaryToPrimitive$1 = function (input, pref) {
318
303
  throw new $TypeError$3("Can't convert object to primitive value");
319
304
  };
320
305
 
321
- var shared$3 = {exports: {}};
306
+ var sharedStore = {exports: {}};
322
307
 
323
- var global$7 = global$b;
308
+ var global$6 = global$a;
324
309
 
325
310
  // eslint-disable-next-line es/no-object-defineproperty -- safe
326
311
  var defineProperty$2 = Object.defineProperty;
327
312
 
328
313
  var defineGlobalProperty$3 = function (key, value) {
329
314
  try {
330
- defineProperty$2(global$7, key, { value: value, configurable: true, writable: true });
315
+ defineProperty$2(global$6, key, { value: value, configurable: true, writable: true });
331
316
  } catch (error) {
332
- global$7[key] = value;
317
+ global$6[key] = value;
333
318
  } return value;
334
319
  };
335
320
 
336
- var global$6 = global$b;
321
+ var globalThis$1 = global$a;
337
322
  var defineGlobalProperty$2 = defineGlobalProperty$3;
338
323
 
339
324
  var SHARED = '__core-js_shared__';
340
- var store$3 = global$6[SHARED] || defineGlobalProperty$2(SHARED, {});
325
+ var store$3 = sharedStore.exports = globalThis$1[SHARED] || defineGlobalProperty$2(SHARED, {});
341
326
 
342
- var sharedStore = store$3;
343
-
344
- var store$2 = sharedStore;
345
-
346
- (shared$3.exports = function (key, value) {
347
- return store$2[key] || (store$2[key] = value !== undefined ? value : {});
348
- })('versions', []).push({
349
- version: '3.33.2',
327
+ (store$3.versions || (store$3.versions = [])).push({
328
+ version: '3.37.1',
350
329
  mode: 'global',
351
- copyright: '© 2014-2023 Denis Pushkarev (zloirock.ru)',
352
- license: 'https://github.com/zloirock/core-js/blob/v3.33.2/LICENSE',
330
+ copyright: '© 2014-2024 Denis Pushkarev (zloirock.ru)',
331
+ license: 'https://github.com/zloirock/core-js/blob/v3.37.1/LICENSE',
353
332
  source: 'https://github.com/zloirock/core-js'
354
333
  });
355
334
 
335
+ var store$2 = sharedStore.exports;
336
+
337
+ var shared$3 = function (key, value) {
338
+ return store$2[key] || (store$2[key] = value || {});
339
+ };
340
+
356
341
  var requireObjectCoercible = requireObjectCoercible$2;
357
342
 
358
343
  var $Object = Object;
@@ -385,8 +370,8 @@ var uid$2 = function (key) {
385
370
  return 'Symbol(' + (key === undefined ? '' : key) + ')_' + toString(++id + postfix, 36);
386
371
  };
387
372
 
388
- var global$5 = global$b;
389
- var shared$2 = shared$3.exports;
373
+ var global$5 = global$a;
374
+ var shared$2 = shared$3;
390
375
  var hasOwn$6 = hasOwnProperty_1;
391
376
  var uid$1 = uid$2;
392
377
  var NATIVE_SYMBOL = symbolConstructorDetection;
@@ -440,7 +425,7 @@ var toPropertyKey$2 = function (argument) {
440
425
  return isSymbol(key) ? key : key + '';
441
426
  };
442
427
 
443
- var global$4 = global$b;
428
+ var global$4 = global$a;
444
429
  var isObject$2 = isObject$5;
445
430
 
446
431
  var document$1 = global$4.document;
@@ -589,7 +574,7 @@ var functionName = {
589
574
 
590
575
  var uncurryThis$4 = functionUncurryThis;
591
576
  var isCallable$4 = isCallable$a;
592
- var store$1 = sharedStore;
577
+ var store$1 = sharedStore.exports;
593
578
 
594
579
  var functionToString = uncurryThis$4(Function.toString);
595
580
 
@@ -602,14 +587,14 @@ if (!isCallable$4(store$1.inspectSource)) {
602
587
 
603
588
  var inspectSource$1 = store$1.inspectSource;
604
589
 
605
- var global$3 = global$b;
590
+ var global$3 = global$a;
606
591
  var isCallable$3 = isCallable$a;
607
592
 
608
593
  var WeakMap$1 = global$3.WeakMap;
609
594
 
610
595
  var weakMapBasicDetection = isCallable$3(WeakMap$1) && /native code/.test(String(WeakMap$1));
611
596
 
612
- var shared$1 = shared$3.exports;
597
+ var shared$1 = shared$3;
613
598
  var uid = uid$2;
614
599
 
615
600
  var keys = shared$1('keys');
@@ -621,11 +606,11 @@ var sharedKey$1 = function (key) {
621
606
  var hiddenKeys$3 = {};
622
607
 
623
608
  var NATIVE_WEAK_MAP = weakMapBasicDetection;
624
- var global$2 = global$b;
609
+ var global$2 = global$a;
625
610
  var isObject = isObject$5;
626
611
  var createNonEnumerableProperty$1 = createNonEnumerableProperty$2;
627
612
  var hasOwn$3 = hasOwnProperty_1;
628
- var shared = sharedStore;
613
+ var shared = sharedStore.exports;
629
614
  var sharedKey = sharedKey$1;
630
615
  var hiddenKeys$2 = hiddenKeys$3;
631
616
 
@@ -717,7 +702,7 @@ var TEMPLATE = String(String).split('String');
717
702
 
718
703
  var makeBuiltIn$1 = makeBuiltIn$2.exports = function (value, name, options) {
719
704
  if (stringSlice($String(name), 0, 7) === 'Symbol(') {
720
- name = '[' + replace($String(name), /^Symbol\(([^)]*)\)/, '$1') + ']';
705
+ name = '[' + replace($String(name), /^Symbol\(([^)]*)\).*$/, '$1') + ']';
721
706
  }
722
707
  if (options && options.getter) name = 'get ' + name;
723
708
  if (options && options.setter) name = 'set ' + name;
@@ -817,7 +802,8 @@ var min = Math.min;
817
802
  // `ToLength` abstract operation
818
803
  // https://tc39.es/ecma262/#sec-tolength
819
804
  var toLength$1 = function (argument) {
820
- return argument > 0 ? min(toIntegerOrInfinity(argument), 0x1FFFFFFFFFFFFF) : 0; // 2 ** 53 - 1 == 9007199254740991
805
+ var len = toIntegerOrInfinity(argument);
806
+ return len > 0 ? min(len, 0x1FFFFFFFFFFFFF) : 0; // 2 ** 53 - 1 == 9007199254740991
821
807
  };
822
808
 
823
809
  var toLength = toLength$1;
@@ -837,6 +823,7 @@ var createMethod = function (IS_INCLUDES) {
837
823
  return function ($this, el, fromIndex) {
838
824
  var O = toIndexedObject$1($this);
839
825
  var length = lengthOfArrayLike(O);
826
+ if (length === 0) return !IS_INCLUDES && -1;
840
827
  var index = toAbsoluteIndex(fromIndex, length);
841
828
  var value;
842
829
  // Array#includes uses SameValueZero equality algorithm
@@ -965,7 +952,7 @@ var POLYFILL = isForced$1.POLYFILL = 'P';
965
952
 
966
953
  var isForced_1 = isForced$1;
967
954
 
968
- var global$1 = global$b;
955
+ var global$1 = global$a;
969
956
  var getOwnPropertyDescriptor = objectGetOwnPropertyDescriptor.f;
970
957
  var createNonEnumerableProperty = createNonEnumerableProperty$2;
971
958
  var defineBuiltIn = defineBuiltIn$1;
@@ -998,7 +985,7 @@ var _export = function (options, source) {
998
985
  } else if (STATIC) {
999
986
  target = global$1[TARGET] || defineGlobalProperty(TARGET, {});
1000
987
  } else {
1001
- target = (global$1[TARGET] || {}).prototype;
988
+ target = global$1[TARGET] && global$1[TARGET].prototype;
1002
989
  }
1003
990
  if (target) for (key in source) {
1004
991
  sourceProperty = source[key];
@@ -1146,10 +1133,14 @@ const Input = /*#__PURE__*/styled__default["default"].input.attrs({
1146
1133
  }).withConfig({
1147
1134
  displayName: "atoms-checkboxstyles__Input",
1148
1135
  componentId: "sc-1gq944z-2"
1149
- })(["appearance:none;margin:0;flex-shrink:0;cursor:pointer;width:14px;height:14px;outline:1px solid ", ";outline-offset:-1px;display:grid;place-content:center;&:focus{box-shadow:0 0 0 1px ", ",0 0 0 2px ", ";outline:none;}&:hover{&::before{content:'';width:8px;height:8px;transform:scale(1);box-shadow:inset 8px 8px ", ";}}&:disabled{outline:1px solid ", ";cursor:not-allowed;}&:checked{background-color:", ";&::before{content:'';width:8px;height:8px;clip-path:polygon(11% 38%,0 53%,49% 90%,100% 24%,87% 11%,47% 65%);box-shadow:inset 12px 12px ", ";transform:scale(1);}&:hover{background-color:", ";}&:disabled{background-color:", ";&::before{box-shadow:inset 12px 12px ", ";}}}&:disabled:not(:checked)&:hover{background-color:", ";&::before{box-shadow:inset 12px 12px ", ";}}"], ({
1136
+ })(["appearance:none;margin:0;flex-shrink:0;cursor:pointer;width:14px;height:14px;outline:", ";outline-offset:", ";border-radius:", ";display:grid;place-content:center;&:focus{box-shadow:0 0 0 1px ", ",0 0 0 2px ", ";outline:none;}&:hover{&::before{content:'';width:8px;height:8px;transform:scale(1);box-shadow:inset 8px 8px ", ";}}&:disabled{outline:", ";cursor:not-allowed;}&:checked{background-color:", ";outline-offset:", ";&::before{content:'';width:8px;height:8px;clip-path:polygon(11% 38%,0 53%,49% 90%,100% 24%,87% 11%,47% 65%);box-shadow:inset 12px 12px ", ";transform:scale(1);}&:hover{background-color:", ";}&:disabled{outline:", ";background-color:", ";&::before{box-shadow:inset 12px 12px ", ";}}}&:disabled:not(:checked)&:hover{background-color:", ";&::before{box-shadow:inset 12px 12px ", ";}}"], ({
1150
1137
  theme,
1151
1138
  $error
1152
- }) => $error ? theme.components.checkbox.square.color.error : theme.components.checkbox.square.color.default, ({
1139
+ }) => $error ? `${theme.components.checkbox.borderWidth.default} solid ${theme.components.checkbox.square.color.error}` : `${theme.components.checkbox.borderWidth.default} solid ${theme.components.checkbox.square.color.default}`, ({
1140
+ theme
1141
+ }) => `calc(${theme.components.checkbox.borderWidth.default}*-1)`, ({
1142
+ theme
1143
+ }) => theme.components.checkbox.borderRadius, ({
1153
1144
  theme
1154
1145
  }) => theme.components.checkbox.focus.color.focus, ({
1155
1146
  theme
@@ -1157,14 +1148,18 @@ const Input = /*#__PURE__*/styled__default["default"].input.attrs({
1157
1148
  theme
1158
1149
  }) => theme.components.checkbox.innerSquare.color.hover, ({
1159
1150
  theme
1160
- }) => theme.components.checkbox.square.color.disable, ({
1151
+ }) => `${theme.components.checkbox.borderWidth.default} solid ${theme.components.checkbox.square.color.disable}`, ({
1161
1152
  theme
1162
1153
  }) => theme.components.checkbox.innerSquare.color.selected, ({
1163
1154
  theme
1155
+ }) => `calc(${theme.components.checkbox.borderWidth.selected}*-1)`, ({
1156
+ theme
1164
1157
  }) => theme.components.checkbox.checkmark.color.selected, ({
1165
1158
  theme
1166
1159
  }) => theme.components.checkbox.innerSquare.color.hoverSelected, ({
1167
1160
  theme
1161
+ }) => `${theme.components.checkbox.borderWidth.selected} solid ${theme.components.checkbox.square.color.disableSelected}`, ({
1162
+ theme
1168
1163
  }) => theme.components.checkbox.innerSquare.color.disableSelected, ({
1169
1164
  theme
1170
1165
  }) => theme.components.checkbox.checkmark.color.selectedDisable, ({
package/package.json CHANGED
@@ -1,14 +1,14 @@
1
1
  {
2
2
  "name": "@bolttech/atoms-checkbox",
3
- "version": "0.17.0",
3
+ "version": "0.18.0",
4
4
  "main": "./index.cjs",
5
5
  "type": "commonjs",
6
6
  "types": "./src/index.d.ts",
7
7
  "dependencies": {
8
- "@bolttech/default-theme": "0.5.0",
9
- "@bolttech/form-engine": "0.10.3",
10
- "@bolttech/frontend-foundations": "0.7.0",
11
- "@bolttech/ui-utils": "0.2.4",
8
+ "@bolttech/default-theme": "0.7.0",
9
+ "@bolttech/form-engine": "0.14.3",
10
+ "@bolttech/frontend-foundations": "0.8.2",
11
+ "@bolttech/ui-utils": "0.2.5",
12
12
  "react": "18.2.0",
13
13
  "styled-components": "6.1.1"
14
14
  },