@ticketlayer/elements 0.2.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 (195) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +55 -0
  3. package/dist/cjs/index-DfzcrE9-.js +3598 -0
  4. package/dist/cjs/index.cjs.js +16 -0
  5. package/dist/cjs/loader.cjs.js +12 -0
  6. package/dist/cjs/order-summary-ZMkJ5bez.js +116 -0
  7. package/dist/cjs/sdk-connector-ClDF3013.js +108 -0
  8. package/dist/cjs/ticketlayer-elements.cjs.js +24 -0
  9. package/dist/cjs/tl-buy-modal.cjs.entry.js +127 -0
  10. package/dist/cjs/tl-buy-tickets-button.cjs.entry.js +131 -0
  11. package/dist/cjs/tl-buy-tickets-wrapper.cjs.entry.js +58 -0
  12. package/dist/cjs/tl-cart-badge.cjs.entry.js +109 -0
  13. package/dist/cjs/tl-cart-drawer.cjs.entry.js +67 -0
  14. package/dist/cjs/tl-cart.cjs.entry.js +148 -0
  15. package/dist/cjs/tl-checkout-wrapper.cjs.entry.js +57 -0
  16. package/dist/cjs/tl-event-card.cjs.entry.js +140 -0
  17. package/dist/cjs/tl-event-list.cjs.entry.js +80 -0
  18. package/dist/cjs/tl-login.cjs.entry.js +184 -0
  19. package/dist/cjs/tl-my-orders.cjs.entry.js +123 -0
  20. package/dist/cjs/tl-occurrence-selector_2.cjs.entry.js +754 -0
  21. package/dist/cjs/tl-order-confirmation.cjs.entry.js +146 -0
  22. package/dist/cjs/tl-order-tickets_2.cjs.entry.js +3198 -0
  23. package/dist/cjs/tl-promo-code.cjs.entry.js +75 -0
  24. package/dist/cjs/tl-seat-map.cjs.entry.js +147 -0
  25. package/dist/collection/collection-manifest.json +29 -0
  26. package/dist/collection/components/tl-buy-modal/tl-buy-modal.css +264 -0
  27. package/dist/collection/components/tl-buy-modal/tl-buy-modal.js +249 -0
  28. package/dist/collection/components/tl-buy-tickets-button/tl-buy-tickets-button.css +120 -0
  29. package/dist/collection/components/tl-buy-tickets-button/tl-buy-tickets-button.js +412 -0
  30. package/dist/collection/components/tl-buy-tickets-wrapper/tl-buy-tickets-wrapper.css +23 -0
  31. package/dist/collection/components/tl-buy-tickets-wrapper/tl-buy-tickets-wrapper.js +192 -0
  32. package/dist/collection/components/tl-cart/tl-cart.css +251 -0
  33. package/dist/collection/components/tl-cart/tl-cart.js +314 -0
  34. package/dist/collection/components/tl-cart-badge/tl-cart-badge.css +138 -0
  35. package/dist/collection/components/tl-cart-badge/tl-cart-badge.js +217 -0
  36. package/dist/collection/components/tl-cart-drawer/tl-cart-drawer.css +98 -0
  37. package/dist/collection/components/tl-cart-drawer/tl-cart-drawer.js +185 -0
  38. package/dist/collection/components/tl-checkout-wrapper/tl-checkout-wrapper.css +23 -0
  39. package/dist/collection/components/tl-checkout-wrapper/tl-checkout-wrapper.js +148 -0
  40. package/dist/collection/components/tl-event-card/event-card-adapter.js +23 -0
  41. package/dist/collection/components/tl-event-card/tl-event-card.css +175 -0
  42. package/dist/collection/components/tl-event-card/tl-event-card.js +205 -0
  43. package/dist/collection/components/tl-event-list/tl-event-list.css +134 -0
  44. package/dist/collection/components/tl-event-list/tl-event-list.js +171 -0
  45. package/dist/collection/components/tl-login/tl-login.css +133 -0
  46. package/dist/collection/components/tl-login/tl-login.js +309 -0
  47. package/dist/collection/components/tl-my-orders/tl-my-orders.css +204 -0
  48. package/dist/collection/components/tl-my-orders/tl-my-orders.js +221 -0
  49. package/dist/collection/components/tl-occurrence-selector/tl-occurrence-selector.css +658 -0
  50. package/dist/collection/components/tl-occurrence-selector/tl-occurrence-selector.js +707 -0
  51. package/dist/collection/components/tl-order-confirmation/tl-order-confirmation.css +176 -0
  52. package/dist/collection/components/tl-order-confirmation/tl-order-confirmation.js +298 -0
  53. package/dist/collection/components/tl-order-tickets/tl-order-tickets.css +30 -0
  54. package/dist/collection/components/tl-order-tickets/tl-order-tickets.js +122 -0
  55. package/dist/collection/components/tl-promo-code/tl-promo-code.css +106 -0
  56. package/dist/collection/components/tl-promo-code/tl-promo-code.js +181 -0
  57. package/dist/collection/components/tl-seat-map/tl-seat-map.css +85 -0
  58. package/dist/collection/components/tl-seat-map/tl-seat-map.js +366 -0
  59. package/dist/collection/components/tl-ticket/tl-ticket.css +90 -0
  60. package/dist/collection/components/tl-ticket/tl-ticket.js +129 -0
  61. package/dist/collection/components/tl-ticket-selector/tl-ticket-selector.css +205 -0
  62. package/dist/collection/components/tl-ticket-selector/tl-ticket-selector.js +332 -0
  63. package/dist/collection/index.js +10 -0
  64. package/dist/collection/utils/order-summary.js +101 -0
  65. package/dist/collection/utils/sdk-connector.js +100 -0
  66. package/dist/collection/utils/testing/mock-sdk.js +95 -0
  67. package/dist/components/index.d.ts +35 -0
  68. package/dist/components/index.js +1 -0
  69. package/dist/components/order-summary.js +1 -0
  70. package/dist/components/sdk-connector.js +1 -0
  71. package/dist/components/tl-buy-modal.d.ts +11 -0
  72. package/dist/components/tl-buy-modal.js +1 -0
  73. package/dist/components/tl-buy-tickets-button.d.ts +11 -0
  74. package/dist/components/tl-buy-tickets-button.js +1 -0
  75. package/dist/components/tl-buy-tickets-wrapper.d.ts +11 -0
  76. package/dist/components/tl-buy-tickets-wrapper.js +1 -0
  77. package/dist/components/tl-buy-tickets-wrapper2.js +1 -0
  78. package/dist/components/tl-cart-badge.d.ts +11 -0
  79. package/dist/components/tl-cart-badge.js +1 -0
  80. package/dist/components/tl-cart-drawer.d.ts +11 -0
  81. package/dist/components/tl-cart-drawer.js +1 -0
  82. package/dist/components/tl-cart.d.ts +11 -0
  83. package/dist/components/tl-cart.js +1 -0
  84. package/dist/components/tl-cart2.js +1 -0
  85. package/dist/components/tl-checkout-wrapper.d.ts +11 -0
  86. package/dist/components/tl-checkout-wrapper.js +1 -0
  87. package/dist/components/tl-checkout-wrapper2.js +1 -0
  88. package/dist/components/tl-event-card.d.ts +11 -0
  89. package/dist/components/tl-event-card.js +1 -0
  90. package/dist/components/tl-event-card2.js +1 -0
  91. package/dist/components/tl-event-list.d.ts +11 -0
  92. package/dist/components/tl-event-list.js +1 -0
  93. package/dist/components/tl-login.d.ts +11 -0
  94. package/dist/components/tl-login.js +1 -0
  95. package/dist/components/tl-login2.js +1 -0
  96. package/dist/components/tl-my-orders.d.ts +11 -0
  97. package/dist/components/tl-my-orders.js +1 -0
  98. package/dist/components/tl-occurrence-selector.d.ts +11 -0
  99. package/dist/components/tl-occurrence-selector.js +1 -0
  100. package/dist/components/tl-occurrence-selector2.js +1 -0
  101. package/dist/components/tl-order-confirmation.d.ts +11 -0
  102. package/dist/components/tl-order-confirmation.js +1 -0
  103. package/dist/components/tl-order-tickets.d.ts +11 -0
  104. package/dist/components/tl-order-tickets.js +1 -0
  105. package/dist/components/tl-order-tickets2.js +1 -0
  106. package/dist/components/tl-promo-code.d.ts +11 -0
  107. package/dist/components/tl-promo-code.js +1 -0
  108. package/dist/components/tl-seat-map.d.ts +11 -0
  109. package/dist/components/tl-seat-map.js +1 -0
  110. package/dist/components/tl-ticket-selector.d.ts +11 -0
  111. package/dist/components/tl-ticket-selector.js +1 -0
  112. package/dist/components/tl-ticket-selector2.js +1 -0
  113. package/dist/components/tl-ticket.d.ts +11 -0
  114. package/dist/components/tl-ticket.js +1 -0
  115. package/dist/components/tl-ticket2.js +1 -0
  116. package/dist/elements.docs.d.ts +454 -0
  117. package/dist/elements.docs.json +3008 -0
  118. package/dist/esm/index-Ba-RZTFI.js +3588 -0
  119. package/dist/esm/index.js +4 -0
  120. package/dist/esm/loader.js +10 -0
  121. package/dist/esm/order-summary-BGekdjN9.js +103 -0
  122. package/dist/esm/sdk-connector-CqhvfyKV.js +102 -0
  123. package/dist/esm/ticketlayer-elements.js +20 -0
  124. package/dist/esm/tl-buy-modal.entry.js +125 -0
  125. package/dist/esm/tl-buy-tickets-button.entry.js +129 -0
  126. package/dist/esm/tl-buy-tickets-wrapper.entry.js +56 -0
  127. package/dist/esm/tl-cart-badge.entry.js +107 -0
  128. package/dist/esm/tl-cart-drawer.entry.js +65 -0
  129. package/dist/esm/tl-cart.entry.js +146 -0
  130. package/dist/esm/tl-checkout-wrapper.entry.js +55 -0
  131. package/dist/esm/tl-event-card.entry.js +138 -0
  132. package/dist/esm/tl-event-list.entry.js +78 -0
  133. package/dist/esm/tl-login.entry.js +182 -0
  134. package/dist/esm/tl-my-orders.entry.js +121 -0
  135. package/dist/esm/tl-occurrence-selector_2.entry.js +751 -0
  136. package/dist/esm/tl-order-confirmation.entry.js +144 -0
  137. package/dist/esm/tl-order-tickets_2.entry.js +3195 -0
  138. package/dist/esm/tl-promo-code.entry.js +73 -0
  139. package/dist/esm/tl-seat-map.entry.js +145 -0
  140. package/dist/index.cjs.js +1 -0
  141. package/dist/index.js +1 -0
  142. package/dist/ticketlayer-elements/index.esm.js +1 -0
  143. package/dist/ticketlayer-elements/p-0291df4c.entry.js +1 -0
  144. package/dist/ticketlayer-elements/p-10f01a1f.entry.js +1 -0
  145. package/dist/ticketlayer-elements/p-11273f8f.entry.js +1 -0
  146. package/dist/ticketlayer-elements/p-340ab4f5.entry.js +1 -0
  147. package/dist/ticketlayer-elements/p-41d22d7c.entry.js +1 -0
  148. package/dist/ticketlayer-elements/p-82752e3b.entry.js +1 -0
  149. package/dist/ticketlayer-elements/p-976770f3.entry.js +1 -0
  150. package/dist/ticketlayer-elements/p-9a903ff6.entry.js +1 -0
  151. package/dist/ticketlayer-elements/p-9c9072c8.entry.js +1 -0
  152. package/dist/ticketlayer-elements/p-9d8163d6.entry.js +1 -0
  153. package/dist/ticketlayer-elements/p-BGekdjN9.js +1 -0
  154. package/dist/ticketlayer-elements/p-Ba-RZTFI.js +2 -0
  155. package/dist/ticketlayer-elements/p-CqhvfyKV.js +1 -0
  156. package/dist/ticketlayer-elements/p-a5c90b68.entry.js +1 -0
  157. package/dist/ticketlayer-elements/p-b6d479ad.entry.js +1 -0
  158. package/dist/ticketlayer-elements/p-dd43f015.entry.js +1 -0
  159. package/dist/ticketlayer-elements/p-eb640760.entry.js +1 -0
  160. package/dist/ticketlayer-elements/p-ee3aa227.entry.js +1 -0
  161. package/dist/ticketlayer-elements/p-fb9444c4.entry.js +1 -0
  162. package/dist/ticketlayer-elements/ticketlayer-elements.css +1 -0
  163. package/dist/ticketlayer-elements/ticketlayer-elements.esm.js +1 -0
  164. package/dist/types/components/tl-buy-modal/tl-buy-modal.d.ts +54 -0
  165. package/dist/types/components/tl-buy-tickets-button/tl-buy-tickets-button.d.ts +61 -0
  166. package/dist/types/components/tl-buy-tickets-wrapper/tl-buy-tickets-wrapper.d.ts +52 -0
  167. package/dist/types/components/tl-cart/tl-cart.d.ts +80 -0
  168. package/dist/types/components/tl-cart-badge/tl-cart-badge.d.ts +36 -0
  169. package/dist/types/components/tl-cart-drawer/tl-cart-drawer.d.ts +35 -0
  170. package/dist/types/components/tl-checkout-wrapper/tl-checkout-wrapper.d.ts +39 -0
  171. package/dist/types/components/tl-event-card/event-card-adapter.d.ts +23 -0
  172. package/dist/types/components/tl-event-card/tl-event-card.d.ts +55 -0
  173. package/dist/types/components/tl-event-list/tl-event-list.d.ts +30 -0
  174. package/dist/types/components/tl-login/tl-login.d.ts +59 -0
  175. package/dist/types/components/tl-my-orders/tl-my-orders.d.ts +39 -0
  176. package/dist/types/components/tl-occurrence-selector/tl-occurrence-selector.d.ts +208 -0
  177. package/dist/types/components/tl-order-confirmation/tl-order-confirmation.d.ts +54 -0
  178. package/dist/types/components/tl-order-tickets/tl-order-tickets.d.ts +21 -0
  179. package/dist/types/components/tl-promo-code/tl-promo-code.d.ts +39 -0
  180. package/dist/types/components/tl-seat-map/tl-seat-map.d.ts +68 -0
  181. package/dist/types/components/tl-ticket/tl-ticket.d.ts +28 -0
  182. package/dist/types/components/tl-ticket-selector/tl-ticket-selector.d.ts +78 -0
  183. package/dist/types/components.d.ts +1629 -0
  184. package/dist/types/index.d.ts +14 -0
  185. package/dist/types/stencil-public-runtime.d.ts +1839 -0
  186. package/dist/types/utils/order-summary.d.ts +67 -0
  187. package/dist/types/utils/sdk-connector.d.ts +113 -0
  188. package/dist/types/utils/testing/mock-sdk.d.ts +36 -0
  189. package/elements.catalogue.json +968 -0
  190. package/loader/cdn.js +1 -0
  191. package/loader/index.cjs.js +1 -0
  192. package/loader/index.d.ts +24 -0
  193. package/loader/index.es2017.js +1 -0
  194. package/loader/index.js +2 -0
  195. package/package.json +101 -0
@@ -0,0 +1,67 @@
1
+ /**
2
+ * Shared helpers for the order-facing components (tl-order-confirmation,
3
+ * tl-my-orders). The sales order view carries line items, totals and tickets
4
+ * but no event name, occurrence date or customer email, so these derive what
5
+ * they can from the order and resolve the rest through the SDK.
6
+ */
7
+ import type { TicketlayerSDK } from './sdk-connector';
8
+ export interface TlOrderItem {
9
+ name: string;
10
+ description?: string | null;
11
+ type?: string;
12
+ quantity: number;
13
+ unitPrice: number | string;
14
+ subtotal: number | string;
15
+ }
16
+ export interface TlOrderTicketRef {
17
+ id: string;
18
+ name: string;
19
+ eventOccurrenceId: string | null;
20
+ }
21
+ export interface TlOrderData {
22
+ id: string;
23
+ orderNumber: string;
24
+ status: string;
25
+ paymentStatus?: string;
26
+ currency: string;
27
+ items: TlOrderItem[];
28
+ subtotal: number | string;
29
+ totalFees?: number | string;
30
+ totalTax?: number | string;
31
+ totalDiscounts?: number | string;
32
+ total: number | string;
33
+ tickets?: TlOrderTicketRef[];
34
+ createdAt?: string;
35
+ eventName?: string | null;
36
+ customerEmail?: string | null;
37
+ customer?: {
38
+ email?: string | null;
39
+ } | null;
40
+ }
41
+ export interface TlResolvedOccurrence {
42
+ eventId: string;
43
+ eventName: string;
44
+ startsAt: string | null;
45
+ }
46
+ /** Money arrives as minor-unit integers or decimal strings ("50.00"). */
47
+ export declare function formatPrice(value: number | string | null | undefined, currency?: string): string;
48
+ export declare function formatDateTime(iso: string): string;
49
+ export declare function formatDate(iso: string): string;
50
+ /** Line items that are tickets (fees, taxes and discounts have their own type). */
51
+ export declare function ticketItems(order: TlOrderData): TlOrderItem[];
52
+ export declare function ticketCount(order: TlOrderData): number;
53
+ /** Event name as the order view exposes it: the first ticket line's name. */
54
+ export declare function orderEventName(order: TlOrderData): string | null;
55
+ export declare function orderCustomerEmail(order: TlOrderData | null, customer: unknown): string | null;
56
+ export declare function statusLabel(status: string | undefined): string;
57
+ export type StatusTone = 'success' | 'info' | 'warning' | 'error' | 'muted';
58
+ export declare function statusTone(status: string | undefined): StatusTone;
59
+ export declare function errorMessage(err: unknown, fallback: string): string;
60
+ /** True for the "not signed in" family of API errors (401/403, NO_SESSION, NOT_AUTHENTICATED). */
61
+ export declare function isAuthError(err: unknown): boolean;
62
+ /**
63
+ * Find the event and start time for an occurrence id. The order view only
64
+ * carries the occurrence id, so this walks the channel's listings (cached by
65
+ * live-api) until one owns the occurrence. Best effort: null when not found.
66
+ */
67
+ export declare function resolveOccurrence(sdk: TicketlayerSDK, occurrenceId: string, maxEvents?: number): Promise<TlResolvedOccurrence | null>;
@@ -0,0 +1,113 @@
1
+ /**
2
+ * SDK Connector
3
+ *
4
+ * Utility to connect external SDK instances to Elements components.
5
+ */
6
+ export interface ModalOptions {
7
+ occurrenceId?: string;
8
+ onComplete?: (order: OrderResult) => void;
9
+ onError?: (error: Error) => void;
10
+ onClose?: () => void;
11
+ }
12
+ export interface OrderResult {
13
+ orderId: string;
14
+ orderNumber: string;
15
+ }
16
+ interface EventContext {
17
+ openModal(options?: ModalOptions): void;
18
+ }
19
+ interface CheckoutWithModal {
20
+ openModal(options?: ModalOptions): void;
21
+ closeModal(): void;
22
+ }
23
+ interface CartManager {
24
+ get(): Promise<unknown>;
25
+ on(event: string, callback: (data: unknown) => void): () => void;
26
+ off(event: string, callback: (data: unknown) => void): void;
27
+ addItem(ticketTypeId: string, quantity: number, occurrenceId: string): Promise<unknown>;
28
+ addItems(items: Array<{
29
+ ticketTypeId: string;
30
+ quantity: number;
31
+ occurrenceId: string;
32
+ }>): Promise<unknown>;
33
+ removeItem(itemId: string): Promise<unknown>;
34
+ addSeat(seatId: string, ticketTypeId: string, occurrenceId: string): Promise<unknown>;
35
+ removeSeat(seatId: string, occurrenceId: string): Promise<unknown>;
36
+ }
37
+ export interface SDKCustomer {
38
+ id: string;
39
+ email: string;
40
+ firstName?: string | null;
41
+ lastName?: string | null;
42
+ }
43
+ export interface AuthManager {
44
+ readonly customer: unknown | null;
45
+ readonly authenticated: boolean;
46
+ requestMagicLink(contact: {
47
+ email?: string;
48
+ phone?: string;
49
+ }): Promise<unknown>;
50
+ exchange(code: string): Promise<unknown>;
51
+ logout(): Promise<void>;
52
+ }
53
+ export interface PresaleRedemption {
54
+ benefit: string;
55
+ alreadyHeld: boolean;
56
+ }
57
+ export interface PresaleManager {
58
+ redeem(code: string): Promise<PresaleRedemption>;
59
+ }
60
+ export interface TicketlayerSDK {
61
+ getEventsManager(): {
62
+ list(options?: {
63
+ limit?: number;
64
+ category?: string;
65
+ }): Promise<{
66
+ items: unknown[];
67
+ }>;
68
+ get(id: string): Promise<unknown>;
69
+ getTicketTypes(eventId: string, occurrenceId: string): Promise<unknown[]>;
70
+ };
71
+ on(event: string, callback: (data: unknown) => void): () => void;
72
+ off(event: string, callback: (data: unknown) => void): void;
73
+ /** Get an event context for fluent API (e.g., sdk.event('evt_xxx').openModal()) */
74
+ event(eventId: string): EventContext;
75
+ /** Checkout accessor with modal support */
76
+ checkout: CheckoutWithModal;
77
+ /** Cart manager accessor */
78
+ getCartManager(): CartManager;
79
+ /** Orders accessor (my-orders, single order with tickets, ticket PDF). */
80
+ getOrdersManager?(): {
81
+ mine(): Promise<unknown>;
82
+ get(orderId: string): Promise<unknown>;
83
+ ticketPdf(orderId: string, passId: string): Promise<Blob>;
84
+ };
85
+ /** Magic-link auth accessor (tl-login, tl-my-orders). Optional on older SDKs. */
86
+ getAuthManager?(): AuthManager;
87
+ /** Presale / promo code accessor (tl-promo-code). Optional on older SDKs. */
88
+ getPresaleManager?(): PresaleManager;
89
+ /** Close any open modal */
90
+ closeModal(): void;
91
+ }
92
+ /**
93
+ * Manually install an SDK/connector instance (escape hatch). The normal path is
94
+ * for the host to call createLiveClient(), which auto-publishes on the registry.
95
+ */
96
+ export declare function setSDK(sdk: TicketlayerSDK): void;
97
+ /**
98
+ * Get the SDK instance synchronously. Throws if not yet available - prefer
99
+ * whenSDK() in lifecycle methods so mounting before Live is ready isn't an error.
100
+ */
101
+ export declare function getSDK(): TicketlayerSDK;
102
+ /** True if a client is currently registered. */
103
+ export declare function hasSDK(): boolean;
104
+ /**
105
+ * Resolve when the SDK is available - immediately if Live is already up, else
106
+ * on the `ticketlayer:ready` event. Replaces busy-wait polling in components.
107
+ */
108
+ export declare function whenSDK(timeoutMs?: number): Promise<TicketlayerSDK>;
109
+ /**
110
+ * Subscribe to SDK events (waits for the SDK, returns an unsubscribe function).
111
+ */
112
+ export declare function onSDKEvent(event: string, callback: (data: unknown) => void): () => void;
113
+ export {};
@@ -0,0 +1,36 @@
1
+ /**
2
+ * Mock SDK for spec tests. Installs a connector-shaped object on the manual
3
+ * slot the sdk-connector reads, with an in-memory bus so tests can push
4
+ * SDK events (cart:updated, auth:changed, checkout:completed) at components.
5
+ */
6
+ import { type TicketlayerSDK } from '../sdk-connector';
7
+ export interface MockSDK extends TicketlayerSDK {
8
+ emit(event: string, payload?: unknown): void;
9
+ authState: {
10
+ customer: unknown | null;
11
+ authenticated: boolean;
12
+ };
13
+ }
14
+ export interface MockSDKOptions {
15
+ events?: Partial<ReturnType<TicketlayerSDK['getEventsManager']>>;
16
+ cart?: Partial<ReturnType<TicketlayerSDK['getCartManager']>>;
17
+ orders?: Partial<NonNullable<ReturnType<NonNullable<TicketlayerSDK['getOrdersManager']>>>>;
18
+ auth?: Partial<NonNullable<ReturnType<NonNullable<TicketlayerSDK['getAuthManager']>>>>;
19
+ presale?: Partial<NonNullable<ReturnType<NonNullable<TicketlayerSDK['getPresaleManager']>>>>;
20
+ authState?: {
21
+ customer: unknown | null;
22
+ authenticated: boolean;
23
+ };
24
+ /** Leave the auth accessor off to simulate an older SDK. */
25
+ withoutAuth?: boolean;
26
+ /** Leave the presale accessor off to simulate an older SDK. */
27
+ withoutPresale?: boolean;
28
+ }
29
+ export declare function createMockSDK(opts?: MockSDKOptions): MockSDK;
30
+ /** Install a mock on the connector's manual slot; returns it for assertions. */
31
+ export declare function installMockSDK(opts?: MockSDKOptions): MockSDK;
32
+ export declare function clearMockSDK(): void;
33
+ /** Let pending promise chains settle before re-rendering. */
34
+ export declare function flush(page: {
35
+ waitForChanges(): Promise<void>;
36
+ }, rounds?: number): Promise<void>;