• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

IgniteUI / igniteui-angular / 12803948818

16 Jan 2025 07:17AM UTC coverage: 91.579% (-0.02%) from 91.595%
12803948818

Pull #14813

github

web-flow
Merge e9cbd10f0 into 58936f8fc
Pull Request #14813: feat(demos): add compared to WC section with samples to compare components

12986 of 15233 branches covered (85.25%)

1 of 6 new or added lines in 1 file covered. (16.67%)

26329 of 28750 relevant lines covered (91.58%)

34033.77 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

16.67
/projects/igniteui-angular/src/lib/directives/size/ig-size.directive.ts
1
import { Directive, HostBinding, Input } from '@angular/core';
2

3
@Directive({
4
    selector: '[igSize]',
5
})
6

7
export class IgSizeDirective {
2✔
8
    private _size: string;
9

10
    @HostBinding('style.--ig-size')
11
    public get styleValue(): string {
NEW
12
        return this._size;
×
13
    }
14

15
    @Input('igSize')
16
    public set igSize(value: 'small' | 'medium' | 'large' | string) {
NEW
17
        if (value === 'small' || value === 'medium' || value === 'large') {
×
NEW
18
            this._size = `var(--ig-size-${value})`;
×
19
        } else {
NEW
20
            console.warn(`Invalid size "${value}" provided. Expected 'small', 'medium', or 'large'.`);
×
NEW
21
            this._size = null; // Clear the size if invalid
×
22
        }
23
    }
24
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc