@nulogy/components 16.0.1 → 16.0.2

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 (62) hide show
  1. package/dist/main.js +45 -59
  2. package/dist/main.js.map +1 -1
  3. package/dist/main.module.js +45 -59
  4. package/dist/main.module.js.map +1 -1
  5. package/dist/src/BottomSheet/BottomSheet.parts.d.ts +2 -2
  6. package/dist/src/BottomSheet/BottomSheet.styled.d.ts +10 -6
  7. package/dist/src/Box/Box.d.ts +12 -13
  8. package/dist/src/BrandedNavBar/DesktopMenu.d.ts +3 -1
  9. package/dist/src/BrandedNavBar/NavBar.js +2 -2
  10. package/dist/src/Button/DangerButton.d.ts +3 -1
  11. package/dist/src/Button/PrimaryButton.d.ts +3 -1
  12. package/dist/src/Button/QuietButton.d.ts +3 -1
  13. package/dist/src/DateRange/EndTime.d.ts +5 -7
  14. package/dist/src/DateRange/StartTime.d.ts +5 -7
  15. package/dist/src/DescriptionList/stories/fixtures.d.ts +2 -2
  16. package/dist/src/DropdownMenu/DropdownMenuContainer.d.ts +1 -1
  17. package/dist/src/DropdownMenu/DropdownText.d.ts +1 -1
  18. package/dist/src/FieldLabel/HelpText.d.ts +1 -1
  19. package/dist/src/Icon/Icon.d.ts +6 -2
  20. package/dist/src/Link/Link.story.js +1 -1
  21. package/dist/src/Modal/Modal.d.ts +5 -3
  22. package/dist/src/Modal/Modal.js +2 -2
  23. package/dist/src/Modal/Modal.story.d.ts +1 -23
  24. package/dist/src/Modal/ModalCloseButton.d.ts +4 -2
  25. package/dist/src/Modal/ModalContent.d.ts +1 -1
  26. package/dist/src/Navigation/components/AppSwitcher/parts/Item.d.ts +3 -1
  27. package/dist/src/Navigation/components/AppSwitcher/parts/index.d.ts +15 -7
  28. package/dist/src/Navigation/components/DesktopNav/parts/MoreMenuItem.d.ts +5 -1
  29. package/dist/src/Navigation/components/MenuSubItem/parts/styled.d.ts +17 -5
  30. package/dist/src/Navigation/components/MobileNav/parts/styled.d.ts +10 -4
  31. package/dist/src/Navigation/components/UserMenu/UserMenu.d.ts +5 -1
  32. package/dist/src/Navigation/components/UserMenu/parts/styled.d.ts +6 -2
  33. package/dist/src/Navigation/components/shared/NavigationMenuContent.d.ts +5 -1
  34. package/dist/src/Navigation/components/shared/NavigationMenuItem.d.ts +3 -1
  35. package/dist/src/Navigation/components/shared/components.d.ts +35 -9
  36. package/dist/src/Radio/Radio.story.d.ts +12 -14
  37. package/dist/src/Summary/Summary.d.ts +1 -2
  38. package/dist/src/Summary/Summary.js +2 -2
  39. package/dist/src/Summary/SummaryContext.d.ts +3 -1
  40. package/dist/src/Summary/SummaryContext.js +2 -2
  41. package/dist/src/Summary/SummaryItem.d.ts +1 -1
  42. package/dist/src/Summary/SummaryItem.js +2 -2
  43. package/dist/src/Switcher/Switcher.d.ts +2 -2
  44. package/dist/src/Switcher/Switcher.js +2 -2
  45. package/dist/src/Tabs/TabScrollIndicator.d.ts +1 -1
  46. package/dist/src/Tabs/TabScrollIndicator.js +2 -2
  47. package/dist/src/TimePicker/TimePicker.d.ts +1 -1
  48. package/dist/src/TimePicker/TimePickerInput.d.ts +3 -1
  49. package/dist/src/TimeRange/TimeRange.d.ts +3 -2
  50. package/dist/src/ToastContainer/ToastFunction.js +2 -2
  51. package/dist/src/Toggle/ToggleButton.js +2 -2
  52. package/dist/src/TopBar/TopBar.styled.d.ts +16 -15
  53. package/dist/src/TopBar/components/BackLink.d.ts +3 -1
  54. package/dist/src/TopBar/components/MenuItemLink.d.ts +3 -1
  55. package/dist/src/TopBar/stories/TopBar.backButton.story.js +1 -1
  56. package/dist/src/TopBar/stories/TopBar.menu.story.js +1 -1
  57. package/dist/src/Type/Headings.d.ts +4 -4
  58. package/dist/src/utils/story/dashed.d.ts +1 -3
  59. package/dist/src/utils/story/resizable.d.ts +4 -2
  60. package/dist/src/utils/ts/FocusManager.d.ts +1 -1
  61. package/dist/src/utils/ts/FocusManager.js +2 -2
  62. package/package.json +11 -12
