@costrict/csc 4.0.4 → 4.0.5-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/README.md +398 -398
- package/dist/{chunk-ndcrbqq2.js → chunk-012zb121.js} +57 -57
- package/dist/{chunk-tyxhcbsd.js → chunk-01kp42d3.js} +1 -1
- package/dist/{chunk-pn0k5wak.js → chunk-03qpgz7e.js} +749 -23
- package/dist/{chunk-jvgc4q2b.js → chunk-06633xka.js} +59 -59
- package/dist/{chunk-g24e2jr3.js → chunk-06wn4wzn.js} +56 -56
- package/dist/{chunk-k591s450.js → chunk-09t6ygtj.js} +56 -56
- package/dist/{chunk-yhjccrrs.js → chunk-0hy8t8bw.js} +97 -97
- package/dist/{chunk-tw4tjc73.js → chunk-0jd3p53p.js} +1 -1
- package/dist/{chunk-vhk0hgnv.js → chunk-0jzfxaag.js} +56 -56
- package/dist/{chunk-waar1mpa.js → chunk-0mf8c3kx.js} +2 -3
- package/dist/chunk-0vrstrej.js +40 -0
- package/dist/{chunk-zw543g0m.js → chunk-0xv2ee7b.js} +57 -57
- package/dist/{chunk-z43cvm9f.js → chunk-17pfrn9m.js} +75 -75
- package/dist/{chunk-w8ttjf01.js → chunk-1b0wr9kg.js} +183 -179
- package/dist/{chunk-wxe04dx4.js → chunk-1fg83mtb.js} +3 -3
- package/dist/{chunk-6rrp0t66.js → chunk-1gj2ern2.js} +530 -1321
- package/dist/{chunk-zatd0y92.js → chunk-1nmcmem8.js} +5 -5
- package/dist/{chunk-pp347e16.js → chunk-1p0seyhs.js} +56 -56
- package/dist/{chunk-1k0wbt0f.js → chunk-1q4zaaha.js} +87 -87
- package/dist/{chunk-5a6vqs49.js → chunk-1qb8gym4.js} +67 -67
- package/dist/{chunk-1d0d18qj.js → chunk-1r736132.js} +22 -22
- package/dist/{chunk-4nvhfqsy.js → chunk-1vvgsaa1.js} +58 -58
- package/dist/{chunk-n0pkzaaw.js → chunk-1xmy5qww.js} +6 -6
- package/dist/{chunk-vj8q7shk.js → chunk-1z7a5f91.js} +2 -2
- package/dist/{chunk-r6ewgv12.js → chunk-22gyk0w9.js} +1 -1
- package/dist/{chunk-nt36mbmr.js → chunk-233zp88n.js} +14 -14
- package/dist/{chunk-npywdb7q.js → chunk-23s6djv1.js} +3 -3
- package/dist/{chunk-wyz7j9j0.js → chunk-2ak7tq7v.js} +23 -23
- package/dist/{chunk-m5chmh67.js → chunk-2c0sn45e.js} +2 -2
- package/dist/chunk-2d5h61sv.js +334 -0
- package/dist/{chunk-4qcmn89e.js → chunk-2dhbfegz.js} +14 -17
- package/dist/{chunk-63v197w4.js → chunk-2g37ph2s.js} +56 -56
- package/dist/{chunk-j1psatq5.js → chunk-2j59ksap.js} +3 -3
- package/dist/{chunk-pv6amr31.js → chunk-2kmmz00g.js} +1 -1
- package/dist/{chunk-2dtmmwxh.js → chunk-2tddqyvr.js} +4 -4
- package/dist/chunk-2xpkjfdd.js +94 -0
- package/dist/{chunk-dct4myst.js → chunk-30fe1k1d.js} +57 -57
- package/dist/{chunk-t4z17xt4.js → chunk-31gay4fg.js} +10 -10
- package/dist/{chunk-zwna33ms.js → chunk-3340c588.js} +36 -36
- package/dist/{chunk-d6713rzt.js → chunk-344z9y37.js} +30 -10
- package/dist/{chunk-3gaxrmqq.js → chunk-359q6vz4.js} +15 -15
- package/dist/{chunk-rzj6hzme.js → chunk-36mn6bea.js} +8 -8
- package/dist/{chunk-xq3k2392.js → chunk-37xtsbs7.js} +57 -57
- package/dist/{chunk-e08marnp.js → chunk-3cd4y3t9.js} +4 -4
- package/dist/{chunk-34vn56ag.js → chunk-3ep2vsk9.js} +8 -8
- package/dist/{chunk-t1whcbtd.js → chunk-3j3nvs90.js} +73 -73
- package/dist/{chunk-j2bv645h.js → chunk-3s96vaet.js} +9 -11
- package/dist/{chunk-8ew7s39b.js → chunk-3wdbgpa5.js} +1 -1
- package/dist/{chunk-sm24ay0y.js → chunk-3xh1a2s5.js} +117 -117
- package/dist/{chunk-y8ab9dyv.js → chunk-45gvpe1x.js} +1 -1
- package/dist/{chunk-6zf34pgy.js → chunk-47sy4t29.js} +1 -1
- package/dist/{chunk-z6wpnk5y.js → chunk-498cjsxq.js} +1 -1
- package/dist/{chunk-bg86k3wz.js → chunk-49gg57pb.js} +83 -339
- package/dist/{chunk-z8zf2bjp.js → chunk-4fxn5ef2.js} +4 -4
- package/dist/{chunk-nvrje5t4.js → chunk-4h5qcy0x.js} +70 -70
- package/dist/{chunk-n00sjrne.js → chunk-4m7gyesz.js} +6 -6
- package/dist/{chunk-90tgpdv5.js → chunk-4q954a7f.js} +3 -3
- package/dist/{chunk-7sgatxct.js → chunk-4qqswajh.js} +5 -5
- package/dist/{chunk-122wp3n9.js → chunk-4sfd9m3h.js} +2 -2
- package/dist/{chunk-3q10e1r5.js → chunk-4tbz95zd.js} +64 -64
- package/dist/{chunk-tg41r14s.js → chunk-4yccdzzy.js} +5 -5
- package/dist/{chunk-9pp9xrw2.js → chunk-50fv6d8k.js} +14 -17
- package/dist/{chunk-fmq83t7h.js → chunk-50x6aec4.js} +3 -3
- package/dist/{chunk-9k7n4z3r.js → chunk-54nmt278.js} +5 -5
- package/dist/{chunk-g8w2205d.js → chunk-57a7z5f5.js} +6 -6
- package/dist/{chunk-sx291v4f.js → chunk-5dwvcfx9.js} +63 -63
- package/dist/{chunk-371mcwkv.js → chunk-5fczmsq9.js} +7 -7
- package/dist/{chunk-ztqfa7pd.js → chunk-5kxr6004.js} +56 -56
- package/dist/{chunk-1sg2k4mx.js → chunk-5vdpbk46.js} +515 -515
- package/dist/{chunk-4w4wdgeb.js → chunk-5vx1mv79.js} +23 -23
- package/dist/{chunk-z5w7a1cv.js → chunk-5yeynd2q.js} +26 -26
- package/dist/{chunk-9rtywfhp.js → chunk-64nsm3qd.js} +2 -2
- package/dist/{chunk-7mpdfrdm.js → chunk-656z4m7c.js} +5 -5
- package/dist/{chunk-2cpxc5we.js → chunk-671hpxt2.js} +56 -56
- package/dist/{chunk-rw44vqpq.js → chunk-678w363v.js} +56 -56
- package/dist/{chunk-8jpxzesa.js → chunk-67zpbdn4.js} +1 -1
- package/dist/{chunk-mq7m54qk.js → chunk-6b3tvkfs.js} +69 -69
- package/dist/{chunk-8vawdfrp.js → chunk-6c5zyga7.js} +3 -5
- package/dist/{chunk-ga3m4ews.js → chunk-6d51qw9g.js} +56 -56
- package/dist/{chunk-njdz3yry.js → chunk-6e2cdmf5.js} +4 -4
- package/dist/{chunk-kk42fg5v.js → chunk-6qd33ktm.js} +23 -23
- package/dist/{chunk-bhwnjx3e.js → chunk-6r0jsmt2.js} +8 -8
- package/dist/{chunk-t1mtqz1e.js → chunk-6r247w4d.js} +1 -1
- package/dist/{chunk-metmg93w.js → chunk-6we5rwx8.js} +2 -2
- package/dist/{chunk-h5qx4apy.js → chunk-6wgh1zjg.js} +1 -1
- package/dist/{chunk-zr78q4qg.js → chunk-70wzwz8n.js} +56 -56
- package/dist/{chunk-wn8nakrh.js → chunk-79m1rh2k.js} +56 -56
- package/dist/{chunk-zf5wkcyy.js → chunk-7bme7hfa.js} +127 -1099
- package/dist/{chunk-yw0st51b.js → chunk-7daa5crp.js} +57 -57
- package/dist/{chunk-v4zejp1f.js → chunk-7ddn67sp.js} +57 -57
- package/dist/{chunk-0wp0zaz8.js → chunk-7n2snadx.js} +57 -57
- package/dist/{chunk-9m27g5s1.js → chunk-7njxy9q8.js} +18 -3
- package/dist/{chunk-vdh36rw7.js → chunk-7pdhxye3.js} +3 -3
- package/dist/{chunk-skxa5fes.js → chunk-7sk1sscc.js} +14 -16
- package/dist/{chunk-swq8qack.js → chunk-7zv16z22.js} +24 -24
- package/dist/{chunk-b43rsa2d.js → chunk-81714r6x.js} +2 -2
- package/dist/{chunk-9b48fxkx.js → chunk-836sdnt9.js} +56 -56
- package/dist/{chunk-m1qqm2nc.js → chunk-86x85yr9.js} +3 -3
- package/dist/{chunk-tp3mqwh3.js → chunk-87gjcnga.js} +7 -7
- package/dist/{chunk-8ympg941.js → chunk-88maa8mt.js} +1 -1
- package/dist/{chunk-vxnvzfnv.js → chunk-8avfrdpz.js} +2 -3
- package/dist/{chunk-h13g15kb.js → chunk-8bcxzxe5.js} +1 -1
- package/dist/{chunk-kn9hzg11.js → chunk-8fffv8wn.js} +3 -3
- package/dist/{chunk-b3t64cwd.js → chunk-8frgpcff.js} +59 -59
- package/dist/{chunk-j64ga6ta.js → chunk-8jyp5q4y.js} +304 -272
- package/dist/{chunk-sdzpdzj3.js → chunk-8mn0xtks.js} +58 -58
- package/dist/{chunk-svw35ajj.js → chunk-8nyxbscw.js} +57 -57
- package/dist/{chunk-7f0atzzf.js → chunk-8pdt72wn.js} +57 -57
- package/dist/{chunk-1ymedh1v.js → chunk-8q45zgt6.js} +23 -23
- package/dist/{chunk-zwkqabbj.js → chunk-8wxvkw8d.js} +11 -11
- package/dist/{chunk-4vqz7w3v.js → chunk-8y4h3zns.js} +4 -4
- package/dist/{chunk-p2xfr5am.js → chunk-931ha1bh.js} +57 -57
- package/dist/{chunk-84cjtasj.js → chunk-93dwdj3d.js} +58 -58
- package/dist/{chunk-ntwe4mq2.js → chunk-9418ay84.js} +11 -11
- package/dist/{chunk-edt6c4pc.js → chunk-951dv8h8.js} +73 -73
- package/dist/{chunk-x6ceqp7t.js → chunk-95g0mnnr.js} +23 -23
- package/dist/{chunk-02n5zpyc.js → chunk-95gj5fgc.js} +4 -4
- package/dist/{chunk-2c8aqb33.js → chunk-98cxa2z3.js} +56 -56
- package/dist/{chunk-atpyr1kg.js → chunk-9brk0eew.js} +57 -57
- package/dist/{chunk-gaz7te9m.js → chunk-9c667xwe.js} +6 -6
- package/dist/{chunk-ng8q29em.js → chunk-9f1128wv.js} +2 -2
- package/dist/{chunk-ezwhbfk8.js → chunk-9g00mhqb.js} +5 -5
- package/dist/{chunk-6v1p41rg.js → chunk-9kgebwrt.js} +7 -7
- package/dist/{chunk-vntvaf0c.js → chunk-9m1e5wpd.js} +63 -63
- package/dist/{chunk-zwv3h48p.js → chunk-9rpt1bhm.js} +3 -3
- package/dist/{chunk-eserktyd.js → chunk-9szwp11z.js} +4 -4
- package/dist/{chunk-9b2ts7my.js → chunk-9vkszccv.js} +1 -1
- package/dist/{chunk-b82adekm.js → chunk-a4dmrp4p.js} +57 -57
- package/dist/{chunk-zbrk28bp.js → chunk-a67r0mwk.js} +56 -56
- package/dist/{chunk-9azyfe65.js → chunk-aamdxwdd.js} +61 -61
- package/dist/{chunk-bneqxcmf.js → chunk-acv242nr.js} +1 -1
- package/dist/chunk-ahgm6d23.js +180 -0
- package/dist/{chunk-w12f58yz.js → chunk-amp2gnxw.js} +14 -17
- package/dist/{chunk-f62xm8dh.js → chunk-as4mdc2w.js} +3 -3
- package/dist/{chunk-kpdp2gz2.js → chunk-b0640wd7.js} +13 -13
- package/dist/{chunk-5zpstd3m.js → chunk-b2ja3r02.js} +7 -7
- package/dist/{chunk-00m08jnq.js → chunk-b60h6kww.js} +56 -56
- package/dist/{chunk-kaqp12mx.js → chunk-b9qd9kra.js} +56 -56
- package/dist/{chunk-ekqvx6ek.js → chunk-b9sm6wxq.js} +56 -56
- package/dist/{chunk-ppa284pd.js → chunk-bd9tyxxr.js} +56 -56
- package/dist/{chunk-2ab59kwj.js → chunk-bdr1btg9.js} +3 -3
- package/dist/{chunk-q4tkspkp.js → chunk-bhbves4r.js} +4 -4
- package/dist/{chunk-3jjc204v.js → chunk-brmc4agx.js} +18 -18
- package/dist/{chunk-j04z48rw.js → chunk-bt64sq5y.js} +3 -3
- package/dist/{chunk-5qxgyby3.js → chunk-btma241g.js} +612 -2
- package/dist/{chunk-0xfz1hj1.js → chunk-bwyqbexk.js} +6 -6
- package/dist/{chunk-p6ejgd85.js → chunk-by1fz71x.js} +60 -60
- package/dist/{chunk-rvn77re6.js → chunk-c013mzjf.js} +23 -23
- package/dist/{chunk-8w2a9md8.js → chunk-c2c9k2td.js} +3 -3
- package/dist/{chunk-ds6b4567.js → chunk-c3bfhzhn.js} +67 -67
- package/dist/{chunk-rar7nmve.js → chunk-c4rny4rc.js} +57 -57
- package/dist/{chunk-ex2q76wx.js → chunk-c5yryhhe.js} +1 -1
- package/dist/{chunk-cb0cjgk3.js → chunk-c8zj46aa.js} +56 -56
- package/dist/{chunk-h0n9zhgw.js → chunk-c9z5dmft.js} +56 -56
- package/dist/{chunk-xeehxb1q.js → chunk-ckagkgyw.js} +3 -3
- package/dist/{chunk-rwzb4fmk.js → chunk-cmzpd1aa.js} +59 -59
- package/dist/{chunk-rn68wk3p.js → chunk-cs7rs76k.js} +22 -22
- package/dist/{chunk-bgptt4dd.js → chunk-ctmqc8dj.js} +56 -56
- package/dist/{chunk-ekkewv4y.js → chunk-dawypyk0.js} +1 -1
- package/dist/{chunk-ngrj6x74.js → chunk-df52t7ys.js} +168 -161
- package/dist/{chunk-kxptk43f.js → chunk-dhhtyqb0.js} +57 -57
- package/dist/{chunk-tq82bwaf.js → chunk-dvd65zc6.js} +2 -2
- package/dist/{chunk-32fv3vze.js → chunk-e0vqhfkh.js} +25 -25
- package/dist/{chunk-sd3jwppm.js → chunk-ebbxn1k1.js} +8 -8
- package/dist/{chunk-wkh76b1p.js → chunk-enxnnzk5.js} +7 -7
- package/dist/{chunk-f16qs2ag.js → chunk-ernd3z3b.js} +56 -56
- package/dist/{chunk-vhjhyt2r.js → chunk-ers6ntf9.js} +26 -26
- package/dist/{chunk-zwa133ny.js → chunk-es1hw74y.js} +2 -2
- package/dist/{chunk-td6j7fcr.js → chunk-ewnbfy3y.js} +56 -56
- package/dist/{chunk-g0jmqbp4.js → chunk-f2gxsfk0.js} +6 -6
- package/dist/{chunk-2mmx9qqz.js → chunk-f46ae3yt.js} +27 -27
- package/dist/{chunk-dc83q1dm.js → chunk-f4kbe948.js} +2 -2
- package/dist/{chunk-vh70jg33.js → chunk-f954nf8n.js} +4 -4
- package/dist/{chunk-w8krbzb0.js → chunk-fc1dg6fw.js} +4 -4
- package/dist/chunk-ff3ahqvh.js +85 -0
- package/dist/{chunk-yb6x70md.js → chunk-fg5ke2mj.js} +1786 -141
- package/dist/{chunk-me2986xy.js → chunk-fh369vs2.js} +57 -57
- package/dist/{chunk-mz0qfs55.js → chunk-fjwzryzq.js} +63 -63
- package/dist/{chunk-qdfzdcz3.js → chunk-fsag2m4a.js} +60 -60
- package/dist/{chunk-bwqvhzrw.js → chunk-fthbxpt7.js} +76 -69
- package/dist/{chunk-1nz1mgm6.js → chunk-fw8e2t6e.js} +39 -268
- package/dist/{chunk-mj9rbmy1.js → chunk-fxwznjpb.js} +5 -5
- package/dist/{chunk-fw64v27c.js → chunk-fz0ch109.js} +3 -3
- package/dist/{chunk-p6359g16.js → chunk-g0zm1y21.js} +26 -26
- package/dist/{chunk-j2cbcyf7.js → chunk-g649rtg8.js} +4 -6
- package/dist/{chunk-zvxjnak3.js → chunk-g7s3wa97.js} +56 -56
- package/dist/{chunk-js21kfpq.js → chunk-garqv1np.js} +1 -1
- package/dist/{chunk-tsdqd747.js → chunk-gfex5hb6.js} +10 -4
- package/dist/{chunk-ftwqpbvy.js → chunk-gn5w9n3x.js} +56 -56
- package/dist/{chunk-rgm0v4he.js → chunk-gt1g8ggp.js} +24 -24
- package/dist/{chunk-5dn1m1r7.js → chunk-gwyn2qmg.js} +2 -2
- package/dist/{chunk-7srwepm7.js → chunk-h0634caf.js} +1 -1
- package/dist/{chunk-zpm1rpmw.js → chunk-h113y7bb.js} +16 -16
- package/dist/{chunk-nbath9yz.js → chunk-h3hebrv2.js} +7 -7
- package/dist/{chunk-0ejzh5by.js → chunk-h7dkj0dk.js} +58 -58
- package/dist/{chunk-r089a4na.js → chunk-h7vssbj0.js} +22 -22
- package/dist/{chunk-nn8nkawn.js → chunk-hece55mn.js} +7 -7
- package/dist/{chunk-fp2z22f1.js → chunk-hmrv8s7y.js} +59 -59
- package/dist/{chunk-hyc3kbfq.js → chunk-hyn7093k.js} +4 -4
- package/dist/{chunk-bnznxckg.js → chunk-j1xk9z8c.js} +56 -56
- package/dist/{chunk-65gzht6d.js → chunk-j4hwj9dm.js} +56 -56
- package/dist/{chunk-t31xvfy2.js → chunk-j5fmtgm9.js} +60 -60
- package/dist/{chunk-ebx4j5r5.js → chunk-j6k3zjb5.js} +5 -7
- package/dist/{chunk-3nmhzccb.js → chunk-j6v1eh21.js} +2 -2
- package/dist/{chunk-tzpxsjm3.js → chunk-j74bmdac.js} +29 -29
- package/dist/{chunk-wsm0s0c3.js → chunk-j9pk89t9.js} +3 -3
- package/dist/{chunk-31959kp1.js → chunk-jdgtrz9z.js} +5 -5
- package/dist/{chunk-2xezy8pc.js → chunk-jfr51c5y.js} +7 -7
- package/dist/{chunk-ew68a4sy.js → chunk-jjgc9402.js} +57 -57
- package/dist/{chunk-khdftpea.js → chunk-jkh5zd5f.js} +9 -9
- package/dist/{chunk-9kqtdah4.js → chunk-jr21cjeg.js} +1 -1
- package/dist/{chunk-znehavdm.js → chunk-jvnb1zrw.js} +1 -1
- package/dist/{chunk-2kxk7ftp.js → chunk-jzy74s4d.js} +59 -59
- package/dist/{chunk-j5keq4ye.js → chunk-k78z7cgq.js} +60 -60
- package/dist/{chunk-7sgn6fv0.js → chunk-k8ardej3.js} +6 -6
- package/dist/{chunk-drnr3z7x.js → chunk-ka74c3kc.js} +144 -144
- package/dist/{chunk-dge3af7q.js → chunk-ke83cm0m.js} +8 -8
- package/dist/{chunk-nzqmmqwj.js → chunk-keakx0ba.js} +23 -23
- package/dist/{chunk-9snpw77c.js → chunk-kp8c9aj2.js} +67 -67
- package/dist/{chunk-8y3eszv7.js → chunk-krbnqs28.js} +2 -2
- package/dist/{chunk-vgdtw10n.js → chunk-ktzxeprc.js} +2 -2
- package/dist/{chunk-xafy9ccy.js → chunk-m04wh4ns.js} +57 -57
- package/dist/{chunk-zwwgfs0j.js → chunk-m567nxhf.js} +3 -3
- package/dist/{chunk-vf3etxnx.js → chunk-mcs219z2.js} +1 -1
- package/dist/{chunk-61edjmf6.js → chunk-mg1w5bk3.js} +2 -2
- package/dist/{chunk-npvte75f.js → chunk-mjhqxw0y.js} +5 -5
- package/dist/{chunk-ffy37ks3.js → chunk-mjm0x5rg.js} +23 -23
- package/dist/{chunk-vmfckw4g.js → chunk-mmks9f9c.js} +56 -56
- package/dist/{chunk-tjaexdr7.js → chunk-mptrdah5.js} +56 -56
- package/dist/{chunk-vmf74a91.js → chunk-mw3yt5e8.js} +57 -57
- package/dist/{chunk-skrja2sz.js → chunk-my2f214y.js} +2 -2
- package/dist/{chunk-n5pe3jtt.js → chunk-n1bh6pgv.js} +2 -2
- package/dist/{chunk-t0twk3e5.js → chunk-n217n8sr.js} +1 -1
- package/dist/chunk-n35vwqby.js +777 -0
- package/dist/{chunk-b3behs0y.js → chunk-n8tka1ne.js} +3 -3
- package/dist/{chunk-92skmpg9.js → chunk-nc6kc7nq.js} +56 -56
- package/dist/{chunk-send164b.js → chunk-nd6a3t02.js} +23 -23
- package/dist/{chunk-vxs1rvy8.js → chunk-nd6bna5f.js} +6 -6
- package/dist/{chunk-4tre5ddg.js → chunk-neak2qc4.js} +1 -1
- package/dist/{chunk-w8yhf638.js → chunk-nfnvct96.js} +1 -1
- package/dist/{chunk-wj8gbr2g.js → chunk-nh55zf4f.js} +58 -58
- package/dist/{chunk-j2ba3wye.js → chunk-nh8b5r5j.js} +22 -22
- package/dist/{chunk-bbxfenf0.js → chunk-njkrycp5.js} +57 -57
- package/dist/{chunk-pb2x8g1w.js → chunk-npwwb947.js} +67 -67
- package/dist/{chunk-h9ef6kkf.js → chunk-nv44pqqe.js} +5 -5
- package/dist/{chunk-b2pxvgwp.js → chunk-ny3x26cq.js} +10 -10
- package/dist/{chunk-hfy21maq.js → chunk-nyd2jxqe.js} +6 -6
- package/dist/{chunk-0pkrwxrg.js → chunk-nz4mxnb9.js} +3 -3
- package/dist/{chunk-74v2mh4t.js → chunk-p1adg740.js} +1 -1
- package/dist/{chunk-0wrzeej6.js → chunk-p4g51g7j.js} +1 -1
- package/dist/{chunk-d9bvzfkg.js → chunk-p4smdj5h.js} +62 -62
- package/dist/{chunk-knc5za98.js → chunk-p6epk4qf.js} +57 -57
- package/dist/{chunk-vny8tpke.js → chunk-pdqstphx.js} +24 -24
- package/dist/{chunk-67jg7cfy.js → chunk-phce1mav.js} +2 -2
- package/dist/{chunk-3xhmzvxm.js → chunk-pjkaqt23.js} +5 -5
- package/dist/{chunk-a7bs51hq.js → chunk-pk7zh1tn.js} +28 -28
- package/dist/{chunk-sqb7kkqx.js → chunk-pnj3nd5q.js} +6 -6
- package/dist/{chunk-6eq35v86.js → chunk-pnv69npn.js} +1 -1
- package/dist/{chunk-epat31ss.js → chunk-pqmhknk0.js} +1 -1
- package/dist/{chunk-cx8c18e3.js → chunk-pstmmxr4.js} +62 -62
- package/dist/{chunk-sw51thrz.js → chunk-pv4jaeme.js} +59 -59
- package/dist/{chunk-xs12ggs7.js → chunk-pw25q7mk.js} +60 -60
- package/dist/{chunk-j95j6wz8.js → chunk-q27bsq0y.js} +1 -1
- package/dist/{chunk-sjraxh5y.js → chunk-q2dfqg20.js} +57 -57
- package/dist/{chunk-wdwa58v1.js → chunk-qdh60qe3.js} +59 -59
- package/dist/{chunk-r41sjxcn.js → chunk-qegzj6nm.js} +1 -1
- package/dist/{chunk-kerkk89t.js → chunk-qfdzqed0.js} +4 -4
- package/dist/{chunk-3px6f9s5.js → chunk-qg8wxcxp.js} +2 -2
- package/dist/{chunk-6jdrt36m.js → chunk-qk4akts4.js} +2 -2
- package/dist/{chunk-hhc28ga0.js → chunk-qmbxp01p.js} +26 -26
- package/dist/{chunk-5ycqyqbj.js → chunk-qnbe7d8a.js} +1 -1
- package/dist/{chunk-z5tmqz5e.js → chunk-qphfxebt.js} +56 -56
- package/dist/{chunk-e4jqbn4d.js → chunk-qqfbkaad.js} +3 -4
- package/dist/{chunk-jp8tnjzr.js → chunk-qr7jt1p9.js} +59 -59
- package/dist/{chunk-f6qh3vrn.js → chunk-qrxyvnng.js} +4 -4
- package/dist/{chunk-zqhxr0h7.js → chunk-qs2xnhte.js} +5 -7
- package/dist/{chunk-h28xqfk8.js → chunk-qwhjh47p.js} +62 -62
- package/dist/{chunk-tbce47cr.js → chunk-qxsrtfzn.js} +4 -4
- package/dist/{chunk-9jt1c7t9.js → chunk-r1sh1xxc.js} +58 -58
- package/dist/{chunk-pb2nc7r0.js → chunk-r5c38r2r.js} +149 -61
- package/dist/{chunk-5p8k3wyp.js → chunk-r7fp9vgn.js} +59 -59
- package/dist/{chunk-ns3babbs.js → chunk-r7mjzgyn.js} +2 -4
- package/dist/{chunk-jxyh3xyq.js → chunk-r8p2e3xm.js} +23 -23
- package/dist/{chunk-tzaj5mwz.js → chunk-r9c159an.js} +31 -31
- package/dist/{chunk-6dhen79h.js → chunk-rc2ym0h1.js} +8 -8
- package/dist/{chunk-yhc1fee8.js → chunk-rcbwt8v4.js} +23 -23
- package/dist/chunk-red9b98p.js +378 -0
- package/dist/{chunk-k95meznc.js → chunk-rf43pnhs.js} +7 -7
- package/dist/{chunk-drnxbc1w.js → chunk-rfp8ja4z.js} +2 -2
- package/dist/{chunk-kh9fj2xh.js → chunk-rrm65zpt.js} +60 -60
- package/dist/{chunk-s38qgqfs.js → chunk-rrtkz2js.js} +4 -4
- package/dist/{chunk-2f3vsxna.js → chunk-rske3dxd.js} +5 -5
- package/dist/{chunk-b4ftppkp.js → chunk-rt7k0yp6.js} +22 -22
- package/dist/{chunk-7t38tp7c.js → chunk-rxz2y16w.js} +24 -24
- package/dist/{chunk-6hk5a6ky.js → chunk-ry1nqm9c.js} +56 -56
- package/dist/{chunk-7jm7pa1e.js → chunk-ryd3pd8a.js} +14 -17
- package/dist/{chunk-jvf4wvhn.js → chunk-s3crjxw3.js} +57 -57
- package/dist/{chunk-yztxtgd8.js → chunk-s45ebhpy.js} +66 -66
- package/dist/{chunk-cs9xxrmx.js → chunk-s5xntz3r.js} +56 -56
- package/dist/{chunk-03mgn26m.js → chunk-s7c77nyd.js} +65 -65
- package/dist/{chunk-13g6d7wt.js → chunk-sebc1r56.js} +10 -10
- package/dist/{chunk-hk24qq7n.js → chunk-sfmv2tck.js} +9 -9
- package/dist/chunk-shj5md9j.js +1486 -0
- package/dist/{chunk-whs655k7.js → chunk-shzw1wsd.js} +57 -57
- package/dist/{chunk-99p0sa4h.js → chunk-skawh5jz.js} +2 -2
- package/dist/{chunk-s6a338bt.js → chunk-smxedkcs.js} +3 -3
- package/dist/{chunk-34b0y9w3.js → chunk-sp4nhyaf.js} +57 -57
- package/dist/{chunk-jxe1a8kz.js → chunk-syj45v8j.js} +6 -6
- package/dist/{chunk-0kh2f6kh.js → chunk-sz53f4b4.js} +3 -3
- package/dist/{chunk-5wxavbb8.js → chunk-t75rde8x.js} +23 -23
- package/dist/{chunk-z93cpz34.js → chunk-t7b3r8v9.js} +3 -3
- package/dist/{chunk-k6tzzr9c.js → chunk-tawtrqva.js} +7 -7
- package/dist/{chunk-d09j71dr.js → chunk-tayaadct.js} +6 -6
- package/dist/{chunk-1395xfcq.js → chunk-tmazne55.js} +58 -58
- package/dist/{chunk-95dy6w67.js → chunk-tq7vtsx4.js} +2 -2
- package/dist/{chunk-pbn6n0kg.js → chunk-tsrdap6v.js} +56 -56
- package/dist/{chunk-dc4krjj4.js → chunk-v0m66j64.js} +22 -22
- package/dist/{chunk-t2ex5gsn.js → chunk-vby4pkky.js} +3 -3
- package/dist/{chunk-fq1j9zm0.js → chunk-vsa6z84y.js} +3 -3
- package/dist/{chunk-mbv3f2vm.js → chunk-vywhk0sd.js} +4 -4
- package/dist/{chunk-neh0bkkf.js → chunk-vzkn76sz.js} +56 -56
- package/dist/{chunk-125xg82c.js → chunk-w1j0gsjn.js} +22 -22
- package/dist/{chunk-jq9vjfbd.js → chunk-w212xcra.js} +57 -57
- package/dist/{chunk-3b5a4wa6.js → chunk-w31rdd6k.js} +22 -22
- package/dist/{chunk-m3szhhvz.js → chunk-w4705aww.js} +58 -58
- package/dist/{chunk-0gqymhpf.js → chunk-wabhnnag.js} +4 -4
- package/dist/{chunk-rexrttsb.js → chunk-wad1y8mh.js} +33 -33
- package/dist/{chunk-kh9hfyzf.js → chunk-wfy46jh3.js} +56 -56
- package/dist/{chunk-jh0d0pbd.js → chunk-wg0d4shw.js} +4 -4
- package/dist/{chunk-nbvc8bh6.js → chunk-wqcx8yb9.js} +24 -24
- package/dist/{chunk-s8zha7q1.js → chunk-ws1046mv.js} +9 -11
- package/dist/{chunk-9pkh2w7v.js → chunk-wvx43m9q.js} +8 -8
- package/dist/{chunk-rvp6qq44.js → chunk-ww3c2p80.js} +5 -5
- package/dist/{chunk-3c1ddhnk.js → chunk-wyggw3r2.js} +19 -207
- package/dist/{chunk-b909mp8w.js → chunk-x19vx307.js} +1 -1
- package/dist/{chunk-jd2ams26.js → chunk-x2538e1h.js} +6 -6
- package/dist/{chunk-4h43b7ww.js → chunk-x28c4ks5.js} +69 -69
- package/dist/{chunk-79ztw13h.js → chunk-x3cre1mq.js} +2 -2
- package/dist/{chunk-sf4rsw52.js → chunk-x463hr55.js} +8 -8
- package/dist/{chunk-7vzwyazf.js → chunk-x4cy988y.js} +4 -4
- package/dist/{chunk-7e78w86v.js → chunk-x57qc0kp.js} +3 -3
- package/dist/{chunk-m0yqzzgm.js → chunk-x63819rk.js} +2 -2
- package/dist/{chunk-1zrpqh8h.js → chunk-x7aa6ah7.js} +1 -1
- package/dist/{chunk-7rk9ppx4.js → chunk-x7gn9nrr.js} +1 -1
- package/dist/{chunk-2katyzq9.js → chunk-x8zp00qp.js} +3 -3
- package/dist/{chunk-q72weaf5.js → chunk-xa9z4cnj.js} +829 -2177
- package/dist/{chunk-6ge6zddg.js → chunk-xg3ycrct.js} +3 -3
- package/dist/{chunk-tz2rkx2s.js → chunk-xkmy3brs.js} +3 -3
- package/dist/{chunk-smzahkka.js → chunk-xmzrasrc.js} +4 -4
- package/dist/{chunk-g1jfytsa.js → chunk-xt17cf7n.js} +5 -5
- package/dist/{chunk-d8ztpy7x.js → chunk-xwx3rv0p.js} +7 -7
- package/dist/{chunk-xt4v95je.js → chunk-xytszm3x.js} +3 -3
- package/dist/{chunk-7vzj8rfd.js → chunk-y05pc4yc.js} +4 -4
- package/dist/{chunk-1j8anrn2.js → chunk-y0ad9bqc.js} +56 -56
- package/dist/chunk-y2raf8mq.js +500 -0
- package/dist/{chunk-m7r4wqc3.js → chunk-y5eh5c89.js} +1 -1
- package/dist/{chunk-avtcf910.js → chunk-y5x8wqe5.js} +1 -1
- package/dist/{chunk-vjv7wvnc.js → chunk-y7bcnxzv.js} +4 -4
- package/dist/{chunk-w2x18mrn.js → chunk-ybskffc3.js} +23 -23
- package/dist/{chunk-j5bved6z.js → chunk-yr3fqscy.js} +61 -61
- package/dist/{chunk-mnrswcqf.js → chunk-yrkgx43b.js} +56 -56
- package/dist/{chunk-e5ewhhx6.js → chunk-ysaab0ws.js} +56 -56
- package/dist/{chunk-7kbezevv.js → chunk-yt2e4mn3.js} +5 -5
- package/dist/{chunk-7d3ba1n4.js → chunk-yvzh49tc.js} +1 -1
- package/dist/{chunk-y64tceyw.js → chunk-yyq7kdv8.js} +3 -3
- package/dist/{chunk-sjmx1scx.js → chunk-yyrvfxhd.js} +23 -23
- package/dist/{chunk-3d953efq.js → chunk-z3j9b1mk.js} +5 -5
- package/dist/chunk-z51d7scc.js +244 -0
- package/dist/{chunk-4mygvv18.js → chunk-z9crxxn3.js} +57 -57
- package/dist/{chunk-eenv3551.js → chunk-zde20je5.js} +56 -56
- package/dist/{chunk-dxcr07z5.js → chunk-ze6zvkg6.js} +4 -4
- package/dist/{chunk-d6vexw90.js → chunk-zyy7th0a.js} +1 -1
- package/dist/cli-bun.js +0 -0
- package/dist/cli-node.js +418 -10
- package/dist/cli.js +11 -11
- package/dist/download-ripgrep.js +1 -1
- package/package.json +200 -195
- package/scripts/postinstall.cjs +339 -339
- package/scripts/setup-chrome-mcp.mjs +39 -39
- package/dist/chunk-05rcynmf.js +0 -81
- package/dist/chunk-27xc1csx.js +0 -104
- package/dist/chunk-30rst83v.js +0 -168
- package/dist/chunk-33tdaxv0.js +0 -16
- package/dist/chunk-3enkzjbw.js +0 -3966
- package/dist/chunk-3h8a89gy.js +0 -46
- package/dist/chunk-3qm927vk.js +0 -542
- package/dist/chunk-3z7wsvpa.js +0 -24
- package/dist/chunk-44ct1wzm.js +0 -17
- package/dist/chunk-4s0bw3mn.js +0 -208
- package/dist/chunk-7m3ja921.js +0 -27
- package/dist/chunk-7vs34s16.js +0 -173
- package/dist/chunk-80h2am3g.js +0 -5241
- package/dist/chunk-8f6raa6q.js +0 -615
- package/dist/chunk-a9vdeb6y.js +0 -258
- package/dist/chunk-ahc4y7pa.js +0 -782
- package/dist/chunk-b0bk6bxs.js +0 -742
- package/dist/chunk-b4wg70y1.js +0 -54
- package/dist/chunk-btnvjcc5.js +0 -15
- package/dist/chunk-cs6c9gbk.js +0 -1172
- package/dist/chunk-enhtm7h3.js +0 -1731
- package/dist/chunk-fckn68n0.js +0 -180
- package/dist/chunk-h0qngp9w.js +0 -157
- package/dist/chunk-hasadm64.js +0 -412
- package/dist/chunk-hk9xz7gk.js +0 -118
- package/dist/chunk-j2k4p94p.js +0 -55
- package/dist/chunk-jgcsawpq.js +0 -659
- package/dist/chunk-jzmz18nn.js +0 -65
- package/dist/chunk-kg4qmgbk.js +0 -1095
- package/dist/chunk-n0qaeaa5.js +0 -256
- package/dist/chunk-nbxr4cfd.js +0 -880
- package/dist/chunk-q25bjaev.js +0 -15
- package/dist/chunk-qpydzzk0.js +0 -182
- package/dist/chunk-qqy9drhh.js +0 -864
- package/dist/chunk-qtddenhw.js +0 -607
- package/dist/chunk-r6h4zwjj.js +0 -36
- package/dist/chunk-th1cykx3.js +0 -494
- package/dist/chunk-ttk5dzz8.js +0 -25
- package/dist/chunk-v9yc4wjc.js +0 -220
- package/dist/chunk-vsemkegd.js +0 -718
- package/dist/chunk-wadkbt36.js +0 -40
- package/dist/chunk-xsq9ae7x.js +0 -90
- package/dist/chunk-ze6h1ch1.js +0 -21
- package/dist/chunk-ztpbxsq6.js +0 -910
- package/dist/{chunk-2j1t3hcw.js → chunk-a07s68gh.js} +3 -3
|
@@ -1,33 +1,26 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
import {
|
|
3
|
-
require_dist_cjs as
|
|
4
|
-
require_dist_cjs1 as
|
|
5
|
-
} from "./chunk-
|
|
3
|
+
require_dist_cjs as require_dist_cjs12,
|
|
4
|
+
require_dist_cjs1 as require_dist_cjs14
|
|
5
|
+
} from "./chunk-r5c38r2r.js";
|
|
6
6
|
import {
|
|
7
|
-
|
|
8
|
-
require_fxp,
|
|
9
|
-
require_invoke_store
|
|
10
|
-
} from "./chunk-enhtm7h3.js";
|
|
11
|
-
import {
|
|
12
|
-
require_dist_cjs as require_dist_cjs14
|
|
7
|
+
require_dist_cjs as require_dist_cjs13
|
|
13
8
|
} from "./chunk-kxqjncxw.js";
|
|
14
9
|
import {
|
|
15
|
-
require_dist_cjs as
|
|
16
|
-
} from "./chunk-
|
|
10
|
+
require_dist_cjs as require_dist_cjs10
|
|
11
|
+
} from "./chunk-y5x8wqe5.js";
|
|
17
12
|
import {
|
|
18
|
-
require_dist_cjs as
|
|
19
|
-
} from "./chunk-
|
|
13
|
+
require_dist_cjs as require_dist_cjs11
|
|
14
|
+
} from "./chunk-q27bsq0y.js";
|
|
20
15
|
import {
|
|
21
|
-
require_dist_cjs as
|
|
16
|
+
require_dist_cjs as require_dist_cjs5,
|
|
17
|
+
require_dist_cjs1 as require_dist_cjs6,
|
|
18
|
+
require_dist_cjs2 as require_dist_cjs9,
|
|
22
19
|
require_endpoints,
|
|
23
20
|
require_protocols,
|
|
24
21
|
require_schema,
|
|
25
22
|
require_serde
|
|
26
|
-
} from "./chunk-
|
|
27
|
-
import {
|
|
28
|
-
require_dist_cjs as require_dist_cjs7,
|
|
29
|
-
require_dist_cjs1 as require_dist_cjs10
|
|
30
|
-
} from "./chunk-b0bk6bxs.js";
|
|
23
|
+
} from "./chunk-03qpgz7e.js";
|
|
31
24
|
import {
|
|
32
25
|
require_client
|
|
33
26
|
} from "./chunk-psmfpddh.js";
|
|
@@ -35,20 +28,17 @@ import {
|
|
|
35
28
|
require_dist_cjs
|
|
36
29
|
} from "./chunk-jcfk76z5.js";
|
|
37
30
|
import {
|
|
38
|
-
require_dist_cjs as
|
|
31
|
+
require_dist_cjs as require_dist_cjs3
|
|
39
32
|
} from "./chunk-pn1q3cxk.js";
|
|
40
33
|
import {
|
|
41
|
-
require_dist_cjs as
|
|
34
|
+
require_dist_cjs as require_dist_cjs4
|
|
42
35
|
} from "./chunk-6f8awfs6.js";
|
|
43
|
-
import {
|
|
44
|
-
require_dist_cjs as require_dist_cjs3
|
|
45
|
-
} from "./chunk-2md5w5h8.js";
|
|
46
36
|
import {
|
|
47
37
|
require_dist_cjs as require_dist_cjs2
|
|
48
|
-
} from "./chunk-
|
|
38
|
+
} from "./chunk-2md5w5h8.js";
|
|
49
39
|
import {
|
|
50
|
-
require_dist_cjs1 as
|
|
51
|
-
require_dist_cjs2 as
|
|
40
|
+
require_dist_cjs1 as require_dist_cjs7,
|
|
41
|
+
require_dist_cjs2 as require_dist_cjs8
|
|
52
42
|
} from "./chunk-2nayx6q1.js";
|
|
53
43
|
import {
|
|
54
44
|
__commonJS,
|
|
@@ -56,7 +46,7 @@ import {
|
|
|
56
46
|
} from "./chunk-qp2qdcda.js";
|
|
57
47
|
|
|
58
48
|
// node_modules/.bun/@aws-sdk+middleware-host-header@3.972.9/node_modules/@aws-sdk/middleware-host-header/dist-cjs/index.js
|
|
59
|
-
var
|
|
49
|
+
var require_dist_cjs15 = __commonJS((exports) => {
|
|
60
50
|
var protocolHttp = require_dist_cjs();
|
|
61
51
|
function resolveHostHeaderConfig(input) {
|
|
62
52
|
return input;
|
|
@@ -96,7 +86,7 @@ var require_dist_cjs17 = __commonJS((exports) => {
|
|
|
96
86
|
});
|
|
97
87
|
|
|
98
88
|
// node_modules/.bun/@aws-sdk+middleware-logger@3.972.9/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js
|
|
99
|
-
var
|
|
89
|
+
var require_dist_cjs16 = __commonJS((exports) => {
|
|
100
90
|
var loggerMiddleware = () => (next, context) => async (args) => {
|
|
101
91
|
try {
|
|
102
92
|
const response = await next(args);
|
|
@@ -143,6 +133,123 @@ var require_dist_cjs18 = __commonJS((exports) => {
|
|
|
143
133
|
exports.loggerMiddlewareOptions = loggerMiddlewareOptions;
|
|
144
134
|
});
|
|
145
135
|
|
|
136
|
+
// node_modules/.bun/@aws+lambda-invoke-store@0.2.4/node_modules/@aws/lambda-invoke-store/dist-cjs/invoke-store.js
|
|
137
|
+
var require_invoke_store = __commonJS((exports) => {
|
|
138
|
+
var PROTECTED_KEYS = {
|
|
139
|
+
REQUEST_ID: Symbol.for("_AWS_LAMBDA_REQUEST_ID"),
|
|
140
|
+
X_RAY_TRACE_ID: Symbol.for("_AWS_LAMBDA_X_RAY_TRACE_ID"),
|
|
141
|
+
TENANT_ID: Symbol.for("_AWS_LAMBDA_TENANT_ID")
|
|
142
|
+
};
|
|
143
|
+
var NO_GLOBAL_AWS_LAMBDA = ["true", "1"].includes(process.env?.AWS_LAMBDA_NODEJS_NO_GLOBAL_AWSLAMBDA ?? "");
|
|
144
|
+
if (!NO_GLOBAL_AWS_LAMBDA) {
|
|
145
|
+
globalThis.awslambda = globalThis.awslambda || {};
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
class InvokeStoreBase {
|
|
149
|
+
static PROTECTED_KEYS = PROTECTED_KEYS;
|
|
150
|
+
isProtectedKey(key) {
|
|
151
|
+
return Object.values(PROTECTED_KEYS).includes(key);
|
|
152
|
+
}
|
|
153
|
+
getRequestId() {
|
|
154
|
+
return this.get(PROTECTED_KEYS.REQUEST_ID) ?? "-";
|
|
155
|
+
}
|
|
156
|
+
getXRayTraceId() {
|
|
157
|
+
return this.get(PROTECTED_KEYS.X_RAY_TRACE_ID);
|
|
158
|
+
}
|
|
159
|
+
getTenantId() {
|
|
160
|
+
return this.get(PROTECTED_KEYS.TENANT_ID);
|
|
161
|
+
}
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
class InvokeStoreSingle extends InvokeStoreBase {
|
|
165
|
+
currentContext;
|
|
166
|
+
getContext() {
|
|
167
|
+
return this.currentContext;
|
|
168
|
+
}
|
|
169
|
+
hasContext() {
|
|
170
|
+
return this.currentContext !== undefined;
|
|
171
|
+
}
|
|
172
|
+
get(key) {
|
|
173
|
+
return this.currentContext?.[key];
|
|
174
|
+
}
|
|
175
|
+
set(key, value) {
|
|
176
|
+
if (this.isProtectedKey(key)) {
|
|
177
|
+
throw new Error(`Cannot modify protected Lambda context field: ${String(key)}`);
|
|
178
|
+
}
|
|
179
|
+
this.currentContext = this.currentContext || {};
|
|
180
|
+
this.currentContext[key] = value;
|
|
181
|
+
}
|
|
182
|
+
run(context, fn) {
|
|
183
|
+
this.currentContext = context;
|
|
184
|
+
return fn();
|
|
185
|
+
}
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
class InvokeStoreMulti extends InvokeStoreBase {
|
|
189
|
+
als;
|
|
190
|
+
static async create() {
|
|
191
|
+
const instance = new InvokeStoreMulti;
|
|
192
|
+
const asyncHooks = await import("async_hooks");
|
|
193
|
+
instance.als = new asyncHooks.AsyncLocalStorage;
|
|
194
|
+
return instance;
|
|
195
|
+
}
|
|
196
|
+
getContext() {
|
|
197
|
+
return this.als.getStore();
|
|
198
|
+
}
|
|
199
|
+
hasContext() {
|
|
200
|
+
return this.als.getStore() !== undefined;
|
|
201
|
+
}
|
|
202
|
+
get(key) {
|
|
203
|
+
return this.als.getStore()?.[key];
|
|
204
|
+
}
|
|
205
|
+
set(key, value) {
|
|
206
|
+
if (this.isProtectedKey(key)) {
|
|
207
|
+
throw new Error(`Cannot modify protected Lambda context field: ${String(key)}`);
|
|
208
|
+
}
|
|
209
|
+
const store = this.als.getStore();
|
|
210
|
+
if (!store) {
|
|
211
|
+
throw new Error("No context available");
|
|
212
|
+
}
|
|
213
|
+
store[key] = value;
|
|
214
|
+
}
|
|
215
|
+
run(context, fn) {
|
|
216
|
+
return this.als.run(context, fn);
|
|
217
|
+
}
|
|
218
|
+
}
|
|
219
|
+
exports.InvokeStore = undefined;
|
|
220
|
+
(function(InvokeStore) {
|
|
221
|
+
let instance = null;
|
|
222
|
+
async function getInstanceAsync(forceInvokeStoreMulti) {
|
|
223
|
+
if (!instance) {
|
|
224
|
+
instance = (async () => {
|
|
225
|
+
const isMulti = forceInvokeStoreMulti === true || "AWS_LAMBDA_MAX_CONCURRENCY" in process.env;
|
|
226
|
+
const newInstance = isMulti ? await InvokeStoreMulti.create() : new InvokeStoreSingle;
|
|
227
|
+
if (!NO_GLOBAL_AWS_LAMBDA && globalThis.awslambda?.InvokeStore) {
|
|
228
|
+
return globalThis.awslambda.InvokeStore;
|
|
229
|
+
} else if (!NO_GLOBAL_AWS_LAMBDA && globalThis.awslambda) {
|
|
230
|
+
globalThis.awslambda.InvokeStore = newInstance;
|
|
231
|
+
return newInstance;
|
|
232
|
+
} else {
|
|
233
|
+
return newInstance;
|
|
234
|
+
}
|
|
235
|
+
})();
|
|
236
|
+
}
|
|
237
|
+
return instance;
|
|
238
|
+
}
|
|
239
|
+
InvokeStore.getInstanceAsync = getInstanceAsync;
|
|
240
|
+
InvokeStore._testing = process.env.AWS_LAMBDA_BENCHMARK_MODE === "1" ? {
|
|
241
|
+
reset: () => {
|
|
242
|
+
instance = null;
|
|
243
|
+
if (globalThis.awslambda?.InvokeStore) {
|
|
244
|
+
delete globalThis.awslambda.InvokeStore;
|
|
245
|
+
}
|
|
246
|
+
globalThis.awslambda = { InvokeStore: undefined };
|
|
247
|
+
}
|
|
248
|
+
} : undefined;
|
|
249
|
+
})(exports.InvokeStore || (exports.InvokeStore = {}));
|
|
250
|
+
exports.InvokeStoreBase = InvokeStoreBase;
|
|
251
|
+
});
|
|
252
|
+
|
|
146
253
|
// node_modules/.bun/@aws-sdk+middleware-recursion-detection@3.972.10/node_modules/@aws-sdk/middleware-recursion-detection/dist-cjs/recursionDetectionMiddleware.js
|
|
147
254
|
var require_recursionDetectionMiddleware = __commonJS((exports) => {
|
|
148
255
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
@@ -179,7 +286,7 @@ var require_recursionDetectionMiddleware = __commonJS((exports) => {
|
|
|
179
286
|
});
|
|
180
287
|
|
|
181
288
|
// node_modules/.bun/@aws-sdk+middleware-recursion-detection@3.972.10/node_modules/@aws-sdk/middleware-recursion-detection/dist-cjs/index.js
|
|
182
|
-
var
|
|
289
|
+
var require_dist_cjs17 = __commonJS((exports) => {
|
|
183
290
|
var recursionDetectionMiddleware = require_recursionDetectionMiddleware();
|
|
184
291
|
var recursionDetectionMiddlewareOptions = {
|
|
185
292
|
step: "build",
|
|
@@ -205,9 +312,9 @@ var require_dist_cjs19 = __commonJS((exports) => {
|
|
|
205
312
|
});
|
|
206
313
|
|
|
207
314
|
// node_modules/.bun/@aws-sdk+util-endpoints@3.996.6/node_modules/@aws-sdk/util-endpoints/dist-cjs/index.js
|
|
208
|
-
var
|
|
209
|
-
var utilEndpoints =
|
|
210
|
-
var urlParser =
|
|
315
|
+
var require_dist_cjs18 = __commonJS((exports) => {
|
|
316
|
+
var utilEndpoints = require_dist_cjs12();
|
|
317
|
+
var urlParser = require_dist_cjs4();
|
|
211
318
|
var isVirtualHostableS3Bucket = (value, allowSubDomains = false) => {
|
|
212
319
|
if (allowSubDomains) {
|
|
213
320
|
for (const label of value.split(".")) {
|
|
@@ -603,7 +710,7 @@ var require_dist_cjs20 = __commonJS((exports) => {
|
|
|
603
710
|
});
|
|
604
711
|
|
|
605
712
|
// node_modules/.bun/@smithy+service-error-classification@4.2.13/node_modules/@smithy/service-error-classification/dist-cjs/index.js
|
|
606
|
-
var
|
|
713
|
+
var require_dist_cjs19 = __commonJS((exports) => {
|
|
607
714
|
var CLOCK_SKEW_ERROR_CODES = [
|
|
608
715
|
"AuthFailure",
|
|
609
716
|
"InvalidSignatureException",
|
|
@@ -671,8 +778,8 @@ var require_dist_cjs21 = __commonJS((exports) => {
|
|
|
671
778
|
});
|
|
672
779
|
|
|
673
780
|
// node_modules/.bun/@smithy+util-retry@4.3.1/node_modules/@smithy/util-retry/dist-cjs/index.js
|
|
674
|
-
var
|
|
675
|
-
var serviceErrorClassification =
|
|
781
|
+
var require_dist_cjs20 = __commonJS((exports) => {
|
|
782
|
+
var serviceErrorClassification = require_dist_cjs19();
|
|
676
783
|
exports.RETRY_MODES = undefined;
|
|
677
784
|
(function(RETRY_MODES) {
|
|
678
785
|
RETRY_MODES["STANDARD"] = "standard";
|
|
@@ -993,12 +1100,12 @@ var require_dist_cjs22 = __commonJS((exports) => {
|
|
|
993
1100
|
});
|
|
994
1101
|
|
|
995
1102
|
// node_modules/.bun/@aws-sdk+middleware-user-agent@3.972.29/node_modules/@aws-sdk/middleware-user-agent/dist-cjs/index.js
|
|
996
|
-
var
|
|
997
|
-
var core =
|
|
998
|
-
var utilEndpoints =
|
|
1103
|
+
var require_dist_cjs21 = __commonJS((exports) => {
|
|
1104
|
+
var core = require_dist_cjs11();
|
|
1105
|
+
var utilEndpoints = require_dist_cjs18();
|
|
999
1106
|
var protocolHttp = require_dist_cjs();
|
|
1000
1107
|
var client = require_client();
|
|
1001
|
-
var utilRetry =
|
|
1108
|
+
var utilRetry = require_dist_cjs20();
|
|
1002
1109
|
var DEFAULT_UA_APP_ID = undefined;
|
|
1003
1110
|
function isValidUserAgentAppId(appId) {
|
|
1004
1111
|
if (appId === undefined) {
|
|
@@ -1171,7 +1278,7 @@ var require_dist_cjs23 = __commonJS((exports) => {
|
|
|
1171
1278
|
});
|
|
1172
1279
|
|
|
1173
1280
|
// node_modules/.bun/@smithy+middleware-content-length@4.2.13/node_modules/@smithy/middleware-content-length/dist-cjs/index.js
|
|
1174
|
-
var
|
|
1281
|
+
var require_dist_cjs22 = __commonJS((exports) => {
|
|
1175
1282
|
var protocolHttp = require_dist_cjs();
|
|
1176
1283
|
var CONTENT_LENGTH_HEADER = "content-length";
|
|
1177
1284
|
function contentLengthMiddleware(bodyLengthChecker) {
|
|
@@ -1215,7 +1322,7 @@ var require_dist_cjs24 = __commonJS((exports) => {
|
|
|
1215
1322
|
var require_getEndpointUrlConfig = __commonJS((exports) => {
|
|
1216
1323
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1217
1324
|
exports.getEndpointUrlConfig = undefined;
|
|
1218
|
-
var shared_ini_file_loader_1 =
|
|
1325
|
+
var shared_ini_file_loader_1 = require_dist_cjs2();
|
|
1219
1326
|
var ENV_ENDPOINT_URL = "AWS_ENDPOINT_URL";
|
|
1220
1327
|
var CONFIG_ENDPOINT_URL = "endpoint_url";
|
|
1221
1328
|
var getEndpointUrlConfig = (serviceId) => ({
|
|
@@ -1253,14 +1360,14 @@ var require_getEndpointUrlConfig = __commonJS((exports) => {
|
|
|
1253
1360
|
var require_getEndpointFromConfig = __commonJS((exports) => {
|
|
1254
1361
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1255
1362
|
exports.getEndpointFromConfig = undefined;
|
|
1256
|
-
var node_config_provider_1 =
|
|
1363
|
+
var node_config_provider_1 = require_dist_cjs3();
|
|
1257
1364
|
var getEndpointUrlConfig_1 = require_getEndpointUrlConfig();
|
|
1258
1365
|
var getEndpointFromConfig = async (serviceId) => (0, node_config_provider_1.loadConfig)((0, getEndpointUrlConfig_1.getEndpointUrlConfig)(serviceId ?? ""))();
|
|
1259
1366
|
exports.getEndpointFromConfig = getEndpointFromConfig;
|
|
1260
1367
|
});
|
|
1261
1368
|
|
|
1262
1369
|
// node_modules/.bun/@smithy+middleware-serde@4.2.17/node_modules/@smithy/middleware-serde/dist-cjs/index.js
|
|
1263
|
-
var
|
|
1370
|
+
var require_dist_cjs23 = __commonJS((exports) => {
|
|
1264
1371
|
var protocolHttp = require_dist_cjs();
|
|
1265
1372
|
var endpoints = require_endpoints();
|
|
1266
1373
|
var deserializerMiddleware = (options, deserializer) => (next, context) => async (args) => {
|
|
@@ -1356,12 +1463,12 @@ var require_dist_cjs25 = __commonJS((exports) => {
|
|
|
1356
1463
|
});
|
|
1357
1464
|
|
|
1358
1465
|
// node_modules/.bun/@smithy+middleware-endpoint@4.4.29/node_modules/@smithy/middleware-endpoint/dist-cjs/index.js
|
|
1359
|
-
var
|
|
1360
|
-
var core =
|
|
1361
|
-
var utilMiddleware =
|
|
1466
|
+
var require_dist_cjs24 = __commonJS((exports) => {
|
|
1467
|
+
var core = require_dist_cjs11();
|
|
1468
|
+
var utilMiddleware = require_dist_cjs5();
|
|
1362
1469
|
var getEndpointFromConfig = require_getEndpointFromConfig();
|
|
1363
|
-
var urlParser =
|
|
1364
|
-
var middlewareSerde =
|
|
1470
|
+
var urlParser = require_dist_cjs4();
|
|
1471
|
+
var middlewareSerde = require_dist_cjs23();
|
|
1365
1472
|
var resolveParamsForS3 = async (endpointParams) => {
|
|
1366
1473
|
const bucket = endpointParams?.Bucket || "";
|
|
1367
1474
|
if (typeof endpointParams.Bucket === "string") {
|
|
@@ -1616,13 +1723,13 @@ var require_isStreamingPayload = __commonJS((exports) => {
|
|
|
1616
1723
|
});
|
|
1617
1724
|
|
|
1618
1725
|
// node_modules/.bun/@smithy+middleware-retry@4.5.1/node_modules/@smithy/middleware-retry/dist-cjs/index.js
|
|
1619
|
-
var
|
|
1620
|
-
var utilRetry =
|
|
1726
|
+
var require_dist_cjs25 = __commonJS((exports) => {
|
|
1727
|
+
var utilRetry = require_dist_cjs20();
|
|
1621
1728
|
var protocolHttp = require_dist_cjs();
|
|
1622
|
-
var serviceErrorClassification =
|
|
1623
|
-
var uuid =
|
|
1624
|
-
var utilMiddleware =
|
|
1625
|
-
var smithyClient =
|
|
1729
|
+
var serviceErrorClassification = require_dist_cjs19();
|
|
1730
|
+
var uuid = require_dist_cjs6();
|
|
1731
|
+
var utilMiddleware = require_dist_cjs5();
|
|
1732
|
+
var smithyClient = require_dist_cjs10();
|
|
1626
1733
|
var isStreamingPayload = require_isStreamingPayload();
|
|
1627
1734
|
var serde = require_serde();
|
|
1628
1735
|
var asSdkError = (error) => {
|
|
@@ -1993,8 +2100,8 @@ var require_stsRegionDefaultResolver = __commonJS((exports) => {
|
|
|
1993
2100
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1994
2101
|
exports.warning = undefined;
|
|
1995
2102
|
exports.stsRegionDefaultResolver = stsRegionDefaultResolver;
|
|
1996
|
-
var config_resolver_1 =
|
|
1997
|
-
var node_config_provider_1 =
|
|
2103
|
+
var config_resolver_1 = require_dist_cjs14();
|
|
2104
|
+
var node_config_provider_1 = require_dist_cjs3();
|
|
1998
2105
|
function stsRegionDefaultResolver(loaderConfig = {}) {
|
|
1999
2106
|
return (0, node_config_provider_1.loadConfig)({
|
|
2000
2107
|
...config_resolver_1.NODE_REGION_CONFIG_OPTIONS,
|
|
@@ -2012,9 +2119,9 @@ var require_stsRegionDefaultResolver = __commonJS((exports) => {
|
|
|
2012
2119
|
});
|
|
2013
2120
|
|
|
2014
2121
|
// node_modules/.bun/@aws-sdk+region-config-resolver@3.972.11/node_modules/@aws-sdk/region-config-resolver/dist-cjs/index.js
|
|
2015
|
-
var
|
|
2122
|
+
var require_dist_cjs26 = __commonJS((exports) => {
|
|
2016
2123
|
var stsRegionDefaultResolver = require_stsRegionDefaultResolver();
|
|
2017
|
-
var configResolver =
|
|
2124
|
+
var configResolver = require_dist_cjs14();
|
|
2018
2125
|
var getAwsRegionExtensionConfiguration = (runtimeConfig) => {
|
|
2019
2126
|
return {
|
|
2020
2127
|
setRegion(region) {
|
|
@@ -2048,14 +2155,14 @@ var require_dist_cjs28 = __commonJS((exports) => {
|
|
|
2048
2155
|
});
|
|
2049
2156
|
|
|
2050
2157
|
// node_modules/.bun/@aws-sdk+util-user-agent-node@3.973.15/node_modules/@aws-sdk/util-user-agent-node/dist-cjs/index.js
|
|
2051
|
-
var
|
|
2052
|
-
var __dirname = "
|
|
2158
|
+
var require_dist_cjs27 = __commonJS((exports) => {
|
|
2159
|
+
var __dirname = "D:\\source_codespace\\geroge\\costrict-repo\\csc\\node_modules\\.bun\\@aws-sdk+util-user-agent-node@3.973.15\\node_modules\\@aws-sdk\\util-user-agent-node\\dist-cjs";
|
|
2053
2160
|
var node_os = __require("os");
|
|
2054
2161
|
var node_process = __require("process");
|
|
2055
|
-
var utilConfigProvider =
|
|
2162
|
+
var utilConfigProvider = require_dist_cjs13();
|
|
2056
2163
|
var promises = __require("fs/promises");
|
|
2057
2164
|
var node_path = __require("path");
|
|
2058
|
-
var middlewareUserAgent =
|
|
2165
|
+
var middlewareUserAgent = require_dist_cjs21();
|
|
2059
2166
|
var getRuntimeUserAgentPair = () => {
|
|
2060
2167
|
const runtimesToCheck = ["deno", "bun", "llrt"];
|
|
2061
2168
|
for (const runtime of runtimesToCheck) {
|
|
@@ -2219,9 +2326,9 @@ var require_dist_cjs29 = __commonJS((exports) => {
|
|
|
2219
2326
|
});
|
|
2220
2327
|
|
|
2221
2328
|
// node_modules/.bun/@smithy+hash-node@4.2.13/node_modules/@smithy/hash-node/dist-cjs/index.js
|
|
2222
|
-
var
|
|
2223
|
-
var utilBufferFrom =
|
|
2224
|
-
var utilUtf8 =
|
|
2329
|
+
var require_dist_cjs28 = __commonJS((exports) => {
|
|
2330
|
+
var utilBufferFrom = require_dist_cjs7();
|
|
2331
|
+
var utilUtf8 = require_dist_cjs8();
|
|
2225
2332
|
var buffer = __require("buffer");
|
|
2226
2333
|
var crypto = __require("crypto");
|
|
2227
2334
|
|
|
@@ -2259,85 +2366,72 @@ var require_dist_cjs30 = __commonJS((exports) => {
|
|
|
2259
2366
|
exports.Hash = Hash;
|
|
2260
2367
|
});
|
|
2261
2368
|
|
|
2262
|
-
// node_modules/.bun/@smithy+util-
|
|
2263
|
-
var
|
|
2264
|
-
var
|
|
2265
|
-
var
|
|
2266
|
-
|
|
2267
|
-
|
|
2268
|
-
|
|
2269
|
-
|
|
2270
|
-
|
|
2271
|
-
|
|
2272
|
-
|
|
2273
|
-
|
|
2274
|
-
|
|
2275
|
-
|
|
2276
|
-
|
|
2277
|
-
|
|
2278
|
-
|
|
2279
|
-
|
|
2280
|
-
|
|
2281
|
-
|
|
2282
|
-
|
|
2283
|
-
|
|
2284
|
-
|
|
2285
|
-
const mode = typeof defaultsMode === "function" ? await defaultsMode() : defaultsMode;
|
|
2286
|
-
switch (mode?.toLowerCase()) {
|
|
2287
|
-
case "auto":
|
|
2288
|
-
return resolveNodeDefaultsModeAuto(region);
|
|
2289
|
-
case "in-region":
|
|
2290
|
-
case "cross-region":
|
|
2291
|
-
case "mobile":
|
|
2292
|
-
case "standard":
|
|
2293
|
-
case "legacy":
|
|
2294
|
-
return Promise.resolve(mode?.toLocaleLowerCase());
|
|
2295
|
-
case undefined:
|
|
2296
|
-
return Promise.resolve("legacy");
|
|
2297
|
-
default:
|
|
2298
|
-
throw new Error(`Invalid parameter for "defaultsMode", expect ${DEFAULTS_MODE_OPTIONS.join(", ")}, got ${mode}`);
|
|
2299
|
-
}
|
|
2300
|
-
});
|
|
2301
|
-
var resolveNodeDefaultsModeAuto = async (clientRegion) => {
|
|
2302
|
-
if (clientRegion) {
|
|
2303
|
-
const resolvedRegion = typeof clientRegion === "function" ? await clientRegion() : clientRegion;
|
|
2304
|
-
const inferredRegion = await inferPhysicalRegion();
|
|
2305
|
-
if (!inferredRegion) {
|
|
2306
|
-
return "standard";
|
|
2307
|
-
}
|
|
2308
|
-
if (resolvedRegion === inferredRegion) {
|
|
2309
|
-
return "in-region";
|
|
2310
|
-
} else {
|
|
2311
|
-
return "cross-region";
|
|
2312
|
-
}
|
|
2313
|
-
}
|
|
2314
|
-
return "standard";
|
|
2369
|
+
// node_modules/.bun/@smithy+util-body-length-node@4.2.3/node_modules/@smithy/util-body-length-node/dist-cjs/index.js
|
|
2370
|
+
var require_dist_cjs29 = __commonJS((exports) => {
|
|
2371
|
+
var node_fs = __require("fs");
|
|
2372
|
+
var calculateBodyLength = (body) => {
|
|
2373
|
+
if (!body) {
|
|
2374
|
+
return 0;
|
|
2375
|
+
}
|
|
2376
|
+
if (typeof body === "string") {
|
|
2377
|
+
return Buffer.byteLength(body);
|
|
2378
|
+
} else if (typeof body.byteLength === "number") {
|
|
2379
|
+
return body.byteLength;
|
|
2380
|
+
} else if (typeof body.size === "number") {
|
|
2381
|
+
return body.size;
|
|
2382
|
+
} else if (typeof body.start === "number" && typeof body.end === "number") {
|
|
2383
|
+
return body.end + 1 - body.start;
|
|
2384
|
+
} else if (body instanceof node_fs.ReadStream) {
|
|
2385
|
+
if (body.path != null) {
|
|
2386
|
+
return node_fs.lstatSync(body.path).size;
|
|
2387
|
+
} else if (typeof body.fd === "number") {
|
|
2388
|
+
return node_fs.fstatSync(body.fd).size;
|
|
2389
|
+
}
|
|
2390
|
+
}
|
|
2391
|
+
throw new Error(`Body Length computation failed for ${body}`);
|
|
2315
2392
|
};
|
|
2316
|
-
|
|
2317
|
-
|
|
2318
|
-
|
|
2319
|
-
|
|
2320
|
-
|
|
2321
|
-
|
|
2322
|
-
|
|
2323
|
-
|
|
2324
|
-
|
|
2325
|
-
|
|
2326
|
-
|
|
2393
|
+
exports.calculateBodyLength = calculateBodyLength;
|
|
2394
|
+
});
|
|
2395
|
+
|
|
2396
|
+
// node_modules/.bun/@smithy+util-body-length-browser@4.2.2/node_modules/@smithy/util-body-length-browser/dist-cjs/index.js
|
|
2397
|
+
var require_dist_cjs30 = __commonJS((exports) => {
|
|
2398
|
+
var TEXT_ENCODER = typeof TextEncoder == "function" ? new TextEncoder : null;
|
|
2399
|
+
var calculateBodyLength = (body) => {
|
|
2400
|
+
if (typeof body === "string") {
|
|
2401
|
+
if (TEXT_ENCODER) {
|
|
2402
|
+
return TEXT_ENCODER.encode(body).byteLength;
|
|
2403
|
+
}
|
|
2404
|
+
let len = body.length;
|
|
2405
|
+
for (let i = len - 1;i >= 0; i--) {
|
|
2406
|
+
const code = body.charCodeAt(i);
|
|
2407
|
+
if (code > 127 && code <= 2047)
|
|
2408
|
+
len++;
|
|
2409
|
+
else if (code > 2047 && code <= 65535)
|
|
2410
|
+
len += 2;
|
|
2411
|
+
if (code >= 56320 && code <= 57343)
|
|
2412
|
+
i--;
|
|
2413
|
+
}
|
|
2414
|
+
return len;
|
|
2415
|
+
} else if (typeof body.byteLength === "number") {
|
|
2416
|
+
return body.byteLength;
|
|
2417
|
+
} else if (typeof body.size === "number") {
|
|
2418
|
+
return body.size;
|
|
2419
|
+
}
|
|
2420
|
+
throw new Error(`Body Length computation failed for ${body}`);
|
|
2327
2421
|
};
|
|
2328
|
-
exports.
|
|
2422
|
+
exports.calculateBodyLength = calculateBodyLength;
|
|
2329
2423
|
});
|
|
2330
2424
|
|
|
2331
2425
|
// node_modules/.bun/@smithy+core@3.23.14/node_modules/@smithy/core/dist-cjs/submodules/cbor/index.js
|
|
2332
2426
|
var require_cbor = __commonJS((exports) => {
|
|
2333
2427
|
var serde = require_serde();
|
|
2334
|
-
var utilUtf8 =
|
|
2428
|
+
var utilUtf8 = require_dist_cjs8();
|
|
2335
2429
|
var protocols = require_protocols();
|
|
2336
2430
|
var protocolHttp = require_dist_cjs();
|
|
2337
|
-
var utilBodyLengthBrowser =
|
|
2431
|
+
var utilBodyLengthBrowser = require_dist_cjs30();
|
|
2338
2432
|
var schema = require_schema();
|
|
2339
|
-
var utilMiddleware =
|
|
2340
|
-
var utilBase64 =
|
|
2433
|
+
var utilMiddleware = require_dist_cjs5();
|
|
2434
|
+
var utilBase64 = require_dist_cjs9();
|
|
2341
2435
|
var majorUint64 = 0;
|
|
2342
2436
|
var majorNegativeInt64 = 1;
|
|
2343
2437
|
var majorUnstructuredByteString = 2;
|
|
@@ -3353,6 +3447,1557 @@ var require_cbor = __commonJS((exports) => {
|
|
|
3353
3447
|
exports.tagSymbol = tagSymbol;
|
|
3354
3448
|
});
|
|
3355
3449
|
|
|
3450
|
+
// node_modules/.bun/fast-xml-parser@5.5.8/node_modules/fast-xml-parser/lib/fxp.cjs
|
|
3451
|
+
var require_fxp = __commonJS((exports, module) => {
|
|
3452
|
+
(() => {
|
|
3453
|
+
var t = { d: (e2, i2) => {
|
|
3454
|
+
for (var n2 in i2)
|
|
3455
|
+
t.o(i2, n2) && !t.o(e2, n2) && Object.defineProperty(e2, n2, { enumerable: true, get: i2[n2] });
|
|
3456
|
+
}, o: (t2, e2) => Object.prototype.hasOwnProperty.call(t2, e2), r: (t2) => {
|
|
3457
|
+
typeof Symbol != "undefined" && Symbol.toStringTag && Object.defineProperty(t2, Symbol.toStringTag, { value: "Module" }), Object.defineProperty(t2, "__esModule", { value: true });
|
|
3458
|
+
} }, e = {};
|
|
3459
|
+
t.r(e), t.d(e, { XMLBuilder: () => $t, XMLParser: () => gt, XMLValidator: () => It });
|
|
3460
|
+
const i = ":A-Za-z_\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD", n = new RegExp("^[" + i + "][" + i + "\\-.\\d\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$");
|
|
3461
|
+
function s(t2, e2) {
|
|
3462
|
+
const i2 = [];
|
|
3463
|
+
let n2 = e2.exec(t2);
|
|
3464
|
+
for (;n2; ) {
|
|
3465
|
+
const s2 = [];
|
|
3466
|
+
s2.startIndex = e2.lastIndex - n2[0].length;
|
|
3467
|
+
const r2 = n2.length;
|
|
3468
|
+
for (let t3 = 0;t3 < r2; t3++)
|
|
3469
|
+
s2.push(n2[t3]);
|
|
3470
|
+
i2.push(s2), n2 = e2.exec(t2);
|
|
3471
|
+
}
|
|
3472
|
+
return i2;
|
|
3473
|
+
}
|
|
3474
|
+
const r = function(t2) {
|
|
3475
|
+
return !(n.exec(t2) == null);
|
|
3476
|
+
}, o = ["hasOwnProperty", "toString", "valueOf", "__defineGetter__", "__defineSetter__", "__lookupGetter__", "__lookupSetter__"], a = ["__proto__", "constructor", "prototype"], h = { allowBooleanAttributes: false, unpairedTags: [] };
|
|
3477
|
+
function l(t2, e2) {
|
|
3478
|
+
e2 = Object.assign({}, h, e2);
|
|
3479
|
+
const i2 = [];
|
|
3480
|
+
let n2 = false, s2 = false;
|
|
3481
|
+
t2[0] === "\uFEFF" && (t2 = t2.substr(1));
|
|
3482
|
+
for (let r2 = 0;r2 < t2.length; r2++)
|
|
3483
|
+
if (t2[r2] === "<" && t2[r2 + 1] === "?") {
|
|
3484
|
+
if (r2 += 2, r2 = u(t2, r2), r2.err)
|
|
3485
|
+
return r2;
|
|
3486
|
+
} else {
|
|
3487
|
+
if (t2[r2] !== "<") {
|
|
3488
|
+
if (p(t2[r2]))
|
|
3489
|
+
continue;
|
|
3490
|
+
return b("InvalidChar", "char '" + t2[r2] + "' is not expected.", w(t2, r2));
|
|
3491
|
+
}
|
|
3492
|
+
{
|
|
3493
|
+
let o2 = r2;
|
|
3494
|
+
if (r2++, t2[r2] === "!") {
|
|
3495
|
+
r2 = c(t2, r2);
|
|
3496
|
+
continue;
|
|
3497
|
+
}
|
|
3498
|
+
{
|
|
3499
|
+
let a2 = false;
|
|
3500
|
+
t2[r2] === "/" && (a2 = true, r2++);
|
|
3501
|
+
let h2 = "";
|
|
3502
|
+
for (;r2 < t2.length && t2[r2] !== ">" && t2[r2] !== " " && t2[r2] !== "\t" && t2[r2] !== `
|
|
3503
|
+
` && t2[r2] !== "\r"; r2++)
|
|
3504
|
+
h2 += t2[r2];
|
|
3505
|
+
if (h2 = h2.trim(), h2[h2.length - 1] === "/" && (h2 = h2.substring(0, h2.length - 1), r2--), !y(h2)) {
|
|
3506
|
+
let e3;
|
|
3507
|
+
return e3 = h2.trim().length === 0 ? "Invalid space after '<'." : "Tag '" + h2 + "' is an invalid name.", b("InvalidTag", e3, w(t2, r2));
|
|
3508
|
+
}
|
|
3509
|
+
const l2 = g(t2, r2);
|
|
3510
|
+
if (l2 === false)
|
|
3511
|
+
return b("InvalidAttr", "Attributes for '" + h2 + "' have open quote.", w(t2, r2));
|
|
3512
|
+
let d2 = l2.value;
|
|
3513
|
+
if (r2 = l2.index, d2[d2.length - 1] === "/") {
|
|
3514
|
+
const i3 = r2 - d2.length;
|
|
3515
|
+
d2 = d2.substring(0, d2.length - 1);
|
|
3516
|
+
const s3 = x(d2, e2);
|
|
3517
|
+
if (s3 !== true)
|
|
3518
|
+
return b(s3.err.code, s3.err.msg, w(t2, i3 + s3.err.line));
|
|
3519
|
+
n2 = true;
|
|
3520
|
+
} else if (a2) {
|
|
3521
|
+
if (!l2.tagClosed)
|
|
3522
|
+
return b("InvalidTag", "Closing tag '" + h2 + "' doesn't have proper closing.", w(t2, r2));
|
|
3523
|
+
if (d2.trim().length > 0)
|
|
3524
|
+
return b("InvalidTag", "Closing tag '" + h2 + "' can't have attributes or invalid starting.", w(t2, o2));
|
|
3525
|
+
if (i2.length === 0)
|
|
3526
|
+
return b("InvalidTag", "Closing tag '" + h2 + "' has not been opened.", w(t2, o2));
|
|
3527
|
+
{
|
|
3528
|
+
const e3 = i2.pop();
|
|
3529
|
+
if (h2 !== e3.tagName) {
|
|
3530
|
+
let i3 = w(t2, e3.tagStartPos);
|
|
3531
|
+
return b("InvalidTag", "Expected closing tag '" + e3.tagName + "' (opened in line " + i3.line + ", col " + i3.col + ") instead of closing tag '" + h2 + "'.", w(t2, o2));
|
|
3532
|
+
}
|
|
3533
|
+
i2.length == 0 && (s2 = true);
|
|
3534
|
+
}
|
|
3535
|
+
} else {
|
|
3536
|
+
const a3 = x(d2, e2);
|
|
3537
|
+
if (a3 !== true)
|
|
3538
|
+
return b(a3.err.code, a3.err.msg, w(t2, r2 - d2.length + a3.err.line));
|
|
3539
|
+
if (s2 === true)
|
|
3540
|
+
return b("InvalidXml", "Multiple possible root nodes found.", w(t2, r2));
|
|
3541
|
+
e2.unpairedTags.indexOf(h2) !== -1 || i2.push({ tagName: h2, tagStartPos: o2 }), n2 = true;
|
|
3542
|
+
}
|
|
3543
|
+
for (r2++;r2 < t2.length; r2++)
|
|
3544
|
+
if (t2[r2] === "<") {
|
|
3545
|
+
if (t2[r2 + 1] === "!") {
|
|
3546
|
+
r2++, r2 = c(t2, r2);
|
|
3547
|
+
continue;
|
|
3548
|
+
}
|
|
3549
|
+
if (t2[r2 + 1] !== "?")
|
|
3550
|
+
break;
|
|
3551
|
+
if (r2 = u(t2, ++r2), r2.err)
|
|
3552
|
+
return r2;
|
|
3553
|
+
} else if (t2[r2] === "&") {
|
|
3554
|
+
const e3 = N(t2, r2);
|
|
3555
|
+
if (e3 == -1)
|
|
3556
|
+
return b("InvalidChar", "char '&' is not expected.", w(t2, r2));
|
|
3557
|
+
r2 = e3;
|
|
3558
|
+
} else if (s2 === true && !p(t2[r2]))
|
|
3559
|
+
return b("InvalidXml", "Extra text at the end", w(t2, r2));
|
|
3560
|
+
t2[r2] === "<" && r2--;
|
|
3561
|
+
}
|
|
3562
|
+
}
|
|
3563
|
+
}
|
|
3564
|
+
return n2 ? i2.length == 1 ? b("InvalidTag", "Unclosed tag '" + i2[0].tagName + "'.", w(t2, i2[0].tagStartPos)) : !(i2.length > 0) || b("InvalidXml", "Invalid '" + JSON.stringify(i2.map((t3) => t3.tagName), null, 4).replace(/\r?\n/g, "") + "' found.", { line: 1, col: 1 }) : b("InvalidXml", "Start tag expected.", 1);
|
|
3565
|
+
}
|
|
3566
|
+
function p(t2) {
|
|
3567
|
+
return t2 === " " || t2 === "\t" || t2 === `
|
|
3568
|
+
` || t2 === "\r";
|
|
3569
|
+
}
|
|
3570
|
+
function u(t2, e2) {
|
|
3571
|
+
const i2 = e2;
|
|
3572
|
+
for (;e2 < t2.length; e2++)
|
|
3573
|
+
if (t2[e2] == "?" || t2[e2] == " ") {
|
|
3574
|
+
const n2 = t2.substr(i2, e2 - i2);
|
|
3575
|
+
if (e2 > 5 && n2 === "xml")
|
|
3576
|
+
return b("InvalidXml", "XML declaration allowed only at the start of the document.", w(t2, e2));
|
|
3577
|
+
if (t2[e2] == "?" && t2[e2 + 1] == ">") {
|
|
3578
|
+
e2++;
|
|
3579
|
+
break;
|
|
3580
|
+
}
|
|
3581
|
+
continue;
|
|
3582
|
+
}
|
|
3583
|
+
return e2;
|
|
3584
|
+
}
|
|
3585
|
+
function c(t2, e2) {
|
|
3586
|
+
if (t2.length > e2 + 5 && t2[e2 + 1] === "-" && t2[e2 + 2] === "-") {
|
|
3587
|
+
for (e2 += 3;e2 < t2.length; e2++)
|
|
3588
|
+
if (t2[e2] === "-" && t2[e2 + 1] === "-" && t2[e2 + 2] === ">") {
|
|
3589
|
+
e2 += 2;
|
|
3590
|
+
break;
|
|
3591
|
+
}
|
|
3592
|
+
} else if (t2.length > e2 + 8 && t2[e2 + 1] === "D" && t2[e2 + 2] === "O" && t2[e2 + 3] === "C" && t2[e2 + 4] === "T" && t2[e2 + 5] === "Y" && t2[e2 + 6] === "P" && t2[e2 + 7] === "E") {
|
|
3593
|
+
let i2 = 1;
|
|
3594
|
+
for (e2 += 8;e2 < t2.length; e2++)
|
|
3595
|
+
if (t2[e2] === "<")
|
|
3596
|
+
i2++;
|
|
3597
|
+
else if (t2[e2] === ">" && (i2--, i2 === 0))
|
|
3598
|
+
break;
|
|
3599
|
+
} else if (t2.length > e2 + 9 && t2[e2 + 1] === "[" && t2[e2 + 2] === "C" && t2[e2 + 3] === "D" && t2[e2 + 4] === "A" && t2[e2 + 5] === "T" && t2[e2 + 6] === "A" && t2[e2 + 7] === "[") {
|
|
3600
|
+
for (e2 += 8;e2 < t2.length; e2++)
|
|
3601
|
+
if (t2[e2] === "]" && t2[e2 + 1] === "]" && t2[e2 + 2] === ">") {
|
|
3602
|
+
e2 += 2;
|
|
3603
|
+
break;
|
|
3604
|
+
}
|
|
3605
|
+
}
|
|
3606
|
+
return e2;
|
|
3607
|
+
}
|
|
3608
|
+
const d = '"', f = "'";
|
|
3609
|
+
function g(t2, e2) {
|
|
3610
|
+
let i2 = "", n2 = "", s2 = false;
|
|
3611
|
+
for (;e2 < t2.length; e2++) {
|
|
3612
|
+
if (t2[e2] === d || t2[e2] === f)
|
|
3613
|
+
n2 === "" ? n2 = t2[e2] : n2 !== t2[e2] || (n2 = "");
|
|
3614
|
+
else if (t2[e2] === ">" && n2 === "") {
|
|
3615
|
+
s2 = true;
|
|
3616
|
+
break;
|
|
3617
|
+
}
|
|
3618
|
+
i2 += t2[e2];
|
|
3619
|
+
}
|
|
3620
|
+
return n2 === "" && { value: i2, index: e2, tagClosed: s2 };
|
|
3621
|
+
}
|
|
3622
|
+
const m = new RegExp(`(\\s*)([^\\s=]+)(\\s*=)?(\\s*(['"])(([\\s\\S])*?)\\5)?`, "g");
|
|
3623
|
+
function x(t2, e2) {
|
|
3624
|
+
const i2 = s(t2, m), n2 = {};
|
|
3625
|
+
for (let t3 = 0;t3 < i2.length; t3++) {
|
|
3626
|
+
if (i2[t3][1].length === 0)
|
|
3627
|
+
return b("InvalidAttr", "Attribute '" + i2[t3][2] + "' has no space in starting.", v(i2[t3]));
|
|
3628
|
+
if (i2[t3][3] !== undefined && i2[t3][4] === undefined)
|
|
3629
|
+
return b("InvalidAttr", "Attribute '" + i2[t3][2] + "' is without value.", v(i2[t3]));
|
|
3630
|
+
if (i2[t3][3] === undefined && !e2.allowBooleanAttributes)
|
|
3631
|
+
return b("InvalidAttr", "boolean attribute '" + i2[t3][2] + "' is not allowed.", v(i2[t3]));
|
|
3632
|
+
const s2 = i2[t3][2];
|
|
3633
|
+
if (!E(s2))
|
|
3634
|
+
return b("InvalidAttr", "Attribute '" + s2 + "' is an invalid name.", v(i2[t3]));
|
|
3635
|
+
if (Object.prototype.hasOwnProperty.call(n2, s2))
|
|
3636
|
+
return b("InvalidAttr", "Attribute '" + s2 + "' is repeated.", v(i2[t3]));
|
|
3637
|
+
n2[s2] = 1;
|
|
3638
|
+
}
|
|
3639
|
+
return true;
|
|
3640
|
+
}
|
|
3641
|
+
function N(t2, e2) {
|
|
3642
|
+
if (t2[++e2] === ";")
|
|
3643
|
+
return -1;
|
|
3644
|
+
if (t2[e2] === "#")
|
|
3645
|
+
return function(t3, e3) {
|
|
3646
|
+
let i3 = /\d/;
|
|
3647
|
+
for (t3[e3] === "x" && (e3++, i3 = /[\da-fA-F]/);e3 < t3.length; e3++) {
|
|
3648
|
+
if (t3[e3] === ";")
|
|
3649
|
+
return e3;
|
|
3650
|
+
if (!t3[e3].match(i3))
|
|
3651
|
+
break;
|
|
3652
|
+
}
|
|
3653
|
+
return -1;
|
|
3654
|
+
}(t2, ++e2);
|
|
3655
|
+
let i2 = 0;
|
|
3656
|
+
for (;e2 < t2.length; e2++, i2++)
|
|
3657
|
+
if (!(t2[e2].match(/\w/) && i2 < 20)) {
|
|
3658
|
+
if (t2[e2] === ";")
|
|
3659
|
+
break;
|
|
3660
|
+
return -1;
|
|
3661
|
+
}
|
|
3662
|
+
return e2;
|
|
3663
|
+
}
|
|
3664
|
+
function b(t2, e2, i2) {
|
|
3665
|
+
return { err: { code: t2, msg: e2, line: i2.line || i2, col: i2.col } };
|
|
3666
|
+
}
|
|
3667
|
+
function E(t2) {
|
|
3668
|
+
return r(t2);
|
|
3669
|
+
}
|
|
3670
|
+
function y(t2) {
|
|
3671
|
+
return r(t2);
|
|
3672
|
+
}
|
|
3673
|
+
function w(t2, e2) {
|
|
3674
|
+
const i2 = t2.substring(0, e2).split(/\r?\n/);
|
|
3675
|
+
return { line: i2.length, col: i2[i2.length - 1].length + 1 };
|
|
3676
|
+
}
|
|
3677
|
+
function v(t2) {
|
|
3678
|
+
return t2.startIndex + t2[1].length;
|
|
3679
|
+
}
|
|
3680
|
+
const T = (t2) => o.includes(t2) ? "__" + t2 : t2, P = { preserveOrder: false, attributeNamePrefix: "@_", attributesGroupName: false, textNodeName: "#text", ignoreAttributes: true, removeNSPrefix: false, allowBooleanAttributes: false, parseTagValue: true, parseAttributeValue: false, trimValues: true, cdataPropName: false, numberParseOptions: { hex: true, leadingZeros: true, eNotation: true }, tagValueProcessor: function(t2, e2) {
|
|
3681
|
+
return e2;
|
|
3682
|
+
}, attributeValueProcessor: function(t2, e2) {
|
|
3683
|
+
return e2;
|
|
3684
|
+
}, stopNodes: [], alwaysCreateTextNode: false, isArray: () => false, commentPropName: false, unpairedTags: [], processEntities: true, htmlEntities: false, ignoreDeclaration: false, ignorePiTags: false, transformTagName: false, transformAttributeName: false, updateTag: function(t2, e2, i2) {
|
|
3685
|
+
return t2;
|
|
3686
|
+
}, captureMetaData: false, maxNestedTags: 100, strictReservedNames: true, jPath: true, onDangerousProperty: T };
|
|
3687
|
+
function S(t2, e2) {
|
|
3688
|
+
if (typeof t2 != "string")
|
|
3689
|
+
return;
|
|
3690
|
+
const i2 = t2.toLowerCase();
|
|
3691
|
+
if (o.some((t3) => i2 === t3.toLowerCase()))
|
|
3692
|
+
throw new Error(`[SECURITY] Invalid ${e2}: "${t2}" is a reserved JavaScript keyword that could cause prototype pollution`);
|
|
3693
|
+
if (a.some((t3) => i2 === t3.toLowerCase()))
|
|
3694
|
+
throw new Error(`[SECURITY] Invalid ${e2}: "${t2}" is a reserved JavaScript keyword that could cause prototype pollution`);
|
|
3695
|
+
}
|
|
3696
|
+
function A(t2) {
|
|
3697
|
+
return typeof t2 == "boolean" ? { enabled: t2, maxEntitySize: 1e4, maxExpansionDepth: 10, maxTotalExpansions: 1000, maxExpandedLength: 1e5, maxEntityCount: 100, allowedTags: null, tagFilter: null } : typeof t2 == "object" && t2 !== null ? { enabled: t2.enabled !== false, maxEntitySize: Math.max(1, t2.maxEntitySize ?? 1e4), maxExpansionDepth: Math.max(1, t2.maxExpansionDepth ?? 10), maxTotalExpansions: Math.max(1, t2.maxTotalExpansions ?? 1000), maxExpandedLength: Math.max(1, t2.maxExpandedLength ?? 1e5), maxEntityCount: Math.max(1, t2.maxEntityCount ?? 100), allowedTags: t2.allowedTags ?? null, tagFilter: t2.tagFilter ?? null } : A(true);
|
|
3698
|
+
}
|
|
3699
|
+
const O = function(t2) {
|
|
3700
|
+
const e2 = Object.assign({}, P, t2), i2 = [{ value: e2.attributeNamePrefix, name: "attributeNamePrefix" }, { value: e2.attributesGroupName, name: "attributesGroupName" }, { value: e2.textNodeName, name: "textNodeName" }, { value: e2.cdataPropName, name: "cdataPropName" }, { value: e2.commentPropName, name: "commentPropName" }];
|
|
3701
|
+
for (const { value: t3, name: e3 } of i2)
|
|
3702
|
+
t3 && S(t3, e3);
|
|
3703
|
+
return e2.onDangerousProperty === null && (e2.onDangerousProperty = T), e2.processEntities = A(e2.processEntities), e2.stopNodes && Array.isArray(e2.stopNodes) && (e2.stopNodes = e2.stopNodes.map((t3) => typeof t3 == "string" && t3.startsWith("*.") ? ".." + t3.substring(2) : t3)), e2;
|
|
3704
|
+
};
|
|
3705
|
+
let C;
|
|
3706
|
+
C = typeof Symbol != "function" ? "@@xmlMetadata" : Symbol("XML Node Metadata");
|
|
3707
|
+
|
|
3708
|
+
class $ {
|
|
3709
|
+
constructor(t2) {
|
|
3710
|
+
this.tagname = t2, this.child = [], this[":@"] = Object.create(null);
|
|
3711
|
+
}
|
|
3712
|
+
add(t2, e2) {
|
|
3713
|
+
t2 === "__proto__" && (t2 = "#__proto__"), this.child.push({ [t2]: e2 });
|
|
3714
|
+
}
|
|
3715
|
+
addChild(t2, e2) {
|
|
3716
|
+
t2.tagname === "__proto__" && (t2.tagname = "#__proto__"), t2[":@"] && Object.keys(t2[":@"]).length > 0 ? this.child.push({ [t2.tagname]: t2.child, ":@": t2[":@"] }) : this.child.push({ [t2.tagname]: t2.child }), e2 !== undefined && (this.child[this.child.length - 1][C] = { startIndex: e2 });
|
|
3717
|
+
}
|
|
3718
|
+
static getMetaDataSymbol() {
|
|
3719
|
+
return C;
|
|
3720
|
+
}
|
|
3721
|
+
}
|
|
3722
|
+
|
|
3723
|
+
class I {
|
|
3724
|
+
constructor(t2) {
|
|
3725
|
+
this.suppressValidationErr = !t2, this.options = t2;
|
|
3726
|
+
}
|
|
3727
|
+
readDocType(t2, e2) {
|
|
3728
|
+
const i2 = Object.create(null);
|
|
3729
|
+
let n2 = 0;
|
|
3730
|
+
if (t2[e2 + 3] !== "O" || t2[e2 + 4] !== "C" || t2[e2 + 5] !== "T" || t2[e2 + 6] !== "Y" || t2[e2 + 7] !== "P" || t2[e2 + 8] !== "E")
|
|
3731
|
+
throw new Error("Invalid Tag instead of DOCTYPE");
|
|
3732
|
+
{
|
|
3733
|
+
e2 += 9;
|
|
3734
|
+
let s2 = 1, r2 = false, o2 = false, a2 = "";
|
|
3735
|
+
for (;e2 < t2.length; e2++)
|
|
3736
|
+
if (t2[e2] !== "<" || o2)
|
|
3737
|
+
if (t2[e2] === ">") {
|
|
3738
|
+
if (o2 ? t2[e2 - 1] === "-" && t2[e2 - 2] === "-" && (o2 = false, s2--) : s2--, s2 === 0)
|
|
3739
|
+
break;
|
|
3740
|
+
} else
|
|
3741
|
+
t2[e2] === "[" ? r2 = true : a2 += t2[e2];
|
|
3742
|
+
else {
|
|
3743
|
+
if (r2 && M(t2, "!ENTITY", e2)) {
|
|
3744
|
+
let s3, r3;
|
|
3745
|
+
if (e2 += 7, [s3, r3, e2] = this.readEntityExp(t2, e2 + 1, this.suppressValidationErr), r3.indexOf("&") === -1) {
|
|
3746
|
+
if (this.options.enabled !== false && this.options.maxEntityCount != null && n2 >= this.options.maxEntityCount)
|
|
3747
|
+
throw new Error(`Entity count (${n2 + 1}) exceeds maximum allowed (${this.options.maxEntityCount})`);
|
|
3748
|
+
const t3 = s3.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
|
|
3749
|
+
i2[s3] = { regx: RegExp(`&${t3};`, "g"), val: r3 }, n2++;
|
|
3750
|
+
}
|
|
3751
|
+
} else if (r2 && M(t2, "!ELEMENT", e2)) {
|
|
3752
|
+
e2 += 8;
|
|
3753
|
+
const { index: i3 } = this.readElementExp(t2, e2 + 1);
|
|
3754
|
+
e2 = i3;
|
|
3755
|
+
} else if (r2 && M(t2, "!ATTLIST", e2))
|
|
3756
|
+
e2 += 8;
|
|
3757
|
+
else if (r2 && M(t2, "!NOTATION", e2)) {
|
|
3758
|
+
e2 += 9;
|
|
3759
|
+
const { index: i3 } = this.readNotationExp(t2, e2 + 1, this.suppressValidationErr);
|
|
3760
|
+
e2 = i3;
|
|
3761
|
+
} else {
|
|
3762
|
+
if (!M(t2, "!--", e2))
|
|
3763
|
+
throw new Error("Invalid DOCTYPE");
|
|
3764
|
+
o2 = true;
|
|
3765
|
+
}
|
|
3766
|
+
s2++, a2 = "";
|
|
3767
|
+
}
|
|
3768
|
+
if (s2 !== 0)
|
|
3769
|
+
throw new Error("Unclosed DOCTYPE");
|
|
3770
|
+
}
|
|
3771
|
+
return { entities: i2, i: e2 };
|
|
3772
|
+
}
|
|
3773
|
+
readEntityExp(t2, e2) {
|
|
3774
|
+
const i2 = e2 = j(t2, e2);
|
|
3775
|
+
for (;e2 < t2.length && !/\s/.test(t2[e2]) && t2[e2] !== '"' && t2[e2] !== "'"; )
|
|
3776
|
+
e2++;
|
|
3777
|
+
let n2 = t2.substring(i2, e2);
|
|
3778
|
+
if (_(n2), e2 = j(t2, e2), !this.suppressValidationErr) {
|
|
3779
|
+
if (t2.substring(e2, e2 + 6).toUpperCase() === "SYSTEM")
|
|
3780
|
+
throw new Error("External entities are not supported");
|
|
3781
|
+
if (t2[e2] === "%")
|
|
3782
|
+
throw new Error("Parameter entities are not supported");
|
|
3783
|
+
}
|
|
3784
|
+
let s2 = "";
|
|
3785
|
+
if ([e2, s2] = this.readIdentifierVal(t2, e2, "entity"), this.options.enabled !== false && this.options.maxEntitySize != null && s2.length > this.options.maxEntitySize)
|
|
3786
|
+
throw new Error(`Entity "${n2}" size (${s2.length}) exceeds maximum allowed size (${this.options.maxEntitySize})`);
|
|
3787
|
+
return [n2, s2, --e2];
|
|
3788
|
+
}
|
|
3789
|
+
readNotationExp(t2, e2) {
|
|
3790
|
+
const i2 = e2 = j(t2, e2);
|
|
3791
|
+
for (;e2 < t2.length && !/\s/.test(t2[e2]); )
|
|
3792
|
+
e2++;
|
|
3793
|
+
let n2 = t2.substring(i2, e2);
|
|
3794
|
+
!this.suppressValidationErr && _(n2), e2 = j(t2, e2);
|
|
3795
|
+
const s2 = t2.substring(e2, e2 + 6).toUpperCase();
|
|
3796
|
+
if (!this.suppressValidationErr && s2 !== "SYSTEM" && s2 !== "PUBLIC")
|
|
3797
|
+
throw new Error(`Expected SYSTEM or PUBLIC, found "${s2}"`);
|
|
3798
|
+
e2 += s2.length, e2 = j(t2, e2);
|
|
3799
|
+
let r2 = null, o2 = null;
|
|
3800
|
+
if (s2 === "PUBLIC")
|
|
3801
|
+
[e2, r2] = this.readIdentifierVal(t2, e2, "publicIdentifier"), t2[e2 = j(t2, e2)] !== '"' && t2[e2] !== "'" || ([e2, o2] = this.readIdentifierVal(t2, e2, "systemIdentifier"));
|
|
3802
|
+
else if (s2 === "SYSTEM" && ([e2, o2] = this.readIdentifierVal(t2, e2, "systemIdentifier"), !this.suppressValidationErr && !o2))
|
|
3803
|
+
throw new Error("Missing mandatory system identifier for SYSTEM notation");
|
|
3804
|
+
return { notationName: n2, publicIdentifier: r2, systemIdentifier: o2, index: --e2 };
|
|
3805
|
+
}
|
|
3806
|
+
readIdentifierVal(t2, e2, i2) {
|
|
3807
|
+
let n2 = "";
|
|
3808
|
+
const s2 = t2[e2];
|
|
3809
|
+
if (s2 !== '"' && s2 !== "'")
|
|
3810
|
+
throw new Error(`Expected quoted string, found "${s2}"`);
|
|
3811
|
+
const r2 = ++e2;
|
|
3812
|
+
for (;e2 < t2.length && t2[e2] !== s2; )
|
|
3813
|
+
e2++;
|
|
3814
|
+
if (n2 = t2.substring(r2, e2), t2[e2] !== s2)
|
|
3815
|
+
throw new Error(`Unterminated ${i2} value`);
|
|
3816
|
+
return [++e2, n2];
|
|
3817
|
+
}
|
|
3818
|
+
readElementExp(t2, e2) {
|
|
3819
|
+
const i2 = e2 = j(t2, e2);
|
|
3820
|
+
for (;e2 < t2.length && !/\s/.test(t2[e2]); )
|
|
3821
|
+
e2++;
|
|
3822
|
+
let n2 = t2.substring(i2, e2);
|
|
3823
|
+
if (!this.suppressValidationErr && !r(n2))
|
|
3824
|
+
throw new Error(`Invalid element name: "${n2}"`);
|
|
3825
|
+
let s2 = "";
|
|
3826
|
+
if (t2[e2 = j(t2, e2)] === "E" && M(t2, "MPTY", e2))
|
|
3827
|
+
e2 += 4;
|
|
3828
|
+
else if (t2[e2] === "A" && M(t2, "NY", e2))
|
|
3829
|
+
e2 += 2;
|
|
3830
|
+
else if (t2[e2] === "(") {
|
|
3831
|
+
const i3 = ++e2;
|
|
3832
|
+
for (;e2 < t2.length && t2[e2] !== ")"; )
|
|
3833
|
+
e2++;
|
|
3834
|
+
if (s2 = t2.substring(i3, e2), t2[e2] !== ")")
|
|
3835
|
+
throw new Error("Unterminated content model");
|
|
3836
|
+
} else if (!this.suppressValidationErr)
|
|
3837
|
+
throw new Error(`Invalid Element Expression, found "${t2[e2]}"`);
|
|
3838
|
+
return { elementName: n2, contentModel: s2.trim(), index: e2 };
|
|
3839
|
+
}
|
|
3840
|
+
readAttlistExp(t2, e2) {
|
|
3841
|
+
let i2 = e2 = j(t2, e2);
|
|
3842
|
+
for (;e2 < t2.length && !/\s/.test(t2[e2]); )
|
|
3843
|
+
e2++;
|
|
3844
|
+
let n2 = t2.substring(i2, e2);
|
|
3845
|
+
for (_(n2), i2 = e2 = j(t2, e2);e2 < t2.length && !/\s/.test(t2[e2]); )
|
|
3846
|
+
e2++;
|
|
3847
|
+
let s2 = t2.substring(i2, e2);
|
|
3848
|
+
if (!_(s2))
|
|
3849
|
+
throw new Error(`Invalid attribute name: "${s2}"`);
|
|
3850
|
+
e2 = j(t2, e2);
|
|
3851
|
+
let r2 = "";
|
|
3852
|
+
if (t2.substring(e2, e2 + 8).toUpperCase() === "NOTATION") {
|
|
3853
|
+
if (r2 = "NOTATION", t2[e2 = j(t2, e2 += 8)] !== "(")
|
|
3854
|
+
throw new Error(`Expected '(', found "${t2[e2]}"`);
|
|
3855
|
+
e2++;
|
|
3856
|
+
let i3 = [];
|
|
3857
|
+
for (;e2 < t2.length && t2[e2] !== ")"; ) {
|
|
3858
|
+
const n3 = e2;
|
|
3859
|
+
for (;e2 < t2.length && t2[e2] !== "|" && t2[e2] !== ")"; )
|
|
3860
|
+
e2++;
|
|
3861
|
+
let s3 = t2.substring(n3, e2);
|
|
3862
|
+
if (s3 = s3.trim(), !_(s3))
|
|
3863
|
+
throw new Error(`Invalid notation name: "${s3}"`);
|
|
3864
|
+
i3.push(s3), t2[e2] === "|" && (e2++, e2 = j(t2, e2));
|
|
3865
|
+
}
|
|
3866
|
+
if (t2[e2] !== ")")
|
|
3867
|
+
throw new Error("Unterminated list of notations");
|
|
3868
|
+
e2++, r2 += " (" + i3.join("|") + ")";
|
|
3869
|
+
} else {
|
|
3870
|
+
const i3 = e2;
|
|
3871
|
+
for (;e2 < t2.length && !/\s/.test(t2[e2]); )
|
|
3872
|
+
e2++;
|
|
3873
|
+
r2 += t2.substring(i3, e2);
|
|
3874
|
+
const n3 = ["CDATA", "ID", "IDREF", "IDREFS", "ENTITY", "ENTITIES", "NMTOKEN", "NMTOKENS"];
|
|
3875
|
+
if (!this.suppressValidationErr && !n3.includes(r2.toUpperCase()))
|
|
3876
|
+
throw new Error(`Invalid attribute type: "${r2}"`);
|
|
3877
|
+
}
|
|
3878
|
+
e2 = j(t2, e2);
|
|
3879
|
+
let o2 = "";
|
|
3880
|
+
return t2.substring(e2, e2 + 8).toUpperCase() === "#REQUIRED" ? (o2 = "#REQUIRED", e2 += 8) : t2.substring(e2, e2 + 7).toUpperCase() === "#IMPLIED" ? (o2 = "#IMPLIED", e2 += 7) : [e2, o2] = this.readIdentifierVal(t2, e2, "ATTLIST"), { elementName: n2, attributeName: s2, attributeType: r2, defaultValue: o2, index: e2 };
|
|
3881
|
+
}
|
|
3882
|
+
}
|
|
3883
|
+
const j = (t2, e2) => {
|
|
3884
|
+
for (;e2 < t2.length && /\s/.test(t2[e2]); )
|
|
3885
|
+
e2++;
|
|
3886
|
+
return e2;
|
|
3887
|
+
};
|
|
3888
|
+
function M(t2, e2, i2) {
|
|
3889
|
+
for (let n2 = 0;n2 < e2.length; n2++)
|
|
3890
|
+
if (e2[n2] !== t2[i2 + n2 + 1])
|
|
3891
|
+
return false;
|
|
3892
|
+
return true;
|
|
3893
|
+
}
|
|
3894
|
+
function _(t2) {
|
|
3895
|
+
if (r(t2))
|
|
3896
|
+
return t2;
|
|
3897
|
+
throw new Error(`Invalid entity name ${t2}`);
|
|
3898
|
+
}
|
|
3899
|
+
const D = /^[-+]?0x[a-fA-F0-9]+$/, V = /^([\-\+])?(0*)([0-9]*(\.[0-9]*)?)$/, k = { hex: true, leadingZeros: true, decimalPoint: ".", eNotation: true, infinity: "original" };
|
|
3900
|
+
const F = /^([-+])?(0*)(\d*(\.\d*)?[eE][-\+]?\d+)$/, L = new Set(["push", "pop", "reset", "updateCurrent", "restore"]);
|
|
3901
|
+
|
|
3902
|
+
class G {
|
|
3903
|
+
constructor(t2 = {}) {
|
|
3904
|
+
this.separator = t2.separator || ".", this.path = [], this.siblingStacks = [];
|
|
3905
|
+
}
|
|
3906
|
+
push(t2, e2 = null, i2 = null) {
|
|
3907
|
+
this.path.length > 0 && (this.path[this.path.length - 1].values = undefined);
|
|
3908
|
+
const n2 = this.path.length;
|
|
3909
|
+
this.siblingStacks[n2] || (this.siblingStacks[n2] = new Map);
|
|
3910
|
+
const s2 = this.siblingStacks[n2], r2 = i2 ? `${i2}:${t2}` : t2, o2 = s2.get(r2) || 0;
|
|
3911
|
+
let a2 = 0;
|
|
3912
|
+
for (const t3 of s2.values())
|
|
3913
|
+
a2 += t3;
|
|
3914
|
+
s2.set(r2, o2 + 1);
|
|
3915
|
+
const h2 = { tag: t2, position: a2, counter: o2 };
|
|
3916
|
+
i2 != null && (h2.namespace = i2), e2 != null && (h2.values = e2), this.path.push(h2);
|
|
3917
|
+
}
|
|
3918
|
+
pop() {
|
|
3919
|
+
if (this.path.length === 0)
|
|
3920
|
+
return;
|
|
3921
|
+
const t2 = this.path.pop();
|
|
3922
|
+
return this.siblingStacks.length > this.path.length + 1 && (this.siblingStacks.length = this.path.length + 1), t2;
|
|
3923
|
+
}
|
|
3924
|
+
updateCurrent(t2) {
|
|
3925
|
+
if (this.path.length > 0) {
|
|
3926
|
+
const e2 = this.path[this.path.length - 1];
|
|
3927
|
+
t2 != null && (e2.values = t2);
|
|
3928
|
+
}
|
|
3929
|
+
}
|
|
3930
|
+
getCurrentTag() {
|
|
3931
|
+
return this.path.length > 0 ? this.path[this.path.length - 1].tag : undefined;
|
|
3932
|
+
}
|
|
3933
|
+
getCurrentNamespace() {
|
|
3934
|
+
return this.path.length > 0 ? this.path[this.path.length - 1].namespace : undefined;
|
|
3935
|
+
}
|
|
3936
|
+
getAttrValue(t2) {
|
|
3937
|
+
if (this.path.length === 0)
|
|
3938
|
+
return;
|
|
3939
|
+
const e2 = this.path[this.path.length - 1];
|
|
3940
|
+
return e2.values?.[t2];
|
|
3941
|
+
}
|
|
3942
|
+
hasAttr(t2) {
|
|
3943
|
+
if (this.path.length === 0)
|
|
3944
|
+
return false;
|
|
3945
|
+
const e2 = this.path[this.path.length - 1];
|
|
3946
|
+
return e2.values !== undefined && t2 in e2.values;
|
|
3947
|
+
}
|
|
3948
|
+
getPosition() {
|
|
3949
|
+
return this.path.length === 0 ? -1 : this.path[this.path.length - 1].position ?? 0;
|
|
3950
|
+
}
|
|
3951
|
+
getCounter() {
|
|
3952
|
+
return this.path.length === 0 ? -1 : this.path[this.path.length - 1].counter ?? 0;
|
|
3953
|
+
}
|
|
3954
|
+
getIndex() {
|
|
3955
|
+
return this.getPosition();
|
|
3956
|
+
}
|
|
3957
|
+
getDepth() {
|
|
3958
|
+
return this.path.length;
|
|
3959
|
+
}
|
|
3960
|
+
toString(t2, e2 = true) {
|
|
3961
|
+
const i2 = t2 || this.separator;
|
|
3962
|
+
return this.path.map((t3) => e2 && t3.namespace ? `${t3.namespace}:${t3.tag}` : t3.tag).join(i2);
|
|
3963
|
+
}
|
|
3964
|
+
toArray() {
|
|
3965
|
+
return this.path.map((t2) => t2.tag);
|
|
3966
|
+
}
|
|
3967
|
+
reset() {
|
|
3968
|
+
this.path = [], this.siblingStacks = [];
|
|
3969
|
+
}
|
|
3970
|
+
matches(t2) {
|
|
3971
|
+
const e2 = t2.segments;
|
|
3972
|
+
return e2.length !== 0 && (t2.hasDeepWildcard() ? this._matchWithDeepWildcard(e2) : this._matchSimple(e2));
|
|
3973
|
+
}
|
|
3974
|
+
_matchSimple(t2) {
|
|
3975
|
+
if (this.path.length !== t2.length)
|
|
3976
|
+
return false;
|
|
3977
|
+
for (let e2 = 0;e2 < t2.length; e2++) {
|
|
3978
|
+
const i2 = t2[e2], n2 = this.path[e2], s2 = e2 === this.path.length - 1;
|
|
3979
|
+
if (!this._matchSegment(i2, n2, s2))
|
|
3980
|
+
return false;
|
|
3981
|
+
}
|
|
3982
|
+
return true;
|
|
3983
|
+
}
|
|
3984
|
+
_matchWithDeepWildcard(t2) {
|
|
3985
|
+
let e2 = this.path.length - 1, i2 = t2.length - 1;
|
|
3986
|
+
for (;i2 >= 0 && e2 >= 0; ) {
|
|
3987
|
+
const n2 = t2[i2];
|
|
3988
|
+
if (n2.type === "deep-wildcard") {
|
|
3989
|
+
if (i2--, i2 < 0)
|
|
3990
|
+
return true;
|
|
3991
|
+
const n3 = t2[i2];
|
|
3992
|
+
let s2 = false;
|
|
3993
|
+
for (let t3 = e2;t3 >= 0; t3--) {
|
|
3994
|
+
const r2 = t3 === this.path.length - 1;
|
|
3995
|
+
if (this._matchSegment(n3, this.path[t3], r2)) {
|
|
3996
|
+
e2 = t3 - 1, i2--, s2 = true;
|
|
3997
|
+
break;
|
|
3998
|
+
}
|
|
3999
|
+
}
|
|
4000
|
+
if (!s2)
|
|
4001
|
+
return false;
|
|
4002
|
+
} else {
|
|
4003
|
+
const t3 = e2 === this.path.length - 1;
|
|
4004
|
+
if (!this._matchSegment(n2, this.path[e2], t3))
|
|
4005
|
+
return false;
|
|
4006
|
+
e2--, i2--;
|
|
4007
|
+
}
|
|
4008
|
+
}
|
|
4009
|
+
return i2 < 0;
|
|
4010
|
+
}
|
|
4011
|
+
_matchSegment(t2, e2, i2) {
|
|
4012
|
+
if (t2.tag !== "*" && t2.tag !== e2.tag)
|
|
4013
|
+
return false;
|
|
4014
|
+
if (t2.namespace !== undefined && t2.namespace !== "*" && t2.namespace !== e2.namespace)
|
|
4015
|
+
return false;
|
|
4016
|
+
if (t2.attrName !== undefined) {
|
|
4017
|
+
if (!i2)
|
|
4018
|
+
return false;
|
|
4019
|
+
if (!e2.values || !(t2.attrName in e2.values))
|
|
4020
|
+
return false;
|
|
4021
|
+
if (t2.attrValue !== undefined) {
|
|
4022
|
+
const i3 = e2.values[t2.attrName];
|
|
4023
|
+
if (String(i3) !== String(t2.attrValue))
|
|
4024
|
+
return false;
|
|
4025
|
+
}
|
|
4026
|
+
}
|
|
4027
|
+
if (t2.position !== undefined) {
|
|
4028
|
+
if (!i2)
|
|
4029
|
+
return false;
|
|
4030
|
+
const n2 = e2.counter ?? 0;
|
|
4031
|
+
if (t2.position === "first" && n2 !== 0)
|
|
4032
|
+
return false;
|
|
4033
|
+
if (t2.position === "odd" && n2 % 2 != 1)
|
|
4034
|
+
return false;
|
|
4035
|
+
if (t2.position === "even" && n2 % 2 != 0)
|
|
4036
|
+
return false;
|
|
4037
|
+
if (t2.position === "nth" && n2 !== t2.positionValue)
|
|
4038
|
+
return false;
|
|
4039
|
+
}
|
|
4040
|
+
return true;
|
|
4041
|
+
}
|
|
4042
|
+
snapshot() {
|
|
4043
|
+
return { path: this.path.map((t2) => ({ ...t2 })), siblingStacks: this.siblingStacks.map((t2) => new Map(t2)) };
|
|
4044
|
+
}
|
|
4045
|
+
restore(t2) {
|
|
4046
|
+
this.path = t2.path.map((t3) => ({ ...t3 })), this.siblingStacks = t2.siblingStacks.map((t3) => new Map(t3));
|
|
4047
|
+
}
|
|
4048
|
+
readOnly() {
|
|
4049
|
+
return new Proxy(this, { get(t2, e2, i2) {
|
|
4050
|
+
if (L.has(e2))
|
|
4051
|
+
return () => {
|
|
4052
|
+
throw new TypeError(`Cannot call '${e2}' on a read-only Matcher. Obtain a writable instance to mutate state.`);
|
|
4053
|
+
};
|
|
4054
|
+
const n2 = Reflect.get(t2, e2, i2);
|
|
4055
|
+
return e2 === "path" || e2 === "siblingStacks" ? Object.freeze(Array.isArray(n2) ? n2.map((t3) => t3 instanceof Map ? Object.freeze(new Map(t3)) : Object.freeze({ ...t3 })) : n2) : typeof n2 == "function" ? n2.bind(t2) : n2;
|
|
4056
|
+
}, set(t2, e2) {
|
|
4057
|
+
throw new TypeError(`Cannot set property '${String(e2)}' on a read-only Matcher.`);
|
|
4058
|
+
}, deleteProperty(t2, e2) {
|
|
4059
|
+
throw new TypeError(`Cannot delete property '${String(e2)}' from a read-only Matcher.`);
|
|
4060
|
+
} });
|
|
4061
|
+
}
|
|
4062
|
+
}
|
|
4063
|
+
|
|
4064
|
+
class R {
|
|
4065
|
+
constructor(t2, e2 = {}) {
|
|
4066
|
+
this.pattern = t2, this.separator = e2.separator || ".", this.segments = this._parse(t2), this._hasDeepWildcard = this.segments.some((t3) => t3.type === "deep-wildcard"), this._hasAttributeCondition = this.segments.some((t3) => t3.attrName !== undefined), this._hasPositionSelector = this.segments.some((t3) => t3.position !== undefined);
|
|
4067
|
+
}
|
|
4068
|
+
_parse(t2) {
|
|
4069
|
+
const e2 = [];
|
|
4070
|
+
let i2 = 0, n2 = "";
|
|
4071
|
+
for (;i2 < t2.length; )
|
|
4072
|
+
t2[i2] === this.separator ? i2 + 1 < t2.length && t2[i2 + 1] === this.separator ? (n2.trim() && (e2.push(this._parseSegment(n2.trim())), n2 = ""), e2.push({ type: "deep-wildcard" }), i2 += 2) : (n2.trim() && e2.push(this._parseSegment(n2.trim())), n2 = "", i2++) : (n2 += t2[i2], i2++);
|
|
4073
|
+
return n2.trim() && e2.push(this._parseSegment(n2.trim())), e2;
|
|
4074
|
+
}
|
|
4075
|
+
_parseSegment(t2) {
|
|
4076
|
+
const e2 = { type: "tag" };
|
|
4077
|
+
let i2 = null, n2 = t2;
|
|
4078
|
+
const s2 = t2.match(/^([^\[]+)(\[[^\]]*\])(.*)$/);
|
|
4079
|
+
if (s2 && (n2 = s2[1] + s2[3], s2[2])) {
|
|
4080
|
+
const t3 = s2[2].slice(1, -1);
|
|
4081
|
+
t3 && (i2 = t3);
|
|
4082
|
+
}
|
|
4083
|
+
let r2, o2, a2 = n2;
|
|
4084
|
+
if (n2.includes("::")) {
|
|
4085
|
+
const e3 = n2.indexOf("::");
|
|
4086
|
+
if (r2 = n2.substring(0, e3).trim(), a2 = n2.substring(e3 + 2).trim(), !r2)
|
|
4087
|
+
throw new Error(`Invalid namespace in pattern: ${t2}`);
|
|
4088
|
+
}
|
|
4089
|
+
let h2 = null;
|
|
4090
|
+
if (a2.includes(":")) {
|
|
4091
|
+
const t3 = a2.lastIndexOf(":"), e3 = a2.substring(0, t3).trim(), i3 = a2.substring(t3 + 1).trim();
|
|
4092
|
+
["first", "last", "odd", "even"].includes(i3) || /^nth\(\d+\)$/.test(i3) ? (o2 = e3, h2 = i3) : o2 = a2;
|
|
4093
|
+
} else
|
|
4094
|
+
o2 = a2;
|
|
4095
|
+
if (!o2)
|
|
4096
|
+
throw new Error(`Invalid segment pattern: ${t2}`);
|
|
4097
|
+
if (e2.tag = o2, r2 && (e2.namespace = r2), i2)
|
|
4098
|
+
if (i2.includes("=")) {
|
|
4099
|
+
const t3 = i2.indexOf("=");
|
|
4100
|
+
e2.attrName = i2.substring(0, t3).trim(), e2.attrValue = i2.substring(t3 + 1).trim();
|
|
4101
|
+
} else
|
|
4102
|
+
e2.attrName = i2.trim();
|
|
4103
|
+
if (h2) {
|
|
4104
|
+
const t3 = h2.match(/^nth\((\d+)\)$/);
|
|
4105
|
+
t3 ? (e2.position = "nth", e2.positionValue = parseInt(t3[1], 10)) : e2.position = h2;
|
|
4106
|
+
}
|
|
4107
|
+
return e2;
|
|
4108
|
+
}
|
|
4109
|
+
get length() {
|
|
4110
|
+
return this.segments.length;
|
|
4111
|
+
}
|
|
4112
|
+
hasDeepWildcard() {
|
|
4113
|
+
return this._hasDeepWildcard;
|
|
4114
|
+
}
|
|
4115
|
+
hasAttributeCondition() {
|
|
4116
|
+
return this._hasAttributeCondition;
|
|
4117
|
+
}
|
|
4118
|
+
hasPositionSelector() {
|
|
4119
|
+
return this._hasPositionSelector;
|
|
4120
|
+
}
|
|
4121
|
+
toString() {
|
|
4122
|
+
return this.pattern;
|
|
4123
|
+
}
|
|
4124
|
+
}
|
|
4125
|
+
function U(t2, e2) {
|
|
4126
|
+
if (!t2)
|
|
4127
|
+
return {};
|
|
4128
|
+
const i2 = e2.attributesGroupName ? t2[e2.attributesGroupName] : t2;
|
|
4129
|
+
if (!i2)
|
|
4130
|
+
return {};
|
|
4131
|
+
const n2 = {};
|
|
4132
|
+
for (const t3 in i2)
|
|
4133
|
+
t3.startsWith(e2.attributeNamePrefix) ? n2[t3.substring(e2.attributeNamePrefix.length)] = i2[t3] : n2[t3] = i2[t3];
|
|
4134
|
+
return n2;
|
|
4135
|
+
}
|
|
4136
|
+
function B(t2) {
|
|
4137
|
+
if (!t2 || typeof t2 != "string")
|
|
4138
|
+
return;
|
|
4139
|
+
const e2 = t2.indexOf(":");
|
|
4140
|
+
if (e2 !== -1 && e2 > 0) {
|
|
4141
|
+
const i2 = t2.substring(0, e2);
|
|
4142
|
+
if (i2 !== "xmlns")
|
|
4143
|
+
return i2;
|
|
4144
|
+
}
|
|
4145
|
+
}
|
|
4146
|
+
|
|
4147
|
+
class W {
|
|
4148
|
+
constructor(t2) {
|
|
4149
|
+
var e2;
|
|
4150
|
+
if (this.options = t2, this.currentNode = null, this.tagsNodeStack = [], this.docTypeEntities = {}, this.lastEntities = { apos: { regex: /&(apos|#39|#x27);/g, val: "'" }, gt: { regex: /&(gt|#62|#x3E);/g, val: ">" }, lt: { regex: /&(lt|#60|#x3C);/g, val: "<" }, quot: { regex: /&(quot|#34|#x22);/g, val: '"' } }, this.ampEntity = { regex: /&(amp|#38|#x26);/g, val: "&" }, this.htmlEntities = { space: { regex: /&(nbsp|#160);/g, val: " " }, cent: { regex: /&(cent|#162);/g, val: "\xA2" }, pound: { regex: /&(pound|#163);/g, val: "\xA3" }, yen: { regex: /&(yen|#165);/g, val: "\xA5" }, euro: { regex: /&(euro|#8364);/g, val: "\u20AC" }, copyright: { regex: /&(copy|#169);/g, val: "\xA9" }, reg: { regex: /&(reg|#174);/g, val: "\xAE" }, inr: { regex: /&(inr|#8377);/g, val: "\u20B9" }, num_dec: { regex: /&#([0-9]{1,7});/g, val: (t3, e3) => rt(e3, 10, "&#") }, num_hex: { regex: /&#x([0-9a-fA-F]{1,6});/g, val: (t3, e3) => rt(e3, 16, "&#x") } }, this.addExternalEntities = Y, this.parseXml = J, this.parseTextData = z, this.resolveNameSpace = X, this.buildAttributesMap = Z, this.isItStopNode = tt, this.replaceEntitiesValue = Q, this.readStopNodeData = nt, this.saveTextToParentTag = H, this.addChild = K, this.ignoreAttributesFn = typeof (e2 = this.options.ignoreAttributes) == "function" ? e2 : Array.isArray(e2) ? (t3) => {
|
|
4151
|
+
for (const i2 of e2) {
|
|
4152
|
+
if (typeof i2 == "string" && t3 === i2)
|
|
4153
|
+
return true;
|
|
4154
|
+
if (i2 instanceof RegExp && i2.test(t3))
|
|
4155
|
+
return true;
|
|
4156
|
+
}
|
|
4157
|
+
} : () => false, this.entityExpansionCount = 0, this.currentExpandedLength = 0, this.matcher = new G, this.readonlyMatcher = this.matcher.readOnly(), this.isCurrentNodeStopNode = false, this.options.stopNodes && this.options.stopNodes.length > 0) {
|
|
4158
|
+
this.stopNodeExpressions = [];
|
|
4159
|
+
for (let t3 = 0;t3 < this.options.stopNodes.length; t3++) {
|
|
4160
|
+
const e3 = this.options.stopNodes[t3];
|
|
4161
|
+
typeof e3 == "string" ? this.stopNodeExpressions.push(new R(e3)) : e3 instanceof R && this.stopNodeExpressions.push(e3);
|
|
4162
|
+
}
|
|
4163
|
+
}
|
|
4164
|
+
}
|
|
4165
|
+
}
|
|
4166
|
+
function Y(t2) {
|
|
4167
|
+
const e2 = Object.keys(t2);
|
|
4168
|
+
for (let i2 = 0;i2 < e2.length; i2++) {
|
|
4169
|
+
const n2 = e2[i2], s2 = n2.replace(/[.\-+*:]/g, "\\.");
|
|
4170
|
+
this.lastEntities[n2] = { regex: new RegExp("&" + s2 + ";", "g"), val: t2[n2] };
|
|
4171
|
+
}
|
|
4172
|
+
}
|
|
4173
|
+
function z(t2, e2, i2, n2, s2, r2, o2) {
|
|
4174
|
+
if (t2 !== undefined && (this.options.trimValues && !n2 && (t2 = t2.trim()), t2.length > 0)) {
|
|
4175
|
+
o2 || (t2 = this.replaceEntitiesValue(t2, e2, i2));
|
|
4176
|
+
const n3 = this.options.jPath ? i2.toString() : i2, a2 = this.options.tagValueProcessor(e2, t2, n3, s2, r2);
|
|
4177
|
+
return a2 == null ? t2 : typeof a2 != typeof t2 || a2 !== t2 ? a2 : this.options.trimValues || t2.trim() === t2 ? st(t2, this.options.parseTagValue, this.options.numberParseOptions) : t2;
|
|
4178
|
+
}
|
|
4179
|
+
}
|
|
4180
|
+
function X(t2) {
|
|
4181
|
+
if (this.options.removeNSPrefix) {
|
|
4182
|
+
const e2 = t2.split(":"), i2 = t2.charAt(0) === "/" ? "/" : "";
|
|
4183
|
+
if (e2[0] === "xmlns")
|
|
4184
|
+
return "";
|
|
4185
|
+
e2.length === 2 && (t2 = i2 + e2[1]);
|
|
4186
|
+
}
|
|
4187
|
+
return t2;
|
|
4188
|
+
}
|
|
4189
|
+
const q = new RegExp(`([^\\s=]+)\\s*(=\\s*(['"])([\\s\\S]*?)\\3)?`, "gm");
|
|
4190
|
+
function Z(t2, e2, i2) {
|
|
4191
|
+
if (this.options.ignoreAttributes !== true && typeof t2 == "string") {
|
|
4192
|
+
const n2 = s(t2, q), r2 = n2.length, o2 = {}, a2 = {};
|
|
4193
|
+
for (let t3 = 0;t3 < r2; t3++) {
|
|
4194
|
+
const e3 = this.resolveNameSpace(n2[t3][1]), s2 = n2[t3][4];
|
|
4195
|
+
if (e3.length && s2 !== undefined) {
|
|
4196
|
+
let t4 = s2;
|
|
4197
|
+
this.options.trimValues && (t4 = t4.trim()), t4 = this.replaceEntitiesValue(t4, i2, this.readonlyMatcher), a2[e3] = t4;
|
|
4198
|
+
}
|
|
4199
|
+
}
|
|
4200
|
+
Object.keys(a2).length > 0 && typeof e2 == "object" && e2.updateCurrent && e2.updateCurrent(a2);
|
|
4201
|
+
for (let t3 = 0;t3 < r2; t3++) {
|
|
4202
|
+
const s2 = this.resolveNameSpace(n2[t3][1]), r3 = this.options.jPath ? e2.toString() : this.readonlyMatcher;
|
|
4203
|
+
if (this.ignoreAttributesFn(s2, r3))
|
|
4204
|
+
continue;
|
|
4205
|
+
let a3 = n2[t3][4], h2 = this.options.attributeNamePrefix + s2;
|
|
4206
|
+
if (s2.length)
|
|
4207
|
+
if (this.options.transformAttributeName && (h2 = this.options.transformAttributeName(h2)), h2 = at(h2, this.options), a3 !== undefined) {
|
|
4208
|
+
this.options.trimValues && (a3 = a3.trim()), a3 = this.replaceEntitiesValue(a3, i2, this.readonlyMatcher);
|
|
4209
|
+
const t4 = this.options.jPath ? e2.toString() : this.readonlyMatcher, n3 = this.options.attributeValueProcessor(s2, a3, t4);
|
|
4210
|
+
o2[h2] = n3 == null ? a3 : typeof n3 != typeof a3 || n3 !== a3 ? n3 : st(a3, this.options.parseAttributeValue, this.options.numberParseOptions);
|
|
4211
|
+
} else
|
|
4212
|
+
this.options.allowBooleanAttributes && (o2[h2] = true);
|
|
4213
|
+
}
|
|
4214
|
+
if (!Object.keys(o2).length)
|
|
4215
|
+
return;
|
|
4216
|
+
if (this.options.attributesGroupName) {
|
|
4217
|
+
const t3 = {};
|
|
4218
|
+
return t3[this.options.attributesGroupName] = o2, t3;
|
|
4219
|
+
}
|
|
4220
|
+
return o2;
|
|
4221
|
+
}
|
|
4222
|
+
}
|
|
4223
|
+
const J = function(t2) {
|
|
4224
|
+
t2 = t2.replace(/\r\n?/g, `
|
|
4225
|
+
`);
|
|
4226
|
+
const e2 = new $("!xml");
|
|
4227
|
+
let i2 = e2, n2 = "";
|
|
4228
|
+
this.matcher.reset(), this.entityExpansionCount = 0, this.currentExpandedLength = 0;
|
|
4229
|
+
const s2 = new I(this.options.processEntities);
|
|
4230
|
+
for (let r2 = 0;r2 < t2.length; r2++)
|
|
4231
|
+
if (t2[r2] === "<")
|
|
4232
|
+
if (t2[r2 + 1] === "/") {
|
|
4233
|
+
const e3 = et(t2, ">", r2, "Closing Tag is not closed.");
|
|
4234
|
+
let s3 = t2.substring(r2 + 2, e3).trim();
|
|
4235
|
+
if (this.options.removeNSPrefix) {
|
|
4236
|
+
const t3 = s3.indexOf(":");
|
|
4237
|
+
t3 !== -1 && (s3 = s3.substr(t3 + 1));
|
|
4238
|
+
}
|
|
4239
|
+
s3 = ot(this.options.transformTagName, s3, "", this.options).tagName, i2 && (n2 = this.saveTextToParentTag(n2, i2, this.readonlyMatcher));
|
|
4240
|
+
const o2 = this.matcher.getCurrentTag();
|
|
4241
|
+
if (s3 && this.options.unpairedTags.indexOf(s3) !== -1)
|
|
4242
|
+
throw new Error(`Unpaired tag can not be used as closing tag: </${s3}>`);
|
|
4243
|
+
o2 && this.options.unpairedTags.indexOf(o2) !== -1 && (this.matcher.pop(), this.tagsNodeStack.pop()), this.matcher.pop(), this.isCurrentNodeStopNode = false, i2 = this.tagsNodeStack.pop(), n2 = "", r2 = e3;
|
|
4244
|
+
} else if (t2[r2 + 1] === "?") {
|
|
4245
|
+
let e3 = it(t2, r2, false, "?>");
|
|
4246
|
+
if (!e3)
|
|
4247
|
+
throw new Error("Pi Tag is not closed.");
|
|
4248
|
+
if (n2 = this.saveTextToParentTag(n2, i2, this.readonlyMatcher), this.options.ignoreDeclaration && e3.tagName === "?xml" || this.options.ignorePiTags)
|
|
4249
|
+
;
|
|
4250
|
+
else {
|
|
4251
|
+
const t3 = new $(e3.tagName);
|
|
4252
|
+
t3.add(this.options.textNodeName, ""), e3.tagName !== e3.tagExp && e3.attrExpPresent && (t3[":@"] = this.buildAttributesMap(e3.tagExp, this.matcher, e3.tagName)), this.addChild(i2, t3, this.readonlyMatcher, r2);
|
|
4253
|
+
}
|
|
4254
|
+
r2 = e3.closeIndex + 1;
|
|
4255
|
+
} else if (t2.substr(r2 + 1, 3) === "!--") {
|
|
4256
|
+
const e3 = et(t2, "-->", r2 + 4, "Comment is not closed.");
|
|
4257
|
+
if (this.options.commentPropName) {
|
|
4258
|
+
const s3 = t2.substring(r2 + 4, e3 - 2);
|
|
4259
|
+
n2 = this.saveTextToParentTag(n2, i2, this.readonlyMatcher), i2.add(this.options.commentPropName, [{ [this.options.textNodeName]: s3 }]);
|
|
4260
|
+
}
|
|
4261
|
+
r2 = e3;
|
|
4262
|
+
} else if (t2.substr(r2 + 1, 2) === "!D") {
|
|
4263
|
+
const e3 = s2.readDocType(t2, r2);
|
|
4264
|
+
this.docTypeEntities = e3.entities, r2 = e3.i;
|
|
4265
|
+
} else if (t2.substr(r2 + 1, 2) === "![") {
|
|
4266
|
+
const e3 = et(t2, "]]>", r2, "CDATA is not closed.") - 2, s3 = t2.substring(r2 + 9, e3);
|
|
4267
|
+
n2 = this.saveTextToParentTag(n2, i2, this.readonlyMatcher);
|
|
4268
|
+
let o2 = this.parseTextData(s3, i2.tagname, this.readonlyMatcher, true, false, true, true);
|
|
4269
|
+
o2 == null && (o2 = ""), this.options.cdataPropName ? i2.add(this.options.cdataPropName, [{ [this.options.textNodeName]: s3 }]) : i2.add(this.options.textNodeName, o2), r2 = e3 + 2;
|
|
4270
|
+
} else {
|
|
4271
|
+
let s3 = it(t2, r2, this.options.removeNSPrefix);
|
|
4272
|
+
if (!s3) {
|
|
4273
|
+
const e3 = t2.substring(Math.max(0, r2 - 50), Math.min(t2.length, r2 + 50));
|
|
4274
|
+
throw new Error(`readTagExp returned undefined at position ${r2}. Context: "${e3}"`);
|
|
4275
|
+
}
|
|
4276
|
+
let o2 = s3.tagName;
|
|
4277
|
+
const a2 = s3.rawTagName;
|
|
4278
|
+
let { tagExp: h2, attrExpPresent: l2, closeIndex: p2 } = s3;
|
|
4279
|
+
if ({ tagName: o2, tagExp: h2 } = ot(this.options.transformTagName, o2, h2, this.options), this.options.strictReservedNames && (o2 === this.options.commentPropName || o2 === this.options.cdataPropName || o2 === this.options.textNodeName || o2 === this.options.attributesGroupName))
|
|
4280
|
+
throw new Error(`Invalid tag name: ${o2}`);
|
|
4281
|
+
i2 && n2 && i2.tagname !== "!xml" && (n2 = this.saveTextToParentTag(n2, i2, this.readonlyMatcher, false));
|
|
4282
|
+
const u2 = i2;
|
|
4283
|
+
u2 && this.options.unpairedTags.indexOf(u2.tagname) !== -1 && (i2 = this.tagsNodeStack.pop(), this.matcher.pop());
|
|
4284
|
+
let c2 = false;
|
|
4285
|
+
h2.length > 0 && h2.lastIndexOf("/") === h2.length - 1 && (c2 = true, o2[o2.length - 1] === "/" ? (o2 = o2.substr(0, o2.length - 1), h2 = o2) : h2 = h2.substr(0, h2.length - 1), l2 = o2 !== h2);
|
|
4286
|
+
let d2, f2 = null, g2 = {};
|
|
4287
|
+
d2 = B(a2), o2 !== e2.tagname && this.matcher.push(o2, {}, d2), o2 !== h2 && l2 && (f2 = this.buildAttributesMap(h2, this.matcher, o2), f2 && (g2 = U(f2, this.options))), o2 !== e2.tagname && (this.isCurrentNodeStopNode = this.isItStopNode(this.stopNodeExpressions, this.matcher));
|
|
4288
|
+
const m2 = r2;
|
|
4289
|
+
if (this.isCurrentNodeStopNode) {
|
|
4290
|
+
let e3 = "";
|
|
4291
|
+
if (c2)
|
|
4292
|
+
r2 = s3.closeIndex;
|
|
4293
|
+
else if (this.options.unpairedTags.indexOf(o2) !== -1)
|
|
4294
|
+
r2 = s3.closeIndex;
|
|
4295
|
+
else {
|
|
4296
|
+
const i3 = this.readStopNodeData(t2, a2, p2 + 1);
|
|
4297
|
+
if (!i3)
|
|
4298
|
+
throw new Error(`Unexpected end of ${a2}`);
|
|
4299
|
+
r2 = i3.i, e3 = i3.tagContent;
|
|
4300
|
+
}
|
|
4301
|
+
const n3 = new $(o2);
|
|
4302
|
+
f2 && (n3[":@"] = f2), n3.add(this.options.textNodeName, e3), this.matcher.pop(), this.isCurrentNodeStopNode = false, this.addChild(i2, n3, this.readonlyMatcher, m2);
|
|
4303
|
+
} else {
|
|
4304
|
+
if (c2) {
|
|
4305
|
+
({ tagName: o2, tagExp: h2 } = ot(this.options.transformTagName, o2, h2, this.options));
|
|
4306
|
+
const t3 = new $(o2);
|
|
4307
|
+
f2 && (t3[":@"] = f2), this.addChild(i2, t3, this.readonlyMatcher, m2), this.matcher.pop(), this.isCurrentNodeStopNode = false;
|
|
4308
|
+
} else {
|
|
4309
|
+
if (this.options.unpairedTags.indexOf(o2) !== -1) {
|
|
4310
|
+
const t3 = new $(o2);
|
|
4311
|
+
f2 && (t3[":@"] = f2), this.addChild(i2, t3, this.readonlyMatcher, m2), this.matcher.pop(), this.isCurrentNodeStopNode = false, r2 = s3.closeIndex;
|
|
4312
|
+
continue;
|
|
4313
|
+
}
|
|
4314
|
+
{
|
|
4315
|
+
const t3 = new $(o2);
|
|
4316
|
+
if (this.tagsNodeStack.length > this.options.maxNestedTags)
|
|
4317
|
+
throw new Error("Maximum nested tags exceeded");
|
|
4318
|
+
this.tagsNodeStack.push(i2), f2 && (t3[":@"] = f2), this.addChild(i2, t3, this.readonlyMatcher, m2), i2 = t3;
|
|
4319
|
+
}
|
|
4320
|
+
}
|
|
4321
|
+
n2 = "", r2 = p2;
|
|
4322
|
+
}
|
|
4323
|
+
}
|
|
4324
|
+
else
|
|
4325
|
+
n2 += t2[r2];
|
|
4326
|
+
return e2.child;
|
|
4327
|
+
};
|
|
4328
|
+
function K(t2, e2, i2, n2) {
|
|
4329
|
+
this.options.captureMetaData || (n2 = undefined);
|
|
4330
|
+
const s2 = this.options.jPath ? i2.toString() : i2, r2 = this.options.updateTag(e2.tagname, s2, e2[":@"]);
|
|
4331
|
+
r2 === false || (typeof r2 == "string" ? (e2.tagname = r2, t2.addChild(e2, n2)) : t2.addChild(e2, n2));
|
|
4332
|
+
}
|
|
4333
|
+
function Q(t2, e2, i2) {
|
|
4334
|
+
const n2 = this.options.processEntities;
|
|
4335
|
+
if (!n2 || !n2.enabled)
|
|
4336
|
+
return t2;
|
|
4337
|
+
if (n2.allowedTags) {
|
|
4338
|
+
const s2 = this.options.jPath ? i2.toString() : i2;
|
|
4339
|
+
if (!(Array.isArray(n2.allowedTags) ? n2.allowedTags.includes(e2) : n2.allowedTags(e2, s2)))
|
|
4340
|
+
return t2;
|
|
4341
|
+
}
|
|
4342
|
+
if (n2.tagFilter) {
|
|
4343
|
+
const s2 = this.options.jPath ? i2.toString() : i2;
|
|
4344
|
+
if (!n2.tagFilter(e2, s2))
|
|
4345
|
+
return t2;
|
|
4346
|
+
}
|
|
4347
|
+
for (const e3 of Object.keys(this.docTypeEntities)) {
|
|
4348
|
+
const i3 = this.docTypeEntities[e3], s2 = t2.match(i3.regx);
|
|
4349
|
+
if (s2) {
|
|
4350
|
+
if (this.entityExpansionCount += s2.length, n2.maxTotalExpansions && this.entityExpansionCount > n2.maxTotalExpansions)
|
|
4351
|
+
throw new Error(`Entity expansion limit exceeded: ${this.entityExpansionCount} > ${n2.maxTotalExpansions}`);
|
|
4352
|
+
const e4 = t2.length;
|
|
4353
|
+
if (t2 = t2.replace(i3.regx, i3.val), n2.maxExpandedLength && (this.currentExpandedLength += t2.length - e4, this.currentExpandedLength > n2.maxExpandedLength))
|
|
4354
|
+
throw new Error(`Total expanded content size exceeded: ${this.currentExpandedLength} > ${n2.maxExpandedLength}`);
|
|
4355
|
+
}
|
|
4356
|
+
}
|
|
4357
|
+
for (const e3 of Object.keys(this.lastEntities)) {
|
|
4358
|
+
const i3 = this.lastEntities[e3], s2 = t2.match(i3.regex);
|
|
4359
|
+
if (s2 && (this.entityExpansionCount += s2.length, n2.maxTotalExpansions && this.entityExpansionCount > n2.maxTotalExpansions))
|
|
4360
|
+
throw new Error(`Entity expansion limit exceeded: ${this.entityExpansionCount} > ${n2.maxTotalExpansions}`);
|
|
4361
|
+
t2 = t2.replace(i3.regex, i3.val);
|
|
4362
|
+
}
|
|
4363
|
+
if (t2.indexOf("&") === -1)
|
|
4364
|
+
return t2;
|
|
4365
|
+
if (this.options.htmlEntities)
|
|
4366
|
+
for (const e3 of Object.keys(this.htmlEntities)) {
|
|
4367
|
+
const i3 = this.htmlEntities[e3], s2 = t2.match(i3.regex);
|
|
4368
|
+
if (s2 && (this.entityExpansionCount += s2.length, n2.maxTotalExpansions && this.entityExpansionCount > n2.maxTotalExpansions))
|
|
4369
|
+
throw new Error(`Entity expansion limit exceeded: ${this.entityExpansionCount} > ${n2.maxTotalExpansions}`);
|
|
4370
|
+
t2 = t2.replace(i3.regex, i3.val);
|
|
4371
|
+
}
|
|
4372
|
+
return t2.replace(this.ampEntity.regex, this.ampEntity.val);
|
|
4373
|
+
}
|
|
4374
|
+
function H(t2, e2, i2, n2) {
|
|
4375
|
+
return t2 && (n2 === undefined && (n2 = e2.child.length === 0), (t2 = this.parseTextData(t2, e2.tagname, i2, false, !!e2[":@"] && Object.keys(e2[":@"]).length !== 0, n2)) !== undefined && t2 !== "" && e2.add(this.options.textNodeName, t2), t2 = ""), t2;
|
|
4376
|
+
}
|
|
4377
|
+
function tt(t2, e2) {
|
|
4378
|
+
if (!t2 || t2.length === 0)
|
|
4379
|
+
return false;
|
|
4380
|
+
for (let i2 = 0;i2 < t2.length; i2++)
|
|
4381
|
+
if (e2.matches(t2[i2]))
|
|
4382
|
+
return true;
|
|
4383
|
+
return false;
|
|
4384
|
+
}
|
|
4385
|
+
function et(t2, e2, i2, n2) {
|
|
4386
|
+
const s2 = t2.indexOf(e2, i2);
|
|
4387
|
+
if (s2 === -1)
|
|
4388
|
+
throw new Error(n2);
|
|
4389
|
+
return s2 + e2.length - 1;
|
|
4390
|
+
}
|
|
4391
|
+
function it(t2, e2, i2, n2 = ">") {
|
|
4392
|
+
const s2 = function(t3, e3, i3 = ">") {
|
|
4393
|
+
let n3, s3 = "";
|
|
4394
|
+
for (let r3 = e3;r3 < t3.length; r3++) {
|
|
4395
|
+
let e4 = t3[r3];
|
|
4396
|
+
if (n3)
|
|
4397
|
+
e4 === n3 && (n3 = "");
|
|
4398
|
+
else if (e4 === '"' || e4 === "'")
|
|
4399
|
+
n3 = e4;
|
|
4400
|
+
else if (e4 === i3[0]) {
|
|
4401
|
+
if (!i3[1])
|
|
4402
|
+
return { data: s3, index: r3 };
|
|
4403
|
+
if (t3[r3 + 1] === i3[1])
|
|
4404
|
+
return { data: s3, index: r3 };
|
|
4405
|
+
} else
|
|
4406
|
+
e4 === "\t" && (e4 = " ");
|
|
4407
|
+
s3 += e4;
|
|
4408
|
+
}
|
|
4409
|
+
}(t2, e2 + 1, n2);
|
|
4410
|
+
if (!s2)
|
|
4411
|
+
return;
|
|
4412
|
+
let r2 = s2.data;
|
|
4413
|
+
const o2 = s2.index, a2 = r2.search(/\s/);
|
|
4414
|
+
let h2 = r2, l2 = true;
|
|
4415
|
+
a2 !== -1 && (h2 = r2.substring(0, a2), r2 = r2.substring(a2 + 1).trimStart());
|
|
4416
|
+
const p2 = h2;
|
|
4417
|
+
if (i2) {
|
|
4418
|
+
const t3 = h2.indexOf(":");
|
|
4419
|
+
t3 !== -1 && (h2 = h2.substr(t3 + 1), l2 = h2 !== s2.data.substr(t3 + 1));
|
|
4420
|
+
}
|
|
4421
|
+
return { tagName: h2, tagExp: r2, closeIndex: o2, attrExpPresent: l2, rawTagName: p2 };
|
|
4422
|
+
}
|
|
4423
|
+
function nt(t2, e2, i2) {
|
|
4424
|
+
const n2 = i2;
|
|
4425
|
+
let s2 = 1;
|
|
4426
|
+
for (;i2 < t2.length; i2++)
|
|
4427
|
+
if (t2[i2] === "<")
|
|
4428
|
+
if (t2[i2 + 1] === "/") {
|
|
4429
|
+
const r2 = et(t2, ">", i2, `${e2} is not closed`);
|
|
4430
|
+
if (t2.substring(i2 + 2, r2).trim() === e2 && (s2--, s2 === 0))
|
|
4431
|
+
return { tagContent: t2.substring(n2, i2), i: r2 };
|
|
4432
|
+
i2 = r2;
|
|
4433
|
+
} else if (t2[i2 + 1] === "?")
|
|
4434
|
+
i2 = et(t2, "?>", i2 + 1, "StopNode is not closed.");
|
|
4435
|
+
else if (t2.substr(i2 + 1, 3) === "!--")
|
|
4436
|
+
i2 = et(t2, "-->", i2 + 3, "StopNode is not closed.");
|
|
4437
|
+
else if (t2.substr(i2 + 1, 2) === "![")
|
|
4438
|
+
i2 = et(t2, "]]>", i2, "StopNode is not closed.") - 2;
|
|
4439
|
+
else {
|
|
4440
|
+
const n3 = it(t2, i2, ">");
|
|
4441
|
+
n3 && ((n3 && n3.tagName) === e2 && n3.tagExp[n3.tagExp.length - 1] !== "/" && s2++, i2 = n3.closeIndex);
|
|
4442
|
+
}
|
|
4443
|
+
}
|
|
4444
|
+
function st(t2, e2, i2) {
|
|
4445
|
+
if (e2 && typeof t2 == "string") {
|
|
4446
|
+
const e3 = t2.trim();
|
|
4447
|
+
return e3 === "true" || e3 !== "false" && function(t3, e4 = {}) {
|
|
4448
|
+
if (e4 = Object.assign({}, k, e4), !t3 || typeof t3 != "string")
|
|
4449
|
+
return t3;
|
|
4450
|
+
let i3 = t3.trim();
|
|
4451
|
+
if (e4.skipLike !== undefined && e4.skipLike.test(i3))
|
|
4452
|
+
return t3;
|
|
4453
|
+
if (t3 === "0")
|
|
4454
|
+
return 0;
|
|
4455
|
+
if (e4.hex && D.test(i3))
|
|
4456
|
+
return function(t4) {
|
|
4457
|
+
if (parseInt)
|
|
4458
|
+
return parseInt(t4, 16);
|
|
4459
|
+
if (Number.parseInt)
|
|
4460
|
+
return Number.parseInt(t4, 16);
|
|
4461
|
+
if (window && window.parseInt)
|
|
4462
|
+
return window.parseInt(t4, 16);
|
|
4463
|
+
throw new Error("parseInt, Number.parseInt, window.parseInt are not supported");
|
|
4464
|
+
}(i3);
|
|
4465
|
+
if (isFinite(i3)) {
|
|
4466
|
+
if (i3.includes("e") || i3.includes("E"))
|
|
4467
|
+
return function(t4, e5, i4) {
|
|
4468
|
+
if (!i4.eNotation)
|
|
4469
|
+
return t4;
|
|
4470
|
+
const n3 = e5.match(F);
|
|
4471
|
+
if (n3) {
|
|
4472
|
+
let s2 = n3[1] || "";
|
|
4473
|
+
const r2 = n3[3].indexOf("e") === -1 ? "E" : "e", o2 = n3[2], a2 = s2 ? t4[o2.length + 1] === r2 : t4[o2.length] === r2;
|
|
4474
|
+
return o2.length > 1 && a2 ? t4 : (o2.length !== 1 || !n3[3].startsWith(`.${r2}`) && n3[3][0] !== r2) && o2.length > 0 ? i4.leadingZeros && !a2 ? (e5 = (n3[1] || "") + n3[3], Number(e5)) : t4 : Number(e5);
|
|
4475
|
+
}
|
|
4476
|
+
return t4;
|
|
4477
|
+
}(t3, i3, e4);
|
|
4478
|
+
{
|
|
4479
|
+
const s2 = V.exec(i3);
|
|
4480
|
+
if (s2) {
|
|
4481
|
+
const r2 = s2[1] || "", o2 = s2[2];
|
|
4482
|
+
let a2 = (n2 = s2[3]) && n2.indexOf(".") !== -1 ? ((n2 = n2.replace(/0+$/, "")) === "." ? n2 = "0" : n2[0] === "." ? n2 = "0" + n2 : n2[n2.length - 1] === "." && (n2 = n2.substring(0, n2.length - 1)), n2) : n2;
|
|
4483
|
+
const h2 = r2 ? t3[o2.length + 1] === "." : t3[o2.length] === ".";
|
|
4484
|
+
if (!e4.leadingZeros && (o2.length > 1 || o2.length === 1 && !h2))
|
|
4485
|
+
return t3;
|
|
4486
|
+
{
|
|
4487
|
+
const n3 = Number(i3), s3 = String(n3);
|
|
4488
|
+
if (n3 === 0)
|
|
4489
|
+
return n3;
|
|
4490
|
+
if (s3.search(/[eE]/) !== -1)
|
|
4491
|
+
return e4.eNotation ? n3 : t3;
|
|
4492
|
+
if (i3.indexOf(".") !== -1)
|
|
4493
|
+
return s3 === "0" || s3 === a2 || s3 === `${r2}${a2}` ? n3 : t3;
|
|
4494
|
+
let h3 = o2 ? a2 : i3;
|
|
4495
|
+
return o2 ? h3 === s3 || r2 + h3 === s3 ? n3 : t3 : h3 === s3 || h3 === r2 + s3 ? n3 : t3;
|
|
4496
|
+
}
|
|
4497
|
+
}
|
|
4498
|
+
return t3;
|
|
4499
|
+
}
|
|
4500
|
+
}
|
|
4501
|
+
var n2;
|
|
4502
|
+
return function(t4, e5, i4) {
|
|
4503
|
+
const n3 = e5 === 1 / 0;
|
|
4504
|
+
switch (i4.infinity.toLowerCase()) {
|
|
4505
|
+
case "null":
|
|
4506
|
+
return null;
|
|
4507
|
+
case "infinity":
|
|
4508
|
+
return e5;
|
|
4509
|
+
case "string":
|
|
4510
|
+
return n3 ? "Infinity" : "-Infinity";
|
|
4511
|
+
default:
|
|
4512
|
+
return t4;
|
|
4513
|
+
}
|
|
4514
|
+
}(t3, Number(i3), e4);
|
|
4515
|
+
}(t2, i2);
|
|
4516
|
+
}
|
|
4517
|
+
return t2 !== undefined ? t2 : "";
|
|
4518
|
+
}
|
|
4519
|
+
function rt(t2, e2, i2) {
|
|
4520
|
+
const n2 = Number.parseInt(t2, e2);
|
|
4521
|
+
return n2 >= 0 && n2 <= 1114111 ? String.fromCodePoint(n2) : i2 + t2 + ";";
|
|
4522
|
+
}
|
|
4523
|
+
function ot(t2, e2, i2, n2) {
|
|
4524
|
+
if (t2) {
|
|
4525
|
+
const n3 = t2(e2);
|
|
4526
|
+
i2 === e2 && (i2 = n3), e2 = n3;
|
|
4527
|
+
}
|
|
4528
|
+
return { tagName: e2 = at(e2, n2), tagExp: i2 };
|
|
4529
|
+
}
|
|
4530
|
+
function at(t2, e2) {
|
|
4531
|
+
if (a.includes(t2))
|
|
4532
|
+
throw new Error(`[SECURITY] Invalid name: "${t2}" is a reserved JavaScript keyword that could cause prototype pollution`);
|
|
4533
|
+
return o.includes(t2) ? e2.onDangerousProperty(t2) : t2;
|
|
4534
|
+
}
|
|
4535
|
+
const ht = $.getMetaDataSymbol();
|
|
4536
|
+
function lt(t2, e2) {
|
|
4537
|
+
if (!t2 || typeof t2 != "object")
|
|
4538
|
+
return {};
|
|
4539
|
+
if (!e2)
|
|
4540
|
+
return t2;
|
|
4541
|
+
const i2 = {};
|
|
4542
|
+
for (const n2 in t2)
|
|
4543
|
+
n2.startsWith(e2) ? i2[n2.substring(e2.length)] = t2[n2] : i2[n2] = t2[n2];
|
|
4544
|
+
return i2;
|
|
4545
|
+
}
|
|
4546
|
+
function pt(t2, e2, i2, n2) {
|
|
4547
|
+
return ut(t2, e2, i2, n2);
|
|
4548
|
+
}
|
|
4549
|
+
function ut(t2, e2, i2, n2) {
|
|
4550
|
+
let s2;
|
|
4551
|
+
const r2 = {};
|
|
4552
|
+
for (let o2 = 0;o2 < t2.length; o2++) {
|
|
4553
|
+
const a2 = t2[o2], h2 = ct(a2);
|
|
4554
|
+
if (h2 !== undefined && h2 !== e2.textNodeName) {
|
|
4555
|
+
const t3 = lt(a2[":@"] || {}, e2.attributeNamePrefix);
|
|
4556
|
+
i2.push(h2, t3);
|
|
4557
|
+
}
|
|
4558
|
+
if (h2 === e2.textNodeName)
|
|
4559
|
+
s2 === undefined ? s2 = a2[h2] : s2 += "" + a2[h2];
|
|
4560
|
+
else {
|
|
4561
|
+
if (h2 === undefined)
|
|
4562
|
+
continue;
|
|
4563
|
+
if (a2[h2]) {
|
|
4564
|
+
let t3 = ut(a2[h2], e2, i2, n2);
|
|
4565
|
+
const s3 = ft(t3, e2);
|
|
4566
|
+
if (a2[":@"] ? dt(t3, a2[":@"], n2, e2) : Object.keys(t3).length !== 1 || t3[e2.textNodeName] === undefined || e2.alwaysCreateTextNode ? Object.keys(t3).length === 0 && (e2.alwaysCreateTextNode ? t3[e2.textNodeName] = "" : t3 = "") : t3 = t3[e2.textNodeName], a2[ht] !== undefined && typeof t3 == "object" && t3 !== null && (t3[ht] = a2[ht]), r2[h2] !== undefined && Object.prototype.hasOwnProperty.call(r2, h2))
|
|
4567
|
+
Array.isArray(r2[h2]) || (r2[h2] = [r2[h2]]), r2[h2].push(t3);
|
|
4568
|
+
else {
|
|
4569
|
+
const i3 = e2.jPath ? n2.toString() : n2;
|
|
4570
|
+
e2.isArray(h2, i3, s3) ? r2[h2] = [t3] : r2[h2] = t3;
|
|
4571
|
+
}
|
|
4572
|
+
h2 !== undefined && h2 !== e2.textNodeName && i2.pop();
|
|
4573
|
+
}
|
|
4574
|
+
}
|
|
4575
|
+
}
|
|
4576
|
+
return typeof s2 == "string" ? s2.length > 0 && (r2[e2.textNodeName] = s2) : s2 !== undefined && (r2[e2.textNodeName] = s2), r2;
|
|
4577
|
+
}
|
|
4578
|
+
function ct(t2) {
|
|
4579
|
+
const e2 = Object.keys(t2);
|
|
4580
|
+
for (let t3 = 0;t3 < e2.length; t3++) {
|
|
4581
|
+
const i2 = e2[t3];
|
|
4582
|
+
if (i2 !== ":@")
|
|
4583
|
+
return i2;
|
|
4584
|
+
}
|
|
4585
|
+
}
|
|
4586
|
+
function dt(t2, e2, i2, n2) {
|
|
4587
|
+
if (e2) {
|
|
4588
|
+
const s2 = Object.keys(e2), r2 = s2.length;
|
|
4589
|
+
for (let o2 = 0;o2 < r2; o2++) {
|
|
4590
|
+
const r3 = s2[o2], a2 = r3.startsWith(n2.attributeNamePrefix) ? r3.substring(n2.attributeNamePrefix.length) : r3, h2 = n2.jPath ? i2.toString() + "." + a2 : i2;
|
|
4591
|
+
n2.isArray(r3, h2, true, true) ? t2[r3] = [e2[r3]] : t2[r3] = e2[r3];
|
|
4592
|
+
}
|
|
4593
|
+
}
|
|
4594
|
+
}
|
|
4595
|
+
function ft(t2, e2) {
|
|
4596
|
+
const { textNodeName: i2 } = e2, n2 = Object.keys(t2).length;
|
|
4597
|
+
return n2 === 0 || !(n2 !== 1 || !t2[i2] && typeof t2[i2] != "boolean" && t2[i2] !== 0);
|
|
4598
|
+
}
|
|
4599
|
+
|
|
4600
|
+
class gt {
|
|
4601
|
+
constructor(t2) {
|
|
4602
|
+
this.externalEntities = {}, this.options = O(t2);
|
|
4603
|
+
}
|
|
4604
|
+
parse(t2, e2) {
|
|
4605
|
+
if (typeof t2 != "string" && t2.toString)
|
|
4606
|
+
t2 = t2.toString();
|
|
4607
|
+
else if (typeof t2 != "string")
|
|
4608
|
+
throw new Error("XML data is accepted in String or Bytes[] form.");
|
|
4609
|
+
if (e2) {
|
|
4610
|
+
e2 === true && (e2 = {});
|
|
4611
|
+
const i3 = l(t2, e2);
|
|
4612
|
+
if (i3 !== true)
|
|
4613
|
+
throw Error(`${i3.err.msg}:${i3.err.line}:${i3.err.col}`);
|
|
4614
|
+
}
|
|
4615
|
+
const i2 = new W(this.options);
|
|
4616
|
+
i2.addExternalEntities(this.externalEntities);
|
|
4617
|
+
const n2 = i2.parseXml(t2);
|
|
4618
|
+
return this.options.preserveOrder || n2 === undefined ? n2 : pt(n2, this.options, i2.matcher, i2.readonlyMatcher);
|
|
4619
|
+
}
|
|
4620
|
+
addEntity(t2, e2) {
|
|
4621
|
+
if (e2.indexOf("&") !== -1)
|
|
4622
|
+
throw new Error("Entity value can't have '&'");
|
|
4623
|
+
if (t2.indexOf("&") !== -1 || t2.indexOf(";") !== -1)
|
|
4624
|
+
throw new Error("An entity must be set without '&' and ';'. Eg. use '#xD' for '
'");
|
|
4625
|
+
if (e2 === "&")
|
|
4626
|
+
throw new Error("An entity with value '&' is not permitted");
|
|
4627
|
+
this.externalEntities[t2] = e2;
|
|
4628
|
+
}
|
|
4629
|
+
static getMetaDataSymbol() {
|
|
4630
|
+
return $.getMetaDataSymbol();
|
|
4631
|
+
}
|
|
4632
|
+
}
|
|
4633
|
+
function mt(t2, e2) {
|
|
4634
|
+
let i2 = "";
|
|
4635
|
+
e2.format && e2.indentBy.length > 0 && (i2 = `
|
|
4636
|
+
`);
|
|
4637
|
+
const n2 = [];
|
|
4638
|
+
if (e2.stopNodes && Array.isArray(e2.stopNodes))
|
|
4639
|
+
for (let t3 = 0;t3 < e2.stopNodes.length; t3++) {
|
|
4640
|
+
const i3 = e2.stopNodes[t3];
|
|
4641
|
+
typeof i3 == "string" ? n2.push(new R(i3)) : i3 instanceof R && n2.push(i3);
|
|
4642
|
+
}
|
|
4643
|
+
return xt(t2, e2, i2, new G, n2);
|
|
4644
|
+
}
|
|
4645
|
+
function xt(t2, e2, i2, n2, s2) {
|
|
4646
|
+
let r2 = "", o2 = false;
|
|
4647
|
+
if (e2.maxNestedTags && n2.getDepth() > e2.maxNestedTags)
|
|
4648
|
+
throw new Error("Maximum nested tags exceeded");
|
|
4649
|
+
if (!Array.isArray(t2)) {
|
|
4650
|
+
if (t2 != null) {
|
|
4651
|
+
let i3 = t2.toString();
|
|
4652
|
+
return i3 = Tt(i3, e2), i3;
|
|
4653
|
+
}
|
|
4654
|
+
return "";
|
|
4655
|
+
}
|
|
4656
|
+
for (let a2 = 0;a2 < t2.length; a2++) {
|
|
4657
|
+
const h2 = t2[a2], l2 = yt(h2);
|
|
4658
|
+
if (l2 === undefined)
|
|
4659
|
+
continue;
|
|
4660
|
+
const p2 = Nt(h2[":@"], e2);
|
|
4661
|
+
n2.push(l2, p2);
|
|
4662
|
+
const u2 = vt(n2, s2);
|
|
4663
|
+
if (l2 === e2.textNodeName) {
|
|
4664
|
+
let t3 = h2[l2];
|
|
4665
|
+
u2 || (t3 = e2.tagValueProcessor(l2, t3), t3 = Tt(t3, e2)), o2 && (r2 += i2), r2 += t3, o2 = false, n2.pop();
|
|
4666
|
+
continue;
|
|
4667
|
+
}
|
|
4668
|
+
if (l2 === e2.cdataPropName) {
|
|
4669
|
+
o2 && (r2 += i2), r2 += `<![CDATA[${h2[l2][0][e2.textNodeName]}]]>`, o2 = false, n2.pop();
|
|
4670
|
+
continue;
|
|
4671
|
+
}
|
|
4672
|
+
if (l2 === e2.commentPropName) {
|
|
4673
|
+
r2 += i2 + `<!--${h2[l2][0][e2.textNodeName]}-->`, o2 = true, n2.pop();
|
|
4674
|
+
continue;
|
|
4675
|
+
}
|
|
4676
|
+
if (l2[0] === "?") {
|
|
4677
|
+
const t3 = wt(h2[":@"], e2, u2), s3 = l2 === "?xml" ? "" : i2;
|
|
4678
|
+
let a3 = h2[l2][0][e2.textNodeName];
|
|
4679
|
+
a3 = a3.length !== 0 ? " " + a3 : "", r2 += s3 + `<${l2}${a3}${t3}?>`, o2 = true, n2.pop();
|
|
4680
|
+
continue;
|
|
4681
|
+
}
|
|
4682
|
+
let c2 = i2;
|
|
4683
|
+
c2 !== "" && (c2 += e2.indentBy);
|
|
4684
|
+
const d2 = i2 + `<${l2}${wt(h2[":@"], e2, u2)}`;
|
|
4685
|
+
let f2;
|
|
4686
|
+
f2 = u2 ? bt(h2[l2], e2) : xt(h2[l2], e2, c2, n2, s2), e2.unpairedTags.indexOf(l2) !== -1 ? e2.suppressUnpairedNode ? r2 += d2 + ">" : r2 += d2 + "/>" : f2 && f2.length !== 0 || !e2.suppressEmptyNode ? f2 && f2.endsWith(">") ? r2 += d2 + `>${f2}${i2}</${l2}>` : (r2 += d2 + ">", f2 && i2 !== "" && (f2.includes("/>") || f2.includes("</")) ? r2 += i2 + e2.indentBy + f2 + i2 : r2 += f2, r2 += `</${l2}>`) : r2 += d2 + "/>", o2 = true, n2.pop();
|
|
4687
|
+
}
|
|
4688
|
+
return r2;
|
|
4689
|
+
}
|
|
4690
|
+
function Nt(t2, e2) {
|
|
4691
|
+
if (!t2 || e2.ignoreAttributes)
|
|
4692
|
+
return null;
|
|
4693
|
+
const i2 = {};
|
|
4694
|
+
let n2 = false;
|
|
4695
|
+
for (let s2 in t2)
|
|
4696
|
+
Object.prototype.hasOwnProperty.call(t2, s2) && (i2[s2.startsWith(e2.attributeNamePrefix) ? s2.substr(e2.attributeNamePrefix.length) : s2] = t2[s2], n2 = true);
|
|
4697
|
+
return n2 ? i2 : null;
|
|
4698
|
+
}
|
|
4699
|
+
function bt(t2, e2) {
|
|
4700
|
+
if (!Array.isArray(t2))
|
|
4701
|
+
return t2 != null ? t2.toString() : "";
|
|
4702
|
+
let i2 = "";
|
|
4703
|
+
for (let n2 = 0;n2 < t2.length; n2++) {
|
|
4704
|
+
const s2 = t2[n2], r2 = yt(s2);
|
|
4705
|
+
if (r2 === e2.textNodeName)
|
|
4706
|
+
i2 += s2[r2];
|
|
4707
|
+
else if (r2 === e2.cdataPropName)
|
|
4708
|
+
i2 += s2[r2][0][e2.textNodeName];
|
|
4709
|
+
else if (r2 === e2.commentPropName)
|
|
4710
|
+
i2 += s2[r2][0][e2.textNodeName];
|
|
4711
|
+
else {
|
|
4712
|
+
if (r2 && r2[0] === "?")
|
|
4713
|
+
continue;
|
|
4714
|
+
if (r2) {
|
|
4715
|
+
const t3 = Et(s2[":@"], e2), n3 = bt(s2[r2], e2);
|
|
4716
|
+
n3 && n3.length !== 0 ? i2 += `<${r2}${t3}>${n3}</${r2}>` : i2 += `<${r2}${t3}/>`;
|
|
4717
|
+
}
|
|
4718
|
+
}
|
|
4719
|
+
}
|
|
4720
|
+
return i2;
|
|
4721
|
+
}
|
|
4722
|
+
function Et(t2, e2) {
|
|
4723
|
+
let i2 = "";
|
|
4724
|
+
if (t2 && !e2.ignoreAttributes)
|
|
4725
|
+
for (let n2 in t2) {
|
|
4726
|
+
if (!Object.prototype.hasOwnProperty.call(t2, n2))
|
|
4727
|
+
continue;
|
|
4728
|
+
let s2 = t2[n2];
|
|
4729
|
+
s2 === true && e2.suppressBooleanAttributes ? i2 += ` ${n2.substr(e2.attributeNamePrefix.length)}` : i2 += ` ${n2.substr(e2.attributeNamePrefix.length)}="${s2}"`;
|
|
4730
|
+
}
|
|
4731
|
+
return i2;
|
|
4732
|
+
}
|
|
4733
|
+
function yt(t2) {
|
|
4734
|
+
const e2 = Object.keys(t2);
|
|
4735
|
+
for (let i2 = 0;i2 < e2.length; i2++) {
|
|
4736
|
+
const n2 = e2[i2];
|
|
4737
|
+
if (Object.prototype.hasOwnProperty.call(t2, n2) && n2 !== ":@")
|
|
4738
|
+
return n2;
|
|
4739
|
+
}
|
|
4740
|
+
}
|
|
4741
|
+
function wt(t2, e2, i2) {
|
|
4742
|
+
let n2 = "";
|
|
4743
|
+
if (t2 && !e2.ignoreAttributes)
|
|
4744
|
+
for (let s2 in t2) {
|
|
4745
|
+
if (!Object.prototype.hasOwnProperty.call(t2, s2))
|
|
4746
|
+
continue;
|
|
4747
|
+
let r2;
|
|
4748
|
+
i2 ? r2 = t2[s2] : (r2 = e2.attributeValueProcessor(s2, t2[s2]), r2 = Tt(r2, e2)), r2 === true && e2.suppressBooleanAttributes ? n2 += ` ${s2.substr(e2.attributeNamePrefix.length)}` : n2 += ` ${s2.substr(e2.attributeNamePrefix.length)}="${r2}"`;
|
|
4749
|
+
}
|
|
4750
|
+
return n2;
|
|
4751
|
+
}
|
|
4752
|
+
function vt(t2, e2) {
|
|
4753
|
+
if (!e2 || e2.length === 0)
|
|
4754
|
+
return false;
|
|
4755
|
+
for (let i2 = 0;i2 < e2.length; i2++)
|
|
4756
|
+
if (t2.matches(e2[i2]))
|
|
4757
|
+
return true;
|
|
4758
|
+
return false;
|
|
4759
|
+
}
|
|
4760
|
+
function Tt(t2, e2) {
|
|
4761
|
+
if (t2 && t2.length > 0 && e2.processEntities)
|
|
4762
|
+
for (let i2 = 0;i2 < e2.entities.length; i2++) {
|
|
4763
|
+
const n2 = e2.entities[i2];
|
|
4764
|
+
t2 = t2.replace(n2.regex, n2.val);
|
|
4765
|
+
}
|
|
4766
|
+
return t2;
|
|
4767
|
+
}
|
|
4768
|
+
const Pt = { attributeNamePrefix: "@_", attributesGroupName: false, textNodeName: "#text", ignoreAttributes: true, cdataPropName: false, format: false, indentBy: " ", suppressEmptyNode: false, suppressUnpairedNode: true, suppressBooleanAttributes: true, tagValueProcessor: function(t2, e2) {
|
|
4769
|
+
return e2;
|
|
4770
|
+
}, attributeValueProcessor: function(t2, e2) {
|
|
4771
|
+
return e2;
|
|
4772
|
+
}, preserveOrder: false, commentPropName: false, unpairedTags: [], entities: [{ regex: new RegExp("&", "g"), val: "&" }, { regex: new RegExp(">", "g"), val: ">" }, { regex: new RegExp("<", "g"), val: "<" }, { regex: new RegExp("'", "g"), val: "'" }, { regex: new RegExp('"', "g"), val: """ }], processEntities: true, stopNodes: [], oneListGroup: false, maxNestedTags: 100, jPath: true };
|
|
4773
|
+
function St(t2) {
|
|
4774
|
+
if (this.options = Object.assign({}, Pt, t2), this.options.stopNodes && Array.isArray(this.options.stopNodes) && (this.options.stopNodes = this.options.stopNodes.map((t3) => typeof t3 == "string" && t3.startsWith("*.") ? ".." + t3.substring(2) : t3)), this.stopNodeExpressions = [], this.options.stopNodes && Array.isArray(this.options.stopNodes))
|
|
4775
|
+
for (let t3 = 0;t3 < this.options.stopNodes.length; t3++) {
|
|
4776
|
+
const e3 = this.options.stopNodes[t3];
|
|
4777
|
+
typeof e3 == "string" ? this.stopNodeExpressions.push(new R(e3)) : e3 instanceof R && this.stopNodeExpressions.push(e3);
|
|
4778
|
+
}
|
|
4779
|
+
var e2;
|
|
4780
|
+
this.options.ignoreAttributes === true || this.options.attributesGroupName ? this.isAttribute = function() {
|
|
4781
|
+
return false;
|
|
4782
|
+
} : (this.ignoreAttributesFn = typeof (e2 = this.options.ignoreAttributes) == "function" ? e2 : Array.isArray(e2) ? (t3) => {
|
|
4783
|
+
for (const i2 of e2) {
|
|
4784
|
+
if (typeof i2 == "string" && t3 === i2)
|
|
4785
|
+
return true;
|
|
4786
|
+
if (i2 instanceof RegExp && i2.test(t3))
|
|
4787
|
+
return true;
|
|
4788
|
+
}
|
|
4789
|
+
} : () => false, this.attrPrefixLen = this.options.attributeNamePrefix.length, this.isAttribute = Ct), this.processTextOrObjNode = At, this.options.format ? (this.indentate = Ot, this.tagEndChar = `>
|
|
4790
|
+
`, this.newLine = `
|
|
4791
|
+
`) : (this.indentate = function() {
|
|
4792
|
+
return "";
|
|
4793
|
+
}, this.tagEndChar = ">", this.newLine = "");
|
|
4794
|
+
}
|
|
4795
|
+
function At(t2, e2, i2, n2) {
|
|
4796
|
+
const s2 = this.extractAttributes(t2);
|
|
4797
|
+
if (n2.push(e2, s2), this.checkStopNode(n2)) {
|
|
4798
|
+
const s3 = this.buildRawContent(t2), r3 = this.buildAttributesForStopNode(t2);
|
|
4799
|
+
return n2.pop(), this.buildObjectNode(s3, e2, r3, i2);
|
|
4800
|
+
}
|
|
4801
|
+
const r2 = this.j2x(t2, i2 + 1, n2);
|
|
4802
|
+
return n2.pop(), t2[this.options.textNodeName] !== undefined && Object.keys(t2).length === 1 ? this.buildTextValNode(t2[this.options.textNodeName], e2, r2.attrStr, i2, n2) : this.buildObjectNode(r2.val, e2, r2.attrStr, i2);
|
|
4803
|
+
}
|
|
4804
|
+
function Ot(t2) {
|
|
4805
|
+
return this.options.indentBy.repeat(t2);
|
|
4806
|
+
}
|
|
4807
|
+
function Ct(t2) {
|
|
4808
|
+
return !(!t2.startsWith(this.options.attributeNamePrefix) || t2 === this.options.textNodeName) && t2.substr(this.attrPrefixLen);
|
|
4809
|
+
}
|
|
4810
|
+
St.prototype.build = function(t2) {
|
|
4811
|
+
if (this.options.preserveOrder)
|
|
4812
|
+
return mt(t2, this.options);
|
|
4813
|
+
{
|
|
4814
|
+
Array.isArray(t2) && this.options.arrayNodeName && this.options.arrayNodeName.length > 1 && (t2 = { [this.options.arrayNodeName]: t2 });
|
|
4815
|
+
const e2 = new G;
|
|
4816
|
+
return this.j2x(t2, 0, e2).val;
|
|
4817
|
+
}
|
|
4818
|
+
}, St.prototype.j2x = function(t2, e2, i2) {
|
|
4819
|
+
let n2 = "", s2 = "";
|
|
4820
|
+
if (this.options.maxNestedTags && i2.getDepth() >= this.options.maxNestedTags)
|
|
4821
|
+
throw new Error("Maximum nested tags exceeded");
|
|
4822
|
+
const r2 = this.options.jPath ? i2.toString() : i2, o2 = this.checkStopNode(i2);
|
|
4823
|
+
for (let a2 in t2)
|
|
4824
|
+
if (Object.prototype.hasOwnProperty.call(t2, a2))
|
|
4825
|
+
if (t2[a2] === undefined)
|
|
4826
|
+
this.isAttribute(a2) && (s2 += "");
|
|
4827
|
+
else if (t2[a2] === null)
|
|
4828
|
+
this.isAttribute(a2) || a2 === this.options.cdataPropName ? s2 += "" : a2[0] === "?" ? s2 += this.indentate(e2) + "<" + a2 + "?" + this.tagEndChar : s2 += this.indentate(e2) + "<" + a2 + "/" + this.tagEndChar;
|
|
4829
|
+
else if (t2[a2] instanceof Date)
|
|
4830
|
+
s2 += this.buildTextValNode(t2[a2], a2, "", e2, i2);
|
|
4831
|
+
else if (typeof t2[a2] != "object") {
|
|
4832
|
+
const h2 = this.isAttribute(a2);
|
|
4833
|
+
if (h2 && !this.ignoreAttributesFn(h2, r2))
|
|
4834
|
+
n2 += this.buildAttrPairStr(h2, "" + t2[a2], o2);
|
|
4835
|
+
else if (!h2)
|
|
4836
|
+
if (a2 === this.options.textNodeName) {
|
|
4837
|
+
let e3 = this.options.tagValueProcessor(a2, "" + t2[a2]);
|
|
4838
|
+
s2 += this.replaceEntitiesValue(e3);
|
|
4839
|
+
} else {
|
|
4840
|
+
i2.push(a2);
|
|
4841
|
+
const n3 = this.checkStopNode(i2);
|
|
4842
|
+
if (i2.pop(), n3) {
|
|
4843
|
+
const i3 = "" + t2[a2];
|
|
4844
|
+
s2 += i3 === "" ? this.indentate(e2) + "<" + a2 + this.closeTag(a2) + this.tagEndChar : this.indentate(e2) + "<" + a2 + ">" + i3 + "</" + a2 + this.tagEndChar;
|
|
4845
|
+
} else
|
|
4846
|
+
s2 += this.buildTextValNode(t2[a2], a2, "", e2, i2);
|
|
4847
|
+
}
|
|
4848
|
+
} else if (Array.isArray(t2[a2])) {
|
|
4849
|
+
const n3 = t2[a2].length;
|
|
4850
|
+
let r3 = "", o3 = "";
|
|
4851
|
+
for (let h2 = 0;h2 < n3; h2++) {
|
|
4852
|
+
const n4 = t2[a2][h2];
|
|
4853
|
+
if (n4 === undefined)
|
|
4854
|
+
;
|
|
4855
|
+
else if (n4 === null)
|
|
4856
|
+
a2[0] === "?" ? s2 += this.indentate(e2) + "<" + a2 + "?" + this.tagEndChar : s2 += this.indentate(e2) + "<" + a2 + "/" + this.tagEndChar;
|
|
4857
|
+
else if (typeof n4 == "object")
|
|
4858
|
+
if (this.options.oneListGroup) {
|
|
4859
|
+
i2.push(a2);
|
|
4860
|
+
const t3 = this.j2x(n4, e2 + 1, i2);
|
|
4861
|
+
i2.pop(), r3 += t3.val, this.options.attributesGroupName && n4.hasOwnProperty(this.options.attributesGroupName) && (o3 += t3.attrStr);
|
|
4862
|
+
} else
|
|
4863
|
+
r3 += this.processTextOrObjNode(n4, a2, e2, i2);
|
|
4864
|
+
else if (this.options.oneListGroup) {
|
|
4865
|
+
let t3 = this.options.tagValueProcessor(a2, n4);
|
|
4866
|
+
t3 = this.replaceEntitiesValue(t3), r3 += t3;
|
|
4867
|
+
} else {
|
|
4868
|
+
i2.push(a2);
|
|
4869
|
+
const t3 = this.checkStopNode(i2);
|
|
4870
|
+
if (i2.pop(), t3) {
|
|
4871
|
+
const t4 = "" + n4;
|
|
4872
|
+
r3 += t4 === "" ? this.indentate(e2) + "<" + a2 + this.closeTag(a2) + this.tagEndChar : this.indentate(e2) + "<" + a2 + ">" + t4 + "</" + a2 + this.tagEndChar;
|
|
4873
|
+
} else
|
|
4874
|
+
r3 += this.buildTextValNode(n4, a2, "", e2, i2);
|
|
4875
|
+
}
|
|
4876
|
+
}
|
|
4877
|
+
this.options.oneListGroup && (r3 = this.buildObjectNode(r3, a2, o3, e2)), s2 += r3;
|
|
4878
|
+
} else if (this.options.attributesGroupName && a2 === this.options.attributesGroupName) {
|
|
4879
|
+
const e3 = Object.keys(t2[a2]), i3 = e3.length;
|
|
4880
|
+
for (let s3 = 0;s3 < i3; s3++)
|
|
4881
|
+
n2 += this.buildAttrPairStr(e3[s3], "" + t2[a2][e3[s3]], o2);
|
|
4882
|
+
} else
|
|
4883
|
+
s2 += this.processTextOrObjNode(t2[a2], a2, e2, i2);
|
|
4884
|
+
return { attrStr: n2, val: s2 };
|
|
4885
|
+
}, St.prototype.buildAttrPairStr = function(t2, e2, i2) {
|
|
4886
|
+
return i2 || (e2 = this.options.attributeValueProcessor(t2, "" + e2), e2 = this.replaceEntitiesValue(e2)), this.options.suppressBooleanAttributes && e2 === "true" ? " " + t2 : " " + t2 + '="' + e2 + '"';
|
|
4887
|
+
}, St.prototype.extractAttributes = function(t2) {
|
|
4888
|
+
if (!t2 || typeof t2 != "object")
|
|
4889
|
+
return null;
|
|
4890
|
+
const e2 = {};
|
|
4891
|
+
let i2 = false;
|
|
4892
|
+
if (this.options.attributesGroupName && t2[this.options.attributesGroupName]) {
|
|
4893
|
+
const n2 = t2[this.options.attributesGroupName];
|
|
4894
|
+
for (let t3 in n2)
|
|
4895
|
+
Object.prototype.hasOwnProperty.call(n2, t3) && (e2[t3.startsWith(this.options.attributeNamePrefix) ? t3.substring(this.options.attributeNamePrefix.length) : t3] = n2[t3], i2 = true);
|
|
4896
|
+
} else
|
|
4897
|
+
for (let n2 in t2) {
|
|
4898
|
+
if (!Object.prototype.hasOwnProperty.call(t2, n2))
|
|
4899
|
+
continue;
|
|
4900
|
+
const s2 = this.isAttribute(n2);
|
|
4901
|
+
s2 && (e2[s2] = t2[n2], i2 = true);
|
|
4902
|
+
}
|
|
4903
|
+
return i2 ? e2 : null;
|
|
4904
|
+
}, St.prototype.buildRawContent = function(t2) {
|
|
4905
|
+
if (typeof t2 == "string")
|
|
4906
|
+
return t2;
|
|
4907
|
+
if (typeof t2 != "object" || t2 === null)
|
|
4908
|
+
return String(t2);
|
|
4909
|
+
if (t2[this.options.textNodeName] !== undefined)
|
|
4910
|
+
return t2[this.options.textNodeName];
|
|
4911
|
+
let e2 = "";
|
|
4912
|
+
for (let i2 in t2) {
|
|
4913
|
+
if (!Object.prototype.hasOwnProperty.call(t2, i2))
|
|
4914
|
+
continue;
|
|
4915
|
+
if (this.isAttribute(i2))
|
|
4916
|
+
continue;
|
|
4917
|
+
if (this.options.attributesGroupName && i2 === this.options.attributesGroupName)
|
|
4918
|
+
continue;
|
|
4919
|
+
const n2 = t2[i2];
|
|
4920
|
+
if (i2 === this.options.textNodeName)
|
|
4921
|
+
e2 += n2;
|
|
4922
|
+
else if (Array.isArray(n2)) {
|
|
4923
|
+
for (let t3 of n2)
|
|
4924
|
+
if (typeof t3 == "string" || typeof t3 == "number")
|
|
4925
|
+
e2 += `<${i2}>${t3}</${i2}>`;
|
|
4926
|
+
else if (typeof t3 == "object" && t3 !== null) {
|
|
4927
|
+
const n3 = this.buildRawContent(t3), s2 = this.buildAttributesForStopNode(t3);
|
|
4928
|
+
e2 += n3 === "" ? `<${i2}${s2}/>` : `<${i2}${s2}>${n3}</${i2}>`;
|
|
4929
|
+
}
|
|
4930
|
+
} else if (typeof n2 == "object" && n2 !== null) {
|
|
4931
|
+
const t3 = this.buildRawContent(n2), s2 = this.buildAttributesForStopNode(n2);
|
|
4932
|
+
e2 += t3 === "" ? `<${i2}${s2}/>` : `<${i2}${s2}>${t3}</${i2}>`;
|
|
4933
|
+
} else
|
|
4934
|
+
e2 += `<${i2}>${n2}</${i2}>`;
|
|
4935
|
+
}
|
|
4936
|
+
return e2;
|
|
4937
|
+
}, St.prototype.buildAttributesForStopNode = function(t2) {
|
|
4938
|
+
if (!t2 || typeof t2 != "object")
|
|
4939
|
+
return "";
|
|
4940
|
+
let e2 = "";
|
|
4941
|
+
if (this.options.attributesGroupName && t2[this.options.attributesGroupName]) {
|
|
4942
|
+
const i2 = t2[this.options.attributesGroupName];
|
|
4943
|
+
for (let t3 in i2) {
|
|
4944
|
+
if (!Object.prototype.hasOwnProperty.call(i2, t3))
|
|
4945
|
+
continue;
|
|
4946
|
+
const n2 = t3.startsWith(this.options.attributeNamePrefix) ? t3.substring(this.options.attributeNamePrefix.length) : t3, s2 = i2[t3];
|
|
4947
|
+
s2 === true && this.options.suppressBooleanAttributes ? e2 += " " + n2 : e2 += " " + n2 + '="' + s2 + '"';
|
|
4948
|
+
}
|
|
4949
|
+
} else
|
|
4950
|
+
for (let i2 in t2) {
|
|
4951
|
+
if (!Object.prototype.hasOwnProperty.call(t2, i2))
|
|
4952
|
+
continue;
|
|
4953
|
+
const n2 = this.isAttribute(i2);
|
|
4954
|
+
if (n2) {
|
|
4955
|
+
const s2 = t2[i2];
|
|
4956
|
+
s2 === true && this.options.suppressBooleanAttributes ? e2 += " " + n2 : e2 += " " + n2 + '="' + s2 + '"';
|
|
4957
|
+
}
|
|
4958
|
+
}
|
|
4959
|
+
return e2;
|
|
4960
|
+
}, St.prototype.buildObjectNode = function(t2, e2, i2, n2) {
|
|
4961
|
+
if (t2 === "")
|
|
4962
|
+
return e2[0] === "?" ? this.indentate(n2) + "<" + e2 + i2 + "?" + this.tagEndChar : this.indentate(n2) + "<" + e2 + i2 + this.closeTag(e2) + this.tagEndChar;
|
|
4963
|
+
{
|
|
4964
|
+
let s2 = "</" + e2 + this.tagEndChar, r2 = "";
|
|
4965
|
+
return e2[0] === "?" && (r2 = "?", s2 = ""), !i2 && i2 !== "" || t2.indexOf("<") !== -1 ? this.options.commentPropName !== false && e2 === this.options.commentPropName && r2.length === 0 ? this.indentate(n2) + `<!--${t2}-->` + this.newLine : this.indentate(n2) + "<" + e2 + i2 + r2 + this.tagEndChar + t2 + this.indentate(n2) + s2 : this.indentate(n2) + "<" + e2 + i2 + r2 + ">" + t2 + s2;
|
|
4966
|
+
}
|
|
4967
|
+
}, St.prototype.closeTag = function(t2) {
|
|
4968
|
+
let e2 = "";
|
|
4969
|
+
return this.options.unpairedTags.indexOf(t2) !== -1 ? this.options.suppressUnpairedNode || (e2 = "/") : e2 = this.options.suppressEmptyNode ? "/" : `></${t2}`, e2;
|
|
4970
|
+
}, St.prototype.checkStopNode = function(t2) {
|
|
4971
|
+
if (!this.stopNodeExpressions || this.stopNodeExpressions.length === 0)
|
|
4972
|
+
return false;
|
|
4973
|
+
for (let e2 = 0;e2 < this.stopNodeExpressions.length; e2++)
|
|
4974
|
+
if (t2.matches(this.stopNodeExpressions[e2]))
|
|
4975
|
+
return true;
|
|
4976
|
+
return false;
|
|
4977
|
+
}, St.prototype.buildTextValNode = function(t2, e2, i2, n2, s2) {
|
|
4978
|
+
if (this.options.cdataPropName !== false && e2 === this.options.cdataPropName)
|
|
4979
|
+
return this.indentate(n2) + `<![CDATA[${t2}]]>` + this.newLine;
|
|
4980
|
+
if (this.options.commentPropName !== false && e2 === this.options.commentPropName)
|
|
4981
|
+
return this.indentate(n2) + `<!--${t2}-->` + this.newLine;
|
|
4982
|
+
if (e2[0] === "?")
|
|
4983
|
+
return this.indentate(n2) + "<" + e2 + i2 + "?" + this.tagEndChar;
|
|
4984
|
+
{
|
|
4985
|
+
let s3 = this.options.tagValueProcessor(e2, t2);
|
|
4986
|
+
return s3 = this.replaceEntitiesValue(s3), s3 === "" ? this.indentate(n2) + "<" + e2 + i2 + this.closeTag(e2) + this.tagEndChar : this.indentate(n2) + "<" + e2 + i2 + ">" + s3 + "</" + e2 + this.tagEndChar;
|
|
4987
|
+
}
|
|
4988
|
+
}, St.prototype.replaceEntitiesValue = function(t2) {
|
|
4989
|
+
if (t2 && t2.length > 0 && this.options.processEntities)
|
|
4990
|
+
for (let e2 = 0;e2 < this.options.entities.length; e2++) {
|
|
4991
|
+
const i2 = this.options.entities[e2];
|
|
4992
|
+
t2 = t2.replace(i2.regex, i2.val);
|
|
4993
|
+
}
|
|
4994
|
+
return t2;
|
|
4995
|
+
};
|
|
4996
|
+
const $t = St, It = { validate: l };
|
|
4997
|
+
module.exports = e;
|
|
4998
|
+
})();
|
|
4999
|
+
});
|
|
5000
|
+
|
|
3356
5001
|
// node_modules/.bun/@aws-sdk+xml-builder@3.972.17/node_modules/@aws-sdk/xml-builder/dist-cjs/xml-parser.js
|
|
3357
5002
|
var require_xml_parser = __commonJS((exports) => {
|
|
3358
5003
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
@@ -3382,7 +5027,7 @@ var require_xml_parser = __commonJS((exports) => {
|
|
|
3382
5027
|
});
|
|
3383
5028
|
|
|
3384
5029
|
// node_modules/.bun/@aws-sdk+xml-builder@3.972.17/node_modules/@aws-sdk/xml-builder/dist-cjs/index.js
|
|
3385
|
-
var
|
|
5030
|
+
var require_dist_cjs31 = __commonJS((exports) => {
|
|
3386
5031
|
var xmlParser = require_xml_parser();
|
|
3387
5032
|
var ATTR_ESCAPE_RE = /[&<>"]/g;
|
|
3388
5033
|
var ATTR_ESCAPE_MAP = {
|
|
@@ -3515,12 +5160,12 @@ var require_dist_cjs32 = __commonJS((exports) => {
|
|
|
3515
5160
|
var require_protocols2 = __commonJS((exports) => {
|
|
3516
5161
|
var cbor = require_cbor();
|
|
3517
5162
|
var schema = require_schema();
|
|
3518
|
-
var smithyClient =
|
|
5163
|
+
var smithyClient = require_dist_cjs10();
|
|
3519
5164
|
var protocols = require_protocols();
|
|
3520
5165
|
var serde = require_serde();
|
|
3521
|
-
var utilBase64 =
|
|
3522
|
-
var utilUtf8 =
|
|
3523
|
-
var xmlBuilder =
|
|
5166
|
+
var utilBase64 = require_dist_cjs9();
|
|
5167
|
+
var utilUtf8 = require_dist_cjs8();
|
|
5168
|
+
var xmlBuilder = require_dist_cjs31();
|
|
3524
5169
|
|
|
3525
5170
|
class ProtocolLib {
|
|
3526
5171
|
queryCompat;
|
|
@@ -5327,4 +6972,4 @@ var require_protocols2 = __commonJS((exports) => {
|
|
|
5327
6972
|
exports.parseXmlErrorBody = parseXmlErrorBody;
|
|
5328
6973
|
});
|
|
5329
6974
|
|
|
5330
|
-
export {
|
|
6975
|
+
export { require_dist_cjs15 as require_dist_cjs, require_dist_cjs16 as require_dist_cjs1, require_dist_cjs17 as require_dist_cjs2, require_dist_cjs18 as require_dist_cjs3, require_dist_cjs20 as require_dist_cjs4, require_dist_cjs21 as require_dist_cjs5, require_dist_cjs22 as require_dist_cjs6, require_dist_cjs24 as require_dist_cjs7, require_dist_cjs25 as require_dist_cjs8, require_dist_cjs27 as require_dist_cjs9, require_dist_cjs28 as require_dist_cjs10, require_dist_cjs29 as require_dist_cjs11, require_protocols2 as require_protocols, require_dist_cjs26 as require_dist_cjs12 };
|