@genesislcap/foundation-utils 14.211.2 → 14.211.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (2) hide show
  1. package/dist/custom-elements.json +507 -507
  2. package/package.json +10 -10
@@ -169,460 +169,251 @@
169
169
  },
170
170
  {
171
171
  "kind": "javascript-module",
172
- "path": "src/directives/index.ts",
173
- "declarations": [],
174
- "exports": [
175
- {
176
- "kind": "js",
177
- "name": "*",
178
- "declaration": {
179
- "name": "*",
180
- "package": "./sync"
181
- }
182
- },
183
- {
184
- "kind": "js",
185
- "name": "*",
186
- "declaration": {
187
- "name": "*",
188
- "package": "./when-else"
189
- }
190
- }
191
- ]
192
- },
193
- {
194
- "kind": "javascript-module",
195
- "path": "src/env/index.ts",
196
- "declarations": [],
197
- "exports": [
198
- {
199
- "kind": "js",
200
- "name": "*",
201
- "declaration": {
202
- "name": "*",
203
- "package": "./is-dev"
204
- }
205
- },
206
- {
207
- "kind": "js",
208
- "name": "*",
209
- "declaration": {
210
- "name": "*",
211
- "package": "./variables"
212
- }
213
- }
214
- ]
215
- },
216
- {
217
- "kind": "javascript-module",
218
- "path": "src/env/is-dev.ts",
219
- "declarations": [
220
- {
221
- "kind": "function",
222
- "name": "isDev",
223
- "description": "Determines if the current environment is a development environment.",
224
- "privacy": "public"
225
- }
226
- ],
227
- "exports": [
228
- {
229
- "kind": "js",
230
- "name": "isDev",
231
- "declaration": {
232
- "name": "isDev",
233
- "module": "src/env/is-dev.ts"
234
- }
235
- }
236
- ]
237
- },
238
- {
239
- "kind": "javascript-module",
240
- "path": "src/env/variables.ts",
241
- "declarations": [
242
- {
243
- "kind": "variable",
244
- "name": "SOCKET_EXT",
245
- "type": {
246
- "text": "string"
247
- }
248
- },
249
- {
250
- "kind": "variable",
251
- "name": "_SOCKET_EXT",
252
- "type": {
253
- "text": "string"
254
- },
255
- "default": "'gwf'",
256
- "description": "The sub-path used for WebSocket connections when API_HOST is not set",
257
- "privacy": "public"
258
- },
259
- {
260
- "kind": "variable",
261
- "name": "FORCE_HTTP",
262
- "type": {
263
- "text": "string"
264
- }
265
- },
266
- {
267
- "kind": "variable",
268
- "name": "_FORCE_HTTP",
269
- "type": {
270
- "text": "string"
271
- },
272
- "description": "The path to a JSON config file for the HTTP mode.",
273
- "privacy": "public"
274
- },
275
- {
276
- "kind": "variable",
277
- "name": "GENESIS_SOCKET_URL",
278
- "default": "`${location.protocol.replace('http', 'ws')}//${location.host}/${_SOCKET_EXT}/`",
279
- "description": "Genesis Socket URL",
280
- "privacy": "public"
281
- },
282
- {
283
- "kind": "variable",
284
- "name": "API_HOST",
285
- "type": {
286
- "text": "string"
287
- }
288
- },
289
- {
290
- "kind": "variable",
291
- "name": "_API_HOST",
292
- "type": {
293
- "text": "string"
294
- },
295
- "default": "`${PROTOCOL}//${location.host}/${_SOCKET_EXT}/`",
296
- "description": "The Genesis Server URL (WebSocket or HTTP).",
297
- "privacy": "public"
298
- },
299
- {
300
- "kind": "variable",
301
- "name": "HTTP_CONFIG",
302
- "type": {
303
- "text": "string"
304
- }
305
- },
306
- {
307
- "kind": "variable",
308
- "name": "_HTTP_CONFIG",
309
- "type": {
310
- "text": "string"
311
- },
312
- "description": "Configuration settings for HTTP, used in http connect flow [`genesislcap-foundation-comms.HttpConnectConfig`](https://link-to-docs).",
313
- "privacy": "public"
314
- },
315
- {
316
- "kind": "variable",
317
- "name": "DEFAULT_ORGANISATION",
318
- "type": {
319
- "text": "string"
320
- }
321
- },
322
- {
323
- "kind": "variable",
324
- "name": "_DEFAULT_ORGANISATION",
325
- "type": {
326
- "text": "string"
327
- },
328
- "description": "The default Organisation value, used in auth/login flow [`genesislcap-foundation-login`](https://link-to-docs).",
329
- "privacy": "public"
330
- },
331
- {
332
- "kind": "variable",
333
- "name": "DEFAULT_PASSWORD",
334
- "type": {
335
- "text": "string"
336
- }
337
- },
338
- {
339
- "kind": "variable",
340
- "name": "_DEFAULT_PASSWORD",
341
- "type": {
342
- "text": "string"
343
- },
344
- "description": "The default Password value, used in auth/login flow [`genesislcap-foundation-login`](https://link-to-docs).",
345
- "privacy": "public"
346
- },
347
- {
348
- "kind": "variable",
349
- "name": "DEFAULT_USER",
350
- "type": {
351
- "text": "string"
352
- }
353
- },
354
- {
355
- "kind": "variable",
356
- "name": "_DEFAULT_USER",
357
- "type": {
358
- "text": "string"
359
- },
360
- "description": "The default Username value, used in auth/login flow [`genesislcap-foundation-login`](https://link-to-docs).",
361
- "privacy": "public"
362
- }
363
- ],
364
- "exports": [
365
- {
366
- "kind": "js",
367
- "name": "SOCKET_EXT",
368
- "declaration": {
369
- "name": "_SOCKET_EXT",
370
- "module": "src/env/variables.ts"
371
- }
372
- },
373
- {
374
- "kind": "js",
375
- "name": "FORCE_HTTP",
376
- "declaration": {
377
- "name": "_FORCE_HTTP",
378
- "module": "src/env/variables.ts"
379
- }
380
- },
381
- {
382
- "kind": "js",
383
- "name": "GENESIS_SOCKET_URL",
384
- "declaration": {
385
- "name": "GENESIS_SOCKET_URL",
386
- "module": "src/env/variables.ts"
387
- }
388
- },
389
- {
390
- "kind": "js",
391
- "name": "API_HOST",
392
- "declaration": {
393
- "name": "_API_HOST",
394
- "module": "src/env/variables.ts"
395
- }
396
- },
397
- {
398
- "kind": "js",
399
- "name": "HTTP_CONFIG",
400
- "declaration": {
401
- "name": "_HTTP_CONFIG",
402
- "module": "src/env/variables.ts"
403
- }
404
- },
405
- {
406
- "kind": "js",
407
- "name": "DEFAULT_ORGANISATION",
408
- "declaration": {
409
- "name": "_DEFAULT_ORGANISATION",
410
- "module": "src/env/variables.ts"
411
- }
412
- },
413
- {
414
- "kind": "js",
415
- "name": "DEFAULT_PASSWORD",
416
- "declaration": {
417
- "name": "_DEFAULT_PASSWORD",
418
- "module": "src/env/variables.ts"
419
- }
420
- },
421
- {
422
- "kind": "js",
423
- "name": "DEFAULT_USER",
424
- "declaration": {
425
- "name": "_DEFAULT_USER",
426
- "module": "src/env/variables.ts"
427
- }
428
- }
429
- ]
430
- },
431
- {
432
- "kind": "javascript-module",
433
- "path": "src/error/errorMap.ts",
172
+ "path": "src/data/inMemoryDatabase.ts",
434
173
  "declarations": [
435
174
  {
436
175
  "kind": "class",
437
- "description": "",
438
- "name": "DefaultErrorMap",
176
+ "description": "An in memory database of specific DatabaseRecord types.",
177
+ "name": "InMemoryDatabase",
439
178
  "members": [
440
179
  {
441
180
  "kind": "field",
442
- "name": "map",
443
- "privacy": "private",
444
- "default": "new Map<keyof TErrorDetailMap, Error>()"
181
+ "name": "isWorking",
182
+ "type": {
183
+ "text": "boolean"
184
+ },
185
+ "privacy": "public",
186
+ "default": "false"
445
187
  },
446
188
  {
447
189
  "kind": "field",
448
- "name": "lastError",
190
+ "name": "records",
449
191
  "type": {
450
- "text": "Error"
192
+ "text": "Record<string, T>"
451
193
  },
452
- "description": "{@inheritDoc ErrorMap.lastError}"
194
+ "privacy": "private",
195
+ "default": "{}"
196
+ },
197
+ {
198
+ "kind": "field",
199
+ "name": "beforeUpdateListeners",
200
+ "privacy": "private"
201
+ },
202
+ {
203
+ "kind": "field",
204
+ "name": "afterUpdateListeners",
205
+ "privacy": "private"
453
206
  },
454
207
  {
455
208
  "kind": "method",
456
- "name": "set",
209
+ "name": "create",
210
+ "privacy": "public",
457
211
  "return": {
458
212
  "type": {
459
- "text": "void"
213
+ "text": "Promise<DatabaseAccessResult.Create<T>>"
460
214
  }
461
215
  },
462
216
  "parameters": [
463
217
  {
464
- "name": "key",
465
- "type": {
466
- "text": "keyof TErrorDetailMap"
467
- }
468
- },
469
- {
470
- "name": "error",
218
+ "name": "newValue",
471
219
  "type": {
472
- "text": "Error"
220
+ "text": "Omit<T, 'id'>"
473
221
  }
474
222
  }
475
- ],
476
- "description": "{@inheritDoc ErrorMap.set}"
223
+ ]
477
224
  },
478
225
  {
479
226
  "kind": "method",
480
- "name": "get",
227
+ "name": "read",
228
+ "privacy": "public",
481
229
  "return": {
482
230
  "type": {
483
- "text": ""
231
+ "text": "Promise<DatabaseAccessResult.Read<T>>"
484
232
  }
485
233
  },
486
234
  "parameters": [
487
235
  {
488
- "name": "key",
236
+ "name": "id",
489
237
  "type": {
490
- "text": "keyof TErrorDetailMap"
491
- },
492
- "description": "The key."
238
+ "text": "string"
239
+ }
493
240
  }
494
- ],
495
- "description": "Get an error by key.",
496
- "privacy": "public"
241
+ ]
497
242
  },
498
243
  {
499
244
  "kind": "method",
500
- "name": "has",
245
+ "name": "update",
246
+ "privacy": "public",
501
247
  "return": {
502
248
  "type": {
503
- "text": ""
249
+ "text": "Promise<DatabaseAccessResult.Update<T>>"
504
250
  }
505
251
  },
506
252
  "parameters": [
507
253
  {
508
- "name": "key",
254
+ "name": "id",
509
255
  "type": {
510
- "text": "keyof TErrorDetailMap"
511
- },
512
- "description": "The key."
256
+ "text": "string"
257
+ }
258
+ },
259
+ {
260
+ "name": "newValue",
261
+ "type": {
262
+ "text": "Omit<Partial<T>, 'id'>"
263
+ }
513
264
  }
514
- ],
515
- "description": "Has an error for key.",
516
- "privacy": "public"
265
+ ]
517
266
  },