package/dist/main.js CHANGED
@@ -11485,7 +11485,7 @@
11485
11485
  const { asChild, ...primitiveProps } = props;
11486
11486
  const Comp = asChild ? $5e63c961fc1ce211$export$8c6ed5c666ac1360 : node2;
11487
11487
  React.useEffect(() => {
11488
- window[Symbol.for("radix-ui")] = true;
11488
+ window[/* @__PURE__ */ Symbol.for("radix-ui")] = true;
11489
11489
  }, []);
11490
11490
  return /* @__PURE__ */ React.createElement(Comp, _extends$3({}, primitiveProps, {
11491
11491
  ref: forwardedRef
@@ -28115,14 +28115,7 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
28115
28115
  textColor: "blackBlue",
28116
28116
  logoColor: "blue"
28117
28117
  };
28118
- const MediumNavBar = ({
28119
- menuData,
28120
- environment,
28121
- logo,
28122
- showNulogyLogo,
28123
- subtext,
28124
- ...props
28125
- }) => {
28118
+ function MediumNavBar({ menuData, environment, logo, showNulogyLogo, subtext, ...props }) {
28126
28119
  const { t: t2 } = useTranslation();
28127
28120
  return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
28128
28121
  environment && /* @__PURE__ */ jsxRuntime.jsx(EnvironmentBanner, { children: environment }),
@@ -28153,7 +28146,7 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
28153
28146
  ] })
28154
28147
  ] }) })
28155
28148
  ] });
28156
- };
28149
+ }
28157
28150
  const SelectNavBarBasedOnWidth = ({
28158
28151
  width: width2,
28159
28152
  defaultOpen,
@@ -44523,17 +44516,15 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
44523
44516
  }
44524
44517
  var libExports = requireLib();
44525
44518
  const ReactModal = /* @__PURE__ */ getDefaultExportFromCjs(libExports);
44526
- const ModalContent = styledComponents.styled.div(
44527
- ({ hasFooter, theme }) => ({
44528
- marginTop: "-64px",
44529
- marginBottom: hasFooter ? "-72px" : 0,
44530
- overflow: "auto",
44531
- paddingTop: "88px",
44532
- paddingBottom: hasFooter ? "96px" : theme.space.x2,
44533
- paddingLeft: theme.space.x3,
44534
- paddingRight: theme.space.x3
44535
- })
44536
- );
44519
+ const ModalContent = styledComponents.styled.div(({ hasFooter, theme }) => ({
44520
+ marginTop: "-64px",
44521
+ marginBottom: hasFooter ? "-72px" : 0,
44522
+ overflow: "auto",
44523
+ paddingTop: "88px",
44524
+ paddingBottom: hasFooter ? "96px" : theme.space.x2,
44525
+ paddingLeft: theme.space.x3,
44526
+ paddingRight: theme.space.x3
44527
+ }));
44537
44528
  const ModalFooter = styledComponents.styled.div(({ theme }) => ({
44538
44529
  position: "relative",
44539
44530
  padding: `${theme.space.x2} ${theme.space.x3}`,
@@ -44624,7 +44615,7 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
44624
44615
  MozOsxFontSmoothing: "grayscale"
44625
44616
  })
44626
44617
  );
44627
- const Modal = ({
44618
+ function Modal({
44628
44619
  isOpen = true,
44629
44620
  shouldFocusAfterRender = true,
44630
44621
  shouldReturnFocusAfterClose = true,
@@ -44644,7 +44635,7 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
44644
44635
  footerContent,
44645
44636
  closeAriaLabel,
44646
44637
  parentSelector
44647
- }) => {
44638
+ }) {
44648
44639
  const modalHasHeader = Boolean(onRequestClose || title);
44649
44640
  const themeContext = React.useContext(styledComponents.ThemeContext);
44650
44641
  return /* @__PURE__ */ jsxRuntime.jsx(
@@ -44686,7 +44677,7 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
44686
44677
  )
44687
44678
  }
44688
44679
  );
44689
- };
44680
+ }
44690
44681
  function ModalWrapper({
44691
44682
  modalHasHeader,
44692
44683
  title,
@@ -51511,17 +51502,19 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
51511
51502
  ref: list,
51512
51503
  outerRef: innerRef,
51513
51504
  estimatedItemSize,
51514
- innerElementType: React__namespace.forwardRef(({ style, ...rest }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
51515
- "div",
51516
- {
51517
- ref,
51518
- style: {
51519
- ...style,
51520
- height: `${parseFloat(style.height) + paddingBottom + paddingTop}px`
51521
- },
51522
- ...rest
51523
- }
51524
- )),
51505
+ innerElementType: React__namespace.forwardRef(
51506
+ ({ style, ...rest }, ref) => /* @__PURE__ */ jsxRuntime.jsx(
51507
+ "div",
51508
+ {
51509
+ ref,
51510
+ style: {
51511
+ ...style,
51512
+ height: `${parseFloat(style.height) + paddingBottom + paddingTop}px`
51513
+ },
51514
+ ...rest
51515
+ }
51516
+ )
51517
+ ),
51525
51518
  height: menuHeight,
51526
51519
  width: "100%",
51527
51520
  itemCount,
@@ -52405,10 +52398,7 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
52405
52398
  }
52406
52399
  return context;
52407
52400
  }
