nexus-shared 2.0.0 → 3.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 (176) hide show
  1. package/CHANGELOG.md +446 -0
  2. package/LICENSE +21 -21
  3. package/README.md +1084 -903
  4. package/dist/Client.Index.d.ts +14 -0
  5. package/dist/Client.Index.js +14 -0
  6. package/dist/Components/Chats/Chat.d.ts +28 -0
  7. package/dist/Components/Chats/Chat.js +19 -0
  8. package/dist/Components/Chats/ChatButton.d.ts +26 -0
  9. package/dist/Components/Chats/ChatButton.js +41 -0
  10. package/dist/Components/Chats/ChatComposer.d.ts +41 -0
  11. package/dist/Components/Chats/ChatComposer.js +177 -0
  12. package/dist/Components/Chats/ChatConversations.d.ts +35 -0
  13. package/dist/Components/Chats/ChatConversations.js +38 -0
  14. package/dist/Components/Chats/ChatPanel.d.ts +66 -0
  15. package/dist/Components/Chats/ChatPanel.js +94 -0
  16. package/dist/Components/Chats/ChatParts.d.ts +87 -0
  17. package/dist/Components/Chats/ChatParts.js +96 -0
  18. package/dist/Components/Chats/ChatThread.d.ts +22 -0
  19. package/dist/Components/Chats/ChatThread.js +96 -0
  20. package/dist/Components/Documents/Button.d.ts +6 -1
  21. package/dist/Components/Documents/Button.js +2 -2
  22. package/dist/Components/Documents/Menu.js +44 -28
  23. package/dist/Components/Documents/SplitButton.d.ts +3 -1
  24. package/dist/Components/Documents/SplitButton.js +12 -8
  25. package/dist/Components/Documents/TabButtons.d.ts +29 -8
  26. package/dist/Components/Documents/TabButtons.js +24 -5
  27. package/dist/Components/Forms/ApiForm.d.ts +6 -4
  28. package/dist/Components/Forms/ApiForm.js +15 -14
  29. package/dist/Components/Forms/Crud.js +342 -71
  30. package/dist/Components/Forms/CrudParts.d.ts +5 -1
  31. package/dist/Components/Forms/CrudParts.js +37 -5
  32. package/dist/Components/Forms/ExcelImport.d.ts +58 -0
  33. package/dist/Components/Forms/ExcelImport.js +319 -0
  34. package/dist/Components/Forms/Form.js +9 -13
  35. package/dist/Components/Forms/SubmitForm.d.ts +11 -2
  36. package/dist/Components/Forms/SubmitForm.js +23 -12
  37. package/dist/Components/Inputs/DateTimePicker.js +2 -1
  38. package/dist/Components/Inputs/DropdownParts.d.ts +1 -1
  39. package/dist/Components/Inputs/DropdownParts.js +4 -6
  40. package/dist/Components/Inputs/GroupForm.js +4 -2
  41. package/dist/Components/Inputs/InputRenderer.d.ts +2 -0
  42. package/dist/Components/Inputs/InputRenderer.js +1 -1
  43. package/dist/Components/Inputs/NumberBox.js +24 -2
  44. package/dist/Components/Inputs/ReadOnlyNotice.js +2 -1
  45. package/dist/Components/Inputs/RowsInput.d.ts +12 -1
  46. package/dist/Components/Inputs/RowsInput.js +55 -6
  47. package/dist/Components/Inputs/Slider.js +4 -1
  48. package/dist/Components/Inputs/TabularForm.d.ts +7 -3
  49. package/dist/Components/Inputs/TabularForm.js +117 -20
  50. package/dist/Components/Inputs/TimePanel.js +4 -3
  51. package/dist/Components/Inputs/TimePicker.js +2 -1
  52. package/dist/Components/Layouts/Popup.js +1 -4
  53. package/dist/Components/Layouts/ThemePicker.d.ts +20 -3
  54. package/dist/Components/Layouts/ThemePicker.js +77 -6
  55. package/dist/Components/Layouts/ThemeScript.d.ts +4 -2
  56. package/dist/Components/Layouts/ThemeScript.js +4 -2
  57. package/dist/Components/Layouts/ThemeSwitcher.d.ts +6 -3
  58. package/dist/Components/Layouts/ThemeSwitcher.js +39 -18
  59. package/dist/Components/Viewers/Avatar.d.ts +21 -0
  60. package/dist/Components/Viewers/Avatar.js +21 -0
  61. package/dist/Components/Viewers/DataTable.js +262 -60
  62. package/dist/Components/Viewers/DataTableColumns.d.ts +32 -0
  63. package/dist/Components/Viewers/DataTableColumns.js +200 -0
  64. package/dist/Components/Viewers/DataTableFilters.d.ts +21 -0
  65. package/dist/Components/Viewers/DataTableFilters.js +68 -0
  66. package/dist/Components/Viewers/DataTableParts.d.ts +8 -4
  67. package/dist/Components/Viewers/DataTableParts.js +24 -12
  68. package/dist/Helpers/AnimationHelpers.d.ts +11 -0
  69. package/dist/Helpers/AnimationHelpers.js +20 -2
  70. package/dist/Helpers/ApiClient.d.ts +22 -0
  71. package/dist/Helpers/ApiClient.js +4 -1
  72. package/dist/Helpers/ApiFormHelpers.d.ts +27 -4
  73. package/dist/Helpers/ApiFormHelpers.js +73 -9
  74. package/dist/Helpers/ApiModules.d.ts +0 -4
  75. package/dist/Helpers/ApiModules.js +1 -0
  76. package/dist/Helpers/ApiResponses.d.ts +14 -4
  77. package/dist/Helpers/ApiResponses.js +116 -25
  78. package/dist/Helpers/ApiRoutes.d.ts +0 -10
  79. package/dist/Helpers/ApiRoutes.js +2 -10
  80. package/dist/Helpers/ChatBackend.d.ts +134 -0
  81. package/dist/Helpers/ChatBackend.js +332 -0
  82. package/dist/Helpers/ChatHelpers.d.ts +189 -0
  83. package/dist/Helpers/ChatHelpers.js +486 -0
  84. package/dist/Helpers/ChatHooks.d.ts +81 -0
  85. package/dist/Helpers/ChatHooks.js +175 -0
  86. package/dist/Helpers/ChatStore.d.ts +132 -0
  87. package/dist/Helpers/ChatStore.js +394 -0
  88. package/dist/Helpers/ChatSummaries.d.ts +39 -0
  89. package/dist/Helpers/ChatSummaries.js +118 -0
  90. package/dist/Helpers/CrudBackend.d.ts +54 -9
  91. package/dist/Helpers/CrudBackend.js +103 -6
  92. package/dist/Helpers/CrudHelpers.d.ts +39 -4
  93. package/dist/Helpers/CrudHelpers.js +76 -11
  94. package/dist/Helpers/ExcelBackend.d.ts +106 -0
  95. package/dist/Helpers/ExcelBackend.js +296 -0
  96. package/dist/Helpers/ExcelHelpers.d.ts +126 -0
  97. package/dist/Helpers/ExcelHelpers.js +344 -0
  98. package/dist/Helpers/FormStore.d.ts +11 -5
  99. package/dist/Helpers/FormStore.js +44 -6
  100. package/dist/Helpers/MessageBuilder.js +1 -2
  101. package/dist/Helpers/NumberHelpers.d.ts +7 -1
  102. package/dist/Helpers/NumberHelpers.js +41 -3
  103. package/dist/Helpers/PopoverHelpers.d.ts +46 -9
  104. package/dist/Helpers/PopoverHelpers.js +163 -24
  105. package/dist/Helpers/PopoverHooks.d.ts +24 -0
  106. package/dist/Helpers/PopoverHooks.js +62 -0
  107. package/dist/Helpers/RowsStore.d.ts +14 -3
  108. package/dist/Helpers/RowsStore.js +37 -3
  109. package/dist/Helpers/TableColumns.d.ts +7 -0
  110. package/dist/Helpers/TableColumns.js +41 -13
  111. package/dist/Helpers/TableExport.js +12 -12
  112. package/dist/Helpers/TableFilters.d.ts +25 -0
  113. package/dist/Helpers/TableFilters.js +162 -0
  114. package/dist/Helpers/TableHelpers.d.ts +15 -4
  115. package/dist/Helpers/TableHelpers.js +28 -4
  116. package/dist/Helpers/TableStore.d.ts +11 -3
  117. package/dist/Helpers/TableStore.js +16 -5
  118. package/dist/Helpers/ThemeHelpers.d.ts +21 -4
  119. package/dist/Helpers/ThemeHelpers.js +46 -9
  120. package/dist/Helpers/UserPreferences.d.ts +14 -0
  121. package/dist/Helpers/UserPreferences.js +99 -0
  122. package/dist/Interfaces/ApiInterfaces.d.ts +29 -4
  123. package/dist/Interfaces/ApiInterfaces.js +16 -10
  124. package/dist/Interfaces/ChatInterfaces.d.ts +240 -0
  125. package/dist/Interfaces/ChatInterfaces.js +1 -0
  126. package/dist/Interfaces/CrudInterfaces.d.ts +92 -12
  127. package/dist/Interfaces/ExcelInterfaces.d.ts +227 -0
  128. package/dist/Interfaces/ExcelInterfaces.js +45 -0
  129. package/dist/Interfaces/FormInterfaces.d.ts +85 -7
  130. package/dist/Interfaces/MessageInterfaces.d.ts +1 -1
  131. package/dist/Interfaces/PreferenceInterfaces.d.ts +43 -0
  132. package/dist/Interfaces/PreferenceInterfaces.js +28 -0
  133. package/dist/Interfaces/TableInterfaces.d.ts +116 -9
  134. package/dist/Interfaces/ThemeInterfaces.d.ts +25 -0
  135. package/dist/Interfaces/ThemeInterfaces.js +15 -0
  136. package/dist/Services/BrowserApi.d.ts +18 -1
  137. package/dist/Services/BrowserApi.js +18 -0
  138. package/dist/Services/ChatApi.d.ts +37 -0
  139. package/dist/Services/ChatApi.js +98 -0
  140. package/dist/Services/ExcelApi.d.ts +48 -0
  141. package/dist/Services/ExcelApi.js +196 -0
  142. package/dist/Services/ServerApi.d.ts +6 -1
  143. package/dist/Services/ServerApi.js +3 -0
  144. package/dist/Services/ThemeService.d.ts +18 -2
  145. package/dist/Services/ThemeService.js +80 -16
  146. package/dist/Shared.Index.d.ts +10 -0
  147. package/dist/Shared.Index.js +10 -0
  148. package/package.json +85 -82
  149. package/src/Styles/Nexus.Avatar.css +79 -0
  150. package/src/Styles/Nexus.Base.css +117 -70
  151. package/src/Styles/Nexus.Button.css +180 -151
  152. package/src/Styles/Nexus.Calendar.css +273 -275
  153. package/src/Styles/Nexus.Chat.css +1443 -0
  154. package/src/Styles/Nexus.Choice.css +343 -345
  155. package/src/Styles/Nexus.Crud.css +168 -84
  156. package/src/Styles/Nexus.DateTime.css +81 -81
  157. package/src/Styles/Nexus.Dropdown.css +725 -774
  158. package/src/Styles/Nexus.Editor.css +295 -297
  159. package/src/Styles/Nexus.Excel.css +389 -0
  160. package/src/Styles/Nexus.Form.css +279 -298
  161. package/src/Styles/Nexus.Index.css +37 -34
  162. package/src/Styles/Nexus.Input.css +602 -637
  163. package/src/Styles/Nexus.Markdown.css +237 -265
  164. package/src/Styles/Nexus.Menu.css +237 -249
  165. package/src/Styles/Nexus.Popup.css +724 -731
  166. package/src/Styles/Nexus.RichText.css +2 -32
  167. package/src/Styles/Nexus.Rows.css +637 -566
  168. package/src/Styles/Nexus.Slider.css +276 -278
  169. package/src/Styles/Nexus.Tab.Buttons.css +432 -364
  170. package/src/Styles/Nexus.Table.css +1386 -1014
  171. package/src/Styles/Nexus.Theme.Picker.css +286 -159
  172. package/src/Styles/Nexus.Themes.css +194 -194
  173. package/src/Styles/Nexus.Time.css +144 -147
  174. package/src/Styles/Nexus.Toast.css +263 -265
  175. package/src/Styles/Nexus.Tokens.css +89 -72
  176. package/src/Styles/Nexus.Tree.css +431 -435
