diff --git a/components/collapse/index.en-US.md b/components/collapse/index.en-US.md index 372d516934..f11ef9c706 100644 --- a/components/collapse/index.en-US.md +++ b/components/collapse/index.en-US.md @@ -12,49 +12,6 @@ coverDark: https://mdn.alipayobjects.com/huamei_7uahnr/afts/img/A*sir-TK0HkWcAAA - Can be used to group or hide complex regions to keep the page clean. - `Accordion` is a special kind of `Collapse`, which allows only one panel to be expanded at a time. -```tsx | pure -// works when >= 5.6.0, recommended ✅ -const text = ` - A dog is a type of domesticated animal. - Known for its loyalty and faithfulness, - it can be found as a welcome guest in many households across the world. -`; - -const items: CollapseProps['items'] = [ - { - key: '1', - label: 'This is panel header 1', - children:

{text}

, - }, - { - key: '2', - label: 'This is panel header 2', - children:

{text}

, - }, - { - key: '3', - label: 'This is panel header 3', - children:

{text}

, - }, -]; - -; - -// works when <5.6.0 , deprecated when >=5.6.0 🙅🏻‍♀️ - - - -

{text}

-
- -

{text}

-
- -

{text}

-
-
; -``` - ## Examples diff --git a/components/collapse/index.zh-CN.md b/components/collapse/index.zh-CN.md index 048008474b..23f93af48d 100644 --- a/components/collapse/index.zh-CN.md +++ b/components/collapse/index.zh-CN.md @@ -13,49 +13,6 @@ coverDark: https://mdn.alipayobjects.com/huamei_7uahnr/afts/img/A*sir-TK0HkWcAAA - 对复杂区域进行分组和隐藏,保持页面的整洁。 - `手风琴` 是一种特殊的折叠面板,只允许单个内容区域展开。 -```tsx | pure -// >= 5.6.0 可用,推荐的写法 ✅ -const text = ` - A dog is a type of domesticated animal. - Known for its loyalty and faithfulness, - it can be found as a welcome guest in many households across the world. -`; - -const items: CollapseProps['items'] = [ - { - key: '1', - label: 'This is panel header 1', - children:

{text}

, - }, - { - key: '2', - label: 'This is panel header 2', - children:

{text}

, - }, - { - key: '3', - label: 'This is panel header 3', - children:

{text}

, - }, -]; - -; - -// <5.6.0 可用,>=5.6.0 时不推荐 🙅🏻‍♀️ - - - -

{text}

-
- -

{text}

-
- -

{text}

-
-
; -``` - ## 代码演示 {#examples}