aristid-ds 1.0.1 → 1.1.0-9f03d8a

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 (59) hide show
  1. package/CHANGELOG.md +49 -0
  2. package/README.md +9 -1
  3. package/dist/Kit/App/index.js +1 -1
  4. package/dist/Kit/DataDisplay/Badge/index.js +13 -13
  5. package/dist/Kit/DataDisplay/Card/index.js +1 -1
  6. package/dist/Kit/DataDisplay/Collapse/index.js +1 -1
  7. package/dist/Kit/DataDisplay/ItemCard/index.js +1 -1
  8. package/dist/Kit/DataDisplay/ItemList/index.js +1 -1
  9. package/dist/Kit/DataDisplay/Tabs/index.js +7 -7
  10. package/dist/Kit/DataDisplay/Tag/index.js +1 -1
  11. package/dist/Kit/DataDisplay/index.js +1 -1
  12. package/dist/Kit/DataEntry/AutoComplete/index.js +25 -17
  13. package/dist/Kit/DataEntry/Checkbox/index.d.ts +2 -2
  14. package/dist/Kit/DataEntry/Checkbox/index.js +32 -32
  15. package/dist/Kit/DataEntry/ColorPicker/index.d.ts +2 -2
  16. package/dist/Kit/DataEntry/ColorPicker/index.js +11 -11
  17. package/dist/Kit/DataEntry/DatePicker/RangePicker.d.ts +4 -4
  18. package/dist/Kit/DataEntry/DatePicker/index.js +23 -25
  19. package/dist/Kit/DataEntry/Input/index.js +34 -34
  20. package/dist/Kit/DataEntry/InputNumber/index.js +14 -14
  21. package/dist/Kit/DataEntry/InputWrapper/index.js +1 -1
  22. package/dist/Kit/DataEntry/Radio/context.d.ts +1 -1
  23. package/dist/Kit/DataEntry/Radio/index.d.ts +4 -4
  24. package/dist/Kit/DataEntry/Radio/index.js +32 -32
  25. package/dist/Kit/DataEntry/Rate/index.d.ts +1 -1
  26. package/dist/Kit/DataEntry/Select/index.d.ts +1 -1
  27. package/dist/Kit/DataEntry/Select/index.js +9 -9
  28. package/dist/Kit/DataEntry/Slider/index.d.ts +1 -1
  29. package/dist/Kit/DataEntry/Upload/Upload.d.ts +1 -1
  30. package/dist/Kit/DataEntry/index.js +2 -2
  31. package/dist/Kit/Feedback/Modal/index.js +1 -1
  32. package/dist/Kit/Feedback/Notification/KitNotification.d.ts +2 -2
  33. package/dist/Kit/Feedback/Notification/index.js +1 -1
  34. package/dist/Kit/Feedback/index.js +1 -1
  35. package/dist/Kit/General/Typography/index.js +1 -1
  36. package/dist/Kit/Layout/Space/index.d.ts +1 -1
  37. package/dist/Kit/Navigation/Header/index.js +1 -1
  38. package/dist/Kit/Navigation/Menu/index.js +1 -1
  39. package/dist/Kit/Navigation/index.js +1 -1
  40. package/dist/Kit/index.js +2 -2
  41. package/dist/assets/InputWrapper.css +1 -1
  42. package/dist/assets/index19.css +1 -1
  43. package/dist/assets/index22.css +1 -1
  44. package/dist/assets/index25.css +1 -1
  45. package/dist/assets/index29.css +1 -1
  46. package/dist/assets/index5.css +1 -1
  47. package/dist/chunks/InputWrapper.69dUKMaK.js +47 -0
  48. package/dist/chunks/{KitNotification.CO3zqMt0.js → KitNotification.3hnPgsKv.js} +1 -1
  49. package/dist/chunks/index.9WV74It5.js +757 -0
  50. package/dist/chunks/{notification-provider.kV-P-2Jh.js → notification-provider.KGowspef.js} +10 -10
  51. package/dist/index.es.js +2 -2
  52. package/dist/theme/theme-context.d.ts +2 -2
  53. package/dist/theme/utils/tokens-mapper/DataEntry/ColorPicker/index.js +6 -6
  54. package/dist/theme/utils/tokens-mapper/DataEntry/DatePicker/index.js +3 -3
  55. package/dist/theme/utils/tokens-mapper/DataEntry/Input/index.js +5 -5
  56. package/dist/theme/utils/tokens-mapper/DataEntry/InputNumber/index.js +5 -5
  57. package/package.json +8 -3
  58. package/dist/chunks/InputWrapper.sHItZx7l.js +0 -40
  59. package/dist/chunks/index.kVWdzwin.js +0 -755
package/CHANGELOG.md CHANGED
@@ -1,6 +1,55 @@
1
1
  # Changelog
2
2
 
3
+ ## [X.X.X](https://www.npmjs.com/package/aristid-ds/v/X.X.Xx) (2024-XX-XX)
3
4
 
