@graphql-yoga/render-graphiql 5.18.0 → 5.18.1-alpha-20260116132831-dc9fc0ad2f1ad6ee99bc438c173cf8496ae505a7

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/esm/index.js DELETED
@@ -1,41 +0,0 @@
1
- import { css, editorWorkerService, favicon, graphqlWorker, js, jsonWorker } from './graphiql.js';
2
- export const renderGraphiQL = (opts) => /* HTML */ `
3
- <!doctype html>
4
- <html lang="en">
5
- <head>
6
- <meta charset="utf-8" />
7
- <title>${opts?.title || 'Yoga GraphiQL'}</title>
8
- <link rel="icon" href="${opts?.favicon || favicon}" />
9
- <style>
10
- ${css}
11
- </style>
12
- </head>
13
- <body id="body" class="no-focus-outline">
14
- <noscript>You need to enable JavaScript to run this app.</noscript>
15
- <div id="root"></div>
16
-
17
- <script>
18
- function prepareBlob(workerContent) {
19
- const blob = new Blob([workerContent], { type: 'application/javascript' });
20
- return URL.createObjectURL(blob);
21
- }
22
- const workers = {
23
- editorWorkerService: prepareBlob(${JSON.stringify(editorWorkerService)}),
24
- json: prepareBlob(${JSON.stringify(jsonWorker)}),
25
- graphql: prepareBlob(${JSON.stringify(graphqlWorker)}),
26
- };
27
- self['MonacoEnvironment'] = {
28
- globalAPI: false,
29
- getWorkerUrl: function (moduleId, label) {
30
- return workers[label];
31
- },
32
- };
33
- ${js};
34
- YogaGraphiQL.renderYogaGraphiQL(
35
- window.document.querySelector('#root'),
36
- ${JSON.stringify(opts ?? {})},
37
- );
38
- </script>
39
- </body>
40
- </html>
41
- `;
@@ -1,6 +0,0 @@
1
- export declare const js: string;
2
- export declare const css: string;
3
- export declare const favicon: string;
4
- export declare const editorWorkerService: string;
5
- export declare const jsonWorker: string;
6
- export declare const graphqlWorker: string;
@@ -1,6 +0,0 @@
1
- export declare const js: string;
2
- export declare const css: string;
3
- export declare const favicon: string;
4
- export declare const editorWorkerService: string;
5
- export declare const jsonWorker: string;
6
- export declare const graphqlWorker: string;
@@ -1,2 +0,0 @@
1
- import type { GraphiQLOptions } from 'graphql-yoga';
2
- export declare const renderGraphiQL: (opts?: GraphiQLOptions) => string;
@@ -1,2 +0,0 @@
1
- import type { GraphiQLOptions } from 'graphql-yoga';
2
- export declare const renderGraphiQL: (opts?: GraphiQLOptions) => string;