518
267
  {
519
268
  "kind": "method",
520
269
  "name": "delete",
270
+ "privacy": "public",
521
271
  "return": {
522
272
  "type": {
523
- "text": ""
273
+ "text": "Promise<DatabaseAccessResult.Delete>"
524
274
  }
525
275
  },
526
276
  "parameters": [
527
277
  {
528
- "name": "key",
278
+ "name": "id",
529
279
  "type": {
530
- "text": "keyof TErrorDetailMap"
531
- },
532
- "description": "The key."
280
+ "text": "string"
281
+ }
533
282
  }
534
- ],
535
- "description": "Delete an error.",
536
- "privacy": "public"
283
+ ]
537
284
  },
538
285
  {
539
286
  "kind": "method",
540
- "name": "clear",
541
- "description": "Clear errors.",
542
- "privacy": "public"
543
- },
544
- {
545
- "kind": "field",
546
- "name": "size",
547
- "type": {
548
- "text": "number"
549
- },
550
- "description": "The size of the error map.",
287
+ "name": "visit",
288
+ "privacy": "public",
551
289
  "return": {
552
290
  "type": {
553
- "text": ""
291
+ "text": "Promise<void>"
554
292
  }
555
293
  },
556
- "privacy": "public",
557
- "readonly": true
294
+ "parameters": [
295
+ {
296
+ "name": "visitor",
297
+ "type": {
298
+ "text": "(record: T) => void"
299
+ }
300
+ }
301
+ ]
558
302
  },
