diff --git a/apps/web/src/routes/categories/[categoryId]/prompt/+page.svelte b/apps/web/src/routes/categories/[categoryId]/prompt/+page.svelte index b01452c..ae0555b 100644 --- a/apps/web/src/routes/categories/[categoryId]/prompt/+page.svelte +++ b/apps/web/src/routes/categories/[categoryId]/prompt/+page.svelte @@ -20,7 +20,6 @@ import Spinner from "$lib/components/Spinner.svelte"; import ContentLanguageSwitcher from "$lib/components/ContentLanguageSwitcher.svelte"; import { - Badge, Button, Card, CardContent, @@ -103,7 +102,6 @@ let assignOpen = $state(false); let activeSection = $state("title"); - let preamble = $state(DEFAULT_ENHANCE_PREAMBLE); let sectionBodies = $state>({ title: "", description: "", @@ -138,14 +136,14 @@ function syncEditorFromStored(raw: string) { const parsed = parseEnhancePrompt(raw); - preamble = parsed.preamble || DEFAULT_ENHANCE_PREAMBLE; sectionBodies = { ...parsed.sections }; unstructuredHint = Boolean(raw.trim()) && !parsed.hasRoleSections; } function currentCombined(): string { - if (isEnhancePromptEmpty(preamble, sectionBodies)) return ""; - return composeEnhancePrompt(preamble, sectionBodies); + // Shared JSON schema intro is system-owned (not editable in the UI). + if (isEnhancePromptEmpty(DEFAULT_ENHANCE_PREAMBLE, sectionBodies)) return ""; + return composeEnhancePrompt(DEFAULT_ENHANCE_PREAMBLE, sectionBodies); } function flushEditorToLang() { @@ -247,7 +245,6 @@ } function clearLanguageOverride() { - preamble = DEFAULT_ENHANCE_PREAMBLE; sectionBodies = { title: "", description: "", meta: "", attributes: "" }; unstructuredHint = false; const next = { ...promptsByLang }; @@ -460,21 +457,7 @@ {i18n.t(sectionMeta.helpKey)} -
-
- - {i18n.t("categories.promptSection.schemaHeading")} - - {#each schemaHint.jsonKeys as key} - {key} - {/each} -
-

- {i18n.t("categories.promptSection.schemaHelp")} -

-
{schemaHint.example}
-

{i18n.t(sectionMeta.formulaNoteKey)}

-
+

{i18n.t(sectionMeta.formulaNoteKey)}

{#each sectionVars as v} @@ -521,25 +504,6 @@ {/if}

- -
- - {i18n.t("categories.promptSection.preambleToggle")} - -
-

- {i18n.t("categories.promptSection.preambleHelp")} -

-