Admin panel in English and Polish, reworded per docs/dev/admin-ux.md
- admin-i18n module: AdminText { en, pl }, component texts under the ipal
namespace (project translations win), en + pl admin languages when the
project sets none (project's supportedLanguages wins)
- every plugin label, description, option, tab and group as { en, pl };
explicit labels instead of auto-labels; sentence case; glossary terms
- visible renames (slugs, names, data unchanged): Cookie banner, Form
messages, Privacy group, Search engines, Maintenance, Spam protection,
E-mail sending, stats nav link Overview (hidden without access)
- Polish visitor defaults by page locale: cookie banner, form messages,
validators, lightbox, accessibility widget; {field} uses the label
- fixes: e-mail status banner used Turnstile wording; developer words and
env var names out of editor messages; stats numbers/dates in the admin
language; test e-mail no longer says ipal-kit
- test/adminUx.test.ts: length limits, en + pl present, no developer words
Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
eeac33ed2f
commit
6b46bc0c14
@@ -114,7 +114,7 @@ ${footerLines ? `<tr><td class="ipal-pad" style="padding:20px 36px 28px;backgrou
|
||||
</table></td></tr></table></body></html>`
|
||||
}
|
||||
|
||||
/** Site Settings → "Emails" tab (shown with `forms: { emailLayout: true }`). */
|
||||
/** Site settings → "E-mails" tab (shown with `forms: { emailLayout: true }`). */
|
||||
export const emailSettingsFields: Field[] = [
|
||||
{
|
||||
name: 'email',
|
||||
@@ -124,18 +124,40 @@ export const emailSettingsFields: Field[] = [
|
||||
{
|
||||
name: 'logo',
|
||||
type: 'upload',
|
||||
admin: { description: 'PNG or JPG for a light background — Gmail and Outlook do not show SVG. Empty = the site name.' },
|
||||
label: 'E-mail logo',
|
||||
admin: {
|
||||
description: {
|
||||
en: 'PNG or JPG on a light background, as many e-mail apps do not show SVG; leave empty to show the site name.',
|
||||
pl: 'PNG lub JPG na jasnym tle, bo wiele programów pocztowych nie wyświetla SVG; zostaw puste, aby pokazać nazwę witryny.',
|
||||
},
|
||||
},
|
||||
label: { en: 'E-mail logo', pl: 'Logo w e-mailach' },
|
||||
relationTo: 'media',
|
||||
},
|
||||
{
|
||||
name: 'accentColor',
|
||||
type: 'text',
|
||||
admin: { description: 'Hex, e.g. #017BD0 — top bar and section titles.' },
|
||||
label: 'Accent colour',
|
||||
validate: (value: unknown) => !value || /^#(?:[0-9a-f]{3}){1,2}$/i.test(String(value)) || 'Use a hex colour, e.g. #017BD0.',
|
||||
admin: {
|
||||
description: {
|
||||
en: 'Used for the top bar and section titles.',
|
||||
pl: 'Używany na górnym pasku i w tytułach sekcji.',
|
||||
},
|
||||
placeholder: '#017BD0',
|
||||
},
|
||||
label: { en: 'Accent colour', pl: 'Kolor akcentu' },
|
||||
validate: (value: unknown, { req }: { req?: { i18n?: { language?: string } } } = {}) =>
|
||||
!value ||
|
||||
/^#(?:[0-9a-f]{3}){1,2}$/i.test(String(value)) ||
|
||||
(req?.i18n?.language === 'pl' ? 'Wpisz kolor w formacie HEX, np. #017BD0.' : 'Enter a hex colour, e.g. #017BD0.'),
|
||||
},
|
||||
{
|
||||
name: 'footer',
|
||||
type: 'textarea',
|
||||
admin: {
|
||||
description: { en: 'E.g. company name and address.', pl: 'Np. nazwa i adres firmy.' },
|
||||
},
|
||||
label: { en: 'Footer', pl: 'Stopka' },
|
||||
localized: true,
|
||||
},
|
||||
{ name: 'footer', type: 'textarea', admin: { description: 'E.g. company name and address.' }, label: 'Footer', localized: true },
|
||||
],
|
||||
label: false,
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user