559
303
  {
560
304
  "kind": "method",
561
- "name": "values",
562
- "privacy": "public"
305
+ "name": "onBeforeUpdate",
306
+ "privacy": "public",
307
+ "return": {
308
+ "type": {
309
+ "text": "() => void"
310
+ }
311
+ },
312
+ "parameters": [
313
+ {
314
+ "name": "listener",
315
+ "type": {
316
+ "text": "Listener<DatabaseEvent.BeforeUpdate<T>>"
317
+ }
318
+ }
319
+ ]
563
320
  },
564
321
  {
565
- "kind": "field",
566
- "name": "messages",
567
- "type": {
568
- "text": "string"
322
+ "kind": "method",
323
+ "name": "onAfterUpdate",
324
+ "privacy": "public",
325
+ "return": {
326
+ "type": {
327
+ "text": "() => void"
328
+ }
569
329
  },
570
- "description": "{@inheritDoc ErrorMap.messages}",
571
- "readonly": true
330
+ "parameters": [
331
+ {
332
+ "name": "listener",
333
+ "type": {
334
+ "text": "Listener<DatabaseEvent.AfterUpdate<T>>"
335
+ }
336
+ }
337
+ ]
572
338
  }
573
339
  ]
574
- },
575
- {
576
- "kind": "function",
577
- "name": "createErrorMap",
578
- "return": {
579
- "type": {
580
- "text": ""
581
- }
582
- },
583
- "parameters": [
584
- {
585
- "name": "logger",
586
- "type": {
587
- "text": "ErrorMapLogger"
588
- },
589
- "description": "A logger error method reference."
590
- }
591
- ],
592
- "description": "A factory to create the error map.",
593
- "privacy": "public"
594
340
  }
595
341
  ],
