Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
69416faca9 | ||
|
|
ee6fbc784f |
+1
-1
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
|
||||
|
||||
[project]
|
||||
name = "govoplan-templates"
|
||||
version = "0.1.19"
|
||||
version = "0.1.21"
|
||||
description = "GovOPlaN typed template library and deterministic printable rendering."
|
||||
readme = "README.md"
|
||||
requires-python = ">=3.12"
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
"""GovOPlaN Templates module."""
|
||||
|
||||
__version__ = "0.1.19"
|
||||
__version__ = "0.1.21"
|
||||
|
||||
@@ -0,0 +1,58 @@
|
||||
"""German translations for public structured documentation metadata."""
|
||||
|
||||
from __future__ import annotations
|
||||
|
||||
from typing import Any
|
||||
|
||||
|
||||
GERMAN_STRUCTURED_TRANSLATIONS: dict[str, dict[str, Any]] = {'templates.data-subject-requests': {'consequence_classes': {'exclude_template_payloads': 'Gibt '
|
||||
'keinen '
|
||||
'Template-Inhalt '
|
||||
'zurück '
|
||||
'oder '
|
||||
'rendert '
|
||||
'Inputs '
|
||||
'und '
|
||||
'Outputs.',
|
||||
'export_template_attribution': 'Returns '
|
||||
'minimiert '
|
||||
'Autor, '
|
||||
'Publikation '
|
||||
'und '
|
||||
'Render-Aktivität.'}},
|
||||
'templates.reference.fields-and-consequences': {'consequence_classes': {'delete_template': 'Verhindert '
|
||||
'zukünftige '
|
||||
'Auswahl, '
|
||||
'ohne '
|
||||
'beibehaltene '
|
||||
'Revisionen '
|
||||
'neu '
|
||||
'zu '
|
||||
'schreiben '
|
||||
'oder '
|
||||
'Nachweise '
|
||||
'zu '
|
||||
'erbringen.',
|
||||
'publish_revision': 'Macht '
|
||||
'die '
|
||||
'ausgewählte '
|
||||
'unveränderliche '
|
||||
'Revision '
|
||||
'für '
|
||||
'die '
|
||||
'Endverbraucherproduktion '
|
||||
'geeignet.',
|
||||
'render_final': 'Erstellt '
|
||||
'gespeicherte '
|
||||
'Render-Nachweise '
|
||||
'und kann '
|
||||
'ein '
|
||||
'Artefakt '
|
||||
'durch '
|
||||
'Dateien '
|
||||
'beibehalten.',
|
||||
'save_revision': 'Erstellt '
|
||||
'eine '
|
||||
'neue '
|
||||
'unveränderliche '
|
||||
'Template-Revision.'}}}
|
||||
@@ -1,5 +1,8 @@
|
||||
from __future__ import annotations
|
||||
|
||||
from govoplan_core.core.modules import with_documentation_structured_translations
|
||||
from govoplan_templates.backend.german_structured_documentation import GERMAN_STRUCTURED_TRANSLATIONS
|
||||
|
||||
from pathlib import Path
|
||||
|
||||
from govoplan_core.core.files import CAPABILITY_FILES_ARTIFACT_STORE
|
||||
@@ -40,7 +43,7 @@ from govoplan_templates.backend.dsar_provider import (
|
||||
|
||||
MODULE_ID = "templates"
|
||||
MODULE_NAME = "Templates"
|
||||
MODULE_VERSION = "0.1.19"
|
||||
MODULE_VERSION = "0.1.21"
|
||||
|
||||
READ_SCOPE = "templates:template:read"
|
||||
WRITE_SCOPE = "templates:template:write"
|
||||
@@ -545,5 +548,10 @@ manifest = ModuleManifest(
|
||||
)
|
||||
|
||||
|
||||
manifest = with_documentation_structured_translations(
|
||||
manifest, locale="de", translations=GERMAN_STRUCTURED_TRANSLATIONS
|
||||
)
|
||||
|
||||
|
||||
def get_manifest() -> ModuleManifest:
|
||||
return manifest
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@govoplan/templates-webui",
|
||||
"version": "0.1.19",
|
||||
"version": "0.1.21",
|
||||
"private": true,
|
||||
"type": "module",
|
||||
"main": "src/index.ts",
|
||||
|
||||
@@ -353,7 +353,7 @@ export default function TemplatesPage({ settings, auth }: Props) {
|
||||
</span>}
|
||||
helpAction={<DocumentationHelpLink reference={TEMPLATES_DOCUMENTATION} />}
|
||||
primaryActions={<>
|
||||
<Button disabled={!selected || !canPublish || dirty || busy} disabledReason={busy ? TEMPLATES_I18N.busy : !selected ? TEMPLATES_I18N.noSelection : !canPublish ? TEMPLATES_I18N.publishReason : dirty ? TEMPLATES_I18N.saveBeforeAction : undefined} onClick={() => setPublishOpen(true)}><FileCheck2 size={16} /> Publish</Button>
|
||||
<Button helpContextId="templates.action.publish" helpModuleId="templates" disabled={!selected || !canPublish || dirty || busy} disabledReason={busy ? TEMPLATES_I18N.busy : !selected ? TEMPLATES_I18N.noSelection : !canPublish ? TEMPLATES_I18N.publishReason : dirty ? TEMPLATES_I18N.saveBeforeAction : undefined} onClick={() => setPublishOpen(true)}><FileCheck2 size={16} /> Publish</Button>
|
||||
<SegmentedControl
|
||||
value={view}
|
||||
onChange={setView}
|
||||
@@ -361,7 +361,7 @@ export default function TemplatesPage({ settings, auth }: Props) {
|
||||
ariaLabel="Template workspace"
|
||||
/>
|
||||
</>}
|
||||
destructiveActions={<IconButton label="Delete template" icon={<Trash2 size={17} />} variant="danger" disabled={!selected || readOnly} disabledReason={!selected ? TEMPLATES_I18N.noSelection : readOnly ? (canWrite ? TEMPLATES_I18N.readOnlyReason : TEMPLATES_I18N.writeReason) : undefined} onClick={() => setDeleteOpen(true)} />}
|
||||
destructiveActions={<IconButton label="Delete template" helpContextId="templates.action.delete" helpModuleId="templates" icon={<Trash2 size={17} />} variant="danger" disabled={!selected || readOnly} disabledReason={!selected ? TEMPLATES_I18N.noSelection : readOnly ? (canWrite ? TEMPLATES_I18N.readOnlyReason : TEMPLATES_I18N.writeReason) : undefined} onClick={() => setDeleteOpen(true)} />}
|
||||
discardAction={{ label: "Discard and reload", onClick: () => requestDiscard(() => void reload(selectedId)), disabled: !selected }}
|
||||
saveAction={{
|
||||
label: <><Save size={16} /> Save revision</>,
|
||||
|
||||
Reference in New Issue
Block a user