@@ -1,297 +1,295 @@
1
- @layer nexus.components {
2
- /*
3
- * The frame of the Markdown and rich text editors (EditorShell.tsx): a field box holding a bar (views, formatting
4
- * buttons, full screen), a body with a height, and a status bar that is also the height handle. The box, label,
5
- * hint, error, and read-only and disabled states come from the field (Nexus.Input.css).
6
- */
7
- .nx-editor .nx-field__box {
8
- align-items: stretch;
9
- overflow: hidden;
10
- /* Narrow editors stack their parts (the bar, split views). */
11
- container: nx-editor / inline-size;
12
- }
13
-
14
- .nx-editor__frame {
15
- display: flex;
16
- flex: 1 1 auto;
17
- flex-direction: column;
18
- min-width: 0;
19
- }
20
-
21
- /* Bar */
22
- .nx-editor__bar {
23
- display: flex;
24
- flex-wrap: wrap;
25
- align-items: center;
26
- gap: 6px var(--nx-space-2);
27
- padding: 5px 6px;
28
- border-bottom: 1px solid var(--nx-border);
29
- }
30
-
31
- /* Views: small tab buttons with icons, the selected one with its label (TabButtons labels="selected"). */
32
- .nx-editor__modes {
33
- flex: 0 0 auto;
34
- }
35
-
36
- /* Formatting buttons */
37
- .nx-editor__tools {
38
- display: flex;
39
- flex-wrap: wrap;
40
- align-items: center;
41
- gap: 2px;
42
- min-width: 0;
43
- }
44
-
45
- .nx-editor__end {
46
- display: flex;
47
- align-items: center;
48
- gap: 2px;
49
- margin-left: auto;
50
- }
51
-
52
- .nx-editor__tool {
53
- display: grid;
54
- place-items: center;
55
- width: var(--nx-control-sm);
56
- height: var(--nx-control-sm);
57
- padding: 0;
58
- border: 0;
59
- border-radius: var(--nx-radius-sm);
60
- background: none;
61
- color: var(--nx-text-muted);
62
- cursor: pointer;
63
- transition:
64
- background-color var(--nx-duration),
65
- color var(--nx-duration);
66
- }
67
-
68
- .nx-editor__tool .nx-icon {
69
- width: 16px;
70
- height: 16px;
71
- vertical-align: 0;
72
- }
73
-
74
- .nx-editor__tool:hover:not(:disabled) {
75
- background: var(--nx-surface-hover);
76
- color: var(--nx-text);
77
- }
78
-
79
- .nx-editor__tool:active:not(:disabled) {
80
- background: color-mix(in oklab, var(--nx-surface-hover), var(--nx-text) 8%);
81
- }
82
-
83
- .nx-editor__tool:focus-visible {
84
- outline: 2px solid var(--nx-primary);
85
- outline-offset: -2px;
86
- }
87
-
88
- .nx-editor__tool[aria-pressed="true"] {
89
- color: var(--nx-primary);
90
- }
91
-
92
- .nx-editor__tool:disabled {
93
- cursor: not-allowed;
94
- }
95
-
96
- .nx-editor__divider {
97
- width: 1px;
98
- height: 16px;
99
- margin: 0 5px;
100
- background: var(--nx-border);
101
- }
102
-
103
- .nx-editor__bar .nx-field__lock {
104
- width: var(--nx-control-sm);
105
- height: var(--nx-control-sm);
106
- }
107
-
108
- .nx-editor__bar .nx-field__lock .nx-icon {
109
- width: 16px;
110
- height: 16px;
111
- }
112
-
113
- /* Body */
114
- .nx-editor__body {
115
- display: grid;
116
- grid-template-columns: minmax(0, 1fr);
117
- height: var(--nx-editor-height, 280px);
118
- }
119
-
120
- /*
121
- * Status bar and height handle. The whole bar drags, so the target is easy to hit; the grip in the middle is the
122
- * keyboard handle (a focusable separator) and turns to the primary color while the height changes.
123
- */
124
- .nx-editor__footer {
125
- position: relative;
126
- display: grid;
127
- grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
128
- align-items: center;
129
- gap: var(--nx-space-2);
130
- min-height: 26px;
131
- padding: 2px var(--nx-space-3);
132
- border-top: 1px solid var(--nx-border);
133
- color: var(--nx-text-muted);
134
- font-size: var(--nx-text-xs);
135
- line-height: 1.3;
136
- user-select: none;
137
- transition: background-color var(--nx-duration);
138
- }
139
-
140
- .nx-editor__footer[data-resizable] {
141
- cursor: ns-resize;
142
- touch-action: none;
143
- }
144
-
145
- .nx-field[data-disabled] .nx-editor__footer {
146
- cursor: not-allowed;
147
- }
148
-
149
- .nx-editor__footer[data-resizable]:hover,
150
- .nx-editor__footer[data-resizing] {
151
- background: color-mix(in oklab, var(--nx-text) 4%, transparent);
152
- }
153
-
154
- .nx-editor__hint {
155
- display: inline-flex;
156
- align-items: center;
157
- gap: 5px;
158
- min-width: 0;
159
- }
160
-
161
- .nx-editor__hint .nx-icon {
162
- flex-shrink: 0;
163
- width: 16px;
164
- height: 16px;
165
- vertical-align: 0;
166
- }
167
-
168
- .nx-editor__handle {
169
- position: relative;
170
- grid-column: 2;
171
- display: grid;
172
- place-items: center;
173
- width: 64px;
174
- height: 18px;
175
- border-radius: var(--nx-radius-full);
176
- outline: none;
177
- }
178
-
179
- .nx-editor__handle:focus-visible {
180
- box-shadow: var(--nx-focus-ring);
181
- }
182
-
183
- .nx-editor__grip {
184
- width: 36px;
185
- height: 4px;
186
- border-radius: var(--nx-radius-full);
187
- /* Muted, not subtle: the grip is the only sign of the handle, so it keeps 3:1 on the box in every theme. */
188
- background: var(--nx-text-muted);
189
- transition:
190
- width var(--nx-duration),
191
- background-color var(--nx-duration);
192
- }
193
-
194
- .nx-editor__footer[data-resizable]:hover .nx-editor__grip {
195
- width: 44px;
196
- background: var(--nx-text);
197
- }
198
-
199
- .nx-editor__footer[data-resizing] .nx-editor__grip,
200
- .nx-editor__handle:focus-visible .nx-editor__grip {
201
- width: 48px;
202
- background: var(--nx-primary);
203
- }
204
-
205
- /* The height while it changes, inverted like a tooltip, above the grip. */
206
- .nx-editor__size {
207
- position: absolute;
208
- bottom: calc(100% + 8px);
209
- left: 50%;
210
- padding: 3px 8px;
211
- border-radius: var(--nx-radius);
212
- background: var(--nx-text);
213
- color: var(--nx-surface);
214
- box-shadow: var(--nx-shadow);
215
- font-size: var(--nx-text-xs);
216
- font-weight: 500;
217
- font-variant-numeric: tabular-nums;
218
- white-space: nowrap;
219
- opacity: 0;
220
- transform: translateX(-50%);
221
- transition: opacity var(--nx-duration);
222
- pointer-events: none;
223
- }
224
-
225
- .nx-editor__footer[data-resizing] .nx-editor__size {
226
- opacity: 1;
227
- }
228
-
229
- .nx-editor__count {
230
- grid-column: 3;
231
- min-width: 0;
232
- overflow: hidden;
233
- font-variant-numeric: tabular-nums;
234
- text-align: right;
235
- text-overflow: ellipsis;
236
- white-space: nowrap;
237
- }
238
-
239
- /*
240
- * Narrow: full screen and the lock stay on the row of the views, the buttons take a row of their own, and the
241
- * status bar keeps the icon and the characters, so nothing runs into the grip.
242
- */
243
- @container nx-editor (width < 560px) {
244
- .nx-editor__end {
245
- order: 1;
246
- }
247
-
248
- .nx-editor__tools {
249
- flex-basis: 100%;
250
- order: 2;
251
- }
252
-
253
- .nx-editor__hint > span,
254
- .nx-editor__words {
255
- display: none;
256
- }
257
- }
258
-
259
- /* Full screen: the box in the top layer, over a dimmed page. */
260
- .nx-editor .nx-field__box:popover-open {
261
- position: fixed;
262
- inset: var(--nx-space-6);
263
- width: auto;
264
- max-width: 1440px;
265
- height: auto;
266
- margin: auto;
267
- padding: 0;
268
- color: var(--nx-text);
269
- box-shadow: var(--nx-shadow);
270
- }
271
-
272
- .nx-editor .nx-field__box::backdrop {
273
- background: rgb(0 0 0 / 0.5);
274
- }
275
-
276
- .nx-editor .nx-field__box:popover-open .nx-editor__body {
277
- flex: 1 1 auto;
278
- height: auto;
279
- min-height: 0;
280
- }
281
-
282
- @media (width < 640px) {
283
- .nx-editor .nx-field__box:popover-open {
284
- inset: 0;
285
- border: 0;
286
- border-radius: 0;
287
- }
288
- }
289
-
290
- @media (prefers-reduced-motion: reduce) {
291
- .nx-editor__grip,
292
- .nx-editor__size,
293
- .nx-editor__footer {
294
- transition: none;
295
- }
296
- }
297
- }
1
+ @layer nexus.components {
2
+ /*
3
+ * The frame of the Markdown and rich text editors (EditorShell.tsx): a field box holding a bar (views, formatting
4
+ * buttons, full screen), a body with a height, and a status bar that is also the height handle. The box, label,
5
+ * hint, error, and read-only and disabled states come from the field (Nexus.Input.css).
6
+ */
7
+ .nx-editor .nx-field__box {
8
+ align-items: stretch;
9
+ overflow: hidden;
10
+ /* Narrow editors stack their parts (the bar, split views). */
11
+ container: nx-editor / inline-size;
12
+ }
13
+
14
+ .nx-editor__frame {
15
+ display: flex;
16
+ flex: 1 1 auto;
17
+ flex-direction: column;
18
+ min-width: 0;
19
+ }
20
+
21
+ /* Bar */
22
+ .nx-editor__bar {
23
+ display: flex;
24
+ flex-wrap: wrap;
25
+ align-items: center;
26
+ gap: 6px var(--nx-space-2);
27
+ padding: 5px 6px;
28
+ border-bottom: 1px solid var(--nx-border);
29
+ }
30
+
31
+ /* Views: small tab buttons with icons, the selected one with its label (TabButtons labels="selected"). */
32
+ .nx-editor__modes {
33
+ flex: 0 0 auto;
34
+ }
35
+
36
+ /* Formatting buttons */
37
+ .nx-editor__tools {
38
+ display: flex;
39
+ flex-wrap: wrap;
40
+ align-items: center;
41
+ gap: 2px;
42
+ min-width: 0;
43
+ }
44
+
45
+ .nx-editor__end {
46
+ display: flex;
47
+ align-items: center;
48
+ gap: 2px;
49
+ margin-left: auto;
50
+ }
51
+
52
+ .nx-editor__tool {
53
+ display: grid;
54
+ place-items: center;
55
+ width: var(--nx-control-sm);
56
+ height: var(--nx-control-sm);
57
+ padding: 0;
58
+ border: 0;
59
+ border-radius: var(--nx-radius-sm);
60
+ background: none;
61
+ color: var(--nx-text-muted);
62
+ cursor: pointer;
63
+ transition:
64
+ background-color var(--nx-duration),
65
+ color var(--nx-duration);
66
+ }
67
+
68
+ .nx-editor__tool .nx-icon {
69
+ width: 16px;
70
+ height: 16px;
71
+ vertical-align: 0;
72
+ }
73
+
74
+ .nx-editor__tool:hover:not(:disabled) {
75
+ background: var(--nx-surface-hover);
76
+ color: var(--nx-text);
77
+ }
78
+
79
+ .nx-editor__tool:active:not(:disabled) {
80
+ background: color-mix(in oklab, var(--nx-surface-hover), var(--nx-text) 8%);
81
+ }
82
+
83
+ .nx-editor__tool:focus-visible {
84
+ outline: 2px solid var(--nx-primary);
85
+ outline-offset: -2px;
86
+ }
87
+
88
+ .nx-editor__tool[aria-pressed="true"] {
89
+ color: var(--nx-primary);
90
+ }
91
+
92
+ .nx-editor__tool:disabled {
93
+ cursor: not-allowed;
94
+ }
95
+
96
+ .nx-editor__divider {
97
+ width: 1px;
98
+ height: 16px;
99
+ margin: 0 5px;
100
+ background: var(--nx-border);
101
+ }
102
+
103
+ .nx-editor__bar .nx-field__lock {
104
+ width: var(--nx-control-sm);
105
+ height: var(--nx-control-sm);
106
+ }
107
+
108
+ .nx-editor__bar .nx-field__lock .nx-icon {
109
+ width: 16px;
110
+ height: 16px;
111
+ }
112
+
113
+ /* Body */
114
+ .nx-editor__body {
115
+ display: grid;
116
+ grid-template-columns: minmax(0, 1fr);
117
+ height: var(--nx-editor-height, 280px);
118
+ }
119
+
120
+ /*
121
+ * Status bar and height handle. The whole bar drags, so the target is easy to hit; the grip in the middle is the
122
+ * keyboard handle (a focusable separator) and turns to the primary color while the height changes.
123
+ */
124
+ .nx-editor__footer {
125
+ position: relative;
126
+ display: grid;
127
+ grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
128
+ align-items: center;
129
+ gap: var(--nx-space-2);
130
+ min-height: 26px;
131
+ padding: 2px var(--nx-space-3);
132
+ border-top: 1px solid var(--nx-border);
133
+ color: var(--nx-text-muted);
134
+ font-size: var(--nx-text-xs);
135
+ line-height: 1.3;
136
+ user-select: none;
137
+ transition: background-color var(--nx-duration);
138
+ }
139
+
140
+ .nx-editor__footer[data-resizable] {
141
+ cursor: ns-resize;
142
+ touch-action: none;
143
+ }
144
+
145
+ .nx-field[data-disabled] .nx-editor__footer {
146
+ cursor: not-allowed;
147
+ }
148
+
149
+ .nx-editor__footer[data-resizable]:hover,
150
+ .nx-editor__footer[data-resizing] {
151
+ background: color-mix(in oklab, var(--nx-text) 4%, transparent);
152
+ }
153
+
154
+ .nx-editor__hint {
155
+ display: inline-flex;
156
+ align-items: center;
157
+ gap: 5px;
158
+ min-width: 0;
159
+ }
160
+
161
+ .nx-editor__hint .nx-icon {
162
+ flex-shrink: 0;
163
+ width: 16px;
164
+ height: 16px;
165
+ vertical-align: 0;
166
+ }
167
+
168
+ .nx-editor__handle {
169
+ position: relative;
170
+ grid-column: 2;
171
+ display: grid;
172
+ place-items: center;
173
+ width: 64px;
174
+ height: 18px;
175
+ border-radius: var(--nx-radius-full);
176
+ outline: none;
177
+ }
178
+
179
+ .nx-editor__handle:focus-visible {
180
+ box-shadow: var(--nx-focus-ring);
181
+ }
182
+
183
+ .nx-editor__grip {
184
+ width: 36px;
185
+ height: 4px;
186
+ border-radius: var(--nx-radius-full);
187
+ /* Muted, not subtle: the grip is the only sign of the handle, so it keeps 3:1 on the box in every theme. */
188
+ background: var(--nx-text-muted);
189
+ transition:
190
+ width var(--nx-duration),
191
+ background-color var(--nx-duration);
192
+ }
193
+
194
+ .nx-editor__footer[data-resizable]:hover .nx-editor__grip {
195
+ width: 44px;
196
+ background: var(--nx-text);
197
+ }
198
+
199
+ .nx-editor__footer[data-resizing] .nx-editor__grip,
200
+ .nx-editor__handle:focus-visible .nx-editor__grip {
201
+ width: 48px;
202
+ background: var(--nx-primary);
203
+ }
204
+
205
+ /* The height while it changes, inverted like a tooltip, above the grip. */
206
+ .nx-editor__size {
207
+ position: absolute;
208
+ bottom: calc(100% + 8px);
209
+ left: 50%;
210
+ padding: 3px 8px;
211
+ border-radius: var(--nx-radius);
212
+ background: var(--nx-text);
213
+ color: var(--nx-surface);
214
+ box-shadow: var(--nx-shadow);
215
+ font-size: var(--nx-text-xs);
216
+ font-weight: 500;
217
+ font-variant-numeric: tabular-nums;
218
+ white-space: nowrap;
219
+ opacity: 0;
220
+ transform: translateX(-50%);
221
+ transition: opacity var(--nx-duration);
222
+ pointer-events: none;
223
+ }
224
+
225
+ .nx-editor__footer[data-resizing] .nx-editor__size {
226
+ opacity: 1;
227
+ }
228
+
229
+ .nx-editor__count {
230
+ grid-column: 3;
231
+ min-width: 0;
232
+ overflow: hidden;
233
+ font-variant-numeric: tabular-nums;
234
+ text-align: right;
235
+ text-overflow: ellipsis;
236
+ white-space: nowrap;
237
+ }
238
+
239
+ /*
240
+ * Narrow: full screen and the lock stay on the row of the views, the buttons take a row of their own, and the
241
+ * status bar keeps the icon and the characters, so nothing runs into the grip.
242
+ */
243
+ @container nx-editor (width < 560px) {
244
+ .nx-editor__end {
245
+ order: 1;
246
+ }
247
+
248
+ .nx-editor__tools {
249
+ flex-basis: 100%;
250
+ order: 2;
251
+ }
252
+
253
+ .nx-editor__hint > span,
254
+ .nx-editor__words {
255
+ display: none;
256
+ }
257
+ }
258
+
259
+ /* Full screen: the box in the top layer, over a dimmed page. */
260
+ .nx-editor .nx-field__box:popover-open {
261
+ position: fixed;
262
+ inset: var(--nx-space-6);
263
+ width: auto;
264
+ max-width: 1440px;
265
+ height: auto;
266
+ margin: auto;
267
+ padding: 0;
268
+ color: var(--nx-text);
269
+ box-shadow: var(--nx-shadow);
270
+ }
271
+
272
+ .nx-editor .nx-field__box::backdrop {
273
+ background: rgb(0 0 0 / 0.5);
274
+ }
275
+
276
+ .nx-editor .nx-field__box:popover-open .nx-editor__body {
277
+ flex: 1 1 auto;
278
+ height: auto;
279
+ min-height: 0;
280
+ }
281
+
282
+ @media (width < 640px) {
283
+ .nx-editor .nx-field__box:popover-open {
284
+ inset: 0;
285
+ border: 0;
286
+ border-radius: 0;
287
+ }
288
+ }
289
+
290
+ [data-nx-motion="reduce"] .nx-editor__grip,
291
+ [data-nx-motion="reduce"] .nx-editor__size,
292
+ [data-nx-motion="reduce"] .nx-editor__footer {
293
+ transition: none;
294
+ }
295
+ }