596
342
  "exports": [
597
343
  {
598
344
  "kind": "js",
599
- "name": "DefaultErrorMap",
345
+ "name": "InMemoryDatabase",
600
346
  "declaration": {
601
- "name": "DefaultErrorMap",
602
- "module": "src/error/errorMap.ts"
347
+ "name": "InMemoryDatabase",
348
+ "module": "src/data/inMemoryDatabase.ts"
603
349
  }
604
- },
350
+ }
351
+ ]
352
+ },
353
+ {
354
+ "kind": "javascript-module",
355
+ "path": "src/data/index.ts",
356
+ "declarations": [],
357
+ "exports": [
605
358
  {
606
359
  "kind": "js",
607
- "name": "createErrorMap",
360
+ "name": "*",
608
361
  "declaration": {
609
- "name": "createErrorMap",
610
- "module": "src/error/errorMap.ts"
362
+ "name": "*",
363
+ "package": "./inMemoryDatabase"
364
+ }
365
+ }
366
+ ]
367
+ },
368
+ {
369
+ "kind": "javascript-module",
370
+ "path": "src/decorators/index.ts",
371
+ "declarations": [],
372
+ "exports": [
373
+ {
374
+ "kind": "js",
375
+ "name": "*",
376
+ "declaration": {
377
+ "name": "*",
378
+ "package": "./renderOnChange"
611
379
  }
612
380
  }
613
- ]
614
- },
615
- {
616
- "kind": "javascript-module",
617
- "path": "src/error/index.ts",
618
- "declarations": [],
381
+ ]
382
+ },
383
+ {
384
+ "kind": "javascript-module",
385
+ "path": "src/decorators/renderOnChange.ts",
386
+ "declarations": [
387
+ {
388
+ "kind": "function",
389
+ "name": "renderOnChange",
390
+ "parameters": [
391
+ {
392
+ "name": "target",
393
+ "type": {
394
+ "text": "FASTElement & { render(): void }"
395
+ },
396
+ "description": "The target to define the property change handler on."
397
+ },
398
+ {
399
+ "name": "name",
400
+ "type": {
401
+ "text": "string"
402
+ },
403
+ "description": "The property name."
404
+ }
405
+ ],
406
+ "description": "Defines a property changed handler that calls a render() method on the target as an internal observation enhancement.",
407
+ "privacy": "public"
408
+ }
409
+ ],
619
410
  "exports": [
620
411
  {
621
412
  "kind": "js",
622
- "name": "*",
413
+ "name": "renderOnChange",
623
414
  "declaration": {
624
- "name": "*",
625
- "package": "./errorMap"
415
+ "name": "renderOnChange",
416
+ "module": "src/decorators/renderOnChange.ts"
626
417
  }
627
418
  }
628
419
  ]
@@ -679,7 +470,7 @@
679
470
  },
680
471
  {
681
472
  "kind": "javascript-module",
682
- "path": "src/decorators/index.ts",
473
+ "path": "src/directives/index.ts",
683
474
  "declarations": [],
684
475
  "exports": [
685
476
  {
@@ -687,235 +478,444 @@
687
478
  "name": "*",
688
479
  "declaration": {
689
480
  "name": "*",
690
- "package": "./renderOnChange"
481
+ "package": "./sync"
482
+ }
483
+ },
484
+ {
485
+ "kind": "js",
486
+ "name": "*",
487
+ "declaration": {
488
+ "name": "*",
489
+ "package": "./when-else"
691
490
  }
692
491
  }
693
492
  ]
694
493
  },
