From f4ef2a78a24ed6721ce897bccb5afb0dfb4bbed4 Mon Sep 17 00:00:00 2001 From: razonyang Date: Tue, 16 Jan 2024 20:45:29 +0800 Subject: [PATCH] feat: add the aliases field --- hugo.toml | 14 ++++++++++++++ i18n/en.toml | 6 ++++++ i18n/zh-hans.toml | 6 ++++++ i18n/zh-hant.toml | 6 ++++++ 4 files changed, 32 insertions(+) diff --git a/hugo.toml b/hugo.toml index c37d794..9385d49 100644 --- a/hugo.toml +++ b/hugo.toml @@ -18,6 +18,20 @@ public_folder = "/images/uploads" search = true _preview_styles = [] +[params.decap_cms._configs.field_aliases.fields.alias] +i18n = true +name = "aliases" +label = "Aliases" +required = false +widget = "list" +summary = "{{fields.alias}}" +collapsed = true +minimize_collapsed = true +[params.decap_cms._configs.field_aliases.fields.alias.field] +label = "Alias" +name = "alias" +widget = "string" + [params.decap_cms._configs.field_body.fields.body] i18n = true name = "body" diff --git a/i18n/en.toml b/i18n/en.toml index 6523c80..b94abf7 100644 --- a/i18n/en.toml +++ b/i18n/en.toml @@ -1,3 +1,9 @@ +[cms_field_label_alias] +other = "Alias" + +[cms_field_label_aliases] +other = "Aliases" + [cms_field_label_body] other = "Body" diff --git a/i18n/zh-hans.toml b/i18n/zh-hans.toml index 4e9cda7..1934b86 100644 --- a/i18n/zh-hans.toml +++ b/i18n/zh-hans.toml @@ -1,3 +1,9 @@ +[cms_field_label_alias] +other = "别名" + +[cms_field_label_aliases] +other = "别名" + [cms_field_label_body] other = "正文" diff --git a/i18n/zh-hant.toml b/i18n/zh-hant.toml index 17dc2d2..c3024c1 100644 --- a/i18n/zh-hant.toml +++ b/i18n/zh-hant.toml @@ -1,3 +1,9 @@ +[cms_field_label_alias] +other = "別名" + +[cms_field_label_aliases] +other = "別名" + [cms_field_label_body] other = "正文"