@shipengine/elements-sdk 1.0.1 → 1.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/helper.d.ts +6 -0
- package/package.json +1 -1
- package/public-sdk.d.ts +4 -24
- package/shipengine-elements-sdk.mjs +11707 -11601
- package/utils.d.ts +5 -25
package/helper.d.ts
ADDED
package/package.json
CHANGED
package/public-sdk.d.ts
CHANGED
|
@@ -1,7 +1,9 @@
|
|
|
1
|
+
import { CleanShipengineAPI } from "./utils";
|
|
1
2
|
import { ShipEngineElement } from "./shipengine-element";
|
|
2
3
|
import { ShipEngineAPIConfig } from "@shipengine/js-api";
|
|
3
4
|
import { SidePanelHeaderProps, SidePanelSDKProps } from "./elements-root";
|
|
4
5
|
import { ElementsProviderProps, PurchaseLabel, AccountSettings, LabelWorkflow, ConnectExternalCarrier, Onboarding, ShipmentSummary, VoidLabel, ManageExternalCarriers } from "@shipengine/elements";
|
|
6
|
+
import { ElementsHelper } from "./helper";
|
|
5
7
|
export type ElementsSDKOptions = Omit<ElementsProviderProps, "getToken" | "children" | "container">;
|
|
6
8
|
export type ElementProps = {
|
|
7
9
|
accountSettings: AccountSettings.ComponentProps;
|
|
@@ -25,30 +27,8 @@ export type AvailableElements = keyof ElementProps;
|
|
|
25
27
|
export declare class ElementsSDK {
|
|
26
28
|
#private;
|
|
27
29
|
constructor(getToken: ElementsProviderProps["getToken"], options?: ElementsSDKOptions, container?: HTMLElement | string);
|
|
28
|
-
getClient(token
|
|
29
|
-
|
|
30
|
-
readonly accountSettings: Omit<import("@shipengine/js-api").AccountSettingsAPI, "client">;
|
|
31
|
-
readonly accountBillingPlan: Omit<import("@shipengine/js-api/account-billing-plan").AccountBillingPlanAPI, "client">;
|
|
32
|
-
readonly addresses: Omit<import("@shipengine/js-api").AddressesAPI, "client">;
|
|
33
|
-
readonly carriers: Omit<import("@shipengine/js-api").CarriersAPI, "client">;
|
|
34
|
-
readonly connections: Omit<import("@shipengine/js-api").ConnectionsAPI, "client">;
|
|
35
|
-
readonly customPackages: Omit<import("@shipengine/js-api").CustomPackagesAPI, "client">;
|
|
36
|
-
readonly fundingSources: Omit<import("@shipengine/js-api").FundingSourcesAPI, "client">;
|
|
37
|
-
readonly insurance: Omit<import("@shipengine/js-api").InsuranceAPI, "client">;
|
|
38
|
-
readonly labels: Omit<import("@shipengine/js-api").LabelsAPI, "client">;
|
|
39
|
-
readonly orderSources: Omit<import("@shipengine/js-api").OrderSourcesAPI, "client">;
|
|
40
|
-
readonly rateCards: Omit<import("@shipengine/js-api").RateCardsAPI, "client">;
|
|
41
|
-
readonly rates: Omit<import("@shipengine/js-api").RatesAPI, "client">;
|
|
42
|
-
readonly salesOrderShipments: Omit<import("@shipengine/js-api").SalesOrderShipmentsAPI, "client">;
|
|
43
|
-
readonly salesOrders: Omit<import("@shipengine/js-api").SalesOrdersAPI, "client">;
|
|
44
|
-
readonly servicePoints: Omit<import("@shipengine/js-api").ServicePointsAPI, "client">;
|
|
45
|
-
readonly shipments: Omit<import("@shipengine/js-api").ShipmentsAPI, "client">;
|
|
46
|
-
readonly themes: Omit<import("@shipengine/js-api").ThemesAPI, "client">;
|
|
47
|
-
readonly warehouses: Omit<import("@shipengine/js-api").WarehousesAPI, "client">;
|
|
48
|
-
readonly shippingRules: Omit<import("@shipengine/js-api").ShippingRulesAPI, "client">;
|
|
49
|
-
readonly webhooks: Omit<import("@shipengine/js-api").WebhooksAPI, "client">;
|
|
50
|
-
readonly sellers: Omit<import("@shipengine/js-api").SellersAPI, "client">;
|
|
51
|
-
};
|
|
30
|
+
getClient(token?: string, config?: ShipEngineAPIConfig): CleanShipengineAPI;
|
|
31
|
+
getHelper(config?: ShipEngineAPIConfig): ElementsHelper;
|
|
52
32
|
create<Key extends AvailableElements>(type: AvailableElements, props?: any): ShipEngineElement<ElementProps[Key]>;
|
|
53
33
|
destroy(): void;
|
|
54
34
|
/**
|