feat: URL rules and the settings singleton

This commit is contained in:
2026-10-27 10:34:39 +01:00
parent fb9590f099
commit ce60c8a1ee
20 changed files with 1412 additions and 0 deletions

24
models/rule/columns.yaml Normal file
View File

@@ -0,0 +1,24 @@
# URL rules list columns (UI-SPEC C7). overrides is filled by the
# controller's ListExtendRecords.
columns:
url:
label: golem15.seo::lang.rules.url
type: text
searchable: true
sortable: true
match:
label: golem15.seo::lang.rules.match
type: text
overrides:
label: golem15.seo::lang.rules.col_overrides
type: text
sortable: false
note:
label: golem15.seo::lang.rules.note
type: text
searchable: true
invisible: true
updated_at:
label: golem15.seo::lang.rules.col_updated
type: datetime
sortable: true

71
models/rule/fields.yaml Normal file
View File

@@ -0,0 +1,71 @@
# URL rule form (UI-SPEC C7). The SEO field types (seotext, seorobots,
# seoimage) and the preview partials come with the field elements.
fields:
url:
label: golem15.seo::lang.rules.url
comment: golem15.seo::lang.rules.url_comment_full
type: text
span: left
required: true
match:
label: golem15.seo::lang.rules.match
type: dropdown
span: right
default: exact
options:
exact: golem15.seo::lang.rules.match_exact
pattern: golem15.seo::lang.rules.match_pattern
title:
label: golem15.seo::lang.field.title
comment: golem15.seo::lang.field.title_comment_rule
type: text
span: full
description:
label: golem15.seo::lang.field.description
type: textarea
size: small
span: full
canonical:
label: golem15.seo::lang.field.canonical
comment: golem15.seo::lang.field.canonical_comment
type: text
span: left
robots:
label: golem15.seo::lang.field.robots
comment: golem15.seo::lang.field.robots_comment_rule
type: dropdown
span: right
options:
'': golem15.seo::lang.robots.inherit
'index,follow': 'index, follow'
'noindex,follow': 'noindex, follow'
'index,nofollow': 'index, nofollow'
'noindex,nofollow': 'noindex, nofollow'
og_title:
label: golem15.seo::lang.field.og_title
type: text
span: left
og_description:
label: golem15.seo::lang.field.og_description
type: textarea
size: small
span: full
og_image:
label: golem15.seo::lang.field.og_image
type: text
span: full
note:
label: golem15.seo::lang.rules.note
comment: golem15.seo::lang.rules.note_comment
type: textarea
size: tiny
span: full