gbpptx 0.2.0 → 0.4.0
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 +237 -214
- package/package.json +5 -3
- package/src/kernel/model.js +1 -2
- package/src/kernel/parts.js +11 -15
- package/src/kernel/print.js +14 -16
- package/web/app/main.js +8 -8
- package/web/app/slides/arrange.js +101 -0
- package/web/app/slides/clipboard.js +93 -0
- package/web/app/slides/file.js +213 -0
- package/web/app/slides/find.js +201 -0
- package/web/app/slides/history.js +100 -0
- package/web/app/slides/keys.js +179 -0
- package/web/app/slides/menus.js +105 -0
- package/web/app/slides/objects.js +254 -0
- package/web/app/slides/render.js +183 -0
- package/web/app/slides/shared.js +85 -0
- package/web/app/slides/slides.js +103 -0
- package/web/app/slides/table.js +102 -0
- package/web/app/slides/text.js +418 -0
- package/web/app/slides/view.js +156 -0
- package/web/app/slides-app.js +323 -2446
- package/web/app/ui/canvas.js +769 -755
- package/web/app/ui/color-panel.js +58 -76
- package/web/app/ui/dialogs.js +120 -159
- package/web/app/ui/file-io.js +116 -132
- package/web/app/ui/format-pane.js +427 -427
- package/web/app/ui/icons.js +129 -129
- package/web/app/ui/menu.js +75 -89
- package/web/app/ui/notify.js +45 -45
- package/web/app/ui/page-view.js +221 -221
- package/web/app/ui/popup.js +80 -80
- package/web/app/ui/present.js +292 -292
- package/web/app/ui/ribbon.js +868 -878
- package/web/app/ui/slide-pane.js +197 -189
- package/web/app/ui/statusbar.js +93 -93
- package/web/app/ui/text-styles.js +84 -84
- package/web/app/ui/titlebar.js +184 -67
- package/web/app/ui/transition.js +30 -30
- package/web/index.html +23 -21
- package/web/serve.mjs +22 -67
- package/web/styles/office.css +466 -644
- package/web/styles/slides.css +97 -219
- package/web/styles/tokens.css +154 -155
- package/src/kernel/util/escape.js +0 -21
- package/src/kernel/util/id.js +0 -13
- package/web/app/ui/backstage.js +0 -255
package/web/styles/slides.css
CHANGED
|
@@ -1,219 +1,97 @@
|
|
|
1
|
-
/* [文件] gbpptx
|
|
2
|
-
|
|
3
|
-
[hidden] { display: none !important; }
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
.sl-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
.sl-obj
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
.sl-obj--
|
|
30
|
-
.sl-obj
|
|
31
|
-
.sl-obj
|
|
32
|
-
|
|
33
|
-
.sl-
|
|
34
|
-
.sl-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
}
|
|
38
|
-
.sl-text
|
|
39
|
-
.sl-text
|
|
40
|
-
.sl-text
|
|
41
|
-
.sl-text
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
.
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
}
|
|
50
|
-
.
|
|
51
|
-
|
|
52
|
-
.
|
|
53
|
-
.
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
}
|
|
58
|
-
.
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
.
|
|
66
|
-
.
|
|
67
|
-
.
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
}
|
|
74
|
-
.
|
|
75
|
-
|
|
76
|
-
.
|
|
77
|
-
.
|
|
78
|
-
.
|
|
79
|
-
.
|
|
80
|
-
.
|
|
81
|
-
.
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
}
|
|
85
|
-
.
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
.
|
|
90
|
-
.
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
}
|
|
95
|
-
.
|
|
96
|
-
.
|
|
97
|
-
.
|
|
98
|
-
.pp-sel__handle[data-dir='e'] { left: 100%; top: 50%; cursor: ew-resize; }
|
|
99
|
-
.pp-sel__handle[data-dir='se'] { left: 100%; top: 100%; cursor: nwse-resize; }
|
|
100
|
-
.pp-sel__handle[data-dir='s'] { left: 50%; top: 100%; cursor: ns-resize; }
|
|
101
|
-
.pp-sel__handle[data-dir='sw'] { left: 0; top: 100%; cursor: nesw-resize; }
|
|
102
|
-
.pp-sel__handle[data-dir='w'] { left: 0; top: 50%; cursor: ew-resize; }
|
|
103
|
-
.pp-sel__rotate {
|
|
104
|
-
position: absolute; left: 50%; width: calc(16px * var(--pp-inv, 1)); height: calc(16px * var(--pp-inv, 1));
|
|
105
|
-
margin-left: calc(-8px * var(--pp-inv, 1)); border-radius: 50%; background: #fff;
|
|
106
|
-
border: 1px solid var(--pp-accent, #c43e1c); cursor: grab; pointer-events: auto;
|
|
107
|
-
}
|
|
108
|
-
.pp-sel__rotate::after {
|
|
109
|
-
content: '↻'; display: block; text-align: center; line-height: calc(14px * var(--pp-inv, 1));
|
|
110
|
-
font-size: calc(11px * var(--pp-inv, 1)); color: var(--pp-accent, #c43e1c);
|
|
111
|
-
}
|
|
112
|
-
|
|
113
|
-
/* ==================== 浮层 / 菜单 ==================== */
|
|
114
|
-
|
|
115
|
-
.gb-popup {
|
|
116
|
-
position: fixed; z-index: 3000; overflow-y: auto; border: 1px solid #d1cfcd; border-radius: 4px;
|
|
117
|
-
background: #fff; box-shadow: 0 8px 26px rgba(0, 0, 0, 0.18); color: #201f1e;
|
|
118
|
-
}
|
|
119
|
-
.gb-menu__list { min-width: 178px; padding: 3px; }
|
|
120
|
-
.gb-menu__list--compact { min-width: 120px; }
|
|
121
|
-
.gb-menu__header { padding: 6px 10px 4px; color: #797775; font-size: 11px; font-weight: 600; letter-spacing: .02em; }
|
|
122
|
-
.gb-menu__item {
|
|
123
|
-
display: flex; align-items: center; gap: 7px; padding: 6px 9px; border-radius: 3px;
|
|
124
|
-
font-size: 12.5px; white-space: nowrap; cursor: pointer; color: #201f1e;
|
|
125
|
-
}
|
|
126
|
-
.gb-menu__item:hover { background: #f3f2f1; }
|
|
127
|
-
.gb-menu__item.is-disabled { color: #b4b2af; cursor: default; }
|
|
128
|
-
.gb-menu__item.is-disabled:hover { background: transparent; }
|
|
129
|
-
.gb-menu__item.is-danger { color: #c43e1c; }
|
|
130
|
-
.gb-menu__item.is-danger:hover { background: #fdeae6; }
|
|
131
|
-
.gb-menu__lead { width: 16px; display: inline-flex; justify-content: center; color: #605e5c; }
|
|
132
|
-
.gb-menu__item.is-active .gb-menu__lead { color: var(--pp-accent, #c43e1c); }
|
|
133
|
-
.gb-menu__dot { width: 12px; height: 12px; border-radius: 3px; border: 1px solid #c8c6c4; }
|
|
134
|
-
.gb-menu__label { flex: 1; }
|
|
135
|
-
.gb-menu__shortcut { color: #a19f9d; font-size: 10.5px; }
|
|
136
|
-
.gb-menu__arrow { color: #a19f9d; }
|
|
137
|
-
.gb-menu__sep { height: 1px; margin: 3px 2px; background: #edebe9; }
|
|
138
|
-
|
|
139
|
-
.gb-color { width: 236px; padding: 10px; }
|
|
140
|
-
.gb-color__title { margin-bottom: 7px; color: #605e5c; font-size: 11.5px; font-weight: 600; }
|
|
141
|
-
.gb-color__grid { display: grid; gap: 3px; }
|
|
142
|
-
.gb-color__swatch {
|
|
143
|
-
width: 18px; height: 18px; padding: 0; border: 1px solid #d1cfcd; border-radius: 2px;
|
|
144
|
-
cursor: pointer;
|
|
145
|
-
}
|
|
146
|
-
.gb-color__swatch:hover { outline: 1px solid var(--pp-accent, #c43e1c); }
|
|
147
|
-
.gb-color__swatch.is-active { outline: 2px solid var(--pp-accent, #c43e1c); outline-offset: 1px; }
|
|
148
|
-
.gb-color__custom { display: flex; align-items: center; gap: 8px; margin-top: 9px; }
|
|
149
|
-
.gb-color__custom input[type='color'] { width: 34px; height: 28px; padding: 0; border: 1px solid #d1cfcd; background: #fff; }
|
|
150
|
-
.gb-color__actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 9px; }
|
|
151
|
-
|
|
152
|
-
.gb-modal-overlay {
|
|
153
|
-
position: fixed; inset: 0; z-index: 4200; display: flex; align-items: center; justify-content: center;
|
|
154
|
-
background: rgba(0, 0, 0, 0.28);
|
|
155
|
-
}
|
|
156
|
-
.gb-modal {
|
|
157
|
-
max-height: 86vh; display: flex; flex-direction: column; border: 1px solid #d1cfcd; border-radius: 5px;
|
|
158
|
-
background: #fff; box-shadow: 0 16px 48px rgba(0, 0, 0, 0.28);
|
|
159
|
-
}
|
|
160
|
-
.gb-modal__head { display: flex; align-items: center; padding: 12px 16px; border-bottom: 1px solid #edebe9; }
|
|
161
|
-
.gb-modal__title { flex: 1; font-size: 15px; font-weight: 600; }
|
|
162
|
-
.gb-modal__body { padding: 16px; overflow-y: auto; font-size: 13px; }
|
|
163
|
-
.gb-modal__foot { display: flex; justify-content: flex-end; gap: 8px; padding: 12px 16px; border-top: 1px solid #edebe9; }
|
|
164
|
-
.gb-modal__close { border: none; background: none; color: #605e5c; font-size: 14px; cursor: pointer; }
|
|
165
|
-
.gb-modal__message { margin: 0; line-height: 1.65; white-space: pre-wrap; }
|
|
166
|
-
|
|
167
|
-
.gb-btn {
|
|
168
|
-
height: 30px; padding: 0 14px; border: 1px solid #d1cfcd; border-radius: 3px; background: #fff;
|
|
169
|
-
color: #201f1e; font-size: 12.5px; cursor: pointer;
|
|
170
|
-
}
|
|
171
|
-
.gb-btn:hover { border-color: #a19f9d; background: #f8f8f8; }
|
|
172
|
-
.gb-btn--primary { border-color: var(--pp-accent, #c43e1c); background: var(--pp-accent, #c43e1c); color: #fff; }
|
|
173
|
-
.gb-btn--primary:hover { background: #a8341a; border-color: #a8341a; }
|
|
174
|
-
.gb-btn--danger { border-color: #c43e1c; background: #c43e1c; color: #fff; }
|
|
175
|
-
.gb-btn--danger:hover { background: #a8341a; }
|
|
176
|
-
.gb-input {
|
|
177
|
-
height: 30px; padding: 0 8px; border: 1px solid #d1cfcd; border-radius: 3px; background: #fff;
|
|
178
|
-
color: #201f1e; font-size: 12.5px; outline: none; box-sizing: border-box;
|
|
179
|
-
}
|
|
180
|
-
.gb-input:focus { border-color: var(--pp-accent, #c43e1c); box-shadow: 0 0 0 1px var(--pp-accent, #c43e1c) inset; }
|
|
181
|
-
.gb-field { display: flex; align-items: center; gap: 10px; min-height: 32px; }
|
|
182
|
-
.gb-field__label { width: 92px; flex: none; color: #605e5c; font-size: 12px; }
|
|
183
|
-
.gb-field .gb-input { flex: 1; min-width: 0; }
|
|
184
|
-
.gb-check { display: flex; align-items: center; gap: 7px; font-size: 12.5px; cursor: pointer; }
|
|
185
|
-
|
|
186
|
-
/* ==================== 通知 ==================== */
|
|
187
|
-
|
|
188
|
-
.gbdocs-notify-host {
|
|
189
|
-
position: fixed; top: 44px; right: 16px; z-index: 5000; display: flex; flex-direction: column;
|
|
190
|
-
gap: 8px; pointer-events: none;
|
|
191
|
-
}
|
|
192
|
-
.gb-notify {
|
|
193
|
-
display: flex; align-items: center; gap: 9px; min-width: 220px; max-width: 400px;
|
|
194
|
-
padding: 9px 13px; border: 1px solid #d1cfcd; border-left: 4px solid var(--pp-accent, #c43e1c);
|
|
195
|
-
border-radius: 3px; background: #fff; box-shadow: 0 8px 24px rgba(0, 0, 0, 0.16);
|
|
196
|
-
font-size: 12.5px; opacity: 0; transform: translateY(-6px);
|
|
197
|
-
transition: opacity .18s ease, transform .18s ease; pointer-events: auto; cursor: pointer;
|
|
198
|
-
}
|
|
199
|
-
.gb-notify.is-in { opacity: 1; transform: translateY(0); }
|
|
200
|
-
.gb-notify__badge {
|
|
201
|
-
width: 18px; height: 18px; display: grid; place-items: center; border-radius: 50%;
|
|
202
|
-
color: #fff; font-size: 11px; flex-shrink: 0;
|
|
203
|
-
}
|
|
204
|
-
.gb-notify--success { border-left-color: #107c10; }
|
|
205
|
-
.gb-notify--success .gb-notify__badge { background: #107c10; }
|
|
206
|
-
.gb-notify--error { border-left-color: #a4262c; }
|
|
207
|
-
.gb-notify--error .gb-notify__badge { background: #a4262c; }
|
|
208
|
-
.gb-notify--warning { border-left-color: #d18f00; }
|
|
209
|
-
.gb-notify--warning .gb-notify__badge { background: #d18f00; }
|
|
210
|
-
.gb-notify--info { border-left-color: var(--pp-accent, #c43e1c); }
|
|
211
|
-
.gb-notify--info .gb-notify__badge { background: var(--pp-accent, #c43e1c); }
|
|
212
|
-
.gb-notify__text { word-break: break-word; }
|
|
213
|
-
|
|
214
|
-
/* ==================== 打印 ==================== */
|
|
215
|
-
|
|
216
|
-
@media print {
|
|
217
|
-
.pp-titlebar, .pp-ribbon, .pp-slidepane, .pp-formatpane, .pp-statusbar, .pp-notes, .pp-findbar { display: none !important; }
|
|
218
|
-
.pp-app, .pp-main, .pp-center, .pp-canvas { display: block; background: #fff; }
|
|
219
|
-
}
|
|
1
|
+
/* [文件] gbpptx·应用样式 —— 幻灯片页渲染 / 浮层 / 通知 */
|
|
2
|
+
|
|
3
|
+
[hidden] { display: none !important; }
|
|
4
|
+
|
|
5
|
+
.gbp-root { height: 100%; margin: 0; }
|
|
6
|
+
.gbp-root {
|
|
7
|
+
color: var(--gbp-dt-text);
|
|
8
|
+
background: var(--gbp-dt-bg-2);
|
|
9
|
+
font-family: 'Microsoft YaHei', -apple-system, 'Segoe UI', sans-serif;
|
|
10
|
+
font-size: 14px;
|
|
11
|
+
}
|
|
12
|
+
.gbp-root { height: 100%; min-height: 0; }
|
|
13
|
+
.gbp-root button { font-family: inherit; font-size: inherit; color: inherit; }
|
|
14
|
+
|
|
15
|
+
/* ==================== 幻灯片页渲染(缩略图/画布/放映/打印共用同一坐标系 960×540) ==================== */
|
|
16
|
+
|
|
17
|
+
.sl-page {
|
|
18
|
+
position: relative; width: 960px; height: 540px; overflow: hidden;
|
|
19
|
+
background: #fff; color: #202124;
|
|
20
|
+
}
|
|
21
|
+
.sl-obj { position: absolute; box-sizing: border-box; }
|
|
22
|
+
.sl-obj--gbp-text { }
|
|
23
|
+
.sl-obj--gbp-shape { display: flex; align-items: center; justify-content: center; }
|
|
24
|
+
.sl-obj--gbp-shape svg { position: absolute; inset: 0; width: 100%; height: 100%; }
|
|
25
|
+
.sl-obj--gbp-shape .sl-shape-text {
|
|
26
|
+
position: relative; z-index: 1; width: 100%; text-align: center; white-space: pre-wrap;
|
|
27
|
+
word-break: break-word; padding: 4px;
|
|
28
|
+
}
|
|
29
|
+
.sl-obj--gbp-image img { display: block; width: 100%; height: 100%; object-fit: contain; }
|
|
30
|
+
.sl-obj--gbp-line svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
|
|
31
|
+
.sl-obj--gbp-table { display: block; }
|
|
32
|
+
.sl-obj.gbp-is-editing { outline: 1px dashed var(--gbp-dt-accent); outline-offset: 1px; }
|
|
33
|
+
.sl-table { width: 100%; height: 100%; border-collapse: collapse; table-layout: fixed; }
|
|
34
|
+
.sl-table td { border: 1px solid var(--gbp-dt-border-strong); padding: 2px 6px; vertical-align: top; white-space: pre-wrap; word-break: break-word; }
|
|
35
|
+
|
|
36
|
+
/* 正文通用排版(渲染层与就地编辑器共用一份口径) */
|
|
37
|
+
.sl-text { width: 100%; height: 100%; line-height: 1.35; word-break: break-word; white-space: pre-wrap; outline: none; }
|
|
38
|
+
.sl-text div, .sl-text p { margin: 0 0 .35em; }
|
|
39
|
+
.sl-text ul, .sl-text ol { margin: 0 0 .35em; padding-left: 1.4em; }
|
|
40
|
+
.sl-text li { margin: 0; }
|
|
41
|
+
.sl-text img { display: block; max-width: 100%; max-height: 100%; object-fit: contain; margin: .2em 0; }
|
|
42
|
+
|
|
43
|
+
/* ==================== 浮层(菜单/气泡/色板/模态) ==================== */
|
|
44
|
+
|
|
45
|
+
.gbp-popup {
|
|
46
|
+
position: fixed; z-index: 1000; overflow-y: auto; border: 1px solid var(--gbp-dt-border); border-radius: 6px;
|
|
47
|
+
background: var(--gbp-dt-surface); box-shadow: var(--gbp-dt-shadow-popup); color: var(--gbp-dt-text);
|
|
48
|
+
}
|
|
49
|
+
.gbp-menu__list { min-width: 160px; padding: 4px; }
|
|
50
|
+
.gbp-menu__item { display: flex; align-items: center; gap: 6px; padding: 5px 8px; border-radius: 4px; font-size: 13px; white-space: nowrap; cursor: pointer; }
|
|
51
|
+
.gbp-menu__item:hover { background: var(--gbp-dt-hover); }
|
|
52
|
+
.gbp-menu__item.gbp-is-disabled { color: var(--gbp-dt-text-disabled); cursor: default; }
|
|
53
|
+
.gbp-menu__item.gbp-is-disabled:hover { background: transparent; }
|
|
54
|
+
.gbp-menu__lead { width: 14px; display: inline-flex; justify-content: center; }
|
|
55
|
+
.gbp-menu__dot { width: 12px; height: 12px; border-radius: 3px; border: 1px solid var(--gbp-dt-border-strong); }
|
|
56
|
+
.gbp-menu__label { flex: 1; }
|
|
57
|
+
.gbp-menu__shortcut { color: var(--gbp-dt-text-tertiary); font-size: 11px; }
|
|
58
|
+
.gbp-menu__arrow { color: var(--gbp-dt-text-tertiary); }
|
|
59
|
+
.gbp-menu__sep { height: 1px; margin: 4px 0; background: var(--gbp-dt-border); }
|
|
60
|
+
|
|
61
|
+
.gbp-btn { padding: 4px 12px; border: 1px solid var(--gbp-dt-border-strong); border-radius: 6px; background: var(--gbp-dt-bg); color: var(--gbp-dt-text); font-size: 13px; cursor: pointer; }
|
|
62
|
+
.gbp-btn:hover { border-color: var(--gbp-dt-accent); background: var(--gbp-dt-accent-soft); }
|
|
63
|
+
.gbp-btn--primary { border-color: var(--gbp-dt-accent); background: var(--gbp-dt-accent); color: var(--gbp-dt-on-accent); }
|
|
64
|
+
.gbp-iconbtn { width: 24px; height: 24px; display: grid; place-items: center; border: 1px solid transparent; border-radius: 4px; background: transparent; color: var(--gbp-dt-text-secondary); cursor: pointer; }
|
|
65
|
+
.gbp-iconbtn:hover { background: var(--gbp-dt-hover); }
|
|
66
|
+
.gbp-input { height: 28px; padding: 0 8px; border: 1px solid var(--gbp-dt-border-strong); border-radius: 4px; background: var(--gbp-dt-bg); color: var(--gbp-dt-text); font-size: 13px; outline: none; }
|
|
67
|
+
.gbp-input:focus { border-color: var(--gbp-dt-accent); }
|
|
68
|
+
|
|
69
|
+
.gbp-color { width: 232px; padding: 10px; }
|
|
70
|
+
.gbp-color__grid { display: grid; gap: 3px; }
|
|
71
|
+
.gbp-color__swatch { width: 18px; height: 18px; border: 1px solid var(--gbp-dt-border-strong); border-radius: 3px; cursor: pointer; }
|
|
72
|
+
.gbp-color__swatch.gbp-is-active { outline: 2px solid var(--gbp-dt-accent); outline-offset: 1px; }
|
|
73
|
+
.gbp-color__custom { display: flex; align-items: center; gap: 8px; margin-top: 8px; }
|
|
74
|
+
.gbp-color__actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 8px; }
|
|
75
|
+
|
|
76
|
+
.gbp-modal-overlay { position: fixed; inset: 0; z-index: 1200; display: flex; align-items: center; justify-content: center; background: rgba(0,0,0,.32); }
|
|
77
|
+
.gbp-modal { max-height: 86vh; display: flex; flex-direction: column; border: 1px solid var(--gbp-dt-border); border-radius: 8px; background: var(--gbp-dt-surface); box-shadow: var(--gbp-dt-shadow-window); }
|
|
78
|
+
.gbp-modal__head { display: flex; align-items: center; padding: 10px 14px; border-bottom: 1px solid var(--gbp-dt-border); }
|
|
79
|
+
.gbp-modal__title { flex: 1; font-size: 14px; font-weight: 600; }
|
|
80
|
+
.gbp-modal__body { padding: 14px; overflow-y: auto; }
|
|
81
|
+
.gbp-modal__foot { display: flex; justify-content: flex-end; gap: 8px; padding: 10px 14px; border-top: 1px solid var(--gbp-dt-border); }
|
|
82
|
+
.gbp-field { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
|
|
83
|
+
.gbp-field__label { width: 88px; color: var(--gbp-dt-text-secondary); font-size: 12px; }
|
|
84
|
+
.gbp-field .gbp-input { flex: 1; min-width: 0; }
|
|
85
|
+
.gbp-modal__foot .gbp-modal__close { border: none; background: none; color: var(--gbp-dt-text-secondary); font-size: 14px; cursor: pointer; }
|
|
86
|
+
|
|
87
|
+
/* ==================== 通知 ==================== */
|
|
88
|
+
|
|
89
|
+
.gbdocx-notify-host { position: fixed; top: 14px; right: 14px; z-index: 2000; display: flex; flex-direction: column; gap: 8px; pointer-events: none; }
|
|
90
|
+
.gbp-notify { display: flex; align-items: center; gap: 8px; min-width: 200px; max-width: 360px; padding: 8px 12px; border: 1px solid var(--gbp-dt-border); border-radius: 6px; background: var(--gbp-dt-surface); box-shadow: var(--gbp-dt-shadow-popup); font-size: 13px; opacity: 0; transform: translateY(-8px); transition: opacity var(--gbp-dt-duration-normal) var(--gbp-dt-ease-out), transform var(--gbp-dt-duration-normal) var(--gbp-dt-ease-out); pointer-events: auto; cursor: pointer; }
|
|
91
|
+
.gbp-notify.gbp-is-in { opacity: 1; transform: translateY(0); }
|
|
92
|
+
.gbp-notify__badge { width: 18px; height: 18px; display: grid; place-items: center; border-radius: 50%; color: #fff; font-size: 12px; flex-shrink: 0; }
|
|
93
|
+
.gbp-notify--success .gbp-notify__badge { background: var(--gbp-dt-success); }
|
|
94
|
+
.gbp-notify--error .gbp-notify__badge { background: var(--gbp-dt-danger); }
|
|
95
|
+
.gbp-notify--warning .gbp-notify__badge { background: var(--gbp-dt-warning); }
|
|
96
|
+
.gbp-notify--info .gbp-notify__badge { background: var(--gbp-dt-accent); }
|
|
97
|
+
.gbp-notify__text { word-break: break-word; }
|
package/web/styles/tokens.css
CHANGED
|
@@ -1,155 +1,154 @@
|
|
|
1
|
-
/* [文件]
|
|
2
|
-
|
|
3
|
-
:root {
|
|
4
|
-
--dt-accent: #2a6bff;
|
|
5
|
-
--dt-accent-hover: #5a8bff;
|
|
6
|
-
--dt-accent-active: #1f52d8;
|
|
7
|
-
--dt-on-accent: #ffffff;
|
|
8
|
-
--dt-accent-soft: rgba(42, 107, 255, 0.14);
|
|
9
|
-
--dt-accent-soft-strong: rgba(42, 107, 255, 0.3);
|
|
10
|
-
--dt-accent-fill: rgba(42, 107, 255, 0.42);
|
|
11
|
-
|
|
12
|
-
--dt-surface: #
|
|
13
|
-
--dt-surface-2: rgba(255, 255, 255, 0.72);
|
|
14
|
-
--dt-surface-3: rgba(255, 255, 255, 0.55);
|
|
15
|
-
|
|
16
|
-
--dt-bg: #ffffff;
|
|
17
|
-
--dt-bg-2: #
|
|
18
|
-
--dt-bg-3: #
|
|
19
|
-
--dt-scrim: #
|
|
20
|
-
--dt-media-overlay: rgba(0, 0, 0, 0.68);
|
|
21
|
-
|
|
22
|
-
--dt-text: #171a1f;
|
|
23
|
-
--dt-text-secondary: rgba(23, 26, 31, 0.64);
|
|
24
|
-
--dt-text-tertiary: rgba(23, 26, 31, 0.44);
|
|
25
|
-
--dt-text-disabled: rgba(23, 26, 31, 0.3);
|
|
26
|
-
|
|
27
|
-
--dt-border: rgba(23, 26, 31, 0.09);
|
|
28
|
-
--dt-border-strong: rgba(23, 26, 31, 0.18);
|
|
29
|
-
|
|
30
|
-
--dt-hover: rgba(23, 26, 31, 0.05);
|
|
31
|
-
--dt-active: rgba(23, 26, 31, 0.09);
|
|
32
|
-
|
|
33
|
-
--dt-fill: rgba(23, 26, 31, 0.035);
|
|
34
|
-
--dt-fill-light: rgba(23, 26, 31, 0.02);
|
|
35
|
-
|
|
36
|
-
--dt-scrollbar: rgba(23, 26, 31, 0.18);
|
|
37
|
-
--dt-scrollbar-hover: rgba(23, 26, 31, 0.3);
|
|
38
|
-
|
|
39
|
-
--dt-success: #16a34a;
|
|
40
|
-
--dt-success-soft: rgba(22, 163, 74, 0.14);
|
|
41
|
-
--dt-warning: #f59e0b;
|
|
42
|
-
--dt-warning-soft: rgba(245, 158, 11, 0.14);
|
|
43
|
-
--dt-danger: #e5484d;
|
|
44
|
-
--dt-danger-hover: #d93a40;
|
|
45
|
-
--dt-danger-soft: rgba(229, 72, 77, 0.12);
|
|
46
|
-
|
|
47
|
-
--dt-shadow-popup: 0 10px 34px rgba(15, 23, 42, 0.18);
|
|
48
|
-
--dt-shadow-window: 0 10px 30px rgba(15, 23, 42, 0.14);
|
|
49
|
-
|
|
50
|
-
--dt-radius-sm: 8px;
|
|
51
|
-
--dt-radius-md: 10px;
|
|
52
|
-
--dt-radius-lg: 14px;
|
|
53
|
-
|
|
54
|
-
--dt-ease-out: cubic-bezier(0.16, 1, 0.3, 1);
|
|
55
|
-
--dt-duration-fast: 0.15s;
|
|
56
|
-
--dt-duration-normal: 0.22s;
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
[data-theme='dark'] {
|
|
60
|
-
--dt-on-accent: #ffffff;
|
|
61
|
-
--dt-accent-soft: rgba(122, 162, 255, 0.2);
|
|
62
|
-
--dt-accent-soft-strong: rgba(122, 162, 255, 0.4);
|
|
63
|
-
--dt-accent-fill: rgba(122, 162, 255, 0.5);
|
|
64
|
-
|
|
65
|
-
--dt-surface: #1a1d24;
|
|
66
|
-
--dt-surface-2: rgba(35, 39, 48, 0.72);
|
|
67
|
-
--dt-surface-3: rgba(47, 52, 63, 0.55);
|
|
68
|
-
|
|
69
|
-
--dt-bg: #1a1d24;
|
|
70
|
-
--dt-bg-2: #22262f;
|
|
71
|
-
--dt-bg-3: #282d37;
|
|
72
|
-
--dt-scrim: #1a1d24;
|
|
73
|
-
|
|
74
|
-
--dt-text: #eef1f6;
|
|
75
|
-
--dt-text-secondary: rgba(238, 241, 246, 0.64);
|
|
76
|
-
--dt-text-tertiary: rgba(238, 241, 246, 0.44);
|
|
77
|
-
--dt-text-disabled: rgba(238, 241, 246, 0.3);
|
|
78
|
-
|
|
79
|
-
--dt-border: rgba(255, 255, 255, 0.09);
|
|
80
|
-
--dt-border-strong: rgba(255, 255, 255, 0.18);
|
|
81
|
-
|
|
82
|
-
--dt-hover: rgba(255, 255, 255, 0.06);
|
|
83
|
-
--dt-active: rgba(255, 255, 255, 0.1);
|
|
84
|
-
|
|
85
|
-
--dt-fill: rgba(255, 255, 255, 0.04);
|
|
86
|
-
--dt-fill-light: rgba(255, 255, 255, 0.02);
|
|
87
|
-
|
|
88
|
-
--dt-scrollbar: rgba(255, 255, 255, 0.18);
|
|
89
|
-
--dt-scrollbar-hover: rgba(255, 255, 255, 0.3);
|
|
90
|
-
|
|
91
|
-
--dt-success: #34c47c;
|
|
92
|
-
--dt-success-soft: rgba(52, 196, 124, 0.16);
|
|
93
|
-
--dt-warning: #fbbf24;
|
|
94
|
-
--dt-warning-soft: rgba(251, 191, 36, 0.16);
|
|
95
|
-
--dt-danger: #ff6b6e;
|
|
96
|
-
--dt-danger-hover: #ff8d90;
|
|
97
|
-
--dt-danger-soft: rgba(255, 107, 110, 0.18);
|
|
98
|
-
|
|
99
|
-
--dt-shadow-popup: 0 10px 38px rgba(0, 0, 0, 0.58);
|
|
100
|
-
--dt-shadow-window: 0 12px 36px rgba(0, 0, 0, 0.55);
|
|
101
|
-
}
|
|
102
|
-
|
|
103
|
-
* {
|
|
104
|
-
scrollbar-color: var(--dt-scrollbar) transparent;
|
|
105
|
-
box-sizing: border-box;
|
|
106
|
-
}
|
|
107
|
-
|
|
108
|
-
::-webkit-scrollbar {
|
|
109
|
-
width: 8px;
|
|
110
|
-
height: 8px;
|
|
111
|
-
}
|
|
112
|
-
::-webkit-scrollbar-track {
|
|
113
|
-
background: transparent;
|
|
114
|
-
}
|
|
115
|
-
::-webkit-scrollbar-thumb {
|
|
116
|
-
background: var(--dt-scrollbar);
|
|
117
|
-
border-radius: 4px;
|
|
118
|
-
}
|
|
119
|
-
::-webkit-scrollbar-thumb:hover {
|
|
120
|
-
background: var(--dt-scrollbar-hover);
|
|
121
|
-
}
|
|
122
|
-
::-webkit-scrollbar-corner {
|
|
123
|
-
background: transparent;
|
|
124
|
-
}
|
|
125
|
-
|
|
126
|
-
.dt-scrollbar-thin::-webkit-scrollbar {
|
|
127
|
-
width: 4px;
|
|
128
|
-
height: 4px;
|
|
129
|
-
}
|
|
130
|
-
.dt-scrollbar-thin::-webkit-scrollbar-thumb {
|
|
131
|
-
border-radius: 2px;
|
|
132
|
-
}
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
font-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
height:
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
font-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
}
|
|
1
|
+
/* [文件] gbdocx·设计令牌 —— 全局视觉变量唯一数据源(移植自 guabi desks top tokens.css 的相关子集) */
|
|
2
|
+
|
|
3
|
+
:root {
|
|
4
|
+
--gbp-dt-accent: #2a6bff;
|
|
5
|
+
--gbp-dt-accent-hover: #5a8bff;
|
|
6
|
+
--gbp-dt-accent-active: #1f52d8;
|
|
7
|
+
--gbp-dt-on-accent: #ffffff;
|
|
8
|
+
--gbp-dt-accent-soft: rgba(42, 107, 255, 0.14);
|
|
9
|
+
--gbp-dt-accent-soft-strong: rgba(42, 107, 255, 0.3);
|
|
10
|
+
--gbp-dt-accent-fill: rgba(42, 107, 255, 0.42);
|
|
11
|
+
|
|
12
|
+
--gbp-dt-surface: #ffffff;
|
|
13
|
+
--gbp-dt-surface-2: rgba(255, 255, 255, 0.72);
|
|
14
|
+
--gbp-dt-surface-3: rgba(255, 255, 255, 0.55);
|
|
15
|
+
|
|
16
|
+
--gbp-dt-bg: #ffffff;
|
|
17
|
+
--gbp-dt-bg-2: #ffffff;
|
|
18
|
+
--gbp-dt-bg-3: #ffffff;
|
|
19
|
+
--gbp-dt-scrim: #ffffff;
|
|
20
|
+
--gbp-dt-media-overlay: rgba(0, 0, 0, 0.68);
|
|
21
|
+
|
|
22
|
+
--gbp-dt-text: #171a1f;
|
|
23
|
+
--gbp-dt-text-secondary: rgba(23, 26, 31, 0.64);
|
|
24
|
+
--gbp-dt-text-tertiary: rgba(23, 26, 31, 0.44);
|
|
25
|
+
--gbp-dt-text-disabled: rgba(23, 26, 31, 0.3);
|
|
26
|
+
|
|
27
|
+
--gbp-dt-border: rgba(23, 26, 31, 0.09);
|
|
28
|
+
--gbp-dt-border-strong: rgba(23, 26, 31, 0.18);
|
|
29
|
+
|
|
30
|
+
--gbp-dt-hover: rgba(23, 26, 31, 0.05);
|
|
31
|
+
--gbp-dt-active: rgba(23, 26, 31, 0.09);
|
|
32
|
+
|
|
33
|
+
--gbp-dt-fill: rgba(23, 26, 31, 0.035);
|
|
34
|
+
--gbp-dt-fill-light: rgba(23, 26, 31, 0.02);
|
|
35
|
+
|
|
36
|
+
--gbp-dt-scrollbar: rgba(23, 26, 31, 0.18);
|
|
37
|
+
--gbp-dt-scrollbar-hover: rgba(23, 26, 31, 0.3);
|
|
38
|
+
|
|
39
|
+
--gbp-dt-success: #16a34a;
|
|
40
|
+
--gbp-dt-success-soft: rgba(22, 163, 74, 0.14);
|
|
41
|
+
--gbp-dt-warning: #f59e0b;
|
|
42
|
+
--gbp-dt-warning-soft: rgba(245, 158, 11, 0.14);
|
|
43
|
+
--gbp-dt-danger: #e5484d;
|
|
44
|
+
--gbp-dt-danger-hover: #d93a40;
|
|
45
|
+
--gbp-dt-danger-soft: rgba(229, 72, 77, 0.12);
|
|
46
|
+
|
|
47
|
+
--gbp-dt-shadow-popup: 0 10px 34px rgba(15, 23, 42, 0.18);
|
|
48
|
+
--gbp-dt-shadow-window: 0 10px 30px rgba(15, 23, 42, 0.14);
|
|
49
|
+
|
|
50
|
+
--gbp-dt-radius-sm: 8px;
|
|
51
|
+
--gbp-dt-radius-md: 10px;
|
|
52
|
+
--gbp-dt-radius-lg: 14px;
|
|
53
|
+
|
|
54
|
+
--gbp-dt-ease-out: cubic-bezier(0.16, 1, 0.3, 1);
|
|
55
|
+
--gbp-dt-duration-fast: 0.15s;
|
|
56
|
+
--gbp-dt-duration-normal: 0.22s;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
[data-gbp-theme='dark'] {
|
|
60
|
+
--gbp-dt-on-accent: #ffffff;
|
|
61
|
+
--gbp-dt-accent-soft: rgba(122, 162, 255, 0.2);
|
|
62
|
+
--gbp-dt-accent-soft-strong: rgba(122, 162, 255, 0.4);
|
|
63
|
+
--gbp-dt-accent-fill: rgba(122, 162, 255, 0.5);
|
|
64
|
+
|
|
65
|
+
--gbp-dt-surface: #1a1d24;
|
|
66
|
+
--gbp-dt-surface-2: rgba(35, 39, 48, 0.72);
|
|
67
|
+
--gbp-dt-surface-3: rgba(47, 52, 63, 0.55);
|
|
68
|
+
|
|
69
|
+
--gbp-dt-bg: #1a1d24;
|
|
70
|
+
--gbp-dt-bg-2: #22262f;
|
|
71
|
+
--gbp-dt-bg-3: #282d37;
|
|
72
|
+
--gbp-dt-scrim: #1a1d24;
|
|
73
|
+
|
|
74
|
+
--gbp-dt-text: #eef1f6;
|
|
75
|
+
--gbp-dt-text-secondary: rgba(238, 241, 246, 0.64);
|
|
76
|
+
--gbp-dt-text-tertiary: rgba(238, 241, 246, 0.44);
|
|
77
|
+
--gbp-dt-text-disabled: rgba(238, 241, 246, 0.3);
|
|
78
|
+
|
|
79
|
+
--gbp-dt-border: rgba(255, 255, 255, 0.09);
|
|
80
|
+
--gbp-dt-border-strong: rgba(255, 255, 255, 0.18);
|
|
81
|
+
|
|
82
|
+
--gbp-dt-hover: rgba(255, 255, 255, 0.06);
|
|
83
|
+
--gbp-dt-active: rgba(255, 255, 255, 0.1);
|
|
84
|
+
|
|
85
|
+
--gbp-dt-fill: rgba(255, 255, 255, 0.04);
|
|
86
|
+
--gbp-dt-fill-light: rgba(255, 255, 255, 0.02);
|
|
87
|
+
|
|
88
|
+
--gbp-dt-scrollbar: rgba(255, 255, 255, 0.18);
|
|
89
|
+
--gbp-dt-scrollbar-hover: rgba(255, 255, 255, 0.3);
|
|
90
|
+
|
|
91
|
+
--gbp-dt-success: #34c47c;
|
|
92
|
+
--gbp-dt-success-soft: rgba(52, 196, 124, 0.16);
|
|
93
|
+
--gbp-dt-warning: #fbbf24;
|
|
94
|
+
--gbp-dt-warning-soft: rgba(251, 191, 36, 0.16);
|
|
95
|
+
--gbp-dt-danger: #ff6b6e;
|
|
96
|
+
--gbp-dt-danger-hover: #ff8d90;
|
|
97
|
+
--gbp-dt-danger-soft: rgba(255, 107, 110, 0.18);
|
|
98
|
+
|
|
99
|
+
--gbp-dt-shadow-popup: 0 10px 38px rgba(0, 0, 0, 0.58);
|
|
100
|
+
--gbp-dt-shadow-window: 0 12px 36px rgba(0, 0, 0, 0.55);
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
.gbp-root, .gbp-root * {
|
|
104
|
+
scrollbar-color: var(--gbp-dt-scrollbar) transparent;
|
|
105
|
+
box-sizing: border-box;
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
.gbp-root ::-webkit-scrollbar {
|
|
109
|
+
width: 8px;
|
|
110
|
+
height: 8px;
|
|
111
|
+
}
|
|
112
|
+
.gbp-root ::-webkit-scrollbar-track {
|
|
113
|
+
background: transparent;
|
|
114
|
+
}
|
|
115
|
+
.gbp-root ::-webkit-scrollbar-thumb {
|
|
116
|
+
background: var(--gbp-dt-scrollbar);
|
|
117
|
+
border-radius: 4px;
|
|
118
|
+
}
|
|
119
|
+
.gbp-root ::-webkit-scrollbar-thumb:hover {
|
|
120
|
+
background: var(--gbp-dt-scrollbar-hover);
|
|
121
|
+
}
|
|
122
|
+
.gbp-root ::-webkit-scrollbar-corner {
|
|
123
|
+
background: transparent;
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
.dt-scrollbar-thin::-webkit-scrollbar {
|
|
127
|
+
width: 4px;
|
|
128
|
+
height: 4px;
|
|
129
|
+
}
|
|
130
|
+
.dt-scrollbar-thin::-webkit-scrollbar-thumb {
|
|
131
|
+
border-radius: 2px;
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
.gbp-root {
|
|
135
|
+
height: 100%;
|
|
136
|
+
margin: 0;
|
|
137
|
+
}
|
|
138
|
+
.gbp-root {
|
|
139
|
+
color: var(--gbp-dt-text);
|
|
140
|
+
background: var(--gbp-dt-bg-2);
|
|
141
|
+
font-family: 'Microsoft YaHei', -apple-system, 'Segoe UI', sans-serif;
|
|
142
|
+
font-size: 14px;
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
.gbp-root {
|
|
146
|
+
height: 100%;
|
|
147
|
+
min-height: 0;
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
.gbp-root button {
|
|
151
|
+
font-family: inherit;
|
|
152
|
+
font-size: inherit;
|
|
153
|
+
color: inherit;
|
|
154
|
+
}
|