695
494
  {
696
495
  "kind": "javascript-module",
697
- "path": "src/decorators/renderOnChange.ts",
496
+ "path": "src/env/index.ts",
497
+ "declarations": [],
498
+ "exports": [
499
+ {
500
+ "kind": "js",
501
+ "name": "*",
502
+ "declaration": {
503
+ "name": "*",
504
+ "package": "./is-dev"
505
+ }
506
+ },
507
+ {
508
+ "kind": "js",
509
+ "name": "*",
510
+ "declaration": {
511
+ "name": "*",
512
+ "package": "./variables"
513
+ }
514
+ }
515
+ ]
516
+ },
517
+ {
518
+ "kind": "javascript-module",
519
+ "path": "src/env/is-dev.ts",
698
520
  "declarations": [
699
521
  {
700
522
  "kind": "function",
701
- "name": "renderOnChange",
702
- "parameters": [
703
- {
704
- "name": "target",
705
- "type": {
706
- "text": "FASTElement & { render(): void }"
707
- },
708
- "description": "The target to define the property change handler on."
709
- },
710
- {
711
- "name": "name",
712
- "type": {
713
- "text": "string"
714
- },
715
- "description": "The property name."
716
- }
717
- ],
718
- "description": "Defines a property changed handler that calls a render() method on the target as an internal observation enhancement.",
523
+ "name": "isDev",
524
+ "description": "Determines if the current environment is a development environment.",
525
+ "privacy": "public"
526
+ }
527
+ ],
528
+ "exports": [
529
+ {
530
+ "kind": "js",
531
+ "name": "isDev",
532
+ "declaration": {
533
+ "name": "isDev",
534
+ "module": "src/env/is-dev.ts"
535
+ }
536
+ }
537
+ ]
538
+ },
539
+ {
540
+ "kind": "javascript-module",
541
+ "path": "src/env/variables.ts",
542
+ "declarations": [
543
+ {
544
+ "kind": "variable",
545
+ "name": "SOCKET_EXT",
546
+ "type": {
547
+ "text": "string"
548
+ }
549
+ },
550
+ {
551
+ "kind": "variable",
552
+ "name": "_SOCKET_EXT",
553
+ "type": {
554
+ "text": "string"
555
+ },
556
+ "default": "'gwf'",
557
+ "description": "The sub-path used for WebSocket connections when API_HOST is not set",
558
+ "privacy": "public"
559
+ },
560
+ {
561
+ "kind": "variable",
562
+ "name": "FORCE_HTTP",
563
+ "type": {
564
+ "text": "string"
565
+ }
566
+ },
567
+ {
568
+ "kind": "variable",
569
+ "name": "_FORCE_HTTP",
570
+ "type": {
571
+ "text": "string"
572
+ },
573
+ "description": "The path to a JSON config file for the HTTP mode.",
574
+ "privacy": "public"
575
+ },
576
+ {
577
+ "kind": "variable",
578
+ "name": "GENESIS_SOCKET_URL",
579
+ "default": "`${location.protocol.replace('http', 'ws')}//${location.host}/${_SOCKET_EXT}/`",
580
+ "description": "Genesis Socket URL",
581
+ "privacy": "public"
582
+ },
583
+ {
584
+ "kind": "variable",
585
+ "name": "API_HOST",
586
+ "type": {
587
+ "text": "string"
588
+ }
589
+ },
590
+ {
591
+ "kind": "variable",
592
+ "name": "_API_HOST",
593
+ "type": {
594
+ "text": "string"
595
+ },
596
+ "default": "`${PROTOCOL}//${location.host}/${_SOCKET_EXT}/`",
597
+ "description": "The Genesis Server URL (WebSocket or HTTP).",
598
+ "privacy": "public"
599
+ },
600
+ {
601
+ "kind": "variable",
602
+ "name": "HTTP_CONFIG",
603
+ "type": {
604
+ "text": "string"
605
+ }
606
+ },
607
+ {
608
+ "kind": "variable",
609
+ "name": "_HTTP_CONFIG",
610
+ "type": {
611
+ "text": "string"
612
+ },
613
+ "description": "Configuration settings for HTTP, used in http connect flow [`genesislcap-foundation-comms.HttpConnectConfig`](https://link-to-docs).",
614
+ "privacy": "public"
615
+ },
616
+ {
617
+ "kind": "variable",
618
+ "name": "DEFAULT_ORGANISATION",
619
+ "type": {
620
+ "text": "string"
621
+ }
622
+ },
623
+ {
624
+ "kind": "variable",
625
+ "name": "_DEFAULT_ORGANISATION",
626
+ "type": {
627
+ "text": "string"
628
+ },
629
+ "description": "The default Organisation value, used in auth/login flow [`genesislcap-foundation-login`](https://link-to-docs).",
630
+ "privacy": "public"
631
+ },
632
+ {
633
+ "kind": "variable",
634
+ "name": "DEFAULT_PASSWORD",
635
+ "type": {
636
+ "text": "string"
637
+ }
638
+ },
639
+ {
640
+ "kind": "variable",
641
+ "name": "_DEFAULT_PASSWORD",
642
+ "type": {
643
+ "text": "string"
644
+ },
645
+ "description": "The default Password value, used in auth/login flow [`genesislcap-foundation-login`](https://link-to-docs).",
646
+ "privacy": "public"
647
+ },
648
+ {
649
+ "kind": "variable",
650
+ "name": "DEFAULT_USER",
651
+ "type": {
652
+ "text": "string"
653
+ }
654
+ },
655
+ {
656
+ "kind": "variable",
657
+ "name": "_DEFAULT_USER",
658
+ "type": {
659
+ "text": "string"
660
+ },
661
+ "description": "The default Username value, used in auth/login flow [`genesislcap-foundation-login`](https://link-to-docs).",
719
662
  "privacy": "public"
720
663
  }
721
664
  ],
722
665
  "exports": [
723
666
  {
724
667
  "kind": "js",
725
- "name": "renderOnChange",
668
+ "name": "SOCKET_EXT",
669
+ "declaration": {
670
+ "name": "_SOCKET_EXT",
671
+ "module": "src/env/variables.ts"
672
+ }
673
+ },
674
+ {
675
+ "kind": "js",
676
+ "name": "FORCE_HTTP",
677
+ "declaration": {
678
+ "name": "_FORCE_HTTP",
679
+ "module": "src/env/variables.ts"
680
+ }
681
+ },
682
+ {
683
+ "kind": "js",
684
+ "name": "GENESIS_SOCKET_URL",
685
+ "declaration": {
686
+ "name": "GENESIS_SOCKET_URL",
687
+ "module": "src/env/variables.ts"
688
+ }
689
+ },
690
+ {
691
+ "kind": "js",
692
+ "name": "API_HOST",
693
+ "declaration": {
694
+ "name": "_API_HOST",
695
+ "module": "src/env/variables.ts"
696
+ }
697
+ },
698
+ {
699
+ "kind": "js",
700
+ "name": "HTTP_CONFIG",
701
+ "declaration": {
702
+ "name": "_HTTP_CONFIG",
703
+ "module": "src/env/variables.ts"
704
+ }
705
+ },
706
+ {
707
+ "kind": "js",
708
+ "name": "DEFAULT_ORGANISATION",
709
+ "declaration": {
710
+ "name": "_DEFAULT_ORGANISATION",
711
+ "module": "src/env/variables.ts"
712
+ }
713
+ },
714
+ {
715
+ "kind": "js",
716
+ "name": "DEFAULT_PASSWORD",
726
717
  "declaration": {
727
- "name": "renderOnChange",
728
- "module": "src/decorators/renderOnChange.ts"
718
+ "name": "_DEFAULT_PASSWORD",
719
+ "module": "src/env/variables.ts"
720
+ }
721
+ },
722
+ {
723
+ "kind": "js",
724
+ "name": "DEFAULT_USER",
725
+ "declaration": {
726
+ "name": "_DEFAULT_USER",
727
+ "module": "src/env/variables.ts"
729
728
  }
730
729
  }
731
730
  ]
732
731
  },
