optimize api docs and build:theme script (#1441)

* feat(drawer): fit x-design theme

* feat(drawer): add demo and api document for 'tipsProps'

* fix(docs): optimize api type anchor

* fix(build): optimize build:theme script
This commit is contained in:
黄怡林 2024-03-01 16:32:17 +08:00 committed by GitHub
parent 0b4ef3c55f
commit a74ec33a1e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 6 additions and 4 deletions

View File

@ -81,12 +81,11 @@
>
</version-tip>
</td>
<td v-if="!key.includes('slots')">
<td v-if="!key.includes('slots')" @click="handleTypeClick">
<a
v-if="row.typeAnchorName"
:href="`${row.typeAnchorName.indexOf('#') === -1 ? '#' : ''}${row.typeAnchorName}`"
v-html="row.type"
@click="handleTypeClick"
></a>
<span v-else v-html="row.type"></span>
</td>
@ -370,7 +369,10 @@ export default defineComponent({
},
// api type
handleTypeClick: (ev) => {
changeActiveNames(ev.target.hash, true)
const hash = ev.target.hash
if (hash) {
changeActiveNames(hash, true)
}
},
//
handleAnchorClick: (e, data) => {

View File

@ -28,7 +28,7 @@
"./*": "./src/*"
},
"scripts": {
"clean": "rimraf dist",
"clean": "rimraf dist src/aurora-theme src/smb-theme",
"build:theme": "gulp build --gulpfile build/gulp-dist.js",
"build": "npm run clean && npm run build:theme && node build/replace-img.js",
"build:fast": "npm run build && npm run release",