@pb33f/cowboy-components 0.1.2 → 0.1.3

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.
@@ -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 "@/events/doctor";
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 "@/css/shared.css.js";
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 "@/components/paginator/paginator-events";
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 "@/components/paginator/paginator-navigator";
10
- import { PaginatorFirstPage, PaginatorLastPage, PaginatorNextPage, PaginatorPreviousPage } from "@/components/paginator/paginator-events";
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 "@/events/doctor";
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 "@/events/doctor";
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";
@@ -1,5 +1,5 @@
1
- import { ProblemItem } from "@/components/problem-list/problem-item";
2
- import { Problem } from "@/model/problem";
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;
@@ -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 "@/model/problem";
2
- import { HowToFix } from "@/model/how_to_fix";
3
- import { DrDiagnostics } from "@/model/document-statistics";
4
- import { Session } from "@/model/session";
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;
@@ -1,4 +1,4 @@
1
- import { Problem } from "@/model/problem";
1
+ import { Problem } from "../model/problem";
2
2
  export class LintingService {
3
3
  static compareProblems(a, b) {
4
4
  if (a.startLineNumber < b.startLineNumber) {
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.2",
6
+ "version": "0.1.3",
7
7
  "type": "module",
8
8
  "main": "./dist/cowboy-components.umd.cjs",
9
9
  "module": "./dist/cowboy-components.js",