@paynext/sdk 0.0.5 → 0.0.7
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/dist/assets/index.css +1 -1
- package/dist/index.d.ts +12 -12
- package/dist/index.es.js +1961 -1910
- package/dist/index.es.js.map +1 -1
- package/dist/index.umd.js +9 -9
- package/dist/index.umd.js.map +1 -1
- package/package.json +1 -1
package/dist/assets/index.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
._googlePay_1a960_1{border-radius:12px;height:40px;overflow:hidden;background-color:transparent}._googlePay_1a960_1 iframe{width:calc(100% + 12px)!important;height:44px!important;border:none;display:block;transform:translateY(-2px);margin:0 -6px}._hidden_1a960_17{display:none}._applePay_2b2iv_1{border-radius:12px;height:40px;overflow:hidden;background-color:transparent}._applePay_2b2iv_1 iframe{width:calc(100% + 12px)!important;height:44px!important;border:none;display:block;transform:translateY(-2px);margin:0 -6px}._hidden_2b2iv_17{display:none}.
|
|
1
|
+
._googlePay_1a960_1{border-radius:12px;height:40px;overflow:hidden;background-color:transparent}._googlePay_1a960_1 iframe{width:calc(100% + 12px)!important;height:44px!important;border:none;display:block;transform:translateY(-2px);margin:0 -6px}._hidden_1a960_17{display:none}._applePay_2b2iv_1{border-radius:12px;height:40px;overflow:hidden;background-color:transparent}._applePay_2b2iv_1 iframe{width:calc(100% + 12px)!important;height:44px!important;border:none;display:block;transform:translateY(-2px);margin:0 -6px}._hidden_2b2iv_17{display:none}._button_qsmkn_1{transition-property:transform,color,background,background-color,border-color,text-decoration-color,fill,stroke,opacity;transition-timing-function:ease;transition-duration:.25s;position:relative;z-index:0;box-sizing:border-box;display:inline-flex;height:2.5rem;width:100%;min-width:5rem;transform:translate3d(var(--tw-translate-x),var(--tw-translate-y),0) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));-webkit-user-select:none;-moz-user-select:none;user-select:none;-webkit-appearance:none;-moz-appearance:none;appearance:none;align-items:center;justify-content:center;gap:.5rem;overflow:hidden;white-space:nowrap;border-radius:.75rem;--tw-bg-opacity: 1;background-color:rgb(59 130 246 / var(--tw-bg-opacity, 1));padding-left:1rem;padding-right:1rem;font-size:.875rem;line-height:1.25rem;font-weight:400;--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1));-webkit-font-smoothing:auto;-moz-osx-font-smoothing:auto;outline:2px solid transparent;outline-offset:2px}@media (prefers-reduced-motion: reduce){._button_qsmkn_1{transition-property:none}}._button_qsmkn_1>svg{max-width:2rem}._primary_qsmkn_11{--tw-bg-opacity: 1;background-color:rgb(59 130 246 / var(--tw-bg-opacity, 1))}._success_qsmkn_15{--tw-bg-opacity: 1;background-color:rgb(22 163 74 / var(--tw-bg-opacity, 1))}._loading_qsmkn_19,._button_qsmkn_1:hover{opacity:.7}._press_qsmkn_24{transform:scale(.95)}._card_ji6om_1{display:grid;gap:.75rem;padding-top:1rem}._title_ji6om_5{font-size:.875rem;line-height:1.25rem;font-weight:600}._error_ji6om_9{--tw-text-opacity: 1;color:rgb(220 38 38 / var(--tw-text-opacity, 1))}._label_ji6om_13{display:flex;width:100%;justify-content:space-between}._label_ji6om_13 span{text-wrap:nowrap;text-overflow:ellipsis;overflow:hidden}._cardDataContainer_ji6om_23{display:grid;grid-column-gap:5px;grid-template-columns:repeat(2,minmax(0,1fr));grid-template-rows:repeat(3,minmax(0,auto))}._iconContainer_ji6om_30{margin:0 1px}._payButton_ji6om_34{display:flex;align-items:center;justify-content:center}._spinner_ji6om_38{width:24px;height:24px}._wrapper_1n2ol_1{position:relative}._inputContainer_1n2ol_5{background-color:transparent;display:flex;height:40px;width:100%;cursor:text;align-items:center;justify-content:space-between;border-radius:.75rem;border-width:1px;--tw-border-opacity: 1;border-color:rgb(209 213 219 / var(--tw-border-opacity, 1));padding-left:.75rem;padding-right:.75rem}._inputContainer_1n2ol_5::-moz-placeholder{--tw-placeholder-opacity: 1;color:rgb(156 163 175 / var(--tw-placeholder-opacity, 1))}._inputContainer_1n2ol_5::placeholder{--tw-placeholder-opacity: 1;color:rgb(156 163 175 / var(--tw-placeholder-opacity, 1))}._inputContainer_1n2ol_5{--tw-shadow: 0 1px 2px 0 rgb(0 0 0 / .05);--tw-shadow-colored: 0 1px 2px 0 var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}@media (min-width: 640px){._inputContainer_1n2ol_5{font-size:.875rem;line-height:1.25rem}}._inputFocus_1n2ol_10,._inputContainer_1n2ol_5:hover{--tw-border-opacity: 1;border-color:rgb(107 114 128 / var(--tw-border-opacity, 1))}._input_1n2ol_5{background-color:transparent;display:block;height:100%;width:100%;border-style:none;font-size:1rem;font-weight:400;outline:2px solid transparent;outline-offset:2px}._endContent_1n2ol_20{display:flex}._errorInput_1n2ol_24{--tw-border-opacity: 1;border-color:rgb(220 38 38 / var(--tw-border-opacity, 1));--tw-text-opacity: 1;color:rgb(220 38 38 / var(--tw-text-opacity, 1))}._errorInput_1n2ol_24:hover{--tw-border-opacity: 1;border-color:rgb(220 38 38 / var(--tw-border-opacity, 1));--tw-ring-opacity: 1;--tw-ring-color: rgb(220 38 38 / var(--tw-ring-opacity, 1))}._errorInput_1n2ol_24:focus{--tw-border-opacity: 1;border-color:rgb(220 38 38 / var(--tw-border-opacity, 1));--tw-ring-opacity: 1;--tw-ring-color: rgb(220 38 38 / var(--tw-ring-opacity, 1))}._error_1n2ol_24{margin-top:.25rem;padding-left:.25rem;font-size:.75rem;line-height:1rem;font-weight:400;--tw-text-opacity: 1;color:rgb(220 38 38 / var(--tw-text-opacity, 1))}._label_1n2ol_32{margin-bottom:2px;display:flex;align-items:flex-end;justify-content:space-between;padding-left:1px;padding-right:.5rem;font-size:.75rem;line-height:1rem;font-weight:400}._labelError_1n2ol_36{font-size:.6875rem;--tw-text-opacity: 1;color:rgb(220 38 38 / var(--tw-text-opacity, 1))}._disabled_1n2ol_40{border-style:none;--tw-bg-opacity: 1;background-color:rgb(229 231 235 / var(--tw-bg-opacity, 1))}._disabledInput_1n2ol_44{--tw-text-opacity: 1;color:rgb(156 163 175 / var(--tw-text-opacity, 1))}._cvcIcon_1yx89_1{width:100%;height:100%}._iconContainer_29xfy_1{margin:0 2px}._container_1ari8_1{display:flex;width:100%;flex-grow:1;flex-direction:row;align-items:center;justify-content:flex-start;-moz-column-gap:.25rem;column-gap:.25rem;border-radius:.375rem;--tw-bg-opacity: 1;background-color:rgb(254 231 239 / var(--tw-bg-opacity, 1));padding:.75rem 1rem}._container_1ari8_1:is(._dark_1ari8_1 *){background-color:#fee7ef80;--tw-text-opacity: 1;color:rgb(239 68 68 / var(--tw-text-opacity, 1))}._iconContainer_1ari8_5{width:16px;height:16px}._icon_1ari8_5{width:100%;height:100%}._title_1ari8_15{padding-left:.25rem;font-size:.875rem;line-height:1.25rem;font-weight:300}._svg_1kkac_1{height:100%;width:100%}@keyframes _spin_1kkac_1{to{transform:rotate(360deg)}}._svg_1kkac_1{animation:_spin_1kkac_1 1s linear infinite;fill:#9ca3af;--tw-text-opacity: 1;color:rgb(229 231 235 / var(--tw-text-opacity, 1))}._svg_1kkac_1:is(._dark_1kkac_1 *){--tw-text-opacity: 1;color:rgb(75 85 99 / var(--tw-text-opacity, 1))}._sr_1kkac_5{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border-width:0}._container_a64yo_1{position:relative;height:auto;min-height:40px;width:100%;max-width:640px}._backBtn_a64yo_5{cursor:pointer}._cardBtn_a64yo_9{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}._btnContainer_a64yo_13{display:grid;gap:.5rem}._spinner_a64yo_17{height:40px;width:40px}._spinnerContainer_a64yo_21{position:absolute;z-index:50;display:flex;height:auto;width:100%;align-items:center;justify-content:center;border-radius:.375rem}._paypalBtn_2m8yd_1{overflow:hidden;border-radius:12px;height:40px}._container_ipway_1{display:flex;width:100%;flex-direction:column;align-items:center;justify-content:center}._icon_ipway_5{position:absolute;top:50%;left:50%;width:1.5rem;--tw-translate-x: -50%;--tw-translate-y: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));fill:#16a34a}._iconContainer_ipway_9{position:relative;display:grid;height:2.25rem;width:2.25rem;flex:none;place-items:center;border-radius:9999px;--tw-bg-opacity: 1;background-color:rgb(232 250 240 / var(--tw-bg-opacity, 1))}._iconContainer_ipway_9:is(._dark_ipway_1 *){--tw-bg-opacity: 1;background-color:rgb(209 244 224 / var(--tw-bg-opacity, 1))}._title_ipway_13{margin-top:.5rem;font-weight:300}
|
package/dist/index.d.ts
CHANGED
|
@@ -2,15 +2,6 @@ import { CSSProperties } from 'react';
|
|
|
2
2
|
import { FC } from 'react';
|
|
3
3
|
import { ReactNode } from 'react';
|
|
4
4
|
|
|
5
|
-
export declare interface AblePayConfig {
|
|
6
|
-
clientToken: string;
|
|
7
|
-
supportedCardTypes?: CardType[];
|
|
8
|
-
variant?: 'default' | 'compact';
|
|
9
|
-
styles?: StylesConfig;
|
|
10
|
-
onCheckoutComplete?: () => void;
|
|
11
|
-
onCheckoutFail?: (error: Error) => void;
|
|
12
|
-
}
|
|
13
|
-
|
|
14
5
|
declare const AblePayModule: FC<CheckoutFormProps>;
|
|
15
6
|
export { AblePayModule }
|
|
16
7
|
export { AblePayModule as CheckoutForm }
|
|
@@ -76,7 +67,7 @@ export declare const cardTypes: readonly [{
|
|
|
76
67
|
readonly maxLength: 19;
|
|
77
68
|
}];
|
|
78
69
|
|
|
79
|
-
export declare type CheckoutFormProps =
|
|
70
|
+
export declare type CheckoutFormProps = PayNextConfig & {
|
|
80
71
|
translate?: DeepPartial<CheckoutTranslate>;
|
|
81
72
|
locale?: Locale;
|
|
82
73
|
};
|
|
@@ -183,7 +174,7 @@ export declare enum InputError {
|
|
|
183
174
|
Expired = "expired"
|
|
184
175
|
}
|
|
185
176
|
|
|
186
|
-
declare
|
|
177
|
+
declare interface InputStyles {
|
|
187
178
|
field?: {
|
|
188
179
|
styles?: CSSProperties;
|
|
189
180
|
className?: string;
|
|
@@ -201,10 +192,19 @@ declare type InputStyles = {
|
|
|
201
192
|
className?: string;
|
|
202
193
|
focus?: string;
|
|
203
194
|
};
|
|
204
|
-
}
|
|
195
|
+
}
|
|
205
196
|
|
|
206
197
|
declare type Locale = keyof typeof i18n;
|
|
207
198
|
|
|
199
|
+
export declare interface PayNextConfig {
|
|
200
|
+
clientToken: string;
|
|
201
|
+
supportedCardTypes?: CardType[];
|
|
202
|
+
variant?: 'default' | 'compact';
|
|
203
|
+
styles?: StylesConfig;
|
|
204
|
+
onCheckoutComplete?: () => void;
|
|
205
|
+
onCheckoutFail?: (error: Error) => void;
|
|
206
|
+
}
|
|
207
|
+
|
|
208
208
|
export declare interface StylesConfig {
|
|
209
209
|
card?: {
|
|
210
210
|
input?: InputStyles;
|