@ticketlayer/elements 0.3.2 → 0.4.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 +16 -15
- package/dist/cjs/{index-DfzcrE9-.js → index-I9CoYv3k.js} +277 -1798
- package/dist/cjs/index.cjs.js +1 -1
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/money-BtmM2gt-.js +118 -0
- package/dist/cjs/{order-summary-ZMkJ5bez.js → order-summary-X3TlZxc2.js} +34 -0
- package/dist/cjs/ticketlayer-elements.cjs.js +3 -3
- package/dist/cjs/tl-buy-modal.cjs.entry.js +3 -3
- package/dist/cjs/tl-buy-tickets-button.cjs.entry.js +10 -7
- package/dist/cjs/tl-buy-tickets-wrapper.cjs.entry.js +2 -2
- package/dist/cjs/tl-cart-badge.cjs.entry.js +2 -2
- package/dist/cjs/tl-cart-drawer.cjs.entry.js +2 -2
- package/dist/cjs/tl-cart.cjs.entry.js +10 -4
- package/dist/cjs/tl-checkout-wrapper.cjs.entry.js +2 -2
- package/dist/cjs/tl-event-card.cjs.entry.js +4 -3
- package/dist/cjs/tl-event-list.cjs.entry.js +2 -2
- package/dist/cjs/tl-login.cjs.entry.js +4 -3
- package/dist/cjs/tl-my-orders.cjs.entry.js +4 -3
- package/dist/cjs/tl-occurrence-selector_2.cjs.entry.js +454 -122
- package/dist/cjs/tl-order-confirmation.cjs.entry.js +11 -8
- package/dist/cjs/tl-order-tickets_2.cjs.entry.js +3 -3
- package/dist/cjs/tl-promo-code.cjs.entry.js +4 -3
- package/dist/cjs/tl-seat-map.cjs.entry.js +2 -2
- package/dist/collection/collection-manifest.json +2 -1
- package/dist/collection/components/tl-buy-modal/tl-buy-modal.css +12 -13
- package/dist/collection/components/tl-buy-modal/tl-buy-modal.js +1 -1
- package/dist/collection/components/tl-buy-tickets-button/tl-buy-tickets-button.css +4 -4
- package/dist/collection/components/tl-buy-tickets-button/tl-buy-tickets-button.js +11 -8
- package/dist/collection/components/tl-buy-tickets-wrapper/tl-buy-tickets-wrapper.css +2 -2
- package/dist/collection/components/tl-cart/tl-cart.css +52 -51
- package/dist/collection/components/tl-cart/tl-cart.js +10 -4
- package/dist/collection/components/tl-cart-badge/tl-cart-badge.css +11 -11
- package/dist/collection/components/tl-cart-drawer/tl-cart-drawer.css +6 -6
- package/dist/collection/components/tl-checkout-wrapper/tl-checkout-wrapper.css +2 -2
- package/dist/collection/components/tl-event-card/tl-event-card.css +22 -22
- package/dist/collection/components/tl-event-card/tl-event-card.js +1 -1
- package/dist/collection/components/tl-event-list/tl-event-list.css +17 -17
- package/dist/collection/components/tl-login/tl-login.css +26 -26
- package/dist/collection/components/tl-login/tl-login.js +1 -1
- package/dist/collection/components/tl-my-orders/tl-my-orders.css +40 -40
- package/dist/collection/components/tl-occurrence-selector/tl-occurrence-selector.css +54 -65
- package/dist/collection/components/tl-occurrence-selector/tl-occurrence-selector.js +2 -2
- package/dist/collection/components/tl-order-confirmation/tl-order-confirmation.css +38 -38
- package/dist/collection/components/tl-order-confirmation/tl-order-confirmation.js +8 -6
- package/dist/collection/components/tl-order-tickets/tl-order-tickets.css +9 -9
- package/dist/collection/components/tl-promo-code/tl-promo-code.css +25 -25
- package/dist/collection/components/tl-promo-code/tl-promo-code.js +1 -1
- package/dist/collection/components/tl-seat-map/tl-seat-map.css +10 -10
- package/dist/collection/components/tl-ticket/tl-ticket.css +13 -13
- package/dist/collection/components/tl-ticket/tl-ticket.js +1 -1
- package/dist/collection/components/tl-ticket-selector/tl-ticket-selector.css +74 -49
- package/dist/collection/components/tl-ticket-selector/tl-ticket-selector.js +73 -127
- package/dist/collection/utils/cart-totals.js +9 -0
- package/dist/collection/utils/order-summary.js +36 -0
- package/dist/components/money.js +1 -0
- package/dist/components/order-summary.js +1 -1
- package/dist/components/tl-buy-modal.js +1 -1
- package/dist/components/tl-buy-tickets-button.js +1 -1
- package/dist/components/tl-buy-tickets-wrapper2.js +1 -1
- package/dist/components/tl-cart-badge.js +1 -1
- package/dist/components/tl-cart-drawer.js +1 -1
- package/dist/components/tl-cart2.js +1 -1
- package/dist/components/tl-checkout-wrapper2.js +1 -1
- package/dist/components/tl-event-card2.js +1 -1
- package/dist/components/tl-event-list.js +1 -1
- package/dist/components/tl-login2.js +1 -1
- package/dist/components/tl-my-orders.js +1 -1
- package/dist/components/tl-occurrence-selector2.js +1 -1
- package/dist/components/tl-order-confirmation.js +1 -1
- package/dist/components/tl-order-tickets2.js +1 -1
- package/dist/components/tl-promo-code.js +1 -1
- package/dist/components/tl-seat-map.js +1 -1
- package/dist/components/tl-ticket-selector2.js +1 -1
- package/dist/components/tl-ticket2.js +1 -1
- package/dist/elements.docs.d.ts +26 -0
- package/dist/elements.docs.json +35 -17
- package/dist/esm/{index-Ba-RZTFI.js → index-OoYV1faY.js} +277 -1798
- package/dist/esm/index.js +1 -1
- package/dist/esm/loader.js +3 -3
- package/dist/esm/money-4ig0-WB6.js +112 -0
- package/dist/esm/{order-summary-BGekdjN9.js → order-summary-DiDtvfZM.js} +34 -1
- package/dist/esm/ticketlayer-elements.js +4 -4
- package/dist/esm/tl-buy-modal.entry.js +3 -3
- package/dist/esm/tl-buy-tickets-button.entry.js +10 -7
- package/dist/esm/tl-buy-tickets-wrapper.entry.js +2 -2
- package/dist/esm/tl-cart-badge.entry.js +2 -2
- package/dist/esm/tl-cart-drawer.entry.js +2 -2
- package/dist/esm/tl-cart.entry.js +10 -4
- package/dist/esm/tl-checkout-wrapper.entry.js +2 -2
- package/dist/esm/tl-event-card.entry.js +4 -3
- package/dist/esm/tl-event-list.entry.js +2 -2
- package/dist/esm/tl-login.entry.js +4 -3
- package/dist/esm/tl-my-orders.entry.js +4 -3
- package/dist/esm/tl-occurrence-selector_2.entry.js +455 -123
- package/dist/esm/tl-order-confirmation.entry.js +11 -8
- package/dist/esm/tl-order-tickets_2.entry.js +3 -3
- package/dist/esm/tl-promo-code.entry.js +4 -3
- package/dist/esm/tl-seat-map.entry.js +2 -2
- package/dist/ticketlayer-elements/index.esm.js +1 -1
- package/dist/ticketlayer-elements/p-0814420f.entry.js +1 -0
- package/dist/ticketlayer-elements/p-0acabc26.entry.js +1 -0
- package/dist/ticketlayer-elements/{p-9372ff1f.entry.js → p-109a3feb.entry.js} +1 -1
- package/dist/ticketlayer-elements/{p-41d22d7c.entry.js → p-1a4ba71c.entry.js} +1 -1
- package/dist/ticketlayer-elements/p-318965c1.entry.js +1 -0
- package/dist/ticketlayer-elements/p-347c7fd1.entry.js +1 -0
- package/dist/ticketlayer-elements/p-3649c26d.entry.js +1 -0
- package/dist/ticketlayer-elements/p-40260cc9.entry.js +1 -0
- package/dist/ticketlayer-elements/p-4ig0-WB6.js +1 -0
- package/dist/ticketlayer-elements/p-55fd2f9f.entry.js +1 -0
- package/dist/ticketlayer-elements/p-62ee659b.entry.js +1 -0
- package/dist/ticketlayer-elements/{p-f446310d.entry.js → p-7d4ecc2b.entry.js} +1 -1
- package/dist/ticketlayer-elements/p-7f0abf95.entry.js +1 -0
- package/dist/ticketlayer-elements/p-BXpVGW51.js +1 -0
- package/dist/ticketlayer-elements/p-OoYV1faY.js +3 -0
- package/dist/ticketlayer-elements/p-a3c1b26c.entry.js +1 -0
- package/dist/ticketlayer-elements/p-ac264adc.entry.js +1 -0
- package/dist/ticketlayer-elements/{p-82752e3b.entry.js → p-aeb4c6fb.entry.js} +1 -1
- package/dist/ticketlayer-elements/{p-9c9072c8.entry.js → p-ba62541f.entry.js} +1 -1
- package/dist/ticketlayer-elements/ticketlayer-elements.css +1 -1
- package/dist/ticketlayer-elements/ticketlayer-elements.esm.js +1 -1
- package/dist/types/components/tl-cart/tl-cart.d.ts +10 -0
- package/dist/types/components/tl-ticket-selector/tl-ticket-selector.d.ts +40 -29
- package/dist/types/components.d.ts +165 -36
- package/dist/types/stencil-public-runtime.d.ts +97 -57
- package/dist/types/utils/cart-totals.d.ts +10 -0
- package/dist/types/utils/order-summary.d.ts +34 -0
- package/elements.catalogue.json +91 -22
- package/loader/index.d.ts +1 -1
- package/package.json +31 -32
- package/dist/ticketlayer-elements/p-0291df4c.entry.js +0 -1
- package/dist/ticketlayer-elements/p-11273f8f.entry.js +0 -1
- package/dist/ticketlayer-elements/p-340ab4f5.entry.js +0 -1
- package/dist/ticketlayer-elements/p-7ff43848.entry.js +0 -1
- package/dist/ticketlayer-elements/p-976770f3.entry.js +0 -1
- package/dist/ticketlayer-elements/p-9a903ff6.entry.js +0 -1
- package/dist/ticketlayer-elements/p-BGekdjN9.js +0 -1
- package/dist/ticketlayer-elements/p-Ba-RZTFI.js +0 -2
- package/dist/ticketlayer-elements/p-a5c90b68.entry.js +0 -1
- package/dist/ticketlayer-elements/p-b6d479ad.entry.js +0 -1
- package/dist/ticketlayer-elements/p-eb640760.entry.js +0 -1
- package/dist/ticketlayer-elements/p-f5846f61.entry.js +0 -1
- package/dist/ticketlayer-elements/p-fb9444c4.entry.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import{proxyCustomElement as t,HTMLElement as n,h as r,transformTag as e}from"@stencil/core/internal/client";import{w as o}from"./sdk-connector.js";function i(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var u,c,s={};function f(){return c?u:(c=1,u=function(){return"function"==typeof Promise&&Promise.prototype&&Promise.prototype.then})}var a,l={},h={};function d(){if(a)return h;let t;a=1;const n=[0,26,44,70,100,134,172,196,242,292,346,404,466,532,581,655,733,815,901,991,1085,1156,1258,1364,1474,1588,1706,1828,1921,2051,2185,2323,2465,2611,2761,2876,3034,3196,3362,3532,3706];return h.getSymbolSize=function(t){if(!t)throw new Error('"version" cannot be null or undefined');if(t<1||t>40)throw new Error('"version" should be in range from 1 to 40');return 4*t+17},h.getSymbolTotalCodewords=function(t){return n[t]},h.getBCHDigit=function(t){let n=0;for(;0!==t;)n++,t>>>=1;return n},h.setToSJISFunction=function(n){if("function"!=typeof n)throw new Error('"toSJISFunc" is not a valid function.');t=n},h.isKanjiModeEnabled=function(){return void 0!==t},h.toSJIS=function(n){return t(n)},h}var w,m,p,v,g,y={};function E(){return w||(w=1,(t=y).L={bit:1},t.M={bit:0},t.Q={bit:3},t.H={bit:2},t.isValid=function(t){return t&&void 0!==t.bit&&t.bit>=0&&t.bit<4},t.from=function(n,r){if(t.isValid(n))return n;try{return function(n){if("string"!=typeof n)throw new Error("Param is not a string");switch(n.toLowerCase()){case"l":case"low":return t.L;case"m":case"medium":return t.M;case"q":case"quartile":return t.Q;case"h":case"high":return t.H;default:throw new Error("Unknown EC Level: "+n)}}(n)}catch(t){return r}}),y;var t}var b,A,k,x,M={},T={},R={},U={};function P(){if(x)return U;x=1;const t=E(),n=[1,1,1,1,1,1,1,1,1,1,2,2,1,2,2,4,1,2,4,4,2,4,4,4,2,4,6,5,2,4,6,6,2,5,8,8,4,5,8,8,4,5,8,11,4,8,10,11,4,9,12,16,4,9,16,16,6,10,12,18,6,10,17,16,6,11,16,19,6,13,18,21,7,14,21,25,8,16,20,25,8,17,23,25,9,17,23,34,9,18,25,30,10,20,27,32,12,21,29,35,12,23,34,37,12,25,34,40,13,26,35,42,14,28,38,45,15,29,40,48,16,31,43,51,17,33,45,54,18,35,48,57,19,37,51,60,19,38,53,63,20,40,56,66,21,43,59,70,22,45,62,74,24,47,65,77,25,49,68,81],r=[7,10,13,17,10,16,22,28,15,26,36,44,20,36,52,64,26,48,72,88,36,64,96,112,40,72,108,130,48,88,132,156,60,110,160,192,72,130,192,224,80,150,224,264,96,176,260,308,104,198,288,352,120,216,320,384,132,240,360,432,144,280,408,480,168,308,448,532,180,338,504,588,196,364,546,650,224,416,600,700,224,442,644,750,252,476,690,816,270,504,750,900,300,560,810,960,312,588,870,1050,336,644,952,1110,360,700,1020,1200,390,728,1050,1260,420,784,1140,1350,450,812,1200,1440,480,868,1290,1530,510,924,1350,1620,540,980,1440,1710,570,1036,1530,1800,570,1064,1590,1890,600,1120,1680,1980,630,1204,1770,2100,660,1260,1860,2220,720,1316,1950,2310,750,1372,2040,2430];return U.getBlocksCount=function(r,e){switch(e){case t.L:return n[4*(r-1)+0];case t.M:return n[4*(r-1)+1];case t.Q:return n[4*(r-1)+2];case t.H:return n[4*(r-1)+3];default:return}},U.getTotalCodewordsCount=function(n,e){switch(e){case t.L:return r[4*(n-1)+0];case t.M:return r[4*(n-1)+1];case t.Q:return r[4*(n-1)+2];case t.H:return r[4*(n-1)+3];default:return}},U}var I,F,N,C,B={},q={};var _,L={},Q={},$={};function S(){return _||(_=1,$.isValid=function(t){return!isNaN(t)&&t>=1&&t<=40}),$}var z,j,D,Z={};function O(){if(z)return Z;z=1;const t="[0-9]+";let n="(?:[u3000-u303F]|[u3040-u309F]|[u30A0-u30FF]|[uFF00-uFFEF]|[u4E00-u9FAF]|[u2605-u2606]|[u2190-u2195]|u203B|[u2010u2015u2018u2019u2025u2026u201Cu201Du2225u2260]|[u0391-u0451]|[u00A7u00A8u00B1u00B4u00D7u00F7])+";n=n.replace(/u/g,"\\u");const r="(?:(?![A-Z0-9 $%*+\\-./:]|"+n+")(?:.|[\r\n]))+";Z.KANJI=new RegExp(n,"g"),Z.BYTE_KANJI=new RegExp("[^A-Z0-9 $%*+\\-./:]+","g"),Z.BYTE=new RegExp(r,"g"),Z.NUMERIC=new RegExp(t,"g"),Z.ALPHANUMERIC=new RegExp("[A-Z $%*+\\-./:]+","g");const e=new RegExp("^"+n+"$"),o=new RegExp("^"+t+"$"),i=new RegExp("^[A-Z0-9 $%*+\\-./:]+$");return Z.testKanji=function(t){return e.test(t)},Z.testNumeric=function(t){return o.test(t)},Z.testAlphanumeric=function(t){return i.test(t)},Z}function H(){return j||(j=1,function(t){const n=S(),r=O();t.NUMERIC={id:"Numeric",bit:1,ccBits:[10,12,14]},t.ALPHANUMERIC={id:"Alphanumeric",bit:2,ccBits:[9,11,13]},t.BYTE={id:"Byte",bit:4,ccBits:[8,16,16]},t.KANJI={id:"Kanji",bit:8,ccBits:[8,10,12]},t.MIXED={bit:-1},t.getCharCountIndicator=function(t,r){if(!t.ccBits)throw new Error("Invalid mode: "+t);if(!n.isValid(r))throw new Error("Invalid version: "+r);return r>=1&&r<10?t.ccBits[0]:r<27?t.ccBits[1]:t.ccBits[2]},t.getBestModeForData=function(n){return r.testNumeric(n)?t.NUMERIC:r.testAlphanumeric(n)?t.ALPHANUMERIC:r.testKanji(n)?t.KANJI:t.BYTE},t.toString=function(t){if(t&&t.id)return t.id;throw new Error("Invalid mode")},t.isValid=function(t){return t&&t.bit&&t.ccBits},t.from=function(n,r){if(t.isValid(n))return n;try{return function(n){if("string"!=typeof n)throw new Error("Param is not a string");switch(n.toLowerCase()){case"numeric":return t.NUMERIC;case"alphanumeric":return t.ALPHANUMERIC;case"kanji":return t.KANJI;case"byte":return t.BYTE;default:throw new Error("Unknown mode: "+n)}}(n)}catch(t){return r}}}(Q)),Q}var J,K,V,W,Y,G,X,tt,nt,rt,et,ot,it={},ut={},ct={exports:{}};function st(){return rt||(rt=1,function(t){var n={single_source_shortest_paths:function(t,r,e){var o={},i={};i[r]=0;var u,c,s,f,a,l,h=n.PriorityQueue.make();for(h.push(r,0);!h.empty();)for(s in f=(u=h.pop()).cost,a=t[c=u.value]||{})a.hasOwnProperty(s)&&(l=f+a[s],(void 0===i[s]||i[s]>l)&&(i[s]=l,h.push(s,l),o[s]=c));if(void 0!==e&&void 0===i[e]){var d=["Could not find a path from ",r," to ",e,"."].join("");throw new Error(d)}return o},extract_shortest_path_from_predecessor_list:function(t,n){for(var r=[],e=n;e;)r.push(e),e=t[e];return r.reverse(),r},find_path:function(t,r,e){var o=n.single_source_shortest_paths(t,r,e);return n.extract_shortest_path_from_predecessor_list(o,e)},PriorityQueue:{make:function(t){var r,e=n.PriorityQueue,o={};for(r in t=t||{},e)e.hasOwnProperty(r)&&(o[r]=e[r]);return o.queue=[],o.sorter=t.sorter||e.default_sorter,o},default_sorter:function(t,n){return t.cost-n.cost},push:function(t,n){this.queue.push({value:t,cost:n}),this.queue.sort(this.sorter)},pop:function(){return this.queue.shift()},empty:function(){return 0===this.queue.length}}};t.exports=n}(ct)),ct.exports}function ft(){if(ot)return l;ot=1;const t=d(),n=E(),r=function(){if(p)return m;function t(){this.buffer=[],this.length=0}return p=1,t.prototype={get:function(t){const n=Math.floor(t/8);return 1==(this.buffer[n]>>>7-t%8&1)},put:function(t,n){for(let r=0;r<n;r++)this.putBit(1==(t>>>n-r-1&1))},getLengthInBits:function(){return this.length},putBit:function(t){const n=Math.floor(this.length/8);this.buffer.length<=n&&this.buffer.push(0),t&&(this.buffer[n]|=128>>>this.length%8),this.length++}},m=t}(),e=function(){if(g)return v;function t(t){if(!t||t<1)throw new Error("BitMatrix size must be defined and greater than 0");this.size=t,this.data=new Uint8Array(t*t),this.reservedBit=new Uint8Array(t*t)}return g=1,t.prototype.set=function(t,n,r,e){const o=t*this.size+n;this.data[o]=r,e&&(this.reservedBit[o]=!0)},t.prototype.get=function(t,n){return this.data[t*this.size+n]},t.prototype.xor=function(t,n,r){this.data[t*this.size+n]^=r},t.prototype.isReserved=function(t,n){return this.reservedBit[t*this.size+n]},v=t}(),o=(b||(b=1,function(t){const n=d().getSymbolSize;t.getRowColCoords=function(t){if(1===t)return[];const r=Math.floor(t/7)+2,e=n(t),o=145===e?26:2*Math.ceil((e-13)/(2*r-2)),i=[e-7];for(let t=1;t<r-1;t++)i[t]=i[t-1]-o;return i.push(6),i.reverse()},t.getPositions=function(n){const r=[],e=t.getRowColCoords(n),o=e.length;for(let t=0;t<o;t++)for(let n=0;n<o;n++)0===t&&0===n||0===t&&n===o-1||t===o-1&&0===n||r.push([e[t],e[n]]);return r}}(M)),M),i=function(){if(A)return T;A=1;const t=d().getSymbolSize;return T.getPositions=function(n){const r=t(n);return[[0,0],[r-7,0],[0,r-7]]},T}(),u=(k||(k=1,function(t){t.Patterns={PATTERN000:0,PATTERN001:1,PATTERN010:2,PATTERN011:3,PATTERN100:4,PATTERN101:5,PATTERN110:6,PATTERN111:7};function n(n,r,e){switch(n){case t.Patterns.PATTERN000:return(r+e)%2==0;case t.Patterns.PATTERN001:return r%2==0;case t.Patterns.PATTERN010:return e%3==0;case t.Patterns.PATTERN011:return(r+e)%3==0;case t.Patterns.PATTERN100:return(Math.floor(r/2)+Math.floor(e/3))%2==0;case t.Patterns.PATTERN101:return r*e%2+r*e%3==0;case t.Patterns.PATTERN110:return(r*e%2+r*e%3)%2==0;case t.Patterns.PATTERN111:return(r*e%3+(r+e)%2)%2==0;default:throw new Error("bad maskPattern:"+n)}}t.isValid=function(t){return null!=t&&""!==t&&!isNaN(t)&&t>=0&&t<=7},t.from=function(n){return t.isValid(n)?parseInt(n,10):void 0},t.getPenaltyN1=function(t){const n=t.size;let r=0,e=0,o=0,i=null,u=null;for(let c=0;c<n;c++){e=o=0,i=u=null;for(let s=0;s<n;s++){let n=t.get(c,s);n===i?e++:(e>=5&&(r+=e-5+3),i=n,e=1),n=t.get(s,c),n===u?o++:(o>=5&&(r+=o-5+3),u=n,o=1)}e>=5&&(r+=e-5+3),o>=5&&(r+=o-5+3)}return r},t.getPenaltyN2=function(t){const n=t.size;let r=0;for(let e=0;e<n-1;e++)for(let o=0;o<n-1;o++){const n=t.get(e,o)+t.get(e,o+1)+t.get(e+1,o)+t.get(e+1,o+1);4!==n&&0!==n||r++}return 3*r},t.getPenaltyN3=function(t){const n=t.size;let r=0,e=0,o=0;for(let i=0;i<n;i++){e=o=0;for(let u=0;u<n;u++)e=e<<1&2047|t.get(i,u),u>=10&&(1488===e||93===e)&&r++,o=o<<1&2047|t.get(u,i),u>=10&&(1488===o||93===o)&&r++}return 40*r},t.getPenaltyN4=function(t){let n=0;const r=t.data.length;for(let e=0;e<r;e++)n+=t.data[e];return 10*Math.abs(Math.ceil(100*n/r/5)-10)},t.applyMask=function(t,r){const e=r.size;for(let o=0;o<e;o++)for(let i=0;i<e;i++)r.isReserved(i,o)||r.xor(i,o,n(t,i,o))},t.getBestMask=function(n,r){const e=Object.keys(t.Patterns).length;let o=0,i=1/0;for(let u=0;u<e;u++){r(u),t.applyMask(u,n);const e=t.getPenaltyN1(n)+t.getPenaltyN2(n)+t.getPenaltyN3(n)+t.getPenaltyN4(n);t.applyMask(u,n),e<i&&(i=e,o=u)}return o}}(R)),R),c=P(),s=function(){if(C)return N;C=1;const t=(F||(F=1,function(t){const n=function(){if(I)return q;I=1;const t=new Uint8Array(512),n=new Uint8Array(256);return function(){let r=1;for(let e=0;e<255;e++)t[e]=r,n[r]=e,r<<=1,256&r&&(r^=285);for(let n=255;n<512;n++)t[n]=t[n-255]}(),q.log=function(t){if(t<1)throw new Error("log("+t+")");return n[t]},q.exp=function(n){return t[n]},q.mul=function(r,e){return 0===r||0===e?0:t[n[r]+n[e]]},q}();t.mul=function(t,r){const e=new Uint8Array(t.length+r.length-1);for(let o=0;o<t.length;o++)for(let i=0;i<r.length;i++)e[o+i]^=n.mul(t[o],r[i]);return e},t.mod=function(t,r){let e=new Uint8Array(t);for(;e.length-r.length>=0;){const t=e[0];for(let o=0;o<r.length;o++)e[o]^=n.mul(r[o],t);let o=0;for(;o<e.length&&0===e[o];)o++;e=e.slice(o)}return e},t.generateECPolynomial=function(r){let e=new Uint8Array([1]);for(let o=0;o<r;o++)e=t.mul(e,new Uint8Array([1,n.exp(o)]));return e}}(B)),B);function n(t){this.genPoly=void 0,this.degree=t,this.degree&&this.initialize(this.degree)}return n.prototype.initialize=function(n){this.degree=n,this.genPoly=t.generateECPolynomial(this.degree)},n.prototype.encode=function(n){if(!this.genPoly)throw new Error("Encoder not initialized");const r=new Uint8Array(n.length+this.degree);r.set(n);const e=t.mod(r,this.genPoly),o=this.degree-e.length;if(o>0){const t=new Uint8Array(this.degree);return t.set(e,o),t}return e},N=n}(),f=(D||(D=1,function(t){const n=d(),r=P(),e=E(),o=H(),i=S(),u=n.getBCHDigit(7973);function c(t,n){return o.getCharCountIndicator(t,n)+4}function s(t,n){let r=0;return t.forEach((function(t){const e=c(t.mode,n);r+=e+t.getBitsLength()})),r}t.from=function(t,n){return i.isValid(t)?parseInt(t,10):n},t.getCapacity=function(t,e,u){if(!i.isValid(t))throw new Error("Invalid QR Code version");void 0===u&&(u=o.BYTE);const s=8*(n.getSymbolTotalCodewords(t)-r.getTotalCodewordsCount(t,e));if(u===o.MIXED)return s;const f=s-c(u,t);switch(u){case o.NUMERIC:return Math.floor(f/10*3);case o.ALPHANUMERIC:return Math.floor(f/11*2);case o.KANJI:return Math.floor(f/13);default:return Math.floor(f/8)}},t.getBestVersionForData=function(n,r){let i;const u=e.from(r,e.M);if(Array.isArray(n)){if(n.length>1)return function(n,r){for(let e=1;e<=40;e++)if(s(n,e)<=t.getCapacity(e,r,o.MIXED))return e}(n,u);if(0===n.length)return 1;i=n[0]}else i=n;return function(n,r,e){for(let o=1;o<=40;o++)if(r<=t.getCapacity(o,e,n))return o}(i.mode,i.getLength(),u)},t.getEncodedBits=function(t){if(!i.isValid(t)||t<7)throw new Error("Invalid QR Code version");let r=t<<12;for(;n.getBCHDigit(r)-u>=0;)r^=7973<<n.getBCHDigit(r)-u;return t<<12|r}}(L)),L),a=function(){if(J)return it;J=1;const t=d(),n=t.getBCHDigit(1335);return it.getEncodedBits=function(r,e){const o=r.bit<<3|e;let i=o<<10;for(;t.getBCHDigit(i)-n>=0;)i^=1335<<t.getBCHDigit(i)-n;return 21522^(o<<10|i)},it}(),h=H(),w=(et||(et=1,function(t){const n=H(),r=function(){if(V)return K;V=1;const t=H();function n(n){this.mode=t.NUMERIC,this.data=n.toString()}return n.getBitsLength=function(t){return 10*Math.floor(t/3)+(t%3?t%3*3+1:0)},n.prototype.getLength=function(){return this.data.length},n.prototype.getBitsLength=function(){return n.getBitsLength(this.data.length)},n.prototype.write=function(t){let n,r,e;for(n=0;n+3<=this.data.length;n+=3)r=this.data.substr(n,3),e=parseInt(r,10),t.put(e,10);const o=this.data.length-n;o>0&&(r=this.data.substr(n),e=parseInt(r,10),t.put(e,3*o+1))},K=n}(),e=function(){if(Y)return W;Y=1;const t=H(),n=["0","1","2","3","4","5","6","7","8","9","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"," ","$","%","*","+","-",".","/",":"];function r(n){this.mode=t.ALPHANUMERIC,this.data=n}return r.getBitsLength=function(t){return 11*Math.floor(t/2)+t%2*6},r.prototype.getLength=function(){return this.data.length},r.prototype.getBitsLength=function(){return r.getBitsLength(this.data.length)},r.prototype.write=function(t){let r;for(r=0;r+2<=this.data.length;r+=2){let e=45*n.indexOf(this.data[r]);e+=n.indexOf(this.data[r+1]),t.put(e,11)}this.data.length%2&&t.put(n.indexOf(this.data[r]),6)},W=r}(),o=function(){if(X)return G;X=1;const t=H();function n(n){this.mode=t.BYTE,this.data="string"==typeof n?(new TextEncoder).encode(n):new Uint8Array(n)}return n.getBitsLength=function(t){return 8*t},n.prototype.getLength=function(){return this.data.length},n.prototype.getBitsLength=function(){return n.getBitsLength(this.data.length)},n.prototype.write=function(t){for(let n=0,r=this.data.length;n<r;n++)t.put(this.data[n],8)},G=n}(),i=function(){if(nt)return tt;nt=1;const t=H(),n=d();function r(n){this.mode=t.KANJI,this.data=n}return r.getBitsLength=function(t){return 13*t},r.prototype.getLength=function(){return this.data.length},r.prototype.getBitsLength=function(){return r.getBitsLength(this.data.length)},r.prototype.write=function(t){let r;for(r=0;r<this.data.length;r++){let e=n.toSJIS(this.data[r]);if(e>=33088&&e<=40956)e-=33088;else{if(!(e>=57408&&e<=60351))throw new Error("Invalid SJIS character: "+this.data[r]+"\nMake sure your charset is UTF-8");e-=49472}e=192*(e>>>8&255)+(255&e),t.put(e,13)}},tt=r}(),u=O(),c=d(),s=st();function f(t){return unescape(encodeURIComponent(t)).length}function a(t,n,r){const e=[];let o;for(;null!==(o=t.exec(r));)e.push({data:o[0],index:o.index,mode:n,length:o[0].length});return e}function l(t){const r=a(u.NUMERIC,n.NUMERIC,t),e=a(u.ALPHANUMERIC,n.ALPHANUMERIC,t);let o,i;return c.isKanjiModeEnabled()?(o=a(u.BYTE,n.BYTE,t),i=a(u.KANJI,n.KANJI,t)):(o=a(u.BYTE_KANJI,n.BYTE,t),i=[]),r.concat(e,o,i).sort((function(t,n){return t.index-n.index})).map((function(t){return{data:t.data,mode:t.mode,length:t.length}}))}function h(t,u){switch(u){case n.NUMERIC:return r.getBitsLength(t);case n.ALPHANUMERIC:return e.getBitsLength(t);case n.KANJI:return i.getBitsLength(t);case n.BYTE:return o.getBitsLength(t)}}function w(t,u){let s;const f=n.getBestModeForData(t);if(s=n.from(u,f),s!==n.BYTE&&s.bit<f.bit)throw new Error('"'+t+'" cannot be encoded with mode '+n.toString(s)+".\n Suggested mode is: "+n.toString(f));switch(s!==n.KANJI||c.isKanjiModeEnabled()||(s=n.BYTE),s){case n.NUMERIC:return new r(t);case n.ALPHANUMERIC:return new e(t);case n.KANJI:return new i(t);case n.BYTE:return new o(t)}}t.fromArray=function(t){return t.reduce((function(t,n){return"string"==typeof n?t.push(w(n,null)):n.data&&t.push(w(n.data,n.mode)),t}),[])},t.fromString=function(r,e){const o=function(t,r){const e={},o={start:{}};let i=["start"];for(let u=0;u<t.length;u++){const c=t[u],s=[];for(let t=0;t<c.length;t++){const f=c[t],a=""+u+t;s.push(a),e[a]={node:f,lastCount:0},o[a]={};for(let t=0;t<i.length;t++){const u=i[t];e[u]&&e[u].node.mode===f.mode?(o[u][a]=h(e[u].lastCount+f.length,f.mode)-h(e[u].lastCount,f.mode),e[u].lastCount+=f.length):(e[u]&&(e[u].lastCount=f.length),o[u][a]=h(f.length,f.mode)+4+n.getCharCountIndicator(f.mode,r))}}i=s}for(let t=0;t<i.length;t++)o[i[t]].end=0;return{map:o,table:e}}(function(t){const r=[];for(let e=0;e<t.length;e++){const o=t[e];switch(o.mode){case n.NUMERIC:r.push([o,{data:o.data,mode:n.ALPHANUMERIC,length:o.length},{data:o.data,mode:n.BYTE,length:o.length}]);break;case n.ALPHANUMERIC:r.push([o,{data:o.data,mode:n.BYTE,length:o.length}]);break;case n.KANJI:r.push([o,{data:o.data,mode:n.BYTE,length:f(o.data)}]);break;case n.BYTE:r.push([{data:o.data,mode:n.BYTE,length:f(o.data)}])}}return r}(l(r,c.isKanjiModeEnabled())),e),i=s.find_path(o.map,"start","end"),u=[];for(let t=1;t<i.length-1;t++)u.push(o.table[i[t]].node);return t.fromArray(u.reduce((function(t,n){const r=t.length-1>=0?t[t.length-1]:null;return r&&r.mode===n.mode?(t[t.length-1].data+=n.data,t):(t.push(n),t)}),[]))},t.rawSplit=function(n){return t.fromArray(l(n,c.isKanjiModeEnabled()))}}(ut)),ut);function y(t,n,r){const e=t.size,o=a.getEncodedBits(n,r);let i,u;for(i=0;i<15;i++)u=1==(o>>i&1),t.set(i<6?i:i<8?i+1:e-15+i,8,u,!0),t.set(8,i<8?e-i-1:i<9?15-i-1+1:15-i-1,u,!0);t.set(e-8,8,1,!0)}function x(n,a,l,d){let m;if(Array.isArray(n))m=w.fromArray(n);else{if("string"!=typeof n)throw new Error("Invalid data");{let t=a;if(!t){const r=w.rawSplit(n);t=f.getBestVersionForData(r,l)}m=w.fromString(n,t||40)}}const p=f.getBestVersionForData(m,l);if(!p)throw new Error("The amount of data is too big to be stored in a QR Code");if(a){if(a<p)throw new Error("\nThe chosen QR Code version cannot contain this amount of data.\nMinimum version required to store current data is: "+p+".\n")}else a=p;const v=function(n,e,o){const i=new r;o.forEach((function(t){i.put(t.mode.bit,4),i.put(t.getLength(),h.getCharCountIndicator(t.mode,n)),t.write(i)}));const u=8*(t.getSymbolTotalCodewords(n)-c.getTotalCodewordsCount(n,e));for(i.getLengthInBits()+4<=u&&i.put(0,4);i.getLengthInBits()%8!=0;)i.putBit(0);const f=(u-i.getLengthInBits())/8;for(let t=0;t<f;t++)i.put(t%2?17:236,8);return function(n,r,e){const o=t.getSymbolTotalCodewords(r),i=o-c.getTotalCodewordsCount(r,e),u=c.getBlocksCount(r,e),f=u-o%u,a=Math.floor(o/u),l=Math.floor(i/u),h=l+1,d=a-l,w=new s(d);let m=0;const p=new Array(u),v=new Array(u);let g=0;const y=new Uint8Array(n.buffer);for(let t=0;t<u;t++){const n=t<f?l:h;p[t]=y.slice(m,m+n),v[t]=w.encode(p[t]),m+=n,g=Math.max(g,n)}const E=new Uint8Array(o);let b,A,k=0;for(b=0;b<g;b++)for(A=0;A<u;A++)b<p[A].length&&(E[k++]=p[A][b]);for(b=0;b<d;b++)for(A=0;A<u;A++)E[k++]=v[A][b];return E}(i,n,e)}(a,l,m),g=t.getSymbolSize(a),E=new e(g);return function(t,n){const r=t.size,e=i.getPositions(n);for(let n=0;n<e.length;n++){const o=e[n][0],i=e[n][1];for(let n=-1;n<=7;n++)if(!(o+n<=-1||r<=o+n))for(let e=-1;e<=7;e++)i+e<=-1||r<=i+e||t.set(o+n,i+e,n>=0&&n<=6&&(0===e||6===e)||e>=0&&e<=6&&(0===n||6===n)||n>=2&&n<=4&&e>=2&&e<=4,!0)}}(E,a),function(t){const n=t.size;for(let r=8;r<n-8;r++){const n=r%2==0;t.set(r,6,n,!0),t.set(6,r,n,!0)}}(E),function(t,n){const r=o.getPositions(n);for(let n=0;n<r.length;n++){const e=r[n][0],o=r[n][1];for(let n=-2;n<=2;n++)for(let r=-2;r<=2;r++)t.set(e+n,o+r,-2===n||2===n||-2===r||2===r||0===n&&0===r,!0)}}(E,a),y(E,l,0),a>=7&&function(t,n){const r=t.size,e=f.getEncodedBits(n);let o,i,u;for(let n=0;n<18;n++)o=Math.floor(n/3),i=n%3+r-8-3,u=1==(e>>n&1),t.set(o,i,u,!0),t.set(i,o,u,!0)}(E,a),function(t,n){const r=t.size;let e=-1,o=r-1,i=7,u=0;for(let c=r-1;c>0;c-=2)for(6===c&&c--;;){for(let r=0;r<2;r++)if(!t.isReserved(o,c-r)){let e=!1;u<n.length&&(e=1==(n[u]>>>i&1)),t.set(o,c-r,e),i--,-1===i&&(u++,i=7)}if(o+=e,o<0||r<=o){o-=e,e=-e;break}}}(E,v),isNaN(d)&&(d=u.getBestMask(E,y.bind(null,E,l))),u.applyMask(d,E),y(E,l,d),{modules:E,version:a,errorCorrectionLevel:l,maskPattern:d,segments:m}}return l.create=function(r,e){if(void 0===r||""===r)throw new Error("No input text");let o,i,c=n.M;return void 0!==e&&(c=n.from(e.errorCorrectionLevel,n.M),o=f.from(e.version),i=u.from(e.maskPattern),e.toSJISFunc&&t.setToSJISFunction(e.toSJISFunc)),x(r,o,c,i)},l}var at,lt,ht={},dt={};function wt(){return at||(at=1,function(t){function n(t){if("number"==typeof t&&(t=t.toString()),"string"!=typeof t)throw new Error("Color should be defined as hex string");let n=t.slice().replace("#","").split("");if(n.length<3||5===n.length||n.length>8)throw new Error("Invalid hex color: "+t);3!==n.length&&4!==n.length||(n=Array.prototype.concat.apply([],n.map((function(t){return[t,t]})))),6===n.length&&n.push("F","F");const r=parseInt(n.join(""),16);return{r:r>>24&255,g:r>>16&255,b:r>>8&255,a:255&r,hex:"#"+n.slice(0,6).join("")}}t.getOptions=function(t){t||(t={}),t.color||(t.color={});const r=t.width&&t.width>=21?t.width:void 0;return{width:r,scale:r?4:t.scale||4,margin:null==t.margin||t.margin<0?4:t.margin,color:{dark:n(t.color.dark||"#000000ff"),light:n(t.color.light||"#ffffffff")},type:t.type,rendererOpts:t.rendererOpts||{}}},t.getScale=function(t,n){return n.width&&n.width>=t+2*n.margin?n.width/(t+2*n.margin):n.scale},t.getImageWidth=function(n,r){const e=t.getScale(n,r);return Math.floor((n+2*r.margin)*e)},t.qrToImageData=function(n,r,e){const o=r.modules.size,i=r.modules.data,u=t.getScale(o,e),c=Math.floor((o+2*e.margin)*u),s=e.margin*u,f=[e.color.light,e.color.dark];for(let t=0;t<c;t++)for(let r=0;r<c;r++){let a=4*(t*c+r),l=e.color.light;t>=s&&r>=s&&t<c-s&&r<c-s&&(l=f[i[Math.floor((t-s)/u)*o+Math.floor((r-s)/u)]?1:0]),n[a++]=l.r,n[a++]=l.g,n[a++]=l.b,n[a]=l.a}}}(dt)),dt}var mt,pt,vt={};var gt=function(){if(pt)return s;pt=1;const t=f(),n=ft(),r=(lt||(lt=1,function(t){const n=wt();t.render=function(t,r,e){let o=e,i=r;void 0!==o||r&&r.getContext||(o=r,r=void 0),r||(i=function(){try{return document.createElement("canvas")}catch(t){throw new Error("You need to specify a canvas element")}}()),o=n.getOptions(o);const u=n.getImageWidth(t.modules.size,o),c=i.getContext("2d"),s=c.createImageData(u,u);return n.qrToImageData(s.data,t,o),function(t,n,r){t.clearRect(0,0,n.width,n.height),n.style||(n.style={}),n.height=r,n.width=r,n.style.height=r+"px",n.style.width=r+"px"}(c,i,u),c.putImageData(s,0,0),i},t.renderToDataURL=function(n,r,e){let o=e;return void 0!==o||r&&r.getContext||(o=r,r=void 0),o||(o={}),t.render(n,r,o).toDataURL(o.type||"image/png",(o.rendererOpts||{}).quality)}}(ht)),ht),e=function(){if(mt)return vt;mt=1;const t=wt();function n(t,n){const r=t.a/255,e=n+'="'+t.hex+'"';return r<1?e+" "+n+'-opacity="'+r.toFixed(2).slice(1)+'"':e}function r(t,n,r){let e=t+n;return void 0!==r&&(e+=" "+r),e}return vt.render=function(e,o,i){const u=t.getOptions(o),c=e.modules.size,s=e.modules.data,f=c+2*u.margin,a=u.color.light.a?"<path "+n(u.color.light,"fill")+' d="M0 0h'+f+"v"+f+'H0z"/>':"",l="<path "+n(u.color.dark,"stroke")+' d="'+function(t,n,e){let o="",i=0,u=!1,c=0;for(let s=0;s<t.length;s++){const f=Math.floor(s%n),a=Math.floor(s/n);f||u||(u=!0),t[s]?(c++,s>0&&f>0&&t[s-1]||(o+=u?r("M",f+e,.5+a+e):r("m",i,0),i=0,u=!1),f+1<n&&t[s+1]||(o+=r("h",c),c=0)):i++}return o}(s,c,u.margin)+'"/>',h='<svg xmlns="http://www.w3.org/2000/svg" '+(u.width?'width="'+u.width+'" height="'+u.width+'" ':"")+'viewBox="0 0 '+f+" "+f+'" shape-rendering="crispEdges">'+a+l+"</svg>\n";return"function"==typeof i&&i(null,h),h},vt}();function o(r,e,o,i,u){const c=[].slice.call(arguments,1),s=c.length,f="function"==typeof c[s-1];if(!f&&!t())throw new Error("Callback required as last argument");if(!f){if(s<1)throw new Error("Too few arguments provided");return 1===s?(o=e,e=i=void 0):2!==s||e.getContext||(i=o,o=e,e=void 0),new Promise((function(t,u){try{const u=n.create(o,i);t(r(u,e,i))}catch(t){u(t)}}))}if(s<2)throw new Error("Too few arguments provided");2===s?(u=o,o=e,e=i=void 0):3===s&&(e.getContext&&void 0===u?(u=i,i=void 0):(u=i,i=o,o=e,e=void 0));try{const t=n.create(o,i);u(null,r(t,e,i))}catch(t){u(t)}}return s.create=n.create,s.toCanvas=o.bind(null,r.render),s.toDataURL=o.bind(null,r.renderToDataURL),s.toString=o.bind(null,(function(t,n,r){return e.render(t,r)})),s}(),yt=i(gt);const Et=t(class extends n{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.qrSvg="",this.downloading=!1}async generateQr(){this.ticket?.barcode&&(this.qrSvg=await yt.toString(this.ticket.barcode,{type:"svg",margin:0,errorCorrectionLevel:"M"}))}async componentWillLoad(){await this.generateQr()}async download(){try{this.downloading=!0;const t=await o(),n=t.getOrdersManager?.();if(!n)throw new Error("Ticket downloads are not available");const r=await n.ticketPdf(this.orderId,this.ticket.id),e=URL.createObjectURL(r),i=document.createElement("a");i.href=e,i.download=`ticket-${this.ticket.id}.pdf`,document.body.appendChild(i),i.click(),i.remove(),URL.revokeObjectURL(e)}catch(t){console.error("[tl-ticket] download failed",t)}finally{this.downloading=!1}}render(){const t=this.ticket;if(!t)return null;const n="fully_redeemed"===t.admissionStatus,e=["cancelled","expired"].includes(t.status),o=n||e;return r("div",{class:"ticket"},r("div",{class:"qr-wrap"},r("div",{class:{qr:!0,inactive:o},innerHTML:this.qrSvg}),o&&r("span",{class:"stamp"},n?"Used":"Void")),r("p",{class:"name"},t.name),t.seatLabel&&r("p",{class:"meta"},"Seat ",t.seatLabel),t.holderName&&r("p",{class:"meta"},t.holderName),r("p",{class:"barcode"},t.barcode),r("button",{class:"download",disabled:this.downloading,onClick:()=>this.download()},this.downloading?"Preparing…":"Download PDF"))}static get watchers(){return{ticket:[{generateQr:0}]}}static get style(){return":host{display:block;font-family:var(--tl-font-family, system-ui, sans-serif)}.ticket{border:1px solid var(--tl-border, #e5e7eb);border-radius:var(--tl-radius-lg, 0.75rem);background:var(--tl-card, #ffffff);padding:var(--tl-spacing-5, 1.25rem);text-align:center}.qr-wrap{position:relative;width:160px;height:160px;margin:0 auto}.qr{width:160px;height:160px}.qr svg{width:100%;height:100%;display:block}.qr.inactive{opacity:0.3}.stamp{position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);padding:0.25rem 0.5rem;border-radius:var(--tl-radius-sm, 0.25rem);background:rgba(17, 24, 39, 0.85);color:#ffffff;font-size:0.7rem;font-weight:700;text-transform:uppercase;letter-spacing:0.05em}.name{margin:1rem 0 0;font-weight:600;color:var(--tl-foreground, #111827)}.meta{margin:0.125rem 0 0;font-size:0.875rem;color:var(--tl-muted-foreground, #6b7280)}.barcode{margin:0.25rem 0 0;font-family:ui-monospace, monospace;font-size:0.625rem;color:var(--tl-muted-foreground, #9ca3af);word-break:break-all}.download{margin-top:0.75rem;padding:0.375rem 0.75rem;border:1px solid var(--tl-border, #e5e7eb);border-radius:var(--tl-radius-md, 0.5rem);background:transparent;color:var(--tl-foreground, #111827);font-size:0.875rem;font-weight:500;cursor:pointer}.download:hover{background:var(--tl-muted, #f3f4f6)}.download:disabled{opacity:0.5;cursor:default}"}},[1,"tl-ticket",{ticket:[16],orderId:[1,"order-id"],qrSvg:[32],downloading:[32]},void 0,{ticket:[{generateQr:0}]}]);function bt(){"undefined"!=typeof customElements&&["tl-ticket"].forEach((t=>{"tl-ticket"===t&&(customElements.get(e(t))||customElements.define(e(t),Et))}))}export{Et as T,bt as d}
|
|
1
|
+
import{proxyCustomElement as t,HTMLElement as n,h as r,transformTag as e}from"@stencil/core/internal/client";import{w as o}from"./sdk-connector.js";function i(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var u,c,s={};function f(){return c?u:(c=1,u=function(){return"function"==typeof Promise&&Promise.prototype&&Promise.prototype.then})}var a,l={},h={};function d(){if(a)return h;let t;a=1;const n=[0,26,44,70,100,134,172,196,242,292,346,404,466,532,581,655,733,815,901,991,1085,1156,1258,1364,1474,1588,1706,1828,1921,2051,2185,2323,2465,2611,2761,2876,3034,3196,3362,3532,3706];return h.getSymbolSize=function(t){if(!t)throw new Error('"version" cannot be null or undefined');if(t<1||t>40)throw new Error('"version" should be in range from 1 to 40');return 4*t+17},h.getSymbolTotalCodewords=function(t){return n[t]},h.getBCHDigit=function(t){let n=0;for(;0!==t;)n++,t>>>=1;return n},h.setToSJISFunction=function(n){if("function"!=typeof n)throw new Error('"toSJISFunc" is not a valid function.');t=n},h.isKanjiModeEnabled=function(){return void 0!==t},h.toSJIS=function(n){return t(n)},h}var w,m,p,v,g,y={};function E(){return w||(w=1,(t=y).L={bit:1},t.M={bit:0},t.Q={bit:3},t.H={bit:2},t.isValid=function(t){return t&&void 0!==t.bit&&t.bit>=0&&t.bit<4},t.from=function(n,r){if(t.isValid(n))return n;try{return function(n){if("string"!=typeof n)throw new Error("Param is not a string");switch(n.toLowerCase()){case"l":case"low":return t.L;case"m":case"medium":return t.M;case"q":case"quartile":return t.Q;case"h":case"high":return t.H;default:throw new Error("Unknown EC Level: "+n)}}(n)}catch(t){return r}}),y;var t}var b,A,k,x,M={},T={},R={},U={};function P(){if(x)return U;x=1;const t=E(),n=[1,1,1,1,1,1,1,1,1,1,2,2,1,2,2,4,1,2,4,4,2,4,4,4,2,4,6,5,2,4,6,6,2,5,8,8,4,5,8,8,4,5,8,11,4,8,10,11,4,9,12,16,4,9,16,16,6,10,12,18,6,10,17,16,6,11,16,19,6,13,18,21,7,14,21,25,8,16,20,25,8,17,23,25,9,17,23,34,9,18,25,30,10,20,27,32,12,21,29,35,12,23,34,37,12,25,34,40,13,26,35,42,14,28,38,45,15,29,40,48,16,31,43,51,17,33,45,54,18,35,48,57,19,37,51,60,19,38,53,63,20,40,56,66,21,43,59,70,22,45,62,74,24,47,65,77,25,49,68,81],r=[7,10,13,17,10,16,22,28,15,26,36,44,20,36,52,64,26,48,72,88,36,64,96,112,40,72,108,130,48,88,132,156,60,110,160,192,72,130,192,224,80,150,224,264,96,176,260,308,104,198,288,352,120,216,320,384,132,240,360,432,144,280,408,480,168,308,448,532,180,338,504,588,196,364,546,650,224,416,600,700,224,442,644,750,252,476,690,816,270,504,750,900,300,560,810,960,312,588,870,1050,336,644,952,1110,360,700,1020,1200,390,728,1050,1260,420,784,1140,1350,450,812,1200,1440,480,868,1290,1530,510,924,1350,1620,540,980,1440,1710,570,1036,1530,1800,570,1064,1590,1890,600,1120,1680,1980,630,1204,1770,2100,660,1260,1860,2220,720,1316,1950,2310,750,1372,2040,2430];return U.getBlocksCount=function(r,e){switch(e){case t.L:return n[4*(r-1)+0];case t.M:return n[4*(r-1)+1];case t.Q:return n[4*(r-1)+2];case t.H:return n[4*(r-1)+3];default:return}},U.getTotalCodewordsCount=function(n,e){switch(e){case t.L:return r[4*(n-1)+0];case t.M:return r[4*(n-1)+1];case t.Q:return r[4*(n-1)+2];case t.H:return r[4*(n-1)+3];default:return}},U}var I,F,N,C,B={},q={};var _,L={},Q={},$={};function S(){return _||(_=1,$.isValid=function(t){return!isNaN(t)&&t>=1&&t<=40}),$}var z,j,D,Z={};function O(){if(z)return Z;z=1;const t="[0-9]+";let n="(?:[u3000-u303F]|[u3040-u309F]|[u30A0-u30FF]|[uFF00-uFFEF]|[u4E00-u9FAF]|[u2605-u2606]|[u2190-u2195]|u203B|[u2010u2015u2018u2019u2025u2026u201Cu201Du2225u2260]|[u0391-u0451]|[u00A7u00A8u00B1u00B4u00D7u00F7])+";n=n.replace(/u/g,"\\u");const r="(?:(?![A-Z0-9 $%*+\\-./:]|"+n+")(?:.|[\r\n]))+";Z.KANJI=new RegExp(n,"g"),Z.BYTE_KANJI=new RegExp("[^A-Z0-9 $%*+\\-./:]+","g"),Z.BYTE=new RegExp(r,"g"),Z.NUMERIC=new RegExp(t,"g"),Z.ALPHANUMERIC=new RegExp("[A-Z $%*+\\-./:]+","g");const e=new RegExp("^"+n+"$"),o=new RegExp("^"+t+"$"),i=new RegExp("^[A-Z0-9 $%*+\\-./:]+$");return Z.testKanji=function(t){return e.test(t)},Z.testNumeric=function(t){return o.test(t)},Z.testAlphanumeric=function(t){return i.test(t)},Z}function H(){return j||(j=1,function(t){const n=S(),r=O();t.NUMERIC={id:"Numeric",bit:1,ccBits:[10,12,14]},t.ALPHANUMERIC={id:"Alphanumeric",bit:2,ccBits:[9,11,13]},t.BYTE={id:"Byte",bit:4,ccBits:[8,16,16]},t.KANJI={id:"Kanji",bit:8,ccBits:[8,10,12]},t.MIXED={bit:-1},t.getCharCountIndicator=function(t,r){if(!t.ccBits)throw new Error("Invalid mode: "+t);if(!n.isValid(r))throw new Error("Invalid version: "+r);return r>=1&&r<10?t.ccBits[0]:r<27?t.ccBits[1]:t.ccBits[2]},t.getBestModeForData=function(n){return r.testNumeric(n)?t.NUMERIC:r.testAlphanumeric(n)?t.ALPHANUMERIC:r.testKanji(n)?t.KANJI:t.BYTE},t.toString=function(t){if(t&&t.id)return t.id;throw new Error("Invalid mode")},t.isValid=function(t){return t&&t.bit&&t.ccBits},t.from=function(n,r){if(t.isValid(n))return n;try{return function(n){if("string"!=typeof n)throw new Error("Param is not a string");switch(n.toLowerCase()){case"numeric":return t.NUMERIC;case"alphanumeric":return t.ALPHANUMERIC;case"kanji":return t.KANJI;case"byte":return t.BYTE;default:throw new Error("Unknown mode: "+n)}}(n)}catch(t){return r}}}(Q)),Q}var J,K,V,W,Y,G,X,tt,nt,rt,et,ot,it={},ut={},ct={exports:{}};function st(){return rt||(rt=1,function(t){var n={single_source_shortest_paths:function(t,r,e){var o={},i={};i[r]=0;var u,c,s,f,a,l,h=n.PriorityQueue.make();for(h.push(r,0);!h.empty();)for(s in f=(u=h.pop()).cost,a=t[c=u.value]||{})a.hasOwnProperty(s)&&(l=f+a[s],(void 0===i[s]||i[s]>l)&&(i[s]=l,h.push(s,l),o[s]=c));if(void 0!==e&&void 0===i[e]){var d=["Could not find a path from ",r," to ",e,"."].join("");throw new Error(d)}return o},extract_shortest_path_from_predecessor_list:function(t,n){for(var r=[],e=n;e;)r.push(e),e=t[e];return r.reverse(),r},find_path:function(t,r,e){var o=n.single_source_shortest_paths(t,r,e);return n.extract_shortest_path_from_predecessor_list(o,e)},PriorityQueue:{make:function(t){var r,e=n.PriorityQueue,o={};for(r in t=t||{},e)e.hasOwnProperty(r)&&(o[r]=e[r]);return o.queue=[],o.sorter=t.sorter||e.default_sorter,o},default_sorter:function(t,n){return t.cost-n.cost},push:function(t,n){this.queue.push({value:t,cost:n}),this.queue.sort(this.sorter)},pop:function(){return this.queue.shift()},empty:function(){return 0===this.queue.length}}};t.exports=n}(ct)),ct.exports}function ft(){if(ot)return l;ot=1;const t=d(),n=E(),r=function(){if(p)return m;function t(){this.buffer=[],this.length=0}return p=1,t.prototype={get:function(t){const n=Math.floor(t/8);return 1==(this.buffer[n]>>>7-t%8&1)},put:function(t,n){for(let r=0;r<n;r++)this.putBit(1==(t>>>n-r-1&1))},getLengthInBits:function(){return this.length},putBit:function(t){const n=Math.floor(this.length/8);this.buffer.length<=n&&this.buffer.push(0),t&&(this.buffer[n]|=128>>>this.length%8),this.length++}},m=t}(),e=function(){if(g)return v;function t(t){if(!t||t<1)throw new Error("BitMatrix size must be defined and greater than 0");this.size=t,this.data=new Uint8Array(t*t),this.reservedBit=new Uint8Array(t*t)}return g=1,t.prototype.set=function(t,n,r,e){const o=t*this.size+n;this.data[o]=r,e&&(this.reservedBit[o]=!0)},t.prototype.get=function(t,n){return this.data[t*this.size+n]},t.prototype.xor=function(t,n,r){this.data[t*this.size+n]^=r},t.prototype.isReserved=function(t,n){return this.reservedBit[t*this.size+n]},v=t}(),o=(b||(b=1,function(t){const n=d().getSymbolSize;t.getRowColCoords=function(t){if(1===t)return[];const r=Math.floor(t/7)+2,e=n(t),o=145===e?26:2*Math.ceil((e-13)/(2*r-2)),i=[e-7];for(let t=1;t<r-1;t++)i[t]=i[t-1]-o;return i.push(6),i.reverse()},t.getPositions=function(n){const r=[],e=t.getRowColCoords(n),o=e.length;for(let t=0;t<o;t++)for(let n=0;n<o;n++)0===t&&0===n||0===t&&n===o-1||t===o-1&&0===n||r.push([e[t],e[n]]);return r}}(M)),M),i=function(){if(A)return T;A=1;const t=d().getSymbolSize;return T.getPositions=function(n){const r=t(n);return[[0,0],[r-7,0],[0,r-7]]},T}(),u=(k||(k=1,function(t){t.Patterns={PATTERN000:0,PATTERN001:1,PATTERN010:2,PATTERN011:3,PATTERN100:4,PATTERN101:5,PATTERN110:6,PATTERN111:7};function n(n,r,e){switch(n){case t.Patterns.PATTERN000:return(r+e)%2==0;case t.Patterns.PATTERN001:return r%2==0;case t.Patterns.PATTERN010:return e%3==0;case t.Patterns.PATTERN011:return(r+e)%3==0;case t.Patterns.PATTERN100:return(Math.floor(r/2)+Math.floor(e/3))%2==0;case t.Patterns.PATTERN101:return r*e%2+r*e%3==0;case t.Patterns.PATTERN110:return(r*e%2+r*e%3)%2==0;case t.Patterns.PATTERN111:return(r*e%3+(r+e)%2)%2==0;default:throw new Error("bad maskPattern:"+n)}}t.isValid=function(t){return null!=t&&""!==t&&!isNaN(t)&&t>=0&&t<=7},t.from=function(n){return t.isValid(n)?parseInt(n,10):void 0},t.getPenaltyN1=function(t){const n=t.size;let r=0,e=0,o=0,i=null,u=null;for(let c=0;c<n;c++){e=o=0,i=u=null;for(let s=0;s<n;s++){let n=t.get(c,s);n===i?e++:(e>=5&&(r+=e-5+3),i=n,e=1),n=t.get(s,c),n===u?o++:(o>=5&&(r+=o-5+3),u=n,o=1)}e>=5&&(r+=e-5+3),o>=5&&(r+=o-5+3)}return r},t.getPenaltyN2=function(t){const n=t.size;let r=0;for(let e=0;e<n-1;e++)for(let o=0;o<n-1;o++){const n=t.get(e,o)+t.get(e,o+1)+t.get(e+1,o)+t.get(e+1,o+1);4!==n&&0!==n||r++}return 3*r},t.getPenaltyN3=function(t){const n=t.size;let r=0,e=0,o=0;for(let i=0;i<n;i++){e=o=0;for(let u=0;u<n;u++)e=e<<1&2047|t.get(i,u),u>=10&&(1488===e||93===e)&&r++,o=o<<1&2047|t.get(u,i),u>=10&&(1488===o||93===o)&&r++}return 40*r},t.getPenaltyN4=function(t){let n=0;const r=t.data.length;for(let e=0;e<r;e++)n+=t.data[e];return 10*Math.abs(Math.ceil(100*n/r/5)-10)},t.applyMask=function(t,r){const e=r.size;for(let o=0;o<e;o++)for(let i=0;i<e;i++)r.isReserved(i,o)||r.xor(i,o,n(t,i,o))},t.getBestMask=function(n,r){const e=Object.keys(t.Patterns).length;let o=0,i=1/0;for(let u=0;u<e;u++){r(u),t.applyMask(u,n);const e=t.getPenaltyN1(n)+t.getPenaltyN2(n)+t.getPenaltyN3(n)+t.getPenaltyN4(n);t.applyMask(u,n),e<i&&(i=e,o=u)}return o}}(R)),R),c=P(),s=function(){if(C)return N;C=1;const t=(F||(F=1,function(t){const n=function(){if(I)return q;I=1;const t=new Uint8Array(512),n=new Uint8Array(256);return function(){let r=1;for(let e=0;e<255;e++)t[e]=r,n[r]=e,r<<=1,256&r&&(r^=285);for(let n=255;n<512;n++)t[n]=t[n-255]}(),q.log=function(t){if(t<1)throw new Error("log("+t+")");return n[t]},q.exp=function(n){return t[n]},q.mul=function(r,e){return 0===r||0===e?0:t[n[r]+n[e]]},q}();t.mul=function(t,r){const e=new Uint8Array(t.length+r.length-1);for(let o=0;o<t.length;o++)for(let i=0;i<r.length;i++)e[o+i]^=n.mul(t[o],r[i]);return e},t.mod=function(t,r){let e=new Uint8Array(t);for(;e.length-r.length>=0;){const t=e[0];for(let o=0;o<r.length;o++)e[o]^=n.mul(r[o],t);let o=0;for(;o<e.length&&0===e[o];)o++;e=e.slice(o)}return e},t.generateECPolynomial=function(r){let e=new Uint8Array([1]);for(let o=0;o<r;o++)e=t.mul(e,new Uint8Array([1,n.exp(o)]));return e}}(B)),B);function n(t){this.genPoly=void 0,this.degree=t,this.degree&&this.initialize(this.degree)}return n.prototype.initialize=function(n){this.degree=n,this.genPoly=t.generateECPolynomial(this.degree)},n.prototype.encode=function(n){if(!this.genPoly)throw new Error("Encoder not initialized");const r=new Uint8Array(n.length+this.degree);r.set(n);const e=t.mod(r,this.genPoly),o=this.degree-e.length;if(o>0){const t=new Uint8Array(this.degree);return t.set(e,o),t}return e},N=n}(),f=(D||(D=1,function(t){const n=d(),r=P(),e=E(),o=H(),i=S(),u=n.getBCHDigit(7973);function c(t,n){return o.getCharCountIndicator(t,n)+4}function s(t,n){let r=0;return t.forEach((function(t){const e=c(t.mode,n);r+=e+t.getBitsLength()})),r}t.from=function(t,n){return i.isValid(t)?parseInt(t,10):n},t.getCapacity=function(t,e,u){if(!i.isValid(t))throw new Error("Invalid QR Code version");void 0===u&&(u=o.BYTE);const s=8*(n.getSymbolTotalCodewords(t)-r.getTotalCodewordsCount(t,e));if(u===o.MIXED)return s;const f=s-c(u,t);switch(u){case o.NUMERIC:return Math.floor(f/10*3);case o.ALPHANUMERIC:return Math.floor(f/11*2);case o.KANJI:return Math.floor(f/13);default:return Math.floor(f/8)}},t.getBestVersionForData=function(n,r){let i;const u=e.from(r,e.M);if(Array.isArray(n)){if(n.length>1)return function(n,r){for(let e=1;e<=40;e++)if(s(n,e)<=t.getCapacity(e,r,o.MIXED))return e}(n,u);if(0===n.length)return 1;i=n[0]}else i=n;return function(n,r,e){for(let o=1;o<=40;o++)if(r<=t.getCapacity(o,e,n))return o}(i.mode,i.getLength(),u)},t.getEncodedBits=function(t){if(!i.isValid(t)||t<7)throw new Error("Invalid QR Code version");let r=t<<12;for(;n.getBCHDigit(r)-u>=0;)r^=7973<<n.getBCHDigit(r)-u;return t<<12|r}}(L)),L),a=function(){if(J)return it;J=1;const t=d(),n=t.getBCHDigit(1335);return it.getEncodedBits=function(r,e){const o=r.bit<<3|e;let i=o<<10;for(;t.getBCHDigit(i)-n>=0;)i^=1335<<t.getBCHDigit(i)-n;return 21522^(o<<10|i)},it}(),h=H(),w=(et||(et=1,function(t){const n=H(),r=function(){if(V)return K;V=1;const t=H();function n(n){this.mode=t.NUMERIC,this.data=n.toString()}return n.getBitsLength=function(t){return 10*Math.floor(t/3)+(t%3?t%3*3+1:0)},n.prototype.getLength=function(){return this.data.length},n.prototype.getBitsLength=function(){return n.getBitsLength(this.data.length)},n.prototype.write=function(t){let n,r,e;for(n=0;n+3<=this.data.length;n+=3)r=this.data.substr(n,3),e=parseInt(r,10),t.put(e,10);const o=this.data.length-n;o>0&&(r=this.data.substr(n),e=parseInt(r,10),t.put(e,3*o+1))},K=n}(),e=function(){if(Y)return W;Y=1;const t=H(),n=["0","1","2","3","4","5","6","7","8","9","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z"," ","$","%","*","+","-",".","/",":"];function r(n){this.mode=t.ALPHANUMERIC,this.data=n}return r.getBitsLength=function(t){return 11*Math.floor(t/2)+t%2*6},r.prototype.getLength=function(){return this.data.length},r.prototype.getBitsLength=function(){return r.getBitsLength(this.data.length)},r.prototype.write=function(t){let r;for(r=0;r+2<=this.data.length;r+=2){let e=45*n.indexOf(this.data[r]);e+=n.indexOf(this.data[r+1]),t.put(e,11)}this.data.length%2&&t.put(n.indexOf(this.data[r]),6)},W=r}(),o=function(){if(X)return G;X=1;const t=H();function n(n){this.mode=t.BYTE,this.data="string"==typeof n?(new TextEncoder).encode(n):new Uint8Array(n)}return n.getBitsLength=function(t){return 8*t},n.prototype.getLength=function(){return this.data.length},n.prototype.getBitsLength=function(){return n.getBitsLength(this.data.length)},n.prototype.write=function(t){for(let n=0,r=this.data.length;n<r;n++)t.put(this.data[n],8)},G=n}(),i=function(){if(nt)return tt;nt=1;const t=H(),n=d();function r(n){this.mode=t.KANJI,this.data=n}return r.getBitsLength=function(t){return 13*t},r.prototype.getLength=function(){return this.data.length},r.prototype.getBitsLength=function(){return r.getBitsLength(this.data.length)},r.prototype.write=function(t){let r;for(r=0;r<this.data.length;r++){let e=n.toSJIS(this.data[r]);if(e>=33088&&e<=40956)e-=33088;else{if(!(e>=57408&&e<=60351))throw new Error("Invalid SJIS character: "+this.data[r]+"\nMake sure your charset is UTF-8");e-=49472}e=192*(e>>>8&255)+(255&e),t.put(e,13)}},tt=r}(),u=O(),c=d(),s=st();function f(t){return unescape(encodeURIComponent(t)).length}function a(t,n,r){const e=[];let o;for(;null!==(o=t.exec(r));)e.push({data:o[0],index:o.index,mode:n,length:o[0].length});return e}function l(t){const r=a(u.NUMERIC,n.NUMERIC,t),e=a(u.ALPHANUMERIC,n.ALPHANUMERIC,t);let o,i;return c.isKanjiModeEnabled()?(o=a(u.BYTE,n.BYTE,t),i=a(u.KANJI,n.KANJI,t)):(o=a(u.BYTE_KANJI,n.BYTE,t),i=[]),r.concat(e,o,i).sort((function(t,n){return t.index-n.index})).map((function(t){return{data:t.data,mode:t.mode,length:t.length}}))}function h(t,u){switch(u){case n.NUMERIC:return r.getBitsLength(t);case n.ALPHANUMERIC:return e.getBitsLength(t);case n.KANJI:return i.getBitsLength(t);case n.BYTE:return o.getBitsLength(t)}}function w(t,u){let s;const f=n.getBestModeForData(t);if(s=n.from(u,f),s!==n.BYTE&&s.bit<f.bit)throw new Error('"'+t+'" cannot be encoded with mode '+n.toString(s)+".\n Suggested mode is: "+n.toString(f));switch(s!==n.KANJI||c.isKanjiModeEnabled()||(s=n.BYTE),s){case n.NUMERIC:return new r(t);case n.ALPHANUMERIC:return new e(t);case n.KANJI:return new i(t);case n.BYTE:return new o(t)}}t.fromArray=function(t){return t.reduce((function(t,n){return"string"==typeof n?t.push(w(n,null)):n.data&&t.push(w(n.data,n.mode)),t}),[])},t.fromString=function(r,e){const o=function(t,r){const e={},o={start:{}};let i=["start"];for(let u=0;u<t.length;u++){const c=t[u],s=[];for(let t=0;t<c.length;t++){const f=c[t],a=""+u+t;s.push(a),e[a]={node:f,lastCount:0},o[a]={};for(let t=0;t<i.length;t++){const u=i[t];e[u]&&e[u].node.mode===f.mode?(o[u][a]=h(e[u].lastCount+f.length,f.mode)-h(e[u].lastCount,f.mode),e[u].lastCount+=f.length):(e[u]&&(e[u].lastCount=f.length),o[u][a]=h(f.length,f.mode)+4+n.getCharCountIndicator(f.mode,r))}}i=s}for(let t=0;t<i.length;t++)o[i[t]].end=0;return{map:o,table:e}}(function(t){const r=[];for(let e=0;e<t.length;e++){const o=t[e];switch(o.mode){case n.NUMERIC:r.push([o,{data:o.data,mode:n.ALPHANUMERIC,length:o.length},{data:o.data,mode:n.BYTE,length:o.length}]);break;case n.ALPHANUMERIC:r.push([o,{data:o.data,mode:n.BYTE,length:o.length}]);break;case n.KANJI:r.push([o,{data:o.data,mode:n.BYTE,length:f(o.data)}]);break;case n.BYTE:r.push([{data:o.data,mode:n.BYTE,length:f(o.data)}])}}return r}(l(r,c.isKanjiModeEnabled())),e),i=s.find_path(o.map,"start","end"),u=[];for(let t=1;t<i.length-1;t++)u.push(o.table[i[t]].node);return t.fromArray(u.reduce((function(t,n){const r=t.length-1>=0?t[t.length-1]:null;return r&&r.mode===n.mode?(t[t.length-1].data+=n.data,t):(t.push(n),t)}),[]))},t.rawSplit=function(n){return t.fromArray(l(n,c.isKanjiModeEnabled()))}}(ut)),ut);function y(t,n,r){const e=t.size,o=a.getEncodedBits(n,r);let i,u;for(i=0;i<15;i++)u=1==(o>>i&1),t.set(i<6?i:i<8?i+1:e-15+i,8,u,!0),t.set(8,i<8?e-i-1:i<9?15-i-1+1:15-i-1,u,!0);t.set(e-8,8,1,!0)}function x(n,a,l,d){let m;if(Array.isArray(n))m=w.fromArray(n);else{if("string"!=typeof n)throw new Error("Invalid data");{let t=a;if(!t){const r=w.rawSplit(n);t=f.getBestVersionForData(r,l)}m=w.fromString(n,t||40)}}const p=f.getBestVersionForData(m,l);if(!p)throw new Error("The amount of data is too big to be stored in a QR Code");if(a){if(a<p)throw new Error("\nThe chosen QR Code version cannot contain this amount of data.\nMinimum version required to store current data is: "+p+".\n")}else a=p;const v=function(n,e,o){const i=new r;o.forEach((function(t){i.put(t.mode.bit,4),i.put(t.getLength(),h.getCharCountIndicator(t.mode,n)),t.write(i)}));const u=8*(t.getSymbolTotalCodewords(n)-c.getTotalCodewordsCount(n,e));for(i.getLengthInBits()+4<=u&&i.put(0,4);i.getLengthInBits()%8!=0;)i.putBit(0);const f=(u-i.getLengthInBits())/8;for(let t=0;t<f;t++)i.put(t%2?17:236,8);return function(n,r,e){const o=t.getSymbolTotalCodewords(r),i=o-c.getTotalCodewordsCount(r,e),u=c.getBlocksCount(r,e),f=u-o%u,a=Math.floor(o/u),l=Math.floor(i/u),h=l+1,d=a-l,w=new s(d);let m=0;const p=new Array(u),v=new Array(u);let g=0;const y=new Uint8Array(n.buffer);for(let t=0;t<u;t++){const n=t<f?l:h;p[t]=y.slice(m,m+n),v[t]=w.encode(p[t]),m+=n,g=Math.max(g,n)}const E=new Uint8Array(o);let b,A,k=0;for(b=0;b<g;b++)for(A=0;A<u;A++)b<p[A].length&&(E[k++]=p[A][b]);for(b=0;b<d;b++)for(A=0;A<u;A++)E[k++]=v[A][b];return E}(i,n,e)}(a,l,m),g=t.getSymbolSize(a),E=new e(g);return function(t,n){const r=t.size,e=i.getPositions(n);for(let n=0;n<e.length;n++){const o=e[n][0],i=e[n][1];for(let n=-1;n<=7;n++)if(!(o+n<=-1||r<=o+n))for(let e=-1;e<=7;e++)i+e<=-1||r<=i+e||t.set(o+n,i+e,n>=0&&n<=6&&(0===e||6===e)||e>=0&&e<=6&&(0===n||6===n)||n>=2&&n<=4&&e>=2&&e<=4,!0)}}(E,a),function(t){const n=t.size;for(let r=8;r<n-8;r++){const n=r%2==0;t.set(r,6,n,!0),t.set(6,r,n,!0)}}(E),function(t,n){const r=o.getPositions(n);for(let n=0;n<r.length;n++){const e=r[n][0],o=r[n][1];for(let n=-2;n<=2;n++)for(let r=-2;r<=2;r++)t.set(e+n,o+r,-2===n||2===n||-2===r||2===r||0===n&&0===r,!0)}}(E,a),y(E,l,0),a>=7&&function(t,n){const r=t.size,e=f.getEncodedBits(n);let o,i,u;for(let n=0;n<18;n++)o=Math.floor(n/3),i=n%3+r-8-3,u=1==(e>>n&1),t.set(o,i,u,!0),t.set(i,o,u,!0)}(E,a),function(t,n){const r=t.size;let e=-1,o=r-1,i=7,u=0;for(let c=r-1;c>0;c-=2)for(6===c&&c--;;){for(let r=0;r<2;r++)if(!t.isReserved(o,c-r)){let e=!1;u<n.length&&(e=1==(n[u]>>>i&1)),t.set(o,c-r,e),i--,-1===i&&(u++,i=7)}if(o+=e,o<0||r<=o){o-=e,e=-e;break}}}(E,v),isNaN(d)&&(d=u.getBestMask(E,y.bind(null,E,l))),u.applyMask(d,E),y(E,l,d),{modules:E,version:a,errorCorrectionLevel:l,maskPattern:d,segments:m}}return l.create=function(r,e){if(void 0===r||""===r)throw new Error("No input text");let o,i,c=n.M;return void 0!==e&&(c=n.from(e.errorCorrectionLevel,n.M),o=f.from(e.version),i=u.from(e.maskPattern),e.toSJISFunc&&t.setToSJISFunction(e.toSJISFunc)),x(r,o,c,i)},l}var at,lt,ht={},dt={};function wt(){return at||(at=1,function(t){function n(t){if("number"==typeof t&&(t=t.toString()),"string"!=typeof t)throw new Error("Color should be defined as hex string");let n=t.slice().replace("#","").split("");if(n.length<3||5===n.length||n.length>8)throw new Error("Invalid hex color: "+t);3!==n.length&&4!==n.length||(n=Array.prototype.concat.apply([],n.map((function(t){return[t,t]})))),6===n.length&&n.push("F","F");const r=parseInt(n.join(""),16);return{r:r>>24&255,g:r>>16&255,b:r>>8&255,a:255&r,hex:"#"+n.slice(0,6).join("")}}t.getOptions=function(t){t||(t={}),t.color||(t.color={});const r=t.width&&t.width>=21?t.width:void 0;return{width:r,scale:r?4:t.scale||4,margin:null==t.margin||t.margin<0?4:t.margin,color:{dark:n(t.color.dark||"#000000ff"),light:n(t.color.light||"#ffffffff")},type:t.type,rendererOpts:t.rendererOpts||{}}},t.getScale=function(t,n){return n.width&&n.width>=t+2*n.margin?n.width/(t+2*n.margin):n.scale},t.getImageWidth=function(n,r){const e=t.getScale(n,r);return Math.floor((n+2*r.margin)*e)},t.qrToImageData=function(n,r,e){const o=r.modules.size,i=r.modules.data,u=t.getScale(o,e),c=Math.floor((o+2*e.margin)*u),s=e.margin*u,f=[e.color.light,e.color.dark];for(let t=0;t<c;t++)for(let r=0;r<c;r++){let a=4*(t*c+r),l=e.color.light;t>=s&&r>=s&&t<c-s&&r<c-s&&(l=f[i[Math.floor((t-s)/u)*o+Math.floor((r-s)/u)]?1:0]),n[a++]=l.r,n[a++]=l.g,n[a++]=l.b,n[a]=l.a}}}(dt)),dt}var mt,pt,vt={};var gt=function(){if(pt)return s;pt=1;const t=f(),n=ft(),r=(lt||(lt=1,function(t){const n=wt();t.render=function(t,r,e){let o=e,i=r;void 0!==o||r&&r.getContext||(o=r,r=void 0),r||(i=function(){try{return document.createElement("canvas")}catch(t){throw new Error("You need to specify a canvas element")}}()),o=n.getOptions(o);const u=n.getImageWidth(t.modules.size,o),c=i.getContext("2d"),s=c.createImageData(u,u);return n.qrToImageData(s.data,t,o),function(t,n,r){t.clearRect(0,0,n.width,n.height),n.style||(n.style={}),n.height=r,n.width=r,n.style.height=r+"px",n.style.width=r+"px"}(c,i,u),c.putImageData(s,0,0),i},t.renderToDataURL=function(n,r,e){let o=e;return void 0!==o||r&&r.getContext||(o=r,r=void 0),o||(o={}),t.render(n,r,o).toDataURL(o.type||"image/png",(o.rendererOpts||{}).quality)}}(ht)),ht),e=function(){if(mt)return vt;mt=1;const t=wt();function n(t,n){const r=t.a/255,e=n+'="'+t.hex+'"';return r<1?e+" "+n+'-opacity="'+r.toFixed(2).slice(1)+'"':e}function r(t,n,r){let e=t+n;return void 0!==r&&(e+=" "+r),e}return vt.render=function(e,o,i){const u=t.getOptions(o),c=e.modules.size,s=e.modules.data,f=c+2*u.margin,a=u.color.light.a?"<path "+n(u.color.light,"fill")+' d="M0 0h'+f+"v"+f+'H0z"/>':"",l="<path "+n(u.color.dark,"stroke")+' d="'+function(t,n,e){let o="",i=0,u=!1,c=0;for(let s=0;s<t.length;s++){const f=Math.floor(s%n),a=Math.floor(s/n);f||u||(u=!0),t[s]?(c++,s>0&&f>0&&t[s-1]||(o+=u?r("M",f+e,.5+a+e):r("m",i,0),i=0,u=!1),f+1<n&&t[s+1]||(o+=r("h",c),c=0)):i++}return o}(s,c,u.margin)+'"/>',h='<svg xmlns="http://www.w3.org/2000/svg" '+(u.width?'width="'+u.width+'" height="'+u.width+'" ':"")+'viewBox="0 0 '+f+" "+f+'" shape-rendering="crispEdges">'+a+l+"</svg>\n";return"function"==typeof i&&i(null,h),h},vt}();function o(r,e,o,i,u){const c=[].slice.call(arguments,1),s=c.length,f="function"==typeof c[s-1];if(!f&&!t())throw new Error("Callback required as last argument");if(!f){if(s<1)throw new Error("Too few arguments provided");return 1===s?(o=e,e=i=void 0):2!==s||e.getContext||(i=o,o=e,e=void 0),new Promise((function(t,u){try{const u=n.create(o,i);t(r(u,e,i))}catch(t){u(t)}}))}if(s<2)throw new Error("Too few arguments provided");2===s?(u=o,o=e,e=i=void 0):3===s&&(e.getContext&&void 0===u?(u=i,i=void 0):(u=i,i=o,o=e,e=void 0));try{const t=n.create(o,i);u(null,r(t,e,i))}catch(t){u(t)}}return s.create=n.create,s.toCanvas=o.bind(null,r.render),s.toDataURL=o.bind(null,r.renderToDataURL),s.toString=o.bind(null,(function(t,n,r){return e.render(t,r)})),s}(),yt=i(gt);const Et=t(class extends n{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.qrSvg="",this.downloading=!1}async generateQr(){this.ticket?.barcode&&(this.qrSvg=await yt.toString(this.ticket.barcode,{type:"svg",margin:0,errorCorrectionLevel:"M"}))}async componentWillLoad(){await this.generateQr()}async download(){try{this.downloading=!0;const t=await o(),n=t.getOrdersManager?.();if(!n)throw new Error("Ticket downloads are not available");const r=await n.ticketPdf(this.orderId,this.ticket.id),e=URL.createObjectURL(r),i=document.createElement("a");i.href=e,i.download=`ticket-${this.ticket.id}.pdf`,document.body.appendChild(i),i.click(),i.remove(),URL.revokeObjectURL(e)}catch(t){console.error("[tl-ticket] download failed",t)}finally{this.downloading=!1}}render(){const t=this.ticket;if(!t)return null;const n="fully_redeemed"===t.admissionStatus,e=["cancelled","expired"].includes(t.status),o=n||e;return r("div",{class:"ticket"},r("div",{class:"qr-wrap"},r("div",{class:{qr:!0,inactive:o},innerHTML:this.qrSvg}),o&&r("span",{class:"stamp"},n?"Used":"Void")),r("p",{class:"name"},t.name),t.seatLabel&&r("p",{class:"meta"},"Seat ",t.seatLabel),t.holderName&&r("p",{class:"meta"},t.holderName),r("p",{class:"barcode"},t.barcode),r("button",{class:"download",disabled:this.downloading,onClick:()=>this.download()},this.downloading?"Preparing…":"Download PDF"))}static get watchers(){return{ticket:[{generateQr:0}]}}static get style(){return":host{display:block;font-family:var(--tl-font-family)}.ticket{border:1px solid var(--tl-border);border-radius:var(--tl-radius-lg);background:var(--tl-card);padding:var(--tl-spacing-5);text-align:center}.qr-wrap{position:relative;width:160px;height:160px;margin:0 auto}.qr{width:160px;height:160px}.qr svg{width:100%;height:100%;display:block}.qr.inactive{opacity:0.3}.stamp{position:absolute;top:50%;left:50%;transform:translate(-50%, -50%);padding:0.25rem 0.5rem;border-radius:var(--tl-radius-sm);background:rgba(17, 24, 39, 0.85);color:#ffffff;font-size:0.7rem;font-weight:700;text-transform:uppercase;letter-spacing:0.05em}.name{margin:1rem 0 0;font-weight:600;color:var(--tl-foreground)}.meta{margin:0.125rem 0 0;font-size:0.875rem;color:var(--tl-muted-foreground)}.barcode{margin:0.25rem 0 0;font-family:ui-monospace, monospace;font-size:0.625rem;color:var(--tl-muted-foreground);word-break:break-all}.download{margin-top:0.75rem;padding:0.375rem 0.75rem;border:1px solid var(--tl-border);border-radius:var(--tl-radius-md);background:transparent;color:var(--tl-foreground);font-size:0.875rem;font-weight:500;cursor:pointer}.download:hover{background:var(--tl-muted)}.download:disabled{opacity:0.5;cursor:default}"}},[1,"tl-ticket",{ticket:[16],orderId:[1,"order-id"],qrSvg:[32],downloading:[32]},void 0,{ticket:[{generateQr:0}]}]);function bt(){"undefined"!=typeof customElements&&["tl-ticket"].forEach((t=>{"tl-ticket"===t&&(customElements.get(e(t))||customElements.define(e(t),Et))}))}export{Et as T,bt as d}
|
package/dist/elements.docs.d.ts
CHANGED
|
@@ -207,6 +207,10 @@ export interface JsonDocsComponent {
|
|
|
207
207
|
* Array of component Parts information, generate from `@part` tags
|
|
208
208
|
*/
|
|
209
209
|
parts: JsonDocsPart[];
|
|
210
|
+
/**
|
|
211
|
+
* Array of custom states defined via @AttachInternals({ states: {...} })
|
|
212
|
+
*/
|
|
213
|
+
customStates: JsonDocsCustomState[];
|
|
210
214
|
/**
|
|
211
215
|
* Array of metadata describing where the current component is used
|
|
212
216
|
*/
|
|
@@ -424,6 +428,28 @@ export interface JsonDocsPart {
|
|
|
424
428
|
*/
|
|
425
429
|
docs: string;
|
|
426
430
|
}
|
|
431
|
+
/**
|
|
432
|
+
* A descriptor for a Custom State defined via @AttachInternals({ states: {...} })
|
|
433
|
+
*
|
|
434
|
+
* Custom states are exposed via the ElementInternals.states CustomStateSet
|
|
435
|
+
* and can be targeted with the CSS `:state()` pseudo-class.
|
|
436
|
+
*
|
|
437
|
+
* @see https://developer.mozilla.org/en-US/docs/Web/API/CustomStateSet
|
|
438
|
+
*/
|
|
439
|
+
export interface JsonDocsCustomState {
|
|
440
|
+
/**
|
|
441
|
+
* The name of the custom state (without dashes)
|
|
442
|
+
*/
|
|
443
|
+
name: string;
|
|
444
|
+
/**
|
|
445
|
+
* The initial/default value of the state
|
|
446
|
+
*/
|
|
447
|
+
initialValue: boolean;
|
|
448
|
+
/**
|
|
449
|
+
* A textual description of the custom state
|
|
450
|
+
*/
|
|
451
|
+
docs: string;
|
|
452
|
+
}
|
|
427
453
|
/**
|
|
428
454
|
* Represents a parsed block comment in a CSS, Sass, etc. file for a custom property.
|
|
429
455
|
*/
|
package/dist/elements.docs.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
|
-
"timestamp": "2026-09-
|
|
2
|
+
"timestamp": "2026-09-18T14:15:31",
|
|
3
3
|
"compiler": {
|
|
4
4
|
"name": "@stencil/core",
|
|
5
|
-
"version": "4.
|
|
5
|
+
"version": "4.45.0",
|
|
6
6
|
"typescriptVersion": "5.8.3"
|
|
7
7
|
},
|
|
8
8
|
"components": [
|
|
@@ -131,6 +131,7 @@
|
|
|
131
131
|
"styles": [],
|
|
132
132
|
"slots": [],
|
|
133
133
|
"parts": [],
|
|
134
|
+
"states": [],
|
|
134
135
|
"dependents": [],
|
|
135
136
|
"dependencies": [
|
|
136
137
|
"tl-occurrence-selector",
|
|
@@ -378,7 +379,7 @@
|
|
|
378
379
|
"references": {
|
|
379
380
|
"ButtonSize": {
|
|
380
381
|
"location": "local",
|
|
381
|
-
"path": "/home/runner/work/live
|
|
382
|
+
"path": "/home/runner/work/live/live/packages/elements/src/components/tl-buy-tickets-button/tl-buy-tickets-button.tsx",
|
|
382
383
|
"id": "src/components/tl-buy-tickets-button/tl-buy-tickets-button.tsx::ButtonSize"
|
|
383
384
|
}
|
|
384
385
|
}
|
|
@@ -422,7 +423,7 @@
|
|
|
422
423
|
"references": {
|
|
423
424
|
"ButtonState": {
|
|
424
425
|
"location": "local",
|
|
425
|
-
"path": "/home/runner/work/live
|
|
426
|
+
"path": "/home/runner/work/live/live/packages/elements/src/components/tl-buy-tickets-button/tl-buy-tickets-button.tsx",
|
|
426
427
|
"id": "src/components/tl-buy-tickets-button/tl-buy-tickets-button.tsx::ButtonState"
|
|
427
428
|
}
|
|
428
429
|
}
|
|
@@ -470,7 +471,7 @@
|
|
|
470
471
|
"references": {
|
|
471
472
|
"ButtonVariant": {
|
|
472
473
|
"location": "local",
|
|
473
|
-
"path": "/home/runner/work/live
|
|
474
|
+
"path": "/home/runner/work/live/live/packages/elements/src/components/tl-buy-tickets-button/tl-buy-tickets-button.tsx",
|
|
474
475
|
"id": "src/components/tl-buy-tickets-button/tl-buy-tickets-button.tsx::ButtonVariant"
|
|
475
476
|
}
|
|
476
477
|
}
|
|
@@ -527,6 +528,7 @@
|
|
|
527
528
|
"styles": [],
|
|
528
529
|
"slots": [],
|
|
529
530
|
"parts": [],
|
|
531
|
+
"states": [],
|
|
530
532
|
"dependents": [],
|
|
531
533
|
"dependencies": [],
|
|
532
534
|
"dependencyGraph": {}
|
|
@@ -697,6 +699,7 @@
|
|
|
697
699
|
}
|
|
698
700
|
],
|
|
699
701
|
"parts": [],
|
|
702
|
+
"states": [],
|
|
700
703
|
"dependents": [],
|
|
701
704
|
"dependencies": [],
|
|
702
705
|
"dependencyGraph": {}
|
|
@@ -839,7 +842,7 @@
|
|
|
839
842
|
"references": {
|
|
840
843
|
"TlCartData": {
|
|
841
844
|
"location": "local",
|
|
842
|
-
"path": "/home/runner/work/live
|
|
845
|
+
"path": "/home/runner/work/live/live/packages/elements/src/components/tl-cart/tl-cart.tsx",
|
|
843
846
|
"id": "src/components/tl-cart/tl-cart.tsx::TlCartData"
|
|
844
847
|
}
|
|
845
848
|
}
|
|
@@ -859,7 +862,7 @@
|
|
|
859
862
|
"references": {
|
|
860
863
|
"TlCartData": {
|
|
861
864
|
"location": "local",
|
|
862
|
-
"path": "/home/runner/work/live
|
|
865
|
+
"path": "/home/runner/work/live/live/packages/elements/src/components/tl-cart/tl-cart.tsx",
|
|
863
866
|
"id": "src/components/tl-cart/tl-cart.tsx::TlCartData"
|
|
864
867
|
}
|
|
865
868
|
}
|
|
@@ -902,6 +905,7 @@
|
|
|
902
905
|
"styles": [],
|
|
903
906
|
"slots": [],
|
|
904
907
|
"parts": [],
|
|
908
|
+
"states": [],
|
|
905
909
|
"dependents": [
|
|
906
910
|
"tl-cart-drawer"
|
|
907
911
|
],
|
|
@@ -1065,6 +1069,7 @@
|
|
|
1065
1069
|
"styles": [],
|
|
1066
1070
|
"slots": [],
|
|
1067
1071
|
"parts": [],
|
|
1072
|
+
"states": [],
|
|
1068
1073
|
"dependents": [],
|
|
1069
1074
|
"dependencies": [],
|
|
1070
1075
|
"dependencyGraph": {}
|
|
@@ -1223,6 +1228,7 @@
|
|
|
1223
1228
|
"styles": [],
|
|
1224
1229
|
"slots": [],
|
|
1225
1230
|
"parts": [],
|
|
1231
|
+
"states": [],
|
|
1226
1232
|
"dependents": [],
|
|
1227
1233
|
"dependencies": [
|
|
1228
1234
|
"tl-cart"
|
|
@@ -1346,6 +1352,7 @@
|
|
|
1346
1352
|
}
|
|
1347
1353
|
],
|
|
1348
1354
|
"parts": [],
|
|
1355
|
+
"states": [],
|
|
1349
1356
|
"dependents": [],
|
|
1350
1357
|
"dependencies": [],
|
|
1351
1358
|
"dependencyGraph": {}
|
|
@@ -1368,7 +1375,7 @@
|
|
|
1368
1375
|
"references": {
|
|
1369
1376
|
"TlEventCardEvent": {
|
|
1370
1377
|
"location": "local",
|
|
1371
|
-
"path": "/home/runner/work/live
|
|
1378
|
+
"path": "/home/runner/work/live/live/packages/elements/src/components/tl-event-card/tl-event-card.tsx",
|
|
1372
1379
|
"id": "src/components/tl-event-card/tl-event-card.tsx::TlEventCardEvent"
|
|
1373
1380
|
}
|
|
1374
1381
|
}
|
|
@@ -1452,6 +1459,7 @@
|
|
|
1452
1459
|
"styles": [],
|
|
1453
1460
|
"slots": [],
|
|
1454
1461
|
"parts": [],
|
|
1462
|
+
"states": [],
|
|
1455
1463
|
"dependents": [
|
|
1456
1464
|
"tl-event-list"
|
|
1457
1465
|
],
|
|
@@ -1577,6 +1585,7 @@
|
|
|
1577
1585
|
"styles": [],
|
|
1578
1586
|
"slots": [],
|
|
1579
1587
|
"parts": [],
|
|
1588
|
+
"states": [],
|
|
1580
1589
|
"dependents": [],
|
|
1581
1590
|
"dependencies": [
|
|
1582
1591
|
"tl-event-card"
|
|
@@ -1680,7 +1689,7 @@
|
|
|
1680
1689
|
"references": {
|
|
1681
1690
|
"TlAuthChanged": {
|
|
1682
1691
|
"location": "local",
|
|
1683
|
-
"path": "/home/runner/work/live
|
|
1692
|
+
"path": "/home/runner/work/live/live/packages/elements/src/components/tl-login/tl-login.tsx",
|
|
1684
1693
|
"id": "src/components/tl-login/tl-login.tsx::TlAuthChanged"
|
|
1685
1694
|
}
|
|
1686
1695
|
}
|
|
@@ -1723,6 +1732,7 @@
|
|
|
1723
1732
|
"styles": [],
|
|
1724
1733
|
"slots": [],
|
|
1725
1734
|
"parts": [],
|
|
1735
|
+
"states": [],
|
|
1726
1736
|
"dependents": [
|
|
1727
1737
|
"tl-my-orders"
|
|
1728
1738
|
],
|
|
@@ -1845,6 +1855,7 @@
|
|
|
1845
1855
|
"styles": [],
|
|
1846
1856
|
"slots": [],
|
|
1847
1857
|
"parts": [],
|
|
1858
|
+
"states": [],
|
|
1848
1859
|
"dependents": [],
|
|
1849
1860
|
"dependencies": [
|
|
1850
1861
|
"tl-order-tickets",
|
|
@@ -1984,7 +1995,7 @@
|
|
|
1984
1995
|
"references": {
|
|
1985
1996
|
"TlOccurrenceSelectorTheme": {
|
|
1986
1997
|
"location": "local",
|
|
1987
|
-
"path": "/home/runner/work/live
|
|
1998
|
+
"path": "/home/runner/work/live/live/packages/elements/src/components/tl-occurrence-selector/tl-occurrence-selector.tsx",
|
|
1988
1999
|
"id": "src/components/tl-occurrence-selector/tl-occurrence-selector.tsx::TlOccurrenceSelectorTheme"
|
|
1989
2000
|
}
|
|
1990
2001
|
}
|
|
@@ -2019,7 +2030,7 @@
|
|
|
2019
2030
|
"references": {
|
|
2020
2031
|
"TlOccurrence": {
|
|
2021
2032
|
"location": "local",
|
|
2022
|
-
"path": "/home/runner/work/live
|
|
2033
|
+
"path": "/home/runner/work/live/live/packages/elements/src/components/tl-occurrence-selector/tl-occurrence-selector.tsx",
|
|
2023
2034
|
"id": "src/components/tl-occurrence-selector/tl-occurrence-selector.tsx::TlOccurrence"
|
|
2024
2035
|
}
|
|
2025
2036
|
}
|
|
@@ -2034,6 +2045,7 @@
|
|
|
2034
2045
|
"styles": [],
|
|
2035
2046
|
"slots": [],
|
|
2036
2047
|
"parts": [],
|
|
2048
|
+
"states": [],
|
|
2037
2049
|
"dependents": [
|
|
2038
2050
|
"tl-buy-modal"
|
|
2039
2051
|
],
|
|
@@ -2215,6 +2227,7 @@
|
|
|
2215
2227
|
"styles": [],
|
|
2216
2228
|
"slots": [],
|
|
2217
2229
|
"parts": [],
|
|
2230
|
+
"states": [],
|
|
2218
2231
|
"dependents": [],
|
|
2219
2232
|
"dependencies": [
|
|
2220
2233
|
"tl-order-tickets"
|
|
@@ -2296,6 +2309,7 @@
|
|
|
2296
2309
|
"styles": [],
|
|
2297
2310
|
"slots": [],
|
|
2298
2311
|
"parts": [],
|
|
2312
|
+
"states": [],
|
|
2299
2313
|
"dependents": [
|
|
2300
2314
|
"tl-my-orders",
|
|
2301
2315
|
"tl-order-confirmation"
|
|
@@ -2418,7 +2432,7 @@
|
|
|
2418
2432
|
"references": {
|
|
2419
2433
|
"TlPromoApplied": {
|
|
2420
2434
|
"location": "local",
|
|
2421
|
-
"path": "/home/runner/work/live
|
|
2435
|
+
"path": "/home/runner/work/live/live/packages/elements/src/components/tl-promo-code/tl-promo-code.tsx",
|
|
2422
2436
|
"id": "src/components/tl-promo-code/tl-promo-code.tsx::TlPromoApplied"
|
|
2423
2437
|
}
|
|
2424
2438
|
}
|
|
@@ -2433,6 +2447,7 @@
|
|
|
2433
2447
|
"styles": [],
|
|
2434
2448
|
"slots": [],
|
|
2435
2449
|
"parts": [],
|
|
2450
|
+
"states": [],
|
|
2436
2451
|
"dependents": [],
|
|
2437
2452
|
"dependencies": [],
|
|
2438
2453
|
"dependencyGraph": {}
|
|
@@ -2677,6 +2692,7 @@
|
|
|
2677
2692
|
"styles": [],
|
|
2678
2693
|
"slots": [],
|
|
2679
2694
|
"parts": [],
|
|
2695
|
+
"states": [],
|
|
2680
2696
|
"dependents": [],
|
|
2681
2697
|
"dependencies": [],
|
|
2682
2698
|
"dependencyGraph": {}
|
|
@@ -2722,7 +2738,7 @@
|
|
|
2722
2738
|
"references": {
|
|
2723
2739
|
"TlTicketData": {
|
|
2724
2740
|
"location": "local",
|
|
2725
|
-
"path": "/home/runner/work/live
|
|
2741
|
+
"path": "/home/runner/work/live/live/packages/elements/src/components/tl-ticket/tl-ticket.tsx",
|
|
2726
2742
|
"id": "src/components/tl-ticket/tl-ticket.tsx::TlTicketData"
|
|
2727
2743
|
}
|
|
2728
2744
|
}
|
|
@@ -2748,6 +2764,7 @@
|
|
|
2748
2764
|
"styles": [],
|
|
2749
2765
|
"slots": [],
|
|
2750
2766
|
"parts": [],
|
|
2767
|
+
"states": [],
|
|
2751
2768
|
"dependents": [
|
|
2752
2769
|
"tl-order-tickets"
|
|
2753
2770
|
],
|
|
@@ -2763,7 +2780,7 @@
|
|
|
2763
2780
|
"encapsulation": "shadow",
|
|
2764
2781
|
"tag": "tl-ticket-selector",
|
|
2765
2782
|
"readme": "# tl-ticket-selector\n\n\n",
|
|
2766
|
-
"docs": "",
|
|
2783
|
+
"docs": "The web harness for `ticketSelectorCore`.\n\nIt renders and it forwards: every decision, every string and every sum is in\n`@ticketlayer/elements-core` (AGENTS.md, TKT-11). What is left here is the\nStencil surface a host writes HTML against - the tag, the attributes, the\nthree `tl*` events - plus the one thing that is genuinely web: finding the\nclient the page published on `window.Ticketlayer`.",
|
|
2767
2784
|
"docsTags": [],
|
|
2768
2785
|
"usage": {},
|
|
2769
2786
|
"props": [
|
|
@@ -2884,7 +2901,7 @@
|
|
|
2884
2901
|
"references": {
|
|
2885
2902
|
"AddToCartItem": {
|
|
2886
2903
|
"location": "local",
|
|
2887
|
-
"path": "/home/runner/work/live
|
|
2904
|
+
"path": "/home/runner/work/live/live/packages/elements/src/components/tl-ticket-selector/tl-ticket-selector.tsx",
|
|
2888
2905
|
"id": "src/components/tl-ticket-selector/tl-ticket-selector.tsx::AddToCartItem"
|
|
2889
2906
|
}
|
|
2890
2907
|
}
|
|
@@ -2927,6 +2944,7 @@
|
|
|
2927
2944
|
"styles": [],
|
|
2928
2945
|
"slots": [],
|
|
2929
2946
|
"parts": [],
|
|
2947
|
+
"states": [],
|
|
2930
2948
|
"dependents": [
|
|
2931
2949
|
"tl-buy-modal"
|
|
2932
2950
|
],
|
|
@@ -2955,7 +2973,7 @@
|
|
|
2955
2973
|
"path": "src/components/tl-buy-tickets-button/tl-buy-tickets-button.tsx"
|
|
2956
2974
|
},
|
|
2957
2975
|
"src/components/tl-cart/tl-cart.tsx::TlCartData": {
|
|
2958
|
-
"declaration": "export interface TlCartData {\n items: TlCartItem[];\n subtotal: number;\n fees: number;\n total: number;\n currency: string;\n itemCount: number;\n}",
|
|
2976
|
+
"declaration": "export interface TlCartData {\n items: TlCartItem[];\n subtotal: number;\n /** Booking fee, minor units. 0 when the surface reports none. */\n fees: number;\n /** Discount as a positive magnitude, minor units. */\n discount?: number;\n total: number;\n currency: string;\n itemCount: number;\n /** Whether the response expressed a fee at all (see utils/cart-totals). */\n hasFees?: boolean;\n /** The channel fee profile's label, when the response carries one. */\n feeLabel?: string | null;\n itemsSubtotal?: number;\n totalFees?: number;\n totalDiscounts?: number;\n}",
|
|
2959
2977
|
"docstring": "",
|
|
2960
2978
|
"path": "src/components/tl-cart/tl-cart.tsx"
|
|
2961
2979
|
},
|
|
@@ -2990,7 +3008,7 @@
|
|
|
2990
3008
|
"path": "src/components/tl-ticket/tl-ticket.tsx"
|
|
2991
3009
|
},
|
|
2992
3010
|
"src/components/tl-ticket-selector/tl-ticket-selector.tsx::AddToCartItem": {
|
|
2993
|
-
"declaration": "export interface AddToCartItem {\n
|
|
3011
|
+
"declaration": "export interface AddToCartItem {\n ticketTypeId: string;\n quantity: number;\n}",
|
|
2994
3012
|
"docstring": "",
|
|
2995
3013
|
"path": "src/components/tl-ticket-selector/tl-ticket-selector.tsx"
|
|
2996
3014
|
},
|