|
@@ -42,7 +42,7 @@ class NavApp extends React.Component {
|
|
|
bodyStyle={{ height: 320 }}
|
|
bodyStyle={{ height: 320 }}
|
|
|
items={[
|
|
items={[
|
|
|
{ itemKey: 'user', text: '用户管理', icon: <IconUser /> },
|
|
{ itemKey: 'user', text: '用户管理', icon: <IconUser /> },
|
|
|
- { itemKey: 'union', text: '公会中心', icon: <IconStar /> },
|
|
|
|
|
|
|
+ { itemKey: 'union', text: '活动管理', icon: <IconStar /> },
|
|
|
{
|
|
{
|
|
|
text: '任务平台',
|
|
text: '任务平台',
|
|
|
icon: <IconSetting />,
|
|
icon: <IconSetting />,
|
|
@@ -82,11 +82,11 @@ class NavApp extends React.Component {
|
|
|
defaultOpenKeys={[ 'job' ]}
|
|
defaultOpenKeys={[ 'job' ]}
|
|
|
items={[
|
|
items={[
|
|
|
{ itemKey: 'user', text: '用户管理' },
|
|
{ itemKey: 'user', text: '用户管理' },
|
|
|
- { itemKey: 'union', text: '公会中心' },
|
|
|
|
|
|
|
+ { itemKey: 'union', text: '活动管理' },
|
|
|
{
|
|
{
|
|
|
itemKey: 'union-management',
|
|
itemKey: 'union-management',
|
|
|
- text: '公会管理',
|
|
|
|
|
- items: ['公告设置', '公会查询', '信息录入']
|
|
|
|
|
|
|
+ text: '任务管理',
|
|
|
|
|
+ items: ['公告设置', '任务查询', '信息录入']
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
|
text: '任务平台',
|
|
text: '任务平台',
|
|
@@ -123,7 +123,7 @@ class NavApp extends React.Component {
|
|
|
bodyStyle={{ height: 320 }}
|
|
bodyStyle={{ height: 320 }}
|
|
|
items={[
|
|
items={[
|
|
|
{ itemKey: 'user', text: '用户管理', icon: <IconUser /> },
|
|
{ itemKey: 'user', text: '用户管理', icon: <IconUser /> },
|
|
|
- { itemKey: 'union', text: '公会中心', icon: <IconStar /> },
|
|
|
|
|
|
|
+ { itemKey: 'union', text: '活动管理', icon: <IconStar /> },
|
|
|
{
|
|
{
|
|
|
text: '任务平台',
|
|
text: '任务平台',
|
|
|
icon: <IconSetting />,
|
|
icon: <IconSetting />,
|
|
@@ -165,7 +165,7 @@ class NavApp extends React.Component {
|
|
|
defaultOpenKeys={['job', 'resource']}
|
|
defaultOpenKeys={['job', 'resource']}
|
|
|
items={[
|
|
items={[
|
|
|
{ itemKey: 'user', text: '用户管理', icon: <IconUser /> },
|
|
{ itemKey: 'user', text: '用户管理', icon: <IconUser /> },
|
|
|
- { itemKey: 'union', text: '公会中心', icon: <IconStar /> },
|
|
|
|
|
|
|
+ { itemKey: 'union', text: '活动管理', icon: <IconStar /> },
|
|
|
{
|
|
{
|
|
|
text: '任务平台',
|
|
text: '任务平台',
|
|
|
icon: <IconSetting />,
|
|
icon: <IconSetting />,
|
|
@@ -212,14 +212,14 @@ class NavApp extends React.Component {
|
|
|
onClick={data => console.log('trigger onClick: ', data)}
|
|
onClick={data => console.log('trigger onClick: ', data)}
|
|
|
>
|
|
>
|
|
|
<Nav.Header logo={<img src="https://sf6-cdn-tos.douyinstatic.com/obj/eden-cn/ptlz_zlp/ljhwZthlaukjlkulzlp/root-web-sites/webcast_logo.svg" />} text={'Semi 运营后台'} />
|
|
<Nav.Header logo={<img src="https://sf6-cdn-tos.douyinstatic.com/obj/eden-cn/ptlz_zlp/ljhwZthlaukjlkulzlp/root-web-sites/webcast_logo.svg" />} text={'Semi 运营后台'} />
|
|
|
- <Nav.Item itemKey={'union'} text={'公会中心'} icon={<IconStar />} />
|
|
|
|
|
|
|
+ <Nav.Item itemKey={'union'} text={'活动管理'} icon={<IconStar />} />
|
|
|
<Nav.Sub itemKey={'user'} text="用户管理" icon={<IconUser />}>
|
|
<Nav.Sub itemKey={'user'} text="用户管理" icon={<IconUser />}>
|
|
|
- <Nav.Item itemKey={'golder'} text={'金主管理'} />
|
|
|
|
|
- <Nav.Item itemKey={'ban'} text={'用户封禁'} />
|
|
|
|
|
|
|
+ <Nav.Item itemKey={'active'} text={'活跃用户'} />
|
|
|
|
|
+ <Nav.Item itemKey={'negative'} text={'非活跃用户'} />
|
|
|
</Nav.Sub>
|
|
</Nav.Sub>
|
|
|
- <Nav.Sub itemKey={'union-management'} text="公会管理" icon={<IconUserGroup />}>
|
|
|
|
|
- <Nav.Item itemKey={'notice'} text={'公告设置'} />
|
|
|
|
|
- <Nav.Item itemKey={'query'} text={'公会查询'} />
|
|
|
|
|
|
|
+ <Nav.Sub itemKey={'union-management'} text="任务管理" icon={<IconUserGroup />}>
|
|
|
|
|
+ <Nav.Item itemKey={'notice'} text={'任务设置'} />
|
|
|
|
|
+ <Nav.Item itemKey={'query'} text={'任务查询'} />
|
|
|
<Nav.Item itemKey={'info'} text={'信息录入'} />
|
|
<Nav.Item itemKey={'info'} text={'信息录入'} />
|
|
|
</Nav.Sub>
|
|
</Nav.Sub>
|
|
|
<Nav.Footer collapseButton={true} />
|
|
<Nav.Footer collapseButton={true} />
|
|
@@ -234,10 +234,9 @@ class NavApp extends React.Component {
|
|
|
|
|
|
|
|
Navigation 目前提供两种方向的导航:
|
|
Navigation 目前提供两种方向的导航:
|
|
|
|
|
|
|
|
-- 垂直方向(默认)
|
|
|
|
|
-- 水平方向
|
|
|
|
|
|
|
+- 垂直方向(默认), `mode = "vertical"`
|
|
|
|
|
+- 水平方向, `mode = "horizontal"`
|
|
|
|
|
|
|
|
-你可以通过 `mode = "vertical"` (默认)或者 `mode = "horizontal"` 来控制。
|
|
|
|
|
|
|
|
|
|
特别注意的是,有一些功能(参数)仅在 `mode = "vertical"` 时有效:
|
|
特别注意的是,有一些功能(参数)仅在 `mode = "vertical"` 时有效:
|
|
|
|
|
|
|
@@ -260,18 +259,18 @@ class NavApp extends React.Component {
|
|
|
bodyStyle={{ height: 320 }}
|
|
bodyStyle={{ height: 320 }}
|
|
|
items={[
|
|
items={[
|
|
|
{ itemKey: 'user', text: '用户管理', icon: <IconUser /> },
|
|
{ itemKey: 'user', text: '用户管理', icon: <IconUser /> },
|
|
|
- { itemKey: 'union', text: '公会中心', icon: <IconStar /> },
|
|
|
|
|
|
|
+ { itemKey: 'union', text: '活动管理', icon: <IconStar /> },
|
|
|
{
|
|
{
|
|
|
itemKey: 'union-management',
|
|
itemKey: 'union-management',
|
|
|
- text: '公会管理',
|
|
|
|
|
|
|
+ text: '任务管理',
|
|
|
icon: <IconUserGroup />,
|
|
icon: <IconUserGroup />,
|
|
|
- items: ['公告设置', '公会查询', '信息录入']
|
|
|
|
|
|
|
+ items: ['任务设置', '任务查询', '信息录入']
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
|
- text: '任务平台',
|
|
|
|
|
|
|
+ text: '公告管理',
|
|
|
icon: <IconSetting />,
|
|
icon: <IconSetting />,
|
|
|
itemKey: 'job',
|
|
itemKey: 'job',
|
|
|
- items: ['任务管理', '用户任务查询'],
|
|
|
|
|
|
|
+ items: ['推送管理', '已推送查询'],
|
|
|
},
|
|
},
|
|
|
]}
|
|
]}
|
|
|
onSelect={key => console.log(key)}
|
|
onSelect={key => console.log(key)}
|
|
@@ -304,7 +303,7 @@ class NavApp extends React.Component {
|
|
|
mode={'horizontal'}
|
|
mode={'horizontal'}
|
|
|
items={[
|
|
items={[
|
|
|
{ itemKey: 'user', text: '用户管理', icon: <IconUser /> },
|
|
{ itemKey: 'user', text: '用户管理', icon: <IconUser /> },
|
|
|
- { itemKey: 'union', text: '公会中心', icon: <IconStar /> },
|
|
|
|
|
|
|
+ { itemKey: 'union', text: '活动管理', icon: <IconStar /> },
|
|
|
{
|
|
{
|
|
|
itemKey: 'approve-management',
|
|
itemKey: 'approve-management',
|
|
|
text: '审批管理',
|
|
text: '审批管理',
|
|
@@ -343,7 +342,7 @@ class NavApp extends React.Component {
|
|
|
</Dropdown.Menu>
|
|
</Dropdown.Menu>
|
|
|
}
|
|
}
|
|
|
>
|
|
>
|
|
|
- <Avatar size="small" color='light-blue' style={{margin: 4}}>BD</Avatar>
|
|
|
|
|
|
|
+ <Avatar size="small" color='light-blue' style={{ margin: 4 }}>BD</Avatar>
|
|
|
<span>Bytedancer</span>
|
|
<span>Bytedancer</span>
|
|
|
</Dropdown>
|
|
</Dropdown>
|
|
|
}
|
|
}
|
|
@@ -367,12 +366,12 @@ class NavApp extends React.Component {
|
|
|
constructor() {
|
|
constructor() {
|
|
|
this.items = [
|
|
this.items = [
|
|
|
{ itemKey: 'user', text: '用户管理', icon: <IconUser /> },
|
|
{ itemKey: 'user', text: '用户管理', icon: <IconUser /> },
|
|
|
- { itemKey: 'union', text: '公会中心', icon: <IconStar /> },
|
|
|
|
|
|
|
+ { itemKey: 'union', text: '活动管理', icon: <IconStar /> },
|
|
|
{
|
|
{
|
|
|
itemKey: 'union-management',
|
|
itemKey: 'union-management',
|
|
|
- text: '公会管理',
|
|
|
|
|
|
|
+ text: '任务管理',
|
|
|
icon: <IconUserGroup />,
|
|
icon: <IconUserGroup />,
|
|
|
- items: ['公告设置', '公会查询', '信息录入']
|
|
|
|
|
|
|
+ items: ['公告设置', '任务查询', '信息录入']
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
|
itemKey: 'approve-management',
|
|
itemKey: 'approve-management',
|
|
@@ -419,7 +418,7 @@ class NavApp extends React.Component {
|
|
|
<Select.Option value='Korean'>한국어</Select.Option>
|
|
<Select.Option value='Korean'>한국어</Select.Option>
|
|
|
<Select.Option value='Japanese'>日本語</Select.Option>
|
|
<Select.Option value='Japanese'>日本語</Select.Option>
|
|
|
</Select>
|
|
</Select>
|
|
|
- <Button style={{ marginRight: 10 }}>切换至海外版</Button>
|
|
|
|
|
|
|
+ <Button style={{ marginRight: 10 }}>切换至全球版</Button>
|
|
|
<Dropdown
|
|
<Dropdown
|
|
|
position="bottomRight"
|
|
position="bottomRight"
|
|
|
render={
|
|
render={
|
|
@@ -429,7 +428,7 @@ class NavApp extends React.Component {
|
|
|
</Dropdown.Menu>
|
|
</Dropdown.Menu>
|
|
|
}
|
|
}
|
|
|
>
|
|
>
|
|
|
- <Avatar size="small" color='light-blue' style={{margin: 4}}>BD</Avatar>
|
|
|
|
|
|
|
+ <Avatar size="small" color='light-blue' style={{ margin: 4 }}>BD</Avatar>
|
|
|
<span>Bytedancer</span>
|
|
<span>Bytedancer</span>
|
|
|
</Dropdown>
|
|
</Dropdown>
|
|
|
</>
|
|
</>
|
|
@@ -480,7 +479,7 @@ class NavApp extends React.Component {
|
|
|
bodyStyle={{ height: 320 }}
|
|
bodyStyle={{ height: 320 }}
|
|
|
items={[
|
|
items={[
|
|
|
{ itemKey: 'user', text: '用户管理', icon: <IconUser /> },
|
|
{ itemKey: 'user', text: '用户管理', icon: <IconUser /> },
|
|
|
- { itemKey: 'union', text: '公会中心', icon: <IconStar /> },
|
|
|
|
|
|
|
+ { itemKey: 'union', text: '活动管理', icon: <IconStar /> },
|
|
|
{
|
|
{
|
|
|
text: '任务平台',
|
|
text: '任务平台',
|
|
|
icon: <IconSetting />,
|
|
icon: <IconSetting />,
|
|
@@ -533,13 +532,15 @@ class NavApp extends React.Component {
|
|
|
text: '任务1',
|
|
text: '任务1',
|
|
|
icon: <IconSetting />,
|
|
icon: <IconSetting />,
|
|
|
itemKey: 'mission1',
|
|
itemKey: 'mission1',
|
|
|
- items: ['任务2',{
|
|
|
|
|
- text: '任务3拆解',
|
|
|
|
|
- icon: <IconSetting />,
|
|
|
|
|
- itemKey: 'mission3',
|
|
|
|
|
- items: ['子任务1', '子任务2'],
|
|
|
|
|
- }, ],
|
|
|
|
|
- },],
|
|
|
|
|
|
|
+ items: ['任务2',
|
|
|
|
|
+ {
|
|
|
|
|
+ text: '任务3拆解',
|
|
|
|
|
+ icon: <IconSetting />,
|
|
|
|
|
+ itemKey: 'mission3',
|
|
|
|
|
+ items: ['子任务1', '子任务2'],
|
|
|
|
|
+ }
|
|
|
|
|
+ ],
|
|
|
|
|
+ }],
|
|
|
},
|
|
},
|
|
|
]}
|
|
]}
|
|
|
onSelect={key => console.log(key)}
|
|
onSelect={key => console.log(key)}
|
|
@@ -580,12 +581,12 @@ class NavApp extends React.Component {
|
|
|
bodyStyle={{ height: 320 }}
|
|
bodyStyle={{ height: 320 }}
|
|
|
items={[
|
|
items={[
|
|
|
{ itemKey: 'user', text: '用户管理', icon: <IconUser /> },
|
|
{ itemKey: 'user', text: '用户管理', icon: <IconUser /> },
|
|
|
- { itemKey: 'union', text: '公会中心', icon: <IconStar /> },
|
|
|
|
|
|
|
+ { itemKey: 'union', text: '活动管理', icon: <IconStar /> },
|
|
|
{
|
|
{
|
|
|
itemKey: 'union-management',
|
|
itemKey: 'union-management',
|
|
|
- text: '公会管理',
|
|
|
|
|
|
|
+ text: '任务管理',
|
|
|
icon: <IconUserGroup />,
|
|
icon: <IconUserGroup />,
|
|
|
- items: ['公告设置', '公会查询', '信息录入']
|
|
|
|
|
|
|
+ items: ['公告设置', '任务查询', '信息录入']
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
|
text: '任务平台',
|
|
text: '任务平台',
|
|
@@ -649,12 +650,12 @@ function NavApp (props = {}) {
|
|
|
|
|
|
|
|
const items = useMemo(() => [
|
|
const items = useMemo(() => [
|
|
|
{ itemKey: 'user', text: '用户管理', icon: <IconUser /> },
|
|
{ itemKey: 'user', text: '用户管理', icon: <IconUser /> },
|
|
|
- { itemKey: 'union', text: '公会中心', icon: <IconStar /> },
|
|
|
|
|
|
|
+ { itemKey: 'union', text: '活动管理', icon: <IconStar /> },
|
|
|
{
|
|
{
|
|
|
itemKey: 'union-management',
|
|
itemKey: 'union-management',
|
|
|
- text: '公会管理',
|
|
|
|
|
|
|
+ text: '任务管理',
|
|
|
icon: <IconUserGroup />,
|
|
icon: <IconUserGroup />,
|
|
|
- items: ['公告设置', '公会查询', '信息录入']
|
|
|
|
|
|
|
+ items: ['公告设置', '任务查询', '信息录入']
|
|
|
},
|
|
},
|
|
|
{
|
|
{
|
|
|
text: '任务平台',
|
|
text: '任务平台',
|
|
@@ -690,10 +691,10 @@ function NavApp (props = {}) {
|
|
|
|
|
|
|
|
### Nav
|
|
### Nav
|
|
|
|
|
|
|
|
-| 属性 | 类型 | 描述 | 默认值 |
|
|
|
|
|
|
|
+| 属性 | 描述 | 类型 | 默认值 |
|
|
|
| ------------------- | -------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------ | ---------- |
|
|
| ------------------- | -------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------ | ---------- |
|
|
|
-| bodyStyle | 导航项列表的自定义样式 | object | |
|
|
|
|
|
-| className | 最外层元素的样式名 | boolean | |
|
|
|
|
|
|
|
+| bodyStyle | 导航项列表的自定义样式 | CSSProperties | |
|
|
|
|
|
+| className | 最外层元素的样式名 | string | |
|
|
|
| defaultIsCollapsed | 默认是否处于收起状态,仅 `mode = "vertical"` 时有效 | boolean | false |
|
|
| defaultIsCollapsed | 默认是否处于收起状态,仅 `mode = "vertical"` 时有效 | boolean | false |
|
|
|
| defaultOpenKeys | 初始打开的子导航 `itemKey` 数组,仅 `mode = "vertical"` 且侧边栏处于展开状态时有效 | string[] | [] |
|
|
| defaultOpenKeys | 初始打开的子导航 `itemKey` 数组,仅 `mode = "vertical"` 且侧边栏处于展开状态时有效 | string[] | [] |
|
|
|
| defaultSelectedKeys | 初始选中的导航项 `itemKey` 数组 | string[] | [] |
|
|
| defaultSelectedKeys | 初始选中的导航项 `itemKey` 数组 | string[] | [] |
|
|
@@ -702,7 +703,7 @@ function NavApp (props = {}) {
|
|
|
| isCollapsed | 是否处于收起状态的受控属性,仅 `mode = "vertical"` 时有效 | boolean | |
|
|
| isCollapsed | 是否处于收起状态的受控属性,仅 `mode = "vertical"` 时有效 | boolean | |
|
|
|
| items | 导航项目列表,每一项可以继续带有 items 属性。如果为 string 数组,则会取每一项作为 text 和 itemKey | object\| string[] \| [Item](#Nav.Item)[] \| [Sub](#Nav.Sub)[] | |
|
|
| items | 导航项目列表,每一项可以继续带有 items 属性。如果为 string 数组,则会取每一项作为 text 和 itemKey | object\| string[] \| [Item](#Nav.Item)[] \| [Sub](#Nav.Sub)[] | |
|
|
|
| limitIndent | 解除缩进限制,可使用 level 自定义导航项缩进,水平模式只能为true >=1.27.0 | boolean | true |
|
|
| limitIndent | 解除缩进限制,可使用 level 自定义导航项缩进,水平模式只能为true >=1.27.0 | boolean | true |
|
|
|
-| mode | 导航类型,目前支持横向与竖直,可选值:`vertical`\ | `horizontal` | string | `vertical` |
|
|
|
|
|
|
|
+| mode | 导航类型,目前支持横向与竖直,可选值:`vertical`/| `horizontal` | string | `vertical` |
|
|
|
| openKeys | 受控的打开的子导航 `itemKey` 数组,配合 `onOpenChange` 回调控制子导航项展开,仅 `mode = "vertical"` 且侧边栏处于展开状态时有效 | string[] | |
|
|
| openKeys | 受控的打开的子导航 `itemKey` 数组,配合 `onOpenChange` 回调控制子导航项展开,仅 `mode = "vertical"` 且侧边栏处于展开状态时有效 | string[] | |
|
|
|
| prefixCls | 类名前缀 | string | `semi` |
|
|
| prefixCls | 类名前缀 | string | `semi` |
|
|
|
| selectedKeys | 受控的导航项 `itemKey` 数组,配合 `onSelect` 回调控制导航项选择 | string[] | |
|
|
| selectedKeys | 受控的导航项 `itemKey` 数组,配合 `onSelect` 回调控制导航项选择 | string[] | |
|
|
@@ -713,10 +714,10 @@ function NavApp (props = {}) {
|
|
|
| toggleIconPosition | 带有子导航项的的父级导航项箭头位置 >=1.27.0 | 'left' \| 'right' | 'right' |
|
|
| toggleIconPosition | 带有子导航项的的父级导航项箭头位置 >=1.27.0 | 'left' \| 'right' | 'right' |
|
|
|
| tooltipHideDelay | tooltip 隐藏的延迟,collapse 为 true 时有效,单位为 ms | number | 100 |
|
|
| tooltipHideDelay | tooltip 隐藏的延迟,collapse 为 true 时有效,单位为 ms | number | 100 |
|
|
|
| tooltipShowDelay | tooltip 显示的延迟,collapse 为 true 时有效,单位为 ms | number | 0 |
|
|
| tooltipShowDelay | tooltip 显示的延迟,collapse 为 true 时有效,单位为 ms | number | 0 |
|
|
|
-| onClick | 点击任意导航项时触发 | ({ itemKey: string, domEvent: MouseEvent, isOpen: boolean }) => {} | () => {} |
|
|
|
|
|
-| onCollapseChange | 收起状态变化时的回调 | (isCollapsed: boolean) => {} | () => {} |
|
|
|
|
|
-| onOpenChange | 切换某个子导航项目显隐状态时触发 | ({ itemKey: string, openKeys: string[], domEvent: MouseEvent, isOpen: boolean }) => {} | () => {} |
|
|
|
|
|
-| onSelect | 第一次选中某个可选中导航项目时触发,其中 selectedItems 这个字段版本 >= 0.17.0 后才支持 | ({ itemKey: string, selectedKeys: string[], selectedItems: [Item](#Nav.Item)[], domEvent: MouseEvent, isOpen: boolean }) => {} | () => {} |
|
|
|
|
|
|
|
+| onClick | 点击任意导航项时触发 |<ApiType detail='({ itemKey: string, domEvent: MouseEvent, isOpen: boolean }) => void'>(itemKey, event, isOpen)=> void </ApiType> | () => {} |
|
|
|
|
|
+| onCollapseChange | 收起状态变化时的回调 |<ApiType detail='(isCollapsed: boolean) => void'>(isCollapsed)=>{} </ApiType> | () => {} |
|
|
|
|
|
+| onOpenChange | 切换某个子导航项目显隐状态时触发 | <ApiType detail='({ itemKey: string, openKeys: string[], domEvent: MouseEvent, isOpen: boolean }) => void'> ({itemKey, openKeys, event, isOpen})=>{}</ApiType> | () => {} |
|
|
|
|
|
+| onSelect | 第一次选中某个可选中导航项目时触发,其中 selectedItems 这个字段版本 >= 0.17.0 后才支持 | <ApiType detail='({ itemKey: string, selectedKeys: string[], selectedItems: Item[], domEvent: MouseEvent, isOpen: boolean }) => void'>(onSelectProps)=>{}</ApiType> | () => {} |
|
|
|
|
|
|
|
|
### Nav.Item
|
|
### Nav.Item
|
|
|
|
|
|
|
@@ -765,14 +766,22 @@ function NavApp (props = {}) {
|
|
|
|
|
|
|
|
### Nav.Footer
|
|
### Nav.Footer
|
|
|
|
|
|
|
|
-| 属性 | 描述 | 类型 | 默认值 | 版本 |
|
|
|
|
|
-| -------------- | ---------------------------------------------------------------------------------------- | ----------------------------------------- | ------ | -------------- |
|
|
|
|
|
-| children | 子元素 | ReactNode | | |
|
|
|
|
|
-| className | 最外层样式名 | string | | |
|
|
|
|
|
-| collapseButton | 是否展示底部“收起侧边栏”按钮,mode="vertical" 且 Footer 组件的 children 参数为空才有效果 | boolean\|ReactNode | false | |
|
|
|
|
|
-| collapseText | “收起”按钮的文案 | (collapsed:boolean) => string\|ReactNode | | 0.35.0 |
|
|
|
|
|
-| style | 最外层样式 | CSSProperties | | |
|
|
|
|
|
-
|
|
|
|
|
|
|
+| 属性 | 描述 | 类型 | 默认值 |
|
|
|
|
|
+| -------------- | ---------------------------------------------------------------------------------------- | ----------------------------------------- | ------ |
|
|
|
|
|
+| children | 子元素 | ReactNode | |
|
|
|
|
|
+| className | 最外层样式名 | string | |
|
|
|
|
|
+| collapseButton | 是否展示底部“收起侧边栏”按钮,mode="vertical" 且 Footer 组件的 children 参数为空才有效果 | boolean\|ReactNode | false |
|
|
|
|
|
+| collapseText | “收起”按钮的文案 | (collapsed:boolean) => string\|ReactNode | |
|
|
|
|
|
+| style | 最外层样式 | CSSProperties | |
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
|
|
+## Accessibility
|
|
|
|
|
+- ### 键盘和焦点
|
|
|
|
|
+- Navigation 内的每个可点击 item 都可以被聚焦,相互之间使用 `Tab` 及 `Shift + Tab` 切换焦点,并且可以通过 `Enter` 键激活每个链接
|
|
|
|
|
+- 当某个 item 可被打开弹层时
|
|
|
|
|
+ - 打开弹层方式为 hover :该 item 被聚焦时,弹层打开。键盘用户可以通过下箭头将焦点移动到弹层上,`Esc` 键可以将焦点返回到 item 上
|
|
|
|
|
+ - 打开弹层的方式为 click :该 item 被聚焦时,点击 Enter 键,打开弹层。键盘用户可以通过下箭头将焦点移动到弹层上,`Esc` 键可以将焦点返回到 item 上
|
|
|
|
|
+ - 键盘交互暂未完整支持嵌套场景
|
|
|
|
|
|
|
|
## 文案规范
|
|
## 文案规范
|
|
|
|
|
|