xt-plugin-sample 0.4.8 → 0.5.0

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.
@@ -3,28 +3,28 @@ import { ChangeDetectionStrategy, Component, inject, Injector, signal, computed,
3
3
  import { XtSimpleComponent, XtCompositeComponent, XtRenderSubComponent } from 'xt-components';
4
4
  import * as i1 from '@angular/forms';
5
5
  import { ReactiveFormsModule } from '@angular/forms';
6
- import * as i3 from 'primeng/inputnumber';
6
+ import * as i2$1 from 'primeng/inputnumber';
7
7
  import { InputNumberModule } from 'primeng/inputnumber';
8
- import * as i1$1 from '@angular/common';
8
+ import * as i3 from '@angular/common';
9
9
  import { CommonModule } from '@angular/common';
10
10
  import * as i2 from 'primeng/inputtext';
11
11
  import { InputTextModule } from 'primeng/inputtext';
12
12
  import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
13
13
 
14
14
  class SampleHelloComponent extends XtSimpleComponent {
15
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.10", ngImport: i0, type: SampleHelloComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
16
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.10", type: SampleHelloComponent, isStandalone: true, selector: "xt-sample-hello", usesInheritance: true, ngImport: i0, template: "<p>Hello {{getValue()}}</p>\n", styles: [""], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
15
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.2.3", ngImport: i0, type: SampleHelloComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
16
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.2.3", type: SampleHelloComponent, isStandalone: true, selector: "xt-sample-hello", usesInheritance: true, ngImport: i0, template: "<p>Hello {{getValue()}}</p>\n", styles: [""], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
17
17
  }
18
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.10", ngImport: i0, type: SampleHelloComponent, decorators: [{
18
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.2.3", ngImport: i0, type: SampleHelloComponent, decorators: [{
19
19
  type: Component,
20
20
  args: [{ selector: 'xt-sample-hello', standalone: true, imports: [], changeDetection: ChangeDetectionStrategy.OnPush, template: "<p>Hello {{getValue()}}</p>\n" }]
21
21
  }] });
22
22
 
23
23
  class SampleCurrencyComponent extends XtSimpleComponent {
24
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.10", ngImport: i0, type: SampleCurrencyComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
25
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.10", type: SampleCurrencyComponent, isStandalone: true, selector: "xt-sample-currency", usesInheritance: true, ngImport: i0, template: "@if (isInForm() ) {\n <ng-container [formGroup]=\"formGroup()\">\n <input type=\"text\" pInputText [name]=\"componentNameInForm ()\" [formControlName]=\"formControlName()\" />\n </ng-container>\n} @else {\n {{ context().displayValue() }}\n}\n", styles: [""], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: InputNumberModule }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "ngmodule", type: InputTextModule }, { kind: "directive", type: i2.InputText, selector: "[pInputText]", inputs: ["variant", "fluid", "pSize"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
24
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.2.3", ngImport: i0, type: SampleCurrencyComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
25
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.2.3", type: SampleCurrencyComponent, isStandalone: true, selector: "xt-sample-currency", usesInheritance: true, ngImport: i0, template: "@if (isInForm() ) {\n <ng-container [formGroup]=\"formGroup()\">\n <input type=\"text\" pInputText [name]=\"componentNameInForm ()\" [formControlName]=\"formControlName()\" />\n </ng-container>\n} @else {\n {{ context().displayValue() }}\n}\n", styles: [""], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: InputNumberModule }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "ngmodule", type: InputTextModule }, { kind: "directive", type: i2.InputText, selector: "[pInputText]", inputs: ["pSize", "variant", "fluid", "invalid"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
26
26
  }
27
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.10", ngImport: i0, type: SampleCurrencyComponent, decorators: [{
27
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.2.3", ngImport: i0, type: SampleCurrencyComponent, decorators: [{
28
28
  type: Component,
29
29
  args: [{ selector: 'xt-sample-currency', standalone: true, imports: [CommonModule, InputNumberModule, ReactiveFormsModule, InputTextModule], changeDetection: ChangeDetectionStrategy.OnPush, template: "@if (isInForm() ) {\n <ng-container [formGroup]=\"formGroup()\">\n <input type=\"text\" pInputText [name]=\"componentNameInForm ()\" [formControlName]=\"formControlName()\" />\n </ng-container>\n} @else {\n {{ context().displayValue() }}\n}\n" }]
30
30
  }] });
