Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(icon): add new icon #1488

Merged
merged 3 commits into from
Jul 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@
"@vueuse/core": "10.7.0",
"dayjs": "^1.10.7",
"lodash": "^4.17.21",
"tdesign-icons-vue-next": "^0.2.0",
"tdesign-icons-vue-next": "^0.2.4",
"validator": "^13.5.1"
},
"peerDependencies": {
Expand Down
24 changes: 18 additions & 6 deletions src/cell/__test__/__snapshots__/demo.test.jsx.snap
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,10 @@ exports[`Cell > Cell groupVue demo works fine 1`] = `
width="1em"
>
<path
d="M5.5 7.5a6.5 6.5 0 0113 0V9h2v13h-17V9h2V7.5zm2 1.5h9V7.5a4.5 4.5 0 10-9 0V9zm-2 2v9h13v-9h-13zM9 14.5h6v2H9v-2z"
clip-rule="evenodd"
d="M12 3a4 4 0 00-4 4v3h8V7a4 4 0 00-4-4zm6 7V7A6 6 0 006 7v3H3.5v12h17V10H18zM5.5 12v8h13v-8h-13zM9 15h6v2H9v-2z"
fill="currentColor"
fill-rule="evenodd"
/>
</svg>
</div>
Expand Down Expand Up @@ -454,8 +456,10 @@ exports[`Cell > Cell mobileVue demo works fine 1`] = `
width="1em"
>
<path
d="M5.5 7.5a6.5 6.5 0 0113 0V9h2v13h-17V9h2V7.5zm2 1.5h9V7.5a4.5 4.5 0 10-9 0V9zm-2 2v9h13v-9h-13zM9 14.5h6v2H9v-2z"
clip-rule="evenodd"
d="M12 3a4 4 0 00-4 4v3h8V7a4 4 0 00-4-4zm6 7V7A6 6 0 006 7v3H3.5v12h17V10H18zM5.5 12v8h13v-8h-13zM9 15h6v2H9v-2z"
fill="currentColor"
fill-rule="evenodd"
/>
</svg>
</div>
Expand Down Expand Up @@ -779,8 +783,10 @@ exports[`Cell > Cell mobileVue demo works fine 1`] = `
width="1em"
>
<path
d="M5.5 7.5a6.5 6.5 0 0113 0V9h2v13h-17V9h2V7.5zm2 1.5h9V7.5a4.5 4.5 0 10-9 0V9zm-2 2v9h13v-9h-13zM9 14.5h6v2H9v-2z"
clip-rule="evenodd"
d="M12 3a4 4 0 00-4 4v3h8V7a4 4 0 00-4-4zm6 7V7A6 6 0 006 7v3H3.5v12h17V10H18zM5.5 12v8h13v-8h-13zM9 15h6v2H9v-2z"
fill="currentColor"
fill-rule="evenodd"
/>
</svg>

Expand Down Expand Up @@ -1059,8 +1065,10 @@ exports[`Cell > Cell mobileVue demo works fine 1`] = `
width="1em"
>
<path
d="M5.5 7.5a6.5 6.5 0 0113 0V9h2v13h-17V9h2V7.5zm2 1.5h9V7.5a4.5 4.5 0 10-9 0V9zm-2 2v9h13v-9h-13zM9 14.5h6v2H9v-2z"
clip-rule="evenodd"
d="M12 3a4 4 0 00-4 4v3h8V7a4 4 0 00-4-4zm6 7V7A6 6 0 006 7v3H3.5v12h17V10H18zM5.5 12v8h13v-8h-13zM9 15h6v2H9v-2z"
fill="currentColor"
fill-rule="evenodd"
/>
</svg>
</div>
Expand Down Expand Up @@ -1474,8 +1482,10 @@ exports[`Cell > Cell multipleVue demo works fine 1`] = `
width="1em"
>
<path
d="M5.5 7.5a6.5 6.5 0 0113 0V9h2v13h-17V9h2V7.5zm2 1.5h9V7.5a4.5 4.5 0 10-9 0V9zm-2 2v9h13v-9h-13zM9 14.5h6v2H9v-2z"
clip-rule="evenodd"
d="M12 3a4 4 0 00-4 4v3h8V7a4 4 0 00-4-4zm6 7V7A6 6 0 006 7v3H3.5v12h17V10H18zM5.5 12v8h13v-8h-13zM9 15h6v2H9v-2z"
fill="currentColor"
fill-rule="evenodd"
/>
</svg>

Expand Down Expand Up @@ -1949,8 +1959,10 @@ exports[`Cell > Cell singleVue demo works fine 1`] = `
width="1em"
>
<path
d="M5.5 7.5a6.5 6.5 0 0113 0V9h2v13h-17V9h2V7.5zm2 1.5h9V7.5a4.5 4.5 0 10-9 0V9zm-2 2v9h13v-9h-13zM9 14.5h6v2H9v-2z"
clip-rule="evenodd"
d="M12 3a4 4 0 00-4 4v3h8V7a4 4 0 00-4-4zm6 7V7A6 6 0 006 7v3H3.5v12h17V10H18zM5.5 12v8h13v-8h-13zM9 15h6v2H9v-2z"
fill="currentColor"
fill-rule="evenodd"
/>
</svg>
</div>
Expand Down
6 changes: 6 additions & 0 deletions src/icon/icon.en-US.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,12 @@ You can get all the name of icon by import manifest from the bundle `import { ma
if your project is in a no-network scenario, please use on-demand loading of icons. For example,`<t-icon name="add" />` should be changed to `<AddIcon />`
### All Icons

<div style="background: #ecf2fe; display: flex; align-items: center; line-height: 20px; padding: 14px 24px; border-radius: 3px; color: #555a65;margin:16px 0">
<svg fill="none" viewBox="0 0 16 16" width="16px" height="16px" style="margin-right: 5px">
<path fill="#0052d9" d="M8 15A7 7 0 108 1a7 7 0 000 14zM7.4 4h1.2v1.2H7.4V4zm.1 2.5h1V12h-1V6.5z" fillOpacity="0.9"></path>
</svg>
Most icons were added to the icon library after version 0.2.0. If you find that the icon cannot be displayed normally after being imported, please check the version of tdesign-icons-vue-next you have installed</div>

<td-icons-view />


Expand Down
8 changes: 8 additions & 0 deletions src/icon/icon.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,14 @@ TDesign 支持通过使用 Iconfont 图标,使用时需要单独引入 Iconfon

### 全部图标

<div style="background: #ecf2fe; display: flex; align-items: center; line-height: 20px; padding: 14px 24px; border-radius: 3px; color: #555a65;margin:16px 0">
<svg fill="none" viewBox="0 0 16 16" width="16px" height="16px" style="margin-right: 5px">
<path fill="#0052d9" d="M8 15A7 7 0 108 1a7 7 0 000 14zM7.4 4h1.2v1.2H7.4V4zm.1 2.5h1V12h-1V6.5z" fillOpacity="0.9"></path>
</svg>
大部分图标在 0.2.0 版本后的图标库新增,如果发现图标引入后无法正常展示,请检查安装的图标库`tdesign-icons-vue-next`的版本。
</div>


<td-icons-view />

## API
Expand Down
Loading