733
732
  {
734
733
  "kind": "javascript-module",
735
- "path": "src/data/inMemoryDatabase.ts",
734
+ "path": "src/error/errorMap.ts",
736
735
  "declarations": [
737
736
  {
738
737
  "kind": "class",
739
- "description": "An in memory database of specific DatabaseRecord types.",
740
- "name": "InMemoryDatabase",
738
+ "description": "",
739
+ "name": "DefaultErrorMap",
741
740
  "members": [
742
741
  {
743
742
  "kind": "field",
744
- "name": "isWorking",
745
- "type": {
746
- "text": "boolean"
747
- },
748
- "privacy": "public",
749
- "default": "false"
743
+ "name": "map",
744
+ "privacy": "private",
745
+ "default": "new Map<keyof TErrorDetailMap, Error>()"
750
746
  },
751
747
  {
752
748
  "kind": "field",
753
- "name": "records",
749
+ "name": "lastError",
754
750
  "type": {
755
- "text": "Record<string, T>"
751
+ "text": "Error"
756
752
  },
757
- "privacy": "private",
758
- "default": "{}"
759
- },
760
- {
761
- "kind": "field",
762
- "name": "beforeUpdateListeners",
763
- "privacy": "private"
764
- },
765
- {
766
- "kind": "field",
767
- "name": "afterUpdateListeners",
768
- "privacy": "private"
753
+ "description": "{@inheritDoc ErrorMap.lastError}"
769
754
  },
770
755
  {
771
756
  "kind": "method",
772
- "name": "create",
773
- "privacy": "public",
757
+ "name": "set",
774
758
  "return": {
775
759
  "type": {
776
- "text": "Promise<DatabaseAccessResult.Create<T>>"
760
+ "text": "void"
777
761
  }
778
762
  },
779
763
  "parameters": [
780
764
  {
781
- "name": "newValue",
765
+ "name": "key",
782
766
  "type": {
783
- "text": "Omit<T, 'id'>"
767
+ "text": "keyof TErrorDetailMap"
784
768
  }
785
- }
786
- ]
787
- },
788
- {
789
- "kind": "method",
790
- "name": "read",
791
- "privacy": "public",
792
- "return": {
793
- "type": {
794
- "text": "Promise<DatabaseAccessResult.Read<T>>"
795
- }
796
- },
797
- "parameters": [
769
+ },
798
770
  {
799
- "name": "id",
771
+ "name": "error",
800
772
  "type": {
801
- "text": "string"
773
+ "text": "Error"
802
774
  }
803
775
  }
804
- ]
776
+ ],
777
+ "description": "{@inheritDoc ErrorMap.set}"
805
778
  },
806
779
  {
807
780
  "kind": "method",
808
- "name": "update",
809
- "privacy": "public",
781
+ "name": "get",
810
782
  "return": {
811
783
  "type": {
812
- "text": "Promise<DatabaseAccessResult.Update<T>>"
784
+ "text": ""
813
785
  }
814
786
  },
815
787
  "parameters": [
816
788
  {
817
- "name": "id",
818
- "type": {
819
- "text": "string"
820
- }
821
- },
822
- {
823
- "name": "newValue",
789
+ "name": "key",
824
790
  "type": {
825
- "text": "Omit<Partial<T>, 'id'>"
826
- }
791
+ "text": "keyof TErrorDetailMap"
792
+ },
793
+ "description": "The key."
827
794
  }
828
- ]
795
+ ],
796
+ "description": "Get an error by key.",
797
+ "privacy": "public"
829
798
  },
