@taiga-ui/addon-commerce 3.0.1 → 3.1.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.
- package/bundles/taiga-ui-addon-commerce-components-input-card-grouped.umd.js +3 -3
- package/bundles/taiga-ui-addon-commerce-components-input-card-grouped.umd.js.map +1 -1
- package/bundles/taiga-ui-addon-commerce-components-input-card.umd.js +12 -13
- package/bundles/taiga-ui-addon-commerce-components-input-card.umd.js.map +1 -1
- package/bundles/taiga-ui-addon-commerce-components-input-cvc.umd.js +12 -13
- package/bundles/taiga-ui-addon-commerce-components-input-cvc.umd.js.map +1 -1
- package/bundles/taiga-ui-addon-commerce-components-input-expire.umd.js +12 -13
- package/bundles/taiga-ui-addon-commerce-components-input-expire.umd.js.map +1 -1
- package/components/input-card/input-card.component.d.ts +2 -2
- package/components/input-card/input-card.module.d.ts +2 -3
- package/components/input-card-grouped/input-card-grouped.component.d.ts +4 -5
- package/components/input-card-grouped/input-card-grouped.module.d.ts +1 -1
- package/components/input-cvc/input-cvc.component.d.ts +2 -3
- package/components/input-cvc/input-cvc.module.d.ts +2 -3
- package/components/input-expire/input-expire.component.d.ts +2 -2
- package/components/input-expire/input-expire.module.d.ts +2 -3
- package/esm2015/components/input-card/input-card.component.js +4 -5
- package/esm2015/components/input-card/input-card.module.js +2 -3
- package/esm2015/components/input-card-grouped/input-card-grouped.component.js +3 -3
- package/esm2015/components/input-card-grouped/input-card-grouped.module.js +2 -2
- package/esm2015/components/input-cvc/input-cvc.component.js +4 -5
- package/esm2015/components/input-cvc/input-cvc.module.js +2 -3
- package/esm2015/components/input-expire/input-expire.component.js +4 -5
- package/esm2015/components/input-expire/input-expire.module.js +2 -3
- package/fesm2015/taiga-ui-addon-commerce-components-input-card-grouped.js +3 -3
- package/fesm2015/taiga-ui-addon-commerce-components-input-card-grouped.js.map +1 -1
- package/fesm2015/taiga-ui-addon-commerce-components-input-card.js +4 -6
- package/fesm2015/taiga-ui-addon-commerce-components-input-card.js.map +1 -1
- package/fesm2015/taiga-ui-addon-commerce-components-input-cvc.js +4 -6
- package/fesm2015/taiga-ui-addon-commerce-components-input-cvc.js.map +1 -1
- package/fesm2015/taiga-ui-addon-commerce-components-input-expire.js +4 -6
- package/fesm2015/taiga-ui-addon-commerce-components-input-expire.js.map +1 -1
- package/package.json +4 -5
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"taiga-ui-addon-commerce-components-input-expire.js","sources":["../../../projects/addon-commerce/components/input-expire/input-expire.component.ts","../../../projects/addon-commerce/components/input-expire/input-expire.template.html","../../../projects/addon-commerce/components/input-expire/input-expire.module.ts","../../../projects/addon-commerce/components/input-expire/taiga-ui-addon-commerce-components-input-expire.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n Inject,\n Input,\n Optional,\n Self,\n ViewChild,\n} from '@angular/core';\nimport {NgControl} from '@angular/forms';\nimport {tuiCreateAutoCorrectedExpirePipe} from '@taiga-ui/addon-commerce/utils';\nimport {\n AbstractTuiControl,\n tuiAsControl,\n tuiAsFocusableItemAccessor,\n TuiAutofillFieldName,\n tuiDefaultProp,\n TuiFocusableElementAccessor,\n} from '@taiga-ui/cdk';\nimport {\n TUI_DIGIT_REGEXP,\n TuiPrimitiveTextfieldComponent,\n TuiTextMaskOptions,\n} from '@taiga-ui/core';\
|
|
1
|
+
{"version":3,"file":"taiga-ui-addon-commerce-components-input-expire.js","sources":["../../../projects/addon-commerce/components/input-expire/input-expire.component.ts","../../../projects/addon-commerce/components/input-expire/input-expire.template.html","../../../projects/addon-commerce/components/input-expire/input-expire.module.ts","../../../projects/addon-commerce/components/input-expire/taiga-ui-addon-commerce-components-input-expire.ts"],"sourcesContent":["import {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n Inject,\n Input,\n Optional,\n Self,\n ViewChild,\n} from '@angular/core';\nimport {NgControl} from '@angular/forms';\nimport {tuiCreateAutoCorrectedExpirePipe} from '@taiga-ui/addon-commerce/utils';\nimport {\n AbstractTuiControl,\n tuiAsControl,\n tuiAsFocusableItemAccessor,\n TuiAutofillFieldName,\n tuiDefaultProp,\n TuiFocusableElementAccessor,\n} from '@taiga-ui/cdk';\nimport {\n TUI_DIGIT_REGEXP,\n TuiPrimitiveTextfieldComponent,\n TuiTextMaskOptions,\n} from '@taiga-ui/core';\n\n@Component({\n selector: `tui-input-expire`,\n templateUrl: `./input-expire.template.html`,\n styleUrls: [`./input-expire.style.less`],\n changeDetection: ChangeDetectionStrategy.OnPush,\n providers: [\n tuiAsFocusableItemAccessor(TuiInputExpireComponent),\n tuiAsControl(TuiInputExpireComponent),\n ],\n})\nexport class TuiInputExpireComponent\n extends AbstractTuiControl<string>\n implements TuiFocusableElementAccessor\n{\n @ViewChild(TuiPrimitiveTextfieldComponent)\n private readonly input?: TuiPrimitiveTextfieldComponent;\n\n @Input()\n @tuiDefaultProp()\n autocompleteEnabled = false;\n\n readonly textMaskOptions: TuiTextMaskOptions = {\n mask: [\n TUI_DIGIT_REGEXP,\n TUI_DIGIT_REGEXP,\n `/`,\n TUI_DIGIT_REGEXP,\n TUI_DIGIT_REGEXP,\n ],\n pipe: tuiCreateAutoCorrectedExpirePipe(),\n guide: false,\n };\n\n constructor(\n @Optional()\n @Self()\n @Inject(NgControl)\n control: NgControl | null,\n @Inject(ChangeDetectorRef) changeDetectorRef: ChangeDetectorRef,\n ) {\n super(control, changeDetectorRef);\n }\n\n get nativeFocusableElement(): HTMLInputElement | null {\n return this.input ? this.input.nativeFocusableElement : null;\n }\n\n get focused(): boolean {\n return !!this.input && this.input.focused;\n }\n\n get autocomplete(): TuiAutofillFieldName {\n return this.autocompleteEnabled ? `cc-exp` : `off`;\n }\n\n onValueChange(value: string): void {\n // @bad TODO: Workaround until mask pipe can replace chars and keep caret position\n // @bad TODO: Think about a solution without mask at all\n if (!this.input?.nativeFocusableElement) {\n return;\n }\n\n if (parseInt(value.slice(0, 2), 10) > 12) {\n value = `12${value.slice(2)}`;\n }\n\n if (value.slice(0, 2) === `00`) {\n value = `01${value.slice(2)}`;\n }\n\n this.input.nativeFocusableElement.value = value;\n\n if (this.value !== value) {\n this.updateValue(value);\n }\n }\n\n onFocused(focused: boolean): void {\n this.updateFocused(focused);\n }\n\n protected getFallbackValue(): string {\n return ``;\n }\n}\n","<tui-primitive-textfield\n tuiValueAccessor\n class=\"t-input\"\n [nativeId]=\"nativeId\"\n [disabled]=\"disabled\"\n [textMask]=\"textMaskOptions\"\n [readOnly]=\"readOnly\"\n [invalid]=\"computedInvalid\"\n [pseudoHover]=\"pseudoHover\"\n [pseudoActive]=\"pseudoActive\"\n [pseudoFocus]=\"pseudoFocus\"\n [value]=\"value\"\n (valueChange)=\"onValueChange($event)\"\n (focusedChange)=\"onFocused($event)\"\n>\n <input\n tuiTextfield\n inputmode=\"numeric\"\n placeholder=\"00/00\"\n [attr.autocomplete]=\"autocomplete\"\n />\n <ng-content></ng-content>\n</tui-primitive-textfield>\n","import {NgModule} from '@angular/core';\nimport {TuiPrimitiveTextfieldModule, TuiTextfieldControllerModule} from '@taiga-ui/core';\nimport {TextMaskModule, TuiValueAccessorModule} from '@taiga-ui/kit';\n\nimport {TuiInputExpireComponent} from './input-expire.component';\n\n@NgModule({\n imports: [\n TextMaskModule,\n TuiPrimitiveTextfieldModule,\n TuiTextfieldControllerModule,\n TuiValueAccessorModule,\n ],\n declarations: [TuiInputExpireComponent],\n exports: [TuiInputExpireComponent],\n})\nexport class TuiInputExpireModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;;AAoCM,MAAO,uBACT,SAAQ,kBAA0B,CAAA;IAsBlC,WAII,CAAA,OAAyB,EACE,iBAAoC,EAAA;AAE/D,QAAA,KAAK,CAAC,OAAO,EAAE,iBAAiB,CAAC,CAAC;QArBtC,IAAmB,CAAA,mBAAA,GAAG,KAAK,CAAC;AAEnB,QAAA,IAAA,CAAA,eAAe,GAAuB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AA;;kHAApB,oBAAoB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;mHAApB,oBAAoB,EAAA,YAAA,EAAA,CAHd,uBAAuB,CAAA,EAAA,OAAA,EAAA,CALlC,cAAc;QACd,2BAA2B;QAC3B,4BAA4B;AAC5B,QAAA,sBAAsB,aAGhB,uBAAuB,CAAA,EAAA,CAAA,CAAA;AAExB,oBAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,oBAAoB,EATpB,OAAA,EAAA,CAAA;YACL,cAAc;YACd,2BAA2B;YAC3B,4BAA4B;YAC5B,sBAAsB;AACzB,SAAA,CAAA,EAAA,CAAA,CAAA;4FAIQ,oBAAoB,EAAA,UAAA,EAAA,CAAA;kBAVhC,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACN,oBAAA,OAAO,EAAE;wBACL,cAAc;wBACd,2BAA2B;wBAC3B,4BAA4B;wBAC5B,sBAAsB;AACzB,qBAAA;oBACD,YAAY,EAAE,CAAC,uBAAuB,CAAC;oBACvC,OAAO,EAAE,CAAC,uBAAuB,CAAC;AACrC,iBAAA,CAAA;;;ACfD;;AAEG;;;;"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@taiga-ui/addon-commerce",
|
|
3
|
-
"version": "3.0
|
|
3
|
+
"version": "3.1.0",
|
|
4
4
|
"description": "Extension package for Taiga UI related to commerce, payment systems, currencies etc.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"angular",
|
|
@@ -21,11 +21,10 @@
|
|
|
21
21
|
"@angular/core": ">=9.0.0",
|
|
22
22
|
"@angular/forms": ">=9.0.0",
|
|
23
23
|
"@ng-web-apis/common": ">=2.0.0",
|
|
24
|
-
"@taiga-ui/cdk": ">=3.0
|
|
25
|
-
"@taiga-ui/core": ">=3.0
|
|
26
|
-
"@taiga-ui/i18n": ">=3.0
|
|
24
|
+
"@taiga-ui/cdk": ">=3.1.0",
|
|
25
|
+
"@taiga-ui/core": ">=3.1.0",
|
|
26
|
+
"@taiga-ui/i18n": ">=3.1.0",
|
|
27
27
|
"@tinkoff/ng-polymorpheus": ">=4.0.0",
|
|
28
|
-
"angular2-text-mask": ">=9.0.0",
|
|
29
28
|
"rxjs": ">=6.0.0"
|
|
30
29
|
},
|
|
31
30
|
"main": "bundles/taiga-ui-addon-commerce.umd.js",
|