5
+ ### ✨ Features
6
+ * **InputWrapper:**
7
+ * Add 4 properties: (@evoiron)
8
+ * `required`: show a red asterisk right after the label
9
+ * `actions`: an array of items to display at the right of the label
10
+ * `onInfoClick`: When set, display a clickable info icon which triggers this event
11
+ * `infoIcon`: customise the infoIcon displayed
12
+ * These components now accept the 4 properties above: (@evoiron)
13
+ * `AutoComplete`, `Checkbox.Group`, `Radio.Group`, `ColorPicker`, `DatePicker`, `RangePicker`, `Input`, `InputNumber`, `Select`
14
+ * **Tabs:**
15
+ * Add `hideSeparator` prop to hide separator between tabs and content (@P0ppoff)
16
+ * (Style) Allow tabs center on extraContent (@P0ppoff)
17
+ * (Style) Reduce space between tabs and separator (@P0ppoff)
18
+
19
+ ### 🐛 Bug Fixes
20
+ * **Select:**
21
+ * Fix default border color (@philippechevieux)
22
+ * **Badge:**
23
+ * Fix custom className bug (@evoiron)
24
+ * **Input:**
25
+ * Update color of content, label, placeholder and clear icon (@TdyP)
26
+ * Add aria-label on clear icon to improve testability (@TdyP)
27
+ * **InputNumber:**
28
+ * Update color of content, label, placeholder and clear icon (@TdyP)
29
+ * **ColorPicker:**
30
+ * Update color of content, label and placeholder (@TdyP)
31
+ * **DatePicker:**
32
+ * Update color of content, label and placeholder (@TdyP)
33
+
34
+ ## [1.1.0](https://www.npmjs.com/package/aristid-ds/v/1.1.0) (2024-02-28)
35
+
36
+ ### ✨ Features
37
+ * **Nightly build:**
38
+ * publish a nightly version of the package under `next`. (@evoiron)
39
+
40
+ ### 🐛 Bug Fixes
41
+ * **AutoComplete:**
42
+ * Fix crashing release (@evoiron)
43
+
44
+ * **AutoComplete:**
45
+ * Fix dropdown border when focused or when a status is set (@philippechevieux)
46
+
47
+ * **Select:**
48
+ * Fix dropdown border when focused or when a status is set (@philippechevieux)
49
+ * Fix dropdown border on click on arrow (@renaudamsellem)
50
+
51
+ * **InputWrapper:**
52
+ * Fix border default color (@philippechevieux)
4
53
 
5
54
  ## [1.0.1](https://www.npmjs.com/package/aristid-ds/v/1.0.1) (2024-02-26)
6
55
  ### 🐛 Bug Fixes
