@opentiny/tiny-engine-toolbar-collaboration 2.5.0-alpha.0 → 2.5.0-alpha.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 CHANGED
@@ -1,28 +1,17 @@
1
1
  import "./style.css";
2
- import { useLayout as _, callEntry as S } from "@opentiny/tiny-engine-meta-register";
3
- import { resolveComponent as p, createBlock as b, openBlock as n, withCtx as i, createElementVNode as s, createVNode as g, createElementBlock as l, Fragment as f, renderList as v, toDisplayString as u, createCommentVNode as y, reactive as w, watchEffect as B } from "vue";
4
- import { Popover as E } from "@opentiny/vue";
5
- import { ToolbarBase as h } from "@opentiny/tiny-engine-common";
6
- const V = {
7
- id: "engine.toolbars.collaboration",
8
- type: "toolbars",
9
- title: "collaboration",
10
- options: {
11
- icon: {
12
- default: "team-collaboration"
13
- },
14
- renderType: "slot",
15
- collapsed: !0
16
- }
17
- }, C = (r, o) => {
18
- const t = r.__vccOpts || r;
2
+ import { resolveComponent as p, createBlock as m, openBlock as n, withCtx as i, createElementVNode as t, createVNode as b, createElementBlock as l, Fragment as g, renderList as f, toDisplayString as u, createCommentVNode as v, reactive as N, watchEffect as L } from "vue";
3
+ import { Popover as x } from "@opentiny/vue";
4
+ import { useLayout as S } from "@opentiny/tiny-engine-meta-register";
5
+ import { ToolbarBase as w } from "@opentiny/tiny-engine-common";
6
+ const B = (r, o) => {
7
+ const s = r.__vccOpts || r;
19
8
  for (const [e, d] of o)
20
- t[e] = d;
21
- return t;
22
- }, D = {
9
+ s[e] = d;
10
+ return s;
11
+ }, C = {
23
12
  components: {
24
- TinyPopover: E,
25
- ToolbarBase: h
13
+ TinyPopover: x,
14
+ ToolbarBase: w
26
15
  },
27
16
  props: {
28
17
  options: {
@@ -31,49 +20,38 @@ const V = {
31
20
  }
32
21
  },
33
22
  setup() {
34
- const {
35
- layoutState: r
36
- } = _(), o = w({
23
+ const { layoutState: r } = S(), o = N({
37
24
  outsideVisible: !1,
38
25
  insideVisible: !1,
39
26
  url: "",
40
27
  userLists: []
41
28
  });
42
- B(() => {
29
+ return L(() => {
43
30
  var e;
44
- o.url = "img/defaultAvator.png", o.userLists = [{
45
- pageName: "当前页",
46
- users: [{
47
- userHead: "img/defaultAvator.png",
48
- userName: (e = r.pageStatus.data) == null ? void 0 : e.username,
49
- status: "编辑"
50
- }]
51
- }];
52
- });
53
- const t = S(() => !0, {
54
- metaData: {
55
- id: `${V.id}.isSingle`
56
- },
57
- ctx: () => ({
58
- layoutState: r,
59
- state: o,
60
- isSingle: t,
61
- useLayout: _,
62
- ToolbarBase: h
63
- })
64
- });
65
- return {
31
+ o.url = "img/defaultAvator.png", o.userLists = [
32
+ {
33
+ pageName: "当前页",
34
+ users: [
35
+ {
36
+ userHead: "img/defaultAvator.png",
37
+ userName: (e = r.pageStatus.data) == null ? void 0 : e.username,
38
+ status: "编辑"
39
+ }
40
+ ]
41
+ }
42
+ ];
43
+ }), {
66
44
  state: o,
67
- isSingle: t
45
+ isSingle: () => !0
68
46
  };
69
47
  }
70
- }, T = { class: "collaboration-container" }, A = { class: "collaborators-list" }, H = { class: "page-name" }, O = ["src"], P = { class: "user-item-name" }, j = { class: "user-item-status" }, F = { class: "icon collaboration-wrap" }, U = { class: "icon-hides" }, q = { key: 0 };
71
- function z(r, o, t, e, d, J) {
72
- const k = p("svg-icon"), m = p("tiny-popover"), N = p("toolbar-base");
73
- return n(), b(N, { options: t.options }, {
48
+ }, E = { class: "collaboration-container" }, T = { class: "collaborators-list" }, A = { class: "page-name" }, D = ["src"], H = { class: "user-item-name" }, O = { class: "user-item-status" }, P = { class: "icon collaboration-wrap" }, j = { class: "icon-hides" }, F = { key: 0 };
49
+ function U(r, o, s, e, d, G) {
50
+ const h = p("svg-icon"), _ = p("tiny-popover"), y = p("toolbar-base");
51
+ return n(), m(y, { options: s.options }, {
74
52
  default: i(() => [
75
- s("span", T, [
76
- g(m, {
53
+ t("span", E, [
54
+ b(_, {
77
55
  modelValue: e.state.outsideVisible,
78
56
  "onUpdate:modelValue": o[0] || (o[0] = (a) => e.state.outsideVisible = a),
79
57
  trigger: "click",
@@ -82,7 +60,7 @@ function z(r, o, t, e, d, J) {
82
60
  "popper-class": "toolbar-right-popover collaborator"
83
61
  }, {
84
62
  reference: i(() => [
85
- g(m, {
63
+ b(_, {
86
64
  class: "toolbar-right-user",
87
65
  trigger: "hover",
88
66
  "open-delay": 1e3,
@@ -93,14 +71,14 @@ function z(r, o, t, e, d, J) {
93
71
  reference: i(() => {
94
72
  var a;
95
73
  return [
96
- s("span", F, [
97
- s("span", U, [
98
- e.state.url ? (n(), b(k, {
74
+ t("span", P, [
75
+ t("span", j, [
76
+ e.state.url ? (n(), m(h, {
99
77
  key: 0,
100
- name: t.options.icon.default || t.options.icon
101
- }, null, 8, ["name"])) : y("", !0)
78
+ name: s.options.icon.default || s.options.icon
79
+ }, null, 8, ["name"])) : v("", !0)
102
80
  ]),
103
- (a = t.options) != null && a.collapsed ? (n(), l("span", q, "多人协作")) : y("", !0)
81
+ (a = s.options) != null && a.collapsed ? (n(), l("span", F, "多人协作")) : v("", !0)
104
82
  ])
105
83
  ];
106
84
  }),
@@ -108,24 +86,24 @@ function z(r, o, t, e, d, J) {
108
86
  }, 8, ["content"])
109
87
  ]),
110
88
  default: i(() => [
111
- s("div", A, [
112
- (n(!0), l(f, null, v(e.state.userLists, (a, x) => (n(), l("div", {
113
- key: x,
89
+ t("div", T, [
90
+ (n(!0), l(g, null, f(e.state.userLists, (a, V) => (n(), l("div", {
91
+ key: V,
114
92
  class: "collaborators-list-group"
115
93
  }, [
116
- s("span", H, u(a.pageName), 1),
117
- s("ul", null, [
118
- (n(!0), l(f, null, v(a.users, (c, L) => (n(), l("li", {
119
- key: L,
94
+ t("span", A, u(a.pageName), 1),
95
+ t("ul", null, [
96
+ (n(!0), l(g, null, f(a.users, (c, k) => (n(), l("li", {
97
+ key: k,
120
98
  class: "user-item"
121
99
  }, [
122
- s("img", {
100
+ t("img", {
123
101
  class: "user-item-head",
124
102
  src: c.userHead,
125
103
  alt: ""
126
- }, null, 8, O),
127
- s("span", P, u(c.userName), 1),
128
- s("span", j, "正在" + u(c.status), 1)
104
+ }, null, 8, D),
105
+ t("span", H, u(c.userName), 1),
106
+ t("span", O, "正在" + u(c.status), 1)
129
107
  ]))), 128))
130
108
  ])
131
109
  ]))), 128))
@@ -138,10 +116,21 @@ function z(r, o, t, e, d, J) {
138
116
  _: 1
139
117
  }, 8, ["options"]);
140
118
  }
141
- const G = /* @__PURE__ */ C(D, [["render", z], ["__scopeId", "data-v-04f54116"]]), X = {
142
- ...V,
143
- entry: G
119
+ const q = /* @__PURE__ */ B(C, [["render", U], ["__scopeId", "data-v-c5fb089a"]]), z = {
120
+ id: "engine.toolbars.collaboration",
121
+ type: "toolbars",
122
+ title: "collaboration",
123
+ options: {
124
+ icon: {
125
+ default: "team-collaboration"
126
+ },
127
+ renderType: "slot",
128
+ collapsed: !0
129
+ }
130
+ }, W = {
131
+ ...z,
132
+ entry: q
144
133
  };
145
134
  export {
146
- X as default
135
+ W as default
147
136
  };
package/dist/style.css CHANGED
@@ -1 +1 @@
1
- .collaboration-container[data-v-04f54116] .reference-wrapper{display:flex}.toolbar-right-user[data-v-04f54116] .reference-wrapper{padding:0!important}.collaborators-list .page-name[data-v-04f54116]{display:inline-block;width:100%;font-size:14px;padding:12px 20px;color:var(--te-toolbars-collaboration-text-color-secondary);line-height:18px;font-weight:600}.collaborators-list .user-item[data-v-04f54116]{padding:10px 16px;display:flex;align-items:center}.collaborators-list .user-item[data-v-04f54116]:hover{background:var(--te-toolbars-collaboration-bg-color-hover)}.collaborators-list .user-item .user-item-head[data-v-04f54116]{width:26px;height:26px;border-radius:50%}.collaborators-list .user-item .user-item-name[data-v-04f54116]{font-size:14px;color:var(--te-toolbars-collaboration-text-color-primary);line-height:16px;font-weight:400;margin:0 4px 0 8px}.collaborators-list .user-item .user-item-status[data-v-04f54116]{font-size:14px}.collaboration-wrap[data-v-04f54116]{display:flex;align-items:center;cursor:pointer;font-size:12px}.collaboration-wrap .user-head[data-v-04f54116]{width:16px;height:16px;border-radius:50%;margin-right:8px;z-index:9;border:1px solid var(--te-toolbars-collaboration-border-color)}:root{--te-toolbars-collaboration-text-color-primary: var(--te-common-text-primary);--te-toolbars-collaboration-text-color-secondary: var(--te-common-text-secondary);--te-toolbars-collaboration-bg-color-hover: var(--te-common-bg-container);--te-toolbars-collaboration-border-color: var(--te-common-border-default)}
1
+ .collaboration-container[data-v-c5fb089a] .reference-wrapper{display:flex}.toolbar-right-user[data-v-c5fb089a] .reference-wrapper{padding:0!important}.collaborators-list .page-name[data-v-c5fb089a]{display:inline-block;width:100%;font-size:14px;padding:12px 20px;color:var(--te-toolbars-collaboration-text-color-secondary);line-height:18px;font-weight:600}.collaborators-list .user-item[data-v-c5fb089a]{padding:10px 16px;display:flex;align-items:center}.collaborators-list .user-item[data-v-c5fb089a]:hover{background:var(--te-toolbars-collaboration-bg-color-hover)}.collaborators-list .user-item .user-item-head[data-v-c5fb089a]{width:26px;height:26px;border-radius:50%}.collaborators-list .user-item .user-item-name[data-v-c5fb089a]{font-size:14px;color:var(--te-toolbars-collaboration-text-color-primary);line-height:16px;font-weight:400;margin:0 4px 0 8px}.collaborators-list .user-item .user-item-status[data-v-c5fb089a]{font-size:14px}.collaboration-wrap[data-v-c5fb089a]{display:flex;align-items:center;cursor:pointer;font-size:12px}.collaboration-wrap .user-head[data-v-c5fb089a]{width:16px;height:16px;border-radius:50%;margin-right:8px;z-index:9;border:1px solid var(--te-toolbars-collaboration-border-color)}:root{--te-toolbars-collaboration-text-color-primary: var(--te-common-text-primary);--te-toolbars-collaboration-text-color-secondary: var(--te-common-text-secondary);--te-toolbars-collaboration-bg-color-hover: var(--te-common-bg-container);--te-toolbars-collaboration-border-color: var(--te-common-border-default)}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@opentiny/tiny-engine-toolbar-collaboration",
3
- "version": "2.5.0-alpha.0",
3
+ "version": "2.5.0-alpha.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.5.0-alpha.0",
29
- "@opentiny/tiny-engine-meta-register": "2.5.0-alpha.0"
28
+ "@opentiny/tiny-engine-common": "2.5.0-alpha.2",
29
+ "@opentiny/tiny-engine-meta-register": "2.5.0-alpha.2"
30
30
  },
31
31
  "devDependencies": {
32
- "@opentiny/tiny-engine-vite-plugin-meta-comments": "2.5.0-alpha.0",
32
+ "@opentiny/tiny-engine-vite-plugin-meta-comments": "2.5.0-alpha.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": "ae59c82734d79f650c9221cb9702714814b099c8"
41
+ "gitHead": "f5707c379397bffc9a63c50c695f3ee3340ad0c6"
42
42
  }