@digital-ai/dot-components 2.0.0-rc.1 → 2.0.0-rc.2
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/CHANGE_LOG.md +65 -4
- package/fonts/dot.woff +0 -0
- package/fonts/selection.json +280 -281
- package/index.d.ts +2 -1
- package/index.esm.js +387 -194
- package/index.umd.js +490 -262
- package/lib/components/alert-banner/AlertBanner.d.ts +3 -1
- package/lib/components/auto-complete/AutoComplete.d.ts +9 -2
- package/lib/components/auto-complete/index.d.ts +1 -1
- package/lib/components/auto-complete/utils/helpers.d.ts +7 -1
- package/lib/components/avatar/Avatar.d.ts +3 -1
- package/lib/components/dynamic-form/utils/formHelpers.d.ts +1 -1
- package/lib/components/file-upload/FileListItem.d.ts +4 -1
- package/lib/components/file-upload/FileUpload.stories.data.d.ts +3 -2
- package/lib/components/file-upload/utils/helpers.d.ts +2 -1
- package/lib/components/inline-edit/InlineEdit.d.ts +5 -1
- package/lib/components/input-form-fields/InputFormFields.propTypes.d.ts +10 -0
- package/lib/components/input-form-fields/InputFormFields.styles.d.ts +4 -1
- package/lib/components/input-form-fields/InputLabel.d.ts +16 -0
- package/lib/components/input-form-fields/InputSelect.d.ts +2 -4
- package/lib/components/input-form-fields/InputText.d.ts +11 -3
- package/lib/components/navigation-rail/NavigationRail.d.ts +4 -0
- package/lib/components/navigation-rail/NavigationRail.stories.data.d.ts +9 -0
- package/lib/components/navigation-rail/NavigationRail.stories.styles.d.ts +2 -0
- package/lib/components/pill/Pill.d.ts +9 -1
- package/lib/components/popper/index.d.ts +1 -1
- package/lib/components/radio/RadioGroup.styles.d.ts +0 -4
- package/lib/components/typography/Typography.d.ts +3 -1
- package/package.json +1 -1
|
@@ -9,9 +9,11 @@ export interface AlertBannerProps extends CommonProps {
|
|
|
9
9
|
children: ReactNode | string;
|
|
10
10
|
/** callback which is triggered when alert banner is closed */
|
|
11
11
|
onClose?: (event: MouseEvent) => void;
|
|
12
|
+
/** If true, the alert banner will have rounded corners */
|
|
13
|
+
roundedCorners?: boolean;
|
|
12
14
|
/** will determine color and icon being used */
|
|
13
15
|
severity: AlertBannerSeverity;
|
|
14
16
|
/** when specified, will control the text that is used inside the alert banner */
|
|
15
17
|
textVariant?: TypographyVariant;
|
|
16
18
|
}
|
|
17
|
-
export declare const DotAlertBanner: ({ action, ariaLabel, children, className, "data-testid": dataTestId, onClose, severity, textVariant, }: AlertBannerProps) => JSX.Element;
|
|
19
|
+
export declare const DotAlertBanner: ({ action, ariaLabel, children, className, "data-testid": dataTestId, onClose, roundedCorners, severity, textVariant, }: AlertBannerProps) => JSX.Element;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ChangeEvent, ReactNode, Ref } from 'react';
|
|
1
|
+
import { ChangeEvent, FocusEvent, ReactNode, Ref } from 'react';
|
|
2
2
|
import { AutocompleteCloseReason, AutocompleteGetTagProps, AutocompleteRenderOptionState } from '@mui/material';
|
|
3
3
|
import { CommonProps } from '../CommonProps';
|
|
4
4
|
export declare const DEFAULT_ACTION_ITEM_TEXT = "Add new item";
|
|
@@ -36,6 +36,7 @@ export interface AutoCompleteProps<T extends AutoCompleteOption = AutoCompleteOp
|
|
|
36
36
|
disablePortal?: boolean;
|
|
37
37
|
/** If true, the input will be disabled. */
|
|
38
38
|
disabled?: boolean;
|
|
39
|
+
endAdornmentTooltip?: string;
|
|
39
40
|
/** If true, the input will be displayed in an error state. */
|
|
40
41
|
error?: boolean;
|
|
41
42
|
/** If `true`, hide the selected options from the list box. */
|
|
@@ -58,6 +59,8 @@ export interface AutoCompleteProps<T extends AutoCompleteOption = AutoCompleteOp
|
|
|
58
59
|
maxHeight?: number | string;
|
|
59
60
|
/** If true, will allow the user to select multiple options */
|
|
60
61
|
multiple?: boolean;
|
|
62
|
+
/** Callback function which will be executed upon blur event */
|
|
63
|
+
onBlur?: (event: FocusEvent<HTMLElement>) => void;
|
|
61
64
|
/** A function that should be executed when the autocomplete value changes */
|
|
62
65
|
onChange?: (event: ChangeEvent<unknown>, value: AutoCompleteValue, reason: string) => void;
|
|
63
66
|
/** Callback fired when the popup requests to be closed. Use in controlled mode. */
|
|
@@ -72,6 +75,8 @@ export interface AutoCompleteProps<T extends AutoCompleteOption = AutoCompleteOp
|
|
|
72
75
|
options?: Array<T>;
|
|
73
76
|
/** Placeholder text always displayed inside the input field */
|
|
74
77
|
placeholder?: string;
|
|
78
|
+
/** If true: popper cannot be opened, TextField is in read only mode, change is not allowed */
|
|
79
|
+
readOnly?: boolean;
|
|
75
80
|
/** Render the option, use `getOptionLabel` by default. */
|
|
76
81
|
renderOption?: (props: React.HTMLAttributes<HTMLLIElement>, option: T, state: AutocompleteRenderOptionState) => ReactNode;
|
|
77
82
|
/** Render the selected value. */
|
|
@@ -82,5 +87,7 @@ export interface AutoCompleteProps<T extends AutoCompleteOption = AutoCompleteOp
|
|
|
82
87
|
size?: autoCompleteSize;
|
|
83
88
|
/** value if this is a controlled component */
|
|
84
89
|
value?: AutoCompleteValue;
|
|
90
|
+
/** If true, the label will be displayed in a warning state. */
|
|
91
|
+
warning?: boolean;
|
|
85
92
|
}
|
|
86
|
-
export declare const DotAutoComplete: <T extends AutoCompleteOption>({ actionItem, ariaLabel, autoFocus, className, "data-testid": dataTestId, defaultValue, dense, disabled, disablePortal, error, filterSelectedOptions, freesolo, group, helperText, inputId, inputRef, label, loading, maxHeight, multiple, onChange, onClose, onInputChange, onOpen, open, options, placeholder, renderOption, renderTags, required, size, value, }: AutoCompleteProps<T>) => JSX.Element;
|
|
93
|
+
export declare const DotAutoComplete: <T extends AutoCompleteOption>({ actionItem, ariaLabel, autoFocus, className, "data-testid": dataTestId, defaultValue, dense, disabled, disablePortal, endAdornmentTooltip, error, filterSelectedOptions, freesolo, group, helperText, inputId, inputRef, label, loading, maxHeight, multiple, onBlur, onChange, onClose, onInputChange, onOpen, open, options, placeholder, readOnly, renderOption, renderTags, required, size, value, warning, }: AutoCompleteProps<T>) => JSX.Element;
|
|
@@ -2,5 +2,11 @@ import { AutocompleteGetTagProps } from '@mui/material';
|
|
|
2
2
|
import { ChipSize } from '../../chip/Chip';
|
|
3
3
|
import { AutoCompleteOption, AutoCompleteValue } from '../AutoComplete';
|
|
4
4
|
export declare const parseAutoCompleteValue: (value: AutoCompleteValue) => string;
|
|
5
|
-
export
|
|
5
|
+
export interface GetChipsFromAutocompleteProps {
|
|
6
|
+
chipSize?: ChipSize;
|
|
7
|
+
getTagProps: AutocompleteGetTagProps;
|
|
8
|
+
isReadOnly?: boolean;
|
|
9
|
+
values: Array<AutoCompleteOption | string>;
|
|
10
|
+
}
|
|
11
|
+
export declare const getChipsFromAutocomplete: ({ chipSize, getTagProps, isReadOnly, values, }: GetChipsFromAutocompleteProps) => JSX.Element[];
|
|
6
12
|
export declare const checkIfDuplicateItem: (itemText: string, autocompleteOptions: AutoCompleteOption[]) => boolean;
|
|
@@ -21,6 +21,8 @@ export interface AvatarProps extends CommonProps {
|
|
|
21
21
|
size?: AvatarSize;
|
|
22
22
|
/** To be used to override styles inline */
|
|
23
23
|
style?: CSSProperties;
|
|
24
|
+
/** tab order for the avatar */
|
|
25
|
+
tabIndex?: number;
|
|
24
26
|
/** The text to be displayed. Only the first 2 letters will be displayed. */
|
|
25
27
|
text?: string;
|
|
26
28
|
/** Tooltip for avatar */
|
|
@@ -30,4 +32,4 @@ export interface AvatarProps extends CommonProps {
|
|
|
30
32
|
/** The shape of the avatar */
|
|
31
33
|
variant?: AvatarVariant;
|
|
32
34
|
}
|
|
33
|
-
export declare const DotAvatar: ({ alt, ariaLabel, className, component, color, "data-testid": dataTestId, iconId, imageSrc, onClick, size, text, type, tooltip, variant, style, }: AvatarProps) => JSX.Element;
|
|
35
|
+
export declare const DotAvatar: ({ alt, ariaLabel, className, component, color, "data-testid": dataTestId, iconId, imageSrc, onClick, size, tabIndex, text, type, tooltip, variant, style, }: AvatarProps) => JSX.Element;
|
|
@@ -20,7 +20,7 @@ export interface UncontrolledInputArgs extends InputBaseArgs {
|
|
|
20
20
|
formState?: DynamicFormState;
|
|
21
21
|
handleClick?: (formValues?: DynamicFormOutputData) => void;
|
|
22
22
|
}
|
|
23
|
-
export declare const getInitialStateFromControl: ({ hidden, initialValue, controlType, validation
|
|
23
|
+
export declare const getInitialStateFromControl: ({ hidden, initialValue, controlType, validation }: DynamicFormControl, liveValidation: boolean, formValues: DynamicFormOutputData) => DynamicFormStateItem;
|
|
24
24
|
export declare const getInitialFormState: (config: DynamicFormConfig, liveValidation: boolean) => DynamicFormState;
|
|
25
25
|
export declare const getControlClickHandler: (formValues: DynamicFormOutputData, onControlClick?: ControlClickHandler) => () => void;
|
|
26
26
|
export declare const buildInputTextControl: ({ controlName, controlProps, disabled, formData, handleChange, index, }: ControlledInputArgs) => JSX.Element;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { KeyboardEvent } from 'react';
|
|
1
2
|
import { CommonProps } from '../CommonProps';
|
|
2
3
|
export interface ListItemFile {
|
|
3
4
|
id: string | number;
|
|
@@ -10,5 +11,7 @@ export interface FileItemProps extends CommonProps {
|
|
|
10
11
|
errorText?: string;
|
|
11
12
|
file: ListItemFile;
|
|
12
13
|
onClick?: (file: ListItemFile) => void;
|
|
14
|
+
onKeyPress?: (event: KeyboardEvent<Element>) => void;
|
|
15
|
+
tabIndex?: number;
|
|
13
16
|
}
|
|
14
|
-
export declare const DotFileListItem: ({ ariaLabel, className, "data-testid": dataTestId, deleteFile, disableDelete, error, errorText, file, onClick, }: FileItemProps) => JSX.Element;
|
|
17
|
+
export declare const DotFileListItem: ({ ariaLabel, className, "data-testid": dataTestId, deleteFile, disableDelete, error, errorText, file, onClick, onKeyPress, tabIndex, }: FileItemProps) => JSX.Element;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { FileUploadProps } from './';
|
|
1
|
+
import { FileUploadProps, MappedListItemFile } from './';
|
|
2
2
|
export interface CustomFileUploadArgs {
|
|
3
|
+
alreadyUploadedFiles?: MappedListItemFile[];
|
|
3
4
|
args: FileUploadProps;
|
|
4
5
|
}
|
|
5
|
-
export declare const CustomFileUpload: ({ args }: CustomFileUploadArgs) => JSX.Element;
|
|
6
|
+
export declare const CustomFileUpload: ({ args, alreadyUploadedFiles, }: CustomFileUploadArgs) => JSX.Element;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React, { ReactNode } from 'react';
|
|
2
2
|
import { FileRejection } from 'react-dropzone';
|
|
3
|
-
import { DropzoneContentArgs, ParseListItemArgs, UploadedFilesListArgs } from './models';
|
|
3
|
+
import { DropzoneContentArgs, FileUploadError, ParseListItemArgs, UploadedFilesListArgs } from './models';
|
|
4
4
|
export declare const renderMaxSizeMessage: (maxSizeMB: number) => ReactNode;
|
|
5
5
|
export declare const renderMaxFilesMessage: (maxFiles: number, maxFilesClasses: string) => ReactNode;
|
|
6
6
|
export declare const renderSelectFilesButton: (isUploadDisabled: boolean, onButtonClick: () => void) => ReactNode;
|
|
@@ -21,3 +21,4 @@ export declare const joinAcceptedAndRejectedFiles: (filesAccepted: File[], files
|
|
|
21
21
|
file: File;
|
|
22
22
|
errors: any[];
|
|
23
23
|
}[];
|
|
24
|
+
export declare const getErrorMessagesForDisplay: (errors: FileUploadError[]) => string;
|
|
@@ -18,6 +18,10 @@ export interface InlineEditProps extends CommonProps {
|
|
|
18
18
|
onEditStateChange?: (editing: boolean) => void;
|
|
19
19
|
/** If true, component will behave like a regular text (editing functionality will be disabled). */
|
|
20
20
|
readOnly?: boolean;
|
|
21
|
+
/** If true, when starting edit it will select all text in the input */
|
|
22
|
+
selectTextOnEdit?: boolean;
|
|
23
|
+
/** tab order for the inline edit */
|
|
24
|
+
tabIndex?: number;
|
|
21
25
|
/** Tooltip text displayed on hover */
|
|
22
26
|
tooltip?: string;
|
|
23
27
|
/** Typography variant to be used */
|
|
@@ -28,4 +32,4 @@ export interface InlineEditProps extends CommonProps {
|
|
|
28
32
|
/**
|
|
29
33
|
* @experimental This component is still in development
|
|
30
34
|
*/
|
|
31
|
-
export declare const DotInlineEdit: ({ ariaLabel, bindings, charactersLimit, className, "data-testid": dataTestId, fullWidth, hideActionButtons, name, onChange, onEditStateChange, readOnly, tooltip, typography, value, }: InlineEditProps) => JSX.Element;
|
|
35
|
+
export declare const DotInlineEdit: ({ ariaLabel, bindings, charactersLimit, className, "data-testid": dataTestId, fullWidth, hideActionButtons, name, onChange, onEditStateChange, readOnly, selectTextOnEdit, tabIndex, tooltip, typography, value, }: InlineEditProps) => JSX.Element;
|
|
@@ -37,17 +37,27 @@ export interface InputProps extends CommonProps {
|
|
|
37
37
|
onKeyDown?: (event: KeyboardEvent) => void;
|
|
38
38
|
/** A function that executes when a user releases a mouse button over an element. */
|
|
39
39
|
onMouseUp?: (event: MouseEvent) => void;
|
|
40
|
+
/** If true, the label will be persistently displayed outside of the field */
|
|
41
|
+
persistentLabel?: boolean;
|
|
42
|
+
/** If true, the input will be read-only. */
|
|
43
|
+
readOnly?: boolean;
|
|
40
44
|
/** If true, the label is displayed as required and the input element` will be required. */
|
|
41
45
|
required?: boolean;
|
|
46
|
+
/** If specified, the label being shrunk/unshrunk must be controlled by the consumer */
|
|
47
|
+
shrink?: boolean;
|
|
42
48
|
/** Size of the input */
|
|
43
49
|
size?: inputSizeOptions;
|
|
44
50
|
/** Icon placed before the children. */
|
|
45
51
|
startIcon?: ReactNode;
|
|
52
|
+
/** If true, the label and field will be displayed in a success state */
|
|
53
|
+
success?: boolean;
|
|
46
54
|
/**
|
|
47
55
|
* Type of input should be a valid HTML 5 input type
|
|
48
56
|
* https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input#input_types
|
|
49
57
|
*/
|
|
50
58
|
type?: string;
|
|
59
|
+
/** value of input field */
|
|
60
|
+
value?: string;
|
|
51
61
|
/** If true, the label will be displayed in an warning state. */
|
|
52
62
|
warning?: boolean;
|
|
53
63
|
}
|
|
@@ -1,8 +1,11 @@
|
|
|
1
|
-
import { TextField } from '@mui/material';
|
|
1
|
+
import { TextField, InputLabel } from '@mui/material';
|
|
2
2
|
export declare const rootClassName = "dot-text-field";
|
|
3
3
|
export declare const rootSelectClassName = "dot-select-field";
|
|
4
|
+
export declare const labelClassName = "dot-input-label";
|
|
4
5
|
export declare const warningClassName = "dot-warning";
|
|
6
|
+
export declare const successClassName = "dot-success";
|
|
5
7
|
export declare const adornmentIconClassName = "dot-adornment-icon";
|
|
6
8
|
export declare const fieldsetClassName = "MuiOutlinedInput-notchedOutline";
|
|
7
9
|
export declare const StyledAdornment: import("styled-components").StyledComponent<import("@mui/material/OverridableComponent").OverridableComponent<import("@mui/material").InputAdornmentTypeMap<{}, "div">>, any, {}, never>;
|
|
10
|
+
export declare const StyledInputLabel: import("styled-components").StyledComponent<typeof InputLabel, any, {}, never>;
|
|
8
11
|
export declare const StyledTextField: import("styled-components").StyledComponent<typeof TextField, any, {}, never>;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
export interface InputLabelProps {
|
|
2
|
+
/** If true, the input will be disabled. */
|
|
3
|
+
disabled?: boolean;
|
|
4
|
+
/** If true, the label will be displayed in an error state. */
|
|
5
|
+
error?: boolean;
|
|
6
|
+
/**
|
|
7
|
+
* id to identify the element, also used to create label "for" and helper text id attribute
|
|
8
|
+
* values while it's optional, it is considered required for accessiblity best practice.
|
|
9
|
+
*/
|
|
10
|
+
id: string;
|
|
11
|
+
/** The label content. */
|
|
12
|
+
label?: string;
|
|
13
|
+
/** If true, the label is displayed as required and the input element` will be required. */
|
|
14
|
+
required?: boolean;
|
|
15
|
+
}
|
|
16
|
+
export declare const DotInputLabel: ({ disabled, error, id, label, required, }: InputLabelProps) => JSX.Element;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { InputProps } from './InputFormFields.propTypes';
|
|
2
2
|
export declare type OptionType = string | InputSelectOption;
|
|
3
3
|
export interface InputSelectOption {
|
|
4
|
-
/** options that
|
|
4
|
+
/** options that appear in dropdown */
|
|
5
5
|
option: string;
|
|
6
6
|
/** value of input field when option is selected */
|
|
7
7
|
value?: string;
|
|
@@ -11,7 +11,5 @@ export interface InputSelectProps extends InputProps {
|
|
|
11
11
|
defaultValue?: string;
|
|
12
12
|
/** options of select dropdown */
|
|
13
13
|
options: Array<OptionType>;
|
|
14
|
-
/** value of input field */
|
|
15
|
-
value?: string;
|
|
16
14
|
}
|
|
17
|
-
export declare const DotInputSelect: ({ ariaLabel, autoFocus, className, "data-testid": dataTestId, defaultValue, disabled, endIcon, error, fullWidth, helperText, id, inputRef, label, name, onBlur, onChange, onFocus, onKeyDown, options, required, size, startIcon, value, warning, }: InputSelectProps) => JSX.Element;
|
|
15
|
+
export declare const DotInputSelect: ({ ariaLabel, autoFocus, className, "data-testid": dataTestId, defaultValue, disabled, endIcon, error, fullWidth, helperText, id, inputRef, label, name, onBlur, onChange, onFocus, onKeyDown, options, persistentLabel, readOnly, required, shrink, size, startIcon, success, value, warning, }: InputSelectProps) => JSX.Element;
|
|
@@ -1,5 +1,7 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
1
2
|
import { InputProps } from './InputFormFields.propTypes';
|
|
2
3
|
export declare const DELAY_MS = 300;
|
|
4
|
+
export declare type endAdornmentIconType = 'warning' | 'error' | 'check';
|
|
3
5
|
export interface InputTextProps extends InputProps {
|
|
4
6
|
/** The HTML autocomplete property to pass along to the input tag. Used for
|
|
5
7
|
controlling autofill behavior in forms. This property follows this HTML spec:
|
|
@@ -17,9 +19,15 @@ export interface InputTextProps extends InputProps {
|
|
|
17
19
|
multiline?: boolean;
|
|
18
20
|
/** Placeholder text always displayed inside the input field */
|
|
19
21
|
placeholder?: string;
|
|
20
|
-
/** If true, the input will be read-only. */
|
|
21
|
-
readOnly?: boolean;
|
|
22
22
|
/** value of the InputText */
|
|
23
23
|
value?: string;
|
|
24
24
|
}
|
|
25
|
-
export
|
|
25
|
+
export interface EndIconProps {
|
|
26
|
+
dataTestId?: string;
|
|
27
|
+
endAdornmentTooltip?: string;
|
|
28
|
+
endIcon?: ReactNode;
|
|
29
|
+
error?: boolean;
|
|
30
|
+
success?: boolean;
|
|
31
|
+
warning?: boolean;
|
|
32
|
+
}
|
|
33
|
+
export declare const DotInputText: ({ autoComplete, autoFocus, className, defaultValue, "data-testid": dataTestId, disabled, error, endAdornmentTooltip, fullWidth, hasDebounce, helperText, endIcon, id, inputRef, label, maxRows, minRows, multiline, name, onBlur, onChange, onFocus, onKeyDown, onMouseUp, persistentLabel, placeholder, readOnly, required, shrink, startIcon, size, success, type, value, warning, }: InputTextProps) => JSX.Element;
|
|
@@ -1,8 +1,12 @@
|
|
|
1
1
|
import { CommonProps } from '../CommonProps';
|
|
2
|
+
import { BadgeProps } from '../badge';
|
|
2
3
|
export declare type RailItemsPosition = 'flex-start' | 'center' | 'flex-end';
|
|
4
|
+
export declare type RailIconBadge = Omit<BadgeProps, 'children'>;
|
|
3
5
|
export interface RailItem {
|
|
4
6
|
/** Defines a string value that labels the current element **/
|
|
5
7
|
ariaLabel?: string;
|
|
8
|
+
/** Optional badge which will be displayed over an icon **/
|
|
9
|
+
iconBadge?: RailIconBadge;
|
|
6
10
|
/** Id of the icon shown in the rail item */
|
|
7
11
|
iconId: string;
|
|
8
12
|
/** text displayed or title text if icon used */
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { RailItem } from './NavigationRail';
|
|
2
|
+
export interface BadgeCount {
|
|
3
|
+
activity: number;
|
|
4
|
+
conditions: number;
|
|
5
|
+
properties: number;
|
|
6
|
+
scheduling: number;
|
|
7
|
+
}
|
|
8
|
+
export declare const mockRailItems: Array<RailItem>;
|
|
9
|
+
export declare const getBadgeRailItems: ({ activity, conditions, properties, scheduling, }: BadgeCount) => RailItem[];
|
|
@@ -1,2 +1,4 @@
|
|
|
1
1
|
export declare const programmaticNavigationClassName = "dot-programmatic-navigation-story";
|
|
2
|
+
export declare const withBadgesClassName = "dot-with-badges-story";
|
|
2
3
|
export declare const StyledWithProgrammaticNavigation: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
4
|
+
export declare const StyledWithBadges: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
@@ -1,9 +1,15 @@
|
|
|
1
|
+
import { ReactElement } from 'react';
|
|
1
2
|
import { CommonProps } from '../CommonProps';
|
|
2
3
|
export declare type PillSize = 'small' | 'medium';
|
|
3
4
|
export declare type PillStatus = 'success' | 'error' | 'warning' | 'in-progress' | 'default';
|
|
5
|
+
export declare type PillVariant = 'filled' | 'outlined';
|
|
4
6
|
export interface PillProps extends CommonProps {
|
|
5
7
|
/** Background color for the pill, ignored if 'status' is not 'default' */
|
|
6
8
|
backgroundcolor?: string;
|
|
9
|
+
/** Border color for the pill, ignored if 'status' is not 'default' */
|
|
10
|
+
bordercolor?: string;
|
|
11
|
+
/** The icon for the pill */
|
|
12
|
+
icon?: ReactElement;
|
|
7
13
|
/** The text for the pill. */
|
|
8
14
|
label: string;
|
|
9
15
|
/** Label color for the pill, ignored if 'status' is not 'default' */
|
|
@@ -12,5 +18,7 @@ export interface PillProps extends CommonProps {
|
|
|
12
18
|
size?: PillSize;
|
|
13
19
|
/** Determines the status of the pill component */
|
|
14
20
|
status?: PillStatus;
|
|
21
|
+
/** Determines the variant of the pill 'filled' or 'outlined' */
|
|
22
|
+
variant?: PillVariant;
|
|
15
23
|
}
|
|
16
|
-
export declare const DotPill: ({ ariaLabel, backgroundcolor, className, "data-testid": dataTestId, label, labelcolor, size, status, }: PillProps) => JSX.Element;
|
|
24
|
+
export declare const DotPill: ({ ariaLabel, backgroundcolor, bordercolor, className, "data-testid": dataTestId, icon, label, labelcolor, size, status, variant, }: PillProps) => JSX.Element;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { PopperPlacementType } from '@mui/material';
|
|
1
|
+
export type { PopperPlacementType } from '@mui/material';
|
|
2
2
|
export * from './Popper';
|
|
@@ -2,9 +2,5 @@ import { RadioGroup } from '@mui/material';
|
|
|
2
2
|
export declare const wrapperClassName = "dot-radio-group-wrapper";
|
|
3
3
|
export declare const groupClassName = "dot-radio-group";
|
|
4
4
|
export declare const rootClassName = "dot-radio-control";
|
|
5
|
-
export declare const groupLabelClassName = "dot-radio-group-label";
|
|
6
|
-
export declare const startAdornmentClassName = "dot-start-adornment";
|
|
7
|
-
export declare const endAdornmentClassName = "dot-end-adornment";
|
|
8
|
-
export declare const placementClassName = "dot-";
|
|
9
5
|
export declare const StyledRadioGroupWrapper: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
10
6
|
export declare const StyledRadioGroup: import("styled-components").StyledComponent<typeof RadioGroup, any, {}, never>;
|
|
@@ -6,9 +6,11 @@ export interface TypographyProps extends CommonProps {
|
|
|
6
6
|
children: ReactNode;
|
|
7
7
|
/** The component used for the root node. Either a string to use a HTML element or a component. */
|
|
8
8
|
component?: ElementType;
|
|
9
|
+
/** If true, the typography will not have a bottom margin set */
|
|
10
|
+
noMarginBottom?: boolean;
|
|
9
11
|
/** If true, the text will wrap and not be truncated */
|
|
10
12
|
noWrap?: boolean;
|
|
11
13
|
/** Applies the theme typography styles. */
|
|
12
14
|
variant?: TypographyVariant;
|
|
13
15
|
}
|
|
14
|
-
export declare const DotTypography: ({ ariaLabel, className, "data-testid": dataTestId, children, component, noWrap, variant, }: TypographyProps) => JSX.Element;
|
|
16
|
+
export declare const DotTypography: ({ ariaLabel, className, "data-testid": dataTestId, children, component, noMarginBottom, noWrap, variant, }: TypographyProps) => JSX.Element;
|