@gataca/qr 4.0.3 → 4.1.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.
- package/dist/cjs/gataca-autoqr.cjs.entry.js +1 -1
- package/dist/cjs/gataca-qr_3.cjs.entry.js +130 -26
- package/dist/cjs/gataca-qrws.cjs.entry.js +142 -22
- package/dist/cjs/gataca-ssibuttonws.cjs.entry.js +1 -1
- package/dist/cjs/gatacaqr.cjs.js +2 -2
- package/dist/cjs/{index-1332a8ce.js → index-d8d3dfde.js} +32 -0
- package/dist/cjs/index.cjs.js +6 -1
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/utils-04522aa4.js +117 -0
- package/dist/collection/components/gataca-qr/components/qr/QR.js +9 -1
- package/dist/collection/components/gataca-qr/components/retryButton/RetryButton.js +5 -2
- package/dist/collection/components/gataca-qr/gataca-qr.css +6 -0
- package/dist/collection/components/gataca-qr/gataca-qr.js +87 -17
- package/dist/collection/components/gataca-qrdisplay/gataca-qrdisplay.js +28 -4
- package/dist/collection/components/gataca-qrws/components/qr/QR.js +9 -1
- package/dist/collection/components/gataca-qrws/components/retryButton/RetryButton.js +5 -2
- package/dist/collection/components/gataca-qrws/gataca-qrws.css +7 -0
- package/dist/collection/components/gataca-qrws/gataca-qrws.js +126 -18
- package/dist/collection/components/gataca-ssibutton/gataca-ssibutton.js +2 -2
- package/dist/collection/utils/utils.js +84 -0
- package/dist/components/gat-icon-check.js +85 -1
- package/dist/components/gataca-qr2.js +106 -20
- package/dist/components/gataca-qrdisplay2.js +25 -4
- package/dist/components/gataca-qrws2.js +145 -21
- package/dist/components/gataca-ssibutton2.js +2 -2
- package/dist/components/index.js +1 -1
- package/dist/esm/gataca-autoqr.entry.js +1 -1
- package/dist/esm/gataca-qr_3.entry.js +131 -27
- package/dist/esm/gataca-qrws.entry.js +142 -22
- package/dist/esm/gataca-ssibuttonws.entry.js +1 -1
- package/dist/esm/gatacaqr.js +2 -2
- package/dist/esm/{index-055790a7.js → index-dca2ab22.js} +32 -0
- package/dist/esm/index.js +1 -1
- package/dist/esm/loader.js +2 -2
- package/dist/esm/utils-cf9db2bd.js +109 -0
- package/dist/gatacaqr/gatacaqr.esm.js +1 -1
- package/dist/gatacaqr/index.esm.js +1 -1
- package/dist/gatacaqr/{p-49cf321c.entry.js → p-2e8accf9.entry.js} +1 -1
- package/dist/gatacaqr/p-3db0f74d.entry.js +1 -0
- package/dist/gatacaqr/p-775c90cf.entry.js +1 -0
- package/dist/gatacaqr/{p-0501e224.js → p-7b6fa63b.js} +1 -1
- package/dist/gatacaqr/p-85af64b1.js +2 -0
- package/dist/gatacaqr/{p-c65f810b.entry.js → p-d27dabe4.entry.js} +1 -1
- package/dist/types/components/gataca-qr/components/qr/QR.d.ts +1 -0
- package/dist/types/components/gataca-qr/components/retryButton/RetryButton.d.ts +0 -2
- package/dist/types/components/gataca-qr/gataca-qr.d.ts +5 -2
- package/dist/types/components/gataca-qrdisplay/gataca-qrdisplay.d.ts +4 -0
- package/dist/types/components/gataca-qrws/components/qr/QR.d.ts +1 -0
- package/dist/types/components/gataca-qrws/components/retryButton/RetryButton.d.ts +0 -2
- package/dist/types/components/gataca-qrws/gataca-qrws.d.ts +8 -2
- package/dist/types/utils/utils.d.ts +10 -0
- package/package.json +1 -1
- package/dist/cjs/utils-c6edb275.js +0 -28
- package/dist/esm/utils-22df0ce4.js +0 -25
- package/dist/gatacaqr/p-2083dd06.entry.js +0 -1
- package/dist/gatacaqr/p-f5a4f65c.entry.js +0 -1
- package/dist/gatacaqr/p-fccf9d4d.js +0 -2
|
@@ -226,6 +226,8 @@ export declare class GatacaQR {
|
|
|
226
226
|
authenticationRequest?: string;
|
|
227
227
|
sessionData: any;
|
|
228
228
|
result: RESULT_STATUS;
|
|
229
|
+
qrHref: string;
|
|
230
|
+
private lastShortenRaw;
|
|
229
231
|
componentDidLoad(): Promise<void>;
|
|
230
232
|
/**
|
|
231
233
|
* GatacaLoginCompleted event, triggered with session data upon login success
|
|
@@ -239,6 +241,8 @@ export declare class GatacaQR {
|
|
|
239
241
|
* Force manually the display of a QR
|
|
240
242
|
*/
|
|
241
243
|
display(): Promise<void>;
|
|
244
|
+
private buildRawLink;
|
|
245
|
+
private refreshQrHref;
|
|
242
246
|
/**
|
|
243
247
|
* Stop manually an ongoing session
|
|
244
248
|
*/
|
|
@@ -258,7 +262,6 @@ export declare class GatacaQR {
|
|
|
258
262
|
title: any;
|
|
259
263
|
description: any;
|
|
260
264
|
}): any;
|
|
261
|
-
renderQR(value: string, useLogo?: boolean, sizeQR?: number): any;
|
|
262
|
-
renderRetryQR(value: string, useLogo?: boolean): any;
|
|
265
|
+
renderQR(value: string, useLogo?: boolean, sizeQR?: number, linkReady?: boolean): any;
|
|
263
266
|
render(): any;
|
|
264
267
|
}
|
|
@@ -1,7 +1,11 @@
|
|
|
1
1
|
import { DrawType } from 'qr-code-styling';
|
|
2
2
|
export declare class GatacaQRDisplay {
|
|
3
3
|
private qr;
|
|
4
|
+
private qrCode;
|
|
5
|
+
private getQrOptions;
|
|
4
6
|
componentDidLoad(): void;
|
|
7
|
+
onQrDataChange(): void;
|
|
8
|
+
private mountOrUpdateQr;
|
|
5
9
|
/**
|
|
6
10
|
* _[Mandatory]_
|
|
7
11
|
* Sets the contents of the QR
|
|
@@ -5,9 +5,7 @@ declare type IRetryButtonProps = {
|
|
|
5
5
|
clickInsideBoxLabel?: string;
|
|
6
6
|
refreshQrLabel?: string;
|
|
7
7
|
scanQrLabel?: string;
|
|
8
|
-
waitingStartSessionLabel?: string;
|
|
9
8
|
display: (x?: any) => void;
|
|
10
|
-
renderRetryQR(value: string, useLogo?: boolean): any;
|
|
11
9
|
};
|
|
12
10
|
export declare const RetryButton: React.FC<IRetryButtonProps>;
|
|
13
11
|
export {};
|
|
@@ -207,6 +207,8 @@ export declare class GatacaQRWS {
|
|
|
207
207
|
authenticationRequest?: string;
|
|
208
208
|
sessionData: any;
|
|
209
209
|
result: RESULT_STATUS;
|
|
210
|
+
qrHref: string;
|
|
211
|
+
qrShortenPending: boolean;
|
|
210
212
|
componentDidLoad(): Promise<void>;
|
|
211
213
|
/**
|
|
212
214
|
* GatacaLoginCompleted event, triggered with session data upon login success
|
|
@@ -217,6 +219,8 @@ export declare class GatacaQRWS {
|
|
|
217
219
|
*/
|
|
218
220
|
gatacaLoginFailed: EventEmitter;
|
|
219
221
|
socket: WebSocket;
|
|
222
|
+
private qrRefreshGeneration;
|
|
223
|
+
private lastShortenRaw;
|
|
220
224
|
/**
|
|
221
225
|
* Force manually the display of a QR
|
|
222
226
|
*/
|
|
@@ -231,6 +235,8 @@ export declare class GatacaQRWS {
|
|
|
231
235
|
* Retrieve manually the session data on a successful login
|
|
232
236
|
*/
|
|
233
237
|
getSessionData(): Promise<any>;
|
|
238
|
+
private buildRawLink;
|
|
239
|
+
private refreshQrHref;
|
|
234
240
|
getLink(): string;
|
|
235
241
|
renderQRSection(): any;
|
|
236
242
|
renderSuccess(): any;
|
|
@@ -239,7 +245,7 @@ export declare class GatacaQRWS {
|
|
|
239
245
|
title: any;
|
|
240
246
|
description: any;
|
|
241
247
|
}): any;
|
|
242
|
-
renderQR(value: string, useLogo?: boolean, sizeQR?: number): any;
|
|
243
|
-
|
|
248
|
+
renderQR(value: string, useLogo?: boolean, sizeQR?: number, linkReady?: boolean): any;
|
|
249
|
+
renderQrLoadingSlot(): any;
|
|
244
250
|
render(): any;
|
|
245
251
|
}
|
|
@@ -55,3 +55,13 @@ export declare type QRConfig = (QRLogin & QRButton) & {
|
|
|
55
55
|
useButton?: boolean;
|
|
56
56
|
useWs?: boolean;
|
|
57
57
|
};
|
|
58
|
+
/** URL schemes before assigning window.location. */
|
|
59
|
+
export declare const ALLOWED_APP_REDIRECT_PROTOCOLS: readonly string[];
|
|
60
|
+
export declare function isAllowedAppRedirect(url?: string | null): boolean;
|
|
61
|
+
export declare function isAllowedNavigationRedirect(url?: string | null): boolean;
|
|
62
|
+
export declare function assignWindowLocationIfAllowed(url?: string | null, allowHttps?: boolean): boolean;
|
|
63
|
+
/**
|
|
64
|
+
* POSTs the link to shortener. On success with a non-empty url in the body, returns that url;
|
|
65
|
+
* otherwise returns the original link.
|
|
66
|
+
*/
|
|
67
|
+
export declare function shortenUrlIfPossible(link?: string): Promise<string>;
|
package/package.json
CHANGED
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
function checkMobile() {
|
|
4
|
-
var check = false;
|
|
5
|
-
(function (a) {
|
|
6
|
-
if (/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino/i.test(a) ||
|
|
7
|
-
/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(pt|ta)|hp( i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|ma)|i230|iac( |\-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc\-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|\-[a-w])|libw|lynx|m1\-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m\-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(\-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)\-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\-2|po(ck|rt|se)|prox|psio|pt\-g|qa\-a|qc(07|12|21|32|60|\-[2-7]|i\-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h\-|oo|p\-)|sdk\/|se(c(\-|0|1)|47|mc|nd|ri)|sgh\-|shar|sie(\-|m)|sk\-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h\-|v\-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl\-|tdg\-|tel(i|m)|tim\-|t\-mo|to(pl|sh)|ts(70|m\-|m3|m5)|tx\-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas\-|your|zeto|zte\-/i.test(a.substr(0, 4)))
|
|
8
|
-
check = true;
|
|
9
|
-
})(navigator.userAgent || navigator.vendor);
|
|
10
|
-
return check;
|
|
11
|
-
}
|
|
12
|
-
function base64UrlEncode(str) {
|
|
13
|
-
let b64 = btoa(str);
|
|
14
|
-
return b64.replace(/\+/g, '-').replace(/\//g, '_').replace(/\=+$/, '');
|
|
15
|
-
}
|
|
16
|
-
exports.RESULT_STATUS = void 0;
|
|
17
|
-
(function (RESULT_STATUS) {
|
|
18
|
-
RESULT_STATUS[RESULT_STATUS["NOT_STARTED"] = -1] = "NOT_STARTED";
|
|
19
|
-
RESULT_STATUS[RESULT_STATUS["ONGOING"] = 0] = "ONGOING";
|
|
20
|
-
RESULT_STATUS[RESULT_STATUS["SUCCESS"] = 1] = "SUCCESS";
|
|
21
|
-
RESULT_STATUS[RESULT_STATUS["FAILED"] = 2] = "FAILED";
|
|
22
|
-
RESULT_STATUS[RESULT_STATUS["EXPIRED"] = 3] = "EXPIRED";
|
|
23
|
-
RESULT_STATUS[RESULT_STATUS["READ"] = 5] = "READ";
|
|
24
|
-
})(exports.RESULT_STATUS || (exports.RESULT_STATUS = {}));
|
|
25
|
-
//
|
|
26
|
-
|
|
27
|
-
exports.base64UrlEncode = base64UrlEncode;
|
|
28
|
-
exports.checkMobile = checkMobile;
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
function checkMobile() {
|
|
2
|
-
var check = false;
|
|
3
|
-
(function (a) {
|
|
4
|
-
if (/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|fennec|hiptop|iemobile|ip(hone|od)|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino/i.test(a) ||
|
|
5
|
-
/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(pt|ta)|hp( i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|ma)|i230|iac( |\-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc\-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|\-[a-w])|libw|lynx|m1\-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m\-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(\-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)\-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\-2|po(ck|rt|se)|prox|psio|pt\-g|qa\-a|qc(07|12|21|32|60|\-[2-7]|i\-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h\-|oo|p\-)|sdk\/|se(c(\-|0|1)|47|mc|nd|ri)|sgh\-|shar|sie(\-|m)|sk\-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h\-|v\-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl\-|tdg\-|tel(i|m)|tim\-|t\-mo|to(pl|sh)|ts(70|m\-|m3|m5)|tx\-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas\-|your|zeto|zte\-/i.test(a.substr(0, 4)))
|
|
6
|
-
check = true;
|
|
7
|
-
})(navigator.userAgent || navigator.vendor);
|
|
8
|
-
return check;
|
|
9
|
-
}
|
|
10
|
-
function base64UrlEncode(str) {
|
|
11
|
-
let b64 = btoa(str);
|
|
12
|
-
return b64.replace(/\+/g, '-').replace(/\//g, '_').replace(/\=+$/, '');
|
|
13
|
-
}
|
|
14
|
-
var RESULT_STATUS;
|
|
15
|
-
(function (RESULT_STATUS) {
|
|
16
|
-
RESULT_STATUS[RESULT_STATUS["NOT_STARTED"] = -1] = "NOT_STARTED";
|
|
17
|
-
RESULT_STATUS[RESULT_STATUS["ONGOING"] = 0] = "ONGOING";
|
|
18
|
-
RESULT_STATUS[RESULT_STATUS["SUCCESS"] = 1] = "SUCCESS";
|
|
19
|
-
RESULT_STATUS[RESULT_STATUS["FAILED"] = 2] = "FAILED";
|
|
20
|
-
RESULT_STATUS[RESULT_STATUS["EXPIRED"] = 3] = "EXPIRED";
|
|
21
|
-
RESULT_STATUS[RESULT_STATUS["READ"] = 5] = "READ";
|
|
22
|
-
})(RESULT_STATUS || (RESULT_STATUS = {}));
|
|
23
|
-
//
|
|
24
|
-
|
|
25
|
-
export { RESULT_STATUS as R, base64UrlEncode as b, checkMobile as c };
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{r as t,h as i,c as e}from"./p-fccf9d4d.js";import{Q as s,l as a,g as n,a as o}from"./p-29119208.js";import{R as r,c as l,b as d}from"./p-0501e224.js";const h=class{constructor(i){t(this,i),this.qrData=void 0,this.qrType="svg",this.size=256,this.logoSize=0,this.logoSrc=void 0,this.qrColor="#1E1E20",this.bgColor="#FFFFFF",this.rounded=!0}componentDidLoad(){new s({data:this.qrData,width:this.size,height:this.size,image:this.logoSize>0?this.logoSrc||a:void 0,margin:10,type:this.qrType,dotsOptions:{color:this.qrColor,type:this.rounded?"dots":"square"},cornersSquareOptions:{type:this.rounded?"extra-rounded":"square"},cornersDotOptions:{type:this.rounded?"dot":"square"},imageOptions:{margin:2,imageSize:this.logoSize},backgroundOptions:{color:this.bgColor}}).append(this.qr)}render(){return i("div",{ref:t=>{this.qr=t}})}},c=t=>{const{value:e,useLogo:s,logoSrc:a,size:n,qrType:o,style:r}=t;return i("gataca-qrdisplay",{qrData:e,rounded:!0,qrType:o,size:n,"logo-size":s?.33:0,"logo-src":a,qrColor:null==r?void 0:r.color,bgColor:null==r?void 0:r.bgColor})},p=t=>{const{color:e="#4745B7"}=t;return i("div",{class:"containerLoader",style:{"--loader-color":e}},i("div",{class:"loader"},i("div",{class:"loader__item loader__item__1"}),i("div",{class:"loader__item loader__item__2"}),i("div",{class:"loader__item loader__item__3"}),i("div",{class:"loader__item loader__item__4"}),i("div",{class:"loader__item loader__item__5"}),i("div",{class:"loader__item loader__item__6"}),i("div",{class:"loader__item loader__item__7"}),i("div",{class:"loader__item loader__item__8"})))},u=t=>{var e;const{modalWidth:s,readQrMessages:a,renderQR:n,url:o,sizeQR:r,style:l}=t,d={backgroundColor:(null==l?void 0:l.bgColor)?null==l?void 0:l.bgColor:"white"},h={color:(null==l?void 0:l.color)?null==l?void 0:l.color:"#707074"};return i("div",{class:"blured",style:{width:(s-48).toString()+"px",height:s?(null===(e=s-48)||void 0===e?void 0:e.toString())+"px":"",backgroundColor:null==l?void 0:l.bgColor,color:null==l?void 0:l.color,border:(null==l?void 0:l.color)?`1px dashed ${null==l?void 0:l.color}`:"1px dashed #a1a1a1"}},i("div",{id:"notify",style:d},i(p,{color:null==l?void 0:l.color}),i("p",{class:"notify-text",style:h},null==a?void 0:a.title," "),i("p",{class:"notify-text bold",style:h},null==a?void 0:a.description)),i("div",{id:"qrwait"},n(o,!1,r)))},g=t=>{const{height:e=24,width:s=24,color:a}=t,n=a||"#8B8B8B";return i("svg",{width:s,height:e,viewBox:`0 0 ${s} ${e}`,fill:"none",xmlns:"http://www.w3.org/2000/svg"},i("path",{d:"M23 4V10H17",stroke:n,"stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"}),i("path",{d:"M20.4899 15C19.8399 16.8399 18.6094 18.4187 16.984 19.4985C15.3586 20.5783 13.4263 21.1006 11.4783 20.9866C9.53026 20.8726 7.67203 20.1286 6.18363 18.8667C4.69524 17.6047 3.6573 15.8932 3.22625 13.9901C2.79519 12.0869 2.99436 10.0952 3.79374 8.31508C4.59313 6.53496 5.94942 5.06288 7.65823 4.12065C9.36705 3.17843 11.3358 2.81711 13.2678 3.09116C15.1999 3.3652 16.9905 4.25975 18.3699 5.64001L22.9999 10",stroke:n,"stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"}))},m=t=>{var e;const{errorMessage:s,modalWidth:a,clickInsideBoxLabel:o,refreshQrLabel:r,scanQrLabel:l,waitingStartSessionLabel:d,style:h,display:c,renderRetryQR:p}=t,u={backgroundColor:(null==h?void 0:h.bgColor)?null==h?void 0:h.bgColor:"white"},m={backgroundColor:(null==h?void 0:h.alertBgColor)?null==h?void 0:h.alertBgColor:"#ffdedf"},b={borderColor:(null==h?void 0:h.alertBorderColor)?null==h?void 0:h.alertBorderColor:"#ee888c"},v={color:(null==h?void 0:h.color)?null==h?void 0:h.color:"#707074"};return i("div",{class:"reload",style:{width:(a-48).toString()+"px",height:a?(null===(e=a-48)||void 0===e?void 0:e.toString())+"px":"",border:(null==h?void 0:h.color)?`1px dashed ${null==h?void 0:h.color}`:"1px dashed #a1a1a1"}},i("div",{id:"notify",onClick:()=>c(),style:u},i(g,{color:null==h?void 0:h.color,height:24,width:24}),i("p",{class:"notify-text",style:v},o," "),i("p",{class:"notify-text bold",style:v},s?r:l),s&&i("div",{class:"alert",style:Object.assign(Object.assign({width:(a-48).toString()+"px"},m),{border:`1px solid ${b}`})},i("img",{src:n,height:24,width:24}),i("p",{style:{color:(null==h?void 0:h.color)?null==h?void 0:h.color:"#1e1e20"}},s))),i("div",{id:"qrwait"},p(d)))},b=t=>{const{modalHeight:e,successLoginLabel:s,style:a}=t,n={color:(null==a?void 0:a.color)?null==a?void 0:a.color:"#1e1e20"};return i("div",{class:"success",style:{height:e?(null==e?void 0:e.toString())+"px":"300px"}},i("img",{src:o,height:52,width:52}),i("p",{class:"successMsg",style:n},s))},v=class{constructor(i){t(this,i),this.gatacaLoginCompleted=e(this,"gatacaLoginCompleted",7),this.gatacaLoginFailed=e(this,"gatacaLoginFailed",7),this.checkStatus=void 0,this.createSession=void 0,this.successCallback=void 0,this.errorCallback=void 0,this.qrRole=void 0,this.qrType="svg",this.callbackServer=void 0,this.autostart=!0,this.autorefresh=!1,this.v="3",this.qrModalTitle="Quick Access",this.modalTitleColor="#4745B7",this.qrModalDescription="Sign up or sign in by scanning the QR Code with the Gataca Wallet",this.hideModalTexts=!1,this.hideModalBoxShadow=!1,this.hideBrandTitle=!1,this.logoSize=0,this.logoSrc=a,this.qrSize=300,this.modalWidth=300,this.modalHeight=void 0,this.qrCodeExpiredLabel="QR Code expired",this.credentialsNotValidatedLabel="User credentials not validated",this.clickInsideBoxLabel="Click inside the box to",this.refreshQrLabel="Refresh QR Code",this.scanQrLabel="Scan QR Code",this.userNotScanInTimeErrorLabel="User did not scan the QR in the allowed time",this.credsNotValidatedErrorLabel="Provided user credentials couldn't be validated",this.failedLoginErrorLabel="No successful login",this.successLoginLabel="Successful Connection!",this.byBrandLabel="by Gataca",this.waitingStartSessionLabel="waiting to start a session",this.readQrTitle="Processing...",this.readQrDescription="Please wait a moment",this.hideQrModalDescription=!1,this.sessionTimeout=300,this.pollingFrequency=3,this.dynamicLink=!0,this.qrStyle=void 0,this.sessionId=void 0,this.authenticationRequest=void 0,this.sessionData=void 0,this.result=r.NOT_STARTED}disconnectedCallback(){this.stop()}async componentDidLoad(){this.autostart&&await this.display()}async display(){await this.getSessionId(),this.result=r.ONGOING,this.poll().then((t=>{this.result=r.SUCCESS,this.sessionData=t,this.gatacaLoginCompleted.emit(t),this.successCallback(t)})).catch((t=>{this.clean();let i=t===r.EXPIRED;if(i&&this.autorefresh)this.display();else if(t!==r.NOT_STARTED){let e=i?new Error(this.userNotScanInTimeErrorLabel):new Error(this.credsNotValidatedErrorLabel);this.result=t,this.gatacaLoginFailed.emit(e),this.errorCallback(e)}})),l()&&this.dynamicLink&&(window.location.href=this.getLink())}async stop(){this.clean(),(this.result===r.ONGOING||r.READ)&&(this.result=r.NOT_STARTED)}clean(){this.sessionData=void 0,this.sessionId=void 0}async getSessionData(){return this.sessionData?Promise.resolve(this.sessionData):Promise.reject(new Error(this.failedLoginErrorLabel))}async getSessionId(){if(this.sessionId)return this.sessionId;let{sessionId:t,authenticationRequest:i}=await this.createSession();return this.sessionId=t,this.authenticationRequest=i,this.sessionId}getLink(){return"2"===this.v?this.authenticationRequest:"https://api.gataca.io/qr/redirect.html?dl="+d(this.authenticationRequest)}async poll(){let t=(new Date).getTime()+1e3*(this.sessionTimeout||300),i=1e3*(this.pollingFrequency||3),e=this,s=async function(a,n){let{result:o,data:l}=await(async t=>{if(t.result===r.NOT_STARTED)return{result:r.NOT_STARTED};let i=await t.getSessionId();return t.checkStatus(i)})(e);switch(o){case r.SUCCESS:a(l);break;case r.READ:e.result=r.READ;case r.ONGOING:e.sessionTimeout>0&&(new Date).getTime()<t?setTimeout(s,i,a,n):n(r.EXPIRED);break;default:n(o)}};return new Promise(s)}renderQRSection(){switch(this.result){case r.NOT_STARTED:return this.renderRetryButton();case r.ONGOING:return this.renderQR(this.getLink(),!0);case r.EXPIRED:return this.renderRetryButton(this.qrCodeExpiredLabel);case r.FAILED:return this.renderRetryButton(this.credentialsNotValidatedLabel);case r.SUCCESS:return this.renderSuccess();case r.READ:return this.renderReadQR({title:null==this?void 0:this.readQrTitle,description:null==this?void 0:this.readQrDescription})}}renderSuccess(){return i(b,{modalHeight:null==this?void 0:this.modalHeight,successLoginLabel:null==this?void 0:this.successLoginLabel,style:null==this?void 0:this.qrStyle})}renderRetryButton(t){return i(m,{errorMessage:t,modalWidth:null==this?void 0:this.modalWidth,clickInsideBoxLabel:null==this?void 0:this.clickInsideBoxLabel,refreshQrLabel:null==this?void 0:this.refreshQrLabel,scanQrLabel:null==this?void 0:this.scanQrLabel,waitingStartSessionLabel:null==this?void 0:this.waitingStartSessionLabel,display:this.display.bind(this),renderRetryQR:this.renderRetryQR.bind(this),style:null==this?void 0:this.qrStyle})}renderReadQR(t){return i(u,{modalWidth:null==this?void 0:this.modalWidth,readQrMessages:t,url:this.getLink(),sizeQR:(null==this?void 0:this.qrSize)?(null==this?void 0:this.qrSize)-50:void 0,renderQR:this.renderQR.bind(this),style:this.qrStyle})}renderQR(t,e,s){return i(c,{value:t,qrType:this.qrType,useLogo:e&&0!==this.logoSize,size:s||(null==this?void 0:this.qrSize)||void 0,logoSrc:null==this?void 0:this.logoSrc,style:null==this?void 0:this.qrStyle})}renderRetryQR(t,e){return i(c,{value:t,useLogo:e&&0!==this.logoSize,qrType:this.qrType,size:(null==this?void 0:this.qrSize)?(null==this?void 0:this.qrSize)-50:void 0,logoSrc:null==this?void 0:this.logoSrc,style:null==this?void 0:this.qrStyle})}render(){var t,e,s,n,o,l;return i("div",{class:"popUpContainer"},i("div",{class:`is-visible modal-window ${this.hideModalTexts?"":"large-modal"} ${this.hideModalBoxShadow?"noBoxShadow":""}`,style:{width:(this.modalWidth-2).toString()+"px",height:this.modalHeight?(null===(t=this.modalHeight-2)||void 0===t?void 0:t.toString())+"px":"",backgroundColor:(null===(e=null==this?void 0:this.qrStyle)||void 0===e?void 0:e.bgColor)?null===(s=null==this?void 0:this.qrStyle)||void 0===s?void 0:s.bgColor:"white",boxShadow:(null===(n=null==this?void 0:this.qrStyle)||void 0===n?void 0:n.boxShadow)?null===(o=null==this?void 0:this.qrStyle)||void 0===o?void 0:o.boxShadow:"0px 3px 10px rgba(48, 48, 48, 0.1);"},onClick:t=>{t.stopPropagation()}},i("div",{class:"modal-window__content"},i("div",{class:"qrTitleContainer "+(this.hideModalTexts?"hidenText":"")},i("p",{class:"qrTitle modalText",style:{color:this.modalTitleColor||"#1e1e20"}},this.qrModalTitle),!this.hideBrandTitle&&i("p",{class:"qrBrand modalText"},this.byBrandLabel," ",i("span",null,i("img",{src:a}))),this.result!==r.SUCCESS&&!this.hideQrModalDescription&&i("p",{class:"qrDescription modalText"},this.qrModalDescription)),i("div",{class:"qrSection",style:{width:this.modalWidth.toString()+"px",height:this.modalWidth?(null===(l=this.modalWidth)||void 0===l?void 0:l.toString())+"px":""}},this.renderQRSection()))))}};v.style='@import url("https://fonts.googleapis.com/css2?family=Ubuntu:wght@100;300;400;500;600;700&display=swap"); @import url("https://fonts.googleapis.com/css2?family=Poppins:wght@100;300;400;500;600;700&display=swap"); @import url("https://fonts.googleapis.com/css2?family=Work+Sans:wght@300;400&display=swap"); html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,img,ins,kbd,q,s,samp,small,strike,strong,sub,sup,tt,var,b,u,i,center,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td,article,aside,canvas,details,embed,figure,figcaption,footer,header,hgroup,menu,nav,output,ruby,section,summary,time,mark,audio,video{margin:0;padding:0;border:0;font-size:100%;font:inherit;vertical-align:baseline}article,aside,details,figcaption,figure,footer,header,hgroup,menu,nav,section{display:block}body{line-height:1}ol,ul{list-style:none}blockquote,q{quotes:none}blockquote:before,blockquote:after,q:before,q:after{content:"";content:none}table{border-collapse:collapse;border-spacing:0}.img-fluid{height:auto;max-width:50%}img{margin-left:auto;margin-right:auto}.brandSection{padding-top:5px;display:flex;align-items:center}.brandSection .gatacaImgSmall{height:13px;width:13px;margin:0;margin-right:10px}.popUpContainer .large-modal{width:300px;min-height:350px}.popUpContainer .modal-window{position:relative;border-radius:6px;overflow:hidden;color:rgba(24, 27, 94, 0.8);box-shadow:0px 3px 10px rgba(48, 48, 48, 0.1);display:flex;flex-direction:column;justify-content:space-between;align-items:center;display:flex;z-index:1001;padding:1px;background-color:white;border-radius:12px;-webkit-transition:opacity 0.5s, visibility 0s 0.5s;transition:opacity 0.5s, visibility 0s 0.5s;visibility:hidden;opacity:0}.popUpContainer .modal-window__content{width:100%;height:100%;text-align:left}.popUpContainer .modal-window__content .hidenText{display:none}.popUpContainer .modal-window .modalText{font-family:"Ubuntu", "Work Sans", "Helvetica Neue", sans-serif;font-size:20px;font-style:normal;font-weight:700;line-height:24px;margin-top:10px;letter-spacing:1px}.popUpContainer .modal-window .qrTitleContainer{padding:14px 24px;padding-bottom:0px}.popUpContainer .modal-window .qrTitle{font-size:20px;font-weight:600;line-height:23.5px}.popUpContainer .modal-window .qrDescription{font-family:"Poppins", "Ubuntu", "Work Sans", "Helvetica Neue", sans-serif;font-size:14px;font-style:normal;font-weight:400;line-height:16px;color:#707074}.popUpContainer .modal-window .bold{font-weight:700}.popUpContainer .modal-window .qrBrand{margin-top:4px;font-size:14px;font-weight:400;line-height:16.5px;display:flex;align-items:center}.popUpContainer .modal-window .qrBrand img{margin-left:5px;height:12px}.popUpContainer .modal-window .qr-section{width:252px;height:252px}.popUpContainer .noBoxShadow{box-shadow:none}.popUpContainer .is-visible{opacity:1;visibility:visible}.is-transparent{opacity:0}.success{display:flex;height:300px;flex-direction:column;justify-content:center;align-items:center;padding:0px}.success>img{padding-bottom:12px}.success>.successMsg{line-height:23.5px;color:var(--neutral-1000, #1e1e20);text-align:center;font-family:"Ubuntu", "Work Sans", "Helvetica Neue", sans-serif;font-size:20px;font-style:normal;font-weight:700;line-height:24px}.reload,.blured{height:252px;width:252px;border:1px dashed #a1a1a1;border-radius:20px;position:relative;top:24px;margin:0 24px 24px;display:flex;overflow:hidden;justify-content:center;align-items:center}#qrwait{display:flex;justify-content:center}#qrwait,#notify{width:100%;height:100%;top:0;left:0;border-radius:20px}#notify{z-index:10;position:absolute;justify-self:center;justify-items:center;justify-content:center;align-items:center;align-content:center;display:flex;flex-direction:column;box-sizing:border-box;padding:20px;background:rgba(255, 255, 255, 0.95)}#notify>svg{padding-bottom:12px}.alert{display:flex;flex-direction:row;justify-content:start;width:252px;position:absolute;bottom:0px;border:1px solid #ee888c;background:#ffdedf;border-radius:11px;box-sizing:border-box;padding:12px;align-items:center;gap:12px}.alert>img{margin:0}.alert>p{font-family:"Poppins", "Ubuntu", "Work Sans", "Helvetica Neue", sans-serif;font-size:14px;font-style:normal;font-weight:400;margin-top:0;line-height:16px;color:#1e1e20}.notify-text{font-family:"Poppins", "Ubuntu", "Work Sans", "Helvetica Neue", sans-serif;font-size:14px;font-style:normal;font-weight:400;line-height:16px;color:#707074;text-align:center}.containerLoader{display:flex;justify-content:center;align-items:center;width:30px;height:30px;margin-bottom:12px}.loader{position:relative;margin-left:0 !important}.loader__item{position:absolute;width:9.68px;height:4px;background-color:var(--loader-color, #4745B7);border-radius:2px;--to-opacity:1;opacity:var(--to-opacity)}.loader__item__1{transform:translate(2.5846212025px, 5.4246212025px) rotate(45deg);-webkit-animation:translate(2.5846212025px, 5.4246212025px) rotate(45deg);-moz-animation:translate(2.5846212025px, 5.4246212025px) rotate(45deg);-o-animation:translate(2.5846212025px, 5.4246212025px) rotate(45deg);--to-opacity:calc(1 - (0 / 8));animation:blink 0.8333333333s linear 0.1041666667s infinite;-webkit-animation:blink 0.8333333333s linear 0.1041666667s infinite;-moz-animation:blink 0.8333333333s linear 0.1041666667s infinite;-o-animation:blink 0.8333333333s linear 0.1041666667s infinite}.loader__item__2{transform:translate(-4.84px, 8.5px) rotate(90deg);-webkit-animation:translate(-4.84px, 8.5px) rotate(90deg);-moz-animation:translate(-4.84px, 8.5px) rotate(90deg);-o-animation:translate(-4.84px, 8.5px) rotate(90deg);--to-opacity:calc(1 - (1 / 8));animation:blink 0.8333333333s linear 0.2083333333s infinite;-webkit-animation:blink 0.8333333333s linear 0.2083333333s infinite;-moz-animation:blink 0.8333333333s linear 0.2083333333s infinite;-o-animation:blink 0.8333333333s linear 0.2083333333s infinite}.loader__item__3{transform:translate(-12.2646212025px, 5.4246212025px) rotate(135deg);-webkit-animation:translate(-12.2646212025px, 5.4246212025px) rotate(135deg);-moz-animation:translate(-12.2646212025px, 5.4246212025px) rotate(135deg);-o-animation:translate(-12.2646212025px, 5.4246212025px) rotate(135deg);--to-opacity:calc(1 - (2 / 8));animation:blink 0.8333333333s linear 0.3125s infinite;-webkit-animation:blink 0.8333333333s linear 0.3125s infinite;-moz-animation:blink 0.8333333333s linear 0.3125s infinite;-o-animation:blink 0.8333333333s linear 0.3125s infinite}.loader__item__4{transform:translate(-15.3399999992px, -1.9999999999px) rotate(180deg);-webkit-animation:translate(-15.3399999992px, -1.9999999999px) rotate(180deg);-moz-animation:translate(-15.3399999992px, -1.9999999999px) rotate(180deg);-o-animation:translate(-15.3399999992px, -1.9999999999px) rotate(180deg);--to-opacity:calc(1 - (3 / 8));animation:blink 0.8333333333s linear 0.4166666667s infinite;-webkit-animation:blink 0.8333333333s linear 0.4166666667s infinite;-moz-animation:blink 0.8333333333s linear 0.4166666667s infinite;-o-animation:blink 0.8333333333s linear 0.4166666667s infinite}.loader__item__5{transform:translate(-12.2646210959px, -9.4246211842px) rotate(225deg);-webkit-animation:translate(-12.2646210959px, -9.4246211842px) rotate(225deg);-moz-animation:translate(-12.2646210959px, -9.4246211842px) rotate(225deg);-o-animation:translate(-12.2646210959px, -9.4246211842px) rotate(225deg);--to-opacity:calc(1 - (4 / 8));animation:blink 0.8333333333s linear 0.5208333333s infinite;-webkit-animation:blink 0.8333333333s linear 0.5208333333s infinite;-moz-animation:blink 0.8333333333s linear 0.5208333333s infinite;-o-animation:blink 0.8333333333s linear 0.5208333333s infinite}.loader__item__6{transform:translate(-4.8399941857px, -12.499998805px) rotate(270deg);-webkit-animation:translate(-4.8399941857px, -12.499998805px) rotate(270deg);-moz-animation:translate(-4.8399941857px, -12.499998805px) rotate(270deg);-o-animation:translate(-4.8399941857px, -12.499998805px) rotate(270deg);--to-opacity:calc(1 - (5 / 8));animation:blink 0.8333333333s linear 0.625s infinite;-webkit-animation:blink 0.8333333333s linear 0.625s infinite;-moz-animation:blink 0.8333333333s linear 0.625s infinite;-o-animation:blink 0.8333333333s linear 0.625s infinite}.loader__item__7{transform:translate(2.5847915061px, -9.4245803212px) rotate(315deg);-webkit-animation:translate(2.5847915061px, -9.4245803212px) rotate(315deg);-moz-animation:translate(2.5847915061px, -9.4245803212px) rotate(315deg);-o-animation:translate(2.5847915061px, -9.4245803212px) rotate(315deg);--to-opacity:calc(1 - (6 / 8));animation:blink 0.8333333333s linear 0.7291666667s infinite;-webkit-animation:blink 0.8333333333s linear 0.7291666667s infinite;-moz-animation:blink 0.8333333333s linear 0.7291666667s infinite;-o-animation:blink 0.8333333333s linear 0.7291666667s infinite}.loader__item__8{transform:translate(5.6631628524px, -1.99913122px) rotate(360deg);-webkit-animation:translate(5.6631628524px, -1.99913122px) rotate(360deg);-moz-animation:translate(5.6631628524px, -1.99913122px) rotate(360deg);-o-animation:translate(5.6631628524px, -1.99913122px) rotate(360deg);--to-opacity:calc(1 - (7 / 8));animation:blink 0.8333333333s linear 0.8333333333s infinite;-webkit-animation:blink 0.8333333333s linear 0.8333333333s infinite;-moz-animation:blink 0.8333333333s linear 0.8333333333s infinite;-o-animation:blink 0.8333333333s linear 0.8333333333s infinite}.loader__item__8{max-width:8.5px}@keyframes blink{0%{opacity:1}100%{opacity:var(--to-opacity)}}@keyframes rotate{0%{transform:rotate(0deg)}100%{background:rotate(360deg)}}';const f="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABsAAAAbCAYAAACN1PRVAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAHvSURBVHgB3ZZPTttAFMbfe3YjL7qYLopcpZXSG7Q3CDfIsqrSJpyg5QQtJ2h7glgUdVs4AeEE5AYEQSDAgtnw357Hm0hAQDaeIRFCfFKyeKPxzzPzvc+DUKCZN80GEv1ABgWOQgSdGbOwv7u0nDueV4zjTzUIKhuAZna4vdQFR828azbI0K/TI/qodaLvjlP+tLDGDCs+IKv9Lbsi7kcv0w9541Q0EREPYcoieEQ9KiyECRXHzbpBUOcnYTfPFOOaaGVx9WsLiDrSIp0iU0wFNgIx/AQyc9I/OmOjy+Y8aBvHQcDUYebewc6/Xtk8J5htcg5efEPGhk0JtqkyBjo7DuZcnuO2sqCyKv8rUDmfTS9IBURqBAL+I6CkzBjOMOs22TLY21n8fl17KzXR3uDvb/CQk0GEdfvN07QvpnAOaGfYaRT25JzU6+rnG2tTpcWAy+Cp0m3U/URLms8HWfg/rn6RFaGSs9KQkZMpvGBWNs2Vandt46ac6YNBuc0fDLMaOU5DFybQ8039p/KJ4bq4rwPewtqoM/1gsCm/NfBXvWjgHhhuDAeLyd3qVSifHQULeZkou9EqemLhmUmav8qrZ4GEMGA7ivzjKvfeqGptFV2YdWPMPHHq0cCh3DdpVdLl/XCY9J1gVvbCiWa6N+JLocPFjCsx9cAAAAAASUVORK5CYII=",x=class{constructor(s){t(this,s),this.gatacaLoginCompleted=e(this,"gatacaLoginCompleted",7),this.gatacaLoginFailed=e(this,"gatacaLoginFailed",7),this.gatacaButtonPushed=e(this,"gatacaButtonPushed",7),this.getRequestFromUri=async t=>{const i=new URL(t).searchParams.get("request_uri");if(i){const t=await fetch(i,{method:"GET",headers:{"Content-Type":"application/json"}}),e=(await t.json()).split(".")[1].replace(/-/g,"+").replace(/_/g,"/"),s=window.atob(e);let a=JSON.parse(s);return a.response_mode="dc_api",a}},this.buttonText="Easy login",this.buttonDCAPIText="Login with Device Credentials",this.qrType="svg",this.autostart=!0,this.checkStatus=void 0,this.createSession=void 0,this.fillSession=void 0,this.successCallback=void 0,this.errorCallback=void 0,this.handleCheckAppLoading=void 0,this.checkAppTimeout=6,this.qrRole=void 0,this.callbackServer=void 0,this.sessionTimeout=void 0,this.pollingFrequency=void 0,this.autorefresh=!1,this.v="3",this.qrModalTitle="Quick Access",this.modalTitleColor="#4745B7",this.qrModalDescription="Sign up or sign in by scanning the QR Code with the Gataca Wallet",this.hideBrandTitle=!1,this.dynamicLink=!0,this.logoSize=0,this.logoSrc=void 0,this.qrCodeExpiredLabel="QR Code expired",this.credentialsNotValidatedLabel="User credentials not validated",this.clickInsideBoxLabel="Click inside the box to",this.refreshQrLabel="Refresh QR Code",this.scanQrLabel="Scan QR Code",this.userNotScanInTimeErrorLabel="User did not scan the QR in the allowed time",this.credsNotValidatedErrorLabel="Provided user credentials couldn't be validated",this.failedLoginErrorLabel="No successful login",this.successLoginLabel="Successful Connection!",this.byBrandLabel="by Gataca",this.waitingStartSessionLabel="waiting to start a session",this.enableDcApi=!1,this.hideQrModalDescription=!1,this.qrStyle=void 0,this.open=!1,this.sessionId=void 0,this.authenticationRequest=void 0,this.sessionData=void 0,this.result=r.NOT_STARTED,this.qr=i("gataca-qr",{ref:t=>this.qrElement=t,checkStatus:this.checkStatus,createSession:this.createSession,successCallback:this.successCallback,errorCallback:this.errorCallback,qrRole:this.qrRole,qrType:this.qrType,callbackServer:this.callbackServer,sessionTimeout:this.sessionTimeout,pollingFrequency:this.pollingFrequency,autostart:this.autostart,autorefresh:this.autorefresh,v:this.v,qrModalTitle:this.qrModalTitle,qrModalDescription:this.qrModalDescription,hideBrandTitle:this.hideBrandTitle,dynamicLink:this.dynamicLink,logoSize:this.logoSize,logoSrc:this.logoSrc,modalTitleColor:this.modalTitleColor,qrCodeExpiredLabel:this.qrCodeExpiredLabel,credentialsNotValidatedLabel:this.credentialsNotValidatedLabel,clickInsideBoxLabel:this.clickInsideBoxLabel,refreshQrLabel:this.refreshQrLabel,scanQrLabel:this.scanQrLabel,userNotScanInTimeErrorLabel:this.userNotScanInTimeErrorLabel,credsNotValidatedErrorLabel:this.credsNotValidatedErrorLabel,failedLoginErrorLabel:this.failedLoginErrorLabel,successLoginLabel:this.successLoginLabel,byBrandLabel:this.byBrandLabel,waitingStartSessionLabel:this.waitingStartSessionLabel,hideQrModalDescription:this.hideQrModalDescription,qrStyle:this.qrStyle})}supportsDCAPI(){if(!this.enableDcApi)return!1;if(void 0===window.DigitalCredential)return!1;const t=["org-iso-mdoc","openid4vp","openid4vci"],i=t.filter(window.DigitalCredential.userAgentAllowsProtocol);return console.log(i,t),!0}async getSessionData(){return this.qr.getSessionData()}async getSessionId(){if(this.sessionId)return this.sessionId;let{sessionId:t,authenticationRequest:i}=await this.createSession();return this.sessionId=t,this.authenticationRequest=i,this.sessionId}async startMobilePolling(){await this.getSessionId(),this.result=r.ONGOING,this.poll().then((t=>{this.result=r.SUCCESS,this.sessionData=t,this.gatacaLoginCompleted.emit(t),this.successCallback(t)})).catch((t=>{this.clean();let i=t===r.EXPIRED;if(i&&this.autorefresh)this.startMobilePolling();else if(t!==r.NOT_STARTED){let e=i?new Error(this.userNotScanInTimeErrorLabel):new Error(this.credsNotValidatedErrorLabel);this.result=t,this.gatacaLoginFailed.emit(e),this.errorCallback(e)}}))}async stop(){this.clean(),(this.result===r.ONGOING||r.READ)&&(this.result=r.NOT_STARTED)}clean(){this.sessionData=void 0,this.sessionId=void 0}renderModal(){return this.qr}async poll(){let t=(new Date).getTime()+1e3*(this.sessionTimeout||300),i=1e3*(this.pollingFrequency||3),e=this,s=async function(a,n){let{result:o,data:l}=await(async t=>{if(t.result===r.NOT_STARTED)return{result:r.NOT_STARTED};let i=await t.getSessionId();return t.checkStatus(i)})(e);switch(o){case r.SUCCESS:a(l);break;case r.READ:e.result=r.READ;case r.ONGOING:e.sessionTimeout>0&&(new Date).getTime()<t?setTimeout(s,i,a,n):n(r.EXPIRED);break;default:n(o)}};return new Promise(s)}isAppInstalled(t,i){let e,s=!1;(null==t?void 0:t.length)&&(window.location.href=t),e=setTimeout((()=>{s||i(!1),n()}),1e3*this.checkAppTimeout);const a=()=>{document.hidden&&(s=!0,i(!0),this.autostart||this.startMobilePolling(),n())};function n(){clearTimeout(e),document.removeEventListener("visibilitychange",a)}document.addEventListener("visibilitychange",a)}renderDesktopButton(){return i("div",{class:"gatacaButtonWrapper"},i("button",{class:"gatacaButton",onClick:()=>{this.open=!this.open,setTimeout((()=>{var t,i;this.open?null===(t=this.qrElement)||void 0===t||t.display():null===(i=this.qrElement)||void 0===i||i.stop()}),0)}},i("img",{src:f,class:"buttonImg",alt:this.buttonText}),i("span",null,this.buttonText)))}async getAuthRequest(){let{authenticationRequest:t}=await this.createSession();return t}renderMobileButton(t,e){this.autostart&&!this.supportsDCAPI()&&this.startMobilePolling();let s=!1;const a=t=>{s=t,this.handleCheckAppLoading&&this.handleCheckAppLoading(t)},n=async()=>{a(!0);try{const i=await this.getAuthRequest();this.isAppInstalled(i,(i=>{i||(this.stop(),t?window.location.href="https://play.google.com/store/apps/details?id=com.gataca.identity":e&&(window.location.href="https://apps.apple.com/us/app/gataca/id1498607616")),a(!1)}))}catch(t){this.stop(),a(!1)}};return i("div",{class:"gatacaButtonWrapper"},i("button",{class:"gatacaButton",onClick:()=>{this.gatacaButtonPushed.emit(),n()},disabled:s},i("img",{src:f,class:"buttonImg",alt:this.buttonText}),i("span",null,this.buttonText)))}renderDCAPIButton(t,e){let s=!1;console.log("Maybe act different",t,e);const a=t=>{s=t,this.handleCheckAppLoading&&this.handleCheckAppLoading(t)},n=async()=>{a(!0);try{const t=await this.getAuthRequest();let i=await this.getRequestFromUri(t),e=await navigator.credentials.get({digital:{requests:[{protocol:"openid4vp-v1-unsigned",data:i}]}});"DigitalCredential"==e.constructor.name&&console.log("Digital Credential - Response Data: "+e),await this.fillSession(i,null==e?void 0:e.data)}catch(t){this.stop(),a(!1)}};return i("div",{class:"gatacaButtonWrapper"},i("button",{class:"gatacaButton",onClick:()=>{this.gatacaButtonPushed.emit(),n()},disabled:s},i("img",{src:f,class:"buttonImg",alt:this.buttonDCAPIText}),i("span",null,this.buttonDCAPIText)))}render(){const t=(null===navigator||void 0===navigator?void 0:navigator.userAgent)||(null===navigator||void 0===navigator?void 0:navigator.vendor)||(null===window||void 0===window?void 0:window.opera),e=/android/i.test(t),s=/iPad|iPhone|iPod/.test(t)&&!window.MSStream||"MacIntel"===navigator.platform&&navigator.maxTouchPoints>1,a=e||s,n=this.supportsDCAPI();return i("div",null,i("div",{class:"buttonContainer"},a&&"3"===this.v?this.renderMobileButton(e,s):this.renderDesktopButton(),this.open&&(!a||"3"===this.v)&&this.renderModal()),n&&i("div",{class:"buttonContainer"},this.renderDCAPIButton(e,s)))}};x.style='@import url("https://fonts.googleapis.com/css2?family=Work+Sans:wght@300;400&display=swap"); html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,img,ins,kbd,q,s,samp,small,strike,strong,sub,sup,tt,var,b,u,i,center,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td,article,aside,canvas,details,embed,figure,figcaption,footer,header,hgroup,menu,nav,output,ruby,section,summary,time,mark,audio,video{margin:0;padding:0;border:0;font-size:100%;font:inherit;vertical-align:baseline}article,aside,details,figcaption,figure,footer,header,hgroup,menu,nav,section{display:block}body{line-height:1}ol,ul{list-style:none}blockquote,q{quotes:none}blockquote:before,blockquote:after,q:before,q:after{content:"";content:none}table{border-collapse:collapse;border-spacing:0}.img-fluid{height:auto;max-width:50%}img{margin-left:auto;margin-right:auto}.buttonContainer{display:inline-block;text-align:right;padding:10px;position:relative}.gatacaButtonWrapper{margin:8px}.gatacaButtonWrapper .gatacaButton{display:flex;min-width:100px;padding:8px 8px;background-color:white;font-size:12px;font-family:"Work Sans", sans-serif;letter-spacing:1px;font-weight:2;justify-content:space-between;align-items:center;border-radius:6px;border:1px solid rgba(24, 27, 94, 0.5);color:rgba(24, 27, 94, 0.8);box-shadow:0px 1px 3px rgba(48, 48, 48, 0.15);cursor:pointer}.gatacaButtonWrapper .gatacaButton>span{margin-right:10px}.gatacaButtonWrapper .gatacaButton:hover{box-shadow:0px 2px 8px rgba(48, 48, 48, 0.1)}.gatacaButtonWrapper .buttonText{text-align:right;font-size:8px;color:rgba(24, 27, 94, 0.5);font-family:"Helvetica Neue", sans-serif;letter-spacing:1px;padding-right:8px;font-weight:1}.gatacaButtonWrapper .buttonImg{height:25px;width:25px;margin:0;margin-right:20px}';export{v as gataca_qr,h as gataca_qrdisplay,x as gataca_ssibutton}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{h as i,r as t,c as e}from"./p-fccf9d4d.js";import{a as n,g as a,l as s}from"./p-29119208.js";import{R as o,c as r,b as l}from"./p-0501e224.js";const d=t=>{const{modalHeight:e,successLoginLabel:a}=t;return i("div",{class:"success",style:{height:e?(null==e?void 0:e.toString())+"px":"300px"}},i("img",{src:n,height:52,width:52}),i("p",{class:"successMsg"},a))},h=t=>{var e;const{errorMessage:n,modalWidth:s,clickInsideBoxLabel:o,refreshQrLabel:r,scanQrLabel:l,waitingStartSessionLabel:d,display:h,renderRetryQR:p}=t;return i("div",{class:"reload",style:{width:(s-48).toString()+"px",height:s?(null===(e=s-48)||void 0===e?void 0:e.toString())+"px":""}},i("div",{id:"notify",onClick:()=>h()},i("img",{src:"data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjQiIGhlaWdodD0iMjQiIHZpZXdCb3g9IjAgMCAyNCAyNCIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZD0iTTIzIDRWMTBIMTciIHN0cm9rZT0iIzhCOEI4QiIgc3Ryb2tlLXdpZHRoPSIyIiBzdHJva2UtbGluZWNhcD0icm91bmQiIHN0cm9rZS1saW5lam9pbj0icm91bmQiLz4KPHBhdGggZD0iTTIwLjQ4OTkgMTVDMTkuODM5OSAxNi44Mzk5IDE4LjYwOTQgMTguNDE4NyAxNi45ODQgMTkuNDk4NUMxNS4zNTg2IDIwLjU3ODMgMTMuNDI2MyAyMS4xMDA2IDExLjQ3ODMgMjAuOTg2NkM5LjUzMDI2IDIwLjg3MjYgNy42NzIwMyAyMC4xMjg2IDYuMTgzNjMgMTguODY2N0M0LjY5NTI0IDE3LjYwNDcgMy42NTczIDE1Ljg5MzIgMy4yMjYyNSAxMy45OTAxQzIuNzk1MTkgMTIuMDg2OSAyLjk5NDM2IDEwLjA5NTIgMy43OTM3NCA4LjMxNTA4QzQuNTkzMTMgNi41MzQ5NiA1Ljk0OTQyIDUuMDYyODggNy42NTgyMyA0LjEyMDY1QzkuMzY3MDUgMy4xNzg0MyAxMS4zMzU4IDIuODE3MTEgMTMuMjY3OCAzLjA5MTE2QzE1LjE5OTkgMy4zNjUyIDE2Ljk5MDUgNC4yNTk3NSAxOC4zNjk5IDUuNjQwMDFMMjIuOTk5OSAxMCIgc3Ryb2tlPSIjOEI4QjhCIiBzdHJva2Utd2lkdGg9IjIiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIvPgo8L3N2Zz4K",height:24,width:24}),i("p",{class:"notify-text"},o," "),i("p",{class:"notify-text bold"},n?r:l),n&&i("div",{class:"alert",style:{width:(s-48).toString()+"px"}},i("img",{src:a,height:24,width:24}),i("p",null,n))),i("div",{id:"qrwait"},p(d)))},p=t=>{const{value:e,useLogo:n,logoSrc:a,size:s,qrType:o}=t;return i("gataca-qrdisplay",{qrData:e,rounded:!0,size:s,qrType:o,"logo-size":n?.33:0,"logo-src":a})},c=()=>i("div",{class:"containerLoader"},i("div",{class:"loader"},i("div",{class:"loader__item loader__item__1"}),i("div",{class:"loader__item loader__item__2"}),i("div",{class:"loader__item loader__item__3"}),i("div",{class:"loader__item loader__item__4"}),i("div",{class:"loader__item loader__item__5"}),i("div",{class:"loader__item loader__item__6"}),i("div",{class:"loader__item loader__item__7"}),i("div",{class:"loader__item loader__item__8"}))),m=t=>{var e;const{modalWidth:n,readQrMessages:a,renderQR:s,url:o,sizeQR:r}=t;return i("div",{class:"blured",style:{width:(n-48).toString()+"px",height:n?(null===(e=n-48)||void 0===e?void 0:e.toString())+"px":""}},i("div",{id:"notify"},i(c,null),i("p",{class:"notify-text"},null==a?void 0:a.title," "),i("p",{class:"notify-text bold"},null==a?void 0:a.description)),i("div",{id:"qrwait"},s(o,!1,r)))},g=class{constructor(i){t(this,i),this.gatacaLoginCompleted=e(this,"gatacaLoginCompleted",7),this.gatacaLoginFailed=e(this,"gatacaLoginFailed",7),this.successCallback=void 0,this.errorCallback=void 0,this.qrRole=void 0,this.qrType="svg",this.callbackServer=void 0,this.socketEndpoint=void 0,this.sessionTimeout=300,this.wsOnOpen=void 0,this.wsOnMessage=void 0,this.autostart=!0,this.autorefresh=!1,this.v="3",this.qrModalTitle="Quick Access",this.modalTitleColor="#4745B7",this.qrModalDescription="Sign up or sign in by scanning the QR Code with the Gataca Wallet",this.hideModalTexts=!1,this.hideModalBoxShadow=!1,this.hideBrandTitle=!1,this.logoSize=0,this.logoSrc=s,this.qrSize=300,this.modalWidth=300,this.modalHeight=void 0,this.qrCodeExpiredLabel="QR Code expired",this.credentialsNotValidatedLabel="User credentials not validated",this.clickInsideBoxLabel="Click inside the box to",this.refreshQrLabel="Refresh QR Code",this.scanQrLabel="Scan QR Code",this.userNotScanInTimeErrorLabel="User did not scan the QR in the allowed time",this.credsNotValidatedErrorLabel="Provided user credentials couldn't be validated",this.failedLoginErrorLabel="No successful login",this.successLoginLabel="Successful Connection!",this.byBrandLabel="by Gataca",this.waitingStartSessionLabel="waiting to start a session",this.readQrTitle="Processing...",this.readQrDescription="Please wait a moment",this.hideQrModalDescription=!1,this.dynamicLink=!0,this.sessionId=void 0,this.authenticationRequest=void 0,this.sessionData=void 0,this.result=o.NOT_STARTED}disconnectedCallback(){this.stop()}async componentDidLoad(){this.autostart&&await this.display()}async display(){let i=new WebSocket(this.socketEndpoint);setTimeout((()=>{this.socket.close(1e3,"")}),1e3*this.sessionTimeout),this.socket=i,i.onopen=()=>{this.wsOnOpen&&this.wsOnOpen(this.socket)},i.onmessage=i=>{if(this.wsOnMessage)this.wsOnMessage(this.socket,i);else{let t=JSON.parse(i.data);t.sessionId&&this.handleWSResponse(t)}},i.onerror=()=>{let t=new Error("Error connecting with server");this.result=o.FAILED,this.gatacaLoginFailed.emit(t),this.errorCallback(t),i.close(1e3,"")},i.onclose=()=>{if((this.result===o.ONGOING||o.READ)&&(this.result=o.EXPIRED),this.result===o.EXPIRED)if(this.autorefresh)this.display();else{let i=new Error("User did not scan the QR in the alloted time");this.gatacaLoginFailed.emit(i),this.errorCallback(i)}},r()&&this.dynamicLink&&(window.location.href=this.getLink())}sessionMsgReceived(i){this.handleWSResponse(i.detail)}handleWSResponse(i){switch(this.result=i.result,i.result){case o.ONGOING:case o.READ:this.sessionId=i.sessionId,this.authenticationRequest=i.authenticationRequest;break;case o.SUCCESS:this.sessionData=i.authenticatedUserData,this.gatacaLoginCompleted.emit(i.authenticatedUserData),this.successCallback(i.authenticatedUserData),this.socket.close(1e3,"");break;case o.FAILED:this.socket.close();let t=new Error("Provided user credentials couldn't be validated");this.gatacaLoginFailed.emit(t),this.errorCallback(t);break;case o.EXPIRED:if(this.socket.close(),this.autorefresh)this.display();else{let i=new Error("User did not scan the QR in the alloted time");this.gatacaLoginFailed.emit(i),this.errorCallback(i)}}}async stop(){this.sessionData=void 0,this.sessionId=void 0,this.socket.close(1e3,"Client stopped the connection")}async getSessionData(){return this.sessionData?Promise.resolve(this.sessionData):Promise.reject(new Error("No successful login"))}getLink(){return"2"===this.v&&"connect"==this.qrRole?this.authenticationRequest:"https://api.gataca.io/qr/redirect.html?dl="+l(this.authenticationRequest)}renderQRSection(){switch(this.result){case o.NOT_STARTED:return this.renderRetryButton();case o.ONGOING:return this.renderQR(this.getLink(),!0);case o.EXPIRED:return this.renderRetryButton(this.qrCodeExpiredLabel);case o.FAILED:return this.renderRetryButton(this.credentialsNotValidatedLabel);case o.SUCCESS:return this.renderSuccess();case o.READ:return this.renderReadQR({title:null==this?void 0:this.readQrTitle,description:null==this?void 0:this.readQrDescription})}}renderSuccess(){return i(d,{modalHeight:null==this?void 0:this.modalHeight,successLoginLabel:null==this?void 0:this.successLoginLabel})}renderRetryButton(t){return i(h,{errorMessage:t,modalWidth:null==this?void 0:this.modalWidth,clickInsideBoxLabel:null==this?void 0:this.clickInsideBoxLabel,refreshQrLabel:null==this?void 0:this.refreshQrLabel,scanQrLabel:null==this?void 0:this.scanQrLabel,waitingStartSessionLabel:null==this?void 0:this.waitingStartSessionLabel,display:this.display.bind(this),renderRetryQR:this.renderRetryQR.bind(this)})}renderReadQR(t){return i(m,{modalWidth:null==this?void 0:this.modalWidth,readQrMessages:t,url:this.getLink(),sizeQR:(null==this?void 0:this.qrSize)?(null==this?void 0:this.qrSize)-50:void 0,renderQR:this.renderQR.bind(this)})}renderQR(t,e,n){return i(p,{value:t,qrType:this.qrType,useLogo:e&&0!==this.logoSize,size:n||(null==this?void 0:this.qrSize)||void 0,logoSrc:null==this?void 0:this.logoSrc})}renderRetryQR(t,e){return i(p,{value:t,qrType:this.qrType,useLogo:e&&0!==this.logoSize,size:(null==this?void 0:this.qrSize)?(null==this?void 0:this.qrSize)-50:void 0,logoSrc:null==this?void 0:this.logoSrc})}render(){var t,e;return i("div",{class:"popUpContainer"},i("div",{class:`is-visible modal-window ${this.hideModalTexts?"":"large-modal"} ${this.hideModalBoxShadow?"noBoxShadow":""}`,style:{width:(this.modalWidth-2).toString()+"px",height:this.modalHeight?(null===(t=this.modalHeight-2)||void 0===t?void 0:t.toString())+"px":""},onClick:i=>{i.stopPropagation()}},i("div",{class:"modal-window__content"},i("div",{class:"qrTitleContainer "+(this.hideModalTexts?"hidenText":"")},i("p",{class:"qrTitle modalText",style:{color:this.modalTitleColor||"#1e1e20"}},this.qrModalTitle),!this.hideBrandTitle&&i("p",{class:"qrBrand modalText"},this.byBrandLabel," ",i("span",null,i("img",{src:s}))),this.result!==o.SUCCESS&&!this.hideQrModalDescription&&i("p",{class:"qrDescription modalText"},this.qrModalDescription)),i("div",{class:"qrSection",style:{width:this.modalWidth.toString()+"px",height:this.modalWidth?(null===(e=this.modalWidth)||void 0===e?void 0:e.toString())+"px":""}},this.renderQRSection()))))}};g.style='@import url("https://fonts.googleapis.com/css2?family=Ubuntu:wght@100;300;400;500;600;700&display=swap"); @import url("https://fonts.googleapis.com/css2?family=Poppins:wght@100;300;400;500;600;700&display=swap"); @import url("https://fonts.googleapis.com/css2?family=Work+Sans:wght@300;400&display=swap"); html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,img,ins,kbd,q,s,samp,small,strike,strong,sub,sup,tt,var,b,u,i,center,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td,article,aside,canvas,details,embed,figure,figcaption,footer,header,hgroup,menu,nav,output,ruby,section,summary,time,mark,audio,video{margin:0;padding:0;border:0;font-size:100%;font:inherit;vertical-align:baseline}article,aside,details,figcaption,figure,footer,header,hgroup,menu,nav,section{display:block}body{line-height:1}ol,ul{list-style:none}blockquote,q{quotes:none}blockquote:before,blockquote:after,q:before,q:after{content:"";content:none}table{border-collapse:collapse;border-spacing:0}.img-fluid{height:auto;max-width:50%}img{margin-left:auto;margin-right:auto}.brandSection{padding-top:5px;display:flex;align-items:center}.brandSection .gatacaImgSmall{height:13px;width:13px;margin:0;margin-right:10px}.popUpContainer .large-modal{width:300px;min-height:350px}.popUpContainer .modal-window{position:relative;border-radius:6px;overflow:hidden;color:rgba(24, 27, 94, 0.8);box-shadow:0px 3px 10px rgba(48, 48, 48, 0.1);display:flex;flex-direction:column;justify-content:space-between;align-items:center;display:flex;z-index:1001;padding:1px;background-color:white;border-radius:12px;-webkit-transition:opacity 0.5s, visibility 0s 0.5s;transition:opacity 0.5s, visibility 0s 0.5s;visibility:hidden;opacity:0}.popUpContainer .modal-window__content{width:100%;height:100%;text-align:left}.popUpContainer .modal-window__content .hidenText{display:none}.popUpContainer .modal-window .modalText{font-family:"Ubuntu", "Work Sans", "Helvetica Neue", sans-serif;font-size:20px;font-style:normal;font-weight:700;line-height:24px;margin-top:10px;letter-spacing:1px}.popUpContainer .modal-window .qrTitleContainer{padding:14px 24px;padding-bottom:0px}.popUpContainer .modal-window .qrTitle{font-size:20px;font-weight:600;line-height:23.5px}.popUpContainer .modal-window .qrDescription{font-family:"Poppins", "Ubuntu", "Work Sans", "Helvetica Neue", sans-serif;font-size:14px;font-style:normal;font-weight:400;line-height:16px;color:#707074}.popUpContainer .modal-window .bold{font-weight:700}.popUpContainer .modal-window .qrBrand{margin-top:4px;font-size:14px;font-weight:400;line-height:16.5px;display:flex;align-items:center}.popUpContainer .modal-window .qrBrand img{margin-left:5px;height:12px}.popUpContainer .modal-window .qr-section{width:252px;height:252px}.popUpContainer .noBoxShadow{box-shadow:none}.popUpContainer .is-visible{opacity:1;visibility:visible}.is-transparent{opacity:0}.success{display:flex;height:300px;flex-direction:column;justify-content:center;align-items:center;padding:0px}.success>img{padding-bottom:12px}.success>.successMsg{line-height:23.5px;color:var(--neutral-1000, #1e1e20);text-align:center;font-family:"Ubuntu", "Work Sans", "Helvetica Neue", sans-serif;font-size:20px;font-style:normal;font-weight:700;line-height:24px}.reload,.blured{height:252px;width:252px;border:1px dashed #a1a1a1;border-radius:12px;position:relative;top:24px;margin:0 24px 24px;display:flex;overflow:hidden;justify-content:center;align-items:center}#qrwait{display:flex;justify-content:center}#qrwait,#notify{width:100%;height:100%;top:0;left:0;border-radius:20px}#notify{z-index:10;position:absolute;justify-self:center;justify-items:center;justify-content:center;align-items:center;align-content:center;display:flex;flex-direction:column;box-sizing:border-box;padding:20px;background:rgba(255, 255, 255, 0.95)}#notify>img{padding-bottom:12px}.alert{display:flex;flex-direction:row;justify-content:start;width:252px;position:absolute;bottom:0px;border:1px solid #ee888c;background:#ffdedf;border-radius:11px;box-sizing:border-box;padding:12px;align-items:center;gap:12px}.alert>img{margin:0}.alert>p{font-family:"Poppins", "Ubuntu", "Work Sans", "Helvetica Neue", sans-serif;font-size:14px;font-style:normal;font-weight:400;margin-top:0;line-height:16px;color:#1e1e20}.notify-text{font-family:"Poppins", "Ubuntu", "Work Sans", "Helvetica Neue", sans-serif;font-size:14px;font-style:normal;font-weight:400;line-height:16px;color:#707074;text-align:center}.containerLoader{display:flex;justify-content:center;align-items:center;width:30px;height:30px;margin-bottom:12px}.loader{position:relative;margin-left:0 !important}.loader__item{position:absolute;width:9.68px;height:4px;background:transparent;border-radius:2px}.loader__item__1{transform:translate(2.5846212025px, 5.4246212025px) rotate(45deg);-webkit-animation:translate(2.5846212025px, 5.4246212025px) rotate(45deg);-moz-animation:translate(2.5846212025px, 5.4246212025px) rotate(45deg);-o-animation:translate(2.5846212025px, 5.4246212025px) rotate(45deg);animation:blink 0.8333333333s linear 0.1041666667s infinite;-webkit-animation:blink 0.8333333333s linear 0.1041666667s infinite;-moz-animation:blink 0.8333333333s linear 0.1041666667s infinite;-o-animation:blink 0.8333333333s linear 0.1041666667s infinite}.loader__item__2{transform:translate(-4.84px, 8.5px) rotate(90deg);-webkit-animation:translate(-4.84px, 8.5px) rotate(90deg);-moz-animation:translate(-4.84px, 8.5px) rotate(90deg);-o-animation:translate(-4.84px, 8.5px) rotate(90deg);animation:blink 0.8333333333s linear 0.2083333333s infinite;-webkit-animation:blink 0.8333333333s linear 0.2083333333s infinite;-moz-animation:blink 0.8333333333s linear 0.2083333333s infinite;-o-animation:blink 0.8333333333s linear 0.2083333333s infinite}.loader__item__3{transform:translate(-12.2646212025px, 5.4246212025px) rotate(135deg);-webkit-animation:translate(-12.2646212025px, 5.4246212025px) rotate(135deg);-moz-animation:translate(-12.2646212025px, 5.4246212025px) rotate(135deg);-o-animation:translate(-12.2646212025px, 5.4246212025px) rotate(135deg);animation:blink 0.8333333333s linear 0.3125s infinite;-webkit-animation:blink 0.8333333333s linear 0.3125s infinite;-moz-animation:blink 0.8333333333s linear 0.3125s infinite;-o-animation:blink 0.8333333333s linear 0.3125s infinite}.loader__item__4{transform:translate(-15.3399999992px, -1.9999999999px) rotate(180deg);-webkit-animation:translate(-15.3399999992px, -1.9999999999px) rotate(180deg);-moz-animation:translate(-15.3399999992px, -1.9999999999px) rotate(180deg);-o-animation:translate(-15.3399999992px, -1.9999999999px) rotate(180deg);animation:blink 0.8333333333s linear 0.4166666667s infinite;-webkit-animation:blink 0.8333333333s linear 0.4166666667s infinite;-moz-animation:blink 0.8333333333s linear 0.4166666667s infinite;-o-animation:blink 0.8333333333s linear 0.4166666667s infinite}.loader__item__5{transform:translate(-12.2646210959px, -9.4246211842px) rotate(225deg);-webkit-animation:translate(-12.2646210959px, -9.4246211842px) rotate(225deg);-moz-animation:translate(-12.2646210959px, -9.4246211842px) rotate(225deg);-o-animation:translate(-12.2646210959px, -9.4246211842px) rotate(225deg);animation:blink 0.8333333333s linear 0.5208333333s infinite;-webkit-animation:blink 0.8333333333s linear 0.5208333333s infinite;-moz-animation:blink 0.8333333333s linear 0.5208333333s infinite;-o-animation:blink 0.8333333333s linear 0.5208333333s infinite}.loader__item__6{transform:translate(-4.8399941857px, -12.499998805px) rotate(270deg);-webkit-animation:translate(-4.8399941857px, -12.499998805px) rotate(270deg);-moz-animation:translate(-4.8399941857px, -12.499998805px) rotate(270deg);-o-animation:translate(-4.8399941857px, -12.499998805px) rotate(270deg);animation:blink 0.8333333333s linear 0.625s infinite;-webkit-animation:blink 0.8333333333s linear 0.625s infinite;-moz-animation:blink 0.8333333333s linear 0.625s infinite;-o-animation:blink 0.8333333333s linear 0.625s infinite}.loader__item__7{transform:translate(2.5847915061px, -9.4245803212px) rotate(315deg);-webkit-animation:translate(2.5847915061px, -9.4245803212px) rotate(315deg);-moz-animation:translate(2.5847915061px, -9.4245803212px) rotate(315deg);-o-animation:translate(2.5847915061px, -9.4245803212px) rotate(315deg);animation:blink 0.8333333333s linear 0.7291666667s infinite;-webkit-animation:blink 0.8333333333s linear 0.7291666667s infinite;-moz-animation:blink 0.8333333333s linear 0.7291666667s infinite;-o-animation:blink 0.8333333333s linear 0.7291666667s infinite}.loader__item__8{transform:translate(5.6631628524px, -1.99913122px) rotate(360deg);-webkit-animation:translate(5.6631628524px, -1.99913122px) rotate(360deg);-moz-animation:translate(5.6631628524px, -1.99913122px) rotate(360deg);-o-animation:translate(5.6631628524px, -1.99913122px) rotate(360deg);animation:blink 0.8333333333s linear 0.8333333333s infinite;-webkit-animation:blink 0.8333333333s linear 0.8333333333s infinite;-moz-animation:blink 0.8333333333s linear 0.8333333333s infinite;-o-animation:blink 0.8333333333s linear 0.8333333333s infinite}.loader__item__8{max-width:8.5px}@keyframes blink{0%{background:#4745B7}100%{background:#CCCBF8}}@keyframes rotate{0%{transform:rotate(0deg)}100%{background:rotate(360deg)}}';export{g as gataca_qrws}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
let t,e,n=!1,l=!1;const s={},o=t=>"object"==(t=typeof t)||"function"===t,r=(t,e,...n)=>{let l=null,s=!1,r=!1;const i=[],a=e=>{for(let n=0;n<e.length;n++)l=e[n],Array.isArray(l)?a(l):null!=l&&"boolean"!=typeof l&&((s="function"!=typeof t&&!o(l))&&(l+=""),s&&r?i[i.length-1].t+=l:i.push(s?c(null,l):l),r=s)};if(a(n),e){const t=e.className||e.class;t&&(e.class="object"!=typeof t?t:Object.keys(t).filter((e=>t[e])).join(" "))}if("function"==typeof t)return t(null===e?{}:e,i,u);const f=c(t,null);return f.l=e,i.length>0&&(f.o=i),f},c=(t,e)=>({i:0,u:t,t:e,h:null,o:null,l:null}),i={},u={forEach:(t,e)=>t.map(a).forEach(e),map:(t,e)=>t.map(a).map(e).map(f)},a=t=>({vattrs:t.l,vchildren:t.o,vkey:t.p,vname:t.m,vtag:t.u,vtext:t.t}),f=t=>{if("function"==typeof t.vtag){const e=Object.assign({},t.vattrs);return t.vkey&&(e.key=t.vkey),t.vname&&(e.name=t.vname),r(t.vtag,e,...t.vchildren||[])}const e=c(t.vtag,t.vtext);return e.l=t.vattrs,e.o=t.vchildren,e.p=t.vkey,e.m=t.vname,e},h=(t,e,n)=>{const l=(t=>V(t).$)(t);return{emit:t=>d(l,e,{bubbles:!!(4&n),composed:!!(2&n),cancelable:!!(1&n),detail:t})}},d=(t,e,n)=>{const l=Y.ce(e,n);return t.dispatchEvent(l),l},p=new WeakMap,y=t=>"sc-"+t.g,m=(t,e,n,l,s,r)=>{if(n!==l){let c=B(t,e),i=e.toLowerCase();if("class"===e){const e=t.classList,s=b(n),o=b(l);e.remove(...s.filter((t=>t&&!o.includes(t)))),e.add(...o.filter((t=>t&&!s.includes(t))))}else if("style"===e){for(const e in n)l&&null!=l[e]||(e.includes("-")?t.style.removeProperty(e):t.style[e]="");for(const e in l)n&&l[e]===n[e]||(e.includes("-")?t.style.setProperty(e,l[e]):t.style[e]=l[e])}else if("ref"===e)l&&l(t);else if(c||"o"!==e[0]||"n"!==e[1]){const i=o(l);if((c||i&&null!==l)&&!s)try{if(t.tagName.includes("-"))t[e]=l;else{const s=null==l?"":l;"list"===e?c=!1:null!=n&&t[e]==s||(t[e]=s)}}catch(t){}null==l||!1===l?!1===l&&""!==t.getAttribute(e)||t.removeAttribute(e):(!c||4&r||s)&&!i&&t.setAttribute(e,l=!0===l?"":l)}else e="-"===e[2]?e.slice(3):B(Q,i)?i.slice(2):i[2]+e.slice(3),n&&Y.rel(t,e,n,!1),l&&Y.ael(t,e,l,!1)}},$=/\s/,b=t=>t?t.split($):[],w=(t,e,n,l)=>{const o=11===e.h.nodeType&&e.h.host?e.h.host:e.h,r=t&&t.l||s,c=e.l||s;for(l in r)l in c||m(o,l,r[l],void 0,n,e.i);for(l in c)m(o,l,r[l],c[l],n,e.i)},g=(e,l,s)=>{const o=l.o[s];let r,c,i=0;if(null!==o.t)r=o.h=X.createTextNode(o.t);else{if(n||(n="svg"===o.u),r=o.h=X.createElementNS(n?"http://www.w3.org/2000/svg":"http://www.w3.org/1999/xhtml",o.u),n&&"foreignObject"===o.u&&(n=!1),w(null,o,n),null!=t&&r["s-si"]!==t&&r.classList.add(r["s-si"]=t),o.o)for(i=0;i<o.o.length;++i)c=g(e,o,i),c&&r.appendChild(c);"svg"===o.u?n=!1:"foreignObject"===r.tagName&&(n=!0)}return r},v=(t,n,l,s,o,r)=>{let c,i=t;for(i.shadowRoot&&i.tagName===e&&(i=i.shadowRoot);o<=r;++o)s[o]&&(c=g(null,l,o),c&&(s[o].h=c,i.insertBefore(c,n)))},j=(t,e,n,l,s)=>{for(;e<=n;++e)(l=t[e])&&(s=l.h,k(l),s.remove())},S=(t,e)=>t.u===e.u,O=(t,e)=>{const l=e.h=t.h,s=t.o,o=e.o,r=e.u,c=e.t;null===c?(n="svg"===r||"foreignObject"!==r&&n,w(t,e,n),null!==s&&null!==o?((t,e,n,l)=>{let s,o=0,r=0,c=e.length-1,i=e[0],u=e[c],a=l.length-1,f=l[0],h=l[a];for(;o<=c&&r<=a;)null==i?i=e[++o]:null==u?u=e[--c]:null==f?f=l[++r]:null==h?h=l[--a]:S(i,f)?(O(i,f),i=e[++o],f=l[++r]):S(u,h)?(O(u,h),u=e[--c],h=l[--a]):S(i,h)?(O(i,h),t.insertBefore(i.h,u.h.nextSibling),i=e[++o],h=l[--a]):S(u,f)?(O(u,f),t.insertBefore(u.h,i.h),u=e[--c],f=l[++r]):(s=g(e&&e[r],n,r),f=l[++r],s&&i.h.parentNode.insertBefore(s,i.h));o>c?v(t,null==l[a+1]?null:l[a+1].h,n,l,r,a):r>a&&j(e,o,c)})(l,s,e,o):null!==o?(null!==t.t&&(l.textContent=""),v(l,null,e,o,0,o.length-1)):null!==s&&j(s,0,s.length-1),n&&"svg"===r&&(n=!1)):t.t!==c&&(l.data=c)},k=t=>{t.l&&t.l.ref&&t.l.ref(null),t.o&&t.o.map(k)},M=(t,e)=>{e&&!t.v&&e["s-p"]&&e["s-p"].push(new Promise((e=>t.v=e)))},C=(t,e)=>{if(t.i|=16,!(4&t.i))return M(t,t.j),ct((()=>x(t,e)));t.i|=512},x=(t,e)=>{const n=t.S;return e&&(t.i|=256,t.O&&(t.O.map((([t,e])=>T(n,t,e))),t.O=null)),q(void 0,(()=>P(t,n,e)))},P=async(t,e,n)=>{const l=t.$,s=l["s-rc"];n&&(t=>{const e=t.k,n=t.$,l=e.i,s=((t,e)=>{let n=y(e);const l=K.get(n);if(t=11===t.nodeType?t:X,l)if("string"==typeof l){let e,s=p.get(t=t.head||t);s||p.set(t,s=new Set),s.has(n)||(e=X.createElement("style"),e.innerHTML=l,t.insertBefore(e,t.querySelector("link")),s&&s.add(n))}else t.adoptedStyleSheets.includes(l)||(t.adoptedStyleSheets=[...t.adoptedStyleSheets,l]);return n})(n.shadowRoot?n.shadowRoot:n.getRootNode(),e);10&l&&(n["s-sc"]=s,n.classList.add(s+"-h"))})(t);E(t,e),s&&(s.map((t=>t())),l["s-rc"]=void 0);{const e=l["s-p"],n=()=>L(t);0===e.length?n():(Promise.all(e).then(n),t.i|=4,e.length=0)}},E=(n,l)=>{try{l=l.render(),n.i&=-17,n.i|=2,((n,l)=>{const s=n.$,o=n.M||c(null,null),u=(t=>t&&t.u===i)(l)?l:r(null,null,l);e=s.tagName,u.u=null,u.i|=4,n.M=u,u.h=o.h=s.shadowRoot||s,t=s["s-sc"],O(o,u)})(n,l)}catch(t){G(t,n.$)}return null},L=t=>{const e=t.$,n=t.S,l=t.j;64&t.i||(t.i|=64,A(e),T(n,"componentDidLoad"),t.C(e),l||N()),t.P(e),t.v&&(t.v(),t.v=void 0),512&t.i&&rt((()=>C(t,!1))),t.i&=-517},N=()=>{A(X.documentElement),rt((()=>d(Q,"appload",{detail:{namespace:"gatacaqr"}})))},T=(t,e,n)=>{if(t&&t[e])try{return t[e](n)}catch(t){G(t)}},q=(t,e)=>t&&t.then?t.then(e):e(),A=t=>t.classList.add("hydrated"),F=(t,e,n)=>{if(e.L){const l=Object.entries(e.L),s=t.prototype;if(l.map((([t,[l]])=>{31&l||2&n&&32&l?Object.defineProperty(s,t,{get(){return((t,e)=>V(this).N.get(e))(0,t)},set(n){((t,e,n,l)=>{const s=V(t),r=s.N.get(e),c=s.i,i=s.S;n=((t,e)=>null==t||o(t)?t:4&e?"false"!==t&&(""===t||!!t):2&e?parseFloat(t):1&e?t+"":t)(n,l.L[e][0]),8&c&&void 0!==r||n===r||Number.isNaN(r)&&Number.isNaN(n)||(s.N.set(e,n),i&&2==(18&c)&&C(s,!1))})(this,t,n,e)},configurable:!0,enumerable:!0}):1&n&&64&l&&Object.defineProperty(s,t,{value(...e){const n=V(this);return n.T.then((()=>n.S[t](...e)))}})})),1&n){const e=new Map;s.attributeChangedCallback=function(t,n,l){Y.jmp((()=>{const n=e.get(t);if(this.hasOwnProperty(n))l=this[n],delete this[n];else if(s.hasOwnProperty(n)&&"number"==typeof this[n]&&this[n]==l)return;this[n]=(null!==l||"boolean"!=typeof this[n])&&l}))},t.observedAttributes=l.filter((([t,e])=>15&e[0])).map((([t,n])=>{const l=n[1]||t;return e.set(l,t),l}))}}return t},R=(t,e={})=>{const n=[],l=e.exclude||[],s=Q.customElements,o=X.head,r=o.querySelector("meta[charset]"),c=X.createElement("style"),i=[];let u,a=!0;Object.assign(Y,e),Y.q=new URL(e.resourcesUrl||"./",X.baseURI).href,t.map((t=>{t[1].map((e=>{const o={i:e[0],g:e[1],L:e[2],A:e[3]};o.L=e[2],o.A=e[3];const r=o.g,c=class extends HTMLElement{constructor(t){super(t),z(t=this,o),1&o.i&&t.attachShadow({mode:"open"})}connectedCallback(){u&&(clearTimeout(u),u=null),a?i.push(this):Y.jmp((()=>(t=>{if(0==(1&Y.i)){const e=V(t),n=e.k,l=()=>{};if(1&e.i)U(t,e,n.A);else{e.i|=1;{let n=t;for(;n=n.parentNode||n.host;)if(n["s-p"]){M(e,e.j=n);break}}n.L&&Object.entries(n.L).map((([e,[n]])=>{if(31&n&&t.hasOwnProperty(e)){const n=t[e];delete t[e],t[e]=n}})),(async(t,e,n,l,s)=>{if(0==(32&e.i)){{if(e.i|=32,(s=J(n)).then){const t=()=>{};s=await s,t()}s.isProxied||(F(s,n,2),s.isProxied=!0);const t=()=>{};e.i|=8;try{new s(e)}catch(t){G(t)}e.i&=-9,t()}if(s.style){let t=s.style;const e=y(n);if(!K.has(e)){const l=()=>{};((t,e,n)=>{let l=K.get(t);tt&&n?(l=l||new CSSStyleSheet,"string"==typeof l?l=e:l.replaceSync(e)):l=e,K.set(t,l)})(e,t,!!(1&n.i)),l()}}}const o=e.j,r=()=>C(e,!0);o&&o["s-rc"]?o["s-rc"].push(r):r()})(0,e,n)}l()}})(this)))}disconnectedCallback(){Y.jmp((()=>(()=>{if(0==(1&Y.i)){const t=V(this),e=t.S;t.F&&(t.F.map((t=>t())),t.F=void 0),T(e,"disconnectedCallback")}})()))}componentOnReady(){return V(this).R}};o.U=t[0],l.includes(r)||s.get(r)||(n.push(r),s.define(r,F(c,o,1)))}))})),c.innerHTML=n+"{visibility:hidden}.hydrated{visibility:inherit}",c.setAttribute("data-styles",""),o.insertBefore(c,r?r.nextSibling:o.firstChild),a=!1,i.length?i.map((t=>t.connectedCallback())):Y.jmp((()=>u=setTimeout(N,30)))},U=(t,e,n)=>{n&&n.map((([n,l,s])=>{const o=t,r=W(e,s),c=D(n);Y.ael(o,l,r,c),(e.F=e.F||[]).push((()=>Y.rel(o,l,r,c)))}))},W=(t,e)=>n=>{try{256&t.i?t.S[e](n):(t.O=t.O||[]).push([e,n])}catch(t){G(t)}},D=t=>0!=(2&t),H=new WeakMap,V=t=>H.get(t),_=(t,e)=>H.set(e.S=t,e),z=(t,e)=>{const n={i:0,$:t,k:e,N:new Map};return n.T=new Promise((t=>n.P=t)),n.R=new Promise((t=>n.C=t)),t["s-p"]=[],t["s-rc"]=[],U(t,n,e.A),H.set(t,n)},B=(t,e)=>e in t,G=(t,e)=>(0,console.error)(t,e),I=new Map,J=t=>{const e=t.g.replace(/-/g,"_"),n=t.U,l=I.get(n);return l?l[e]:import(`./${n}.entry.js`).then((t=>(I.set(n,t),t[e])),G)
|
|
2
|
-
/*!__STENCIL_STATIC_IMPORT_SWITCH__*/},K=new Map,Q="undefined"!=typeof window?window:{},X=Q.document||{head:{}},Y={i:0,q:"",jmp:t=>t(),raf:t=>requestAnimationFrame(t),ael:(t,e,n,l)=>t.addEventListener(e,n,l),rel:(t,e,n,l)=>t.removeEventListener(e,n,l),ce:(t,e)=>new CustomEvent(t,e)},Z=t=>Promise.resolve(t),tt=(()=>{try{return new CSSStyleSheet,"function"==typeof(new CSSStyleSheet).replaceSync}catch(t){}return!1})(),et=[],nt=[],lt=(t,e)=>n=>{t.push(n),l||(l=!0,e&&4&Y.i?rt(ot):Y.raf(ot))},st=t=>{for(let e=0;e<t.length;e++)try{t[e](performance.now())}catch(t){G(t)}t.length=0},ot=()=>{st(et),st(nt),(l=et.length>0)&&Y.raf(ot)},rt=t=>Z().then(t),ct=lt(nt,!0);export{R as b,h as c,r as h,Z as p,_ as r}
|