@beworke/pixel-bemony 0.1.0-rc.1

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 (67) hide show
  1. package/CHANGELOG.md +157 -0
  2. package/README.md +176 -0
  3. package/RELEASE_CANDIDATE.md +37 -0
  4. package/dist/browser/index.cjs.js +2598 -0
  5. package/dist/browser/index.cjs.js.map +1 -0
  6. package/dist/browser/index.d.mts +184 -0
  7. package/dist/browser/index.d.ts +184 -0
  8. package/dist/browser/index.esm.js +2557 -0
  9. package/dist/browser/index.esm.js.map +1 -0
  10. package/dist/browser/pixel-bemony.global.js +9848 -0
  11. package/dist/browser/pixel-bemony.global.js.map +1 -0
  12. package/dist/createBemonyPixel-BGRD66p-.d.mts +474 -0
  13. package/dist/createBemonyPixel-BGRD66p-.d.ts +474 -0
  14. package/dist/index.cjs.js +2154 -0
  15. package/dist/index.cjs.js.map +1 -0
  16. package/dist/index.d.mts +320 -0
  17. package/dist/index.d.ts +320 -0
  18. package/dist/index.esm.js +2081 -0
  19. package/dist/index.esm.js.map +1 -0
  20. package/docs/BACKEND_PURCHASE_AND_REDIRECTS.md +125 -0
  21. package/docs/BROWSER_EVENT_ENRICHMENT.md +116 -0
  22. package/docs/SCENARIOS.md +92 -0
  23. package/docs/SECURITY_LIMITATIONS.md +45 -0
  24. package/docs/TEST_MATRIX.md +39 -0
  25. package/docs/TROUBLESHOOTING.md +81 -0
  26. package/examples/README.md +73 -0
  27. package/examples/browser-bootstrap.html +47 -0
  28. package/examples/checkout-price-code.html +37 -0
  29. package/examples/funnel/donsell/downsell_1.html +130 -0
  30. package/examples/funnel/donsell/downsell_2.html +130 -0
  31. package/examples/funnel/donsell/downsell_3.html +130 -0
  32. package/examples/funnel/offer-page.html +105 -0
  33. package/examples/funnel/upsell/upsell_1.html +130 -0
  34. package/examples/funnel/upsell/upsell_2.html +130 -0
  35. package/examples/funnel/upsell/upsell_3.html +139 -0
  36. package/examples/offer-page-price-code.html +22 -0
  37. package/examples/one-click-price-code.html +38 -0
  38. package/examples/security/checkout-sim.css +408 -0
  39. package/examples/security/checkout-sim.js +414 -0
  40. package/examples/security/one-click/pri_downsell_1.html +85 -0
  41. package/examples/security/one-click/pri_downsell_1a.html +85 -0
  42. package/examples/security/one-click/pri_downsell_1b.html +78 -0
  43. package/examples/security/one-click/pri_downsell_2.html +78 -0
  44. package/examples/security/one-click/pri_downsell_2a.html +78 -0
  45. package/examples/security/one-click/pri_downsell_2b.html +78 -0
  46. package/examples/security/one-click/pri_downsell_3.html +78 -0
  47. package/examples/security/one-click/pri_downsell_3a.html +78 -0
  48. package/examples/security/one-click/pri_downsell_3b.html +78 -0
  49. package/examples/security/one-click/pri_upsell_1.html +78 -0
  50. package/examples/security/one-click/pri_upsell_1a.html +78 -0
  51. package/examples/security/one-click/pri_upsell_1b.html +78 -0
  52. package/examples/security/one-click/pri_upsell_2.html +78 -0
  53. package/examples/security/one-click/pri_upsell_2a.html +78 -0
  54. package/examples/security/one-click/pri_upsell_2b.html +78 -0
  55. package/examples/security/one-click/pri_upsell_3.html +78 -0
  56. package/examples/security/one-click/pri_upsell_3a.html +78 -0
  57. package/examples/security/one-click/pri_upsell_3b.html +78 -0
  58. package/examples/security/one-click/pri_upsell_3c.html +78 -0
  59. package/examples/security/pri1766322.html +333 -0
  60. package/examples/security/pri5529930.html +333 -0
  61. package/examples/security/pri6670988.html +334 -0
  62. package/examples/security/thank-you.html +65 -0
  63. package/examples/sim/funnel-flow.js +258 -0
  64. package/examples/sim/one-click-sim.js +167 -0
  65. package/examples/upsell-price-code.html +41 -0
  66. package/examples/url-context-navigation.html +96 -0
  67. package/package.json +63 -0