@@ -34,7 +34,7 @@ class SampleMoneyComponent extends XtCompositeComponent {
34
34
  super(...arguments);
35
35
  this.injector = inject(Injector);
36
36
  // Force a recalculation of currency
37
- this.recalculate = signal(true);
37
+ this.recalculate = signal(true, ...(ngDevMode ? [{ debugName: "recalculate" }] : []));
38
38
  this.currency = computed(() => {
39
39
  // console.debug("Calculating currency in XtMoneyComponent");
40
40
  this.recalculate();
@@ -42,7 +42,7 @@ class SampleMoneyComponent extends XtCompositeComponent {
42
42
  if (value?.currency == null)
43
43
  return undefined;
44
44
  return value.currency;
45
- });
45
+ }, ...(ngDevMode ? [{ debugName: "currency" }] : []));
46
46
  this.isValidCurrency = computed(() => {
47
47
  const cur = this.currency();
48
48
  if (cur == null)
@@ -52,10 +52,10 @@ class SampleMoneyComponent extends XtCompositeComponent {
52
52
  }
53
53
  else
54
54
  return false;
55
- });
55
+ }, ...(ngDevMode ? [{ debugName: "isValidCurrency" }] : []));
56
56
  this.amount = computed(() => {
57
57
  return this.context().displayValue()?.amount;
58
- });
58
+ }, ...(ngDevMode ? [{ debugName: "amount" }] : []));
59
59
  }
60
60
  ngOnInit() {
61
61
  super.ngOnInit();
@@ -72,10 +72,10 @@ class SampleMoneyComponent extends XtCompositeComponent {
72
72
  }
73
73
  });
74
74
  }
