Skip to content

Commit 40d3a87

Browse files
committed
Directive updates
1 parent 405bf96 commit 40d3a87

File tree

5 files changed

+64
-0
lines changed

5 files changed

+64
-0
lines changed

packages/angular-workspace/nimble-angular/src/directives/combobox/nimble-combobox.directive.ts

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -83,5 +83,21 @@ export class NimbleComboboxDirective {
8383
this.renderer.setProperty(this.elementRef.nativeElement, 'requiredVisible', toBooleanProperty(value));
8484
}
8585

86+
public get appearanceReadOnly(): boolean {
87+
return this.elementRef.nativeElement.appearanceReadOnly;
88+
}
89+
90+
@Input('appearance-readonly') public set appearanceReadOnly(value: BooleanValueOrAttribute) {
91+
this.renderer.setProperty(this.elementRef.nativeElement, 'appearanceReadOnly', toBooleanProperty(value));
92+
}
93+
94+
public get fullBleed(): boolean {
95+
return this.elementRef.nativeElement.fullBleed;
96+
}
97+
98+
@Input('full-bleed') public set fullBleed(value: BooleanValueOrAttribute) {
99+
this.renderer.setProperty(this.elementRef.nativeElement, 'fullBleed', toBooleanProperty(value));
100+
}
101+
86102
public constructor(private readonly renderer: Renderer2, private readonly elementRef: ElementRef<Combobox>) {}
87103
}

packages/angular-workspace/nimble-angular/src/directives/number-field/nimble-number-field.directive.ts

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -96,5 +96,21 @@ export class NimbleNumberFieldDirective {
9696
this.renderer.setProperty(this.elementRef.nativeElement, 'requiredVisible', toBooleanProperty(value));
9797
}
9898

99+
public get appearanceReadOnly(): boolean {
100+
return this.elementRef.nativeElement.appearanceReadOnly;
101+
}
102+
103+
@Input('appearance-readonly') public set appearanceReadOnly(value: BooleanValueOrAttribute) {
104+
this.renderer.setProperty(this.elementRef.nativeElement, 'appearanceReadOnly', toBooleanProperty(value));
105+
}
106+
107+
public get fullBleed(): boolean {
108+
return this.elementRef.nativeElement.fullBleed;
109+
}
110+
111+
@Input('full-bleed') public set fullBleed(value: BooleanValueOrAttribute) {
112+
this.renderer.setProperty(this.elementRef.nativeElement, 'fullBleed', toBooleanProperty(value));
113+
}
114+
99115
public constructor(private readonly renderer: Renderer2, private readonly elementRef: ElementRef<NumberField>) {}
100116
}

packages/angular-workspace/nimble-angular/src/directives/select/nimble-select.directive.ts

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,5 +79,21 @@ export class NimbleSelectDirective {
7979
this.renderer.setProperty(this.elementRef.nativeElement, 'requiredVisible', toBooleanProperty(value));
8080
}
8181

82+
public get appearanceReadOnly(): boolean {
83+
return this.elementRef.nativeElement.appearanceReadOnly;
84+
}
85+
86+
@Input('appearance-readonly') public set appearanceReadOnly(value: BooleanValueOrAttribute) {
87+
this.renderer.setProperty(this.elementRef.nativeElement, 'appearanceReadOnly', toBooleanProperty(value));
88+
}
89+
90+
public get fullBleed(): boolean {
91+
return this.elementRef.nativeElement.fullBleed;
92+
}
93+
94+
@Input('full-bleed') public set fullBleed(value: BooleanValueOrAttribute) {
95+
this.renderer.setProperty(this.elementRef.nativeElement, 'fullBleed', toBooleanProperty(value));
96+
}
97+
8298
public constructor(private readonly renderer: Renderer2, private readonly elementRef: ElementRef<Select>) {}
8399
}

packages/angular-workspace/nimble-angular/src/directives/text-area/nimble-text-area.directive.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -146,5 +146,13 @@ export class NimbleTextAreaDirective {
146146
this.renderer.setProperty(this.elementRef.nativeElement, 'requiredVisible', toBooleanProperty(value));
147147
}
148148

149+
public get appearanceReadOnly(): boolean {
150+
return this.elementRef.nativeElement.appearanceReadOnly;
151+
}
152+
153+
@Input('appearance-readonly') public set appearanceReadOnly(value: BooleanValueOrAttribute) {
154+
this.renderer.setProperty(this.elementRef.nativeElement, 'appearanceReadOnly', toBooleanProperty(value));
155+
}
156+
149157
public constructor(private readonly renderer: Renderer2, private readonly elementRef: ElementRef<TextArea>) {}
150158
}

packages/angular-workspace/nimble-angular/src/directives/text-field/nimble-text-field.directive.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -144,5 +144,13 @@ export class NimbleTextFieldDirective {
144144
this.renderer.setProperty(this.elementRef.nativeElement, 'requiredVisible', toBooleanProperty(value));
145145
}
146146

147+
public get appearanceReadOnly(): boolean {
148+
return this.elementRef.nativeElement.appearanceReadOnly;
149+
}
150+
151+
@Input('appearance-readonly') public set appearanceReadOnly(value: BooleanValueOrAttribute) {
152+
this.renderer.setProperty(this.elementRef.nativeElement, 'appearanceReadOnly', toBooleanProperty(value));
153+
}
154+
147155
public constructor(private readonly renderer: Renderer2, private readonly elementRef: ElementRef<TextField>) {}
148156
}

0 commit comments

Comments
 (0)