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

donatj / loggre / 29301421458

14 Jul 2026 02:34AM UTC coverage: 29.284% (+2.4%) from 26.892%
29301421458

Pull #27

github

web-flow
Regenerate package-lock.json to fix missing @emnapi transitive dependencies
Pull Request #27: Bump typescript from 5.3.3 to 7.0.2

45 of 125 branches covered (36.0%)

Branch coverage included in aggregate %.

90 of 336 relevant lines covered (26.79%)

24.29 hits per line

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

0.0
/src/AbstractController.ts
1
export interface ControllerInterface<T extends HTMLElement = HTMLElement> {
2
        // attach(elm: HTMLElement): void;
3
        getContainer(): HTMLElement;
4
}
5

6
export abstract class AbstractBaseController<T extends HTMLElement = HTMLElement> implements ControllerInterface<T> {
7

8
        protected container: T;
×
9

10
        constructor(
11
                private name: string,
×
12
                container: T|keyof HTMLElementTagNameMap = "div",
×
13
        ) {
14
                if (typeof container === "string") {
×
15
                        this.container = document.createElement(container) as T;
×
16
                } else {
17
                        this.container = container;
×
18
                }
19

20
                this.container.classList.add(`${this.name}--controller`);
×
21
        }
22

23
        public getContainer() {
24
                return this.container;
×
25
        }
26

27
}
28

29
export function labelFor(label: string, input: HTMLInputElement|HTMLTextAreaElement|HTMLSelectElement) {
30
        if (input.id === "") {
×
31
                input.id = makeUniqueId();
×
32
        }
33

34
        let labelElm = document.createElement("label");
×
35
        labelElm.textContent = label;
×
36
        labelElm.htmlFor = input.id;
×
37

38
        return [labelElm, input];
×
39
}
40

41
export function makeUniqueId() {
42
        return "id-" + Math.random().toString(36).substring(2) + "-" + Date.now().toString(36);
×
43
}
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc