gemi 0.4.119 → 0.4.121
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/app/index.js +2 -2
- package/dist/app/index.js.map +2 -2
- package/dist/broadcasting/index.js +1 -1
- package/dist/chunk-001ftwam.js +4 -0
- package/dist/chunk-001ftwam.js.map +10 -0
- package/dist/chunk-01td3x3h.js +4 -0
- package/dist/chunk-01td3x3h.js.map +10 -0
- package/dist/chunk-029k2gah.js +4 -0
- package/dist/chunk-029k2gah.js.map +10 -0
- package/dist/chunk-0662pv0m.js +4 -0
- package/dist/{chunk-a67a5vtk.js.map → chunk-0662pv0m.js.map} +2 -2
- package/dist/chunk-0cax9v4f.js +4 -0
- package/dist/chunk-0cax9v4f.js.map +10 -0
- package/dist/chunk-0d9amhty.js +4 -0
- package/dist/chunk-0d9amhty.js.map +10 -0
- package/dist/chunk-0e502hy4.js +4 -0
- package/dist/chunk-0e502hy4.js.map +10 -0
- package/dist/chunk-0gqrxkhr.js +4 -0
- package/dist/chunk-0gqrxkhr.js.map +10 -0
- package/dist/chunk-0kk73bxd.js +4 -0
- package/dist/chunk-0kk73bxd.js.map +10 -0
- package/dist/{chunk-x8wrqc4y.js → chunk-0nvzdwwv.js} +2 -2
- package/dist/{chunk-x8wrqc4y.js.map → chunk-0nvzdwwv.js.map} +1 -1
- package/dist/chunk-0t4b19w0.js +5 -0
- package/dist/chunk-0t4b19w0.js.map +10 -0
- package/dist/chunk-0xq80cr7.js +4 -0
- package/dist/chunk-0xq80cr7.js.map +10 -0
- package/dist/chunk-0zp3sbms.js +4 -0
- package/dist/chunk-0zp3sbms.js.map +10 -0
- package/dist/chunk-10897e1t.js +5 -0
- package/dist/chunk-10897e1t.js.map +10 -0
- package/dist/chunk-147gjb8j.js +4 -0
- package/dist/chunk-147gjb8j.js.map +10 -0
- package/dist/chunk-165evrks.js +4 -0
- package/dist/chunk-165evrks.js.map +10 -0
- package/dist/chunk-16pqbv30.js +4 -0
- package/dist/chunk-16pqbv30.js.map +10 -0
- package/dist/chunk-18akssnh.js +4 -0
- package/dist/chunk-18akssnh.js.map +10 -0
- package/dist/chunk-1d07epxn.js +4 -0
- package/dist/chunk-1d07epxn.js.map +10 -0
- package/dist/chunk-1d3brmyr.js +4 -0
- package/dist/{chunk-ef6dgp5k.js.map → chunk-1d3brmyr.js.map} +6 -6
- package/dist/chunk-1fenkptw.js +4 -0
- package/dist/chunk-1fenkptw.js.map +10 -0
- package/dist/chunk-1fpyfztm.js +4 -0
- package/dist/chunk-1fpyfztm.js.map +10 -0
- package/dist/chunk-1jr2awdv.js +4 -0
- package/dist/chunk-1jr2awdv.js.map +10 -0
- package/dist/chunk-1pjd7z7e.js +5 -0
- package/dist/chunk-1pjd7z7e.js.map +11 -0
- package/dist/chunk-1vxhaep8.js +4 -0
- package/dist/chunk-1vxhaep8.js.map +10 -0
- package/dist/chunk-1zje855e.js +4 -0
- package/dist/chunk-1zje855e.js.map +10 -0
- package/dist/chunk-2a6xtt8w.js +4 -0
- package/dist/chunk-2a6xtt8w.js.map +10 -0
- package/dist/chunk-2nbxbgja.js +4 -0
- package/dist/chunk-2nbxbgja.js.map +10 -0
- package/dist/chunk-2qek6vwk.js +5 -0
- package/dist/chunk-2qek6vwk.js.map +10 -0
- package/dist/chunk-2qs5hcvw.js +4 -0
- package/dist/chunk-2qs5hcvw.js.map +15 -0
- package/dist/chunk-2rpt28ng.js +4 -0
- package/dist/chunk-2rpt28ng.js.map +10 -0
- package/dist/chunk-2zbw9b4r.js +4 -0
- package/dist/chunk-2zbw9b4r.js.map +10 -0
- package/dist/chunk-3evg8b1k.js +4 -0
- package/dist/chunk-3evg8b1k.js.map +10 -0
- package/dist/chunk-3vasf2wf.js +4 -0
- package/dist/chunk-3vasf2wf.js.map +10 -0
- package/dist/chunk-3zmgkx0w.js +4 -0
- package/dist/chunk-3zmgkx0w.js.map +10 -0
- package/dist/chunk-44g267q3.js +77 -0
- package/dist/chunk-44g267q3.js.map +22 -0
- package/dist/chunk-4b5zjps1.js +4 -0
- package/dist/chunk-4b5zjps1.js.map +10 -0
- package/dist/chunk-4f60mvxv.js +4 -0
- package/dist/chunk-4f60mvxv.js.map +10 -0
- package/dist/chunk-4gam76xs.js +4 -0
- package/dist/chunk-4gam76xs.js.map +10 -0
- package/dist/chunk-4jzv24rt.js +4 -0
- package/dist/chunk-4jzv24rt.js.map +10 -0
- package/dist/chunk-4np6kjty.js +4 -0
- package/dist/chunk-4np6kjty.js.map +10 -0
- package/dist/chunk-4psr7qf1.js +4 -0
- package/dist/chunk-4psr7qf1.js.map +10 -0
- package/dist/chunk-4s350vgd.js +4 -0
- package/dist/chunk-4s350vgd.js.map +10 -0
- package/dist/chunk-4txy30je.js +4 -0
- package/dist/chunk-4txy30je.js.map +10 -0
- package/dist/chunk-4zq5qst4.js +4 -0
- package/dist/chunk-4zq5qst4.js.map +10 -0
- package/dist/chunk-54a103ah.js +4 -0
- package/dist/chunk-54a103ah.js.map +10 -0
- package/dist/chunk-58jyqcxt.js +4 -0
- package/dist/chunk-58jyqcxt.js.map +10 -0
- package/dist/chunk-59a4qnm6.js +4 -0
- package/dist/chunk-59a4qnm6.js.map +10 -0
- package/dist/chunk-5crks4mc.js +4 -0
- package/dist/chunk-5crks4mc.js.map +10 -0
- package/dist/chunk-5fs16qc2.js +4 -0
- package/dist/chunk-5fs16qc2.js.map +10 -0
- package/dist/chunk-5nb5v649.js +4 -0
- package/dist/chunk-5nb5v649.js.map +10 -0
- package/dist/chunk-5psj5g03.js +4 -0
- package/dist/chunk-5psj5g03.js.map +10 -0
- package/dist/chunk-5qa0wvgg.js +4 -0
- package/dist/chunk-5qa0wvgg.js.map +10 -0
- package/dist/chunk-5t6fd3qq.js +4 -0
- package/dist/chunk-5t6fd3qq.js.map +12 -0
- package/dist/chunk-5whsf328.js +4 -0
- package/dist/chunk-5whsf328.js.map +10 -0
- package/dist/chunk-612vvdg0.js +5 -0
- package/dist/chunk-612vvdg0.js.map +10 -0
- package/dist/chunk-61fr8e09.js +5 -0
- package/dist/chunk-61fr8e09.js.map +10 -0
- package/dist/chunk-629qemrx.js +4 -0
- package/dist/chunk-629qemrx.js.map +10 -0
- package/dist/chunk-65kp9t0w.js +4 -0
- package/dist/chunk-65kp9t0w.js.map +10 -0
- package/dist/chunk-66f14pqy.js +4 -0
- package/dist/chunk-66f14pqy.js.map +10 -0
- package/dist/chunk-69bs53j4.js +4 -0
- package/dist/chunk-69bs53j4.js.map +10 -0
- package/dist/chunk-6a16vs8y.js +4 -0
- package/dist/chunk-6a16vs8y.js.map +10 -0
- package/dist/chunk-6ant7bcg.js +5 -0
- package/dist/chunk-6ant7bcg.js.map +10 -0
- package/dist/chunk-6fvkzn8b.js +4 -0
- package/dist/chunk-6fvkzn8b.js.map +10 -0
- package/dist/chunk-6fvtad65.js +4 -0
- package/dist/chunk-6fvtad65.js.map +10 -0
- package/dist/chunk-6m11rfdt.js +4 -0
- package/dist/chunk-6m11rfdt.js.map +10 -0
- package/dist/chunk-6p5ty79g.js +4 -0
- package/dist/chunk-6p5ty79g.js.map +10 -0
- package/dist/chunk-6vzzwyt5.js +4 -0
- package/dist/chunk-6vzzwyt5.js.map +10 -0
- package/dist/chunk-6zfyy2sq.js +5 -0
- package/dist/chunk-6zfyy2sq.js.map +10 -0
- package/dist/chunk-73mtep9k.js +5 -0
- package/dist/chunk-73mtep9k.js.map +10 -0
- package/dist/chunk-76cxqdm5.js +4 -0
- package/dist/chunk-76cxqdm5.js.map +10 -0
- package/dist/chunk-76q7gcr7.js +4 -0
- package/dist/chunk-76q7gcr7.js.map +10 -0
- package/dist/chunk-77hx7jrk.js +4 -0
- package/dist/chunk-77hx7jrk.js.map +10 -0
- package/dist/chunk-7e7xv67y.js +4 -0
- package/dist/chunk-7e7xv67y.js.map +10 -0
- package/dist/chunk-7sj61wa1.js +4 -0
- package/dist/chunk-7sj61wa1.js.map +10 -0
- package/dist/chunk-7w7gd3mf.js +4 -0
- package/dist/chunk-7w7gd3mf.js.map +10 -0
- package/dist/chunk-7y71tyb6.js +4 -0
- package/dist/chunk-7y71tyb6.js.map +10 -0
- package/dist/chunk-7yw671gx.js +5 -0
- package/dist/chunk-7yw671gx.js.map +10 -0
- package/dist/chunk-81zgg7ah.js +4 -0
- package/dist/chunk-81zgg7ah.js.map +10 -0
- package/dist/chunk-82sj7aem.js +5 -0
- package/dist/chunk-82sj7aem.js.map +10 -0
- package/dist/chunk-83ngngpn.js +4 -0
- package/dist/chunk-83ngngpn.js.map +10 -0
- package/dist/chunk-88h3dfxg.js +4 -0
- package/dist/chunk-88h3dfxg.js.map +10 -0
- package/dist/chunk-88pbkfa6.js +4 -0
- package/dist/chunk-88pbkfa6.js.map +10 -0
- package/dist/chunk-8dj48k3f.js +4 -0
- package/dist/chunk-8dj48k3f.js.map +10 -0
- package/dist/chunk-8mmnj32j.js +4 -0
- package/dist/chunk-8mmnj32j.js.map +10 -0
- package/dist/chunk-8qf94hzv.js +4 -0
- package/dist/chunk-8qf94hzv.js.map +10 -0
- package/dist/chunk-8w9c6mxe.js +3 -0
- package/dist/chunk-8w9c6mxe.js.map +17 -0
- package/dist/chunk-93mkmwaj.js +4 -0
- package/dist/chunk-93mkmwaj.js.map +10 -0
- package/dist/chunk-96m5669w.js +4 -0
- package/dist/chunk-96m5669w.js.map +10 -0
- package/dist/chunk-9717ybek.js +4 -0
- package/dist/chunk-9717ybek.js.map +10 -0
- package/dist/chunk-997k48kg.js +4 -0
- package/dist/chunk-997k48kg.js.map +10 -0
- package/dist/chunk-9abm0pr9.js +4 -0
- package/dist/chunk-9abm0pr9.js.map +10 -0
- package/dist/chunk-9dz8xyy1.js +3 -0
- package/dist/{chunk-p9gc7ke6.js.map → chunk-9dz8xyy1.js.map} +4 -4
- package/dist/chunk-9f1r7zrg.js +4 -0
- package/dist/chunk-9f1r7zrg.js.map +10 -0
- package/dist/chunk-9fj0c4p1.js +4 -0
- package/dist/chunk-9fj0c4p1.js.map +10 -0
- package/dist/chunk-9mv0k6t0.js +4 -0
- package/dist/chunk-9mv0k6t0.js.map +11 -0
- package/dist/chunk-9q75e96q.js +4 -0
- package/dist/chunk-9q75e96q.js.map +10 -0
- package/dist/chunk-9s0w0gjc.js +4 -0
- package/dist/chunk-9s0w0gjc.js.map +10 -0
- package/dist/chunk-9seafyf3.js +4 -0
- package/dist/chunk-9seafyf3.js.map +10 -0
- package/dist/chunk-9tpfth1g.js +5 -0
- package/dist/chunk-9tpfth1g.js.map +10 -0
- package/dist/chunk-9vm0ck1e.js +4 -0
- package/dist/{chunk-kmfnx43s.js.map → chunk-9vm0ck1e.js.map} +2 -2
- package/dist/chunk-aanamgj7.js +4 -0
- package/dist/chunk-aanamgj7.js.map +10 -0
- package/dist/chunk-acfp8fm2.js +5 -0
- package/dist/chunk-acfp8fm2.js.map +10 -0
- package/dist/chunk-agf0k1k9.js +4 -0
- package/dist/chunk-agf0k1k9.js.map +10 -0
- package/dist/chunk-ajft9tzm.js +5 -0
- package/dist/chunk-ajft9tzm.js.map +10 -0
- package/dist/chunk-apgh9fht.js +4 -0
- package/dist/chunk-apgh9fht.js.map +10 -0
- package/dist/chunk-aq7h2jz2.js +4 -0
- package/dist/chunk-aq7h2jz2.js.map +10 -0
- package/dist/chunk-atx3b9qj.js +4 -0
- package/dist/chunk-atx3b9qj.js.map +10 -0
- package/dist/chunk-axa5gvjg.js +4 -0
- package/dist/chunk-axa5gvjg.js.map +10 -0
- package/dist/chunk-b44x5gst.js +4 -0
- package/dist/chunk-b44x5gst.js.map +10 -0
- package/dist/chunk-b7ap0z6v.js +4 -0
- package/dist/chunk-b7ap0z6v.js.map +10 -0
- package/dist/{chunk-35bsy26w.js → chunk-bajafpzj.js} +2 -2
- package/dist/{chunk-35bsy26w.js.map → chunk-bajafpzj.js.map} +1 -1
- package/dist/chunk-baxfcaes.js +5 -0
- package/dist/chunk-baxfcaes.js.map +10 -0
- package/dist/chunk-bbrwkw5y.js +4 -0
- package/dist/chunk-bbrwkw5y.js.map +13 -0
- package/dist/chunk-befwbt0h.js +5 -0
- package/dist/chunk-befwbt0h.js.map +14 -0
- package/dist/chunk-bej163fy.js +4 -0
- package/dist/chunk-bej163fy.js.map +10 -0
- package/dist/chunk-bfrzstr0.js +4 -0
- package/dist/chunk-bfrzstr0.js.map +10 -0
- package/dist/chunk-bgf2a50m.js +4 -0
- package/dist/chunk-bgf2a50m.js.map +10 -0
- package/dist/chunk-bk649aen.js +4 -0
- package/dist/chunk-bk649aen.js.map +10 -0
- package/dist/chunk-brsavvrn.js +4 -0
- package/dist/chunk-brsavvrn.js.map +10 -0
- package/dist/chunk-bwgwxgw8.js +4 -0
- package/dist/chunk-bwgwxgw8.js.map +10 -0
- package/dist/chunk-c7qx33ys.js +4 -0
- package/dist/chunk-c7qx33ys.js.map +10 -0
- package/dist/chunk-cb616xw5.js +4 -0
- package/dist/{chunk-ktwy9nyn.js.map → chunk-cb616xw5.js.map} +1 -1
- package/dist/chunk-ce7rcdsg.js +4 -0
- package/dist/chunk-ce7rcdsg.js.map +10 -0
- package/dist/chunk-ce89kst6.js +4 -0
- package/dist/chunk-ce89kst6.js.map +10 -0
- package/dist/chunk-cefrz6wd.js +4 -0
- package/dist/chunk-cefrz6wd.js.map +10 -0
- package/dist/chunk-cgfc4w0w.js +4 -0
- package/dist/chunk-cgfc4w0w.js.map +10 -0
- package/dist/chunk-chabgvmr.js +4 -0
- package/dist/chunk-chabgvmr.js.map +10 -0
- package/dist/chunk-cjsmqv12.js +4 -0
- package/dist/chunk-cjsmqv12.js.map +10 -0
- package/dist/chunk-d12swf8t.js +4 -0
- package/dist/chunk-d12swf8t.js.map +10 -0
- package/dist/chunk-d1vf91bx.js +5 -0
- package/dist/chunk-d1vf91bx.js.map +10 -0
- package/dist/chunk-d3vvh6x2.js +4 -0
- package/dist/chunk-d3vvh6x2.js.map +13 -0
- package/dist/chunk-d7zvjgvr.js +4 -0
- package/dist/{chunk-1gjhrqfe.js.map → chunk-d7zvjgvr.js.map} +5 -5
- package/dist/chunk-d87mx4t6.js +4 -0
- package/dist/chunk-d87mx4t6.js.map +13 -0
- package/dist/chunk-d8nm5ddh.js +7 -0
- package/dist/chunk-d8nm5ddh.js.map +65 -0
- package/dist/chunk-dgpcg2dh.js +5 -0
- package/dist/chunk-dgpcg2dh.js.map +10 -0
- package/dist/chunk-dhfkqc5x.js +4 -0
- package/dist/chunk-dhfkqc5x.js.map +10 -0
- package/dist/chunk-e5n4eyrc.js +4 -0
- package/dist/chunk-e5n4eyrc.js.map +10 -0
- package/dist/chunk-ec6tgefk.js +5 -0
- package/dist/chunk-ec6tgefk.js.map +10 -0
- package/dist/chunk-eddsdprs.js +5 -0
- package/dist/chunk-eddsdprs.js.map +10 -0
- package/dist/chunk-efkfryw1.js +4 -0
- package/dist/chunk-efkfryw1.js.map +10 -0
- package/dist/chunk-enbw3h06.js +4 -0
- package/dist/chunk-enbw3h06.js.map +10 -0
- package/dist/chunk-eqne9ppg.js +5 -0
- package/dist/chunk-eqne9ppg.js.map +10 -0
- package/dist/chunk-etcm6fh1.js +4 -0
- package/dist/chunk-etcm6fh1.js.map +10 -0
- package/dist/chunk-evmtw59h.js +4 -0
- package/dist/chunk-evmtw59h.js.map +10 -0
- package/dist/chunk-eytgtgtj.js +4 -0
- package/dist/chunk-eytgtgtj.js.map +10 -0
- package/dist/chunk-eza2c3t1.js +4 -0
- package/dist/chunk-eza2c3t1.js.map +10 -0
- package/dist/chunk-f08ksmq5.js +4 -0
- package/dist/chunk-f08ksmq5.js.map +10 -0
- package/dist/chunk-f48vajs9.js +4 -0
- package/dist/chunk-f48vajs9.js.map +10 -0
- package/dist/chunk-f6ypbp8s.js +4 -0
- package/dist/chunk-f6ypbp8s.js.map +10 -0
- package/dist/chunk-f867b961.js +4 -0
- package/dist/chunk-f867b961.js.map +10 -0
- package/dist/chunk-f9q2xx8j.js +4 -0
- package/dist/chunk-f9q2xx8j.js.map +10 -0
- package/dist/chunk-fb3xpd5h.js +4 -0
- package/dist/chunk-fb3xpd5h.js.map +10 -0
- package/dist/chunk-fc95wase.js +4 -0
- package/dist/chunk-fc95wase.js.map +10 -0
- package/dist/chunk-fqqhza9s.js +4 -0
- package/dist/chunk-fqqhza9s.js.map +10 -0
- package/dist/chunk-g28v2sg8.js +4 -0
- package/dist/chunk-g28v2sg8.js.map +10 -0
- package/dist/chunk-g3nnqcbw.js +5 -0
- package/dist/chunk-g3nnqcbw.js.map +10 -0
- package/dist/chunk-g5b9r81v.js +5 -0
- package/dist/chunk-g5b9r81v.js.map +10 -0
- package/dist/chunk-gj0zbz3g.js +4 -0
- package/dist/chunk-gj0zbz3g.js.map +10 -0
- package/dist/chunk-gn1cd35p.js +4 -0
- package/dist/chunk-gn1cd35p.js.map +10 -0
- package/dist/chunk-gprayftg.js +4 -0
- package/dist/chunk-gprayftg.js.map +10 -0
- package/dist/chunk-gr995e76.js +5 -0
- package/dist/chunk-gr995e76.js.map +10 -0
- package/dist/chunk-grva5cgq.js +4 -0
- package/dist/chunk-grva5cgq.js.map +10 -0
- package/dist/chunk-gtvgm63z.js +4 -0
- package/dist/chunk-gtvgm63z.js.map +10 -0
- package/dist/chunk-gwf5xs7m.js +18 -0
- package/dist/{chunk-qf6zg7nd.js.map → chunk-gwf5xs7m.js.map} +15 -34
- package/dist/chunk-gwnr2ycm.js +5 -0
- package/dist/chunk-gwnr2ycm.js.map +10 -0
- package/dist/chunk-gyxgxwcc.js +4 -0
- package/dist/chunk-gyxgxwcc.js.map +10 -0
- package/dist/chunk-h25tw54p.js +4 -0
- package/dist/chunk-h25tw54p.js.map +10 -0
- package/dist/chunk-h3tskj7j.js +4 -0
- package/dist/chunk-h3tskj7j.js.map +10 -0
- package/dist/chunk-hh62xvjr.js +4 -0
- package/dist/chunk-hh62xvjr.js.map +10 -0
- package/dist/chunk-hk1q1ep4.js +4 -0
- package/dist/chunk-hk1q1ep4.js.map +10 -0
- package/dist/chunk-hqhrt4re.js +5 -0
- package/dist/chunk-hqhrt4re.js.map +10 -0
- package/dist/chunk-hvk0d1ww.js +4 -0
- package/dist/chunk-hvk0d1ww.js.map +10 -0
- package/dist/chunk-j19xcy0f.js +4 -0
- package/dist/chunk-j19xcy0f.js.map +10 -0
- package/dist/chunk-j20akbzn.js +4 -0
- package/dist/chunk-j20akbzn.js.map +10 -0
- package/dist/chunk-j4xa9v2b.js +4 -0
- package/dist/chunk-j4xa9v2b.js.map +10 -0
- package/dist/chunk-jaywwzjq.js +4 -0
- package/dist/chunk-jaywwzjq.js.map +10 -0
- package/dist/chunk-jc7ftaka.js +4 -0
- package/dist/{chunk-ckds5kj4.js.map → chunk-jc7ftaka.js.map} +2 -2
- package/dist/chunk-jcs320db.js +4 -0
- package/dist/chunk-jcs320db.js.map +10 -0
- package/dist/chunk-jd1v2z6g.js +4 -0
- package/dist/chunk-jd1v2z6g.js.map +10 -0
- package/dist/chunk-jfrvg24q.js +4 -0
- package/dist/chunk-jfrvg24q.js.map +10 -0
- package/dist/chunk-jhxnydm7.js +5 -0
- package/dist/chunk-jhxnydm7.js.map +10 -0
- package/dist/chunk-jjt3mqyj.js +4 -0
- package/dist/chunk-jjt3mqyj.js.map +10 -0
- package/dist/chunk-jmv6j1ma.js +4 -0
- package/dist/chunk-jmv6j1ma.js.map +10 -0
- package/dist/chunk-jrg0k6fy.js +4 -0
- package/dist/chunk-jrg0k6fy.js.map +10 -0
- package/dist/chunk-k1gr1y2n.js +4 -0
- package/dist/chunk-k1gr1y2n.js.map +10 -0
- package/dist/chunk-k5903r56.js +4 -0
- package/dist/chunk-k5903r56.js.map +10 -0
- package/dist/chunk-k7er8zn9.js +5 -0
- package/dist/chunk-k7er8zn9.js.map +10 -0
- package/dist/chunk-k7seyqnj.js +5 -0
- package/dist/chunk-k7seyqnj.js.map +10 -0
- package/dist/chunk-keqxzdm8.js +4 -0
- package/dist/chunk-keqxzdm8.js.map +10 -0
- package/dist/chunk-kj73phvd.js +4 -0
- package/dist/chunk-kj73phvd.js.map +10 -0
- package/dist/chunk-kttqecab.js +4 -0
- package/dist/chunk-kttqecab.js.map +20 -0
- package/dist/chunk-kv6jab20.js +4 -0
- package/dist/chunk-kv6jab20.js.map +10 -0
- package/dist/chunk-m10rw8zf.js +4 -0
- package/dist/chunk-m10rw8zf.js.map +10 -0
- package/dist/chunk-m3x7ehjz.js +4 -0
- package/dist/chunk-m3x7ehjz.js.map +10 -0
- package/dist/chunk-m4ywwfhj.js +4 -0
- package/dist/chunk-m4ywwfhj.js.map +10 -0
- package/dist/chunk-m9xdm31a.js +5 -0
- package/dist/chunk-m9xdm31a.js.map +10 -0
- package/dist/chunk-mb5me03r.js +4 -0
- package/dist/chunk-mb5me03r.js.map +10 -0
- package/dist/chunk-mbhvesxn.js +4 -0
- package/dist/chunk-mbhvesxn.js.map +10 -0
- package/dist/chunk-md05dm8y.js +4 -0
- package/dist/{chunk-wfc30gdx.js.map → chunk-md05dm8y.js.map} +2 -2
- package/dist/chunk-mdwc3caf.js +4 -0
- package/dist/{chunk-en5bya0k.js.map → chunk-mdwc3caf.js.map} +2 -2
- package/dist/chunk-mq4xa8g0.js +4 -0
- package/dist/chunk-mq4xa8g0.js.map +10 -0
- package/dist/chunk-msarsnba.js +4 -0
- package/dist/chunk-msarsnba.js.map +10 -0
- package/dist/chunk-mtt5kfk0.js +4 -0
- package/dist/chunk-mtt5kfk0.js.map +10 -0
- package/dist/chunk-mtvvnps3.js +4 -0
- package/dist/chunk-mtvvnps3.js.map +10 -0
- package/dist/chunk-mww3xsh5.js +4 -0
- package/dist/chunk-mww3xsh5.js.map +10 -0
- package/dist/chunk-n0yg50tm.js +4 -0
- package/dist/chunk-n0yg50tm.js.map +10 -0
- package/dist/chunk-n15vbtzw.js +4 -0
- package/dist/chunk-n15vbtzw.js.map +10 -0
- package/dist/chunk-n1x0b75g.js +4 -0
- package/dist/chunk-n1x0b75g.js.map +10 -0
- package/dist/chunk-n6eekz6f.js +4 -0
- package/dist/chunk-n6eekz6f.js.map +10 -0
- package/dist/chunk-ng4pttb5.js +4 -0
- package/dist/chunk-ng4pttb5.js.map +10 -0
- package/dist/chunk-ngpkbmcy.js +4 -0
- package/dist/chunk-ngpkbmcy.js.map +10 -0
- package/dist/chunk-np64fgdg.js +4 -0
- package/dist/chunk-np64fgdg.js.map +10 -0
- package/dist/chunk-nshtq1ys.js +4 -0
- package/dist/chunk-nshtq1ys.js.map +10 -0
- package/dist/chunk-p2a7zrdj.js +4 -0
- package/dist/chunk-p2a7zrdj.js.map +10 -0
- package/dist/chunk-p7r1931r.js +4 -0
- package/dist/{chunk-hjr9ztvj.js.map → chunk-p7r1931r.js.map} +2 -2
- package/dist/chunk-pb70nyeg.js +4 -0
- package/dist/chunk-pb70nyeg.js.map +10 -0
- package/dist/chunk-pbgrf052.js +8 -0
- package/dist/chunk-pbgrf052.js.map +53 -0
- package/dist/chunk-pebk5hpa.js +4 -0
- package/dist/chunk-pebk5hpa.js.map +10 -0
- package/dist/chunk-pmtd0cc3.js +4 -0
- package/dist/chunk-pmtd0cc3.js.map +10 -0
- package/dist/chunk-q0fe3c44.js +4 -0
- package/dist/chunk-q0fe3c44.js.map +10 -0
- package/dist/chunk-q2btpck1.js +4 -0
- package/dist/chunk-q2btpck1.js.map +10 -0
- package/dist/chunk-q656e0z8.js +4 -0
- package/dist/chunk-q656e0z8.js.map +10 -0
- package/dist/chunk-q9q0m0fk.js +4 -0
- package/dist/chunk-q9q0m0fk.js.map +10 -0
- package/dist/chunk-qepjnnqp.js +4 -0
- package/dist/chunk-qepjnnqp.js.map +10 -0
- package/dist/chunk-qhxd2v41.js +4 -0
- package/dist/chunk-qhxd2v41.js.map +10 -0
- package/dist/chunk-qjepp6dz.js +4 -0
- package/dist/chunk-qjepp6dz.js.map +10 -0
- package/dist/chunk-r015e873.js +4 -0
- package/dist/chunk-r015e873.js.map +10 -0
- package/dist/chunk-r2wpm2d7.js +4 -0
- package/dist/chunk-r2wpm2d7.js.map +10 -0
- package/dist/chunk-r70xpzx4.js +4 -0
- package/dist/chunk-r70xpzx4.js.map +10 -0
- package/dist/chunk-r7qn7nya.js +4 -0
- package/dist/chunk-r7qn7nya.js.map +10 -0
- package/dist/chunk-r9fb428b.js +4 -0
- package/dist/chunk-r9fb428b.js.map +10 -0
- package/dist/chunk-raq3khzd.js +4 -0
- package/dist/chunk-raq3khzd.js.map +10 -0
- package/dist/chunk-rf60qjxw.js +5 -0
- package/dist/chunk-rf60qjxw.js.map +14 -0
- package/dist/chunk-rjjjt0eg.js +8 -0
- package/dist/{chunk-h1xm4rnm.js.map → chunk-rjjjt0eg.js.map} +2 -2
- package/dist/chunk-rjzrfj86.js +4 -0
- package/dist/chunk-rjzrfj86.js.map +10 -0
- package/dist/chunk-rm3pct07.js +4 -0
- package/dist/chunk-rm3pct07.js.map +10 -0
- package/dist/chunk-rmhs40sh.js +4 -0
- package/dist/chunk-rmhs40sh.js.map +10 -0
- package/dist/chunk-rqrezesz.js +4 -0
- package/dist/chunk-rqrezesz.js.map +10 -0
- package/dist/chunk-s0b5gyec.js +5 -0
- package/dist/chunk-s0b5gyec.js.map +10 -0
- package/dist/chunk-s0g6kddk.js +4 -0
- package/dist/chunk-s0g6kddk.js.map +10 -0
- package/dist/chunk-s4twrhpt.js +4 -0
- package/dist/chunk-s4twrhpt.js.map +10 -0
- package/dist/chunk-s5q7xgm7.js +4 -0
- package/dist/chunk-s5q7xgm7.js.map +10 -0
- package/dist/chunk-s6337cg6.js +4 -0
- package/dist/chunk-s6337cg6.js.map +10 -0
- package/dist/chunk-sarcnr78.js +5 -0
- package/dist/chunk-sarcnr78.js.map +10 -0
- package/dist/chunk-sgqzh2eh.js +4 -0
- package/dist/chunk-sgqzh2eh.js.map +10 -0
- package/dist/chunk-sh7q9p7c.js +4 -0
- package/dist/chunk-sh7q9p7c.js.map +10 -0
- package/dist/chunk-shvm8xpf.js +4 -0
- package/dist/chunk-shvm8xpf.js.map +10 -0
- package/dist/chunk-sm4gyh1f.js +4 -0
- package/dist/{chunk-dtkvdcf6.js.map → chunk-sm4gyh1f.js.map} +3 -7
- package/dist/chunk-sqdy9tjw.js +4 -0
- package/dist/chunk-sqdy9tjw.js.map +10 -0
- package/dist/chunk-stfzvxzh.js +5 -0
- package/dist/chunk-stfzvxzh.js.map +25 -0
- package/dist/chunk-sxt20n19.js +4 -0
- package/dist/chunk-sxt20n19.js.map +10 -0
- package/dist/chunk-t1mdzmvf.js +4 -0
- package/dist/{chunk-55xdqqbt.js.map → chunk-t1mdzmvf.js.map} +3 -14
- package/dist/chunk-t24w0gem.js +4 -0
- package/dist/chunk-t24w0gem.js.map +10 -0
- package/dist/chunk-t8pfwzwx.js +4 -0
- package/dist/chunk-t8pfwzwx.js.map +10 -0
- package/dist/chunk-t9fpc42w.js +4 -0
- package/dist/chunk-t9fpc42w.js.map +10 -0
- package/dist/chunk-ta1fz9d1.js +5 -0
- package/dist/chunk-ta1fz9d1.js.map +10 -0
- package/dist/chunk-thdwxt6w.js +4 -0
- package/dist/chunk-thdwxt6w.js.map +10 -0
- package/dist/chunk-tkgk80b9.js +4 -0
- package/dist/chunk-tkgk80b9.js.map +10 -0
- package/dist/chunk-twf1wr4h.js +4 -0
- package/dist/chunk-twf1wr4h.js.map +10 -0
- package/dist/chunk-v9kg2vy4.js +4 -0
- package/dist/{chunk-arbx49j6.js.map → chunk-v9kg2vy4.js.map} +5 -5
- package/dist/chunk-veamz5d0.js +4 -0
- package/dist/chunk-veamz5d0.js.map +10 -0
- package/dist/chunk-vf6yxr0r.js +4 -0
- package/dist/chunk-vf6yxr0r.js.map +10 -0
- package/dist/chunk-vh816yqy.js +4 -0
- package/dist/chunk-vh816yqy.js.map +10 -0
- package/dist/chunk-vnxja8xq.js +4 -0
- package/dist/chunk-vnxja8xq.js.map +10 -0
- package/dist/chunk-vpgsy207.js +4 -0
- package/dist/chunk-vpgsy207.js.map +10 -0
- package/dist/chunk-vqnvrsnc.js +4 -0
- package/dist/chunk-vqnvrsnc.js.map +10 -0
- package/dist/chunk-vx2ep3d6.js +5 -0
- package/dist/chunk-vx2ep3d6.js.map +10 -0
- package/dist/chunk-vybrcp16.js +4 -0
- package/dist/chunk-vybrcp16.js.map +10 -0
- package/dist/chunk-w100wbf2.js +11 -0
- package/dist/{chunk-r3qdswng.js.map → chunk-w100wbf2.js.map} +5 -5
- package/dist/chunk-w1d1dmx3.js +4 -0
- package/dist/chunk-w1d1dmx3.js.map +10 -0
- package/dist/chunk-w1nwkvbe.js +4 -0
- package/dist/chunk-w1nwkvbe.js.map +10 -0
- package/dist/chunk-w1zabjwt.js +4 -0
- package/dist/chunk-w1zabjwt.js.map +10 -0
- package/dist/chunk-w4hqdtab.js +4 -0
- package/dist/chunk-w4hqdtab.js.map +10 -0
- package/dist/chunk-w5tgtsfr.js +4 -0
- package/dist/chunk-w5tgtsfr.js.map +10 -0
- package/dist/chunk-w7ezjfcb.js +4 -0
- package/dist/chunk-w7ezjfcb.js.map +10 -0
- package/dist/chunk-w7mjxa9e.js +4 -0
- package/dist/chunk-w7mjxa9e.js.map +10 -0
- package/dist/chunk-w9h179q6.js +5 -0
- package/dist/chunk-w9h179q6.js.map +10 -0
- package/dist/chunk-wb75jnfp.js +4 -0
- package/dist/chunk-wb75jnfp.js.map +10 -0
- package/dist/chunk-wd9hmfa8.js +4 -0
- package/dist/chunk-wd9hmfa8.js.map +10 -0
- package/dist/chunk-wqmd1wv4.js +4 -0
- package/dist/chunk-wqmd1wv4.js.map +10 -0
- package/dist/chunk-wrz50ar3.js +4 -0
- package/dist/chunk-wrz50ar3.js.map +48 -0
- package/dist/chunk-wxgcwv7j.js +4 -0
- package/dist/chunk-wxgcwv7j.js.map +11 -0
- package/dist/chunk-wxw4254w.js +4 -0
- package/dist/{chunk-2n21sn7a.js.map → chunk-wxw4254w.js.map} +3 -4
- package/dist/chunk-wyc2ab1h.js +4 -0
- package/dist/chunk-wyc2ab1h.js.map +10 -0
- package/dist/chunk-wzbs51e4.js +4 -0
- package/dist/chunk-wzbs51e4.js.map +10 -0
- package/dist/chunk-x6248vkg.js +5 -0
- package/dist/chunk-x6248vkg.js.map +10 -0
- package/dist/{chunk-td079vg9.js → chunk-xajvm5dg.js} +3 -3
- package/dist/{chunk-td079vg9.js.map → chunk-xajvm5dg.js.map} +1 -1
- package/dist/chunk-xrteffkv.js +4 -0
- package/dist/chunk-xrteffkv.js.map +10 -0
- package/dist/chunk-xtc3sb35.js +5 -0
- package/dist/chunk-xtc3sb35.js.map +10 -0
- package/dist/chunk-xvfygk82.js +4 -0
- package/dist/{chunk-enc2835j.js.map → chunk-xvfygk82.js.map} +2 -2
- package/dist/chunk-xyagccth.js +4 -0
- package/dist/chunk-xyagccth.js.map +10 -0
- package/dist/chunk-y0msdehj.js +4 -0
- package/dist/chunk-y0msdehj.js.map +21 -0
- package/dist/chunk-y2zzprr2.js +4 -0
- package/dist/chunk-y2zzprr2.js.map +10 -0
- package/dist/chunk-y425gbw0.js +4 -0
- package/dist/{chunk-11by8vja.js.map → chunk-y425gbw0.js.map} +5 -5
- package/dist/chunk-y7q3vx60.js +4 -0
- package/dist/chunk-y7q3vx60.js.map +10 -0
- package/dist/chunk-y8vm6nhq.js +4 -0
- package/dist/chunk-y8vm6nhq.js.map +10 -0
- package/dist/chunk-ym3p77cw.js +4 -0
- package/dist/chunk-ym3p77cw.js.map +10 -0
- package/dist/chunk-yqq2hs5v.js +4 -0
- package/dist/chunk-yqq2hs5v.js.map +10 -0
- package/dist/chunk-ys2w3w3h.js +4 -0
- package/dist/chunk-ys2w3w3h.js.map +10 -0
- package/dist/chunk-yx2dstze.js +4 -0
- package/dist/chunk-yx2dstze.js.map +10 -0
- package/dist/chunk-yxb1tm10.js +5 -0
- package/dist/chunk-yxb1tm10.js.map +10 -0
- package/dist/chunk-yxngksdn.js +4 -0
- package/dist/chunk-yxngksdn.js.map +10 -0
- package/dist/chunk-yzf50f27.js +4 -0
- package/dist/chunk-yzf50f27.js.map +10 -0
- package/dist/chunk-z2536ve8.js +4 -0
- package/dist/chunk-z2536ve8.js.map +14 -0
- package/dist/chunk-z6d8dyj4.js +4 -0
- package/dist/{chunk-b6w0fgxz.js.map → chunk-z6d8dyj4.js.map} +2 -2
- package/dist/chunk-z73h9wcv.js +4 -0
- package/dist/chunk-z73h9wcv.js.map +10 -0
- package/dist/chunk-z744x29v.js +5 -0
- package/dist/chunk-z744x29v.js.map +10 -0
- package/dist/chunk-zajtvy67.js +4 -0
- package/dist/chunk-zajtvy67.js.map +10 -0
- package/dist/chunk-zgcwtt7q.js +4 -0
- package/dist/chunk-zgcwtt7q.js.map +10 -0
- package/dist/chunk-zt083h6w.js +4 -0
- package/dist/chunk-zt083h6w.js.map +10 -0
- package/dist/email/index.js +2 -2
- package/dist/email/index.js.map +26 -5
- package/dist/facades/index.js +2 -2
- package/dist/facades/index.js.map +2 -2
- package/dist/http/ApiRouter.d.ts +5 -0
- package/dist/http/ApiRouter.d.ts.map +1 -1
- package/dist/http/Controller.d.ts +0 -1
- package/dist/http/Controller.d.ts.map +1 -1
- package/dist/http/ViewRouter.d.ts.map +1 -1
- package/dist/http/index.js +2 -2
- package/dist/http/index.js.map +5 -5
- package/dist/kernel/index.js +2 -2
- package/dist/kernel/index.js.map +2 -2
- package/dist/server/index.js +2 -2
- package/dist/server/index.js.map +2 -2
- package/dist/services/index.js +2 -11
- package/dist/services/index.js.map +28 -15
- package/dist/vite/{index-Bu4AXBt9.mjs → index-C9AWJ7QP.mjs} +1 -1
- package/dist/vite/index.mjs +1 -1
- package/dist/vite/{typescript-D69Uqrn5.mjs → typescript-CKrglZ4F.mjs} +56 -48
- package/package.json +2 -2
- package/dist/chunk-11by8vja.js +0 -4
- package/dist/chunk-1gjhrqfe.js +0 -4
- package/dist/chunk-2n21sn7a.js +0 -4
- package/dist/chunk-55xdqqbt.js +0 -4
- package/dist/chunk-6vp2svxg.js +0 -4
- package/dist/chunk-6vp2svxg.js.map +0 -13
- package/dist/chunk-a67a5vtk.js +0 -4
- package/dist/chunk-arbx49j6.js +0 -4
- package/dist/chunk-b6w0fgxz.js +0 -4
- package/dist/chunk-ckds5kj4.js +0 -4
- package/dist/chunk-dtkvdcf6.js +0 -4
- package/dist/chunk-ef6dgp5k.js +0 -4
- package/dist/chunk-en5bya0k.js +0 -4
- package/dist/chunk-enc2835j.js +0 -4
- package/dist/chunk-gsrxf3xp.js +0 -5
- package/dist/chunk-gsrxf3xp.js.map +0 -64
- package/dist/chunk-h1xm4rnm.js +0 -8
- package/dist/chunk-hjr9ztvj.js +0 -4
- package/dist/chunk-kmfnx43s.js +0 -4
- package/dist/chunk-ktwy9nyn.js +0 -4
- package/dist/chunk-n7j3s0s0.js +0 -3
- package/dist/chunk-n7j3s0s0.js.map +0 -15
- package/dist/chunk-p9gc7ke6.js +0 -3
- package/dist/chunk-qf6zg7nd.js +0 -20
- package/dist/chunk-r3qdswng.js +0 -11
- package/dist/chunk-t3g9fdba.js +0 -5
- package/dist/chunk-t3g9fdba.js.map +0 -54
- package/dist/chunk-wfc30gdx.js +0 -4
- package/dist/chunk-z4ha0p3z.js +0 -4
- package/dist/chunk-z4ha0p3z.js.map +0 -10
package/dist/services/index.js
CHANGED
|
@@ -1,13 +1,4 @@
|
|
|
1
1
|
// @bun
|
|
2
|
-
import"../chunk-kmfnx43s.js";import{H as B}from"../chunk-ktwy9nyn.js";import{I as T}from"../chunk-td079vg9.js";import{O as _f,P as MA}from"../chunk-t3g9fdba.js";import{U as xg}from"../chunk-wfc30gdx.js";import{$ as er,Aa as tm,Ba as rg,Ca as wg,Da as dg,V as rs,W as Rs,X as Rg,Y as Sg,Z as Eg,_ as cg,aa as fr,ba as Ge,ca as Pg,da as hh,ea as mh,fa as gh,ga as wh,ha as kg,ia as jm,ja as im,ka as bm,la as xm,ma as Ng,na as Dg,oa as dh,pa as Tr,qa as Mr,ra as $g,sa as om,ta as nm,ua as yg,va as pm,wa as Ug,xa as Ls,ya as um,za as se}from"../chunk-qf6zg7nd.js";import{$a as Ur,Ea as ag,Fa as hg,Ga as L,Ha as Es,Ia as ls,La as Vr,Ma as Y,Na as Wm,Oa as Ss,Pa as Ig,Qa as Qm,Ra as Xm,Sa as Zm,Ta as cr,Ua as Ym,Va as Om,Wa as Er,Xa as Vm,Ya as ea,Za as fa,_a as Kh,ab as Z,cb as br,fb as Dr,gb as Lh,hb as $r,ib as Wh,jb as qs,kb as qr,mb as Nf,nb as Qr,ob as Ph,pb as i,qb as Qh,rb as _m,sb as qm,tb as mg,ub as gg,wb as G,yb as Xh}from"../chunk-gsrxf3xp.js";import{Ab as Rw}from"../chunk-z4ha0p3z.js";import{Bb as q,Cb as Jm}from"../chunk-1gjhrqfe.js";import"../chunk-n7j3s0s0.js";import{Jb as sg}from"../chunk-r3qdswng.js";import"../chunk-p9gc7ke6.js";class mr{}class ss extends mr{r;constructor(r=`${process.env.ROOT_DIR}/storage`){super();this.folderPath=r}async put(r){let s,e;if(r instanceof Blob)s=r,e=`${rs()}.${r.type.split("/")[1].split(";")[0]}`;else s=r.body,e=r.name;const f=s instanceof Buffer?s:Buffer.from(await s.arrayBuffer()),l=`${this.folderPath}/${e}`;return await Bun.write(l,f),e}async fetch(r){let s=process.env.BUCKET_NAME,e;if(typeof r==="string")e=r;else s=r.bucket??s,e=r.name;if(!e)throw new Error("Object name has to be specified");const f=`${this.folderPath}/${e}`,l=Bun.file(f),a=Bun.file(f).stream(),h=new Date(l.lastModified).toUTCString();return new Response(a,{headers:{"Content-Type":l.type,"Content-Length":String(l.size),"Cache-Control":"private, max-age=12000, must-revalidate","Last-Modified":h}})}}class qf extends B{driver=new ss;boot(){}}function Og(r){return(s)=>async(e)=>{const{request:f}=e;if(L.isInstance(f)&&f.body&&r.runtime==="node"){if(r.requestHandler?.constructor?.name!=="FetchHttpHandler")f.headers={...f.headers,Expect:"100-continue"}}return s({...e,request:f})}}var _g={step:"build",tags:["SET_EXPECT_HEADER","EXPECT_HEADER"],name:"addExpectContinueMiddleware",override:!0},jf=(r)=>({applyToStack:(s)=>{s.add(Og(r),_g)}});var Gr={WHEN_SUPPORTED:"WHEN_SUPPORTED",WHEN_REQUIRED:"WHEN_REQUIRED"},es=Gr.WHEN_SUPPORTED,Ae={WHEN_SUPPORTED:"WHEN_SUPPORTED",WHEN_REQUIRED:"WHEN_REQUIRED"},fs=Gr.WHEN_SUPPORTED,U;(function(r){r.MD5="MD5",r.CRC32="CRC32",r.CRC32C="CRC32C",r.SHA1="SHA1",r.SHA256="SHA256"})(U||(U={}));var bf;(function(r){r.HEADER="header",r.TRAILER="trailer"})(bf||(bf={}));var{MD5:xf,CRC32:of}=U;var o;(function(r){r.ENV="env",r.CONFIG="shared config entry"})(o||(o={}));var gr=(r,s,e,f)=>{if(!(s in r))return;const l=r[s].toUpperCase();if(!Object.values(e).includes(l))throw new TypeError(`Cannot load ${f} '${s}'. Expected one of ${Object.values(e)}, got '${r[s]}'.`);return l};var qg="AWS_REQUEST_CHECKSUM_CALCULATION",jg="request_checksum_calculation",nf={environmentVariableSelector:(r)=>gr(r,qg,Gr,o.ENV),configFileSelector:(r)=>gr(r,jg,Gr,o.CONFIG),default:es};var ig="AWS_RESPONSE_CHECKSUM_VALIDATION",bg="response_checksum_validation",pf={environmentVariableSelector:(r)=>gr(r,ig,Ae,o.ENV),configFileSelector:(r)=>gr(r,bg,Ae,o.CONFIG),default:fs};var zr=[U.CRC32,U.CRC32C,U.SHA1,U.SHA256],uf=[U.CRC32,U.CRC32C,U.SHA1,U.SHA256];var tf=(r,{requestChecksumRequired:s,requestAlgorithmMember:e},f)=>{const l=f?of:xf;if(!e||!r[e])return s?l:void 0;const a=r[e];if(!zr.includes(a))throw new Error(`The checksum algorithm "${a}" is not supported by the client. Select one of ${zr}.`);return a};var wr=(r)=>r===U.MD5?"content-md5":`x-amz-checksum-${r.toLowerCase()}`;var rl=(r,s)=>{const e=r.toLowerCase();for(let f of Object.keys(s))if(e===f.toLowerCase())return!0;return!1};var dr=(r)=>r!==void 0&&typeof r!=="string"&&!ArrayBuffer.isView(r)&&!ls(r);var sl=T(xg(),1),{__extends:yR,__assign:UR,__rest:TR,__decorate:MR,__param:CR,__esDecorate:HR,__runInitializers:vR,__propKey:GR,__setFunctionName:zR,__metadata:FR,__awaiter:as,__generator:hs,__exportStar:KR,__createBinding:LR,__values:ms,__read:WR,__spread:QR,__spreadArrays:XR,__spreadArray:ZR,__await:VR,__asyncGenerator:JR,__asyncDelegator:BR,__asyncValues:YR,__makeTemplateObject:OR,__importStar:_R,__importDefault:qR,__classPrivateFieldGet:jR,__classPrivateFieldSet:iR,__classPrivateFieldIn:bR,__addDisposableResource:xR,__disposeResources:oR}=sl.default;import{Buffer as el}from"buffer";var fl=(r,s)=>{if(typeof r!=="string")throw new TypeError(`The "input" argument must be of type string. Received type ${typeof r} (${r})`);return s?el.from(r,s):el.from(r)};var Re=(r)=>{const s=fl(r,"utf8");return new Uint8Array(s.buffer,s.byteOffset,s.byteLength/Uint8Array.BYTES_PER_ELEMENT)};function Fr(r){if(r instanceof Uint8Array)return r;if(typeof r==="string")return og(r);if(ArrayBuffer.isView(r))return new Uint8Array(r.buffer,r.byteOffset,r.byteLength/Uint8Array.BYTES_PER_ELEMENT);return new Uint8Array(r)}var og=typeof Buffer!=="undefined"&&Buffer.from?function(r){return Buffer.from(r,"utf8")}:Re;function Kr(r){if(typeof r==="string")return r.length===0;return r.byteLength===0}function Lr(r){return new Uint8Array([(r&4278190080)>>24,(r&16711680)>>16,(r&65280)>>8,r&255])}function Wr(r){if(!Uint32Array.from){var s=new Uint32Array(r.length),e=0;while(e<r.length)s[e]=r[e],e+=1;return s}return Uint32Array.from(r)}var Se=function(){function r(){this.crc32=new sr}return r.prototype.update=function(s){if(Kr(s))return;this.crc32.update(Fr(s))},r.prototype.digest=function(){return as(this,void 0,void 0,function(){return hs(this,function(s){return[2,Lr(this.crc32.digest())]})})},r.prototype.reset=function(){this.crc32=new sr},r}();var sr=function(){function r(){this.checksum=4294967295}return r.prototype.update=function(s){var e,f;try{for(var l=ms(s),a=l.next();!a.done;a=l.next()){var h=a.value;this.checksum=this.checksum>>>8^pg[(this.checksum^h)&255]}}catch(m){e={error:m}}finally{try{if(a&&!a.done&&(f=l.return))f.call(l)}finally{if(e)throw e.error}}return this},r.prototype.digest=function(){return(this.checksum^4294967295)>>>0},r}();var ng=[0,1996959894,3993919788,2567524794,124634137,1886057615,3915621685,2657392035,249268274,2044508324,3772115230,2547177864,162941995,2125561021,3887607047,2428444049,498536548,1789927666,4089016648,2227061214,450548861,1843258603,4107580753,2211677639,325883990,1684777152,4251122042,2321926636,335633487,1661365465,4195302755,2366115317,997073096,1281953886,3579855332,2724688242,1006888145,1258607687,3524101629,2768942443,901097722,1119000684,3686517206,2898065728,853044451,1172266101,3705015759,2882616665,651767980,1373503546,3369554304,3218104598,565507253,1454621731,3485111705,3099436303,671266974,1594198024,3322730930,2970347812,795835527,1483230225,3244367275,3060149565,1994146192,31158534,2563907772,4023717930,1907459465,112637215,2680153253,3904427059,2013776290,251722036,2517215374,3775830040,2137656763,141376813,2439277719,3865271297,1802195444,476864866,2238001368,4066508878,1812370925,453092731,2181625025,4111451223,1706088902,314042704,2344532202,4240017532,1658658271,366619977,2362670323,4224994405,1303535960,984961486,2747007092,3569037538,1256170817,1037604311,2765210733,3554079995,1131014506,879679996,2909243462,3663771856,1141124467,855842277,2852801631,3708648649,1342533948,654459306,3188396048,3373015174,1466479909,544179635,3110523913,3462522015,1591671054,702138776,2966460450,3352799412,1504918807,783551873,3082640443,3233442989,3988292384,2596254646,62317068,1957810842,3939845945,2647816111,81470997,1943803523,3814918930,2489596804,225274430,2053790376,3826175755,2466906013,167816743,2097651377,4027552580,2265490386,503444072,1762050814,4150417245,2154129355,426522225,1852507879,4275313526,2312317920,282753626,1742555852,4189708143,2394877945,397917763,1622183637,3604390888,2714866558,953729732,1340076626,3518719985,2797360999,1068828381,1219638859,3624741850,2936675148,906185462,1090812512,3747672003,2825379669,829329135,1181335161,3412177804,3160834842,628085408,1382605366,3423369109,3138078467,570562233,1426400815,3317316542,2998733608,733239954,1555261956,3268935591,3050360625,752459403,1541320221,2607071920,3965973030,1969922972,40735498,2617837225,3943577151,1913087877,83908371,2512341634,3803740692,2075208622,213261112,2463272603,3855990285,2094854071,198958881,2262029012,4057260610,1759359992,534414190,2176718541,4139329115,1873836001,414664567,2282248934,4279200368,1711684554,285281116,2405801727,4167216745,1634467795,376229701,2685067896,3608007406,1308918612,956543938,2808555105,3495958263,1231636301,1047427035,2932959818,3654703836,1088359270,936918000,2847714899,3736837829,1202900863,817233897,3183342108,3401237130,1404277552,615818150,3134207493,3453421203,1423857449,601450431,3009837614,3294710456,1567103746,711928724,3020668471,3272380065,1510334235,755167117],pg=Wr(ng);var ce=function(){function r(){this.crc32c=new Ee}return r.prototype.update=function(s){if(Kr(s))return;this.crc32c.update(Fr(s))},r.prototype.digest=function(){return as(this,void 0,void 0,function(){return hs(this,function(s){return[2,Lr(this.crc32c.digest())]})})},r.prototype.reset=function(){this.crc32c=new Ee},r}();var Ee=function(){function r(){this.checksum=4294967295}return r.prototype.update=function(s){var e,f;try{for(var l=ms(s),a=l.next();!a.done;a=l.next()){var h=a.value;this.checksum=this.checksum>>>8^tg[(this.checksum^h)&255]}}catch(m){e={error:m}}finally{try{if(a&&!a.done&&(f=l.return))f.call(l)}finally{if(e)throw e.error}}return this},r.prototype.digest=function(){return(this.checksum^4294967295)>>>0},r}();var ug=[0,4067132163,3778769143,324072436,3348797215,904991772,648144872,3570033899,2329499855,2024987596,1809983544,2575936315,1296289744,3207089363,2893594407,1578318884,274646895,3795141740,4049975192,51262619,3619967088,632279923,922689671,3298075524,2592579488,1760304291,2075979607,2312596564,1562183871,2943781820,3156637768,1313733451,549293790,3537243613,3246849577,871202090,3878099393,357341890,102525238,4101499445,2858735121,1477399826,1264559846,3107202533,1845379342,2677391885,2361733625,2125378298,820201905,3263744690,3520608582,598981189,4151959214,85089709,373468761,3827903834,3124367742,1213305469,1526817161,2842354314,2107672161,2412447074,2627466902,1861252501,1098587580,3004210879,2688576843,1378610760,2262928035,1955203488,1742404180,2511436119,3416409459,969524848,714683780,3639785095,205050476,4266873199,3976438427,526918040,1361435347,2739821008,2954799652,1114974503,2529119692,1691668175,2005155131,2247081528,3690758684,697762079,986182379,3366744552,476452099,3993867776,4250756596,255256311,1640403810,2477592673,2164122517,1922457750,2791048317,1412925310,1197962378,3037525897,3944729517,427051182,170179418,4165941337,746937522,3740196785,3451792453,1070968646,1905808397,2213795598,2426610938,1657317369,3053634322,1147748369,1463399397,2773627110,4215344322,153784257,444234805,3893493558,1021025245,3467647198,3722505002,797665321,2197175160,1889384571,1674398607,2443626636,1164749927,3070701412,2757221520,1446797203,137323447,4198817972,3910406976,461344835,3484808360,1037989803,781091935,3705997148,2460548119,1623424788,1939049696,2180517859,1429367560,2807687179,3020495871,1180866812,410100952,3927582683,4182430767,186734380,3756733383,763408580,1053836080,3434856499,2722870694,1344288421,1131464017,2971354706,1708204729,2545590714,2229949006,1988219213,680717673,3673779818,3383336350,1002577565,4010310262,493091189,238226049,4233660802,2987750089,1082061258,1395524158,2705686845,1972364758,2279892693,2494862625,1725896226,952904198,3399985413,3656866545,731699698,4283874585,222117402,510512622,3959836397,3280807620,837199303,582374963,3504198960,68661723,4135334616,3844915500,390545967,1230274059,3141532936,2825850620,1510247935,2395924756,2091215383,1878366691,2644384480,3553878443,565732008,854102364,3229815391,340358836,3861050807,4117890627,119113024,1493875044,2875275879,3090270611,1247431312,2660249211,1828433272,2141937292,2378227087,3811616794,291187481,34330861,4032846830,615137029,3603020806,3314634738,939183345,1776939221,2609017814,2295496738,2058945313,2926798794,1545135305,1330124605,3173225534,4084100981,17165430,307568514,3762199681,888469610,3332340585,3587147933,665062302,2042050490,2346497209,2559330125,1793573966,3190661285,1279665062,1595330642,2910671697],tg=Wr(ug);var gs=(r,s)=>({[U.MD5]:s.md5,[U.CRC32]:Se,[U.CRC32C]:ce,[U.SHA1]:s.sha1,[U.SHA256]:s.sha256})[r];var ws=(r,s)=>{const e=new r;return e.update(Y(s||"")),e.digest()};var ll={name:"flexibleChecksumsMiddleware",step:"build",tags:["BODY_CHECKSUM"],override:!0},al=(r,s)=>(e,f)=>async(l)=>{if(!L.isInstance(l.request))return e(l);const{request:a}=l,{body:h,headers:m}=a,{base64Encoder:g,streamHasher:w}=r,{input:E,requestChecksumRequired:I,requestAlgorithmMember:P}=s,N=tf(E,{requestChecksumRequired:I,requestAlgorithmMember:P},!!f.isS3ExpressBucket);let y=h,V=m;if(N){const b=wr(N),vr=gs(N,r);if(dr(h)){const{getAwsChunkedEncodingStream:de,bodyLengthChecker:Yg}=r;y=de(h,{base64Encoder:g,bodyLengthChecker:Yg,checksumLocationName:b,checksumAlgorithmFn:vr,streamHasher:w}),V={...m,"content-encoding":m["content-encoding"]?`${m["content-encoding"]},aws-chunked`:"aws-chunked","transfer-encoding":"chunked","x-amz-decoded-content-length":m["content-length"],"x-amz-content-sha256":"STREAMING-UNSIGNED-PAYLOAD-TRAILER","x-amz-trailer":b},delete V["content-length"]}else if(!rl(b,m)){const de=await ws(vr,h);V={...m,[b]:g(de)}}}return await e({...l,request:{...a,headers:V,body:y}})};var ds=(r=[])=>{const s=[];for(let e of uf){if(!r.includes(e)||!zr.includes(e))continue;s.push(e)}return s};var hl=(r)=>{const s=r.lastIndexOf("-");if(s!==-1){const e=r.slice(s+1);if(!e.startsWith("0")){const f=parseInt(e,10);if(!isNaN(f)&&f>=1&&f<=1e4)return!0}}return!1};import{Transform as rw}from"stream";function Ie(r){const s=new rw;return s.push(r),s.push(null),s}var ml=async(r,{streamHasher:s,checksumAlgorithmFn:e,base64Encoder:f})=>{const l=dr(r)?s(e,r):ws(e,r);return f(await l)};var gl=async(r,{config:s,responseAlgorithms:e})=>{const f=ds(e),{body:l,headers:a}=r;for(let h of f){const m=wr(h),g=a[m];if(g){const w=gs(h,s),{streamHasher:E,base64Encoder:I}=s,P=await ml(l,{streamHasher:E,checksumAlgorithmFn:w,base64Encoder:I});if(P===g)break;throw new Error(`Checksum mismatch: expected "${P}" but received "${g}" in response header "${m}".`)}}};var wl={name:"flexibleChecksumsResponseMiddleware",toMiddleware:"deserializerMiddleware",relation:"after",tags:["BODY_CHECKSUM"],override:!0},dl=(r,s)=>(e,f)=>async(l)=>{if(!L.isInstance(l.request))return e(l);const a=l.input,h=await e(l),m=h.response;let g=void 0;const{requestValidationModeMember:w,responseAlgorithms:E}=s;if(w&&a[w]==="ENABLED"){const{clientName:I,commandName:P}=f;if(I==="S3Client"&&P==="GetObjectCommand"&&ds(E).every((V)=>{const tr=wr(V),b=m.headers[tr];return!b||hl(b)}))return h;const y=dr(m.body);if(y)g=await r.streamCollector(m.body),m.body=Ie(g);if(await gl(h.response,{config:r,responseAlgorithms:E}),y&&g)m.body=Ie(g)}return h};var As=(r,s)=>({applyToStack:(e)=>{e.add(al(r,s),ll),e.addRelativeTo(dl(r,s),wl)}});var Pe=T(Rs(),1);var Al=(r)=>({...r,requestChecksumCalculation:Pe.normalizeProvider(r.requestChecksumCalculation??es),responseChecksumValidation:Pe.normalizeProvider(r.responseChecksumValidation??fs)});function ew(){return(r,s)=>async(e)=>{const{request:f}=e;if(L.isInstance(f)){if(!(sw in f.headers))if(typeof s?.logger?.warn==="function"&&!(s.logger instanceof Ss))s.logger.warn("Are you using a Stream of unknown length as the Body of a PutObject request? Consider using Upload instead from @aws-sdk/lib-storage.");else console.warn("Are you using a Stream of unknown length as the Body of a PutObject request? Consider using Upload instead from @aws-sdk/lib-storage.")}return r({...e})}}var sw="content-length",fw={step:"finalizeRequest",tags:["CHECK_CONTENT_LENGTH_HEADER"],name:"getCheckContentLengthHeaderPlugin",override:!0},Rl=(r)=>({applyToStack:(s)=>{s.add(ew(),fw)}});var Sl=(r)=>{return(s,e)=>async(f)=>{const l=await r.region(),a=r.region;let h=()=>{};if(e.__s3RegionRedirect)Object.defineProperty(r,"region",{writable:!1,value:async()=>{return e.__s3RegionRedirect}}),h=()=>Object.defineProperty(r,"region",{writable:!0,value:a});try{const m=await s(f);if(e.__s3RegionRedirect){h();const g=await r.region();if(l!==g)throw new Error("Region was not restored following S3 region redirect.")}return m}catch(m){throw h(),m}}},El={tags:["REGION_REDIRECT","S3"],name:"regionRedirectEndpointMiddleware",override:!0,relation:"before",toMiddleware:"endpointV2Middleware"};function lw(r){return(s,e)=>async(f)=>{try{return await s(f)}catch(l){if(r.followRegionRedirects&&l?.$metadata?.httpStatusCode===301){try{const a=l.$response.headers["x-amz-bucket-region"];e.logger?.debug(`Redirecting from ${await r.region()} to ${a}`),e.__s3RegionRedirect=a}catch(a){throw new Error("Region redirect failed: "+a)}return s(f)}else throw l}}}var aw={step:"initialize",tags:["REGION_REDIRECT","S3"],name:"regionRedirectMiddleware",override:!0},cl=(r)=>({applyToStack:(s)=>{s.add(lw(r),aw),s.addRelativeTo(Sl(r),El)}});var hw=(r)=>{return(s,e)=>async(f)=>{const l=await s(f),{response:a}=l;if(Es.isInstance(a)){if(a.headers.expires){a.headers.expiresstring=a.headers.expires;try{Qr(a.headers.expires)}catch(h){e.logger?.warn(`AWS SDK Warning for ${e.clientName}::${e.commandName} response parsing (${a.headers.expires}): ${h}`),delete a.headers.expires}}}return l}},mw={tags:["S3"],name:"s3ExpiresMiddleware",override:!0,relation:"after",toMiddleware:"deserializerMiddleware"},Il=(r)=>({applyToStack:(s)=>{s.addRelativeTo(hw(r),mw)}});class Ar{constructor(r={}){this.data=r,this.lastPurgeTime=Date.now()}get(r){const s=this.data[r];if(!s)return;return s}set(r,s){return this.data[r]=s,s}delete(r){delete this.data[r]}async purgeExpired(){const r=Date.now();if(this.lastPurgeTime+Ar.EXPIRED_CREDENTIAL_PURGE_INTERVAL_MS>r)return;for(let s in this.data){const e=this.data[s];if(!e.isRefreshing){const f=await e.identity;if(f.expiration){if(f.expiration.getTime()<r)delete this.data[s]}}}}}Ar.EXPIRED_CREDENTIAL_PURGE_INTERVAL_MS=30000;class Rr{constructor(r,s=!1,e=Date.now()){this._identity=r,this.isRefreshing=s,this.accessed=e}get identity(){return this.accessed=Date.now(),this._identity}}class Sr{constructor(r,s=new Ar){this.createSessionFn=r,this.cache=s}async getS3ExpressIdentity(r,s){const e=s.Bucket,{cache:f}=this,l=f.get(e);if(l)return l.identity.then((a)=>{if((a.expiration?.getTime()??0)<Date.now())return f.set(e,new Rr(this.getIdentity(e))).identity;if((a.expiration?.getTime()??0)<Date.now()+Sr.REFRESH_WINDOW_MS&&!l.isRefreshing)l.isRefreshing=!0,this.getIdentity(e).then((g)=>{f.set(e,new Rr(Promise.resolve(g)))});return a});return f.set(e,new Rr(this.getIdentity(e))).identity}async getIdentity(r){await this.cache.purgeExpired().catch((f)=>{console.warn("Error while clearing expired entries in S3ExpressIdentityCache: \n"+f)});const s=await this.createSessionFn(r);if(!s.Credentials?.AccessKeyId||!s.Credentials?.SecretAccessKey)throw new Error("s3#createSession response credential missing AccessKeyId or SecretAccessKey.");return{accessKeyId:s.Credentials.AccessKeyId,secretAccessKey:s.Credentials.SecretAccessKey,sessionToken:s.Credentials.SessionToken,expiration:s.Credentials.Expiration?new Date(s.Credentials.Expiration):void 0}}}Sr.REFRESH_WINDOW_MS=60000;var Jr=T(Er(),1),Me=T(Rs(),1);var Pl="X-Amz-Algorithm",kl="X-Amz-Credential",Nl="X-Amz-Date",Dl="X-Amz-SignedHeaders",$l="X-Amz-Expires",yl="X-Amz-Signature",Ul="X-Amz-Security-Token";var Tl="authorization",ke="X-Amz-Date".toLowerCase();var Ml=["authorization",ke,"date"],Cl="X-Amz-Signature".toLowerCase(),Xr="x-amz-content-sha256",Hl="X-Amz-Security-Token".toLowerCase();var vl={authorization:!0,"cache-control":!0,connection:!0,expect:!0,from:!0,"keep-alive":!0,"max-forwards":!0,pragma:!0,referer:!0,te:!0,trailer:!0,"transfer-encoding":!0,upgrade:!0,"user-agent":!0,"x-amzn-trace-id":!0},Gl=/^proxy-/,zl=/^sec-/;var cs="AWS4-HMAC-SHA256";var Fl="AWS4-HMAC-SHA256-PAYLOAD",Kl="UNSIGNED-PAYLOAD",Ll=50,Ne="aws4_request",Wl=604800;var Xl=T(Er(),1);var Is={},De=[],Ps=(r,s,e)=>`${r}/${s}/${e}/${Ne}`,Zl=async(r,s,e,f,l)=>{const a=await Ql(r,s.secretAccessKey,s.accessKeyId),h=`${e}:${f}:${l}:${Xl.toHex(a)}:${s.sessionToken}`;if(h in Is)return Is[h];De.push(h);while(De.length>Ll)delete Is[De.shift()];let m=`AWS4${s.secretAccessKey}`;for(let g of[e,f,l,Ne])m=await Ql(r,m,g);return Is[h]=m};var Ql=(r,s,e)=>{const f=new r(s);return f.update(Y(e)),f.digest()};var ks=({headers:r},s,e)=>{const f={};for(let l of Object.keys(r).sort()){if(r[l]==null)continue;const a=l.toLowerCase();if(a in vl||s?.has(a)||Gl.test(a)||zl.test(a)){if(!e||e&&!e.has(a))continue}f[a]=r[l].trim().replace(/\s+/g," ")}return f};var $e=({query:r={}})=>{const s=[],e={};for(let f of Object.keys(r)){if(f.toLowerCase()===Cl)continue;const l=cr(f);s.push(l);const a=r[f];if(typeof a==="string")e[l]=`${l}=${cr(a)}`;else if(Array.isArray(a))e[l]=a.slice(0).reduce((h,m)=>h.concat([`${l}=${cr(m)}`]),[]).sort().join("&")}return s.sort().map((f)=>e[f]).filter((f)=>f).join("&")};var Vl=T(Er(),1);var Zr=async({headers:r,body:s},e)=>{for(let f of Object.keys(r))if(f.toLowerCase()===Xr)return r[f];if(s==null)return"e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855";else if(typeof s==="string"||ArrayBuffer.isView(s)||ls(s)){const f=new e;return f.update(Y(s)),Vl.toHex(await f.digest())}return Kl};var Ns=T(Er(),1);function Bl(r){for(let s=0;s<8;s++)r[s]^=255;for(let s=7;s>-1;s--)if(r[s]++,r[s]!==0)break}class ye{format(r){const s=[];for(let l of Object.keys(r)){const a=Vr(l);s.push(Uint8Array.from([a.byteLength]),a,this.formatHeaderValue(r[l]))}const e=new Uint8Array(s.reduce((l,a)=>l+a.byteLength,0));let f=0;for(let l of s)e.set(l,f),f+=l.byteLength;return e}formatHeaderValue(r){switch(r.type){case"boolean":return Uint8Array.from([r.value?0:1]);case"byte":return Uint8Array.from([2,r.value]);case"short":const s=new DataView(new ArrayBuffer(3));return s.setUint8(0,3),s.setInt16(1,r.value,!1),new Uint8Array(s.buffer);case"integer":const e=new DataView(new ArrayBuffer(5));return e.setUint8(0,4),e.setInt32(1,r.value,!1),new Uint8Array(e.buffer);case"long":const f=new Uint8Array(9);return f[0]=5,f.set(r.value.bytes,1),f;case"binary":const l=new DataView(new ArrayBuffer(3+r.value.byteLength));l.setUint8(0,6),l.setUint16(1,r.value.byteLength,!1);const a=new Uint8Array(l.buffer);return a.set(r.value,3),a;case"string":const h=Vr(r.value),m=new DataView(new ArrayBuffer(3+h.byteLength));m.setUint8(0,7),m.setUint16(1,h.byteLength,!1);const g=new Uint8Array(m.buffer);return g.set(h,3),g;case"timestamp":const w=new Uint8Array(9);return w[0]=8,w.set(Ue.fromNumber(r.value.valueOf()).bytes,1),w;case"uuid":if(!gw.test(r.value))throw new Error(`Invalid UUID received: ${r.value}`);const E=new Uint8Array(17);return E[0]=9,E.set(Ns.fromHex(r.value.replace(/\-/g,"")),1),E}}}var Jl;(function(r){r[r.boolTrue=0]="boolTrue",r[r.boolFalse=1]="boolFalse",r[r.byte=2]="byte",r[r.short=3]="short",r[r.integer=4]="integer",r[r.long=5]="long",r[r.byteArray=6]="byteArray",r[r.string=7]="string",r[r.timestamp=8]="timestamp",r[r.uuid=9]="uuid"})(Jl||(Jl={}));var gw=/^[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}$/;class Ue{constructor(r){if(this.bytes=r,r.byteLength!==8)throw new Error("Int64 buffers must be exactly 8 bytes")}static fromNumber(r){if(r>9223372036854776000||r<-9223372036854776000)throw new Error(`${r} is too large (or, if negative, too small) to represent as an Int64`);const s=new Uint8Array(8);for(let e=7,f=Math.abs(Math.round(r));e>-1&&f>0;e--,f/=256)s[e]=f;if(r<0)Bl(s);return new Ue(s)}valueOf(){const r=this.bytes.slice(0),s=r[0]&128;if(s)Bl(r);return parseInt(Ns.toHex(r),16)*(s?-1:1)}toString(){return String(this.valueOf())}}var Yl=(r,s)=>{r=r.toLowerCase();for(let e of Object.keys(s))if(r===e.toLowerCase())return!0;return!1};var Te=(r,s={})=>{const{headers:e,query:f={}}=L.clone(r);for(let l of Object.keys(e)){const a=l.toLowerCase();if(a.slice(0,6)==="x-amz-"&&!s.unhoistableHeaders?.has(a))f[l]=e[l],delete e[l]}return{...r,headers:e,query:f}};var Ds=(r)=>{r=L.clone(r);for(let s of Object.keys(r.headers))if(Ml.indexOf(s.toLowerCase())>-1)delete r.headers[s];return r};var Ol=(r)=>ww(r).toISOString().replace(/\.\d{3}Z$/,"Z"),ww=(r)=>{if(typeof r==="number")return new Date(r*1000);if(typeof r==="string"){if(Number(r))return new Date(Number(r)*1000);return new Date(r)}return r};class Ce{constructor({applyChecksum:r,credentials:s,region:e,service:f,sha256:l,uriEscapePath:a=!0}){this.headerFormatter=new ye,this.service=f,this.sha256=l,this.uriEscapePath=a,this.applyChecksum=typeof r==="boolean"?r:!0,this.regionProvider=Me.normalizeProvider(e),this.credentialProvider=Me.normalizeProvider(s)}async presign(r,s={}){const{signingDate:e=new Date,expiresIn:f=3600,unsignableHeaders:l,unhoistableHeaders:a,signableHeaders:h,signingRegion:m,signingService:g}=s,w=await this.credentialProvider();this.validateResolvedCredentials(w);const E=m??await this.regionProvider(),{longDate:I,shortDate:P}=$s(e);if(f>Wl)return Promise.reject("Signature version 4 presigned URLs must have an expiration date less than one week in the future");const N=Ps(P,E,g??this.service),y=Te(Ds(r),{unhoistableHeaders:a});if(w.sessionToken)y.query[Ul]=w.sessionToken;y.query[Pl]=cs,y.query[kl]=`${w.accessKeyId}/${N}`,y.query[Nl]=I,y.query[$l]=f.toString(10);const V=ks(y,l,h);return y.query[Dl]=_l(V),y.query[yl]=await this.getSignature(I,N,this.getSigningKey(w,E,P,g),this.createCanonicalRequest(y,V,await Zr(r,this.sha256))),y}async sign(r,s){if(typeof r==="string")return this.signString(r,s);else if(r.headers&&r.payload)return this.signEvent(r,s);else if(r.message)return this.signMessage(r,s);else return this.signRequest(r,s)}async signEvent({headers:r,payload:s},{signingDate:e=new Date,priorSignature:f,signingRegion:l,signingService:a}){const h=l??await this.regionProvider(),{shortDate:m,longDate:g}=$s(e),w=Ps(m,h,a??this.service),E=await Zr({headers:{},body:s},this.sha256),I=new this.sha256;I.update(r);const P=Jr.toHex(await I.digest()),N=[Fl,g,w,f,P,E].join("\n");return this.signString(N,{signingDate:e,signingRegion:h,signingService:a})}async signMessage(r,{signingDate:s=new Date,signingRegion:e,signingService:f}){return this.signEvent({headers:this.headerFormatter.format(r.message.headers),payload:r.message.body},{signingDate:s,signingRegion:e,signingService:f,priorSignature:r.priorSignature}).then((a)=>{return{message:r.message,signature:a}})}async signString(r,{signingDate:s=new Date,signingRegion:e,signingService:f}={}){const l=await this.credentialProvider();this.validateResolvedCredentials(l);const a=e??await this.regionProvider(),{shortDate:h}=$s(s),m=new this.sha256(await this.getSigningKey(l,a,h,f));return m.update(Y(r)),Jr.toHex(await m.digest())}async signRequest(r,{signingDate:s=new Date,signableHeaders:e,unsignableHeaders:f,signingRegion:l,signingService:a}={}){const h=await this.credentialProvider();this.validateResolvedCredentials(h);const m=l??await this.regionProvider(),g=Ds(r),{longDate:w,shortDate:E}=$s(s),I=Ps(E,m,a??this.service);if(g.headers[ke]=w,h.sessionToken)g.headers[Hl]=h.sessionToken;const P=await Zr(g,this.sha256);if(!Yl(Xr,g.headers)&&this.applyChecksum)g.headers[Xr]=P;const N=ks(g,f,e),y=await this.getSignature(w,I,this.getSigningKey(h,m,E,a),this.createCanonicalRequest(g,N,P));return g.headers[Tl]=`${cs} Credential=${h.accessKeyId}/${I}, SignedHeaders=${_l(N)}, Signature=${y}`,g}createCanonicalRequest(r,s,e){const f=Object.keys(s).sort();return`${r.method}
|
|
3
|
-
${this.getCanonicalPath(r)}
|
|
4
|
-
${$e(r)}
|
|
5
|
-
${f.map((l)=>`${l}:${s[l]}`).join("\n")}
|
|
2
|
+
import"../chunk-9vm0ck1e.js";import{Oa as If}from"../chunk-cb616xw5.js";import{Pa as K,Qa as z}from"../chunk-xajvm5dg.js";import{db as cA}from"../chunk-stfzvxzh.js";import"../chunk-z2536ve8.js";import{ub as Cm}from"../chunk-md05dm8y.js";import{$b as wR,Ab as K0,Bb as v0,Cb as vm,Db as Vf,Eb as Qf,Fb as sI,Gb as c0,Hb as BS,Ib as lS,Jb as yS,Kb as qS,Lb as b0,Mb as D0,Nb as F0,Ob as N0,Pb as T0,Qb as a0,Rb as k0,Sb as dS,Tb as uf,Ub as tf,Vb as x0,Wb as $0,Xb as L0,Yb as i0,Zb as W0,_b as _0,ac as G0,bc as BR,cc as C0,dc as m0,ec as E0,fc as Y0,gc as y0,hc as q0,vb as Oh,wb as Hh,xb as Eh,yb as O0,zb as j0}from"../chunk-gwf5xs7m.js";import{Ac as Lh,Dc as ef,Ec as A3,Fc as of,Gc as s3,Hc as LR,Ic as Nh,Kc as oI,Lc as Ph,Mc as bS,Nc as Hf,Oc as S3,Pc as U0,Qc as H0,Rc as B0,Sc as l0,Uc as O,Wc as w3,Yc as M0,Zc as g0,ic as Q0,jc as z0,kc as hf,lc as eh,mc as Gm,nc as hI,oc as _h,qc as r0,uc as o3,vc as Vs,wc as I3,xc as nf,yc as u}from"../chunk-d8nm5ddh.js";import"../chunk-8w9c6mxe.js";import{cd as Ef,dd as w0}from"../chunk-d7zvjgvr.js";import"../chunk-w1zabjwt.js";import{gd as X0}from"../chunk-w100wbf2.js";import"../chunk-9dz8xyy1.js";var jR=z((nP,n0)=>{function b(f){this.__parent=f,this.__character_count=0,this.__indent_count=-1,this.__alignment_count=0,this.__wrap_point_index=0,this.__wrap_point_character_count=0,this.__wrap_point_indent_count=-1,this.__wrap_point_alignment_count=0,this.__items=[]}function Ch(f,h){if(this.__cache=[""],this.__indent_size=f.indent_size,this.__indent_string=f.indent_char,!f.indent_with_tabs)this.__indent_string=new Array(f.indent_size+1).join(f.indent_char);if(h=h||"",f.indent_level>0)h=new Array(f.indent_level+1).join(this.__indent_string);this.__base_string=h,this.__base_string_length=h.length}function a(f,h){this.__indent_cache=new Ch(f,h),this.raw=!1,this._end_with_newline=f.end_with_newline,this.indent_size=f.indent_size,this.wrap_line_length=f.wrap_line_length,this.indent_empty_lines=f.indent_empty_lines,this.__lines=[],this.previous_line=null,this.current_line=null,this.next_line=new b(this),this.space_before_token=!1,this.non_breaking_space=!1,this.previous_token_wrapped=!1,this.__add_outputline()}b.prototype.clone_empty=function(){var f=new b(this.__parent);return f.set_indent(this.__indent_count,this.__alignment_count),f};b.prototype.item=function(f){if(f<0)return this.__items[this.__items.length+f];else return this.__items[f]};b.prototype.has_match=function(f){for(var h=this.__items.length-1;h>=0;h--)if(this.__items[h].match(f))return!0;return!1};b.prototype.set_indent=function(f,h){if(this.is_empty())this.__indent_count=f||0,this.__alignment_count=h||0,this.__character_count=this.__parent.get_indent_size(this.__indent_count,this.__alignment_count)};b.prototype._set_wrap_point=function(){if(this.__parent.wrap_line_length)this.__wrap_point_index=this.__items.length,this.__wrap_point_character_count=this.__character_count,this.__wrap_point_indent_count=this.__parent.next_line.__indent_count,this.__wrap_point_alignment_count=this.__parent.next_line.__alignment_count};b.prototype._should_wrap=function(){return this.__wrap_point_index&&this.__character_count>this.__parent.wrap_line_length&&this.__wrap_point_character_count>this.__parent.next_line.__character_count};b.prototype._allow_wrap=function(){if(this._should_wrap()){this.__parent.add_new_line();var f=this.__parent.current_line;if(f.set_indent(this.__wrap_point_indent_count,this.__wrap_point_alignment_count),f.__items=this.__items.slice(this.__wrap_point_index),this.__items=this.__items.slice(0,this.__wrap_point_index),f.__character_count+=this.__character_count-this.__wrap_point_character_count,this.__character_count=this.__wrap_point_character_count,f.__items[0]===" ")f.__items.splice(0,1),f.__character_count-=1;return!0}return!1};b.prototype.is_empty=function(){return this.__items.length===0};b.prototype.last=function(){if(!this.is_empty())return this.__items[this.__items.length-1];else return null};b.prototype.push=function(f){this.__items.push(f);var h=f.lastIndexOf("\n");if(h!==-1)this.__character_count=f.length-h;else this.__character_count+=f.length};b.prototype.pop=function(){var f=null;if(!this.is_empty())f=this.__items.pop(),this.__character_count-=f.length;return f};b.prototype._remove_indent=function(){if(this.__indent_count>0)this.__indent_count-=1,this.__character_count-=this.__parent.indent_size};b.prototype._remove_wrap_indent=function(){if(this.__wrap_point_indent_count>0)this.__wrap_point_indent_count-=1};b.prototype.trim=function(){while(this.last()===" ")this.__items.pop(),this.__character_count-=1};b.prototype.toString=function(){var f="";if(this.is_empty()){if(this.__parent.indent_empty_lines)f=this.__parent.get_indent_string(this.__indent_count)}else f=this.__parent.get_indent_string(this.__indent_count,this.__alignment_count),f+=this.__items.join("");return f};Ch.prototype.get_indent_size=function(f,h){var R=this.__base_string_length;if(h=h||0,f<0)R=0;return R+=f*this.__indent_size,R+=h,R};Ch.prototype.get_indent_string=function(f,h){var R=this.__base_string;if(h=h||0,f<0)f=0,R="";return h+=f*this.__indent_size,this.__ensure_cache(h),R+=this.__cache[h],R};Ch.prototype.__ensure_cache=function(f){while(f>=this.__cache.length)this.__add_column()};Ch.prototype.__add_column=function(){var f=this.__cache.length,h=0,R="";if(this.__indent_size&&f>=this.__indent_size)h=Math.floor(f/this.__indent_size),f-=h*this.__indent_size,R=new Array(h+1).join(this.__indent_string);if(f)R+=new Array(f+1).join(" ");this.__cache.push(R)};a.prototype.__add_outputline=function(){this.previous_line=this.current_line,this.current_line=this.next_line.clone_empty(),this.__lines.push(this.current_line)};a.prototype.get_line_number=function(){return this.__lines.length};a.prototype.get_indent_string=function(f,h){return this.__indent_cache.get_indent_string(f,h)};a.prototype.get_indent_size=function(f,h){return this.__indent_cache.get_indent_size(f,h)};a.prototype.is_empty=function(){return!this.previous_line&&this.current_line.is_empty()};a.prototype.add_new_line=function(f){if(this.is_empty()||!f&&this.just_added_newline())return!1;if(!this.raw)this.__add_outputline();return!0};a.prototype.get_code=function(f){this.trim(!0);var h=this.current_line.pop();if(h){if(h[h.length-1]==="\n")h=h.replace(/\n+$/g,"");this.current_line.push(h)}if(this._end_with_newline)this.__add_outputline();var R=this.__lines.join("\n");if(f!=="\n")R=R.replace(/[\n]/g,f);return R};a.prototype.set_wrap_point=function(){this.current_line._set_wrap_point()};a.prototype.set_indent=function(f,h){if(f=f||0,h=h||0,this.next_line.set_indent(f,h),this.__lines.length>1)return this.current_line.set_indent(f,h),!0;return this.current_line.set_indent(),!1};a.prototype.add_raw_token=function(f){for(var h=0;h<f.newlines;h++)this.__add_outputline();this.current_line.set_indent(-1),this.current_line.push(f.whitespace_before),this.current_line.push(f.text),this.space_before_token=!1,this.non_breaking_space=!1,this.previous_token_wrapped=!1};a.prototype.add_token=function(f){this.__add_space_before_token(),this.current_line.push(f),this.space_before_token=!1,this.non_breaking_space=!1,this.previous_token_wrapped=this.current_line._allow_wrap()};a.prototype.__add_space_before_token=function(){if(this.space_before_token&&!this.just_added_newline()){if(!this.non_breaking_space)this.set_wrap_point();this.current_line.push(" ")}};a.prototype.remove_indent=function(f){var h=this.__lines.length;while(f<h)this.__lines[f]._remove_indent(),f++;this.current_line._remove_wrap_indent()};a.prototype.trim=function(f){f=f===void 0?!1:f,this.current_line.trim();while(f&&this.__lines.length>1&&this.current_line.is_empty())this.__lines.pop(),this.current_line=this.__lines[this.__lines.length-1],this.current_line.trim();this.previous_line=this.__lines.length>1?this.__lines[this.__lines.length-2]:null};a.prototype.just_added_newline=function(){return this.current_line.is_empty()};a.prototype.just_added_blankline=function(){return this.is_empty()||this.current_line.is_empty()&&this.previous_line.is_empty()};a.prototype.ensure_empty_line_above=function(f,h){var R=this.__lines.length-2;while(R>=0){var I=this.__lines[R];if(I.is_empty())break;else if(I.item(0).indexOf(f)!==0&&I.item(-1)!==h){this.__lines.splice(R+1,0,new b(this)),this.previous_line=this.__lines[this.__lines.length-2];break}R--}};nP.Output=a});var $A=z((fU,u0)=>{function tP(f,h,R,I){this.type=f,this.text=h,this.comments_before=null,this.newlines=R||0,this.whitespace_before=I||"",this.parent=null,this.next=null,this.previous=null,this.opened=null,this.closed=null,this.directives=null}fU.Token=tP});var MA=z((AU)=>{var RU="\\x23\\x24\\x40\\x41-\\x5a\\x5f\\x61-\\x7a",t0="\\x24\\x30-\\x39\\x41-\\x5a\\x5f\\x61-\\x7a",LA="\\xaa\\xb5\\xba\\xc0-\\xd6\\xd8-\\xf6\\xf8-\\u02c1\\u02c6-\\u02d1\\u02e0-\\u02e4\\u02ec\\u02ee\\u0370-\\u0374\\u0376\\u0377\\u037a-\\u037d\\u0386\\u0388-\\u038a\\u038c\\u038e-\\u03a1\\u03a3-\\u03f5\\u03f7-\\u0481\\u048a-\\u0527\\u0531-\\u0556\\u0559\\u0561-\\u0587\\u05d0-\\u05ea\\u05f0-\\u05f2\\u0620-\\u064a\\u066e\\u066f\\u0671-\\u06d3\\u06d5\\u06e5\\u06e6\\u06ee\\u06ef\\u06fa-\\u06fc\\u06ff\\u0710\\u0712-\\u072f\\u074d-\\u07a5\\u07b1\\u07ca-\\u07ea\\u07f4\\u07f5\\u07fa\\u0800-\\u0815\\u081a\\u0824\\u0828\\u0840-\\u0858\\u08a0\\u08a2-\\u08ac\\u0904-\\u0939\\u093d\\u0950\\u0958-\\u0961\\u0971-\\u0977\\u0979-\\u097f\\u0985-\\u098c\\u098f\\u0990\\u0993-\\u09a8\\u09aa-\\u09b0\\u09b2\\u09b6-\\u09b9\\u09bd\\u09ce\\u09dc\\u09dd\\u09df-\\u09e1\\u09f0\\u09f1\\u0a05-\\u0a0a\\u0a0f\\u0a10\\u0a13-\\u0a28\\u0a2a-\\u0a30\\u0a32\\u0a33\\u0a35\\u0a36\\u0a38\\u0a39\\u0a59-\\u0a5c\\u0a5e\\u0a72-\\u0a74\\u0a85-\\u0a8d\\u0a8f-\\u0a91\\u0a93-\\u0aa8\\u0aaa-\\u0ab0\\u0ab2\\u0ab3\\u0ab5-\\u0ab9\\u0abd\\u0ad0\\u0ae0\\u0ae1\\u0b05-\\u0b0c\\u0b0f\\u0b10\\u0b13-\\u0b28\\u0b2a-\\u0b30\\u0b32\\u0b33\\u0b35-\\u0b39\\u0b3d\\u0b5c\\u0b5d\\u0b5f-\\u0b61\\u0b71\\u0b83\\u0b85-\\u0b8a\\u0b8e-\\u0b90\\u0b92-\\u0b95\\u0b99\\u0b9a\\u0b9c\\u0b9e\\u0b9f\\u0ba3\\u0ba4\\u0ba8-\\u0baa\\u0bae-\\u0bb9\\u0bd0\\u0c05-\\u0c0c\\u0c0e-\\u0c10\\u0c12-\\u0c28\\u0c2a-\\u0c33\\u0c35-\\u0c39\\u0c3d\\u0c58\\u0c59\\u0c60\\u0c61\\u0c85-\\u0c8c\\u0c8e-\\u0c90\\u0c92-\\u0ca8\\u0caa-\\u0cb3\\u0cb5-\\u0cb9\\u0cbd\\u0cde\\u0ce0\\u0ce1\\u0cf1\\u0cf2\\u0d05-\\u0d0c\\u0d0e-\\u0d10\\u0d12-\\u0d3a\\u0d3d\\u0d4e\\u0d60\\u0d61\\u0d7a-\\u0d7f\\u0d85-\\u0d96\\u0d9a-\\u0db1\\u0db3-\\u0dbb\\u0dbd\\u0dc0-\\u0dc6\\u0e01-\\u0e30\\u0e32\\u0e33\\u0e40-\\u0e46\\u0e81\\u0e82\\u0e84\\u0e87\\u0e88\\u0e8a\\u0e8d\\u0e94-\\u0e97\\u0e99-\\u0e9f\\u0ea1-\\u0ea3\\u0ea5\\u0ea7\\u0eaa\\u0eab\\u0ead-\\u0eb0\\u0eb2\\u0eb3\\u0ebd\\u0ec0-\\u0ec4\\u0ec6\\u0edc-\\u0edf\\u0f00\\u0f40-\\u0f47\\u0f49-\\u0f6c\\u0f88-\\u0f8c\\u1000-\\u102a\\u103f\\u1050-\\u1055\\u105a-\\u105d\\u1061\\u1065\\u1066\\u106e-\\u1070\\u1075-\\u1081\\u108e\\u10a0-\\u10c5\\u10c7\\u10cd\\u10d0-\\u10fa\\u10fc-\\u1248\\u124a-\\u124d\\u1250-\\u1256\\u1258\\u125a-\\u125d\\u1260-\\u1288\\u128a-\\u128d\\u1290-\\u12b0\\u12b2-\\u12b5\\u12b8-\\u12be\\u12c0\\u12c2-\\u12c5\\u12c8-\\u12d6\\u12d8-\\u1310\\u1312-\\u1315\\u1318-\\u135a\\u1380-\\u138f\\u13a0-\\u13f4\\u1401-\\u166c\\u166f-\\u167f\\u1681-\\u169a\\u16a0-\\u16ea\\u16ee-\\u16f0\\u1700-\\u170c\\u170e-\\u1711\\u1720-\\u1731\\u1740-\\u1751\\u1760-\\u176c\\u176e-\\u1770\\u1780-\\u17b3\\u17d7\\u17dc\\u1820-\\u1877\\u1880-\\u18a8\\u18aa\\u18b0-\\u18f5\\u1900-\\u191c\\u1950-\\u196d\\u1970-\\u1974\\u1980-\\u19ab\\u19c1-\\u19c7\\u1a00-\\u1a16\\u1a20-\\u1a54\\u1aa7\\u1b05-\\u1b33\\u1b45-\\u1b4b\\u1b83-\\u1ba0\\u1bae\\u1baf\\u1bba-\\u1be5\\u1c00-\\u1c23\\u1c4d-\\u1c4f\\u1c5a-\\u1c7d\\u1ce9-\\u1cec\\u1cee-\\u1cf1\\u1cf5\\u1cf6\\u1d00-\\u1dbf\\u1e00-\\u1f15\\u1f18-\\u1f1d\\u1f20-\\u1f45\\u1f48-\\u1f4d\\u1f50-\\u1f57\\u1f59\\u1f5b\\u1f5d\\u1f5f-\\u1f7d\\u1f80-\\u1fb4\\u1fb6-\\u1fbc\\u1fbe\\u1fc2-\\u1fc4\\u1fc6-\\u1fcc\\u1fd0-\\u1fd3\\u1fd6-\\u1fdb\\u1fe0-\\u1fec\\u1ff2-\\u1ff4\\u1ff6-\\u1ffc\\u2071\\u207f\\u2090-\\u209c\\u2102\\u2107\\u210a-\\u2113\\u2115\\u2119-\\u211d\\u2124\\u2126\\u2128\\u212a-\\u212d\\u212f-\\u2139\\u213c-\\u213f\\u2145-\\u2149\\u214e\\u2160-\\u2188\\u2c00-\\u2c2e\\u2c30-\\u2c5e\\u2c60-\\u2ce4\\u2ceb-\\u2cee\\u2cf2\\u2cf3\\u2d00-\\u2d25\\u2d27\\u2d2d\\u2d30-\\u2d67\\u2d6f\\u2d80-\\u2d96\\u2da0-\\u2da6\\u2da8-\\u2dae\\u2db0-\\u2db6\\u2db8-\\u2dbe\\u2dc0-\\u2dc6\\u2dc8-\\u2dce\\u2dd0-\\u2dd6\\u2dd8-\\u2dde\\u2e2f\\u3005-\\u3007\\u3021-\\u3029\\u3031-\\u3035\\u3038-\\u303c\\u3041-\\u3096\\u309d-\\u309f\\u30a1-\\u30fa\\u30fc-\\u30ff\\u3105-\\u312d\\u3131-\\u318e\\u31a0-\\u31ba\\u31f0-\\u31ff\\u3400-\\u4db5\\u4e00-\\u9fcc\\ua000-\\ua48c\\ua4d0-\\ua4fd\\ua500-\\ua60c\\ua610-\\ua61f\\ua62a\\ua62b\\ua640-\\ua66e\\ua67f-\\ua697\\ua6a0-\\ua6ef\\ua717-\\ua71f\\ua722-\\ua788\\ua78b-\\ua78e\\ua790-\\ua793\\ua7a0-\\ua7aa\\ua7f8-\\ua801\\ua803-\\ua805\\ua807-\\ua80a\\ua80c-\\ua822\\ua840-\\ua873\\ua882-\\ua8b3\\ua8f2-\\ua8f7\\ua8fb\\ua90a-\\ua925\\ua930-\\ua946\\ua960-\\ua97c\\ua984-\\ua9b2\\ua9cf\\uaa00-\\uaa28\\uaa40-\\uaa42\\uaa44-\\uaa4b\\uaa60-\\uaa76\\uaa7a\\uaa80-\\uaaaf\\uaab1\\uaab5\\uaab6\\uaab9-\\uaabd\\uaac0\\uaac2\\uaadb-\\uaadd\\uaae0-\\uaaea\\uaaf2-\\uaaf4\\uab01-\\uab06\\uab09-\\uab0e\\uab11-\\uab16\\uab20-\\uab26\\uab28-\\uab2e\\uabc0-\\uabe2\\uac00-\\ud7a3\\ud7b0-\\ud7c6\\ud7cb-\\ud7fb\\uf900-\\ufa6d\\ufa70-\\ufad9\\ufb00-\\ufb06\\ufb13-\\ufb17\\ufb1d\\ufb1f-\\ufb28\\ufb2a-\\ufb36\\ufb38-\\ufb3c\\ufb3e\\ufb40\\ufb41\\ufb43\\ufb44\\ufb46-\\ufbb1\\ufbd3-\\ufd3d\\ufd50-\\ufd8f\\ufd92-\\ufdc7\\ufdf0-\\ufdfb\\ufe70-\\ufe74\\ufe76-\\ufefc\\uff21-\\uff3a\\uff41-\\uff5a\\uff66-\\uffbe\\uffc2-\\uffc7\\uffca-\\uffcf\\uffd2-\\uffd7\\uffda-\\uffdc",fw="\\u0300-\\u036f\\u0483-\\u0487\\u0591-\\u05bd\\u05bf\\u05c1\\u05c2\\u05c4\\u05c5\\u05c7\\u0610-\\u061a\\u0620-\\u0649\\u0672-\\u06d3\\u06e7-\\u06e8\\u06fb-\\u06fc\\u0730-\\u074a\\u0800-\\u0814\\u081b-\\u0823\\u0825-\\u0827\\u0829-\\u082d\\u0840-\\u0857\\u08e4-\\u08fe\\u0900-\\u0903\\u093a-\\u093c\\u093e-\\u094f\\u0951-\\u0957\\u0962-\\u0963\\u0966-\\u096f\\u0981-\\u0983\\u09bc\\u09be-\\u09c4\\u09c7\\u09c8\\u09d7\\u09df-\\u09e0\\u0a01-\\u0a03\\u0a3c\\u0a3e-\\u0a42\\u0a47\\u0a48\\u0a4b-\\u0a4d\\u0a51\\u0a66-\\u0a71\\u0a75\\u0a81-\\u0a83\\u0abc\\u0abe-\\u0ac5\\u0ac7-\\u0ac9\\u0acb-\\u0acd\\u0ae2-\\u0ae3\\u0ae6-\\u0aef\\u0b01-\\u0b03\\u0b3c\\u0b3e-\\u0b44\\u0b47\\u0b48\\u0b4b-\\u0b4d\\u0b56\\u0b57\\u0b5f-\\u0b60\\u0b66-\\u0b6f\\u0b82\\u0bbe-\\u0bc2\\u0bc6-\\u0bc8\\u0bca-\\u0bcd\\u0bd7\\u0be6-\\u0bef\\u0c01-\\u0c03\\u0c46-\\u0c48\\u0c4a-\\u0c4d\\u0c55\\u0c56\\u0c62-\\u0c63\\u0c66-\\u0c6f\\u0c82\\u0c83\\u0cbc\\u0cbe-\\u0cc4\\u0cc6-\\u0cc8\\u0cca-\\u0ccd\\u0cd5\\u0cd6\\u0ce2-\\u0ce3\\u0ce6-\\u0cef\\u0d02\\u0d03\\u0d46-\\u0d48\\u0d57\\u0d62-\\u0d63\\u0d66-\\u0d6f\\u0d82\\u0d83\\u0dca\\u0dcf-\\u0dd4\\u0dd6\\u0dd8-\\u0ddf\\u0df2\\u0df3\\u0e34-\\u0e3a\\u0e40-\\u0e45\\u0e50-\\u0e59\\u0eb4-\\u0eb9\\u0ec8-\\u0ecd\\u0ed0-\\u0ed9\\u0f18\\u0f19\\u0f20-\\u0f29\\u0f35\\u0f37\\u0f39\\u0f41-\\u0f47\\u0f71-\\u0f84\\u0f86-\\u0f87\\u0f8d-\\u0f97\\u0f99-\\u0fbc\\u0fc6\\u1000-\\u1029\\u1040-\\u1049\\u1067-\\u106d\\u1071-\\u1074\\u1082-\\u108d\\u108f-\\u109d\\u135d-\\u135f\\u170e-\\u1710\\u1720-\\u1730\\u1740-\\u1750\\u1772\\u1773\\u1780-\\u17b2\\u17dd\\u17e0-\\u17e9\\u180b-\\u180d\\u1810-\\u1819\\u1920-\\u192b\\u1930-\\u193b\\u1951-\\u196d\\u19b0-\\u19c0\\u19c8-\\u19c9\\u19d0-\\u19d9\\u1a00-\\u1a15\\u1a20-\\u1a53\\u1a60-\\u1a7c\\u1a7f-\\u1a89\\u1a90-\\u1a99\\u1b46-\\u1b4b\\u1b50-\\u1b59\\u1b6b-\\u1b73\\u1bb0-\\u1bb9\\u1be6-\\u1bf3\\u1c00-\\u1c22\\u1c40-\\u1c49\\u1c5b-\\u1c7d\\u1cd0-\\u1cd2\\u1d00-\\u1dbe\\u1e01-\\u1f15\\u200c\\u200d\\u203f\\u2040\\u2054\\u20d0-\\u20dc\\u20e1\\u20e5-\\u20f0\\u2d81-\\u2d96\\u2de0-\\u2dff\\u3021-\\u3028\\u3099\\u309a\\ua640-\\ua66d\\ua674-\\ua67d\\ua69f\\ua6f0-\\ua6f1\\ua7f8-\\ua800\\ua806\\ua80b\\ua823-\\ua827\\ua880-\\ua881\\ua8b4-\\ua8c4\\ua8d0-\\ua8d9\\ua8f3-\\ua8f7\\ua900-\\ua909\\ua926-\\ua92d\\ua930-\\ua945\\ua980-\\ua983\\ua9b3-\\ua9c0\\uaa00-\\uaa27\\uaa40-\\uaa41\\uaa4c-\\uaa4d\\uaa50-\\uaa59\\uaa7b\\uaae0-\\uaae9\\uaaf2-\\uaaf3\\uabc0-\\uabe1\\uabec\\uabed\\uabf0-\\uabf9\\ufb20-\\ufb28\\ufe00-\\ufe0f\\ufe20-\\ufe26\\ufe33\\ufe34\\ufe4d-\\ufe4f\\uff10-\\uff19\\uff3f",WA="\\\\u[0-9a-fA-F]{4}|\\\\u\\{[0-9a-fA-F]+\\}",hw="(?:"+WA+"|["+RU+LA+"])",IU="(?:"+WA+"|["+t0+LA+fw+"])*";AU.identifier=new RegExp(hw+IU,"g");AU.identifierStart=new RegExp(hw);AU.identifierMatch=new RegExp("(?:"+WA+"|["+t0+LA+fw+"])+");AU.newline=/[\n\r\u2028\u2029]/;AU.lineBreak=new RegExp("\r\n|"+AU.newline.source);AU.allLineBreaks=new RegExp(AU.lineBreak.source,"g")});var vR=z((EU,KR)=>{function Yf(f,h){if(this.raw_options=Aw(f,h),this.disabled=this._get_boolean("disabled"),this.eol=this._get_characters("eol","auto"),this.end_with_newline=this._get_boolean("end_with_newline"),this.indent_size=this._get_number("indent_size",4),this.indent_char=this._get_characters("indent_char"," "),this.indent_level=this._get_number("indent_level"),this.preserve_newlines=this._get_boolean("preserve_newlines",!0),this.max_preserve_newlines=this._get_number("max_preserve_newlines",32786),!this.preserve_newlines)this.max_preserve_newlines=0;if(this.indent_with_tabs=this._get_boolean("indent_with_tabs",this.indent_char==="\t"),this.indent_with_tabs){if(this.indent_char="\t",this.indent_size===1)this.indent_size=4}this.wrap_line_length=this._get_number("wrap_line_length",this._get_number("max_char")),this.indent_empty_lines=this._get_boolean("indent_empty_lines"),this.templating=this._get_selection_list("templating",["auto","none","angular","django","erb","handlebars","php","smarty"],["auto"])}function Aw(f,h){var R={};f=sw(f);var I;for(I in f)if(I!==h)R[I]=f[I];if(h&&f[h])for(I in f[h])R[I]=f[h][I];return R}function sw(f){var h={},R;for(R in f){var I=R.replace(/-/g,"_");h[I]=f[R]}return h}Yf.prototype._get_array=function(f,h){var R=this.raw_options[f],I=h||[];if(typeof R==="object"){if(R!==null&&typeof R.concat==="function")I=R.concat()}else if(typeof R==="string")I=R.split(/[^a-zA-Z0-9_\/\-]+/);return I};Yf.prototype._get_boolean=function(f,h){var R=this.raw_options[f],I=R===void 0?!!h:!!R;return I};Yf.prototype._get_characters=function(f,h){var R=this.raw_options[f],I=h||"";if(typeof R==="string")I=R.replace(/\\r/,"\r").replace(/\\n/,"\n").replace(/\\t/,"\t");return I};Yf.prototype._get_number=function(f,h){var R=this.raw_options[f];if(h=parseInt(h,10),isNaN(h))h=0;var I=parseInt(R,10);if(isNaN(I))I=h;return I};Yf.prototype._get_selection=function(f,h,R){var I=this._get_selection_list(f,h,R);if(I.length!==1)throw new Error("Invalid Option Value: The option '"+f+"' can only be one of the following values:\n"+h+"\nYou passed in: '"+this.raw_options[f]+"'");return I[0]};Yf.prototype._get_selection_list=function(f,h,R){if(!h||h.length===0)throw new Error("Selection list cannot be empty.");if(R=R||[h[0]],!this._is_valid_selection(R,h))throw new Error("Invalid Default Value!");var I=this._get_array(f,R);if(!this._is_valid_selection(I,h))throw new Error("Invalid Option Value: The option '"+f+"' can contain only the following values:\n"+h+"\nYou passed in: '"+this.raw_options[f]+"'");return I};Yf.prototype._is_valid_selection=function(f,h){return f.length&&h.length&&!f.some(function(R){return h.indexOf(R)===-1})};EU.Options=Yf;EU.normalizeOpts=sw;EU.mergeOpts=Aw});var gA=z((FU,mw)=>{function ww(f){Sw.call(this,f,"js");var h=this.raw_options.brace_style||null;if(h==="expand-strict")this.raw_options.brace_style="expand";else if(h==="collapse-preserve-inline")this.raw_options.brace_style="collapse,preserve-inline";else if(this.raw_options.braces_on_own_line!==void 0)this.raw_options.brace_style=this.raw_options.braces_on_own_line?"expand":"collapse";var R=this._get_selection_list("brace_style",["collapse","expand","end-expand","none","preserve-inline"]);this.brace_preserve_inline=!1,this.brace_style="collapse";for(var I=0;I<R.length;I++)if(R[I]==="preserve-inline")this.brace_preserve_inline=!0;else this.brace_style=R[I];if(this.unindent_chained_methods=this._get_boolean("unindent_chained_methods"),this.break_chained_methods=this._get_boolean("break_chained_methods"),this.space_in_paren=this._get_boolean("space_in_paren"),this.space_in_empty_paren=this._get_boolean("space_in_empty_paren"),this.jslint_happy=this._get_boolean("jslint_happy"),this.space_after_anon_function=this._get_boolean("space_after_anon_function"),this.space_after_named_function=this._get_boolean("space_after_named_function"),this.keep_array_indentation=this._get_boolean("keep_array_indentation"),this.space_before_conditional=this._get_boolean("space_before_conditional",!0),this.unescape_strings=this._get_boolean("unescape_strings"),this.e4x=this._get_boolean("e4x"),this.comma_first=this._get_boolean("comma_first"),this.operator_position=this._get_selection("operator_position",DU),this.test_output_raw=this._get_boolean("test_output_raw"),this.jslint_happy)this.space_after_anon_function=!0}var Sw=vR().Options,DU=["before-newline","after-newline","preserve-newline"];ww.prototype=new Sw;FU.Options=ww});var rR=z((TU,Pw)=>{function x(f){this.__input=f||"",this.__input_length=this.__input.length,this.__position=0}var Ew=RegExp.prototype.hasOwnProperty("sticky");x.prototype.restart=function(){this.__position=0};x.prototype.back=function(){if(this.__position>0)this.__position-=1};x.prototype.hasNext=function(){return this.__position<this.__input_length};x.prototype.next=function(){var f=null;if(this.hasNext())f=this.__input.charAt(this.__position),this.__position+=1;return f};x.prototype.peek=function(f){var h=null;if(f=f||0,f+=this.__position,f>=0&&f<this.__input_length)h=this.__input.charAt(f);return h};x.prototype.__match=function(f,h){f.lastIndex=h;var R=f.exec(this.__input);if(R&&!(Ew&&f.sticky)){if(R.index!==h)R=null}return R};x.prototype.test=function(f,h){if(h=h||0,h+=this.__position,h>=0&&h<this.__input_length)return!!this.__match(f,h);else return!1};x.prototype.testChar=function(f,h){var R=this.peek(h);return f.lastIndex=0,R!==null&&f.test(R)};x.prototype.match=function(f){var h=this.__match(f,this.__position);if(h)this.__position+=h[0].length;else h=null;return h};x.prototype.read=function(f,h,R){var I="",A;if(f){if(A=this.match(f),A)I+=A[0]}if(h&&(A||!f))I+=this.readUntil(h,R);return I};x.prototype.readUntil=function(f,h){var R="",I=this.__position;f.lastIndex=this.__position;var A=f.exec(this.__input);if(A){if(I=A.index,h)I+=A[0].length}else I=this.__input_length;return R=this.__input.substring(this.__position,I),this.__position=I,R};x.prototype.readUntilAfter=function(f){return this.readUntil(f,!0)};x.prototype.get_regexp=function(f,h){var R=null,I="g";if(h&&Ew)I="y";if(typeof f==="string"&&f!=="")R=new RegExp(f,I);else if(f)R=new RegExp(f.source,I);return R};x.prototype.get_literal_regexp=function(f){return RegExp(f.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&"))};x.prototype.peekUntilAfter=function(f){var h=this.__position,R=this.readUntilAfter(f);return this.__position=h,R};x.prototype.lookBack=function(f){var h=this.__position-1;return h>=f.length&&this.__input.substring(h-f.length,h).toLowerCase()===f};TU.InputScanner=x});var Hw=z((LU,Uw)=>{function yf(f){this.__tokens=[],this.__tokens_length=this.__tokens.length,this.__position=0,this.__parent_token=f}yf.prototype.restart=function(){this.__position=0};yf.prototype.isEmpty=function(){return this.__tokens_length===0};yf.prototype.hasNext=function(){return this.__position<this.__tokens_length};yf.prototype.next=function(){var f=null;if(this.hasNext())f=this.__tokens[this.__position],this.__position+=1;return f};yf.prototype.peek=function(f){var h=null;if(f=f||0,f+=this.__position,f>=0&&f<this.__tokens_length)h=this.__tokens[f];return h};yf.prototype.add=function(f){if(this.__parent_token)f.parent=this.__parent_token;this.__tokens.push(f),this.__tokens_length+=1};LU.TokenStream=yf});var Yh=z((MU,Dw)=>{function Df(f,h){if(this._input=f,this._starting_pattern=null,this._match_pattern=null,this._until_pattern=null,this._until_after=!1,h)this._starting_pattern=this._input.get_regexp(h._starting_pattern,!0),this._match_pattern=this._input.get_regexp(h._match_pattern,!0),this._until_pattern=this._input.get_regexp(h._until_pattern),this._until_after=h._until_after}Df.prototype.read=function(){var f=this._input.read(this._starting_pattern);if(!this._starting_pattern||f)f+=this._input.read(this._match_pattern,this._until_pattern,this._until_after);return f};Df.prototype.read_match=function(){return this._input.match(this._match_pattern)};Df.prototype.until_after=function(f){var h=this._create();return h._until_after=!0,h._until_pattern=this._input.get_regexp(f),h._update(),h};Df.prototype.until=function(f){var h=this._create();return h._until_after=!1,h._until_pattern=this._input.get_regexp(f),h._update(),h};Df.prototype.starting_with=function(f){var h=this._create();return h._starting_pattern=this._input.get_regexp(f,!0),h._update(),h};Df.prototype.matching=function(f){var h=this._create();return h._match_pattern=this._input.get_regexp(f,!0),h._update(),h};Df.prototype._create=function(){return new Df(this._input,this)};Df.prototype._update=function(){};MU.Pattern=Df});var Tw=z((GU,Nw)=>{function Xf(f,h){if(Fw.call(this,f,h),h)this._line_regexp=this._input.get_regexp(h._line_regexp);else this.__set_whitespace_patterns("","");this.newline_count=0,this.whitespace_before_token=""}var Fw=Yh().Pattern;Xf.prototype=new Fw;Xf.prototype.__set_whitespace_patterns=function(f,h){f+="\\t ",h+="\\n\\r",this._match_pattern=this._input.get_regexp("["+f+h+"]+",!0),this._newline_regexp=this._input.get_regexp("\\r\\n|["+h+"]")};Xf.prototype.read=function(){this.newline_count=0,this.whitespace_before_token="";var f=this._input.read(this._match_pattern);if(f===" ")this.whitespace_before_token=" ";else if(f){var h=this.__split(this._newline_regexp,f);this.newline_count=h.length-1,this.whitespace_before_token=h[this.newline_count]}return f};Xf.prototype.matching=function(f,h){var R=this._create();return R.__set_whitespace_patterns(f,h),R._update(),R};Xf.prototype._create=function(){return new Xf(this._input,this)};Xf.prototype.__split=function(f,h){f.lastIndex=0;var R=0,I=[],A=f.exec(h);while(A)I.push(h.substring(R,A.index)),R=A.index+A[0].length,A=f.exec(h);if(R<h.length)I.push(h.substring(R,h.length));else I.push("");return I};GU.WhitespacePattern=Xf});var Zh=z((ZU,CA)=>{var YU=rR().InputScanner,$w=$A().Token,GA=Hw().TokenStream,XU=Tw().WhitespacePattern,Xh={START:"TK_START",RAW:"TK_RAW",EOF:"TK_EOF"},Ff=function(f,h){this._input=new YU(f),this._options=h||{},this.__tokens=null,this._patterns={},this._patterns.whitespace=new XU(this._input)};Ff.prototype.tokenize=function(){this._input.restart(),this.__tokens=new GA,this._reset();var f,h=new $w(Xh.START,""),R=null,I=[],A=new GA;while(h.type!==Xh.EOF){f=this._get_next_token(h,R);while(this._is_comment(f))A.add(f),f=this._get_next_token(h,R);if(!A.isEmpty())f.comments_before=A,A=new GA;if(f.parent=R,this._is_opening(f))I.push(R),R=f;else if(R&&this._is_closing(f,R))f.opened=R,R.closed=f,R=I.pop(),f.parent=R;f.previous=h,h.next=f,this.__tokens.add(f),h=f}return this.__tokens};Ff.prototype._is_first_token=function(){return this.__tokens.isEmpty()};Ff.prototype._reset=function(){};Ff.prototype._get_next_token=function(f,h){this._readWhitespace();var R=this._input.read(/.+/g);if(R)return this._create_token(Xh.RAW,R);else return this._create_token(Xh.EOF,"")};Ff.prototype._is_comment=function(f){return!1};Ff.prototype._is_opening=function(f){return!1};Ff.prototype._is_closing=function(f,h){return!1};Ff.prototype._create_token=function(f,h){var R=new $w(f,h,this._patterns.whitespace.newline_count,this._patterns.whitespace.whitespace_before_token);return R};Ff.prototype._readWhitespace=function(){return this._patterns.whitespace.read()};ZU.Tokenizer=Ff;ZU.TOKEN=Xh});var cR=z((QU,Lw)=>{function YA(f,h){f=typeof f==="string"?f:f.source,h=typeof h==="string"?h:h.source,this.__directives_block_pattern=new RegExp(f+/ beautify( \w+[:]\w+)+ /.source+h,"g"),this.__directive_pattern=/ (\w+)[:](\w+)/g,this.__directives_end_ignore_pattern=new RegExp(f+/\sbeautify\signore:end\s/.source+h,"g")}YA.prototype.get_directives=function(f){if(!f.match(this.__directives_block_pattern))return null;var h={};this.__directive_pattern.lastIndex=0;var R=this.__directive_pattern.exec(f);while(R)h[R[1]]=R[2],R=this.__directive_pattern.exec(f);return h};YA.prototype.readIgnored=function(f){return f.readUntilAfter(this.__directives_end_ignore_pattern)};QU.Directives=YA});var JA=z((BU,Ww)=>{function Pf(f,h){if(XA.call(this,f,h),this.__template_pattern=null,this._disabled=Object.assign({},ZA),this._excluded=Object.assign({},ZA),h)this.__template_pattern=this._input.get_regexp(h.__template_pattern),this._excluded=Object.assign(this._excluded,h._excluded),this._disabled=Object.assign(this._disabled,h._disabled);var R=new XA(f);this.__patterns={handlebars_comment:R.starting_with(/{{!--/).until_after(/--}}/),handlebars_unescaped:R.starting_with(/{{{/).until_after(/}}}/),handlebars:R.starting_with(/{{/).until_after(/}}/),php:R.starting_with(/<\?(?:[= ]|php)/).until_after(/\?>/),erb:R.starting_with(/<%[^%]/).until_after(/[^%]%>/),django:R.starting_with(/{%/).until_after(/%}/),django_value:R.starting_with(/{{/).until_after(/}}/),django_comment:R.starting_with(/{#/).until_after(/#}/),smarty:R.starting_with(/{(?=[^}{\s\n])/).until_after(/[^\s\n]}/),smarty_comment:R.starting_with(/{\*/).until_after(/\*}/),smarty_literal:R.starting_with(/{literal}/).until_after(/{\/literal}/)}}var XA=Yh().Pattern,ZA={django:!1,erb:!1,handlebars:!1,php:!1,smarty:!1,angular:!1};Pf.prototype=new XA;Pf.prototype._create=function(){return new Pf(this._input,this)};Pf.prototype._update=function(){this.__set_templated_pattern()};Pf.prototype.disable=function(f){var h=this._create();return h._disabled[f]=!0,h._update(),h};Pf.prototype.read_options=function(f){var h=this._create();for(var R in ZA)h._disabled[R]=f.templating.indexOf(R)===-1;return h._update(),h};Pf.prototype.exclude=function(f){var h=this._create();return h._excluded[f]=!0,h._update(),h};Pf.prototype.read=function(){var f="";if(this._match_pattern)f=this._input.read(this._starting_pattern);else f=this._input.read(this._starting_pattern,this.__template_pattern);var h=this._read_template();while(h){if(this._match_pattern)h+=this._input.read(this._match_pattern);else h+=this._input.readUntil(this.__template_pattern);f+=h,h=this._read_template()}if(this._until_after)f+=this._input.readUntilAfter(this._until_pattern);return f};Pf.prototype.__set_templated_pattern=function(){var f=[];if(!this._disabled.php)f.push(this.__patterns.php._starting_pattern.source);if(!this._disabled.handlebars)f.push(this.__patterns.handlebars._starting_pattern.source);if(!this._disabled.erb)f.push(this.__patterns.erb._starting_pattern.source);if(!this._disabled.django)f.push(this.__patterns.django._starting_pattern.source),f.push(this.__patterns.django_value._starting_pattern.source),f.push(this.__patterns.django_comment._starting_pattern.source);if(!this._disabled.smarty)f.push(this.__patterns.smarty._starting_pattern.source);if(this._until_pattern)f.push(this._until_pattern.source);this.__template_pattern=this._input.get_regexp("(?:"+f.join("|")+")")};Pf.prototype._read_template=function(){var f="",h=this._input.peek();if(h==="<"){var R=this._input.peek(1);if(!this._disabled.php&&!this._excluded.php&&R==="?")f=f||this.__patterns.php.read();if(!this._disabled.erb&&!this._excluded.erb&&R==="%")f=f||this.__patterns.erb.read()}else if(h==="{"){if(!this._disabled.handlebars&&!this._excluded.handlebars)f=f||this.__patterns.handlebars_comment.read(),f=f||this.__patterns.handlebars_unescaped.read(),f=f||this.__patterns.handlebars.read();if(!this._disabled.django){if(!this._excluded.django&&!this._excluded.handlebars)f=f||this.__patterns.django_value.read();if(!this._excluded.django)f=f||this.__patterns.django_comment.read(),f=f||this.__patterns.django.read()}if(!this._disabled.smarty){if(this._disabled.django&&this._disabled.handlebars)f=f||this.__patterns.smarty_comment.read(),f=f||this.__patterns.smarty_literal.read(),f=f||this.__patterns.smarty.read()}}return f};BU.TemplatablePattern=Pf});var Vh=z((xU,Jh)=>{function QA(f,h){return h.indexOf(f)!==-1}function kU(f){var h="",R=0,I=new yU(f),A=null;while(I.hasNext()){if(A=I.match(/([\s]|[^\\]|\\\\)+/g),A)h+=A[0];if(I.peek()==="\\"){if(I.next(),I.peek()==="x")A=I.match(/x([0-9A-Fa-f]{2})/g);else if(I.peek()==="u"){if(A=I.match(/u([0-9A-Fa-f]{4})/g),!A)A=I.match(/u\{([0-9A-Fa-f]+)\}/g)}else{if(h+="\\",I.hasNext())h+=I.next();continue}if(!A)return f;if(R=parseInt(A[1],16),R>126&&R<=255&&A[0].indexOf("x")===0)return f;else if(R>=0&&R<32)h+="\\"+A[0];else if(R>1114111)h+="\\"+A[0];else if(R===34||R===39||R===92)h+="\\"+String.fromCharCode(R);else h+=String.fromCharCode(R)}}return h}var yU=rR().InputScanner,gw=Zh().Tokenizer,VA=Zh().TOKEN,qU=cR().Directives,sf=MA(),dU=Yh().Pattern,OU=JA().TemplatablePattern,U={START_EXPR:"TK_START_EXPR",END_EXPR:"TK_END_EXPR",START_BLOCK:"TK_START_BLOCK",END_BLOCK:"TK_END_BLOCK",WORD:"TK_WORD",RESERVED:"TK_RESERVED",SEMICOLON:"TK_SEMICOLON",STRING:"TK_STRING",EQUALS:"TK_EQUALS",OPERATOR:"TK_OPERATOR",COMMA:"TK_COMMA",BLOCK_COMMENT:"TK_BLOCK_COMMENT",COMMENT:"TK_COMMENT",DOT:"TK_DOT",UNKNOWN:"TK_UNKNOWN",START:VA.START,RAW:VA.RAW,EOF:VA.EOF},Mw=new qU(/\/\*/,/\*\//),jU=/0[xX][0123456789abcdefABCDEF_]*n?|0[oO][01234567_]*n?|0[bB][01_]*n?|\d[\d_]*n|(?:\.\d[\d_]*|\d[\d_]*\.?[\d_]*)(?:[eE][+-]?[\d_]+)?/,KU=/[0-9]/,vU=/[^\d\.]/,rU=">>> === !== &&= ??= ||= << && >= ** != == <= >> || ?? |> < / - + > : & % ? ^ | *".split(" "),qf=">>>= ... >>= <<= === >>> !== **= &&= ??= ||= => ^= :: /= << <= == && -= >= >> != -- += ** || ?? ++ %= &= *= |= |> = ! ? > < : / ^ - + * & % ~ |";qf=qf.replace(/[-[\]{}()*+?.,\\^$|#]/g,"\\$&");qf="\\?\\.(?!\\d) "+qf;qf=qf.replace(/ /g,"|");var cU=new RegExp(qf),Gw="continue,try,throw,return,var,let,const,if,switch,case,default,for,while,break,function,import,export".split(","),bU=Gw.concat(["do","in","of","else","get","set","new","catch","finally","typeof","yield","async","await","from","as","class","extends"]),aU=new RegExp("^(?:"+bU.join("|")+")$"),bR,k=function(f,h){gw.call(this,f,h),this._patterns.whitespace=this._patterns.whitespace.matching(/\u00A0\u1680\u180e\u2000-\u200a\u202f\u205f\u3000\ufeff/.source,/\u2028\u2029/.source);var R=new dU(this._input),I=new OU(this._input).read_options(this._options);this.__patterns={template:I,identifier:I.starting_with(sf.identifier).matching(sf.identifierMatch),number:R.matching(jU),punct:R.matching(cU),comment:R.starting_with(/\/\//).until(/[\n\r\u2028\u2029]/),block_comment:R.starting_with(/\/\*/).until_after(/\*\//),html_comment_start:R.matching(/<!--/),html_comment_end:R.matching(/-->/),include:R.starting_with(/#include/).until_after(sf.lineBreak),shebang:R.starting_with(/#!/).until_after(sf.lineBreak),xml:R.matching(/[\s\S]*?<(\/?)([-a-zA-Z:0-9_.]+|{[^}]+?}|!\[CDATA\[[^\]]*?\]\]|)(\s*{[^}]+?}|\s+[-a-zA-Z:0-9_.]+|\s+[-a-zA-Z:0-9_.]+\s*=\s*('[^']*'|"[^"]*"|{([^{}]|{[^}]+?})+?}))*\s*(\/?)\s*>/),single_quote:I.until(/['\\\n\r\u2028\u2029]/),double_quote:I.until(/["\\\n\r\u2028\u2029]/),template_text:I.until(/[`\\$]/),template_expression:I.until(/[`}\\]/)}};k.prototype=new gw;k.prototype._is_comment=function(f){return f.type===U.COMMENT||f.type===U.BLOCK_COMMENT||f.type===U.UNKNOWN};k.prototype._is_opening=function(f){return f.type===U.START_BLOCK||f.type===U.START_EXPR};k.prototype._is_closing=function(f,h){return(f.type===U.END_BLOCK||f.type===U.END_EXPR)&&(h&&(f.text==="]"&&h.text==="["||f.text===")"&&h.text==="("||f.text==="}"&&h.text==="{"))};k.prototype._reset=function(){bR=!1};k.prototype._get_next_token=function(f,h){var R=null;this._readWhitespace();var I=this._input.peek();if(I===null)return this._create_token(U.EOF,"");return R=R||this._read_non_javascript(I),R=R||this._read_string(I),R=R||this._read_pair(I,this._input.peek(1)),R=R||this._read_word(f),R=R||this._read_singles(I),R=R||this._read_comment(I),R=R||this._read_regexp(I,f),R=R||this._read_xml(I,f),R=R||this._read_punctuation(),R=R||this._create_token(U.UNKNOWN,this._input.next()),R};k.prototype._read_word=function(f){var h=this.__patterns.identifier.read();if(h!==""){if(h=h.replace(sf.allLineBreaks,"\n"),!(f.type===U.DOT||f.type===U.RESERVED&&(f.text==="set"||f.text==="get"))&&aU.test(h)){if((h==="in"||h==="of")&&(f.type===U.WORD||f.type===U.STRING))return this._create_token(U.OPERATOR,h);return this._create_token(U.RESERVED,h)}return this._create_token(U.WORD,h)}if(h=this.__patterns.number.read(),h!=="")return this._create_token(U.WORD,h)};k.prototype._read_singles=function(f){var h=null;if(f==="("||f==="[")h=this._create_token(U.START_EXPR,f);else if(f===")"||f==="]")h=this._create_token(U.END_EXPR,f);else if(f==="{")h=this._create_token(U.START_BLOCK,f);else if(f==="}")h=this._create_token(U.END_BLOCK,f);else if(f===";")h=this._create_token(U.SEMICOLON,f);else if(f==="."&&vU.test(this._input.peek(1)))h=this._create_token(U.DOT,f);else if(f===",")h=this._create_token(U.COMMA,f);if(h)this._input.next();return h};k.prototype._read_pair=function(f,h){var R=null;if(f==="#"&&h==="{")R=this._create_token(U.START_BLOCK,f+h);if(R)this._input.next(),this._input.next();return R};k.prototype._read_punctuation=function(){var f=this.__patterns.punct.read();if(f!=="")if(f==="=")return this._create_token(U.EQUALS,f);else if(f==="?.")return this._create_token(U.DOT,f);else return this._create_token(U.OPERATOR,f)};k.prototype._read_non_javascript=function(f){var h="";if(f==="#"){if(this._is_first_token()){if(h=this.__patterns.shebang.read(),h)return this._create_token(U.UNKNOWN,h.trim()+"\n")}if(h=this.__patterns.include.read(),h)return this._create_token(U.UNKNOWN,h.trim()+"\n");f=this._input.next();var R="#";if(this._input.hasNext()&&this._input.testChar(KU)){do f=this._input.next(),R+=f;while(this._input.hasNext()&&f!=="#"&&f!=="=");if(f==="#");else if(this._input.peek()==="["&&this._input.peek(1)==="]")R+="[]",this._input.next(),this._input.next();else if(this._input.peek()==="{"&&this._input.peek(1)==="}")R+="{}",this._input.next(),this._input.next();return this._create_token(U.WORD,R)}this._input.back()}else if(f==="<"&&this._is_first_token()){if(h=this.__patterns.html_comment_start.read(),h){while(this._input.hasNext()&&!this._input.testChar(sf.newline))h+=this._input.next();return bR=!0,this._create_token(U.COMMENT,h)}}else if(bR&&f==="-"){if(h=this.__patterns.html_comment_end.read(),h)return bR=!1,this._create_token(U.COMMENT,h)}return null};k.prototype._read_comment=function(f){var h=null;if(f==="/"){var R="";if(this._input.peek(1)==="*"){R=this.__patterns.block_comment.read();var I=Mw.get_directives(R);if(I&&I.ignore==="start")R+=Mw.readIgnored(this._input);R=R.replace(sf.allLineBreaks,"\n"),h=this._create_token(U.BLOCK_COMMENT,R),h.directives=I}else if(this._input.peek(1)==="/")R=this.__patterns.comment.read(),h=this._create_token(U.COMMENT,R)}return h};k.prototype._read_string=function(f){if(f==="`"||f==="'"||f==='"'){var h=this._input.next();if(this.has_char_escapes=!1,f==="`")h+=this._read_string_recursive("`",!0,"${");else h+=this._read_string_recursive(f);if(this.has_char_escapes&&this._options.unescape_strings)h=kU(h);if(this._input.peek()===f)h+=this._input.next();return h=h.replace(sf.allLineBreaks,"\n"),this._create_token(U.STRING,h)}return null};k.prototype._allow_regexp_or_xml=function(f){return f.type===U.RESERVED&&QA(f.text,["return","case","throw","else","do","typeof","yield"])||f.type===U.END_EXPR&&f.text===")"&&f.opened.previous.type===U.RESERVED&&QA(f.opened.previous.text,["if","while","for"])||QA(f.type,[U.COMMENT,U.START_EXPR,U.START_BLOCK,U.START,U.END_BLOCK,U.OPERATOR,U.EQUALS,U.EOF,U.SEMICOLON,U.COMMA])};k.prototype._read_regexp=function(f,h){if(f==="/"&&this._allow_regexp_or_xml(h)){var R=this._input.next(),I=!1,A=!1;while(this._input.hasNext()&&((I||A||this._input.peek()!==f)&&!this._input.testChar(sf.newline))){if(R+=this._input.peek(),!I){if(I=this._input.peek()==="\\",this._input.peek()==="[")A=!0;else if(this._input.peek()==="]")A=!1}else I=!1;this._input.next()}if(this._input.peek()===f)R+=this._input.next(),R+=this._input.read(sf.identifier);return this._create_token(U.STRING,R)}return null};k.prototype._read_xml=function(f,h){if(this._options.e4x&&f==="<"&&this._allow_regexp_or_xml(h)){var R="",I=this.__patterns.xml.read_match();if(I){var A=I[2].replace(/^{\s+/,"{").replace(/\s+}$/,"}"),s=A.indexOf("{")===0,S=0;while(I){var w=!!I[1],E=I[2],P=!!I[I.length-1]||E.slice(0,8)==="![CDATA[";if(!P&&(E===A||s&&E.replace(/^{\s+/,"{").replace(/\s+}$/,"}")))if(w)--S;else++S;if(R+=I[0],S<=0)break;I=this.__patterns.xml.read_match()}if(!I)R+=this._input.match(/[\s\S]*/g)[0];return R=R.replace(sf.allLineBreaks,"\n"),this._create_token(U.STRING,R)}}return null};k.prototype._read_string_recursive=function(f,h,R){var I,A;if(f==="\'")A=this.__patterns.single_quote;else if(f==='"')A=this.__patterns.double_quote;else if(f==="`")A=this.__patterns.template_text;else if(f==="}")A=this.__patterns.template_expression;var s=A.read(),S="";while(this._input.hasNext()){if(S=this._input.next(),S===f||!h&&sf.newline.test(S)){this._input.back();break}else if(S==="\\"&&this._input.hasNext()){if(I=this._input.peek(),I==="x"||I==="u")this.has_char_escapes=!0;else if(I==="\r"&&this._input.peek(1)==="\n")this._input.next();S+=this._input.next()}else if(R){if(R==="${"&&S==="$"&&this._input.peek()==="{")S+=this._input.next();if(R===S){if(f==="`")S+=this._read_string_recursive("}",h,"`");else S+=this._read_string_recursive("`",h,"${");if(this._input.hasNext())S+=this._input.next()}}S+=A.read(),s+=S}return s};xU.Tokenizer=k;xU.TOKEN=U;xU.positionable_operators=rU.slice();xU.line_starters=Gw.slice()});var Zw=z((SH,Xw)=>{function T(f,h){return h.indexOf(f)!==-1}function fH(f){return f.replace(/^\s+/g,"")}function hH(f){var h={};for(var R=0;R<f.length;R++)h[f[R].replace(/-/g,"_")]=f[R];return h}function Sf(f,h){return f&&f.type===m.RESERVED&&f.text===h}function J(f,h){return f&&f.type===m.RESERVED&&T(f.text,h)}function Yw(f,h){if(h.multiline_frame||h.mode===H.ForInitializer||h.mode===H.Conditional)return;f.remove_indent(h.start_line_index)}function IH(f){f=f.replace(aR.allLineBreaks,"\n");var h=[],R=f.indexOf("\n");while(R!==-1)h.push(f.substring(0,R)),f=f.substring(R+1),R=f.indexOf("\n");if(f.length)h.push(f);return h}function Zf(f){return f===H.ArrayLiteral}function Bh(f){return T(f,[H.Expression,H.ForInitializer,H.Conditional])}function AH(f,h){for(var R=0;R<f.length;R++){var I=f[R].trim();if(I.charAt(0)!==h)return!1}return!0}function sH(f,h){var R=0,I=f.length,A;for(;R<I;R++)if(A=f[R],A&&A.indexOf(h)!==0)return!1;return!0}function C(f,h){h=h||{},this._source_text=f||"",this._output=null,this._tokens=null,this._last_last_text=null,this._flags=null,this._previous_flags=null,this._flag_store=null,this._options=new uU(h)}var pU=jR().Output,nU=$A().Token,aR=MA(),uU=gA().Options,tU=Vh().Tokenizer,lh=Vh().line_starters,Qh=Vh().positionable_operators,m=Vh().TOKEN,kR=["case","return","do","if","throw","else","await","break","continue","async"],RH=["before-newline","after-newline","preserve-newline"],zh=hH(RH),Cw=[zh.before_newline,zh.preserve_newline],H={BlockStatement:"BlockStatement",Statement:"Statement",ObjectLiteral:"ObjectLiteral",ArrayLiteral:"ArrayLiteral",ForInitializer:"ForInitializer",Conditional:"Conditional",Expression:"Expression"};C.prototype.create_flags=function(f,h){var R=0;if(f){if(R=f.indentation_level,!this._output.just_added_newline()&&f.line_indent_level>R)R=f.line_indent_level}var I={mode:h,parent:f,last_token:f?f.last_token:new nU(m.START_BLOCK,""),last_word:f?f.last_word:"",declaration_statement:!1,declaration_assignment:!1,multiline_frame:!1,inline_frame:!1,if_block:!1,else_block:!1,class_start_block:!1,do_block:!1,do_while:!1,import_block:!1,in_case_statement:!1,in_case:!1,case_body:!1,case_block:!1,indentation_level:R,alignment:0,line_indent_level:f?f.line_indent_level:R,start_line_index:this._output.get_line_number(),ternary_depth:0};return I};C.prototype._reset=function(f){var h=f.match(/^[\t ]*/)[0];this._last_last_text="",this._output=new pU(this._options,h),this._output.raw=this._options.test_output_raw,this._flag_store=[],this.set_mode(H.BlockStatement);var R=new tU(f,this._options);return this._tokens=R.tokenize(),f};C.prototype.beautify=function(){if(this._options.disabled)return this._source_text;var f,h=this._reset(this._source_text),R=this._options.eol;if(this._options.eol==="auto"){if(R="\n",h&&aR.lineBreak.test(h||""))R=h.match(aR.lineBreak)[0]}var I=this._tokens.next();while(I)this.handle_token(I),this._last_last_text=this._flags.last_token.text,this._flags.last_token=I,I=this._tokens.next();return f=this._output.get_code(R),f};C.prototype.handle_token=function(f,h){if(f.type===m.START_EXPR)this.handle_start_expr(f);else if(f.type===m.END_EXPR)this.handle_end_expr(f);else if(f.type===m.START_BLOCK)this.handle_start_block(f);else if(f.type===m.END_BLOCK)this.handle_end_block(f);else if(f.type===m.WORD)this.handle_word(f);else if(f.type===m.RESERVED)this.handle_word(f);else if(f.type===m.SEMICOLON)this.handle_semicolon(f);else if(f.type===m.STRING)this.handle_string(f);else if(f.type===m.EQUALS)this.handle_equals(f);else if(f.type===m.OPERATOR)this.handle_operator(f);else if(f.type===m.COMMA)this.handle_comma(f);else if(f.type===m.BLOCK_COMMENT)this.handle_block_comment(f,h);else if(f.type===m.COMMENT)this.handle_comment(f,h);else if(f.type===m.DOT)this.handle_dot(f);else if(f.type===m.EOF)this.handle_eof(f);else if(f.type===m.UNKNOWN)this.handle_unknown(f,h);else this.handle_unknown(f,h)};C.prototype.handle_whitespace_and_comments=function(f,h){var R=f.newlines,I=this._options.keep_array_indentation&&Zf(this._flags.mode);if(f.comments_before){var A=f.comments_before.next();while(A)this.handle_whitespace_and_comments(A,h),this.handle_token(A,h),A=f.comments_before.next()}if(I)for(var s=0;s<R;s+=1)this.print_newline(s>0,h);else{if(this._options.max_preserve_newlines&&R>this._options.max_preserve_newlines)R=this._options.max_preserve_newlines;if(this._options.preserve_newlines){if(R>1){this.print_newline(!1,h);for(var S=1;S<R;S+=1)this.print_newline(!0,h)}}}};var zA=["async","break","continue","return","throw","yield"];C.prototype.allow_wrap_or_preserved_newline=function(f,h){if(h=h===void 0?!1:h,this._output.just_added_newline())return;var R=this._options.preserve_newlines&&f.newlines||h,I=T(this._flags.last_token.text,Qh)||T(f.text,Qh);if(I){var A=T(this._flags.last_token.text,Qh)&&T(this._options.operator_position,Cw)||T(f.text,Qh);R=R&&A}if(R)this.print_newline(!1,!0);else if(this._options.wrap_line_length){if(J(this._flags.last_token,zA))return;this._output.set_wrap_point()}};C.prototype.print_newline=function(f,h){if(!h){if(this._flags.last_token.text!==";"&&this._flags.last_token.text!==","&&this._flags.last_token.text!=="="&&(this._flags.last_token.type!==m.OPERATOR||this._flags.last_token.text==="--"||this._flags.last_token.text==="++")){var R=this._tokens.peek();while(this._flags.mode===H.Statement&&!(this._flags.if_block&&Sf(R,"else"))&&!this._flags.do_block)this.restore_mode()}}if(this._output.add_new_line(f))this._flags.multiline_frame=!0};C.prototype.print_token_line_indentation=function(f){if(this._output.just_added_newline()){if(this._options.keep_array_indentation&&f.newlines&&(f.text==="["||Zf(this._flags.mode)))this._output.current_line.set_indent(-1),this._output.current_line.push(f.whitespace_before),this._output.space_before_token=!1;else if(this._output.set_indent(this._flags.indentation_level,this._flags.alignment))this._flags.line_indent_level=this._flags.indentation_level}};C.prototype.print_token=function(f){if(this._output.raw){this._output.add_raw_token(f);return}if(this._options.comma_first&&f.previous&&f.previous.type===m.COMMA&&this._output.just_added_newline()){if(this._output.previous_line.last()===","){var h=this._output.previous_line.pop();if(this._output.previous_line.is_empty())this._output.previous_line.push(h),this._output.trim(!0),this._output.current_line.pop(),this._output.trim();this.print_token_line_indentation(f),this._output.add_token(","),this._output.space_before_token=!0}}if(this.print_token_line_indentation(f),this._output.non_breaking_space=!0,this._output.add_token(f.text),this._output.previous_token_wrapped)this._flags.multiline_frame=!0};C.prototype.indent=function(){this._flags.indentation_level+=1,this._output.set_indent(this._flags.indentation_level,this._flags.alignment)};C.prototype.deindent=function(){if(this._flags.indentation_level>0&&(!this._flags.parent||this._flags.indentation_level>this._flags.parent.indentation_level))this._flags.indentation_level-=1,this._output.set_indent(this._flags.indentation_level,this._flags.alignment)};C.prototype.set_mode=function(f){if(this._flags)this._flag_store.push(this._flags),this._previous_flags=this._flags;else this._previous_flags=this.create_flags(null,f);this._flags=this.create_flags(this._previous_flags,f),this._output.set_indent(this._flags.indentation_level,this._flags.alignment)};C.prototype.restore_mode=function(){if(this._flag_store.length>0){if(this._previous_flags=this._flags,this._flags=this._flag_store.pop(),this._previous_flags.mode===H.Statement)Yw(this._output,this._previous_flags);this._output.set_indent(this._flags.indentation_level,this._flags.alignment)}};C.prototype.start_of_object_property=function(){return this._flags.parent.mode===H.ObjectLiteral&&this._flags.mode===H.Statement&&(this._flags.last_token.text===":"&&this._flags.ternary_depth===0||J(this._flags.last_token,["get","set"]))};C.prototype.start_of_statement=function(f){var h=!1;if(h=h||J(this._flags.last_token,["var","let","const"])&&f.type===m.WORD,h=h||Sf(this._flags.last_token,"do"),h=h||!(this._flags.parent.mode===H.ObjectLiteral&&this._flags.mode===H.Statement)&&J(this._flags.last_token,zA)&&!f.newlines,h=h||Sf(this._flags.last_token,"else")&&!(Sf(f,"if")&&!f.comments_before),h=h||this._flags.last_token.type===m.END_EXPR&&(this._previous_flags.mode===H.ForInitializer||this._previous_flags.mode===H.Conditional),h=h||this._flags.last_token.type===m.WORD&&this._flags.mode===H.BlockStatement&&!this._flags.in_case&&!(f.text==="--"||f.text==="++")&&this._last_last_text!=="function"&&f.type!==m.WORD&&f.type!==m.RESERVED,h=h||this._flags.mode===H.ObjectLiteral&&(this._flags.last_token.text===":"&&this._flags.ternary_depth===0||J(this._flags.last_token,["get","set"])),h){if(this.set_mode(H.Statement),this.indent(),this.handle_whitespace_and_comments(f,!0),!this.start_of_object_property())this.allow_wrap_or_preserved_newline(f,J(f,["do","for","if","while"]));return!0}return!1};C.prototype.handle_start_expr=function(f){if(!this.start_of_statement(f))this.handle_whitespace_and_comments(f);var h=H.Expression;if(f.text==="["){if(this._flags.last_token.type===m.WORD||this._flags.last_token.text===")"){if(J(this._flags.last_token,lh))this._output.space_before_token=!0;if(this.print_token(f),this.set_mode(h),this.indent(),this._options.space_in_paren)this._output.space_before_token=!0;return}if(h=H.ArrayLiteral,Zf(this._flags.mode)){if(this._flags.last_token.text==="["||this._flags.last_token.text===","&&(this._last_last_text==="]"||this._last_last_text==="}")){if(!this._options.keep_array_indentation)this.print_newline()}}if(!T(this._flags.last_token.type,[m.START_EXPR,m.END_EXPR,m.WORD,m.OPERATOR,m.DOT]))this._output.space_before_token=!0}else{if(this._flags.last_token.type===m.RESERVED){if(this._flags.last_token.text==="for")this._output.space_before_token=this._options.space_before_conditional,h=H.ForInitializer;else if(T(this._flags.last_token.text,["if","while","switch"]))this._output.space_before_token=this._options.space_before_conditional,h=H.Conditional;else if(T(this._flags.last_word,["await","async"]))this._output.space_before_token=!0;else if(this._flags.last_token.text==="import"&&f.whitespace_before==="")this._output.space_before_token=!1;else if(T(this._flags.last_token.text,lh)||this._flags.last_token.text==="catch")this._output.space_before_token=!0}else if(this._flags.last_token.type===m.EQUALS||this._flags.last_token.type===m.OPERATOR){if(!this.start_of_object_property())this.allow_wrap_or_preserved_newline(f)}else if(this._flags.last_token.type===m.WORD){this._output.space_before_token=!1;var R=this._tokens.peek(-3);if(this._options.space_after_named_function&&R){var I=this._tokens.peek(-4);if(J(R,["async","function"])||R.text==="*"&&J(I,["async","function"]))this._output.space_before_token=!0;else if(this._flags.mode===H.ObjectLiteral){if(R.text==="{"||R.text===","||R.text==="*"&&(I.text==="{"||I.text===","))this._output.space_before_token=!0}else if(this._flags.parent&&this._flags.parent.class_start_block)this._output.space_before_token=!0}}else this.allow_wrap_or_preserved_newline(f);if(this._flags.last_token.type===m.RESERVED&&(this._flags.last_word==="function"||this._flags.last_word==="typeof")||this._flags.last_token.text==="*"&&(T(this._last_last_text,["function","yield"])||this._flags.mode===H.ObjectLiteral&&T(this._last_last_text,["{",","])))this._output.space_before_token=this._options.space_after_anon_function}if(this._flags.last_token.text===";"||this._flags.last_token.type===m.START_BLOCK)this.print_newline();else if(this._flags.last_token.type===m.END_EXPR||this._flags.last_token.type===m.START_EXPR||this._flags.last_token.type===m.END_BLOCK||this._flags.last_token.text==="."||this._flags.last_token.type===m.COMMA)this.allow_wrap_or_preserved_newline(f,f.newlines);if(this.print_token(f),this.set_mode(h),this._options.space_in_paren)this._output.space_before_token=!0;this.indent()};C.prototype.handle_end_expr=function(f){while(this._flags.mode===H.Statement)this.restore_mode();if(this.handle_whitespace_and_comments(f),this._flags.multiline_frame)this.allow_wrap_or_preserved_newline(f,f.text==="]"&&Zf(this._flags.mode)&&!this._options.keep_array_indentation);if(this._options.space_in_paren)if(this._flags.last_token.type===m.START_EXPR&&!this._options.space_in_empty_paren)this._output.trim(),this._output.space_before_token=!1;else this._output.space_before_token=!0;if(this.deindent(),this.print_token(f),this.restore_mode(),Yw(this._output,this._previous_flags),this._flags.do_while&&this._previous_flags.mode===H.Conditional)this._previous_flags.mode=H.Expression,this._flags.do_block=!1,this._flags.do_while=!1};C.prototype.handle_start_block=function(f){this.handle_whitespace_and_comments(f);var h=this._tokens.peek(),R=this._tokens.peek(1);if(this._flags.last_word==="switch"&&this._flags.last_token.type===m.END_EXPR)this.set_mode(H.BlockStatement),this._flags.in_case_statement=!0;else if(this._flags.case_body)this.set_mode(H.BlockStatement);else if(R&&(T(R.text,[":",","])&&T(h.type,[m.STRING,m.WORD,m.RESERVED])||T(h.text,["get","set","..."])&&T(R.type,[m.WORD,m.RESERVED])))if(T(this._last_last_text,["class","interface"])&&!T(R.text,[":",","]))this.set_mode(H.BlockStatement);else this.set_mode(H.ObjectLiteral);else if(this._flags.last_token.type===m.OPERATOR&&this._flags.last_token.text==="=>")this.set_mode(H.BlockStatement);else if(T(this._flags.last_token.type,[m.EQUALS,m.START_EXPR,m.COMMA,m.OPERATOR])||J(this._flags.last_token,["return","throw","import","default"]))this.set_mode(H.ObjectLiteral);else this.set_mode(H.BlockStatement);if(this._flags.last_token){if(J(this._flags.last_token.previous,["class","extends"]))this._flags.class_start_block=!0}var I=!h.comments_before&&h.text==="}",A=I&&this._flags.last_word==="function"&&this._flags.last_token.type===m.END_EXPR;if(this._options.brace_preserve_inline){var s=0,S=null;this._flags.inline_frame=!0;do if(s+=1,S=this._tokens.peek(s-1),S.newlines){this._flags.inline_frame=!1;break}while(S.type!==m.EOF&&!(S.type===m.END_BLOCK&&S.opened===f))}if((this._options.brace_style==="expand"||this._options.brace_style==="none"&&f.newlines)&&!this._flags.inline_frame)if(this._flags.last_token.type!==m.OPERATOR&&(A||this._flags.last_token.type===m.EQUALS||J(this._flags.last_token,kR)&&this._flags.last_token.text!=="else"))this._output.space_before_token=!0;else this.print_newline(!1,!0);else{if(Zf(this._previous_flags.mode)&&(this._flags.last_token.type===m.START_EXPR||this._flags.last_token.type===m.COMMA)){if(this._flags.last_token.type===m.COMMA||this._options.space_in_paren)this._output.space_before_token=!0;if(this._flags.last_token.type===m.COMMA||this._flags.last_token.type===m.START_EXPR&&this._flags.inline_frame)this.allow_wrap_or_preserved_newline(f),this._previous_flags.multiline_frame=this._previous_flags.multiline_frame||this._flags.multiline_frame,this._flags.multiline_frame=!1}if(this._flags.last_token.type!==m.OPERATOR&&this._flags.last_token.type!==m.START_EXPR)if(T(this._flags.last_token.type,[m.START_BLOCK,m.SEMICOLON])&&!this._flags.inline_frame)this.print_newline();else this._output.space_before_token=!0}if(this.print_token(f),this.indent(),!I&&!(this._options.brace_preserve_inline&&this._flags.inline_frame))this.print_newline()};C.prototype.handle_end_block=function(f){this.handle_whitespace_and_comments(f);while(this._flags.mode===H.Statement)this.restore_mode();var h=this._flags.last_token.type===m.START_BLOCK;if(this._flags.inline_frame&&!h)this._output.space_before_token=!0;else if(this._options.brace_style==="expand"){if(!h)this.print_newline()}else if(!h)if(Zf(this._flags.mode)&&this._options.keep_array_indentation)this._options.keep_array_indentation=!1,this.print_newline(),this._options.keep_array_indentation=!0;else this.print_newline();this.restore_mode(),this.print_token(f)};C.prototype.handle_word=function(f){if(f.type===m.RESERVED){if(T(f.text,["set","get"])&&this._flags.mode!==H.ObjectLiteral)f.type=m.WORD;else if(f.text==="import"&&T(this._tokens.peek().text,["(","."]))f.type=m.WORD;else if(T(f.text,["as","from"])&&!this._flags.import_block)f.type=m.WORD;else if(this._flags.mode===H.ObjectLiteral){var h=this._tokens.peek();if(h.text===":")f.type=m.WORD}}if(this.start_of_statement(f)){if(J(this._flags.last_token,["var","let","const"])&&f.type===m.WORD)this._flags.declaration_statement=!0}else if(f.newlines&&!Bh(this._flags.mode)&&(this._flags.last_token.type!==m.OPERATOR||(this._flags.last_token.text==="--"||this._flags.last_token.text==="++"))&&this._flags.last_token.type!==m.EQUALS&&(this._options.preserve_newlines||!J(this._flags.last_token,["var","let","const","set","get"])))this.handle_whitespace_and_comments(f),this.print_newline();else this.handle_whitespace_and_comments(f);if(this._flags.do_block&&!this._flags.do_while)if(Sf(f,"while")){this._output.space_before_token=!0,this.print_token(f),this._output.space_before_token=!0,this._flags.do_while=!0;return}else this.print_newline(),this._flags.do_block=!1;if(this._flags.if_block)if(!this._flags.else_block&&Sf(f,"else"))this._flags.else_block=!0;else{while(this._flags.mode===H.Statement)this.restore_mode();this._flags.if_block=!1,this._flags.else_block=!1}if(this._flags.in_case_statement&&J(f,["case","default"])){if(this.print_newline(),!this._flags.case_block&&(this._flags.case_body||this._options.jslint_happy))this.deindent();this._flags.case_body=!1,this.print_token(f),this._flags.in_case=!0;return}if(this._flags.last_token.type===m.COMMA||this._flags.last_token.type===m.START_EXPR||this._flags.last_token.type===m.EQUALS||this._flags.last_token.type===m.OPERATOR){if(!this.start_of_object_property()&&!(T(this._flags.last_token.text,["+","-"])&&this._last_last_text===":"&&this._flags.parent.mode===H.ObjectLiteral))this.allow_wrap_or_preserved_newline(f)}if(Sf(f,"function")){if(T(this._flags.last_token.text,["}",";"])||this._output.just_added_newline()&&!(T(this._flags.last_token.text,["(","[","{",":","=",","])||this._flags.last_token.type===m.OPERATOR)){if(!this._output.just_added_blankline()&&!f.comments_before)this.print_newline(),this.print_newline(!0)}if(this._flags.last_token.type===m.RESERVED||this._flags.last_token.type===m.WORD)if(J(this._flags.last_token,["get","set","new","export"])||J(this._flags.last_token,zA))this._output.space_before_token=!0;else if(Sf(this._flags.last_token,"default")&&this._last_last_text==="export")this._output.space_before_token=!0;else if(this._flags.last_token.text==="declare")this._output.space_before_token=!0;else this.print_newline();else if(this._flags.last_token.type===m.OPERATOR||this._flags.last_token.text==="=")this._output.space_before_token=!0;else if(!this._flags.multiline_frame&&(Bh(this._flags.mode)||Zf(this._flags.mode)));else this.print_newline();this.print_token(f),this._flags.last_word=f.text;return}var R="NONE";if(this._flags.last_token.type===m.END_BLOCK)if(this._previous_flags.inline_frame)R="SPACE";else if(!J(f,["else","catch","finally","from"]))R="NEWLINE";else if(this._options.brace_style==="expand"||this._options.brace_style==="end-expand"||this._options.brace_style==="none"&&f.newlines)R="NEWLINE";else R="SPACE",this._output.space_before_token=!0;else if(this._flags.last_token.type===m.SEMICOLON&&this._flags.mode===H.BlockStatement)R="NEWLINE";else if(this._flags.last_token.type===m.SEMICOLON&&Bh(this._flags.mode))R="SPACE";else if(this._flags.last_token.type===m.STRING)R="NEWLINE";else if(this._flags.last_token.type===m.RESERVED||this._flags.last_token.type===m.WORD||this._flags.last_token.text==="*"&&(T(this._last_last_text,["function","yield"])||this._flags.mode===H.ObjectLiteral&&T(this._last_last_text,["{",","])))R="SPACE";else if(this._flags.last_token.type===m.START_BLOCK)if(this._flags.inline_frame)R="SPACE";else R="NEWLINE";else if(this._flags.last_token.type===m.END_EXPR)this._output.space_before_token=!0,R="NEWLINE";if(J(f,lh)&&this._flags.last_token.text!==")")if(this._flags.inline_frame||this._flags.last_token.text==="else"||this._flags.last_token.text==="export")R="SPACE";else R="NEWLINE";if(J(f,["else","catch","finally"]))if((!(this._flags.last_token.type===m.END_BLOCK&&this._previous_flags.mode===H.BlockStatement)||this._options.brace_style==="expand"||this._options.brace_style==="end-expand"||this._options.brace_style==="none"&&f.newlines)&&!this._flags.inline_frame)this.print_newline();else{this._output.trim(!0);var I=this._output.current_line;if(I.last()!=="}")this.print_newline();this._output.space_before_token=!0}else if(R==="NEWLINE"){if(J(this._flags.last_token,kR))this._output.space_before_token=!0;else if(this._flags.last_token.text==="declare"&&J(f,["var","let","const"]))this._output.space_before_token=!0;else if(this._flags.last_token.type!==m.END_EXPR){if((this._flags.last_token.type!==m.START_EXPR||!J(f,["var","let","const"]))&&this._flags.last_token.text!==":")if(Sf(f,"if")&&Sf(f.previous,"else"))this._output.space_before_token=!0;else this.print_newline()}else if(J(f,lh)&&this._flags.last_token.text!==")")this.print_newline()}else if(this._flags.multiline_frame&&Zf(this._flags.mode)&&this._flags.last_token.text===","&&this._last_last_text==="}")this.print_newline();else if(R==="SPACE")this._output.space_before_token=!0;if(f.previous&&(f.previous.type===m.WORD||f.previous.type===m.RESERVED))this._output.space_before_token=!0;if(this.print_token(f),this._flags.last_word=f.text,f.type===m.RESERVED){if(f.text==="do")this._flags.do_block=!0;else if(f.text==="if")this._flags.if_block=!0;else if(f.text==="import")this._flags.import_block=!0;else if(this._flags.import_block&&Sf(f,"from"))this._flags.import_block=!1}};C.prototype.handle_semicolon=function(f){if(this.start_of_statement(f))this._output.space_before_token=!1;else this.handle_whitespace_and_comments(f);var h=this._tokens.peek();while(this._flags.mode===H.Statement&&!(this._flags.if_block&&Sf(h,"else"))&&!this._flags.do_block)this.restore_mode();if(this._flags.import_block)this._flags.import_block=!1;this.print_token(f)};C.prototype.handle_string=function(f){if(f.text.startsWith("`")&&f.newlines===0&&f.whitespace_before===""&&(f.previous.text===")"||this._flags.last_token.type===m.WORD));else if(this.start_of_statement(f))this._output.space_before_token=!0;else if(this.handle_whitespace_and_comments(f),this._flags.last_token.type===m.RESERVED||this._flags.last_token.type===m.WORD||this._flags.inline_frame)this._output.space_before_token=!0;else if(this._flags.last_token.type===m.COMMA||this._flags.last_token.type===m.START_EXPR||this._flags.last_token.type===m.EQUALS||this._flags.last_token.type===m.OPERATOR){if(!this.start_of_object_property())this.allow_wrap_or_preserved_newline(f)}else if(f.text.startsWith("`")&&this._flags.last_token.type===m.END_EXPR&&(f.previous.text==="]"||f.previous.text===")")&&f.newlines===0)this._output.space_before_token=!0;else this.print_newline();this.print_token(f)};C.prototype.handle_equals=function(f){if(this.start_of_statement(f));else this.handle_whitespace_and_comments(f);if(this._flags.declaration_statement)this._flags.declaration_assignment=!0;this._output.space_before_token=!0,this.print_token(f),this._output.space_before_token=!0};C.prototype.handle_comma=function(f){if(this.handle_whitespace_and_comments(f,!0),this.print_token(f),this._output.space_before_token=!0,this._flags.declaration_statement){if(Bh(this._flags.parent.mode))this._flags.declaration_assignment=!1;if(this._flags.declaration_assignment)this._flags.declaration_assignment=!1,this.print_newline(!1,!0);else if(this._options.comma_first)this.allow_wrap_or_preserved_newline(f)}else if(this._flags.mode===H.ObjectLiteral||this._flags.mode===H.Statement&&this._flags.parent.mode===H.ObjectLiteral){if(this._flags.mode===H.Statement)this.restore_mode();if(!this._flags.inline_frame)this.print_newline()}else if(this._options.comma_first)this.allow_wrap_or_preserved_newline(f)};C.prototype.handle_operator=function(f){var h=f.text==="*"&&(J(this._flags.last_token,["function","yield"])||T(this._flags.last_token.type,[m.START_BLOCK,m.COMMA,m.END_BLOCK,m.SEMICOLON])),R=T(f.text,["-","+"])&&(T(this._flags.last_token.type,[m.START_BLOCK,m.START_EXPR,m.EQUALS,m.OPERATOR])||T(this._flags.last_token.text,lh)||this._flags.last_token.text===",");if(this.start_of_statement(f));else{var I=!h;this.handle_whitespace_and_comments(f,I)}if(f.text==="*"&&this._flags.last_token.type===m.DOT){this.print_token(f);return}if(f.text==="::"){this.print_token(f);return}if(T(f.text,["-","+"])&&this.start_of_object_property()){this.print_token(f);return}if(this._flags.last_token.type===m.OPERATOR&&T(this._options.operator_position,Cw))this.allow_wrap_or_preserved_newline(f);if(f.text===":"&&this._flags.in_case){if(this.print_token(f),this._flags.in_case=!1,this._flags.case_body=!0,this._tokens.peek().type!==m.START_BLOCK)this.indent(),this.print_newline(),this._flags.case_block=!1;else this._flags.case_block=!0,this._output.space_before_token=!0;return}var A=!0,s=!0,S=!1;if(f.text===":")if(this._flags.ternary_depth===0)A=!1;else this._flags.ternary_depth-=1,S=!0;else if(f.text==="?")this._flags.ternary_depth+=1;if(!R&&!h&&this._options.preserve_newlines&&T(f.text,Qh)){var w=f.text===":",E=w&&S,P=w&&!S;switch(this._options.operator_position){case zh.before_newline:if(this._output.space_before_token=!P,this.print_token(f),!w||E)this.allow_wrap_or_preserved_newline(f);this._output.space_before_token=!0;return;case zh.after_newline:if(this._output.space_before_token=!0,!w||E)if(this._tokens.peek().newlines)this.print_newline(!1,!0);else this.allow_wrap_or_preserved_newline(f);else this._output.space_before_token=!1;this.print_token(f),this._output.space_before_token=!0;return;case zh.preserve_newline:if(!P)this.allow_wrap_or_preserved_newline(f);A=!(this._output.just_added_newline()||P),this._output.space_before_token=A,this.print_token(f),this._output.space_before_token=!0;return}}if(h){this.allow_wrap_or_preserved_newline(f),A=!1;var N=this._tokens.peek();s=N&&T(N.type,[m.WORD,m.RESERVED])}else if(f.text==="...")this.allow_wrap_or_preserved_newline(f),A=this._flags.last_token.type===m.START_BLOCK,s=!1;else if(T(f.text,["--","++","!","~"])||R){if(this._flags.last_token.type===m.COMMA||this._flags.last_token.type===m.START_EXPR)this.allow_wrap_or_preserved_newline(f);if(A=!1,s=!1,f.newlines&&(f.text==="--"||f.text==="++"||f.text==="~")){var G=J(this._flags.last_token,kR)&&f.newlines;if(G&&(this._previous_flags.if_block||this._previous_flags.else_block))this.restore_mode();this.print_newline(G,!0)}if(this._flags.last_token.text===";"&&Bh(this._flags.mode))A=!0;if(this._flags.last_token.type===m.RESERVED)A=!0;else if(this._flags.last_token.type===m.END_EXPR)A=!(this._flags.last_token.text==="]"&&(f.text==="--"||f.text==="++"));else if(this._flags.last_token.type===m.OPERATOR){if(A=T(f.text,["--","-","++","+"])&&T(this._flags.last_token.text,["--","-","++","+"]),T(f.text,["+","-"])&&T(this._flags.last_token.text,["--","++"]))s=!0}if((this._flags.mode===H.BlockStatement&&!this._flags.inline_frame||this._flags.mode===H.Statement)&&(this._flags.last_token.text==="{"||this._flags.last_token.text===";"))this.print_newline()}this._output.space_before_token=this._output.space_before_token||A,this.print_token(f),this._output.space_before_token=s};C.prototype.handle_block_comment=function(f,h){if(this._output.raw){if(this._output.add_raw_token(f),f.directives&&f.directives.preserve==="end")this._output.raw=this._options.test_output_raw;return}if(f.directives){if(this.print_newline(!1,h),this.print_token(f),f.directives.preserve==="start")this._output.raw=!0;this.print_newline(!1,!0);return}if(!aR.newline.test(f.text)&&!f.newlines){this._output.space_before_token=!0,this.print_token(f),this._output.space_before_token=!0;return}else this.print_block_commment(f,h)};C.prototype.print_block_commment=function(f,h){var R=IH(f.text),I,A=!1,s=!1,S=f.whitespace_before,w=S.length;if(this.print_newline(!1,h),this.print_token_line_indentation(f),this._output.add_token(R[0]),this.print_newline(!1,h),R.length>1){if(R=R.slice(1),A=AH(R,"*"),s=sH(R,S),A)this._flags.alignment=1;for(I=0;I<R.length;I++){if(A)this.print_token_line_indentation(f),this._output.add_token(fH(R[I]));else if(s&&R[I])this.print_token_line_indentation(f),this._output.add_token(R[I].substring(w));else this._output.current_line.set_indent(-1),this._output.add_token(R[I]);this.print_newline(!1,h)}this._flags.alignment=0}};C.prototype.handle_comment=function(f,h){if(f.newlines)this.print_newline(!1,h);else this._output.trim(!0);this._output.space_before_token=!0,this.print_token(f),this.print_newline(!1,h)};C.prototype.handle_dot=function(f){if(this.start_of_statement(f));else this.handle_whitespace_and_comments(f,!0);if(this._flags.last_token.text.match("^[0-9]+$"))this._output.space_before_token=!0;if(J(this._flags.last_token,kR))this._output.space_before_token=!1;else this.allow_wrap_or_preserved_newline(f,this._flags.last_token.text===")"&&this._options.break_chained_methods);if(this._options.unindent_chained_methods&&this._output.just_added_newline())this.deindent();this.print_token(f)};C.prototype.handle_unknown=function(f,h){if(this.print_token(f),f.text[f.text.length-1]==="\n")this.print_newline(!1,h)};C.prototype.handle_eof=function(f){while(this._flags.mode===H.Statement)this.restore_mode();this.handle_whitespace_and_comments(f)};SH.Beautifier=C});var Jw=z(($W,BA)=>{function PH(f,h){var R=new mH(f,h);return R.beautify()}var mH=Zw().Beautifier,EH=gA().Options;BA.exports=PH;BA.exports.defaultOptions=function(){return new EH}});var lA=z((UH,zw)=>{function Qw(f){Vw.call(this,f,"css"),this.selector_separator_newline=this._get_boolean("selector_separator_newline",!0),this.newline_between_rules=this._get_boolean("newline_between_rules",!0);var h=this._get_boolean("space_around_selector_separator");this.space_around_combinator=this._get_boolean("space_around_combinator")||h;var R=this._get_selection_list("brace_style",["collapse","expand","end-expand","none","preserve-inline"]);this.brace_style="collapse";for(var I=0;I<R.length;I++)if(R[I]!=="expand")this.brace_style="collapse";else this.brace_style=R[I]}var Vw=vR().Options;Qw.prototype=new Vw;UH.Options=Qw});var qw=z((gH,yw)=>{function $f(f,h){this._source_text=f||"",this._options=new DH(h),this._ch=null,this._input=null,this.NESTED_AT_RULE={page:!0,"font-face":!0,keyframes:!0,media:!0,supports:!0,document:!0},this.CONDITIONAL_GROUP_RULE={media:!0,supports:!0,document:!0},this.NON_SEMICOLON_NEWLINE_PROPERTY=["grid-template-areas","grid-template"]}var DH=lA().Options,FH=jR().Output,NH=rR().InputScanner,TH=cR().Directives,Bw=new TH(/\/\*/,/\*\//),lw=/\r\n|[\r\n]/,$H=/\r\n|[\r\n]/g,xR=/\s/,LH=/(?:\s|\n)+/g,WH=/\/\*(?:[\s\S]*?)((?:\*\/)|$)/g,MH=/\/\/(?:[^\n\r\u2028\u2029]*)/g;$f.prototype.eatString=function(f){var h="";this._ch=this._input.next();while(this._ch){if(h+=this._ch,this._ch==="\\")h+=this._input.next();else if(f.indexOf(this._ch)!==-1||this._ch==="\n")break;this._ch=this._input.next()}return h};$f.prototype.eatWhitespace=function(f){var h=xR.test(this._input.peek()),R=0;while(xR.test(this._input.peek()))if(this._ch=this._input.next(),f&&this._ch==="\n"){if(R===0||R<this._options.max_preserve_newlines)R++,this._output.add_new_line(!0)}return h};$f.prototype.foundNestedPseudoClass=function(){var f=0,h=1,R=this._input.peek(h);while(R){if(R==="{")return!0;else if(R==="(")f+=1;else if(R===")"){if(f===0)return!1;f-=1}else if(R===";"||R==="}")return!1;h++,R=this._input.peek(h)}return!1};$f.prototype.print_string=function(f){this._output.set_indent(this._indentLevel),this._output.non_breaking_space=!0,this._output.add_token(f)};$f.prototype.preserveSingleSpace=function(f){if(f)this._output.space_before_token=!0};$f.prototype.indent=function(){this._indentLevel++};$f.prototype.outdent=function(){if(this._indentLevel>0)this._indentLevel--};$f.prototype.beautify=function(){if(this._options.disabled)return this._source_text;var f=this._source_text,h=this._options.eol;if(h==="auto"){if(h="\n",f&&lw.test(f||""))h=f.match(lw)[0]}f=f.replace($H,"\n");var R=f.match(/^[\t ]*/)[0];this._output=new FH(this._options,R),this._input=new NH(f),this._indentLevel=0,this._nestedLevel=0,this._ch=null;var I=0,A=!1,s=!1,S=!1,w=!1,E=!1,P=this._ch,N=!1,G,M,g;while(!0){if(G=this._input.read(LH),M=G!=="",g=P,this._ch=this._input.next(),this._ch==="\\"&&this._input.hasNext())this._ch+=this._input.next();if(P=this._ch,!this._ch)break;else if(this._ch==="/"&&this._input.peek()==="*"){this._output.add_new_line(),this._input.back();var j=this._input.read(WH),_=Bw.get_directives(j);if(_&&_.ignore==="start")j+=Bw.readIgnored(this._input);this.print_string(j),this.eatWhitespace(!0),this._output.add_new_line()}else if(this._ch==="/"&&this._input.peek()==="/")this._output.space_before_token=!0,this._input.back(),this.print_string(this._input.read(MH)),this.eatWhitespace(!0);else if(this._ch==="$"){this.preserveSingleSpace(M),this.print_string(this._ch);var wf=this._input.peekUntilAfter(/[: ,;{}()[\]\/='"]/g);if(wf.match(/[ :]$/))wf=this.eatString(": ").replace(/\s+$/,""),this.print_string(wf),this._output.space_before_token=!0;if(I===0&&wf.indexOf(":")!==-1)s=!0,this.indent()}else if(this._ch==="@")if(this.preserveSingleSpace(M),this._input.peek()==="{")this.print_string(this._ch+this.eatString("}"));else{this.print_string(this._ch);var e=this._input.peekUntilAfter(/[: ,;{}()[\]\/='"]/g);if(e.match(/[ :]$/))e=this.eatString(": ").replace(/\s+$/,""),this.print_string(e),this._output.space_before_token=!0;if(I===0&&e.indexOf(":")!==-1)s=!0,this.indent();else if(e in this.NESTED_AT_RULE){if(this._nestedLevel+=1,e in this.CONDITIONAL_GROUP_RULE)S=!0}else if(I===0&&!s)w=!0}else if(this._ch==="#"&&this._input.peek()==="{")this.preserveSingleSpace(M),this.print_string(this._ch+this.eatString("}"));else if(this._ch==="{"){if(s)s=!1,this.outdent();if(w=!1,S)S=!1,A=this._indentLevel>=this._nestedLevel;else A=this._indentLevel>=this._nestedLevel-1;if(this._options.newline_between_rules&&A){if(this._output.previous_line&&this._output.previous_line.item(-1)!=="{")this._output.ensure_empty_line_above("/",",")}if(this._output.space_before_token=!0,this._options.brace_style==="expand")this._output.add_new_line(),this.print_string(this._ch),this.indent(),this._output.set_indent(this._indentLevel);else{if(g==="(")this._output.space_before_token=!1;else if(g!==",")this.indent();this.print_string(this._ch)}this.eatWhitespace(!0),this._output.add_new_line()}else if(this._ch==="}"){if(this.outdent(),this._output.add_new_line(),g==="{")this._output.trim(!0);if(s)this.outdent(),s=!1;if(this.print_string(this._ch),A=!1,this._nestedLevel)this._nestedLevel--;if(this.eatWhitespace(!0),this._output.add_new_line(),this._options.newline_between_rules&&!this._output.just_added_blankline()){if(this._input.peek()!=="}")this._output.add_new_line(!0)}if(this._input.peek()===")"){if(this._output.trim(!0),this._options.brace_style==="expand")this._output.add_new_line(!0)}}else if(this._ch===":"){for(var Nf=0;Nf<this.NON_SEMICOLON_NEWLINE_PROPERTY.length;Nf++)if(this._input.lookBack(this.NON_SEMICOLON_NEWLINE_PROPERTY[Nf])){N=!0;break}if((A||S)&&!(this._input.lookBack("&")||this.foundNestedPseudoClass())&&!this._input.lookBack("(")&&!w&&I===0){if(this.print_string(":"),!s)s=!0,this._output.space_before_token=!0,this.eatWhitespace(!0),this.indent()}else{if(this._input.lookBack(" "))this._output.space_before_token=!0;if(this._input.peek()===":")this._ch=this._input.next(),this.print_string("::");else this.print_string(":")}}else if(this._ch==='"'||this._ch==="\'"){var Rh=g==='"'||g==="\'";this.preserveSingleSpace(Rh||M),this.print_string(this._ch+this.eatString(this._ch)),this.eatWhitespace(!0)}else if(this._ch===";")if(N=!1,I===0){if(s)this.outdent(),s=!1;if(w=!1,this.print_string(this._ch),this.eatWhitespace(!0),this._input.peek()!=="/")this._output.add_new_line()}else this.print_string(this._ch),this.eatWhitespace(!0),this._output.space_before_token=!0;else if(this._ch==="(")if(this._input.lookBack("url")){if(this.print_string(this._ch),this.eatWhitespace(),I++,this.indent(),this._ch=this._input.next(),this._ch===")"||this._ch==='"'||this._ch==="\'")this._input.back();else if(this._ch){if(this.print_string(this._ch+this.eatString(")")),I)I--,this.outdent()}}else{var dh=!1;if(this._input.lookBack("with"))dh=!0;if(this.preserveSingleSpace(M||dh),this.print_string(this._ch),s&&g==="$"&&this._options.selector_separator_newline)this._output.add_new_line(),E=!0;else this.eatWhitespace(),I++,this.indent()}else if(this._ch===")"){if(I)I--,this.outdent();if(E&&this._input.peek()===";"&&this._options.selector_separator_newline)E=!1,this.outdent(),this._output.add_new_line();this.print_string(this._ch)}else if(this._ch===",")if(this.print_string(this._ch),this.eatWhitespace(!0),this._options.selector_separator_newline&&(!s||E)&&I===0&&!w)this._output.add_new_line();else this._output.space_before_token=!0;else if((this._ch===">"||this._ch==="+"||this._ch==="~")&&!s&&I===0){if(this._options.space_around_combinator)this._output.space_before_token=!0,this.print_string(this._ch),this._output.space_before_token=!0;else if(this.print_string(this._ch),this.eatWhitespace(),this._ch&&xR.test(this._ch))this._ch=""}else if(this._ch==="]")this.print_string(this._ch);else if(this._ch==="[")this.preserveSingleSpace(M),this.print_string(this._ch);else if(this._ch==="="){if(this.eatWhitespace(),this.print_string("="),xR.test(this._ch))this._ch=""}else if(this._ch==="!"&&!this._input.lookBack("\\"))this._output.space_before_token=!0,this.print_string(this._ch);else{var Fm=g==='"'||g==="\'";if(this.preserveSingleSpace(Fm||M),this.print_string(this._ch),!this._output.just_added_newline()&&this._input.peek()==="\n"&&N)this._output.add_new_line()}}var Nm=this._output.get_code(h);return Nm};gH.Beautifier=$f});var dw=z((LW,yA)=>{function XH(f,h){var R=new CH(f,h);return R.beautify()}var CH=qw().Beautifier,YH=lA().Options;yA.exports=XH;yA.exports.defaultOptions=function(){return new YH}});var qA=z((ZH,Kw)=>{function jw(f){if(Ow.call(this,f,"html"),this.templating.length===1&&this.templating[0]==="auto")this.templating=["django","erb","handlebars","php"];this.indent_inner_html=this._get_boolean("indent_inner_html"),this.indent_body_inner_html=this._get_boolean("indent_body_inner_html",!0),this.indent_head_inner_html=this._get_boolean("indent_head_inner_html",!0),this.indent_handlebars=this._get_boolean("indent_handlebars",!0),this.wrap_attributes=this._get_selection("wrap_attributes",["auto","force","force-aligned","force-expand-multiline","aligned-multiple","preserve","preserve-aligned"]),this.wrap_attributes_min_attrs=this._get_number("wrap_attributes_min_attrs",2),this.wrap_attributes_indent_size=this._get_number("wrap_attributes_indent_size",this.indent_size),this.extra_liners=this._get_array("extra_liners",["head","body","/html"]),this.inline=this._get_array("inline",["a","abbr","area","audio","b","bdi","bdo","br","button","canvas","cite","code","data","datalist","del","dfn","em","embed","i","iframe","img","input","ins","kbd","keygen","label","map","mark","math","meter","noscript","object","output","progress","q","ruby","s","samp","select","small","span","strong","sub","sup","svg","template","textarea","time","u","var","video","wbr","text","acronym","big","strike","tt"]),this.inline_custom_elements=this._get_boolean("inline_custom_elements",!0),this.void_elements=this._get_array("void_elements",["area","base","br","col","embed","hr","img","input","keygen","link","menuitem","meta","param","source","track","wbr","!doctype","?xml","basefont","isindex"]),this.unformatted=this._get_array("unformatted",[]),this.content_unformatted=this._get_array("content_unformatted",["pre","textarea"]),this.unformatted_content_delimiter=this._get_characters("unformatted_content_delimiter"),this.indent_scripts=this._get_selection("indent_scripts",["normal","keep","separate"])}var Ow=vR().Options;jw.prototype=new Ow;ZH.Options=jw});var jA=z((BH,OA)=>{var rw=Zh().Tokenizer,dA=Zh().TOKEN,VH=cR().Directives,QH=JA().TemplatablePattern,zH=Yh().Pattern,X={TAG_OPEN:"TK_TAG_OPEN",TAG_CLOSE:"TK_TAG_CLOSE",CONTROL_FLOW_OPEN:"TK_CONTROL_FLOW_OPEN",CONTROL_FLOW_CLOSE:"TK_CONTROL_FLOW_CLOSE",ATTRIBUTE:"TK_ATTRIBUTE",EQUALS:"TK_EQUALS",VALUE:"TK_VALUE",COMMENT:"TK_COMMENT",TEXT:"TK_TEXT",UNKNOWN:"TK_UNKNOWN",START:dA.START,RAW:dA.RAW,EOF:dA.EOF},vw=new VH(/<\!--/,/-->/),i=function(f,h){rw.call(this,f,h),this._current_tag_name="";var R=new QH(this._input).read_options(this._options),I=new zH(this._input);if(this.__patterns={word:R.until(/[\n\r\t <]/),word_control_flow_close_excluded:R.until(/[\n\r\t <}]/),single_quote:R.until_after(/'/),double_quote:R.until_after(/"/),attribute:R.until(/[\n\r\t =>]|\/>/),element_name:R.until(/[\n\r\t >\/]/),angular_control_flow_start:I.matching(/\@[a-zA-Z]+[^({]*[({]/),handlebars_comment:I.starting_with(/{{!--/).until_after(/--}}/),handlebars:I.starting_with(/{{/).until_after(/}}/),handlebars_open:I.until(/[\n\r\t }]/),handlebars_raw_close:I.until(/}}/),comment:I.starting_with(/<!--/).until_after(/-->/),cdata:I.starting_with(/<!\[CDATA\[/).until_after(/]]>/),conditional_comment:I.starting_with(/<!\[/).until_after(/]>/),processing:I.starting_with(/<\?/).until_after(/\?>/)},this._options.indent_handlebars)this.__patterns.word=this.__patterns.word.exclude("handlebars"),this.__patterns.word_control_flow_close_excluded=this.__patterns.word_control_flow_close_excluded.exclude("handlebars");if(this._unformatted_content_delimiter=null,this._options.unformatted_content_delimiter){var A=this._input.get_literal_regexp(this._options.unformatted_content_delimiter);this.__patterns.unformatted_content_delimiter=I.matching(A).until_after(A)}};i.prototype=new rw;i.prototype._is_comment=function(f){return!1};i.prototype._is_opening=function(f){return f.type===X.TAG_OPEN||f.type===X.CONTROL_FLOW_OPEN};i.prototype._is_closing=function(f,h){return f.type===X.TAG_CLOSE&&(h&&((f.text===">"||f.text==="/>")&&h.text[0]==="<"||f.text==="}}"&&h.text[0]==="{"&&h.text[1]==="{"))||f.type===X.CONTROL_FLOW_CLOSE&&(f.text==="}"&&h.text.endsWith("{"))};i.prototype._reset=function(){this._current_tag_name=""};i.prototype._get_next_token=function(f,h){var R=null;this._readWhitespace();var I=this._input.peek();if(I===null)return this._create_token(X.EOF,"");return R=R||this._read_open_handlebars(I,h),R=R||this._read_attribute(I,f,h),R=R||this._read_close(I,h),R=R||this._read_control_flows(I,h),R=R||this._read_raw_content(I,f,h),R=R||this._read_content_word(I,h),R=R||this._read_comment_or_cdata(I),R=R||this._read_processing(I),R=R||this._read_open(I,h),R=R||this._create_token(X.UNKNOWN,this._input.next()),R};i.prototype._read_comment_or_cdata=function(f){var h=null,R=null,I=null;if(f==="<"){var A=this._input.peek(1);if(A==="!")if(R=this.__patterns.comment.read(),R){if(I=vw.get_directives(R),I&&I.ignore==="start")R+=vw.readIgnored(this._input)}else R=this.__patterns.cdata.read();if(R)h=this._create_token(X.COMMENT,R),h.directives=I}return h};i.prototype._read_processing=function(f){var h=null,R=null,I=null;if(f==="<"){var A=this._input.peek(1);if(A==="!"||A==="?")R=this.__patterns.conditional_comment.read(),R=R||this.__patterns.processing.read();if(R)h=this._create_token(X.COMMENT,R),h.directives=I}return h};i.prototype._read_open=function(f,h){var R=null,I=null;if(!h||h.type===X.CONTROL_FLOW_OPEN){if(f==="<"){if(R=this._input.next(),this._input.peek()==="/")R+=this._input.next();R+=this.__patterns.element_name.read(),I=this._create_token(X.TAG_OPEN,R)}}return I};i.prototype._read_open_handlebars=function(f,h){var R=null,I=null;if(!h||h.type===X.CONTROL_FLOW_OPEN){if(this._options.indent_handlebars&&f==="{"&&this._input.peek(1)==="{")if(this._input.peek(2)==="!")R=this.__patterns.handlebars_comment.read(),R=R||this.__patterns.handlebars.read(),I=this._create_token(X.COMMENT,R);else R=this.__patterns.handlebars_open.read(),I=this._create_token(X.TAG_OPEN,R)}return I};i.prototype._read_control_flows=function(f,h){var R="",I=null;if(!this._options.templating.includes("angular")||!this._options.indent_handlebars)return I;if(f==="@"){if(R=this.__patterns.angular_control_flow_start.read(),R==="")return I;var A=R.endsWith("(")?1:0,s=0;while(!(R.endsWith("{")&&A===s)){var S=this._input.next();if(S===null)break;else if(S==="(")A++;else if(S===")")s++;R+=S}I=this._create_token(X.CONTROL_FLOW_OPEN,R)}else if(f==="}"&&h&&h.type===X.CONTROL_FLOW_OPEN)R=this._input.next(),I=this._create_token(X.CONTROL_FLOW_CLOSE,R);return I};i.prototype._read_close=function(f,h){var R=null,I=null;if(h&&h.type===X.TAG_OPEN){if(h.text[0]==="<"&&(f===">"||f==="/"&&this._input.peek(1)===">")){if(R=this._input.next(),f==="/")R+=this._input.next();I=this._create_token(X.TAG_CLOSE,R)}else if(h.text[0]==="{"&&f==="}"&&this._input.peek(1)==="}")this._input.next(),this._input.next(),I=this._create_token(X.TAG_CLOSE,"}}")}return I};i.prototype._read_attribute=function(f,h,R){var I=null,A="";if(R&&R.text[0]==="<"){if(f==="=")I=this._create_token(X.EQUALS,this._input.next());else if(f==='"'||f==="'"){var s=this._input.next();if(f==='"')s+=this.__patterns.double_quote.read();else s+=this.__patterns.single_quote.read();I=this._create_token(X.VALUE,s)}else if(A=this.__patterns.attribute.read(),A)if(h.type===X.EQUALS)I=this._create_token(X.VALUE,A);else I=this._create_token(X.ATTRIBUTE,A)}return I};i.prototype._is_content_unformatted=function(f){return this._options.void_elements.indexOf(f)===-1&&(this._options.content_unformatted.indexOf(f)!==-1||this._options.unformatted.indexOf(f)!==-1)};i.prototype._read_raw_content=function(f,h,R){var I="";if(R&&R.text[0]==="{")I=this.__patterns.handlebars_raw_close.read();else if(h.type===X.TAG_CLOSE&&h.opened.text[0]==="<"&&h.text[0]!=="/"){var A=h.opened.text.substr(1).toLowerCase();if(A==="script"||A==="style"){var s=this._read_comment_or_cdata(f);if(s)return s.type=X.TEXT,s;I=this._input.readUntil(new RegExp("</"+A+"[\\n\\r\\t ]*?>","ig"))}else if(this._is_content_unformatted(A))I=this._input.readUntil(new RegExp("</"+A+"[\\n\\r\\t ]*?>","ig"))}if(I)return this._create_token(X.TEXT,I);return null};i.prototype._read_content_word=function(f,h){var R="";if(this._options.unformatted_content_delimiter){if(f===this._options.unformatted_content_delimiter[0])R=this.__patterns.unformatted_content_delimiter.read()}if(!R)R=h&&h.type===X.CONTROL_FLOW_OPEN?this.__patterns.word_control_flow_close_excluded.read():this.__patterns.word.read();if(R)return this._create_token(X.TEXT,R)};BH.Tokenizer=i;BH.TOKEN=X});var kw=z((aH,aw)=>{function yh(f,h){return h.indexOf(f)!==-1}function rH(f,h,R){this.parent=f||null,this.tag=h?h.tag_name:"",this.indent_level=R||0,this.parser_token=h||null}function df(f){this._printer=f,this._current_frame=null}function ff(f,h,R,I){this._source_text=f||"",h=h||{},this._js_beautify=R,this._css_beautify=I,this._tag_stack=null;var A=new qH(h,"html");this._options=A,this._is_wrap_attributes_force=this._options.wrap_attributes.substr(0,"force".length)==="force",this._is_wrap_attributes_force_expand_multiline=this._options.wrap_attributes==="force-expand-multiline",this._is_wrap_attributes_force_aligned=this._options.wrap_attributes==="force-aligned",this._is_wrap_attributes_aligned_multiple=this._options.wrap_attributes==="aligned-multiple",this._is_wrap_attributes_preserve=this._options.wrap_attributes.substr(0,"preserve".length)==="preserve",this._is_wrap_attributes_preserve_aligned=this._options.wrap_attributes==="preserve-aligned"}var qH=qA().Options,dH=jR().Output,OH=jA().Tokenizer,Y=jA().TOKEN,cw=/\r\n|[\r\n]/,jH=/\r\n|[\r\n]/g,Rf=function(f,h){this.indent_level=0,this.alignment_size=0,this.max_preserve_newlines=f.max_preserve_newlines,this.preserve_newlines=f.preserve_newlines,this._output=new dH(f,h)};Rf.prototype.current_line_has_match=function(f){return this._output.current_line.has_match(f)};Rf.prototype.set_space_before_token=function(f,h){this._output.space_before_token=f,this._output.non_breaking_space=h};Rf.prototype.set_wrap_point=function(){this._output.set_indent(this.indent_level,this.alignment_size),this._output.set_wrap_point()};Rf.prototype.add_raw_token=function(f){this._output.add_raw_token(f)};Rf.prototype.print_preserved_newlines=function(f){var h=0;if(f.type!==Y.TEXT&&f.previous.type!==Y.TEXT)h=f.newlines?1:0;if(this.preserve_newlines)h=f.newlines<this.max_preserve_newlines+1?f.newlines:this.max_preserve_newlines+1;for(var R=0;R<h;R++)this.print_newline(R>0);return h!==0};Rf.prototype.traverse_whitespace=function(f){if(f.whitespace_before||f.newlines){if(!this.print_preserved_newlines(f))this._output.space_before_token=!0;return!0}return!1};Rf.prototype.previous_token_wrapped=function(){return this._output.previous_token_wrapped};Rf.prototype.print_newline=function(f){this._output.add_new_line(f)};Rf.prototype.print_token=function(f){if(f.text)this._output.set_indent(this.indent_level,this.alignment_size),this._output.add_token(f.text)};Rf.prototype.indent=function(){this.indent_level++};Rf.prototype.deindent=function(){if(this.indent_level>0)this.indent_level--,this._output.set_indent(this.indent_level,this.alignment_size)};Rf.prototype.get_full_indent=function(f){if(f=this.indent_level+(f||0),f<1)return"";return this._output.get_indent_string(f)};var KH=function(f){var h=null,R=f.next;while(R.type!==Y.EOF&&f.closed!==R){if(R.type===Y.ATTRIBUTE&&R.text==="type"){if(R.next&&R.next.type===Y.EQUALS&&R.next.next&&R.next.next.type===Y.VALUE)h=R.next.next.text;break}R=R.next}return h},vH=function(f,h){var R=null,I=null;if(!h.closed)return null;if(f==="script")R="text/javascript";else if(f==="style")R="text/css";if(R=KH(h)||R,R.search("text/css")>-1)I="css";else if(R.search(/module|((text|application|dojo)\/(x-)?(javascript|ecmascript|jscript|livescript|(ld\+)?json|method|aspect))/)>-1)I="javascript";else if(R.search(/(text|application|dojo)\/(x-)?(html)/)>-1)I="html";else if(R.search(/test\/null/)>-1)I="null";return I};df.prototype.get_parser_token=function(){return this._current_frame?this._current_frame.parser_token:null};df.prototype.record_tag=function(f){var h=new rH(this._current_frame,f,this._printer.indent_level);this._current_frame=h};df.prototype._try_pop_frame=function(f){var h=null;if(f)h=f.parser_token,this._printer.indent_level=f.indent_level,this._current_frame=f.parent;return h};df.prototype._get_frame=function(f,h){var R=this._current_frame;while(R){if(f.indexOf(R.tag)!==-1)break;else if(h&&h.indexOf(R.tag)!==-1){R=null;break}R=R.parent}return R};df.prototype.try_pop=function(f,h){var R=this._get_frame([f],h);return this._try_pop_frame(R)};df.prototype.indent_to_tag=function(f){var h=this._get_frame(f);if(h)this._printer.indent_level=h.indent_level};ff.prototype.beautify=function(){if(this._options.disabled)return this._source_text;var f=this._source_text,h=this._options.eol;if(this._options.eol==="auto"){if(h="\n",f&&cw.test(f))h=f.match(cw)[0]}f=f.replace(jH,"\n");var R=f.match(/^[\t ]*/)[0],I={text:"",type:""},A=new bw,s=new Rf(this._options,R),S=new OH(f,this._options).tokenize();this._tag_stack=new df(s);var w=null,E=S.next();while(E.type!==Y.EOF){if(E.type===Y.TAG_OPEN||E.type===Y.COMMENT)w=this._handle_tag_open(s,E,A,I,S),A=w;else if(E.type===Y.ATTRIBUTE||E.type===Y.EQUALS||E.type===Y.VALUE||E.type===Y.TEXT&&!A.tag_complete)w=this._handle_inside_tag(s,E,A,I);else if(E.type===Y.TAG_CLOSE)w=this._handle_tag_close(s,E,A);else if(E.type===Y.TEXT)w=this._handle_text(s,E,A);else if(E.type===Y.CONTROL_FLOW_OPEN)w=this._handle_control_flow_open(s,E);else if(E.type===Y.CONTROL_FLOW_CLOSE)w=this._handle_control_flow_close(s,E);else s.add_raw_token(E);I=w,E=S.next()}var P=s._output.get_code(h);return P};ff.prototype._handle_control_flow_open=function(f,h){var R={text:h.text,type:h.type};if(f.set_space_before_token(h.newlines||h.whitespace_before!=="",!0),h.newlines)f.print_preserved_newlines(h);else f.set_space_before_token(h.newlines||h.whitespace_before!=="",!0);return f.print_token(h),f.indent(),R};ff.prototype._handle_control_flow_close=function(f,h){var R={text:h.text,type:h.type};if(f.deindent(),h.newlines)f.print_preserved_newlines(h);else f.set_space_before_token(h.newlines||h.whitespace_before!=="",!0);return f.print_token(h),R};ff.prototype._handle_tag_close=function(f,h,R){var I={text:h.text,type:h.type};if(f.alignment_size=0,R.tag_complete=!0,f.set_space_before_token(h.newlines||h.whitespace_before!=="",!0),R.is_unformatted)f.add_raw_token(h);else{if(R.tag_start_char==="<"){if(f.set_space_before_token(h.text[0]==="/",!0),this._is_wrap_attributes_force_expand_multiline&&R.has_wrapped_attrs)f.print_newline(!1)}f.print_token(h)}if(R.indent_content&&!(R.is_unformatted||R.is_content_unformatted))f.indent(),R.indent_content=!1;if(!R.is_inline_element&&!(R.is_unformatted||R.is_content_unformatted))f.set_wrap_point();return I};ff.prototype._handle_inside_tag=function(f,h,R,I){var A=R.has_wrapped_attrs,s={text:h.text,type:h.type};if(f.set_space_before_token(h.newlines||h.whitespace_before!=="",!0),R.is_unformatted)f.add_raw_token(h);else if(R.tag_start_char==="{"&&h.type===Y.TEXT)if(f.print_preserved_newlines(h))h.newlines=0,f.add_raw_token(h);else f.print_token(h);else{if(h.type===Y.ATTRIBUTE)f.set_space_before_token(!0);else if(h.type===Y.EQUALS)f.set_space_before_token(!1);else if(h.type===Y.VALUE&&h.previous.type===Y.EQUALS)f.set_space_before_token(!1);if(h.type===Y.ATTRIBUTE&&R.tag_start_char==="<"){if(this._is_wrap_attributes_preserve||this._is_wrap_attributes_preserve_aligned)f.traverse_whitespace(h),A=A||h.newlines!==0;if(this._is_wrap_attributes_force&&R.attr_count>=this._options.wrap_attributes_min_attrs&&(I.type!==Y.TAG_OPEN||this._is_wrap_attributes_force_expand_multiline))f.print_newline(!1),A=!0}f.print_token(h),A=A||f.previous_token_wrapped(),R.has_wrapped_attrs=A}return s};ff.prototype._handle_text=function(f,h,R){var I={text:h.text,type:"TK_CONTENT"};if(R.custom_beautifier_name)this._print_custom_beatifier_text(f,h,R);else if(R.is_unformatted||R.is_content_unformatted)f.add_raw_token(h);else f.traverse_whitespace(h),f.print_token(h);return I};ff.prototype._print_custom_beatifier_text=function(f,h,R){var I=this;if(h.text!==""){var A=h.text,s,S=1,w="",E="";if(R.custom_beautifier_name==="javascript"&&typeof this._js_beautify==="function")s=this._js_beautify;else if(R.custom_beautifier_name==="css"&&typeof this._css_beautify==="function")s=this._css_beautify;else if(R.custom_beautifier_name==="html")s=function(j,_){var wf=new ff(j,_,I._js_beautify,I._css_beautify);return wf.beautify()};if(this._options.indent_scripts==="keep")S=0;else if(this._options.indent_scripts==="separate")S=-f.indent_level;var P=f.get_full_indent(S);if(A=A.replace(/\n[ \t]*$/,""),R.custom_beautifier_name!=="html"&&A[0]==="<"&&A.match(/^(<!--|<!\[CDATA\[)/)){var N=/^(<!--[^\n]*|<!\[CDATA\[)(\n?)([ \t\n]*)([\s\S]*)(-->|]]>)$/.exec(A);if(!N){f.add_raw_token(h);return}if(w=P+N[1]+"\n",A=N[4],N[5])E=P+N[5];if(A=A.replace(/\n[ \t]*$/,""),N[2]||N[3].indexOf("\n")!==-1){if(N=N[3].match(/[ \t]+$/),N)h.whitespace_before=N[0]}}if(A)if(s){var G=function(){this.eol="\n"};G.prototype=this._options.raw_options;var M=new G;A=s(P+A,M)}else{var g=h.whitespace_before;if(g)A=A.replace(new RegExp("\n("+g+")?","g"),"\n");A=P+A.replace(/\n/g,"\n"+P)}if(w)if(!A)A=w+E;else A=w+A+"\n"+E;if(f.print_newline(!1),A)h.text=A,h.whitespace_before="",h.newlines=0,f.add_raw_token(h),f.print_newline(!0)}};ff.prototype._handle_tag_open=function(f,h,R,I,A){var s=this._get_tag_open_token(h);if((R.is_unformatted||R.is_content_unformatted)&&!R.is_empty_element&&h.type===Y.TAG_OPEN&&!s.is_start_tag)f.add_raw_token(h),s.start_tag_token=this._tag_stack.try_pop(s.tag_name);else{if(f.traverse_whitespace(h),this._set_tag_position(f,h,s,R,I),!s.is_inline_element)f.set_wrap_point();f.print_token(h)}if(s.is_start_tag&&this._is_wrap_attributes_force){var S=0,w;do{if(w=A.peek(S),w.type===Y.ATTRIBUTE)s.attr_count+=1;S+=1}while(w.type!==Y.EOF&&w.type!==Y.TAG_CLOSE)}if(this._is_wrap_attributes_force_aligned||this._is_wrap_attributes_aligned_multiple||this._is_wrap_attributes_preserve_aligned)s.alignment_size=h.text.length+1;if(!s.tag_complete&&!s.is_unformatted)f.alignment_size=s.alignment_size;return s};var bw=function(f,h){if(this.parent=f||null,this.text="",this.type="TK_TAG_OPEN",this.tag_name="",this.is_inline_element=!1,this.is_unformatted=!1,this.is_content_unformatted=!1,this.is_empty_element=!1,this.is_start_tag=!1,this.is_end_tag=!1,this.indent_content=!1,this.multiline_content=!1,this.custom_beautifier_name=null,this.start_tag_token=null,this.attr_count=0,this.has_wrapped_attrs=!1,this.alignment_size=0,this.tag_complete=!1,this.tag_start_char="",this.tag_check="",!h)this.tag_complete=!0;else{var R;if(this.tag_start_char=h.text[0],this.text=h.text,this.tag_start_char==="<")R=h.text.match(/^<([^\s>]*)/),this.tag_check=R?R[1]:"";else if(R=h.text.match(/^{{~?(?:[\^]|#\*?)?([^\s}]+)/),this.tag_check=R?R[1]:"",(h.text.startsWith("{{#>")||h.text.startsWith("{{~#>"))&&this.tag_check[0]===">")if(this.tag_check===">"&&h.next!==null)this.tag_check=h.next.text.split(" ")[0];else this.tag_check=h.text.split(">")[1];if(this.tag_check=this.tag_check.toLowerCase(),h.type===Y.COMMENT)this.tag_complete=!0;this.is_start_tag=this.tag_check.charAt(0)!=="/",this.tag_name=!this.is_start_tag?this.tag_check.substr(1):this.tag_check,this.is_end_tag=!this.is_start_tag||h.closed&&h.closed.text==="/>";var I=2;if(this.tag_start_char==="{"&&this.text.length>=3){if(this.text.charAt(2)==="~")I=3}this.is_end_tag=this.is_end_tag||this.tag_start_char==="{"&&(this.text.length<3||/[^#\^]/.test(this.text.charAt(I)))}};ff.prototype._get_tag_open_token=function(f){var h=new bw(this._tag_stack.get_parser_token(),f);return h.alignment_size=this._options.wrap_attributes_indent_size,h.is_end_tag=h.is_end_tag||yh(h.tag_check,this._options.void_elements),h.is_empty_element=h.tag_complete||h.is_start_tag&&h.is_end_tag,h.is_unformatted=!h.tag_complete&&yh(h.tag_check,this._options.unformatted),h.is_content_unformatted=!h.is_empty_element&&yh(h.tag_check,this._options.content_unformatted),h.is_inline_element=yh(h.tag_name,this._options.inline)||this._options.inline_custom_elements&&h.tag_name.includes("-")||h.tag_start_char==="{",h};ff.prototype._set_tag_position=function(f,h,R,I,A){if(!R.is_empty_element)if(R.is_end_tag)R.start_tag_token=this._tag_stack.try_pop(R.tag_name);else{if(this._do_optional_end_element(R)){if(!R.is_inline_element)f.print_newline(!1)}if(this._tag_stack.record_tag(R),(R.tag_name==="script"||R.tag_name==="style")&&!(R.is_unformatted||R.is_content_unformatted))R.custom_beautifier_name=vH(R.tag_check,h)}if(yh(R.tag_check,this._options.extra_liners)){if(f.print_newline(!1),!f._output.just_added_blankline())f.print_newline(!0)}if(R.is_empty_element){if(R.tag_start_char==="{"&&R.tag_check==="else"){this._tag_stack.indent_to_tag(["if","unless","each"]),R.indent_content=!0;var s=f.current_line_has_match(/{{#if/);if(!s)f.print_newline(!1)}if(R.tag_name==="!--"&&A.type===Y.TAG_CLOSE&&I.is_end_tag&&R.text.indexOf("\n")===-1);else{if(!(R.is_inline_element||R.is_unformatted))f.print_newline(!1);this._calcluate_parent_multiline(f,R)}}else if(R.is_end_tag){var S=!1;if(S=R.start_tag_token&&R.start_tag_token.multiline_content,S=S||!R.is_inline_element&&!(I.is_inline_element||I.is_unformatted)&&!(A.type===Y.TAG_CLOSE&&R.start_tag_token===I)&&A.type!=="TK_CONTENT",R.is_content_unformatted||R.is_unformatted)S=!1;if(S)f.print_newline(!1)}else{if(R.indent_content=!R.custom_beautifier_name,R.tag_start_char==="<"){if(R.tag_name==="html")R.indent_content=this._options.indent_inner_html;else if(R.tag_name==="head")R.indent_content=this._options.indent_head_inner_html;else if(R.tag_name==="body")R.indent_content=this._options.indent_body_inner_html}if(!(R.is_inline_element||R.is_unformatted)&&(A.type!=="TK_CONTENT"||R.is_content_unformatted))f.print_newline(!1);this._calcluate_parent_multiline(f,R)}};ff.prototype._calcluate_parent_multiline=function(f,h){if(h.parent&&f._output.just_added_newline()&&!((h.is_inline_element||h.is_unformatted)&&h.parent.is_inline_element))h.parent.multiline_content=!0};var cH=["address","article","aside","blockquote","details","div","dl","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","header","hr","main","menu","nav","ol","p","pre","section","table","ul"],bH=["a","audio","del","ins","map","noscript","video"];ff.prototype._do_optional_end_element=function(f){var h=null;if(f.is_empty_element||!f.is_start_tag||!f.parent)return;if(f.tag_name==="body")h=h||this._tag_stack.try_pop("head");else if(f.tag_name==="li")h=h||this._tag_stack.try_pop("li",["ol","ul","menu"]);else if(f.tag_name==="dd"||f.tag_name==="dt")h=h||this._tag_stack.try_pop("dt",["dl"]),h=h||this._tag_stack.try_pop("dd",["dl"]);else if(f.parent.tag_name==="p"&&cH.indexOf(f.tag_name)!==-1){var R=f.parent.parent;if(!R||bH.indexOf(R.tag_name)===-1)h=h||this._tag_stack.try_pop("p")}else if(f.tag_name==="rp"||f.tag_name==="rt")h=h||this._tag_stack.try_pop("rt",["ruby","rtc"]),h=h||this._tag_stack.try_pop("rp",["ruby","rtc"]);else if(f.tag_name==="optgroup")h=h||this._tag_stack.try_pop("optgroup",["select"]);else if(f.tag_name==="option")h=h||this._tag_stack.try_pop("option",["select","datalist","optgroup"]);else if(f.tag_name==="colgroup")h=h||this._tag_stack.try_pop("caption",["table"]);else if(f.tag_name==="thead")h=h||this._tag_stack.try_pop("caption",["table"]),h=h||this._tag_stack.try_pop("colgroup",["table"]);else if(f.tag_name==="tbody"||f.tag_name==="tfoot")h=h||this._tag_stack.try_pop("caption",["table"]),h=h||this._tag_stack.try_pop("colgroup",["table"]),h=h||this._tag_stack.try_pop("thead",["table"]),h=h||this._tag_stack.try_pop("tbody",["table"]);else if(f.tag_name==="tr")h=h||this._tag_stack.try_pop("caption",["table"]),h=h||this._tag_stack.try_pop("colgroup",["table"]),h=h||this._tag_stack.try_pop("tr",["table","thead","tbody","tfoot"]);else if(f.tag_name==="th"||f.tag_name==="td")h=h||this._tag_stack.try_pop("td",["table","thead","tbody","tfoot","tr"]),h=h||this._tag_stack.try_pop("th",["table","thead","tbody","tfoot","tr"]);return f.parent=this._tag_stack.get_parser_token(),h};aH.Beautifier=ff});var xw=z((WW,KA)=>{function _H(f,h,R,I){var A=new xH(f,h,R,I);return A.beautify()}var xH=kw().Beautifier,iH=qA().Options;KA.exports=_H;KA.exports.defaultOptions=function(){return new iH}});var pw=z((eH,iR)=>{function ow(f,h,R,I){return R=R||iw,I=I||_w,ew(f,h,R,I)}var iw=Jw(),_w=dw(),ew=xw();ow.defaultOptions=ew.defaultOptions;eH.js=iw;eH.css=_w;eH.html=ow});var tw=z((MW,uw)=>{function nw(f,h,R){var I=function(A,s){return f.js_beautify(A,s)};return I.js=f.js_beautify,I.css=h.css_beautify,I.html=R.html_beautify,I.js_beautify=f.js_beautify,I.css_beautify=h.css_beautify,I.html_beautify=R.html_beautify,I}if(typeof define==="function"&&define.amd)define(["./lib/beautify","./lib/beautify-css","./lib/beautify-html"],function(f,h,R){return nw(f,h,R)});else(function(f){var h=pw();h.js_beautify=h.js,h.css_beautify=h.css,h.html_beautify=h.html,f.exports=nw(h,h,h)})(uw)});class Of{}class jh extends Of{f;constructor(f=`${process.env.ROOT_DIR}/storage`){super();this.folderPath=f}async put(f){let h,R;if(f instanceof Blob)h=f,R=`${Oh()}.${f.type.split("/")[1].split(";")[0]}`;else h=f.body,R=f.name;const I=h instanceof Buffer?h:Buffer.from(await h.arrayBuffer()),A=`${this.folderPath}/${R}`;return await Bun.write(A,I),R}async fetch(f){let h=process.env.BUCKET_NAME,R;if(typeof f==="string")R=f;else h=f.bucket??h,R=f.name;if(!R)throw new Error("Object name has to be specified");const I=`${this.folderPath}/${R}`,A=Bun.file(I),s=Bun.file(I).stream(),S=new Date(A.lastModified).toUTCString();return new Response(s,{headers:{"Content-Type":A.type,"Content-Length":String(A.size),"Cache-Control":"private, max-age=12000, must-revalidate","Last-Modified":S}})}}class bA extends If{driver=new jh;boot(){}}function Tm(f){return(h)=>async(R)=>{const{request:I}=R;if(hf.isInstance(I)&&I.body&&f.runtime==="node"){if(f.requestHandler?.constructor?.name!=="FetchHttpHandler")I.headers={...I.headers,Expect:"100-continue"}}return h({...R,request:I})}}var $m={step:"build",tags:["SET_EXPECT_HEADER","EXPECT_HEADER"],name:"addExpectContinueMiddleware",override:!0},aA=(f)=>({applyToStack:(h)=>{h.add(Tm(f),$m)}});var Ih={WHEN_SUPPORTED:"WHEN_SUPPORTED",WHEN_REQUIRED:"WHEN_REQUIRED"},Kh=Ih.WHEN_SUPPORTED,pR={WHEN_SUPPORTED:"WHEN_SUPPORTED",WHEN_REQUIRED:"WHEN_REQUIRED"},vh=Ih.WHEN_SUPPORTED,B;(function(f){f.MD5="MD5",f.CRC32="CRC32",f.CRC32C="CRC32C",f.SHA1="SHA1",f.SHA256="SHA256"})(B||(B={}));var kA;(function(f){f.HEADER="header",f.TRAILER="trailer"})(kA||(kA={}));var{MD5:xA,CRC32:iA}=B;var Lf;(function(f){f.ENV="env",f.CONFIG="shared config entry"})(Lf||(Lf={}));var jf=(f,h,R,I)=>{if(!(h in f))return;const A=f[h].toUpperCase();if(!Object.values(R).includes(A))throw new TypeError(`Cannot load ${I} '${h}'. Expected one of ${Object.values(R)}, got '${f[h]}'.`);return A};var Lm="AWS_REQUEST_CHECKSUM_CALCULATION",Wm="request_checksum_calculation",_A={environmentVariableSelector:(f)=>jf(f,Lm,Ih,Lf.ENV),configFileSelector:(f)=>jf(f,Wm,Ih,Lf.CONFIG),default:Kh};var Mm="AWS_RESPONSE_CHECKSUM_VALIDATION",gm="response_checksum_validation",eA={environmentVariableSelector:(f)=>jf(f,Mm,pR,Lf.ENV),configFileSelector:(f)=>jf(f,gm,pR,Lf.CONFIG),default:vh};var Ah=[B.CRC32,B.CRC32C,B.SHA1,B.SHA256],oA=[B.CRC32,B.CRC32C,B.SHA1,B.SHA256];var pA=(f,{requestChecksumRequired:h,requestAlgorithmMember:R},I)=>{const A=I?iA:xA;if(!R||!f[R])return h?A:void 0;const s=f[R];if(!Ah.includes(s))throw new Error(`The checksum algorithm "${s}" is not supported by the client. Select one of ${Ah}.`);return s};var Kf=(f)=>f===B.MD5?"content-md5":`x-amz-checksum-${f.toLowerCase()}`;var nA=(f,h)=>{const R=f.toLowerCase();for(let I of Object.keys(h))if(R===I.toLowerCase())return!0;return!1};var uA=K(Gm(),1),vf=(f)=>f!==void 0&&typeof f!=="string"&&!ArrayBuffer.isView(f)&&!uA.isArrayBuffer(f);var tA=K(Cm(),1),{__extends:_D,__assign:eD,__rest:oD,__decorate:pD,__param:nD,__esDecorate:uD,__runInitializers:tD,__propKey:fF,__setFunctionName:hF,__metadata:RF,__awaiter:rh,__generator:ch,__exportStar:IF,__createBinding:AF,__values:bh,__read:sF,__spread:SF,__spreadArrays:wF,__spreadArray:mF,__await:EF,__asyncGenerator:PF,__asyncDelegator:UF,__asyncValues:HF,__makeTemplateObject:DF,__importStar:FF,__importDefault:NF,__classPrivateFieldGet:TF,__classPrivateFieldSet:$F,__classPrivateFieldIn:LF,__addDisposableResource:WF,__disposeResources:MF}=tA.default;import{Buffer as fs}from"buffer";var hs=(f,h)=>{if(typeof f!=="string")throw new TypeError(`The "input" argument must be of type string. Received type ${typeof f} (${f})`);return h?fs.from(f,h):fs.from(f)};var nR=(f)=>{const h=hs(f,"utf8");return new Uint8Array(h.buffer,h.byteOffset,h.byteLength/Uint8Array.BYTES_PER_ELEMENT)};function sh(f){if(f instanceof Uint8Array)return f;if(typeof f==="string")return Ym(f);if(ArrayBuffer.isView(f))return new Uint8Array(f.buffer,f.byteOffset,f.byteLength/Uint8Array.BYTES_PER_ELEMENT);return new Uint8Array(f)}var Ym=typeof Buffer!=="undefined"&&Buffer.from?function(f){return Buffer.from(f,"utf8")}:nR;function Sh(f){if(typeof f==="string")return f.length===0;return f.byteLength===0}function wh(f){return new Uint8Array([(f&4278190080)>>24,(f&16711680)>>16,(f&65280)>>8,f&255])}function mh(f){if(!Uint32Array.from){var h=new Uint32Array(f.length),R=0;while(R<f.length)h[R]=f[R],R+=1;return h}return Uint32Array.from(f)}var uR=function(){function f(){this.crc32=new Jf}return f.prototype.update=function(h){if(Sh(h))return;this.crc32.update(sh(h))},f.prototype.digest=function(){return rh(this,void 0,void 0,function(){return ch(this,function(h){return[2,wh(this.crc32.digest())]})})},f.prototype.reset=function(){this.crc32=new Jf},f}();var Jf=function(){function f(){this.checksum=4294967295}return f.prototype.update=function(h){var R,I;try{for(var A=bh(h),s=A.next();!s.done;s=A.next()){var S=s.value;this.checksum=this.checksum>>>8^Zm[(this.checksum^S)&255]}}catch(w){R={error:w}}finally{try{if(s&&!s.done&&(I=A.return))I.call(A)}finally{if(R)throw R.error}}return this},f.prototype.digest=function(){return(this.checksum^4294967295)>>>0},f}();var Xm=[0,1996959894,3993919788,2567524794,124634137,1886057615,3915621685,2657392035,249268274,2044508324,3772115230,2547177864,162941995,2125561021,3887607047,2428444049,498536548,1789927666,4089016648,2227061214,450548861,1843258603,4107580753,2211677639,325883990,1684777152,4251122042,2321926636,335633487,1661365465,4195302755,2366115317,997073096,1281953886,3579855332,2724688242,1006888145,1258607687,3524101629,2768942443,901097722,1119000684,3686517206,2898065728,853044451,1172266101,3705015759,2882616665,651767980,1373503546,3369554304,3218104598,565507253,1454621731,3485111705,3099436303,671266974,1594198024,3322730930,2970347812,795835527,1483230225,3244367275,3060149565,1994146192,31158534,2563907772,4023717930,1907459465,112637215,2680153253,3904427059,2013776290,251722036,2517215374,3775830040,2137656763,141376813,2439277719,3865271297,1802195444,476864866,2238001368,4066508878,1812370925,453092731,2181625025,4111451223,1706088902,314042704,2344532202,4240017532,1658658271,366619977,2362670323,4224994405,1303535960,984961486,2747007092,3569037538,1256170817,1037604311,2765210733,3554079995,1131014506,879679996,2909243462,3663771856,1141124467,855842277,2852801631,3708648649,1342533948,654459306,3188396048,3373015174,1466479909,544179635,3110523913,3462522015,1591671054,702138776,2966460450,3352799412,1504918807,783551873,3082640443,3233442989,3988292384,2596254646,62317068,1957810842,3939845945,2647816111,81470997,1943803523,3814918930,2489596804,225274430,2053790376,3826175755,2466906013,167816743,2097651377,4027552580,2265490386,503444072,1762050814,4150417245,2154129355,426522225,1852507879,4275313526,2312317920,282753626,1742555852,4189708143,2394877945,397917763,1622183637,3604390888,2714866558,953729732,1340076626,3518719985,2797360999,1068828381,1219638859,3624741850,2936675148,906185462,1090812512,3747672003,2825379669,829329135,1181335161,3412177804,3160834842,628085408,1382605366,3423369109,3138078467,570562233,1426400815,3317316542,2998733608,733239954,1555261956,3268935591,3050360625,752459403,1541320221,2607071920,3965973030,1969922972,40735498,2617837225,3943577151,1913087877,83908371,2512341634,3803740692,2075208622,213261112,2463272603,3855990285,2094854071,198958881,2262029012,4057260610,1759359992,534414190,2176718541,4139329115,1873836001,414664567,2282248934,4279200368,1711684554,285281116,2405801727,4167216745,1634467795,376229701,2685067896,3608007406,1308918612,956543938,2808555105,3495958263,1231636301,1047427035,2932959818,3654703836,1088359270,936918000,2847714899,3736837829,1202900863,817233897,3183342108,3401237130,1404277552,615818150,3134207493,3453421203,1423857449,601450431,3009837614,3294710456,1567103746,711928724,3020668471,3272380065,1510334235,755167117],Zm=mh(Xm);var fI=function(){function f(){this.crc32c=new tR}return f.prototype.update=function(h){if(Sh(h))return;this.crc32c.update(sh(h))},f.prototype.digest=function(){return rh(this,void 0,void 0,function(){return ch(this,function(h){return[2,wh(this.crc32c.digest())]})})},f.prototype.reset=function(){this.crc32c=new tR},f}();var tR=function(){function f(){this.checksum=4294967295}return f.prototype.update=function(h){var R,I;try{for(var A=bh(h),s=A.next();!s.done;s=A.next()){var S=s.value;this.checksum=this.checksum>>>8^Vm[(this.checksum^S)&255]}}catch(w){R={error:w}}finally{try{if(s&&!s.done&&(I=A.return))I.call(A)}finally{if(R)throw R.error}}return this},f.prototype.digest=function(){return(this.checksum^4294967295)>>>0},f}();var Jm=[0,4067132163,3778769143,324072436,3348797215,904991772,648144872,3570033899,2329499855,2024987596,1809983544,2575936315,1296289744,3207089363,2893594407,1578318884,274646895,3795141740,4049975192,51262619,3619967088,632279923,922689671,3298075524,2592579488,1760304291,2075979607,2312596564,1562183871,2943781820,3156637768,1313733451,549293790,3537243613,3246849577,871202090,3878099393,357341890,102525238,4101499445,2858735121,1477399826,1264559846,3107202533,1845379342,2677391885,2361733625,2125378298,820201905,3263744690,3520608582,598981189,4151959214,85089709,373468761,3827903834,3124367742,1213305469,1526817161,2842354314,2107672161,2412447074,2627466902,1861252501,1098587580,3004210879,2688576843,1378610760,2262928035,1955203488,1742404180,2511436119,3416409459,969524848,714683780,3639785095,205050476,4266873199,3976438427,526918040,1361435347,2739821008,2954799652,1114974503,2529119692,1691668175,2005155131,2247081528,3690758684,697762079,986182379,3366744552,476452099,3993867776,4250756596,255256311,1640403810,2477592673,2164122517,1922457750,2791048317,1412925310,1197962378,3037525897,3944729517,427051182,170179418,4165941337,746937522,3740196785,3451792453,1070968646,1905808397,2213795598,2426610938,1657317369,3053634322,1147748369,1463399397,2773627110,4215344322,153784257,444234805,3893493558,1021025245,3467647198,3722505002,797665321,2197175160,1889384571,1674398607,2443626636,1164749927,3070701412,2757221520,1446797203,137323447,4198817972,3910406976,461344835,3484808360,1037989803,781091935,3705997148,2460548119,1623424788,1939049696,2180517859,1429367560,2807687179,3020495871,1180866812,410100952,3927582683,4182430767,186734380,3756733383,763408580,1053836080,3434856499,2722870694,1344288421,1131464017,2971354706,1708204729,2545590714,2229949006,1988219213,680717673,3673779818,3383336350,1002577565,4010310262,493091189,238226049,4233660802,2987750089,1082061258,1395524158,2705686845,1972364758,2279892693,2494862625,1725896226,952904198,3399985413,3656866545,731699698,4283874585,222117402,510512622,3959836397,3280807620,837199303,582374963,3504198960,68661723,4135334616,3844915500,390545967,1230274059,3141532936,2825850620,1510247935,2395924756,2091215383,1878366691,2644384480,3553878443,565732008,854102364,3229815391,340358836,3861050807,4117890627,119113024,1493875044,2875275879,3090270611,1247431312,2660249211,1828433272,2141937292,2378227087,3811616794,291187481,34330861,4032846830,615137029,3603020806,3314634738,939183345,1776939221,2609017814,2295496738,2058945313,2926798794,1545135305,1330124605,3173225534,4084100981,17165430,307568514,3762199681,888469610,3332340585,3587147933,665062302,2042050490,2346497209,2559330125,1793573966,3190661285,1279665062,1595330642,2910671697],Vm=mh(Jm);var ah=(f,h)=>({[B.MD5]:h.md5,[B.CRC32]:uR,[B.CRC32C]:fI,[B.SHA1]:h.sha1,[B.SHA256]:h.sha256})[f];var Rs=K(hI(),1),kh=(f,h)=>{const R=new f;return R.update(Rs.toUint8Array(h||"")),R.digest()};var Is={name:"flexibleChecksumsMiddleware",step:"build",tags:["BODY_CHECKSUM"],override:!0},As=(f,h)=>(R,I)=>async(A)=>{if(!hf.isInstance(A.request))return R(A);const{request:s}=A,{body:S,headers:w}=s,{base64Encoder:E,streamHasher:P}=f,{input:N,requestChecksumRequired:G,requestAlgorithmMember:M}=h,g=pA(N,{requestChecksumRequired:G,requestAlgorithmMember:M},!!I.isS3ExpressBucket);let j=S,_=w;if(g){const e=Kf(g),Nf=ah(g,f);if(vf(S)){const{getAwsChunkedEncodingStream:Rh,bodyLengthChecker:dh}=f;j=Rh(S,{base64Encoder:E,bodyLengthChecker:dh,checksumLocationName:e,checksumAlgorithmFn:Nf,streamHasher:P}),_={...w,"content-encoding":w["content-encoding"]?`${w["content-encoding"]},aws-chunked`:"aws-chunked","transfer-encoding":"chunked","x-amz-decoded-content-length":w["content-length"],"x-amz-content-sha256":"STREAMING-UNSIGNED-PAYLOAD-TRAILER","x-amz-trailer":e},delete _["content-length"]}else if(!nA(e,w)){const Rh=await kh(Nf,S);_={...w,[e]:E(Rh)}}}return await R({...A,request:{...s,headers:_,body:j}})};var xh=(f=[])=>{const h=[];for(let R of oA){if(!f.includes(R)||!Ah.includes(R))continue;h.push(R)}return h};var ss=(f)=>{const h=f.lastIndexOf("-");if(h!==-1){const R=f.slice(h+1);if(!R.startsWith("0")){const I=parseInt(R,10);if(!isNaN(I)&&I>=1&&I<=1e4)return!0}}return!1};import{Transform as Qm}from"stream";function RI(f){const h=new Qm;return h.push(f),h.push(null),h}var Ss=async(f,{streamHasher:h,checksumAlgorithmFn:R,base64Encoder:I})=>{const A=vf(f)?h(R,f):kh(R,f);return I(await A)};var ws=async(f,{config:h,responseAlgorithms:R})=>{const I=xh(R),{body:A,headers:s}=f;for(let S of I){const w=Kf(S),E=s[w];if(E){const P=ah(S,h),{streamHasher:N,base64Encoder:G}=h,M=await Ss(A,{streamHasher:N,checksumAlgorithmFn:P,base64Encoder:G});if(M===E)break;throw new Error(`Checksum mismatch: expected "${M}" but received "${E}" in response header "${w}".`)}}};var ms={name:"flexibleChecksumsResponseMiddleware",toMiddleware:"deserializerMiddleware",relation:"after",tags:["BODY_CHECKSUM"],override:!0},Es=(f,h)=>(R,I)=>async(A)=>{if(!hf.isInstance(A.request))return R(A);const s=A.input,S=await R(A),w=S.response;let E=void 0;const{requestValidationModeMember:P,responseAlgorithms:N}=h;if(P&&s[P]==="ENABLED"){const{clientName:G,commandName:M}=I;if(G==="S3Client"&&M==="GetObjectCommand"&&xh(N).every((_)=>{const wf=Kf(_),e=w.headers[wf];return!e||ss(e)}))return S;const j=vf(w.body);if(j)E=await f.streamCollector(w.body),w.body=RI(E);if(await ws(S.response,{config:f,responseAlgorithms:N}),j&&E)w.body=RI(E)}return S};var ih=(f,h)=>({applyToStack:(R)=>{R.add(As(f,h),Is),R.addRelativeTo(Es(f,h),ms)}});var Ps=(f)=>({...f,requestChecksumCalculation:Eh(f.requestChecksumCalculation??Kh),responseChecksumValidation:Eh(f.responseChecksumValidation??vh)});function Bm(){return(f,h)=>async(R)=>{const{request:I}=R;if(hf.isInstance(I)){if(!(zm in I.headers))if(typeof h?.logger?.warn==="function"&&!(h.logger instanceof _h))h.logger.warn("Are you using a Stream of unknown length as the Body of a PutObject request? Consider using Upload instead from @aws-sdk/lib-storage.");else console.warn("Are you using a Stream of unknown length as the Body of a PutObject request? Consider using Upload instead from @aws-sdk/lib-storage.")}return f({...R})}}var zm="content-length",lm={step:"finalizeRequest",tags:["CHECK_CONTENT_LENGTH_HEADER"],name:"getCheckContentLengthHeaderPlugin",override:!0},Us=(f)=>({applyToStack:(h)=>{h.add(Bm(),lm)}});var Hs=(f)=>{return(h,R)=>async(I)=>{const A=await f.region(),s=f.region;let S=()=>{};if(R.__s3RegionRedirect)Object.defineProperty(f,"region",{writable:!1,value:async()=>{return R.__s3RegionRedirect}}),S=()=>Object.defineProperty(f,"region",{writable:!0,value:s});try{const w=await h(I);if(R.__s3RegionRedirect){S();const E=await f.region();if(A!==E)throw new Error("Region was not restored following S3 region redirect.")}return w}catch(w){throw S(),w}}},Ds={tags:["REGION_REDIRECT","S3"],name:"regionRedirectEndpointMiddleware",override:!0,relation:"before",toMiddleware:"endpointV2Middleware"};function ym(f){return(h,R)=>async(I)=>{try{return await h(I)}catch(A){if(f.followRegionRedirects&&A?.$metadata?.httpStatusCode===301){try{const s=A.$response.headers["x-amz-bucket-region"];R.logger?.debug(`Redirecting from ${await f.region()} to ${s}`),R.__s3RegionRedirect=s}catch(s){throw new Error("Region redirect failed: "+s)}return h(I)}else throw A}}}var qm={step:"initialize",tags:["REGION_REDIRECT","S3"],name:"regionRedirectMiddleware",override:!0},Fs=(f)=>({applyToStack:(h)=>{h.add(ym(f),qm),h.addRelativeTo(Hs(f),Ds)}});var dm=(f)=>{return(h,R)=>async(I)=>{const A=await h(I),{response:s}=A;if(eh.isInstance(s)){if(s.headers.expires){s.headers.expiresstring=s.headers.expires;try{Ph(s.headers.expires)}catch(S){R.logger?.warn(`AWS SDK Warning for ${R.clientName}::${R.commandName} response parsing (${s.headers.expires}): ${S}`),delete s.headers.expires}}}return A}},Om={tags:["S3"],name:"s3ExpiresMiddleware",override:!0,relation:"after",toMiddleware:"deserializerMiddleware"},Ns=(f)=>({applyToStack:(h)=>{h.addRelativeTo(dm(f),Om)}});class rf{constructor(f={}){this.data=f,this.lastPurgeTime=Date.now()}get(f){const h=this.data[f];if(!h)return;return h}set(f,h){return this.data[f]=h,h}delete(f){delete this.data[f]}async purgeExpired(){const f=Date.now();if(this.lastPurgeTime+rf.EXPIRED_CREDENTIAL_PURGE_INTERVAL_MS>f)return;for(let h in this.data){const R=this.data[h];if(!R.isRefreshing){const I=await R.identity;if(I.expiration){if(I.expiration.getTime()<f)delete this.data[h]}}}}}rf.EXPIRED_CREDENTIAL_PURGE_INTERVAL_MS=30000;class cf{constructor(f,h=!1,R=Date.now()){this._identity=f,this.isRefreshing=h,this.accessed=R}get identity(){return this.accessed=Date.now(),this._identity}}class bf{constructor(f,h=new rf){this.createSessionFn=f,this.cache=h}async getS3ExpressIdentity(f,h){const R=h.Bucket,{cache:I}=this,A=I.get(R);if(A)return A.identity.then((s)=>{if((s.expiration?.getTime()??0)<Date.now())return I.set(R,new cf(this.getIdentity(R))).identity;if((s.expiration?.getTime()??0)<Date.now()+bf.REFRESH_WINDOW_MS&&!A.isRefreshing)A.isRefreshing=!0,this.getIdentity(R).then((E)=>{I.set(R,new cf(Promise.resolve(E)))});return s});return I.set(R,new cf(this.getIdentity(R))).identity}async getIdentity(f){await this.cache.purgeExpired().catch((I)=>{console.warn("Error while clearing expired entries in S3ExpressIdentityCache: \n"+I)});const h=await this.createSessionFn(f);if(!h.Credentials?.AccessKeyId||!h.Credentials?.SecretAccessKey)throw new Error("s3#createSession response credential missing AccessKeyId or SecretAccessKey.");return{accessKeyId:h.Credentials.AccessKeyId,secretAccessKey:h.Credentials.SecretAccessKey,sessionToken:h.Credentials.SessionToken,expiration:h.Credentials.Expiration?new Date(h.Credentials.Expiration):void 0}}}bf.REFRESH_WINDOW_MS=60000;var gs=K(vm(),1);var Ts="Directory",$s="S3Express",Ls="sigv4-s3express",oh="X-Amz-S3session-Token",Uh=oh.toLowerCase(),jm="AWS_S3_DISABLE_EXPRESS_SESSION_AUTH",Km="s3_disable_express_session_auth",II={environmentVariableSelector:(f)=>Vf(f,jm,Qf.ENV),configFileSelector:(f)=>Vf(f,Km,Qf.CONFIG),default:!1};function Ws(f){return{accessKeyId:f.accessKeyId,secretAccessKey:f.secretAccessKey,expiration:f.expiration}}function Ms(f,h){const R=setTimeout(()=>{throw new Error("SignatureV4S3Express credential override was created but not called.")},10),I=f.credentialProvider,A=()=>{return clearTimeout(R),f.credentialProvider=I,Promise.resolve(h)};f.credentialProvider=A}class ph extends gs.SignatureV4{async signWithCredentials(f,h,R){const I=Ws(h);f.headers[Uh]=h.sessionToken;const A=this;return Ms(A,I),A.signRequest(f,R??{})}async presignWithCredentials(f,h,R){const I=Ws(h);return delete f.headers[Uh],f.headers[oh]=h.sessionToken,f.query=f.query??{},f.query[oh]=h.sessionToken,Ms(this,I),this.presign(f,R)}}var Gs=(f)=>{return(h,R)=>async(I)=>{if(R.endpointV2){const A=R.endpointV2,s=A.properties?.authSchemes?.[0]?.name===Ls;if(A.properties?.backend===$s||A.properties?.bucketType===Ts)R.isS3ExpressBucket=!0;if(s){const w=I.input.Bucket;if(w){const E=await f.s3ExpressIdentityProvider.getS3ExpressIdentity(await f.credentials(),{Bucket:w});if(R.s3ExpressIdentity=E,hf.isInstance(I.request)&&E.sessionToken)I.request.headers[Uh]=E.sessionToken}}}return h(I)}},Cs={name:"s3ExpressMiddleware",step:"build",tags:["S3","S3_EXPRESS"],override:!0},AI=(f)=>({applyToStack:(h)=>{h.add(Gs(f),Cs)}});var Xs=K(sI(),1);var Ys=async(f,h,R,I)=>{const A=await I.signWithCredentials(R,f,{});if(A.headers["X-Amz-Security-Token"]||A.headers["x-amz-security-token"])throw new Error("X-Amz-Security-Token must not be set for s3-express requests.");return A};var rm=(f)=>(h)=>{throw h},cm=(f,h)=>{};var Zs=(f)=>(h,R)=>async(I)=>{if(!hf.isInstance(I.request))return h(I);const s=Hh(R).selectedHttpAuthScheme;if(!s)throw new Error("No HttpAuthScheme was selected: unable to sign request");const{httpAuthOption:{signingProperties:S={}},identity:w,signer:E}=s;let P;if(R.s3ExpressIdentity)P=await Ys(R.s3ExpressIdentity,S,I.request,await f.signer());else P=await E.sign(I.request,w,S);const N=await h({...I,request:P}).catch((E.errorHandler||rm)(S));return(E.successHandler||cm)(N.response,S),N},SI=(f)=>({applyToStack:(h)=>{h.addRelativeTo(Zs(f),Xs.httpSigningMiddlewareOptions)}});var Js=(f,{session:h})=>{const[R,I]=h;return{...f,forcePathStyle:f.forcePathStyle??!1,useAccelerateEndpoint:f.useAccelerateEndpoint??!1,disableMultiregionAccessPoints:f.disableMultiregionAccessPoints??!1,followRegionRedirects:f.followRegionRedirects??!1,s3ExpressIdentityProvider:f.s3ExpressIdentityProvider??new bf(async(A)=>R().send(new I({Bucket:A,SessionMode:"ReadWrite"}))),bucketEndpoint:f.bucketEndpoint??!1}};var nh=K(Vs(),1),bm={CopyObjectCommand:!0,UploadPartCopyCommand:!0,CompleteMultipartUploadCommand:!0},am=3000,km=(f)=>(h,R)=>async(I)=>{const A=await h(I),{response:s}=A;if(!eh.isInstance(s))return A;const{statusCode:S,body:w}=s;if(S<200||S>=300)return A;if(!(typeof w?.stream==="function"||typeof w?.pipe==="function"||typeof w?.tee==="function"))return A;let P=w,N=w;if(w&&typeof w==="object"&&!(w instanceof Uint8Array))[P,N]=await nh.splitStream(w);s.body=N;const G=await xm(P,{streamCollector:async(g)=>{return nh.headStream(g,am)}});if(typeof P?.destroy==="function")P.destroy();const M=f.utf8Encoder(G.subarray(G.length-16));if(G.length===0&&bm[R.commandName]){const g=new Error("S3 aborted request");throw g.name="InternalError",g}if(M&&M.endsWith("</Error>"))s.statusCode=400;return A},xm=(f=new Uint8Array,h)=>{if(f instanceof Uint8Array)return Promise.resolve(f);return h.streamCollector(f)||Promise.resolve(new Uint8Array)},im={relation:"after",toMiddleware:"deserializerMiddleware",tags:["THROW_200_EXCEPTIONS","S3"],name:"throw200ExceptionsMiddleware",override:!0},uh=(f)=>({applyToStack:(h)=>{h.addRelativeTo(km(f),im)}});var wI=(f)=>typeof f==="string"&&f.indexOf("arn:")===0&&f.split(":").length>=6;function Qs(f){return(h,R)=>async(I)=>{if(f.bucketEndpoint){const A=R.endpointV2;if(A){const s=I.input.Bucket;if(typeof s==="string")try{const S=new URL(s);R.endpointV2={...A,url:S}}catch(S){const w=`@aws-sdk/middleware-sdk-s3: bucketEndpoint=true was set but Bucket=${s} could not be parsed as URL.`;if(R.logger?.constructor?.name==="NoOpLogger")console.warn(w);else R.logger?.warn?.(w);throw S}}}return h(I)}}var zs={name:"bucketEndpointMiddleware",override:!0,relation:"after",toMiddleware:"endpointV2Middleware"};function _m({bucketEndpoint:f}){return(h)=>async(R)=>{const{input:{Bucket:I}}=R;if(!f&&typeof I==="string"&&!wI(I)&&I.indexOf("/")>=0){const A=new Error(`Bucket name shouldn't contain '/', received '${I}'`);throw A.name="InvalidBucketName",A}return h({...R})}}var em={step:"initialize",tags:["VALIDATE_BUCKET_NAME"],name:"validateBucketNameMiddleware",override:!0},Bs=(f)=>({applyToStack:(h)=>{h.add(_m(f),em),h.addRelativeTo(Qs(f),zs)}});var hh=K(sI(),1);var ls=(f)=>({...f,eventStreamMarshaller:f.eventStreamSerdeProvider(f)});var mR=K(wR(),1);var th={CrtSignerV4:null};class mI{constructor(f){this.sigv4Signer=new ph(f),this.signerOptions=f}async sign(f,h={}){if(h.signingRegion==="*"){if(this.signerOptions.runtime!=="node")throw new Error("This request requires signing with SigV4Asymmetric algorithm. It's only available in Node.js");return this.getSigv4aSigner().sign(f,h)}return this.sigv4Signer.sign(f,h)}async signWithCredentials(f,h,R={}){if(R.signingRegion==="*"){if(this.signerOptions.runtime!=="node")throw new Error("This request requires signing with SigV4Asymmetric algorithm. It's only available in Node.js");return this.getSigv4aSigner().signWithCredentials(f,h,R)}return this.sigv4Signer.signWithCredentials(f,h,R)}async presign(f,h={}){if(h.signingRegion==="*"){if(this.signerOptions.runtime!=="node")throw new Error("This request requires signing with SigV4Asymmetric algorithm. It's only available in Node.js");return this.getSigv4aSigner().presign(f,h)}return this.sigv4Signer.presign(f,h)}async presignWithCredentials(f,h,R={}){if(R.signingRegion==="*")throw new Error("Method presignWithCredentials is not supported for [signingRegion=*].");return this.sigv4Signer.presignWithCredentials(f,h,R)}getSigv4aSigner(){if(!this.sigv4aSigner){let f=null;try{if(f=th.CrtSignerV4,typeof f!=="function")throw new Error}catch(h){throw h.message=`${h.message}\nPlease check whether you have installed the "@aws-sdk/signature-v4-crt" package explicitly. \nYou must also register the package by calling [require("@aws-sdk/signature-v4-crt");] or an ESM equivalent such as [import "@aws-sdk/signature-v4-crt";]. \nFor more information please go to https://github.com/aws/aws-sdk-js-v3#functionality-requiring-aws-common-runtime-crt`,h}this.sigv4aSigner=new f({...this.signerOptions,signingAlgorithm:1})}return this.sigv4aSigner}}var af={["required"]:!1,["type"]:"String"},kf={["required"]:!0,default:!1,["type"]:"Boolean"},Dh={["required"]:!1,["type"]:"Boolean"},mf={["fn"]:"booleanEquals",["argv"]:[{["ref"]:"Accelerate"},!0]},Q={["fn"]:"booleanEquals",["argv"]:[{["ref"]:"UseFIPS"},!0]},V={["fn"]:"booleanEquals",["argv"]:[{["ref"]:"UseDualStack"},!0]},y={["fn"]:"isSet",["argv"]:[{["ref"]:"Endpoint"}]},CS={["fn"]:"aws.partition",["argv"]:[{["ref"]:"Region"}],["assign"]:"partitionResult"},ys={["fn"]:"stringEquals",["argv"]:[{["fn"]:"getAttr",["argv"]:[{["ref"]:"partitionResult"},"name"]},"aws-cn"]},AR={["fn"]:"isSet",["argv"]:[{["ref"]:"Bucket"}]},p={["ref"]:"Bucket"},o={["fn"]:"parseURL",["argv"]:[{["ref"]:"Endpoint"}],["assign"]:"url"},IR={["fn"]:"booleanEquals",["argv"]:[{["fn"]:"getAttr",["argv"]:[{["ref"]:"url"},"isIp"]},!0]},YS={["ref"]:"url"},XS={["fn"]:"uriEncode",["argv"]:[p],["assign"]:"uri_encoded_bucket"},Tf={["backend"]:"S3Express",["authSchemes"]:[{["disableDoubleEncoding"]:!0,["name"]:"sigv4",["signingName"]:"s3express",["signingRegion"]:"{Region}"}]},D={},ZS={["fn"]:"aws.isVirtualHostableS3Bucket",["argv"]:[p,!1]},EI={["error"]:"S3Express bucket name is not a valid virtual hostable name.",["type"]:"error"},sR={["backend"]:"S3Express",["authSchemes"]:[{["disableDoubleEncoding"]:!0,["name"]:"sigv4-s3express",["signingName"]:"s3express",["signingRegion"]:"{Region}"}]},qs={["fn"]:"isSet",["argv"]:[{["ref"]:"UseS3ExpressControlEndpoint"}]},ds={["fn"]:"booleanEquals",["argv"]:[{["ref"]:"UseS3ExpressControlEndpoint"},!0]},F={["fn"]:"not",["argv"]:[y]},Os={["error"]:"Unrecognized S3Express bucket name format.",["type"]:"error"},js={["fn"]:"not",["argv"]:[AR]},Ks={["ref"]:"hardwareType"},vs={["conditions"]:[F],["error"]:"Expected a endpoint to be specified but no endpoint was found",["type"]:"error"},fR={["authSchemes"]:[{["disableDoubleEncoding"]:!0,["name"]:"sigv4a",["signingName"]:"s3-outposts",["signingRegionSet"]:["*"]},{["disableDoubleEncoding"]:!0,["name"]:"sigv4",["signingName"]:"s3-outposts",["signingRegion"]:"{Region}"}]},PI={["fn"]:"booleanEquals",["argv"]:[{["ref"]:"ForcePathStyle"},!1]},om={["ref"]:"ForcePathStyle"},l={["fn"]:"booleanEquals",["argv"]:[{["ref"]:"Accelerate"},!1]},d={["fn"]:"stringEquals",["argv"]:[{["ref"]:"Region"},"aws-global"]},v={["authSchemes"]:[{["disableDoubleEncoding"]:!0,["name"]:"sigv4",["signingName"]:"s3",["signingRegion"]:"us-east-1"}]},W={["fn"]:"not",["argv"]:[d]},r={["fn"]:"booleanEquals",["argv"]:[{["ref"]:"UseGlobalEndpoint"},!0]},rs={["url"]:"https://{Bucket}.s3-fips.dualstack.{Region}.{partitionResult#dnsSuffix}",["properties"]:{["authSchemes"]:[{["disableDoubleEncoding"]:!0,["name"]:"sigv4",["signingName"]:"s3",["signingRegion"]:"{Region}"}]},["headers"]:{}},q={["authSchemes"]:[{["disableDoubleEncoding"]:!0,["name"]:"sigv4",["signingName"]:"s3",["signingRegion"]:"{Region}"}]},c={["fn"]:"booleanEquals",["argv"]:[{["ref"]:"UseGlobalEndpoint"},!1]},L={["fn"]:"booleanEquals",["argv"]:[{["ref"]:"UseDualStack"},!1]},cs={["url"]:"https://{Bucket}.s3-fips.{Region}.{partitionResult#dnsSuffix}",["properties"]:q,["headers"]:{}},$={["fn"]:"booleanEquals",["argv"]:[{["ref"]:"UseFIPS"},!1]},bs={["url"]:"https://{Bucket}.s3-accelerate.dualstack.{partitionResult#dnsSuffix}",["properties"]:q,["headers"]:{}},as={["url"]:"https://{Bucket}.s3.dualstack.{Region}.{partitionResult#dnsSuffix}",["properties"]:q,["headers"]:{}},UI={["fn"]:"booleanEquals",["argv"]:[{["fn"]:"getAttr",["argv"]:[YS,"isIp"]},!1]},HI={["url"]:"{url#scheme}://{url#authority}{url#normalizedPath}{Bucket}",["properties"]:q,["headers"]:{}},lI={["url"]:"{url#scheme}://{Bucket}.{url#authority}{url#path}",["properties"]:q,["headers"]:{}},ks={["endpoint"]:lI,["type"]:"endpoint"},DI={["url"]:"https://{Bucket}.s3-accelerate.{partitionResult#dnsSuffix}",["properties"]:q,["headers"]:{}},xs={["url"]:"https://{Bucket}.s3.{Region}.{partitionResult#dnsSuffix}",["properties"]:q,["headers"]:{}},hR={["error"]:"Invalid region: region was not a valid DNS name.",["type"]:"error"},t={["ref"]:"bucketArn"},JS={["ref"]:"arnType"},FI={["fn"]:"getAttr",["argv"]:[t,"service"]},yI={["ref"]:"accessPointName"},is={["conditions"]:[V],["error"]:"S3 Object Lambda does not support Dual-stack",["type"]:"error"},_s={["conditions"]:[mf],["error"]:"S3 Object Lambda does not support S3 Accelerate",["type"]:"error"},es={["conditions"]:[{["fn"]:"isSet",["argv"]:[{["ref"]:"DisableAccessPoints"}]},{["fn"]:"booleanEquals",["argv"]:[{["ref"]:"DisableAccessPoints"},!0]}],["error"]:"Access points are not supported for this operation",["type"]:"error"},NI={["conditions"]:[{["fn"]:"isSet",["argv"]:[{["ref"]:"UseArnRegion"}]},{["fn"]:"booleanEquals",["argv"]:[{["ref"]:"UseArnRegion"},!1]},{["fn"]:"not",["argv"]:[{["fn"]:"stringEquals",["argv"]:[{["fn"]:"getAttr",["argv"]:[t,"region"]},"{Region}"]}]}],["error"]:"Invalid configuration: region from ARN `{bucketArn#region}` does not match client region `{Region}` and UseArnRegion is `false`",["type"]:"error"},VS={["fn"]:"getAttr",["argv"]:[{["ref"]:"bucketPartition"},"name"]},QS={["fn"]:"getAttr",["argv"]:[t,"accountId"]},TI={["authSchemes"]:[{["disableDoubleEncoding"]:!0,["name"]:"sigv4",["signingName"]:"s3-object-lambda",["signingRegion"]:"{bucketArn#region}"}]},os={["error"]:"Invalid ARN: The access point name may only contain a-z, A-Z, 0-9 and `-`. Found: `{accessPointName}`",["type"]:"error"},$I={["error"]:"Invalid ARN: The account id may only contain a-z, A-Z, 0-9 and `-`. Found: `{bucketArn#accountId}`",["type"]:"error"},LI={["error"]:"Invalid region in ARN: `{bucketArn#region}` (invalid DNS name)",["type"]:"error"},WI={["error"]:"Client was configured for partition `{partitionResult#name}` but ARN (`{Bucket}`) has `{bucketPartition#name}`",["type"]:"error"},ps={["error"]:"Invalid ARN: The ARN may only contain a single resource component after `accesspoint`.",["type"]:"error"},ns={["error"]:"Invalid ARN: Expected a resource of the format `accesspoint:<accesspoint name>` but no name was provided",["type"]:"error"},Fh={["authSchemes"]:[{["disableDoubleEncoding"]:!0,["name"]:"sigv4",["signingName"]:"s3",["signingRegion"]:"{bucketArn#region}"}]},us={["authSchemes"]:[{["disableDoubleEncoding"]:!0,["name"]:"sigv4a",["signingName"]:"s3-outposts",["signingRegionSet"]:["*"]},{["disableDoubleEncoding"]:!0,["name"]:"sigv4",["signingName"]:"s3-outposts",["signingRegion"]:"{bucketArn#region}"}]},ts={["fn"]:"aws.parseArn",["argv"]:[p]},fS={["url"]:"https://s3-fips.dualstack.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",["properties"]:q,["headers"]:{}},hS={["url"]:"https://s3-fips.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",["properties"]:q,["headers"]:{}},RS={["url"]:"https://s3.dualstack.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",["properties"]:q,["headers"]:{}},MI={["url"]:"{url#scheme}://{url#authority}{url#normalizedPath}{uri_encoded_bucket}",["properties"]:q,["headers"]:{}},IS={["url"]:"https://s3.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",["properties"]:q,["headers"]:{}},AS={["ref"]:"UseObjectLambdaEndpoint"},gI={["authSchemes"]:[{["disableDoubleEncoding"]:!0,["name"]:"sigv4",["signingName"]:"s3-object-lambda",["signingRegion"]:"{Region}"}]},sS={["url"]:"https://s3-fips.dualstack.{Region}.{partitionResult#dnsSuffix}",["properties"]:q,["headers"]:{}},SS={["url"]:"https://s3-fips.{Region}.{partitionResult#dnsSuffix}",["properties"]:q,["headers"]:{}},wS={["url"]:"https://s3.dualstack.{Region}.{partitionResult#dnsSuffix}",["properties"]:q,["headers"]:{}},GI={["url"]:"{url#scheme}://{url#authority}{url#path}",["properties"]:q,["headers"]:{}},mS={["url"]:"https://s3.{Region}.{partitionResult#dnsSuffix}",["properties"]:q,["headers"]:{}},CI=[{["ref"]:"Region"}],pm=[{["ref"]:"Endpoint"}],nm=[p],YI=[V],RR=[mf],zf=[y,o],ES=[{["fn"]:"isSet",["argv"]:[{["ref"]:"DisableS3ExpressSessionAuth"}]},{["fn"]:"booleanEquals",["argv"]:[{["ref"]:"DisableS3ExpressSessionAuth"},!0]}],PS=[IR],XI=[XS],ZI=[ZS],xf=[Q],US=[{["fn"]:"substring",["argv"]:[p,6,14,!0],["assign"]:"s3expressAvailabilityZoneId"},{["fn"]:"substring",["argv"]:[p,14,16,!0],["assign"]:"s3expressAvailabilityZoneDelim"},{["fn"]:"stringEquals",["argv"]:[{["ref"]:"s3expressAvailabilityZoneDelim"},"--"]}],HS=[{["conditions"]:[Q],["endpoint"]:{["url"]:"https://{Bucket}.s3express-fips-{s3expressAvailabilityZoneId}.{Region}.amazonaws.com",["properties"]:Tf,["headers"]:{}},["type"]:"endpoint"},{["endpoint"]:{["url"]:"https://{Bucket}.s3express-{s3expressAvailabilityZoneId}.{Region}.amazonaws.com",["properties"]:Tf,["headers"]:{}},["type"]:"endpoint"}],DS=[{["fn"]:"substring",["argv"]:[p,6,15,!0],["assign"]:"s3expressAvailabilityZoneId"},{["fn"]:"substring",["argv"]:[p,15,17,!0],["assign"]:"s3expressAvailabilityZoneDelim"},{["fn"]:"stringEquals",["argv"]:[{["ref"]:"s3expressAvailabilityZoneDelim"},"--"]}],FS=[{["conditions"]:[Q],["endpoint"]:{["url"]:"https://{Bucket}.s3express-fips-{s3expressAvailabilityZoneId}.{Region}.amazonaws.com",["properties"]:sR,["headers"]:{}},["type"]:"endpoint"},{["endpoint"]:{["url"]:"https://{Bucket}.s3express-{s3expressAvailabilityZoneId}.{Region}.amazonaws.com",["properties"]:sR,["headers"]:{}},["type"]:"endpoint"}],um=[AR],NS=[{["fn"]:"isValidHostLabel",["argv"]:[{["ref"]:"outpostId"},!1]}],TS=[{["fn"]:"stringEquals",["argv"]:[{["ref"]:"regionPrefix"},"beta"]}],tm=["*"],Wf=[CS],$S=[{["fn"]:"isValidHostLabel",["argv"]:[{["ref"]:"Region"},!1]}],Mf=[{["fn"]:"stringEquals",["argv"]:[{["ref"]:"Region"},"us-east-1"]}],JI=[{["fn"]:"stringEquals",["argv"]:[JS,"accesspoint"]}],LS=[{["fn"]:"getAttr",["argv"]:[t,"resourceId[1]"],["assign"]:"accessPointName"},{["fn"]:"not",["argv"]:[{["fn"]:"stringEquals",["argv"]:[yI,""]}]}],fE=[t,"resourceId[1]"],VI=[{["fn"]:"not",["argv"]:[{["fn"]:"stringEquals",["argv"]:[{["fn"]:"getAttr",["argv"]:[t,"region"]},""]}]}],WS=[{["fn"]:"not",["argv"]:[{["fn"]:"isSet",["argv"]:[{["fn"]:"getAttr",["argv"]:[t,"resourceId[2]"]}]}]}],hE=[t,"resourceId[2]"],QI=[{["fn"]:"aws.partition",["argv"]:[{["fn"]:"getAttr",["argv"]:[t,"region"]}],["assign"]:"bucketPartition"}],MS=[{["fn"]:"stringEquals",["argv"]:[VS,{["fn"]:"getAttr",["argv"]:[{["ref"]:"partitionResult"},"name"]}]}],zI=[{["fn"]:"isValidHostLabel",["argv"]:[{["fn"]:"getAttr",["argv"]:[t,"region"]},!0]}],BI=[{["fn"]:"isValidHostLabel",["argv"]:[QS,!1]}],gS=[{["fn"]:"isValidHostLabel",["argv"]:[yI,!1]}],GS=[{["fn"]:"isValidHostLabel",["argv"]:[{["ref"]:"Region"},!0]}],RE={version:"1.0",parameters:{Bucket:af,Region:af,UseFIPS:kf,UseDualStack:kf,Endpoint:af,ForcePathStyle:kf,Accelerate:kf,UseGlobalEndpoint:kf,UseObjectLambdaEndpoint:Dh,Key:af,Prefix:af,CopySource:af,DisableAccessPoints:Dh,DisableMultiRegionAccessPoints:kf,UseArnRegion:Dh,UseS3ExpressControlEndpoint:Dh,DisableS3ExpressSessionAuth:Dh},rules:[{["conditions"]:[{["fn"]:"isSet",["argv"]:CI}],rules:[{["conditions"]:[mf,Q],error:"Accelerate cannot be used with FIPS",["type"]:"error"},{["conditions"]:[V,y],error:"Cannot set dual-stack in combination with a custom endpoint.",["type"]:"error"},{["conditions"]:[y,Q],error:"A custom endpoint cannot be combined with FIPS",["type"]:"error"},{["conditions"]:[y,mf],error:"A custom endpoint cannot be combined with S3 Accelerate",["type"]:"error"},{["conditions"]:[Q,CS,ys],error:"Partition does not support FIPS",["type"]:"error"},{["conditions"]:[AR,{["fn"]:"substring",["argv"]:[p,0,6,!0],["assign"]:"bucketSuffix"},{["fn"]:"stringEquals",["argv"]:[{["ref"]:"bucketSuffix"},"--x-s3"]}],rules:[{["conditions"]:YI,error:"S3Express does not support Dual-stack.",["type"]:"error"},{["conditions"]:RR,error:"S3Express does not support S3 Accelerate.",["type"]:"error"},{["conditions"]:zf,rules:[{["conditions"]:ES,rules:[{["conditions"]:PS,rules:[{["conditions"]:XI,rules:[{endpoint:{["url"]:"{url#scheme}://{url#authority}/{uri_encoded_bucket}{url#path}",["properties"]:Tf,["headers"]:D},["type"]:"endpoint"}],["type"]:"tree"}],["type"]:"tree"},{["conditions"]:ZI,rules:[{endpoint:{["url"]:"{url#scheme}://{Bucket}.{url#authority}{url#path}",["properties"]:Tf,["headers"]:D},["type"]:"endpoint"}],["type"]:"tree"},EI],["type"]:"tree"},{["conditions"]:PS,rules:[{["conditions"]:XI,rules:[{endpoint:{["url"]:"{url#scheme}://{url#authority}/{uri_encoded_bucket}{url#path}",["properties"]:sR,["headers"]:D},["type"]:"endpoint"}],["type"]:"tree"}],["type"]:"tree"},{["conditions"]:ZI,rules:[{endpoint:{["url"]:"{url#scheme}://{Bucket}.{url#authority}{url#path}",["properties"]:sR,["headers"]:D},["type"]:"endpoint"}],["type"]:"tree"},EI],["type"]:"tree"},{["conditions"]:[qs,ds],rules:[{["conditions"]:[XS,F],rules:[{["conditions"]:xf,endpoint:{["url"]:"https://s3express-control-fips.{Region}.amazonaws.com/{uri_encoded_bucket}",["properties"]:Tf,["headers"]:D},["type"]:"endpoint"},{endpoint:{["url"]:"https://s3express-control.{Region}.amazonaws.com/{uri_encoded_bucket}",["properties"]:Tf,["headers"]:D},["type"]:"endpoint"}],["type"]:"tree"}],["type"]:"tree"},{["conditions"]:ZI,rules:[{["conditions"]:ES,rules:[{["conditions"]:US,rules:HS,["type"]:"tree"},{["conditions"]:DS,rules:HS,["type"]:"tree"},Os],["type"]:"tree"},{["conditions"]:US,rules:FS,["type"]:"tree"},{["conditions"]:DS,rules:FS,["type"]:"tree"},Os],["type"]:"tree"},EI],["type"]:"tree"},{["conditions"]:[js,qs,ds],rules:[{["conditions"]:zf,endpoint:{["url"]:"{url#scheme}://{url#authority}{url#path}",["properties"]:Tf,["headers"]:D},["type"]:"endpoint"},{["conditions"]:xf,endpoint:{["url"]:"https://s3express-control-fips.{Region}.amazonaws.com",["properties"]:Tf,["headers"]:D},["type"]:"endpoint"},{endpoint:{["url"]:"https://s3express-control.{Region}.amazonaws.com",["properties"]:Tf,["headers"]:D},["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[AR,{["fn"]:"substring",["argv"]:[p,49,50,!0],["assign"]:"hardwareType"},{["fn"]:"substring",["argv"]:[p,8,12,!0],["assign"]:"regionPrefix"},{["fn"]:"substring",["argv"]:[p,0,7,!0],["assign"]:"bucketAliasSuffix"},{["fn"]:"substring",["argv"]:[p,32,49,!0],["assign"]:"outpostId"},{["fn"]:"aws.partition",["argv"]:CI,["assign"]:"regionPartition"},{["fn"]:"stringEquals",["argv"]:[{["ref"]:"bucketAliasSuffix"},"--op-s3"]}],rules:[{["conditions"]:NS,rules:[{["conditions"]:[{["fn"]:"stringEquals",["argv"]:[Ks,"e"]}],rules:[{["conditions"]:TS,rules:[vs,{["conditions"]:zf,endpoint:{["url"]:"https://{Bucket}.ec2.{url#authority}",["properties"]:fR,["headers"]:D},["type"]:"endpoint"}],["type"]:"tree"},{endpoint:{["url"]:"https://{Bucket}.ec2.s3-outposts.{Region}.{regionPartition#dnsSuffix}",["properties"]:fR,["headers"]:D},["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[{["fn"]:"stringEquals",["argv"]:[Ks,"o"]}],rules:[{["conditions"]:TS,rules:[vs,{["conditions"]:zf,endpoint:{["url"]:"https://{Bucket}.op-{outpostId}.{url#authority}",["properties"]:fR,["headers"]:D},["type"]:"endpoint"}],["type"]:"tree"},{endpoint:{["url"]:"https://{Bucket}.op-{outpostId}.s3-outposts.{Region}.{regionPartition#dnsSuffix}",["properties"]:fR,["headers"]:D},["type"]:"endpoint"}],["type"]:"tree"},{error:"Unrecognized hardware type: \"Expected hardware type o or e but got {hardwareType}\"",["type"]:"error"}],["type"]:"tree"},{error:"Invalid ARN: The outpost Id must only contain a-z, A-Z, 0-9 and `-`.",["type"]:"error"}],["type"]:"tree"},{["conditions"]:um,rules:[{["conditions"]:[y,{["fn"]:"not",["argv"]:[{["fn"]:"isSet",["argv"]:[{["fn"]:"parseURL",["argv"]:pm}]}]}],error:"Custom endpoint `{Endpoint}` was not a valid URI",["type"]:"error"},{["conditions"]:[PI,ZS],rules:[{["conditions"]:Wf,rules:[{["conditions"]:$S,rules:[{["conditions"]:[mf,ys],error:"S3 Accelerate cannot be used in this region",["type"]:"error"},{["conditions"]:[V,Q,l,F,d],endpoint:{["url"]:"https://{Bucket}.s3-fips.dualstack.us-east-1.{partitionResult#dnsSuffix}",["properties"]:v,["headers"]:D},["type"]:"endpoint"},{["conditions"]:[V,Q,l,F,W,r],rules:[{endpoint:rs,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[V,Q,l,F,W,c],endpoint:rs,["type"]:"endpoint"},{["conditions"]:[L,Q,l,F,d],endpoint:{["url"]:"https://{Bucket}.s3-fips.us-east-1.{partitionResult#dnsSuffix}",["properties"]:v,["headers"]:D},["type"]:"endpoint"},{["conditions"]:[L,Q,l,F,W,r],rules:[{endpoint:cs,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[L,Q,l,F,W,c],endpoint:cs,["type"]:"endpoint"},{["conditions"]:[V,$,mf,F,d],endpoint:{["url"]:"https://{Bucket}.s3-accelerate.dualstack.us-east-1.{partitionResult#dnsSuffix}",["properties"]:v,["headers"]:D},["type"]:"endpoint"},{["conditions"]:[V,$,mf,F,W,r],rules:[{endpoint:bs,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[V,$,mf,F,W,c],endpoint:bs,["type"]:"endpoint"},{["conditions"]:[V,$,l,F,d],endpoint:{["url"]:"https://{Bucket}.s3.dualstack.us-east-1.{partitionResult#dnsSuffix}",["properties"]:v,["headers"]:D},["type"]:"endpoint"},{["conditions"]:[V,$,l,F,W,r],rules:[{endpoint:as,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[V,$,l,F,W,c],endpoint:as,["type"]:"endpoint"},{["conditions"]:[L,$,l,y,o,IR,d],endpoint:{["url"]:"{url#scheme}://{url#authority}{url#normalizedPath}{Bucket}",["properties"]:v,["headers"]:D},["type"]:"endpoint"},{["conditions"]:[L,$,l,y,o,UI,d],endpoint:{["url"]:"{url#scheme}://{Bucket}.{url#authority}{url#path}",["properties"]:v,["headers"]:D},["type"]:"endpoint"},{["conditions"]:[L,$,l,y,o,IR,W,r],rules:[{["conditions"]:Mf,endpoint:HI,["type"]:"endpoint"},{endpoint:HI,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[L,$,l,y,o,UI,W,r],rules:[{["conditions"]:Mf,endpoint:lI,["type"]:"endpoint"},ks],["type"]:"tree"},{["conditions"]:[L,$,l,y,o,IR,W,c],endpoint:HI,["type"]:"endpoint"},{["conditions"]:[L,$,l,y,o,UI,W,c],endpoint:lI,["type"]:"endpoint"},{["conditions"]:[L,$,mf,F,d],endpoint:{["url"]:"https://{Bucket}.s3-accelerate.{partitionResult#dnsSuffix}",["properties"]:v,["headers"]:D},["type"]:"endpoint"},{["conditions"]:[L,$,mf,F,W,r],rules:[{["conditions"]:Mf,endpoint:DI,["type"]:"endpoint"},{endpoint:DI,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[L,$,mf,F,W,c],endpoint:DI,["type"]:"endpoint"},{["conditions"]:[L,$,l,F,d],endpoint:{["url"]:"https://{Bucket}.s3.{partitionResult#dnsSuffix}",["properties"]:v,["headers"]:D},["type"]:"endpoint"},{["conditions"]:[L,$,l,F,W,r],rules:[{["conditions"]:Mf,endpoint:{["url"]:"https://{Bucket}.s3.{partitionResult#dnsSuffix}",["properties"]:q,["headers"]:D},["type"]:"endpoint"},{endpoint:xs,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[L,$,l,F,W,c],endpoint:xs,["type"]:"endpoint"}],["type"]:"tree"},hR],["type"]:"tree"}],["type"]:"tree"},{["conditions"]:[y,o,{["fn"]:"stringEquals",["argv"]:[{["fn"]:"getAttr",["argv"]:[YS,"scheme"]},"http"]},{["fn"]:"aws.isVirtualHostableS3Bucket",["argv"]:[p,!0]},PI,$,L,l],rules:[{["conditions"]:Wf,rules:[{["conditions"]:$S,rules:[ks],["type"]:"tree"},hR],["type"]:"tree"}],["type"]:"tree"},{["conditions"]:[PI,{["fn"]:"aws.parseArn",["argv"]:nm,["assign"]:"bucketArn"}],rules:[{["conditions"]:[{["fn"]:"getAttr",["argv"]:[t,"resourceId[0]"],["assign"]:"arnType"},{["fn"]:"not",["argv"]:[{["fn"]:"stringEquals",["argv"]:[JS,""]}]}],rules:[{["conditions"]:[{["fn"]:"stringEquals",["argv"]:[FI,"s3-object-lambda"]}],rules:[{["conditions"]:JI,rules:[{["conditions"]:LS,rules:[is,_s,{["conditions"]:VI,rules:[es,{["conditions"]:WS,rules:[NI,{["conditions"]:QI,rules:[{["conditions"]:Wf,rules:[{["conditions"]:MS,rules:[{["conditions"]:zI,rules:[{["conditions"]:[{["fn"]:"stringEquals",["argv"]:[QS,""]}],error:"Invalid ARN: Missing account id",["type"]:"error"},{["conditions"]:BI,rules:[{["conditions"]:gS,rules:[{["conditions"]:zf,endpoint:{["url"]:"{url#scheme}://{accessPointName}-{bucketArn#accountId}.{url#authority}{url#path}",["properties"]:TI,["headers"]:D},["type"]:"endpoint"},{["conditions"]:xf,endpoint:{["url"]:"https://{accessPointName}-{bucketArn#accountId}.s3-object-lambda-fips.{bucketArn#region}.{bucketPartition#dnsSuffix}",["properties"]:TI,["headers"]:D},["type"]:"endpoint"},{endpoint:{["url"]:"https://{accessPointName}-{bucketArn#accountId}.s3-object-lambda.{bucketArn#region}.{bucketPartition#dnsSuffix}",["properties"]:TI,["headers"]:D},["type"]:"endpoint"}],["type"]:"tree"},os],["type"]:"tree"},$I],["type"]:"tree"},LI],["type"]:"tree"},WI],["type"]:"tree"}],["type"]:"tree"}],["type"]:"tree"},ps],["type"]:"tree"},{error:"Invalid ARN: bucket ARN is missing a region",["type"]:"error"}],["type"]:"tree"},ns],["type"]:"tree"},{error:"Invalid ARN: Object Lambda ARNs only support `accesspoint` arn types, but found: `{arnType}`",["type"]:"error"}],["type"]:"tree"},{["conditions"]:JI,rules:[{["conditions"]:LS,rules:[{["conditions"]:VI,rules:[{["conditions"]:JI,rules:[{["conditions"]:VI,rules:[es,{["conditions"]:WS,rules:[NI,{["conditions"]:QI,rules:[{["conditions"]:Wf,rules:[{["conditions"]:[{["fn"]:"stringEquals",["argv"]:[VS,"{partitionResult#name}"]}],rules:[{["conditions"]:zI,rules:[{["conditions"]:[{["fn"]:"stringEquals",["argv"]:[FI,"s3"]}],rules:[{["conditions"]:BI,rules:[{["conditions"]:gS,rules:[{["conditions"]:RR,error:"Access Points do not support S3 Accelerate",["type"]:"error"},{["conditions"]:[Q,V],endpoint:{["url"]:"https://{accessPointName}-{bucketArn#accountId}.s3-accesspoint-fips.dualstack.{bucketArn#region}.{bucketPartition#dnsSuffix}",["properties"]:Fh,["headers"]:D},["type"]:"endpoint"},{["conditions"]:[Q,L],endpoint:{["url"]:"https://{accessPointName}-{bucketArn#accountId}.s3-accesspoint-fips.{bucketArn#region}.{bucketPartition#dnsSuffix}",["properties"]:Fh,["headers"]:D},["type"]:"endpoint"},{["conditions"]:[$,V],endpoint:{["url"]:"https://{accessPointName}-{bucketArn#accountId}.s3-accesspoint.dualstack.{bucketArn#region}.{bucketPartition#dnsSuffix}",["properties"]:Fh,["headers"]:D},["type"]:"endpoint"},{["conditions"]:[$,L,y,o],endpoint:{["url"]:"{url#scheme}://{accessPointName}-{bucketArn#accountId}.{url#authority}{url#path}",["properties"]:Fh,["headers"]:D},["type"]:"endpoint"},{["conditions"]:[$,L],endpoint:{["url"]:"https://{accessPointName}-{bucketArn#accountId}.s3-accesspoint.{bucketArn#region}.{bucketPartition#dnsSuffix}",["properties"]:Fh,["headers"]:D},["type"]:"endpoint"}],["type"]:"tree"},os],["type"]:"tree"},$I],["type"]:"tree"},{error:"Invalid ARN: The ARN was not for the S3 service, found: {bucketArn#service}",["type"]:"error"}],["type"]:"tree"},LI],["type"]:"tree"},WI],["type"]:"tree"}],["type"]:"tree"}],["type"]:"tree"},ps],["type"]:"tree"}],["type"]:"tree"}],["type"]:"tree"},{["conditions"]:[{["fn"]:"isValidHostLabel",["argv"]:[yI,!0]}],rules:[{["conditions"]:YI,error:"S3 MRAP does not support dual-stack",["type"]:"error"},{["conditions"]:xf,error:"S3 MRAP does not support FIPS",["type"]:"error"},{["conditions"]:RR,error:"S3 MRAP does not support S3 Accelerate",["type"]:"error"},{["conditions"]:[{["fn"]:"booleanEquals",["argv"]:[{["ref"]:"DisableMultiRegionAccessPoints"},!0]}],error:"Invalid configuration: Multi-Region Access Point ARNs are disabled.",["type"]:"error"},{["conditions"]:[{["fn"]:"aws.partition",["argv"]:CI,["assign"]:"mrapPartition"}],rules:[{["conditions"]:[{["fn"]:"stringEquals",["argv"]:[{["fn"]:"getAttr",["argv"]:[{["ref"]:"mrapPartition"},"name"]},{["fn"]:"getAttr",["argv"]:[t,"partition"]}]}],rules:[{endpoint:{["url"]:"https://{accessPointName}.accesspoint.s3-global.{mrapPartition#dnsSuffix}",["properties"]:{["authSchemes"]:[{["disableDoubleEncoding"]:!0,name:"sigv4a",["signingName"]:"s3",["signingRegionSet"]:tm}]},["headers"]:D},["type"]:"endpoint"}],["type"]:"tree"},{error:"Client was configured for partition `{mrapPartition#name}` but bucket referred to partition `{bucketArn#partition}`",["type"]:"error"}],["type"]:"tree"}],["type"]:"tree"},{error:"Invalid Access Point Name",["type"]:"error"}],["type"]:"tree"},ns],["type"]:"tree"},{["conditions"]:[{["fn"]:"stringEquals",["argv"]:[FI,"s3-outposts"]}],rules:[{["conditions"]:YI,error:"S3 Outposts does not support Dual-stack",["type"]:"error"},{["conditions"]:xf,error:"S3 Outposts does not support FIPS",["type"]:"error"},{["conditions"]:RR,error:"S3 Outposts does not support S3 Accelerate",["type"]:"error"},{["conditions"]:[{["fn"]:"isSet",["argv"]:[{["fn"]:"getAttr",["argv"]:[t,"resourceId[4]"]}]}],error:"Invalid Arn: Outpost Access Point ARN contains sub resources",["type"]:"error"},{["conditions"]:[{["fn"]:"getAttr",["argv"]:fE,["assign"]:"outpostId"}],rules:[{["conditions"]:NS,rules:[NI,{["conditions"]:QI,rules:[{["conditions"]:Wf,rules:[{["conditions"]:MS,rules:[{["conditions"]:zI,rules:[{["conditions"]:BI,rules:[{["conditions"]:[{["fn"]:"getAttr",["argv"]:hE,["assign"]:"outpostType"}],rules:[{["conditions"]:[{["fn"]:"getAttr",["argv"]:[t,"resourceId[3]"],["assign"]:"accessPointName"}],rules:[{["conditions"]:[{["fn"]:"stringEquals",["argv"]:[{["ref"]:"outpostType"},"accesspoint"]}],rules:[{["conditions"]:zf,endpoint:{["url"]:"https://{accessPointName}-{bucketArn#accountId}.{outpostId}.{url#authority}",["properties"]:us,["headers"]:D},["type"]:"endpoint"},{endpoint:{["url"]:"https://{accessPointName}-{bucketArn#accountId}.{outpostId}.s3-outposts.{bucketArn#region}.{bucketPartition#dnsSuffix}",["properties"]:us,["headers"]:D},["type"]:"endpoint"}],["type"]:"tree"},{error:"Expected an outpost type `accesspoint`, found {outpostType}",["type"]:"error"}],["type"]:"tree"},{error:"Invalid ARN: expected an access point name",["type"]:"error"}],["type"]:"tree"},{error:"Invalid ARN: Expected a 4-component resource",["type"]:"error"}],["type"]:"tree"},$I],["type"]:"tree"},LI],["type"]:"tree"},WI],["type"]:"tree"}],["type"]:"tree"}],["type"]:"tree"},{error:"Invalid ARN: The outpost Id may only contain a-z, A-Z, 0-9 and `-`. Found: `{outpostId}`",["type"]:"error"}],["type"]:"tree"},{error:"Invalid ARN: The Outpost Id was not set",["type"]:"error"}],["type"]:"tree"},{error:"Invalid ARN: Unrecognized format: {Bucket} (type: {arnType})",["type"]:"error"}],["type"]:"tree"},{error:"Invalid ARN: No ARN type specified",["type"]:"error"}],["type"]:"tree"},{["conditions"]:[{["fn"]:"substring",["argv"]:[p,0,4,!1],["assign"]:"arnPrefix"},{["fn"]:"stringEquals",["argv"]:[{["ref"]:"arnPrefix"},"arn:"]},{["fn"]:"not",["argv"]:[{["fn"]:"isSet",["argv"]:[ts]}]}],error:"Invalid ARN: `{Bucket}` was not a valid ARN",["type"]:"error"},{["conditions"]:[{["fn"]:"booleanEquals",["argv"]:[om,!0]},ts],error:"Path-style addressing cannot be used with ARN buckets",["type"]:"error"},{["conditions"]:XI,rules:[{["conditions"]:Wf,rules:[{["conditions"]:[l],rules:[{["conditions"]:[V,F,Q,d],endpoint:{["url"]:"https://s3-fips.dualstack.us-east-1.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",["properties"]:v,["headers"]:D},["type"]:"endpoint"},{["conditions"]:[V,F,Q,W,r],rules:[{endpoint:fS,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[V,F,Q,W,c],endpoint:fS,["type"]:"endpoint"},{["conditions"]:[L,F,Q,d],endpoint:{["url"]:"https://s3-fips.us-east-1.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",["properties"]:v,["headers"]:D},["type"]:"endpoint"},{["conditions"]:[L,F,Q,W,r],rules:[{endpoint:hS,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[L,F,Q,W,c],endpoint:hS,["type"]:"endpoint"},{["conditions"]:[V,F,$,d],endpoint:{["url"]:"https://s3.dualstack.us-east-1.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",["properties"]:v,["headers"]:D},["type"]:"endpoint"},{["conditions"]:[V,F,$,W,r],rules:[{endpoint:RS,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[V,F,$,W,c],endpoint:RS,["type"]:"endpoint"},{["conditions"]:[L,y,o,$,d],endpoint:{["url"]:"{url#scheme}://{url#authority}{url#normalizedPath}{uri_encoded_bucket}",["properties"]:v,["headers"]:D},["type"]:"endpoint"},{["conditions"]:[L,y,o,$,W,r],rules:[{["conditions"]:Mf,endpoint:MI,["type"]:"endpoint"},{endpoint:MI,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[L,y,o,$,W,c],endpoint:MI,["type"]:"endpoint"},{["conditions"]:[L,F,$,d],endpoint:{["url"]:"https://s3.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",["properties"]:v,["headers"]:D},["type"]:"endpoint"},{["conditions"]:[L,F,$,W,r],rules:[{["conditions"]:Mf,endpoint:{["url"]:"https://s3.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",["properties"]:q,["headers"]:D},["type"]:"endpoint"},{endpoint:IS,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[L,F,$,W,c],endpoint:IS,["type"]:"endpoint"}],["type"]:"tree"},{error:"Path-style addressing cannot be used with S3 Accelerate",["type"]:"error"}],["type"]:"tree"}],["type"]:"tree"}],["type"]:"tree"},{["conditions"]:[{["fn"]:"isSet",["argv"]:[AS]},{["fn"]:"booleanEquals",["argv"]:[AS,!0]}],rules:[{["conditions"]:Wf,rules:[{["conditions"]:GS,rules:[is,_s,{["conditions"]:zf,endpoint:{["url"]:"{url#scheme}://{url#authority}{url#path}",["properties"]:gI,["headers"]:D},["type"]:"endpoint"},{["conditions"]:xf,endpoint:{["url"]:"https://s3-object-lambda-fips.{Region}.{partitionResult#dnsSuffix}",["properties"]:gI,["headers"]:D},["type"]:"endpoint"},{endpoint:{["url"]:"https://s3-object-lambda.{Region}.{partitionResult#dnsSuffix}",["properties"]:gI,["headers"]:D},["type"]:"endpoint"}],["type"]:"tree"},hR],["type"]:"tree"}],["type"]:"tree"},{["conditions"]:[js],rules:[{["conditions"]:Wf,rules:[{["conditions"]:GS,rules:[{["conditions"]:[Q,V,F,d],endpoint:{["url"]:"https://s3-fips.dualstack.us-east-1.{partitionResult#dnsSuffix}",["properties"]:v,["headers"]:D},["type"]:"endpoint"},{["conditions"]:[Q,V,F,W,r],rules:[{endpoint:sS,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[Q,V,F,W,c],endpoint:sS,["type"]:"endpoint"},{["conditions"]:[Q,L,F,d],endpoint:{["url"]:"https://s3-fips.us-east-1.{partitionResult#dnsSuffix}",["properties"]:v,["headers"]:D},["type"]:"endpoint"},{["conditions"]:[Q,L,F,W,r],rules:[{endpoint:SS,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[Q,L,F,W,c],endpoint:SS,["type"]:"endpoint"},{["conditions"]:[$,V,F,d],endpoint:{["url"]:"https://s3.dualstack.us-east-1.{partitionResult#dnsSuffix}",["properties"]:v,["headers"]:D},["type"]:"endpoint"},{["conditions"]:[$,V,F,W,r],rules:[{endpoint:wS,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[$,V,F,W,c],endpoint:wS,["type"]:"endpoint"},{["conditions"]:[$,L,y,o,d],endpoint:{["url"]:"{url#scheme}://{url#authority}{url#path}",["properties"]:v,["headers"]:D},["type"]:"endpoint"},{["conditions"]:[$,L,y,o,W,r],rules:[{["conditions"]:Mf,endpoint:GI,["type"]:"endpoint"},{endpoint:GI,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[$,L,y,o,W,c],endpoint:GI,["type"]:"endpoint"},{["conditions"]:[$,L,F,d],endpoint:{["url"]:"https://s3.{partitionResult#dnsSuffix}",["properties"]:v,["headers"]:D},["type"]:"endpoint"},{["conditions"]:[$,L,F,W,r],rules:[{["conditions"]:Mf,endpoint:{["url"]:"https://s3.{partitionResult#dnsSuffix}",["properties"]:q,["headers"]:D},["type"]:"endpoint"},{endpoint:mS,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[$,L,F,W,c],endpoint:mS,["type"]:"endpoint"}],["type"]:"tree"},hR],["type"]:"tree"}],["type"]:"tree"}],["type"]:"tree"},{error:"A region must be set when sending requests to S3.",["type"]:"error"}]},zS=RE;var IE=new BS({size:50,params:["Accelerate","Bucket","DisableAccessPoints","DisableMultiRegionAccessPoints","DisableS3ExpressSessionAuth","Endpoint","ForcePathStyle","Region","UseArnRegion","UseDualStack","UseFIPS","UseGlobalEndpoint","UseObjectLambdaEndpoint","UseS3ExpressControlEndpoint"]}),SR=(f,h={})=>{return IE.get(f,()=>yS(zS,{endpointParams:f,logger:h.logger}))};lS.aws=qS;function jS(f){return{schemeId:"aws.auth#sigv4",signingProperties:{name:"s3",region:f.region},propertiesExtractor:(h,R)=>({signingProperties:{config:h,context:R}})}}function KS(f){return{schemeId:"aws.auth#sigv4a",signingProperties:{name:"s3",region:f.region},propertiesExtractor:(h,R)=>({signingProperties:{config:h,context:R}})}}var AE=(f)=>async(h,R,I)=>{if(!I)throw new Error("Could not find \`input\` for \`defaultEndpointRuleSetHttpAuthSchemeParametersProvider\`");const A=await f(h,R,I),s=Hh(R)?.commandInstance?.constructor?.getEndpointParameterInstructions;if(!s)throw new Error(`getEndpointParameterInstructions() is not defined on \`${R.commandName}\``);const S=await dS(I,{getEndpointParameterInstructions:s},h);return Object.assign(A,S)},sE=async(f,h,R)=>{return{operation:Hh(h).operation,region:await Eh(f.region)()||(()=>{throw new Error("expected `region` to be configured for `aws.auth#sigv4`")})()}},OS=AE(sE),SE=(f,h,R)=>{return(A)=>{const S=f(A).properties?.authSchemes;if(!S)return h(A);const w=[];for(let E of S){const{name:P,properties:N={},...G}=E,M=P.toLowerCase();if(P!==M)console.warn(`HttpAuthScheme has been normalized with lowercasing: \`${P}\` to \`${M}\``);let g;if(M==="sigv4a"){g="aws.auth#sigv4a";const wf=S.find((e)=>{const Nf=e.name.toLowerCase();return Nf!=="sigv4a"&&Nf.startsWith("sigv4")});if(!th.CrtSignerV4&&wf)continue}else if(M.startsWith("sigv4"))g="aws.auth#sigv4";else throw new Error(`Unknown HttpAuthScheme found in \`@smithy.rules#endpointRuleSet\`: \`${M}\``);const j=R[g];if(!j)throw new Error(`Could not find HttpAuthOption create function for \`${g}\``);const _=j(A);_.schemeId=g,_.signingProperties={..._.signingProperties||{},...G,...N},w.push(_)}return w}},wE=(f)=>{const h=[];switch(f.operation){default:h.push(jS(f)),h.push(KS(f))}return h},vS=SE(SR,wE,{"aws.auth#sigv4":jS,"aws.auth#sigv4a":KS}),rS=(f)=>{const h=mR.resolveAwsSdkSigV4Config(f);return{...mR.resolveAwsSdkSigV4AConfig(h)}};var cS=(f)=>{return{...f,useFipsEndpoint:f.useFipsEndpoint??!1,useDualstackEndpoint:f.useDualstackEndpoint??!1,forcePathStyle:f.forcePathStyle??!1,useAccelerateEndpoint:f.useAccelerateEndpoint??!1,useGlobalEndpoint:f.useGlobalEndpoint??!1,disableMultiregionAccessPoints:f.disableMultiregionAccessPoints??!1,defaultSigningName:"s3"}},_f={ForcePathStyle:{type:"clientContextParams",name:"forcePathStyle"},UseArnRegion:{type:"clientContextParams",name:"useArnRegion"},DisableMultiRegionAccessPoints:{type:"clientContextParams",name:"disableMultiregionAccessPoints"},Accelerate:{type:"clientContextParams",name:"useAccelerateEndpoint"},DisableS3ExpressSessionAuth:{type:"clientContextParams",name:"disableS3ExpressSessionAuth"},UseGlobalEndpoint:{type:"builtInParams",name:"useGlobalEndpoint"},UseFIPS:{type:"builtInParams",name:"useFipsEndpoint"},Endpoint:{type:"builtInParams",name:"endpoint"},Region:{type:"builtInParams",name:"region"},UseDualStack:{type:"builtInParams",name:"useDualstackEndpoint"}};class n extends bS{constructor(f){super(f);Object.setPrototypeOf(this,n.prototype)}}class ER extends n{constructor(f){super({name:"NoSuchUpload",$fault:"client",...f});this.name="NoSuchUpload",this.$fault="client",Object.setPrototypeOf(this,ER.prototype)}}class PR extends n{constructor(f){super({name:"ObjectNotInActiveTierError",$fault:"client",...f});this.name="ObjectNotInActiveTierError",this.$fault="client",Object.setPrototypeOf(this,PR.prototype)}}class UR extends n{constructor(f){super({name:"BucketAlreadyExists",$fault:"client",...f});this.name="BucketAlreadyExists",this.$fault="client",Object.setPrototypeOf(this,UR.prototype)}}class HR extends n{constructor(f){super({name:"BucketAlreadyOwnedByYou",$fault:"client",...f});this.name="BucketAlreadyOwnedByYou",this.$fault="client",Object.setPrototypeOf(this,HR.prototype)}}class DR extends n{constructor(f){super({name:"NoSuchBucket",$fault:"client",...f});this.name="NoSuchBucket",this.$fault="client",Object.setPrototypeOf(this,DR.prototype)}}var qI;(function(f){f.visit=(h,R)=>{if(h.Prefix!==void 0)return R.Prefix(h.Prefix);if(h.Tag!==void 0)return R.Tag(h.Tag);if(h.And!==void 0)return R.And(h.And);return R._(h.$unknown[0],h.$unknown[1])}})(qI||(qI={}));var dI;(function(f){f.visit=(h,R)=>{if(h.Prefix!==void 0)return R.Prefix(h.Prefix);if(h.Tag!==void 0)return R.Tag(h.Tag);if(h.ObjectSizeGreaterThan!==void 0)return R.ObjectSizeGreaterThan(h.ObjectSizeGreaterThan);if(h.ObjectSizeLessThan!==void 0)return R.ObjectSizeLessThan(h.ObjectSizeLessThan);if(h.And!==void 0)return R.And(h.And);return R._(h.$unknown[0],h.$unknown[1])}})(dI||(dI={}));var OI;(function(f){f.visit=(h,R)=>{if(h.Prefix!==void 0)return R.Prefix(h.Prefix);if(h.Tag!==void 0)return R.Tag(h.Tag);if(h.AccessPointArn!==void 0)return R.AccessPointArn(h.AccessPointArn);if(h.And!==void 0)return R.And(h.And);return R._(h.$unknown[0],h.$unknown[1])}})(OI||(OI={}));var jI;(function(f){f.visit=(h,R)=>{if(h.Prefix!==void 0)return R.Prefix(h.Prefix);if(h.Tag!==void 0)return R.Tag(h.Tag);if(h.And!==void 0)return R.And(h.And);return R._(h.$unknown[0],h.$unknown[1])}})(jI||(jI={}));class FR extends n{constructor(f){super({name:"InvalidObjectState",$fault:"client",...f});this.name="InvalidObjectState",this.$fault="client",Object.setPrototypeOf(this,FR.prototype),this.StorageClass=f.StorageClass,this.AccessTier=f.AccessTier}}class NR extends n{constructor(f){super({name:"NoSuchKey",$fault:"client",...f});this.name="NoSuchKey",this.$fault="client",Object.setPrototypeOf(this,NR.prototype)}}class TR extends n{constructor(f){super({name:"NotFound",$fault:"client",...f});this.name="NotFound",this.$fault="client",Object.setPrototypeOf(this,TR.prototype)}}var mE=(f)=>({...f,...f.SecretAccessKey&&{SecretAccessKey:u},...f.SessionToken&&{SessionToken:u}}),aS=(f)=>({...f,...f.SSEKMSKeyId&&{SSEKMSKeyId:u},...f.SSEKMSEncryptionContext&&{SSEKMSEncryptionContext:u},...f.Credentials&&{Credentials:mE(f.Credentials)}}),kS=(f)=>({...f,...f.SSEKMSKeyId&&{SSEKMSKeyId:u},...f.SSEKMSEncryptionContext&&{SSEKMSEncryptionContext:u}});var xS=(f)=>({...f,...f.SSEKMSKeyId&&{SSEKMSKeyId:u}}),iS=(f)=>({...f,...f.SSECustomerKey&&{SSECustomerKey:u}});var pf=K(wR(),1);var WR=K(sI(),1);class $R extends n{constructor(f){super({name:"ObjectAlreadyInActiveTierError",$fault:"client",...f});this.name="ObjectAlreadyInActiveTierError",this.$fault="client",Object.setPrototypeOf(this,$R.prototype)}}var _S;(function(f){f.visit=(h,R)=>{if(h.Records!==void 0)return R.Records(h.Records);if(h.Stats!==void 0)return R.Stats(h.Stats);if(h.Progress!==void 0)return R.Progress(h.Progress);if(h.Cont!==void 0)return R.Cont(h.Cont);if(h.End!==void 0)return R.End(h.End);return R._(h.$unknown[0],h.$unknown[1])}})(_S||(_S={}));var eS=(f)=>({...f,...f.SSEKMSKeyId&&{SSEKMSKeyId:u},...f.SSEKMSEncryptionContext&&{SSEKMSEncryptionContext:u}}),oS=(f)=>({...f,...f.SSECustomerKey&&{SSECustomerKey:u},...f.SSEKMSKeyId&&{SSEKMSKeyId:u},...f.SSEKMSEncryptionContext&&{SSEKMSEncryptionContext:u}});var m3=async(f,h)=>{const R=WR.requestBuilder(f,h),I=O({},Uf,{[NP]:f[_E],[gh]:f[Wh],[Gh]:f[Mh],[CR]:f[GR],[gf]:[()=>Uf(f[Bf]),()=>f[Bf].toString()]});R.bp("/"),R.p("Bucket",()=>f.Bucket,"{Bucket}",!1);const A=O({[UP]:[,""]});let s;return R.m("GET").h(I).q(A).b(s),R.build()};var E3=async(f,h)=>{const R=WR.requestBuilder(f,h),I=O({},Uf,{[fP]:f[yE],[hP]:[()=>Uf(f[pS]),()=>Nh(f[pS]).toString()],[q3]:f[g3],[RP]:[()=>Uf(f[nS]),()=>Nh(f[nS]).toString()],[AP]:f[KE],[YR]:f[MR],[b3]:f[Z3],[XR]:f[gR],[r3]:f[X3],[O3]:f[W3],[FP]:f[YE]});R.bp("/{Key+}"),R.p("Bucket",()=>f.Bucket,"{Bucket}",!1),R.p("Key",()=>f.Key,"{Key+}",!0);const A=O({[x3]:[,"GetObject"],[sP]:[,f[vE]],[SP]:[,f[rE]],[wP]:[,f[cE]],[mP]:[,f[bE]],[EP]:[,f[aE]],[PP]:[()=>f.ResponseExpires!==void 0,()=>Nh(f[kE]).toString()],[HP]:[,f[hA]],[IP]:[()=>f.PartNumber!==void 0,()=>f[jE].toString()]});let s;return R.m("GET").h(I).q(A).b(s),R.build()};var P3=async(f,h)=>{const R=WR.requestBuilder(f,h),I=O({},Uf,{[l3]:f[L3]||"application/octet-stream",[DP]:f[gE],[V3]:f[F3],[Q3]:f[N3],[z3]:f[T3],[B3]:f[$3],[iI]:[()=>Uf(f[aI]),()=>f[aI].toString()],[nE]:f[XE],[GP]:f[CE],[RA]:f[nI],[IA]:f[uI],[AA]:f[tI],[sA]:f[fA],[_I]:[()=>Uf(f[kI]),()=>Nh(f[kI]).toString()],[q3]:f[g3],[TP]:f[QE],[$P]:f[zE],[LP]:f[BE],[WP]:f[lE],[gh]:f[Wh],[c3]:f[$h],[k3]:f[J3],[YR]:f[MR],[b3]:f[Z3],[XR]:f[gR],[Gh]:f[Mh],[CR]:f[GR],[gf]:[()=>Uf(f[Bf]),()=>f[Bf].toString()],[r3]:f[X3],[CP]:f[eE],[K3]:f[C3],[eI]:[()=>Uf(f[xI]),()=>w3(f[xI]).toString()],[j3]:f[G3],[O3]:f[W3],...f.Metadata!==void 0&&Object.keys(f.Metadata).reduce((w,E)=>{return w[`x-amz-meta-${E.toLowerCase()}`]=f.Metadata[E],w},{})});R.bp("/{Key+}"),R.p("Bucket",()=>f.Bucket,"{Bucket}",!1),R.p("Key",()=>f.Key,"{Key+}",!0);const A=O({[x3]:[,"PutObject"]});let s,S;if(f.Body!==void 0)S=f.Body,s=S;return R.m("PUT").h(I).q(A).b(s),R.build()};var U3=async(f,h)=>{if(f.statusCode!==200&&f.statusCode>=300)return pI(f,h);const R=O({$metadata:Af(f),[Wh]:[,f.headers[gh]],[Mh]:[,f.headers[Gh]],[GR]:[,f.headers[CR]],[Bf]:[()=>f.headers[gf]!==void 0,()=>Lh(f.headers[gf])]}),I=ef(A3(await pf.parseXmlBody(f.body,h)),"body");if(I[rI]!=null)R[rI]=ME(I[rI],h);return R};var H3=async(f,h)=>{if(f.statusCode!==200&&f.statusCode>=300)return pI(f,h);const R=O({$metadata:Af(f),[JE]:[()=>f.headers[tS]!==void 0,()=>Lh(f.headers[tS])],[GE]:[,f.headers[pE]],[Th]:[,f.headers[d3]],[iE]:[,f.headers[MP]],[qE]:[()=>f.headers[uS]!==void 0,()=>ef(Ph(f.headers[uS]))],[aI]:[()=>f.headers[iI]!==void 0,()=>s3(f.headers[iI])],[M3]:[,f.headers[y3]],[nI]:[,f.headers[RA]],[uI]:[,f.headers[IA]],[tI]:[,f.headers[AA]],[fA]:[,f.headers[sA]],[dE]:[()=>f.headers[f3]!==void 0,()=>LR(f.headers[f3])],[hA]:[,f.headers[a3]],[F3]:[,f.headers[V3]],[N3]:[,f.headers[Q3]],[T3]:[,f.headers[z3]],[$3]:[,f.headers[B3]],[ZE]:[,f.headers[uE]],[L3]:[,f.headers[l3]],[kI]:[()=>f.headers[_I]!==void 0,()=>ef(Ph(f.headers[_I]))],[VE]:[,f.headers[tE]],[J3]:[,f.headers[k3]],[Wh]:[,f.headers[gh]],[MR]:[,f.headers[YR]],[gR]:[,f.headers[XR]],[Mh]:[,f.headers[Gh]],[Bf]:[()=>f.headers[gf]!==void 0,()=>Lh(f.headers[gf])],[$h]:[,f.headers[c3]],[Y3]:[,f.headers[v3]],[xE]:[,f.headers[gP]],[OE]:[()=>f.headers[h3]!==void 0,()=>LR(f.headers[h3])],[oE]:[()=>f.headers[R3]!==void 0,()=>LR(f.headers[R3])],[C3]:[,f.headers[K3]],[xI]:[()=>f.headers[eI]!==void 0,()=>ef(oI(f.headers[eI]))],[G3]:[,f.headers[j3]],Metadata:[,Object.keys(f.headers).filter((A)=>A.startsWith("x-amz-meta-")).reduce((A,s)=>{return A[s.substring(11)]=f.headers[s],A},{})]}),I=f.body;return h.sdkStreamMixin(I),R.Body=I,R};var D3=async(f,h)=>{if(f.statusCode!==200&&f.statusCode>=300)return pI(f,h);const R=O({$metadata:Af(f),[Th]:[,f.headers[d3]],[M3]:[,f.headers[y3]],[nI]:[,f.headers[RA]],[uI]:[,f.headers[IA]],[tI]:[,f.headers[AA]],[fA]:[,f.headers[sA]],[Wh]:[,f.headers[gh]],[hA]:[,f.headers[a3]],[MR]:[,f.headers[YR]],[gR]:[,f.headers[XR]],[Mh]:[,f.headers[Gh]],[GR]:[,f.headers[CR]],[Bf]:[()=>f.headers[gf]!==void 0,()=>Lh(f.headers[gf])],[Y3]:[,f.headers[v3]]});return await I3(f.body,h),R};var pI=async(f,h)=>{const R={...f,body:await pf.parseXmlErrorBody(f.body,h)},I=pf.loadRestXmlErrorCode(f,R.body);switch(I){case"NoSuchUpload":case"com.amazonaws.s3#NoSuchUpload":throw await TE(R,h);case"ObjectNotInActiveTierError":case"com.amazonaws.s3#ObjectNotInActiveTierError":throw await WE(R,h);case"BucketAlreadyExists":case"com.amazonaws.s3#BucketAlreadyExists":throw await UE(R,h);case"BucketAlreadyOwnedByYou":case"com.amazonaws.s3#BucketAlreadyOwnedByYou":throw await HE(R,h);case"NoSuchBucket":case"com.amazonaws.s3#NoSuchBucket":throw await FE(R,h);case"InvalidObjectState":case"com.amazonaws.s3#InvalidObjectState":throw await DE(R,h);case"NoSuchKey":case"com.amazonaws.s3#NoSuchKey":throw await NE(R,h);case"NotFound":case"com.amazonaws.s3#NotFound":throw await $E(R,h);case"ObjectAlreadyInActiveTierError":case"com.amazonaws.s3#ObjectAlreadyInActiveTierError":throw await LE(R,h);default:const A=R.body;return PE({output:f,parsedBody:A,errorCode:I})}},PE=S3(n),UE=async(f,h)=>{const R=O({}),I=f.body,A=new UR({$metadata:Af(f),...R});return Hf(A,f.body)},HE=async(f,h)=>{const R=O({}),I=f.body,A=new HR({$metadata:Af(f),...R});return Hf(A,f.body)},DE=async(f,h)=>{const R=O({}),I=f.body;if(I[vI]!=null)R[vI]=of(I[vI]);if(I[$h]!=null)R[$h]=of(I[$h]);const A=new FR({$metadata:Af(f),...R});return Hf(A,f.body)},FE=async(f,h)=>{const R=O({}),I=f.body,A=new DR({$metadata:Af(f),...R});return Hf(A,f.body)},NE=async(f,h)=>{const R=O({}),I=f.body,A=new NR({$metadata:Af(f),...R});return Hf(A,f.body)},TE=async(f,h)=>{const R=O({}),I=f.body,A=new ER({$metadata:Af(f),...R});return Hf(A,f.body)},$E=async(f,h)=>{const R=O({}),I=f.body,A=new TR({$metadata:Af(f),...R});return Hf(A,f.body)},LE=async(f,h)=>{const R=O({}),I=f.body,A=new $R({$metadata:Af(f),...R});return Hf(A,f.body)},WE=async(f,h)=>{const R=O({}),I=f.body,A=new PR({$metadata:Af(f),...R});return Hf(A,f.body)};var ME=(f,h)=>{const R={};if(f[KI]!=null)R[KI]=of(f[KI]);if(f[cI]!=null)R[cI]=of(f[cI]);if(f[bI]!=null)R[bI]=of(f[bI]);if(f[Th]!=null)R[Th]=ef(oI(f[Th]));return R};var Af=(f)=>({httpStatusCode:f.statusCode,requestId:f.headers["x-amzn-requestid"]??f.headers["x-amzn-request-id"]??f.headers["x-amz-request-id"],extendedRequestId:f.headers["x-amz-id-2"],cfId:f.headers["x-amz-cf-id"]});var Uf=(f)=>f!==void 0&&f!==null&&f!==""&&(!Object.getOwnPropertyNames(f).includes("length")||f.length!=0)&&(!Object.getOwnPropertyNames(f).includes("size")||f.size!=0);var gE="ACL";var KI="AccessKeyId";var GE="AcceptRanges";var vI="AccessTier";var Bf="BucketKeyEnabled";var rI="Credentials",CE="ChecksumAlgorithm";var F3="CacheControl",nI="ChecksumCRC32",uI="ChecksumCRC32C",N3="ContentDisposition";var T3="ContentEncoding";var $3="ContentLanguage",aI="ContentLength",YE="ChecksumMode",XE="ContentMD5";var ZE="ContentRange";var tI="ChecksumSHA1",fA="ChecksumSHA256";var L3="ContentType";var JE="DeleteMarker";var kI="Expires";var W3="ExpectedBucketOwner";var VE="ExpiresString";var M3="ETag";var Th="Expiration";var QE="GrantFullControl";var zE="GrantRead",BE="GrantReadACP";var lE="GrantWriteACP";var yE="IfMatch",pS="IfModifiedSince",g3="IfNoneMatch";var nS="IfUnmodifiedSince";var qE="LastModified";var dE="MissingMeta";var G3="ObjectLockLegalHoldStatus",C3="ObjectLockMode";var xI="ObjectLockRetainUntilDate";var OE="PartsCount";var jE="PartNumber";var KE="Range";var Y3="RequestCharged",vE="ResponseCacheControl",rE="ResponseContentDisposition",cE="ResponseContentEncoding",bE="ResponseContentLanguage",aE="ResponseContentType";var kE="ResponseExpires";var X3="RequestPayer";var xE="ReplicationStatus";var iE="Restore";var cI="SecretAccessKey";var $h="StorageClass";var _E="SessionMode";var Wh="ServerSideEncryption";var MR="SSECustomerAlgorithm",Z3="SSECustomerKey",gR="SSECustomerKeyMD5";var GR="SSEKMSEncryptionContext",Mh="SSEKMSKeyId";var bI="SessionToken";var eE="Tagging";var oE="TagCount";var hA="VersionId";var J3="WebsiteRedirectLocation";var pE="accept-ranges";var V3="cache-control",Q3="content-disposition",z3="content-encoding",B3="content-language",iI="content-length",nE="content-md5",uE="content-range",l3="content-type";var _I="expires";var y3="etag",tE="expiresstring";var fP="if-match",hP="if-modified-since";var q3="if-none-match";var RP="if-unmodified-since";var uS="last-modified";var IP="partNumber";var AP="range",sP="response-cache-control",SP="response-content-disposition",wP="response-content-encoding",mP="response-content-language",EP="response-content-type",PP="response-expires";var UP="session";var HP="versionId";var DP="x-amz-acl";var RA="x-amz-checksum-crc32",IA="x-amz-checksum-crc32c",FP="x-amz-checksum-mode";var AA="x-amz-checksum-sha1",sA="x-amz-checksum-sha256";var NP="x-amz-create-session-mode";var tS="x-amz-delete-marker",d3="x-amz-expiration",O3="x-amz-expected-bucket-owner";var TP="x-amz-grant-full-control",$P="x-amz-grant-read",LP="x-amz-grant-read-acp";var WP="x-amz-grant-write-acp";var f3="x-amz-missing-meta";var h3="x-amz-mp-parts-count";var j3="x-amz-object-lock-legal-hold",K3="x-amz-object-lock-mode",eI="x-amz-object-lock-retain-until-date";var MP="x-amz-restore",v3="x-amz-request-charged";var r3="x-amz-request-payer";var gP="x-amz-replication-status";var c3="x-amz-storage-class",GP="x-amz-sdk-checksum-algorithm";var gh="x-amz-server-side-encryption",Gh="x-amz-server-side-encryption-aws-kms-key-id",gf="x-amz-server-side-encryption-bucket-key-enabled",CR="x-amz-server-side-encryption-context",YR="x-amz-server-side-encryption-customer-algorithm",b3="x-amz-server-side-encryption-customer-key",XR="x-amz-server-side-encryption-customer-key-md5",CP="x-amz-tagging",R3="x-amz-tagging-count";var a3="x-amz-version-id",k3="x-amz-website-redirect-location",x3="x-id";class SA extends nf.classBuilder().ep({..._f,DisableS3ExpressSessionAuth:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(f,h,R,I){return[uf(R,this.serialize,this.deserialize),tf(R,f.getEndpointParameterInstructions()),uh(R)]}).s("AmazonS3","CreateSession",{}).n("S3Client","CreateSessionCommand").f(kS,aS).ser(m3).de(U3).build(){}var i3={name:"@aws-sdk/client-s3",description:"AWS SDK for JavaScript S3 Client for Node.js, Browser and React Native",version:"3.654.0",scripts:{build:"concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'","build:cjs":"node ../../scripts/compilation/inline client-s3","build:es":"tsc -p tsconfig.es.json","build:include:deps":"lerna run --scope $npm_package_name --include-dependencies build","build:types":"tsc -p tsconfig.types.json","build:types:downlevel":"downlevel-dts dist-types dist-types/ts3.4",clean:"rimraf ./dist-* && rimraf *.tsbuildinfo","extract:docs":"api-extractor run --local","generate:client":"node ../../scripts/generate-clients/single-service --solo s3",test:"yarn test:unit","test:e2e":"yarn test:e2e:node && yarn test:e2e:browser","test:e2e:browser":"ts-mocha test/**/*.browser.ispec.ts && karma start karma.conf.js","test:e2e:node":"jest --c jest.config.e2e.js","test:unit":"ts-mocha test/unit/**/*.spec.ts"},main:"./dist-cjs/index.js",types:"./dist-types/index.d.ts",module:"./dist-es/index.js",sideEffects:!1,dependencies:{"@aws-crypto/sha1-browser":"5.2.0","@aws-crypto/sha256-browser":"5.2.0","@aws-crypto/sha256-js":"5.2.0","@aws-sdk/client-sso-oidc":"3.654.0","@aws-sdk/client-sts":"3.654.0","@aws-sdk/core":"3.654.0","@aws-sdk/credential-provider-node":"3.654.0","@aws-sdk/middleware-bucket-endpoint":"3.654.0","@aws-sdk/middleware-expect-continue":"3.654.0","@aws-sdk/middleware-flexible-checksums":"3.654.0","@aws-sdk/middleware-host-header":"3.654.0","@aws-sdk/middleware-location-constraint":"3.654.0","@aws-sdk/middleware-logger":"3.654.0","@aws-sdk/middleware-recursion-detection":"3.654.0","@aws-sdk/middleware-sdk-s3":"3.654.0","@aws-sdk/middleware-ssec":"3.654.0","@aws-sdk/middleware-user-agent":"3.654.0","@aws-sdk/region-config-resolver":"3.654.0","@aws-sdk/signature-v4-multi-region":"3.654.0","@aws-sdk/types":"3.654.0","@aws-sdk/util-endpoints":"3.654.0","@aws-sdk/util-user-agent-browser":"3.654.0","@aws-sdk/util-user-agent-node":"3.654.0","@aws-sdk/xml-builder":"3.654.0","@smithy/config-resolver":"^3.0.8","@smithy/core":"^2.4.3","@smithy/eventstream-serde-browser":"^3.0.9","@smithy/eventstream-serde-config-resolver":"^3.0.6","@smithy/eventstream-serde-node":"^3.0.8","@smithy/fetch-http-handler":"^3.2.7","@smithy/hash-blob-browser":"^3.1.5","@smithy/hash-node":"^3.0.6","@smithy/hash-stream-node":"^3.1.5","@smithy/invalid-dependency":"^3.0.6","@smithy/md5-js":"^3.0.6","@smithy/middleware-content-length":"^3.0.8","@smithy/middleware-endpoint":"^3.1.3","@smithy/middleware-retry":"^3.0.18","@smithy/middleware-serde":"^3.0.6","@smithy/middleware-stack":"^3.0.6","@smithy/node-config-provider":"^3.1.7","@smithy/node-http-handler":"^3.2.2","@smithy/protocol-http":"^4.1.3","@smithy/smithy-client":"^3.3.2","@smithy/types":"^3.4.2","@smithy/url-parser":"^3.0.6","@smithy/util-base64":"^3.0.0","@smithy/util-body-length-browser":"^3.0.0","@smithy/util-body-length-node":"^3.0.0","@smithy/util-defaults-mode-browser":"^3.0.18","@smithy/util-defaults-mode-node":"^3.0.18","@smithy/util-endpoints":"^2.1.2","@smithy/util-middleware":"^3.0.6","@smithy/util-retry":"^3.0.6","@smithy/util-stream":"^3.1.6","@smithy/util-utf8":"^3.0.0","@smithy/util-waiter":"^3.1.5",tslib:"^2.6.2"},devDependencies:{"@aws-sdk/signature-v4-crt":"3.654.0","@tsconfig/node16":"16.1.3","@types/chai":"^4.2.11","@types/mocha":"^8.0.4","@types/node":"^16.18.96",concurrently:"7.0.0","downlevel-dts":"0.10.1",rimraf:"3.0.2",typescript:"~4.9.5"},engines:{node:">=16.0.0"},typesVersions:{"<4.0":{"dist-types/*":["dist-types/ts3.4/*"]}},files:["dist-*/**"],author:{name:"AWS SDK for JavaScript Team",url:"https://aws.amazon.com/javascript/"},license:"Apache-2.0",browser:{"./dist-es/runtimeConfig":"./dist-es/runtimeConfig.browser"},"react-native":{"./dist-es/runtimeConfig":"./dist-es/runtimeConfig.native"},homepage:"https://github.com/aws/aws-sdk-js-v3/tree/main/clients/client-s3",repository:{type:"git",url:"https://github.com/aws/aws-sdk-js-v3.git",directory:"clients/client-s3"}};var lR=K(wR(),1);var XP="AWS_S3_USE_ARN_REGION",ZP="s3_use_arn_region",_3={environmentVariableSelector:(f)=>Vf(f,XP,Qf.ENV),configFileSelector:(f)=>Vf(f,ZP,Qf.CONFIG),default:!1};var Gf=K(o3(),1);var p3=K(o3(),1);function e3(f){for(let h=0;h<8;h++)f[h]^=255;for(let h=7;h>-1;h--)if(f[h]++,f[h]!==0)break}class fh{constructor(f){if(this.bytes=f,f.byteLength!==8)throw new Error("Int64 buffers must be exactly 8 bytes")}static fromNumber(f){if(f>9223372036854776000||f<-9223372036854776000)throw new Error(`${f} is too large (or, if negative, too small) to represent as an Int64`);const h=new Uint8Array(8);for(let R=7,I=Math.abs(Math.round(f));R>-1&&I>0;R--,I/=256)h[R]=I;if(f<0)e3(h);return new fh(h)}valueOf(){const f=this.bytes.slice(0),h=f[0]&128;if(h)e3(f);return parseInt(p3.toHex(f),16)*(h?-1:1)}toString(){return String(this.valueOf())}}class wA{constructor(f,h){this.toUtf8=f,this.fromUtf8=h}format(f){const h=[];for(let A of Object.keys(f)){const s=this.fromUtf8(A);h.push(Uint8Array.from([s.byteLength]),s,this.formatHeaderValue(f[A]))}const R=new Uint8Array(h.reduce((A,s)=>A+s.byteLength,0));let I=0;for(let A of h)R.set(A,I),I+=A.byteLength;return R}formatHeaderValue(f){switch(f.type){case"boolean":return Uint8Array.from([f.value?0:1]);case"byte":return Uint8Array.from([2,f.value]);case"short":const h=new DataView(new ArrayBuffer(3));return h.setUint8(0,3),h.setInt16(1,f.value,!1),new Uint8Array(h.buffer);case"integer":const R=new DataView(new ArrayBuffer(5));return R.setUint8(0,4),R.setInt32(1,f.value,!1),new Uint8Array(R.buffer);case"long":const I=new Uint8Array(9);return I[0]=5,I.set(f.value.bytes,1),I;case"binary":const A=new DataView(new ArrayBuffer(3+f.value.byteLength));A.setUint8(0,6),A.setUint16(1,f.value.byteLength,!1);const s=new Uint8Array(A.buffer);return s.set(f.value,3),s;case"string":const S=this.fromUtf8(f.value),w=new DataView(new ArrayBuffer(3+S.byteLength));w.setUint8(0,7),w.setUint16(1,S.byteLength,!1);const E=new Uint8Array(w.buffer);return E.set(S,3),E;case"timestamp":const P=new Uint8Array(9);return P[0]=8,P.set(fh.fromNumber(f.value.valueOf()).bytes,1),P;case"uuid":if(!kP.test(f.value))throw new Error(`Invalid UUID received: ${f.value}`);const N=new Uint8Array(17);return N[0]=9,N.set(Gf.fromHex(f.value.replace(/\-/g,"")),1),N}}parse(f){const h={};let R=0;while(R<f.byteLength){const I=f.getUint8(R++),A=this.toUtf8(new Uint8Array(f.buffer,f.byteOffset+R,I));switch(R+=I,f.getUint8(R++)){case 0:h[A]={type:u3,value:!0};break;case 1:h[A]={type:u3,value:!1};break;case 2:h[A]={type:OP,value:f.getInt8(R++)};break;case 3:h[A]={type:jP,value:f.getInt16(R,!1)},R+=2;break;case 4:h[A]={type:KP,value:f.getInt32(R,!1)},R+=4;break;case 5:h[A]={type:vP,value:new fh(new Uint8Array(f.buffer,f.byteOffset+R,8))},R+=8;break;case 6:const s=f.getUint16(R,!1);R+=2,h[A]={type:rP,value:new Uint8Array(f.buffer,f.byteOffset+R,s)},R+=s;break;case 7:const S=f.getUint16(R,!1);R+=2,h[A]={type:cP,value:this.toUtf8(new Uint8Array(f.buffer,f.byteOffset+R,S))},R+=S;break;case 8:h[A]={type:bP,value:new Date(new fh(new Uint8Array(f.buffer,f.byteOffset+R,8)).valueOf())},R+=8;break;case 9:const w=new Uint8Array(f.buffer,f.byteOffset+R,16);R+=16,h[A]={type:aP,value:`${Gf.toHex(w.subarray(0,4))}-${Gf.toHex(w.subarray(4,6))}-${Gf.toHex(w.subarray(6,8))}-${Gf.toHex(w.subarray(8,10))}-${Gf.toHex(w.subarray(10))}`};break;default:throw new Error("Unrecognized header type tag")}}return h}}var n3;(function(f){f[f.boolTrue=0]="boolTrue",f[f.boolFalse=1]="boolFalse",f[f.byte=2]="byte",f[f.short=3]="short",f[f.integer=4]="integer",f[f.long=5]="long",f[f.byteArray=6]="byteArray",f[f.string=7]="string",f[f.timestamp=8]="timestamp",f[f.uuid=9]="uuid"})(n3||(n3={}));var u3="boolean",OP="byte",jP="short",KP="integer",vP="long",rP="binary",cP="string",bP="timestamp",aP="uuid",kP=/^[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}$/;function f0({byteLength:f,byteOffset:h,buffer:R}){if(f<xP)throw new Error("Provided message too short to accommodate event stream message overhead");const I=new DataView(R,h,f),A=I.getUint32(0,!1);if(f!==A)throw new Error("Reported message length does not match received message length");const s=I.getUint32(t3,!1),S=I.getUint32(Cf,!1),w=I.getUint32(f-lf,!1),E=new Jf().update(new Uint8Array(R,h,Cf));if(S!==E.digest())throw new Error(`The prelude checksum specified in the message (${S}) does not match the calculated CRC32 checksum (${E.digest()})`);if(E.update(new Uint8Array(R,h+Cf,f-(Cf+lf))),w!==E.digest())throw new Error(`The message checksum (${E.digest()}) did not match the expected value of ${w}`);return{headers:new DataView(R,h+Cf+lf,s),body:new Uint8Array(R,h+Cf+lf+s,A-s-(Cf+lf+lf))}}var t3=4,Cf=t3*2,lf=4,xP=Cf+lf*2;class mA{constructor(f,h){this.headerMarshaller=new wA(f,h),this.messageBuffer=[],this.isEndOfStream=!1}feed(f){this.messageBuffer.push(this.decode(f))}endOfStream(){this.isEndOfStream=!0}getMessage(){const f=this.messageBuffer.pop(),h=this.isEndOfStream;return{getMessage(){return f},isEndOfStream(){return h}}}getAvailableMessages(){const f=this.messageBuffer;this.messageBuffer=[];const h=this.isEndOfStream;return{getMessages(){return f},isEndOfStream(){return h}}}encode({headers:f,body:h}){const R=this.headerMarshaller.format(f),I=R.byteLength+h.byteLength+16,A=new Uint8Array(I),s=new DataView(A.buffer,A.byteOffset,A.byteLength),S=new Jf;return s.setUint32(0,I,!1),s.setUint32(4,R.byteLength,!1),s.setUint32(8,S.update(A.subarray(0,8)).digest(),!1),A.set(R,12),A.set(h,R.byteLength+12),s.setUint32(I-4,S.update(A.subarray(8,I-4)).digest(),!1),A}decode(f){const{headers:h,body:R}=f0(f);return{headers:this.headerMarshaller.parse(h),body:R}}formatHeaders(f){return this.headerMarshaller.format(f)}}class EA{constructor(f){this.options=f}[Symbol.asyncIterator](){return this.asyncIterator()}async*asyncIterator(){for await(let f of this.options.inputStream)yield this.options.decoder.decode(f)}}class PA{constructor(f){this.options=f}[Symbol.asyncIterator](){return this.asyncIterator()}async*asyncIterator(){for await(let f of this.options.messageStream)yield this.options.encoder.encode(f);if(this.options.includeEndFrame)yield new Uint8Array(0)}}class UA{constructor(f){this.options=f}[Symbol.asyncIterator](){return this.asyncIterator()}async*asyncIterator(){for await(let f of this.options.messageStream){const h=await this.options.deserializer(f);if(h===void 0)continue;yield h}}}class HA{constructor(f){this.options=f}[Symbol.asyncIterator](){return this.asyncIterator()}async*asyncIterator(){for await(let f of this.options.inputStream)yield this.options.serializer(f)}}function h0(f){let h=0,R=0,I=null,A=null;const s=(w)=>{if(typeof w!=="number")throw new Error("Attempted to allocate an event message where size was not a number: "+w);h=w,R=4,I=new Uint8Array(w),new DataView(I.buffer).setUint32(0,w,!1)},S=async function*(){const w=f[Symbol.asyncIterator]();while(!0){const{value:E,done:P}=await w.next();if(P){if(!h)return;else if(h===R)yield I;else throw new Error("Truncated event message received.");return}const N=E.length;let G=0;while(G<N){if(!I){const g=N-G;if(!A)A=new Uint8Array(4);const j=Math.min(4-R,g);if(A.set(E.slice(G,G+j),R),R+=j,G+=j,R<4)break;s(new DataView(A.buffer).getUint32(0,!1)),A=null}const M=Math.min(h-R,N-G);if(I.set(E.slice(G,G+M),R),R+=M,G+=M,h&&h===R)yield I,I=null,h=0,R=0}}};return{[Symbol.asyncIterator]:S}}function R0(f,h){return async function(R){const{value:I}=R.headers[":message-type"];if(I==="error"){const A=new Error(R.headers[":error-message"].value||"UnknownError");throw A.name=R.headers[":error-code"].value,A}else if(I==="exception"){const A=R.headers[":exception-type"].value,s={[A]:R},S=await f(s);if(S.$unknown){const w=new Error(h(R.body));throw w.name=A,w}throw S[A]}else if(I==="event"){const A={[R.headers[":event-type"].value]:R},s=await f(A);if(s.$unknown)return;return s}else throw Error(`Unrecognizable event type: ${R.headers[":event-type"].value}`)}}class ZR{constructor({utf8Encoder:f,utf8Decoder:h}){this.eventStreamCodec=new mA(f,h),this.utfEncoder=f}deserialize(f,h){const R=h0(f);return new UA({messageStream:new EA({inputStream:R,decoder:this.eventStreamCodec}),deserializer:R0(h,this.utfEncoder)})}serialize(f,h){return new PA({messageStream:new HA({inputStream:f,serializer:h}),encoder:this.eventStreamCodec,includeEndFrame:!0})}}import{Readable as iP}from"stream";async function*I0(f){let h=!1,R=!1;const I=new Array;f.on("error",(A)=>{if(!h)h=!0;if(A)throw A}),f.on("data",(A)=>{I.push(A)}),f.on("end",()=>{h=!0});while(!R){const A=await new Promise((s)=>setTimeout(()=>s(I.shift()),0));if(A)yield A;R=h&&I.length===0}}class DA{constructor({utf8Encoder:f,utf8Decoder:h}){this.universalMarshaller=new ZR({utf8Decoder:h,utf8Encoder:f})}deserialize(f,h){const R=typeof f[Symbol.asyncIterator]==="function"?f:I0(f);return this.universalMarshaller.deserialize(R,h)}serialize(f,h){return iP.from(this.universalMarshaller.serialize(f,h))}}var A0=(f)=>new DA(f);var s0=K(hI(),1);import{Writable as _P}from"stream";class JR extends _P{constructor(f,h){super(h);this.hash=f}_write(f,h,R){try{this.hash.update(s0.toUint8Array(f))}catch(I){return R(I)}R()}}var S0=(f,h)=>{if(h.readableFlowing!==null)throw new Error("Unable to calculate hash for flowing readable stream");const R=new f,I=new JR(R);return h.pipe(I),new Promise((A,s)=>{h.on("error",(S)=>{I.end(),s(S)}),I.on("error",s),I.on("finish",()=>{R.digest().then(A).catch(s)})})};var VR=K(wR(),1);var QR=K(Vs(),1),zR=K(hI(),1);var P0=(f)=>{return{apiVersion:"2006-03-01",base64Decoder:f?.base64Decoder??m0,base64Encoder:f?.base64Encoder??E0,disableHostPrefix:f?.disableHostPrefix??!1,endpointProvider:f?.endpointProvider??SR,extensions:f?.extensions??[],getAwsChunkedEncodingStream:f?.getAwsChunkedEncodingStream??QR.getAwsChunkedEncodingStream,httpAuthSchemeProvider:f?.httpAuthSchemeProvider??vS,httpAuthSchemes:f?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:(h)=>h.getIdentityProvider("aws.auth#sigv4"),signer:new VR.AwsSdkSigV4Signer},{schemeId:"aws.auth#sigv4a",identityProvider:(h)=>h.getIdentityProvider("aws.auth#sigv4a"),signer:new VR.AwsSdkSigV4ASigner}],logger:f?.logger??new _h,sdkStreamMixin:f?.sdkStreamMixin??QR.sdkStreamMixin,serviceId:f?.serviceId??"S3",signerConstructor:f?.signerConstructor??mI,signingEscapePath:f?.signingEscapePath??!1,urlParser:f?.urlParser??w0,useArnRegion:f?.useArnRegion??!1,utf8Decoder:f?.utf8Decoder??zR.fromUtf8,utf8Encoder:f?.utf8Encoder??zR.toUtf8}};var Z0=(f)=>{H0(process.version);const h=Y0(f),R=()=>h().then(U0),I=P0(f);return lR.emitWarningIfUnsupportedVersion(process.version),{...I,...f,runtime:"node",defaultsMode:h,bodyLengthChecker:f?.bodyLengthChecker??C0,credentialDefaultProvider:f?.credentialDefaultProvider??X0,defaultUserAgentProvider:f?.defaultUserAgentProvider??G0({serviceId:I.serviceId,clientVersion:i3.version}),disableS3ExpressSessionAuth:f?.disableS3ExpressSessionAuth??Ef(II),eventStreamSerdeProvider:f?.eventStreamSerdeProvider??A0,maxAttempts:f?.maxAttempts??Ef(L0),md5:f?.md5??BR.bind(null,"md5"),region:f?.region??Ef(N0,T0),requestChecksumCalculation:f?.requestChecksumCalculation??Ef(_A),requestHandler:M0.create(f?.requestHandler??R),responseChecksumValidation:f?.responseChecksumValidation??Ef(eA),retryMode:f?.retryMode??Ef({...W0,default:async()=>(await R()).retryMode||$0}),sha1:f?.sha1??BR.bind(null,"sha1"),sha256:f?.sha256??BR.bind(null,"sha256"),sigv4aSigningRegionSet:f?.sigv4aSigningRegionSet??Ef(lR.NODE_SIGV4A_CONFIG_OPTIONS),streamCollector:f?.streamCollector??g0,streamHasher:f?.streamHasher??S0,useArnRegion:f?.useArnRegion??Ef(_3),useDualstackEndpoint:f?.useDualstackEndpoint??Ef(D0),useFipsEndpoint:f?.useFipsEndpoint??Ef(F0)}};var J0=(f)=>{const h=f.httpAuthSchemes;let{httpAuthSchemeProvider:R,credentials:I}=f;return{setHttpAuthScheme(A){const s=h.findIndex((S)=>S.schemeId===A.schemeId);if(s===-1)h.push(A);else h.splice(s,1,A)},httpAuthSchemes(){return h},setHttpAuthSchemeProvider(A){R=A},httpAuthSchemeProvider(){return R},setCredentials(A){I=A},credentials(){return I}}},V0=(f)=>{return{httpAuthSchemes:f.httpAuthSchemes(),httpAuthSchemeProvider:f.httpAuthSchemeProvider(),credentials:f.credentials()}};var yR=(f)=>f,d0=(f,h)=>{const R={...yR(y0(f)),...yR(B0(f)),...yR(Q0(f)),...yR(J0(f))};return h.forEach((I)=>I.configure(R)),{...f,...q0(R),...l0(R),...z0(R),...V0(R)}};class FA extends r0{constructor(...[f]){const h=Z0(f||{}),R=cS(h),I=c0(R),A=Ps(I),s=i0(A),S=a0(s),w=O0(S),E=x0(w),P=ls(E),N=rS(P),G=Js(N,{session:[()=>this,SA]}),M=d0(G,f?.extensions||[]);super(M);this.config=M,this.middlewareStack.use(b0(this.config)),this.middlewareStack.use(_0(this.config)),this.middlewareStack.use(k0(this.config)),this.middlewareStack.use(j0(this.config)),this.middlewareStack.use(K0(this.config)),this.middlewareStack.use(v0(this.config)),this.middlewareStack.use(hh.getHttpAuthSchemeEndpointRuleSetPlugin(this.config,{httpAuthSchemeParametersProvider:OS,identityProviderConfigProvider:async(g)=>new hh.DefaultIdentityProviderConfig({"aws.auth#sigv4":g.credentials,"aws.auth#sigv4a":g.credentials})})),this.middlewareStack.use(hh.getHttpSigningPlugin(this.config)),this.middlewareStack.use(Bs(this.config)),this.middlewareStack.use(aA(this.config)),this.middlewareStack.use(Fs(this.config)),this.middlewareStack.use(AI(this.config)),this.middlewareStack.use(SI(this.config))}destroy(){super.destroy()}}function eP(f){return(h)=>async(R)=>{const I={...R.input},A=[{target:"SSECustomerKey",hash:"SSECustomerKeyMD5"},{target:"CopySourceSSECustomerKey",hash:"CopySourceSSECustomerKeyMD5"}];for(let s of A){const S=I[s.target];if(S){let w;if(typeof S==="string")if(pP(S,f))w=f.base64Decoder(S);else w=f.utf8Decoder(S),I[s.target]=f.base64Encoder(w);else w=ArrayBuffer.isView(S)?new Uint8Array(S.buffer,S.byteOffset,S.byteLength):new Uint8Array(S),I[s.target]=f.base64Encoder(w);const E=new f.md5;E.update(w),I[s.hash]=f.base64Encoder(await E.digest())}}return h({...R,input:I})}}function pP(f,h){if(!/^(?:[A-Za-z0-9+/]{4})*([A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/.test(f))return!1;try{return h.base64Decoder(f).length===32}catch{return!1}}var oP={name:"ssecMiddleware",step:"initialize",tags:["SSE"],override:!0},qR=(f)=>({applyToStack:(h)=>{h.add(eP(f),oP)}});class NA extends nf.classBuilder().ep({..._f,Bucket:{type:"contextParams",name:"Bucket"},Key:{type:"contextParams",name:"Key"}}).m(function(f,h,R,I){return[uf(R,this.serialize,this.deserialize),tf(R,f.getEndpointParameterInstructions()),ih(R,{input:this.input,requestChecksumRequired:!1,requestValidationModeMember:"ChecksumMode",responseAlgorithms:["CRC32","CRC32C","SHA256","SHA1"]}),qR(R),Ns(R)]}).s("AmazonS3","GetObject",{}).n("S3Client","GetObjectCommand").f(iS,xS).ser(E3).de(H3).build(){}class TA extends nf.classBuilder().ep({..._f,Bucket:{type:"contextParams",name:"Bucket"},Key:{type:"contextParams",name:"Key"}}).m(function(f,h,R,I){return[uf(R,this.serialize,this.deserialize),tf(R,f.getEndpointParameterInstructions()),ih(R,{input:this.input,requestAlgorithmMember:"ChecksumAlgorithm",requestChecksumRequired:!1}),Us(R),uh(R),qR(R)]}).s("AmazonS3","PutObject",{}).n("S3Client","PutObjectCommand").f(oS,eS).ser(P3).de(D3).build(){}import{Buffer as e0}from"buffer";class o0 extends Of{client;constructor(...f){super();this.client=new FA(...f)}async put(f){let h,R,I,A=process.env.BUCKET_NAME;if(f instanceof Blob)h=f,I=`${Oh()}.${f.type.split("/")[1].split(";")[0]}`,R=f.type;else h=f.body,I=f.name,R=f.contentType;R=h instanceof Blob||h instanceof File?h.type:void 0;const s=h instanceof e0?h:e0.from(await h.arrayBuffer());return await this.client.send(new TA({Bucket:A,Key:I,Body:s,ContentType:R})),I}async fetch(f){let h=process.env.BUCKET_NAME,R;if(typeof f==="string")R=f;else h=f.bucket??h,R=f.name;if(!R)throw new Error("Object name has to be specified");const I=await this.client.send(new NA({Bucket:h,Key:R}));return new Response(I.Body.transformToWebStream(),{headers:{"Content-Type":I.ContentType,"Content-Length":I.ContentLength.toString(),"Cache-Control":"private, max-age=12000, must-revalidate","Last-Modified":I.LastModified?.toUTCString()||"",ETag:I.ETag||""}})}}class dR{}class OR extends dR{requests=new Map;consume(f,h){if(!this.requests.has(f))this.requests.set(f,{date:Date.now(),count:1});else{const R=this.requests.get(f),I=Date.now();if(I-R.date>=60000)this.requests.set(f,{date:I,count:1});else this.requests.set(f,{date:R.date,count:R.count+1})}return this.requests.get(f).count}}class p0 extends If{driver=new OR;boot(){}}import*as hD from"react-dom/server";var Am=K(tw(),1);import{Writable as sD}from"stream";var{defineProperty:uH,getOwnPropertySymbols:fm}=Object,tH=Object.prototype.hasOwnProperty,fD=Object.prototype.propertyIsEnumerable,hm=(f,h,R)=>(h in f)?uH(f,h,{enumerable:!0,configurable:!0,writable:!0,value:R}):f[h]=R,vA=(f,h)=>{for(var R in h||(h={}))if(tH.call(h,R))hm(f,R,h[R]);if(fm){for(var R of fm(h))if(fD.call(h,R))hm(f,R,h[R])}return f},rA=(f,h,R)=>{return new Promise((I,A)=>{var s=(E)=>{try{w(R.next(E))}catch(P){A(P)}},S=(E)=>{try{w(R.throw(E))}catch(P){A(P)}},w=(E)=>E.done?I(E.value):Promise.resolve(E.value).then(s,S);w((R=R.apply(f,h)).next())})},RD={unformatted:["code","pre","em","strong","span"],indent_inner_html:!0,indent_char:" ",indent_size:2,sep:"\n"},ID=(f,h={})=>{return Am.default.html(f,vA(vA({},RD),h))},AD=[{selector:"img",format:"skip"},{selector:"#__react-email-preview",format:"skip"},{selector:"a",options:{linkBrackets:!1}}];var Rm=new TextDecoder("utf-8"),Im=(f)=>rA(void 0,null,function*(){let h="";if("pipeTo"in f){const R=new WritableStream({write(I){h+=Rm.decode(I)}});yield f.pipeTo(R)}else{const R=new sD({write(I,A,s){h+=Rm.decode(I),s()}});return f.pipe(R),new Promise((I,A)=>{R.on("error",A),R.on("close",()=>{I(h)})})}return h}),_R=(f,h)=>rA(void 0,null,function*(){const{default:R}=yield import("react-dom/server");let I;if(Object.hasOwn(R,"renderToReadableStream"))I=yield Im(yield R.renderToReadableStream(f));else yield new Promise((S,w)=>{const E=R.renderToPipeableStream(f,{onAllReady(){return rA(this,null,function*(){I=yield Im(E),S()})},onError(P){w(P)}})});if(h==null?void 0:h.plainText)return cA(I,vA({selectors:AD},h.htmlToTextOptions));const s=`${'<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">'}${I.replace(/<!DOCTYPE.*?>/,"")}`;if(h==null?void 0:h.pretty)return ID(s);return s});var{defineProperty:SD,defineProperties:wD,getOwnPropertyDescriptors:mD,getOwnPropertySymbols:sm}=Object,ED=Object.prototype.hasOwnProperty,PD=Object.prototype.propertyIsEnumerable,Sm=(f,h,R)=>(h in f)?SD(f,h,{enumerable:!0,configurable:!0,writable:!0,value:R}):f[h]=R,qh=(f,h)=>{for(var R in h||(h={}))if(ED.call(h,R))Sm(f,R,h[R]);if(sm){for(var R of sm(h))if(PD.call(h,R))Sm(f,R,h[R])}return f},UD=(f,h)=>wD(f,mD(h)),Z=(f,h,R)=>{return new Promise((I,A)=>{var s=(E)=>{try{w(R.next(E))}catch(P){A(P)}},S=(E)=>{try{w(R.throw(E))}catch(P){A(P)}},w=(E)=>E.done?I(E.value):Promise.resolve(E.value).then(s,S);w((R=R.apply(f,h)).next())})},HD="3.5.0",DD=class{constructor(f){this.resend=f}create(f){return Z(this,arguments,function*(h,R={}){return yield this.resend.post("/api-keys",h,R)})}list(){return Z(this,null,function*(){return yield this.resend.get("/api-keys")})}remove(f){return Z(this,null,function*(){return yield this.resend.delete(`/api-keys/${f}`)})}},FD=class{constructor(f){this.resend=f}create(f){return Z(this,arguments,function*(h,R={}){return yield this.resend.post("/audiences",h,R)})}list(){return Z(this,null,function*(){return yield this.resend.get("/audiences")})}get(f){return Z(this,null,function*(){return yield this.resend.get(`/audiences/${f}`)})}remove(f){return Z(this,null,function*(){return yield this.resend.delete(`/audiences/${f}`)})}},ND=class{constructor(f){this.resend=f}send(f){return Z(this,arguments,function*(h,R={}){return this.create(h,R)})}create(f){return Z(this,arguments,function*(h,R={}){for(let A of h)if(A.react)A.html=yield _R(A.react),delete A.react;return yield this.resend.post("/emails/batch",h,R)})}},TD=class{constructor(f){this.resend=f}create(f){return Z(this,arguments,function*(h,R={}){return yield this.resend.post(`/audiences/${h.audienceId}/contacts`,{unsubscribed:h.unsubscribed,email:h.email,first_name:h.firstName,last_name:h.lastName},R)})}list(f){return Z(this,null,function*(){return yield this.resend.get(`/audiences/${f.audienceId}/contacts`)})}get(f){return Z(this,null,function*(){return yield this.resend.get(`/audiences/${f.audienceId}/contacts/${f.id}`)})}update(f){return Z(this,null,function*(){return yield this.resend.patch(`/audiences/${f.audienceId}/contacts/${f.id}`,{unsubscribed:f.unsubscribed,first_name:f.firstName,last_name:f.lastName})})}remove(f){return Z(this,null,function*(){return yield this.resend.delete(`/audiences/${f.audienceId}/contacts/${(f==null?void 0:f.email)?f==null?void 0:f.email:f==null?void 0:f.id}`)})}},$D=class{constructor(f){this.resend=f}create(f){return Z(this,arguments,function*(h,R={}){return yield this.resend.post("/domains",h,R)})}list(){return Z(this,null,function*(){return yield this.resend.get("/domains")})}get(f){return Z(this,null,function*(){return yield this.resend.get(`/domains/${f}`)})}update(f){return Z(this,null,function*(){return yield this.resend.patch(`/domains/${f.id}`,{click_tracking:f.clickTracking,open_tracking:f.openTracking,tls:f.tls})})}remove(f){return Z(this,null,function*(){return yield this.resend.delete(`/domains/${f}`)})}verify(f){return Z(this,null,function*(){return yield this.resend.post(`/domains/${f}/verify`)})}},LD=class{constructor(f){this.resend=f}send(f){return Z(this,arguments,function*(h,R={}){return this.create(h,R)})}create(f){return Z(this,arguments,function*(h,R={}){if(h.react)h.html=yield _R(h.react),delete h.react;return yield this.resend.post("/emails",h,R)})}get(f){return Z(this,null,function*(){return yield this.resend.get(`/emails/${f}`)})}},wm="https://api.resend.com",mm=`resend-node:${HD}`,WD=typeof process!=="undefined"&&process.env?process.env.RESEND_BASE_URL||wm:wm,MD=typeof process!=="undefined"&&process.env?process.env.RESEND_USER_AGENT||mm:mm,Em=class{constructor(f){if(this.key=f,this.apiKeys=new DD(this),this.audiences=new FD(this),this.batch=new ND(this),this.contacts=new TD(this),this.domains=new $D(this),this.emails=new LD(this),!f){if(typeof process!=="undefined"&&process.env)this.key=process.env.RESEND_API_KEY;if(!this.key)throw new Error('Missing API key. Pass it to the constructor `new Resend("re_123")`')}this.headers=new Headers({Authorization:`Bearer ${this.key}`,"User-Agent":MD,"Content-Type":"application/json"})}fetchRequest(f){return Z(this,arguments,function*(h,R={}){try{const I=yield fetch(`${WD}${h}`,R);if(!I.ok)try{const s=yield I.text();return{data:null,error:JSON.parse(s)}}catch(s){if(s instanceof SyntaxError)return{data:null,error:{name:"application_error",message:"Internal server error. We are unable to process your request right now, please try again later."}};const S={message:I.statusText,name:"application_error"};if(s instanceof Error)return{data:null,error:UD(qh({},S),{message:s.message})};return{data:null,error:S}}return{data:yield I.json(),error:null}}catch(I){return{data:null,error:{name:"application_error",message:"Unable to fetch data. The request could not be resolved."}}}})}post(f,h){return Z(this,arguments,function*(R,I,A={}){const s=qh({method:"POST",headers:this.headers,body:JSON.stringify(I)},A);return this.fetchRequest(R,s)})}get(f){return Z(this,arguments,function*(h,R={}){const I=qh({method:"GET",headers:this.headers},R);return this.fetchRequest(h,I)})}put(f,h){return Z(this,arguments,function*(R,I,A={}){const s=qh({method:"PUT",headers:this.headers,body:JSON.stringify(I)},A);return this.fetchRequest(R,s)})}patch(f,h){return Z(this,arguments,function*(R,I,A={}){const s=qh({method:"PATCH",headers:this.headers,body:JSON.stringify(I)},A);return this.fetchRequest(R,s)})}delete(f,h){return Z(this,null,function*(){const R={method:"DELETE",headers:this.headers,body:JSON.stringify(h)};return this.fetchRequest(f,R)})}};class eR{}class oR extends eR{f;constructor(f=process.env.RESEND_API_KEY){super();this.apiKey=f}async send(f){const h=new Em(this.apiKey),{data:R,error:I}=await h.emails.send({...f});if(I)return console.error(I),!1;if(R)return!0}}class Pm extends If{driver=new oR;boot(){}}class Um extends If{channels={};boot(){}}class Hm extends If{root;rootRouter;boot(){}}class Dm extends If{rootRouter;boot(){return"Origin"}}export{Hm as ViewRouterServiceProvider,o0 as S3Driver,oR as ResendDriver,p0 as RateLimiterServiceProvider,dR as RateLimiterDriver,OR as InMemoryRateLimiter,jh as FileSystemDriver,bA as FileStorageServiceProvider,Of as FileStorageDriver,Pm as EmailServiceProvider,eR as EmailDriver,Um as BroadcastingServiceProvider,Dm as ApiRouterServiceProvider};export{bA as w,Dm as x,p0 as y,Pm as z,Um as A,Hm as B};
|
|
6
3
|
|
|
7
|
-
|
|
8
|
-
${e}`}async createStringToSign(r,s,e){const f=new this.sha256;f.update(Y(e));const l=await f.digest();return`${cs}
|
|
9
|
-
${r}
|
|
10
|
-
${s}
|
|
11
|
-
${Jr.toHex(l)}`}getCanonicalPath({path:r}){if(this.uriEscapePath){const s=[];for(let l of r.split("/")){if(l?.length===0)continue;if(l===".")continue;if(l==="..")s.pop();else s.push(l)}const e=`${r?.startsWith("/")?"/":""}${s.join("/")}${s.length>0&&r?.endsWith("/")?"/":""}`;return cr(e).replace(/%2F/g,"/")}return r}async getSignature(r,s,e,f){const l=await this.createStringToSign(r,s,f),a=new this.sha256(await e);return a.update(Y(l)),Jr.toHex(await a.digest())}getSigningKey(r,s,e,f){return Zl(this.sha256,r,e,s,f||this.service)}validateResolvedCredentials(r){if(typeof r!=="object"||typeof r.accessKeyId!=="string"||typeof r.secretAccessKey!=="string")throw new Error("Resolved credential object is not valid")}}var $s=(r)=>{const s=Ol(r).replace(/[\-:]/g,"");return{longDate:s,shortDate:s.slice(0,8)}},_l=(r)=>Object.keys(r).sort().join(";");var ql="Directory",jl="S3Express",il="sigv4-s3express",ys="X-Amz-S3session-Token",Br=ys.toLowerCase(),dw="AWS_S3_DISABLE_EXPRESS_SESSION_AUTH",Aw="s3_disable_express_session_auth",He={environmentVariableSelector:(r)=>er(r,dw,fr.ENV),configFileSelector:(r)=>er(r,Aw,fr.CONFIG),default:!1};function bl(r){return{accessKeyId:r.accessKeyId,secretAccessKey:r.secretAccessKey,expiration:r.expiration}}function xl(r,s){const e=setTimeout(()=>{throw new Error("SignatureV4S3Express credential override was created but not called.")},10),f=r.credentialProvider,l=()=>{return clearTimeout(e),r.credentialProvider=f,Promise.resolve(s)};r.credentialProvider=l}class Us extends Ce{async signWithCredentials(r,s,e){const f=bl(s);r.headers[Br]=s.sessionToken;const l=this;return xl(l,f),l.signRequest(r,e??{})}async presignWithCredentials(r,s,e){const f=bl(s);return delete r.headers[Br],r.headers[ys]=s.sessionToken,r.query=r.query??{},r.query[ys]=s.sessionToken,xl(this,f),this.presign(r,e)}}var ol=(r)=>{return(s,e)=>async(f)=>{if(e.endpointV2){const l=e.endpointV2,a=l.properties?.authSchemes?.[0]?.name===il;if(l.properties?.backend===jl||l.properties?.bucketType===ql)e.isS3ExpressBucket=!0;if(a){const m=f.input.Bucket;if(m){const g=await r.s3ExpressIdentityProvider.getS3ExpressIdentity(await r.credentials(),{Bucket:m});if(e.s3ExpressIdentity=g,L.isInstance(f.request)&&g.sessionToken)f.request.headers[Br]=g.sessionToken}}}return s(f)}},nl={name:"s3ExpressMiddleware",step:"build",tags:["S3","S3_EXPRESS"],override:!0},ve=(r)=>({applyToStack:(s)=>{s.add(ol(r),nl)}});var ul=T(Ge(),1);var Sw=T(Rw(),1),tl=T(Rs(),1);var pl=async(r,s,e,f)=>{const l=await f.signWithCredentials(e,r,{});if(l.headers["X-Amz-Security-Token"]||l.headers["x-amz-security-token"])throw new Error("X-Amz-Security-Token must not be set for s3-express requests.");return l};var Ew=(r)=>(s)=>{throw s},cw=(r,s)=>{};var ra=(r)=>(s,e)=>async(f)=>{if(!L.isInstance(f.request))return s(f);const a=tl.getSmithyContext(e).selectedHttpAuthScheme;if(!a)throw new Error("No HttpAuthScheme was selected: unable to sign request");const{httpAuthOption:{signingProperties:h={}},identity:m,signer:g}=a;let w;if(e.s3ExpressIdentity)w=await pl(e.s3ExpressIdentity,h,f.request,await r.signer());else w=await g.sign(f.request,m,h);const E=await s({...f,request:w}).catch((g.errorHandler||Ew)(h));return(g.successHandler||cw)(E.response,h),E},ze=(r)=>({applyToStack:(s)=>{s.addRelativeTo(ra(r),ul.httpSigningMiddlewareOptions)}});var sa=(r,{session:s})=>{const[e,f]=s;return{...r,forcePathStyle:r.forcePathStyle??!1,useAccelerateEndpoint:r.useAccelerateEndpoint??!1,disableMultiregionAccessPoints:r.disableMultiregionAccessPoints??!1,followRegionRedirects:r.followRegionRedirects??!1,s3ExpressIdentityProvider:r.s3ExpressIdentityProvider??new Sr(async(l)=>e().send(new f({Bucket:l,SessionMode:"ReadWrite"}))),bucketEndpoint:r.bucketEndpoint??!1}};var Iw={CopyObjectCommand:!0,UploadPartCopyCommand:!0,CompleteMultipartUploadCommand:!0},Pw=3000,kw=(r)=>(s,e)=>async(f)=>{const l=await s(f),{response:a}=l;if(!Es.isInstance(a))return l;const{statusCode:h,body:m}=a;if(h<200||h>=300)return l;if(!(typeof m?.stream==="function"||typeof m?.pipe==="function"||typeof m?.tee==="function"))return l;let w=m,E=m;if(m&&typeof m==="object"&&!(m instanceof Uint8Array))[w,E]=await ea(m);a.body=E;const I=await Nw(w,{streamCollector:async(N)=>{return fa(N,Pw)}});if(typeof w?.destroy==="function")w.destroy();const P=r.utf8Encoder(I.subarray(I.length-16));if(I.length===0&&Iw[e.commandName]){const N=new Error("S3 aborted request");throw N.name="InternalError",N}if(P&&P.endsWith("</Error>"))a.statusCode=400;return l},Nw=(r=new Uint8Array,s)=>{if(r instanceof Uint8Array)return Promise.resolve(r);return s.streamCollector(r)||Promise.resolve(new Uint8Array)},Dw={relation:"after",toMiddleware:"deserializerMiddleware",tags:["THROW_200_EXCEPTIONS","S3"],name:"throw200ExceptionsMiddleware",override:!0},Ts=(r)=>({applyToStack:(s)=>{s.addRelativeTo(kw(r),Dw)}});var Fe=(r)=>typeof r==="string"&&r.indexOf("arn:")===0&&r.split(":").length>=6;function la(r){return(s,e)=>async(f)=>{if(r.bucketEndpoint){const l=e.endpointV2;if(l){const a=f.input.Bucket;if(typeof a==="string")try{const h=new URL(a);e.endpointV2={...l,url:h}}catch(h){const m=`@aws-sdk/middleware-sdk-s3: bucketEndpoint=true was set but Bucket=${a} could not be parsed as URL.`;if(e.logger?.constructor?.name==="NoOpLogger")console.warn(m);else e.logger?.warn?.(m);throw h}}}return s(f)}}var aa={name:"bucketEndpointMiddleware",override:!0,relation:"after",toMiddleware:"endpointV2Middleware"};function $w({bucketEndpoint:r}){return(s)=>async(e)=>{const{input:{Bucket:f}}=e;if(!r&&typeof f==="string"&&!Fe(f)&&f.indexOf("/")>=0){const l=new Error(`Bucket name shouldn't contain '/', received '${f}'`);throw l.name="InvalidBucketName",l}return s({...e})}}var yw={step:"initialize",tags:["VALIDATE_BUCKET_NAME"],name:"validateBucketNameMiddleware",override:!0},ha=(r)=>({applyToStack:(s)=>{s.add($w(r),yw),s.addRelativeTo(la(r),aa)}});var Hr=T(Ge(),1);var ma=(r)=>({...r,eventStreamMarshaller:r.eventStreamSerdeProvider(r)});var Ws=T(Ls(),1);var Ms={CrtSignerV4:null};class Ke{constructor(r){this.sigv4Signer=new Us(r),this.signerOptions=r}async sign(r,s={}){if(s.signingRegion==="*"){if(this.signerOptions.runtime!=="node")throw new Error("This request requires signing with SigV4Asymmetric algorithm. It's only available in Node.js");return this.getSigv4aSigner().sign(r,s)}return this.sigv4Signer.sign(r,s)}async signWithCredentials(r,s,e={}){if(e.signingRegion==="*"){if(this.signerOptions.runtime!=="node")throw new Error("This request requires signing with SigV4Asymmetric algorithm. It's only available in Node.js");return this.getSigv4aSigner().signWithCredentials(r,s,e)}return this.sigv4Signer.signWithCredentials(r,s,e)}async presign(r,s={}){if(s.signingRegion==="*"){if(this.signerOptions.runtime!=="node")throw new Error("This request requires signing with SigV4Asymmetric algorithm. It's only available in Node.js");return this.getSigv4aSigner().presign(r,s)}return this.sigv4Signer.presign(r,s)}async presignWithCredentials(r,s,e={}){if(e.signingRegion==="*")throw new Error("Method presignWithCredentials is not supported for [signingRegion=*].");return this.sigv4Signer.presignWithCredentials(r,s,e)}getSigv4aSigner(){if(!this.sigv4aSigner){let r=null;try{if(r=Ms.CrtSignerV4,typeof r!=="function")throw new Error}catch(s){throw s.message=`${s.message}\nPlease check whether you have installed the "@aws-sdk/signature-v4-crt" package explicitly. \nYou must also register the package by calling [require("@aws-sdk/signature-v4-crt");] or an ESM equivalent such as [import "@aws-sdk/signature-v4-crt";]. \nFor more information please go to https://github.com/aws/aws-sdk-js-v3#functionality-requiring-aws-common-runtime-crt`,s}this.sigv4aSigner=new r({...this.signerOptions,signingAlgorithm:1})}return this.sigv4aSigner}}var _r=T(Rs(),1);var Ir={["required"]:!1,["type"]:"String"},Pr={["required"]:!0,default:!1,["type"]:"Boolean"},Yr={["required"]:!1,["type"]:"Boolean"},_={["fn"]:"booleanEquals",["argv"]:[{["ref"]:"Accelerate"},!0]},$={["fn"]:"booleanEquals",["argv"]:[{["ref"]:"UseFIPS"},!0]},D={["fn"]:"booleanEquals",["argv"]:[{["ref"]:"UseDualStack"},!0]},C={["fn"]:"isSet",["argv"]:[{["ref"]:"Endpoint"}]},ua={["fn"]:"aws.partition",["argv"]:[{["ref"]:"Region"}],["assign"]:"partitionResult"},ga={["fn"]:"stringEquals",["argv"]:[{["fn"]:"getAttr",["argv"]:[{["ref"]:"partitionResult"},"name"]},"aws-cn"]},zs={["fn"]:"isSet",["argv"]:[{["ref"]:"Bucket"}]},Q={["ref"]:"Bucket"},W={["fn"]:"parseURL",["argv"]:[{["ref"]:"Endpoint"}],["assign"]:"url"},Gs={["fn"]:"booleanEquals",["argv"]:[{["fn"]:"getAttr",["argv"]:[{["ref"]:"url"},"isIp"]},!0]},ta={["ref"]:"url"},rh={["fn"]:"uriEncode",["argv"]:[Q],["assign"]:"uri_encoded_bucket"},x={["backend"]:"S3Express",["authSchemes"]:[{["disableDoubleEncoding"]:!0,["name"]:"sigv4",["signingName"]:"s3express",["signingRegion"]:"{Region}"}]},d={},sh={["fn"]:"aws.isVirtualHostableS3Bucket",["argv"]:[Q,!1]},Le={["error"]:"S3Express bucket name is not a valid virtual hostable name.",["type"]:"error"},Fs={["backend"]:"S3Express",["authSchemes"]:[{["disableDoubleEncoding"]:!0,["name"]:"sigv4-s3express",["signingName"]:"s3express",["signingRegion"]:"{Region}"}]},wa={["fn"]:"isSet",["argv"]:[{["ref"]:"UseS3ExpressControlEndpoint"}]},da={["fn"]:"booleanEquals",["argv"]:[{["ref"]:"UseS3ExpressControlEndpoint"},!0]},A={["fn"]:"not",["argv"]:[C]},Aa={["error"]:"Unrecognized S3Express bucket name format.",["type"]:"error"},Ra={["fn"]:"not",["argv"]:[zs]},Sa={["ref"]:"hardwareType"},Ea={["conditions"]:[A],["error"]:"Expected a endpoint to be specified but no endpoint was found",["type"]:"error"},Cs={["authSchemes"]:[{["disableDoubleEncoding"]:!0,["name"]:"sigv4a",["signingName"]:"s3-outposts",["signingRegionSet"]:["*"]},{["disableDoubleEncoding"]:!0,["name"]:"sigv4",["signingName"]:"s3-outposts",["signingRegion"]:"{Region}"}]},We={["fn"]:"booleanEquals",["argv"]:[{["ref"]:"ForcePathStyle"},!1]},Uw={["ref"]:"ForcePathStyle"},M={["fn"]:"booleanEquals",["argv"]:[{["ref"]:"Accelerate"},!1]},v={["fn"]:"stringEquals",["argv"]:[{["ref"]:"Region"},"aws-global"]},z={["authSchemes"]:[{["disableDoubleEncoding"]:!0,["name"]:"sigv4",["signingName"]:"s3",["signingRegion"]:"us-east-1"}]},c={["fn"]:"not",["argv"]:[v]},F={["fn"]:"booleanEquals",["argv"]:[{["ref"]:"UseGlobalEndpoint"},!0]},ca={["url"]:"https://{Bucket}.s3-fips.dualstack.{Region}.{partitionResult#dnsSuffix}",["properties"]:{["authSchemes"]:[{["disableDoubleEncoding"]:!0,["name"]:"sigv4",["signingName"]:"s3",["signingRegion"]:"{Region}"}]},["headers"]:{}},H={["authSchemes"]:[{["disableDoubleEncoding"]:!0,["name"]:"sigv4",["signingName"]:"s3",["signingRegion"]:"{Region}"}]},K={["fn"]:"booleanEquals",["argv"]:[{["ref"]:"UseGlobalEndpoint"},!1]},S={["fn"]:"booleanEquals",["argv"]:[{["ref"]:"UseDualStack"},!1]},Ia={["url"]:"https://{Bucket}.s3-fips.{Region}.{partitionResult#dnsSuffix}",["properties"]:H,["headers"]:{}},R={["fn"]:"booleanEquals",["argv"]:[{["ref"]:"UseFIPS"},!1]},Pa={["url"]:"https://{Bucket}.s3-accelerate.dualstack.{partitionResult#dnsSuffix}",["properties"]:H,["headers"]:{}},ka={["url"]:"https://{Bucket}.s3.dualstack.{Region}.{partitionResult#dnsSuffix}",["properties"]:H,["headers"]:{}},Qe={["fn"]:"booleanEquals",["argv"]:[{["fn"]:"getAttr",["argv"]:[ta,"isIp"]},!1]},Xe={["url"]:"{url#scheme}://{url#authority}{url#normalizedPath}{Bucket}",["properties"]:H,["headers"]:{}},ef={["url"]:"{url#scheme}://{Bucket}.{url#authority}{url#path}",["properties"]:H,["headers"]:{}},Na={["endpoint"]:ef,["type"]:"endpoint"},Ze={["url"]:"https://{Bucket}.s3-accelerate.{partitionResult#dnsSuffix}",["properties"]:H,["headers"]:{}},Da={["url"]:"https://{Bucket}.s3.{Region}.{partitionResult#dnsSuffix}",["properties"]:H,["headers"]:{}},Hs={["error"]:"Invalid region: region was not a valid DNS name.",["type"]:"error"},J={["ref"]:"bucketArn"},eh={["ref"]:"arnType"},Ve={["fn"]:"getAttr",["argv"]:[J,"service"]},ff={["ref"]:"accessPointName"},$a={["conditions"]:[D],["error"]:"S3 Object Lambda does not support Dual-stack",["type"]:"error"},ya={["conditions"]:[_],["error"]:"S3 Object Lambda does not support S3 Accelerate",["type"]:"error"},Ua={["conditions"]:[{["fn"]:"isSet",["argv"]:[{["ref"]:"DisableAccessPoints"}]},{["fn"]:"booleanEquals",["argv"]:[{["ref"]:"DisableAccessPoints"},!0]}],["error"]:"Access points are not supported for this operation",["type"]:"error"},Je={["conditions"]:[{["fn"]:"isSet",["argv"]:[{["ref"]:"UseArnRegion"}]},{["fn"]:"booleanEquals",["argv"]:[{["ref"]:"UseArnRegion"},!1]},{["fn"]:"not",["argv"]:[{["fn"]:"stringEquals",["argv"]:[{["fn"]:"getAttr",["argv"]:[J,"region"]},"{Region}"]}]}],["error"]:"Invalid configuration: region from ARN `{bucketArn#region}` does not match client region `{Region}` and UseArnRegion is `false`",["type"]:"error"},fh={["fn"]:"getAttr",["argv"]:[{["ref"]:"bucketPartition"},"name"]},lh={["fn"]:"getAttr",["argv"]:[J,"accountId"]},Be={["authSchemes"]:[{["disableDoubleEncoding"]:!0,["name"]:"sigv4",["signingName"]:"s3-object-lambda",["signingRegion"]:"{bucketArn#region}"}]},Ta={["error"]:"Invalid ARN: The access point name may only contain a-z, A-Z, 0-9 and `-`. Found: `{accessPointName}`",["type"]:"error"},Ye={["error"]:"Invalid ARN: The account id may only contain a-z, A-Z, 0-9 and `-`. Found: `{bucketArn#accountId}`",["type"]:"error"},Oe={["error"]:"Invalid region in ARN: `{bucketArn#region}` (invalid DNS name)",["type"]:"error"},_e={["error"]:"Client was configured for partition `{partitionResult#name}` but ARN (`{Bucket}`) has `{bucketPartition#name}`",["type"]:"error"},Ma={["error"]:"Invalid ARN: The ARN may only contain a single resource component after `accesspoint`.",["type"]:"error"},Ca={["error"]:"Invalid ARN: Expected a resource of the format `accesspoint:<accesspoint name>` but no name was provided",["type"]:"error"},Or={["authSchemes"]:[{["disableDoubleEncoding"]:!0,["name"]:"sigv4",["signingName"]:"s3",["signingRegion"]:"{bucketArn#region}"}]},Ha={["authSchemes"]:[{["disableDoubleEncoding"]:!0,["name"]:"sigv4a",["signingName"]:"s3-outposts",["signingRegionSet"]:["*"]},{["disableDoubleEncoding"]:!0,["name"]:"sigv4",["signingName"]:"s3-outposts",["signingRegion"]:"{bucketArn#region}"}]},va={["fn"]:"aws.parseArn",["argv"]:[Q]},Ga={["url"]:"https://s3-fips.dualstack.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",["properties"]:H,["headers"]:{}},za={["url"]:"https://s3-fips.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",["properties"]:H,["headers"]:{}},Fa={["url"]:"https://s3.dualstack.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",["properties"]:H,["headers"]:{}},qe={["url"]:"{url#scheme}://{url#authority}{url#normalizedPath}{uri_encoded_bucket}",["properties"]:H,["headers"]:{}},Ka={["url"]:"https://s3.{Region}.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",["properties"]:H,["headers"]:{}},La={["ref"]:"UseObjectLambdaEndpoint"},je={["authSchemes"]:[{["disableDoubleEncoding"]:!0,["name"]:"sigv4",["signingName"]:"s3-object-lambda",["signingRegion"]:"{Region}"}]},Wa={["url"]:"https://s3-fips.dualstack.{Region}.{partitionResult#dnsSuffix}",["properties"]:H,["headers"]:{}},Qa={["url"]:"https://s3-fips.{Region}.{partitionResult#dnsSuffix}",["properties"]:H,["headers"]:{}},Xa={["url"]:"https://s3.dualstack.{Region}.{partitionResult#dnsSuffix}",["properties"]:H,["headers"]:{}},ie={["url"]:"{url#scheme}://{url#authority}{url#path}",["properties"]:H,["headers"]:{}},Za={["url"]:"https://s3.{Region}.{partitionResult#dnsSuffix}",["properties"]:H,["headers"]:{}},be=[{["ref"]:"Region"}],Tw=[{["ref"]:"Endpoint"}],Mw=[Q],xe=[D],vs=[_],lr=[C,W],Va=[{["fn"]:"isSet",["argv"]:[{["ref"]:"DisableS3ExpressSessionAuth"}]},{["fn"]:"booleanEquals",["argv"]:[{["ref"]:"DisableS3ExpressSessionAuth"},!0]}],Ja=[Gs],oe=[rh],ne=[sh],kr=[$],Ba=[{["fn"]:"substring",["argv"]:[Q,6,14,!0],["assign"]:"s3expressAvailabilityZoneId"},{["fn"]:"substring",["argv"]:[Q,14,16,!0],["assign"]:"s3expressAvailabilityZoneDelim"},{["fn"]:"stringEquals",["argv"]:[{["ref"]:"s3expressAvailabilityZoneDelim"},"--"]}],Ya=[{["conditions"]:[$],["endpoint"]:{["url"]:"https://{Bucket}.s3express-fips-{s3expressAvailabilityZoneId}.{Region}.amazonaws.com",["properties"]:x,["headers"]:{}},["type"]:"endpoint"},{["endpoint"]:{["url"]:"https://{Bucket}.s3express-{s3expressAvailabilityZoneId}.{Region}.amazonaws.com",["properties"]:x,["headers"]:{}},["type"]:"endpoint"}],Oa=[{["fn"]:"substring",["argv"]:[Q,6,15,!0],["assign"]:"s3expressAvailabilityZoneId"},{["fn"]:"substring",["argv"]:[Q,15,17,!0],["assign"]:"s3expressAvailabilityZoneDelim"},{["fn"]:"stringEquals",["argv"]:[{["ref"]:"s3expressAvailabilityZoneDelim"},"--"]}],_a=[{["conditions"]:[$],["endpoint"]:{["url"]:"https://{Bucket}.s3express-fips-{s3expressAvailabilityZoneId}.{Region}.amazonaws.com",["properties"]:Fs,["headers"]:{}},["type"]:"endpoint"},{["endpoint"]:{["url"]:"https://{Bucket}.s3express-{s3expressAvailabilityZoneId}.{Region}.amazonaws.com",["properties"]:Fs,["headers"]:{}},["type"]:"endpoint"}],Cw=[zs],qa=[{["fn"]:"isValidHostLabel",["argv"]:[{["ref"]:"outpostId"},!1]}],ja=[{["fn"]:"stringEquals",["argv"]:[{["ref"]:"regionPrefix"},"beta"]}],Hw=["*"],n=[ua],ia=[{["fn"]:"isValidHostLabel",["argv"]:[{["ref"]:"Region"},!1]}],p=[{["fn"]:"stringEquals",["argv"]:[{["ref"]:"Region"},"us-east-1"]}],pe=[{["fn"]:"stringEquals",["argv"]:[eh,"accesspoint"]}],ba=[{["fn"]:"getAttr",["argv"]:[J,"resourceId[1]"],["assign"]:"accessPointName"},{["fn"]:"not",["argv"]:[{["fn"]:"stringEquals",["argv"]:[ff,""]}]}],vw=[J,"resourceId[1]"],ue=[{["fn"]:"not",["argv"]:[{["fn"]:"stringEquals",["argv"]:[{["fn"]:"getAttr",["argv"]:[J,"region"]},""]}]}],xa=[{["fn"]:"not",["argv"]:[{["fn"]:"isSet",["argv"]:[{["fn"]:"getAttr",["argv"]:[J,"resourceId[2]"]}]}]}],Gw=[J,"resourceId[2]"],te=[{["fn"]:"aws.partition",["argv"]:[{["fn"]:"getAttr",["argv"]:[J,"region"]}],["assign"]:"bucketPartition"}],oa=[{["fn"]:"stringEquals",["argv"]:[fh,{["fn"]:"getAttr",["argv"]:[{["ref"]:"partitionResult"},"name"]}]}],rf=[{["fn"]:"isValidHostLabel",["argv"]:[{["fn"]:"getAttr",["argv"]:[J,"region"]},!0]}],sf=[{["fn"]:"isValidHostLabel",["argv"]:[lh,!1]}],na=[{["fn"]:"isValidHostLabel",["argv"]:[ff,!1]}],pa=[{["fn"]:"isValidHostLabel",["argv"]:[{["ref"]:"Region"},!0]}],zw={version:"1.0",parameters:{Bucket:Ir,Region:Ir,UseFIPS:Pr,UseDualStack:Pr,Endpoint:Ir,ForcePathStyle:Pr,Accelerate:Pr,UseGlobalEndpoint:Pr,UseObjectLambdaEndpoint:Yr,Key:Ir,Prefix:Ir,CopySource:Ir,DisableAccessPoints:Yr,DisableMultiRegionAccessPoints:Pr,UseArnRegion:Yr,UseS3ExpressControlEndpoint:Yr,DisableS3ExpressSessionAuth:Yr},rules:[{["conditions"]:[{["fn"]:"isSet",["argv"]:be}],rules:[{["conditions"]:[_,$],error:"Accelerate cannot be used with FIPS",["type"]:"error"},{["conditions"]:[D,C],error:"Cannot set dual-stack in combination with a custom endpoint.",["type"]:"error"},{["conditions"]:[C,$],error:"A custom endpoint cannot be combined with FIPS",["type"]:"error"},{["conditions"]:[C,_],error:"A custom endpoint cannot be combined with S3 Accelerate",["type"]:"error"},{["conditions"]:[$,ua,ga],error:"Partition does not support FIPS",["type"]:"error"},{["conditions"]:[zs,{["fn"]:"substring",["argv"]:[Q,0,6,!0],["assign"]:"bucketSuffix"},{["fn"]:"stringEquals",["argv"]:[{["ref"]:"bucketSuffix"},"--x-s3"]}],rules:[{["conditions"]:xe,error:"S3Express does not support Dual-stack.",["type"]:"error"},{["conditions"]:vs,error:"S3Express does not support S3 Accelerate.",["type"]:"error"},{["conditions"]:lr,rules:[{["conditions"]:Va,rules:[{["conditions"]:Ja,rules:[{["conditions"]:oe,rules:[{endpoint:{["url"]:"{url#scheme}://{url#authority}/{uri_encoded_bucket}{url#path}",["properties"]:x,["headers"]:d},["type"]:"endpoint"}],["type"]:"tree"}],["type"]:"tree"},{["conditions"]:ne,rules:[{endpoint:{["url"]:"{url#scheme}://{Bucket}.{url#authority}{url#path}",["properties"]:x,["headers"]:d},["type"]:"endpoint"}],["type"]:"tree"},Le],["type"]:"tree"},{["conditions"]:Ja,rules:[{["conditions"]:oe,rules:[{endpoint:{["url"]:"{url#scheme}://{url#authority}/{uri_encoded_bucket}{url#path}",["properties"]:Fs,["headers"]:d},["type"]:"endpoint"}],["type"]:"tree"}],["type"]:"tree"},{["conditions"]:ne,rules:[{endpoint:{["url"]:"{url#scheme}://{Bucket}.{url#authority}{url#path}",["properties"]:Fs,["headers"]:d},["type"]:"endpoint"}],["type"]:"tree"},Le],["type"]:"tree"},{["conditions"]:[wa,da],rules:[{["conditions"]:[rh,A],rules:[{["conditions"]:kr,endpoint:{["url"]:"https://s3express-control-fips.{Region}.amazonaws.com/{uri_encoded_bucket}",["properties"]:x,["headers"]:d},["type"]:"endpoint"},{endpoint:{["url"]:"https://s3express-control.{Region}.amazonaws.com/{uri_encoded_bucket}",["properties"]:x,["headers"]:d},["type"]:"endpoint"}],["type"]:"tree"}],["type"]:"tree"},{["conditions"]:ne,rules:[{["conditions"]:Va,rules:[{["conditions"]:Ba,rules:Ya,["type"]:"tree"},{["conditions"]:Oa,rules:Ya,["type"]:"tree"},Aa],["type"]:"tree"},{["conditions"]:Ba,rules:_a,["type"]:"tree"},{["conditions"]:Oa,rules:_a,["type"]:"tree"},Aa],["type"]:"tree"},Le],["type"]:"tree"},{["conditions"]:[Ra,wa,da],rules:[{["conditions"]:lr,endpoint:{["url"]:"{url#scheme}://{url#authority}{url#path}",["properties"]:x,["headers"]:d},["type"]:"endpoint"},{["conditions"]:kr,endpoint:{["url"]:"https://s3express-control-fips.{Region}.amazonaws.com",["properties"]:x,["headers"]:d},["type"]:"endpoint"},{endpoint:{["url"]:"https://s3express-control.{Region}.amazonaws.com",["properties"]:x,["headers"]:d},["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[zs,{["fn"]:"substring",["argv"]:[Q,49,50,!0],["assign"]:"hardwareType"},{["fn"]:"substring",["argv"]:[Q,8,12,!0],["assign"]:"regionPrefix"},{["fn"]:"substring",["argv"]:[Q,0,7,!0],["assign"]:"bucketAliasSuffix"},{["fn"]:"substring",["argv"]:[Q,32,49,!0],["assign"]:"outpostId"},{["fn"]:"aws.partition",["argv"]:be,["assign"]:"regionPartition"},{["fn"]:"stringEquals",["argv"]:[{["ref"]:"bucketAliasSuffix"},"--op-s3"]}],rules:[{["conditions"]:qa,rules:[{["conditions"]:[{["fn"]:"stringEquals",["argv"]:[Sa,"e"]}],rules:[{["conditions"]:ja,rules:[Ea,{["conditions"]:lr,endpoint:{["url"]:"https://{Bucket}.ec2.{url#authority}",["properties"]:Cs,["headers"]:d},["type"]:"endpoint"}],["type"]:"tree"},{endpoint:{["url"]:"https://{Bucket}.ec2.s3-outposts.{Region}.{regionPartition#dnsSuffix}",["properties"]:Cs,["headers"]:d},["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[{["fn"]:"stringEquals",["argv"]:[Sa,"o"]}],rules:[{["conditions"]:ja,rules:[Ea,{["conditions"]:lr,endpoint:{["url"]:"https://{Bucket}.op-{outpostId}.{url#authority}",["properties"]:Cs,["headers"]:d},["type"]:"endpoint"}],["type"]:"tree"},{endpoint:{["url"]:"https://{Bucket}.op-{outpostId}.s3-outposts.{Region}.{regionPartition#dnsSuffix}",["properties"]:Cs,["headers"]:d},["type"]:"endpoint"}],["type"]:"tree"},{error:"Unrecognized hardware type: \"Expected hardware type o or e but got {hardwareType}\"",["type"]:"error"}],["type"]:"tree"},{error:"Invalid ARN: The outpost Id must only contain a-z, A-Z, 0-9 and `-`.",["type"]:"error"}],["type"]:"tree"},{["conditions"]:Cw,rules:[{["conditions"]:[C,{["fn"]:"not",["argv"]:[{["fn"]:"isSet",["argv"]:[{["fn"]:"parseURL",["argv"]:Tw}]}]}],error:"Custom endpoint `{Endpoint}` was not a valid URI",["type"]:"error"},{["conditions"]:[We,sh],rules:[{["conditions"]:n,rules:[{["conditions"]:ia,rules:[{["conditions"]:[_,ga],error:"S3 Accelerate cannot be used in this region",["type"]:"error"},{["conditions"]:[D,$,M,A,v],endpoint:{["url"]:"https://{Bucket}.s3-fips.dualstack.us-east-1.{partitionResult#dnsSuffix}",["properties"]:z,["headers"]:d},["type"]:"endpoint"},{["conditions"]:[D,$,M,A,c,F],rules:[{endpoint:ca,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[D,$,M,A,c,K],endpoint:ca,["type"]:"endpoint"},{["conditions"]:[S,$,M,A,v],endpoint:{["url"]:"https://{Bucket}.s3-fips.us-east-1.{partitionResult#dnsSuffix}",["properties"]:z,["headers"]:d},["type"]:"endpoint"},{["conditions"]:[S,$,M,A,c,F],rules:[{endpoint:Ia,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[S,$,M,A,c,K],endpoint:Ia,["type"]:"endpoint"},{["conditions"]:[D,R,_,A,v],endpoint:{["url"]:"https://{Bucket}.s3-accelerate.dualstack.us-east-1.{partitionResult#dnsSuffix}",["properties"]:z,["headers"]:d},["type"]:"endpoint"},{["conditions"]:[D,R,_,A,c,F],rules:[{endpoint:Pa,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[D,R,_,A,c,K],endpoint:Pa,["type"]:"endpoint"},{["conditions"]:[D,R,M,A,v],endpoint:{["url"]:"https://{Bucket}.s3.dualstack.us-east-1.{partitionResult#dnsSuffix}",["properties"]:z,["headers"]:d},["type"]:"endpoint"},{["conditions"]:[D,R,M,A,c,F],rules:[{endpoint:ka,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[D,R,M,A,c,K],endpoint:ka,["type"]:"endpoint"},{["conditions"]:[S,R,M,C,W,Gs,v],endpoint:{["url"]:"{url#scheme}://{url#authority}{url#normalizedPath}{Bucket}",["properties"]:z,["headers"]:d},["type"]:"endpoint"},{["conditions"]:[S,R,M,C,W,Qe,v],endpoint:{["url"]:"{url#scheme}://{Bucket}.{url#authority}{url#path}",["properties"]:z,["headers"]:d},["type"]:"endpoint"},{["conditions"]:[S,R,M,C,W,Gs,c,F],rules:[{["conditions"]:p,endpoint:Xe,["type"]:"endpoint"},{endpoint:Xe,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[S,R,M,C,W,Qe,c,F],rules:[{["conditions"]:p,endpoint:ef,["type"]:"endpoint"},Na],["type"]:"tree"},{["conditions"]:[S,R,M,C,W,Gs,c,K],endpoint:Xe,["type"]:"endpoint"},{["conditions"]:[S,R,M,C,W,Qe,c,K],endpoint:ef,["type"]:"endpoint"},{["conditions"]:[S,R,_,A,v],endpoint:{["url"]:"https://{Bucket}.s3-accelerate.{partitionResult#dnsSuffix}",["properties"]:z,["headers"]:d},["type"]:"endpoint"},{["conditions"]:[S,R,_,A,c,F],rules:[{["conditions"]:p,endpoint:Ze,["type"]:"endpoint"},{endpoint:Ze,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[S,R,_,A,c,K],endpoint:Ze,["type"]:"endpoint"},{["conditions"]:[S,R,M,A,v],endpoint:{["url"]:"https://{Bucket}.s3.{partitionResult#dnsSuffix}",["properties"]:z,["headers"]:d},["type"]:"endpoint"},{["conditions"]:[S,R,M,A,c,F],rules:[{["conditions"]:p,endpoint:{["url"]:"https://{Bucket}.s3.{partitionResult#dnsSuffix}",["properties"]:H,["headers"]:d},["type"]:"endpoint"},{endpoint:Da,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[S,R,M,A,c,K],endpoint:Da,["type"]:"endpoint"}],["type"]:"tree"},Hs],["type"]:"tree"}],["type"]:"tree"},{["conditions"]:[C,W,{["fn"]:"stringEquals",["argv"]:[{["fn"]:"getAttr",["argv"]:[ta,"scheme"]},"http"]},{["fn"]:"aws.isVirtualHostableS3Bucket",["argv"]:[Q,!0]},We,R,S,M],rules:[{["conditions"]:n,rules:[{["conditions"]:ia,rules:[Na],["type"]:"tree"},Hs],["type"]:"tree"}],["type"]:"tree"},{["conditions"]:[We,{["fn"]:"aws.parseArn",["argv"]:Mw,["assign"]:"bucketArn"}],rules:[{["conditions"]:[{["fn"]:"getAttr",["argv"]:[J,"resourceId[0]"],["assign"]:"arnType"},{["fn"]:"not",["argv"]:[{["fn"]:"stringEquals",["argv"]:[eh,""]}]}],rules:[{["conditions"]:[{["fn"]:"stringEquals",["argv"]:[Ve,"s3-object-lambda"]}],rules:[{["conditions"]:pe,rules:[{["conditions"]:ba,rules:[$a,ya,{["conditions"]:ue,rules:[Ua,{["conditions"]:xa,rules:[Je,{["conditions"]:te,rules:[{["conditions"]:n,rules:[{["conditions"]:oa,rules:[{["conditions"]:rf,rules:[{["conditions"]:[{["fn"]:"stringEquals",["argv"]:[lh,""]}],error:"Invalid ARN: Missing account id",["type"]:"error"},{["conditions"]:sf,rules:[{["conditions"]:na,rules:[{["conditions"]:lr,endpoint:{["url"]:"{url#scheme}://{accessPointName}-{bucketArn#accountId}.{url#authority}{url#path}",["properties"]:Be,["headers"]:d},["type"]:"endpoint"},{["conditions"]:kr,endpoint:{["url"]:"https://{accessPointName}-{bucketArn#accountId}.s3-object-lambda-fips.{bucketArn#region}.{bucketPartition#dnsSuffix}",["properties"]:Be,["headers"]:d},["type"]:"endpoint"},{endpoint:{["url"]:"https://{accessPointName}-{bucketArn#accountId}.s3-object-lambda.{bucketArn#region}.{bucketPartition#dnsSuffix}",["properties"]:Be,["headers"]:d},["type"]:"endpoint"}],["type"]:"tree"},Ta],["type"]:"tree"},Ye],["type"]:"tree"},Oe],["type"]:"tree"},_e],["type"]:"tree"}],["type"]:"tree"}],["type"]:"tree"},Ma],["type"]:"tree"},{error:"Invalid ARN: bucket ARN is missing a region",["type"]:"error"}],["type"]:"tree"},Ca],["type"]:"tree"},{error:"Invalid ARN: Object Lambda ARNs only support `accesspoint` arn types, but found: `{arnType}`",["type"]:"error"}],["type"]:"tree"},{["conditions"]:pe,rules:[{["conditions"]:ba,rules:[{["conditions"]:ue,rules:[{["conditions"]:pe,rules:[{["conditions"]:ue,rules:[Ua,{["conditions"]:xa,rules:[Je,{["conditions"]:te,rules:[{["conditions"]:n,rules:[{["conditions"]:[{["fn"]:"stringEquals",["argv"]:[fh,"{partitionResult#name}"]}],rules:[{["conditions"]:rf,rules:[{["conditions"]:[{["fn"]:"stringEquals",["argv"]:[Ve,"s3"]}],rules:[{["conditions"]:sf,rules:[{["conditions"]:na,rules:[{["conditions"]:vs,error:"Access Points do not support S3 Accelerate",["type"]:"error"},{["conditions"]:[$,D],endpoint:{["url"]:"https://{accessPointName}-{bucketArn#accountId}.s3-accesspoint-fips.dualstack.{bucketArn#region}.{bucketPartition#dnsSuffix}",["properties"]:Or,["headers"]:d},["type"]:"endpoint"},{["conditions"]:[$,S],endpoint:{["url"]:"https://{accessPointName}-{bucketArn#accountId}.s3-accesspoint-fips.{bucketArn#region}.{bucketPartition#dnsSuffix}",["properties"]:Or,["headers"]:d},["type"]:"endpoint"},{["conditions"]:[R,D],endpoint:{["url"]:"https://{accessPointName}-{bucketArn#accountId}.s3-accesspoint.dualstack.{bucketArn#region}.{bucketPartition#dnsSuffix}",["properties"]:Or,["headers"]:d},["type"]:"endpoint"},{["conditions"]:[R,S,C,W],endpoint:{["url"]:"{url#scheme}://{accessPointName}-{bucketArn#accountId}.{url#authority}{url#path}",["properties"]:Or,["headers"]:d},["type"]:"endpoint"},{["conditions"]:[R,S],endpoint:{["url"]:"https://{accessPointName}-{bucketArn#accountId}.s3-accesspoint.{bucketArn#region}.{bucketPartition#dnsSuffix}",["properties"]:Or,["headers"]:d},["type"]:"endpoint"}],["type"]:"tree"},Ta],["type"]:"tree"},Ye],["type"]:"tree"},{error:"Invalid ARN: The ARN was not for the S3 service, found: {bucketArn#service}",["type"]:"error"}],["type"]:"tree"},Oe],["type"]:"tree"},_e],["type"]:"tree"}],["type"]:"tree"}],["type"]:"tree"},Ma],["type"]:"tree"}],["type"]:"tree"}],["type"]:"tree"},{["conditions"]:[{["fn"]:"isValidHostLabel",["argv"]:[ff,!0]}],rules:[{["conditions"]:xe,error:"S3 MRAP does not support dual-stack",["type"]:"error"},{["conditions"]:kr,error:"S3 MRAP does not support FIPS",["type"]:"error"},{["conditions"]:vs,error:"S3 MRAP does not support S3 Accelerate",["type"]:"error"},{["conditions"]:[{["fn"]:"booleanEquals",["argv"]:[{["ref"]:"DisableMultiRegionAccessPoints"},!0]}],error:"Invalid configuration: Multi-Region Access Point ARNs are disabled.",["type"]:"error"},{["conditions"]:[{["fn"]:"aws.partition",["argv"]:be,["assign"]:"mrapPartition"}],rules:[{["conditions"]:[{["fn"]:"stringEquals",["argv"]:[{["fn"]:"getAttr",["argv"]:[{["ref"]:"mrapPartition"},"name"]},{["fn"]:"getAttr",["argv"]:[J,"partition"]}]}],rules:[{endpoint:{["url"]:"https://{accessPointName}.accesspoint.s3-global.{mrapPartition#dnsSuffix}",["properties"]:{["authSchemes"]:[{["disableDoubleEncoding"]:!0,name:"sigv4a",["signingName"]:"s3",["signingRegionSet"]:Hw}]},["headers"]:d},["type"]:"endpoint"}],["type"]:"tree"},{error:"Client was configured for partition `{mrapPartition#name}` but bucket referred to partition `{bucketArn#partition}`",["type"]:"error"}],["type"]:"tree"}],["type"]:"tree"},{error:"Invalid Access Point Name",["type"]:"error"}],["type"]:"tree"},Ca],["type"]:"tree"},{["conditions"]:[{["fn"]:"stringEquals",["argv"]:[Ve,"s3-outposts"]}],rules:[{["conditions"]:xe,error:"S3 Outposts does not support Dual-stack",["type"]:"error"},{["conditions"]:kr,error:"S3 Outposts does not support FIPS",["type"]:"error"},{["conditions"]:vs,error:"S3 Outposts does not support S3 Accelerate",["type"]:"error"},{["conditions"]:[{["fn"]:"isSet",["argv"]:[{["fn"]:"getAttr",["argv"]:[J,"resourceId[4]"]}]}],error:"Invalid Arn: Outpost Access Point ARN contains sub resources",["type"]:"error"},{["conditions"]:[{["fn"]:"getAttr",["argv"]:vw,["assign"]:"outpostId"}],rules:[{["conditions"]:qa,rules:[Je,{["conditions"]:te,rules:[{["conditions"]:n,rules:[{["conditions"]:oa,rules:[{["conditions"]:rf,rules:[{["conditions"]:sf,rules:[{["conditions"]:[{["fn"]:"getAttr",["argv"]:Gw,["assign"]:"outpostType"}],rules:[{["conditions"]:[{["fn"]:"getAttr",["argv"]:[J,"resourceId[3]"],["assign"]:"accessPointName"}],rules:[{["conditions"]:[{["fn"]:"stringEquals",["argv"]:[{["ref"]:"outpostType"},"accesspoint"]}],rules:[{["conditions"]:lr,endpoint:{["url"]:"https://{accessPointName}-{bucketArn#accountId}.{outpostId}.{url#authority}",["properties"]:Ha,["headers"]:d},["type"]:"endpoint"},{endpoint:{["url"]:"https://{accessPointName}-{bucketArn#accountId}.{outpostId}.s3-outposts.{bucketArn#region}.{bucketPartition#dnsSuffix}",["properties"]:Ha,["headers"]:d},["type"]:"endpoint"}],["type"]:"tree"},{error:"Expected an outpost type `accesspoint`, found {outpostType}",["type"]:"error"}],["type"]:"tree"},{error:"Invalid ARN: expected an access point name",["type"]:"error"}],["type"]:"tree"},{error:"Invalid ARN: Expected a 4-component resource",["type"]:"error"}],["type"]:"tree"},Ye],["type"]:"tree"},Oe],["type"]:"tree"},_e],["type"]:"tree"}],["type"]:"tree"}],["type"]:"tree"},{error:"Invalid ARN: The outpost Id may only contain a-z, A-Z, 0-9 and `-`. Found: `{outpostId}`",["type"]:"error"}],["type"]:"tree"},{error:"Invalid ARN: The Outpost Id was not set",["type"]:"error"}],["type"]:"tree"},{error:"Invalid ARN: Unrecognized format: {Bucket} (type: {arnType})",["type"]:"error"}],["type"]:"tree"},{error:"Invalid ARN: No ARN type specified",["type"]:"error"}],["type"]:"tree"},{["conditions"]:[{["fn"]:"substring",["argv"]:[Q,0,4,!1],["assign"]:"arnPrefix"},{["fn"]:"stringEquals",["argv"]:[{["ref"]:"arnPrefix"},"arn:"]},{["fn"]:"not",["argv"]:[{["fn"]:"isSet",["argv"]:[va]}]}],error:"Invalid ARN: `{Bucket}` was not a valid ARN",["type"]:"error"},{["conditions"]:[{["fn"]:"booleanEquals",["argv"]:[Uw,!0]},va],error:"Path-style addressing cannot be used with ARN buckets",["type"]:"error"},{["conditions"]:oe,rules:[{["conditions"]:n,rules:[{["conditions"]:[M],rules:[{["conditions"]:[D,A,$,v],endpoint:{["url"]:"https://s3-fips.dualstack.us-east-1.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",["properties"]:z,["headers"]:d},["type"]:"endpoint"},{["conditions"]:[D,A,$,c,F],rules:[{endpoint:Ga,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[D,A,$,c,K],endpoint:Ga,["type"]:"endpoint"},{["conditions"]:[S,A,$,v],endpoint:{["url"]:"https://s3-fips.us-east-1.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",["properties"]:z,["headers"]:d},["type"]:"endpoint"},{["conditions"]:[S,A,$,c,F],rules:[{endpoint:za,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[S,A,$,c,K],endpoint:za,["type"]:"endpoint"},{["conditions"]:[D,A,R,v],endpoint:{["url"]:"https://s3.dualstack.us-east-1.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",["properties"]:z,["headers"]:d},["type"]:"endpoint"},{["conditions"]:[D,A,R,c,F],rules:[{endpoint:Fa,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[D,A,R,c,K],endpoint:Fa,["type"]:"endpoint"},{["conditions"]:[S,C,W,R,v],endpoint:{["url"]:"{url#scheme}://{url#authority}{url#normalizedPath}{uri_encoded_bucket}",["properties"]:z,["headers"]:d},["type"]:"endpoint"},{["conditions"]:[S,C,W,R,c,F],rules:[{["conditions"]:p,endpoint:qe,["type"]:"endpoint"},{endpoint:qe,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[S,C,W,R,c,K],endpoint:qe,["type"]:"endpoint"},{["conditions"]:[S,A,R,v],endpoint:{["url"]:"https://s3.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",["properties"]:z,["headers"]:d},["type"]:"endpoint"},{["conditions"]:[S,A,R,c,F],rules:[{["conditions"]:p,endpoint:{["url"]:"https://s3.{partitionResult#dnsSuffix}/{uri_encoded_bucket}",["properties"]:H,["headers"]:d},["type"]:"endpoint"},{endpoint:Ka,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[S,A,R,c,K],endpoint:Ka,["type"]:"endpoint"}],["type"]:"tree"},{error:"Path-style addressing cannot be used with S3 Accelerate",["type"]:"error"}],["type"]:"tree"}],["type"]:"tree"}],["type"]:"tree"},{["conditions"]:[{["fn"]:"isSet",["argv"]:[La]},{["fn"]:"booleanEquals",["argv"]:[La,!0]}],rules:[{["conditions"]:n,rules:[{["conditions"]:pa,rules:[$a,ya,{["conditions"]:lr,endpoint:{["url"]:"{url#scheme}://{url#authority}{url#path}",["properties"]:je,["headers"]:d},["type"]:"endpoint"},{["conditions"]:kr,endpoint:{["url"]:"https://s3-object-lambda-fips.{Region}.{partitionResult#dnsSuffix}",["properties"]:je,["headers"]:d},["type"]:"endpoint"},{endpoint:{["url"]:"https://s3-object-lambda.{Region}.{partitionResult#dnsSuffix}",["properties"]:je,["headers"]:d},["type"]:"endpoint"}],["type"]:"tree"},Hs],["type"]:"tree"}],["type"]:"tree"},{["conditions"]:[Ra],rules:[{["conditions"]:n,rules:[{["conditions"]:pa,rules:[{["conditions"]:[$,D,A,v],endpoint:{["url"]:"https://s3-fips.dualstack.us-east-1.{partitionResult#dnsSuffix}",["properties"]:z,["headers"]:d},["type"]:"endpoint"},{["conditions"]:[$,D,A,c,F],rules:[{endpoint:Wa,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[$,D,A,c,K],endpoint:Wa,["type"]:"endpoint"},{["conditions"]:[$,S,A,v],endpoint:{["url"]:"https://s3-fips.us-east-1.{partitionResult#dnsSuffix}",["properties"]:z,["headers"]:d},["type"]:"endpoint"},{["conditions"]:[$,S,A,c,F],rules:[{endpoint:Qa,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[$,S,A,c,K],endpoint:Qa,["type"]:"endpoint"},{["conditions"]:[R,D,A,v],endpoint:{["url"]:"https://s3.dualstack.us-east-1.{partitionResult#dnsSuffix}",["properties"]:z,["headers"]:d},["type"]:"endpoint"},{["conditions"]:[R,D,A,c,F],rules:[{endpoint:Xa,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[R,D,A,c,K],endpoint:Xa,["type"]:"endpoint"},{["conditions"]:[R,S,C,W,v],endpoint:{["url"]:"{url#scheme}://{url#authority}{url#path}",["properties"]:z,["headers"]:d},["type"]:"endpoint"},{["conditions"]:[R,S,C,W,c,F],rules:[{["conditions"]:p,endpoint:ie,["type"]:"endpoint"},{endpoint:ie,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[R,S,C,W,c,K],endpoint:ie,["type"]:"endpoint"},{["conditions"]:[R,S,A,v],endpoint:{["url"]:"https://s3.{partitionResult#dnsSuffix}",["properties"]:z,["headers"]:d},["type"]:"endpoint"},{["conditions"]:[R,S,A,c,F],rules:[{["conditions"]:p,endpoint:{["url"]:"https://s3.{partitionResult#dnsSuffix}",["properties"]:H,["headers"]:d},["type"]:"endpoint"},{endpoint:Za,["type"]:"endpoint"}],["type"]:"tree"},{["conditions"]:[R,S,A,c,K],endpoint:Za,["type"]:"endpoint"}],["type"]:"tree"},Hs],["type"]:"tree"}],["type"]:"tree"}],["type"]:"tree"},{error:"A region must be set when sending requests to S3.",["type"]:"error"}]},ah=zw;var Fw=new hh({size:50,params:["Accelerate","Bucket","DisableAccessPoints","DisableMultiRegionAccessPoints","DisableS3ExpressSessionAuth","Endpoint","ForcePathStyle","Region","UseArnRegion","UseDualStack","UseFIPS","UseGlobalEndpoint","UseObjectLambdaEndpoint","UseS3ExpressControlEndpoint"]}),Ks=(r,s={})=>{return Fw.get(r,()=>gh(ah,{endpointParams:r,logger:s.logger}))};mh.aws=wh;function Rh(r){return{schemeId:"aws.auth#sigv4",signingProperties:{name:"s3",region:r.region},propertiesExtractor:(s,e)=>({signingProperties:{config:s,context:e}})}}function Sh(r){return{schemeId:"aws.auth#sigv4a",signingProperties:{name:"s3",region:r.region},propertiesExtractor:(s,e)=>({signingProperties:{config:s,context:e}})}}var Kw=(r)=>async(s,e,f)=>{if(!f)throw new Error("Could not find \`input\` for \`defaultEndpointRuleSetHttpAuthSchemeParametersProvider\`");const l=await r(s,e,f),a=_r.getSmithyContext(e)?.commandInstance?.constructor?.getEndpointParameterInstructions;if(!a)throw new Error(`getEndpointParameterInstructions() is not defined on \`${e.commandName}\``);const h=await dh(f,{getEndpointParameterInstructions:a},s);return Object.assign(l,h)},Lw=async(r,s,e)=>{return{operation:_r.getSmithyContext(s).operation,region:await _r.normalizeProvider(r.region)()||(()=>{throw new Error("expected `region` to be configured for `aws.auth#sigv4`")})()}},Ah=Kw(Lw),Ww=(r,s,e)=>{return(l)=>{const h=r(l).properties?.authSchemes;if(!h)return s(l);const m=[];for(let g of h){const{name:w,properties:E={},...I}=g,P=w.toLowerCase();if(w!==P)console.warn(`HttpAuthScheme has been normalized with lowercasing: \`${w}\` to \`${P}\``);let N;if(P==="sigv4a"){N="aws.auth#sigv4a";const tr=h.find((b)=>{const vr=b.name.toLowerCase();return vr!=="sigv4a"&&vr.startsWith("sigv4")});if(!Ms.CrtSignerV4&&tr)continue}else if(P.startsWith("sigv4"))N="aws.auth#sigv4";else throw new Error(`Unknown HttpAuthScheme found in \`@smithy.rules#endpointRuleSet\`: \`${P}\``);const y=e[N];if(!y)throw new Error(`Could not find HttpAuthOption create function for \`${N}\``);const V=y(l);V.schemeId=N,V.signingProperties={...V.signingProperties||{},...I,...E},m.push(V)}return m}},Qw=(r)=>{const s=[];switch(r.operation){default:s.push(Rh(r)),s.push(Sh(r))}return s},Eh=Ww(Ks,Qw,{"aws.auth#sigv4":Rh,"aws.auth#sigv4a":Sh}),ch=(r)=>{const s=Ws.resolveAwsSdkSigV4Config(r);return{...Ws.resolveAwsSdkSigV4AConfig(s)}};var Ih=(r)=>{return{...r,useFipsEndpoint:r.useFipsEndpoint??!1,useDualstackEndpoint:r.useDualstackEndpoint??!1,forcePathStyle:r.forcePathStyle??!1,useAccelerateEndpoint:r.useAccelerateEndpoint??!1,useGlobalEndpoint:r.useGlobalEndpoint??!1,disableMultiregionAccessPoints:r.disableMultiregionAccessPoints??!1,defaultSigningName:"s3"}},Nr={ForcePathStyle:{type:"clientContextParams",name:"forcePathStyle"},UseArnRegion:{type:"clientContextParams",name:"useArnRegion"},DisableMultiRegionAccessPoints:{type:"clientContextParams",name:"disableMultiregionAccessPoints"},Accelerate:{type:"clientContextParams",name:"useAccelerateEndpoint"},DisableS3ExpressSessionAuth:{type:"clientContextParams",name:"disableS3ExpressSessionAuth"},UseGlobalEndpoint:{type:"builtInParams",name:"useGlobalEndpoint"},UseFIPS:{type:"builtInParams",name:"useFipsEndpoint"},Endpoint:{type:"builtInParams",name:"endpoint"},Region:{type:"builtInParams",name:"region"},UseDualStack:{type:"builtInParams",name:"useDualstackEndpoint"}};class X extends Ph{constructor(r){super(r);Object.setPrototypeOf(this,X.prototype)}}class Qs extends X{constructor(r){super({name:"NoSuchUpload",$fault:"client",...r});this.name="NoSuchUpload",this.$fault="client",Object.setPrototypeOf(this,Qs.prototype)}}class Xs extends X{constructor(r){super({name:"ObjectNotInActiveTierError",$fault:"client",...r});this.name="ObjectNotInActiveTierError",this.$fault="client",Object.setPrototypeOf(this,Xs.prototype)}}class Zs extends X{constructor(r){super({name:"BucketAlreadyExists",$fault:"client",...r});this.name="BucketAlreadyExists",this.$fault="client",Object.setPrototypeOf(this,Zs.prototype)}}class Vs extends X{constructor(r){super({name:"BucketAlreadyOwnedByYou",$fault:"client",...r});this.name="BucketAlreadyOwnedByYou",this.$fault="client",Object.setPrototypeOf(this,Vs.prototype)}}class Js extends X{constructor(r){super({name:"NoSuchBucket",$fault:"client",...r});this.name="NoSuchBucket",this.$fault="client",Object.setPrototypeOf(this,Js.prototype)}}var lf;(function(r){r.visit=(s,e)=>{if(s.Prefix!==void 0)return e.Prefix(s.Prefix);if(s.Tag!==void 0)return e.Tag(s.Tag);if(s.And!==void 0)return e.And(s.And);return e._(s.$unknown[0],s.$unknown[1])}})(lf||(lf={}));var af;(function(r){r.visit=(s,e)=>{if(s.Prefix!==void 0)return e.Prefix(s.Prefix);if(s.Tag!==void 0)return e.Tag(s.Tag);if(s.ObjectSizeGreaterThan!==void 0)return e.ObjectSizeGreaterThan(s.ObjectSizeGreaterThan);if(s.ObjectSizeLessThan!==void 0)return e.ObjectSizeLessThan(s.ObjectSizeLessThan);if(s.And!==void 0)return e.And(s.And);return e._(s.$unknown[0],s.$unknown[1])}})(af||(af={}));var hf;(function(r){r.visit=(s,e)=>{if(s.Prefix!==void 0)return e.Prefix(s.Prefix);if(s.Tag!==void 0)return e.Tag(s.Tag);if(s.AccessPointArn!==void 0)return e.AccessPointArn(s.AccessPointArn);if(s.And!==void 0)return e.And(s.And);return e._(s.$unknown[0],s.$unknown[1])}})(hf||(hf={}));var mf;(function(r){r.visit=(s,e)=>{if(s.Prefix!==void 0)return e.Prefix(s.Prefix);if(s.Tag!==void 0)return e.Tag(s.Tag);if(s.And!==void 0)return e.And(s.And);return e._(s.$unknown[0],s.$unknown[1])}})(mf||(mf={}));class Bs extends X{constructor(r){super({name:"InvalidObjectState",$fault:"client",...r});this.name="InvalidObjectState",this.$fault="client",Object.setPrototypeOf(this,Bs.prototype),this.StorageClass=r.StorageClass,this.AccessTier=r.AccessTier}}class Ys extends X{constructor(r){super({name:"NoSuchKey",$fault:"client",...r});this.name="NoSuchKey",this.$fault="client",Object.setPrototypeOf(this,Ys.prototype)}}class Os extends X{constructor(r){super({name:"NotFound",$fault:"client",...r});this.name="NotFound",this.$fault="client",Object.setPrototypeOf(this,Os.prototype)}}var Xw=(r)=>({...r,...r.SecretAccessKey&&{SecretAccessKey:Z},...r.SessionToken&&{SessionToken:Z}}),kh=(r)=>({...r,...r.SSEKMSKeyId&&{SSEKMSKeyId:Z},...r.SSEKMSEncryptionContext&&{SSEKMSEncryptionContext:Z},...r.Credentials&&{Credentials:Xw(r.Credentials)}}),Nh=(r)=>({...r,...r.SSEKMSKeyId&&{SSEKMSKeyId:Z},...r.SSEKMSEncryptionContext&&{SSEKMSEncryptionContext:Z}});var Dh=(r)=>({...r,...r.SSEKMSKeyId&&{SSEKMSKeyId:Z}}),$h=(r)=>({...r,...r.SSECustomerKey&&{SSECustomerKey:Z}});var yr=T(Ls(),1);var js=T(Ge(),1);class _s extends X{constructor(r){super({name:"ObjectAlreadyInActiveTierError",$fault:"client",...r});this.name="ObjectAlreadyInActiveTierError",this.$fault="client",Object.setPrototypeOf(this,_s.prototype)}}var yh;(function(r){r.visit=(s,e)=>{if(s.Records!==void 0)return e.Records(s.Records);if(s.Stats!==void 0)return e.Stats(s.Stats);if(s.Progress!==void 0)return e.Progress(s.Progress);if(s.Cont!==void 0)return e.Cont(s.Cont);if(s.End!==void 0)return e.End(s.End);return e._(s.$unknown[0],s.$unknown[1])}})(yh||(yh={}));var Uh=(r)=>({...r,...r.SSEKMSKeyId&&{SSEKMSKeyId:Z},...r.SSEKMSEncryptionContext&&{SSEKMSEncryptionContext:Z}}),Th=(r)=>({...r,...r.SSECustomerKey&&{SSECustomerKey:Z},...r.SSEKMSKeyId&&{SSEKMSKeyId:Z},...r.SSEKMSEncryptionContext&&{SSEKMSEncryptionContext:Z}});var Zh=async(r,s)=>{const e=js.requestBuilder(r,s),f=G({},j,{[_d]:r[$d],[nr]:r[xr],[pr]:r[or],[os]:r[xs],[u]:[()=>j(r[ar]),()=>r[ar].toString()]});e.bp("/"),e.p("Bucket",()=>r.Bucket,"{Bucket}",!1);const l=G({[Jd]:[,""]});let a;return e.m("GET").h(f).q(l).b(a),e.build()};var Vh=async(r,s)=>{const e=js.requestBuilder(r,s),f=G({},j,{[vd]:r[md],[Gd]:[()=>j(r[Mh]),()=>qr(r[Mh]).toString()],[wm]:r[nh],[zd]:[()=>j(r[Ch]),()=>qr(r[Ch]).toString()],[Kd]:r[Rd],[ns]:r[is],[Pm]:r[sm],[ps]:r[bs],[cm]:r[rm],[Am]:r[xh],[Od]:r[uw]});e.bp("/{Key+}"),e.p("Bucket",()=>r.Bucket,"{Bucket}",!1),e.p("Key",()=>r.Key,"{Key+}",!0);const l=G({[Dm]:[,"GetObject"],[Ld]:[,r[Sd]],[Wd]:[,r[Ed]],[Qd]:[,r[cd]],[Xd]:[,r[Id]],[Zd]:[,r[Pd]],[Vd]:[()=>r.ResponseExpires!==void 0,()=>qr(r[kd]).toString()],[Bd]:[,r[Mf]],[Fd]:[()=>r.PartNumber!==void 0,()=>r[Ad].toString()]});let a;return e.m("GET").h(f).q(l).b(a),e.build()};var Jh=async(r,s)=>{const e=js.requestBuilder(r,s),f=G({},j,{[mm]:r[bh]||"application/octet-stream",[Yd]:r[ow],[fm]:r[_h],[lm]:r[qh],[am]:r[jh],[hm]:r[ih],[If]:[()=>j(r[Sf]),()=>r[Sf].toString()],[Md]:r[tw],[nd]:r[pw],[Cf]:r[$f],[Hf]:r[yf],[vf]:r[Uf],[Gf]:r[Tf],[Pf]:[()=>j(r[Ef]),()=>qr(r[Ef]).toString()],[wm]:r[nh],[qd]:r[fd],[jd]:r[ld],[id]:r[ad],[bd]:r[hd],[nr]:r[xr],[Im]:r[ir],[Nm]:r[em],[ns]:r[is],[Pm]:r[sm],[ps]:r[bs],[pr]:r[or],[os]:r[xs],[u]:[()=>j(r[ar]),()=>r[ar].toString()],[cm]:r[rm],[pd]:r[yd],[Sm]:r[uh],[kf]:[()=>j(r[cf]),()=>Xh(r[cf]).toString()],[Rm]:r[ph],[Am]:r[xh],...r.Metadata!==void 0&&Object.keys(r.Metadata).reduce((m,g)=>{return m[`x-amz-meta-${g.toLowerCase()}`]=r.Metadata[g],m},{})});e.bp("/{Key+}"),e.p("Bucket",()=>r.Bucket,"{Bucket}",!1),e.p("Key",()=>r.Key,"{Key+}",!0);const l=G({[Dm]:[,"PutObject"]});let a,h;if(r.Body!==void 0)h=r.Body,a=h;return e.m("PUT").h(f).q(l).b(a),e.build()};var Bh=async(r,s)=>{if(r.statusCode!==200&&r.statusCode>=300)return Df(r,s);const e=G({$metadata:O(r),[xr]:[,r.headers[nr]],[or]:[,r.headers[pr]],[xs]:[,r.headers[os]],[ar]:[()=>r.headers[u]!==void 0,()=>br(r.headers[u])]}),f=Dr(Lh(await yr.parseXmlBody(r.body,s)),"body");if(f[df]!=null)e[df]=xw(f[df],s);return e};var Yh=async(r,s)=>{if(r.statusCode!==200&&r.statusCode>=300)return Df(r,s);const e=G({$metadata:O(r),[sd]:[()=>r.headers[vh]!==void 0,()=>br(r.headers[vh])],[nw]:[,r.headers[Td]],[jr]:[,r.headers[dm]],[Dd]:[,r.headers[xd]],[gd]:[()=>r.headers[Hh]!==void 0,()=>Dr(Qr(r.headers[Hh]))],[Sf]:[()=>r.headers[If]!==void 0,()=>Wh(r.headers[If])],[oh]:[,r.headers[gm]],[$f]:[,r.headers[Cf]],[yf]:[,r.headers[Hf]],[Uf]:[,r.headers[vf]],[Tf]:[,r.headers[Gf]],[wd]:[()=>r.headers[Gh]!==void 0,()=>qs(r.headers[Gh])],[Mf]:[,r.headers[km]],[_h]:[,r.headers[fm]],[qh]:[,r.headers[lm]],[jh]:[,r.headers[am]],[ih]:[,r.headers[hm]],[rd]:[,r.headers[Cd]],[bh]:[,r.headers[mm]],[Ef]:[()=>r.headers[Pf]!==void 0,()=>Dr(Qr(r.headers[Pf]))],[ed]:[,r.headers[Hd]],[em]:[,r.headers[Nm]],[xr]:[,r.headers[nr]],[is]:[,r.headers[ns]],[bs]:[,r.headers[ps]],[or]:[,r.headers[pr]],[ar]:[()=>r.headers[u]!==void 0,()=>br(r.headers[u])],[ir]:[,r.headers[Im]],[th]:[,r.headers[Em]],[Nd]:[,r.headers[od]],[dd]:[()=>r.headers[zh]!==void 0,()=>qs(r.headers[zh])],[Ud]:[()=>r.headers[Fh]!==void 0,()=>qs(r.headers[Fh])],[uh]:[,r.headers[Sm]],[cf]:[()=>r.headers[kf]!==void 0,()=>Dr(Nf(r.headers[kf]))],[ph]:[,r.headers[Rm]],Metadata:[,Object.keys(r.headers).filter((l)=>l.startsWith("x-amz-meta-")).reduce((l,a)=>{return l[a.substring(11)]=r.headers[a],l},{})]}),f=r.body;return s.sdkStreamMixin(f),e.Body=f,e};var Oh=async(r,s)=>{if(r.statusCode!==200&&r.statusCode>=300)return Df(r,s);const e=G({$metadata:O(r),[jr]:[,r.headers[dm]],[oh]:[,r.headers[gm]],[$f]:[,r.headers[Cf]],[yf]:[,r.headers[Hf]],[Uf]:[,r.headers[vf]],[Tf]:[,r.headers[Gf]],[xr]:[,r.headers[nr]],[Mf]:[,r.headers[km]],[is]:[,r.headers[ns]],[bs]:[,r.headers[ps]],[or]:[,r.headers[pr]],[xs]:[,r.headers[os]],[ar]:[()=>r.headers[u]!==void 0,()=>br(r.headers[u])],[th]:[,r.headers[Em]]});return await Kh(r.body,s),e};var Df=async(r,s)=>{const e={...r,body:await yr.parseXmlErrorBody(r.body,s)},f=yr.loadRestXmlErrorCode(r,e.body);switch(f){case"NoSuchUpload":case"com.amazonaws.s3#NoSuchUpload":throw await qw(e,s);case"ObjectNotInActiveTierError":case"com.amazonaws.s3#ObjectNotInActiveTierError":throw await bw(e,s);case"BucketAlreadyExists":case"com.amazonaws.s3#BucketAlreadyExists":throw await Jw(e,s);case"BucketAlreadyOwnedByYou":case"com.amazonaws.s3#BucketAlreadyOwnedByYou":throw await Bw(e,s);case"NoSuchBucket":case"com.amazonaws.s3#NoSuchBucket":throw await Ow(e,s);case"InvalidObjectState":case"com.amazonaws.s3#InvalidObjectState":throw await Yw(e,s);case"NoSuchKey":case"com.amazonaws.s3#NoSuchKey":throw await _w(e,s);case"NotFound":case"com.amazonaws.s3#NotFound":throw await jw(e,s);case"ObjectAlreadyInActiveTierError":case"com.amazonaws.s3#ObjectAlreadyInActiveTierError":throw await iw(e,s);default:const l=e.body;return Vw({output:r,parsedBody:l,errorCode:f})}},Vw=Qh(X),Jw=async(r,s)=>{const e=G({}),f=r.body,l=new Zs({$metadata:O(r),...e});return i(l,r.body)},Bw=async(r,s)=>{const e=G({}),f=r.body,l=new Vs({$metadata:O(r),...e});return i(l,r.body)},Yw=async(r,s)=>{const e=G({}),f=r.body;if(f[wf]!=null)e[wf]=$r(f[wf]);if(f[ir]!=null)e[ir]=$r(f[ir]);const l=new Bs({$metadata:O(r),...e});return i(l,r.body)},Ow=async(r,s)=>{const e=G({}),f=r.body,l=new Js({$metadata:O(r),...e});return i(l,r.body)},_w=async(r,s)=>{const e=G({}),f=r.body,l=new Ys({$metadata:O(r),...e});return i(l,r.body)},qw=async(r,s)=>{const e=G({}),f=r.body,l=new Qs({$metadata:O(r),...e});return i(l,r.body)},jw=async(r,s)=>{const e=G({}),f=r.body,l=new Os({$metadata:O(r),...e});return i(l,r.body)},iw=async(r,s)=>{const e=G({}),f=r.body,l=new _s({$metadata:O(r),...e});return i(l,r.body)},bw=async(r,s)=>{const e=G({}),f=r.body,l=new Xs({$metadata:O(r),...e});return i(l,r.body)};var xw=(r,s)=>{const e={};if(r[gf]!=null)e[gf]=$r(r[gf]);if(r[Af]!=null)e[Af]=$r(r[Af]);if(r[Rf]!=null)e[Rf]=$r(r[Rf]);if(r[jr]!=null)e[jr]=Dr(Nf(r[jr]));return e};var O=(r)=>({httpStatusCode:r.statusCode,requestId:r.headers["x-amzn-requestid"]??r.headers["x-amzn-request-id"]??r.headers["x-amz-request-id"],extendedRequestId:r.headers["x-amz-id-2"],cfId:r.headers["x-amz-cf-id"]});var j=(r)=>r!==void 0&&r!==null&&r!==""&&(!Object.getOwnPropertyNames(r).includes("length")||r.length!=0)&&(!Object.getOwnPropertyNames(r).includes("size")||r.size!=0);var ow="ACL";var gf="AccessKeyId";var nw="AcceptRanges";var wf="AccessTier";var ar="BucketKeyEnabled";var df="Credentials",pw="ChecksumAlgorithm";var _h="CacheControl",$f="ChecksumCRC32",yf="ChecksumCRC32C",qh="ContentDisposition";var jh="ContentEncoding";var ih="ContentLanguage",Sf="ContentLength",uw="ChecksumMode",tw="ContentMD5";var rd="ContentRange";var Uf="ChecksumSHA1",Tf="ChecksumSHA256";var bh="ContentType";var sd="DeleteMarker";var Ef="Expires";var xh="ExpectedBucketOwner";var ed="ExpiresString";var oh="ETag";var jr="Expiration";var fd="GrantFullControl";var ld="GrantRead",ad="GrantReadACP";var hd="GrantWriteACP";var md="IfMatch",Mh="IfModifiedSince",nh="IfNoneMatch";var Ch="IfUnmodifiedSince";var gd="LastModified";var wd="MissingMeta";var ph="ObjectLockLegalHoldStatus",uh="ObjectLockMode";var cf="ObjectLockRetainUntilDate";var dd="PartsCount";var Ad="PartNumber";var Rd="Range";var th="RequestCharged",Sd="ResponseCacheControl",Ed="ResponseContentDisposition",cd="ResponseContentEncoding",Id="ResponseContentLanguage",Pd="ResponseContentType";var kd="ResponseExpires";var rm="RequestPayer";var Nd="ReplicationStatus";var Dd="Restore";var Af="SecretAccessKey";var ir="StorageClass";var $d="SessionMode";var xr="ServerSideEncryption";var is="SSECustomerAlgorithm",sm="SSECustomerKey",bs="SSECustomerKeyMD5";var xs="SSEKMSEncryptionContext",or="SSEKMSKeyId";var Rf="SessionToken";var yd="Tagging";var Ud="TagCount";var Mf="VersionId";var em="WebsiteRedirectLocation";var Td="accept-ranges";var fm="cache-control",lm="content-disposition",am="content-encoding",hm="content-language",If="content-length",Md="content-md5",Cd="content-range",mm="content-type";var Pf="expires";var gm="etag",Hd="expiresstring";var vd="if-match",Gd="if-modified-since";var wm="if-none-match";var zd="if-unmodified-since";var Hh="last-modified";var Fd="partNumber";var Kd="range",Ld="response-cache-control",Wd="response-content-disposition",Qd="response-content-encoding",Xd="response-content-language",Zd="response-content-type",Vd="response-expires";var Jd="session";var Bd="versionId";var Yd="x-amz-acl";var Cf="x-amz-checksum-crc32",Hf="x-amz-checksum-crc32c",Od="x-amz-checksum-mode";var vf="x-amz-checksum-sha1",Gf="x-amz-checksum-sha256";var _d="x-amz-create-session-mode";var vh="x-amz-delete-marker",dm="x-amz-expiration",Am="x-amz-expected-bucket-owner";var qd="x-amz-grant-full-control",jd="x-amz-grant-read",id="x-amz-grant-read-acp";var bd="x-amz-grant-write-acp";var Gh="x-amz-missing-meta";var zh="x-amz-mp-parts-count";var Rm="x-amz-object-lock-legal-hold",Sm="x-amz-object-lock-mode",kf="x-amz-object-lock-retain-until-date";var xd="x-amz-restore",Em="x-amz-request-charged";var cm="x-amz-request-payer";var od="x-amz-replication-status";var Im="x-amz-storage-class",nd="x-amz-sdk-checksum-algorithm";var nr="x-amz-server-side-encryption",pr="x-amz-server-side-encryption-aws-kms-key-id",u="x-amz-server-side-encryption-bucket-key-enabled",os="x-amz-server-side-encryption-context",ns="x-amz-server-side-encryption-customer-algorithm",Pm="x-amz-server-side-encryption-customer-key",ps="x-amz-server-side-encryption-customer-key-md5",pd="x-amz-tagging",Fh="x-amz-tagging-count";var km="x-amz-version-id",Nm="x-amz-website-redirect-location",Dm="x-id";class zf extends Ur.classBuilder().ep({...Nr,DisableS3ExpressSessionAuth:{type:"staticContextParams",value:!0},Bucket:{type:"contextParams",name:"Bucket"}}).m(function(r,s,e,f){return[Tr(e,this.serialize,this.deserialize),Mr(e,r.getEndpointParameterInstructions()),Ts(e)]}).s("AmazonS3","CreateSession",{}).n("S3Client","CreateSessionCommand").f(Nh,kh).ser(Zh).de(Bh).build(){}var $m={name:"@aws-sdk/client-s3",description:"AWS SDK for JavaScript S3 Client for Node.js, Browser and React Native",version:"3.654.0",scripts:{build:"concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'","build:cjs":"node ../../scripts/compilation/inline client-s3","build:es":"tsc -p tsconfig.es.json","build:include:deps":"lerna run --scope $npm_package_name --include-dependencies build","build:types":"tsc -p tsconfig.types.json","build:types:downlevel":"downlevel-dts dist-types dist-types/ts3.4",clean:"rimraf ./dist-* && rimraf *.tsbuildinfo","extract:docs":"api-extractor run --local","generate:client":"node ../../scripts/generate-clients/single-service --solo s3",test:"yarn test:unit","test:e2e":"yarn test:e2e:node && yarn test:e2e:browser","test:e2e:browser":"ts-mocha test/**/*.browser.ispec.ts && karma start karma.conf.js","test:e2e:node":"jest --c jest.config.e2e.js","test:unit":"ts-mocha test/unit/**/*.spec.ts"},main:"./dist-cjs/index.js",types:"./dist-types/index.d.ts",module:"./dist-es/index.js",sideEffects:!1,dependencies:{"@aws-crypto/sha1-browser":"5.2.0","@aws-crypto/sha256-browser":"5.2.0","@aws-crypto/sha256-js":"5.2.0","@aws-sdk/client-sso-oidc":"3.654.0","@aws-sdk/client-sts":"3.654.0","@aws-sdk/core":"3.654.0","@aws-sdk/credential-provider-node":"3.654.0","@aws-sdk/middleware-bucket-endpoint":"3.654.0","@aws-sdk/middleware-expect-continue":"3.654.0","@aws-sdk/middleware-flexible-checksums":"3.654.0","@aws-sdk/middleware-host-header":"3.654.0","@aws-sdk/middleware-location-constraint":"3.654.0","@aws-sdk/middleware-logger":"3.654.0","@aws-sdk/middleware-recursion-detection":"3.654.0","@aws-sdk/middleware-sdk-s3":"3.654.0","@aws-sdk/middleware-ssec":"3.654.0","@aws-sdk/middleware-user-agent":"3.654.0","@aws-sdk/region-config-resolver":"3.654.0","@aws-sdk/signature-v4-multi-region":"3.654.0","@aws-sdk/types":"3.654.0","@aws-sdk/util-endpoints":"3.654.0","@aws-sdk/util-user-agent-browser":"3.654.0","@aws-sdk/util-user-agent-node":"3.654.0","@aws-sdk/xml-builder":"3.654.0","@smithy/config-resolver":"^3.0.8","@smithy/core":"^2.4.3","@smithy/eventstream-serde-browser":"^3.0.9","@smithy/eventstream-serde-config-resolver":"^3.0.6","@smithy/eventstream-serde-node":"^3.0.8","@smithy/fetch-http-handler":"^3.2.7","@smithy/hash-blob-browser":"^3.1.5","@smithy/hash-node":"^3.0.6","@smithy/hash-stream-node":"^3.1.5","@smithy/invalid-dependency":"^3.0.6","@smithy/md5-js":"^3.0.6","@smithy/middleware-content-length":"^3.0.8","@smithy/middleware-endpoint":"^3.1.3","@smithy/middleware-retry":"^3.0.18","@smithy/middleware-serde":"^3.0.6","@smithy/middleware-stack":"^3.0.6","@smithy/node-config-provider":"^3.1.7","@smithy/node-http-handler":"^3.2.2","@smithy/protocol-http":"^4.1.3","@smithy/smithy-client":"^3.3.2","@smithy/types":"^3.4.2","@smithy/url-parser":"^3.0.6","@smithy/util-base64":"^3.0.0","@smithy/util-body-length-browser":"^3.0.0","@smithy/util-body-length-node":"^3.0.0","@smithy/util-defaults-mode-browser":"^3.0.18","@smithy/util-defaults-mode-node":"^3.0.18","@smithy/util-endpoints":"^2.1.2","@smithy/util-middleware":"^3.0.6","@smithy/util-retry":"^3.0.6","@smithy/util-stream":"^3.1.6","@smithy/util-utf8":"^3.0.0","@smithy/util-waiter":"^3.1.5",tslib:"^2.6.2"},devDependencies:{"@aws-sdk/signature-v4-crt":"3.654.0","@tsconfig/node16":"16.1.3","@types/chai":"^4.2.11","@types/mocha":"^8.0.4","@types/node":"^16.18.96",concurrently:"7.0.0","downlevel-dts":"0.10.1",rimraf:"3.0.2",typescript:"~4.9.5"},engines:{node:">=16.0.0"},typesVersions:{"<4.0":{"dist-types/*":["dist-types/ts3.4/*"]}},files:["dist-*/**"],author:{name:"AWS SDK for JavaScript Team",url:"https://aws.amazon.com/javascript/"},license:"Apache-2.0",browser:{"./dist-es/runtimeConfig":"./dist-es/runtimeConfig.browser"},"react-native":{"./dist-es/runtimeConfig":"./dist-es/runtimeConfig.native"},homepage:"https://github.com/aws/aws-sdk-js-v3/tree/main/clients/client-s3",repository:{type:"git",url:"https://github.com/aws/aws-sdk-js-v3.git",directory:"clients/client-s3"}};var ee=T(Ls(),1);var td="AWS_S3_USE_ARN_REGION",rA="s3_use_arn_region",ym={environmentVariableSelector:(r)=>er(r,td,fr.ENV),configFileSelector:(r)=>er(r,rA,fr.CONFIG),default:!1};var t=T(Er(),1);var Tm=T(Er(),1);function Um(r){for(let s=0;s<8;s++)r[s]^=255;for(let s=7;s>-1;s--)if(r[s]++,r[s]!==0)break}class Cr{constructor(r){if(this.bytes=r,r.byteLength!==8)throw new Error("Int64 buffers must be exactly 8 bytes")}static fromNumber(r){if(r>9223372036854776000||r<-9223372036854776000)throw new Error(`${r} is too large (or, if negative, too small) to represent as an Int64`);const s=new Uint8Array(8);for(let e=7,f=Math.abs(Math.round(r));e>-1&&f>0;e--,f/=256)s[e]=f;if(r<0)Um(s);return new Cr(s)}valueOf(){const r=this.bytes.slice(0),s=r[0]&128;if(s)Um(r);return parseInt(Tm.toHex(r),16)*(s?-1:1)}toString(){return String(this.valueOf())}}class Ff{constructor(r,s){this.toUtf8=r,this.fromUtf8=s}format(r){const s=[];for(let l of Object.keys(r)){const a=this.fromUtf8(l);s.push(Uint8Array.from([a.byteLength]),a,this.formatHeaderValue(r[l]))}const e=new Uint8Array(s.reduce((l,a)=>l+a.byteLength,0));let f=0;for(let l of s)e.set(l,f),f+=l.byteLength;return e}formatHeaderValue(r){switch(r.type){case"boolean":return Uint8Array.from([r.value?0:1]);case"byte":return Uint8Array.from([2,r.value]);case"short":const s=new DataView(new ArrayBuffer(3));return s.setUint8(0,3),s.setInt16(1,r.value,!1),new Uint8Array(s.buffer);case"integer":const e=new DataView(new ArrayBuffer(5));return e.setUint8(0,4),e.setInt32(1,r.value,!1),new Uint8Array(e.buffer);case"long":const f=new Uint8Array(9);return f[0]=5,f.set(r.value.bytes,1),f;case"binary":const l=new DataView(new ArrayBuffer(3+r.value.byteLength));l.setUint8(0,6),l.setUint16(1,r.value.byteLength,!1);const a=new Uint8Array(l.buffer);return a.set(r.value,3),a;case"string":const h=this.fromUtf8(r.value),m=new DataView(new ArrayBuffer(3+h.byteLength));m.setUint8(0,7),m.setUint16(1,h.byteLength,!1);const g=new Uint8Array(m.buffer);return g.set(h,3),g;case"timestamp":const w=new Uint8Array(9);return w[0]=8,w.set(Cr.fromNumber(r.value.valueOf()).bytes,1),w;case"uuid":if(!kA.test(r.value))throw new Error(`Invalid UUID received: ${r.value}`);const E=new Uint8Array(17);return E[0]=9,E.set(t.fromHex(r.value.replace(/\-/g,"")),1),E}}parse(r){const s={};let e=0;while(e<r.byteLength){const f=r.getUint8(e++),l=this.toUtf8(new Uint8Array(r.buffer,r.byteOffset+e,f));switch(e+=f,r.getUint8(e++)){case 0:s[l]={type:Cm,value:!0};break;case 1:s[l]={type:Cm,value:!1};break;case 2:s[l]={type:dA,value:r.getInt8(e++)};break;case 3:s[l]={type:AA,value:r.getInt16(e,!1)},e+=2;break;case 4:s[l]={type:RA,value:r.getInt32(e,!1)},e+=4;break;case 5:s[l]={type:SA,value:new Cr(new Uint8Array(r.buffer,r.byteOffset+e,8))},e+=8;break;case 6:const a=r.getUint16(e,!1);e+=2,s[l]={type:EA,value:new Uint8Array(r.buffer,r.byteOffset+e,a)},e+=a;break;case 7:const h=r.getUint16(e,!1);e+=2,s[l]={type:cA,value:this.toUtf8(new Uint8Array(r.buffer,r.byteOffset+e,h))},e+=h;break;case 8:s[l]={type:IA,value:new Date(new Cr(new Uint8Array(r.buffer,r.byteOffset+e,8)).valueOf())},e+=8;break;case 9:const m=new Uint8Array(r.buffer,r.byteOffset+e,16);e+=16,s[l]={type:PA,value:`${t.toHex(m.subarray(0,4))}-${t.toHex(m.subarray(4,6))}-${t.toHex(m.subarray(6,8))}-${t.toHex(m.subarray(8,10))}-${t.toHex(m.subarray(10))}`};break;default:throw new Error("Unrecognized header type tag")}}return s}}var Mm;(function(r){r[r.boolTrue=0]="boolTrue",r[r.boolFalse=1]="boolFalse",r[r.byte=2]="byte",r[r.short=3]="short",r[r.integer=4]="integer",r[r.long=5]="long",r[r.byteArray=6]="byteArray",r[r.string=7]="string",r[r.timestamp=8]="timestamp",r[r.uuid=9]="uuid"})(Mm||(Mm={}));var Cm="boolean",dA="byte",AA="short",RA="integer",SA="long",EA="binary",cA="string",IA="timestamp",PA="uuid",kA=/^[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}$/;function vm({byteLength:r,byteOffset:s,buffer:e}){if(r<NA)throw new Error("Provided message too short to accommodate event stream message overhead");const f=new DataView(e,s,r),l=f.getUint32(0,!1);if(r!==l)throw new Error("Reported message length does not match received message length");const a=f.getUint32(Hm,!1),h=f.getUint32(rr,!1),m=f.getUint32(r-hr,!1),g=new sr().update(new Uint8Array(e,s,rr));if(h!==g.digest())throw new Error(`The prelude checksum specified in the message (${h}) does not match the calculated CRC32 checksum (${g.digest()})`);if(g.update(new Uint8Array(e,s+rr,r-(rr+hr))),m!==g.digest())throw new Error(`The message checksum (${g.digest()}) did not match the expected value of ${m}`);return{headers:new DataView(e,s+rr+hr,a),body:new Uint8Array(e,s+rr+hr+a,l-a-(rr+hr+hr))}}var Hm=4,rr=Hm*2,hr=4,NA=rr+hr*2;class Kf{constructor(r,s){this.headerMarshaller=new Ff(r,s),this.messageBuffer=[],this.isEndOfStream=!1}feed(r){this.messageBuffer.push(this.decode(r))}endOfStream(){this.isEndOfStream=!0}getMessage(){const r=this.messageBuffer.pop(),s=this.isEndOfStream;return{getMessage(){return r},isEndOfStream(){return s}}}getAvailableMessages(){const r=this.messageBuffer;this.messageBuffer=[];const s=this.isEndOfStream;return{getMessages(){return r},isEndOfStream(){return s}}}encode({headers:r,body:s}){const e=this.headerMarshaller.format(r),f=e.byteLength+s.byteLength+16,l=new Uint8Array(f),a=new DataView(l.buffer,l.byteOffset,l.byteLength),h=new sr;return a.setUint32(0,f,!1),a.setUint32(4,e.byteLength,!1),a.setUint32(8,h.update(l.subarray(0,8)).digest(),!1),l.set(e,12),l.set(s,e.byteLength+12),a.setUint32(f-4,h.update(l.subarray(8,f-4)).digest(),!1),l}decode(r){const{headers:s,body:e}=vm(r);return{headers:this.headerMarshaller.parse(s),body:e}}formatHeaders(r){return this.headerMarshaller.format(r)}}class Lf{constructor(r){this.options=r}[Symbol.asyncIterator](){return this.asyncIterator()}async*asyncIterator(){for await(let r of this.options.inputStream)yield this.options.decoder.decode(r)}}class Wf{constructor(r){this.options=r}[Symbol.asyncIterator](){return this.asyncIterator()}async*asyncIterator(){for await(let r of this.options.messageStream)yield this.options.encoder.encode(r);if(this.options.includeEndFrame)yield new Uint8Array(0)}}class Qf{constructor(r){this.options=r}[Symbol.asyncIterator](){return this.asyncIterator()}async*asyncIterator(){for await(let r of this.options.messageStream){const s=await this.options.deserializer(r);if(s===void 0)continue;yield s}}}class Xf{constructor(r){this.options=r}[Symbol.asyncIterator](){return this.asyncIterator()}async*asyncIterator(){for await(let r of this.options.inputStream)yield this.options.serializer(r)}}function Gm(r){let s=0,e=0,f=null,l=null;const a=(m)=>{if(typeof m!=="number")throw new Error("Attempted to allocate an event message where size was not a number: "+m);s=m,e=4,f=new Uint8Array(m),new DataView(f.buffer).setUint32(0,m,!1)},h=async function*(){const m=r[Symbol.asyncIterator]();while(!0){const{value:g,done:w}=await m.next();if(w){if(!s)return;else if(s===e)yield f;else throw new Error("Truncated event message received.");return}const E=g.length;let I=0;while(I<E){if(!f){const N=E-I;if(!l)l=new Uint8Array(4);const y=Math.min(4-e,N);if(l.set(g.slice(I,I+y),e),e+=y,I+=y,e<4)break;a(new DataView(l.buffer).getUint32(0,!1)),l=null}const P=Math.min(s-e,E-I);if(f.set(g.slice(I,I+P),e),e+=P,I+=P,s&&s===e)yield f,f=null,s=0,e=0}}};return{[Symbol.asyncIterator]:h}}function zm(r,s){return async function(e){const{value:f}=e.headers[":message-type"];if(f==="error"){const l=new Error(e.headers[":error-message"].value||"UnknownError");throw l.name=e.headers[":error-code"].value,l}else if(f==="exception"){const l=e.headers[":exception-type"].value,a={[l]:e},h=await r(a);if(h.$unknown){const m=new Error(s(e.body));throw m.name=l,m}throw h[l]}else if(f==="event"){const l={[e.headers[":event-type"].value]:e},a=await r(l);if(a.$unknown)return;return a}else throw Error(`Unrecognizable event type: ${e.headers[":event-type"].value}`)}}class us{constructor({utf8Encoder:r,utf8Decoder:s}){this.eventStreamCodec=new Kf(r,s),this.utfEncoder=r}deserialize(r,s){const e=Gm(r);return new Qf({messageStream:new Lf({inputStream:e,decoder:this.eventStreamCodec}),deserializer:zm(s,this.utfEncoder)})}serialize(r,s){return new Wf({messageStream:new Xf({inputStream:r,serializer:s}),encoder:this.eventStreamCodec,includeEndFrame:!0})}}import{Readable as DA}from"stream";async function*Fm(r){let s=!1,e=!1;const f=new Array;r.on("error",(l)=>{if(!s)s=!0;if(l)throw l}),r.on("data",(l)=>{f.push(l)}),r.on("end",()=>{s=!0});while(!e){const l=await new Promise((a)=>setTimeout(()=>a(f.shift()),0));if(l)yield l;e=s&&f.length===0}}class Zf{constructor({utf8Encoder:r,utf8Decoder:s}){this.universalMarshaller=new us({utf8Decoder:s,utf8Encoder:r})}deserialize(r,s){const e=typeof r[Symbol.asyncIterator]==="function"?r:Fm(r);return this.universalMarshaller.deserialize(e,s)}serialize(r,s){return DA.from(this.universalMarshaller.serialize(r,s))}}var Km=(r)=>new Zf(r);import{Writable as $A}from"stream";class ts extends $A{constructor(r,s){super(s);this.hash=r}_write(r,s,e){try{this.hash.update(Y(r))}catch(f){return e(f)}e()}}var Lm=(r,s)=>{if(s.readableFlowing!==null)throw new Error("Unable to calculate hash for flowing readable stream");const e=new r,f=new ts(e);return s.pipe(f),new Promise((l,a)=>{s.on("error",(h)=>{f.end(),a(h)}),f.on("error",a),f.on("finish",()=>{e.digest().then(l).catch(a)})})};var re=T(Ls(),1);var Bm=(r)=>{return{apiVersion:"2006-03-01",base64Decoder:r?.base64Decoder??Qm,base64Encoder:r?.base64Encoder??Xm,disableHostPrefix:r?.disableHostPrefix??!1,endpointProvider:r?.endpointProvider??Ks,extensions:r?.extensions??[],getAwsChunkedEncodingStream:r?.getAwsChunkedEncodingStream??Zm,httpAuthSchemeProvider:r?.httpAuthSchemeProvider??Eh,httpAuthSchemes:r?.httpAuthSchemes??[{schemeId:"aws.auth#sigv4",identityProvider:(s)=>s.getIdentityProvider("aws.auth#sigv4"),signer:new re.AwsSdkSigV4Signer},{schemeId:"aws.auth#sigv4a",identityProvider:(s)=>s.getIdentityProvider("aws.auth#sigv4a"),signer:new re.AwsSdkSigV4ASigner}],logger:r?.logger??new Ss,sdkStreamMixin:r?.sdkStreamMixin??Vm,serviceId:r?.serviceId??"S3",signerConstructor:r?.signerConstructor??Ke,signingEscapePath:r?.signingEscapePath??!1,urlParser:r?.urlParser??Jm,useArnRegion:r?.useArnRegion??!1,utf8Decoder:r?.utf8Decoder??Vr,utf8Encoder:r?.utf8Encoder??Wm}};var eg=(r)=>{qm(process.version);const s=rg(r),e=()=>s().then(_m),f=Bm(r);return ee.emitWarningIfUnsupportedVersion(process.version),{...f,...r,runtime:"node",defaultsMode:s,bodyLengthChecker:r?.bodyLengthChecker??tm,credentialDefaultProvider:r?.credentialDefaultProvider??sg,defaultUserAgentProvider:r?.defaultUserAgentProvider??um({serviceId:f.serviceId,clientVersion:$m.version}),disableS3ExpressSessionAuth:r?.disableS3ExpressSessionAuth??q(He),eventStreamSerdeProvider:r?.eventStreamSerdeProvider??Km,maxAttempts:r?.maxAttempts??q(nm),md5:r?.md5??se.bind(null,"md5"),region:r?.region??q(bm,xm),requestChecksumCalculation:r?.requestChecksumCalculation??q(nf),requestHandler:Ym.create(r?.requestHandler??e),responseChecksumValidation:r?.responseChecksumValidation??q(pf),retryMode:r?.retryMode??q({...pm,default:async()=>(await e()).retryMode||om}),sha1:r?.sha1??se.bind(null,"sha1"),sha256:r?.sha256??se.bind(null,"sha256"),sigv4aSigningRegionSet:r?.sigv4aSigningRegionSet??q(ee.NODE_SIGV4A_CONFIG_OPTIONS),streamCollector:r?.streamCollector??Om,streamHasher:r?.streamHasher??Lm,useArnRegion:r?.useArnRegion??q(ym),useDualstackEndpoint:r?.useDualstackEndpoint??q(jm),useFipsEndpoint:r?.useFipsEndpoint??q(im)}};var fg=(r)=>{const s=r.httpAuthSchemes;let{httpAuthSchemeProvider:e,credentials:f}=r;return{setHttpAuthScheme(l){const a=s.findIndex((h)=>h.schemeId===l.schemeId);if(a===-1)s.push(l);else s.splice(a,1,l)},httpAuthSchemes(){return s},setHttpAuthSchemeProvider(l){e=l},httpAuthSchemeProvider(){return e},setCredentials(l){f=l},credentials(){return f}}},lg=(r)=>{return{httpAuthSchemes:r.httpAuthSchemes(),httpAuthSchemeProvider:r.httpAuthSchemeProvider(),credentials:r.credentials()}};var fe=(r)=>r,Ag=(r,s)=>{const e={...fe(wg(r)),...fe(mg(r)),...fe(ag(r)),...fe(fg(r))};return s.forEach((f)=>f.configure(e)),{...r,...dg(e),...gg(e),...hg(e),...lg(e)}};class Vf extends Ig{constructor(...[r]){const s=eg(r||{}),e=Ih(s),f=Pg(e),l=Al(f),a=yg(l),h=Ng(a),m=Rg(h),g=$g(m),w=ma(g),E=ch(w),I=sa(E,{session:[()=>this,zf]}),P=Ag(I,r?.extensions||[]);super(P);this.config=P,this.middlewareStack.use(kg(this.config)),this.middlewareStack.use(Ug(this.config)),this.middlewareStack.use(Dg(this.config)),this.middlewareStack.use(Sg(this.config)),this.middlewareStack.use(Eg(this.config)),this.middlewareStack.use(cg(this.config)),this.middlewareStack.use(Hr.getHttpAuthSchemeEndpointRuleSetPlugin(this.config,{httpAuthSchemeParametersProvider:Ah,identityProviderConfigProvider:async(N)=>new Hr.DefaultIdentityProviderConfig({"aws.auth#sigv4":N.credentials,"aws.auth#sigv4a":N.credentials})})),this.middlewareStack.use(Hr.getHttpSigningPlugin(this.config)),this.middlewareStack.use(ha(this.config)),this.middlewareStack.use(jf(this.config)),this.middlewareStack.use(cl(this.config)),this.middlewareStack.use(ve(this.config)),this.middlewareStack.use(ze(this.config))}destroy(){super.destroy()}}function yA(r){return(s)=>async(e)=>{const f={...e.input},l=[{target:"SSECustomerKey",hash:"SSECustomerKeyMD5"},{target:"CopySourceSSECustomerKey",hash:"CopySourceSSECustomerKeyMD5"}];for(let a of l){const h=f[a.target];if(h){let m;if(typeof h==="string")if(TA(h,r))m=r.base64Decoder(h);else m=r.utf8Decoder(h),f[a.target]=r.base64Encoder(m);else m=ArrayBuffer.isView(h)?new Uint8Array(h.buffer,h.byteOffset,h.byteLength):new Uint8Array(h),f[a.target]=r.base64Encoder(m);const g=new r.md5;g.update(m),f[a.hash]=r.base64Encoder(await g.digest())}}return s({...e,input:f})}}function TA(r,s){if(!/^(?:[A-Za-z0-9+/]{4})*([A-Za-z0-9+/]{2}==|[A-Za-z0-9+/]{3}=)?$/.test(r))return!1;try{return s.base64Decoder(r).length===32}catch{return!1}}var UA={name:"ssecMiddleware",step:"initialize",tags:["SSE"],override:!0},le=(r)=>({applyToStack:(s)=>{s.add(yA(r),UA)}});class Jf extends Ur.classBuilder().ep({...Nr,Bucket:{type:"contextParams",name:"Bucket"},Key:{type:"contextParams",name:"Key"}}).m(function(r,s,e,f){return[Tr(e,this.serialize,this.deserialize),Mr(e,r.getEndpointParameterInstructions()),As(e,{input:this.input,requestChecksumRequired:!1,requestValidationModeMember:"ChecksumMode",responseAlgorithms:["CRC32","CRC32C","SHA256","SHA1"]}),le(e),Il(e)]}).s("AmazonS3","GetObject",{}).n("S3Client","GetObjectCommand").f($h,Dh).ser(Vh).de(Yh).build(){}class Bf extends Ur.classBuilder().ep({...Nr,Bucket:{type:"contextParams",name:"Bucket"},Key:{type:"contextParams",name:"Key"}}).m(function(r,s,e,f){return[Tr(e,this.serialize,this.deserialize),Mr(e,r.getEndpointParameterInstructions()),As(e,{input:this.input,requestAlgorithmMember:"ChecksumAlgorithm",requestChecksumRequired:!1}),Rl(e),Ts(e),le(e)]}).s("AmazonS3","PutObject",{}).n("S3Client","PutObjectCommand").f(Th,Uh).ser(Jh).de(Oh).build(){}import{Buffer as Tg}from"buffer";class Mg extends mr{client;constructor(...r){super();this.client=new Vf(...r)}async put(r){let s,e,f,l=process.env.BUCKET_NAME;if(r instanceof Blob)s=r,f=`${rs()}.${r.type.split("/")[1].split(";")[0]}`,e=r.type;else s=r.body,f=r.name,e=r.contentType;e=s instanceof Blob||s instanceof File?s.type:void 0;const a=s instanceof Tg?s:Tg.from(await s.arrayBuffer());return await this.client.send(new Bf({Bucket:l,Key:f,Body:a,ContentType:e})),f}async fetch(r){let s=process.env.BUCKET_NAME,e;if(typeof r==="string")e=r;else s=r.bucket??s,e=r.name;if(!e)throw new Error("Object name has to be specified");const f=await this.client.send(new Jf({Bucket:s,Key:e}));return new Response(f.Body.transformToWebStream(),{headers:{"Content-Type":f.ContentType,"Content-Length":f.ContentLength.toString(),"Cache-Control":"private, max-age=12000, must-revalidate","Last-Modified":f.LastModified?.toUTCString()||"",ETag:f.ETag||""}})}}class ae{}class he extends ae{requests=new Map;consume(r,s){if(!this.requests.has(r))this.requests.set(r,{date:Date.now(),count:1});else{const e=this.requests.get(r),f=Date.now();if(f-e.date>=60000)this.requests.set(r,{date:f,count:1});else this.requests.set(r,{date:e.date,count:e.count+1})}return this.requests.get(r).count}}class Cg extends B{driver=new he;boot(){}}import*as GA from"react-dom/server";var Fg=T(MA(),1);import{Writable as LA}from"stream";var{defineProperty:CA,getOwnPropertySymbols:Hg}=Object,HA=Object.prototype.hasOwnProperty,vA=Object.prototype.propertyIsEnumerable,vg=(r,s,e)=>(s in r)?CA(r,s,{enumerable:!0,configurable:!0,writable:!0,value:e}):r[s]=e,Yf=(r,s)=>{for(var e in s||(s={}))if(HA.call(s,e))vg(r,e,s[e]);if(Hg){for(var e of Hg(s))if(vA.call(s,e))vg(r,e,s[e])}return r},Of=(r,s,e)=>{return new Promise((f,l)=>{var a=(g)=>{try{m(e.next(g))}catch(w){l(w)}},h=(g)=>{try{m(e.throw(g))}catch(w){l(w)}},m=(g)=>g.done?f(g.value):Promise.resolve(g.value).then(a,h);m((e=e.apply(r,s)).next())})},zA={unformatted:["code","pre","em","strong","span"],indent_inner_html:!0,indent_char:" ",indent_size:2,sep:"\n"},FA=(r,s={})=>{return Fg.default.html(r,Yf(Yf({},zA),s))},KA=[{selector:"img",format:"skip"},{selector:"#__react-email-preview",format:"skip"},{selector:"a",options:{linkBrackets:!1}}];var Gg=new TextDecoder("utf-8"),zg=(r)=>Of(void 0,null,function*(){let s="";if("pipeTo"in r){const e=new WritableStream({write(f){s+=Gg.decode(f)}});yield r.pipeTo(e)}else{const e=new LA({write(f,l,a){s+=Gg.decode(f),a()}});return r.pipe(e),new Promise((f,l)=>{e.on("error",l),e.on("close",()=>{f(s)})})}return s}),me=(r,s)=>Of(void 0,null,function*(){const{default:e}=yield import("react-dom/server");let f;if(Object.hasOwn(e,"renderToReadableStream"))f=yield zg(yield e.renderToReadableStream(r));else yield new Promise((h,m)=>{const g=e.renderToPipeableStream(r,{onAllReady(){return Of(this,null,function*(){f=yield zg(g),h()})},onError(w){m(w)}})});if(s==null?void 0:s.plainText)return _f(f,Yf({selectors:KA},s.htmlToTextOptions));const a=`${'<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">'}${f.replace(/<!DOCTYPE.*?>/,"")}`;if(s==null?void 0:s.pretty)return FA(a);return a});var{defineProperty:WA,defineProperties:QA,getOwnPropertyDescriptors:XA,getOwnPropertySymbols:Kg}=Object,ZA=Object.prototype.hasOwnProperty,VA=Object.prototype.propertyIsEnumerable,Lg=(r,s,e)=>(s in r)?WA(r,s,{enumerable:!0,configurable:!0,writable:!0,value:e}):r[s]=e,ur=(r,s)=>{for(var e in s||(s={}))if(ZA.call(s,e))Lg(r,e,s[e]);if(Kg){for(var e of Kg(s))if(VA.call(s,e))Lg(r,e,s[e])}return r},JA=(r,s)=>QA(r,XA(s)),k=(r,s,e)=>{return new Promise((f,l)=>{var a=(g)=>{try{m(e.next(g))}catch(w){l(w)}},h=(g)=>{try{m(e.throw(g))}catch(w){l(w)}},m=(g)=>g.done?f(g.value):Promise.resolve(g.value).then(a,h);m((e=e.apply(r,s)).next())})},BA="3.5.0",YA=class{constructor(r){this.resend=r}create(r){return k(this,arguments,function*(s,e={}){return yield this.resend.post("/api-keys",s,e)})}list(){return k(this,null,function*(){return yield this.resend.get("/api-keys")})}remove(r){return k(this,null,function*(){return yield this.resend.delete(`/api-keys/${r}`)})}},OA=class{constructor(r){this.resend=r}create(r){return k(this,arguments,function*(s,e={}){return yield this.resend.post("/audiences",s,e)})}list(){return k(this,null,function*(){return yield this.resend.get("/audiences")})}get(r){return k(this,null,function*(){return yield this.resend.get(`/audiences/${r}`)})}remove(r){return k(this,null,function*(){return yield this.resend.delete(`/audiences/${r}`)})}},_A=class{constructor(r){this.resend=r}send(r){return k(this,arguments,function*(s,e={}){return this.create(s,e)})}create(r){return k(this,arguments,function*(s,e={}){for(let l of s)if(l.react)l.html=yield me(l.react),delete l.react;return yield this.resend.post("/emails/batch",s,e)})}},qA=class{constructor(r){this.resend=r}create(r){return k(this,arguments,function*(s,e={}){return yield this.resend.post(`/audiences/${s.audienceId}/contacts`,{unsubscribed:s.unsubscribed,email:s.email,first_name:s.firstName,last_name:s.lastName},e)})}list(r){return k(this,null,function*(){return yield this.resend.get(`/audiences/${r.audienceId}/contacts`)})}get(r){return k(this,null,function*(){return yield this.resend.get(`/audiences/${r.audienceId}/contacts/${r.id}`)})}update(r){return k(this,null,function*(){return yield this.resend.patch(`/audiences/${r.audienceId}/contacts/${r.id}`,{unsubscribed:r.unsubscribed,first_name:r.firstName,last_name:r.lastName})})}remove(r){return k(this,null,function*(){return yield this.resend.delete(`/audiences/${r.audienceId}/contacts/${(r==null?void 0:r.email)?r==null?void 0:r.email:r==null?void 0:r.id}`)})}},jA=class{constructor(r){this.resend=r}create(r){return k(this,arguments,function*(s,e={}){return yield this.resend.post("/domains",s,e)})}list(){return k(this,null,function*(){return yield this.resend.get("/domains")})}get(r){return k(this,null,function*(){return yield this.resend.get(`/domains/${r}`)})}update(r){return k(this,null,function*(){return yield this.resend.patch(`/domains/${r.id}`,{click_tracking:r.clickTracking,open_tracking:r.openTracking,tls:r.tls})})}remove(r){return k(this,null,function*(){return yield this.resend.delete(`/domains/${r}`)})}verify(r){return k(this,null,function*(){return yield this.resend.post(`/domains/${r}/verify`)})}},iA=class{constructor(r){this.resend=r}send(r){return k(this,arguments,function*(s,e={}){return this.create(s,e)})}create(r){return k(this,arguments,function*(s,e={}){if(s.react)s.html=yield me(s.react),delete s.react;return yield this.resend.post("/emails",s,e)})}get(r){return k(this,null,function*(){return yield this.resend.get(`/emails/${r}`)})}},Wg="https://api.resend.com",Qg=`resend-node:${BA}`,bA=typeof process!=="undefined"&&process.env?process.env.RESEND_BASE_URL||Wg:Wg,xA=typeof process!=="undefined"&&process.env?process.env.RESEND_USER_AGENT||Qg:Qg,Xg=class{constructor(r){if(this.key=r,this.apiKeys=new YA(this),this.audiences=new OA(this),this.batch=new _A(this),this.contacts=new qA(this),this.domains=new jA(this),this.emails=new iA(this),!r){if(typeof process!=="undefined"&&process.env)this.key=process.env.RESEND_API_KEY;if(!this.key)throw new Error('Missing API key. Pass it to the constructor `new Resend("re_123")`')}this.headers=new Headers({Authorization:`Bearer ${this.key}`,"User-Agent":xA,"Content-Type":"application/json"})}fetchRequest(r){return k(this,arguments,function*(s,e={}){try{const f=yield fetch(`${bA}${s}`,e);if(!f.ok)try{const a=yield f.text();return{data:null,error:JSON.parse(a)}}catch(a){if(a instanceof SyntaxError)return{data:null,error:{name:"application_error",message:"Internal server error. We are unable to process your request right now, please try again later."}};const h={message:f.statusText,name:"application_error"};if(a instanceof Error)return{data:null,error:JA(ur({},h),{message:a.message})};return{data:null,error:h}}return{data:yield f.json(),error:null}}catch(f){return{data:null,error:{name:"application_error",message:"Unable to fetch data. The request could not be resolved."}}}})}post(r,s){return k(this,arguments,function*(e,f,l={}){const a=ur({method:"POST",headers:this.headers,body:JSON.stringify(f)},l);return this.fetchRequest(e,a)})}get(r){return k(this,arguments,function*(s,e={}){const f=ur({method:"GET",headers:this.headers},e);return this.fetchRequest(s,f)})}put(r,s){return k(this,arguments,function*(e,f,l={}){const a=ur({method:"PUT",headers:this.headers,body:JSON.stringify(f)},l);return this.fetchRequest(e,a)})}patch(r,s){return k(this,arguments,function*(e,f,l={}){const a=ur({method:"PATCH",headers:this.headers,body:JSON.stringify(f)},l);return this.fetchRequest(e,a)})}delete(r,s){return k(this,null,function*(){const e={method:"DELETE",headers:this.headers,body:JSON.stringify(s)};return this.fetchRequest(r,e)})}};class ge{}class we extends ge{r;constructor(r=process.env.RESEND_API_KEY){super();this.apiKey=r}async send(r){const s=new Xg(this.apiKey),{data:e,error:f}=await s.emails.send({...r});if(f)return console.error(f),!1;if(e)return!0}}class Zg extends B{driver=new we;boot(){}}class Vg extends B{channels={};boot(){}}class Jg extends B{root;rootRouter;boot(){}}class Bg extends B{rootRouter;boot(){return"Origin"}}export{Jg as ViewRouterServiceProvider,Mg as S3Driver,we as ResendDriver,Cg as RateLimiterServiceProvider,ae as RateLimiterDriver,he as InMemoryRateLimiter,ss as FileSystemDriver,qf as FileStorageServiceProvider,mr as FileStorageDriver,Zg as EmailServiceProvider,ge as EmailDriver,Vg as BroadcastingServiceProvider,Bg as ApiRouterServiceProvider};export{qf as w,Bg as x,Cg as y,Zg as z,Vg as A,Jg as B};
|
|
12
|
-
|
|
13
|
-
//# debugId=66178310053F56D864756E2164756E21
|
|
4
|
+
//# debugId=0D2921094D58EA0064756E2164756E21
|