@common-stack/client-core 0.2.3 → 0.2.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/lib/index.js CHANGED
@@ -1,107 +1,20 @@
1
- module.exports =
2
- /******/ (function(modules) { // webpackBootstrap
3
- /******/ // The module cache
4
- /******/ var installedModules = {};
5
- /******/
6
- /******/ // The require function
7
- /******/ function __webpack_require__(moduleId) {
8
- /******/
9
- /******/ // Check if module is in cache
10
- /******/ if(installedModules[moduleId]) {
11
- /******/ return installedModules[moduleId].exports;
12
- /******/ }
13
- /******/ // Create a new module (and put it into the cache)
14
- /******/ var module = installedModules[moduleId] = {
15
- /******/ i: moduleId,
16
- /******/ l: false,
17
- /******/ exports: {}
18
- /******/ };
19
- /******/
20
- /******/ // Execute the module function
21
- /******/ modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
22
- /******/
23
- /******/ // Flag the module as loaded
24
- /******/ module.l = true;
25
- /******/
26
- /******/ // Return the exports of the module
27
- /******/ return module.exports;
28
- /******/ }
29
- /******/
30
- /******/
31
- /******/ // expose the modules object (__webpack_modules__)
32
- /******/ __webpack_require__.m = modules;
33
- /******/
34
- /******/ // expose the module cache
35
- /******/ __webpack_require__.c = installedModules;
36
- /******/
37
- /******/ // define getter function for harmony exports
38
- /******/ __webpack_require__.d = function(exports, name, getter) {
39
- /******/ if(!__webpack_require__.o(exports, name)) {
40
- /******/ Object.defineProperty(exports, name, { enumerable: true, get: getter });
41
- /******/ }
42
- /******/ };
43
- /******/
44
- /******/ // define __esModule on exports
45
- /******/ __webpack_require__.r = function(exports) {
46
- /******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
47
- /******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
48
- /******/ }
49
- /******/ Object.defineProperty(exports, '__esModule', { value: true });
50
- /******/ };
51
- /******/
52
- /******/ // create a fake namespace object
53
- /******/ // mode & 1: value is a module id, require it
54
- /******/ // mode & 2: merge all properties of value into the ns
55
- /******/ // mode & 4: return value when already ns object
56
- /******/ // mode & 8|1: behave like require
57
- /******/ __webpack_require__.t = function(value, mode) {
58
- /******/ if(mode & 1) value = __webpack_require__(value);
59
- /******/ if(mode & 8) return value;
60
- /******/ if((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;
61
- /******/ var ns = Object.create(null);
62
- /******/ __webpack_require__.r(ns);
63
- /******/ Object.defineProperty(ns, 'default', { enumerable: true, value: value });
64
- /******/ if(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));
65
- /******/ return ns;
66
- /******/ };
67
- /******/
68
- /******/ // getDefaultExport function for compatibility with non-harmony modules
69
- /******/ __webpack_require__.n = function(module) {
70
- /******/ var getter = module && module.__esModule ?
71
- /******/ function getDefault() { return module['default']; } :
72
- /******/ function getModuleExports() { return module; };
73
- /******/ __webpack_require__.d(getter, 'a', getter);
74
- /******/ return getter;
75
- /******/ };
76
- /******/
77
- /******/ // Object.prototype.hasOwnProperty.call
78
- /******/ __webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
79
- /******/
80
- /******/ // __webpack_public_path__
81
- /******/ __webpack_require__.p = "";
82
- /******/
83
- /******/
84
- /******/ // Load entry module and return exports
85
- /******/ return __webpack_require__(__webpack_require__.s = "./src/index.ts");
86
- /******/ })
87
- /************************************************************************/
88
- /******/ ({
1
+ /******/ (() => { // webpackBootstrap
2
+ /******/ "use strict";
3
+ /******/ var __webpack_modules__ = ({
89
4
 
90
5
  /***/ "./src/connector/abstract-connector.ts":
91
6
  /*!*********************************************!*\
92
7
  !*** ./src/connector/abstract-connector.ts ***!
93
8
  \*********************************************/
94
- /*! no static exports found */
95
- /***/ (function(module, exports, __webpack_require__) {
9
+ /***/ ((__unused_webpack_module, exports, __webpack_require__) => {
96
10
 
97
- "use strict";
98
11
 
99
- Object.defineProperty(exports, "__esModule", { value: true });
12
+ Object.defineProperty(exports, "__esModule", ({ value: true }));
100
13
  exports.AbstractFeature = exports.featureCatalog = void 0;
101
14
  const React = __webpack_require__(/*! react */ "react");
102
15
  const lodash_1 = __webpack_require__(/*! lodash */ "lodash");
103
16
  const inversify_1 = __webpack_require__(/*! inversify */ "inversify");
104
- const combine = (features, extractor) => lodash_1.without(lodash_1.union(...lodash_1.map(features, res => lodash_1.castArray(extractor(res)))), undefined);
17
+ const combine = (features, extractor) => (0, lodash_1.without)((0, lodash_1.union)(...(0, lodash_1.map)(features, res => (0, lodash_1.castArray)(extractor(res)))), undefined);
105
18
  exports.featureCatalog = {};
106
19
  class AbstractFeature {
107
20
  /**
@@ -166,7 +79,7 @@ class AbstractFeature {
166
79
  return this.routerFactory(this.getRoutes());
167
80
  }
168
81
  get reducers() {
169
- return lodash_1.merge({}, ...(this.reducer || []));
82
+ return (0, lodash_1.merge)({}, ...(this.reducer || []));
170
83
  }
171
84
  createContainers(options) {
172
85
  // only create once
@@ -188,7 +101,7 @@ class AbstractFeature {
188
101
  if (!this.isContainerLoaded) {
189
102
  this.createContainers(options);
190
103
  }
191
- this.services = lodash_1.merge({}, ...this.createServiceFunc.map(serviceFunc => serviceFunc(this.container)));
104
+ this.services = (0, lodash_1.merge)({}, ...this.createServiceFunc.map(serviceFunc => serviceFunc(this.container)));
192
105
  return this.services;
193
106
  }
194
107
  catch (err) {
@@ -214,9 +127,9 @@ class AbstractFeature {
214
127
  .join('\n');
215
128
  const typeDefs = acc.typeDefs ? acc.typeDefs.concat('\n', schema) : schema;
216
129
  const defaults = curr.defaults ? attemptDefaults.concat(curr.defaults) : attemptDefaults;
217
- const resolvers = lodash_1.merge(acc.resolvers, consoldidatedResolvers(curr.resolvers, args.resolverContex));
218
- const possibleTypes = lodash_1.merge(acc.possibleTypes, curr.possibleTypes);
219
- const typePolicies = lodash_1.merge(acc.typePolicies, curr.typePolicies);
130
+ const resolvers = (0, lodash_1.merge)(acc.resolvers, consoldidatedResolvers(curr.resolvers, args.resolverContex));
131
+ const possibleTypes = (0, lodash_1.merge)(acc.possibleTypes, curr.possibleTypes);
132
+ const typePolicies = (0, lodash_1.merge)(acc.typePolicies, curr.typePolicies);
220
133
  const retryLinkAttemptFuncs = curr.retryLinkAttemptFuncs ? attemptFuncAccumulator.concat(curr.retryLinkAttemptFuncs || []) : attemptFuncAccumulator;
221
134
  const preLinks = preLinksAccumulator.concat((curr.preLinkFuncs || []).map(linkF => linkF(cn)) || []);
222
135
  const connectionParams = curr.connectionParam ? connectionParamsFuncAccumulator.concat(consoldidatedConnection(curr.connectionParam, cn)) : connectionParamsFuncAccumulator;
@@ -244,10 +157,10 @@ class AbstractFeature {
244
157
  return this.scriptsInsert;
245
158
  }
246
159
  get leftMainPanel() {
247
- return lodash_1.merge({}, ...(this.leftMainPanelItems || []));
160
+ return (0, lodash_1.merge)({}, ...(this.leftMainPanelItems || []));
248
161
  }
249
162
  get middleMainPanel() {
250
- const panelObj = lodash_1.merge({}, ...(this.middleMainPanelItems || []));
163
+ const panelObj = (0, lodash_1.merge)({}, ...(this.middleMainPanelItems || []));
251
164
  const withProps = {};
252
165
  Object.keys(panelObj).forEach(key => {
253
166
  const props = this.middleMainPanelItemsProps.filter(el => !!el[key]);
@@ -274,13 +187,13 @@ class AbstractFeature {
274
187
  return this.rightFooterItems;
275
188
  }
276
189
  get middleLowerPanel() {
277
- return lodash_1.merge({}, ...(this.middleLowerPanelItems || []));
190
+ return (0, lodash_1.merge)({}, ...(this.middleLowerPanelItems || []));
278
191
  }
279
192
  get reduxPersistStateTransformers() {
280
193
  return this.reduxPersistTransforms;
281
194
  }
282
195
  getDataIdFromObject(result) {
283
- const dataIdFromObject = lodash_1.merge({}, ...this.dataIdFromObject);
196
+ const dataIdFromObject = (0, lodash_1.merge)({}, ...this.dataIdFromObject);
284
197
  if (dataIdFromObject[result.__typename]) {
285
198
  return dataIdFromObject[result.__typename](result);
286
199
  }
@@ -296,7 +209,7 @@ function consoldidatedResolvers(resolvers, context) {
296
209
  ? resolver(context)
297
210
  : resolver;
298
211
  });
299
- finalResolvers = lodash_1.merge({}, ...resolverObject);
212
+ finalResolvers = (0, lodash_1.merge)({}, ...resolverObject);
300
213
  }
301
214
  else {
302
215
  finalResolvers = typeof resolvers === 'function'
@@ -325,14 +238,16 @@ async function consoldidatedConnection(connectionParams, context) {
325
238
  /*!********************************!*\
326
239
  !*** ./src/connector/index.ts ***!
327
240
  \********************************/
328
- /*! no static exports found */
329
- /***/ (function(module, exports, __webpack_require__) {
241
+ /***/ (function(__unused_webpack_module, exports, __webpack_require__) {
330
242
 
331
- "use strict";
332
243
 
333
244
  var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
334
245
  if (k2 === undefined) k2 = k;
335
- Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
246
+ var desc = Object.getOwnPropertyDescriptor(m, k);
247
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
248
+ desc = { enumerable: true, get: function() { return m[k]; } };
249
+ }
250
+ Object.defineProperty(o, k2, desc);
336
251
  }) : (function(o, m, k, k2) {
337
252
  if (k2 === undefined) k2 = k;
338
253
  o[k2] = m[k];
@@ -340,7 +255,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi
340
255
  var __exportStar = (this && this.__exportStar) || function(m, exports) {
341
256
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
342
257
  };
343
- Object.defineProperty(exports, "__esModule", { value: true });
258
+ Object.defineProperty(exports, "__esModule", ({ value: true }));
344
259
  __exportStar(__webpack_require__(/*! ./abstract-connector */ "./src/connector/abstract-connector.ts"), exports);
345
260
 
346
261
 
@@ -350,16 +265,14 @@ __exportStar(__webpack_require__(/*! ./abstract-connector */ "./src/connector/ab
350
265
  /*!************************************!*\
351
266
  !*** ./src/constants/constants.ts ***!
352
267
  \************************************/
353
- /*! no static exports found */
354
- /***/ (function(module, exports, __webpack_require__) {
268
+ /***/ ((__unused_webpack_module, exports, __webpack_require__) => {
355
269
 
356
- "use strict";
357
270
 
358
- Object.defineProperty(exports, "__esModule", { value: true });
271
+ Object.defineProperty(exports, "__esModule", ({ value: true }));
359
272
  exports.REDUX_PERSIST_KEY = exports.ClientTypes = exports.ElectronTypes = void 0;
360
273
  const core_1 = __webpack_require__(/*! @common-stack/core */ "@common-stack/core");
361
- Object.defineProperty(exports, "ClientTypes", { enumerable: true, get: function () { return core_1.ClientTypes; } });
362
- Object.defineProperty(exports, "ElectronTypes", { enumerable: true, get: function () { return core_1.ElectronTypes; } });
274
+ Object.defineProperty(exports, "ClientTypes", ({ enumerable: true, get: function () { return core_1.ClientTypes; } }));
275
+ Object.defineProperty(exports, "ElectronTypes", ({ enumerable: true, get: function () { return core_1.ElectronTypes; } }));
363
276
  exports.REDUX_PERSIST_KEY = 'root';
364
277
 
365
278
 
@@ -369,14 +282,16 @@ exports.REDUX_PERSIST_KEY = 'root';
369
282
  /*!********************************!*\
370
283
  !*** ./src/constants/index.ts ***!
371
284
  \********************************/
372
- /*! no static exports found */
373
- /***/ (function(module, exports, __webpack_require__) {
285
+ /***/ (function(__unused_webpack_module, exports, __webpack_require__) {
374
286
 
375
- "use strict";
376
287
 
377
288
  var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
378
289
  if (k2 === undefined) k2 = k;
379
- Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
290
+ var desc = Object.getOwnPropertyDescriptor(m, k);
291
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
292
+ desc = { enumerable: true, get: function() { return m[k]; } };
293
+ }
294
+ Object.defineProperty(o, k2, desc);
380
295
  }) : (function(o, m, k, k2) {
381
296
  if (k2 === undefined) k2 = k;
382
297
  o[k2] = m[k];
@@ -384,7 +299,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi
384
299
  var __exportStar = (this && this.__exportStar) || function(m, exports) {
385
300
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
386
301
  };
387
- Object.defineProperty(exports, "__esModule", { value: true });
302
+ Object.defineProperty(exports, "__esModule", ({ value: true }));
388
303
  __exportStar(__webpack_require__(/*! ./constants */ "./src/constants/constants.ts"), exports);
389
304
 
390
305
 
@@ -394,12 +309,10 @@ __exportStar(__webpack_require__(/*! ./constants */ "./src/constants/constants.t
394
309
  /*!**************************************************!*\
395
310
  !*** ./src/helpers/apollo-client-test-helper.ts ***!
396
311
  \**************************************************/
397
- /*! no static exports found */
398
- /***/ (function(module, exports, __webpack_require__) {
312
+ /***/ ((__unused_webpack_module, exports, __webpack_require__) => {
399
313
 
400
- "use strict";
401
314
 
402
- Object.defineProperty(exports, "__esModule", { value: true });
315
+ Object.defineProperty(exports, "__esModule", ({ value: true }));
403
316
  exports.apolloClientHelper = void 0;
404
317
  const client_1 = __webpack_require__(/*! @apollo/client */ "@apollo/client");
405
318
  const client_2 = __webpack_require__(/*! @cdm-logger/client */ "@cdm-logger/client");
@@ -464,14 +377,16 @@ exports.apolloClientHelper = apolloClientHelper;
464
377
  /*!******************************!*\
465
378
  !*** ./src/helpers/index.ts ***!
466
379
  \******************************/
467
- /*! no static exports found */
468
- /***/ (function(module, exports, __webpack_require__) {
380
+ /***/ (function(__unused_webpack_module, exports, __webpack_require__) {
469
381
 
470
- "use strict";
471
382
 
472
383
  var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
473
384
  if (k2 === undefined) k2 = k;
474
- Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
385
+ var desc = Object.getOwnPropertyDescriptor(m, k);
386
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
387
+ desc = { enumerable: true, get: function() { return m[k]; } };
388
+ }
389
+ Object.defineProperty(o, k2, desc);
475
390
  }) : (function(o, m, k, k2) {
476
391
  if (k2 === undefined) k2 = k;
477
392
  o[k2] = m[k];
@@ -479,7 +394,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi
479
394
  var __exportStar = (this && this.__exportStar) || function(m, exports) {
480
395
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
481
396
  };
482
- Object.defineProperty(exports, "__esModule", { value: true });
397
+ Object.defineProperty(exports, "__esModule", ({ value: true }));
483
398
  __exportStar(__webpack_require__(/*! ./apollo-client-test-helper */ "./src/helpers/apollo-client-test-helper.ts"), exports);
484
399
 
485
400
 
@@ -489,14 +404,16 @@ __exportStar(__webpack_require__(/*! ./apollo-client-test-helper */ "./src/helpe
489
404
  /*!**********************!*\
490
405
  !*** ./src/index.ts ***!
491
406
  \**********************/
492
- /*! no static exports found */
493
- /***/ (function(module, exports, __webpack_require__) {
407
+ /***/ (function(__unused_webpack_module, exports, __webpack_require__) {
494
408
 
495
- "use strict";
496
409
 
497
410
  var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
498
411
  if (k2 === undefined) k2 = k;
499
- Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
412
+ var desc = Object.getOwnPropertyDescriptor(m, k);
413
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
414
+ desc = { enumerable: true, get: function() { return m[k]; } };
415
+ }
416
+ Object.defineProperty(o, k2, desc);
500
417
  }) : (function(o, m, k, k2) {
501
418
  if (k2 === undefined) k2 = k;
502
419
  o[k2] = m[k];
@@ -504,7 +421,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi
504
421
  var __exportStar = (this && this.__exportStar) || function(m, exports) {
505
422
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
506
423
  };
507
- Object.defineProperty(exports, "__esModule", { value: true });
424
+ Object.defineProperty(exports, "__esModule", ({ value: true }));
508
425
  __exportStar(__webpack_require__(/*! ./logger */ "./src/logger/index.ts"), exports);
509
426
  __exportStar(__webpack_require__(/*! ./connector */ "./src/connector/index.ts"), exports);
510
427
  __exportStar(__webpack_require__(/*! ./interfaces */ "./src/interfaces/index.ts"), exports);
@@ -518,13 +435,11 @@ __exportStar(__webpack_require__(/*! ./helpers */ "./src/helpers/index.ts"), exp
518
435
  /*!*************************************!*\
519
436
  !*** ./src/interfaces/connector.ts ***!
520
437
  \*************************************/
521
- /*! no static exports found */
522
- /***/ (function(module, exports, __webpack_require__) {
438
+ /***/ ((__unused_webpack_module, exports) => {
523
439
 
524
- "use strict";
525
440
 
526
441
  // tslint:disable:max-line-length
527
- Object.defineProperty(exports, "__esModule", { value: true });
442
+ Object.defineProperty(exports, "__esModule", ({ value: true }));
528
443
 
529
444
 
530
445
  /***/ }),
@@ -533,14 +448,16 @@ Object.defineProperty(exports, "__esModule", { value: true });
533
448
  /*!*********************************!*\
534
449
  !*** ./src/interfaces/index.ts ***!
535
450
  \*********************************/
536
- /*! no static exports found */
537
- /***/ (function(module, exports, __webpack_require__) {
451
+ /***/ (function(__unused_webpack_module, exports, __webpack_require__) {
538
452
 
539
- "use strict";
540
453
 
541
454
  var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
542
455
  if (k2 === undefined) k2 = k;
543
- Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
456
+ var desc = Object.getOwnPropertyDescriptor(m, k);
457
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
458
+ desc = { enumerable: true, get: function() { return m[k]; } };
459
+ }
460
+ Object.defineProperty(o, k2, desc);
544
461
  }) : (function(o, m, k, k2) {
545
462
  if (k2 === undefined) k2 = k;
546
463
  o[k2] = m[k];
@@ -548,7 +465,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi
548
465
  var __exportStar = (this && this.__exportStar) || function(m, exports) {
549
466
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
550
467
  };
551
- Object.defineProperty(exports, "__esModule", { value: true });
468
+ Object.defineProperty(exports, "__esModule", ({ value: true }));
552
469
  __exportStar(__webpack_require__(/*! ./connector */ "./src/interfaces/connector.ts"), exports);
553
470
 
554
471
 
@@ -558,14 +475,16 @@ __exportStar(__webpack_require__(/*! ./connector */ "./src/interfaces/connector.
558
475
  /*!*****************************!*\
559
476
  !*** ./src/logger/index.ts ***!
560
477
  \*****************************/
561
- /*! no static exports found */
562
- /***/ (function(module, exports, __webpack_require__) {
478
+ /***/ (function(__unused_webpack_module, exports, __webpack_require__) {
563
479
 
564
- "use strict";
565
480
 
566
481
  var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
567
482
  if (k2 === undefined) k2 = k;
568
- Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
483
+ var desc = Object.getOwnPropertyDescriptor(m, k);
484
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
485
+ desc = { enumerable: true, get: function() { return m[k]; } };
486
+ }
487
+ Object.defineProperty(o, k2, desc);
569
488
  }) : (function(o, m, k, k2) {
570
489
  if (k2 === undefined) k2 = k;
571
490
  o[k2] = m[k];
@@ -573,7 +492,7 @@ var __createBinding = (this && this.__createBinding) || (Object.create ? (functi
573
492
  var __exportStar = (this && this.__exportStar) || function(m, exports) {
574
493
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
575
494
  };
576
- Object.defineProperty(exports, "__esModule", { value: true });
495
+ Object.defineProperty(exports, "__esModule", ({ value: true }));
577
496
  __exportStar(__webpack_require__(/*! ./logger */ "./src/logger/logger.ts"), exports);
578
497
 
579
498
 
@@ -583,12 +502,10 @@ __exportStar(__webpack_require__(/*! ./logger */ "./src/logger/logger.ts"), expo
583
502
  /*!******************************!*\
584
503
  !*** ./src/logger/logger.ts ***!
585
504
  \******************************/
586
- /*! no static exports found */
587
- /***/ (function(module, exports, __webpack_require__) {
505
+ /***/ ((__unused_webpack_module, exports, __webpack_require__) => {
588
506
 
589
- "use strict";
590
507
 
591
- Object.defineProperty(exports, "__esModule", { value: true });
508
+ Object.defineProperty(exports, "__esModule", ({ value: true }));
592
509
  exports.logger = void 0;
593
510
  const client_1 = __webpack_require__(/*! @cdm-logger/client */ "@cdm-logger/client");
594
511
  const appName = (process.env && process.env.APP_NAME) || 'FullStack';
@@ -603,8 +520,7 @@ exports.logger = logger;
603
520
  /*!*********************************!*\
604
521
  !*** external "@apollo/client" ***!
605
522
  \*********************************/
606
- /*! no static exports found */
607
- /***/ (function(module, exports) {
523
+ /***/ ((module) => {
608
524
 
609
525
  module.exports = require("@apollo/client");
610
526
 
@@ -614,8 +530,7 @@ module.exports = require("@apollo/client");
614
530
  /*!*************************************!*\
615
531
  !*** external "@cdm-logger/client" ***!
616
532
  \*************************************/
617
- /*! no static exports found */
618
- /***/ (function(module, exports) {
533
+ /***/ ((module) => {
619
534
 
620
535
  module.exports = require("@cdm-logger/client");
621
536
 
@@ -625,8 +540,7 @@ module.exports = require("@cdm-logger/client");
625
540
  /*!*************************************!*\
626
541
  !*** external "@common-stack/core" ***!
627
542
  \*************************************/
628
- /*! no static exports found */
629
- /***/ (function(module, exports) {
543
+ /***/ ((module) => {
630
544
 
631
545
  module.exports = require("@common-stack/core");
632
546
 
@@ -636,8 +550,7 @@ module.exports = require("@common-stack/core");
636
550
  /*!****************************!*\
637
551
  !*** external "inversify" ***!
638
552
  \****************************/
639
- /*! no static exports found */
640
- /***/ (function(module, exports) {
553
+ /***/ ((module) => {
641
554
 
642
555
  module.exports = require("inversify");
643
556
 
@@ -647,8 +560,7 @@ module.exports = require("inversify");
647
560
  /*!*************************!*\
648
561
  !*** external "lodash" ***!
649
562
  \*************************/
650
- /*! no static exports found */
651
- /***/ (function(module, exports) {
563
+ /***/ ((module) => {
652
564
 
653
565
  module.exports = require("lodash");
654
566
 
@@ -658,12 +570,46 @@ module.exports = require("lodash");
658
570
  /*!************************!*\
659
571
  !*** external "react" ***!
660
572
  \************************/
661
- /*! no static exports found */
662
- /***/ (function(module, exports) {
573
+ /***/ ((module) => {
663
574
 
664
575
  module.exports = require("react");
665
576
 
666
577
  /***/ })
667
578
 
668
- /******/ });
579
+ /******/ });
580
+ /************************************************************************/
581
+ /******/ // The module cache
582
+ /******/ var __webpack_module_cache__ = {};
583
+ /******/
584
+ /******/ // The require function
585
+ /******/ function __webpack_require__(moduleId) {
586
+ /******/ // Check if module is in cache
587
+ /******/ var cachedModule = __webpack_module_cache__[moduleId];
588
+ /******/ if (cachedModule !== undefined) {
589
+ /******/ return cachedModule.exports;
590
+ /******/ }
591
+ /******/ // Create a new module (and put it into the cache)
592
+ /******/ var module = __webpack_module_cache__[moduleId] = {
593
+ /******/ // no module.id needed
594
+ /******/ // no module.loaded needed
595
+ /******/ exports: {}
596
+ /******/ };
597
+ /******/
598
+ /******/ // Execute the module function
599
+ /******/ __webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);
600
+ /******/
601
+ /******/ // Return the exports of the module
602
+ /******/ return module.exports;
603
+ /******/ }
604
+ /******/
605
+ /************************************************************************/
606
+ /******/
607
+ /******/ // startup
608
+ /******/ // Load entry module and return exports
609
+ /******/ // This entry module is referenced by other modules so it can't be inlined
610
+ /******/ var __webpack_exports__ = __webpack_require__("./src/index.ts");
611
+ /******/ module.exports = __webpack_exports__;
612
+ /******/
613
+ /******/ })()
614
+ ;
669
615
  //# sourceMappingURL=index.js.map
package/lib/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["webpack:///webpack/bootstrap","webpack:///./src/connector/abstract-connector.ts","webpack:///./src/connector/index.ts","webpack:///./src/constants/constants.ts","webpack:///./src/constants/index.ts","webpack:///./src/helpers/apollo-client-test-helper.ts","webpack:///./src/helpers/index.ts","webpack:///./src/index.ts","webpack:///./src/interfaces/connector.ts","webpack:///./src/interfaces/index.ts","webpack:///./src/logger/index.ts","webpack:///./src/logger/logger.ts","webpack:///external \"@apollo/client\"","webpack:///external \"@cdm-logger/client\"","webpack:///external \"@common-stack/core\"","webpack:///external \"inversify\"","webpack:///external \"lodash\"","webpack:///external \"react\""],"names":[],"mappings":";;QAAA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;;QAEA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;;;QAGA;QACA;;QAEA;QACA;;QAEA;QACA;QACA;QACA,0CAA0C,gCAAgC;QAC1E;QACA;;QAEA;QACA;QACA;QACA,wDAAwD,kBAAkB;QAC1E;QACA,iDAAiD,cAAc;QAC/D;;QAEA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA;QACA,yCAAyC,iCAAiC;QAC1E,gHAAgH,mBAAmB,EAAE;QACrI;QACA;;QAEA;QACA;QACA;QACA,2BAA2B,0BAA0B,EAAE;QACvD,iCAAiC,eAAe;QAChD;QACA;QACA;;QAEA;QACA,sDAAsD,+DAA+D;;QAErH;QACA;;;QAGA;QACA;;;;;;;;;;;;;;;;AClFA,wDAA+B;AAI/B,6DAA+D;AAE/D,sEAAkD;AAElD,MAAM,OAAO,GAAG,CAAC,QAAQ,EAAE,SAAS,EAAE,EAAE,CAAC,gBAAO,CAAC,cAAK,CAAC,GAAG,YAAG,CAAC,QAAQ,EAAE,GAAG,CAAC,EAAE,CAAC,kBAAS,CAAC,SAAS,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE,SAAS,CAAC,CAAC;AAC1G,sBAAc,GAAG,EAAE,CAAC;AAGjC,MAAsB,eAAe;IAqCjC;;;;;OAKG;IACH,YACI,OAAsB;IACtB,gCAAgC;IAChC,GAAG,QAAwB;QAE3B,eAAe;QACf,IAAI,CAAC,IAAI,GAAG,OAAO,CAAC,SAAS,EAAE,CAAC,GAAiB,EAAE,EAAE,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;QAChE,IAAI,CAAC,SAAS,GAAG,OAAO,CAAC,SAAS,EAAE,CAAC,GAAiB,EAAE,EAAE,CAAC,GAAG,CAAC,SAAS,CAAC,CAA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O;QACH,MAAM;QACN,gBAAgB;QAChB,QAAQ;QACR,SAAS;KACZ;AACL,CAAC;AA5CY,0BAAkB,sBA4C9B;;;;;;;;;;;;;;;;;;;;;;;;;AC/DD,4HAA4C;;;;;;;;;;;;;;;;;;;;;;;;;ACA5C,oFAAyB;AACzB,0FAA4B;AAC5B,4FAA6B;AAC7B,0FAA4B;AAC5B,sFAA0B;;;;;;;;;;;;;;ACJ1B,iCAAiC;;;;;;;;;;;;;;;;;;;;;;;;;;ACAjC,+FAA4B;;;;;;;;;;;;;;;;;;;;;;;;;ACA5B,qFAAyB;;;;;;;;;;;;;;;;ACAzB,qFAAkD;AAElD,MAAM,OAAO,GAAG,CAAC,OAAO,CAAC,GAAG,IAAI,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,IAAI,WAAW,CAAC;AACrE,MAAM,QAAQ,GAAG,CAAC,OAAO,CAAC,GAAG,IAAI,OAAO,CAAC,GAAG,CAAC,SAAS,CAAC,IAAI,MAAM,CAAC;AAClE,MAAM,MAAM,GAAG,qBAAY,CAAC,MAAM,CAAC,OAAO,EAAE,EAAE,KAAK,EAAE,QAAe,EAAE,CAAC,CAAC;AAE/D,wBAAM;;;;;;;;;;;;ACNf,2C;;;;;;;;;;;ACAA,+C;;;;;;;;;;;ACAA,+C;;;;;;;;;;;ACAA,sC;;;;;;;;;;;ACAA,mC;;;;;;;;;;;ACAA,kC","file":"index.js","sourcesContent":[" \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = \"./src/index.ts\");\n","import * as React from 'react';\nimport { IFeature, IModuleShape, IClientStateConfig, IClientState, ResolverType, ApolloConnectionParamFunc } from '../interfaces';\nimport { IdGetterObj, Resolvers } from '@apollo/client';\nimport { ErrorLink } from '@apollo/client/link/error'\nimport { merge, map, union, without, castArray } from 'lodash';\nimport { ReducersMapObject } from 'redux';\nimport { interfaces, Container } from 'inversify';\n\nconst combine = (features, extractor) => without(union(...map(features, res => castArray(extractor(res)))), undefined);\nexport const featureCatalog = {};\n\n\nexport abstract class AbstractFeature implements IFeature {\n public link: any;\n public errorLink: ErrorLink[];\n public createFetch: any;\n public connectionParam: any;\n public epic: any;\n public reducer: ReducersMapObject[];\n public reduxContext: any;\n public clientStateParams?: IClientStateConfig[];\n public sidebarSegments: any[];\n public routerFactory: any;\n public route: any;\n public navItem: any;\n public navItemRight: any;\n public rootComponentFactory: any[];\n public dataRootComponent: any[];\n public createFetchOptions: any[];\n public stylesInsert: any[];\n public scriptsInsert: any[];\n public catalogInfo: any[];\n public languagesFuncs: any[];\n public data: any[];\n public dataIdFromObject: { [key: string]: (value: any) => string }[];\n public createContainerFunc: Function[];\n public createServiceFunc: Function[];\n public leftMainPanelItems: any;\n public middleMainPanelItems: any;\n public middleMainPanelItemsProps: any;\n public leftFooterItems: any;\n public rightFooterItems: any;\n public middleLowerPanelItems: any;\n public reduxPersistTransforms: any[];\n\n private isContainerLoaded: boolean;\n private services;\n private _container: interfaces.Container;\n\n /**\n * Constructs Client feature module representation, that folds all the feature modules\n * into a single module represented by this instance.\n * @param feature\n * @param features\n */\n constructor(\n feature?: IModuleShape,\n // tslint:disable:trailing-comma\n ...features: IModuleShape[]\n ) {\n // Connectivity\n this.link = combine(arguments, (arg: IModuleShape) => arg.link);\n this.errorLink = combine(arguments, (arg: IModuleShape) => arg.errorLink);\n\n this.createFetch = combine(arguments, (arg: IModuleShape) => arg.createFetch)\n .slice(-1)\n .pop();\n this.connectionParam = combine(arguments, (arg: IModuleShape) => arg.connectionParam);\n\n // State management\n this.reducer = combine(arguments, (arg: IModuleShape) => arg.reducer);\n // Client side schema for apollo-link-state\n this.clientStateParams = combine(arguments, (arg: IModuleShape) => arg.clientStateParams);\n\n // Epic actions\n this.epic = combine(arguments, (arg: IModuleShape) => arg.epic);\n\n\n this.sidebarSegments = combine(arguments, (arg: IModuleShape) => arg.sidebarSegments);\n\n this.leftMainPanelItems = combine(arguments, (arg: IModuleShape) => arg.leftMainPanelItems);\n this.middleMainPanelItems = combine(arguments, (arg: IModuleShape) => arg.middleMainPanelItems);\n this.middleMainPanelItemsProps = combine(arguments, (arg: IModuleShape) => arg.middleMainPanelItemsProps);\n this.leftFooterItems = combine(arguments, (arg: IModuleShape) => arg.leftFooterItems);\n this.rightFooterItems = combine(arguments, (arg: IModuleShape) => arg.rightFooterItems);\n this.middleLowerPanelItems = combine(arguments, (arg: IModuleShape) => arg.middleLowerPanelItems);\n this.dataIdFromObject = combine(arguments, (arg: IModuleShape) => arg.dataIdFromObject);\n\n\n this.navItem = combine(arguments, (arg: IModuleShape) => arg.navItem);\n this.navItemRight = combine(arguments, (arg: IModuleShape) => arg.navItemRight);\n\n // UI provider-components\n this.rootComponentFactory = combine(arguments, (arg: IModuleShape) => arg.rootComponentFactory);\n this.dataRootComponent = combine(arguments, (arg: IModuleShape) => arg.dataRootComponent);\n\n // UI provider-components\n this.languagesFuncs = combine(arguments, (arg: IModuleShape) => arg.languagesFuncs);\n\n // container\n this.createContainerFunc = combine(arguments, arg => arg.createContainerFunc);\n\n // services\n this.createServiceFunc = combine(arguments, arg => arg.createServiceFunc);\n\n // TODO: Use React Helmet for those. Low level DOM manipulation\n this.stylesInsert = combine(arguments, (arg: IModuleShape) => arg.stylesInsert);\n this.scriptsInsert = combine(arguments, (arg: IModuleShape) => arg.scriptsInsert);\n this.reduxPersistTransforms = combine(arguments, (arg: IModuleShape) => arg.reduxPersistTransforms);\n\n\n // Shared modules data\n this.data = combine([{}].concat(Array.from(arguments)), arg => arg.data)\n .reduce(\n (acc, el) => [{ ...acc[0], ...el }],\n [{}],\n );\n }\n\n private get container(): interfaces.Container {\n if (!this._container) {\n this._container = new Container();\n }\n return this._container;\n }\n\n public get epics() {\n return this.epic;\n }\n\n public getRouter(withRoot?: boolean, rootComponent?: any) {\n return this.routerFactory(this.getRoutes());\n }\n\n public abstract getRoutes(searchPath?: RegExp);\n\n public abstract get navItems();\n\n public abstract get navItemsRight();\n\n get reducers() {\n return merge({}, ...(this.reducer || []));\n }\n\n public createContainers(options): interfaces.Container {\n // only create once\n if (this.isContainerLoaded) {\n return this.container;\n }\n this.createContainerFunc.map(createModule => {\n this.container.load(createModule(options));\n });\n this.isContainerLoaded = true;\n return this.container;\n }\n\n public createService(options, updateOptions) {\n // only create once\n if (this.services) {\n return this.services;\n }\n try {\n if (!this.isContainerLoaded) {\n this.createContainers(options);\n }\n this.services = merge({}, ...this.createServiceFunc.map(serviceFunc => serviceFunc(this.container)));\n return this.services;\n } catch (err) {\n throw err;\n }\n }\n\n public getStateParams(args: { resolverContex?: any } = {}) {\n const cn = this.container;\n return this.clientStateParams.reduce<IClientState>(function (acc, curr: IClientStateConfig) {\n const defs = curr.typeDefs ? Array.isArray(curr.typeDefs) ? curr.typeDefs : [curr.typeDefs] : [];\n const preLinksAccumulator = acc.preLinks || [];\n const attemptFuncAccumulator = acc.retryLinkAttemptFuncs || [];\n const connectionParamsFuncAccumulator = acc.connectionParams || [];\n const callbackBackFuncAccumulator = acc.connectionCallbackFuncs || [];\n const attemptDefaults = acc.defaults || [];\n const schema = defs.map(typeDef => {\n if (typeof typeDef === 'string') {\n return typeDef;\n }\n console.warn(`Not supported AST format `, typeDef);\n })\n .map(str => str.trim())\n .join('\\n');\n const typeDefs = acc.typeDefs ? acc.typeDefs.concat('\\n', schema) : schema;\n const defaults = curr.defaults ? attemptDefaults.concat(curr.defaults) : attemptDefaults;\n const resolvers = merge(acc.resolvers, consoldidatedResolvers(curr.resolvers, args.resolverContex)) as Resolvers;\n const possibleTypes = merge(acc.possibleTypes, curr.possibleTypes);\n const typePolicies = merge(acc.typePolicies, curr.typePolicies);\n const retryLinkAttemptFuncs = curr.retryLinkAttemptFuncs ? attemptFuncAccumulator.concat(curr.retryLinkAttemptFuncs || []) : attemptFuncAccumulator;\n const preLinks = preLinksAccumulator.concat((curr.preLinkFuncs || []).map(linkF => linkF(cn)) || []);\n const connectionParams = curr.connectionParam ? connectionParamsFuncAccumulator.concat(consoldidatedConnection(curr.connectionParam, cn)) : connectionParamsFuncAccumulator;\n const connectionCallbackFuncs = curr.connectionCallbackFunc ? callbackBackFuncAccumulator.concat(curr.connectionCallbackFunc(cn) || []) : callbackBackFuncAccumulator;\n return {\n defaults,\n resolvers,\n typeDefs,\n possibleTypes,\n retryLinkAttemptFuncs,\n preLinks,\n typePolicies,\n connectionParams,\n connectionCallbackFuncs\n };\n }, {} as IClientState);\n }\n\n\n get connectionParams() {\n return this.connectionParam;\n }\n\n get stylesInserts() {\n return this.stylesInsert;\n }\n\n get scriptsInserts() {\n return this.scriptsInsert;\n }\n\n get leftMainPanel() {\n return merge({}, ...(this.leftMainPanelItems || []));\n }\n\n get middleMainPanel() {\n const panelObj = merge({}, ...(this.middleMainPanelItems || []));\n const withProps = {} as any;\n Object.keys(panelObj).forEach(key => {\n const props = this.middleMainPanelItemsProps.filter(el => !!el[key]);\n let mergedProps = [];\n props.forEach(el => {\n const insideEl = el[key];\n Object.keys(insideEl).forEach(item => {\n if (mergedProps[item]) {\n mergedProps[item] = [...mergedProps[item], ...insideEl[item]];\n } else {\n mergedProps = { ...mergedProps, [item]: insideEl[item] };\n }\n });\n });\n return withProps[key] = React.cloneElement(\n panelObj[key],\n mergedProps,\n );\n });\n return withProps;\n }\n\n get leftFooter() {\n return this.leftFooterItems;\n }\n\n get rightFooter() {\n return this.rightFooterItems;\n }\n\n get middleLowerPanel() {\n return merge({}, ...(this.middleLowerPanelItems || []));\n }\n\n get reduxPersistStateTransformers() {\n return this.reduxPersistTransforms\n }\n\n public getDataIdFromObject(result: { [key: string]: string | number, __typename?: string } | IdGetterObj) {\n const dataIdFromObject = merge({}, ...this.dataIdFromObject);\n if (dataIdFromObject[result.__typename]) {\n return dataIdFromObject[result.__typename](result);\n }\n return result.id || (result as any)._id;\n }\n\n public abstract getWrappedRoot(root, req);\n\n public abstract getDataRoot(root);\n\n public abstract registerLanguages(monaco);\n}\n\nfunction consoldidatedResolvers(resolvers: ResolverType, context): Resolvers {\n let finalResolvers;\n if (Array.isArray(resolvers)) {\n const resolverObject = (resolvers as (object[])).map(resolver => {\n return typeof resolver === 'function'\n ? resolver(context)\n : resolver;\n });\n finalResolvers = merge({}, ...resolverObject);\n } else {\n finalResolvers = typeof resolvers === 'function'\n ? resolvers(context)\n : resolvers;\n }\n\n return finalResolvers;\n}\n\nasync function consoldidatedConnection(connectionParams: ApolloConnectionParamFunc, context): Promise<any> {\n let finalConnectionParams;\n if (Array.isArray(connectionParams)) {\n throw new Error('Array is not supported for ConnectionParams')\n } else {\n finalConnectionParams = typeof connectionParams === 'function'\n ? await connectionParams(context)\n : connectionParams;\n }\n\n return finalConnectionParams;\n}\n\n","export * from './abstract-connector';\n","import { ClientTypes, ElectronTypes } from '@common-stack/core';\n\nexport {\n ElectronTypes,\n ClientTypes,\n}\n\nexport const REDUX_PERSIST_KEY = 'root'; \n","export * from './constants';\n","import { ApolloClient, ApolloClientOptions, InMemoryCache } from '@apollo/client';\nimport { interfaces } from 'inversify';\nimport { logger } from '@cdm-logger/client';\nimport { IFeature } from '../interfaces';\nimport { ClientTypes } from '../constants';\n\nclass UtilityClass {\n constructor(private modules) {\n }\n public getCacheKey(storeObj) {\n return this.modules.getDataIdFromObject(storeObj);\n }\n}\n\n\n/**\n * Helper method to produce ApolloClient and Services from the feeded Feature Module.\n * @param modules \n */\nexport const apolloClientHelper = (modules: IFeature) => {\n const clientState = modules.getStateParams({ resolverContex: () => modules.createService({}, {}) });\n\n const dataIdFromObject = (result) => modules.getDataIdFromObject(result);\n const cache = new InMemoryCache({\n dataIdFromObject,\n possibleTypes: clientState.possibleTypes\n });\n\n const schema = ``;\n\n const params: ApolloClientOptions<any> = {\n cache,\n queryDeduplication: true,\n typeDefs: schema.concat(<string>clientState.typeDefs),\n resolvers: clientState.resolvers as any,\n };\n const client = new ApolloClient(params);\n clientState.defaults.map(x => {\n if (x.type === 'query') {\n cache.writeQuery(x);\n } else if (x.type === 'fragment') {\n cache.writeFragment(x);\n }\n });\n\n const utility = new UtilityClass(modules);\n\n // additional bindings to container\n const container: interfaces.Container = modules.createContainers({});\n container.bind(ClientTypes.Logger).toConstantValue(logger);\n container.bind(ClientTypes.UtilityClass).toConstantValue(utility);\n container.bind(ClientTypes.ApolloClient).toConstantValue(client);\n container.bind(ClientTypes.InMemoryCache).toConstantValue(cache);\n const services = modules.createService({}, {});\n (client as any).container = services;\n\n\n return {\n client,\n dataIdFromObject,\n services,\n container,\n }\n}\n\n\n\n","export * from './apollo-client-test-helper';\n","export * from './logger';\nexport * from './connector';\nexport * from './interfaces';\nexport * from './constants';\nexport * from './helpers';","// tslint:disable:max-line-length\n\nimport { Resolvers, IdGetterObj, PossibleTypesMap, TypePolicies, Operation, ApolloLink, ApolloClientOptions } from '@apollo/client';\nimport { interfaces } from 'inversify';\nimport { Cache } from '@apollo/client/cache';\nimport { ReducersMapObject } from 'redux';\nimport { ErrorLink } from '@apollo/client/link/error';\nimport { ConnectionParams } from 'subscriptions-transport-ws';\n\nexport type ResolverType = Resolvers | Resolvers[] | ((service: any) => Resolvers) | ((service: any) => Resolvers)[] | ((service: any) => any) | ((service: any) => any)[];\nexport type ApolloLinkFunc = (container: interfaces.Container) => ApolloLink;\nexport type ApolloConnectionParamFunc = ((container: interfaces.Container) => ConnectionParams) | ConnectionParams ;\nexport type IWSConnectionCallbackFunc = (webSocket: any, error: Error[], result?: any) => void | Promise<void>;\nexport type ApolloWSConnectionCallbackFunc = (container: interfaces.Container) => IWSConnectionCallbackFunc;\n\ntype IRetryLinkAttemptFuncs = (count: number, operation: Operation, error: any) => boolean | Promise<boolean>;\ntype IClientStateQueryDefault<T, V> = {\n type: 'query',\n} & Cache.WriteQueryOptions<T, V>;\n\ntype IClientStateFragmentDefault<T, V> = {\n type: 'fragment',\n} & Cache.WriteFragmentOptions<T, V>;\n\nexport type IClientStateDefault<T = unknown, V = unknown> = IClientStateFragmentDefault<T,V> | IClientStateQueryDefault<T,V>;\nexport interface IClientStateConfig {\n resolvers?: ResolverType; // don't need `Resolvers` type as it may conflict with the usage\n defaults?: IClientStateDefault[];\n typeDefs?: string | string[];\n possibleTypes?: PossibleTypesMap;\n typePolicies?: TypePolicies;\n // retries the request if function returns true\n retryLinkAttemptFuncs?: IRetryLinkAttemptFuncs;\n /**\n * @param preLinkFuncs all `apollo-link` that need to be composed before the network link. Should be a function.\n * @inheritdoc https://www.apollographql.com/docs/react/api/link/introduction/\n */\n preLinkFuncs?: ApolloLinkFunc[];\n /**\n * @param connectionParam To provide connectionParam to `WebSocketLink`. It takes a single `Object` or a `Function`.\n * @inheritdoc https://www.apollographql.com/docs/react/api/link/apollo-link-ws/\n */\n connectionParam?: ApolloConnectionParamFunc;\n /**\n * @param connectionCallback Accept only one function for all modules.\n * @inheritdoc\n */\n connectionCallbackFunc?: ApolloWSConnectionCallbackFunc;\n \n}\n\nexport interface IClientState {\n resolvers?: Resolvers; // don't need `Resolvers` type as it may conflict with the usage\n defaults: IClientStateDefault[];\n typeDefs?: string | string[];\n possibleTypes?: PossibleTypesMap;\n retryLinkAttemptFuncs?: IRetryLinkAttemptFuncs[];\n typePolicies?: TypePolicies,\n preLinks: ApolloLink[];\n connectionParams: ConnectionParams[];\n connectionCallbackFuncs?: IWSConnectionCallbackFunc[];\n}\n\n/**\n * ModuleShape have optional configuration to be implemented by all the feature modules\n * in the application.\n */\nexport interface IModuleShape {\n /**\n * @param link all `apollo-link` that need to be composed.\n * @inheritdoc https://github.com/apollographql/apollo-link\n * @deprecated use ClientStateParms.preLinkFuncs\n */\n readonly link?: any;\n /**\n * @param errorLink compose all errorLink\n * @inheritdoc https://github.com/apollographql/apollo-link/tree/master/packages/apollo-link-error\n */\n readonly errorLink?: ErrorLink | ErrorLink[];\n readonly createFetch?: any;\n /**\n * @param connectionParam method that called when a client connects to the socket.\n * @inheritdoc https://github.com/apollographql/subscriptions-transport-ws#constructorurl-options-connectioncallback\n * @deprecated use clientStateParams\n */\n readonly connectionParam?: any;\n /**\n * @param epic all `epics` that need to be composed.\n * @inheritdoc https://redux-observable.js.org/docs/basics/Epics.html\n */\n readonly epic?: any;\n /**\n * @param reducer Redux reducers list\n */\n readonly reducer?: ReducersMapObject | ReducersMapObject[];\n /**\n * @param clientStateParams Client side configuration of `apollo-client`\n * @inheritdoc https://github.com/apollographql/apollo-client/tree/2d65da133c156f6d808e64aee7e7fd5f7cc71d7f\n */\n readonly clientStateParams?: IClientStateConfig | IClientStateConfig[];\n /**\n * @param dataIdFromObject A function that returns an object identifier given an particular result\n * object.\n * @inheritdoc https://github.com/apollographql/apollo-client/tree/ed66999bac40226abfeada8d6c83b454636bb4b0/packages/apollo-cache-inmemory#configuration\n */\n readonly dataIdFromObject?: { [key: string]: (value: any) => string } | { [key: string]: (value: any) => string }[] | IdGetterObj;\n /**\n * @param createContainerFunc Synchronous Container Modules of inversify.\n * @inheritdoc https://github.com/inversify/InversifyJS/blob/master/wiki/container_modules.md\n */\n readonly createContainerFunc?: Function | Function[];\n /**\n * @param createServiceFunc Services\n */\n readonly createServiceFunc?: Function | Function[];\n readonly sidebarSegments?: any;\n readonly routerFactory?: any;\n /**\n * @param route Route list\n */\n readonly route?: any;\n /**\n * @param navItem Top left navigation links\n */\n readonly navItem?: any;\n /**\n * @param navItemRightTop right navigation links\n */\n readonly navItemRight?: any;\n /**\n * @param rootComponentFactory Root component factory list\n */\n readonly rootComponentFactory?: any;\n /**\n * @param dataRootComponent Data root React elements list (data root elements wraps data fetching react subtree root)\n */\n readonly dataRootComponent?: any;\n readonly createFetchOptions?: any;\n /**\n * @param stylesInsert URL list to 3rd party css scripts\n */\n readonly stylesInsert?: any;\n /**\n * @param scriptsInsert URL list to 3rd party js scripts\n */\n readonly scriptsInsert?: any;\n /**\n * @deprecated\n */\n readonly catalogInfo?: any;\n /**\n * @deprecated\n */\n readonly languagesFuncs?: any;\n /**\n * @param leftMainPanelItems Components that will be placed left panel.\n */\n readonly leftMainPanelItems?: any;\n /**\n * @param middleMainPanelItems Components that will be placed middle center panel\n */\n readonly middleMainPanelItems?: any;\n /**\n * @param middleMainPanelItemsProps Props of the component that will be placed middle center panel\n */\n readonly middleMainPanelItemsProps?: any;\n /**\n * @param leftFooterItems Components that will be placed left footer panel\n */\n readonly leftFooterItems?: any;\n /**\n * @param rightFooterItems Components that will be placed right footer panel\n */\n readonly rightFooterItems?: any;\n /**\n * @param middleLowerPanelItems Components that will be placed below middle panel\n */\n readonly middleLowerPanelItems?: any;\n\n readonly reduxPersistTransforms?: any[];\n\n}\n\n\n/**\n * Feature module methods\n */\nexport interface IFeature extends IModuleShape {\n // Public variables\n readonly data: any[];\n\n /**\n * @returns Redux-Observable Epics\n */\n readonly epics;\n\n readonly getRouter;\n /**\n * @returns client-side React route components list\n */\n readonly getRoutes;\n\n /**\n * @returns client-side top left navbar link component list\n */\n readonly navItems;\n /**\n * @returns client-side top right navbar link component list\n */\n readonly navItemsRight;\n /**\n * @returns Redux reducers\n */\n readonly reducers;\n\n readonly connectionParams;\n\n /**\n * @returns URL list to 3rd party css styles\n */\n readonly stylesInserts;\n /**\n * @returns URL list to 3rd party js styles\n */\n readonly scriptsInserts;\n\n readonly leftMainPanel;\n readonly middleMainPanel;\n readonly leftFooter;\n readonly rightFooter;\n readonly middleLowerPanel;\n readonly dataIdFromObject;\n\n /**\n * @param args Options to pass to each Container Module\n * @returns Created container and binds all the container modules\n */\n createContainers(args);\n\n\n createService(options, updateOptions);\n /**\n * @param args Provide resolverContext which can be passed to all resolver functions.\n * @returns IClientState\n */\n getStateParams(args?: { resolverContex?: any }): IClientState;\n\n getDataIdFromObject(result: {\n [key: string]: string | number;\n __typename?: string;\n } | IdGetterObj): any;\n /**\n * @arguments root React tree root component\n * @arguments req Http Request\n * @returns React tree root component wrapped up by root components exposed by this module\n */\n getWrappedRoot(root: any, req?: any): any;\n /**\n * @param root React tree data root component (first React root components which is used for fetching data)\n *\n * @returns React tree data root component wrapped up by data root components exposed by this module\n */\n getDataRoot(root: any): any;\n registerLanguages(monaco): void;\n}\n","export * from './connector';\n","export * from './logger';\n","import { ClientLogger } from '@cdm-logger/client';\n\nconst appName = (process.env && process.env.APP_NAME) || 'FullStack';\nconst logLevel = (process.env && process.env.LOG_LEVEL) || 'info';\nconst logger = ClientLogger.create(appName, { level: logLevel as any });\n\nexport { logger };\n","module.exports = require(\"@apollo/client\");","module.exports = require(\"@cdm-logger/client\");","module.exports = require(\"@common-stack/core\");","module.exports = require(\"inversify\");","module.exports = require(\"lodash\");","module.exports = require(\"react\");"],"sourceRoot":""}
1
+ {"version":3,"file":"index.js","mappings":";;;;;;;;;;;;;AAAA,wDAA+B;AAI/B,6DAA+D;AAE/D,sEAAkD;AAElD,MAAM,OAAO,GAAG,CAAC,QAAQ,EAAE,SAAS,EAAE,EAAE,CAAC,oBAAO,EAAC,kBAAK,EAAC,GAAG,gBAAG,EAAC,QAAQ,EAAE,GAAG,CAAC,EAAE,CAAC,sBAAS,EAAC,SAAS,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,EAAE,SAAS,CAAC,CAAC;AAC1G,sBAAc,GAAG,EAAE,CAAC;AAGjC,MAAsB,eAAe;IAqCjC;;;;;OAKG;IACH,YACI,OAAsB;IACtB,gCAAgC;IAChC,GAAG,QAAwB;QAE3B,eAAe;QACf,IAAI,CAAC,IAAI,GAAG,OAAO,CAAC,SAAS,EAAE,CAAC,GAAiB,EAAE,EAAE,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;QAChE,IAAI,CAAC,SAAS,GAAG,OAAO,CAAC,SAAS,EAAE,CAAC,GAAiB,EAAE,EAAE,CAAC,GAAG,CAAC,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AG,QAAQ,CAAC;IAGrC,OAAO;QACH,MAAM;QACN,gBAAgB;QAChB,QAAQ;QACR,SAAS;KACZ;AACL,CAAC;AA5CY,0BAAkB,sBA4C9B;;;;;;;;;;;;;;;;;;;;;;;;;;;AC/DD,4HAA4C;;;;;;;;;;;;;;;;;;;;;;;;;;;ACA5C,oFAAyB;AACzB,0FAA4B;AAC5B,4FAA6B;AAC7B,0FAA4B;AAC5B,sFAA0B;;;;;;;;;;;;ACJ1B,iCAAiC;;;;;;;;;;;;;;;;;;;;;;;;;;;;ACAjC,+FAA4B;;;;;;;;;;;;;;;;;;;;;;;;;;;ACA5B,qFAAyB;;;;;;;;;;;;;;ACAzB,qFAAkD;AAElD,MAAM,OAAO,GAAG,CAAC,OAAO,CAAC,GAAG,IAAI,OAAO,CAAC,GAAG,CAAC,QAAQ,CAAC,IAAI,WAAW,CAAC;AACrE,MAAM,QAAQ,GAAG,CAAC,OAAO,CAAC,GAAG,IAAI,OAAO,CAAC,GAAG,CAAC,SAAS,CAAC,IAAI,MAAM,CAAC;AAClE,MAAM,MAAM,GAAG,qBAAY,CAAC,MAAM,CAAC,OAAO,EAAE,EAAE,KAAK,EAAE,QAAe,EAAE,CAAC,CAAC;AAE/D,wBAAM;;;;;;;;;;;ACNf;;;;;;;;;;ACAA;;;;;;;;;;ACAA;;;;;;;;;;ACAA;;;;;;;;;;ACAA;;;;;;;;;;ACAA;;;;;;UCAA;UACA;;UAEA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;UACA;;UAEA;UACA;;UAEA;UACA;UACA;;;;UEtBA;UACA;UACA;UACA","sources":["webpack://@common-stack/client-core/./src/connector/abstract-connector.ts","webpack://@common-stack/client-core/./src/connector/index.ts","webpack://@common-stack/client-core/./src/constants/constants.ts","webpack://@common-stack/client-core/./src/constants/index.ts","webpack://@common-stack/client-core/./src/helpers/apollo-client-test-helper.ts","webpack://@common-stack/client-core/./src/helpers/index.ts","webpack://@common-stack/client-core/./src/index.ts","webpack://@common-stack/client-core/./src/interfaces/connector.ts","webpack://@common-stack/client-core/./src/interfaces/index.ts","webpack://@common-stack/client-core/./src/logger/index.ts","webpack://@common-stack/client-core/./src/logger/logger.ts","webpack://@common-stack/client-core/external commonjs \"@apollo/client\"","webpack://@common-stack/client-core/external commonjs \"@cdm-logger/client\"","webpack://@common-stack/client-core/external commonjs \"@common-stack/core\"","webpack://@common-stack/client-core/external commonjs \"inversify\"","webpack://@common-stack/client-core/external commonjs \"lodash\"","webpack://@common-stack/client-core/external commonjs \"react\"","webpack://@common-stack/client-core/webpack/bootstrap","webpack://@common-stack/client-core/webpack/before-startup","webpack://@common-stack/client-core/webpack/startup","webpack://@common-stack/client-core/webpack/after-startup"],"sourcesContent":["import * as React from 'react';\nimport { IFeature, IModuleShape, IClientStateConfig, IClientState, ResolverType, ApolloConnectionParamFunc } from '../interfaces';\nimport { IdGetterObj, Resolvers } from '@apollo/client';\nimport { ErrorLink } from '@apollo/client/link/error'\nimport { merge, map, union, without, castArray } from 'lodash';\nimport { ReducersMapObject } from 'redux';\nimport { interfaces, Container } from 'inversify';\n\nconst combine = (features, extractor) => without(union(...map(features, res => castArray(extractor(res)))), undefined);\nexport const featureCatalog = {};\n\n\nexport abstract class AbstractFeature implements IFeature {\n public link: any;\n public errorLink: ErrorLink[];\n public createFetch: any;\n public connectionParam: any;\n public epic: any;\n public reducer: ReducersMapObject[];\n public reduxContext: any;\n public clientStateParams?: IClientStateConfig[];\n public sidebarSegments: any[];\n public routerFactory: any;\n public route: any;\n public navItem: any;\n public navItemRight: any;\n public rootComponentFactory: any[];\n public dataRootComponent: any[];\n public createFetchOptions: any[];\n public stylesInsert: any[];\n public scriptsInsert: any[];\n public catalogInfo: any[];\n public languagesFuncs: any[];\n public data: any[];\n public dataIdFromObject: { [key: string]: (value: any) => string }[];\n public createContainerFunc: Function[];\n public createServiceFunc: Function[];\n public leftMainPanelItems: any;\n public middleMainPanelItems: any;\n public middleMainPanelItemsProps: any;\n public leftFooterItems: any;\n public rightFooterItems: any;\n public middleLowerPanelItems: any;\n public reduxPersistTransforms: any[];\n\n private isContainerLoaded: boolean;\n private services;\n private _container: interfaces.Container;\n\n /**\n * Constructs Client feature module representation, that folds all the feature modules\n * into a single module represented by this instance.\n * @param feature\n * @param features\n */\n constructor(\n feature?: IModuleShape,\n // tslint:disable:trailing-comma\n ...features: IModuleShape[]\n ) {\n // Connectivity\n this.link = combine(arguments, (arg: IModuleShape) => arg.link);\n this.errorLink = combine(arguments, (arg: IModuleShape) => arg.errorLink);\n\n this.createFetch = combine(arguments, (arg: IModuleShape) => arg.createFetch)\n .slice(-1)\n .pop();\n this.connectionParam = combine(arguments, (arg: IModuleShape) => arg.connectionParam);\n\n // State management\n this.reducer = combine(arguments, (arg: IModuleShape) => arg.reducer);\n // Client side schema for apollo-link-state\n this.clientStateParams = combine(arguments, (arg: IModuleShape) => arg.clientStateParams);\n\n // Epic actions\n this.epic = combine(arguments, (arg: IModuleShape) => arg.epic);\n\n\n this.sidebarSegments = combine(arguments, (arg: IModuleShape) => arg.sidebarSegments);\n\n this.leftMainPanelItems = combine(arguments, (arg: IModuleShape) => arg.leftMainPanelItems);\n this.middleMainPanelItems = combine(arguments, (arg: IModuleShape) => arg.middleMainPanelItems);\n this.middleMainPanelItemsProps = combine(arguments, (arg: IModuleShape) => arg.middleMainPanelItemsProps);\n this.leftFooterItems = combine(arguments, (arg: IModuleShape) => arg.leftFooterItems);\n this.rightFooterItems = combine(arguments, (arg: IModuleShape) => arg.rightFooterItems);\n this.middleLowerPanelItems = combine(arguments, (arg: IModuleShape) => arg.middleLowerPanelItems);\n this.dataIdFromObject = combine(arguments, (arg: IModuleShape) => arg.dataIdFromObject);\n\n\n this.navItem = combine(arguments, (arg: IModuleShape) => arg.navItem);\n this.navItemRight = combine(arguments, (arg: IModuleShape) => arg.navItemRight);\n\n // UI provider-components\n this.rootComponentFactory = combine(arguments, (arg: IModuleShape) => arg.rootComponentFactory);\n this.dataRootComponent = combine(arguments, (arg: IModuleShape) => arg.dataRootComponent);\n\n // UI provider-components\n this.languagesFuncs = combine(arguments, (arg: IModuleShape) => arg.languagesFuncs);\n\n // container\n this.createContainerFunc = combine(arguments, arg => arg.createContainerFunc);\n\n // services\n this.createServiceFunc = combine(arguments, arg => arg.createServiceFunc);\n\n // TODO: Use React Helmet for those. Low level DOM manipulation\n this.stylesInsert = combine(arguments, (arg: IModuleShape) => arg.stylesInsert);\n this.scriptsInsert = combine(arguments, (arg: IModuleShape) => arg.scriptsInsert);\n this.reduxPersistTransforms = combine(arguments, (arg: IModuleShape) => arg.reduxPersistTransforms);\n\n\n // Shared modules data\n this.data = combine([{}].concat(Array.from(arguments)), arg => arg.data)\n .reduce(\n (acc, el) => [{ ...acc[0], ...el }],\n [{}],\n );\n }\n\n private get container(): interfaces.Container {\n if (!this._container) {\n this._container = new Container();\n }\n return this._container;\n }\n\n public get epics() {\n return this.epic;\n }\n\n public getRouter(withRoot?: boolean, rootComponent?: any) {\n return this.routerFactory(this.getRoutes());\n }\n\n public abstract getRoutes(searchPath?: RegExp);\n\n public abstract get navItems();\n\n public abstract get navItemsRight();\n\n get reducers() {\n return merge({}, ...(this.reducer || []));\n }\n\n public createContainers(options): interfaces.Container {\n // only create once\n if (this.isContainerLoaded) {\n return this.container;\n }\n this.createContainerFunc.map(createModule => {\n this.container.load(createModule(options));\n });\n this.isContainerLoaded = true;\n return this.container;\n }\n\n public createService(options, updateOptions) {\n // only create once\n if (this.services) {\n return this.services;\n }\n try {\n if (!this.isContainerLoaded) {\n this.createContainers(options);\n }\n this.services = merge({}, ...this.createServiceFunc.map(serviceFunc => serviceFunc(this.container)));\n return this.services;\n } catch (err) {\n throw err;\n }\n }\n\n public getStateParams(args: { resolverContex?: any } = {}) {\n const cn = this.container;\n return this.clientStateParams.reduce<IClientState>(function (acc, curr: IClientStateConfig) {\n const defs = curr.typeDefs ? Array.isArray(curr.typeDefs) ? curr.typeDefs : [curr.typeDefs] : [];\n const preLinksAccumulator = acc.preLinks || [];\n const attemptFuncAccumulator = acc.retryLinkAttemptFuncs || [];\n const connectionParamsFuncAccumulator = acc.connectionParams || [];\n const callbackBackFuncAccumulator = acc.connectionCallbackFuncs || [];\n const attemptDefaults = acc.defaults || [];\n const schema = defs.map(typeDef => {\n if (typeof typeDef === 'string') {\n return typeDef;\n }\n console.warn(`Not supported AST format `, typeDef);\n })\n .map(str => str.trim())\n .join('\\n');\n const typeDefs = acc.typeDefs ? acc.typeDefs.concat('\\n', schema) : schema;\n const defaults = curr.defaults ? attemptDefaults.concat(curr.defaults) : attemptDefaults;\n const resolvers = merge(acc.resolvers, consoldidatedResolvers(curr.resolvers, args.resolverContex)) as Resolvers;\n const possibleTypes = merge(acc.possibleTypes, curr.possibleTypes);\n const typePolicies = merge(acc.typePolicies, curr.typePolicies);\n const retryLinkAttemptFuncs = curr.retryLinkAttemptFuncs ? attemptFuncAccumulator.concat(curr.retryLinkAttemptFuncs || []) : attemptFuncAccumulator;\n const preLinks = preLinksAccumulator.concat((curr.preLinkFuncs || []).map(linkF => linkF(cn)) || []);\n const connectionParams = curr.connectionParam ? connectionParamsFuncAccumulator.concat(consoldidatedConnection(curr.connectionParam, cn)) : connectionParamsFuncAccumulator;\n const connectionCallbackFuncs = curr.connectionCallbackFunc ? callbackBackFuncAccumulator.concat(curr.connectionCallbackFunc(cn) || []) : callbackBackFuncAccumulator;\n return {\n defaults,\n resolvers,\n typeDefs,\n possibleTypes,\n retryLinkAttemptFuncs,\n preLinks,\n typePolicies,\n connectionParams,\n connectionCallbackFuncs\n };\n }, {} as IClientState);\n }\n\n\n get connectionParams() {\n return this.connectionParam;\n }\n\n get stylesInserts() {\n return this.stylesInsert;\n }\n\n get scriptsInserts() {\n return this.scriptsInsert;\n }\n\n get leftMainPanel() {\n return merge({}, ...(this.leftMainPanelItems || []));\n }\n\n get middleMainPanel() {\n const panelObj = merge({}, ...(this.middleMainPanelItems || []));\n const withProps = {} as any;\n Object.keys(panelObj).forEach(key => {\n const props = this.middleMainPanelItemsProps.filter(el => !!el[key]);\n let mergedProps = [];\n props.forEach(el => {\n const insideEl = el[key];\n Object.keys(insideEl).forEach(item => {\n if (mergedProps[item]) {\n mergedProps[item] = [...mergedProps[item], ...insideEl[item]];\n } else {\n mergedProps = { ...mergedProps, [item]: insideEl[item] };\n }\n });\n });\n return withProps[key] = React.cloneElement(\n panelObj[key],\n mergedProps,\n );\n });\n return withProps;\n }\n\n get leftFooter() {\n return this.leftFooterItems;\n }\n\n get rightFooter() {\n return this.rightFooterItems;\n }\n\n get middleLowerPanel() {\n return merge({}, ...(this.middleLowerPanelItems || []));\n }\n\n get reduxPersistStateTransformers() {\n return this.reduxPersistTransforms\n }\n\n public getDataIdFromObject(result: { [key: string]: string | number, __typename?: string } | IdGetterObj) {\n const dataIdFromObject = merge({}, ...this.dataIdFromObject);\n if (dataIdFromObject[result.__typename]) {\n return dataIdFromObject[result.__typename](result);\n }\n return result.id || (result as any)._id;\n }\n\n public abstract getWrappedRoot(root, req);\n\n public abstract getDataRoot(root);\n\n public abstract registerLanguages(monaco);\n}\n\nfunction consoldidatedResolvers(resolvers: ResolverType, context): Resolvers {\n let finalResolvers;\n if (Array.isArray(resolvers)) {\n const resolverObject = (resolvers as (object[])).map(resolver => {\n return typeof resolver === 'function'\n ? resolver(context)\n : resolver;\n });\n finalResolvers = merge({}, ...resolverObject);\n } else {\n finalResolvers = typeof resolvers === 'function'\n ? resolvers(context)\n : resolvers;\n }\n\n return finalResolvers;\n}\n\nasync function consoldidatedConnection(connectionParams: ApolloConnectionParamFunc, context): Promise<any> {\n let finalConnectionParams;\n if (Array.isArray(connectionParams)) {\n throw new Error('Array is not supported for ConnectionParams')\n } else {\n finalConnectionParams = typeof connectionParams === 'function'\n ? await connectionParams(context)\n : connectionParams;\n }\n\n return finalConnectionParams;\n}\n\n","export * from './abstract-connector';\n","import { ClientTypes, ElectronTypes } from '@common-stack/core';\n\nexport {\n ElectronTypes,\n ClientTypes,\n}\n\nexport const REDUX_PERSIST_KEY = 'root'; \n","export * from './constants';\n","import { ApolloClient, ApolloClientOptions, InMemoryCache } from '@apollo/client';\nimport { interfaces } from 'inversify';\nimport { logger } from '@cdm-logger/client';\nimport { IFeature } from '../interfaces';\nimport { ClientTypes } from '../constants';\n\nclass UtilityClass {\n constructor(private modules) {\n }\n public getCacheKey(storeObj) {\n return this.modules.getDataIdFromObject(storeObj);\n }\n}\n\n\n/**\n * Helper method to produce ApolloClient and Services from the feeded Feature Module.\n * @param modules \n */\nexport const apolloClientHelper = (modules: IFeature) => {\n const clientState = modules.getStateParams({ resolverContex: () => modules.createService({}, {}) });\n\n const dataIdFromObject = (result) => modules.getDataIdFromObject(result);\n const cache = new InMemoryCache({\n dataIdFromObject,\n possibleTypes: clientState.possibleTypes\n });\n\n const schema = ``;\n\n const params: ApolloClientOptions<any> = {\n cache,\n queryDeduplication: true,\n typeDefs: schema.concat(<string>clientState.typeDefs),\n resolvers: clientState.resolvers as any,\n };\n const client = new ApolloClient(params);\n clientState.defaults.map(x => {\n if (x.type === 'query') {\n cache.writeQuery(x);\n } else if (x.type === 'fragment') {\n cache.writeFragment(x);\n }\n });\n\n const utility = new UtilityClass(modules);\n\n // additional bindings to container\n const container: interfaces.Container = modules.createContainers({});\n container.bind(ClientTypes.Logger).toConstantValue(logger);\n container.bind(ClientTypes.UtilityClass).toConstantValue(utility);\n container.bind(ClientTypes.ApolloClient).toConstantValue(client);\n container.bind(ClientTypes.InMemoryCache).toConstantValue(cache);\n const services = modules.createService({}, {});\n (client as any).container = services;\n\n\n return {\n client,\n dataIdFromObject,\n services,\n container,\n }\n}\n\n\n\n","export * from './apollo-client-test-helper';\n","export * from './logger';\nexport * from './connector';\nexport * from './interfaces';\nexport * from './constants';\nexport * from './helpers';","// tslint:disable:max-line-length\n\nimport { Resolvers, IdGetterObj, PossibleTypesMap, TypePolicies, Operation, ApolloLink, ApolloClientOptions } from '@apollo/client';\nimport { interfaces } from 'inversify';\nimport { Cache } from '@apollo/client/cache';\nimport { ReducersMapObject } from 'redux';\nimport { ErrorLink } from '@apollo/client/link/error';\nimport { ConnectionParams } from 'subscriptions-transport-ws';\n\nexport type ResolverType = Resolvers | Resolvers[] | ((service: any) => Resolvers) | ((service: any) => Resolvers)[] | ((service: any) => any) | ((service: any) => any)[];\nexport type ApolloLinkFunc = (container: interfaces.Container) => ApolloLink;\nexport type ApolloConnectionParamFunc = ((container: interfaces.Container) => ConnectionParams) | ConnectionParams ;\nexport type IWSConnectionCallbackFunc = (webSocket: any, error: Error[], result?: any) => void | Promise<void>;\nexport type ApolloWSConnectionCallbackFunc = (container: interfaces.Container) => IWSConnectionCallbackFunc;\n\ntype IRetryLinkAttemptFuncs = (count: number, operation: Operation, error: any) => boolean | Promise<boolean>;\ntype IClientStateQueryDefault<T, V> = {\n type: 'query',\n} & Cache.WriteQueryOptions<T, V>;\n\ntype IClientStateFragmentDefault<T, V> = {\n type: 'fragment',\n} & Cache.WriteFragmentOptions<T, V>;\n\nexport type IClientStateDefault<T = unknown, V = unknown> = IClientStateFragmentDefault<T,V> | IClientStateQueryDefault<T,V>;\nexport interface IClientStateConfig {\n resolvers?: ResolverType; // don't need `Resolvers` type as it may conflict with the usage\n defaults?: IClientStateDefault[];\n typeDefs?: string | string[];\n possibleTypes?: PossibleTypesMap;\n typePolicies?: TypePolicies;\n // retries the request if function returns true\n retryLinkAttemptFuncs?: IRetryLinkAttemptFuncs;\n /**\n * @param preLinkFuncs all `apollo-link` that need to be composed before the network link. Should be a function.\n * @inheritdoc https://www.apollographql.com/docs/react/api/link/introduction/\n */\n preLinkFuncs?: ApolloLinkFunc[];\n /**\n * @param connectionParam To provide connectionParam to `WebSocketLink`. It takes a single `Object` or a `Function`.\n * @inheritdoc https://www.apollographql.com/docs/react/api/link/apollo-link-ws/\n */\n connectionParam?: ApolloConnectionParamFunc;\n /**\n * @param connectionCallback Accept only one function for all modules.\n * @inheritdoc\n */\n connectionCallbackFunc?: ApolloWSConnectionCallbackFunc;\n \n}\n\nexport interface IClientState {\n resolvers?: Resolvers; // don't need `Resolvers` type as it may conflict with the usage\n defaults: IClientStateDefault[];\n typeDefs?: string | string[];\n possibleTypes?: PossibleTypesMap;\n retryLinkAttemptFuncs?: IRetryLinkAttemptFuncs[];\n typePolicies?: TypePolicies,\n preLinks: ApolloLink[];\n connectionParams: ConnectionParams[];\n connectionCallbackFuncs?: IWSConnectionCallbackFunc[];\n}\n\n/**\n * ModuleShape have optional configuration to be implemented by all the feature modules\n * in the application.\n */\nexport interface IModuleShape {\n /**\n * @param link all `apollo-link` that need to be composed.\n * @inheritdoc https://github.com/apollographql/apollo-link\n * @deprecated use ClientStateParms.preLinkFuncs\n */\n readonly link?: any;\n /**\n * @param errorLink compose all errorLink\n * @inheritdoc https://github.com/apollographql/apollo-link/tree/master/packages/apollo-link-error\n */\n readonly errorLink?: ErrorLink | ErrorLink[];\n readonly createFetch?: any;\n /**\n * @param connectionParam method that called when a client connects to the socket.\n * @inheritdoc https://github.com/apollographql/subscriptions-transport-ws#constructorurl-options-connectioncallback\n * @deprecated use clientStateParams\n */\n readonly connectionParam?: any;\n /**\n * @param epic all `epics` that need to be composed.\n * @inheritdoc https://redux-observable.js.org/docs/basics/Epics.html\n */\n readonly epic?: any;\n /**\n * @param reducer Redux reducers list\n */\n readonly reducer?: ReducersMapObject | ReducersMapObject[];\n /**\n * @param clientStateParams Client side configuration of `apollo-client`\n * @inheritdoc https://github.com/apollographql/apollo-client/tree/2d65da133c156f6d808e64aee7e7fd5f7cc71d7f\n */\n readonly clientStateParams?: IClientStateConfig | IClientStateConfig[];\n /**\n * @param dataIdFromObject A function that returns an object identifier given an particular result\n * object.\n * @inheritdoc https://github.com/apollographql/apollo-client/tree/ed66999bac40226abfeada8d6c83b454636bb4b0/packages/apollo-cache-inmemory#configuration\n */\n readonly dataIdFromObject?: { [key: string]: (value: any) => string } | { [key: string]: (value: any) => string }[] | IdGetterObj;\n /**\n * @param createContainerFunc Synchronous Container Modules of inversify.\n * @inheritdoc https://github.com/inversify/InversifyJS/blob/master/wiki/container_modules.md\n */\n readonly createContainerFunc?: Function | Function[];\n /**\n * @param createServiceFunc Services\n */\n readonly createServiceFunc?: Function | Function[];\n readonly sidebarSegments?: any;\n readonly routerFactory?: any;\n /**\n * @param route Route list\n */\n readonly route?: any;\n /**\n * @param navItem Top left navigation links\n */\n readonly navItem?: any;\n /**\n * @param navItemRightTop right navigation links\n */\n readonly navItemRight?: any;\n /**\n * @param rootComponentFactory Root component factory list\n */\n readonly rootComponentFactory?: any;\n /**\n * @param dataRootComponent Data root React elements list (data root elements wraps data fetching react subtree root)\n */\n readonly dataRootComponent?: any;\n readonly createFetchOptions?: any;\n /**\n * @param stylesInsert URL list to 3rd party css scripts\n */\n readonly stylesInsert?: any;\n /**\n * @param scriptsInsert URL list to 3rd party js scripts\n */\n readonly scriptsInsert?: any;\n /**\n * @deprecated\n */\n readonly catalogInfo?: any;\n /**\n * @deprecated\n */\n readonly languagesFuncs?: any;\n /**\n * @param leftMainPanelItems Components that will be placed left panel.\n */\n readonly leftMainPanelItems?: any;\n /**\n * @param middleMainPanelItems Components that will be placed middle center panel\n */\n readonly middleMainPanelItems?: any;\n /**\n * @param middleMainPanelItemsProps Props of the component that will be placed middle center panel\n */\n readonly middleMainPanelItemsProps?: any;\n /**\n * @param leftFooterItems Components that will be placed left footer panel\n */\n readonly leftFooterItems?: any;\n /**\n * @param rightFooterItems Components that will be placed right footer panel\n */\n readonly rightFooterItems?: any;\n /**\n * @param middleLowerPanelItems Components that will be placed below middle panel\n */\n readonly middleLowerPanelItems?: any;\n\n readonly reduxPersistTransforms?: any[];\n\n}\n\n\n/**\n * Feature module methods\n */\nexport interface IFeature extends IModuleShape {\n // Public variables\n readonly data: any[];\n\n /**\n * @returns Redux-Observable Epics\n */\n readonly epics;\n\n readonly getRouter;\n /**\n * @returns client-side React route components list\n */\n readonly getRoutes;\n\n /**\n * @returns client-side top left navbar link component list\n */\n readonly navItems;\n /**\n * @returns client-side top right navbar link component list\n */\n readonly navItemsRight;\n /**\n * @returns Redux reducers\n */\n readonly reducers;\n\n readonly connectionParams;\n\n /**\n * @returns URL list to 3rd party css styles\n */\n readonly stylesInserts;\n /**\n * @returns URL list to 3rd party js styles\n */\n readonly scriptsInserts;\n\n readonly leftMainPanel;\n readonly middleMainPanel;\n readonly leftFooter;\n readonly rightFooter;\n readonly middleLowerPanel;\n readonly dataIdFromObject;\n\n /**\n * @param args Options to pass to each Container Module\n * @returns Created container and binds all the container modules\n */\n createContainers(args);\n\n\n createService(options, updateOptions);\n /**\n * @param args Provide resolverContext which can be passed to all resolver functions.\n * @returns IClientState\n */\n getStateParams(args?: { resolverContex?: any }): IClientState;\n\n getDataIdFromObject(result: {\n [key: string]: string | number;\n __typename?: string;\n } | IdGetterObj): any;\n /**\n * @arguments root React tree root component\n * @arguments req Http Request\n * @returns React tree root component wrapped up by root components exposed by this module\n */\n getWrappedRoot(root: any, req?: any): any;\n /**\n * @param root React tree data root component (first React root components which is used for fetching data)\n *\n * @returns React tree data root component wrapped up by data root components exposed by this module\n */\n getDataRoot(root: any): any;\n registerLanguages(monaco): void;\n}\n","export * from './connector';\n","export * from './logger';\n","import { ClientLogger } from '@cdm-logger/client';\n\nconst appName = (process.env && process.env.APP_NAME) || 'FullStack';\nconst logLevel = (process.env && process.env.LOG_LEVEL) || 'info';\nconst logger = ClientLogger.create(appName, { level: logLevel as any });\n\nexport { logger };\n","module.exports = require(\"@apollo/client\");","module.exports = require(\"@cdm-logger/client\");","module.exports = require(\"@common-stack/core\");","module.exports = require(\"inversify\");","module.exports = require(\"lodash\");","module.exports = require(\"react\");","// The module cache\nvar __webpack_module_cache__ = {};\n\n// The require function\nfunction __webpack_require__(moduleId) {\n\t// Check if module is in cache\n\tvar cachedModule = __webpack_module_cache__[moduleId];\n\tif (cachedModule !== undefined) {\n\t\treturn cachedModule.exports;\n\t}\n\t// Create a new module (and put it into the cache)\n\tvar module = __webpack_module_cache__[moduleId] = {\n\t\t// no module.id needed\n\t\t// no module.loaded needed\n\t\texports: {}\n\t};\n\n\t// Execute the module function\n\t__webpack_modules__[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n\t// Return the exports of the module\n\treturn module.exports;\n}\n\n","","// startup\n// Load entry module and return exports\n// This entry module is referenced by other modules so it can't be inlined\nvar __webpack_exports__ = __webpack_require__(\"./src/index.ts\");\n",""],"names":[],"sourceRoot":""}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@common-stack/client-core",
3
- "version": "0.2.3",
3
+ "version": "0.2.16",
4
4
  "description": "common core for higher packages to depend on",
5
5
  "license": "ISC",
6
6
  "author": "CDMBase LLC",
@@ -38,7 +38,7 @@
38
38
  }
39
39
  },
40
40
  "dependencies": {
41
- "@common-stack/core": "^0.2.1"
41
+ "@common-stack/core": "^0.2.16"
42
42
  },
43
43
  "publishConfig": {
44
44
  "access": "public"
@@ -50,5 +50,5 @@
50
50
  "typescript": {
51
51
  "definition": "lib/index.d.ts"
52
52
  },
53
- "gitHead": "cda34f3dd864e4126075af77e454e8b5b095d42a"
53
+ "gitHead": "b6b684b47c3aab68830ce5788ef271bf8e7b6e19"
54
54
  }