@pisell/materials 1.8.12 → 1.8.13
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/build/lowcode/assets-daily.json +11 -11
- package/build/lowcode/assets-dev.json +2 -2
- package/build/lowcode/assets-prod.json +11 -11
- package/build/lowcode/index.js +1 -1
- package/build/lowcode/meta.js +7 -7
- package/build/lowcode/preview.js +150 -164
- package/build/lowcode/render/default/view.css +1 -1
- package/build/lowcode/render/default/view.js +27 -40
- package/build/lowcode/view.css +1 -1
- package/build/lowcode/view.js +27 -40
- package/es/components/Pagination/index.d.ts +3 -5
- package/es/components/Pagination/index.js +77 -59
- package/es/components/Pagination/index.less +13 -7
- package/es/components/PisellFields/index.d.ts +2 -2
- package/es/components/PisellSuperTabs/PisellSuperTabs.d.ts +8 -0
- package/es/components/PisellSuperTabs/hooks/useTabsState.d.ts +7 -0
- package/es/components/PisellSuperTabs/types.d.ts +212 -0
- package/es/components/PisellTabbar/PisellTabbar.d.ts +20 -0
- package/es/components/PisellTabbar/constants.d.ts +47 -0
- package/es/components/PisellTabbar/hooks/useActiveKey.d.ts +55 -0
- package/es/components/PisellTabbar/hooks/useExpand.d.ts +42 -0
- package/es/components/PisellTabbar/locales.d.ts +23 -0
- package/es/components/PisellTabbar/template/Template1/PisellTabbar.d.ts +5 -0
- package/es/components/PisellTabbar/template/Template1/constants.d.ts +10 -0
- package/es/components/PisellTabbar/types.d.ts +90 -0
- package/es/components/PisellTabbar/utils/index.d.ts +69 -0
- package/es/components/PisellTabbar2/locales.d.ts +23 -0
- package/es/components/PisellTabbar3/locales.d.ts +23 -0
- package/es/components/config-provider/index.d.ts +9 -0
- package/es/components/dataSourceComponents/dataSourceForm/BaseForm.js +6 -8
- package/es/components/dataSourceComponents/dataSourceForm/serve.d.ts +5 -6
- package/es/components/dataSourceComponents/dataSourceForm/serve.js +39 -33
- package/es/components/dataSourceComponents/dataSourceForm/submitButton/index.js +27 -30
- package/es/components/dataSourceComponents/dataSourceForm/urlUtils.js +1 -1
- package/es/components/dataSourceComponents/dataSourceForm/utils.d.ts +1 -0
- package/es/components/dataSourceComponents/dataSourceForm/utils.js +5 -1
- package/es/components/dataSourceComponents/dataSourceTable/hooks/useDataSourceKey.d.ts +2 -2
- package/es/components/dataSourceComponents/dataSourceTable/hooks/useFormat.js +33 -15
- package/es/components/dataSourceComponents/dataSourceTable/hooks/useTableProps.d.ts +2 -2
- package/es/components/dataSourceComponents/fields/Input.Mobile/serve.d.ts +26 -0
- package/es/components/dataSourceComponents/fields/Input.Phone/serve.d.ts +27 -0
- package/es/components/dataSourceComponents/fields/Select/index.d.ts +1 -0
- package/es/components/dataSourceComponents/fields/Translation/BaseTranslation.d.ts +5 -0
- package/es/components/dataSourceComponents/fields/Translation/BaseTranslation.js +6 -3
- package/es/components/dataSourceComponents/fields/Translation/type.d.ts +21 -0
- package/es/components/dataSourceComponents/fields/Upload/constants.d.ts +9 -0
- package/es/components/dataSourceComponents/fields/Upload/utils.d.ts +18 -0
- package/es/components/dataSourceComponents/fields/index.d.ts +8 -6
- package/es/components/dataSourceComponents/hooks/useActions.js +3 -2
- package/es/components/dataSourceComponents/hooks/useFormSettingParams.d.ts +7 -0
- package/es/components/dataSourceComponents/hooks/useFormSettingParams.js +32 -0
- package/es/components/filter/components/Dropdown/index.js +6 -2
- package/es/components/filter/components/FilterButton/index.js +19 -4
- package/es/components/filter/components/FilterButton/types.d.ts +8 -0
- package/es/components/filter/components/FilterItem/AsyncOptionsSelectWrapper.d.ts +21 -0
- package/es/components/filter/components/FilterItem/AsyncOptionsSelectWrapper.js +90 -0
- package/es/components/filter/components/FilterItem/index.d.ts +3 -3
- package/es/components/filter/components/FilterItem/index.js +138 -7
- package/es/components/filter/components/FilterItem/index.less +90 -0
- package/es/components/filter/types.d.ts +4 -2
- package/es/components/media/index.d.ts +18 -0
- package/es/components/media/index.js +340 -0
- package/es/components/media/index.less +100 -0
- package/es/components/page/index.d.ts +8 -0
- package/es/components/pisellBatchActionBar/PisellBatchActionBar.js +38 -29
- package/es/components/pisellCurrency/PisellCurrency.less +163 -25
- package/es/components/pisellCurrency/PisellCurrency.stories.js +1 -1
- package/es/components/pisellCurrency/index.d.ts +2 -1
- package/es/components/pisellCurrency/index.js +16 -1
- package/es/components/pisellDataSourceContainer/components/ColumnsSetting/utils.d.ts +18 -12
- package/es/components/pisellDataSourceContainer/components/ColumnsSetting/utils.js +15 -64
- package/es/components/pisellDataSourceContainer/components/Pagination/index.d.ts +6 -0
- package/es/components/pisellDataSourceContainer/hooks/useDataSourceKey.d.ts +2 -2
- package/es/components/pisellDateTimeDisplay/PisellDateTimeDisplay.d.ts +35 -0
- package/es/components/pisellDateTimeDisplay/PisellDateTimeDisplay.js +21 -15
- package/es/components/pisellDateTimeDisplay/PisellDateTimeDisplay.less +2 -1
- package/es/components/pisellDateTimeDisplay/PisellDateTimeDisplay.stories.d.ts +195 -0
- package/es/components/pisellDateTimeDisplay/components/DateDisplay.d.ts +48 -0
- package/es/components/pisellDateTimeDisplay/formats/dateTimeDisplayFormats.d.ts +7 -0
- package/es/components/pisellDateTimeDisplay/formats/dateTimeDisplayFormats.js +5 -5
- package/es/components/pisellDateTimeDisplay/formats/index.d.ts +1 -0
- package/es/components/pisellDateTimeDisplay/hooks/useCurrentTime.d.ts +46 -0
- package/es/components/pisellDateTimeDisplay/hooks/useCurrentTime.js +6 -4
- package/es/components/pisellDateTimeDisplay/index.d.ts +3 -0
- package/es/components/pisellDateTimeDisplay/types.d.ts +352 -0
- package/es/components/pisellDateTimeDisplay/utils/formatDate.d.ts +21 -0
- package/es/components/pisellDateTimeDisplay/utils/formatDateOrRelative.d.ts +17 -0
- package/es/components/pisellDateTimeDisplay/utils/formatWeekday.d.ts +30 -0
- package/es/components/pisellDateTimeDisplay/utils/index.d.ts +7 -0
- package/es/components/pisellDateTimeDisplay/utils/localeUtils.d.ts +22 -0
- package/es/components/pisellDateTimeDisplay/utils/localeUtils.js +15 -4
- package/es/components/pisellDateTimeDisplay/utils/relativeDay.d.ts +24 -0
- package/es/components/pisellDateTimeDisplay/utils/relativeDay.js +4 -2
- package/es/components/pisellEmail/PisellEmail.less +119 -10
- package/es/components/pisellEmail/PisellEmail.stories.js +1 -1
- package/es/components/pisellEmail/index.d.ts +3 -1
- package/es/components/pisellEmail/index.js +17 -1
- package/es/components/pisellFilter/index.js +76 -10
- package/es/components/pisellFind/PisellFind.stories.d.ts +45 -0
- package/es/components/pisellFind/index.d.ts +40 -0
- package/es/components/pisellFind/index.js +11 -2
- package/es/components/pisellGridPro/ToolBar/index.less +23 -0
- package/es/components/pisellLongText/PisellLongText.less +72 -4
- package/es/components/pisellLongText/PisellLongText.stories.js +1 -1
- package/es/components/pisellLongText/index.d.ts +2 -1
- package/es/components/pisellLongText/index.js +16 -1
- package/es/components/pisellLookup/PisellLookup.d.ts +4 -0
- package/es/components/pisellLookup/PisellLookup.js +18 -9
- package/es/components/pisellLookup/PisellLookup.less +39 -16
- package/es/components/pisellLookup/PisellLookup.stories.d.ts +129 -0
- package/es/components/pisellLookup/components/HotWords.d.ts +7 -0
- package/es/components/pisellLookup/components/LookupAuxiliary.d.ts +7 -0
- package/es/components/pisellLookup/components/LookupResultHost.d.ts +7 -0
- package/es/components/pisellLookup/components/LookupTrigger.d.ts +3 -0
- package/es/components/pisellLookup/components/LookupTrigger.js +30 -17
- package/es/components/pisellLookup/components/SearchHistory.d.ts +7 -0
- package/es/components/pisellLookup/components/SuggestWords.d.ts +7 -0
- package/es/components/pisellLookup/components/index.d.ts +9 -0
- package/es/components/pisellLookup/hooks/index.d.ts +6 -0
- package/es/components/pisellLookup/hooks/useDebounceSearch.d.ts +40 -0
- package/es/components/pisellLookup/hooks/useSearchHistory.d.ts +48 -0
- package/es/components/pisellLookup/hooks/useSearchState.d.ts +80 -0
- package/es/components/pisellLookup/index.d.ts +6 -0
- package/es/components/pisellLookup/types.d.ts +667 -0
- package/es/components/pisellLookup/utils/index.d.ts +5 -0
- package/es/components/pisellLookup/utils/storage.d.ts +42 -0
- package/es/components/pisellLookup/utils/trigger.d.ts +42 -0
- package/es/components/pisellMultipleSelect/PisellMultipleSelect.less +159 -124
- package/es/components/pisellMultipleSelect/PisellMultipleSelect.stories.js +1 -1
- package/es/components/pisellMultipleSelect/components/EditView.js +8 -2
- package/es/components/pisellMultipleSelect/components/ReadOnlyView.d.ts +1 -1
- package/es/components/pisellMultipleSelect/components/ReadOnlyView.js +15 -11
- package/es/components/pisellMultipleSelect/index.d.ts +2 -1
- package/es/components/pisellMultipleSelect/index.js +16 -1
- package/es/components/pisellNumber/PisellNumber.less +135 -17
- package/es/components/pisellNumber/PisellNumber.stories.js +1 -1
- package/es/components/pisellNumber/index.d.ts +2 -1
- package/es/components/pisellNumber/index.js +16 -1
- package/es/components/pisellPercent/PisellPercent.less +142 -24
- package/es/components/pisellPercent/PisellPercent.stories.js +1 -1
- package/es/components/pisellPercent/index.d.ts +2 -1
- package/es/components/pisellPercent/index.js +16 -1
- package/es/components/pisellPhone/PisellPhone.less +122 -27
- package/es/components/pisellPhone/PisellPhone.stories.js +1 -1
- package/es/components/pisellPhone/components/EditView.js +1 -1
- package/es/components/pisellPhone/components/ReadOnlyView.js +15 -6
- package/es/components/pisellPhone/index.d.ts +2 -1
- package/es/components/pisellPhone/index.js +16 -1
- package/es/components/pisellRating/PisellRating.less +20 -12
- package/es/components/pisellRating/PisellRating.stories.js +1 -1
- package/es/components/pisellRating/index.d.ts +2 -1
- package/es/components/pisellRating/index.js +16 -1
- package/es/components/pisellRecordBoard/PisellRecordBoard.d.ts +9 -0
- package/es/components/pisellRecordBoard/PisellRecordBoard.d.ts.map +1 -0
- package/es/components/pisellRecordBoard/PisellRecordBoard.js +243 -0
- package/es/components/pisellRecordBoard/PisellRecordBoard.stories.d.ts +81 -0
- package/es/components/pisellRecordBoard/PisellRecordBoard.stories.js +2358 -0
- package/es/components/pisellRecordBoard/context/RecordBoardContext.d.ts +3 -0
- package/es/components/pisellRecordBoard/context/RecordBoardContext.js +2 -0
- package/es/components/pisellRecordBoard/context/RecordBoardProvider.d.ts +11 -0
- package/es/components/pisellRecordBoard/context/RecordBoardProvider.js +13 -0
- package/es/components/pisellRecordBoard/hooks/useRecordBoardContext.d.ts +16 -0
- package/es/components/pisellRecordBoard/hooks/useRecordBoardContext.js +29 -0
- package/es/components/pisellRecordBoard/index.d.ts +35 -0
- package/es/components/pisellRecordBoard/index.js +23 -0
- package/es/components/pisellRecordBoard/layouts/CardLayout/CardList.d.ts +12 -0
- package/es/components/pisellRecordBoard/layouts/CardLayout/CardList.js +36 -0
- package/es/components/pisellRecordBoard/layouts/CardLayout/index.d.ts +13 -0
- package/es/components/pisellRecordBoard/layouts/CardLayout/index.js +20 -0
- package/es/components/pisellRecordBoard/layouts/GridLayout/Grid.d.ts +14 -0
- package/es/components/pisellRecordBoard/layouts/GridLayout/Grid.js +242 -0
- package/es/components/pisellRecordBoard/layouts/GridLayout/Grid.less +100 -0
- package/es/components/pisellRecordBoard/layouts/GridLayout/index.d.ts +13 -0
- package/es/components/pisellRecordBoard/layouts/GridLayout/index.js +20 -0
- package/es/components/pisellRecordBoard/shellFrame/BatchActionBar/index.d.ts +8 -0
- package/es/components/pisellRecordBoard/shellFrame/BatchActionBar/index.js +90 -0
- package/es/components/pisellRecordBoard/shellFrame/ColumnSetting/ColumnSettingPopover.d.ts +15 -0
- package/es/components/pisellRecordBoard/shellFrame/ColumnSetting/ColumnSettingPopover.js +138 -0
- package/es/components/pisellRecordBoard/shellFrame/ColumnSetting/index.d.ts +8 -0
- package/es/components/pisellRecordBoard/shellFrame/ColumnSetting/index.js +66 -0
- package/es/components/pisellRecordBoard/shellFrame/ColumnSetting/index.less +2 -0
- package/es/components/pisellRecordBoard/shellFrame/Pagination/index.d.ts +14 -0
- package/es/components/pisellRecordBoard/shellFrame/Pagination/index.js +66 -0
- package/es/components/pisellRecordBoard/shellFrame/Pagination/index.less +78 -0
- package/es/components/pisellRecordBoard/shellFrame/Search/index.d.ts +10 -0
- package/es/components/pisellRecordBoard/shellFrame/Search/index.js +41 -0
- package/es/components/pisellRecordBoard/shellFrame/ToolBar/ToolBarFilter.less +112 -0
- package/es/components/pisellRecordBoard/shellFrame/ToolBar/index.d.ts +12 -0
- package/es/components/pisellRecordBoard/shellFrame/ToolBar/index.d.ts.map +1 -0
- package/es/components/pisellRecordBoard/shellFrame/ToolBar/index.js +215 -0
- package/es/components/pisellRecordBoard/shellFrame/ToolBarQuickFilter/index.d.ts +17 -0
- package/es/components/pisellRecordBoard/shellFrame/ToolBarQuickFilter/index.js +77 -0
- package/es/components/pisellRecordBoard/shellFrame/ToolBarReset/index.d.ts +17 -0
- package/es/components/pisellRecordBoard/shellFrame/ToolBarReset/index.d.ts.map +1 -0
- package/es/components/pisellRecordBoard/shellFrame/ToolBarReset/index.js +65 -0
- package/es/components/pisellRecordBoard/shellFrame/ToolBarReset/index.less +41 -0
- package/es/components/pisellRecordBoard/shellFrame/index.d.ts +26 -0
- package/es/components/pisellRecordBoard/shellFrame/index.js +104 -0
- package/es/components/pisellRecordBoard/types.d.ts +316 -0
- package/es/components/pisellRecordBoard/types.d.ts.map +1 -0
- package/es/components/pisellRecordBoard/types.js +1 -0
- package/es/components/pisellRecordBoard/utils/recordBoardColumns.d.ts +41 -0
- package/es/components/pisellRecordBoard/utils/recordBoardColumns.js +508 -0
- package/es/components/pisellRecordBoard/utils/withRecordBoard.d.ts +9 -0
- package/es/components/pisellRecordBoard/utils/withRecordBoard.js +27 -0
- package/es/components/pisellShellFrame/PisellShellFrame.d.ts +13 -0
- package/es/components/pisellShellFrame/PisellShellFrame.js +107 -0
- package/es/components/pisellShellFrame/PisellShellFrame.less +78 -0
- package/es/components/pisellShellFrame/PisellShellFrame.stories.d.ts +15 -0
- package/es/components/pisellShellFrame/PisellShellFrame.stories.js +195 -0
- package/es/components/pisellShellFrame/index.d.ts +2 -0
- package/es/components/pisellShellFrame/index.js +1 -0
- package/es/components/pisellShellFrame/types.d.ts +56 -0
- package/es/components/pisellShellFrame/types.js +1 -0
- package/es/components/pisellSingleLineText/PisellSingleLineText.stories.js +1 -1
- package/es/components/pisellSingleLineText/index.d.ts +2 -1
- package/es/components/pisellSingleLineText/index.js +16 -1
- package/es/components/pisellSingleSelect/PisellSingleSelect.less +103 -46
- package/es/components/pisellSingleSelect/PisellSingleSelect.stories.js +1 -1
- package/es/components/pisellSingleSelect/components/EditView.js +8 -2
- package/es/components/pisellSingleSelect/components/ReadOnlyView.d.ts +1 -1
- package/es/components/pisellSingleSelect/components/ReadOnlyView.js +10 -6
- package/es/components/pisellSingleSelect/index.d.ts +2 -1
- package/es/components/pisellSingleSelect/index.js +16 -1
- package/es/components/pisellStatisticList/index.d.ts +1 -0
- package/es/components/pisellStatisticList/index.js +5 -2
- package/es/components/pisellText/components/Editable/index.d.ts +32 -0
- package/es/components/pisellTimeRangeDisplay/PisellTimeRangeDisplay.d.ts +32 -0
- package/es/components/pisellTimeRangeDisplay/PisellTimeRangeDisplay.js +8 -5
- package/es/components/pisellTimeRangeDisplay/PisellTimeRangeDisplay.stories.d.ts +61 -0
- package/es/components/pisellTimeRangeDisplay/components/DateBlock.d.ts +20 -0
- package/es/components/pisellTimeRangeDisplay/components/DurationBlock.d.ts +19 -0
- package/es/components/pisellTimeRangeDisplay/components/TimeRangeBlock.d.ts +30 -0
- package/es/components/pisellTimeRangeDisplay/components/WeekdayBlock.d.ts +18 -0
- package/es/components/pisellTimeRangeDisplay/components/index.d.ts +8 -0
- package/es/components/pisellTimeRangeDisplay/index.d.ts +3 -0
- package/es/components/pisellTimeRangeDisplay/types.d.ts +137 -0
- package/es/components/pisellTimeRangeDisplay/utils/formatDuration.d.ts +14 -0
- package/es/components/pisellTimeRangeDisplay/utils/index.d.ts +4 -0
- package/es/components/pisellTimeRangeDisplay/utils/parseTimeRange.d.ts +23 -0
- package/es/components/pisellUrl/PisellUrl.less +120 -11
- package/es/components/pisellUrl/PisellUrl.stories.js +1 -1
- package/es/components/pisellUrl/index.d.ts +3 -1
- package/es/components/pisellUrl/index.js +17 -1
- package/es/components/pisellVHFix/index.d.ts +13 -0
- package/es/components/pisellVHFix/index.js +36 -0
- package/es/components/pisellVHFix/index.less +10 -0
- package/es/components/productCard/cartSkuCard/components/Gift/index.d.ts +4 -0
- package/es/components/productCard/cartSkuCard/components/Gift/index.js +1 -1
- package/es/components/productCard/cartSkuCard/components/Gift/types.d.ts +29 -0
- package/es/components/productCard/cartSkuCard/components/Promotion/index.d.ts +6 -0
- package/es/components/productCard/cartSkuCard/components/basicInfo/index.d.ts +36 -0
- package/es/components/productCard/cartSkuCard/components/basicInfo/index.js +5 -3
- package/es/components/productCard/cartSkuCard/components/basicInfo/index.less +1 -1
- package/es/components/productCard/cartSkuCard/components/packages/index.d.ts +11 -0
- package/es/components/productCard/cartSkuCard/components/timeRange/index.d.ts +8 -0
- package/es/components/productCard/cartSkuCard/components/timeRange/index.js +1 -0
- package/es/components/productCard/cartSkuCard/index.d.ts +10 -0
- package/es/components/productCard/cartSkuCard/index.js +5 -1
- package/es/components/productCard/cartSkuCard/locales.d.ts +178 -0
- package/es/components/productCard/cartSkuCard/locales.js +12 -2
- package/es/components/productCard/components/Header/EditButton/index.d.ts +3 -0
- package/es/components/productCard/locales.d.ts +138 -0
- package/es/components/productCard/status.d.ts +32 -0
- package/es/components/productCard/types.d.ts +95 -0
- package/es/components/productCard/utils.d.ts +33 -0
- package/es/components/select/index.less +18 -2
- package/es/components/sort/index.js +25 -3
- package/es/components/sort/types.d.ts +20 -1
- package/es/components/table/Gallery/components/VirtualGrid/useGapSize.d.ts +2 -2
- package/es/components/table/Table/fields/select/filterUtil/index.d.ts +1 -1
- package/es/components/table/Table/fields/treeSelect/filterUtil/index.d.ts +1 -1
- package/es/components/table/Table/utils.d.ts +1 -1
- package/es/components/translation/index.d.ts +17 -0
- package/es/components/translation/utils.d.ts +9 -0
- package/es/components/virtualInput/BaseVirtualInput/index.less +2 -2
- package/es/components/virtualInput/index.d.ts +5 -0
- package/es/components/virtualInput/index.js +6 -2
- package/es/components/walletCard/index.d.ts +79 -0
- package/es/hooks/useThemeTokens.d.ts +7 -0
- package/es/hooks/useThemeTokens.js +20 -0
- package/es/index.d.ts +235 -0
- package/es/index.js +23 -21
- package/es/locales/en-US.d.ts +384 -0
- package/es/locales/en-US.js +51 -2
- package/es/locales/index.d.ts +1 -0
- package/es/locales/index.js +2 -2
- package/es/locales/ja.d.ts +348 -0
- package/es/locales/ja.js +13 -1
- package/es/locales/pt.d.ts +348 -0
- package/es/locales/pt.js +12 -1
- package/es/locales/zh-CN.d.ts +379 -0
- package/es/locales/zh-CN.js +55 -6
- package/es/locales/zh-TW.d.ts +379 -0
- package/es/locales/zh-TW.js +55 -6
- package/es/theme/tokens.d.ts +22 -0
- package/es/utils/index.d.ts +1 -1
- package/es/utils/platform.d.ts +1 -1
- package/es/utils/tagColor.d.ts +7 -0
- package/es/utils/tagColor.js +39 -0
- package/lib/components/Pagination/index.d.ts +3 -5
- package/lib/components/Pagination/index.js +44 -21
- package/lib/components/Pagination/index.less +13 -7
- package/lib/components/PisellFields/index.d.ts +2 -2
- package/lib/components/PisellSuperTabs/PisellSuperTabs.d.ts +8 -0
- package/lib/components/PisellSuperTabs/hooks/useTabsState.d.ts +7 -0
- package/lib/components/PisellSuperTabs/types.d.ts +212 -0
- package/lib/components/PisellTabbar/PisellTabbar.d.ts +20 -0
- package/lib/components/PisellTabbar/constants.d.ts +47 -0
- package/lib/components/PisellTabbar/hooks/useActiveKey.d.ts +55 -0
- package/lib/components/PisellTabbar/hooks/useExpand.d.ts +42 -0
- package/lib/components/PisellTabbar/locales.d.ts +23 -0
- package/lib/components/PisellTabbar/template/Template1/PisellTabbar.d.ts +5 -0
- package/lib/components/PisellTabbar/template/Template1/constants.d.ts +10 -0
- package/lib/components/PisellTabbar/types.d.ts +90 -0
- package/lib/components/PisellTabbar/utils/index.d.ts +69 -0
- package/lib/components/PisellTabbar2/locales.d.ts +23 -0
- package/lib/components/PisellTabbar3/locales.d.ts +23 -0
- package/lib/components/config-provider/index.d.ts +9 -0
- package/lib/components/dataSourceComponents/dataSourceForm/BaseForm.js +3 -3
- package/lib/components/dataSourceComponents/dataSourceForm/serve.d.ts +5 -6
- package/lib/components/dataSourceComponents/dataSourceForm/serve.js +38 -22
- package/lib/components/dataSourceComponents/dataSourceForm/submitButton/index.js +4 -8
- package/lib/components/dataSourceComponents/dataSourceForm/urlUtils.js +1 -1
- package/lib/components/dataSourceComponents/dataSourceForm/utils.d.ts +1 -0
- package/lib/components/dataSourceComponents/dataSourceForm/utils.js +2 -1
- package/lib/components/dataSourceComponents/dataSourceTable/hooks/useDataSourceKey.d.ts +2 -2
- package/lib/components/dataSourceComponents/dataSourceTable/hooks/useFormat.js +33 -15
- package/lib/components/dataSourceComponents/dataSourceTable/hooks/useTableProps.d.ts +2 -2
- package/lib/components/dataSourceComponents/fields/Input.Mobile/serve.d.ts +26 -0
- package/lib/components/dataSourceComponents/fields/Input.Phone/serve.d.ts +27 -0
- package/lib/components/dataSourceComponents/fields/Select/index.d.ts +1 -0
- package/lib/components/dataSourceComponents/fields/Translation/BaseTranslation.d.ts +5 -0
- package/lib/components/dataSourceComponents/fields/Translation/BaseTranslation.js +6 -3
- package/lib/components/dataSourceComponents/fields/Translation/type.d.ts +21 -0
- package/lib/components/dataSourceComponents/fields/Upload/constants.d.ts +9 -0
- package/lib/components/dataSourceComponents/fields/Upload/utils.d.ts +18 -0
- package/lib/components/dataSourceComponents/fields/index.d.ts +8 -6
- package/lib/components/dataSourceComponents/hooks/useActions.js +6 -2
- package/lib/components/dataSourceComponents/hooks/useFormSettingParams.d.ts +7 -0
- package/lib/components/dataSourceComponents/hooks/useFormSettingParams.js +63 -0
- package/lib/components/filter/components/Dropdown/index.js +9 -2
- package/lib/components/filter/components/FilterButton/index.js +14 -3
- package/lib/components/filter/components/FilterButton/types.d.ts +8 -0
- package/lib/components/filter/components/FilterItem/AsyncOptionsSelectWrapper.d.ts +21 -0
- package/lib/components/filter/components/FilterItem/AsyncOptionsSelectWrapper.js +69 -0
- package/lib/components/filter/components/FilterItem/index.d.ts +3 -3
- package/lib/components/filter/components/FilterItem/index.js +133 -4
- package/lib/components/filter/components/FilterItem/index.less +90 -0
- package/lib/components/filter/types.d.ts +4 -2
- package/lib/components/media/index.d.ts +18 -0
- package/lib/components/media/index.js +265 -0
- package/lib/components/media/index.less +100 -0
- package/lib/components/page/index.d.ts +8 -0
- package/lib/components/pisellBatchActionBar/PisellBatchActionBar.js +26 -23
- package/lib/components/pisellCurrency/PisellCurrency.less +163 -25
- package/lib/components/pisellCurrency/PisellCurrency.stories.js +1 -1
- package/lib/components/pisellCurrency/index.d.ts +2 -1
- package/lib/components/pisellCurrency/index.js +7 -0
- package/lib/components/pisellDataSourceContainer/components/ColumnsSetting/utils.d.ts +18 -12
- package/lib/components/pisellDataSourceContainer/components/ColumnsSetting/utils.js +8 -48
- package/lib/components/pisellDataSourceContainer/components/Pagination/index.d.ts +6 -0
- package/lib/components/pisellDataSourceContainer/hooks/useDataSourceKey.d.ts +2 -2
- package/lib/components/pisellDateTimeDisplay/PisellDateTimeDisplay.d.ts +35 -0
- package/lib/components/pisellDateTimeDisplay/PisellDateTimeDisplay.js +17 -11
- package/lib/components/pisellDateTimeDisplay/PisellDateTimeDisplay.less +2 -1
- package/lib/components/pisellDateTimeDisplay/PisellDateTimeDisplay.stories.d.ts +195 -0
- package/lib/components/pisellDateTimeDisplay/components/DateDisplay.d.ts +48 -0
- package/lib/components/pisellDateTimeDisplay/formats/dateTimeDisplayFormats.d.ts +7 -0
- package/lib/components/pisellDateTimeDisplay/formats/dateTimeDisplayFormats.js +3 -3
- package/lib/components/pisellDateTimeDisplay/formats/index.d.ts +1 -0
- package/lib/components/pisellDateTimeDisplay/hooks/useCurrentTime.d.ts +46 -0
- package/lib/components/pisellDateTimeDisplay/hooks/useCurrentTime.js +7 -1
- package/lib/components/pisellDateTimeDisplay/index.d.ts +3 -0
- package/lib/components/pisellDateTimeDisplay/types.d.ts +352 -0
- package/lib/components/pisellDateTimeDisplay/utils/formatDate.d.ts +21 -0
- package/lib/components/pisellDateTimeDisplay/utils/formatDateOrRelative.d.ts +17 -0
- package/lib/components/pisellDateTimeDisplay/utils/formatWeekday.d.ts +30 -0
- package/lib/components/pisellDateTimeDisplay/utils/index.d.ts +7 -0
- package/lib/components/pisellDateTimeDisplay/utils/localeUtils.d.ts +22 -0
- package/lib/components/pisellDateTimeDisplay/utils/localeUtils.js +10 -2
- package/lib/components/pisellDateTimeDisplay/utils/relativeDay.d.ts +24 -0
- package/lib/components/pisellDateTimeDisplay/utils/relativeDay.js +2 -1
- package/lib/components/pisellEmail/PisellEmail.less +119 -10
- package/lib/components/pisellEmail/PisellEmail.stories.js +1 -1
- package/lib/components/pisellEmail/index.d.ts +3 -1
- package/lib/components/pisellEmail/index.js +10 -2
- package/lib/components/pisellFilter/index.js +79 -8
- package/lib/components/pisellFind/PisellFind.stories.d.ts +45 -0
- package/lib/components/pisellFind/index.d.ts +40 -0
- package/lib/components/pisellFind/index.js +11 -2
- package/lib/components/pisellGridPro/ToolBar/index.less +23 -0
- package/lib/components/pisellLongText/PisellLongText.less +72 -4
- package/lib/components/pisellLongText/PisellLongText.stories.js +1 -1
- package/lib/components/pisellLongText/index.d.ts +2 -1
- package/lib/components/pisellLongText/index.js +7 -0
- package/lib/components/pisellLookup/PisellLookup.d.ts +4 -0
- package/lib/components/pisellLookup/PisellLookup.js +12 -6
- package/lib/components/pisellLookup/PisellLookup.less +39 -16
- package/lib/components/pisellLookup/PisellLookup.stories.d.ts +129 -0
- package/lib/components/pisellLookup/components/HotWords.d.ts +7 -0
- package/lib/components/pisellLookup/components/LookupAuxiliary.d.ts +7 -0
- package/lib/components/pisellLookup/components/LookupResultHost.d.ts +7 -0
- package/lib/components/pisellLookup/components/LookupTrigger.d.ts +3 -0
- package/lib/components/pisellLookup/components/LookupTrigger.js +17 -11
- package/lib/components/pisellLookup/components/SearchHistory.d.ts +7 -0
- package/lib/components/pisellLookup/components/SuggestWords.d.ts +7 -0
- package/lib/components/pisellLookup/components/index.d.ts +9 -0
- package/lib/components/pisellLookup/hooks/index.d.ts +6 -0
- package/lib/components/pisellLookup/hooks/useDebounceSearch.d.ts +40 -0
- package/lib/components/pisellLookup/hooks/useSearchHistory.d.ts +48 -0
- package/lib/components/pisellLookup/hooks/useSearchState.d.ts +80 -0
- package/lib/components/pisellLookup/index.d.ts +6 -0
- package/lib/components/pisellLookup/types.d.ts +667 -0
- package/lib/components/pisellLookup/utils/index.d.ts +5 -0
- package/lib/components/pisellLookup/utils/storage.d.ts +42 -0
- package/lib/components/pisellLookup/utils/trigger.d.ts +42 -0
- package/lib/components/pisellMultipleSelect/PisellMultipleSelect.less +159 -124
- package/lib/components/pisellMultipleSelect/PisellMultipleSelect.stories.js +1 -1
- package/lib/components/pisellMultipleSelect/components/EditView.js +4 -1
- package/lib/components/pisellMultipleSelect/components/ReadOnlyView.d.ts +1 -1
- package/lib/components/pisellMultipleSelect/components/ReadOnlyView.js +29 -1
- package/lib/components/pisellMultipleSelect/index.d.ts +2 -1
- package/lib/components/pisellMultipleSelect/index.js +7 -0
- package/lib/components/pisellNumber/PisellNumber.less +135 -17
- package/lib/components/pisellNumber/PisellNumber.stories.js +1 -1
- package/lib/components/pisellNumber/index.d.ts +2 -1
- package/lib/components/pisellNumber/index.js +7 -0
- package/lib/components/pisellPercent/PisellPercent.less +142 -24
- package/lib/components/pisellPercent/PisellPercent.stories.js +1 -1
- package/lib/components/pisellPercent/index.d.ts +2 -1
- package/lib/components/pisellPercent/index.js +7 -0
- package/lib/components/pisellPhone/PisellPhone.less +122 -27
- package/lib/components/pisellPhone/PisellPhone.stories.js +1 -1
- package/lib/components/pisellPhone/components/EditView.js +1 -1
- package/lib/components/pisellPhone/components/ReadOnlyView.js +18 -4
- package/lib/components/pisellPhone/index.d.ts +2 -1
- package/lib/components/pisellPhone/index.js +7 -0
- package/lib/components/pisellRating/PisellRating.less +20 -12
- package/lib/components/pisellRating/PisellRating.stories.js +1 -1
- package/lib/components/pisellRating/index.d.ts +2 -1
- package/lib/components/pisellRating/index.js +7 -0
- package/lib/components/pisellRecordBoard/PisellRecordBoard.d.ts +9 -0
- package/lib/components/pisellRecordBoard/PisellRecordBoard.d.ts.map +1 -0
- package/lib/components/pisellRecordBoard/PisellRecordBoard.js +263 -0
- package/lib/components/pisellRecordBoard/PisellRecordBoard.stories.d.ts +81 -0
- package/lib/components/pisellRecordBoard/PisellRecordBoard.stories.js +1673 -0
- package/lib/components/pisellRecordBoard/context/RecordBoardContext.d.ts +3 -0
- package/lib/components/pisellRecordBoard/context/RecordBoardContext.js +30 -0
- package/lib/components/pisellRecordBoard/context/RecordBoardProvider.d.ts +11 -0
- package/lib/components/pisellRecordBoard/context/RecordBoardProvider.js +46 -0
- package/lib/components/pisellRecordBoard/hooks/useRecordBoardContext.d.ts +16 -0
- package/lib/components/pisellRecordBoard/hooks/useRecordBoardContext.js +47 -0
- package/lib/components/pisellRecordBoard/index.d.ts +35 -0
- package/lib/components/pisellRecordBoard/index.js +59 -0
- package/lib/components/pisellRecordBoard/layouts/CardLayout/CardList.d.ts +12 -0
- package/lib/components/pisellRecordBoard/layouts/CardLayout/CardList.js +46 -0
- package/lib/components/pisellRecordBoard/layouts/CardLayout/index.d.ts +13 -0
- package/lib/components/pisellRecordBoard/layouts/CardLayout/index.js +46 -0
- package/lib/components/pisellRecordBoard/layouts/GridLayout/Grid.d.ts +14 -0
- package/lib/components/pisellRecordBoard/layouts/GridLayout/Grid.js +264 -0
- package/lib/components/pisellRecordBoard/layouts/GridLayout/Grid.less +100 -0
- package/lib/components/pisellRecordBoard/layouts/GridLayout/index.d.ts +13 -0
- package/lib/components/pisellRecordBoard/layouts/GridLayout/index.js +46 -0
- package/lib/components/pisellRecordBoard/shellFrame/BatchActionBar/index.d.ts +8 -0
- package/lib/components/pisellRecordBoard/shellFrame/BatchActionBar/index.js +108 -0
- package/lib/components/pisellRecordBoard/shellFrame/ColumnSetting/ColumnSettingPopover.d.ts +15 -0
- package/lib/components/pisellRecordBoard/shellFrame/ColumnSetting/ColumnSettingPopover.js +173 -0
- package/lib/components/pisellRecordBoard/shellFrame/ColumnSetting/index.d.ts +8 -0
- package/lib/components/pisellRecordBoard/shellFrame/ColumnSetting/index.js +100 -0
- package/lib/components/pisellRecordBoard/shellFrame/ColumnSetting/index.less +2 -0
- package/lib/components/pisellRecordBoard/shellFrame/Pagination/index.d.ts +14 -0
- package/lib/components/pisellRecordBoard/shellFrame/Pagination/index.js +90 -0
- package/lib/components/pisellRecordBoard/shellFrame/Pagination/index.less +78 -0
- package/lib/components/pisellRecordBoard/shellFrame/Search/index.d.ts +10 -0
- package/lib/components/pisellRecordBoard/shellFrame/Search/index.js +53 -0
- package/lib/components/pisellRecordBoard/shellFrame/ToolBar/ToolBarFilter.less +112 -0
- package/lib/components/pisellRecordBoard/shellFrame/ToolBar/index.d.ts +12 -0
- package/lib/components/pisellRecordBoard/shellFrame/ToolBar/index.d.ts.map +1 -0
- package/lib/components/pisellRecordBoard/shellFrame/ToolBar/index.js +247 -0
- package/lib/components/pisellRecordBoard/shellFrame/ToolBarQuickFilter/index.d.ts +17 -0
- package/lib/components/pisellRecordBoard/shellFrame/ToolBarQuickFilter/index.js +93 -0
- package/lib/components/pisellRecordBoard/shellFrame/ToolBarReset/index.d.ts +17 -0
- package/lib/components/pisellRecordBoard/shellFrame/ToolBarReset/index.d.ts.map +1 -0
- package/lib/components/pisellRecordBoard/shellFrame/ToolBarReset/index.js +85 -0
- package/lib/components/pisellRecordBoard/shellFrame/ToolBarReset/index.less +41 -0
- package/lib/components/pisellRecordBoard/shellFrame/index.d.ts +26 -0
- package/lib/components/pisellRecordBoard/shellFrame/index.js +137 -0
- package/lib/components/pisellRecordBoard/types.d.ts +316 -0
- package/lib/components/pisellRecordBoard/types.d.ts.map +1 -0
- package/lib/components/pisellRecordBoard/types.js +17 -0
- package/lib/components/pisellRecordBoard/utils/recordBoardColumns.d.ts +41 -0
- package/lib/components/pisellRecordBoard/utils/recordBoardColumns.js +365 -0
- package/lib/components/pisellRecordBoard/utils/withRecordBoard.d.ts +9 -0
- package/lib/components/pisellRecordBoard/utils/withRecordBoard.js +49 -0
- package/lib/components/pisellShellFrame/PisellShellFrame.d.ts +13 -0
- package/lib/components/pisellShellFrame/PisellShellFrame.js +113 -0
- package/lib/components/pisellShellFrame/PisellShellFrame.less +78 -0
- package/lib/components/pisellShellFrame/PisellShellFrame.stories.d.ts +15 -0
- package/lib/components/pisellShellFrame/PisellShellFrame.stories.js +129 -0
- package/lib/components/pisellShellFrame/index.d.ts +2 -0
- package/lib/components/pisellShellFrame/index.js +40 -0
- package/lib/components/pisellShellFrame/types.d.ts +56 -0
- package/lib/components/pisellShellFrame/types.js +17 -0
- package/lib/components/pisellSingleLineText/PisellSingleLineText.stories.js +1 -1
- package/lib/components/pisellSingleLineText/index.d.ts +2 -1
- package/lib/components/pisellSingleLineText/index.js +7 -0
- package/lib/components/pisellSingleSelect/PisellSingleSelect.less +103 -46
- package/lib/components/pisellSingleSelect/PisellSingleSelect.stories.js +1 -1
- package/lib/components/pisellSingleSelect/components/EditView.js +4 -1
- package/lib/components/pisellSingleSelect/components/ReadOnlyView.d.ts +1 -1
- package/lib/components/pisellSingleSelect/components/ReadOnlyView.js +12 -9
- package/lib/components/pisellSingleSelect/index.d.ts +2 -1
- package/lib/components/pisellSingleSelect/index.js +7 -0
- package/lib/components/pisellStatisticList/index.d.ts +1 -0
- package/lib/components/pisellStatisticList/index.js +4 -2
- package/lib/components/pisellText/components/Editable/index.d.ts +32 -0
- package/lib/components/pisellTimeRangeDisplay/PisellTimeRangeDisplay.d.ts +32 -0
- package/lib/components/pisellTimeRangeDisplay/PisellTimeRangeDisplay.js +7 -3
- package/lib/components/pisellTimeRangeDisplay/PisellTimeRangeDisplay.stories.d.ts +61 -0
- package/lib/components/pisellTimeRangeDisplay/components/DateBlock.d.ts +20 -0
- package/lib/components/pisellTimeRangeDisplay/components/DurationBlock.d.ts +19 -0
- package/lib/components/pisellTimeRangeDisplay/components/TimeRangeBlock.d.ts +30 -0
- package/lib/components/pisellTimeRangeDisplay/components/WeekdayBlock.d.ts +18 -0
- package/lib/components/pisellTimeRangeDisplay/components/index.d.ts +8 -0
- package/lib/components/pisellTimeRangeDisplay/index.d.ts +3 -0
- package/lib/components/pisellTimeRangeDisplay/types.d.ts +137 -0
- package/lib/components/pisellTimeRangeDisplay/utils/formatDuration.d.ts +14 -0
- package/lib/components/pisellTimeRangeDisplay/utils/index.d.ts +4 -0
- package/lib/components/pisellTimeRangeDisplay/utils/parseTimeRange.d.ts +23 -0
- package/lib/components/pisellUrl/PisellUrl.less +120 -11
- package/lib/components/pisellUrl/PisellUrl.stories.js +1 -1
- package/lib/components/pisellUrl/index.d.ts +3 -1
- package/lib/components/pisellUrl/index.js +10 -2
- package/lib/components/pisellVHFix/index.d.ts +13 -0
- package/lib/components/pisellVHFix/index.js +56 -0
- package/lib/components/pisellVHFix/index.less +10 -0
- package/lib/components/productCard/cartSkuCard/components/Gift/index.d.ts +4 -0
- package/lib/components/productCard/cartSkuCard/components/Gift/index.js +1 -1
- package/lib/components/productCard/cartSkuCard/components/Gift/types.d.ts +29 -0
- package/lib/components/productCard/cartSkuCard/components/Promotion/index.d.ts +6 -0
- package/lib/components/productCard/cartSkuCard/components/basicInfo/index.d.ts +36 -0
- package/lib/components/productCard/cartSkuCard/components/basicInfo/index.js +7 -1
- package/lib/components/productCard/cartSkuCard/components/basicInfo/index.less +1 -1
- package/lib/components/productCard/cartSkuCard/components/packages/index.d.ts +11 -0
- package/lib/components/productCard/cartSkuCard/components/timeRange/index.d.ts +8 -0
- package/lib/components/productCard/cartSkuCard/components/timeRange/index.js +1 -0
- package/lib/components/productCard/cartSkuCard/index.d.ts +10 -0
- package/lib/components/productCard/cartSkuCard/index.js +5 -1
- package/lib/components/productCard/cartSkuCard/locales.d.ts +178 -0
- package/lib/components/productCard/cartSkuCard/locales.js +8 -2
- package/lib/components/productCard/components/Header/EditButton/index.d.ts +3 -0
- package/lib/components/productCard/locales.d.ts +138 -0
- package/lib/components/productCard/status.d.ts +32 -0
- package/lib/components/productCard/types.d.ts +95 -0
- package/lib/components/productCard/utils.d.ts +33 -0
- package/lib/components/select/index.less +18 -2
- package/lib/components/sort/index.js +13 -3
- package/lib/components/sort/types.d.ts +20 -1
- package/lib/components/table/Gallery/components/VirtualGrid/useGapSize.d.ts +2 -2
- package/lib/components/table/Table/fields/select/filterUtil/index.d.ts +1 -1
- package/lib/components/table/Table/fields/treeSelect/filterUtil/index.d.ts +1 -1
- package/lib/components/table/Table/utils.d.ts +1 -1
- package/lib/components/translation/index.d.ts +17 -0
- package/lib/components/translation/utils.d.ts +9 -0
- package/lib/components/virtualInput/BaseVirtualInput/index.less +2 -2
- package/lib/components/virtualInput/index.d.ts +5 -0
- package/lib/components/virtualInput/index.js +7 -1
- package/lib/components/walletCard/index.d.ts +79 -0
- package/lib/hooks/useThemeTokens.d.ts +7 -0
- package/lib/hooks/useThemeTokens.js +40 -0
- package/lib/index.d.ts +235 -0
- package/lib/index.js +14 -8
- package/lib/locales/en-US.d.ts +384 -0
- package/lib/locales/en-US.js +43 -2
- package/lib/locales/index.d.ts +1 -0
- package/lib/locales/index.js +2 -2
- package/lib/locales/ja.d.ts +348 -0
- package/lib/locales/ja.js +13 -1
- package/lib/locales/pt.d.ts +348 -0
- package/lib/locales/pt.js +12 -1
- package/lib/locales/zh-CN.d.ts +379 -0
- package/lib/locales/zh-CN.js +47 -6
- package/lib/locales/zh-TW.d.ts +379 -0
- package/lib/locales/zh-TW.js +47 -6
- package/lib/theme/tokens.d.ts +22 -0
- package/lib/utils/index.d.ts +1 -1
- package/lib/utils/platform.d.ts +1 -1
- package/lib/utils/tagColor.d.ts +7 -0
- package/lib/utils/tagColor.js +60 -0
- package/lowcode/_utils/defaultSchema.ts +95 -30
- package/lowcode/data-source-form/utils.ts +68 -4
- package/package.json +3 -3
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import './index.less';
|
|
3
|
+
export declare type MultiLanguageValue = {
|
|
4
|
+
en: string;
|
|
5
|
+
'zh-CN': string;
|
|
6
|
+
'zh-HK': string;
|
|
7
|
+
'ja': string;
|
|
8
|
+
'pt': string;
|
|
9
|
+
original: string;
|
|
10
|
+
};
|
|
11
|
+
export interface EditableConfig {
|
|
12
|
+
/** 是否禁用编辑 */
|
|
13
|
+
disabled?: boolean;
|
|
14
|
+
/** 最大长度 */
|
|
15
|
+
maxLength?: number;
|
|
16
|
+
/** 编辑图标 */
|
|
17
|
+
icon?: React.ReactNode;
|
|
18
|
+
}
|
|
19
|
+
export interface EditableProps extends React.HTMLAttributes<HTMLSpanElement> {
|
|
20
|
+
/** 文本内容,支持字符串或多语言对象 */
|
|
21
|
+
value?: string | MultiLanguageValue;
|
|
22
|
+
/** 子节点内容,优先级高于 value */
|
|
23
|
+
children?: string;
|
|
24
|
+
/** 可编辑配置,boolean 时使用默认配置 */
|
|
25
|
+
editable?: boolean | EditableConfig;
|
|
26
|
+
/** 编辑变更回调 */
|
|
27
|
+
onChange?: (value: string | MultiLanguageValue) => void;
|
|
28
|
+
/** 输入框尺寸 */
|
|
29
|
+
size?: 'large' | 'middle' | 'small';
|
|
30
|
+
}
|
|
31
|
+
declare const Editable: React.FC<EditableProps>;
|
|
32
|
+
export default Editable;
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import 'dayjs/locale/zh-cn';
|
|
3
|
+
import 'dayjs/locale/en';
|
|
4
|
+
import type { PisellTimeRangeDisplayProps } from './types';
|
|
5
|
+
import './PisellTimeRangeDisplay.less';
|
|
6
|
+
/**
|
|
7
|
+
* PisellTimeRangeDisplay 组件
|
|
8
|
+
*
|
|
9
|
+
* @description
|
|
10
|
+
* 纯展示型时间区间组件,将 startAt / endAt 格式化为「时间区间 + 持续时间」。
|
|
11
|
+
* - 同一天:HH:mm-HH:mm,可选显示日期/星期
|
|
12
|
+
* - 跨天:起止日期时间
|
|
13
|
+
* - 持续时间:d h m s 格式
|
|
14
|
+
* - 字段顺序由 fieldOrder 控制,可将 duration 放在中间
|
|
15
|
+
*
|
|
16
|
+
* @example
|
|
17
|
+
* <PisellTimeRangeDisplay
|
|
18
|
+
* startAt="2026-02-04 09:00"
|
|
19
|
+
* endAt="2026-02-04 18:00"
|
|
20
|
+
* />
|
|
21
|
+
* // => "09:00-18:00" + "9h"
|
|
22
|
+
*
|
|
23
|
+
* <PisellTimeRangeDisplay
|
|
24
|
+
* startAt={start}
|
|
25
|
+
* endAt={end}
|
|
26
|
+
* fields={{ fieldOrder: ['time', 'duration', 'date', 'weekday'] }}
|
|
27
|
+
* showDateForSameDay
|
|
28
|
+
* />
|
|
29
|
+
*/
|
|
30
|
+
export declare const PisellTimeRangeDisplay: React.FC<PisellTimeRangeDisplayProps>;
|
|
31
|
+
declare const _default: React.NamedExoticComponent<PisellTimeRangeDisplayProps>;
|
|
32
|
+
export default _default;
|
|
@@ -39,8 +39,10 @@ var import_zh_cn = require("dayjs/locale/zh-cn");
|
|
|
39
39
|
var import_en = require("dayjs/locale/en");
|
|
40
40
|
var import_utils = require("./utils");
|
|
41
41
|
var import_components = require("./components");
|
|
42
|
+
var import_useEngineContext = __toESM(require("../../hooks/useEngineContext"));
|
|
42
43
|
var import_PisellTimeRangeDisplay = require("./PisellTimeRangeDisplay.less");
|
|
43
44
|
var PisellTimeRangeDisplay = (props) => {
|
|
45
|
+
var _a, _b;
|
|
44
46
|
const {
|
|
45
47
|
startAt,
|
|
46
48
|
endAt,
|
|
@@ -61,9 +63,11 @@ var PisellTimeRangeDisplay = (props) => {
|
|
|
61
63
|
style,
|
|
62
64
|
onClick
|
|
63
65
|
} = props;
|
|
66
|
+
const context = (0, import_useEngineContext.default)();
|
|
67
|
+
const resolvedLocale = localeProp || ((_b = (_a = context == null ? void 0 : context.engine) == null ? void 0 : _a.props) == null ? void 0 : _b.locale) || "en";
|
|
64
68
|
const effectiveLocale = (0, import_react.useMemo)(
|
|
65
|
-
() =>
|
|
66
|
-
[
|
|
69
|
+
() => (0, import_utils.getDayjsLocale)(resolvedLocale),
|
|
70
|
+
[resolvedLocale]
|
|
67
71
|
);
|
|
68
72
|
const { start, end, isSameDay } = (0, import_react.useMemo)(
|
|
69
73
|
() => (0, import_utils.parseTimeRange)(startAt, endAt, effectiveLocale),
|
|
@@ -79,7 +83,7 @@ var PisellTimeRangeDisplay = (props) => {
|
|
|
79
83
|
} = fields || {};
|
|
80
84
|
const showSeconds = (durationFormat == null ? void 0 : durationFormat.showSeconds) ?? false;
|
|
81
85
|
const effectiveDateFormat = (0, import_react.useMemo)(
|
|
82
|
-
() => ({ showRelativeDay:
|
|
86
|
+
() => ({ showRelativeDay: false, ...dateFormat }),
|
|
83
87
|
[dateFormat]
|
|
84
88
|
);
|
|
85
89
|
const referenceDate = (0, import_dayjs.default)();
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import type { Meta, StoryObj } from '@storybook/react';
|
|
2
|
+
import { PisellTimeRangeDisplay } from './PisellTimeRangeDisplay';
|
|
3
|
+
/**
|
|
4
|
+
* PisellTimeRangeDisplay 组件 Storybook
|
|
5
|
+
* 用于时间区间 + 持续时长的展示(同一天 / 跨天)
|
|
6
|
+
*/
|
|
7
|
+
declare const meta: Meta<typeof PisellTimeRangeDisplay>;
|
|
8
|
+
export default meta;
|
|
9
|
+
declare type Story = StoryObj<typeof PisellTimeRangeDisplay>;
|
|
10
|
+
/**
|
|
11
|
+
* 默认:同一天时间区间 + 持续时长
|
|
12
|
+
*/
|
|
13
|
+
export declare const Default: Story;
|
|
14
|
+
/**
|
|
15
|
+
* 同一天 + 显示日期与星期
|
|
16
|
+
*/
|
|
17
|
+
export declare const SameDayWithDate: Story;
|
|
18
|
+
/**
|
|
19
|
+
* 跨天时间区间
|
|
20
|
+
*/
|
|
21
|
+
export declare const CrossDay: Story;
|
|
22
|
+
/**
|
|
23
|
+
* 跨年
|
|
24
|
+
*/
|
|
25
|
+
export declare const CrossYear: Story;
|
|
26
|
+
/**
|
|
27
|
+
* 持续时间在中间(默认 fieldOrder)
|
|
28
|
+
*/
|
|
29
|
+
export declare const DurationInMiddle: Story;
|
|
30
|
+
/**
|
|
31
|
+
* 持续时长在前
|
|
32
|
+
*/
|
|
33
|
+
export declare const DurationFirst: Story;
|
|
34
|
+
/**
|
|
35
|
+
* 持续时长显示秒
|
|
36
|
+
*/
|
|
37
|
+
export declare const DurationWithSeconds: Story;
|
|
38
|
+
/**
|
|
39
|
+
* 仅时间区间 + 持续时长(不显示日期星期)
|
|
40
|
+
*/
|
|
41
|
+
export declare const TimeAndDurationOnly: Story;
|
|
42
|
+
/**
|
|
43
|
+
* 12 小时制
|
|
44
|
+
*/
|
|
45
|
+
export declare const Time12Hour: Story;
|
|
46
|
+
/**
|
|
47
|
+
* 中文(日期 + 持续时长「天/时/分/秒」i18n)
|
|
48
|
+
*/
|
|
49
|
+
export declare const LocaleZhCN: Story;
|
|
50
|
+
/**
|
|
51
|
+
* 英文(日期 + 持续时长 d/h/m/s)
|
|
52
|
+
*/
|
|
53
|
+
export declare const LocaleEn: Story;
|
|
54
|
+
/**
|
|
55
|
+
* 小宽度:容器较窄时按块换行
|
|
56
|
+
*/
|
|
57
|
+
export declare const NarrowWidth: Story;
|
|
58
|
+
/**
|
|
59
|
+
* 自定义容器样式
|
|
60
|
+
*/
|
|
61
|
+
export declare const CustomContainerStyle: Story;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { type Dayjs } from 'dayjs';
|
|
3
|
+
import type { DateFormatConfig, TextStyleConfig } from '../types';
|
|
4
|
+
export interface DateBlockProps {
|
|
5
|
+
/** 日期对象 */
|
|
6
|
+
date: Dayjs;
|
|
7
|
+
/** 日期格式配置(含 showRelativeDay:今天/昨天/明天) */
|
|
8
|
+
format?: DateFormatConfig;
|
|
9
|
+
/** 参考日期,用于相对日判定,默认 dayjs() */
|
|
10
|
+
referenceDate?: Dayjs;
|
|
11
|
+
/** 文本样式 */
|
|
12
|
+
style?: TextStyleConfig;
|
|
13
|
+
/** 自定义类名 */
|
|
14
|
+
className?: string;
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* 日期展示块(复用 PisellDateTimeDisplay 的 formatDate 与相对日逻辑)
|
|
18
|
+
*/
|
|
19
|
+
export declare const DateBlock: React.FC<DateBlockProps>;
|
|
20
|
+
export default DateBlock;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { TextStyleConfig } from '../types';
|
|
3
|
+
export interface DurationBlockProps {
|
|
4
|
+
/** 持续时间(毫秒) */
|
|
5
|
+
durationMs: number;
|
|
6
|
+
/** 是否显示秒 */
|
|
7
|
+
showSeconds?: boolean;
|
|
8
|
+
/** 语言代码,zh 时使用「天/时/分/秒」 */
|
|
9
|
+
locale?: string;
|
|
10
|
+
/** 文本样式 */
|
|
11
|
+
style?: TextStyleConfig;
|
|
12
|
+
/** 自定义类名 */
|
|
13
|
+
className?: string;
|
|
14
|
+
}
|
|
15
|
+
/**
|
|
16
|
+
* 持续时长展示块(d h m s 或 天/时/分/秒,按 locale i18n)
|
|
17
|
+
*/
|
|
18
|
+
export declare const DurationBlock: React.FC<DurationBlockProps>;
|
|
19
|
+
export default DurationBlock;
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { type Dayjs } from 'dayjs';
|
|
3
|
+
import type { TimeFormatConfig, DateFormatConfig, WeekdayFormatConfig, TextStyleConfig } from '../types';
|
|
4
|
+
export interface TimeRangeBlockProps {
|
|
5
|
+
/** 开始时间 */
|
|
6
|
+
start: Dayjs;
|
|
7
|
+
/** 结束时间 */
|
|
8
|
+
end: Dayjs;
|
|
9
|
+
/** 是否同一天 */
|
|
10
|
+
isSameDay: boolean;
|
|
11
|
+
/** 时间格式配置 */
|
|
12
|
+
timeFormat?: TimeFormatConfig;
|
|
13
|
+
/** 日期格式配置(跨天时用于起止日期,含 showRelativeDay) */
|
|
14
|
+
dateFormat?: DateFormatConfig;
|
|
15
|
+
/** 星期格式配置(跨天时用于「Sat, 22 Jan」) */
|
|
16
|
+
weekdayFormat?: WeekdayFormatConfig;
|
|
17
|
+
/** 参考日期,用于相对日判定,默认 dayjs() */
|
|
18
|
+
referenceDate?: Dayjs;
|
|
19
|
+
/** 文本样式 */
|
|
20
|
+
style?: TextStyleConfig;
|
|
21
|
+
/** 自定义类名 */
|
|
22
|
+
className?: string;
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* 时间区间展示块
|
|
26
|
+
* - 同一天:HH:mm-HH:mm
|
|
27
|
+
* - 跨天:起止完整日期时间;若某端为相对日(今天/昨天/明天)则只显示「时间 相对日」,不显示星期+日期
|
|
28
|
+
*/
|
|
29
|
+
export declare const TimeRangeBlock: React.FC<TimeRangeBlockProps>;
|
|
30
|
+
export default TimeRangeBlock;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { Dayjs } from 'dayjs';
|
|
3
|
+
import type { WeekdayFormatConfig, TextStyleConfig } from '../types';
|
|
4
|
+
export interface WeekdayBlockProps {
|
|
5
|
+
/** 日期对象(用于获取星期) */
|
|
6
|
+
weekday: Dayjs;
|
|
7
|
+
/** 星期格式配置 */
|
|
8
|
+
format?: WeekdayFormatConfig;
|
|
9
|
+
/** 文本样式 */
|
|
10
|
+
style?: TextStyleConfig;
|
|
11
|
+
/** 自定义类名 */
|
|
12
|
+
className?: string;
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* 星期展示块(复用 PisellDateTimeDisplay 的 formatWeekday)
|
|
16
|
+
*/
|
|
17
|
+
export declare const WeekdayBlock: React.FC<WeekdayBlockProps>;
|
|
18
|
+
export default WeekdayBlock;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export { TimeRangeBlock } from './TimeRangeBlock';
|
|
2
|
+
export { DateBlock } from './DateBlock';
|
|
3
|
+
export { WeekdayBlock } from './WeekdayBlock';
|
|
4
|
+
export { DurationBlock } from './DurationBlock';
|
|
5
|
+
export type { TimeRangeBlockProps } from './TimeRangeBlock';
|
|
6
|
+
export type { DateBlockProps } from './DateBlock';
|
|
7
|
+
export type { WeekdayBlockProps } from './WeekdayBlock';
|
|
8
|
+
export type { DurationBlockProps } from './DurationBlock';
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
export { PisellTimeRangeDisplay, default } from './PisellTimeRangeDisplay';
|
|
2
|
+
export type { PisellTimeRangeDisplayProps, LayoutDirection, TimeRangeFieldType, TimeRangeFieldConfig, DurationFormatConfig, DayjsLike, } from './types';
|
|
3
|
+
export type { TimeFormatConfig, DateFormatConfig, WeekdayFormatConfig, ContainerStyleConfig, TextStyleConfig, TextAlign, } from './types';
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
import type { CSSProperties } from 'react';
|
|
2
|
+
import type { Dayjs } from 'dayjs';
|
|
3
|
+
import type { TimeFormatConfig, DateFormatConfig, WeekdayFormatConfig, ContainerStyleConfig, TextStyleConfig, TextAlign } from '../pisellDateTimeDisplay/types';
|
|
4
|
+
export type { TimeFormatConfig, DateFormatConfig, WeekdayFormatConfig, ContainerStyleConfig, TextStyleConfig, TextAlign, };
|
|
5
|
+
/**
|
|
6
|
+
* 字段类型(时间区间、日期、星期、持续时长)
|
|
7
|
+
* - time: 时间区间块(HH:mm-HH:mm 或跨天起止)
|
|
8
|
+
* - date: 日期块
|
|
9
|
+
* - weekday: 星期块
|
|
10
|
+
* - duration: 持续时长块
|
|
11
|
+
*/
|
|
12
|
+
export declare type TimeRangeFieldType = 'time' | 'date' | 'weekday' | 'duration';
|
|
13
|
+
/**
|
|
14
|
+
* 持续时长格式配置
|
|
15
|
+
*/
|
|
16
|
+
export interface DurationFormatConfig {
|
|
17
|
+
/**
|
|
18
|
+
* 是否显示秒
|
|
19
|
+
* @default false
|
|
20
|
+
* @example true -> "2h30m23s" | false -> "2h30m"
|
|
21
|
+
*/
|
|
22
|
+
showSeconds?: boolean;
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* 字段配置
|
|
26
|
+
*/
|
|
27
|
+
export interface TimeRangeFieldConfig {
|
|
28
|
+
/**
|
|
29
|
+
* 是否显示时间区间块
|
|
30
|
+
* @default true
|
|
31
|
+
*/
|
|
32
|
+
showTimeRange?: boolean;
|
|
33
|
+
/**
|
|
34
|
+
* 是否显示日期块
|
|
35
|
+
* @default true
|
|
36
|
+
*/
|
|
37
|
+
showDate?: boolean;
|
|
38
|
+
/**
|
|
39
|
+
* 是否显示星期块
|
|
40
|
+
* @default true
|
|
41
|
+
*/
|
|
42
|
+
showWeekday?: boolean;
|
|
43
|
+
/**
|
|
44
|
+
* 是否显示持续时长块
|
|
45
|
+
* @default true
|
|
46
|
+
*/
|
|
47
|
+
showDuration?: boolean;
|
|
48
|
+
/**
|
|
49
|
+
* 字段顺序(四类块可任意排序;默认 时间 日期 星期 持续时长,可实现「持续时间在前」等)
|
|
50
|
+
* @default ['weekday', 'date', 'time', 'duration'] 换行顺序:先持续时间 → 结束时间(跨天)→ 开始/结束时间与日期 → 星期
|
|
51
|
+
*/
|
|
52
|
+
fieldOrder?: TimeRangeFieldType[];
|
|
53
|
+
}
|
|
54
|
+
/**
|
|
55
|
+
* startAt / endAt 的 dayjs 兼容值
|
|
56
|
+
*/
|
|
57
|
+
export declare type DayjsLike = Dayjs | string | number;
|
|
58
|
+
/**
|
|
59
|
+
* PisellTimeRangeDisplay 组件 Props
|
|
60
|
+
*/
|
|
61
|
+
export interface PisellTimeRangeDisplayProps {
|
|
62
|
+
/**
|
|
63
|
+
* 开始时间(dayjs 兼容值)
|
|
64
|
+
*/
|
|
65
|
+
startAt: DayjsLike;
|
|
66
|
+
/**
|
|
67
|
+
* 结束时间(dayjs 兼容值)
|
|
68
|
+
*/
|
|
69
|
+
endAt: DayjsLike;
|
|
70
|
+
/**
|
|
71
|
+
* 文本对齐方式(单行/多行均生效)
|
|
72
|
+
* @default 'center'
|
|
73
|
+
*/
|
|
74
|
+
textAlign?: TextAlign;
|
|
75
|
+
/**
|
|
76
|
+
* 字段显示与排序配置
|
|
77
|
+
*/
|
|
78
|
+
fields?: TimeRangeFieldConfig;
|
|
79
|
+
/**
|
|
80
|
+
* 同一天时是否显示具体日期
|
|
81
|
+
* @default true
|
|
82
|
+
*/
|
|
83
|
+
showDateForSameDay?: boolean;
|
|
84
|
+
/**
|
|
85
|
+
* 时间格式配置(复用 PisellDateTimeDisplay)
|
|
86
|
+
*/
|
|
87
|
+
timeFormat?: TimeFormatConfig;
|
|
88
|
+
/**
|
|
89
|
+
* 日期格式配置(复用 PisellDateTimeDisplay)
|
|
90
|
+
*/
|
|
91
|
+
dateFormat?: DateFormatConfig;
|
|
92
|
+
/**
|
|
93
|
+
* 星期格式配置(复用 PisellDateTimeDisplay)
|
|
94
|
+
*/
|
|
95
|
+
weekdayFormat?: WeekdayFormatConfig;
|
|
96
|
+
/**
|
|
97
|
+
* 持续时长格式配置
|
|
98
|
+
*/
|
|
99
|
+
durationFormat?: DurationFormatConfig;
|
|
100
|
+
/**
|
|
101
|
+
* 容器样式
|
|
102
|
+
*/
|
|
103
|
+
containerStyle?: ContainerStyleConfig;
|
|
104
|
+
/**
|
|
105
|
+
* 时间区间文本样式
|
|
106
|
+
*/
|
|
107
|
+
timeStyle?: TextStyleConfig;
|
|
108
|
+
/**
|
|
109
|
+
* 日期文本样式
|
|
110
|
+
*/
|
|
111
|
+
dateStyle?: TextStyleConfig;
|
|
112
|
+
/**
|
|
113
|
+
* 星期文本样式
|
|
114
|
+
*/
|
|
115
|
+
weekdayStyle?: TextStyleConfig;
|
|
116
|
+
/**
|
|
117
|
+
* 持续时长文本样式
|
|
118
|
+
*/
|
|
119
|
+
durationStyle?: TextStyleConfig;
|
|
120
|
+
/**
|
|
121
|
+
* dayjs locale(语言代码)
|
|
122
|
+
* @default 优先使用全局配置,其次浏览器语言
|
|
123
|
+
*/
|
|
124
|
+
locale?: string;
|
|
125
|
+
/**
|
|
126
|
+
* 自定义类名
|
|
127
|
+
*/
|
|
128
|
+
className?: string;
|
|
129
|
+
/**
|
|
130
|
+
* 自定义样式
|
|
131
|
+
*/
|
|
132
|
+
style?: CSSProperties;
|
|
133
|
+
/**
|
|
134
|
+
* 点击回调
|
|
135
|
+
*/
|
|
136
|
+
onClick?: () => void;
|
|
137
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 将毫秒数格式化为持续时间字符串(d h m s 或 天/时/分/秒)
|
|
3
|
+
*
|
|
4
|
+
* @param ms 持续时间(毫秒)
|
|
5
|
+
* @param showSeconds 是否显示秒,默认 false
|
|
6
|
+
* @param locale 语言代码,zh 时使用「天/时/分/秒」,否则使用 d/h/m/s
|
|
7
|
+
* @returns 如 "2h30m"、"1d2h30m23s" 或 "2时30分"、"1天2时30分23秒"
|
|
8
|
+
*
|
|
9
|
+
* @example
|
|
10
|
+
* formatDuration(9000000, false) // => "2h30m"
|
|
11
|
+
* formatDuration(9000000, false, 'zh-cn') // => "2时30分"
|
|
12
|
+
* formatDuration(86400000, false) // => "1d"
|
|
13
|
+
*/
|
|
14
|
+
export declare function formatDuration(ms: number, showSeconds?: boolean, locale?: string): string;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export { parseTimeRange } from './parseTimeRange';
|
|
2
|
+
export type { ParseTimeRangeResult } from './parseTimeRange';
|
|
3
|
+
export { formatDuration } from './formatDuration';
|
|
4
|
+
export { formatTime, formatDate, formatWeekday, getDayjsLocale, getRelativeDay, getRelativeDayLabel, getDatePartDisplay, } from '../../pisellDateTimeDisplay/utils';
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { type Dayjs } from 'dayjs';
|
|
2
|
+
import type { DayjsLike } from '../types';
|
|
3
|
+
export interface ParseTimeRangeResult {
|
|
4
|
+
/** 开始时间(已应用 locale) */
|
|
5
|
+
start: Dayjs;
|
|
6
|
+
/** 结束时间(已应用 locale) */
|
|
7
|
+
end: Dayjs;
|
|
8
|
+
/** 是否同一天(按本地时区自然日判定) */
|
|
9
|
+
isSameDay: boolean;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* 解析 startAt / endAt 为 Dayjs,并判定是否同一天
|
|
13
|
+
*
|
|
14
|
+
* @param startAt 开始时间(dayjs 兼容值)
|
|
15
|
+
* @param endAt 结束时间(dayjs 兼容值)
|
|
16
|
+
* @param locale dayjs locale,可选
|
|
17
|
+
* @returns { start, end, isSameDay }
|
|
18
|
+
*
|
|
19
|
+
* @example
|
|
20
|
+
* parseTimeRange('2026-02-04 09:00', '2026-02-04 18:00', 'zh-cn')
|
|
21
|
+
* // => { start: Dayjs, end: Dayjs, isSameDay: true }
|
|
22
|
+
*/
|
|
23
|
+
export declare function parseTimeRange(startAt: DayjsLike, endAt: DayjsLike, locale?: string): ParseTimeRangeResult;
|
|
@@ -1,37 +1,135 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* PisellUrl 组件样式
|
|
3
|
+
* 基于 Figma 设计规范,与 SingleLineText / PisellEmail 设计体系一致,覆盖时使用 pisell-lowcode-xxx
|
|
3
4
|
*/
|
|
4
5
|
|
|
5
6
|
.pisell-url {
|
|
6
7
|
&-edit {
|
|
8
|
+
position: relative;
|
|
7
9
|
width: 100%;
|
|
8
10
|
|
|
9
|
-
//
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
font-size:
|
|
13
|
-
|
|
14
|
-
|
|
11
|
+
// Input 组件内置样式(Figma 设计规范)
|
|
12
|
+
.pisell-lowcode-input,
|
|
13
|
+
.pisell-lowcode-input-affix-wrapper {
|
|
14
|
+
font-size: 16px !important;
|
|
15
|
+
line-height: 24px !important;
|
|
16
|
+
border-radius: 8px !important;
|
|
17
|
+
border: 1px solid #d0d5dd !important; // Gray/300
|
|
18
|
+
padding: 12px 16px !important;
|
|
19
|
+
height: 48px !important;
|
|
20
|
+
color: #101828 !important; // Gray/900
|
|
21
|
+
background-color: #ffffff !important;
|
|
22
|
+
|
|
23
|
+
&::placeholder {
|
|
24
|
+
color: #667085 !important; // Gray/500
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
&:focus,
|
|
28
|
+
&:focus-within {
|
|
29
|
+
border-color: #d6bbfb !important; // Primary/300
|
|
30
|
+
box-shadow: 0 0 0 4px #f4ebff !important; // Primary/100
|
|
31
|
+
outline: none !important;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
&:hover:not(:focus):not(:focus-within):not([disabled]) {
|
|
35
|
+
border-color: #b692f6 !important; // Primary/400
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
&[disabled],
|
|
39
|
+
&.pisell-lowcode-input-disabled {
|
|
40
|
+
background-color: #f9fafb !important; // Gray/50
|
|
41
|
+
color: #98a2b3 !important; // Gray/400
|
|
42
|
+
border-color: #d0d5dd !important;
|
|
43
|
+
cursor: not-allowed !important;
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
// 带前缀(链接图标)的 Input 容器
|
|
48
|
+
.pisell-lowcode-input-affix-wrapper {
|
|
49
|
+
padding: 0 !important;
|
|
50
|
+
|
|
51
|
+
.pisell-lowcode-input-prefix {
|
|
52
|
+
margin-right: 8px;
|
|
53
|
+
margin-left: 16px;
|
|
54
|
+
color: #667085; // Gray/500
|
|
55
|
+
font-size: 16px;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
.pisell-lowcode-input-suffix {
|
|
59
|
+
margin-left: 8px;
|
|
60
|
+
margin-right: 16px;
|
|
61
|
+
color: #667085;
|
|
62
|
+
font-size: 16px;
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
.pisell-lowcode-input {
|
|
66
|
+
padding: 12px 0 !important;
|
|
67
|
+
border: none !important;
|
|
68
|
+
box-shadow: none !important;
|
|
69
|
+
|
|
70
|
+
&:focus {
|
|
71
|
+
box-shadow: none !important;
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
// 清空按钮
|
|
77
|
+
.pisell-lowcode-input-clear-icon {
|
|
78
|
+
color: #667085 !important;
|
|
79
|
+
font-size: 14px !important;
|
|
80
|
+
|
|
81
|
+
&:hover {
|
|
82
|
+
color: #344054 !important; // Gray/700
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
|
|
86
|
+
// 错误状态
|
|
87
|
+
.pisell-lowcode-input-status-error,
|
|
88
|
+
.pisell-lowcode-input-affix-wrapper-status-error {
|
|
89
|
+
border-color: #fda29b !important; // Error/300
|
|
90
|
+
|
|
91
|
+
&:focus,
|
|
92
|
+
&:focus-within {
|
|
93
|
+
border-color: #f97066 !important; // Error/400
|
|
94
|
+
box-shadow: 0 0 0 4px #fee4e2 !important; // Error/100
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
&:hover:not(:focus):not(:focus-within) {
|
|
98
|
+
border-color: #f97066 !important; // Error/400
|
|
99
|
+
}
|
|
15
100
|
}
|
|
16
101
|
}
|
|
17
102
|
|
|
103
|
+
// 错误提示(与设计体系一致)
|
|
104
|
+
&-edit-error {
|
|
105
|
+
margin-top: 4px;
|
|
106
|
+
font-size: 12px;
|
|
107
|
+
color: #d92d20; // Error/600
|
|
108
|
+
line-height: 1.5;
|
|
109
|
+
animation: pisell-url-fadeIn 0.3s ease-in-out;
|
|
110
|
+
}
|
|
111
|
+
|
|
18
112
|
&-read {
|
|
19
113
|
display: inline-flex;
|
|
20
114
|
align-items: center;
|
|
21
115
|
|
|
22
|
-
// 链接样式
|
|
23
116
|
.pisell-lowcode-typography-link {
|
|
24
117
|
cursor: pointer;
|
|
25
|
-
transition:
|
|
118
|
+
transition: color 0.2s ease-in-out;
|
|
26
119
|
|
|
27
120
|
&:hover {
|
|
28
|
-
|
|
121
|
+
color: #6d48c4 !important;
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
&:active {
|
|
125
|
+
color: #5f3da8 !important;
|
|
29
126
|
}
|
|
30
127
|
}
|
|
31
128
|
|
|
32
|
-
//
|
|
33
|
-
.
|
|
129
|
+
// 链接图标(只读态 Space 内第一项)
|
|
130
|
+
.pisell-lowcode-space-item:first-child {
|
|
34
131
|
font-size: 14px;
|
|
132
|
+
line-height: 1;
|
|
35
133
|
}
|
|
36
134
|
}
|
|
37
135
|
|
|
@@ -44,3 +142,14 @@
|
|
|
44
142
|
}
|
|
45
143
|
}
|
|
46
144
|
}
|
|
145
|
+
|
|
146
|
+
@keyframes pisell-url-fadeIn {
|
|
147
|
+
from {
|
|
148
|
+
opacity: 0;
|
|
149
|
+
transform: translateY(-4px);
|
|
150
|
+
}
|
|
151
|
+
to {
|
|
152
|
+
opacity: 1;
|
|
153
|
+
transform: translateY(0);
|
|
154
|
+
}
|
|
155
|
+
}
|
|
@@ -58,7 +58,7 @@ module.exports = __toCommonJS(PisellUrl_stories_exports);
|
|
|
58
58
|
var import_PisellUrl = require("./PisellUrl");
|
|
59
59
|
var import_react = __toESM(require("react"));
|
|
60
60
|
var meta = {
|
|
61
|
-
title: "
|
|
61
|
+
title: "表单/表单组件/PisellUrl",
|
|
62
62
|
component: import_PisellUrl.PisellUrl,
|
|
63
63
|
parameters: {
|
|
64
64
|
layout: "centered",
|
|
@@ -29,11 +29,19 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
|
|
|
29
29
|
// src/components/pisellUrl/index.tsx
|
|
30
30
|
var pisellUrl_exports = {};
|
|
31
31
|
__export(pisellUrl_exports, {
|
|
32
|
-
PisellUrl: () => import_PisellUrl.
|
|
33
|
-
default: () =>
|
|
32
|
+
PisellUrl: () => import_PisellUrl.default,
|
|
33
|
+
default: () => pisellUrl_default
|
|
34
34
|
});
|
|
35
35
|
module.exports = __toCommonJS(pisellUrl_exports);
|
|
36
|
+
var import_locales = require("../../locales");
|
|
36
37
|
var import_PisellUrl = __toESM(require("./PisellUrl"));
|
|
38
|
+
import_PisellUrl.default.SortOptions = {
|
|
39
|
+
getSortItems: (fieldKey) => [
|
|
40
|
+
{ key: `${fieldKey}:asc`, label: (0, import_locales.getText)("sort-a-z") },
|
|
41
|
+
{ key: `${fieldKey}:desc`, label: (0, import_locales.getText)("sort-z-a") }
|
|
42
|
+
]
|
|
43
|
+
};
|
|
44
|
+
var pisellUrl_default = import_PisellUrl.default;
|
|
37
45
|
// Annotate the CommonJS export names for ESM import in node:
|
|
38
46
|
0 && (module.exports = {
|
|
39
47
|
PisellUrl
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import './index.less';
|
|
3
|
+
interface PisellVHFixProps {
|
|
4
|
+
children?: React.ReactNode;
|
|
5
|
+
className?: string;
|
|
6
|
+
style?: React.CSSProperties;
|
|
7
|
+
height?: number;
|
|
8
|
+
minHeight?: boolean;
|
|
9
|
+
maxHeight?: boolean;
|
|
10
|
+
minusPixels?: number;
|
|
11
|
+
}
|
|
12
|
+
declare const PisellVHFix: React.FC<PisellVHFixProps>;
|
|
13
|
+
export default PisellVHFix;
|