@jiovan-labs/ant-buddy-pro 0.0.0-stage → 2.0.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/LICENSE.txt +21 -0
- package/README.md +55 -2
- package/dist/cjs/constant/DesignConst.d.ts +11 -0
- package/dist/cjs/constant/DesignConst.js +48 -0
- package/dist/cjs/constant/PackageConst.d.ts +3 -0
- package/dist/cjs/constant/PackageConst.js +31 -0
- package/dist/cjs/field/AvatarStamp/index.d.ts +14 -0
- package/dist/cjs/field/AvatarStamp/index.js +103 -0
- package/dist/cjs/field/AvatarStamp/styles.d.ts +2 -0
- package/dist/cjs/field/AvatarStamp/styles.js +54 -0
- package/dist/cjs/field/BadgeRibbon/index.d.ts +9 -0
- package/dist/cjs/field/BadgeRibbon/index.js +68 -0
- package/dist/cjs/field/BadgeRibbon/styles.d.ts +2 -0
- package/dist/cjs/field/BadgeRibbon/styles.js +55 -0
- package/dist/cjs/field/CommentCard/index.d.ts +12 -0
- package/dist/cjs/field/CommentCard/index.js +65 -0
- package/dist/cjs/field/CommentCard/styles.d.ts +2 -0
- package/dist/cjs/field/CommentCard/styles.js +132 -0
- package/dist/cjs/field/CompactTuple/index.d.ts +25 -0
- package/dist/cjs/field/CompactTuple/index.js +84 -0
- package/dist/cjs/field/CompactTuple/styles.d.ts +2 -0
- package/dist/cjs/field/CompactTuple/styles.js +118 -0
- package/dist/cjs/field/CornerStamp/index.d.ts +19 -0
- package/dist/cjs/field/CornerStamp/index.js +237 -0
- package/dist/cjs/field/CornerStamp/styles.d.ts +2 -0
- package/dist/cjs/field/CornerStamp/styles.js +66 -0
- package/dist/cjs/field/CountField/index.d.ts +25 -0
- package/dist/cjs/field/CountField/index.js +119 -0
- package/dist/cjs/field/CountField/styles.d.ts +2 -0
- package/dist/cjs/field/CountField/styles.js +58 -0
- package/dist/cjs/field/DelayModal/index.d.ts +32 -0
- package/dist/cjs/field/DelayModal/index.js +232 -0
- package/dist/cjs/field/DragModal/index.d.ts +7 -0
- package/dist/cjs/field/DragModal/index.js +151 -0
- package/dist/cjs/field/FallbackImage/index.d.ts +8 -0
- package/dist/cjs/field/FallbackImage/index.js +72 -0
- package/dist/cjs/field/Fullscreen/index.d.ts +24 -0
- package/dist/cjs/field/Fullscreen/index.js +95 -0
- package/dist/cjs/field/Fullscreen/locales.d.ts +2 -0
- package/dist/cjs/field/Fullscreen/locales.js +37 -0
- package/dist/cjs/field/LabelField/index.d.ts +26 -0
- package/dist/cjs/field/LabelField/index.js +100 -0
- package/dist/cjs/field/LabelField/styles.d.ts +2 -0
- package/dist/cjs/field/LabelField/styles.js +101 -0
- package/dist/cjs/field/NotifyBadge/index.d.ts +53 -0
- package/dist/cjs/field/NotifyBadge/index.js +203 -0
- package/dist/cjs/field/NotifyBadge/locales.d.ts +2 -0
- package/dist/cjs/field/NotifyBadge/locales.js +43 -0
- package/dist/cjs/field/NotifyBadge/styles.d.ts +2 -0
- package/dist/cjs/field/NotifyBadge/styles.js +163 -0
- package/dist/cjs/field/PreviewImage/index.d.ts +8 -0
- package/dist/cjs/field/PreviewImage/index.js +75 -0
- package/dist/cjs/field/RefreshImage/index.d.ts +20 -0
- package/dist/cjs/field/RefreshImage/index.js +105 -0
- package/dist/cjs/field/RefreshImage/locales.d.ts +2 -0
- package/dist/cjs/field/RefreshImage/locales.js +34 -0
- package/dist/cjs/field/RefreshImage/styles.d.ts +2 -0
- package/dist/cjs/field/RefreshImage/styles.js +50 -0
- package/dist/cjs/field/RemoteField/index.d.ts +17 -0
- package/dist/cjs/field/RemoteField/index.js +90 -0
- package/dist/cjs/field/SettingDrawer/index.d.ts +20 -0
- package/dist/cjs/field/SettingDrawer/index.js +115 -0
- package/dist/cjs/field/SettingDrawer/locales.d.ts +2 -0
- package/dist/cjs/field/SettingDrawer/locales.js +34 -0
- package/dist/cjs/field/SettingDrawer/styles.d.ts +2 -0
- package/dist/cjs/field/SettingDrawer/styles.js +61 -0
- package/dist/cjs/field/ThumbToggle/index.d.ts +43 -0
- package/dist/cjs/field/ThumbToggle/index.js +184 -0
- package/dist/cjs/field/ThumbToggle/locales.d.ts +2 -0
- package/dist/cjs/field/ThumbToggle/locales.js +40 -0
- package/dist/cjs/field/ThumbToggle/styles.d.ts +2 -0
- package/dist/cjs/field/ThumbToggle/styles.js +52 -0
- package/dist/cjs/field/ThumbTuple/index.d.ts +16 -0
- package/dist/cjs/field/ThumbTuple/index.js +110 -0
- package/dist/cjs/field/ThumbTuple/styles.d.ts +2 -0
- package/dist/cjs/field/ThumbTuple/styles.js +47 -0
- package/dist/cjs/field/TooltipField/index.d.ts +15 -0
- package/dist/cjs/field/TooltipField/index.js +57 -0
- package/dist/cjs/form/AddonInput/index.d.ts +15 -0
- package/dist/cjs/form/AddonInput/index.js +138 -0
- package/dist/cjs/form/AddonInput/styles.d.ts +2 -0
- package/dist/cjs/form/AddonInput/styles.js +106 -0
- package/dist/cjs/form/AvatarUpload/index.d.ts +68 -0
- package/dist/cjs/form/AvatarUpload/index.js +241 -0
- package/dist/cjs/form/AvatarUpload/locales.d.ts +2 -0
- package/dist/cjs/form/AvatarUpload/locales.js +46 -0
- package/dist/cjs/form/AvatarUpload/styles.d.ts +2 -0
- package/dist/cjs/form/AvatarUpload/styles.js +58 -0
- package/dist/cjs/form/CaptchaInput/index.d.ts +43 -0
- package/dist/cjs/form/CaptchaInput/index.js +219 -0
- package/dist/cjs/form/CaptchaInput/locales.d.ts +2 -0
- package/dist/cjs/form/CaptchaInput/locales.js +37 -0
- package/dist/cjs/form/CaptchaInput/styles.d.ts +2 -0
- package/dist/cjs/form/CaptchaInput/styles.js +56 -0
- package/dist/cjs/form/ChronoSelect/index.d.ts +25 -0
- package/dist/cjs/form/ChronoSelect/index.js +95 -0
- package/dist/cjs/form/ChronoSelect/locales.d.ts +2 -0
- package/dist/cjs/form/ChronoSelect/locales.js +58 -0
- package/dist/cjs/form/ChronoSelect/styles.d.ts +2 -0
- package/dist/cjs/form/ChronoSelect/styles.js +49 -0
- package/dist/cjs/form/ChronoTuple/index.d.ts +13 -0
- package/dist/cjs/form/ChronoTuple/index.js +102 -0
- package/dist/cjs/form/ChronoTuple/styles.d.ts +2 -0
- package/dist/cjs/form/ChronoTuple/styles.js +73 -0
- package/dist/cjs/form/CipherStrength/index.d.ts +32 -0
- package/dist/cjs/form/CipherStrength/index.js +119 -0
- package/dist/cjs/form/CipherStrength/locales.d.ts +2 -0
- package/dist/cjs/form/CipherStrength/locales.js +46 -0
- package/dist/cjs/form/CipherStrength/styles.d.ts +2 -0
- package/dist/cjs/form/CipherStrength/styles.js +66 -0
- package/dist/cjs/form/CollapseForm/index.d.ts +31 -0
- package/dist/cjs/form/CollapseForm/index.js +165 -0
- package/dist/cjs/form/CollapseForm/styles.d.ts +2 -0
- package/dist/cjs/form/CollapseForm/styles.js +60 -0
- package/dist/cjs/form/CronInput/component/DayPanel/index.d.ts +41 -0
- package/dist/cjs/form/CronInput/component/DayPanel/index.js +381 -0
- package/dist/cjs/form/CronInput/component/DayPanel/locales.d.ts +2 -0
- package/dist/cjs/form/CronInput/component/DayPanel/locales.js +76 -0
- package/dist/cjs/form/CronInput/component/DayPanel/styles.d.ts +2 -0
- package/dist/cjs/form/CronInput/component/DayPanel/styles.js +63 -0
- package/dist/cjs/form/CronInput/component/HourPanel/index.d.ts +29 -0
- package/dist/cjs/form/CronInput/component/HourPanel/index.js +284 -0
- package/dist/cjs/form/CronInput/component/HourPanel/locales.d.ts +2 -0
- package/dist/cjs/form/CronInput/component/HourPanel/locales.js +55 -0
- package/dist/cjs/form/CronInput/component/HourPanel/styles.d.ts +2 -0
- package/dist/cjs/form/CronInput/component/HourPanel/styles.js +63 -0
- package/dist/cjs/form/CronInput/component/MinutePanel/index.d.ts +29 -0
- package/dist/cjs/form/CronInput/component/MinutePanel/index.js +284 -0
- package/dist/cjs/form/CronInput/component/MinutePanel/locales.d.ts +2 -0
- package/dist/cjs/form/CronInput/component/MinutePanel/locales.js +55 -0
- package/dist/cjs/form/CronInput/component/MinutePanel/styles.d.ts +2 -0
- package/dist/cjs/form/CronInput/component/MinutePanel/styles.js +63 -0
- package/dist/cjs/form/CronInput/component/MonthPanel/index.d.ts +32 -0
- package/dist/cjs/form/CronInput/component/MonthPanel/index.js +341 -0
- package/dist/cjs/form/CronInput/component/MonthPanel/locales.d.ts +2 -0
- package/dist/cjs/form/CronInput/component/MonthPanel/locales.js +58 -0
- package/dist/cjs/form/CronInput/component/MonthPanel/styles.d.ts +2 -0
- package/dist/cjs/form/CronInput/component/MonthPanel/styles.js +63 -0
- package/dist/cjs/form/CronInput/component/SecondPanel/index.d.ts +29 -0
- package/dist/cjs/form/CronInput/component/SecondPanel/index.js +284 -0
- package/dist/cjs/form/CronInput/component/SecondPanel/locales.d.ts +2 -0
- package/dist/cjs/form/CronInput/component/SecondPanel/locales.js +55 -0
- package/dist/cjs/form/CronInput/component/SecondPanel/styles.d.ts +2 -0
- package/dist/cjs/form/CronInput/component/SecondPanel/styles.js +63 -0
- package/dist/cjs/form/CronInput/component/WeekPanel/index.d.ts +48 -0
- package/dist/cjs/form/CronInput/component/WeekPanel/index.js +506 -0
- package/dist/cjs/form/CronInput/component/WeekPanel/locales.d.ts +2 -0
- package/dist/cjs/form/CronInput/component/WeekPanel/locales.js +94 -0
- package/dist/cjs/form/CronInput/component/WeekPanel/styles.d.ts +2 -0
- package/dist/cjs/form/CronInput/component/WeekPanel/styles.js +52 -0
- package/dist/cjs/form/CronInput/component/YearPanel/index.d.ts +31 -0
- package/dist/cjs/form/CronInput/component/YearPanel/index.js +288 -0
- package/dist/cjs/form/CronInput/component/YearPanel/locales.d.ts +2 -0
- package/dist/cjs/form/CronInput/component/YearPanel/locales.js +55 -0
- package/dist/cjs/form/CronInput/component/YearPanel/styles.d.ts +2 -0
- package/dist/cjs/form/CronInput/component/YearPanel/styles.js +63 -0
- package/dist/cjs/form/CronInput/context.d.ts +7 -0
- package/dist/cjs/form/CronInput/context.js +40 -0
- package/dist/cjs/form/CronInput/index.d.ts +61 -0
- package/dist/cjs/form/CronInput/index.js +600 -0
- package/dist/cjs/form/CronInput/locales.d.ts +2 -0
- package/dist/cjs/form/CronInput/locales.js +61 -0
- package/dist/cjs/form/CronInput/styles.d.ts +2 -0
- package/dist/cjs/form/CronInput/styles.js +96 -0
- package/dist/cjs/form/DivideSelect/index.d.ts +21 -0
- package/dist/cjs/form/DivideSelect/index.js +239 -0
- package/dist/cjs/form/DivideSelect/styles.d.ts +2 -0
- package/dist/cjs/form/DivideSelect/styles.js +73 -0
- package/dist/cjs/form/ExactInput/index.d.ts +23 -0
- package/dist/cjs/form/ExactInput/index.js +119 -0
- package/dist/cjs/form/ExactInput/locales.d.ts +2 -0
- package/dist/cjs/form/ExactInput/locales.js +34 -0
- package/dist/cjs/form/IconSelect/index.d.ts +50 -0
- package/dist/cjs/form/IconSelect/index.js +561 -0
- package/dist/cjs/form/IconSelect/locales.d.ts +2 -0
- package/dist/cjs/form/IconSelect/locales.js +61 -0
- package/dist/cjs/form/IconSelect/styles.d.ts +2 -0
- package/dist/cjs/form/IconSelect/styles.js +140 -0
- package/dist/cjs/form/LocaleInput/index.d.ts +47 -0
- package/dist/cjs/form/LocaleInput/index.js +439 -0
- package/dist/cjs/form/LocaleInput/locales.d.ts +2 -0
- package/dist/cjs/form/LocaleInput/locales.js +43 -0
- package/dist/cjs/form/LocaleInput/styles.d.ts +2 -0
- package/dist/cjs/form/LocaleInput/styles.js +134 -0
- package/dist/cjs/form/LocaleTextarea/index.d.ts +45 -0
- package/dist/cjs/form/LocaleTextarea/index.js +305 -0
- package/dist/cjs/form/LocaleTextarea/locales.d.ts +2 -0
- package/dist/cjs/form/LocaleTextarea/locales.js +34 -0
- package/dist/cjs/form/LocaleTextarea/styles.d.ts +2 -0
- package/dist/cjs/form/LocaleTextarea/styles.js +89 -0
- package/dist/cjs/form/MaskInput/index.d.ts +9 -0
- package/dist/cjs/form/MaskInput/index.js +128 -0
- package/dist/cjs/form/MathInput/index.d.ts +26 -0
- package/dist/cjs/form/MathInput/index.js +192 -0
- package/dist/cjs/form/MathInput/locales.d.ts +2 -0
- package/dist/cjs/form/MathInput/locales.js +34 -0
- package/dist/cjs/form/MathInput/styles.d.ts +2 -0
- package/dist/cjs/form/MathInput/styles.js +71 -0
- package/dist/cjs/form/SegmentRadio/index.d.ts +16 -0
- package/dist/cjs/form/SegmentRadio/index.js +116 -0
- package/dist/cjs/form/ServerTuple/index.d.ts +22 -0
- package/dist/cjs/form/ServerTuple/index.js +141 -0
- package/dist/cjs/form/ServerTuple/locales.d.ts +2 -0
- package/dist/cjs/form/ServerTuple/locales.js +37 -0
- package/dist/cjs/form/ServerTuple/styles.d.ts +2 -0
- package/dist/cjs/form/ServerTuple/styles.js +84 -0
- package/dist/cjs/form/SortableList/index.d.ts +17 -0
- package/dist/cjs/form/SortableList/index.js +153 -0
- package/dist/cjs/form/SortableList/locales.d.ts +2 -0
- package/dist/cjs/form/SortableList/locales.js +43 -0
- package/dist/cjs/form/SortableList/styles.d.ts +2 -0
- package/dist/cjs/form/SortableList/styles.js +58 -0
- package/dist/cjs/form/StretchInput/index.d.ts +16 -0
- package/dist/cjs/form/StretchInput/index.js +139 -0
- package/dist/cjs/form/StretchInput/styles.d.ts +2 -0
- package/dist/cjs/form/StretchInput/styles.js +49 -0
- package/dist/cjs/form/TagInput/index.d.ts +57 -0
- package/dist/cjs/form/TagInput/index.js +368 -0
- package/dist/cjs/form/TagInput/locales.d.ts +2 -0
- package/dist/cjs/form/TagInput/locales.js +34 -0
- package/dist/cjs/form/TagInput/styles.d.ts +2 -0
- package/dist/cjs/form/TagInput/styles.js +80 -0
- package/dist/cjs/global.d.ts +20 -0
- package/dist/cjs/index.d.ts +73 -0
- package/dist/cjs/index.js +243 -0
- package/dist/cjs/layout/ApartTitle/index.d.ts +19 -0
- package/dist/cjs/layout/ApartTitle/index.js +75 -0
- package/dist/cjs/layout/ApartTitle/styles.d.ts +2 -0
- package/dist/cjs/layout/ApartTitle/styles.js +96 -0
- package/dist/cjs/layout/BorderBox/index.d.ts +16 -0
- package/dist/cjs/layout/BorderBox/index.js +86 -0
- package/dist/cjs/layout/BorderBox/styles.d.ts +2 -0
- package/dist/cjs/layout/BorderBox/styles.js +75 -0
- package/dist/cjs/layout/CardTabs/index.d.ts +19 -0
- package/dist/cjs/layout/CardTabs/index.js +79 -0
- package/dist/cjs/layout/CardTabs/styles.d.ts +2 -0
- package/dist/cjs/layout/CardTabs/styles.js +210 -0
- package/dist/cjs/layout/CodePreview/index.d.ts +25 -0
- package/dist/cjs/layout/CodePreview/index.js +79 -0
- package/dist/cjs/layout/CodePreview/styles.d.ts +2 -0
- package/dist/cjs/layout/CodePreview/styles.js +125 -0
- package/dist/cjs/layout/FlexBox/index.d.ts +23 -0
- package/dist/cjs/layout/FlexBox/index.js +96 -0
- package/dist/cjs/layout/FlexBox/styles.d.ts +2 -0
- package/dist/cjs/layout/FlexBox/styles.js +57 -0
- package/dist/cjs/layout/FoldSection/index.d.ts +36 -0
- package/dist/cjs/layout/FoldSection/index.js +124 -0
- package/dist/cjs/layout/FoldSection/locales.d.ts +2 -0
- package/dist/cjs/layout/FoldSection/locales.js +37 -0
- package/dist/cjs/layout/FoldSection/styles.d.ts +2 -0
- package/dist/cjs/layout/FoldSection/styles.js +141 -0
- package/dist/cjs/layout/LoginPortal/index.d.ts +21 -0
- package/dist/cjs/layout/LoginPortal/index.js +57 -0
- package/dist/cjs/layout/LoginPortal/styles.d.ts +2 -0
- package/dist/cjs/layout/LoginPortal/styles.js +73 -0
- package/dist/cjs/layout/MenuTabs/index.d.ts +38 -0
- package/dist/cjs/layout/MenuTabs/index.js +158 -0
- package/dist/cjs/layout/MenuTabs/styles.d.ts +2 -0
- package/dist/cjs/layout/MenuTabs/styles.js +159 -0
- package/dist/cjs/layout/PageFooter/index.d.ts +32 -0
- package/dist/cjs/layout/PageFooter/index.js +96 -0
- package/dist/cjs/layout/PageFooter/styles.d.ts +2 -0
- package/dist/cjs/layout/PageFooter/styles.js +82 -0
- package/dist/cjs/layout/SectionTitle/index.d.ts +19 -0
- package/dist/cjs/layout/SectionTitle/index.js +75 -0
- package/dist/cjs/layout/SectionTitle/styles.d.ts +2 -0
- package/dist/cjs/layout/SectionTitle/styles.js +130 -0
- package/dist/cjs/layout/SpaceBox/index.d.ts +11 -0
- package/dist/cjs/layout/SpaceBox/index.js +88 -0
- package/dist/cjs/layout/SpaceBox/styles.d.ts +2 -0
- package/dist/cjs/layout/SpaceBox/styles.js +58 -0
- package/dist/cjs/render/SchemaRender.d.ts +22 -0
- package/dist/cjs/render/SchemaRender.js +268 -0
- package/dist/cjs/render/SelectRender.d.ts +6 -0
- package/dist/cjs/render/SelectRender.js +57 -0
- package/dist/cjs/render/TooltipRender.d.ts +5 -0
- package/dist/cjs/render/TooltipRender.js +51 -0
- package/dist/cjs/style/calendar/default.less +85 -0
- package/dist/cjs/style/color/gray.less +50 -0
- package/dist/cjs/style/keepalive/tabs.less +49 -0
- package/dist/cjs/style/scrollbar/gray.less +64 -0
- package/dist/cjs/type/declaration.d.ts +16 -0
- package/dist/cjs/type/declaration.js +17 -0
- package/dist/cjs/type/design-icon.d.ts +31 -0
- package/dist/cjs/type/design-icon.js +986 -0
- package/dist/cjs/type/design-token.d.ts +5 -0
- package/dist/cjs/type/design-token.js +17 -0
- package/dist/cjs/util/ChildUtils.d.ts +4 -0
- package/dist/cjs/util/ChildUtils.js +80 -0
- package/dist/cjs/util/ConsoleUtils.d.ts +7 -0
- package/dist/cjs/util/ConsoleUtils.js +203 -0
- package/dist/cjs/util/DatasetUtils.d.ts +5 -0
- package/dist/cjs/util/DatasetUtils.js +69 -0
- package/dist/cjs/util/DesignUtils.d.ts +6 -0
- package/dist/cjs/util/DesignUtils.js +161 -0
- package/dist/cjs/util/ElementUtils.d.ts +6 -0
- package/dist/cjs/util/ElementUtils.js +98 -0
- package/dist/cjs/util/FieldUtils.d.ts +7 -0
- package/dist/cjs/util/FieldUtils.js +105 -0
- package/dist/cjs/util/FileUtils.d.ts +6 -0
- package/dist/cjs/util/FileUtils.js +64 -0
- package/dist/cjs/util/IconUtils.d.ts +11 -0
- package/dist/cjs/util/IconUtils.js +231 -0
- package/dist/cjs/util/ImageUtils.d.ts +3 -0
- package/dist/cjs/util/ImageUtils.js +54 -0
- package/dist/cjs/util/ModalUtils.d.ts +8 -0
- package/dist/cjs/util/ModalUtils.js +87 -0
- package/dist/cjs/util/NodeUtils.d.ts +5 -0
- package/dist/cjs/util/NodeUtils.js +88 -0
- package/dist/cjs/util/PaginationUtils.d.ts +5 -0
- package/dist/cjs/util/PaginationUtils.js +67 -0
- package/dist/cjs/util/ParticleUtils.d.ts +6 -0
- package/dist/cjs/util/ParticleUtils.js +410 -0
- package/dist/cjs/util/PropUtils.d.ts +5 -0
- package/dist/cjs/util/PropUtils.js +86 -0
- package/dist/cjs/util/ReactUtils.d.ts +3 -0
- package/dist/cjs/util/ReactUtils.js +55 -0
- package/dist/cjs/util/StyleUtils.d.ts +12 -0
- package/dist/cjs/util/StyleUtils.js +178 -0
- package/dist/cjs/util/TriggerUtils.d.ts +3 -0
- package/dist/cjs/util/TriggerUtils.js +76 -0
- package/dist/esm/constant/DesignConst.d.ts +11 -0
- package/dist/esm/constant/DesignConst.js +27 -0
- package/dist/esm/constant/PackageConst.d.ts +3 -0
- package/dist/esm/constant/PackageConst.js +11 -0
- package/dist/esm/field/AvatarStamp/index.d.ts +14 -0
- package/dist/esm/field/AvatarStamp/index.js +72 -0
- package/dist/esm/field/AvatarStamp/styles.d.ts +2 -0
- package/dist/esm/field/AvatarStamp/styles.js +28 -0
- package/dist/esm/field/BadgeRibbon/index.d.ts +9 -0
- package/dist/esm/field/BadgeRibbon/index.js +31 -0
- package/dist/esm/field/BadgeRibbon/styles.d.ts +2 -0
- package/dist/esm/field/BadgeRibbon/styles.js +26 -0
- package/dist/esm/field/CommentCard/index.d.ts +12 -0
- package/dist/esm/field/CommentCard/index.js +58 -0
- package/dist/esm/field/CommentCard/styles.d.ts +2 -0
- package/dist/esm/field/CommentCard/styles.js +85 -0
- package/dist/esm/field/CompactTuple/index.d.ts +25 -0
- package/dist/esm/field/CompactTuple/index.js +62 -0
- package/dist/esm/field/CompactTuple/styles.d.ts +2 -0
- package/dist/esm/field/CompactTuple/styles.js +66 -0
- package/dist/esm/field/CornerStamp/index.d.ts +19 -0
- package/dist/esm/field/CornerStamp/index.js +212 -0
- package/dist/esm/field/CornerStamp/styles.d.ts +2 -0
- package/dist/esm/field/CornerStamp/styles.js +38 -0
- package/dist/esm/field/CountField/index.d.ts +25 -0
- package/dist/esm/field/CountField/index.js +94 -0
- package/dist/esm/field/CountField/styles.d.ts +2 -0
- package/dist/esm/field/CountField/styles.js +30 -0
- package/dist/esm/field/DelayModal/index.d.ts +32 -0
- package/dist/esm/field/DelayModal/index.js +222 -0
- package/dist/esm/field/DragModal/index.d.ts +7 -0
- package/dist/esm/field/DragModal/index.js +137 -0
- package/dist/esm/field/FallbackImage/index.d.ts +8 -0
- package/dist/esm/field/FallbackImage/index.js +55 -0
- package/dist/esm/field/Fullscreen/index.d.ts +24 -0
- package/dist/esm/field/Fullscreen/index.js +74 -0
- package/dist/esm/field/Fullscreen/locales.d.ts +2 -0
- package/dist/esm/field/Fullscreen/locales.js +2 -0
- package/dist/esm/field/LabelField/index.d.ts +26 -0
- package/dist/esm/field/LabelField/index.js +61 -0
- package/dist/esm/field/LabelField/styles.d.ts +2 -0
- package/dist/esm/field/LabelField/styles.js +60 -0
- package/dist/esm/field/NotifyBadge/index.d.ts +53 -0
- package/dist/esm/field/NotifyBadge/index.js +212 -0
- package/dist/esm/field/NotifyBadge/locales.d.ts +2 -0
- package/dist/esm/field/NotifyBadge/locales.js +2 -0
- package/dist/esm/field/NotifyBadge/styles.d.ts +2 -0
- package/dist/esm/field/NotifyBadge/styles.js +106 -0
- package/dist/esm/field/PreviewImage/index.d.ts +8 -0
- package/dist/esm/field/PreviewImage/index.js +57 -0
- package/dist/esm/field/RefreshImage/index.d.ts +20 -0
- package/dist/esm/field/RefreshImage/index.js +89 -0
- package/dist/esm/field/RefreshImage/locales.d.ts +2 -0
- package/dist/esm/field/RefreshImage/locales.js +2 -0
- package/dist/esm/field/RefreshImage/styles.d.ts +2 -0
- package/dist/esm/field/RefreshImage/styles.js +24 -0
- package/dist/esm/field/RemoteField/index.d.ts +17 -0
- package/dist/esm/field/RemoteField/index.js +68 -0
- package/dist/esm/field/SettingDrawer/index.d.ts +20 -0
- package/dist/esm/field/SettingDrawer/index.js +76 -0
- package/dist/esm/field/SettingDrawer/locales.d.ts +2 -0
- package/dist/esm/field/SettingDrawer/locales.js +2 -0
- package/dist/esm/field/SettingDrawer/styles.d.ts +2 -0
- package/dist/esm/field/SettingDrawer/styles.js +33 -0
- package/dist/esm/field/ThumbToggle/index.d.ts +43 -0
- package/dist/esm/field/ThumbToggle/index.js +217 -0
- package/dist/esm/field/ThumbToggle/locales.d.ts +2 -0
- package/dist/esm/field/ThumbToggle/locales.js +2 -0
- package/dist/esm/field/ThumbToggle/styles.d.ts +2 -0
- package/dist/esm/field/ThumbToggle/styles.js +24 -0
- package/dist/esm/field/ThumbTuple/index.d.ts +16 -0
- package/dist/esm/field/ThumbTuple/index.js +105 -0
- package/dist/esm/field/ThumbTuple/styles.d.ts +2 -0
- package/dist/esm/field/ThumbTuple/styles.js +22 -0
- package/dist/esm/field/TooltipField/index.d.ts +15 -0
- package/dist/esm/field/TooltipField/index.js +29 -0
- package/dist/esm/form/AddonInput/index.d.ts +15 -0
- package/dist/esm/form/AddonInput/index.js +144 -0
- package/dist/esm/form/AddonInput/styles.d.ts +2 -0
- package/dist/esm/form/AddonInput/styles.js +67 -0
- package/dist/esm/form/AvatarUpload/index.d.ts +68 -0
- package/dist/esm/form/AvatarUpload/index.js +235 -0
- package/dist/esm/form/AvatarUpload/locales.d.ts +2 -0
- package/dist/esm/form/AvatarUpload/locales.js +2 -0
- package/dist/esm/form/AvatarUpload/styles.d.ts +2 -0
- package/dist/esm/form/AvatarUpload/styles.js +29 -0
- package/dist/esm/form/CaptchaInput/index.d.ts +43 -0
- package/dist/esm/form/CaptchaInput/index.js +287 -0
- package/dist/esm/form/CaptchaInput/locales.d.ts +2 -0
- package/dist/esm/form/CaptchaInput/locales.js +2 -0
- package/dist/esm/form/CaptchaInput/styles.d.ts +2 -0
- package/dist/esm/form/CaptchaInput/styles.js +29 -0
- package/dist/esm/form/ChronoSelect/index.d.ts +25 -0
- package/dist/esm/form/ChronoSelect/index.js +62 -0
- package/dist/esm/form/ChronoSelect/locales.d.ts +2 -0
- package/dist/esm/form/ChronoSelect/locales.js +2 -0
- package/dist/esm/form/ChronoSelect/styles.d.ts +2 -0
- package/dist/esm/form/ChronoSelect/styles.js +22 -0
- package/dist/esm/form/ChronoTuple/index.d.ts +13 -0
- package/dist/esm/form/ChronoTuple/index.js +62 -0
- package/dist/esm/form/ChronoTuple/styles.d.ts +2 -0
- package/dist/esm/form/ChronoTuple/styles.js +37 -0
- package/dist/esm/form/CipherStrength/index.d.ts +32 -0
- package/dist/esm/form/CipherStrength/index.js +73 -0
- package/dist/esm/form/CipherStrength/locales.d.ts +2 -0
- package/dist/esm/form/CipherStrength/locales.js +2 -0
- package/dist/esm/form/CipherStrength/styles.d.ts +2 -0
- package/dist/esm/form/CipherStrength/styles.js +34 -0
- package/dist/esm/form/CollapseForm/index.d.ts +31 -0
- package/dist/esm/form/CollapseForm/index.js +176 -0
- package/dist/esm/form/CollapseForm/styles.d.ts +2 -0
- package/dist/esm/form/CollapseForm/styles.js +28 -0
- package/dist/esm/form/CronInput/component/DayPanel/index.d.ts +41 -0
- package/dist/esm/form/CronInput/component/DayPanel/index.js +374 -0
- package/dist/esm/form/CronInput/component/DayPanel/locales.d.ts +2 -0
- package/dist/esm/form/CronInput/component/DayPanel/locales.js +2 -0
- package/dist/esm/form/CronInput/component/DayPanel/styles.d.ts +2 -0
- package/dist/esm/form/CronInput/component/DayPanel/styles.js +31 -0
- package/dist/esm/form/CronInput/component/HourPanel/index.d.ts +29 -0
- package/dist/esm/form/CronInput/component/HourPanel/index.js +271 -0
- package/dist/esm/form/CronInput/component/HourPanel/locales.d.ts +2 -0
- package/dist/esm/form/CronInput/component/HourPanel/locales.js +2 -0
- package/dist/esm/form/CronInput/component/HourPanel/styles.d.ts +2 -0
- package/dist/esm/form/CronInput/component/HourPanel/styles.js +31 -0
- package/dist/esm/form/CronInput/component/MinutePanel/index.d.ts +29 -0
- package/dist/esm/form/CronInput/component/MinutePanel/index.js +271 -0
- package/dist/esm/form/CronInput/component/MinutePanel/locales.d.ts +2 -0
- package/dist/esm/form/CronInput/component/MinutePanel/locales.js +2 -0
- package/dist/esm/form/CronInput/component/MinutePanel/styles.d.ts +2 -0
- package/dist/esm/form/CronInput/component/MinutePanel/styles.js +31 -0
- package/dist/esm/form/CronInput/component/MonthPanel/index.d.ts +32 -0
- package/dist/esm/form/CronInput/component/MonthPanel/index.js +318 -0
- package/dist/esm/form/CronInput/component/MonthPanel/locales.d.ts +2 -0
- package/dist/esm/form/CronInput/component/MonthPanel/locales.js +2 -0
- package/dist/esm/form/CronInput/component/MonthPanel/styles.d.ts +2 -0
- package/dist/esm/form/CronInput/component/MonthPanel/styles.js +31 -0
- package/dist/esm/form/CronInput/component/SecondPanel/index.d.ts +29 -0
- package/dist/esm/form/CronInput/component/SecondPanel/index.js +271 -0
- package/dist/esm/form/CronInput/component/SecondPanel/locales.d.ts +2 -0
- package/dist/esm/form/CronInput/component/SecondPanel/locales.js +2 -0
- package/dist/esm/form/CronInput/component/SecondPanel/styles.d.ts +2 -0
- package/dist/esm/form/CronInput/component/SecondPanel/styles.js +31 -0
- package/dist/esm/form/CronInput/component/WeekPanel/index.d.ts +48 -0
- package/dist/esm/form/CronInput/component/WeekPanel/index.js +483 -0
- package/dist/esm/form/CronInput/component/WeekPanel/locales.d.ts +2 -0
- package/dist/esm/form/CronInput/component/WeekPanel/locales.js +2 -0
- package/dist/esm/form/CronInput/component/WeekPanel/styles.d.ts +2 -0
- package/dist/esm/form/CronInput/component/WeekPanel/styles.js +23 -0
- package/dist/esm/form/CronInput/component/YearPanel/index.d.ts +31 -0
- package/dist/esm/form/CronInput/component/YearPanel/index.js +277 -0
- package/dist/esm/form/CronInput/component/YearPanel/locales.d.ts +2 -0
- package/dist/esm/form/CronInput/component/YearPanel/locales.js +2 -0
- package/dist/esm/form/CronInput/component/YearPanel/styles.d.ts +2 -0
- package/dist/esm/form/CronInput/component/YearPanel/styles.js +31 -0
- package/dist/esm/form/CronInput/context.d.ts +7 -0
- package/dist/esm/form/CronInput/context.js +2 -0
- package/dist/esm/form/CronInput/index.d.ts +61 -0
- package/dist/esm/form/CronInput/index.js +608 -0
- package/dist/esm/form/CronInput/locales.d.ts +2 -0
- package/dist/esm/form/CronInput/locales.js +2 -0
- package/dist/esm/form/CronInput/styles.d.ts +2 -0
- package/dist/esm/form/CronInput/styles.js +58 -0
- package/dist/esm/form/DivideSelect/index.d.ts +21 -0
- package/dist/esm/form/DivideSelect/index.js +234 -0
- package/dist/esm/form/DivideSelect/styles.d.ts +2 -0
- package/dist/esm/form/DivideSelect/styles.js +37 -0
- package/dist/esm/form/ExactInput/index.d.ts +23 -0
- package/dist/esm/form/ExactInput/index.js +95 -0
- package/dist/esm/form/ExactInput/locales.d.ts +2 -0
- package/dist/esm/form/ExactInput/locales.js +2 -0
- package/dist/esm/form/IconSelect/index.d.ts +50 -0
- package/dist/esm/form/IconSelect/index.js +601 -0
- package/dist/esm/form/IconSelect/locales.d.ts +2 -0
- package/dist/esm/form/IconSelect/locales.js +2 -0
- package/dist/esm/form/IconSelect/styles.d.ts +2 -0
- package/dist/esm/form/IconSelect/styles.js +91 -0
- package/dist/esm/form/LocaleInput/index.d.ts +47 -0
- package/dist/esm/form/LocaleInput/index.js +482 -0
- package/dist/esm/form/LocaleInput/locales.d.ts +2 -0
- package/dist/esm/form/LocaleInput/locales.js +2 -0
- package/dist/esm/form/LocaleInput/styles.d.ts +2 -0
- package/dist/esm/form/LocaleInput/styles.js +82 -0
- package/dist/esm/form/LocaleTextarea/index.d.ts +45 -0
- package/dist/esm/form/LocaleTextarea/index.js +295 -0
- package/dist/esm/form/LocaleTextarea/locales.d.ts +2 -0
- package/dist/esm/form/LocaleTextarea/locales.js +2 -0
- package/dist/esm/form/LocaleTextarea/styles.d.ts +2 -0
- package/dist/esm/form/LocaleTextarea/styles.js +45 -0
- package/dist/esm/form/MaskInput/index.d.ts +9 -0
- package/dist/esm/form/MaskInput/index.js +101 -0
- package/dist/esm/form/MathInput/index.d.ts +26 -0
- package/dist/esm/form/MathInput/index.js +183 -0
- package/dist/esm/form/MathInput/locales.d.ts +2 -0
- package/dist/esm/form/MathInput/locales.js +2 -0
- package/dist/esm/form/MathInput/styles.d.ts +2 -0
- package/dist/esm/form/MathInput/styles.js +41 -0
- package/dist/esm/form/SegmentRadio/index.d.ts +16 -0
- package/dist/esm/form/SegmentRadio/index.js +100 -0
- package/dist/esm/form/ServerTuple/index.d.ts +22 -0
- package/dist/esm/form/ServerTuple/index.js +97 -0
- package/dist/esm/form/ServerTuple/locales.d.ts +2 -0
- package/dist/esm/form/ServerTuple/locales.js +2 -0
- package/dist/esm/form/ServerTuple/styles.d.ts +2 -0
- package/dist/esm/form/ServerTuple/styles.js +44 -0
- package/dist/esm/form/SortableList/index.d.ts +17 -0
- package/dist/esm/form/SortableList/index.js +103 -0
- package/dist/esm/form/SortableList/locales.d.ts +2 -0
- package/dist/esm/form/SortableList/locales.js +2 -0
- package/dist/esm/form/SortableList/styles.d.ts +2 -0
- package/dist/esm/form/SortableList/styles.js +27 -0
- package/dist/esm/form/StretchInput/index.d.ts +16 -0
- package/dist/esm/form/StretchInput/index.js +111 -0
- package/dist/esm/form/StretchInput/styles.d.ts +2 -0
- package/dist/esm/form/StretchInput/styles.js +22 -0
- package/dist/esm/form/TagInput/index.d.ts +57 -0
- package/dist/esm/form/TagInput/index.js +425 -0
- package/dist/esm/form/TagInput/locales.d.ts +2 -0
- package/dist/esm/form/TagInput/locales.js +2 -0
- package/dist/esm/form/TagInput/styles.d.ts +2 -0
- package/dist/esm/form/TagInput/styles.js +42 -0
- package/dist/esm/global.d.ts +20 -0
- package/dist/esm/index.d.ts +73 -0
- package/dist/esm/index.js +73 -0
- package/dist/esm/layout/ApartTitle/index.d.ts +19 -0
- package/dist/esm/layout/ApartTitle/index.js +36 -0
- package/dist/esm/layout/ApartTitle/styles.d.ts +2 -0
- package/dist/esm/layout/ApartTitle/styles.js +58 -0
- package/dist/esm/layout/BorderBox/index.d.ts +16 -0
- package/dist/esm/layout/BorderBox/index.js +52 -0
- package/dist/esm/layout/BorderBox/styles.d.ts +2 -0
- package/dist/esm/layout/BorderBox/styles.js +42 -0
- package/dist/esm/layout/CardTabs/index.d.ts +19 -0
- package/dist/esm/layout/CardTabs/index.js +54 -0
- package/dist/esm/layout/CardTabs/styles.d.ts +2 -0
- package/dist/esm/layout/CardTabs/styles.js +128 -0
- package/dist/esm/layout/CodePreview/index.d.ts +25 -0
- package/dist/esm/layout/CodePreview/index.js +54 -0
- package/dist/esm/layout/CodePreview/styles.d.ts +2 -0
- package/dist/esm/layout/CodePreview/styles.js +80 -0
- package/dist/esm/layout/FlexBox/index.d.ts +23 -0
- package/dist/esm/layout/FlexBox/index.js +69 -0
- package/dist/esm/layout/FlexBox/styles.d.ts +2 -0
- package/dist/esm/layout/FlexBox/styles.js +29 -0
- package/dist/esm/layout/FoldSection/index.d.ts +36 -0
- package/dist/esm/layout/FoldSection/index.js +121 -0
- package/dist/esm/layout/FoldSection/locales.d.ts +2 -0
- package/dist/esm/layout/FoldSection/locales.js +2 -0
- package/dist/esm/layout/FoldSection/styles.d.ts +2 -0
- package/dist/esm/layout/FoldSection/styles.js +85 -0
- package/dist/esm/layout/LoginPortal/index.d.ts +21 -0
- package/dist/esm/layout/LoginPortal/index.js +31 -0
- package/dist/esm/layout/LoginPortal/styles.d.ts +2 -0
- package/dist/esm/layout/LoginPortal/styles.js +44 -0
- package/dist/esm/layout/MenuTabs/index.d.ts +38 -0
- package/dist/esm/layout/MenuTabs/index.js +125 -0
- package/dist/esm/layout/MenuTabs/styles.d.ts +2 -0
- package/dist/esm/layout/MenuTabs/styles.js +99 -0
- package/dist/esm/layout/PageFooter/index.d.ts +32 -0
- package/dist/esm/layout/PageFooter/index.js +77 -0
- package/dist/esm/layout/PageFooter/styles.d.ts +2 -0
- package/dist/esm/layout/PageFooter/styles.js +44 -0
- package/dist/esm/layout/SectionTitle/index.d.ts +19 -0
- package/dist/esm/layout/SectionTitle/index.js +36 -0
- package/dist/esm/layout/SectionTitle/styles.d.ts +2 -0
- package/dist/esm/layout/SectionTitle/styles.js +81 -0
- package/dist/esm/layout/SpaceBox/index.d.ts +11 -0
- package/dist/esm/layout/SpaceBox/index.js +68 -0
- package/dist/esm/layout/SpaceBox/styles.d.ts +2 -0
- package/dist/esm/layout/SpaceBox/styles.js +30 -0
- package/dist/esm/render/SchemaRender.d.ts +22 -0
- package/dist/esm/render/SchemaRender.js +162 -0
- package/dist/esm/render/SelectRender.d.ts +6 -0
- package/dist/esm/render/SelectRender.js +56 -0
- package/dist/esm/render/TooltipRender.d.ts +5 -0
- package/dist/esm/render/TooltipRender.js +30 -0
- package/dist/esm/style/calendar/default.less +85 -0
- package/dist/esm/style/color/gray.less +50 -0
- package/dist/esm/style/keepalive/tabs.less +49 -0
- package/dist/esm/style/scrollbar/gray.less +64 -0
- package/dist/esm/type/declaration.d.ts +16 -0
- package/dist/esm/type/declaration.js +1 -0
- package/dist/esm/type/design-icon.d.ts +31 -0
- package/dist/esm/type/design-icon.js +30 -0
- package/dist/esm/type/design-token.d.ts +5 -0
- package/dist/esm/type/design-token.js +1 -0
- package/dist/esm/util/ChildUtils.d.ts +4 -0
- package/dist/esm/util/ChildUtils.js +31 -0
- package/dist/esm/util/ConsoleUtils.d.ts +7 -0
- package/dist/esm/util/ConsoleUtils.js +117 -0
- package/dist/esm/util/DatasetUtils.d.ts +5 -0
- package/dist/esm/util/DatasetUtils.js +37 -0
- package/dist/esm/util/DesignUtils.d.ts +6 -0
- package/dist/esm/util/DesignUtils.js +75 -0
- package/dist/esm/util/ElementUtils.d.ts +6 -0
- package/dist/esm/util/ElementUtils.js +54 -0
- package/dist/esm/util/FieldUtils.d.ts +7 -0
- package/dist/esm/util/FieldUtils.js +72 -0
- package/dist/esm/util/FileUtils.d.ts +6 -0
- package/dist/esm/util/FileUtils.js +34 -0
- package/dist/esm/util/IconUtils.d.ts +11 -0
- package/dist/esm/util/IconUtils.js +174 -0
- package/dist/esm/util/ImageUtils.d.ts +3 -0
- package/dist/esm/util/ImageUtils.js +29 -0
- package/dist/esm/util/ModalUtils.d.ts +8 -0
- package/dist/esm/util/ModalUtils.js +37 -0
- package/dist/esm/util/NodeUtils.d.ts +5 -0
- package/dist/esm/util/NodeUtils.js +51 -0
- package/dist/esm/util/PaginationUtils.d.ts +5 -0
- package/dist/esm/util/PaginationUtils.js +41 -0
- package/dist/esm/util/ParticleUtils.d.ts +6 -0
- package/dist/esm/util/ParticleUtils.js +350 -0
- package/dist/esm/util/PropUtils.d.ts +5 -0
- package/dist/esm/util/PropUtils.js +49 -0
- package/dist/esm/util/ReactUtils.d.ts +3 -0
- package/dist/esm/util/ReactUtils.js +19 -0
- package/dist/esm/util/StyleUtils.d.ts +12 -0
- package/dist/esm/util/StyleUtils.js +132 -0
- package/dist/esm/util/TriggerUtils.d.ts +3 -0
- package/dist/esm/util/TriggerUtils.js +48 -0
- package/package.json +152 -5
|
@@ -0,0 +1,608 @@
|
|
|
1
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
2
|
+
function _regeneratorRuntime() { "use strict"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { return e; }; var t, e = {}, r = Object.prototype, n = r.hasOwnProperty, o = Object.defineProperty || function (t, e, r) { t[e] = r.value; }, i = "function" == typeof Symbol ? Symbol : {}, a = i.iterator || "@@iterator", c = i.asyncIterator || "@@asyncIterator", u = i.toStringTag || "@@toStringTag"; function define(t, e, r) { return Object.defineProperty(t, e, { value: r, enumerable: !0, configurable: !0, writable: !0 }), t[e]; } try { define({}, ""); } catch (t) { define = function define(t, e, r) { return t[e] = r; }; } function wrap(t, e, r, n) { var i = e && e.prototype instanceof Generator ? e : Generator, a = Object.create(i.prototype), c = new Context(n || []); return o(a, "_invoke", { value: makeInvokeMethod(t, r, c) }), a; } function tryCatch(t, e, r) { try { return { type: "normal", arg: t.call(e, r) }; } catch (t) { return { type: "throw", arg: t }; } } e.wrap = wrap; var h = "suspendedStart", l = "suspendedYield", f = "executing", s = "completed", y = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var p = {}; define(p, a, function () { return this; }); var d = Object.getPrototypeOf, v = d && d(d(values([]))); v && v !== r && n.call(v, a) && (p = v); var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p); function defineIteratorMethods(t) { ["next", "throw", "return"].forEach(function (e) { define(t, e, function (t) { return this._invoke(e, t); }); }); } function AsyncIterator(t, e) { function invoke(r, o, i, a) { var c = tryCatch(t[r], t, o); if ("throw" !== c.type) { var u = c.arg, h = u.value; return h && "object" == _typeof(h) && n.call(h, "__await") ? e.resolve(h.__await).then(function (t) { invoke("next", t, i, a); }, function (t) { invoke("throw", t, i, a); }) : e.resolve(h).then(function (t) { u.value = t, i(u); }, function (t) { return invoke("throw", t, i, a); }); } a(c.arg); } var r; o(this, "_invoke", { value: function value(t, n) { function callInvokeWithMethodAndArg() { return new e(function (e, r) { invoke(t, n, e, r); }); } return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(e, r, n) { var o = h; return function (i, a) { if (o === f) throw new Error("Generator is already running"); if (o === s) { if ("throw" === i) throw a; return { value: t, done: !0 }; } for (n.method = i, n.arg = a;;) { var c = n.delegate; if (c) { var u = maybeInvokeDelegate(c, n); if (u) { if (u === y) continue; return u; } } if ("next" === n.method) n.sent = n._sent = n.arg;else if ("throw" === n.method) { if (o === h) throw o = s, n.arg; n.dispatchException(n.arg); } else "return" === n.method && n.abrupt("return", n.arg); o = f; var p = tryCatch(e, r, n); if ("normal" === p.type) { if (o = n.done ? s : l, p.arg === y) continue; return { value: p.arg, done: n.done }; } "throw" === p.type && (o = s, n.method = "throw", n.arg = p.arg); } }; } function maybeInvokeDelegate(e, r) { var n = r.method, o = e.iterator[n]; if (o === t) return r.delegate = null, "throw" === n && e.iterator.return && (r.method = "return", r.arg = t, maybeInvokeDelegate(e, r), "throw" === r.method) || "return" !== n && (r.method = "throw", r.arg = new TypeError("The iterator does not provide a '" + n + "' method")), y; var i = tryCatch(o, e.iterator, r.arg); if ("throw" === i.type) return r.method = "throw", r.arg = i.arg, r.delegate = null, y; var a = i.arg; return a ? a.done ? (r[e.resultName] = a.value, r.next = e.nextLoc, "return" !== r.method && (r.method = "next", r.arg = t), r.delegate = null, y) : a : (r.method = "throw", r.arg = new TypeError("iterator result is not an object"), r.delegate = null, y); } function pushTryEntry(t) { var e = { tryLoc: t[0] }; 1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e); } function resetTryEntry(t) { var e = t.completion || {}; e.type = "normal", delete e.arg, t.completion = e; } function Context(t) { this.tryEntries = [{ tryLoc: "root" }], t.forEach(pushTryEntry, this), this.reset(!0); } function values(e) { if (e || "" === e) { var r = e[a]; if (r) return r.call(e); if ("function" == typeof e.next) return e; if (!isNaN(e.length)) { var o = -1, i = function next() { for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next; return next.value = t, next.done = !0, next; }; return i.next = i; } } throw new TypeError(_typeof(e) + " is not iterable"); } return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, "constructor", { value: GeneratorFunctionPrototype, configurable: !0 }), o(GeneratorFunctionPrototype, "constructor", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, "GeneratorFunction"), e.isGeneratorFunction = function (t) { var e = "function" == typeof t && t.constructor; return !!e && (e === GeneratorFunction || "GeneratorFunction" === (e.displayName || e.name)); }, e.mark = function (t) { return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, "GeneratorFunction")), t.prototype = Object.create(g), t; }, e.awrap = function (t) { return { __await: t }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () { return this; }), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) { void 0 === i && (i = Promise); var a = new AsyncIterator(wrap(t, r, n, o), i); return e.isGeneratorFunction(r) ? a : a.next().then(function (t) { return t.done ? t.value : a.next(); }); }, defineIteratorMethods(g), define(g, u, "Generator"), define(g, a, function () { return this; }), define(g, "toString", function () { return "[object Generator]"; }), e.keys = function (t) { var e = Object(t), r = []; for (var n in e) r.push(n); return r.reverse(), function next() { for (; r.length;) { var t = r.pop(); if (t in e) return next.value = t, next.done = !1, next; } return next.done = !0, next; }; }, e.values = values, Context.prototype = { constructor: Context, reset: function reset(e) { if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = "next", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) "t" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t); }, stop: function stop() { this.done = !0; var t = this.tryEntries[0].completion; if ("throw" === t.type) throw t.arg; return this.rval; }, dispatchException: function dispatchException(e) { if (this.done) throw e; var r = this; function handle(n, o) { return a.type = "throw", a.arg = e, r.next = n, o && (r.method = "next", r.arg = t), !!o; } for (var o = this.tryEntries.length - 1; o >= 0; --o) { var i = this.tryEntries[o], a = i.completion; if ("root" === i.tryLoc) return handle("end"); if (i.tryLoc <= this.prev) { var c = n.call(i, "catchLoc"), u = n.call(i, "finallyLoc"); if (c && u) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } else if (c) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); } else { if (!u) throw new Error("try statement without catch or finally"); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } } } }, abrupt: function abrupt(t, e) { for (var r = this.tryEntries.length - 1; r >= 0; --r) { var o = this.tryEntries[r]; if (o.tryLoc <= this.prev && n.call(o, "finallyLoc") && this.prev < o.finallyLoc) { var i = o; break; } } i && ("break" === t || "continue" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null); var a = i ? i.completion : {}; return a.type = t, a.arg = e, i ? (this.method = "next", this.next = i.finallyLoc, y) : this.complete(a); }, complete: function complete(t, e) { if ("throw" === t.type) throw t.arg; return "break" === t.type || "continue" === t.type ? this.next = t.arg : "return" === t.type ? (this.rval = this.arg = t.arg, this.method = "return", this.next = "end") : "normal" === t.type && e && (this.next = e), y; }, finish: function finish(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y; } }, catch: function _catch(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.tryLoc === t) { var n = r.completion; if ("throw" === n.type) { var o = n.arg; resetTryEntry(r); } return o; } } throw new Error("illegal catch attempt"); }, delegateYield: function delegateYield(e, r, n) { return this.delegate = { iterator: values(e), resultName: r, nextLoc: n }, "next" === this.method && (this.arg = t), y; } }, e; }
|
|
3
|
+
function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } }
|
|
4
|
+
function _asyncToGenerator(fn) { return function () { var self = this, args = arguments; return new Promise(function (resolve, reject) { var gen = fn.apply(self, args); function _next(value) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value); } function _throw(err) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err); } _next(undefined); }); }; }
|
|
5
|
+
function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
|
|
6
|
+
function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
7
|
+
function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter); }
|
|
8
|
+
function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); }
|
|
9
|
+
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
10
|
+
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
11
|
+
function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
12
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
|
13
|
+
function _toPrimitive(t, r) { if ("object" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != _typeof(i)) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
14
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
15
|
+
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
16
|
+
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
17
|
+
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
18
|
+
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
19
|
+
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
20
|
+
import React from 'react';
|
|
21
|
+
import { ConfigProvider, Form, Button, Switch, Space, Input, message as messageApi } from 'antd';
|
|
22
|
+
import { FieldTimeOutlined } from '@ant-design/icons';
|
|
23
|
+
import { useIntl } from '@ant-design/pro-components';
|
|
24
|
+
import { EditOrReadOnlyContext } from '@ant-design/pro-components/es/form/BaseForm/EditOrReadOnlyContext.js';
|
|
25
|
+
import { If } from '@jiovan-labs/react-condition';
|
|
26
|
+
import { ElementUtils, NanoidUtils, ObjectUtils, StringUtils } from '@jiovan-labs/ts-lang-utils';
|
|
27
|
+
import Trigger from '@rc-component/trigger';
|
|
28
|
+
import '@rc-component/trigger/assets/index.less';
|
|
29
|
+
import { omit } from '@rc-component/util';
|
|
30
|
+
import { useEventListener, useMutationObserver } from 'ahooks';
|
|
31
|
+
import classnames from 'classnames';
|
|
32
|
+
import cronValidate from 'cron-validate';
|
|
33
|
+
import { CardTabs } from "../../layout/CardTabs";
|
|
34
|
+
import { AddonInput } from "../AddonInput";
|
|
35
|
+
import { ConsoleUtils } from "../../util/ConsoleUtils";
|
|
36
|
+
import { DesignUtils } from "../../util/DesignUtils";
|
|
37
|
+
import { StyleUtils } from "../../util/StyleUtils";
|
|
38
|
+
import { TriggerUtils } from "../../util/TriggerUtils";
|
|
39
|
+
import { CronInputContext } from "./context";
|
|
40
|
+
import { SecondPanel } from "./component/SecondPanel";
|
|
41
|
+
import { MinutePanel } from "./component/MinutePanel";
|
|
42
|
+
import { HourPanel } from "./component/HourPanel";
|
|
43
|
+
import { DayPanel } from "./component/DayPanel";
|
|
44
|
+
import { MonthPanel } from "./component/MonthPanel";
|
|
45
|
+
import { WeekPanel } from "./component/WeekPanel";
|
|
46
|
+
import { YearPanel } from "./component/YearPanel";
|
|
47
|
+
import { intlLocales } from "./locales";
|
|
48
|
+
import { useFieldStyle } from "./styles";
|
|
49
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
50
|
+
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
51
|
+
import { Fragment as _Fragment } from "react/jsx-runtime";
|
|
52
|
+
export var CronInput = /*#__PURE__*/React.forwardRef(function (props, ref) {
|
|
53
|
+
var _props$clazzPrefix, _props$tabsProps$claz, _props$tabsProps, _props$defaultShowSec, _props$defaultShowYea, _props$defaultOpen, _props$initialValue, _props$fieldProps, _props$proFieldProps, _props$fieldProps3, _props$proFieldProps2, _props$fieldProps4, _props$triggerProps$a, _props$triggerProps2, _props$triggerProps$b, _props$triggerProps3, _props$triggerProps5, _props$triggerProps6, _props$triggerProps7, _props$triggerProps8, _props$triggerProps$s, _props$triggerProps9;
|
|
54
|
+
CronInput.displayName = 'CronInput';
|
|
55
|
+
var configContext = React.useContext(ConfigProvider.ConfigContext);
|
|
56
|
+
var form = Form.useFormInstance();
|
|
57
|
+
var editContext = React.useContext(EditOrReadOnlyContext);
|
|
58
|
+
var clazzPrefix = (_props$clazzPrefix = props === null || props === void 0 ? void 0 : props.clazzPrefix) !== null && _props$clazzPrefix !== void 0 ? _props$clazzPrefix : 'abp-cron-input';
|
|
59
|
+
var subClazzPrefix = (_props$tabsProps$claz = props === null || props === void 0 || (_props$tabsProps = props.tabsProps) === null || _props$tabsProps === void 0 ? void 0 : _props$tabsProps.clazzPrefix) !== null && _props$tabsProps$claz !== void 0 ? _props$tabsProps$claz : 'abp-card-tabs';
|
|
60
|
+
var intlType = useIntl();
|
|
61
|
+
var _ref = props !== null && props !== void 0 ? props : {},
|
|
62
|
+
_ref$addon = _ref.addon,
|
|
63
|
+
addon = _ref$addon === void 0 ? /*#__PURE__*/_jsx(FieldTimeOutlined, {}) : _ref$addon,
|
|
64
|
+
_ref$addonPos = _ref.addonPos,
|
|
65
|
+
addonPos = _ref$addonPos === void 0 ? 'after' : _ref$addonPos,
|
|
66
|
+
_ref$allowSecond = _ref.allowSecond,
|
|
67
|
+
allowSecond = _ref$allowSecond === void 0 ? true : _ref$allowSecond,
|
|
68
|
+
_ref$allowYear = _ref.allowYear,
|
|
69
|
+
allowYear = _ref$allowYear === void 0 ? true : _ref$allowYear,
|
|
70
|
+
_ref$allowOkEcho = _ref.allowOkEcho,
|
|
71
|
+
allowOkEcho = _ref$allowOkEcho === void 0 ? true : _ref$allowOkEcho,
|
|
72
|
+
_ref$validateRule = _ref.validateRule,
|
|
73
|
+
validateRule = _ref$validateRule === void 0 ? true : _ref$validateRule,
|
|
74
|
+
_ref$proField = _ref.proField,
|
|
75
|
+
proField = _ref$proField === void 0 ? true : _ref$proField,
|
|
76
|
+
_ref$locale = _ref.locale,
|
|
77
|
+
locale = _ref$locale === void 0 ? intlType.locale : _ref$locale;
|
|
78
|
+
var _messageApi$useMessag = messageApi.useMessage(),
|
|
79
|
+
_messageApi$useMessag2 = _slicedToArray(_messageApi$useMessag, 2),
|
|
80
|
+
messageInvoker = _messageApi$useMessag2[0],
|
|
81
|
+
messageContext = _messageApi$useMessag2[1];
|
|
82
|
+
var _React$useState = React.useState(NanoidUtils.getPopularId()),
|
|
83
|
+
_React$useState2 = _slicedToArray(_React$useState, 1),
|
|
84
|
+
fieldId = _React$useState2[0];
|
|
85
|
+
var _React$useState3 = React.useState((_props$defaultShowSec = props === null || props === void 0 ? void 0 : props.defaultShowSecond) !== null && _props$defaultShowSec !== void 0 ? _props$defaultShowSec : false),
|
|
86
|
+
_React$useState4 = _slicedToArray(_React$useState3, 2),
|
|
87
|
+
showSecond = _React$useState4[0],
|
|
88
|
+
_setShowSecond = _React$useState4[1];
|
|
89
|
+
var _React$useState5 = React.useState((_props$defaultShowYea = props === null || props === void 0 ? void 0 : props.defaultShowYear) !== null && _props$defaultShowYea !== void 0 ? _props$defaultShowYea : false),
|
|
90
|
+
_React$useState6 = _slicedToArray(_React$useState5, 2),
|
|
91
|
+
showYear = _React$useState6[0],
|
|
92
|
+
_setShowYear = _React$useState6[1];
|
|
93
|
+
var _React$useState7 = React.useState((_props$defaultOpen = props === null || props === void 0 ? void 0 : props.defaultOpen) !== null && _props$defaultOpen !== void 0 ? _props$defaultOpen : false),
|
|
94
|
+
_React$useState8 = _slicedToArray(_React$useState7, 2),
|
|
95
|
+
triggerOpen = _React$useState8[0],
|
|
96
|
+
setTriggerOpen = _React$useState8[1];
|
|
97
|
+
var _React$useState9 = React.useState(4),
|
|
98
|
+
_React$useState10 = _slicedToArray(_React$useState9, 2),
|
|
99
|
+
triggerOffset = _React$useState10[0],
|
|
100
|
+
setTriggerOffset = _React$useState10[1];
|
|
101
|
+
var closeTimerRef = React.useRef(null);
|
|
102
|
+
var fieldStyle = useFieldStyle(clazzPrefix, subClazzPrefix);
|
|
103
|
+
React.useImperativeHandle(ref, function () {
|
|
104
|
+
return {
|
|
105
|
+
isShowSecond: function isShowSecond() {
|
|
106
|
+
return showSecond;
|
|
107
|
+
},
|
|
108
|
+
isShowYear: function isShowYear() {
|
|
109
|
+
return showYear;
|
|
110
|
+
},
|
|
111
|
+
setShowSecond: function setShowSecond(show) {
|
|
112
|
+
_setShowSecond(show);
|
|
113
|
+
},
|
|
114
|
+
setShowYear: function setShowYear(show) {
|
|
115
|
+
_setShowYear(show);
|
|
116
|
+
}
|
|
117
|
+
};
|
|
118
|
+
});
|
|
119
|
+
var secondPanelRef = React.useRef(null);
|
|
120
|
+
var minutePanelRef = React.useRef(null);
|
|
121
|
+
var hourPanelRef = React.useRef(null);
|
|
122
|
+
var dayPanelRef = React.useRef(null);
|
|
123
|
+
var monthPanelRef = React.useRef(null);
|
|
124
|
+
var weekPanelRef = React.useRef(null);
|
|
125
|
+
var yearPanelRef = React.useRef(null);
|
|
126
|
+
var _React$useState11 = React.useState(),
|
|
127
|
+
_React$useState12 = _slicedToArray(_React$useState11, 2),
|
|
128
|
+
secondExpress = _React$useState12[0],
|
|
129
|
+
setSecondExpress = _React$useState12[1];
|
|
130
|
+
var _React$useState13 = React.useState(),
|
|
131
|
+
_React$useState14 = _slicedToArray(_React$useState13, 2),
|
|
132
|
+
minuteExpress = _React$useState14[0],
|
|
133
|
+
setMinuteExpress = _React$useState14[1];
|
|
134
|
+
var _React$useState15 = React.useState(),
|
|
135
|
+
_React$useState16 = _slicedToArray(_React$useState15, 2),
|
|
136
|
+
hourExpress = _React$useState16[0],
|
|
137
|
+
setHourExpress = _React$useState16[1];
|
|
138
|
+
var _React$useState17 = React.useState(),
|
|
139
|
+
_React$useState18 = _slicedToArray(_React$useState17, 2),
|
|
140
|
+
dayExpress = _React$useState18[0],
|
|
141
|
+
setDayExpress = _React$useState18[1];
|
|
142
|
+
var _React$useState19 = React.useState(),
|
|
143
|
+
_React$useState20 = _slicedToArray(_React$useState19, 2),
|
|
144
|
+
monthExpress = _React$useState20[0],
|
|
145
|
+
setMonthExpress = _React$useState20[1];
|
|
146
|
+
var _React$useState21 = React.useState(),
|
|
147
|
+
_React$useState22 = _slicedToArray(_React$useState21, 2),
|
|
148
|
+
weekExpress = _React$useState22[0],
|
|
149
|
+
setWeekExpress = _React$useState22[1];
|
|
150
|
+
var _React$useState23 = React.useState(),
|
|
151
|
+
_React$useState24 = _slicedToArray(_React$useState23, 2),
|
|
152
|
+
yearExpress = _React$useState24[0],
|
|
153
|
+
setYearExpress = _React$useState24[1];
|
|
154
|
+
var _React$useState25 = React.useState((_props$initialValue = props === null || props === void 0 ? void 0 : props.initialValue) !== null && _props$initialValue !== void 0 ? _props$initialValue : props === null || props === void 0 || (_props$fieldProps = props.fieldProps) === null || _props$fieldProps === void 0 ? void 0 : _props$fieldProps.value),
|
|
155
|
+
_React$useState26 = _slicedToArray(_React$useState25, 2),
|
|
156
|
+
incomeExpress = _React$useState26[0],
|
|
157
|
+
setIncomeExpress = _React$useState26[1];
|
|
158
|
+
var outcomeExpresses = [secondExpress, minuteExpress, hourExpress, dayExpress, monthExpress, weekExpress, yearExpress];
|
|
159
|
+
var clearSubExpresses = function clearSubExpresses() {
|
|
160
|
+
setSecondExpress(undefined);
|
|
161
|
+
setMinuteExpress(undefined);
|
|
162
|
+
setHourExpress(undefined);
|
|
163
|
+
setDayExpress(undefined);
|
|
164
|
+
setMonthExpress(undefined);
|
|
165
|
+
setWeekExpress(undefined);
|
|
166
|
+
setYearExpress(undefined);
|
|
167
|
+
};
|
|
168
|
+
var validateOptions = {
|
|
169
|
+
override: {
|
|
170
|
+
useSeconds: allowSecond && showSecond,
|
|
171
|
+
useYears: allowYear && showYear,
|
|
172
|
+
useAliases: true,
|
|
173
|
+
useBlankDay: true,
|
|
174
|
+
useLastDayOfMonth: true,
|
|
175
|
+
useNearestWeekday: true,
|
|
176
|
+
useLastDayOfWeek: true,
|
|
177
|
+
useNthWeekdayOfMonth: true
|
|
178
|
+
}
|
|
179
|
+
};
|
|
180
|
+
var entryElementRef = React.useRef(null);
|
|
181
|
+
var updateTriggerOffset = React.useCallback(function () {
|
|
182
|
+
var _configContext$getPre;
|
|
183
|
+
if (!entryElementRef.current) {
|
|
184
|
+
return;
|
|
185
|
+
}
|
|
186
|
+
var prefixCls = (_configContext$getPre = configContext === null || configContext === void 0 ? void 0 : configContext.getPrefixCls('')) !== null && _configContext$getPre !== void 0 ? _configContext$getPre : 'ant';
|
|
187
|
+
var additionalHeight = DesignUtils.getFormAdditionalHeight(entryElementRef.current, prefixCls);
|
|
188
|
+
setTriggerOffset(4 - additionalHeight);
|
|
189
|
+
}, []);
|
|
190
|
+
useMutationObserver(updateTriggerOffset, entryElementRef, {
|
|
191
|
+
childList: true,
|
|
192
|
+
subtree: true
|
|
193
|
+
});
|
|
194
|
+
React.useEffect(function () {
|
|
195
|
+
var element = document.querySelector(".".concat(clazzPrefix, "-entry-").concat(fieldId));
|
|
196
|
+
if (!element) {
|
|
197
|
+
return;
|
|
198
|
+
}
|
|
199
|
+
entryElementRef.current = element;
|
|
200
|
+
updateTriggerOffset();
|
|
201
|
+
}, [clazzPrefix, fieldId]);
|
|
202
|
+
React.useEffect(function () {
|
|
203
|
+
if (!incomeExpress) {
|
|
204
|
+
clearSubExpresses();
|
|
205
|
+
return;
|
|
206
|
+
}
|
|
207
|
+
var validate = cronValidate(incomeExpress, validateOptions);
|
|
208
|
+
if (validate.isError()) {
|
|
209
|
+
var _props$name, _props$fieldProps2, _props$onValidateErro;
|
|
210
|
+
ConsoleUtils.warn(!(props !== null && props !== void 0 && props.echoValidateError), false, 'CronInput', "Field '".concat((_props$name = props === null || props === void 0 ? void 0 : props.name) !== null && _props$name !== void 0 ? _props$name : props === null || props === void 0 || (_props$fieldProps2 = props.fieldProps) === null || _props$fieldProps2 === void 0 ? void 0 : _props$fieldProps2.name, "' validation error: ").concat(validate.error.join('; ')));
|
|
211
|
+
clearSubExpresses();
|
|
212
|
+
props === null || props === void 0 || (_props$onValidateErro = props.onValidateError) === null || _props$onValidateErro === void 0 || _props$onValidateErro.call(props, incomeExpress, validate.error, true);
|
|
213
|
+
return;
|
|
214
|
+
}
|
|
215
|
+
var express = validate.getValue();
|
|
216
|
+
setSecondExpress(express.seconds);
|
|
217
|
+
setMinuteExpress(express.minutes);
|
|
218
|
+
setHourExpress(express.hours);
|
|
219
|
+
setDayExpress(express.daysOfMonth);
|
|
220
|
+
setMonthExpress(express.months);
|
|
221
|
+
setWeekExpress(express.daysOfWeek);
|
|
222
|
+
setYearExpress(express.years);
|
|
223
|
+
}, [incomeExpress]);
|
|
224
|
+
var entryImmutable = editContext.mode === 'read' || (props === null || props === void 0 || (_props$proFieldProps = props.proFieldProps) === null || _props$proFieldProps === void 0 ? void 0 : _props$proFieldProps.mode) === 'read' || (props === null || props === void 0 || (_props$fieldProps3 = props.fieldProps) === null || _props$fieldProps3 === void 0 ? void 0 : _props$fieldProps3.readOnly) || (props === null || props === void 0 || (_props$proFieldProps2 = props.proFieldProps) === null || _props$proFieldProps2 === void 0 ? void 0 : _props$proFieldProps2.readonly) || (props === null || props === void 0 ? void 0 : props.disabled) || (props === null || props === void 0 || (_props$fieldProps4 = props.fieldProps) === null || _props$fieldProps4 === void 0 ? void 0 : _props$fieldProps4.disabled);
|
|
225
|
+
var echoToEntry = function echoToEntry() {
|
|
226
|
+
if (entryImmutable) {
|
|
227
|
+
return;
|
|
228
|
+
}
|
|
229
|
+
var outcome = StringUtils.join(outcomeExpresses, ' ', function (item) {
|
|
230
|
+
return !!item;
|
|
231
|
+
});
|
|
232
|
+
if (!outcome) {
|
|
233
|
+
return;
|
|
234
|
+
}
|
|
235
|
+
var validate = cronValidate(outcome, validateOptions);
|
|
236
|
+
if (validate.isError()) {
|
|
237
|
+
var _props$name2, _props$fieldProps5, _props$onValidateErro2;
|
|
238
|
+
ConsoleUtils.warn(!(props !== null && props !== void 0 && props.echoValidateError), false, 'CronInput', "Field '".concat((_props$name2 = props === null || props === void 0 ? void 0 : props.name) !== null && _props$name2 !== void 0 ? _props$name2 : props === null || props === void 0 || (_props$fieldProps5 = props.fieldProps) === null || _props$fieldProps5 === void 0 ? void 0 : _props$fieldProps5.name, "' validation error: ").concat(validate.error.join('; ')));
|
|
239
|
+
props === null || props === void 0 || (_props$onValidateErro2 = props.onValidateError) === null || _props$onValidateErro2 === void 0 || _props$onValidateErro2.call(props, outcome, validate.error, false);
|
|
240
|
+
return;
|
|
241
|
+
}
|
|
242
|
+
var inspect = document.querySelector("[data-cron-input-id='".concat(fieldId, "']"));
|
|
243
|
+
ElementUtils.setElementValue(inspect, outcome);
|
|
244
|
+
};
|
|
245
|
+
React.useEffect(function () {
|
|
246
|
+
if (allowOkEcho) {
|
|
247
|
+
return;
|
|
248
|
+
}
|
|
249
|
+
echoToEntry();
|
|
250
|
+
}, [outcomeExpresses, showSecond, showYear]);
|
|
251
|
+
var addonEntryDom = typeof addon === 'function' ? addon() : addon;
|
|
252
|
+
var buildEntryAddonDom = function buildEntryAddonDom(before) {
|
|
253
|
+
return before && addonPos === 'before' || !before && addonPos === 'after' ? addonEntryDom : undefined;
|
|
254
|
+
};
|
|
255
|
+
var buildEntryDom = function buildEntryDom() {
|
|
256
|
+
var omitFieldProps = !(props !== null && props !== void 0 && props.fieldProps) ? {} : omit(props === null || props === void 0 ? void 0 : props.fieldProps, ['className', 'addonBefore', 'addonAfter', 'onChange']);
|
|
257
|
+
if (proField) {
|
|
258
|
+
var _props$className, _props$fieldProps6, _props$rules;
|
|
259
|
+
var restProps = !props ? {} : omit(props, ['fieldProps', 'proFieldProps', 'rules', 'clazzPrefix', 'addon', 'addonPos', 'allowSecond', 'allowYear', 'allowOkEcho', 'defaultOpen', 'defaultShowSecond', 'defaultShowYear', 'echoValidateError', 'triggerProps', 'tabsProps', 'secondPanelProps', 'minutePanelProps', 'hourPanelProps', 'dayPanelProps', 'monthPanelProps', 'weekPanelProps', 'yearPanelProps', 'validateRule', 'proField', 'locale', 'localeProps', 'onValidateError']);
|
|
260
|
+
return /*#__PURE__*/_jsx("div", {
|
|
261
|
+
className: clazzPrefix,
|
|
262
|
+
children: /*#__PURE__*/_jsx(AddonInput, _objectSpread({
|
|
263
|
+
addonBefore: buildEntryAddonDom(true),
|
|
264
|
+
addonAfter: buildEntryAddonDom(false),
|
|
265
|
+
cursorBefore: addonPos === 'before' ? 'pointer' : undefined,
|
|
266
|
+
cursorAfter: addonPos === 'after' ? 'pointer' : undefined,
|
|
267
|
+
fieldProps: _objectSpread(_objectSpread({
|
|
268
|
+
className: classnames("".concat(clazzPrefix, "-entry-").concat(fieldId), (_props$className = props === null || props === void 0 ? void 0 : props.className) !== null && _props$className !== void 0 ? _props$className : props === null || props === void 0 || (_props$fieldProps6 = props.fieldProps) === null || _props$fieldProps6 === void 0 ? void 0 : _props$fieldProps6.className)
|
|
269
|
+
}, omitFieldProps), {}, {
|
|
270
|
+
onChange: function onChange(event) {
|
|
271
|
+
var _props$fieldProps7, _props$fieldProps7$on;
|
|
272
|
+
props === null || props === void 0 || (_props$fieldProps7 = props.fieldProps) === null || _props$fieldProps7 === void 0 || (_props$fieldProps7$on = _props$fieldProps7.onChange) === null || _props$fieldProps7$on === void 0 || _props$fieldProps7$on.call(_props$fieldProps7, event);
|
|
273
|
+
if (!event.isDefaultPrevented()) {
|
|
274
|
+
setIncomeExpress(event.target.value);
|
|
275
|
+
}
|
|
276
|
+
},
|
|
277
|
+
'data-cron-input-id': fieldId
|
|
278
|
+
}),
|
|
279
|
+
proField: proField,
|
|
280
|
+
rules: [].concat(_toConsumableArray((_props$rules = props === null || props === void 0 ? void 0 : props.rules) !== null && _props$rules !== void 0 ? _props$rules : []), [!validateRule ? {} : {
|
|
281
|
+
validator: function () {
|
|
282
|
+
var _validator = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(_rule, value) {
|
|
283
|
+
var _props$localeProps2;
|
|
284
|
+
var validate, _props$localeProps;
|
|
285
|
+
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
286
|
+
while (1) switch (_context.prev = _context.next) {
|
|
287
|
+
case 0:
|
|
288
|
+
if (value) {
|
|
289
|
+
_context.next = 2;
|
|
290
|
+
break;
|
|
291
|
+
}
|
|
292
|
+
return _context.abrupt("return", undefined);
|
|
293
|
+
case 2:
|
|
294
|
+
validate = cronValidate(value, validateOptions);
|
|
295
|
+
if (!validate.isValid()) {
|
|
296
|
+
_context.next = 5;
|
|
297
|
+
break;
|
|
298
|
+
}
|
|
299
|
+
return _context.abrupt("return", Promise.resolve(ObjectUtils.firstNotNil(props === null || props === void 0 || (_props$localeProps = props.localeProps) === null || _props$localeProps === void 0 ? void 0 : _props$localeProps.validExpress, intlLocales.get([locale, 'validExpress']), intlLocales.get(['en_US', 'validExpress']))));
|
|
300
|
+
case 5:
|
|
301
|
+
return _context.abrupt("return", Promise.reject(ObjectUtils.firstNotNil(props === null || props === void 0 || (_props$localeProps2 = props.localeProps) === null || _props$localeProps2 === void 0 ? void 0 : _props$localeProps2.invalidExpress, intlLocales.get([locale, 'invalidExpress']), intlLocales.get(['en_US', 'invalidExpress']))));
|
|
302
|
+
case 6:
|
|
303
|
+
case "end":
|
|
304
|
+
return _context.stop();
|
|
305
|
+
}
|
|
306
|
+
}, _callee);
|
|
307
|
+
}));
|
|
308
|
+
function validator(_x, _x2) {
|
|
309
|
+
return _validator.apply(this, arguments);
|
|
310
|
+
}
|
|
311
|
+
return validator;
|
|
312
|
+
}()
|
|
313
|
+
}])
|
|
314
|
+
}, restProps))
|
|
315
|
+
});
|
|
316
|
+
} else {
|
|
317
|
+
var _props$className2, _props$fieldProps8, _StringUtils$join, _props$fieldProps9;
|
|
318
|
+
var _restProps = omit(omitFieldProps, ['placeholder']);
|
|
319
|
+
return /*#__PURE__*/_jsx("div", {
|
|
320
|
+
className: clazzPrefix,
|
|
321
|
+
children: /*#__PURE__*/_jsxs(Space.Compact, {
|
|
322
|
+
className: "".concat(clazzPrefix, "-space"),
|
|
323
|
+
style: {
|
|
324
|
+
width: '100%'
|
|
325
|
+
},
|
|
326
|
+
children: [addonPos === 'before' && /*#__PURE__*/_jsx(Space.Addon, {
|
|
327
|
+
className: "".concat(clazzPrefix, "-compact-before"),
|
|
328
|
+
style: {
|
|
329
|
+
cursor: 'pointer'
|
|
330
|
+
},
|
|
331
|
+
children: buildEntryAddonDom(true)
|
|
332
|
+
}), /*#__PURE__*/_jsx(Input, _objectSpread(_objectSpread({
|
|
333
|
+
className: classnames("".concat(clazzPrefix, "-entry-").concat(fieldId), (_props$className2 = props === null || props === void 0 ? void 0 : props.className) !== null && _props$className2 !== void 0 ? _props$className2 : props === null || props === void 0 || (_props$fieldProps8 = props.fieldProps) === null || _props$fieldProps8 === void 0 ? void 0 : _props$fieldProps8.className),
|
|
334
|
+
placeholder: (_StringUtils$join = StringUtils.join(props === null || props === void 0 ? void 0 : props.placeholder)) !== null && _StringUtils$join !== void 0 ? _StringUtils$join : props === null || props === void 0 || (_props$fieldProps9 = props.fieldProps) === null || _props$fieldProps9 === void 0 ? void 0 : _props$fieldProps9.placeholder,
|
|
335
|
+
"data-cron-input-id": fieldId
|
|
336
|
+
}, _restProps), {}, {
|
|
337
|
+
onChange: function onChange(event) {
|
|
338
|
+
var _props$fieldProps10, _props$fieldProps10$o;
|
|
339
|
+
props === null || props === void 0 || (_props$fieldProps10 = props.fieldProps) === null || _props$fieldProps10 === void 0 || (_props$fieldProps10$o = _props$fieldProps10.onChange) === null || _props$fieldProps10$o === void 0 || _props$fieldProps10$o.call(_props$fieldProps10, event);
|
|
340
|
+
if (event.isDefaultPrevented()) {
|
|
341
|
+
return;
|
|
342
|
+
}
|
|
343
|
+
if (validateRule && !!event.target.value) {
|
|
344
|
+
var validate = cronValidate(event.target.value, validateOptions);
|
|
345
|
+
if (validate.isError()) {
|
|
346
|
+
var _props$localeProps3;
|
|
347
|
+
messageInvoker.warning(ObjectUtils.firstNotNil(props === null || props === void 0 || (_props$localeProps3 = props.localeProps) === null || _props$localeProps3 === void 0 ? void 0 : _props$localeProps3.invalidExpress, intlLocales.get([locale, 'invalidExpress']), intlLocales.get(['en_US', 'invalidExpress'])));
|
|
348
|
+
}
|
|
349
|
+
}
|
|
350
|
+
setIncomeExpress(event.target.value);
|
|
351
|
+
}
|
|
352
|
+
}, omitFieldProps)), addonPos === 'after' && /*#__PURE__*/_jsx(Space.Addon, {
|
|
353
|
+
className: "".concat(clazzPrefix, "-compact-after"),
|
|
354
|
+
style: {
|
|
355
|
+
cursor: 'pointer'
|
|
356
|
+
},
|
|
357
|
+
children: buildEntryAddonDom(false)
|
|
358
|
+
})]
|
|
359
|
+
})
|
|
360
|
+
});
|
|
361
|
+
}
|
|
362
|
+
};
|
|
363
|
+
if (entryImmutable) {
|
|
364
|
+
return buildEntryDom();
|
|
365
|
+
}
|
|
366
|
+
var handleWindowResize = function handleWindowResize() {
|
|
367
|
+
var inspect = document.querySelector(".".concat(clazzPrefix, "-entry-").concat(fieldId));
|
|
368
|
+
var sponsor = document.querySelector(".".concat(clazzPrefix, "-popup-").concat(fieldId));
|
|
369
|
+
if (inspect && sponsor) {
|
|
370
|
+
StyleUtils.addStyle(sponsor, 'width', "".concat(inspect.offsetWidth, "px"));
|
|
371
|
+
StyleUtils.addStyle(sponsor, 'min-width', "".concat(inspect.offsetWidth, "px"));
|
|
372
|
+
}
|
|
373
|
+
};
|
|
374
|
+
useEventListener('resize', handleWindowResize);
|
|
375
|
+
var buildPopupDom = function buildPopupDom() {
|
|
376
|
+
var _props$localeProps4, _props$minutePanelPro3, _props$minutePanelPro4, _props$localeProps5, _props$hourPanelProps3, _props$hourPanelProps4, _props$localeProps6, _props$dayPanelProps$2, _props$dayPanelProps2, _props$localeProps7, _props$monthPanelProp3, _props$monthPanelProp4, _props$localeProps8, _props$weekPanelProps3, _props$weekPanelProps4, _props$tabsProps$defa, _props$tabsProps2, _props$tabsProps$size, _props$tabsProps3, _props$tabsProps4, _props$localeProps11, _props$localeProps12, _props$localeProps13, _props$localeProps14, _props$localeProps15;
|
|
377
|
+
var tabItems = [{
|
|
378
|
+
key: 'minute',
|
|
379
|
+
label: ObjectUtils.firstNotNil(props === null || props === void 0 || (_props$localeProps4 = props.localeProps) === null || _props$localeProps4 === void 0 ? void 0 : _props$localeProps4.minute, intlLocales.get([locale, 'minute']), intlLocales.get(['en_US', 'minute'])),
|
|
380
|
+
children: /*#__PURE__*/_jsx(MinutePanel, _objectSpread({
|
|
381
|
+
ref: minutePanelRef,
|
|
382
|
+
disabled: entryImmutable,
|
|
383
|
+
value: minuteExpress,
|
|
384
|
+
onChange: function onChange(value) {
|
|
385
|
+
var _props$minutePanelPro, _props$minutePanelPro2;
|
|
386
|
+
setMinuteExpress(value);
|
|
387
|
+
props === null || props === void 0 || (_props$minutePanelPro = props.minutePanelProps) === null || _props$minutePanelPro === void 0 || (_props$minutePanelPro2 = _props$minutePanelPro.onChange) === null || _props$minutePanelPro2 === void 0 || _props$minutePanelPro2.call(_props$minutePanelPro, value);
|
|
388
|
+
},
|
|
389
|
+
locale: (_props$minutePanelPro3 = props === null || props === void 0 || (_props$minutePanelPro4 = props.minutePanelProps) === null || _props$minutePanelPro4 === void 0 ? void 0 : _props$minutePanelPro4.locale) !== null && _props$minutePanelPro3 !== void 0 ? _props$minutePanelPro3 : props === null || props === void 0 ? void 0 : props.locale
|
|
390
|
+
}, !(props !== null && props !== void 0 && props.minutePanelProps) ? {} : omit(props.minutePanelProps, ['value', 'onChange', 'locale'])))
|
|
391
|
+
}, {
|
|
392
|
+
key: 'hour',
|
|
393
|
+
label: ObjectUtils.firstNotNil(props === null || props === void 0 || (_props$localeProps5 = props.localeProps) === null || _props$localeProps5 === void 0 ? void 0 : _props$localeProps5.hour, intlLocales.get([locale, 'hour']), intlLocales.get(['en_US', 'hour'])),
|
|
394
|
+
children: /*#__PURE__*/_jsx(HourPanel, _objectSpread({
|
|
395
|
+
ref: hourPanelRef,
|
|
396
|
+
disabled: entryImmutable,
|
|
397
|
+
value: hourExpress,
|
|
398
|
+
onChange: function onChange(value) {
|
|
399
|
+
var _props$hourPanelProps, _props$hourPanelProps2;
|
|
400
|
+
setHourExpress(value);
|
|
401
|
+
props === null || props === void 0 || (_props$hourPanelProps = props.hourPanelProps) === null || _props$hourPanelProps === void 0 || (_props$hourPanelProps2 = _props$hourPanelProps.onChange) === null || _props$hourPanelProps2 === void 0 || _props$hourPanelProps2.call(_props$hourPanelProps, value);
|
|
402
|
+
},
|
|
403
|
+
locale: (_props$hourPanelProps3 = props === null || props === void 0 || (_props$hourPanelProps4 = props.hourPanelProps) === null || _props$hourPanelProps4 === void 0 ? void 0 : _props$hourPanelProps4.locale) !== null && _props$hourPanelProps3 !== void 0 ? _props$hourPanelProps3 : props === null || props === void 0 ? void 0 : props.locale
|
|
404
|
+
}, !(props !== null && props !== void 0 && props.hourPanelProps) ? {} : omit(props.hourPanelProps, ['value', 'onChange', 'locale'])))
|
|
405
|
+
}, {
|
|
406
|
+
key: 'day',
|
|
407
|
+
label: ObjectUtils.firstNotNil(props === null || props === void 0 || (_props$localeProps6 = props.localeProps) === null || _props$localeProps6 === void 0 ? void 0 : _props$localeProps6.day, intlLocales.get([locale, 'day']), intlLocales.get(['en_US', 'day'])),
|
|
408
|
+
children: /*#__PURE__*/_jsx(DayPanel, _objectSpread({
|
|
409
|
+
ref: dayPanelRef,
|
|
410
|
+
disabled: entryImmutable,
|
|
411
|
+
value: dayExpress,
|
|
412
|
+
onChange: function onChange(value) {
|
|
413
|
+
var _props$dayPanelProps, _props$dayPanelProps$;
|
|
414
|
+
setDayExpress(value);
|
|
415
|
+
props === null || props === void 0 || (_props$dayPanelProps = props.dayPanelProps) === null || _props$dayPanelProps === void 0 || (_props$dayPanelProps$ = _props$dayPanelProps.onChange) === null || _props$dayPanelProps$ === void 0 || _props$dayPanelProps$.call(_props$dayPanelProps, value);
|
|
416
|
+
},
|
|
417
|
+
locale: (_props$dayPanelProps$2 = props === null || props === void 0 || (_props$dayPanelProps2 = props.dayPanelProps) === null || _props$dayPanelProps2 === void 0 ? void 0 : _props$dayPanelProps2.locale) !== null && _props$dayPanelProps$2 !== void 0 ? _props$dayPanelProps$2 : props === null || props === void 0 ? void 0 : props.locale
|
|
418
|
+
}, !(props !== null && props !== void 0 && props.dayPanelProps) ? {} : omit(props.dayPanelProps, ['value', 'onChange', 'locale'])))
|
|
419
|
+
}, {
|
|
420
|
+
key: 'month',
|
|
421
|
+
label: ObjectUtils.firstNotNil(props === null || props === void 0 || (_props$localeProps7 = props.localeProps) === null || _props$localeProps7 === void 0 ? void 0 : _props$localeProps7.month, intlLocales.get([locale, 'month']), intlLocales.get(['en_US', 'month'])),
|
|
422
|
+
children: /*#__PURE__*/_jsx(MonthPanel, _objectSpread({
|
|
423
|
+
ref: monthPanelRef,
|
|
424
|
+
disabled: entryImmutable,
|
|
425
|
+
value: monthExpress,
|
|
426
|
+
onChange: function onChange(value) {
|
|
427
|
+
var _props$monthPanelProp, _props$monthPanelProp2;
|
|
428
|
+
setMonthExpress(value);
|
|
429
|
+
props === null || props === void 0 || (_props$monthPanelProp = props.monthPanelProps) === null || _props$monthPanelProp === void 0 || (_props$monthPanelProp2 = _props$monthPanelProp.onChange) === null || _props$monthPanelProp2 === void 0 || _props$monthPanelProp2.call(_props$monthPanelProp, value);
|
|
430
|
+
},
|
|
431
|
+
locale: (_props$monthPanelProp3 = props === null || props === void 0 || (_props$monthPanelProp4 = props.monthPanelProps) === null || _props$monthPanelProp4 === void 0 ? void 0 : _props$monthPanelProp4.locale) !== null && _props$monthPanelProp3 !== void 0 ? _props$monthPanelProp3 : props === null || props === void 0 ? void 0 : props.locale
|
|
432
|
+
}, !(props !== null && props !== void 0 && props.monthPanelProps) ? {} : omit(props.monthPanelProps, ['value', 'onChange', 'locale'])))
|
|
433
|
+
}, {
|
|
434
|
+
key: 'week',
|
|
435
|
+
label: ObjectUtils.firstNotNil(props === null || props === void 0 || (_props$localeProps8 = props.localeProps) === null || _props$localeProps8 === void 0 ? void 0 : _props$localeProps8.week, intlLocales.get([locale, 'week']), intlLocales.get(['en_US', 'week'])),
|
|
436
|
+
children: /*#__PURE__*/_jsx(WeekPanel, _objectSpread({
|
|
437
|
+
ref: weekPanelRef,
|
|
438
|
+
disabled: entryImmutable,
|
|
439
|
+
value: weekExpress,
|
|
440
|
+
onChange: function onChange(value) {
|
|
441
|
+
var _props$weekPanelProps, _props$weekPanelProps2;
|
|
442
|
+
setWeekExpress(value);
|
|
443
|
+
props === null || props === void 0 || (_props$weekPanelProps = props.weekPanelProps) === null || _props$weekPanelProps === void 0 || (_props$weekPanelProps2 = _props$weekPanelProps.onChange) === null || _props$weekPanelProps2 === void 0 || _props$weekPanelProps2.call(_props$weekPanelProps, value);
|
|
444
|
+
},
|
|
445
|
+
locale: (_props$weekPanelProps3 = props === null || props === void 0 || (_props$weekPanelProps4 = props.weekPanelProps) === null || _props$weekPanelProps4 === void 0 ? void 0 : _props$weekPanelProps4.locale) !== null && _props$weekPanelProps3 !== void 0 ? _props$weekPanelProps3 : props === null || props === void 0 ? void 0 : props.locale
|
|
446
|
+
}, !(props !== null && props !== void 0 && props.weekPanelProps) ? {} : omit(props.weekPanelProps, ['value', 'onChange', 'locale'])))
|
|
447
|
+
}];
|
|
448
|
+
if (allowSecond && showSecond) {
|
|
449
|
+
var _props$localeProps9, _props$secondPanelPro3, _props$secondPanelPro4;
|
|
450
|
+
tabItems.unshift({
|
|
451
|
+
key: 'second',
|
|
452
|
+
label: ObjectUtils.firstNotNil(props === null || props === void 0 || (_props$localeProps9 = props.localeProps) === null || _props$localeProps9 === void 0 ? void 0 : _props$localeProps9.second, intlLocales.get([locale, 'second']), intlLocales.get(['en_US', 'second'])),
|
|
453
|
+
children: /*#__PURE__*/_jsx(SecondPanel, _objectSpread({
|
|
454
|
+
ref: secondPanelRef,
|
|
455
|
+
disabled: entryImmutable,
|
|
456
|
+
value: secondExpress,
|
|
457
|
+
onChange: function onChange(value) {
|
|
458
|
+
var _props$secondPanelPro, _props$secondPanelPro2;
|
|
459
|
+
setSecondExpress(value);
|
|
460
|
+
props === null || props === void 0 || (_props$secondPanelPro = props.secondPanelProps) === null || _props$secondPanelPro === void 0 || (_props$secondPanelPro2 = _props$secondPanelPro.onChange) === null || _props$secondPanelPro2 === void 0 || _props$secondPanelPro2.call(_props$secondPanelPro, value);
|
|
461
|
+
},
|
|
462
|
+
locale: (_props$secondPanelPro3 = props === null || props === void 0 || (_props$secondPanelPro4 = props.secondPanelProps) === null || _props$secondPanelPro4 === void 0 ? void 0 : _props$secondPanelPro4.locale) !== null && _props$secondPanelPro3 !== void 0 ? _props$secondPanelPro3 : props === null || props === void 0 ? void 0 : props.locale
|
|
463
|
+
}, !(props !== null && props !== void 0 && props.secondPanelProps) ? {} : omit(props.secondPanelProps, ['value', 'onChange', 'locale'])))
|
|
464
|
+
});
|
|
465
|
+
}
|
|
466
|
+
if (allowYear && showYear) {
|
|
467
|
+
var _props$localeProps10, _props$yearPanelProps3, _props$yearPanelProps4;
|
|
468
|
+
tabItems.push({
|
|
469
|
+
key: 'year',
|
|
470
|
+
label: ObjectUtils.firstNotNil(props === null || props === void 0 || (_props$localeProps10 = props.localeProps) === null || _props$localeProps10 === void 0 ? void 0 : _props$localeProps10.year, intlLocales.get([locale, 'year']), intlLocales.get(['en_US', 'year'])),
|
|
471
|
+
children: /*#__PURE__*/_jsx(YearPanel, _objectSpread({
|
|
472
|
+
ref: yearPanelRef,
|
|
473
|
+
disabled: entryImmutable,
|
|
474
|
+
value: yearExpress,
|
|
475
|
+
onChange: function onChange(value) {
|
|
476
|
+
var _props$yearPanelProps, _props$yearPanelProps2;
|
|
477
|
+
setYearExpress(value);
|
|
478
|
+
props === null || props === void 0 || (_props$yearPanelProps = props.yearPanelProps) === null || _props$yearPanelProps === void 0 || (_props$yearPanelProps2 = _props$yearPanelProps.onChange) === null || _props$yearPanelProps2 === void 0 || _props$yearPanelProps2.call(_props$yearPanelProps, value);
|
|
479
|
+
},
|
|
480
|
+
locale: (_props$yearPanelProps3 = props === null || props === void 0 || (_props$yearPanelProps4 = props.yearPanelProps) === null || _props$yearPanelProps4 === void 0 ? void 0 : _props$yearPanelProps4.locale) !== null && _props$yearPanelProps3 !== void 0 ? _props$yearPanelProps3 : props === null || props === void 0 ? void 0 : props.locale
|
|
481
|
+
}, !(props !== null && props !== void 0 && props.yearPanelProps) ? {} : omit(props.yearPanelProps, ['value', 'onChange', 'locale'])))
|
|
482
|
+
});
|
|
483
|
+
}
|
|
484
|
+
var omitTabsProps = !(props !== null && props !== void 0 && props.tabsProps) ? {} : omit(props.tabsProps, ['defaultActiveKey', 'size', 'tabBarExtraContent']);
|
|
485
|
+
return /*#__PURE__*/_jsx("div", {
|
|
486
|
+
onMouseEnter: function onMouseEnter() {
|
|
487
|
+
if (closeTimerRef.current) {
|
|
488
|
+
clearTimeout(closeTimerRef.current);
|
|
489
|
+
closeTimerRef.current = null;
|
|
490
|
+
}
|
|
491
|
+
},
|
|
492
|
+
onMouseLeave: function onMouseLeave() {
|
|
493
|
+
if (closeTimerRef.current) {
|
|
494
|
+
clearTimeout(closeTimerRef.current);
|
|
495
|
+
}
|
|
496
|
+
closeTimerRef.current = setTimeout(function () {
|
|
497
|
+
var _props$triggerProps, _props$triggerProps$o;
|
|
498
|
+
setTriggerOpen(false);
|
|
499
|
+
props === null || props === void 0 || (_props$triggerProps = props.triggerProps) === null || _props$triggerProps === void 0 || (_props$triggerProps$o = _props$triggerProps.onOpenChange) === null || _props$triggerProps$o === void 0 || _props$triggerProps$o.call(_props$triggerProps, false);
|
|
500
|
+
}, 200);
|
|
501
|
+
},
|
|
502
|
+
children: /*#__PURE__*/_jsx(CronInputContext.Provider, {
|
|
503
|
+
value: {
|
|
504
|
+
fieldId: fieldId,
|
|
505
|
+
allowOkEcho: allowOkEcho,
|
|
506
|
+
popupOpen: triggerOpen
|
|
507
|
+
},
|
|
508
|
+
children: /*#__PURE__*/_jsx(CardTabs, _objectSpread({
|
|
509
|
+
items: tabItems,
|
|
510
|
+
defaultActiveKey: (_props$tabsProps$defa = props === null || props === void 0 || (_props$tabsProps2 = props.tabsProps) === null || _props$tabsProps2 === void 0 ? void 0 : _props$tabsProps2.defaultActiveKey) !== null && _props$tabsProps$defa !== void 0 ? _props$tabsProps$defa : 'minute',
|
|
511
|
+
size: (_props$tabsProps$size = props === null || props === void 0 || (_props$tabsProps3 = props.tabsProps) === null || _props$tabsProps3 === void 0 ? void 0 : _props$tabsProps3.size) !== null && _props$tabsProps$size !== void 0 ? _props$tabsProps$size : 'extra-small',
|
|
512
|
+
tabBarExtraContent: /*#__PURE__*/_jsxs(_Fragment, {
|
|
513
|
+
children: [props === null || props === void 0 || (_props$tabsProps4 = props.tabsProps) === null || _props$tabsProps4 === void 0 ? void 0 : _props$tabsProps4.tabBarExtraContent, /*#__PURE__*/_jsx(If, {
|
|
514
|
+
condition: allowSecond || allowYear || allowOkEcho,
|
|
515
|
+
validation: false,
|
|
516
|
+
children: /*#__PURE__*/_jsx("div", {
|
|
517
|
+
className: "".concat(clazzPrefix, "-tabs-extra"),
|
|
518
|
+
children: /*#__PURE__*/_jsxs(Space, {
|
|
519
|
+
size: 'middle',
|
|
520
|
+
children: [/*#__PURE__*/_jsx(If, {
|
|
521
|
+
condition: allowSecond && !entryImmutable,
|
|
522
|
+
validation: false,
|
|
523
|
+
children: /*#__PURE__*/_jsx(Switch, {
|
|
524
|
+
checked: showSecond,
|
|
525
|
+
size: "small",
|
|
526
|
+
checkedChildren: ObjectUtils.firstNotNil(props === null || props === void 0 || (_props$localeProps11 = props.localeProps) === null || _props$localeProps11 === void 0 ? void 0 : _props$localeProps11.second, intlLocales.get([locale, 'second']), intlLocales.get(['en_US', 'second'])),
|
|
527
|
+
unCheckedChildren: ObjectUtils.firstNotNil(props === null || props === void 0 || (_props$localeProps12 = props.localeProps) === null || _props$localeProps12 === void 0 ? void 0 : _props$localeProps12.second, intlLocales.get([locale, 'second']), intlLocales.get(['en_US', 'second'])),
|
|
528
|
+
onChange: function onChange(checked) {
|
|
529
|
+
var _props$name3, _props$fieldProps11;
|
|
530
|
+
_setShowSecond(checked);
|
|
531
|
+
var rawName = (_props$name3 = props === null || props === void 0 ? void 0 : props.name) !== null && _props$name3 !== void 0 ? _props$name3 : props === null || props === void 0 || (_props$fieldProps11 = props.fieldProps) === null || _props$fieldProps11 === void 0 ? void 0 : _props$fieldProps11.name;
|
|
532
|
+
if (validateRule && rawName && form && form.getFieldValue(rawName)) {
|
|
533
|
+
form.validateFields([rawName]);
|
|
534
|
+
}
|
|
535
|
+
}
|
|
536
|
+
})
|
|
537
|
+
}), /*#__PURE__*/_jsx(If, {
|
|
538
|
+
condition: allowYear && !entryImmutable,
|
|
539
|
+
validation: false,
|
|
540
|
+
children: /*#__PURE__*/_jsx(Switch, {
|
|
541
|
+
checked: showYear,
|
|
542
|
+
size: "small",
|
|
543
|
+
checkedChildren: ObjectUtils.firstNotNil(props === null || props === void 0 || (_props$localeProps13 = props.localeProps) === null || _props$localeProps13 === void 0 ? void 0 : _props$localeProps13.year, intlLocales.get([locale, 'year']), intlLocales.get(['en_US', 'year'])),
|
|
544
|
+
unCheckedChildren: ObjectUtils.firstNotNil(props === null || props === void 0 || (_props$localeProps14 = props.localeProps) === null || _props$localeProps14 === void 0 ? void 0 : _props$localeProps14.year, intlLocales.get([locale, 'year']), intlLocales.get(['en_US', 'year'])),
|
|
545
|
+
onChange: function onChange(checked) {
|
|
546
|
+
var _props$name4, _props$fieldProps12;
|
|
547
|
+
_setShowYear(checked);
|
|
548
|
+
var rawName = (_props$name4 = props === null || props === void 0 ? void 0 : props.name) !== null && _props$name4 !== void 0 ? _props$name4 : props === null || props === void 0 || (_props$fieldProps12 = props.fieldProps) === null || _props$fieldProps12 === void 0 ? void 0 : _props$fieldProps12.name;
|
|
549
|
+
if (validateRule && rawName && form && form.getFieldValue(rawName)) {
|
|
550
|
+
form.validateFields([rawName]);
|
|
551
|
+
}
|
|
552
|
+
}
|
|
553
|
+
})
|
|
554
|
+
}), /*#__PURE__*/_jsx(If, {
|
|
555
|
+
condition: allowOkEcho && !entryImmutable,
|
|
556
|
+
validation: false,
|
|
557
|
+
children: /*#__PURE__*/_jsx(Button, {
|
|
558
|
+
className: "".concat(clazzPrefix, "-ok-echo"),
|
|
559
|
+
size: "small",
|
|
560
|
+
type: "primary",
|
|
561
|
+
onClick: function onClick() {
|
|
562
|
+
echoToEntry();
|
|
563
|
+
setTriggerOpen(false);
|
|
564
|
+
},
|
|
565
|
+
children: ObjectUtils.firstNotNil(props === null || props === void 0 || (_props$localeProps15 = props.localeProps) === null || _props$localeProps15 === void 0 ? void 0 : _props$localeProps15.ok, intlLocales.get([locale, 'ok']), intlLocales.get(['en_US', 'ok']))
|
|
566
|
+
})
|
|
567
|
+
})]
|
|
568
|
+
})
|
|
569
|
+
})
|
|
570
|
+
})]
|
|
571
|
+
})
|
|
572
|
+
}, omitTabsProps))
|
|
573
|
+
})
|
|
574
|
+
});
|
|
575
|
+
};
|
|
576
|
+
var omitTriggerProps = !(props !== null && props !== void 0 && props.triggerProps) ? {} : omit(props === null || props === void 0 ? void 0 : props.triggerProps, ['action', 'builtinPlacements', 'getPopupContainer', 'popupAlign', 'popupClassName', 'stretch', 'onOpenChange']);
|
|
577
|
+
return /*#__PURE__*/_jsxs(_Fragment, {
|
|
578
|
+
children: [messageContext, /*#__PURE__*/_jsx(Trigger, _objectSpread(_objectSpread({
|
|
579
|
+
action: (_props$triggerProps$a = props === null || props === void 0 || (_props$triggerProps2 = props.triggerProps) === null || _props$triggerProps2 === void 0 ? void 0 : _props$triggerProps2.action) !== null && _props$triggerProps$a !== void 0 ? _props$triggerProps$a : entryImmutable ? ['hover'] : ['click'],
|
|
580
|
+
builtinPlacements: (_props$triggerProps$b = props === null || props === void 0 || (_props$triggerProps3 = props.triggerProps) === null || _props$triggerProps3 === void 0 ? void 0 : _props$triggerProps3.builtinPlacements) !== null && _props$triggerProps$b !== void 0 ? _props$triggerProps$b : TriggerUtils.buildPlacements(),
|
|
581
|
+
getPopupContainer: function getPopupContainer(trigger) {
|
|
582
|
+
var _props$triggerProps4, _props$triggerProps4$, _trigger$closest;
|
|
583
|
+
return (props === null || props === void 0 || (_props$triggerProps4 = props.triggerProps) === null || _props$triggerProps4 === void 0 || (_props$triggerProps4$ = _props$triggerProps4.getPopupContainer) === null || _props$triggerProps4$ === void 0 ? void 0 : _props$triggerProps4$.call(_props$triggerProps4, trigger)) || (trigger === null || trigger === void 0 || (_trigger$closest = trigger.closest('form')) === null || _trigger$closest === void 0 ? void 0 : _trigger$closest.parentElement) || document.body;
|
|
584
|
+
},
|
|
585
|
+
popup: buildPopupDom(),
|
|
586
|
+
popupAlign: props !== null && props !== void 0 && (_props$triggerProps5 = props.triggerProps) !== null && _props$triggerProps5 !== void 0 && _props$triggerProps5.popupPlacement || props !== null && props !== void 0 && (_props$triggerProps6 = props.triggerProps) !== null && _props$triggerProps6 !== void 0 && _props$triggerProps6.popupAlign ? props === null || props === void 0 || (_props$triggerProps7 = props.triggerProps) === null || _props$triggerProps7 === void 0 ? void 0 : _props$triggerProps7.popupAlign : {
|
|
587
|
+
points: ['tl', 'bl'],
|
|
588
|
+
offset: [0, triggerOffset]
|
|
589
|
+
},
|
|
590
|
+
popupClassName: classnames("".concat(clazzPrefix, "-popup"), fieldStyle.hashId, "".concat(clazzPrefix, "-popup-").concat(fieldId), !entryImmutable ? undefined : "".concat(clazzPrefix, "-popup-immutable"), props === null || props === void 0 || (_props$triggerProps8 = props.triggerProps) === null || _props$triggerProps8 === void 0 ? void 0 : _props$triggerProps8.popupClassName),
|
|
591
|
+
popupVisible: triggerOpen,
|
|
592
|
+
stretch: (_props$triggerProps$s = props === null || props === void 0 || (_props$triggerProps9 = props.triggerProps) === null || _props$triggerProps9 === void 0 ? void 0 : _props$triggerProps9.stretch) !== null && _props$triggerProps$s !== void 0 ? _props$triggerProps$s : 'width',
|
|
593
|
+
onOpenChange: function onOpenChange(open) {
|
|
594
|
+
var _secondPanelRef$curre, _minutePanelRef$curre, _hourPanelRef$current, _dayPanelRef$current, _monthPanelRef$curren, _weekPanelRef$current, _yearPanelRef$current, _props$triggerProps10, _props$triggerProps11;
|
|
595
|
+
if (!open && ((_secondPanelRef$curre = secondPanelRef.current) !== null && _secondPanelRef$curre !== void 0 && _secondPanelRef$curre.isCompositing() || (_minutePanelRef$curre = minutePanelRef.current) !== null && _minutePanelRef$curre !== void 0 && _minutePanelRef$curre.isCompositing() || (_hourPanelRef$current = hourPanelRef.current) !== null && _hourPanelRef$current !== void 0 && _hourPanelRef$current.isCompositing() || (_dayPanelRef$current = dayPanelRef.current) !== null && _dayPanelRef$current !== void 0 && _dayPanelRef$current.isCompositing() || (_monthPanelRef$curren = monthPanelRef.current) !== null && _monthPanelRef$curren !== void 0 && _monthPanelRef$curren.isCompositing() || (_weekPanelRef$current = weekPanelRef.current) !== null && _weekPanelRef$current !== void 0 && _weekPanelRef$current.isCompositing() || (_yearPanelRef$current = yearPanelRef.current) !== null && _yearPanelRef$current !== void 0 && _yearPanelRef$current.isCompositing())) {
|
|
596
|
+
return;
|
|
597
|
+
}
|
|
598
|
+
setTriggerOpen(open);
|
|
599
|
+
props === null || props === void 0 || (_props$triggerProps10 = props.triggerProps) === null || _props$triggerProps10 === void 0 || (_props$triggerProps11 = _props$triggerProps10.onOpenChange) === null || _props$triggerProps11 === void 0 || _props$triggerProps11.call(_props$triggerProps10, open);
|
|
600
|
+
}
|
|
601
|
+
}, omitTriggerProps), {}, {
|
|
602
|
+
children: /*#__PURE__*/_jsx("div", {
|
|
603
|
+
"data-cron-input-entry": fieldId,
|
|
604
|
+
children: buildEntryDom()
|
|
605
|
+
})
|
|
606
|
+
}))]
|
|
607
|
+
});
|
|
608
|
+
});
|