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

atinc / ngx-tethys / 1b395ef9-9b5d-4553-9091-e0714143e3a7

13 Dec 2023 02:40AM UTC coverage: 17.395% (-73.0%) from 90.364%
1b395ef9-9b5d-4553-9091-e0714143e3a7

push

circleci

luxiaobei
fix(select): remove focus() when close panel #INFR-10914

502 of 6578 branches covered (0.0%)

Branch coverage included in aggregate %.

1 of 2 new or added lines in 1 file covered. (50.0%)

10248 existing lines in 329 files now uncovered.

3092 of 14083 relevant lines covered (21.96%)

92.82 hits per line

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

20.0
/src/form/form-group-error/form-group-error.component.ts
1
import { InputBoolean } from 'ngx-tethys/core';
2
import { Component, HostBinding, ViewEncapsulation, OnInit, Optional, Input } from '@angular/core';
3
import { ThyFormDirective } from '../form.directive';
4
import { ThyAlertComponent } from 'ngx-tethys/alert';
5
import { NgClass, NgFor } from '@angular/common';
6

7
/**
8
 * @name thy-form-group-error
9
 * @order 50
10
 */
11
@Component({
12
    selector: 'thy-form-group-error',
1✔
13
    templateUrl: './form-group-error.component.html',
UNCOV
14
    encapsulation: ViewEncapsulation.None,
×
15
    standalone: true,
16
    imports: [NgClass, NgFor, ThyAlertComponent]
UNCOV
17
})
×
UNCOV
18
export class ThyFormGroupErrorComponent implements OnInit {
×
19
    public errors: string[];
20

UNCOV
21
    @Input() @InputBoolean() thyShowFirst = true;
×
22

23
    /**
UNCOV
24
     * @type string[]
×
UNCOV
25
     */
×
UNCOV
26
    @Input()
×
27
    set thyErrors(errors: string[]) {
28
        this.errors = errors;
UNCOV
29
    }
×
UNCOV
30

×
31
    get thyErrors() {
32
        const errors = this.errors || this.thyParentForm.validator.errors;
33
        return errors && errors.length > 0 && this.thyShowFirst ? [errors[0]] : errors;
1✔
34
    }
35

36
    @HostBinding('class.form-group')
1✔
37
    get _isFormGroup() {
38
        return this.thyErrors && this.thyErrors.length > 0;
39
    }
40

41
    @HostBinding('class.row') isHorizontal = true;
42

43
    constructor(@Optional() private thyParentForm: ThyFormDirective) {}
1✔
44

45
    ngOnInit() {
46
        if (this.thyParentForm) {
47
            this.isHorizontal = this.thyParentForm.isHorizontal;
1✔
48
        }
49
    }
50
}
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