@opentiny/tiny-engine-toolbar-collaboration 2.6.1 → 2.6.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/dist/index.js.map +1 -1
- package/package.json +5 -5
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../src/Main.vue","../meta.js","../index.ts"],"sourcesContent":["<template>\n <toolbar-base :options=\"options\">\n <template #default>\n <span class=\"collaboration-container\">\n <tiny-popover\n v-model=\"state.outsideVisible\"\n trigger=\"click\"\n width=\"260\"\n append-to-body\n popper-class=\"toolbar-right-popover collaborator\"\n >\n <div class=\"collaborators-list\">\n <div v-for=\"(list, index) in state.userLists\" :key=\"index\" class=\"collaborators-list-group\">\n <span class=\"page-name\">{{ list.pageName }}</span>\n <ul>\n <li v-for=\"(userItem, index) in list.users\" :key=\"index\" class=\"user-item\">\n <img class=\"user-item-head\" :src=\"userItem.userHead\" alt=\"\" />\n <span class=\"user-item-name\">{{ userItem.userName }}</span>\n <span class=\"user-item-status\">正在{{ userItem.status }}</span>\n </li>\n </ul>\n </div>\n </div>\n <template #reference>\n <tiny-popover\n class=\"toolbar-right-user\"\n trigger=\"hover\"\n :open-delay=\"1000\"\n popper-class=\"collaboration-popover toolbar-right-popover\"\n append-to-body\n :content=\"`该项目共有 ${state.userLists.length} 位用户在编辑`\"\n >\n <template #reference>\n <span class=\"icon collaboration-wrap\">\n <span class=\"icon-hides\">\n <svg-icon v-if=\"state.url\" :name=\"options.icon.default || options.icon\"></svg-icon>\n </span>\n <span v-if=\"options?.collapsed\">多人协作</span>\n </span>\n </template>\n </tiny-popover>\n </template>\n </tiny-popover>\n </span>\n </template>\n </toolbar-base>\n</template>\n\n<script>\nimport { reactive, watchEffect } from 'vue'\nimport { Popover } from '@opentiny/vue'\nimport { useLayout } from '@opentiny/tiny-engine-meta-register'\nimport { ToolbarBase } from '@opentiny/tiny-engine-common'\n\nexport default {\n components: {\n TinyPopover: Popover,\n ToolbarBase\n },\n props: {\n options: {\n type: Object,\n default: () => ({})\n }\n },\n setup() {\n const { layoutState } = useLayout()\n\n const state = reactive({\n outsideVisible: false,\n insideVisible: false,\n url: '',\n userLists: []\n })\n\n watchEffect(() => {\n state.url = 'img/defaultAvator.png'\n state.userLists = [\n {\n pageName: '当前页',\n users: [\n {\n userHead: 'img/defaultAvator.png',\n userName: layoutState.pageStatus.data?.username,\n status: '编辑'\n }\n ]\n }\n ]\n })\n\n const isSingle = () => {\n return true\n }\n\n return {\n state,\n isSingle\n }\n }\n}\n</script>\n\n<style lang=\"less\" scoped>\n.collaboration-container {\n :deep(.reference-wrapper) {\n display: flex;\n }\n}\n\n.toolbar-right-user {\n :deep(.reference-wrapper) {\n padding: 0 !important;\n }\n}\n\n.collaborators-list {\n .page-name {\n display: inline-block;\n width: 100%;\n font-size: 14px;\n padding: 12px 20px;\n color: var(--te-toolbars-collaboration-text-color-secondary);\n line-height: 18px;\n font-weight: 600;\n }\n\n .user-item {\n padding: 10px 16px;\n display: flex;\n align-items: center;\n\n &:hover {\n background: var(--te-toolbars-collaboration-bg-color-hover);\n }\n\n .user-item-head {\n width: 26px;\n height: 26px;\n border-radius: 50%;\n }\n\n .user-item-name {\n font-size: 14px;\n color: var(--te-toolbars-collaboration-text-color-primary);\n line-height: 16px;\n font-weight: 400;\n margin: 0 4px 0 8px;\n }\n\n .user-item-status {\n font-size: 14px;\n }\n }\n}\n\n.collaboration-wrap {\n display: flex;\n align-items: center;\n cursor: pointer;\n font-size: 12px;\n\n .user-head {\n width: 16px;\n height: 16px;\n border-radius: 50%;\n margin-right: 8px;\n z-index: 9;\n border: 1px solid var(--te-toolbars-collaboration-border-color);\n }\n}\n</style>\n","export default {\n id: 'engine.toolbars.collaboration',\n type: 'toolbars',\n title: 'collaboration',\n options: {\n icon: {\n default: 'team-collaboration'\n },\n renderType: 'slot',\n collapsed: true\n }\n}\n","/**\n * Copyright (c) 2023 - present TinyEngine Authors.\n * Copyright (c) 2023 - present Huawei Cloud Computing Technologies Co., Ltd.\n *\n * Use of this source code is governed by an MIT-style license.\n *\n * THE OPEN SOURCE SOFTWARE IN THIS PRODUCT IS DISTRIBUTED IN THE HOPE THAT IT WILL BE USEFUL,\n * BUT WITHOUT ANY WARRANTY, WITHOUT EVEN THE IMPLIED WARRANTY OF MERCHANTABILITY OR FITNESS FOR\n * A PARTICULAR PURPOSE. SEE THE APPLICABLE LICENSES FOR MORE DETAILS.\n *\n */\n\nimport entry from './src/Main.vue'\nimport metaData from './meta'\nimport './src/styles/vars.less'\n\nexport default {\n ...metaData,\n entry\n}\n"],"names":["_sfc_main","Popover","ToolbarBase","layoutState","useLayout","state","reactive","watchEffect","_a","_hoisted_1","_hoisted_2","_hoisted_3","_hoisted_5","_hoisted_6","_hoisted_7","_hoisted_8","_createBlock","_component_toolbar_base","$props","_createElementVNode","_createVNode","_component_tiny_popover","$setup","_cache","$event","_component_svg_icon","_openBlock","_createElementBlock","_Fragment","list","index","_toDisplayString","userItem","metaData","entry"],"mappings":";;;;;;;;;;GAsDKA,IAAU;AAAA,EACb,YAAY;AAAA,IACV,aAAaC;AAAA,IACb,aAAAC;AAAA;EAEF,OAAO;AAAA,IACL,SAAS;AAAA,MACP,MAAM;AAAA,MACN,SAAS,OAAO,CAAA;AAAA,IAClB;AAAA;EAEF,QAAQ;AACN,UAAM,EAAE,aAAAC,EAAU,IAAMC,EAAS,GAE3BC,IAAQC,EAAS;AAAA,MACrB,gBAAgB;AAAA,MAChB,eAAe;AAAA,MACf,KAAK;AAAA,MACL,WAAW,CAAA;AAAA,KACZ;AAED,WAAAC,EAAY,MAAM;;AAChB,MAAAF,EAAM,MAAM,yBACZA,EAAM,YAAY;AAAA,QAChB;AAAA,UACE,UAAU;AAAA,UACV,OAAO;AAAA,YACL;AAAA,cACE,UAAU;AAAA,cACV,WAAUG,IAAAL,EAAY,WAAW,SAAvB,gBAAAK,EAA6B;AAAA,cACvC,QAAQ;AAAA,YACV;AAAA,UACF;AAAA,QACF;AAAA,MACF;AAAA,
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../src/Main.vue","../meta.js","../index.ts"],"sourcesContent":["<template>\n <toolbar-base :options=\"options\">\n <template #default>\n <span class=\"collaboration-container\">\n <tiny-popover\n v-model=\"state.outsideVisible\"\n trigger=\"click\"\n width=\"260\"\n append-to-body\n popper-class=\"toolbar-right-popover collaborator\"\n >\n <div class=\"collaborators-list\">\n <div v-for=\"(list, index) in state.userLists\" :key=\"index\" class=\"collaborators-list-group\">\n <span class=\"page-name\">{{ list.pageName }}</span>\n <ul>\n <li v-for=\"(userItem, index) in list.users\" :key=\"index\" class=\"user-item\">\n <img class=\"user-item-head\" :src=\"userItem.userHead\" alt=\"\" />\n <span class=\"user-item-name\">{{ userItem.userName }}</span>\n <span class=\"user-item-status\">正在{{ userItem.status }}</span>\n </li>\n </ul>\n </div>\n </div>\n <template #reference>\n <tiny-popover\n class=\"toolbar-right-user\"\n trigger=\"hover\"\n :open-delay=\"1000\"\n popper-class=\"collaboration-popover toolbar-right-popover\"\n append-to-body\n :content=\"`该项目共有 ${state.userLists.length} 位用户在编辑`\"\n >\n <template #reference>\n <span class=\"icon collaboration-wrap\">\n <span class=\"icon-hides\">\n <svg-icon v-if=\"state.url\" :name=\"options.icon.default || options.icon\"></svg-icon>\n </span>\n <span v-if=\"options?.collapsed\">多人协作</span>\n </span>\n </template>\n </tiny-popover>\n </template>\n </tiny-popover>\n </span>\n </template>\n </toolbar-base>\n</template>\n\n<script>\nimport { reactive, watchEffect } from 'vue'\nimport { Popover } from '@opentiny/vue'\nimport { useLayout } from '@opentiny/tiny-engine-meta-register'\nimport { ToolbarBase } from '@opentiny/tiny-engine-common'\n\nexport default {\n components: {\n TinyPopover: Popover,\n ToolbarBase\n },\n props: {\n options: {\n type: Object,\n default: () => ({})\n }\n },\n setup() {\n const { layoutState } = useLayout()\n\n const state = reactive({\n outsideVisible: false,\n insideVisible: false,\n url: '',\n userLists: []\n })\n\n watchEffect(() => {\n state.url = 'img/defaultAvator.png'\n state.userLists = [\n {\n pageName: '当前页',\n users: [\n {\n userHead: 'img/defaultAvator.png',\n userName: layoutState.pageStatus.data?.username,\n status: '编辑'\n }\n ]\n }\n ]\n })\n\n const isSingle = () => {\n return true\n }\n\n return {\n state,\n isSingle\n }\n }\n}\n</script>\n\n<style lang=\"less\" scoped>\n.collaboration-container {\n :deep(.reference-wrapper) {\n display: flex;\n }\n}\n\n.toolbar-right-user {\n :deep(.reference-wrapper) {\n padding: 0 !important;\n }\n}\n\n.collaborators-list {\n .page-name {\n display: inline-block;\n width: 100%;\n font-size: 14px;\n padding: 12px 20px;\n color: var(--te-toolbars-collaboration-text-color-secondary);\n line-height: 18px;\n font-weight: 600;\n }\n\n .user-item {\n padding: 10px 16px;\n display: flex;\n align-items: center;\n\n &:hover {\n background: var(--te-toolbars-collaboration-bg-color-hover);\n }\n\n .user-item-head {\n width: 26px;\n height: 26px;\n border-radius: 50%;\n }\n\n .user-item-name {\n font-size: 14px;\n color: var(--te-toolbars-collaboration-text-color-primary);\n line-height: 16px;\n font-weight: 400;\n margin: 0 4px 0 8px;\n }\n\n .user-item-status {\n font-size: 14px;\n }\n }\n}\n\n.collaboration-wrap {\n display: flex;\n align-items: center;\n cursor: pointer;\n font-size: 12px;\n\n .user-head {\n width: 16px;\n height: 16px;\n border-radius: 50%;\n margin-right: 8px;\n z-index: 9;\n border: 1px solid var(--te-toolbars-collaboration-border-color);\n }\n}\n</style>\n","export default {\n id: 'engine.toolbars.collaboration',\n type: 'toolbars',\n title: 'collaboration',\n options: {\n icon: {\n default: 'team-collaboration'\n },\n renderType: 'slot',\n collapsed: true\n }\n}\n","/**\n * Copyright (c) 2023 - present TinyEngine Authors.\n * Copyright (c) 2023 - present Huawei Cloud Computing Technologies Co., Ltd.\n *\n * Use of this source code is governed by an MIT-style license.\n *\n * THE OPEN SOURCE SOFTWARE IN THIS PRODUCT IS DISTRIBUTED IN THE HOPE THAT IT WILL BE USEFUL,\n * BUT WITHOUT ANY WARRANTY, WITHOUT EVEN THE IMPLIED WARRANTY OF MERCHANTABILITY OR FITNESS FOR\n * A PARTICULAR PURPOSE. SEE THE APPLICABLE LICENSES FOR MORE DETAILS.\n *\n */\n\nimport entry from './src/Main.vue'\nimport metaData from './meta'\nimport './src/styles/vars.less'\n\nexport default {\n ...metaData,\n entry\n}\n"],"names":["_sfc_main","Popover","ToolbarBase","layoutState","useLayout","state","reactive","watchEffect","_a","_hoisted_1","_hoisted_2","_hoisted_3","_hoisted_5","_hoisted_6","_hoisted_7","_hoisted_8","_createBlock","_component_toolbar_base","$props","_createElementVNode","_createVNode","_component_tiny_popover","$setup","_cache","$event","_component_svg_icon","_openBlock","_createElementBlock","_Fragment","list","index","_toDisplayString","userItem","metaData","entry"],"mappings":";;;;;;;;;;GAsDKA,IAAU;AAAA,EACb,YAAY;AAAA,IACV,aAAaC;AAAA,IACb,aAAAC;AAAA;EAEF,OAAO;AAAA,IACL,SAAS;AAAA,MACP,MAAM;AAAA,MACN,SAAS,OAAO,CAAA;AAAA,IAClB;AAAA;EAEF,QAAQ;AACN,UAAM,EAAE,aAAAC,EAAU,IAAMC,EAAS,GAE3BC,IAAQC,EAAS;AAAA,MACrB,gBAAgB;AAAA,MAChB,eAAe;AAAA,MACf,KAAK;AAAA,MACL,WAAW,CAAA;AAAA,KACZ;AAED,WAAAC,EAAY,MAAM;;AAChB,MAAAF,EAAM,MAAM,yBACZA,EAAM,YAAY;AAAA,QAChB;AAAA,UACE,UAAU;AAAA,UACV,OAAO;AAAA,YACL;AAAA,cACE,UAAU;AAAA,cACV,WAAUG,IAAAL,EAAY,WAAW,SAAvB,gBAAAK,EAA6B;AAAA,cACvC,QAAQ;AAAA,YACV;AAAA,UACF;AAAA,QACF;AAAA,MACF;AAAA,IACF,CAAC,GAMM;AAAA,MACL,OAAAH;AAAA,MACA,UANe,MACR;AAAA,IAMT;AAAA,EACF;AACF,GAjGYI,IAAA,EAAA,OAAM,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A;gBAC/DX,EAAkD,QAAlDR,GAAkDoB,EAAvBF,EAAK,QAAQ,GAAA,CAAA;AAAA,gBACxCV,EAMK,MAAA,MAAA;AAAA,mBALHO,EAAA,EAAA,GAAAC,EAIKC,WAJ2BC,EAAK,OAAK,CAA9BG,GAAUF,YAAtBH,EAIK,MAAA;AAAA,oBAJwC,KAAKG;AAAA,oBAAO,OAAM;AAAA;oBAC7DX,EAA8D,OAAA;AAAA,sBAAzD,OAAM;AAAA,sBAAkB,KAAKa,EAAS;AAAA,sBAAU,KAAI;AAAA;oBACzDb,EAA2D,QAA3DP,GAA2DmB,EAA3BC,EAAS,QAAQ,GAAA,CAAA;AAAA,oBACjDb,EAA6D,QAA7DN,GAA+B,OAAEkB,EAAGC,EAAS,MAAM,GAAA,CAAA;AAAA;;;;;;;;;;;;mFClBrEC,IAAe;AAAA,EACb,IAAI;AAAA,EACJ,MAAM;AAAA,EACN,OAAO;AAAA,EACP,SAAS;AAAA,IACP,MAAM;AAAA,MACJ,SAAS;AAAA,IACf;AAAA,IACI,YAAY;AAAA,IACZ,WAAW;AAAA,EACf;AACA,GCKAH,IAAe;AAAA,EACb,GAAGG;AAAA,EACH,OAAAC;AACF;"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@opentiny/tiny-engine-toolbar-collaboration",
|
|
3
|
-
"version": "2.6.
|
|
3
|
+
"version": "2.6.2",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -25,11 +25,11 @@
|
|
|
25
25
|
"license": "MIT",
|
|
26
26
|
"homepage": "https://opentiny.design/tiny-engine",
|
|
27
27
|
"dependencies": {
|
|
28
|
-
"@opentiny/tiny-engine-common": "2.6.
|
|
29
|
-
"@opentiny/tiny-engine-meta-register": "2.6.
|
|
28
|
+
"@opentiny/tiny-engine-common": "2.6.2",
|
|
29
|
+
"@opentiny/tiny-engine-meta-register": "2.6.2"
|
|
30
30
|
},
|
|
31
31
|
"devDependencies": {
|
|
32
|
-
"@opentiny/tiny-engine-vite-plugin-meta-comments": "2.6.
|
|
32
|
+
"@opentiny/tiny-engine-vite-plugin-meta-comments": "2.6.2",
|
|
33
33
|
"@vitejs/plugin-vue": "^5.1.2",
|
|
34
34
|
"@vitejs/plugin-vue-jsx": "^4.0.1",
|
|
35
35
|
"vite": "^5.4.2"
|
|
@@ -38,5 +38,5 @@
|
|
|
38
38
|
"@opentiny/vue": "^3.20.0",
|
|
39
39
|
"vue": "^3.4.15"
|
|
40
40
|
},
|
|
41
|
-
"gitHead": "
|
|
41
|
+
"gitHead": "f0a78631f157b7888a491ace9a962db777c4a0bd"
|
|
42
42
|
}
|