@univerjs/ui 0.1.0-alpha.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/LICENSE +21 -0
- package/README.md +16 -0
- package/lib/cjs/index.js +4671 -0
- package/lib/cjs/locale/en-US.js +46 -0
- package/lib/cjs/locale/zh-CN.js +35 -0
- package/lib/esm/index.js +4507 -0
- package/lib/esm/locale/en-US.js +25 -0
- package/lib/esm/locale/zh-CN.js +14 -0
- package/lib/index.css +474 -0
- package/lib/types/BaseComponent.d.ts +8 -0
- package/lib/types/BaseComponent.d.ts.map +1 -0
- package/lib/types/commands/operations/toggle-shortcut-panel.operation.d.ts +4 -0
- package/lib/types/commands/operations/toggle-shortcut-panel.operation.d.ts.map +1 -0
- package/lib/types/common/component-manager.d.ts +14 -0
- package/lib/types/common/component-manager.d.ts.map +1 -0
- package/lib/types/common/index.d.ts +3 -0
- package/lib/types/common/index.d.ts.map +1 -0
- package/lib/types/common/lifecycle.d.ts +4 -0
- package/lib/types/common/lifecycle.d.ts.map +1 -0
- package/lib/types/common/z-index-manager.d.ts +8 -0
- package/lib/types/common/z-index-manager.d.ts.map +1 -0
- package/lib/types/components/custom-label/CustomLabel.d.ts +14 -0
- package/lib/types/components/custom-label/CustomLabel.d.ts.map +1 -0
- package/lib/types/components/custom-label/index.d.ts +2 -0
- package/lib/types/components/custom-label/index.d.ts.map +1 -0
- package/lib/types/components/hooks/observable.d.ts +4 -0
- package/lib/types/components/hooks/observable.d.ts.map +1 -0
- package/lib/types/components/index.d.ts +3 -0
- package/lib/types/components/index.d.ts.map +1 -0
- package/lib/types/components/menu/Menu.d.ts +11 -0
- package/lib/types/components/menu/Menu.d.ts.map +1 -0
- package/lib/types/components/menu/index.d.ts +2 -0
- package/lib/types/components/menu/index.d.ts.map +1 -0
- package/lib/types/components/notification/Notification.d.ts +41 -0
- package/lib/types/components/notification/Notification.d.ts.map +1 -0
- package/lib/types/controllers/error/error.controller.d.ts +8 -0
- package/lib/types/controllers/error/error.controller.d.ts.map +1 -0
- package/lib/types/controllers/menus/menus.d.ts +5 -0
- package/lib/types/controllers/menus/menus.d.ts.map +1 -0
- package/lib/types/controllers/shared-shortcut.controller.d.ts +25 -0
- package/lib/types/controllers/shared-shortcut.controller.d.ts.map +1 -0
- package/lib/types/controllers/shortcut-display/menu.d.ts +3 -0
- package/lib/types/controllers/shortcut-display/menu.d.ts.map +1 -0
- package/lib/types/controllers/shortcut-display/shortcut-panel.controller.d.ts +10 -0
- package/lib/types/controllers/shortcut-display/shortcut-panel.controller.d.ts.map +1 -0
- package/lib/types/controllers/ui/ui-desktop.controller.d.ts +55 -0
- package/lib/types/controllers/ui/ui-desktop.controller.d.ts.map +1 -0
- package/lib/types/controllers/ui/ui.controller.d.ts +14 -0
- package/lib/types/controllers/ui/ui.controller.d.ts.map +1 -0
- package/lib/types/index.d.ts +30 -0
- package/lib/types/index.d.ts.map +1 -0
- package/lib/types/locale/en-US.d.ts +23 -0
- package/lib/types/locale/en-US.d.ts.map +1 -0
- package/lib/types/locale/index.d.ts +3 -0
- package/lib/types/locale/index.d.ts.map +1 -0
- package/lib/types/locale/zh-CN.d.ts +12 -0
- package/lib/types/locale/zh-CN.d.ts.map +1 -0
- package/lib/types/services/before-close/before-close.service.d.ts +21 -0
- package/lib/types/services/before-close/before-close.service.d.ts.map +1 -0
- package/lib/types/services/clipboard/clipboard-interface.service.d.ts +36 -0
- package/lib/types/services/clipboard/clipboard-interface.service.d.ts.map +1 -0
- package/lib/types/services/clipboard/clipboard.command.d.ts +5 -0
- package/lib/types/services/clipboard/clipboard.command.d.ts.map +1 -0
- package/lib/types/services/confirm/confirm.service.d.ts +10 -0
- package/lib/types/services/confirm/confirm.service.d.ts.map +1 -0
- package/lib/types/services/confirm/desktop-confirm.service.d.ts +12 -0
- package/lib/types/services/confirm/desktop-confirm.service.d.ts.map +1 -0
- package/lib/types/services/contextmenu/contextmenu.service.d.ts +18 -0
- package/lib/types/services/contextmenu/contextmenu.service.d.ts.map +1 -0
- package/lib/types/services/dialog/desktop-dialog.service.d.ts +12 -0
- package/lib/types/services/dialog/desktop-dialog.service.d.ts.map +1 -0
- package/lib/types/services/dialog/dialog.service.d.ts +10 -0
- package/lib/types/services/dialog/dialog.service.d.ts.map +1 -0
- package/lib/types/services/focus/focus.service.d.ts +22 -0
- package/lib/types/services/focus/focus.service.d.ts.map +1 -0
- package/lib/types/services/local-storage/local-storage.service.d.ts +11 -0
- package/lib/types/services/local-storage/local-storage.service.d.ts.map +1 -0
- package/lib/types/services/menu/menu.d.ts +103 -0
- package/lib/types/services/menu/menu.d.ts.map +1 -0
- package/lib/types/services/menu/menu.service.d.ts +28 -0
- package/lib/types/services/menu/menu.service.d.ts.map +1 -0
- package/lib/types/services/message/desktop-message.service.d.ts +11 -0
- package/lib/types/services/message/desktop-message.service.d.ts.map +1 -0
- package/lib/types/services/message/message.service.d.ts +8 -0
- package/lib/types/services/message/message.service.d.ts.map +1 -0
- package/lib/types/services/notification/desktop-notification.service.d.ts +7 -0
- package/lib/types/services/notification/desktop-notification.service.d.ts.map +1 -0
- package/lib/types/services/notification/notification.service.d.ts +7 -0
- package/lib/types/services/notification/notification.service.d.ts.map +1 -0
- package/lib/types/services/platform/platform.service.d.ts +15 -0
- package/lib/types/services/platform/platform.service.d.ts.map +1 -0
- package/lib/types/services/shortcut/keycode.d.ts +79 -0
- package/lib/types/services/shortcut/keycode.d.ts.map +1 -0
- package/lib/types/services/shortcut/shortcut-experience.service.d.ts +31 -0
- package/lib/types/services/shortcut/shortcut-experience.service.d.ts.map +1 -0
- package/lib/types/services/shortcut/shortcut-panel.service.d.ts +10 -0
- package/lib/types/services/shortcut/shortcut-panel.service.d.ts.map +1 -0
- package/lib/types/services/shortcut/shortcut.service.d.ts +55 -0
- package/lib/types/services/shortcut/shortcut.service.d.ts.map +1 -0
- package/lib/types/services/sidebar/desktop-sidebar.service.d.ts +12 -0
- package/lib/types/services/sidebar/desktop-sidebar.service.d.ts.map +1 -0
- package/lib/types/services/sidebar/sidebar.service.d.ts +10 -0
- package/lib/types/services/sidebar/sidebar.service.d.ts.map +1 -0
- package/lib/types/ui-plugin.d.ts +20 -0
- package/lib/types/ui-plugin.d.ts.map +1 -0
- package/lib/types/utils/cell.d.ts +34 -0
- package/lib/types/utils/cell.d.ts.map +1 -0
- package/lib/types/utils/index.d.ts +3 -0
- package/lib/types/utils/index.d.ts.map +1 -0
- package/lib/types/utils/util.d.ts +2 -0
- package/lib/types/utils/util.d.ts.map +1 -0
- package/lib/types/views/App.d.ts +13 -0
- package/lib/types/views/App.d.ts.map +1 -0
- package/lib/types/views/components/ComponentContainer.d.ts +6 -0
- package/lib/types/views/components/ComponentContainer.d.ts.map +1 -0
- package/lib/types/views/components/confirm-part/ConfirmPart.d.ts +3 -0
- package/lib/types/views/components/confirm-part/ConfirmPart.d.ts.map +1 -0
- package/lib/types/views/components/confirm-part/interface.d.ts +8 -0
- package/lib/types/views/components/confirm-part/interface.d.ts.map +1 -0
- package/lib/types/views/components/context-menu/ContextMenu.d.ts +5 -0
- package/lib/types/views/components/context-menu/ContextMenu.d.ts.map +1 -0
- package/lib/types/views/components/dialog-part/DialogPart.d.ts +3 -0
- package/lib/types/views/components/dialog-part/DialogPart.d.ts.map +1 -0
- package/lib/types/views/components/dialog-part/interface.d.ts +10 -0
- package/lib/types/views/components/dialog-part/interface.d.ts.map +1 -0
- package/lib/types/views/components/doc-bars/Button/ToolbarButton.d.ts +28 -0
- package/lib/types/views/components/doc-bars/Button/ToolbarButton.d.ts.map +1 -0
- package/lib/types/views/components/doc-bars/MenuBar.d.ts +7 -0
- package/lib/types/views/components/doc-bars/MenuBar.d.ts.map +1 -0
- package/lib/types/views/components/doc-bars/Toolbar.d.ts +3 -0
- package/lib/types/views/components/doc-bars/Toolbar.d.ts.map +1 -0
- package/lib/types/views/components/doc-bars/ToolbarItem.d.ts +4 -0
- package/lib/types/views/components/doc-bars/ToolbarItem.d.ts.map +1 -0
- package/lib/types/views/components/doc-bars/hooks/menu.d.ts +10 -0
- package/lib/types/views/components/doc-bars/hooks/menu.d.ts.map +1 -0
- package/lib/types/views/components/shortcut-panel/ShortcutPanel.d.ts +6 -0
- package/lib/types/views/components/shortcut-panel/ShortcutPanel.d.ts.map +1 -0
- package/lib/types/views/components/sidebar/Sidebar.d.ts +3 -0
- package/lib/types/views/components/sidebar/Sidebar.d.ts.map +1 -0
- package/lib/types/views/components/sidebar/interface.d.ts +11 -0
- package/lib/types/views/components/sidebar/interface.d.ts.map +1 -0
- package/lib/types/views/parts.d.ts +3 -0
- package/lib/types/views/parts.d.ts.map +1 -0
- package/package.json +77 -0
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
// src/locale/en-US.ts
|
|
2
|
+
var en_US_default = {
|
|
3
|
+
uiToolbar: {
|
|
4
|
+
start: "Start",
|
|
5
|
+
insert: "Insert",
|
|
6
|
+
formulas: "Formulas",
|
|
7
|
+
data: "Data",
|
|
8
|
+
view: "View",
|
|
9
|
+
others: "Others"
|
|
10
|
+
},
|
|
11
|
+
"shortcut-panel": {
|
|
12
|
+
title: "Shortcuts"
|
|
13
|
+
},
|
|
14
|
+
shortcut: {
|
|
15
|
+
undo: "Undo",
|
|
16
|
+
redo: "Redo",
|
|
17
|
+
cut: "Cut",
|
|
18
|
+
copy: "Copy",
|
|
19
|
+
paste: "Paste"
|
|
20
|
+
},
|
|
21
|
+
"common-edit": "Common Editing Shortcuts"
|
|
22
|
+
};
|
|
23
|
+
export {
|
|
24
|
+
en_US_default as default
|
|
25
|
+
};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
// src/locale/zh-CN.ts
|
|
2
|
+
var zh_CN_default = {
|
|
3
|
+
uiToolbar: {
|
|
4
|
+
start: "\u5F00\u59CB",
|
|
5
|
+
insert: "\u63D2\u5165",
|
|
6
|
+
formulas: "\u516C\u5F0F",
|
|
7
|
+
data: "\u6570\u636E",
|
|
8
|
+
view: "\u89C6\u56FE",
|
|
9
|
+
others: "\u5176\u4ED6"
|
|
10
|
+
}
|
|
11
|
+
};
|
|
12
|
+
export {
|
|
13
|
+
zh_CN_default as default
|
|
14
|
+
};
|
package/lib/index.css
ADDED
|
@@ -0,0 +1,474 @@
|
|
|
1
|
+
/* temp_stylePlugin:src/components/menu/index.module.less */
|
|
2
|
+
.univer-menu-item-no-hover {
|
|
3
|
+
background: none;
|
|
4
|
+
}
|
|
5
|
+
.univer-menu-item-content {
|
|
6
|
+
display: inline-flex;
|
|
7
|
+
gap: var(--margin-xs);
|
|
8
|
+
align-items: center;
|
|
9
|
+
}
|
|
10
|
+
.univer-menu-item-selectable {
|
|
11
|
+
position: relative;
|
|
12
|
+
padding-left: var(--padding-xl);
|
|
13
|
+
}
|
|
14
|
+
.univer-menu-item-selectable-icon {
|
|
15
|
+
position: absolute;
|
|
16
|
+
left: 0;
|
|
17
|
+
display: inline-flex;
|
|
18
|
+
align-items: center;
|
|
19
|
+
font-size: var(--font-size-lg);
|
|
20
|
+
}
|
|
21
|
+
.univer-menu-item-more-icon {
|
|
22
|
+
font-size: var(--font-size-sm);
|
|
23
|
+
color: rgb(var(--text-color));
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
/* temp_stylePlugin:src/views/app.module.less */
|
|
27
|
+
.univer-app-layout {
|
|
28
|
+
display: flex;
|
|
29
|
+
flex-direction: column;
|
|
30
|
+
height: 100%;
|
|
31
|
+
background-color: rgb(var(--bg-color));
|
|
32
|
+
}
|
|
33
|
+
.univer-app-container {
|
|
34
|
+
display: flex;
|
|
35
|
+
flex: 1;
|
|
36
|
+
flex-direction: column;
|
|
37
|
+
}
|
|
38
|
+
.univer-app-container-header {
|
|
39
|
+
position: relative;
|
|
40
|
+
z-index: 10;
|
|
41
|
+
width: 100%;
|
|
42
|
+
}
|
|
43
|
+
.univer-app-container-wrapper {
|
|
44
|
+
display: grid;
|
|
45
|
+
grid-template-columns: 1fr auto;
|
|
46
|
+
height: 100%;
|
|
47
|
+
}
|
|
48
|
+
.univer-app-container-content {
|
|
49
|
+
position: relative;
|
|
50
|
+
overflow: hidden;
|
|
51
|
+
display: grid;
|
|
52
|
+
grid-template-rows: auto 1fr;
|
|
53
|
+
flex: 1;
|
|
54
|
+
background-color: rgb(var(--bg-color-secondary));
|
|
55
|
+
border-bottom: 1px solid rgb(var(--border-color));
|
|
56
|
+
}
|
|
57
|
+
.univer-app-container-canvas {
|
|
58
|
+
position: relative;
|
|
59
|
+
}
|
|
60
|
+
.univer-app-container-sidebar {
|
|
61
|
+
height: 100%;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
/* temp_stylePlugin:src/views/components/doc-bars/index.module.less */
|
|
65
|
+
.univer-headerbar {
|
|
66
|
+
user-select: none;
|
|
67
|
+
position: relative;
|
|
68
|
+
}
|
|
69
|
+
.univer-headerbar > .univer-header-menu {
|
|
70
|
+
position: absolute;
|
|
71
|
+
top: 0;
|
|
72
|
+
right: 0;
|
|
73
|
+
display: flex;
|
|
74
|
+
box-sizing: border-box;
|
|
75
|
+
height: 100%;
|
|
76
|
+
}
|
|
77
|
+
.univer-headerbar > .univer-header-menu > div {
|
|
78
|
+
user-select: none;
|
|
79
|
+
display: inline-flex;
|
|
80
|
+
align-items: center;
|
|
81
|
+
height: 28px;
|
|
82
|
+
margin-left: 4px;
|
|
83
|
+
padding: 2px 4px;
|
|
84
|
+
text-align: center;
|
|
85
|
+
border-radius: 4px;
|
|
86
|
+
}
|
|
87
|
+
.univer-headerbar > .univer-header-menu > div:hover {
|
|
88
|
+
background-color: rgb(var(--grey-300));
|
|
89
|
+
}
|
|
90
|
+
.univer-menubar {
|
|
91
|
+
display: flex;
|
|
92
|
+
gap: var(--margin-xs);
|
|
93
|
+
align-items: center;
|
|
94
|
+
justify-content: center;
|
|
95
|
+
height: 32px;
|
|
96
|
+
}
|
|
97
|
+
.univer-menubar-item {
|
|
98
|
+
cursor: pointer;
|
|
99
|
+
display: block;
|
|
100
|
+
padding: var(--padding-xs) var(--padding-sm);
|
|
101
|
+
font-size: var(--font-size-xs);
|
|
102
|
+
font-weight: 400;
|
|
103
|
+
border-radius: var(--border-radius-base);
|
|
104
|
+
transition: all 0.1s ease-in-out;
|
|
105
|
+
}
|
|
106
|
+
.univer-menubar-item:hover:not(.univer-menubar-item-active) {
|
|
107
|
+
background: rgb(var(--grey-300));
|
|
108
|
+
}
|
|
109
|
+
.univer-menubar-item-active {
|
|
110
|
+
color: rgb(var(--color-white));
|
|
111
|
+
background: rgb(var(--primary-color));
|
|
112
|
+
}
|
|
113
|
+
.univer-toolbar {
|
|
114
|
+
user-select: none;
|
|
115
|
+
position: relative;
|
|
116
|
+
display: flex;
|
|
117
|
+
align-items: center;
|
|
118
|
+
box-sizing: border-box;
|
|
119
|
+
height: 32px;
|
|
120
|
+
padding: 0 var(--padding-xl);
|
|
121
|
+
font-size: var(--font-size-base);
|
|
122
|
+
color: rgb(var(--text-color));
|
|
123
|
+
background-color: rgb(var(--bg-color-secondary));
|
|
124
|
+
border-bottom: 1px solid rgb(var(--border-color));
|
|
125
|
+
}
|
|
126
|
+
.univer-toolbar-container {
|
|
127
|
+
display: flex;
|
|
128
|
+
gap: var(--margin-xs);
|
|
129
|
+
align-items: center;
|
|
130
|
+
justify-content: center;
|
|
131
|
+
box-sizing: border-box;
|
|
132
|
+
width: 100%;
|
|
133
|
+
height: 100%;
|
|
134
|
+
}
|
|
135
|
+
.univer-toolbar-group {
|
|
136
|
+
display: flex;
|
|
137
|
+
gap: var(--margin-xs);
|
|
138
|
+
align-items: center;
|
|
139
|
+
}
|
|
140
|
+
.univer-toolbar-group:not(:last-child)::after {
|
|
141
|
+
content: "";
|
|
142
|
+
display: block;
|
|
143
|
+
width: 1px;
|
|
144
|
+
height: 20px;
|
|
145
|
+
background-color: rgb(var(--border-color));
|
|
146
|
+
}
|
|
147
|
+
.univer-toolbar-item-select-button {
|
|
148
|
+
cursor: pointer;
|
|
149
|
+
position: relative;
|
|
150
|
+
overflow: hidden;
|
|
151
|
+
display: flex;
|
|
152
|
+
gap: var(--margin-xs);
|
|
153
|
+
align-items: center;
|
|
154
|
+
height: 24px;
|
|
155
|
+
padding-right: 18px;
|
|
156
|
+
font-size: var(--font-size-lg);
|
|
157
|
+
border-radius: var(--border-radius-base);
|
|
158
|
+
}
|
|
159
|
+
.univer-toolbar-item-select-button:hover {
|
|
160
|
+
background-color: rgb(var(--grey-100));
|
|
161
|
+
}
|
|
162
|
+
.univer-toolbar-item-select-button:hover .univer-toolbar-item-select-button-label {
|
|
163
|
+
background-color: rgb(var(--grey-100));
|
|
164
|
+
}
|
|
165
|
+
.univer-toolbar-item-select-button-label {
|
|
166
|
+
position: relative;
|
|
167
|
+
z-index: 1;
|
|
168
|
+
display: flex;
|
|
169
|
+
align-items: center;
|
|
170
|
+
height: 100%;
|
|
171
|
+
padding: 0 var(--padding-xs);
|
|
172
|
+
}
|
|
173
|
+
.univer-toolbar-item-select-button-label:hover {
|
|
174
|
+
background-color: rgb(var(--grey-300)) !important;
|
|
175
|
+
}
|
|
176
|
+
.univer-toolbar-item-select-button-arrow {
|
|
177
|
+
position: absolute;
|
|
178
|
+
top: 0;
|
|
179
|
+
left: 0;
|
|
180
|
+
display: flex;
|
|
181
|
+
align-items: center;
|
|
182
|
+
justify-content: flex-end;
|
|
183
|
+
box-sizing: border-box;
|
|
184
|
+
width: 100%;
|
|
185
|
+
height: 100%;
|
|
186
|
+
padding-right: var(--padding-xs);
|
|
187
|
+
font-size: 10px;
|
|
188
|
+
color: rgb(var(--grey-400));
|
|
189
|
+
}
|
|
190
|
+
.univer-toolbar-item-select-button-arrow:hover {
|
|
191
|
+
background-color: rgb(var(--grey-300));
|
|
192
|
+
}
|
|
193
|
+
.univer-toolbar-item-select {
|
|
194
|
+
cursor: pointer;
|
|
195
|
+
position: relative;
|
|
196
|
+
display: flex;
|
|
197
|
+
gap: var(--margin-xs);
|
|
198
|
+
align-items: center;
|
|
199
|
+
height: 24px;
|
|
200
|
+
padding: 0 var(--padding-xs);
|
|
201
|
+
font-size: var(--font-size-lg);
|
|
202
|
+
border-radius: var(--border-radius-base);
|
|
203
|
+
}
|
|
204
|
+
.univer-toolbar-item-select:hover {
|
|
205
|
+
background-color: rgb(var(--grey-100));
|
|
206
|
+
border-radius: var(--border-radius-base);
|
|
207
|
+
}
|
|
208
|
+
.univer-toolbar-item-select-arrow {
|
|
209
|
+
display: flex;
|
|
210
|
+
align-items: center;
|
|
211
|
+
height: 100%;
|
|
212
|
+
font-size: 10px;
|
|
213
|
+
color: rgb(var(--grey-400));
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
/* temp_stylePlugin:src/views/components/doc-bars/Button/index.module.less */
|
|
217
|
+
.univer-toolbar-btn {
|
|
218
|
+
cursor: pointer;
|
|
219
|
+
display: flex;
|
|
220
|
+
align-items: center;
|
|
221
|
+
justify-content: center;
|
|
222
|
+
min-width: 24px;
|
|
223
|
+
height: 24px;
|
|
224
|
+
padding: 0;
|
|
225
|
+
font-size: var(--font-size-lg);
|
|
226
|
+
color: rgb(var(--text-color));
|
|
227
|
+
background-color: transparent;
|
|
228
|
+
border: none;
|
|
229
|
+
border-radius: var(--border-radius-base);
|
|
230
|
+
outline: none;
|
|
231
|
+
}
|
|
232
|
+
.univer-toolbar-btn:not([disabled]):hover {
|
|
233
|
+
background-color: rgb(var(--grey-100));
|
|
234
|
+
}
|
|
235
|
+
.univer-toolbar-btn[disabled] {
|
|
236
|
+
cursor: not-allowed;
|
|
237
|
+
color: rgb(var(--grey-200));
|
|
238
|
+
}
|
|
239
|
+
.univer-toolbar-btn-active {
|
|
240
|
+
background-color: rgb(var(--grey-100));
|
|
241
|
+
}
|
|
242
|
+
|
|
243
|
+
/* temp_stylePlugin:src/views/components/sidebar/index.module.less */
|
|
244
|
+
.univer-sidebar {
|
|
245
|
+
position: relative;
|
|
246
|
+
transform: translateX(100%);
|
|
247
|
+
box-sizing: border-box;
|
|
248
|
+
width: 0;
|
|
249
|
+
height: 100%;
|
|
250
|
+
color: rgb(var(--text-color));
|
|
251
|
+
transition: all 0.15s;
|
|
252
|
+
}
|
|
253
|
+
.univer-sidebar.univer-sidebar-open {
|
|
254
|
+
transform: translateX(0);
|
|
255
|
+
width: 380px;
|
|
256
|
+
}
|
|
257
|
+
.univer-sidebar-container {
|
|
258
|
+
overflow-y: auto;
|
|
259
|
+
display: grid;
|
|
260
|
+
grid-template-rows: auto 1fr auto;
|
|
261
|
+
box-sizing: border-box;
|
|
262
|
+
width: 100%;
|
|
263
|
+
height: 0;
|
|
264
|
+
min-height: 100%;
|
|
265
|
+
margin: auto;
|
|
266
|
+
background-color: rgb(var(--bg-color-secondary));
|
|
267
|
+
border-bottom: 1px solid rgb(var(--border-color));
|
|
268
|
+
border-left: 1px solid rgb(var(--border-color));
|
|
269
|
+
}
|
|
270
|
+
.univer-sidebar-header {
|
|
271
|
+
position: sticky;
|
|
272
|
+
top: 0;
|
|
273
|
+
display: flex;
|
|
274
|
+
align-items: center;
|
|
275
|
+
justify-content: space-between;
|
|
276
|
+
height: 44px;
|
|
277
|
+
padding: var(--padding-xl) var(--padding-xl) 0;
|
|
278
|
+
font-size: var(--font-size-lg);
|
|
279
|
+
font-weight: 500;
|
|
280
|
+
background: rgb(var(--bg-color-secondary));
|
|
281
|
+
}
|
|
282
|
+
.univer-sidebar-header-close {
|
|
283
|
+
cursor: pointer;
|
|
284
|
+
color: rgb(var(--text-color-secondary));
|
|
285
|
+
}
|
|
286
|
+
.univer-sidebar-body {
|
|
287
|
+
padding: 0 var(--padding-xl);
|
|
288
|
+
}
|
|
289
|
+
.univer-sidebar-footer {
|
|
290
|
+
position: sticky;
|
|
291
|
+
bottom: 0;
|
|
292
|
+
padding: var(--padding-xl);
|
|
293
|
+
background: rgb(var(--bg-color-secondary));
|
|
294
|
+
}
|
|
295
|
+
|
|
296
|
+
/* temp_stylePlugin:src/components/notification/index.module.less */
|
|
297
|
+
.univer-notification {
|
|
298
|
+
position: fixed;
|
|
299
|
+
z-index: 1000;
|
|
300
|
+
display: flex;
|
|
301
|
+
flex-direction: column;
|
|
302
|
+
align-items: flex-end;
|
|
303
|
+
justify-content: center;
|
|
304
|
+
box-sizing: border-box;
|
|
305
|
+
margin: var(--margin-xs) 0;
|
|
306
|
+
}
|
|
307
|
+
.univer-notification-notice {
|
|
308
|
+
display: flex;
|
|
309
|
+
gap: var(--margin-xs);
|
|
310
|
+
justify-content: space-between;
|
|
311
|
+
width: 280px;
|
|
312
|
+
padding: var(--padding-lg);
|
|
313
|
+
font-size: var(--font-size-lg);
|
|
314
|
+
background-color: rgb(var(--color-white));
|
|
315
|
+
border-radius: var(--border-radius-base);
|
|
316
|
+
box-shadow: var(--box-shadow-lg);
|
|
317
|
+
}
|
|
318
|
+
.univer-notification-notice-wrapper {
|
|
319
|
+
margin: var(--margin-xs) var(--margin-base);
|
|
320
|
+
}
|
|
321
|
+
.univer-notification-notice-content {
|
|
322
|
+
display: inline-flex;
|
|
323
|
+
gap: var(--margin-xs);
|
|
324
|
+
align-items: center;
|
|
325
|
+
align-items: flex-start;
|
|
326
|
+
}
|
|
327
|
+
.univer-notification-notice-close {
|
|
328
|
+
cursor: pointer;
|
|
329
|
+
display: flex;
|
|
330
|
+
align-items: center;
|
|
331
|
+
justify-content: center;
|
|
332
|
+
width: fit-content;
|
|
333
|
+
height: fit-content;
|
|
334
|
+
padding: var(--padding-xs);
|
|
335
|
+
color: rgb(var(--text-color-secondary));
|
|
336
|
+
border-radius: var(--border-radius-base);
|
|
337
|
+
outline: none;
|
|
338
|
+
transition: background-color 0.2s;
|
|
339
|
+
}
|
|
340
|
+
.univer-notification-notice-close:hover {
|
|
341
|
+
background-color: rgb(var(--bg-color-hover));
|
|
342
|
+
}
|
|
343
|
+
.univer-notification-icon {
|
|
344
|
+
padding: var(--padding-xs);
|
|
345
|
+
}
|
|
346
|
+
.univer-notification-icon-success {
|
|
347
|
+
color: rgb(var(--success-color));
|
|
348
|
+
}
|
|
349
|
+
.univer-notification-icon-info {
|
|
350
|
+
color: rgb(var(--info-color));
|
|
351
|
+
}
|
|
352
|
+
.univer-notification-icon-warning {
|
|
353
|
+
color: rgb(var(--warning-color));
|
|
354
|
+
}
|
|
355
|
+
.univer-notification-icon-error {
|
|
356
|
+
color: rgb(var(--error-color));
|
|
357
|
+
}
|
|
358
|
+
.univer-notification-content-container {
|
|
359
|
+
display: inline-flex;
|
|
360
|
+
flex-direction: column;
|
|
361
|
+
gap: var(--margin-xs);
|
|
362
|
+
align-items: flex-start;
|
|
363
|
+
padding-top: var(--padding-xs);
|
|
364
|
+
}
|
|
365
|
+
.univer-notification-title {
|
|
366
|
+
color: rgb(var(--text-color));
|
|
367
|
+
}
|
|
368
|
+
.univer-notification-content {
|
|
369
|
+
color: rgb(var(--text-color-secondary));
|
|
370
|
+
}
|
|
371
|
+
.univer-notification-content-ellipsis {
|
|
372
|
+
overflow: hidden;
|
|
373
|
+
display: -webkit-box;
|
|
374
|
+
text-overflow: ellipsis;
|
|
375
|
+
-webkit-box-orient: vertical;
|
|
376
|
+
}
|
|
377
|
+
.univer-notification-top,
|
|
378
|
+
.univer-notification-topLeft,
|
|
379
|
+
.univer-notification-topRight {
|
|
380
|
+
top: 0;
|
|
381
|
+
}
|
|
382
|
+
.univer-notification-bottom,
|
|
383
|
+
.univer-notification-bottomRight,
|
|
384
|
+
.univer-notification-bottomLeft {
|
|
385
|
+
bottom: 0;
|
|
386
|
+
}
|
|
387
|
+
.univer-notification-bottomRight,
|
|
388
|
+
.univer-notification-topRight {
|
|
389
|
+
right: 0;
|
|
390
|
+
}
|
|
391
|
+
.univer-notification-fade {
|
|
392
|
+
overflow: hidden;
|
|
393
|
+
transition: all 0.3s;
|
|
394
|
+
}
|
|
395
|
+
.univer-notification-fade-appear-prepare {
|
|
396
|
+
opacity: 0;
|
|
397
|
+
}
|
|
398
|
+
.univer-notification-fade-appear-start {
|
|
399
|
+
transform: translateX(100%);
|
|
400
|
+
opacity: 0;
|
|
401
|
+
}
|
|
402
|
+
.univer-notification-fade-appear-active {
|
|
403
|
+
transform: translateX(0);
|
|
404
|
+
opacity: 1;
|
|
405
|
+
}
|
|
406
|
+
.univer-notification-fade-appear,
|
|
407
|
+
.univer-notification-fade-enter {
|
|
408
|
+
opacity: 0;
|
|
409
|
+
animation-play-state: paused;
|
|
410
|
+
animation-duration: 0.3s;
|
|
411
|
+
animation-timing-function: cubic-bezier(0.55, 0, 0.55, 0.2);
|
|
412
|
+
animation-fill-mode: both;
|
|
413
|
+
}
|
|
414
|
+
.univer-notification-fade-leave {
|
|
415
|
+
animation-duration: 0.3s;
|
|
416
|
+
animation-timing-function: cubic-bezier(0.55, 0, 0.55, 0.2);
|
|
417
|
+
animation-fill-mode: both;
|
|
418
|
+
animation-play-state: paused;
|
|
419
|
+
}
|
|
420
|
+
.univer-notification-fade-appear.univer-notification-fade-appear-active,
|
|
421
|
+
.univer-notification-fade-enter.univer-notification-fade-enter-active {
|
|
422
|
+
animation-name: univer-notification-fade-in;
|
|
423
|
+
animation-play-state: running;
|
|
424
|
+
}
|
|
425
|
+
.univer-notification-fade-leave.univer-notification-fade-leave-active {
|
|
426
|
+
animation-name: univer-notification-fade-out;
|
|
427
|
+
animation-play-state: running;
|
|
428
|
+
}
|
|
429
|
+
@keyframes univer-notification-fade-in {
|
|
430
|
+
0% {
|
|
431
|
+
opacity: 0;
|
|
432
|
+
}
|
|
433
|
+
100% {
|
|
434
|
+
opacity: 1;
|
|
435
|
+
}
|
|
436
|
+
}
|
|
437
|
+
@keyframes univer-notification-fade-out {
|
|
438
|
+
0% {
|
|
439
|
+
opacity: 1;
|
|
440
|
+
}
|
|
441
|
+
100% {
|
|
442
|
+
opacity: 0;
|
|
443
|
+
}
|
|
444
|
+
}
|
|
445
|
+
|
|
446
|
+
/* temp_stylePlugin:src/views/components/shortcut-panel/index.module.less */
|
|
447
|
+
.univer-shortcut-panel-group-title {
|
|
448
|
+
height: 40px;
|
|
449
|
+
font-size: 13px;
|
|
450
|
+
font-weight: 700;
|
|
451
|
+
line-height: 40px;
|
|
452
|
+
}
|
|
453
|
+
.univer-shortcut-panel-item {
|
|
454
|
+
display: flex;
|
|
455
|
+
justify-content: space-between;
|
|
456
|
+
height: 40px;
|
|
457
|
+
font-size: 13px;
|
|
458
|
+
line-height: 40px;
|
|
459
|
+
}
|
|
460
|
+
.univer-shortcut-panel-item-title {
|
|
461
|
+
overflow: hidden;
|
|
462
|
+
flex-grow: 1;
|
|
463
|
+
flex-shrink: 1;
|
|
464
|
+
max-width: 200px;
|
|
465
|
+
text-overflow: ellipsis;
|
|
466
|
+
text-wrap: nowrap;
|
|
467
|
+
}
|
|
468
|
+
.univer-shortcut-panel-item-shortcut {
|
|
469
|
+
flex-grow: 0;
|
|
470
|
+
flex-shrink: 0;
|
|
471
|
+
}
|
|
472
|
+
.univer-shortcut-panel-item:not(:last-of-type) {
|
|
473
|
+
border-bottom: 1px solid rgb(var(--grey-200));
|
|
474
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"BaseComponent.d.ts","sourceRoot":"","sources":["../../src/BaseComponent.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,WAAW,kBAAkB;IAC/B,YAAY,CAAC,EAAE,CAAC,GAAG,EAAE,GAAG,KAAK,IAAI,CAAC;IAClC,EAAE,CAAC,EAAE,MAAM,CAAC;CACf"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"toggle-shortcut-panel.operation.d.ts","sourceRoot":"","sources":["../../../../src/commands/operations/toggle-shortcut-panel.operation.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAOjD,eAAO,MAAM,0BAA0B,kBAAkB,CAAC;AAE1D,eAAO,MAAM,4BAA4B,EAAE,UAsB1C,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { IDisposable } from '@wendellhu/redi';
|
|
2
|
+
export interface ICustomComponent {
|
|
3
|
+
name: string;
|
|
4
|
+
props?: any;
|
|
5
|
+
}
|
|
6
|
+
export type ComponentList = Map<string, React.ForwardRefExoticComponent<any>>;
|
|
7
|
+
export declare class ComponentManager {
|
|
8
|
+
private _components;
|
|
9
|
+
constructor();
|
|
10
|
+
register(name: string, component: any): IDisposable;
|
|
11
|
+
get(name: string): import("react").ForwardRefExoticComponent<any> | undefined;
|
|
12
|
+
delete(name: string): void;
|
|
13
|
+
}
|
|
14
|
+
//# sourceMappingURL=component-manager.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"component-manager.d.ts","sourceRoot":"","sources":["../../../src/common/component-manager.ts"],"names":[],"mappings":"AA0EA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAEnD,MAAM,WAAW,gBAAgB;IAC7B,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,CAAC,EAAE,GAAG,CAAC;CACf;AAED,MAAM,MAAM,aAAa,GAAG,GAAG,CAAC,MAAM,EAAE,KAAK,CAAC,yBAAyB,CAAC,GAAG,CAAC,CAAC,CAAC;AAE9E,qBAAa,gBAAgB;IACzB,OAAO,CAAC,WAAW,CAA4B;;IAkF/C,QAAQ,CAAC,IAAI,EAAE,MAAM,EAAE,SAAS,EAAE,GAAG,GAAG,WAAW;IASnD,GAAG,CAAC,IAAI,EAAE,MAAM;IAIhB,MAAM,CAAC,IAAI,EAAE,MAAM;CAGtB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/common/index.ts"],"names":[],"mappings":"AAAA,cAAc,qBAAqB,CAAC;AACpC,cAAc,mBAAmB,CAAC"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { IDisposable } from '@wendellhu/redi';
|
|
2
|
+
export declare function fromDocumentEvent<K extends keyof DocumentEventMap>(type: K, listener: (this: Document, ev: DocumentEventMap[K]) => any, options?: boolean | AddEventListenerOptions): IDisposable;
|
|
3
|
+
export declare function fromEvent<K extends keyof HTMLElementEventMap>(target: HTMLElement, type: K, listener: (this: HTMLElement, ev: HTMLElementEventMap[K]) => any, options?: boolean | AddEventListenerOptions): IDisposable;
|
|
4
|
+
//# sourceMappingURL=lifecycle.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"lifecycle.d.ts","sourceRoot":"","sources":["../../../src/common/lifecycle.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAEnD,wBAAgB,iBAAiB,CAAC,CAAC,SAAS,MAAM,gBAAgB,EAC9D,IAAI,EAAE,CAAC,EAEP,QAAQ,EAAE,CAAC,IAAI,EAAE,QAAQ,EAAE,EAAE,EAAE,gBAAgB,CAAC,CAAC,CAAC,KAAK,GAAG,EAC1D,OAAO,CAAC,EAAE,OAAO,GAAG,uBAAuB,GAC5C,WAAW,CAGb;AAED,wBAAgB,SAAS,CAAC,CAAC,SAAS,MAAM,mBAAmB,EACzD,MAAM,EAAE,WAAW,EACnB,IAAI,EAAE,CAAC,EAEP,QAAQ,EAAE,CAAC,IAAI,EAAE,WAAW,EAAE,EAAE,EAAE,mBAAmB,CAAC,CAAC,CAAC,KAAK,GAAG,EAChE,OAAO,CAAC,EAAE,OAAO,GAAG,uBAAuB,GAC5C,WAAW,CAGb"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"z-index-manager.d.ts","sourceRoot":"","sources":["../../../src/common/z-index-manager.ts"],"names":[],"mappings":"AAAA,qBAAa,aAAa;IACtB,OAAO,CAAC,KAAK,CAAkC;IAE/C,QAAQ,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM;IAIpC,QAAQ,CAAC,IAAI,EAAE,MAAM;IAIrB,WAAW,CAAC,IAAI,EAAE,MAAM;IAIxB,WAAW;CASd"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { Observable } from 'rxjs';
|
|
2
|
+
import type { IMenuSelectorItem } from '../../services/menu/menu';
|
|
3
|
+
export type ICustomLabelProps<T = undefined> = {
|
|
4
|
+
value?: string | number | undefined;
|
|
5
|
+
value$?: Observable<T>;
|
|
6
|
+
onChange?(v: string | number): void;
|
|
7
|
+
} & Pick<IMenuSelectorItem<unknown>, 'label' | 'icon' | 'title'>;
|
|
8
|
+
/**
|
|
9
|
+
* The component to render toolbar item label and menu item label.
|
|
10
|
+
* @param props
|
|
11
|
+
* @returns
|
|
12
|
+
*/
|
|
13
|
+
export declare function CustomLabel(props: ICustomLabelProps): JSX.Element | null;
|
|
14
|
+
//# sourceMappingURL=CustomLabel.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CustomLabel.d.ts","sourceRoot":"","sources":["../../../../src/components/custom-label/CustomLabel.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,MAAM,CAAC;AAIvC,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,0BAA0B,CAAC;AAGlE,MAAM,MAAM,iBAAiB,CAAC,CAAC,GAAG,SAAS,IAAI;IAC3C,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,CAAC;IAEpC,MAAM,CAAC,EAAE,UAAU,CAAC,CAAC,CAAC,CAAC;IAEvB,QAAQ,CAAC,CAAC,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI,CAAC;CACvC,GAAG,IAAI,CAAC,iBAAiB,CAAC,OAAO,CAAC,EAAE,OAAO,GAAG,MAAM,GAAG,OAAO,CAAC,CAAC;AAEjE;;;;GAIG;AACH,wBAAgB,WAAW,CAAC,KAAK,EAAE,iBAAiB,GAAG,GAAG,CAAC,OAAO,GAAG,IAAI,CAiDxE"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/custom-label/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAC"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { Observable } from 'rxjs';
|
|
2
|
+
export declare function useObservable<T>(observable: Observable<T>, defaultValue?: T): T | undefined;
|
|
3
|
+
export declare function useObservable<T>(observable: Observable<T>, defaultValue?: T, shouldHaveSyncValue?: true): T;
|
|
4
|
+
//# sourceMappingURL=observable.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"observable.d.ts","sourceRoot":"","sources":["../../../../src/components/hooks/observable.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,UAAU,EAAgB,MAAM,MAAM,CAAC;AAErD,wBAAgB,aAAa,CAAC,CAAC,EAAE,UAAU,EAAE,UAAU,CAAC,CAAC,CAAC,EAAE,YAAY,CAAC,EAAE,CAAC,GAAG,CAAC,GAAG,SAAS,CAAC;AAC7F,wBAAgB,aAAa,CAAC,CAAC,EAAE,UAAU,EAAE,UAAU,CAAC,CAAC,CAAC,EAAE,YAAY,CAAC,EAAE,CAAC,EAAE,mBAAmB,CAAC,EAAE,IAAI,GAAG,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/index.ts"],"names":[],"mappings":"AAAA,cAAc,gBAAgB,CAAC;AAC/B,cAAc,QAAQ,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { IValueOption } from '../../services/menu/menu';
|
|
3
|
+
export interface IBaseMenuProps {
|
|
4
|
+
parentKey?: string | number;
|
|
5
|
+
menuType?: string | string[];
|
|
6
|
+
value?: string | number;
|
|
7
|
+
options?: IValueOption[];
|
|
8
|
+
onOptionSelect?: (option: IValueOption) => void;
|
|
9
|
+
}
|
|
10
|
+
export declare const Menu: (props: IBaseMenuProps) => React.JSX.Element;
|
|
11
|
+
//# sourceMappingURL=Menu.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Menu.d.ts","sourceRoot":"","sources":["../../../../src/components/menu/Menu.tsx"],"names":[],"mappings":"AAUA,OAAO,KAAmB,MAAM,OAAO,CAAC;AAGxC,OAAO,KAAK,EAKR,YAAY,EAEf,MAAM,0BAA0B,CAAC;AASlC,MAAM,WAAW,cAAc;IAC3B,SAAS,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAC5B,QAAQ,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;IAE7B,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IACxB,OAAO,CAAC,EAAE,YAAY,EAAE,CAAC;IAEzB,cAAc,CAAC,EAAE,CAAC,MAAM,EAAE,YAAY,KAAK,IAAI,CAAC;CACnD;AAgHD,eAAO,MAAM,IAAI,UAAW,cAAc,sBAKzC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/menu/index.ts"],"names":[],"mappings":"AAAA,cAAc,QAAQ,CAAC"}
|