@operato/scene-graphql 9.0.0-beta.1 → 9.0.0-beta.16
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/graphql-client.d.ts +1 -1
- package/dist/graphql-client.js +16 -11
- package/dist/graphql-client.js.map +1 -1
- package/dist/graphql-query-and-mutation.js +19 -12
- package/dist/graphql-query-and-mutation.js.map +1 -1
- package/dist/graphql-subscription.js +14 -9
- package/dist/graphql-subscription.js.map +1 -1
- package/dist/index.d.ts +4 -4
- package/dist/index.js +3 -3
- package/dist/index.js.map +1 -1
- package/dist/templates/index.js +4 -4
- package/dist/templates/index.js.map +1 -1
- package/package.json +5 -4
- package/things-scene.config.js +1 -1
package/dist/graphql-client.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ApolloClient, NormalizedCacheObject } from '@apollo/client/core';
|
|
1
|
+
import { ApolloClient, NormalizedCacheObject } from '@apollo/client/core/index.js';
|
|
2
2
|
import { ComponentNature, Shape } from '@hatiolab/things-scene';
|
|
3
3
|
declare const GraphqlClient_base: (new (...args: any[]) => {
|
|
4
4
|
isDataSource(): boolean;
|
package/dist/graphql-client.js
CHANGED
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Copyright © HatioLab Inc. All rights reserved.
|
|
3
3
|
*/
|
|
4
|
-
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
4
|
+
var GraphqlClient_1;
|
|
5
|
+
import { __decorate } from "tslib";
|
|
6
|
+
import { ApolloClient, from, HttpLink, InMemoryCache } from '@apollo/client/core/index.js';
|
|
7
|
+
import { onError } from '@apollo/client/link/error/index.js';
|
|
8
|
+
import { DataSource, RectPath, Shape, sceneComponent } from '@hatiolab/things-scene';
|
|
7
9
|
const defaultOptions = {
|
|
8
10
|
watchQuery: {
|
|
9
11
|
fetchPolicy: 'no-cache',
|
|
@@ -79,13 +81,13 @@ const NATURE = {
|
|
|
79
81
|
],
|
|
80
82
|
help: 'scene/component/graphql'
|
|
81
83
|
};
|
|
82
|
-
|
|
84
|
+
let GraphqlClient = GraphqlClient_1 = class GraphqlClient extends DataSource(RectPath(Shape)) {
|
|
83
85
|
static get image() {
|
|
84
|
-
if (!
|
|
85
|
-
|
|
86
|
-
|
|
86
|
+
if (!GraphqlClient_1._image) {
|
|
87
|
+
GraphqlClient_1._image = new Image();
|
|
88
|
+
GraphqlClient_1._image.src = new URL('../icons/symbol-graphql-client.png', import.meta.url).href;
|
|
87
89
|
}
|
|
88
|
-
return
|
|
90
|
+
return GraphqlClient_1._image;
|
|
89
91
|
}
|
|
90
92
|
ready() {
|
|
91
93
|
super.ready();
|
|
@@ -130,7 +132,7 @@ export default class GraphqlClient extends DataSource(RectPath(Shape)) {
|
|
|
130
132
|
*/
|
|
131
133
|
var { left, top, width, height } = this.bounds;
|
|
132
134
|
context.beginPath();
|
|
133
|
-
this.drawImage(context,
|
|
135
|
+
this.drawImage(context, GraphqlClient_1.image, left, top, width, height);
|
|
134
136
|
}
|
|
135
137
|
onchangeData(data, before) {
|
|
136
138
|
super.onchangeData(data, before);
|
|
@@ -138,6 +140,9 @@ export default class GraphqlClient extends DataSource(RectPath(Shape)) {
|
|
|
138
140
|
get nature() {
|
|
139
141
|
return NATURE;
|
|
140
142
|
}
|
|
141
|
-
}
|
|
142
|
-
|
|
143
|
+
};
|
|
144
|
+
GraphqlClient = GraphqlClient_1 = __decorate([
|
|
145
|
+
sceneComponent('graphql-client')
|
|
146
|
+
], GraphqlClient);
|
|
147
|
+
export default GraphqlClient;
|
|
143
148
|
//# sourceMappingURL=graphql-client.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"graphql-client.js","sourceRoot":"","sources":["../src/graphql-client.ts"],"names":[],"mappings":"AAAA;;GAEG
|
|
1
|
+
{"version":3,"file":"graphql-client.js","sourceRoot":"","sources":["../src/graphql-client.ts"],"names":[],"mappings":"AAAA;;GAEG;;;AAEH,OAAO,E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EAAE,IAAI,EAAE,GAAG,EAAE,KAAK,EAAE,MAAM,EAAE,GAAG,IAAI,CAAC,MAAM,CAAA;QAE9C,OAAO,CAAC,SAAS,EAAE,CAAA;QACnB,IAAI,CAAC,SAAS,CAAC,OAAO,EAAE,eAAa,CAAC,KAAK,EAAE,IAAI,EAAE,GAAG,EAAE,KAAK,EAAE,MAAM,CAAC,CAAA;IACxE,CAAC;IAED,YAAY,CAAC,IAAS,EAAE,MAAW;QACjC,KAAK,CAAC,YAAY,CAAC,IAAI,EAAE,MAAM,CAAC,CAAA;IAClC,CAAC;IAED,IAAI,MAAM;QACR,OAAO,MAAM,CAAA;IACf,CAAC;CACF,CAAA;AA7EoB,aAAa;IADjC,cAAc,CAAC,gBAAgB,CAAC;GACZ,aAAa,CA6EjC;eA7EoB,aAAa","sourcesContent":["/*\n * Copyright © HatioLab Inc. All rights reserved.\n */\n\nimport {\n ApolloClient,\n DefaultOptions,\n from,\n HttpLink,\n HttpOptions,\n InMemoryCache,\n NormalizedCacheObject,\n ServerParseError\n} from '@apollo/client/core/index.js'\nimport { ErrorLink, onError } from '@apollo/client/link/error/index.js'\nimport { Component, ComponentNature, DataSource, RectPath, Shape, sceneComponent } from '@hatiolab/things-scene'\n\nconst defaultOptions: DefaultOptions = {\n watchQuery: {\n fetchPolicy: 'no-cache',\n errorPolicy: 'ignore'\n },\n query: {\n fetchPolicy: 'no-cache', //'network-only'\n errorPolicy: 'all'\n },\n mutate: {\n errorPolicy: 'all'\n }\n}\n\nconst ERROR_HANDLER: ErrorLink.ErrorHandler = ({ operation, graphQLErrors, networkError }) => {\n if (graphQLErrors) {\n document.dispatchEvent(\n new CustomEvent('notify', {\n detail: {\n level: 'error',\n message: graphQLErrors[0].message,\n ex: graphQLErrors\n }\n })\n )\n }\n\n if (networkError) {\n /* networkError가 ServerParseError 이거나 ServerError 인 경우에만 statusCode를 갖는다. */\n switch ((networkError as ServerParseError).statusCode) {\n case undefined /* in case this error is not a server side error */:\n document.dispatchEvent(\n new CustomEvent('notify', {\n detail: {\n level: 'error',\n message: networkError.message,\n ex: networkError\n }\n })\n )\n break\n\n case 401:\n /* 401 에러가 리턴되면, 인증이 필요하다는 메시지를 dispatch 한다. 이 auth 모듈 등에서 이 메시지를 받아서 signin 프로세스를 진행할 수 있다. */\n document.dispatchEvent(new CustomEvent('auth-required'))\n break\n\n case 403:\n /* 403 에러가 리턴되면, 도메인 정보가 필요하다는 메시지를 dispatch 한다. 이 auth 모듈 등에서 이 메시지를 받아서 domain-register 프로세스 등을 진행할 수 있다. */\n document.dispatchEvent(new CustomEvent('domain-required'))\n break\n\n default:\n var { name, response, statusCode, bodyText, message } = networkError as ServerParseError\n if (name == 'ServerParseError') {\n message = `[ ${statusCode || ''} : ${response.statusText} ] ${bodyText}`\n } else {\n /* in case this error is instanceof ServerError */\n message = `[ ${statusCode || ''} : ${response.statusText} ] ${message}`\n }\n\n document.dispatchEvent(\n new CustomEvent('notify', {\n detail: {\n level: 'error',\n message,\n ex: networkError\n }\n })\n )\n }\n }\n}\n\nconst NATURE: ComponentNature = {\n mutable: false,\n resizable: true,\n rotatable: true,\n properties: [\n {\n type: 'string',\n label: 'endpoint',\n name: 'endpoint'\n }\n ],\n help: 'scene/component/graphql'\n}\n\n@sceneComponent('graphql-client')\nexport default class GraphqlClient extends DataSource(RectPath(Shape)) {\n private static _image: HTMLImageElement\n private _client?: ApolloClient<NormalizedCacheObject>\n\n static get image() {\n if (!GraphqlClient._image) {\n GraphqlClient._image = new Image()\n GraphqlClient._image.src = new URL('../icons/symbol-graphql-client.png', import.meta.url).href\n }\n\n return GraphqlClient._image\n }\n\n ready() {\n super.ready()\n\n this.init()\n }\n\n init() {\n var { endpoint } = this.state\n\n if (!endpoint) {\n console.warn('endpoint not defined')\n return\n }\n\n var cache = new InMemoryCache()\n const httpOptions: HttpOptions = {\n uri: endpoint,\n credentials: 'include'\n }\n\n const client = new ApolloClient({\n defaultOptions,\n cache,\n link: from([onError(ERROR_HANDLER), new HttpLink(httpOptions)])\n })\n\n this._client = client\n }\n\n get client(): ApolloClient<NormalizedCacheObject> | undefined {\n return this._client\n }\n\n dispose() {\n super.dispose()\n\n try {\n if (this._client) {\n this._client.stop()\n }\n } catch (e) {\n console.error(e)\n }\n delete this._client\n }\n\n render(context: CanvasRenderingContext2D) {\n /*\n * TODO role이 publisher 인지 subscriber 인지에 따라서 구분할 수 있는 표시를 추가할 것.\n */\n\n var { left, top, width, height } = this.bounds\n\n context.beginPath()\n this.drawImage(context, GraphqlClient.image, left, top, width, height)\n }\n\n onchangeData(data: any, before: any) {\n super.onchangeData(data, before)\n }\n\n get nature() {\n return NATURE\n }\n}\n"]}
|
|
@@ -1,6 +1,8 @@
|
|
|
1
|
+
var Mutation_1;
|
|
2
|
+
import { __decorate } from "tslib";
|
|
1
3
|
import 'ses';
|
|
2
4
|
import gql from 'graphql-tag';
|
|
3
|
-
import { Component, DataSource, RectPath, Shape } from '@hatiolab/things-scene';
|
|
5
|
+
import { Component, DataSource, RectPath, Shape, sceneComponent } from '@hatiolab/things-scene';
|
|
4
6
|
import { buildArgs, client as localClient } from '@operato/graphql';
|
|
5
7
|
const NATURE = {
|
|
6
8
|
mutable: false,
|
|
@@ -36,7 +38,7 @@ const NATURE = {
|
|
|
36
38
|
'value-property': 'value',
|
|
37
39
|
help: 'scene/component/graphql'
|
|
38
40
|
};
|
|
39
|
-
class GraphQLQuery extends DataSource(RectPath(Shape)) {
|
|
41
|
+
let GraphQLQuery = class GraphQLQuery extends DataSource(RectPath(Shape)) {
|
|
40
42
|
constructor() {
|
|
41
43
|
super(...arguments);
|
|
42
44
|
this._isStarted = false;
|
|
@@ -166,7 +168,10 @@ class GraphQLQuery extends DataSource(RectPath(Shape)) {
|
|
|
166
168
|
this.data = response;
|
|
167
169
|
}
|
|
168
170
|
}
|
|
169
|
-
}
|
|
171
|
+
};
|
|
172
|
+
GraphQLQuery = __decorate([
|
|
173
|
+
sceneComponent('graphql-query')
|
|
174
|
+
], GraphQLQuery);
|
|
170
175
|
export class Query extends GraphQLQuery {
|
|
171
176
|
static get image() {
|
|
172
177
|
if (!Query._image) {
|
|
@@ -181,20 +186,22 @@ export class Query extends GraphQLQuery {
|
|
|
181
186
|
this.drawImage(context, Query.image, left, top, width, height);
|
|
182
187
|
}
|
|
183
188
|
}
|
|
184
|
-
|
|
189
|
+
let Mutation = Mutation_1 = class Mutation extends GraphQLQuery {
|
|
185
190
|
static get image() {
|
|
186
|
-
if (!
|
|
187
|
-
|
|
188
|
-
|
|
191
|
+
if (!Mutation_1._image) {
|
|
192
|
+
Mutation_1._image = new Image();
|
|
193
|
+
Mutation_1._image.src = new URL('../icons/symbol-graphql-mutation.png', import.meta.url).href;
|
|
189
194
|
}
|
|
190
|
-
return
|
|
195
|
+
return Mutation_1._image;
|
|
191
196
|
}
|
|
192
197
|
render(context) {
|
|
193
198
|
var { left, top, width, height } = this.bounds;
|
|
194
199
|
context.beginPath();
|
|
195
|
-
this.drawImage(context,
|
|
200
|
+
this.drawImage(context, Mutation_1.image, left, top, width, height);
|
|
196
201
|
}
|
|
197
|
-
}
|
|
198
|
-
|
|
199
|
-
|
|
202
|
+
};
|
|
203
|
+
Mutation = Mutation_1 = __decorate([
|
|
204
|
+
sceneComponent('graphql-mutation')
|
|
205
|
+
], Mutation);
|
|
206
|
+
export { Mutation };
|
|
200
207
|
//# sourceMappingURL=graphql-query-and-mutation.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"graphql-query-and-mutation.js","sourceRoot":"","sources":["../src/graphql-query-and-mutation.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,CAAA;AACZ,OAAO,GAAG,MAAM,aAAa,CAAA;AAG7B,OAAO,EAAE,SAAS,EAAmB,UAAU,EAAc,QAAQ,EAAE,KAAK,EAAE,MAAM,wBAAwB,CAAA;AAC5G,OAAO,EAAE,SAAS,EAAE,MAAM,IAAI,WAAW,EAAE,MAAM,kBAAkB,CAAA;AAInE,MAAM,MAAM,GAAoB;IAC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AkB,EAAE,QAAQ,CAAC,CAAA","sourcesContent":["import 'ses'\nimport gql from 'graphql-tag'\n\nimport { ApolloClient, NormalizedCacheObject } from '@apollo/client/core'\nimport { Component, ComponentNature, DataSource, Properties, RectPath, Shape } from '@hatiolab/things-scene'\nimport { buildArgs, client as localClient } from '@operato/graphql'\n\nimport GraphqlClient from './graphql-client'\n\nconst NATURE: ComponentNature = {\n mutable: false,\n resizable: true,\n rotatable: true,\n properties: [\n {\n type: 'id-input',\n label: 'client',\n name: 'client',\n placeholder: 'leave blank to use origin server',\n property: {\n component: 'graphql-client' // component의 type (null or undefined이면 모든 컴포넌트)\n }\n },\n {\n type: 'number',\n label: 'period',\n name: 'period',\n placeholder: 'SECONDS'\n },\n {\n type: 'graphql',\n label: 'query',\n name: 'query'\n },\n {\n type: 'checkbox',\n label: 'auto-start',\n name: 'autoStart'\n }\n ],\n 'value-property': 'value',\n help: 'scene/component/graphql'\n}\n\nclass GraphQLQuery extends DataSource(RectPath(Shape)) {\n private _repeatTimer?: number\n private _isStarted: boolean = false\n\n get nature() {\n return NATURE\n }\n\n onchange(after: Properties, before: Properties) {\n if ('value' in after) {\n if (after.value) this.requestData()\n }\n }\n\n get period() {\n return this.state.period * 1000\n }\n\n set period(period) {\n this.setState('period', period)\n this._initGraphqlQuery()\n }\n\n get repeatTimer() {\n return this._repeatTimer\n }\n\n set repeatTimer(repeatTimer) {\n this._stopRepeater()\n this._repeatTimer = repeatTimer\n }\n\n get autoStart() {\n return this.state.autoStart\n }\n\n set autoStart(autoStart) {\n this.setState('autoStart', autoStart)\n }\n\n get query() {\n var _query = this.state.query\n var objToVal = (exp: any) => {\n if (typeof exp === 'string') return exp\n else return JSON.stringify(exp)\n }\n var changedQuery: string | undefined = (Component.buildSubstitutor(_query, this, objToVal) || (() => _query))()\n try {\n changedQuery = changedQuery!.replace(/\\(.*\\)/gi, params => {\n const c = new Compartment({ console })\n let paramObject = c.evaluate(`({${params.slice(1, -1)}})`)\n return '(' + buildArgs(paramObject) + ')'\n })\n } catch (e) {\n console.log(e)\n }\n\n return changedQuery\n }\n\n get source() {\n return this.getState('source')\n }\n\n set source(source) {\n this.setState('source', source)\n }\n\n dispose() {\n super.dispose()\n this._stopRepeater()\n }\n\n ready() {\n super.ready()\n if (this.autoStart) {\n this._initGraphqlQuery()\n }\n }\n\n _initGraphqlQuery() {\n if (!this.app.isViewMode) return\n\n this._stopRepeater()\n this._startRepeater()\n }\n\n _stopRepeater() {\n if (this.repeatTimer !== undefined) {\n clearTimeout(this._repeatTimer!)\n delete this._repeatTimer\n }\n\n this._isStarted = false\n }\n\n _startRepeater() {\n this._isStarted = true\n\n // requestAnimationFrame 이 호출되지 않을 때는 requestData 호출도 하지 않도록 함.\n var _ = () => {\n if (!this._isStarted) {\n return\n }\n this.requestData()\n if (!Number.isNaN(this.period) && this.period > 0) {\n this._repeatTimer = setTimeout(() => {\n requestAnimationFrame(_)\n }, this.period)\n }\n }\n requestAnimationFrame(_)\n }\n\n async requestData() {\n if (!this.app.isViewMode) return\n var { client } = this.state\n var query = this.query\n var variables = this.value\n\n if (query) {\n const graphqlClient: ApolloClient<NormalizedCacheObject> =\n (client && (this.root.findById(client) as GraphqlClient)?.client) || localClient\n\n var response\n\n if (typeof variables === 'object') {\n response = await graphqlClient.query({\n query: gql`\n ${query}\n `,\n variables: variables\n })\n } else {\n response = await graphqlClient.query({\n query: gql`\n ${query}\n `,\n errorPolicy: 'all'\n })\n }\n\n console.log('response', response)\n this.data = response\n }\n }\n}\n\nexport class Query extends GraphQLQuery {\n private static _image: HTMLImageElement\n\n static get image() {\n if (!Query._image) {\n Query._image = new Image()\n Query._image.src = new URL('../icons/symbol-graphql-query.png', import.meta.url).href\n }\n\n return Query._image\n }\n\n render(context: CanvasRenderingContext2D) {\n var { left, top, width, height } = this.bounds\n\n context.beginPath()\n this.drawImage(context, Query.image, left, top, width, height)\n }\n}\n\nexport class Mutation extends GraphQLQuery {\n private static _image: HTMLImageElement\n\n static get image() {\n if (!Mutation._image) {\n Mutation._image = new Image()\n Mutation._image.src = new URL('../icons/symbol-graphql-mutation.png', import.meta.url).href\n }\n\n return Mutation._image\n }\n\n render(context: CanvasRenderingContext2D) {\n var { left, top, width, height } = this.bounds\n\n context.beginPath()\n this.drawImage(context, Mutation.image, left, top, width, height)\n }\n}\n\nComponent.register('graphql-query', Query)\nComponent.register('graphql-mutation', Mutation)\n"]}
|
|
1
|
+
{"version":3,"file":"graphql-query-and-mutation.js","sourceRoot":"","sources":["../src/graphql-query-and-mutation.ts"],"names":[],"mappings":";;AAAA,OAAO,KAAK,CAAA;AACZ,OAAO,GAAG,MAAM,aAAa,CAAA;AAG7B,OAAO,EACL,SAAS,EAET,UAAU,EAEV,QAAQ,EACR,KAAK,EACL,cAAc,EACf,MAAM,wBAAwB,CAAA;AAC/B,OAAO,EAAE,SAAS,EAAE,MAAM,IAAI,WAAW,EAAE,MAAM,kBAAkB,CAAA;AAInE,MAAM,MAAM,GAAoB;IAC9B,OAAO,EAAE,KAAK;IACd,SAAS,EAAE,IAAI;IACf,SAAS,EAAE,IAAI;IACf,UAAU,EAAE;QACV;YACE,IAAI,EAAE,UAAU;YAChB,KAAK,EAAE,QAAQ;YACf,IAAI,EAAE,QAAQ;YACd,WAAW,EAAE,kCAAkC;YAC/C,QAAQ,EAAE;gBACR,SAAS,EAAE,gBAAgB,CAAC,gDAAgD;aAC7E;SACF;QACD;YACE,IAAI,EAAE,QAAQ;YACd,KAAK,EAAE,QAAQ;YACf,IAAI,EAAE,QAAQ;YACd,WAAW,EAAE,SAAS;SACvB;QACD;YACE,IAAI,EAAE,SAAS;YACf,KAAK,EAAE,OAAO;YACd,IAAI,EAAE,OAAO;SACd;QACD;YACE,IAAI,EAAE,UAAU;YAChB,KAAK,EAAE,YAAY;YACnB,IAAI,EAAE,WAAW;SAClB;KACF;IACD,gBAAgB,EAAE,OAAO;IACzB,IAAI,EAAE,yBAAyB;CAChC,CAAA;AAGD,IAAM,YAAY,GAAlB,MAAM,YAAa,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,MAAM,KAAK,KAAK;QACd,IAAI,CAAC,UAAQ,CAAC,MAAM,EAAE,CAAC;YACrB,UAAQ,CAAC,MAAM,GAAG,IAAI,KAAK,EAAE,CAAA;YAC7B,UAAQ,CAAC,MAAM,CAAC,GAAG,GAAG,IAAI,GAAG,CAAC,sCAAsC,EAAE,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,IAAI,CAAA;QAC7F,CAAC;QAED,OAAO,UAAQ,CAAC,MAAM,CAAA;IACxB,CAAC;IAED,MAAM,CAAC,OAAiC;QACtC,IAAI,EAAE,IAAI,EAAE,GAAG,EAAE,KAAK,EAAE,MAAM,EAAE,GAAG,IAAI,CAAC,MAAM,CAAA;QAE9C,OAAO,CAAC,SAAS,EAAE,CAAA;QACnB,IAAI,CAAC,SAAS,CAAC,OAAO,EAAE,UAAQ,CAAC,KAAK,EAAE,IAAI,EAAE,GAAG,EAAE,KAAK,EAAE,MAAM,CAAC,CAAA;IACnE,CAAC;CACF,CAAA;AAlBY,QAAQ;IADpB,cAAc,CAAC,kBAAkB,CAAC;GACtB,QAAQ,CAkBpB","sourcesContent":["import 'ses'\nimport gql from 'graphql-tag'\n\nimport { ApolloClient, NormalizedCacheObject } from '@apollo/client/core/index.js'\nimport {\n Component,\n ComponentNature,\n DataSource,\n Properties,\n RectPath,\n Shape,\n sceneComponent\n} from '@hatiolab/things-scene'\nimport { buildArgs, client as localClient } from '@operato/graphql'\n\nimport GraphqlClient from './graphql-client.js'\n\nconst NATURE: ComponentNature = {\n mutable: false,\n resizable: true,\n rotatable: true,\n properties: [\n {\n type: 'id-input',\n label: 'client',\n name: 'client',\n placeholder: 'leave blank to use origin server',\n property: {\n component: 'graphql-client' // component의 type (null or undefined이면 모든 컴포넌트)\n }\n },\n {\n type: 'number',\n label: 'period',\n name: 'period',\n placeholder: 'SECONDS'\n },\n {\n type: 'graphql',\n label: 'query',\n name: 'query'\n },\n {\n type: 'checkbox',\n label: 'auto-start',\n name: 'autoStart'\n }\n ],\n 'value-property': 'value',\n help: 'scene/component/graphql'\n}\n\n@sceneComponent('graphql-query')\nclass GraphQLQuery extends DataSource(RectPath(Shape)) {\n private _repeatTimer?: number\n private _isStarted: boolean = false\n\n get nature() {\n return NATURE\n }\n\n onchange(after: Properties, before: Properties) {\n if ('value' in after) {\n if (after.value) this.requestData()\n }\n }\n\n get period() {\n return this.state.period * 1000\n }\n\n set period(period) {\n this.setState('period', period)\n this._initGraphqlQuery()\n }\n\n get repeatTimer() {\n return this._repeatTimer\n }\n\n set repeatTimer(repeatTimer) {\n this._stopRepeater()\n this._repeatTimer = repeatTimer\n }\n\n get autoStart() {\n return this.state.autoStart\n }\n\n set autoStart(autoStart) {\n this.setState('autoStart', autoStart)\n }\n\n get query() {\n var _query = this.state.query\n var objToVal = (exp: any) => {\n if (typeof exp === 'string') return exp\n else return JSON.stringify(exp)\n }\n var changedQuery: string | undefined = (Component.buildSubstitutor(_query, this, objToVal) || (() => _query))()\n try {\n changedQuery = changedQuery!.replace(/\\(.*\\)/gi, params => {\n const c = new Compartment({ console })\n let paramObject = c.evaluate(`({${params.slice(1, -1)}})`)\n return '(' + buildArgs(paramObject) + ')'\n })\n } catch (e) {\n console.log(e)\n }\n\n return changedQuery\n }\n\n get source() {\n return this.getState('source')\n }\n\n set source(source) {\n this.setState('source', source)\n }\n\n dispose() {\n super.dispose()\n this._stopRepeater()\n }\n\n ready() {\n super.ready()\n if (this.autoStart) {\n this._initGraphqlQuery()\n }\n }\n\n _initGraphqlQuery() {\n if (!this.app.isViewMode) return\n\n this._stopRepeater()\n this._startRepeater()\n }\n\n _stopRepeater() {\n if (this.repeatTimer !== undefined) {\n clearTimeout(this._repeatTimer!)\n delete this._repeatTimer\n }\n\n this._isStarted = false\n }\n\n _startRepeater() {\n this._isStarted = true\n\n // requestAnimationFrame 이 호출되지 않을 때는 requestData 호출도 하지 않도록 함.\n var _ = () => {\n if (!this._isStarted) {\n return\n }\n this.requestData()\n if (!Number.isNaN(this.period) && this.period > 0) {\n this._repeatTimer = setTimeout(() => {\n requestAnimationFrame(_)\n }, this.period)\n }\n }\n requestAnimationFrame(_)\n }\n\n async requestData() {\n if (!this.app.isViewMode) return\n var { client } = this.state\n var query = this.query\n var variables = this.value\n\n if (query) {\n const graphqlClient: ApolloClient<NormalizedCacheObject> =\n (client && (this.root.findById(client) as GraphqlClient)?.client) || localClient\n\n var response\n\n if (typeof variables === 'object') {\n response = await graphqlClient.query({\n query: gql`\n ${query}\n `,\n variables: variables\n })\n } else {\n response = await graphqlClient.query({\n query: gql`\n ${query}\n `,\n errorPolicy: 'all'\n })\n }\n\n console.log('response', response)\n this.data = response\n }\n }\n}\n\nexport class Query extends GraphQLQuery {\n private static _image: HTMLImageElement\n\n static get image() {\n if (!Query._image) {\n Query._image = new Image()\n Query._image.src = new URL('../icons/symbol-graphql-query.png', import.meta.url).href\n }\n\n return Query._image\n }\n\n render(context: CanvasRenderingContext2D) {\n var { left, top, width, height } = this.bounds\n\n context.beginPath()\n this.drawImage(context, Query.image, left, top, width, height)\n }\n}\n\n@sceneComponent('graphql-mutation')\nexport class Mutation extends GraphQLQuery {\n private static _image: HTMLImageElement\n\n static get image() {\n if (!Mutation._image) {\n Mutation._image = new Image()\n Mutation._image.src = new URL('../icons/symbol-graphql-mutation.png', import.meta.url).href\n }\n\n return Mutation._image\n }\n\n render(context: CanvasRenderingContext2D) {\n var { left, top, width, height } = this.bounds\n\n context.beginPath()\n this.drawImage(context, Mutation.image, left, top, width, height)\n }\n}\n"]}
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
/*
|
|
2
2
|
* Copyright © HatioLab Inc. All rights reserved.
|
|
3
3
|
*/
|
|
4
|
+
var GraphqlSubscription_1;
|
|
5
|
+
import { __decorate } from "tslib";
|
|
4
6
|
import { gql } from 'graphql-tag';
|
|
5
|
-
import {
|
|
7
|
+
import { DataSource, RectPath, Shape, sceneComponent } from '@hatiolab/things-scene';
|
|
6
8
|
import { subscribe } from '@operato/graphql';
|
|
7
9
|
const NATURE = {
|
|
8
10
|
mutable: false,
|
|
@@ -23,13 +25,13 @@ const NATURE = {
|
|
|
23
25
|
],
|
|
24
26
|
help: 'scene/component/graphql-subscription'
|
|
25
27
|
};
|
|
26
|
-
|
|
28
|
+
let GraphqlSubscription = GraphqlSubscription_1 = class GraphqlSubscription extends DataSource(RectPath(Shape)) {
|
|
27
29
|
static get image() {
|
|
28
|
-
if (!
|
|
29
|
-
|
|
30
|
-
|
|
30
|
+
if (!GraphqlSubscription_1._image) {
|
|
31
|
+
GraphqlSubscription_1._image = new Image();
|
|
32
|
+
GraphqlSubscription_1._image.src = new URL('../icons/symbol-graphql-subscription.png', import.meta.url).href;
|
|
31
33
|
}
|
|
32
|
-
return
|
|
34
|
+
return GraphqlSubscription_1._image;
|
|
33
35
|
}
|
|
34
36
|
dispose() {
|
|
35
37
|
if (this.unsubscribe) {
|
|
@@ -40,7 +42,7 @@ export default class GraphqlSubscription extends DataSource(RectPath(Shape)) {
|
|
|
40
42
|
render(context) {
|
|
41
43
|
var { left, top, width, height } = this.bounds;
|
|
42
44
|
context.beginPath();
|
|
43
|
-
this.drawImage(context,
|
|
45
|
+
this.drawImage(context, GraphqlSubscription_1.image, left, top, width, height);
|
|
44
46
|
}
|
|
45
47
|
ready() {
|
|
46
48
|
super.ready();
|
|
@@ -66,6 +68,9 @@ export default class GraphqlSubscription extends DataSource(RectPath(Shape)) {
|
|
|
66
68
|
});
|
|
67
69
|
this.unsubscribe = unsubscribe;
|
|
68
70
|
}
|
|
69
|
-
}
|
|
70
|
-
|
|
71
|
+
};
|
|
72
|
+
GraphqlSubscription = GraphqlSubscription_1 = __decorate([
|
|
73
|
+
sceneComponent('graphql-subscription')
|
|
74
|
+
], GraphqlSubscription);
|
|
75
|
+
export default GraphqlSubscription;
|
|
71
76
|
//# sourceMappingURL=graphql-subscription.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"graphql-subscription.js","sourceRoot":"","sources":["../src/graphql-subscription.ts"],"names":[],"mappings":"AAAA;;GAEG
|
|
1
|
+
{"version":3,"file":"graphql-subscription.js","sourceRoot":"","sources":["../src/graphql-subscription.ts"],"names":[],"mappings":"AAAA;;GAEG;;;AAEH,OAAO,EAAE,GAAG,EAAE,MAAM,aAAa,CAAA;AAEjC,OAAO,EAA8B,UAAU,EAAE,QAAQ,EAAE,KAAK,EAAE,cAAc,EAAE,MAAM,wBAAwB,CAAA;AAChH,OAAO,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAA;AAE5C,MAAM,MAAM,GAAoB;IAC9B,OAAO,EAAE,KAAK;IACd,SAAS,EAAE,IAAI;IACf,SAAS,EAAE,IAAI;IACf,UAAU,EAAE;QACV;YACE,oDAAoD;YACpD,IAAI,EAAE,QAAQ;YACd,KAAK,EAAE,UAAU;YACjB,IAAI,EAAE,UAAU;SACjB;QACD;YACE,IAAI,EAAE,SAAS;YACf,KAAK,EAAE,OAAO;YACd,IAAI,EAAE,OAAO;SACd;KACF;IACD,IAAI,EAAE,sCAAsC;CAC7C,CAAA;AAGc,IAAM,mBAAmB,2BAAzB,MAAM,mBAAoB,SAAQ,UAAU,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC;IAI1E,MAAM,KAAK,KAAK;QACd,IAAI,CAAC,qBAAmB,CAAC,MAAM,EAAE,CAAC;YAChC,qBAAmB,CAAC,MAAM,GAAG,IAAI,KAAK,EAAE,CAAA;YACxC,qBAAmB,CAAC,MAAM,CAAC,GAAG,GAAG,IAAI,GAAG,CAAC,0CAA0C,EAAE,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,IAAI,CAAA;QAC5G,CAAC;QAED,OAAO,qBAAmB,CAAC,MAAM,CAAA;IACnC,CAAC;IAED,OAAO;QACL,IAAI,IAAI,CAAC,WAAW,EAAE,CAAC;YACrB,IAAI,CAAC,WAAW,EAAE,CAAA;QACpB,CAAC;QAED,KAAK,CAAC,OAAO,EAAE,CAAA;IACjB,CAAC;IAED,MAAM,CAAC,OAAiC;QACtC,IAAI,EAAE,IAAI,EAAE,GAAG,EAAE,KAAK,EAAE,MAAM,EAAE,GAAG,IAAI,CAAC,MAAM,CAAA;QAE9C,OAAO,CAAC,SAAS,EAAE,CAAA;QACnB,IAAI,CAAC,SAAS,CAAC,OAAO,EAAE,qBAAmB,CAAC,KAAK,EAAE,IAAI,EAAE,GAAG,EAAE,KAAK,EAAE,MAAM,CAAC,CAAA;IAC9E,CAAC;IAED,KAAK;QACH,KAAK,CAAC,KAAK,EAAE,CAAA;QAEb,IAAI,IAAI,CAAC,GAAG,CAAC,UAAU,EAAE,CAAC;YACxB,IAAI,CAAC,WAAW,EAAE,CAAA;QACpB,CAAC;IACH,CAAC;IAED,IAAI,MAAM;QACR,OAAO,MAAM,CAAA;IACf,CAAC;IAED,KAAK,CAAC,WAAW;QACf,IAAI,EAAE,KAAK,EAAE,GAAG,IAAI,CAAC,KAAK,CAAA;QAE1B,MAAM,EAAE,WAAW,EAAE,GAAG,MAAM,SAAS,CACrC;YACE,KAAK,EAAE,GAAG,CAAA;YACN,KAAK;SACR;SACF,EACD;YACE,IAAI,EAAE,CAAC,EAAE,IAAI,EAAiB,EAAE,EAAE;gBAChC,IAAI,IAAI,EAAE,CAAC;oBACT,IAAI,CAAC,IAAI,GAAG,IAAI,CAAA;gBAClB,CAAC;YACH,CAAC;SACF,CACF,CAAA;QAED,IAAI,CAAC,WAAW,GAAG,WAAW,CAAA;IAChC,CAAC;CACF,CAAA;AA5DoB,mBAAmB;IADvC,cAAc,CAAC,sBAAsB,CAAC;GAClB,mBAAmB,CA4DvC;eA5DoB,mBAAmB","sourcesContent":["/*\n * Copyright © HatioLab Inc. All rights reserved.\n */\n\nimport { gql } from 'graphql-tag'\n\nimport { Component, ComponentNature, DataSource, RectPath, Shape, sceneComponent } from '@hatiolab/things-scene'\nimport { subscribe } from '@operato/graphql'\n\nconst NATURE: ComponentNature = {\n mutable: false,\n resizable: true,\n rotatable: true,\n properties: [\n {\n /* origin의 subscription 만을 허용하므로, 엔드포인트 속성은 무시한다. */\n type: 'string',\n label: 'endpoint',\n name: 'endpoint'\n },\n {\n type: 'graphql',\n label: 'query',\n name: 'query'\n }\n ],\n help: 'scene/component/graphql-subscription'\n}\n\n@sceneComponent('graphql-subscription')\nexport default class GraphqlSubscription extends DataSource(RectPath(Shape)) {\n private static _image: HTMLImageElement\n private unsubscribe?: () => void\n\n static get image() {\n if (!GraphqlSubscription._image) {\n GraphqlSubscription._image = new Image()\n GraphqlSubscription._image.src = new URL('../icons/symbol-graphql-subscription.png', import.meta.url).href\n }\n\n return GraphqlSubscription._image\n }\n\n dispose() {\n if (this.unsubscribe) {\n this.unsubscribe()\n }\n\n super.dispose()\n }\n\n render(context: CanvasRenderingContext2D) {\n var { left, top, width, height } = this.bounds\n\n context.beginPath()\n this.drawImage(context, GraphqlSubscription.image, left, top, width, height)\n }\n\n ready() {\n super.ready()\n\n if (this.app.isViewMode) {\n this.requestData()\n }\n }\n\n get nature() {\n return NATURE\n }\n\n async requestData() {\n var { query } = this.state\n\n const { unsubscribe } = await subscribe(\n {\n query: gql`\n ${query}\n `\n },\n {\n next: ({ data }: { data: any }) => {\n if (data) {\n this.data = data\n }\n }\n }\n )\n\n this.unsubscribe = unsubscribe\n }\n}\n"]}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import Client from './graphql-client';
|
|
2
|
-
import { Mutation, Query } from './graphql-query-and-mutation';
|
|
3
|
-
import Subscription from './graphql-subscription';
|
|
4
|
-
declare const _default: (typeof
|
|
1
|
+
import Client from './graphql-client.js';
|
|
2
|
+
import { Mutation, Query } from './graphql-query-and-mutation.js';
|
|
3
|
+
import Subscription from './graphql-subscription.js';
|
|
4
|
+
declare const _default: (typeof Subscription | typeof Query | typeof Mutation | typeof Client)[];
|
|
5
5
|
export default _default;
|
package/dist/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import Client from './graphql-client';
|
|
2
|
-
import { Mutation, Query } from './graphql-query-and-mutation';
|
|
3
|
-
import Subscription from './graphql-subscription';
|
|
1
|
+
import Client from './graphql-client.js';
|
|
2
|
+
import { Mutation, Query } from './graphql-query-and-mutation.js';
|
|
3
|
+
import Subscription from './graphql-subscription.js';
|
|
4
4
|
export default [Client, Query, Mutation, Subscription];
|
|
5
5
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,qBAAqB,CAAA;AACxC,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,MAAM,iCAAiC,CAAA;AACjE,OAAO,YAAY,MAAM,2BAA2B,CAAA;AAEpD,eAAe,CAAC,MAAM,EAAE,KAAK,EAAE,QAAQ,EAAE,YAAY,CAAC,CAAA","sourcesContent":["import Client from './graphql-client.js'\nimport { Mutation, Query } from './graphql-query-and-mutation.js'\nimport Subscription from './graphql-subscription.js'\n\nexport default [Client, Query, Mutation, Subscription]\n"]}
|
package/dist/templates/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import graphqlClient from './graphql-client';
|
|
2
|
-
import graphqlMutation from './graphql-mutation';
|
|
3
|
-
import graphqlQuery from './graphql-query';
|
|
4
|
-
import graphqlSubscription from './graphql-subscription';
|
|
1
|
+
import graphqlClient from './graphql-client.js';
|
|
2
|
+
import graphqlMutation from './graphql-mutation.js';
|
|
3
|
+
import graphqlQuery from './graphql-query.js';
|
|
4
|
+
import graphqlSubscription from './graphql-subscription.js';
|
|
5
5
|
export default [graphqlClient, graphqlQuery, graphqlMutation, graphqlSubscription];
|
|
6
6
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/templates/index.ts"],"names":[],"mappings":"AAAA,OAAO,aAAa,MAAM,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/templates/index.ts"],"names":[],"mappings":"AAAA,OAAO,aAAa,MAAM,qBAAqB,CAAA;AAC/C,OAAO,eAAe,MAAM,uBAAuB,CAAA;AACnD,OAAO,YAAY,MAAM,oBAAoB,CAAA;AAC7C,OAAO,mBAAmB,MAAM,2BAA2B,CAAA;AAE3D,eAAe,CAAC,aAAa,EAAE,YAAY,EAAE,eAAe,EAAE,mBAAmB,CAAC,CAAA","sourcesContent":["import graphqlClient from './graphql-client.js'\nimport graphqlMutation from './graphql-mutation.js'\nimport graphqlQuery from './graphql-query.js'\nimport graphqlSubscription from './graphql-subscription.js'\n\nexport default [graphqlClient, graphqlQuery, graphqlMutation, graphqlSubscription]\n"]}
|
package/package.json
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@operato/scene-graphql",
|
|
3
3
|
"description": "Graphql datasource component for things-scene",
|
|
4
|
-
"version": "9.0.0-beta.
|
|
4
|
+
"version": "9.0.0-beta.16",
|
|
5
|
+
"type": "module",
|
|
5
6
|
"main": "dist/index.js",
|
|
6
7
|
"module": "dist/index.js",
|
|
7
8
|
"author": "heartyoh",
|
|
@@ -40,8 +41,8 @@
|
|
|
40
41
|
"@typescript-eslint/parser": "^4.33.0",
|
|
41
42
|
"@web/dev-server": "^0.1.28",
|
|
42
43
|
"concurrently": "^8.0.1",
|
|
43
|
-
"eslint": "^
|
|
44
|
-
"eslint-config-prettier": "^
|
|
44
|
+
"eslint": "^9.18.0",
|
|
45
|
+
"eslint-config-prettier": "^10.0.1",
|
|
45
46
|
"graphql-tag": "^2.12.6",
|
|
46
47
|
"husky": "^8.0.3",
|
|
47
48
|
"lint-staged": "^13.2.2",
|
|
@@ -61,5 +62,5 @@
|
|
|
61
62
|
"prettier --write"
|
|
62
63
|
]
|
|
63
64
|
},
|
|
64
|
-
"gitHead": "
|
|
65
|
+
"gitHead": "761c3944e6c4a6c382c940522fc746c7f1aabc3e"
|
|
65
66
|
}
|
package/things-scene.config.js
CHANGED