@rxap/form-window-system 12.1.8-next.0 → 13.0.0-next.1

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.
Files changed (34) hide show
  1. package/esm2020/index.mjs +7 -0
  2. package/esm2020/lib/form-window-footer.directive.mjs +64 -0
  3. package/esm2020/lib/form-window-ref.mjs +27 -0
  4. package/esm2020/lib/form-window.service.mjs +118 -0
  5. package/esm2020/lib/open-form-window-method.directive.mjs +114 -0
  6. package/esm2020/lib/open-form-window.method.mjs +50 -0
  7. package/esm2020/lib/open-form.directive.mjs +130 -0
  8. package/esm2020/rxap-form-window-system.mjs +5 -0
  9. package/fesm2015/rxap-form-window-system.mjs +496 -0
  10. package/fesm2015/rxap-form-window-system.mjs.map +1 -0
  11. package/{fesm2015/rxap-form-window-system.js → fesm2020/rxap-form-window-system.mjs} +44 -42
  12. package/fesm2020/rxap-form-window-system.mjs.map +1 -0
  13. package/package.json +47 -28
  14. package/src/schematics/ng-add/index.js +1 -1
  15. package/src/schematics/ng-add/index.js.map +1 -1
  16. package/bundles/rxap-form-window-system.umd.js +0 -868
  17. package/bundles/rxap-form-window-system.umd.js.map +0 -1
  18. package/esm2015/index.js +0 -7
  19. package/esm2015/index.js.map +0 -1
  20. package/esm2015/lib/form-window-footer.directive.js +0 -64
  21. package/esm2015/lib/form-window-footer.directive.js.map +0 -1
  22. package/esm2015/lib/form-window-ref.js +0 -27
  23. package/esm2015/lib/form-window-ref.js.map +0 -1
  24. package/esm2015/lib/form-window.service.js +0 -119
  25. package/esm2015/lib/form-window.service.js.map +0 -1
  26. package/esm2015/lib/open-form-window-method.directive.js +0 -114
  27. package/esm2015/lib/open-form-window-method.directive.js.map +0 -1
  28. package/esm2015/lib/open-form-window.method.js +0 -45
  29. package/esm2015/lib/open-form-window.method.js.map +0 -1
  30. package/esm2015/lib/open-form.directive.js +0 -132
  31. package/esm2015/lib/open-form.directive.js.map +0 -1
  32. package/esm2015/rxap-form-window-system.js +0 -5
  33. package/esm2015/rxap-form-window-system.js.map +0 -1
  34. package/fesm2015/rxap-form-window-system.js.map +0 -1
@@ -18,15 +18,14 @@ class FormWindowService {
18
18
  this.injector = injector;
19
19
  }
20
20
  open(formDefinitionConstructor, options) {
21
- var _a, _b, _c, _d, _e;
22
21
  function FormDefinitionFactory(formBuilder, initial) {
23
22
  return formBuilder.build(initial);
24
23
  }
25
24
  function FormDefinitionBuilderFactory(_injector) {
26
25
  return new RxapFormBuilder(formDefinitionConstructor, _injector);
27
26
  }
28
- const providers = (_a = options === null || options === void 0 ? void 0 : options.providers) !== null && _a !== void 0 ? _a : [];
29
- if (((_b = options === null || options === void 0 ? void 0 : options.injector) !== null && _b !== void 0 ? _b : this.injector).get(formDefinitionConstructor, null, InjectFlags.Optional)) {
27
+ const providers = options?.providers ?? [];
28
+ if ((options?.injector ?? this.injector).get(formDefinitionConstructor, null, InjectFlags.Optional)) {
30
29
  providers.push({
31
30
  provide: RXAP_FORM_DEFINITION_BUILDER,
32
31
  useFactory: FormDefinitionBuilderFactory,
@@ -85,11 +84,12 @@ class FormWindowService {
85
84
  }
86
85
  }
87
86
  const injector = Injector.create({
88
- parent: (_c = options === null || options === void 0 ? void 0 : options.injector) !== null && _c !== void 0 ? _c : this.injector,
87
+ parent: options?.injector ?? this.injector,
89
88
  providers,
90
- name: (_d = options === null || options === void 0 ? void 0 : options.injectorName) !== null && _d !== void 0 ? _d : 'FormWindowService',
89
+ name: options?.injectorName ?? 'FormWindowService',
91
90
  });
92
- const component = (_e = options === null || options === void 0 ? void 0 : options.component) !== null && _e !== void 0 ? _e : this.extractFormComponent(formDefinitionConstructor);
91
+ const component = options?.component ??
92
+ this.extractFormComponent(formDefinitionConstructor);
93
93
  let windowConfig = {
94
94
  component,
95
95
  injector,
@@ -100,17 +100,16 @@ class FormWindowService {
100
100
  return this.windowService.open(windowConfig);
101
101
  }
102
102
  extractFormComponent(formDefinitionConstructor) {
103
- var _a;
104
- const component = (_a = getMetadata(FormSystemMetadataKeys.FORM_COMPONENT, formDefinitionConstructor)) !== null && _a !== void 0 ? _a : null;
103
+ const component = getMetadata(FormSystemMetadataKeys.FORM_COMPONENT, formDefinitionConstructor) ?? null;
105
104
  if (!component) {
106
105
  throw new Error('Could not extract form component constructor');
107
106
  }
108
107
  return component;
109
108
  }
110
109
  }
111
- FormWindowService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0, type: FormWindowService, deps: [{ token: WindowService }, { token: INJECTOR }], target: i0.ɵɵFactoryTarget.Injectable });
112
- FormWindowService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0, type: FormWindowService, providedIn: 'root' });
113
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0, type: FormWindowService, decorators: [{
110
+ FormWindowService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.3", ngImport: i0, type: FormWindowService, deps: [{ token: WindowService }, { token: INJECTOR }], target: i0.ɵɵFactoryTarget.Injectable });
111
+ FormWindowService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.2.3", ngImport: i0, type: FormWindowService, providedIn: 'root' });
112
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.3", ngImport: i0, type: FormWindowService, decorators: [{
114
113
  type: Injectable,
115
114
  args: [{
116
115
  providedIn: 'root',
@@ -190,22 +189,20 @@ class OpenFormDirective extends ConfirmClick {
190
189
  });
191
190
  }
192
191
  onSubmitSuccessful(result) {
193
- var _a;
194
192
  this.submitted.emit(result);
195
- (_a = this._formWindowRef) === null || _a === void 0 ? void 0 : _a.close();
193
+ this._formWindowRef?.close();
196
194
  }
197
195
  ngOnDestroy() {
198
- var _a;
199
- (_a = this._formWindowRef) === null || _a === void 0 ? void 0 : _a.close();
196
+ this._formWindowRef?.close();
200
197
  }
201
198
  }
202
- OpenFormDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0, type: OpenFormDirective, deps: [{ token: RXAP_WINDOW_FORM_SYSTEM_OPEN_FORM_CONSTRUCTOR, optional: true }, { token: FormWindowService }, { token: INJECTOR }], target: i0.ɵɵFactoryTarget.Directive });
203
- OpenFormDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.0.1", type: OpenFormDirective, selector: "[rxapOpenForm]", inputs: { type: "type", formDefinitionConstructor: ["rxapOpenForm", "formDefinitionConstructor"], initial: "initial", title: "title", icon: "icon", width: "width", height: "height", resizeable: "resizeable", draggable: "draggable", panelClass: "panelClass", onSubmit: "onSubmit" }, outputs: { submitted: "submitted" }, host: { listeners: { "click": "onClick()", "confirmed": "onConfirm()" }, properties: { "attr.type": "this.type" } }, usesInheritance: true, ngImport: i0 });
199
+ OpenFormDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.3", ngImport: i0, type: OpenFormDirective, deps: [{ token: RXAP_WINDOW_FORM_SYSTEM_OPEN_FORM_CONSTRUCTOR, optional: true }, { token: FormWindowService }, { token: INJECTOR }], target: i0.ɵɵFactoryTarget.Directive });
200
+ OpenFormDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.2.3", type: OpenFormDirective, selector: "[rxapOpenForm]", inputs: { type: "type", formDefinitionConstructor: ["rxapOpenForm", "formDefinitionConstructor"], initial: "initial", title: "title", icon: "icon", width: "width", height: "height", resizeable: "resizeable", draggable: "draggable", panelClass: "panelClass", onSubmit: "onSubmit" }, outputs: { submitted: "submitted" }, host: { listeners: { "click": "onClick()", "confirmed": "onConfirm()" }, properties: { "attr.type": "this.type" } }, usesInheritance: true, ngImport: i0 });
204
201
  __decorate([
205
202
  Required,
206
203
  __metadata("design:type", Object)
207
204
  ], OpenFormDirective.prototype, "_formDefinitionConstructor", void 0);
