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

atinc / ngx-tethys / d9ae709b-3c27-4b69-b125-b8b80b54f90b

pending completion
d9ae709b-3c27-4b69-b125-b8b80b54f90b

Pull #2757

circleci

mengshuicmq
fix: fix code review
Pull Request #2757: feat(color-picker): color-picker support disabled (#INFR-8645)

98 of 6315 branches covered (1.55%)

Branch coverage included in aggregate %.

1 of 1 new or added line in 1 file covered. (100.0%)

2392 of 13661 relevant lines covered (17.51%)

83.12 hits per line

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

33.33
/src/color-picker/helpers/rgba.class.ts
1
/**
2
 * RGB (Red Green Blue)
3
 *
4
 * Red = ranges from 0-255
5
 * Green = ranges from 0-255
6
 * Blue = ranges from 0-255
7
 * Alpha = range from 0-1
8
 */
9
export class ThyRgba {
10
    constructor(public red: number, public green: number, public blue: number, public alpha: number) {}
11

141✔
12
    public toString(showAlphaChannel: boolean = true): string {
141✔
13
        return showAlphaChannel
141✔
14
            ? `rgba(${this.getRed()}, ${this.getGreen()}, ${this.getBlue()}, ${this.getAlpha()})`
141✔
15
            : `rgb(${this.getRed()}, ${this.getGreen()}, ${this.getBlue()})`;
16
    }
×
17

×
18
    public getRed(): number {
19
        return Math.round(this.red);
20
    }
21

22
    public getGreen(): number {
×
23
        return Math.round(this.green);
24
    }
25

×
26
    public getBlue(): number {
27
        return Math.round(this.blue);
28
    }
×
29

30
    public getAlpha(): number {
31
        return Math.round(this.alpha * 100) / 100;
×
32
    }
33
}
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