Skip to content

Commit

Permalink
feat(breadcrumb): [breadcrumb] modify delimiter (#2576)
Browse files Browse the repository at this point in the history
* feat(breadcrumb): [breadcrumb]  modify delimiter

* feat(breadcrumb): [breadcrumb]  modify delimiter
  • Loading branch information
wuyiping0628 authored Nov 29, 2024
1 parent 487a38b commit f8b2a47
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 9 deletions.
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
<template>
<div>
<tiny-breadcrumb separator="/">
<tiny-breadcrumb separator=">">
<tiny-breadcrumb-item><a href="#">首页</a></tiny-breadcrumb-item>
<tiny-breadcrumb-item>
<a href="#"> 产品 </a>
</tiny-breadcrumb-item>
<tiny-breadcrumb-item><a href="#"> 软件</a></tiny-breadcrumb-item>
</tiny-breadcrumb>
<br />
<tiny-breadcrumb :separator-icon="IconBoat">
<tiny-breadcrumb :separator-icon="iconChevronRight">
<tiny-breadcrumb-item><a hrfe="#">首页</a></tiny-breadcrumb-item>
<tiny-breadcrumb-item>
<a href="#"> 产品 </a>
Expand All @@ -20,7 +20,7 @@

<script setup>
import { TinyBreadcrumb, TinyBreadcrumbItem } from '@opentiny/vue'
import { iconBoat } from '@opentiny/vue-icon'
import { IconChevronRight } from '@opentiny/vue-icon'
const IconBoat = iconBoat()
const iconChevronRight = IconChevronRight()
</script>
2 changes: 1 addition & 1 deletion examples/sites/demos/pc/app/breadcrumb/separator.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@ test('Breadcrumb 自定义分隔符', async ({ page }) => {
const separator1 = breadcrumb.first().locator('.tiny-breadcrumb__separator')
const separator2 = breadcrumb.nth(1).locator('.tiny-breadcrumb__separator-cls')

await expect(separator1.first()).not.toHaveText(/>/)
await expect(separator1.first()).toHaveText(/>/)
await expect(separator2.first()).not.toHaveText(/>/)
})
8 changes: 4 additions & 4 deletions examples/sites/demos/pc/app/breadcrumb/separator.vue
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
<template>
<div>
<tiny-breadcrumb separator="/">
<tiny-breadcrumb separator=">">
<tiny-breadcrumb-item><a href="#">首页</a></tiny-breadcrumb-item>
<tiny-breadcrumb-item>
<a href="#"> 产品 </a>
</tiny-breadcrumb-item>
<tiny-breadcrumb-item><a href="#"> 软件</a></tiny-breadcrumb-item>
</tiny-breadcrumb>
<br />
<tiny-breadcrumb :separator-icon="IconBoat">
<tiny-breadcrumb :separator-icon="iconChevronRight">
<tiny-breadcrumb-item><a hrfe="#">首页</a></tiny-breadcrumb-item>
<tiny-breadcrumb-item>
<a href="#"> 产品 </a>
Expand All @@ -20,7 +20,7 @@

<script>
import { TinyBreadcrumb, TinyBreadcrumbItem } from '@opentiny/vue'
import { IconBoat } from '@opentiny/vue-icon'
import { IconChevronRight } from '@opentiny/vue-icon'
export default {
components: {
Expand All @@ -29,7 +29,7 @@ export default {
},
data() {
return {
IconBoat: IconBoat()
iconChevronRight: IconChevronRight()
}
}
}
Expand Down

0 comments on commit f8b2a47

Please sign in to comment.