package/README.md CHANGED
@@ -21,6 +21,7 @@ ARiSTiD Design System Readme.
21
21
  - [Component code](#component-code)
22
22
  - [Component theming](#component-theming)
23
23
  - [Component documentation](#component-documentation)
24
+ - [Nightly build](#nightly-build)
24
25
  - [Important](#important)
25
26
  - [Contributing](#contributing)
26
27
  - [Commit](#commit)
@@ -451,9 +452,16 @@ Every components **style** of the design system can be **override** by tokens.
451
452
  After the script run, section `Design Tokens` documentation is up to date with all design tokens.
452
453
 
453
454
 
455
+ ## Nightly build
456
+ A nightly version of the package is published on daily basis on branch develop (assuming new commits have been pushed on develop branch). To use it just install the more recent next version :
457
+
458
+ ```sh
459
+ yarn add aristid-ds@next
460
+ ```
461
+ **Note:** Though it is useful to test upcoming feature, this version should **NEVER** be used in production
454
462
 
455
463
  ## Important
456
- Every import of antd library should pass by `antd` or `/lib/antd`. `es` import will lead to issues in the build process.
464
+ Every import of antd library should pass by `antd` or `ant/es`. `lib` import will lead to issues in the build process.
457
465
 
458
466
  ## Contributing
459
467
 
@@ -13,7 +13,7 @@ import { frFR as m } from "../../translation/fr-FR/index.js";
13
13
  import { enUS as I } from "../../translation/en-US/index.js";
14
14
  import { K as F, u as R } from "../../chunks/useKitLocale.96CdK3og.js";
15
15
  import { mapKitLocaleToAntdLocale as T } from "../../translation/utils/index.js";
16
- import { d as $ } from "../../chunks/notification-provider.kV-P-2Jh.js";
16
+ import { d as $ } from "../../chunks/notification-provider.KGowspef.js";
17
17
  const k = P`
18
18
  .${(t) => t.id} {
19
19
  ${(t) => d(t.customTheme)};
@@ -1,18 +1,18 @@
1
1
  import "../../../assets/index.css";
2
- import l, { useMemo as p } from "react";
3
- import { Badge as g } from "antd";
4
- import { u } from "../../../chunks/useKitTheme.KSAU-Pdv.js";
5
- import { isValidColor as c, getColor as d, getLighterColor as f } from "../../../utils/functions/index.js";
6
- import { kitBadgeCssTokens as m } from "../../../theme/aristid/components/DataDisplay/Badge/index.js";
7
- import n from "classnames";
8
- const k = {
2
+ import g, { useMemo as l } from "react";
3
+ import { Badge as u } from "antd";
4
+ import { u as d } from "../../../chunks/useKitTheme.KSAU-Pdv.js";
5
+ import { isValidColor as f, getColor as n, getLighterColor as c } from "../../../utils/functions/index.js";
6
+ import { kitBadgeCssTokens as s } from "../../../theme/aristid/components/DataDisplay/Badge/index.js";
7
+ import k from "classnames";
8
+ const b = {
9
9
  "kit-badge": "_kit-badge_16zpm_2"
10
- }, B = (t, e) => !t || !c(t) ? null : {
11
- [m.colors.background.default]: d(t, e),
12
- [m.colors.typography.default]: f(t, e)
13
- }, C = ({ color: t, style: e, secondaryColorInvert: o = !1, ...s }) => {
14
- const { appId: a } = u(), i = p(() => ({ ...e, ...B(t, o) }), [t, o, e]), r = n(a, k["kit-badge"], s.className);
15
- return l.createElement(g, { style: i, className: r, ...s });
10
+ }, B = (t, e) => !t || !f(t) ? null : {
11
+ [s.colors.background.default]: n(t, e),
12
+ [s.colors.typography.default]: c(t, e)
13
+ }, C = ({ color: t, style: e, secondaryColorInvert: o = !1, className: m, ...r }) => {
14
+ const { appId: a } = d(), i = l(() => ({ ...e, ...B(t, o) }), [t, o, e]), p = k(a, b["kit-badge"], m);
15
+ return g.createElement(u, { style: i, ...r, className: p });
16
16
  };
17
17
  C.displayName = "KitBadge";
18
18
  export {
@@ -8,7 +8,7 @@ import "../../DataEntry/Input/index.js";
8
8
  import "../../DataEntry/InputNumber/index.js";
9
9
  import "../../DataEntry/Radio/index.js";
10
10
  import "../../DataEntry/Rate/index.js";
11
- import { K as y } from "../../../chunks/index.kVWdzwin.js";
11
+ import { K as y } from "../../../chunks/index.9WV74It5.js";
12
12
  import "../../DataEntry/Switch/index.js";
13
13
  import "../../DataEntry/DatePicker/index.js";
14
14
  import "../../DataEntry/AutoComplete/index.js";
@@ -1,4 +1,4 @@
1
- import { b as e } from "../../../chunks/index.kVWdzwin.js";
1
+ import { b as e } from "../../../chunks/index.9WV74It5.js";
2
2
  export {
3
3
  e as KitCollapse
4
4
  };
@@ -1,6 +1,6 @@
1
1
  import "react";
2
2
  import "classnames";
3
- import { a as q } from "../../../chunks/index.kVWdzwin.js";
3
+ import { a as q } from "../../../chunks/index.9WV74It5.js";
4
4
  import "../../General/Button/index.js";
5
5
  import "../../General/Typography/index.js";
6
6
  import "../../General/Icon/index.js";
@@ -4,7 +4,7 @@ import "../../DataEntry/Input/index.js";
4
4
  import "../../DataEntry/InputNumber/index.js";
5
5
  import "../../DataEntry/Radio/index.js";
6
6
  import "../../DataEntry/Rate/index.js";
7
- import { c as u } from "../../../chunks/index.kVWdzwin.js";
7
+ import { c as u } from "../../../chunks/index.9WV74It5.js";
8
8
  import "../../DataEntry/Switch/index.js";
9
9
  import "../../DataEntry/DatePicker/index.js";
10
10
  import "../../DataEntry/AutoComplete/index.js";
@@ -1,13 +1,13 @@
1
1
  import "../../../assets/index5.css";
2
2
  import i from "react";
3
- import { Tabs as e } from "antd";
4
- import { u as m } from "../../../chunks/useKitTheme.KSAU-Pdv.js";
5
- import c from "classnames";
3
+ import { Tabs as c } from "antd";
4
+ import { u as l } from "../../../chunks/useKitTheme.KSAU-Pdv.js";
5
+ import s from "classnames";
6
6
  const n = {
7
- "kit-tabs": "_kit-tabs_1cr1a_2"
8
- }, b = ({ className: o, popupClassName: t, ...r }) => {
9
- const { appId: s } = m(), a = c(s, n["kit-tabs"], o);
10
- return i.createElement(e, { className: a, popupClassName: `${s} ${t ?? ""}`, ...r });
7
+ "kit-tabs": "_kit-tabs_sc95q_2"
8
+ }, b = ({ className: a, popupClassName: o, hideSeparator: e = !1, ...p }) => {
9
+ const { appId: t } = l(), r = s(t, n["kit-tabs"], a, { "hide-separator": e }), m = s(t, o);
10
+ return i.createElement(c, { className: r, popupClassName: m, ...p });
11
11
  };
12
12
  b.displayName = "KitTabs";
13
13
  export {
@@ -1,4 +1,4 @@
1
- import { d as r } from "../../../chunks/index.kVWdzwin.js";
1
+ import { d as r } from "../../../chunks/index.9WV74It5.js";
2
2
  export {
3
3
  r as KitTag
4
4
  };
@@ -1,7 +1,7 @@
1
1
  import { KitAvatar as o } from "./Avatar/index.js";
2
2
  import { KitBadge as e } from "./Badge/index.js";
3
3
  import { KitLegacyCard as K } from "./LegacyCard/index.js";
4
- import { K as p, b as f, a as x, c as s, d } from "../../chunks/index.kVWdzwin.js";
4
+ import { K as p, b as f, a as x, c as s, d } from "../../chunks/index.9WV74It5.js";
5
5
  import { KitImage as g } from "./Image/index.js";
6
6
  import { KitTooltip as l } from "./Tooltip/index.js";
7
7
  import { KitTree as b } from "./Tree/index.js";
@@ -1,26 +1,34 @@
1
1
  import "../../../assets/index9.css";
2
- import t, { forwardRef as K } from "react";
3
- import { AutoComplete as d } from "antd";
4
- import { KitInput as w } from "../Input/index.js";
5
- import { K as x } from "../../../chunks/InputWrapper.sHItZx7l.js";
6
- import { FontAwesomeIcon as A } from "@fortawesome/react-fontawesome";
7
- import { faMagnifyingGlass as E } from "@fortawesome/free-solid-svg-icons";
8
- import N from "classnames";
9
- const y = {
2
+ import t, { forwardRef as N, useState as x } from "react";
3
+ import { AutoComplete as y } from "antd";
4
+ import { KitInput as h } from "../Input/index.js";
5
+ import { K as O } from "../../../chunks/InputWrapper.69dUKMaK.js";
6
+ import { FontAwesomeIcon as P } from "@fortawesome/react-fontawesome";
7
+ import { faMagnifyingGlass as R } from "@fortawesome/free-solid-svg-icons";
8
+ import z from "classnames";
9
+ const B = {
10
10
  "kit-autocomplete": "_kit-autocomplete_ekz5x_2"
11
- }, I = K(({ allowClear: m, label: p, helper: r, autoFocus: a, defaultValue: i, disabled: e, placeholder: n, status: o, value: c, onBlur: l, popupClassName: s, wrapperClassName: f, ...u }, k) => {
12
- const C = N("ant-select-dropdown", "kit-select-dropdown-bottom", s);
11
+ }, G = (o, r, e) => z(o, "ant-select-dropdown", "kit-select-dropdown-bottom", {
12
+ "kit-select-dropdown-focus": r,
13
+ "kit-select-dropdown-error": e === "error",
14
+ "kit-select-dropdown-warning": e === "warning"
15
+ }), M = N(({ allowClear: o, label: r, helper: e, autoFocus: i, defaultValue: l, disabled: p, placeholder: f, status: n, value: u, onFocus: s, onBlur: c, popupClassName: d, wrapperClassName: w, required: k, infoIcon: _, actions: g, onInfoClick: C, ...K }, A) => {
16
+ const [E, a] = x(!1), F = (m) => {
17
+ a(!0), s && s(m);
18
+ }, I = (m) => {
19
+ a(!1), c && c(m);
20
+ };
13
21
  return t.createElement(
14
- x,
15
- { label: p, helper: r, disabled: e, status: o, className: f },
22
+ O,
23
+ { label: r, helper: e, disabled: p, status: n, className: w, required: k, infoIcon: _, actions: g, onInfoClick: C },
16
24
  t.createElement(
17
- d,
18
- { ...u, disabled: e, ref: k, className: y["kit-autocomplete"], popupClassName: C },
19
- t.createElement(w, { prefix: t.createElement(A, { icon: E }), allowClear: m, autoFocus: a, defaultValue: i, placeholder: n, status: o, value: c, onBlur: l })
25
+ y,
26
+ { ...K, disabled: p, ref: A, className: B["kit-autocomplete"], popupClassName: G(d, E, n) },
27
+ t.createElement(h, { prefix: t.createElement(P, { icon: R }), allowClear: o, autoFocus: i, defaultValue: l, placeholder: f, status: n, value: u, onBlur: I, onFocus: F })
20
28
  )
21
29
  );
22
30
  });
23
- I.displayName = "KitAutoComplete";
31
+ M.displayName = "KitAutoComplete";
24
32
  export {
25
- I as KitAutoComplete
33
+ M as KitAutoComplete
26
34
  };
@@ -1,7 +1,7 @@
1
1
  import { ForwardRefExoticComponent, ForwardRefRenderFunction } from 'react';
2
2
  import { IKitCheckbox, ICheckboxGroup } from './types';
3
- export type { CheckboxChangeEvent } from 'antd/lib/checkbox/Checkbox';
4
- export type { CheckboxGroupProps, CheckboxOptionType } from 'antd/lib/checkbox/Group';
3
+ export type { CheckboxChangeEvent } from 'antd/es/checkbox/Checkbox';
4
+ export type { CheckboxGroupProps, CheckboxOptionType } from 'antd/es/checkbox/Group';
5
5
  type CompoundedComponent = ForwardRefExoticComponent<IKitCheckbox> & {
6
6
  Group: ForwardRefRenderFunction<HTMLDivElement, ICheckboxGroup>;
7
7
  };
@@ -1,58 +1,58 @@
1
1
  import "../../../assets/index21.css";
2
- import r, { createContext as X, memo as Y, forwardRef as S, useContext as N, useState as K, useEffect as V, useRef as Z } from "react";
3
- import { Checkbox as P } from "antd";
4
- import { u as p } from "../../../chunks/useKitTheme.KSAU-Pdv.js";
2
+ import r, { createContext as p, memo as ee, forwardRef as S, useContext as N, useState as K, useEffect as V, useRef as le } from "react";
3
+ import { Checkbox as ae } from "antd";
4
+ import { u as te } from "../../../chunks/useKitTheme.KSAU-Pdv.js";
5
5
  import O from "classnames";
6
- import ee from "rc-util/lib/omit";
7
- import { ConfigContext as le } from "antd/lib/config-provider/";
8
- import ae from "antd/lib/checkbox/style";
9
- import { K as te } from "../../../chunks/InputWrapper.sHItZx7l.js";
10
- const R = X(null), ne = ({ defaultValue: v, children: o, options: a = [], prefixCls: m, className: l, wrapperClassName: f, status: b, rootClassName: u, style: n, onChange: d, label: x, helper: $, ...t }, A) => {
11
- const { getPrefixCls: B, direction: D } = N(le), [s, y] = K(t.value || v || []), [T, G] = K([]);
6
+ import ne from "rc-util/es/omit";
7
+ import { ConfigContext as ce } from "antd/es/config-provider/";
8
+ import ie from "antd/es/checkbox/style";
9
+ import { K as ue } from "../../../chunks/InputWrapper.69dUKMaK.js";
10
+ const R = p(null), de = ({ defaultValue: v, children: o, options: a = [], prefixCls: m, className: l, wrapperClassName: f, status: b, rootClassName: u, style: n, onChange: d, label: x, helper: $, required: A, infoIcon: B, actions: D, onInfoClick: T, ...t }, W) => {
11
+ const { getPrefixCls: j, direction: q } = N(ce), [s, y] = K(t.value || v || []), [z, G] = K([]);
12
12
  V(() => {
13
13
  "value" in t && y(t.value || []);
14
14
  }, [t]);
15
15
  const I = () => a.map((e) => typeof e == "string" || typeof e == "number" ? {
16
16
  label: e,
17
17
  value: e
18
- } : e), W = (e) => {
18
+ } : e), F = (e) => {
19
19
  G((c) => c.filter((i) => i !== e));
20
- }, j = (e) => {
20
+ }, H = (e) => {
21
21
  G((c) => [...c, e]);
22
- }, q = (e) => {
22
+ }, J = (e) => {
23
23
  const c = s.indexOf(e.value), i = [...s];
24
24
  c === -1 ? i.push(e.value) : i.splice(c, 1), "value" in t || y(i);
25
25
  const E = I();
26
- d == null || d(i.filter((k) => T.includes(k)).sort((k, M) => {
27
- const Q = E.findIndex((C) => C.value === k), U = E.findIndex((C) => C.value === M);
28
- return Q - U;
26
+ d == null || d(i.filter((k) => z.includes(k)).sort((k, Y) => {
27
+ const Z = E.findIndex((C) => C.value === k), P = E.findIndex((C) => C.value === Y);
28
+ return Z - P;
29
29
  }));
30
- }, g = B("checkbox", m), h = `${g}-group`, [z, F] = ae(g), H = ee(t, ["value", "disabled"]);
30
+ }, g = j("checkbox", m), h = `${g}-group`, [L, M] = ie(g), Q = ne(t, ["value", "disabled"]);
31
31
  a && a.length > 0 && (o = I().map((e) => r.createElement(w, { prefixCls: g, key: e.value.toString(), danger: "danger" in e ? e.danger : t.danger, disabled: "disabled" in e ? e.disabled : t.disabled, value: e.value, checked: s.includes(e.value), onChange: e.onChange, className: `${h}-item`, style: e.style }, e.label)));
32
- const J = {
33
- toggleOption: q,
32
+ const U = {
33
+ toggleOption: J,
34
34
  value: s,
35
35
  disabled: t.disabled,
36
36
  name: t.name,
37
37
  // https://github.com/ant-design/ant-design/issues/16376
38
- registerValue: j,
39
- cancelValue: W
40
- }, L = O(h, {
41
- [`${h}-rtl`]: D === "rtl"
42
- }, l, u, F);
43
- return z(r.createElement(
38
+ registerValue: H,
39
+ cancelValue: F
40
+ }, X = O(h, {
41
+ [`${h}-rtl`]: q === "rtl"
42
+ }, l, u, M);
43
+ return L(r.createElement(
44
44
  "div",
45
- { className: L, style: n, ...H, ref: A },
45
+ { className: X, style: n, ...Q, ref: W },
46
46
  r.createElement(
47
47
  R.Provider,
48
- { value: J },
49
- r.createElement(te, { label: x, helper: $, disabled: t.disabled, bordered: t.bordered, status: b, className: f }, o)
48
+ { value: U },
49
+ r.createElement(ue, { label: x, helper: $, disabled: t.disabled, bordered: t.bordered, status: b, className: f, required: A, infoIcon: B, actions: D, onInfoClick: T }, o)
50
50
  )
51
51
  ));
52
- }, ce = Y(S(ne)), ie = ce, ue = {
52
+ }, re = ee(S(de)), oe = re, se = {
53
53
  "kit-checkbox": "_kit-checkbox_bsyc5_2"
54
54
  }, w = S(({ danger: v, className: o, ...a }, m) => {
55
- const l = N(R), { appId: f } = p(), b = (l == null ? void 0 : l.disabled) || a.disabled, u = Z(a.value);
55
+ const l = N(R), { appId: f } = te(), b = (l == null ? void 0 : l.disabled) || a.disabled, u = le(a.value);
56
56
  V(() => {
57
57
  l == null || l.registerValue(a.value);
58
58
  }, []), V(() => {
@@ -63,13 +63,13 @@ const R = X(null), ne = ({ defaultValue: v, children: o, options: a = [], prefix
63
63
  l && !a.skipGroup && (n.onChange = (...x) => {
64
64
  a.onChange && a.onChange(...x), l.toggleOption && l.toggleOption({ label: a.children, value: a.value });
65
65
  }, n.name = l.name, n.checked = l.value.includes(a.value));
66
- const d = O(f, ue["kit-checkbox"], o, {
66
+ const d = O(f, se["kit-checkbox"], o, {
67
67
  "ant-checkbox-wrapper-danger": v
68
68
  });
69
- return r.createElement(P, { ...n, ref: m, disabled: b, className: d });
69
+ return r.createElement(ae, { ...n, ref: m, disabled: b, className: d });
70
70
  }), _ = w;
71
71
  _.displayName = "KitCheckbox";
72
- _.Group = ie;
72
+ _.Group = oe;
73
73
  export {
74
74
  _ as KitCheckbox
75
75
  };
@@ -1,3 +1,3 @@
1
- import { FC } from 'react';
1
+ import { FunctionComponent } from 'react';
2
2
  import { KitColorPickerProps } from './types';
3
- export declare const KitColorPicker: FC<KitColorPickerProps>;
3
+ export declare const KitColorPicker: FunctionComponent<KitColorPickerProps>;
@@ -1,20 +1,20 @@
1
1
  import "../../../assets/index11.css";
2
2
  import t from "react";
3
- import { K as p } from "../../../chunks/InputWrapper.sHItZx7l.js";
4
- import { u as n } from "../../../chunks/useKitTheme.KSAU-Pdv.js";
5
- import { ColorPicker as k } from "antd";
3
+ import { K as f } from "../../../chunks/InputWrapper.69dUKMaK.js";
4
+ import { u as C } from "../../../chunks/useKitTheme.KSAU-Pdv.js";
5
+ import { ColorPicker as K } from "antd";
6
6
  import e from "classnames";
7
- const d = {
7
+ const u = {
8
8
  "kit-colorpicker": "_kit-colorpicker_6l8nk_2"
9
- }, f = ({ label: i, className: c, helper: m, rootClassName: l, ...o }) => {
10
- const { appId: r } = n(), s = e(r, d["kit-colorpicker"], l), a = e(r, c);
9
+ }, x = ({ label: i, className: c, helper: m, rootClassName: l, required: s, infoIcon: a, actions: p, onInfoClick: n, ...o }) => {
10
+ const { appId: r } = C(), k = e(r, u["kit-colorpicker"], l), d = e(r, c);
11
11
  return t.createElement(
12
- p,
13
- { label: i, helper: m, disabled: o.disabled },
14
- t.createElement(k, { ...o, rootClassName: s, className: a })
12
+ f,
13
+ { label: i, helper: m, disabled: o.disabled, required: s, infoIcon: a, actions: p, onInfoClick: n },
14
+ t.createElement(K, { ...o, rootClassName: k, className: d })
15
15
  );
16
16
  };
17
- f.displayName = "KitColorPicker";
17
+ x.displayName = "KitColorPicker";
18
18
  export {
19
- f as KitColorPicker
19
+ x as KitColorPicker
20
20
  };
@@ -1,7 +1,7 @@
1
1
  import React from 'react';
2
- declare const KitDatePicker: React.ForwardRefExoticComponent<Omit<import("rc-picker").RangePickerProps<import("dayjs").Dayjs>, "locale" | "generateConfig" | "hideHeader"> & {
3
- locale?: import("antd/lib/date-picker/generatePicker").PickerLocale | undefined;
4
- size?: import("antd/lib/button").ButtonSize;
2
+ declare const KitRangePicker: React.ForwardRefExoticComponent<Omit<import("rc-picker").RangePickerProps<import("dayjs").Dayjs>, "locale" | "generateConfig" | "hideHeader"> & {
3
+ locale?: import("antd/es/date-picker/generatePicker").PickerLocale | undefined;
4
+ size?: import("antd/es/button").ButtonSize;
5
5
  placement?: "topLeft" | "topRight" | "bottomLeft" | "bottomRight" | undefined;
6
6
  bordered?: boolean | undefined;
7
7
  status?: "" | "error" | "warning" | undefined;
@@ -11,4 +11,4 @@ declare const KitDatePicker: React.ForwardRefExoticComponent<Omit<import("rc-pic
11
11
  rootClassName?: string | undefined;
12
12
  popupStyle?: React.CSSProperties | undefined;
13
13
  } & import("./types").IInternalRangerPicker & React.RefAttributes<any>>;
14
- export default KitDatePicker;
14
+ export default KitRangePicker;
@@ -1,41 +1,39 @@
1
1
  import "../../../assets/index22.css";
2
- import e, { forwardRef as k } from "react";
3
- import { DatePicker as E } from "antd";
4
- import { K as I } from "../../../chunks/InputWrapper.sHItZx7l.js";
5
- import { u as _ } from "../../../chunks/useKitTheme.KSAU-Pdv.js";
2
+ import { faCircleXmark as _, faClock as I, faCalendar as K } from "@fortawesome/free-regular-svg-icons";
6
3
  import { FontAwesomeIcon as a } from "@fortawesome/react-fontawesome";
7
- import { faCircleXmark as b, faClock as v, faCalendar as x } from "@fortawesome/free-regular-svg-icons";
8
- import K from "classnames";
9
- const D = {
10
- "kit-datepicker": "_kit-datepicker_7610n_2",
11
- "kit-rangepicker": "_kit-rangepicker_7610n_117"
12
- }, C = k(({ label: o, helper: s, suffixIcon: m, className: d, wrapperClassName: c, picker: l = "date", allowClear: t = !0, ...n }, i) => {
13
- var r;
14
- const { appId: f } = _(), u = () => l === "time" ? e.createElement(a, { icon: v }) : e.createElement(a, { icon: x }), p = K(f, D["kit-datepicker"], d);
4
+ import { K as R } from "../../../chunks/InputWrapper.69dUKMaK.js";
5
+ import { u as v } from "../../../chunks/useKitTheme.KSAU-Pdv.js";
6
+ import { DatePicker as C } from "antd";
7
+ import D from "classnames";
8
+ import e, { forwardRef as g } from "react";
9
+ const w = {
10
+ "kit-datepicker": "_kit-datepicker_n1csk_2",
11
+ "kit-rangepicker": "_kit-rangepicker_n1csk_117"
12
+ }, x = g(({ label: o, helper: s, suffixIcon: l, className: r, wrapperClassName: i, picker: c = "date", allowClear: m = !0, required: d, infoIcon: u, actions: f, onInfoClick: t, ...n }, k) => {
13
+ const { appId: p } = v(), b = () => c === "time" ? e.createElement(a, { icon: I }) : e.createElement(a, { icon: K }), E = D(p, w["kit-datepicker"], r);
15
14
  return e.createElement(
16
- I,
17
- { label: o, helper: s, disabled: n.disabled, status: n.status, className: c },
15
+ R,
16
+ { label: o, helper: s, disabled: n.disabled, status: n.status, className: i, required: d, infoIcon: u, actions: f, onInfoClick: t },
18
17
  e.createElement(
19
18
  "div",
20
19
  null,
21
- e.createElement(E, { ...n, picker: l, ref: i, suffixIcon: (r = m) !== null && r !== void 0 ? r : u(), allowClear: t ? { clearIcon: e.createElement(a, { icon: b }) } : !1, className: p })
20
+ e.createElement(C, { ...n, picker: c, ref: k, suffixIcon: l ?? b(), allowClear: m ? { clearIcon: e.createElement(a, { "aria-label": "clear", icon: _ }) } : !1, className: E })
22
21
  )
23
22
  );
24
- }), w = k(({ label: o, className: s, helper: m, suffixIcon: d, picker: c, allowClear: l = !0, ...t }, n) => {
25
- var i;
26
- const { appId: r } = _(), f = () => c === "time" ? e.createElement(a, { icon: v }) : e.createElement(a, { icon: x }), u = () => t.disabled === void 0 ? !1 : typeof t.disabled == "boolean" ? t.disabled : t.disabled[0] && t.disabled[1], p = K(r, D["kit-rangepicker"], s);
23
+ }), y = g(({ label: o, className: s, helper: l, suffixIcon: r, picker: i, allowClear: c = !0, required: m, infoIcon: d, actions: u, onInfoClick: f, ...t }, n) => {
24
+ const { appId: k } = v(), p = () => i === "time" ? e.createElement(a, { icon: I }) : e.createElement(a, { icon: K }), b = () => t.disabled === void 0 ? !1 : typeof t.disabled == "boolean" ? t.disabled : t.disabled[0] && t.disabled[1], E = D(k, w["kit-rangepicker"], s);
27
25
  return e.createElement(
28
- I,
29
- { label: o, helper: m, disabled: u(), status: t.status },
26
+ R,
27
+ { label: o, helper: l, disabled: b(), status: t.status, required: m, infoIcon: d, actions: u, onInfoClick: f },
30
28
  e.createElement(
31
29
  "div",
32
30
  null,
33
- e.createElement(E.RangePicker, { ...t, picker: c, ref: n, suffixIcon: (i = d) !== null && i !== void 0 ? i : f(), allowClear: l ? { clearIcon: e.createElement(a, { icon: b }) } : !1, className: p })
31
+ e.createElement(C.RangePicker, { ...t, picker: i, ref: n, suffixIcon: r ?? p(), allowClear: c ? { clearIcon: e.createElement(a, { "aria-label": "clear", icon: _ }) } : !1, className: E })
34
32
  )
35
33
  );
36
- }), N = w, R = C;
37
- R.displayName = "KitDatePicker";
38
- R.RangePicker = N;
34
+ }), S = y, N = x;
35
+ N.displayName = "KitDatePicker";
36
+ N.RangePicker = S;
39
37
  export {
40
- R as KitDatePicker
38
+ N as KitDatePicker
41
39
  };
@@ -1,40 +1,40 @@
1
1
  import "../../../assets/index25.css";
2
- import t, { forwardRef as d } from "react";
3
- import { Input as u } from "antd";
4
- import { K as p } from "../../../chunks/InputWrapper.sHItZx7l.js";
5
- import { u as I } from "../../../chunks/useKitTheme.KSAU-Pdv.js";
6
- import { FontAwesomeIcon as m } from "@fortawesome/react-fontawesome";
7
- import { faCircleXmark as f, faEye as N, faEyeSlash as b } from "@fortawesome/free-regular-svg-icons";
8
- import E from "classnames";
9
- const k = {
10
- "kit-input": "_kit-input_15u8a_2",
11
- "kit-password": "_kit-password_15u8a_140",
12
- "kit-textarea": "_kit-textarea_15u8a_264"
13
- }, T = d(({ label: s, className: n, helper: c, wrapperClassName: a, allowClear: o = !0, ...e }, r) => {
14
- const { appId: l } = I(), i = E(l, k["kit-input"], n);
15
- return t.createElement(
16
- p,
17
- { label: s, helper: c, disabled: e.disabled, status: e.status, className: a },
18
- t.createElement(u, { ...e, ref: r, className: i, allowClear: o ? { clearIcon: t.createElement(m, { icon: f }) } : void 0 })
2
+ import e, { forwardRef as f } from "react";
3
+ import { Input as E } from "antd";
4
+ import { faCircleXmark as k, faEye as y, faEyeSlash as C } from "@fortawesome/free-regular-svg-icons";
5
+ import { FontAwesomeIcon as I } from "@fortawesome/react-fontawesome";
6
+ import { K as w } from "../../../chunks/InputWrapper.69dUKMaK.js";
7
+ import { u as _ } from "../../../chunks/useKitTheme.KSAU-Pdv.js";
8
+ import b from "classnames";
9
+ const x = {
10
+ "kit-input": "_kit-input_12a1a_2",
11
+ "kit-password": "_kit-password_12a1a_140",
12
+ "kit-textarea": "_kit-textarea_12a1a_264"
13
+ }, A = f(({ label: s, className: l, helper: c, wrapperClassName: a, allowClear: n = !0, required: o, infoIcon: i, actions: m, onInfoClick: d, ...t }, r) => {
14
+ const { appId: u } = _(), p = b(u, x["kit-input"], l);
15
+ return e.createElement(
16
+ w,
17
+ { label: s, helper: c, disabled: t.disabled, status: t.status, className: a, required: o, infoIcon: i, actions: m, onInfoClick: d },
18
+ e.createElement(E, { ...t, ref: r, className: p, allowClear: n ? { clearIcon: e.createElement(I, { "aria-label": "clear", icon: k }) } : void 0 })
19
19
  );
20
- }), v = d(({ label: s, className: n, helper: c, wrapperClassName: a, allowClear: o = !0, ...e }, r) => {
21
- const { appId: l } = I(), i = E(l, k["kit-textarea"], n);
22
- return t.createElement(
23
- p,
24
- { label: s, helper: c, disabled: e.disabled, status: e.status, className: a },
25
- t.createElement(u.TextArea, { ...e, ref: r, allowClear: o ? { clearIcon: t.createElement(m, { icon: f }) } : void 0, className: i })
20
+ }), h = f(({ label: s, className: l, helper: c, wrapperClassName: a, allowClear: n = !0, required: o, infoIcon: i, actions: m, onInfoClick: d, ...t }, r) => {
21
+ const { appId: u } = _(), p = b(u, x["kit-textarea"], l);
22
+ return e.createElement(
23
+ w,
24
+ { label: s, helper: c, disabled: t.disabled, status: t.status, className: a, required: o, infoIcon: i, actions: m, onInfoClick: d },
25
+ e.createElement(E.TextArea, { ...t, ref: r, allowClear: n ? { clearIcon: e.createElement(I, { "aria-label": "clear", icon: k }) } : void 0, className: p })
26
26
  );
27
- }), y = v, C = d(({ label: s, className: n, helper: c, iconRender: a, wrapperClassName: o, allowClear: e = !0, ...r }, l) => {
28
- const { appId: i } = I(), _ = E(i, k["kit-password"], n), x = (K) => K ? t.createElement(m, { icon: N }) : t.createElement(m, { icon: b });
29
- return t.createElement(
30
- p,
31
- { label: s, helper: c, disabled: r.disabled, status: r.status, className: o },
32
- t.createElement(u.Password, { ...r, className: _, ref: l, allowClear: e ? { clearIcon: t.createElement(m, { icon: f }) } : void 0, iconRender: a ?? x })
27
+ }), R = h, g = f(({ label: s, className: l, helper: c, iconRender: a, wrapperClassName: n, allowClear: o = !0, required: i, infoIcon: m, actions: d, onInfoClick: t, ...r }, u) => {
28
+ const { appId: p } = _(), N = b(p, x["kit-password"], l), T = (v) => v ? e.createElement(I, { icon: y }) : e.createElement(I, { icon: C });
29
+ return e.createElement(
30
+ w,
31
+ { label: s, helper: c, disabled: r.disabled, status: r.status, className: n, required: i, infoIcon: m, actions: d, onInfoClick: t },
32
+ e.createElement(E.Password, { ...r, className: N, ref: u, allowClear: o ? { clearIcon: e.createElement(I, { "aria-label": "clear", icon: k }) } : void 0, iconRender: a ?? T })
33
33
  );
34
- }), A = C, w = T;
35
- w.displayName = "KitInput";
36
- w.TextArea = y;
37
- w.Password = A;
34
+ }), F = g, K = A;
35
+ K.displayName = "KitInput";
36
+ K.TextArea = R;
37
+ K.Password = F;
38
38
  export {
39
- w as KitInput
39
+ K as KitInput
40
40
  };
@@ -1,22 +1,22 @@
1
1
  import "../../../assets/index6.css";
2
- import s, { forwardRef as c, useState as f } from "react";
3
- import { InputNumber as l } from "antd";
4
- import { K as d } from "../../../chunks/InputWrapper.sHItZx7l.js";
5
- import { u as b } from "../../../chunks/useKitTheme.KSAU-Pdv.js";
6
- import I from "classnames";
7
- const K = {
2
+ import s, { forwardRef as b, useState as I } from "react";
3
+ import { InputNumber as K } from "antd";
4
+ import { K as k } from "../../../chunks/InputWrapper.69dUKMaK.js";
5
+ import { u as N } from "../../../chunks/useKitTheme.KSAU-Pdv.js";
6
+ import x from "classnames";
7
+ const F = {
8
8
  "kit-input-number": "_kit-input-number_nszsj_2"
9
- }, k = c(({ label: r, helper: a, wrapperClassName: u, className: m, ...t }, n) => {
10
- const { appId: o } = b(), [i, e] = f(!1), p = I(o, K["kit-input-number"], m, {
11
- "kit-input-number-affix-wrapper-focused": i
9
+ }, _ = b(({ label: r, helper: a, wrapperClassName: u, className: m, required: n, infoIcon: o, actions: i, onInfoClick: p, ...t }, c) => {
10
+ const { appId: f } = N(), [l, e] = I(!1), d = x(f, F["kit-input-number"], m, {
11
+ "kit-input-number-affix-wrapper-focused": l
12
12
  });
13
13
  return s.createElement(
14
- d,
15
- { label: r, helper: a, disabled: t.disabled, status: t.status, className: u },
16
- s.createElement(l, { ref: n, onFocus: () => e(!0), onBlur: () => e(!1), className: p, ...t })
14
+ k,
15
+ { label: r, helper: a, disabled: t.disabled, status: t.status, className: u, required: n, infoIcon: o, actions: i, onInfoClick: p },
16
+ s.createElement(K, { ref: c, onFocus: () => e(!0), onBlur: () => e(!1), className: d, ...t })
17
17
  );
18
18
  });
19
- k.displayName = "KitInputNumber";
19
+ _.displayName = "KitInputNumber";
20
20
  export {
21
- k as KitInputNumber
21
+ _ as KitInputNumber
22
22
  };