@pb33f/cowboy-components 0.0.14 → 0.1.1
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/abap-DXvTa7XC.js +1404 -0
- package/dist/apex-DsQH3mjJ.js +332 -0
- package/dist/assets/css.worker-B_qZXUzt.js +84 -0
- package/dist/assets/editor.worker-HEmB0D7P.js +11 -0
- package/dist/assets/html.worker-D3WUrk8Q.js +458 -0
- package/dist/assets/json.worker-CAhUaBo4.js +42 -0
- package/dist/assets/rule-documentation.worker-BFIxMBU8.js +1 -0
- package/dist/assets/search-problems.worker-VJi4P9Gj.js +1 -0
- package/dist/azcli-Cir32SBk.js +74 -0
- package/dist/bat-BsNExolo.js +106 -0
- package/dist/bicep-2KcKzeQF.js +108 -0
- package/dist/cameligo-D0ezznwE.js +180 -0
- package/dist/clojure-DxYzAIlu.js +767 -0
- package/dist/coffee-DgiPTF3g.js +238 -0
- package/dist/components/editor/editor.d.ts +27 -0
- package/dist/components/editor/editor.js +192 -0
- package/dist/components/error-banner/error-banner.css.d.ts +2 -0
- package/dist/components/error-banner/error-banner.css.js +23 -0
- package/dist/components/error-banner/error-banner.d.ts +9 -0
- package/dist/components/error-banner/error-banner.js +40 -0
- package/dist/components/mailing-list/mailing-list.js +1 -1
- package/dist/components/paginator/paginator-events.d.ts +4 -0
- package/dist/components/paginator/paginator-events.js +4 -0
- package/dist/components/paginator/paginator-navigator.css.d.ts +2 -0
- package/dist/components/paginator/paginator-navigator.css.js +35 -0
- package/dist/components/paginator/paginator-navigator.d.ts +27 -0
- package/dist/components/paginator/paginator-navigator.js +168 -0
- package/dist/components/paginator/paginator.css.d.ts +2 -0
- package/dist/components/paginator/paginator.css.js +38 -0
- package/dist/components/paginator/paginator.d.ts +22 -0
- package/dist/components/paginator/paginator.js +122 -0
- package/dist/components/percent-bar/percent-bar.css.d.ts +2 -0
- package/dist/components/percent-bar/percent-bar.css.js +65 -0
- package/dist/components/percent-bar/percent-bar.d.ts +11 -0
- package/dist/components/percent-bar/percent-bar.js +85 -0
- package/dist/components/problem-list/details-drawer.css.d.ts +2 -0
- package/dist/components/problem-list/details-drawer.css.js +42 -0
- package/dist/components/problem-list/details-drawer.d.ts +22 -0
- package/dist/components/problem-list/details-drawer.js +66 -0
- package/dist/components/problem-list/filter.css.d.ts +2 -0
- package/dist/components/problem-list/filter.css.js +67 -0
- package/dist/components/problem-list/problem-item.css.d.ts +2 -0
- package/dist/components/problem-list/problem-item.css.js +170 -0
- package/dist/components/problem-list/problem-item.d.ts +27 -0
- package/dist/components/problem-list/problem-item.js +126 -0
- package/dist/components/problem-list/problem-label-view-filter.css.d.ts +2 -0
- package/dist/components/problem-list/problem-label-view-filter.css.js +6 -0
- package/dist/components/problem-list/problem-label-view-filter.d.ts +18 -0
- package/dist/components/problem-list/problem-label-view-filter.js +66 -0
- package/dist/components/problem-list/problem-list.css.d.ts +2 -0
- package/dist/components/problem-list/problem-list.css.js +59 -0
- package/dist/components/problem-list/problem-list.d.ts +37 -0
- package/dist/components/problem-list/problem-list.js +334 -0
- package/dist/components/problem-list/problem-mainview.css.d.ts +2 -0
- package/dist/components/problem-list/problem-mainview.css.js +100 -0
- package/dist/components/problem-list/problem-mainview.d.ts +20 -0
- package/dist/components/problem-list/problem-mainview.js +126 -0
- package/dist/components/problem-list/problem-rule-filter.d.ts +13 -0
- package/dist/components/problem-list/problem-rule-filter.js +67 -0
- package/dist/components/problem-list/problem-search-filter.d.ts +13 -0
- package/dist/components/problem-list/problem-search-filter.js +45 -0
- package/dist/components/problem-list/problem-sort-filter.d.ts +19 -0
- package/dist/components/problem-list/problem-sort-filter.js +67 -0
- package/dist/components/problem-list/problem-toolbar.css.d.ts +2 -0
- package/dist/components/problem-list/problem-toolbar.css.js +41 -0
- package/dist/components/problem-list/problem-toolbar.d.ts +14 -0
- package/dist/components/problem-list/problem-toolbar.js +63 -0
- package/dist/components/problem-list/shared.css.d.ts +2 -0
- package/dist/components/problem-list/shared.css.js +91 -0
- package/dist/components/problems-overview/diagnostic-evaluation.css.d.ts +2 -0
- package/dist/components/problems-overview/diagnostic-evaluation.css.js +178 -0
- package/dist/components/problems-overview/diagnostic-evaluation.d.ts +13 -0
- package/dist/components/problems-overview/diagnostic-evaluation.js +118 -0
- package/dist/components/problems-overview/document-statistic.css.d.ts +2 -0
- package/dist/components/problems-overview/document-statistic.css.js +16 -0
- package/dist/components/problems-overview/document-statistic.d.ts +10 -0
- package/dist/components/problems-overview/document-statistic.js +49 -0
- package/dist/components/problems-overview/problem-overview-group.css.d.ts +2 -0
- package/dist/components/problems-overview/problem-overview-group.css.js +84 -0
- package/dist/components/problems-overview/problem-overview-group.d.ts +17 -0
- package/dist/components/problems-overview/problem-overview-group.js +121 -0
- package/dist/components/problems-overview/problem-statistic.css.d.ts +2 -0
- package/dist/components/problems-overview/problem-statistic.css.js +40 -0
- package/dist/components/problems-overview/problem-statistic.d.ts +11 -0
- package/dist/components/problems-overview/problem-statistic.js +57 -0
- package/dist/components/problems-overview/problem-statistics.css.d.ts +2 -0
- package/dist/components/problems-overview/problem-statistics.css.js +46 -0
- package/dist/components/problems-overview/problem-statistics.d.ts +14 -0
- package/dist/components/problems-overview/problem-statistics.js +132 -0
- package/dist/components/problems-overview/problems-overview.css.d.ts +2 -0
- package/dist/components/problems-overview/problems-overview.css.js +49 -0
- package/dist/components/problems-overview/problems-overview.d.ts +21 -0
- package/dist/components/problems-overview/problems-overview.js +108 -0
- package/dist/components/render-json-path/render-json-path.css.d.ts +2 -0
- package/dist/components/render-json-path/render-json-path.css.js +86 -0
- package/dist/components/render-json-path/render-json-path.d.ts +11 -0
- package/dist/components/render-json-path/render-json-path.js +105 -0
- package/dist/components/the-doctor/settings.d.ts +5 -0
- package/dist/components/the-doctor/settings.js +22 -0
- package/dist/components/the-doctor/status-bar.css.d.ts +2 -0
- package/dist/components/the-doctor/status-bar.css.js +47 -0
- package/dist/components/the-doctor/status-bar.d.ts +12 -0
- package/dist/components/the-doctor/status-bar.js +71 -0
- package/dist/components/the-doctor/the-doctor.css.d.ts +2 -0
- package/dist/components/the-doctor/the-doctor.css.js +156 -0
- package/dist/components/the-doctor/the-doctor.d.ts +57 -0
- package/dist/components/the-doctor/the-doctor.js +340 -0
- package/dist/cowboy-components-BOuaCruy.js +114388 -0
- package/dist/cowboy-components.d.ts +5 -2
- package/dist/cowboy-components.js +8 -2
- package/dist/cowboy-components.umd.cjs +3997 -103
- package/dist/cpp-Bq-GnYlH.js +407 -0
- package/dist/csharp-IDcibKAT.js +332 -0
- package/dist/csp-QdYr8JWa.js +59 -0
- package/dist/css/button.css.d.ts +2 -0
- package/dist/css/button.css.js +34 -0
- package/dist/css/chroma-synxtax.css.d.ts +2 -0
- package/dist/css/chroma-synxtax.css.js +130 -0
- package/dist/css/cowboy-components.css +3 -0
- package/dist/css/links.css.d.ts +2 -0
- package/dist/css/links.css.js +17 -0
- package/dist/css/lists.css.d.ts +2 -0
- package/dist/css/lists.css.js +43 -0
- package/dist/css/pb33f-theme.css +2 -2
- package/dist/css/syntax.css.js +1 -1
- package/dist/css-C-wMMefI.js +193 -0
- package/dist/cssMode-Cvbhe77l.js +1541 -0
- package/dist/cypher-BfBo9yir.js +269 -0
- package/dist/dart-Cv3rVfv_.js +287 -0
- package/dist/dockerfile-DyCXBGhV.js +136 -0
- package/dist/ecl-COP_iObm.js +462 -0
- package/dist/elixir-DoEhbk9F.js +575 -0
- package/dist/events/doctor.d.ts +51 -0
- package/dist/events/doctor.js +17 -0
- package/dist/flow9-DuHGSNW1.js +148 -0
- package/dist/freemarker2-DmhDQrVn.js +995 -0
- package/dist/fsharp-Dv9PDxVO.js +223 -0
- package/dist/go-CcdAeqiK.js +224 -0
- package/dist/graphql-CoRm4b1H.js +157 -0
- package/dist/handlebars-DWUSy2Nn.js +425 -0
- package/dist/hcl-BSgAhV5f.js +189 -0
- package/dist/html-BTxdvu8o.js +314 -0
- package/dist/htmlMode-DeG-6tqP.js +1551 -0
- package/dist/ini-ewx9HLIq.js +77 -0
- package/dist/java-B5lwcbTy.js +238 -0
- package/dist/javascript-CQTBmqTv.js +76 -0
- package/dist/jsonMode-DJhhXlcK.js +1958 -0
- package/dist/julia-NCcg_P_q.js +517 -0
- package/dist/kotlin-BYlnmGrb.js +259 -0
- package/dist/less-DG4tqgOo.js +168 -0
- package/dist/lexon-CTTPcJLv.js +163 -0
- package/dist/liquid-OuSl50Zm.js +246 -0
- package/dist/lua-CxQ1RWuo.js +168 -0
- package/dist/m3-mHFfpmgx.js +216 -0
- package/dist/markdown-Dh6sYULt.js +235 -0
- package/dist/mdx-Cs8POpae.js +171 -0
- package/dist/mips-CNUcjHD1.js +204 -0
- package/dist/model/document-statistics.d.ts +40 -0
- package/dist/model/document-statistics.js +4 -0
- package/dist/model/how_to_fix.d.ts +4 -0
- package/dist/model/how_to_fix.js +1 -0
- package/dist/model/problem.d.ts +19 -0
- package/dist/model/problem.js +106 -0
- package/dist/model/rule_documentation.d.ts +5 -0
- package/dist/model/rule_documentation.js +1 -0
- package/dist/model/session.d.ts +5 -0
- package/dist/model/session.js +1 -0
- package/dist/msdax-ZvxFeKvs.js +381 -0
- package/dist/mysql-COjg31sJ.js +884 -0
- package/dist/objective-c-BqrCFBhT.js +189 -0
- package/dist/pascal-CUpkilAS.js +257 -0
- package/dist/pascaligo-nJfvRJ7x.js +170 -0
- package/dist/perl-CWsX6Ysg.js +632 -0
- package/dist/pgsql-DwgpEXC8.js +857 -0
- package/dist/php-CrbKyd62.js +506 -0
- package/dist/pla-JxXT6Kb-.js +143 -0
- package/dist/postiats-BOdnTRGv.js +913 -0
- package/dist/powerquery-DTkwcXGH.js +896 -0
- package/dist/powershell-Cx53dGpt.js +245 -0
- package/dist/protobuf-Dp9vE-l-.js +426 -0
- package/dist/pug-BSjKVjwP.js +408 -0
- package/dist/python-BsXAz21q.js +282 -0
- package/dist/qsharp-C5P1RxY3.js +291 -0
- package/dist/r-sEMYnclc.js +249 -0
- package/dist/razor-CXJ9MZn4.js +556 -0
- package/dist/redis-DbzUc-fU.js +308 -0
- package/dist/redshift-nrLijj1O.js +815 -0
- package/dist/restructuredtext-CIbGUl6T.js +180 -0
- package/dist/ruby-JcYJisWg.js +517 -0
- package/dist/rust-BgbFBFXH.js +349 -0
- package/dist/sb-hRFFChi7.js +121 -0
- package/dist/scala-Cs0yVo3Q.js +376 -0
- package/dist/scheme-l_0jNtxy.js +114 -0
- package/dist/scss-C4l7ZIRR.js +268 -0
- package/dist/services/linting-service.d.ts +12 -0
- package/dist/services/linting-service.js +121 -0
- package/dist/shell-ikLk_l24.js +227 -0
- package/dist/solidity-4GxCaH9e.js +1373 -0
- package/dist/sophia-tX0WEZsZ.js +205 -0
- package/dist/sparql-D7ky-uMk.js +207 -0
- package/dist/sql-CqEfBVGS.js +859 -0
- package/dist/st-CNWQPqyI.js +422 -0
- package/dist/style.css +1 -1
- package/dist/swift-C_fDfC0d.js +318 -0
- package/dist/systemverilog-gAvsEtN_.js +582 -0
- package/dist/tcl-KbBChuA6.js +238 -0
- package/dist/tsMode-C-mwN8lz.js +886 -0
- package/dist/twig-Bb652BpM.js +398 -0
- package/dist/typescript-CamPbG-s.js +349 -0
- package/dist/vb-2e5hSeUh.js +378 -0
- package/dist/wgsl-CYSDq0zg.js +445 -0
- package/dist/workers/rule-documentation.worker.d.ts +1 -0
- package/dist/workers/rule-documentation.worker.js +85 -0
- package/dist/workers/search-problems.worker.d.ts +1 -0
- package/dist/workers/search-problems.worker.js +19 -0
- package/dist/xml-CrDvxVsf.js +101 -0
- package/dist/yaml-xGWjZwPI.js +212 -0
- package/package.json +6 -4
|
@@ -0,0 +1,334 @@
|
|
|
1
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
+
};
|
|
7
|
+
import { customElement } from "lit/decorators.js";
|
|
8
|
+
import { html, LitElement } from "lit";
|
|
9
|
+
import { ProblemItem } from "@/components/problem-list/problem-item.js";
|
|
10
|
+
import { ProblemMainView } from "@/components/problem-list/problem-mainview.js";
|
|
11
|
+
import { MainViewSlideChanged, ProblemClicked, ProblemLabelViewFilterChanged, ProblemSortFilterChanged, ProblemSearchFilterChanged, MessageEvent, ProblemRuleFilterChanged, ProblemRuleFilterChangedManual } from "@/events/doctor";
|
|
12
|
+
import problemListCss from "./problem-list.css";
|
|
13
|
+
import sharedCss from "@/css/shared.css";
|
|
14
|
+
import { Problem } from "@/model/problem";
|
|
15
|
+
import { ProblemToolbar } from "@/components/problem-list/problem-toolbar";
|
|
16
|
+
import { ProblemLabelView } from "@/components/problem-list/problem-label-view-filter";
|
|
17
|
+
import { Paginator } from "@/components/paginator/paginator";
|
|
18
|
+
import { ProblemSortView } from "@/components/problem-list/problem-sort-filter";
|
|
19
|
+
import SearchWorker from "@/workers/search-problems.worker?worker";
|
|
20
|
+
import { Rules } from "@/components/problem-list/problem-rule-filter";
|
|
21
|
+
let ProblemList = class ProblemList extends LitElement {
|
|
22
|
+
constructor() {
|
|
23
|
+
super();
|
|
24
|
+
this.problemLabelView = ProblemLabelView.JSONPath;
|
|
25
|
+
this.problemList = [];
|
|
26
|
+
this.mainView = new ProblemMainView();
|
|
27
|
+
this.problemToolbar = new ProblemToolbar();
|
|
28
|
+
this.paginator = new Paginator();
|
|
29
|
+
this.unfilteredProblems = [];
|
|
30
|
+
this.searchWorker = new SearchWorker();
|
|
31
|
+
this.activeSearch = false;
|
|
32
|
+
this.addSearchWorkerListener();
|
|
33
|
+
// @ts-ignore
|
|
34
|
+
this.addEventListener(ProblemClicked, this.problemClicked);
|
|
35
|
+
// @ts-ignore
|
|
36
|
+
this.addEventListener(MainViewSlideChanged, this.slideChanged);
|
|
37
|
+
// @ts-ignore
|
|
38
|
+
this.addEventListener(ProblemLabelViewFilterChanged, this.labelFilterChanged);
|
|
39
|
+
// @ts-ignore
|
|
40
|
+
this.addEventListener(ProblemSortFilterChanged, this.sortFilterChanged);
|
|
41
|
+
// @ts-ignore
|
|
42
|
+
this.addEventListener(ProblemSearchFilterChanged, this.searchFilterChanged);
|
|
43
|
+
// @ts-ignore
|
|
44
|
+
this.addEventListener(ProblemRuleFilterChanged, this.ruleFilterChanged);
|
|
45
|
+
// @ts-ignore
|
|
46
|
+
this.addEventListener(ProblemRuleFilterChangedManual, this.ruleFilterChangedManual);
|
|
47
|
+
}
|
|
48
|
+
reset() {
|
|
49
|
+
this.activeSearch = false;
|
|
50
|
+
this.problemList = this.unfilteredProblems;
|
|
51
|
+
this.requestUpdate();
|
|
52
|
+
}
|
|
53
|
+
addSearchWorkerListener() {
|
|
54
|
+
const search = (event) => {
|
|
55
|
+
const data = event.data;
|
|
56
|
+
if (data) {
|
|
57
|
+
this.problemList = this.problemList.filter((problem) => {
|
|
58
|
+
for (let i = 0; i < data.length; i++) {
|
|
59
|
+
if (problem.problemObject.hash() === Problem.reconstruct(data[i]).hash()) {
|
|
60
|
+
return this.problemList[i];
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
});
|
|
64
|
+
this.paginator.setPage(1);
|
|
65
|
+
this.requestUpdate();
|
|
66
|
+
}
|
|
67
|
+
};
|
|
68
|
+
this.searchWorker.addEventListener(MessageEvent, search);
|
|
69
|
+
}
|
|
70
|
+
ruleFilterChanged(event) {
|
|
71
|
+
if (event.detail.rule !== Rules.AllRules) {
|
|
72
|
+
this.activeSearch = false;
|
|
73
|
+
this.problemList = this.unfilteredProblems;
|
|
74
|
+
this.search(event.detail.rule);
|
|
75
|
+
}
|
|
76
|
+
else {
|
|
77
|
+
this.activeSearch = false;
|
|
78
|
+
this.problemList = this.unfilteredProblems;
|
|
79
|
+
this.requestUpdate();
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
// triggered outside the component stack
|
|
83
|
+
ruleFilterChangedManual(event) {
|
|
84
|
+
this.ruleFilterChanged(event);
|
|
85
|
+
this.problemToolbar.ruleFilterChanged(event.detail.rule);
|
|
86
|
+
// TODO: tell the paginator to update the active rule
|
|
87
|
+
}
|
|
88
|
+
searchFilterChanged(event) {
|
|
89
|
+
if (event.detail.search !== "") {
|
|
90
|
+
if (!this.activeSearch) {
|
|
91
|
+
this.unfilteredProblems = this.problemList;
|
|
92
|
+
}
|
|
93
|
+
this.search(event.detail.search);
|
|
94
|
+
}
|
|
95
|
+
else {
|
|
96
|
+
this.activeSearch = false;
|
|
97
|
+
this.problemList = this.unfilteredProblems;
|
|
98
|
+
this.requestUpdate();
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
labelFilterChanged(event) {
|
|
102
|
+
this.changeProblemLabels(event.detail.label);
|
|
103
|
+
}
|
|
104
|
+
sortFilterChanged(event) {
|
|
105
|
+
this.changeSorting(event.detail.sort);
|
|
106
|
+
}
|
|
107
|
+
extractProblemsFromList() {
|
|
108
|
+
return this.problemList.map((problemItem) => {
|
|
109
|
+
return problemItem.problemObject;
|
|
110
|
+
});
|
|
111
|
+
}
|
|
112
|
+
extractRulesFromProblems() {
|
|
113
|
+
const mapped = this.extractProblemsFromList().map((problem) => {
|
|
114
|
+
return problem.source;
|
|
115
|
+
});
|
|
116
|
+
return new Set(mapped);
|
|
117
|
+
}
|
|
118
|
+
search(searchText) {
|
|
119
|
+
this.activeSearch = true;
|
|
120
|
+
this.searchWorker.postMessage({ search: searchText, problems: this.extractProblemsFromList() });
|
|
121
|
+
}
|
|
122
|
+
changeProblemLabels(problemType) {
|
|
123
|
+
for (let i = 0; i < this.problemList.length; i++) {
|
|
124
|
+
this.problemList[i].scrollOnUpdate = false;
|
|
125
|
+
switch (problemType) {
|
|
126
|
+
case ProblemLabelView.JSONPath:
|
|
127
|
+
this.problemList[i].problemLabelView = ProblemLabelView.JSONPath;
|
|
128
|
+
this.problemLabelView = ProblemLabelView.JSONPath;
|
|
129
|
+
break;
|
|
130
|
+
case ProblemLabelView.RuleViolation:
|
|
131
|
+
this.problemList[i].problemLabelView = ProblemLabelView.RuleViolation;
|
|
132
|
+
this.problemLabelView = ProblemLabelView.RuleViolation;
|
|
133
|
+
break;
|
|
134
|
+
case ProblemLabelView.Message:
|
|
135
|
+
this.problemList[i].problemLabelView = ProblemLabelView.Message;
|
|
136
|
+
this.problemLabelView = ProblemLabelView.Message;
|
|
137
|
+
break;
|
|
138
|
+
case ProblemLabelView.Category:
|
|
139
|
+
this.problemList[i].problemLabelView = ProblemLabelView.Category;
|
|
140
|
+
this.problemLabelView = ProblemLabelView.Category;
|
|
141
|
+
break;
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
}
|
|
145
|
+
changeSorting(sort) {
|
|
146
|
+
switch (sort) {
|
|
147
|
+
case ProblemSortView.LineNumber:
|
|
148
|
+
this.problemList = this.problemList.sort((a, b) => {
|
|
149
|
+
if (a.line < b.line)
|
|
150
|
+
return -1;
|
|
151
|
+
if (a.line > b.line)
|
|
152
|
+
return 1;
|
|
153
|
+
return 0;
|
|
154
|
+
});
|
|
155
|
+
break;
|
|
156
|
+
case ProblemSortView.Rule:
|
|
157
|
+
this.problemList = this.problemList.sort((a, b) => {
|
|
158
|
+
if (a.problemObject.source < b.problemObject.source)
|
|
159
|
+
return 1;
|
|
160
|
+
if (a.problemObject.source > b.problemObject.source)
|
|
161
|
+
return -1;
|
|
162
|
+
return 0;
|
|
163
|
+
});
|
|
164
|
+
break;
|
|
165
|
+
case ProblemSortView.JSONPath:
|
|
166
|
+
this.problemList = this.problemList.sort((a, b) => {
|
|
167
|
+
if (a.problemObject.jsonPath < b.problemObject.jsonPath)
|
|
168
|
+
return -1;
|
|
169
|
+
if (a.problemObject.jsonPath > b.problemObject.jsonPath)
|
|
170
|
+
return 1;
|
|
171
|
+
return 0;
|
|
172
|
+
});
|
|
173
|
+
break;
|
|
174
|
+
case ProblemSortView.Category:
|
|
175
|
+
this.problemList = this.problemList.sort((a, b) => {
|
|
176
|
+
if (a.problemObject.category < b.problemObject.category)
|
|
177
|
+
return -1;
|
|
178
|
+
if (a.problemObject.category > b.problemObject.category)
|
|
179
|
+
return 1;
|
|
180
|
+
return 0;
|
|
181
|
+
});
|
|
182
|
+
break;
|
|
183
|
+
case ProblemSortView.Severity:
|
|
184
|
+
this.problemList = this.problemList.sort((a, b) => {
|
|
185
|
+
if (a.problemObject.severity < b.problemObject.severity)
|
|
186
|
+
return 1;
|
|
187
|
+
if (a.problemObject.severity > b.problemObject.severity)
|
|
188
|
+
return -1;
|
|
189
|
+
return 0;
|
|
190
|
+
});
|
|
191
|
+
break;
|
|
192
|
+
}
|
|
193
|
+
this.problemList = this.problemList.slice(0, this.problemList.length);
|
|
194
|
+
this.requestUpdate();
|
|
195
|
+
}
|
|
196
|
+
problemClicked(event) {
|
|
197
|
+
//event.stopPropagation()
|
|
198
|
+
this.mainView.problems = [event.detail.problem];
|
|
199
|
+
this.lineClicked(event.detail.problem.line, false, event.detail.problem.idx);
|
|
200
|
+
this.paginator.activeIndex = event.detail.problem.resultIndex;
|
|
201
|
+
}
|
|
202
|
+
slideChanged(event) {
|
|
203
|
+
this.lineClicked(event.detail.problem.line, false, event.detail.index, true);
|
|
204
|
+
}
|
|
205
|
+
setActiveProblem(problems) {
|
|
206
|
+
let clicked = false;
|
|
207
|
+
if (this.activeProblem) {
|
|
208
|
+
for (let i = 0; i < problems.length; i++) {
|
|
209
|
+
if (problems[i].problemObject.hash() == this.activeProblem.problemObject.hash()) {
|
|
210
|
+
this.lineClicked(problems[i].line, false, problems[i].idx);
|
|
211
|
+
clicked = true;
|
|
212
|
+
}
|
|
213
|
+
}
|
|
214
|
+
}
|
|
215
|
+
if (!clicked) {
|
|
216
|
+
this.mainView.problems = [];
|
|
217
|
+
}
|
|
218
|
+
}
|
|
219
|
+
get problemItems() {
|
|
220
|
+
return this.problemList;
|
|
221
|
+
}
|
|
222
|
+
generateProblemItems(problems) {
|
|
223
|
+
const problemList = [];
|
|
224
|
+
const lineIdx = new Map();
|
|
225
|
+
for (let i = 0; i < problems.length; i++) {
|
|
226
|
+
const marker = problems[i];
|
|
227
|
+
const prob = new ProblemItem();
|
|
228
|
+
prob.line = marker.startLineNumber;
|
|
229
|
+
prob.column = marker.startColumn;
|
|
230
|
+
prob.problem = marker.jsonPath;
|
|
231
|
+
prob.problemLabelView = this.problemLabelView;
|
|
232
|
+
prob.problemObject = marker;
|
|
233
|
+
prob.resultIndex = i;
|
|
234
|
+
prob.parent = this;
|
|
235
|
+
if (lineIdx.has(marker.startLineNumber)) {
|
|
236
|
+
const problems = lineIdx.get(marker.startLineNumber);
|
|
237
|
+
problems.push(prob);
|
|
238
|
+
for (let i = 0; i < problems.length; i++) {
|
|
239
|
+
problems[i].idx = i + 1;
|
|
240
|
+
}
|
|
241
|
+
lineIdx.set(marker.startLineNumber, problems);
|
|
242
|
+
}
|
|
243
|
+
else {
|
|
244
|
+
lineIdx.set(marker.startLineNumber, [prob]);
|
|
245
|
+
}
|
|
246
|
+
problemList.push(prob);
|
|
247
|
+
}
|
|
248
|
+
return problemList;
|
|
249
|
+
}
|
|
250
|
+
set problems(problems) {
|
|
251
|
+
const problemList = this.generateProblemItems(problems);
|
|
252
|
+
this.problemList = problemList;
|
|
253
|
+
this.unfilteredProblems = problemList;
|
|
254
|
+
this.setActiveProblem(problemList);
|
|
255
|
+
this.problemToolbar.availableRules = [Rules.AllRules, ...this.extractRulesFromProblems()];
|
|
256
|
+
this.requestUpdate();
|
|
257
|
+
}
|
|
258
|
+
lineClicked(line, scroll = true, index = 0, stopCycle = false) {
|
|
259
|
+
let foundProblems = [];
|
|
260
|
+
this.problemList.forEach((problem) => {
|
|
261
|
+
const problemExists = problem.line === line;
|
|
262
|
+
if (problemExists) {
|
|
263
|
+
foundProblems.push(problem);
|
|
264
|
+
}
|
|
265
|
+
});
|
|
266
|
+
let selected = null;
|
|
267
|
+
this.problemList.forEach((problem) => {
|
|
268
|
+
problem.select(false);
|
|
269
|
+
problem.selectSibling(false);
|
|
270
|
+
});
|
|
271
|
+
if (foundProblems.length > 0) {
|
|
272
|
+
for (let i = 0; i < foundProblems.length; i++) {
|
|
273
|
+
const problem = foundProblems[i];
|
|
274
|
+
let s = i < 1;
|
|
275
|
+
if (!scroll)
|
|
276
|
+
s = false;
|
|
277
|
+
if (i === 0 && index == 0) {
|
|
278
|
+
selected = problem;
|
|
279
|
+
problem.select(true, s);
|
|
280
|
+
if (!this.activeSearch) {
|
|
281
|
+
this.paginator.setPage(problem.resultIndex + 1);
|
|
282
|
+
}
|
|
283
|
+
continue;
|
|
284
|
+
}
|
|
285
|
+
if (i === 0 && problem.idx === index) {
|
|
286
|
+
problem.select(true, s);
|
|
287
|
+
selected = problem;
|
|
288
|
+
if (!this.activeSearch) {
|
|
289
|
+
this.paginator.setPage(problem.resultIndex + 1);
|
|
290
|
+
}
|
|
291
|
+
continue;
|
|
292
|
+
}
|
|
293
|
+
if (i > 0 && problem.idx === index) {
|
|
294
|
+
problem.select(true, s);
|
|
295
|
+
if (!this.activeSearch) {
|
|
296
|
+
this.paginator.setPage(problem.resultIndex + 1);
|
|
297
|
+
}
|
|
298
|
+
selected = problem;
|
|
299
|
+
}
|
|
300
|
+
else {
|
|
301
|
+
problem.selectSibling(true, s);
|
|
302
|
+
}
|
|
303
|
+
}
|
|
304
|
+
}
|
|
305
|
+
this.mainView.problems = foundProblems;
|
|
306
|
+
if (selected)
|
|
307
|
+
this.activeProblem = selected;
|
|
308
|
+
if (selected && selected.idx !== 0) {
|
|
309
|
+
if (!stopCycle)
|
|
310
|
+
this.mainView.selectSlide(selected.idx);
|
|
311
|
+
}
|
|
312
|
+
}
|
|
313
|
+
render() {
|
|
314
|
+
this.paginator.values = this.problemList;
|
|
315
|
+
return html `
|
|
316
|
+
<div class="problem-list-container">
|
|
317
|
+
<div class="main-view">
|
|
318
|
+
${this.mainView}
|
|
319
|
+
</div>
|
|
320
|
+
<div class="toolbar">
|
|
321
|
+
${this.problemToolbar}
|
|
322
|
+
</div>
|
|
323
|
+
<div class="problem-list">
|
|
324
|
+
${this.paginator}
|
|
325
|
+
</div>
|
|
326
|
+
</div>
|
|
327
|
+
`;
|
|
328
|
+
}
|
|
329
|
+
};
|
|
330
|
+
ProblemList.styles = [problemListCss, sharedCss];
|
|
331
|
+
ProblemList = __decorate([
|
|
332
|
+
customElement("pb33f-problem-list")
|
|
333
|
+
], ProblemList);
|
|
334
|
+
export { ProblemList };
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
import { css } from "lit";
|
|
2
|
+
export default css `
|
|
3
|
+
|
|
4
|
+
:host {
|
|
5
|
+
font-size: 0.9rem;
|
|
6
|
+
}
|
|
7
|
+
.empty {
|
|
8
|
+
color: var(--font-color-sub2);
|
|
9
|
+
font-size: 1.4rem;
|
|
10
|
+
text-align: center;
|
|
11
|
+
margin-top: 20px;
|
|
12
|
+
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
.empty sl-icon {
|
|
16
|
+
margin-top: 20px;
|
|
17
|
+
font-size: 5rem;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
.main-view {
|
|
21
|
+
padding: 10px;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
.main-view-carousel{
|
|
25
|
+
padding: 0;
|
|
26
|
+
width: 100%;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
.problem {
|
|
30
|
+
display: flex;
|
|
31
|
+
width: 100%;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.message {
|
|
35
|
+
height: 155px;
|
|
36
|
+
max-height: 155px;
|
|
37
|
+
overflow-y: auto;
|
|
38
|
+
font-size: 1rem;
|
|
39
|
+
word-wrap: break-word;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
.icon {
|
|
43
|
+
width: 20px;
|
|
44
|
+
margin-right: 10px;
|
|
45
|
+
margin-left: 1px;
|
|
46
|
+
padding-top: 2px;
|
|
47
|
+
font-size: 1.2rem;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
.source {
|
|
51
|
+
display: flex;
|
|
52
|
+
margin-bottom: 5px;
|
|
53
|
+
width:100%;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
.location {
|
|
57
|
+
font-size: 0.7rem;
|
|
58
|
+
margin-top: 15px;
|
|
59
|
+
display: block;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
pb33f-render-json-path {
|
|
63
|
+
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
.carousel-message {
|
|
67
|
+
height: 200px;
|
|
68
|
+
overflow-y: auto;
|
|
69
|
+
text-align: left;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
sl-carousel {
|
|
73
|
+
height: 216px;
|
|
74
|
+
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
sl-carousel::part(base) {
|
|
78
|
+
grid-column-gap: 0;
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
sl-carousel::part(pagination) {
|
|
82
|
+
display: none;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
sl-carousel::part(navigation-button--next) {
|
|
86
|
+
color: var(--primary-color);
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
sl-carousel::part(navigation-button--previous) {
|
|
90
|
+
color: var(--primary-color);
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
sl-carousel-item {
|
|
94
|
+
border-radius: 0;
|
|
95
|
+
padding: 0;
|
|
96
|
+
margin: 0;
|
|
97
|
+
width: 100%;
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
`;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import '@shoelace-style/shoelace/dist/components/carousel/carousel.js';
|
|
2
|
+
import '@shoelace-style/shoelace/dist/components/carousel-item/carousel-item.js';
|
|
3
|
+
import { LitElement, TemplateResult } from "lit";
|
|
4
|
+
import { ProblemItem } from "./problem-item.js";
|
|
5
|
+
import { Problem } from "@/model/problem.js";
|
|
6
|
+
import { SlCarousel } from "@shoelace-style/shoelace";
|
|
7
|
+
export declare class ProblemMainView extends LitElement {
|
|
8
|
+
static styles: import("lit").CSSResult[];
|
|
9
|
+
problems: ProblemItem[];
|
|
10
|
+
carousel: SlCarousel;
|
|
11
|
+
selectedIndex: number;
|
|
12
|
+
private manualChange;
|
|
13
|
+
constructor();
|
|
14
|
+
showRuleDocs(): void;
|
|
15
|
+
howToFix(): void;
|
|
16
|
+
slideChanged(event: CustomEvent): void;
|
|
17
|
+
selectSlide(index: number): void;
|
|
18
|
+
render(): TemplateResult<1>;
|
|
19
|
+
renderProblem(problem: Problem): TemplateResult;
|
|
20
|
+
}
|
|
@@ -0,0 +1,126 @@
|
|
|
1
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
+
};
|
|
7
|
+
import '@shoelace-style/shoelace/dist/components/carousel/carousel.js';
|
|
8
|
+
import '@shoelace-style/shoelace/dist/components/carousel-item/carousel-item.js';
|
|
9
|
+
import { customElement, property, query } from "lit/decorators.js";
|
|
10
|
+
import { html, LitElement } from "lit";
|
|
11
|
+
import { ProblemItem } from "./problem-item.js";
|
|
12
|
+
import problemMainViewCss from "./problem-mainview.css.js";
|
|
13
|
+
import { marked } from "marked";
|
|
14
|
+
import { unsafeHTML } from "lit/directives/unsafe-html.js";
|
|
15
|
+
import sharedCss from "./shared.css.js";
|
|
16
|
+
import { getProblemClass, getProblemIcon } from "@/model/problem.js";
|
|
17
|
+
import { MainViewSlideChanged, OpenProblemDrawer } from "@/events/doctor.js";
|
|
18
|
+
import { ProblemDrawerEventType } from "@/components/problem-list/details-drawer.js";
|
|
19
|
+
let ProblemMainView = class ProblemMainView extends LitElement {
|
|
20
|
+
constructor() {
|
|
21
|
+
super();
|
|
22
|
+
this.selectedIndex = 0;
|
|
23
|
+
this.manualChange = false;
|
|
24
|
+
}
|
|
25
|
+
showRuleDocs() {
|
|
26
|
+
this.dispatchEvent(new CustomEvent(OpenProblemDrawer, {
|
|
27
|
+
bubbles: true,
|
|
28
|
+
composed: true,
|
|
29
|
+
detail: {
|
|
30
|
+
type: ProblemDrawerEventType.RULE_DOCS,
|
|
31
|
+
rule: this.problems[0].problemObject.source
|
|
32
|
+
}
|
|
33
|
+
}));
|
|
34
|
+
}
|
|
35
|
+
howToFix() {
|
|
36
|
+
this.dispatchEvent(new CustomEvent(OpenProblemDrawer, {
|
|
37
|
+
bubbles: true,
|
|
38
|
+
composed: true,
|
|
39
|
+
detail: {
|
|
40
|
+
type: ProblemDrawerEventType.HOW_TO_FIX,
|
|
41
|
+
rule: this.problems[0].problemObject.source
|
|
42
|
+
}
|
|
43
|
+
}));
|
|
44
|
+
}
|
|
45
|
+
slideChanged(event) {
|
|
46
|
+
if (this.manualChange) {
|
|
47
|
+
this.manualChange = false;
|
|
48
|
+
return;
|
|
49
|
+
}
|
|
50
|
+
this.dispatchEvent(new CustomEvent(MainViewSlideChanged, {
|
|
51
|
+
bubbles: true,
|
|
52
|
+
composed: true,
|
|
53
|
+
detail: {
|
|
54
|
+
index: event.detail.index + 1,
|
|
55
|
+
problem: this.problems[event.detail.index]
|
|
56
|
+
}
|
|
57
|
+
}));
|
|
58
|
+
}
|
|
59
|
+
selectSlide(index) {
|
|
60
|
+
this.selectedIndex = index;
|
|
61
|
+
this.manualChange = true;
|
|
62
|
+
setTimeout(() => {
|
|
63
|
+
this.carousel?.goToSlide(index - 1);
|
|
64
|
+
});
|
|
65
|
+
}
|
|
66
|
+
render() {
|
|
67
|
+
if (this.problems) {
|
|
68
|
+
if (this.problems.length > 1) {
|
|
69
|
+
return html `
|
|
70
|
+
<div class="main-view-carousel">
|
|
71
|
+
<sl-carousel @sl-slide-change=${this.slideChanged} navigation mouse-dragging>
|
|
72
|
+
${this.problems.map((problemItem) => {
|
|
73
|
+
return html `
|
|
74
|
+
<sl-carousel-item>
|
|
75
|
+
<div class="main-view-carousel">
|
|
76
|
+
${this.renderProblem(problemItem.problemObject)}
|
|
77
|
+
</div>
|
|
78
|
+
</sl-carousel-item>
|
|
79
|
+
`;
|
|
80
|
+
})}
|
|
81
|
+
</sl-carousel>
|
|
82
|
+
</div>
|
|
83
|
+
`;
|
|
84
|
+
}
|
|
85
|
+
if (this.problems[0] && this.problems[0].problemObject) {
|
|
86
|
+
return html `
|
|
87
|
+
<div class="main-view">
|
|
88
|
+
${this.renderProblem(this.problems[0].problemObject)}
|
|
89
|
+
</div>
|
|
90
|
+
`;
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
return html `
|
|
94
|
+
<div class="main-view empty">Pick a problem...<br/><sl-icon name="pin-angle"></sl-icon><br/></div>`;
|
|
95
|
+
}
|
|
96
|
+
renderProblem(problem) {
|
|
97
|
+
return html `
|
|
98
|
+
<div class="problem">
|
|
99
|
+
<div class="icon ${getProblemClass(problem)}">
|
|
100
|
+
<sl-icon name="${getProblemIcon(problem)}"></sl-icon>
|
|
101
|
+
</div>
|
|
102
|
+
<div class="message">
|
|
103
|
+
${unsafeHTML(marked.parse(problem.message).toString())}
|
|
104
|
+
<div class="location">
|
|
105
|
+
Location: <pb33f-render-json-path path="${problem.jsonPath}"></pb33f-render-json-path>
|
|
106
|
+
</div>
|
|
107
|
+
</div>
|
|
108
|
+
</div>
|
|
109
|
+
<div class="source">
|
|
110
|
+
<div>Rule: <a @click="${this.showRuleDocs}" href="#">${problem.source}</a></div>
|
|
111
|
+
<sl-icon-button @click=${this.howToFix} name="question-square" class="button-icon">
|
|
112
|
+
</sl-icon-button>
|
|
113
|
+
</div>`;
|
|
114
|
+
}
|
|
115
|
+
};
|
|
116
|
+
ProblemMainView.styles = [problemMainViewCss, sharedCss];
|
|
117
|
+
__decorate([
|
|
118
|
+
property({ type: ProblemItem })
|
|
119
|
+
], ProblemMainView.prototype, "problems", void 0);
|
|
120
|
+
__decorate([
|
|
121
|
+
query('sl-carousel')
|
|
122
|
+
], ProblemMainView.prototype, "carousel", void 0);
|
|
123
|
+
ProblemMainView = __decorate([
|
|
124
|
+
customElement("pb33f-problem-mainview")
|
|
125
|
+
], ProblemMainView);
|
|
126
|
+
export { ProblemMainView };
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { LitElement } from "lit";
|
|
2
|
+
export declare enum Rules {
|
|
3
|
+
AllRules = "All rules"
|
|
4
|
+
}
|
|
5
|
+
export declare class ProblemRuleFilter extends LitElement {
|
|
6
|
+
static styles: import("lit").CSSResult[];
|
|
7
|
+
rules: string[];
|
|
8
|
+
selectedRule: string;
|
|
9
|
+
constructor();
|
|
10
|
+
filterChanged(event: CustomEvent): void;
|
|
11
|
+
willUpdate(): void;
|
|
12
|
+
render(): import("lit-html").TemplateResult<1>;
|
|
13
|
+
}
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
2
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
3
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
4
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
5
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
6
|
+
};
|
|
7
|
+
import { html, LitElement } from "lit";
|
|
8
|
+
import { property, customElement } from "lit/decorators.js";
|
|
9
|
+
import { ProblemRuleFilterChanged, } from "@/events/doctor.js";
|
|
10
|
+
import problemLabelViewFilterCss from "./problem-label-view-filter.css.js";
|
|
11
|
+
import filterCss from "./filter.css.js";
|
|
12
|
+
export var Rules;
|
|
13
|
+
(function (Rules) {
|
|
14
|
+
Rules["AllRules"] = "All rules";
|
|
15
|
+
})(Rules || (Rules = {}));
|
|
16
|
+
let ProblemRuleFilter = class ProblemRuleFilter extends LitElement {
|
|
17
|
+
constructor() {
|
|
18
|
+
super();
|
|
19
|
+
}
|
|
20
|
+
filterChanged(event) {
|
|
21
|
+
const menuItem = event.detail.item;
|
|
22
|
+
this.selectedRule = menuItem.value;
|
|
23
|
+
this.dispatchEvent(new CustomEvent(ProblemRuleFilterChanged, {
|
|
24
|
+
composed: true,
|
|
25
|
+
detail: {
|
|
26
|
+
rule: this.selectedRule,
|
|
27
|
+
}
|
|
28
|
+
}));
|
|
29
|
+
}
|
|
30
|
+
willUpdate() {
|
|
31
|
+
if (this.selectedRule === undefined && this.rules?.length > 0) {
|
|
32
|
+
this.selectedRule = this.rules[0];
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
render() {
|
|
36
|
+
return html `
|
|
37
|
+
<div class="filter">
|
|
38
|
+
<div class="label"><label>Rule:</label></div>
|
|
39
|
+
<div class="dropdown">
|
|
40
|
+
<sl-dropdown skidding="5" distance="5">
|
|
41
|
+
<sl-button slot="trigger" caret>${this.selectedRule}</sl-button>
|
|
42
|
+
<sl-menu @sl-select=${this.filterChanged}>
|
|
43
|
+
${this.rules?.map((value) => {
|
|
44
|
+
return html `
|
|
45
|
+
<sl-menu-item value="${value}" type="checkbox"
|
|
46
|
+
.checked=${this.selectedRule === value}>
|
|
47
|
+
${value}
|
|
48
|
+
</sl-menu-item>`;
|
|
49
|
+
})}
|
|
50
|
+
</sl-menu>
|
|
51
|
+
</sl-dropdown>
|
|
52
|
+
</div>
|
|
53
|
+
</div>
|
|
54
|
+
`;
|
|
55
|
+
}
|
|
56
|
+
};
|
|
57
|
+
ProblemRuleFilter.styles = [problemLabelViewFilterCss, filterCss];
|
|
58
|
+
__decorate([
|
|
59
|
+
property()
|
|
60
|
+
], ProblemRuleFilter.prototype, "rules", void 0);
|
|
61
|
+
__decorate([
|
|
62
|
+
property()
|
|
63
|
+
], ProblemRuleFilter.prototype, "selectedRule", void 0);
|
|
64
|
+
ProblemRuleFilter = __decorate([
|
|
65
|
+
customElement('pb33f-problem-rule-filter')
|
|
66
|
+
], ProblemRuleFilter);
|
|
67
|
+
export { ProblemRuleFilter };
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import '@shoelace-style/shoelace/dist/components/dropdown/dropdown.js';
|
|
2
|
+
import '@shoelace-style/shoelace/dist/components/menu/menu.js';
|
|
3
|
+
import '@shoelace-style/shoelace/dist/components/menu-item/menu-item.js';
|
|
4
|
+
import { LitElement } from "lit";
|
|
5
|
+
import { SlInput } from "@shoelace-style/shoelace";
|
|
6
|
+
export declare class ProblemSearchFilter extends LitElement {
|
|
7
|
+
static styles: import("lit").CSSResult[];
|
|
8
|
+
selectedSort: string;
|
|
9
|
+
input: SlInput;
|
|
10
|
+
constructor();
|
|
11
|
+
search(): void;
|
|
12
|
+
render(): import("lit-html").TemplateResult<1>;
|
|
13
|
+
}
|