@jx3box/jx3box-ui 2.3.25 → 2.3.26

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jx3box/jx3box-ui",
3
- "version": "2.3.25",
3
+ "version": "2.3.26",
4
4
  "description": "JX3BOX Vue3 UI",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -16,8 +16,10 @@
16
16
  <template v-for="item in userPanel" :key="item.label">
17
17
  <li>
18
18
  <a :href="item.link" :target="item.target || '_self'" class="u-menu-item" @click="onClick(item)">
19
- <img :src="resolveImg(item.icon)" class="u-menu-icon" :alt="item.icon" />
20
- {{ getPanelLabel(item) }}
19
+ <span class="u-menu-icon-wrap">
20
+ <img :src="resolveImg(item.icon)" class="u-menu-icon" :alt="item.icon" />
21
+ </span>
22
+ <span class="u-menu-label">{{ getPanelLabel(item) }}</span>
21
23
  <span v-if="showPop && isFeaturePanelItem(item)" class="u-new">New!</span>
22
24
  </a>
23
25
  <a
@@ -26,8 +28,10 @@
26
28
  class="u-menu-item u-menu-item--account-ready"
27
29
  @click.prevent="openAccountReady"
28
30
  >
29
- <img :src="resolveImg(item.icon)" class="u-menu-icon" :alt="item.icon" />
30
- 资料完善
31
+ <span class="u-menu-icon-wrap">
32
+ <img :src="resolveImg(item.icon)" class="u-menu-icon" :alt="item.icon" />
33
+ </span>
34
+ <span class="u-menu-label">资料完善</span>
31
35
  <span class="u-new u-new--important">重要</span>
32
36
  </a>
33
37
  </li>
@@ -36,8 +40,10 @@
36
40
  <hr v-if="adminPanel.length" />
37
41
  <li v-for="item in adminPanel" :key="item.label">
38
42
  <a :href="item.link" :target="item.target || '_self'" class="u-menu-item">
39
- <img :src="resolveImg(item.icon)" class="u-menu-icon" :alt="item.icon" />
40
- {{ getPanelLabel(item) }}
43
+ <span class="u-menu-icon-wrap">
44
+ <img :src="resolveImg(item.icon)" class="u-menu-icon" :alt="item.icon" />
45
+ </span>
46
+ <span class="u-menu-label">{{ getPanelLabel(item) }}</span>
41
47
  </a>
42
48
  </li>
43
49
  </template>
@@ -215,29 +221,95 @@ export default {
215
221
  align-items: center;
216
222
  }