830
799
  {
831
800
  "kind": "method",
832
- "name": "delete",
833
- "privacy": "public",
801
+ "name": "has",
834
802
  "return": {
835
803
  "type": {
836
- "text": "Promise<DatabaseAccessResult.Delete>"
804
+ "text": ""
837
805
  }
838
806
  },
839
807
  "parameters": [
840
808
  {
841
- "name": "id",
809
+ "name": "key",
842
810
  "type": {
843
- "text": "string"
844
- }
811
+ "text": "keyof TErrorDetailMap"
812
+ },
813
+ "description": "The key."
845
814
  }
846
- ]
815
+ ],
816
+ "description": "Has an error for key.",
817
+ "privacy": "public"
847
818
  },
848
819
  {
849
820
  "kind": "method",
850
- "name": "visit",
851
- "privacy": "public",
821
+ "name": "delete",
852
822
  "return": {
853
823
  "type": {
854
- "text": "Promise<void>"
824
+ "text": ""
855
825
  }
856
826
  },
857
827
  "parameters": [
858
828
  {
859
- "name": "visitor",
829
+ "name": "key",
860
830
  "type": {
861
- "text": "(record: T) => void"
862
- }
831
+ "text": "keyof TErrorDetailMap"
832
+ },
833
+ "description": "The key."
863
834
  }
864
- ]
835
+ ],
836
+ "description": "Delete an error.",
837
+ "privacy": "public"
865
838
  },
866
839
  {
867
840
  "kind": "method",
868
- "name": "onBeforeUpdate",
869
- "privacy": "public",
841
+ "name": "clear",
842
+ "description": "Clear errors.",
843
+ "privacy": "public"
844
+ },
845
+ {
846
+ "kind": "field",
847
+ "name": "size",
848
+ "type": {
849
+ "text": "number"
850
+ },
851
+ "description": "The size of the error map.",
870
852
  "return": {
871
853
  "type": {
872
- "text": "() => void"
854
+ "text": ""
873
855
  }
874
856
  },
875
- "parameters": [
876
- {
877
- "name": "listener",
878
- "type": {
879
- "text": "Listener<DatabaseEvent.BeforeUpdate<T>>"
880
- }
881
- }
882
- ]
857
+ "privacy": "public",
858
+ "readonly": true
883
859
  },
884
860
  {
885
861
  "kind": "method",
886
- "name": "onAfterUpdate",
887
- "privacy": "public",
888
- "return": {
889
- "type": {
890
- "text": "() => void"
891
- }
862
+ "name": "values",
863
+ "privacy": "public"
864
+ },
865
+ {
866
+ "kind": "field",
867
+ "name": "messages",
868
+ "type": {
869
+ "text": "string"
892
870
  },
893
- "parameters": [
894
- {
895
- "name": "listener",
896
- "type": {
897
- "text": "Listener<DatabaseEvent.AfterUpdate<T>>"
898
- }
899
- }
900
- ]
871
+ "description": "{@inheritDoc ErrorMap.messages}",
872
+ "readonly": true
901
873
  }
902
874
  ]
875
+ },
876
+ {
877
+ "kind": "function",
878
+ "name": "createErrorMap",
879
+ "return": {
880
+ "type": {
881
+ "text": ""
882
+ }
883
+ },
884
+ "parameters": [
885
+ {
886
+ "name": "logger",
887
+ "type": {
888
+ "text": "ErrorMapLogger"
889
+ },
890
+ "description": "A logger error method reference."
891
+ }
892
+ ],
893
+ "description": "A factory to create the error map.",
894
+ "privacy": "public"
903
895
  }
904
896
  ],
905
897
  "exports": [
906
898
  {
907
899
  "kind": "js",
908
- "name": "InMemoryDatabase",
900
+ "name": "DefaultErrorMap",
909
901
  "declaration": {
910
- "name": "InMemoryDatabase",
911
- "module": "src/data/inMemoryDatabase.ts"
902
+ "name": "DefaultErrorMap",
903
+ "module": "src/error/errorMap.ts"
904
+ }
905
+ },
906
+ {
907
+ "kind": "js",
908
+ "name": "createErrorMap",
909
+ "declaration": {
910
+ "name": "createErrorMap",
911
+ "module": "src/error/errorMap.ts"
912
912
  }
913
913
  }
914
914
  ]
915
915
  },
916
916
  {
917
917
  "kind": "javascript-module",
918
- "path": "src/data/index.ts",
918
+ "path": "src/error/index.ts",
919
919
  "declarations": [],
920
920
  "exports": [
921
921
  {
@@ -923,7 +923,7 @@
923
923
  "name": "*",
924
924
  "declaration": {
925
925
  "name": "*",
926
- "package": "./inMemoryDatabase"
926
+ "package": "./errorMap"
927
927
  }
928
928
  }
929
929
  ]
@@ -1996,7 +1996,7 @@
1996
1996
  },
