@justifi/webcomponents 0.0.15 → 0.2.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.
- package/CHANGELOG.md +45 -0
- package/changelog-template.hbs +41 -0
- package/dist/cjs/{index-e1b45289.js → index-ca2cd154.js} +456 -97
- package/dist/cjs/justifi-bank-account-form.cjs.entry.js +59 -0
- package/dist/cjs/justifi-billing-form.cjs.entry.js +2150 -0
- package/dist/cjs/justifi-card-form.cjs.entry.js +59 -0
- package/dist/cjs/justifi-payment-form.cjs.entry.js +17 -0
- package/dist/cjs/{justifi-bank-account-form_3.cjs.entry.js → justifi-payment-method-form.cjs.entry.js} +86 -110
- package/dist/cjs/justifi-payments-list.cjs.entry.js +1 -1
- package/dist/cjs/loader.cjs.js +3 -4
- package/dist/cjs/select-input_2.cjs.entry.js +59 -0
- package/dist/cjs/webcomponents.cjs.js +3 -7
- package/dist/collection/collection-manifest.json +7 -3
- package/dist/collection/components/bank-account-form/bank-account-form.js +1 -1
- package/dist/collection/components/billing-form/billing-form-schema.js +14 -0
- package/dist/collection/components/billing-form/billing-form.css +11 -0
- package/dist/collection/components/billing-form/billing-form.js +92 -0
- package/dist/collection/components/billing-form/state-options.js +243 -0
- package/dist/collection/components/card-form/card-form.js +1 -1
- package/dist/collection/components/card-form/card-form.stories.js +132 -0
- package/dist/collection/components/payment-form/payment-form.js +31 -0
- package/dist/collection/components/payment-method-form/payment-method-form.js +6 -4
- package/dist/collection/components/select-input/select-input.css +7 -0
- package/dist/collection/components/select-input/select-input.js +144 -0
- package/dist/collection/components/text-input/text-input.css +7 -0
- package/dist/collection/components/text-input/text-input.js +126 -0
- package/dist/components/index.d.ts +4 -9
- package/dist/components/index.js +5 -1
- package/dist/components/justifi-billing-form.d.ts +11 -0
- package/dist/components/justifi-billing-form.js +2180 -0
- package/dist/components/justifi-payment-form.d.ts +11 -0
- package/dist/components/justifi-payment-form.js +32 -0
- package/dist/components/payment-method-form.js +85 -3
- package/dist/components/select-input.d.ts +11 -0
- package/dist/components/select-input.js +6 -0
- package/dist/components/select-input2.js +52 -0
- package/dist/components/text-input.d.ts +11 -0
- package/dist/components/text-input.js +6 -0
- package/dist/components/text-input2.js +48 -0
- package/dist/esm/{index-c1f569bd.js → index-05706eb5.js} +457 -97
- package/dist/esm/justifi-bank-account-form.entry.js +55 -0
- package/dist/esm/justifi-billing-form.entry.js +2146 -0
- package/dist/esm/justifi-card-form.entry.js +55 -0
- package/dist/esm/justifi-payment-form.entry.js +13 -0
- package/dist/esm/justifi-payment-method-form.entry.js +187 -0
- package/dist/esm/justifi-payments-list.entry.js +1 -1
- package/dist/esm/loader.js +3 -4
- package/dist/esm/polyfills/css-shim.js +1 -1
- package/dist/esm/select-input_2.entry.js +54 -0
- package/dist/esm/webcomponents.js +3 -4
- package/dist/types/api/Api.d.ts +1 -1
- package/dist/types/api/Payment.d.ts +1 -1
- package/dist/types/components/billing-form/billing-form-schema.d.ts +15 -0
- package/dist/types/components/billing-form/billing-form.d.ts +17 -0
- package/dist/types/components/billing-form/state-options.d.ts +5 -0
- package/dist/types/components/card-form/card-form.stories.d.ts +14 -0
- package/dist/types/components/payment-form/payment-form.d.ts +4 -0
- package/dist/types/components/payment-method-form/payment-method-form.d.ts +1 -1
- package/dist/types/components/payment-method-form/theme.d.ts +3 -1
- package/dist/types/components/select-input/select-input.d.ts +18 -0
- package/dist/types/components/text-input/text-input.d.ts +14 -0
- package/dist/types/components.d.ts +87 -3
- package/dist/types/stencil-public-runtime.d.ts +3 -59
- package/dist/webcomponents/p-3809130a.entry.js +1 -0
- package/dist/webcomponents/p-67be9585.entry.js +1 -0
- package/dist/webcomponents/p-787671b9.entry.js +1 -0
- package/dist/webcomponents/p-87654bf4.entry.js +1 -0
- package/dist/webcomponents/p-8ee06fd1.js +2 -0
- package/dist/webcomponents/p-94ef2d0e.entry.js +1 -0
- package/dist/webcomponents/p-c07191dc.entry.js +1 -0
- package/dist/webcomponents/p-e5b0f047.entry.js +1 -0
- package/dist/webcomponents/webcomponents.esm.js +1 -1
- package/loader/index.d.ts +0 -9
- package/package.json +23 -5
- package/LICENSE +0 -21
- package/dist/esm/justifi-bank-account-form_3.entry.js +0 -209
- package/dist/webcomponents/p-1de39730.js +0 -2
- package/dist/webcomponents/p-f0eb5ed0.entry.js +0 -1
- package/dist/webcomponents/p-f91b7b05.entry.js +0 -1
|
@@ -0,0 +1,126 @@
|
|
|
1
|
+
import { Host, h } from '@stencil/core';
|
|
2
|
+
export class TextInput {
|
|
3
|
+
constructor() {
|
|
4
|
+
this.name = undefined;
|
|
5
|
+
this.label = undefined;
|
|
6
|
+
this.defaultValue = undefined;
|
|
7
|
+
this.error = undefined;
|
|
8
|
+
this.internalValue = '';
|
|
9
|
+
}
|
|
10
|
+
onInput(event) {
|
|
11
|
+
const target = event.target;
|
|
12
|
+
const name = target.getAttribute('name');
|
|
13
|
+
this.fieldReceivedInput.emit({ name: name, value: target.value });
|
|
14
|
+
}
|
|
15
|
+
;
|
|
16
|
+
render() {
|
|
17
|
+
return (h(Host, null, h("label", null, this.label), h("input", { name: this.name, type: "text", onInput: (event) => this.onInput(event), value: this.internalValue || this.defaultValue }), this.error && h("div", { style: { color: 'red' } }, this.error)));
|
|
18
|
+
}
|
|
19
|
+
static get is() { return "text-input"; }
|
|
20
|
+
static get encapsulation() { return "shadow"; }
|
|
21
|
+
static get originalStyleUrls() {
|
|
22
|
+
return {
|
|
23
|
+
"$": ["text-input.css"]
|
|
24
|
+
};
|
|
25
|
+
}
|
|
26
|
+
static get styleUrls() {
|
|
27
|
+
return {
|
|
28
|
+
"$": ["text-input.css"]
|
|
29
|
+
};
|
|
30
|
+
}
|
|
31
|
+
static get properties() {
|
|
32
|
+
return {
|
|
33
|
+
"name": {
|
|
34
|
+
"type": "string",
|
|
35
|
+
"mutable": false,
|
|
36
|
+
"complexType": {
|
|
37
|
+
"original": "string",
|
|
38
|
+
"resolved": "string",
|
|
39
|
+
"references": {}
|
|
40
|
+
},
|
|
41
|
+
"required": false,
|
|
42
|
+
"optional": false,
|
|
43
|
+
"docs": {
|
|
44
|
+
"tags": [],
|
|
45
|
+
"text": ""
|
|
46
|
+
},
|
|
47
|
+
"attribute": "name",
|
|
48
|
+
"reflect": false
|
|
49
|
+
},
|
|
50
|
+
"label": {
|
|
51
|
+
"type": "string",
|
|
52
|
+
"mutable": false,
|
|
53
|
+
"complexType": {
|
|
54
|
+
"original": "string",
|
|
55
|
+
"resolved": "string",
|
|
56
|
+
"references": {}
|
|
57
|
+
},
|
|
58
|
+
"required": false,
|
|
59
|
+
"optional": false,
|
|
60
|
+
"docs": {
|
|
61
|
+
"tags": [],
|
|
62
|
+
"text": ""
|
|
63
|
+
},
|
|
64
|
+
"attribute": "label",
|
|
65
|
+
"reflect": false
|
|
66
|
+
},
|
|
67
|
+
"defaultValue": {
|
|
68
|
+
"type": "string",
|
|
69
|
+
"mutable": false,
|
|
70
|
+
"complexType": {
|
|
71
|
+
"original": "string",
|
|
72
|
+
"resolved": "string",
|
|
73
|
+
"references": {}
|
|
74
|
+
},
|
|
75
|
+
"required": false,
|
|
76
|
+
"optional": false,
|
|
77
|
+
"docs": {
|
|
78
|
+
"tags": [],
|
|
79
|
+
"text": ""
|
|
80
|
+
},
|
|
81
|
+
"attribute": "default-value",
|
|
82
|
+
"reflect": false
|
|
83
|
+
},
|
|
84
|
+
"error": {
|
|
85
|
+
"type": "string",
|
|
86
|
+
"mutable": false,
|
|
87
|
+
"complexType": {
|
|
88
|
+
"original": "string",
|
|
89
|
+
"resolved": "string",
|
|
90
|
+
"references": {}
|
|
91
|
+
},
|
|
92
|
+
"required": false,
|
|
93
|
+
"optional": false,
|
|
94
|
+
"docs": {
|
|
95
|
+
"tags": [],
|
|
96
|
+
"text": ""
|
|
97
|
+
},
|
|
98
|
+
"attribute": "error",
|
|
99
|
+
"reflect": false
|
|
100
|
+
}
|
|
101
|
+
};
|
|
102
|
+
}
|
|
103
|
+
static get states() {
|
|
104
|
+
return {
|
|
105
|
+
"internalValue": {}
|
|
106
|
+
};
|
|
107
|
+
}
|
|
108
|
+
static get events() {
|
|
109
|
+
return [{
|
|
110
|
+
"method": "fieldReceivedInput",
|
|
111
|
+
"name": "fieldReceivedInput",
|
|
112
|
+
"bubbles": true,
|
|
113
|
+
"cancelable": true,
|
|
114
|
+
"composed": true,
|
|
115
|
+
"docs": {
|
|
116
|
+
"tags": [],
|
|
117
|
+
"text": ""
|
|
118
|
+
},
|
|
119
|
+
"complexType": {
|
|
120
|
+
"original": "{ name: string, value: string }",
|
|
121
|
+
"resolved": "{ name: string; value: string; }",
|
|
122
|
+
"references": {}
|
|
123
|
+
}
|
|
124
|
+
}];
|
|
125
|
+
}
|
|
126
|
+
}
|
|
@@ -1,8 +1,12 @@
|
|
|
1
1
|
/* webcomponents custom elements */
|
|
2
2
|
export { BankAccountForm as JustifiBankAccountForm } from '../types/components/bank-account-form/bank-account-form';
|
|
3
|
+
export { BillingForm as JustifiBillingForm } from '../types/components/billing-form/billing-form';
|
|
3
4
|
export { CardForm as JustifiCardForm } from '../types/components/card-form/card-form';
|
|
5
|
+
export { PaymentForm as JustifiPaymentForm } from '../types/components/payment-form/payment-form';
|
|
4
6
|
export { PaymentMethodForm as JustifiPaymentMethodForm } from '../types/components/payment-method-form/payment-method-form';
|
|
5
7
|
export { PaymentsList as JustifiPaymentsList } from '../types/components/payments-list/payments-list';
|
|
8
|
+
export { SelectInput as SelectInput } from '../types/components/select-input/select-input';
|
|
9
|
+
export { TextInput as TextInput } from '../types/components/text-input/text-input';
|
|
6
10
|
|
|
7
11
|
/**
|
|
8
12
|
* Used to manually set the base path where assets can be found.
|
|
@@ -16,15 +20,6 @@ export { PaymentsList as JustifiPaymentsList } from '../types/components/payment
|
|
|
16
20
|
*/
|
|
17
21
|
export declare const setAssetPath: (path: string) => void;
|
|
18
22
|
|
|
19
|
-
/**
|
|
20
|
-
* Used to specify a nonce value that corresponds with an application's CSP.
|
|
21
|
-
* When set, the nonce will be added to all dynamically created script and style tags at runtime.
|
|
22
|
-
* Alternatively, the nonce value can be set on a meta tag in the DOM head
|
|
23
|
-
* (<meta name="csp-nonce" content="{ nonce value here }" />) which
|
|
24
|
-
* will result in the same behavior.
|
|
25
|
-
*/
|
|
26
|
-
export declare const setNonce: (nonce: string) => void
|
|
27
|
-
|
|
28
23
|
export interface SetPlatformOptions {
|
|
29
24
|
raf?: (c: FrameRequestCallback) => number;
|
|
30
25
|
ael?: (el: EventTarget, eventName: string, listener: EventListenerOrEventListenerObject, options: boolean | AddEventListenerOptions) => void;
|
package/dist/components/index.js
CHANGED
|
@@ -1,5 +1,9 @@
|
|
|
1
|
-
export { setAssetPath,
|
|
1
|
+
export { setAssetPath, setPlatformOptions } from '@stencil/core/internal/client';
|
|
2
2
|
export { JustifiBankAccountForm, defineCustomElement as defineCustomElementJustifiBankAccountForm } from './justifi-bank-account-form.js';
|
|
3
|
+
export { JustifiBillingForm, defineCustomElement as defineCustomElementJustifiBillingForm } from './justifi-billing-form.js';
|
|
3
4
|
export { JustifiCardForm, defineCustomElement as defineCustomElementJustifiCardForm } from './justifi-card-form.js';
|
|
5
|
+
export { JustifiPaymentForm, defineCustomElement as defineCustomElementJustifiPaymentForm } from './justifi-payment-form.js';
|
|
4
6
|
export { JustifiPaymentMethodForm, defineCustomElement as defineCustomElementJustifiPaymentMethodForm } from './justifi-payment-method-form.js';
|
|
5
7
|
export { JustifiPaymentsList, defineCustomElement as defineCustomElementJustifiPaymentsList } from './justifi-payments-list.js';
|
|
8
|
+
export { SelectInput, defineCustomElement as defineCustomElementSelectInput } from './select-input.js';
|
|
9
|
+
export { TextInput, defineCustomElement as defineCustomElementTextInput } from './text-input.js';
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { Components, JSX } from "../types/components";
|
|
2
|
+
|
|
3
|
+
interface JustifiBillingForm extends Components.JustifiBillingForm, HTMLElement {}
|
|
4
|
+
export const JustifiBillingForm: {
|
|
5
|
+
prototype: JustifiBillingForm;
|
|
6
|
+
new (): JustifiBillingForm;
|
|
7
|
+
};
|
|
8
|
+
/**
|
|
9
|
+
* Used to define this component and all nested components recursively.
|
|
10
|
+
*/
|
|
11
|
+
export const defineCustomElement: () => void;
|