217
223
  .u-menu {
224
+ width: 272px;
225
+ box-sizing: border-box;
226
+ right: -10px;
227
+ top: calc(100% + 8px);
228
+ margin: 0;
229
+ padding: 8px;
230
+ border: 1px solid rgba(31, 35, 41, 0.1);
231
+ border-radius: 12px;
232
+ background: rgba(255, 255, 255, 0.98);
233
+ box-shadow: 0 12px 36px rgba(15, 23, 42, 0.16), 0 2px 8px rgba(15, 23, 42, 0.08);
234
+ backdrop-filter: blur(12px);
235
+ -webkit-backdrop-filter: blur(12px);
236
+
237
+ &:before {
238
+ right: 16px;
239
+ top: -14px;
240
+ border-width: 7px;
241
+ border-bottom-color: rgba(31, 35, 41, 0.1);
242
+ }
243
+
244
+ &:after {
245
+ right: 17px;
246
+ top: -12px;
247
+ border-width: 6px;
248
+ border-bottom-color: #fff;
249
+ }
250
+
251
+ li {
252
+ margin: 0;
253
+ }
254
+
218
255
  .u-menu-item {
219
256
  .flex;
220
257
  align-items: center;
221
- gap: 4px;
258
+ gap: 10px;
259
+ min-height: 44px;
260
+ box-sizing: border-box;
261
+ padding: 8px 10px;
262
+ border-radius: 8px;
263
+ color: #303133;
264
+ font-size: 14px;
265
+ line-height: 20px;
266
+ text-decoration: none;
267
+ transition: background-color 0.16s ease, color 0.16s ease;
222
268
 
223
269
  &:hover {
224
- .u-menu-icon {
225
- filter: invert(100%) sepia(0%) saturate(5658%) hue-rotate(215deg) brightness(114%) contrast(106%);
270
+ color: #4338ca;
271
+ background: #f4f3ff;
272
+
273
+ .u-menu-icon-wrap {
274
+ background: #e8e7ff;
226
275
  }
227
- .u-new {
228
- color: #fff;
276
+
277
+ .u-menu-icon {
278
+ opacity: 0.9;
229
279
  }
230
280
  }
231
281
  }
282
+
283
+ .u-menu-icon-wrap {
284
+ .flex;
285
+ align-items: center;
286
+ justify-content: center;
287
+ width: 30px;
288
+ height: 30px;
289
+ flex: 0 0 30px;
290
+ border-radius: 8px;
291
+ background: #f3f4f6;
292
+ transition: background-color 0.16s ease;
293
+ }
294
+
232
295
  .u-menu-icon {
233
- width: 16px;
234
- height: 16px;
296
+ width: 18px;
297
+ height: 18px;
298
+ opacity: 0.72;
299
+ }
300
+
301
+ .u-menu-label {
302
+ flex: 1;
303
+ min-width: 0;
304
+ font-weight: 500;
305
+ letter-spacing: 0.01em;
235
306
  }
236
307
  }
237
308
 
238
309
  hr {
239
310
  border: 0;
240
- border-top: 1px solid #eee;
311
+ border-top: 1px solid #eef0f3;
312
+ margin: 6px 4px;
241
313
  }
242
314
 
243
315
  .u-icon-msg {
@@ -260,19 +332,38 @@ export default {
260
332
  }
261
333
 
262
334
  .u-new {
263
- font-size: 12px;
335
+ flex: 0 0 auto;
336
+ box-sizing: border-box;
337
+ min-width: 38px;
264
338
  margin-left: 4px;
265
- background-color: @v4primary-dark;
266
- color: #fff;
267
- padding: 0px 6px;
339
+ padding: 2px 7px;
340
+ border: 1px solid #d9d6fe;
341
+ border-radius: 999px;
342
+ background: #eeedff;
343
+ color: #4f46e5;
344
+ font-size: 11px;
345
+ font-weight: 700;
346
+ line-height: 16px;
347
+ text-align: center;
268
348
  }
269
349
 
270
350
  .u-new--important {
271
- background-color: #f56c6c;
351
+ border-color: #ffd1d1;
352
+ background: #fff0f0;
353
+ color: #e5484d;
272
354
  }
273
355
 
274
356
  .u-menu-item--account-ready {
275
- color: #f56c6c;
357
+ color: #303133;
358
+
359
+ &:hover {
360
+ color: #d9363e;
361
+ background: #fff5f5;
362
+
363
+ .u-menu-icon-wrap {
364
+ background: #ffe8e8;
365
+ }
366
+ }
276
367
  }
277
368
  }
278
369
  </style>
@@ -0,0 +1,16 @@
1
+ import ManagePanelStage from "./ManagePanelStage.vue";
2
+
3
+ export default {
4
+ title: "Layout/CommonHeader/ManagePanel",
5
+ component: ManagePanelStage,
6
+ parameters: {
7
+ layout: "fullscreen",
8
+ },
9
+ };
10
+
11
+ export const Refined = {
12
+ render: () => ({
13
+ components: { ManagePanelStage },
14
+ template: "<ManagePanelStage />",
15
+ }),
16
+ };
@@ -0,0 +1,135 @@
1
+ <template>
2
+ <div class="manage-preview">
3
+ <div class="manage-preview__header">
4
+ <div class="manage-preview__brand">JX3BOX</div>
5
+ <div class="manage-preview__tools">
6
+ <span class="manage-preview__tool">◯</span>
7
+ <span class="manage-preview__tool">◇</span>
8
+ <span class="manage-preview__tool">♢</span>
9
+ <Manage
10
+ ref="manage"
11
+ :header-config-loaded="false"
12
+ :account-ready-incomplete="true"
13
+ :account-ready-issues="['contact']"
14
+ />
15
+ <span class="manage-preview__tool">文</span>
16
+ <span class="manage-preview__avatar">侠</span>
17
+ </div>
18
+ </div>
19
+ <main class="manage-preview__body">
20
+ <div class="manage-preview__eyebrow">COMMON HEADER</div>
21
+ <h1>公共头扩展菜单</h1>
22
+ <p>重新梳理信息密度、状态层级与悬浮反馈后的实际组件预览。</p>
23
+ </main>
24
+ </div>
25
+ </template>
26
+
27
+ <script>
28
+ import Manage from "../../header/manage.vue";
29
+
30
+ export default {
31
+ name: "ManagePanelStage",
32
+ components: { Manage },
33
+ mounted() {
34
+ this.$refs.manage.panel = [
35
+ {
36
+ key: "featureUpdate",
37
+ label: "功能更新",
38
+ link: "javascript:;",
39
+ icon: "feature.svg",
40
+ remark: "feature",
41
+ meta: "storybook-preview",
42
+ },
43
+ ];
44
+ this.$refs.manage.showPop = true;
45
+ },
46
+ };
47
+ </script>
48
+
49
+ <style lang="less">
50
+ .manage-preview {
51
+ min-height: 100vh;
52
+ background:
53
+ radial-gradient(circle at 72% 8%, rgba(79, 70, 229, 0.09), transparent 26rem),
54
+ #f5f7fa;
55
+ }
56
+
57
+ .manage-preview__header {
58
+ height: 64px;
59
+ display: flex;
60
+ align-items: center;
61
+ justify-content: space-between;
62
+ box-sizing: border-box;
63
+ padding: 0 32px;
64
+ color: #fff;
65
+ background: #202124;
66
+ box-shadow: 0 4px 18px rgba(15, 23, 42, 0.2);
67
+ }
68
+
69
+ .manage-preview__brand {
70
+ font-size: 14px;
71
+ font-weight: 800;
72
+ letter-spacing: 0.12em;
73
+ }
74
+
75
+ .manage-preview__tools {
76
+ height: 100%;
77
+ display: flex;
78
+ align-items: center;
79
+ gap: 8px;
80
+ }
81
+
82
+ .manage-preview__tool {
83
+ width: 38px;
84
+ height: 38px;
85
+ display: flex;
86
+ align-items: center;
87
+ justify-content: center;
88
+ color: rgba(255, 255, 255, 0.88);
89
+ font-size: 19px;
90
+ }
91
+
92
+ .manage-preview__avatar {
93
+ width: 34px;
94
+ height: 34px;
95
+ display: flex;
96
+ align-items: center;
97
+ justify-content: center;
98
+ margin-left: 4px;
99
+ border: 2px solid rgba(255, 255, 255, 0.75);
100
+ border-radius: 50%;
101
+ color: #7c2d12;
102
+ background: #fef3c7;
103
+ font-size: 13px;
104
+ font-weight: 700;
105
+ }
106
+
107
+ .manage-preview .c-header-manage .u-pop-content {
108
+ visibility: visible;
109
+ opacity: 1;
110
+ }
111
+
112
+ .manage-preview__body {
113
+ padding: 112px 9vw;
114
+ }
115
+
116
+ .manage-preview__eyebrow {
117
+ color: #4f46e5;
118
+ font-size: 12px;
119
+ font-weight: 800;
120
+ letter-spacing: 0.14em;
121
+ }
122
+
123
+ .manage-preview__body h1 {
124
+ margin: 12px 0 0;
125
+ color: #111827;
126
+ font-size: 34px;
127
+ line-height: 1.2;
128
+ }
129
+
130
+ .manage-preview__body p {
131
+ margin: 14px 0 0;
132
+ color: #6b7280;
133
+ font-size: 15px;
134
+ }
135
+ </style>