@shipengine/elements 0.20.2 → 0.21.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.
Files changed (139) hide show
  1. package/index.cjs +1065 -1052
  2. package/index.js +935 -922
  3. package/package.json +3 -3
  4. package/src/components/add-funds-form/add-funds-schema.d.ts +7 -7
  5. package/src/components/address-preference-context/address-preference-context.d.ts +42 -0
  6. package/src/components/address-preference-context/index.d.ts +1 -0
  7. package/src/components/auto-funding-form/auto-funding-schema.d.ts +10 -10
  8. package/src/components/field/fields.d.ts +2 -1
  9. package/src/components/field/money-input/hooks/use-utils.d.ts +1 -1
  10. package/src/components/field/money-input/money-input.d.ts +1 -1
  11. package/src/components/field/rate-card/cost-breakdown/cost-breakdown.d.ts +1 -1
  12. package/src/components/field/select-auto-complete/index.d.ts +1 -0
  13. package/src/components/field/select-auto-complete/select-auto-complete.d.ts +7 -0
  14. package/src/components/history/history-card/history-card.d.ts +5 -0
  15. package/src/components/history/history-card/history-card.styles.d.ts +1 -0
  16. package/src/components/history/history-card/index.d.ts +1 -0
  17. package/src/components/history/index.d.ts +1 -4
  18. package/src/components/index.d.ts +1 -1
  19. package/src/components/inline-label/inline-label.d.ts +5 -1
  20. package/src/components/inline-label/inline-label.styles.d.ts +1 -0
  21. package/src/components/items-breakdown/items-breakdown.d.ts +1 -1
  22. package/src/components/label/index.d.ts +1 -0
  23. package/src/components/label/label.d.ts +10 -0
  24. package/src/components/label/label.styles.d.ts +2 -0
  25. package/src/components/label-layout/label-layout-purchase.d.ts +1 -1
  26. package/src/components/label-layout/label-layout-settings.d.ts +1 -1
  27. package/src/components/section/index.d.ts +1 -0
  28. package/src/components/section/section.d.ts +10 -0
  29. package/src/components/section/section.styles.d.ts +1 -0
  30. package/src/components/templates/add-carrier-form/add-carrier-form.d.ts +1 -1
  31. package/src/components/templates/address-display/address-display.d.ts +1 -1
  32. package/src/components/templates/address-form/address-form.d.ts +1 -1
  33. package/src/components/templates/address-preference-display/address-preference-display.d.ts +1 -1
  34. package/src/components/templates/address-preference-select/address-preference-select.d.ts +24 -0
  35. package/src/components/templates/address-preference-select/index.d.ts +1 -0
  36. package/src/components/templates/carrier-recovery-form/carrier-recovery-form.d.ts +1 -1
  37. package/src/components/templates/carrier-terms-form/carrier-terms-form.d.ts +1 -1
  38. package/src/components/templates/customs-item-form/customs-item-form-schema.d.ts +20 -20
  39. package/src/components/templates/customs-item-form/customs-item-form.d.ts +1 -1
  40. package/src/components/templates/customs-items-display/customs-items-display.d.ts +1 -1
  41. package/src/components/templates/edit-billing-form/edit-billing-form.styles.d.ts +1 -1
  42. package/src/components/templates/index.d.ts +2 -3
  43. package/src/components/templates/label/label.d.ts +1 -1
  44. package/src/components/templates/list-carriers/list-carriers.d.ts +1 -1
  45. package/src/components/templates/list-carriers-row/list-carriers-row.d.ts +1 -1
  46. package/src/components/templates/manage-wallet/manage-wallet.styles.d.ts +1 -1
  47. package/src/components/templates/manage-warehouses/manage-warehouses.d.ts +2 -6
  48. package/src/components/templates/onboarding/onboarding.d.ts +14 -8
  49. package/src/components/templates/onboarding/onboarding.styles.d.ts +1 -1
  50. package/src/components/templates/rate-form/rate-form.d.ts +1 -1
  51. package/src/components/templates/shipment/shipment.d.ts +1 -1
  52. package/src/components/templates/shipment-form/shipment-form.d.ts +1 -1
  53. package/src/components/templates/shipment-form/shipment-schema.d.ts +26 -2
  54. package/src/components/templates/suspend-sales-order/suspend-sales-order.d.ts +1 -1
  55. package/src/components/templates/suspend-shipment/suspend-shipment.d.ts +1 -1
  56. package/src/components/templates/void-label/void-label.d.ts +1 -1
  57. package/src/components/templates/wallet-form/edit-wallet-address-form.d.ts +1 -1
  58. package/src/components/templates/wallet-form/wallet-form.d.ts +7 -6
  59. package/src/components/templates/wallet-form/wallet-form.styles.d.ts +1 -1
  60. package/src/components/templates/wallet-form/wallet-schema.d.ts +1 -1
  61. package/src/components/templates/warehouse-display/warehouse-display.d.ts +1 -1
  62. package/src/components/templates/warehouse-form/warehouse-form.d.ts +1 -1
  63. package/src/elements/components/configure-shipment/configure-shipment.d.ts +1 -1
  64. package/src/elements/components/configure-shipment/hooks/use-address.d.ts +1 -1
  65. package/src/elements/components/configure-shipment/hooks/use-customs.d.ts +1 -1
  66. package/src/elements/components/configure-shipment/hooks/use-presets.d.ts +1 -1
  67. package/src/elements/components/configure-shipment/hooks/use-rates-form.d.ts +1 -1
  68. package/src/elements/components/configure-shipment/hooks/use-request-rates.d.ts +1 -1
  69. package/src/elements/components/configure-shipment/hooks/use-shipment-form.d.ts +1 -1
  70. package/src/elements/components/index.d.ts +0 -1
  71. package/src/elements/components/list-carriers/hooks/use-list-connected-carriers.d.ts +2 -2
  72. package/src/elements/components/purchase-label/hooks/use-configure-shipment.d.ts +1 -1
  73. package/src/elements/components/purchase-label/hooks/use-import-sales-order.d.ts +2 -2
  74. package/src/elements/components/purchase-label/hooks/use-load-shipment.d.ts +3 -3
  75. package/src/elements/components/purchase-label/hooks/use-pending-shipment.d.ts +1 -1
  76. package/src/elements/components/shipment/shipment.d.ts +1 -1
  77. package/src/elements/components/void-label/void-label.d.ts +1 -1
  78. package/src/elements/index.d.ts +0 -1
  79. package/src/factories/shipengine/address.d.ts +8 -1
  80. package/src/factories/shipengine/carrier.d.ts +1 -1
  81. package/src/factories/shipengine/label.d.ts +1 -1
  82. package/src/factories/shipengine/money.d.ts +1 -1
  83. package/src/factories/shipengine/order-source.d.ts +1 -1
  84. package/src/factories/shipengine/package.d.ts +1 -1
  85. package/src/factories/shipengine/resource.d.ts +1 -1
  86. package/src/factories/shipengine/sales-order.d.ts +1 -1
  87. package/src/factories/shipengine/service.d.ts +1 -1
  88. package/src/factories/shipengine/shipment.d.ts +1 -1
  89. package/src/factories/shipengine/wallet-history.d.ts +1 -1
  90. package/src/factories/shipengine/warehouse.d.ts +1 -3
  91. package/src/factories/shipengine/weight.d.ts +1 -1
  92. package/src/features/wallet-history/wallet-history.styles.d.ts +1 -0
  93. package/src/hooks/index.d.ts +1 -1
  94. package/src/hooks/options/use-confirmation-options.d.ts +1 -1
  95. package/src/hooks/options/use-customs-contents-options.d.ts +1 -1
  96. package/src/hooks/options/use-customs-non-delivery-options.d.ts +1 -1
  97. package/src/hooks/options/use-insurance-provider-options.d.ts +1 -1
  98. package/src/hooks/options/use-package-options.d.ts +1 -1
  99. package/src/hooks/options/use-rate-options.d.ts +1 -1
  100. package/src/hooks/options/use-service-code-options.d.ts +1 -1
  101. package/src/hooks/options/use-warehouse-options.d.ts +1 -1
  102. package/src/hooks/use-address-validation.d.ts +12 -0
  103. package/src/hooks/use-carrier-metadata.d.ts +1 -1
  104. package/src/hooks/use-elements.d.ts +2 -2
  105. package/src/hooks/use-scrub-errors.d.ts +1 -1
  106. package/src/locales/en/index.d.ts +13 -2
  107. package/src/mocks/carriers/handlers.d.ts +1 -1
  108. package/src/mocks/warehouses/handlers.d.ts +1 -1
  109. package/src/schemas/shipengine/money.d.ts +1 -1
  110. package/src/types/carrier-metadata.d.ts +1 -1
  111. package/src/types/shipping-preset/shipping-preset.d.ts +1 -1
  112. package/src/utilities/money.d.ts +1 -1
  113. package/src/utilities/rates.d.ts +2 -1
  114. package/src/utilities/shipengine/address.d.ts +1 -1
  115. package/src/utilities/shipengine/dimensions.d.ts +1 -1
  116. package/src/utilities/shipengine/sales-order.d.ts +1 -1
  117. package/src/utilities/shipengine/shipment.d.ts +1 -1
  118. package/src/utilities/shipengine/weight.d.ts +1 -1
  119. package/src/components/accordion/accordion.d.ts +0 -13
  120. package/src/components/accordion/accordion.styles.d.ts +0 -7
  121. package/src/components/accordion/index.d.ts +0 -1
  122. package/src/components/history/history-body/history-body.d.ts +0 -5
  123. package/src/components/history/history-body/history-body.styles.d.ts +0 -1
  124. package/src/components/history/history-body/index.d.ts +0 -1
  125. package/src/components/history/history-list/history-list.d.ts +0 -12
  126. package/src/components/history/history-list/index.d.ts +0 -1
  127. package/src/components/history/history-row/history-row.d.ts +0 -6
  128. package/src/components/history/history-row/index.d.ts +0 -1
  129. package/src/components/history/history.d.ts +0 -10
  130. package/src/components/templates/wallet-history/wallet-history.d.ts +0 -6
  131. package/src/components/templates/warehouse-preference-select/index.d.ts +0 -1
  132. package/src/components/templates/warehouse-preference-select/warehouse-preference-select.d.ts +0 -24
  133. package/src/components/templates/warehouse-preference-wizard/index.d.ts +0 -1
  134. package/src/components/templates/warehouse-preference-wizard/warehouse-preference-wizard.d.ts +0 -23
  135. package/src/elements/wallet-history.d.ts +0 -1
  136. package/src/hooks/use-warehouse-validation.d.ts +0 -14
  137. /package/src/{components/templates/wallet-history → features}/index.d.ts +0 -0
  138. /package/src/{elements/components → features}/wallet-history/index.d.ts +0 -0
  139. /package/src/{elements/components → features}/wallet-history/wallet-history.d.ts +0 -0
