import { EventEmitter } from "../../stencil-public-runtime"; import { A11yComponent, ThemeableComponent } from "../../common"; import { DuetColor, DuetTheme } from "../../common-types"; import { DuetLangObject } from "../../utils/language-utils"; export type DuetActionButtonEvent = { originalEvent?: Event; component: "duet-action-button"; action: string; name?: string; id?: string | undefined; index?: string | undefined; meta?: Record | string | undefined; }; export type DuetActionButtonIconSize = "xx-small" | "x-small" | "small"; /** * @slot default - slot inside an invisible element, this can be used to enhance accessibility * @part button - this part enables style overrides for the button * @part icon - this part enables style overrides for the icon */ export declare class DuetActionButton implements ThemeableComponent, A11yComponent { private listId; private nativeButton?; numbersStore: string; /** * Reference to host HTML element. */ element: HTMLElement; /** * Theme of the pagination. */ theme: DuetTheme; /** * Name of the icon to display */ iconName: string; /** * Color of the icon to display */ iconColor: string; /** * Size of the icon */ iconSize: DuetActionButtonIconSize; /** * Name of action being called */ actionName: string; /** * Name of id of action that was called being called */ actionId: string; /** * Name of id of action that was called being called */ actionMeta: Record | string; /** * Disables the button */ disabled: boolean; /** * Custom color to be used for the icon, as a design token entered in camelCase * or kebab-case. Example: "color-primary". This property can also be set to * "currentColor" which forces the icon to use the CSS text color of parent * element instead. Useful when you want to control the color in stylesheet * instead. */ color: DuetColor; /** * Custom color to be used for a background, as a design token entered * in camelCase or kebab-case. Using this option the icon will always be resized * to $size-icon-medium on mobile viewports. Example: "color-primary". */ background: DuetColor; /** * Title of the action button (shows as DOM tooltip when hovering) * if set to true, this will try to add a best-guess title based on action-name * if set to a string the string is used * if set to false nothing is set */ accessibleTitle: string | boolean; /** * Described By id */ accessibleDescribedBy: string; /** * Details of the component */ accessibleDetails: string; /** * String of id's that indicate alternative labels elements */ accessibleLabelledBy: string; /** * Aria description the button */ accessibleDescription: string; /** * Default accessible label */ accessibleLabelsDefaults: DuetLangObject; /** * Accessible label */ accessibleLabel: string; /** * Used to indicate which dom element with ID this element controls */ accessibleControls: string; /** * A destination to link to, rendered in the href attribute of a link. */ url: string; /** * Emitted when an action has been invoked */ duetActionEvent: EventEmitter; /** * Private methods. */ private emitPageEvent; private onKeyboardDown; private getTitle; private onMouseHandler; /** * Component lifecycle events. */ componentWillLoad(): void; connectedCallback(): void; disconnectedCallback(): void; /** * Sets focus on the specified `duet-action-button`. Use this method instead of the global * `button.focus()`. */ setFocus(options?: FocusOptions): Promise; /** * render() function * Always the last one in the class. */ render(): any; }