@indico-data/design-system 3.17.0 → 3.19.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/lib/components/floatUI/FloatUI.d.ts +1 -1
- package/lib/components/floatUI/types.d.ts +2 -0
- package/lib/components/forms/date/datePicker/types.d.ts +7 -0
- package/lib/components/forms/date/iconTriggerDatePicker/IconTriggerDatePicker.d.ts +3 -0
- package/lib/components/forms/date/iconTriggerDatePicker/types.d.ts +5 -0
- package/lib/components/forms/date/inputDatePicker/SingleInputDatePicker.d.ts +2 -1
- package/lib/components/forms/date/inputDateRangePicker/InputDateRangePicker.d.ts +3 -0
- package/lib/components/forms/date/inputDateRangePicker/types.d.ts +7 -0
- package/lib/components/forms/date/inputDateTimePicker/SingleInputDateTimePicker.d.ts +2 -1
- package/lib/components/forms/select/Select.d.ts +3 -1
- package/lib/components/forms/select/types.d.ts +10 -0
- package/lib/components/forms/subcomponents/Label.d.ts +4 -0
- package/lib/components/forms/subcomponents/types.d.ts +5 -0
- package/lib/components/forms/timePicker/TimePicker.d.ts +4 -1
- package/lib/components/forms/timePicker/types.d.ts +5 -0
- package/lib/components/modal/ConfirmationModal.d.ts +1 -1
- package/lib/components/modal/Modal.d.ts +1 -1
- package/lib/components/modal/Modal.stories.d.ts +4 -0
- package/lib/components/modal/types.d.ts +19 -5
- package/lib/components/pagination/Pagination.d.ts +1 -1
- package/lib/components/pagination/index.d.ts +1 -0
- package/lib/components/pagination/types.d.ts +13 -0
- package/lib/components/stepper/Stepper.d.ts +1 -1
- package/lib/components/stepper/components/BackNavigation.d.ts +2 -1
- package/lib/components/stepper/components/NextNavigation.d.ts +3 -1
- package/lib/components/stepper/types.d.ts +11 -0
- package/lib/components/table/LoadingComponent.d.ts +5 -1
- package/lib/components/table/components/HorizontalStickyHeader.d.ts +4 -1
- package/lib/components/table/hooks/usePinnedColumnsManager.d.ts +2 -2
- package/lib/components/table/types.d.ts +18 -0
- package/lib/components/table/utils/processColumns.d.ts +2 -2
- package/lib/components/tanstackTable/TankstackTable.types.d.ts +19 -2
- package/lib/components/tanstackTable/TanstackTable.d.ts +1 -1
- package/lib/components/tanstackTable/components/NoResults/NoResults.d.ts +2 -1
- package/lib/components/tanstackTable/components/TablePagination/TablePagination.d.ts +3 -1
- package/lib/index.d.ts +146 -24
- package/lib/index.esm.js +135 -63
- package/lib/index.esm.js.map +1 -1
- package/lib/index.js +135 -63
- package/lib/index.js.map +1 -1
- package/package.json +1 -1
- package/src/components/button/Button.tsx +4 -18
- package/src/components/button/__tests__/Button.test.tsx +30 -28
- package/src/components/floatUI/FloatUI.stories.tsx +14 -0
- package/src/components/floatUI/FloatUI.tsx +5 -0
- package/src/components/floatUI/types.ts +2 -0
- package/src/components/forms/date/datePicker/DatePicker.stories.tsx +10 -0
- package/src/components/forms/date/datePicker/DatePicker.tsx +9 -2
- package/src/components/forms/date/datePicker/types.ts +8 -0
- package/src/components/forms/date/iconTriggerDatePicker/IconTriggerDatePicker.stories.tsx +10 -0
- package/src/components/forms/date/iconTriggerDatePicker/IconTriggerDatePicker.tsx +12 -1
- package/src/components/forms/date/iconTriggerDatePicker/types.ts +5 -0
- package/src/components/forms/date/inputDatePicker/SingleInputDatePicker.tsx +4 -3
- package/src/components/forms/date/inputDatePicker/__tests__/SingleInputDatePicker.test.tsx +2 -0
- package/src/components/forms/date/inputDateRangePicker/InputDateRangePicker.stories.tsx +10 -0
- package/src/components/forms/date/inputDateRangePicker/InputDateRangePicker.tsx +14 -2
- package/src/components/forms/date/inputDateRangePicker/types.ts +7 -0
- package/src/components/forms/date/inputDateTimePicker/SingleInputDateTimePicker.tsx +3 -2
- package/src/components/forms/input/Input.tsx +1 -0
- package/src/components/forms/numberInput/NumberInput.tsx +1 -0
- package/src/components/forms/passwordInput/PasswordInput.tsx +7 -1
- package/src/components/forms/select/Select.stories.tsx +6 -5
- package/src/components/forms/select/Select.tsx +15 -1
- package/src/components/forms/select/types.ts +11 -0
- package/src/components/forms/subcomponents/Label.tsx +20 -3
- package/src/components/forms/subcomponents/types.ts +5 -0
- package/src/components/forms/textarea/Textarea.tsx +1 -0
- package/src/components/forms/timePicker/TimePicker.stories.tsx +10 -0
- package/src/components/forms/timePicker/TimePicker.tsx +10 -1
- package/src/components/forms/timePicker/types.ts +5 -0
- package/src/components/modal/ConfirmationModal.tsx +19 -14
- package/src/components/modal/Modal.stories.tsx +53 -22
- package/src/components/modal/Modal.tsx +8 -2
- package/src/components/modal/types.ts +21 -5
- package/src/components/pagination/Pagination.stories.tsx +11 -0
- package/src/components/pagination/Pagination.tsx +14 -5
- package/src/components/pagination/index.ts +1 -0
- package/src/components/pagination/types.ts +14 -0
- package/src/components/stepper/Stepper.stories.tsx +11 -0
- package/src/components/stepper/Stepper.tsx +16 -2
- package/src/components/stepper/components/BackNavigation.tsx +5 -3
- package/src/components/stepper/components/NextNavigation.tsx +15 -5
- package/src/components/stepper/types.ts +12 -0
- package/src/components/table/LoadingComponent.tsx +6 -2
- package/src/components/table/Table.stories.tsx +10 -0
- package/src/components/table/Table.tsx +12 -2
- package/src/components/table/components/HorizontalStickyHeader.tsx +12 -1
- package/src/components/table/hooks/usePinnedColumnsManager.ts +3 -2
- package/src/components/table/types.ts +20 -0
- package/src/components/table/utils/processColumns.tsx +3 -1
- package/src/components/tanstackTable/TankstackTable.types.ts +20 -2
- package/src/components/tanstackTable/TanstackTable.stories.tsx +8 -6
- package/src/components/tanstackTable/TanstackTable.tsx +21 -11
- package/src/components/tanstackTable/components/NoResults/NoResults.tsx +9 -3
- package/src/components/tanstackTable/components/TablePagination/TablePagination.tsx +4 -1
- package/src/index.ts +1 -1
- package/src/storybook/formArgTypes.ts +10 -0
- package/src/storybookDocs/Permafrost.mdx +8 -0
package/lib/index.d.ts
CHANGED
|
@@ -197,12 +197,36 @@ type IconProps = PermafrostComponent & {
|
|
|
197
197
|
faPrefix?: IconPrefix;
|
|
198
198
|
};
|
|
199
199
|
|
|
200
|
+
/** Customizable text for form Label. */
|
|
201
|
+
interface FormLabelText {
|
|
202
|
+
/** Text appended to aria-label for required fields. Default: "(required)" */
|
|
203
|
+
required?: string;
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
interface LabelProps {
|
|
207
|
+
label?: string;
|
|
208
|
+
name: string;
|
|
209
|
+
isRequired?: boolean;
|
|
210
|
+
hasHiddenLabel?: boolean;
|
|
211
|
+
/** Customizable display text. */
|
|
212
|
+
text?: FormLabelText;
|
|
213
|
+
}
|
|
214
|
+
|
|
200
215
|
type SelectOption = {
|
|
201
216
|
label: string;
|
|
202
217
|
value: string;
|
|
203
218
|
detail?: ReactNode;
|
|
204
219
|
[key: string]: any;
|
|
205
220
|
};
|
|
221
|
+
/** Customizable text for Select. Extends FormLabelText for label-related text. */
|
|
222
|
+
interface SelectText extends FormLabelText {
|
|
223
|
+
/** Placeholder text when no option is selected. Default: "Select..." */
|
|
224
|
+
placeholder?: string;
|
|
225
|
+
/** Text when there are no options. Default: "No options" */
|
|
226
|
+
noOptions?: string;
|
|
227
|
+
/** Text while loading options. Default: "Loading..." */
|
|
228
|
+
loading?: string;
|
|
229
|
+
}
|
|
206
230
|
|
|
207
231
|
type Direction = `${Direction$1}`;
|
|
208
232
|
interface PinnableColumn<T> extends TableColumn$1<T> {
|
|
@@ -212,6 +236,15 @@ interface PinnableColumn<T> extends TableColumn$1<T> {
|
|
|
212
236
|
position?: number;
|
|
213
237
|
}
|
|
214
238
|
type TableColumn<T> = PinnableColumn<T>;
|
|
239
|
+
/** Customizable text for Table. */
|
|
240
|
+
interface TableText {
|
|
241
|
+
/** Text to display while loading. Default: "Loading..." */
|
|
242
|
+
loading?: string;
|
|
243
|
+
/** Aria label for unpinning a column. Default: "Unpin column" */
|
|
244
|
+
unpinColumn?: string;
|
|
245
|
+
/** Aria label for pinning a column. Default: "Pin column" */
|
|
246
|
+
pinColumn?: string;
|
|
247
|
+
}
|
|
215
248
|
interface TableProps<T> extends Omit<IDataTableProps<T>, 'paginationComponent' | 'direction' | 'subHeaderAlign'> {
|
|
216
249
|
/** The columns to display in the table. All columns require a unique id property. For pinned columns, please see the pinned example below. */
|
|
217
250
|
columns: TableColumn<T>[];
|
|
@@ -231,6 +264,8 @@ interface TableProps<T> extends Omit<IDataTableProps<T>, 'paginationComponent' |
|
|
|
231
264
|
canPinColumns?: boolean;
|
|
232
265
|
/** Callback that receives the IDs of the pinned columns when they change. */
|
|
233
266
|
onPinnedColumnsChange?: (pinnedColumnIds: any[]) => void;
|
|
267
|
+
/** Customizable display text. */
|
|
268
|
+
text?: TableText;
|
|
234
269
|
}
|
|
235
270
|
|
|
236
271
|
type PillSize = 'sm' | 'md' | 'lg';
|
|
@@ -315,13 +350,6 @@ declare const Icon: ({ name, size, className, ariaLabel, faPrefix, ...props }: I
|
|
|
315
350
|
|
|
316
351
|
declare const Table: <T>(props: TableProps<T>) => react_jsx_runtime.JSX.Element;
|
|
317
352
|
|
|
318
|
-
interface LabelProps {
|
|
319
|
-
label?: string;
|
|
320
|
-
name: string;
|
|
321
|
-
isRequired?: boolean;
|
|
322
|
-
hasHiddenLabel?: boolean;
|
|
323
|
-
}
|
|
324
|
-
|
|
325
353
|
interface BaseInputProps {
|
|
326
354
|
id?: string;
|
|
327
355
|
value?: string | undefined;
|
|
@@ -462,11 +490,18 @@ interface SelectProps<OptionType extends SelectOption> extends Props$4<OptionTyp
|
|
|
462
490
|
classNamePrefix?: string;
|
|
463
491
|
/** Event handler for when the selected value changes */
|
|
464
492
|
onChange?: (newValue: any, actionMeta: any) => void;
|
|
493
|
+
/** Customizable display text. */
|
|
494
|
+
text?: SelectText;
|
|
465
495
|
}
|
|
466
496
|
declare const LabeledSelect: React$1.ForwardRefExoticComponent<Omit<SelectProps<SelectOption> & {
|
|
467
497
|
ref?: React$1.Ref<any>;
|
|
468
498
|
} & LabelProps, "ref"> & React$1.RefAttributes<any>>;
|
|
469
499
|
|
|
500
|
+
/** Customizable text for DatePicker. */
|
|
501
|
+
interface DatePickerText {
|
|
502
|
+
/** Label for "Select Time" text. Default: "Select Time" */
|
|
503
|
+
selectTime?: string;
|
|
504
|
+
}
|
|
470
505
|
interface DatePickerProps {
|
|
471
506
|
ref?: React.LegacyRef<HTMLInputElement>;
|
|
472
507
|
/** The selected day(s). */
|
|
@@ -509,6 +544,8 @@ interface DatePickerProps {
|
|
|
509
544
|
isReadOnly?: boolean;
|
|
510
545
|
timeTabIndex?: number;
|
|
511
546
|
dateTabIndex?: number;
|
|
547
|
+
/** Customizable display text. */
|
|
548
|
+
text?: DatePickerText;
|
|
512
549
|
}
|
|
513
550
|
interface PortalOptions {
|
|
514
551
|
rootId?: string;
|
|
@@ -516,6 +553,12 @@ interface PortalOptions {
|
|
|
516
553
|
|
|
517
554
|
declare const DatePicker: (props: DatePickerProps) => react_jsx_runtime.JSX.Element;
|
|
518
555
|
|
|
556
|
+
/** Customizable text for TimePicker. */
|
|
557
|
+
interface TimePickerText {
|
|
558
|
+
/** Aria label for the validation error tooltip. Default: "Time validation error" */
|
|
559
|
+
validationError?: string;
|
|
560
|
+
}
|
|
561
|
+
|
|
519
562
|
interface TimePickerProps {
|
|
520
563
|
ref?: React.LegacyRef<HTMLInputElement>;
|
|
521
564
|
/** The time value to be displayed in the input field */
|
|
@@ -532,9 +575,17 @@ interface TimePickerProps {
|
|
|
532
575
|
isReadOnly?: boolean;
|
|
533
576
|
isDisabled?: boolean;
|
|
534
577
|
tabIndex?: number;
|
|
578
|
+
/** Customizable display text. */
|
|
579
|
+
text?: TimePickerText;
|
|
535
580
|
[key: string]: unknown;
|
|
536
581
|
}
|
|
537
|
-
declare const TimePicker: ({ ref, timeValue, label, name, hasHiddenLabel, onTimeChange, className, isDisabled, isReadOnly, tabIndex, ...rest }: TimePickerProps) => react_jsx_runtime.JSX.Element;
|
|
582
|
+
declare const TimePicker: ({ ref, timeValue, label, name, hasHiddenLabel, onTimeChange, className, isDisabled, isReadOnly, tabIndex, text: textProp, ...rest }: TimePickerProps) => react_jsx_runtime.JSX.Element;
|
|
583
|
+
|
|
584
|
+
/** Customizable text for IconTriggerDatePicker. */
|
|
585
|
+
interface IconTriggerDatePickerText {
|
|
586
|
+
/** Aria label for the trigger icon. Default: "Open date picker" */
|
|
587
|
+
triggerIcon?: string;
|
|
588
|
+
}
|
|
538
589
|
|
|
539
590
|
interface Props$3 {
|
|
540
591
|
/** Allows you to select a single day, a range of days, or multiple days. */
|
|
@@ -572,6 +623,8 @@ interface Props$3 {
|
|
|
572
623
|
isPortal?: boolean;
|
|
573
624
|
/** The floating options for the date picker. Follows floating-ui options. */
|
|
574
625
|
floatingOptions?: UseFloatingOptions;
|
|
626
|
+
/** Customizable display text. */
|
|
627
|
+
text?: IconTriggerDatePickerText;
|
|
575
628
|
}
|
|
576
629
|
declare const IconTriggerDatePicker: (props: Props$3) => react_jsx_runtime.JSX.Element;
|
|
577
630
|
|
|
@@ -584,7 +637,8 @@ interface SingleInputDatePickerProps {
|
|
|
584
637
|
/** The layout of the caption. Enables you to add or remove the dropdown navigation for months/years */
|
|
585
638
|
captionLayout?: 'dropdown' | 'dropdown-months' | 'dropdown-years' | 'label';
|
|
586
639
|
id?: string;
|
|
587
|
-
label
|
|
640
|
+
/** The label for the input field. */
|
|
641
|
+
label: string;
|
|
588
642
|
onSelect: (selected: Date | undefined) => void;
|
|
589
643
|
initialMonth?: Date;
|
|
590
644
|
selected?: Date;
|
|
@@ -612,6 +666,14 @@ interface SingleInputDatePickerProps {
|
|
|
612
666
|
}
|
|
613
667
|
declare function SingleInputDatePicker(props: SingleInputDatePickerProps): react_jsx_runtime.JSX.Element;
|
|
614
668
|
|
|
669
|
+
/** Customizable text for InputDateRangePicker. */
|
|
670
|
+
interface InputDateRangePickerText {
|
|
671
|
+
/** Label for the "from" date input. Default: "From Date" */
|
|
672
|
+
fromDate?: string;
|
|
673
|
+
/** Label for the "to" date input. Default: "To Date" */
|
|
674
|
+
toDate?: string;
|
|
675
|
+
}
|
|
676
|
+
|
|
615
677
|
interface InputDateRangePickerProps {
|
|
616
678
|
/** A label for assistive technologies. */
|
|
617
679
|
ariaLabel: string;
|
|
@@ -653,6 +715,8 @@ interface InputDateRangePickerProps {
|
|
|
653
715
|
floatingOptions?: UseFloatingOptions;
|
|
654
716
|
/** Whether the date picker is a portal. */
|
|
655
717
|
isPortal?: boolean;
|
|
718
|
+
/** Customizable display text. */
|
|
719
|
+
text?: InputDateRangePickerText;
|
|
656
720
|
}
|
|
657
721
|
declare function InputDateRangePicker(props: InputDateRangePickerProps): react_jsx_runtime.JSX.Element;
|
|
658
722
|
|
|
@@ -664,7 +728,8 @@ interface SingleInputDateTimePickerProps {
|
|
|
664
728
|
isDisabled?: boolean;
|
|
665
729
|
captionLayout?: 'dropdown' | 'dropdown-months' | 'dropdown-years' | 'label';
|
|
666
730
|
id?: string;
|
|
667
|
-
label
|
|
731
|
+
/** The label for the date input field. */
|
|
732
|
+
label: string;
|
|
668
733
|
onSelect: (selected: Date | undefined) => void;
|
|
669
734
|
initialMonth?: Date;
|
|
670
735
|
selected?: Date;
|
|
@@ -762,9 +827,11 @@ type FloatUIProps = {
|
|
|
762
827
|
hover?: boolean;
|
|
763
828
|
/** Callback function to be called when the FloatUI is opened or closed. */
|
|
764
829
|
onOpenChange?: (isOpen: boolean) => void;
|
|
830
|
+
/** If true, disables automatic position updates when the reference element moves (e.g., due to layout shifts). Defaults to false. */
|
|
831
|
+
disableAutoUpdate?: boolean;
|
|
765
832
|
};
|
|
766
833
|
|
|
767
|
-
declare function FloatUI({ children, ariaLabel, isOpen: controlledIsOpen, setIsOpen: controlledSetIsOpen, isPortal, portalOptions, floatingOptions, className, hover, onOpenChange, }: FloatUIProps): react_jsx_runtime.JSX.Element;
|
|
834
|
+
declare function FloatUI({ children, ariaLabel, isOpen: controlledIsOpen, setIsOpen: controlledSetIsOpen, isPortal, portalOptions, floatingOptions, className, hover, onOpenChange, disableAutoUpdate, }: FloatUIProps): react_jsx_runtime.JSX.Element;
|
|
768
835
|
|
|
769
836
|
type MenuProps = {
|
|
770
837
|
children: React$1.ReactNode;
|
|
@@ -789,6 +856,11 @@ interface BadgeProps {
|
|
|
789
856
|
|
|
790
857
|
declare const Badge: ({ className, children, size, string, ...rest }: BadgeProps) => react_jsx_runtime.JSX.Element;
|
|
791
858
|
|
|
859
|
+
/** Customizable text for Modal. */
|
|
860
|
+
interface ModalText {
|
|
861
|
+
/** Aria label for the close button. Default: "Close" */
|
|
862
|
+
closeButton?: string;
|
|
863
|
+
}
|
|
792
864
|
interface ModalProps {
|
|
793
865
|
/** Additional classes for the badge component */
|
|
794
866
|
className?: string;
|
|
@@ -824,8 +896,19 @@ interface ModalProps {
|
|
|
824
896
|
footer?: React.ReactNode;
|
|
825
897
|
/** The maximum width of the modal in pixels */
|
|
826
898
|
maxWidthInPixels?: number;
|
|
899
|
+
/** Customizable display text. */
|
|
900
|
+
text?: ModalText;
|
|
827
901
|
}
|
|
828
|
-
|
|
902
|
+
/** Customizable text for ConfirmationModal. Extends ModalText. */
|
|
903
|
+
interface ConfirmationModalText extends ModalText {
|
|
904
|
+
/** Label for the "Don't show again" checkbox. Default: "Don't display this again." */
|
|
905
|
+
dontShowAgain?: string;
|
|
906
|
+
/** Text for the confirm button. Default: "Confirm" */
|
|
907
|
+
confirm?: string;
|
|
908
|
+
/** Text for the cancel button. Default: "Cancel" */
|
|
909
|
+
cancel?: string;
|
|
910
|
+
}
|
|
911
|
+
interface ConfirmationModalProps extends Omit<ModalProps, 'text'> {
|
|
829
912
|
onConfirmRequest?: ({ dontShowAgain, }: {
|
|
830
913
|
dontShowAgain?: boolean;
|
|
831
914
|
}) => void | Promise<void> | Promise<boolean>;
|
|
@@ -834,20 +917,35 @@ interface ConfirmationModalProps extends ModalProps {
|
|
|
834
917
|
hasDontShowAgainCheckbox?: boolean;
|
|
835
918
|
/** The variant of the confirmation button. */
|
|
836
919
|
confirmationButtonVariant?: ButtonVariants;
|
|
837
|
-
/** The text of the confirmation button */
|
|
838
|
-
confirmationButtonText?: string;
|
|
839
|
-
/** The text of the cancel button */
|
|
840
|
-
cancelButtonText?: string;
|
|
841
920
|
/** The icon of the modal */
|
|
842
921
|
icon?: IconName;
|
|
843
922
|
/** The status of the modal. This will determine the color of the icon. */
|
|
844
923
|
status?: 'info' | 'success' | 'error';
|
|
924
|
+
/** Customizable display text. */
|
|
925
|
+
text?: ConfirmationModalText;
|
|
845
926
|
}
|
|
846
927
|
|
|
847
|
-
declare const Modal: ({ className, children, isOpen, onRequestClose, portalClassName, overlayClassName, appElement, shouldCloseOnOverlayClick, shouldCloseOnEsc, testId, contentElement, overlayElement, position, parentSelector, title, subtitle, footer, maxWidthInPixels, ...rest }: ModalProps) => react_jsx_runtime.JSX.Element;
|
|
928
|
+
declare const Modal: ({ className, children, isOpen, onRequestClose, portalClassName, overlayClassName, appElement, shouldCloseOnOverlayClick, shouldCloseOnEsc, testId, contentElement, overlayElement, position, parentSelector, title, subtitle, footer, maxWidthInPixels, text: textProp, ...rest }: ModalProps) => react_jsx_runtime.JSX.Element;
|
|
848
929
|
|
|
849
|
-
declare const ConfirmationModal: ({ className, overlayClassName, testId, isOpen, onRequestClose, portalClassName, appElement, parentSelector, shouldCloseOnOverlayClick, shouldCloseOnEsc, contentElement, overlayElement, footer, children, onConfirmRequest, onCancelRequest,
|
|
930
|
+
declare const ConfirmationModal: ({ className, overlayClassName, testId, isOpen, onRequestClose, portalClassName, appElement, parentSelector, shouldCloseOnOverlayClick, shouldCloseOnEsc, contentElement, overlayElement, footer, children, onConfirmRequest, onCancelRequest, confirmationButtonVariant, icon, title, status, maxWidthInPixels, hasDontShowAgainCheckbox, text: textProp, }: ConfirmationModalProps) => react_jsx_runtime.JSX.Element;
|
|
850
931
|
|
|
932
|
+
/** Customizable text for TanstackTable. */
|
|
933
|
+
interface TanstackTableText {
|
|
934
|
+
/** Message while table is loading. Default: "Table is loading..." */
|
|
935
|
+
loading?: string;
|
|
936
|
+
/** Message when no results found. Default: "No results found." */
|
|
937
|
+
noResults?: string;
|
|
938
|
+
/** Message when there's an error loading data. Default: "There was an error loading the data." */
|
|
939
|
+
error?: string;
|
|
940
|
+
/** Text for reset filters button. Default: "Reset filters" */
|
|
941
|
+
resetFilters?: string;
|
|
942
|
+
/** Singular entry text. Default: "entry" */
|
|
943
|
+
entry?: string;
|
|
944
|
+
/** Plural entries text. Default: "entries" */
|
|
945
|
+
entries?: string;
|
|
946
|
+
/** "of" text in pagination (e.g., "5 of 10 entries"). Default: "of" */
|
|
947
|
+
of?: string;
|
|
948
|
+
}
|
|
851
949
|
type WithPaginationProps = {
|
|
852
950
|
/** Number of rows to display per pagination page. */
|
|
853
951
|
rowsPerPage: number;
|
|
@@ -901,8 +999,6 @@ type Props<T extends object> = {
|
|
|
901
999
|
hasFilters?: boolean;
|
|
902
1000
|
/** When this is true, the table is considered to be in a loading state. */
|
|
903
1001
|
isLoading?: boolean;
|
|
904
|
-
/** Message to display when the table is loading. */
|
|
905
|
-
isLoadingMessage?: string;
|
|
906
1002
|
/** Columns that are pinned by default. */
|
|
907
1003
|
defaultPinnedColumns?: string[];
|
|
908
1004
|
/** Callback when a row is clicked. */
|
|
@@ -919,9 +1015,11 @@ type Props<T extends object> = {
|
|
|
919
1015
|
onSelectAllChange?: (isSelected: boolean) => void;
|
|
920
1016
|
/** You may pass a default sorting state to the table. This will be used to sort the table by default. This is useful if you want to sort the table by a column by default. */
|
|
921
1017
|
defaultSorting?: SortingState;
|
|
1018
|
+
/** Customizable display text. */
|
|
1019
|
+
text?: TanstackTableText;
|
|
922
1020
|
} & PaginationProps$1;
|
|
923
1021
|
|
|
924
|
-
declare function TanstackTable<T extends object>({ columns: defaultColumns, data, className, currentPage, rowCount, rowsPerPage, onChangePage, totalEntriesText, TableActions, error, enableRowSelection, clearFilters, hasFilters, showPagination, isLoading,
|
|
1022
|
+
declare function TanstackTable<T extends object>({ columns: defaultColumns, data, className, currentPage, rowCount, rowsPerPage, onChangePage, totalEntriesText, TableActions, error, enableRowSelection, clearFilters, hasFilters, showPagination, isLoading, defaultPinnedColumns, onRowClick, activeRows, isStriped, actionBarClassName, defaultSorting, text: textProp, ...rest }: Props<T & {
|
|
925
1023
|
id: string;
|
|
926
1024
|
}>): react_jsx_runtime.JSX.Element;
|
|
927
1025
|
|
|
@@ -947,6 +1045,17 @@ interface TooltipProps {
|
|
|
947
1045
|
}
|
|
948
1046
|
declare const Tooltip: ({ id, clickToShow, delayShow, delayHide, children, place, width, maxWidth, opacity, positionStrategy, ...rest }: TooltipProps) => react_jsx_runtime.JSX.Element;
|
|
949
1047
|
|
|
1048
|
+
/** Customizable text for Pagination. */
|
|
1049
|
+
interface PaginationText {
|
|
1050
|
+
/** Aria label for previous page button. Default: "Previous Page" */
|
|
1051
|
+
previousPage?: string;
|
|
1052
|
+
/** Aria label for next page button. Default: "Next Page" */
|
|
1053
|
+
nextPage?: string;
|
|
1054
|
+
/** Label for current page input. Default: "Current Page" */
|
|
1055
|
+
currentPage?: string;
|
|
1056
|
+
/** Text between current page and total (e.g., "of"). Default: "of" */
|
|
1057
|
+
of?: string;
|
|
1058
|
+
}
|
|
950
1059
|
interface PaginationProps {
|
|
951
1060
|
/** The total number of pages to be displayed */
|
|
952
1061
|
totalPages: number;
|
|
@@ -956,9 +1065,11 @@ interface PaginationProps {
|
|
|
956
1065
|
className?: string;
|
|
957
1066
|
/** The callback function that is called when the page changes. */
|
|
958
1067
|
onChange?: (value: number) => void;
|
|
1068
|
+
/** Customizable display text. */
|
|
1069
|
+
text?: PaginationText;
|
|
959
1070
|
}
|
|
960
1071
|
|
|
961
|
-
declare const Pagination: ({ totalPages, currentPage, onChange, className, ...rest }: PaginationProps) => react_jsx_runtime.JSX.Element;
|
|
1072
|
+
declare const Pagination: ({ totalPages, currentPage, onChange, className, text: textProp, ...rest }: PaginationProps) => react_jsx_runtime.JSX.Element;
|
|
962
1073
|
|
|
963
1074
|
interface CirclePulseProps {
|
|
964
1075
|
/** The size of the circle */
|
|
@@ -982,6 +1093,15 @@ declare function BarSpinner({ width, id, height, className, ...rest }: {
|
|
|
982
1093
|
[key: string]: any;
|
|
983
1094
|
}): react_jsx_runtime.JSX.Element;
|
|
984
1095
|
|
|
1096
|
+
/** Customizable text for Stepper. */
|
|
1097
|
+
interface StepperText {
|
|
1098
|
+
/** Label for the "Previous Step" button. Default: "Previous Step" */
|
|
1099
|
+
previousStep?: string;
|
|
1100
|
+
/** Label for the "Next Step" button. Default: "Next Step" */
|
|
1101
|
+
nextStep?: string;
|
|
1102
|
+
/** Label for the "Finish" button. Default: "Finish" */
|
|
1103
|
+
finish?: string;
|
|
1104
|
+
}
|
|
985
1105
|
interface StepperProps {
|
|
986
1106
|
/** An array of step objects that define the stepper navigation. */
|
|
987
1107
|
steps: Step[];
|
|
@@ -1000,6 +1120,8 @@ interface StepperProps {
|
|
|
1000
1120
|
children: React.ReactNode;
|
|
1001
1121
|
/** The function to call when a step is clicked ont he legend. */
|
|
1002
1122
|
onStepClick: (step: number) => void;
|
|
1123
|
+
/** Customizable display text. */
|
|
1124
|
+
text?: StepperText;
|
|
1003
1125
|
}
|
|
1004
1126
|
interface Step {
|
|
1005
1127
|
/** Display text for the step in the sidebar/legend */
|
|
@@ -1010,7 +1132,7 @@ interface Step {
|
|
|
1010
1132
|
isSidebarEnabled?: boolean;
|
|
1011
1133
|
}
|
|
1012
1134
|
|
|
1013
|
-
declare const Stepper: ({ currentStep: externalCurrentStep, legendHeader, legendFooter, steps, onBackClick, onNextClick, onFinishClick, children, onStepClick, }: StepperProps) => react_jsx_runtime.JSX.Element;
|
|
1135
|
+
declare const Stepper: ({ currentStep: externalCurrentStep, legendHeader, legendFooter, steps, onBackClick, onNextClick, onFinishClick, children, onStepClick, text: textProp, }: StepperProps) => react_jsx_runtime.JSX.Element;
|
|
1014
1136
|
|
|
1015
1137
|
interface TruncateProps {
|
|
1016
1138
|
/** The number of lines to truncate the text to. If left blank, it will default to 1 line. */
|
|
@@ -1025,4 +1147,4 @@ interface TruncateProps {
|
|
|
1025
1147
|
|
|
1026
1148
|
declare const Truncate: ({ numLines, tooltipOptions, children, ...rest }: TruncateProps) => react_jsx_runtime.JSX.Element;
|
|
1027
1149
|
|
|
1028
|
-
export { Badge, BarSpinner, Button, Card, Checkbox, CirclePulse, Col, ConfirmationModal, Container, DatePicker, FloatUI, Form, Icon, IconTriggerDatePicker, LabeledInput as Input, InputDateRangePicker, Menu, Modal, Pagination, LabeledPasswordInput as PasswordInput, Pill, Radio as RadioInput, Row, LabeledSelect as SelectInput, type SelectOption, SingleInputDatePicker, SingleInputDateTimePicker, Skeleton, Stepper, Table, TanstackTable, LabeledTextarea as Textarea, TimePicker, Toggle as ToggleInput, Tooltip, Truncate, registerFontAwesomeIcons };
|
|
1150
|
+
export { Badge, BarSpinner, Button, Card, Checkbox, CirclePulse, Col, ConfirmationModal, Container, DatePicker, FloatUI, Form, Icon, IconTriggerDatePicker, LabeledInput as Input, InputDateRangePicker, Menu, Modal, Pagination, LabeledPasswordInput as PasswordInput, Pill, Radio as RadioInput, Row, LabeledSelect as SelectInput, type SelectOption, type SelectText, SingleInputDatePicker, SingleInputDateTimePicker, Skeleton, Stepper, Table, TanstackTable, LabeledTextarea as Textarea, TimePicker, Toggle as ToggleInput, Tooltip, Truncate, registerFontAwesomeIcons };
|