@sveltia/ui 0.42.0 → 0.43.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/dist/components/alert/alert.svelte +30 -36
- package/dist/components/alert/infobar.svelte +45 -55
- package/dist/components/bottom-navigation/bottom-navigation.svelte +15 -21
- package/dist/components/button/button-group.svelte +5 -7
- package/dist/components/button/button.svelte +175 -274
- package/dist/components/button/floating-action-button-wrapper.svelte +18 -23
- package/dist/components/button/select-button-group.svelte +41 -57
- package/dist/components/button/split-button.svelte +18 -25
- package/dist/components/calendar/calendar.svelte +80 -103
- package/dist/components/checkbox/checkbox-group.svelte +19 -22
- package/dist/components/checkbox/checkbox.svelte +63 -91
- package/dist/components/dialog/dialog.svelte +87 -105
- package/dist/components/dialog/prompt-dialog.svelte +3 -5
- package/dist/components/disclosure/disclosure.svelte +21 -34
- package/dist/components/divider/divider.svelte +14 -18
- package/dist/components/divider/spacer.svelte +8 -13
- package/dist/components/drawer/drawer.svelte +190 -343
- package/dist/components/grid/grid-body.svelte +14 -16
- package/dist/components/grid/grid-cell.svelte +3 -5
- package/dist/components/grid/grid-col-header.svelte +3 -5
- package/dist/components/grid/grid-foot.svelte +3 -5
- package/dist/components/grid/grid-head.svelte +3 -5
- package/dist/components/grid/grid-row-header.svelte +4 -6
- package/dist/components/grid/grid-row.svelte +4 -6
- package/dist/components/grid/grid.svelte +12 -18
- package/dist/components/icon/icon.svelte +5 -7
- package/dist/components/listbox/listbox.svelte +61 -78
- package/dist/components/listbox/option-group.svelte +11 -15
- package/dist/components/listbox/option.svelte +39 -54
- package/dist/components/menu/menu-item-group.svelte +3 -5
- package/dist/components/menu/menu-item.svelte +51 -67
- package/dist/components/menu/menu.svelte +17 -21
- package/dist/components/progressbar/progressbar.svelte +15 -24
- package/dist/components/radio/radio-group.svelte +31 -40
- package/dist/components/radio/radio.svelte +63 -81
- package/dist/components/resizable-pane/resizable-handle.svelte +48 -60
- package/dist/components/resizable-pane/resizable-pane-group.svelte +14 -18
- package/dist/components/select/combobox.svelte +112 -135
- package/dist/components/select/select-tags.svelte +57 -73
- package/dist/components/slider/slider.svelte +74 -94
- package/dist/components/switch/switch.svelte +81 -115
- package/dist/components/table/table-body.svelte +14 -16
- package/dist/components/table/table-cell.svelte +3 -5
- package/dist/components/table/table-col-header.svelte +3 -5
- package/dist/components/table/table-foot.svelte +3 -5
- package/dist/components/table/table-head.svelte +3 -5
- package/dist/components/table/table-row-header.svelte +4 -6
- package/dist/components/table/table-row.svelte +4 -6
- package/dist/components/table/table.svelte +12 -18
- package/dist/components/tabs/tab-box.svelte +6 -9
- package/dist/components/tabs/tab-list.svelte +73 -91
- package/dist/components/tabs/tab-panel.svelte +7 -11
- package/dist/components/tabs/tab-panels.svelte +14 -19
- package/dist/components/text-editor/code-editor.svelte +7 -10
- package/dist/components/text-editor/core.js +10 -7
- package/dist/components/text-editor/lexical-root.svelte +160 -221
- package/dist/components/text-editor/text-editor.svelte +18 -25
- package/dist/components/text-editor/toolbar/toolbar-wrapper.svelte +37 -44
- package/dist/components/text-field/number-input.svelte +68 -87
- package/dist/components/text-field/password-input.svelte +42 -52
- package/dist/components/text-field/search-bar.svelte +53 -64
- package/dist/components/text-field/secret-input.svelte +46 -61
- package/dist/components/text-field/text-area.svelte +68 -80
- package/dist/components/text-field/text-input.svelte +106 -138
- package/dist/components/toast/toast.svelte +89 -104
- package/dist/components/toolbar/toolbar.svelte +54 -70
- package/dist/components/typography/truncated-text.svelte +7 -9
- package/dist/components/util/app-shell.svelte +493 -40
- package/dist/components/util/empty-state.svelte +11 -13
- package/dist/components/util/group.svelte +3 -5
- package/dist/components/util/modal.svelte +48 -59
- package/dist/components/util/popup.svelte +67 -87
- package/dist/services/i18n.js +2 -2
- package/package.json +2 -2
|
@@ -217,62 +217,51 @@
|
|
|
217
217
|
</dialog>
|
|
218
218
|
{/snippet}
|
|
219
219
|
|
|
220
|
-
<style
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
pointer-events: none !important;
|
|
269
|
-
|
|
270
|
-
:global {
|
|
271
|
-
* {
|
|
272
|
-
transition-duration: 0ms !important;
|
|
273
|
-
pointer-events: none !important;
|
|
274
|
-
}
|
|
275
|
-
}
|
|
276
|
-
}
|
|
277
|
-
}
|
|
278
|
-
</style>
|
|
220
|
+
<style>dialog {
|
|
221
|
+
position: fixed;
|
|
222
|
+
inset: 0;
|
|
223
|
+
z-index: 9999999;
|
|
224
|
+
display: flex;
|
|
225
|
+
justify-content: center;
|
|
226
|
+
align-items: center;
|
|
227
|
+
overflow: hidden;
|
|
228
|
+
outline: 0;
|
|
229
|
+
margin: 0;
|
|
230
|
+
border: 0;
|
|
231
|
+
padding: 0;
|
|
232
|
+
width: 100dvw;
|
|
233
|
+
max-width: 100dvw;
|
|
234
|
+
height: 100dvh;
|
|
235
|
+
max-height: 100dvh;
|
|
236
|
+
color: var(--sui-primary-foreground-color);
|
|
237
|
+
background: transparent;
|
|
238
|
+
-webkit-user-select: none;
|
|
239
|
+
user-select: none;
|
|
240
|
+
touch-action: none;
|
|
241
|
+
pointer-events: all;
|
|
242
|
+
cursor: default;
|
|
243
|
+
}
|
|
244
|
+
dialog::backdrop {
|
|
245
|
+
background: transparent;
|
|
246
|
+
}
|
|
247
|
+
dialog.backdrop {
|
|
248
|
+
background-color: var(--sui-popup-backdrop-color);
|
|
249
|
+
}
|
|
250
|
+
dialog.open {
|
|
251
|
+
transition-duration: 50ms;
|
|
252
|
+
opacity: 1;
|
|
253
|
+
}
|
|
254
|
+
dialog:not(.open) {
|
|
255
|
+
transition-duration: 400ms;
|
|
256
|
+
opacity: 0;
|
|
257
|
+
}
|
|
258
|
+
dialog[hidden] {
|
|
259
|
+
transition-duration: 1ms !important;
|
|
260
|
+
}
|
|
261
|
+
dialog:not(.active) {
|
|
262
|
+
pointer-events: none !important;
|
|
263
|
+
}
|
|
264
|
+
dialog:not(.active) :global(*) {
|
|
265
|
+
transition-duration: 0ms !important;
|
|
266
|
+
pointer-events: none !important;
|
|
267
|
+
}</style>
|
|
@@ -201,90 +201,70 @@
|
|
|
201
201
|
</Modal>
|
|
202
202
|
{/if}
|
|
203
203
|
|
|
204
|
-
<style
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
gap: 4px;
|
|
272
|
-
padding: 8px 4px !important;
|
|
273
|
-
}
|
|
274
|
-
}
|
|
275
|
-
}
|
|
276
|
-
}
|
|
277
|
-
|
|
278
|
-
:global(dialog.open) & {
|
|
279
|
-
transition-duration: 50ms;
|
|
280
|
-
opacity: 1;
|
|
281
|
-
transform: translateY(2px);
|
|
282
|
-
}
|
|
283
|
-
|
|
284
|
-
:global(dialog:not(.open)) & {
|
|
285
|
-
transition-duration: 300ms;
|
|
286
|
-
opacity: 0;
|
|
287
|
-
transform: translateY(-8px);
|
|
288
|
-
}
|
|
289
|
-
}
|
|
290
|
-
</style>
|
|
204
|
+
<style>.content {
|
|
205
|
+
position: absolute;
|
|
206
|
+
overflow-y: auto;
|
|
207
|
+
outline-width: 0 !important;
|
|
208
|
+
width: auto;
|
|
209
|
+
color: var(--sui-primary-foreground-color);
|
|
210
|
+
background-color: var(--sui-secondary-background-color-translucent);
|
|
211
|
+
box-shadow: 0 8px 16px var(--sui-popup-shadow-color);
|
|
212
|
+
-webkit-backdrop-filter: blur(16px);
|
|
213
|
+
backdrop-filter: blur(16px);
|
|
214
|
+
transition-property: opacity, transform;
|
|
215
|
+
}
|
|
216
|
+
.content.menu {
|
|
217
|
+
border-width: var(--sui-menu-border-width, 1px);
|
|
218
|
+
border-style: var(--sui-menu-border-style, solid);
|
|
219
|
+
border-color: var(--sui-menu-border-width, var(--sui-secondary-border-color));
|
|
220
|
+
border-radius: var(--sui-menu-border-radius, 4px);
|
|
221
|
+
padding: var(--sui-menu-padding, 4px);
|
|
222
|
+
}
|
|
223
|
+
.content.menu :global(.sui.menu) {
|
|
224
|
+
border-width: 0;
|
|
225
|
+
border-radius: 0;
|
|
226
|
+
padding: 0;
|
|
227
|
+
background-color: transparent;
|
|
228
|
+
}
|
|
229
|
+
.content.listbox {
|
|
230
|
+
border-width: var(--sui-listbox-border-width, 1px);
|
|
231
|
+
border-style: var(--sui-listbox-border-style, solid);
|
|
232
|
+
border-color: var(--sui-listbox-border-width, var(--sui-secondary-border-color));
|
|
233
|
+
border-radius: var(--sui-listbox-border-radius, 4px);
|
|
234
|
+
padding: var(--sui-listbox-padding, 4px);
|
|
235
|
+
}
|
|
236
|
+
.content.listbox :global(.sui.listbox) {
|
|
237
|
+
border-width: 0;
|
|
238
|
+
border-radius: 0;
|
|
239
|
+
padding: 0;
|
|
240
|
+
background-color: transparent;
|
|
241
|
+
}
|
|
242
|
+
.content.touch {
|
|
243
|
+
position: static;
|
|
244
|
+
border-width: 0 !important;
|
|
245
|
+
border-radius: 4px !important;
|
|
246
|
+
padding: 8px;
|
|
247
|
+
min-width: 320px !important;
|
|
248
|
+
max-width: calc(100dvw - 32px) !important;
|
|
249
|
+
max-height: calc(100dvh - 32px) !important;
|
|
250
|
+
}
|
|
251
|
+
:global(dialog.open) .content.touch {
|
|
252
|
+
transform: scale(100%) !important;
|
|
253
|
+
}
|
|
254
|
+
:global(dialog:not(.open)) .content.touch {
|
|
255
|
+
transform: scale(90%);
|
|
256
|
+
}
|
|
257
|
+
.content.touch.combobox :global(.sui.listbox) {
|
|
258
|
+
gap: 4px;
|
|
259
|
+
padding: 8px 4px !important;
|
|
260
|
+
}
|
|
261
|
+
:global(dialog.open) .content {
|
|
262
|
+
transition-duration: 50ms;
|
|
263
|
+
opacity: 1;
|
|
264
|
+
transform: translateY(2px);
|
|
265
|
+
}
|
|
266
|
+
:global(dialog:not(.open)) .content {
|
|
267
|
+
transition-duration: 300ms;
|
|
268
|
+
opacity: 0;
|
|
269
|
+
transform: translateY(-8px);
|
|
270
|
+
}</style>
|
package/dist/services/i18n.js
CHANGED
|
@@ -15,8 +15,8 @@ export const resources = Object.fromEntries(
|
|
|
15
15
|
);
|
|
16
16
|
|
|
17
17
|
/**
|
|
18
|
-
* Load strings and initialize the locales. Consumers can use this function
|
|
19
|
-
* strings for their application.
|
|
18
|
+
* Load strings and initialize the locales. Consumers can use this function or {@link resources} to
|
|
19
|
+
* load the localized strings for their application.
|
|
20
20
|
* @param {object} [init] Initialize options.
|
|
21
21
|
* @param {string} [init.fallbackLocale] Fallback locale.
|
|
22
22
|
* @param {string} [init.initialLocale] Initial locale.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sveltia/ui",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.43.0",
|
|
4
4
|
"description": "A collection of Svelte components and utilities for building user interfaces.",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -45,7 +45,7 @@
|
|
|
45
45
|
"@lexical/selection": "^0.47.0",
|
|
46
46
|
"@lexical/table": "^0.47.0",
|
|
47
47
|
"@lexical/utils": "^0.47.0",
|
|
48
|
-
"@sveltia/i18n": "^1.1.
|
|
48
|
+
"@sveltia/i18n": "^1.1.3",
|
|
49
49
|
"@sveltia/utils": "^0.10.7",
|
|
50
50
|
"lexical": "^0.47.0",
|
|
51
51
|
"prismjs": "^1.30.0"
|