208
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0, type: OpenFormDirective, decorators: [{
205
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.3", ngImport: i0, type: OpenFormDirective, decorators: [{
209
206
  type: Directive,
210
207
  args: [{
211
208
  selector: '[rxapOpenForm]',
@@ -259,10 +256,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.1", ngImpor
259
256
  */
260
257
  class OpenFormDirectiveModule {
261
258
  }
262
- OpenFormDirectiveModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0, type: OpenFormDirectiveModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
263
- OpenFormDirectiveModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0, type: OpenFormDirectiveModule, declarations: [OpenFormDirective], exports: [OpenFormDirective] });
264
- OpenFormDirectiveModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0, type: OpenFormDirectiveModule });
265
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0, type: OpenFormDirectiveModule, decorators: [{
259
+ OpenFormDirectiveModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.3", ngImport: i0, type: OpenFormDirectiveModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
260
+ OpenFormDirectiveModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.2.3", ngImport: i0, type: OpenFormDirectiveModule, declarations: [OpenFormDirective], exports: [OpenFormDirective] });
261
+ OpenFormDirectiveModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.2.3", ngImport: i0, type: OpenFormDirectiveModule });
262
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.3", ngImport: i0, type: OpenFormDirectiveModule, decorators: [{
266
263
  type: NgModule,
267
264
  args: [{
268
265
  exports: [OpenFormDirective],
@@ -294,9 +291,9 @@ class FormWindowFooterDirective {
294
291
  }));
295
292
  }
296
293
  }
297
- FormWindowFooterDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0, type: FormWindowFooterDirective, deps: [{ token: FormDirective }, { token: RXAP_WINDOW_REF }, { token: TemplateRef }, { token: ViewContainerRef }], target: i0.ɵɵFactoryTarget.Directive });
298
- FormWindowFooterDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.0.1", type: FormWindowFooterDirective, selector: "[rxapFormWindowFooter]", ngImport: i0 });
299
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0, type: FormWindowFooterDirective, decorators: [{
294
+ FormWindowFooterDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.3", ngImport: i0, type: FormWindowFooterDirective, deps: [{ token: FormDirective }, { token: RXAP_WINDOW_REF }, { token: TemplateRef }, { token: ViewContainerRef }], target: i0.ɵɵFactoryTarget.Directive });
295
+ FormWindowFooterDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.2.3", type: FormWindowFooterDirective, selector: "[rxapFormWindowFooter]", ngImport: i0 });
296
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.3", ngImport: i0, type: FormWindowFooterDirective, decorators: [{
300
297
  type: Directive,
301
298
  args: [{
302
299
  selector: '[rxapFormWindowFooter]'
@@ -316,10 +313,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.1", ngImpor
316
313
  }] }]; } });
317
314
  class FormWindowFooterDirectiveModule {
318
315
  }
319
- FormWindowFooterDirectiveModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0, type: FormWindowFooterDirectiveModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
320
- FormWindowFooterDirectiveModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0, type: FormWindowFooterDirectiveModule, declarations: [FormWindowFooterDirective], exports: [FormWindowFooterDirective] });
321
- FormWindowFooterDirectiveModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0, type: FormWindowFooterDirectiveModule });
322
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0, type: FormWindowFooterDirectiveModule, decorators: [{
316
+ FormWindowFooterDirectiveModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.3", ngImport: i0, type: FormWindowFooterDirectiveModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
317
+ FormWindowFooterDirectiveModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.2.3", ngImport: i0, type: FormWindowFooterDirectiveModule, declarations: [FormWindowFooterDirective], exports: [FormWindowFooterDirective] });
318
+ FormWindowFooterDirectiveModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.2.3", ngImport: i0, type: FormWindowFooterDirectiveModule });
319
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.3", ngImport: i0, type: FormWindowFooterDirectiveModule, decorators: [{
323
320
  type: NgModule,
324
321
  args: [{
325
322
  exports: [FormWindowFooterDirective],
@@ -339,13 +336,18 @@ class OpenFormWindowMethod {
339
336
  this.defaultOptions = defaultOptions;
340
337
  }
341
338
  call(initial, options) {
342
- var _a, _b, _c, _d, _e;
343
- return this.formWindowService.open(this.formDefinitionConstructor, Object.assign(Object.assign(Object.assign(Object.assign({}, ((_a = this.defaultOptions) !== null && _a !== void 0 ? _a : {})), { injector: this.injector }), (options !== null && options !== void 0 ? options : {})), { initial: initial !== null && initial !== void 0 ? initial : (_b = this.defaultOptions) === null || _b === void 0 ? void 0 : _b.initial, component: (_e = (_c = this.formComponent) !== null && _c !== void 0 ? _c : (_d = this.defaultOptions) === null || _d === void 0 ? void 0 : _d.component) !== null && _e !== void 0 ? _e : undefined }));
339
+ return this.formWindowService.open(this.formDefinitionConstructor, {
340
+ ...(this.defaultOptions ?? {}),
341
+ injector: this.injector,
342
+ ...(options ?? {}),
343
+ initial: initial ?? this.defaultOptions?.initial,
344
+ component: this.formComponent ?? this.defaultOptions?.component ?? undefined,
345
+ });
344
346
  }
345
347
  }
346
- OpenFormWindowMethod.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0, type: OpenFormWindowMethod, deps: [{ token: FormWindowService }, { token: RXAP_FORM_WINDOW_SYSTEM_OPEN_FORM_DEFINITION_CONSTRUCTOR }, { token: INJECTOR }, { token: RXAP_FORM_WINDOW_SYSTEM_OPEN_FORM_COMPONENT, optional: true }, { token: RXAP_FORM_WINDOW_SYSTEM_OPEN_FORM_DEFAULT_OPTIONS, optional: true }], target: i0.ɵɵFactoryTarget.Injectable });
347
- OpenFormWindowMethod.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0, type: OpenFormWindowMethod });
348
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0, type: OpenFormWindowMethod, decorators: [{
348
+ OpenFormWindowMethod.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.3", ngImport: i0, type: OpenFormWindowMethod, deps: [{ token: FormWindowService }, { token: RXAP_FORM_WINDOW_SYSTEM_OPEN_FORM_DEFINITION_CONSTRUCTOR }, { token: INJECTOR }, { token: RXAP_FORM_WINDOW_SYSTEM_OPEN_FORM_COMPONENT, optional: true }, { token: RXAP_FORM_WINDOW_SYSTEM_OPEN_FORM_DEFAULT_OPTIONS, optional: true }], target: i0.ɵɵFactoryTarget.Injectable });
349
+ OpenFormWindowMethod.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.2.3", ngImport: i0, type: OpenFormWindowMethod });
350
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.3", ngImport: i0, type: OpenFormWindowMethod, decorators: [{
349
351
  type: Injectable
350
352
  }], ctorParameters: function () { return [{ type: FormWindowService, decorators: [{
351
353
  type: Inject,
@@ -427,9 +429,9 @@ class OpenFormWindowMethodDirective {
427
429
  this.completed$.emit();
428
430
  }
429
431
  }
430
- OpenFormWindowMethodDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0, type: OpenFormWindowMethodDirective, deps: [{ token: INJECTOR, optional: true }], target: i0.ɵɵFactoryTarget.Directive });
431
- OpenFormWindowMethodDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.0.1", type: OpenFormWindowMethodDirective, selector: "[rxapOpenFormWindowMethod]", inputs: { method: ["rxapOpenFormWindowMethod", "method"], initial: "initial", hasConfirmDirective: ["rxapConfirm", "hasConfirmDirective"], providers: "providers" }, outputs: { failure$: "failure", completed$: "completed", submitted$: "submitted" }, host: { listeners: { "confirmed": "onConfirmed()", "click": "onClick()" } }, ngImport: i0 });
432
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0, type: OpenFormWindowMethodDirective, decorators: [{
432
+ OpenFormWindowMethodDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.3", ngImport: i0, type: OpenFormWindowMethodDirective, deps: [{ token: INJECTOR, optional: true }], target: i0.ɵɵFactoryTarget.Directive });
433
+ OpenFormWindowMethodDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "13.2.3", type: OpenFormWindowMethodDirective, selector: "[rxapOpenFormWindowMethod]", inputs: { method: ["rxapOpenFormWindowMethod", "method"], initial: "initial", hasConfirmDirective: ["rxapConfirm", "hasConfirmDirective"], providers: "providers" }, outputs: { failure$: "failure", completed$: "completed", submitted$: "submitted" }, host: { listeners: { "confirmed": "onConfirmed()", "click": "onClick()" } }, ngImport: i0 });
434
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.3", ngImport: i0, type: OpenFormWindowMethodDirective, decorators: [{
433
435
  type: Directive,
434
436
  args: [{
435
437
  selector: '[rxapOpenFormWindowMethod]'
@@ -467,10 +469,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.1", ngImpor
467
469
  }] } });
