Skip to content

Commit b4d7ba1

Browse files
breadcrumb add thySeparator
1 parent 02bf881 commit b4d7ba1

File tree

7 files changed

+127
-216
lines changed

7 files changed

+127
-216
lines changed

.angulardoc.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
{
2+
"repoId": "5160fd8f-ac09-4862-8ed4-175e19c6bd87",
3+
"lastSync": 0
4+
}

demo/src/app/components/+breadcrumb/api-parameters.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,11 @@ export const apiBreadcrumbParameters = [
44
description: '面包屑的前缀展示图标,可以是 wtf wtf-folder, 如果是 wtf 图标,可以省略 wtf',
55
type: 'string',
66
default: ''
7+
},
8+
{
9+
property: 'thySeparator',
10+
description: '面包屑的分隔符,默认为">", thySeparator值为true时分隔符为"/"',
11+
type: 'boolean',
12+
default: ''
713
}
814
];

demo/src/app/components/+breadcrumb/breadcrumb-section.component.html

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<section>
2-
<div class="header"><h2>面包屑</h2></div>
2+
<div class="header"><h2>面包屑(">"分隔符)</h2></div>
33
<div class="body">
44
<thy-breadcrumb thyIcon="wtf-folder">
55
<thy-breadcrumb-item><span>首页</span></thy-breadcrumb-item>
@@ -17,6 +17,25 @@
1717
</div>
1818
</section>
1919

20+
<section>
21+
<div class="header"><h2>面包屑("/"分隔符)</h2></div>
22+
<div class="body">
23+
<thy-breadcrumb thyIcon="wtf-folder" thySeparator="true">
24+
<thy-breadcrumb-item><span>首页</span></thy-breadcrumb-item>
25+
<thy-breadcrumb-item>
26+
<a href="javascript:;">产品研发部</a>
27+
</thy-breadcrumb-item>
28+
<thy-breadcrumb-item>
29+
<a href="javascript:;">架构</a>
30+
</thy-breadcrumb-item>
31+
<thy-breadcrumb-item>
32+
<a href="javascript:;">基础 <i class="wtf wtf-angle-down"></i></a>
33+
</thy-breadcrumb-item>
34+
</thy-breadcrumb>
35+
<pre class="mt-1"><code lang="typescript" [highlight]="exampleCode2"></code></pre>
36+
</div>
37+
</section>
38+
2039
<api-parameters
2140
title="thy-breadcrumb 参数列表"
2241
[parameters]="apiBreadcrumbParameters"

demo/src/app/components/+breadcrumb/breadcrumb-section.component.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,12 @@ export class DemoBreadcrumbSectionComponent implements OnInit {
2222
</thy-breadcrumb>
2323
`;
2424

25+
exampleCode2 = `
26+
<thy-breadcrumb thyIcon="wtf-folder" thySeparator="true">
27+
...
28+
</thy-breadcrumb>
29+
`;
30+
2531
apiBreadcrumbParameters = apiBreadcrumbParameters;
2632
constructor() {}
2733

0 commit comments

Comments
 (0)