@redocly/replay 0.29.0-next.2 → 0.29.0-next.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/{replay-AiChatProvider-CRI2UTsZ.js → replay-AiChatProvider-DR7NuYZo.js} +52 -52
- package/dist/{replay-AiChatProvider-6XfGmlMO.js → replay-AiChatProvider-GWJ-n-vh.js} +1 -1
- package/dist/{replay-AiChatSqliteDBStorage-BlEocJgY.js → replay-AiChatSqliteDBStorage--C03eLtv.js} +1 -1
- package/dist/{replay-AiChatSqliteDBStorage-DA-eJh6c.js → replay-AiChatSqliteDBStorage-BFkOn15p.js} +1 -1
- package/dist/{replay-AiPanel-DYVgRVdG.js → replay-AiPanel-1tEi12j1.js} +1 -1
- package/dist/{replay-AiPanel-ZrR1tDqo.js → replay-AiPanel-CXIw_O8d.js} +4 -4
- package/dist/{replay-FileWatcher-BNFHO596.js → replay-FileWatcher-B9PZyA8D.js} +1 -1
- package/dist/{replay-FileWatcher-CELEsith.js → replay-FileWatcher-SUnXmGod.js} +2 -2
- package/dist/{replay-SemanticSearchService-BEk_dTbd.js → replay-SemanticSearchService-BGg8Dbuq.js} +20 -20
- package/dist/{replay-SemanticSearchService-Dooeje9n.js → replay-SemanticSearchService-vr1hqPU7.js} +1 -1
- package/dist/{replay-SqliteDBStorage-3K7IPlJU.js → replay-SqliteDBStorage-DcIA3sjg.js} +1 -1
- package/dist/{replay-SqliteDBStorage-CLSBc7bS.js → replay-SqliteDBStorage-lUh6lJSO.js} +1 -1
- package/dist/{replay-TauriFileSystemAdapter-D-IrcgXM.js → replay-TauriFileSystemAdapter-C2c2Qy4S.js} +1 -1
- package/dist/{replay-TauriFileSystemAdapter-BvJ1azsj.js → replay-TauriFileSystemAdapter-wAZBliTE.js} +1 -1
- package/dist/{replay-TauriRootStorage-b3tjVs4a.js → replay-TauriRootStorage-CwVriXnS.js} +12 -12
- package/dist/{replay-TauriRootStorage-DylcqkvS.js → replay-TauriRootStorage-olGW7jq5.js} +1 -1
- package/dist/{replay-agent-loop-DgP7lcS9.js → replay-agent-loop-GDXIQGy5.js} +1 -1
- package/dist/{replay-agent-loop-Dev3mG-o.js → replay-agent-loop-QLgzMDfU.js} +5 -5
- package/dist/{replay-ai-chat-mappers-B6nh9aAX.js → replay-ai-chat-mappers-DFVcviEH.js} +1 -1
- package/dist/{replay-ai-chat-mappers-f3kvLmAu.js → replay-ai-chat-mappers-Dkj4vl9T.js} +1 -1
- package/dist/{replay-create-model-CKCKpcry.js → replay-create-model-D9NcJ3yx.js} +3 -3
- package/dist/{replay-create-model-DWPoobaj.js → replay-create-model-UDURpFQ4.js} +4 -4
- package/dist/{replay-db-B6aY7_xq.js → replay-db-CFx-F30d.js} +1 -1
- package/dist/{replay-db-C5zt3C9P.js → replay-db-CMt9dX-H.js} +6 -6
- package/dist/{replay-external-resolver-CnBhw18p.js → replay-external-resolver-CPD4hskh.js} +1 -1
- package/dist/{replay-external-resolver-vQRj5DBT.js → replay-external-resolver-rqFR7T0O.js} +2 -2
- package/dist/{replay-index-qjs9VMHC.js → replay-index-0MfVkwY4.js} +1 -1
- package/dist/replay-index-BTZoG4e-.js +4 -0
- package/dist/replay-index-CLJOTBS9.js +7204 -0
- package/dist/{replay-index-_gr2NUI6.js → replay-index-CVhBLstt.js} +1 -1
- package/dist/{replay-index-CG98QK-s.js → replay-index-DFopWLS5.js} +146 -139
- package/dist/replay-index-DFpzg2pO.js +1 -0
- package/dist/{replay-index-DK7gbiWU.js → replay-index-DhelzkVo.js} +54095 -39989
- package/dist/{replay-index-kTnSyklR.js → replay-index-X5PC09Iq.js} +1 -1
- package/dist/replay-lint-VrViwed0.js +121 -0
- package/dist/replay-lint-graphql-BytE8Msa.js +99 -0
- package/dist/replay-lint-graphql-Cj0YxKYW.js +1 -0
- package/dist/replay-lint-xvdvEmuK.js +22810 -0
- package/dist/{replay-periodic-revalidation--AI8Odct.js → replay-periodic-revalidation-CBK4GGcK.js} +1 -1
- package/dist/{replay-periodic-revalidation-B3_dehdk.js → replay-periodic-revalidation-UaQh_EiA.js} +1 -1
- package/dist/{replay-resolve-CF2p-q2m.js → replay-resolve-B-ScAEQ_.js} +1 -1
- package/dist/{replay-resolve-CVaipzl1.js → replay-resolve-DxLYwKrU.js} +1 -1
- package/dist/{replay-respect-run-CMwBljW2.js → replay-respect-run-BC7vr1j1.js} +21 -21
- package/dist/{replay-respect-run-D8MFUbGR.js → replay-respect-run-C84RN_GR.js} +430 -421
- package/dist/{replay-tauri-path-00tVitOG.js → replay-tauri-path-B-SLo2Ec.js} +2 -2
- package/dist/{replay-tauri-path-CNqnykPe.js → replay-tauri-path-Bl15GRY1.js} +1 -1
- package/dist/{replay-useAiChatQueries-1FXgtUM0.js → replay-useAiChatQueries-C-ZR0ZaE.js} +1 -1
- package/dist/{replay-useAiChatQueries-B1lLdezQ.js → replay-useAiChatQueries-gO6Sj7A5.js} +4 -4
- package/dist/{replay-validate-key-BY6-63zj.js → replay-validate-key-CuCnpHLS.js} +1 -1
- package/dist/{replay-validate-key-CQrY8WaE.js → replay-validate-key-D5QLY_qk.js} +2 -2
- package/dist/replay.cjs +1 -1
- package/dist/replay.d.ts +7 -0
- package/dist/replay.js +11 -11
- package/package.json +7 -4
- package/dist/replay-index-CucrJtfX.js +0 -7026
- package/dist/replay-index-D5Z0mNdH.js +0 -1
- package/dist/replay-index-Ea2twOHC.js +0 -4
- package/dist/replay-lint-B27guSWl.js +0 -30232
- package/dist/replay-lint-BMx3SufP.js +0 -177
- package/dist/replay-lint-graphql-Ddb-P1_x.js +0 -1956
- package/dist/replay-lint-graphql-DttNVvr_.js +0 -3
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
import { i as y } from "./replay-lint-xvdvEmuK.js";
|
|
2
|
+
import { x as d, y as h, S as v, G as I, z as x, B as G } from "./replay-index-DhelzkVo.js";
|
|
3
|
+
function b(t, n) {
|
|
4
|
+
const e = {};
|
|
5
|
+
for (const o of Object.keys(t)) {
|
|
6
|
+
const s = t[o];
|
|
7
|
+
if (!s)
|
|
8
|
+
continue;
|
|
9
|
+
const c = typeof s == "function" ? s : s.enter, r = typeof s == "function" ? void 0 : s.leave;
|
|
10
|
+
e[o] = {
|
|
11
|
+
...c ? { enter: g(c, n) } : {},
|
|
12
|
+
...r ? { leave: g(r, n) } : {}
|
|
13
|
+
};
|
|
14
|
+
}
|
|
15
|
+
return e;
|
|
16
|
+
}
|
|
17
|
+
function g(t, n) {
|
|
18
|
+
return (e, o, s, c, r) => {
|
|
19
|
+
t(e, k(e, n, r));
|
|
20
|
+
};
|
|
21
|
+
}
|
|
22
|
+
function k(t, n, e = []) {
|
|
23
|
+
const { ruleId: o, severity: s, message: c, source: r, config: l, problems: a } = n, u = e.filter((i) => !Array.isArray(i));
|
|
24
|
+
return {
|
|
25
|
+
source: r,
|
|
26
|
+
config: l,
|
|
27
|
+
ancestors: u,
|
|
28
|
+
report(i) {
|
|
29
|
+
const p = i.node ?? t, f = i.loc ?? q(p), m = {
|
|
30
|
+
source: r,
|
|
31
|
+
pointer: void 0,
|
|
32
|
+
start: f?.start ?? { line: 1, col: 1 },
|
|
33
|
+
end: f?.end
|
|
34
|
+
};
|
|
35
|
+
a.push({
|
|
36
|
+
ruleId: i.ruleId ?? o,
|
|
37
|
+
severity: i.severity ?? s,
|
|
38
|
+
message: c ? c.replace("{{message}}", i.message) : i.message,
|
|
39
|
+
suggest: i.suggest ?? [],
|
|
40
|
+
location: [m]
|
|
41
|
+
});
|
|
42
|
+
}
|
|
43
|
+
};
|
|
44
|
+
}
|
|
45
|
+
function q(t) {
|
|
46
|
+
if (!t?.loc)
|
|
47
|
+
return;
|
|
48
|
+
const n = d(t.loc.source, t.loc.start), e = d(t.loc.source, t.loc.end);
|
|
49
|
+
return {
|
|
50
|
+
start: { line: n.line, col: n.column },
|
|
51
|
+
end: { line: e.line, col: e.column }
|
|
52
|
+
};
|
|
53
|
+
}
|
|
54
|
+
function V(t) {
|
|
55
|
+
const { document: n, config: e } = t, o = n.source;
|
|
56
|
+
if (o.body.trim() === "")
|
|
57
|
+
return [
|
|
58
|
+
{
|
|
59
|
+
ruleId: "struct",
|
|
60
|
+
severity: "error",
|
|
61
|
+
message: "The GraphQL document is empty. Expected at least one type definition.",
|
|
62
|
+
suggest: [],
|
|
63
|
+
location: [{ source: o, pointer: void 0, start: { line: 1, col: 1 } }]
|
|
64
|
+
}
|
|
65
|
+
];
|
|
66
|
+
let s;
|
|
67
|
+
try {
|
|
68
|
+
s = h(new v(o.body, o.absoluteRef));
|
|
69
|
+
} catch (a) {
|
|
70
|
+
if (a instanceof I)
|
|
71
|
+
return [L(a, o)];
|
|
72
|
+
throw a;
|
|
73
|
+
}
|
|
74
|
+
const c = e.getRulesForSpecVersion("graphql") ?? [], r = y(c, e, "rules", "graphql");
|
|
75
|
+
return R({ ast: s, source: o, config: e, rules: r }).map((a) => e.addProblemToIgnore(a));
|
|
76
|
+
}
|
|
77
|
+
function L(t, n) {
|
|
78
|
+
const e = t.locations?.[0];
|
|
79
|
+
return {
|
|
80
|
+
ruleId: "struct",
|
|
81
|
+
severity: "error",
|
|
82
|
+
message: t.message,
|
|
83
|
+
suggest: [],
|
|
84
|
+
location: [
|
|
85
|
+
{
|
|
86
|
+
source: n,
|
|
87
|
+
pointer: void 0,
|
|
88
|
+
start: e ? { line: e.line, col: e.column } : { line: 1, col: 1 }
|
|
89
|
+
}
|
|
90
|
+
]
|
|
91
|
+
};
|
|
92
|
+
}
|
|
93
|
+
function R(t) {
|
|
94
|
+
const { ast: n, source: e, config: o, rules: s } = t, c = [], r = s.map(({ ruleId: l, severity: a, message: u, visitor: i }) => b(i, { ruleId: l, severity: a, message: u, source: e, config: o, problems: c }));
|
|
95
|
+
return r.length > 0 && x(n, G(r)), c;
|
|
96
|
+
}
|
|
97
|
+
export {
|
|
98
|
+
V as lintGraphqlDocument
|
|
99
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const y=require("./replay-lint-VrViwed0.js"),u=require("./replay-index-CLJOTBS9.js");function h(t,n){const e={};for(const o of Object.keys(t)){const r=t[o];if(!r)continue;const c=typeof r=="function"?r:r.enter,s=typeof r=="function"?void 0:r.leave;e[o]={...c?{enter:g(c,n)}:{},...s?{leave:g(s,n)}:{}}}return e}function g(t,n){return(e,o,r,c,s)=>{t(e,v(e,n,s))}}function v(t,n,e=[]){const{ruleId:o,severity:r,message:c,source:s,config:a,problems:l}=n,f=e.filter(i=>!Array.isArray(i));return{source:s,config:a,ancestors:f,report(i){const p=i.node??t,d=i.loc??q(p),m={source:s,pointer:void 0,start:d?.start??{line:1,col:1},end:d?.end};l.push({ruleId:i.ruleId??o,severity:i.severity??r,message:c?c.replace("{{message}}",i.message):i.message,suggest:i.suggest??[],location:[m]})}}}function q(t){if(!t?.loc)return;const n=u.getLocation(t.loc.source,t.loc.start),e=u.getLocation(t.loc.source,t.loc.end);return{start:{line:n.line,col:n.column},end:{line:e.line,col:e.column}}}function I(t){const{document:n,config:e}=t,o=n.source;if(o.body.trim()==="")return[{ruleId:"struct",severity:"error",message:"The GraphQL document is empty. Expected at least one type definition.",suggest:[],location:[{source:o,pointer:void 0,start:{line:1,col:1}}]}];let r;try{r=u.parse(new u.Source(o.body,o.absoluteRef))}catch(l){if(l instanceof u.GraphQLError)return[b(l,o)];throw l}const c=e.getRulesForSpecVersion("graphql")??[],s=y.initRules(c,e,"rules","graphql");return G({ast:r,source:o,config:e,rules:s}).map(l=>e.addProblemToIgnore(l))}function b(t,n){const e=t.locations?.[0];return{ruleId:"struct",severity:"error",message:t.message,suggest:[],location:[{source:n,pointer:void 0,start:e?{line:e.line,col:e.column}:{line:1,col:1}}]}}function G(t){const{ast:n,source:e,config:o,rules:r}=t,c=[],s=r.map(({ruleId:a,severity:l,message:f,visitor:i})=>h(i,{ruleId:a,severity:l,message:f,source:e,config:o,problems:c}));return s.length>0&&u.visit(n,u.visitInParallel(s)),c}exports.lintGraphqlDocument=I;
|