UNPKG

@open-condo/ui

Version:

A set of React UI components for developing applications inside the condo ecosystem

52 lines 1.98 kB
import { TextAreaProps as AntdTextAreaProps } from 'antd/es/input'; import React, { TextareaHTMLAttributes } from 'react'; import { Dropdown } from '../Dropdown'; import type { InputRef } from 'antd'; export declare const TEXTAREA_CLASS_PREFIX = "condo-input"; export type TextAreaCustomLabels = { bottomPanelLabels?: Partial<TextAreaBottomPanelLabels>; emojiDropdown?: Partial<TextAreaEmojiDropdownLabels>; }; type TextAreaBottomPanelLabels = { emoji: string; }; type TextAreaEmojiDropdownLabels = { categories: { activity: string; flags: string; foods: string; frequent: string; nature: string; objects: string; people: string; places: string; symbols: string; }; }; type BottomPanelBuiltinKey = 'emoji'; type BottomPanelBuiltinUtilConfig = { key: 'emoji'; dropdownProps?: Pick<React.ComponentProps<typeof Dropdown>, 'placement'>; }; type BottomPanelReactUtilElement = React.ReactElement<{ disabled?: boolean; }>; type BottomPanelUtilsItem = BottomPanelBuiltinKey | BottomPanelBuiltinUtilConfig | BottomPanelReactUtilElement; export type TextAreaProps = Omit<TextareaHTMLAttributes<HTMLTextAreaElement>, 'style' | 'size' | 'onResize'> & Pick<AntdTextAreaProps, 'autoSize'> & { value?: string; isSubmitDisabled?: boolean; showCount?: boolean; onSubmit?: (value: string) => void; bottomPanelUtils?: BottomPanelUtilsItem[]; customLabels?: TextAreaCustomLabels; }; declare const TextArea: React.ForwardRefExoticComponent<Omit<React.TextareaHTMLAttributes<HTMLTextAreaElement>, "size" | "style" | "onResize"> & Pick<AntdTextAreaProps, "autoSize"> & { value?: string; isSubmitDisabled?: boolean; showCount?: boolean; onSubmit?: (value: string) => void; bottomPanelUtils?: BottomPanelUtilsItem[]; customLabels?: TextAreaCustomLabels; } & React.RefAttributes<InputRef>>; export { TextArea }; //# sourceMappingURL=textArea.d.ts.map