gbflowengine 0.0.0-stage → 0.1.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/LICENSE +21 -0
- package/README.md +271 -3
- package/dist/gbflowengine.css +1 -0
- package/dist/gbflowengine.js +18363 -0
- package/dist/gbflowengine.js.map +1 -0
- package/dist/gbflowengine.umd.cjs +5 -0
- package/dist/gbflowengine.umd.cjs.map +1 -0
- package/package.json +84 -6
- package/src/center/DefinitionInspect.vue +291 -0
- package/src/center/FlowCenter.vue +33 -0
- package/src/center/index.js +29 -0
- package/src/center/storage.js +748 -0
- package/src/core/flow/condition.js +160 -0
- package/src/core/flow/customNode.js +385 -0
- package/src/core/flow/defaults.js +124 -0
- package/src/core/flow/flowConstant.js +265 -0
- package/src/core/flow/flowNodeUtils.js +30 -0
- package/src/core/flow/index.js +47 -0
- package/src/core/flow/node.js +44 -0
- package/src/core/flow/nodeFactory.js +58 -0
- package/src/core/flow/prediction.js +325 -0
- package/src/core/flow/runtime/auto.js +83 -0
- package/src/core/flow/runtime/decide.js +329 -0
- package/src/core/flow/runtime/event.js +28 -0
- package/src/core/flow/runtime/execute.js +357 -0
- package/src/core/flow/runtime/helpers.js +52 -0
- package/src/core/flow/runtime/query.js +146 -0
- package/src/core/flow/runtime/reject.js +137 -0
- package/src/core/flow/runtime/token.js +269 -0
- package/src/core/flow/runtime.js +129 -0
- package/src/core/flow/schema.js +864 -0
- package/src/definition/FlowDefinitionDesigner.vue +338 -0
- package/src/definition/index.js +9 -0
- package/src/index.js +39 -0
- package/src/storage.js +200 -0
- package/src/testing/FlowTestPanel.vue +2502 -0
- package/src/testing/UserConfigDrawer.vue +376 -0
- package/src/testing/diagram/FlowProgressDiagram.vue +318 -0
- package/src/testing/diagramModel.js +517 -0
- package/src/testing/index.js +23 -0
- package/src/testing/mock.js +246 -0
- package/src/testing/oaExecutors.js +51 -0
- package/src/testing/oaSeed.js +467 -0
- package/src/testing/sample.js +412 -0
- package/src/testing/seed.js +122 -0
- package/src/utils/format.js +27 -0
- package/src/visual/FlowCanvas.vue +441 -0
- package/src/visual/NodeProgressDetail.vue +43 -0
- package/src/visual/NodeStatusBadge.vue +17 -0
- package/src/visual/NodeWrap.vue +47 -0
- package/src/visual/ScWorkflow.vue +50 -0
- package/src/visual/SelectDialog.vue +460 -0
- package/src/visual/conditionHelpers.js +117 -0
- package/src/visual/index.js +6 -0
- package/src/visual/nodes/AddNode.vue +223 -0
- package/src/visual/nodes/ApproverNode.vue +348 -0
- package/src/visual/nodes/BranchNode.vue +442 -0
- package/src/visual/nodes/CustomNode.vue +339 -0
- package/src/visual/nodes/EndNode.vue +22 -0
- package/src/visual/nodes/PassNode.vue +101 -0
- package/src/visual/nodes/PromoterNode.vue +135 -0
- package/src/visual/nodes/RejectNode.vue +101 -0
- package/src/visual/nodes/SendNode.vue +152 -0
- package/src/visual/styles.scss +879 -0
- package/src/visual/useScNodeStatus.js +18 -0
- package/src/workbench/OaWorkbench.vue +1341 -0
- package/src/workbench/components/ApprovalWorkspace.vue +2090 -0
- package/src/workbench/components/CategoryIcon.vue +74 -0
- package/src/workbench/components/NotificationIcon.vue +73 -0
- package/src/workbench/components/ProcessSteps.vue +557 -0
- package/src/workbench/components/ResubmitDialog.vue +227 -0
- package/src/workbench/components/SidebarNav.vue +138 -0
- package/src/workbench/components/StartFlowDialog.vue +1058 -0
- package/src/workbench/components/UserAvatar.vue +68 -0
- package/src/workbench/custom-tasks.js +130 -0
- package/src/workbench/model.js +1080 -0
- package/src/workbench/pages/DesignPage.vue +798 -0
- package/src/workbench/pages/HomePage.vue +1050 -0
- package/src/workbench/pages/MonitorPage.vue +1029 -0
- package/src/workbench/pages/NotificationsPage.vue +554 -0
- package/src/workbench/pages/RequestsPage.vue +644 -0
- package/src/workbench/pages/TaskCenterPage.vue +1155 -0
- package/src/workbench/pages/TemplatesPage.vue +680 -0
- package/src/workbench/persistence.js +89 -0
- package/src/workbench/shared.js +18 -0
- package/src/workbench/styles.scss +555 -0
- package/src/workbench/useWorkbench.js +955 -0
- package/types/center.d.ts +5 -0
- package/types/core.d.ts +479 -0
- package/types/definition.d.ts +4 -0
- package/types/index.d.ts +34 -0
- package/types/testing.d.ts +20 -0
- package/types/visual.d.ts +20 -0
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
// [文件] gbflowengine·workbench·persistence —— 本地持久化 —— 实例快照与界面偏好的读取、防抖落盘
|
|
2
|
+
//
|
|
3
|
+
// [设计] 从 useWorkbench 拆出的职责块,接收一个 ctx(refs + state + 兄弟函数),把隐式闭包改成显式依赖:
|
|
4
|
+
// 仍是同一份响应式对象、同一个 state,行为不变。
|
|
5
|
+
// ctx 里的函数只在调用时解析,所以装配顺序无关(Object.assign 早于任何生命周期回调)。
|
|
6
|
+
|
|
7
|
+
import { loadDefinitions } from '../center/storage.js'
|
|
8
|
+
import { flowStorage } from '../storage.js'
|
|
9
|
+
import { INSTANCE_STORAGE_KEY, UI_STORAGE_KEY, isValidInstance } from './shared.js'
|
|
10
|
+
|
|
11
|
+
export function createPersistence(ctx) {
|
|
12
|
+
function schedulePersist() {
|
|
13
|
+
if (!ctx.storageReady.value) return
|
|
14
|
+
if (ctx.lifecycle.persistTimer) clearTimeout(ctx.lifecycle.persistTimer)
|
|
15
|
+
ctx.lifecycle.persistTimer = setTimeout(() => {
|
|
16
|
+
ctx.lifecycle.persistTimer = null
|
|
17
|
+
ctx.persistNow()
|
|
18
|
+
}, 120)
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
async function persistNow() {
|
|
22
|
+
if (!ctx.storageReady.value) return
|
|
23
|
+
try {
|
|
24
|
+
await flowStorage.setJSON(INSTANCE_STORAGE_KEY, {
|
|
25
|
+
instances: ctx.instances.value,
|
|
26
|
+
currentUserId: ctx.currentUserId.value,
|
|
27
|
+
updatedAt: new Date().toISOString()
|
|
28
|
+
})
|
|
29
|
+
} catch {
|
|
30
|
+
// 本地存储不可用时保持内存态可用
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
function scheduleUiPersist() {
|
|
35
|
+
if (!ctx.storageReady.value) return
|
|
36
|
+
if (ctx.lifecycle.uiPersistTimer) clearTimeout(ctx.lifecycle.uiPersistTimer)
|
|
37
|
+
ctx.lifecycle.uiPersistTimer = setTimeout(() => {
|
|
38
|
+
ctx.lifecycle.uiPersistTimer = null
|
|
39
|
+
flowStorage
|
|
40
|
+
.setJSON(UI_STORAGE_KEY, {
|
|
41
|
+
readNotificationIds: ctx.readNotificationIds.value,
|
|
42
|
+
favorites: ctx.favorites.value,
|
|
43
|
+
drafts: ctx.drafts.value,
|
|
44
|
+
savedViews: ctx.savedViews.value,
|
|
45
|
+
adminLogs: ctx.adminLogs.value
|
|
46
|
+
})
|
|
47
|
+
.catch(() => {})
|
|
48
|
+
}, 160)
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
async function hydrate() {
|
|
52
|
+
ctx.lifecycle.hydrating = true
|
|
53
|
+
try {
|
|
54
|
+
const [loadedDefinitions, stored, storedUi] = await Promise.all([
|
|
55
|
+
loadDefinitions(),
|
|
56
|
+
flowStorage.getJSON(INSTANCE_STORAGE_KEY),
|
|
57
|
+
flowStorage.getJSON(UI_STORAGE_KEY)
|
|
58
|
+
])
|
|
59
|
+
ctx.definitions.value = loadedDefinitions
|
|
60
|
+
if (stored && Array.isArray(stored.instances)) {
|
|
61
|
+
ctx.instances.value = stored.instances.filter(isValidInstance)
|
|
62
|
+
if (stored.currentUserId != null && ctx.userIndex.value.has(String(stored.currentUserId))) {
|
|
63
|
+
ctx.currentUserId.value = stored.currentUserId
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
if (storedUi && typeof storedUi === 'object') {
|
|
67
|
+
ctx.readNotificationIds.value = Array.isArray(storedUi.readNotificationIds)
|
|
68
|
+
? storedUi.readNotificationIds
|
|
69
|
+
: []
|
|
70
|
+
ctx.favorites.value = Array.isArray(storedUi.favorites) ? storedUi.favorites : []
|
|
71
|
+
ctx.drafts.value = storedUi.drafts && typeof storedUi.drafts === 'object' ? storedUi.drafts : {}
|
|
72
|
+
ctx.savedViews.value = Array.isArray(storedUi.savedViews) ? storedUi.savedViews : []
|
|
73
|
+
ctx.adminLogs.value = Array.isArray(storedUi.adminLogs) ? storedUi.adminLogs : []
|
|
74
|
+
}
|
|
75
|
+
} catch {
|
|
76
|
+
// 存储损坏时从演示数据继续
|
|
77
|
+
} finally {
|
|
78
|
+
ctx.lifecycle.hydrating = false
|
|
79
|
+
ctx.storageReady.value = true
|
|
80
|
+
ctx.ready.value = true
|
|
81
|
+
ctx.tickAllInstances()
|
|
82
|
+
await ctx.persistNow()
|
|
83
|
+
ctx.scheduleUiPersist()
|
|
84
|
+
ctx.scheduleCustomSweep(0)
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
return { schedulePersist, persistNow, scheduleUiPersist, hydrate }
|
|
89
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
// [文件] gbflowengine·workbench·shared —— 应用级常量与纯工具(无闭包依赖,useWorkbench 与各职责模块共用)
|
|
2
|
+
|
|
3
|
+
/** 实例快照的存储键 */
|
|
4
|
+
export const INSTANCE_STORAGE_KEY = 'gb-flowengine-oa-v2'
|
|
5
|
+
/** 界面偏好(已读通知/收藏/草稿/视图/审计)的存储键 */
|
|
6
|
+
export const UI_STORAGE_KEY = 'gb-flowengine-oa-ui-v1'
|
|
7
|
+
|
|
8
|
+
export const clone = (value) => JSON.parse(JSON.stringify(value))
|
|
9
|
+
|
|
10
|
+
/** 存储里读回的实例必须结构完整才收:缺 workflow 或 state 的条目会让运行时整个炸掉 */
|
|
11
|
+
export function isValidInstance(instance) {
|
|
12
|
+
return Boolean(
|
|
13
|
+
instance?.id &&
|
|
14
|
+
instance?.definition?.workflow &&
|
|
15
|
+
instance?.state?.tasks &&
|
|
16
|
+
instance?.state?.status
|
|
17
|
+
)
|
|
18
|
+
}
|
|
@@ -0,0 +1,555 @@
|
|
|
1
|
+
.oa-shell {
|
|
2
|
+
--oa-bg: #f3f5f9;
|
|
3
|
+
--oa-surface: #ffffff;
|
|
4
|
+
--oa-surface-soft: #f8fafc;
|
|
5
|
+
--oa-ink: #18243a;
|
|
6
|
+
--oa-ink-strong: #0d1728;
|
|
7
|
+
--oa-muted: #68758a;
|
|
8
|
+
--oa-faint: #97a2b4;
|
|
9
|
+
--oa-line: #e4e9f1;
|
|
10
|
+
--oa-line-strong: #d5dce8;
|
|
11
|
+
--oa-primary: #2456d6;
|
|
12
|
+
--oa-primary-dark: #1b44ad;
|
|
13
|
+
--oa-primary-soft: #edf2ff;
|
|
14
|
+
--oa-sidebar: #0e1f33;
|
|
15
|
+
--oa-sidebar-text: #c9d5e5;
|
|
16
|
+
--oa-success: #0d8057;
|
|
17
|
+
--oa-success-soft: #e9f7f0;
|
|
18
|
+
--oa-warning: #aa6a12;
|
|
19
|
+
--oa-warning-soft: #fff5e3;
|
|
20
|
+
--oa-danger: #c23b32;
|
|
21
|
+
--oa-danger-soft: #fdf0ee;
|
|
22
|
+
--oa-radius: 10px;
|
|
23
|
+
--oa-shadow: 0 1px 2px rgba(15, 31, 55, 0.04), 0 6px 20px rgba(15, 31, 55, 0.04);
|
|
24
|
+
--el-color-primary: #2456d6;
|
|
25
|
+
--el-color-primary-light-3: #5279df;
|
|
26
|
+
--el-color-primary-light-5: #8aa4ea;
|
|
27
|
+
--el-color-primary-light-7: #bfcef3;
|
|
28
|
+
--el-color-primary-light-8: #d8e2f8;
|
|
29
|
+
--el-color-primary-light-9: #edf2ff;
|
|
30
|
+
--el-color-success: #0d8057;
|
|
31
|
+
--el-color-warning: #aa6a12;
|
|
32
|
+
--el-color-danger: #c23b32;
|
|
33
|
+
--el-border-radius-base: 7px;
|
|
34
|
+
--el-border-color: #e4e9f1;
|
|
35
|
+
--el-border-color-light: #ebeff6;
|
|
36
|
+
--el-text-color-primary: #18243a;
|
|
37
|
+
--el-text-color-regular: #4c5a70;
|
|
38
|
+
--el-text-color-secondary: #7e8b9f;
|
|
39
|
+
position: relative;
|
|
40
|
+
display: flex;
|
|
41
|
+
width: 100%;
|
|
42
|
+
height: 100%;
|
|
43
|
+
min-height: 0;
|
|
44
|
+
overflow: hidden;
|
|
45
|
+
background: var(--oa-bg);
|
|
46
|
+
color: var(--oa-ink);
|
|
47
|
+
font-family: 'Inter', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', system-ui,
|
|
48
|
+
-apple-system, 'Segoe UI', sans-serif;
|
|
49
|
+
font-size: 13px;
|
|
50
|
+
line-height: 1.55;
|
|
51
|
+
-webkit-font-smoothing: antialiased;
|
|
52
|
+
|
|
53
|
+
*,
|
|
54
|
+
*::before,
|
|
55
|
+
*::after {
|
|
56
|
+
box-sizing: border-box;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
button,
|
|
60
|
+
input,
|
|
61
|
+
textarea,
|
|
62
|
+
select {
|
|
63
|
+
font-family: inherit;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
::selection {
|
|
67
|
+
background: rgba(36, 86, 214, 0.16);
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
:focus-visible {
|
|
71
|
+
outline: 2px solid rgba(36, 86, 214, 0.6);
|
|
72
|
+
outline-offset: 2px;
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
::-webkit-scrollbar {
|
|
76
|
+
width: 8px;
|
|
77
|
+
height: 8px;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
::-webkit-scrollbar-thumb {
|
|
81
|
+
border: 2px solid transparent;
|
|
82
|
+
border-radius: 8px;
|
|
83
|
+
background: #c7d1e0;
|
|
84
|
+
background-clip: padding-box;
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
::-webkit-scrollbar-thumb:hover {
|
|
88
|
+
background: #aebacd;
|
|
89
|
+
background-clip: padding-box;
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
.oa-card {
|
|
94
|
+
background: var(--oa-surface);
|
|
95
|
+
border: 1px solid var(--oa-line);
|
|
96
|
+
border-radius: var(--oa-radius);
|
|
97
|
+
box-shadow: var(--oa-shadow);
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
.oa-page {
|
|
101
|
+
display: flex;
|
|
102
|
+
flex-direction: column;
|
|
103
|
+
gap: 16px;
|
|
104
|
+
min-height: 100%;
|
|
105
|
+
padding: 22px 26px 30px;
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
.oa-page-head {
|
|
109
|
+
display: flex;
|
|
110
|
+
align-items: flex-start;
|
|
111
|
+
justify-content: space-between;
|
|
112
|
+
gap: 20px;
|
|
113
|
+
flex-wrap: wrap;
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
.oa-page-head__main {
|
|
117
|
+
min-width: 0;
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
.oa-eyebrow {
|
|
121
|
+
display: flex;
|
|
122
|
+
align-items: center;
|
|
123
|
+
gap: 6px;
|
|
124
|
+
margin: 0 0 4px;
|
|
125
|
+
color: var(--oa-faint);
|
|
126
|
+
font-size: 11px;
|
|
127
|
+
font-weight: 600;
|
|
128
|
+
letter-spacing: 0.08em;
|
|
129
|
+
text-transform: uppercase;
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
.oa-title {
|
|
133
|
+
margin: 0;
|
|
134
|
+
color: var(--oa-ink-strong);
|
|
135
|
+
font-size: 22px;
|
|
136
|
+
font-weight: 650;
|
|
137
|
+
letter-spacing: -0.02em;
|
|
138
|
+
line-height: 1.3;
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
.oa-title--sm {
|
|
142
|
+
font-size: 17px;
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
.oa-subtitle {
|
|
146
|
+
margin: 5px 0 0;
|
|
147
|
+
color: var(--oa-muted);
|
|
148
|
+
font-size: 13px;
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
.oa-section-head {
|
|
152
|
+
display: flex;
|
|
153
|
+
align-items: center;
|
|
154
|
+
justify-content: space-between;
|
|
155
|
+
gap: 12px;
|
|
156
|
+
padding: 16px 18px 12px;
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
.oa-section-head__title {
|
|
160
|
+
display: flex;
|
|
161
|
+
align-items: center;
|
|
162
|
+
gap: 9px;
|
|
163
|
+
min-width: 0;
|
|
164
|
+
margin: 0;
|
|
165
|
+
color: var(--oa-ink);
|
|
166
|
+
font-size: 14px;
|
|
167
|
+
font-weight: 650;
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
.oa-section-head__title small {
|
|
171
|
+
color: var(--oa-faint);
|
|
172
|
+
font-size: 12px;
|
|
173
|
+
font-weight: 450;
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
.oa-muted {
|
|
177
|
+
color: var(--oa-muted);
|
|
178
|
+
}
|
|
179
|
+
|
|
180
|
+
.oa-faint {
|
|
181
|
+
color: var(--oa-faint);
|
|
182
|
+
}
|
|
183
|
+
|
|
184
|
+
.oa-num {
|
|
185
|
+
font-variant-numeric: tabular-nums;
|
|
186
|
+
font-feature-settings: 'tnum';
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
.oa-actions {
|
|
190
|
+
display: flex;
|
|
191
|
+
align-items: center;
|
|
192
|
+
gap: 8px;
|
|
193
|
+
flex-wrap: wrap;
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
.oa-chip {
|
|
197
|
+
display: inline-flex;
|
|
198
|
+
align-items: center;
|
|
199
|
+
gap: 4px;
|
|
200
|
+
min-height: 22px;
|
|
201
|
+
padding: 1px 8px;
|
|
202
|
+
border: 1px solid var(--oa-line);
|
|
203
|
+
border-radius: 999px;
|
|
204
|
+
background: var(--oa-surface-soft);
|
|
205
|
+
color: var(--oa-muted);
|
|
206
|
+
font-size: 11px;
|
|
207
|
+
font-weight: 500;
|
|
208
|
+
white-space: nowrap;
|
|
209
|
+
}
|
|
210
|
+
|
|
211
|
+
.oa-chip--primary {
|
|
212
|
+
border-color: #cddbfb;
|
|
213
|
+
background: var(--oa-primary-soft);
|
|
214
|
+
color: var(--oa-primary);
|
|
215
|
+
}
|
|
216
|
+
|
|
217
|
+
.oa-chip--danger {
|
|
218
|
+
border-color: #f3cfcb;
|
|
219
|
+
background: var(--oa-danger-soft);
|
|
220
|
+
color: var(--oa-danger);
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
.oa-chip--warning {
|
|
224
|
+
border-color: #f3dfbe;
|
|
225
|
+
background: var(--oa-warning-soft);
|
|
226
|
+
color: var(--oa-warning);
|
|
227
|
+
}
|
|
228
|
+
|
|
229
|
+
.oa-chip--success {
|
|
230
|
+
border-color: #c7e8d8;
|
|
231
|
+
background: var(--oa-success-soft);
|
|
232
|
+
color: var(--oa-success);
|
|
233
|
+
}
|
|
234
|
+
|
|
235
|
+
.oa-status {
|
|
236
|
+
display: inline-flex;
|
|
237
|
+
align-items: center;
|
|
238
|
+
gap: 5px;
|
|
239
|
+
min-height: 22px;
|
|
240
|
+
padding: 1px 8px;
|
|
241
|
+
border-radius: 5px;
|
|
242
|
+
font-size: 11px;
|
|
243
|
+
font-weight: 600;
|
|
244
|
+
white-space: nowrap;
|
|
245
|
+
}
|
|
246
|
+
|
|
247
|
+
.oa-status::before {
|
|
248
|
+
content: '';
|
|
249
|
+
width: 5px;
|
|
250
|
+
height: 5px;
|
|
251
|
+
border-radius: 50%;
|
|
252
|
+
background: currentColor;
|
|
253
|
+
opacity: 0.8;
|
|
254
|
+
}
|
|
255
|
+
|
|
256
|
+
.oa-status--neutral {
|
|
257
|
+
background: #f0f3f8;
|
|
258
|
+
color: #5f6c80;
|
|
259
|
+
}
|
|
260
|
+
|
|
261
|
+
.oa-status--info {
|
|
262
|
+
background: var(--oa-primary-soft);
|
|
263
|
+
color: var(--oa-primary);
|
|
264
|
+
}
|
|
265
|
+
|
|
266
|
+
.oa-status--success {
|
|
267
|
+
background: var(--oa-success-soft);
|
|
268
|
+
color: var(--oa-success);
|
|
269
|
+
}
|
|
270
|
+
|
|
271
|
+
.oa-status--warning {
|
|
272
|
+
background: var(--oa-warning-soft);
|
|
273
|
+
color: var(--oa-warning);
|
|
274
|
+
}
|
|
275
|
+
|
|
276
|
+
.oa-status--danger {
|
|
277
|
+
background: var(--oa-danger-soft);
|
|
278
|
+
color: var(--oa-danger);
|
|
279
|
+
}
|
|
280
|
+
|
|
281
|
+
.oa-empty {
|
|
282
|
+
display: flex;
|
|
283
|
+
flex-direction: column;
|
|
284
|
+
align-items: center;
|
|
285
|
+
justify-content: center;
|
|
286
|
+
gap: 8px;
|
|
287
|
+
padding: 46px 24px;
|
|
288
|
+
color: var(--oa-muted);
|
|
289
|
+
text-align: center;
|
|
290
|
+
}
|
|
291
|
+
|
|
292
|
+
.oa-empty__icon {
|
|
293
|
+
display: grid;
|
|
294
|
+
place-items: center;
|
|
295
|
+
width: 46px;
|
|
296
|
+
height: 46px;
|
|
297
|
+
margin-bottom: 2px;
|
|
298
|
+
border-radius: 50%;
|
|
299
|
+
background: var(--oa-surface-soft);
|
|
300
|
+
color: var(--oa-faint);
|
|
301
|
+
font-size: 20px;
|
|
302
|
+
}
|
|
303
|
+
|
|
304
|
+
.oa-empty strong {
|
|
305
|
+
color: var(--oa-ink);
|
|
306
|
+
font-size: 13px;
|
|
307
|
+
font-weight: 600;
|
|
308
|
+
}
|
|
309
|
+
|
|
310
|
+
.oa-empty p {
|
|
311
|
+
max-width: 340px;
|
|
312
|
+
margin: 0;
|
|
313
|
+
color: var(--oa-faint);
|
|
314
|
+
font-size: 12px;
|
|
315
|
+
line-height: 1.7;
|
|
316
|
+
}
|
|
317
|
+
|
|
318
|
+
.oa-table {
|
|
319
|
+
width: 100%;
|
|
320
|
+
border-collapse: separate;
|
|
321
|
+
border-spacing: 0;
|
|
322
|
+
|
|
323
|
+
th {
|
|
324
|
+
padding: 10px 14px;
|
|
325
|
+
background: var(--oa-surface-soft);
|
|
326
|
+
border-bottom: 1px solid var(--oa-line);
|
|
327
|
+
color: var(--oa-faint);
|
|
328
|
+
font-size: 11px;
|
|
329
|
+
font-weight: 600;
|
|
330
|
+
letter-spacing: 0.02em;
|
|
331
|
+
text-align: left;
|
|
332
|
+
white-space: nowrap;
|
|
333
|
+
}
|
|
334
|
+
|
|
335
|
+
td {
|
|
336
|
+
padding: 13px 14px;
|
|
337
|
+
border-bottom: 1px solid var(--oa-line);
|
|
338
|
+
color: var(--oa-ink);
|
|
339
|
+
font-size: 12.5px;
|
|
340
|
+
vertical-align: middle;
|
|
341
|
+
}
|
|
342
|
+
|
|
343
|
+
tbody tr {
|
|
344
|
+
transition: background 0.15s ease;
|
|
345
|
+
}
|
|
346
|
+
|
|
347
|
+
tbody tr:hover {
|
|
348
|
+
background: #f8faff;
|
|
349
|
+
}
|
|
350
|
+
|
|
351
|
+
tbody tr:last-child td {
|
|
352
|
+
border-bottom: none;
|
|
353
|
+
}
|
|
354
|
+
|
|
355
|
+
&__primary {
|
|
356
|
+
display: block;
|
|
357
|
+
max-width: 280px;
|
|
358
|
+
overflow: hidden;
|
|
359
|
+
color: var(--oa-ink);
|
|
360
|
+
font-weight: 600;
|
|
361
|
+
text-overflow: ellipsis;
|
|
362
|
+
white-space: nowrap;
|
|
363
|
+
}
|
|
364
|
+
|
|
365
|
+
&__code {
|
|
366
|
+
display: block;
|
|
367
|
+
margin-top: 2px;
|
|
368
|
+
color: var(--oa-faint);
|
|
369
|
+
font-size: 11px;
|
|
370
|
+
font-variant-numeric: tabular-nums;
|
|
371
|
+
}
|
|
372
|
+
}
|
|
373
|
+
|
|
374
|
+
.oa-link {
|
|
375
|
+
color: var(--oa-primary);
|
|
376
|
+
font-weight: 500;
|
|
377
|
+
text-decoration: none;
|
|
378
|
+
cursor: pointer;
|
|
379
|
+
background: none;
|
|
380
|
+
border: none;
|
|
381
|
+
padding: 0;
|
|
382
|
+
|
|
383
|
+
&:hover {
|
|
384
|
+
color: var(--oa-primary-dark);
|
|
385
|
+
text-decoration: underline;
|
|
386
|
+
text-underline-offset: 3px;
|
|
387
|
+
}
|
|
388
|
+
}
|
|
389
|
+
|
|
390
|
+
.oa-progress {
|
|
391
|
+
height: 4px;
|
|
392
|
+
overflow: hidden;
|
|
393
|
+
border-radius: 999px;
|
|
394
|
+
background: #edf0f6;
|
|
395
|
+
|
|
396
|
+
> span {
|
|
397
|
+
display: block;
|
|
398
|
+
height: 100%;
|
|
399
|
+
border-radius: inherit;
|
|
400
|
+
background: var(--oa-primary);
|
|
401
|
+
transition: width 0.3s ease;
|
|
402
|
+
}
|
|
403
|
+
}
|
|
404
|
+
|
|
405
|
+
.oa-skeleton {
|
|
406
|
+
display: flex;
|
|
407
|
+
flex-direction: column;
|
|
408
|
+
gap: 12px;
|
|
409
|
+
padding: 24px;
|
|
410
|
+
|
|
411
|
+
&__row {
|
|
412
|
+
height: 64px;
|
|
413
|
+
border-radius: 8px;
|
|
414
|
+
background: linear-gradient(90deg, #eef1f6 25%, #f6f8fb 37%, #eef1f6 63%);
|
|
415
|
+
background-size: 400% 100%;
|
|
416
|
+
animation: oa-shimmer 1.4s ease infinite;
|
|
417
|
+
}
|
|
418
|
+
}
|
|
419
|
+
|
|
420
|
+
@keyframes oa-shimmer {
|
|
421
|
+
0% {
|
|
422
|
+
background-position: 100% 50%;
|
|
423
|
+
}
|
|
424
|
+
100% {
|
|
425
|
+
background-position: 0 50%;
|
|
426
|
+
}
|
|
427
|
+
}
|
|
428
|
+
|
|
429
|
+
.oa-mobile-only {
|
|
430
|
+
display: none !important;
|
|
431
|
+
}
|
|
432
|
+
|
|
433
|
+
@media (max-width: 960px) {
|
|
434
|
+
.oa-page {
|
|
435
|
+
padding: 16px 14px 88px;
|
|
436
|
+
gap: 12px;
|
|
437
|
+
}
|
|
438
|
+
|
|
439
|
+
.oa-title {
|
|
440
|
+
font-size: 19px;
|
|
441
|
+
}
|
|
442
|
+
|
|
443
|
+
.oa-section-head {
|
|
444
|
+
padding: 14px 14px 10px;
|
|
445
|
+
}
|
|
446
|
+
|
|
447
|
+
.oa-mobile-only {
|
|
448
|
+
display: inline-flex !important;
|
|
449
|
+
}
|
|
450
|
+
|
|
451
|
+
.oa-desktop-only {
|
|
452
|
+
display: none !important;
|
|
453
|
+
}
|
|
454
|
+
|
|
455
|
+
.oa-table {
|
|
456
|
+
th,
|
|
457
|
+
td {
|
|
458
|
+
padding: 11px 12px;
|
|
459
|
+
}
|
|
460
|
+
}
|
|
461
|
+
}
|
|
462
|
+
|
|
463
|
+
@media (max-width: 560px) {
|
|
464
|
+
.oa-page {
|
|
465
|
+
padding: 14px 12px 86px;
|
|
466
|
+
}
|
|
467
|
+
|
|
468
|
+
.oa-title {
|
|
469
|
+
font-size: 18px;
|
|
470
|
+
}
|
|
471
|
+
}
|
|
472
|
+
|
|
473
|
+
.oa-start-dialog.el-dialog {
|
|
474
|
+
padding: 0;
|
|
475
|
+
overflow: hidden;
|
|
476
|
+
border-radius: 12px;
|
|
477
|
+
background: transparent;
|
|
478
|
+
box-shadow: 0 24px 80px rgba(9, 20, 38, 0.24);
|
|
479
|
+
}
|
|
480
|
+
|
|
481
|
+
.oa-start-dialog .el-dialog__body {
|
|
482
|
+
padding: 0;
|
|
483
|
+
}
|
|
484
|
+
|
|
485
|
+
.oa-action-dialog .el-dialog__body,
|
|
486
|
+
.oa-resubmit-dialog .el-dialog__body {
|
|
487
|
+
padding-top: 10px;
|
|
488
|
+
}
|
|
489
|
+
|
|
490
|
+
@media (max-width: 960px) {
|
|
491
|
+
.oa-action-dialog.el-dialog,
|
|
492
|
+
.oa-resubmit-dialog.el-dialog {
|
|
493
|
+
width: calc(100vw - 20px) !important;
|
|
494
|
+
margin-top: 8vh !important;
|
|
495
|
+
}
|
|
496
|
+
|
|
497
|
+
.oa-resubmit-dialog .el-dialog__footer .el-button {
|
|
498
|
+
min-height: 44px;
|
|
499
|
+
}
|
|
500
|
+
}
|
|
501
|
+
|
|
502
|
+
@media (max-width: 960px) {
|
|
503
|
+
.oa-shell .el-button:not(.is-link):not(.is-text) {
|
|
504
|
+
min-height: 44px;
|
|
505
|
+
}
|
|
506
|
+
|
|
507
|
+
.oa-shell .el-input__wrapper,
|
|
508
|
+
.oa-shell .el-select__wrapper {
|
|
509
|
+
min-height: 44px;
|
|
510
|
+
}
|
|
511
|
+
|
|
512
|
+
.oa-shell .oa-search {
|
|
513
|
+
height: 44px;
|
|
514
|
+
}
|
|
515
|
+
|
|
516
|
+
.oa-shell .oa-topbar__icon,
|
|
517
|
+
.oa-shell .oa-topbar__menu {
|
|
518
|
+
width: 44px;
|
|
519
|
+
height: 44px;
|
|
520
|
+
}
|
|
521
|
+
|
|
522
|
+
.oa-shell .oa-identity {
|
|
523
|
+
min-height: 44px;
|
|
524
|
+
}
|
|
525
|
+
|
|
526
|
+
.oa-shell .oa-filter-pill,
|
|
527
|
+
.oa-shell .oa-segment button,
|
|
528
|
+
.oa-shell .oa-category,
|
|
529
|
+
.oa-shell .oa-requests__scope-item,
|
|
530
|
+
.oa-shell .oa-saved-view,
|
|
531
|
+
.oa-shell .oa-batch-toggle {
|
|
532
|
+
min-height: 44px;
|
|
533
|
+
}
|
|
534
|
+
}
|
|
535
|
+
|
|
536
|
+
@media (max-width: 960px) {
|
|
537
|
+
.oa-start-dialog .el-input__wrapper,
|
|
538
|
+
.oa-start-dialog .el-select__wrapper,
|
|
539
|
+
.oa-resubmit-dialog .el-input__wrapper,
|
|
540
|
+
.oa-resubmit-dialog .el-select__wrapper,
|
|
541
|
+
.oa-action-dialog .el-input__wrapper,
|
|
542
|
+
.oa-action-dialog .el-select__wrapper {
|
|
543
|
+
min-height: 44px;
|
|
544
|
+
}
|
|
545
|
+
|
|
546
|
+
.oa-start-dialog .el-button,
|
|
547
|
+
.oa-resubmit-dialog .el-button,
|
|
548
|
+
.oa-action-dialog .el-button {
|
|
549
|
+
min-height: 44px;
|
|
550
|
+
}
|
|
551
|
+
|
|
552
|
+
.oa-user-popper .el-dropdown-menu__item {
|
|
553
|
+
min-height: 44px;
|
|
554
|
+
}
|
|
555
|
+
}
|