1997
1997
  {
1998
1998
  "kind": "javascript-module",
1999
- "path": "src/uuid/index.ts",
1999
+ "path": "src/utils/index.ts",
2000
2000
  "declarations": [],
2001
2001
  "exports": [
2002
2002
  {
@@ -2004,36 +2004,36 @@
2004
2004
  "name": "*",
2005
2005
  "declaration": {
2006
2006
  "name": "*",
2007
- "package": "./uuid"
2007
+ "package": "./logger"
2008
2008
  }
2009
2009
  }
2010
2010
  ]
2011
2011
  },
2012
2012
  {
2013
2013
  "kind": "javascript-module",
2014
- "path": "src/uuid/uuid.ts",
2014
+ "path": "src/utils/logger.ts",
2015
2015
  "declarations": [
2016
2016
  {
2017
2017
  "kind": "variable",
2018
- "name": "UUID",
2019
- "description": "A dependency injection token for the UUID interface.",
2018
+ "name": "logger",
2019
+ "description": "Logger for the foundation-utils package",
2020
2020
  "privacy": "public"
2021
2021
  }
2022
2022
  ],
2023
2023
  "exports": [
2024
2024
  {
2025
2025
  "kind": "js",
2026
- "name": "UUID",
2026
+ "name": "logger",
2027
2027
  "declaration": {
2028
- "name": "UUID",
2029
- "module": "src/uuid/uuid.ts"
2028
+ "name": "logger",
2029
+ "module": "src/utils/logger.ts"
2030
2030
  }
2031
2031
  }
2032
2032
  ]
2033
2033
  },
2034
2034
  {
2035
2035
  "kind": "javascript-module",
2036
- "path": "src/utils/index.ts",
2036
+ "path": "src/uuid/index.ts",
2037
2037
  "declarations": [],
2038
2038
  "exports": [
2039
2039
  {
@@ -2041,29 +2041,29 @@
2041
2041
  "name": "*",
2042
2042
  "declaration": {
2043
2043
  "name": "*",
2044
- "package": "./logger"
2044
+ "package": "./uuid"
2045
2045
  }
2046
2046
  }
2047
2047
  ]
2048
2048
  },
2049
2049
  {
2050
2050
  "kind": "javascript-module",
2051
- "path": "src/utils/logger.ts",
2051
+ "path": "src/uuid/uuid.ts",
2052
2052
  "declarations": [
2053
2053
  {
2054
2054
  "kind": "variable",
2055
- "name": "logger",
2056
- "description": "Logger for the foundation-utils package",
2055
+ "name": "UUID",
2056
+ "description": "A dependency injection token for the UUID interface.",
2057
2057
  "privacy": "public"
2058
2058
  }
2059
2059
  ],
2060
2060
  "exports": [
2061
2061
  {
2062
2062
  "kind": "js",
2063
- "name": "logger",
2063
+ "name": "UUID",
2064
2064
  "declaration": {
2065
- "name": "logger",
2066
- "module": "src/utils/logger.ts"
2065
+ "name": "UUID",
2066
+ "module": "src/uuid/uuid.ts"
2067
2067
  }
2068
2068
  }
2069
2069
  ]
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@genesislcap/foundation-utils",
3
3
  "description": "Genesis Foundation Utils",
4
- "version": "14.211.2",
4
+ "version": "14.211.4",
5
5
  "sideEffects": false,
6
6
  "license": "SEE LICENSE IN license.txt",
7
7
  "main": "dist/esm/index.js",
@@ -27,17 +27,17 @@
27
27
  }
28
28
  },
29
29
  "devDependencies": {
30
- "@genesislcap/foundation-testing": "14.211.2",
31
- "@genesislcap/genx": "14.211.2",
32
- "@genesislcap/rollup-builder": "14.211.2",
33
- "@genesislcap/ts-builder": "14.211.2",
34
- "@genesislcap/uvu-playwright-builder": "14.211.2",
35
- "@genesislcap/vite-builder": "14.211.2",
36
- "@genesislcap/webpack-builder": "14.211.2",
30
+ "@genesislcap/foundation-testing": "14.211.4",
31
+ "@genesislcap/genx": "14.211.4",
32
+ "@genesislcap/rollup-builder": "14.211.4",
33
+ "@genesislcap/ts-builder": "14.211.4",
34
+ "@genesislcap/uvu-playwright-builder": "14.211.4",
35
+ "@genesislcap/vite-builder": "14.211.4",
36
+ "@genesislcap/webpack-builder": "14.211.4",
37
37
  "rimraf": "^5.0.0"
38
38
  },
39
39
  "dependencies": {
40
- "@genesislcap/foundation-logger": "14.211.2",
40
+ "@genesislcap/foundation-logger": "14.211.4",
41
41
  "@microsoft/fast-components": "^2.30.6",
42
42
  "@microsoft/fast-element": "^1.12.0",
43
43
  "@microsoft/fast-foundation": "^2.49.4",
@@ -55,5 +55,5 @@
55
55
  "access": "public"
56
56
  },
57
57
  "customElements": "dist/custom-elements.json",
58
- "gitHead": "c7134894f5bd7efb903b1612957041422fccb0ba"
58
+ "gitHead": "2e97f2125409e269ed87c650aaecc49ee986471b"
59
59
  }