@cmstops/pro-compo 3.9.2 → 3.10.5-nanning.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +103 -76
- package/dist/index.css +97 -4
- package/dist/index.min.css +1 -1
- package/dist/index.min.js.map +1 -1
- package/es/appCenter/script/api.d.ts +5 -5
- package/es/baseFilter/component.js +71 -14
- package/es/baseFilter/components/FilterGroup.js +1 -1
- package/es/baseFilter/components/filterItem.js +1 -1
- package/es/colorPalette/component.js +1 -1
- package/es/contentDetailList/component.js +33 -9
- package/es/contentDetailList/components/Content/CircleItem/index.d.ts +0 -0
- package/es/contentDetailList/components/Content/CircleItem/index.js +92 -0
- package/es/contentDetailList/components/Content/CompoItem/index.js +12 -12
- package/es/contentDetailList/components/Content/ContentListItem/index.js +15 -15
- package/es/contentDetailList/components/Content/DocItem/ApprovalStateMap/index.js +18 -18
- package/es/contentDetailList/components/Content/DocItem/index.js +27 -27
- package/es/contentDetailList/components/Content/DocMpItem/index.js +13 -13
- package/es/contentDetailList/components/Content/GroupPieceItem/index.js +11 -11
- package/es/contentDetailList/components/Content/KongoNavItem/index.js +14 -14
- package/es/contentDetailList/components/Content/LiveItem/index.js +9 -9
- package/es/contentDetailList/components/Content/MaccountItem/index.js +12 -12
- package/es/contentDetailList/components/Content/courseItem/index.js +10 -10
- package/es/contentDetailList/components/Content/funhdItem/index.js +10 -10
- package/es/contentDetailList/components/Content/index.js +170 -117
- package/es/contentDetailList/components/CustomWrp/CustomItem.js +5 -5
- package/es/contentDetailList/components/CustomWrp/index.js +10 -10
- package/es/contentDetailList/components/Doc/index.js +16 -10
- package/es/contentDetailList/components/Records/MatrixItem/index.js +22 -22
- package/es/contentDetailList/components/Records/index.js +8 -8
- package/es/contentDetailList/components/ShowQRCode/QrcodeView/index.js +6 -6
- package/es/contentDetailList/components/ShowQRCode/index.js +1 -1
- package/es/contentDetailList/script/api.d.ts +2 -2
- package/es/contentModal/component.js +40 -40
- package/es/contentModal/components/CompoList/index.js +1 -1
- package/es/contentModal/components/Dejin/index.js +1 -1
- package/es/contentModal/components/MpContentList/MediaFilter/index.js +2 -2
- package/es/contentModal/components/MpContentList/index.js +1 -1
- package/es/contentModal/components/ViewAllColumn/MediaFilter/index.js +3 -3
- package/es/contentModal/components/ViewAllColumn/index.js +7 -3
- package/es/contentModal/components/storeBox/index.js +8 -8
- package/es/contentModal/script/api.d.ts +13 -13
- package/es/dataTags/component.js +38 -38
- package/es/docHistory/component.js +44 -15
- package/es/docHistory/components/DocDiffPanel/index.js +2 -2
- package/es/docHistory/components/DocHistoryList/index.js +2 -2
- package/es/docHistory/scripts/diff.js +4 -3
- package/es/docHistory/scripts/useDocHistory.d.ts +1 -1
- package/es/docHistory/style/index.css +4 -0
- package/es/docHistory/style/index.less +5 -0
- package/es/docPreview/component.js +228 -60
- package/es/docPreview/components/PreviewIframe.js +37 -6
- package/es/docPreview/images/pc.js +2 -0
- package/es/docPreview/scripts/api.d.ts +2 -1
- package/es/docPreview/scripts/hook.d.ts +11 -1
- package/es/docPreview/scripts/hook.js +115 -4
- package/es/docPreview/style/index.css +48 -0
- package/es/docPreview/style/index.less +23 -0
- package/es/docPreview/style/previewIframe.less +31 -0
- package/es/editMetaInfo/component.js +24 -4
- package/es/editMetaInfo/components/metaInfoForm.js +358 -17
- package/es/editMetaInfo/script/api.d.ts +9 -2
- package/es/editMetaInfo/script/api.js +20 -1
- package/es/emptyData/component.js +4 -4
- package/es/emptyData/svg/acount.js +2 -2
- package/es/emptyData/svg/add.js +2 -2
- package/es/emptyData/svg/analize.js +2 -2
- package/es/emptyData/svg/analize_fail.js +2 -2
- package/es/emptyData/svg/empty.js +2 -2
- package/es/emptyData/svg/file.js +2 -2
- package/es/emptyData/svg/manager.js +2 -2
- package/es/emptyData/svg/message.js +2 -2
- package/es/emptyData/svg/noanalize.js +2 -2
- package/es/emptyData/svg/null.js +2 -2
- package/es/emptyData/svg/search.js +2 -2
- package/es/emptyData/svg/star.js +2 -2
- package/es/emptyData/svg/trash.js +2 -2
- package/es/emptyData/svg/user.js +2 -2
- package/es/hooks/assets.d.ts +1 -1
- package/es/hooks/source.d.ts +1 -1
- package/es/hooks/useAttachement.d.ts +32 -13
- package/es/hooks/useAttachement.js +42 -2
- package/es/hooks/usePopper.d.ts +1 -1
- package/es/hooks/usePopper.js +3 -3
- package/es/hooks/useUpload.d.ts +53 -5
- package/es/hooks/useUpload.js +43 -4
- package/es/hooks/user.d.ts +1 -1
- package/es/imageCrop/component.js +11 -11
- package/es/imageCrop/script/api.d.ts +1 -1
- package/es/importData/component.js +13 -13
- package/es/index.css +97 -4
- package/es/index.d.ts +1 -0
- package/es/index.js +1 -0
- package/es/mediaFilter/component.js +4 -4
- package/es/mediaFilter/components/DocFilter.js +1 -1
- package/es/mediaFilter/components/FilterGroup.js +1 -1
- package/es/mediaFilter/components/FilterItem.js +1 -1
- package/es/mediaView/component.js +8 -8
- package/es/messageBox/component.js +3 -3
- package/es/messageBox/script/api.d.ts +2 -2
- package/es/previousVersion/script/api.d.ts +4 -4
- package/es/resourceGridList/component.js +16 -16
- package/es/resourceGridList/components/FileTypeThumb/index.js +6 -6
- package/es/resourceModal/component.js +7 -7
- package/es/resourceModal/components/MediaPreviewer/index.js +8 -8
- package/es/resourceModal/components/MediaSelection/DocAiMediaSelected/index.js +5 -5
- package/es/resourceModal/components/MediaSelection/MainContent/FileTypeThumb/index.js +6 -6
- package/es/resourceModal/components/MediaSelection/MainContent/index.js +18 -18
- package/es/resourceModal/components/MediaSelection/SystemResourceSelected/components/SystemResourceFilter.js +3 -3
- package/es/resourceModal/components/MediaSelection/SystemResourceSelected/components/SystemResourceList.js +3 -3
- package/es/resourceModal/components/MediaSelection/SystemResourceSelected/index.js +2 -2
- package/es/resourceModal/components/MediaSelection/ToolbarSearch/index.js +4 -4
- package/es/resourceModal/components/MediaSelection/index.js +6 -6
- package/es/resourceModal/script/api.d.ts +11 -11
- package/es/selectAddTo/component.d.ts +0 -0
- package/es/selectAddTo/component.js +47 -0
- package/es/selectAddTo/component.vue_vue_type_style_index_0_scoped_true_lang.js +2 -0
- package/es/selectAddTo/components/SelectAddToView.d.ts +0 -0
- package/es/selectAddTo/components/SelectAddToView.js +90 -0
- package/es/selectAddTo/components/SelectAddToView.vue_vue_type_style_index_0_scoped_true_lang.js +2 -0
- package/es/selectAddTo/components/ViewAllColumn/MediaFilter/index.d.ts +0 -0
- package/es/selectAddTo/components/ViewAllColumn/MediaFilter/index.js +166 -0
- package/es/selectAddTo/components/ViewAllColumn/index.d.ts +0 -0
- package/es/selectAddTo/components/ViewAllColumn/index.js +212 -0
- package/es/selectAddTo/components/ViewAllColumn/index.vue_vue_type_style_index_0_scoped_true_lang.js +2 -0
- package/es/selectAddTo/components/ViewAllColumn/script/useTableColumns.d.ts +6 -0
- package/es/selectAddTo/components/ViewAllColumn/script/useTableColumns.js +102 -0
- package/es/selectAddTo/components/ViewAllColumn/script/useViewAllColumnState.d.ts +144 -0
- package/es/selectAddTo/components/ViewAllColumn/script/useViewAllColumnState.js +182 -0
- package/es/selectAddTo/components/ViewAllColumn/types/index.d.ts +55 -0
- package/es/selectAddTo/index.d.ts +2 -0
- package/es/selectAddTo/index.js +7 -0
- package/es/selectAddTo/script/api.d.ts +18 -0
- package/es/selectAddTo/script/api.js +23 -0
- package/es/selectAddTo/script/index.d.ts +2 -0
- package/es/selectAddTo/script/useSelectAddToState.d.ts +13 -0
- package/es/selectAddTo/script/useSelectAddToState.js +55 -0
- package/es/selectAddTo/style/css.js +1 -0
- package/es/selectAddTo/style/index.css +3 -0
- package/es/selectAddTo/style/index.d.ts +1 -0
- package/es/selectAddTo/style/index.js +1 -0
- package/es/selectAddTo/style/index.less +3 -0
- package/es/selectAddTo/types/index.d.ts +37 -0
- package/es/selectGategory/component.js +5 -5
- package/es/selectGategory/components/ColumnSelection/index.js +6 -6
- package/es/selectGategory/script/api.d.ts +2 -2
- package/es/selectResourceModal/__demo__/module/DivWrapper.d.ts +261 -0
- package/es/selectResourceModal/__demo__/module/basic.d.ts +292 -0
- package/es/selectResourceModal/component.js +26 -34
- package/es/selectResourceModal/components/List/ListCardWrapper.js +6 -6
- package/es/selectResourceModal/components/List/ListLocal/Upload.js +1 -1
- package/es/selectResourceModal/components/List/ListLocal/index.js +8 -3
- package/es/selectResourceModal/components/List/ListNormal/Filter.js +210 -83
- package/es/selectResourceModal/components/List/ListNormal/index.js +23 -7
- package/es/selectResourceModal/components/List/ListSystem/Filter.js +3 -3
- package/es/selectResourceModal/components/List/ListSystem/SubList.js +3 -3
- package/es/selectResourceModal/components/List/ListSystem/index.js +2 -2
- package/es/selectResourceModal/components/List/ListWraper.js +2 -2
- package/es/selectResourceModal/components/ListSelected/index.js +6 -6
- package/es/selectResourceModal/components/ListTabs/index.js +1 -1
- package/es/selectResourceModal/hooks/useResponsiveFilter.d.ts +21 -0
- package/es/selectResourceModal/hooks/useResponsiveFilter.js +142 -0
- package/es/selectResourceModal/scripts/selectionApis.d.ts +2 -2
- package/es/selectResourceModal/scripts/useCompoLf.js +1 -1
- package/es/selectResourceModal/scripts/useTabFilter.js +1 -11
- package/es/selectResourceModal/style/index.css +45 -4
- package/es/selectResourceModal/style/index.less +14 -0
- package/es/selectResourceModal/style/list.less +40 -4
- package/es/selectThumb/component.js +76 -33
- package/es/selectThumb/components/card.js +3 -3
- package/es/style.css +63 -0
- package/es/thumbCard/component.js +7 -7
- package/es/thumbCard/components/ThumbUploading/index.js +3 -3
- package/es/typeIcons/component.js +1 -1
- package/es/uploadBefore/component.js +1 -1
- package/es/uploadBefore/components/UploadBefore.js +9 -9
- package/es/uploadBefore/script/api.d.ts +4 -4
- package/es/uploadStep/component.js +3 -3
- package/es/userAvater/component.js +3 -3
- package/es/userAvater/script/api.d.ts +4 -4
- package/es/userDirector/component.js +5 -5
- package/es/userDirector/components/userTree.js +2 -2
- package/es/userDirector/script/api.d.ts +6 -6
- package/es/utils/index.js +6 -6
- package/es/utils/request.d.ts +1 -1
- package/es/utils/transcodeMedia.d.ts +1 -1
- package/es/videoThumb/scripts/api.d.ts +1 -1
- package/lib/baseFilter/component.js +69 -12
- package/lib/baseFilter/components/FilterGroup.js +1 -1
- package/lib/baseFilter/components/filterItem.js +1 -1
- package/lib/colorPalette/component.js +1 -1
- package/lib/contentDetailList/component.js +33 -9
- package/lib/contentDetailList/components/Content/CircleItem/index.js +93 -0
- package/lib/contentDetailList/components/Content/CompoItem/index.js +12 -12
- package/lib/contentDetailList/components/Content/ContentListItem/index.js +15 -15
- package/lib/contentDetailList/components/Content/DocItem/ApprovalStateMap/index.js +18 -18
- package/lib/contentDetailList/components/Content/DocItem/index.js +27 -27
- package/lib/contentDetailList/components/Content/DocMpItem/index.js +13 -13
- package/lib/contentDetailList/components/Content/GroupPieceItem/index.js +11 -11
- package/lib/contentDetailList/components/Content/KongoNavItem/index.js +14 -14
- package/lib/contentDetailList/components/Content/LiveItem/index.js +9 -9
- package/lib/contentDetailList/components/Content/MaccountItem/index.js +12 -12
- package/lib/contentDetailList/components/Content/courseItem/index.js +10 -10
- package/lib/contentDetailList/components/Content/funhdItem/index.js +10 -10
- package/lib/contentDetailList/components/Content/index.js +170 -117
- package/lib/contentDetailList/components/CustomWrp/CustomItem.js +5 -5
- package/lib/contentDetailList/components/CustomWrp/index.js +10 -10
- package/lib/contentDetailList/components/Doc/index.js +16 -10
- package/lib/contentDetailList/components/Records/MatrixItem/index.js +22 -22
- package/lib/contentDetailList/components/Records/index.js +8 -8
- package/lib/contentDetailList/components/ShowQRCode/QrcodeView/index.js +6 -6
- package/lib/contentDetailList/components/ShowQRCode/index.js +1 -1
- package/lib/contentModal/component.js +40 -40
- package/lib/contentModal/components/CompoList/index.js +1 -1
- package/lib/contentModal/components/Dejin/index.js +1 -1
- package/lib/contentModal/components/MpContentList/MediaFilter/index.js +2 -2
- package/lib/contentModal/components/MpContentList/index.js +1 -1
- package/lib/contentModal/components/ViewAllColumn/MediaFilter/index.js +3 -3
- package/lib/contentModal/components/ViewAllColumn/index.js +7 -3
- package/lib/contentModal/components/storeBox/index.js +8 -8
- package/lib/dataTags/component.js +38 -38
- package/lib/docHistory/component.js +42 -13
- package/lib/docHistory/components/DocDiffPanel/index.js +2 -2
- package/lib/docHistory/components/DocHistoryList/index.js +2 -2
- package/lib/docHistory/scripts/diff.js +4 -3
- package/lib/docHistory/style/index.css +4 -0
- package/lib/docHistory/style/index.less +5 -0
- package/lib/docPreview/component.js +227 -59
- package/lib/docPreview/components/PreviewIframe.js +37 -6
- package/lib/docPreview/images/pc.js +3 -0
- package/lib/docPreview/scripts/hook.js +115 -3
- package/lib/docPreview/style/index.css +48 -0
- package/lib/docPreview/style/index.less +23 -0
- package/lib/docPreview/style/previewIframe.less +31 -0
- package/lib/editMetaInfo/component.js +23 -3
- package/lib/editMetaInfo/components/metaInfoForm.js +356 -15
- package/lib/editMetaInfo/script/api.js +21 -0
- package/lib/emptyData/component.js +4 -4
- package/lib/emptyData/svg/acount.js +2 -2
- package/lib/emptyData/svg/add.js +2 -2
- package/lib/emptyData/svg/analize.js +2 -2
- package/lib/emptyData/svg/analize_fail.js +2 -2
- package/lib/emptyData/svg/empty.js +2 -2
- package/lib/emptyData/svg/file.js +2 -2
- package/lib/emptyData/svg/manager.js +2 -2
- package/lib/emptyData/svg/message.js +2 -2
- package/lib/emptyData/svg/noanalize.js +2 -2
- package/lib/emptyData/svg/null.js +2 -2
- package/lib/emptyData/svg/search.js +2 -2
- package/lib/emptyData/svg/star.js +2 -2
- package/lib/emptyData/svg/trash.js +2 -2
- package/lib/emptyData/svg/user.js +2 -2
- package/lib/hooks/useAttachement.js +42 -0
- package/lib/hooks/usePopper.js +3 -3
- package/lib/hooks/useUpload.js +43 -3
- package/lib/imageCrop/component.js +11 -11
- package/lib/importData/component.js +13 -13
- package/lib/index.css +97 -4
- package/lib/index.js +2 -0
- package/lib/mediaFilter/component.js +4 -4
- package/lib/mediaFilter/components/DocFilter.js +1 -1
- package/lib/mediaFilter/components/FilterGroup.js +1 -1
- package/lib/mediaFilter/components/FilterItem.js +1 -1
- package/lib/mediaView/component.js +8 -8
- package/lib/messageBox/component.js +3 -3
- package/lib/resourceGridList/component.js +16 -16
- package/lib/resourceGridList/components/FileTypeThumb/index.js +6 -6
- package/lib/resourceModal/component.js +7 -7
- package/lib/resourceModal/components/MediaPreviewer/index.js +8 -8
- package/lib/resourceModal/components/MediaSelection/DocAiMediaSelected/index.js +5 -5
- package/lib/resourceModal/components/MediaSelection/MainContent/FileTypeThumb/index.js +6 -6
- package/lib/resourceModal/components/MediaSelection/MainContent/index.js +18 -18
- package/lib/resourceModal/components/MediaSelection/SystemResourceSelected/components/SystemResourceFilter.js +3 -3
- package/lib/resourceModal/components/MediaSelection/SystemResourceSelected/components/SystemResourceList.js +3 -3
- package/lib/resourceModal/components/MediaSelection/SystemResourceSelected/index.js +2 -2
- package/lib/resourceModal/components/MediaSelection/ToolbarSearch/index.js +4 -4
- package/lib/resourceModal/components/MediaSelection/index.js +6 -6
- package/lib/selectAddTo/component.js +48 -0
- package/lib/selectAddTo/component.vue_vue_type_style_index_0_scoped_true_lang.js +3 -0
- package/lib/selectAddTo/components/SelectAddToView.js +91 -0
- package/lib/selectAddTo/components/SelectAddToView.vue_vue_type_style_index_0_scoped_true_lang.js +3 -0
- package/lib/selectAddTo/components/ViewAllColumn/MediaFilter/index.js +167 -0
- package/lib/selectAddTo/components/ViewAllColumn/index.js +213 -0
- package/lib/selectAddTo/components/ViewAllColumn/index.vue_vue_type_style_index_0_scoped_true_lang.js +3 -0
- package/lib/selectAddTo/components/ViewAllColumn/script/useTableColumns.js +108 -0
- package/lib/selectAddTo/components/ViewAllColumn/script/useViewAllColumnState.js +184 -0
- package/lib/selectAddTo/index.js +8 -0
- package/lib/selectAddTo/script/api.js +27 -0
- package/lib/selectAddTo/script/useSelectAddToState.js +57 -0
- package/lib/selectAddTo/style/css.js +2 -0
- package/lib/selectAddTo/style/index.css +3 -0
- package/lib/selectAddTo/style/index.js +2 -0
- package/lib/selectAddTo/style/index.less +3 -0
- package/lib/selectGategory/component.js +5 -5
- package/lib/selectGategory/components/ColumnSelection/index.js +6 -6
- package/lib/selectResourceModal/component.js +25 -33
- package/lib/selectResourceModal/components/List/ListCardWrapper.js +6 -6
- package/lib/selectResourceModal/components/List/ListLocal/Upload.js +1 -1
- package/lib/selectResourceModal/components/List/ListLocal/index.js +6 -1
- package/lib/selectResourceModal/components/List/ListNormal/Filter.js +207 -80
- package/lib/selectResourceModal/components/List/ListNormal/index.js +22 -6
- package/lib/selectResourceModal/components/List/ListSystem/Filter.js +3 -3
- package/lib/selectResourceModal/components/List/ListSystem/SubList.js +3 -3
- package/lib/selectResourceModal/components/List/ListSystem/index.js +2 -2
- package/lib/selectResourceModal/components/List/ListWraper.js +2 -2
- package/lib/selectResourceModal/components/ListSelected/index.js +6 -6
- package/lib/selectResourceModal/components/ListTabs/index.js +1 -1
- package/lib/selectResourceModal/hooks/useResponsiveFilter.js +144 -0
- package/lib/selectResourceModal/scripts/useCompoLf.js +1 -1
- package/lib/selectResourceModal/scripts/useTabFilter.js +1 -13
- package/lib/selectResourceModal/style/index.css +45 -4
- package/lib/selectResourceModal/style/index.less +14 -0
- package/lib/selectResourceModal/style/list.less +40 -4
- package/lib/selectThumb/component.js +75 -32
- package/lib/selectThumb/components/card.js +3 -3
- package/lib/thumbCard/component.js +7 -7
- package/lib/thumbCard/components/ThumbUploading/index.js +3 -3
- package/lib/typeIcons/component.js +1 -1
- package/lib/uploadBefore/component.js +1 -1
- package/lib/uploadBefore/components/UploadBefore.js +9 -9
- package/lib/uploadStep/component.js +3 -3
- package/lib/userAvater/component.js +3 -3
- package/lib/userDirector/component.js +5 -5
- package/lib/userDirector/components/userTree.js +2 -2
- package/lib/utils/index.js +6 -6
- package/package.json +1 -1
|
@@ -70,12 +70,12 @@ const _sfc_main = defineComponent({
|
|
|
70
70
|
class: normalizeClass(["card-wrapper", { disable: !canIUse.value, active: selectedOrder.value[resourceKey.value] }])
|
|
71
71
|
}, [
|
|
72
72
|
createVNode(unref(thumbCard), {
|
|
73
|
-
url:
|
|
74
|
-
thumb:
|
|
75
|
-
catalog:
|
|
76
|
-
meta:
|
|
73
|
+
url: __props.item.url,
|
|
74
|
+
thumb: __props.item.thumb || __props.item.url,
|
|
75
|
+
catalog: __props.item.catalog,
|
|
76
|
+
meta: __props.item,
|
|
77
77
|
options: {
|
|
78
|
-
fit: ["image", "video"].includes(
|
|
78
|
+
fit: ["image", "video"].includes(__props.item.catalog) ? "contain" : "cover"
|
|
79
79
|
},
|
|
80
80
|
"use-mask": true,
|
|
81
81
|
"handlers-key": handlersKey.value,
|
|
@@ -83,7 +83,7 @@ const _sfc_main = defineComponent({
|
|
|
83
83
|
}, null, 8, ["url", "thumb", "catalog", "meta", "options", "handlers-key"]),
|
|
84
84
|
_cache[1] || (_cache[1] = createElementVNode("div", { class: "mask" }, null, -1))
|
|
85
85
|
], 2),
|
|
86
|
-
createElementVNode("div", _hoisted_1, toDisplayString(
|
|
86
|
+
createElementVNode("div", _hoisted_1, toDisplayString(__props.item.alias), 1),
|
|
87
87
|
createElementVNode("div", {
|
|
88
88
|
class: "check-box-wrapper",
|
|
89
89
|
onClick: withModifiers(handleCheck, ["stop"])
|
|
@@ -45,7 +45,7 @@ const _sfc_main = defineComponent({
|
|
|
45
45
|
createVNode(unref(IconComputer))
|
|
46
46
|
]),
|
|
47
47
|
default: withCtx(() => [
|
|
48
|
-
_cache[0] || (_cache[0] = createTextVNode(" \u672C\u5730\u4E0A\u4F20 "))
|
|
48
|
+
_cache[0] || (_cache[0] = createTextVNode(" \u672C\u5730\u4E0A\u4F20 ", -1))
|
|
49
49
|
]),
|
|
50
50
|
_: 1
|
|
51
51
|
})
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { defineComponent, inject, computed, openBlock, createBlock, withCtx, renderSlot, createElementVNode, createVNode, unref, createElementBlock, toDisplayString, createCommentVNode, Fragment, renderList } from "vue";
|
|
1
|
+
import { defineComponent, inject, computed, onMounted, openBlock, createBlock, withCtx, renderSlot, createElementVNode, createVNode, unref, createElementBlock, toDisplayString, createCommentVNode, Fragment, renderList } from "vue";
|
|
2
2
|
import _sfc_main$2 from "./Upload.js";
|
|
3
|
-
import useUpload from "../../../../hooks/useUpload.js";
|
|
3
|
+
import useUpload, { useUploadConfig } from "../../../../hooks/useUpload.js";
|
|
4
4
|
import _sfc_main$1 from "../ListWraper.js";
|
|
5
5
|
const _hoisted_1 = { class: "list-upload" };
|
|
6
6
|
const _hoisted_2 = { class: "list-content" };
|
|
@@ -22,6 +22,7 @@ const _sfc_main = defineComponent({
|
|
|
22
22
|
var _a;
|
|
23
23
|
return (_a = userInfo == null ? void 0 : userInfo.value) == null ? void 0 : _a.repository_id;
|
|
24
24
|
});
|
|
25
|
+
const { template, initTemplate } = useUploadConfig();
|
|
25
26
|
const { list, uploadFile, reTranscode, transcodingFile, removeRecord } = useUpload();
|
|
26
27
|
function handleChange(file) {
|
|
27
28
|
if (!baseAPI || !repoId.value)
|
|
@@ -31,7 +32,8 @@ const _sfc_main = defineComponent({
|
|
|
31
32
|
file.file,
|
|
32
33
|
0,
|
|
33
34
|
repoId.value,
|
|
34
|
-
(media) => transcodingFile(baseAPI, media, repoId.value)
|
|
35
|
+
(media) => transcodingFile(baseAPI, media, repoId.value),
|
|
36
|
+
{ template: template.value }
|
|
35
37
|
);
|
|
36
38
|
}
|
|
37
39
|
async function handleOptions(e) {
|
|
@@ -54,6 +56,9 @@ const _sfc_main = defineComponent({
|
|
|
54
56
|
removeRecord(e.item);
|
|
55
57
|
}
|
|
56
58
|
}
|
|
59
|
+
onMounted(() => {
|
|
60
|
+
initTemplate(baseAPI);
|
|
61
|
+
});
|
|
57
62
|
return (_ctx, _cache) => {
|
|
58
63
|
return openBlock(), createBlock(_sfc_main$1, null, {
|
|
59
64
|
"footer-extra": withCtx(() => [
|
|
@@ -1,42 +1,71 @@
|
|
|
1
|
-
import { defineComponent, inject, computed, ref, watch, onMounted, openBlock, createElementBlock, createElementVNode,
|
|
2
|
-
import { Input, Dropdown, Doption,
|
|
3
|
-
import { IconUpload } from "@arco-design/web-vue/es/icon";
|
|
1
|
+
import { defineComponent, inject, computed, ref, watch, onMounted, openBlock, createElementBlock, createCommentVNode, createElementVNode, withDirectives, createVNode, unref, withModifiers, withCtx, createTextVNode, vShow, toDisplayString, Fragment, renderList, createBlock, normalizeClass } from "vue";
|
|
2
|
+
import { Button, Input, Dropdown, Doption, TreeSelect, Select, Option, RangePicker } from "@arco-design/web-vue";
|
|
3
|
+
import { IconCaretDown, IconRefresh, IconUpload } from "@arco-design/web-vue/es/icon";
|
|
4
4
|
import useSelection from "../../../../hooks/useSelection.js";
|
|
5
|
+
import { useDirectory } from "../../../../hooks/useAttachement.js";
|
|
5
6
|
import { RESOURCE_SOURCE_OPTIONS, RESOURCE_CATALOG_OPTIONS } from "../../../../utils/typeMap.js";
|
|
6
7
|
import { getAccountList } from "../../../scripts/selectionApis.js";
|
|
7
8
|
import { keywordsSelection } from "../../../../utils/resource.js";
|
|
9
|
+
import { useResponsiveFilter } from "../../../hooks/useResponsiveFilter.js";
|
|
8
10
|
const _hoisted_1 = { class: "list-filter-wrapper" };
|
|
9
11
|
const _hoisted_2 = { class: "list-filter" };
|
|
10
|
-
const _hoisted_3 = { class: "
|
|
11
|
-
const _hoisted_4 = {
|
|
12
|
+
const _hoisted_3 = { class: "more-btn" };
|
|
13
|
+
const _hoisted_4 = { class: "right-prefix" };
|
|
12
14
|
const _hoisted_5 = {
|
|
13
15
|
class: "filter-item",
|
|
14
16
|
style: { "width": "200px" }
|
|
15
17
|
};
|
|
16
|
-
const _hoisted_6 = {
|
|
18
|
+
const _hoisted_6 = {
|
|
19
|
+
class: "filter-item",
|
|
20
|
+
style: { "width": "180px" }
|
|
21
|
+
};
|
|
17
22
|
const _hoisted_7 = {
|
|
23
|
+
class: "filter-item",
|
|
24
|
+
style: { "width": "170px" }
|
|
25
|
+
};
|
|
26
|
+
const _hoisted_8 = {
|
|
27
|
+
class: "filter-item",
|
|
28
|
+
style: { "width": "240px" }
|
|
29
|
+
};
|
|
30
|
+
const _hoisted_9 = {
|
|
31
|
+
class: "filter-item",
|
|
32
|
+
style: { "width": "240px" }
|
|
33
|
+
};
|
|
34
|
+
const _hoisted_10 = {
|
|
18
35
|
key: 0,
|
|
19
36
|
class: "filter-item"
|
|
20
37
|
};
|
|
21
|
-
const
|
|
22
|
-
const
|
|
38
|
+
const _hoisted_11 = { class: "filter-extra" };
|
|
39
|
+
const _hoisted_12 = { class: "filter-item" };
|
|
40
|
+
const _hoisted_13 = {
|
|
23
41
|
key: 0,
|
|
24
42
|
class: "list-filter-tags"
|
|
25
43
|
};
|
|
26
|
-
const
|
|
44
|
+
const _hoisted_14 = ["onClick"];
|
|
27
45
|
const _sfc_main = defineComponent({
|
|
28
46
|
__name: "Filter",
|
|
29
47
|
props: {
|
|
48
|
+
smallScreen: { type: Boolean },
|
|
30
49
|
disableUploadBy: { type: Boolean }
|
|
31
50
|
},
|
|
32
51
|
emits: ["upload", "change"],
|
|
33
52
|
setup(__props, { expose: __expose, emit: __emit }) {
|
|
53
|
+
var _a, _b, _c;
|
|
34
54
|
const props = __props;
|
|
35
55
|
const emits = __emit;
|
|
36
56
|
const userInfo = inject("userInfo");
|
|
37
57
|
const baseAPI = inject("baseAPI");
|
|
38
58
|
const filterOptions = inject("filterOptions");
|
|
39
59
|
const domainId = computed(() => userInfo == null ? void 0 : userInfo.value.domain_id);
|
|
60
|
+
const filterItemsRef = ref();
|
|
61
|
+
const {
|
|
62
|
+
moreBtnRef,
|
|
63
|
+
popperPanelRef,
|
|
64
|
+
hiddenElementList,
|
|
65
|
+
visible,
|
|
66
|
+
show,
|
|
67
|
+
hide
|
|
68
|
+
} = useResponsiveFilter(filterItemsRef);
|
|
40
69
|
const { options, loading, load, loadMore, handleSearch } = useSelection({
|
|
41
70
|
labelStr: "alias",
|
|
42
71
|
valueStr: "id",
|
|
@@ -56,6 +85,9 @@ const _sfc_main = defineComponent({
|
|
|
56
85
|
});
|
|
57
86
|
const resourceSource = RESOURCE_SOURCE_OPTIONS;
|
|
58
87
|
const resourceCatalog = RESOURCE_CATALOG_OPTIONS;
|
|
88
|
+
const { tree } = useDirectory({
|
|
89
|
+
BASE_API: baseAPI
|
|
90
|
+
});
|
|
59
91
|
const originFilter = {
|
|
60
92
|
catalog: [],
|
|
61
93
|
source: "",
|
|
@@ -64,9 +96,20 @@ const _sfc_main = defineComponent({
|
|
|
64
96
|
keyword: "",
|
|
65
97
|
precise_keyword: "",
|
|
66
98
|
upload_by: null,
|
|
67
|
-
sf: ""
|
|
99
|
+
sf: "",
|
|
100
|
+
directory_id: void 0
|
|
68
101
|
};
|
|
69
|
-
|
|
102
|
+
if ((_a = filterOptions == null ? void 0 : filterOptions.value) == null ? void 0 : _a.mediaTypeStrict) {
|
|
103
|
+
originFilter.catalog = filterOptions.value.mediaType.split(",");
|
|
104
|
+
}
|
|
105
|
+
const filter = ref(
|
|
106
|
+
JSON.parse(
|
|
107
|
+
JSON.stringify({
|
|
108
|
+
...originFilter,
|
|
109
|
+
catalog: ((_c = (_b = filterOptions == null ? void 0 : filterOptions.value) == null ? void 0 : _b.mediaType) == null ? void 0 : _c.split(",")) || []
|
|
110
|
+
})
|
|
111
|
+
)
|
|
112
|
+
);
|
|
70
113
|
const handleReset = () => {
|
|
71
114
|
filter.value = JSON.parse(JSON.stringify(originFilter));
|
|
72
115
|
};
|
|
@@ -111,84 +154,116 @@ const _sfc_main = defineComponent({
|
|
|
111
154
|
filter.value.keyword = val;
|
|
112
155
|
filter.value.precise_keyword = "";
|
|
113
156
|
}
|
|
157
|
+
filter.value.sf = "";
|
|
114
158
|
}
|
|
115
159
|
});
|
|
116
|
-
watch(
|
|
117
|
-
() => searchType.value,
|
|
118
|
-
() => {
|
|
119
|
-
searchInput.value = filter.value.keyword || filter.value.precise_keyword;
|
|
120
|
-
}
|
|
121
|
-
);
|
|
122
160
|
const isEmpty = computed(() => {
|
|
123
|
-
return Object.keys(
|
|
161
|
+
return Object.keys(originFilter).every((key) => {
|
|
162
|
+
if (key === "catalog") {
|
|
163
|
+
const currentCatalog = filter.value[key] || [];
|
|
164
|
+
const originCatalog = originFilter[key] || [];
|
|
165
|
+
return currentCatalog.length === originCatalog.length && currentCatalog.every((v) => originCatalog.includes(v));
|
|
166
|
+
}
|
|
124
167
|
return filter.value[key] === originFilter[key];
|
|
125
168
|
});
|
|
126
169
|
});
|
|
127
170
|
watch(
|
|
128
171
|
() => filter.value,
|
|
129
|
-
() => {
|
|
130
|
-
const result = { ...
|
|
172
|
+
(val) => {
|
|
173
|
+
const result = { ...val };
|
|
131
174
|
Object.keys(result).forEach((key) => {
|
|
132
175
|
if (props.disableUploadBy && key === "upload_by")
|
|
133
176
|
delete result[key];
|
|
134
|
-
if (
|
|
135
|
-
|
|
177
|
+
if (result[key] === "" || result[key] === null || result[key] === void 0) {
|
|
178
|
+
if (key !== "catalog") {
|
|
179
|
+
delete result[key];
|
|
180
|
+
}
|
|
181
|
+
}
|
|
136
182
|
});
|
|
137
|
-
if (
|
|
138
|
-
result.catalog
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
},
|
|
143
|
-
{ deep: true, immediate: true }
|
|
144
|
-
);
|
|
145
|
-
watch(
|
|
146
|
-
() => filterOptions == null ? void 0 : filterOptions.value,
|
|
147
|
-
() => {
|
|
148
|
-
var _a;
|
|
149
|
-
if ((_a = filterOptions == null ? void 0 : filterOptions.value) == null ? void 0 : _a.mediaType) {
|
|
150
|
-
filter.value.catalog = filterOptions == null ? void 0 : filterOptions.value.mediaType.split(",");
|
|
151
|
-
if (filterOptions == null ? void 0 : filterOptions.value.mediaTypeStrict) {
|
|
152
|
-
originFilter.catalog = filterOptions == null ? void 0 : filterOptions.value.mediaType.split(",");
|
|
183
|
+
if (result.catalog && Array.isArray(result.catalog)) {
|
|
184
|
+
if (result.catalog.length > 0) {
|
|
185
|
+
result.catalog = result.catalog.join(",");
|
|
186
|
+
} else {
|
|
187
|
+
delete result.catalog;
|
|
153
188
|
}
|
|
154
189
|
}
|
|
190
|
+
emits("change", result);
|
|
155
191
|
},
|
|
156
|
-
{
|
|
192
|
+
{ deep: true, immediate: true }
|
|
157
193
|
);
|
|
158
194
|
onMounted(() => {
|
|
159
195
|
load();
|
|
160
196
|
});
|
|
161
197
|
__expose({
|
|
162
|
-
|
|
198
|
+
filter,
|
|
199
|
+
handleReset
|
|
163
200
|
});
|
|
164
201
|
return (_ctx, _cache) => {
|
|
165
|
-
var
|
|
202
|
+
var _a2;
|
|
166
203
|
return openBlock(), createElementBlock("div", _hoisted_1, [
|
|
204
|
+
createCommentVNode(" Use filterItemsRef's parentElement as the container for boundary checks "),
|
|
167
205
|
createElementVNode("div", _hoisted_2, [
|
|
168
|
-
|
|
206
|
+
createCommentVNode(" Filter Items Container "),
|
|
207
|
+
createElementVNode("div", {
|
|
208
|
+
id: "resource-filter-pannel",
|
|
209
|
+
ref_key: "filterItemsRef",
|
|
210
|
+
ref: filterItemsRef,
|
|
211
|
+
class: "filter-list"
|
|
212
|
+
}, [
|
|
213
|
+
createCommentVNode(" More Filters Button and Popper Panel "),
|
|
214
|
+
createElementVNode("div", _hoisted_3, [
|
|
215
|
+
createElementVNode("div", {
|
|
216
|
+
ref_key: "moreBtnRef",
|
|
217
|
+
ref: moreBtnRef
|
|
218
|
+
}, [
|
|
219
|
+
withDirectives(createVNode(unref(Button), {
|
|
220
|
+
style: { marginRight: "10px" },
|
|
221
|
+
onClick: _cache[0] || (_cache[0] = withModifiers(() => unref(visible) ? unref(hide)() : unref(show)(), ["stop"]))
|
|
222
|
+
}, {
|
|
223
|
+
default: withCtx(() => [
|
|
224
|
+
createElementVNode("span", _hoisted_4, [
|
|
225
|
+
_cache[11] || (_cache[11] = createTextVNode(" \u66F4\u591A ", -1)),
|
|
226
|
+
createVNode(unref(IconCaretDown))
|
|
227
|
+
])
|
|
228
|
+
]),
|
|
229
|
+
_: 1
|
|
230
|
+
}, 512), [
|
|
231
|
+
[vShow, unref(hiddenElementList).length]
|
|
232
|
+
])
|
|
233
|
+
], 512),
|
|
234
|
+
withDirectives(createElementVNode("div", {
|
|
235
|
+
ref_key: "popperPanelRef",
|
|
236
|
+
ref: popperPanelRef,
|
|
237
|
+
class: "filter-pannel",
|
|
238
|
+
onClick: _cache[1] || (_cache[1] = withModifiers(() => {
|
|
239
|
+
}, ["stop"]))
|
|
240
|
+
}, null, 512), [
|
|
241
|
+
[vShow, unref(visible)]
|
|
242
|
+
])
|
|
243
|
+
]),
|
|
169
244
|
createCommentVNode(" \u5173\u952E\u8BCD "),
|
|
170
|
-
createElementVNode("div",
|
|
245
|
+
createElementVNode("div", _hoisted_5, [
|
|
171
246
|
createVNode(unref(Input), {
|
|
172
247
|
modelValue: searchInput.value,
|
|
173
|
-
"onUpdate:modelValue": _cache[
|
|
248
|
+
"onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => searchInput.value = $event),
|
|
174
249
|
"allow-clear": "",
|
|
175
250
|
placeholder: "\u8BF7\u8F93\u5165\u5173\u952E\u8BCD"
|
|
176
251
|
}, {
|
|
177
252
|
prepend: withCtx(() => [
|
|
178
253
|
createVNode(unref(Dropdown), {
|
|
179
|
-
onSelect: _cache[
|
|
254
|
+
onSelect: _cache[2] || (_cache[2] = (e) => searchType.value = e)
|
|
180
255
|
}, {
|
|
181
256
|
content: withCtx(() => [
|
|
182
257
|
createVNode(unref(Doption), { value: 0 }, {
|
|
183
|
-
default: withCtx(() => _cache[
|
|
184
|
-
createTextVNode("\u7CBE\u51C6\u641C")
|
|
185
|
-
])),
|
|
258
|
+
default: withCtx(() => [..._cache[12] || (_cache[12] = [
|
|
259
|
+
createTextVNode("\u7CBE\u51C6\u641C", -1)
|
|
260
|
+
])]),
|
|
186
261
|
_: 1
|
|
187
262
|
}),
|
|
188
263
|
createVNode(unref(Doption), { value: 1 }, {
|
|
189
|
-
default: withCtx(() => _cache[
|
|
190
|
-
createTextVNode("\u6A21\u7CCA\u641C")
|
|
191
|
-
])),
|
|
264
|
+
default: withCtx(() => [..._cache[13] || (_cache[13] = [
|
|
265
|
+
createTextVNode("\u6A21\u7CCA\u641C", -1)
|
|
266
|
+
])]),
|
|
192
267
|
_: 1
|
|
193
268
|
})
|
|
194
269
|
]),
|
|
@@ -206,15 +281,39 @@ const _sfc_main = defineComponent({
|
|
|
206
281
|
_: 1
|
|
207
282
|
}, 8, ["modelValue"])
|
|
208
283
|
]),
|
|
284
|
+
createCommentVNode(" \u76EE\u5F55 "),
|
|
285
|
+
createElementVNode("div", _hoisted_6, [
|
|
286
|
+
createVNode(unref(TreeSelect), {
|
|
287
|
+
modelValue: filter.value.directory_id,
|
|
288
|
+
"onUpdate:modelValue": _cache[4] || (_cache[4] = ($event) => filter.value.directory_id = $event),
|
|
289
|
+
data: unref(tree),
|
|
290
|
+
"popup-container": "#resource-filter-pannel",
|
|
291
|
+
placeholder: "\u8BF7\u9009\u62E9\u76EE\u5F55",
|
|
292
|
+
"field-names": {
|
|
293
|
+
title: "alias",
|
|
294
|
+
key: "id"
|
|
295
|
+
},
|
|
296
|
+
"allow-clear": "",
|
|
297
|
+
"allow-search": "",
|
|
298
|
+
"filter-tree-node": (searchValue, nodeData) => {
|
|
299
|
+
console.log(nodeData);
|
|
300
|
+
if (!nodeData.alias)
|
|
301
|
+
return false;
|
|
302
|
+
return nodeData.alias.toLowerCase().indexOf(searchValue.toLowerCase()) > -1;
|
|
303
|
+
}
|
|
304
|
+
}, null, 8, ["modelValue", "data", "filter-tree-node"])
|
|
305
|
+
]),
|
|
209
306
|
createCommentVNode(" \u7D20\u6750\u7C7B\u578B "),
|
|
210
|
-
createElementVNode("div",
|
|
307
|
+
createElementVNode("div", _hoisted_7, [
|
|
211
308
|
createVNode(unref(Select), {
|
|
212
309
|
modelValue: filter.value.catalog,
|
|
213
|
-
"onUpdate:modelValue": _cache[
|
|
214
|
-
disabled: (
|
|
310
|
+
"onUpdate:modelValue": _cache[5] || (_cache[5] = ($event) => filter.value.catalog = $event),
|
|
311
|
+
disabled: (_a2 = unref(filterOptions)) == null ? void 0 : _a2.mediaTypeStrict,
|
|
312
|
+
"popup-container": "#resource-filter-pannel",
|
|
215
313
|
"allow-clear": "",
|
|
216
314
|
placeholder: "\u7C7B\u578B",
|
|
217
|
-
multiple: ""
|
|
315
|
+
multiple: "",
|
|
316
|
+
"max-tag-count": 1
|
|
218
317
|
}, {
|
|
219
318
|
default: withCtx(() => [
|
|
220
319
|
(openBlock(true), createElementBlock(Fragment, null, renderList(unref(resourceCatalog), (item) => {
|
|
@@ -229,19 +328,22 @@ const _sfc_main = defineComponent({
|
|
|
229
328
|
}, 8, ["modelValue", "disabled"])
|
|
230
329
|
]),
|
|
231
330
|
createCommentVNode(" \u65F6\u95F4\u8303\u56F4 "),
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
331
|
+
createElementVNode("div", _hoisted_8, [
|
|
332
|
+
createVNode(unref(RangePicker), {
|
|
333
|
+
modelValue: rangeTime.value,
|
|
334
|
+
"onUpdate:modelValue": _cache[6] || (_cache[6] = ($event) => rangeTime.value = $event),
|
|
335
|
+
"allow-clear": "",
|
|
336
|
+
"popup-container": "#resource-filter-pannel"
|
|
337
|
+
}, null, 8, ["modelValue"])
|
|
338
|
+
]),
|
|
238
339
|
createCommentVNode(" \u7D20\u6750\u4E0A\u4F20\u6765\u6E90 "),
|
|
239
|
-
createElementVNode("div",
|
|
340
|
+
createElementVNode("div", _hoisted_9, [
|
|
240
341
|
createVNode(unref(Select), {
|
|
241
342
|
modelValue: filter.value.source,
|
|
242
|
-
"onUpdate:modelValue": _cache[
|
|
343
|
+
"onUpdate:modelValue": _cache[7] || (_cache[7] = ($event) => filter.value.source = $event),
|
|
243
344
|
"allow-clear": "",
|
|
244
|
-
placeholder: "\u6765\u6E90"
|
|
345
|
+
placeholder: "\u6765\u6E90",
|
|
346
|
+
"popup-container": "#resource-filter-pannel"
|
|
245
347
|
}, {
|
|
246
348
|
default: withCtx(() => [
|
|
247
349
|
(openBlock(true), createElementBlock(Fragment, null, renderList(unref(resourceSource), (item) => {
|
|
@@ -256,14 +358,15 @@ const _sfc_main = defineComponent({
|
|
|
256
358
|
}, 8, ["modelValue"])
|
|
257
359
|
]),
|
|
258
360
|
createCommentVNode(" \u7D20\u6750\u4E0A\u4F20\u4EBA "),
|
|
259
|
-
!
|
|
361
|
+
!__props.disableUploadBy ? (openBlock(), createElementBlock("div", _hoisted_10, [
|
|
260
362
|
createVNode(unref(Select), {
|
|
261
363
|
modelValue: filter.value.upload_by,
|
|
262
|
-
"onUpdate:modelValue": _cache[
|
|
364
|
+
"onUpdate:modelValue": _cache[8] || (_cache[8] = ($event) => filter.value.upload_by = $event),
|
|
263
365
|
"allow-clear": "",
|
|
264
366
|
placeholder: "\u4E0A\u4F20\u4EBA",
|
|
265
367
|
loading: unref(loading),
|
|
266
368
|
"allow-search": "",
|
|
369
|
+
"popup-container": "#resource-filter-pannel",
|
|
267
370
|
onSearch: unref(handleSearch),
|
|
268
371
|
onDropdownReachBottom: unref(loadMore)
|
|
269
372
|
}, {
|
|
@@ -278,40 +381,64 @@ const _sfc_main = defineComponent({
|
|
|
278
381
|
]),
|
|
279
382
|
_: 1
|
|
280
383
|
}, 8, ["modelValue", "loading", "onSearch", "onDropdownReachBottom"])
|
|
281
|
-
])) : createCommentVNode("v-if", true)
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
384
|
+
])) : createCommentVNode("v-if", true)
|
|
385
|
+
], 512),
|
|
386
|
+
createElementVNode("div", _hoisted_11, [
|
|
387
|
+
createCommentVNode(" \u91CD\u7F6E\u6309\u94AE - Wrap in filter-item to be managed by the hook "),
|
|
388
|
+
withDirectives(createElementVNode("div", _hoisted_12, [
|
|
389
|
+
__props.smallScreen ? (openBlock(), createBlock(unref(Button), {
|
|
390
|
+
key: 0,
|
|
391
|
+
type: "text",
|
|
392
|
+
onClick: handleReset
|
|
393
|
+
}, {
|
|
394
|
+
icon: withCtx(() => [
|
|
395
|
+
createVNode(unref(IconRefresh))
|
|
396
|
+
]),
|
|
397
|
+
_: 1
|
|
398
|
+
})) : (openBlock(), createBlock(unref(Button), {
|
|
399
|
+
key: 1,
|
|
400
|
+
type: "text",
|
|
401
|
+
onClick: handleReset
|
|
402
|
+
}, {
|
|
403
|
+
default: withCtx(() => [..._cache[14] || (_cache[14] = [
|
|
404
|
+
createTextVNode(" \u91CD\u7F6E ", -1)
|
|
405
|
+
])]),
|
|
406
|
+
_: 1
|
|
407
|
+
}))
|
|
408
|
+
], 512), [
|
|
409
|
+
[vShow, !isEmpty.value]
|
|
410
|
+
]),
|
|
411
|
+
__props.smallScreen ? (openBlock(), createBlock(unref(Button), {
|
|
412
|
+
key: 0,
|
|
413
|
+
type: "primary",
|
|
414
|
+
onClick: _cache[9] || (_cache[9] = ($event) => emits("upload"))
|
|
286
415
|
}, {
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
])
|
|
416
|
+
icon: withCtx(() => [
|
|
417
|
+
createVNode(unref(IconUpload))
|
|
418
|
+
]),
|
|
290
419
|
_: 1
|
|
291
|
-
})) :
|
|
292
|
-
|
|
293
|
-
createElementVNode("div", _hoisted_8, [
|
|
294
|
-
createVNode(unref(Button), {
|
|
420
|
+
})) : (openBlock(), createBlock(unref(Button), {
|
|
421
|
+
key: 1,
|
|
295
422
|
type: "primary",
|
|
296
|
-
onClick: _cache[
|
|
423
|
+
onClick: _cache[10] || (_cache[10] = ($event) => emits("upload"))
|
|
297
424
|
}, {
|
|
298
425
|
icon: withCtx(() => [
|
|
299
426
|
createVNode(unref(IconUpload))
|
|
300
427
|
]),
|
|
301
428
|
default: withCtx(() => [
|
|
302
|
-
_cache[
|
|
429
|
+
_cache[15] || (_cache[15] = createTextVNode(" \u4E0A\u4F20 ", -1))
|
|
303
430
|
]),
|
|
304
431
|
_: 1
|
|
305
|
-
})
|
|
432
|
+
}))
|
|
306
433
|
])
|
|
307
434
|
]),
|
|
308
|
-
searchInput.value ? (openBlock(), createElementBlock("div",
|
|
435
|
+
searchInput.value ? (openBlock(), createElementBlock("div", _hoisted_13, [
|
|
309
436
|
(openBlock(true), createElementBlock(Fragment, null, renderList(unref(keywordsSelection), (item) => {
|
|
310
437
|
return openBlock(), createElementBlock("div", {
|
|
311
438
|
key: item.value,
|
|
312
439
|
class: normalizeClass(["list-filter-tag", { active: filter.value.sf === item.value }]),
|
|
313
440
|
onClick: ($event) => filter.value.sf = item.value
|
|
314
|
-
}, toDisplayString(item.name), 11,
|
|
441
|
+
}, toDisplayString(item.name), 11, _hoisted_14);
|
|
315
442
|
}), 128))
|
|
316
443
|
])) : createCommentVNode("v-if", true)
|
|
317
444
|
]);
|
|
@@ -1,9 +1,8 @@
|
|
|
1
|
-
import { defineComponent, inject, watch, onMounted, openBlock, createBlock, unref, withCtx, renderSlot, createVNode, isRef, createElementVNode, createElementBlock, Fragment, renderList } from "vue";
|
|
1
|
+
import { defineComponent, inject, watch, ref, onMounted, openBlock, createBlock, unref, withCtx, renderSlot, createVNode, isRef, createElementVNode, createElementBlock, Fragment, renderList } from "vue";
|
|
2
2
|
import { Pagination } from "@arco-design/web-vue";
|
|
3
3
|
import _sfc_main$1 from "../ListWraper.js";
|
|
4
4
|
import useAttachement from "../../../../hooks/useAttachement.js";
|
|
5
5
|
import _sfc_main$2 from "./Filter.js";
|
|
6
|
-
const _hoisted_1 = { class: "list-item-grid" };
|
|
7
6
|
const _sfc_main = defineComponent({
|
|
8
7
|
__name: "index",
|
|
9
8
|
props: {
|
|
@@ -27,6 +26,18 @@ const _sfc_main = defineComponent({
|
|
|
27
26
|
changeKey
|
|
28
27
|
} = useAttachement({ key: props.activeKey, BASE_API });
|
|
29
28
|
watch(() => props.activeKey, changeKey);
|
|
29
|
+
const listWrapper = ref(null);
|
|
30
|
+
const smallScreen = ref(false);
|
|
31
|
+
watch(
|
|
32
|
+
() => {
|
|
33
|
+
var _a;
|
|
34
|
+
return (_a = listWrapper.value) == null ? void 0 : _a.offsetWidth;
|
|
35
|
+
},
|
|
36
|
+
(val) => {
|
|
37
|
+
smallScreen.value = !!(val && val < 600);
|
|
38
|
+
},
|
|
39
|
+
{ immediate: true }
|
|
40
|
+
);
|
|
30
41
|
onMounted(() => {
|
|
31
42
|
loadData();
|
|
32
43
|
});
|
|
@@ -40,9 +51,10 @@ const _sfc_main = defineComponent({
|
|
|
40
51
|
]),
|
|
41
52
|
header: withCtx(() => [
|
|
42
53
|
createVNode(_sfc_main$2, {
|
|
54
|
+
smallScreen: smallScreen.value,
|
|
43
55
|
onChange: unref(changeFilter),
|
|
44
56
|
onUpload: _cache[0] || (_cache[0] = ($event) => emits("change-tab", "local"))
|
|
45
|
-
}, null, 8, ["onChange"])
|
|
57
|
+
}, null, 8, ["smallScreen", "onChange"])
|
|
46
58
|
]),
|
|
47
59
|
footer: withCtx(() => [
|
|
48
60
|
createVNode(unref(Pagination), {
|
|
@@ -51,22 +63,26 @@ const _sfc_main = defineComponent({
|
|
|
51
63
|
total: unref(total),
|
|
52
64
|
"page-size": unref(limit),
|
|
53
65
|
"show-total": "",
|
|
54
|
-
"show-page-size":
|
|
66
|
+
"show-page-size": !smallScreen.value,
|
|
55
67
|
"base-size": 3,
|
|
56
68
|
"buffer-size": 1,
|
|
57
69
|
onChange: _cache[2] || (_cache[2] = (e) => unref(changePage)((e - 1) * unref(limit))),
|
|
58
70
|
onPageSizeChange: unref(changeSize)
|
|
59
|
-
}, null, 8, ["current", "total", "page-size", "onPageSizeChange"])
|
|
71
|
+
}, null, 8, ["current", "total", "page-size", "show-page-size", "onPageSizeChange"])
|
|
60
72
|
]),
|
|
61
73
|
default: withCtx(() => [
|
|
62
|
-
createElementVNode("div",
|
|
74
|
+
createElementVNode("div", {
|
|
75
|
+
ref_key: "listWrapper",
|
|
76
|
+
ref: listWrapper,
|
|
77
|
+
class: "list-item-grid"
|
|
78
|
+
}, [
|
|
63
79
|
(openBlock(true), createElementBlock(Fragment, null, renderList(unref(list), (item) => {
|
|
64
80
|
return renderSlot(_ctx.$slots, "item", {
|
|
65
81
|
key: item.id,
|
|
66
82
|
item
|
|
67
83
|
});
|
|
68
84
|
}), 128))
|
|
69
|
-
])
|
|
85
|
+
], 512)
|
|
70
86
|
]),
|
|
71
87
|
_: 3
|
|
72
88
|
}, 8, ["loading", "is-empty"]);
|
|
@@ -127,9 +127,9 @@ const _sfc_main = defineComponent({
|
|
|
127
127
|
type: "text",
|
|
128
128
|
onClick: handleReset
|
|
129
129
|
}, {
|
|
130
|
-
default: withCtx(() => _cache[3] || (_cache[3] = [
|
|
131
|
-
createTextVNode(" \u91CD\u7F6E ")
|
|
132
|
-
])),
|
|
130
|
+
default: withCtx(() => [..._cache[3] || (_cache[3] = [
|
|
131
|
+
createTextVNode(" \u91CD\u7F6E ", -1)
|
|
132
|
+
])]),
|
|
133
133
|
_: 1
|
|
134
134
|
})) : createCommentVNode("v-if", true)
|
|
135
135
|
])
|
|
@@ -54,10 +54,10 @@ const _sfc_main = defineComponent({
|
|
|
54
54
|
key: 0,
|
|
55
55
|
class: "item-load-more",
|
|
56
56
|
onClick: loadMore
|
|
57
|
-
}, _cache[0] || (_cache[0] = [
|
|
57
|
+
}, [..._cache[0] || (_cache[0] = [
|
|
58
58
|
createElementVNode("img", { src: _imports_0 }, null, -1),
|
|
59
|
-
createTextVNode(" \u70B9\u51FB\u52A0\u8F7D\u66F4\u591A ")
|
|
60
|
-
]))) : createCommentVNode("v-if", true)
|
|
59
|
+
createTextVNode(" \u70B9\u51FB\u52A0\u8F7D\u66F4\u591A ", -1)
|
|
60
|
+
])])) : createCommentVNode("v-if", true)
|
|
61
61
|
])
|
|
62
62
|
], 2112);
|
|
63
63
|
};
|
|
@@ -91,8 +91,8 @@ const _sfc_main = defineComponent({
|
|
|
91
91
|
item: withCtx(({ item }) => [
|
|
92
92
|
renderSlot(_ctx.$slots, "item", { item })
|
|
93
93
|
]),
|
|
94
|
-
_:
|
|
95
|
-
},
|
|
94
|
+
_: 3
|
|
95
|
+
}, 8, ["outside-filter", "sceniro"])
|
|
96
96
|
], 512)), [
|
|
97
97
|
[vShow, [sceniro.classify_id, ""].includes(choseScen.value)]
|
|
98
98
|
]) : createCommentVNode("v-if", true)
|
|
@@ -33,12 +33,12 @@ const _sfc_main = defineComponent({
|
|
|
33
33
|
renderSlot(_ctx.$slots, "header")
|
|
34
34
|
])) : createCommentVNode("v-if", true),
|
|
35
35
|
createElementVNode("div", _hoisted_3, [
|
|
36
|
-
|
|
36
|
+
__props.loading ? (openBlock(), createElementBlock("div", _hoisted_4, [
|
|
37
37
|
createVNode(unref(Spin), {
|
|
38
38
|
tip: "\u7D20\u6750\u52A0\u8F7D\u4E2D",
|
|
39
39
|
loading: true
|
|
40
40
|
})
|
|
41
|
-
])) :
|
|
41
|
+
])) : __props.isEmpty ? (openBlock(), createElementBlock("div", _hoisted_5, [
|
|
42
42
|
createVNode(_sfc_main$1, { type: "empty" })
|
|
43
43
|
])) : (openBlock(), createElementBlock(Fragment, { key: 2 }, [
|
|
44
44
|
createCommentVNode(" \u5185\u5BB9\u6837\u5F0F\u4E00\uFF1A\u6805\u683C\u6837\u5F0F\uFF0C\u5916\u90E8 props \u4F20 list "),
|