@wayke-se/ecom-web 2.1.1 → 2.1.2

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/dist/App.d.ts CHANGED
@@ -24,7 +24,6 @@ declare class App {
24
24
  private readonly props;
25
25
  private view;
26
26
  private stageOrderList;
27
- private readonly cdnMedia?;
28
27
  private readonly contexts;
29
28
  private marketCode;
30
29
  constructor(props: AppProps);
@@ -4,7 +4,6 @@ interface ItemTileLargeProps {
4
4
  vehicle?: IOrderVehicle;
5
5
  order?: OrderOptions;
6
6
  meta?: string;
7
- cdnMedia?: string;
8
7
  }
9
- declare const ItemTileLarge: ({ vehicle, order, meta, cdnMedia }: ItemTileLargeProps) => string;
8
+ declare const ItemTileLarge: ({ vehicle, order, meta }: ItemTileLargeProps) => string;
10
9
  export default ItemTileLarge;
@@ -3,7 +3,6 @@ import { Vehicle } from '../@types/Vehicle';
3
3
  interface ItemTileSmallProps {
4
4
  vehicle?: Vehicle;
5
5
  order?: OrderOptions;
6
- cdnMedia?: string;
7
6
  }
8
- declare const ItemTileSmall: ({ vehicle, order, cdnMedia }: ItemTileSmallProps) => string;
7
+ declare const ItemTileSmall: ({ vehicle, order }: ItemTileSmallProps) => string;
9
8
  export default ItemTileSmall;
@@ -1 +1,17 @@
1
- export declare const toCdnMedia: (url: string, cdn?: string) => string;
1
+ interface WaykeImageOptions {
2
+ /** Width in px; must be one of cfit/v3's widths (48, 64, 225, 800, …). */
3
+ width?: number;
4
+ /**
5
+ * Leave unset for photos (cfit/v3 negotiates webp/jpeg from Accept). `png` for logos:
6
+ * it keeps a transparent logo transparent and a JPEG stays JPEG.
7
+ */
8
+ format?: 'png' | 'webp';
9
+ }
10
+ /**
11
+ * A Wayke media image (blob storage, a CDN's /media or /cfit) as cfit/v3 on the CDN.
12
+ * `/media/<id>?w=` went to the legacy resizer and blob storage served the original
13
+ * straight from storage; both are being retired. Any other URL is returned as is.
14
+ */
15
+ export declare function waykeImage(url: string, options?: WaykeImageOptions): string;
16
+ export declare function waykeImage(url: string | null | undefined, options?: WaykeImageOptions): string | null | undefined;
17
+ export {};
@@ -3,7 +3,6 @@ import HtmlNode from '../../Components/Extension/HtmlNode';
3
3
  import { WaykeStore } from '../../Redux/store';
4
4
  interface MainProps {
5
5
  readonly store: WaykeStore;
6
- cdnMedia?: string;
7
6
  marketCode: MarketCode;
8
7
  }
9
8
  declare class Main extends HtmlNode {
@@ -6,7 +6,6 @@ interface PreviewProps {
6
6
  readonly store: WaykeStore;
7
7
  readonly stageOrderList: StageMapKeys[];
8
8
  readonly vehicle?: Vehicle;
9
- readonly cdnMedia?: string;
10
9
  }
11
10
  declare class Preview extends HtmlNode {
12
11
  private readonly props;
@@ -2,7 +2,6 @@ import StackNode from '../../Components/Extension/StackNode';
2
2
  import { WaykeStore } from '../../Redux/store';
3
3
  interface OrderProps {
4
4
  readonly store: WaykeStore;
5
- readonly cdnMedia?: string;
6
5
  }
7
6
  declare class Order extends StackNode {
8
7
  private readonly props;
@@ -3,7 +3,6 @@ import HtmlNode from '../../Components/Extension/HtmlNode';
3
3
  import { WaykeStore } from '../../Redux/store';
4
4
  interface SummaryProps {
5
5
  readonly store: WaykeStore;
6
- readonly cdnMedia?: string;
7
6
  readonly onClose: () => void;
8
7
  readonly marketCode: MarketCode;
9
8
  }