@elastic/eui 72.0.0 → 72.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/eui_charts_theme.js +13 -1
- package/dist/eui_charts_theme.js.map +1 -1
- package/dist/eui_theme_dark.css +0 -151
- package/dist/eui_theme_dark.min.css +1 -1
- package/dist/eui_theme_light.css +0 -151
- package/dist/eui_theme_light.min.css +1 -1
- package/es/components/accordion/accordion.js +1 -1
- package/es/components/basic_table/basic_table.js +2 -2
- package/es/components/basic_table/in_memory_table.js +3 -6
- package/es/components/basic_table/table.a11y.js +128 -0
- package/es/components/color_picker/color_picker.styles.js +16 -0
- package/es/components/color_picker/color_stops/color_stop_thumb.js +19 -7
- package/es/components/color_picker/color_stops/color_stop_thumb.styles.js +59 -0
- package/es/components/color_picker/color_stops/color_stops.js +25 -15
- package/es/components/color_picker/color_stops/color_stops.styles.js +65 -0
- package/es/components/date_picker/super_date_picker/super_date_picker.js +9 -0
- package/es/components/date_picker/super_date_picker/super_update_button.js +8 -0
- package/es/components/form/range/range_highlight.styles.js +1 -1
- package/es/components/form/range/range_levels.styles.js +1 -1
- package/es/components/form/range/range_track.js +5 -2
- package/es/components/image/image.a11y.js +55 -0
- package/es/components/image/image.js +9 -2
- package/es/components/image/image_fullscreen_wrapper.js +3 -1
- package/es/components/image/image_wrapper.js +3 -1
- package/es/components/key_pad_menu/key_pad_menu.a11y.js +158 -0
- package/es/components/markdown_editor/markdown_format.styles.js +2 -5
- package/es/components/popover/popover.js +2 -2
- package/es/components/table/table_footer_cell.js +1 -1
- package/es/components/table/table_header_cell.js +1 -1
- package/es/components/table/table_row_cell.js +2 -2
- package/es/components/text/text.styles.js +6 -3
- package/es/components/tool_tip/icon_tip.js +8 -0
- package/es/components/tool_tip/tool_tip.js +24 -1
- package/es/components/tour/tour.styles.js +1 -1
- package/es/services/color/manipulation.js +9 -0
- package/es/services/index.js +11 -11
- package/eui.d.ts +166 -107
- package/i18ntokens.json +16 -16
- package/lib/components/accordion/accordion.js +1 -1
- package/lib/components/basic_table/basic_table.js +2 -2
- package/lib/components/basic_table/in_memory_table.js +3 -6
- package/lib/components/basic_table/table.a11y.js +139 -0
- package/lib/components/color_picker/color_picker.styles.js +26 -0
- package/lib/components/color_picker/color_stops/color_stop_thumb.js +19 -6
- package/lib/components/color_picker/color_stops/color_stop_thumb.styles.js +69 -0
- package/lib/components/color_picker/color_stops/color_stops.js +25 -14
- package/lib/components/color_picker/color_stops/color_stops.styles.js +73 -0
- package/lib/components/date_picker/super_date_picker/super_date_picker.js +9 -0
- package/lib/components/date_picker/super_date_picker/super_update_button.js +8 -0
- package/lib/components/form/range/range_highlight.styles.js +1 -1
- package/lib/components/form/range/range_levels.styles.js +1 -1
- package/lib/components/form/range/range_track.js +6 -2
- package/lib/components/image/image.a11y.js +61 -0
- package/lib/components/image/image.js +9 -2
- package/lib/components/image/image_fullscreen_wrapper.js +3 -1
- package/lib/components/image/image_wrapper.js +3 -1
- package/lib/components/key_pad_menu/key_pad_menu.a11y.js +163 -0
- package/lib/components/markdown_editor/markdown_format.styles.js +1 -4
- package/lib/components/popover/popover.js +2 -2
- package/lib/components/table/table_footer_cell.js +1 -1
- package/lib/components/table/table_header_cell.js +1 -1
- package/lib/components/table/table_row_cell.js +2 -2
- package/lib/components/text/text.styles.js +5 -2
- package/lib/components/tool_tip/icon_tip.js +8 -0
- package/lib/components/tool_tip/tool_tip.js +24 -1
- package/lib/components/tour/tour.styles.js +1 -1
- package/lib/services/color/manipulation.js +14 -2
- package/lib/services/index.js +65 -58
- package/optimize/es/components/accordion/accordion.js +1 -1
- package/optimize/es/components/basic_table/table.a11y.js +128 -0
- package/optimize/es/components/color_picker/color_picker.styles.js +16 -0
- package/optimize/es/components/color_picker/color_stops/color_stop_thumb.js +19 -7
- package/optimize/es/components/color_picker/color_stops/color_stop_thumb.styles.js +59 -0
- package/optimize/es/components/color_picker/color_stops/color_stops.js +25 -15
- package/optimize/es/components/color_picker/color_stops/color_stops.styles.js +65 -0
- package/optimize/es/components/form/range/range_highlight.styles.js +1 -1
- package/optimize/es/components/form/range/range_levels.styles.js +1 -1
- package/optimize/es/components/form/range/range_track.js +5 -2
- package/optimize/es/components/image/image.a11y.js +55 -0
- package/optimize/es/components/image/image.js +4 -2
- package/optimize/es/components/image/image_fullscreen_wrapper.js +3 -1
- package/optimize/es/components/image/image_wrapper.js +3 -1
- package/optimize/es/components/key_pad_menu/key_pad_menu.a11y.js +148 -0
- package/optimize/es/components/markdown_editor/markdown_format.styles.js +2 -5
- package/optimize/es/components/popover/popover.js +2 -2
- package/optimize/es/components/text/text.styles.js +6 -3
- package/optimize/es/components/tool_tip/tool_tip.js +16 -1
- package/optimize/es/components/tour/tour.styles.js +1 -1
- package/optimize/es/services/color/manipulation.js +9 -0
- package/optimize/es/services/index.js +11 -11
- package/optimize/lib/components/accordion/accordion.js +1 -1
- package/optimize/lib/components/basic_table/table.a11y.js +139 -0
- package/optimize/lib/components/color_picker/color_picker.styles.js +26 -0
- package/optimize/lib/components/color_picker/color_stops/color_stop_thumb.js +19 -6
- package/optimize/lib/components/color_picker/color_stops/color_stop_thumb.styles.js +69 -0
- package/optimize/lib/components/color_picker/color_stops/color_stops.js +25 -14
- package/optimize/lib/components/color_picker/color_stops/color_stops.styles.js +73 -0
- package/optimize/lib/components/form/range/range_highlight.styles.js +1 -1
- package/optimize/lib/components/form/range/range_levels.styles.js +1 -1
- package/optimize/lib/components/form/range/range_track.js +6 -2
- package/optimize/lib/components/image/image.a11y.js +61 -0
- package/optimize/lib/components/image/image.js +4 -2
- package/optimize/lib/components/image/image_fullscreen_wrapper.js +3 -1
- package/optimize/lib/components/image/image_wrapper.js +3 -1
- package/optimize/lib/components/key_pad_menu/key_pad_menu.a11y.js +163 -0
- package/optimize/lib/components/markdown_editor/markdown_format.styles.js +1 -4
- package/optimize/lib/components/popover/popover.js +2 -2
- package/optimize/lib/components/text/text.styles.js +5 -2
- package/optimize/lib/components/tool_tip/tool_tip.js +16 -1
- package/optimize/lib/components/tour/tour.styles.js +1 -1
- package/optimize/lib/services/color/manipulation.js +14 -2
- package/optimize/lib/services/index.js +65 -58
- package/package.json +2 -2
- package/src/components/color_picker/_index.scss +0 -1
- package/src/components/markdown_editor/_markdown_format.scss +0 -4
- package/src/themes/amsterdam/overrides/_index.scss +0 -1
- package/test-env/components/accordion/accordion.js +1 -1
- package/test-env/components/basic_table/basic_table.js +2 -2
- package/test-env/components/basic_table/in_memory_table.js +3 -6
- package/test-env/components/basic_table/table.a11y.js +139 -0
- package/test-env/components/color_picker/color_picker.styles.js +26 -0
- package/test-env/components/color_picker/color_stops/color_stop_thumb.js +19 -6
- package/test-env/components/color_picker/color_stops/color_stop_thumb.styles.js +69 -0
- package/test-env/components/color_picker/color_stops/color_stops.js +25 -14
- package/test-env/components/color_picker/color_stops/color_stops.styles.js +73 -0
- package/test-env/components/date_picker/super_date_picker/super_date_picker.js +9 -0
- package/test-env/components/date_picker/super_date_picker/super_update_button.js +8 -0
- package/test-env/components/form/range/range_highlight.styles.js +1 -1
- package/test-env/components/form/range/range_levels.styles.js +1 -1
- package/test-env/components/form/range/range_track.js +6 -2
- package/test-env/components/image/image.a11y.js +61 -0
- package/test-env/components/image/image.js +9 -2
- package/test-env/components/image/image_fullscreen_wrapper.js +3 -1
- package/test-env/components/image/image_wrapper.js +3 -1
- package/test-env/components/key_pad_menu/key_pad_menu.a11y.js +163 -0
- package/test-env/components/markdown_editor/markdown_format.styles.js +1 -4
- package/test-env/components/popover/popover.js +2 -2
- package/test-env/components/table/table_footer_cell.js +1 -1
- package/test-env/components/table/table_header_cell.js +1 -1
- package/test-env/components/table/table_row_cell.js +2 -2
- package/test-env/components/text/text.styles.js +5 -2
- package/test-env/components/tool_tip/icon_tip.js +8 -0
- package/test-env/components/tool_tip/tool_tip.js +24 -1
- package/test-env/components/tour/tour.styles.js +1 -1
- package/test-env/services/color/manipulation.js +14 -2
- package/test-env/services/index.js +65 -58
- package/src/components/color_picker/color_stops/_color_stops.scss +0 -101
- package/src/components/color_picker/color_stops/_index.scss +0 -1
- package/src/themes/amsterdam/overrides/_color_stops.scss +0 -58
package/eui.d.ts
CHANGED
|
@@ -4587,7 +4587,7 @@ declare module '@elastic/eui/src/components/popover/popover' {
|
|
|
4587
4587
|
/**
|
|
4588
4588
|
* Object of props passed to EuiFocusTrap
|
|
4589
4589
|
*/
|
|
4590
|
-
focusTrapProps?: Pick<EuiFocusTrapProps, 'clickOutsideDisables' | 'noIsolation' | 'scrollLock' | 'shards'>;
|
|
4590
|
+
focusTrapProps?: Pick<EuiFocusTrapProps, 'clickOutsideDisables' | 'onClickOutside' | 'noIsolation' | 'scrollLock' | 'shards'>;
|
|
4591
4591
|
/**
|
|
4592
4592
|
* Show arrow indicating to originating button
|
|
4593
4593
|
*/
|
|
@@ -5753,6 +5753,13 @@ declare module '@elastic/eui/src/components/tool_tip/tool_tip' {
|
|
|
5753
5753
|
* Suggested position. If there is not enough room for it this will be changed.
|
|
5754
5754
|
*/
|
|
5755
5755
|
position: ToolTipPositions;
|
|
5756
|
+
/**
|
|
5757
|
+
* When `true`, the tooltip's position is re-calculated when the user
|
|
5758
|
+
* scrolls. This supports having fixed-position tooltip anchors.
|
|
5759
|
+
*
|
|
5760
|
+
* When nesting an `EuiTooltip` in a scrollable container, `repositionOnScroll` should be `true`
|
|
5761
|
+
*/
|
|
5762
|
+
repositionOnScroll?: boolean;
|
|
5756
5763
|
/**
|
|
5757
5764
|
* If supplied, called when mouse movement causes the tool tip to be
|
|
5758
5765
|
* hidden.
|
|
@@ -6433,6 +6440,29 @@ declare module '@elastic/eui/src/components/color_picker/color_picker' {
|
|
|
6433
6440
|
export const EuiColorPicker: FunctionComponent<EuiColorPickerProps>;
|
|
6434
6441
|
export {};
|
|
6435
6442
|
|
|
6443
|
+
}
|
|
6444
|
+
declare module '@elastic/eui/src/components/color_picker/color_picker.styles' {
|
|
6445
|
+
import { UseEuiTheme } from '@elastic/eui/src/services';
|
|
6446
|
+
export const euiColorPickerVariables: (euiThemeContext: UseEuiTheme) => {
|
|
6447
|
+
width: string;
|
|
6448
|
+
};
|
|
6449
|
+
|
|
6450
|
+
}
|
|
6451
|
+
declare module '@elastic/eui/src/components/color_picker/color_stops/color_stop_thumb.styles' {
|
|
6452
|
+
import { UseEuiTheme } from '@elastic/eui/src/services';
|
|
6453
|
+
export const euiColorStopThumbStyles: (euiThemeContext: UseEuiTheme) => {
|
|
6454
|
+
euiColorStopThumb: import("@emotion/utils").SerializedStyles;
|
|
6455
|
+
isPopoverOpen: import("@emotion/utils").SerializedStyles;
|
|
6456
|
+
};
|
|
6457
|
+
export const euiColorStopThumbPopoverStyles: (euiThemeContext: UseEuiTheme) => {
|
|
6458
|
+
euiColorStopThumbPopover: import("@emotion/utils").SerializedStyles;
|
|
6459
|
+
isLoadingPanel: import("@emotion/utils").SerializedStyles;
|
|
6460
|
+
hasFocus: import("@emotion/utils").SerializedStyles;
|
|
6461
|
+
};
|
|
6462
|
+
export const euiColorStopStyles: (euiThemeContext: UseEuiTheme) => {
|
|
6463
|
+
euiColorStop: import("@emotion/utils").SerializedStyles;
|
|
6464
|
+
};
|
|
6465
|
+
|
|
6436
6466
|
}
|
|
6437
6467
|
declare module '@elastic/eui/src/components/color_picker/color_stops/color_stop_thumb' {
|
|
6438
6468
|
import { FunctionComponent, CSSProperties } from 'react';
|
|
@@ -6473,6 +6503,25 @@ declare module '@elastic/eui/src/components/color_picker/color_stops/color_stop_
|
|
|
6473
6503
|
export const EuiColorStopThumb: FunctionComponent<EuiColorStopThumbProps>;
|
|
6474
6504
|
export {};
|
|
6475
6505
|
|
|
6506
|
+
}
|
|
6507
|
+
declare module '@elastic/eui/src/components/color_picker/color_stops/color_stops.styles' {
|
|
6508
|
+
import { UseEuiTheme } from '@elastic/eui/src/services';
|
|
6509
|
+
export const euiColorStopsStyles: (euiThemeContext: UseEuiTheme) => {
|
|
6510
|
+
euiColorStops: import("@emotion/utils").SerializedStyles;
|
|
6511
|
+
isEnabled: import("@emotion/utils").SerializedStyles;
|
|
6512
|
+
isDisabled: import("@emotion/utils").SerializedStyles;
|
|
6513
|
+
isHoverDisabled: import("@emotion/utils").SerializedStyles;
|
|
6514
|
+
isReadOnly: import("@emotion/utils").SerializedStyles;
|
|
6515
|
+
isDragging: import("@emotion/utils").SerializedStyles;
|
|
6516
|
+
euiColorStops__track: import("@emotion/utils").SerializedStyles;
|
|
6517
|
+
euiColorStops__addTarget: import("@emotion/utils").SerializedStyles;
|
|
6518
|
+
};
|
|
6519
|
+
export const euiColorStopsAddContainerStyles: (euiThemeContext: UseEuiTheme) => {
|
|
6520
|
+
euiColorStopsAddContainer: import("@emotion/utils").SerializedStyles;
|
|
6521
|
+
isEnabled: import("@emotion/utils").SerializedStyles;
|
|
6522
|
+
isDisabled: import("@emotion/utils").SerializedStyles;
|
|
6523
|
+
};
|
|
6524
|
+
|
|
6476
6525
|
}
|
|
6477
6526
|
declare module '@elastic/eui/src/components/color_picker/color_stops/color_stops' {
|
|
6478
6527
|
import { FunctionComponent } from 'react';
|
|
@@ -6586,6 +6635,12 @@ declare module '@elastic/eui/src/services/color/manipulation' {
|
|
|
6586
6635
|
* @param amount - Amount to change in absolute terms. 0-1.
|
|
6587
6636
|
*/
|
|
6588
6637
|
export const darken: (color: string, amount: number) => string;
|
|
6638
|
+
/**
|
|
6639
|
+
* Returns the brighten value of a color. 0-100
|
|
6640
|
+
* @param color - Color to manipulate
|
|
6641
|
+
* @param amount - Amount to change in absolute terms. 0-1.
|
|
6642
|
+
*/
|
|
6643
|
+
export const brighten: (color: string, amount: number) => string;
|
|
6589
6644
|
|
|
6590
6645
|
}
|
|
6591
6646
|
declare module '@elastic/eui/src/services/color/contrast' {
|
|
@@ -7203,6 +7258,54 @@ declare module '@elastic/eui/src/services/format' {
|
|
|
7203
7258
|
export { formatNumber } from '@elastic/eui/src/services/format/format_number';
|
|
7204
7259
|
export { formatText } from '@elastic/eui/src/services/format/format_text';
|
|
7205
7260
|
|
|
7261
|
+
}
|
|
7262
|
+
declare module '@elastic/eui/src/services/hooks/useUpdateEffect' {
|
|
7263
|
+
export const useUpdateEffect: (effect: Function, deps: unknown[]) => void;
|
|
7264
|
+
|
|
7265
|
+
}
|
|
7266
|
+
declare module '@elastic/eui/src/services/hooks/useDependentState' {
|
|
7267
|
+
|
|
7268
|
+
export function useDependentState<T>(valueFn: (previousState: undefined | T) => T, deps: unknown[]): readonly [T, import("react").Dispatch<import("react").SetStateAction<T>>];
|
|
7269
|
+
|
|
7270
|
+
}
|
|
7271
|
+
declare module '@elastic/eui/src/services/hooks/useCombinedRefs' {
|
|
7272
|
+
import { MutableRefObject, Ref } from 'react';
|
|
7273
|
+
export const useCombinedRefs: <T>(refs: (Ref<T> | MutableRefObject<T | undefined> | undefined)[]) => (node: T) => void;
|
|
7274
|
+
|
|
7275
|
+
}
|
|
7276
|
+
declare module '@elastic/eui/src/services/hooks/useForceRender' {
|
|
7277
|
+
export const useForceRender: () => () => void;
|
|
7278
|
+
|
|
7279
|
+
}
|
|
7280
|
+
declare module '@elastic/eui/src/services/hooks/useLatest' {
|
|
7281
|
+
import { MutableRefObject } from 'react';
|
|
7282
|
+
/**
|
|
7283
|
+
* Wraps the given `value` into a `MutableRefObject` and keeps the `current`
|
|
7284
|
+
* value up-to-date on every render cycle.
|
|
7285
|
+
*/
|
|
7286
|
+
export function useLatest<Value>(value: Value): MutableRefObject<Value | null>;
|
|
7287
|
+
|
|
7288
|
+
}
|
|
7289
|
+
declare module '@elastic/eui/src/services/hooks/useMouseMove' {
|
|
7290
|
+
import { MouseEvent, TouchEvent } from 'react';
|
|
7291
|
+
export function isMouseEvent<T = HTMLDivElement>(event: MouseEvent<T> | TouchEvent<T>): event is MouseEvent<T>;
|
|
7292
|
+
export function useMouseMove<T = HTMLDivElement>(handleChange: (location: {
|
|
7293
|
+
x: number;
|
|
7294
|
+
y: number;
|
|
7295
|
+
}, isFirstInteraction?: boolean) => void, interactionConditional?: any): [
|
|
7296
|
+
(e: MouseEvent<T>) => void,
|
|
7297
|
+
(e: MouseEvent<T> | TouchEvent<T>, isFirstInteraction?: boolean) => void
|
|
7298
|
+
];
|
|
7299
|
+
|
|
7300
|
+
}
|
|
7301
|
+
declare module '@elastic/eui/src/services/hooks' {
|
|
7302
|
+
export * from '@elastic/eui/src/services/hooks/useDependentState';
|
|
7303
|
+
export * from '@elastic/eui/src/services/hooks/useCombinedRefs';
|
|
7304
|
+
export * from '@elastic/eui/src/services/hooks/useForceRender';
|
|
7305
|
+
export * from '@elastic/eui/src/services/hooks/useLatest';
|
|
7306
|
+
export * from '@elastic/eui/src/services/hooks/useMouseMove';
|
|
7307
|
+
export * from '@elastic/eui/src/services/hooks/useUpdateEffect';
|
|
7308
|
+
|
|
7206
7309
|
}
|
|
7207
7310
|
declare module '@elastic/eui/src/services/paging/pager' {
|
|
7208
7311
|
export class Pager {
|
|
@@ -7286,50 +7389,6 @@ declare module '@elastic/eui/src/services/security/get_secure_rel_for_target' {
|
|
|
7286
7389
|
declare module '@elastic/eui/src/services/security' {
|
|
7287
7390
|
export { getSecureRelForTarget } from '@elastic/eui/src/services/security/get_secure_rel_for_target';
|
|
7288
7391
|
|
|
7289
|
-
}
|
|
7290
|
-
declare module '@elastic/eui/src/services/string/to_initials' {
|
|
7291
|
-
/**
|
|
7292
|
-
* This function calculates the initials/acronym for a given name.
|
|
7293
|
-
* It defaults to only 2 characters and will take the first character (of each word).
|
|
7294
|
-
* If only one word is supplied for the name, it will only pass back the first letter of the word,
|
|
7295
|
-
* unless forced to 2 letters by setting `initialsLength` to `2`.
|
|
7296
|
-
* It will pass back the characters with the same casing as the original string
|
|
7297
|
-
* unless otherwise specified.
|
|
7298
|
-
*
|
|
7299
|
-
* @param {string} name The full name of the item to turn into initials
|
|
7300
|
-
* @param {number} initialsLength (Optional) How many characters to show (max 2 allowed)
|
|
7301
|
-
* @param {string} initials (Optional) Custom initials (max 2 characters)
|
|
7302
|
-
* @returns {string} True if the color is dark, false otherwise.
|
|
7303
|
-
*/
|
|
7304
|
-
export const MAX_INITIALS = 2;
|
|
7305
|
-
export function toInitials(name: string, initialsLength?: 1 | 2, initials?: string): string | null;
|
|
7306
|
-
|
|
7307
|
-
}
|
|
7308
|
-
declare module '@elastic/eui/src/services/string/to_case' {
|
|
7309
|
-
/**
|
|
7310
|
-
* This function returns the same string with the first letter of the first word capitalized.
|
|
7311
|
-
*
|
|
7312
|
-
* @param {string} string The input string
|
|
7313
|
-
*/
|
|
7314
|
-
export function toSentenceCase(string: string): string;
|
|
7315
|
-
|
|
7316
|
-
}
|
|
7317
|
-
declare module '@elastic/eui/src/services/string/slugify' {
|
|
7318
|
-
/**
|
|
7319
|
-
* Lowercases input and replaces spaces with hyphens:
|
|
7320
|
-
* e.g. 'GridView Example' -> 'gridview-example'
|
|
7321
|
-
*
|
|
7322
|
-
* @param {string} string The starting string
|
|
7323
|
-
* @returns {string} Lowercase, dashed version of the starting staring
|
|
7324
|
-
*/
|
|
7325
|
-
export function slugify(str: string): string;
|
|
7326
|
-
|
|
7327
|
-
}
|
|
7328
|
-
declare module '@elastic/eui/src/services/string' {
|
|
7329
|
-
export { toInitials } from '@elastic/eui/src/services/string/to_initials';
|
|
7330
|
-
export { toSentenceCase } from '@elastic/eui/src/services/string/to_case';
|
|
7331
|
-
export { slugify } from '@elastic/eui/src/services/string/slugify';
|
|
7332
|
-
|
|
7333
7392
|
}
|
|
7334
7393
|
declare module '@elastic/eui/src/services/sort/sort_direction' {
|
|
7335
7394
|
import PropTypes from 'prop-types'; const ASC: "asc"; const DESC: "desc";
|
|
@@ -7441,6 +7500,50 @@ declare module '@elastic/eui/src/services/sort' {
|
|
|
7441
7500
|
export { PropertySortType } from '@elastic/eui/src/services/sort/property_sort';
|
|
7442
7501
|
export { Comparators } from '@elastic/eui/src/services/sort/comparators';
|
|
7443
7502
|
|
|
7503
|
+
}
|
|
7504
|
+
declare module '@elastic/eui/src/services/string/to_initials' {
|
|
7505
|
+
/**
|
|
7506
|
+
* This function calculates the initials/acronym for a given name.
|
|
7507
|
+
* It defaults to only 2 characters and will take the first character (of each word).
|
|
7508
|
+
* If only one word is supplied for the name, it will only pass back the first letter of the word,
|
|
7509
|
+
* unless forced to 2 letters by setting `initialsLength` to `2`.
|
|
7510
|
+
* It will pass back the characters with the same casing as the original string
|
|
7511
|
+
* unless otherwise specified.
|
|
7512
|
+
*
|
|
7513
|
+
* @param {string} name The full name of the item to turn into initials
|
|
7514
|
+
* @param {number} initialsLength (Optional) How many characters to show (max 2 allowed)
|
|
7515
|
+
* @param {string} initials (Optional) Custom initials (max 2 characters)
|
|
7516
|
+
* @returns {string} True if the color is dark, false otherwise.
|
|
7517
|
+
*/
|
|
7518
|
+
export const MAX_INITIALS = 2;
|
|
7519
|
+
export function toInitials(name: string, initialsLength?: 1 | 2, initials?: string): string | null;
|
|
7520
|
+
|
|
7521
|
+
}
|
|
7522
|
+
declare module '@elastic/eui/src/services/string/to_case' {
|
|
7523
|
+
/**
|
|
7524
|
+
* This function returns the same string with the first letter of the first word capitalized.
|
|
7525
|
+
*
|
|
7526
|
+
* @param {string} string The input string
|
|
7527
|
+
*/
|
|
7528
|
+
export function toSentenceCase(string: string): string;
|
|
7529
|
+
|
|
7530
|
+
}
|
|
7531
|
+
declare module '@elastic/eui/src/services/string/slugify' {
|
|
7532
|
+
/**
|
|
7533
|
+
* Lowercases input and replaces spaces with hyphens:
|
|
7534
|
+
* e.g. 'GridView Example' -> 'gridview-example'
|
|
7535
|
+
*
|
|
7536
|
+
* @param {string} string The starting string
|
|
7537
|
+
* @returns {string} Lowercase, dashed version of the starting staring
|
|
7538
|
+
*/
|
|
7539
|
+
export function slugify(str: string): string;
|
|
7540
|
+
|
|
7541
|
+
}
|
|
7542
|
+
declare module '@elastic/eui/src/services/string' {
|
|
7543
|
+
export { toInitials } from '@elastic/eui/src/services/string/to_initials';
|
|
7544
|
+
export { toSentenceCase } from '@elastic/eui/src/services/string/to_case';
|
|
7545
|
+
export { slugify } from '@elastic/eui/src/services/string/slugify';
|
|
7546
|
+
|
|
7444
7547
|
}
|
|
7445
7548
|
declare module '@elastic/eui/src/services/transition/transition' {
|
|
7446
7549
|
export const getTransitionTimings: (element: Element) => {
|
|
@@ -7476,84 +7579,36 @@ declare module '@elastic/eui/src/services/window_event/window_event' {
|
|
|
7476
7579
|
declare module '@elastic/eui/src/services/window_event' {
|
|
7477
7580
|
export { EuiWindowEvent } from '@elastic/eui/src/services/window_event/window_event';
|
|
7478
7581
|
|
|
7479
|
-
}
|
|
7480
|
-
declare module '@elastic/eui/src/services/hooks/useUpdateEffect' {
|
|
7481
|
-
export const useUpdateEffect: (effect: Function, deps: unknown[]) => void;
|
|
7482
|
-
|
|
7483
|
-
}
|
|
7484
|
-
declare module '@elastic/eui/src/services/hooks/useDependentState' {
|
|
7485
|
-
|
|
7486
|
-
export function useDependentState<T>(valueFn: (previousState: undefined | T) => T, deps: unknown[]): readonly [T, import("react").Dispatch<import("react").SetStateAction<T>>];
|
|
7487
|
-
|
|
7488
|
-
}
|
|
7489
|
-
declare module '@elastic/eui/src/services/hooks/useCombinedRefs' {
|
|
7490
|
-
import { MutableRefObject, Ref } from 'react';
|
|
7491
|
-
export const useCombinedRefs: <T>(refs: (Ref<T> | MutableRefObject<T | undefined> | undefined)[]) => (node: T) => void;
|
|
7492
|
-
|
|
7493
|
-
}
|
|
7494
|
-
declare module '@elastic/eui/src/services/hooks/useForceRender' {
|
|
7495
|
-
export const useForceRender: () => () => void;
|
|
7496
|
-
|
|
7497
|
-
}
|
|
7498
|
-
declare module '@elastic/eui/src/services/hooks/useLatest' {
|
|
7499
|
-
import { MutableRefObject } from 'react';
|
|
7500
|
-
/**
|
|
7501
|
-
* Wraps the given `value` into a `MutableRefObject` and keeps the `current`
|
|
7502
|
-
* value up-to-date on every render cycle.
|
|
7503
|
-
*/
|
|
7504
|
-
export function useLatest<Value>(value: Value): MutableRefObject<Value | null>;
|
|
7505
|
-
|
|
7506
|
-
}
|
|
7507
|
-
declare module '@elastic/eui/src/services/hooks/useMouseMove' {
|
|
7508
|
-
import { MouseEvent, TouchEvent } from 'react';
|
|
7509
|
-
export function isMouseEvent<T = HTMLDivElement>(event: MouseEvent<T> | TouchEvent<T>): event is MouseEvent<T>;
|
|
7510
|
-
export function useMouseMove<T = HTMLDivElement>(handleChange: (location: {
|
|
7511
|
-
x: number;
|
|
7512
|
-
y: number;
|
|
7513
|
-
}, isFirstInteraction?: boolean) => void, interactionConditional?: any): [
|
|
7514
|
-
(e: MouseEvent<T>) => void,
|
|
7515
|
-
(e: MouseEvent<T> | TouchEvent<T>, isFirstInteraction?: boolean) => void
|
|
7516
|
-
];
|
|
7517
|
-
|
|
7518
|
-
}
|
|
7519
|
-
declare module '@elastic/eui/src/services/hooks' {
|
|
7520
|
-
export * from '@elastic/eui/src/services/hooks/useDependentState';
|
|
7521
|
-
export * from '@elastic/eui/src/services/hooks/useCombinedRefs';
|
|
7522
|
-
export * from '@elastic/eui/src/services/hooks/useForceRender';
|
|
7523
|
-
export * from '@elastic/eui/src/services/hooks/useLatest';
|
|
7524
|
-
export * from '@elastic/eui/src/services/hooks/useMouseMove';
|
|
7525
|
-
export * from '@elastic/eui/src/services/hooks/useUpdateEffect';
|
|
7526
|
-
|
|
7527
7582
|
}
|
|
7528
7583
|
declare module '@elastic/eui/src/services' {
|
|
7529
7584
|
import * as keys from '@elastic/eui/src/services/keys';
|
|
7530
|
-
export { keys };
|
|
7531
7585
|
export { accessibleClickKeys, cascadingMenuKeys, comboBoxKeys, htmlIdGenerator, useGeneratedHtmlId, } from '@elastic/eui/src/services/accessibility';
|
|
7586
|
+
export { CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT } from '@elastic/eui/src/services/alignment';
|
|
7532
7587
|
export type { HorizontalAlignment } from '@elastic/eui/src/services/alignment';
|
|
7533
|
-
export {
|
|
7588
|
+
export { CurrentEuiBreakpointContext, CurrentEuiBreakpointProvider, useCurrentEuiBreakpoint, useIsWithinBreakpoints, useIsWithinMaxBreakpoint, useIsWithinMinBreakpoint, } from '@elastic/eui/src/services/breakpoint';
|
|
7534
7589
|
export type { EuiBreakpointSize } from '@elastic/eui/src/services/breakpoint';
|
|
7535
|
-
export {
|
|
7590
|
+
export { brighten, calculateContrast, calculateLuminance, colorPalette, darken, DEFAULT_VISUALIZATION_COLOR, desaturate, euiPaletteColorBlind, euiPaletteColorBlindBehindText, euiPaletteComplimentary, euiPaletteCool, euiPaletteForDarkBackground, euiPaletteForLightBackground, euiPaletteForStatus, euiPaletteForTemperature, euiPaletteGray, euiPaletteNegative, euiPalettePositive, euiPaletteWarm, getSteppedGradient, hexToHsv, hexToRgb, hsvToHex, hsvToRgb, isColorDark, isValidHex, lightness, makeDisabledContrastColor, makeHighContrastColor, rgbToHex, rgbToHsv, saturate, shade, shadeOrTint, tint, tintOrShade, transparentize, VISUALIZATION_COLORS, wcagContrastMin, } from '@elastic/eui/src/services/color';
|
|
7536
7591
|
export type { HSV } from '@elastic/eui/src/services/color';
|
|
7537
|
-
export { isColorDark, isValidHex, calculateContrast, calculateLuminance, hexToHsv, hexToRgb, hsvToHex, hsvToRgb, rgbToHex, rgbToHsv, VISUALIZATION_COLORS, DEFAULT_VISUALIZATION_COLOR, colorPalette, euiPaletteForLightBackground, euiPaletteForDarkBackground, euiPaletteColorBlind, euiPaletteColorBlindBehindText, euiPaletteForStatus, euiPaletteForTemperature, euiPaletteComplimentary, euiPaletteNegative, euiPalettePositive, euiPaletteCool, euiPaletteWarm, euiPaletteGray, getSteppedGradient, transparentize, tint, shade, tintOrShade, shadeOrTint, saturate, desaturate, lightness, darken, makeHighContrastColor, makeDisabledContrastColor, wcagContrastMin, } from '@elastic/eui/src/services/color';
|
|
7538
|
-
export type { EuiSetColorMethod } from '@elastic/eui/src/services/color_picker';
|
|
7539
7592
|
export { useColorPickerState, useColorStopsState } from '@elastic/eui/src/services/color_picker';
|
|
7593
|
+
export type { EuiSetColorMethod } from '@elastic/eui/src/services/color_picker';
|
|
7540
7594
|
export * from '@elastic/eui/src/services/console';
|
|
7541
7595
|
export { copyToClipboard } from '@elastic/eui/src/services/copy_to_clipboard';
|
|
7542
7596
|
export * from '@elastic/eui/src/services/findElement';
|
|
7543
|
-
export { formatAuto, formatBoolean, formatDate, formatNumber, formatText,
|
|
7597
|
+
export { dateFormatAliases, formatAuto, formatBoolean, formatDate, formatNumber, formatText, } from '@elastic/eui/src/services/format';
|
|
7598
|
+
export * from '@elastic/eui/src/services/hooks';
|
|
7544
7599
|
export { isEvenlyDivisibleBy, isWithinRange } from '@elastic/eui/src/services/number';
|
|
7545
7600
|
export { Pager } from '@elastic/eui/src/services/paging';
|
|
7601
|
+
export { calculatePopoverPosition, findPopoverPosition } from '@elastic/eui/src/services/popover';
|
|
7546
7602
|
export { Random } from '@elastic/eui/src/services/random';
|
|
7547
7603
|
export { getSecureRelForTarget } from '@elastic/eui/src/services/security';
|
|
7548
|
-
export {
|
|
7549
|
-
export type {
|
|
7550
|
-
export {
|
|
7551
|
-
export
|
|
7604
|
+
export { Comparators, PropertySortType, SortableProperties, SortDirection, SortDirectionType, } from '@elastic/eui/src/services/sort';
|
|
7605
|
+
export type { Direction, PropertySort } from '@elastic/eui/src/services/sort';
|
|
7606
|
+
export { slugify, toInitials, toSentenceCase } from '@elastic/eui/src/services/string';
|
|
7607
|
+
export * from '@elastic/eui/src/services/theme';
|
|
7608
|
+
export { throttle } from '@elastic/eui/src/services/throttle';
|
|
7552
7609
|
export { getDurationAndPerformOnFrame, getTransitionTimings, getWaitDuration, performOnFrame, } from '@elastic/eui/src/services/transition';
|
|
7553
7610
|
export { EuiWindowEvent } from '@elastic/eui/src/services/window_event';
|
|
7554
|
-
export
|
|
7555
|
-
export { throttle } from '@elastic/eui/src/services/throttle';
|
|
7556
|
-
export * from '@elastic/eui/src/services/theme';
|
|
7611
|
+
export { keys };
|
|
7557
7612
|
|
|
7558
7613
|
}
|
|
7559
7614
|
declare module '@elastic/eui/src/global_styling/mixins/_color' {
|
|
@@ -15075,6 +15130,10 @@ declare module '@elastic/eui/src/components/image/image_types' {
|
|
|
15075
15130
|
* When set to `true` will make the image clickable to a larger version
|
|
15076
15131
|
*/
|
|
15077
15132
|
allowFullScreen?: boolean;
|
|
15133
|
+
/**
|
|
15134
|
+
* Callback when the image is clicked and `allowFullScreen` is `true`
|
|
15135
|
+
*/
|
|
15136
|
+
onFullScreen?: (isFullScreen: boolean) => void;
|
|
15078
15137
|
/**
|
|
15079
15138
|
* Changes the color of the icon that floats above the image when it can be clicked to fullscreen.
|
|
15080
15139
|
* The default value of `light` is fine unless your image has a white background, in which case you should change it to `dark`.
|
|
@@ -15085,7 +15144,7 @@ declare module '@elastic/eui/src/components/image/image_types' {
|
|
|
15085
15144
|
*/
|
|
15086
15145
|
wrapperProps?: CommonProps & HTMLAttributes<HTMLDivElement>;
|
|
15087
15146
|
};
|
|
15088
|
-
export type EuiImageWrapperProps = Pick<EuiImageProps, 'alt' | 'caption' | 'float' | 'margin' | 'hasShadow' | 'wrapperProps' | 'fullScreenIconColor' | 'allowFullScreen'> & {
|
|
15147
|
+
export type EuiImageWrapperProps = Pick<EuiImageProps, 'alt' | 'caption' | 'float' | 'margin' | 'hasShadow' | 'wrapperProps' | 'fullScreenIconColor' | 'allowFullScreen' | 'onFullScreen'> & {
|
|
15089
15148
|
isFullWidth: boolean;
|
|
15090
15149
|
setIsFullScreen: (isFullScreen: boolean) => void;
|
|
15091
15150
|
};
|
package/i18ntokens.json
CHANGED
|
@@ -485,11 +485,11 @@
|
|
|
485
485
|
"highlighting": "string",
|
|
486
486
|
"loc": {
|
|
487
487
|
"start": {
|
|
488
|
-
"line":
|
|
488
|
+
"line": 290,
|
|
489
489
|
"column": 8
|
|
490
490
|
},
|
|
491
491
|
"end": {
|
|
492
|
-
"line":
|
|
492
|
+
"line": 299,
|
|
493
493
|
"column": 9
|
|
494
494
|
}
|
|
495
495
|
},
|
|
@@ -501,11 +501,11 @@
|
|
|
501
501
|
"highlighting": "string",
|
|
502
502
|
"loc": {
|
|
503
503
|
"start": {
|
|
504
|
-
"line":
|
|
504
|
+
"line": 290,
|
|
505
505
|
"column": 8
|
|
506
506
|
},
|
|
507
507
|
"end": {
|
|
508
|
-
"line":
|
|
508
|
+
"line": 299,
|
|
509
509
|
"column": 9
|
|
510
510
|
}
|
|
511
511
|
},
|
|
@@ -517,11 +517,11 @@
|
|
|
517
517
|
"highlighting": "string",
|
|
518
518
|
"loc": {
|
|
519
519
|
"start": {
|
|
520
|
-
"line":
|
|
520
|
+
"line": 341,
|
|
521
521
|
"column": 12
|
|
522
522
|
},
|
|
523
523
|
"end": {
|
|
524
|
-
"line":
|
|
524
|
+
"line": 346,
|
|
525
525
|
"column": 14
|
|
526
526
|
}
|
|
527
527
|
},
|
|
@@ -533,11 +533,11 @@
|
|
|
533
533
|
"highlighting": "string",
|
|
534
534
|
"loc": {
|
|
535
535
|
"start": {
|
|
536
|
-
"line":
|
|
536
|
+
"line": 351,
|
|
537
537
|
"column": 12
|
|
538
538
|
},
|
|
539
539
|
"end": {
|
|
540
|
-
"line":
|
|
540
|
+
"line": 357,
|
|
541
541
|
"column": 13
|
|
542
542
|
}
|
|
543
543
|
},
|
|
@@ -549,11 +549,11 @@
|
|
|
549
549
|
"highlighting": "string",
|
|
550
550
|
"loc": {
|
|
551
551
|
"start": {
|
|
552
|
-
"line":
|
|
552
|
+
"line": 351,
|
|
553
553
|
"column": 12
|
|
554
554
|
},
|
|
555
555
|
"end": {
|
|
556
|
-
"line":
|
|
556
|
+
"line": 357,
|
|
557
557
|
"column": 13
|
|
558
558
|
}
|
|
559
559
|
},
|
|
@@ -565,11 +565,11 @@
|
|
|
565
565
|
"highlighting": "string",
|
|
566
566
|
"loc": {
|
|
567
567
|
"start": {
|
|
568
|
-
"line":
|
|
568
|
+
"line": 383,
|
|
569
569
|
"column": 16
|
|
570
570
|
},
|
|
571
571
|
"end": {
|
|
572
|
-
"line":
|
|
572
|
+
"line": 386,
|
|
573
573
|
"column": 17
|
|
574
574
|
}
|
|
575
575
|
},
|
|
@@ -581,11 +581,11 @@
|
|
|
581
581
|
"highlighting": "string",
|
|
582
582
|
"loc": {
|
|
583
583
|
"start": {
|
|
584
|
-
"line":
|
|
584
|
+
"line": 534,
|
|
585
585
|
"column": 10
|
|
586
586
|
},
|
|
587
587
|
"end": {
|
|
588
|
-
"line":
|
|
588
|
+
"line": 542,
|
|
589
589
|
"column": 12
|
|
590
590
|
}
|
|
591
591
|
},
|
|
@@ -5109,11 +5109,11 @@
|
|
|
5109
5109
|
"highlighting": "string",
|
|
5110
5110
|
"loc": {
|
|
5111
5111
|
"start": {
|
|
5112
|
-
"line":
|
|
5112
|
+
"line": 688,
|
|
5113
5113
|
"column": 16
|
|
5114
5114
|
},
|
|
5115
5115
|
"end": {
|
|
5116
|
-
"line":
|
|
5116
|
+
"line": 691,
|
|
5117
5117
|
"column": 18
|
|
5118
5118
|
}
|
|
5119
5119
|
},
|
|
@@ -260,7 +260,7 @@ var EuiAccordionClass = /*#__PURE__*/function (_Component) {
|
|
|
260
260
|
css: cssSpinnerStyles
|
|
261
261
|
}), (0, _react2.jsx)(_text.EuiText, {
|
|
262
262
|
size: "s"
|
|
263
|
-
}, (0, _react2.jsx)("p", null, isLoadingMessage
|
|
263
|
+
}, (0, _react2.jsx)("p", null, isLoadingMessage !== true ? isLoadingMessage : (0, _react2.jsx)(_i18n.EuiI18n, {
|
|
264
264
|
token: "euiAccordion.isLoading",
|
|
265
265
|
default: "Loading"
|
|
266
266
|
}))));
|
|
@@ -1261,7 +1261,7 @@ EuiBasicTable.propTypes = {
|
|
|
1261
1261
|
/**
|
|
1262
1262
|
* Defines the horizontal alignment of the column
|
|
1263
1263
|
*/
|
|
1264
|
-
align: _propTypes.default.
|
|
1264
|
+
align: _propTypes.default.any,
|
|
1265
1265
|
|
|
1266
1266
|
/**
|
|
1267
1267
|
* Indicates whether this column should truncate its content when it doesn't fit
|
|
@@ -1320,7 +1320,7 @@ EuiBasicTable.propTypes = {
|
|
|
1320
1320
|
*/
|
|
1321
1321
|
truncateText: _propTypes.default.bool,
|
|
1322
1322
|
isExpander: _propTypes.default.bool,
|
|
1323
|
-
align: _propTypes.default.
|
|
1323
|
+
align: _propTypes.default.any,
|
|
1324
1324
|
|
|
1325
1325
|
/**
|
|
1326
1326
|
* Disables the user's ability to change the sort but still shows the current direction
|
|
@@ -686,7 +686,7 @@ EuiInMemoryTable.propTypes = {
|
|
|
686
686
|
/**
|
|
687
687
|
* Defines the horizontal alignment of the column
|
|
688
688
|
*/
|
|
689
|
-
align: _propTypes.default.
|
|
689
|
+
align: _propTypes.default.any,
|
|
690
690
|
|
|
691
691
|
/**
|
|
692
692
|
* Indicates whether this column should truncate its content when it doesn't fit
|
|
@@ -745,7 +745,7 @@ EuiInMemoryTable.propTypes = {
|
|
|
745
745
|
*/
|
|
746
746
|
truncateText: _propTypes.default.bool,
|
|
747
747
|
isExpander: _propTypes.default.bool,
|
|
748
|
-
align: _propTypes.default.
|
|
748
|
+
align: _propTypes.default.any,
|
|
749
749
|
|
|
750
750
|
/**
|
|
751
751
|
* Disables the user's ability to change the sort but still shows the current direction
|
|
@@ -1200,10 +1200,7 @@ EuiInMemoryTable.propTypes = {
|
|
|
1200
1200
|
"aria-label": _propTypes.default.string
|
|
1201
1201
|
}).isRequired])]),
|
|
1202
1202
|
sorting: _propTypes.default.oneOfType([_propTypes.default.bool.isRequired, _propTypes.default.shape({
|
|
1203
|
-
sort: _propTypes.default.
|
|
1204
|
-
field: _propTypes.default.string.isRequired,
|
|
1205
|
-
direction: _propTypes.default.oneOfType([_propTypes.default.any.isRequired, _propTypes.default.any.isRequired]).isRequired
|
|
1206
|
-
}).isRequired
|
|
1203
|
+
sort: _propTypes.default.any.isRequired
|
|
1207
1204
|
}).isRequired]),
|
|
1208
1205
|
|
|
1209
1206
|
/**
|