@pb33f/cowboy-components 0.1.2 → 0.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/editor/editor.js +1 -1
- package/dist/components/mailing-list/mailing-list.js +2 -3
- package/dist/components/paginator/paginator-navigator.js +1 -1
- package/dist/components/paginator/paginator.js +3 -3
- package/dist/components/the-doctor/the-doctor.d.ts +1 -1
- package/dist/components/the-doctor/the-doctor.js +1 -1
- package/dist/events/doctor.d.ts +2 -2
- package/dist/model/problem.js +0 -64
- package/dist/services/linting-service.d.ts +4 -4
- package/dist/services/linting-service.js +1 -1
- package/package.json +6 -3
|
@@ -19,7 +19,7 @@ import htmlWorker from "monaco-editor/esm/vs/language/html/html.worker?worker";
|
|
|
19
19
|
import cssWorker from "monaco-editor/esm/vs/language/css/css.worker?worker";
|
|
20
20
|
// @ts-ignore
|
|
21
21
|
import jsonWorker from "monaco-editor/esm/vs/language/json/json.worker?worker";
|
|
22
|
-
import { EditorClicked, EditorUpdated } from "
|
|
22
|
+
import { EditorClicked, EditorUpdated } from "../../events/doctor";
|
|
23
23
|
// @ts-ignore
|
|
24
24
|
self.MonacoEnvironment = {
|
|
25
25
|
getWorker(_, label) {
|
|
@@ -5,10 +5,9 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
5
5
|
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
6
|
};
|
|
7
7
|
import { customElement, property, query, state } from "lit/decorators.js";
|
|
8
|
-
import { LitElement } from "lit";
|
|
9
|
-
import { html } from "lit";
|
|
8
|
+
import { LitElement, html } from "lit";
|
|
10
9
|
import mailingListComponentsCss from "./mailing-list.css.js";
|
|
11
|
-
import sharedCss from "
|
|
10
|
+
import sharedCss from "../../css/shared.css.js";
|
|
12
11
|
let MailingList = class MailingList extends LitElement {
|
|
13
12
|
constructor() {
|
|
14
13
|
super();
|
|
@@ -7,7 +7,7 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
7
7
|
import { customElement, property, query, state } from "lit/decorators.js";
|
|
8
8
|
import { html, LitElement } from "lit";
|
|
9
9
|
import paginatorNavigatorCss from "./paginator-navigator.css";
|
|
10
|
-
import { PaginatorFirstPage, PaginatorLastPage, PaginatorNextPage, PaginatorPreviousPage } from "
|
|
10
|
+
import { PaginatorFirstPage, PaginatorLastPage, PaginatorNextPage, PaginatorPreviousPage } from "../paginator/paginator-events";
|
|
11
11
|
import "@shoelace-style/shoelace/dist/components/format-number/format-number.js";
|
|
12
12
|
let PaginatorNavigation = class PaginatorNavigation extends LitElement {
|
|
13
13
|
constructor() {
|
|
@@ -6,9 +6,9 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
|
|
|
6
6
|
};
|
|
7
7
|
import { customElement, property } from "lit/decorators.js";
|
|
8
8
|
import { html, LitElement } from "lit";
|
|
9
|
-
import { PaginatorNavigation } from "
|
|
10
|
-
import { PaginatorFirstPage, PaginatorLastPage, PaginatorNextPage, PaginatorPreviousPage } from "
|
|
11
|
-
import paginatorCss from "./paginator.css";
|
|
9
|
+
import { PaginatorNavigation } from "./paginator-navigator.js";
|
|
10
|
+
import { PaginatorFirstPage, PaginatorLastPage, PaginatorNextPage, PaginatorPreviousPage } from "./paginator-events.js";
|
|
11
|
+
import paginatorCss from "./paginator.css.js";
|
|
12
12
|
let Paginator = class Paginator extends LitElement {
|
|
13
13
|
constructor() {
|
|
14
14
|
super();
|
|
@@ -5,7 +5,7 @@ import '@shoelace-style/shoelace/dist/components/tab/tab.js';
|
|
|
5
5
|
import '@shoelace-style/shoelace/dist/components/switch/switch.js';
|
|
6
6
|
import '@shoelace-style/shoelace/dist/components/dialog/dialog.js';
|
|
7
7
|
import { LitElement } from "lit";
|
|
8
|
-
import { EditorUpdatedEvent, ProblemRuleFilterChangedEvent } from "
|
|
8
|
+
import { EditorUpdatedEvent, ProblemRuleFilterChangedEvent } from "../../events/doctor";
|
|
9
9
|
import { ProblemDrawerEvent } from "../problem-list/details-drawer.js";
|
|
10
10
|
import { SlSwitch, SlTab, SlTabGroup } from "@shoelace-style/shoelace";
|
|
11
11
|
export declare const DoctorDocumentBag = "pb33f-doctor-editor";
|
|
@@ -13,7 +13,7 @@ import '@shoelace-style/shoelace/dist/components/dialog/dialog.js';
|
|
|
13
13
|
import { customElement, property, query } from "lit/decorators.js";
|
|
14
14
|
import { html, LitElement } from "lit";
|
|
15
15
|
import { SpecEditor } from "../editor/editor.js";
|
|
16
|
-
import { ActiveView, EditorClicked, EditorUpdated, OpenProblemDrawer, ProblemClicked, ProblemRuleFilterChangedManual, RuleClicked } from "
|
|
16
|
+
import { ActiveView, EditorClicked, EditorUpdated, OpenProblemDrawer, ProblemClicked, ProblemRuleFilterChangedManual, RuleClicked } from "../../events/doctor";
|
|
17
17
|
import { CreateBagManager } from "@pb33f/saddlebag";
|
|
18
18
|
import { LintingService } from "../../services/linting-service";
|
|
19
19
|
import { ProblemList } from "../../components/problem-list/problem-list.js";
|
package/dist/events/doctor.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ProblemItem } from "
|
|
2
|
-
import { Problem } from "
|
|
1
|
+
import { ProblemItem } from "../components/problem-list/problem-item";
|
|
2
|
+
import { Problem } from "../model/problem";
|
|
3
3
|
export declare const EditorUpdated: string;
|
|
4
4
|
export declare const EditorClicked: string;
|
|
5
5
|
export declare const ProblemClicked: string;
|
package/dist/model/problem.js
CHANGED
|
@@ -1,68 +1,4 @@
|
|
|
1
1
|
import * as monaco from "monaco-editor";
|
|
2
|
-
// export class ProblemStatistics {
|
|
3
|
-
// private _problems: ProblemItem[];
|
|
4
|
-
//
|
|
5
|
-
// errors: number;
|
|
6
|
-
// warnings: number;
|
|
7
|
-
// info: number;
|
|
8
|
-
// totalViolations: number;
|
|
9
|
-
// rulesViolated: number;
|
|
10
|
-
// categoriesViolated: number;
|
|
11
|
-
//
|
|
12
|
-
// constructor(problems: ProblemItem[]) {
|
|
13
|
-
// this.errors = 0;
|
|
14
|
-
// this.warnings = 0;
|
|
15
|
-
// this.info = 0;
|
|
16
|
-
// this.totalViolations = 0;
|
|
17
|
-
// this.rulesViolated = 0;
|
|
18
|
-
// this.categoriesViolated = 0;
|
|
19
|
-
// if (problems) {
|
|
20
|
-
// this.buildProblemStatistics(problems);
|
|
21
|
-
// }
|
|
22
|
-
// }
|
|
23
|
-
//
|
|
24
|
-
// private getErrors(): number {
|
|
25
|
-
// return this._problems.filter((problem) => {
|
|
26
|
-
// return problem.problemObject.severity === monaco.MarkerSeverity.Error;
|
|
27
|
-
// }).length;
|
|
28
|
-
// }
|
|
29
|
-
//
|
|
30
|
-
// private getWarnings(): number {
|
|
31
|
-
// return this._problems.filter((problem) => {
|
|
32
|
-
// return problem.problemObject.severity === monaco.MarkerSeverity.Warning;
|
|
33
|
-
// }).length;
|
|
34
|
-
// }
|
|
35
|
-
//
|
|
36
|
-
// private getInfo(): number {
|
|
37
|
-
// return this._problems.filter((problem) => {
|
|
38
|
-
// return problem?.problemObject?.severity === monaco.MarkerSeverity.Info;
|
|
39
|
-
// }).length;
|
|
40
|
-
// }
|
|
41
|
-
//
|
|
42
|
-
// get problems(): ProblemItem[] {
|
|
43
|
-
// return this._problems;
|
|
44
|
-
// }
|
|
45
|
-
//
|
|
46
|
-
// private buildProblemStatistics(problems: ProblemItem[]) {
|
|
47
|
-
// this._problems = problems;
|
|
48
|
-
// this.info = this.getInfo();
|
|
49
|
-
// this.errors = this.getErrors();
|
|
50
|
-
// this.warnings = this.getWarnings();
|
|
51
|
-
// this.totalViolations = this.errors + this.warnings + this.info;
|
|
52
|
-
// this.rulesViolated = new Set(problems.map((problem) => {
|
|
53
|
-
// return problem.source;
|
|
54
|
-
// })).size;
|
|
55
|
-
// this.categoriesViolated = new Set(problems.map((problem) => {
|
|
56
|
-
// return problem.problemObject.category;
|
|
57
|
-
// })).size
|
|
58
|
-
//
|
|
59
|
-
// }
|
|
60
|
-
//
|
|
61
|
-
// set problems(problems: ProblemItem[]) {
|
|
62
|
-
// this.buildProblemStatistics(problems);
|
|
63
|
-
// }
|
|
64
|
-
//
|
|
65
|
-
// }
|
|
66
2
|
export class Problem {
|
|
67
3
|
static reconstruct(problem) {
|
|
68
4
|
return new Problem(problem.category, problem.jsonPath, problem.endColumn, problem.endLineNumber, problem.message, problem.severity, problem.startColumn, problem.startLineNumber, problem.source, problem.id);
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { Problem } from "
|
|
2
|
-
import { HowToFix } from "
|
|
3
|
-
import { DrDiagnostics } from "
|
|
4
|
-
import { Session } from "
|
|
1
|
+
import { Problem } from "../model/problem";
|
|
2
|
+
import { HowToFix } from "../model/how_to_fix";
|
|
3
|
+
import { DrDiagnostics } from "../model/document-statistics";
|
|
4
|
+
import { Session } from "../model/session";
|
|
5
5
|
export declare class LintingService {
|
|
6
6
|
static doctorEndpoint: string;
|
|
7
7
|
static compareProblems(a: Problem, b: Problem): number;
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"description": "Princess Beef Heavy Industries Cowboy Components",
|
|
4
4
|
"private": false,
|
|
5
5
|
"license": "BUSL-1.1",
|
|
6
|
-
"version": "0.1.
|
|
6
|
+
"version": "0.1.4",
|
|
7
7
|
"type": "module",
|
|
8
8
|
"main": "./dist/cowboy-components.umd.cjs",
|
|
9
9
|
"module": "./dist/cowboy-components.js",
|
|
@@ -20,10 +20,13 @@
|
|
|
20
20
|
"./cowboy-components.js": "./dist/cowboy-components.js",
|
|
21
21
|
"./cowboy-components.umd.cjs": "./dist/cowboy-components.umd.cjs",
|
|
22
22
|
"./cowboy-components.css": "./dist/style.css",
|
|
23
|
-
"./
|
|
23
|
+
"./pb33f-theme.css": "./dist/css/pb33f-theme.css",
|
|
24
24
|
"./components/*": "./dist/components/*",
|
|
25
25
|
"./model/*": "./dist/model/*",
|
|
26
|
-
"./
|
|
26
|
+
"./services/*": "./dist/services/*",
|
|
27
|
+
"./workers/*": "./dist/workers/*",
|
|
28
|
+
"./events/*": "./dist/events/*",
|
|
29
|
+
"./assets/*": "./dist/assets/*"
|
|
27
30
|
},
|
|
28
31
|
"files": [
|
|
29
32
|
"dist"
|