@miragon/modeler-shell 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.
Files changed (126) hide show
  1. package/API.md +1902 -0
  2. package/LICENSE +21 -0
  3. package/README.md +435 -2
  4. package/THIRD_PARTY_NOTICES.md +52 -0
  5. package/dist/appearance-D3FUcbu6.d.cts +53 -0
  6. package/dist/appearance-D3FUcbu6.d.ts +53 -0
  7. package/dist/chunk-5JSZ4VGA.js +551 -0
  8. package/dist/chunk-5JSZ4VGA.js.map +1 -0
  9. package/dist/chunk-6LQOFACK.js +1576 -0
  10. package/dist/chunk-6LQOFACK.js.map +1 -0
  11. package/dist/chunk-N4QXFF3A.js +23 -0
  12. package/dist/chunk-N4QXFF3A.js.map +1 -0
  13. package/dist/chunk-RJRFR6N3.js +136 -0
  14. package/dist/chunk-RJRFR6N3.js.map +1 -0
  15. package/dist/core.cjs +619 -0
  16. package/dist/core.cjs.map +1 -0
  17. package/dist/core.d.cts +171 -0
  18. package/dist/core.d.ts +171 -0
  19. package/dist/core.js +91 -0
  20. package/dist/core.js.map +1 -0
  21. package/dist/diagram-js.cjs +1115 -0
  22. package/dist/diagram-js.cjs.map +1 -0
  23. package/dist/diagram-js.d.cts +163 -0
  24. package/dist/diagram-js.d.ts +163 -0
  25. package/dist/diagram-js.js +867 -0
  26. package/dist/diagram-js.js.map +1 -0
  27. package/dist/index.cjs +2175 -0
  28. package/dist/index.cjs.map +1 -0
  29. package/dist/index.d.cts +20 -0
  30. package/dist/index.d.ts +20 -0
  31. package/dist/index.js +103 -0
  32. package/dist/index.js.map +1 -0
  33. package/dist/keymap-CObQE6q6.d.cts +151 -0
  34. package/dist/keymap-DORzHnK-.d.ts +151 -0
  35. package/dist/protocol-DhYBakWL.d.cts +15 -0
  36. package/dist/protocol-IeW8bf4f.d.ts +15 -0
  37. package/dist/shell.css +914 -0
  38. package/dist/testing-vscode-stub.cjs +332 -0
  39. package/dist/testing-vscode-stub.cjs.map +1 -0
  40. package/dist/testing-vscode-stub.d.cts +65 -0
  41. package/dist/testing-vscode-stub.d.ts +65 -0
  42. package/dist/testing-vscode-stub.js +154 -0
  43. package/dist/testing-vscode-stub.js.map +1 -0
  44. package/dist/testing.cjs +2364 -0
  45. package/dist/testing.cjs.map +1 -0
  46. package/dist/testing.d.cts +165 -0
  47. package/dist/testing.d.ts +165 -0
  48. package/dist/testing.js +2297 -0
  49. package/dist/testing.js.map +1 -0
  50. package/dist/types-B6NfkiUG.d.cts +66 -0
  51. package/dist/types-B6NfkiUG.d.ts +66 -0
  52. package/dist/types-DnZn9CPw.d.ts +284 -0
  53. package/dist/types-OuFlqZp0.d.cts +284 -0
  54. package/dist/vscode-extension.cjs +215 -0
  55. package/dist/vscode-extension.cjs.map +1 -0
  56. package/dist/vscode-extension.d.cts +103 -0
  57. package/dist/vscode-extension.d.ts +103 -0
  58. package/dist/vscode-extension.js +24 -0
  59. package/dist/vscode-extension.js.map +1 -0
  60. package/dist/vscode-webview.cjs +2198 -0
  61. package/dist/vscode-webview.cjs.map +1 -0
  62. package/dist/vscode-webview.d.cts +82 -0
  63. package/dist/vscode-webview.d.ts +82 -0
  64. package/dist/vscode-webview.js +250 -0
  65. package/dist/vscode-webview.js.map +1 -0
  66. package/package.json +145 -4
  67. package/src/core/appearance.ts +104 -0
  68. package/src/core/fit.ts +205 -0
  69. package/src/core/index.ts +84 -0
  70. package/src/core/keymap.ts +275 -0
  71. package/src/core/layout.ts +69 -0
  72. package/src/core/messages.ts +88 -0
  73. package/src/core/sizes.ts +85 -0
  74. package/src/core/types.ts +84 -0
  75. package/src/core/zoom.ts +74 -0
  76. package/src/core.ts +2 -0
  77. package/src/diagram-js/connect.ts +75 -0
  78. package/src/diagram-js/index.ts +16 -0
  79. package/src/diagram-js/module.ts +20 -0
  80. package/src/diagram-js/palette-skin.ts +267 -0
  81. package/src/diagram-js/palette.css +269 -0
  82. package/src/diagram-js/service.ts +240 -0
  83. package/src/diagram-js/types.ts +67 -0
  84. package/src/diagram-js/viewport.ts +564 -0
  85. package/src/diagram-js.ts +2 -0
  86. package/src/dom/element.ts +51 -0
  87. package/src/dom/hint.ts +51 -0
  88. package/src/dom/icons.ts +309 -0
  89. package/src/dom/index.ts +29 -0
  90. package/src/dom/inspector.ts +35 -0
  91. package/src/dom/keys.ts +59 -0
  92. package/src/dom/ledger.ts +87 -0
  93. package/src/dom/legend.ts +85 -0
  94. package/src/dom/menu.ts +393 -0
  95. package/src/dom/mount.ts +461 -0
  96. package/src/dom/problems.ts +72 -0
  97. package/src/dom/shell-dom.css +966 -0
  98. package/src/dom/status.ts +72 -0
  99. package/src/dom/tooltip.ts +237 -0
  100. package/src/dom/types.ts +277 -0
  101. package/src/dom/zoom-panel.ts +154 -0
  102. package/src/index.ts +3 -0
  103. package/src/shell.css +6 -0
  104. package/src/testing/cases.ts +1012 -0
  105. package/src/testing/checks.ts +832 -0
  106. package/src/testing/facts.ts +587 -0
  107. package/src/testing/geometry.ts +472 -0
  108. package/src/testing/harness.ts +138 -0
  109. package/src/testing/index.ts +15 -0
  110. package/src/testing/page-tools.ts +434 -0
  111. package/src/testing/page.ts +17 -0
  112. package/src/testing/vscode-stub.ts +237 -0
  113. package/src/testing-vscode-stub.ts +2 -0
  114. package/src/testing.ts +2 -0
  115. package/src/vscode/extension/html.ts +107 -0
  116. package/src/vscode/extension/index.ts +8 -0
  117. package/src/vscode/extension/reveal.ts +9 -0
  118. package/src/vscode/extension/theme-bridge.ts +85 -0
  119. package/src/vscode/extension/types.ts +36 -0
  120. package/src/vscode/protocol.ts +31 -0
  121. package/src/vscode/webview/appearance.ts +141 -0
  122. package/src/vscode/webview/index.ts +8 -0
  123. package/src/vscode/webview/mount.ts +76 -0
  124. package/src/vscode/webview/state.ts +116 -0
  125. package/src/vscode-extension.ts +2 -0
  126. package/src/vscode-webview.ts +2 -0
