nexus-shared 3.1.0 → 3.2.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/CHANGELOG.md +704 -446
- package/LICENSE +21 -21
- package/README.md +44 -5
- package/dist/Client.Index.d.ts +3 -0
- package/dist/Client.Index.js +3 -0
- package/dist/Components/Forms/Crud.js +322 -161
- package/dist/Components/Forms/CrudHistory.d.ts +66 -0
- package/dist/Components/Forms/CrudHistory.js +140 -0
- package/dist/Components/Forms/CrudParts.js +2 -1
- package/dist/Components/Forms/Form.js +4 -1
- package/dist/Components/Inputs/CodeBox.d.ts +69 -0
- package/dist/Components/Inputs/CodeBox.js +316 -0
- package/dist/Components/Inputs/DatePicker.js +4 -1
- package/dist/Components/Inputs/DateRangePicker.js +4 -1
- package/dist/Components/Inputs/DateTimePicker.js +4 -1
- package/dist/Components/Inputs/Dropdown.js +4 -1
- package/dist/Components/Inputs/InputRenderer.js +3 -0
- package/dist/Components/Inputs/NumberBox.js +4 -2
- package/dist/Components/Inputs/TextArea.js +4 -1
- package/dist/Components/Inputs/TextBox.js +4 -1
- package/dist/Components/Inputs/TimePicker.js +4 -1
- package/dist/Components/Inputs/TreeView.d.ts +55 -5
- package/dist/Components/Inputs/TreeView.js +372 -23
- package/dist/Components/Layouts/ThemePicker.d.ts +3 -2
- package/dist/Components/Layouts/ThemePicker.js +16 -4
- package/dist/Components/Viewers/DataTable.js +63 -21
- package/dist/Components/Viewers/DataTableParts.d.ts +26 -8
- package/dist/Components/Viewers/DataTableParts.js +39 -10
- package/dist/Helpers/ApiModules.d.ts +3 -34
- package/dist/Helpers/ApiModules.js +3 -3
- package/dist/Helpers/ApiRoutes.d.ts +68 -26
- package/dist/Helpers/ApiRoutes.js +31 -27
- package/dist/Helpers/ArrayHelpers.d.ts +0 -0
- package/dist/Helpers/ArrayHelpers.js +2 -0
- package/dist/Helpers/CodeHelpers.d.ts +97 -0
- package/dist/Helpers/CodeHelpers.js +332 -0
- package/dist/Helpers/CrudBackend.d.ts +94 -4
- package/dist/Helpers/CrudBackend.js +168 -9
- package/dist/Helpers/CrudColumns.d.ts +51 -0
- package/dist/Helpers/CrudColumns.js +69 -0
- package/dist/Helpers/CrudHelpers.d.ts +50 -5
- package/dist/Helpers/CrudHelpers.js +109 -12
- package/dist/Helpers/InputParamsHelpers.js +8 -0
- package/dist/Helpers/MessageBuilder.js +2 -0
- package/dist/Helpers/NexusHelpers.d.ts +0 -0
- package/dist/Helpers/NexusHelpers.js +1 -0
- package/dist/Helpers/RequestCache.d.ts +35 -0
- package/dist/Helpers/RequestCache.js +113 -0
- package/dist/Helpers/TableExport.js +12 -12
- package/dist/Helpers/TableHelpers.d.ts +1 -1
- package/dist/Helpers/TableHelpers.js +7 -2
- package/dist/Helpers/TableJoins.d.ts +70 -0
- package/dist/Helpers/TableJoins.js +250 -0
- package/dist/Helpers/TableStore.d.ts +5 -0
- package/dist/Helpers/TableStore.js +9 -0
- package/dist/Helpers/TreeStore.d.ts +225 -11
- package/dist/Helpers/TreeStore.js +683 -90
- package/dist/Helpers/UserPreferences.d.ts +8 -0
- package/dist/Helpers/UserPreferences.js +17 -0
- package/dist/Interfaces/CrudInterfaces.d.ts +47 -9
- package/dist/Interfaces/FormInterfaces.d.ts +4 -1
- package/dist/Interfaces/InputInterfaces.d.ts +24 -0
- package/dist/Interfaces/MessageInterfaces.d.ts +1 -1
- package/dist/Interfaces/PreferenceInterfaces.d.ts +8 -0
- package/dist/Interfaces/PreferenceInterfaces.js +2 -5
- package/dist/Interfaces/TableInterfaces.d.ts +86 -4
- package/dist/Services/ApiProxy.d.ts +36 -1
- package/dist/Services/ApiProxy.js +182 -52
- package/dist/Services/ApiProxyRules.d.ts +203 -0
- package/dist/Services/ApiProxyRules.js +426 -0
- package/dist/Services/JoinSources.d.ts +48 -0
- package/dist/Services/JoinSources.js +74 -0
- package/dist/Services/ServerApi.d.ts +13 -2
- package/dist/Services/ServerApi.js +8 -3
- package/dist/Shared.Index.d.ts +4 -0
- package/dist/Shared.Index.js +4 -0
- package/package.json +87 -85
- package/src/Styles/Nexus.Avatar.css +79 -79
- package/src/Styles/Nexus.Base.css +117 -117
- package/src/Styles/Nexus.Button.css +180 -180
- package/src/Styles/Nexus.Calendar.css +273 -273
- package/src/Styles/Nexus.Chat.css +1443 -1443
- package/src/Styles/Nexus.Choice.css +343 -343
- package/src/Styles/Nexus.Crud.css +168 -168
- package/src/Styles/Nexus.DateTime.css +81 -81
- package/src/Styles/Nexus.Dropdown.css +725 -725
- package/src/Styles/Nexus.Editor.css +295 -295
- package/src/Styles/Nexus.Excel.css +389 -389
- package/src/Styles/Nexus.Form.css +279 -279
- package/src/Styles/Nexus.Index.css +37 -37
- package/src/Styles/Nexus.Input.css +196 -4
- package/src/Styles/Nexus.Markdown.css +237 -237
- package/src/Styles/Nexus.Menu.css +237 -237
- package/src/Styles/Nexus.Popup.css +724 -724
- package/src/Styles/Nexus.Rows.css +637 -637
- package/src/Styles/Nexus.Slider.css +276 -276
- package/src/Styles/Nexus.Tab.Buttons.css +432 -432
- package/src/Styles/Nexus.Table.css +31 -30
- package/src/Styles/Nexus.Theme.Picker.css +59 -3
- package/src/Styles/Nexus.Themes.css +194 -194
- package/src/Styles/Nexus.Time.css +144 -144
- package/src/Styles/Nexus.Toast.css +263 -263
- package/src/Styles/Nexus.Tokens.css +89 -89
- package/src/Styles/Nexus.Tree.css +500 -431
|
@@ -1,263 +1,263 @@
|
|
|
1
|
-
@layer nexus.components {
|
|
2
|
-
/*
|
|
3
|
-
* Toasts: each one is a manual popover, fixed at its edge and stacked by --nx-toast-offset (set by the Toaster).
|
|
4
|
-
* The panel is raised like a popover; the tone shows in the icon and in the progress line along the bottom edge,
|
|
5
|
-
* which pauses while the pointer or the focus is on the toast.
|
|
6
|
-
*/
|
|
7
|
-
.nx-toaster {
|
|
8
|
-
display: contents;
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
.nx-toast {
|
|
12
|
-
--nx-toast-accent: var(--nx-primary);
|
|
13
|
-
--nx-toast-offset: 0px;
|
|
14
|
-
--nx-toast-edge: 16px;
|
|
15
|
-
|
|
16
|
-
position: fixed;
|
|
17
|
-
inset: auto;
|
|
18
|
-
display: flex;
|
|
19
|
-
align-items: flex-start;
|
|
20
|
-
gap: 10px;
|
|
21
|
-
width: min(360px, calc(100% - 2 * var(--nx-toast-edge)));
|
|
22
|
-
margin: 0;
|
|
23
|
-
padding: 12px 12px 12px 14px;
|
|
24
|
-
overflow: hidden;
|
|
25
|
-
border: 1px solid var(--nx-border);
|
|
26
|
-
border-radius: var(--nx-radius-lg);
|
|
27
|
-
background: light-dark(var(--nx-surface), var(--nx-surface-2));
|
|
28
|
-
color: var(--nx-text);
|
|
29
|
-
font-size: var(--nx-text-md);
|
|
30
|
-
box-shadow: var(--nx-shadow);
|
|
31
|
-
pointer-events: auto;
|
|
32
|
-
transition:
|
|
33
|
-
top 220ms cubic-bezier(0.2, 0, 0, 1),
|
|
34
|
-
bottom 220ms cubic-bezier(0.2, 0, 0, 1);
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
.nx-toast:popover-open {
|
|
38
|
-
animation: nx-toast-in 220ms cubic-bezier(0.2, 0, 0, 1);
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
.nx-toast--closing:popover-open {
|
|
42
|
-
animation: nx-toast-out 180ms ease-in forwards;
|
|
43
|
-
pointer-events: none;
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
/* Positions: the offset counts from the chosen edge, newest nearest to it. */
|
|
47
|
-
.nx-toast--top-right,
|
|
48
|
-
.nx-toast--top-center,
|
|
49
|
-
.nx-toast--top-left {
|
|
50
|
-
top: calc(var(--nx-toast-edge) + var(--nx-toast-offset));
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
.nx-toast--bottom-right,
|
|
54
|
-
.nx-toast--bottom-center,
|
|
55
|
-
.nx-toast--bottom-left {
|
|
56
|
-
bottom: calc(var(--nx-toast-edge) + var(--nx-toast-offset));
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
.nx-toast--top-right,
|
|
60
|
-
.nx-toast--bottom-right {
|
|
61
|
-
right: var(--nx-toast-edge);
|
|
62
|
-
}
|
|
63
|
-
|
|
64
|
-
/* Minimized popups wait at the bottom right; toasts there stack above them (the dock sets --nx-dock-space). */
|
|
65
|
-
.nx-toast--bottom-right {
|
|
66
|
-
bottom: calc(var(--nx-toast-edge) + var(--nx-toast-offset) + var(--nx-dock-space, 0px));
|
|
67
|
-
}
|
|
68
|
-
|
|
69
|
-
.nx-toast--top-left,
|
|
70
|
-
.nx-toast--bottom-left {
|
|
71
|
-
left: var(--nx-toast-edge);
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
.nx-toast--top-center,
|
|
75
|
-
.nx-toast--bottom-center {
|
|
76
|
-
left: 50%;
|
|
77
|
-
translate: -50% 0;
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
@keyframes nx-toast-in {
|
|
81
|
-
from {
|
|
82
|
-
opacity: 0;
|
|
83
|
-
transform: translateY(-8px) scale(0.98);
|
|
84
|
-
}
|
|
85
|
-
}
|
|
86
|
-
|
|
87
|
-
.nx-toast--bottom-right:popover-open,
|
|
88
|
-
.nx-toast--bottom-center:popover-open,
|
|
89
|
-
.nx-toast--bottom-left:popover-open {
|
|
90
|
-
animation-name: nx-toast-in-up;
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
@keyframes nx-toast-in-up {
|
|
94
|
-
from {
|
|
95
|
-
opacity: 0;
|
|
96
|
-
transform: translateY(8px) scale(0.98);
|
|
97
|
-
}
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
@keyframes nx-toast-out {
|
|
101
|
-
to {
|
|
102
|
-
opacity: 0;
|
|
103
|
-
transform: scale(0.96);
|
|
104
|
-
}
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
.nx-toast--closing.nx-toast--bottom-right:popover-open,
|
|
108
|
-
.nx-toast--closing.nx-toast--bottom-center:popover-open,
|
|
109
|
-
.nx-toast--closing.nx-toast--bottom-left:popover-open {
|
|
110
|
-
animation-name: nx-toast-out;
|
|
111
|
-
}
|
|
112
|
-
|
|
113
|
-
/* Tones */
|
|
114
|
-
.nx-toast--info {
|
|
115
|
-
--nx-toast-accent: var(--nx-info);
|
|
116
|
-
}
|
|
117
|
-
|
|
118
|
-
.nx-toast--success {
|
|
119
|
-
--nx-toast-accent: var(--nx-success);
|
|
120
|
-
}
|
|
121
|
-
|
|
122
|
-
.nx-toast--warning {
|
|
123
|
-
--nx-toast-accent: var(--nx-warning);
|
|
124
|
-
}
|
|
125
|
-
|
|
126
|
-
.nx-toast--danger {
|
|
127
|
-
--nx-toast-accent: var(--nx-danger);
|
|
128
|
-
}
|
|
129
|
-
|
|
130
|
-
.nx-toast__icon {
|
|
131
|
-
display: grid;
|
|
132
|
-
flex-shrink: 0;
|
|
133
|
-
place-items: center;
|
|
134
|
-
width: 20px;
|
|
135
|
-
height: 20px;
|
|
136
|
-
margin-top: 1px;
|
|
137
|
-
color: var(--nx-toast-accent);
|
|
138
|
-
}
|
|
139
|
-
|
|
140
|
-
.nx-toast__icon .nx-icon {
|
|
141
|
-
width: 20px;
|
|
142
|
-
height: 20px;
|
|
143
|
-
vertical-align: 0;
|
|
144
|
-
}
|
|
145
|
-
|
|
146
|
-
.nx-toast--neutral .nx-toast__icon {
|
|
147
|
-
color: var(--nx-text-muted);
|
|
148
|
-
}
|
|
149
|
-
|
|
150
|
-
.nx-toast__body {
|
|
151
|
-
flex: 1 1 auto;
|
|
152
|
-
min-width: 0;
|
|
153
|
-
padding-top: 1px;
|
|
154
|
-
}
|
|
155
|
-
|
|
156
|
-
.nx-toast__title {
|
|
157
|
-
font-weight: 600;
|
|
158
|
-
line-height: 1.35;
|
|
159
|
-
overflow-wrap: anywhere;
|
|
160
|
-
}
|
|
161
|
-
|
|
162
|
-
.nx-toast__message {
|
|
163
|
-
margin-top: 2px;
|
|
164
|
-
color: var(--nx-text-muted);
|
|
165
|
-
font-size: var(--nx-text-sm);
|
|
166
|
-
line-height: 1.45;
|
|
167
|
-
overflow-wrap: anywhere;
|
|
168
|
-
}
|
|
169
|
-
|
|
170
|
-
.nx-toast__action {
|
|
171
|
-
flex-shrink: 0;
|
|
172
|
-
align-self: center;
|
|
173
|
-
height: 28px;
|
|
174
|
-
margin: 0;
|
|
175
|
-
padding: 0 10px;
|
|
176
|
-
border: 1px solid var(--nx-border-strong);
|
|
177
|
-
border-radius: var(--nx-radius);
|
|
178
|
-
background: var(--nx-surface);
|
|
179
|
-
color: var(--nx-text);
|
|
180
|
-
font: inherit;
|
|
181
|
-
font-size: var(--nx-text-sm);
|
|
182
|
-
font-weight: 500;
|
|
183
|
-
white-space: nowrap;
|
|
184
|
-
cursor: pointer;
|
|
185
|
-
}
|
|
186
|
-
|
|
187
|
-
.nx-toast__action:hover {
|
|
188
|
-
border-color: var(--nx-toast-accent);
|
|
189
|
-
color: var(--nx-toast-accent);
|
|
190
|
-
}
|
|
191
|
-
|
|
192
|
-
.nx-toast__action:focus-visible {
|
|
193
|
-
outline: none;
|
|
194
|
-
box-shadow: var(--nx-focus-ring);
|
|
195
|
-
}
|
|
196
|
-
|
|
197
|
-
.nx-toast__close {
|
|
198
|
-
display: grid;
|
|
199
|
-
flex-shrink: 0;
|
|
200
|
-
place-items: center;
|
|
201
|
-
width: 24px;
|
|
202
|
-
height: 24px;
|
|
203
|
-
margin: -2px -2px 0 0;
|
|
204
|
-
padding: 0;
|
|
205
|
-
border: 0;
|
|
206
|
-
border-radius: var(--nx-radius-sm);
|
|
207
|
-
background: none;
|
|
208
|
-
color: var(--nx-text-subtle);
|
|
209
|
-
cursor: pointer;
|
|
210
|
-
}
|
|
211
|
-
|
|
212
|
-
.nx-toast__close:hover {
|
|
213
|
-
background: var(--nx-surface-hover);
|
|
214
|
-
color: var(--nx-text);
|
|
215
|
-
}
|
|
216
|
-
|
|
217
|
-
.nx-toast__close:focus-visible {
|
|
218
|
-
outline: none;
|
|
219
|
-
box-shadow: var(--nx-focus-ring);
|
|
220
|
-
}
|
|
221
|
-
|
|
222
|
-
.nx-toast__close .nx-icon {
|
|
223
|
-
width: 16px;
|
|
224
|
-
height: 16px;
|
|
225
|
-
vertical-align: 0;
|
|
226
|
-
}
|
|
227
|
-
|
|
228
|
-
/* The time left, shrinking along the bottom edge; its end closes the toast. */
|
|
229
|
-
.nx-toast__progress {
|
|
230
|
-
position: absolute;
|
|
231
|
-
right: 0;
|
|
232
|
-
bottom: 0;
|
|
233
|
-
left: 0;
|
|
234
|
-
height: 3px;
|
|
235
|
-
background: var(--nx-toast-accent);
|
|
236
|
-
opacity: 0.7;
|
|
237
|
-
transform-origin: left;
|
|
238
|
-
animation: nx-toast-progress linear forwards;
|
|
239
|
-
}
|
|
240
|
-
|
|
241
|
-
.nx-toast:is(:hover, :focus-within) .nx-toast__progress {
|
|
242
|
-
animation-play-state: paused;
|
|
243
|
-
}
|
|
244
|
-
|
|
245
|
-
@keyframes nx-toast-progress {
|
|
246
|
-
from {
|
|
247
|
-
transform: scaleX(1);
|
|
248
|
-
}
|
|
249
|
-
|
|
250
|
-
to {
|
|
251
|
-
transform: scaleX(0);
|
|
252
|
-
}
|
|
253
|
-
}
|
|
254
|
-
|
|
255
|
-
[data-nx-motion="reduce"] .nx-toast {
|
|
256
|
-
transition: none;
|
|
257
|
-
}
|
|
258
|
-
|
|
259
|
-
[data-nx-motion="reduce"] .nx-toast:popover-open,
|
|
260
|
-
[data-nx-motion="reduce"] .nx-toast--closing:popover-open {
|
|
261
|
-
animation: none;
|
|
262
|
-
}
|
|
263
|
-
}
|
|
1
|
+
@layer nexus.components {
|
|
2
|
+
/*
|
|
3
|
+
* Toasts: each one is a manual popover, fixed at its edge and stacked by --nx-toast-offset (set by the Toaster).
|
|
4
|
+
* The panel is raised like a popover; the tone shows in the icon and in the progress line along the bottom edge,
|
|
5
|
+
* which pauses while the pointer or the focus is on the toast.
|
|
6
|
+
*/
|
|
7
|
+
.nx-toaster {
|
|
8
|
+
display: contents;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
.nx-toast {
|
|
12
|
+
--nx-toast-accent: var(--nx-primary);
|
|
13
|
+
--nx-toast-offset: 0px;
|
|
14
|
+
--nx-toast-edge: 16px;
|
|
15
|
+
|
|
16
|
+
position: fixed;
|
|
17
|
+
inset: auto;
|
|
18
|
+
display: flex;
|
|
19
|
+
align-items: flex-start;
|
|
20
|
+
gap: 10px;
|
|
21
|
+
width: min(360px, calc(100% - 2 * var(--nx-toast-edge)));
|
|
22
|
+
margin: 0;
|
|
23
|
+
padding: 12px 12px 12px 14px;
|
|
24
|
+
overflow: hidden;
|
|
25
|
+
border: 1px solid var(--nx-border);
|
|
26
|
+
border-radius: var(--nx-radius-lg);
|
|
27
|
+
background: light-dark(var(--nx-surface), var(--nx-surface-2));
|
|
28
|
+
color: var(--nx-text);
|
|
29
|
+
font-size: var(--nx-text-md);
|
|
30
|
+
box-shadow: var(--nx-shadow);
|
|
31
|
+
pointer-events: auto;
|
|
32
|
+
transition:
|
|
33
|
+
top 220ms cubic-bezier(0.2, 0, 0, 1),
|
|
34
|
+
bottom 220ms cubic-bezier(0.2, 0, 0, 1);
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
.nx-toast:popover-open {
|
|
38
|
+
animation: nx-toast-in 220ms cubic-bezier(0.2, 0, 0, 1);
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
.nx-toast--closing:popover-open {
|
|
42
|
+
animation: nx-toast-out 180ms ease-in forwards;
|
|
43
|
+
pointer-events: none;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
/* Positions: the offset counts from the chosen edge, newest nearest to it. */
|
|
47
|
+
.nx-toast--top-right,
|
|
48
|
+
.nx-toast--top-center,
|
|
49
|
+
.nx-toast--top-left {
|
|
50
|
+
top: calc(var(--nx-toast-edge) + var(--nx-toast-offset));
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
.nx-toast--bottom-right,
|
|
54
|
+
.nx-toast--bottom-center,
|
|
55
|
+
.nx-toast--bottom-left {
|
|
56
|
+
bottom: calc(var(--nx-toast-edge) + var(--nx-toast-offset));
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
.nx-toast--top-right,
|
|
60
|
+
.nx-toast--bottom-right {
|
|
61
|
+
right: var(--nx-toast-edge);
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
/* Minimized popups wait at the bottom right; toasts there stack above them (the dock sets --nx-dock-space). */
|
|
65
|
+
.nx-toast--bottom-right {
|
|
66
|
+
bottom: calc(var(--nx-toast-edge) + var(--nx-toast-offset) + var(--nx-dock-space, 0px));
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
.nx-toast--top-left,
|
|
70
|
+
.nx-toast--bottom-left {
|
|
71
|
+
left: var(--nx-toast-edge);
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
.nx-toast--top-center,
|
|
75
|
+
.nx-toast--bottom-center {
|
|
76
|
+
left: 50%;
|
|
77
|
+
translate: -50% 0;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
@keyframes nx-toast-in {
|
|
81
|
+
from {
|
|
82
|
+
opacity: 0;
|
|
83
|
+
transform: translateY(-8px) scale(0.98);
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
.nx-toast--bottom-right:popover-open,
|
|
88
|
+
.nx-toast--bottom-center:popover-open,
|
|
89
|
+
.nx-toast--bottom-left:popover-open {
|
|
90
|
+
animation-name: nx-toast-in-up;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
@keyframes nx-toast-in-up {
|
|
94
|
+
from {
|
|
95
|
+
opacity: 0;
|
|
96
|
+
transform: translateY(8px) scale(0.98);
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
@keyframes nx-toast-out {
|
|
101
|
+
to {
|
|
102
|
+
opacity: 0;
|
|
103
|
+
transform: scale(0.96);
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
.nx-toast--closing.nx-toast--bottom-right:popover-open,
|
|
108
|
+
.nx-toast--closing.nx-toast--bottom-center:popover-open,
|
|
109
|
+
.nx-toast--closing.nx-toast--bottom-left:popover-open {
|
|
110
|
+
animation-name: nx-toast-out;
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
/* Tones */
|
|
114
|
+
.nx-toast--info {
|
|
115
|
+
--nx-toast-accent: var(--nx-info);
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
.nx-toast--success {
|
|
119
|
+
--nx-toast-accent: var(--nx-success);
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
.nx-toast--warning {
|
|
123
|
+
--nx-toast-accent: var(--nx-warning);
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
.nx-toast--danger {
|
|
127
|
+
--nx-toast-accent: var(--nx-danger);
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
.nx-toast__icon {
|
|
131
|
+
display: grid;
|
|
132
|
+
flex-shrink: 0;
|
|
133
|
+
place-items: center;
|
|
134
|
+
width: 20px;
|
|
135
|
+
height: 20px;
|
|
136
|
+
margin-top: 1px;
|
|
137
|
+
color: var(--nx-toast-accent);
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
.nx-toast__icon .nx-icon {
|
|
141
|
+
width: 20px;
|
|
142
|
+
height: 20px;
|
|
143
|
+
vertical-align: 0;
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
.nx-toast--neutral .nx-toast__icon {
|
|
147
|
+
color: var(--nx-text-muted);
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
.nx-toast__body {
|
|
151
|
+
flex: 1 1 auto;
|
|
152
|
+
min-width: 0;
|
|
153
|
+
padding-top: 1px;
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
.nx-toast__title {
|
|
157
|
+
font-weight: 600;
|
|
158
|
+
line-height: 1.35;
|
|
159
|
+
overflow-wrap: anywhere;
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
.nx-toast__message {
|
|
163
|
+
margin-top: 2px;
|
|
164
|
+
color: var(--nx-text-muted);
|
|
165
|
+
font-size: var(--nx-text-sm);
|
|
166
|
+
line-height: 1.45;
|
|
167
|
+
overflow-wrap: anywhere;
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
.nx-toast__action {
|
|
171
|
+
flex-shrink: 0;
|
|
172
|
+
align-self: center;
|
|
173
|
+
height: 28px;
|
|
174
|
+
margin: 0;
|
|
175
|
+
padding: 0 10px;
|
|
176
|
+
border: 1px solid var(--nx-border-strong);
|
|
177
|
+
border-radius: var(--nx-radius);
|
|
178
|
+
background: var(--nx-surface);
|
|
179
|
+
color: var(--nx-text);
|
|
180
|
+
font: inherit;
|
|
181
|
+
font-size: var(--nx-text-sm);
|
|
182
|
+
font-weight: 500;
|
|
183
|
+
white-space: nowrap;
|
|
184
|
+
cursor: pointer;
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
.nx-toast__action:hover {
|
|
188
|
+
border-color: var(--nx-toast-accent);
|
|
189
|
+
color: var(--nx-toast-accent);
|
|
190
|
+
}
|
|
191
|
+
|
|
192
|
+
.nx-toast__action:focus-visible {
|
|
193
|
+
outline: none;
|
|
194
|
+
box-shadow: var(--nx-focus-ring);
|
|
195
|
+
}
|
|
196
|
+
|
|
197
|
+
.nx-toast__close {
|
|
198
|
+
display: grid;
|
|
199
|
+
flex-shrink: 0;
|
|
200
|
+
place-items: center;
|
|
201
|
+
width: 24px;
|
|
202
|
+
height: 24px;
|
|
203
|
+
margin: -2px -2px 0 0;
|
|
204
|
+
padding: 0;
|
|
205
|
+
border: 0;
|
|
206
|
+
border-radius: var(--nx-radius-sm);
|
|
207
|
+
background: none;
|
|
208
|
+
color: var(--nx-text-subtle);
|
|
209
|
+
cursor: pointer;
|
|
210
|
+
}
|
|
211
|
+
|
|
212
|
+
.nx-toast__close:hover {
|
|
213
|
+
background: var(--nx-surface-hover);
|
|
214
|
+
color: var(--nx-text);
|
|
215
|
+
}
|
|
216
|
+
|
|
217
|
+
.nx-toast__close:focus-visible {
|
|
218
|
+
outline: none;
|
|
219
|
+
box-shadow: var(--nx-focus-ring);
|
|
220
|
+
}
|
|
221
|
+
|
|
222
|
+
.nx-toast__close .nx-icon {
|
|
223
|
+
width: 16px;
|
|
224
|
+
height: 16px;
|
|
225
|
+
vertical-align: 0;
|
|
226
|
+
}
|
|
227
|
+
|
|
228
|
+
/* The time left, shrinking along the bottom edge; its end closes the toast. */
|
|
229
|
+
.nx-toast__progress {
|
|
230
|
+
position: absolute;
|
|
231
|
+
right: 0;
|
|
232
|
+
bottom: 0;
|
|
233
|
+
left: 0;
|
|
234
|
+
height: 3px;
|
|
235
|
+
background: var(--nx-toast-accent);
|
|
236
|
+
opacity: 0.7;
|
|
237
|
+
transform-origin: left;
|
|
238
|
+
animation: nx-toast-progress linear forwards;
|
|
239
|
+
}
|
|
240
|
+
|
|
241
|
+
.nx-toast:is(:hover, :focus-within) .nx-toast__progress {
|
|
242
|
+
animation-play-state: paused;
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
@keyframes nx-toast-progress {
|
|
246
|
+
from {
|
|
247
|
+
transform: scaleX(1);
|
|
248
|
+
}
|
|
249
|
+
|
|
250
|
+
to {
|
|
251
|
+
transform: scaleX(0);
|
|
252
|
+
}
|
|
253
|
+
}
|
|
254
|
+
|
|
255
|
+
[data-nx-motion="reduce"] .nx-toast {
|
|
256
|
+
transition: none;
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
[data-nx-motion="reduce"] .nx-toast:popover-open,
|
|
260
|
+
[data-nx-motion="reduce"] .nx-toast--closing:popover-open {
|
|
261
|
+
animation: none;
|
|
262
|
+
}
|
|
263
|
+
}
|