@nulogy/components 15.4.1 → 16.0.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.
- package/dist/main.js +91 -93
- package/dist/main.js.map +1 -1
- package/dist/main.module.js +91 -93
- package/dist/main.module.js.map +1 -1
- package/dist/src/BottomSheet/BottomSheet.styled.js +1 -1
- package/dist/src/BrandedNavBar/MenuTrigger.js +1 -3
- package/dist/src/BrandedNavBar/MobileMenu.d.ts +1 -1
- package/dist/src/BrandedNavBar/MobileMenu.js +0 -2
- package/dist/src/BrandedNavBar/NavBarDropdownMenu.js +26 -23
- package/dist/src/BrandedNavBar/SmallNavBar.js +0 -2
- package/dist/src/DropdownMenu/DropdownMenu.story.js +8 -4
- package/dist/src/Navigation/components/shared/NavigationMenuItem.js +5 -1
- package/dist/src/Popper/Popper.js +0 -1
- package/dist/src/RangeContainer/RangeContainer.js +1 -3
- package/dist/src/Tabs/Tabs.story.d.ts +0 -1
- package/dist/src/Tabs/Tabs.story.js +0 -5
- package/dist/src/TimeRange/TimeRange.d.ts +7 -3
- package/dist/src/TimeRange/TimeRange.js +2 -2
- package/dist/src/Toast/Toast.js +1 -3
- package/dist/src/Toast/Toast.story.js +0 -2
- package/dist/src/Toggle/Toggle.js +0 -2
- package/dist/src/i18n.js +0 -2
- package/dist/src/utils/PopperArrow.js +3 -3
- package/dist/src/utils/noop.js +1 -3
- package/dist/src/utils/ts/FocusManager.d.ts +2 -2
- package/dist/src/utils/useScrollLock.js +0 -1
- package/package.json +12 -6
package/dist/main.js
CHANGED
|
@@ -8246,7 +8246,7 @@
|
|
|
8246
8246
|
}
|
|
8247
8247
|
}
|
|
8248
8248
|
const getThemeColor = (color2, theme) => theme.colors[color2] ? theme.colors[color2] : color2;
|
|
8249
|
-
const positionArrow = (placement
|
|
8249
|
+
const positionArrow = (placement) => {
|
|
8250
8250
|
const location = String(placement).split("-")[0];
|
|
8251
8251
|
switch (location) {
|
|
8252
8252
|
case "top":
|
|
@@ -8379,7 +8379,7 @@
|
|
|
8379
8379
|
({ placement = "bottom", borderColor: borderColor2 = "grey", backgroundColor = "white", theme }) => ({
|
|
8380
8380
|
...drawArrow(placement, borderColor2, backgroundColor, theme)
|
|
8381
8381
|
}),
|
|
8382
|
-
({ placement = "bottom"
|
|
8382
|
+
({ placement = "bottom" }) => ({
|
|
8383
8383
|
...positionArrow(placement)
|
|
8384
8384
|
})
|
|
8385
8385
|
);
|
|
@@ -23670,7 +23670,7 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
23670
23670
|
}),
|
|
23671
23671
|
compose(...styleFns)
|
|
23672
23672
|
);
|
|
23673
|
-
const ContentContainer = styledComponents.styled.div((
|
|
23673
|
+
const ContentContainer = styledComponents.styled.div(() => ({
|
|
23674
23674
|
overflowY: "auto",
|
|
23675
23675
|
flex: 1,
|
|
23676
23676
|
WebkitOverflowScrolling: "touch",
|
|
@@ -26465,46 +26465,52 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
26465
26465
|
}
|
|
26466
26466
|
}
|
|
26467
26467
|
) }),
|
|
26468
|
-
isOpen && /* @__PURE__ */ jsxRuntime.jsx(Popper$2, { placement, modifiers: modifiers2, children: (popperProps) =>
|
|
26469
|
-
|
|
26470
|
-
{
|
|
26471
|
-
|
|
26472
|
-
|
|
26473
|
-
|
|
26474
|
-
|
|
26475
|
-
|
|
26476
|
-
|
|
26477
|
-
|
|
26478
|
-
|
|
26479
|
-
|
|
26480
|
-
|
|
26481
|
-
|
|
26482
|
-
|
|
26483
|
-
|
|
26484
|
-
},
|
|
26485
|
-
...dropdownMenuContainerEventHandlers({
|
|
26486
|
-
openMenu,
|
|
26487
|
-
closeMenu
|
|
26488
|
-
}),
|
|
26489
|
-
children: [
|
|
26490
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
26491
|
-
PopperArrow,
|
|
26492
|
-
{
|
|
26493
|
-
...popperProps.arrowProps,
|
|
26494
|
-
placement,
|
|
26495
|
-
ref: popperProps.arrowProps.ref,
|
|
26496
|
-
backgroundColor: "white",
|
|
26497
|
-
borderColor: "white"
|
|
26468
|
+
isOpen && /* @__PURE__ */ jsxRuntime.jsx(Popper$2, { placement, modifiers: modifiers2, children: (popperProps) => {
|
|
26469
|
+
const { ref: popperRef, style, placement: popperPlacement } = popperProps;
|
|
26470
|
+
return /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
26471
|
+
DropdownMenuContainer,
|
|
26472
|
+
{
|
|
26473
|
+
dataPlacement: popperPlacement,
|
|
26474
|
+
style,
|
|
26475
|
+
placement,
|
|
26476
|
+
showArrow,
|
|
26477
|
+
...this.menuEventHandlers(),
|
|
26478
|
+
...{
|
|
26479
|
+
ref: (node2) => {
|
|
26480
|
+
if (typeof popperRef === "function") {
|
|
26481
|
+
popperRef(node2);
|
|
26482
|
+
}
|
|
26483
|
+
this.setMenuRef(node2);
|
|
26498
26484
|
}
|
|
26499
|
-
|
|
26500
|
-
|
|
26501
|
-
|
|
26502
|
-
|
|
26503
|
-
|
|
26504
|
-
|
|
26505
|
-
|
|
26506
|
-
|
|
26507
|
-
|
|
26485
|
+
},
|
|
26486
|
+
onMouseDown: (e2) => {
|
|
26487
|
+
e2.preventDefault();
|
|
26488
|
+
e2.target.focus();
|
|
26489
|
+
},
|
|
26490
|
+
...dropdownMenuContainerEventHandlers({
|
|
26491
|
+
openMenu,
|
|
26492
|
+
closeMenu
|
|
26493
|
+
}),
|
|
26494
|
+
children: [
|
|
26495
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
26496
|
+
PopperArrow,
|
|
26497
|
+
{
|
|
26498
|
+
...popperProps.arrowProps,
|
|
26499
|
+
placement,
|
|
26500
|
+
ref: popperProps.arrowProps.ref,
|
|
26501
|
+
backgroundColor: "white",
|
|
26502
|
+
borderColor: "white"
|
|
26503
|
+
}
|
|
26504
|
+
),
|
|
26505
|
+
/* @__PURE__ */ jsxRuntime.jsx(DetectOutsideClick, { onClick: this.handleOutsideClick, clickRef: [this.menuRef, this.triggerRef] }),
|
|
26506
|
+
childrenFnc({
|
|
26507
|
+
closeMenu,
|
|
26508
|
+
openMenu
|
|
26509
|
+
})
|
|
26510
|
+
]
|
|
26511
|
+
}
|
|
26512
|
+
) });
|
|
26513
|
+
} })
|
|
26508
26514
|
] });
|
|
26509
26515
|
}
|
|
26510
26516
|
}
|
|
@@ -26615,7 +26621,6 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
26615
26621
|
}
|
|
26616
26622
|
});
|
|
26617
26623
|
return React.cloneElement(transformedElement, {
|
|
26618
|
-
// eslint-disable-next-line react/no-array-index-key
|
|
26619
26624
|
key: i2
|
|
26620
26625
|
});
|
|
26621
26626
|
});
|
|
@@ -27074,52 +27079,49 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
27074
27079
|
name,
|
|
27075
27080
|
"aria-label": ariaLabel
|
|
27076
27081
|
};
|
|
27077
|
-
return (
|
|
27078
|
-
|
|
27079
|
-
|
|
27080
|
-
|
|
27081
|
-
|
|
27082
|
-
|
|
27083
|
-
|
|
27084
|
-
|
|
27085
|
-
|
|
27086
|
-
|
|
27087
|
-
enabled: true,
|
|
27088
|
-
fn: setDropdownMinWidth
|
|
27089
|
-
},
|
|
27090
|
-
preventOverflow: {
|
|
27091
|
-
enabled: true,
|
|
27092
|
-
padding: 8,
|
|
27093
|
-
boundariesElement: "viewport"
|
|
27094
|
-
}
|
|
27095
|
-
},
|
|
27096
|
-
trigger: () => {
|
|
27097
|
-
const defaultRender = () => /* @__PURE__ */ jsxRuntime.jsx(MenuTriggerButton, { ...triggerProps });
|
|
27098
|
-
return trigger ? trigger({ size: "medium", defaultRender, layer }) : defaultRender();
|
|
27082
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
27083
|
+
NavBarDropdownMenu,
|
|
27084
|
+
{
|
|
27085
|
+
...props,
|
|
27086
|
+
placement: "bottom-start",
|
|
27087
|
+
modifiers: {
|
|
27088
|
+
flip: { behavior: ["bottom"] },
|
|
27089
|
+
setPopperWidth: {
|
|
27090
|
+
enabled: true,
|
|
27091
|
+
fn: setDropdownMinWidth
|
|
27099
27092
|
},
|
|
27100
|
-
|
|
27101
|
-
|
|
27102
|
-
|
|
27103
|
-
|
|
27104
|
-
|
|
27105
|
-
|
|
27106
|
-
|
|
27107
|
-
|
|
27093
|
+
preventOverflow: {
|
|
27094
|
+
enabled: true,
|
|
27095
|
+
padding: 8,
|
|
27096
|
+
boundariesElement: "viewport"
|
|
27097
|
+
}
|
|
27098
|
+
},
|
|
27099
|
+
trigger: () => {
|
|
27100
|
+
const defaultRender = () => /* @__PURE__ */ jsxRuntime.jsx(MenuTriggerButton, { ...triggerProps });
|
|
27101
|
+
return trigger ? trigger({ size: "medium", defaultRender, layer }) : defaultRender();
|
|
27102
|
+
},
|
|
27103
|
+
children: ({ closeMenu }) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
27104
|
+
"ul",
|
|
27105
|
+
{
|
|
27106
|
+
style: {
|
|
27107
|
+
listStyle: "none",
|
|
27108
|
+
margin: "0",
|
|
27109
|
+
padding: "0",
|
|
27110
|
+
minWidth: dropdownMinWidth
|
|
27111
|
+
},
|
|
27112
|
+
children: renderSubMenuItems(
|
|
27113
|
+
menuData,
|
|
27114
|
+
(e2) => {
|
|
27115
|
+
closeMenu(e2);
|
|
27116
|
+
e2.stopPropagation();
|
|
27108
27117
|
},
|
|
27109
|
-
|
|
27110
|
-
|
|
27111
|
-
|
|
27112
|
-
|
|
27113
|
-
|
|
27114
|
-
|
|
27115
|
-
|
|
27116
|
-
layer + 1,
|
|
27117
|
-
menuType
|
|
27118
|
-
)
|
|
27119
|
-
}
|
|
27120
|
-
)
|
|
27121
|
-
}
|
|
27122
|
-
)
|
|
27118
|
+
SubMenuTrigger,
|
|
27119
|
+
layer + 1,
|
|
27120
|
+
menuType
|
|
27121
|
+
)
|
|
27122
|
+
}
|
|
27123
|
+
)
|
|
27124
|
+
}
|
|
27123
27125
|
);
|
|
27124
27126
|
};
|
|
27125
27127
|
const getSharedStyles$1 = (color2, theme) => {
|
|
@@ -27819,7 +27821,6 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
27819
27821
|
href: menuItem.href,
|
|
27820
27822
|
as: menuItem.as,
|
|
27821
27823
|
to: menuItem.to,
|
|
27822
|
-
// eslint-disable-next-line no-mixed-operators
|
|
27823
27824
|
pl: layer === 0 ? getPaddingLeft(layer) : `${24 * layer + 20}px`,
|
|
27824
27825
|
mb: "x1",
|
|
27825
27826
|
target: menuItem.openInNew ? "_blank" : void 0
|
|
@@ -40620,10 +40621,7 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
40620
40621
|
/* @__PURE__ */ jsxRuntime.jsx(Flex, { px: "half", alignItems: "flex-end", alignSelf: "flex-end", children: /* @__PURE__ */ jsxRuntime.jsx(Text, { lineHeight: variant2 === "touch" ? "56px" : "38px", children: "-" }) }),
|
|
40621
40622
|
/* @__PURE__ */ jsxRuntime.jsx(Flex, { children: endComponent })
|
|
40622
40623
|
] }),
|
|
40623
|
-
errorMessages.map((errorMessage, i2) => (
|
|
40624
|
-
// eslint-disable-next-line react/no-array-index-key
|
|
40625
|
-
/* @__PURE__ */ jsxRuntime.jsx(InlineValidation, { errorMessage }, i2)
|
|
40626
|
-
))
|
|
40624
|
+
errorMessages.map((errorMessage, i2) => /* @__PURE__ */ jsxRuntime.jsx(InlineValidation, { errorMessage }, i2))
|
|
40627
40625
|
] });
|
|
40628
40626
|
};
|
|
40629
40627
|
const START_DATE_CLASS = "nds-datepicker-day--start-date";
|
|
@@ -44666,7 +44664,7 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
44666
44664
|
}
|
|
44667
44665
|
`;
|
|
44668
44666
|
const Button = React.forwardRef(
|
|
44669
|
-
({ onPointerEnter
|
|
44667
|
+
({ onPointerEnter, onPointerLeave, onPointerMove, ...props }, forwardedRef) => {
|
|
44670
44668
|
return /* @__PURE__ */ jsxRuntime.jsx("button", { ...props, ref: forwardedRef });
|
|
44671
44669
|
}
|
|
44672
44670
|
);
|