@magicfeedback/popup-sdk 1.13.0 → 1.15.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.
- package/README.md +6 -1
- package/dist/assets/assets/style.css +1 -1
- package/dist/{chunk-GXEPYT33.mjs → chunk-C7VD3HY4.mjs} +2 -2
- package/dist/{chunk-GXEPYT33.mjs.map → chunk-C7VD3HY4.mjs.map} +1 -1
- package/dist/{chunk-TSORXOQG.mjs → chunk-GUJSOVS6.mjs} +2 -2
- package/dist/{chunk-TSORXOQG.mjs.map → chunk-GUJSOVS6.mjs.map} +1 -1
- package/dist/index.d.mts +16 -3
- package/dist/index.d.ts +16 -3
- package/dist/index.js +389 -355
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +22 -73
- package/dist/index.mjs.map +1 -1
- package/dist/react-native.d.mts +16 -3
- package/dist/react-native.d.ts +16 -3
- package/dist/react-native.js +63 -124
- package/dist/react-native.js.map +1 -1
- package/dist/react-native.mjs +22 -73
- package/dist/react-native.mjs.map +1 -1
- package/dist/{renderPopup-KSZJ5AN4.mjs → renderPopup-CHWH3KHR.mjs} +368 -283
- package/dist/renderPopup-CHWH3KHR.mjs.map +1 -0
- package/dist/{renderPopup-JF6IB6HL.mjs → renderPopup-RWSU5Y2H.mjs} +42 -52
- package/dist/renderPopup-RWSU5Y2H.mjs.map +1 -0
- package/package.json +2 -2
- package/dist/renderPopup-JF6IB6HL.mjs.map +0 -1
- package/dist/renderPopup-KSZJ5AN4.mjs.map +0 -1
package/dist/index.d.ts
CHANGED
|
@@ -332,6 +332,15 @@ interface DeepdotsInitParams {
|
|
|
332
332
|
* en vez de cambiar los defaults que comparten todos los clientes.
|
|
333
333
|
*/
|
|
334
334
|
surveyCss?: string;
|
|
335
|
+
/**
|
|
336
|
+
* Nonce de la Content-Security-Policy de la página, para hosts con una CSP estricta
|
|
337
|
+
* (`style-src 'nonce-…'` sin `'unsafe-inline'`). El popup lo pone en cada `<style>` que
|
|
338
|
+
* inyecta en el `<head>` (hoja del survey, spinner, responsive, `surveyCss`, `@font-face`);
|
|
339
|
+
* sin él el navegador las bloquea y el survey sale sin estilos. Debe ser el MISMO nonce de
|
|
340
|
+
* la cabecera CSP de esa respuesta (en Angular, el token `CSP_NONCE`). Solo web: en React
|
|
341
|
+
* Native el survey vive en su propio WebView y no le afecta la CSP del host.
|
|
342
|
+
*/
|
|
343
|
+
cspNonce?: string;
|
|
335
344
|
}
|
|
336
345
|
interface DeepdotsConfig {
|
|
337
346
|
/** API key for authentication */
|
|
@@ -508,6 +517,12 @@ interface PopupRenderOptions {
|
|
|
508
517
|
* (`formData.lang[0]`) en cuanto este carga, y ambos los pisa `actions.*.label` de la API.
|
|
509
518
|
*/
|
|
510
519
|
language?: string;
|
|
520
|
+
/**
|
|
521
|
+
* Nonce de la Content-Security-Policy del host (`DeepdotsInitParams.cspNonce`). Se pone en
|
|
522
|
+
* cada `<style>` que inyecta el popup DOM; sin él, una CSP con `style-src 'nonce-…'` bloquea
|
|
523
|
+
* la hoja del survey. No aplica a React Native (el survey vive en su propio WebView).
|
|
524
|
+
*/
|
|
525
|
+
cspNonce?: string;
|
|
511
526
|
}
|
|
512
527
|
interface PopupRenderer {
|
|
513
528
|
/** Preparar recursos si aplica */
|
|
@@ -727,7 +742,6 @@ declare class DeepdotsPopups {
|
|
|
727
742
|
private renderer;
|
|
728
743
|
/** Logger para el output de debug. Default `console`; el host puede inyectar el suyo en init(). */
|
|
729
744
|
private logger;
|
|
730
|
-
private popupContainer;
|
|
731
745
|
private popupDefinitions;
|
|
732
746
|
private popupsLoaded;
|
|
733
747
|
/**
|
|
@@ -752,6 +766,7 @@ declare class DeepdotsPopups {
|
|
|
752
766
|
private showProgressBar;
|
|
753
767
|
/** CSS del host inyectado al final de los estilos del popup. */
|
|
754
768
|
private surveyCss;
|
|
769
|
+
private cspNonce;
|
|
755
770
|
/** Identidad + sesión (Fase 1 tracking). Null hasta init(). */
|
|
756
771
|
private tracking;
|
|
757
772
|
/** Capa de analytics (canal separado del feedback). Null hasta init(). */
|
|
@@ -1064,8 +1079,6 @@ declare class DeepdotsPopups {
|
|
|
1064
1079
|
on(eventType: DeepdotsEventType, listener: EventListener): void;
|
|
1065
1080
|
/** Remove an event listener */
|
|
1066
1081
|
off(eventType: DeepdotsEventType, listener: EventListener): void;
|
|
1067
|
-
/** Setup popup container element */
|
|
1068
|
-
private setupPopupContainer;
|
|
1069
1082
|
/** Render the popup UI */
|
|
1070
1083
|
private renderPopup;
|
|
1071
1084
|
/** Hide the popup */
|