@jacshuo/onyx 2.1.0 → 2.3.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/README.md +358 -361
- package/dist/Chart/BarChart.cjs +1 -1
- package/dist/Chart/BarChart.js +1 -1
- package/dist/Chart/PieChart.cjs +1 -1
- package/dist/Chart/PieChart.js +1 -1
- package/dist/Chart/ScatterChart.cjs +1 -1
- package/dist/Chart/ScatterChart.js +1 -1
- package/dist/Chart/index.cjs +1 -1
- package/dist/Chart/index.js +1 -1
- package/dist/DataDisplay/VirtualList.cjs +2 -0
- package/dist/DataDisplay/VirtualList.css +1 -0
- package/dist/DataDisplay/VirtualList.d.cts +5 -0
- package/dist/DataDisplay/VirtualList.d.ts +5 -0
- package/dist/DataDisplay/VirtualList.js +2 -0
- package/dist/DataDisplay/index.cjs +3 -2
- package/dist/DataDisplay/index.css +1 -0
- package/dist/DataDisplay/index.d.cts +5 -0
- package/dist/DataDisplay/index.d.ts +5 -0
- package/dist/DataDisplay/index.js +3 -2
- package/dist/Extras/DateTimePicker.cjs +1 -0
- package/dist/Extras/DateTimePicker.css +1 -0
- package/dist/Extras/DateTimePicker.d.cts +5 -0
- package/dist/Extras/DateTimePicker.d.ts +5 -0
- package/dist/Extras/DateTimePicker.js +1 -0
- package/dist/Extras/FileExplorer.cjs +2 -2
- package/dist/Extras/FileExplorer.js +2 -2
- package/dist/Extras/LoginPanel.cjs +1 -0
- package/dist/Extras/LoginPanel.css +1 -0
- package/dist/Extras/LoginPanel.d.cts +3 -0
- package/dist/Extras/LoginPanel.d.ts +3 -0
- package/dist/Extras/LoginPanel.js +1 -0
- package/dist/Extras/RichTextEditor.cjs +45 -0
- package/dist/Extras/RichTextEditor.css +1 -0
- package/dist/Extras/RichTextEditor.d.cts +10 -0
- package/dist/Extras/RichTextEditor.d.ts +10 -0
- package/dist/Extras/RichTextEditor.js +45 -0
- package/dist/Extras/index.cjs +48 -4
- package/dist/Extras/index.css +1 -1
- package/dist/Extras/index.d.cts +12 -0
- package/dist/Extras/index.d.ts +12 -0
- package/dist/Extras/index.js +48 -4
- package/dist/Forms/Form.cjs +1 -1
- package/dist/Forms/Form.js +1 -1
- package/dist/Forms/OTPInput.cjs +1 -0
- package/dist/Forms/OTPInput.css +1 -0
- package/dist/Forms/OTPInput.d.cts +4 -0
- package/dist/Forms/OTPInput.d.ts +4 -0
- package/dist/Forms/OTPInput.js +1 -0
- package/dist/Forms/Select.cjs +1 -1
- package/dist/Forms/Select.js +1 -1
- package/dist/Forms/index.cjs +1 -1
- package/dist/Forms/index.css +1 -0
- package/dist/Forms/index.d.cts +4 -0
- package/dist/Forms/index.d.ts +4 -0
- package/dist/Forms/index.js +1 -1
- package/dist/Layout/SplitPanel.cjs +1 -0
- package/dist/Layout/SplitPanel.d.cts +3 -0
- package/dist/Layout/SplitPanel.d.ts +3 -0
- package/dist/Layout/SplitPanel.js +1 -0
- package/dist/Layout/index.cjs +1 -1
- package/dist/Layout/index.d.cts +3 -0
- package/dist/Layout/index.d.ts +3 -0
- package/dist/Layout/index.js +1 -1
- package/dist/Navigation/Header.cjs +1 -1
- package/dist/Navigation/Header.js +1 -1
- package/dist/Navigation/RibbonBar.d.cts +3 -3
- package/dist/Navigation/RibbonBar.d.ts +3 -3
- package/dist/Navigation/SideNav.cjs +1 -1
- package/dist/Navigation/SideNav.js +1 -1
- package/dist/Navigation/index.cjs +2 -2
- package/dist/Navigation/index.d.cts +3 -3
- package/dist/Navigation/index.d.ts +3 -3
- package/dist/Navigation/index.js +2 -2
- package/dist/Primitives/Avatar.cjs +1 -1
- package/dist/Primitives/Avatar.js +1 -1
- package/dist/Primitives/Badge.cjs +1 -1
- package/dist/Primitives/Badge.js +1 -1
- package/dist/Primitives/Button.cjs +1 -1
- package/dist/Primitives/Button.js +1 -1
- package/dist/Primitives/Checkbox.cjs +1 -1
- package/dist/Primitives/Checkbox.js +1 -1
- package/dist/Primitives/Dropdown.cjs +1 -1
- package/dist/Primitives/Dropdown.js +1 -1
- package/dist/Primitives/DropdownButton.cjs +1 -1
- package/dist/Primitives/DropdownButton.js +1 -1
- package/dist/Primitives/Indicator.cjs +1 -1
- package/dist/Primitives/Indicator.js +1 -1
- package/dist/Primitives/Input.cjs +1 -1
- package/dist/Primitives/Input.js +1 -1
- package/dist/Primitives/Kbd.cjs +1 -0
- package/dist/Primitives/Kbd.css +0 -0
- package/dist/Primitives/Kbd.d.cts +6 -0
- package/dist/Primitives/Kbd.d.ts +6 -0
- package/dist/Primitives/Kbd.js +1 -0
- package/dist/Primitives/Label.cjs +1 -1
- package/dist/Primitives/Label.js +1 -1
- package/dist/Primitives/Radio.cjs +1 -1
- package/dist/Primitives/Radio.js +1 -1
- package/dist/Primitives/Rating.cjs +2 -0
- package/dist/Primitives/Rating.css +0 -0
- package/dist/Primitives/Rating.d.cts +4 -0
- package/dist/Primitives/Rating.d.ts +4 -0
- package/dist/Primitives/Rating.js +2 -0
- package/dist/Primitives/Slider.cjs +1 -1
- package/dist/Primitives/Slider.js +1 -1
- package/dist/Primitives/Switch.cjs +1 -1
- package/dist/Primitives/Switch.js +1 -1
- package/dist/Primitives/Tag.cjs +1 -1
- package/dist/Primitives/Tag.js +1 -1
- package/dist/Primitives/index.cjs +2 -1
- package/dist/Primitives/index.d.cts +10 -0
- package/dist/Primitives/index.d.ts +10 -0
- package/dist/Primitives/index.js +2 -1
- package/dist/_tsup-dts-rollup.d.cts +990 -3
- package/dist/_tsup-dts-rollup.d.ts +990 -3
- package/dist/index.cjs +49 -5
- package/dist/index.css +1 -1
- package/dist/index.d.cts +40 -0
- package/dist/index.d.ts +40 -0
- package/dist/index.js +49 -5
- package/dist/styles/DataDisplay/VirtualList.css +35 -0
- package/dist/styles/Extras/DateTimePicker.css +566 -0
- package/dist/styles/Extras/LoginPanel.css +16 -0
- package/dist/styles/Extras/RichTextEditor.css +908 -0
- package/dist/styles/Forms/OTPInput.css +11 -0
- package/dist/styles/Layout/SplitPanel.css +15 -0
- package/dist/styles/Primitives/Kbd.css +1 -0
- package/dist/styles/Primitives/Rating.css +1 -0
- package/dist/styles/base.css +312 -7
- package/dist/styles.css +770 -7
- package/dist/theme.cjs +1 -1
- package/dist/theme.d.cts +3 -0
- package/dist/theme.d.ts +3 -0
- package/dist/theme.js +1 -1
- package/package.json +21 -1
|
@@ -1,8 +1,20 @@
|
|
|
1
1
|
import { ClassProp } from 'class-variance-authority/types';
|
|
2
2
|
import { ClassValue } from 'clsx';
|
|
3
|
+
import type { CSSProperties } from 'react';
|
|
3
4
|
import { Dispatch } from 'react';
|
|
5
|
+
import { Editor } from '@tiptap/core';
|
|
6
|
+
import { Extension } from '@tiptap/core';
|
|
7
|
+
import { ForwardRefExoticComponent } from 'react';
|
|
8
|
+
import { ImageOptions } from '@tiptap/extension-image';
|
|
4
9
|
import { JSX } from 'react/jsx-runtime';
|
|
10
|
+
import { Node as Node_2 } from '@tiptap/core';
|
|
11
|
+
import type { Node as Node_3 } from '@tiptap/pm/model';
|
|
12
|
+
import { PluginKey } from '@tiptap/pm/state';
|
|
5
13
|
import { default as React_2 } from 'react';
|
|
14
|
+
import type { ReactNode } from 'react';
|
|
15
|
+
import type { Ref } from 'react';
|
|
16
|
+
import { RefAttributes } from 'react';
|
|
17
|
+
import { RefObject } from 'react';
|
|
6
18
|
import { SetStateAction } from 'react';
|
|
7
19
|
import { VariantProps } from 'class-variance-authority';
|
|
8
20
|
|
|
@@ -122,6 +134,8 @@ export { alertVariants }
|
|
|
122
134
|
export { alertVariants as alertVariants_alias_1 }
|
|
123
135
|
export { alertVariants as alertVariants_alias_2 }
|
|
124
136
|
|
|
137
|
+
export declare function applyOffset(base: Date, amount: number, unit: OffsetUnit, direction: OffsetDirection): Date;
|
|
138
|
+
|
|
125
139
|
declare function Avatar({ src, alt, initials, size, shape, status, className, ...props }: AvatarProps): JSX.Element;
|
|
126
140
|
export { Avatar }
|
|
127
141
|
export { Avatar as Avatar_alias_1 }
|
|
@@ -330,6 +344,11 @@ export { buttonVariants }
|
|
|
330
344
|
export { buttonVariants as buttonVariants_alias_1 }
|
|
331
345
|
export { buttonVariants as buttonVariants_alias_2 }
|
|
332
346
|
|
|
347
|
+
export declare interface CalendarDay {
|
|
348
|
+
date: Date;
|
|
349
|
+
thisMonth: boolean;
|
|
350
|
+
}
|
|
351
|
+
|
|
333
352
|
declare function Card({ intent, size, className, ...props }: CardProps): JSX.Element;
|
|
334
353
|
export { Card }
|
|
335
354
|
export { Card as Card_alias_1 }
|
|
@@ -562,6 +581,8 @@ export { CinePlayerSortKey }
|
|
|
562
581
|
export { CinePlayerSortKey as CinePlayerSortKey_alias_1 }
|
|
563
582
|
export { CinePlayerSortKey as CinePlayerSortKey_alias_2 }
|
|
564
583
|
|
|
584
|
+
export declare function clampDate(date: Date, min?: Date, max?: Date): Date;
|
|
585
|
+
|
|
565
586
|
/** Computes a padded [min, max] range from raw data extents. */
|
|
566
587
|
export declare function clampRange(min: number, max: number, padding?: number): [number, number];
|
|
567
588
|
|
|
@@ -809,6 +830,11 @@ export { ContextMenuProps as ContextMenuProps_alias_2 }
|
|
|
809
830
|
export { ContextMenuProps as ContextMenuProps_alias_3 }
|
|
810
831
|
export { ContextMenuProps as ContextMenuProps_alias_4 }
|
|
811
832
|
|
|
833
|
+
/**
|
|
834
|
+
* Count words in a string.
|
|
835
|
+
*/
|
|
836
|
+
export declare function countWords(text: string): number;
|
|
837
|
+
|
|
812
838
|
/** Creates a categorical band scale (returns center-of-band x). */
|
|
813
839
|
export declare function createCategoryScale(categories: string[], range: [number, number]): (cat: string) => number;
|
|
814
840
|
|
|
@@ -829,6 +855,7 @@ declare const DataDisplay: {
|
|
|
829
855
|
CodeBlock: typeof CodeBlock;
|
|
830
856
|
Stat: typeof Stat;
|
|
831
857
|
MetricCard: typeof MetricCard;
|
|
858
|
+
VirtualList: <T>(props: VirtualListProps<T> & React.RefAttributes<VirtualListHandle>) => React.ReactElement;
|
|
832
859
|
};
|
|
833
860
|
export { DataDisplay }
|
|
834
861
|
export { DataDisplay as DataDisplay_alias_1 }
|
|
@@ -877,6 +904,63 @@ export { DataTableProps }
|
|
|
877
904
|
export { DataTableProps as DataTableProps_alias_1 }
|
|
878
905
|
export { DataTableProps as DataTableProps_alias_2 }
|
|
879
906
|
|
|
907
|
+
declare type DateTimeMode = "date" | "time" | "datetime";
|
|
908
|
+
export { DateTimeMode }
|
|
909
|
+
export { DateTimeMode as DateTimeMode_alias_1 }
|
|
910
|
+
export { DateTimeMode as DateTimeMode_alias_2 }
|
|
911
|
+
export { DateTimeMode as DateTimeMode_alias_3 }
|
|
912
|
+
|
|
913
|
+
declare function DateTimePicker({ className, popupClassName, triggerClassName, disabled, placeholder, ...restProps }: DateTimePickerProps): JSX.Element;
|
|
914
|
+
export { DateTimePicker }
|
|
915
|
+
export { DateTimePicker as DateTimePicker_alias_1 }
|
|
916
|
+
export { DateTimePicker as DateTimePicker_alias_2 }
|
|
917
|
+
export { DateTimePicker as DateTimePicker_alias_3 }
|
|
918
|
+
|
|
919
|
+
declare interface DateTimePickerProps {
|
|
920
|
+
/** Controlled selected date/time value. */
|
|
921
|
+
value?: Date | null;
|
|
922
|
+
/** Uncontrolled initial value. */
|
|
923
|
+
defaultValue?: Date | null;
|
|
924
|
+
/** Called when the user confirms a new selection. */
|
|
925
|
+
onChange?: (date: Date | null) => void;
|
|
926
|
+
/** Picker mode: date only, time only, or full datetime. Default "datetime". */
|
|
927
|
+
mode?: DateTimeMode;
|
|
928
|
+
/** Minimum selectable date (inclusive). */
|
|
929
|
+
minDate?: Date;
|
|
930
|
+
/** Maximum selectable date (inclusive). */
|
|
931
|
+
maxDate?: Date;
|
|
932
|
+
/** Disable the trigger and prevent all interaction. */
|
|
933
|
+
disabled?: boolean;
|
|
934
|
+
/** Placeholder text in the trigger when no value is selected. */
|
|
935
|
+
placeholder?: string;
|
|
936
|
+
/**
|
|
937
|
+
* Display-format string.
|
|
938
|
+
* Tokens: YYYY YY MMMM MMM MM M DD D HH H hh h mm ss A a
|
|
939
|
+
* @example "YYYY-MM-DD HH:mm:ss"
|
|
940
|
+
*/
|
|
941
|
+
format?: string;
|
|
942
|
+
/** Use 24-hour clock. false → 12-hour with AM/PM column. Default true. */
|
|
943
|
+
use24Hour?: boolean;
|
|
944
|
+
/** Show seconds column when mode includes time. Default true. */
|
|
945
|
+
showSeconds?: boolean;
|
|
946
|
+
/** BCP-47 locale tag for month/weekday names. Default "en-US". */
|
|
947
|
+
locale?: string;
|
|
948
|
+
/** Extra class applied to the root wrapper element. */
|
|
949
|
+
className?: string;
|
|
950
|
+
/** Extra class applied to the frosted-glass popup panel. */
|
|
951
|
+
popupClassName?: string;
|
|
952
|
+
/** Extra class applied to the trigger button. */
|
|
953
|
+
triggerClassName?: string;
|
|
954
|
+
/** Called when the picker popup opens. */
|
|
955
|
+
onOpen?: () => void;
|
|
956
|
+
/** Called when the picker popup closes (cancel OR confirm). */
|
|
957
|
+
onClose?: () => void;
|
|
958
|
+
}
|
|
959
|
+
export { DateTimePickerProps }
|
|
960
|
+
export { DateTimePickerProps as DateTimePickerProps_alias_1 }
|
|
961
|
+
export { DateTimePickerProps as DateTimePickerProps_alias_2 }
|
|
962
|
+
export { DateTimePickerProps as DateTimePickerProps_alias_3 }
|
|
963
|
+
|
|
880
964
|
export declare const default_alias: {
|
|
881
965
|
Primitives: {
|
|
882
966
|
Button: Button;
|
|
@@ -896,11 +980,15 @@ export declare const default_alias: {
|
|
|
896
980
|
AvatarGroup: AvatarGroup;
|
|
897
981
|
Slider: Slider;
|
|
898
982
|
SliderRange: SliderRange;
|
|
983
|
+
Rating: Rating;
|
|
984
|
+
Kbd: Kbd;
|
|
985
|
+
KbdGroup: KbdGroup;
|
|
899
986
|
};
|
|
900
987
|
Layout: {
|
|
901
988
|
Card: Card;
|
|
902
989
|
ImageCard: ImageCard;
|
|
903
990
|
Panel: Panel;
|
|
991
|
+
SplitPanel: SplitPanel;
|
|
904
992
|
};
|
|
905
993
|
DataDisplay: {
|
|
906
994
|
Table: Table;
|
|
@@ -910,6 +998,7 @@ export declare const default_alias: {
|
|
|
910
998
|
CodeBlock: CodeBlock;
|
|
911
999
|
Stat: Stat;
|
|
912
1000
|
MetricCard: MetricCard;
|
|
1001
|
+
VirtualList: <T>(props: VirtualListProps<T> & React.RefAttributes<VirtualListHandle>) => React.ReactElement;
|
|
913
1002
|
};
|
|
914
1003
|
Navigation: {
|
|
915
1004
|
SideNav: SideNav;
|
|
@@ -946,9 +1035,13 @@ export declare const default_alias: {
|
|
|
946
1035
|
TypewriterText: TypewriterText;
|
|
947
1036
|
CommandPalette: CommandPalette;
|
|
948
1037
|
Timeline: Timeline;
|
|
1038
|
+
DateTimePicker: DateTimePicker;
|
|
1039
|
+
LoginPanel: LoginPanel;
|
|
1040
|
+
RichTextEditor: ForwardRefExoticComponent<RichTextEditorProps & RefAttributes<RichTextEditorHandle>>;
|
|
949
1041
|
};
|
|
950
1042
|
Forms: {
|
|
951
1043
|
Form: Form;
|
|
1044
|
+
OTPInput: OTPInput;
|
|
952
1045
|
};
|
|
953
1046
|
Chart: {
|
|
954
1047
|
LineChart: LineChart;
|
|
@@ -1002,8 +1095,40 @@ export declare function default_alias_119(): JSX.Element;
|
|
|
1002
1095
|
|
|
1003
1096
|
export declare function default_alias_12(): JSX.Element;
|
|
1004
1097
|
|
|
1098
|
+
export declare function default_alias_120(): JSX.Element;
|
|
1099
|
+
|
|
1100
|
+
export declare function default_alias_121(): JSX.Element;
|
|
1101
|
+
|
|
1102
|
+
export declare function default_alias_122(): JSX.Element;
|
|
1103
|
+
|
|
1104
|
+
export declare function default_alias_123(): JSX.Element;
|
|
1105
|
+
|
|
1106
|
+
export declare function default_alias_124(): JSX.Element;
|
|
1107
|
+
|
|
1108
|
+
export declare function default_alias_125(): JSX.Element;
|
|
1109
|
+
|
|
1110
|
+
export declare function default_alias_126(): JSX.Element;
|
|
1111
|
+
|
|
1112
|
+
export declare function default_alias_127(): JSX.Element;
|
|
1113
|
+
|
|
1114
|
+
export declare function default_alias_128(): JSX.Element;
|
|
1115
|
+
|
|
1116
|
+
export declare function default_alias_129(): JSX.Element;
|
|
1117
|
+
|
|
1005
1118
|
export declare function default_alias_13(): JSX.Element;
|
|
1006
1119
|
|
|
1120
|
+
export declare function default_alias_130(): JSX.Element;
|
|
1121
|
+
|
|
1122
|
+
export declare function default_alias_131(): JSX.Element;
|
|
1123
|
+
|
|
1124
|
+
export declare function default_alias_132(): JSX.Element;
|
|
1125
|
+
|
|
1126
|
+
export declare function default_alias_133(): JSX.Element;
|
|
1127
|
+
|
|
1128
|
+
export declare function default_alias_134(): JSX.Element;
|
|
1129
|
+
|
|
1130
|
+
export declare function default_alias_135(): JSX.Element;
|
|
1131
|
+
|
|
1007
1132
|
export declare function default_alias_14(): JSX.Element;
|
|
1008
1133
|
|
|
1009
1134
|
export declare function default_alias_15(): JSX.Element;
|
|
@@ -1487,6 +1612,11 @@ export { DropdownSingleProps }
|
|
|
1487
1612
|
export { DropdownSingleProps as DropdownSingleProps_alias_1 }
|
|
1488
1613
|
export { DropdownSingleProps as DropdownSingleProps_alias_2 }
|
|
1489
1614
|
|
|
1615
|
+
export declare const EmbedFrame: Node_2<any, any>;
|
|
1616
|
+
|
|
1617
|
+
/** Distribute `totalPx` equally among the provided ids. */
|
|
1618
|
+
export declare function even(ids: string[], totalPx: number): Record<string, number>;
|
|
1619
|
+
|
|
1490
1620
|
declare const Extras: {
|
|
1491
1621
|
FilmReel: typeof FilmReel;
|
|
1492
1622
|
MiniPlayer: typeof MiniPlayer;
|
|
@@ -1496,6 +1626,9 @@ declare const Extras: {
|
|
|
1496
1626
|
TypewriterText: typeof TypewriterText;
|
|
1497
1627
|
CommandPalette: typeof CommandPalette;
|
|
1498
1628
|
Timeline: typeof Timeline;
|
|
1629
|
+
DateTimePicker: typeof DateTimePicker;
|
|
1630
|
+
LoginPanel: typeof LoginPanel;
|
|
1631
|
+
RichTextEditor: ForwardRefExoticComponent<RichTextEditorProps & RefAttributes<RichTextEditorHandle>>;
|
|
1499
1632
|
};
|
|
1500
1633
|
export { Extras }
|
|
1501
1634
|
export { Extras as Extras_alias_1 }
|
|
@@ -1692,6 +1825,18 @@ export { FilmReelProps }
|
|
|
1692
1825
|
export { FilmReelProps as FilmReelProps_alias_1 }
|
|
1693
1826
|
export { FilmReelProps as FilmReelProps_alias_2 }
|
|
1694
1827
|
|
|
1828
|
+
/**
|
|
1829
|
+
* Find all occurrences of `query` in a ProseMirror document.
|
|
1830
|
+
* Returns positions in ProseMirror document coordinates.
|
|
1831
|
+
*/
|
|
1832
|
+
export declare function findMatchesInDoc(doc: Node_3, query: string, caseSensitive?: boolean): TextMatch[];
|
|
1833
|
+
|
|
1834
|
+
/**
|
|
1835
|
+
* Find all occurrences of `query` in a plain string (for Markdown textarea).
|
|
1836
|
+
* Returns [start, end] character index pairs.
|
|
1837
|
+
*/
|
|
1838
|
+
export declare function findMatchesInText(text: string, query: string, caseSensitive?: boolean): Array<[number, number]>;
|
|
1839
|
+
|
|
1695
1840
|
/** Finds the index of the nearest category to a given SVG x position. */
|
|
1696
1841
|
export declare function findNearestCategoryIndex(svgX: number, categories: string[], xScale: (cat: string) => number): number;
|
|
1697
1842
|
|
|
@@ -1704,6 +1849,8 @@ export { Form as Form_alias_3 }
|
|
|
1704
1849
|
/** Formats an axis value using an optional custom formatter. */
|
|
1705
1850
|
export declare function formatAxisValue(v: number | string, formatter?: (v: number | string) => string): string;
|
|
1706
1851
|
|
|
1852
|
+
export declare function formatDate(date: Date, format: string, locale?: string): string;
|
|
1853
|
+
|
|
1707
1854
|
declare function FormItem({ label, layout: itemLayout, required, hint, validation, name, onValidate, className, children, }: FormItemProps): JSX.Element;
|
|
1708
1855
|
export { FormItem }
|
|
1709
1856
|
export { FormItem as FormItem_alias_1 }
|
|
@@ -1789,6 +1936,7 @@ export { FormProps as FormProps_alias_2 }
|
|
|
1789
1936
|
|
|
1790
1937
|
declare const Forms: {
|
|
1791
1938
|
Form: typeof Form;
|
|
1939
|
+
OTPInput: typeof OTPInput;
|
|
1792
1940
|
};
|
|
1793
1941
|
export { Forms }
|
|
1794
1942
|
export { Forms as Forms_alias_1 }
|
|
@@ -1846,12 +1994,46 @@ declare const formVariants: (props?: ({
|
|
|
1846
1994
|
export { formVariants }
|
|
1847
1995
|
export { formVariants as formVariants_alias_1 }
|
|
1848
1996
|
|
|
1997
|
+
export declare function getCalendarDays(year: number, month: number): CalendarDay[];
|
|
1998
|
+
|
|
1999
|
+
export declare function getDaysInMonth(year: number, month: number): number;
|
|
2000
|
+
|
|
2001
|
+
export declare function getDefaultFormat(mode: DateTimeMode, use24Hour?: boolean, showSeconds?: boolean): string;
|
|
2002
|
+
|
|
1849
2003
|
/** Returns an array of CSS custom property references for chart series colors. */
|
|
1850
2004
|
export declare function getDefaultPalette(count: number): string[];
|
|
1851
2005
|
|
|
2006
|
+
export declare function getMonthNames(locale?: string, format?: "long" | "short"): string[];
|
|
2007
|
+
|
|
2008
|
+
export declare function getWeekdayNames(locale?: string, format?: "long" | "narrow" | "short"): string[];
|
|
2009
|
+
|
|
1852
2010
|
/** Gets the y value for a series at a given category key. */
|
|
1853
2011
|
export declare function getYAtCategory(series: ChartSeries, category: string): number | undefined;
|
|
1854
2012
|
|
|
2013
|
+
export declare function getYearRange(center: number, span?: number): number[];
|
|
2014
|
+
|
|
2015
|
+
/** State passed to a rendered handle element. */
|
|
2016
|
+
export declare interface _HandleProps {
|
|
2017
|
+
/** Index in the visible-pane array: handle sits between [index] and [index+1]. */
|
|
2018
|
+
index: number;
|
|
2019
|
+
/** Configuration of the pane to the left / above. */
|
|
2020
|
+
paneA: SplitPanelPane;
|
|
2021
|
+
/** Configuration of the pane to the right / below. */
|
|
2022
|
+
paneB: SplitPanelPane;
|
|
2023
|
+
/** Whether this handle is currently being dragged. */
|
|
2024
|
+
isDragging: boolean;
|
|
2025
|
+
/** Visual bar thickness in px. */
|
|
2026
|
+
handleSize: number;
|
|
2027
|
+
/** Are panels stacked horizontally? */
|
|
2028
|
+
isHorizontal: boolean;
|
|
2029
|
+
/** Pointer event handlers. */
|
|
2030
|
+
onPointerDown: (e: React_2.PointerEvent<HTMLDivElement>) => void;
|
|
2031
|
+
onPointerMove: (e: React_2.PointerEvent<HTMLDivElement>) => void;
|
|
2032
|
+
onPointerUp: (e: React_2.PointerEvent<HTMLDivElement>) => void;
|
|
2033
|
+
/** Keyboard step resize handler. */
|
|
2034
|
+
onKeyDown: (e: React_2.KeyboardEvent<HTMLDivElement>) => void;
|
|
2035
|
+
}
|
|
2036
|
+
|
|
1855
2037
|
declare function Header({ brand, onBrandClick, navItems, actions, linkComponent: Link, height, mobileMenu, navMenuIcon, actionsMenuIcon, className, children, }: HeaderProps): JSX.Element;
|
|
1856
2038
|
export { Header }
|
|
1857
2039
|
export { Header as Header_alias_1 }
|
|
@@ -1949,6 +2131,14 @@ declare type HorizontalCardProps = Omit<React_2.HTMLAttributes<HTMLDivElement>,
|
|
|
1949
2131
|
stackOnMobile?: boolean;
|
|
1950
2132
|
};
|
|
1951
2133
|
|
|
2134
|
+
/**
|
|
2135
|
+
* Converts HTML produced by Tiptap to Markdown.
|
|
2136
|
+
* Handles headings, bold, italic, strikethrough, code, links,
|
|
2137
|
+
* images, ordered/unordered lists, blockquotes, horizontal rules,
|
|
2138
|
+
* and falls back to plain text for unrecognised tags.
|
|
2139
|
+
*/
|
|
2140
|
+
export declare function htmlToMarkdown(html: string): string;
|
|
2141
|
+
|
|
1952
2142
|
declare function ImageCard({ src, alt, aspectRatio, className, children, ...props }: ImageCardProps): JSX.Element;
|
|
1953
2143
|
export { ImageCard }
|
|
1954
2144
|
export { ImageCard as ImageCard_alias_1 }
|
|
@@ -2063,9 +2253,72 @@ export { inputVariants }
|
|
|
2063
2253
|
export { inputVariants as inputVariants_alias_1 }
|
|
2064
2254
|
export { inputVariants as inputVariants_alias_2 }
|
|
2065
2255
|
|
|
2256
|
+
export declare function isAfterDay(a: Date, b: Date): boolean;
|
|
2257
|
+
|
|
2258
|
+
export declare function isBeforeDay(a: Date, b: Date): boolean;
|
|
2259
|
+
|
|
2260
|
+
export declare function isSameDay(a: Date, b: Date): boolean;
|
|
2261
|
+
|
|
2066
2262
|
/** Returns true if any data point in the series has a string x value. */
|
|
2067
2263
|
export declare function isSeriesCategorical(series: ChartSeries[]): boolean;
|
|
2068
2264
|
|
|
2265
|
+
export declare function isToday(date: Date): boolean;
|
|
2266
|
+
|
|
2267
|
+
export declare const ITEM_H = 40;
|
|
2268
|
+
|
|
2269
|
+
declare function Kbd({ size, variant, className, children, ...rest }: KbdProps): JSX.Element;
|
|
2270
|
+
export { Kbd }
|
|
2271
|
+
export { Kbd as Kbd_alias_1 }
|
|
2272
|
+
export { Kbd as Kbd_alias_2 }
|
|
2273
|
+
export { Kbd as Kbd_alias_3 }
|
|
2274
|
+
|
|
2275
|
+
declare function KbdGroup({ separator, className, children }: KbdGroupProps): JSX.Element;
|
|
2276
|
+
export { KbdGroup }
|
|
2277
|
+
export { KbdGroup as KbdGroup_alias_1 }
|
|
2278
|
+
export { KbdGroup as KbdGroup_alias_2 }
|
|
2279
|
+
export { KbdGroup as KbdGroup_alias_3 }
|
|
2280
|
+
|
|
2281
|
+
declare interface KbdGroupProps {
|
|
2282
|
+
separator?: React_2.ReactNode;
|
|
2283
|
+
className?: string;
|
|
2284
|
+
children: React_2.ReactNode;
|
|
2285
|
+
}
|
|
2286
|
+
export { KbdGroupProps }
|
|
2287
|
+
export { KbdGroupProps as KbdGroupProps_alias_1 }
|
|
2288
|
+
export { KbdGroupProps as KbdGroupProps_alias_2 }
|
|
2289
|
+
export { KbdGroupProps as KbdGroupProps_alias_3 }
|
|
2290
|
+
|
|
2291
|
+
declare interface KbdProps extends React_2.HTMLAttributes<HTMLElement> {
|
|
2292
|
+
size?: KbdSize;
|
|
2293
|
+
variant?: KbdVariant;
|
|
2294
|
+
className?: string;
|
|
2295
|
+
children: React_2.ReactNode;
|
|
2296
|
+
}
|
|
2297
|
+
export { KbdProps }
|
|
2298
|
+
export { KbdProps as KbdProps_alias_1 }
|
|
2299
|
+
export { KbdProps as KbdProps_alias_2 }
|
|
2300
|
+
export { KbdProps as KbdProps_alias_3 }
|
|
2301
|
+
|
|
2302
|
+
declare type KbdSize = "xs" | "sm" | "md" | "lg";
|
|
2303
|
+
export { KbdSize }
|
|
2304
|
+
export { KbdSize as KbdSize_alias_1 }
|
|
2305
|
+
export { KbdSize as KbdSize_alias_2 }
|
|
2306
|
+
export { KbdSize as KbdSize_alias_3 }
|
|
2307
|
+
|
|
2308
|
+
declare type KbdVariant = "default" | "outline" | "ghost";
|
|
2309
|
+
export { KbdVariant }
|
|
2310
|
+
export { KbdVariant as KbdVariant_alias_1 }
|
|
2311
|
+
export { KbdVariant as KbdVariant_alias_2 }
|
|
2312
|
+
export { KbdVariant as KbdVariant_alias_3 }
|
|
2313
|
+
|
|
2314
|
+
declare const kbdVariants: (props?: ({
|
|
2315
|
+
size?: "sm" | "md" | "lg" | "xs" | null | undefined;
|
|
2316
|
+
variant?: "ghost" | "outline" | "default" | null | undefined;
|
|
2317
|
+
} & ClassProp) | undefined) => string;
|
|
2318
|
+
export { kbdVariants }
|
|
2319
|
+
export { kbdVariants as kbdVariants_alias_1 }
|
|
2320
|
+
export { kbdVariants as kbdVariants_alias_2 }
|
|
2321
|
+
|
|
2069
2322
|
declare function Label({ intent, size, className, ...props }: LabelProps): JSX.Element;
|
|
2070
2323
|
export { Label }
|
|
2071
2324
|
export { Label as Label_alias_1 }
|
|
@@ -2086,6 +2339,7 @@ declare const Layout: {
|
|
|
2086
2339
|
Card: typeof Card;
|
|
2087
2340
|
ImageCard: typeof ImageCard;
|
|
2088
2341
|
Panel: typeof Panel;
|
|
2342
|
+
SplitPanel: typeof SplitPanel;
|
|
2089
2343
|
};
|
|
2090
2344
|
export { Layout }
|
|
2091
2345
|
export { Layout as Layout_alias_1 }
|
|
@@ -2165,6 +2419,44 @@ export { listVariants }
|
|
|
2165
2419
|
export { listVariants as listVariants_alias_1 }
|
|
2166
2420
|
export { listVariants as listVariants_alias_2 }
|
|
2167
2421
|
|
|
2422
|
+
declare function LoginPanel({ mode: controlledMode, onModeChange, onLogin, onRegister, onOTPComplete, onForgotPassword, logo, title, subtitle, socialLogins, showRememberMe, isLoading, error, className, style, }: LoginPanelProps): JSX.Element;
|
|
2423
|
+
export { LoginPanel }
|
|
2424
|
+
export { LoginPanel as LoginPanel_alias_1 }
|
|
2425
|
+
export { LoginPanel as LoginPanel_alias_2 }
|
|
2426
|
+
export { LoginPanel as LoginPanel_alias_3 }
|
|
2427
|
+
|
|
2428
|
+
declare type LoginPanelMode = "login" | "register" | "otp" | "forgot";
|
|
2429
|
+
export { LoginPanelMode }
|
|
2430
|
+
export { LoginPanelMode as LoginPanelMode_alias_1 }
|
|
2431
|
+
export { LoginPanelMode as LoginPanelMode_alias_2 }
|
|
2432
|
+
export { LoginPanelMode as LoginPanelMode_alias_3 }
|
|
2433
|
+
|
|
2434
|
+
declare interface LoginPanelProps {
|
|
2435
|
+
mode?: LoginPanelMode;
|
|
2436
|
+
onModeChange?: (mode: LoginPanelMode) => void;
|
|
2437
|
+
onLogin?: (email: string, password: string, rememberMe: boolean) => void | Promise<void>;
|
|
2438
|
+
onRegister?: (name: string, email: string, password: string) => void | Promise<void>;
|
|
2439
|
+
onOTPComplete?: (otp: string) => void | Promise<void>;
|
|
2440
|
+
onForgotPassword?: (email: string) => void | Promise<void>;
|
|
2441
|
+
logo?: React_2.ReactNode;
|
|
2442
|
+
title?: string;
|
|
2443
|
+
subtitle?: string;
|
|
2444
|
+
socialLogins?: Array<{
|
|
2445
|
+
label: string;
|
|
2446
|
+
icon: React_2.ReactNode;
|
|
2447
|
+
onClick: () => void;
|
|
2448
|
+
}>;
|
|
2449
|
+
showRememberMe?: boolean;
|
|
2450
|
+
isLoading?: boolean;
|
|
2451
|
+
error?: string;
|
|
2452
|
+
className?: string;
|
|
2453
|
+
style?: CSSProperties;
|
|
2454
|
+
}
|
|
2455
|
+
export { LoginPanelProps }
|
|
2456
|
+
export { LoginPanelProps as LoginPanelProps_alias_1 }
|
|
2457
|
+
export { LoginPanelProps as LoginPanelProps_alias_2 }
|
|
2458
|
+
export { LoginPanelProps as LoginPanelProps_alias_3 }
|
|
2459
|
+
|
|
2168
2460
|
/**
|
|
2169
2461
|
* Pinterest-style waterfall / masonry layout with rich interactions.
|
|
2170
2462
|
*
|
|
@@ -2362,6 +2654,66 @@ export { navLinkVariants }
|
|
|
2362
2654
|
export { navLinkVariants as navLinkVariants_alias_1 }
|
|
2363
2655
|
export { navLinkVariants as navLinkVariants_alias_2 }
|
|
2364
2656
|
|
|
2657
|
+
declare type OffsetDirection = "future" | "past";
|
|
2658
|
+
export { OffsetDirection }
|
|
2659
|
+
export { OffsetDirection as OffsetDirection_alias_1 }
|
|
2660
|
+
export { OffsetDirection as OffsetDirection_alias_2 }
|
|
2661
|
+
export { OffsetDirection as OffsetDirection_alias_3 }
|
|
2662
|
+
|
|
2663
|
+
declare type OffsetUnit = "day" | "week" | "month" | "year";
|
|
2664
|
+
export { OffsetUnit }
|
|
2665
|
+
export { OffsetUnit as OffsetUnit_alias_1 }
|
|
2666
|
+
export { OffsetUnit as OffsetUnit_alias_2 }
|
|
2667
|
+
export { OffsetUnit as OffsetUnit_alias_3 }
|
|
2668
|
+
|
|
2669
|
+
declare function OTPInput({ length, value: controlledValue, defaultValue, onChange, onComplete, size, variant, disabled, readOnly, autoFocus, alphanumeric, mask, invalid, className, }: OTPInputProps): JSX.Element;
|
|
2670
|
+
export { OTPInput }
|
|
2671
|
+
export { OTPInput as OTPInput_alias_1 }
|
|
2672
|
+
export { OTPInput as OTPInput_alias_2 }
|
|
2673
|
+
export { OTPInput as OTPInput_alias_3 }
|
|
2674
|
+
|
|
2675
|
+
declare interface OTPInputProps {
|
|
2676
|
+
length?: number;
|
|
2677
|
+
value?: string;
|
|
2678
|
+
defaultValue?: string;
|
|
2679
|
+
onChange?: (value: string) => void;
|
|
2680
|
+
onComplete?: (value: string) => void;
|
|
2681
|
+
size?: OTPInputSize;
|
|
2682
|
+
variant?: OTPInputVariant;
|
|
2683
|
+
disabled?: boolean;
|
|
2684
|
+
readOnly?: boolean;
|
|
2685
|
+
autoFocus?: boolean;
|
|
2686
|
+
alphanumeric?: boolean;
|
|
2687
|
+
mask?: boolean;
|
|
2688
|
+
invalid?: boolean;
|
|
2689
|
+
className?: string;
|
|
2690
|
+
}
|
|
2691
|
+
export { OTPInputProps }
|
|
2692
|
+
export { OTPInputProps as OTPInputProps_alias_1 }
|
|
2693
|
+
export { OTPInputProps as OTPInputProps_alias_2 }
|
|
2694
|
+
export { OTPInputProps as OTPInputProps_alias_3 }
|
|
2695
|
+
|
|
2696
|
+
declare type OTPInputSize = "sm" | "md" | "lg";
|
|
2697
|
+
export { OTPInputSize }
|
|
2698
|
+
export { OTPInputSize as OTPInputSize_alias_1 }
|
|
2699
|
+
export { OTPInputSize as OTPInputSize_alias_2 }
|
|
2700
|
+
export { OTPInputSize as OTPInputSize_alias_3 }
|
|
2701
|
+
|
|
2702
|
+
declare type OTPInputVariant = "outline" | "filled" | "underline";
|
|
2703
|
+
export { OTPInputVariant }
|
|
2704
|
+
export { OTPInputVariant as OTPInputVariant_alias_1 }
|
|
2705
|
+
export { OTPInputVariant as OTPInputVariant_alias_2 }
|
|
2706
|
+
export { OTPInputVariant as OTPInputVariant_alias_3 }
|
|
2707
|
+
|
|
2708
|
+
declare const otpInputVariants: (props?: ({
|
|
2709
|
+
size?: "sm" | "md" | "lg" | null | undefined;
|
|
2710
|
+
variant?: "outline" | "underline" | "filled" | null | undefined;
|
|
2711
|
+
invalid?: boolean | null | undefined;
|
|
2712
|
+
} & ClassProp) | undefined) => string;
|
|
2713
|
+
export { otpInputVariants }
|
|
2714
|
+
export { otpInputVariants as otpInputVariants_alias_1 }
|
|
2715
|
+
export { otpInputVariants as otpInputVariants_alias_2 }
|
|
2716
|
+
|
|
2365
2717
|
declare const Overlay: {
|
|
2366
2718
|
Dialog: typeof Dialog;
|
|
2367
2719
|
Tooltip: typeof Tooltip;
|
|
@@ -2431,6 +2783,13 @@ export { panelVariants }
|
|
|
2431
2783
|
export { panelVariants as panelVariants_alias_1 }
|
|
2432
2784
|
export { panelVariants as panelVariants_alias_2 }
|
|
2433
2785
|
|
|
2786
|
+
/**
|
|
2787
|
+
* Parse Markdown to HTML using marked.
|
|
2788
|
+
* Returns synchronously; marked v12+ may return Promise for async renderers,
|
|
2789
|
+
* but the default renderer is synchronous with no async extensions.
|
|
2790
|
+
*/
|
|
2791
|
+
export declare function parseMarkdown(md: string): string;
|
|
2792
|
+
|
|
2434
2793
|
declare function PieChart({ data, donut, donutThickness, startAngle, padAngle, labelType, centerLabel, centerSubLabel, explodeOnHover, explodeOffset, title, height, className, legend, legendPosition, animateOnMount, emptyText, }: PieChartProps): JSX.Element;
|
|
2435
2794
|
export { PieChart }
|
|
2436
2795
|
export { PieChart as PieChart_alias_1 }
|
|
@@ -2496,6 +2855,9 @@ declare const Primitives: {
|
|
|
2496
2855
|
AvatarGroup: typeof AvatarGroup;
|
|
2497
2856
|
Slider: typeof Slider;
|
|
2498
2857
|
SliderRange: typeof SliderRange;
|
|
2858
|
+
Rating: typeof Rating;
|
|
2859
|
+
Kbd: typeof Kbd;
|
|
2860
|
+
KbdGroup: typeof KbdGroup;
|
|
2499
2861
|
};
|
|
2500
2862
|
export { Primitives }
|
|
2501
2863
|
export { Primitives as Primitives_alias_1 }
|
|
@@ -2599,8 +2961,57 @@ export { radioVariants }
|
|
|
2599
2961
|
export { radioVariants as radioVariants_alias_1 }
|
|
2600
2962
|
export { radioVariants as radioVariants_alias_2 }
|
|
2601
2963
|
|
|
2964
|
+
declare function Rating({ value: controlledValue, defaultValue, max, size, intent, precision, readOnly, disabled, onChange, icon, emptyIcon, label, className, }: RatingProps): JSX.Element;
|
|
2965
|
+
export { Rating }
|
|
2966
|
+
export { Rating as Rating_alias_1 }
|
|
2967
|
+
export { Rating as Rating_alias_2 }
|
|
2968
|
+
export { Rating as Rating_alias_3 }
|
|
2969
|
+
|
|
2970
|
+
declare type RatingIntent = "warning" | "danger" | "success" | "primary";
|
|
2971
|
+
export { RatingIntent }
|
|
2972
|
+
export { RatingIntent as RatingIntent_alias_1 }
|
|
2973
|
+
export { RatingIntent as RatingIntent_alias_2 }
|
|
2974
|
+
export { RatingIntent as RatingIntent_alias_3 }
|
|
2975
|
+
|
|
2976
|
+
declare interface RatingProps {
|
|
2977
|
+
value?: number;
|
|
2978
|
+
defaultValue?: number;
|
|
2979
|
+
max?: number;
|
|
2980
|
+
size?: RatingSize;
|
|
2981
|
+
intent?: RatingIntent;
|
|
2982
|
+
precision?: 0.5 | 1;
|
|
2983
|
+
readOnly?: boolean;
|
|
2984
|
+
disabled?: boolean;
|
|
2985
|
+
onChange?: (value: number) => void;
|
|
2986
|
+
icon?: React_2.ReactNode;
|
|
2987
|
+
emptyIcon?: React_2.ReactNode;
|
|
2988
|
+
label?: string;
|
|
2989
|
+
className?: string;
|
|
2990
|
+
}
|
|
2991
|
+
export { RatingProps }
|
|
2992
|
+
export { RatingProps as RatingProps_alias_1 }
|
|
2993
|
+
export { RatingProps as RatingProps_alias_2 }
|
|
2994
|
+
export { RatingProps as RatingProps_alias_3 }
|
|
2995
|
+
|
|
2996
|
+
declare type RatingSize = "sm" | "md" | "lg";
|
|
2997
|
+
export { RatingSize }
|
|
2998
|
+
export { RatingSize as RatingSize_alias_1 }
|
|
2999
|
+
export { RatingSize as RatingSize_alias_2 }
|
|
3000
|
+
export { RatingSize as RatingSize_alias_3 }
|
|
3001
|
+
|
|
3002
|
+
declare const ratingVariants: (props?: ({
|
|
3003
|
+
size?: "sm" | "md" | "lg" | null | undefined;
|
|
3004
|
+
} & ClassProp) | undefined) => string;
|
|
3005
|
+
export { ratingVariants }
|
|
3006
|
+
export { ratingVariants as ratingVariants_alias_1 }
|
|
3007
|
+
export { ratingVariants as ratingVariants_alias_2 }
|
|
3008
|
+
|
|
2602
3009
|
declare function removeAlert(id: string): void;
|
|
2603
3010
|
|
|
3011
|
+
export declare const ResizableImage: Node_2<ImageOptions, any>;
|
|
3012
|
+
|
|
3013
|
+
export declare const ResizableVideo: Node_2<any, any>;
|
|
3014
|
+
|
|
2604
3015
|
declare function RibbonBar({ tabs, defaultTab, activeTab: controlledTab, onTabChange, mode: controlledMode, onModeChange, sticky, className, }: RibbonBarProps): JSX.Element;
|
|
2605
3016
|
export { RibbonBar }
|
|
2606
3017
|
export { RibbonBar as RibbonBar_alias_1 }
|
|
@@ -2643,6 +3054,8 @@ export { RibbonGroup as RibbonGroup_alias_1 }
|
|
|
2643
3054
|
export { RibbonGroup as RibbonGroup_alias_2 }
|
|
2644
3055
|
export { RibbonGroup as RibbonGroup_alias_3 }
|
|
2645
3056
|
export { RibbonGroup as RibbonGroup_alias_4 }
|
|
3057
|
+
export { RibbonGroup as RibbonGroup_alias_5 }
|
|
3058
|
+
export { RibbonGroup as RibbonGroup_alias_6 }
|
|
2646
3059
|
|
|
2647
3060
|
declare interface RibbonItem {
|
|
2648
3061
|
key: string;
|
|
@@ -2662,6 +3075,8 @@ export { RibbonItem as RibbonItem_alias_1 }
|
|
|
2662
3075
|
export { RibbonItem as RibbonItem_alias_2 }
|
|
2663
3076
|
export { RibbonItem as RibbonItem_alias_3 }
|
|
2664
3077
|
export { RibbonItem as RibbonItem_alias_4 }
|
|
3078
|
+
export { RibbonItem as RibbonItem_alias_5 }
|
|
3079
|
+
export { RibbonItem as RibbonItem_alias_6 }
|
|
2665
3080
|
|
|
2666
3081
|
declare type RibbonMode = "full" | "compact" | "icons";
|
|
2667
3082
|
export { RibbonMode }
|
|
@@ -2685,6 +3100,190 @@ export { RibbonTab as RibbonTab_alias_1 }
|
|
|
2685
3100
|
export { RibbonTab as RibbonTab_alias_2 }
|
|
2686
3101
|
export { RibbonTab as RibbonTab_alias_3 }
|
|
2687
3102
|
export { RibbonTab as RibbonTab_alias_4 }
|
|
3103
|
+
export { RibbonTab as RibbonTab_alias_5 }
|
|
3104
|
+
export { RibbonTab as RibbonTab_alias_6 }
|
|
3105
|
+
|
|
3106
|
+
/** Built-in tab keys for use with extraRibbonGroups. */
|
|
3107
|
+
declare type RichEditorBuiltInTabKey = "home" | "insert" | "format";
|
|
3108
|
+
export { RichEditorBuiltInTabKey }
|
|
3109
|
+
export { RichEditorBuiltInTabKey as RichEditorBuiltInTabKey_alias_1 }
|
|
3110
|
+
export { RichEditorBuiltInTabKey as RichEditorBuiltInTabKey_alias_2 }
|
|
3111
|
+
|
|
3112
|
+
declare type RichEditorMode = "richtext" | "markdown";
|
|
3113
|
+
export { RichEditorMode }
|
|
3114
|
+
export { RichEditorMode as RichEditorMode_alias_1 }
|
|
3115
|
+
export { RichEditorMode as RichEditorMode_alias_2 }
|
|
3116
|
+
export { RichEditorMode as RichEditorMode_alias_3 }
|
|
3117
|
+
|
|
3118
|
+
declare const RichTextEditor: React_2.ForwardRefExoticComponent<RichTextEditorProps & React_2.RefAttributes<RichTextEditorHandle>>;
|
|
3119
|
+
export { RichTextEditor }
|
|
3120
|
+
export { RichTextEditor as RichTextEditor_alias_1 }
|
|
3121
|
+
export { RichTextEditor as RichTextEditor_alias_2 }
|
|
3122
|
+
export { RichTextEditor as RichTextEditor_alias_3 }
|
|
3123
|
+
|
|
3124
|
+
declare interface RichTextEditorHandle {
|
|
3125
|
+
/** Returns HTML when in richtext mode, raw Markdown when in markdown mode. */
|
|
3126
|
+
getContent: () => string;
|
|
3127
|
+
/** The currently active editor mode. */
|
|
3128
|
+
getMode: () => RichEditorMode;
|
|
3129
|
+
getHTML: () => string;
|
|
3130
|
+
getMarkdown: () => string;
|
|
3131
|
+
getJSON: () => object;
|
|
3132
|
+
getText: () => string;
|
|
3133
|
+
setHTML: (html: string) => void;
|
|
3134
|
+
setMarkdown: (md: string) => void;
|
|
3135
|
+
setJSON: (json: object) => void;
|
|
3136
|
+
clear: () => void;
|
|
3137
|
+
focus: () => void;
|
|
3138
|
+
blur: () => void;
|
|
3139
|
+
}
|
|
3140
|
+
export { RichTextEditorHandle }
|
|
3141
|
+
export { RichTextEditorHandle as RichTextEditorHandle_alias_1 }
|
|
3142
|
+
export { RichTextEditorHandle as RichTextEditorHandle_alias_2 }
|
|
3143
|
+
export { RichTextEditorHandle as RichTextEditorHandle_alias_3 }
|
|
3144
|
+
|
|
3145
|
+
/**
|
|
3146
|
+
* All user-visible strings in the RichTextEditor ribbon bar.
|
|
3147
|
+
* Pass a partial record to override only the strings you need.
|
|
3148
|
+
*
|
|
3149
|
+
* Keys follow the pattern:
|
|
3150
|
+
* - tab_<tabKey> → tab header label
|
|
3151
|
+
* - group_<groupKey> → group header label
|
|
3152
|
+
* - <buttonKey> → button label
|
|
3153
|
+
*/
|
|
3154
|
+
declare interface RichTextEditorLabels {
|
|
3155
|
+
tab_home: string;
|
|
3156
|
+
tab_insert: string;
|
|
3157
|
+
tab_format: string;
|
|
3158
|
+
group_clipboard: string;
|
|
3159
|
+
undo: string;
|
|
3160
|
+
redo: string;
|
|
3161
|
+
group_text: string;
|
|
3162
|
+
bold: string;
|
|
3163
|
+
italic: string;
|
|
3164
|
+
underline: string;
|
|
3165
|
+
strikethrough: string;
|
|
3166
|
+
group_headings: string;
|
|
3167
|
+
h1: string;
|
|
3168
|
+
h2: string;
|
|
3169
|
+
h3: string;
|
|
3170
|
+
paragraph: string;
|
|
3171
|
+
group_alignment: string;
|
|
3172
|
+
alignLeft: string;
|
|
3173
|
+
alignCenter: string;
|
|
3174
|
+
alignRight: string;
|
|
3175
|
+
alignJustify: string;
|
|
3176
|
+
group_lists: string;
|
|
3177
|
+
bulletList: string;
|
|
3178
|
+
orderedList: string;
|
|
3179
|
+
save: string;
|
|
3180
|
+
group_media: string;
|
|
3181
|
+
image: string;
|
|
3182
|
+
/** Label for the generic video/embed insert button (YouTube, Vimeo, Bilibili, mp4…). */
|
|
3183
|
+
video: string;
|
|
3184
|
+
/** @deprecated renamed to `video`; kept for backward compatibility */
|
|
3185
|
+
youtube: string;
|
|
3186
|
+
group_content: string;
|
|
3187
|
+
link: string;
|
|
3188
|
+
table: string;
|
|
3189
|
+
codeBlock: string;
|
|
3190
|
+
blockquote: string;
|
|
3191
|
+
divider: string;
|
|
3192
|
+
group_style: string;
|
|
3193
|
+
color: string;
|
|
3194
|
+
highlight: string;
|
|
3195
|
+
subscript: string;
|
|
3196
|
+
superscript: string;
|
|
3197
|
+
group_reset: string;
|
|
3198
|
+
clear: string;
|
|
3199
|
+
group_table_rows: string;
|
|
3200
|
+
addRowBefore: string;
|
|
3201
|
+
addRowAfter: string;
|
|
3202
|
+
deleteRow: string;
|
|
3203
|
+
group_table_cols: string;
|
|
3204
|
+
addColBefore: string;
|
|
3205
|
+
addColAfter: string;
|
|
3206
|
+
deleteColumn: string;
|
|
3207
|
+
group_table_cells: string;
|
|
3208
|
+
mergeCells: string;
|
|
3209
|
+
splitCell: string;
|
|
3210
|
+
deleteTable: string;
|
|
3211
|
+
}
|
|
3212
|
+
export { RichTextEditorLabels }
|
|
3213
|
+
export { RichTextEditorLabels as RichTextEditorLabels_alias_1 }
|
|
3214
|
+
export { RichTextEditorLabels as RichTextEditorLabels_alias_2 }
|
|
3215
|
+
|
|
3216
|
+
declare interface RichTextEditorProps extends RichTextEditorRibbonProps {
|
|
3217
|
+
/** Editor mode: richtext (WYSIWYG) or markdown (plain text source) */
|
|
3218
|
+
mode?: RichEditorMode;
|
|
3219
|
+
defaultMode?: RichEditorMode;
|
|
3220
|
+
onModeChange?: (mode: RichEditorMode) => void;
|
|
3221
|
+
/** Whether live preview pane is visible. Default: false (OFF) */
|
|
3222
|
+
showPreview?: boolean;
|
|
3223
|
+
/** Uncontrolled default preview visibility. Default: false */
|
|
3224
|
+
defaultShowPreview?: boolean;
|
|
3225
|
+
/** Called when preview toggle changes */
|
|
3226
|
+
onPreviewChange?: (show: boolean) => void;
|
|
3227
|
+
/** Initial HTML or Markdown content */
|
|
3228
|
+
defaultValue?: string;
|
|
3229
|
+
/** Controlled content value */
|
|
3230
|
+
value?: string;
|
|
3231
|
+
/** Called on every content change */
|
|
3232
|
+
onChange?: (value: {
|
|
3233
|
+
html: string;
|
|
3234
|
+
markdown: string;
|
|
3235
|
+
json: object;
|
|
3236
|
+
text: string;
|
|
3237
|
+
}) => void;
|
|
3238
|
+
/**
|
|
3239
|
+
* Called when the user presses Cmd/Ctrl+S or clicks the Save ribbon button.
|
|
3240
|
+
* `content` is the current editor content in the active `mode`:
|
|
3241
|
+
* HTML string for "richtext", raw Markdown string for "markdown".
|
|
3242
|
+
*/
|
|
3243
|
+
onSave?: (content: string, mode: RichEditorMode) => void;
|
|
3244
|
+
placeholder?: string;
|
|
3245
|
+
readOnly?: boolean;
|
|
3246
|
+
height?: number | string;
|
|
3247
|
+
minHeight?: number | string;
|
|
3248
|
+
maxHeight?: number | string;
|
|
3249
|
+
showWordCount?: boolean;
|
|
3250
|
+
showCharCount?: boolean;
|
|
3251
|
+
/** If provided, called on image paste/upload; return public URL. Default: base64 inline */
|
|
3252
|
+
onImageUpload?: (file: File) => Promise<string>;
|
|
3253
|
+
allowedImageTypes?: string[];
|
|
3254
|
+
maxImageSize?: number;
|
|
3255
|
+
autoFocus?: boolean;
|
|
3256
|
+
spellCheck?: boolean;
|
|
3257
|
+
className?: string;
|
|
3258
|
+
style?: React_2.CSSProperties;
|
|
3259
|
+
/**
|
|
3260
|
+
* Override any ribbon button / group / tab label for internationalisation.
|
|
3261
|
+
* Unspecified keys fall back to the built-in English defaults.
|
|
3262
|
+
*/
|
|
3263
|
+
labels?: Partial<RichTextEditorLabels>;
|
|
3264
|
+
}
|
|
3265
|
+
export { RichTextEditorProps }
|
|
3266
|
+
export { RichTextEditorProps as RichTextEditorProps_alias_1 }
|
|
3267
|
+
export { RichTextEditorProps as RichTextEditorProps_alias_2 }
|
|
3268
|
+
export { RichTextEditorProps as RichTextEditorProps_alias_3 }
|
|
3269
|
+
|
|
3270
|
+
/**
|
|
3271
|
+
* Inject extra groups into built-in ribbon tabs or supply entirely new tabs.
|
|
3272
|
+
*/
|
|
3273
|
+
declare interface RichTextEditorRibbonProps {
|
|
3274
|
+
/**
|
|
3275
|
+
* Extra `RibbonGroup[]` to append to built-in ribbon tabs.
|
|
3276
|
+
* Key is the built-in tab key ("home" | "insert" | "format").
|
|
3277
|
+
*/
|
|
3278
|
+
extraRibbonGroups?: Partial<Record<RichEditorBuiltInTabKey, RibbonGroup[]>>;
|
|
3279
|
+
/**
|
|
3280
|
+
* Additional ribbon tabs appended after the built-in tabs.
|
|
3281
|
+
*/
|
|
3282
|
+
extraRibbonTabs?: RibbonTab[];
|
|
3283
|
+
}
|
|
3284
|
+
export { RichTextEditorRibbonProps }
|
|
3285
|
+
export { RichTextEditorRibbonProps as RichTextEditorRibbonProps_alias_1 }
|
|
3286
|
+
export { RichTextEditorRibbonProps as RichTextEditorRibbonProps_alias_2 }
|
|
2688
3287
|
|
|
2689
3288
|
declare function ScatterChart({ series, xAxis, yAxis, dotRadius, dotOpacity, clusters, jitter, jitterAmount, linkedLines, title, height, className, legend, legendPosition, animateOnMount, emptyText, }: ScatterChartProps): JSX.Element;
|
|
2690
3289
|
export { ScatterChart }
|
|
@@ -2715,6 +3314,17 @@ export { ScatterChartProps }
|
|
|
2715
3314
|
export { ScatterChartProps as ScatterChartProps_alias_1 }
|
|
2716
3315
|
export { ScatterChartProps as ScatterChartProps_alias_2 }
|
|
2717
3316
|
|
|
3317
|
+
export declare const SearchExtension: Extension<any, any>;
|
|
3318
|
+
|
|
3319
|
+
export declare const searchPluginKey: PluginKey<SearchState>;
|
|
3320
|
+
|
|
3321
|
+
export declare interface SearchState {
|
|
3322
|
+
query: string;
|
|
3323
|
+
caseSensitive: boolean;
|
|
3324
|
+
currentIndex: number;
|
|
3325
|
+
matches: TextMatch[];
|
|
3326
|
+
}
|
|
3327
|
+
|
|
2718
3328
|
export declare function Section({ title, children }: {
|
|
2719
3329
|
title: string;
|
|
2720
3330
|
children: React_2.ReactNode;
|
|
@@ -2758,7 +3368,7 @@ export declare const selectVariants: (props?: ({
|
|
|
2758
3368
|
size?: "sm" | "md" | "lg" | null | undefined;
|
|
2759
3369
|
} & ClassProp) | undefined) => string;
|
|
2760
3370
|
|
|
2761
|
-
declare function SideNav({ items, title, basePath, onItemClick, LinkComponent, collapsible, collapseMode: controlledMode, defaultCollapseMode, onCollapseModeChange, showLines, expandedKeys: controlledExpandedKeys, defaultExpandedKeys, onExpandedKeysChange, className, responsive, mobileBreakpoint, mobileTopOffset, ...props }: SideNavProps): JSX.Element;
|
|
3371
|
+
declare function SideNav({ items, title, basePath, onItemClick, LinkComponent, collapsible, collapseMode: controlledMode, defaultCollapseMode, onCollapseModeChange, showLines, expandedKeys: controlledExpandedKeys, defaultExpandedKeys, onExpandedKeysChange, className, responsive, mobileBreakpoint, mobileTopOffset, mobileDrawerSlot, ...props }: SideNavProps): JSX.Element;
|
|
2762
3372
|
export { SideNav }
|
|
2763
3373
|
export { SideNav as SideNav_alias_1 }
|
|
2764
3374
|
export { SideNav as SideNav_alias_2 }
|
|
@@ -2849,6 +3459,12 @@ declare interface SideNavProps extends React_2.HTMLAttributes<HTMLElement> {
|
|
|
2849
3459
|
* Set this to the height of your app's top bar. @default 48
|
|
2850
3460
|
*/
|
|
2851
3461
|
mobileTopOffset?: number;
|
|
3462
|
+
/**
|
|
3463
|
+
* Optional slot rendered inside the mobile slide-in drawer, between the
|
|
3464
|
+
* header row and the scrollable nav body. Use it to inject a search input
|
|
3465
|
+
* or other controls that should appear on mobile too.
|
|
3466
|
+
*/
|
|
3467
|
+
mobileDrawerSlot?: React_2.ReactNode;
|
|
2852
3468
|
}
|
|
2853
3469
|
export { SideNavProps }
|
|
2854
3470
|
export { SideNavProps as SideNavProps_alias_1 }
|
|
@@ -2908,7 +3524,7 @@ export declare interface SliceSpec {
|
|
|
2908
3524
|
cy: number;
|
|
2909
3525
|
}
|
|
2910
3526
|
|
|
2911
|
-
declare function Slider({ mode, value: valueProp, defaultValue, onChange, min, max, step, intent, size, disabled, showValue, formatValue, label, className, ...props }: SliderProps): JSX.Element;
|
|
3527
|
+
declare function Slider({ mode, value: valueProp, defaultValue, onChange, min, max, step, intent, size, disabled, showValue, formatValue, label, className, id: propId, ...props }: SliderProps): JSX.Element;
|
|
2912
3528
|
export { Slider }
|
|
2913
3529
|
export { Slider as Slider_alias_1 }
|
|
2914
3530
|
export { Slider as Slider_alias_2 }
|
|
@@ -2936,7 +3552,7 @@ export { SliderProps }
|
|
|
2936
3552
|
export { SliderProps as SliderProps_alias_1 }
|
|
2937
3553
|
export { SliderProps as SliderProps_alias_2 }
|
|
2938
3554
|
|
|
2939
|
-
declare function SliderRange({ value: valueProp, defaultValue, onChange, min, max, step, intent, size, disabled, showValue, formatValue, label, className, ...props }: SliderRangeProps): JSX.Element;
|
|
3555
|
+
declare function SliderRange({ value: valueProp, defaultValue, onChange, min, max, step, intent, size, disabled, showValue, formatValue, label, className, id: propId, ...props }: SliderRangeProps): JSX.Element;
|
|
2940
3556
|
export { SliderRange }
|
|
2941
3557
|
export { SliderRange as SliderRange_alias_1 }
|
|
2942
3558
|
export { SliderRange as SliderRange_alias_2 }
|
|
@@ -3022,6 +3638,116 @@ export { spinVariants }
|
|
|
3022
3638
|
export { spinVariants as spinVariants_alias_1 }
|
|
3023
3639
|
export { spinVariants as spinVariants_alias_2 }
|
|
3024
3640
|
|
|
3641
|
+
/**
|
|
3642
|
+
* SplitPanel — VSCode-style resizable split-pane layout for desktop applications.
|
|
3643
|
+
*
|
|
3644
|
+
* - Supports horizontal (side-by-side) and vertical (stacked) splits.
|
|
3645
|
+
* - Any number of panes; each can be independently shown or hidden.
|
|
3646
|
+
* - Drag handles with hover & active visual feedback.
|
|
3647
|
+
* - Keyboard resize (arrow keys) for accessibility.
|
|
3648
|
+
* - Optional localStorage persistence via `autoSaveId`.
|
|
3649
|
+
* - Data-driven via the `panes` prop + controlled `visibility` map.
|
|
3650
|
+
*/
|
|
3651
|
+
declare function SplitPanel({ direction, panes, visibility, onVisibilityChange, width, height, handleSize, defaultBackground, autoSaveId, onResizeEnd, className, style, }: SplitPanelProps): JSX.Element;
|
|
3652
|
+
export { SplitPanel }
|
|
3653
|
+
export { SplitPanel as SplitPanel_alias_1 }
|
|
3654
|
+
export { SplitPanel as SplitPanel_alias_2 }
|
|
3655
|
+
export { SplitPanel as SplitPanel_alias_3 }
|
|
3656
|
+
|
|
3657
|
+
/**
|
|
3658
|
+
* Configuration for a single pane inside SplitPanel.
|
|
3659
|
+
*/
|
|
3660
|
+
declare interface SplitPanelPane {
|
|
3661
|
+
/** Unique identifier used to key the pane and track visibility/sizes. */
|
|
3662
|
+
id: string;
|
|
3663
|
+
/**
|
|
3664
|
+
* Initial size in pixels when the pane has no persisted size.
|
|
3665
|
+
* Panes without a `defaultSize` share remaining container space equally.
|
|
3666
|
+
*/
|
|
3667
|
+
defaultSize?: number;
|
|
3668
|
+
/** Minimum size in pixels. The pane cannot be dragged smaller than this. Default: 48. */
|
|
3669
|
+
minSize?: number;
|
|
3670
|
+
/** Maximum size in pixels. The pane cannot be dragged larger than this. Default: unlimited. */
|
|
3671
|
+
maxSize?: number;
|
|
3672
|
+
/**
|
|
3673
|
+
* CSS background color for this pane.
|
|
3674
|
+
* Overrides the container-level `defaultBackground`.
|
|
3675
|
+
* Accepts any valid CSS color value.
|
|
3676
|
+
*/
|
|
3677
|
+
background?: string;
|
|
3678
|
+
/** Additional CSS class names applied to this pane's wrapper element. */
|
|
3679
|
+
className?: string;
|
|
3680
|
+
/** Inline style overrides for this pane's wrapper element. */
|
|
3681
|
+
style?: React_2.CSSProperties;
|
|
3682
|
+
/** Pane content. */
|
|
3683
|
+
children?: React_2.ReactNode;
|
|
3684
|
+
}
|
|
3685
|
+
export { SplitPanelPane }
|
|
3686
|
+
export { SplitPanelPane as SplitPanelPane_alias_1 }
|
|
3687
|
+
export { SplitPanelPane as SplitPanelPane_alias_2 }
|
|
3688
|
+
export { SplitPanelPane as SplitPanelPane_alias_3 }
|
|
3689
|
+
export { SplitPanelPane as SplitPanelPane_alias_4 }
|
|
3690
|
+
|
|
3691
|
+
/**
|
|
3692
|
+
* Props for the SplitPanel component.
|
|
3693
|
+
*/
|
|
3694
|
+
declare interface SplitPanelProps {
|
|
3695
|
+
/**
|
|
3696
|
+
* Controls whether panes are arranged side-by-side (`"horizontal"`) or
|
|
3697
|
+
* stacked top-to-bottom (`"vertical"`). Default: `"horizontal"`.
|
|
3698
|
+
*/
|
|
3699
|
+
direction?: "horizontal" | "vertical";
|
|
3700
|
+
/**
|
|
3701
|
+
* Pane definitions. Order determines visual order left-to-right (horizontal)
|
|
3702
|
+
* or top-to-bottom (vertical).
|
|
3703
|
+
*/
|
|
3704
|
+
panes: SplitPanelPane[];
|
|
3705
|
+
/**
|
|
3706
|
+
* Controlled visibility map `{ [paneId]: boolean }`.
|
|
3707
|
+
* Omitted or `true` → visible. `false` → the pane is removed from layout
|
|
3708
|
+
* and its space is redistributed to its neighbours.
|
|
3709
|
+
*/
|
|
3710
|
+
visibility?: Record<string, boolean>;
|
|
3711
|
+
/**
|
|
3712
|
+
* Fires when the component wants to toggle a pane.
|
|
3713
|
+
* (Reserved for future imperative toggle APIs — the consumer drives state.)
|
|
3714
|
+
*/
|
|
3715
|
+
onVisibilityChange?: (id: string, visible: boolean) => void;
|
|
3716
|
+
/** Container width. Default: `"100%"`. Accepts CSS length strings or numbers (px). */
|
|
3717
|
+
width?: string | number;
|
|
3718
|
+
/** Container height. Default: `"100%"`. Accepts CSS length strings or numbers (px). */
|
|
3719
|
+
height?: string | number;
|
|
3720
|
+
/**
|
|
3721
|
+
* Visual thickness of the resize divider bar in pixels. Default: 4.
|
|
3722
|
+
* The interactive hit-area is always ≥ 8 px for usability.
|
|
3723
|
+
*/
|
|
3724
|
+
handleSize?: number;
|
|
3725
|
+
/**
|
|
3726
|
+
* Default background color applied to every pane unless the pane defines
|
|
3727
|
+
* its own `background`. Accepts any CSS color value.
|
|
3728
|
+
*/
|
|
3729
|
+
defaultBackground?: string;
|
|
3730
|
+
/**
|
|
3731
|
+
* When provided, each pane's pixel size is persisted under
|
|
3732
|
+
* `localStorage["onyx-split:<autoSaveId>"]` and restored on re-mount.
|
|
3733
|
+
*/
|
|
3734
|
+
autoSaveId?: string;
|
|
3735
|
+
/**
|
|
3736
|
+
* Called after the user finishes a resize drag interaction.
|
|
3737
|
+
* Receives a snapshot of all pane sizes (visible and hidden) in pixels.
|
|
3738
|
+
*/
|
|
3739
|
+
onResizeEnd?: (sizes: Record<string, number>) => void;
|
|
3740
|
+
/** Additional CSS class names for the container element. */
|
|
3741
|
+
className?: string;
|
|
3742
|
+
/** Inline style overrides for the container element. */
|
|
3743
|
+
style?: React_2.CSSProperties;
|
|
3744
|
+
}
|
|
3745
|
+
export { SplitPanelProps }
|
|
3746
|
+
export { SplitPanelProps as SplitPanelProps_alias_1 }
|
|
3747
|
+
export { SplitPanelProps as SplitPanelProps_alias_2 }
|
|
3748
|
+
export { SplitPanelProps as SplitPanelProps_alias_3 }
|
|
3749
|
+
export { SplitPanelProps as SplitPanelProps_alias_4 }
|
|
3750
|
+
|
|
3025
3751
|
declare function Stat({ title, value, prefix, suffix, icon, trend, trendValue, description, intent, size, className, }: StatProps): JSX.Element;
|
|
3026
3752
|
export { Stat }
|
|
3027
3753
|
export { Stat as Stat_alias_1 }
|
|
@@ -3269,6 +3995,11 @@ export { TextBoxProps }
|
|
|
3269
3995
|
export { TextBoxProps as TextBoxProps_alias_1 }
|
|
3270
3996
|
export { TextBoxProps as TextBoxProps_alias_2 }
|
|
3271
3997
|
|
|
3998
|
+
export declare interface TextMatch {
|
|
3999
|
+
from: number;
|
|
4000
|
+
to: number;
|
|
4001
|
+
}
|
|
4002
|
+
|
|
3272
4003
|
declare function Timeline({ items, orientation, activeIndex, animated, lineStyle, className, }: TimelineProps): JSX.Element;
|
|
3273
4004
|
export { Timeline }
|
|
3274
4005
|
export { Timeline as Timeline_alias_1 }
|
|
@@ -3611,6 +4342,68 @@ export declare function useCommandPalette(commands: CommandItem[], open: boolean
|
|
|
3611
4342
|
handleKeyDown: (e: React.KeyboardEvent) => void;
|
|
3612
4343
|
};
|
|
3613
4344
|
|
|
4345
|
+
export declare function useDateTimePicker(props: DateTimePickerProps): {
|
|
4346
|
+
isOpen: boolean;
|
|
4347
|
+
displayValue: string;
|
|
4348
|
+
workingDate: Date;
|
|
4349
|
+
view: "drum" | "calendar";
|
|
4350
|
+
calYear: number;
|
|
4351
|
+
calMonth: number;
|
|
4352
|
+
offsetAmount: number;
|
|
4353
|
+
offsetUnit: OffsetUnit;
|
|
4354
|
+
offsetDirection: OffsetDirection;
|
|
4355
|
+
mode: DateTimeMode;
|
|
4356
|
+
use24Hour: boolean;
|
|
4357
|
+
showSeconds: boolean;
|
|
4358
|
+
locale: string;
|
|
4359
|
+
minDate: Date | undefined;
|
|
4360
|
+
maxDate: Date | undefined;
|
|
4361
|
+
openPicker: () => void;
|
|
4362
|
+
closePicker: () => void;
|
|
4363
|
+
confirm: () => void;
|
|
4364
|
+
clear: () => void;
|
|
4365
|
+
updateField: (field: "year" | "month" | "day" | "hour" | "minute" | "second", val: number) => void;
|
|
4366
|
+
setView: Dispatch<SetStateAction<"drum" | "calendar">>;
|
|
4367
|
+
setCalYear: Dispatch<SetStateAction<number>>;
|
|
4368
|
+
setCalMonth: Dispatch<SetStateAction<number>>;
|
|
4369
|
+
setOffsetAmount: Dispatch<SetStateAction<number>>;
|
|
4370
|
+
setOffsetUnit: Dispatch<SetStateAction<OffsetUnit>>;
|
|
4371
|
+
setOffsetDirection: Dispatch<SetStateAction<OffsetDirection>>;
|
|
4372
|
+
applyQuickOffset: () => void;
|
|
4373
|
+
navigateCalendar: (dir: -1 | 1) => void;
|
|
4374
|
+
};
|
|
4375
|
+
|
|
4376
|
+
export declare function useOutsideClick(refs: ReadonlyArray<{
|
|
4377
|
+
readonly current: Element | null;
|
|
4378
|
+
}>, callback: () => void, enabled?: boolean): void;
|
|
4379
|
+
|
|
4380
|
+
export declare function usePositioning(anchorRef: {
|
|
4381
|
+
readonly current: Element | null;
|
|
4382
|
+
}, popupRef: {
|
|
4383
|
+
readonly current: HTMLElement | null;
|
|
4384
|
+
}, isOpen: boolean): void;
|
|
4385
|
+
|
|
4386
|
+
export declare function useRichEditor(options: UseRichEditorOptions): Editor;
|
|
4387
|
+
|
|
4388
|
+
export declare interface UseRichEditorOptions {
|
|
4389
|
+
defaultValue?: string;
|
|
4390
|
+
placeholder?: string;
|
|
4391
|
+
readOnly?: boolean;
|
|
4392
|
+
autoFocus?: boolean;
|
|
4393
|
+
onChange?: (value: {
|
|
4394
|
+
html: string;
|
|
4395
|
+
markdown: string;
|
|
4396
|
+
json: object;
|
|
4397
|
+
text: string;
|
|
4398
|
+
}) => void;
|
|
4399
|
+
}
|
|
4400
|
+
|
|
4401
|
+
export declare function useScrollColumn(containerRef: React.RefObject<HTMLDivElement | null>, count: number, onSelectIndex: (idx: number) => void): {
|
|
4402
|
+
scrollToIndex: (index: number, behavior?: "smooth" | "instant" | "auto") => void;
|
|
4403
|
+
handleScroll: () => void;
|
|
4404
|
+
isScrollingRef: RefObject<boolean>;
|
|
4405
|
+
};
|
|
4406
|
+
|
|
3614
4407
|
/**
|
|
3615
4408
|
* Returns a `setSpin(target, tip?)` function.
|
|
3616
4409
|
* Each call returns a **close** function to dismiss that specific overlay.
|
|
@@ -3620,6 +4413,35 @@ export { useSpin }
|
|
|
3620
4413
|
export { useSpin as useSpin_alias_1 }
|
|
3621
4414
|
export { useSpin as useSpin_alias_2 }
|
|
3622
4415
|
|
|
4416
|
+
export declare function useSplitPanel({ panes, direction, containerRef, visibility, autoSaveId, onResizeEnd, }: UseSplitPanelOptions): UseSplitPanelReturn;
|
|
4417
|
+
|
|
4418
|
+
export declare interface UseSplitPanelOptions {
|
|
4419
|
+
panes: SplitPanelPane[];
|
|
4420
|
+
direction: "horizontal" | "vertical";
|
|
4421
|
+
containerRef: RefObject<HTMLDivElement | null>;
|
|
4422
|
+
visibility: Record<string, boolean>;
|
|
4423
|
+
autoSaveId?: string;
|
|
4424
|
+
onResizeEnd?: (sizes: Record<string, number>) => void;
|
|
4425
|
+
}
|
|
4426
|
+
|
|
4427
|
+
export declare interface UseSplitPanelReturn {
|
|
4428
|
+
/** Current px sizes for every pane, keyed by id. */
|
|
4429
|
+
sizes: Record<string, number>;
|
|
4430
|
+
/** Index of the handle currently being dragged, or null. */
|
|
4431
|
+
activeHandleIndex: number | null;
|
|
4432
|
+
/**
|
|
4433
|
+
* Build pointer-event handlers for interacting with a specific resize handle.
|
|
4434
|
+
* `handleIndex` is the index within the *visible* pane array —
|
|
4435
|
+
* the handle sits between visiblePanes[handleIndex] and visiblePanes[handleIndex + 1].
|
|
4436
|
+
*/
|
|
4437
|
+
buildHandlers: (handleIndex: number, paneA: SplitPanelPane, paneB: SplitPanelPane) => {
|
|
4438
|
+
onPointerDown: (e: React.PointerEvent<HTMLDivElement>) => void;
|
|
4439
|
+
onPointerMove: (e: React.PointerEvent<HTMLDivElement>) => void;
|
|
4440
|
+
onPointerUp: (e: React.PointerEvent<HTMLDivElement>) => void;
|
|
4441
|
+
onKeyDown: (e: React.KeyboardEvent<HTMLDivElement>) => void;
|
|
4442
|
+
};
|
|
4443
|
+
}
|
|
4444
|
+
|
|
3623
4445
|
/**
|
|
3624
4446
|
* useToast — hook for triggering toasts from anywhere inside a <ToastProvider>.
|
|
3625
4447
|
* Throws if called outside of a ToastProvider.
|
|
@@ -3641,6 +4463,18 @@ export declare function useToastManager(defaultPosition: ToastPosition, defaultD
|
|
|
3641
4463
|
dismissAll: () => void;
|
|
3642
4464
|
};
|
|
3643
4465
|
|
|
4466
|
+
export declare function useVirtualList<T>(props: VirtualListProps<T>, handleRef: Ref<VirtualListHandle>): UseVirtualListReturn;
|
|
4467
|
+
|
|
4468
|
+
export declare interface UseVirtualListReturn {
|
|
4469
|
+
scrollerRef: React.RefObject<HTMLDivElement | null>;
|
|
4470
|
+
startIndex: number;
|
|
4471
|
+
endIndex: number;
|
|
4472
|
+
totalSize: number;
|
|
4473
|
+
getItemOffset: (index: number) => number;
|
|
4474
|
+
getItemSize: (index: number) => number;
|
|
4475
|
+
measureItem: (index: number, el: Element | null) => void;
|
|
4476
|
+
}
|
|
4477
|
+
|
|
3644
4478
|
/** Callback type for FormItem's `onValidate` prop. */
|
|
3645
4479
|
declare type ValidateCallback = (value: unknown) => ValidationResult;
|
|
3646
4480
|
export { ValidateCallback }
|
|
@@ -3656,4 +4490,157 @@ export { ValidationResult }
|
|
|
3656
4490
|
export { ValidationResult as ValidationResult_alias_1 }
|
|
3657
4491
|
export { ValidationResult as ValidationResult_alias_2 }
|
|
3658
4492
|
|
|
4493
|
+
/**
|
|
4494
|
+
* `VirtualList` renders only the visible slice of a (potentially enormous) dataset,
|
|
4495
|
+
* keeping DOM node count constant regardless of `items.length`.
|
|
4496
|
+
*
|
|
4497
|
+
* Supports **fixed-height** rows (O(1) offset lookup), **variable-height** rows
|
|
4498
|
+
* (auto-measured via `ResizeObserver`), **horizontal** axis, **infinite scroll**,
|
|
4499
|
+
* **scroll-to-index**, and **scroll restoration** out of the box.
|
|
4500
|
+
*
|
|
4501
|
+
* Drop it into any container — `Panel`, `SplitPanel`, `Card`, a bare `div` — and it
|
|
4502
|
+
* fills the available space.
|
|
4503
|
+
*
|
|
4504
|
+
* @example
|
|
4505
|
+
* ```tsx
|
|
4506
|
+
* <VirtualList
|
|
4507
|
+
* items={myData}
|
|
4508
|
+
* itemHeight={48}
|
|
4509
|
+
* height={400}
|
|
4510
|
+
* renderItem={(item, i) => <Row key={i} item={item} />}
|
|
4511
|
+
* />
|
|
4512
|
+
* ```
|
|
4513
|
+
*/
|
|
4514
|
+
declare const VirtualList: <T>(props: VirtualListProps<T> & React_2.RefAttributes<VirtualListHandle>) => React_2.ReactElement;
|
|
4515
|
+
export { VirtualList }
|
|
4516
|
+
export { VirtualList as VirtualList_alias_1 }
|
|
4517
|
+
export { VirtualList as VirtualList_alias_2 }
|
|
4518
|
+
export { VirtualList as VirtualList_alias_3 }
|
|
4519
|
+
|
|
4520
|
+
/**
|
|
4521
|
+
* Alignment hint for `scrollToIndex`.
|
|
4522
|
+
* - `"start"` — item top/left aligns with viewport start
|
|
4523
|
+
* - `"end"` — item bottom/right aligns with viewport end
|
|
4524
|
+
* - `"center"` — item is centered in the viewport
|
|
4525
|
+
* - `"auto"` — minimal scroll to bring the item into view (default)
|
|
4526
|
+
*/
|
|
4527
|
+
declare type VirtualListAlign = "start" | "center" | "end" | "auto";
|
|
4528
|
+
export { VirtualListAlign }
|
|
4529
|
+
export { VirtualListAlign as VirtualListAlign_alias_1 }
|
|
4530
|
+
export { VirtualListAlign as VirtualListAlign_alias_2 }
|
|
4531
|
+
export { VirtualListAlign as VirtualListAlign_alias_3 }
|
|
4532
|
+
|
|
4533
|
+
/** Scroll axis for the virtual list. */
|
|
4534
|
+
declare type VirtualListDirection = "vertical" | "horizontal";
|
|
4535
|
+
export { VirtualListDirection }
|
|
4536
|
+
export { VirtualListDirection as VirtualListDirection_alias_1 }
|
|
4537
|
+
export { VirtualListDirection as VirtualListDirection_alias_2 }
|
|
4538
|
+
export { VirtualListDirection as VirtualListDirection_alias_3 }
|
|
4539
|
+
|
|
4540
|
+
/** Imperative handle exposed via `ref` on `<VirtualList>`. */
|
|
4541
|
+
declare interface VirtualListHandle {
|
|
4542
|
+
/** Scroll to bring item at `index` into view at the specified alignment. */
|
|
4543
|
+
scrollToIndex: (index: number, align?: VirtualListAlign) => void;
|
|
4544
|
+
/** Jump to an exact pixel offset (smooth by default). */
|
|
4545
|
+
scrollToOffset: (offset: number) => void;
|
|
4546
|
+
/** Returns the current scroll offset in pixels. */
|
|
4547
|
+
getScrollOffset: () => number;
|
|
4548
|
+
}
|
|
4549
|
+
export { VirtualListHandle }
|
|
4550
|
+
export { VirtualListHandle as VirtualListHandle_alias_1 }
|
|
4551
|
+
export { VirtualListHandle as VirtualListHandle_alias_2 }
|
|
4552
|
+
export { VirtualListHandle as VirtualListHandle_alias_3 }
|
|
4553
|
+
|
|
4554
|
+
declare interface VirtualListProps<T = unknown> {
|
|
4555
|
+
/** Dataset to virtualise. Change the reference to swap/extend data. */
|
|
4556
|
+
items: T[];
|
|
4557
|
+
/**
|
|
4558
|
+
* Returns a stable key for an item. Defaults to the item's array index.
|
|
4559
|
+
* Provide this whenever items can be reordered or inserted at arbitrary positions.
|
|
4560
|
+
*/
|
|
4561
|
+
getItemKey?: (item: T, index: number) => string | number;
|
|
4562
|
+
/**
|
|
4563
|
+
* Render callback for each visible item.
|
|
4564
|
+
* The component wraps every item in an absolutely-positioned container, so
|
|
4565
|
+
* your element can fill 100 % of its wrapper without extra layout work.
|
|
4566
|
+
*/
|
|
4567
|
+
renderItem: (item: T, index: number) => ReactNode;
|
|
4568
|
+
/**
|
|
4569
|
+
* Height (vertical) or width (horizontal) of each item in pixels.
|
|
4570
|
+
*
|
|
4571
|
+
* - **number** — fixed uniform size; fastest render path (O(1) offset lookup).
|
|
4572
|
+
* - **function** — variable per-item size; items are measured via
|
|
4573
|
+
* `ResizeObserver` after first render and the layout is corrected automatically.
|
|
4574
|
+
*/
|
|
4575
|
+
itemHeight: number | ((item: T, index: number) => number);
|
|
4576
|
+
/**
|
|
4577
|
+
* Estimated size used as a placeholder before a variable-height item is
|
|
4578
|
+
* measured. Only relevant when `itemHeight` is a function.
|
|
4579
|
+
* A good estimate reduces layout shift on first render.
|
|
4580
|
+
* @default 48
|
|
4581
|
+
*/
|
|
4582
|
+
estimatedItemHeight?: number;
|
|
4583
|
+
/** Viewport height (CSS value). Set to `"100%"` to fill a parent container. @default "100%" */
|
|
4584
|
+
height?: number | string;
|
|
4585
|
+
/** Viewport width (CSS value). @default "100%" */
|
|
4586
|
+
width?: number | string;
|
|
4587
|
+
direction?: VirtualListDirection;
|
|
4588
|
+
/**
|
|
4589
|
+
* Extra rows rendered outside the visible viewport on each side to reduce
|
|
4590
|
+
* white-flash during fast scroll. Higher values trade CPU/memory for smoothness.
|
|
4591
|
+
* @default 3
|
|
4592
|
+
*/
|
|
4593
|
+
overscan?: number;
|
|
4594
|
+
/** Fired when the user scrolls within `reachEndThreshold` px of the end. */
|
|
4595
|
+
onReachEnd?: () => void;
|
|
4596
|
+
/**
|
|
4597
|
+
* Pixel distance from the scroll end that triggers `onReachEnd`.
|
|
4598
|
+
* @default 120
|
|
4599
|
+
*/
|
|
4600
|
+
reachEndThreshold?: number;
|
|
4601
|
+
/** When `true` a loading indicator is shown at the bottom/right. */
|
|
4602
|
+
isLoading?: boolean;
|
|
4603
|
+
/** Custom loading indicator. Overrides the default spinner row entirely. */
|
|
4604
|
+
loadingRenderer?: () => ReactNode;
|
|
4605
|
+
/**
|
|
4606
|
+
* Text shown in the **default** loading indicator (when `loadingRenderer` is not provided).
|
|
4607
|
+
* @default "Loading…"
|
|
4608
|
+
*/
|
|
4609
|
+
loadingText?: string;
|
|
4610
|
+
/** Rendered when `items` is empty. Overrides the default empty state entirely. */
|
|
4611
|
+
emptyRenderer?: () => ReactNode;
|
|
4612
|
+
/**
|
|
4613
|
+
* Text shown in the **default** empty-state indicator (when `emptyRenderer` is not provided).
|
|
4614
|
+
* @default "No items"
|
|
4615
|
+
*/
|
|
4616
|
+
emptyText?: string;
|
|
4617
|
+
/**
|
|
4618
|
+
* When provided the scroll position is persisted to `localStorage` under
|
|
4619
|
+
* the key `"onyx-vlist:<scrollRestorationId>"` and restored on mount.
|
|
4620
|
+
*/
|
|
4621
|
+
scrollRestorationId?: string;
|
|
4622
|
+
/** Called on every scroll event with the current pixel offset. */
|
|
4623
|
+
onScroll?: (offset: number) => void;
|
|
4624
|
+
/**
|
|
4625
|
+
* Called whenever the set of *visually* visible items changes.
|
|
4626
|
+
* Indices exclude the overscan buffer.
|
|
4627
|
+
*/
|
|
4628
|
+
onVisibleRangeChange?: (startIndex: number, endIndex: number) => void;
|
|
4629
|
+
className?: string;
|
|
4630
|
+
style?: CSSProperties;
|
|
4631
|
+
/**
|
|
4632
|
+
* Class name applied to every item's wrapper `<div>`. Use this to add
|
|
4633
|
+
* borders, hover states, or selection highlights without modifying each
|
|
4634
|
+
* rendered item.
|
|
4635
|
+
*/
|
|
4636
|
+
itemClassName?: string;
|
|
4637
|
+
}
|
|
4638
|
+
export { VirtualListProps }
|
|
4639
|
+
export { VirtualListProps as VirtualListProps_alias_1 }
|
|
4640
|
+
export { VirtualListProps as VirtualListProps_alias_2 }
|
|
4641
|
+
export { VirtualListProps as VirtualListProps_alias_3 }
|
|
4642
|
+
|
|
4643
|
+
/** Return ids of panes that are currently visible. */
|
|
4644
|
+
export declare function visibleIds(panes: SplitPanelPane[], visibility: Record<string, boolean>): string[];
|
|
4645
|
+
|
|
3659
4646
|
export { }
|