@shipengine/elements 1.2.0 → 1.3.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/index.cjs +1447 -638
- package/index.js +1447 -639
- package/package.json +2 -2
- package/src/components/add-funds-form/add-funds-form.d.ts +2 -1
- package/src/components/auto-funding-form/auto-funding-form.d.ts +7 -2
- package/src/components/carrier-balance/carrier-balance.d.ts +3 -1
- package/src/components/drawer/drawer.styles.d.ts +0 -1
- package/src/components/fund-and-purchase/fund-and-purchase.d.ts +3 -1
- package/src/components/grid-controller/cell-formatted-date.d.ts +5 -3
- package/src/components/history/history-card/history-card.d.ts +4 -3
- package/src/components/history/history-card-extension/history-card-extension.d.ts +3 -1
- package/src/components/index.d.ts +0 -1
- package/src/components/manage-funding/manage-funding.d.ts +6 -1
- package/src/components/tabs/tabs.styles.d.ts +1 -1
- package/src/components/templates/account-settings/account-settings.d.ts +2 -1
- package/src/components/templates/connect-carrier-form/connect-carrier-form.d.ts +8 -2
- package/src/components/templates/connect-carrier-form/connect-carrier-form.styles.d.ts +4 -0
- package/src/components/templates/index.d.ts +1 -1
- package/src/components/templates/product-form/index.d.ts +2 -0
- package/src/components/templates/{customs-item-form/customs-item-form-schema.d.ts → product-form/product-form-schema.d.ts} +16 -16
- package/src/components/templates/product-form/product-form.d.ts +15 -0
- package/src/components/templates/products-display/index.d.ts +1 -0
- package/src/components/templates/products-display/products-display.d.ts +7 -0
- package/src/components/templates/rate-form/rate-form.d.ts +2 -1
- package/src/components/templates/shipment-form/shipment-form.d.ts +3 -2
- package/src/components/templates/shipment-form/shipment-schema.d.ts +331 -140
- package/src/components/templates/theme-creator/theme-creator.d.ts +6 -1
- package/src/components/templates/theme-creator/theme-creator.styles.d.ts +2 -2
- package/src/elements/account-settings/account-settings.d.ts +51 -6
- package/src/elements/configure-shipment/configure-shipment.d.ts +2 -1
- package/src/elements/configure-shipment/hooks/use-customs.d.ts +1 -1
- package/src/elements/configure-shipment/hooks/use-rates-with-cache.d.ts +4 -4
- package/src/elements/configure-shipment/hooks/use-shipment-form.d.ts +1 -1
- package/src/elements/connect-carrier/connect-carrier.d.ts +17 -3
- package/src/elements/labels-grid/labels-grid.d.ts +12 -1
- package/src/elements/purchase-label/purchase-label-by-sales-order.d.ts +3 -1
- package/src/elements/purchase-label/purchase-label-by-shipment.d.ts +3 -1
- package/src/elements/purchase-label/purchase-label.d.ts +64 -28
- package/src/elements/shipments-grid/shipments-grid.d.ts +12 -1
- package/src/elements/theme-creator/theme-creator.d.ts +16 -1
- package/src/elements/view-shipment/view-shipment.d.ts +12 -1
- package/src/elements/void-label/void-label.d.ts +18 -8
- package/src/factories/shipengine/shipment.d.ts +2 -1
- package/src/features/wallet-history/wallet-history.styles.d.ts +6 -1
- package/src/locales/en/index.d.ts +12 -1
- package/src/utilities/money.d.ts +7 -0
- package/src/utilities/shipengine/sales-order.d.ts +4 -1
- package/src/workflows/onboarding/onboarding.d.ts +19 -1
- package/src/components/code-block/code-block.d.ts +0 -6
- package/src/components/code-block/index.d.ts +0 -1
- package/src/components/field/money-input/hooks/index.d.ts +0 -1
- package/src/components/field/money-input/hooks/use-utils.d.ts +0 -6
- package/src/components/templates/connect-carrier/connect-carrier.d.ts +0 -1
- package/src/components/templates/connect-carrier/connect-carrier.styles.d.ts +0 -1
- package/src/components/templates/connect-carrier/index.d.ts +0 -1
- package/src/components/templates/customs-item-form/customs-item-form.d.ts +0 -15
- package/src/components/templates/customs-item-form/index.d.ts +0 -2
- package/src/components/templates/customs-items-display/customs-items-display.d.ts +0 -7
- package/src/components/templates/customs-items-display/index.d.ts +0 -1
- /package/src/components/templates/{customs-items-display/customs-items-display.styles.d.ts → products-display/products-display.styles.d.ts} +0 -0
|
@@ -96,8 +96,15 @@ export declare const Element: ({ resources, ...props }: ComponentProps & {
|
|
|
96
96
|
actions: {
|
|
97
97
|
downloadCsv: string;
|
|
98
98
|
chooseDate: string;
|
|
99
|
+
tryAgain: string;
|
|
100
|
+
};
|
|
101
|
+
errors: {
|
|
102
|
+
failureToFetch: string;
|
|
99
103
|
};
|
|
100
104
|
dateRange: string;
|
|
105
|
+
details: {
|
|
106
|
+
inaccurateWeight: string;
|
|
107
|
+
};
|
|
101
108
|
historyOptions: {
|
|
102
109
|
custom: string;
|
|
103
110
|
last30days: string;
|
|
@@ -632,6 +639,7 @@ export declare const Element: ({ resources, ...props }: ComponentProps & {
|
|
|
632
639
|
autoFundingSettings: string;
|
|
633
640
|
carrier: string;
|
|
634
641
|
carriers: string;
|
|
642
|
+
connectCarrierForm: string;
|
|
635
643
|
fundingSourceMetadata: string;
|
|
636
644
|
label: string;
|
|
637
645
|
salesOrder: string;
|
|
@@ -669,6 +677,7 @@ export declare const Element: ({ resources, ...props }: ComponentProps & {
|
|
|
669
677
|
accountSettings: string;
|
|
670
678
|
carrier: string;
|
|
671
679
|
carriers: string;
|
|
680
|
+
connectCarrierForm: string;
|
|
672
681
|
connectingCarriers: string;
|
|
673
682
|
creatingFundingSource: string;
|
|
674
683
|
data: string;
|
|
@@ -770,11 +779,13 @@ export declare const Element: ({ resources, ...props }: ComponentProps & {
|
|
|
770
779
|
"connect-carrier": {
|
|
771
780
|
registrationForm: {
|
|
772
781
|
title: string;
|
|
773
|
-
isLoading: string;
|
|
774
782
|
betaWarning: string;
|
|
775
783
|
};
|
|
776
784
|
};
|
|
777
785
|
"account-settings": {
|
|
786
|
+
messages: {
|
|
787
|
+
noFundingSources: string;
|
|
788
|
+
};
|
|
778
789
|
title: string;
|
|
779
790
|
sections: {
|
|
780
791
|
accountBalance: string;
|
|
@@ -102,8 +102,15 @@ export declare const Element: ({ resources, ...props }: ComponentProps & {
|
|
|
102
102
|
actions: {
|
|
103
103
|
downloadCsv: string;
|
|
104
104
|
chooseDate: string;
|
|
105
|
+
tryAgain: string;
|
|
106
|
+
};
|
|
107
|
+
errors: {
|
|
108
|
+
failureToFetch: string;
|
|
105
109
|
};
|
|
106
110
|
dateRange: string;
|
|
111
|
+
details: {
|
|
112
|
+
inaccurateWeight: string;
|
|
113
|
+
};
|
|
107
114
|
historyOptions: {
|
|
108
115
|
custom: string;
|
|
109
116
|
last30days: string;
|
|
@@ -458,6 +465,12 @@ export declare const Element: ({ resources, ...props }: ComponentProps & {
|
|
|
458
465
|
other: string;
|
|
459
466
|
};
|
|
460
467
|
fundAndPurchase: {
|
|
468
|
+
/**
|
|
469
|
+
* `onViewShipment` is a callback function that will be invoked when the user clicks the
|
|
470
|
+
* `View Shipment` button. This will take you back to the
|
|
471
|
+
* {@link ViewShipment.Element | `View Shipment Element`} for the given shipment, where you
|
|
472
|
+
* will be able to see the voided label listed.
|
|
473
|
+
*/
|
|
461
474
|
finalBalance: string;
|
|
462
475
|
insufficientFunds: string;
|
|
463
476
|
insufficientFundsTitle: string;
|
|
@@ -624,6 +637,7 @@ export declare const Element: ({ resources, ...props }: ComponentProps & {
|
|
|
624
637
|
autoFundingSettings: string;
|
|
625
638
|
carrier: string;
|
|
626
639
|
carriers: string;
|
|
640
|
+
connectCarrierForm: string;
|
|
627
641
|
fundingSourceMetadata: string;
|
|
628
642
|
label: string;
|
|
629
643
|
salesOrder: string;
|
|
@@ -661,6 +675,7 @@ export declare const Element: ({ resources, ...props }: ComponentProps & {
|
|
|
661
675
|
accountSettings: string;
|
|
662
676
|
carrier: string;
|
|
663
677
|
carriers: string;
|
|
678
|
+
connectCarrierForm: string;
|
|
664
679
|
connectingCarriers: string;
|
|
665
680
|
creatingFundingSource: string;
|
|
666
681
|
data: string;
|
|
@@ -762,11 +777,13 @@ export declare const Element: ({ resources, ...props }: ComponentProps & {
|
|
|
762
777
|
"connect-carrier": {
|
|
763
778
|
registrationForm: {
|
|
764
779
|
title: string;
|
|
765
|
-
isLoading: string;
|
|
766
780
|
betaWarning: string;
|
|
767
781
|
};
|
|
768
782
|
};
|
|
769
783
|
"account-settings": {
|
|
784
|
+
messages: {
|
|
785
|
+
noFundingSources: string;
|
|
786
|
+
};
|
|
770
787
|
title: string;
|
|
771
788
|
sections: {
|
|
772
789
|
accountBalance: string;
|
|
@@ -776,13 +793,6 @@ export declare const Element: ({ resources, ...props }: ComponentProps & {
|
|
|
776
793
|
warehouses: string;
|
|
777
794
|
carriers: string;
|
|
778
795
|
labelLayout: string;
|
|
779
|
-
/**
|
|
780
|
-
* # Void Label Component Props
|
|
781
|
-
*
|
|
782
|
-
* - These are the base props that will be passed into the `<VoidLabel />` component.
|
|
783
|
-
*
|
|
784
|
-
* @see {@link VoidLabel.Component | This prop types usage in the `<VoidLabel />` component}
|
|
785
|
-
*/
|
|
786
796
|
unitSettings: string;
|
|
787
797
|
};
|
|
788
798
|
};
|
|
@@ -6,13 +6,14 @@ export declare const randomInsuranceProvider: (allowNone?: boolean) => SE.Insura
|
|
|
6
6
|
/**
|
|
7
7
|
* @category Factories
|
|
8
8
|
*/
|
|
9
|
-
export declare const
|
|
9
|
+
export declare const productFactory: Factory<SE.Product, MoneyTransientParams, SE.Product>;
|
|
10
10
|
/**
|
|
11
11
|
* @category Factories
|
|
12
12
|
*/
|
|
13
13
|
export declare const shipmentItemFactory: Factory<SE.SalesOrderShipmentItem, any, SE.SalesOrderShipmentItem>;
|
|
14
14
|
export type ShipmentPackageTransientParams = {
|
|
15
15
|
isInsured?: boolean;
|
|
16
|
+
isInternational?: boolean;
|
|
16
17
|
isShipped?: boolean;
|
|
17
18
|
};
|
|
18
19
|
/**
|
|
@@ -26,7 +26,8 @@ export declare const styles: {
|
|
|
26
26
|
justifyContent: "space-between";
|
|
27
27
|
placeItems: "center";
|
|
28
28
|
};
|
|
29
|
-
linkAction:
|
|
29
|
+
linkAction: {
|
|
30
|
+
margin: string;
|
|
30
31
|
textAlign: "end";
|
|
31
32
|
};
|
|
32
33
|
pagination: (theme: import("@shipengine/giger-theme/dist/lib/Theme").Theme) => {
|
|
@@ -78,4 +79,8 @@ export declare const styles: {
|
|
|
78
79
|
marginRight: string;
|
|
79
80
|
maxWidth: string;
|
|
80
81
|
};
|
|
82
|
+
transactionTypeSelect: {
|
|
83
|
+
height: string;
|
|
84
|
+
width: string;
|
|
85
|
+
};
|
|
81
86
|
};
|
|
@@ -3,8 +3,15 @@ declare const _default: {
|
|
|
3
3
|
actions: {
|
|
4
4
|
downloadCsv: string;
|
|
5
5
|
chooseDate: string;
|
|
6
|
+
tryAgain: string;
|
|
7
|
+
};
|
|
8
|
+
errors: {
|
|
9
|
+
failureToFetch: string;
|
|
6
10
|
};
|
|
7
11
|
dateRange: string;
|
|
12
|
+
details: {
|
|
13
|
+
inaccurateWeight: string;
|
|
14
|
+
};
|
|
8
15
|
historyOptions: {
|
|
9
16
|
custom: string;
|
|
10
17
|
last30days: string;
|
|
@@ -520,6 +527,7 @@ declare const _default: {
|
|
|
520
527
|
autoFundingSettings: string;
|
|
521
528
|
carrier: string;
|
|
522
529
|
carriers: string;
|
|
530
|
+
connectCarrierForm: string;
|
|
523
531
|
fundingSourceMetadata: string;
|
|
524
532
|
label: string;
|
|
525
533
|
salesOrder: string;
|
|
@@ -557,6 +565,7 @@ declare const _default: {
|
|
|
557
565
|
accountSettings: string;
|
|
558
566
|
carrier: string;
|
|
559
567
|
carriers: string;
|
|
568
|
+
connectCarrierForm: string;
|
|
560
569
|
connectingCarriers: string;
|
|
561
570
|
creatingFundingSource: string;
|
|
562
571
|
data: string;
|
|
@@ -658,11 +667,13 @@ declare const _default: {
|
|
|
658
667
|
"connect-carrier": {
|
|
659
668
|
registrationForm: {
|
|
660
669
|
title: string;
|
|
661
|
-
isLoading: string;
|
|
662
670
|
betaWarning: string;
|
|
663
671
|
};
|
|
664
672
|
};
|
|
665
673
|
"account-settings": {
|
|
674
|
+
messages: {
|
|
675
|
+
noFundingSources: string;
|
|
676
|
+
};
|
|
666
677
|
title: string;
|
|
667
678
|
sections: {
|
|
668
679
|
accountBalance: string;
|
package/src/utilities/money.d.ts
CHANGED
|
@@ -29,3 +29,10 @@ export declare const formatCreditCardNumber: (cc: string) => string;
|
|
|
29
29
|
* # Money Utils - formatExpiration
|
|
30
30
|
*/
|
|
31
31
|
export declare const formatExpiration: (exp: string) => string;
|
|
32
|
+
/**
|
|
33
|
+
* @internal
|
|
34
|
+
*
|
|
35
|
+
* # Money Utils - getCurrencyFromString
|
|
36
|
+
*/
|
|
37
|
+
export declare const getCurrencyFromString: (currency?: string) => SE.Currency;
|
|
38
|
+
export declare const getCurrencySymbolFromString: (currency?: string) => string | undefined;
|
|
@@ -6,7 +6,10 @@ import { SE } from "@shipengine/alchemy";
|
|
|
6
6
|
*
|
|
7
7
|
* @category Utilities
|
|
8
8
|
*/
|
|
9
|
-
export declare const getCustomsFromSalesOrder: (salesOrder: SE.SalesOrder, warehouse: SE.Warehouse) =>
|
|
9
|
+
export declare const getCustomsFromSalesOrder: (salesOrder: SE.SalesOrder, warehouse: SE.Warehouse) => {
|
|
10
|
+
customs: SE.Customs;
|
|
11
|
+
products: SE.Product[];
|
|
12
|
+
};
|
|
10
13
|
/**
|
|
11
14
|
* @internal
|
|
12
15
|
*
|
|
@@ -80,8 +80,15 @@ export declare const Element: ({ resources, ...props }: ComponentProps & {
|
|
|
80
80
|
actions: {
|
|
81
81
|
downloadCsv: string;
|
|
82
82
|
chooseDate: string;
|
|
83
|
+
tryAgain: string;
|
|
84
|
+
};
|
|
85
|
+
errors: {
|
|
86
|
+
failureToFetch: string;
|
|
83
87
|
};
|
|
84
88
|
dateRange: string;
|
|
89
|
+
details: {
|
|
90
|
+
inaccurateWeight: string;
|
|
91
|
+
};
|
|
85
92
|
historyOptions: {
|
|
86
93
|
custom: string;
|
|
87
94
|
last30days: string;
|
|
@@ -638,6 +645,7 @@ export declare const Element: ({ resources, ...props }: ComponentProps & {
|
|
|
638
645
|
autoFundingSettings: string;
|
|
639
646
|
carrier: string;
|
|
640
647
|
carriers: string;
|
|
648
|
+
connectCarrierForm: string;
|
|
641
649
|
fundingSourceMetadata: string;
|
|
642
650
|
label: string;
|
|
643
651
|
salesOrder: string;
|
|
@@ -675,6 +683,7 @@ export declare const Element: ({ resources, ...props }: ComponentProps & {
|
|
|
675
683
|
accountSettings: string;
|
|
676
684
|
carrier: string;
|
|
677
685
|
carriers: string;
|
|
686
|
+
connectCarrierForm: string;
|
|
678
687
|
connectingCarriers: string;
|
|
679
688
|
creatingFundingSource: string;
|
|
680
689
|
data: string;
|
|
@@ -776,13 +785,22 @@ export declare const Element: ({ resources, ...props }: ComponentProps & {
|
|
|
776
785
|
"connect-carrier": {
|
|
777
786
|
registrationForm: {
|
|
778
787
|
title: string;
|
|
779
|
-
isLoading: string;
|
|
780
788
|
betaWarning: string;
|
|
781
789
|
};
|
|
782
790
|
};
|
|
783
791
|
"account-settings": {
|
|
792
|
+
messages: {
|
|
793
|
+
noFundingSources: string;
|
|
794
|
+
};
|
|
784
795
|
title: string;
|
|
785
796
|
sections: {
|
|
797
|
+
/**
|
|
798
|
+
* # Onboarding Component Props
|
|
799
|
+
*
|
|
800
|
+
* - These are the base props that will be passed into the `<Onboarding />` component.
|
|
801
|
+
*
|
|
802
|
+
* @see {@link Onboarding.Component | This prop types usage in the `<Onboarding />` component}
|
|
803
|
+
*/
|
|
786
804
|
accountBalance: string;
|
|
787
805
|
paymentMethod: string;
|
|
788
806
|
transactionHistory: string;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from "./code-block";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from "./use-utils";
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare const ConnectCarrier: () => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export declare const styles: {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from "./connect-carrier";
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
|
-
import { SE } from "@shipengine/alchemy";
|
|
3
|
-
export type CustomsItemFormProps<T = undefined> = {
|
|
4
|
-
customsItem?: SE.CustomsItem;
|
|
5
|
-
onCancel?: () => void;
|
|
6
|
-
onSubmit: (values: SE.CustomsItem) => Promise<void>;
|
|
7
|
-
shipToCountry?: string;
|
|
8
|
-
} & ({
|
|
9
|
-
formId: string;
|
|
10
|
-
portalRef: React.RefObject<T>;
|
|
11
|
-
} | {
|
|
12
|
-
formId?: string;
|
|
13
|
-
portalRef?: never;
|
|
14
|
-
});
|
|
15
|
-
export declare const CustomsItemForm: <T extends Element>({ customsItem, formId, onCancel, onSubmit, portalRef, shipToCountry, }: CustomsItemFormProps<T>) => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import { SE } from "@shipengine/alchemy";
|
|
2
|
-
type CustomsItemsDisplayProps = {
|
|
3
|
-
onUpdate: (customsItems: SE.CustomsItem[]) => Promise<void>;
|
|
4
|
-
shipment: SE.SalesOrderShipment;
|
|
5
|
-
};
|
|
6
|
-
export declare const CustomsItemsDisplay: ({ onUpdate, shipment }: CustomsItemsDisplayProps) => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
7
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from "./customs-items-display";
|