From 142371ea3e9a1db3efbfdefa52899596d9c4f9a1 Mon Sep 17 00:00:00 2001 From: 07akioni <07akioni2@gmail.com> Date: Tue, 4 Feb 2020 12:40:06 +0800 Subject: [PATCH] doc(anchor): zh-cn --- .../components/anchor/enUS/index.md | 10 +++--- .../components/anchor/zhCN/affix.md | 14 +++++++++ .../components/anchor/zhCN/basic.md | 13 ++++++++ .../components/anchor/zhCN/index.md | 20 ++++++++++++ .../components/anchor/zhCN/scrollto.md | 31 +++++++++++++++++++ 5 files changed, 83 insertions(+), 5 deletions(-) create mode 100644 demo/documentation/components/anchor/zhCN/affix.md create mode 100644 demo/documentation/components/anchor/zhCN/basic.md create mode 100644 demo/documentation/components/anchor/zhCN/scrollto.md diff --git a/demo/documentation/components/anchor/enUS/index.md b/demo/documentation/components/anchor/enUS/index.md index b1401c3b8..02c8f9555 100644 --- a/demo/documentation/components/anchor/enUS/index.md +++ b/demo/documentation/components/anchor/enUS/index.md @@ -1,6 +1,6 @@ # Anchor -The demo used to use some charactor names from *Hard-Boiled Wonderland and the End of the World* as anchor links, but if so there will be too wired in this page. So I rewrite them. What a pity. +These demos used to use some charactor names from *Hard-Boiled Wonderland and the End of the World* as anchor links, but if so there will be too wired in this page compared with other pages. So I rewrite them. What a pity. ## Demos ```demo basic @@ -11,10 +11,10 @@ scrollto |Name|Type|Default|Description| |-|-|-|-| |affix|`boolean`|`false`|If it works like a affix. If set to `true`, it will recieve props from [affix](n-affix#Props)| -|target|`() => HTMLElement`|A function that returns the nearest scrollable ascendant element|The element that anchor listens to scroll event.| +|target|`() => HTMLElement`|A function that returns the nearest scrollable ascendant element|The element that anchor listens to scroll event. (If you want affix & anchor to listen to different target, manually warp anchor in affix instead.)| |bound|`number`|`12`|| ## Methods -|Method|Description| -|-|-| -|`scrollTo(href: string)`|| \ No newline at end of file +|Name|Type|Description| +|-|-|-| +|scrollTo|`(href: string): void`|| \ No newline at end of file diff --git a/demo/documentation/components/anchor/zhCN/affix.md b/demo/documentation/components/anchor/zhCN/affix.md new file mode 100644 index 000000000..346df7148 --- /dev/null +++ b/demo/documentation/components/anchor/zhCN/affix.md @@ -0,0 +1,14 @@ +# 固定 +在固定模式下,Anchor 还接受和 Affix 一样的 Props。 +```html +