@hitachivantara/uikit-react-core 5.15.0 → 5.16.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 (42) hide show
  1. package/dist/cjs/components/ActionBar/ActionBar.cjs +8 -7
  2. package/dist/cjs/components/ActionBar/ActionBar.cjs.map +1 -1
  3. package/dist/cjs/components/ActionBar/ActionBar.styles.cjs +16 -17
  4. package/dist/cjs/components/ActionBar/ActionBar.styles.cjs.map +1 -1
  5. package/dist/cjs/components/TimePicker/Placeholder.cjs +70 -0
  6. package/dist/cjs/components/TimePicker/Placeholder.cjs.map +1 -0
  7. package/dist/cjs/components/TimePicker/TimePicker.cjs +222 -0
  8. package/dist/cjs/components/TimePicker/TimePicker.cjs.map +1 -0
  9. package/dist/cjs/components/TimePicker/TimePicker.styles.cjs +53 -0
  10. package/dist/cjs/components/TimePicker/TimePicker.styles.cjs.map +1 -0
  11. package/dist/cjs/components/TimePicker/Unit/Unit.cjs +72 -0
  12. package/dist/cjs/components/TimePicker/Unit/Unit.cjs.map +1 -0
  13. package/dist/cjs/components/TimePicker/Unit/Unit.styles.cjs +56 -0
  14. package/dist/cjs/components/TimePicker/Unit/Unit.styles.cjs.map +1 -0
  15. package/dist/cjs/index.cjs +6 -2
  16. package/dist/cjs/index.cjs.map +1 -1
  17. package/dist/cjs/utils/classes.cjs +4 -3
  18. package/dist/cjs/utils/classes.cjs.map +1 -1
  19. package/dist/esm/components/ActionBar/ActionBar.js +11 -9
  20. package/dist/esm/components/ActionBar/ActionBar.js.map +1 -1
  21. package/dist/esm/components/ActionBar/ActionBar.styles.js +16 -15
  22. package/dist/esm/components/ActionBar/ActionBar.styles.js.map +1 -1
  23. package/dist/esm/components/TimePicker/Placeholder.js +70 -0
  24. package/dist/esm/components/TimePicker/Placeholder.js.map +1 -0
  25. package/dist/esm/components/TimePicker/TimePicker.js +223 -0
  26. package/dist/esm/components/TimePicker/TimePicker.js.map +1 -0
  27. package/dist/esm/components/TimePicker/TimePicker.styles.js +53 -0
  28. package/dist/esm/components/TimePicker/TimePicker.styles.js.map +1 -0
  29. package/dist/esm/components/TimePicker/Unit/Unit.js +72 -0
  30. package/dist/esm/components/TimePicker/Unit/Unit.js.map +1 -0
  31. package/dist/esm/components/TimePicker/Unit/Unit.styles.js +56 -0
  32. package/dist/esm/components/TimePicker/Unit/Unit.styles.js.map +1 -0
  33. package/dist/esm/index.js +238 -234
  34. package/dist/esm/index.js.map +1 -1
  35. package/dist/esm/utils/classes.js +4 -3
  36. package/dist/esm/utils/classes.js.map +1 -1
  37. package/dist/types/index.d.ts +134 -13
  38. package/package.json +5 -5
  39. package/dist/cjs/components/ActionBar/actionBarClasses.cjs +0 -8
  40. package/dist/cjs/components/ActionBar/actionBarClasses.cjs.map +0 -1
  41. package/dist/esm/components/ActionBar/actionBarClasses.js +0 -8
  42. package/dist/esm/components/ActionBar/actionBarClasses.js.map +0 -1
@@ -1,23 +1,24 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
- const clsx = require("clsx");
4
3
  const ActionBar_styles = require("./ActionBar.styles.cjs");
5
- const actionBarClasses = require("./actionBarClasses.cjs");
6
4
  const jsxRuntime = require("@emotion/react/jsx-runtime");