75
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.10", ngImport: i0, type: SampleMoneyComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
76
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.10", type: SampleMoneyComponent, isStandalone: true, selector: "xt-sample-money", usesInheritance: true, ngImport: i0, template: "@if (isInForm() ) {\n @let cur = currency();\n <ng-container [formGroup]=\"formGroup()\">\n <xt-render-sub [context]=\"subContext('currency', 'sampleCurrency')\" />\n @if (isValidCurrency()) {\n <p-inputNumber mode=\"currency\" [currency]=\"cur\" formControlName=\"amount\" />\n } @else {\n <p-inputNumber mode=\"decimal\" formControlName=\"amount\" />\n }\n </ng-container>\n} @else {\n @let displayAmount = amount();\n @if (displayAmount) {\n {{ displayAmount | currency : currency() }}\n }\n}\n", styles: [""], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "pipe", type: i1$1.CurrencyPipe, name: "currency" }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "component", type: XtRenderSubComponent, selector: "xt-render-sub", inputs: ["context", "componentType", "inputs"], outputs: ["outputs"] }, { kind: "ngmodule", type: InputNumberModule }, { kind: "component", type: i3.InputNumber, selector: "p-inputNumber, p-inputnumber, p-input-number", inputs: ["showButtons", "format", "buttonLayout", "inputId", "styleClass", "style", "placeholder", "size", "maxlength", "tabindex", "title", "ariaLabelledBy", "ariaDescribedBy", "ariaLabel", "ariaRequired", "name", "required", "autocomplete", "min", "max", "incrementButtonClass", "decrementButtonClass", "incrementButtonIcon", "decrementButtonIcon", "readonly", "step", "allowEmpty", "locale", "localeMatcher", "mode", "currency", "currencyDisplay", "useGrouping", "variant", "minFractionDigits", "maxFractionDigits", "prefix", "suffix", "inputStyle", "inputStyleClass", "showClear", "autofocus", "disabled", "fluid"], outputs: ["onInput", "onFocus", "onBlur", "onKeyDown", "onClear"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
75
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.2.3", ngImport: i0, type: SampleMoneyComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
76
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.2.3", type: SampleMoneyComponent, isStandalone: true, selector: "xt-sample-money", usesInheritance: true, ngImport: i0, template: "@if (isInForm() ) {\n @let cur = currency();\n <ng-container [formGroup]=\"formGroup()\">\n <xt-render-sub [context]=\"subContext('currency', 'sampleCurrency')\" />\n @if (isValidCurrency()) {\n <p-inputNumber mode=\"currency\" [currency]=\"cur\" formControlName=\"amount\" />\n } @else {\n <p-inputNumber mode=\"decimal\" formControlName=\"amount\" />\n }\n </ng-container>\n} @else {\n @let displayAmount = amount();\n @if (displayAmount) {\n {{ displayAmount | currency : currency() }}\n }\n}\n", styles: [""], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i1.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i1.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "component", type: XtRenderSubComponent, selector: "xt-render-sub", inputs: ["context", "componentType", "inputs"], outputs: ["outputs"] }, { kind: "ngmodule", type: InputNumberModule }, { kind: "component", type: i2$1.InputNumber, selector: "p-inputNumber, p-inputnumber, p-input-number", inputs: ["showButtons", "format", "buttonLayout", "inputId", "styleClass", "placeholder", "tabindex", "title", "ariaLabelledBy", "ariaDescribedBy", "ariaLabel", "ariaRequired", "autocomplete", "incrementButtonClass", "decrementButtonClass", "incrementButtonIcon", "decrementButtonIcon", "readonly", "allowEmpty", "locale", "localeMatcher", "mode", "currency", "currencyDisplay", "useGrouping", "minFractionDigits", "maxFractionDigits", "prefix", "suffix", "inputStyle", "inputStyleClass", "showClear", "autofocus"], outputs: ["onInput", "onFocus", "onBlur", "onKeyDown", "onClear"] }, { kind: "pipe", type: i3.CurrencyPipe, name: "currency" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
77
77
  }
78
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.10", ngImport: i0, type: SampleMoneyComponent, decorators: [{
78
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.2.3", ngImport: i0, type: SampleMoneyComponent, decorators: [{
79
79
  type: Component,
80
80
  args: [{ selector: 'xt-sample-money', standalone: true, imports: [CommonModule, ReactiveFormsModule, XtRenderSubComponent, InputNumberModule], changeDetection: ChangeDetectionStrategy.OnPush, template: "@if (isInForm() ) {\n @let cur = currency();\n <ng-container [formGroup]=\"formGroup()\">\n <xt-render-sub [context]=\"subContext('currency', 'sampleCurrency')\" />\n @if (isValidCurrency()) {\n <p-inputNumber mode=\"currency\" [currency]=\"cur\" formControlName=\"amount\" />\n } @else {\n <p-inputNumber mode=\"decimal\" formControlName=\"amount\" />\n }\n </ng-container>\n} @else {\n @let displayAmount = amount();\n @if (displayAmount) {\n {{ displayAmount | currency : currency() }}\n }\n}\n" }]
81
81
  }] });
