diff --git a/src/components/Authorized/index.md b/src/components/Authorized/index.md index f3b2f80af5ffa27ecb310b6932dc7dfa7c7945c8..48c93f8faf435ef32b61e36f8cac8e7e7992c4cd 100644 --- a/src/components/Authorized/index.md +++ b/src/components/Authorized/index.md @@ -1,7 +1,5 @@ --- -title: - en-US: Authorized - zh-CN: Authorized +title: Authorized subtitle: 权限 cols: 1 order: 15 diff --git a/src/components/Charts/index.md b/src/components/Charts/index.md index cb7c9c96e191d47fe2dac084c25cb194f3c169c0..e5f41c873a8b9d4a71b49afd3948aa6aca780ec5 100644 --- a/src/components/Charts/index.md +++ b/src/components/Charts/index.md @@ -1,7 +1,5 @@ --- -title: - en-US: Charts - zh-CN: Charts +title: Charts subtitle: 图表 order: 2 cols: 2 diff --git a/src/components/GlobalFooter/index.md b/src/components/GlobalFooter/index.md index 55b4be46c9187818887c020f72ec3465d29b1294..96e04fee22c0adf4be46882a3d6e52d4fe5f04a6 100644 --- a/src/components/GlobalFooter/index.md +++ b/src/components/GlobalFooter/index.md @@ -1,7 +1,5 @@ --- -title: - en-US: GlobalFooter - zh-CN: GlobalFooter +title: GlobalFooter subtitle: 全局页脚 cols: 1 order: 7 diff --git a/src/components/HeaderSearch/index.en-US.md b/src/components/HeaderSearch/index.en-US.md index 6f4d06b4e10f43f16e2b997629a8ecd79ca50a3c..989df8868a913e9dddcefb3b1a79171d1991bb8f 100644 --- a/src/components/HeaderSearch/index.en-US.md +++ b/src/components/HeaderSearch/index.en-US.md @@ -1,7 +1,5 @@ --- -title: - en-US: HeaderSearch - zh-CN: HeaderSearch +title: HeaderSearch subtitle: Top search box cols: 1 order: 8 @@ -21,4 +19,4 @@ onSelect | Called when a option is selected. param is option's value and option onPressEnter | Callback when pressing Enter | function(value) | - onVisibleChange | Show or hide the callback of the text box | function(value) |- defaultOpen | The input box is displayed for the first time. | boolean | false -open | The input box is displayed | booelan |false \ No newline at end of file +open | The input box is displayed | boolean |false \ No newline at end of file diff --git a/src/components/HeaderSearch/index.zh-CN.md b/src/components/HeaderSearch/index.zh-CN.md index 9c108c2bc14594ea082fe93af37836e610862f63..83e74887f48f92ed380b274cec6c89d883962153 100644 --- a/src/components/HeaderSearch/index.zh-CN.md +++ b/src/components/HeaderSearch/index.zh-CN.md @@ -1,7 +1,5 @@ --- -title: - en-US: HeaderSearch - zh-CN: HeaderSearch +title: HeaderSearch subtitle: 顶部搜索框 cols: 1 order: 8 @@ -21,4 +19,4 @@ onSelect | 被选中时调用,参数为选中项的 value 值 | function(value onPressEnter | 按下回车时的回调 | function(value) | - onVisibleChange | 显示或隐藏文本框的回调 | function(value) |- defaultOpen | 输入框首次显示是否显示 | boolean | false -open | 控制输入框是否显示 | booelan |false \ No newline at end of file +open | 控制输入框是否显示 | boolean |false \ No newline at end of file diff --git a/src/components/PageHeader/index.md b/src/components/PageHeader/index.md index e82c8b89a81e6bfdadb3edf49c405a83daff5eda..48543f5f4dcad7012984fddc045f35292ca7bc88 100644 --- a/src/components/PageHeader/index.md +++ b/src/components/PageHeader/index.md @@ -1,7 +1,5 @@ --- -title: - en-US: PageHeader - zh-CN: PageHeader +title: PageHeader subtitle: 页头 cols: 1 order: 11 diff --git a/src/components/Result/index.md b/src/components/Result/index.md index dc11206cc4dc88bea7f2c9b182849361ba18c0f4..05e1c0e2f8a4967f7a23528ce1ac7a4704598a05 100644 --- a/src/components/Result/index.md +++ b/src/components/Result/index.md @@ -1,7 +1,5 @@ --- -title: - en-US: Result - zh-CN: Result +title: Result subtitle: 处理结果 cols: 1 order: 12 diff --git a/src/components/TagSelect/index.md b/src/components/TagSelect/index.md index 25a42b57a114818e4de2d30d58124acfde99eef7..8d21de7b7edb88cfa4f1ff7a0c857dd8bfeeb0ec 100644 --- a/src/components/TagSelect/index.md +++ b/src/components/TagSelect/index.md @@ -1,7 +1,5 @@ --- -title: - en-US: TagSelect - zh-CN: TagSelect +title: TagSelect subtitle: 标签选择器 cols: 1 order: 13 diff --git a/src/components/Trend/index.md b/src/components/Trend/index.md index 3e3ac07a57cf8c20b71ccf8fe21ed27820db2804..96d83b853e29671fe9b73f3205a47c491ae4262d 100644 --- a/src/components/Trend/index.md +++ b/src/components/Trend/index.md @@ -1,7 +1,5 @@ --- -title: - en-US: Trend - zh-CN: Trend +title: Trend subtitle: 趋势标记 cols: 1 order: 14 diff --git a/src/utils/getPageTitle.js b/src/utils/getPageTitle.js index 09e69c32c9f89447075b45eb6147039c3d18c998..0dd1e6207858670ee08f256ff10e292717e6a078 100644 --- a/src/utils/getPageTitle.js +++ b/src/utils/getPageTitle.js @@ -8,6 +8,7 @@ export const matchParamsPath = (pathname, breadcrumbNameMap) => { const pathKey = Object.keys(breadcrumbNameMap).find(key => pathToRegexp(key).test(pathname)); return breadcrumbNameMap[pathKey]; }; + const getPageTitle = (pathname, breadcrumbNameMap) => { const currRouterData = matchParamsPath(pathname, breadcrumbNameMap); if (!currRouterData) {