@@ -0,0 +1,184 @@
1
+ import { f as CreateBemonyPixelOptions, h as BemonyPixel, F as BemonyEnvironment, a as BemonyScenario, I as BemonyPlatformOptions } from '../createBemonyPixel-BGRD66p-.mjs';
2
+ import '@beworke/pixel';
3
+ import '@beworke/pixel/events';
4
+
5
+ type BootstrapBemonyPixelOptions = CreateBemonyPixelOptions & {
6
+ /**
7
+ * Destrói a instância atual (se houver) e cria outra.
8
+ * Útil para HMR / reinit controlado.
9
+ */
10
+ force?: boolean;
11
+ /**
12
+ * Gate de consentimento. Se retornar `false`, o bootstrap aborta.
13
+ */
14
+ waitForConsent?: () => boolean | Promise<boolean>;
15
+ };
16
+ /**
17
+ * Bootstrap explícito: uma instância por `window`.
18
+ * SSR-safe no sentido de falhar com erro claro fora do browser.
19
+ */
20
+ declare function bootstrapBemonyPixel(options: BootstrapBemonyPixelOptions): Promise<BemonyPixel>;
21
+ declare function getBootstrappedBemonyPixel(): BemonyPixel | null;
22
+ /**
23
+ * Promise pendente do bootstrap atual (se houver).
24
+ */
25
+ declare function getBootstrappedBemonyPixelPending(): Promise<BemonyPixel> | null;
26
+ /**
27
+ * Destroi a instância bootstrapada (se existir) e limpa o store da window.
28
+ */
29
+ declare function destroyBootstrappedBemonyPixel(): Promise<void>;
30
+
31
+ /**
32
+ * Config global opcional (`window.BemonyPixelConfig`).
33
+ * Apenas campos públicos — sem token efêmero.
34
+ * Campos omitidos herdam `BEMONY_BROWSER_AUTO_INIT_DEFAULTS`.
35
+ */
36
+ type BemonyPixelGlobalConfig = {
37
+ environment?: BemonyEnvironment;
38
+ scenario?: BemonyScenario;
39
+ /** Parcial — campos omitidos herdam defaults oficiais. */
40
+ platform?: Partial<BemonyPlatformOptions>;
41
+ page?: CreateBemonyPixelOptions['page'];
42
+ commerce?: CreateBemonyPixelOptions['commerce'];
43
+ overrides?: CreateBemonyPixelOptions['overrides'];
44
+ autoInitiateCheckout?: boolean;
45
+ /** URL de “No Thanks” (upsell/downsell). */
46
+ noThanksUrl?: string;
47
+ };
48
+ /**
49
+ * Fontes de configuração do auto-init.
50
+ * Precedência (menor → maior): default → window-config → data-attributes → explicit.
51
+ */
52
+ type BemonyConfigSource = 'default' | 'window-config' | 'data-attributes' | 'explicit' | 'merged';
53
+ /** Atributos que nunca podem aparecer em data-* (token / segredos). */
54
+ declare const BEMONY_FORBIDDEN_DATA_ATTRIBUTES: readonly string[];
55
+ declare const SCRIPT_SELECTOR = "script[data-bemony-pixel]";
56
+ /**
57
+ * Parse de boolean em data-*.
58
+ * Aceita: true/false/1/0 e atributo vazio (= true) quando aplicável.
59
+ */
60
+ declare function parseBooleanAttr(value: string | null): boolean | undefined;
61
+ /**
62
+ * Interpreta `data-auto-init` no entry global.
63
+ * Ausência do atributo → true (auto-init por padrão).
64
+ */
65
+ declare function isAutoInitEnabledFromAttr(value: string | null | undefined): boolean;
66
+ /**
67
+ * Merge campo a campo — nunca apaga irmãos de objetos aninhados.
68
+ * Strings vazias não apagam defaults obrigatórios.
69
+ */
70
+ declare function mergeBemonyPixelOptions(base: CreateBemonyPixelOptions, overlay: Partial<CreateBemonyPixelOptions> | BemonyPixelGlobalConfig): CreateBemonyPixelOptions;
71
+ /**
72
+ * Lê overrides públicos de um elemento script (campos parciais).
73
+ * Não exige environment/scenario — ausentes usam defaults no merge.
74
+ */
75
+ declare function parseBemonyScriptAttributes(el: Element): Partial<CreateBemonyPixelOptions>;
76
+ type ResolveAutoInitConfigResult = {
77
+ options: CreateBemonyPixelOptions;
78
+ source: BemonyConfigSource;
79
+ /** Fontes que participaram do merge (menor → maior prioridade). */
80
+ sources: readonly BemonyConfigSource[];
81
+ script: Element | null;
82
+ };
83
+ type ResolveAutoInitConfigInput = {
84
+ /** Config explícita (maior precedência). */
85
+ config?: CreateBemonyPixelOptions;
86
+ /** Documento / raiz para buscar scripts (default: document). */
87
+ root?: ParentNode;
88
+ /**
89
+ * Script já resolvido (ex.: pelo entry global).
90
+ * Se omitido, tenta `resolveBemonyExecutingScript`.
91
+ */
92
+ script?: HTMLScriptElement | null;
93
+ /**
94
+ * Quando true, aplica defaults browser mesmo sem fonte.
95
+ * Default: true (auto-init com defaults oficiais).
96
+ */
97
+ applyDefaults?: boolean;
98
+ };
99
+ /**
100
+ * Resolve opções com defaults + merge campo a campo.
101
+ *
102
+ * Precedência (menor → maior):
103
+ * 1. BEMONY_BROWSER_AUTO_INIT_DEFAULTS
104
+ * 2. window.BemonyPixelConfig
105
+ * 3. atributos data-* do script executado
106
+ * 4. config explícita
107
+ */
108
+ declare function resolveAutoInitConfig(input?: ResolveAutoInitConfigInput): ResolveAutoInitConfigResult | null;
109
+
110
+ type InstallBemonyPixelAutoInitOptions = {
111
+ /**
112
+ * Config explícita (maior precedência no merge).
113
+ */
114
+ config?: CreateBemonyPixelOptions;
115
+ root?: ParentNode;
116
+ /**
117
+ * Script já resolvido (entry global). Se omitido, resolve automaticamente.
118
+ */
119
+ script?: HTMLScriptElement | null;
120
+ /**
121
+ * Gate de consentimento. Se retornar `false`, lança CONSENT_DENIED.
122
+ */
123
+ waitForConsent?: () => boolean | Promise<boolean>;
124
+ /**
125
+ * Reinit controlado (HMR).
126
+ */
127
+ force?: boolean;
128
+ /**
129
+ * Se true, não aplica defaults browser e retorna null sem fonte.
130
+ * Default: false — auto-init usa `BEMONY_BROWSER_AUTO_INIT_DEFAULTS`.
131
+ */
132
+ applyDefaults?: boolean;
133
+ /**
134
+ * @deprecated Preferir opt-out via `data-auto-init="false"` no entry global.
135
+ * Mantido por compatibilidade.
136
+ */
137
+ requireDataAutoInit?: boolean;
138
+ };
139
+ type InstallBemonyPixelAutoInitResult = {
140
+ pixel: BemonyPixel;
141
+ source: BemonyConfigSource;
142
+ };
143
+ /**
144
+ * Instalação do auto-init.
145
+ * No entry principal ESM não roda sozinha — só quando chamada (ou via IIFE global).
146
+ */
147
+ declare function installBemonyPixelAutoInit(options?: InstallBemonyPixelAutoInitOptions): Promise<InstallBemonyPixelAutoInitResult | null>;
148
+
149
+ /** Nome do arquivo do bundle IIFE global. */
150
+ declare const BEMONY_GLOBAL_BUNDLE_FILENAME: "pixel-bemony.global.js";
151
+ type ResolveBemonyExecutingScriptInput = {
152
+ /** Override de `document.currentScript` (testes). */
153
+ currentScript?: HTMLScriptElement | SVGScriptElement | null;
154
+ /** Documento / raiz para fallbacks (default: `document`). */
155
+ root?: ParentNode;
156
+ };
157
+ /**
158
+ * Verifica se o `src` do script aponta para o bundle global Bemony.
159
+ * Suporta URL absoluta, relativa, query string e hash.
160
+ */
161
+ declare function isBemonyGlobalBundleSrc(src: string | null | undefined): boolean;
162
+ /**
163
+ * Localiza o `<script>` que está executando o bundle Bemony.
164
+ *
165
+ * Prioridade:
166
+ * 1. `document.currentScript` (HTMLScriptElement)
167
+ * 2. fallback por `src` contendo `pixel-bemony.global.js`
168
+ * 3. legado `script[data-bemony-pixel]`
169
+ */
170
+ declare function resolveBemonyExecutingScript(input?: ResolveBemonyExecutingScriptInput): HTMLScriptElement | null;
171
+
172
+ type BemonyBootstrapErrorCode = 'NOT_BROWSER' | 'CONSENT_DENIED' | 'INVALID_ATTRIBUTES' | 'FORBIDDEN_ATTRIBUTE' | 'MULTIPLE_SCRIPTS' | 'AMBIGUOUS_SCRIPT' | 'SCRIPT_NOT_FOUND' | 'MISSING_CONFIG' | 'INVALID_CONFIG' | 'AUTO_INIT_DISABLED' | 'AUTO_INIT_FAILED' | 'MISSING_ENDPOINT';
173
+ declare class BemonyBootstrapError extends Error {
174
+ readonly code: BemonyBootstrapErrorCode;
175
+ readonly cause?: unknown;
176
+ constructor(message: string, code: BemonyBootstrapErrorCode, cause?: unknown);
177
+ }
178
+
179
+ declare const BEMONY_PIXEL_READY_EVENT: "bemony:pixel:ready";
180
+ declare const BEMONY_PIXEL_ERROR_EVENT: "bemony:pixel:error";
181
+ declare const BEMONY_PIXEL_INITIALIZING_EVENT: "bemony:pixel:initializing";
182
+ declare const BEMONY_PIXEL_DESTROYED_EVENT: "bemony:pixel:destroyed";
183
+
184
+ export { BEMONY_FORBIDDEN_DATA_ATTRIBUTES, BEMONY_GLOBAL_BUNDLE_FILENAME, BEMONY_PIXEL_DESTROYED_EVENT, BEMONY_PIXEL_ERROR_EVENT, BEMONY_PIXEL_INITIALIZING_EVENT, BEMONY_PIXEL_READY_EVENT, SCRIPT_SELECTOR as BEMONY_PIXEL_SCRIPT_SELECTOR, BemonyBootstrapError, type BemonyBootstrapErrorCode, type BemonyConfigSource, type BemonyPixelGlobalConfig, type BootstrapBemonyPixelOptions, type InstallBemonyPixelAutoInitOptions, type InstallBemonyPixelAutoInitResult, type ResolveAutoInitConfigInput, type ResolveAutoInitConfigResult, type ResolveBemonyExecutingScriptInput, bootstrapBemonyPixel, destroyBootstrappedBemonyPixel, getBootstrappedBemonyPixel, getBootstrappedBemonyPixelPending, installBemonyPixelAutoInit, isAutoInitEnabledFromAttr, isBemonyGlobalBundleSrc, mergeBemonyPixelOptions, parseBemonyScriptAttributes, parseBooleanAttr, resolveAutoInitConfig, resolveBemonyExecutingScript };
@@ -0,0 +1,184 @@
1
+ import { f as CreateBemonyPixelOptions, h as BemonyPixel, F as BemonyEnvironment, a as BemonyScenario, I as BemonyPlatformOptions } from '../createBemonyPixel-BGRD66p-.js';
2
+ import '@beworke/pixel';
3
+ import '@beworke/pixel/events';
4
+
5
+ type BootstrapBemonyPixelOptions = CreateBemonyPixelOptions & {
6
+ /**
7
+ * Destrói a instância atual (se houver) e cria outra.
8
+ * Útil para HMR / reinit controlado.
9
+ */
10
+ force?: boolean;
11
+ /**
12
+ * Gate de consentimento. Se retornar `false`, o bootstrap aborta.
13
+ */
14
+ waitForConsent?: () => boolean | Promise<boolean>;
15
+ };
16
+ /**
17
+ * Bootstrap explícito: uma instância por `window`.
18
+ * SSR-safe no sentido de falhar com erro claro fora do browser.
19
+ */
20
+ declare function bootstrapBemonyPixel(options: BootstrapBemonyPixelOptions): Promise<BemonyPixel>;
21
+ declare function getBootstrappedBemonyPixel(): BemonyPixel | null;
22
+ /**
23
+ * Promise pendente do bootstrap atual (se houver).
24
+ */
25
+ declare function getBootstrappedBemonyPixelPending(): Promise<BemonyPixel> | null;
26
+ /**
27
+ * Destroi a instância bootstrapada (se existir) e limpa o store da window.
28
+ */
29
+ declare function destroyBootstrappedBemonyPixel(): Promise<void>;
30
+
31
+ /**
32
+ * Config global opcional (`window.BemonyPixelConfig`).
33
+ * Apenas campos públicos — sem token efêmero.
34
+ * Campos omitidos herdam `BEMONY_BROWSER_AUTO_INIT_DEFAULTS`.
35
+ */
36
+ type BemonyPixelGlobalConfig = {
37
+ environment?: BemonyEnvironment;
38
+ scenario?: BemonyScenario;
39
+ /** Parcial — campos omitidos herdam defaults oficiais. */
40
+ platform?: Partial<BemonyPlatformOptions>;
41
+ page?: CreateBemonyPixelOptions['page'];
42
+ commerce?: CreateBemonyPixelOptions['commerce'];
43
+ overrides?: CreateBemonyPixelOptions['overrides'];
44
+ autoInitiateCheckout?: boolean;
45
+ /** URL de “No Thanks” (upsell/downsell). */
46
+ noThanksUrl?: string;
47
+ };
48
+ /**
49
+ * Fontes de configuração do auto-init.
50
+ * Precedência (menor → maior): default → window-config → data-attributes → explicit.
51
+ */
52
+ type BemonyConfigSource = 'default' | 'window-config' | 'data-attributes' | 'explicit' | 'merged';
53
+ /** Atributos que nunca podem aparecer em data-* (token / segredos). */
54
+ declare const BEMONY_FORBIDDEN_DATA_ATTRIBUTES: readonly string[];
55
+ declare const SCRIPT_SELECTOR = "script[data-bemony-pixel]";
56
+ /**
57
+ * Parse de boolean em data-*.
58
+ * Aceita: true/false/1/0 e atributo vazio (= true) quando aplicável.
59
+ */
60
+ declare function parseBooleanAttr(value: string | null): boolean | undefined;
61
+ /**
62
+ * Interpreta `data-auto-init` no entry global.
63
+ * Ausência do atributo → true (auto-init por padrão).
64
+ */
65
+ declare function isAutoInitEnabledFromAttr(value: string | null | undefined): boolean;
66
+ /**
67
+ * Merge campo a campo — nunca apaga irmãos de objetos aninhados.
68
+ * Strings vazias não apagam defaults obrigatórios.
69
+ */
70
+ declare function mergeBemonyPixelOptions(base: CreateBemonyPixelOptions, overlay: Partial<CreateBemonyPixelOptions> | BemonyPixelGlobalConfig): CreateBemonyPixelOptions;
71
+ /**
72
+ * Lê overrides públicos de um elemento script (campos parciais).
73
+ * Não exige environment/scenario — ausentes usam defaults no merge.
74
+ */
75
+ declare function parseBemonyScriptAttributes(el: Element): Partial<CreateBemonyPixelOptions>;
76
+ type ResolveAutoInitConfigResult = {
77
+ options: CreateBemonyPixelOptions;
78
+ source: BemonyConfigSource;
79
+ /** Fontes que participaram do merge (menor → maior prioridade). */
80
+ sources: readonly BemonyConfigSource[];
81
+ script: Element | null;
82
+ };
83
+ type ResolveAutoInitConfigInput = {
84
+ /** Config explícita (maior precedência). */
85
+ config?: CreateBemonyPixelOptions;
86
+ /** Documento / raiz para buscar scripts (default: document). */
87
+ root?: ParentNode;
88
+ /**
89
+ * Script já resolvido (ex.: pelo entry global).
90
+ * Se omitido, tenta `resolveBemonyExecutingScript`.
91
+ */
92
+ script?: HTMLScriptElement | null;
93
+ /**
94
+ * Quando true, aplica defaults browser mesmo sem fonte.
95
+ * Default: true (auto-init com defaults oficiais).
96
+ */
97
+ applyDefaults?: boolean;
98
+ };
99
+ /**
100
+ * Resolve opções com defaults + merge campo a campo.
101
+ *
102
+ * Precedência (menor → maior):
103
+ * 1. BEMONY_BROWSER_AUTO_INIT_DEFAULTS
104
+ * 2. window.BemonyPixelConfig
105
+ * 3. atributos data-* do script executado
106
+ * 4. config explícita
107
+ */
108
+ declare function resolveAutoInitConfig(input?: ResolveAutoInitConfigInput): ResolveAutoInitConfigResult | null;
109
+
110
+ type InstallBemonyPixelAutoInitOptions = {
111
+ /**
112
+ * Config explícita (maior precedência no merge).
113
+ */
114
+ config?: CreateBemonyPixelOptions;
115
+ root?: ParentNode;
116
+ /**
117
+ * Script já resolvido (entry global). Se omitido, resolve automaticamente.
118
+ */
119
+ script?: HTMLScriptElement | null;
120
+ /**
121
+ * Gate de consentimento. Se retornar `false`, lança CONSENT_DENIED.
122
+ */
123
+ waitForConsent?: () => boolean | Promise<boolean>;
124
+ /**
125
+ * Reinit controlado (HMR).
126
+ */
127
+ force?: boolean;
128
+ /**
129
+ * Se true, não aplica defaults browser e retorna null sem fonte.
130
+ * Default: false — auto-init usa `BEMONY_BROWSER_AUTO_INIT_DEFAULTS`.
131
+ */
132
+ applyDefaults?: boolean;
133
+ /**
134
+ * @deprecated Preferir opt-out via `data-auto-init="false"` no entry global.
135
+ * Mantido por compatibilidade.
136
+ */
137
+ requireDataAutoInit?: boolean;
138
+ };
139
+ type InstallBemonyPixelAutoInitResult = {
140
+ pixel: BemonyPixel;
141
+ source: BemonyConfigSource;
142
+ };
143
+ /**
144
+ * Instalação do auto-init.
145
+ * No entry principal ESM não roda sozinha — só quando chamada (ou via IIFE global).
146
+ */
147
+ declare function installBemonyPixelAutoInit(options?: InstallBemonyPixelAutoInitOptions): Promise<InstallBemonyPixelAutoInitResult | null>;
148
+
149
+ /** Nome do arquivo do bundle IIFE global. */
150
+ declare const BEMONY_GLOBAL_BUNDLE_FILENAME: "pixel-bemony.global.js";
151
+ type ResolveBemonyExecutingScriptInput = {
152
+ /** Override de `document.currentScript` (testes). */
153
+ currentScript?: HTMLScriptElement | SVGScriptElement | null;
154
+ /** Documento / raiz para fallbacks (default: `document`). */
155
+ root?: ParentNode;
156
+ };
157
+ /**
158
+ * Verifica se o `src` do script aponta para o bundle global Bemony.
159
+ * Suporta URL absoluta, relativa, query string e hash.
160
+ */
161
+ declare function isBemonyGlobalBundleSrc(src: string | null | undefined): boolean;
162
+ /**
163
+ * Localiza o `<script>` que está executando o bundle Bemony.
164
+ *
165
+ * Prioridade:
166
+ * 1. `document.currentScript` (HTMLScriptElement)
167
+ * 2. fallback por `src` contendo `pixel-bemony.global.js`
168
+ * 3. legado `script[data-bemony-pixel]`
169
+ */
170
+ declare function resolveBemonyExecutingScript(input?: ResolveBemonyExecutingScriptInput): HTMLScriptElement | null;
171
+
172
+ type BemonyBootstrapErrorCode = 'NOT_BROWSER' | 'CONSENT_DENIED' | 'INVALID_ATTRIBUTES' | 'FORBIDDEN_ATTRIBUTE' | 'MULTIPLE_SCRIPTS' | 'AMBIGUOUS_SCRIPT' | 'SCRIPT_NOT_FOUND' | 'MISSING_CONFIG' | 'INVALID_CONFIG' | 'AUTO_INIT_DISABLED' | 'AUTO_INIT_FAILED' | 'MISSING_ENDPOINT';
173
+ declare class BemonyBootstrapError extends Error {
174
+ readonly code: BemonyBootstrapErrorCode;
175
+ readonly cause?: unknown;
176
+ constructor(message: string, code: BemonyBootstrapErrorCode, cause?: unknown);
177
+ }
178
+
179
+ declare const BEMONY_PIXEL_READY_EVENT: "bemony:pixel:ready";
180
+ declare const BEMONY_PIXEL_ERROR_EVENT: "bemony:pixel:error";
181
+ declare const BEMONY_PIXEL_INITIALIZING_EVENT: "bemony:pixel:initializing";
182
+ declare const BEMONY_PIXEL_DESTROYED_EVENT: "bemony:pixel:destroyed";
183
+
184
+ export { BEMONY_FORBIDDEN_DATA_ATTRIBUTES, BEMONY_GLOBAL_BUNDLE_FILENAME, BEMONY_PIXEL_DESTROYED_EVENT, BEMONY_PIXEL_ERROR_EVENT, BEMONY_PIXEL_INITIALIZING_EVENT, BEMONY_PIXEL_READY_EVENT, SCRIPT_SELECTOR as BEMONY_PIXEL_SCRIPT_SELECTOR, BemonyBootstrapError, type BemonyBootstrapErrorCode, type BemonyConfigSource, type BemonyPixelGlobalConfig, type BootstrapBemonyPixelOptions, type InstallBemonyPixelAutoInitOptions, type InstallBemonyPixelAutoInitResult, type ResolveAutoInitConfigInput, type ResolveAutoInitConfigResult, type ResolveBemonyExecutingScriptInput, bootstrapBemonyPixel, destroyBootstrappedBemonyPixel, getBootstrappedBemonyPixel, getBootstrappedBemonyPixelPending, installBemonyPixelAutoInit, isAutoInitEnabledFromAttr, isBemonyGlobalBundleSrc, mergeBemonyPixelOptions, parseBemonyScriptAttributes, parseBooleanAttr, resolveAutoInitConfig, resolveBemonyExecutingScript };