@worldresources/wri-design-systems 2.194.2 → 2.194.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs.js +527 -527
- package/dist/index.d.ts +29 -5
- package/dist/index.esm.js +745 -745
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -441,9 +441,16 @@ type RichTextEditorLabels = {
|
|
|
441
441
|
/** Tooltip / aria labels for controls. */
|
|
442
442
|
undoTooltip: string;
|
|
443
443
|
redoTooltip: string;
|
|
444
|
-
|
|
444
|
+
textTypeTooltip: string;
|
|
445
445
|
fontSizeTooltip: string;
|
|
446
|
+
alignmentTooltip: string;
|
|
447
|
+
alignLeftOptionLabel: string;
|
|
448
|
+
alignCenterOptionLabel: string;
|
|
449
|
+
alignRightOptionLabel: string;
|
|
450
|
+
alignJustifyOptionLabel: string;
|
|
446
451
|
boldTooltip: string;
|
|
452
|
+
/** Short text rendered inside the bold control icon button (for example: B, N). */
|
|
453
|
+
boldIconText: string;
|
|
447
454
|
italicTooltip: string;
|
|
448
455
|
underlineTooltip: string;
|
|
449
456
|
strikethroughTooltip: string;
|
|
@@ -451,6 +458,18 @@ type RichTextEditorLabels = {
|
|
|
451
458
|
orderedListTooltip: string;
|
|
452
459
|
linkTooltip: string;
|
|
453
460
|
imageTooltip: string;
|
|
461
|
+
/** Placeholder text for link URL input in the link popover. */
|
|
462
|
+
linkUrlPlaceholder: string;
|
|
463
|
+
/** Placeholder text for link label input in the link popover. */
|
|
464
|
+
linkLabelPlaceholder: string;
|
|
465
|
+
/** Aria-label for link label input in the link popover. */
|
|
466
|
+
linkLabelAriaLabel: string;
|
|
467
|
+
/** Label for apply action in link popover. */
|
|
468
|
+
linkApplyLabel: string;
|
|
469
|
+
/** Label for remove action in link popover. */
|
|
470
|
+
linkRemoveLabel: string;
|
|
471
|
+
/** Validation message when URL is invalid in link popover. */
|
|
472
|
+
linkInvalidUrlMessage: string;
|
|
454
473
|
};
|
|
455
474
|
/**
|
|
456
475
|
* Top-level labels map for the design system.
|
|
@@ -515,7 +534,7 @@ type IconButtonProps = Omit<ButtonProps$1, 'size' | 'variant' | 'colorPalette' |
|
|
|
515
534
|
disabled?: boolean;
|
|
516
535
|
};
|
|
517
536
|
|
|
518
|
-
type RichTextEditorControlKey = 'undo' | 'redo' | '
|
|
537
|
+
type RichTextEditorControlKey = 'undo' | 'redo' | 'textType' | 'fontSize' | 'alignment' | 'bold' | 'italic' | 'underline' | 'strikethrough' | 'bulletList' | 'orderedList' | 'link' | 'image';
|
|
519
538
|
type RichTextEditorSize = string;
|
|
520
539
|
type RichTextEditorProps = {
|
|
521
540
|
defaultValue?: string;
|
|
@@ -652,6 +671,8 @@ type MenuItemProps = {
|
|
|
652
671
|
type MenuProps = {
|
|
653
672
|
theme?: 'light' | 'dark';
|
|
654
673
|
label: string;
|
|
674
|
+
/** Hides the decorative arrow on the menu content. Default: false. */
|
|
675
|
+
hideArrow?: boolean;
|
|
655
676
|
fontSize?: string;
|
|
656
677
|
items?: MenuItemProps[];
|
|
657
678
|
groups?: {
|
|
@@ -666,7 +687,7 @@ type MenuProps = {
|
|
|
666
687
|
defaultSelectedValues?: string[];
|
|
667
688
|
};
|
|
668
689
|
|
|
669
|
-
declare const Menu: ({ theme, label, fontSize, items, groups, onSelect, customTrigger, selectionMode, defaultSelectedValues, }: MenuProps) => _emotion_react_jsx_runtime.JSX.Element;
|
|
690
|
+
declare const Menu: ({ theme, label, hideArrow, fontSize, items, groups, onSelect, customTrigger, selectionMode, defaultSelectedValues, }: MenuProps) => _emotion_react_jsx_runtime.JSX.Element;
|
|
670
691
|
|
|
671
692
|
type MultiActionButtonProps = Omit<ButtonProps$1, 'size' | 'variant' | 'colorPalette' | 'children'> & {
|
|
672
693
|
variant?: 'primary' | 'secondary';
|
|
@@ -1229,6 +1250,8 @@ type TableColumn = {
|
|
|
1229
1250
|
label: string;
|
|
1230
1251
|
sortable?: boolean;
|
|
1231
1252
|
width?: string;
|
|
1253
|
+
/** Optional custom renderer for this column cell. */
|
|
1254
|
+
cell?: (row: any) => ReactNode;
|
|
1232
1255
|
/** When true, this column sticks to the left during horizontal scroll. */
|
|
1233
1256
|
sticky?: boolean;
|
|
1234
1257
|
};
|
|
@@ -1239,7 +1262,7 @@ type TableRenderRowContext = {
|
|
|
1239
1262
|
type TableProps = {
|
|
1240
1263
|
columns: TableColumn[];
|
|
1241
1264
|
data?: any;
|
|
1242
|
-
renderRow
|
|
1265
|
+
renderRow?: (row: any, context?: TableRenderRowContext) => ReactNode;
|
|
1243
1266
|
striped?: boolean;
|
|
1244
1267
|
stickyHeader?: boolean;
|
|
1245
1268
|
selectable?: boolean;
|
|
@@ -1259,6 +1282,7 @@ type TableProps = {
|
|
|
1259
1282
|
onPageSizeChange?: (pageSize: number) => void;
|
|
1260
1283
|
onPageChange?: (page: number) => void;
|
|
1261
1284
|
onAllItemsSelected?: (checked: boolean) => void;
|
|
1285
|
+
onRowSelected?: (row: any, checked: boolean) => void;
|
|
1262
1286
|
loading?: boolean;
|
|
1263
1287
|
/** When set, the table scrolls vertically within this height and horizontally when it overflows its container (e.g. '400px', '60vh'). */
|
|
1264
1288
|
height?: string;
|
|
@@ -1266,7 +1290,7 @@ type TableProps = {
|
|
|
1266
1290
|
labels?: Partial<TableLabels>;
|
|
1267
1291
|
};
|
|
1268
1292
|
|
|
1269
|
-
declare const Table: ({ columns, data, renderRow, striped, stickyHeader, pagination, selectable, selectedRows, variant, onSortColumn, onPageSizeChange, onPageChange, onAllItemsSelected, loading, height, labels, }: TableProps) => _emotion_react_jsx_runtime.JSX.Element;
|
|
1293
|
+
declare const Table: ({ columns, data, renderRow, striped, stickyHeader, pagination, selectable, selectedRows, variant, onSortColumn, onPageSizeChange, onPageChange, onAllItemsSelected, onRowSelected, loading, height, labels, }: TableProps) => _emotion_react_jsx_runtime.JSX.Element;
|
|
1270
1294
|
|
|
1271
1295
|
declare const TableRow: React__default.ForwardRefExoticComponent<Table$1.RowProps & React__default.RefAttributes<HTMLTableRowElement>>;
|
|
1272
1296
|
declare const TableCell: React__default.ForwardRefExoticComponent<Table$1.CellProps & React__default.RefAttributes<HTMLTableCellElement>>;
|