@ccs-ui/rc-pro 2.4.6 → 2.4.7-beta.2
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/docs-dist/1080.145ad951.async.js +580 -0
- package/docs-dist/404.html +2 -2
- package/docs-dist/atom__demos.634b9888.async.js +1 -0
- package/docs-dist/docs__rc-pro__atom___api__enumerations__DataEvent.md.bb7df9e5.async.js +1 -0
- package/docs-dist/docs__rc-pro__atom___api__index.md.0c77e6cb.async.js +1 -0
- package/docs-dist/docs__rc-pro__atom___api__interfaces__AtomCheckboxProps.md.4f3df5f9.async.js +1 -0
- package/docs-dist/docs__rc-pro__atom___api__interfaces__AtomEllipsisProps.md.1562f61e.async.js +1 -0
- package/docs-dist/docs__rc-pro__atom___api__interfaces__AtomFullScreenProps.md.f0fdf4d7.async.js +1 -0
- package/docs-dist/docs__rc-pro__atom___api__interfaces__AtomMultiStateProps.md.b43bdb35.async.js +1 -0
- package/docs-dist/docs__rc-pro__atom___api__interfaces__ResizeSize.md.93bec405.async.js +1 -0
- package/docs-dist/docs__rc-pro__atom___api__type-aliases__AtomCountdownProps.md.875dc115.async.js +1 -0
- package/docs-dist/docs__rc-pro__atom___api__type-aliases__AtomFilterInstance.md.35156b74.async.js +1 -0
- package/docs-dist/docs__rc-pro__atom___api__type-aliases__AtomFilterProps.md.b176db61.async.js +1 -0
- package/docs-dist/docs__rc-pro__atom___api__type-aliases__AtomFormItem.md.33be0665.chunk.css +1 -0
- package/docs-dist/docs__rc-pro__atom___api__type-aliases__AtomFormItem.md.fa22615e.async.js +1 -0
- package/docs-dist/docs__rc-pro__atom___api__type-aliases__AtomFormItems.md.33be0665.chunk.css +1 -0
- package/docs-dist/docs__rc-pro__atom___api__type-aliases__AtomFormItems.md.83b41d59.async.js +1 -0
- package/docs-dist/docs__rc-pro__atom___api__type-aliases__AtomOperationProps.md.33be0665.chunk.css +1 -0
- package/docs-dist/docs__rc-pro__atom___api__type-aliases__AtomOperationProps.md.8cc54dfd.async.js +1 -0
- package/docs-dist/docs__rc-pro__atom___api__type-aliases__AtomPageRequestProps.md.33be0665.chunk.css +1 -0
- package/docs-dist/docs__rc-pro__atom___api__type-aliases__AtomPageRequestProps.md.b06fd87c.async.js +1 -0
- package/docs-dist/docs__rc-pro__atom___api__type-aliases__AtomResizeProps.md.33be0665.chunk.css +1 -0
- package/docs-dist/docs__rc-pro__atom___api__type-aliases__AtomResizeProps.md.8d06e954.async.js +1 -0
- package/docs-dist/docs__rc-pro__atom___api__type-aliases__AtomTitleProps.md.33be0665.chunk.css +1 -0
- package/docs-dist/docs__rc-pro__atom___api__type-aliases__AtomTitleProps.md.fd553fcf.async.js +1 -0
- package/docs-dist/docs__rc-pro__atom___api__type-aliases__TableEventHandle.md.33be0665.chunk.css +1 -0
- package/docs-dist/docs__rc-pro__atom___api__type-aliases__TableEventHandle.md.4351e01a.async.js +1 -0
- package/docs-dist/{docs__rc-pro__button___api__index.md.d60cfe48.async.js → docs__rc-pro__button___api__index.md.15b75096.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__button___api__interfaces__ButtonGroupProps.md.c2087f48.async.js → docs__rc-pro__button___api__interfaces__ButtonGroupProps.md.50cae9d3.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__button___api__interfaces__DropdownProps.md.8c40fed3.async.js → docs__rc-pro__button___api__interfaces__DropdownProps.md.38fb1a4f.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__button___api__interfaces__GroupButtonItem.md.179076b4.async.js → docs__rc-pro__button___api__interfaces__GroupButtonItem.md.145875f5.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__button___api__type-aliases__ButtonProps.md.1b893707.async.js → docs__rc-pro__button___api__type-aliases__ButtonProps.md.e943b53e.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__button___api__type-aliases__DropdownClick.md.d2a5ced0.async.js → docs__rc-pro__button___api__type-aliases__DropdownClick.md.13d2a796.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__button___api__type-aliases__DropdownMenuItemType.md.66130238.async.js → docs__rc-pro__button___api__type-aliases__DropdownMenuItemType.md.97d89de0.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__button___api__type-aliases__GroupClick.md.09ca8488.async.js → docs__rc-pro__button___api__type-aliases__GroupClick.md.dc41dade.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__cascader___api__index.md.09640e24.async.js → docs__rc-pro__cascader___api__index.md.47c62918.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__cascader___api__type-aliases__ApiCascaderProps.md.65084fc1.async.js → docs__rc-pro__cascader___api__type-aliases__ApiCascaderProps.md.cb969c6e.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__context___api__index.md.20cc0933.async.js → docs__rc-pro__context___api__index.md.2d350d6f.async.js} +1 -1
- package/docs-dist/docs__rc-pro__context___api__type-aliases__AppConfigType.md.bf01193d.async.js +1 -0
- package/docs-dist/docs__rc-pro__context___api__type-aliases__AppFieldNames.md.33be0665.chunk.css +1 -0
- package/docs-dist/docs__rc-pro__context___api__type-aliases__AppFieldNames.md.6906521a.async.js +1 -0
- package/docs-dist/{docs__rc-pro__context___api__type-aliases__FnContextType.md.568b0641.async.js → docs__rc-pro__context___api__type-aliases__FnContextType.md.f84b939d.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__context___api__type-aliases__PageContextType.md.cd99fc9e.async.js → docs__rc-pro__context___api__type-aliases__PageContextType.md.9548623a.async.js} +1 -1
- package/docs-dist/docs__rc-pro__context___api__type-aliases__PageFieldNames.md.2d6f58a1.async.js +1 -0
- package/docs-dist/docs__rc-pro__context___api__type-aliases__PageFieldNames.md.33be0665.chunk.css +1 -0
- package/docs-dist/{docs__rc-pro__date-picker___api__index.md.1c120e64.async.js → docs__rc-pro__date-picker___api__index.md.855eff0e.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__date-picker___api__type-aliases__DatePickerProps.md.b6cc6691.async.js → docs__rc-pro__date-picker___api__type-aliases__DatePickerProps.md.40c84779.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__date-picker___api__type-aliases__RangePickerProps.md.c422ed80.async.js → docs__rc-pro__date-picker___api__type-aliases__RangePickerProps.md.0ac69687.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__dialog___api__index.md.323195bf.async.js → docs__rc-pro__dialog___api__index.md.6c636f36.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__dialog___api__interfaces__DialogContextType.md.85948cd5.async.js → docs__rc-pro__dialog___api__interfaces__DialogContextType.md.cbff2435.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__dialog___api__interfaces__DialogDrawer.md.7fa47fb7.async.js → docs__rc-pro__dialog___api__interfaces__DialogDrawer.md.77130a4c.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__dialog___api__interfaces__DialogInterface.md.39c3e85d.async.js → docs__rc-pro__dialog___api__interfaces__DialogInterface.md.376d95aa.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__dialog___api__interfaces__DialogModal.md.3d45a85e.async.js → docs__rc-pro__dialog___api__interfaces__DialogModal.md.be0dca59.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__dialog___api__interfaces__DialogProps.md.474686ef.async.js → docs__rc-pro__dialog___api__interfaces__DialogProps.md.e00cba5c.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__dialog___api__type-aliases__DialogButtonsProps.md.061c091d.async.js → docs__rc-pro__dialog___api__type-aliases__DialogButtonsProps.md.10b6bc8d.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__dialog___api__type-aliases__DialogDrawerProps.md.32adaa67.async.js → docs__rc-pro__dialog___api__type-aliases__DialogDrawerProps.md.4d0b0459.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__dialog___api__type-aliases__DialogModalProps.md.f9fe0f4f.async.js → docs__rc-pro__dialog___api__type-aliases__DialogModalProps.md.020421e1.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__dialog___api__type-aliases__OkBtnProps.md.ea328029.async.js → docs__rc-pro__dialog___api__type-aliases__OkBtnProps.md.df9f263a.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__dialog___api__type-aliases__OkEvent.md.4b1ae037.async.js → docs__rc-pro__dialog___api__type-aliases__OkEvent.md.c7ec7123.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__dialog___api__type-aliases__Service.md.44f8ef7e.async.js → docs__rc-pro__dialog___api__type-aliases__Service.md.6cf4c49d.async.js} +1 -1
- package/docs-dist/docs__rc-pro__editor___api__index.md.806efab7.async.js +1 -0
- package/docs-dist/docs__rc-pro__editor___api__type-aliases__EditorCodeProps.md.1a78f516.async.js +1 -0
- package/docs-dist/docs__rc-pro__editor___api__type-aliases__EditorCodeProps.md.33be0665.chunk.css +1 -0
- package/docs-dist/docs__rc-pro__editor___api__type-aliases__EditorRichProps.md.1526f411.async.js +1 -0
- package/docs-dist/docs__rc-pro__editor___api__type-aliases__EditorRichProps.md.33be0665.chunk.css +1 -0
- package/docs-dist/docs__rc-pro__editor___api__type-aliases__LexicalEditorBaseProps.md.33be0665.chunk.css +1 -0
- package/docs-dist/docs__rc-pro__editor___api__type-aliases__LexicalEditorBaseProps.md.efbfec2c.async.js +1 -0
- package/docs-dist/docs__rc-pro__editor___api__type-aliases__RichImageUpload.md.33be0665.chunk.css +1 -0
- package/docs-dist/docs__rc-pro__editor___api__type-aliases__RichImageUpload.md.d386fae1.async.js +1 -0
- package/docs-dist/{docs__rc-pro__form___api__index.md.ff691778.async.js → docs__rc-pro__form___api__index.md.0d80a8ef.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__form___api__type-aliases__FormItem.md.87be7aec.async.js → docs__rc-pro__form___api__type-aliases__FormItem.md.2ef8f670.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__form___api__type-aliases__FormItemChildren.md.04d0ec88.async.js → docs__rc-pro__form___api__type-aliases__FormItemChildren.md.852f5415.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__form___api__type-aliases__FormItemProps.md.f4b50b5e.async.js → docs__rc-pro__form___api__type-aliases__FormItemProps.md.cfad0725.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__form___api__type-aliases__FormListProps.md.c9e7229e.async.js → docs__rc-pro__form___api__type-aliases__FormListProps.md.3ce363ad.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__form___api__type-aliases__ListItemBtnProps.md.5e43e012.async.js → docs__rc-pro__form___api__type-aliases__ListItemBtnProps.md.f68c4402.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__form___api__type-aliases__RenderItem.md.5ea4e95c.async.js → docs__rc-pro__form___api__type-aliases__RenderItem.md.8eeef6c6.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__form___api__type-aliases__RenderItemButton.md.dd2c0118.async.js → docs__rc-pro__form___api__type-aliases__RenderItemButton.md.bab3405e.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__form___api__type-aliases__RenderItemProps.md.5c837071.async.js → docs__rc-pro__form___api__type-aliases__RenderItemProps.md.95e5e7d8.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__form___api__type-aliases__RuleType.md.bfaf5b74.async.js → docs__rc-pro__form___api__type-aliases__RuleType.md.e56e8fe8.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__form___api__type-aliases__ShowValidateEvent.md.845761c8.async.js → docs__rc-pro__form___api__type-aliases__ShowValidateEvent.md.1c0db839.async.js} +1 -1
- package/docs-dist/docs__rc-pro__index.md.1815af96.async.js +1 -0
- package/docs-dist/{docs__rc-pro__layout-keep-alive___api__index.md.d26250e6.async.js → docs__rc-pro__layout-keep-alive___api__index.md.3b1ec665.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__layout-keep-alive___api__interfaces__KeepAliveTabsProps.md.11942fb5.async.js → docs__rc-pro__layout-keep-alive___api__interfaces__KeepAliveTabsProps.md.8861c03e.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__layout-keep-alive___api__type-aliases__MenuType.md.1ae3b908.async.js → docs__rc-pro__layout-keep-alive___api__type-aliases__MenuType.md.a322e04c.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__layout-single-page___api__index.md.a72f9e2b.async.js → docs__rc-pro__layout-single-page___api__index.md.8ed4f72f.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__layout-single-page___api__interfaces__SinglePageProps.md.c6b5993f.async.js → docs__rc-pro__layout-single-page___api__interfaces__SinglePageProps.md.d396b5f1.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__loading___api__index.md.531605e4.async.js → docs__rc-pro__loading___api__index.md.7e626bac.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__loading___api__interfaces__LoadingProps.md.4af93070.async.js → docs__rc-pro__loading___api__interfaces__LoadingProps.md.cc583085.async.js} +1 -1
- package/docs-dist/docs__rc-pro__pro-table___api__index.md.1c149b7d.async.js +1 -0
- package/docs-dist/docs__rc-pro__pro-table___api__interfaces__ProTableProps.md.99154324.async.js +1 -0
- package/docs-dist/{docs__rc-pro__pro-table___api__interfaces__TableInstance.md.b3023c86.async.js → docs__rc-pro__pro-table___api__interfaces__TableInstance.md.18ebe0f4.async.js} +1 -1
- package/docs-dist/docs__rc-pro__pro-table___api__interfaces__TableProps.md.32cf0854.async.js +1 -0
- package/docs-dist/{docs__rc-pro__pro-table___api__type-aliases__LeafVerify.md.281e7051.async.js → docs__rc-pro__pro-table___api__type-aliases__LeafVerify.md.eacda6a2.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__pro-table___api__type-aliases__TableColumn.md.27401944.async.js → docs__rc-pro__pro-table___api__type-aliases__TableColumn.md.376c1f4a.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__pro-table___api__type-aliases__TableColumns.md.02e1af85.async.js → docs__rc-pro__pro-table___api__type-aliases__TableColumns.md.a5432088.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__pro-table___api__type-aliases__TableData.md.7ab682b3.async.js → docs__rc-pro__pro-table___api__type-aliases__TableData.md.c853060f.async.js} +1 -1
- package/docs-dist/docs__rc-pro__pro-table___api__type-aliases__TableFormItems.md.a62c7537.async.js +1 -0
- package/docs-dist/{docs__rc-pro__pro-table___api__type-aliases__TableInstanceRef.md.8e3da7a2.async.js → docs__rc-pro__pro-table___api__type-aliases__TableInstanceRef.md.091247ff.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__pro-table___api__type-aliases__TreeInstance.md.2a7b637d.async.js → docs__rc-pro__pro-table___api__type-aliases__TreeInstance.md.9b11fee0.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__pro-tabs___api__index.md.c0861fdf.async.js → docs__rc-pro__pro-tabs___api__index.md.c8a9c1ff.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__pro-tabs___api__interfaces__TabsChangeProps.md.4671d3dc.async.js → docs__rc-pro__pro-tabs___api__interfaces__TabsChangeProps.md.c31813fb.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__pro-tabs___api__interfaces__TabsContextType.md.e06c5adf.async.js → docs__rc-pro__pro-tabs___api__interfaces__TabsContextType.md.cc5241a0.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__pro-tabs___api__type-aliases__TabProps.md.9a9aa1b6.async.js → docs__rc-pro__pro-tabs___api__type-aliases__TabProps.md.9264b5cb.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__select___api__index.md.ab1e2918.async.js → docs__rc-pro__select___api__index.md.a5e94bb0.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__select___api__type-aliases__ApiSelectProps.md.31b1e31e.async.js → docs__rc-pro__select___api__type-aliases__ApiSelectProps.md.8e3f35a6.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__select___api__type-aliases__CacheType.md.992fa9c6.async.js → docs__rc-pro__select___api__type-aliases__CacheType.md.3e80fc84.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__select___api__type-aliases__CustomizeSelectProps.md.e65bd44c.async.js → docs__rc-pro__select___api__type-aliases__CustomizeSelectProps.md.4b7ba9b4.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__select___api__type-aliases__ModalSelectProps.md.c923813c.async.js → docs__rc-pro__select___api__type-aliases__ModalSelectProps.md.24aa1062.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__select___api__type-aliases__SelectChildrenProps.md.23106cbc.async.js → docs__rc-pro__select___api__type-aliases__SelectChildrenProps.md.78b68535.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__select___api__type-aliases__SelectProps.md.199c9680.async.js → docs__rc-pro__select___api__type-aliases__SelectProps.md.4820ef77.async.js} +1 -1
- package/docs-dist/docs__rc-pro__upload___api__index.md.bdb6d1f4.async.js +1 -0
- package/docs-dist/docs__rc-pro__upload___api__interfaces__ImageInfo.md.33be0665.chunk.css +1 -0
- package/docs-dist/docs__rc-pro__upload___api__interfaces__ImageInfo.md.b27b1b46.async.js +1 -0
- package/docs-dist/{docs__rc-pro__upload___api__type-aliases__FileUploadList.md.68327760.async.js → docs__rc-pro__upload___api__type-aliases__FileUploadList.md.4e43600c.async.js} +1 -1
- package/docs-dist/docs__rc-pro__upload___api__type-aliases__UploadImageProps.md.bc7609b0.async.js +1 -0
- package/docs-dist/docs__rc-pro__upload___api__type-aliases__UploadProps.md.1c53df2d.async.js +1 -0
- package/docs-dist/{docs__rc-pro__upload___api__type-aliases__UploadRequest.md.04c0e604.async.js → docs__rc-pro__upload___api__type-aliases__UploadRequest.md.b8594bb0.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__water-mark___api__index.md.9e696870.async.js → docs__rc-pro__water-mark___api__index.md.7f96f622.async.js} +1 -1
- package/docs-dist/{docs__rc-pro__water-mark___api__type-aliases__WaterMarkProps.md.17279af0.async.js → docs__rc-pro__water-mark___api__type-aliases__WaterMarkProps.md.ed3387ca.async.js} +1 -1
- package/docs-dist/editor__demos.d7755e25.async.js +24 -0
- package/docs-dist/guide/index.html +2 -2
- package/docs-dist/index.html +2 -2
- package/docs-dist/meta__docs.9484e17c.async.js +176 -0
- package/docs-dist/meta__packages.50e42993.async.js +13725 -0
- package/docs-dist/meta__packages.5b16e5e9.chunk.css +1 -0
- package/docs-dist/packages__rc-pro__src__atom__index.md.33be0665.chunk.css +1 -0
- package/docs-dist/packages__rc-pro__src__atom__index.md.7cbd6276.async.js +1 -0
- package/docs-dist/{packages__rc-pro__src__dialog__index.md.bd8bf51a.async.js → packages__rc-pro__src__dialog__index.md.e8a688de.async.js} +1 -1
- package/docs-dist/packages__rc-pro__src__editor__index.md.a2f44718.async.js +1 -0
- package/docs-dist/packages__rc-pro__src__pro-table__index.md.038f16c9.async.js +27 -0
- package/docs-dist/plugins/index.html +2 -2
- package/docs-dist/preload_helper.37208c37.js +1 -0
- package/docs-dist/pro-table__demos.a812caf5.async.js +1 -0
- package/docs-dist/{pro-tabs__demos.51945949.async.js → pro-tabs__demos.1edccbc5.async.js} +1 -1
- package/docs-dist/rc-pro/{context/_api/type-aliases/DialogFieldNames.md → atom/_api/enumerations/DataEvent.md}/index.html +2 -2
- package/docs-dist/rc-pro/{context/_api/type-aliases/TableFieldNames.md → atom/_api/index.md}/index.html +2 -2
- package/docs-dist/rc-pro/{editor/_api/type-aliases/EditorProps.md → atom/_api/interfaces/AtomCheckboxProps.md}/index.html +2 -2
- package/docs-dist/rc-pro/{ellipsis/_api/index.md → atom/_api/interfaces/AtomEllipsisProps.md}/index.html +2 -2
- package/docs-dist/rc-pro/atom/_api/interfaces/AtomFullScreenProps.md/index.html +15 -0
- package/docs-dist/rc-pro/atom/_api/interfaces/AtomMultiStateProps.md/index.html +15 -0
- package/docs-dist/rc-pro/atom/_api/interfaces/ResizeSize.md/index.html +15 -0
- package/docs-dist/rc-pro/atom/_api/type-aliases/AtomCountdownProps.md/index.html +15 -0
- package/docs-dist/rc-pro/atom/_api/type-aliases/AtomFilterInstance.md/index.html +15 -0
- package/docs-dist/rc-pro/atom/_api/type-aliases/AtomFilterProps.md/index.html +15 -0
- package/docs-dist/rc-pro/atom/_api/type-aliases/AtomFormItem.md/index.html +15 -0
- package/docs-dist/rc-pro/atom/_api/type-aliases/AtomFormItems.md/index.html +15 -0
- package/docs-dist/rc-pro/atom/_api/type-aliases/AtomOperationProps.md/index.html +15 -0
- package/docs-dist/rc-pro/atom/_api/type-aliases/AtomPageRequestProps.md/index.html +15 -0
- package/docs-dist/rc-pro/atom/_api/type-aliases/AtomResizeProps.md/index.html +15 -0
- package/docs-dist/rc-pro/atom/_api/type-aliases/AtomTitleProps.md/index.html +15 -0
- package/docs-dist/rc-pro/atom/_api/type-aliases/TableEventHandle.md/index.html +15 -0
- package/docs-dist/rc-pro/button/_api/index.md/index.html +2 -2
- package/docs-dist/rc-pro/button/_api/interfaces/ButtonGroupProps.md/index.html +2 -2
- package/docs-dist/rc-pro/button/_api/interfaces/DropdownProps.md/index.html +2 -2
- package/docs-dist/rc-pro/button/_api/interfaces/GroupButtonItem.md/index.html +2 -2
- package/docs-dist/rc-pro/button/_api/type-aliases/ButtonProps.md/index.html +2 -2
- package/docs-dist/rc-pro/button/_api/type-aliases/DropdownClick.md/index.html +2 -2
- package/docs-dist/rc-pro/button/_api/type-aliases/DropdownMenuItemType.md/index.html +2 -2
- package/docs-dist/rc-pro/button/_api/type-aliases/GroupClick.md/index.html +2 -2
- package/docs-dist/rc-pro/cascader/_api/index.md/index.html +2 -2
- package/docs-dist/rc-pro/cascader/_api/type-aliases/ApiCascaderProps.md/index.html +2 -2
- package/docs-dist/rc-pro/context/_api/index.md/index.html +2 -2
- package/docs-dist/rc-pro/context/_api/type-aliases/AppConfigType.md/index.html +2 -2
- package/docs-dist/rc-pro/context/_api/type-aliases/AppFieldNames.md/index.html +15 -0
- package/docs-dist/rc-pro/context/_api/type-aliases/FnContextType.md/index.html +2 -2
- package/docs-dist/rc-pro/context/_api/type-aliases/PageContextType.md/index.html +2 -2
- package/docs-dist/rc-pro/context/_api/type-aliases/PageFieldNames.md/index.html +15 -0
- package/docs-dist/rc-pro/date-picker/_api/index.md/index.html +2 -2
- package/docs-dist/rc-pro/date-picker/_api/type-aliases/DatePickerProps.md/index.html +2 -2
- package/docs-dist/rc-pro/date-picker/_api/type-aliases/RangePickerProps.md/index.html +2 -2
- package/docs-dist/rc-pro/dialog/_api/index.md/index.html +2 -2
- package/docs-dist/rc-pro/dialog/_api/interfaces/DialogContextType.md/index.html +2 -2
- package/docs-dist/rc-pro/dialog/_api/interfaces/DialogDrawer.md/index.html +2 -2
- package/docs-dist/rc-pro/dialog/_api/interfaces/DialogInterface.md/index.html +2 -2
- package/docs-dist/rc-pro/dialog/_api/interfaces/DialogModal.md/index.html +2 -2
- package/docs-dist/rc-pro/dialog/_api/interfaces/DialogProps.md/index.html +2 -2
- package/docs-dist/rc-pro/dialog/_api/type-aliases/DialogButtonsProps.md/index.html +2 -2
- package/docs-dist/rc-pro/dialog/_api/type-aliases/DialogDrawerProps.md/index.html +2 -2
- package/docs-dist/rc-pro/dialog/_api/type-aliases/DialogModalProps.md/index.html +2 -2
- package/docs-dist/rc-pro/dialog/_api/type-aliases/OkBtnProps.md/index.html +2 -2
- package/docs-dist/rc-pro/dialog/_api/type-aliases/OkEvent.md/index.html +2 -2
- package/docs-dist/rc-pro/dialog/_api/type-aliases/Service.md/index.html +2 -2
- package/docs-dist/rc-pro/editor/_api/index.md/index.html +2 -2
- package/docs-dist/rc-pro/editor/_api/type-aliases/EditorCodeProps.md/index.html +15 -0
- package/docs-dist/rc-pro/editor/_api/type-aliases/EditorRichProps.md/index.html +15 -0
- package/docs-dist/rc-pro/editor/_api/type-aliases/LexicalEditorBaseProps.md/index.html +15 -0
- package/docs-dist/rc-pro/editor/_api/type-aliases/RichImageUpload.md/index.html +15 -0
- package/docs-dist/rc-pro/form/_api/index.md/index.html +2 -2
- package/docs-dist/rc-pro/form/_api/type-aliases/FormItem.md/index.html +2 -2
- package/docs-dist/rc-pro/form/_api/type-aliases/FormItemChildren.md/index.html +2 -2
- package/docs-dist/rc-pro/form/_api/type-aliases/FormItemProps.md/index.html +2 -2
- package/docs-dist/rc-pro/form/_api/type-aliases/FormListProps.md/index.html +2 -2
- package/docs-dist/rc-pro/form/_api/type-aliases/ListItemBtnProps.md/index.html +2 -2
- package/docs-dist/rc-pro/form/_api/type-aliases/RenderItem.md/index.html +2 -2
- package/docs-dist/rc-pro/form/_api/type-aliases/RenderItemButton.md/index.html +2 -2
- package/docs-dist/rc-pro/form/_api/type-aliases/RenderItemProps.md/index.html +2 -2
- package/docs-dist/rc-pro/form/_api/type-aliases/RuleType.md/index.html +2 -2
- package/docs-dist/rc-pro/form/_api/type-aliases/ShowValidateEvent.md/index.html +2 -2
- package/docs-dist/rc-pro/index.html +2 -2
- package/docs-dist/rc-pro/index.md/index.html +2 -2
- package/docs-dist/rc-pro/layout-keep-alive/_api/index.md/index.html +2 -2
- package/docs-dist/rc-pro/layout-keep-alive/_api/interfaces/KeepAliveTabsProps.md/index.html +2 -2
- package/docs-dist/rc-pro/layout-keep-alive/_api/type-aliases/MenuType.md/index.html +2 -2
- package/docs-dist/rc-pro/layout-single-page/_api/index.md/index.html +2 -2
- package/docs-dist/rc-pro/layout-single-page/_api/interfaces/SinglePageProps.md/index.html +2 -2
- package/docs-dist/rc-pro/loading/_api/index.md/index.html +2 -2
- package/docs-dist/rc-pro/loading/_api/interfaces/LoadingProps.md/index.html +2 -2
- package/docs-dist/rc-pro/pro-table/_api/index.md/index.html +2 -2
- package/docs-dist/rc-pro/pro-table/_api/interfaces/ProTableProps.md/index.html +2 -2
- package/docs-dist/rc-pro/pro-table/_api/interfaces/TableInstance.md/index.html +2 -2
- package/docs-dist/rc-pro/pro-table/_api/interfaces/TableProps.md/index.html +2 -2
- package/docs-dist/rc-pro/pro-table/_api/type-aliases/LeafVerify.md/index.html +2 -2
- package/docs-dist/rc-pro/pro-table/_api/type-aliases/TableColumn.md/index.html +2 -2
- package/docs-dist/rc-pro/pro-table/_api/type-aliases/TableColumns.md/index.html +2 -2
- package/docs-dist/rc-pro/pro-table/_api/type-aliases/TableData.md/index.html +2 -2
- package/docs-dist/rc-pro/pro-table/_api/type-aliases/TableFormItems.md/index.html +2 -2
- package/docs-dist/rc-pro/pro-table/_api/type-aliases/TableInstanceRef.md/index.html +2 -2
- package/docs-dist/rc-pro/pro-table/_api/type-aliases/TreeInstance.md/index.html +2 -2
- package/docs-dist/rc-pro/pro-tabs/_api/index.md/index.html +2 -2
- package/docs-dist/rc-pro/pro-tabs/_api/interfaces/TabsChangeProps.md/index.html +2 -2
- package/docs-dist/rc-pro/pro-tabs/_api/interfaces/TabsContextType.md/index.html +2 -2
- package/docs-dist/rc-pro/pro-tabs/_api/type-aliases/TabProps.md/index.html +2 -2
- package/docs-dist/rc-pro/select/_api/index.md/index.html +2 -2
- package/docs-dist/rc-pro/select/_api/type-aliases/ApiSelectProps.md/index.html +2 -2
- package/docs-dist/rc-pro/select/_api/type-aliases/CacheType.md/index.html +2 -2
- package/docs-dist/rc-pro/select/_api/type-aliases/CustomizeSelectProps.md/index.html +2 -2
- package/docs-dist/rc-pro/select/_api/type-aliases/ModalSelectProps.md/index.html +2 -2
- package/docs-dist/rc-pro/select/_api/type-aliases/SelectChildrenProps.md/index.html +2 -2
- package/docs-dist/rc-pro/select/_api/type-aliases/SelectProps.md/index.html +2 -2
- package/docs-dist/rc-pro/upload/_api/index.md/index.html +2 -2
- package/docs-dist/rc-pro/upload/_api/interfaces/ImageInfo.md/index.html +15 -0
- package/docs-dist/rc-pro/upload/_api/type-aliases/FileUploadList.md/index.html +2 -2
- package/docs-dist/rc-pro/upload/_api/type-aliases/UploadImageProps.md/index.html +2 -2
- package/docs-dist/rc-pro/upload/_api/type-aliases/UploadProps.md/index.html +2 -2
- package/docs-dist/rc-pro/upload/_api/type-aliases/UploadRequest.md/index.html +2 -2
- package/docs-dist/rc-pro/water-mark/_api/index.md/index.html +2 -2
- package/docs-dist/rc-pro/water-mark/_api/type-aliases/WaterMarkProps.md/index.html +2 -2
- package/docs-dist/rc-pros/atom/index.html +15 -0
- package/docs-dist/rc-pros/auth/index.html +2 -2
- package/docs-dist/rc-pros/button/index.html +2 -2
- package/docs-dist/rc-pros/cascader/index.html +2 -2
- package/docs-dist/rc-pros/date-picker/index.html +2 -2
- package/docs-dist/rc-pros/dialog/index.html +2 -2
- package/docs-dist/rc-pros/editor/index.html +2 -2
- package/docs-dist/rc-pros/form/index.html +2 -2
- package/docs-dist/rc-pros/index.html +2 -2
- package/docs-dist/rc-pros/layout-keep-alive/index.html +2 -2
- package/docs-dist/rc-pros/loading/index.html +2 -2
- package/docs-dist/rc-pros/pro-table/index.html +2 -2
- package/docs-dist/rc-pros/pro-tabs/index.html +2 -2
- package/docs-dist/rc-pros/result/index.html +2 -2
- package/docs-dist/rc-pros/select/index.html +2 -2
- package/docs-dist/rc-pros/time-picker/index.html +2 -2
- package/docs-dist/rc-pros/upload/index.html +2 -2
- package/docs-dist/rc-pros/water-mark/index.html +2 -2
- package/docs-dist/{umi.f6ba7429.js → umi.be7ce5af.js} +62 -62
- package/docs-dist/utils/index.html +2 -2
- package/docs-dist/~demos/:id/index.html +2 -2
- package/docs-dist/~demos/atom-demo-base/index.html +15 -0
- package/docs-dist/~demos/atom-demo-ellipsis/index.html +15 -0
- package/docs-dist/~demos/atom-demo-filter/index.html +15 -0
- package/docs-dist/~demos/atom-demo-operation/index.html +15 -0
- package/docs-dist/~demos/atom-demo-state/index.html +15 -0
- package/docs-dist/~demos/auth-demo-basic/index.html +2 -2
- package/docs-dist/~demos/button-demo-button/index.html +2 -2
- package/docs-dist/~demos/button-demo-group/index.html +2 -2
- package/docs-dist/~demos/cascader-demo-basic/index.html +2 -2
- package/docs-dist/~demos/cascader-demo-cache/index.html +2 -2
- package/docs-dist/~demos/date-picker-demo-basic/index.html +2 -2
- package/docs-dist/~demos/date-picker-demo-range/index.html +2 -2
- package/docs-dist/~demos/dialog-demo-demos/index.html +2 -2
- package/docs-dist/~demos/dialog-demo-form/index.html +2 -2
- package/docs-dist/~demos/dialog-demo-prompt/index.html +2 -2
- package/docs-dist/~demos/editor-demo-demos/index.html +2 -2
- package/docs-dist/~demos/editor-demo-rich/index.html +15 -0
- package/docs-dist/~demos/form-demo-demos/index.html +2 -2
- package/docs-dist/~demos/loading-demo-basic/index.html +2 -2
- package/docs-dist/~demos/packages-utils-src-demo-demos/index.html +2 -2
- package/docs-dist/~demos/pro-table-demo-basic/index.html +2 -2
- package/docs-dist/~demos/pro-table-demo-cascade/index.html +2 -2
- package/docs-dist/~demos/pro-table-demo-extra/index.html +2 -2
- package/docs-dist/~demos/pro-table-demo-filter/index.html +2 -2
- package/docs-dist/~demos/pro-table-demo-fixed/index.html +2 -2
- package/docs-dist/~demos/pro-table-demo-refresh/index.html +2 -2
- package/docs-dist/~demos/pro-table-demo-selection/index.html +2 -2
- package/docs-dist/~demos/pro-table-demo-show-depend/index.html +2 -2
- package/docs-dist/~demos/pro-table-demo-tree-async/index.html +2 -2
- package/docs-dist/~demos/pro-tabs-demo-basic/index.html +2 -2
- package/docs-dist/~demos/pro-tabs-demo-tab/index.html +2 -2
- package/docs-dist/~demos/result-demo-basic/index.html +2 -2
- package/docs-dist/~demos/select-demo-api/index.html +2 -2
- package/docs-dist/~demos/select-demo-basic/index.html +2 -2
- package/docs-dist/~demos/select-demo-customize/index.html +2 -2
- package/docs-dist/~demos/select-demo-customize-label/index.html +2 -2
- package/docs-dist/~demos/time-picker-demo-basic/index.html +2 -2
- package/docs-dist/~demos/upload-demo-basic/index.html +2 -2
- package/docs-dist/~demos/upload-demo-image/index.html +2 -2
- package/docs-dist/~demos/water-mark-demo-basic/index.html +2 -2
- package/es/atom/_api.d.ts +170 -0
- package/es/atom/_api.js +18 -0
- package/es/atom/check.d.ts +2 -0
- package/es/atom/check.js +86 -0
- package/es/atom/count-down.d.ts +12 -0
- package/es/atom/count-down.js +123 -0
- package/es/atom/ellipsis.d.ts +13 -0
- package/es/{ellipsis/index.js → atom/ellipsis.js} +3 -4
- package/es/atom/filter.d.ts +13 -0
- package/es/{pro-table/head.js → atom/filter.js} +98 -57
- package/es/atom/full-screen.d.ts +6 -0
- package/es/atom/full-screen.js +74 -0
- package/es/atom/index.d.ts +53 -0
- package/es/atom/index.js +55 -0
- package/es/atom/index.less +91 -0
- package/es/atom/item.d.ts +5 -0
- package/es/atom/item.js +34 -0
- package/es/atom/operation.d.ts +6 -0
- package/es/atom/operation.js +79 -0
- package/es/atom/resize-observer.d.ts +8 -0
- package/es/atom/resize-observer.js +63 -0
- package/es/atom/title.d.ts +2 -0
- package/es/atom/title.js +25 -0
- package/es/atom/useComplexState.d.ts +25 -0
- package/es/atom/useComplexState.js +108 -0
- package/es/atom/usePageRequest.d.ts +9 -0
- package/es/atom/usePageRequest.js +243 -0
- package/es/ccs.d.ts +7 -3
- package/es/ccs.js +14 -2
- package/es/color-picker/index.js +5 -1
- package/es/config.js +17 -6
- package/es/context/_api.d.ts +37 -19
- package/es/dialog/HookDrawer.js +6 -0
- package/es/dialog/_api.d.ts +1 -1
- package/es/dialog/button.d.ts +1 -1
- package/es/dialog/button.js +3 -3
- package/es/editor/_api.d.ts +45 -5
- package/es/editor/code-base.d.ts +3 -0
- package/es/editor/{base.js → code-base.js} +38 -33
- package/es/editor/code.less +16 -0
- package/es/editor/index.d.ts +6 -1
- package/es/editor/index.js +12 -1
- package/es/editor/javascript.d.ts +2 -2
- package/es/editor/javascript.js +1 -1
- package/es/editor/json.d.ts +2 -2
- package/es/editor/json.js +1 -1
- package/es/editor/lexical/base/index.d.ts +7 -0
- package/es/editor/lexical/base/index.js +100 -0
- package/es/editor/lexical/base/index.less +304 -0
- package/es/editor/lexical/base/styleConfig.d.ts +9 -0
- package/es/editor/lexical/base/styleConfig.js +23 -0
- package/es/editor/lexical/base/toolbar/code.d.ts +5 -0
- package/es/editor/lexical/base/toolbar/code.js +59 -0
- package/es/editor/lexical/base/toolbar/index.d.ts +7 -0
- package/es/editor/lexical/base/toolbar/index.js +562 -0
- package/es/editor/lexical/base/toolbar/upload.d.ts +5 -0
- package/es/editor/lexical/base/toolbar/upload.js +262 -0
- package/es/editor/lexical/plugins/image/ImageComponent.d.ts +2 -0
- package/es/{full-screen/index.js → editor/lexical/plugins/image/ImageComponent.js} +32 -32
- package/es/editor/lexical/plugins/image/ImageNode.d.ts +38 -0
- package/es/editor/lexical/plugins/image/ImageNode.js +198 -0
- package/es/editor/lexical/plugins/image/index.d.ts +3 -0
- package/es/editor/lexical/plugins/image/index.js +28 -0
- package/es/editor/lexical/plugins/init-code.d.ts +12 -0
- package/es/editor/lexical/plugins/init-code.js +45 -0
- package/es/editor/lexical/plugins/init-html.d.ts +11 -0
- package/es/editor/lexical/plugins/init-html.js +46 -0
- package/es/editor/lexical/plugins/line-number.d.ts +5 -0
- package/es/editor/lexical/plugins/line-number.js +49 -0
- package/es/editor/lexical/plugins/tree-view.d.ts +9 -0
- package/es/editor/lexical/plugins/tree-view.js +31 -0
- package/es/editor/rich/export.d.ts +2 -0
- package/es/editor/rich/export.js +111 -0
- package/es/editor/rich/index.d.ts +9 -0
- package/es/editor/rich/index.js +150 -0
- package/es/editor/rich/theme.d.ts +43 -0
- package/es/editor/rich/theme.js +44 -0
- package/es/editor/sql.d.ts +2 -2
- package/es/editor/sql.js +1 -1
- package/es/editor/xml.d.ts +2 -0
- package/es/editor/xml.js +14 -0
- package/es/editor/yaml.d.ts +2 -0
- package/es/editor/yaml.js +14 -0
- package/es/hooks/use-app.d.ts +5 -7
- package/es/hooks/use-app.js +5 -11
- package/es/hooks/use-input-css.d.ts +17 -0
- package/es/hooks/use-input-css.js +101 -0
- package/es/hooks/use-insert-css.d.ts +1 -0
- package/es/hooks/use-insert-css.js +17 -0
- package/es/index.d.ts +2 -3
- package/es/index.js +3 -3
- package/es/layout-keep-alive/index.js +6 -0
- package/es/pro-table/_api.d.ts +9 -75
- package/es/pro-table/_api.js +1 -32
- package/es/pro-table/index.less +26 -40
- package/es/pro-table/table.d.ts +1 -1
- package/es/pro-table/table.js +163 -396
- package/es/pro-table/tree.d.ts +2 -3
- package/es/pro-table/tree.js +5 -7
- package/es/table/index.js +5 -5
- package/es/theme-dialog.js +4 -4
- package/es/upload/_api.d.ts +13 -1
- package/es/upload/upload-image.d.ts +1 -1
- package/es/upload/upload-image.js +29 -7
- package/package.json +15 -1
- package/docs-dist/7865.1cc75d3e.async.js +0 -565
- package/docs-dist/docs__rc-pro__context___api__type-aliases__AppConfigType.md.421cf93c.async.js +0 -1
- package/docs-dist/docs__rc-pro__context___api__type-aliases__DialogFieldNames.md.325a86bc.async.js +0 -1
- package/docs-dist/docs__rc-pro__context___api__type-aliases__TableFieldNames.md.134b6aa7.async.js +0 -1
- package/docs-dist/docs__rc-pro__editor___api__index.md.37609e3b.async.js +0 -1
- package/docs-dist/docs__rc-pro__editor___api__type-aliases__EditorProps.md.93d04abc.async.js +0 -1
- package/docs-dist/docs__rc-pro__ellipsis___api__index.md.4b927638.async.js +0 -1
- package/docs-dist/docs__rc-pro__ellipsis___api__interfaces__EllipsisProps.md.990f0e29.async.js +0 -1
- package/docs-dist/docs__rc-pro__index.md.9119dcc4.async.js +0 -1
- package/docs-dist/docs__rc-pro__pro-table___api__enumerations__TableEvent.md.0c74c5f6.async.js +0 -1
- package/docs-dist/docs__rc-pro__pro-table___api__index.md.a502c6fb.async.js +0 -1
- package/docs-dist/docs__rc-pro__pro-table___api__interfaces__ProTableProps.md.06987c55.async.js +0 -1
- package/docs-dist/docs__rc-pro__pro-table___api__interfaces__TableProps.md.06291a3e.async.js +0 -1
- package/docs-dist/docs__rc-pro__pro-table___api__type-aliases__TableEventHandle.md.762adb4b.async.js +0 -1
- package/docs-dist/docs__rc-pro__pro-table___api__type-aliases__TableFormItem.md.b1c27010.async.js +0 -1
- package/docs-dist/docs__rc-pro__pro-table___api__type-aliases__TableFormItems.md.2a4acb24.async.js +0 -1
- package/docs-dist/docs__rc-pro__upload___api__index.md.b86ae575.async.js +0 -1
- package/docs-dist/docs__rc-pro__upload___api__type-aliases__UploadImageProps.md.4eca13b2.async.js +0 -1
- package/docs-dist/docs__rc-pro__upload___api__type-aliases__UploadProps.md.2ccd8b68.async.js +0 -1
- package/docs-dist/editor__demos.88663d1e.async.js +0 -6
- package/docs-dist/ellipsis__demos.47352a48.async.js +0 -1
- package/docs-dist/interval-button__demos.d647fbab.async.js +0 -1
- package/docs-dist/meta__docs.af3efc1f.async.js +0 -176
- package/docs-dist/meta__packages.38529667.chunk.css +0 -1
- package/docs-dist/meta__packages.5a564341.async.js +0 -11183
- package/docs-dist/packages__rc-pro__src__editor__index.md.dd655a92.async.js +0 -1
- package/docs-dist/packages__rc-pro__src__ellipsis__index.md.d9a92ef6.async.js +0 -1
- package/docs-dist/packages__rc-pro__src__interval-button__index.md.4ee5873c.async.js +0 -1
- package/docs-dist/packages__rc-pro__src__pro-table__index.md.5bbcf5a4.async.js +0 -21
- package/docs-dist/preload_helper.0fb99d58.js +0 -1
- package/docs-dist/pro-table__demos.24218bff.async.js +0 -1
- package/docs-dist/rc-pro/ellipsis/_api/interfaces/EllipsisProps.md/index.html +0 -15
- package/docs-dist/rc-pro/pro-table/_api/enumerations/TableEvent.md/index.html +0 -15
- package/docs-dist/rc-pro/pro-table/_api/type-aliases/TableEventHandle.md/index.html +0 -15
- package/docs-dist/rc-pro/pro-table/_api/type-aliases/TableFormItem.md/index.html +0 -15
- package/docs-dist/rc-pros/ellipsis/index.html +0 -15
- package/docs-dist/rc-pros/interval-button/index.html +0 -15
- package/docs-dist/~demos/ellipsis-demo-demos/index.html +0 -15
- package/docs-dist/~demos/interval-button-demo-basic/index.html +0 -15
- package/es/editor/base.d.ts +0 -2
- package/es/editor/index.less +0 -24
- package/es/ellipsis/_api.d.ts +0 -10
- package/es/ellipsis/_api.js +0 -1
- package/es/ellipsis/index.d.ts +0 -14
- package/es/ellipsis/index.less +0 -26
- package/es/full-screen/index.d.ts +0 -3
- package/es/pro-table/head.d.ts +0 -16
- package/es/pro-table/operation.d.ts +0 -14
- package/es/pro-table/operation.js +0 -194
- package/es/pro-table/size.d.ts +0 -10
- package/es/pro-table/size.js +0 -17
- package/es/resize-observer.d.ts +0 -15
- package/es/resize-observer.js +0 -37
- /package/docs-dist/{docs__rc-pro__context___api__type-aliases__DialogFieldNames.md.33be0665.chunk.css → docs__rc-pro__atom___api__enumerations__DataEvent.md.33be0665.chunk.css} +0 -0
- /package/docs-dist/{docs__rc-pro__context___api__type-aliases__TableFieldNames.md.33be0665.chunk.css → docs__rc-pro__atom___api__index.md.33be0665.chunk.css} +0 -0
- /package/docs-dist/{docs__rc-pro__editor___api__type-aliases__EditorProps.md.33be0665.chunk.css → docs__rc-pro__atom___api__interfaces__AtomCheckboxProps.md.33be0665.chunk.css} +0 -0
- /package/docs-dist/{docs__rc-pro__ellipsis___api__index.md.33be0665.chunk.css → docs__rc-pro__atom___api__interfaces__AtomEllipsisProps.md.33be0665.chunk.css} +0 -0
- /package/docs-dist/{docs__rc-pro__ellipsis___api__interfaces__EllipsisProps.md.33be0665.chunk.css → docs__rc-pro__atom___api__interfaces__AtomFullScreenProps.md.33be0665.chunk.css} +0 -0
- /package/docs-dist/{docs__rc-pro__pro-table___api__enumerations__TableEvent.md.33be0665.chunk.css → docs__rc-pro__atom___api__interfaces__AtomMultiStateProps.md.33be0665.chunk.css} +0 -0
- /package/docs-dist/{docs__rc-pro__pro-table___api__type-aliases__TableEventHandle.md.33be0665.chunk.css → docs__rc-pro__atom___api__interfaces__ResizeSize.md.33be0665.chunk.css} +0 -0
- /package/docs-dist/{docs__rc-pro__pro-table___api__type-aliases__TableFormItem.md.33be0665.chunk.css → docs__rc-pro__atom___api__type-aliases__AtomCountdownProps.md.33be0665.chunk.css} +0 -0
- /package/docs-dist/{packages__rc-pro__src__ellipsis__index.md.33be0665.chunk.css → docs__rc-pro__atom___api__type-aliases__AtomFilterInstance.md.33be0665.chunk.css} +0 -0
- /package/docs-dist/{packages__rc-pro__src__interval-button__index.md.33be0665.chunk.css → docs__rc-pro__atom___api__type-aliases__AtomFilterProps.md.33be0665.chunk.css} +0 -0
|
@@ -0,0 +1,262 @@
|
|
|
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 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; }
|
|
3
|
+
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; }
|
|
4
|
+
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; }
|
|
5
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
|
6
|
+
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); }
|
|
7
|
+
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; }
|
|
8
|
+
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); } }
|
|
9
|
+
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); }); }; }
|
|
10
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
11
|
+
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."); }
|
|
12
|
+
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); }
|
|
13
|
+
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; }
|
|
14
|
+
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; } }
|
|
15
|
+
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
16
|
+
import { CcsForm } from "../../../..";
|
|
17
|
+
import { useLexicalComposerContext } from '@lexical/react/LexicalComposerContext';
|
|
18
|
+
import { Form, Input, Modal, Radio } from 'antd';
|
|
19
|
+
import { $getNodeByKey } from 'lexical';
|
|
20
|
+
import { useContext, useRef, useState } from 'react';
|
|
21
|
+
import { EditorRichContext } from '..';
|
|
22
|
+
import CcsUpload from "../../../../upload";
|
|
23
|
+
import { INSERT_IMAGE_COMMAND } from "../../plugins/image";
|
|
24
|
+
import { $isImageNode } from "../../plugins/image/ImageNode";
|
|
25
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
26
|
+
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
27
|
+
import { Fragment as _Fragment } from "react/jsx-runtime";
|
|
28
|
+
var onFmtSize = function onFmtSize(e) {
|
|
29
|
+
if (!e) return '100%';
|
|
30
|
+
if (typeof e === 'number') {
|
|
31
|
+
return e + 'px';
|
|
32
|
+
}
|
|
33
|
+
if (e.endsWith('px') || e.endsWith('%')) {
|
|
34
|
+
return e;
|
|
35
|
+
}
|
|
36
|
+
return parseInt(e) + 'px';
|
|
37
|
+
};
|
|
38
|
+
export default function UploadModal(_ref) {
|
|
39
|
+
var _ref$imageProps = _ref.imageProps,
|
|
40
|
+
imageProps = _ref$imageProps === void 0 ? {
|
|
41
|
+
urlType: 'url'
|
|
42
|
+
} : _ref$imageProps,
|
|
43
|
+
onCancel = _ref.onCancel;
|
|
44
|
+
var _useLexicalComposerCo = useLexicalComposerContext(),
|
|
45
|
+
_useLexicalComposerCo2 = _slicedToArray(_useLexicalComposerCo, 1),
|
|
46
|
+
editor = _useLexicalComposerCo2[0];
|
|
47
|
+
var _useContext = useContext(EditorRichContext),
|
|
48
|
+
imageUpload = _useContext.imageUpload;
|
|
49
|
+
function initImageInfo() {
|
|
50
|
+
if (!imageProps.src) return {};
|
|
51
|
+
return imageProps.urlType === 'url' ? {
|
|
52
|
+
base64: undefined,
|
|
53
|
+
url: imageProps.src
|
|
54
|
+
} : {
|
|
55
|
+
base64: imageProps.src,
|
|
56
|
+
url: undefined
|
|
57
|
+
};
|
|
58
|
+
}
|
|
59
|
+
var _useState = useState(initImageInfo),
|
|
60
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
61
|
+
imageInfo = _useState2[0],
|
|
62
|
+
setImageInfo = _useState2[1];
|
|
63
|
+
var _Form$useForm = Form.useForm(),
|
|
64
|
+
_Form$useForm2 = _slicedToArray(_Form$useForm, 1),
|
|
65
|
+
form = _Form$useForm2[0];
|
|
66
|
+
var imageRef = useRef(null);
|
|
67
|
+
|
|
68
|
+
// 确定
|
|
69
|
+
var onOk = /*#__PURE__*/function () {
|
|
70
|
+
var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
|
|
71
|
+
var values, urlType, src, altText, height, width;
|
|
72
|
+
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
73
|
+
while (1) switch (_context.prev = _context.next) {
|
|
74
|
+
case 0:
|
|
75
|
+
_context.next = 2;
|
|
76
|
+
return form.validateFields();
|
|
77
|
+
case 2:
|
|
78
|
+
values = _context.sent;
|
|
79
|
+
urlType = values.urlType, src = values.src, altText = values.altText, height = values.height, width = values.width; // 更新节点
|
|
80
|
+
if (!(imageProps.key !== undefined)) {
|
|
81
|
+
_context.next = 8;
|
|
82
|
+
break;
|
|
83
|
+
}
|
|
84
|
+
editor.update(function () {
|
|
85
|
+
var node = $getNodeByKey(imageProps.key);
|
|
86
|
+
if (node && $isImageNode(node)) {
|
|
87
|
+
node.updateData({
|
|
88
|
+
altText: altText,
|
|
89
|
+
height: onFmtSize(height),
|
|
90
|
+
width: onFmtSize(width),
|
|
91
|
+
urlType: urlType,
|
|
92
|
+
src: src
|
|
93
|
+
});
|
|
94
|
+
}
|
|
95
|
+
});
|
|
96
|
+
onCancel();
|
|
97
|
+
return _context.abrupt("return");
|
|
98
|
+
case 8:
|
|
99
|
+
// 创建节点
|
|
100
|
+
editor.dispatchCommand(INSERT_IMAGE_COMMAND, {
|
|
101
|
+
altText: altText || '',
|
|
102
|
+
src: src,
|
|
103
|
+
width: onFmtSize(width),
|
|
104
|
+
height: onFmtSize(height)
|
|
105
|
+
});
|
|
106
|
+
onCancel();
|
|
107
|
+
case 10:
|
|
108
|
+
case "end":
|
|
109
|
+
return _context.stop();
|
|
110
|
+
}
|
|
111
|
+
}, _callee);
|
|
112
|
+
}));
|
|
113
|
+
return function onOk() {
|
|
114
|
+
return _ref2.apply(this, arguments);
|
|
115
|
+
};
|
|
116
|
+
}();
|
|
117
|
+
return /*#__PURE__*/_jsx(_Fragment, {
|
|
118
|
+
children: /*#__PURE__*/_jsx(Modal, {
|
|
119
|
+
open: true,
|
|
120
|
+
title: "\u56FE\u7247\u4E0A\u4F20",
|
|
121
|
+
onCancel: onCancel,
|
|
122
|
+
rootClassName: "ccs-rich-upload",
|
|
123
|
+
onOk: onOk,
|
|
124
|
+
width: 550,
|
|
125
|
+
children: /*#__PURE__*/_jsxs("div", {
|
|
126
|
+
style: {
|
|
127
|
+
display: 'flex',
|
|
128
|
+
gap: 16,
|
|
129
|
+
justifyContent: 'center'
|
|
130
|
+
},
|
|
131
|
+
children: [/*#__PURE__*/_jsxs(Form, {
|
|
132
|
+
form: form,
|
|
133
|
+
labelCol: {
|
|
134
|
+
span: 8
|
|
135
|
+
},
|
|
136
|
+
layout: "horizontal",
|
|
137
|
+
initialValues: imageProps,
|
|
138
|
+
children: [/*#__PURE__*/_jsx(Form.Item, {
|
|
139
|
+
name: "urlType",
|
|
140
|
+
label: "\u52A0\u8F7D\u7C7B\u578B",
|
|
141
|
+
style: {
|
|
142
|
+
marginBottom: 16
|
|
143
|
+
},
|
|
144
|
+
children: /*#__PURE__*/_jsx(Radio.Group, {
|
|
145
|
+
optionType: "button",
|
|
146
|
+
options: [{
|
|
147
|
+
label: '链接',
|
|
148
|
+
value: 'url'
|
|
149
|
+
}, {
|
|
150
|
+
label: 'BASE64',
|
|
151
|
+
value: 'base64'
|
|
152
|
+
}]
|
|
153
|
+
})
|
|
154
|
+
}), /*#__PURE__*/_jsx(CcsForm.Item, {
|
|
155
|
+
name: "src",
|
|
156
|
+
label: "\u56FE\u7247\u94FE\u63A5",
|
|
157
|
+
style: {
|
|
158
|
+
marginBottom: 16
|
|
159
|
+
},
|
|
160
|
+
simpleRule: "input",
|
|
161
|
+
children: /*#__PURE__*/_jsx(Input.TextArea, {
|
|
162
|
+
placeholder: "\u8BF7\u8F93\u5165\u56FE\u7247\u94FE\u63A5"
|
|
163
|
+
})
|
|
164
|
+
}), /*#__PURE__*/_jsx(Form.Item, {
|
|
165
|
+
name: "altText",
|
|
166
|
+
label: "\u56FE\u7247\u540D\u79F0",
|
|
167
|
+
style: {
|
|
168
|
+
marginBottom: 16
|
|
169
|
+
},
|
|
170
|
+
children: /*#__PURE__*/_jsx(Input, {
|
|
171
|
+
placeholder: "\u8BF7\u8F93\u5165\u56FE\u7247\u540D\u79F0"
|
|
172
|
+
})
|
|
173
|
+
}), /*#__PURE__*/_jsx(Form.Item, {
|
|
174
|
+
name: "width",
|
|
175
|
+
label: "\u56FE\u7247\u5BBD\u5EA6",
|
|
176
|
+
style: {
|
|
177
|
+
marginBottom: 16
|
|
178
|
+
},
|
|
179
|
+
children: /*#__PURE__*/_jsx(Input, {
|
|
180
|
+
placeholder: "\u8BF7\u8F93\u5165\u56FE\u7247\u5BBD\u5EA6"
|
|
181
|
+
})
|
|
182
|
+
}), /*#__PURE__*/_jsx(Form.Item, {
|
|
183
|
+
name: "height",
|
|
184
|
+
label: "\u56FE\u7247\u9AD8\u5EA6",
|
|
185
|
+
style: {
|
|
186
|
+
marginBottom: 0
|
|
187
|
+
},
|
|
188
|
+
children: /*#__PURE__*/_jsx(Input, {
|
|
189
|
+
placeholder: "\u8BF7\u8F93\u5165\u56FE\u7247\u9AD8\u5EA6"
|
|
190
|
+
})
|
|
191
|
+
}), /*#__PURE__*/_jsx(Form.Item, {
|
|
192
|
+
shouldUpdate: function shouldUpdate(l, n) {
|
|
193
|
+
return l.urlType !== n.urlType;
|
|
194
|
+
},
|
|
195
|
+
children: function children(_ref3) {
|
|
196
|
+
var getFieldValue = _ref3.getFieldValue,
|
|
197
|
+
setFieldValue = _ref3.setFieldValue;
|
|
198
|
+
var urlType = getFieldValue('urlType');
|
|
199
|
+
var src = getFieldValue('src');
|
|
200
|
+
setTimeout(function () {
|
|
201
|
+
if (urlType === 'base64') {
|
|
202
|
+
if (imageInfo.base64 === src) return null;
|
|
203
|
+
setFieldValue('src', imageInfo.base64);
|
|
204
|
+
}
|
|
205
|
+
if (urlType === 'url') {
|
|
206
|
+
if (imageInfo.url === src) return null;
|
|
207
|
+
setFieldValue('src', imageInfo.url);
|
|
208
|
+
}
|
|
209
|
+
}, 1);
|
|
210
|
+
return null;
|
|
211
|
+
}
|
|
212
|
+
})]
|
|
213
|
+
}), /*#__PURE__*/_jsx("div", {
|
|
214
|
+
style: {
|
|
215
|
+
flex: '0 0 200px'
|
|
216
|
+
},
|
|
217
|
+
children: /*#__PURE__*/_jsx(CcsUpload.Image, _objectSpread(_objectSpread({
|
|
218
|
+
value: imageProps.src
|
|
219
|
+
}, imageUpload), {}, {
|
|
220
|
+
onImageInfo: function onImageInfo(info) {
|
|
221
|
+
var imageUrl = "".concat((imageUpload === null || imageUpload === void 0 ? void 0 : imageUpload.imageUrl) || '').concat(info.url);
|
|
222
|
+
setImageInfo({
|
|
223
|
+
base64: info.base64,
|
|
224
|
+
url: imageUrl
|
|
225
|
+
});
|
|
226
|
+
var urlType = form.getFieldValue('urlType');
|
|
227
|
+
form.setFieldValue('altText', info.name);
|
|
228
|
+
form.setFieldValue('src', urlType === 'url' ? imageUrl : info.base64);
|
|
229
|
+
},
|
|
230
|
+
onChange: function onChange(e) {
|
|
231
|
+
if (!e) {
|
|
232
|
+
form.setFieldsValue({
|
|
233
|
+
src: '',
|
|
234
|
+
altText: '',
|
|
235
|
+
width: '',
|
|
236
|
+
height: ''
|
|
237
|
+
});
|
|
238
|
+
setImageInfo({});
|
|
239
|
+
}
|
|
240
|
+
}
|
|
241
|
+
}))
|
|
242
|
+
}), /*#__PURE__*/_jsx("img", {
|
|
243
|
+
style: {
|
|
244
|
+
position: 'fixed',
|
|
245
|
+
visibility: 'hidden',
|
|
246
|
+
top: 0,
|
|
247
|
+
left: 0
|
|
248
|
+
},
|
|
249
|
+
onLoad: function onLoad() {
|
|
250
|
+
var _imageRef$current, _imageRef$current2;
|
|
251
|
+
return form.setFieldsValue({
|
|
252
|
+
width: "".concat((_imageRef$current = imageRef.current) === null || _imageRef$current === void 0 ? void 0 : _imageRef$current.width, "px"),
|
|
253
|
+
height: "".concat((_imageRef$current2 = imageRef.current) === null || _imageRef$current2 === void 0 ? void 0 : _imageRef$current2.height, "px")
|
|
254
|
+
});
|
|
255
|
+
},
|
|
256
|
+
ref: imageRef,
|
|
257
|
+
src: imageInfo.base64
|
|
258
|
+
})]
|
|
259
|
+
})
|
|
260
|
+
})
|
|
261
|
+
});
|
|
262
|
+
}
|
|
@@ -4,46 +4,46 @@ function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o =
|
|
|
4
4
|
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; }
|
|
5
5
|
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; } }
|
|
6
6
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
7
|
-
import { FullscreenExitOutlined, FullscreenOutlined } from '@ant-design/icons';
|
|
8
|
-
import { Button, Tooltip } from 'antd';
|
|
9
7
|
import { useState } from 'react';
|
|
10
|
-
import
|
|
8
|
+
import UploadModal from "../../base/toolbar/upload";
|
|
11
9
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
12
|
-
|
|
13
|
-
|
|
10
|
+
import { Fragment as _Fragment } from "react/jsx-runtime";
|
|
11
|
+
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
12
|
+
export default function ImageComponent(_ref) {
|
|
13
|
+
var src = _ref.src,
|
|
14
|
+
altText = _ref.altText,
|
|
15
|
+
nodeKey = _ref.nodeKey,
|
|
16
|
+
width = _ref.width,
|
|
17
|
+
height = _ref.height;
|
|
14
18
|
var _useState = useState(false),
|
|
15
19
|
_useState2 = _slicedToArray(_useState, 2),
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
var
|
|
19
|
-
|
|
20
|
-
onFullScreen(!isFull);
|
|
20
|
+
isUpload = _useState2[0],
|
|
21
|
+
setIsUpload = _useState2[1];
|
|
22
|
+
var onClick = function onClick() {
|
|
23
|
+
setIsUpload(true);
|
|
21
24
|
};
|
|
22
|
-
return /*#__PURE__*/
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
25
|
+
return /*#__PURE__*/_jsxs(_Fragment, {
|
|
26
|
+
children: [isUpload && /*#__PURE__*/_jsx(UploadModal, {
|
|
27
|
+
imageProps: {
|
|
28
|
+
key: nodeKey,
|
|
29
|
+
src: src,
|
|
30
|
+
altText: altText,
|
|
31
|
+
width: width,
|
|
32
|
+
height: height,
|
|
33
|
+
urlType: src !== null && src !== void 0 && src.startsWith('data:image') ? 'base64' : 'url'
|
|
27
34
|
},
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
}),
|
|
31
|
-
type: "text",
|
|
32
|
-
style: {
|
|
33
|
-
width: 24
|
|
35
|
+
onCancel: function onCancel() {
|
|
36
|
+
return setIsUpload(false);
|
|
34
37
|
}
|
|
35
|
-
})
|
|
36
|
-
onClick: function onClick() {
|
|
37
|
-
return handleOnFullScreen();
|
|
38
|
-
},
|
|
39
|
-
icon: /*#__PURE__*/_jsx(FullscreenOutlined, {
|
|
40
|
-
className: "".concat(classPrefix, "-icon")
|
|
41
|
-
}),
|
|
42
|
-
type: "text",
|
|
38
|
+
}), /*#__PURE__*/_jsx("img", {
|
|
43
39
|
style: {
|
|
44
|
-
width:
|
|
40
|
+
width: width,
|
|
41
|
+
height: height
|
|
45
42
|
},
|
|
46
|
-
|
|
47
|
-
|
|
43
|
+
onClick: onClick,
|
|
44
|
+
alt: altText,
|
|
45
|
+
src: src,
|
|
46
|
+
draggable: "false"
|
|
47
|
+
})]
|
|
48
48
|
});
|
|
49
49
|
}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { DecoratorNode, LexicalNode } from 'lexical';
|
|
2
|
+
export type ImageNodeType = {
|
|
3
|
+
src: string;
|
|
4
|
+
altText: string;
|
|
5
|
+
width: string;
|
|
6
|
+
height: string;
|
|
7
|
+
key?: any;
|
|
8
|
+
nodeKey?: any;
|
|
9
|
+
urlType?: 'url' | 'base64';
|
|
10
|
+
};
|
|
11
|
+
export declare class ImageNode extends DecoratorNode<ImageNodeType> {
|
|
12
|
+
__src: string;
|
|
13
|
+
__altText: string;
|
|
14
|
+
__width: string;
|
|
15
|
+
__height: string;
|
|
16
|
+
static getType(): string;
|
|
17
|
+
static clone(node: any): ImageNode;
|
|
18
|
+
static importJSON(serializedNode: any): ImageNode;
|
|
19
|
+
exportJSON(): {
|
|
20
|
+
altText: string;
|
|
21
|
+
height: string;
|
|
22
|
+
src: string;
|
|
23
|
+
width: string;
|
|
24
|
+
type: string;
|
|
25
|
+
version: number;
|
|
26
|
+
};
|
|
27
|
+
constructor(src: string, altText: string, width: string, height: string, key?: any);
|
|
28
|
+
exportDOM(): {
|
|
29
|
+
element: HTMLImageElement;
|
|
30
|
+
};
|
|
31
|
+
createDOM(config: any): HTMLSpanElement;
|
|
32
|
+
updateDOM(): boolean;
|
|
33
|
+
static importDOM(): any;
|
|
34
|
+
updateData(config: ImageNodeType): void;
|
|
35
|
+
decorate(): any;
|
|
36
|
+
}
|
|
37
|
+
export declare function $createImageNode({ altText, height, src, width, }: ImageNodeType): ImageNode;
|
|
38
|
+
export declare function $isImageNode(node: LexicalNode): boolean;
|
|
@@ -0,0 +1,198 @@
|
|
|
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 _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
|
|
3
|
+
function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
|
|
4
|
+
function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
|
|
5
|
+
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); Object.defineProperty(subClass, "prototype", { writable: false }); if (superClass) _setPrototypeOf(subClass, superClass); }
|
|
6
|
+
function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); }
|
|
7
|
+
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
8
|
+
function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } else if (call !== void 0) { throw new TypeError("Derived constructors may only return object or undefined"); } return _assertThisInitialized(self); }
|
|
9
|
+
function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; }
|
|
10
|
+
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
11
|
+
function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); }
|
|
12
|
+
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; }
|
|
13
|
+
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == _typeof(i) ? i : String(i); }
|
|
14
|
+
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); }
|
|
15
|
+
import { DecoratorNode } from 'lexical';
|
|
16
|
+
import * as React from 'react';
|
|
17
|
+
import { Suspense } from 'react';
|
|
18
|
+
|
|
19
|
+
// 懒加载 ImageComponent 以优化性能
|
|
20
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
21
|
+
var ImageComponent = /*#__PURE__*/React.lazy(function () {
|
|
22
|
+
return import("./ImageComponent");
|
|
23
|
+
});
|
|
24
|
+
export var ImageNode = /*#__PURE__*/function (_DecoratorNode) {
|
|
25
|
+
_inherits(ImageNode, _DecoratorNode);
|
|
26
|
+
var _super = _createSuper(ImageNode);
|
|
27
|
+
function ImageNode(src, altText, width, height, key) {
|
|
28
|
+
var _this;
|
|
29
|
+
_classCallCheck(this, ImageNode);
|
|
30
|
+
_this = _super.call(this, key);
|
|
31
|
+
// 1. 定义节点类型属性
|
|
32
|
+
_defineProperty(_assertThisInitialized(_this), "__src", void 0);
|
|
33
|
+
_defineProperty(_assertThisInitialized(_this), "__altText", void 0);
|
|
34
|
+
_defineProperty(_assertThisInitialized(_this), "__width", void 0);
|
|
35
|
+
_defineProperty(_assertThisInitialized(_this), "__height", void 0);
|
|
36
|
+
_this.__src = src;
|
|
37
|
+
_this.__altText = altText;
|
|
38
|
+
_this.__width = width || 'inherit';
|
|
39
|
+
_this.__height = height || 'inherit';
|
|
40
|
+
return _this;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
// ----------------------------------------------------------------
|
|
44
|
+
// 1. exportDOM: 将 Node 转换为 HTML 标签 (用于 $generateHtmlFromNodes)
|
|
45
|
+
// ----------------------------------------------------------------
|
|
46
|
+
_createClass(ImageNode, [{
|
|
47
|
+
key: "exportJSON",
|
|
48
|
+
value: function exportJSON() {
|
|
49
|
+
return {
|
|
50
|
+
altText: this.__altText,
|
|
51
|
+
height: this.__height,
|
|
52
|
+
src: this.__src,
|
|
53
|
+
width: this.__width,
|
|
54
|
+
type: 'image',
|
|
55
|
+
version: 1
|
|
56
|
+
};
|
|
57
|
+
}
|
|
58
|
+
}, {
|
|
59
|
+
key: "exportDOM",
|
|
60
|
+
value: function exportDOM() {
|
|
61
|
+
var element = document.createElement('img');
|
|
62
|
+
element.setAttribute('src', this.__src);
|
|
63
|
+
element.setAttribute('alt', this.__altText);
|
|
64
|
+
|
|
65
|
+
// 处理宽高
|
|
66
|
+
if (this.__width) {
|
|
67
|
+
element.setAttribute('width', this.__width.toString());
|
|
68
|
+
}
|
|
69
|
+
if (this.__height) {
|
|
70
|
+
element.setAttribute('height', this.__height.toString());
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
// 返回 { element } 对象
|
|
74
|
+
return {
|
|
75
|
+
element: element
|
|
76
|
+
};
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
// 3. 创建 DOM (HTML 标签)
|
|
80
|
+
}, {
|
|
81
|
+
key: "createDOM",
|
|
82
|
+
value: function createDOM(config) {
|
|
83
|
+
var span = document.createElement('span');
|
|
84
|
+
var theme = config.theme;
|
|
85
|
+
var className = theme.image;
|
|
86
|
+
if (className !== undefined) {
|
|
87
|
+
span.className = className;
|
|
88
|
+
}
|
|
89
|
+
return span;
|
|
90
|
+
}
|
|
91
|
+
}, {
|
|
92
|
+
key: "updateDOM",
|
|
93
|
+
value: function updateDOM() {
|
|
94
|
+
return false;
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
// ----------------------------------------------------------------
|
|
98
|
+
// 2. importDOM: 从 HTML 标签转换为 Node (用于粘贴 HTML 字符串)
|
|
99
|
+
// ----------------------------------------------------------------
|
|
100
|
+
}, {
|
|
101
|
+
key: "updateData",
|
|
102
|
+
value: function updateData(config) {
|
|
103
|
+
// 关键:获取可写副本。这会标记节点为"脏"节点,触发更新流程
|
|
104
|
+
var writable = this.getWritable();
|
|
105
|
+
writable.__width = config.width;
|
|
106
|
+
writable.__height = config.height;
|
|
107
|
+
writable.__src = config.src;
|
|
108
|
+
writable.__altText = config.altText;
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
// 4. 渲染 React 组件 (视图层)
|
|
112
|
+
}, {
|
|
113
|
+
key: "decorate",
|
|
114
|
+
value: function decorate() {
|
|
115
|
+
return /*#__PURE__*/_jsx(Suspense, {
|
|
116
|
+
fallback: null,
|
|
117
|
+
children: /*#__PURE__*/_jsx(ImageComponent, {
|
|
118
|
+
src: this.__src,
|
|
119
|
+
altText: this.__altText,
|
|
120
|
+
width: this.__width,
|
|
121
|
+
height: this.__height,
|
|
122
|
+
nodeKey: this.getKey()
|
|
123
|
+
})
|
|
124
|
+
});
|
|
125
|
+
}
|
|
126
|
+
}], [{
|
|
127
|
+
key: "getType",
|
|
128
|
+
value: function getType() {
|
|
129
|
+
return 'image';
|
|
130
|
+
}
|
|
131
|
+
}, {
|
|
132
|
+
key: "clone",
|
|
133
|
+
value: function clone(node) {
|
|
134
|
+
return new ImageNode(node.__src, node.__altText, node.__width, node.__height, node.__key);
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
// 2. 序列化 (Export JSON) - 必须支持,否则双向绑定会丢失图片
|
|
138
|
+
}, {
|
|
139
|
+
key: "importJSON",
|
|
140
|
+
value: function importJSON(serializedNode) {
|
|
141
|
+
var altText = serializedNode.altText,
|
|
142
|
+
height = serializedNode.height,
|
|
143
|
+
width = serializedNode.width,
|
|
144
|
+
src = serializedNode.src;
|
|
145
|
+
return new ImageNode(src, altText, width, height);
|
|
146
|
+
}
|
|
147
|
+
}, {
|
|
148
|
+
key: "importDOM",
|
|
149
|
+
value: function importDOM() {
|
|
150
|
+
return {
|
|
151
|
+
img: function img() {
|
|
152
|
+
return {
|
|
153
|
+
// eslint-disable-next-line @typescript-eslint/no-use-before-define
|
|
154
|
+
conversion: convertImageElement,
|
|
155
|
+
priority: 0
|
|
156
|
+
};
|
|
157
|
+
}
|
|
158
|
+
};
|
|
159
|
+
}
|
|
160
|
+
}]);
|
|
161
|
+
return ImageNode;
|
|
162
|
+
}(DecoratorNode);
|
|
163
|
+
|
|
164
|
+
// 辅助函数:用于创建节点
|
|
165
|
+
export function $createImageNode(_ref) {
|
|
166
|
+
var altText = _ref.altText,
|
|
167
|
+
height = _ref.height,
|
|
168
|
+
src = _ref.src,
|
|
169
|
+
width = _ref.width;
|
|
170
|
+
return new ImageNode(src, altText, width, height);
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
// ----------------------------------------------------------------
|
|
174
|
+
// 辅助函数:用于 importDOM 解析逻辑
|
|
175
|
+
// ----------------------------------------------------------------
|
|
176
|
+
function convertImageElement(domNode) {
|
|
177
|
+
if (domNode instanceof HTMLImageElement) {
|
|
178
|
+
var altText = domNode.alt,
|
|
179
|
+
src = domNode.src,
|
|
180
|
+
width = domNode.width,
|
|
181
|
+
height = domNode.height;
|
|
182
|
+
var node = $createImageNode({
|
|
183
|
+
altText: altText,
|
|
184
|
+
height: height,
|
|
185
|
+
src: src,
|
|
186
|
+
width: width
|
|
187
|
+
});
|
|
188
|
+
return {
|
|
189
|
+
node: node
|
|
190
|
+
};
|
|
191
|
+
}
|
|
192
|
+
return null;
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
// 辅助函数:判断是否为 ImageNode
|
|
196
|
+
export function $isImageNode(node) {
|
|
197
|
+
return node instanceof ImageNode;
|
|
198
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
2
|
+
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."); }
|
|
3
|
+
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); }
|
|
4
|
+
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; }
|
|
5
|
+
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; } }
|
|
6
|
+
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
7
|
+
import { useLexicalComposerContext } from '@lexical/react/LexicalComposerContext';
|
|
8
|
+
import { $insertNodes, COMMAND_PRIORITY_EDITOR, createCommand } from 'lexical';
|
|
9
|
+
import { useEffect } from 'react';
|
|
10
|
+
import { $createImageNode } from "./ImageNode";
|
|
11
|
+
|
|
12
|
+
// 定义命令
|
|
13
|
+
export var INSERT_IMAGE_COMMAND = createCommand('INSERT_IMAGE_COMMAND');
|
|
14
|
+
export var UPDATE_IMAGE_COMMAND = createCommand('UPDATE_IMAGE_COMMAND');
|
|
15
|
+
export default function PluginImage() {
|
|
16
|
+
var _useLexicalComposerCo = useLexicalComposerContext(),
|
|
17
|
+
_useLexicalComposerCo2 = _slicedToArray(_useLexicalComposerCo, 1),
|
|
18
|
+
editor = _useLexicalComposerCo2[0];
|
|
19
|
+
useEffect(function () {
|
|
20
|
+
// 注册监听器:当 dispatch 该命令时触发
|
|
21
|
+
editor.registerCommand(INSERT_IMAGE_COMMAND, function (payload) {
|
|
22
|
+
var imageNode = $createImageNode(payload);
|
|
23
|
+
$insertNodes([imageNode]);
|
|
24
|
+
return true;
|
|
25
|
+
}, COMMAND_PRIORITY_EDITOR);
|
|
26
|
+
}, [editor]);
|
|
27
|
+
return null;
|
|
28
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
3
|
+
*
|
|
4
|
+
* This source code is licensed under the MIT license found in the
|
|
5
|
+
* LICENSE file in the root directory of this source tree.
|
|
6
|
+
*
|
|
7
|
+
*/
|
|
8
|
+
declare const PluginInitCode: ({ value, language, }: {
|
|
9
|
+
value?: string | undefined;
|
|
10
|
+
language: string;
|
|
11
|
+
}) => null;
|
|
12
|
+
export default PluginInitCode;
|