@helpwave/hightide 0.1.18 → 0.1.20
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/components/branding/HelpwaveBadge.js +7 -7
- package/dist/components/branding/HelpwaveBadge.js.map +1 -1
- package/dist/components/branding/HelpwaveBadge.mjs +7 -7
- package/dist/components/branding/HelpwaveBadge.mjs.map +1 -1
- package/dist/components/date/DatePicker.js +67 -39
- package/dist/components/date/DatePicker.js.map +1 -1
- package/dist/components/date/DatePicker.mjs +56 -28
- package/dist/components/date/DatePicker.mjs.map +1 -1
- package/dist/components/date/DayPicker.js +3 -3
- package/dist/components/date/DayPicker.js.map +1 -1
- package/dist/components/date/DayPicker.mjs +3 -3
- package/dist/components/date/DayPicker.mjs.map +1 -1
- package/dist/components/date/TimePicker.js +4 -4
- package/dist/components/date/TimePicker.js.map +1 -1
- package/dist/components/date/TimePicker.mjs +4 -4
- package/dist/components/date/TimePicker.mjs.map +1 -1
- package/dist/components/date/YearMonthPicker.js +48 -20
- package/dist/components/date/YearMonthPicker.js.map +1 -1
- package/dist/components/date/YearMonthPicker.mjs +46 -18
- package/dist/components/date/YearMonthPicker.mjs.map +1 -1
- package/dist/components/dialogs/ConfirmDialog.js +32 -28
- package/dist/components/dialogs/ConfirmDialog.js.map +1 -1
- package/dist/components/dialogs/ConfirmDialog.mjs +18 -14
- package/dist/components/dialogs/ConfirmDialog.mjs.map +1 -1
- package/dist/components/icons-and-geometry/Avatar.js +2 -2
- package/dist/components/icons-and-geometry/Avatar.js.map +1 -1
- package/dist/components/icons-and-geometry/Avatar.mjs +2 -2
- package/dist/components/icons-and-geometry/Avatar.mjs.map +1 -1
- package/dist/components/icons-and-geometry/Ring.js +2 -2
- package/dist/components/icons-and-geometry/Ring.js.map +1 -1
- package/dist/components/icons-and-geometry/Ring.mjs +2 -2
- package/dist/components/icons-and-geometry/Ring.mjs.map +1 -1
- package/dist/components/layout-and-navigation/BreadCrumb.js +1 -1
- package/dist/components/layout-and-navigation/BreadCrumb.js.map +1 -1
- package/dist/components/layout-and-navigation/BreadCrumb.mjs +1 -1
- package/dist/components/layout-and-navigation/BreadCrumb.mjs.map +1 -1
- package/dist/components/layout-and-navigation/Carousel.js +84 -15
- package/dist/components/layout-and-navigation/Carousel.js.map +1 -1
- package/dist/components/layout-and-navigation/Carousel.mjs +76 -7
- package/dist/components/layout-and-navigation/Carousel.mjs.map +1 -1
- package/dist/components/layout-and-navigation/Chip.js +1 -1
- package/dist/components/layout-and-navigation/Chip.js.map +1 -1
- package/dist/components/layout-and-navigation/Chip.mjs +1 -1
- package/dist/components/layout-and-navigation/Chip.mjs.map +1 -1
- package/dist/components/layout-and-navigation/Expandable.d.mts +10 -1
- package/dist/components/layout-and-navigation/Expandable.d.ts +10 -1
- package/dist/components/layout-and-navigation/Expandable.js +38 -10
- package/dist/components/layout-and-navigation/Expandable.js.map +1 -1
- package/dist/components/layout-and-navigation/Expandable.mjs +38 -11
- package/dist/components/layout-and-navigation/Expandable.mjs.map +1 -1
- package/dist/components/layout-and-navigation/FAQSection.js +36 -12
- package/dist/components/layout-and-navigation/FAQSection.js.map +1 -1
- package/dist/components/layout-and-navigation/FAQSection.mjs +38 -14
- package/dist/components/layout-and-navigation/FAQSection.mjs.map +1 -1
- package/dist/components/layout-and-navigation/Overlay.js +92 -19
- package/dist/components/layout-and-navigation/Overlay.js.map +1 -1
- package/dist/components/layout-and-navigation/Overlay.mjs +81 -8
- package/dist/components/layout-and-navigation/Overlay.mjs.map +1 -1
- package/dist/components/layout-and-navigation/Pagination.js +82 -9
- package/dist/components/layout-and-navigation/Pagination.js.map +1 -1
- package/dist/components/layout-and-navigation/Pagination.mjs +79 -6
- package/dist/components/layout-and-navigation/Pagination.mjs.map +1 -1
- package/dist/components/layout-and-navigation/SearchableList.js +127 -25
- package/dist/components/layout-and-navigation/SearchableList.js.map +1 -1
- package/dist/components/layout-and-navigation/SearchableList.mjs +126 -24
- package/dist/components/layout-and-navigation/SearchableList.mjs.map +1 -1
- package/dist/components/layout-and-navigation/StepperBar.js +22 -16
- package/dist/components/layout-and-navigation/StepperBar.js.map +1 -1
- package/dist/components/layout-and-navigation/StepperBar.mjs +19 -13
- package/dist/components/layout-and-navigation/StepperBar.mjs.map +1 -1
- package/dist/components/layout-and-navigation/TextImage.js +7 -3
- package/dist/components/layout-and-navigation/TextImage.js.map +1 -1
- package/dist/components/layout-and-navigation/TextImage.mjs +7 -3
- package/dist/components/layout-and-navigation/TextImage.mjs.map +1 -1
- package/dist/components/layout-and-navigation/Tile.d.mts +2 -2
- package/dist/components/layout-and-navigation/Tile.d.ts +2 -2
- package/dist/components/layout-and-navigation/Tile.js +7 -7
- package/dist/components/layout-and-navigation/Tile.js.map +1 -1
- package/dist/components/layout-and-navigation/Tile.mjs +7 -7
- package/dist/components/layout-and-navigation/Tile.mjs.map +1 -1
- package/dist/components/loading-states/ErrorComponent.js +1 -1
- package/dist/components/loading-states/ErrorComponent.js.map +1 -1
- package/dist/components/loading-states/ErrorComponent.mjs +1 -1
- package/dist/components/loading-states/ErrorComponent.mjs.map +1 -1
- package/dist/components/loading-states/LoadingAndErrorComponent.d.mts +5 -10
- package/dist/components/loading-states/LoadingAndErrorComponent.d.ts +5 -10
- package/dist/components/loading-states/LoadingAndErrorComponent.js +14 -327
- package/dist/components/loading-states/LoadingAndErrorComponent.js.map +1 -1
- package/dist/components/loading-states/LoadingAndErrorComponent.mjs +15 -318
- package/dist/components/loading-states/LoadingAndErrorComponent.mjs.map +1 -1
- package/dist/components/loading-states/LoadingAnimation.js +5 -1
- package/dist/components/loading-states/LoadingAnimation.js.map +1 -1
- package/dist/components/loading-states/LoadingAnimation.mjs +5 -1
- package/dist/components/loading-states/LoadingAnimation.mjs.map +1 -1
- package/dist/components/loading-states/LoadingButton.js +8 -6
- package/dist/components/loading-states/LoadingButton.js.map +1 -1
- package/dist/components/loading-states/LoadingButton.mjs +8 -6
- package/dist/components/loading-states/LoadingButton.mjs.map +1 -1
- package/dist/components/loading-states/LoadingContainer.d.mts +8 -0
- package/dist/components/loading-states/LoadingContainer.d.ts +8 -0
- package/dist/components/loading-states/LoadingContainer.js +34 -0
- package/dist/components/loading-states/LoadingContainer.js.map +1 -0
- package/dist/components/loading-states/LoadingContainer.mjs +10 -0
- package/dist/components/loading-states/LoadingContainer.mjs.map +1 -0
- package/dist/components/modals/ConfirmModal.js +32 -28
- package/dist/components/modals/ConfirmModal.js.map +1 -1
- package/dist/components/modals/ConfirmModal.mjs +18 -14
- package/dist/components/modals/ConfirmModal.mjs.map +1 -1
- package/dist/components/modals/DiscardChangesModal.js +28 -24
- package/dist/components/modals/DiscardChangesModal.js.map +1 -1
- package/dist/components/modals/DiscardChangesModal.mjs +18 -14
- package/dist/components/modals/DiscardChangesModal.mjs.map +1 -1
- package/dist/components/modals/InputModal.js +32 -28
- package/dist/components/modals/InputModal.js.map +1 -1
- package/dist/components/modals/InputModal.mjs +18 -14
- package/dist/components/modals/InputModal.mjs.map +1 -1
- package/dist/components/modals/LanguageModal.js +729 -434
- package/dist/components/modals/LanguageModal.js.map +1 -1
- package/dist/components/modals/LanguageModal.mjs +729 -430
- package/dist/components/modals/LanguageModal.mjs.map +1 -1
- package/dist/components/modals/ThemeModal.js +733 -438
- package/dist/components/modals/ThemeModal.js.map +1 -1
- package/dist/components/modals/ThemeModal.mjs +732 -433
- package/dist/components/modals/ThemeModal.mjs.map +1 -1
- package/dist/components/properties/CheckboxProperty.js +110 -35
- package/dist/components/properties/CheckboxProperty.js.map +1 -1
- package/dist/components/properties/CheckboxProperty.mjs +110 -35
- package/dist/components/properties/CheckboxProperty.mjs.map +1 -1
- package/dist/components/properties/DateProperty.js +118 -41
- package/dist/components/properties/DateProperty.js.map +1 -1
- package/dist/components/properties/DateProperty.mjs +114 -37
- package/dist/components/properties/DateProperty.mjs.map +1 -1
- package/dist/components/properties/MultiSelectProperty.d.mts +10 -3
- package/dist/components/properties/MultiSelectProperty.d.ts +10 -3
- package/dist/components/properties/MultiSelectProperty.js +916 -463
- package/dist/components/properties/MultiSelectProperty.js.map +1 -1
- package/dist/components/properties/MultiSelectProperty.mjs +921 -464
- package/dist/components/properties/MultiSelectProperty.mjs.map +1 -1
- package/dist/components/properties/NumberProperty.js +101 -18
- package/dist/components/properties/NumberProperty.js.map +1 -1
- package/dist/components/properties/NumberProperty.mjs +101 -18
- package/dist/components/properties/NumberProperty.mjs.map +1 -1
- package/dist/components/properties/PropertyBase.js +103 -20
- package/dist/components/properties/PropertyBase.js.map +1 -1
- package/dist/components/properties/PropertyBase.mjs +99 -16
- package/dist/components/properties/PropertyBase.mjs.map +1 -1
- package/dist/components/properties/SelectProperty.d.mts +9 -2
- package/dist/components/properties/SelectProperty.d.ts +9 -2
- package/dist/components/properties/SelectProperty.js +683 -243
- package/dist/components/properties/SelectProperty.js.map +1 -1
- package/dist/components/properties/SelectProperty.mjs +687 -243
- package/dist/components/properties/SelectProperty.mjs.map +1 -1
- package/dist/components/properties/TextProperty.js +133 -46
- package/dist/components/properties/TextProperty.js.map +1 -1
- package/dist/components/properties/TextProperty.mjs +133 -46
- package/dist/components/properties/TextProperty.mjs.map +1 -1
- package/dist/components/table/Table.js +285 -185
- package/dist/components/table/Table.js.map +1 -1
- package/dist/components/table/Table.mjs +270 -166
- package/dist/components/table/Table.mjs.map +1 -1
- package/dist/components/table/TableFilterButton.js +179 -78
- package/dist/components/table/TableFilterButton.js.map +1 -1
- package/dist/components/table/TableFilterButton.mjs +160 -55
- package/dist/components/table/TableFilterButton.mjs.map +1 -1
- package/dist/components/table/TableSortButton.js +72 -3
- package/dist/components/table/TableSortButton.js.map +1 -1
- package/dist/components/table/TableSortButton.mjs +72 -3
- package/dist/components/table/TableSortButton.mjs.map +1 -1
- package/dist/components/user-action/Button.d.mts +15 -2
- package/dist/components/user-action/Button.d.ts +15 -2
- package/dist/components/user-action/Button.js +12 -12
- package/dist/components/user-action/Button.js.map +1 -1
- package/dist/components/user-action/Button.mjs +12 -12
- package/dist/components/user-action/Button.mjs.map +1 -1
- package/dist/components/user-action/Checkbox.js +6 -15
- package/dist/components/user-action/Checkbox.js.map +1 -1
- package/dist/components/user-action/Checkbox.mjs +6 -15
- package/dist/components/user-action/Checkbox.mjs.map +1 -1
- package/dist/components/user-action/CopyToClipboardWrapper.js +6 -2
- package/dist/components/user-action/CopyToClipboardWrapper.js.map +1 -1
- package/dist/components/user-action/CopyToClipboardWrapper.mjs +6 -2
- package/dist/components/user-action/CopyToClipboardWrapper.mjs.map +1 -1
- package/dist/components/user-action/DateAndTimePicker.js +81 -49
- package/dist/components/user-action/DateAndTimePicker.js.map +1 -1
- package/dist/components/user-action/DateAndTimePicker.mjs +67 -35
- package/dist/components/user-action/DateAndTimePicker.mjs.map +1 -1
- package/dist/components/user-action/Menu.d.mts +11 -6
- package/dist/components/user-action/Menu.d.ts +11 -6
- package/dist/components/user-action/Menu.js +128 -31
- package/dist/components/user-action/Menu.js.map +1 -1
- package/dist/components/user-action/Menu.mjs +134 -33
- package/dist/components/user-action/Menu.mjs.map +1 -1
- package/dist/components/user-action/MultiSelect.d.mts +17 -7
- package/dist/components/user-action/MultiSelect.d.ts +17 -7
- package/dist/components/user-action/MultiSelect.js +797 -375
- package/dist/components/user-action/MultiSelect.js.map +1 -1
- package/dist/components/user-action/MultiSelect.mjs +782 -356
- package/dist/components/user-action/MultiSelect.mjs.map +1 -1
- package/dist/components/user-action/ScrollPicker.js +2 -2
- package/dist/components/user-action/ScrollPicker.js.map +1 -1
- package/dist/components/user-action/ScrollPicker.mjs +2 -2
- package/dist/components/user-action/ScrollPicker.mjs.map +1 -1
- package/dist/components/user-action/SearchBar.d.mts +14 -0
- package/dist/components/user-action/SearchBar.d.ts +14 -0
- package/dist/components/user-action/SearchBar.js +673 -0
- package/dist/components/user-action/SearchBar.js.map +1 -0
- package/dist/components/user-action/SearchBar.mjs +637 -0
- package/dist/components/user-action/SearchBar.mjs.map +1 -0
- package/dist/components/user-action/Select.d.mts +18 -5
- package/dist/components/user-action/Select.d.ts +18 -5
- package/dist/components/user-action/Select.js +765 -355
- package/dist/components/user-action/Select.js.map +1 -1
- package/dist/components/user-action/Select.mjs +762 -349
- package/dist/components/user-action/Select.mjs.map +1 -1
- package/dist/components/user-action/Textarea.d.mts +1 -1
- package/dist/components/user-action/Textarea.d.ts +1 -1
- package/dist/components/user-action/Textarea.js +13 -3
- package/dist/components/user-action/Textarea.js.map +1 -1
- package/dist/components/user-action/Textarea.mjs +13 -3
- package/dist/components/user-action/Textarea.mjs.map +1 -1
- package/dist/components/user-action/ToggleableInput.js +2 -2
- package/dist/components/user-action/ToggleableInput.js.map +1 -1
- package/dist/components/user-action/ToggleableInput.mjs +2 -2
- package/dist/components/user-action/ToggleableInput.mjs.map +1 -1
- package/dist/css/globals.css +284 -113
- package/dist/css/uncompiled/globals.css +19 -13
- package/dist/css/uncompiled/theme/colors-component.css +12 -3
- package/dist/css/uncompiled/theme/colors-semantic.css +10 -7
- package/dist/css/uncompiled/utitlity/animation.css +96 -1
- package/dist/css/uncompiled/utitlity/general.css +16 -0
- package/dist/hooks/usePopoverPosition.d.mts +15 -0
- package/dist/hooks/usePopoverPosition.d.ts +15 -0
- package/dist/hooks/usePopoverPosition.js +81 -0
- package/dist/hooks/usePopoverPosition.js.map +1 -0
- package/dist/hooks/usePopoverPosition.mjs +57 -0
- package/dist/hooks/usePopoverPosition.mjs.map +1 -0
- package/dist/hooks/useSearch.d.mts +7 -2
- package/dist/hooks/useSearch.d.ts +7 -2
- package/dist/hooks/useSearch.js +44 -15
- package/dist/hooks/useSearch.js.map +1 -1
- package/dist/hooks/useSearch.mjs +45 -16
- package/dist/hooks/useSearch.mjs.map +1 -1
- package/dist/index.d.mts +7 -4
- package/dist/index.d.ts +7 -4
- package/dist/index.js +1197 -902
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1048 -754
- package/dist/index.mjs.map +1 -1
- package/dist/localization/defaults/form.d.mts +2 -0
- package/dist/localization/defaults/form.d.ts +2 -0
- package/dist/localization/defaults/form.js +4 -0
- package/dist/localization/defaults/form.js.map +1 -1
- package/dist/localization/defaults/form.mjs +4 -0
- package/dist/localization/defaults/form.mjs.map +1 -1
- package/dist/util/simpleSearch.d.mts +1 -1
- package/dist/util/simpleSearch.d.ts +1 -1
- package/dist/util/simpleSearch.js +4 -1
- package/dist/util/simpleSearch.js.map +1 -1
- package/dist/util/simpleSearch.mjs +4 -1
- package/dist/util/simpleSearch.mjs.map +1 -1
- package/package.json +1 -1
|
@@ -272,6 +272,7 @@ var getWeeksForCalenderMonth = (date, weekStart, weeks = 6) => {
|
|
|
272
272
|
};
|
|
273
273
|
|
|
274
274
|
// src/components/user-action/Button.tsx
|
|
275
|
+
var import_react3 = require("react");
|
|
275
276
|
var import_clsx = __toESM(require("clsx"));
|
|
276
277
|
var import_jsx_runtime2 = require("react/jsx-runtime");
|
|
277
278
|
var ButtonColorUtil = {
|
|
@@ -297,7 +298,7 @@ var ButtonUtil = {
|
|
|
297
298
|
paddingMapping,
|
|
298
299
|
iconPaddingMapping
|
|
299
300
|
};
|
|
300
|
-
var SolidButton = ({
|
|
301
|
+
var SolidButton = (0, import_react3.forwardRef)(function SolidButton2({
|
|
301
302
|
children,
|
|
302
303
|
disabled = false,
|
|
303
304
|
color = "primary",
|
|
@@ -307,7 +308,7 @@ var SolidButton = ({
|
|
|
307
308
|
onClick,
|
|
308
309
|
className,
|
|
309
310
|
...restProps
|
|
310
|
-
})
|
|
311
|
+
}, ref) {
|
|
311
312
|
const colorClasses = {
|
|
312
313
|
primary: "bg-button-solid-primary-background text-button-solid-primary-text",
|
|
313
314
|
secondary: "bg-button-solid-secondary-background text-button-solid-secondary-text",
|
|
@@ -329,8 +330,9 @@ var SolidButton = ({
|
|
|
329
330
|
return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(
|
|
330
331
|
"button",
|
|
331
332
|
{
|
|
332
|
-
|
|
333
|
-
|
|
333
|
+
ref,
|
|
334
|
+
onClick,
|
|
335
|
+
disabled,
|
|
334
336
|
className: (0, import_clsx.default)(
|
|
335
337
|
{
|
|
336
338
|
"text-disabled-text bg-disabled-background cursor-not-allowed": disabled,
|
|
@@ -365,7 +367,7 @@ var SolidButton = ({
|
|
|
365
367
|
]
|
|
366
368
|
}
|
|
367
369
|
);
|
|
368
|
-
};
|
|
370
|
+
});
|
|
369
371
|
var TextButton = ({
|
|
370
372
|
children,
|
|
371
373
|
disabled = false,
|
|
@@ -390,8 +392,8 @@ var TextButton = ({
|
|
|
390
392
|
return /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(
|
|
391
393
|
"button",
|
|
392
394
|
{
|
|
393
|
-
onClick
|
|
394
|
-
disabled
|
|
395
|
+
onClick,
|
|
396
|
+
disabled,
|
|
395
397
|
className: (0, import_clsx.default)(
|
|
396
398
|
{
|
|
397
399
|
"text-disabled-text cursor-not-allowed": disabled,
|
|
@@ -429,7 +431,7 @@ var TextButton = ({
|
|
|
429
431
|
};
|
|
430
432
|
|
|
431
433
|
// src/components/date/TimePicker.tsx
|
|
432
|
-
var
|
|
434
|
+
var import_react4 = require("react");
|
|
433
435
|
var import_react_custom_scrollbars_2 = require("react-custom-scrollbars-2");
|
|
434
436
|
var import_clsx2 = __toESM(require("clsx"));
|
|
435
437
|
var import_jsx_runtime3 = require("react/jsx-runtime");
|
|
@@ -441,12 +443,12 @@ var TimePicker = ({
|
|
|
441
443
|
maxHeight = 300,
|
|
442
444
|
className = ""
|
|
443
445
|
}) => {
|
|
444
|
-
const minuteRef = (0,
|
|
445
|
-
const hourRef = (0,
|
|
446
|
+
const minuteRef = (0, import_react4.useRef)(null);
|
|
447
|
+
const hourRef = (0, import_react4.useRef)(null);
|
|
446
448
|
const isPM = time.getHours() >= 11;
|
|
447
449
|
const hours = is24HourFormat ? range(24) : range([1, 12], { exclusiveEnd: false });
|
|
448
450
|
let minutes = range(60);
|
|
449
|
-
(0,
|
|
451
|
+
(0, import_react4.useEffect)(() => {
|
|
450
452
|
const scrollToItem = () => {
|
|
451
453
|
if (minuteRef.current) {
|
|
452
454
|
const container = minuteRef.current.parentElement;
|
|
@@ -461,7 +463,7 @@ var TimePicker = ({
|
|
|
461
463
|
};
|
|
462
464
|
scrollToItem();
|
|
463
465
|
}, [minuteRef, minuteRef.current]);
|
|
464
|
-
(0,
|
|
466
|
+
(0, import_react4.useEffect)(() => {
|
|
465
467
|
const scrollToItem = () => {
|
|
466
468
|
if (hourRef.current) {
|
|
467
469
|
const container = hourRef.current.parentElement;
|
|
@@ -500,8 +502,8 @@ var TimePicker = ({
|
|
|
500
502
|
transformer(newDate);
|
|
501
503
|
onChange(newDate);
|
|
502
504
|
};
|
|
503
|
-
return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("div", { className: (0, import_clsx2.default)("row
|
|
504
|
-
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_react_custom_scrollbars_2.Scrollbars, { autoHeight: true, autoHeightMax: maxHeight, style: { height: "100%" }, children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("div", { className: "col
|
|
505
|
+
return /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("div", { className: (0, import_clsx2.default)("flex-row-2 w-fit min-w-[150px] select-none", className), children: [
|
|
506
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_react_custom_scrollbars_2.Scrollbars, { autoHeight: true, autoHeightMax: maxHeight, style: { height: "100%" }, children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("div", { className: "flex-col-1 h-full", children: hours.map((hour) => {
|
|
505
507
|
const currentHour = hour === time.getHours() - (!is24HourFormat && isPM ? 12 : 0);
|
|
506
508
|
return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
507
509
|
"button",
|
|
@@ -514,7 +516,7 @@ var TimePicker = ({
|
|
|
514
516
|
hour
|
|
515
517
|
);
|
|
516
518
|
}) }) }),
|
|
517
|
-
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_react_custom_scrollbars_2.Scrollbars, { autoHeight: true, autoHeightMax: maxHeight, style: { height: "100%" }, children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("div", { className: "col
|
|
519
|
+
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_react_custom_scrollbars_2.Scrollbars, { autoHeight: true, autoHeightMax: maxHeight, style: { height: "100%" }, children: /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("div", { className: "flex-col-1 h-full", children: minutes.map((minute) => {
|
|
518
520
|
const currentMinute = minute === closestMinute;
|
|
519
521
|
return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
520
522
|
"button",
|
|
@@ -527,7 +529,7 @@ var TimePicker = ({
|
|
|
527
529
|
minute + minuteIncrement
|
|
528
530
|
);
|
|
529
531
|
}) }) }),
|
|
530
|
-
!is24HourFormat && /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("div", { className: "col
|
|
532
|
+
!is24HourFormat && /* @__PURE__ */ (0, import_jsx_runtime3.jsxs)("div", { className: "flex-col-1", children: [
|
|
531
533
|
/* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
|
|
532
534
|
"button",
|
|
533
535
|
{
|
|
@@ -549,22 +551,33 @@ var TimePicker = ({
|
|
|
549
551
|
};
|
|
550
552
|
|
|
551
553
|
// src/components/date/DatePicker.tsx
|
|
552
|
-
var
|
|
554
|
+
var import_react8 = require("react");
|
|
553
555
|
var import_lucide_react2 = require("lucide-react");
|
|
554
556
|
var import_clsx6 = __toESM(require("clsx"));
|
|
555
557
|
|
|
556
558
|
// src/components/date/YearMonthPicker.tsx
|
|
557
|
-
var
|
|
559
|
+
var import_react6 = require("react");
|
|
558
560
|
var import_react_custom_scrollbars_22 = require("react-custom-scrollbars-2");
|
|
559
561
|
var import_clsx4 = __toESM(require("clsx"));
|
|
560
562
|
|
|
561
563
|
// src/components/layout-and-navigation/Expandable.tsx
|
|
562
|
-
var
|
|
564
|
+
var import_react5 = require("react");
|
|
563
565
|
var import_lucide_react = require("lucide-react");
|
|
564
566
|
var import_clsx3 = __toESM(require("clsx"));
|
|
565
567
|
var import_jsx_runtime4 = require("react/jsx-runtime");
|
|
566
|
-
var
|
|
567
|
-
|
|
568
|
+
var ExpansionIcon = ({ isExpanded, className }) => {
|
|
569
|
+
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
570
|
+
import_lucide_react.ChevronDown,
|
|
571
|
+
{
|
|
572
|
+
className: (0, import_clsx3.default)(
|
|
573
|
+
"min-w-6 w-6 min-h-6 h-6 transition-transform duration-200 ease-in-out",
|
|
574
|
+
{ "rotate-180": isExpanded },
|
|
575
|
+
className
|
|
576
|
+
)
|
|
577
|
+
}
|
|
578
|
+
);
|
|
579
|
+
};
|
|
580
|
+
var Expandable = (0, import_react5.forwardRef)(function Expandable2({
|
|
568
581
|
children,
|
|
569
582
|
label,
|
|
570
583
|
icon,
|
|
@@ -574,24 +587,26 @@ var Expandable = (0, import_react4.forwardRef)(function Expandable2({
|
|
|
574
587
|
disabled = false,
|
|
575
588
|
className,
|
|
576
589
|
headerClassName,
|
|
577
|
-
contentClassName
|
|
590
|
+
contentClassName,
|
|
591
|
+
contentExpandedClassName
|
|
578
592
|
}, ref) {
|
|
579
|
-
|
|
593
|
+
const defaultIcon = (0, import_react5.useCallback)((expanded) => /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(ExpansionIcon, { isExpanded: expanded }), []);
|
|
594
|
+
icon ??= defaultIcon;
|
|
580
595
|
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
|
|
581
596
|
"div",
|
|
582
597
|
{
|
|
583
598
|
ref,
|
|
584
|
-
className: (0, import_clsx3.default)("col
|
|
599
|
+
className: (0, import_clsx3.default)("flex-col-0 bg-surface text-on-surface group rounded-lg shadow-sm", { "cursor-pointer": !clickOnlyOnHeader && !disabled }, className),
|
|
585
600
|
onClick: () => !clickOnlyOnHeader && !disabled && onChange(!isExpanded),
|
|
586
601
|
children: [
|
|
587
602
|
/* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
|
|
588
603
|
"div",
|
|
589
604
|
{
|
|
590
605
|
className: (0, import_clsx3.default)(
|
|
591
|
-
"row py-2 px-4 rounded-lg justify-between items-center bg-surface text-on-surface select-none",
|
|
606
|
+
"flex-row-2 py-2 px-4 rounded-lg justify-between items-center bg-surface text-on-surface select-none",
|
|
592
607
|
{
|
|
593
|
-
"group-hover:brightness-
|
|
594
|
-
"hover:brightness-
|
|
608
|
+
"group-hover:brightness-97": !isExpanded,
|
|
609
|
+
"hover:brightness-97": isExpanded && !disabled,
|
|
595
610
|
"cursor-pointer": clickOnlyOnHeader && !disabled
|
|
596
611
|
},
|
|
597
612
|
headerClassName
|
|
@@ -603,18 +618,31 @@ var Expandable = (0, import_react4.forwardRef)(function Expandable2({
|
|
|
603
618
|
]
|
|
604
619
|
}
|
|
605
620
|
),
|
|
606
|
-
|
|
621
|
+
/* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
622
|
+
"div",
|
|
623
|
+
{
|
|
624
|
+
className: (0, import_clsx3.default)(
|
|
625
|
+
"flex-col-2 px-4 transition-all duration-300 ease-in-out",
|
|
626
|
+
{
|
|
627
|
+
[(0, import_clsx3.default)("max-h-96 opacity-100 pb-2 overflow-y-auto", contentExpandedClassName)]: isExpanded,
|
|
628
|
+
"max-h-0 opacity-0 overflow-hidden": !isExpanded
|
|
629
|
+
},
|
|
630
|
+
contentClassName
|
|
631
|
+
),
|
|
632
|
+
children
|
|
633
|
+
}
|
|
634
|
+
)
|
|
607
635
|
]
|
|
608
636
|
}
|
|
609
637
|
);
|
|
610
638
|
});
|
|
611
|
-
var ExpandableUncontrolled = (0,
|
|
639
|
+
var ExpandableUncontrolled = (0, import_react5.forwardRef)(function ExpandableUncontrolled2({
|
|
612
640
|
isExpanded,
|
|
613
641
|
onChange = noop,
|
|
614
642
|
...props
|
|
615
643
|
}, ref) {
|
|
616
|
-
const [usedIsExpanded, setUsedIsExpanded] = (0,
|
|
617
|
-
(0,
|
|
644
|
+
const [usedIsExpanded, setUsedIsExpanded] = (0, import_react5.useState)(isExpanded);
|
|
645
|
+
(0, import_react5.useEffect)(() => {
|
|
618
646
|
setUsedIsExpanded(isExpanded);
|
|
619
647
|
}, [isExpanded]);
|
|
620
648
|
return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
|
|
@@ -643,8 +671,8 @@ var YearMonthPicker = ({
|
|
|
643
671
|
showValueOpen = true
|
|
644
672
|
}) => {
|
|
645
673
|
const locale = useLocale();
|
|
646
|
-
const ref = (0,
|
|
647
|
-
(0,
|
|
674
|
+
const ref = (0, import_react6.useRef)(null);
|
|
675
|
+
(0, import_react6.useEffect)(() => {
|
|
648
676
|
const scrollToItem = () => {
|
|
649
677
|
if (ref.current) {
|
|
650
678
|
ref.current.scrollIntoView({
|
|
@@ -660,7 +688,7 @@ var YearMonthPicker = ({
|
|
|
660
688
|
return null;
|
|
661
689
|
}
|
|
662
690
|
const years = range([start.getFullYear(), end.getFullYear()], { exclusiveEnd: false });
|
|
663
|
-
return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("div", { className: (0, import_clsx4.default)("col select-none", className), children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_react_custom_scrollbars_22.Scrollbars, { autoHeight: true, autoHeightMax: maxHeight, style: { height: "100%" }, children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("div", { className: "col
|
|
691
|
+
return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("div", { className: (0, import_clsx4.default)("flex-col-0 select-none", className), children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(import_react_custom_scrollbars_22.Scrollbars, { autoHeight: true, autoHeightMax: maxHeight, style: { height: "100%" }, children: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("div", { className: "flex-col-1 mr-3", children: years.map((year) => {
|
|
664
692
|
const selectedYear = displayedYearMonth.getFullYear() === year;
|
|
665
693
|
return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
|
|
666
694
|
ExpandableUncontrolled,
|
|
@@ -669,7 +697,7 @@ var YearMonthPicker = ({
|
|
|
669
697
|
label: /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("span", { className: (0, import_clsx4.default)({ "text-primary font-bold": selectedYear }), children: year }),
|
|
670
698
|
isExpanded: showValueOpen && selectedYear,
|
|
671
699
|
contentClassName: "gap-y-1",
|
|
672
|
-
children: equalSizeGroups([...monthsList], 3).map((monthList, index) => /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("div", { className: "row
|
|
700
|
+
children: equalSizeGroups([...monthsList], 3).map((monthList, index) => /* @__PURE__ */ (0, import_jsx_runtime5.jsx)("div", { className: "flex-row-1", children: monthList.map((month) => {
|
|
673
701
|
const monthIndex = monthsList.indexOf(month);
|
|
674
702
|
const newDate = new Date(year, monthIndex);
|
|
675
703
|
const selectedMonth = selectedYear && monthIndex === displayedYearMonth.getMonth();
|
|
@@ -701,7 +729,7 @@ var YearMonthPicker = ({
|
|
|
701
729
|
|
|
702
730
|
// src/components/date/DayPicker.tsx
|
|
703
731
|
var import_clsx5 = __toESM(require("clsx"));
|
|
704
|
-
var
|
|
732
|
+
var import_react7 = require("react");
|
|
705
733
|
var import_jsx_runtime6 = require("react/jsx-runtime");
|
|
706
734
|
var DayPicker = ({
|
|
707
735
|
displayedMonth,
|
|
@@ -716,9 +744,9 @@ var DayPicker = ({
|
|
|
716
744
|
const locale = useLocale();
|
|
717
745
|
const month = displayedMonth.getMonth();
|
|
718
746
|
const weeks = getWeeksForCalenderMonth(displayedMonth, weekStart);
|
|
719
|
-
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: (0, import_clsx5.default)("col
|
|
720
|
-
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { className: "row text-center", children: weeks[0].map((weekDay, index) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { className: "flex-1 font-semibold", children: new Intl.DateTimeFormat(locale, { weekday: "long" }).format(weekDay).substring(0, 2) }, index)) }),
|
|
721
|
-
weeks.map((week, index) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { className: "row text-center", children: week.map((date) => {
|
|
747
|
+
return /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)("div", { className: (0, import_clsx5.default)("flex-col-1 min-w-[220px] select-none", className), children: [
|
|
748
|
+
/* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { className: "flex-row-2 text-center", children: weeks[0].map((weekDay, index) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { className: "flex-1 font-semibold", children: new Intl.DateTimeFormat(locale, { weekday: "long" }).format(weekDay).substring(0, 2) }, index)) }),
|
|
749
|
+
weeks.map((week, index) => /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("div", { className: "flex-row-2 text-center", children: week.map((date) => {
|
|
722
750
|
const isSelected = !!selected && equalDate(selected, date);
|
|
723
751
|
const isToday = equalDate(/* @__PURE__ */ new Date(), date);
|
|
724
752
|
const isSameMonth = date.getMonth() === month;
|
|
@@ -835,17 +863,17 @@ var DatePicker = ({
|
|
|
835
863
|
}) => {
|
|
836
864
|
const locale = useLocale();
|
|
837
865
|
const translation = useTranslation([timeTranslation], overwriteTranslation);
|
|
838
|
-
const [displayedMonth, setDisplayedMonth] = (0,
|
|
839
|
-
const [displayMode, setDisplayMode] = (0,
|
|
840
|
-
(0,
|
|
866
|
+
const [displayedMonth, setDisplayedMonth] = (0, import_react8.useState)(value);
|
|
867
|
+
const [displayMode, setDisplayMode] = (0, import_react8.useState)(initialDisplay);
|
|
868
|
+
(0, import_react8.useEffect)(() => {
|
|
841
869
|
setDisplayedMonth(value);
|
|
842
870
|
}, [value]);
|
|
843
|
-
return /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)("div", { className: (0, import_clsx6.default)("col
|
|
844
|
-
/* @__PURE__ */ (0, import_jsx_runtime7.jsxs)("div", { className: "row items-center justify-between h-7", children: [
|
|
871
|
+
return /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)("div", { className: (0, import_clsx6.default)("flex-col-4", className), children: [
|
|
872
|
+
/* @__PURE__ */ (0, import_jsx_runtime7.jsxs)("div", { className: "flex-row-2 items-center justify-between h-7", children: [
|
|
845
873
|
/* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(
|
|
846
874
|
TextButton,
|
|
847
875
|
{
|
|
848
|
-
className: (0, import_clsx6.default)("row
|
|
876
|
+
className: (0, import_clsx6.default)("flex-row-1 items-center cursor-pointer select-none", {
|
|
849
877
|
"text-disabled-text": displayMode !== "day"
|
|
850
878
|
}),
|
|
851
879
|
onClick: () => setDisplayMode(displayMode === "day" ? "yearMonth" : "day"),
|
|
@@ -855,7 +883,7 @@ var DatePicker = ({
|
|
|
855
883
|
]
|
|
856
884
|
}
|
|
857
885
|
),
|
|
858
|
-
displayMode === "day" && /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)("div", { className: "row justify-end", children: [
|
|
886
|
+
displayMode === "day" && /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)("div", { className: "flex-row-2 justify-end", children: [
|
|
859
887
|
/* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
|
|
860
888
|
SolidButton,
|
|
861
889
|
{
|
|
@@ -927,6 +955,7 @@ var DatePicker = ({
|
|
|
927
955
|
// src/localization/defaults/form.ts
|
|
928
956
|
var formTranslation = {
|
|
929
957
|
en: {
|
|
958
|
+
add: "Add",
|
|
930
959
|
all: "All",
|
|
931
960
|
apply: "Apply",
|
|
932
961
|
back: "Back",
|
|
@@ -939,6 +968,7 @@ var formTranslation = {
|
|
|
939
968
|
confirm: "Confirm",
|
|
940
969
|
copy: "Copy",
|
|
941
970
|
copied: "Copied",
|
|
971
|
+
create: "Create",
|
|
942
972
|
decline: "Decline",
|
|
943
973
|
delete: "Delete",
|
|
944
974
|
discard: "Discard",
|
|
@@ -981,6 +1011,7 @@ var formTranslation = {
|
|
|
981
1011
|
yes: "Yes"
|
|
982
1012
|
},
|
|
983
1013
|
de: {
|
|
1014
|
+
add: "Hinzuf\xFCgen",
|
|
984
1015
|
all: "Alle",
|
|
985
1016
|
apply: "Anwenden",
|
|
986
1017
|
back: "Zur\xFCck",
|
|
@@ -993,6 +1024,7 @@ var formTranslation = {
|
|
|
993
1024
|
confirm: "Best\xE4tigen",
|
|
994
1025
|
copy: "Kopieren",
|
|
995
1026
|
copied: "Kopiert",
|
|
1027
|
+
create: "Erstellen",
|
|
996
1028
|
decline: "Ablehnen",
|
|
997
1029
|
delete: "L\xF6schen",
|
|
998
1030
|
discard: "Verwerfen",
|
|
@@ -1081,12 +1113,12 @@ var DateTimePicker = ({
|
|
|
1081
1113
|
}
|
|
1082
1114
|
);
|
|
1083
1115
|
}
|
|
1084
|
-
return /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("div", { className: "col w-fit", children: [
|
|
1085
|
-
/* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("div", { className: "row
|
|
1116
|
+
return /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("div", { className: "flex-col-2 w-fit", children: [
|
|
1117
|
+
/* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("div", { className: "flex-row-4", children: [
|
|
1086
1118
|
dateDisplay,
|
|
1087
1119
|
timeDisplay
|
|
1088
1120
|
] }),
|
|
1089
|
-
/* @__PURE__ */ (0, import_jsx_runtime8.jsx)("div", { className: "row justify-end", children: /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("div", { className: "row
|
|
1121
|
+
/* @__PURE__ */ (0, import_jsx_runtime8.jsx)("div", { className: "flex-row-2 justify-end", children: /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("div", { className: "flex-row-2 mt-1", children: [
|
|
1090
1122
|
/* @__PURE__ */ (0, import_jsx_runtime8.jsx)(SolidButton, { size: "medium", color: "negative", onClick: onRemove, children: translation("clear") }),
|
|
1091
1123
|
/* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
|
|
1092
1124
|
SolidButton,
|