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

IgniteUI / igniteui-angular / 16053471080

03 Jul 2025 02:41PM UTC coverage: 4.981% (-86.4%) from 91.409%
16053471080

Pull #16021

github

web-flow
Merge 7c49966eb into 7e40671a1
Pull Request #16021: fix(radio-group): dynamically added radio buttons do not initialize

178 of 15753 branches covered (1.13%)

13 of 14 new or added lines in 2 files covered. (92.86%)

25644 existing lines in 324 files now uncovered.

1478 of 29670 relevant lines covered (4.98%)

0.51 hits per line

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

11.11
/projects/igniteui-angular/src/lib/select/select-item.component.ts
1
import { IgxDropDownItemComponent } from './../drop-down/drop-down-item.component';
2
import { Component, Input } from '@angular/core';
3

4
@Component({
5
    selector: 'igx-select-item',
6
        templateUrl: 'select-item.component.html',
7
    standalone: true
8
})
9
export class IgxSelectItemComponent extends IgxDropDownItemComponent {
3✔
10
    /** @hidden @internal */
11
    public override isHeader: boolean;
12

13
    private _text: any;
14

15
    /**
16
     * Gets/Sets the item's text to be displayed in the select component's input when the item is selected.
17
     *
18
     * ```typescript
19
     *  //get
20
     *  let mySelectedItem = this.dropDown.selectedItem;
21
     *  let selectedItemText = mySelectedItem.text;
22
     * ```
23
     *
24
     * ```html
25
     * // set
26
     * <igx-select-item [text]="'London'"></igx-select-item>
27
     * ```
28
     */
29
    @Input()
30
    public get text(): string {
UNCOV
31
        return this._text;
×
32
    }
33

34
    public set text(text: string) {
UNCOV
35
        this._text = text;
×
36
    }
37

38
    /** @hidden @internal */
39
    public get itemText() {
UNCOV
40
        if (this._text !== undefined) {
×
UNCOV
41
            return this._text;
×
42
        }
43
        // If text @Input is undefined, try extract a meaningful item text out of the item template
UNCOV
44
        return this.elementRef.nativeElement.textContent.trim();
×
45
    }
46

47
    /**
48
     * Sets/Gets if the item is the currently selected one in the select
49
     *
50
     * ```typescript
51
     *  let mySelectedItem = this.select.selectedItem;
52
     *  let isMyItemSelected = mySelectedItem.selected; // true
53
     * ```
54
     */
55
    public override get selected() {
UNCOV
56
        return !this.isHeader && !this.disabled && this.selection.is_item_selected(this.dropDown.id, this);
×
57
    }
58

59
    public override set selected(value: any) {
UNCOV
60
        if (value && !this.isHeader && !this.disabled) {
×
UNCOV
61
            this.dropDown.selectItem(this);
×
62
        }
63
    }
64
}
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

© 2026 Coveralls, Inc