@@ -1 +1 @@
1
- {"version":3,"file":"xt-plugin-sample.mjs","sources":["../../../projects/sample/src/lib/hello/sample-hello.component.ts","../../../projects/sample/src/lib/hello/sample-hello.component.html","../../../projects/sample/src/lib/currency/sample-currency.component.ts","../../../projects/sample/src/lib/currency/sample-currency.component.html","../../../projects/sample/src/lib/money/sample-money.component.ts","../../../projects/sample/src/lib/money/sample-money.component.html","../../../projects/sample/src/lib/register.ts","../../../projects/sample/src/public-api.ts","../../../projects/sample/src/xt-plugin-sample.ts"],"sourcesContent":["import { ChangeDetectionStrategy, Component } from '@angular/core';\nimport {XtSimpleComponent} from 'xt-components';\n\n@Component({\n selector: 'xt-sample-hello',\n standalone: true,\n imports: [],\n templateUrl: './sample-hello.component.html',\n styleUrl: './sample-hello.component.css',\n changeDetection: ChangeDetectionStrategy.OnPush\n\n})\nexport class SampleHelloComponent extends XtSimpleComponent<string>{\n\n}\n","<p>Hello {{getValue()}}</p>\n","import { ChangeDetectionStrategy, Component } from '@angular/core';\nimport { ReactiveFormsModule } from '@angular/forms';\nimport { InputNumberModule } from 'primeng/inputnumber';\nimport { XtSimpleComponent } from 'xt-components';\nimport { CommonModule } from '@angular/common';\nimport { InputTextModule } from 'primeng/inputtext';\n\n@Component({\n selector: 'xt-sample-currency',\n standalone: true,\n imports: [CommonModule, InputNumberModule, ReactiveFormsModule, InputTextModule],\n templateUrl: './sample-currency.component.html',\n styleUrl: './sample-currency.component.css',\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class SampleCurrencyComponent extends XtSimpleComponent {\n}\n","@if (isInForm() ) {\n <ng-container [formGroup]=\"formGroup()\">\n <input type=\"text\" pInputText [name]=\"componentNameInForm ()\" [formControlName]=\"formControlName()\" />\n </ng-container>\n} @else {\n {{ context().displayValue() }}\n}\n","import { CommonModule } from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n computed,\n inject,\n Injector,\n OnInit,\n runInInjectionContext,\n signal\n} from '@angular/core';\nimport { ReactiveFormsModule } from '@angular/forms';\nimport { SampleMoney } from './sample-money.model';\nimport { XtCompositeComponent, XtRenderSubComponent } from 'xt-components';\nimport { InputNumberModule } from 'primeng/inputnumber';\nimport { takeUntilDestroyed } from '@angular/core/rxjs-interop';\n\n@Component({\n selector: 'xt-sample-money',\n standalone: true,\n imports: [CommonModule, ReactiveFormsModule, XtRenderSubComponent, InputNumberModule],\n templateUrl: './sample-money.component.html',\n styleUrl: './sample-money.component.css',\n changeDetection: ChangeDetectionStrategy.OnPush\n\n})\nexport class SampleMoneyComponent extends XtCompositeComponent<SampleMoney> implements OnInit {\n injector = inject(Injector);\n\n // Force a recalculation of currency\n recalculate = signal<boolean>(true);\n\n currency= computed<string|undefined>( () => {\n // console.debug(\"Calculating currency in XtMoneyComponent\");\n this.recalculate();\n const value = this.context().value();\n if (value?.currency==null) return undefined;\n\n return value.currency;\n });\n\n isValidCurrency= computed<boolean> ( () => {\n const cur=this.currency();\n if (cur==null) return false;\n if (Intl.supportedValuesOf('currency').indexOf(cur) > -1) {\n return true;\n }else\n return false;\n });\n\n amount = computed<number|undefined>(()=> {\n return this.context().displayValue()?.amount;\n })\n\n override ngOnInit(): void {\n super.ngOnInit();\n// console.debug(\"XtMoneyComponent ngOnInit\");\n const amountCtrl = this.manageFormControl('amount');\n\n // Make sure the display is updated whenever the value change in the formgroup\n runInInjectionContext(this.injector, () => {\n if (amountCtrl?.parent!=null) {\n amountCtrl.parent.valueChanges.pipe(takeUntilDestroyed()).subscribe({\n next: value => {\n this.recalculate.set(!this.recalculate());\n }\n });\n }\n });\n }\n}\n","@if (isInForm() ) {\n @let cur = currency();\n <ng-container [formGroup]=\"formGroup()\">\n <xt-render-sub [context]=\"subContext('currency', 'sampleCurrency')\" />\n @if (isValidCurrency()) {\n <p-inputNumber mode=\"currency\" [currency]=\"cur\" formControlName=\"amount\" />\n } @else {\n <p-inputNumber mode=\"decimal\" formControlName=\"amount\" />\n }\n </ng-container>\n} @else {\n @let displayAmount = amount();\n @if (displayAmount) {\n {{ displayAmount | currency : currency() }}\n }\n}\n","import { XtResolverService } from 'xt-components';\nimport { SampleCurrencyComponent } from './currency/sample-currency.component';\nimport { SampleHelloComponent } from './hello/sample-hello.component';\nimport { SampleMoneyComponent } from './money/sample-money.component';\n\nexport function registerSamplePlugin (resolverService:XtResolverService):string {\n const pluginName = \"Plugin Sample\";\n console.info ('Registering '+pluginName);\n resolverService.registerPlugin ({\n name:pluginName,\n uriLogo:'pluginicon.png',\n components: [\n {\n componentName:'SampleHello',\n componentClass:SampleHelloComponent,\n typesHandled: ['sampleHello']\n },\n {\n componentName:'SampleCurrency',\n componentClass:SampleCurrencyComponent,\n typesHandled: ['sampleCurrency']\n },\n {\n componentName:'SampleMoney',\n componentClass:SampleMoneyComponent,\n typesHandled: ['sampleMoney']\n },\n ],\n types:\n {\n sampleHello:'string',\n sampleCurrency:'string',\n sampleMoney:{\n amount: 'number',\n currency: 'sampleCurrency'\n }\n }\n });\n return pluginName;\n}\n\nexport function registerPlugin (resolverService:XtResolverService):string {\n return registerSamplePlugin(resolverService);\n}\n","/*\n * Public API Surface of sample-plugin\n */\n\nexport * from './lib/hello/sample-hello.component';\nexport * from './lib/currency/sample-currency.component';\nexport * from './lib/money/sample-money.component';\nexport * from './lib/money/sample-money.model';\nexport * from './lib/register';\n\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":["i2"],"mappings":";;;;;;;;;;;;;AAYM,MAAO,oBAAqB,SAAQ,iBAAyB,CAAA;+GAAtD,oBAAoB,EAAA,IAAA,EAAA,IAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAApB,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,IAAA,EAAA,oBAAoB,kG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,aAAa;AAC3B,gBAAA,cAAc,EAAC,oBAAoB;gBACnC,YAAY,EAAE,CAAC,aAAa;AAC7B,aAAA;AACD,YAAA;AACI,gBAAA,aAAa,EAAC,gBAAgB;AAC9B,gBAAA,cAAc,EAAC,uBAAuB;gBACtC,YAAY,EAAE,CAAC,gBAAgB;AAClC,aAAA;AACD,YAAA;AACI,gBAAA,aAAa,EAAC,aAAa;AAC3B,gBAAA,cAAc,EAAC,oBAAoB;gBACnC,YAAY,EAAE,CAAC,aAAa;AAC/B,aAAA;AACJ,SAAA;AACD,QAAA,KAAK,EACD;AACI,YAAA,WAAW,EAAC,QAAQ;AACpB,YAAA,cAAc,EAAC,QAAQ;AACvB,YAAA,WAAW,EAAC;AACV,gBAAA,MAAM,EAAE,QAAQ;AAChB,gBAAA,QAAQ,EAAE;AACX;AACN;AACN,KAAA,CAAC;AACF,IAAA,OAAO,UAAU;AACrB;AAEM,SAAU,cAAc,CAAE,eAAiC,EAAA;AAC/D,IAAA,OAAO,oBAAoB,CAAC,eAAe,CAAC;AAC9C;;AC3CA;;AAEG;;ACFH;;AAEG;;;;"}
1
+ {"version":3,"file":"xt-plugin-sample.mjs","sources":["../../../projects/sample/src/lib/hello/sample-hello.component.ts","../../../projects/sample/src/lib/hello/sample-hello.component.html","../../../projects/sample/src/lib/currency/sample-currency.component.ts","../../../projects/sample/src/lib/currency/sample-currency.component.html","../../../projects/sample/src/lib/money/sample-money.component.ts","../../../projects/sample/src/lib/money/sample-money.component.html","../../../projects/sample/src/lib/register.ts","../../../projects/sample/src/public-api.ts","../../../projects/sample/src/xt-plugin-sample.ts"],"sourcesContent":["import { ChangeDetectionStrategy, Component } from '@angular/core';\nimport {XtSimpleComponent} from 'xt-components';\n\n@Component({\n selector: 'xt-sample-hello',\n standalone: true,\n imports: [],\n templateUrl: './sample-hello.component.html',\n styleUrl: './sample-hello.component.css',\n changeDetection: ChangeDetectionStrategy.OnPush\n\n})\nexport class SampleHelloComponent extends XtSimpleComponent<string>{\n\n}\n","<p>Hello {{getValue()}}</p>\n","import { ChangeDetectionStrategy, Component } from '@angular/core';\nimport { ReactiveFormsModule } from '@angular/forms';\nimport { InputNumberModule } from 'primeng/inputnumber';\nimport { XtSimpleComponent } from 'xt-components';\nimport { CommonModule } from '@angular/common';\nimport { InputTextModule } from 'primeng/inputtext';\n\n@Component({\n selector: 'xt-sample-currency',\n standalone: true,\n imports: [CommonModule, InputNumberModule, ReactiveFormsModule, InputTextModule],\n templateUrl: './sample-currency.component.html',\n styleUrl: './sample-currency.component.css',\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class SampleCurrencyComponent extends XtSimpleComponent {\n}\n","@if (isInForm() ) {\n <ng-container [formGroup]=\"formGroup()\">\n <input type=\"text\" pInputText [name]=\"componentNameInForm ()\" [formControlName]=\"formControlName()\" />\n </ng-container>\n} @else {\n {{ context().displayValue() }}\n}\n","import { CommonModule } from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n computed,\n inject,\n Injector,\n OnInit,\n runInInjectionContext,\n signal\n} from '@angular/core';\nimport { ReactiveFormsModule } from '@angular/forms';\nimport { SampleMoney } from './sample-money.model';\nimport { XtCompositeComponent, XtRenderSubComponent } from 'xt-components';\nimport { InputNumberModule } from 'primeng/inputnumber';\nimport { takeUntilDestroyed } from '@angular/core/rxjs-interop';\n\n@Component({\n selector: 'xt-sample-money',\n standalone: true,\n imports: [CommonModule, ReactiveFormsModule, XtRenderSubComponent, InputNumberModule],\n templateUrl: './sample-money.component.html',\n styleUrl: './sample-money.component.css',\n changeDetection: ChangeDetectionStrategy.OnPush\n\n})\nexport class SampleMoneyComponent extends XtCompositeComponent<SampleMoney> implements OnInit {\n injector = inject(Injector);\n\n // Force a recalculation of currency\n recalculate = signal<boolean>(true);\n\n currency= computed<string|undefined>( () => {\n // console.debug(\"Calculating currency in XtMoneyComponent\");\n this.recalculate();\n const value = this.context().value();\n if (value?.currency==null) return undefined;\n\n return value.currency;\n });\n\n isValidCurrency= computed<boolean> ( () => {\n const cur=this.currency();\n if (cur==null) return false;\n if (Intl.supportedValuesOf('currency').indexOf(cur) > -1) {\n return true;\n }else\n return false;\n });\n\n amount = computed<number|undefined>(()=> {\n return this.context().displayValue()?.amount;\n })\n\n override ngOnInit(): void {\n super.ngOnInit();\n// console.debug(\"XtMoneyComponent ngOnInit\");\n const amountCtrl = this.manageFormControl('amount');\n\n // Make sure the display is updated whenever the value change in the formgroup\n runInInjectionContext(this.injector, () => {\n if (amountCtrl?.parent!=null) {\n amountCtrl.parent.valueChanges.pipe(takeUntilDestroyed()).subscribe({\n next: value => {\n this.recalculate.set(!this.recalculate());\n }\n });\n }\n });\n }\n}\n","@if (isInForm() ) {\n @let cur = currency();\n <ng-container [formGroup]=\"formGroup()\">\n <xt-render-sub [context]=\"subContext('currency', 'sampleCurrency')\" />\n @if (isValidCurrency()) {\n <p-inputNumber mode=\"currency\" [currency]=\"cur\" formControlName=\"amount\" />\n } @else {\n <p-inputNumber mode=\"decimal\" formControlName=\"amount\" />\n }\n </ng-container>\n} @else {\n @let displayAmount = amount();\n @if (displayAmount) {\n {{ displayAmount | currency : currency() }}\n }\n}\n","import { XtResolverService } from 'xt-components';\nimport { SampleCurrencyComponent } from './currency/sample-currency.component';\nimport { SampleHelloComponent } from './hello/sample-hello.component';\nimport { SampleMoneyComponent } from './money/sample-money.component';\n\nexport function registerSamplePlugin (resolverService:XtResolverService):string {\n const pluginName = \"Plugin Sample\";\n console.info ('Registering '+pluginName);\n resolverService.registerPlugin ({\n name:pluginName,\n uriLogo:'pluginicon.png',\n components: [\n {\n componentName:'SampleHello',\n componentClass:SampleHelloComponent,\n typesHandled: ['sampleHello']\n },\n {\n componentName:'SampleCurrency',\n componentClass:SampleCurrencyComponent,\n typesHandled: ['sampleCurrency']\n },\n {\n componentName:'SampleMoney',\n componentClass:SampleMoneyComponent,\n typesHandled: ['sampleMoney']\n },\n ],\n types:\n {\n sampleHello:'string',\n sampleCurrency:'string',\n sampleMoney:{\n amount: 'number',\n currency: 'sampleCurrency'\n }\n }\n });\n return pluginName;\n}\n\nexport function registerPlugin (resolverService:XtResolverService):string {\n return registerSamplePlugin(resolverService);\n}\n","/*\n * Public API Surface of sample-plugin\n */\n\nexport * from './lib/hello/sample-hello.component';\nexport * from './lib/currency/sample-currency.component';\nexport * from './lib/money/sample-money.component';\nexport * from './lib/money/sample-money.model';\nexport * from './lib/register';\n\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":["i2"],"mappings":";;;;;;;;;;;;;AAYM,MAAO,oBAAqB,SAAQ,iBAAyB,CAAA;8GAAtD,oBAAoB,EAAA,IAAA,EAAA,IAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;AAApB,IAAA,SAAA,IAAA,CAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,oBAAoB,kGCZjC,+BACA,EAAA,MAAA,EAAA,CAAA,EAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA,CAAA;;2FDWa,oBAAoB,EAAA,UAAA,EAAA,CAAA;kBAThC,SAAS;AACE,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,iBAAiB,cACf,IAAI,EAAA,OAAA,EACP,EAAE,EAGM,eAAA,EAAA,uBAAuB,CAAC,MAAM,EAAA,QAAA,EAAA,+BAAA,EAAA;;;AEM3C,MAAO,uBAAwB,SAAQ,iBAAiB,CAAA;8GAAjD,uBAAuB,EAAA,IAAA,EAAA,IAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA,CAAA;kGAAvB,uBAAuB,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,oBAAA,EAAA,eAAA,EAAA,IAAA,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,EC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,eAAe,CAAC;AAC9C;;AC3CA;;AAEG;;ACFH;;AAEG;;;;"}
package/index.d.ts CHANGED
@@ -1,5 +1,35 @@
1
- /**
2
- * Generated bundle index. Do not edit.
3
- */
4
- /// <amd-module name="xt-plugin-sample" />
5
- export * from './public-api';
1
+ import { XtSimpleComponent, XtCompositeComponent, XtResolverService } from 'xt-components';
2
+ import * as i0 from '@angular/core';
3
+ import { OnInit, Injector } from '@angular/core';
4
+
5
+ declare class SampleHelloComponent extends XtSimpleComponent<string> {
6
+ static ɵfac: i0.ɵɵFactoryDeclaration<SampleHelloComponent, never>;
7
+ static ɵcmp: i0.ɵɵComponentDeclaration<SampleHelloComponent, "xt-sample-hello", never, {}, {}, never, never, true, never>;
8
+ }
9
+
10
+ declare class SampleCurrencyComponent extends XtSimpleComponent {
11
+ static ɵfac: i0.ɵɵFactoryDeclaration<SampleCurrencyComponent, never>;
12
+ static ɵcmp: i0.ɵɵComponentDeclaration<SampleCurrencyComponent, "xt-sample-currency", never, {}, {}, never, never, true, never>;
13
+ }
14
+
15
+ type SampleMoney = {
16
+ amount: number;
17
+ currency: string;
18
+ };
19
+
20
+ declare class SampleMoneyComponent extends XtCompositeComponent<SampleMoney> implements OnInit {
21
+ injector: Injector;
22
+ recalculate: i0.WritableSignal<boolean>;
23
+ currency: i0.Signal<string | undefined>;
24
+ isValidCurrency: i0.Signal<boolean>;
25
+ amount: i0.Signal<number | undefined>;
26
+ ngOnInit(): void;
27
+ static ɵfac: i0.ɵɵFactoryDeclaration<SampleMoneyComponent, never>;
28
+ static ɵcmp: i0.ɵɵComponentDeclaration<SampleMoneyComponent, "xt-sample-money", never, {}, {}, never, never, true, never>;
29
+ }
30
+
31
+ declare function registerSamplePlugin(resolverService: XtResolverService): string;
32
+ declare function registerPlugin(resolverService: XtResolverService): string;
33
+
34
+ export { SampleCurrencyComponent, SampleHelloComponent, SampleMoneyComponent, registerPlugin, registerSamplePlugin };
35
+ export type { SampleMoney };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "xt-plugin-sample",
3
- "version": "0.4.8",
3
+ "version": "0.5.0",
4
4
  "peerDependencies": {
5
5
  "@angular/animations": "^19.0.5",
6
6
  "@angular/common": "^19.0.5",
@@ -1,6 +0,0 @@
1
- import { XtSimpleComponent } from 'xt-components';
2
- import * as i0 from "@angular/core";
3
- export declare class SampleCurrencyComponent extends XtSimpleComponent {
4
- static ɵfac: i0.ɵɵFactoryDeclaration<SampleCurrencyComponent, never>;
5
- static ɵcmp: i0.ɵɵComponentDeclaration<SampleCurrencyComponent, "xt-sample-currency", never, {}, {}, never, never, true, never>;
6
- }
@@ -1,6 +0,0 @@
1
- import { XtSimpleComponent } from 'xt-components';
2
- import * as i0 from "@angular/core";
3
- export declare class SampleHelloComponent extends XtSimpleComponent<string> {
4
- static ɵfac: i0.ɵɵFactoryDeclaration<SampleHelloComponent, never>;
5
- static ɵcmp: i0.ɵɵComponentDeclaration<SampleHelloComponent, "xt-sample-hello", never, {}, {}, never, never, true, never>;
6
- }
@@ -1,14 +0,0 @@
1
- import { Injector, OnInit } from '@angular/core';
2
- import { SampleMoney } from './sample-money.model';
3
- import { XtCompositeComponent } from 'xt-components';
4
- import * as i0 from "@angular/core";
5
- export declare class SampleMoneyComponent extends XtCompositeComponent<SampleMoney> implements OnInit {
6
- injector: Injector;
7
- recalculate: import("@angular/core").WritableSignal<boolean>;
8
- currency: import("@angular/core").Signal<string | undefined>;
9
- isValidCurrency: import("@angular/core").Signal<boolean>;
10
- amount: import("@angular/core").Signal<number | undefined>;
11
- ngOnInit(): void;
12
- static ɵfac: i0.ɵɵFactoryDeclaration<SampleMoneyComponent, never>;
13
- static ɵcmp: i0.ɵɵComponentDeclaration<SampleMoneyComponent, "xt-sample-money", never, {}, {}, never, never, true, never>;
14
- }
@@ -1,4 +0,0 @@
1
- export type SampleMoney = {
2
- amount: number;
3
- currency: string;
4
- };
package/lib/register.d.ts DELETED
@@ -1,3 +0,0 @@
1
- import { XtResolverService } from 'xt-components';
2
- export declare function registerSamplePlugin(resolverService: XtResolverService): string;
3
- export declare function registerPlugin(resolverService: XtResolverService): string;
package/public-api.d.ts DELETED
@@ -1,5 +0,0 @@
1
- export * from './lib/hello/sample-hello.component';
2
- export * from './lib/currency/sample-currency.component';
3
- export * from './lib/money/sample-money.component';
4
- export * from './lib/money/sample-money.model';
5
- export * from './lib/register';