Files
summercms/modules/cabana/backendscreens/models/maillayout/fields.yaml
Jakub Zych d320733510 feat(postcard): inline mail CSS at render with a per-layout opt-out
- github.com/vanng822/go-premailer v1.38.0 (default options) inlines the
  rendered HTML after the safety checks; the result is checked again,
  HTML without a style element is left as it is, an inliner error sends
  the style block only and warns (key inline:<layout>)
- opt-out: layout header key disable_auto_inline_css, the layouts column
  of the same name (migration 202611130003), LayoutFile/LayoutOverride/
  Draft.DisableAutoInlineCSS; SyncIndex mirrors and ResetOverride restores
  the file's value
- cabana layout form switch on the CSS tab, mapped into the layout draft
  and the save validation; en/pl copy
- tests: TestMailPartialsSmoke/inline, TestMailEditorSmoke/inline_flag,
  the layouts switch in TestMailScreensSmoke; CSS-slot tests read the
  style block through a no-op inliner
- 35-06 Task 2 (G-35-8)
2026-11-13 21:12:01 +01:00

81 lines
2.3 KiB
YAML

fields:
_info:
type: partial
path: info
span: full
context: update
tab: backend::lang.mail.layout.tab_html
name:
label: backend::lang.mail.name_field
type: text
span: left
required: true
tab: backend::lang.mail.layout.tab_html
code:
label: backend::lang.mail.code
comment: backend::lang.mail.layout.code_comment
type: text
span: right
required: true
context: create
tab: backend::lang.mail.layout.tab_html
preset:
type: slug
field: name
content_html:
label: backend::lang.mail.layout.html
comment: backend::lang.mail.layout.html_comment
type: codeeditor
language: html
size: giant
mailImages: true
span: full
tab: backend::lang.mail.layout.tab_html
_preview_html:
label: backend::lang.mail.preview.label
type: mailpreview
mode: layout
span: full
tab: backend::lang.mail.layout.tab_html
content_text:
label: backend::lang.mail.layout.text
comment: backend::lang.mail.layout.text_comment
type: codeeditor
language: text
size: huge
span: full
tab: backend::lang.mail.layout.tab_text
_preview_text:
label: backend::lang.mail.preview.label
type: mailpreview
mode: layout
span: full
tab: backend::lang.mail.layout.tab_text
disable_auto_inline_css:
label: backend::lang.mail.layout.disable_inline_css
comment: backend::lang.mail.layout.disable_inline_css_comment
type: switch
span: full
tab: backend::lang.mail.layout.tab_css
content_css:
label: backend::lang.mail.layout.css
comment: backend::lang.mail.layout.css_comment
type: codeeditor
language: css
size: huge
mailImages: true
span: full
tab: backend::lang.mail.layout.tab_css
_preview_css:
label: backend::lang.mail.preview.label
type: mailpreview
mode: layout
span: full
tab: backend::lang.mail.layout.tab_css
_file_version:
type: partial
path: file_version
span: full
context: update
tab: backend::lang.mail.tab_file_version