@shipengine/elements 2.12.0 → 2.13.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 (58) hide show
  1. package/actions-menu.js +5 -5
  2. package/index.js +1 -1
  3. package/package.json +2 -2
  4. package/src/components/add-funds-form/add-funds-form.d.ts +9 -1
  5. package/src/components/carrier-connection-card/carrier-connection-card.styles.d.ts +1 -1
  6. package/src/components/collapsible-panel/collapsible-panel.d.ts +15 -1
  7. package/src/components/field/date-picker/date-picker.d.ts +3 -1
  8. package/src/components/field/rate-select/rate-card/cost-breakdown/cost-breakdown.styles.d.ts +2 -1
  9. package/src/components/field/rate-select/rate-card/rate-card.styles.d.ts +1 -1
  10. package/src/components/grid-controller/grid-controller.styles.d.ts +8 -3
  11. package/src/components/grid-filters/components/label-id-filter/label-id-filter.styles.d.ts +1 -1
  12. package/src/components/history/history-card/history-card.styles.d.ts +1 -1
  13. package/src/components/save-status/save-status.d.ts +15 -1
  14. package/src/components/templates/label-display/label-card.styles.d.ts +1 -1
  15. package/src/components/templates/shipment-form/shipment-schema.d.ts +15 -109
  16. package/src/components/templates/theme-creator/theme-creator.styles.d.ts +1 -1
  17. package/src/elements/labels-grid/labels-grid.d.ts +15 -6
  18. package/src/elements/manage-carriers/manage-carriers.d.ts +10 -1
  19. package/src/elements/manage-external-carriers/manage-external-carriers.d.ts +10 -1
  20. package/src/elements/manage-funding/manage-funding-element.d.ts +10 -1
  21. package/src/elements/manage-warehouses/manage-warehouses.d.ts +10 -1
  22. package/src/elements/payment-method-settings/payment-method-settings-element.d.ts +10 -1
  23. package/src/elements/purchase-label/purchase-label.d.ts +14 -2
  24. package/src/elements/select-label-layout/select-label-layout-element.d.ts +10 -1
  25. package/src/elements/shipment-summary/shipment-summary.d.ts +13 -2
  26. package/src/elements/shipments-grid/shipments-grid.d.ts +10 -1
  27. package/src/elements/theme-creator/theme-creator.d.ts +10 -1
  28. package/src/elements/transaction-history/transaction-history-element.d.ts +10 -1
  29. package/src/elements/unit-settings/unit-settings-element.d.ts +10 -1
  30. package/src/elements/vat-settings/vat-settings-element.d.ts +10 -1
  31. package/src/elements/void-label/components/actions/actions.d.ts +2 -1
  32. package/src/elements/void-label/void-label.d.ts +65 -25
  33. package/src/elements-provider/elements-context-provider.d.ts +10 -3
  34. package/src/elements-provider/elements-provider.d.ts +7 -2
  35. package/src/features/manage-carriers/index.d.ts +1 -0
  36. package/src/features/manage-carriers/manage-carriers.d.ts +12 -1
  37. package/src/features/manage-carriers/use-manage-carriers.d.ts +15 -0
  38. package/src/features/manage-funding/manage-funding.d.ts +10 -1
  39. package/src/features/vat-settings/use-vat-settings.d.ts +1 -1
  40. package/src/hooks/options/use-insurance-provider-options.d.ts +1 -1
  41. package/src/hooks/use-root-portal.d.ts +3 -2
  42. package/src/locales/en/index.d.ts +10 -1
  43. package/src/utilities/styles.d.ts +6 -2
  44. package/src/workflows/account-settings/account-settings.d.ts +10 -1
  45. package/src/workflows/account-settings/use-get-panel-props.d.ts +2 -2
  46. package/src/workflows/carrier-services/carrier-services.d.ts +60 -2
  47. package/src/workflows/connect-external-carrier/connect-external-carrier.d.ts +33 -1
  48. package/src/workflows/label-workflow/label-workflow.d.ts +10 -0
  49. package/src/workflows/onboarding/onboarding.d.ts +17 -1
  50. package/suspend-text.js +1 -1
  51. package/transaction-history-element.js +1 -1
  52. package/use-scrub-errors.js +1 -1
  53. package/use-toggle.js +1 -1
  54. package/use-unit-settings.js +1 -1
  55. package/usePager.js +1 -1
  56. package/utilities.js +1 -1
  57. package/validation.js +1 -1
  58. package/wallet-form.js +1 -1
