@svadmin/ui 0.126.0 → 0.126.1
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.
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
const resources = $derived(adminContext.resources.filter((resource) => resource.meta?.['aboutVisible'] !== false));
|
|
12
12
|
const providerNames = $derived(adminContext.getDataProviderNames());
|
|
13
13
|
let { version: suppliedVersion, headingLevel = 'h1' }: { version?: string; headingLevel?: 'h1' | 'h2' } = $props();
|
|
14
|
-
const buildVersion = "0.126.
|
|
14
|
+
const buildVersion = "0.126.1";
|
|
15
15
|
const version = $derived(suppliedVersion ?? (
|
|
16
16
|
buildVersion.startsWith('__')
|
|
17
17
|
? (i18n.locale === 'zh-CN' ? '开发构建(未提供版本)' : 'Development build (version unavailable)')
|
|
@@ -1,8 +1,11 @@
|
|
|
1
1
|
<script lang="ts">
|
|
2
2
|
import { onMount, onDestroy } from 'svelte';
|
|
3
|
+
import { useTranslation } from '@svadmin/core/i18n';
|
|
3
4
|
import { RotateCw, Clock } from '@lucide/svelte';
|
|
4
5
|
import { cn } from '../utils.js';
|
|
5
6
|
|
|
7
|
+
const i18n = useTranslation();
|
|
8
|
+
|
|
6
9
|
export type FreshnessStatus = 'live' | 'fresh' | 'stale' | 'offline';
|
|
7
10
|
export type PollInterval = 0 | 5 | 15 | 30 | 60 | 300;
|
|
8
11
|
|
|
@@ -137,7 +140,7 @@
|
|
|
137
140
|
class="bg-transparent text-[11px] font-mono outline-none text-foreground cursor-pointer"
|
|
138
141
|
value={currentPollInterval}
|
|
139
142
|
onchange={handleIntervalChange}
|
|
140
|
-
aria-label=
|
|
143
|
+
aria-label={i18n.t('common.pollInterval')}
|
|
141
144
|
>
|
|
142
145
|
<option value={5} class="text-foreground bg-card">5秒自动刷新</option>
|
|
143
146
|
<option value={15} class="text-foreground bg-card">15秒自动刷新</option>
|
|
@@ -1,8 +1,11 @@
|
|
|
1
1
|
<script lang="ts">
|
|
2
2
|
import { onMount } from 'svelte';
|
|
3
|
+
import { useTranslation } from '@svadmin/core/i18n';
|
|
3
4
|
import { Bookmark, BookmarkPlus, X, Trash2, Check, Filter } from '@lucide/svelte';
|
|
4
5
|
import { cn } from '../utils.js';
|
|
5
6
|
|
|
7
|
+
const i18n = useTranslation();
|
|
8
|
+
|
|
6
9
|
export interface FilterTagItem {
|
|
7
10
|
id: string;
|
|
8
11
|
field: string;
|
|
@@ -119,7 +122,7 @@
|
|
|
119
122
|
type="button"
|
|
120
123
|
class="rounded-full p-0.5 text-muted-foreground hover:bg-primary/20 hover:text-primary transition-colors cursor-pointer"
|
|
121
124
|
onclick={() => onremove?.(item.id)}
|
|
122
|
-
aria-label=
|
|
125
|
+
aria-label={i18n.t('common.removeFilter')}
|
|
123
126
|
>
|
|
124
127
|
<X class="h-3 w-3" />
|
|
125
128
|
</button>
|
|
@@ -160,8 +163,8 @@
|
|
|
160
163
|
type="button"
|
|
161
164
|
class="p-1 text-muted-foreground hover:text-destructive transition-colors cursor-pointer"
|
|
162
165
|
onclick={() => activePresetId && deletePreset(activePresetId)}
|
|
163
|
-
title=
|
|
164
|
-
aria-label=
|
|
166
|
+
title={i18n.t('common.deletePreset')}
|
|
167
|
+
aria-label={i18n.t('common.deletePreset')}
|
|
165
168
|
>
|
|
166
169
|
<Trash2 class="h-3 w-3" />
|
|
167
170
|
</button>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@svadmin/ui",
|
|
3
|
-
"version": "0.126.
|
|
3
|
+
"version": "0.126.1",
|
|
4
4
|
"description": "Pre-built admin UI components — AdminApp, AutoTable, AutoForm, Sidebar, Layout",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"sideEffects": [
|
|
@@ -88,7 +88,7 @@
|
|
|
88
88
|
"@codemirror/lang-json": "^6.0.0",
|
|
89
89
|
"@codemirror/lang-markdown": "^6.0.0",
|
|
90
90
|
"@codemirror/lang-sql": "^6.0.0",
|
|
91
|
-
"@svadmin/core": "^0.81.
|
|
91
|
+
"@svadmin/core": "^0.81.1",
|
|
92
92
|
"@tanstack/svelte-query": "^6.1.48",
|
|
93
93
|
"codemirror": "^6.0.0",
|
|
94
94
|
"dashjs": "^5.3.0",
|
|
@@ -151,7 +151,7 @@
|
|
|
151
151
|
}
|
|
152
152
|
},
|
|
153
153
|
"dependencies": {
|
|
154
|
-
"@svadmin/devtools": "^0.6.
|
|
154
|
+
"@svadmin/devtools": "^0.6.11",
|
|
155
155
|
"@svadmin/devtools-contract": "^0.3.3",
|
|
156
156
|
"@vibeunion/devtools-devframe": "^0.1.2",
|
|
157
157
|
"typebox": "^1.4.6",
|
|
@@ -189,7 +189,7 @@
|
|
|
189
189
|
"@codemirror/lang-markdown": "^6.5.2",
|
|
190
190
|
"@codemirror/lang-sql": "^6.10.0",
|
|
191
191
|
"@happy-dom/global-registrator": "^21.0.4",
|
|
192
|
-
"@svadmin/ai-elements": "^0.14.
|
|
192
|
+
"@svadmin/ai-elements": "^0.14.6",
|
|
193
193
|
"@sveltejs/vite-plugin-svelte": "^7.3.1",
|
|
194
194
|
"@tailwindcss/cli": "4.3.5",
|
|
195
195
|
"@testing-library/dom": "^10.4.2",
|