Skip to content

Commit

Permalink
Unified type for shipping line
Browse files Browse the repository at this point in the history
  • Loading branch information
js-goupil committed Jan 23, 2025
1 parent 7745cd9 commit 4fc6a64
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 16 deletions.
6 changes: 1 addition & 5 deletions packages/ui-extensions/src/surfaces/point-of-sale/api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -93,11 +93,7 @@ export type {
Address,
} from './types/cart';

export type {
ShippingLine,
CalculatedShippingLine,
CustomShippingLine,
} from './types/shipping-line';
export type {ShippingLine} from './types/shipping-line';

export type {TaxLine} from './types/tax-line';

Expand Down
Original file line number Diff line number Diff line change
@@ -1,14 +1,7 @@
export type ShippingLine = CalculatedShippingLine | CustomShippingLine;

export interface CalculatedShippingLine {
export interface ShippingLine {
handle: string;
price: string;
title: string;
methodType: 'SHIPPING' | 'RETAIL';
type: 'Calculated';
}

export interface CustomShippingLine {
price: string;
title: string;
type: 'Custom';
methodType: 'SHIPPING' | 'RETAIL' | undefined;
type: 'Calculated' | 'Custom';
}

0 comments on commit 4fc6a64

Please sign in to comment.