468
470
  class OpenFormWindowMethodDirectiveModule {
469
471
  }
470
- OpenFormWindowMethodDirectiveModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0, type: OpenFormWindowMethodDirectiveModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
471
- OpenFormWindowMethodDirectiveModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0, type: OpenFormWindowMethodDirectiveModule, declarations: [OpenFormWindowMethodDirective], exports: [OpenFormWindowMethodDirective] });
472
- OpenFormWindowMethodDirectiveModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0, type: OpenFormWindowMethodDirectiveModule });
473
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.1", ngImport: i0, type: OpenFormWindowMethodDirectiveModule, decorators: [{
472
+ OpenFormWindowMethodDirectiveModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.2.3", ngImport: i0, type: OpenFormWindowMethodDirectiveModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
473
+ OpenFormWindowMethodDirectiveModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.2.3", ngImport: i0, type: OpenFormWindowMethodDirectiveModule, declarations: [OpenFormWindowMethodDirective], exports: [OpenFormWindowMethodDirective] });
474
+ OpenFormWindowMethodDirectiveModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.2.3", ngImport: i0, type: OpenFormWindowMethodDirectiveModule });
475
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.2.3", ngImport: i0, type: OpenFormWindowMethodDirectiveModule, decorators: [{
474
476
  type: NgModule,
