@oliasoft-open-source/react-ui-library 5.15.3 → 5.15.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.ts CHANGED
@@ -97,7 +97,7 @@ export declare enum Color {
97
97
  MUTED = "muted"
98
98
  }
99
99
 
100
- export declare const ColorInput: ({ columns, disabled, options, small, value, onChange, }: IColorInputProps) => JSX_2.Element;
100
+ export declare const ColorInput: ({ columns, disabled, options, small, value, onChange, adjustColorsInDarkMode, }: IColorInputProps) => JSX_2.Element;
101
101
 
102
102
  export declare const Column: ({ background, borderLeft, borderRight, children, flex, flexbox, padding, scroll, showScrollbar, spacing, width, widthMobile, widthTablet, testId, }: ILayoutColumnProps) => JSX_2.Element;
103
103
 
@@ -347,6 +347,7 @@ export declare interface IColorInputProps {
347
347
  small?: boolean;
348
348
  value?: string;
349
349
  onChange?: (value: string) => void;
350
+ adjustColorsInDarkMode?: boolean;
350
351
  }
351
352
 
352
353
  /**
package/dist/index.js CHANGED
@@ -1337,23 +1337,24 @@ const Popover = ({ children: t, content: n, placement: r = "top-center", closeOn
1337
1337
  })] });
1338
1338
  };
1339
1339
  var color_input_module_default = {
1340
- colorInput: "_colorInput_hb750_1",
1341
- trigger: "_trigger_hb750_8",
1342
- buttonColor: "_buttonColor_hb750_12",
1343
- options: "_options_hb750_17",
1344
- option: "_option_hb750_17"
1345
- };
1346
- const ColorInput = ({ columns: e = 9, disabled: t, options: n = [], small: r, value: i, onChange: a }) => {
1347
- var o;
1348
- let [s, c] = useState(!1), l = (o = n.find((e) => e.value === i)) == null ? void 0 : o.label;
1340
+ colorInput: "_colorInput_1j7vk_1",
1341
+ trigger: "_trigger_1j7vk_8",
1342
+ buttonColor: "_buttonColor_1j7vk_12",
1343
+ options: "_options_1j7vk_17",
1344
+ option: "_option_1j7vk_17",
1345
+ adjustColorsInDarkMode: "_adjustColorsInDarkMode_1j7vk_26"
1346
+ };
1347
+ const ColorInput = ({ columns: e = 9, disabled: t, options: n = [], small: r, value: i, onChange: a, adjustColorsInDarkMode: o = !1 }) => {
1348
+ var s;
1349
+ let [c, l] = useState(!1), u = (s = n.find((e) => e.value === i)) == null ? void 0 : s.label;
1349
1350
  return /* @__PURE__ */ jsx("div", {
1350
- className: color_input_module_default.colorInput,
1351
+ className: cx(color_input_module_default.colorInput, o ? color_input_module_default.adjustColorsInDarkMode : void 0),
1351
1352
  children: /* @__PURE__ */ jsx(Popover, {
1352
1353
  placement: "bottom-start",
1353
- isOpen: s,
1354
- onToggle: c,
1354
+ isOpen: c,
1355
+ onToggle: l,
1355
1356
  content: /* @__PURE__ */ jsx("div", {
1356
- className: color_input_module_default.options,
1357
+ className: cx(color_input_module_default.options, o ? color_input_module_default.adjustColorsInDarkMode : void 0),
1357
1358
  style: { gridTemplateColumns: `repeat(${e}, auto)` },
1358
1359
  children: n.map((e) => /* @__PURE__ */ jsx("div", {
1359
1360
  className: color_input_module_default.option,
@@ -1367,7 +1368,7 @@ const ColorInput = ({ columns: e = 9, disabled: t, options: n = [], small: r, va
1367
1368
  style: { backgroundColor: e.value }
1368
1369
  }),
1369
1370
  onClick: () => {
1370
- a == null || a(e.value), c(!1);
1371
+ a == null || a(e.value), l(!1);
1371
1372
  }
1372
1373
  }, e.value)
1373
1374
  }))
@@ -1375,9 +1376,9 @@ const ColorInput = ({ columns: e = 9, disabled: t, options: n = [], small: r, va
1375
1376
  children: /* @__PURE__ */ jsx(Button, {
1376
1377
  disabled: t,
1377
1378
  small: r,
1378
- active: s,
1379
+ active: c,
1379
1380
  width: r ? "var(--size-sm)" : "var(--size)",
1380
- tooltip: l,
1381
+ tooltip: u,
1381
1382
  label: /* @__PURE__ */ jsx("div", {
1382
1383
  className: color_input_module_default.buttonColor,
1383
1384
  style: { backgroundColor: i }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@oliasoft-open-source/react-ui-library",
3
- "version": "5.15.3",
3
+ "version": "5.15.4",
4
4
  "description": "Reusable UI components for React projects",
5
5
  "homepage": "https://oliasoft-open-source.gitlab.io/react-ui-library",
6
6
  "bugs": {