@@ -1 +1 @@
1
- export declare const styles: Record<"container" | "subtitle" | "headingContainer", import("@emotion/serialize").Interpolation<import("@packlink/giger-theme/dist/lib/Theme").Theme>>;
1
+ export declare const styles: Record<"subtitle" | "container" | "headingContainer", import("@emotion/serialize").Interpolation<import("@packlink/giger-theme/dist/lib/Theme").Theme>>;
@@ -1,5 +1,4 @@
1
- import { SE } from "@shipengine/api";
2
- import { WarehousePreference } from "../warehouse-preference-wizard";
1
+ import { SE } from "@shipengine/js-api";
3
2
  export type WarehousePayload = Partial<SE.Warehouse> & Pick<SE.Warehouse, "name" | "originAddress" | "isDefault">;
4
3
  export type ManageWarehousesProps = {
5
4
  errors?: SE.CodedError[];
@@ -7,9 +6,6 @@ export type ManageWarehousesProps = {
7
6
  onDelete: (warehouseId: string) => Promise<void>;
8
7
  onEdit: (payload: WarehousePayload, warehouseId: string) => Promise<void>;
9
8
  onSetDefault: (warehouse: Partial<SE.Warehouse>, warehouseId: string) => Promise<void>;
10
- onValidate: (warehouse: WarehousePayload) => Promise<WarehousePreference>;
11
- setWarehousePreference: (warehousePreference?: WarehousePreference) => void;
12
- warehousePreference?: WarehousePreference;
13
9
  warehouses: SE.Warehouse[];
14
10
  };
15
- export declare const ManageWarehouses: ({ errors, onAdd, onDelete, onEdit, onSetDefault, onValidate, setWarehousePreference, warehousePreference, warehouses, }: ManageWarehousesProps) => import("@emotion/react/jsx-runtime").JSX.Element;
11
+ export declare const ManageWarehouses: ({ errors, onAdd, onDelete, onEdit, onSetDefault, warehouses, }: ManageWarehousesProps) => import("@emotion/react/jsx-runtime").JSX.Element;
@@ -1,13 +1,22 @@
1
- import { SE } from "@shipengine/api";
1
+ import { SE } from "@shipengine/js-api";
2
2
  import { Templates } from "../../../components";
3
- import { WarehousePayload } from "../manage-warehouses";
4
- import { WarehousePreference } from "../warehouse-preference-wizard";
3
+ export type ValidateWarehouse = {
4
+ type: "warehouse";
5
+ warehouse: Partial<SE.Warehouse> & Pick<SE.Warehouse, "isDefault" | "name" | "originAddress">;
6
+ };
7
+ export type ValidateBilling = {
8
+ billing: {
9
+ address: SE.Address;
10
+ creditCard: SE.CreditCard;
11
+ };
12
+ type: "billing";
13
+ };
14
+ export type ValidateAddress = ValidateWarehouse | ValidateBilling;
5
15
  export type OnboardingProps = {
6
16
  carriers: SE.Carrier[];
7
17
  createWarehouse: (payload: Partial<SE.Warehouse>) => Promise<SE.Warehouse>;
8
18
  onCarrierCreated: () => Promise<void>;
9
19
  onCompleteOnboarding: () => void;
10
- onValidateWarehouse: (warehouse: WarehousePayload) => Promise<WarehousePreference>;
11
20
  onWarehouseCreated: () => Promise<void>;
12
21
  registerDhlCarrier: (payload: SE.CarrierConnection) => Promise<void>;
13
22
  registerDhlCarrierErrors: SE.CodedError[] | null;
@@ -15,9 +24,6 @@ export type OnboardingProps = {
15
24
  registerStampsCarrierErrors: SE.CodedError[] | null;
16
25
  registerUpsCarrier: (payload: SE.CarrierConnection) => Promise<void>;
17
26
  registerUpsCarrierErrors: SE.CodedError[] | null;
18
- setWarehousePreference: (warehousePreference?: WarehousePreference) => void;
19
- validationErrors: SE.CodedError[] | null;
20
- warehousePreference?: WarehousePreference;
21
27
  warehouses: SE.Warehouse[];
22
28
  };
23
- export declare const Onboarding: ({ carriers, createWarehouse, onCarrierCreated, onWarehouseCreated, onValidateWarehouse, warehousePreference, setWarehousePreference, onCompleteOnboarding, registerDhlCarrier, registerDhlCarrierErrors, registerStampsCarrier, registerStampsCarrierErrors, registerUpsCarrier, registerUpsCarrierErrors, warehouses, validationErrors, }: OnboardingProps) => import("@emotion/react/jsx-runtime").JSX.Element;
29
+ export declare const Onboarding: ({ carriers, createWarehouse, onCarrierCreated, onCompleteOnboarding, onWarehouseCreated, registerDhlCarrier, registerDhlCarrierErrors, registerStampsCarrier, registerStampsCarrierErrors, registerUpsCarrier, registerUpsCarrierErrors, warehouses, }: OnboardingProps) => import("@emotion/react/jsx-runtime").JSX.Element;
@@ -1 +1 @@
1
- export declare const styles: Record<"step" | "wrapper", import("@emotion/serialize").Interpolation<import("@packlink/giger-theme/dist/lib/Theme").Theme>>;
1
+ export declare const styles: Record<"container" | "step" | "walletFormHeader" | "walletFormTitle" | "wrapper", import("@emotion/serialize").Interpolation<import("@packlink/giger-theme/dist/lib/Theme").Theme>>;
@@ -1,4 +1,4 @@
1
- import { SE } from "@shipengine/api";
1
+ import { SE } from "@shipengine/js-api";
2
2
  export type RateFormFeatures = {
3
3
  enableFunding?: boolean;
4
4
  enableGlobalPostFiltering?: boolean;
@@ -1,4 +1,4 @@
1
- import { SE } from "@shipengine/api";
1
+ import { SE } from "@shipengine/js-api";
2
2
  export declare const schedulePickupForCarrier: (carrierCode?: string, plaftformSchedulePickupUrl?: string) => string | undefined;
3
3
  export type ShipmentFeatures = {
4
4
  schedulePickup?: boolean;
@@ -1,5 +1,5 @@
1
1
  /// <reference types="react" />
2
- import { SE } from "@shipengine/api";
2
+ import { SE } from "@shipengine/js-api";
3
3
  import { UseShippingPresetsOptionsProps } from "../../../hooks";
4
4
  import { ShippingPreset } from "../../../types";
5
5
  import { AddressParserPayload } from "../address-parser";
@@ -1,12 +1,13 @@
1
1
  import { z } from "zod";
2
- import { SE } from "@shipengine/api";
2
+ import { SE } from "@shipengine/js-api";
3
3
  type GetShipmentSchemaOptions = {
4
4
  allowInternationalShipFrom?: boolean;
5
+ isContentDescriptionRequired?: boolean;
5
6
  isCustomsRequired?: boolean;
6
7
  requireMeasurements?: boolean;
7
8
  warehouses?: SE.Warehouse[];
8
9
  };
9
- export declare const getShipmentSchema: ({ allowInternationalShipFrom, warehouses, requireMeasurements, isCustomsRequired, }?: GetShipmentSchemaOptions) => z.ZodEffects<z.ZodDiscriminatedUnion<"__mode", z.Primitive, z.ZodObject<z.extendShape<{
10
+ export declare const getShipmentSchema: ({ allowInternationalShipFrom, warehouses, requireMeasurements, isContentDescriptionRequired, isCustomsRequired, }?: GetShipmentSchemaOptions) => z.ZodEffects<z.ZodDiscriminatedUnion<"__mode", z.Primitive, z.ZodObject<z.extendShape<{
10
11
  carrierId: z.ZodNullable<z.ZodOptional<z.ZodString>>;
11
12
  confirmation: z.ZodDefault<z.ZodNativeEnum<typeof SE.ConfirmationType>>;
12
13
  customs: z.ZodNullable<z.ZodOptional<z.ZodObject<{
@@ -59,6 +60,7 @@ export declare const getShipmentSchema: ({ allowInternationalShipFrom, warehouse
59
60
  }>>>;
60
61
  insuranceProvider: z.ZodDefault<z.ZodNativeEnum<typeof SE.InsuranceProviderType>>;
61
62
  packages: z.ZodArray<z.ZodObject<{
63
+ contentDescription: z.ZodString | z.ZodNullable<z.ZodOptional<z.ZodString>>;
62
64
  dimensions: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodObject<{
63
65
  height: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
64
66
  length: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
@@ -146,6 +148,7 @@ export declare const getShipmentSchema: ({ allowInternationalShipFrom, warehouse
146
148
  whole?: number | null | undefined;
147
149
  }>;
148
150
  }, "strip", z.ZodTypeAny, {
151
+ contentDescription?: string | null | undefined;
149
152
  dimensions?: SE.DimensionsWithUnit | undefined;
150
153
  insuredValue?: {
151
154
  amount: number;
@@ -157,6 +160,7 @@ export declare const getShipmentSchema: ({ allowInternationalShipFrom, warehouse
157
160
  code?: string | null | undefined;
158
161
  };
159
162
  }, {
163
+ contentDescription?: string | null | undefined;
160
164
  dimensions?: {
161
165
  length: number;
162
166
  height: number;
@@ -220,6 +224,7 @@ export declare const getShipmentSchema: ({ allowInternationalShipFrom, warehouse
220
224
  confirmation: SE.ConfirmationType;
221
225
  insuranceProvider: SE.InsuranceProviderType;
222
226
  packages: {
227
+ contentDescription?: string | null | undefined;
223
228
  dimensions?: SE.DimensionsWithUnit | undefined;
224
229
  insuredValue?: {
225
230
  amount: number;
@@ -256,6 +261,7 @@ export declare const getShipmentSchema: ({ allowInternationalShipFrom, warehouse
256
261
  shipmentId?: string | null | undefined;
257
262
  __mode: "browse_rates";
258
263
  packages: {
264
+ contentDescription?: string | null | undefined;
259
265
  dimensions?: {
260
266
  length: number;
261
267
  height: number;
@@ -336,6 +342,7 @@ export declare const getShipmentSchema: ({ allowInternationalShipFrom, warehouse
336
342
  }>>>;
337
343
  insuranceProvider: z.ZodDefault<z.ZodNativeEnum<typeof SE.InsuranceProviderType>>;
338
344
  packages: z.ZodArray<z.ZodObject<{
345
+ contentDescription: z.ZodString | z.ZodNullable<z.ZodOptional<z.ZodString>>;
339
346
  dimensions: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodObject<{
340
347
  height: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
341
348
  length: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
@@ -423,6 +430,7 @@ export declare const getShipmentSchema: ({ allowInternationalShipFrom, warehouse
423
430
  whole?: number | null | undefined;
424
431
  }>;
425
432
  }, "strip", z.ZodTypeAny, {
433
+ contentDescription?: string | null | undefined;
426
434
  dimensions?: SE.DimensionsWithUnit | undefined;
427
435
  insuredValue?: {
428
436
  amount: number;
@@ -434,6 +442,7 @@ export declare const getShipmentSchema: ({ allowInternationalShipFrom, warehouse
434
442
  code?: string | null | undefined;
435
443
  };
436
444
  }, {
445
+ contentDescription?: string | null | undefined;
437
446
  dimensions?: {
438
447
  length: number;
439
448
  height: number;
@@ -475,6 +484,7 @@ export declare const getShipmentSchema: ({ allowInternationalShipFrom, warehouse
475
484
  }, {
476
485
  __mode: z.ZodLiteral<"select_service">;
477
486
  packages: z.ZodArray<z.ZodObject<z.extendShape<{
487
+ contentDescription: z.ZodString | z.ZodNullable<z.ZodOptional<z.ZodString>>;
478
488
  dimensions: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodObject<{
479
489
  height: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
480
490
  length: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
@@ -588,6 +598,7 @@ export declare const getShipmentSchema: ({ allowInternationalShipFrom, warehouse
588
598
  width?: number | null | undefined;
589
599
  } | null | undefined>;
590
600
  }>, "strip", z.ZodTypeAny, {
601
+ contentDescription?: string | null | undefined;
591
602
  dimensions?: SE.DimensionsWithUnit | undefined;
592
603
  insuredValue?: {
593
604
  amount: number;
@@ -599,6 +610,7 @@ export declare const getShipmentSchema: ({ allowInternationalShipFrom, warehouse
599
610
  code?: string | null | undefined;
600
611
  };
601
612
  }, {
613
+ contentDescription?: string | null | undefined;
602
614
  dimensions?: {
603
615
  length?: number | null | undefined;
604
616
  height?: number | null | undefined;
@@ -649,6 +661,7 @@ export declare const getShipmentSchema: ({ allowInternationalShipFrom, warehouse
649
661
  confirmation: SE.ConfirmationType;
650
662
  insuranceProvider: SE.InsuranceProviderType;
651
663
  packages: {
664
+ contentDescription?: string | null | undefined;
652
665
  dimensions?: SE.DimensionsWithUnit | undefined;
653
666
  insuredValue?: {
654
667
  amount: number;
@@ -685,6 +698,7 @@ export declare const getShipmentSchema: ({ allowInternationalShipFrom, warehouse
685
698
  shipmentId?: string | null | undefined;
686
699
  __mode: "select_service";
687
700
  packages: {
701
+ contentDescription?: string | null | undefined;
688
702
  dimensions?: {
689
703
  length?: number | null | undefined;
690
704
  height?: number | null | undefined;
@@ -733,6 +747,7 @@ export declare const getShipmentSchema: ({ allowInternationalShipFrom, warehouse
733
747
  unit: string;
734
748
  value: number;
735
749
  } | undefined;
750
+ contentDescription?: string | null | undefined;
736
751
  insuredValue?: {
737
752
  amount: number;
738
753
  currency: SE.Currency;
@@ -743,6 +758,7 @@ export declare const getShipmentSchema: ({ allowInternationalShipFrom, warehouse
743
758
  unit: string;
744
759
  value: number;
745
760
  } | undefined;
761
+ contentDescription?: string | null | undefined;
746
762
  insuredValue?: {
747
763
  amount: number;
748
764
  currency: SE.Currency;
@@ -754,6 +770,7 @@ export declare const getShipmentSchema: ({ allowInternationalShipFrom, warehouse
754
770
  unit: string;
755
771
  value: number;
756
772
  } | undefined;
773
+ contentDescription?: string | null | undefined;
757
774
  insuredValue?: {
758
775
  amount: number;
759
776
  currency: SE.Currency;
@@ -764,6 +781,7 @@ export declare const getShipmentSchema: ({ allowInternationalShipFrom, warehouse
764
781
  unit: string;
765
782
  value: number;
766
783
  } | undefined;
784
+ contentDescription?: string | null | undefined;
767
785
  insuredValue?: {
768
786
  amount: number;
769
787
  currency: SE.Currency;
@@ -797,6 +815,7 @@ export declare const getShipmentSchema: ({ allowInternationalShipFrom, warehouse
797
815
  unit: string;
798
816
  value: number;
799
817
  } | undefined;
818
+ contentDescription?: string | null | undefined;
800
819
  insuredValue?: {
801
820
  amount: number;
802
821
  currency: SE.Currency;
@@ -807,6 +826,7 @@ export declare const getShipmentSchema: ({ allowInternationalShipFrom, warehouse
807
826
  unit: string;
808
827
  value: number;
809
828
  } | undefined;
829
+ contentDescription?: string | null | undefined;
810
830
  insuredValue?: {
811
831
  amount: number;
812
832
  currency: SE.Currency;
@@ -818,6 +838,7 @@ export declare const getShipmentSchema: ({ allowInternationalShipFrom, warehouse
818
838
  unit: string;
819
839
  value: number;
820
840
  } | undefined;
841
+ contentDescription?: string | null | undefined;
821
842
  insuredValue?: {
822
843
  amount: number;
823
844
  currency: SE.Currency;
@@ -828,6 +849,7 @@ export declare const getShipmentSchema: ({ allowInternationalShipFrom, warehouse
828
849
  unit: string;
829
850
  value: number;
830
851
  } | undefined;
852
+ contentDescription?: string | null | undefined;
831
853
  insuredValue?: {
832
854
  amount: number;
833
855
  currency: SE.Currency;
@@ -863,6 +885,7 @@ export declare const getShipmentSchema: ({ allowInternationalShipFrom, warehouse
863
885
  shipmentId?: string | null | undefined;
864
886
  __mode: "browse_rates";
865
887
  packages: {
888
+ contentDescription?: string | null | undefined;
866
889
  dimensions?: {
867
890
  length: number;
868
891
  height: number;
@@ -909,6 +932,7 @@ export declare const getShipmentSchema: ({ allowInternationalShipFrom, warehouse
909
932
  shipmentId?: string | null | undefined;
910
933
  __mode: "select_service";
911
934
  packages: {
935
+ contentDescription?: string | null | undefined;
912
936
  dimensions?: {
913
937
  length?: number | null | undefined;
914
938
  height?: number | null | undefined;
@@ -1,5 +1,5 @@
1
1
  import { WithChildrenCommonProps } from "@packlink/giger";
2
- import { SE } from "@shipengine/api";
2
+ import { SE } from "@shipengine/js-api";
3
3
  export type SuspendSalesOrderProps = WithChildrenCommonProps<{
4
4
  errors?: SE.CodedError[];
5
5
  isLoading?: boolean;
@@ -1,5 +1,5 @@
1
1
  import { WithChildrenCommonProps } from "@packlink/giger";
2
- import { SE } from "@shipengine/api";
2
+ import { SE } from "@shipengine/js-api";
3
3
  export type SuspendShipmentProps = WithChildrenCommonProps<{
4
4
  errors?: SE.CodedError[];
5
5
  isLoading?: boolean;
@@ -1,4 +1,4 @@
1
- import { SE } from "@shipengine/api";
1
+ import { SE } from "@shipengine/js-api";
2
2
  export type VoidLabelProps = {
3
3
  onComplete: (request: SE.VoidRequest, shipment: SE.SalesOrderShipment) => void;
4
4
  onSubmit: () => Promise<void>;
@@ -1,5 +1,5 @@
1
1
  /// <reference types="react" />
2
- import { SE } from "@shipengine/api";
2
+ import { SE } from "@shipengine/js-api";
3
3
  import { BillingAddressPayload } from "./wallet-schema";
4
4
  export type EditWalletAddressFormProps<T = undefined> = {
5
5
  address?: SE.Address;
@@ -1,11 +1,12 @@
1
- import { SE } from "@shipengine/api";
1
+ import { SE } from "@shipengine/js-api";
2
2
  export type WalletFormFeatures = {};
3
+ export type WalletPayload = {
4
+ address: SE.Address;
5
+ creditCard: SE.CreditCard;
6
+ };
3
7
  export type WalletFormProps = {
4
8
  address: SE.Address;
5
- errors: SE.CodedError[] | null;
6
- onSubmit: ({ address, creditCard, }: {
7
- address: SE.Address;
8
- creditCard: SE.CreditCard;
9
- }) => Promise<void>;
9
+ errors?: SE.CodedError[] | null;
10
+ onSubmit: (payload: WalletPayload) => Promise<void>;
10
11
  };
11
12
  export declare const WalletForm: ({ address, errors, onSubmit }: WalletFormProps) => import("@emotion/react/jsx-runtime").JSX.Element;
@@ -1 +1 @@
1
- export declare const styles: Record<"grid" | "heading" | "subtitle", import("@emotion/serialize").Interpolation<import("@packlink/giger-theme/dist/lib/Theme").Theme>>;
1
+ export declare const styles: Record<"grid", import("@emotion/serialize").Interpolation<import("@packlink/giger-theme/dist/lib/Theme").Theme>>;
@@ -1,5 +1,5 @@
1
1
  import { z } from "zod";
2
- import { CreditCardVendor } from "@shipengine/api";
2
+ import { CreditCardVendor } from "@shipengine/js-api";
3
3
  export declare const billingAddressSchema: z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodObject<z.extendShape<{
4
4
  addressLine1: z.ZodString;
5
5
  addressLine2: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodString>>, string | undefined, string | null | undefined>;
@@ -1,4 +1,4 @@
1
- import { SE } from "@shipengine/api";
1
+ import { SE } from "@shipengine/js-api";
2
2
  type WarehouseDisplayProps = {
3
3
  warehouse: SE.Warehouse;
4
4
  };
@@ -1,4 +1,4 @@
1
- import { SE } from "@shipengine/api";
1
+ import { SE } from "@shipengine/js-api";
2
2
  import { WarehousePayload } from "../manage-warehouses";
3
3
  export type WarehouseFormProps = {
4
4
  isOnboarding?: boolean;
@@ -1,4 +1,4 @@
1
- import { SE } from "@shipengine/api";
1
+ import { SE } from "@shipengine/js-api";
2
2
  import { Templates } from "../../../components";
3
3
  import { UseShippingPresetsOptionsProps } from "../../../hooks";
4
4
  import { UseRatesFormProps, UseShipmentFormProps } from "./hooks";
@@ -1,4 +1,4 @@
1
- import { SE } from "@shipengine/api";
1
+ import { SE } from "@shipengine/js-api";
2
2
  import { Templates } from "../../../../components";
3
3
  import { CountryCode } from "../../../../constants";
4
4
  export type UseAddressProps = {
@@ -1,4 +1,4 @@
1
- import { SE } from "@shipengine/api";
1
+ import { SE } from "@shipengine/js-api";
2
2
  export type UseCustomsProps = {
3
3
  onUpdate?: (shipment: SE.SalesOrderShipment) => Promise<void> | void;
4
4
  shipment?: SE.SalesOrderShipment;
@@ -1,4 +1,4 @@
1
- import { SE } from "@shipengine/api";
1
+ import { SE } from "@shipengine/js-api";
2
2
  import { ShippingPreset } from "../../../../types";
3
3
  export type UsePresetsProps = {
4
4
  onApply?: (preset: ShippingPreset, shipment: SE.SalesOrderShipment) => Promise<void> | void;
@@ -1,4 +1,4 @@
1
- import { SE } from "@shipengine/api";
1
+ import { SE } from "@shipengine/js-api";
2
2
  import { UseRequestRatesProps } from "./use-request-rates";
3
3
  export type UseRatesFormProps = {
4
4
  onBeforeLabelCreate?: (rate: SE.Rate, shipment: SE.SalesOrderShipment) => Promise<void> | void;
@@ -1,4 +1,4 @@
1
- import { SE } from "@shipengine/api";
1
+ import { SE } from "@shipengine/js-api";
2
2
  export type UseRequestRatesProps = {
3
3
  onRatesCalculated?: (rates: SE.Rate[], shipment: SE.SalesOrderShipment) => Promise<void> | void;
4
4
  };
@@ -1,4 +1,4 @@
1
- import { SE } from "@shipengine/api";
1
+ import { SE } from "@shipengine/js-api";
2
2
  import { ShippingPreset } from "../../../../types";
3
3
  import { UseAddressProps } from "./use-address";
4
4
  import { UsePresetsProps } from "./use-presets";
@@ -4,5 +4,4 @@ export * from "./manage-warehouses";
4
4
  export * from "./onboarding";
5
5
  export * from "./purchase-label";
6
6
  export * from "./shipment";
7
- export * from "./wallet-history";
8
7
  export * from "./void-label";
@@ -5,7 +5,7 @@ export type ConnectedCarrierMetadata = {
5
5
  };
6
6
  export declare const useListConnectedCarriers: () => {
7
7
  data: ConnectedCarrierMetadata[];
8
- error: import("dist/shipengine-api/src").CodedError[] | null;
8
+ error: import("@shipengine/react-api").CodedError[] | null;
9
9
  isLoading: boolean;
10
- refetch: <TPageData>(options?: (import("react-query").RefetchOptions & import("react-query").RefetchQueryFilters<TPageData>) | undefined) => Promise<import("react-query").QueryObserverResult<import("dist/shipengine-api/src").Carrier[], import("dist/shipengine-api/src").CodedError[]>>;
10
+ refetch: <TPageData>(options?: (import("react-query").RefetchOptions & import("react-query").RefetchQueryFilters<TPageData>) | undefined) => Promise<import("react-query").QueryObserverResult<import("@shipengine/react-api").Carrier[], import("@shipengine/react-api").CodedError[]>>;
11
11
  };
@@ -1,4 +1,4 @@
1
- import { SE } from "@shipengine/api";
1
+ import { SE } from "@shipengine/js-api";
2
2
  import { ConfigureShipmentProps } from "../../configure-shipment";
3
3
  import { UsePendingShipmentProps } from "./use-pending-shipment";
4
4
  export type UseConfigureShipmentProps = {
@@ -5,7 +5,7 @@ export type UseImportSalesOrderProps = {
5
5
  salesOrderId?: string;
6
6
  };
7
7
  export declare const useImportSalesOrder: ({ externalOrderId, externalOrderNumber, orderSourceCode, salesOrderId, }: UseImportSalesOrderProps) => {
8
- errors: import("dist/shipengine-api/src").CodedError[] | undefined;
8
+ errors: import("@shipengine/react-api").CodedError[] | undefined;
9
9
  isLoading: boolean;
10
- salesOrder: import("dist/shipengine-api/src").SalesOrder | undefined;
10
+ salesOrder: import("@shipengine/react-api").SalesOrder | undefined;
11
11
  };
@@ -2,8 +2,8 @@ export type UseLoadShipmentProps = {
2
2
  shipmentId: string;
3
3
  };
4
4
  export declare const useLoadShipment: ({ shipmentId }: UseLoadShipmentProps) => {
5
- errors: import("dist/shipengine-api/src").CodedError[] | undefined;
5
+ errors: import("@shipengine/react-api").CodedError[] | undefined;
6
6
  isLoading: boolean;
7
- refetchShipment: <TPageData>(options?: (import("react-query").RefetchOptions & import("react-query").RefetchQueryFilters<TPageData>) | undefined) => Promise<import("react-query").QueryObserverResult<import("dist/shipengine-api/src").SalesOrderShipment, import("dist/shipengine-api/src").CodedError[]>>;
8
- shipment: import("dist/shipengine-api/src").SalesOrderShipment | undefined;
7
+ refetchShipment: <TPageData>(options?: (import("react-query").RefetchOptions & import("react-query").RefetchQueryFilters<TPageData>) | undefined) => Promise<import("react-query").QueryObserverResult<import("@shipengine/react-api").SalesOrderShipment, import("@shipengine/react-api").CodedError[]>>;
8
+ shipment: import("@shipengine/react-api").SalesOrderShipment | undefined;
9
9
  };
@@ -1,4 +1,4 @@
1
- import { SE } from "@shipengine/api";
1
+ import { SE } from "@shipengine/js-api";
2
2
  export type UsePendingShipmentProps = {
3
3
  onLoad?: (salesOrder: SE.SalesOrder, shipments: SE.SalesOrderShipment[], pendingShipment?: SE.SalesOrderShipment) => Promise<void> | void;
4
4
  salesOrder?: SE.SalesOrder;
@@ -1,4 +1,4 @@
1
- import { SE } from "@shipengine/api";
1
+ import { SE } from "@shipengine/js-api";
2
2
  import { Templates } from "../../../components";
3
3
  export type ShipmentFeatures = {
4
4
  shipment?: Templates.ShipmentFeatures;
@@ -1,4 +1,4 @@
1
- import { SE } from "@shipengine/api";
1
+ import { SE } from "@shipengine/js-api";
2
2
  export type VoidLabelProps = {
3
3
  labelId?: string;
4
4
  onComplete: (request: SE.VoidRequest, shipment: SE.SalesOrderShipment) => void;
@@ -2,6 +2,5 @@ export { Element as ListCarriers } from "./list-carriers";
2
2
  export { Element as ManageWarehouses } from "./manage-warehouses";
3
3
  export { Element as PurchaseLabel } from "./purchase-label";
4
4
  export { Element as Onboarding } from "./onboarding";
5
- export { Element as WalletHistory } from "./wallet-history";
6
5
  export { Element as ViewShipment } from "./view-shipment";
7
6
  export { Element as VoidLabel } from "./void-label";
@@ -1,5 +1,6 @@
1
1
  import { Factory } from "fishery";
2
- import { SE } from "@shipengine/api";
2
+ import { SE } from "@shipengine/js-api";
3
+ import { Templates } from "../../components";
3
4
  export type AddressTransientParams = {
4
5
  isInternational?: boolean;
5
6
  };
@@ -25,4 +26,10 @@ type AddressPreference = SE.AddressValidation & {
25
26
  * @category Factory
26
27
  */
27
28
  export declare const addressPreferenceFactory: Factory<AddressPreference, any, AddressPreference>;
29
+ /**
30
+ * Mock the addressValidationPreference object used to hyrdate the address valiation feature
31
+ * used for warehouse management and onboarding.
32
+ * @category Factory
33
+ */
34
+ export declare const addressValidationWithTypeFactory: Factory<Templates.AddressValidationPreference, any, Templates.AddressValidationPreference>;
28
35
  export {};
@@ -1,5 +1,5 @@
1
1
  import { Factory } from "fishery";
2
- import { SE } from "@shipengine/api";
2
+ import { SE } from "@shipengine/js-api";
3
3
  /**
4
4
  * @category Factories
5
5
  */
@@ -1,5 +1,5 @@
1
1
  import { Factory } from "fishery";
2
- import { SE } from "@shipengine/api";
2
+ import { SE } from "@shipengine/js-api";
3
3
  export type LabelTransientParams = {
4
4
  carrier: SE.Carrier;
5
5
  shipment: SE.SalesOrderShipment;
@@ -1,5 +1,5 @@
1
1
  import { Factory } from "fishery";
2
- import { SE } from "@shipengine/api";
2
+ import { SE } from "@shipengine/js-api";
3
3
  export type MoneyTransientParams = {
4
4
  isInternational?: boolean;
5
5
  };
@@ -1,5 +1,5 @@
1
1
  import { Factory } from "fishery";
2
- import { SE } from "@shipengine/api";
2
+ import { SE } from "@shipengine/js-api";
3
3
  export declare const randomOrderSourceCode: () => SE.OrderSourceCode;
4
4
  /**
5
5
  * @category Factories
@@ -1,5 +1,5 @@
1
1
  import { Factory } from "fishery";
2
- import { SE } from "@shipengine/api";
2
+ import { SE } from "@shipengine/js-api";
3
3
  export type PackageTransientParams = {
4
4
  noDimensions?: boolean;
5
5
  };
@@ -1,5 +1,5 @@
1
1
  import { Factory } from "fishery";
2
- import { SE } from "@shipengine/api";
2
+ import { SE } from "@shipengine/js-api";
3
3
  /**
4
4
  * @category Factories
5
5
  */
@@ -1,5 +1,5 @@
1
1
  import { Factory } from "fishery";
2
- import { SE } from "@shipengine/api";
2
+ import { SE } from "@shipengine/js-api";
3
3
  import { MoneyTransientParams } from "./money";
4
4
  export declare const randomPaymentStatus: () => SE.PaymentStatus;
5
5
  export declare const randomFulfillmentStatus: () => SE.FulfillmentStatus;
@@ -1,5 +1,5 @@
1
1
  import { Factory } from "fishery";
2
- import { SE } from "@shipengine/api";
2
+ import { SE } from "@shipengine/js-api";
3
3
  export type ServiceTransientParams = {
4
4
  carrier?: SE.Carrier;
5
5
  };
@@ -1,5 +1,5 @@
1
1
  import { Factory } from "fishery";
2
- import { SE } from "@shipengine/api";
2
+ import { SE } from "@shipengine/js-api";
3
3
  import { MoneyTransientParams } from "./money";
4
4
  export declare const randomDeliveryConfirmation: () => SE.ConfirmationType;
5
5
  export declare const randomInsuranceProvider: (allowNone?: boolean) => SE.InsuranceProviderType;
@@ -1,5 +1,5 @@
1
1
  import { Factory } from "fishery";
2
- import { SE } from "@shipengine/api";
2
+ import { SE } from "@shipengine/react-api";
3
3
  /**
4
4
  * Wallet Transaction Factory
5
5
  *
@@ -1,8 +1,6 @@
1
1
  import { Factory } from "fishery";
2
- import { SE } from "@shipengine/api";
3
- import { Templates } from "../../components";
2
+ import { SE } from "@shipengine/js-api";
4
3
  /**
5
4
  * @category Factories
6
5
  */
7
6
  export declare const warehouseFactory: Factory<SE.Warehouse, any, SE.Warehouse>;
8
- export declare const warehouseAddressPreferenceFactory: Factory<Templates.WarehouseAddressPreference, any, Templates.WarehouseAddressPreference>;
@@ -1,5 +1,5 @@
1
1
  import { Factory } from "fishery";
2
- import { SE } from "@shipengine/api";
2
+ import { SE } from "@shipengine/js-api";
3
3
  export declare const randomWeightUnit: () => SE.WeightUnit;
4
4
  /**
5
5
  * @category Factories
@@ -0,0 +1 @@
1
+ export declare const styles: Record<"action" | "displayStateContainer" | "emptyStateContainer" | "gridContainer" | "linkAction" | "pagination" | "skeletonCard" | "skeletonCardColumnLeft" | "skeletonCardColumnRight" | "skeletonCardList" | "skeletonCardLogo" | "skeletonPagination", import("@emotion/serialize").Interpolation<import("@packlink/giger-theme/dist/lib/Theme").Theme>>;
@@ -6,4 +6,4 @@ export * from "./use-page-layout";
6
6
  export * from "./use-root-portal";
7
7
  export * from "./use-run-once-on-true";
8
8
  export * from "./use-toggle";
9
- export * from "./use-warehouse-validation";
9
+ export * from "./use-address-validation";