From 182a09bde2807edd89ccda7253a25c487a198353 Mon Sep 17 00:00:00 2001 From: ishinewang Date: Wed, 7 Sep 2022 18:58:57 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20HeaderSelectMenu=E6=94=AF=E6=8C=81?= =?UTF-8?q?=E4=BB=A5i18n=E6=96=B9=E5=BC=8F=E8=87=AA=E5=AE=9A=E4=B9=89?= =?UTF-8?q?=E6=A0=87=E9=A2=98=E4=B8=8B=E6=8B=89=E8=8F=9C=E5=8D=95=E4=B8=AD?= =?UTF-8?q?H1-H5=E6=B8=B2=E6=9F=93=E5=86=85=E5=AE=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/basic-modules/src/locale/zh-CN.ts | 5 +++++ .../src/modules/header/menu/HeaderSelectMenu.ts | 10 +++++----- 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/packages/basic-modules/src/locale/zh-CN.ts b/packages/basic-modules/src/locale/zh-CN.ts index cccc6187b..837785b16 100644 --- a/packages/basic-modules/src/locale/zh-CN.ts +++ b/packages/basic-modules/src/locale/zh-CN.ts @@ -43,6 +43,11 @@ export default { header: { title: '标题', text: '正文', + header1: 'H1', + header2: 'H2', + header3: 'H3', + header4: 'H4', + header5: 'H5', }, image: { netImage: '网络图片', diff --git a/packages/basic-modules/src/modules/header/menu/HeaderSelectMenu.ts b/packages/basic-modules/src/modules/header/menu/HeaderSelectMenu.ts index a79031d15..3985016b5 100644 --- a/packages/basic-modules/src/modules/header/menu/HeaderSelectMenu.ts +++ b/packages/basic-modules/src/modules/header/menu/HeaderSelectMenu.ts @@ -19,27 +19,27 @@ class HeaderSelectMenu implements ISelectMenu { // value 和 elemNode.type 对应 { value: 'header1', - text: 'H1', + text: t('header.header1'), styleForRenderMenuList: { 'font-size': '32px', 'font-weight': 'bold' }, }, { value: 'header2', - text: 'H2', + text: t('header.header2'), styleForRenderMenuList: { 'font-size': '24px', 'font-weight': 'bold' }, }, { value: 'header3', - text: 'H3', + text: t('header.header3'), styleForRenderMenuList: { 'font-size': '18px', 'font-weight': 'bold' }, }, { value: 'header4', - text: 'H4', + text: t('header.header4'), styleForRenderMenuList: { 'font-size': '16px', 'font-weight': 'bold' }, }, { value: 'header5', - text: 'H5', + text: t('header.header5'), styleForRenderMenuList: { 'font-size': '13px', 'font-weight': 'bold' }, }, { value: 'paragraph', text: t('header.text') },