@yamada-ui/utils 0.1.0 → 0.1.1

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.
@@ -120,45 +120,43 @@ var useUpdateEffect = (callback, deps) => {
120
120
  };
121
121
 
122
122
  // src/color.ts
123
- import { TinyColor } from "@ctrl/tinycolor";
123
+ import { toHex, parseToRgba, transparentize, mix, darken, lighten } from "color2k";
124
124
  var getColor = (color, fallback) => (theme, colorMode) => {
125
125
  const hex = getMemoizedObject(
126
126
  theme,
127
127
  `colors.${color}`,
128
128
  color
129
129
  );
130
- if (isArray(hex)) {
131
- const [lightHex, darkHex] = hex;
132
- const { isValid, originalInput } = new TinyColor(colorMode !== "dark" ? lightHex : darkHex);
133
- return isValid ? originalInput : fallback;
134
- } else {
135
- const { isValid, originalInput } = new TinyColor(hex);
136
- return isValid ? originalInput : fallback;
130
+ try {
131
+ if (isArray(hex)) {
132
+ const [lightHex, darkHex] = hex;
133
+ return toHex(String(colorMode !== "dark" ? lightHex : darkHex));
134
+ } else {
135
+ return toHex(String(hex));
136
+ }
137
+ } catch {
138
+ return fallback != null ? fallback : "#000000";
137
139
  }
138
140
  };
139
141
  var lightenColor = (color, amount) => (theme, colorMode) => {
140
142
  const raw = getColor(color)(theme, colorMode);
141
- return new TinyColor(raw).lighten(amount).toRgbString();
143
+ return toHex(lighten(raw, amount / 100));
142
144
  };
143
145
  var darkenColor = (color, amount) => (theme, colorMode) => {
144
146
  const raw = getColor(color)(theme, colorMode);
145
- return new TinyColor(raw).darken(amount).toRgbString();
146
- };
147
- var brightenColor = (color, amount) => (theme, colorMode) => {
148
- const raw = getColor(color)(theme, colorMode);
149
- return new TinyColor(raw).brighten(amount).toRgbString();
147
+ return toHex(darken(raw, amount / 100));
150
148
  };
151
149
  var tintColor = (color, amount) => (theme, colorMode) => {
152
150
  const raw = getColor(color)(theme, colorMode);
153
- return new TinyColor(raw).tint(amount).toRgbString();
151
+ return toHex(mix(raw, "#fff", amount));
154
152
  };
155
153
  var shadeColor = (color, amount) => (theme, colorMode) => {
156
154
  const raw = getColor(color)(theme, colorMode);
157
- return new TinyColor(raw).shade(amount).toRgbString();
155
+ return toHex(mix(raw, "#000", amount / 100));
158
156
  };
159
157
  var transparentizeColor = (color, alpha) => (theme, colorMode) => {
160
158
  const raw = getColor(color)(theme, colorMode);
161
- return new TinyColor(raw).setAlpha(alpha).toRgbString();
159
+ return transparentize(raw, 1 - alpha);
162
160
  };
163
161
  var toneColor = (color, l) => (theme, colorMode) => {
164
162
  const raw = getColor(color)(theme, colorMode);
@@ -170,7 +168,7 @@ var toneColor = (color, l) => (theme, colorMode) => {
170
168
  n *= -1;
171
169
  if (n !== 0)
172
170
  n = n - 5 * (isLighten ? 1 : -1);
173
- return new TinyColor(raw)[isLighten ? "lighten" : "shade"](n).toString();
171
+ return toHex(isLighten ? lighten(raw, n / 100) : mix(raw, "#000", n / 100));
174
172
  };
175
173
  var randomColor = ({ string, colors } = {}) => {
176
174
  const fallback = randomHex();
@@ -210,14 +208,18 @@ var randomColorFromList = (str, list) => {
210
208
  return list[index];
211
209
  };
212
210
  var randomFromList = (list) => list[Math.floor(Math.random() * list.length)];
213
- var isLight = (color) => (theme, colorMode) => {
214
- const raw = getColor(color)(theme, colorMode);
215
- return new TinyColor(raw).isLight();
211
+ var getBrightness = (color) => {
212
+ const [r, g, b] = parseToRgba(color);
213
+ return (r * 299 + g * 587 + b * 114) / 1e3;
216
214
  };
217
- var isDark = (color) => (theme, colorMode) => {
215
+ var isTone = (color) => (theme, colorMode) => {
218
216
  const raw = getColor(color)(theme, colorMode);
219
- return new TinyColor(raw).isDark();
217
+ const brightness = getBrightness(raw);
218
+ const isDark2 = brightness < 128;
219
+ return isDark2 ? "dark" : "light";
220
220
  };
221
+ var isLight = (color) => (theme, colorMode) => isTone(color)(theme, colorMode) === "dark";
222
+ var isDark = (color) => (theme, colorMode) => isTone(color)(theme, colorMode) === "light";
221
223
 
222
224
  // src/object.ts
223
225
  var omitObject = (obj, keys) => {
@@ -390,12 +392,12 @@ export {
390
392
  getColor,
391
393
  lightenColor,
392
394
  darkenColor,
393
- brightenColor,
394
395
  tintColor,
395
396
  shadeColor,
396
397
  transparentizeColor,
397
398
  toneColor,
398
399
  randomColor,
400
+ isTone,
399
401
  isLight,
400
402
  isDark
401
403
  };
package/dist/color.d.ts CHANGED
@@ -1,10 +1,8 @@
1
- import * as _ctrl_tinycolor from '@ctrl/tinycolor';
2
1
  import { Dict } from './index.types.js';
3
2
 
4
- declare const getColor: (color: string, fallback?: string) => (theme: Dict, colorMode: 'light' | 'dark' | undefined) => string | number | _ctrl_tinycolor.RGB | _ctrl_tinycolor.HSL | _ctrl_tinycolor.HSV | undefined;
3
+ declare const getColor: (color: string, fallback?: string) => (theme: Dict, colorMode: 'light' | 'dark' | undefined) => string;
5
4
  declare const lightenColor: (color: string, amount: number) => (theme: Dict, colorMode: 'light' | 'dark' | undefined) => string;
6
5
  declare const darkenColor: (color: string, amount: number) => (theme: Dict, colorMode: 'light' | 'dark' | undefined) => string;
7
- declare const brightenColor: (color: string, amount: number) => (theme: Dict, colorMode: 'light' | 'dark' | undefined) => string;
8
6
  declare const tintColor: (color: string, amount: number) => (theme: Dict, colorMode: 'light' | 'dark' | undefined) => string;
9
7
  declare const shadeColor: (color: string, amount: number) => (theme: Dict, colorMode: 'light' | 'dark' | undefined) => string;
10
8
  declare const transparentizeColor: (color: string, alpha: number) => (theme: Dict, colorMode: 'light' | 'dark' | undefined) => string;
@@ -13,7 +11,8 @@ declare const randomColor: ({ string, colors }?: {
13
11
  string?: string | undefined;
14
12
  colors?: string[] | undefined;
15
13
  }) => string;
14
+ declare const isTone: (color: string) => (theme: Dict, colorMode: 'light' | 'dark' | undefined) => "light" | "dark";
16
15
  declare const isLight: (color: string) => (theme: Dict, colorMode: 'light' | 'dark' | undefined) => boolean;
17
16
  declare const isDark: (color: string) => (theme: Dict, colorMode: 'light' | 'dark' | undefined) => boolean;
18
17
 
19
- export { brightenColor, darkenColor, getColor, isDark, isLight, lightenColor, randomColor, shadeColor, tintColor, toneColor, transparentizeColor };
18
+ export { darkenColor, getColor, isDark, isLight, isTone, lightenColor, randomColor, shadeColor, tintColor, toneColor, transparentizeColor };
package/dist/color.js CHANGED
@@ -20,11 +20,11 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
20
20
  // src/color.ts
21
21
  var color_exports = {};
22
22
  __export(color_exports, {
23
- brightenColor: () => brightenColor,
24
23
  darkenColor: () => darkenColor,
25
24
  getColor: () => getColor,
26
25
  isDark: () => isDark,
27
26
  isLight: () => isLight,
27
+ isTone: () => isTone,
28
28
  lightenColor: () => lightenColor,
29
29
  randomColor: () => randomColor,
30
30
  shadeColor: () => shadeColor,
@@ -33,7 +33,7 @@ __export(color_exports, {
33
33
  transparentizeColor: () => transparentizeColor
34
34
  });
35
35
  module.exports = __toCommonJS(color_exports);
36
- var import_tinycolor = require("@ctrl/tinycolor");
36
+ var import_color2k = require("color2k");
37
37
 
38
38
  // src/assertion.ts
39
39
  var isArray = (value) => Array.isArray(value);
@@ -74,38 +74,36 @@ var getColor = (color, fallback) => (theme, colorMode) => {
74
74
  `colors.${color}`,
75
75
  color
76
76
  );
77
- if (isArray(hex)) {
78
- const [lightHex, darkHex] = hex;
79
- const { isValid, originalInput } = new import_tinycolor.TinyColor(colorMode !== "dark" ? lightHex : darkHex);
80
- return isValid ? originalInput : fallback;
81
- } else {
82
- const { isValid, originalInput } = new import_tinycolor.TinyColor(hex);
83
- return isValid ? originalInput : fallback;
77
+ try {
78
+ if (isArray(hex)) {
79
+ const [lightHex, darkHex] = hex;
80
+ return (0, import_color2k.toHex)(String(colorMode !== "dark" ? lightHex : darkHex));
81
+ } else {
82
+ return (0, import_color2k.toHex)(String(hex));
83
+ }
84
+ } catch {
85
+ return fallback != null ? fallback : "#000000";
84
86
  }
85
87
  };
86
88
  var lightenColor = (color, amount) => (theme, colorMode) => {
87
89
  const raw = getColor(color)(theme, colorMode);
88
- return new import_tinycolor.TinyColor(raw).lighten(amount).toRgbString();
90
+ return (0, import_color2k.toHex)((0, import_color2k.lighten)(raw, amount / 100));
89
91
  };
90
92
  var darkenColor = (color, amount) => (theme, colorMode) => {
91
93
  const raw = getColor(color)(theme, colorMode);
92
- return new import_tinycolor.TinyColor(raw).darken(amount).toRgbString();
93
- };
94
- var brightenColor = (color, amount) => (theme, colorMode) => {
95
- const raw = getColor(color)(theme, colorMode);
96
- return new import_tinycolor.TinyColor(raw).brighten(amount).toRgbString();
94
+ return (0, import_color2k.toHex)((0, import_color2k.darken)(raw, amount / 100));
97
95
  };
98
96
  var tintColor = (color, amount) => (theme, colorMode) => {
99
97
  const raw = getColor(color)(theme, colorMode);
100
- return new import_tinycolor.TinyColor(raw).tint(amount).toRgbString();
98
+ return (0, import_color2k.toHex)((0, import_color2k.mix)(raw, "#fff", amount));
101
99
  };
102
100
  var shadeColor = (color, amount) => (theme, colorMode) => {
103
101
  const raw = getColor(color)(theme, colorMode);
104
- return new import_tinycolor.TinyColor(raw).shade(amount).toRgbString();
102
+ return (0, import_color2k.toHex)((0, import_color2k.mix)(raw, "#000", amount / 100));
105
103
  };
106
104
  var transparentizeColor = (color, alpha) => (theme, colorMode) => {
107
105
  const raw = getColor(color)(theme, colorMode);
108
- return new import_tinycolor.TinyColor(raw).setAlpha(alpha).toRgbString();
106
+ return (0, import_color2k.transparentize)(raw, 1 - alpha);
109
107
  };
110
108
  var toneColor = (color, l) => (theme, colorMode) => {
111
109
  const raw = getColor(color)(theme, colorMode);
@@ -117,7 +115,7 @@ var toneColor = (color, l) => (theme, colorMode) => {
117
115
  n *= -1;
118
116
  if (n !== 0)
119
117
  n = n - 5 * (isLighten ? 1 : -1);
120
- return new import_tinycolor.TinyColor(raw)[isLighten ? "lighten" : "shade"](n).toString();
118
+ return (0, import_color2k.toHex)(isLighten ? (0, import_color2k.lighten)(raw, n / 100) : (0, import_color2k.mix)(raw, "#000", n / 100));
121
119
  };
122
120
  var randomColor = ({ string, colors } = {}) => {
123
121
  const fallback = randomHex();
@@ -157,21 +155,25 @@ var randomColorFromList = (str, list) => {
157
155
  return list[index];
158
156
  };
159
157
  var randomFromList = (list) => list[Math.floor(Math.random() * list.length)];
160
- var isLight = (color) => (theme, colorMode) => {
161
- const raw = getColor(color)(theme, colorMode);
162
- return new import_tinycolor.TinyColor(raw).isLight();
158
+ var getBrightness = (color) => {
159
+ const [r, g, b] = (0, import_color2k.parseToRgba)(color);
160
+ return (r * 299 + g * 587 + b * 114) / 1e3;
163
161
  };
164
- var isDark = (color) => (theme, colorMode) => {
162
+ var isTone = (color) => (theme, colorMode) => {
165
163
  const raw = getColor(color)(theme, colorMode);
166
- return new import_tinycolor.TinyColor(raw).isDark();
164
+ const brightness = getBrightness(raw);
165
+ const isDark2 = brightness < 128;
166
+ return isDark2 ? "dark" : "light";
167
167
  };
168
+ var isLight = (color) => (theme, colorMode) => isTone(color)(theme, colorMode) === "dark";
169
+ var isDark = (color) => (theme, colorMode) => isTone(color)(theme, colorMode) === "light";
168
170
  // Annotate the CommonJS export names for ESM import in node:
169
171
  0 && (module.exports = {
170
- brightenColor,
171
172
  darkenColor,
172
173
  getColor,
173
174
  isDark,
174
175
  isLight,
176
+ isTone,
175
177
  lightenColor,
176
178
  randomColor,
177
179
  shadeColor,
package/dist/color.mjs CHANGED
@@ -1,16 +1,16 @@
1
1
  import {
2
- brightenColor,
3
2
  darkenColor,
4
3
  getColor,
5
4
  isDark,
6
5
  isLight,
6
+ isTone,
7
7
  lightenColor,
8
8
  randomColor,
9
9
  shadeColor,
10
10
  tintColor,
11
11
  toneColor,
12
12
  transparentizeColor
13
- } from "./chunk-A6J4FUU7.mjs";
13
+ } from "./chunk-HUEOJZVC.mjs";
14
14
  import "./chunk-SLJ4M7XC.mjs";
15
15
  import "./chunk-VYMGBE25.mjs";
16
16
  import "./chunk-BZAW2D6U.mjs";
@@ -20,11 +20,11 @@ import "./chunk-R5OUKGQ5.mjs";
20
20
  import "./chunk-FW7XS4NH.mjs";
21
21
  import "./chunk-PF7LRFIA.mjs";
22
22
  export {
23
- brightenColor,
24
23
  darkenColor,
25
24
  getColor,
26
25
  isDark,
27
26
  isLight,
27
+ isTone,
28
28
  lightenColor,
29
29
  randomColor,
30
30
  shadeColor,
package/dist/function.mjs CHANGED
@@ -3,7 +3,7 @@ import {
3
3
  handlerAll,
4
4
  noop,
5
5
  runIfFunc
6
- } from "./chunk-A6J4FUU7.mjs";
6
+ } from "./chunk-HUEOJZVC.mjs";
7
7
  import "./chunk-SLJ4M7XC.mjs";
8
8
  import "./chunk-VYMGBE25.mjs";
9
9
  import "./chunk-BZAW2D6U.mjs";
package/dist/index.d.ts CHANGED
@@ -6,9 +6,8 @@ export { DOMAttributes, MaybeRenderProp, PropGetter, RequiredPropGetter, assignR
6
6
  export { FocusableElement, ariaAttr, createdDom, dataAttr, getActiveElement, getAllFocusable, getEventRelatedTarget, getOwnerDocument, getOwnerWindow, getPlatform, hasNegativeTabIndex, hasTabIndex, isActiveElement, isApple, isContains, isContentEditable, isDisabled, isElement, isFocusable, isHTMLElement, isHidden, isMac, isSafari, isTabbable, platform, vendor } from './dom.js';
7
7
  export { escape } from './string.js';
8
8
  export { Operand, calc } from './calc.js';
9
- export { brightenColor, darkenColor, getColor, isDark, isLight, lightenColor, randomColor, shadeColor, tintColor, toneColor, transparentizeColor } from './color.js';
9
+ export { darkenColor, getColor, isDark, isLight, isTone, lightenColor, randomColor, shadeColor, tintColor, toneColor, transparentizeColor } from './color.js';
10
10
  export { filterEmpty } from './array.js';
11
11
  export { clampNumber, countDecimal, percentToValue, roundNumberToStep, toPrecision, valueToPercent } from './number.js';
12
12
  export { AnyPointerEvent, MixedEventListener, Point, PointType, PointerEventInfo, addDomEvent, addPointerEvent, getEventPoint, getEventWindow, isMouseEvent, isMultiTouchEvent, isTouchEvent, pointFromMouse, pointFromTouch } from './event.js';
13
13
  import 'react';
14
- import '@ctrl/tinycolor';
package/dist/index.js CHANGED
@@ -35,7 +35,6 @@ __export(src_exports, {
35
35
  ariaAttr: () => ariaAttr,
36
36
  assignAfter: () => assignAfter,
37
37
  assignRef: () => assignRef,
38
- brightenColor: () => brightenColor,
39
38
  calc: () => calc,
40
39
  cast: () => cast,
41
40
  clampNumber: () => clampNumber,
@@ -94,6 +93,7 @@ __export(src_exports, {
94
93
  isSafari: () => isSafari,
95
94
  isString: () => isString,
96
95
  isTabbable: () => isTabbable,
96
+ isTone: () => isTone,
97
97
  isTouchEvent: () => isTouchEvent,
98
98
  isUndefined: () => isUndefined,
99
99
  isUnit: () => isUnit,
@@ -518,45 +518,43 @@ var calc = Object.assign(
518
518
  );
519
519
 
520
520
  // src/color.ts
521
- var import_tinycolor = require("@ctrl/tinycolor");
521
+ var import_color2k = require("color2k");
522
522
  var getColor = (color, fallback) => (theme, colorMode) => {
523
523
  const hex = getMemoizedObject(
524
524
  theme,
525
525
  `colors.${color}`,
526
526
  color
527
527
  );
528
- if (isArray(hex)) {
529
- const [lightHex, darkHex] = hex;
530
- const { isValid, originalInput } = new import_tinycolor.TinyColor(colorMode !== "dark" ? lightHex : darkHex);
531
- return isValid ? originalInput : fallback;
532
- } else {
533
- const { isValid, originalInput } = new import_tinycolor.TinyColor(hex);
534
- return isValid ? originalInput : fallback;
528
+ try {
529
+ if (isArray(hex)) {
530
+ const [lightHex, darkHex] = hex;
531
+ return (0, import_color2k.toHex)(String(colorMode !== "dark" ? lightHex : darkHex));
532
+ } else {
533
+ return (0, import_color2k.toHex)(String(hex));
534
+ }
535
+ } catch {
536
+ return fallback != null ? fallback : "#000000";
535
537
  }
536
538
  };
537
539
  var lightenColor = (color, amount) => (theme, colorMode) => {
538
540
  const raw = getColor(color)(theme, colorMode);
539
- return new import_tinycolor.TinyColor(raw).lighten(amount).toRgbString();
541
+ return (0, import_color2k.toHex)((0, import_color2k.lighten)(raw, amount / 100));
540
542
  };
541
543
  var darkenColor = (color, amount) => (theme, colorMode) => {
542
544
  const raw = getColor(color)(theme, colorMode);
543
- return new import_tinycolor.TinyColor(raw).darken(amount).toRgbString();
544
- };
545
- var brightenColor = (color, amount) => (theme, colorMode) => {
546
- const raw = getColor(color)(theme, colorMode);
547
- return new import_tinycolor.TinyColor(raw).brighten(amount).toRgbString();
545
+ return (0, import_color2k.toHex)((0, import_color2k.darken)(raw, amount / 100));
548
546
  };
549
547
  var tintColor = (color, amount) => (theme, colorMode) => {
550
548
  const raw = getColor(color)(theme, colorMode);
551
- return new import_tinycolor.TinyColor(raw).tint(amount).toRgbString();
549
+ return (0, import_color2k.toHex)((0, import_color2k.mix)(raw, "#fff", amount));
552
550
  };
553
551
  var shadeColor = (color, amount) => (theme, colorMode) => {
554
552
  const raw = getColor(color)(theme, colorMode);
555
- return new import_tinycolor.TinyColor(raw).shade(amount).toRgbString();
553
+ return (0, import_color2k.toHex)((0, import_color2k.mix)(raw, "#000", amount / 100));
556
554
  };
557
555
  var transparentizeColor = (color, alpha) => (theme, colorMode) => {
558
556
  const raw = getColor(color)(theme, colorMode);
559
- return new import_tinycolor.TinyColor(raw).setAlpha(alpha).toRgbString();
557
+ return (0, import_color2k.transparentize)(raw, 1 - alpha);
560
558
  };
561
559
  var toneColor = (color, l) => (theme, colorMode) => {
562
560
  const raw = getColor(color)(theme, colorMode);
@@ -568,7 +566,7 @@ var toneColor = (color, l) => (theme, colorMode) => {
568
566
  n *= -1;
569
567
  if (n !== 0)
570
568
  n = n - 5 * (isLighten ? 1 : -1);
571
- return new import_tinycolor.TinyColor(raw)[isLighten ? "lighten" : "shade"](n).toString();
569
+ return (0, import_color2k.toHex)(isLighten ? (0, import_color2k.lighten)(raw, n / 100) : (0, import_color2k.mix)(raw, "#000", n / 100));
572
570
  };
573
571
  var randomColor = ({ string, colors } = {}) => {
574
572
  const fallback = randomHex();
@@ -608,14 +606,18 @@ var randomColorFromList = (str, list) => {
608
606
  return list[index];
609
607
  };
610
608
  var randomFromList = (list) => list[Math.floor(Math.random() * list.length)];
611
- var isLight = (color) => (theme, colorMode) => {
612
- const raw = getColor(color)(theme, colorMode);
613
- return new import_tinycolor.TinyColor(raw).isLight();
609
+ var getBrightness = (color) => {
610
+ const [r, g, b] = (0, import_color2k.parseToRgba)(color);
611
+ return (r * 299 + g * 587 + b * 114) / 1e3;
614
612
  };
615
- var isDark = (color) => (theme, colorMode) => {
613
+ var isTone = (color) => (theme, colorMode) => {
616
614
  const raw = getColor(color)(theme, colorMode);
617
- return new import_tinycolor.TinyColor(raw).isDark();
615
+ const brightness = getBrightness(raw);
616
+ const isDark2 = brightness < 128;
617
+ return isDark2 ? "dark" : "light";
618
618
  };
619
+ var isLight = (color) => (theme, colorMode) => isTone(color)(theme, colorMode) === "dark";
620
+ var isDark = (color) => (theme, colorMode) => isTone(color)(theme, colorMode) === "light";
619
621
 
620
622
  // src/array.ts
621
623
  var filterEmpty = (array) => array.filter((value) => value != null);
@@ -697,7 +699,6 @@ var addPointerEvent = (target, type, cb, options) => addDomEvent(target, type, w
697
699
  ariaAttr,
698
700
  assignAfter,
699
701
  assignRef,
700
- brightenColor,
701
702
  calc,
702
703
  cast,
703
704
  clampNumber,
@@ -756,6 +757,7 @@ var addPointerEvent = (target, type, cb, options) => addDomEvent(target, type, w
756
757
  isSafari,
757
758
  isString,
758
759
  isTabbable,
760
+ isTone,
759
761
  isTouchEvent,
760
762
  isUndefined,
761
763
  isUnit,
package/dist/index.mjs CHANGED
@@ -1,7 +1,6 @@
1
1
  import {
2
2
  assignAfter,
3
3
  assignRef,
4
- brightenColor,
5
4
  createContext,
6
5
  cx,
7
6
  darkenColor,
@@ -19,6 +18,7 @@ import {
19
18
  isDark,
20
19
  isLight,
21
20
  isRefObject,
21
+ isTone,
22
22
  isValidElement,
23
23
  keysFormObject,
24
24
  lightenColor,
@@ -45,7 +45,7 @@ import {
45
45
  useSafeLayoutEffect,
46
46
  useUnmountEffect,
47
47
  useUpdateEffect
48
- } from "./chunk-A6J4FUU7.mjs";
48
+ } from "./chunk-HUEOJZVC.mjs";
49
49
  import "./chunk-SLJ4M7XC.mjs";
50
50
  import {
51
51
  clampNumber,
@@ -122,7 +122,6 @@ export {
122
122
  ariaAttr,
123
123
  assignAfter,
124
124
  assignRef,
125
- brightenColor,
126
125
  calc,
127
126
  cast,
128
127
  clampNumber,
@@ -181,6 +180,7 @@ export {
181
180
  isSafari,
182
181
  isString,
183
182
  isTabbable,
183
+ isTone,
184
184
  isTouchEvent,
185
185
  isUndefined,
186
186
  isUnit,
package/dist/object.mjs CHANGED
@@ -13,7 +13,7 @@ import {
13
13
  pickObject,
14
14
  replaceObject,
15
15
  splitObject
16
- } from "./chunk-A6J4FUU7.mjs";
16
+ } from "./chunk-HUEOJZVC.mjs";
17
17
  import "./chunk-SLJ4M7XC.mjs";
18
18
  import "./chunk-VYMGBE25.mjs";
19
19
  import "./chunk-BZAW2D6U.mjs";
package/dist/react.mjs CHANGED
@@ -16,7 +16,7 @@ import {
16
16
  useSafeLayoutEffect,
17
17
  useUnmountEffect,
18
18
  useUpdateEffect
19
- } from "./chunk-A6J4FUU7.mjs";
19
+ } from "./chunk-HUEOJZVC.mjs";
20
20
  import "./chunk-SLJ4M7XC.mjs";
21
21
  import "./chunk-VYMGBE25.mjs";
22
22
  import "./chunk-BZAW2D6U.mjs";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yamada-ui/utils",
3
- "version": "0.1.0",
3
+ "version": "0.1.1",
4
4
  "description": "Yamada UI utils",
5
5
  "keywords": [
6
6
  "utils",
@@ -28,11 +28,11 @@
28
28
  "url": "https://github.com/hirotomoyamada/yamada-ui/issues"
29
29
  },
30
30
  "dependencies": {
31
- "@ctrl/tinycolor": "^3.4.1"
31
+ "color2k": "^2.0.2"
32
32
  },
33
33
  "devDependencies": {
34
- "react": "^18.0.0",
35
- "clean-package": "2.2.0"
34
+ "clean-package": "2.2.0",
35
+ "react": "^18.0.0"
36
36
  },
37
37
  "peerDependencies": {
38
38
  "react": ">=18"