Skip to content

Commit ef1b5f9

Browse files
committed
chore(demos): let input-group-showcase inherit size from global setting
1 parent 51f912e commit ef1b5f9

2 files changed

Lines changed: 7 additions & 22 deletions

File tree

src/app/input-group-showcase/input-group-showcase.sample.html

Lines changed: 7 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,7 @@ <h1 class="showcase__title">Angular</h1>
1313
<!-- Angular Input Group -->
1414
<igx-input-group
1515
#field
16-
[type]="getInputGroupType()"
17-
[style.--ig-size]="getSize()">
18-
16+
[type]="getInputGroupType()">
1917
@if (getLabel()) {
2018
<label igxLabel>{{ getLabel() }}</label>
2119
}
@@ -46,8 +44,7 @@ <h1 class="showcase__title">Angular</h1>
4644
<!-- Angular Textarea Group -->
4745
<igx-input-group
4846
#fieldTextarea
49-
[type]="getInputGroupType()"
50-
[style.--ig-size]="getSize()">
47+
[type]="getInputGroupType()">
5148
@if (getLabel()) {
5249
<label igxLabel>{{ getLabel() }}</label>
5350
}
@@ -77,8 +74,7 @@ <h1 class="showcase__title">Angular</h1>
7774
#selectReactive
7875
formControlName="angularSelect"
7976
[placeholder]="getPlaceholder()"
80-
[type]="getInputGroupType()"
81-
[style.--ig-size]="getSize()">
77+
[type]="getInputGroupType()">
8278
@if (getLabel()) {
8379
<label igxLabel>{{ getLabel() }}</label>
8480
}
@@ -105,9 +101,7 @@ <h1 class="showcase__title">Angular</h1>
105101
#comboReactive
106102
formControlName="angularCombo"
107103
[placeholder]="getPlaceholder()"
108-
[type]="getInputGroupType()"
109-
[style.--ig-size]="getSize()">
110-
104+
[type]="getInputGroupType()">
111105
@if (getLabel()) {
112106
<label igxLabel>{{ getLabel() }}</label>
113107
}
@@ -132,9 +126,7 @@ <h1 class="showcase__title">Angular</h1>
132126
<!-- Angular File Input -->
133127
<igx-input-group
134128
#fieldFile
135-
[type]="getInputGroupType()"
136-
[style.--ig-size]="getSize()">
137-
129+
[type]="getInputGroupType()">
138130
@if (getLabel()) {
139131
<label igxLabel for="file-in">{{ getLabel() }}</label>
140132
}
@@ -196,7 +188,6 @@ <h1 class="showcase__title">Web components</h1>
196188
<div class="showcase__fields">
197189
<!-- Web Component Input -->
198190
<igc-input
199-
[style.--ig-size]="getSize()"
200191
[label]="getLabel()"
201192
[required]="isRequired()"
202193
[attr.placeholder]="getPlaceholder()"
@@ -219,7 +210,6 @@ <h1 class="showcase__title">Web components</h1>
219210
</igc-input>
220211

221212
<igc-textarea
222-
[style.--ig-size]="getSize()"
223213
[label]="getLabel()"
224214
[required]="isRequired()"
225215
[disabled]="isDisabled()"
@@ -246,9 +236,7 @@ <h1 class="showcase__title">Web components</h1>
246236
[attr.placeholder]="getPlaceholder()"
247237
[label]="getLabel()"
248238
[disabled]="isDisabled()"
249-
[outlined]="isOutlined()"
250-
[style.--ig-size]="getSize()">
251-
239+
[outlined]="isOutlined()">
252240
@if (hidePrefix()) {
253241
<igc-icon slot="prefix" name="face"></igc-icon>
254242
}
@@ -267,16 +255,14 @@ <h1 class="showcase__title">Web components</h1>
267255
[label]="getLabel()"
268256
[attr.placeholder]="getPlaceholder()"
269257
[outlined]="isOutlined()"
270-
[disabled]="isDisabled()"
271-
[style.--ig-size]="getSize()">
258+
[disabled]="isDisabled()">
272259
@if (getHint()) {
273260
<span slot="helper-text">{{getHint()}}</span>
274261
}
275262
</igc-combo>
276263

277264

278265
<igc-file-input
279-
[style.--ig-size]="getSize()"
280266
[label]="getLabel()"
281267
[required]="isRequired()"
282268
[disabled]="isDisabled()"

src/app/input-group-showcase/input-group-showcase.sample.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -234,7 +234,6 @@ export class InputGroupShowcaseSampleComponent {
234234
}
235235

236236
public getValue = computed(() => this.properties()?.value || '');
237-
public getSize = computed(() => `var(--ig-size-${this.properties()?.size || 'medium'})`);
238237
public getPlaceholder = computed(() => this.properties()?.placeholder || null);
239238
public getLabel = computed(() => this.properties()?.label || '');
240239

0 commit comments

Comments
 (0)