package/index.js CHANGED
@@ -1 +1 @@
1
- import{ShipEngine as _}from"@shipengine/react-api";export*from"@shipengine/react-api";export{y as Actions,x as ActionsMenu,A as AddFundsForm,a as AutoFundingForm,B as ButtonGroup,C as CarrierBalance,c as CarrierConnectionCard,d as CarrierIcon,e as CarrierLogo,f as CollapsiblePanel,h as CopyButton,i as Cube,D as DateRangeCombo,j as DateRangeSelect,k as DisplayTerm,E as EditBillingForm,l as ErrorFallback,F as FieldLabel,m as FormPortal,n as FundAndPurchase,H as HistoryCard,o as HistoryCardExtension,I as InlineLabel,p as ItemsBreakdown,L as LinkAction,q as Loader,P as PoweredByShipEngine,R as RateDetails,S as Section,r as SettingsCard,z as ShipFromAddressForm,t as SkeletonCarrierRow,u as Spacer,v as Spread,T as Tabs,V as VatForm,W as WalletCard,w as WarehouseForm,b as autoFundingSchema,g as getAddFundsSchema,s as styles}from"./actions-menu.js";export{C as CellFormattedDate,D as Drawer,E as ErrorState,G as GridController,b as GridFilters,a as GridFooter,u as usePager}from"./usePager.js";export{f as Field,P as Pager,S as StoryNotes,a as SuspendText}from"./suspend-text.js";import{E as ee,R as ae,a as te}from"./use-toggle.js";export{a as ElementsContext,E as ElementsContextProvider,P as Portal,R as RootPortalProvider,c as useAddressValidation,u as useCountryCodeOptions,g as useElements,d as useNestedForm,e as useRootPortal,b as useStateCodeOptions,f as useToggle}from"./use-toggle.js";export{C as Country,U as UsState,d as UsaCity,c as countries,a as countryCodes,e as euCountryCodes,p as postalCodeRegex,f as usCities,b as usStateCodes,u as usStates}from"./address.js";export{a as CarrierServices,b as ConnectExternalCarrier,p as PurchaseLabel,s as ShipmentSummary,v as VoidLabel,c as createElement}from"./use-unit-settings.js";export{l as LabelsGrid,m as ManageCarriers,b as ManageExternalCarriers,d as ManageFunding,a as ManageWarehouses,p as PaymentMethodSettings,e as SelectLabelLayout,s as ShipmentsGrid,t as ThemeCreator,T as ThemeCreatorProvider,f as TransactionHistory,c as UnitSettings,u as useThemeCreator}from"./transaction-history-element.js";export{e as extendZod}from"./zod.js";export{P as PudoType,p as useBlackboxDetection,u as useConfirmationOptions,a as useCustomsContentsOptions,b as useCustomsNonDeliveryOptions,c as useDateRangeOptions,n as useGetFundingSourceInsuranceProvider,d as useInsuranceProviderOptions,o as useManageFundingSourceInsurance,e as useMovementIndicatorOptions,f as usePackageOptions,g as useRateOptions,q as useScrubErrors,h as useServiceCodeOptions,l as useServicePoints,k as useShipFromAddressOptions,i as useShipmentMetadata,j as useShippingPresetsOptions,m as useWindsorFramework}from"./use-scrub-errors.js";export{P as PageLayoutProvider,u as useExpirationMonthOptions,a as useHelpers,b as usePageLayout}from"./use-page-layout.js";export{u as useGetServiceName}from"./use-get-service-name.js";export{u as useRunOnceOnTrue}from"./use-run-once-on-true.js";export{m as moneySchema}from"./money.js";export{p as phoneSchema,a as phoneSchemaUnvalidated}from"./phone.js";export{C as CanadaDeliveredDutyOptions}from"./canada-ddp.js";export{a as assert,r as raise}from"./assertions.js";export{g as getSellerIdFromToken,i as isOnboarded}from"./checks.js";export{b as convertDimensions,c as createDictionary,f as formatDimensions,h as getCancelledShipment,d as getIsCustomsRequiredForShipment,g as getIsInternationalShipment,e as getPendingShipment,j as getShipmentByStatus,a as isCollectionService,i as isPudoEligibleRate,m as moveCustomsItemsToProducts}from"./shipment.js";import{_ as re,g as se,d as oe}from"./carrier.js";export{P as addEmailToValidation,x as addSpaceBetweenWords,A as calculateTotal,t as capitalizeFirstLetter,u as capitalizeFirstLetterOfEachWord,y as currencySymbol,i as daysAfter,d as deepMergeFeatures,q as featureFlagComponentNameLookup,a0 as filterFundingSourceCarriers,a as findDateLocale,b as formatByDateAndLocale,B as formatCreditCardNumber,f as formatDate,c as formatDateDDMMYY,e as formatDateDDMMYYYY,C as formatExpiration,z as formatMoney,X as getCarrierIdByCarrierCode,D as getCurrencyFromString,E as getCurrencySymbolFromString,g as getDefaultFeatures,Q as getDefaultShipFromAddress,j as getExpirationYears,S as getIsShipmentUsingSavedShipFromAddress,Y as getLogoOrIconByCarrierCode,F as getRateRequiresAcknowledgement,l as getRelativeDates,R as getSavedShipFromAddressId,G as getTotalRateAmount,h as getlocaleDateStringFormat,I as isDomesticAddress,O as isEmptyAddress,W as isEvriCarrier,Z as isGlobalPostEligible,J as isMilitaryAddress,k as isNowOrInTheFuture,r as isObject,M as isPoBox,N as isPoBoxAddress,$ as isSendleEligible,K as isUnitedStatesTerritory,L as isUnsupportedByUps,U as isUpsCarrier,T as isUspsCarrier,V as isYodelCarrier,m as mostRecent,n as nextDayCutoff,o as omitTime,H as overrideCarrierCodes,p as parseLocaleDate,v as pascalize,w as replaceSpacesWithDashes,s as sortByCreationDate}from"./carrier.js";export{N as NO_VAT_COUNTRIES,k as convertDecimalWeightToFractionalWeight,j as convertFractionalWeightToDecimalWeight,h as convertPoundsAndOuncesToOunces,l as convertWeight,c as createCodedErrors,m as formatFractionalWeight,u as formatTrackingNumber,g as getCustomsFromSalesOrder,o as getDefaultWarehouse,q as getInsuranceProviderWithFriendlyName,b as getIsCustomsRequiredForSalesOrder,r as getIsInsuraceProviderAccepted,v as getIsVatRequired,d as getRequestedServices,e as getSalesOrderItemsFromSalesOrderOrShipment,p as getWarehouseById,f as isDecimalWeight,n as isFlatRatePackageCode,i as isMetricWeightUnit,a as throwAny,t as throwJoinedMessages,s as trackingStatusFormatter}from"./vat.js";export{a as aggregateRateDetailItems,c as calculateRateDetailBreakdown,b as createStyles,e as errorMap,f as formLogger,i as isString,v as validationResolver}from"./validation.js";export{a as AccountSettings,l as LabelWorkflow,o as Onboarding}from"./wallet-form.js";import{jsx as ie}from"@emotion/react/jsx-runtime";import{GigerProvider as ne,GigerTestProvider as de}from"@shipengine/giger";import{Theme as le}from"@shipengine/giger-theme";import pe from"axios";import{useCallback as ce,useMemo as me}from"react";import"date-fns/isToday";import"react-hook-form";import"react-i18next";import"@emotion/react";import"lodash/isEqual";import"zod";import"copy-to-clipboard";import"js-base64";import"libphonenumber-js/min";import"lodash/omit";import"card-validator";import"react-use";import"date-fns/subDays";import"react-dom";import"lodash/merge";import"@tanstack/react-query";import"lodash/mergeWith";import"humps";import"@shipengine/js-api";import"@rjsf/core";import"@rjsf/validator-ajv8";import"lodash/camelCase";import"use-debounce";import"classnames";import"i18next";import"i18next-browser-languagedetector";import"@emotion/cache";import"stylis";import"date-fns/formatISO";import"date-fns/isSameDay";import"date-fns/isWithinInterval";import"date-fns/setHours";import"date-fns/setMinutes";import"lodash/orderBy";import"jwt-decode";import"date-fns/format";import"date-fns/locale";import"date-fns/parse";import"lodash/get";import"lodash/isNil";import"lodash/omitBy";import"@hookform/resolvers/zod";var ge={fallback:{borderRadius:{L:"16px",M:"8px",S:"4px",XL:"32px",XS:"2px"},breakPoints:{desktop:1280,mobileLarge:480,tablet:768,tabletLarge:960},card:{borderRadius:{desktop:"8px",mobile:"4px",tablet:"8px"}},components:{Button:{borderRadius:"4px"},Checkbox:{borderRadius:"2px",square:!1},Chip:{backgroundColor:"#f4f4f4",border:"none",borderRadius:"16px",color:"#706f6f",fontWeight:600,isSelected:{backgroundColor:"#EDEDED",border:"none",color:"#7A7A7A"},padding:"4px 16px"},Dialog:{action:{justifyContent:"center"},content:{padding:24,textAlign:"center"},dialog:{backgroundColor:"rgba(0, 0, 0, 0.26)",borderRadius:"4px"},header:{borderBottom:"2px solid #d3d3d3",padding:24,titleColor:"#616161"}},Field:{color:"#373737",fontWeight:700,placeholder:{fontWeight:700}},FieldContainer:{borderRadius:"4px"},Link:{activeColor:"#787878",defaultColor:"#616161",hoverColor:"#303030",isDark:{activeColor:"#787878",defaultColor:"#fff",hoverColor:"#fff",visitedColor:"#fff"},visitedColor:"#303030"},Table:{border:"none",borderRadius:"4px",boxShadow:"0 0 12px rgba(0, 0, 0, 0.1)"},Typography:{body1:{fontSize:"16px",fontWeight:400,letterSpacing:0,lineHeight:"24px"},body2:{fontSize:"14px",fontWeight:400,letterSpacing:3,lineHeight:"20px"},heading1:{fontSize:"48px",fontWeight:700,letterSpacing:0,lineHeight:"72px"},heading2:{fontSize:"32px",fontWeight:700,letterSpacing:1,lineHeight:"48px"},heading3:{fontSize:"24px",fontWeight:700,letterSpacing:3,lineHeight:"48px"},heading4:{fontSize:"20px",fontWeight:700,letterSpacing:3,lineHeight:"32px"},heading5:{fontSize:"18px",fontWeight:700,letterSpacing:3,lineHeight:"28px"},heading6:{fontSize:"16px",fontWeight:700,letterSpacing:3,lineHeight:"24px"},small:{fontSize:"12px",fontWeight:400,letterSpacing:5,lineHeight:"20px"},subtitle1:{fontSize:"16px",fontWeight:600,letterSpacing:3,lineHeight:"24px"},subtitle2:{fontSize:"14px",fontWeight:600,letterSpacing:5,lineHeight:"20px"}}},defaultFontFamily:"Arial",elevations:{above:{boxShadow:"0 0 12px rgba(0, 0, 0, 0.1)",zIndex:1e3},backdrop:{boxShadow:"none",zIndex:1007},flat1:{boxShadow:"0 2px 2px rgba(0, 0, 0, 0.1)",zIndex:1},flat2:{boxShadow:"0 2px 2px rgba(0, 0, 0, 0.1)",zIndex:1e3},overlay1:{boxShadow:"0 0 24px rgba(0, 0, 0, 0.1)",zIndex:1006},overlay2:{boxShadow:"0 0 24px rgba(0, 0, 0, 0.1)",zIndex:1008},popout1:{boxShadow:"0 4px 16px rgba(0, 0, 0, 0.1)",zIndex:1004},popout2:{boxShadow:"0 4px 16px rgba(0, 0, 0, 0.1)",zIndex:1005},raised:{boxShadow:"0 8px 8px rgba(0, 0, 0, 0.1)",zIndex:1002},raisedInverted1:{boxShadow:"0 -8px 8px rgba(0, 0, 0, 0.1)",zIndex:1002},raisedInverted2:{boxShadow:"0 -8px 8px rgba(0, 0, 0, 0.1)",zIndex:1003},sticky:{boxShadow:"none",zIndex:1001}},fontFaces:[],grid:{desktop:{columns:12,gutter:24,horizontalSpace:16,verticalSpace:24},desktopLarge:{columns:12,gutter:24,horizontalSpace:16,verticalSpace:24},mobile:{columns:4,gutter:16,horizontalSpace:16,verticalSpace:16},mobileLarge:{columns:4,gutter:16,horizontalSpace:16,verticalSpace:16},tablet:{columns:12,gutter:24,horizontalSpace:16,verticalSpace:24},tabletLarge:{columns:12,gutter:24,horizontalSpace:16,verticalSpace:24}},iconSize:{extra_large:"48px",large:"32px",medium:"20px",regular:"24px",small:"16px"},palette:{alert:{light:"#ffe7ca",main:"#725200"},black:"#000",dataVisualization:{highContrast:{blue:"#3970C1",blueDark:"#002039",coral:"#F95D6A",cyan:"#45CEE0",green:"#B3D849",orange:"#FFA600",orangeDark:"#FF7C43",pink:"#D12771",purple:"#A05195",purpleDark:"#665191"},lowContrast:{blue:"#96B3DE",blueDark:"#5283AB",coral:"#FCA6AD",cyan:"#BAE6FF",green:"#DEF895",orange:"#FDDFA5",orangeDark:"#FCC2A9",pink:"#E995BA",purple:"#D4BBFF",purpleDark:"#B1A2D0"}},error:{light:"#fee5e4",main:"#a72514"},gray:{dark:"#373737",light:"#d3d3d3",main:"#706f6f",megaLight:"#f4f4f4",ultraLight:"#f4f4f4"},info:{light:"#dbedfd",main:"#195f7f"},primary:{dark:"#626262",light:"#D6D6D6",main:"#7A7A7A",ultraLight:"#EDEDED"},secondary:{dark:"#303030",light:"#787878",main:"#616161",ultraLight:"#F4F4F4"},success:{light:"#dcfddb",main:"#286327"},white:"#fff"},spacingBase:8,typography:{fontSize:{L:"18px",M:"16px",S:"14px",XL:"20px",XS:"12px",XXL:"24px",XXS:"10px",XXXL:"32px",XXXXL:"48px"},fontWeight:{bold:700,light:200,normal:400,semibold:600},letterSpacing:{L:3,M:1,S:0,XL:5,XXL:8,XXXL:12},lineHeight:{L:"28px",M:"24px",S:"20px",XL:"32px",XXL:"48px",XXXL:"72px"}}}};const ue=({baseURL:e="https://elements.shipengine.com",cdnURL:a="https://cdn.packlink.com",children:t,container:r,features:s,getToken:o,headers:i,locale:n,onApiError:d,onError:l=(()=>{}),scope:p="lmnt",themeConfig:c,defaultQueryClientOptions:m})=>{const g=(({cdnURL:e})=>ce((a=>re(void 0,void 0,void 0,(function*(){return(yield pe.get(`/brand/fallback/icons/${a.toLowerCase()}.svg`,{baseURL:e,responseType:"text"})).data}))),[e]))({cdnURL:a}),u=new le(null!=c?c:ge.fallback),h={baseURL:e,cdnURL:a,container:r,features:s,getToken:o,locale:n,onError:l,scope:p,theme:u};return ie(ee,Object.assign({},h,{children:ie(ne,Object.assign({cdnUrl:a,reference:p||void 0,resolveIcon:g,theme:u},{children:ie(_,Object.assign({baseURL:e,defaultQueryClientOptions:m,getToken:o,headers:i,onApiError:d},{children:ie(ae,{children:t})}))}))}))},he=({baseURL:e,children:a,features:t})=>{const r=me((()=>new le),[]),s=se(["globalFeatures"]),o=ce((()=>"none"),[]),i={baseURL:e,cdnURL:"mockCdnUrl",getFeatures:e=>{var a;return oe(null!==(a=se([e]))&&void 0!==a?a:{},null==t?void 0:t[e])},getToken:o,globalFeatures:Object.assign(Object.assign({enabledExternalCarriers:["apc","asendia","better_trucks","canpar","chronopost","couriers_please","courierpost","dpd","hermes_germany","intelliquick_delivery","lso","ontrac","seko","ups","yodel"]},s),t.globalFeatures),onError:()=>{},scope:"lmnt",theme:r};return ie(te.Provider,Object.assign({value:i},{children:ie(de,Object.assign({theme:r},{children:ie(_,Object.assign({baseURL:e,getToken:o},{children:a}))}))}))};export{ue as ElementsProvider,he as ElementsTestProvider};
1
+ import{ShipEngine as _}from"@shipengine/react-api";export*from"@shipengine/react-api";export{y as Actions,x as ActionsMenu,A as AddFundsForm,a as AutoFundingForm,B as ButtonGroup,C as CarrierBalance,c as CarrierConnectionCard,d as CarrierIcon,e as CarrierLogo,f as CollapsiblePanel,h as CopyButton,i as Cube,D as DateRangeCombo,j as DateRangeSelect,k as DisplayTerm,E as EditBillingForm,l as ErrorFallback,F as FieldLabel,m as FormPortal,n as FundAndPurchase,H as HistoryCard,o as HistoryCardExtension,I as InlineLabel,p as ItemsBreakdown,L as LinkAction,q as Loader,P as PoweredByShipEngine,R as RateDetails,S as Section,r as SettingsCard,z as ShipFromAddressForm,t as SkeletonCarrierRow,u as Spacer,v as Spread,T as Tabs,V as VatForm,W as WalletCard,w as WarehouseForm,b as autoFundingSchema,g as getAddFundsSchema,s as styles}from"./actions-menu.js";export{C as CellFormattedDate,D as Drawer,E as ErrorState,G as GridController,b as GridFilters,a as GridFooter,u as usePager}from"./usePager.js";export{f as Field,P as Pager,S as StoryNotes,a as SuspendText}from"./suspend-text.js";import{E as ee,R as ae,a as te}from"./use-toggle.js";export{a as ElementsContext,E as ElementsContextProvider,P as Portal,R as RootPortalProvider,c as useAddressValidation,u as useCountryCodeOptions,g as useElements,d as useNestedForm,e as useRootPortal,b as useStateCodeOptions,f as useToggle}from"./use-toggle.js";export{C as Country,U as UsState,d as UsaCity,c as countries,a as countryCodes,e as euCountryCodes,p as postalCodeRegex,f as usCities,b as usStateCodes,u as usStates}from"./address.js";export{a as CarrierServices,b as ConnectExternalCarrier,p as PurchaseLabel,s as ShipmentSummary,v as VoidLabel,c as createElement}from"./use-unit-settings.js";export{l as LabelsGrid,m as ManageCarriers,b as ManageExternalCarriers,d as ManageFunding,a as ManageWarehouses,p as PaymentMethodSettings,e as SelectLabelLayout,s as ShipmentsGrid,t as ThemeCreator,T as ThemeCreatorProvider,f as TransactionHistory,c as UnitSettings,u as useThemeCreator}from"./transaction-history-element.js";export{e as extendZod}from"./zod.js";export{P as PudoType,p as useBlackboxDetection,u as useConfirmationOptions,a as useCustomsContentsOptions,b as useCustomsNonDeliveryOptions,c as useDateRangeOptions,n as useGetFundingSourceInsuranceProvider,d as useInsuranceProviderOptions,o as useManageFundingSourceInsurance,e as useMovementIndicatorOptions,f as usePackageOptions,g as useRateOptions,q as useScrubErrors,h as useServiceCodeOptions,l as useServicePoints,k as useShipFromAddressOptions,i as useShipmentMetadata,j as useShippingPresetsOptions,m as useWindsorFramework}from"./use-scrub-errors.js";export{P as PageLayoutProvider,u as useExpirationMonthOptions,a as useHelpers,b as usePageLayout}from"./use-page-layout.js";export{u as useGetServiceName}from"./use-get-service-name.js";export{u as useRunOnceOnTrue}from"./use-run-once-on-true.js";export{m as moneySchema}from"./money.js";export{p as phoneSchema,a as phoneSchemaUnvalidated}from"./phone.js";export{C as CanadaDeliveredDutyOptions}from"./canada-ddp.js";export{a as assert,r as raise}from"./assertions.js";export{g as getSellerIdFromToken,i as isOnboarded}from"./checks.js";export{b as convertDimensions,c as createDictionary,f as formatDimensions,h as getCancelledShipment,d as getIsCustomsRequiredForShipment,g as getIsInternationalShipment,e as getPendingShipment,j as getShipmentByStatus,a as isCollectionService,i as isPudoEligibleRate,m as moveCustomsItemsToProducts}from"./shipment.js";import{_ as re,g as oe,d as se}from"./carrier.js";export{P as addEmailToValidation,x as addSpaceBetweenWords,A as calculateTotal,t as capitalizeFirstLetter,u as capitalizeFirstLetterOfEachWord,y as currencySymbol,i as daysAfter,d as deepMergeFeatures,q as featureFlagComponentNameLookup,a0 as filterFundingSourceCarriers,a as findDateLocale,b as formatByDateAndLocale,B as formatCreditCardNumber,f as formatDate,c as formatDateDDMMYY,e as formatDateDDMMYYYY,C as formatExpiration,z as formatMoney,X as getCarrierIdByCarrierCode,D as getCurrencyFromString,E as getCurrencySymbolFromString,g as getDefaultFeatures,Q as getDefaultShipFromAddress,j as getExpirationYears,S as getIsShipmentUsingSavedShipFromAddress,Y as getLogoOrIconByCarrierCode,F as getRateRequiresAcknowledgement,l as getRelativeDates,R as getSavedShipFromAddressId,G as getTotalRateAmount,h as getlocaleDateStringFormat,I as isDomesticAddress,O as isEmptyAddress,W as isEvriCarrier,Z as isGlobalPostEligible,J as isMilitaryAddress,k as isNowOrInTheFuture,r as isObject,M as isPoBox,N as isPoBoxAddress,$ as isSendleEligible,K as isUnitedStatesTerritory,L as isUnsupportedByUps,U as isUpsCarrier,T as isUspsCarrier,V as isYodelCarrier,m as mostRecent,n as nextDayCutoff,o as omitTime,H as overrideCarrierCodes,p as parseLocaleDate,v as pascalize,w as replaceSpacesWithDashes,s as sortByCreationDate}from"./carrier.js";export{N as NO_VAT_COUNTRIES,k as convertDecimalWeightToFractionalWeight,j as convertFractionalWeightToDecimalWeight,h as convertPoundsAndOuncesToOunces,l as convertWeight,c as createCodedErrors,m as formatFractionalWeight,u as formatTrackingNumber,g as getCustomsFromSalesOrder,o as getDefaultWarehouse,q as getInsuranceProviderWithFriendlyName,b as getIsCustomsRequiredForSalesOrder,r as getIsInsuraceProviderAccepted,v as getIsVatRequired,d as getRequestedServices,e as getSalesOrderItemsFromSalesOrderOrShipment,p as getWarehouseById,f as isDecimalWeight,n as isFlatRatePackageCode,i as isMetricWeightUnit,a as throwAny,t as throwJoinedMessages,s as trackingStatusFormatter}from"./vat.js";export{a as aggregateRateDetailItems,c as calculateRateDetailBreakdown,b as createStyles,e as errorMap,f as formLogger,i as isString,s as scopeTheme,v as validationResolver}from"./validation.js";export{a as AccountSettings,l as LabelWorkflow,o as Onboarding}from"./wallet-form.js";import{jsx as ie}from"@emotion/react/jsx-runtime";import{useCallback as ne,useMemo as de}from"react";import{THEME_ID as le,GigerProvider as pe,GigerTestProvider as ce}from"@shipengine/giger";import{Theme as me}from"@shipengine/giger-theme";import ge from"axios";import"date-fns/isToday";import"react-hook-form";import"react-i18next";import"@emotion/react";import"lodash/isEqual";import"zod";import"copy-to-clipboard";import"js-base64";import"libphonenumber-js/min";import"lodash/omit";import"card-validator";import"react-use";import"date-fns/subDays";import"react-dom";import"lodash/merge";import"@tanstack/react-query";import"lodash/mergeWith";import"humps";import"@shipengine/js-api";import"@rjsf/core";import"@rjsf/validator-ajv8";import"lodash/camelCase";import"use-debounce";import"classnames";import"i18next";import"i18next-browser-languagedetector";import"@emotion/cache";import"stylis";import"date-fns/formatISO";import"date-fns/isSameDay";import"date-fns/isWithinInterval";import"date-fns/setHours";import"date-fns/setMinutes";import"lodash/orderBy";import"jwt-decode";import"date-fns/format";import"date-fns/locale";import"date-fns/parse";import"lodash/get";import"lodash/isNil";import"lodash/omitBy";import"@hookform/resolvers/zod";var ue={fallback:{borderRadius:{L:"16px",M:"8px",S:"4px",XL:"32px",XS:"2px"},breakPoints:{desktop:1280,mobileLarge:480,tablet:768,tabletLarge:960},card:{borderRadius:{desktop:"8px",mobile:"4px",tablet:"8px"}},components:{Button:{borderRadius:"4px"},Checkbox:{borderRadius:"2px",square:!1},Chip:{backgroundColor:"#f4f4f4",border:"none",borderRadius:"16px",color:"#706f6f",fontWeight:600,isSelected:{backgroundColor:"#EDEDED",border:"none",color:"#7A7A7A"},padding:"4px 16px"},Dialog:{action:{justifyContent:"center"},content:{padding:24,textAlign:"center"},dialog:{backgroundColor:"rgba(0, 0, 0, 0.26)",borderRadius:"4px"},header:{borderBottom:"2px solid #d3d3d3",padding:24,titleColor:"#616161"}},Field:{color:"#373737",fontWeight:700,placeholder:{fontWeight:700}},FieldContainer:{borderRadius:"4px"},Link:{activeColor:"#787878",defaultColor:"#616161",hoverColor:"#303030",isDark:{activeColor:"#787878",defaultColor:"#fff",hoverColor:"#fff",visitedColor:"#fff"},visitedColor:"#303030"},Table:{border:"none",borderRadius:"4px",boxShadow:"0 0 12px rgba(0, 0, 0, 0.1)"},Typography:{body1:{fontSize:"16px",fontWeight:400,letterSpacing:0,lineHeight:"24px"},body2:{fontSize:"14px",fontWeight:400,letterSpacing:3,lineHeight:"20px"},heading1:{fontSize:"48px",fontWeight:700,letterSpacing:0,lineHeight:"72px"},heading2:{fontSize:"32px",fontWeight:700,letterSpacing:1,lineHeight:"48px"},heading3:{fontSize:"24px",fontWeight:700,letterSpacing:3,lineHeight:"48px"},heading4:{fontSize:"20px",fontWeight:700,letterSpacing:3,lineHeight:"32px"},heading5:{fontSize:"18px",fontWeight:700,letterSpacing:3,lineHeight:"28px"},heading6:{fontSize:"16px",fontWeight:700,letterSpacing:3,lineHeight:"24px"},small:{fontSize:"12px",fontWeight:400,letterSpacing:5,lineHeight:"20px"},subtitle1:{fontSize:"16px",fontWeight:600,letterSpacing:3,lineHeight:"24px"},subtitle2:{fontSize:"14px",fontWeight:600,letterSpacing:5,lineHeight:"20px"}}},defaultFontFamily:"Arial",elevations:{above:{boxShadow:"0 0 12px rgba(0, 0, 0, 0.1)",zIndex:1e3},backdrop:{boxShadow:"none",zIndex:1007},flat1:{boxShadow:"0 2px 2px rgba(0, 0, 0, 0.1)",zIndex:1},flat2:{boxShadow:"0 2px 2px rgba(0, 0, 0, 0.1)",zIndex:1e3},overlay1:{boxShadow:"0 0 24px rgba(0, 0, 0, 0.1)",zIndex:1006},overlay2:{boxShadow:"0 0 24px rgba(0, 0, 0, 0.1)",zIndex:1008},popout1:{boxShadow:"0 4px 16px rgba(0, 0, 0, 0.1)",zIndex:1004},popout2:{boxShadow:"0 4px 16px rgba(0, 0, 0, 0.1)",zIndex:1005},raised:{boxShadow:"0 8px 8px rgba(0, 0, 0, 0.1)",zIndex:1002},raisedInverted1:{boxShadow:"0 -8px 8px rgba(0, 0, 0, 0.1)",zIndex:1002},raisedInverted2:{boxShadow:"0 -8px 8px rgba(0, 0, 0, 0.1)",zIndex:1003},sticky:{boxShadow:"none",zIndex:1001}},fontFaces:[],grid:{desktop:{columns:12,gutter:24,horizontalSpace:16,verticalSpace:24},desktopLarge:{columns:12,gutter:24,horizontalSpace:16,verticalSpace:24},mobile:{columns:4,gutter:16,horizontalSpace:16,verticalSpace:16},mobileLarge:{columns:4,gutter:16,horizontalSpace:16,verticalSpace:16},tablet:{columns:12,gutter:24,horizontalSpace:16,verticalSpace:24},tabletLarge:{columns:12,gutter:24,horizontalSpace:16,verticalSpace:24}},iconSize:{extra_large:"48px",large:"32px",medium:"20px",regular:"24px",small:"16px"},palette:{alert:{light:"#ffe7ca",main:"#725200"},black:"#000",dataVisualization:{highContrast:{blue:"#3970C1",blueDark:"#002039",coral:"#F95D6A",cyan:"#45CEE0",green:"#B3D849",orange:"#FFA600",orangeDark:"#FF7C43",pink:"#D12771",purple:"#A05195",purpleDark:"#665191"},lowContrast:{blue:"#96B3DE",blueDark:"#5283AB",coral:"#FCA6AD",cyan:"#BAE6FF",green:"#DEF895",orange:"#FDDFA5",orangeDark:"#FCC2A9",pink:"#E995BA",purple:"#D4BBFF",purpleDark:"#B1A2D0"}},error:{light:"#fee5e4",main:"#a72514"},gray:{dark:"#373737",light:"#d3d3d3",main:"#706f6f",megaLight:"#f4f4f4",ultraLight:"#f4f4f4"},info:{light:"#dbedfd",main:"#195f7f"},primary:{dark:"#626262",light:"#D6D6D6",main:"#7A7A7A",ultraLight:"#EDEDED"},secondary:{dark:"#303030",light:"#787878",main:"#616161",ultraLight:"#F4F4F4"},success:{light:"#dcfddb",main:"#286327"},white:"#fff"},spacingBase:8,typography:{fontSize:{L:"18px",M:"16px",S:"14px",XL:"20px",XS:"12px",XXL:"24px",XXS:"10px",XXXL:"32px",XXXXL:"48px"},fontWeight:{bold:700,light:200,normal:400,semibold:600},letterSpacing:{L:3,M:1,S:0,XL:5,XXL:8,XXXL:12},lineHeight:{L:"28px",M:"24px",S:"20px",XL:"32px",XXL:"48px",XXXL:"72px"}}}};const he=({baseURL:e="https://elements.shipengine.com",cdnURL:a="https://cdn.packlink.com",children:t,container:r,features:o,getToken:s,headers:i,locale:n,onApiError:d,onError:l=(()=>{}),scope:p="lmnt",themeConfig:c,defaultQueryClientOptions:m,emotionCacheShadowRootContainer:g,emotionCacheShadowRootContainerWrapper:u})=>{const h=(({cdnURL:e})=>ne((a=>re(void 0,void 0,void 0,(function*(){return(yield ge.get(`/brand/fallback/icons/${a.toLowerCase()}.svg`,{baseURL:e,responseType:"text"})).data}))),[e]))({cdnURL:a}),f=de((()=>{var e;const a=new me(null!==(e=c&&le in c?c[le]:c)&&void 0!==e?e:ue.fallback);return c&&le in c?{[le]:a}:a}),[c]),x={baseURL:e,cdnURL:a,container:r,emotionCacheShadowRootContainer:g,features:o,getToken:s,locale:n,onError:l,scope:p,theme:f};return ie(ee,Object.assign({},x,{children:ie(pe,Object.assign({cdnUrl:a,emotionCacheShadowRootContainer:g,reference:u||p||void 0,resolveIcon:h,theme:f},{children:ie(_,Object.assign({baseURL:e,defaultQueryClientOptions:m,getToken:s,headers:i,onApiError:d},{children:ie(ae,Object.assign({emotionCacheShadowRootContainer:g},{children:t}))}))}))}))},fe=({baseURL:e,children:a,features:t})=>{const r=de((()=>new me),[]),o=oe(["globalFeatures"]),s=ne((()=>"none"),[]),i={baseURL:e,cdnURL:"mockCdnUrl",getFeatures:e=>{var a;return se(null!==(a=oe([e]))&&void 0!==a?a:{},null==t?void 0:t[e])},getToken:s,globalFeatures:Object.assign(Object.assign({enabledExternalCarriers:["apc","asendia","better_trucks","canpar","chronopost","couriers_please","courierpost","dpd","hermes_germany","intelliquick_delivery","lso","ontrac","seko","ups","yodel"]},o),t.globalFeatures),onError:()=>{},scope:"lmnt",theme:r};return ie(te.Provider,Object.assign({value:i},{children:ie(ce,Object.assign({theme:r},{children:ie(_,Object.assign({baseURL:e,getToken:s},{children:a}))}))}))};export{he as ElementsProvider,fe as ElementsTestProvider};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@shipengine/elements",
3
- "version": "2.12.0",
3
+ "version": "2.13.0",
4
4
  "peerDependencies": {
5
5
  "@emotion/react": "11.x",
6
6
  "react-i18next": "11.x",
@@ -38,7 +38,7 @@
38
38
  "@shipengine/giger": "1.19.1",
39
39
  "@shipengine/giger-theme": "1.7.0",
40
40
  "@shipengine/js-api": "2.6.0",
41
- "@shipengine/react-api": "3.6.0",
41
+ "@shipengine/react-api": "3.6.2",
42
42
  "@storybook/addons": "6.5.16",
43
43
  "@storybook/api": "6.5.16",
44
44
  "@storybook/components": "7.0.0-rc.1",
@@ -22,6 +22,14 @@ export type AddFundsFormProvider = {
22
22
  * @see {@link AddFundsForm | The `<AddFundsForm />` component using these props}
23
23
  */
24
24
  export type AddFundsFormProps = {
25
+ addedFundsError?: SE.CodedError[] | null;
26
+ addFunds?: (payload: {
27
+ carrierId: string;
28
+ funds: {
29
+ amount: number;
30
+ currency: SE.Currency;
31
+ };
32
+ }) => Promise<void>;
25
33
  carrierId: string;
26
34
  children?: (addFundsForm: AddFundsFormProvider) => React.ReactElement;
27
35
  currency?: SE.Currency;
@@ -41,4 +49,4 @@ export type AddFundsFormProps = {
41
49
  *
42
50
  * @see {@link AddFundsFormProps | The props that are passed into the `<AddFundsForm />` component}
43
51
  */
44
- export declare const AddFundsForm: ({ carrierId, children, currency, onCancel, onSuccess, minimumAmount, onFail, }: AddFundsFormProps) => import("@emotion/react/jsx-runtime").JSX.Element;
52
+ export declare const AddFundsForm: ({ carrierId, children, currency, onCancel, onSuccess, minimumAmount, onFail, addFunds, addedFundsError, }: AddFundsFormProps) => import("@emotion/react/jsx-runtime").JSX.Element;
@@ -22,7 +22,7 @@ export declare const styles: {
22
22
  maxHeight: string;
23
23
  width: string;
24
24
  };
25
- carrierName: (theme: import("@shipengine/giger-theme/dist/lib/Theme").Theme) => {
25
+ carrierName: () => {
26
26
  display: "block";
27
27
  flex: string;
28
28
  };
@@ -28,6 +28,20 @@ export type CollapsiblePanelProps = WithChildrenCommonProps<{
28
28
  * within another panel and therfore should have a different background color and padding.
29
29
  */
30
30
  nested?: boolean;
31
+ statusSettings?: {
32
+ fail?: {
33
+ disabled?: boolean;
34
+ message?: string;
35
+ };
36
+ loading?: {
37
+ disabled?: boolean;
38
+ message?: string;
39
+ };
40
+ success?: {
41
+ disabled?: boolean;
42
+ message?: string;
43
+ };
44
+ };
31
45
  /**
32
46
  * `title` is an optional string that will be used to display the title of the panel.
33
47
  */
@@ -43,4 +57,4 @@ export type CollapsiblePanelProps = WithChildrenCommonProps<{
43
57
  *
44
58
  * @see {@link CollapsiblePanelProps | The props that are passed into the `<CollapsiblePanel />` component}
45
59
  */
46
- export declare const CollapsiblePanel: ({ errors, initialExpanded, isSaving, nested, children, title, }: CollapsiblePanelProps) => import("@emotion/react/jsx-runtime").JSX.Element;
60
+ export declare const CollapsiblePanel: ({ errors, initialExpanded, isSaving, nested, children, title, statusSettings, }: CollapsiblePanelProps) => import("@emotion/react/jsx-runtime").JSX.Element;
@@ -1,3 +1,5 @@
1
1
  import { IDatePickerProps } from "@shipengine/giger";
2
2
  import { ControlledField } from "../create-field-controller";
3
- export declare const DatePicker: ControlledField<IDatePickerProps<boolean>>;
3
+ export declare const DatePicker: ControlledField<IDatePickerProps<boolean> & {
4
+ placeholderText: string;
5
+ }>;
@@ -1,5 +1,6 @@
1
1
  import { SerializedStyles } from "@emotion/react";
2
2
  import { Theme } from "@shipengine/giger-theme";
3
- export declare const getAsideStyles: (theme: Theme) => SerializedStyles;
3
+ export declare const getAsideStyles: () => SerializedStyles;
4
4
  export declare const getPriceStyles: (theme: Theme) => SerializedStyles;
5
+ export declare const getTableStyles: (theme: Theme) => SerializedStyles;
5
6
  export declare const getTableCellLabelStyles: (theme: Theme) => SerializedStyles;
@@ -1,5 +1,5 @@
1
1
  import { Theme } from "@shipengine/giger-theme";
2
- export declare const rateCardFirstLineSize: (theme: Theme) => string;
2
+ export declare const getRateCardFirstLineSize: (theme: Theme) => string;
3
3
  export declare const styles: {
4
4
  acknowledgment: (theme: Theme) => {
5
5
  alignItems: "center";
@@ -1,15 +1,20 @@
1
1
  export declare const styles: {
2
2
  getCheckboxHeader: (theme: any) => {
3
- width: any;
3
+ width: number;
4
4
  };
5
5
  getFilters: (theme: any) => {
6
6
  borderBottom: string;
7
7
  padding: string;
8
8
  };
9
9
  getTableHeader: (theme: any) => {
10
- background: any;
10
+ background: string;
11
+ };
12
+ getWrapper: (theme: any) => {
13
+ border?: string | undefined;
14
+ borderRadius?: string | undefined;
15
+ boxShadow?: string | undefined;
16
+ height: string;
11
17
  };
12
- getWrapper: (theme: any) => any;
13
18
  table: {
14
19
  tableLayout: "initial";
15
20
  };
@@ -1,7 +1,7 @@
1
1
  export declare const styles: {
2
2
  getButtons: (theme: any) => {
3
3
  display: "flex";
4
- gap: any;
4
+ gap: number;
5
5
  justifyContent: "flex-end";
6
6
  };
7
7
  };
@@ -13,7 +13,7 @@ export declare const styles: {
13
13
  justifyContent: "space-between";
14
14
  rowGap: string;
15
15
  };
16
- cardContainer: (theme: import("@shipengine/giger-theme/dist/lib/Theme").Theme) => {
16
+ cardContainer: () => {
17
17
  display: "flex";
18
18
  justifyContent: "space-between";
19
19
  };
@@ -2,5 +2,19 @@ import { SE } from "@shipengine/react-api";
2
2
  export type SaveStatusProps = {
3
3
  errors?: SE.CodedError[] | null;
4
4
  isSaving?: boolean;
5
+ statusSettings?: {
6
+ fail?: {
7
+ disabled?: boolean;
8
+ message?: string;
9
+ };
10
+ loading?: {
11
+ disabled?: boolean;
12
+ message?: string;
13
+ };
14
+ success?: {
15
+ disabled?: boolean;
16
+ message?: string;
17
+ };
18
+ };
5
19
  };
6
- export declare const SaveStatus: ({ errors, isSaving }: SaveStatusProps) => import("@emotion/react/jsx-runtime").JSX.Element | null;
20
+ export declare const SaveStatus: ({ errors, isSaving, statusSettings: { loading: loadingSettings, success: successSettings, fail: failSettings }, }: SaveStatusProps) => import("@emotion/react/jsx-runtime").JSX.Element | null;
@@ -1,5 +1,5 @@
1
1
  export declare const styles: {
2
- button: (theme: import("@shipengine/giger-theme/dist/lib/Theme").Theme) => {
2
+ button: () => {
3
3
  cursor: "pointer";
4
4
  };
5
5
  codeImage: () => {
@@ -70,9 +70,9 @@ export declare const getShipmentSchema: ({ dimensionsUnit, isContentDescriptionR
70
70
  packages: z.ZodArray<z.ZodObject<{
71
71
  contentDescription: z.ZodString | z.ZodNullable<z.ZodOptional<z.ZodString>>;
72
72
  dimensions: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodObject<{
73
- height: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
74
- length: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
75
- width: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
73
+ height: z.ZodNumber | z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
74
+ length: z.ZodNumber | z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
75
+ width: z.ZodNumber | z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
76
76
  }, "strip", z.ZodTypeAny, {
77
77
  length: number;
78
78
  height: number;
@@ -95,33 +95,7 @@ export declare const getShipmentSchema: ({ dimensionsUnit, isContentDescriptionR
95
95
  length?: number | null | undefined;
96
96
  height?: number | null | undefined;
97
97
  width?: number | null | undefined;
98
- } | null | undefined> | z.ZodEffects<z.ZodObject<{
99
- height: z.ZodNumber;
100
- length: z.ZodNumber;
101
- width: z.ZodNumber;
102
- }, "strip", z.ZodTypeAny, {
103
- length: number;
104
- height: number;
105
- width: number;
106
- }, {
107
- length: number;
108
- height: number;
109
- width: number;
110
- }>, {
111
- unit: SE.DimensionUnit;
112
- girth?: number | undefined;
113
- height: number;
114
- length: number;
115
- lengthPlusGirth?: number | undefined;
116
- noThreeSidesExceed?: number | undefined;
117
- noTwoSidesExceed?: number | undefined;
118
- volume?: number | undefined;
119
- width: number;
120
- } | undefined, {
121
- length: number;
122
- height: number;
123
- width: number;
124
- }>;
98
+ } | null | undefined>;
125
99
  insuredValue: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodObject<z.extendShape<{
126
100
  amount: z.ZodNumber;
127
101
  currency: z.ZodNativeEnum<typeof SE.Currency>;
@@ -296,10 +270,6 @@ export declare const getShipmentSchema: ({ dimensionsUnit, isContentDescriptionR
296
270
  }, {
297
271
  contentDescription?: string | null | undefined;
298
272
  dimensions?: {
299
- length: number;
300
- height: number;
301
- width: number;
302
- } | {
303
273
  length?: number | null | undefined;
304
274
  height?: number | null | undefined;
305
275
  width?: number | null | undefined;
@@ -453,10 +423,6 @@ export declare const getShipmentSchema: ({ dimensionsUnit, isContentDescriptionR
453
423
  packages: {
454
424
  contentDescription?: string | null | undefined;
455
425
  dimensions?: {
456
- length: number;
457
- height: number;
458
- width: number;
459
- } | {
460
426
  length?: number | null | undefined;
461
427
  height?: number | null | undefined;
462
428
  width?: number | null | undefined;
@@ -559,9 +525,9 @@ export declare const getShipmentSchema: ({ dimensionsUnit, isContentDescriptionR
559
525
  packages: z.ZodArray<z.ZodObject<{
560
526
  contentDescription: z.ZodString | z.ZodNullable<z.ZodOptional<z.ZodString>>;
561
527
  dimensions: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodObject<{
562
- height: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
563
- length: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
564
- width: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
528
+ height: z.ZodNumber | z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
529
+ length: z.ZodNumber | z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
530
+ width: z.ZodNumber | z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
565
531
  }, "strip", z.ZodTypeAny, {
566
532
  length: number;
567
533
  height: number;
@@ -584,33 +550,7 @@ export declare const getShipmentSchema: ({ dimensionsUnit, isContentDescriptionR
584
550
  length?: number | null | undefined;
585
551
  height?: number | null | undefined;
586
552
  width?: number | null | undefined;
587
- } | null | undefined> | z.ZodEffects<z.ZodObject<{
588
- height: z.ZodNumber;
589
- length: z.ZodNumber;
590
- width: z.ZodNumber;
591
- }, "strip", z.ZodTypeAny, {
592
- length: number;
593
- height: number;
594
- width: number;
595
- }, {
596
- length: number;
597
- height: number;
598
- width: number;
599
- }>, {
600
- unit: SE.DimensionUnit;
601
- girth?: number | undefined;
602
- height: number;
603
- length: number;
604
- lengthPlusGirth?: number | undefined;
605
- noThreeSidesExceed?: number | undefined;
606
- noTwoSidesExceed?: number | undefined;
607
- volume?: number | undefined;
608
- width: number;
609
- } | undefined, {
610
- length: number;
611
- height: number;
612
- width: number;
613
- }>;
553
+ } | null | undefined>;
614
554
  insuredValue: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodObject<z.extendShape<{
615
555
  amount: z.ZodNumber;
616
556
  currency: z.ZodNativeEnum<typeof SE.Currency>;
@@ -785,10 +725,6 @@ export declare const getShipmentSchema: ({ dimensionsUnit, isContentDescriptionR
785
725
  }, {
786
726
  contentDescription?: string | null | undefined;
787
727
  dimensions?: {
788
- length: number;
789
- height: number;
790
- width: number;
791
- } | {
792
728
  length?: number | null | undefined;
793
729
  height?: number | null | undefined;
794
730
  width?: number | null | undefined;
@@ -846,9 +782,9 @@ export declare const getShipmentSchema: ({ dimensionsUnit, isContentDescriptionR
846
782
  packages: z.ZodArray<z.ZodObject<z.extendShape<{
847
783
  contentDescription: z.ZodString | z.ZodNullable<z.ZodOptional<z.ZodString>>;
848
784
  dimensions: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodObject<{
849
- height: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
850
- length: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
851
- width: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
785
+ height: z.ZodNumber | z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
786
+ length: z.ZodNumber | z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
787
+ width: z.ZodNumber | z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
852
788
  }, "strip", z.ZodTypeAny, {
853
789
  length: number;
854
790
  height: number;
@@ -871,33 +807,7 @@ export declare const getShipmentSchema: ({ dimensionsUnit, isContentDescriptionR
871
807
  length?: number | null | undefined;
872
808
  height?: number | null | undefined;
873
809
  width?: number | null | undefined;
874
- } | null | undefined> | z.ZodEffects<z.ZodObject<{
875
- height: z.ZodNumber;
876
- length: z.ZodNumber;
877
- width: z.ZodNumber;
878
- }, "strip", z.ZodTypeAny, {
879
- length: number;
880
- height: number;
881
- width: number;
882
- }, {
883
- length: number;
884
- height: number;
885
- width: number;
886
- }>, {
887
- unit: SE.DimensionUnit;
888
- girth?: number | undefined;
889
- height: number;
890
- length: number;
891
- lengthPlusGirth?: number | undefined;
892
- noThreeSidesExceed?: number | undefined;
893
- noTwoSidesExceed?: number | undefined;
894
- volume?: number | undefined;
895
- width: number;
896
- } | undefined, {
897
- length: number;
898
- height: number;
899
- width: number;
900
- }>;
810
+ } | null | undefined>;
901
811
  insuredValue: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodObject<z.extendShape<{
902
812
  amount: z.ZodNumber;
903
813
  currency: z.ZodNativeEnum<typeof SE.Currency>;
@@ -1029,9 +939,9 @@ export declare const getShipmentSchema: ({ dimensionsUnit, isContentDescriptionR
1029
939
  }>;
1030
940
  }, {
1031
941
  dimensions: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodEffects<z.ZodObject<{
1032
- height: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
1033
- length: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
1034
- width: z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
942
+ height: z.ZodNumber | z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
943
+ length: z.ZodNumber | z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
944
+ width: z.ZodNumber | z.ZodEffects<z.ZodNullable<z.ZodOptional<z.ZodNumber>>, number, number | null | undefined>;
1035
945
  }, "strip", z.ZodTypeAny, {
1036
946
  length: number;
1037
947
  height: number;
@@ -1633,10 +1543,6 @@ export declare const getShipmentSchema: ({ dimensionsUnit, isContentDescriptionR
1633
1543
  packages: {
1634
1544
  contentDescription?: string | null | undefined;
1635
1545
  dimensions?: {
1636
- length: number;
1637
- height: number;
1638
- width: number;
1639
- } | {
1640
1546
  length?: number | null | undefined;
1641
1547
  height?: number | null | undefined;
1642
1548
  width?: number | null | undefined;
@@ -49,7 +49,7 @@ export declare const styles: {
49
49
  };
50
50
  presetOption: (theme: Theme) => {
51
51
  "&:hover": {
52
- backgroundColor: "theme.palette.gray.ultraLight";
52
+ backgroundColor: "scopeTheme(theme).palette.gray.ultraLight";
53
53
  };
54
54
  backgroundColor: "transparent";
55
55
  borderRadius: string;
@@ -80,6 +80,7 @@ export declare const Element: ({ resources, ...props }: LabelsGridProps & {
80
80
  };
81
81
  errorMessages: {
82
82
  labelIdRequired: string;
83
+ request_failed_to_complete: string;
83
84
  };
84
85
  resultMessages: {
85
86
  approved: string;
@@ -91,12 +92,12 @@ export declare const Element: ({ resources, ...props }: LabelsGridProps & {
91
92
  resultTitles: {
92
93
  approved: string;
93
94
  rejected: string;
94
- }; /**
95
- * `labelStatus` is the status of the labels you wish to view.
96
- * If no value is defined, all labels will be rendered.
97
- */
95
+ };
98
96
  voidedOn: string;
99
- };
97
+ }; /**
98
+ * `onClickExternalOrderId` is an optional callback function that will be invoked when the user clicks the id number within the
99
+ * `External Order ID` column, if present.
100
+ */
100
101
  "view-shipment": {
101
102
  title: string;
102
103
  actions: {
@@ -1016,6 +1017,9 @@ export declare const Element: ({ resources, ...props }: LabelsGridProps & {
1016
1017
  tooManyCharacters: string;
1017
1018
  requiredShipmentId: string;
1018
1019
  requiredLabelId: string;
1020
+ heightExceeded: string;
1021
+ widthExceeded: string;
1022
+ lengthExceeded: string;
1019
1023
  };
1020
1024
  shippingPresets: {
1021
1025
  apply: string;
@@ -1090,7 +1094,12 @@ export declare const Element: ({ resources, ...props }: LabelsGridProps & {
1090
1094
  transactionHistory: string;
1091
1095
  adjustmentHistory: string;
1092
1096
  warehouses: string;
1093
- carriers: string;
1097
+ carriers: {
1098
+ title: string;
1099
+ customStatusMessages: {
1100
+ success: string;
1101
+ };
1102
+ };
1094
1103
  externalCarriers: string;
1095
1104
  labelLayout: string;
1096
1105
  unitSettings: string;
@@ -56,6 +56,7 @@ export declare const Element: ({ resources, ...props }: ShipEngineCarriersProps
56
56
  };
57
57
  errorMessages: {
58
58
  labelIdRequired: string;
59
+ request_failed_to_complete: string;
59
60
  };
60
61
  resultMessages: {
61
62
  approved: string;
@@ -1029,6 +1030,9 @@ export declare const Element: ({ resources, ...props }: ShipEngineCarriersProps
1029
1030
  tooManyCharacters: string;
1030
1031
  requiredShipmentId: string;
1031
1032
  requiredLabelId: string;
1033
+ heightExceeded: string;
1034
+ widthExceeded: string;
1035
+ lengthExceeded: string;
1032
1036
  };
1033
1037
  shippingPresets: {
1034
1038
  apply: string;
@@ -1103,7 +1107,12 @@ export declare const Element: ({ resources, ...props }: ShipEngineCarriersProps
1103
1107
  transactionHistory: string;
1104
1108
  adjustmentHistory: string;
1105
1109
  warehouses: string;
1106
- carriers: string;
1110
+ carriers: {
1111
+ title: string;
1112
+ customStatusMessages: {
1113
+ success: string;
1114
+ };
1115
+ };
1107
1116
  externalCarriers: string;
1108
1117
  labelLayout: string;
1109
1118
  unitSettings: string;
@@ -56,6 +56,7 @@ export declare const Element: ({ resources, ...props }: ExternalCarriersProps &
56
56
  };
57
57
  errorMessages: {
58
58
  labelIdRequired: string;
59
+ request_failed_to_complete: string;
59
60
  };
60
61
  resultMessages: {
61
62
  approved: string;
@@ -1029,6 +1030,9 @@ export declare const Element: ({ resources, ...props }: ExternalCarriersProps &
1029
1030
  tooManyCharacters: string;
1030
1031
  requiredShipmentId: string;
1031
1032
  requiredLabelId: string;
1033
+ heightExceeded: string;
1034
+ widthExceeded: string;
1035
+ lengthExceeded: string;
1032
1036
  };
1033
1037
  shippingPresets: {
1034
1038
  apply: string;
@@ -1103,7 +1107,12 @@ export declare const Element: ({ resources, ...props }: ExternalCarriersProps &
1103
1107
  transactionHistory: string;
1104
1108
  adjustmentHistory: string;
1105
1109
  warehouses: string;
1106
- carriers: string;
1110
+ carriers: {
1111
+ title: string;
1112
+ customStatusMessages: {
1113
+ success: string;
1114
+ };
1115
+ };
1107
1116
  externalCarriers: string;
1108
1117
  labelLayout: string;
1109
1118
  unitSettings: string;
@@ -33,6 +33,7 @@ export declare const Element: ({ resources, ...props }: ManageFundingProps & {
33
33
  };
34
34
  errorMessages: {
35
35
  labelIdRequired: string;
36
+ request_failed_to_complete: string;
36
37
  };
37
38
  resultMessages: {
38
39
  approved: string;
@@ -962,6 +963,9 @@ export declare const Element: ({ resources, ...props }: ManageFundingProps & {
962
963
  tooManyCharacters: string;
963
964
  requiredShipmentId: string;
964
965
  requiredLabelId: string;
966
+ heightExceeded: string;
967
+ widthExceeded: string;
968
+ lengthExceeded: string;
965
969
  };
966
970
  shippingPresets: {
967
971
  apply: string;
@@ -1036,7 +1040,12 @@ export declare const Element: ({ resources, ...props }: ManageFundingProps & {
1036
1040
  transactionHistory: string;
1037
1041
  adjustmentHistory: string;
1038
1042
  warehouses: string;
1039
- carriers: string;
1043
+ carriers: {
1044
+ title: string;
1045
+ customStatusMessages: {
1046
+ success: string;
1047
+ };
1048
+ };
1040
1049
  externalCarriers: string;
1041
1050
  labelLayout: string;
1042
1051
  unitSettings: string;
@@ -50,6 +50,7 @@ export declare const Element: ({ resources, ...props }: object & {
50
50
  };
51
51
  errorMessages: {
52
52
  labelIdRequired: string;
53
+ request_failed_to_complete: string;
53
54
  };
54
55
  resultMessages: {
55
56
  approved: string;
@@ -996,6 +997,9 @@ export declare const Element: ({ resources, ...props }: object & {
996
997
  tooManyCharacters: string;
997
998
  requiredShipmentId: string;
998
999
  requiredLabelId: string;
1000
+ heightExceeded: string;
1001
+ widthExceeded: string;
1002
+ lengthExceeded: string;
999
1003
  };
1000
1004
  shippingPresets: {
1001
1005
  apply: string;
@@ -1070,7 +1074,12 @@ export declare const Element: ({ resources, ...props }: object & {
1070
1074
  transactionHistory: string;
1071
1075
  adjustmentHistory: string;
1072
1076
  warehouses: string;
1073
- carriers: string;
1077
+ carriers: {
1078
+ title: string;
1079
+ customStatusMessages: {
1080
+ success: string;
1081
+ };
1082
+ };
1074
1083
  externalCarriers: string;
1075
1084
  labelLayout: string;
1076
1085
  unitSettings: string;