7
5
  const HvActionBar = (props) => {
8
6
  const {
9
- classes,
7
+ classes: classesProp,
10
8
  className,
11
- id,
12
9
  children,
13
10
  ...others
14
11
  } = props;
15
- return /* @__PURE__ */ jsxRuntime.jsx(ActionBar_styles.StyledRoot, {
16
- id,
17
- className: clsx.clsx(actionBarClasses.default.root, classes == null ? void 0 : classes.root, className),
12
+ const {
13
+ classes,
14
+ cx
15
+ } = ActionBar_styles.useClasses(classesProp);
16
+ return /* @__PURE__ */ jsxRuntime.jsx("div", {
17
+ className: cx(classes.root, className),
18
18
  ...others,
19
19
  children
20
20
  });
21
21
  };
22
+ exports.actionBarClasses = ActionBar_styles.staticClasses;
22
23
  exports.HvActionBar = HvActionBar;
23
24
  //# sourceMappingURL=ActionBar.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"ActionBar.cjs","sources":["../../../../src/components/ActionBar/ActionBar.tsx"],"sourcesContent":["import { clsx } from \"clsx\";\nimport { HvBaseProps } from \"@core/types\";\nimport { StyledRoot } from \"./ActionBar.styles\";\nimport actionBarClasses, { HvActionBarClasses } from \"./actionBarClasses\";\n\nexport interface HvActionBarProps extends HvBaseProps {\n /** A Jss Object used to override or extend the styles applied to the component. */\n classes?: HvActionBarClasses;\n}\n\nexport const HvActionBar = (props: HvActionBarProps) => {\n const { classes, className, id, children, ...others } = props;\n\n return (\n <StyledRoot\n id={id}\n className={clsx(actionBarClasses.root, classes?.root, className)}\n {...others}\n >\n {children}\n </StyledRoot>\n );\n};\n"],"names":["HvActionBar","props","classes","className","id","children","others","StyledRoot","clsx","actionBarClasses","root"],"mappings":";;;;;;AAUaA,MAAAA,cAAcA,CAACC,UAA4B;AAChD,QAAA;AAAA,IAAEC;AAAAA,IAASC;AAAAA,IAAWC;AAAAA,IAAIC;AAAAA,IAAU,GAAGC;AAAAA,EAAWL,IAAAA;AAExD,wCACGM,iBAAAA,YAAU;AAAA,IACTH;AAAAA,IACAD,WAAWK,KAAKC,KAAAA,iBAAAA,QAAiBC,MAAMR,mCAASQ,MAAMP,SAAS;AAAA,IAAE,GAC7DG;AAAAA,IAAMD;AAAAA,EAAAA,CAGA;AAEhB;;"}
1
+ {"version":3,"file":"ActionBar.cjs","sources":["../../../../src/components/ActionBar/ActionBar.tsx"],"sourcesContent":["import { HvBaseProps } from \"@core/types\";\nimport { ExtractNames } from \"@core/utils\";\nimport { staticClasses, useClasses } from \"./ActionBar.styles\";\n\nexport { staticClasses as actionBarClasses };\n\nexport type HvActionBarClasses = ExtractNames<typeof useClasses>;\n\nexport interface HvActionBarProps extends HvBaseProps {\n /** A Jss Object used to override or extend the styles applied to the component. */\n classes?: Partial<HvActionBarClasses>;\n}\n\nexport const HvActionBar = (props: HvActionBarProps) => {\n const { classes: classesProp, className, children, ...others } = props;\n const { classes, cx } = useClasses(classesProp);\n\n return (\n <div className={cx(classes.root, className)} {...others}>\n {children}\n </div>\n );\n};\n"],"names":["HvActionBar","props","classes","classesProp","className","children","others","cx","useClasses","root"],"mappings":";;;;AAaaA,MAAAA,cAAcA,CAACC,UAA4B;AAChD,QAAA;AAAA,IAAEC,SAASC;AAAAA,IAAaC;AAAAA,IAAWC;AAAAA,IAAU,GAAGC;AAAAA,EAAWL,IAAAA;AAC3D,QAAA;AAAA,IAAEC;AAAAA,IAASK;AAAAA,EAAAA,IAAOC,iBAAAA,WAAWL,WAAW;AAE9C,wCACE,OAAA;AAAA,IAAKC,WAAWG,GAAGL,QAAQO,MAAML,SAAS;AAAA,IAAE,GAAKE;AAAAA,IAAMD;AAAAA,EAAAA,CAElD;AAET;;;"}
@@ -1,21 +1,20 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
- const _styled = require("@emotion/styled/base");
4
3
  const uikitStyles = require("@hitachivantara/uikit-styles");
5
- const _interopDefault = (e) => e && e.__esModule ? e : { default: e };
6
- const _styled__default = /* @__PURE__ */ _interopDefault(_styled);
7
- const StyledRoot = /* @__PURE__ */ _styled__default.default("div", process.env.NODE_ENV === "production" ? {
8
- target: "eae5m590"
9
- } : {
10
- target: "eae5m590",
11
- label: "StyledRoot"
12
- })({
13
- width: "100%",
14
- height: "75px",
15
- padding: uikitStyles.theme.space.sm,
16
- borderTop: `3px solid ${uikitStyles.theme.colors.atmo2}`,
17
- display: "flex",
18
- justifyContent: "flex-end"
19
- }, process.env.NODE_ENV === "production" ? "" : "/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi9ob21lL3J1bm5lci93b3JrL2h2LXVpa2l0LXJlYWN0L2h2LXVpa2l0LXJlYWN0L3BhY2thZ2VzL2NvcmUvc3JjL2NvbXBvbmVudHMvQWN0aW9uQmFyL0FjdGlvbkJhci5zdHlsZXMudHN4Il0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUcwQiIsImZpbGUiOiIvaG9tZS9ydW5uZXIvd29yay9odi11aWtpdC1yZWFjdC9odi11aWtpdC1yZWFjdC9wYWNrYWdlcy9jb3JlL3NyYy9jb21wb25lbnRzL0FjdGlvbkJhci9BY3Rpb25CYXIuc3R5bGVzLnRzeCIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCBzdHlsZWQgZnJvbSBcIkBlbW90aW9uL3N0eWxlZFwiO1xuaW1wb3J0IHsgdGhlbWUgfSBmcm9tIFwiQGhpdGFjaGl2YW50YXJhL3Vpa2l0LXN0eWxlc1wiO1xuXG5leHBvcnQgY29uc3QgU3R5bGVkUm9vdCA9IHN0eWxlZChcImRpdlwiKSh7XG4gIHdpZHRoOiBcIjEwMCVcIixcbiAgaGVpZ2h0OiBcIjc1cHhcIixcbiAgcGFkZGluZzogdGhlbWUuc3BhY2Uuc20sXG4gIGJvcmRlclRvcDogYDNweCBzb2xpZCAke3RoZW1lLmNvbG9ycy5hdG1vMn1gLFxuICBkaXNwbGF5OiBcImZsZXhcIixcbiAganVzdGlmeUNvbnRlbnQ6IFwiZmxleC1lbmRcIixcbn0pO1xuIl19 */");
20
- exports.StyledRoot = StyledRoot;
4
+ const classes = require("../../utils/classes.cjs");
5
+ const {
6
+ staticClasses,
7
+ useClasses
8
+ } = classes.createClasses("HvActionBar", {
9
+ root: {
10
+ width: "100%",
11
+ padding: uikitStyles.theme.space.sm,
12
+ borderTop: uikitStyles.theme.actionBar.borderTop,
13
+ display: "flex",
14
+ alignItems: "center",
15
+ justifyContent: "flex-end"
16
+ }
17
+ });
18
+ exports.staticClasses = staticClasses;
19
+ exports.useClasses = useClasses;
21
20
  //# sourceMappingURL=ActionBar.styles.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"ActionBar.styles.cjs","sources":["../../../../src/components/ActionBar/ActionBar.styles.tsx"],"sourcesContent":["import styled from \"@emotion/styled\";\nimport { theme } from \"@hitachivantara/uikit-styles\";\n\nexport const StyledRoot = styled(\"div\")({\n width: \"100%\",\n height: \"75px\",\n padding: theme.space.sm,\n borderTop: `3px solid ${theme.colors.atmo2}`,\n display: \"flex\",\n justifyContent: \"flex-end\",\n});\n"],"names":["StyledRoot","_styled","process","env","NODE_ENV","target","label","width","height","padding","theme","space","sm","borderTop","colors","atmo2","display","justifyContent"],"mappings":";;;;;;AAGO,MAAMA,aAAoBC,iCAAA,QAAA,OAAKC,QAAAC,IAAAC,aAAA,eAAA;AAAA,EAAAC,QAAA;AAAA,IAAA;AAAA,EAAAA,QAAA;AAAA,EAAAC,OAAA;AAAA,CAAA,EAAE;AAAA,EACtCC,OAAO;AAAA,EACPC,QAAQ;AAAA,EACRC,SAASC,YAAAA,MAAMC,MAAMC;AAAAA,EACrBC,WAAY,aAAYH,YAAAA,MAAMI,OAAOC;AAAAA,EACrCC,SAAS;AAAA,EACTC,gBAAgB;AAClB,GAACf,QAAAC,IAAAC,aAAC,eAAA,KAAA,y4BAAA;;"}
1
+ {"version":3,"file":"ActionBar.styles.cjs","sources":["../../../../src/components/ActionBar/ActionBar.styles.tsx"],"sourcesContent":["import { createClasses } from \"@core/utils\";\nimport { theme } from \"@hitachivantara/uikit-styles\";\n\nexport const { staticClasses, useClasses } = createClasses(\"HvActionBar\", {\n root: {\n width: \"100%\",\n padding: theme.space.sm,\n borderTop: theme.actionBar.borderTop,\n display: \"flex\",\n alignItems: \"center\",\n justifyContent: \"flex-end\",\n },\n});\n"],"names":["staticClasses","useClasses","createClasses","root","width","padding","theme","space","sm","borderTop","actionBar","display","alignItems","justifyContent"],"mappings":";;;;AAGa,MAAA;AAAA,EAAEA;AAAAA,EAAeC;AAAW,IAAIC,QAAAA,cAAc,eAAe;AAAA,EACxEC,MAAM;AAAA,IACJC,OAAO;AAAA,IACPC,SAASC,YAAAA,MAAMC,MAAMC;AAAAA,IACrBC,WAAWH,YAAAA,MAAMI,UAAUD;AAAAA,IAC3BE,SAAS;AAAA,IACTC,YAAY;AAAA,IACZC,gBAAgB;AAAA,EAClB;AACF,CAAC;;;"}
@@ -0,0 +1,70 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
+ const React = require("react");
4
+ const datepicker = require("@react-aria/datepicker");
5
+ const jsxRuntime = require("@emotion/react/jsx-runtime");
6
+ const getDateValue = (date) => {
7
+ if (!date)
8
+ return "";
9
+ const {
10
+ hour,
11
+ minute,
12
+ second
13
+ } = date;
14
+ return [hour, minute, second].map((el) => String(el).padStart(2, "0")).join(":");
15
+ };
16
+ const PlaceholderSegment = ({
17
+ segment,
18
+ state,
19
+ placeholder
20
+ }) => {
21
+ const ref = React.useRef(null);
22
+ const {
23
+ segmentProps
24
+ } = datepicker.useDateSegment(segment, state, ref);
25
+ return /* @__PURE__ */ jsxRuntime.jsx("div", {
26
+ ref,
27
+ ...segmentProps,
28
+ children: (() => {
29
+ if (segment.type === "literal")
30
+ return segment.text;
31
+ if (segment.isPlaceholder)
32
+ return placeholder ?? segment.text;
33
+ return segment.text.padStart(2, "0");
34
+ })()
35
+ });
36
+ };
37
+ const Placeholder = React.forwardRef((props, ref) => {
38
+ const {
39
+ name,
40
+ state,
41
+ placeholders,
42
+ onKeyDown,
43
+ ...others
44
+ } = props;
45
+ const {
46
+ value,
47
+ segments
48
+ } = state;
49
+ return /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, {
50
+ children: /* @__PURE__ */ jsxRuntime.jsxs("div", {
51
+ ref,
52
+ onKeyDown: (event) => {
53
+ event.stopPropagation();
54
+ onKeyDown == null ? void 0 : onKeyDown(event);
55
+ },
56
+ ...others,
57
+ children: [name && /* @__PURE__ */ jsxRuntime.jsx("input", {
58
+ type: "hidden",
59
+ name,
60
+ value: getDateValue(value)
61
+ }), segments.map((segment, i) => /* @__PURE__ */ jsxRuntime.jsx(PlaceholderSegment, {
62
+ segment,
63
+ state,
64
+ placeholder: placeholders[segment.type]
65
+ }, i))]
66
+ })
67
+ });
68
+ });
69
+ exports.Placeholder = Placeholder;
70
+ //# sourceMappingURL=Placeholder.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Placeholder.cjs","sources":["../../../../src/components/TimePicker/Placeholder.tsx"],"sourcesContent":["import { forwardRef, useRef } from \"react\";\nimport { DateFieldState, DateSegment } from \"@react-stately/datepicker\";\nimport { useDateSegment } from \"@react-aria/datepicker\";\nimport { HvBaseProps } from \"@core/types\";\n\n/** Convert `Date` into `hh:mm:ss` format */\nconst getDateValue = (date) => {\n if (!date) return \"\";\n const { hour, minute, second } = date;\n\n return [hour, minute, second]\n .map((el) => String(el).padStart(2, \"0\"))\n .join(\":\");\n};\n\nconst PlaceholderSegment = ({\n segment,\n state,\n placeholder,\n}: {\n segment: DateSegment;\n state: DateFieldState;\n placeholder: string;\n}) => {\n const ref = useRef(null);\n const { segmentProps } = useDateSegment(segment, state, ref);\n\n return (\n <div ref={ref} {...segmentProps}>\n {(() => {\n if (segment.type === \"literal\") return segment.text;\n if (segment.isPlaceholder) return placeholder ?? segment.text;\n return segment.text.padStart(2, \"0\");\n })()}\n </div>\n );\n};\n\ninterface PlaceholderProps extends HvBaseProps<HTMLDivElement> {\n name?: string;\n state: DateFieldState;\n placeholders: { hour?: string; minute?: string; second?: string };\n}\n\nexport const Placeholder = forwardRef<HTMLDivElement, PlaceholderProps>(\n (props, ref) => {\n const { name, state, placeholders, onKeyDown, ...others } = props;\n const { value, segments } = state;\n\n return (\n <>\n {/* eslint-disable-next-line jsx-a11y/no-static-element-interactions */}\n <div\n ref={ref}\n onKeyDown={(event) => {\n // stop ArrowDown from opening dropdown\n event.stopPropagation();\n onKeyDown?.(event);\n }}\n {...others}\n >\n {name && (\n <input type=\"hidden\" name={name} value={getDateValue(value)} />\n )}\n {segments.map((segment, i) => (\n <PlaceholderSegment\n key={i}\n segment={segment}\n state={state}\n placeholder={placeholders[segment.type]}\n />\n ))}\n </div>\n </>\n );\n }\n);\n"],"names":["getDateValue","date","hour","minute","second","map","el","String","padStart","join","PlaceholderSegment","segment","state","placeholder","ref","useRef","segmentProps","useDateSegment","children","type","text","isPlaceholder","Placeholder","forwardRef","props","name","placeholders","onKeyDown","others","value","segments","_Fragment","event","stopPropagation","_jsx","i"],"mappings":";;;;;AAMA,MAAMA,eAAgBC,CAAS,SAAA;AAC7B,MAAI,CAACA;AAAa,WAAA;AACZ,QAAA;AAAA,IAAEC;AAAAA,IAAMC;AAAAA,IAAQC;AAAAA,EAAWH,IAAAA;AAEjC,SAAO,CAACC,MAAMC,QAAQC,MAAM,EACzBC,IAAKC,CAAOC,OAAAA,OAAOD,EAAE,EAAEE,SAAS,GAAG,GAAG,CAAC,EACvCC,KAAK,GAAG;AACb;AAEA,MAAMC,qBAAqBA,CAAC;AAAA,EAC1BC;AAAAA,EACAC;AAAAA,EACAC;AAKF,MAAM;AACEC,QAAAA,MAAMC,aAAO,IAAI;AACjB,QAAA;AAAA,IAAEC;AAAAA,EAAiBC,IAAAA,0BAAeN,SAASC,OAAOE,GAAG;AAE3D,wCACE,OAAA;AAAA,IAAKA;AAAAA,IAAS,GAAKE;AAAAA,IAAYE,WAC3B,MAAM;AACN,UAAIP,QAAQQ,SAAS;AAAW,eAAOR,QAAQS;AAC/C,UAAIT,QAAQU;AAAe,eAAOR,eAAeF,QAAQS;AACzD,aAAOT,QAAQS,KAAKZ,SAAS,GAAG,GAAG;AAAA,IAAA,GAClC;AAAA,EAAA,CACA;AAET;AAQO,MAAMc,cAAcC,MAAAA,WACzB,CAACC,OAAOV,QAAQ;AACR,QAAA;AAAA,IAAEW;AAAAA,IAAMb;AAAAA,IAAOc;AAAAA,IAAcC;AAAAA,IAAW,GAAGC;AAAAA,EAAWJ,IAAAA;AACtD,QAAA;AAAA,IAAEK;AAAAA,IAAOC;AAAAA,EAAalB,IAAAA;AAE5B,wCACEmB,WAAAA,UAAA;AAAA,IAAAb,0CAEE,OAAA;AAAA,MACEJ;AAAAA,MACAa,WAAYK,CAAU,UAAA;AAEpBA,cAAMC,gBAAgB;AACtBN,+CAAYK;AAAAA,MACd;AAAA,MAAE,GACEJ;AAAAA,MAAMV,UAAA,CAETO,QACCS,2BAAAA,IAAA,SAAA;AAAA,QAAOf,MAAK;AAAA,QAASM;AAAAA,QAAYI,OAAO7B,aAAa6B,KAAK;AAAA,MAAA,CAAI,GAE/DC,SAASzB,IAAI,CAACM,SAASwB,qCACrBzB,oBAAkB;AAAA,QAEjBC;AAAAA,QACAC;AAAAA,QACAC,aAAaa,aAAaf,QAAQQ,IAAI;AAAA,MAAA,GAHjCgB,CAIN,CACF,CAAC;AAAA,IAAA,CACC;AAAA,EAAA,CACL;AAEN,CACF;;"}
@@ -0,0 +1,222 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
+ const React = require("react");
4
+ const date = require("@internationalized/date");
5
+ const datepicker$1 = require("@react-aria/datepicker");
6
+ const datepicker = require("@react-stately/datepicker");
7
+ const uikitReactIcons = require("@hitachivantara/uikit-react-icons");
8
+ const useCss = require("../../hooks/useCss.cjs");
9
+ require("@hitachivantara/uikit-styles");
10
+ const Placeholder = require("./Placeholder.cjs");
11
+ const TimePicker_styles = require("./TimePicker.styles.cjs");
12
+ const jsxRuntime = require("@emotion/react/jsx-runtime");
13
+ const useUniqueId = require("../../hooks/useUniqueId.cjs");
14
+ const Unit = require("./Unit/Unit.cjs");
15
+ const useControlled = require("../../hooks/useControlled.cjs");
16
+ const setId = require("../../utils/setId.cjs");
17
+ const FormElement = require("../Forms/FormElement/FormElement.cjs");
18
+ const Label = require("../Forms/Label/Label.cjs");
19
+ const InfoMessage = require("../Forms/InfoMessage/InfoMessage.cjs");
20
+ const BaseDropdown = require("../BaseDropdown/BaseDropdown.cjs");
21
+ const WarningText = require("../Forms/WarningText/WarningText.cjs");
22
+ const toTime = (value) => {
23
+ if (!value)
24
+ return void 0;
25
+ const {
26
+ hours,
27
+ minutes,
28
+ seconds
29
+ } = value;
30
+ return new date.Time(hours, minutes, seconds);
31
+ };
32
+ const getFormat = (timeFormat) => {
33
+ if (timeFormat == null)
34
+ return 24;
35
+ return timeFormat === "12" ? 12 : 24;
36
+ };
37
+ const HvTimePicker = (props) => {
38
+ const {
39
+ classes: classesProp = {},
40
+ className,
41
+ id: idProp,
42
+ name,
43
+ required = false,
44
+ disabled = false,
45
+ readOnly = false,
46
+ label,
47
+ "aria-label": ariaLabel,
48
+ "aria-labelledby": ariaLabelledBy,
49
+ description,
50
+ "aria-describedby": ariaDescribedBy,
51
+ status,
52
+ statusMessage,
53
+ "aria-errormessage": ariaErrorMessage,
54
+ placeholder,
55
+ hoursPlaceholder = "hh",
56
+ minutesPlaceholder = "mm",
57
+ secondsPlaceholder = "ss",
58
+ value: valueProp,
59
+ defaultValue: defaultValueProp,
60
+ timeFormat,
61
+ showSeconds,
62
+ disableExpand,
63
+ locale = "en",
64
+ onToggle,
65
+ onChange,
66
+ // misc properties:
67
+ disablePortal = true,
68
+ escapeWithReference = true,
69
+ dropdownProps,
70
+ ...others
71
+ } = props;
72
+ const id = useUniqueId.default(idProp, "hvtimepicker");
73
+ const ref = React.useRef(null);
74
+ const {
75
+ css
76
+ } = useCss.useCss();
77
+ const {
78
+ classes,
79
+ cx
80
+ } = TimePicker_styles.useClasses(classesProp);
81
+ const stateProps = {
82
+ value: toTime(valueProp),
83
+ defaultValue: toTime(defaultValueProp),
84
+ label,
85
+ locale,
86
+ isRequired: required,
87
+ isReadOnly: readOnly,
88
+ isDisabled: disabled,
89
+ granularity: "second",
90
+ hourCycle: getFormat(timeFormat),
91
+ onChange: (value) => {
92
+ const {
93
+ hour: hours,
94
+ minute: minutes,
95
+ second: seconds
96
+ } = value;
97
+ onChange == null ? void 0 : onChange({
98
+ hours,
99
+ minutes,
100
+ seconds
101
+ });
102
+ }
103
+ };
104
+ const state = datepicker.useTimeFieldState(stateProps);
105
+ const {
106
+ labelProps,
107
+ fieldProps
108
+ } = datepicker$1.useTimeField({
109
+ ...stateProps,
110
+ id,
111
+ "aria-label": ariaLabel,
112
+ "aria-labelledby": ariaLabelledBy,
113
+ "aria-describedby": ariaDescribedBy
114
+ }, state, ref);
115
+ const [open, setOpen] = React.useState(false);
116
+ const [validationMessage] = useControlled.useControlled(statusMessage, "Required");
117
+ const [validationState] = useControlled.useControlled(status, "standBy");
118
+ const placeholders = React.useMemo(() => ({
119
+ hour: hoursPlaceholder,
120
+ minute: minutesPlaceholder,
121
+ second: secondsPlaceholder
122
+ }), [hoursPlaceholder, minutesPlaceholder, secondsPlaceholder]);
123
+ const canShowError = ariaErrorMessage == null && (status !== void 0 && statusMessage !== void 0 || status === void 0 && required);
124
+ const is12HrFormat = state.segments[5] != null;
125
+ const isStateInvalid = validationState === "invalid";
126
+ const errorMessageId = isStateInvalid ? canShowError ? setId.setId(id, "error") : ariaErrorMessage : void 0;
127
+ return /* @__PURE__ */ jsxRuntime.jsxs(FormElement.HvFormElement, {
128
+ name,
129
+ required,
130
+ disabled,
131
+ status: validationState,
132
+ className: cx(classes.root, className),
133
+ ...others,
134
+ children: [(label || description) && /* @__PURE__ */ jsxRuntime.jsxs("div", {
135
+ className: classes.labelContainer,
136
+ children: [label && /* @__PURE__ */ jsxRuntime.jsx(Label.HvLabel, {
137
+ label,
138
+ className: classes.label,
139
+ ...labelProps
140
+ }), description && /* @__PURE__ */ jsxRuntime.jsx(InfoMessage.HvInfoMessage, {
141
+ className: classes.description,
142
+ children: description
143
+ })]
144
+ }), /* @__PURE__ */ jsxRuntime.jsx("div", {
145
+ className: css({
146
+ width: is12HrFormat ? 220 : 200
147
+ }),
148
+ children: /* @__PURE__ */ jsxRuntime.jsx(BaseDropdown.HvBaseDropdown, {
149
+ role: "combobox",
150
+ variableWidth: true,
151
+ disabled,
152
+ readOnly,
153
+ placeholder: placeholder && !state.value ? placeholder : /* @__PURE__ */ jsxRuntime.jsx(Placeholder.Placeholder, {
154
+ ref,
155
+ name,
156
+ state,
157
+ placeholders,
158
+ className: cx(classes.placeholder, {
159
+ [classes.placeholderDisabled]: disabled
160
+ }),
161
+ ...fieldProps
162
+ }),
163
+ classes: {
164
+ header: cx(classes.dropdownHeader, {
165
+ [classes.dropdownHeaderInvalid]: isStateInvalid
166
+ }),
167
+ panel: classes.dropdownPanel,
168
+ headerOpen: classes.dropdownHeaderOpen
169
+ },
170
+ placement: "right",
171
+ adornment: /* @__PURE__ */ jsxRuntime.jsx(uikitReactIcons.Time, {
172
+ color: disabled ? "secondary_60" : void 0,
173
+ className: classes.icon
174
+ }),
175
+ expanded: open,
176
+ onToggle: (evt, newOpen) => {
177
+ if (disableExpand)
178
+ return;
179
+ setOpen(newOpen);
180
+ onToggle == null ? void 0 : onToggle(evt, newOpen);
181
+ },
182
+ onContainerCreation: (containerRef) => {
183
+ var _a;
184
+ (_a = containerRef == null ? void 0 : containerRef.getElementsByTagName("input")[0]) == null ? void 0 : _a.focus();
185
+ },
186
+ "aria-haspopup": "dialog",
187
+ "aria-invalid": isStateInvalid ? true : void 0,
188
+ "aria-errormessage": errorMessageId,
189
+ disablePortal,
190
+ popperProps: {
191
+ modifiers: [{
192
+ name: "preventOverflow",
193
+ enabled: escapeWithReference
194
+ }]
195
+ },
196
+ ...dropdownProps,
197
+ children: /* @__PURE__ */ jsxRuntime.jsx("div", {
198
+ ref,
199
+ className: classes.timePopperContainer,
200
+ children: state.segments.map((segment, i) => /* @__PURE__ */ jsxRuntime.jsx(Unit.Unit, {
201
+ state,
202
+ segment,
203
+ placeholder: placeholders[segment.type],
204
+ onAdd: () => state.increment(segment.type),
205
+ onSub: () => state.decrement(segment.type),
206
+ onChange: (evt, val) => {
207
+ state.setSegment(segment.type, Number(val));
208
+ }
209
+ }, i))
210
+ })
211
+ })
212
+ }), canShowError && /* @__PURE__ */ jsxRuntime.jsx(WarningText.HvWarningText, {
213
+ id: setId.setId(id, "error"),
214
+ disableBorder: true,
215
+ className: classes.error,
216
+ children: validationMessage
217
+ })]
218
+ });
219
+ };
220
+ exports.timePickerClasses = TimePicker_styles.staticClasses;
221
+ exports.HvTimePicker = HvTimePicker;
222
+ //# sourceMappingURL=TimePicker.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TimePicker.cjs","sources":["../../../../src/components/TimePicker/TimePicker.tsx"],"sourcesContent":["import { useState, useRef, useMemo } from \"react\";\nimport { Time } from \"@internationalized/date\";\nimport { useTimeField } from \"@react-aria/datepicker\";\nimport {\n TimeFieldStateOptions,\n useTimeFieldState,\n} from \"@react-stately/datepicker\";\n\nimport { Time as TimeIcon } from \"@hitachivantara/uikit-react-icons\";\nimport { useCss } from \"@core/hooks/useCss\";\nimport {\n HvFormElement,\n HvBaseDropdown,\n HvLabel,\n HvWarningText,\n HvInfoMessage,\n HvFormElementProps,\n HvBaseDropdownProps,\n useControlled,\n useUniqueId,\n setId,\n ExtractNames,\n} from \"../..\";\n\nimport { Unit } from \"./Unit\";\nimport { Placeholder } from \"./Placeholder\";\nimport { staticClasses, useClasses } from \"./TimePicker.styles\";\n\nconst toTime = (value?: HvTimePickerValue) => {\n if (!value) return undefined;\n const { hours, minutes, seconds } = value;\n return new Time(hours, minutes, seconds);\n};\n\nconst getFormat = (timeFormat?: TimeFormat) => {\n if (timeFormat == null) return 24;\n return timeFormat === \"12\" ? 12 : 24;\n};\n\nexport { staticClasses as timePickerClasses };\n\nexport type TimeFormat = \"12\" | \"24\";\n\nexport type HvTimePickerClasses = ExtractNames<typeof useClasses>;\n\nexport type HvTimePickerClassKey =\n | \"root\"\n | \"input\"\n | \"label\"\n | \"placeholder\"\n | \"timePopperContainer\"\n | \"separator\"\n | \"periodContainer\"\n | \"formElementRoot\"\n | \"dropdownPlaceholder\"\n | \"iconBaseRoot\"\n | \"error\"\n | \"labelContainer\"\n | \"description\"\n | \"dropdownHeaderInvalid\"\n | \"dropdownPlaceholderDisabled\"\n | \"dropdownHeaderOpen\";\n\nexport type HvTimePickerValue = {\n hours: number;\n minutes: number;\n seconds: number;\n};\n\nexport interface HvTimePickerProps\n extends Omit<\n HvFormElementProps,\n \"classes\" | \"value\" | \"defaultValue\" | \"onChange\" | \"onFocus\" | \"onBlur\"\n > {\n /** Id to be applied to the form element root node. */\n id?: string;\n /** A Jss Object used to override or extend the styles applied to the component. */\n classes?: Partial<HvTimePickerClasses>;\n /** Current value of the element when _controlled_. Follows the 24-hour format. */\n value?: HvTimePickerValue;\n /** Initial value of the element when _uncontrolled_. Follows the 24-hour format. */\n defaultValue?: HvTimePickerValue;\n /** The placeholder value when no time is selected. */\n placeholder?: string;\n /** The placeholder of the hours input. */\n hoursPlaceholder?: string;\n /** The placeholder of the minutes input. */\n minutesPlaceholder?: string;\n /** The placeholder of the seconds input. */\n secondsPlaceholder?: string;\n /**\n * Whether the time picker should show the AM/PM 12-hour clock or the 24-hour one.\n * If undefined, the component will use a format according to the passed locale.\n */\n timeFormat?: TimeFormat;\n /** Whether to show the seconds when using the native time picker */\n showSeconds?: boolean;\n /** Locale that will provide the time format(12 or 24 hour format). It is \"overwritten\" by `showAmPm` */\n locale?: string;\n /** Whether the dropdown is expandable. */\n disableExpand?: boolean;\n\n /**\n * Callback function to be triggered when the input value is changed.\n * It is invoked with a `{hours, minutes, seconds}` object, always in the 24h format\n */\n onChange?: (value: HvTimePickerValue) => void;\n\n /** Callback called when dropdown changes the expanded state. */\n onToggle?: (event: Event, isOpen: boolean) => void;\n\n /** Disable the portal behavior. The children stay within it's parent DOM hierarchy. */\n disablePortal?: boolean;\n\n /** Sets if the calendar container should follow the date picker input out of the screen or stay visible. */\n escapeWithReference?: boolean;\n\n /** Extra properties to be passed to the TimePicker's dropdown. */\n dropdownProps?: Partial<HvBaseDropdownProps>;\n}\n\n/**\n * A Time Picker allows the user to choose a specific time or a time range.\n */\nexport const HvTimePicker = (props: HvTimePickerProps) => {\n const {\n classes: classesProp = {},\n className,\n\n id: idProp,\n name,\n required = false,\n disabled = false,\n readOnly = false,\n label,\n\n \"aria-label\": ariaLabel,\n \"aria-labelledby\": ariaLabelledBy,\n description,\n \"aria-describedby\": ariaDescribedBy,\n status,\n statusMessage,\n \"aria-errormessage\": ariaErrorMessage,\n\n placeholder,\n hoursPlaceholder = \"hh\",\n minutesPlaceholder = \"mm\",\n secondsPlaceholder = \"ss\",\n\n value: valueProp,\n defaultValue: defaultValueProp,\n\n timeFormat,\n showSeconds,\n disableExpand,\n locale = \"en\",\n\n onToggle,\n onChange,\n\n // misc properties:\n disablePortal = true,\n escapeWithReference = true,\n dropdownProps,\n ...others\n } = props;\n const id = useUniqueId(idProp, \"hvtimepicker\");\n const ref = useRef<HTMLDivElement>(null);\n const { css } = useCss();\n const { classes, cx } = useClasses(classesProp);\n\n const stateProps: TimeFieldStateOptions = {\n value: toTime(valueProp),\n defaultValue: toTime(defaultValueProp),\n label,\n locale,\n isRequired: required,\n isReadOnly: readOnly,\n isDisabled: disabled,\n granularity: \"second\",\n hourCycle: getFormat(timeFormat),\n onChange: (value) => {\n const { hour: hours, minute: minutes, second: seconds } = value;\n onChange?.({ hours, minutes, seconds });\n },\n };\n const state = useTimeFieldState(stateProps);\n const { labelProps, fieldProps } = useTimeField(\n {\n ...stateProps,\n id,\n \"aria-label\": ariaLabel,\n \"aria-labelledby\": ariaLabelledBy,\n \"aria-describedby\": ariaDescribedBy,\n },\n state,\n ref\n );\n\n const [open, setOpen] = useState(false);\n\n const [validationMessage] = useControlled(statusMessage, \"Required\");\n const [validationState] = useControlled(status, \"standBy\");\n\n const placeholders = useMemo(\n () => ({\n hour: hoursPlaceholder,\n minute: minutesPlaceholder,\n second: secondsPlaceholder,\n }),\n [hoursPlaceholder, minutesPlaceholder, secondsPlaceholder]\n );\n\n // the error message area will only be created if:\n // - an external element that provides an error message isn't identified via aria-errormessage AND\n // - both status and statusMessage properties are being controlled OR\n // - status is uncontrolled and required is true\n const canShowError =\n ariaErrorMessage == null &&\n ((status !== undefined && statusMessage !== undefined) ||\n (status === undefined && required));\n\n const is12HrFormat = state.segments[5] != null;\n const isStateInvalid = validationState === \"invalid\";\n const errorMessageId = isStateInvalid\n ? canShowError\n ? setId(id, \"error\")\n : ariaErrorMessage\n : undefined;\n\n return (\n <HvFormElement\n name={name}\n required={required}\n disabled={disabled}\n status={validationState}\n className={cx(classes.root, className)}\n {...others}\n >\n {(label || description) && (\n <div className={classes.labelContainer}>\n {label && (\n <HvLabel label={label} className={classes.label} {...labelProps} />\n )}\n {description && (\n <HvInfoMessage className={classes.description}>\n {description}\n </HvInfoMessage>\n )}\n </div>\n )}\n\n <div className={css({ width: is12HrFormat ? 220 : 200 })}>\n <HvBaseDropdown\n role=\"combobox\"\n variableWidth\n disabled={disabled}\n readOnly={readOnly}\n placeholder={\n placeholder && !state.value ? (\n placeholder\n ) : (\n <Placeholder\n ref={ref}\n name={name}\n state={state}\n placeholders={placeholders}\n className={cx(classes.placeholder, {\n [classes.placeholderDisabled]: disabled,\n })}\n {...fieldProps}\n />\n )\n }\n classes={{\n header: cx(classes.dropdownHeader, {\n [classes.dropdownHeaderInvalid]: isStateInvalid,\n }),\n panel: classes.dropdownPanel,\n headerOpen: classes.dropdownHeaderOpen,\n }}\n placement=\"right\"\n adornment={\n <TimeIcon\n color={disabled ? \"secondary_60\" : undefined}\n className={classes.icon}\n />\n }\n expanded={open}\n onToggle={(evt, newOpen) => {\n if (disableExpand) return;\n setOpen(newOpen);\n onToggle?.(evt, newOpen);\n }}\n onContainerCreation={(containerRef) => {\n containerRef?.getElementsByTagName(\"input\")[0]?.focus();\n }}\n aria-haspopup=\"dialog\"\n aria-invalid={isStateInvalid ? true : undefined}\n aria-errormessage={errorMessageId}\n disablePortal={disablePortal}\n popperProps={{\n modifiers: [\n { name: \"preventOverflow\", enabled: escapeWithReference },\n ],\n }}\n {...dropdownProps}\n >\n <div ref={ref} className={classes.timePopperContainer}>\n {state.segments.map((segment, i) => (\n <Unit\n key={i}\n state={state}\n segment={segment}\n placeholder={placeholders[segment.type]}\n onAdd={() => state.increment(segment.type)}\n onSub={() => state.decrement(segment.type)}\n onChange={(evt, val) => {\n state.setSegment(segment.type, Number(val));\n }}\n />\n ))}\n </div>\n </HvBaseDropdown>\n </div>\n\n {canShowError && (\n <HvWarningText\n id={setId(id, \"error\")}\n disableBorder\n className={classes.error}\n >\n {validationMessage}\n </HvWarningText>\n )}\n </HvFormElement>\n );\n};\n"],"names":["toTime","value","undefined","hours","minutes","seconds","Time","getFormat","timeFormat","HvTimePicker","props","classes","classesProp","className","id","idProp","name","required","disabled","readOnly","label","ariaLabel","ariaLabelledBy","description","ariaDescribedBy","status","statusMessage","ariaErrorMessage","placeholder","hoursPlaceholder","minutesPlaceholder","secondsPlaceholder","valueProp","defaultValue","defaultValueProp","showSeconds","disableExpand","locale","onToggle","onChange","disablePortal","escapeWithReference","dropdownProps","others","useUniqueId","ref","useRef","css","useCss","cx","useClasses","stateProps","isRequired","isReadOnly","isDisabled","granularity","hourCycle","hour","minute","second","state","useTimeFieldState","labelProps","fieldProps","useTimeField","open","setOpen","useState","validationMessage","useControlled","validationState","placeholders","useMemo","canShowError","is12HrFormat","segments","isStateInvalid","errorMessageId","setId","HvFormElement","root","children","labelContainer","_jsx","HvLabel","HvInfoMessage","width","HvBaseDropdown","role","variableWidth","Placeholder","placeholderDisabled","header","dropdownHeader","dropdownHeaderInvalid","panel","dropdownPanel","headerOpen","dropdownHeaderOpen","placement","adornment","TimeIcon","color","icon","expanded","evt","newOpen","onContainerCreation","containerRef","getElementsByTagName","focus","popperProps","modifiers","enabled","timePopperContainer","map","segment","i","Unit","type","onAdd","increment","onSub","decrement","val","setSegment","Number","HvWarningText","disableBorder","error"],"mappings":";;;;;;;;;;;;;;;;;;;;;AA4BA,MAAMA,SAASA,CAACC,UAA8B;AAC5C,MAAI,CAACA;AAAcC,WAAAA;AACb,QAAA;AAAA,IAAEC;AAAAA,IAAOC;AAAAA,IAASC;AAAAA,EAAYJ,IAAAA;AACpC,SAAO,IAAIK,KAAAA,KAAKH,OAAOC,SAASC,OAAO;AACzC;AAEA,MAAME,YAAYA,CAACC,eAA4B;AAC7C,MAAIA,cAAc;AAAa,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AAsBC,CAAiB,iBAAA;;AACrCA,6DAAcC,qBAAqB,SAAS,OAA5CD,mBAAgDE;AAAAA,QAClD;AAAA,QACA,iBAAc;AAAA,QACd,gBAAclC,iBAAiB,OAAO1E;AAAAA,QACtC,qBAAmB2E;AAAAA,QACnBrC;AAAAA,QACAuE,aAAa;AAAA,UACXC,WAAW,CACT;AAAA,YAAEhG,MAAM;AAAA,YAAmBiG,SAASxE;AAAAA,UAAAA,CAAqB;AAAA,QAE7D;AAAA,QAAE,GACEC;AAAAA,QAAauC,yCAEjB,OAAA;AAAA,UAAKpC;AAAAA,UAAUhC,WAAWF,QAAQuG;AAAAA,UAAoBjC,UACnDrB,MAAMe,SAASwC,IAAI,CAACC,SAASC,qCAC3BC,WAAI;AAAA,YAEH1D;AAAAA,YACAwD;AAAAA,YACAxF,aAAa2C,aAAa6C,QAAQG,IAAI;AAAA,YACtCC,OAAOA,MAAM5D,MAAM6D,UAAUL,QAAQG,IAAI;AAAA,YACzCG,OAAOA,MAAM9D,MAAM+D,UAAUP,QAAQG,IAAI;AAAA,YACzChF,UAAUA,CAACkE,KAAKmB,QAAQ;AACtBhE,oBAAMiE,WAAWT,QAAQG,MAAMO,OAAOF,GAAG,CAAC;AAAA,YAC5C;AAAA,UAAE,GARGP,CASN,CACF;AAAA,QAAA,CACE;AAAA,MAAA,CACS;AAAA,IAAA,CACb,GAEJ5C,gBACCU,2BAAAA,IAAC4C,2BAAa;AAAA,MACZjH,IAAIgE,MAAAA,MAAMhE,IAAI,OAAO;AAAA,MACrBkH,eAAa;AAAA,MACbnH,WAAWF,QAAQsH;AAAAA,MAAMhD,UAExBb;AAAAA,IAAAA,CACY,CAChB;AAAA,EAAA,CACY;AAEnB;;;"}
@@ -0,0 +1,53 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
+ const uikitStyles = require("@hitachivantara/uikit-styles");
4
+ const classes = require("../../utils/classes.cjs");
5
+ const {
6
+ useClasses,
7
+ staticClasses
8
+ } = classes.createClasses("HvTimerPicker", {
9
+ root: {
10
+ position: "relative"
11
+ },
12
+ labelContainer: {
13
+ display: "flex",
14
+ alignItems: "flex-start"
15
+ },
16
+ label: {
17
+ marginBottom: 6,
18
+ display: "block"
19
+ },
20
+ description: {},
21
+ placeholder: {
22
+ display: "flex",
23
+ gap: 1
24
+ },
25
+ placeholderDisabled: {
26
+ color: uikitStyles.theme.colors.secondary_60
27
+ },
28
+ dropdownHeader: {},
29
+ dropdownHeaderOpen: {},
30
+ dropdownHeaderInvalid: {
31
+ border: `1px solid ${uikitStyles.theme.colors.negative}`,
32
+ "&:hover": {
33
+ border: `1px solid ${uikitStyles.theme.colors.negative}`
34
+ }
35
+ },
36
+ dropdownPanel: {},
37
+ icon: {},
38
+ timePopperContainer: {
39
+ backgroundColor: uikitStyles.theme.colors.atmo1,
40
+ zIndex: 10,
41
+ display: "flex",
42
+ flexDirection: "row",
43
+ justifyContent: "center",
44
+ alignItems: "center",
45
+ padding: uikitStyles.theme.spacing(["xs", 0]),
46
+ userSelect: "none",
47
+ minWidth: "175px"
48
+ },
49
+ error: {}
50
+ });
51
+ exports.staticClasses = staticClasses;
52
+ exports.useClasses = useClasses;
53
+ //# sourceMappingURL=TimePicker.styles.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TimePicker.styles.cjs","sources":["../../../../src/components/TimePicker/TimePicker.styles.ts"],"sourcesContent":["import { theme } from \"@hitachivantara/uikit-styles\";\nimport { createClasses } from \"@core/utils\";\n\nexport const { useClasses, staticClasses } = createClasses(\"HvTimerPicker\", {\n root: {\n position: \"relative\",\n },\n\n labelContainer: {\n display: \"flex\",\n alignItems: \"flex-start\",\n },\n label: {\n marginBottom: 6,\n display: \"block\",\n },\n description: {},\n\n placeholder: {\n display: \"flex\",\n gap: 1,\n },\n placeholderDisabled: {\n color: theme.colors.secondary_60,\n },\n\n dropdownHeader: {},\n dropdownHeaderOpen: {},\n dropdownHeaderInvalid: {\n border: `1px solid ${theme.colors.negative}`,\n \"&:hover\": {\n border: `1px solid ${theme.colors.negative}`,\n },\n },\n dropdownPanel: {},\n\n icon: {},\n\n timePopperContainer: {\n backgroundColor: theme.colors.atmo1,\n zIndex: 10,\n display: \"flex\",\n flexDirection: \"row\",\n justifyContent: \"center\",\n alignItems: \"center\",\n padding: theme.spacing([\"xs\", 0]),\n userSelect: \"none\",\n minWidth: \"175px\",\n },\n\n error: {},\n});\n"],"names":["useClasses","staticClasses","createClasses","root","position","labelContainer","display","alignItems","label","marginBottom","description","placeholder","gap","placeholderDisabled","color","theme","colors","secondary_60","dropdownHeader","dropdownHeaderOpen","dropdownHeaderInvalid","border","negative","dropdownPanel","icon","timePopperContainer","backgroundColor","atmo1","zIndex","flexDirection","justifyContent","padding","spacing","userSelect","minWidth","error"],"mappings":";;;;AAGa,MAAA;AAAA,EAAEA;AAAAA,EAAYC;AAAc,IAAIC,QAAAA,cAAc,iBAAiB;AAAA,EAC1EC,MAAM;AAAA,IACJC,UAAU;AAAA,EACZ;AAAA,EAEAC,gBAAgB;AAAA,IACdC,SAAS;AAAA,IACTC,YAAY;AAAA,EACd;AAAA,EACAC,OAAO;AAAA,IACLC,cAAc;AAAA,IACdH,SAAS;AAAA,EACX;AAAA,EACAI,aAAa,CAAC;AAAA,EAEdC,aAAa;AAAA,IACXL,SAAS;AAAA,IACTM,KAAK;AAAA,EACP;AAAA,EACAC,qBAAqB;AAAA,IACnBC,OAAOC,YAAAA,MAAMC,OAAOC;AAAAA,EACtB;AAAA,EAEAC,gBAAgB,CAAC;AAAA,EACjBC,oBAAoB,CAAC;AAAA,EACrBC,uBAAuB;AAAA,IACrBC,QAAS,aAAYN,YAAAA,MAAMC,OAAOM;AAAAA,IAClC,WAAW;AAAA,MACTD,QAAS,aAAYN,YAAAA,MAAMC,OAAOM;AAAAA,IACpC;AAAA,EACF;AAAA,EACAC,eAAe,CAAC;AAAA,EAEhBC,MAAM,CAAC;AAAA,EAEPC,qBAAqB;AAAA,IACnBC,iBAAiBX,YAAAA,MAAMC,OAAOW;AAAAA,IAC9BC,QAAQ;AAAA,IACRtB,SAAS;AAAA,IACTuB,eAAe;AAAA,IACfC,gBAAgB;AAAA,IAChBvB,YAAY;AAAA,IACZwB,SAAShB,YAAAA,MAAMiB,QAAQ,CAAC,MAAM,CAAC,CAAC;AAAA,IAChCC,YAAY;AAAA,IACZC,UAAU;AAAA,EACZ;AAAA,EAEAC,OAAO,CAAC;AACV,CAAC;;;"}
@@ -0,0 +1,72 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
+ const react = require("@emotion/react");
4
+ const uikitReactIcons = require("@hitachivantara/uikit-react-icons");
5
+ const uikitStyles = require("@hitachivantara/uikit-styles");
6
+ const Unit_styles = require("./Unit.styles.cjs");
7
+ const jsxRuntime = require("@emotion/react/jsx-runtime");
8
+ const ToggleButton = require("../../ToggleButton/ToggleButton.cjs");
9
+ const Input = require("../../Input/Input.cjs");
10
+ const Unit = ({
11
+ id,
12
+ state,
13
+ segment,
14
+ placeholder: placeholderProp,
15
+ onChange,
16
+ onAdd,
17
+ onSub
18
+ }) => {
19
+ const {
20
+ type,
21
+ text
22
+ } = segment;
23
+ const placeholder = placeholderProp ?? segment.placeholder;
24
+ return /* @__PURE__ */ jsxRuntime.jsx(react.ClassNames, {
25
+ children: ({
26
+ css
27
+ }) => /* @__PURE__ */ jsxRuntime.jsxs("div", {
28
+ className: css(Unit_styles.styles.root),
29
+ children: [type !== "literal" && /* @__PURE__ */ jsxRuntime.jsx(uikitReactIcons.DropUpXS, {
30
+ onClick: onAdd
31
+ }), type === "literal" && /* @__PURE__ */ jsxRuntime.jsx("div", {
32
+ className: css(Unit_styles.styles.separator),
33
+ children: text
34
+ }), type === "dayPeriod" && /* @__PURE__ */ jsxRuntime.jsx(ToggleButton.HvToggleButton, {
35
+ className: css(Unit_styles.styles.periodToggle),
36
+ onClick: onAdd,
37
+ children: text
38
+ }), ["hour", "minute", "second"].includes(type) && /* @__PURE__ */ jsxRuntime.jsx(Input.HvInput, {
39
+ id,
40
+ disableClear: true,
41
+ style: {
42
+ ...uikitStyles.theme.typography.title3
43
+ },
44
+ classes: {
45
+ input: css(Unit_styles.styles.input),
46
+ root: css(Unit_styles.styles.inputContainer),
47
+ inputBorderContainer: css(Unit_styles.styles.inputBorderContainer),
48
+ inputRoot: css(Unit_styles.styles.inputRoot)
49
+ },
50
+ onKeyDown: (event) => {
51
+ if (event.key === "Enter") {
52
+ event.preventDefault();
53
+ event.stopPropagation();
54
+ }
55
+ },
56
+ required: true,
57
+ status: state.validationState,
58
+ value: text.padStart(2, "0"),
59
+ onChange,
60
+ placeholder,
61
+ inputProps: {
62
+ autoComplete: "off",
63
+ type: "number"
64
+ }
65
+ }), type !== "literal" && /* @__PURE__ */ jsxRuntime.jsx(uikitReactIcons.DropDownXS, {
66
+ onClick: onSub
67
+ })]
68
+ })
69
+ });
70
+ };
71
+ exports.Unit = Unit;
72
+ //# sourceMappingURL=Unit.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Unit.cjs","sources":["../../../../../src/components/TimePicker/Unit/Unit.tsx"],"sourcesContent":["import { KeyboardEvent } from \"react\";\nimport { ClassNames } from \"@emotion/react\";\nimport { DateFieldState, DateSegment } from \"@react-stately/datepicker\";\nimport {\n DropDownXS as SubtractTimeIcon,\n DropUpXS as AddTimeIcon,\n} from \"@hitachivantara/uikit-react-icons\";\nimport { HvInput, HvInputProps, HvToggleButton, theme } from \"../../..\";\nimport { styles } from \"./Unit.styles\";\n\ninterface UnitProps {\n id?: string;\n state: DateFieldState;\n segment: DateSegment;\n placeholder?: string;\n /** Called when the value changes */\n onChange?: HvInputProps[\"onChange\"];\n /** Called when the up/add arrow is pressed */\n onAdd?: () => void;\n /** Called when the down/subtract arrow is pressed */\n onSub?: () => void;\n}\n\nexport const Unit = ({\n id,\n state,\n segment,\n placeholder: placeholderProp,\n onChange,\n onAdd,\n onSub,\n}: UnitProps) => {\n const { type, text } = segment;\n const placeholder = placeholderProp ?? segment.placeholder;\n\n return (\n <ClassNames>\n {({ css }) => (\n <div className={css(styles.root)}>\n {type !== \"literal\" && <AddTimeIcon onClick={onAdd} />}\n {type === \"literal\" && (\n <div className={css(styles.separator)}>{text}</div>\n )}\n {type === \"dayPeriod\" && (\n <HvToggleButton\n className={css(styles.periodToggle)}\n onClick={onAdd}\n >\n {text}\n </HvToggleButton>\n )}\n {[\"hour\", \"minute\", \"second\"].includes(type) && (\n <HvInput\n id={id}\n disableClear\n style={{\n ...theme.typography.title3,\n }}\n classes={{\n input: css(styles.input),\n root: css(styles.inputContainer),\n inputBorderContainer: css(styles.inputBorderContainer),\n inputRoot: css(styles.inputRoot),\n }}\n onKeyDown={(event) => {\n if ((event as KeyboardEvent).key === \"Enter\") {\n event.preventDefault();\n event.stopPropagation();\n }\n }}\n required\n status={state.validationState}\n value={text.padStart(2, \"0\")}\n onChange={onChange}\n placeholder={placeholder}\n inputProps={{ autoComplete: \"off\", type: \"number\" }}\n />\n )}\n {type !== \"literal\" && <SubtractTimeIcon onClick={onSub} />}\n </div>\n )}\n </ClassNames>\n );\n};\n"],"names":["Unit","id","state","segment","placeholder","placeholderProp","onChange","onAdd","onSub","type","text","ClassNames","children","css","className","styles","root","AddTimeIcon","onClick","separator","HvToggleButton","periodToggle","includes","_jsx","HvInput","disableClear","style","theme","typography","title3","classes","input","inputContainer","inputBorderContainer","inputRoot","onKeyDown","event","key","preventDefault","stopPropagation","required","status","validationState","value","padStart","inputProps","autoComplete","SubtractTimeIcon"],"mappings":";;;;;;;;;AAuBO,MAAMA,OAAOA,CAAC;AAAA,EACnBC;AAAAA,EACAC;AAAAA,EACAC;AAAAA,EACAC,aAAaC;AAAAA,EACbC;AAAAA,EACAC;AAAAA,EACAC;AACS,MAAM;AACT,QAAA;AAAA,IAAEC;AAAAA,IAAMC;AAAAA,EAASP,IAAAA;AACjBC,QAAAA,cAAcC,mBAAmBF,QAAQC;AAE/C,wCACGO,MAAAA,YAAU;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GAEFA,SAAS,4CAAcsC,gBAAAA,YAAgB;AAAA,QAAC7B,SAASV;AAAAA,MAAAA,CAAQ,CAAC;AAAA,IAAA,CACxD;AAAA,EAAA,CAEG;AAEhB;;"}
@@ -0,0 +1,56 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
+ const uikitStyles = require("@hitachivantara/uikit-styles");
4
+ const styles = {
5
+ root: {
6
+ display: "flex",
7
+ flexDirection: "column",
8
+ justifyContent: "center",
9
+ alignItems: "center",
10
+ textAlign: "center",
11
+ ...uikitStyles.theme.typography.sTitle
12
+ },
13
+ separator: {
14
+ width: 8
15
+ },
16
+ periodToggle: {
17
+ height: 40,
18
+ width: 40
19
+ },
20
+ element: {
21
+ display: "flex",
22
+ justifyContent: "center",
23
+ alignItems: "center",
24
+ height: 40,
25
+ width: 40
26
+ },
27
+ input: {
28
+ ...uikitStyles.theme.typography.sTitle,
29
+ fontWeight: 600,
30
+ textAlign: "center",
31
+ height: 40,
32
+ width: 40,
33
+ padding: 0,
34
+ margin: 0,
35
+ "&::placeholder": {
36
+ fontSize: 16,
37
+ fontWeight: 600
38
+ }
39
+ },
40
+ inputRoot: {
41
+ width: 40,
42
+ height: 40
43
+ },
44
+ subtractIcon: {
45
+ marginTop: uikitStyles.theme.space.xs
46
+ },
47
+ inputContainer: {
48
+ minWidth: 40,
49
+ maxWidth: 40
50
+ },
51
+ inputBorderContainer: {
52
+ top: 40
53
+ }
54
+ };
55
+ exports.styles = styles;
56
+ //# sourceMappingURL=Unit.styles.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Unit.styles.cjs","sources":["../../../../../src/components/TimePicker/Unit/Unit.styles.ts"],"sourcesContent":["import { CSSInterpolation } from \"@emotion/css\";\nimport { theme } from \"@hitachivantara/uikit-styles\";\n\nexport const styles = {\n root: {\n display: \"flex\",\n flexDirection: \"column\",\n justifyContent: \"center\",\n alignItems: \"center\",\n textAlign: \"center\",\n ...theme.typography.sTitle,\n },\n\n separator: {\n width: 8,\n },\n\n periodToggle: {\n height: 40,\n width: 40,\n },\n\n element: {\n display: \"flex\",\n justifyContent: \"center\",\n alignItems: \"center\",\n height: 40,\n width: 40,\n },\n\n input: {\n ...theme.typography.sTitle,\n fontWeight: 600,\n textAlign: \"center\",\n height: 40,\n width: 40,\n padding: 0,\n margin: 0,\n \"&::placeholder\": {\n fontSize: 16,\n fontWeight: 600,\n },\n },\n inputRoot: {\n width: 40,\n height: 40,\n },\n\n subtractIcon: {\n marginTop: theme.space.xs,\n },\n inputContainer: {\n minWidth: 40,\n maxWidth: 40,\n },\n inputBorderContainer: {\n top: 40,\n },\n} satisfies Record<string, CSSInterpolation>;\n"],"names":["styles","root","display","flexDirection","justifyContent","alignItems","textAlign","theme","typography","sTitle","separator","width","periodToggle","height","element","input","fontWeight","padding","margin","fontSize","inputRoot","subtractIcon","marginTop","space","xs","inputContainer","minWidth","maxWidth","inputBorderContainer","top"],"mappings":";;;AAGO,MAAMA,SAAS;AAAA,EACpBC,MAAM;AAAA,IACJC,SAAS;AAAA,IACTC,eAAe;AAAA,IACfC,gBAAgB;AAAA,IAChBC,YAAY;AAAA,IACZC,WAAW;AAAA,IACX,GAAGC,YAAAA,MAAMC,WAAWC;AAAAA,EACtB;AAAA,EAEAC,WAAW;AAAA,IACTC,OAAO;AAAA,EACT;AAAA,EAEAC,cAAc;AAAA,IACZC,QAAQ;AAAA,IACRF,OAAO;AAAA,EACT;AAAA,EAEAG,SAAS;AAAA,IACPZ,SAAS;AAAA,IACTE,gBAAgB;AAAA,IAChBC,YAAY;AAAA,IACZQ,QAAQ;AAAA,IACRF,OAAO;AAAA,EACT;AAAA,EAEAI,OAAO;AAAA,IACL,GAAGR,YAAAA,MAAMC,WAAWC;AAAAA,IACpBO,YAAY;AAAA,IACZV,WAAW;AAAA,IACXO,QAAQ;AAAA,IACRF,OAAO;AAAA,IACPM,SAAS;AAAA,IACTC,QAAQ;AAAA,IACR,kBAAkB;AAAA,MAChBC,UAAU;AAAA,MACVH,YAAY;AAAA,IACd;AAAA,EACF;AAAA,EACAI,WAAW;AAAA,IACTT,OAAO;AAAA,IACPE,QAAQ;AAAA,EACV;AAAA,EAEAQ,cAAc;AAAA,IACZC,WAAWf,YAAAA,MAAMgB,MAAMC;AAAAA,EACzB;AAAA,EACAC,gBAAgB;AAAA,IACdC,UAAU;AAAA,IACVC,UAAU;AAAA,EACZ;AAAA,EACAC,sBAAsB;AAAA,IACpBC,KAAK;AAAA,EACP;AACF;;"}