52408
- const SummaryContextProvider = ({
52409
- breakpoint,
52410
- children
52411
- }) => {
52401
+ function SummaryContextProvider({ breakpoint, children }) {
52412
52402
  return /* @__PURE__ */ jsxRuntime.jsx(
52413
52403
  SummaryContext.Provider,
52414
52404
  {
@@ -52418,7 +52408,7 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
52418
52408
  children
52419
52409
  }
52420
52410
  );
52421
- };
52411
+ }
52422
52412
  const SummaryWrapper = styledComponents.styled(Box)(({ theme, breakpoint }) => ({
52423
52413
  display: "flex",
52424
52414
  background: theme.colors.white,
@@ -52437,12 +52427,12 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
52437
52427
  rowGap: 0
52438
52428
  }
52439
52429
  }));
52440
- const Summary = ({ breakpoint, children, ...rest }) => {
52430
+ function Summary({ breakpoint, children, ...rest }) {
52441
52431
  const theme = styledComponents.useTheme();
52442
52432
  breakpoint || (breakpoint = theme.breakpoints.medium);
52443
52433
  const breakpointPx = numberFromDimension(breakpoint);
52444
52434
  return /* @__PURE__ */ jsxRuntime.jsx(SummaryContextProvider, { breakpoint: breakpointPx, children: /* @__PURE__ */ jsxRuntime.jsx(SummaryWrapper, { breakpoint: breakpointPx, ...rest, children }) });
52445
- };
52435
+ }
52446
52436
  const SummaryItemWrapper = styledComponents.styled(Flex)(({ theme, breakpoint }) => ({
52447
52437
  gap: theme.space.half,
52448
52438
  flexDirection: "column",
@@ -52450,7 +52440,7 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
52450
52440
  flexDirection: "row"
52451
52441
  }
52452
52442
  }));
52453
- const SummaryItem = ({ value, status, ...rest }) => {
52443
+ function SummaryItem({ value, status, ...rest }) {
52454
52444
  const { breakpoint } = useSummaryContext();
52455
52445
  const matches = useMediaQuery(`(max-width: ${breakpoint}px)`);
52456
52446
  delete rest["children"];
@@ -52458,7 +52448,7 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
52458
52448
  /* @__PURE__ */ jsxRuntime.jsx(Text, { fontWeight: "medium", fontSize: !matches ? "heading4" : void 0, children: value }),
52459
52449
  status
52460
52450
  ] });
52461
- };
52451
+ }
52462
52452
  const Divider = styledComponents.styled(Box)(({ theme, breakpoint }) => ({
52463
52453
  display: "block",
52464
52454
  alignSelf: "stretch",
@@ -52474,11 +52464,7 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
52474
52464
  const { breakpoint } = useSummaryContext();
52475
52465
  return /* @__PURE__ */ jsxRuntime.jsx(Divider, { breakpoint: numberFromDimension(breakpoint), ...props });
52476
52466
  };
52477
- const FocusManager = ({
52478
- children,
52479
- refs = void 0,
52480
- defaultFocusedIndex
52481
- }) => {
52467
+ function FocusManager({ children, refs = void 0, defaultFocusedIndex }) {
52482
52468
  const [focusedIndex, setFocusedIndex] = React.useState(defaultFocusedIndex ?? 0);
52483
52469
  const prevFocusedIndex = React.useRef(focusedIndex);
52484
52470
  const focusPrevious = () => {
@@ -52513,8 +52499,8 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
52513
52499
  setFocusedIndex,
52514
52500
  handleArrowNavigation
52515
52501
  }) });
52516
- };
52517
- const Switcher = ({ variant: variant2, selected, onChange, ...rest }) => {
52502
+ }
52503
+ function Switcher({ variant: variant2, selected, onChange, ...rest }) {
52518
52504
  const componentVariant = useComponentVariant(variant2);
52519
52505
  const optionRefs = [];
52520
52506
  const isSelected = (value, index2) => {
@@ -52548,7 +52534,7 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
52548
52534
  });
