mirror of https://github.com/abpframework/abp.git
committed by
GitHub
14 changed files with 57 additions and 70 deletions
@ -1,16 +1,13 @@ |
|||||
import { Component, Input } from '@angular/core'; |
import { Component, HostBinding, Input } from '@angular/core'; |
||||
|
|
||||
@Component({ |
@Component({ |
||||
selector: 'abp-card-body', |
selector: 'abp-card-body', |
||||
template: ` |
template: ` <div [ngClass]="cardBodyClass" [ngStyle]="cardBodyStyle">
|
||||
<div [ngClass]="cardBodyClass" [ngStyle]="cardBodyStyle" > |
<ng-content></ng-content> |
||||
<ng-content></ng-content> |
</div>`,
|
||||
</div>`,
|
|
||||
host: { |
|
||||
class: 'card-body', |
|
||||
} |
|
||||
}) |
}) |
||||
export class CardBodyComponent { |
export class CardBodyComponent { |
||||
|
@HostBinding('class') componentClass = 'card-body'; |
||||
@Input() cardBodyClass: string; |
@Input() cardBodyClass: string; |
||||
@Input() cardBodyStyle: string; |
@Input() cardBodyStyle: string; |
||||
} |
} |
||||
|
|||||
@ -1,19 +1,16 @@ |
|||||
import { Component, Input } from '@angular/core'; |
import { Component, HostBinding, Input } from '@angular/core'; |
||||
|
|
||||
@Component({ |
@Component({ |
||||
selector: 'abp-card-footer', |
selector: 'abp-card-footer', |
||||
template: ` |
template: ` |
||||
<div [ngStyle]="cardFooterStyle" [ngClass]="cardFooterClass" > |
<div [ngStyle]="cardFooterStyle" [ngClass]="cardFooterClass"> |
||||
<ng-content ></ng-content> |
<ng-content></ng-content> |
||||
</div> |
</div> |
||||
`,
|
`,
|
||||
styles: [], |
styles: [], |
||||
host: { |
|
||||
class: 'card-footer', |
|
||||
} |
|
||||
}) |
}) |
||||
export class CardFooterComponent { |
export class CardFooterComponent { |
||||
|
@HostBinding('class') componentClass = 'card-footer'; |
||||
@Input() cardFooterStyle: string; |
@Input() cardFooterStyle: string; |
||||
@Input() cardFooterClass: string; |
@Input() cardFooterClass: string; |
||||
|
|
||||
} |
} |
||||
|
|||||
@ -1,18 +1,16 @@ |
|||||
import { Component, Input } from '@angular/core'; |
import { Component, HostBinding, Input } from '@angular/core'; |
||||
|
|
||||
@Component({ |
@Component({ |
||||
selector: 'abp-card-header', |
selector: 'abp-card-header', |
||||
template: ` |
template: ` |
||||
<div [ngClass]="cardHeaderClass" [ngStyle]="cardHeaderStyle"> |
<div [ngClass]="cardHeaderClass" [ngStyle]="cardHeaderStyle"> |
||||
<ng-content ></ng-content> |
<ng-content></ng-content> |
||||
</div> |
</div> |
||||
`,
|
`,
|
||||
styles: [], |
styles: [], |
||||
host: { |
|
||||
class: 'card-header', |
|
||||
} |
|
||||
}) |
}) |
||||
export class CardHeaderComponent { |
export class CardHeaderComponent { |
||||
|
@HostBinding('class') componentClass = 'card-header'; |
||||
@Input() cardHeaderClass: string; |
@Input() cardHeaderClass: string; |
||||
@Input() cardHeaderStyle: string; |
@Input() cardHeaderStyle: string; |
||||
} |
} |
||||
|
|||||
@ -1,9 +1,8 @@ |
|||||
import { Directive } from "@angular/core"; |
import { Directive, HostBinding } from '@angular/core'; |
||||
|
|
||||
@Directive({ |
@Directive({ |
||||
selector: `abp-card-header, [abp-card-header], [abpCardHeader]`, |
selector: `abp-card-header, [abp-card-header], [abpCardHeader]`, |
||||
host: { |
|
||||
class: 'card-header', |
|
||||
}, |
|
||||
}) |
}) |
||||
export class CardHeader {} |
export class CardHeaderDirective { |
||||
|
@HostBinding('class') directiveClass = 'card-header'; |
||||
|
} |
||||
|
|||||
@ -1,9 +1,8 @@ |
|||||
import { Directive } from "@angular/core"; |
import { Directive, HostBinding } from '@angular/core'; |
||||
|
|
||||
@Directive({ |
@Directive({ |
||||
selector: `abp-card-img-top, [abp-card-img-top], [abpCardImgTop]`, |
selector: `abp-card-img-top, [abp-card-img-top], [abpCardImgTop]`, |
||||
host: { |
|
||||
class: 'card-img-top', |
|
||||
}, |
|
||||
}) |
}) |
||||
export class CardImgTop {} |
export class CardImgTopDirective { |
||||
|
@HostBinding('class') directiveClass = 'card-img-top'; |
||||
|
} |
||||
|
|||||
@ -1,9 +1,8 @@ |
|||||
import { Directive } from "@angular/core"; |
import { Directive, HostBinding } from '@angular/core'; |
||||
|
|
||||
@Directive({ |
@Directive({ |
||||
selector: `abp-card-subtitle, [abp-card-subtitle], [abpCardSubtitle]`, |
selector: `abp-card-subtitle, [abp-card-subtitle], [abpCardSubtitle]`, |
||||
host: { |
|
||||
class: 'card-subtitle', |
|
||||
}, |
|
||||
}) |
}) |
||||
export class CardSubtitle {} |
export class CardSubtitleDirective { |
||||
|
@HostBinding('class') directiveClass = 'card-subtitle'; |
||||
|
} |
||||
|
|||||
@ -1,9 +1,8 @@ |
|||||
import { Directive } from "@angular/core"; |
import { Directive, HostBinding } from '@angular/core'; |
||||
|
|
||||
@Directive({ |
@Directive({ |
||||
selector: `abp-card-title, [abp-card-title], [abpCardTitle]`, |
selector: `abp-card-title, [abp-card-title], [abpCardTitle]`, |
||||
host: { |
|
||||
class: 'card-title', |
|
||||
}, |
|
||||
}) |
}) |
||||
export class CardTitle {} |
export class CardTitleDirective { |
||||
|
@HostBinding('class') directiveClass = 'card-title'; |
||||
|
} |
||||
|
|||||
Loading…
Reference in new issue