-
-
Notifications
You must be signed in to change notification settings - Fork 225
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
文档完善,修复
Mask
、Icon
组件bug,Progress
组件type属性更名为shape
- Loading branch information
Showing
45 changed files
with
1,046 additions
and
154 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,5 @@ | ||
node_modules/ | ||
node_modules/ | ||
assets/ | ||
dist/ | ||
lib/ | ||
coverage/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,61 @@ | ||
# 徽标 Badge | ||
|
||
[demo页面](https://zhongantecheng.github.io/zarm/#/badge) | ||
|
||
### 引入 | ||
|
||
```js | ||
import { Badge } from 'zarm'; | ||
``` | ||
|
||
### 代码演示 | ||
|
||
#### 基本用法 | ||
|
||
###### 点状 | ||
```jsx | ||
<Badge shape="dot" /> | ||
``` | ||
|
||
###### 直角 | ||
```jsx | ||
<Badge text="免费" /> | ||
``` | ||
|
||
###### 圆角 | ||
```jsx | ||
<Badge shape="radius" text="new" /> | ||
``` | ||
|
||
###### 椭圆形 | ||
```jsx | ||
<Badge shape="round" text="999+" /> | ||
``` | ||
|
||
###### 圆形 | ||
```jsx | ||
<Badge shape="circle" text={3} /> | ||
``` | ||
|
||
#### 上标位置 | ||
```jsx | ||
<Badge sup shape="dot"> | ||
<div style={{ width: 30, height: 30, background: '#ddd' }}></div> | ||
</Badge> | ||
``` | ||
|
||
|
||
### API | ||
|
||
| 属性 | 类型 | 默认值 | 可选值/参数 | 说明 | | ||
| :--- | :--- | :--- | :--- | :--- | | ||
| prefixCls | string | za-badge | | 类名前缀 | | ||
| className | string | | | 追加类名 | | ||
| theme | string | 'error' | 'default', 'primary', 'info', 'success', 'warning', 'error' | 主题 | | ||
| shape | string | | 'dot', 'radius', 'round', 'circle' | 形状 | | ||
| text | any | | | 显示文字 | | ||
| sup | bool | false | | 是否上标位置 | | ||
|
||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
# 列表项 Cell | ||
|
||
[demo页面](https://zhongantecheng.github.io/zarm/#/cell) | ||
|
||
### 引入 | ||
|
||
```js | ||
import { Cell } from 'zarm'; | ||
``` | ||
|
||
### 代码演示 | ||
|
||
#### 基本用法 | ||
|
||
###### 普通 | ||
```jsx | ||
<Cell title="标题文字" /> | ||
<Cell | ||
title={ | ||
<div className="box"> | ||
<div className="box-title">标题文字</div> | ||
<div className="box-description">描述文字</div> | ||
</div> | ||
} | ||
/> | ||
``` | ||
|
||
###### 带描述 | ||
```jsx | ||
<Cell title="标题文字" description="描述文字" /> | ||
<Cell title="标题文字" description={<Icon type="right" />} /> | ||
``` | ||
|
||
###### 带图标、描述 | ||
```jsx | ||
<Cell title="标题文字" icon={<Icon type="right" />} /> | ||
<Cell title="标题文字" icon={<img alt="" src={require('../images/icons/state.png')} />} /> | ||
``` | ||
|
||
###### 带跳转 | ||
```jsx | ||
<Cell hasArrow title="标题文字" onClick={() => {}} /> | ||
``` | ||
|
||
#### 提示信息 | ||
```jsx | ||
<Cell | ||
title="标题" | ||
help={<Message theme="error" icon={<Icon type="info-round" />}>标题不能为空</Message>}> | ||
<Input type="text" placeholder="请输入标题" /> | ||
</Cell> | ||
``` | ||
|
||
|
||
### API | ||
|
||
| 属性 | 类型 | 默认值 | 可选值/参数 | 说明 | | ||
| :--- | :--- | :--- | :--- | :--- | | ||
| prefixCls | string | za-cell | | 类名前缀 | | ||
| className | string | | | 追加类名 | | ||
| icon | any | | | 显示的图标 | | ||
| titile | any | | | 标题 | | ||
| description | any | | | 描述 | | ||
| hasArrow | bool | false | | 是否显示箭头 | | ||
| onClick | func | noop | | 点击后触发的回调函数 | | ||
| help | any | | | 下方提示信息,通常配合`Message`组件使用 | | ||
|
||
|
||
|
||
|
||
|
||
|
Oops, something went wrong.