ServerKit is a lightweight, modern server control panel for managing web applications, databases, and services on your VPS or dedicated server. Built with Python/Flask backend and React frontend.
Python astracloudflarecontrol-panelcyberpaneldnsfablehosting-control-panelhosting-panelkimi-k3server-managementserverkitubuntu-web-panelwebserver
Move extension, engine and server-template cards onto CatalogCard
Juan Denis3e7aedbf17a0
diff --git a/frontend/scripts/LOGICAL_PROPERTY_CEILING b/frontend/scripts/LOGICAL_PROPERTY_CEILINGindex c8eb5888..e828e5d0 100644--- a/frontend/scripts/LOGICAL_PROPERTY_CEILING+++ b/frontend/scripts/LOGICAL_PROPERTY_CEILING@@ -1 +1 @@-438+434diff --git a/frontend/scripts/check-frontend-boundaries.mjs b/frontend/scripts/check-frontend-boundaries.mjsindex d3e096ef..38c4c0e5 100644--- a/frontend/scripts/check-frontend-boundaries.mjs+++ b/frontend/scripts/check-frontend-boundaries.mjs@@ -73,14 +73,14 @@ const LEGACY_COLOR_LITERALS = new Map(Object.entries({'styles/pages/_backups.scss': 1,'styles/pages/_bandwidth.scss': 1,'styles/pages/_cutover.scss': 1,- 'styles/pages/_databases.scss': 4,+ 'styles/pages/_databases.scss': 3,'styles/pages/_deploy-console.scss': 14,'styles/pages/_doctor.scss': 1,'styles/pages/_domains.scss': 1,'styles/pages/_file-manager.scss': 10,'styles/pages/_git.scss': 6,'styles/pages/_import-wizard.scss': 1,- 'styles/pages/_marketplace.scss': 5,+ 'styles/pages/_marketplace.scss': 2,'styles/pages/_notification-center.scss': 4,'styles/pages/_settings.scss': 14,'styles/pages/_setup-wizard.scss': 5,diff --git a/frontend/src/components/databases/EngineCatalogDrawer.jsx b/frontend/src/components/databases/EngineCatalogDrawer.jsxindex 169e2c1e..b69bb4d7 100644--- a/frontend/src/components/databases/EngineCatalogDrawer.jsx+++ b/frontend/src/components/databases/EngineCatalogDrawer.jsx@@ -4,7 +4,7 @@ import {Layers, Check, Download, Loader2, PackageX, ShieldAlert, RefreshCw, ChevronRight,} from 'lucide-react';import api from '../../services/api';-import { Drawer, SearchField } from '@/components/ds';+import { Drawer, SearchField, CatalogCard, CatalogGrid } from '@/components/ds';import EmptyState from '../EmptyState';import { useToast } from '../../contexts/useToast.js';import EngineGlyph from './EngineGlyph';@@ -80,35 +80,26 @@ function EngineCard({ entry, onPick }) {].filter(Boolean).join(' · ');return (- <li className="dbx-engine-card">- <SharedButton variant="unstyled"- type="button"- className="dbx-engine-card__hit"- onClick={() => onPick(entry)}- aria-label={t('app.engineCatalogDrawer.install', 'Install {{name}}', { name: entry.name })}- >- <span className="dbx-engine-card__top">- <span className="dbx-eng-glyph dbx-eng-glyph--lg">- <EngineGlyph entry={entry} size={20} />- </span>- <span className="dbx-eng-rowtext">- <span className="dbx-eng-name">{entry.name}</span>- <span className="dbx-eng-sub">- {[entry.version ? `v${entry.version}` : null, entry.id].filter(Boolean).join(' · ')}- </span>- </span>- {meta.family && <span className="dbx-eng-family">{meta.family}</span>}- </span>- <span className="dbx-engine-card__desc">{entry.description}</span>- <span className="dbx-engine-card__foot">- <span className="dbx-eng-facts">{facts || ' '}</span>- <span className="dbx-engine-card__cta">- <Download size={12} aria-hidden="true" />- {entry.installed_count > 0 ? 'Add another' : 'Install'}- </span>- </span>- </SharedButton>- </li>+ <CatalogCard+ icon={<EngineGlyph entry={entry} size={20} />}+ title={entry.name}+ sub={[entry.version ? `v${entry.version}` : null, entry.id].filter(Boolean).join(' · ')}+ tag={meta.family}+ description={entry.description}+ facts={facts}+ onClick={() => onPick(entry)}+ action={(+ <SharedButton+ variant="outline"+ size="sm"+ onClick={() => onPick(entry)}+ aria-label={t('app.engineCatalogDrawer.install', 'Install {{name}}', { name: entry.name })}+ >+ <Download size={12} aria-hidden="true" />+ {entry.installed_count > 0 ? 'Add another' : 'Install'}+ </SharedButton>+ )}+ />);}@@ -255,11 +246,11 @@ export default function EngineCatalogDrawer({: t('app.engineCatalogDrawer.tryADifferentSearchTermOr', 'Try a different search term or clear the family filter.')}/>) : (- <ul className="dbx-engine-grid">+ <CatalogGrid>{results.map((entry) => (<EngineCard key={entry.id} entry={entry} onPick={onPick} />))}- </ul>+ </CatalogGrid>)}</section></>diff --git a/frontend/src/i18n/locales/ar.json b/frontend/src/i18n/locales/ar.jsonindex f653a373..ff901413 100644--- a/frontend/src/i18n/locales/ar.json+++ b/frontend/src/i18n/locales/ar.json@@ -2889,7 +2889,6 @@"extensionUpdatedToV": "تم تحديث الامتداد \"{{displayname}}\" إلى v{{version}}.","failedToLoadExtensions": "فشل تحميل الملحقات","failedToSaveConfiguration": "فشل حفظ التكوين",- "featured": "مميز","filterExtensions": "ملحقات التصفية","frontend": "الواجهة الأمامية","install": "ثَبَّتَ",diff --git a/frontend/src/i18n/locales/bn.json b/frontend/src/i18n/locales/bn.jsonindex eb15d90d..8217d7e8 100644--- a/frontend/src/i18n/locales/bn.json+++ b/frontend/src/i18n/locales/bn.json@@ -2889,7 +2889,6 @@"extensionUpdatedToV": "এক্সটেনশন \"{{displayname}}\" v{{version}} এ আপডেট করা হয়েছে।","failedToLoadExtensions": "এক্সটেনশনগুলি লোড করতে ব্যর্থ হয়েছে৷","failedToSaveConfiguration": "কনফিগারেশন সংরক্ষণ করতে ব্যর্থ হয়েছে",- "featured": "বৈশিষ্ট্যযুক্ত","filterExtensions": "ফিল্টার এক্সটেনশন","frontend": "ফ্রন্টেন্ড","install": "ইনস্টল করুন",diff --git a/frontend/src/i18n/locales/de.json b/frontend/src/i18n/locales/de.jsonindex ffb10f0a..7ce3c258 100644--- a/frontend/src/i18n/locales/de.json+++ b/frontend/src/i18n/locales/de.json@@ -2889,7 +2889,6 @@"extensionUpdatedToV": "Erweiterung „{{displayname}}“ auf v{{version}} aktualisiert.","failedToLoadExtensions": "Erweiterungen konnten nicht geladen werden","failedToSaveConfiguration": "Die Konfiguration konnte nicht gespeichert werden",- "featured": "Hervorgehoben","filterExtensions": "Erweiterungen filtern","frontend": "Frontend","install": "Installieren",diff --git a/frontend/src/i18n/locales/en.json b/frontend/src/i18n/locales/en.jsonindex 358f9641..d0657dbb 100644--- a/frontend/src/i18n/locales/en.json+++ b/frontend/src/i18n/locales/en.json@@ -3175,7 +3175,6 @@"extensionUpdatedToV": "Extension \"{{displayname}}\" updated to v{{version}}.","failedToLoadExtensions": "Failed to load extensions","failedToSaveConfiguration": "Failed to save configuration",- "featured": "Featured","filterExtensions": "Filter extensions","frontend": "Frontend","install": "Install",@@ -3184,9 +3183,11 @@"installUnreviewedExtension": "Install unreviewed extension?","installWithAnUnverifiableSignature": "Install with an unverifiable signature?","installWithoutChecksumVerification": "Install without checksum verification?",+ "installed": "Installed","installedExtensions": "Installed extensions","installedHotReloadShouldPickIt": "Installed \"{{displayname}}\". Hot-reload should pick it up; restart backend if blueprint routes do not appear.","installedRestartBackendIfBlueprintRoutes": "Installed \"{{displayname}}\". Restart backend if blueprint routes do not appear.",+ "installing": "Installing...","itRunsWithFullPanelPrivileges": "It runs with full panel privileges. Only install it if you trust the author.","keepData": "Keep data","leavesTheExtensionSDatabaseTables": "leaves the extension's database tables intact so you can reinstall later.",@@ -3220,7 +3221,8 @@"unreviewed": "Unreviewed","unsigned": "Unsigned","update": "Update",- "updateAvailableV": "Update available → v"+ "updateAvailableV": "Update available → v",+ "versionByAuthor": "v{{version}} · by {{author}}"},"memberActionsCard": {"allowMembersToRunCuratedActions": "Allow members to run curated actions",@@ -4893,8 +4895,13 @@"firewall": "Firewall","firewallRules": "firewall rules","library": "Library",+ "nPackages": "{{n}} packages",+ "nServices": "{{n}} services","nginxPhpFpmCertbot": "nginx\nphp-fpm\ncertbot","noTemplatesYet": "No templates yet",+ "oneFirewallRule": "1 firewall rule",+ "onePackage": "1 package",+ "oneService": "1 service","packages": "Packages","packagesOnePerLine": "Packages (one per line)","remediation": "Remediation",diff --git a/frontend/src/i18n/locales/es.json b/frontend/src/i18n/locales/es.jsonindex 9f59dedc..73d24e4e 100644--- a/frontend/src/i18n/locales/es.json+++ b/frontend/src/i18n/locales/es.json@@ -2890,7 +2890,6 @@"extensionUpdatedToV": "Extensión \"{{displayname}}\" actualizada a v{{version}}.","failedToLoadExtensions": "No se pudieron cargar las extensiones","failedToSaveConfiguration": "No se pudo guardar la configuración",- "featured": "Destacadas","filterExtensions": "Filtrar extensiones","frontend": "Frontend","install": "Instalar",diff --git a/frontend/src/i18n/locales/fr.json b/frontend/src/i18n/locales/fr.jsonindex 52720831..61e48f48 100644--- a/frontend/src/i18n/locales/fr.json+++ b/frontend/src/i18n/locales/fr.json@@ -2889,7 +2889,6 @@"extensionUpdatedToV": "Extension « {{displayname}} » mise à jour vers v{{version}}.","failedToLoadExtensions": "Échec du chargement des extensions","failedToSaveConfiguration": "Échec de l'enregistrement de la configuration",- "featured": "En vedette","filterExtensions": "Filtrer les extensions","frontend": "L'extrémité avant","install": "Installer",diff --git a/frontend/src/i18n/locales/id.json b/frontend/src/i18n/locales/id.jsonindex 8aa6cb13..46aed77f 100644--- a/frontend/src/i18n/locales/id.json+++ b/frontend/src/i18n/locales/id.json@@ -2889,7 +2889,6 @@"extensionUpdatedToV": "Ekstensi \"{{displayname}}\" diperbarui menjadi v{{version}}.","failedToLoadExtensions": "Gagal memuat ekstensi","failedToSaveConfiguration": "Gagal menyimpan konfigurasi",- "featured": "Unggulan","filterExtensions": "Filter ekstensi","frontend": "Bagian depan","install": "Memasang",diff --git a/frontend/src/i18n/locales/it.json b/frontend/src/i18n/locales/it.jsonindex 0aada37f..90c69a1f 100644--- a/frontend/src/i18n/locales/it.json+++ b/frontend/src/i18n/locales/it.json@@ -2889,7 +2889,6 @@"extensionUpdatedToV": "Estensione \"{{displayname}}\" aggiornata a v{{version}}.","failedToLoadExtensions": "Impossibile caricare le estensioni","failedToSaveConfiguration": "Impossibile salvare la configurazione",- "featured": "In primo piano","filterExtensions": "Filtra le estensioni","frontend": "Fine frontale","install": "Installare",diff --git a/frontend/src/i18n/locales/ko.json b/frontend/src/i18n/locales/ko.jsonindex f124fd84..32d9a516 100644--- a/frontend/src/i18n/locales/ko.json+++ b/frontend/src/i18n/locales/ko.json@@ -2889,7 +2889,6 @@"extensionUpdatedToV": "확장 프로그램 \"{{displayname}}\"이(가) v{{version}}으로 업데이트되었습니다.","failedToLoadExtensions": "확장 프로그램을 로드하지 못했습니다.","failedToSaveConfiguration": "구성을 저장하지 못했습니다.",- "featured": "추천","filterExtensions": "확장 프로그램 필터링","frontend": "프런트엔드","install": "설치",diff --git a/frontend/src/i18n/locales/pl.json b/frontend/src/i18n/locales/pl.jsonindex 35515012..44686fc9 100644--- a/frontend/src/i18n/locales/pl.json+++ b/frontend/src/i18n/locales/pl.json@@ -2889,7 +2889,6 @@"extensionUpdatedToV": "Rozszerzenie „{{displayname}}” zaktualizowane do wersji v{{version}}.","failedToLoadExtensions": "Nie udało się załadować rozszerzeń","failedToSaveConfiguration": "Nie udało się zapisać konfiguracji",- "featured": "Wyróżniony","filterExtensions": "Rozszerzenia filtrów","frontend": "Frontend","install": "Zainstalować",diff --git a/frontend/src/i18n/locales/pt.json b/frontend/src/i18n/locales/pt.jsonindex bda42caa..9d3315c6 100644--- a/frontend/src/i18n/locales/pt.json+++ b/frontend/src/i18n/locales/pt.json@@ -2889,7 +2889,6 @@"extensionUpdatedToV": "Extensão \"{{displayname}}\" atualizada para v{{version}}.","failedToLoadExtensions": "Falha ao carregar extensões","failedToSaveConfiguration": "Falha ao salvar a configuração",- "featured": "Destaque","filterExtensions": "Extensões de filtro","frontend": "Interface","install": "Instalar",diff --git a/frontend/src/i18n/locales/ru.json b/frontend/src/i18n/locales/ru.jsonindex b45c90a2..82bafb7a 100644--- a/frontend/src/i18n/locales/ru.json+++ b/frontend/src/i18n/locales/ru.json@@ -2889,7 +2889,6 @@"extensionUpdatedToV": "Расширение \"{{displayname}}\" обновлено до версии v{{version}}.","failedToLoadExtensions": "Не удалось загрузить расширения.","failedToSaveConfiguration": "Не удалось сохранить конфигурацию.",- "featured": "Рекомендуемые","filterExtensions": "Фильтровать расширения","frontend": "Внешний интерфейс","install": "Установить",diff --git a/frontend/src/i18n/locales/th.json b/frontend/src/i18n/locales/th.jsonindex 60e064aa..f9415099 100644--- a/frontend/src/i18n/locales/th.json+++ b/frontend/src/i18n/locales/th.json@@ -2889,7 +2889,6 @@"extensionUpdatedToV": "ส่วนขยาย \"{{displayname}}\" อัปเดตเป็น v{{version}}","failedToLoadExtensions": "โหลดส่วนขยายไม่สำเร็จ","failedToSaveConfiguration": "บันทึกการกำหนดค่าไม่สำเร็จ",- "featured": "โดดเด่น","filterExtensions": "กรองส่วนขยาย","frontend": "ส่วนหน้า","install": "ติดตั้ง",diff --git a/frontend/src/i18n/locales/tr.json b/frontend/src/i18n/locales/tr.jsonindex 11ea3368..3aa6a5b9 100644--- a/frontend/src/i18n/locales/tr.json+++ b/frontend/src/i18n/locales/tr.json@@ -2889,7 +2889,6 @@"extensionUpdatedToV": "\"{{displayname}}\" uzantısı v{{version}} olarak güncellendi.","failedToLoadExtensions": "Uzantılar yüklenemedi","failedToSaveConfiguration": "Yapılandırma kaydedilemedi",- "featured": "Öne Çıkanlar","filterExtensions": "Uzantıları filtrele","frontend": "Başlangıç aşaması","install": "Düzenlemek",diff --git a/frontend/src/i18n/locales/vi.json b/frontend/src/i18n/locales/vi.jsonindex 7aa5bb09..47fd614b 100644--- a/frontend/src/i18n/locales/vi.json+++ b/frontend/src/i18n/locales/vi.json@@ -2889,7 +2889,6 @@"extensionUpdatedToV": "Tiện ích mở rộng \"{{displayname}}\" đã được cập nhật thành v{{version}}.","failedToLoadExtensions": "Không tải được tiện ích mở rộng","failedToSaveConfiguration": "Không lưu được cấu hình",- "featured": "Nổi bật","filterExtensions": "Lọc tiện ích mở rộng","frontend": "Giao diện người dùng","install": "Cài đặt",diff --git a/frontend/src/i18n/locales/zh-Hans.json b/frontend/src/i18n/locales/zh-Hans.jsonindex 22112e16..881548e0 100644--- a/frontend/src/i18n/locales/zh-Hans.json+++ b/frontend/src/i18n/locales/zh-Hans.json@@ -2889,7 +2889,6 @@"extensionUpdatedToV": "扩展程序“{{displayname}}”已更新至 v{{version}}。","failedToLoadExtensions": "无法加载扩展","failedToSaveConfiguration": "保存配置失败",- "featured": "精选","filterExtensions": "过滤器扩展","frontend": "前端","install": "安装",diff --git a/frontend/src/i18n/locales/zh-Hant.json b/frontend/src/i18n/locales/zh-Hant.jsonindex 03fc087e..fc7e29cc 100644--- a/frontend/src/i18n/locales/zh-Hant.json+++ b/frontend/src/i18n/locales/zh-Hant.json@@ -3080,7 +3080,6 @@"extensionUpdatedToV": "擴充“{{displayname}}”更新為 v{{version}}。","failedToLoadExtensions": "無法載入擴充功能","failedToSaveConfiguration": "儲存設定失敗",- "featured": "精選","filterExtensions": "篩選擴充功能","frontend": "前端","install": "安裝",diff --git a/frontend/src/pages/Marketplace.jsx b/frontend/src/pages/Marketplace.jsxindex 0f559258..4a68ad8a 100644--- a/frontend/src/pages/Marketplace.jsx+++ b/frontend/src/pages/Marketplace.jsx@@ -17,7 +17,6 @@ import {ShieldCheck,ShieldQuestion,Sparkles,- Star,UploadCloud,} from 'lucide-react';import api from '../services/api';@@ -30,6 +29,7 @@ import { Button } from '@/components/ui/button';import { Badge } from '@/components/ui/badge';import {SearchField, FilterDrawer, FilterButton, countActiveFilters,+ CatalogCard, CatalogGrid,} from '@/components/ds';import { useTopbarActions } from '@/hooks/useTopbarActions';import ManualInstallModal from '../components/marketplace/ManualInstallModal';@@ -544,7 +544,7 @@ const Marketplace = () => {<section className="marketplace-section">{catalogEntries.length > 0 ? (- <div className="extensions-grid">+ <CatalogGrid>{catalogEntries.map((entry) => (<CatalogExtensionCardkey={entry.key}@@ -552,10 +552,9 @@ const Marketplace = () => {installing={installing}onInstall={() => installEntry(entry)}onOpenDetail={setDetailEntry}- statusVariant={pluginStatusVariant}/>))}- </div>+ </CatalogGrid>) : (<EmptyStateicon={Package}@@ -719,8 +718,8 @@ const SectionHeader = ({ title, meta }) => (// glyph fallbacks keep the deterministic gradient so they stay legible. The// tile is chosen from what actually renders, so a registry logo that fails to// load falls back to the gradient instead of a white glyph on white. `base` is-// the cover class ('extension-card__cover' or 'extension-detail__cover'); both-// the card and the detail modal share this component.+// the cover class ('sk-catalog-card__art' for the compact catalog-card icon,+// 'extension-detail__cover' for the modal banner); both share this component.const ExtensionCover = ({ base, entry, category, brandSize = 34, children }) => {const [logoFailed, setLogoFailed] = useState(false);const rasterIcon = resolveExtensionIcon(entry.installKey, category);@@ -779,77 +778,69 @@ const ExtensionGlyph = ({ entry, category, brandSize }) => {return <Icon aria-hidden="true" className="extension-card__glyph" />;};-const CatalogExtensionCard = ({ entry, installing, onInstall, onOpenDetail, statusVariant }) => {+// Trust as a plain-text fact on the card: only the two states that carry+// information (a hash-bound review, or a registry entry nobody reviewed).+// Built-in entries never carry a trust field, so they show nothing.+const TrustFact = ({ entry }) => {+ const { t } = useTranslation();+ if (entry.trust === 'reviewed') {+ const review = entry.review || {};+ const title = review.reviewer && review.date+ ? `Reviewed by ${review.reviewer} on ${review.date}`+ : 'Reviewed by the ServerKit maintainers';+ return <span title={title}>{t('app.marketplace.reviewed', 'Reviewed')}</span>;+ }+ if (entry.trust === 'unreviewed' && entry.source === 'registry') {+ return <span>{t('app.marketplace.unreviewed', 'Unreviewed')}</span>;+ }+ return null;+};++const CatalogExtensionCard = ({ entry, installing, onInstall, onOpenDetail }) => {const { t } = useTranslation();const category = entry.category || 'utility';const isLocal = entry.source === 'local';const installedLabel = entry.status && entry.status !== 'active'? titleCase(entry.status)- : 'Installed';-- const openDetail = () => onOpenDetail(entry);- const handleKeyDown = (event) => {- if (event.key === 'Enter' || event.key === ' ') {- event.preventDefault();- openDetail();- }- };+ : t('app.marketplace.installed', 'Installed');+ const hasTrustFact = entry.trust === 'reviewed'+ || (entry.trust === 'unreviewed' && entry.source === 'registry');return (- <article- className={`extension-card extension-card--${entry.source} extension-card--${category} extension-card--clickable card${entry.featured ? ' extension-card--featured' : ''}`}- role="button"- tabIndex={0}- onClick={openDetail}- onKeyDown={handleKeyDown}- >- <ExtensionCover base="extension-card__cover" entry={entry} category={category} brandSize={34}>- {entry.featured && (- <span className="extension-featured-badge">- <Star aria-hidden="true" /> {t('app.marketplace.featured', 'Featured')}- </span>- )}- </ExtensionCover>- <div className="extension-card__badges">- <Badge variant={sourceBadgeVariant(entry.source)}>{entry.sourceLabel}</Badge>- <Badge variant="outline">{titleCase(category)}</Badge>- </div>- <div className="extension-card__body">- <h3>{entry.displayName}</h3>- <p className="extension-card__desc">{entry.description}</p>- </div>- <div className="extension-card__footer">- <div className="extension-card__info">- <span>v{entry.version}</span>- {entry.firstParty ? (- <Badge variant="secondary" className="extension-firstparty">{t('app.marketplace.byServerkit2', 'by ServerKit')}</Badge>- ) : (- entry.author && <span>by {entry.author}</span>- )}- <TrustBadge entry={entry} />- </div>- <div className="extension-card__actions">- {entry.installed ? (- <Badge variant={isLocal ? statusVariant(entry.status) : 'success'}>- <CheckCircle2 aria-hidden="true" />- {installedLabel}- </Badge>- ) : (- <Button- size="sm"- disabled={installing}- onClick={(event) => {- event.stopPropagation();- onInstall(entry.installKey);- }}- >- <DownloadCloud aria-hidden="true" />- {installing ? 'Installing...' : 'Install'}- </Button>- )}- </div>- </div>- </article>+ <CatalogCard+ icon={<ExtensionCover base="sk-catalog-card__art" entry={entry} category={category} brandSize={20} />}+ title={entry.displayName}+ sub={t('app.marketplace.versionByAuthor', 'v{{version}} · by {{author}}', {+ version: entry.version,+ author: entry.author || 'ServerKit',+ })}+ tag={titleCase(category)}+ featured={entry.featured}+ description={entry.description}+ facts={(isLocal || hasTrustFact) && (+ <>+ {isLocal && t('app.marketplace.builtIn', 'Built-in')}+ {isLocal && hasTrustFact && ' · '}+ <TrustFact entry={entry} />+ </>+ )}+ onClick={() => onOpenDetail(entry)}+ action={entry.installed ? (+ <span className="marketplace-installed-label">{installedLabel}</span>+ ) : (+ <Button+ variant="outline"+ size="sm"+ disabled={installing}+ onClick={() => onInstall(entry.installKey)}+ >+ <DownloadCloud aria-hidden="true" />+ {installing+ ? t('app.marketplace.installing', 'Installing...')+ : t('app.marketplace.install', 'Install')}+ </Button>+ )}+ />);};diff --git a/frontend/src/pages/ServerTemplates.jsx b/frontend/src/pages/ServerTemplates.jsxindex d5637acf..504c948f 100644--- a/frontend/src/pages/ServerTemplates.jsx+++ b/frontend/src/pages/ServerTemplates.jsx@@ -1,4 +1,3 @@-import { Card as SharedCard } from '@/components/ui/card';import { useState, useEffect, useCallback, useMemo } from 'react';import { useTopbarActions, useTopbarChrome } from '@/hooks/useTopbarActions';import { useTableSort } from '@/hooks/useTableSort';@@ -16,7 +15,7 @@ import { Input } from '@/components/ui/input';import { Textarea } from '@/components/ui/textarea';import { Badge } from '@/components/ui/badge';import { Tabs, TabsList, TabsTrigger, TabsContent } from '@/components/ui/tabs';-import { DataTable, Pill } from '@/components/ds';+import { DataTable, Pill, CatalogCard, CatalogGrid } from '@/components/ds';import { useTranslation } from 'react-i18next';import {useTableChrome, GridViewPicker, GridChips, GridFilterButton,@@ -41,6 +40,12 @@ const CATEGORY_LABELS = {const categoryLabel = (tmpl) => CATEGORY_LABELS[tmpl.category] || tmpl.category || 'General';+// Library card facts: a zero count is left out rather than printed.+const countLabel = (n, one, many) => {+ if (!n) return null;+ return n === 1 ? one : many(n);+};+// Auto-remediation is three states, not two booleans, and the difference is// the whole risk story: Manual never touches a server, "on approval" waits for// a human, "unattended" rewrites the box by itself. Collapsed into one enum so@@ -369,8 +374,8 @@ const ServerTemplates = () => {value: categoryLabel,groupValue: categoryLabel,sortValue: categoryLabel,- // Badge, not Pill: the library cards label this exact field with a- // Badge, and the same datum should not change shape between tabs.+ // Badge, not Pill: a category is a neutral label, not a status, so+ // it gets no tone.render: (tmpl) => <Badge variant="outline">{categoryLabel(tmpl)}</Badge>,},{@@ -588,27 +593,33 @@ const ServerTemplates = () => {</TabsContent><TabsContent value="library">- <div className="templates-grid">+ <CatalogGrid className="server-templates-library">{Object.entries(library).map(([key, tmpl]) => (- <SharedCard variant="legacy" key={key} className="template-card card">- <div className="template-card__header">- <h3>{tmpl.name}</h3>- <Badge variant="outline">{CATEGORY_LABELS[tmpl.category] || tmpl.category}</Badge>- </div>- <p className="template-card__desc">{tmpl.description}</p>- <div className="template-card__spec">- {tmpl.packages?.length > 0 && <span>{tmpl.packages.length} packages</span>}- {tmpl.services?.length > 0 && <span>{tmpl.services.length} services</span>}- {tmpl.firewall_rules?.length > 0 && <span>{tmpl.firewall_rules.length} {t('app.serverTemplates.firewallRules', 'firewall rules')}</span>}- </div>- <div className="template-card__actions">- <Button size="sm" onClick={() => handleCreateFromLibrary(key)}>+ <CatalogCard+ key={key}+ icon={<LayoutTemplate size={18} />}+ title={tmpl.name}+ tag={categoryLabel(tmpl)}+ description={tmpl.description}+ facts={[+ countLabel(tmpl.packages?.length,+ t('app.serverTemplates.onePackage', '1 package'),+ (n) => t('app.serverTemplates.nPackages', '{{n}} packages', { n })),+ countLabel(tmpl.services?.length,+ t('app.serverTemplates.oneService', '1 service'),+ (n) => t('app.serverTemplates.nServices', '{{n}} services', { n })),+ countLabel(tmpl.firewall_rules?.length,+ t('app.serverTemplates.oneFirewallRule', '1 firewall rule'),+ (n) => `${n} ${t('app.serverTemplates.firewallRules', 'firewall rules')}`),+ ].filter(Boolean).join(' · ')}+ action={(+ <Button variant="outline" size="sm" onClick={() => handleCreateFromLibrary(key)}>{t('app.serverTemplates.useTemplate', 'Use Template')}</Button>- </div>- </SharedCard>+ )}+ />))}- </div>+ </CatalogGrid></TabsContent></Tabs>diff --git a/frontend/src/styles/pages/_databases.scss b/frontend/src/styles/pages/_databases.scssindex 1882196e..3548a2f5 100644--- a/frontend/src/styles/pages/_databases.scss+++ b/frontend/src/styles/pages/_databases.scss@@ -1455,13 +1455,6 @@ $dbx-sqlite: #3d8fd1;height: 24px;flex-shrink: 0;color: $text-secondary;-- &--lg {- width: 38px;- height: 38px;- background: $bg-tertiary;- border-radius: $radius-md;- }}.dbx-eng-img { object-fit: contain; border-radius: 3px; }@@ -1482,23 +1475,6 @@ $dbx-sqlite: #3d8fd1;@include dbx-trunc;}-.dbx-eng-family {- flex-shrink: 0;- color: $text-tertiary;- font-family: $font-mono;- font-size: 10px;- letter-spacing: 0.04em;- text-transform: uppercase;-}--.dbx-eng-facts {- min-width: 0;- color: $text-tertiary;- font-family: $font-mono;- font-size: 11px;- @include dbx-trunc;-}-.dbx-eng-badge {display: inline-flex;align-items: center;@@ -1533,72 +1509,6 @@ $dbx-sqlite: #3d8fd1;&:first-child { border-top: none; }}-.dbx-engine-grid {- display: grid;- grid-template-columns: repeat(auto-fill, minmax(228px, 1fr));- gap: $space-3;- list-style: none;- margin: 0;- padding: 0;-}--.dbx-engine-card {- display: flex;-- // The whole card is the hit target — a card you can only activate by its- // small "Install" label is a card that reads as clickable and isn't.- &__hit {- display: flex;- flex-direction: column;- gap: 9px;- width: 100%;- min-height: 168px;- padding: $space-3;- background: $bg-elevated;- border: 1px solid $border-default;- border-radius: $radius-md;- text-align: left;- cursor: pointer;- transition: border-color $transition-fast, background $transition-fast, transform $transition-fast;-- &:hover {- border-color: $accent-primary;- background: $bg-hover;- transform: translateY(-1px);- }- &:focus-visible { outline: 2px solid $accent-primary; outline-offset: 2px; }- }-- &__top { display: flex; align-items: flex-start; gap: $space-2; }-- &__desc {- flex: 1;- color: $text-tertiary;- font-size: $font-size-xs;- line-height: 1.5;- }-- &__foot {- display: flex;- align-items: center;- justify-content: space-between;- gap: $space-2;- }-- &__cta {- display: inline-flex;- align-items: center;- gap: 5px;- flex-shrink: 0;- padding: 3px 10px;- background: $accent-primary;- border-radius: $radius-sm;- color: #fff;- font-size: $font-size-xs;- font-weight: $font-weight-semibold;- }-}-// ─── Engine picker (create-database modal) ────────────────.dbx-eng-pick {display: grid;@@ -1647,7 +1557,6 @@ $dbx-sqlite: #3d8fd1;@media (prefers-reduced-motion: reduce) {.dbx-spin { animation: none; }- .dbx-engine-card__hit:hover { transform: none; }}// ============================================diff --git a/frontend/src/styles/pages/_marketplace.scss b/frontend/src/styles/pages/_marketplace.scssindex 4c41f205..e1c22ecc 100644--- a/frontend/src/styles/pages/_marketplace.scss+++ b/frontend/src/styles/pages/_marketplace.scss@@ -84,160 +84,31 @@}}- .extensions-grid {- display: grid;- grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));- gap: $space-3;- }-- .extension-card {- display: flex;- flex-direction: column;- gap: $space-3;- padding: $space-4;- background: $bg-card;- transition:- transform $transition-base,- border-color $transition-base,- box-shadow $transition-base;-- &:hover {- transform: translateY(-2px);- border-color: $border-active;- box-shadow: var(--shadow-lg);- }- }-- .extension-card--clickable {- cursor: pointer;-- &:focus-visible {- outline: 2px solid $accent-primary;- outline-offset: 2px;- }- }-- // Cover banner. Gradient variant (per-slug hue set inline via- // extensionCoverStyle) holds the brand mark / manifest icon / category glyph.- .extension-card__cover {- position: relative;+ // ExtensionCover in compact form: the CatalogCard's 36px icon slot. It+ // keeps the cover's fallback chain (light tile for image art, per-slug+ // gradient for the white brand mark / glyph), just at icon size.+ .sk-catalog-card__art {display: grid;place-items: center;- height: 140px;- border-radius: $radius-md;- overflow: hidden;+ width: 100%;+ height: 100%;- // Illustrated-icon variant: a clean light tile that lets the colourful- // 3D art sit centred with breathing room (drawn for a light backdrop).&--icon {background: #fff;}- }-- // Featured ribbon (top-left of the cover). Driven by manifest `featured`;- // the feature_score only orders cards, it is not shown.- .extension-featured-badge {- position: absolute;- top: 8px;- left: 8px;- z-index: 2;- display: inline-flex;- align-items: center;- gap: 4px;- padding: 3px 9px 3px 7px;- border-radius: $radius-full;- background: linear-gradient(135deg, #f7b733, #fc9d3c);- color: #1c1200;- font-size: 11px;- font-weight: 700;- box-shadow: 0 2px 6px rgba(0, 0, 0, 0.28);- svg {- width: 12px;- height: 12px;- fill: currentColor;+ .extension-card__brand,+ .extension-card__glyph {+ color: rgba(255, 255, 255, 0.92);}- }-- .extension-card--featured {- border-color: rgba(247, 183, 51, 0.5);- box-shadow: 0 0 0 1px rgba(247, 183, 51, 0.22);- }-- .extension-card__brand,- .extension-card__glyph {- color: rgba(255, 255, 255, 0.92);- }-- .extension-card__glyph {- width: 34px;- height: 34px;- }-- // Registry logos and bundled illustrated icons share one size (never- // stretched or zoomed) so every card reads consistently with room around- // the art; registry logos are normalized to the same fill at the source.- .extension-card__icon {- width: 92px;- height: 92px;- max-width: 66%;- object-fit: contain;- }-- .extension-card__footer,- .extension-card__info,- .extension-card__actions {- display: flex;- align-items: center;- }- .extension-card__footer {- justify-content: space-between;- gap: $space-3;- }-- .extension-card__badges {- display: flex;- align-items: center;- gap: $space-2;- flex-wrap: wrap;- min-width: 0;- }-- .extension-card__body {- min-width: 0;-- h3 {- margin: 0 0 $space-2;- color: $text-primary;- font-size: $font-size-md;- line-height: $line-height-tight;- letter-spacing: 0;+ .extension-card__glyph {+ width: 20px;+ height: 20px;}}- .extension-card__desc {- display: -webkit-box;- min-height: 40px;- margin: 0;- overflow: hidden;- color: $text-secondary;- font-size: $font-size-base;- line-height: $line-height-normal;- -webkit-box-orient: vertical;- -webkit-line-clamp: 2;- }-- .extension-card__footer {- margin-top: auto;- padding-top: $space-3;- border-top: 1px solid $border-subtle;- }-- .extension-card__info {- flex-wrap: wrap;- gap: $space-2;- min-width: 0;+ .marketplace-installed-label {color: $text-tertiary;font-size: $font-size-sm;}@@ -360,10 +231,6 @@}}- .extensions-grid {- grid-template-columns: 1fr;- }-.installed-item {align-items: flex-start;flex-direction: column;@@ -383,23 +250,13 @@align-items: flex-start;flex-direction: column;}-- .extension-card__footer {- align-items: flex-start;- flex-direction: column;- }-- .extension-card__actions,- .extension-card__actions .btn {- width: 100%;- }}}-// First-party "by ServerKit" badge. Rendered both inside .marketplace-page-// (cards) and inside the detail Modal (a Radix portal outside the page tree),-// so it lives at the root. Matches the `secondary` variant selector specificity-// and wins on source order to apply the accent tint.+// First-party "by ServerKit" badge, rendered in the detail Modal (a Radix+// portal outside the page tree), so it lives at the root. Matches the+// `secondary` variant selector specificity and wins on source order to apply+// the accent tint.[data-slot='badge'].extension-firstparty {gap: 4px;border-color: var(--accent-dim);diff --git a/frontend/src/styles/pages/_server-templates.scss b/frontend/src/styles/pages/_server-templates.scssindex f0600310..1b86640f 100644--- a/frontend/src/styles/pages/_server-templates.scss+++ b/frontend/src/styles/pages/_server-templates.scss@@ -1,66 +1,10 @@// Server Templates page styles.server-templates-page {- .templates-grid {- display: grid;- grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));- gap: $space-6;- margin-top: $space-6;- }-- .template-card {- padding: $space-6;- display: flex;- flex-direction: column;- gap: $space-2;- cursor: pointer;- transition: border-color 0.15s;-- &:hover {- border-color: $accent-primary;- }-- &__header {- display: flex;- justify-content: space-between;- align-items: center;-- h3 { margin: 0; }- }-- &__desc {- color: $text-secondary;- font-size: 0.9rem;- margin: 0;- }-- &__meta {- display: flex;- gap: $space-4;- font-size: 0.85rem;- color: $text-tertiary;- }-- &__spec {- display: flex;- flex-wrap: wrap;- gap: $space-1;-- span {- font-size: 0.8rem;- padding: 2px 8px;- background: $bg-hover;- border-radius: $radius-sm;- }- }-- &__actions {- display: flex;- gap: $space-2;- margin-top: $space-2;- padding-top: $space-2;- border-top: 1px solid $border-default;- }+ // Wider columns than the catalog default: the facts line spells out three+ // counts, and at the default width it truncates mid-word.+ .server-templates-library {+ grid-template-columns: repeat(auto-fill, minmax(min(420px, 100%), 1fr));}.server-select-list {