@shipengine/elements 0.18.0 → 0.19.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/components/history/history-actions/history-actions.d.ts +1 -0
- package/components/history/history-actions/history-actions.styles.d.ts +1 -0
- package/components/history/history-actions/index.d.ts +1 -0
- package/components/history/history-body/history-body.d.ts +6 -0
- package/components/history/history-body/index.d.ts +1 -0
- package/components/history/history-list/history-list.d.ts +12 -0
- package/components/history/history-list/index.d.ts +1 -0
- package/components/history/history-row/history-row.d.ts +6 -0
- package/components/history/history-row/index.d.ts +1 -0
- package/components/history/history.d.ts +11 -0
- package/components/history/index.d.ts +1 -0
- package/components/templates/index.d.ts +1 -0
- package/components/templates/onboarding/onboarding.d.ts +7 -1
- package/components/templates/wallet-history/index.d.ts +1 -0
- package/components/templates/wallet-history/wallet-history.d.ts +6 -0
- package/components/templates/warehouse-form/warehouse-form-schema.d.ts +51 -45
- package/elements/components/index.d.ts +1 -0
- package/elements/components/wallet-history/index.d.ts +1 -0
- package/elements/components/wallet-history/wallet-history.d.ts +1 -0
- package/elements/index.d.ts +1 -0
- package/elements/wallet-history.d.ts +1 -0
- package/factories/shipengine/index.d.ts +1 -0
- package/factories/shipengine/wallet-history.d.ts +14 -0
- package/index.cjs +251 -81
- package/index.js +249 -80
- package/locales/en/index.d.ts +11 -0
- package/package.json +3 -3
package/index.cjs
CHANGED
|
@@ -23098,7 +23098,7 @@ const AddressParser = ({
|
|
|
23098
23098
|
}));
|
|
23099
23099
|
};
|
|
23100
23100
|
|
|
23101
|
-
const styles$
|
|
23101
|
+
const styles$b = createStyles({
|
|
23102
23102
|
grow: {
|
|
23103
23103
|
flexGrow: 1
|
|
23104
23104
|
},
|
|
@@ -23197,13 +23197,13 @@ const AddressFields = ({
|
|
|
23197
23197
|
},
|
|
23198
23198
|
options: countryCodeOptions
|
|
23199
23199
|
}), jsxRuntime.jsxs("div", Object.assign({
|
|
23200
|
-
css: styles$
|
|
23200
|
+
css: styles$b.stateZipWrapper
|
|
23201
23201
|
}, {
|
|
23202
23202
|
children: [jsxRuntime.jsx("div", Object.assign({
|
|
23203
|
-
css: styles$
|
|
23203
|
+
css: styles$b.stateWrapper
|
|
23204
23204
|
}, {
|
|
23205
23205
|
children: jsxRuntime.jsx("div", Object.assign({
|
|
23206
|
-
css: styles$
|
|
23206
|
+
css: styles$b.grow
|
|
23207
23207
|
}, {
|
|
23208
23208
|
children: watchCountryCode === "US" ?
|
|
23209
23209
|
// Domestic States
|
|
@@ -23227,10 +23227,10 @@ const AddressFields = ({
|
|
|
23227
23227
|
})
|
|
23228
23228
|
}))
|
|
23229
23229
|
})), jsxRuntime.jsx("div", Object.assign({
|
|
23230
|
-
css: styles$
|
|
23230
|
+
css: styles$b.zipWrapper
|
|
23231
23231
|
}, {
|
|
23232
23232
|
children: jsxRuntime.jsx("div", Object.assign({
|
|
23233
|
-
css: styles$
|
|
23233
|
+
css: styles$b.grow
|
|
23234
23234
|
}, {
|
|
23235
23235
|
children: jsxRuntime.jsx(TextInput, {
|
|
23236
23236
|
control: form.control,
|
|
@@ -23458,7 +23458,7 @@ const AddressForm = ({
|
|
|
23458
23458
|
}));
|
|
23459
23459
|
};
|
|
23460
23460
|
|
|
23461
|
-
const styles$
|
|
23461
|
+
const styles$a = createStyles({
|
|
23462
23462
|
agreement: {
|
|
23463
23463
|
alignItems: "center",
|
|
23464
23464
|
display: "flex",
|
|
@@ -23528,10 +23528,10 @@ const DisplayCarrierTerms = c => {
|
|
|
23528
23528
|
const listCarrierLinks = () => {
|
|
23529
23529
|
return c.carrierTerms.links.map((term, index) => {
|
|
23530
23530
|
return jsxRuntime.jsx("li", Object.assign({
|
|
23531
|
-
css: styles$
|
|
23531
|
+
css: styles$a.listItems
|
|
23532
23532
|
}, {
|
|
23533
23533
|
children: jsxRuntime.jsx(giger.Link, Object.assign({
|
|
23534
|
-
css: styles$
|
|
23534
|
+
css: styles$a.link,
|
|
23535
23535
|
href: term.url,
|
|
23536
23536
|
isExternal: true,
|
|
23537
23537
|
target: "_blank"
|
|
@@ -23547,18 +23547,18 @@ const DisplayCarrierTerms = c => {
|
|
|
23547
23547
|
};
|
|
23548
23548
|
const listCarrierTerms = () => {
|
|
23549
23549
|
return jsxRuntime.jsxs("div", Object.assign({
|
|
23550
|
-
css: styles$
|
|
23550
|
+
css: styles$a.terms
|
|
23551
23551
|
}, {
|
|
23552
23552
|
children: [jsxRuntime.jsx(giger.Typography, Object.assign({
|
|
23553
23553
|
variant: "subtitle1"
|
|
23554
23554
|
}, {
|
|
23555
23555
|
children: c.carrierTerms.title
|
|
23556
23556
|
})), jsxRuntime.jsx("div", Object.assign({
|
|
23557
|
-
css: styles$
|
|
23557
|
+
css: styles$a.terms
|
|
23558
23558
|
}, {
|
|
23559
23559
|
children: listCarrierContent()
|
|
23560
23560
|
})), jsxRuntime.jsx("ul", Object.assign({
|
|
23561
|
-
css: styles$
|
|
23561
|
+
css: styles$a.links
|
|
23562
23562
|
}, {
|
|
23563
23563
|
children: listCarrierLinks()
|
|
23564
23564
|
}))]
|
|
@@ -23788,7 +23788,7 @@ const AddressDisplay = ({
|
|
|
23788
23788
|
}));
|
|
23789
23789
|
};
|
|
23790
23790
|
|
|
23791
|
-
const styles$
|
|
23791
|
+
const styles$9 = createStyles({
|
|
23792
23792
|
container: theme => ({
|
|
23793
23793
|
display: "flex",
|
|
23794
23794
|
gap: theme.spacing()
|
|
@@ -23826,13 +23826,13 @@ const Disclosure = ({
|
|
|
23826
23826
|
}, [open]);
|
|
23827
23827
|
return jsxRuntime.jsxs(jsxRuntime.Fragment, {
|
|
23828
23828
|
children: [jsxRuntime.jsxs("div", Object.assign({
|
|
23829
|
-
css: styles$
|
|
23829
|
+
css: styles$9.container
|
|
23830
23830
|
}, {
|
|
23831
23831
|
children: [jsxRuntime.jsx("div", {
|
|
23832
23832
|
children: label
|
|
23833
23833
|
}), _showToggle && jsxRuntime.jsx("button", Object.assign({
|
|
23834
23834
|
"aria-expanded": isOpen,
|
|
23835
|
-
css: styles$
|
|
23835
|
+
css: styles$9.toggle,
|
|
23836
23836
|
onClick: () => {
|
|
23837
23837
|
setIsOpen(!isOpen);
|
|
23838
23838
|
onToggle(!isOpen);
|
|
@@ -23840,12 +23840,12 @@ const Disclosure = ({
|
|
|
23840
23840
|
type: "button"
|
|
23841
23841
|
}, {
|
|
23842
23842
|
children: jsxRuntime.jsx(giger.Icon, {
|
|
23843
|
-
css: styles$
|
|
23843
|
+
css: styles$9.icon,
|
|
23844
23844
|
name: isOpen ? brands.IconNames.CHEVRON_TOP : brands.IconNames.CHEVRON_BOTTOM
|
|
23845
23845
|
})
|
|
23846
23846
|
}))]
|
|
23847
23847
|
})), isOpen && jsxRuntime.jsx("div", Object.assign({
|
|
23848
|
-
css: styles$
|
|
23848
|
+
css: styles$9.content
|
|
23849
23849
|
}, {
|
|
23850
23850
|
children: typeof children === "function" ? children(() => setIsOpen(!isOpen)) : children
|
|
23851
23851
|
}))]
|
|
@@ -23985,7 +23985,7 @@ const getCarrierRecoverySchema = requiresAddress => zod.z.object({
|
|
|
23985
23985
|
address: requiresAddress ? baseSchema : baseSchema.optional()
|
|
23986
23986
|
});
|
|
23987
23987
|
|
|
23988
|
-
const styles$
|
|
23988
|
+
const styles$8 = createStyles({
|
|
23989
23989
|
grid: theme => ({
|
|
23990
23990
|
margin: theme.spacing(4)
|
|
23991
23991
|
}),
|
|
@@ -24028,7 +24028,7 @@ const CarrierRecoveryForm = ({
|
|
|
24028
24028
|
onSubmit: formLogger.capture(handleSubmit)
|
|
24029
24029
|
}, {
|
|
24030
24030
|
children: jsxRuntime.jsxs(giger.Grid, Object.assign({
|
|
24031
|
-
css: styles$
|
|
24031
|
+
css: styles$8.grid,
|
|
24032
24032
|
noPadding: true
|
|
24033
24033
|
}, {
|
|
24034
24034
|
children: [requiresAddress && jsxRuntime.jsxs(jsxRuntime.Fragment, {
|
|
@@ -24036,14 +24036,14 @@ const CarrierRecoveryForm = ({
|
|
|
24036
24036
|
colSpan: 12
|
|
24037
24037
|
}, {
|
|
24038
24038
|
children: jsxRuntime.jsx(giger.Typography, Object.assign({
|
|
24039
|
-
css: styles$
|
|
24039
|
+
css: styles$8.heading,
|
|
24040
24040
|
variant: "heading4"
|
|
24041
24041
|
}, {
|
|
24042
24042
|
children: t("register-wallet:sections.carriers.title")
|
|
24043
24043
|
}))
|
|
24044
24044
|
})), jsxRuntime.jsx(giger.GridChild, Object.assign({
|
|
24045
24045
|
colSpan: 12,
|
|
24046
|
-
css: styles$
|
|
24046
|
+
css: styles$8.subtitle
|
|
24047
24047
|
}, {
|
|
24048
24048
|
children: jsxRuntime.jsx(giger.Typography, Object.assign({
|
|
24049
24049
|
variant: "subtitle1"
|
|
@@ -24129,7 +24129,7 @@ const CarrierTermsForm = ({
|
|
|
24129
24129
|
onSubmit(payload.agreement);
|
|
24130
24130
|
}));
|
|
24131
24131
|
return jsxRuntime.jsxs("div", Object.assign({
|
|
24132
|
-
css: styles$
|
|
24132
|
+
css: styles$a.termsForm,
|
|
24133
24133
|
"data-testid": "carrier-terms-form"
|
|
24134
24134
|
}, {
|
|
24135
24135
|
children: [jsxRuntime.jsx(giger.Typography, Object.assign({
|
|
@@ -24145,7 +24145,7 @@ const CarrierTermsForm = ({
|
|
|
24145
24145
|
})), jsxRuntime.jsx(Spacer, {
|
|
24146
24146
|
multiplier: 1
|
|
24147
24147
|
}), jsxRuntime.jsx("div", Object.assign({
|
|
24148
|
-
css: styles$
|
|
24148
|
+
css: styles$a.carrierLogos
|
|
24149
24149
|
}, {
|
|
24150
24150
|
children: metadatas.map(({
|
|
24151
24151
|
name,
|
|
@@ -24161,7 +24161,7 @@ const CarrierTermsForm = ({
|
|
|
24161
24161
|
onSubmit: formLogger.capture(handleSubmit)
|
|
24162
24162
|
}, {
|
|
24163
24163
|
children: jsxRuntime.jsxs("div", Object.assign({
|
|
24164
|
-
css: styles$
|
|
24164
|
+
css: styles$a.agreement
|
|
24165
24165
|
}, {
|
|
24166
24166
|
children: [jsxRuntime.jsx("div", {
|
|
24167
24167
|
children: jsxRuntime.jsx(CheckboxInput, {
|
|
@@ -24188,12 +24188,12 @@ const CarrierTermsForm = ({
|
|
|
24188
24188
|
name: "agreement"
|
|
24189
24189
|
})
|
|
24190
24190
|
}), showTerms && jsxRuntime.jsxs("div", Object.assign({
|
|
24191
|
-
css: styles$
|
|
24191
|
+
css: styles$a.well
|
|
24192
24192
|
}, {
|
|
24193
24193
|
children: [terms.map((t, idx) => jsxRuntime.jsx(DisplayCarrierTerms, {
|
|
24194
24194
|
carrierTerms: t
|
|
24195
24195
|
}, idx)), jsxRuntime.jsx("div", Object.assign({
|
|
24196
|
-
css: styles$
|
|
24196
|
+
css: styles$a.close
|
|
24197
24197
|
}, {
|
|
24198
24198
|
children: jsxRuntime.jsx(giger.Button, Object.assign({
|
|
24199
24199
|
onClick: () => setShowTerms(false),
|
|
@@ -24581,7 +24581,7 @@ const LandingPageForm = ({
|
|
|
24581
24581
|
}));
|
|
24582
24582
|
};
|
|
24583
24583
|
|
|
24584
|
-
const styles$
|
|
24584
|
+
const styles$7 = createStyles({
|
|
24585
24585
|
container: theme => ({
|
|
24586
24586
|
padding: theme.spacing(2)
|
|
24587
24587
|
}),
|
|
@@ -24603,11 +24603,11 @@ const LandingPage = ({
|
|
|
24603
24603
|
t
|
|
24604
24604
|
} = reactI18next.useTranslation();
|
|
24605
24605
|
return jsxRuntime.jsxs("div", Object.assign({
|
|
24606
|
-
css: styles$
|
|
24606
|
+
css: styles$7.container,
|
|
24607
24607
|
"data-testid": "landing-page"
|
|
24608
24608
|
}, {
|
|
24609
24609
|
children: [jsxRuntime.jsxs("div", Object.assign({
|
|
24610
|
-
css: styles$
|
|
24610
|
+
css: styles$7.header
|
|
24611
24611
|
}, {
|
|
24612
24612
|
children: [jsxRuntime.jsx(giger.Typography, Object.assign({
|
|
24613
24613
|
variant: "heading4"
|
|
@@ -24625,7 +24625,7 @@ const LandingPage = ({
|
|
|
24625
24625
|
})), jsxRuntime.jsx(LandingPageForm, {
|
|
24626
24626
|
onSubmit: onSubmit
|
|
24627
24627
|
}), jsxRuntime.jsxs("div", Object.assign({
|
|
24628
|
-
css: styles$
|
|
24628
|
+
css: styles$7.header
|
|
24629
24629
|
}, {
|
|
24630
24630
|
children: [jsxRuntime.jsx(Spacer, {
|
|
24631
24631
|
multiplier: 6
|
|
@@ -24636,7 +24636,7 @@ const LandingPage = ({
|
|
|
24636
24636
|
})), jsxRuntime.jsx(Spacer, {
|
|
24637
24637
|
multiplier: 2
|
|
24638
24638
|
}), jsxRuntime.jsx(giger.Typography, Object.assign({
|
|
24639
|
-
css: styles$
|
|
24639
|
+
css: styles$7.description,
|
|
24640
24640
|
variant: "body1"
|
|
24641
24641
|
}, {
|
|
24642
24642
|
children: t("onboarding:landing.description")
|
|
@@ -24820,7 +24820,7 @@ const ListCarriersRow = ({
|
|
|
24820
24820
|
}));
|
|
24821
24821
|
};
|
|
24822
24822
|
|
|
24823
|
-
const styles$
|
|
24823
|
+
const styles$6 = createStyles({
|
|
24824
24824
|
listContainer: theme => ({
|
|
24825
24825
|
"& > li:not(:last-of-type)": {
|
|
24826
24826
|
borderBottom: `1px solid ${theme.palette.gray.light}`
|
|
@@ -24867,7 +24867,7 @@ const ListCarriers$1 = ({
|
|
|
24867
24867
|
children: t("list-carriers:headers.accountCarriers")
|
|
24868
24868
|
}))
|
|
24869
24869
|
}), jsxRuntime.jsx("ul", Object.assign({
|
|
24870
|
-
css: styles$
|
|
24870
|
+
css: styles$6.listContainer
|
|
24871
24871
|
}, {
|
|
24872
24872
|
children: isLoading ? jsxRuntime.jsxs(jsxRuntime.Fragment, {
|
|
24873
24873
|
children: [jsxRuntime.jsx(LoadingSkeletonRow, {}), jsxRuntime.jsx(LoadingSkeletonRow, {}), jsxRuntime.jsx(LoadingSkeletonRow, {})]
|
|
@@ -24888,10 +24888,10 @@ const ListCarriers$1 = ({
|
|
|
24888
24888
|
};
|
|
24889
24889
|
const LoadingSkeletonRow = () => {
|
|
24890
24890
|
return jsxRuntime.jsxs("div", Object.assign({
|
|
24891
|
-
css: styles$
|
|
24891
|
+
css: styles$6.skeletonRow
|
|
24892
24892
|
}, {
|
|
24893
24893
|
children: [jsxRuntime.jsxs("div", Object.assign({
|
|
24894
|
-
css: styles$
|
|
24894
|
+
css: styles$6.skeletonLogoContainer
|
|
24895
24895
|
}, {
|
|
24896
24896
|
children: [jsxRuntime.jsx(giger.Skeleton, {
|
|
24897
24897
|
animation: giger.SkeletonAnimation.WAVE,
|
|
@@ -24915,7 +24915,7 @@ const LoadingSkeletonRow = () => {
|
|
|
24915
24915
|
}));
|
|
24916
24916
|
};
|
|
24917
24917
|
|
|
24918
|
-
const styles$
|
|
24918
|
+
const styles$5 = createStyles({
|
|
24919
24919
|
body: theme => ({
|
|
24920
24920
|
borderTop: `1px solid ${theme.palette.gray.light}`,
|
|
24921
24921
|
color: theme.palette.black,
|
|
@@ -24966,14 +24966,14 @@ const SettingsCard = ({
|
|
|
24966
24966
|
verticallyAligned
|
|
24967
24967
|
}) => {
|
|
24968
24968
|
return jsxRuntime.jsxs("div", Object.assign({
|
|
24969
|
-
css: verticallyAligned ? styles$
|
|
24969
|
+
css: verticallyAligned ? styles$5.verticalContainer : styles$5.container,
|
|
24970
24970
|
"data-testid": "settingsCard"
|
|
24971
24971
|
}, {
|
|
24972
24972
|
children: [jsxRuntime.jsxs("div", Object.assign({
|
|
24973
|
-
css: styles$
|
|
24973
|
+
css: styles$5.header
|
|
24974
24974
|
}, {
|
|
24975
24975
|
children: [jsxRuntime.jsxs("div", Object.assign({
|
|
24976
|
-
css: styles$
|
|
24976
|
+
css: styles$5.title
|
|
24977
24977
|
}, {
|
|
24978
24978
|
children: [typeof title === "string" ? jsxRuntime.jsx(giger.Typography, Object.assign({
|
|
24979
24979
|
variant: "subtitle2"
|
|
@@ -25008,7 +25008,7 @@ const SettingsCard = ({
|
|
|
25008
25008
|
}))
|
|
25009
25009
|
}))]
|
|
25010
25010
|
})), children && jsxRuntime.jsx("div", Object.assign({
|
|
25011
|
-
css: styles$
|
|
25011
|
+
css: styles$5.body
|
|
25012
25012
|
}, {
|
|
25013
25013
|
children: jsxRuntime.jsxs("div", {
|
|
25014
25014
|
children: [children, accessoryAction && jsxRuntime.jsx(ButtonGroup, Object.assign({
|
|
@@ -25085,7 +25085,9 @@ const WarehouseDisplay = ({
|
|
|
25085
25085
|
|
|
25086
25086
|
const postalCodeRegex$1 = /(^\d{5}$)|(^\d{5}-\d{4}$)/;
|
|
25087
25087
|
const warehouseAddressSchema = addressSchema.extend({
|
|
25088
|
-
addressResidentialIndicator: zod.z.preprocess(v => v === "yes" ? true : false, zod.z.boolean().default(false).transform(value => value ? "yes" : "no"))
|
|
25088
|
+
addressResidentialIndicator: zod.z.preprocess(v => v === "yes" ? true : false, zod.z.boolean().default(false).transform(value => value ? "yes" : "no")),
|
|
25089
|
+
companyName: zod.z.string().trim().min(1),
|
|
25090
|
+
phone: zod.z.string().trim().min(1)
|
|
25089
25091
|
}).refine(schema => !schema.phone || min$4.isValidPhoneNumber(schema.phone, schema.countryCode), {
|
|
25090
25092
|
message: "schemaErrors.notAValidPhoneNumber",
|
|
25091
25093
|
path: ["phone"]
|
|
@@ -25166,7 +25168,8 @@ const WarehouseForm = ({
|
|
|
25166
25168
|
nativeLabel: true
|
|
25167
25169
|
}), jsxRuntime.jsx(AddressFields, {
|
|
25168
25170
|
form: form,
|
|
25169
|
-
formatFieldName: fieldName => `originAddress.${fieldName}
|
|
25171
|
+
formatFieldName: fieldName => `originAddress.${fieldName}`,
|
|
25172
|
+
optionalFields: ["addressLine2"]
|
|
25170
25173
|
}), jsxRuntime.jsx(CheckboxInput, {
|
|
25171
25174
|
checkboxLabel: t("manage-warehouses:residentialAddress"),
|
|
25172
25175
|
control: form.control,
|
|
@@ -25191,6 +25194,7 @@ const WarehouseForm = ({
|
|
|
25191
25194
|
form.reset(formValues => Object.assign(Object.assign({}, formValues), {
|
|
25192
25195
|
returnAddress: Object.assign(Object.assign({}, {}), {
|
|
25193
25196
|
addressResidentialIndicator: false,
|
|
25197
|
+
companyName: "",
|
|
25194
25198
|
countryCode: "US"
|
|
25195
25199
|
}),
|
|
25196
25200
|
returnToAddressIsDifferent: true
|
|
@@ -25202,7 +25206,8 @@ const WarehouseForm = ({
|
|
|
25202
25206
|
}), form.watch("returnToAddressIsDifferent") && jsxRuntime.jsxs(jsxRuntime.Fragment, {
|
|
25203
25207
|
children: [jsxRuntime.jsx(AddressFields, {
|
|
25204
25208
|
form: form,
|
|
25205
|
-
formatFieldName: fieldName => `returnAddress.${fieldName}
|
|
25209
|
+
formatFieldName: fieldName => `returnAddress.${fieldName}`,
|
|
25210
|
+
optionalFields: ["addressLine2"]
|
|
25206
25211
|
}), jsxRuntime.jsx(CheckboxInput, {
|
|
25207
25212
|
checkboxLabel: t("manage-warehouses:residentialAddress"),
|
|
25208
25213
|
control: form.control,
|
|
@@ -25487,7 +25492,7 @@ const WarehousePreferenceWizard = ({
|
|
|
25487
25492
|
}));
|
|
25488
25493
|
};
|
|
25489
25494
|
|
|
25490
|
-
const styles$
|
|
25495
|
+
const styles$4 = createStyles({
|
|
25491
25496
|
cardSpacing: theme => ({
|
|
25492
25497
|
display: "flex",
|
|
25493
25498
|
flexDirection: "column",
|
|
@@ -25520,9 +25525,9 @@ const ManageWarehouses$1 = ({
|
|
|
25520
25525
|
const [showAddNewWarehouseForm, toggleShowAddNewWarehouseForm] = useToggle(false);
|
|
25521
25526
|
return jsxRuntime.jsxs(jsxRuntime.Fragment, {
|
|
25522
25527
|
children: [showAddNewWarehouseForm ? jsxRuntime.jsx(WarehousePreferenceWizard, {
|
|
25523
|
-
css: styles$
|
|
25528
|
+
css: styles$4.well,
|
|
25524
25529
|
formHeader: jsxRuntime.jsxs("div", Object.assign({
|
|
25525
|
-
css: styles$
|
|
25530
|
+
css: styles$4.header
|
|
25526
25531
|
}, {
|
|
25527
25532
|
children: [jsxRuntime.jsx(giger.Typography, Object.assign({
|
|
25528
25533
|
variant: "subtitle1"
|
|
@@ -25559,7 +25564,7 @@ const ManageWarehouses$1 = ({
|
|
|
25559
25564
|
})]
|
|
25560
25565
|
}))
|
|
25561
25566
|
})), jsxRuntime.jsx("div", Object.assign({
|
|
25562
|
-
css: styles$
|
|
25567
|
+
css: styles$4.cardSpacing
|
|
25563
25568
|
}, {
|
|
25564
25569
|
children: warehouses.sort((a, b) => {
|
|
25565
25570
|
if (b.isDefault) return 1;
|
|
@@ -25567,9 +25572,9 @@ const ManageWarehouses$1 = ({
|
|
|
25567
25572
|
}).map(warehouse => {
|
|
25568
25573
|
if (editWarehouseId && editWarehouseId === warehouse.warehouseId) {
|
|
25569
25574
|
return jsxRuntime.jsx(WarehousePreferenceWizard, {
|
|
25570
|
-
css: styles$
|
|
25575
|
+
css: styles$4.well,
|
|
25571
25576
|
formHeader: jsxRuntime.jsxs("div", Object.assign({
|
|
25572
|
-
css: styles$
|
|
25577
|
+
css: styles$4.header
|
|
25573
25578
|
}, {
|
|
25574
25579
|
children: [jsxRuntime.jsx(giger.Typography, Object.assign({
|
|
25575
25580
|
variant: "subtitle1"
|
|
@@ -26736,7 +26741,7 @@ const EditWalletAddressForm = ({
|
|
|
26736
26741
|
}));
|
|
26737
26742
|
};
|
|
26738
26743
|
|
|
26739
|
-
const styles$
|
|
26744
|
+
const styles$3 = createStyles({
|
|
26740
26745
|
grid: theme => ({
|
|
26741
26746
|
margin: theme.spacing(4)
|
|
26742
26747
|
}),
|
|
@@ -26788,21 +26793,21 @@ const WalletForm = ({
|
|
|
26788
26793
|
onSubmit: formLogger.capture(handleSubmit)
|
|
26789
26794
|
}, {
|
|
26790
26795
|
children: jsxRuntime.jsxs(giger.Grid, Object.assign({
|
|
26791
|
-
css: styles$
|
|
26796
|
+
css: styles$3.grid,
|
|
26792
26797
|
noPadding: true
|
|
26793
26798
|
}, {
|
|
26794
26799
|
children: [jsxRuntime.jsx(giger.GridChild, Object.assign({
|
|
26795
26800
|
colSpan: 12
|
|
26796
26801
|
}, {
|
|
26797
26802
|
children: jsxRuntime.jsx(giger.Typography, Object.assign({
|
|
26798
|
-
css: styles$
|
|
26803
|
+
css: styles$3.heading,
|
|
26799
26804
|
variant: "heading4"
|
|
26800
26805
|
}, {
|
|
26801
26806
|
children: t("register-wallet:sections.billing.title")
|
|
26802
26807
|
}))
|
|
26803
26808
|
})), jsxRuntime.jsx(giger.GridChild, Object.assign({
|
|
26804
26809
|
colSpan: 12,
|
|
26805
|
-
css: styles$
|
|
26810
|
+
css: styles$3.subtitle
|
|
26806
26811
|
}, {
|
|
26807
26812
|
children: jsxRuntime.jsx(giger.Typography, Object.assign({
|
|
26808
26813
|
variant: "subtitle1"
|
|
@@ -26835,7 +26840,7 @@ const WalletForm = ({
|
|
|
26835
26840
|
colSpan: 12
|
|
26836
26841
|
}, {
|
|
26837
26842
|
children: jsxRuntime.jsx(giger.Typography, Object.assign({
|
|
26838
|
-
css: styles$
|
|
26843
|
+
css: styles$3.subtitle,
|
|
26839
26844
|
variant: "subtitle1"
|
|
26840
26845
|
}, {
|
|
26841
26846
|
children: t("register-wallet:sections.billing.addressSubTitle")
|
|
@@ -26891,7 +26896,7 @@ const WalletForm = ({
|
|
|
26891
26896
|
}));
|
|
26892
26897
|
};
|
|
26893
26898
|
|
|
26894
|
-
const styles$
|
|
26899
|
+
const styles$2 = createStyles({
|
|
26895
26900
|
step: {
|
|
26896
26901
|
"& > span:last-child": {
|
|
26897
26902
|
position: "static"
|
|
@@ -26909,6 +26914,9 @@ const Onboarding$1 = ({
|
|
|
26909
26914
|
createWarehouse,
|
|
26910
26915
|
onCarrierCreated,
|
|
26911
26916
|
onWarehouseCreated,
|
|
26917
|
+
onValidateWarehouse,
|
|
26918
|
+
warehousePreference,
|
|
26919
|
+
setWarehousePreference,
|
|
26912
26920
|
onCompleteOnboarding,
|
|
26913
26921
|
registerDhlCarrier,
|
|
26914
26922
|
registerDhlCarrierErrors,
|
|
@@ -26916,7 +26924,8 @@ const Onboarding$1 = ({
|
|
|
26916
26924
|
registerStampsCarrierErrors,
|
|
26917
26925
|
registerUpsCarrier,
|
|
26918
26926
|
registerUpsCarrierErrors,
|
|
26919
|
-
warehouses
|
|
26927
|
+
warehouses,
|
|
26928
|
+
validationErrors
|
|
26920
26929
|
}) => {
|
|
26921
26930
|
const {
|
|
26922
26931
|
t
|
|
@@ -26969,6 +26978,7 @@ const Onboarding$1 = ({
|
|
|
26969
26978
|
const handleCreateWarehouse = payload => __awaiter(void 0, void 0, void 0, function* () {
|
|
26970
26979
|
const result = yield createWarehouse(payload);
|
|
26971
26980
|
if (result) yield onWarehouseCreated();
|
|
26981
|
+
setHasValidAddress(true);
|
|
26972
26982
|
});
|
|
26973
26983
|
const handleWalletRegistration = ({
|
|
26974
26984
|
address,
|
|
@@ -27014,14 +27024,34 @@ const Onboarding$1 = ({
|
|
|
27014
27024
|
}
|
|
27015
27025
|
if (agreedToTerms && !warehouses.length && !hasValidAddress) {
|
|
27016
27026
|
// Step 3: Add Ship From (Warehouse) Address
|
|
27017
|
-
return jsxRuntime.jsx(
|
|
27027
|
+
return jsxRuntime.jsx(WarehousePreferenceWizard, {
|
|
27028
|
+
formHeader: jsxRuntime.jsxs("div", Object.assign({
|
|
27029
|
+
css: {
|
|
27030
|
+
textAlign: "center"
|
|
27031
|
+
}
|
|
27032
|
+
}, {
|
|
27033
|
+
children: [jsxRuntime.jsx(giger.Typography, Object.assign({
|
|
27034
|
+
variant: "heading4"
|
|
27035
|
+
}, {
|
|
27036
|
+
children: t("onboarding:warehouse.title")
|
|
27037
|
+
})), jsxRuntime.jsx(Spacer, {
|
|
27038
|
+
multiplier: 2
|
|
27039
|
+
}), jsxRuntime.jsx(giger.Typography, Object.assign({
|
|
27040
|
+
variant: "subtitle1"
|
|
27041
|
+
}, {
|
|
27042
|
+
children: t("onboarding:warehouse.subtitle")
|
|
27043
|
+
})), jsxRuntime.jsx(Spacer, {
|
|
27044
|
+
multiplier: 1
|
|
27045
|
+
})]
|
|
27046
|
+
})),
|
|
27018
27047
|
isOnboarding: true,
|
|
27019
27048
|
onSubmit: payload => {
|
|
27020
27049
|
handleCreateWarehouse(payload);
|
|
27021
|
-
|
|
27022
|
-
// Step 3.1: TODO: LMNT-815 Validate Address
|
|
27050
|
+
setWarehousePreference(undefined);
|
|
27023
27051
|
},
|
|
27024
|
-
|
|
27052
|
+
onValidate: onValidateWarehouse,
|
|
27053
|
+
submitButtonTitle: t("actions.continue"),
|
|
27054
|
+
warehousePreference: warehousePreference
|
|
27025
27055
|
});
|
|
27026
27056
|
}
|
|
27027
27057
|
// Step 4: Register Stamps Wallet, UPS, DHL
|
|
@@ -27061,22 +27091,22 @@ const Onboarding$1 = ({
|
|
|
27061
27091
|
return jsxRuntime.jsx(Loader, {});
|
|
27062
27092
|
};
|
|
27063
27093
|
return jsxRuntime.jsxs("div", Object.assign({
|
|
27064
|
-
css: styles$
|
|
27094
|
+
css: styles$2.wrapper
|
|
27065
27095
|
}, {
|
|
27066
27096
|
children: [jsxRuntime.jsxs(giger.Stepper, Object.assign({
|
|
27067
27097
|
currentStep: currentStep
|
|
27068
27098
|
}, {
|
|
27069
27099
|
children: [jsxRuntime.jsx(giger.Step, {
|
|
27070
|
-
css: styles$
|
|
27100
|
+
css: styles$2.step,
|
|
27071
27101
|
label: t("onboarding:steps.login")
|
|
27072
27102
|
}), jsxRuntime.jsx(giger.Step, {
|
|
27073
|
-
css: styles$
|
|
27103
|
+
css: styles$2.step,
|
|
27074
27104
|
label: t("onboarding:steps.carriers")
|
|
27075
27105
|
}), jsxRuntime.jsx(giger.Step, {
|
|
27076
|
-
css: styles$
|
|
27106
|
+
css: styles$2.step,
|
|
27077
27107
|
label: t("onboarding:steps.addresses")
|
|
27078
27108
|
}), jsxRuntime.jsx(giger.Step, {
|
|
27079
|
-
css: styles$
|
|
27109
|
+
css: styles$2.step,
|
|
27080
27110
|
label: t("onboarding:steps.payment")
|
|
27081
27111
|
})]
|
|
27082
27112
|
})), renderStep()]
|
|
@@ -27696,7 +27726,7 @@ const FundAndPurchase = ({
|
|
|
27696
27726
|
}));
|
|
27697
27727
|
};
|
|
27698
27728
|
|
|
27699
|
-
const styles = createStyles({
|
|
27729
|
+
const styles$1 = createStyles({
|
|
27700
27730
|
fundAndPurchase: theme => ({
|
|
27701
27731
|
borderTop: `1px solid ${theme.palette.gray.ultraLight}`
|
|
27702
27732
|
}),
|
|
@@ -27847,7 +27877,7 @@ const RateForm = ({
|
|
|
27847
27877
|
onClick: onSelectRate,
|
|
27848
27878
|
options: showHiddenRates ? rateOptions : filteredRateOptions
|
|
27849
27879
|
}), rateOptions.some(option => option.requiresAcknowledgement) && rateOptions.length > 5 && jsxRuntime.jsx(giger.Link, Object.assign({
|
|
27850
|
-
css: styles.showMoreOrLessRatesButton,
|
|
27880
|
+
css: styles$1.showMoreOrLessRatesButton,
|
|
27851
27881
|
onClick: () => {
|
|
27852
27882
|
var _a;
|
|
27853
27883
|
setShowHiddenRates(!showHiddenRates);
|
|
@@ -27868,7 +27898,7 @@ const RateForm = ({
|
|
|
27868
27898
|
}))
|
|
27869
27899
|
}))]
|
|
27870
27900
|
}) : !isLoading && errors && !!errors.length ? null : jsxRuntime.jsxs("article", Object.assign({
|
|
27871
|
-
css: styles.ratesInterstitial,
|
|
27901
|
+
css: styles$1.ratesInterstitial,
|
|
27872
27902
|
role: "presentation"
|
|
27873
27903
|
}, {
|
|
27874
27904
|
children: [jsxRuntime.jsx(Cube, {
|
|
@@ -27889,7 +27919,7 @@ const RateForm = ({
|
|
|
27889
27919
|
})), jsxRuntime.jsx(FundAndPurchase, {
|
|
27890
27920
|
carrierId: selectedRate === null || selectedRate === void 0 ? void 0 : selectedRate.carrierId,
|
|
27891
27921
|
control: form.control,
|
|
27892
|
-
css: styles.fundAndPurchase,
|
|
27922
|
+
css: styles$1.fundAndPurchase,
|
|
27893
27923
|
disabled: disabled,
|
|
27894
27924
|
isFundingEnabled: features === null || features === void 0 ? void 0 : features.enableFunding,
|
|
27895
27925
|
isFundingRequired: (selectedRate === null || selectedRate === void 0 ? void 0 : selectedRate.balance) !== undefined && !!selectedRate.requiresFundedAmount,
|
|
@@ -29345,6 +29375,110 @@ const SuspendShipment = ({
|
|
|
29345
29375
|
}));
|
|
29346
29376
|
};
|
|
29347
29377
|
|
|
29378
|
+
const styles = createStyles({
|
|
29379
|
+
dateRangeInput: theme => ({
|
|
29380
|
+
width: theme.spacing(30)
|
|
29381
|
+
})
|
|
29382
|
+
});
|
|
29383
|
+
|
|
29384
|
+
const HistoryActions = () => {
|
|
29385
|
+
const {
|
|
29386
|
+
t
|
|
29387
|
+
} = reactI18next.useTranslation();
|
|
29388
|
+
const selectOptions = React.useMemo(() => [{
|
|
29389
|
+
label: t("wallet-history:historyOptions.custom"),
|
|
29390
|
+
value: t("wallet-history:historyOptions.custom")
|
|
29391
|
+
}, {
|
|
29392
|
+
label: t("wallet-history:historyOptions.last30days"),
|
|
29393
|
+
value: t("wallet-history:historyOptions.last30days")
|
|
29394
|
+
}, {
|
|
29395
|
+
label: t("wallet-history:historyOptions.thisMonth"),
|
|
29396
|
+
value: t("wallet-history:historyOptions.thisMonth")
|
|
29397
|
+
}, {
|
|
29398
|
+
label: t("wallet-history:historyOptions.lastMonth"),
|
|
29399
|
+
value: t("wallet-history:historyOptions.lastMonth")
|
|
29400
|
+
}], [t]);
|
|
29401
|
+
const [selectValue, setSelectValue] = React.useState();
|
|
29402
|
+
return jsxRuntime.jsxs(Spread, {
|
|
29403
|
+
children: [jsxRuntime.jsx(giger.Select, Object.assign({
|
|
29404
|
+
css: styles.dateRangeInput,
|
|
29405
|
+
label: "Date range",
|
|
29406
|
+
leftContent: jsxRuntime.jsx(giger.Icon, {
|
|
29407
|
+
name: brands.IconNames.FILTER
|
|
29408
|
+
}),
|
|
29409
|
+
name: "date-range-select",
|
|
29410
|
+
onChange: newValue => setSelectValue(newValue),
|
|
29411
|
+
onClear: c => console.log("SELECT ON CLEAR CALLBACK:", c)
|
|
29412
|
+
}, {
|
|
29413
|
+
children: selectOptions.map(item => jsxRuntime.jsx(giger.Option, Object.assign({
|
|
29414
|
+
value: item.value
|
|
29415
|
+
}, {
|
|
29416
|
+
children: item.label
|
|
29417
|
+
}), item.value))
|
|
29418
|
+
})), jsxRuntime.jsx(LinkAction, {
|
|
29419
|
+
onClick: x => console.log("Downloaded a CSV!", x),
|
|
29420
|
+
title: t("wallet-history:actions.downloadCsv")
|
|
29421
|
+
})]
|
|
29422
|
+
});
|
|
29423
|
+
};
|
|
29424
|
+
|
|
29425
|
+
const HistoryRow = ({
|
|
29426
|
+
key,
|
|
29427
|
+
rowItem
|
|
29428
|
+
}) => jsxRuntime.jsx("div", {
|
|
29429
|
+
children: "History Row Component"
|
|
29430
|
+
});
|
|
29431
|
+
|
|
29432
|
+
/**
|
|
29433
|
+
* This component is the list of events that represent the history of a
|
|
29434
|
+
* specific entity. The events are displayed in reverse chronological order.
|
|
29435
|
+
*
|
|
29436
|
+
* @param historyData The history data to display.
|
|
29437
|
+
*/
|
|
29438
|
+
const HistoryList = ({
|
|
29439
|
+
historyData
|
|
29440
|
+
}) => {
|
|
29441
|
+
console.table(historyData);
|
|
29442
|
+
return jsxRuntime.jsx(jsxRuntime.Fragment, {
|
|
29443
|
+
children: [1, 2, 3].map((item, idx) => {
|
|
29444
|
+
return jsxRuntime.jsx(HistoryRow, {
|
|
29445
|
+
rowItem: item
|
|
29446
|
+
}, idx);
|
|
29447
|
+
})
|
|
29448
|
+
});
|
|
29449
|
+
};
|
|
29450
|
+
|
|
29451
|
+
const HistoryBody = ({
|
|
29452
|
+
historyData
|
|
29453
|
+
}) => {
|
|
29454
|
+
const [page, setPage] = React.useState(1);
|
|
29455
|
+
return jsxRuntime.jsxs(jsxRuntime.Fragment, {
|
|
29456
|
+
children: [jsxRuntime.jsx(HistoryActions, {}), jsxRuntime.jsx(HistoryList, {
|
|
29457
|
+
historyData: historyData
|
|
29458
|
+
}), jsxRuntime.jsxs(jsxRuntime.Fragment, {
|
|
29459
|
+
children: [jsxRuntime.jsxs("p", {
|
|
29460
|
+
children: ["Page ", jsxRuntime.jsx("strong", {
|
|
29461
|
+
children: page
|
|
29462
|
+
}), " selected."]
|
|
29463
|
+
}), jsxRuntime.jsx(giger.Pagination, {
|
|
29464
|
+
boundaryPagesToShow: 7,
|
|
29465
|
+
currentPage: page,
|
|
29466
|
+
onPageChange: selectedPage => setPage(selectedPage),
|
|
29467
|
+
siblingCount: 2,
|
|
29468
|
+
totalPages: 20
|
|
29469
|
+
})]
|
|
29470
|
+
})]
|
|
29471
|
+
});
|
|
29472
|
+
};
|
|
29473
|
+
|
|
29474
|
+
const WalletHistory$1 = ({
|
|
29475
|
+
historyData
|
|
29476
|
+
}) => {
|
|
29477
|
+
return jsxRuntime.jsx(HistoryBody, {
|
|
29478
|
+
historyData: historyData
|
|
29479
|
+
});
|
|
29480
|
+
};
|
|
29481
|
+
|
|
29348
29482
|
const VoidLabel$1 = ({
|
|
29349
29483
|
onComplete,
|
|
29350
29484
|
onSubmit,
|
|
@@ -29486,10 +29620,11 @@ var index$1 = /*#__PURE__*/Object.freeze({
|
|
|
29486
29620
|
schedulePickupForCarrier: schedulePickupForCarrier,
|
|
29487
29621
|
Shipment: Shipment$1,
|
|
29488
29622
|
SuspendShipment: SuspendShipment,
|
|
29623
|
+
WalletHistory: WalletHistory$1,
|
|
29489
29624
|
WarehouseForm: WarehouseForm,
|
|
29490
29625
|
VoidLabel: VoidLabel$1,
|
|
29491
29626
|
WalletForm: WalletForm,
|
|
29492
|
-
styles: styles$
|
|
29627
|
+
styles: styles$3,
|
|
29493
29628
|
billingAddressSchema: billingAddressSchema,
|
|
29494
29629
|
walletSchema: walletSchema,
|
|
29495
29630
|
BillingFields: BillingFields,
|
|
@@ -31275,7 +31410,21 @@ var voidLabel = {
|
|
|
31275
31410
|
}
|
|
31276
31411
|
};
|
|
31277
31412
|
|
|
31278
|
-
var
|
|
31413
|
+
var walletHistory = {
|
|
31414
|
+
"wallet-history": {
|
|
31415
|
+
actions: {
|
|
31416
|
+
downloadCsv: "Download a CSV"
|
|
31417
|
+
},
|
|
31418
|
+
historyOptions: {
|
|
31419
|
+
custom: "Custom",
|
|
31420
|
+
last30days: "Last 30 days",
|
|
31421
|
+
thisMonth: "This month",
|
|
31422
|
+
lastMonth: "Last month"
|
|
31423
|
+
}
|
|
31424
|
+
}
|
|
31425
|
+
};
|
|
31426
|
+
|
|
31427
|
+
var index = Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({}, common$1), listCarriers), manageFunding), manageWarehouses), onboarding$1), purchaseLabel), registerCarrier), registerWallet), viewShipment), voidLabel), walletHistory);
|
|
31279
31428
|
|
|
31280
31429
|
var resources = /*#__PURE__*/Object.freeze({
|
|
31281
31430
|
__proto__: null,
|
|
@@ -31545,7 +31694,7 @@ const ListCarriers = () => {
|
|
|
31545
31694
|
});
|
|
31546
31695
|
};
|
|
31547
31696
|
|
|
31548
|
-
const Element$
|
|
31697
|
+
const Element$6 = registerElement("list-carriers", ListCarriers);
|
|
31549
31698
|
|
|
31550
31699
|
const ManageWarehouses = ({
|
|
31551
31700
|
onWarehouseAddressValidation
|
|
@@ -31624,7 +31773,7 @@ const ManageWarehouses = ({
|
|
|
31624
31773
|
});
|
|
31625
31774
|
};
|
|
31626
31775
|
|
|
31627
|
-
const Element$
|
|
31776
|
+
const Element$5 = registerElement("manage-warehouses", ManageWarehouses);
|
|
31628
31777
|
|
|
31629
31778
|
const useAddress = ({
|
|
31630
31779
|
compatibleCountryCodes,
|
|
@@ -32257,6 +32406,12 @@ const Onboarding = ({
|
|
|
32257
32406
|
const onWarehouseCreated = React.useCallback(() => __awaiter(void 0, void 0, void 0, function* () {
|
|
32258
32407
|
yield refetchWarehouses();
|
|
32259
32408
|
}), [refetchWarehouses]);
|
|
32409
|
+
const {
|
|
32410
|
+
errors: validateWarehouseErrors,
|
|
32411
|
+
validate: validateWarehouse,
|
|
32412
|
+
warehousePreference,
|
|
32413
|
+
setWarehousePreference
|
|
32414
|
+
} = useWarehouseValidation();
|
|
32260
32415
|
const onCarrierCreated = React.useCallback(() => __awaiter(void 0, void 0, void 0, function* () {
|
|
32261
32416
|
yield refetchCarriers();
|
|
32262
32417
|
}), [refetchCarriers]);
|
|
@@ -32267,6 +32422,7 @@ const Onboarding = ({
|
|
|
32267
32422
|
createWarehouse: createWarehouse,
|
|
32268
32423
|
onCarrierCreated: onCarrierCreated,
|
|
32269
32424
|
onCompleteOnboarding: onCompleteOnboarding,
|
|
32425
|
+
onValidateWarehouse: validateWarehouse,
|
|
32270
32426
|
onWarehouseCreated: onWarehouseCreated,
|
|
32271
32427
|
registerDhlCarrier: registerDhlCarrier,
|
|
32272
32428
|
registerDhlCarrierErrors: registerDhlCarrierErrors,
|
|
@@ -32274,6 +32430,9 @@ const Onboarding = ({
|
|
|
32274
32430
|
registerStampsCarrierErrors: registerStampsCarrierErrors,
|
|
32275
32431
|
registerUpsCarrier: registerUpsCarrier,
|
|
32276
32432
|
registerUpsCarrierErrors: registerUpsCarrierErrors,
|
|
32433
|
+
setWarehousePreference: setWarehousePreference,
|
|
32434
|
+
validationErrors: validateWarehouseErrors,
|
|
32435
|
+
warehousePreference: warehousePreference,
|
|
32277
32436
|
warehouses: warehouses
|
|
32278
32437
|
});
|
|
32279
32438
|
};
|
|
@@ -32399,7 +32558,7 @@ const useImportSalesOrder = ({
|
|
|
32399
32558
|
error: getSalesOrderErrors,
|
|
32400
32559
|
refetch: refetchSalesOrder,
|
|
32401
32560
|
isFetching: isFetchingSalesOrder
|
|
32402
|
-
} = react.useGetSalesOrder(salesOrderId !== null && salesOrderId !== void 0 ? salesOrderId : salesOrders
|
|
32561
|
+
} = react.useGetSalesOrder(salesOrderId !== null && salesOrderId !== void 0 ? salesOrderId : salesOrders && salesOrders[0] ? salesOrders[0].salesOrderId : undefined);
|
|
32403
32562
|
const {
|
|
32404
32563
|
data: orderSources,
|
|
32405
32564
|
error: listOrderSourcesErrors
|
|
@@ -32407,6 +32566,7 @@ const useImportSalesOrder = ({
|
|
|
32407
32566
|
const {
|
|
32408
32567
|
data: refreshedOrderSource,
|
|
32409
32568
|
error: refreshOrderSourceErrors,
|
|
32569
|
+
isLoading: isRefreshingOrderSource,
|
|
32410
32570
|
mutateAsync: refreshOrderSource
|
|
32411
32571
|
} = react.useRefreshOrderSource();
|
|
32412
32572
|
React.useEffect(() => {
|
|
@@ -32426,7 +32586,7 @@ const useImportSalesOrder = ({
|
|
|
32426
32586
|
const errors = [...(listOrderSourcesErrors !== null && listOrderSourcesErrors !== void 0 ? listOrderSourcesErrors : []), ...(listSalesOrdersErrors !== null && listSalesOrdersErrors !== void 0 ? listSalesOrdersErrors : []), ...(getSalesOrderErrors !== null && getSalesOrderErrors !== void 0 ? getSalesOrderErrors : []), ...(refreshOrderSourceErrors !== null && refreshOrderSourceErrors !== void 0 ? refreshOrderSourceErrors : [])];
|
|
32427
32587
|
return {
|
|
32428
32588
|
errors: errors.length > 0 ? errors : undefined,
|
|
32429
|
-
isLoading: !
|
|
32589
|
+
isLoading: isFetchingSalesOrder || isFetchingSalesOrders || isRefreshingOrderSource || !hasRefreshedOrderSource && !salesOrder && (salesOrders === null || salesOrders === void 0 ? void 0 : salesOrders.length) === 0 && errors.length === 0,
|
|
32430
32590
|
salesOrder
|
|
32431
32591
|
};
|
|
32432
32592
|
};
|
|
@@ -32584,6 +32744,13 @@ const Shipment = ({
|
|
|
32584
32744
|
});
|
|
32585
32745
|
};
|
|
32586
32746
|
|
|
32747
|
+
const WalletHistory = () => {
|
|
32748
|
+
const walletHistory = react.useGetWalletTransactionHistory(); // Mock data for now. Real implementation coming in a subsequent PR [LMNT-842] https://auctane.atlassian.net/browse/LMNT-842
|
|
32749
|
+
return jsxRuntime.jsx(WalletHistory$1, {
|
|
32750
|
+
historyData: walletHistory
|
|
32751
|
+
});
|
|
32752
|
+
};
|
|
32753
|
+
|
|
32587
32754
|
const VoidLabel = ({
|
|
32588
32755
|
labelId,
|
|
32589
32756
|
onComplete,
|
|
@@ -32612,9 +32779,11 @@ const VoidLabel = ({
|
|
|
32612
32779
|
});
|
|
32613
32780
|
};
|
|
32614
32781
|
|
|
32615
|
-
const Element$
|
|
32782
|
+
const Element$4 = registerElement("purchase-label", PurchaseLabel);
|
|
32783
|
+
|
|
32784
|
+
const Element$3 = registerElement("onboarding", Onboarding);
|
|
32616
32785
|
|
|
32617
|
-
const Element$2 = registerElement("
|
|
32786
|
+
const Element$2 = registerElement("wallet-history", WalletHistory);
|
|
32618
32787
|
|
|
32619
32788
|
const Element$1 = registerElement("view-shipment", Shipment);
|
|
32620
32789
|
|
|
@@ -32639,14 +32808,14 @@ exports.GigerProvider = GigerProvider;
|
|
|
32639
32808
|
exports.InlineLabel = InlineLabel;
|
|
32640
32809
|
exports.ItemsBreakdown = ItemsBreakdown;
|
|
32641
32810
|
exports.LinkAction = LinkAction;
|
|
32642
|
-
exports.ListCarriers = Element$
|
|
32811
|
+
exports.ListCarriers = Element$6;
|
|
32643
32812
|
exports.Loader = Loader;
|
|
32644
32813
|
exports.ManageFunding = ManageFunding;
|
|
32645
|
-
exports.ManageWarehouses = Element$
|
|
32646
|
-
exports.Onboarding = Element$
|
|
32814
|
+
exports.ManageWarehouses = Element$5;
|
|
32815
|
+
exports.Onboarding = Element$3;
|
|
32647
32816
|
exports.PageLayoutProvider = PageLayoutProvider;
|
|
32648
32817
|
exports.Portal = Portal;
|
|
32649
|
-
exports.PurchaseLabel = Element$
|
|
32818
|
+
exports.PurchaseLabel = Element$4;
|
|
32650
32819
|
exports.RootPortalProvider = RootPortalProvider;
|
|
32651
32820
|
exports.Spacer = Spacer;
|
|
32652
32821
|
exports.Spread = Spread;
|
|
@@ -32656,6 +32825,7 @@ exports.UsState = UsState;
|
|
|
32656
32825
|
exports.UsaCity = UsaCity;
|
|
32657
32826
|
exports.ViewShipment = Element$1;
|
|
32658
32827
|
exports.VoidLabel = Element;
|
|
32828
|
+
exports.WalletHistory = Element$2;
|
|
32659
32829
|
exports.autoFundingSchema = autoFundingSchema;
|
|
32660
32830
|
exports.calculateTotal = calculateTotal;
|
|
32661
32831
|
exports.capitalizeFirstLetter = capitalizeFirstLetter;
|