475
477
  args: [{
476
478
  exports: [OpenFormWindowMethodDirective],
@@ -483,4 +485,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.0.1", ngImpor
483
485
  */
484
486
 
485
487
  export { FormWindowFooterDirective, FormWindowFooterDirectiveModule, FormWindowRef, FormWindowService, OpenFormDirective, OpenFormDirectiveModule, OpenFormWindowMethod, OpenFormWindowMethodDirective, OpenFormWindowMethodDirectiveModule, RXAP_FORM_WINDOW_SYSTEM_OPEN_FORM_COMPONENT, RXAP_FORM_WINDOW_SYSTEM_OPEN_FORM_DEFAULT_OPTIONS, RXAP_FORM_WINDOW_SYSTEM_OPEN_FORM_DEFINITION_CONSTRUCTOR, RXAP_WINDOW_FORM_SYSTEM_OPEN_FORM_CONSTRUCTOR };
486
- //# sourceMappingURL=rxap-form-window-system.js.map
488
+ //# sourceMappingURL=rxap-form-window-system.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"rxap-form-window-system.mjs","sources":["../../../../libs/form-window-system/src/lib/form-window.service.ts","../../../../libs/form-window-system/src/lib/form-window-ref.ts","../../../../libs/form-window-system/src/lib/open-form.directive.ts","../../../../libs/form-window-system/src/lib/form-window-footer.directive.ts","../../../../libs/form-window-system/src/lib/open-form-window.method.ts","../../../../libs/form-window-system/src/lib/open-form-window-method.directive.ts","../../../../libs/form-window-system/src/rxap-form-window-system.ts"],"sourcesContent":["import {\n Injectable,\n Injector,\n Optional,\n StaticProvider,\n Inject,\n INJECTOR,\n InjectFlags\n} from '@angular/core';\nimport {\n WindowService,\n WindowConfig,\n WindowRef\n} from '@rxap/window-system';\nimport {\n RxapFormBuilder,\n FormDefinition,\n RXAP_FORM_DEFINITION_BUILDER,\n RXAP_FORM_DEFINITION,\n RXAP_FORM_INITIAL_STATE,\n FormSubmitMethod,\n RXAP_FORM_SUBMIT_METHOD,\n RXAP_FORM_SUBMIT_SUCCESSFUL_METHOD,\n FormSubmitSuccessfulMethod,\n RXAP_FORM_LOAD_METHOD,\n FormLoadMethod,\n RXAP_FORM_CONTEXT,\n FormType\n} from '@rxap/forms';\nimport {\n Constructor,\n DeleteUndefinedProperties\n} from '@rxap/utilities';\nimport { FormSystemMetadataKeys } from '@rxap/form-system';\nimport { getMetadata } from '@rxap/utilities/reflect-metadata';\n\nexport interface FormWindowOptions<FormData, D = any, T = any>\n extends WindowConfig<D, T> {\n initial?: FormData;\n submitMethod?: FormSubmitMethod<FormData>;\n submitSuccessfulMethod?: FormSubmitSuccessfulMethod;\n providers?: StaticProvider[];\n resetLoad?: boolean;\n resetSubmit?: boolean;\n loadMethod?: FormLoadMethod<FormData>;\n /**\n * Stores the context of the form window.\n * Can be used to transfer the id or uuid of the\n * document the is currently edited\n */\n context?: any;\n}\n\n@Injectable({\n providedIn: 'root',\n})\nexport class FormWindowService {\n constructor(\n @Inject(WindowService)\n private readonly windowService: WindowService,\n @Inject(INJECTOR)\n private readonly injector: Injector\n ) {}\n\n public open<FormData extends Record<string, any>>(\n formDefinitionConstructor: Constructor<FormType<any>>,\n options?: FormWindowOptions<FormData>\n ): WindowRef<FormDefinition, FormData> {\n function FormDefinitionFactory(\n formBuilder: RxapFormBuilder,\n initial?: any\n ): FormDefinition {\n return formBuilder.build(initial);\n }\n\n function FormDefinitionBuilderFactory(\n _injector: Injector\n ): RxapFormBuilder {\n return new RxapFormBuilder(formDefinitionConstructor, _injector);\n }\n\n const providers: StaticProvider[] = options?.providers ?? [];\n\n if ((options?.injector ?? this.injector).get(formDefinitionConstructor, null, InjectFlags.Optional)) {\n providers.push(\n {\n provide: RXAP_FORM_DEFINITION_BUILDER,\n useFactory: FormDefinitionBuilderFactory,\n deps: [ INJECTOR ]\n },\n {\n provide: RXAP_FORM_DEFINITION,\n useFactory: FormDefinitionFactory,\n deps: [\n RXAP_FORM_DEFINITION_BUILDER,\n [ new Optional(), RXAP_FORM_INITIAL_STATE ]\n ]\n }\n );\n }\n\n if (options) {\n if (options.initial) {\n providers.push({\n provide: RXAP_FORM_INITIAL_STATE,\n useValue: options.initial\n });\n }\n if (options.submitMethod) {\n providers.push({\n provide: RXAP_FORM_SUBMIT_METHOD,\n useValue: options.submitMethod,\n });\n }\n if (options.submitSuccessfulMethod) {\n providers.push({\n provide: RXAP_FORM_SUBMIT_SUCCESSFUL_METHOD,\n useValue: options.submitSuccessfulMethod,\n });\n }\n if (options.resetSubmit) {\n providers.push({\n provide: RXAP_FORM_SUBMIT_METHOD,\n useValue: null,\n });\n }\n if (options.resetLoad && !options.loadMethod) {\n providers.push({\n provide: RXAP_FORM_LOAD_METHOD,\n useValue: null,\n });\n }\n if (options.loadMethod) {\n providers.push({\n provide: RXAP_FORM_LOAD_METHOD,\n useValue: options.loadMethod,\n });\n }\n if (options.context) {\n providers.push({\n provide: RXAP_FORM_CONTEXT,\n useValue: options.context,\n });\n }\n }\n\n const injector = Injector.create({\n parent: options?.injector ?? this.injector,\n providers,\n name: options?.injectorName ?? 'FormWindowService',\n });\n\n const component =\n options?.component ??\n this.extractFormComponent(formDefinitionConstructor);\n\n let windowConfig: WindowConfig<any, any> = {\n component,\n injector,\n };\n\n if (options) {\n windowConfig = Object.assign(\n DeleteUndefinedProperties(options),\n windowConfig\n );\n }\n\n return this.windowService.open(windowConfig);\n }\n\n private extractFormComponent(\n formDefinitionConstructor: Constructor<FormType<any>>\n ): Constructor {\n const component =\n getMetadata<Constructor>(\n FormSystemMetadataKeys.FORM_COMPONENT,\n formDefinitionConstructor\n ) ?? null;\n\n if (!component) {\n throw new Error('Could not extract form component constructor');\n }\n\n return component;\n }\n}\n","import { FormDefinition } from \"@rxap/forms\";\nimport { WindowRef } from \"@rxap/window-system\";\nimport { Inject } from \"@angular/core\";\n\n/**\n * @deprecated removed\n */\nexport class FormWindowRef<Data = any> {\n constructor(\n public readonly formDefinition: FormDefinition,\n @Inject(WindowRef)\n public readonly windowRef: WindowRef\n ) {}\n\n public submit() {\n throw new Error('Not yet implemented!');\n }\n\n public reset() {\n throw new Error('Not yet implemented!');\n }\n\n public close(result?: any) {\n this.windowRef.close(result);\n }\n}\n","import {\n Directive,\n Inject,\n InjectionToken,\n Output,\n EventEmitter,\n HostBinding,\n Input,\n Injector,\n INJECTOR,\n OnDestroy,\n NgModule,\n Optional,\n isDevMode,\n} from '@angular/core';\nimport { Constructor, Required, IconConfig } from '@rxap/utilities';\nimport { FormDefinition, ToFormMethod, FormType } from '@rxap/forms';\nimport { FormWindowService } from './form-window.service';\nimport { WindowRef } from '@rxap/window-system';\nimport { ConfirmClick } from '@rxap/directives';\n\n/**\n * @deprecated\n */\nexport const RXAP_WINDOW_FORM_SYSTEM_OPEN_FORM_CONSTRUCTOR = new InjectionToken(\n 'rxap/window-form-system/open-form-constructor'\n);\n\n/**\n * @deprecated\n */\n@Directive({\n selector: '[rxapOpenForm]',\n host: {\n '(click)': 'onClick()',\n '(confirmed)': 'onConfirm()',\n },\n})\nexport class OpenFormDirective<Data, Result = Data>\n extends ConfirmClick\n implements OnDestroy\n{\n @HostBinding('attr.type')\n @Input()\n public type = 'button';\n\n @Output()\n public submitted = new EventEmitter<Result>();\n\n @Input('rxapOpenForm')\n public set formDefinitionConstructor(value: Constructor<FormType<any>> | '') {\n if (value) {\n this._formDefinitionConstructor = value;\n }\n }\n\n @Input()\n public initial?: Data;\n\n private _formWindowRef?: WindowRef;\n\n @Required\n private _formDefinitionConstructor!: Constructor<FormType<any>>;\n\n @Input()\n public title?: string;\n\n @Input()\n public icon?: IconConfig;\n\n @Input()\n public width?: string;\n\n @Input()\n public height?: string;\n\n @Input()\n public resizeable?: boolean;\n\n @Input()\n public draggable?: boolean;\n\n @Input()\n public panelClass?: string;\n\n constructor(\n @Optional()\n @Inject(RXAP_WINDOW_FORM_SYSTEM_OPEN_FORM_CONSTRUCTOR)\n formDefinitionConstructor: Constructor<FormType<any>> | null,\n @Inject(FormWindowService)\n private readonly formWindowService: FormWindowService,\n @Inject(INJECTOR)\n private readonly injector: Injector\n ) {\n super();\n if (formDefinitionConstructor) {\n this._formDefinitionConstructor = formDefinitionConstructor;\n }\n }\n\n @Input()\n public onSubmit(value: Data): any | Promise<any> {\n if (isDevMode()) {\n console.warn('[rxapOpenForm] No \"onSubmit\" method is provided!');\n }\n return value;\n }\n\n protected execute() {\n this._formWindowRef = this.formWindowService.open(\n this._formDefinitionConstructor,\n {\n injector: this.injector,\n submitSuccessfulMethod: ToFormMethod(\n this.onSubmitSuccessful.bind(this)\n ),\n initial: this.initial,\n injectorName: 'OpenFormDirective',\n title: this.title,\n icon: this.icon,\n width: this.width,\n resizeable: this.resizeable,\n draggable: this.draggable,\n panelClass: this.panelClass,\n }\n );\n }\n\n public onSubmitSuccessful(result: Result): void {\n this.submitted.emit(result);\n this._formWindowRef?.close();\n }\n\n public ngOnDestroy() {\n this._formWindowRef?.close();\n }\n}\n\n/**\n * @deprecated\n */\n@NgModule({\n exports: [OpenFormDirective],\n declarations: [OpenFormDirective],\n})\nexport class OpenFormDirectiveModule {}\n","import {\n Directive,\n NgModule,\n OnInit,\n Inject,\n TemplateRef,\n ViewContainerRef\n} from '@angular/core';\nimport {\n WindowRef,\n RXAP_WINDOW_REF\n} from '@rxap/window-system';\nimport {\n FormDirective,\n FormDefinition\n} from '@rxap/forms';\nimport { TemplatePortal } from '@angular/cdk/portal';\n\nexport interface FormWindowFooterTemplateContext<Data = any> {\n $implicit: WindowRef;\n formDirective: FormDirective<Data>;\n formDefinition: FormDefinition<Data>;\n}\n\n@Directive({\n selector: '[rxapFormWindowFooter]'\n})\nexport class FormWindowFooterDirective<Data> implements OnInit {\n\n /**\n * Asserts the correct type of the context for the template that `NgForOf` will render.\n *\n * The presence of this method is a signal to the Ivy template type-check compiler that the\n * `NgForOf` structural directive renders its template with a specific context type.\n */\n static ngTemplateContextGuard<T>(dir: FormWindowFooterDirective<T>, ctx: any):\n ctx is FormWindowFooterTemplateContext<T> {\n return true;\n }\n\n constructor(\n @Inject(FormDirective)\n private readonly formDirective: FormDirective<Data>,\n @Inject(RXAP_WINDOW_REF)\n private readonly windowRef: WindowRef<Data>,\n @Inject(TemplateRef)\n private readonly template: TemplateRef<FormWindowFooterTemplateContext<Data>>,\n @Inject(ViewContainerRef)\n private readonly viewContainerRef: ViewContainerRef,\n ) { }\n\n public ngOnInit() {\n this.windowRef.setFooterPortal(new TemplatePortal<FormWindowFooterTemplateContext<Data>>(\n this.template,\n this.viewContainerRef,\n {\n $implicit: this.windowRef,\n formDefinition: this.formDirective.formDefinition,\n formDirective: this.formDirective,\n }\n ));\n }\n\n}\n\n@NgModule({\n exports: [ FormWindowFooterDirective ],\n declarations: [ FormWindowFooterDirective ]\n})\nexport class FormWindowFooterDirectiveModule {}\n","import { Constructor } from '@rxap/utilities';\nimport {\n Injectable,\n InjectionToken,\n Inject,\n Optional,\n Injector,\n INJECTOR\n} from '@angular/core';\nimport {\n FormDefinition,\n FormType\n} from '@rxap/forms';\nimport { ComponentType } from '@angular/cdk/portal';\nimport {\n FormWindowService,\n FormWindowOptions\n} from './form-window.service';\nimport { WindowRef } from '@rxap/window-system';\nimport { Method } from '@rxap/utilities/rxjs';\n\nexport const RXAP_FORM_WINDOW_SYSTEM_OPEN_FORM_DEFINITION_CONSTRUCTOR =\n new InjectionToken(\n 'rxap/form-window-system/open-form/definition-constructor'\n );\nexport const RXAP_FORM_WINDOW_SYSTEM_OPEN_FORM_DEFAULT_OPTIONS =\n new InjectionToken('rxap/form-window-system/open-form/default-options');\nexport const RXAP_FORM_WINDOW_SYSTEM_OPEN_FORM_COMPONENT = new InjectionToken(\n 'rxap/form-window-system/open-form/component'\n);\n\n@Injectable()\nexport class OpenFormWindowMethod<\n FormData extends Record<string, any> = Record<string, any>\n> implements Method<WindowRef<FormDefinition, FormData>, Partial<FormData>>\n{\n constructor(\n @Inject(FormWindowService)\n private readonly formWindowService: FormWindowService,\n @Inject(RXAP_FORM_WINDOW_SYSTEM_OPEN_FORM_DEFINITION_CONSTRUCTOR)\n private readonly formDefinitionConstructor: Constructor<FormType<FormData>>,\n @Inject(INJECTOR)\n private readonly injector: Injector,\n @Optional()\n @Inject(RXAP_FORM_WINDOW_SYSTEM_OPEN_FORM_COMPONENT)\n private readonly formComponent: ComponentType<any> | null = null,\n @Optional()\n @Inject(RXAP_FORM_WINDOW_SYSTEM_OPEN_FORM_DEFAULT_OPTIONS)\n private readonly defaultOptions: FormWindowOptions<FormData> | null = null\n ) {}\n\n public call(\n initial?: FormData,\n options?: Partial<FormWindowOptions<FormData>>\n ): WindowRef<FormDefinition, FormData> {\n return this.formWindowService.open<FormData>(\n this.formDefinitionConstructor,\n {\n ...(this.defaultOptions ?? {}),\n injector: this.injector,\n ...(options ?? {}),\n initial: initial ?? this.defaultOptions?.initial,\n component:\n this.formComponent ?? this.defaultOptions?.component ?? undefined,\n }\n );\n }\n}\n","import {\n Directive,\n HostListener,\n Input,\n NgModule,\n EventEmitter,\n Output,\n OnDestroy,\n StaticProvider,\n Injector,\n Inject,\n INJECTOR,\n Optional\n} from '@angular/core';\nimport { coerceBoolean } from '@rxap/utilities';\nimport { WindowRef } from '@rxap/window-system';\nimport { FormDefinition } from '@rxap/forms';\nimport {\n CounterSubject,\n Method\n} from '@rxap/utilities/rxjs';\n\n@Directive({\n selector: '[rxapOpenFormWindowMethod]'\n})\nexport class OpenFormWindowMethodDirective<\n FormData extends Record<string, any> = Record<string, any>,\n Initial extends Partial<Record<string, any>> = Partial<Record<string, any>>>\n implements OnDestroy {\n\n @Input('rxapOpenFormWindowMethod')\n public method!: Method<WindowRef<FormDefinition, FormData>, Initial>;\n\n @Input()\n public initial?: Initial;\n\n @Output('failure')\n public failure$ = new EventEmitter<Error>();\n\n @Output('completed')\n public completed$ = new EventEmitter();\n\n @Output('submitted')\n public submitted$ = new EventEmitter<FormData>();\n\n @Input('rxapConfirm')\n public set hasConfirmDirective(value: any) {\n this._hasConfirmDirective = coerceBoolean(value);\n }\n\n /**\n * true - a remote method call is in progress\n */\n public executing$ = new CounterSubject(0);\n\n private _hasConfirmDirective = false;\n\n /**\n * Set of all active window ref instances.\n *\n * Used to distory all windows of the directive is\n * destroyed\n * @protected\n */\n protected _windowRefInstance = new Set<WindowRef<FormDefinition, FormData>>();\n\n @Input()\n public providers?: StaticProvider[];\n\n constructor(\n @Optional()\n @Inject(INJECTOR)\n private readonly injector: Injector | null = null\n ) {}\n\n public ngOnDestroy() {\n this._windowRefInstance.forEach(windowRef => windowRef.complete());\n }\n\n @HostListener('confirmed')\n public onConfirmed() {\n this.execute();\n }\n\n @HostListener('click')\n public onClick() {\n if (!this._hasConfirmDirective) {\n this.execute();\n } else {\n console.debug('skip remote method call. Wait for confirmation.');\n }\n }\n\n public execute(): void {\n this.executing$.increase();\n\n const windowRef = this.method.call(this.initial, {\n providers: this.providers,\n injector: this.injector\n }) as WindowRef<FormDefinition, FormData>;\n\n windowRef.subscribe(\n (value) => this.submitted(value),\n (error) => this.failure(error),\n () => {\n this.completed();\n this.executing$.decrease();\n this._windowRefInstance.delete(windowRef);\n }\n );\n }\n\n protected submitted(value: FormData) {\n this.submitted$.emit(value);\n }\n\n protected failure(error: Error): void {\n this.failure$.emit(error);\n }\n\n protected completed(): void {\n this.completed$.emit();\n }\n\n}\n\n@NgModule({\n exports: [OpenFormWindowMethodDirective],\n declarations: [OpenFormWindowMethodDirective]\n})\nexport class OpenFormWindowMethodDirectiveModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;;;MAwDa,iBAAiB;IAC5B,YAEmB,aAA4B,EAE5B,QAAkB;QAFlB,kBAAa,GAAb,aAAa,CAAe;QAE5B,aAAQ,GAAR,QAAQ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B;gBAI1B,OAAO;sBADb,KAAK;gBAIC,QAAQ;sBADd,MAAM;uBAAC,SAAS;gBAIV,UAAU;sBADhB,MAAM;uBAAC,WAAW;gBAIZ,UAAU;sBADhB,MAAM;uBAAC,WAAW;gBAIR,mBAAmB;sBAD7B,KAAK;uBAAC,aAAa;gBAsBb,SAAS;sBADf,KAAK;gBAcC,WAAW;sBADjB,YAAY;uBAAC,WAAW;gBAMlB,OAAO;sBADb,YAAY;uBAAC,OAAO;;MA8CV,mCAAmC;;gIAAnC,mCAAmC;iIAAnC,mCAAmC,iBAzGnC,6BAA6B,aAA7B,6BAA6B;iIAyG7B,mCAAmC;2FAAnC,mCAAmC;kBAJ/C,QAAQ;mBAAC;oBACR,OAAO,EAAE,CAAC,6BAA6B,CAAC;oBACxC,YAAY,EAAE,CAAC,6BAA6B,CAAC;iBAC9C;;;ACjID;;;;;;"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rxap/form-window-system",
3
- "version": "12.1.8-next.0",
3
+ "version": "13.0.0-next.1",
4
4
  "author": "Merzough Münker",
5
5
  "homepage": "https://gitlab.com/rxap/packages/libs/form-window-system",
6
6
  "repository": "git@gitlab.com:rxap/packages.git",
@@ -18,25 +18,29 @@
18
18
  "description": "Provides the FormSystem concept for RxAP.",
19
19
  "license": "MIT",
20
20
  "peerDependencies": {
21
- "@angular/cdk": "^12.0.1",
22
- "@angular/common": "^12.0.1",
23
- "@angular/core": "^12.0.1",
24
- "@angular/flex-layout": "^12.0.0-beta.34",
25
- "@angular/forms": "^12.0.1",
26
- "@angular/material": "^12.0.1",
27
- "@angular/platform-browser": "^12.0.1",
28
- "@angular/router": "^12.0.1",
29
- "@rxap/components": "^12.0.10",
30
- "@rxap/data-source": "^12.1.3-next.0",
31
- "@rxap/definition": "^12.0.8",
32
- "@rxap/directives": "^12.1.2",
33
- "@rxap/form-system": "^12.0.11",
34
- "@rxap/forms": "^12.5.1-next.2",
35
- "@rxap/material-directives": "^12.0.6",
36
- "@rxap/mixin": "^12.0.7",
37
- "@rxap/services": "^12.0.7",
38
- "@rxap/utilities": "^12.2.1",
39
- "@rxap/window-system": "^12.0.9",
21
+ "@angular-devkit/schematics": "^13.2.4",
22
+ "@angular/cdk": "^13.2.3",
23
+ "@angular/common": "^13.2.3",
24
+ "@angular/core": "^13.2.3",
25
+ "@angular/flex-layout": "^13.0.0-beta.38",
26
+ "@angular/forms": "^13.2.3",
27
+ "@angular/localize": "^13.2.3",
28
+ "@angular/material": "^13.2.3",
29
+ "@angular/platform-browser": "^13.2.3",
30
+ "@angular/platform-browser-dynamic": "^13.2.3",
31
+ "@angular/router": "^13.2.3",
32
+ "@rxap/components": "^13.0.0-next.1",
33
+ "@rxap/config": "^13.0.0-next.1",
34
+ "@rxap/data-source": "^13.0.0-next.1",
35
+ "@rxap/definition": "^13.0.0-next.1",
36
+ "@rxap/directives": "^13.0.0-next.2",
37
+ "@rxap/form-system": "^13.0.0-next.2",
38
+ "@rxap/forms": "^13.0.0-next.1",
39
+ "@rxap/material-directives": "^13.0.0-next.1",
40
+ "@rxap/mixin": "^13.0.0-next.1",
41
+ "@rxap/services": "^13.0.0-next.1",
42
+ "@rxap/utilities": "^13.0.0-next.1",
43
+ "@rxap/window-system": "^13.0.0-next.1",
40
44
  "reflect-metadata": "^0.1.13",
41
45
  "rxjs": "^6.5.5"
42
46
  },
@@ -45,6 +49,7 @@
45
49
  "migrations": "./migration.json",
46
50
  "packageGroup": [
47
51
  "@rxap/components",
52
+ "@rxap/config",
48
53
  "@rxap/data-source",
49
54
  "@rxap/definition",
50
55
  "@rxap/directives",
@@ -67,16 +72,30 @@
67
72
  "save": "dependencies"
68
73
  },
69
74
  "dependencies": {
70
- "@rxap/schematics-utilities": "^12.6.0",
71
- "tslib": "^2.2.0",
75
+ "@rxap/schematics-utilities": "^13.0.0-next.0",
76
+ "tslib": "^2.3.1",
77
+ "@rxap/schematics-ts-morph": "^13.0.0-next.0",
72
78
  "uuid": "8.3.2",
73
- "@rxap/validator": "0.0.2"
79
+ "@rxap/validator": "1.0.0-next.0"
74
80
  },
75
- "main": "bundles/rxap-form-window-system.umd.js",
76
- "module": "fesm2015/rxap-form-window-system.js",
77
- "es2015": "fesm2015/rxap-form-window-system.js",
78
- "esm2015": "esm2015/rxap-form-window-system.js",
79
- "fesm2015": "fesm2015/rxap-form-window-system.js",
81
+ "module": "fesm2015/rxap-form-window-system.mjs",
82
+ "es2020": "fesm2020/rxap-form-window-system.mjs",
83
+ "esm2020": "esm2020/rxap-form-window-system.mjs",
84
+ "fesm2020": "fesm2020/rxap-form-window-system.mjs",
85
+ "fesm2015": "fesm2015/rxap-form-window-system.mjs",
80
86
  "typings": "rxap-form-window-system.d.ts",
87
+ "exports": {
88
+ "./package.json": {
89
+ "default": "./package.json"
90
+ },
91
+ ".": {
92
+ "types": "./rxap-form-window-system.d.ts",
93
+ "esm2020": "./esm2020/rxap-form-window-system.mjs",
94
+ "es2020": "./fesm2020/rxap-form-window-system.mjs",
95
+ "es2015": "./fesm2015/rxap-form-window-system.mjs",
96
+ "node": "./fesm2015/rxap-form-window-system.mjs",
97
+ "default": "./fesm2020/rxap-form-window-system.mjs"
98
+ }
99
+ },
81
100
  "sideEffects": false
82
101
  }
@@ -2,7 +2,7 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const schematics_utilities_1 = require("@rxap/schematics-utilities");
4
4
  function default_1() {
5
- return schematics_utilities_1.InstallPeerDependencies();
5
+ return (0, schematics_utilities_1.InstallPeerDependencies)();
6
6
  }
7
7
  exports.default = default_1;
8
8
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../libs/form-window-system/src/schematics/ng-add/index.ts"],"names":[],"mappings":";;AACA,qEAAqE;AAErE;IACE,OAAO,8CAAuB,EAAE,CAAC;AACnC,CAAC;AAFD,4BAEC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../libs/form-window-system/src/schematics/ng-add/index.ts"],"names":[],"mappings":";;AACA,qEAAqE;AAErE;IACE,OAAO,IAAA,8CAAuB,GAAE,CAAC;AACnC,CAAC;AAFD,4BAEC"}