@cloudtower/eagle 0.0.0-testid-rc-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/README.md +60 -0
- package/dist/UIKitProvider/UIKitProvider.stories.d.ts +7 -0
- package/dist/UIKitProvider/index.d.ts +17 -0
- package/dist/assets/55a976ab.woff2 +0 -0
- package/dist/assets/575908fb.woff2 +0 -0
- package/dist/assets/5d4275ee.woff +0 -0
- package/dist/assets/632c7446.woff2 +0 -0
- package/dist/assets/643e5041.woff +0 -0
- package/dist/assets/66e8de15.woff2 +0 -0
- package/dist/assets/cf89dd5b.woff +0 -0
- package/dist/assets/d11ea859.woff2 +0 -0
- package/dist/assets/d778f33f.woff +0 -0
- package/dist/assets/ed5714f7.woff2 +0 -0
- package/dist/components/Alert/Alert.stories.d.ts +11 -0
- package/dist/components/Alert/index.d.ts +3 -0
- package/dist/components/Arch/Arch.stories.d.ts +18 -0
- package/dist/components/Arch/index.d.ts +3 -0
- package/dist/components/Badge/index.d.ts +3 -0
- package/dist/components/BaseIcon/BaseIcon.stories.d.ts +4 -0
- package/dist/components/BaseIcon/index.d.ts +15 -0
- package/dist/components/Bit/Bit.stories.d.ts +17 -0
- package/dist/components/Bit/index.d.ts +3 -0
- package/dist/components/BitPerSecond/BitPerSecond.stories.d.ts +17 -0
- package/dist/components/BitPerSecond/index.d.ts +3 -0
- package/dist/components/Bps/Bps.stories.d.ts +17 -0
- package/dist/components/Bps/index.d.ts +3 -0
- package/dist/components/Button/Button.stories.d.ts +20 -0
- package/dist/components/Button/HoverableElement.d.ts +9 -0
- package/dist/components/Button/HoverableElement.stories.d.ts +3 -0
- package/dist/components/Button/index.d.ts +16 -0
- package/dist/components/ButtonGroup/index.d.ts +5 -0
- package/dist/components/Byte/Byte.stories.d.ts +17 -0
- package/dist/components/Byte/index.d.ts +3 -0
- package/dist/components/Card/Card.stories.d.ts +23 -0
- package/dist/components/Card/CardBody.d.ts +5 -0
- package/dist/components/Card/CardTitle.d.ts +5 -0
- package/dist/components/Card/CardWrapper.d.ts +10 -0
- package/dist/components/Card/__test__/Card.test.d.ts +1 -0
- package/dist/components/Card/index.d.ts +22 -0
- package/dist/components/Checkbox/__test__/h5_css.test.d.ts +1 -0
- package/dist/components/Checkbox/index.d.ts +8 -0
- package/dist/components/Empty/index.d.ts +7 -0
- package/dist/components/ErrorBoundary/index.d.ts +4 -0
- package/dist/components/ExpandableList/CustomHeader.stories.d.ts +4 -0
- package/dist/components/ExpandableList/ExpandIcon.d.ts +13 -0
- package/dist/components/ExpandableList/ExpandableContainer.d.ts +5 -0
- package/dist/components/ExpandableList/ExpandableItem.d.ts +9 -0
- package/dist/components/ExpandableList/ExpandableItem.stories.d.ts +10 -0
- package/dist/components/ExpandableList/ExpandableList.stories.d.ts +5 -0
- package/dist/components/ExpandableList/RoundOrder.d.ts +6 -0
- package/dist/components/ExpandableList/__test__/h5_css.test.d.ts +1 -0
- package/dist/components/FailedLoad/index.d.ts +9 -0
- package/dist/components/Fields/FieldsBoolean/FieldsBoolean.stories.d.ts +9 -0
- package/dist/components/Fields/FieldsBoolean/__test__/h5_css.test.d.ts +1 -0
- package/dist/components/Fields/FieldsBoolean/index.d.ts +4 -0
- package/dist/components/Fields/FieldsDateTime/index.d.ts +4 -0
- package/dist/components/Fields/FieldsDateTimeRange/FieldsDateTimeRange.stories.d.ts +5 -0
- package/dist/components/Fields/FieldsDateTimeRange/__test__/h5_css.test.d.ts +1 -0
- package/dist/components/Fields/FieldsDateTimeRange/index.d.ts +5 -0
- package/dist/components/Fields/FieldsEnum/FieldsEnum.stories.d.ts +7 -0
- package/dist/components/Fields/FieldsEnum/__test__/h5_css.test.d.ts +1 -0
- package/dist/components/Fields/FieldsEnum/index.d.ts +4 -0
- package/dist/components/Fields/FieldsFloat/__test__/h5_css.test.d.ts +1 -0
- package/dist/components/Fields/FieldsFloat/index.d.ts +4 -0
- package/dist/components/Fields/FieldsInt/__test__/h5_css.test.d.ts +1 -0
- package/dist/components/Fields/FieldsInt/index.d.ts +4 -0
- package/dist/components/Fields/FieldsInteger/FieldsInteger.stories.d.ts +7 -0
- package/dist/components/Fields/FieldsInteger/__test__/h5_css.test.d.ts +1 -0
- package/dist/components/Fields/FieldsInteger/index.d.ts +4 -0
- package/dist/components/Fields/FieldsString/FieldsString.stories.d.ts +17 -0
- package/dist/components/Fields/FieldsString/__test__/h5_css.test.d.ts +1 -0
- package/dist/components/Fields/FieldsString/index.d.ts +4 -0
- package/dist/components/Fields/FieldsTextArea/index.d.ts +5 -0
- package/dist/components/Fields/FieldsTimePicker/FieldsTimePicker.stories.d.ts +9 -0
- package/dist/components/Fields/FieldsTimePicker/__test__/h5_css.test.d.ts +1 -0
- package/dist/components/Fields/FieldsTimePicker/index.d.ts +5 -0
- package/dist/components/Fields/index.d.ts +26 -0
- package/dist/components/Form/index.d.ts +3 -0
- package/dist/components/FormItem/Form.stories.d.ts +3 -0
- package/dist/components/FormItem/index.d.ts +4 -0
- package/dist/components/Frequency/Frequency.stories.d.ts +17 -0
- package/dist/components/Frequency/index.d.ts +3 -0
- package/dist/components/I18nNameTag/I18nNameTag.stories.d.ts +13 -0
- package/dist/components/I18nNameTag/__test__/index.test.d.ts +1 -0
- package/dist/components/I18nNameTag/index.d.ts +10 -0
- package/dist/components/Icon/Icon.stories.d.ts +21 -0
- package/dist/components/Icon/index.d.ts +39 -0
- package/dist/components/Input/Input.simple.stories.d.ts +12 -0
- package/dist/components/Input/Input.stories.d.ts +28 -0
- package/dist/components/Input/__test__/h5_css.test.d.ts +1 -0
- package/dist/components/Input/index.d.ts +6 -0
- package/dist/components/InputGroup/__test__/h5_css.test.d.ts +1 -0
- package/dist/components/InputGroup/index.d.ts +3 -0
- package/dist/components/InputGroup/inputGroup.stories.d.ts +6 -0
- package/dist/components/InputInteger/__test__/unit.test.d.ts +1 -0
- package/dist/components/InputInteger/formatterInteger.d.ts +2 -0
- package/dist/components/InputInteger/index.d.ts +12 -0
- package/dist/components/InputNumber/index.d.ts +12 -0
- package/dist/components/InputTagItem/index.d.ts +5 -0
- package/dist/components/KitStoreProvider/index.d.ts +8 -0
- package/dist/components/Loading/Loading.stories.d.ts +12 -0
- package/dist/components/Loading/index.d.ts +3 -0
- package/dist/components/Loading/style.d.ts +4 -0
- package/dist/components/Metric/Metric.stories.d.ts +4 -0
- package/dist/components/Metric/MetricActions.d.ts +9 -0
- package/dist/components/Metric/MetricLegend.d.ts +16 -0
- package/dist/components/Metric/Pointer.d.ts +6 -0
- package/dist/components/Metric/RenderChart.d.ts +41 -0
- package/dist/components/Metric/TooltipFormatter.d.ts +10 -0
- package/dist/components/Metric/index.d.ts +29 -0
- package/dist/components/Metric/metric.d.ts +43 -0
- package/dist/components/Metric/mockMetric.d.ts +3 -0
- package/dist/components/Metric/mockMetric2.d.ts +3 -0
- package/dist/components/Metric/styled.d.ts +18 -0
- package/dist/components/Metric/type.d.ts +39 -0
- package/dist/components/Modal/Modal.stories.d.ts +16 -0
- package/dist/components/Modal/index.d.ts +4 -0
- package/dist/components/ModalStack/index.d.ts +3 -0
- package/dist/components/Overflow/index.d.ts +14 -0
- package/dist/components/OverflowTooltip/OverflowTooltip.stories.d.ts +17 -0
- package/dist/components/OverflowTooltip/index.d.ts +4 -0
- package/dist/components/Pagination/Pagination.stories.d.ts +6 -0
- package/dist/components/Pagination/index.d.ts +5 -0
- package/dist/components/Percent/Percent.stories.d.ts +32 -0
- package/dist/components/Percent/index.d.ts +3 -0
- package/dist/components/Progress/index.d.ts +3 -0
- package/dist/components/Radio/Radio.stories.d.ts +29 -0
- package/dist/components/Radio/RadioButton.stories.d.ts +8 -0
- package/dist/components/Radio/RadioGroup.stories.d.ts +23 -0
- package/dist/components/Radio/__test__/h5_css.test.d.ts +1 -0
- package/dist/components/Radio/index.d.ts +8 -0
- package/dist/components/SearchInput/SearchInput.stories.d.ts +14 -0
- package/dist/components/SearchInput/__test__/h5_css.test.d.ts +1 -0
- package/dist/components/SearchInput/index.d.ts +3 -0
- package/dist/components/Second/Second.stories.d.ts +22 -0
- package/dist/components/Second/index.d.ts +3 -0
- package/dist/components/Select/Select.Simple.stories.d.ts +10 -0
- package/dist/components/Select/Select.stories.d.ts +16 -0
- package/dist/components/Select/index.d.ts +3 -0
- package/dist/components/SimplePagination/SimplePagination.stories.d.ts +7 -0
- package/dist/components/SimplePagination/__test__/h5_css.test.d.ts +1 -0
- package/dist/components/SimplePagination/index.d.ts +4 -0
- package/dist/components/Space/Space.stories.d.ts +8 -0
- package/dist/components/Space/index.d.ts +1 -0
- package/dist/components/Speed/Speed.stories.d.ts +17 -0
- package/dist/components/Speed/index.d.ts +3 -0
- package/dist/components/StatusCapsule/StatusCapsule.stories.d.ts +12 -0
- package/dist/components/StatusCapsule/__test__/h5_css.test.d.ts +1 -0
- package/dist/components/StatusCapsule/index.d.ts +8 -0
- package/dist/components/Steps/Steps.stories.d.ts +8 -0
- package/dist/components/Steps/index.d.ts +4 -0
- package/dist/components/Steps/style.d.ts +5 -0
- package/dist/components/Styled/index.d.ts +78 -0
- package/dist/components/Switch/Switch.stories.d.ts +17 -0
- package/dist/components/Switch/index.d.ts +4 -0
- package/dist/components/Table/Table.stories.d.ts +16 -0
- package/dist/components/Table/TableWidget.d.ts +10 -0
- package/dist/components/Table/__test__/h5_css.test.d.ts +1 -0
- package/dist/components/Table/common.d.ts +2 -0
- package/dist/components/Table/index.d.ts +9 -0
- package/dist/components/TableForm/AddRowButton.d.ts +4 -0
- package/dist/components/TableForm/Columns/AffixColumn.d.ts +6 -0
- package/dist/components/TableForm/Columns/CheckboxColumn.d.ts +8 -0
- package/dist/components/TableForm/Columns/FormItem.d.ts +7 -0
- package/dist/components/TableForm/Columns/InputColumn.d.ts +11 -0
- package/dist/components/TableForm/Columns/TextColumn.d.ts +4 -0
- package/dist/components/TableForm/Columns/index.d.ts +40 -0
- package/dist/components/TableForm/TableForm.stories.d.ts +17 -0
- package/dist/components/TableForm/TableFormBodyCell.d.ts +3 -0
- package/dist/components/TableForm/TableFormBodyRows.d.ts +4 -0
- package/dist/components/TableForm/TableFormHeaderCell.d.ts +3 -0
- package/dist/components/TableForm/__test__/tableForm.test.d.ts +1 -0
- package/dist/components/TableForm/__test__/utils.test.d.ts +1 -0
- package/dist/components/TableForm/const.d.ts +9 -0
- package/dist/components/TableForm/index.d.ts +4 -0
- package/dist/components/TableForm/style.d.ts +17 -0
- package/dist/components/TableForm/types.d.ts +166 -0
- package/dist/components/TableForm/utils.d.ts +4 -0
- package/dist/components/Tag/SplitTag.d.ts +3 -0
- package/dist/components/Tag/Tag.stories.d.ts +29 -0
- package/dist/components/Tag/__test__/h5_css.test.d.ts +1 -0
- package/dist/components/Tag/const.d.ts +1 -0
- package/dist/components/Tag/index.d.ts +4 -0
- package/dist/components/Tag/style.d.ts +4 -0
- package/dist/components/TextArea/index.d.ts +4 -0
- package/dist/components/Time/__test__/h5_css.test.d.ts +1 -0
- package/dist/components/Time/index.d.ts +4 -0
- package/dist/components/Time/time.stories.d.ts +6 -0
- package/dist/components/TimePicker/index.d.ts +6 -0
- package/dist/components/TimeZoneSelect/TimeZoneSelect.stories.d.ts +17 -0
- package/dist/components/TimeZoneSelect/index.d.ts +4 -0
- package/dist/components/Token/Token.stories.d.ts +24 -0
- package/dist/components/Token/__test__/h5_css.test.d.ts +1 -0
- package/dist/components/Token/index.d.ts +12 -0
- package/dist/components/Token/style.d.ts +1 -0
- package/dist/components/Tooltip/Tooltip.stories.d.ts +6 -0
- package/dist/components/Tooltip/index.d.ts +4 -0
- package/dist/components/Truncate/Truncate.stories.d.ts +8 -0
- package/dist/components/Truncate/index.d.ts +12 -0
- package/dist/components/Typo/index.d.ts +70 -0
- package/dist/components/antd.d.ts +3 -0
- package/dist/components/index.d.ts +31 -0
- package/dist/components/message/__tests__/index.test.d.ts +1 -0
- package/dist/components/message/index.d.ts +52 -0
- package/dist/components/message/style/index.d.ts +2 -0
- package/dist/components/message-group/__test__/message-group.test.d.ts +1 -0
- package/dist/components/message-group/index.d.ts +27 -0
- package/dist/components/message-group/message-group.stories.d.ts +17 -0
- package/dist/components.css +32929 -0
- package/dist/core/AccordionCard/AccordionCard.stories.d.ts +7 -0
- package/dist/core/AccordionCard/index.d.ts +16 -0
- package/dist/core/Breadcrumb/Breadcrumb.stories.d.ts +6 -0
- package/dist/core/Breadcrumb/index.d.ts +7 -0
- package/dist/core/DetailCard/DetailCard.stories.d.ts +7 -0
- package/dist/core/DetailCard/index.d.ts +4 -0
- package/dist/core/ParrotTrans/index.d.ts +4 -0
- package/dist/core/StepProgress/StepProgress.stories.d.ts +8 -0
- package/dist/core/StepProgress/index.d.ts +3 -0
- package/dist/coreX/Counting/Counting.stories.d.ts +29 -0
- package/dist/coreX/Counting/index.d.ts +4 -0
- package/dist/coreX/DropdownTransition/index.d.ts +6 -0
- package/dist/coreX/TruncatedTextWithTooltip/TruncatedTextWithTooltip.stories.d.ts +7 -0
- package/dist/coreX/TruncatedTextWithTooltip/index.d.ts +10 -0
- package/dist/esm/index.js +6296 -0
- package/dist/esm/stats1.html +6177 -0
- package/dist/font.css +98 -0
- package/dist/hooks/index.d.ts +2 -0
- package/dist/hooks/useElementResize.d.ts +2 -0
- package/dist/hooks/useElementsSize.d.ts +8 -0
- package/dist/hooks/useParrotTranslation.d.ts +2 -0
- package/dist/index.d.ts +36 -0
- package/dist/spec/base.d.ts +601 -0
- package/dist/spec/index.d.ts +2 -0
- package/dist/spec/react-final-form.d.ts +46 -0
- package/dist/spec/type.d.ts +70 -0
- package/dist/store/chart.d.ts +40 -0
- package/dist/store/index.d.ts +25 -0
- package/dist/store/modal.d.ts +50 -0
- package/dist/stories/Stack.d.ts +12 -0
- package/dist/stories/Story.d.ts +5 -0
- package/dist/stories/changeLng.stories.d.ts +8 -0
- package/dist/stories/icons-react.stories.d.ts +3 -0
- package/dist/stories/index.d.ts +2 -0
- package/dist/stories/menu.stories.d.ts +17 -0
- package/dist/style.css +33016 -0
- package/dist/umd/index.js +6347 -0
- package/dist/umd/stats1.html +6177 -0
- package/dist/utils/__test__/tower.test.d.ts +1 -0
- package/dist/utils/constants.d.ts +5 -0
- package/dist/utils/dom.d.ts +6 -0
- package/dist/utils/formatValue.d.ts +2 -0
- package/dist/utils/icon.d.ts +2 -0
- package/dist/utils/index.d.ts +4 -0
- package/dist/utils/isEmpty.d.ts +2 -0
- package/dist/utils/testSuit.d.ts +2 -0
- package/dist/utils/tower.d.ts +65 -0
- package/dist/variables.scss +536 -0
- package/package.json +110 -0
|
@@ -0,0 +1,601 @@
|
|
|
1
|
+
import { StyledMeta } from "@linaria/react";
|
|
2
|
+
import { SizeType } from "antd/es/config-provider/SizeContext";
|
|
3
|
+
import { AlertProps } from "antd/lib/alert";
|
|
4
|
+
import { AutoCompleteProps } from "antd/lib/auto-complete";
|
|
5
|
+
import { BadgeProps } from "antd/lib/badge";
|
|
6
|
+
import { ButtonProps as AntdButtonProps, ButtonType } from "antd/lib/button";
|
|
7
|
+
import { CalendarProps } from "antd/lib/calendar/generateCalendar";
|
|
8
|
+
import { CascaderProps } from "antd/lib/cascader";
|
|
9
|
+
import { CheckboxGroupProps, CheckboxProps } from "antd/lib/checkbox";
|
|
10
|
+
import { ColProps } from "antd/lib/col";
|
|
11
|
+
import { CollapsePanelProps, CollapseProps } from "antd/lib/collapse";
|
|
12
|
+
import { DatePickerProps, RangePickerProps } from "antd/lib/date-picker";
|
|
13
|
+
import { DividerProps as AntdDividerProps } from "antd/lib/divider";
|
|
14
|
+
import { DrawerProps } from "antd/lib/drawer";
|
|
15
|
+
import { DropDownProps } from "antd/lib/dropdown";
|
|
16
|
+
import { EmptyProps } from "antd/lib/empty";
|
|
17
|
+
import type Form from "antd/lib/form";
|
|
18
|
+
import type Input from "antd/lib/input";
|
|
19
|
+
import { GroupProps, InputProps } from "antd/lib/input";
|
|
20
|
+
import { TextAreaProps as AntdTextAreaProps } from "antd/lib/input/TextArea";
|
|
21
|
+
import { InputNumberProps } from "antd/lib/input-number";
|
|
22
|
+
import { SiderProps } from "antd/lib/layout";
|
|
23
|
+
import { BasicProps } from "antd/lib/layout/layout";
|
|
24
|
+
import { ListProps } from "antd/lib/list";
|
|
25
|
+
import { ListItemProps } from "antd/lib/list/Item";
|
|
26
|
+
import { MenuItemGroupProps, MenuProps } from "antd/lib/menu";
|
|
27
|
+
import { MenuItemProps } from "antd/lib/menu/MenuItem";
|
|
28
|
+
import { SubMenuProps } from "antd/lib/menu/SubMenu";
|
|
29
|
+
import { ModalProps as AntdModalProps } from "antd/lib/modal";
|
|
30
|
+
import { PopoverProps } from "antd/lib/popover";
|
|
31
|
+
import { ProgressProps } from "antd/lib/progress";
|
|
32
|
+
import { RadioGroupProps as AntdRadioGroupProps, RadioProps as AntdRadioProps } from "antd/lib/radio";
|
|
33
|
+
import { RadioButtonProps as AntdRadioButtonProps } from "antd/lib/radio/radioButton";
|
|
34
|
+
import { RowProps } from "antd/lib/row";
|
|
35
|
+
import { SelectProps as AntdSelectProps, SelectProps } from "antd/lib/select";
|
|
36
|
+
import { SkeletonProps as AntdSkeletonProps } from "antd/lib/skeleton";
|
|
37
|
+
import { SkeletonButtonProps } from "antd/lib/skeleton/Button";
|
|
38
|
+
import Steps from "antd/lib/steps";
|
|
39
|
+
import { SwitchProps as AntdSwitchProps } from "antd/lib/switch";
|
|
40
|
+
import { ColumnsType, ColumnType, TableProps as AntdTableProps } from "antd/lib/table";
|
|
41
|
+
import { TableRowSelection } from "antd/lib/table/interface";
|
|
42
|
+
import { TabPaneProps, TabsProps } from "antd/lib/tabs";
|
|
43
|
+
import { TagProps } from "antd/lib/tag";
|
|
44
|
+
import { TimePickerProps } from "antd/lib/time-picker";
|
|
45
|
+
import { TimeLineItemProps, TimelineProps } from "antd/lib/timeline";
|
|
46
|
+
import { TooltipProps as AntdTooltipProps } from "antd/lib/tooltip";
|
|
47
|
+
import { TreeProps as AntdTreeProps } from "antd/lib/tree";
|
|
48
|
+
import type TreeSelect from "antd/lib/tree-select";
|
|
49
|
+
import { TextProps } from "antd/lib/typography/Text";
|
|
50
|
+
import { DraggerProps, UploadProps } from "antd/lib/upload";
|
|
51
|
+
import type { Moment } from "moment";
|
|
52
|
+
import React, { ForwardRefExoticComponent, PropsWithChildren, PropsWithoutRef, ReactNode, RefAttributes } from "react";
|
|
53
|
+
import { CardProps } from "../components/Card";
|
|
54
|
+
import { IEmptyProps } from "../components/Empty";
|
|
55
|
+
import { MessageApi } from "../components/message";
|
|
56
|
+
import { TableFormHandle, TableFormProps } from "../components/TableForm/types";
|
|
57
|
+
import { TruncatePropTypes } from "../components/Truncate";
|
|
58
|
+
import type { CloseButtonProps } from "../core/AccordionCard";
|
|
59
|
+
import { SerializableObject } from "../utils/tower";
|
|
60
|
+
import { FieldRenderProps } from "./react-final-form";
|
|
61
|
+
import { Architecture, DropdownTransitionProps, IAccordionCardProps, IBreadcrumbProps, ICircleProgressProps, ICountingProps, IDetailCardProps, ISpaceProps, ITimeProps, ITimeZoneSelectProps } from "./type";
|
|
62
|
+
export type AntdTableComponentType = <RecordType extends object = any>(props: AntdTableProps<RecordType>) => JSX.Element;
|
|
63
|
+
export type AntdTreeSelectComponentType<T> = TreeSelect<T>;
|
|
64
|
+
interface EmptyType extends React.FC<EmptyProps> {
|
|
65
|
+
PRESENTED_IMAGE_DEFAULT: React.ReactNode;
|
|
66
|
+
PRESENTED_IMAGE_SIMPLE: React.ReactNode;
|
|
67
|
+
}
|
|
68
|
+
export interface CollapseInterface extends React.FC<CollapseProps> {
|
|
69
|
+
Panel: React.FC<CollapsePanelProps>;
|
|
70
|
+
}
|
|
71
|
+
type BadgeTypeProps = "warning" | "error" | "info";
|
|
72
|
+
type Primitive = "Int" | "Float" | "DateTime" | "Enum" | "String" | "Boolean";
|
|
73
|
+
export type Child = {
|
|
74
|
+
type: Exclude<Primitive, "Enum">;
|
|
75
|
+
} | {
|
|
76
|
+
type: "Enum";
|
|
77
|
+
enumValues: readonly string[];
|
|
78
|
+
};
|
|
79
|
+
interface IdObject {
|
|
80
|
+
id: string;
|
|
81
|
+
}
|
|
82
|
+
interface LooseFieldRenderProps<V, T extends HTMLElement> {
|
|
83
|
+
input: {
|
|
84
|
+
name?: FieldRenderProps<V, T>["input"]["name"];
|
|
85
|
+
value?: FieldRenderProps<V, T>["input"]["value"];
|
|
86
|
+
onBlur?: FieldRenderProps<V, T>["input"]["onBlur"];
|
|
87
|
+
onChange?: (value: string | string[], option: {
|
|
88
|
+
object: V;
|
|
89
|
+
} | Array<{
|
|
90
|
+
object: V;
|
|
91
|
+
}>) => void;
|
|
92
|
+
onFocus?: FieldRenderProps<V, T>["input"]["onFocus"];
|
|
93
|
+
type?: FieldRenderProps<V, T>["input"]["type"];
|
|
94
|
+
checked?: FieldRenderProps<V, T>["input"]["checked"];
|
|
95
|
+
multiple?: FieldRenderProps<V, T>["input"]["multiple"];
|
|
96
|
+
};
|
|
97
|
+
meta?: FieldRenderProps<V, T>["meta"];
|
|
98
|
+
focusIndicator?: boolean;
|
|
99
|
+
}
|
|
100
|
+
export interface PaginationProps {
|
|
101
|
+
current: number;
|
|
102
|
+
count: number;
|
|
103
|
+
size: number;
|
|
104
|
+
onChange: (page: number) => void;
|
|
105
|
+
onSizeChange?: (size: number) => void;
|
|
106
|
+
simple?: boolean;
|
|
107
|
+
showTotal?: (total: number, range: [number, number]) => string;
|
|
108
|
+
selectorVisible?: boolean;
|
|
109
|
+
className?: string;
|
|
110
|
+
}
|
|
111
|
+
export type InputSize = "large" | "middle" | "small";
|
|
112
|
+
export type KitSelectProps = {
|
|
113
|
+
defaultValue?: string;
|
|
114
|
+
error?: unknown | React.ReactNode;
|
|
115
|
+
danger?: boolean;
|
|
116
|
+
multiple?: boolean;
|
|
117
|
+
scrollBottomBuffer?: number;
|
|
118
|
+
onScrollBottom?: () => void;
|
|
119
|
+
selectLimit?: number;
|
|
120
|
+
} & AntdSelectProps<string>;
|
|
121
|
+
interface OptionProps {
|
|
122
|
+
value: React.ReactText;
|
|
123
|
+
disabled?: boolean;
|
|
124
|
+
key?: string;
|
|
125
|
+
hidden?: boolean;
|
|
126
|
+
label?: string;
|
|
127
|
+
className?: string;
|
|
128
|
+
object?: SerializableObject;
|
|
129
|
+
title?: string;
|
|
130
|
+
}
|
|
131
|
+
export interface RawValue {
|
|
132
|
+
rawValue?: number | null;
|
|
133
|
+
decimals?: number;
|
|
134
|
+
noUnitOnZero?: boolean;
|
|
135
|
+
abbreviate?: boolean;
|
|
136
|
+
valueClassName?: string;
|
|
137
|
+
unitClassName?: string;
|
|
138
|
+
}
|
|
139
|
+
export type UnitFn = React.FC<RawValue & {
|
|
140
|
+
emptyProps?: IEmptyProps;
|
|
141
|
+
}>;
|
|
142
|
+
export type PercentFn = React.FC<RawValue & {
|
|
143
|
+
saturated?: boolean;
|
|
144
|
+
emptyProps?: IEmptyProps;
|
|
145
|
+
}>;
|
|
146
|
+
export type SorterOrder = "descend" | "ascend" | undefined;
|
|
147
|
+
type Columns<T> = ColumnsType<T>[0];
|
|
148
|
+
export interface RequiredColumnProps<T> extends Omit<Columns<T>, "onHeaderCell" | "onCell" | "title"> {
|
|
149
|
+
key: Exclude<Columns<T>["key"], undefined | number>;
|
|
150
|
+
dataIndex: Exclude<ColumnType<T>["dataIndex"], undefined>;
|
|
151
|
+
sortable?: boolean;
|
|
152
|
+
width?: number | string;
|
|
153
|
+
onHeaderCell?: (column: ColumnType<T>) => any;
|
|
154
|
+
onCell?: (column: T) => any;
|
|
155
|
+
/**
|
|
156
|
+
* removed params for title function
|
|
157
|
+
* because we need to cast the function in customize column
|
|
158
|
+
* which cannot access the header params
|
|
159
|
+
*/
|
|
160
|
+
title: React.ReactNode | (() => React.ReactNode);
|
|
161
|
+
customizable?: boolean;
|
|
162
|
+
}
|
|
163
|
+
export type TableScroll = string | number | boolean;
|
|
164
|
+
export interface TableProps<T extends {
|
|
165
|
+
id: string;
|
|
166
|
+
}> {
|
|
167
|
+
bordered?: boolean;
|
|
168
|
+
loading?: boolean;
|
|
169
|
+
error?: React.ReactNode | string;
|
|
170
|
+
dataSource: T[] | undefined;
|
|
171
|
+
columns: RequiredColumnProps<T>[];
|
|
172
|
+
onSorterChange?: (order: SorterOrder | null, key?: string | number) => void;
|
|
173
|
+
onRowClick?: (record: T, index: number, evt: React.MouseEvent<HTMLElement, MouseEvent>) => void;
|
|
174
|
+
rowClassName?: (record: T, index: number) => string;
|
|
175
|
+
scroll?: {
|
|
176
|
+
x?: number | string | true;
|
|
177
|
+
y?: number | string;
|
|
178
|
+
};
|
|
179
|
+
onResize?: (column: RequiredColumnProps<T>[]) => void;
|
|
180
|
+
resizable?: boolean;
|
|
181
|
+
components?: {
|
|
182
|
+
table?: (props: any) => any;
|
|
183
|
+
header?: {
|
|
184
|
+
wrapper?: (props: any) => any;
|
|
185
|
+
row?: (props: any) => any;
|
|
186
|
+
cell?: (props: any) => any;
|
|
187
|
+
};
|
|
188
|
+
body?: {
|
|
189
|
+
wrapper?: (props: any) => any;
|
|
190
|
+
row?: (props: any) => any;
|
|
191
|
+
cell?: (props: any) => any;
|
|
192
|
+
};
|
|
193
|
+
};
|
|
194
|
+
RowMenu?: React.FC<{
|
|
195
|
+
record: T;
|
|
196
|
+
index: number;
|
|
197
|
+
}>;
|
|
198
|
+
rowSelection?: TableRowSelection<T>;
|
|
199
|
+
empty?: string | React.ReactNode;
|
|
200
|
+
tableLayout?: "fixed" | "auto";
|
|
201
|
+
initLoading?: boolean;
|
|
202
|
+
rowKey?: AntdTableProps<T>["rowKey"];
|
|
203
|
+
wrapper?: React.MutableRefObject<HTMLDivElement | null>;
|
|
204
|
+
pagination?: {
|
|
205
|
+
current: number;
|
|
206
|
+
pageSize: number;
|
|
207
|
+
};
|
|
208
|
+
onRow?: AntdTableProps<T>["onRow"];
|
|
209
|
+
}
|
|
210
|
+
interface TableComponent {
|
|
211
|
+
<TData extends IdObject>(props: React.PropsWithChildren<TableProps<TData>>, context?: unknown): React.ReactElement | null;
|
|
212
|
+
}
|
|
213
|
+
export interface BaseEnumProps {
|
|
214
|
+
enumValues: readonly (string | {
|
|
215
|
+
value: string;
|
|
216
|
+
text: string;
|
|
217
|
+
})[];
|
|
218
|
+
placeholder?: string;
|
|
219
|
+
emptyLabel?: string;
|
|
220
|
+
size?: InputSize;
|
|
221
|
+
defaultValue?: string;
|
|
222
|
+
multiple?: boolean;
|
|
223
|
+
}
|
|
224
|
+
export interface TextAreaProps extends AntdTextAreaProps {
|
|
225
|
+
error?: boolean;
|
|
226
|
+
size?: "large" | "middle" | "small";
|
|
227
|
+
autoSize?: AntdTextAreaProps["autoSize"];
|
|
228
|
+
onFocusChangeHeight?: {
|
|
229
|
+
onFocus: number;
|
|
230
|
+
onBlur: number;
|
|
231
|
+
};
|
|
232
|
+
}
|
|
233
|
+
export interface StringProps {
|
|
234
|
+
placeholder?: string;
|
|
235
|
+
autoComplete?: "on" | "off" | "new-password";
|
|
236
|
+
prefix?: React.ReactNode;
|
|
237
|
+
suffix?: React.ReactNode;
|
|
238
|
+
className?: string;
|
|
239
|
+
size?: InputSize;
|
|
240
|
+
allowClear?: boolean;
|
|
241
|
+
tags?: string[];
|
|
242
|
+
tagsOverflow?: React.ReactNode;
|
|
243
|
+
onTagsAllowClearClick?: (e: React.MouseEvent) => void;
|
|
244
|
+
onClick?: (e: React.MouseEvent) => void;
|
|
245
|
+
maxLength?: number;
|
|
246
|
+
disabled?: boolean;
|
|
247
|
+
}
|
|
248
|
+
export interface IntProps {
|
|
249
|
+
placeholder?: string;
|
|
250
|
+
suffix?: string;
|
|
251
|
+
size?: InputSize;
|
|
252
|
+
onBlur?: (input: FieldBaseProps<number, HTMLInputElement>["input"], event?: React.FocusEvent<HTMLInputElement>) => void;
|
|
253
|
+
}
|
|
254
|
+
export interface FloatProps {
|
|
255
|
+
placeholder?: string;
|
|
256
|
+
suffix?: string;
|
|
257
|
+
size?: InputSize;
|
|
258
|
+
onBlur?: (input: FieldBaseProps<number, HTMLInputElement>["input"], event?: React.FocusEvent<HTMLInputElement>) => void;
|
|
259
|
+
}
|
|
260
|
+
export type TooltipProps = AntdTooltipProps & {
|
|
261
|
+
followMouse?: boolean;
|
|
262
|
+
};
|
|
263
|
+
export type FieldBaseProps<V = any, T extends HTMLElement = HTMLElement> = FieldRenderProps<V, T> & {
|
|
264
|
+
disabled?: boolean;
|
|
265
|
+
className?: string;
|
|
266
|
+
};
|
|
267
|
+
export type WizardSteps = {
|
|
268
|
+
title: string;
|
|
269
|
+
render: React.ReactNode;
|
|
270
|
+
prevText?: string | React.ReactNode;
|
|
271
|
+
okText?: string | React.ReactNode;
|
|
272
|
+
onOk?: (e: React.MouseEvent<HTMLElement>) => void;
|
|
273
|
+
disabled?: boolean;
|
|
274
|
+
}[];
|
|
275
|
+
export type ModalProps = Omit<AntdModalProps, "okType"> & {
|
|
276
|
+
confirmLoading?: boolean;
|
|
277
|
+
fullscreen?: boolean;
|
|
278
|
+
error?: string | React.ReactNode;
|
|
279
|
+
normal?: boolean;
|
|
280
|
+
children?: React.ReactNode;
|
|
281
|
+
showCancel?: boolean;
|
|
282
|
+
showOk?: boolean;
|
|
283
|
+
wizard?: {
|
|
284
|
+
step: number;
|
|
285
|
+
onStepChange?: (step: number) => void;
|
|
286
|
+
steps: WizardSteps;
|
|
287
|
+
hideLeft?: boolean;
|
|
288
|
+
right?: React.ReactNode;
|
|
289
|
+
destroyOtherStep?: boolean;
|
|
290
|
+
disablePrevStep?: boolean;
|
|
291
|
+
} | boolean;
|
|
292
|
+
};
|
|
293
|
+
type SearchInputProps = Omit<InputProps, "onChange"> & {
|
|
294
|
+
onChange: (value: string) => void;
|
|
295
|
+
debounceWait?: number;
|
|
296
|
+
};
|
|
297
|
+
export type DateTimeRangeProps = DatePickerProps;
|
|
298
|
+
export type IntFieldProps<V = any, T extends HTMLElement = HTMLElement> = FieldBaseProps<V, T> & IntProps & {
|
|
299
|
+
onChange?: FieldBaseProps<V, T>["input"]["onChange"];
|
|
300
|
+
autoComplete?: "on" | "off";
|
|
301
|
+
maximum?: number;
|
|
302
|
+
minimum?: number;
|
|
303
|
+
supportNegativeValue?: boolean;
|
|
304
|
+
};
|
|
305
|
+
export type ButtonGroupType = {
|
|
306
|
+
className?: string;
|
|
307
|
+
size?: SizeType;
|
|
308
|
+
options: Array<Omit<ButtonProps, "shape" | "size" | "icon"> & {
|
|
309
|
+
key: string;
|
|
310
|
+
title?: string;
|
|
311
|
+
hideTitle?: boolean;
|
|
312
|
+
icon?: JSX.Element;
|
|
313
|
+
}>;
|
|
314
|
+
};
|
|
315
|
+
export type IntegerFieldProps<V = any, T extends HTMLElement = HTMLElement> = FieldBaseProps<V, T> & InputNumberProps & {
|
|
316
|
+
onChange?: FieldBaseProps<V, T>["input"]["onChange"];
|
|
317
|
+
controls?: boolean;
|
|
318
|
+
suffix?: string;
|
|
319
|
+
prefix?: string;
|
|
320
|
+
size?: InputSize;
|
|
321
|
+
onBlur?: (input: FieldBaseProps<number, HTMLInputElement>["input"], event?: React.FocusEvent<HTMLInputElement>) => void;
|
|
322
|
+
};
|
|
323
|
+
export type FloatFieldProps<V = any, T extends HTMLElement = HTMLElement> = FieldBaseProps<V, T> & FloatProps & {
|
|
324
|
+
onChange?: FieldBaseProps<V, T>["input"]["onChange"];
|
|
325
|
+
autoComplete?: "on" | "off";
|
|
326
|
+
};
|
|
327
|
+
export type ButtonProps = {
|
|
328
|
+
prefixIcon?: JSX.Element;
|
|
329
|
+
hoverPrefixIcon?: JSX.Element;
|
|
330
|
+
suffixIcon?: JSX.Element;
|
|
331
|
+
hoverSuffixIcon?: JSX.Element;
|
|
332
|
+
type?: ButtonType | "secondary" | "tertiary" | "ordinary" | "ordinary-onTint" | "quiet";
|
|
333
|
+
} & Omit<AntdButtonProps, "type" | "icon">;
|
|
334
|
+
export type SwitchProps = Omit<AntdSwitchProps, "size"> & {
|
|
335
|
+
size?: "small" | "default" | "large";
|
|
336
|
+
};
|
|
337
|
+
export type RadioProps = AntdRadioProps & {
|
|
338
|
+
description?: React.ReactNode;
|
|
339
|
+
compact?: boolean;
|
|
340
|
+
};
|
|
341
|
+
export type RadioButtonProps = AntdRadioButtonProps & {
|
|
342
|
+
type?: "input" | "input-number";
|
|
343
|
+
min?: number;
|
|
344
|
+
max?: number;
|
|
345
|
+
precision?: number;
|
|
346
|
+
placeholder?: string;
|
|
347
|
+
initialValue?: string | number;
|
|
348
|
+
onInputChange?: (val: number | string | undefined) => void;
|
|
349
|
+
};
|
|
350
|
+
export type StepProps = {
|
|
351
|
+
className?: string;
|
|
352
|
+
onClick?: React.MouseEventHandler<HTMLElement>;
|
|
353
|
+
title: string;
|
|
354
|
+
style?: React.CSSProperties;
|
|
355
|
+
};
|
|
356
|
+
export type IStepsProps = {
|
|
357
|
+
className?: string;
|
|
358
|
+
current?: number;
|
|
359
|
+
direction?: "horizontal" | "vertical";
|
|
360
|
+
style?: React.CSSProperties;
|
|
361
|
+
onChange?: (current: number) => void;
|
|
362
|
+
stepsConfig: Array<StepProps>;
|
|
363
|
+
containerClassname?: string;
|
|
364
|
+
disabled?: boolean;
|
|
365
|
+
};
|
|
366
|
+
export interface ISimplePaginationProps {
|
|
367
|
+
className?: string;
|
|
368
|
+
current: number;
|
|
369
|
+
count: number;
|
|
370
|
+
size: number;
|
|
371
|
+
onPageChange?: (page: number) => void;
|
|
372
|
+
}
|
|
373
|
+
export type AntdInputComponentType = Input;
|
|
374
|
+
export interface IExpandableItemProps {
|
|
375
|
+
header?: React.ReactNode;
|
|
376
|
+
order?: number;
|
|
377
|
+
disableExpand?: boolean;
|
|
378
|
+
defaultActive?: boolean;
|
|
379
|
+
}
|
|
380
|
+
export interface Kit<V = any, T extends HTMLElement = HTMLElement> {
|
|
381
|
+
loading: LoadingComponentType;
|
|
382
|
+
error: React.FunctionComponent<{
|
|
383
|
+
error: unknown;
|
|
384
|
+
}>;
|
|
385
|
+
pagination: React.FC<PaginationProps>;
|
|
386
|
+
select: SelectComponentType<V, T>;
|
|
387
|
+
option: OptionComponentType;
|
|
388
|
+
selectOptGroup: import("rc-select/lib/OptGroup").OptionGroupFC;
|
|
389
|
+
table: TableComponent;
|
|
390
|
+
button: React.FC<ButtonProps>;
|
|
391
|
+
modal: React.FC<ModalProps>;
|
|
392
|
+
dropdown: React.FC<DropDownProps>;
|
|
393
|
+
switch: React.FC<SwitchProps>;
|
|
394
|
+
tooltip: React.FC<TooltipProps>;
|
|
395
|
+
input: React.FC<InputProps & {
|
|
396
|
+
error?: boolean;
|
|
397
|
+
}>;
|
|
398
|
+
textArea: React.FC<TextAreaProps>;
|
|
399
|
+
checkbox: React.FC<CheckboxProps & {
|
|
400
|
+
description?: ReactNode;
|
|
401
|
+
compact?: boolean;
|
|
402
|
+
}>;
|
|
403
|
+
fields: {
|
|
404
|
+
Int: React.FunctionComponent<IntFieldProps<V, T>>;
|
|
405
|
+
Integer: React.FunctionComponent<IntegerFieldProps<V, T>>;
|
|
406
|
+
Float: React.FunctionComponent<FloatFieldProps<V, T>>;
|
|
407
|
+
DateTime: React.FunctionComponent<FieldBaseProps<V, T>>;
|
|
408
|
+
Enum: React.FunctionComponent<{
|
|
409
|
+
input: Partial<FieldRenderProps<V, T>["input"]>;
|
|
410
|
+
meta: FieldRenderProps<V, T>["meta"];
|
|
411
|
+
disabled?: boolean;
|
|
412
|
+
className?: string;
|
|
413
|
+
dropdownClassName?: string;
|
|
414
|
+
} & BaseEnumProps>;
|
|
415
|
+
String: React.FunctionComponent<FieldBaseProps<V, T> & StringProps>;
|
|
416
|
+
Boolean: React.FunctionComponent<FieldBaseProps<V, T>>;
|
|
417
|
+
TextArea: React.FC<FieldBaseProps<V, T> & TextAreaProps>;
|
|
418
|
+
DateTimeRange: React.FunctionComponent<FieldBaseProps<V, T> & DatePickerProps>;
|
|
419
|
+
TimePicker: React.FunctionComponent<FieldBaseProps<V, T> & TimePickerProps>;
|
|
420
|
+
};
|
|
421
|
+
units: {
|
|
422
|
+
Percent: PercentFn;
|
|
423
|
+
Byte: UnitFn;
|
|
424
|
+
Frequency: UnitFn;
|
|
425
|
+
Speed: UnitFn;
|
|
426
|
+
Second: UnitFn;
|
|
427
|
+
Bps: UnitFn;
|
|
428
|
+
BitPerSecond: UnitFn;
|
|
429
|
+
Bit: UnitFn;
|
|
430
|
+
};
|
|
431
|
+
inputGroup: InputGroupComponentType;
|
|
432
|
+
Empty: React.ReactElement | null;
|
|
433
|
+
alert: AlertComponentType;
|
|
434
|
+
searchInput: React.FC<SearchInputProps>;
|
|
435
|
+
badge: BadgeComponentType;
|
|
436
|
+
radio: React.FC<RadioProps>;
|
|
437
|
+
radioGroup: React.FC<AntdRadioGroupProps>;
|
|
438
|
+
radioButton: React.FC<RadioButtonProps>;
|
|
439
|
+
tree: React.FC<AntdTreeProps>;
|
|
440
|
+
progress: ProgressComponentType;
|
|
441
|
+
divider: React.FC<AntdDividerProps>;
|
|
442
|
+
skeleton: React.FC<AntdSkeletonProps>;
|
|
443
|
+
skeletonButton: {
|
|
444
|
+
(props: SkeletonButtonProps): JSX.Element;
|
|
445
|
+
defaultProps: {
|
|
446
|
+
size: string;
|
|
447
|
+
};
|
|
448
|
+
};
|
|
449
|
+
menu: React.ComponentType<MenuProps> & {
|
|
450
|
+
Divider: React.FC<import("rc-menu/lib/Divider").DividerProps>;
|
|
451
|
+
Item: React.ComponentType<MenuItemProps>;
|
|
452
|
+
SubMenu: React.ComponentType<SubMenuProps>;
|
|
453
|
+
ItemGroup: React.ComponentType<MenuItemGroupProps>;
|
|
454
|
+
};
|
|
455
|
+
menuItem: React.ComponentType<MenuItemProps>;
|
|
456
|
+
menuItemGroup: React.ComponentType<MenuItemGroupProps>;
|
|
457
|
+
list: <T>(props: ListProps<T>) => JSX.Element;
|
|
458
|
+
listItem: React.FC<ListItemProps>;
|
|
459
|
+
layout: React.ComponentType<BasicProps> & {
|
|
460
|
+
Header: React.ComponentType<BasicProps>;
|
|
461
|
+
Footer: React.ComponentType<BasicProps>;
|
|
462
|
+
Content: React.ComponentType<BasicProps>;
|
|
463
|
+
Sider: React.ComponentType<SiderProps>;
|
|
464
|
+
};
|
|
465
|
+
autoComplete: React.ForwardRefExoticComponent<AutoCompleteProps>;
|
|
466
|
+
message: MessageApi;
|
|
467
|
+
tag: TagComponentType;
|
|
468
|
+
popover: React.ForwardRefExoticComponent<PopoverProps & React.RefAttributes<unknown>>;
|
|
469
|
+
arch: ArchComponentType;
|
|
470
|
+
buttonGroup: React.ForwardRefExoticComponent<ButtonGroupType & React.RefAttributes<HTMLDivElement>>;
|
|
471
|
+
steps: React.FC<IStepsProps>;
|
|
472
|
+
form: Form;
|
|
473
|
+
antdSteps: typeof Steps;
|
|
474
|
+
simplePagination: React.FC<ISimplePaginationProps>;
|
|
475
|
+
statusCapsule: StatusCapsuleComponentType;
|
|
476
|
+
space: React.FC<ISpaceProps>;
|
|
477
|
+
timeZoneSelect: React.FC<ITimeZoneSelectProps>;
|
|
478
|
+
col: React.FC<ColProps>;
|
|
479
|
+
row: React.FC<RowProps>;
|
|
480
|
+
timeline: React.FC<TimelineProps>;
|
|
481
|
+
timelineItem: React.FC<TimeLineItemProps>;
|
|
482
|
+
cascader: React.ComponentType<CascaderProps>;
|
|
483
|
+
checkboxGroup: React.ComponentType<CheckboxGroupProps>;
|
|
484
|
+
typographyText: React.FC<TextProps>;
|
|
485
|
+
upload: React.ComponentType<UploadProps>;
|
|
486
|
+
datePickerRangePicker: React.ComponentType<RangePickerProps>;
|
|
487
|
+
tableForm: React.ForwardRefExoticComponent<TableFormProps & React.RefAttributes<TableFormHandle>>;
|
|
488
|
+
token: TokenComponentType;
|
|
489
|
+
overflowTooltip: React.FC<OverflowTooltipProps>;
|
|
490
|
+
I18nNameTag: React.FC<any>;
|
|
491
|
+
uploadDragger: React.ComponentType<DraggerProps>;
|
|
492
|
+
calendar: React.FC<CalendarProps<Moment>>;
|
|
493
|
+
timePicker: React.FC<TimePickerProps>;
|
|
494
|
+
datePicker: React.ComponentType<DatePickerProps>;
|
|
495
|
+
tabs: React.FC<TabsProps>;
|
|
496
|
+
tabsTabPane: React.FC<TabPaneProps>;
|
|
497
|
+
antdBadge: React.FC<BadgeProps>;
|
|
498
|
+
antdMessage: MessageApi;
|
|
499
|
+
antdButton: React.ComponentType<AntdButtonProps>;
|
|
500
|
+
antdSelect: React.ComponentType<SelectProps<V>>;
|
|
501
|
+
antdTooltip: React.FC<TooltipProps>;
|
|
502
|
+
antdModal: React.FC<AntdModalProps & {
|
|
503
|
+
focusTriggerAfterClose?: boolean;
|
|
504
|
+
}>;
|
|
505
|
+
antdInput: typeof Input;
|
|
506
|
+
antdTable: AntdTableComponentType;
|
|
507
|
+
antdEmpty: EmptyType;
|
|
508
|
+
antdCheckbox: React.ComponentType<CheckboxProps>;
|
|
509
|
+
antdSwitch: React.FC<AntdSwitchProps>;
|
|
510
|
+
antdCollapse: CollapseInterface;
|
|
511
|
+
antdTreeSelect: typeof TreeSelect;
|
|
512
|
+
antdDrawer: React.FC<DrawerProps>;
|
|
513
|
+
truncate: React.FC<TruncatePropTypes>;
|
|
514
|
+
card: ForwardRefExoticComponent<PropsWithoutRef<PropsWithChildren<CardProps>> & RefAttributes<HTMLDivElement>>;
|
|
515
|
+
expandableList: {
|
|
516
|
+
ExpandableContainer: React.FC<PropsWithChildren<{}>>;
|
|
517
|
+
ExpandableItem: React.FC<PropsWithChildren<IExpandableItemProps>>;
|
|
518
|
+
};
|
|
519
|
+
time: React.FC<ITimeProps>;
|
|
520
|
+
DropdownTransition: React.FC<DropdownTransitionProps>;
|
|
521
|
+
AccordionCard: React.FC<IAccordionCardProps> & {
|
|
522
|
+
CloseButton: React.FC<CloseButtonProps>;
|
|
523
|
+
};
|
|
524
|
+
DetailCard: React.FC<IDetailCardProps>;
|
|
525
|
+
TruncatedTextWithTooltip: React.FC<TruncateTextWithTooltipType>;
|
|
526
|
+
Counting: React.FC<ICountingProps>;
|
|
527
|
+
Breadcrumb: React.FC<IBreadcrumbProps>;
|
|
528
|
+
CircleProgress: React.FC<ICircleProgressProps>;
|
|
529
|
+
}
|
|
530
|
+
export type ArchComponentType = React.FC<{
|
|
531
|
+
architecture?: Architecture;
|
|
532
|
+
}>;
|
|
533
|
+
export type SelectComponentType<V = any, T extends HTMLElement = HTMLElement> = React.FunctionComponent<LooseFieldRenderProps<V, T> & KitSelectProps>;
|
|
534
|
+
export type OptionComponentType = React.FC<OptionProps> & {
|
|
535
|
+
isSelectOption: boolean;
|
|
536
|
+
};
|
|
537
|
+
export type BadgeComponentType = React.FC<BadgeProps & {
|
|
538
|
+
type?: BadgeTypeProps;
|
|
539
|
+
}>;
|
|
540
|
+
export type ProgressComponentType = React.FC<ProgressProps>;
|
|
541
|
+
export type InputGroupComponentType = StyledMeta & React.FC<GroupProps>;
|
|
542
|
+
export type AlertComponentType = React.FunctionComponent<Omit<AlertProps, "type"> & {
|
|
543
|
+
type?: AlertProps["type"] | "normal";
|
|
544
|
+
action?: React.ReactNode;
|
|
545
|
+
}>;
|
|
546
|
+
export type SearchInputComponentType = React.FC<SearchInputProps>;
|
|
547
|
+
export type LoadingComponentType = React.FunctionComponent<{
|
|
548
|
+
fullView?: boolean;
|
|
549
|
+
}>;
|
|
550
|
+
export type EnumProps<V = any, T extends HTMLElement = HTMLElement> = {
|
|
551
|
+
input: Partial<FieldRenderProps<V, T>["input"]>;
|
|
552
|
+
meta: FieldRenderProps<V, T>["meta"];
|
|
553
|
+
disabled?: boolean;
|
|
554
|
+
className?: string;
|
|
555
|
+
dropdownClassName?: string;
|
|
556
|
+
} & BaseEnumProps;
|
|
557
|
+
export type TableFormPropsType = React.ForwardRefExoticComponent<TableFormProps & React.RefAttributes<TableFormHandle>>;
|
|
558
|
+
export type TagColor = "red" | "yellow" | "green" | "blue" | "purple" | "gray" | "red-ontint" | "green-ontint" | "error" | "warning" | "processing" | "default" | "success";
|
|
559
|
+
export type TagComponentType = React.FC<Omit<TagProps, "closable" | "closeIcon" | "onClose"> & {
|
|
560
|
+
color?: TagColor;
|
|
561
|
+
size?: "small" | "medium";
|
|
562
|
+
hoverable?: boolean;
|
|
563
|
+
}> & {
|
|
564
|
+
SplitTag: SplitTagComponentType;
|
|
565
|
+
};
|
|
566
|
+
export type StatusCapsuleColor = "red" | "yellow" | "green" | "blue" | "gray" | "success" | "danger" | "warning";
|
|
567
|
+
export type StatusCapsuleComponentType = React.FC<Omit<TagProps, "closable" | "closeIcon" | "onClose" | "icon" | "size"> & {
|
|
568
|
+
color?: StatusCapsuleColor;
|
|
569
|
+
loading?: boolean;
|
|
570
|
+
hoverable?: boolean;
|
|
571
|
+
offWhiteMode?: boolean;
|
|
572
|
+
number?: number;
|
|
573
|
+
}>;
|
|
574
|
+
export type SplitTagComponentType = React.FC<Omit<TagProps, "closable" | "closeIcon" | "onClose" | "visible"> & {
|
|
575
|
+
color?: "red" | "yellow" | "green" | "blue" | "purple" | "gray";
|
|
576
|
+
size?: "small" | "medium";
|
|
577
|
+
primaryContent: React.ReactNode;
|
|
578
|
+
secondaryContent: React.ReactNode;
|
|
579
|
+
}>;
|
|
580
|
+
export type TokenColor = "red" | "yellow" | "green" | "blue" | "gray" | "purple";
|
|
581
|
+
export type TokenType = Omit<TagProps, "closeIcon"> & {
|
|
582
|
+
color?: TokenColor;
|
|
583
|
+
size?: "small" | "medium" | "large";
|
|
584
|
+
checked?: boolean;
|
|
585
|
+
tooltipConfig?: {
|
|
586
|
+
title: string;
|
|
587
|
+
};
|
|
588
|
+
};
|
|
589
|
+
export type TokenComponentType = React.ForwardRefExoticComponent<TokenType & React.RefAttributes<HTMLDivElement>>;
|
|
590
|
+
export type OverflowTooltipProps = {
|
|
591
|
+
content: React.ReactNode;
|
|
592
|
+
tooltip?: React.ReactNode;
|
|
593
|
+
className?: string;
|
|
594
|
+
onClick?: () => void;
|
|
595
|
+
isMultiLine?: boolean;
|
|
596
|
+
};
|
|
597
|
+
export type TruncateTextWithTooltipType = {
|
|
598
|
+
text: string;
|
|
599
|
+
textWrapperCls?: string;
|
|
600
|
+
} & Omit<TooltipProps, "title">;
|
|
601
|
+
export {};
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
interface AnyObject {
|
|
3
|
+
[key: string]: any;
|
|
4
|
+
}
|
|
5
|
+
interface FieldInputProps<FieldValue, T extends HTMLElement = HTMLElement> extends AnyObject {
|
|
6
|
+
name: string;
|
|
7
|
+
onBlur: (event?: React.FocusEvent<T>) => void;
|
|
8
|
+
onChange: (event: React.ChangeEvent<T> | any) => void;
|
|
9
|
+
onFocus: (event?: React.FocusEvent<T>) => void;
|
|
10
|
+
type?: string;
|
|
11
|
+
value: FieldValue;
|
|
12
|
+
checked?: boolean;
|
|
13
|
+
multiple?: boolean;
|
|
14
|
+
}
|
|
15
|
+
export interface FieldState<FieldValue> {
|
|
16
|
+
active?: boolean;
|
|
17
|
+
blur: () => void;
|
|
18
|
+
change: (value: any) => void;
|
|
19
|
+
data?: AnyObject;
|
|
20
|
+
dirty?: boolean;
|
|
21
|
+
dirtySinceLastSubmit?: boolean;
|
|
22
|
+
error?: any;
|
|
23
|
+
focus: () => void;
|
|
24
|
+
initial?: FieldValue;
|
|
25
|
+
invalid?: boolean;
|
|
26
|
+
length?: number;
|
|
27
|
+
modified?: boolean;
|
|
28
|
+
name: string;
|
|
29
|
+
pristine?: boolean;
|
|
30
|
+
submitError?: any;
|
|
31
|
+
submitFailed?: boolean;
|
|
32
|
+
submitSucceeded?: boolean;
|
|
33
|
+
submitting?: boolean;
|
|
34
|
+
touched?: boolean;
|
|
35
|
+
valid?: boolean;
|
|
36
|
+
validating?: boolean;
|
|
37
|
+
value?: FieldValue;
|
|
38
|
+
visited?: boolean;
|
|
39
|
+
}
|
|
40
|
+
export type FieldMetaState<FieldValue> = Pick<FieldState<FieldValue>, Exclude<keyof FieldState<FieldValue>, "blur" | "change" | "focus" | "name" | "value">>;
|
|
41
|
+
export interface FieldRenderProps<FieldValue, T extends HTMLElement = HTMLElement> {
|
|
42
|
+
input: FieldInputProps<FieldValue, T>;
|
|
43
|
+
meta: FieldMetaState<FieldValue>;
|
|
44
|
+
[otherProp: string]: any;
|
|
45
|
+
}
|
|
46
|
+
export {};
|