-
-
-
-
+
+
+
+
-
-
- {{ author.name }}
-
- - {{ author.username ? `@${author.username}` : '' }}
-
-
-
-
-
-
-
- {{ module }}
-
+
+
+
+
+
+
+
+
+ {{ author.name }}
+
+
+ @{{ author.username }}
+
+
+
+ {{ author.role }}
+
+
+
+ {{ formatDate(author.birthDate) }}
+
+
+
+
+
+ {{ module }}
+
+
+
+
+ View Profile
+
+
+
+
+
diff --git a/playground/docus/content.config.ts b/playground/docus/content.config.ts
index 0918172c..3b4c8053 100644
--- a/playground/docus/content.config.ts
+++ b/playground/docus/content.config.ts
@@ -14,11 +14,16 @@ const createDocsSchema = () => z.object({
const createAuthorsSchema = () => z.object({
name: z.string(),
avatar: z.object({
- src: z.string(),
+ src: z.string().editor({ input: 'media' }),
alt: z.string(),
}),
to: z.string(),
username: z.string(),
+ role: z.enum(['creator', 'maintainer', 'contributor']).default('contributor'),
+ order: z.number().default(0),
+ birthDate: z.date(),
+ icon: z.string().editor({ input: 'icon', iconLibraries: ['lucide'] }),
+ isOpenSourceLover: z.boolean().default(true),
modules: z.array(z.string()),
})
diff --git a/playground/docus/content/authors/atinux.yml b/playground/docus/content/authors/atinux.yml
index 4738f542..ec36ae96 100644
--- a/playground/docus/content/authors/atinux.yml
+++ b/playground/docus/content/authors/atinux.yml
@@ -1,8 +1,13 @@
name: Sébastien Chopin
avatar:
- src: https://avatars.githubusercontent.com/u/904724?v=4
+ src: /atinux.jpeg
to: https://x.com/atinux
username: atinux
+role: creator
+order: 1
+birthDate: 1992-11-23
+icon: i-lucide-rocket
+isOpenSourceLover: true
modules:
- hub
- ui
diff --git a/playground/docus/content/authors/farnabaz.md b/playground/docus/content/authors/farnabaz.md
index aab08517..735cec52 100644
--- a/playground/docus/content/authors/farnabaz.md
+++ b/playground/docus/content/authors/farnabaz.md
@@ -1,9 +1,14 @@
---
name: Ahad Birang
avatar:
- src: https://avatars.githubusercontent.com/u/2047945?v=4
+ src: /farnabaz.jpeg
to: https://x.com/farnabaz
username: farnabaz
+role: maintainer
+order: 2
+birthDate: 1990-08-10
+icon: i-lucide-code
+isOpenSourceLover: true
modules:
- studio
- content
diff --git a/playground/docus/content/authors/larbish.json b/playground/docus/content/authors/larbish.json
index ffde193c..8bb90630 100644
--- a/playground/docus/content/authors/larbish.json
+++ b/playground/docus/content/authors/larbish.json
@@ -1,10 +1,15 @@
{
"name": "Baptiste Leproux",
"avatar": {
- "src": "https://avatars.githubusercontent.com/u/7290030?v=4"
+ "src": "/larbish.jpeg"
},
"to": "https://x.com/_larbish",
"username": "larbish",
+ "role": "contributor",
+ "order": 3,
+ "birthDate": "1993-09-03",
+ "icon": "i-lucide-palette",
+ "isOpenSourceLover": true,
"modules": [
"studio",
"content",
diff --git a/playground/docus/public/atinux.jpeg b/playground/docus/public/atinux.jpeg
new file mode 100644
index 00000000..31073eab
Binary files /dev/null and b/playground/docus/public/atinux.jpeg differ
diff --git a/playground/docus/public/farnabaz.jpeg b/playground/docus/public/farnabaz.jpeg
new file mode 100644
index 00000000..858b1caf
Binary files /dev/null and b/playground/docus/public/farnabaz.jpeg differ
diff --git a/playground/docus/public/larbish.jpeg b/playground/docus/public/larbish.jpeg
new file mode 100644
index 00000000..80170966
Binary files /dev/null and b/playground/docus/public/larbish.jpeg differ
diff --git a/src/app/src/components/form/FormPanelInput.vue b/src/app/src/components/form/FormPanelInput.vue
index bc586d2c..76965f8b 100644
--- a/src/app/src/components/form/FormPanelInput.vue
+++ b/src/app/src/components/form/FormPanelInput.vue
@@ -1,9 +1,16 @@
@@ -87,22 +86,13 @@ function computeValue(formItem: FormItem): unknown {
:label="label"
:ui="{
root: 'w-full mt-2',
- label: 'text-xs font-medium tracking-tight',
+ label: 'text-xs font-semibold tracking-tight',
}"
>
-
-
diff --git a/src/app/src/components/form/input/FormInputArray.vue b/src/app/src/components/form/input/FormInputArray.vue
index d958c0a7..71821c90 100644
--- a/src/app/src/components/form/input/FormInputArray.vue
+++ b/src/app/src/components/form/input/FormInputArray.vue
@@ -111,8 +111,8 @@ function updateObjectItem(index: number, value: Record
) {
:key="item.label"
variant="subtle"
color="neutral"
- size="sm"
- class="group/badge flex items-center gap-3 px-2 py-1 min-w-0"
+ size="xs"
+ class="min-w-0"
>
+const model = defineModel({ type: Boolean, default: false })
+
+
+
+
+
diff --git a/src/app/src/components/form/input/InputDate.vue b/src/app/src/components/form/input/InputDate.vue
new file mode 100644
index 00000000..ad2ae76d
--- /dev/null
+++ b/src/app/src/components/form/input/InputDate.vue
@@ -0,0 +1,68 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/app/src/components/form/input/InputIcon.vue b/src/app/src/components/form/input/InputIcon.vue
new file mode 100644
index 00000000..0cc6ecaa
--- /dev/null
+++ b/src/app/src/components/form/input/InputIcon.vue
@@ -0,0 +1,160 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ $t('studio.form.icon.noIconsFound') }}
+
+
+
+ {{ $t('studio.form.icon.searchHint') }}
+
+
+
+ {{ $t('studio.form.icon.libraries') }} {{ iconLibraries === 'all' ? $t('studio.form.icon.allLibraries') : iconLibraries.join(', ') }}
+
+
+
+
+
+
+
+
diff --git a/src/app/src/components/form/input/InputMedia.vue b/src/app/src/components/form/input/InputMedia.vue
new file mode 100644
index 00000000..bf77c0af
--- /dev/null
+++ b/src/app/src/components/form/input/InputMedia.vue
@@ -0,0 +1,161 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ search ? $t('studio.form.media.noImagesFound') : $t('studio.form.media.noImagesAvailable') }}
+
+
+
+
+
+
+
+
+
+
+ {{ $t('studio.form.media.imageCount', { count: mediaFiles.length, total: allMediaFiles.length }, allMediaFiles.length) }}
+
+
+
+
+
+
+
+
diff --git a/src/app/src/components/form/input/InputNumber.vue b/src/app/src/components/form/input/InputNumber.vue
new file mode 100644
index 00000000..273c5f1d
--- /dev/null
+++ b/src/app/src/components/form/input/InputNumber.vue
@@ -0,0 +1,23 @@
+
+
+
+
+
diff --git a/src/app/src/components/form/input/InputText.vue b/src/app/src/components/form/input/InputText.vue
new file mode 100644
index 00000000..6a857ee7
--- /dev/null
+++ b/src/app/src/components/form/input/InputText.vue
@@ -0,0 +1,42 @@
+
+
+
+
+
+
diff --git a/src/app/src/locales/ar.json b/src/app/src/locales/ar.json
index e5fa8d64..7191bfc6 100644
--- a/src/app/src/locales/ar.json
+++ b/src/app/src/locales/ar.json
@@ -300,6 +300,31 @@
},
"section": {
"propertyCount": "خاصية واحدة | {count} خصائص"
+ },
+ "media": {
+ "placeholder": "مسار نسبي أو رابط عام...",
+ "searchPlaceholder": "بحث عن الصور...",
+ "noImagesFound": "لم يتم العثور على صور",
+ "noImagesAvailable": "لا توجد صور متاحة",
+ "imageCount": "{count} من {total} صورة | {count} من {total} صور"
+ },
+ "icon": {
+ "placeholder": "i-lucide-icon",
+ "searchPlaceholder": "بحث عن الأيقونات...",
+ "noIconsFound": "لم يتم العثور على أيقونات",
+ "searchHint": "اكتب حرفين على الأقل للبحث",
+ "libraries": "المكتبات:",
+ "allLibraries": "الكل"
+ },
+ "text": {
+ "placeholder": "أدخل النص...",
+ "selectPlaceholder": "اختر خياراً..."
+ },
+ "date": {
+ "selectDate": "اختر تاريخاً"
+ },
+ "number": {
+ "placeholder": "0"
}
}
}
diff --git a/src/app/src/locales/bg.json b/src/app/src/locales/bg.json
index fed7d654..94537577 100644
--- a/src/app/src/locales/bg.json
+++ b/src/app/src/locales/bg.json
@@ -301,6 +301,31 @@
},
"section": {
"propertyCount": "1 свойство | {count} свойства"
+ },
+ "media": {
+ "placeholder": "Относителен път или публичен URL...",
+ "searchPlaceholder": "Търсене на изображения...",
+ "noImagesFound": "Не са намерени изображения",
+ "noImagesAvailable": "Няма налични изображения",
+ "imageCount": "{count} от {total} изображение | {count} от {total} изображения"
+ },
+ "icon": {
+ "placeholder": "i-lucide-icon",
+ "searchPlaceholder": "Търсене на икони...",
+ "noIconsFound": "Не са намерени икони",
+ "searchHint": "Въведете поне 2 символа за търсене",
+ "libraries": "Библиотеки:",
+ "allLibraries": "Всички"
+ },
+ "text": {
+ "placeholder": "Въведете текст...",
+ "selectPlaceholder": "Изберете опция..."
+ },
+ "date": {
+ "selectDate": "Изберете дата"
+ },
+ "number": {
+ "placeholder": "0"
}
}
}
diff --git a/src/app/src/locales/de.json b/src/app/src/locales/de.json
index 12d4dd33..79d635a7 100644
--- a/src/app/src/locales/de.json
+++ b/src/app/src/locales/de.json
@@ -301,6 +301,31 @@
},
"section": {
"propertyCount": "1 Eigenschaft | {count} Eigenschaften"
+ },
+ "media": {
+ "placeholder": "Relativen Pfad oder öffentliche URL eingeben...",
+ "searchPlaceholder": "Bilder suchen...",
+ "noImagesFound": "Keine Bilder gefunden",
+ "noImagesAvailable": "Keine Bilder verfügbar",
+ "imageCount": "{count} von {total} Bild | {count} von {total} Bildern"
+ },
+ "icon": {
+ "placeholder": "i-lucide-icon",
+ "searchPlaceholder": "Icons suchen...",
+ "noIconsFound": "Keine Icons gefunden",
+ "searchHint": "Mindestens 2 Zeichen eingeben",
+ "libraries": "Bibliotheken:",
+ "allLibraries": "Alle"
+ },
+ "text": {
+ "placeholder": "Text eingeben...",
+ "selectPlaceholder": "Option auswählen..."
+ },
+ "date": {
+ "selectDate": "Datum auswählen"
+ },
+ "number": {
+ "placeholder": "0"
}
}
}
diff --git a/src/app/src/locales/en.json b/src/app/src/locales/en.json
index e4c7a1a9..7c7646f5 100644
--- a/src/app/src/locales/en.json
+++ b/src/app/src/locales/en.json
@@ -301,6 +301,31 @@
},
"section": {
"propertyCount": "1 property | {count} properties"
+ },
+ "media": {
+ "placeholder": "Enter relative path or Public URL...",
+ "searchPlaceholder": "Search images...",
+ "noImagesFound": "No images found",
+ "noImagesAvailable": "No images available",
+ "imageCount": "{count} of {total} image | {count} of {total} images"
+ },
+ "icon": {
+ "placeholder": "i-lucide-icon",
+ "searchPlaceholder": "Search icons...",
+ "noIconsFound": "No icons found",
+ "searchHint": "Type at least 2 characters to search",
+ "libraries": "Libraries:",
+ "allLibraries": "All"
+ },
+ "text": {
+ "placeholder": "Enter text...",
+ "selectPlaceholder": "Select an option..."
+ },
+ "date": {
+ "selectDate": "Select a date"
+ },
+ "number": {
+ "placeholder": "0"
}
}
}
diff --git a/src/app/src/locales/es.json b/src/app/src/locales/es.json
index 5bf35db0..34257c94 100644
--- a/src/app/src/locales/es.json
+++ b/src/app/src/locales/es.json
@@ -301,6 +301,31 @@
},
"section": {
"propertyCount": "1 propiedad | {count} propiedades"
+ },
+ "media": {
+ "placeholder": "Ruta relativa o URL pública...",
+ "searchPlaceholder": "Buscar imágenes...",
+ "noImagesFound": "No se encontraron imágenes",
+ "noImagesAvailable": "No hay imágenes disponibles",
+ "imageCount": "{count} de {total} imagen | {count} de {total} imágenes"
+ },
+ "icon": {
+ "placeholder": "i-lucide-icon",
+ "searchPlaceholder": "Buscar iconos...",
+ "noIconsFound": "No se encontraron iconos",
+ "searchHint": "Escriba al menos 2 caracteres para buscar",
+ "libraries": "Bibliotecas:",
+ "allLibraries": "Todas"
+ },
+ "text": {
+ "placeholder": "Ingrese texto...",
+ "selectPlaceholder": "Seleccione una opción..."
+ },
+ "date": {
+ "selectDate": "Seleccionar fecha"
+ },
+ "number": {
+ "placeholder": "0"
}
}
}
diff --git a/src/app/src/locales/fa.json b/src/app/src/locales/fa.json
index d0d7f55d..04302390 100644
--- a/src/app/src/locales/fa.json
+++ b/src/app/src/locales/fa.json
@@ -301,6 +301,31 @@
},
"section": {
"propertyCount": "۱ ویژگی | {count} ویژگی"
+ },
+ "media": {
+ "placeholder": "مسیر نسبی یا URL عمومی...",
+ "searchPlaceholder": "جستجوی تصاویر...",
+ "noImagesFound": "تصویری یافت نشد",
+ "noImagesAvailable": "تصویری در دسترس نیست",
+ "imageCount": "{count} از {total} تصویر"
+ },
+ "icon": {
+ "placeholder": "i-lucide-icon",
+ "searchPlaceholder": "جستجوی آیکونها...",
+ "noIconsFound": "آیکونی یافت نشد",
+ "searchHint": "حداقل ۲ کاراکتر برای جستجو وارد کنید",
+ "libraries": "کتابخانهها:",
+ "allLibraries": "همه"
+ },
+ "text": {
+ "placeholder": "متن را وارد کنید...",
+ "selectPlaceholder": "یک گزینه انتخاب کنید..."
+ },
+ "date": {
+ "selectDate": "انتخاب تاریخ"
+ },
+ "number": {
+ "placeholder": "۰"
}
}
}
diff --git a/src/app/src/locales/fi.json b/src/app/src/locales/fi.json
index 8ea44975..986d3113 100644
--- a/src/app/src/locales/fi.json
+++ b/src/app/src/locales/fi.json
@@ -301,6 +301,31 @@
},
"section": {
"propertyCount": "1 ominaisuus | {count} ominaisuutta"
+ },
+ "media": {
+ "placeholder": "Suhteellinen polku tai julkinen URL...",
+ "searchPlaceholder": "Etsi kuvia...",
+ "noImagesFound": "Kuvia ei löytynyt",
+ "noImagesAvailable": "Kuvia ei saatavilla",
+ "imageCount": "{count} / {total} kuva | {count} / {total} kuvaa"
+ },
+ "icon": {
+ "placeholder": "i-lucide-icon",
+ "searchPlaceholder": "Etsi kuvakkeita...",
+ "noIconsFound": "Kuvakkeita ei löytynyt",
+ "searchHint": "Kirjoita vähintään 2 merkkiä hakeaksesi",
+ "libraries": "Kirjastot:",
+ "allLibraries": "Kaikki"
+ },
+ "text": {
+ "placeholder": "Syötä teksti...",
+ "selectPlaceholder": "Valitse vaihtoehto..."
+ },
+ "date": {
+ "selectDate": "Valitse päivämäärä"
+ },
+ "number": {
+ "placeholder": "0"
}
}
}
diff --git a/src/app/src/locales/fr.json b/src/app/src/locales/fr.json
index 0ecc1571..b58d877c 100644
--- a/src/app/src/locales/fr.json
+++ b/src/app/src/locales/fr.json
@@ -301,6 +301,31 @@
},
"section": {
"propertyCount": "1 propriété | {count} propriétés"
+ },
+ "media": {
+ "placeholder": "Chemin relatif ou URL publique...",
+ "searchPlaceholder": "Rechercher des images...",
+ "noImagesFound": "Aucune image trouvée",
+ "noImagesAvailable": "Aucune image disponible",
+ "imageCount": "{count} sur {total} image | {count} sur {total} images"
+ },
+ "icon": {
+ "placeholder": "i-lucide-icon",
+ "searchPlaceholder": "Rechercher des icônes...",
+ "noIconsFound": "Aucune icône trouvée",
+ "searchHint": "Tapez au moins 2 caractères pour rechercher",
+ "libraries": "Bibliothèques :",
+ "allLibraries": "Toutes"
+ },
+ "text": {
+ "placeholder": "Saisir du texte...",
+ "selectPlaceholder": "Sélectionner une option..."
+ },
+ "date": {
+ "selectDate": "Sélectionner une date"
+ },
+ "number": {
+ "placeholder": "0"
}
}
}
diff --git a/src/app/src/locales/id.json b/src/app/src/locales/id.json
index b8e2e177..44d8eb61 100644
--- a/src/app/src/locales/id.json
+++ b/src/app/src/locales/id.json
@@ -301,6 +301,31 @@
},
"section": {
"propertyCount": "1 properti | {count} properti"
+ },
+ "media": {
+ "placeholder": "Path relatif atau URL publik...",
+ "searchPlaceholder": "Cari gambar...",
+ "noImagesFound": "Gambar tidak ditemukan",
+ "noImagesAvailable": "Tidak ada gambar tersedia",
+ "imageCount": "{count} dari {total} gambar"
+ },
+ "icon": {
+ "placeholder": "i-lucide-icon",
+ "searchPlaceholder": "Cari ikon...",
+ "noIconsFound": "Ikon tidak ditemukan",
+ "searchHint": "Ketik minimal 2 karakter untuk mencari",
+ "libraries": "Pustaka:",
+ "allLibraries": "Semua"
+ },
+ "text": {
+ "placeholder": "Masukkan teks...",
+ "selectPlaceholder": "Pilih opsi..."
+ },
+ "date": {
+ "selectDate": "Pilih tanggal"
+ },
+ "number": {
+ "placeholder": "0"
}
}
}
diff --git a/src/app/src/locales/it.json b/src/app/src/locales/it.json
index e3e12a8b..2a98e020 100644
--- a/src/app/src/locales/it.json
+++ b/src/app/src/locales/it.json
@@ -301,6 +301,31 @@
},
"section": {
"propertyCount": "1 proprietà | {count} proprietà"
+ },
+ "media": {
+ "placeholder": "Percorso relativo o URL pubblico...",
+ "searchPlaceholder": "Cerca immagini...",
+ "noImagesFound": "Nessuna immagine trovata",
+ "noImagesAvailable": "Nessuna immagine disponibile",
+ "imageCount": "{count} di {total} immagine | {count} di {total} immagini"
+ },
+ "icon": {
+ "placeholder": "i-lucide-icon",
+ "searchPlaceholder": "Cerca icone...",
+ "noIconsFound": "Nessuna icona trovata",
+ "searchHint": "Digita almeno 2 caratteri per cercare",
+ "libraries": "Librerie:",
+ "allLibraries": "Tutte"
+ },
+ "text": {
+ "placeholder": "Inserisci testo...",
+ "selectPlaceholder": "Seleziona un'opzione..."
+ },
+ "date": {
+ "selectDate": "Seleziona data"
+ },
+ "number": {
+ "placeholder": "0"
}
}
}
diff --git a/src/app/src/locales/ja.json b/src/app/src/locales/ja.json
index 01ec04ba..cf541996 100644
--- a/src/app/src/locales/ja.json
+++ b/src/app/src/locales/ja.json
@@ -300,6 +300,31 @@
},
"section": {
"propertyCount": "1 プロパティ | {count} プロパティ"
+ },
+ "media": {
+ "placeholder": "相対パスまたは公開URL...",
+ "searchPlaceholder": "画像を検索...",
+ "noImagesFound": "画像が見つかりません",
+ "noImagesAvailable": "利用可能な画像がありません",
+ "imageCount": "{total}件中{count}件の画像"
+ },
+ "icon": {
+ "placeholder": "i-lucide-icon",
+ "searchPlaceholder": "アイコンを検索...",
+ "noIconsFound": "アイコンが見つかりません",
+ "searchHint": "検索するには2文字以上入力してください",
+ "libraries": "ライブラリ:",
+ "allLibraries": "すべて"
+ },
+ "text": {
+ "placeholder": "テキストを入力...",
+ "selectPlaceholder": "オプションを選択..."
+ },
+ "date": {
+ "selectDate": "日付を選択"
+ },
+ "number": {
+ "placeholder": "0"
}
}
}
diff --git a/src/app/src/locales/nb-no.json b/src/app/src/locales/nb-no.json
index d4eb3c7e..5d181324 100644
--- a/src/app/src/locales/nb-no.json
+++ b/src/app/src/locales/nb-no.json
@@ -301,6 +301,31 @@
},
"section": {
"propertyCount": "1 egenskap | {count} egenskaper"
+ },
+ "media": {
+ "placeholder": "Relativ sti eller offentlig URL...",
+ "searchPlaceholder": "Søk etter bilder...",
+ "noImagesFound": "Ingen bilder funnet",
+ "noImagesAvailable": "Ingen bilder tilgjengelig",
+ "imageCount": "{count} av {total} bilde | {count} av {total} bilder"
+ },
+ "icon": {
+ "placeholder": "i-lucide-icon",
+ "searchPlaceholder": "Søk etter ikoner...",
+ "noIconsFound": "Ingen ikoner funnet",
+ "searchHint": "Skriv minst 2 tegn for å søke",
+ "libraries": "Biblioteker:",
+ "allLibraries": "Alle"
+ },
+ "text": {
+ "placeholder": "Skriv inn tekst...",
+ "selectPlaceholder": "Velg et alternativ..."
+ },
+ "date": {
+ "selectDate": "Velg dato"
+ },
+ "number": {
+ "placeholder": "0"
}
}
}
diff --git a/src/app/src/locales/nl.json b/src/app/src/locales/nl.json
index 2dff6316..b3346838 100644
--- a/src/app/src/locales/nl.json
+++ b/src/app/src/locales/nl.json
@@ -301,6 +301,31 @@
},
"section": {
"propertyCount": "1 eigenschap | {count} eigenschappen"
+ },
+ "media": {
+ "placeholder": "Relatief pad of publieke URL...",
+ "searchPlaceholder": "Afbeeldingen zoeken...",
+ "noImagesFound": "Geen afbeeldingen gevonden",
+ "noImagesAvailable": "Geen afbeeldingen beschikbaar",
+ "imageCount": "{count} van {total} afbeelding | {count} van {total} afbeeldingen"
+ },
+ "icon": {
+ "placeholder": "i-lucide-icon",
+ "searchPlaceholder": "Iconen zoeken...",
+ "noIconsFound": "Geen iconen gevonden",
+ "searchHint": "Typ minimaal 2 tekens om te zoeken",
+ "libraries": "Bibliotheken:",
+ "allLibraries": "Alle"
+ },
+ "text": {
+ "placeholder": "Voer tekst in...",
+ "selectPlaceholder": "Selecteer een optie..."
+ },
+ "date": {
+ "selectDate": "Selecteer datum"
+ },
+ "number": {
+ "placeholder": "0"
}
}
}
diff --git a/src/app/src/locales/nn-no.json b/src/app/src/locales/nn-no.json
index f55f9ebd..4cf01eb1 100644
--- a/src/app/src/locales/nn-no.json
+++ b/src/app/src/locales/nn-no.json
@@ -301,6 +301,31 @@
},
"section": {
"propertyCount": "1 eigenskap | {count} eigenskapar"
+ },
+ "media": {
+ "placeholder": "Relativ sti eller offentleg URL...",
+ "searchPlaceholder": "Søk etter bilete...",
+ "noImagesFound": "Ingen bilete funne",
+ "noImagesAvailable": "Ingen bilete tilgjengelege",
+ "imageCount": "{count} av {total} bilete"
+ },
+ "icon": {
+ "placeholder": "i-lucide-icon",
+ "searchPlaceholder": "Søk etter ikon...",
+ "noIconsFound": "Ingen ikon funne",
+ "searchHint": "Skriv minst 2 teikn for å søkje",
+ "libraries": "Bibliotek:",
+ "allLibraries": "Alle"
+ },
+ "text": {
+ "placeholder": "Skriv inn tekst...",
+ "selectPlaceholder": "Vel eit alternativ..."
+ },
+ "date": {
+ "selectDate": "Vel dato"
+ },
+ "number": {
+ "placeholder": "0"
}
}
}
diff --git a/src/app/src/locales/pl.json b/src/app/src/locales/pl.json
index 622c0063..6323edab 100644
--- a/src/app/src/locales/pl.json
+++ b/src/app/src/locales/pl.json
@@ -301,6 +301,31 @@
},
"section": {
"propertyCount": "1 właściwość | {count} właściwości"
+ },
+ "media": {
+ "placeholder": "Ścieżka względna lub publiczny URL...",
+ "searchPlaceholder": "Szukaj obrazów...",
+ "noImagesFound": "Nie znaleziono obrazów",
+ "noImagesAvailable": "Brak dostępnych obrazów",
+ "imageCount": "{count} z {total} obraz | {count} z {total} obrazów"
+ },
+ "icon": {
+ "placeholder": "i-lucide-icon",
+ "searchPlaceholder": "Szukaj ikon...",
+ "noIconsFound": "Nie znaleziono ikon",
+ "searchHint": "Wpisz co najmniej 2 znaki aby szukać",
+ "libraries": "Biblioteki:",
+ "allLibraries": "Wszystkie"
+ },
+ "text": {
+ "placeholder": "Wprowadź tekst...",
+ "selectPlaceholder": "Wybierz opcję..."
+ },
+ "date": {
+ "selectDate": "Wybierz datę"
+ },
+ "number": {
+ "placeholder": "0"
}
}
}
diff --git a/src/app/src/locales/pt-br.json b/src/app/src/locales/pt-br.json
index ed88258f..7443186e 100644
--- a/src/app/src/locales/pt-br.json
+++ b/src/app/src/locales/pt-br.json
@@ -301,6 +301,31 @@
},
"section": {
"propertyCount": "1 propriedade | {count} propriedades"
+ },
+ "media": {
+ "placeholder": "Caminho relativo ou URL pública...",
+ "searchPlaceholder": "Pesquisar imagens...",
+ "noImagesFound": "Nenhuma imagem encontrada",
+ "noImagesAvailable": "Nenhuma imagem disponível",
+ "imageCount": "{count} de {total} imagem | {count} de {total} imagens"
+ },
+ "icon": {
+ "placeholder": "i-lucide-icon",
+ "searchPlaceholder": "Pesquisar ícones...",
+ "noIconsFound": "Nenhum ícone encontrado",
+ "searchHint": "Digite pelo menos 2 caracteres para pesquisar",
+ "libraries": "Bibliotecas:",
+ "allLibraries": "Todas"
+ },
+ "text": {
+ "placeholder": "Digite o texto...",
+ "selectPlaceholder": "Selecione uma opção..."
+ },
+ "date": {
+ "selectDate": "Selecionar data"
+ },
+ "number": {
+ "placeholder": "0"
}
}
}
diff --git a/src/app/src/locales/ua.json b/src/app/src/locales/ua.json
index 53d12bd0..d5a4bd3c 100644
--- a/src/app/src/locales/ua.json
+++ b/src/app/src/locales/ua.json
@@ -300,6 +300,31 @@
},
"section": {
"propertyCount": "1 властивість | {count} властивостей"
+ },
+ "media": {
+ "placeholder": "Відносний шлях або публічна URL...",
+ "searchPlaceholder": "Пошук зображень...",
+ "noImagesFound": "Зображень не знайдено",
+ "noImagesAvailable": "Немає доступних зображень",
+ "imageCount": "{count} з {total} зображення | {count} з {total} зображень"
+ },
+ "icon": {
+ "placeholder": "i-lucide-icon",
+ "searchPlaceholder": "Пошук іконок...",
+ "noIconsFound": "Іконок не знайдено",
+ "searchHint": "Введіть щонайменше 2 символи для пошуку",
+ "libraries": "Бібліотеки:",
+ "allLibraries": "Усі"
+ },
+ "text": {
+ "placeholder": "Введіть текст...",
+ "selectPlaceholder": "Оберіть опцію..."
+ },
+ "date": {
+ "selectDate": "Оберіть дату"
+ },
+ "number": {
+ "placeholder": "0"
}
}
}
diff --git a/src/app/src/locales/zh-tw.json b/src/app/src/locales/zh-tw.json
index 587a9ad2..49b37b82 100644
--- a/src/app/src/locales/zh-tw.json
+++ b/src/app/src/locales/zh-tw.json
@@ -301,6 +301,31 @@
},
"section": {
"propertyCount": "1 個屬性 | {count} 個屬性"
+ },
+ "media": {
+ "placeholder": "相對路徑或公開URL...",
+ "searchPlaceholder": "搜尋圖片...",
+ "noImagesFound": "找不到圖片",
+ "noImagesAvailable": "沒有可用的圖片",
+ "imageCount": "{total}張圖片中的{count}張"
+ },
+ "icon": {
+ "placeholder": "i-lucide-icon",
+ "searchPlaceholder": "搜尋圖示...",
+ "noIconsFound": "找不到圖示",
+ "searchHint": "輸入至少2個字元進行搜尋",
+ "libraries": "圖示庫:",
+ "allLibraries": "全部"
+ },
+ "text": {
+ "placeholder": "輸入文字...",
+ "selectPlaceholder": "選擇一個選項..."
+ },
+ "date": {
+ "selectDate": "選擇日期"
+ },
+ "number": {
+ "placeholder": "0"
}
}
}
diff --git a/src/app/src/locales/zh.json b/src/app/src/locales/zh.json
index 37e205dc..9fa424ca 100644
--- a/src/app/src/locales/zh.json
+++ b/src/app/src/locales/zh.json
@@ -301,6 +301,31 @@
},
"section": {
"propertyCount": "1 个属性 | {count} 个属性"
+ },
+ "media": {
+ "placeholder": "相对路径或公共URL...",
+ "searchPlaceholder": "搜索图片...",
+ "noImagesFound": "未找到图片",
+ "noImagesAvailable": "没有可用的图片",
+ "imageCount": "{total}张图片中的{count}张"
+ },
+ "icon": {
+ "placeholder": "i-lucide-icon",
+ "searchPlaceholder": "搜索图标...",
+ "noIconsFound": "未找到图标",
+ "searchHint": "输入至少2个字符进行搜索",
+ "libraries": "图标库:",
+ "allLibraries": "全部"
+ },
+ "text": {
+ "placeholder": "输入文本...",
+ "selectPlaceholder": "选择一个选项..."
+ },
+ "date": {
+ "selectDate": "选择日期"
+ },
+ "number": {
+ "placeholder": "0"
}
}
}
diff --git a/src/app/src/utils/form.ts b/src/app/src/utils/form.ts
index a9e65436..c15e1ec1 100644
--- a/src/app/src/utils/form.ts
+++ b/src/app/src/utils/form.ts
@@ -112,6 +112,9 @@ export const buildFormTreeFromSchema = (treeKey: string, schema: Draft07): FormT
if (def.enum && Array.isArray(def.enum) && def.enum.length > 0) {
item.options = def.enum as string[]
}
+ else if (editor?.iconLibraries && Array.isArray(editor.iconLibraries)) {
+ item.options = editor.iconLibraries
+ }
return item
}
@@ -133,6 +136,10 @@ export const buildFormTreeFromSchema = (treeKey: string, schema: Draft07): FormT
if (def.enum && Array.isArray(def.enum) && def.enum.length > 0) {
item.options = def.enum as string[]
}
+ // Pass iconLibraries from editor options for icon inputs
+ else if (editor?.iconLibraries && Array.isArray(editor.iconLibraries)) {
+ item.options = editor.iconLibraries as string[]
+ }
return item
}
diff --git a/src/app/test/unit/utils/form.test.ts b/src/app/test/unit/utils/form.test.ts
index 4ecd9858..8478bfca 100644
--- a/src/app/test/unit/utils/form.test.ts
+++ b/src/app/test/unit/utils/form.test.ts
@@ -234,6 +234,47 @@ describe('buildFormTreeFromSchema', () => {
})
})
+ test('handle iconLibraries from editor options for icon input', () => {
+ const schema: Draft07 = {
+ $schema: 'http://json-schema.org/draft-07/schema#',
+ $ref: '#/definitions/authors',
+ definitions: {
+ authors: {
+ type: 'object',
+ properties: {
+ icon: {
+ type: 'string',
+ $content: {
+ editor: {
+ input: 'icon',
+ iconLibraries: ['lucide', 'simple-icons'],
+ },
+ },
+ },
+ },
+ additionalProperties: false,
+ required: [],
+ },
+ },
+ }
+
+ expect(buildFormTreeFromSchema('authors', schema)).toStrictEqual({
+ authors: {
+ id: '#authors',
+ type: 'object',
+ title: 'Authors',
+ children: {
+ icon: {
+ id: '#authors/icon',
+ type: 'icon',
+ title: 'Icon',
+ options: ['lucide', 'simple-icons'],
+ },
+ },
+ },
+ })
+ })
+
test('hide field if set in editor metas', () => {
const schema: Draft07 = {
$schema: 'http://json-schema.org/draft-07/schema#',