@tranzakpackage/cards-core 0.0.0-stage → 2.0.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 CHANGED
@@ -1,3 +1,11 @@
1
- # Temporary Holding Version
1
+ # Tranzak Cards - web core
2
2
 
3
- This version is a temporary placeholder for this package. An operational version to replace this has been submitted for review and is awaiting a staged release.
3
+ Show a Tranzak virtual card inside your own page. The sensitive values (number, CVC, PIN) stay in isolated Tranzak iframes and never touch your page.
4
+
5
+ ```bash
6
+ npm install @tranzakpackage/cards-core
7
+ ```
8
+
9
+ Full documentation and API reference: https://docs.tranzak.co (Cards section).
10
+
11
+ Proprietary software of Lomotec LLC. All rights reserved.
package/package.json CHANGED
@@ -1,6 +1,25 @@
1
1
  {
2
2
  "name": "@tranzakpackage/cards-core",
3
- "version": "0.0.0-stage",
4
- "stub": true,
5
- "description": "Temporary package placeholder for staged publishing"
6
- }
3
+ "version": "2.0.0",
4
+ "description": "Tranzak Cards for the web: show a virtual card inside your own page. Sensitive values stay in isolated Tranzak iframes.",
5
+ "type": "module",
6
+ "main": "src/index.js",
7
+ "module": "src/index.js",
8
+ "types": "src/index.d.ts",
9
+ "exports": {
10
+ ".": {
11
+ "types": "./src/index.d.ts",
12
+ "default": "./src/index.js"
13
+ }
14
+ },
15
+ "sideEffects": false,
16
+ "license": "UNLICENSED",
17
+ "files": [
18
+ "src",
19
+ "README.md"
20
+ ],
21
+ "publishConfig": {
22
+ "access": "public"
23
+ },
24
+ "homepage": "https://docs.tranzak.co"
25
+ }
package/src/index.d.ts ADDED
@@ -0,0 +1,53 @@
1
+ export interface InlineWidget {
2
+ layout: 'inline';
3
+ vault_url: string;
4
+ field_urls: { number: string; expiry: string; cvc: string };
5
+ expires_at?: string;
6
+ origin?: string;
7
+ }
8
+
9
+ export interface FramedWidget {
10
+ layout?: 'framed';
11
+ url: string;
12
+ expires_at?: string;
13
+ origin?: string;
14
+ }
15
+
16
+ /** Only non-sensitive information: never the number, the CVC, the expiry date or the PIN. */
17
+ export interface PublicCardState {
18
+ last4: string | null;
19
+ brand: 'mastercard' | 'visa';
20
+ holder: string | null;
21
+ status: string;
22
+ balance: number;
23
+ currency: string;
24
+ revealed: boolean;
25
+ }
26
+
27
+ export interface MountOptions {
28
+ /** Where to display the card: a CSS selector or an element. */
29
+ container: string | Element;
30
+ /** The `widget` object returned by your server (POST /api/cards/v1/cards/{id}/widget-sessions). */
31
+ widget?: InlineWidget | FramedWidget;
32
+ /** Older format: the URL of a single iframe. */
33
+ url?: string;
34
+ onReady?: () => void;
35
+ onFrozen?: () => void;
36
+ onUnfrozen?: () => void;
37
+ onResize?: (e: { height: number }) => void;
38
+ onStateChange?: (state: PublicCardState) => void;
39
+ /** `code` such as session_expired, pin_locked, timeout. Never card data. */
40
+ onError?: (e: { code: string }) => void;
41
+ }
42
+
43
+ export interface MountedCard {
44
+ layout: 'inline' | 'framed';
45
+ iframes: Record<string, HTMLIFrameElement>;
46
+ destroy(): void;
47
+ }
48
+
49
+ export const VERSION: string;
50
+ export function mount(options: MountOptions): MountedCard;
51
+ export function parseWidgetUrl(url: string, expectedPrefix: string): URL | null;
52
+ declare const _default: { version: string; mount: typeof mount };
53
+ export default _default;
package/src/index.js ADDED
@@ -0,0 +1,312 @@
1
+ /*!
2
+ * Tranzak Cards, web core.
3
+ *
4
+ * const widget = TranzakCards.mount({ container: '#card', widget: apiWidgetObject, onFrozen() {} });
5
+ *
6
+ * Deux dispositions, selon ce que votre serveur a demandé (`layout`) :
7
+ *
8
+ * - "inline" (recommandé) : la carte est DESSINÉE DANS VOTRE PAGE, directement dans la zone que vous lui réservez.
9
+ * Seules les zones sensibles sont de petites iframes hébergées par Tranzak : le numéro, l'expiration, le CVC et la
10
+ * saisie du PIN. Les valeurs sensibles ne passent jamais dans le JavaScript de votre site : le navigateur isole les
11
+ * iframes d'une autre origine, donc aucun script de votre page (publicité, analytics, faille) ne peut les lire.
12
+ * Votre page ne reçoit que des informations non sensibles : 4 derniers chiffres, titulaire, solde, statut.
13
+ * - "framed" : une seule iframe contient toute la carte.
14
+ *
15
+ * Ce script n'a accès à AUCUNE donnée de carte. Les messages ne sont acceptés que de nos iframes et de l'origine exacte
16
+ * du widget.
17
+ */
18
+
19
+ export const VERSION = '2.0.0';
20
+
21
+ const MAX_WIDTH = 420;
22
+ const SLOW_MS = 10000;
23
+ const HIDDEN = 'position:absolute;top:0;left:0;visibility:hidden;pointer-events:none;';
24
+
25
+ function el(tag, css) {
26
+ const e = document.createElement(tag);
27
+ if (css) e.style.cssText = css;
28
+ return e;
29
+ }
30
+
31
+ /** URL d'un widget Tranzak : https (http pour un poste local), chemin attendu. */
32
+ export function parseWidgetUrl(url, expectedPrefix) {
33
+ let u;
34
+ try { u = new URL(url, typeof window !== 'undefined' ? window.location.href : undefined); } catch { return null; }
35
+ const local = u.hostname === 'localhost' || u.hostname === '127.0.0.1';
36
+ if (!(u.protocol === 'https:' || (u.protocol === 'http:' && local))) return null;
37
+ if (!u.pathname.startsWith(expectedPrefix)) return null;
38
+ return u;
39
+ }
40
+
41
+ function frame(src, title, css) {
42
+ const f = el('iframe', css);
43
+ f.title = title;
44
+ f.setAttribute('allow', ''); // aucune permission du navigateur
45
+ f.setAttribute('referrerpolicy', 'no-referrer');
46
+ f.setAttribute('scrolling', 'no');
47
+ f.setAttribute('sandbox', 'allow-scripts allow-same-origin'); // ni formulaire, ni popup, ni navigation du site
48
+ f.src = src;
49
+ return f;
50
+ }
51
+
52
+ // -- Disposition « inline » : carte dans la page ---------------------------------------------------------------------
53
+
54
+ const CSS = `
55
+ :host { display:block; }
56
+ .root { --u:4px; --ink:#000; --paper:#fff; --soft:#5f6368; --line:#d0d0d0; --r:16px; --font:-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Helvetica,Arial,sans-serif;
57
+ position:relative; width:100%; max-width:${MAX_WIDTH}px; margin:0 auto; color:var(--ink); font-family:var(--font); }
58
+ .root[data-theme="dark"] { --ink:#fff; --paper:#000; --soft:#a8a8a8; --line:#3a3a3a; }
59
+ .root[data-radius="none"] { --r:0px; } .root[data-radius="sm"] { --r:8px; } .root[data-radius="lg"] { --r:26px; }
60
+ .root[data-font="serif"] { --font:Georgia,"Times New Roman",serif; } .root[data-font="mono"] { --font:ui-monospace,SFMono-Regular,Menlo,Consolas,monospace; }
61
+ * { box-sizing:border-box; }
62
+ .face { position:relative; width:100%; aspect-ratio:1.586 / 1; background:var(--paper); color:var(--ink); border:max(1.5px, calc(var(--u) * .5)) solid var(--ink); border-radius:var(--r); padding:calc(var(--u) * 6); display:flex; flex-direction:column; justify-content:space-between; overflow:hidden; transition:opacity .2s, filter .2s; }
63
+ .face.frozen { border-style:dashed; filter:grayscale(1); opacity:.6; }
64
+ .top { display:flex; justify-content:space-between; align-items:center; gap:8px; }
65
+ .chip { width:calc(var(--u) * 11); height:calc(var(--u) * 8); border:1.5px solid var(--ink); border-radius:calc(var(--u) * 1.6); position:relative; flex:none; }
66
+ .chip::before { content:""; position:absolute; left:0; right:0; top:50%; border-top:1.5px solid var(--ink); }
67
+ .chip::after { content:""; position:absolute; top:0; bottom:0; left:50%; border-left:1.5px solid var(--ink); }
68
+ .status { font-size:max(9px, calc(var(--u) * 2.9)); font-weight:700; letter-spacing:.08em; text-transform:uppercase; border:1.5px solid var(--ink); border-radius:999px; padding:calc(var(--u) * .8) calc(var(--u) * 2.4); white-space:nowrap; }
69
+ .face.frozen .status { background:var(--ink); color:var(--paper); }
70
+ .numslot { position:relative; height:calc(var(--u) * 9); }
71
+ .bottom { display:flex; align-items:flex-end; gap:calc(var(--u) * 3); min-width:0; }
72
+ .cols { flex:1; display:flex; gap:calc(var(--u) * 3); min-width:0; align-items:flex-end; }
73
+ .col { min-width:0; } .col.h { flex:5; } .col.e { flex:3; } .col.c { flex:3; }
74
+ .lbl { display:block; font-size:max(7px, calc(var(--u) * 2.3)); text-transform:uppercase; letter-spacing:.09em; color:var(--soft); font-weight:600; }
75
+ .val { display:block; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; font-size:max(9px, calc(var(--u) * 3.3)); font-weight:600; }
76
+ .slot { height:calc(var(--u) * 5.6); position:relative; }
77
+ .slot iframe, .numslot iframe { position:absolute; inset:0; width:100%; height:100%; border:0; background:transparent; }
78
+ .brand { flex:none; width:calc(var(--u) * 15.5); line-height:0; }
79
+ .brand svg { width:100%; height:auto; display:none; }
80
+ .root[data-brand="mastercard"] .mc, .root[data-brand="visa"] .visa { display:block; }
81
+ .info { display:flex; justify-content:space-between; align-items:baseline; gap:12px; margin:14px 0 0; font-size:.9rem; color:var(--soft); }
82
+ .info strong { color:var(--ink); font-size:1rem; }
83
+ .skel { color:transparent !important; user-select:none; border-radius:6px; background:linear-gradient(90deg, var(--line) 25%, rgba(128,128,128,.3) 37%, var(--line) 63%); background-size:400% 100%; animation:tzc-shimmer 1.3s ease-in-out infinite; }
84
+ .bar { position:absolute; left:0; bottom:0; height:max(3px, calc(var(--u) * .9)); width:38%; background:var(--ink); animation:tzc-slide 1.1s ease-in-out infinite; display:none; }
85
+ .face.busy .bar { display:block; }
86
+ .vault { margin-top:10px; }
87
+ .notice { margin-top:12px; font-size:.9rem; line-height:1.45; font-weight:600; text-align:center; }
88
+ .hidden { display:none !important; }
89
+ @keyframes tzc-shimmer { 0% { background-position:100% 50%; } 100% { background-position:0 50%; } }
90
+ @keyframes tzc-slide { 0% { transform:translateX(-100%); } 100% { transform:translateX(265%); } }
91
+ @media (prefers-reduced-motion: reduce) { .skel { animation:none; } .bar { animation:none; width:100%; opacity:.35; } }
92
+ `;
93
+
94
+ // Gabarit STATIQUE : aucune valeur dynamique n'y est insérée. Les valeurs sont écrites ensuite avec textContent.
95
+ const TEMPLATE = `
96
+ <div class="root" data-theme="light" data-radius="md" data-font="system" data-brand="mastercard">
97
+ <div class="face" part="face">
98
+ <div class="top"><span class="chip" aria-hidden="true"></span><span class="status skel" data-r="status">ACTIVE</span></div>
99
+ <div class="numslot" data-r="number"></div>
100
+ <div class="bottom">
101
+ <div class="cols">
102
+ <div class="col h"><span class="lbl">Titulaire</span><span class="val skel" data-r="holder">LUCIEN GILOT</span></div>
103
+ <div class="col e"><span class="lbl">Expire</span><div class="slot" data-r="expiry"></div></div>
104
+ <div class="col c"><span class="lbl">CVC</span><div class="slot" data-r="cvc"></div></div>
105
+ </div>
106
+ <span class="brand" aria-hidden="true">
107
+ <svg class="mc" viewBox="0 0 48 30" role="img" aria-label="Mastercard"><circle cx="16" cy="15" r="14" fill="#EB001B"/><circle cx="32" cy="15" r="14" fill="#F79E1B"/><path d="M24 3.5A14 14 0 0 1 24 26.5A14 14 0 0 1 24 3.5z" fill="#FF5F00"/></svg>
108
+ <svg class="visa" viewBox="0 0 48 30" role="img" aria-label="Visa"><text x="24" y="21" text-anchor="middle" font-family="Arial,Helvetica,sans-serif" font-size="17" font-weight="800" font-style="italic" letter-spacing="-.5" fill="currentColor">VISA</text></svg>
109
+ </span>
110
+ </div>
111
+ <div class="bar" data-r="bar"></div>
112
+ </div>
113
+ <div class="info"><span>Solde disponible</span><strong class="skel" data-r="balance">$00.00 USD</strong></div>
114
+ <div class="notice hidden" data-r="notice" role="alert"></div>
115
+ <div class="vault" data-r="vault"></div>
116
+ </div>`;
117
+
118
+ const STYLE_OK = {
119
+ theme: ['light', 'dark'],
120
+ radius: ['none', 'sm', 'md', 'lg'],
121
+ font: ['system', 'serif', 'mono'],
122
+ };
123
+
124
+ function mountInline(options, container) {
125
+ const w = options.widget;
126
+ const vaultUrl = parseWidgetUrl(w.vault_url, '/widget/controls/');
127
+ if (!vaultUrl) throw new Error('TranzakCards.mount: URL du vault invalide');
128
+ const widgetOrigin = vaultUrl.origin;
129
+
130
+ const fieldUrls = {};
131
+ for (const f of ['number', 'expiry', 'cvc']) {
132
+ const u = parseWidgetUrl(w.field_urls && w.field_urls[f], '/widget/field/');
133
+ if (!u || u.origin !== widgetOrigin) throw new Error('TranzakCards.mount: URL de champ invalide');
134
+ fieldUrls[f] = u.toString();
135
+ }
136
+
137
+ const host = el('div', 'display:block;width:100%;');
138
+ const shadow = host.attachShadow({ mode: 'closed' });
139
+ const style = document.createElement('style');
140
+ style.textContent = CSS;
141
+ const tpl = document.createElement('template');
142
+ tpl.innerHTML = TEMPLATE; // gabarit statique, sans donnée
143
+ shadow.appendChild(style);
144
+ shadow.appendChild(tpl.content.cloneNode(true));
145
+ container.appendChild(host);
146
+
147
+ const q = (name) => shadow.querySelector(`[data-r="${name}"]`);
148
+ const root = shadow.querySelector('.root');
149
+ const face = shadow.querySelector('.face');
150
+
151
+ // Les trois zones sensibles : de petites iframes AFFICHANT seulement ce que le vault leur envoie.
152
+ q('number').appendChild(frame(fieldUrls.number, 'Numéro de carte', ''));
153
+ q('expiry').appendChild(frame(fieldUrls.expiry, 'Expiration', ''));
154
+ q('cvc').appendChild(frame(fieldUrls.cvc, 'CVC', ''));
155
+
156
+ // Le vault (PIN, boutons) : invisible mais en page tant que la hauteur n'est pas connue (sinon il ne peut pas se mesurer).
157
+ const vault = frame(vaultUrl.toString(), 'Contrôles de la carte', HIDDEN + 'width:100%;height:60px;border:0;background:transparent;color-scheme:normal;');
158
+ q('vault').appendChild(vault);
159
+
160
+ // Taille : tout le dessin est proportionnel à la largeur de la zone (--u = 1 % de la largeur de la carte).
161
+ const setUnit = () => root.style.setProperty('--u', Math.max(2.4, Math.min(host.clientWidth || MAX_WIDTH, MAX_WIDTH) / 100) + 'px');
162
+ setUnit();
163
+ const ro = typeof ResizeObserver !== 'undefined' ? new ResizeObserver(setUnit) : null;
164
+ if (ro) ro.observe(host);
165
+
166
+ let ready = false;
167
+ const timer = setTimeout(() => {
168
+ if (ready) return;
169
+ // Le widget n'a pas démarré (réseau coupé, lien déjà utilisé ou expiré) : un message lisible, pas un squelette éternel.
170
+ face.classList.remove('busy');
171
+ const notice = q('notice');
172
+ notice.textContent = 'Carte momentanément indisponible. Rechargez la page.';
173
+ notice.classList.remove('hidden');
174
+ call('onError', { code: 'timeout' });
175
+ }, SLOW_MS);
176
+
177
+ function call(name, data) {
178
+ if (typeof options[name] === 'function') { try { options[name](data || {}); } catch { /* le code du site ne casse pas le widget */ } }
179
+ }
180
+
181
+ function applyState(s) {
182
+ const pick = (k, v) => (STYLE_OK[k].includes(v) ? v : root.dataset[k]);
183
+ const st = s.style || {};
184
+ root.dataset.theme = pick('theme', st.theme);
185
+ root.dataset.radius = pick('radius', st.radius);
186
+ root.dataset.font = pick('font', st.font);
187
+ root.dataset.brand = s.brand === 'visa' ? 'visa' : 'mastercard';
188
+ face.classList.toggle('frozen', s.status === 'frozen');
189
+
190
+ const status = q('status'), holder = q('holder'), balance = q('balance');
191
+ status.textContent = s.status === 'frozen' ? 'Gelée' : 'Active';
192
+ holder.textContent = typeof s.holder === 'string' ? s.holder : '—';
193
+ balance.textContent = '$' + Number(s.balance || 0).toFixed(2) + ' ' + String(s.currency || 'USD').slice(0, 3);
194
+ [status, holder, balance].forEach((n) => n.classList.remove('skel'));
195
+ }
196
+
197
+ function onMessage(e) {
198
+ // Seulement le vault, seulement l'origine exacte du widget, seulement notre format de message.
199
+ if (e.source !== vault.contentWindow || e.origin !== widgetOrigin) return;
200
+ const d = e.data;
201
+ if (!d || d.source !== 'tranzak-card' || typeof d.type !== 'string') return;
202
+
203
+ switch (d.type) {
204
+ case 'state':
205
+ if (d.state && typeof d.state === 'object') { applyState(d.state); call('onStateChange', publicCopy(d.state)); }
206
+ break;
207
+ case 'busy': face.classList.toggle('busy', d.value === true); break;
208
+ case 'ready':
209
+ ready = true; clearTimeout(timer);
210
+ vault.style.cssText = `display:block;width:100%;height:${vault.style.height || '60px'};border:0;background:transparent;color-scheme:normal;`;
211
+ call('onReady');
212
+ break;
213
+ case 'resize':
214
+ if (typeof d.height === 'number' && d.height > 0 && d.height < 2000) { vault.style.height = Math.ceil(d.height) + 'px'; call('onResize', { height: d.height }); }
215
+ break;
216
+ case 'frozen': call('onFrozen'); break;
217
+ case 'unfrozen': call('onUnfrozen'); break;
218
+ case 'error': call('onError', { code: typeof d.code === 'string' ? d.code.slice(0, 40) : 'error' }); break;
219
+ }
220
+ }
221
+ window.addEventListener('message', onMessage);
222
+
223
+ return {
224
+ layout: 'inline',
225
+ iframes: { vault },
226
+ destroy() {
227
+ clearTimeout(timer);
228
+ window.removeEventListener('message', onMessage);
229
+ if (ro) ro.disconnect();
230
+ host.remove();
231
+ },
232
+ };
233
+ }
234
+
235
+ /** Copie des SEULES informations non sensibles remises à votre code. */
236
+ function publicCopy(s) {
237
+ return {
238
+ last4: s.last4 ?? null, brand: s.brand === 'visa' ? 'visa' : 'mastercard', holder: s.holder ?? null, status: s.status,
239
+ balance: Number(s.balance || 0), currency: s.currency || 'USD', revealed: s.revealed === true,
240
+ };
241
+ }
242
+
243
+ // -- Disposition « framed » : une seule iframe ----------------------------------------------------------------------
244
+
245
+ function mountFramed(options, container, url) {
246
+ const u = parseWidgetUrl(url, '/widget/cards/');
247
+ if (!u) throw new Error('TranzakCards.mount: URL de widget invalide');
248
+ const widgetOrigin = u.origin;
249
+
250
+ const wrap = el('div', `position:relative;width:100%;max-width:${MAX_WIDTH + 40}px;margin:0 auto;`);
251
+ const skel = el('div', `width:100%;max-width:${MAX_WIDTH}px;aspect-ratio:1.586/1;margin:12px auto;border-radius:16px;background:linear-gradient(90deg,#e6e6e6 25%,#f4f4f4 37%,#e6e6e6 63%);background-size:400% 100%;animation:tzc-shimmer 1.3s ease-in-out infinite;`);
252
+ skel.setAttribute('aria-hidden', 'true');
253
+ ensureKeyframes();
254
+ const iframe = frame(u.toString(), 'Carte', HIDDEN + 'width:100%;height:380px;border:0;background:transparent;color-scheme:normal;');
255
+ wrap.append(skel, iframe);
256
+ container.appendChild(wrap);
257
+
258
+ let shown = false;
259
+ const reveal = () => {
260
+ if (shown) return;
261
+ shown = true;
262
+ skel.style.display = 'none';
263
+ iframe.style.cssText = `display:block;width:100%;height:${iframe.style.height};border:0;background:transparent;color-scheme:normal;`;
264
+ };
265
+ const slow = setTimeout(reveal, SLOW_MS);
266
+ const call = (name, data) => { if (typeof options[name] === 'function') { try { options[name](data || {}); } catch { /* idem */ } } };
267
+
268
+ function onMessage(e) {
269
+ if (e.source !== iframe.contentWindow || e.origin !== widgetOrigin) return;
270
+ const d = e.data;
271
+ if (!d || d.source !== 'tranzak-card' || typeof d.type !== 'string') return;
272
+ if (d.type === 'ready') { clearTimeout(slow); reveal(); call('onReady'); }
273
+ else if (d.type === 'resize' && typeof d.height === 'number' && d.height > 0 && d.height < 2000) { iframe.style.height = Math.ceil(d.height) + 'px'; call('onResize', { height: d.height }); }
274
+ else if (d.type === 'frozen') call('onFrozen');
275
+ else if (d.type === 'unfrozen') call('onUnfrozen');
276
+ else if (d.type === 'error') { reveal(); call('onError', { code: typeof d.code === 'string' ? d.code.slice(0, 40) : 'error' }); }
277
+ }
278
+ window.addEventListener('message', onMessage);
279
+
280
+ return {
281
+ layout: 'framed',
282
+ iframes: { main: iframe },
283
+ destroy() { clearTimeout(slow); window.removeEventListener('message', onMessage); wrap.remove(); },
284
+ };
285
+ }
286
+
287
+ function ensureKeyframes() {
288
+ if (document.getElementById('tranzak-cards-style')) return;
289
+ const s = document.createElement('style');
290
+ s.id = 'tranzak-cards-style';
291
+ s.textContent = '@keyframes tzc-shimmer{0%{background-position:100% 50%}100%{background-position:0 50%}}@media (prefers-reduced-motion:reduce){[aria-hidden="true"]{animation:none!important}}';
292
+ document.head.appendChild(s);
293
+ }
294
+
295
+ /**
296
+ * @param {object} options
297
+ * @param {string|Element} options.container Zone de votre page où afficher la carte.
298
+ * @param {object} [options.widget] L'objet `widget` renvoyé par votre serveur (API widget-sessions).
299
+ * @param {string} [options.url] Ancien format : URL d'une iframe unique.
300
+ */
301
+ export function mount(options = {}) {
302
+ const container = typeof options.container === 'string' ? document.querySelector(options.container) : options.container;
303
+ if (!container) throw new Error('TranzakCards.mount: container introuvable');
304
+
305
+ const w = options.widget;
306
+ if (w && w.layout === 'inline') return mountInline(options, container);
307
+ const url = options.url || (w && w.url);
308
+ if (!url) throw new Error('TranzakCards.mount: widget ou url manquant');
309
+ return mountFramed(options, container, url);
310
+ }
311
+
312
+ export default { version: VERSION, mount };