-
Notifications
You must be signed in to change notification settings - Fork 357
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(docs): support list in pretty markdown to showcase API's better (#…
…1073) also added example in chips README.md
- Loading branch information
1 parent
d61416d
commit ac260e3
Showing
6 changed files
with
93 additions
and
19 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
13 changes: 13 additions & 0 deletions
13
src/app/documentation-tools/pretty-markdown/cfm-list/cfm-list.component.html
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,13 @@ | ||
<mat-list [attr.dense]="dense ? true : null"> | ||
<ng-template let-line let-last="last" ngFor [ngForOf]="lines"> | ||
<mat-list-item> | ||
<h4 matLine> | ||
{{line.line}} | ||
</h4> | ||
<p *ngFor="let subline of line.sublines" matLine> | ||
{{subline}} | ||
</p> | ||
</mat-list-item> | ||
<mat-divider *ngIf="!last"></mat-divider> | ||
</ng-template> | ||
</mat-list> |
Empty file.
19 changes: 19 additions & 0 deletions
19
src/app/documentation-tools/pretty-markdown/cfm-list/cfm-list.component.ts
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,19 @@ | ||
import { | ||
Component, | ||
Input, | ||
} from '@angular/core'; | ||
|
||
export interface IFlavoredListItem { | ||
line: string; | ||
sublines?: string[]; | ||
} | ||
|
||
@Component({ | ||
selector: 'cfm-list', | ||
styleUrls: ['./cfm-list.component.scss'], | ||
templateUrl: './cfm-list.component.html', | ||
}) | ||
export class TdFlavoredListComponent { | ||
@Input() lines: IFlavoredListItem[]; | ||
@Input() dense: boolean = 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