package/dist/shell.css ADDED
@@ -0,0 +1,914 @@
1
+ /* src/dom/shell-dom.css */
2
+ .cd-shell,
3
+ html.cd-shell-document {
4
+ --modeler-shell-font:
5
+ "Geist Variable",
6
+ "Geist",
7
+ ui-sans-serif,
8
+ system-ui,
9
+ -apple-system,
10
+ "Segoe UI",
11
+ sans-serif;
12
+ --modeler-shell-font-mono:
13
+ "Geist Mono Variable",
14
+ "Geist Mono",
15
+ ui-monospace,
16
+ monospace;
17
+ }
18
+ .cd-shell {
19
+ position: relative;
20
+ overflow: hidden;
21
+ container: cd-shell / size;
22
+ isolation: isolate;
23
+ color: var(--cd-ui-text);
24
+ font: 400 13px/1.5 var(--modeler-shell-font);
25
+ -webkit-font-smoothing: antialiased;
26
+ }
27
+ :where(html.cd-shell-document body > .cd-shell) {
28
+ height: 100%;
29
+ }
30
+ .cd-shell > .cd-shell-canvas {
31
+ position: absolute;
32
+ inset: 0;
33
+ z-index: 0;
34
+ isolation: isolate;
35
+ overflow: hidden;
36
+ }
37
+ :where(.cd-shell-canvas) {
38
+ background-color: var(--cd-ui-grund);
39
+ }
40
+ :where(.cd-shell) :where(button, input, select, textarea) {
41
+ font: inherit;
42
+ color: inherit;
43
+ }
44
+ :where(.cd-shell) :is(.cd-shell-layer, .cd-shell-island, .cd-shell-menu, .cd-shell-menu-group, .cd-shell-status, .cd-shell-hint, .cd-shell-inspector, .cd-shell-legend-header, .cd-shell-legend-body, .cd-shell-tooltip, .cd-shell-menu-trigger, .cd-shell-target, .cd-shell-menu-item, .cd-shell-menu-item-label, .cd-shell-menu-shortcut, .cd-shell-menu-heading, .cd-shell-problems, .cd-shell-problems-text, .cd-shell-legend-close, .cd-shell-legend-title, .cd-shell-hint-text, .cd-shell-hint-action, .cd-shell-status-text, .cd-shell-tooltip-label, .cd-shell-kbd) {
45
+ color: inherit;
46
+ font: inherit;
47
+ letter-spacing: normal;
48
+ word-spacing: normal;
49
+ text-transform: none;
50
+ text-indent: 0;
51
+ text-shadow: none;
52
+ }
53
+ .cd-shell-layer {
54
+ position: absolute;
55
+ inset: 0;
56
+ z-index: var(--cd-shell-ebene-aufklapper);
57
+ pointer-events: none;
58
+ }
59
+ .cd-shell :is(.cd-shell-island, .cd-shell-status, .cd-shell-hint, .cd-shell-inspector, .cd-shell-menu, .cd-shell-tooltip, .cd-shell-kbd)[hidden] {
60
+ display: none;
61
+ }
62
+ .cd-shell-island {
63
+ position: absolute;
64
+ z-index: var(--cd-shell-ebene-inseln);
65
+ box-sizing: border-box;
66
+ margin: 0;
67
+ color: var(--cd-ui-text);
68
+ background: color-mix(in srgb, var(--cd-ui-flaeche-hoch) var(--cd-ui-chrome-deckkraft), transparent);
69
+ -webkit-backdrop-filter: blur(8px);
70
+ backdrop-filter: blur(8px);
71
+ border: 1px solid var(--cd-ui-linie);
72
+ border-radius: var(--cd-radius-md);
73
+ box-shadow: var(--cd-shadow-1);
74
+ user-select: none;
75
+ -webkit-user-select: none;
76
+ }
77
+ .cd-shell :is(.cd-shell-menu-trigger, .cd-shell-target, .cd-shell-menu-item-icon, .cd-shell-menu-item-end, .cd-shell-problems-icon, .cd-shell-status-icon, .cd-shell-legend-close) svg {
78
+ display: block;
79
+ flex: none;
80
+ }
81
+ .cd-shell :is(.cd-shell-menu-trigger, .cd-shell-target, .cd-shell-menu-item, .cd-shell-problems, .cd-shell-legend-close, .cd-shell-hint-action):focus {
82
+ outline: none;
83
+ }
84
+ .cd-shell :is(.cd-shell-menu-trigger, .cd-shell-target, .cd-shell-menu-item, .cd-shell-problems, .cd-shell-legend-close, .cd-shell-hint-action):focus-visible {
85
+ outline: 2px solid var(--cd-ui-fokus);
86
+ outline-offset: 2px;
87
+ }
88
+ .cd-shell :is(.cd-shell-menu-item, .cd-shell-zoom .cd-shell-target):focus-visible {
89
+ outline-offset: -2px;
90
+ }
91
+ .cd-shell-canvas .djs-container > svg:focus {
92
+ outline: none;
93
+ }
94
+ .cd-shell-canvas .djs-container > svg:focus-visible {
95
+ outline: 2px solid var(--cd-ui-fokus);
96
+ outline-offset: -2px;
97
+ }
98
+ .cd-shell-menu-trigger {
99
+ top: var(--cd-shell-rand);
100
+ left: var(--cd-shell-rand);
101
+ z-index: var(--cd-shell-ebene-reihe);
102
+ display: grid;
103
+ place-items: center;
104
+ width: var(--cd-shell-zeile);
105
+ height: var(--cd-shell-zeile);
106
+ padding: 0;
107
+ cursor: pointer;
108
+ transition: background-color var(--cd-motion-fast) var(--cd-ease), color var(--cd-motion-fast) var(--cd-ease);
109
+ }
110
+ .cd-shell-menu-trigger:hover,
111
+ .cd-shell-menu-trigger:active,
112
+ .cd-shell-menu-trigger[aria-expanded=true] {
113
+ color: var(--cd-ui-interaktion);
114
+ background: var(--cd-ui-hover);
115
+ }
116
+ .cd-shell-menu {
117
+ position: absolute;
118
+ top: calc(var(--cd-shell-rand) + var(--cd-shell-zeile) + var(--cd-shell-luecke));
119
+ left: var(--cd-shell-rand);
120
+ box-sizing: border-box;
121
+ display: flex;
122
+ flex-direction: column;
123
+ min-width: min(var(--cd-shell-menue-breite), 100cqw - 2 * var(--cd-shell-rand));
124
+ max-width: min(320px, 100cqw - 2 * var(--cd-shell-rand));
125
+ max-height: calc(100cqh - 72px);
126
+ overflow-y: auto;
127
+ overscroll-behavior: contain;
128
+ margin: 0;
129
+ padding: 6px;
130
+ color: var(--cd-ui-text);
131
+ background: var(--cd-ui-flaeche-hoch);
132
+ border: 1px solid var(--cd-ui-linie);
133
+ border-radius: var(--cd-radius-md);
134
+ box-shadow: var(--cd-shadow-3);
135
+ pointer-events: auto;
136
+ user-select: none;
137
+ -webkit-user-select: none;
138
+ animation: cd-shell-drop-in var(--cd-motion-fast) var(--cd-ease-out);
139
+ }
140
+ .cd-shell-menu-item {
141
+ box-sizing: border-box;
142
+ display: flex;
143
+ flex: none;
144
+ align-items: center;
145
+ gap: 12px;
146
+ width: 100%;
147
+ min-height: var(--cd-shell-eintrag);
148
+ margin: 0;
149
+ padding: 8px 12px;
150
+ color: var(--cd-ui-text);
151
+ font: inherit;
152
+ font-size: 13px;
153
+ font-weight: 400;
154
+ line-height: 1.5;
155
+ text-align: left;
156
+ background: transparent;
157
+ border: 0;
158
+ border-radius: var(--cd-radius-sm);
159
+ cursor: pointer;
160
+ transition: background-color var(--cd-motion-fast) var(--cd-ease);
161
+ }
162
+ .cd-shell-menu-item:hover,
163
+ .cd-shell-menu-item:focus-visible {
164
+ background: var(--cd-ui-hover);
165
+ }
166
+ .cd-shell-menu-item-icon {
167
+ display: grid;
168
+ flex: none;
169
+ place-items: center;
170
+ width: 16px;
171
+ height: 16px;
172
+ }
173
+ .cd-shell-menu-item-label {
174
+ flex: 1 1 auto;
175
+ min-width: 0;
176
+ }
177
+ .cd-shell-menu-item-end {
178
+ display: flex;
179
+ flex: none;
180
+ align-items: center;
181
+ margin-left: auto;
182
+ }
183
+ .cd-shell-menu-shortcut {
184
+ color: var(--cd-ui-text-leise);
185
+ font-family: var(--modeler-shell-font-mono);
186
+ font-size: 13px;
187
+ }
188
+ .cd-shell-menu-check {
189
+ color: var(--cd-ui-text);
190
+ }
191
+ .cd-shell-menu-item[aria-checked=false] .cd-shell-menu-check {
192
+ visibility: hidden;
193
+ }
194
+ .cd-shell-menu-item[data-danger] .cd-shell-menu-item-icon {
195
+ color: var(--cd-ui-danger);
196
+ }
197
+ .cd-shell-menu-item[aria-disabled=true] {
198
+ color: var(--cd-ui-text-leise);
199
+ cursor: not-allowed;
200
+ }
201
+ .cd-shell-menu-item[aria-disabled=true]:hover,
202
+ .cd-shell-menu-item[aria-disabled=true]:focus-visible {
203
+ background: transparent;
204
+ }
205
+ .cd-shell-menu-item[aria-disabled=true] :is(.cd-shell-menu-item-icon, .cd-shell-menu-check) {
206
+ color: inherit;
207
+ }
208
+ .cd-shell-menu-separator {
209
+ flex: none;
210
+ height: 1px;
211
+ margin: 4px 8px;
212
+ background: var(--cd-ui-linie);
213
+ }
214
+ .cd-shell-menu-group {
215
+ display: flex;
216
+ flex: none;
217
+ flex-direction: column;
218
+ }
219
+ .cd-shell-menu-heading {
220
+ padding: 8px 12px 4px;
221
+ color: var(--cd-ui-text-leise);
222
+ font-size: 13px;
223
+ font-weight: 600;
224
+ line-height: 1.5;
225
+ }
226
+ .cd-shell-tooltip {
227
+ position: absolute;
228
+ top: 0;
229
+ left: 0;
230
+ box-sizing: border-box;
231
+ width: max-content;
232
+ max-width: min(280px, 100cqw - 2 * var(--cd-shell-rand));
233
+ margin: 0;
234
+ padding: 3px 8px;
235
+ color: var(--cd-ui-text);
236
+ font: 400 13px/20px var(--modeler-shell-font);
237
+ white-space: normal;
238
+ background: var(--cd-ui-flaeche-hoch);
239
+ border: 1px solid var(--cd-ui-linie);
240
+ border-radius: var(--cd-radius-sm);
241
+ box-shadow: var(--cd-shadow-2);
242
+ pointer-events: none;
243
+ user-select: none;
244
+ -webkit-user-select: none;
245
+ }
246
+ .cd-shell-tooltip .cd-shell-kbd {
247
+ margin-left: 6px;
248
+ }
249
+ .cd-shell-kbd,
250
+ html.cd-shell-document kbd {
251
+ display: inline;
252
+ margin: 0;
253
+ padding: 1px 6px;
254
+ color: var(--cd-ui-text-leise);
255
+ font: 400 13px/16px var(--modeler-shell-font-mono);
256
+ text-shadow: none;
257
+ vertical-align: baseline;
258
+ background: var(--cd-ui-grund);
259
+ border: 1px solid var(--cd-ui-linie);
260
+ border-radius: var(--cd-radius-sm);
261
+ box-shadow: none;
262
+ }
263
+ .cd-shell-zoom {
264
+ right: var(--cd-shell-rand);
265
+ bottom: var(--cd-shell-rand);
266
+ display: flex;
267
+ align-items: center;
268
+ gap: 2px;
269
+ height: var(--cd-shell-zeile);
270
+ padding: 3px;
271
+ }
272
+ .cd-shell-target {
273
+ box-sizing: border-box;
274
+ display: inline-grid;
275
+ flex: none;
276
+ place-items: center;
277
+ width: var(--cd-shell-ziel);
278
+ height: var(--cd-shell-ziel);
279
+ margin: 0;
280
+ padding: 0;
281
+ color: var(--cd-ui-text);
282
+ background: transparent;
283
+ border: 0;
284
+ border-radius: var(--cd-radius-sm);
285
+ cursor: pointer;
286
+ transition: background-color var(--cd-motion-fast) var(--cd-ease), color var(--cd-motion-fast) var(--cd-ease);
287
+ }
288
+ .cd-shell-target:hover {
289
+ color: var(--cd-ui-interaktion);
290
+ background: var(--cd-ui-hover);
291
+ }
292
+ .cd-shell-zoom-readout {
293
+ width: auto;
294
+ min-width: 56px;
295
+ padding: 0 4px;
296
+ font-size: 13px;
297
+ font-weight: 600;
298
+ font-variant-numeric: tabular-nums;
299
+ line-height: 1;
300
+ white-space: nowrap;
301
+ }
302
+ .cd-shell-zoom-readout:hover {
303
+ color: var(--cd-ui-text);
304
+ }
305
+ .cd-shell-target[aria-disabled=true],
306
+ .cd-shell-target[aria-disabled=true]:hover {
307
+ color: var(--cd-ui-text-leise);
308
+ background: transparent;
309
+ cursor: not-allowed;
310
+ }
311
+ .cd-shell-zoom-separator {
312
+ flex: none;
313
+ align-self: stretch;
314
+ width: 1px;
315
+ margin: 4px 2px;
316
+ background: var(--cd-ui-linie);
317
+ }
318
+ .cd-shell-problems {
319
+ left: var(--cd-shell-rand);
320
+ bottom: var(--cd-shell-rand);
321
+ display: inline-flex;
322
+ align-items: center;
323
+ gap: var(--cd-shell-luecke);
324
+ height: var(--cd-shell-zeile);
325
+ padding: 0 16px;
326
+ font: inherit;
327
+ font-size: 13px;
328
+ line-height: 1.5;
329
+ white-space: nowrap;
330
+ border-radius: var(--cd-radius-pill);
331
+ cursor: pointer;
332
+ transition: background-color var(--cd-motion-fast) var(--cd-ease);
333
+ }
334
+ .cd-shell-problems:hover {
335
+ background: var(--cd-ui-hover);
336
+ }
337
+ .cd-shell-problems[data-severity=danger] .cd-shell-problems-icon {
338
+ color: var(--cd-ui-danger);
339
+ }
340
+ .cd-shell-problems[data-severity=warning] .cd-shell-problems-icon {
341
+ color: var(--cd-ui-warning);
342
+ }
343
+ .cd-shell[data-cd-shell-host=web] .cd-shell-problems {
344
+ bottom: calc(var(--cd-shell-rand) + 20px + var(--cd-shell-luecke));
345
+ }
346
+ .cd-shell-status {
347
+ position: absolute;
348
+ top: var(--cd-shell-frei);
349
+ left: 50%;
350
+ translate: -50% 0;
351
+ z-index: var(--cd-shell-ebene-inseln);
352
+ box-sizing: border-box;
353
+ display: flex;
354
+ align-items: flex-start;
355
+ gap: var(--cd-shell-luecke);
356
+ width: max-content;
357
+ max-width: min(560px, 100cqw - 2 * var(--cd-shell-rand));
358
+ margin: 0;
359
+ padding: 12px 16px;
360
+ overflow: hidden;
361
+ color: var(--cd-ui-text);
362
+ font-size: 13px;
363
+ line-height: 1.5;
364
+ background: var(--cd-ui-danger-flaeche);
365
+ border: 1px solid var(--cd-ui-danger);
366
+ border-radius: var(--cd-radius-md);
367
+ box-shadow: var(--cd-shadow-2);
368
+ user-select: none;
369
+ -webkit-user-select: none;
370
+ animation: cd-shell-drop-in var(--cd-motion-base) var(--cd-ease-out);
371
+ }
372
+ .cd-shell-status::before {
373
+ content: "";
374
+ position: absolute;
375
+ top: 0;
376
+ bottom: 0;
377
+ left: 0;
378
+ width: 4px;
379
+ background: var(--cd-ui-danger);
380
+ }
381
+ .cd-shell-status-icon {
382
+ flex: none;
383
+ margin-top: 2px;
384
+ color: var(--cd-ui-danger);
385
+ }
386
+ .cd-shell-status-text {
387
+ margin: 0;
388
+ }
389
+ .cd-shell-status[data-severity=warning] {
390
+ background: var(--cd-ui-warning-flaeche);
391
+ border-color: var(--cd-ui-warning);
392
+ }
393
+ .cd-shell-status[data-severity=warning]::before {
394
+ background: var(--cd-ui-warning);
395
+ }
396
+ .cd-shell-status[data-severity=warning] .cd-shell-status-icon {
397
+ color: var(--cd-ui-warning);
398
+ }
399
+ .cd-shell[data-palette=second-row] .cd-shell-status {
400
+ top: calc(var(--cd-shell-frei) + var(--cd-shell-zeile) + var(--cd-shell-rand));
401
+ }
402
+ @container cd-shell (width > 760px) {
403
+ .cd-shell[data-inspector=open] .cd-shell-status {
404
+ left: calc((100cqw - var(--cd-shell-inspector-breite) - var(--cd-shell-rand)) / 2);
405
+ max-width: min(560px, 100cqw - var(--cd-shell-inspector-breite) - 3 * var(--cd-shell-rand));
406
+ }
407
+ }
408
+ .cd-shell-hint {
409
+ position: absolute;
410
+ inset: var(--cd-shell-einpassen-oben) var(--cd-shell-einpassen-seite) var(--cd-shell-einpassen-unten);
411
+ z-index: var(--cd-shell-ebene-inseln);
412
+ display: flex;
413
+ flex-direction: column;
414
+ align-items: center;
415
+ justify-content: center;
416
+ gap: 12px;
417
+ text-align: center;
418
+ pointer-events: none;
419
+ user-select: none;
420
+ -webkit-user-select: none;
421
+ }
422
+ .cd-shell[data-palette=second-row] .cd-shell-hint {
423
+ top: var(--cd-shell-einpassen-oben-schmal);
424
+ }
425
+ .cd-shell-hint-text {
426
+ margin: 0;
427
+ color: var(--cd-ui-text-leise);
428
+ font-size: 13px;
429
+ line-height: 1.5;
430
+ }
431
+ .cd-shell-hint-action {
432
+ box-sizing: border-box;
433
+ display: inline-flex;
434
+ align-items: center;
435
+ justify-content: center;
436
+ height: var(--cd-shell-eintrag);
437
+ margin: 0;
438
+ padding: 0 16px;
439
+ color: var(--cd-ui-text);
440
+ font: inherit;
441
+ font-size: 13px;
442
+ font-weight: 600;
443
+ line-height: 1;
444
+ white-space: nowrap;
445
+ background: transparent;
446
+ border: 1px solid transparent;
447
+ border-radius: var(--cd-radius-md);
448
+ cursor: pointer;
449
+ pointer-events: auto;
450
+ transition: background-color var(--cd-motion-fast) var(--cd-ease);
451
+ }
452
+ .cd-shell-hint-action:hover {
453
+ background: var(--cd-ui-hover);
454
+ }
455
+ .cd-shell-legend {
456
+ --modeler-shell-legend-bottom: var(--cd-shell-rand);
457
+ --modeler-shell-legend-min-bottom: 0px;
458
+ --modeler-shell-legend-top: var(--cd-shell-frei);
459
+ left: var(--cd-shell-rand);
460
+ bottom: max(var(--modeler-shell-legend-bottom), var(--modeler-shell-legend-min-bottom));
461
+ min-width: 184px;
462
+ max-height: calc(100cqh - var(--modeler-shell-legend-top) - max(var(--modeler-shell-legend-bottom), var(--modeler-shell-legend-min-bottom)) - var(--cd-shell-rand));
463
+ overflow-y: auto;
464
+ overscroll-behavior: contain;
465
+ padding: 8px 12px 12px 16px;
466
+ box-shadow: var(--cd-shadow-2);
467
+ animation: cd-shell-rise-in var(--cd-motion-base) var(--cd-ease-out);
468
+ }
469
+ .cd-shell[data-problems=shown] .cd-shell-legend {
470
+ --modeler-shell-legend-bottom: calc(var(--cd-shell-rand) + var(--cd-shell-zeile) + var(--cd-shell-luecke));
471
+ }
472
+ .cd-shell[data-cd-shell-host=web] .cd-shell-legend {
473
+ --modeler-shell-legend-bottom: calc(var(--cd-shell-rand) + 20px + var(--cd-shell-luecke));
474
+ }
475
+ .cd-shell[data-cd-shell-host=web][data-problems=shown] .cd-shell-legend {
476
+ --modeler-shell-legend-bottom: calc( var(--cd-shell-rand) + 20px + var(--cd-shell-luecke) + var(--cd-shell-zeile) + var(--cd-shell-luecke) );
477
+ }
478
+ .cd-shell[data-palette=second-row] .cd-shell-legend {
479
+ --modeler-shell-legend-top: calc(var(--cd-shell-frei) + var(--cd-shell-zeile) + var(--cd-shell-rand));
480
+ }
481
+ @container cd-shell (max-width: 440px) {
482
+ .cd-shell-legend {
483
+ --modeler-shell-legend-min-bottom: calc( var(--cd-shell-rand) + var(--cd-shell-zeile) + var(--cd-shell-luecke) );
484
+ }
485
+ }
486
+ .cd-shell-legend-header {
487
+ display: flex;
488
+ align-items: center;
489
+ justify-content: space-between;
490
+ gap: var(--cd-shell-luecke);
491
+ margin: 0 -4px 4px 0;
492
+ }
493
+ .cd-shell-legend-title {
494
+ margin: 0;
495
+ font-size: 13px;
496
+ font-weight: 600;
497
+ line-height: 1.5;
498
+ }
499
+ .cd-shell-legend-close {
500
+ box-sizing: border-box;
501
+ display: grid;
502
+ flex: none;
503
+ place-items: center;
504
+ width: 28px;
505
+ height: 28px;
506
+ margin: 0;
507
+ padding: 0;
508
+ color: var(--cd-ui-text);
509
+ background: transparent;
510
+ border: 0;
511
+ border-radius: var(--cd-radius-sm);
512
+ cursor: pointer;
513
+ transition: background-color var(--cd-motion-fast) var(--cd-ease), color var(--cd-motion-fast) var(--cd-ease);
514
+ }
515
+ .cd-shell-legend-close:hover {
516
+ color: var(--cd-ui-interaktion);
517
+ background: var(--cd-ui-hover);
518
+ }
519
+ .cd-shell-legend-body {
520
+ display: flex;
521
+ flex-direction: column;
522
+ gap: 4px;
523
+ }
524
+ .cd-shell-legend-row {
525
+ display: flex;
526
+ align-items: center;
527
+ gap: var(--cd-shell-luecke);
528
+ min-height: 24px;
529
+ color: var(--cd-ui-text);
530
+ font-size: 13px;
531
+ line-height: 1.5;
532
+ }
533
+ .cd-shell-legend-preview {
534
+ display: inline-grid;
535
+ flex: none;
536
+ place-items: center;
537
+ width: 24px;
538
+ height: 24px;
539
+ }
540
+ .cd-shell-legend-separator {
541
+ flex: none;
542
+ height: 1px;
543
+ margin: 4px 0;
544
+ background: var(--cd-ui-linie);
545
+ border: 0;
546
+ }
547
+ .cd-shell-inspector {
548
+ position: absolute;
549
+ top: var(--cd-shell-frei);
550
+ right: var(--cd-shell-rand);
551
+ z-index: var(--cd-shell-ebene-inspector);
552
+ box-sizing: border-box;
553
+ width: var(--cd-shell-inspector-breite);
554
+ max-height: calc(100cqh - 2 * var(--cd-shell-frei));
555
+ overflow-y: auto;
556
+ overscroll-behavior: contain;
557
+ margin: 0;
558
+ padding: 16px;
559
+ color: var(--cd-ui-text);
560
+ background: var(--cd-ui-flaeche-hoch);
561
+ border: 1px solid var(--cd-ui-linie);
562
+ border-radius: var(--cd-radius-lg);
563
+ box-shadow: var(--cd-shadow-2);
564
+ animation: cd-shell-drop-in var(--cd-motion-fast) var(--cd-ease-out);
565
+ }
566
+ @container cd-shell (max-width: 760px) {
567
+ .cd-shell-inspector {
568
+ top: auto;
569
+ left: var(--cd-shell-rand);
570
+ bottom: var(--cd-shell-rand);
571
+ width: auto;
572
+ max-height: 45cqh;
573
+ animation: cd-shell-rise-in var(--cd-motion-base) var(--cd-ease-out);
574
+ }
575
+ .cd-shell[data-inspector=open] :is(.cd-shell-zoom, .cd-shell-problems, .cd-shell-legend) {
576
+ visibility: hidden;
577
+ }
578
+ .cd-shell-status {
579
+ top: calc(var(--cd-shell-frei) + var(--cd-shell-zeile) + var(--cd-shell-rand));
580
+ }
581
+ .cd-shell-hint {
582
+ top: var(--cd-shell-einpassen-oben-schmal);
583
+ }
584
+ .cd-shell-legend {
585
+ --modeler-shell-legend-top: calc(var(--cd-shell-frei) + var(--cd-shell-zeile) + var(--cd-shell-rand));
586
+ }
587
+ }
588
+ @keyframes cd-shell-drop-in {
589
+ from {
590
+ opacity: 0;
591
+ transform: translateY(-4px);
592
+ }
593
+ }
594
+ @keyframes cd-shell-rise-in {
595
+ from {
596
+ opacity: 0;
597
+ transform: translateY(8px);
598
+ }
599
+ }
600
+ @media (prefers-reduced-motion: reduce) {
601
+ .cd-shell,
602
+ .cd-shell *,
603
+ .cd-shell *::before,
604
+ .cd-shell *::after {
605
+ animation-duration: 0.001ms !important;
606
+ animation-iteration-count: 1 !important;
607
+ transition-duration: 0.001ms !important;
608
+ }
609
+ }
610
+ html.cd-shell-reduce-motion .cd-shell,
611
+ html.cd-shell-reduce-motion .cd-shell *,
612
+ html.cd-shell-reduce-motion .cd-shell *::before,
613
+ html.cd-shell-reduce-motion .cd-shell *::after {
614
+ animation-duration: 0.001ms !important;
615
+ animation-iteration-count: 1 !important;
616
+ transition-duration: 0.001ms !important;
617
+ }
618
+ html.cd-shell-no-transition,
619
+ html.cd-shell-no-transition *,
620
+ html.cd-shell-no-transition *::before,
621
+ html.cd-shell-no-transition *::after {
622
+ transition: none !important;
623
+ }
624
+ .cd-shell:is([data-cd-kontrast=hoch], [data-cd-kontrast=hoch] *) :is(.cd-shell-island, .cd-shell-menu, .cd-shell-tooltip, .cd-shell-status, .cd-shell-inspector) {
625
+ box-shadow: none;
626
+ }
627
+ .cd-shell:is([data-cd-kontrast=hoch], [data-cd-kontrast=hoch] *) :is(.cd-shell-menu-trigger, .cd-shell-target, .cd-shell-menu-item, .cd-shell-problems, .cd-shell-legend-close, .cd-shell-hint-action):focus-visible {
628
+ outline-width: 3px;
629
+ }
630
+ .cd-shell:is([data-cd-kontrast=hoch], [data-cd-kontrast=hoch] *) :is(.cd-shell-menu-item, .cd-shell-zoom .cd-shell-target):focus-visible {
631
+ outline-offset: -3px;
632
+ }
633
+ .cd-shell:is([data-cd-kontrast=hoch], [data-cd-kontrast=hoch] *) .cd-shell-canvas .djs-container > svg:focus-visible {
634
+ outline-width: 3px;
635
+ outline-offset: -3px;
636
+ }
637
+ @media (forced-colors: active) {
638
+ .cd-shell :is(.cd-shell-island, .cd-shell-menu, .cd-shell-tooltip, .cd-shell-status, .cd-shell-inspector) {
639
+ border-color: CanvasText;
640
+ }
641
+ .cd-shell-status::before,
642
+ .cd-shell :is(.cd-shell-menu-separator, .cd-shell-zoom-separator, .cd-shell-legend-separator) {
643
+ forced-color-adjust: none;
644
+ background: CanvasText;
645
+ }
646
+ .cd-shell :is(.cd-shell-menu-trigger, .cd-shell-target, .cd-shell-menu-item, .cd-shell-problems, .cd-shell-legend-close, .cd-shell-hint-action):focus-visible {
647
+ outline-color: Highlight;
648
+ }
649
+ .cd-shell :is(.cd-shell-menu-trigger, .cd-shell-target)[aria-pressed=true] {
650
+ forced-color-adjust: none;
651
+ box-shadow: inset 0 0 0 2px Highlight;
652
+ }
653
+ .cd-shell .cd-shell-canvas .djs-container > svg:focus-visible {
654
+ outline-color: Highlight;
655
+ }
656
+ .cd-shell :is(.cd-shell-target, .cd-shell-menu-item)[aria-disabled=true] {
657
+ color: GrayText;
658
+ }
659
+ }
660
+ html.cd-shell-document,
661
+ html.cd-shell-document body {
662
+ height: 100%;
663
+ margin: 0;
664
+ padding: 0;
665
+ overflow: hidden;
666
+ color: var(--cd-ui-text);
667
+ font: 400 13px/1.5 var(--modeler-shell-font);
668
+ background: var(--cd-ui-grund);
669
+ }
670
+ html.cd-shell-document {
671
+ scrollbar-color: var(--cd-ui-kontur) transparent;
672
+ }
673
+ :where(html.cd-shell-document) :where(button, input, select, textarea) {
674
+ font: inherit;
675
+ color: inherit;
676
+ }
677
+ html.cd-shell-document code {
678
+ padding: 0;
679
+ color: inherit;
680
+ font-family: var(--modeler-shell-font-mono);
681
+ font-size: inherit;
682
+ background: transparent;
683
+ border-radius: 0;
684
+ }
685
+ html.cd-shell-document a,
686
+ html.cd-shell-document a:hover,
687
+ html.cd-shell-document a:visited {
688
+ color: var(--cd-ui-link);
689
+ }
690
+ html.cd-shell-document :where(a, input, select, textarea):focus {
691
+ outline: none;
692
+ }
693
+ html.cd-shell-document :where(a, input, select, textarea, button, summary):focus-visible {
694
+ outline: 2px solid var(--cd-ui-fokus);
695
+ outline-offset: 2px;
696
+ }
697
+ html.cd-shell-document[data-cd-kontrast=hoch] :where(a, input, select, textarea, button, summary):focus-visible {
698
+ outline-width: 3px;
699
+ }
700
+
701
+ /* src/diagram-js/palette.css */
702
+ .djs-palette[data-chrome=palette] {
703
+ --modeler-shell-palette-focus-width: 2px;
704
+ --modeler-shell-palette-focus-offset: 2px;
705
+ --modeler-shell-palette-focus-offset-pressed: 2px;
706
+ position: absolute;
707
+ top: var(--cd-shell-rand);
708
+ left: 50%;
709
+ z-index: 110;
710
+ display: flex;
711
+ align-items: center;
712
+ box-sizing: border-box;
713
+ width: auto;
714
+ height: var(--cd-shell-zeile);
715
+ padding: 3px;
716
+ border: 1px solid var(--cd-ui-linie);
717
+ border-radius: var(--cd-radius-md);
718
+ background: color-mix(in srgb, var(--cd-ui-flaeche-hoch) var(--cd-ui-chrome-deckkraft), transparent);
719
+ -webkit-backdrop-filter: blur(8px);
720
+ backdrop-filter: blur(8px);
721
+ box-shadow: var(--cd-shadow-1);
722
+ color: var(--cd-ui-text);
723
+ transform: translateX(-50%);
724
+ white-space: nowrap;
725
+ -webkit-user-select: none;
726
+ user-select: none;
727
+ }
728
+ .djs-palette[data-chrome=palette].two-column.open {
729
+ width: auto;
730
+ }
731
+ .djs-palette[data-chrome=palette] .djs-palette-toggle,
732
+ .djs-palette[data-chrome=palette] .djs-palette-entries::after {
733
+ display: none;
734
+ }
735
+ .djs-palette[data-chrome=palette] .djs-palette-entries,
736
+ .djs-palette[data-chrome=palette]:not(.open) .djs-palette-entries {
737
+ display: flex;
738
+ flex: none;
739
+ align-items: center;
740
+ }
741
+ .djs-palette[data-chrome=palette] .group {
742
+ position: relative;
743
+ display: flex;
744
+ flex: none;
745
+ align-items: center;
746
+ gap: 2px;
747
+ }
748
+ .djs-palette[data-chrome=palette] .group + .group {
749
+ margin-left: 8px;
750
+ padding-left: 9px;
751
+ }
752
+ .djs-palette[data-chrome=palette] .group + .group::before {
753
+ content: "";
754
+ position: absolute;
755
+ top: 4px;
756
+ bottom: 4px;
757
+ left: 0;
758
+ width: 1px;
759
+ background: var(--cd-ui-linie);
760
+ }
761
+ .djs-palette[data-chrome=palette] .separator {
762
+ flex: none;
763
+ align-self: stretch;
764
+ width: 1px;
765
+ height: auto;
766
+ margin: 4px 6px;
767
+ padding: 0;
768
+ border: 0;
769
+ background: var(--cd-ui-linie);
770
+ }
771
+ .djs-palette[data-chrome=palette] .entry {
772
+ position: relative;
773
+ display: flex;
774
+ flex: none;
775
+ align-items: center;
776
+ justify-content: center;
777
+ box-sizing: border-box;
778
+ width: var(--cd-shell-ziel);
779
+ height: var(--cd-shell-ziel);
780
+ margin: 0;
781
+ padding: 0;
782
+ float: none;
783
+ border: 0;
784
+ border-radius: var(--cd-radius-sm);
785
+ background: transparent;
786
+ color: var(--cd-ui-text);
787
+ font-size: 24px;
788
+ line-height: 1;
789
+ text-align: center;
790
+ cursor: default;
791
+ transition:
792
+ background-color var(--cd-motion-fast) var(--cd-ease),
793
+ color var(--cd-motion-fast) var(--cd-ease),
794
+ box-shadow var(--cd-motion-fast) var(--cd-ease);
795
+ }
796
+ .djs-palette[data-chrome=palette] .entry > img,
797
+ .djs-palette[data-chrome=palette] .entry > svg {
798
+ display: block;
799
+ flex: none;
800
+ max-width: 100%;
801
+ max-height: 100%;
802
+ }
803
+ .djs-palette[data-chrome=palette] .group[data-group=tools] .entry > svg,
804
+ .djs-palette[data-chrome=palette] .group[data-group=tools] .entry::before,
805
+ .djs-palette[data-chrome=palette] .entry[data-action$=-tool] > svg,
806
+ .djs-palette[data-chrome=palette] .entry[data-action$=-tool]::before {
807
+ color: inherit;
808
+ }
809
+ .djs-palette[data-chrome=palette] .entry:hover {
810
+ background: var(--cd-ui-hover);
811
+ color: var(--cd-ui-interaktion);
812
+ }
813
+ .djs-palette[data-chrome=palette] .entry.highlighted-entry {
814
+ color: var(--cd-ui-text) !important;
815
+ }
816
+ .djs-palette[data-chrome=palette] .entry.highlighted-entry:hover {
817
+ color: var(--cd-ui-interaktion) !important;
818
+ }
819
+ .djs-palette[data-chrome=palette] .entry[aria-pressed=true] {
820
+ background: var(--cd-ui-hover);
821
+ box-shadow: inset 0 0 0 2px var(--cd-ui-interaktion);
822
+ color: var(--cd-ui-text);
823
+ }
824
+ .djs-palette[data-chrome=palette] .entry[aria-pressed=true]:hover {
825
+ color: var(--cd-ui-interaktion);
826
+ }
827
+ .djs-palette[data-chrome=palette] .entry:focus {
828
+ outline: none;
829
+ }
830
+ .djs-palette[data-chrome=palette] .entry:focus-visible {
831
+ outline: var(--modeler-shell-palette-focus-width) solid var(--cd-ui-fokus);
832
+ outline-offset: var(--modeler-shell-palette-focus-offset);
833
+ }
834
+ .djs-palette[data-chrome=palette] .entry[aria-pressed=true]:focus-visible {
835
+ outline-offset: var(--modeler-shell-palette-focus-offset-pressed);
836
+ }
837
+ .djs-palette[data-chrome=palette] .entry[aria-disabled=true],
838
+ .djs-palette[data-chrome=palette] .entry[aria-disabled=true]:hover {
839
+ background: transparent;
840
+ color: var(--cd-ui-text-leise);
841
+ cursor: not-allowed;
842
+ }
843
+ .djs-palette[data-chrome=palette] .entry.highlighted-entry[aria-disabled=true] {
844
+ color: var(--cd-ui-text-leise) !important;
845
+ }
846
+ .djs-palette[data-chrome=palette] .entry[aria-disabled=true] > *,
847
+ .djs-palette[data-chrome=palette] .entry[aria-disabled=true]::before {
848
+ filter: grayscale(1);
849
+ }
850
+ [data-cd-kontrast=hoch] .djs-palette[data-chrome=palette] {
851
+ --modeler-shell-palette-focus-width: 3px;
852
+ box-shadow: none;
853
+ }
854
+ .cd-shell[data-palette=second-row] .djs-palette[data-chrome=palette] {
855
+ --modeler-shell-palette-focus-offset: calc(-1 * var(--modeler-shell-palette-focus-width));
856
+ --modeler-shell-palette-focus-offset-pressed: calc(-3px - var(--modeler-shell-palette-focus-width));
857
+ top: var(--cd-shell-frei);
858
+ max-width: calc(100cqw - 2 * var(--cd-shell-rand));
859
+ overflow-x: auto;
860
+ overflow-y: hidden;
861
+ overscroll-behavior-x: contain;
862
+ scrollbar-width: none;
863
+ }
864
+ .cd-shell[data-palette=second-row] .djs-palette[data-chrome=palette]::-webkit-scrollbar {
865
+ display: none;
866
+ }
867
+ @container cd-shell (max-width: 760px) {
868
+ .djs-palette[data-chrome=palette] {
869
+ --modeler-shell-palette-focus-offset: calc(-1 * var(--modeler-shell-palette-focus-width));
870
+ --modeler-shell-palette-focus-offset-pressed: calc(-3px - var(--modeler-shell-palette-focus-width));
871
+ top: var(--cd-shell-frei);
872
+ max-width: calc(100cqw - 2 * var(--cd-shell-rand));
873
+ overflow-x: auto;
874
+ overflow-y: hidden;
875
+ overscroll-behavior-x: contain;
876
+ scrollbar-width: none;
877
+ }
878
+ .djs-palette[data-chrome=palette]::-webkit-scrollbar {
879
+ display: none;
880
+ }
881
+ }
882
+ @media (forced-colors: active) {
883
+ .djs-palette[data-chrome=palette] {
884
+ border-color: CanvasText;
885
+ }
886
+ .djs-palette[data-chrome=palette] .group + .group::before,
887
+ .djs-palette[data-chrome=palette] .separator {
888
+ forced-color-adjust: none;
889
+ background: CanvasText;
890
+ }
891
+ .djs-palette[data-chrome=palette] .entry:focus-visible {
892
+ outline-color: Highlight;
893
+ }
894
+ .djs-palette[data-chrome=palette] .entry[aria-pressed=true],
895
+ .djs-palette[data-chrome=palette] .entry[aria-pressed=true]:hover {
896
+ forced-color-adjust: none;
897
+ background: Canvas;
898
+ color: CanvasText;
899
+ box-shadow: inset 0 0 0 2px Highlight;
900
+ }
901
+ .djs-palette[data-chrome=palette] .entry[aria-disabled=true] {
902
+ color: GrayText;
903
+ }
904
+ }
905
+ @media (prefers-reduced-motion: reduce) {
906
+ .djs-palette[data-chrome=palette] .entry {
907
+ transition: none;
908
+ }
909
+ }
910
+ html.cd-shell-reduce-motion .djs-palette[data-chrome=palette] .entry {
911
+ transition: none;
912
+ }
913
+
914
+ /* src/shell.css */