@moonbase.sh/storefront 0.2.86 → 0.2.106

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.
@@ -1,3 +1,5 @@
1
+ import { InjectionKey } from 'vue';
2
+
1
3
  declare type DeepPartial<T> = T extends object ? {
2
4
  [P in keyof T]?: T[P] extends HTMLElement | undefined ? T[P] : DeepPartial<T[P]>;
3
5
  } : T;
@@ -11,6 +13,7 @@ declare class MoonbaseImpl implements MoonbaseInstance {
11
13
  private storefront;
12
14
  private options;
13
15
  setup(url: string, options?: DeepPartial<MoonbaseOptions>): Promise<void>;
16
+ configure(options: DeepPartial<MoonbaseOptions>): void;
14
17
  sign_in(parameters?: MoonbaseIntentArgs['sign_in']): void;
15
18
  sign_up(parameters?: MoonbaseIntentArgs['sign_up']): void;
16
19
  forgot_password(parameters?: MoonbaseIntentArgs['forgot_password']): void;
@@ -21,6 +24,7 @@ declare class MoonbaseImpl implements MoonbaseInstance {
21
24
  view_account(): void;
22
25
  view_products(): void;
23
26
  redeem_voucher(parameters?: MoonbaseIntentArgs['redeem_voucher']): void;
27
+ view_product(parameters?: MoonbaseIntentArgs['view_product']): void;
24
28
  download_product(parameters?: MoonbaseIntentArgs['download_product']): void;
25
29
  activate_product(parameters?: MoonbaseIntentArgs['activate_product']): void;
26
30
  view_cart(): void;
@@ -32,6 +36,7 @@ declare class MoonbaseImpl implements MoonbaseInstance {
32
36
 
33
37
  export declare type MoonbaseInstance = MoonbaseInstanceIntents & {
34
38
  setup: (url: string, options: DeepPartial<MoonbaseOptions>) => Promise<void>;
39
+ configure: (options: DeepPartial<MoonbaseOptions>) => void;
35
40
  };
36
41
 
37
42
  declare type MoonbaseInstanceIntents = {
@@ -49,6 +54,7 @@ export declare enum MoonbaseIntent {
49
54
  ViewAccount = "view_account",
50
55
  ViewProducts = "view_products",
51
56
  RedeemVoucher = "redeem_voucher",
57
+ ViewProduct = "view_product",
52
58
  DownloadProduct = "download_product",
53
59
  ActivateProduct = "activate_product",
54
60
  ViewCart = "view_cart",
@@ -89,6 +95,10 @@ export declare interface MoonbaseIntentArgs {
89
95
  [MoonbaseIntent.RedeemVoucher]: {
90
96
  code?: string;
91
97
  };
98
+ [MoonbaseIntent.ViewProduct]: {
99
+ product_id: string;
100
+ version?: string;
101
+ };
92
102
  [MoonbaseIntent.DownloadProduct]: {
93
103
  product_id: string;
94
104
  version?: string;
@@ -128,7 +138,22 @@ declare interface MoonbaseOptions {
128
138
  checkout: {
129
139
  redirect: boolean;
130
140
  };
141
+ theme: {
142
+ colors: {
143
+ primary: Record<number, string>;
144
+ background: 'white' | 'gray';
145
+ };
146
+ fonts: {
147
+ heading: 'Poppins' | 'PT Serif' | 'Montserrat' | 'Aleo';
148
+ body: 'Inter' | 'Roboto' | 'EB Garamond' | 'Merriweather';
149
+ };
150
+ corners: 'sharp' | 'soft' | 'round';
151
+ buttons: 'a' | 'b' | 'c';
152
+ cards: 'outlined' | 'shadow' | 'white';
153
+ };
131
154
  target: HTMLElement | undefined;
132
155
  }
133
156
 
157
+ export declare const urlKey: InjectionKey<string>;
158
+
134
159
  export { }