@graphiql/plugin-collections 1.0.0-beta.0 → 1.0.0-beta.2
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/LICENSE +21 -0
- package/dist/components/collection-item-row.js +212 -282
- package/dist/components/collection-item-row.js.map +1 -1
- package/dist/components/collection-row.js +139 -159
- package/dist/components/collection-row.js.map +1 -1
- package/dist/components/collections-panel.js +408 -496
- package/dist/components/collections-panel.js.map +1 -1
- package/dist/components/conflict-dialog.js +148 -164
- package/dist/components/conflict-dialog.js.map +1 -1
- package/dist/components/export-dialog.js +52 -52
- package/dist/components/export-dialog.js.map +1 -1
- package/dist/components/import-dialog.js +100 -112
- package/dist/components/import-dialog.js.map +1 -1
- package/dist/components/save-dialog.js +116 -124
- package/dist/components/save-dialog.js.map +1 -1
- package/dist/components/session-actions.js +23 -31
- package/dist/components/session-actions.js.map +1 -1
- package/dist/icons/check.js +18 -9
- package/dist/icons/check.js.map +1 -1
- package/dist/icons/collections.js +16 -9
- package/dist/icons/collections.js.map +1 -1
- package/dist/icons/download.js +16 -9
- package/dist/icons/download.js.map +1 -1
- package/dist/icons/upload.js +16 -9
- package/dist/icons/upload.js.map +1 -1
- package/dist/index.js +31 -41
- package/dist/index.js.map +1 -1
- package/dist/operation-method.js +24 -24
- package/dist/operation-method.js.map +1 -1
- package/dist/storage/local-storage.js +32 -37
- package/dist/storage/local-storage.js.map +1 -1
- package/dist/storage/tab-links.js +27 -30
- package/dist/storage/tab-links.js.map +1 -1
- package/dist/store.js +365 -402
- package/dist/store.js.map +1 -1
- package/dist/style.css +6 -27
- package/dist/types.js +9 -8
- package/dist/types.js.map +1 -1
- package/dist/utility/uuid.js +11 -9
- package/dist/utility/uuid.js.map +1 -1
- package/package.json +19 -15
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"export-dialog.js","sources":["../../src/components/export-dialog.tsx"],"sourcesContent":["import { FC } from 'react';\nimport { Button, Dialog } from '@graphiql/react';\nimport { collectionsStore } from '../store';\n\ntype ExportDialogProps = {\n open: boolean;\n onClose(): void;\n};\n\nexport const ExportDialog: FC<ExportDialogProps> = ({ open, onClose }) => {\n const exported = open\n ? collectionsStore.getState().actions.exportCollections()\n : '';\n\n const handleCopy = async () => {\n try {\n await navigator.clipboard.writeText(exported);\n } catch {\n // clipboard unavailable; leave the dialog open so the textarea stays\n // selectable as a fallback.\n return;\n }\n onClose();\n };\n\n const handleDownload = () => {\n const blob = new Blob([exported], { type: 'application/json' });\n const url = URL.createObjectURL(blob);\n const a = document.createElement('a');\n a.href = url;\n a.download = 'graphiql-collections.json';\n a.click();\n setTimeout(() => URL.revokeObjectURL(url), 0);\n onClose();\n };\n\n return (\n <Dialog open={open} onOpenChange={o => !o && onClose()}>\n <Dialog.Header>Export collections</Dialog.Header>\n <Dialog.Body>\n <div className=\"graphiql-import-export-section\">\n <textarea\n readOnly\n className=\"graphiql-import-export-textarea\"\n value={exported}\n rows={12}\n />\n <div className=\"graphiql-import-export-actions\">\n <Button\n type=\"button\"\n variant=\"primary\"\n onClick={() => void handleCopy()}\n >\n Copy JSON\n </Button>\n <Button type=\"button\" onClick={handleDownload}>\n Download JSON\n </Button>\n </div>\n </div>\n </Dialog.Body>\n </Dialog>\n );\n};\n"],"
|
|
1
|
+
{"version":3,"file":"export-dialog.js","names":[],"sources":["../../src/components/export-dialog.tsx"],"sourcesContent":["import { FC } from 'react';\nimport { Button, Dialog } from '@graphiql/react';\nimport { collectionsStore } from '../store';\n\ntype ExportDialogProps = {\n open: boolean;\n onClose(): void;\n};\n\nexport const ExportDialog: FC<ExportDialogProps> = ({ open, onClose }) => {\n const exported = open\n ? collectionsStore.getState().actions.exportCollections()\n : '';\n\n const handleCopy = async () => {\n try {\n await navigator.clipboard.writeText(exported);\n } catch {\n // clipboard unavailable; leave the dialog open so the textarea stays\n // selectable as a fallback.\n return;\n }\n onClose();\n };\n\n const handleDownload = () => {\n const blob = new Blob([exported], { type: 'application/json' });\n const url = URL.createObjectURL(blob);\n const a = document.createElement('a');\n a.href = url;\n a.download = 'graphiql-collections.json';\n a.click();\n setTimeout(() => URL.revokeObjectURL(url), 0);\n onClose();\n };\n\n return (\n <Dialog open={open} onOpenChange={o => !o && onClose()}>\n <Dialog.Header>Export collections</Dialog.Header>\n <Dialog.Body>\n <div className=\"graphiql-import-export-section\">\n <textarea\n readOnly\n className=\"graphiql-import-export-textarea\"\n value={exported}\n rows={12}\n />\n <div className=\"graphiql-import-export-actions\">\n <Button\n type=\"button\"\n variant=\"primary\"\n onClick={() => void handleCopy()}\n >\n Copy JSON\n </Button>\n <Button type=\"button\" onClick={handleDownload}>\n Download JSON\n </Button>\n </div>\n </div>\n </Dialog.Body>\n </Dialog>\n );\n};\n"],"mappings":";;;;AASA,IAAa,gBAAuC,EAAE,MAAM,cAAc;CACxE,MAAM,WAAW,OACb,iBAAiB,SAAS,CAAC,CAAC,QAAQ,kBAAkB,IACtD;CAEJ,MAAM,aAAa,YAAY;EAC7B,IAAI;GACF,MAAM,UAAU,UAAU,UAAU,QAAQ;EAC9C,QAAQ;GAGN;EACF;EACA,QAAQ;CACV;CAEA,MAAM,uBAAuB;EAC3B,MAAM,OAAO,IAAI,KAAK,CAAC,QAAQ,GAAG,EAAE,MAAM,mBAAmB,CAAC;EAC9D,MAAM,MAAM,IAAI,gBAAgB,IAAI;EACpC,MAAM,IAAI,SAAS,cAAc,GAAG;EACpC,EAAE,OAAO;EACT,EAAE,WAAW;EACb,EAAE,MAAM;EACR,iBAAiB,IAAI,gBAAgB,GAAG,GAAG,CAAC;EAC5C,QAAQ;CACV;CAEA,OACE,qBAAC,QAAD;EAAc;EAAM,eAAc,MAAK,CAAC,KAAK,QAAQ;EAArD,UAAA,CACE,oBAAC,OAAO,QAAR,EAAA,UAAe,qBAAiC,CAAA,GAChD,oBAAC,OAAO,MAAR,EAAA,UACE,qBAAC,OAAD;GAAK,WAAU;GAAf,UAAA,CACE,oBAAC,YAAD;IACE,UAAA;IACA,WAAU;IACV,OAAO;IACP,MAAM;GACP,CAAA,GACD,qBAAC,OAAD;IAAK,WAAU;IAAf,UAAA,CACE,oBAAC,QAAD;KACE,MAAK;KACL,SAAQ;KACR,eAAe,KAAK,WAAW;KAChC,UAAA;IAEO,CAAA,GACR,oBAAC,QAAD;KAAQ,MAAK;KAAS,SAAS;KAAgB,UAAA;IAEvC,CAAA,CACL;GACF,CAAA,CAAA;EACM,CAAA,EAAA,CAAA,CACP;;AAEZ"}
|
|
@@ -1,114 +1,102 @@
|
|
|
1
|
-
import { jsxs, jsx } from "react/jsx-runtime";
|
|
2
|
-
import { useState, useRef } from "react";
|
|
3
|
-
import { Dialog, Button } from "@graphiql/react";
|
|
4
1
|
import { collectionsStore } from "../store.js";
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
}
|
|
102
|
-
),
|
|
103
|
-
"Replace (remove all existing collections)"
|
|
104
|
-
] })
|
|
105
|
-
] }),
|
|
106
|
-
importError && /* @__PURE__ */ jsx("p", { className: "graphiql-import-export-error", children: importError }),
|
|
107
|
-
/* @__PURE__ */ jsx(Button, { type: "button", variant: "primary", onClick: handleImport, children: "Import" })
|
|
108
|
-
] }) })
|
|
109
|
-
] });
|
|
2
|
+
import { useRef, useState } from "react";
|
|
3
|
+
import { Button, Dialog } from "@graphiql/react";
|
|
4
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
5
|
+
//#region src/components/import-dialog.tsx
|
|
6
|
+
var ImportDialog = ({ open, onClose, onImport, allowReplace = true }) => {
|
|
7
|
+
const [importMode, setImportMode] = useState("merge");
|
|
8
|
+
const [importError, setImportError] = useState(null);
|
|
9
|
+
const [pastedText, setPastedText] = useState("");
|
|
10
|
+
const fileInputRef = useRef(null);
|
|
11
|
+
const validateAndImport = (text) => {
|
|
12
|
+
try {
|
|
13
|
+
JSON.parse(text);
|
|
14
|
+
} catch {
|
|
15
|
+
setImportError("Invalid JSON. Please paste or select a valid collections export.");
|
|
16
|
+
return;
|
|
17
|
+
}
|
|
18
|
+
if (!collectionsStore.getState().actions.analyzeImport(text).ok) {
|
|
19
|
+
setImportError("This isn’t a valid collections export.");
|
|
20
|
+
return;
|
|
21
|
+
}
|
|
22
|
+
onImport(text, allowReplace ? importMode : "merge");
|
|
23
|
+
onClose();
|
|
24
|
+
};
|
|
25
|
+
const handleImport = () => {
|
|
26
|
+
const pasted = pastedText.trim();
|
|
27
|
+
if (pasted) {
|
|
28
|
+
validateAndImport(pasted);
|
|
29
|
+
return;
|
|
30
|
+
}
|
|
31
|
+
const file = fileInputRef.current?.files?.[0];
|
|
32
|
+
if (!file) {
|
|
33
|
+
setImportError("Paste a collections export or choose a file.");
|
|
34
|
+
return;
|
|
35
|
+
}
|
|
36
|
+
const reader = new FileReader();
|
|
37
|
+
reader.onload = (e) => {
|
|
38
|
+
validateAndImport(e.target?.result);
|
|
39
|
+
};
|
|
40
|
+
reader.readAsText(file);
|
|
41
|
+
};
|
|
42
|
+
return /* @__PURE__ */ jsxs(Dialog, {
|
|
43
|
+
open,
|
|
44
|
+
onOpenChange: (o) => !o && onClose(),
|
|
45
|
+
children: [/* @__PURE__ */ jsx(Dialog.Header, { children: "Import collections" }), /* @__PURE__ */ jsx(Dialog.Body, { children: /* @__PURE__ */ jsxs("div", {
|
|
46
|
+
className: "graphiql-import-export-section",
|
|
47
|
+
children: [
|
|
48
|
+
/* @__PURE__ */ jsx("textarea", {
|
|
49
|
+
className: "graphiql-import-export-textarea",
|
|
50
|
+
rows: 6,
|
|
51
|
+
"aria-label": "Paste collections export JSON",
|
|
52
|
+
placeholder: "Paste a collections export (JSON)…",
|
|
53
|
+
value: pastedText,
|
|
54
|
+
onChange: (e) => {
|
|
55
|
+
setPastedText(e.target.value);
|
|
56
|
+
setImportError(null);
|
|
57
|
+
}
|
|
58
|
+
}),
|
|
59
|
+
/* @__PURE__ */ jsx("input", {
|
|
60
|
+
ref: fileInputRef,
|
|
61
|
+
type: "file",
|
|
62
|
+
accept: ".json,application/json",
|
|
63
|
+
onChange: () => setImportError(null)
|
|
64
|
+
}),
|
|
65
|
+
/* @__PURE__ */ jsxs("fieldset", {
|
|
66
|
+
className: "graphiql-import-export-mode",
|
|
67
|
+
children: [
|
|
68
|
+
/* @__PURE__ */ jsx("legend", { children: "Import mode" }),
|
|
69
|
+
/* @__PURE__ */ jsxs("label", { children: [/* @__PURE__ */ jsx("input", {
|
|
70
|
+
type: "radio",
|
|
71
|
+
name: "import-mode",
|
|
72
|
+
value: "merge",
|
|
73
|
+
checked: !allowReplace || importMode === "merge",
|
|
74
|
+
onChange: () => setImportMode("merge")
|
|
75
|
+
}), "Merge (add new, update changed in place)"] }),
|
|
76
|
+
allowReplace && /* @__PURE__ */ jsxs("label", { children: [/* @__PURE__ */ jsx("input", {
|
|
77
|
+
type: "radio",
|
|
78
|
+
name: "import-mode",
|
|
79
|
+
value: "replace",
|
|
80
|
+
checked: importMode === "replace",
|
|
81
|
+
onChange: () => setImportMode("replace")
|
|
82
|
+
}), "Replace (remove all existing collections)"] })
|
|
83
|
+
]
|
|
84
|
+
}),
|
|
85
|
+
importError && /* @__PURE__ */ jsx("p", {
|
|
86
|
+
className: "graphiql-import-export-error",
|
|
87
|
+
children: importError
|
|
88
|
+
}),
|
|
89
|
+
/* @__PURE__ */ jsx(Button, {
|
|
90
|
+
type: "button",
|
|
91
|
+
variant: "primary",
|
|
92
|
+
onClick: handleImport,
|
|
93
|
+
children: "Import"
|
|
94
|
+
})
|
|
95
|
+
]
|
|
96
|
+
}) })]
|
|
97
|
+
});
|
|
110
98
|
};
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
//# sourceMappingURL=import-dialog.js.map
|
|
99
|
+
//#endregion
|
|
100
|
+
export { ImportDialog };
|
|
101
|
+
|
|
102
|
+
//# sourceMappingURL=import-dialog.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"import-dialog.js","sources":["../../src/components/import-dialog.tsx"],"sourcesContent":["import { FC, useRef, useState } from 'react';\nimport { Button, Dialog } from '@graphiql/react';\nimport { collectionsStore } from '../store';\n\ntype ImportDialogProps = {\n open: boolean;\n onClose(): void;\n onImport(text: string, mode: 'merge' | 'replace'): void;\n /** Hide the \"Replace\" import option (force merge) when false. */\n allowReplace?: boolean;\n};\n\nexport const ImportDialog: FC<ImportDialogProps> = ({\n open,\n onClose,\n onImport,\n allowReplace = true,\n}) => {\n const [importMode, setImportMode] = useState<'merge' | 'replace'>('merge');\n const [importError, setImportError] = useState<string | null>(null);\n const [pastedText, setPastedText] = useState('');\n const fileInputRef = useRef<HTMLInputElement>(null);\n\n const validateAndImport = (text: string) => {\n try {\n JSON.parse(text);\n } catch {\n setImportError(\n 'Invalid JSON. Please paste or select a valid collections export.',\n );\n return;\n }\n const analysis = collectionsStore.getState().actions.analyzeImport(text);\n if (!analysis.ok) {\n setImportError('This isn’t a valid collections export.');\n return;\n }\n onImport(text, allowReplace ? importMode : 'merge');\n onClose();\n };\n\n const handleImport = () => {\n const pasted = pastedText.trim();\n if (pasted) {\n validateAndImport(pasted);\n return;\n }\n const file = fileInputRef.current?.files?.[0];\n if (!file) {\n setImportError('Paste a collections export or choose a file.');\n return;\n }\n const reader = new FileReader();\n reader.onload = e => {\n validateAndImport(e.target?.result as string);\n };\n reader.readAsText(file);\n };\n\n return (\n <Dialog open={open} onOpenChange={o => !o && onClose()}>\n <Dialog.Header>Import collections</Dialog.Header>\n <Dialog.Body>\n <div className=\"graphiql-import-export-section\">\n <textarea\n className=\"graphiql-import-export-textarea\"\n rows={6}\n aria-label=\"Paste collections export JSON\"\n placeholder=\"Paste a collections export (JSON)…\"\n value={pastedText}\n onChange={e => {\n setPastedText(e.target.value);\n setImportError(null);\n }}\n />\n <input\n ref={fileInputRef}\n type=\"file\"\n accept=\".json,application/json\"\n onChange={() => setImportError(null)}\n />\n <fieldset className=\"graphiql-import-export-mode\">\n <legend>Import mode</legend>\n <label>\n <input\n type=\"radio\"\n name=\"import-mode\"\n value=\"merge\"\n checked={!allowReplace || importMode === 'merge'}\n onChange={() => setImportMode('merge')}\n />\n Merge (add new, update changed in place)\n </label>\n {allowReplace && (\n <label>\n <input\n type=\"radio\"\n name=\"import-mode\"\n value=\"replace\"\n checked={importMode === 'replace'}\n onChange={() => setImportMode('replace')}\n />\n Replace (remove all existing collections)\n </label>\n )}\n </fieldset>\n {importError && (\n <p className=\"graphiql-import-export-error\">{importError}</p>\n )}\n <Button type=\"button\" variant=\"primary\" onClick={handleImport}>\n Import\n </Button>\n </div>\n </Dialog.Body>\n </Dialog>\n );\n};\n"],"
|
|
1
|
+
{"version":3,"file":"import-dialog.js","names":[],"sources":["../../src/components/import-dialog.tsx"],"sourcesContent":["import { FC, useRef, useState } from 'react';\nimport { Button, Dialog } from '@graphiql/react';\nimport { collectionsStore } from '../store';\n\ntype ImportDialogProps = {\n open: boolean;\n onClose(): void;\n onImport(text: string, mode: 'merge' | 'replace'): void;\n /** Hide the \"Replace\" import option (force merge) when false. */\n allowReplace?: boolean;\n};\n\nexport const ImportDialog: FC<ImportDialogProps> = ({\n open,\n onClose,\n onImport,\n allowReplace = true,\n}) => {\n const [importMode, setImportMode] = useState<'merge' | 'replace'>('merge');\n const [importError, setImportError] = useState<string | null>(null);\n const [pastedText, setPastedText] = useState('');\n const fileInputRef = useRef<HTMLInputElement>(null);\n\n const validateAndImport = (text: string) => {\n try {\n JSON.parse(text);\n } catch {\n setImportError(\n 'Invalid JSON. Please paste or select a valid collections export.',\n );\n return;\n }\n const analysis = collectionsStore.getState().actions.analyzeImport(text);\n if (!analysis.ok) {\n setImportError('This isn’t a valid collections export.');\n return;\n }\n onImport(text, allowReplace ? importMode : 'merge');\n onClose();\n };\n\n const handleImport = () => {\n const pasted = pastedText.trim();\n if (pasted) {\n validateAndImport(pasted);\n return;\n }\n const file = fileInputRef.current?.files?.[0];\n if (!file) {\n setImportError('Paste a collections export or choose a file.');\n return;\n }\n const reader = new FileReader();\n reader.onload = e => {\n validateAndImport(e.target?.result as string);\n };\n reader.readAsText(file);\n };\n\n return (\n <Dialog open={open} onOpenChange={o => !o && onClose()}>\n <Dialog.Header>Import collections</Dialog.Header>\n <Dialog.Body>\n <div className=\"graphiql-import-export-section\">\n <textarea\n className=\"graphiql-import-export-textarea\"\n rows={6}\n aria-label=\"Paste collections export JSON\"\n placeholder=\"Paste a collections export (JSON)…\"\n value={pastedText}\n onChange={e => {\n setPastedText(e.target.value);\n setImportError(null);\n }}\n />\n <input\n ref={fileInputRef}\n type=\"file\"\n accept=\".json,application/json\"\n onChange={() => setImportError(null)}\n />\n <fieldset className=\"graphiql-import-export-mode\">\n <legend>Import mode</legend>\n <label>\n <input\n type=\"radio\"\n name=\"import-mode\"\n value=\"merge\"\n checked={!allowReplace || importMode === 'merge'}\n onChange={() => setImportMode('merge')}\n />\n Merge (add new, update changed in place)\n </label>\n {allowReplace && (\n <label>\n <input\n type=\"radio\"\n name=\"import-mode\"\n value=\"replace\"\n checked={importMode === 'replace'}\n onChange={() => setImportMode('replace')}\n />\n Replace (remove all existing collections)\n </label>\n )}\n </fieldset>\n {importError && (\n <p className=\"graphiql-import-export-error\">{importError}</p>\n )}\n <Button type=\"button\" variant=\"primary\" onClick={handleImport}>\n Import\n </Button>\n </div>\n </Dialog.Body>\n </Dialog>\n );\n};\n"],"mappings":";;;;;AAYA,IAAa,gBAAuC,EAClD,MACA,SACA,UACA,eAAe,WACX;CACJ,MAAM,CAAC,YAAY,iBAAiB,SAA8B,OAAO;CACzE,MAAM,CAAC,aAAa,kBAAkB,SAAwB,IAAI;CAClE,MAAM,CAAC,YAAY,iBAAiB,SAAS,EAAE;CAC/C,MAAM,eAAe,OAAyB,IAAI;CAElD,MAAM,qBAAqB,SAAiB;EAC1C,IAAI;GACF,KAAK,MAAM,IAAI;EACjB,QAAQ;GACN,eACE,kEACF;GACA;EACF;EAEA,IAAI,CADa,iBAAiB,SAAS,CAAC,CAAC,QAAQ,cAAc,IAC9D,CAAA,CAAS,IAAI;GAChB,eAAe,wCAAwC;GACvD;EACF;EACA,SAAS,MAAM,eAAe,aAAa,OAAO;EAClD,QAAQ;CACV;CAEA,MAAM,qBAAqB;EACzB,MAAM,SAAS,WAAW,KAAK;EAC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AQ,MAAK;KAAS,SAAQ;KAAU,SAAS;KAAc,UAAA;IAEvD,CAAA;GACL;EACM,CAAA,EAAA,CAAA,CACP;;AAEZ"}
|
|
@@ -1,125 +1,117 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
/* @__PURE__ */ jsxs(Dialog.Footer, { children: [
|
|
114
|
-
/* @__PURE__ */ jsx(Button, { type: "button", onClick: () => actions.closeSaveDialog(), children: "Cancel" }),
|
|
115
|
-
/* @__PURE__ */ jsx(Button, { type: "submit", variant: "primary", children: "Save" })
|
|
116
|
-
] })
|
|
117
|
-
]
|
|
118
|
-
}
|
|
119
|
-
)
|
|
120
|
-
] });
|
|
1
|
+
import { collectionsStore, useCollectionsStore } from "../store.js";
|
|
2
|
+
import { useEffect, useState } from "react";
|
|
3
|
+
import { Button, Dialog, useGraphiQLActions } from "@graphiql/react";
|
|
4
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
5
|
+
//#region src/components/save-dialog.tsx
|
|
6
|
+
var NEW_COLLECTION = "__new__";
|
|
7
|
+
/**
|
|
8
|
+
* The single "Save to collection" dialog. Its open state and the operation
|
|
9
|
+
* being saved live in the collections store, so ⌘S and the save button can open
|
|
10
|
+
* it imperatively via `requestSave`.
|
|
11
|
+
*/
|
|
12
|
+
var SaveDialog = () => {
|
|
13
|
+
const collections = useCollectionsStore((s) => s.collections);
|
|
14
|
+
const actions = useCollectionsStore((s) => s.actions);
|
|
15
|
+
const { open, name: initialName } = useCollectionsStore((s) => s.saveDialog);
|
|
16
|
+
const { markTabSaved } = useGraphiQLActions();
|
|
17
|
+
const [name, setName] = useState(initialName);
|
|
18
|
+
const [description, setDescription] = useState("");
|
|
19
|
+
const [selectedCollectionId, setSelectedCollectionId] = useState(NEW_COLLECTION);
|
|
20
|
+
const [newCollectionName, setNewCollectionName] = useState("New Collection");
|
|
21
|
+
useEffect(() => {
|
|
22
|
+
if (open) {
|
|
23
|
+
const { collections: current } = collectionsStore.getState();
|
|
24
|
+
setName(initialName);
|
|
25
|
+
setDescription("");
|
|
26
|
+
setSelectedCollectionId(current[0]?.id ?? NEW_COLLECTION);
|
|
27
|
+
setNewCollectionName("New Collection");
|
|
28
|
+
}
|
|
29
|
+
}, [open, initialName]);
|
|
30
|
+
const handleSave = () => {
|
|
31
|
+
const { saveDialog, actions: a } = collectionsStore.getState();
|
|
32
|
+
let collectionId = selectedCollectionId;
|
|
33
|
+
if (selectedCollectionId === NEW_COLLECTION) collectionId = a.createCollection(newCollectionName || "New Collection").id;
|
|
34
|
+
const item = a.addItem(collectionId, {
|
|
35
|
+
name: name || "Unnamed operation",
|
|
36
|
+
description: description || void 0,
|
|
37
|
+
query: saveDialog.query,
|
|
38
|
+
variables: saveDialog.variables,
|
|
39
|
+
headers: saveDialog.headers
|
|
40
|
+
});
|
|
41
|
+
if (saveDialog.tabId) {
|
|
42
|
+
a.linkTab(saveDialog.tabId, collectionId, item.id);
|
|
43
|
+
markTabSaved(saveDialog.tabId);
|
|
44
|
+
}
|
|
45
|
+
a.closeSaveDialog();
|
|
46
|
+
};
|
|
47
|
+
return /* @__PURE__ */ jsxs(Dialog, {
|
|
48
|
+
open,
|
|
49
|
+
onOpenChange: (o) => !o && actions.closeSaveDialog(),
|
|
50
|
+
children: [/* @__PURE__ */ jsx(Dialog.Header, { children: "Save to collection" }), /* @__PURE__ */ jsxs("form", {
|
|
51
|
+
onSubmit: (e) => {
|
|
52
|
+
e.preventDefault();
|
|
53
|
+
handleSave();
|
|
54
|
+
},
|
|
55
|
+
children: [/* @__PURE__ */ jsxs(Dialog.Body, { children: [
|
|
56
|
+
/* @__PURE__ */ jsxs("label", {
|
|
57
|
+
className: "graphiql-save-dialog-field",
|
|
58
|
+
children: [/* @__PURE__ */ jsx("span", { children: "Operation name" }), /* @__PURE__ */ jsx("input", {
|
|
59
|
+
type: "text",
|
|
60
|
+
value: name,
|
|
61
|
+
onChange: (e) => setName(e.target.value),
|
|
62
|
+
placeholder: "Unnamed operation",
|
|
63
|
+
className: "graphiql-save-dialog-input",
|
|
64
|
+
autoFocus: true
|
|
65
|
+
})]
|
|
66
|
+
}),
|
|
67
|
+
/* @__PURE__ */ jsxs("label", {
|
|
68
|
+
className: "graphiql-save-dialog-field",
|
|
69
|
+
children: [/* @__PURE__ */ jsx("span", { children: "Description" }), /* @__PURE__ */ jsx("input", {
|
|
70
|
+
type: "text",
|
|
71
|
+
value: description,
|
|
72
|
+
onChange: (e) => setDescription(e.target.value),
|
|
73
|
+
placeholder: "Description (optional)",
|
|
74
|
+
className: "graphiql-save-dialog-input"
|
|
75
|
+
})]
|
|
76
|
+
}),
|
|
77
|
+
/* @__PURE__ */ jsxs("label", {
|
|
78
|
+
className: "graphiql-save-dialog-field",
|
|
79
|
+
children: [/* @__PURE__ */ jsx("span", { children: "Collection" }), /* @__PURE__ */ jsxs("select", {
|
|
80
|
+
value: selectedCollectionId,
|
|
81
|
+
onChange: (e) => setSelectedCollectionId(e.target.value),
|
|
82
|
+
className: "graphiql-save-dialog-select",
|
|
83
|
+
children: [/* @__PURE__ */ jsx("option", {
|
|
84
|
+
value: NEW_COLLECTION,
|
|
85
|
+
children: "+ New collection"
|
|
86
|
+
}), collections.map((c) => /* @__PURE__ */ jsx("option", {
|
|
87
|
+
value: c.id,
|
|
88
|
+
children: c.name
|
|
89
|
+
}, c.id))]
|
|
90
|
+
})]
|
|
91
|
+
}),
|
|
92
|
+
selectedCollectionId === NEW_COLLECTION && /* @__PURE__ */ jsxs("label", {
|
|
93
|
+
className: "graphiql-save-dialog-field",
|
|
94
|
+
children: [/* @__PURE__ */ jsx("span", { children: "Collection name" }), /* @__PURE__ */ jsx("input", {
|
|
95
|
+
type: "text",
|
|
96
|
+
value: newCollectionName,
|
|
97
|
+
onChange: (e) => setNewCollectionName(e.target.value),
|
|
98
|
+
placeholder: "Collection name",
|
|
99
|
+
className: "graphiql-save-dialog-input"
|
|
100
|
+
})]
|
|
101
|
+
})
|
|
102
|
+
] }), /* @__PURE__ */ jsxs(Dialog.Footer, { children: [/* @__PURE__ */ jsx(Button, {
|
|
103
|
+
type: "button",
|
|
104
|
+
onClick: () => actions.closeSaveDialog(),
|
|
105
|
+
children: "Cancel"
|
|
106
|
+
}), /* @__PURE__ */ jsx(Button, {
|
|
107
|
+
type: "submit",
|
|
108
|
+
variant: "primary",
|
|
109
|
+
children: "Save"
|
|
110
|
+
})] })]
|
|
111
|
+
})]
|
|
112
|
+
});
|
|
121
113
|
};
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
//# sourceMappingURL=save-dialog.js.map
|
|
114
|
+
//#endregion
|
|
115
|
+
export { SaveDialog };
|
|
116
|
+
|
|
117
|
+
//# sourceMappingURL=save-dialog.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"save-dialog.js","sources":["../../src/components/save-dialog.tsx"],"sourcesContent":["import { FC, useEffect, useState } from 'react';\nimport { Button, Dialog, useGraphiQLActions } from '@graphiql/react';\nimport { useCollectionsStore, collectionsStore } from '../store';\n\nconst NEW_COLLECTION = '__new__';\n\n/**\n * The single \"Save to collection\" dialog. Its open state and the operation\n * being saved live in the collections store, so ⌘S and the save button can open\n * it imperatively via `requestSave`.\n */\nexport const SaveDialog: FC = () => {\n const collections = useCollectionsStore(s => s.collections);\n const actions = useCollectionsStore(s => s.actions);\n const { open, name: initialName } = useCollectionsStore(s => s.saveDialog);\n const { markTabSaved } = useGraphiQLActions();\n\n const [name, setName] = useState(initialName);\n const [description, setDescription] = useState('');\n const [selectedCollectionId, setSelectedCollectionId] =\n useState<string>(NEW_COLLECTION);\n const [newCollectionName, setNewCollectionName] = useState('New Collection');\n\n // Reset the form each time the dialog opens with a fresh operation.\n useEffect(() => {\n if (open) {\n const { collections: current } = collectionsStore.getState();\n setName(initialName);\n setDescription('');\n setSelectedCollectionId(current[0]?.id ?? NEW_COLLECTION);\n setNewCollectionName('New Collection');\n }\n }, [open, initialName]);\n\n const handleSave = () => {\n const { saveDialog, actions: a } = collectionsStore.getState();\n let collectionId = selectedCollectionId;\n if (selectedCollectionId === NEW_COLLECTION) {\n collectionId = a.createCollection(\n newCollectionName || 'New Collection',\n ).id;\n }\n const item = a.addItem(collectionId, {\n name: name || 'Unnamed operation',\n description: description || undefined,\n query: saveDialog.query,\n variables: saveDialog.variables,\n headers: saveDialog.headers,\n });\n if (saveDialog.tabId) {\n a.linkTab(saveDialog.tabId, collectionId, item.id);\n markTabSaved(saveDialog.tabId);\n }\n a.closeSaveDialog();\n };\n\n return (\n <Dialog open={open} onOpenChange={o => !o && actions.closeSaveDialog()}>\n <Dialog.Header>Save to collection</Dialog.Header>\n <form\n onSubmit={e => {\n e.preventDefault();\n handleSave();\n }}\n >\n <Dialog.Body>\n <label className=\"graphiql-save-dialog-field\">\n <span>Operation name</span>\n <input\n type=\"text\"\n value={name}\n onChange={e => setName(e.target.value)}\n placeholder=\"Unnamed operation\"\n className=\"graphiql-save-dialog-input\"\n autoFocus\n />\n </label>\n <label className=\"graphiql-save-dialog-field\">\n <span>Description</span>\n <input\n type=\"text\"\n value={description}\n onChange={e => setDescription(e.target.value)}\n placeholder=\"Description (optional)\"\n className=\"graphiql-save-dialog-input\"\n />\n </label>\n <label className=\"graphiql-save-dialog-field\">\n <span>Collection</span>\n <select\n value={selectedCollectionId}\n onChange={e => setSelectedCollectionId(e.target.value)}\n className=\"graphiql-save-dialog-select\"\n >\n <option value={NEW_COLLECTION}>+ New collection</option>\n {collections.map(c => (\n <option key={c.id} value={c.id}>\n {c.name}\n </option>\n ))}\n </select>\n </label>\n {selectedCollectionId === NEW_COLLECTION && (\n <label className=\"graphiql-save-dialog-field\">\n <span>Collection name</span>\n <input\n type=\"text\"\n value={newCollectionName}\n onChange={e => setNewCollectionName(e.target.value)}\n placeholder=\"Collection name\"\n className=\"graphiql-save-dialog-input\"\n />\n </label>\n )}\n </Dialog.Body>\n <Dialog.Footer>\n <Button type=\"button\" onClick={() => actions.closeSaveDialog()}>\n Cancel\n </Button>\n <Button type=\"submit\" variant=\"primary\">\n Save\n </Button>\n </Dialog.Footer>\n </form>\n </Dialog>\n );\n};\n"],"
|
|
1
|
+
{"version":3,"file":"save-dialog.js","names":[],"sources":["../../src/components/save-dialog.tsx"],"sourcesContent":["import { FC, useEffect, useState } from 'react';\nimport { Button, Dialog, useGraphiQLActions } from '@graphiql/react';\nimport { useCollectionsStore, collectionsStore } from '../store';\n\nconst NEW_COLLECTION = '__new__';\n\n/**\n * The single \"Save to collection\" dialog. Its open state and the operation\n * being saved live in the collections store, so ⌘S and the save button can open\n * it imperatively via `requestSave`.\n */\nexport const SaveDialog: FC = () => {\n const collections = useCollectionsStore(s => s.collections);\n const actions = useCollectionsStore(s => s.actions);\n const { open, name: initialName } = useCollectionsStore(s => s.saveDialog);\n const { markTabSaved } = useGraphiQLActions();\n\n const [name, setName] = useState(initialName);\n const [description, setDescription] = useState('');\n const [selectedCollectionId, setSelectedCollectionId] =\n useState<string>(NEW_COLLECTION);\n const [newCollectionName, setNewCollectionName] = useState('New Collection');\n\n // Reset the form each time the dialog opens with a fresh operation.\n useEffect(() => {\n if (open) {\n const { collections: current } = collectionsStore.getState();\n setName(initialName);\n setDescription('');\n setSelectedCollectionId(current[0]?.id ?? NEW_COLLECTION);\n setNewCollectionName('New Collection');\n }\n }, [open, initialName]);\n\n const handleSave = () => {\n const { saveDialog, actions: a } = collectionsStore.getState();\n let collectionId = selectedCollectionId;\n if (selectedCollectionId === NEW_COLLECTION) {\n collectionId = a.createCollection(\n newCollectionName || 'New Collection',\n ).id;\n }\n const item = a.addItem(collectionId, {\n name: name || 'Unnamed operation',\n description: description || undefined,\n query: saveDialog.query,\n variables: saveDialog.variables,\n headers: saveDialog.headers,\n });\n if (saveDialog.tabId) {\n a.linkTab(saveDialog.tabId, collectionId, item.id);\n markTabSaved(saveDialog.tabId);\n }\n a.closeSaveDialog();\n };\n\n return (\n <Dialog open={open} onOpenChange={o => !o && actions.closeSaveDialog()}>\n <Dialog.Header>Save to collection</Dialog.Header>\n <form\n onSubmit={e => {\n e.preventDefault();\n handleSave();\n }}\n >\n <Dialog.Body>\n <label className=\"graphiql-save-dialog-field\">\n <span>Operation name</span>\n <input\n type=\"text\"\n value={name}\n onChange={e => setName(e.target.value)}\n placeholder=\"Unnamed operation\"\n className=\"graphiql-save-dialog-input\"\n autoFocus\n />\n </label>\n <label className=\"graphiql-save-dialog-field\">\n <span>Description</span>\n <input\n type=\"text\"\n value={description}\n onChange={e => setDescription(e.target.value)}\n placeholder=\"Description (optional)\"\n className=\"graphiql-save-dialog-input\"\n />\n </label>\n <label className=\"graphiql-save-dialog-field\">\n <span>Collection</span>\n <select\n value={selectedCollectionId}\n onChange={e => setSelectedCollectionId(e.target.value)}\n className=\"graphiql-save-dialog-select\"\n >\n <option value={NEW_COLLECTION}>+ New collection</option>\n {collections.map(c => (\n <option key={c.id} value={c.id}>\n {c.name}\n </option>\n ))}\n </select>\n </label>\n {selectedCollectionId === NEW_COLLECTION && (\n <label className=\"graphiql-save-dialog-field\">\n <span>Collection name</span>\n <input\n type=\"text\"\n value={newCollectionName}\n onChange={e => setNewCollectionName(e.target.value)}\n placeholder=\"Collection name\"\n className=\"graphiql-save-dialog-input\"\n />\n </label>\n )}\n </Dialog.Body>\n <Dialog.Footer>\n <Button type=\"button\" onClick={() => actions.closeSaveDialog()}>\n Cancel\n </Button>\n <Button type=\"submit\" variant=\"primary\">\n Save\n </Button>\n </Dialog.Footer>\n </form>\n </Dialog>\n );\n};\n"],"mappings":";;;;;AAIA,IAAM,iBAAiB;;;;;;AAOvB,IAAa,mBAAuB;CAClC,MAAM,cAAc,qBAAoB,MAAK,EAAE,WAAW;CAC1D,MAAM,UAAU,qBAAoB,MAAK,EAAE,OAAO;CAClD,MAAM,EAAE,MAAM,MAAM,gBAAgB,qBAAoB,MAAK,EAAE,UAAU;CACzE,MAAM,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