@rxdi/credit-card-form 0.7.190 → 0.7.191-nightly.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.
@@ -1 +1 @@
1
- export declare const CardCSS: import("@rxdi/lit-html").CSSResult;
1
+ export declare const CardCSS: any;
@@ -30,6 +30,7 @@ let CreditCardComponent = class CreditCardComponent extends lit_html_1.LitElemen
30
30
  this.cvc = '985';
31
31
  }
32
32
  };
33
+ exports.CreditCardComponent = CreditCardComponent;
33
34
  __decorate([
34
35
  (0, lit_html_1.property)({ type: String }),
35
36
  __metadata("design:type", Object)
@@ -50,7 +51,7 @@ __decorate([
50
51
  (0, lit_html_1.property)({ type: Boolean }),
51
52
  __metadata("design:type", Boolean)
52
53
  ], CreditCardComponent.prototype, "flipped", void 0);
53
- CreditCardComponent = __decorate([
54
+ exports.CreditCardComponent = CreditCardComponent = __decorate([
54
55
  (0, lit_html_1.Component)({
55
56
  selector: 'credit-card',
56
57
  styles: [credit_card_component_css_1.CardCSS],
@@ -243,4 +244,3 @@ CreditCardComponent = __decorate([
243
244
  },
244
245
  })
245
246
  ], CreditCardComponent);
246
- exports.CreditCardComponent = CreditCardComponent;
@@ -1 +1 @@
1
- export declare const AmericanExpress: import("lit-html").TemplateResult<2>;
1
+ export declare const AmericanExpress: any;
@@ -1 +1 @@
1
- export declare const Diners: import("lit-html").TemplateResult<2>;
1
+ export declare const Diners: any;
@@ -1 +1 @@
1
- export declare const Discover: import("lit-html").TemplateResult<2>;
1
+ export declare const Discover: any;
@@ -7,14 +7,14 @@ export * from './mastercard';
7
7
  export * from './union-pay';
8
8
  export * from './visa';
9
9
  export declare const CardTypes: {
10
- visa: import("lit-html").TemplateResult<2>;
11
- mastercard: import("lit-html").TemplateResult<2>;
12
- 'american-express': import("lit-html").TemplateResult<2>;
13
- 'diners-club': import("lit-html").TemplateResult<2>;
14
- discover: import("lit-html").TemplateResult<2>;
15
- jcb: import("lit-html").TemplateResult<2>;
16
- unionpay: import("lit-html").TemplateResult<2>;
17
- maestro: import("lit-html").TemplateResult<2>;
10
+ visa: any;
11
+ mastercard: any;
12
+ 'american-express': any;
13
+ 'diners-club': any;
14
+ discover: any;
15
+ jcb: any;
16
+ unionpay: any;
17
+ maestro: any;
18
18
  elo: any;
19
19
  mir: any;
20
20
  hiper: any;
@@ -1,7 +1,11 @@
1
1
  "use strict";
2
2
  var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
3
  if (k2 === undefined) k2 = k;
4
- Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
5
9
  }) : (function(o, m, k, k2) {
6
10
  if (k2 === undefined) k2 = k;
7
11
  o[k2] = m[k];
@@ -1 +1 @@
1
- export declare const JSB: import("lit-html").TemplateResult<2>;
1
+ export declare const JSB: any;
@@ -1 +1 @@
1
- export declare const Maesto: import("lit-html").TemplateResult<2>;
1
+ export declare const Maesto: any;
@@ -1 +1 @@
1
- export declare const Mastercard: import("lit-html").TemplateResult<2>;
1
+ export declare const Mastercard: any;
@@ -1 +1 @@
1
- export declare const UnionPay: import("lit-html").TemplateResult<2>;
1
+ export declare const UnionPay: any;
@@ -1 +1 @@
1
- export declare const Visa: import("lit-html").TemplateResult<2>;
1
+ export declare const Visa: any;
@@ -1,7 +1,11 @@
1
1
  "use strict";
2
2
  var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
3
  if (k2 === undefined) k2 = k;
4
- Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
5
9
  }) : (function(o, m, k, k2) {
6
10
  if (k2 === undefined) k2 = k;
7
11
  o[k2] = m[k];
@@ -1,2 +1,2 @@
1
1
  import { AbstractInput } from '@rxdi/forms';
2
- export declare function InputErrorTemplate(input: AbstractInput): "" | import("lit-html").TemplateResult<1>;
2
+ export declare function InputErrorTemplate(input: AbstractInput): any;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.InputErrorTemplate = void 0;
3
+ exports.InputErrorTemplate = InputErrorTemplate;
4
4
  const lit_html_1 = require("@rxdi/lit-html");
5
5
  // import { translate } from '../i18n/translate';
6
6
  function InputErrorTemplate(input) {
@@ -24,4 +24,3 @@ function InputErrorTemplate(input) {
24
24
  input && input.classList.remove('is-invalid');
25
25
  return '';
26
26
  }
27
- exports.InputErrorTemplate = InputErrorTemplate;
@@ -1,12 +1,8 @@
1
- import { FormGroup } from '@rxdi/forms';
2
1
  import { LitElement } from '@rxdi/lit-html';
3
- import { CardModel } from './model';
4
2
  /**
5
3
  * @customElement credit-card-form
6
4
  */
7
5
  export declare class CreditCardFormComponent extends LitElement {
8
6
  private flipped;
9
- form: FormGroup<CardModel, {
10
- [key: string]: never;
11
- }>;
7
+ form: any;
12
8
  }
@@ -8,6 +8,15 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
8
8
  var __metadata = (this && this.__metadata) || function (k, v) {
9
9
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
10
10
  };
11
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
12
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
13
+ return new (P || (P = Promise))(function (resolve, reject) {
14
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
15
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
16
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
17
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
18
+ });
19
+ };
11
20
  Object.defineProperty(exports, "__esModule", { value: true });
12
21
  exports.CreditCardFormComponent = void 0;
13
22
  const error_template_1 = require("./error-template");
@@ -31,6 +40,7 @@ let CreditCardFormComponent = class CreditCardFormComponent extends lit_html_1.L
31
40
  });
32
41
  }
33
42
  };
43
+ exports.CreditCardFormComponent = CreditCardFormComponent;
34
44
  __decorate([
35
45
  (0, lit_html_1.property)({ type: Boolean }),
36
46
  __metadata("design:type", Boolean)
@@ -42,7 +52,7 @@ __decorate([
42
52
  }),
43
53
  __metadata("design:type", Object)
44
54
  ], CreditCardFormComponent.prototype, "form", void 0);
45
- CreditCardFormComponent = __decorate([
55
+ exports.CreditCardFormComponent = CreditCardFormComponent = __decorate([
46
56
  (0, lit_html_1.Component)({
47
57
  selector: 'credit-card-form',
48
58
  style: (0, lit_html_1.css) `
@@ -71,11 +81,12 @@ CreditCardFormComponent = __decorate([
71
81
  class="form"
72
82
  novalidate
73
83
  name="credit-card-details"
74
- @submit=${() => {
75
- if (!this.form.updateValueAndValidity().length) {
84
+ @submit=${() => __awaiter(this, void 0, void 0, function* () {
85
+ const validity = yield this.form.updateValueAndValidity();
86
+ if (!validity.length) {
76
87
  this.dispatchEvent(new CustomEvent('submit', { detail: (0, helpers_1.convertModel)(this.form.value) }));
77
88
  }
78
- }}
89
+ })}
79
90
  >
80
91
  <p>Credit Card Number</p>
81
92
  <input
@@ -128,4 +139,3 @@ CreditCardFormComponent = __decorate([
128
139
  },
129
140
  })
130
141
  ], CreditCardFormComponent);
131
- exports.CreditCardFormComponent = CreditCardFormComponent;
@@ -1,7 +1,11 @@
1
1
  "use strict";
2
2
  var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
3
  if (k2 === undefined) k2 = k;
4
- Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
5
9
  }) : (function(o, m, k, k2) {
6
10
  if (k2 === undefined) k2 = k;
7
11
  o[k2] = m[k];
package/dist/index.js CHANGED
@@ -1,7 +1,11 @@
1
1
  "use strict";
2
2
  var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
3
  if (k2 === undefined) k2 = k;
4
- Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
5
9
  }) : (function(o, m, k, k2) {
6
10
  if (k2 === undefined) k2 = k;
7
11
  o[k2] = m[k];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rxdi/credit-card-form",
3
- "version": "0.7.190",
3
+ "version": "0.7.191-nightly.0",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "https://github.com/rxdi/rxdi-monorepo"
@@ -31,21 +31,21 @@
31
31
  "homepage": "https://github.com/rxdi/rxdi-monorepo#readme",
32
32
  "dependencies": {
33
33
  "@rxdi/ui-kit": "^0.7",
34
- "@rxdi/forms": "^0.7.189",
35
- "@rxdi/lit-html": "^0.7.189",
34
+ "@rxdi/forms": "^0.7.190",
35
+ "@rxdi/lit-html": "^0.7.190",
36
36
  "credit-card-type": "^9.1.0"
37
37
  },
38
38
  "devDependencies": {
39
39
  "@types/graphql": "^14.5.0",
40
40
  "@types/hapi": "^18.0.4",
41
41
  "@types/jest": "^24.0.22",
42
- "@types/node": "^12.0.10",
42
+ "@types/node": "^25.0.3",
43
43
  "jest": "^24.8.0",
44
44
  "jest-cli": "^24.8.1",
45
45
  "ts-jest": "^24.0.2",
46
46
  "tslint": "^5.20.1",
47
47
  "tslint-language-service": "^0.9.9",
48
- "typescript": "^4.3.5"
48
+ "typescript": "^5.9.3"
49
49
  },
50
50
  "jest": {
51
51
  "testEnvironment": "node",