52549
52535
  };
52550
52536
  return /* @__PURE__ */ jsxRuntime.jsx(Box, { display: "inline-flex", bg: "whiteGrey", borderRadius: "9999px", ...rest, children: /* @__PURE__ */ jsxRuntime.jsx(FocusManager, { refs: optionRefs, defaultFocusedIndex: getSelectedIndex(), children: ({ focusedIndex, setFocusedIndex, handleArrowNavigation }) => options2(focusedIndex, setFocusedIndex, handleArrowNavigation) }) });
52551
- };
52537
+ }
52552
52538
  const Switch$1 = React.forwardRef(({ children, ...rest }, ref) => {
52553
52539
  return /* @__PURE__ */ jsxRuntime.jsx(SwitchButton, { ...rest, ref, children });
52554
52540
  });
@@ -52720,14 +52706,14 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
52720
52706
  opacity: ".5"
52721
52707
  }
52722
52708
  }));
52723
- const TabScrollIndicator = ({
52709
+ function TabScrollIndicator({
52724
52710
  side = "left",
52725
52711
  width: width2 = 40,
52726
52712
  ariaLabelLeft,
52727
52713
  ariaLabelRight,
52728
52714
  onClick,
52729
52715
  ...props
52730
- }) => {
52716
+ }) {
52731
52717
  const { t: t2 } = useTranslation();
52732
52718
  const rightArrowLabel = ariaLabelRight || t2("next");
52733
52719
  const leftArrowLabel = ariaLabelLeft || t2("previous");
@@ -52747,7 +52733,7 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
52747
52733
  children: /* @__PURE__ */ jsxRuntime.jsx(Icon, { icon: side === "right" ? "rightArrow" : "leftArrow" })
52748
52734
  }
52749
52735
  );
52750
- };
52736
+ }
52751
52737
  const TabScrollIndicatorContainer = styledComponents.styled.div(({ width: width2, theme }) => ({
52752
52738
  position: "absolute",
52753
52739
  width: width2,
@@ -53733,12 +53719,12 @@ to {
53733
53719
  }
53734
53720
  );
53735
53721
  };
53736
- const CustomToast = ({ isVisible, id: id2, children, ...props }) => {
53722
+ function CustomToast({ isVisible, id: id2, children, ...props }) {
53737
53723
  const handleClose = () => {
53738
53724
  n.dismiss(id2);
53739
53725
  };
53740
53726
  return /* @__PURE__ */ jsxRuntime.jsx(AnimatePresence, { children: isVisible && /* @__PURE__ */ jsxRuntime.jsx(AnimatedBox, { role: "alert", ...toastAnimationConfig, children: /* @__PURE__ */ jsxRuntime.jsx(Alert$1, { controlled: true, onClose: handleClose, ...props, children }) }, "notification") });
53741
- };
53727
+ }
53742
53728
  const toast = {
53743
53729
  danger: (children, props = {}, options2 = {}) => n.custom(
53744
53730
  (t2) => /* @__PURE__ */ jsxRuntime.jsx(CustomToast, { id: t2.id, isVisible: t2.visible, type: "danger", ...props, children }),
@@ -53788,7 +53774,7 @@ to {
53788
53774
  }
53789
53775
  );
53790
53776
  }
53791
- const Slider = ({ disabled, children }) => {
53777
+ function Slider({ disabled, children }) {
53792
53778
  const theme = styledComponents.useTheme();
53793
53779
  return /* @__PURE__ */ jsxRuntime.jsx(
53794
53780
  motion.div,
@@ -53817,7 +53803,7 @@ to {
53817
53803
  children
53818
53804
  }
53819
53805
  );
53820
- };
53806
+ }
53821
53807
  const ToggleInput = styledComponents.styled.input(({ disabled, theme }) => ({
53822
53808
  width: "1px",
53823
53809
  height: "1px",