PageSourceSearch

https://static3.freecash.com/_next/static/chunks/0_x81-3fn92qc.js?dpl=r2-1

js freecash.com collected 2026-10-01 10:22:36 UTC 324,448 bytes, 52 lines download raw bytes

1;!function(){try { var e="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof global?global:"undefined"!=typeof window?window:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&((e._debugIds|| (e._debugIds={}))[n]="0f4f7dab-2aca-a0b2-b2e2-256d8213bc67")}catch(e){}}();
2(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,588993,(e,t,a)=>{t.exports=JSON.parse('{"nm":"Main Scene","ddd":0,"h":512,"w":512,"meta":{"g":"@lottiefiles/[email protected]"},"layers":[{"ty":0,"nm":"Wing dx","sr":1,"st":0,"op":90,"ip":0,"hd":false,"ddd":0,"bm":0,"hasMask":false,"ao":0,"ks":{"a":{"a":0,"k":[6.304753623319229,12.98982545479994]},"s":{"a":0,"k":[100,100]},"sk":{"a":0,"k":0},"p":{"a":0,"k":[47.52826319339223,40.800223918486054]},"r":{"a":1,"k":[{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[0],"t":1},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[14],"t":5},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[0],"t":9},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[18],"t":13},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[0],"t":17},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[18],"t":21},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[0],"t":25},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[18],"t":29},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[0],"t":33},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[18],"t":37},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[0],"t":41},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[18],"t":45},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[0],"t":49},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[18],"t":53},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[0],"t":57},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[18],"t":61},{"o":{"x":0.167,"y":0.167},"i":{"x":0.833,"y":0.833},"s":[0],"t":65},{"o":{"x":0.167,"y":0.167},"i":{"x":0.833,"y":0.833},"s":[18],"t":69},{"o":{"x":0.167,"y":0.167},"i":{"x":0.833,"y":0.833},"s":[0],"t":73},{"o":{"x":0.167,"y":0.167},"i":{"x":0.833,"y":0.833},"s":[18],"t":77},{"s":[0],"t":81}]},"sa":{"a":0,"k":0},"o":{"a":0,"k":100}},"w":56,"h":53,"refId":"precomp_Shape Layer - SVG_XGn1X-uVPx_24c5de1a-9871-454c-84d6-332198e02dab","ind":1,"parent":2},{"ty":0,"nm":"Money","sr":1,"st":0,"op":150,"ip":0,"hd":false,"ddd":0,"bm":0,"hasMask":false,"ao":0,"ks":{"a":{"a":0,"k":[34.09706297993166,35.39615642692687]},"s":{"a":0,"k":[333.08235183043405,333.08235183043405]},"sk":{"a":0,"k":0},"p":{"a":1,"k":[{"o":{"x":0.26999737394957984,"y":0.16521796218487397},"i":{"x":0.6667000000000001,"y":1},"s":[252.56173106602265,245.75541891370497],"t":0},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[251.46497584541063,218.25543478260872],"t":18},{"o":{"x":0.3333,"y":0},"i":{"x":0.4161961659663866,"y":1.0185399159663866},"s":[252.06280193236717,246.96014492753625],"t":40},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[250.98490338164257,234.02234299516908],"t":59},{"s":[252.20169082125608,247.3798309178744],"t":81}]},"r":{"a":0,"k":0},"sa":{"a":0,"k":0},"o":{"a":0,"k":100}},"w":76,"h":81,"refId":"precomp_Shape Layer - SVG_iYtmjw_OFB_814643af-78d8-4a93-bd8d-ae614b1933dd","ind":2},{"ty":0,"nm":"Star","sr":1,"st":0,"op":150,"ip":0,"hd":false,"ddd":0,"bm":0,"hasMask":false,"ao":0,"ks":{"a":{"a":0,"k":[9.999998731207,16.999997987635354]},"s":{"a":1,"k":[{"o":{"x":0,"y":0.9895483193277312},"i":{"x":0.03215598739495798,"y":1.0023503151260504},"s":[0,0],"t":2},{"o":{"x":0.9393644957983192,"y":0.00554753822313625},"i":{"x":0,"y":1.0104159250680138},"s":[100,100],"t":31},{"s":[0,0],"t":72}]},"sk":{"a":0,"k":0},"p":{"a":0,"k":[39.5011289989989,75.32622020040914]},"r":{"a":1,"k":[{"o":{"x":0,"y":0.9030265231092436},"i":{"x":0.18459823237998144,"y":0.9997863787412644},"s":[0],"t":2},{"s":[360],"t":64}]},"sa":{"a":0,"k":0},"o":{"a":0,"k":100}},"w":20,"h":34,"refId":"precomp_Shape Layer - SVG_epyw6C5u57_0e11cd55-0c69-4dc3-80b6-a128c413b49e","ind":3,"parent":2},{"ty":0,"nm":"Wing sx","sr":1,"st":0,"op":90,"ip":0,"hd":false,"ddd":0,"bm":0,"hasMask":false,"ao":0,"ks":{"a":{"a":0,"k":[54.09706146201805,25.19751372993855]},"s":{"a":0,"k":[100.0,100.0]},"sk":{"a":0,"k":0},"p":{"a":0,"k":[24.921638180660775,37.3692812538017]},"r":{"a":1,"k":[{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[5],"t":1},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1}
2,"s":[-10],"t":5},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[5],"t":9},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[-10],"t":13},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[5],"t":17},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[-10],"t":21},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[5],"t":25},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[-10],"t":29},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[5],"t":33},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[-10],"t":37},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[5],"t":41},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[-10],"t":45},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[5],"t":49},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[-10],"t":53},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[5],"t":57},{"o":{"x":0.3333,"y":0},"i":{"x":0.6667000000000001,"y":1},"s":[-10],"t":61},{"o":{"x":0.167,"y":0.167},"i":{"x":0.833,"y":0.833},"s":[5],"t":65},{"o":{"x":0.167,"y":0.167},"i":{"x":0.833,"y":0.833},"s":[-10],"t":69},{"o":{"x":0.167,"y":0.167},"i":{"x":0.833,"y":0.833},"s":[5],"t":73},{"o":{"x":0.167,"y":0.167},"i":{"x":0.833,"y":0.833},"s":[-10],"t":77},{"s":[5],"t":81}]},"sa":{"a":0,"k":0},"o":{"a":0,"k":100}},"w":58,"h":57,"refId":"precomp_Shape Layer - SVG_i-Pgm2dlwU_19bf4358-b580-4930-93b9-60ec6eaec45f","ind":4,"parent":2}],"v":"5.7.0","fr":30,"op":81,"ip":0,"assets":[{"nm":"Group 513682","id":"precomp_Shape Layer - SVG_i-Pgm2dlwU_19bf4358-b580-4930-93b9-60ec6eaec45f","fr":30,"layers":[{"ty":4,"nm":"Shape Layer 1","sr":1,"st":0,"op":150,"ip":0,"hd":false,"ddd":0,"bm":0,"hasMask":false,"ao":0,"ks":{"a":{"a":0,"k":[0,0]},"s":{"a":0,"k":[100,100]},"sk":{"a":0,"k":0},"p":{"a":0,"k":[10.04997502326025,-0.6155308752613236]},"r":{"a":0,"k":0},"sa":{"a":0,"k":0},"o":{"a":0,"k":100}},"shapes":[{"ty":"gr","bm":0,"hd":false,"nm":"Group 1","np":2,"it":[{"ty":"sh","bm":0,"hd":false,"nm":"Path 1","d":1,"ks":{"a":0,"k":{"c":true,"i":[[0,0],[0,0],[0,0],[0,0],[0,0],[1.48,1.87],[0.01,0.01],[0,0],[0.05,-0.01],[0.76,2.51],[0,0],[0.35,-0.01],[0.7,1.77],[-0.48,-0.01],[-12.91,7.58],[-2.64,-3.7],[-0.35,-1.39],[0,0],[0,0]],"o":[[0,0],[-3.63,6.86],[-1.22,8.31],[-2.18,9.38],[-3.2,4.22],[0,0],[-0.14,-0.36],[-0.04,0.02],[-4.52,2.86],[-0.49,-1.64],[-0.39,0.05],[-3.56,0.25],[0.35,0.04],[4.23,0.09],[7.07,-4.16],[0.58,1.3],[0,0],[0.41,3.12],[0,0]],"v":[[46.48,31.4],[45.8,37.59],[39,37.84],[32.75,36.93],[25.32,36.82],[18.24,37.91],[18.22,37.89],[17.99,37.31],[17.86,37.4],[10.72,35.15],[10.21,31.89],[9.1,31.99],[3.22,28.9],[4.48,28.97],[30.67,20.51],[44.7,21.79],[46.07,25.85],[46.08,25.89],[46.48,31.4]]}}},{"ty":"fl","bm":0,"hd":false,"nm":"Fill","c":{"a":0,"k":[0.4706,0.4902,1]},"r":1,"o":{"a":0,"k":100}},{"ty":"tr","a":{"a":0,"k":[0,0]},"s":{"a":0,"k":[100,100]},"sk":{"a":0,"k":0},"p":{"a":0,"k":[0,0]},"r":{"a":0,"k":0},"sa":{"a":0,"k":0},"o":{"a":0,"k":100}}]},{"ty":"gr","bm":0,"hd":false,"nm":"Group 2","np":2,"it":[{"ty":"sh","bm":0,"hd":false,"nm":"Path 2","d":1,"ks":{"a":0,"k":{"c":true,"i":[[0,0],[0,0],[0,0],[0,0],[0,0],[0.83,2],[-3.2,4.22],[-2.17,9.37],[-1.22,8.31],[-3.62,6.87],[0,0],[0.42,3.13],[0,0],[0.56,1.3],[-0.59,-2.4],[0.01,-0.03],[0,0],[0,0]],"o":[[0,0],[-3.63,6.88],[-1.22,8.31],[-2.17,9.37],[-4.76,6.3],[1.49,1.89],[0,0],[0,0],[0,0],[0,0],[0,0],[0,0],[-0.35,-1.39],[1.34,1.9],[0,0],[0.41,3.12],[0,0],[0,0]],"v":[[47.95,34.05],[47.27,40.23],[40.47,40.49],[34.22,39.58],[26.79,39.48],[18.22,37.9],[25.3,36.81],[32.73,36.92],[38.99,37.83],[45.78,37.58],[46.46,31.39],[46.06,25.88],[46.06,25.84],[44.69,21.78],[47.54,28.49],[47.55,28.54],[47.95,34.03],[47.95,34.05]]}}},{"ty":"fl","bm":0,"hd":false,"nm":"Fill","c":{"a":0,"k":[0.3294,0.3608,1]},"r":1,"o":{"a":0,"k":100}},{"ty":"tr","a":{"a":0,"k":[0,0]},"s":{"a":0,"k":[100,100]},"sk":{"a":0,"k":0},"p":{"a":0,"k":[0,0]},"r":{"a":0,"k":0},"sa":{"a":0,"k":0},"o":{"a":0,"k":100}}]},{"ty":"gr","bm":0,"hd":false,"nm":"Group 3","np":2,"it":[{"ty":"sh","bm":0,"hd":false,"nm":"Path 3","d":1,"ks":{"a":0,"k":{"c":true,"i":[[0,0],[10.7,-6.27],[3.47,0.29],[0,0],[-17.66,10.38],[-1,-7.52],[0,0]],"o":[[-1.8,-7.11],[-14.4,8.46],[-0.86,-2.09],[0,0],[12.45,-7.31],[0,0],[0,0]],"v":[[47.6,28.51],[30.71,20.5],[3.26,28.91],[2.84,24.45],[30.59,16.58],[47.58,28.5],[47.6,28.51]]}}},{"ty":"fl","bm":0,"hd":false,"nm":"Fill","c":{"a":0,"k":[0.6784,0.6902,1]},"r":1,"o":{"a":0,"k":100}},{"ty":"tr","a":{"a":0,"k":[0,0]},"s":{"a":0,"k":[100,100]},"sk":{"a":0,"k":0},"p":{"a":0,"k":[0,0]},"r":{"a":0,"k":0},"sa":{"a":0,"k":0},"o":{"a":0,"k":100}}]}],"ind":1}],"w":58,"h":57}
2,{"nm":"Vector","id":"precomp_Shape Layer - SVG_epyw6C5u57_0e11cd55-0c69-4dc3-80b6-a128c413b49e","fr":30,"layers":[{"ty":4,"nm":"Shape Layer 2","sr":1,"st":0,"op":150,"ip":0,"hd":false,"ddd":0,"bm":0,"hasMask":false,"ao":0,"ks":{"a":{"a":0,"k":[0,0]},"s":{"a":0,"k":[100,100]},"sk":{"a":0,"k":0},"p":{"a":0,"k":[0,0]},"r":{"a":0,"k":0},"sa":{"a":0,"k":0},"o":{"a":0,"k":100}},"shapes":[{"ty":"gr","bm":0,"hd":false,"nm":"Group 4","np":2,"it":[{"ty":"sh","bm":0,"hd":false,"nm":"Path 4","d":1,"ks":{"a":0,"k":{"c":true,"i":[[0,0],[8.36,-14.99],[3.04,1.64],[-0.83,-0.21],[-4.96,5.71],[-1.62,2.89],[0.68,-2.21],[-0.89,-2.26],[-1.28,-0.7],[0,0]],"o":[[-3.02,-1.67],[8.36,-14.99],[0.55,0.3],[2.85,0.74],[1.53,-1.75],[-1.6,2.89],[-1.4,4.47],[0.98,2.42],[0,0],[0,0]],"v":[[19.31,22.01],[0.34,33.42],[0,11.43],[2.08,12.25],[14.25,6.9],[18.97,0],[15.59,7.61],[15.33,17.52],[19.31,21.99],[19.31,22.01]]}}},{"ty":"fl","bm":0,"hd":false,"nm":"Fill","c":{"a":0,"k":[0.949,0.8392,0.3882]},"r":1,"o":{"a":0,"k":100}},{"ty":"tr","a":{"a":0,"k":[0,0]},"s":{"a":0,"k":[100,100]},"sk":{"a":0,"k":0},"p":{"a":0,"k":[0,0]},"r":{"a":0,"k":0},"sa":{"a":0,"k":0},"o":{"a":0,"k":100}}]}],"ind":1}],"w":20,"h":34},{"nm":"Group 513686","id":"precomp_Shape Layer - SVG_iYtmjw_OFB_814643af-78d8-4a93-bd8d-ae614b1933dd","fr":30,"layers":[{"ty":4,"nm":"Shape Layer 3","sr":1,"st":0,"op":150,"ip":0,"hd":false,"ddd":0,"bm":0,"hasMask":false,"ao":0,"ks":{"a":{"a":0,"k":[0,0]},"s":{"a":0,"k":[100,100]},"sk":{"a":0,"k":0},"p":{"a":0,"k":[0,0]},"r":{"a":0,"k":0},"sa":{"a":0,"k":0},"o":{"a":0,"k":100}},"shapes":[{"ty":"gr","bm":0,"hd":false,"nm":"Group 5","np":2,"it":[{"ty":"sh","bm":0,"hd":false,"nm":"Path 5","d":1,"ks":{"a":0,"k":{"c":true,"i":[[0,0],[-0.87,0.82],[0,0],[-0.12,1.96],[-0.41,1.58],[-0.09,0.29],[-0.37,-0.02],[-0.36,2.47],[0,0],[-2.03,-0.69],[0.04,-0.21],[0.1,-0.69],[0.09,-0.91],[0.03,-0.31],[0.02,-0.29],[0.03,-0.48],[0.16,-0.78],[5.05,0.3],[0,0],[0,0]],"o":[[2.05,0.13],[1.26,-1.15],[0.56,-1.53],[0.12,-1.96],[0.08,-0.32],[0.35,0.11],[2.54,0.15],[0,0],[-0.13,2.24],[-0.04,0.21],[-0.12,0.65],[-0.13,0.85],[-0.03,0.29],[-0.03,0.29],[-0.04,0.47],[-0.05,0.94],[0,0],[0,0],[0,0],[0,0]],"v":[[23.95,34.68],[28.24,33.33],[29.79,30.71],[30.84,25.49],[31.62,20.22],[31.88,19.29],[32.95,19.48],[38.05,15.33],[51.55,16.14],[54.85,21.04],[54.72,21.67],[54.38,23.67],[54.04,26.32],[53.96,27.22],[53.88,28.11],[53.78,29.54],[53.45,32.14],[48.55,36.16],[23.96,34.68],[23.95,34.68]]}}},{"ty":"gf","bm":0,"hd":false,"nm":"paint1_linear_686_326","e":{"a":0,"k":[54.89,36.17]},"g":{"p":2,"k":{"a":0,"k":[0,0.4392156862745098,1,0.7490196078431373,1,0,0.8392156862745098,0.4588235294117647]}},"t":1,"a":{"a":0,"k":0},"h":{"a":0,"k":0},"s":{"a":0,"k":[39.21,36.17]},"r":2,"o":{"a":0,"k":100}},{"ty":"tr","a":{"a":0,"k":[0,0]},"s":{"a":0,"k":[100,100]},"sk":{"a":0,"k":0},"p":{"a":0,"k":[0,0]},"r":{"a":0,"k":0},"sa":{"a":0,"k":0},"o":{"a":0,"k":100}}]},{"ty":"gr","bm":0,"hd":false,"nm":"Group 6","np":2,"it":[{"ty":"sh","bm":0,"hd":false,"nm":"Path 6","d":1,"ks":{"a":0,"k":{"c":true,"i":[[0,0],[-1.49,2.05],[-0.17,2.83],[-0.44,1.7],[-1.03,1.28],[-1.2,-0.07],[0,0],[0.32,-0.28],[0.67,-11.17],[0.25,-1.11],[1.89,0.11],[0,0],[0,0],[-0.06,0.94],[-0.04,0.47],[-0.03,0.29],[-0.04,0.29],[-0.13,0.85],[-0.12,0.65],[-0.04,0.21],[-0.14,2.24],[0,0],[2.54,0.15],[0.35,0.1],[0.08,-0.32],[0.11,-1.91],[0.56,-1.53],[1.26,-1.15],[2.06,0.12],[0,0],[0,0]],"o":[[1.61,0.1],[1.06,-1.47],[0.14,-2.37],[0.9,-3.53],[0.75,-0.94],[0,0],[0.43,0.03],[-1.62,1.38],[-0.08,1.35],[-0.42,1.84],[0,0],[5.05,0.31],[0.16,-0.78],[0.03,-0.49],[0.02,-0.29],[0.03,-0.3],[0.09,-0.92],[0.1,-0.69],[0.04,-0.21],[-2.03,-0.69],[0,0],[-0.36,2.47],[-0.37,-0.02],[-0.09,0.29],[-0.41,1.58],[-0.11,1.91],[0,0],[-0.87,0.82],[0,0],[0,0],[0,0]],"v":[[19.38,34.4],[24.5,31.62],[26.53,25.22],[27.45,19.14],[30.71,12.12],[33.83,10.76],[62.64,12.5],[62.92,13.33],[58.08,29.81],[57.57,33.48],[53.55,36.46],[48.55,36.16],[53.45,32.14],[53.78,29.55],[53.88,28.11],[53.96,27.22],[54.04,26.32],[54.38,23.67],[54.72,21.68],[54.85,21.04],[51.55,16.15],[38.05,15.34],[32.95,19.48],[31.88,19.3],[31.62,20.22],[30.84,25.49],[29.79,30.72],[28.24,33.33],[23.95,34.68],[19.38,34.41],[19.38,34.4]]}}},{"ty":"fl","bm":0,"hd":false,"nm":"Fill","c":{"a":0,"k":[0,0.5882,0.3294]}
2,"r":1,"o":{"a":0,"k":100}},{"ty":"tr","a":{"a":0,"k":[0,0]},"s":{"a":0,"k":[100,100]},"sk":{"a":0,"k":0},"p":{"a":0,"k":[0,0]},"r":{"a":0,"k":0},"sa":{"a":0,"k":0},"o":{"a":0,"k":100}}]},{"ty":"gr","bm":0,"hd":false,"nm":"Group 7","np":2,"it":[{"ty":"sh","bm":0,"hd":false,"nm":"Path 7","d":1,"ks":{"a":0,"k":{"c":true,"i":[[0,0],[0.87,-0.82],[0,0],[0.12,-1.96],[0.41,-1.58],[0.09,-0.29],[0.37,0.02],[0.36,-2.47],[0,0],[2.03,0.69],[-0.04,0.21],[-0.1,0.69],[-0.09,0.91],[-0.03,0.31],[-0.02,0.29],[-0.03,0.48],[-0.16,0.78],[-5.05,-0.3],[0,0],[0,0]],"o":[[-2.05,-0.13],[-1.26,1.15],[-0.56,1.53],[-0.12,1.96],[-0.08,0.32],[-0.34,-0.11],[-2.54,-0.15],[0,0],[0.13,-2.24],[0.04,-0.21],[0.12,-0.65],[0.13,-0.85],[0.03,-0.29],[0.03,-0.29],[0.04,-0.47],[0.05,-0.94],[0,0],[0,0],[0,0],[0,0]],"v":[[39.14,35.58],[34.85,36.93],[33.3,39.54],[32.25,44.77],[31.46,50.03],[31.21,50.96],[30.14,50.78],[25.03,54.92],[11.54,54.11],[8.24,49.21],[8.37,48.58],[8.71,46.59],[9.05,43.94],[9.13,43.04],[9.21,42.15],[9.31,40.71],[9.63,38.12],[14.54,34.1],[39.13,35.58],[39.14,35.58]]}}},{"ty":"gf","bm":0,"hd":false,"nm":"paint0_linear_686_326","e":{"a":0,"k":[23.69,54.92]},"g":{"p":2,"k":{"a":0,"k":[0,0.4392156862745098,1,0.7490196078431373,0.65,0,0.8392156862745098,0.4588235294117647]}},"t":1,"a":{"a":0,"k":0},"h":{"a":0,"k":0},"s":{"a":0,"k":[10.53,54.92]},"r":2,"o":{"a":0,"k":100}},{"ty":"tr","a":{"a":0,"k":[0,0]},"s":{"a":0,"k":[100,100]},"sk":{"a":0,"k":0},"p":{"a":0,"k":[0,0]},"r":{"a":0,"k":0},"sa":{"a":0,"k":0},"o":{"a":0,"k":100}}]},{"ty":"gr","bm":0,"hd":false,"nm":"Group 8","np":2,"it":[{"ty":"sh","bm":0,"hd":false,"nm":"Path 8","d":1,"ks":{"a":0,"k":{"c":true,"i":[[0,0],[1.49,-2.05],[0.17,-2.83],[0.44,-1.7],[1.03,-1.28],[1.2,0.07],[0,0],[-0.32,0.28],[-0.67,11.17],[-0.25,1.11],[-1.89,-0.11],[0,0],[0,0],[0.06,-0.94],[0.04,-0.47],[0.03,-0.29],[0.04,-0.29],[0.13,-0.85],[0.12,-0.65],[0.04,-0.21],[0.14,-2.24],[0,0],[-2.54,-0.15],[-0.35,-0.1],[-0.08,0.32],[-0.11,1.91],[-0.56,1.53],[-1.26,1.15],[-2.06,-0.12],[0,0],[0,0]],"o":[[-1.61,-0.1],[-1.06,1.47],[-0.14,2.37],[-0.9,3.53],[-0.75,0.94],[0,0],[-0.43,-0.03],[1.62,-1.38],[0.08,-1.35],[0.42,-1.84],[0,0],[-5.05,-0.31],[-0.16,0.78],[-0.03,0.49],[-0.02,0.29],[-0.03,0.3],[-0.09,0.92],[-0.1,0.69],[-0.04,0.21],[2.03,0.69],[0,0],[0.36,-2.47],[0.37,0.02],[0.09,-0.29],[0.41,-1.58],[0.11,-1.91],[0,0],[0.87,-0.82],[0,0],[0,0],[0,0]],"v":[[43.7,35.86],[38.59,38.64],[36.56,45.03],[35.64,51.12],[32.38,58.14],[29.26,59.5],[0.45,57.76],[0.17,56.93],[5,40.45],[5.52,36.77],[9.54,33.79],[14.54,34.1],[9.63,38.12],[9.31,40.71],[9.21,42.15],[9.13,43.04],[9.05,43.94],[8.71,46.59],[8.37,48.58],[8.24,49.21],[11.54,54.11],[25.03,54.92],[30.14,50.78],[31.21,50.96],[31.46,50.03],[32.25,44.77],[33.3,39.54],[34.85,36.93],[39.14,35.58],[43.7,35.85],[43.7,35.86]]}}},{"ty":"fl","bm":0,"hd":false,"nm":"Fill","c":{"a":0,"k":[0,0.5882,0.3294]},"r":1,"o":{"a":0,"k":100}},{"ty":"tr","a":{"a":0,"k":[0,0]},"s":{"a":0,"k":[100,100]},"sk":{"a":0,"k":0},"p":{"a":0,"k":[0,0]},"r":{"a":0,"k":0},"sa":{"a":0,"k":0},"o":{"a":0,"k":100}}]},{"ty":"gr","bm":0,"hd":false,"nm":"Group 9","np":2,"it":[{"ty":"sh","bm":0,"hd":false,"nm":"Path 9","d":1,"ks":{"a":0,"k":{"c":true,"i":[[0,0],[0.32,-10.83],[0.22,-1.08],[1.92,-0.01],[0,0],[1.42,-1.97],[0.07,-2.75],[0.39,-1.65],[1.02,-1.29],[1.22,0],[0,0],[0.08,0.05],[0,0],[0,0],[0,0],[0,0],[-0.1,-0.02],[0,0],[0,0],[0,0],[0,0],[-0.75,0.92],[-0.81,3.45],[-0.06,2.3],[-1.05,1.47],[-0.86,0.46],[-0.11,0.06],[-0.1,0.04],[-0.1,0.04],[-0.22,0.05],[-0.29,0.01],[-0.02,0],[0,0],[0,0],[0,0],[0,0],[-0.76,1.82],[-0.07,1.33],[-0.47,1.72],[-0.82,1.34],[-0.15,0.41],[-0.06,0.16],[-0.1,0.18],[-0.08,0.16],[-0.08,0.14],[-0.08,0.12],[-0.07,0.11],[0,0],[0,0],[0,0],[0.22,-0.19],[0,0]],"o":[[-1.63,1.38],[-0.04,1.31],[-0.37,1.75],[0,0],[-1.65,0.02],[-1.05,1.47],[-0.07,2.29],[-0.81,3.45],[-0.73,0.9],[0,0],[-0.11,-0.01],[0,0],[0,0],[0,0],[0,0],[0.08,0.05],[0,0],[0,0],[0,0],[0,0],[1.24,0.03],[1.03,-1.28],[0.4,-1.67],[0.08,-2.74],[0.7,-0.96],[0.11,-0.06],[0.1,-0.05],[0.1,-0.04],[0.23,-0.08],[0.32,-0.07],[0.01,-0.01],[0,0],[0,0],[0,0],[0,0],[1.97,0.05],[0.47,-1.09],[0.11,-2.27],[0.57,-2],[0.29,-0.46],[0.07,-0.
217],[0.09,-0.21],[0.08,-0.16],[0.08,-0.15],[0.08,-0.15],[0.07,-0.13],[0,0],[0,0],[0,0],[0.17,0.17],[0,0],[0,0]],"v":[[67.66,18.6],[63.19,34.71],[62.78,38.29],[58.83,41.31],[48.28,41.08],[43.24,43.95],[41.36,50.2],[40.62,56.12],[37.47,63.04],[34.36,64.45],[7.72,63.83],[7.44,63.75],[7.31,63.65],[7.29,63.63],[0.22,57.55],[0.22,57.47],[0.48,57.55],[6.91,57.7],[10.35,57.78],[27.1,58.16],[30.46,58.25],[31.65,56.83],[34.8,49.92],[35.54,44],[37.42,37.75],[41.8,35.63],[42.13,35.47],[42.41,35.33],[42.7,35.22],[43.37,35.02],[44.28,34.89],[44.34,34.89],[45.99,34.92],[49.7,35],[51.7,35.06],[54.9,35.13],[57,32.25],[57.83,28.64],[58.75,22.68],[60,16.75],[61,15.25],[61,14.75],[61.5,14.75],[62,14.25],[62.5,13.75],[62.5,13.25],[63,13.25],[66.35,16.84],[67.59,17.92],[67.66,17.97],[67.63,18.63],[67.66,18.6]]}}},{"ty":"fl","bm":0,"hd":false,"nm":"Fill","c":{"a":0,"k":[0.0196,0.4588,0.2706]},"r":1,"o":{"a":0,"k":100}},{"ty":"tr","a":{"a":0,"k":[0,0]},"s":{"a":0,"k":[100,100]},"sk":{"a":0,"k":0},"p":{"a":0,"k":[0,0]},"r":{"a":0,"k":0},"sa":{"a":0,"k":0},"o":{"a":0,"k":100}}]}],"ind":1}],"w":76,"h":81},{"nm":"Group 513681","id":"precomp_Shape Layer - SVG_XGn1X-uVPx_24c5de1a-9871-454c-84d6-332198e02dab","fr":30,"layers":[{"ty":4,"nm":"Shape Layer 4","sr":1,"st":0,"op":150,"ip":0,"hd":false,"ddd":0,"bm":0,"hasMask":false,"ao":0,"ks":{"a":{"a":0,"k":[24.21904891167936,25.23227846847584]},"s":{"a":0,"k":[100,100]},"sk":{"a":0,"k":0},"p":{"a":0,"k":[21.44095193372978,18.17813594483889]},"r":{"a":0,"k":0},"sa":{"a":0,"k":0},"o":{"a":0,"k":100}},"shapes":[{"ty":"gr","bm":0,"hd":false,"nm":"Group 10","np":2,"it":[{"ty":"sh","bm":0,"hd":false,"nm":"Path 10","d":1,"ks":{"a":0,"k":{"c":true,"i":[[0,0],[2.16,-0.37],[0.69,2.99],[0.04,0.38],[1.92,-0.15],[-0.87,3.59],[1.34,-0.11],[-0.01,0.06],[0.64,-0.11],[-3.92,5.25],[-6.18,7],[-3.29,7.81],[0,0],[0,0],[-6.29,1.9],[-1.05,-6.16],[-2.64,-5.07],[0,0]],"o":[[-0.51,0.37],[-1.83,0.29],[-0.06,-0.33],[0,0],[-1.41,-0.67],[0,0],[0,-0.04],[0,0],[-2.8,0.04],[0,0],[0,0],[0,0],[0,0],[0.39,-0.31],[3.19,1.45],[1.65,9.48],[0,0],[0,0]],"v":[[34.7,40.22],[29.8,42.58],[25.48,39.31],[25.3,38.25],[21.53,39.19],[20.16,33.27],[17.7,33.66],[17.73,33.51],[16.67,33.71],[14.9,27.58],[9.82,23.43],[5.34,18],[7.89,15.3],[8.09,15.09],[21.03,7.73],[27.78,18.62],[34.68,40.19],[34.7,40.22]]}}},{"ty":"fl","bm":0,"hd":false,"nm":"Fill","c":{"a":0,"k":[0.4706,0.4902,1]},"r":1,"o":{"a":0,"k":100}},{"ty":"tr","a":{"a":0,"k":[0,0]},"s":{"a":0,"k":[100,100]},"sk":{"a":0,"k":0},"p":{"a":0,"k":[0,0]},"r":{"a":0,"k":0},"sa":{"a":0,"k":0},"o":{"a":0,"k":100}}]},{"ty":"gr","bm":0,"hd":false,"nm":"Group 11","np":2,"it":[{"ty":"sh","bm":0,"hd":false,"nm":"Path 11","d":1,"ks":{"a":0,"k":{"c":true,"i":[[0,0],[-4.9,6.22],[-5.88,6.35],[-3.13,7.1],[0,0],[0,0],[0,0],[0,0],[-2.81,0.05],[0,0]],"o":[[-2.61,0.4],[0,0],[0,0],[0,0],[0,0],[-3.29,7.81],[-6.18,7],[-3.92,5.25],[0,0],[0,0]],"v":[[16.64,33.74],[12.68,28.39],[7.82,24.61],[3.55,19.68],[7.86,15.32],[5.32,18.02],[9.8,23.45],[14.88,27.6],[16.65,33.73],[16.64,33.74]]}}},{"ty":"fl","bm":0,"hd":false,"nm":"Fill","c":{"a":0,"k":[0.6784,0.6902,1]},"r":1,"o":{"a":0,"k":100}},{"ty":"tr","a":{"a":0,"k":[0,0]},"s":{"a":0,"k":[100,100]},"sk":{"a":0,"k":0},"p":{"a":0,"k":[0,0]},"r":{"a":0,"k":0},"sa":{"a":0,"k":0},"o":{"a":0,"k":100}}]},{"ty":"gr","bm":0,"hd":false,"nm":"Group 12","np":2,"it":[{"ty":"sh","bm":0,"hd":false,"nm":"Path 12","d":1,"ks":{"a":0,"k":{"c":true,"i":[[0,0],[4.82,7.22],[0.08,-0.06],[1.64,9.49],[3.18,1.44],[-1.54,-8.87],[0,0],[0,0]],"o":[[0,0],[0,0],[-2.65,-5.08],[-1.07,-6.16],[5.53,-1.68],[3.35,19.22],[0,0],[0,0]],"v":[[45.66,40.4],[34.79,40.13],[34.69,40.22],[27.78,18.65],[21.03,7.76],[33.63,15.77],[45.65,40.41],[45.66,40.4]]}}},{"ty":"fl","bm":0,"hd":false,"nm":"Fill","c":{"a":0,"k":[0.1804,0.3098,0.9294]},"r":1,"o":{"a":0,"k":100}},{"ty":"tr","a":{"a":0,"k":[0,0]},"s":{"a":0,"k":[100,100]},"sk":{"a":0,"k":0},"p":{"a":0,"k":[0,0]},"r":{"a":0,"k":0},"sa":{"a":0,"k":0},"o":{"a":0,"k":100}}]}],"ind":1}],"w":56,"h":53}]}')},626621,e=>{"use strict";var t=e.i(271645);let a=(0,t.createContext)({showSkeleton:!1,animation:"none"}),r=a.Provider;e.s(["CashoutSkeletonProvider",0,r,"useCashoutSkeleton",0,()=>(0,t.useContext)(a)])},32305,e=>{"use strict";let t,a;var r,s=e.i(843476),n=e.i(570318),i=e.i(304868),l=e.i(413107),o=e.i(675803),c=e.i(355424),d=e.i(542017),u=e.i(944378),m=e.i(866622),h=e.i(68119),p=e.i(382574),x=e.i(944316);function f({onClick:e}){let{withdrawableNowBalance:t,isLoading:a}=(0,x.default)(),{t:r}=(0,p.default)("_cashout");return(0,s.jsx)("button",{type:"button",className:"cursor-pointer border-0 bg-transparent p-0 text-core-freecashGreen-500",onClick:()=>{a||void 0===t||e(t)},children:r("maxAmount")})}var g=e.i(344298),y=e.i(955592),b=e.i(350844),v=e.i(780007),w=e.i(964913),C=e.i(630868),j=e.i(718628),k=e.i(420786);
2let N="/public/img/earn/global.svg",S="/public/img/flags/round-flags/us.svg";function F({name:e,value:t,checked:a,onChange:r,children:n}){return(0,s.jsxs)("label",{className:"flex cursor-pointer items-center",children:[(0,s.jsx)("input",{className:"sr-only",type:"radio",name:e,value:t,checked:a,onChange:()=>r(t)}),(0,s.jsx)("div",{className:(0,w.cn)("flex h-[20px] w-[20px] items-center justify-center rounded-[10px] border border-solid bg-transparent",a?"border-core-freecashGreen-500":"border-core-neutral-0"),children:(0,s.jsx)("div",{className:(0,w.cn)("h-[14px] w-[14px] rounded-[9px] border border-solid border-transparent hover:bg-core-freecashGreen-500",a?"bg-core-freecashGreen-500":"bg-transparent")})}),n]})}function T({stakeBonus:e,flag:t}){let{t:a}=(0,C.useTranslationTyped)(["_common","_cashout"]);return(0,s.jsxs)("div",{className:"flex ml-[10px] items-center",children:[(0,s.jsxs)("span",{className:"m-0 text-core-neutral-0",children:["Stake",void 0===t&&(0,s.jsx)("span",{className:"m-0 hidden md:inline",children:" username"}),t===N&&".com",t===S&&".us"]}),t&&(0,s.jsx)("img",{className:"ml-[10px] h-[20px] w-[20px]",src:t}),"number"==typeof e&&e>0&&(0,s.jsx)("span",{className:"m-0 text-core-freecashGreen-500 text-[12px] ml-[10px]",children:a("withdraw.stake.bonus",{discount:e})})]})}function E({formType:e,onSelect:t}){let[{selectedMethod:a}]=(0,v.useRecoilState)(m.default),r=(0,j.useFeatureFlags)(e=>e.isStakeUSEnabled),{stakeBonus:n,stakeUSBonus:i}=(0,k.useStakeBonus)(),l=e=>{t(e)},o=r?["standard","stakeUS","stake"]:["standard","stake"];return(0,s.jsx)("div",{role:"radiogroup",className:"flex flex-col md:flex-row justify-around md:justify-start gap-[10px] md:gap-[30px]",children:o.map(t=>(0,s.jsxs)("div",{className:"flex gap-[10px]",children:["standard"===t&&(0,s.jsx)(F,{name:"methods",value:t,checked:e===t,onChange:l,children:(0,s.jsxs)("span",{className:"m-0 text-core-neutral-0 ml-[10px]",children:[a," address"]})}),"stake"===t&&(0,s.jsxs)(F,{name:"methods",value:t,checked:e===t,onChange:l,children:[r&&(0,s.jsx)(T,{stakeBonus:n,flag:N}),!r&&(0,s.jsx)(T,{stakeBonus:n})]}),"stakeUS"===t&&(0,s.jsx)(F,{name:"methods",value:t,checked:e===t,onChange:l,children:(0,s.jsx)(T,{stakeBonus:i||0,flag:S})})]},t))})}var A=e.i(293653),R=e.i(158081);function M(e){switch(e){case"bitcoin":return"BTC";case"ether":return"ETH";case"litecoin":return"LTC";case"dogecoin":return"DOGE";case"ripple":return"XRP";case"tron":return"TRX";case"bitcoincash":return"BCH";case"eos":return"EOS";case"tether":return"USDT";case"sol":return"SOL";default:return""}}let _=e=>{switch(e){case"bitcoin":return R.Currencies.Btc;case"ether":return R.Currencies.Eth;case"litecoin":return R.Currencies.Ltc;case"dogecoin":return R.Currencies.Doge;case"ripple":return R.Currencies.Xrp;case"tron":return R.Currencies.Trx;case"bitcoincash":return R.Currencies.Bch;case"eos":return R.Currencies.Eos;case"tether":return R.Currencies.Usdt;default:return null}};var I=e.i(227406),P=e.i(212977),B=e.i(68411),U=e.i(812497),O=e.i(271645),G=e.i(499683),L=e.i(724325),D=e.i(92743);function V(){return(0,s.jsxs)("svg",{width:"16",height:"17",viewBox:"0 0 16 17",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,s.jsx)("rect",{y:"0.5",width:"16",height:"16",rx:"8",fill:(0,n.resolveColorToken)("core.freecashGreen.500")}),(0,s.jsx)("path",{d:"M4.5 11.6154L5.49273 10.2046C6.09091 10.8447 7.02 11.3803 8.19091 11.3803C9.18364 11.3803 9.66727 10.897 9.66727 10.4006C9.66727 9.74746 8.92909 9.5254 7.94909 9.29028C6.56182 8.96372 4.78 8.57184 4.78 6.62554C4.78 5.17562 6.00182 4 8 4C9.34909 4 10.4691 4.418 11.3091 5.2148L10.3036 6.57329C9.61636 5.92017 8.7 5.61974 7.87273 5.61974C7.05818 5.61974 6.62545 5.98549 6.62545 6.50798C6.62545 7.09579 7.33818 7.27866 8.31818 7.51379C9.71818 7.84035 11.5 8.27141 11.5 10.2046C11.5 11.7983 10.3927 13 8.10182 13C6.47273 13 5.30182 12.4383 4.5 11.6154Z",fill:(0,n.resolveColorToken)("core.yellow.900")})]})}var W=e.i(453415),K=e.i(892251),z=e.i(675985),H=e.i(954616),q=e.i(266027),$=e.i(912598);function Q(){let e=(0,j.useFeatureFlags)(e=>e.isStakeUSEnabled),t=(0,$.useQueryClient)(),{isLoggedIn:a}=(0,z.default)(),{data:r,isFetched:s}=(0,q.useQuery)({queryKey:[i.QueryKeys.GRAPHQL_GET_USER_STAKE_WITHDRAWAL_PREFERENCES],queryFn:()=>K.default.cashout.getUserStakeWithdrawalPreferences(R.Currencies.StakeCash),enabled:a}),n=r?.data?.getUserStakeWithdrawalPreferences,l=n?{stakePreference:n.stakePreference,hasSetStakePreference:n.hasSetStakePreference,conversionRate:n.conversionRate}:void 0,o=e&&n?.stakePreference?n.stakePreference:R.StakeProvider.StakeCom,{mutate:c}=(0,H.useMutation)({mutationKey:[i.QueryKeys.GRAPHQL_UPDATE_STAKE_PREFERENCE],mutationFn:e=>K.default.cashout.updateUserDefaultStakeProvider(e),onSuccess:()=>{t.invalidateQueries({queryKey:[i.QueryKeys.GRAPHQL_GET_USER_STAKE_WITHDRAWAL_PREFERENCES]})}});return{isFetched:s,isStakeUSEnabled:e,stakeSettings:l,defaultStakeTab:o,updateStakePreference:c,stakePreference:l?.stakePreference,hasSetStakePreference:l?.hasSetStakePreference,conversionRate:l?.conversionRate}}var Z=e.i(526917),Y=e.i(966396);function X({stakeBonus:e,conversionRate:t}){let{values:a}=(0,U.useFormikContext)(),[r,n]=(0,O.useState)(0),[i,l]=(0,O.useState)(0),{t:o}=(0,C.useTranslationTyped)(["_cashout","_common"]);return(0,O.useEffect)(()=>
2{let r=(0,P.usdToCoins)(a.amountInCoins)||0,s=r*(e||0)/100,i=(r-0+s)/1e3/t;n(Number(i)>0?i:0),l(s)},[a.amountInCoins]),(0,s.jsxs)(s.Fragment,{children:[(e??0)>0&&(0,s.jsxs)("div",{className:"flex justify-between w-full items-center",children:[(0,s.jsxs)("div",{className:"flex gap-[8px] items-center",children:[(0,s.jsx)("p",{className:"m-0 text-core-greyBlue-50 text-sm whitespace-nowrap",children:o("withdraw.stake.form.labels.bonus")}),(0,s.jsxs)("div",{className:"bg-core-freecashGreen-25-A10 p-[2px_4px] md:p-[4px_8px] rounded-[4px] text-core-freecashGreen-400",children:[e,"%"]})]}),(0,s.jsx)("div",{className:"m-0 text-sm text-core-greyBlue-50",children:(0,s.jsx)(B.default,{coins:i,hideUsdIcon:!0})})]}),(0,s.jsx)("div",{className:"flex justify-between w-full items-center",children:(0,s.jsxs)("div",{className:"flex justify-between w-full",children:[(0,s.jsx)("div",{className:"m-0 text-[16px] text-core-neutral-0 font-semibold",children:o("stakeUs.modal.form.youReceived")}),(0,s.jsxs)("div",{className:"flex gap-[5px] items-center",children:[(0,s.jsx)("div",{className:"flex size-[14px] items-center",children:(0,s.jsx)(V,{})}),(0,s.jsx)("span",{className:"m-0 text-core-neutral-0 font-semibold",children:r})]})]})})]})}function J(e){let{isFetched:t,stakeSettings:a}=Q(),{stakeUSBonus:r}=(0,k.useStakeBonus)(),{withdrawMinimums:n}=(0,A.default)(),{t:i}=(0,C.useTranslationTyped)(["_cashout","_common"]),{link:l}=(0,Y.useStakeOfferLink)({selectedProvider:R.StakeProvider.StakeUs}),o=G.object().shape({stakeUserName:G.string().required(),amountInCoins:G.number().positive(i("validations.invalidAmount")||"Invalid amount").required(i("validations.amountRequired")||"Required")}),d=async e=>{try{return await o.validate(e,{abortEarly:!1}),{}}catch(e){return e}};if(!t||!a)return null;let u=a.conversionRate,m=n.stakeMinimums.minStakeCashWithdraw;return(0,s.jsx)("div",{className:"w-full",children:(0,s.jsx)(U.Formik,{initialValues:{stakeUserName:e.initValues?.stakeUserName,amountInCoins:e.initValues?.amountInCoins||0},validationSchema:o,onSubmit:t=>{e.onSubmit({...t,amountInCoins:(0,P.usdToCoins)(t.amountInCoins)})},validateOnBlur:!1,validateOnChange:!0,validate:d,children:({isValid:t,errors:n,values:o,setFieldValue:d})=>(0,s.jsxs)(U.Form,{children:[(0,s.jsxs)("div",{className:"flex flex-col mb-[15px] gap-[10px]",children:[(0,s.jsxs)("div",{className:"my-6",children:[(0,s.jsx)("label",{htmlFor:"stakeUserName",className:"m-0 text-core-neutral-0 mb-[6px] block text-md",children:i("stakeUs.modal.form.usernameLabel")}),(0,s.jsxs)("div",{className:"grid grid-cols-1 md:grid-cols-[3fr_minmax(145px,auto)] gap-[10px]",children:[(0,s.jsx)("div",{className:"relative w-full",children:(0,s.jsx)(U.Field,{...I.fieldStyle,...n?.stakeUserName&&I.errorFieldStyle,color:"core.neutral.0",fontSize:"16px",type:"text",name:"stakeUserName",placeholder:i("withdraw.stake.form.labels.placeholder"),id:"stakeUserName",as:b.default})}),(0,s.jsx)(g.Button,{variant:"primary",size:"lg",onClick:()=>{e.onSaveUserName&&e.onSaveUserName(o.stakeUserName)},children:i("saveUserName")})]}),(0,s.jsx)("div",{className:"m-0 text-core-greyBlue-50 mt-2 text-[12px]",children:(0,s.jsx)(Z.Trans,{t:i,i18nKey:"stakeUs.modal.form.noStakeAccount",components:{em:(0,s.jsx)(W.default,{href:l})}})})]}),(0,s.jsxs)("div",{className:"my-6",children:[(0,s.jsx)("label",{htmlFor:"amountInCoins",className:"m-0 text-core-neutral-0 mb-[6px] block text-md",children:i("amountInUsd")}),(0,s.jsxs)("div",{className:"grid grid-cols-1 md:grid-cols-[3fr_minmax(145px,auto)] gap-[10px]",children:[(0,s.jsxs)("div",{className:"relative w-full",children:[(0,s.jsx)(U.Field,{...I.numberFieldStyle,...n?.amountInCoins&&I.errorFieldStyle,className:"placeholder:text-sm placeholder:font-[400] placeholder:tracking-[-0.03em] focus:placeholder:text-transparent",type:"number",name:"amountInCoins",placeholder:i("amountPlaceholder"),id:"amountInCoins",as:b.default}),(0,s.jsx)("div",{className:"absolute top-0 right-0 z-2 flex h-[48px] min-w-fit items-center justify-end",children:(0,s.jsx)(f,{onClick:e=>{d("amountInCoins",(0,P.coinsToUsd)(e))}})})]}),(0,s.jsxs)("div",{className:"flex bg-core-greyBlue-400 rounded-[8px] items-center font-bold p-[0_16px] justify-between min-h-[48px] gap-[8px]",children:[(0,s.jsx)("div",{className:"m-0",children:(0,P.formatDollarDigit)(u,!1,2,2)}),(0,s.jsxs)("div",{className:"flex items-center gap-[8px]",children:[(0,s.jsx)("div",{className:"m-0 text-[#F7931A] text-[30px]",children:"·"}),(0,s.jsx)("div",{className:"m-0",children:"Stake Cash"})]})]})]}),(0,s.jsxs)("div",{className:"flex items-center gap-[10px] mt-2",children:[(0,s.jsx)(y.default,{fill:"none",...n?.amountInCoins&&I.errorIconStyle}),(0,s.jsx)("div",{className:(0,w.cn)("m-0 text-core-greyBlue-50 text-[12px]",n?.amountInCoins&&"text-core-red-700"),children:(0,s.jsx)(c.default,{i18nKey:"_cashout:withdraw.stake.form.labels.minimumAmount",minimum:m})})]})]})]}),(0,s.jsx)("div",{className:"border-t-2 border-dashed border-highlight-purple-900 my-[24px]"}),(0,s.jsxs)("div",{className:"grid grid-cols-1 md:grid-cols-[300px_1fr] items-center",children:[(0,s.jsx)("div",{className:"flex flex-col gap-[4px]",children:(0,s.jsx)(X,{stakeBonus:r||0,conversionRate:a.conversionRate})}),(0,s.jsx)("div",{className:"flex justify-end mt-[24px] md:mt-0",children:(0,s.jsx)("div",{className:"w-full md:max-w-[300px]",children:(0,s.jsx)(g.Button,{variant:"primary",size:"lg",type:"submit",isLoading:e.isLoading,disabled:!t,width:"full",children:i("stakeUs.modal.form.cta")})})})]})]})})})}
2function ee(e,t){switch(e){case h.Bitcoin:return t?.bitcoin?.dollarPrice||0;case h.Ethereum:return t?.ether?.dollarPrice||0;case h.Litecoin:return t?.litecoin?.dollarPrice||0;case h.Dogecoin:return t?.dogecoin?.dollarPrice||0;default:return 0}}function et({isStake:e}){let[{selectedMethod:t}]=(0,v.useRecoilState)(m.default),{stakeBonus:a}=(0,k.useStakeBonus)(),{t:r}=(0,C.useTranslationTyped)(["_cashout","_common"]),{values:n}=(0,U.useFormikContext)(),[i,l]=(0,O.useState)(0),[o,c]=(0,O.useState)(0),[d,u]=(0,O.useState)(0),{cryptoData:p}=(0,A.default)();return(0,O.useEffect)(()=>{if(!t)return;let r=(0,P.usdToCoins)(n.amountInCoins)||0,s=e?0:function(e,t){switch(e){case h.Bitcoin:return t?.bitcoin?.coinFee||0;case h.Ethereum:return t?.ether?.coinFee||0;case h.Litecoin:return t?.litecoin?.coinFee||0;case h.Dogecoin:return t?.dogecoin?.coinFee||0;default:return 0}}(t,p),i=e?r*(a||0)/100:0,o=((r-s+i)/1e3/ee(t,p)).toFixed(8),d=Number(o)>0?o:0;u(s),l(d),c(i)},[n.amountInCoins,a,p,t,e]),(0,s.jsxs)("div",{children:[e&&(a??0)>0&&(0,s.jsx)(s.Fragment,{children:(0,s.jsxs)("div",{className:"flex justify-between w-full",children:[(0,s.jsxs)("div",{className:"m-0 text-sm text-core-freecashGreen-500",children:[r("bonus")," ",a,"%"]}),(0,s.jsx)("div",{className:"m-0 text-sm text-core-greyBlue-50",children:(0,s.jsx)(B.default,{coins:o,hideUsdIcon:!0})})]})}),!e&&(0,s.jsx)(s.Fragment,{children:(0,s.jsxs)("div",{className:"flex justify-between w-full",children:[(0,s.jsx)("div",{className:"m-0 text-sm text-core-greyBlue-50",children:r("fee")}),(0,s.jsx)("div",{className:"m-0 text-sm text-core-greyBlue-50",children:(0,s.jsx)(B.default,{coins:Math.ceil(d),hideUsdIcon:!0})})]})}),(0,s.jsxs)("div",{className:"flex justify-between w-full",children:[(0,s.jsx)("div",{className:"m-0 text-[16px] text-core-neutral-0 font-semibold",children:r("withdraw.stake.form.labels.youReceive",{crypto:t})}),(0,s.jsxs)("div",{className:"flex gap-[5px] items-center",children:[(0,s.jsx)("div",{className:"flex size-[10px] items-center",children:t&&(0,s.jsx)(D.default,{name:t.toLowerCase()})}),(0,s.jsx)("span",{className:"m-0 text-core-neutral-0 font-semibold",children:i})]})]})]})}function ea(e){let[{selectedMethod:t}]=(0,v.useRecoilState)(m.default),{t:a}=(0,C.useTranslationTyped)(["_cashout","_common"]),{cryptoData:r,withdrawMinimums:n}=(0,A.default)(),{initValues:i}=e,l=G.object().shape({stakeUserName:G.string().required(),amountInCoins:G.number().positive(a("validations.invalidAmount")||"Invalid amount").required(a("validations.amountRequired")||"Required")});return t?(0,s.jsx)("div",{className:"w-full",children:(0,s.jsx)(U.Formik,{initialValues:{stakeUserName:i?.stakeUserName,amountInCoins:i?.amountInCoins||0},validationSchema:l,onSubmit:t=>{e.onSubmit({...t,submitType:"stake",amountInCoins:(0,P.usdToCoins)(t.amountInCoins)})},validateOnBlur:!1,validateOnChange:!0,validate:(0,u.handleValidate)(l,{isInline:!1,onSubmit:e.onSubmit}),children:({isValid:i,errors:l,values:o,setFieldValue:d})=>(0,s.jsxs)(U.Form,{children:[(0,s.jsxs)("div",{className:"flex flex-col mb-[15px] gap-[10px]",children:[(0,s.jsxs)("div",{className:"my-6",children:[(0,s.jsx)("label",{htmlFor:"stakeUserName",className:"block m-0 mb-[6px] text-core-neutral-0",children:a("withdraw.stake.form.labels.usernameLabel")}),(0,s.jsxs)("div",{className:"grid grid-cols-[1fr] md:grid-cols-[1fr_auto] gap-[10px]",children:[(0,s.jsx)("div",{className:"relative w-full",children:(0,s.jsx)(U.Field,{...I.textFieldStyle,...l?.stakeUserName&&I.errorFieldStyle,type:"text",name:"stakeUserName",placeholder:a("withdraw.stake.form.labels.placeholder"),id:"stakeUserName",as:b.default,className:"placeholder:text-sm placeholder:font-[400] placeholder:tracking-[-0.03em]"})}),(0,s.jsx)(g.Button,{variant:"primary",size:"lg",onClick:()=>{e.onSaveStakeUsername&&o.stakeUserName&&e.onSaveStakeUsername(o.stakeUserName)},children:a("saveUserName")})]}),(0,s.jsx)("div",{className:(0,w.cn)("m-0 mt-[8px] text-[12px] font-normal text-core-greyBlue-100",l?.stakeUserName&&"text-core-red-700"),children:a("withdraw.stake.form.labels.usernameExplanation")})]}),(0,s.jsxs)("div",{className:"my-6",children:[(0,s.jsx)("label",{htmlFor:"amountInCoins",className:"block m-0 mb-[6px] text-core-neutral-0",children:a("amountInUsd")}),(0,s.jsxs)("div",{className:"grid grid-cols-[1fr] md:grid-cols-[1fr_auto] gap-[10px]",children:[(0,s.jsxs)("div",{className:"relative w-full",children:[(0,s.jsx)(U.Field,{...I.numberFieldStyle,...l?.amountInCoins&&I.errorFieldStyle,type:"number",name:"amountInCoins",placeholder:a("amountPlaceholder"),id:"amountInCoins",as:b.default,className:"placeholder:text-sm placeholder:font-[400] placeholder:tracking-[-0.03em] focus:placeholder:text-[#0000]"}),(0,s.jsx)("div",{className:"absolute top-0 right-0 z-2 flex h-[48px] min-w-fit items-center justify-end",children:(0,s.jsx)(f,{onClick:e=>{d("amountInCoins",(0,P.coinsToUsd)(e))}})})]}),(0,s.jsxs)("div",{className:"flex bg-core-greyBlue-400 rounded-[8px] items-center font-bold p-[0_16px] justify-between gap-[8px]",children:[(0,s.jsx)("div",{className:"m-0",children:(0,P.formatDollarDigit)(ee(t,r),!1,2,4)}),(0,s.jsxs)("div",{className:"flex items-center gap-[8px]",children:[(0,s.jsx)("div",{className:"m-0 text-[#F7931A] text-[30px]",children:"·"}),(0,s.jsxs)("div",{className:"m-0",children:["ethereum"===t.toLowerCase()?M("ether"):M(t.toLowerCase())," ","rate"]})]})]})]}),(0,s.jsxs)("div",{className:"flex items-center gap-[10px] mt-2",children:[(0,s.jsx)(y.default,{fill:"none",...l?.amountInCoins&&I.errorIconStyle}),(0,s.jsx)("div",{className:(0,w.cn)("m-0 text-core-greyBlue-50 text-[12px]",l?.amountInCoins&&"text-core-red-700"),children:(0,s.jsx)(c.default,{i18nKey:"_cashout:minimumAmount",minimum:(0,u.getCryptoMinimumWithdraw)(t,n,!0)})})]})]})]}),(0,s.jsx)("div",{className:"border-t-2 border-dashed border-highlight-purple-900 my-6"}),(0,s.jsxs)("div",{className:"grid grid-cols-[1fr] md:grid-cols-[350px_1fr] gap-[10px] md:gap-0",children:[(0,s.jsx)("div",{children:(0,s.jsx)(et,{isStake:!0})}),(0,s.jsx)("div",{className:"flex justify-end",children:(0,s.jsx)("div",{className:"w-full md:max-w-[300px]",children:(0,s.jsx)(g.Button,{variant:"primary",size:"lg",type:"submit",isLoading:e.isLoading,disabled:!i,width:"full",children:a("withdraw")})})})]})]})})}):null}function er(e){let[{selectedMethod:t}]=(0,v.useRecoilState)(m.default),{t:a}=(0,C.useTranslationTyped)(["_cashout","_common"]),{cryptoData:r,withdrawMinimums:n}=(0,A.default)(),{initValues:i}=e,l=G.object().shape({cryptoAddress:G.string().required(),amountInCoins:G.number().positive(a("validations.invalidAmount")||"Invalid amount").required(a("validations.amountRequired")||"Required")});return t?(0,s.jsx)("div",{className:"w-full",children:(0,s.jsx)(U.Formik,{initialValues:{cryptoAddress:i?.cryptoAddress,amountInCoins:i?.amountInCoins||0},validationSchema:l,onSubmit:t=>{e.onSubmit({...t,submitType:"crypto",amountInCoins:(0,P.usdToCoins)(t.amountInCoins)})},validateOnBlur:!1,validateOnChange:!0,validate:(0,u.handleValidate)(l,{isInline:!1,onSubmit:e.onSubmit}),children:({isValid:i,errors:l,values:o,setFieldValue:d})=>(0,s.jsxs)(U.Form,{children:[(0,s.jsxs)("div",{className:"flex flex-col mb-[15px] gap-[10px]",children:[(0,s.jsxs)("div",{className:"my-6",children:[(0,s.jsx)("label",{htmlFor:"cryptoAddress",className:"block m-0 mb-[6px] text-core-neutral-0",children:a("withdraw.bitcoin.form.labels.addressLabel",{method:t})}),(0,s.jsxs)("div",{className:"grid grid-cols-[1fr] md:grid-cols-[1fr_auto] gap-[10px]",children:[(0,s.jsx)("div",{className:"relative w-full",children:(0,s.jsx)(U.Field,{...I.textFieldStyle,...l?.cryptoAddress&&I.errorFieldStyle,type:"text",name:"cryptoAddress",placeholder:a("withdraw.bitcoin.form.labels.addressPlaceholder",{method:t}),id:"cryptoAddress",as:b.default,className:"placeholder:text-sm placeholder:font-[400] placeholder:tracking-[-0.03em]"})}),(0,s.jsx)(g.Button,{variant:"primary",size:"lg",onClick:()=>{e.onSaveCryptoAddress&&o.cryptoAddress&&e.onSaveCryptoAddress(o.cryptoAddress)},children:a("saveAddress")})]}),(0,s.jsx)("div",{className:(0,w.cn)("m-0 mt-[8px] text-[12px] font-normal text-core-greyBlue-100",l?.cryptoAddress&&"text-core-red-700"),children:a("withdraw.bitcoin.form.labels.addressExplanation",{method:t})})]}),(0,s.jsxs)("div",{className:"my-6",children:[(0,s.jsx)("label",{htmlFor:"amountInCoins",className:"block m-0 mb-[6px] text-core-neutral-0",children:a("amountInUsd")}),(0,s.jsxs)("div",{className:"grid grid-cols-[1fr] md:grid-cols-[1fr_auto] gap-[10px]",children:[(0,s.jsxs)("div",{className:"relative w-full",children:[(0,s.jsx)(U.Field,{...I.numberFieldStyle,...l?.amountInCoins&&I.errorFieldStyle,type:"number",name:"amountInCoins",placeholder:a("amountPlaceholder"),id:"amountInCoins",as:b.default,className:"placeholder:text-sm placeholder:font-[400] placeholder:tracking-[-0.03em] focus:placeholder:text-[#0000]"}),(0,s.jsx)("div",{className:"absolute top-0 right-0 z-2 flex h-[48px] min-w-fit items-center justify-end",children:(0,s.jsx)(f,{onClick:e=>{d("amountInCoins",(0,P.coinsToUsd)(e))}})})]}),(0,s.jsxs)("div",{className:"flex bg-core-greyBlue-400 rounded-[8px] items-center font-bold p-[0_16px] justify-between min-h-[48px] gap-[8px]",children:[(0,s.jsx)("div",{className:"m-0",children:(0,P.formatDollarDigit)(ee(t,r),!1,2,4)}),(0,s.jsxs)("div",{className:"flex items-center gap-[8px]",children:[(0,s.jsx)("div",{className:"m-0 text-[#F7931A] text-[30px]",children:"·"}),(0,s.jsxs)("div",{className:"m-0",children:["ethereum"===t.toLowerCase()?M("ether"):M(t.toLowerCase())," ","rate"]})]})]})]}),(0,s.jsxs)("div",{className:"flex items-center gap-[10px] mt-2",children:[(0,s.jsx)(y.default,{fill:"none",...l?.amountInCoins&&I.errorIconStyle}),(0,s.jsx)("div",{className:(0,w.cn)("m-0 text-core-greyBlue-50 text-[12px]",l?.amountInCoins&&"text-core-red-700"),children:(0,s.jsx)(c.default,{i18nKey:"_cashout:minimumAmount",minimum:function(e,t){switch(e){case h.Bitcoin:return t?.bit
2coin?.minimumCashoutAmount;case h.Ethereum:return t?.ether?.minimumCashoutAmount;case h.Litecoin:return t?.litecoin?.minimumCashoutAmount;case h.Dogecoin:return t?.dogecoin?.minimumCashoutAmount;default:return null}}(t,r)??(0,u.getCryptoMinimumWithdraw)(t,n,!1)})})]})]})]}),(0,s.jsx)("div",{className:"border-t-2 border-dashed border-highlight-purple-900 my-6"}),(0,s.jsxs)("div",{className:"grid grid-cols-[1fr] md:grid-cols-[350px_1fr] gap-[10px] md:gap-0",children:[(0,s.jsx)("div",{children:(0,s.jsx)(et,{isStake:!1})}),(0,s.jsx)("div",{className:"flex justify-end",children:(0,s.jsx)("div",{className:"w-full md:max-w-[300px]",children:(0,s.jsx)(g.Button,{variant:"primary",size:"lg",type:"submit",isLoading:e.isLoading,disabled:!i,width:"full",children:a("withdraw")})})})]})]})})}):null}function es(e){let{t}=(0,C.useTranslationTyped)(["_common","_cashout"]),[a,r]=(0,O.useState)("standard"),n=(0,L.useIsStakeCashoutEnabled)();return(0,s.jsxs)("div",{children:[(0,s.jsx)(d.default,{}),(0,s.jsxs)("div",{className:"m-0 text-core-greyBlue-50 my-6",children:["standard"===a&&t("cryptoWithdrawalDelayWarning",{amount:"$20"}),"stake"===a&&t("withdraw.stake.modal.description"),"stakeUS"===a&&t("stakeUs.modal.form.description")]}),e.withStakePromo&&n&&(0,s.jsx)(E,{formType:a,onSelect:e=>{r(e)}}),"standard"===a&&(0,s.jsx)(er,{...e}),"stake"===a&&(0,s.jsx)(ea,{...e}),"stakeUS"===a&&(0,s.jsx)(J,{onSaveUserName:e.onSaveStakeUSUsername,onSubmit:t=>{e.onSubmit({...t,submitType:"stake.us"})},initValues:{amountInCoins:e.initValues.amountInCoins,stakeUserName:e.initValues.stakeUSUserName||""},isLoading:e.isLoading})]})}e.i(91917);var en=e.i(181944),ei=e.i(66012),el=e.i(322171);let eo="stake-username",ec="stake-us-username",ed={[h.Bitcoin]:"bitcoinId",[h.Ethereum]:"etherId",[h.Litecoin]:"litecoinId",[h.Dogecoin]:"dogecoinId",coinbase:"coinbaseEmail"};function eu({selectedMethod:e}){let t,{toast:a}=(0,l.useToast)(),r=(0,L.useIsStakeCashoutEnabled)(),[n,i]=(0,O.useState)(!1),{t:c}=(0,p.default)("_cashout"),[d,u]=(0,O.useState)(null),[m,x]=(0,O.useState)(!1),f=(0,O.useRef)(null),g=(0,el.default)(),{mutate:y}=(0,H.useMutation)({mutationFn:async t=>{if("crypto"===t.submitType&&t.cryptoAddress){let r=(await K.default.cashout.getCryptoCoins())?.data?.getCryptoCoins,s=r?.items?.find(t=>t.localCurrencyType===_(h.CryptoMethodMap[e]))?.id;if(!s)return a({title:c("_cashout:crypto.toasts.coinNotAvailable"),status:"warning"});let n=(await K.default.cashout.cryptoCashout({address:t.cryptoAddress,amount:Math.floor(t.amountInCoins),cryptoCoinId:s}))?.data.cryptoCashout;if(n?.__typename==="CashoutInitiatedResponseObject")return n;throw new ei.default("Crypto",n)}if("stake.us"===t.submitType&&t.stakeUSUserName){let e=(await K.default.cashout.stakeUsCashout({username:t.stakeUSUserName,coinsAmount:Math.floor(t.amountInCoins),currency:R.Currencies.StakeCash}))?.data.stakeUsCashout;if(e?.__typename==="CashoutInitiatedResponseObject")return e;throw new ei.default("Stake US",e)}if("stake"===t.submitType&&h.CryptoMethodMap[e]&&t.stakeUserName){let a=_(h.CryptoMethodMap[e]);if(a){let e=(await K.default.cashout.stakeComCashout({username:t.stakeUserName,coinsAmount:Math.floor(t.amountInCoins),currency:a}))?.data.stakeComCashout;if(e?.__typename==="CashoutInitiatedResponseObject")return e;throw new ei.default("Stake.com",e)}}},onError:g(e)});return((0,O.useEffect)(()=>()=>{f.current&&clearTimeout(f.current)},[]),m)?(0,s.jsx)(o.default,{onClick:()=>{d&&(x(!1),y(d),i(!0),f.current=setTimeout(()=>{i(!1)},2500))}}):(0,s.jsx)(es,{method:e,onSubmit:t=>{u(t),n||("crypto"===t.submitType&&h.CryptoMethodMap[e]?y(t):("stake"===t.submitType||"stake.us"===t.submitType)&&x(!0))},onSaveCryptoAddress:t=>{let r=ed[e];r&&((0,en.setLocalStorage)(r,t||""),a({title:"Address saved",status:"info"}))},onSaveStakeUsername:e=>{(0,en.setLocalStorage)(eo,e||""),a({title:"Username saved",status:"info"})},onSaveStakeUSUsername:e=>{(0,en.setLocalStorage)(ec,e||""),a({title:"Username saved",status:"info"})},withStakePromo:r,initValues:{stakeUserName:(0,en.getLocalStorage)(eo)||"",stakeUSUserName:(0,en.getLocalStorage)(ec)||"",cryptoAddress:(t=ed[e],(0,en.getLocalStorage)(t)||""),amountInCoins:0},isLoading:n})}var em=e.i(306614),eh=e.i(989847),ep=e.i(134338),ex=e.i(655145);let ef="revolut-revtag";function eg({hasRevolutWithdrawal:e}){let{toast:t}=(0,l.useToast)(),[a,r]=(0,O.useState)(!1),n=(0,O.useRef)(null),{showCurrency:i,format:o}=(0,ex.default)(),{wdCurrency:c}=(0,ep.default)(h.Revolut),{t:d}=(0,p.default)("_cashout"),{mutate:u}=(0,H.useMutation)({mutationFn:e=>K.default.cashout.revolutCashout({revtag:e.revtag,customerName:e.revname,coinsAmount:Math.floor(e.amountInCoins),currency:c}).then(e=>{let t=e.data.revolutCashout;if(t?.__typename==="CashoutInitiatedResponseObject")return t;throw new ei.default("Revolut",t)}),onSuccess:e=>{},onError:e=>{let t=e instanceof Error?e.cause:e,a={};t?.metadata&&["maxWithdrawableCoins","minEarnedToWithdraw","minWithdrawableCoins","minimumWithdrawalCoins","remainingAmou
2ntToEarn","unwithdrawableBalance","withdrawableNowCoins"].forEach(e=>{let r=t?.metadata?.[e];"number"==typeof r&&(a[e]=i?o(r,!1,!1,!0,2):`${(0,P.formatCoins)(r)} coins`)});let r={title:"Something went wrong",text:d(`cashoutV2ErrorMessages.${t.code}`,{...a,defaultValue:"Something went wrong. Please try again."}),showReviewButton:!1,cashoutMethod:h.Revolut};window.dispatchEvent(new CustomEvent(em.CustomWindowEvents.SHOW_AFTER_WITHDRAW_POPUP,{detail:r}))}});(0,O.useEffect)(()=>()=>{n.current&&clearTimeout(n.current)},[]);let{revtag:m,name:x}=(()=>{let e=(0,en.getLocalStorage)(ef),t={revtag:"",name:""},a=t;if(e)try{a=JSON.parse(e)}catch{a=t}return a})();return(0,s.jsx)(eh.default,{isInline:!1,onSaveRevtag:(e,a)=>{(0,en.setLocalStorage)(ef,JSON.stringify({revtag:e||"",name:a||""})),t({title:"Info saved",status:"info"})},onSubmit:e=>{a||(u(e),r(!0),n.current=setTimeout(()=>{r(!1)},2500))},initValues:{amountInCoins:0,revtag:m,revname:x},isLoading:a,hasRevolutWithdrawal:e})}var ey=e.i(643483);function eb({onClick:e}){return(0,s.jsx)("div",{className:"flex mb-[20px] mt-[-10px]",children:(0,s.jsx)("button",{type:"button",className:"flex items-center justify-center gap-[5px] w-[36px] h-[36px] rounded-full border-[1.25px] border-solid border-core-greyBlue-400 bg-transparent cursor-pointer",onClick:e,children:(0,s.jsx)(ey.default,{size:"sm",color:"core.neutral.0"})})})}function ev(e){let[{stakeSelectedCrypto:t},a]=(0,v.useRecoilState)(m.default),{stakeBonus:r}=(0,k.useStakeBonus)(),{t:n}=(0,C.useTranslationTyped)(["_cashout","_common"]),{cryptoData:i,withdrawMinimums:l}=(0,A.default)(),o=G.object().shape({stakeUserName:G.string().required(),amountInCoins:G.number().positive(n("validations.invalidAmount")||"Invalid amount").required(n("validations.amountRequired")||"Required")}),p=async e=>{try{return await o.validate(e,{abortEarly:!1}),{}}catch(e){return e}};return t?(0,s.jsxs)("div",{className:"w-full",children:[(0,s.jsx)(eb,{onClick:()=>{a(e=>({...e,stakeSelectedCrypto:null}))}}),(0,s.jsxs)("div",{className:"flex gap-[15px] items-center",children:[(0,s.jsx)(d.default,{bgColor:"radial-gradient(70.71% 70.71% at 50% 50%, var(--color-core-blue-800) 0%, var(--color-core-blue-900) 100%)"}),(0,s.jsx)("span",{className:"m-0 text-highlight-grey-200",children:"via"}),(0,s.jsxs)("div",{className:"flex gap-[10px] items-center",children:[(0,s.jsx)("img",{src:[...h.stakeRecommendedMethods,...h.stakeOtherMethods].find(e=>e.cryptoMethod===t)?.logo,className:"h-[36px] w-auto block"}),(0,s.jsx)("div",{className:"m-0 font-bold text-[20px] capitalize",children:t})]})]}),(0,s.jsx)("h3",{className:"m-0 text-core-greyBlue-50 my-6",children:n("withdraw.stake.modal.description")}),(0,s.jsx)(U.Formik,{initialValues:{stakeUserName:e.initValues?.stakeUserName,amountInCoins:e.initValues?.amountInCoins||0},validationSchema:o,onSubmit:t=>{e.onSubmit({...t,amountInCoins:(0,P.usdToCoins)(t.amountInCoins)})},validateOnBlur:!1,validateOnChange:!0,validate:p,children:({isValid:a,errors:o,values:d,setFieldValue:m})=>(0,s.jsxs)(U.Form,{children:[(0,s.jsxs)("div",{className:"flex flex-col mb-[15px] gap-[10px]",children:[(0,s.jsxs)("div",{className:"my-6",children:[(0,s.jsx)("label",{htmlFor:"stakeUserName",className:"m-0 text-core-neutral-0 mb-[6px] block text-md",children:n("withdraw.stake.form.labels.username")}),(0,s.jsxs)("div",{className:"grid grid-cols-1 md:grid-cols-[3fr_minmax(145px,auto)] gap-[10px]",children:[(0,s.jsx)("div",{className:"relative w-full",children:(0,s.jsx)(U.Field,{...I.fieldStyle,...o?.stakeUserName&&I.errorFieldStyle,fontSize:"16px",type:"text",name:"stakeUserName",placeholder:n("withdraw.stake.form.labels.placeholder"),id:"stakeUserName",as:b.default,className:"placeholder:font-medium placeholder:tracking-[-0.03em]"})}),(0,s.jsx)(g.Button,{variant:"primary",size:"lg",onClick:()=>{e.onSaveUserName&&e.onSaveUserName(d.stakeUserName)},children:n("saveUserName")})]}),(0,s.jsx)("div",{className:"m-0 text-core-greyBlue-50 mt-2 text-[12px]",children:(0,s.jsx)(Z.Trans,{t:n,i18nKey:"withdraw.stake.modal.noStakeAccount",components:{em:(0,s.jsx)(W.default,{})}})})]}),(0,s.jsxs)("div",{className:"my-6",children:[(0,s.jsx)("label",{htmlFor:"amountInCoins",className:"m-0 text-core-neutral-0 mb-[6px] block text-md",children:n("amountInUsd")}),(0,s.jsxs)("div",{className:"grid grid-cols-1 md:grid-cols-[3fr_minmax(145px,auto)] gap-[10px]",children:[(0,s.jsxs)("div",{className:"relative w-full",children:[(0,s.jsx)(U.Field,{...I.numberFieldStyle,...o?.amountInCoins&&I.errorFieldStyle,type:"number",name:"amountInCoins",placeholder:n("amountPlaceholder"),id:"amountInCoins",as:b.default,className:"placeholder:text-sm placeholder:font-[400] placeholder:tracking-[-0.03em] focus:placeholder:text-[#0000]"}),(0,s.jsx)("div",{className:"absolute top-0 right-0 z-2 flex h-[48px] min-w-fit items-center justify-end",children:(0,s.jsx)(f,{onClick:e=>{m("amountInCoins",(0,P.coinsToUsd)(e))}})})]}),(0,s.jsxs)("div",{className:"flex bg-core-greyBlue-400 rounded-[8px] items-center font-bold p-[0_16px] justify-between min-h-[48px] gap-[8px]",children:[(0,s.jsx)("div",{className:"m-0",children:(0,P.formatDollarDigit)(i?.[t]?.dollarPrice||0,!1,2,4)}),(0,s.jsxs)("div",{className:"flex items-center gap-[8px]",children:[(0,s.jsx)("div",{className:"m-0 text-[#F7931A] text-[30px]",children:"·"}),(0,s.jsxs)("div",{className:"m-0",children:[M(t)," rate"]})]})]})]}),(0,s.jsxs)("div",{className:"flex items-center gap-[10px] mt-2",children:[(0,s.jsx)(y.default,{fill:"none",...o?.amountInCoins&&I.errorIconStyle}),(0,s.jsx)("div",{className:(0,w.cn)("m-0 text-core-greyBlue-50 text-[12px]",o?.amountInCoins&&"text-core-red-700"),children:(0,s.jsx)(c.default,{i18nKey:"_cashout:withdraw.stake.form.labels.minimumAmount",minimum:(0,u.getCryptoMinimumWithdraw)(t,l,!0)})})]})]})]}),(0,s.jsx)("div",{className:"border-t-2 border-dashed border-highlight-purple-900 my-[24px]"}),(0,s.jsxs)("div",{className:"grid grid-cols-1 md:grid-cols-[300px_1fr] items-center",children:[(0,s.jsx)("div",{className:"flex flex-col gap-[4px]",children:(0,s.jsx)(ew,{stakeBonus:r,cryptoData:i,stakeSelectedCrypto:t})}),(0,s.jsx)("div",{className:"flex justify-end mt-[24px] md:mt-0",children:(0,s.jsx)("div",{className:"w-full md:max-w-[300px]",children:(0,s.jsx)(g.Button,{variant:"primary",size:"lg",type:"submit",isLoading:e.isLoading,disabled:!a,width:"full",children:n("withdraw")})})})]})]})})]}):null}function ew({stakeBonus:e,cryptoData:t,stakeSelectedCrypto:a}){let{values:r}=(0,U.useFormikContext)(),[n,i]=(0,O.useState)(0),[l,o]=(0,O.useState)(0),{t:c}=(0,C.useTranslationTyped)(["_cashout","_common"]);return(0,O.useEffect)(()=>{let s=(0,P.usdToCoins)(r.amountInCoins)||0,n=s*(e||0)/100,l=t?.[a]?.dollarPrice,c=l?((s-0+n)/1e3/l).toFixed(8):0;i(Number(c)>0?c:0),o(n)},[r.amountInCoins,e,t,a]),(0,s.jsxs)(s.Fragment,{children:[(e??0)>0&&(0,s.jsxs)("div",{className:"flex justify-between w-full items-center",children:[(0,s.jsxs)("div",{className:"flex gap-[8px] items-center",children:[(0,s.jsx)("p",{className:"m-0 text-core-greyBlue-50 text-sm whitespace-nowrap",children:c("withdraw.stake.form.labels.bonus")}),(0,s.jsxs)("div",{className:"bg-core-freecashGreen-25-A10 p-[2px_4px] md:p-[4px_8px] rounded-[4px] text-core-freecashGreen-400",children:[e,"%"]})]}),(0,s.jsx)("div",{className:"m-0 text-sm text-core-greyBlue-50",children:(0,s.jsx)(B.default,{coins:l,hideUsdIcon:!0})})]}),(0,s.jsx)("div",{className:"flex justify-between w-full items-center",children:(0,s.jsxs)("div",{className:"flex justify-between w-full",children:[(0,s.jsx)("div",{className:"m-0 text-[16px] text-core-neutral-0 font-semibold",children:c("withdraw.stake.form.labels.youReceive",{crypto:M(a)})}),(0,s.jsxs)("div",{className:"flex gap-[5px] items-center",children:[(0,s.jsx)("div",{className:"flex size-[14px] items-center",children:(0,s.jsx)(D.default,{name:a})}),(0,s.jsx)("span",{className:"m-0 text-core-neutral-0 font-semibold",children:n})]})]})})]})}var eC=e.i(908044);e.i(785269);var ej=e.i(345771);function ek(e){let{t}=(0,p.default)(["_cashout","_common"]),{bonus:a}=e;return(0,s.jsx)(eC.default,{onClick:e.onCardClick,children:(0,s.jsxs)("div",{className:"flex flex-col gap-2 items-center cursor-pointer w-full h-full rounded-[10px] p-[10px_8px] md:p-[12px] pb-[20px] md:pb-[20px] -outline-offset-1 hover:outline-solid hover:outline-[1px] hover:outline-core-freecashGreen-500",style:{background:"radial-gradient(70.71% 70.71% at 50% 50%, var(--color-core-blue-800) 0%, var(--color-core-blue-900) 100%)"},children:[(0,s.jsx)("div",{className:"flex flex-none justify-center w-full items-center",children:(a??0)>0&&(0,s.jsx)("div",{className:"bg-core-freecashGreen-900 p-[2px_4px] md:p-[4px_8px] rounded-[4px]",children:(0,s.jsx)("div",{className:"m-0 text-sm text-core-freecashGreen-500 whitespace-nowrap",children:t("_cashout:withdraw.stake.bonus",{discount:a})})})}),(0,s.jsx)("div",{className:"flex flex-col flex-1",children:(0,s.jsx)("img",{src:e.logo,alt:`Freecash Stake ${e.name}
2`,className:"w-[40px] h-[40px] md:w-[64px] md:h-[64px] m-auto block"})}),(0,s.jsx)("div",{className:"m-0 font-bold text-sm",children:e.name}),(0,s.jsx)("p",{className:"m-0 text-sm",children:"Stake"})]})})}function eN(e){let{t}=(0,p.default)(["_cashout","_common"]),{stakeBonus:a}=(0,k.useStakeBonus)();return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("h3",{className:"m-0 my-4 text-sm text-core-greyBlue-50",children:t("_cashout:withdraw.stake.modal.description")}),(0,s.jsx)("p",{className:"m-0 mt-6 text-core-neutral-0",children:(0,s.jsx)(ej.Trans,{t:t,i18nKey:"_cashout:withdraw.stake.modal.noStakeAccount",components:{em:(0,s.jsx)(W.default,{})}})}),(0,s.jsx)("div",{className:"m-0 mt-6 mb-4 text-core-greyBlue-50",children:t("_common:recommended")}),(0,s.jsx)("div",{className:"grid grid-cols-3 md:grid-cols-[repeat(auto-fill,minmax(135px,1fr))] gap-[10px]",children:h.stakeRecommendedMethods.map(t=>(0,s.jsx)(ek,{bonus:a,...t,onCardClick:()=>{e.onCardClick&&e.onCardClick(t.cryptoMethod)}},t.name))}),(0,s.jsx)("div",{className:"m-0 mt-6 mb-4 text-core-greyBlue-50",children:t("_common:other")}),(0,s.jsx)("div",{className:"grid grid-cols-3 md:grid-cols-[repeat(auto-fill,minmax(135px,1fr))] gap-[10px]",children:h.stakeOtherMethods.map(t=>(0,s.jsx)(ek,{bonus:a,...t,onCardClick:()=>{e.onCardClick&&e.onCardClick(t.cryptoMethod)}},t.name))})]})}function eS(){let[e,t]=(0,O.useState)(!1),a="stake-us-username",{toast:r}=(0,l.useToast)(),[n,i]=(0,O.useState)(!1),c=(0,O.useRef)(null),[d,u]=(0,O.useState)({stakeUserName:"",amountInCoins:0}),{t:m}=(0,p.default)("_cashout"),x=(0,el.default)(),{mutate:f}=(0,H.useMutation)({mutationFn:async e=>{let t=(await K.default.cashout.stakeUsCashout({username:e.stakeUserName,coinsAmount:Math.floor(e.amountInCoins),currency:R.Currencies.StakeCash}))?.data.stakeUsCashout;if(t?.__typename==="CashoutInitiatedResponseObject")return t;throw new ei.default("Stake US",t)},onError:x(h.StakeUS)});return((0,O.useEffect)(()=>()=>{c.current&&clearTimeout(c.current)},[]),e)?(0,s.jsx)("div",{className:"mt-[20px]",children:(0,s.jsx)(o.default,{onClick:()=>{(t(!1),n)?r({title:"We are still attempting to send your last withdrawal request. Please wait 30 seconds between requests.",status:"info"}):(i(!0),f(d),c.current=setTimeout(()=>{i(!1)},3e3))}})}):(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("h3",{className:"m-0 my-6 text-core-greyBlue-50",children:m("stakeUs.modal.form.description")}),(0,s.jsx)(J,{onSaveUserName:e=>{(0,en.setLocalStorage)(a,e||""),r({title:"Username saved",status:"info"})},onSubmit:e=>{t(!0),u(e)},initValues:{amountInCoins:0,stakeUserName:(0,en.getLocalStorage)(a)||""},isLoading:n})]})}function eF(e){let{children:t,name:a,value:r,isChecked:n,onChange:i}=e;return(0,s.jsxs)("label",{className:"cursor-pointer flex-none",children:[(0,s.jsx)("input",{type:"radio",name:a,value:r,checked:n,onChange:()=>i(r),className:"sr-only"}),(0,s.jsxs)("div",{className:"flex gap-[10px] items-center",children:[(0,s.jsx)("div",{className:(0,w.cn)("flex-none w-[24px] h-[24px] rounded-[12px] border border-solid",n?"bg-core-freecashGreen-500 border-core-freecashGreen-500 outline-solid outline-[3px] outline-core-greyBlue-300 -outline-offset-4":"bg-core-greyBlue-300 border-core-neutral-0")}),(0,s.jsx)("p",{className:"m-0 text-core-neutral-0",children:t})]})]})}function eT({value:e,onSelect:t}){let a=(0,j.useFeatureFlags)(e=>e.isStakeUSEnabled),{stakeBonus:r,stakeUSBonus:n}=(0,k.useStakeBonus)(),i=[{label:(0,s.jsxs)("div",{className:"flex items-center gap-[10px]",children:[(0,s.jsx)("span",{className:"m-0",children:"Stake.us"}),(0,s.jsx)("img",{src:"/public/img/flags/round-flags/us.svg",className:"h-[20px] w-[20px]"}),(n??0)>0&&(0,s.jsxs)("span",{className:"m-0 text-core-freecashGreen-500",children:["+",n,"%"]})]}),value:R.StakeProvider.StakeUs},{label:(0,s.jsxs)("div",{className:"flex items-center gap-[10px]",children:[(0,s.jsx)("span",{className:"m-0",children:"Stake.com"}),(0,s.jsx)("img",{src:"/public/img/earn/global.svg",className:"h-[20px] w-[20px]"}),(r??0)>0&&(0,s.jsxs)("span",{className:"m-0 text-core-freecashGreen-500",children:["+",r,"%"]})]}),value:R.StakeProvider.StakeCom}];return a?(0,s.jsx)("div",{className:"flex justify-start gap-[16px] md:gap-[48px] mt-[24px] flex-col md:flex-row",children:i.map(a=>(0,s.jsx)(eF,{name:"stake-preference",value:a.value,isChecked:e===a.value,onChange:t,children:a.label},a.value))}):null}function eE(e){let{defaultStakeTab:t,isFetched:a}=Q(),[r,n]=(0,O.useState)(R.StakeProvider.StakeCom);return(0,O.useEffect)(()=>{a&&n(t)},[a,t]),(0,s.jsxs)("div",{children:[(0,s.jsxs)("div",{className:"flex gap-[10px] items-center",children:[(0,s.jsx)("div",{className:"p-[3px] rounded-[4px] w-[48px] h-[48px] flex",style:{background:"radial-gradient(70.71% 70.71% at 50% 50%, var(--color-core-blue-800) 0%, var(--color-core-blue-900) 100%)"},children:(0,s.jsx)("img",{src:"/img/cashout/legacy/stake.png",className:"h-[16px] w-auto block m-auto"})}),(0,s.jsx)("h2",{className:"m-0 text-[20px]",children:"Stake"})]}),(0,s.jsx)(eT,{value:r,onSelect:e=>{n(e)}}),r===R.StakeProvider.StakeUs&&(0,s.jsx)(eS,{}),r===R.StakeProvider.StakeCom&&(0,s.jsx)(eN,{...e})]})}function eA(){let[{selectedMethod:e,stakeSelectedCrypto:t},a]=(0,v.useRecoilState)(m.default),[r,n]=(0,O.useState)(!1),i="stake-username",{toast:c}=(0,l.useToast)(),[d,u]=(0,O.useState)(!1),p=(0,O.useRef)(null),[x,f]=(0,O.useState)({stakeUserName:"",amountInCoins:0}),g=(0,el.default)(),{mutate:y}=(0,H.useMutation)({mutationFn:async e=>{if(null!==t){let a=_(t);if(null!==a){let t=(await K.default.cashout.stakeComCashout({username:e.stakeUserName,coinsAmount:Math.floor(e.amountInCoins),currency:a}))?.data.stakeComCashout;if(t?.__typename==="CashoutInitiatedResponseObject")return t;throw new ei.default("Stake.com",t)}}},onError:g(h.Stake)});return((0,O.useEffect)(()=>()=>{p.current&&clearTimeout(p.current)},[]),e!==h.Stake||t)?r?(0,s.jsx)(o.default,{onClick:()=>{(n(!1),d)?c({title:"We are still attempting to send your last withdrawal request. Please wait 30 seconds between requests.",status:"info"}):(y(x),u(!0),p.current=setTimeout(()=>{u(!1)},3e3))}}):(0,s.jsx)(ev,{onSaveUserName:e=>{(0,en.setLocalStorage)(i,e||""),c({title:"Username saved",status:"info"})},onSubmit:e=>{n(!0),f(e)},initValues:{amountInCoins:0,stakeUserName:(0,en.getLocalStorage)(i)||""},isLoading:d}):(0,s.jsx)(eE,{isInline:!1,onCardClick:e=>{a(t=>({...t,stakeSelectedCrypto:e}))}})}var eR=e.i(838210),eM=e.i(756438),e_=e.i(141151),eI=e.i(74128);function eP(){let{hasRevolutWithdrawal:e,isRevolutCashoutEnabled:t}=(0,eR.useWithdrawMethodConfig)(),a=(0,L.useIsStakeCashoutEnabled)(),[{selectedMethod:r},n]=(0,v.useRecoilState)(m.default),i=!!r,l=(0,e_.useIsBelowBreakpoint)("md");if((0,eI.useAppOverlayEffects)(i),!r)return null;let o={[h.Revolut]:"660px"}[r]||"800px";return(0,s.jsx)(eM.Modal,{open:i,onClose:()=>{n(e=>
2({...e,selectedMethod:null,stakeSelectedCrypto:null}))},size:l?"full":"660px"===o?"lg":"xl",surface:"raised",children:(0,s.jsxs)(eM.ModalBody,{children:[r===h.Stake&&a&&(0,s.jsx)(eA,{}),r===h.Revolut&&t&&(0,s.jsx)(eg,{hasRevolutWithdrawal:e}),[h.Bitcoin,h.Ethereum,h.Litecoin,h.Dogecoin].includes(r)&&(0,s.jsx)(eu,{selectedMethod:r})]})})}var eB=e.i(27339),eU=e.i(409617),eO=e.i(243418),eG=e.i(20500),eL=e.i(733969);e.i(870515);var eD=e.i(820814),eV=e.i(973857),eW=e.i(45839),eK=e.i(838751);function ez({minWithdrawableCoins:e}){let{t}=(0,p.default)("_cashout"),{format:a}=(0,ex.default)(),r=(0,eK.useAsyncPopup)();return(0,s.jsxs)("div",{className:"flex flex-col",children:[(0,s.jsx)("hr",{className:"m-0 w-full border-0 border-t border-solid border-t-core-greyBlue-400 mb-[10px] mt-[20px]"}),(0,s.jsx)("p",{className:"m-0 text-core-greyBlue-50",children:t("cashoutGoalRemoval.widget.firstMinimumWithdraw",{minWithdrawable:a(e,!1,!0,!0,2)})}),(0,s.jsx)(eV.default,{onClick:()=>{r.trigger({name:eK.AllowedAsyncPopupName.CASHOUT_GOAL_REMOVAL_POPUP})},children:(0,s.jsxs)("div",{className:"flex gap-[8px] items-center",children:[(0,s.jsx)("div",{className:"m-0 whitespace-nowrap",children:t("cashoutGoalRemoval.widget.cta",{minWithdrawable:a(e,!1,!0,!0,2)})}),(0,s.jsx)(eW.default,{boxSize:"16px",color:"core.greyBlue.50"})]})})]})}var eH=e.i(921380);let eq=({withdrawableNowBalance:e})=>{let{t}=(0,p.default)("_cashout"),a=(0,j.useFeatureFlags)(e=>e.isCashoutGoalRemovalEnabled),{minWithdrawableCoins:r,signupBonusCoins:n}=(0,eG.default)(),{userProfileInfo:i}=(0,eL.default)();return(0,s.jsxs)("div",{className:"w-full md:w-fit min-h-[84px] md:min-h-[166px] md:p-[24px] p-[16px_24px] max-w-[650px] bg-core-greyBlue-500 rounded-[12px]",children:[(0,s.jsxs)("div",{className:"flex items-center md:items-stretch flex-row md:flex-col mb-0",children:[(0,s.jsx)("div",{className:"flex md:mb-[27px] mb-0 mr-[32px] md:mr-0",children:(0,s.jsx)(eH.default,{height:"40px",width:"40px"})}),(0,s.jsxs)("div",{className:"flex flex-col text-left",children:[(0,s.jsx)("p",{className:"m-0 not-italic text-core-greyBlue-50 font-medium text-sm leading-[160%]",children:t("balance")}),(0,s.jsx)(eD.CurrencyText,{amount:e??0,targetCurrency:"USER_CURRENCY",fontSize:"20px",fontWeight:"500",lineHeight:"150%",color:"core.neutral.0"})]})]}),a&&null!==r&&r>0&&null!==n&&n>0&&i?.canRefer===!0&&(0,s.jsx)(ez,{minWithdrawableCoins:r})]})},e$=e=>(0,s.jsx)("svg",{viewBox:"0 0 25 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e,children:(0,s.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M3.5 12C3.5 7.03228 7.53228 3 12.5 3C17.4677 3 21.5 7.03228 21.5 12C21.5 16.9677 17.4677 21 12.5 21C7.53228 21 3.5 16.9677 3.5 12ZM12.5 1C6.42772 1 1.5 5.92772 1.5 12C1.5 18.0723 6.42772 23 12.5 23C18.5723 23 23.5 18.0723 23.5 12C23.5 5.92772 18.5723 1 12.5 1ZM13.1309 6.99998C13.1309 6.4477 12.6831 5.99998 12.1309 5.99998C11.5786 5.99998 11.1309 6.4477 11.1309 6.99998V11.61C11.1309 12.372 11.2428 13.0152 11.6454 13.5057C11.8421 13.7453 12.0628 13.8913 12.2299 13.9878C12.3006 14.0285 12.3734 14.0669 12.4281 14.0957L12.4471 14.1057C12.5098 14.1388 12.5566 14.164 12.6011 14.1903C12.6441 14.2158 12.6891 14.2381 12.7355 14.2569L15.6247 15.4269C16.1366 15.6342 16.7196 15.3872 16.9269 14.8753C17.1342 14.3634 16.8873 13.7804 16.3753 13.5731L13.5507 12.4293C13.4868 12.3931 13.4281 12.362 13.3803 12.3368L13.3644 12.3284C13.3027 12.2958 13.265 12.276 13.2299 12.2557C13.2144 12.2468 13.203 12.2397 13.1948 12.2344C13.1756 12.1817 13.1309 12.0142 13.1309 11.61V6.99998ZM13.2034 12.2543C13.2034 12.2544 13.2028 12.2534 13.2017 12.2511C13.2029 12.2531 13.2035 12.2542 13.2034 12.2543Z",fill:(0,n.resolveColorToken)("core.greyBlue.200")})});var eQ=e.i(661209);e.i(858314);var eZ=e.i(967608);e.i(441024);var eY=e.i(746006);let eX=({icon:e,offerName:t,coins:a,dateToRelease:r,dayToRelease:n,isMobile:i})=>(0,s.jsxs)("div",{className:"flex flex-row items-center mb-[16px] md:mb-[8px] flex-1",children:[(0,s.jsx)("img",{className:"rounded-[8px] size-[48px] md:size-[32px] mr-[16px] md:mr-[12px]",src:e||"/public/img/profile/offerIcon.png",alt:t}),(0,s.jsxs)("div",{className:"flex flex-col md:flex-row justify-between min-w-[250px] flex-1",children:[(()=>{if(!r){let e=i?"top-start":"bottom",t="max-w-[210px] p-[10px_12px] text-[12px] font-normal leading-[165%] text-core-greyBlue-50 shadow-[0px_0px_16px_var(--color-core-greyBlue-A-30)]",a=(0,s.jsxs)("p",{className:"m-0 flex-row text-[12px]",children:["The payout date may be pending for several reasons. You can learn more"," ",(0,s.jsx)("a",{className:"text-core-blue-200 hover:underline",target:"_blank",rel:"noreferrer",href:"https://freecash.com/academy/en/support/general/platform/cashback-pending",children:"here"}),"."]});return(0,s.jsxs)("div",{className:"flex items-center",children:[(0,s.jsx)("p",{className:"m-0 my-0",children:"Date pending"}),i?(0,s.jsx)(eY.Popover,{placement:e,hasArrow:!0,className:(0,w.cn)("rounded-[6px] bg-core-greyBlue-300",t),arrowClassName:"fill-core-greyBlue-300",trigger:(0,s.jsx)(eQ.QuestionOutlineIcon,{ml:"8px"}),children:a}):(0,s.jsx)(eZ.Tooltip,{placement:e,hasArrow:!0,label:a,className:(0,w.cn)("bg-core-greyBlue-300",t),arrowClassName:"fill-core-greyBlue-300",children:(0,s.jsx)(eQ.QuestionOutlineIcon,{ml:"8px"})})]})}return(0,s.jsxs)("p",{className:"m-0 my-0 w-fit",children:["Withdrawable ",n]})})(),(0,s.jsx)(B.default,{hideUsdIcon:!0,coins:a,gap:"8px",fontSize:"14px",fontWeight:"500",lineHeight:"22px"})]})]});var eJ=e.i(180589),e0=e.i(476984);let e1=e=>(0,s.jsx)(e0.default,{viewBox:"0 0 12 12",fill:"none",...e,children:(0,s.jsx)("path",{d:"M4.5 0C3.40135 0 2.5 0.901365 2.5 2C2.5 2.36533 2.6068 2.70419 2.78025 3H0.5C0.22385 3.00003 5e-05 3.22387 0 3.5V5.5C5e-05 5.77613 0.22385 5.99997 0.5 6H1H4.7754H5.8496H7.1494H7.67675H11H11.5C11.7761 5.99997 12 5.77613 12 5.5V3.5C12 3.22387 11.7761 3.00003 11.5 3H9.2197C9.39315 2.70419 9.5 2.36534 9.5 2C9.5 0.901365 8.59865 0 7.5 0C6.90145 0 6.3676 0.2731 6 0.694335C5.63245 0.2731 5.0986 0 4.5 0ZM4.5 1C5.05825 1 5.5 1.44178 5.5 2V3H4.5C3.94175 3 3.5 2.55822 3.5 2C3.5 1.44178 3.94175 1 4.5 1ZM7.5 1C8.05825 1 8.5 1.44178 8.5 2C8.5 2.55819 8.0582 3 7.5 3H6.5V2C6.5 1.44178 6.94175 1 7.5 1ZM1 7V11.5C1.00005 11.7761 1.22385 12 1.5 12H5.5V11.3897V7H4.88965H1ZM6.5 7V11.2754V12H10.5C10.7761 12 11 11.7761 11 11.5V7H7.7041H7.1494H6.5Z",fill:(0,n.resolveColorToken)("core.greyBlue.100")})}),e2=({bonusBalance:e,bonusWithdrawableCoins:t,isMobile:a})=>
2{let r=a?"top-start":"bottom",n="max-w-[210px] p-[10px_12px] text-[12px] font-normal leading-[165%] text-core-greyBlue-50 shadow-[0px_0px_15px_var(--color-core-neutral-1000-A30)]",i=(0,s.jsxs)("p",{className:"m-0 flex-row text-[12px]",children:["Earn"," ",(0,s.jsx)(B.default,{containerProps:{className:"inline-flex items-baseline"},gap:"2px",hideUsdIcon:!0,marginRight:"0",coins:t,iconWidth:"12px",fontSize:"12px"})," ","more to withdraw your claimed bonus codes."]});return(0,s.jsxs)("div",{className:"flex bg-core-neutral-0-A10 rounded-[8px] text-core-greyBlue-50 flex-row items-center h-[30px] min-w-[130px] p-[4px_8px] justify-between",children:[(0,s.jsx)(e1,{width:"12px",height:"12px"}),(0,s.jsx)(B.default,{coins:e,hideUsdIcon:!0,gap:"4px",iconWidth:"12px",fontSize:"14px",fontWeight:"500",lineHeight:"150%"}),a?(0,s.jsx)(eY.Popover,{placement:r,hasArrow:!0,className:(0,w.cn)("rounded-[6px] bg-core-greyBlue-300",n),arrowClassName:"fill-core-greyBlue-300",trigger:(0,s.jsx)(eQ.QuestionOutlineIcon,{}),children:i}):(0,s.jsx)(eZ.Tooltip,{placement:r,hasArrow:!0,label:i,className:n,children:(0,s.jsx)(eQ.QuestionOutlineIcon,{})})]})};var e3=e.i(84006);let e5=({rewards:e,offers:t,offersCount:a,totalAmount:r})=>{let n=(0,eJ.default)(),{t:i}=(0,p.default)(["_earn","_cashout"]);return(0,s.jsxs)("div",{className:"flex flex-col md:flex-row bg-core-greyBlue-500 rounded-[12px] ml-0 md:ml-[16px] mt-[16px] md:mt-0 md:p-[24px] p-[16px_24px] min-w-full md:min-w-fit max-h-full md:max-h-fit max-w-[650px] flex-1",children:[(0,s.jsxs)("div",{className:"flex flex-row md:flex-col items-center md:items-stretch",children:[(0,s.jsx)("div",{className:"flex md:mb-[27px] mb-0 md:mr-0 mr-[32px]",children:(0,s.jsx)(e$,{width:"40px",height:"40px"})}),(0,s.jsxs)("div",{className:"flex flex-col text-left",children:[(0,s.jsx)("p",{className:"m-0 not-italic font-medium text-core-greyBlue-50 text-sm leading-[160%] whitespace-nowrap",children:i("_cashout:withdrawableSoon")}),(0,s.jsx)(B.default,{color:"core.neutral.0",hideUsdIcon:!0,gap:"8px",coins:r,iconWidth:"18px",fontSize:"20px",fontWeight:"500",lineHeight:"150%"})]})]}),(0,s.jsx)("hr",{"aria-orientation":n?"horizontal":"vertical",className:(0,w.cn)("border-0 border-solid border-current opacity-60 mx-0 md:mx-[32px] my-[16px] md:my-0",n?"border-b w-full":"border-l h-full")}),(0,s.jsxs)("div",{className:"flex flex-col justify-between flex-1",children:[(0,s.jsx)("div",{children:t.length?t.map((e,t)=>(0,s.jsx)(eX,{...e,isMobile:n},t)):(0,s.jsx)("p",{className:"m-0 not-italic font-medium text-sm",children:i("_cashout:noPendingOffers")})}),(0,s.jsxs)("div",{className:(0,w.cn)("flex flex-row-reverse md:flex-row items-center md:items-end flex-1 mt-[4px]",e.bonusBalance?"justify-between":"justify-end"),children:[!!e.bonusBalance&&(0,s.jsx)(e2,{isMobile:n,...e}),(0,s.jsx)("p",{className:"m-0 flex my-0",children:(0,s.jsxs)(e3.default,{onClick:()=>window.onlyHeld=!0,className:"pageRoute",id:"pendingAnchor","alma-page":"myprofile","alma-redirect":void 0,"alma-route":"/myprofile",href:"/myprofile",style:{color:"var(--color-core-greyBlue-50)"},children:[i("_earn:viewAll"),(0,s.jsxs)("span",{className:"m-0 text-core-neutral-0 ml-[3px] mr-[8px]",children:["(",a,")"]}),(0,s.jsx)("span",{className:"m-0 text-core-neutral-0",children:(0,s.jsx)(eQ.ChevronRightIcon,{color:"core.neutral.0"})})]})})]})]})]})};var e4=e.i(815526),e8=e.i(682459),e6=e.i(404434);let e7=()=>{let e=(0,$.useQueryClient)(),{data:t=0,isPending:a}=(0,e6.default)(),{data:r,isPending:s}=(0,q.useQuery)({queryKey:[i.QueryKeys.GRAPHQL_GET_PENDING_OFFERS],queryFn:e4.userPendingOffersApi.findOffersByQuery,placeholderData:e=>e}),{data:n,isPending:l}=(0,q.useQuery)({queryKey:[i.QueryKeys.GRAPHQL_GET_USER_REWARDS],queryFn:e4.userRewardsApi.getUserRewards,placeholderData:e=>e});(0,O.useEffect)(()=>{let t=()=>{e.invalidateQueries({queryKey:[i.QueryKeys.GRAPHQL_GET_PENDING_OFFERS]}),e.invalidateQueries({queryKey:[i.QueryKeys.GRAPHQL_GET_USER_REWARDS]})};return e8.default.on("user:changedBalance",t),()=>{e8.default.off("user:changedBalance",t)}},[e]);let o=r?.data?.findOffersByQuery,c=n?.data?.bonusBalanceAndFulfilment??{bonusBalance:0,bonusWithdrawableCoins:0};return{offersCount:o?.meta.totalItemsCount??0,rewards:c,offers:o?.items??[],totalAmount:(o?.meta.totalAmount??0)+t,isLoading:s||l||a}};e.i(361318);var e9=e.i(814063),te=e.i(11934);let tt=e=>{let{rewards:t,offersCount:a,offers:r,isLoading:n}=e7(),{withdrawableNowBalance:i,pendingBalance:l,isLoading:o}=(0,x.default)();if(n||o)return(0,s.jsx)("div",{className:"flex w-full md:w-[733px] h-[380px] md:h-[166px] rounded-[12px] mb-[44px] md:mb-[28px] flex-col md:flex-row mr-0 xxl:mr-[85px]",children:(0,s.jsx)(e9.Skeleton,{width:"100%",height:"100%",className:"bg-core-greyBlue-400"})});let{className:c,style:d,rest:u}=(0,te.splitChakraBoxProps)(e);return(0,s.jsxs)("div",{className:(0,w.cn)("flex flex-col md:flex-row mb-[28px] md:mb-[60px] mr-0 xxl:mr-[85px]",c),style:d,...u,children:[(0,s.jsx)(eq,{withdrawableNowBalance:i}),r.length||t.bonusBalance?(0,s.jsx)(e5,{rewards:t,offersCount:a,offers:r,totalAmount:l??0}):null]})};function ta(){let{t:e}=(0,p.default)(["_cashout"]);return(0,s.jsx)("button",{type:"button",className:"inline-flex flex-1 items-center justify-center w-fit min-h-[36px] px-4 appearance-none cursor-pointer rounded-[4px] border border-solid border-core-freecashGreen-700 bg-transparent text-[12px] font-semibold text-core-freecashGreen-700",children:(0,s.jsx)("span",{style:{display:"contents"},children:e("_cashout:myWithdrawals")})})}function tr(){let{isIosAppWebView:e}=(0,eO.useIosAppV2UiMode)(),{t}=(0,p.default)(["_common","_cashout","_cashout2024"]);return(0,s.jsx)("div",{className:"p-[24px] lg:p-[30px_24px_0px_24px] overflow-hidden relative",children:(0,s.jsxs)("div",{className:"flex gap-0 lg:gap-[50px] flex-col lg:flex-row justify-between",children:[(0,s.jsxs)("div",{className:"relative w-auto lg:w-[40%] max-w-[700px]",children:[(0,s.jsxs)("div",{className:"flex mb-0 md:mb-[24px] justify-between items-baseline md:items-center",children:[(0,s.jsx)(eU.default,{className:"shopTitle text-[20px] lg:text-2xl",my:"0",fontWeight:"bold",as:"h1",children:t("_cashout:cashout")}),(0,s.jsx)(eB.default,{className:"visible md:invisible",href:"/myprofile#withdrawals",page:"myprofile",children:(0,s.jsx)(ta,{})})]}),(0,s.jsxs)("div",{className:"flex flex-col items-start my-[16px] gap-[16px]",children:[!e&&(0,s.jsx)(eU.default,{color:"core.greyBlue.50",className:"text-sm lg:text-[16
2px]",children:t("_cashout2024:pageDescription")}),(0,s.jsx)(eB.default,{className:"hidden md:inline-block mb-[40px]",href:"/myprofile#withdrawals",page:"myprofile",children:(0,s.jsx)(ta,{})})]})]}),(0,s.jsx)(tt,{className:"mb-[-4px] md:mb-[20px]"})]})})}var ts=e.i(353787);function tn({type:e="percentage",bonus:t,discount:a,className:r}){let{t:n}=(0,C.useTranslationTyped)("_cashout");return(0,s.jsx)("div",{className:"max-w-full rounded-[4px] border border-solid border-core-freecashGreen-25-A30 bg-core-freecashGreen-25-A10 p-[2px_4px] md:p-[4px_8px]",children:(0,s.jsxs)("div",{className:(0,w.cn)("whitespace-nowrap text-[8px] text-core-freecashGreen-500",r),children:["string"==typeof t&&(0,s.jsx)("div",{children:t}),"number"==typeof t&&(0,s.jsx)("div",{children:"fixed"===e?!!t&&n("withdraw.bonus",{amount:t}):!!t&&n("withdraw.stake.bonus",{discount:`+${t}`})}),!!a&&(0,s.jsx)("div",{children:n("discountAmount",{amount:a})})]})})}function ti(){return(0,s.jsx)("div",{className:"text-core-freecashGreen-500 text-[10px] whitespace-nowrap",children:"Stake.US is Live!"})}var tl=e.i(182893),to=e.i(230892),tc=e.i(787274),td=e.i(343242);function tu({stakeBonus:e,bonus:t}){return(0,s.jsx)(tn,{bonus:e||t,type:t?"fixed":"percentage",className:"text-[12px] md:text-sm m-auto w-fit"})}function tm(e){let{item:t,stakeBonus:a}=e,r=(0,j.useFeatureFlags)(e=>e.isStakeUSEnabled),n=[h.Stake,h.StakeUS].includes(t.name)&&r,{isNonUSD:i,addCurrencySymbol:l}=(0,ep.default)(t.name),o=(0,j.useFeatureFlags)(e=>e.cashoutV2Settings?.isTangoBackendEnabled),{methods:c}=(0,tl.default)({trackOfferingMethodsShown:!1}),{isStakeUSDepositPromoEnabled:d,coinAmount:u}=(0,td.default)(),{hasRevolutWithdrawal:m,hasStakeUsWithdrawal:p}=(0,eR.useWithdrawMethodConfig)(),{t:x}=(0,C.useTranslationTyped)("_cashout"),[f,g]=(0,tc.default)(),y=(0,O.useMemo)(()=>{let e=c.find(e=>e.slug===t.route);return e&&o&&e?.giftCards?.[0]?e:null},[c,t.route,o]),b=(0,O.useMemo)(()=>t.name===h.Revolut?(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("img",{className:"h-[20px] object-contain max-w-full",src:`/img/cashout/legacy/${t.image}`}),(0,s.jsx)("p",{className:"m-0 mb-[6px] text-core-neutral-0 text-[10px] leading-[15px] tracking-[2%] font-medium",children:x("withdraw.revolut.promoCard.ourCashoutPartner")}),(0,s.jsx)("p",{className:"m-0 text-core-freecashGreen-500 text-[10px] leading-[15px] tracking-[2%] font-medium",children:f>0&&g===to.FeeType.PERCENTAGE?x("withdraw.revolut.promoCard.percentageFee",{feePct:f}):f>0&&g===to.FeeType.FIXED?x("withdraw.revolut.promoCard.fixedFee",{feeAmount:l(f)}):x("withdraw.revolut.promoCard.zeroFee")})]}):y&&y.giftCards?.[0]?(0,s.jsx)("div",{className:"overflow-hidden",children:(0,s.jsx)(ts.default,{giftCard:y.giftCards[0],method:y})}):(0,s.jsx)("img",{className:"h-[42px] lg:h-[64px] object-contain max-w-full",src:`/img/cashout/legacy/${t.image}`}),[t,x,y,f,g]),v=(0,O.useMemo)(()=>t.bonus&&t.name===h.Revolut?!1===m:t.bonus&&t.name===h.StakeUS?!1===p:!!a,[a,t,m,p]),k=(0,O.useMemo)(()=>t.name===h.StakeUS?d?(0,s.jsx)(tu,{bonus:(0,P.coinsToUsd)(u)}):(0,s.jsx)(tu,{bonus:x("stakeUs.promotionCard.bonusTag",{amount:l(t.bonus??0)})}):i&&t.bonus?(0,s.jsx)(tu,{bonus:x("withdraw.bonusRaw",{amount:l(t.bonus)})}):(0,s.jsx)(tu,{stakeBonus:a,bonus:t.bonus}),[i,t,a,l,u,d]);return(0,s.jsx)("div",{className:(0,w.cn)("h-full relative rounded-[12px] shadow-[0px_10px_15px_0px_var(--color-core-neutral-1000-A10)]","md:hover:outline-solid md:hover:outline-1 md:hover:outline-core-freecashGreen-500",y?"p-0":"p-[16px_8px] md:p-[16px]"),style:{background:y?.bg??t.bgColor},children:(0,s.jsx)(eC.default,{isClickable:!1,onClick:()=>{},children:(0,s.jsxs)("div",{className:"text-center flex items-center justify-center flex-col w-full h-full gap-[12px] relative",children:[v&&(0,s.jsx)("div",{className:"absolute top-0 left-0 right-0",children:k}),(0,s.jsx)("div",{children:b}),(0,s.jsxs)("div",{className:(0,w.cn)("absolute",y?"bottom-[16px]":"bottom-0"),children:[(0,s.jsx)("span",{className:(0,w.cn)("leading-normal",!y?.color&&"text-core-neutral-0"),style:y?.color?{color:y.color}:void 0,children:t.name}),n&&(0,s.jsx)(ti,{})]})]})})},t.route)}var th=e.i(14484);let tp=[h.Stake,h.StakeUS,h.FaucetPay,h.Airtm,h.Revolut,h.Bitcoin,h.Ethereum,h.Litecoin,h.Dogecoin,h.BankTransfer,h.Minecraft,h.Mastercard,...h.GiftCardsWithoutCountryList,...h.GiftCardsWithCountryList];function tx(e){let{shouldOpenStakePreferenceModal:t=!1,hasCashoutLimit:a,onCashoutLimit:r}=e,[,n]=(0,v.useRecoilState)(m.default),i=(0,j.useFeatureFlags)(e=>e.cashoutV2Settings),{methods:l}=(0,tl.default)({trackOfferingMethodsShown:!1}),[o,c]=(0,O.useMemo)(()=>i?.isTangoBackendEnabled&&(e.route!==h.MethodSlug.Mastercard||i.isMastercardEnabled)?[l.some(t=>t.slug===e.route),l.find(t=>t.slug===e.route)]:[!1,null],[i,l,e.route]),d=(0,th.useOnClickCashoutV2Card)();return e.isLoggedIn&&tp.includes(e.name)?(0,s.jsx)(eV.default,{style:{cursor:"pointer"},onClick:()=>{a&&r?r():e.name===h.Stake&&t?n(e=>({...e,showStakePreferenceModal:!0})):o&&c?d({method:c}):n(t=>({...t,selectedMethod:e.name}))},children:e.children}):(0,s.jsx)(eB.default,{href:`/cashout/${e.route}`,page:`withdraw/${e.route}`,children:e.children})}var tf=e.i(899432),tg=e.i(780387);let ty=()=>{let{t:e}=(0,p.default)("_cashout2024"),t=(0,j.useFeatureFlags)(e=>e.isMoneyLionEnabled),a=(0,eJ.default)();return t?(0,s.jsxs)("div",{className:"mt-0 sm:mt-[40px]",children:[!a&&(0,s.jsx)("p",{className:"m-0 hidden text-[20px] font-bold leading-[30px] tracking-[2%] text-core-neutral-0 sm:[display:initial]",children:e("loans")}),(0,s.jsx)("div",{className:"flex mt-[20px] mb-[10px] w-fit gap-[10px]",children:(0,s.jsx)("a",{href:"https://www.moneylion.com/network/freecash/loans/search",target:"_blank",rel:"noreferrer noopener",onClick:()=>tg.default.customEvent("MoneyLion affiliate link Clicked"),children:a?(0,s.jsx)("img",{src:"/img/cashout/legacy/moneyLionBannerMobile.png",alt:"MoneyLion loans promotion",className:"w-full object-contain"}
2):(0,s.jsx)("img",{src:"/img/cashout/legacy/moneyLionBannerDesktop.png",alt:"MoneyLion loans promotion",className:"w-auto max-w-full max-h-[204px] object-contain"})})})]}):null};var tb=e.i(124264);function tv(e){let{bottomAddons:t,rightAddons:a,...r}=e;return(0,s.jsxs)("div",{className:"relative w-fit h-full",children:[(0,s.jsx)(tb.default,{...r}),t&&!r.skeleton&&(0,s.jsx)("div",{className:"absolute bottom-0 left-0 right-0",children:t})]})}var tw=e.i(910633),tC=e.i(510840),tj=e.i(554047);function tk({method:e,giftCard:t,withdrawableNowBalance:a,onClick:r,skeleton:i}){let{t:l}=(0,p.default)("_cashout2024"),{t:o}=(0,C.useTranslationTyped)("_cashout2024"),c=a>=e.minimumCoinsAmount,d=(0,O.useMemo)(()=>{switch(t.brandName){case tj.AvailableSlotNamesEnum.low_risk_jackpot_case_v3:return{bg:(0,n.resolveColorToken)("core.freecashGreen.900"),subTitleBg:(0,n.resolveColorToken)("core.freecashGreen.25-A10"),coins:1e4,coinsColor:"white"};case tj.AvailableSlotNamesEnum.medium_risk_jackpot_case_v3:return{bg:(0,n.resolveColorToken)("core.blue.900"),subTitleBg:(0,n.resolveColorToken)("core.blue.25-A10"),coins:15e4,coinsColor:"white"};case tj.AvailableSlotNamesEnum.high_risk_jackpot_case_v3:return{bg:(0,n.resolveColorToken)("core.yellow.900"),subTitleBg:(0,n.resolveColorToken)("core.yellow.25-A10"),coins:599e3,coinsColor:(0,n.resolveColorToken)("core.yellow.500")};default:return{bg:(0,n.resolveColorToken)("core.freecashGreen.900"),subTitleBg:(0,n.resolveColorToken)("core.freecashGreen.25-A10"),coins:1e4,coinsColor:"white"}}},[t.brandName]),u=(0,tw.useCurrencyValues)({amount:d.coins}),m=(0,tj.getSlotDisplayDetails)(t.brandName,"Cashout"),h=d?.bg??(0,n.resolveColorToken)("core.greyBlue.600");return(0,s.jsx)(tv,{skeleton:i,isUnavailable:e.isUnavailable,onClick:r,style:{backgroundColor:h},className:"w-[220px] rounded-[8px] p-[8px] hover:cursor-pointer hover:border-none hover:outline-hidden active:border-none md:hover:outline-solid md:hover:outline-1 md:hover:outline-core-freecashGreen-500",children:(0,s.jsxs)("div",{className:"flex flex-col items-center relative w-full",children:[(0,s.jsx)("div",{className:"absolute top-[12px] left-1/2 -translate-x-1/2 -translate-y-1/2",children:(0,s.jsx)(tC.T,{t:o,i18nKey:"cases.title",values:u,variant:"sm",weight:"bold",color:"core.neutral.0",components:{coin:(0,s.jsx)("span",{className:"text-sm font-bold whitespace-nowrap",style:{color:d.coinsColor}})}})}),(0,s.jsx)("div",{className:"relative flex items-center justify-center min-h-[120px] max-h-[120px] rounded-[8px] w-full aspect-[2/1.3]",style:{background:e.bg},children:(0,s.jsx)("div",{className:"rounded-[8px] overflow-hidden w-full h-full md:h-[120px]",children:(0,s.jsx)("img",{src:t.imageUrl,alt:t.brandName,className:"h-full w-full object-cover"})})}),(0,s.jsx)("div",{className:"px-[8px] mt-[4px] rounded-[10px]",style:{background:d?.subTitleBg},children:(0,s.jsx)("p",{className:"m-0 text-[12px] text-core-neutral-0 text-center",children:l(m.i18nNameKey,m.fallbackName)})}),(0,s.jsx)(tB,{withdrawableNowBalance:a,withdrawMinCoins:e.minimumCoinsAmount}),(0,s.jsx)("div",{className:"flex items-center justify-center w-full",children:(0,s.jsx)("div",{className:"flex text-[10px] mt-[12px] gap-[0.5ch] text-core-neutral-0 w-full",children:c?(0,s.jsx)("div",{className:"flex items-center justify-center w-full text-[12px] text-core-freecashGreen-500 font-semibold",children:l("withdrawNow")}):(0,s.jsx)("div",{className:"flex items-center justify-center w-full",children:(0,s.jsx)(eD.CurrencyText,{amount:a,targetCurrency:t?.currency,fontSize:"10px",color:"core.neutral.0"})})})})]})})}var tN=e.i(668468),tS=e.i(910238),tF=e.i(400996),tT=e.i(337684),tE=e.i(712225),tA=e.i(775851),tR=e.i(537763),tM=e.i(409610),t_=e.i(14569),tI=e.i(201587);function tP({children:e}){let t=(0,O.useRef)(null),a=(0,O.useRef)(null),[r,n]=(0,O.useState)(),i=(0,O.useCallback)(()=>{let e=t.current,r=a.current;if(!e||!r)return;let s=e.clientWidth,i=Number.parseFloat(window.getComputedStyle(r).fontSize),l=r.getBoundingClientRect().width;s&&i&&l&&n(Math.min(.1/.86*s,s/(l/i)))},[]);return(0,O.useLayoutEffect)(()=>{i();let e=!1;document.fonts?.ready.then(()=>{e||i()});let a=new ResizeObserver(i);return t.current&&a.observe(t.current),()=>{e=!0,a.disconnect()}},[e,i]),(0,s.jsx)("div",{ref:t,className:"pointer-events-none absolute left-1/2 -translate-x-1/2 -translate-y-1/2 text-center",style:{to
2p:"73%",width:"86%"},children:(0,s.jsx)("span",{ref:a,className:"font-poppins inline-block whitespace-nowrap font-medium leading-none text-core-neutral-0",style:r?{fontSize:`${r}px`}:void 0,children:e})})}function tB({withdrawMinCoins:e=0,withdrawableNowBalance:t}){let a=t>=e;return(0,s.jsx)("div",{className:"mb-[5px] mt-[10px] [&_[role=progressbar]>div>div]:[transition:width_1s_ease-in-out]!",children:(0,s.jsx)(tI.default,{value:t,max:e,height:"8px",borderRadius:"full",trackColor:(0,n.resolveColorToken)("core.greyBlue.400"),filledColor:a?"core.freecashGreen.500":"white"})})}function tU({method:e,giftCard:t,withdrawableNowBalance:a,displayLowerFeesBadge:r,onClick:n,skeleton:i}){let{t:l}=(0,C.useTranslationTyped)("_cashout2024"),[o,c]=(0,O.useState)(t&&"imageUrl"in t),d=(0,tS.useCurrencyText)(),{triggerGate:u,activeGate:m,isProviderAvailable:p}=(0,tA.useCashoutGate)(),x=(0,th.getCashoutCardUnavailableReason)(e,t),f=null!==x,[g]=e.bonus?.()||[0,to.BonusType.CUSTOM],{canWithdraw:y,requiredCoins:b}=(0,O.useMemo)(()=>{if(!t)return{canWithdraw:a>=e.minimumCoinsAmount,requiredCoins:e.minimumCoinsAmount};{let e=d({amount:t.value,originalCurrency:t.currency,targetCurrency:tF.Currency.COINS,autoConvertToCoins:!1}).rawValue;return{canWithdraw:a>=e,requiredCoins:e}}},[t,d,a,e.minimumCoinsAmount]),v=()=>{if(!f){if(!p)return void n();if((0,tM.isAccountRestrictionGate)(m))return void u();y?m?u():n():u(tR.CashoutGate.CASHOUT_GOAL_NOT_MET,{goalAmount:b,amountLeftToWithdraw:Math.max(0,b-a),isMet:!1,justReached:!1,displayCurrency:t?.currency})}},j=e.slug===h.MethodSlug.Giftee?t_.GIFTEE_CURRENCY_DISPLAY:void 0,k=(0,O.useMemo)(()=>t?(0,s.jsx)(eD.CurrencyText,{amount:t.value,fontWeight:600,fontSize:"14px",color:f?"core.greyBlue.100":"white",targetCurrency:t.currency,originalCurrency:t.currency,...j}):(0,s.jsx)("p",{className:"m-0 font-semibold",children:l("cryptoWithdrawRange",{min:d({amount:e.minimumCoinsAmount,targetCurrency:"USER_CURRENCY",autoConvertToCoins:!1}).value,max:d({amount:e.maximumCoinsAmount,targetCurrency:"USER_CURRENCY",autoConvertToCoins:!1}).value})}),[d,t,f,e.maximumCoinsAmount,e.minimumCoinsAmount,l]);return e.slug===h.MethodSlug.Cases&&t&&"brand"in t?(0,s.jsx)(tk,{method:e,giftCard:t,withdrawableNowBalance:a,onClick:v}):(0,s.jsx)(tv,{skeleton:i,isUnavailable:f,variant:"primary",onClick:v,className:(0,w.cn)("h-auto w-[220px] rounded-[8px] bg-core-greyBlue-600 p-[8px]","border border-solid border-transparent","hover:cursor-pointer hover:border-core-freecashGreen-500","hover:outline-hidden md:hover:outline-solid md:hover:outline-1 md:hover:outline-core-freecashGreen-500","active:border-none",!1),header:(0,s.jsx)(tE.default,{giftCardCurrency:t?.currency,badgeTextClassName:(0,w.cn)("font-semibold text-sm",f?"text-core-greyBlue-100":"text-core-neutral-0"),children:k}),bonus:void 0,unavailableFallbackText:"outOfStock"===x?l("outOfStock"):void 0,bottomAddons:void 0,children:(0,s.jsxs)("div",{className:"flex flex-col items-center relative w-full h-full",children:[(0,s.jsxs)("div",{className:"relative flex aspect-8/5 w-full items-center justify-center overflow-hidden rounded-[8px]",style:{background:o?void 0:e.bg},children:[t&&"imageUrl"in t?(0,s.jsx)(ts.default,{giftCard:t,method:e,onError:()=>c(!1)}):(0,s.jsx)("img",{src:e.primaryLogo,alt:e.displayName,className:(0,th.cashoutLogoImageClass)(e.primaryLogo,"h-1/2 max-h-[50%] w-auto max-w-[50%] object-contain")}),(0,th.shouldLabelArtwork)(e)&&(0,s.jsx)(tP,{children:e.displayName}),r&&(0,s.jsx)(tT.default,{})]}),t?(0,s.jsx)(tN.default,{giftCard:t,withdrawableNowBalance:a}):(0,s.jsx)(tB,{withdrawableNowBalance:a,withdrawMinCoins:e.minimumCoinsAmount}),(0,s.jsx)("div",{className:"flex items-center justify-center w-full mt-0",children:(0,s.jsxs)("div",{className:(0,w.cn)("mt-[12px] flex w-full gap-[0.5ch] text-[10px]",f?"text-core-greyBlue-100":"text-core-neutral-0"),children:[!e.isUnavailable&&(0,s.jsx)(tO,{canWithdraw:y,withdrawableNowBalance:a,method:e,giftCard:t}),e.isUnavailable&&(0,s.jsx)("div",{className:"mt-[12px] w-full text-[10px] text-core-greyBlue-100",children:l("temporarilyUnavailable")})]})})]})})}let tO=({canWithdraw:e,withdrawableNowBalance:t,method:a,giftCard:r})=>{let{t:n}=(0,C.useTranslationTyped)("_cashout2024");return e?(0,s.jsx)("div",{className:"flex w-full items-center justify-center text-xs font-semibold text-core-freecashGreen-500",children:n("withdrawNow")}):r?(0,s.jsx)(tE.default,{giftCardCurrency:r?.currency,badgeTextClassName:"text-core-neutral-0 text-[10px]",children:(0,s.jsxs)("div",{className:"flex items-center justify-center w-full",children:[(0,s.jsx)(eD.CurrencyText,{amount:t,targetCurrency:r?.currency,color:"core.neutral.0",fontSize:"10px"}),(0,s.jsx)("span",{className:"mx-1",children:"/"}),(0,s.jsx)(eD.CurrencyText,{amount:r?.value,originalCurrency:r?.currency,targetCurrency:r?.currency,fontSize:"10px"})]})}):(0,s.jsxs)("div",{className:"flex justify-between w-full",children:[(0,s.jsx)("div",{className:"m-0 text-core-greyBlue-50 text-[10px]",children:n("minimumWithdraw","Minimum withdrawal")}),(0,s.jsx)(eD.CurrencyText,{amount:a.minimumCoinsAmount,targetCurrency:"USER_CURRENCY",fontSize:"10px"})]})};var tG=e.i(300524),tL=e.i(849607);function tD({method:e,onClick:t,onWithdrawClick:a,skeleton:r}){let n=(0,eK.useAsyncPopup)(),i=(0,th.useOnClickCashoutV2Card)(),{withdrawableNowBalance:l}=(0,x.default)(),o=e.giftCards||[],{userInfo:c}=(0,tG.default)(),{isCashoutGoalEnabled:d,minWithdrawableCoins:u}=(0,eG.default)(),{t:m}=(0,C.useTranslationTyped)("_cashout"),p=(0,tS.useCurrencyText)(),{isProviderAvailable:f}=(0,tA.useCashoutGate)(),g=(0,O.useCallback)(r=>{if((0,th.isCashoutCardUnavailable)(e,r))return;if(t)return void t(r);let l=p({amount:r.value,originalCurrency:r.currency,targetCurrency:"COINS"}).rawValue;if(!f&&d&&!c?.totalWithdrawn&&l<Number(u??2e4))return void n.trigger({name:eK.AllowedAsyncPopupName.GENERIC_FEEDBACK,args:{title:m("cashoutV2ErrorTitle.MinWithdrawableCoins"),content:(0,s.jsx)(tC.T,{t:m,i18nKey:"cashoutV2ErrorMessages.MinWithdrawableCoins",values:{minWithdrawableCoins:p({amount:Number(u??2e4)}).value},components:tL.default})}});let o={method:e,giftCard:r};a?a(o):i(o)},[t,a,p,d,c?.totalWithdrawn,u,n,i,m,e,f]),y=(0,th.isProviderFeeEnabled)(e);return(0,s.jsx)("div",{className:"flex gap-[10px] flex-nowrap md:flex-wrap",children:o.map((t,a)=>e.slug===h.MethodSlug.PayPal&&1===t.value&&t.currency===R.AvailableCurrencies.Usd?null:(0,s.jsx)(tU,{method:e,giftCard:t,displayLowerFeesBadge:"brand"in t&&y&&!t.providerFee,withdrawableNowBalance:l||0,onClick:()=>g(t),skeleton:r},e.slug+t.currency+t.value+a))})}var tV=e.i(675346),tW=e.i(533940),tK=e.i(610669),tz=e.i(177507);function tH({isMobile:e,children:t}){return e?(0,s.jsxs)("div",{className:"flex overflow-x-auto scrollbar-none [-ms-overflow-style:none] [&::-webkit-scrollbar]:hidden [&::-webkit-scrollbar-thumb]:hidden [&::-webkit-scrollbar-track]:hidden",children:[t,(0,s.jsx)("div",{className:"flex-none w-[8px]"})]}):(0,s.jsx)(s.Fragment,{children:t})}function tq(){let[e,t]=(0,O.useState)(null),a=(0,eJ.default)(),{arcadeCases:r,slotsToDisplay:n}=function(){let e=(0,j.useFeatureFlags)(e=>e.cashoutV2Settings),t=!!e?.isArcadeBonusCashout,a=e?.arcadeDisplayVariant,{data:r}=(0,q.useQuery)({queryKey:[i.QueryKeys.GRAPHQL_JACKPOT_GET_SLOTS],queryFn:()=>K.default.graphql.request(tV.GET_SLOTS_QUERY),enabled:t}),{isIosAppWebView:s}=(0,eO.useIosAppV2UiMode)(),n=(0,O.useMemo)(()=>
2{if(a===tf.ArcadeDisplayVariantEnum.CASE_V2){let e=r?.data?.getSlots.items.find(e=>e.name===tj.AvailableSlotNamesEnum.cashout_jackpot_case_v1);if(e)return[tj.AvailableSlotNamesEnum.cashout_jackpot_case_v1_paypal,tj.AvailableSlotNamesEnum.cashout_jackpot_case_v1_apple,tj.AvailableSlotNamesEnum.cashout_jackpot_case_v1_amazon,tj.AvailableSlotNamesEnum.cashout_jackpot_case_v1_google,tj.AvailableSlotNamesEnum.cashout_jackpot_case_v1_mastercard,tj.AvailableSlotNamesEnum.cashout_jackpot_case_v1_visa].map(t=>({...e,name:t})).filter(Boolean)}return[tj.AvailableSlotNamesEnum.low_risk_jackpot_case_v3,tj.AvailableSlotNamesEnum.medium_risk_jackpot_case_v3,tj.AvailableSlotNamesEnum.high_risk_jackpot_case_v3].map(e=>r?.data?.getSlots.items.find(t=>t.name===e)).filter(Boolean)},[a,r]);return{arcadeCases:(0,O.useMemo)(()=>{if(!t||s)return null;let e=n.map(e=>{let t=(0,tj.getSlotDisplayDetails)(e.name,"Cashout");return{brand:null,brandName:e.name,country:R.CountryCode.Us,currency:R.AvailableCurrencies.Usd,disclaimer:e.name,enabled:!0,id:e.id,imageUrl:t.image,status:R.GiftCardStatus.Available,value:e.inventoryItemAmount/1e3}});return{slug:h.MethodSlug.Cases,displayName:h.Cases,primaryLogo:"/img/cashout/legacy/cases/box-1.png",bg:"none",minimumCoinsAmount:Math.min(Number(n[0]?.inventoryItemAmount))??0,maximumCoinsAmount:Math.max(Number(n[0]?.inventoryItemAmount))??0,fee:()=>[0,to.FeeType.FIXED],bonus:()=>[0,to.BonusType.PERCENTAGE_BONUS],giftCards:(0,tW.default)(e,"value","asc"),viewMode:"default",isUnavailable:!1}},[t,n,s]),slotsToDisplay:n}}(),l=!!r?.giftCards?.length;return(0,s.jsxs)(s.Fragment,{children:[l&&(0,s.jsx)(tK.default,{targetId:a?"arcade-case-mobile":"arcade-case-desktop",children:r&&(0,s.jsxs)("div",{className:"w-full md:w-auto min-w-0 md:min-w-auto",children:[(0,s.jsx)("p",{className:"m-0 text-[20px] font-bold text-core-neutral-0",children:r.displayName}),(0,s.jsx)("div",{className:"mt-[12px] whitespace-nowrap",children:(0,s.jsx)(tH,{isMobile:a,children:(0,s.jsx)(tD,{method:r,onClick:e=>{if("brandName"in e){let a=n.find(t=>t.name===e.brandName);a&&t(a)}}},r.slug)})})]},r.slug)}),e&&(0,s.jsx)(tz.default,{slot:e,source:"Cashout",onClose:()=>{t(null)}})]})}var t$=e.i(550202);function tQ({boxProps:e,trailingSpace:t,children:a}){let{className:r,style:n,rest:i}=(0,te.splitChakraBoxProps)(e);return(0,s.jsxs)("div",{className:(0,w.cn)("horizontal-scroll-container flex overflow-x-auto whitespace-nowrap","min-w-[calc(100vw-16px)] md:min-w-auto","scrollbar-none [-ms-overflow-style:none] [&::-webkit-scrollbar]:hidden [&::-webkit-scrollbar-thumb]:hidden [&::-webkit-scrollbar-track]:hidden",r),style:n,...i,children:[a,(0,s.jsx)("div",{className:"flex-none",style:{width:t}})]})}function tZ({children:e}){return(0,s.jsx)("div",{className:"contents phoneMax:hidden",children:e})}function tY({children:e}){return(0,s.jsx)("div",{className:"hidden phoneMax:contents",children:e})}e.i(534577);var tX=e.i(118734);let tJ=({offer:e})=>{let{t}=(0,t$.default)(["_cashout","_cashout2024"]);return(0,s.jsxs)("div",{className:"w-[220px] h-[202px] relative flex flex-col items-center cursor-pointer p-[8px] bg-core-greyBlue-600 rounded-[8px] z-1",onClick:()=>(0,tX.openOfferModal)({isLoggedIn:!0,slug:e.slug,source:R.OfferClickSource.CashoutPage,offerPosition:0,openOptions:{isCashoutBoostOffer:!0}}),children:[(0,s.jsx)("div",{className:"flex justify-center items-center",children:(0,s.jsx)(eU.default,{as:"span",fontSize:"14px",fontWeight:600,color:"core.neutral.0",mb:"8px",textAlign:"center",textOverflow:"ellipsis",whiteSpace:"nowrap",children:e.title||t("cashoutBoosts.title")})}),(0,s.jsx)("div",{className:"w-[204px] md:w-[188px] h-[120px] mt-[9px] bg-cover bg-no-repeat rounded-[8px]",style:{backgroundImage:`url(${e.image||"/public/img/cashout2024/boost-placeholder.png"})`,backgroundPosition:e.slug?.includes("coinbase")?"-9px center":"center"}}),(0,s.jsxs)("div",{className:"flex items-center gap-[8px] mt-[10px] justify-center",children:[(0,s.jsx)(eU.default,{as:"span",fontSize:"12px",fontWeight:600,color:"core.greyBlue.25",children:t("earnUpTo")}),(0,s.jsx)(eD.CurrencyText,{amount:e.coins??0,targetCurrency:"USER_CURRENCY",fontSize:"12px",fontWeight:600,color:"core.freecashGreen.500"})]})]})},t0=({offers:e})=>{let{t}=(0,t$.default)("_cashout2024");return(0,s.jsxs)("div",{className:"flex flex-col w-full gap-[10px]",children:[(0,s.jsx)("div",{className:"flex items-center",children:(0,s.jsx)("p",{className:"m-0 text-[20px] font-bold text-core-neutral-0",children:t("cashoutBoosts.title")})}),(0,s.jsxs)("div",{className:"flex gap-[10px] flex-wrap",children:[(0,s.jsx)(tY,{children:e?.map(e=>{if(e.status!==R.OfferStatusEnum.Credited&&e.canStart)return(0,s.jsx)(s.Fragment,{children:(0,s.jsx)(tJ,{offer:e})})})}),(0,s.jsx)(tZ,{children:(0,s.jsx)(tQ,{trailingSpace:"24px",children:(0,s.jsx)("div",{className:"flex gap-[10px]",children:e?.map(e=>{if(e.status!==R.OfferStatusEnum.Credited&&e.canStart)return(0,s.jsx)(s.Fragment,{children:(0,s.jsx)(tJ,{offer:e})})})})})})]})]})};
2var t1=e.i(661465),t2=e.i(212651);function t3({method:e,withdrawableNowBalance:t,onWithdrawClick:a,skeleton:r}){let{t:i}=(0,C.useTranslationTyped)("_cashout2024"),l=(0,th.useOnClickCashoutV2Card)(),o=t>=e.minimumCoinsAmount,[c,d]=(0,O.useState)(!!e.giftCards?.[0]),{triggerGate:u,activeGate:m,isProviderAvailable:h}=(0,tA.useCashoutGate)(),p=()=>{a?a({method:e}):l({method:e})};return(0,s.jsx)(tb.default,{skeleton:r,isUnavailable:e.isUnavailable,variant:"primary",onClick:()=>{h?(0,tM.isAccountRestrictionGate)(m)?u():o?m?u():p():u(tR.CashoutGate.CASHOUT_GOAL_NOT_MET,{goalAmount:e.minimumCoinsAmount,amountLeftToWithdraw:Math.max(0,e.minimumCoinsAmount-t),isMet:!1,justReached:!1,displayCurrency:e.giftCards?.[0]?.currency}):p()},className:"rounded-[8px] bg-core-greyBlue-600 p-[4px_16px] w-[220px] min-w-[220px] h-auto cursor-pointer md:hover:outline-solid md:hover:outline-1 md:hover:outline-core-freecashGreen-500",header:(0,s.jsx)("div",{className:"m-0 text-center text-sm font-semibold my-[5px]",children:(0,s.jsx)(tE.default,{giftCardCurrency:e?.giftCards?.[0]?.currency,badgeTextClassName:"text-sm font-semibold",children:e.displayName})}),bonus:e.bonus?.(),footer:(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("div",{className:"my-[5px] [&>div>div>div]:[transition:width_1s_ease-in-out]!",children:(0,s.jsx)(tI.default,{value:t,max:e.minimumCoinsAmount,height:"8px",borderRadius:"full",trackColor:(0,n.resolveColorToken)("core.greyBlue.400"),filledColor:o?"core.freecashGreen.500":"white"})}),(0,s.jsxs)("div",{className:(0,w.cn)("flex items-center",o?"justify-center":"justify-between"),children:[!e.isUnavailable&&(0,s.jsx)(t5,{canWithdraw:o,withdrawableNowBalance:t,method:e}),e.isUnavailable&&(0,s.jsx)("div",{className:"flex items-center justify-center w-full text-xs mt-[12px] text-core-greyBlue-100",children:i("temporarilyUnavailable")})]})]}),children:(0,s.jsxs)("div",{className:"relative flex items-center justify-center overflow-hidden rounded-[8px] aspect-8/5",style:c?void 0:{background:e.bg},children:[e.giftCards?.[0]?(0,s.jsx)(ts.default,{giftCard:e.giftCards[0],method:e,onError:()=>d(!1)}):(0,s.jsx)("img",{src:e.primaryLogo,alt:e.displayName,className:(0,th.cashoutLogoImageClass)(e.primaryLogo,"w-[60%] h-[60%] max-h-[40px] object-contain")}),(0,th.shouldLabelArtwork)(e)&&(0,s.jsx)(tP,{children:e.displayName})]})})}let t5=({canWithdraw:e,withdrawableNowBalance:t,method:a})=>{let{t:r}=(0,C.useTranslationTyped)("_cashout2024"),{userCurrency:n}=(0,t2.useUserCurrencyInfo)(),i=(0,t1.getCurrencyConfig)({targetCurrency:n})?.symbol??"";return e?(0,s.jsx)("div",{className:"flex items-center justify-center w-full text-xs text-core-freecashGreen-500 font-semibold",children:r("withdrawNow")}):(0,s.jsxs)(tE.default,{giftCardCurrency:a?.giftCards?.[0]?.currency,badgeTextClassName:"text-[10px] font-[400]",children:[(0,s.jsx)("div",{className:"text-core-greyBlue-50 text-[10px]",children:(0,s.jsx)("p",{className:"m-0 text-[7px] text-core-greyBlue-50",children:r("minimumWithCurrency",{currency:i})})}),(0,s.jsxs)("div",{className:"flex text-[10px]",children:[(0,s.jsx)(eD.CurrencyText,{amount:t,targetCurrency:"USER_CURRENCY",fontSize:"10px",currencyIconProps:{display:"none"}})," / ",(0,s.jsx)(eD.CurrencyText,{amount:a.minimumCoinsAmount,targetCurrency:"USER_CURRENCY",fontSize:"10px",currencyIconProps:{display:"none"}})]})]})},t4=e=>e&&!!e.giftCards?.length;function t8({methods:e,successfulOffers:t,shouldShowCashoutBoostsSection:a,skeleton:r}){let n=(0,j.useFeatureFlags)(e=>e.cashoutBoostsSection),{withdrawableNowBalance:i}=(0,x.default)(),l=(0,th.useOnClickCashoutV2Card)(),{t:o}=(0,C.useTranslationTyped)("_cashout2024");return 0===e.length?null:(0,s.jsxs)("div",{className:(0,w.cn)("flex gap-0 phoneMax:gap-2.5 flex-wrap pt-0","phoneMax:pt-0"),children:[(0,s.jsx)(tY,{children:e.map(e=>(0,s.jsx)(t3,{method:e,withdrawableNowBalance:i||0,skeleton:r},e.slug))}),(0,s.jsx)(tZ,{children:(0,s.jsx)("div",{className:"flex flex-col items-stretch gap-6 w-full",children:e.map(e=>{let[o]=e.bonus?.()||[0,to.BonusType.CUSTOM];return(0,s.jsxs)("div",{className:"contents",children:[e.slug===h.MethodSlug.PayPal&&n?.variant===tf.CashoutBoostsVariants.VARIANT_2&&a&&(0,s.jsx)(t0,{offers:t}),(0,s.jsxs)("div",{children:[(0,s.jsxs)("div",{className:"flex gap-2.5 mb-2.5 items-center w-full md:w-fit",children:[(0,s.jsx)("p",{className:"m-0 text-[20px] font-bold text-core-neutral-0",children:(0,s.jsx)(tE.default,{giftCardCurrency:e?.giftCards?.[0]?.currency,badgeTextClassName:"text-[20px] font-bold",children:e.displayName})}),!1,e.bonus&&(0,s.jsx)(tb.BonusTagDisplay,{bonus:e.bonus?.(),method:e})]}),t4(e)&&(0,s.jsx)(tQ,{trailingSpace:"24px",children:(0,s.jsx)(tD,{method:e,skeleton:r},e.slug)}),!t4(e)&&(0,s.jsx)("div",{className:"w-full",children:(0,s.jsx)(tU,{method:e,withdrawableNowBalance:i||0,skeleton:r,onClick:()=>{l({method:e})}})})]}),e.slug===h.MethodSlug.PayPal&&(0,s.jsx)(tK.PortalTarget,{id:"arcade-case-mobile"})]},e.slug)})})})]})}var t6=e.i(489665),t7=e.i(631875);function t9({cashoutAmountString:e}){let{t}=(0,C.useTranslationTyped)("_cashout2024");return(0,s.jsx)("div",{className:"flex-1 md:flex-[unset] w-[180px] md:w-[220px] bg-core-greyBlue-800 p-[24px] rounded-[12px]",children:(0,s.jsx)("p",{className:"m-0",children:(0,s.jsx)(tC.T,{t:t,i18nKey:"revolutFaucet.createAccountDesc",variant:"xs",color:"core.greyBlue.50",components:{b:(0,s.jsx)("span",{className:"m-0 text-core-greyBlue-50 text-[12px] md:text-sm font-semibold"}),green:(0,s.jsx)("span",{className:"m-0 text-core-freecashGreen-500 text-[12px] md:text-sm font-medium"})},values:{amount:e}})})})}function ae(){let{t:e}=(0,C.useTranslationTyped)("_cashout2024"),t=(0,eK.useAsyncPopup)(),a=(0,j.useFeatureFlags)(e=>e.revolutCashoutSettings),r=(0,tS.useCurrencyText)(),{isLoggedIn:n}=(0,t6.default)(),{data:i,isPending:l}=(0,t7.default)({type:R.WithdrawType.Revolut,providerName:R.WithdrawProvider.Revolut},{enabled:n}),o=(0,O.useMemo)(()=>r({amount:a?.faucet?.coins??0,targetCurrency:a?.faucet?.currency??"USD"}).value,[a?.faucet?.coins,a?.faucet?.currency,r]);return!a?.enableFaucet||!a?.faucet?.coins||!a?.faucet?.currency||!n||i?.data?.hasUserWithdrawal||l?null:(0,s.jsxs)("div",{className:"flex gap-[10px]",children:[(0,s.jsx)(eV.default,{flex:{base:"1",md:"unset"},onClick:()=>{t.trigger({name:eK.AllowedAsyncPopupName.REVOLUT_FAUCET,args:{revolutCashoutSettings:a}})},ref:()=>{tg.default.setUserProperties("User Interface Elements",{"Revolut Faucet":!0})},children:(0,s.jsx)("div",{className:"h-[224px] w-[170px] md:w-[220px] rounded-[10px] overflow-hidden",style:{backgroundImage:"url(/img/cashout/legacy/revolut-faucet-bg-square.png)",backgroundSize:"cover"},children:(0,s.jsxs)("div",{className:"flex flex-col items-center relative justify-between h-full",children:[(0,s.jsxs)("div",{className:"flex flex-col items-center h-fit relative z-1 text-center pt-[20px] gap-[9px]",children:[(0,s.jsx)("p",{className:"m-0",children:(0,s.jsx)(tC.T,{t:e,i18nKey:"revolutFaucet.free",variant:"3xl",color:"core.neutral.0",components:{b:(0,s.jsx)("span",{className:"m-0 text-[32px] font-semibold"})},values:{amount:o}})}
2),(0,s.jsx)("p",{className:"m-0 leading-[16px] text-md text-core-neutral-0 font-light whitespace-nowrap",children:e("revolutFaucet.instantlyWith")}),(0,s.jsx)("img",{src:"/img/cashout/legacy/revolut.png",className:"h-[14px] w-auto"})]}),(0,s.jsx)("img",{src:"/img/cashout/legacy/revolut-faucet-foreground-5.png",className:"w-auto h-[210px] translate-y-[-30px] object-cover right-0"})]})})}),(0,s.jsx)(t9,{cashoutAmountString:o})]})}let at=e=>(0,s.jsx)(e0.default,{...e,viewBox:"0 0 22 18",children:(0,s.jsx)("path",{d:"M15.0838 8.34996C15.0238 8.27562 14.9512 8.29023 14.9131 8.3054C14.8812 8.3182 14.8081 8.35911 14.8182 8.46163C14.8304 8.58474 14.8372 8.71025 14.8385 8.83473C14.8439 9.35112 14.6346 9.85704 14.2644 10.2227C13.8965 10.5861 13.4126 10.7818 12.8973 10.7762C12.1936 10.7673 11.6098 10.4039 11.2092 9.72529C10.878 9.16417 11.0236 8.44045 11.1777 7.67419C11.2679 7.22568 11.3612 6.76188 11.3612 6.32046C11.3612 2.88345 9.02705 0.900536 7.6357 0.0244491C7.60693 0.00635935 7.57954 0 7.55527 0C7.51582 0 7.48456 0.0168437 7.46915 0.0271561C7.43929 0.0471795 7.3915 0.0928121 7.40686 0.173593C7.93868 2.96921 6.35244 4.65062 4.67304 6.43072C2.94199 8.26561 0.97998 10.3453 0.97998 14.0961C0.97998 18.4544 4.56175 22 8.96437 22C12.5893 22 15.7854 19.4982 16.7365 15.9161C17.3851 13.4736 16.7054 10.3623 15.0838 8.34996ZM9.16357 20.3129C8.06113 20.3627 7.01269 19.9713 6.21189 19.2133C5.41968 18.4634 4.9653 17.4169 4.9653 16.3421C4.9653 14.3251 5.74436 12.8444 7.83976 10.8787C7.87405 10.8465 7.90916 10.8363 7.93977 10.8363C7.9675 10.8363 7.99155 10.8447 8.00809 10.8526C8.04294 10.8692 8.10024 10.9104 8.09251 10.9994C8.01759 11.8624 8.0189 12.5788 8.09633 13.1286C8.29427 14.533 9.33285 15.4766 10.6808 15.4766C11.3417 15.4766 11.9713 15.2304 12.4535 14.7833C12.5094 14.7314 12.5719 14.7381 12.5959 14.7431C12.6276 14.7499 12.6701 14.7691 12.6924 14.8223C12.8923 15.3001 12.9945 15.8074 12.996 16.3298C13.0024 18.4321 11.2832 20.2189 9.16357 20.3129Z",fill:"inherit"})});function aa({show:e}){let{t}=(0,p.default)("_cashout2024"),a=(0,eJ.default)();return e?(0,s.jsxs)("div",{children:[(0,s.jsxs)("div",{className:"flex mb-[16px] gap-0 md:gap-[3px] items-center",children:[!a&&(0,s.jsx)(at,{fontSize:"20px",fill:"highlight.orange.400"}),(0,s.jsx)("p",{className:"m-0 text-[16px] md:text-[20px] font-bold text-core-neutral-0",children:t("freeCashoutSectionTitle")})]}),(0,s.jsx)(ae,{})]}):null}var ar=e.i(56792);let as=e=>(0,s.jsx)(e0.default,{...e,viewBox:"0 0 12 12",fill:"none",children:(0,s.jsx)("path",{d:"M7.80624 5.06464C7.77377 5.02438 7.73441 5.03229 7.71379 5.0405C7.69651 5.04744 7.65691 5.0696 7.66239 5.12513C7.66898 5.19181 7.67267 5.2598 7.67337 5.32722C7.67631 5.60694 7.56296 5.88098 7.36241 6.07907C7.16312 6.27588 6.90101 6.38192 6.62192 6.37884C6.2407 6.37403 5.92452 6.17719 5.70753 5.80962C5.52811 5.50567 5.60697 5.11366 5.69046 4.6986C5.73931 4.45566 5.78984 4.20443 5.78984 3.96533C5.78984 2.10362 4.52552 1.02954 3.77187 0.554991C3.75628 0.545193 3.74145 0.541748 3.7283 0.541748C3.70693 0.541748 3.69 0.550872 3.68166 0.556458C3.66548 0.567304 3.63959 0.592021 3.64792 0.635778C3.93598 2.15007 3.07677 3.06083 2.1671 4.02505C1.22944 5.01895 0.166687 6.14547 0.166687 8.17716C0.166687 10.5379 2.10681 12.4584 4.49157 12.4584C6.45508 12.4584 8.18628 11.1033 8.70147 9.16296C9.05279 7.83996 8.68464 6.15469 7.80624 5.06464V5.06464ZM4.59946 11.5446C4.00231 11.5715 3.43441 11.3595 3.00064 10.949C2.57152 10.5428 2.3254 9.97592 2.3254 9.39373C2.3254 8.30119 2.74739 7.49915 3.8824 6.43438C3.90097 6.41694 3.91999 6.41143 3.93657 6.41143C3.95159 6.41143 3.96462 6.41597 3.97358 6.42023C3.99246 6.42923 4.02349 6.45153 4.01931 6.49976C3.97873 6.96723 3.97943 7.35524 4.02138 7.65306C4.12859 8.41379 4.69116 8.92493 5.42132 8.92493C5.77931 8.92493 6.1203 8.79156 6.38149 8.54939C6.4118 8.52128 6.44566 8.52486 6.45864 8.52758C6.47582 8.53126 6.49884 8.54169 6.5109 8.57048C6.6192 8.82932 6.67454 9.10407 6.67539 9.38707C6.67885 10.5258 5.74759 11.4937 4.59946 11.5446V11.5446Z",fill:"currentColor"})});function an({offer:e,skeleton:t}){let{t:a}=(0,C.useTranslationTyped)("_cashout2024"),r=e?.slug?.includes("coinbase")?"/public/img/coinbase.png":e?.thumbnailLarge??e?.thumbnail;return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("style",{children:"@keyframes coPulsate { 0%{box-shadow:0 0 0 0 var(--color-core-freecashGreen-500)} 50%,100%{box-shadow:0 0 0 5px var(--color-core-red-25-A10)} }"}),(0,s.jsxs)(tb.default,{skeleton:t,onClick:()=>{(0,tX.openOfferModal)({isLoggedIn:!0,slug:e?.slug||"",source:R.OfferClickSource.CashoutPage,offerPosition:0})},className:"rounded-[8px] bg-core-greyBlue-600 border border-solid border-core-freecashGreen-25-A10 p-[4px_16px] w-[250px] md:w-[220px] min-w-[220px] cursor-pointer md:hover:outline-solid md:hover:outline-1 md:hover:outline-core-freecashGreen-500 animate-[coPulsate_4s_infinite]",header:(0,s.jsxs)("div",{className:"flex gap-[4px] items-center",children:[(0,s.jsx)(as,{color:"core.freecashGreen.500",width:"15px",height:"15px"}),(0,s.jsx)("div",{className:"m-0 text-center text-core-freecashGreen-500 text-sm font-medium my-[5px]",children:a("specialOffer")})]}),children:[(0,s.jsx)("img",{src:r,alt:e?.name,className:"w-full h-[110px] rounded-[8px] object-cover"}),(0,s.jsxs)("div",{className:"flex items-center justify-between mt-[20px] md:mt-[10px]",children:[(0,s.jsx)("span",{className:"m-0 text-[12px] font-normal text-core-greyBlue-25",children:a("earnUpTo")}),(0,s.jsx)(eD.CurrencyText,{amount:e?.coins??0,targetCurrency:"USER_CURRENCY",fontSize:"18px",fontWeight:700,color:"core.freecashGreen.500"})]})]})]})}function ai({methods:e,offer:t,onWithdrawClick:a,skeleton:r}){let n=(0,th.useOnClickCashoutV2Card)(),{withdrawableNowBalance:i}=(0,x.default)();return(0,s.jsxs)("div",{className:"flex gap-[10px] py-[2px]",children:[t&&t.status!==ar.OfferStatus.CREDITED&&t.canStart&&(0,s.jsx)(an,{offer:t,skeleton:r},t?.id),e.map(e=>(0,s.jsx)(tU,{method:e,withdrawableNowBalance:i||0,skeleton:r,onClick:()=>{let t={method:e};a?a(t):n(t)}},e.slug))]})}var al=e.i(457391);let ao=e=>["crypto","cryptoStakePreselected"].includes(e);function ac({methods:e}){let t=(0,j.useFeatureFlags)(e=>e.cashoutOffers),{withdrawableNowBalance:a}=(0,x.default)(),r=(0,th.useOnClickCashoutV2Card)(),n=e.filter(e=>
2ao(e.viewMode)),i=e.filter(e=>!ao(e.viewMode)),{data:l}=(0,al.default)({slug:t?.offer},{enabled:!!t?.offer});return 0===e.length?null:(0,s.jsxs)("div",{className:"flex flex-col items-stretch gap-[24px] md:gap-[40px]",children:[(0,s.jsx)(tK.PortalTarget,{id:"arcade-case-desktop"}),(0,s.jsxs)("div",{children:[(0,s.jsx)("div",{className:"flex gap-[10px] items-center",children:(0,s.jsx)("p",{className:"m-0 text-[20px] font-bold text-core-neutral-0",children:"Crypto"})}),(0,s.jsxs)("div",{className:"flex gap-[10px] mt-[16px] flex-wrap",children:[(0,s.jsxs)(tY,{children:[l&&l.status!==ar.OfferStatus.CREDITED&&l.canStart&&(0,s.jsx)(an,{offer:l},l?.id),e.map(e=>(0,s.jsx)(t3,{method:e,withdrawableNowBalance:a||0},e.slug))]}),(0,s.jsx)(tZ,{children:(0,s.jsxs)("div",{className:"contents",children:[(0,s.jsx)(tQ,{trailingSpace:"24px",children:(0,s.jsx)(ai,{methods:n,offer:l})}),i.map(e=>(0,s.jsxs)("div",{children:[(0,s.jsxs)("div",{className:"flex gap-[10px] items-center",children:[(0,s.jsx)("p",{className:"m-0 text-[20px] font-bold text-core-neutral-0",children:(0,s.jsx)(tE.default,{giftCardCurrency:e?.giftCards?.[0]?.currency,badgeTextClassName:"text-[20px] font-bold",children:e.displayName})}),e.bonus&&(0,s.jsx)(tb.BonusTagDisplay,{bonus:e.bonus?.(),method:e})]}),e.giftCards?.length>0&&(0,s.jsx)(tQ,{trailingSpace:"24px",children:(0,s.jsx)(tD,{method:e},e.slug)}),!e.giftCards?.length&&(0,s.jsx)("div",{className:"w-full",children:(0,s.jsx)(tU,{method:e,withdrawableNowBalance:a||0,onClick:()=>r({method:e})})})]},e.displayName))]})})]})]})]})}var ad=e.i(522149);function au(){return(0,s.jsxs)("div",{"aria-hidden":!0,children:[(0,s.jsx)(tY,{children:(0,s.jsx)(ad.MethodCardRowSkeleton,{tone:"section",count:5})}),(0,s.jsx)(tZ,{children:(0,s.jsx)(ad.MethodRailsSkeleton,{tone:"section"})})]})}var am=e.i(73316);function ah(e){let{t}=(0,C.useTranslationTyped)(["_cashout2024","_common"]),a="error"===e.variant;return(0,s.jsx)(am.EmptyState,{variant:"card",role:"status",title:t(a?"offeringEmpty.errorTitle":"offeringEmpty.regionTitle"),description:t(a?"offeringEmpty.errorDescription":"offeringEmpty.regionDescription"),cta:"error"===e.variant?(0,s.jsx)(g.Button,{variant:"secondary",size:"sm",onClick:()=>void e.onRetry(),children:t("retry")}):void 0})}e.i(247167);var ap=e.i(540143),ax=e.i(869230),af=e.i(915823),ag=e.i(619273);function ay(e,t){let a=new Set(t);return e.filter(e=>!a.has(e))}var ab=class extends af.Subscribable{#e;#t;#a;#r;#s;#n;#i;#l;#o;#c=[];constructor(e,t,a){super(),this.#e=e,this.#r=a,this.#a=[],this.#s=[],this.#t=[],this.setQueries(t)}onSubscribe(){1===this.listeners.size&&this.#s.forEach(e=>{e.subscribe(t=>{this.#d(e,t)})})}onUnsubscribe(){this.listeners.size||this.destroy()}destroy(){this.listeners=new Set,this.#s.forEach(e=>{e.destroy()})}setQueries(e,t){this.#a=e,this.#r=t,ap.notifyManager.batch(()=>{let e=this.#s,t=this.#u(this.#a);t.forEach(e=>e.observer.setOptions(e.defaultedQueryOptions));let a=t.map(e=>e.observer),r=a.map(e=>e.getCurrentResult()),s=e.length!==a.length,n=a.some((t,a)=>t!==e[a]),i=s||n,l=!!i||r.some((e,t)=>{let a=this.#t[t];return!a||!(0,ag.shallowEqualObjects)(e,a)});(i||l)&&(i&&(this.#c=t,this.#s=a),this.#t=r,this.hasListeners()&&(i&&(ay(e,a).forEac
2h(e=>{e.destroy()}),ay(a,e).forEach(e=>{e.subscribe(t=>{this.#d(e,t)})})),this.#m()))})}getCurrentResult(){return this.#t}getQueries(){return this.#s.map(e=>e.getCurrentQuery())}getObservers(){return this.#s}getOptimisticResult(e,t){let a=this.#u(e),r=a.map(e=>e.observer.getOptimisticResult(e.defaultedQueryOptions)),s=a.map(e=>e.defaultedQueryOptions.queryHash);return[r,e=>this.#h(e??r,t,s),()=>this.#p(r,a)]}#p(e,t){return t.map((a,r)=>{let s=e[r];return a.defaultedQueryOptions.notifyOnChangeProps?s:a.observer.trackResult(s,e=>{t.forEach(t=>{t.observer.trackProp(e)})})})}#h(e,t,a){if(t){let r=this.#o,s=void 0!==a&&void 0!==r&&(r.length!==a.length||a.some((e,t)=>e!==r[t]));return(!this.#n||this.#t!==this.#l||s||t!==this.#i)&&(this.#i=t,this.#l=this.#t,void 0!==a&&(this.#o=a),this.#n=(0,ag.replaceEqualDeep)(this.#n,t(e))),this.#n}return e}#x(){return this.#r?.combine!==void 0&&this.#s.some((e,t)=>e.options.suspense&&this.#t[t]?.data===void 0)}#u(e){let t=new Map;this.#s.forEach(e=>{let a=e.options.queryHash;if(!a)return;let r=t.get(a);r?r.push(e):t.set(a,[e])});let a=[];return e.forEach(e=>{let r=this.#e.defaultQueryOptions(e),s=t.get(r.queryHash)?.shift()??new ax.QueryObserver(this.#e,r);a.push({defaultedQueryOptions:r,observer:s})}),a}#d(e,t){let a=this.#s.indexOf(e);if(-1!==a){var r;let e;this.#t=(r=this.#t,(e=r.slice(0))[a]=t,e),this.#m()}}#m(){if(this.hasListeners()){let e=this.#p(this.#t,this.#c),t=this.#x(),a=this.#n,r=t?a:this.#h(e,this.#r?.combine);(t||a!==r)&&ap.notifyManager.batch(()=>{this.listeners.forEach(e=>{e(this.#t)})})}}},av=e.i(381384),aw=e.i(673664),aC=e.i(427001),aj=e.i(254440);function ak(){let e=(0,j.useFeatureFlags)(e=>e.cashoutBoostsSection),t=e?.offers||[],a=function({queries:e,...t}){let a=(0,$.useQueryClient)(void 0),r=(0,av.useIsRestoring)(),s=(0,aw.useQueryErrorResetBoundary)(),n=O.useMemo(()=>e.map(e=>{let t=a.defaultQueryOptions(e);return t._optimisticResults=r?"isRestoring":"optimistic",t}),[e,a,r]);n.forEach(e=>{(0,aj.ensureSuspenseTimers)(e);let t=a.getQueryCache().get(e.queryHash);(0,aC.ensurePreventErrorBoundaryRetry)(e,s,t)}),(0,aC.useClearResetErrorBoundary)(s);let[i]=O.useState(()=>new ab(a,n,t)),[l,o,c]=i.getOptimisticResult(n,t.combine),d=!r&&!1!==t.subscribed;O.useSyncExternalStore(O.useCallback(e=>d?i.subscribe(ap.notifyManager.batchCalls(e)):ag.noop,[i,d]),()=>i.getCurrentResult(),()=>i.getCurrentResult()),O.useEffect(()=>{i.setQueries(n,t)},[n,t,i]);let u=l.some((e,t)=>(0,aj.shouldSuspend)(n[t],e))?l.flatMap((e,t)=>{let r=n[t];if(r&&(0,aj.shouldSuspend)(r,e)){let e=new ax.QueryObserver(a,r);return(0,aj.fetchOptimistic)(r,e,s)}return[]}):[];if(u.length>0)throw Promise.all(u);let m=l.find((e,t)=>{let r=n[t];return r&&(0,aC.getHasError)({result:e,errorResetBoundary:s,throwOnError:r.throwOnError,query:a.getQueryCache().get(r.queryHash),suspense:r.suspense})});if(m?.error)throw m.error;return o(c())}({queries:t.map(t=>({queryKey:[i.QueryKeys.GRAPHQL_GET_OFFER_QUERY,t.slug],queryFn:()=>K.default.offers.getOffer({slug:t.slug}),enabled:!!t.slug&&e?.enabled}))}),r=!!e?.enabled,s=r?a.filter(e=>e.data?.data).map(e=>{let a=e.data?.data?.getOffer,r=a?.slug,s=t.find(e=>e.slug===r),n=s?.image,i=s?.title;return a?.canStart?{...a,image:n,title:i}:null}).filter(Boolean):[];return{cashoutBoostsSection:e,successfulOffers:s,shouldShowCashoutBoostsSection:r&&s.length>0}}var aN=e.i(156889),aS=e.i(542579);function aF(){let{defaultMethods:e,provisionalDefaultMethods:t,otherMethods:a,isLoading:r,hasFetchError:n,refetchOffering:i,isRetryingOffering:l}=(0,tl.default)(),{successfulOffers:o,shouldShowCashoutBoostsSection:c}=ak(),{country:d}=(0,aS.default)(),{t:u}=(0,C.useTranslationTyped)("_cashout2024"),m=(0,j.useFeatureFlags)(e=>e.revolutCashoutSettings),h=(0,j.useFeatureFlags)(e=>e.cashoutBoostsSection),p=(0,eJ.default)(),x=!r&&0===e.length,f=r||x&&l,g=x&&n&&!l,y=x&&0===a.length&&!n&&!l,b=f?"skeleton":e.length?"cards":"empty";(0,aN.useRecordOfferingRender)({mostPopular:{rendered:b,loading:f,slugs:e.map(e=>e.slug)},moreOptions:{rendered:a.length?"cards":"empty",loading:r,slugs:a.map(e=>e.slug)}});let v=!m?.enableFaucet||!m?.faucet?.coins||!m?.faucet?.currency;return(0,s.jsxs)("div",{className:"flex flex-col items-stretch gap-6 md:gap-10",children:[(0,s.jsx)(tq,{}),(0,s.jsx)(aa,{show:!v}),"empty"!==b&&(0,s.jsxs)("div",{children:[(0,s.jsx)("p",{className:"m-0 mb-4 font-bold text-[20px] hidden md:block",children:u("mostPopular")}),"skeleton"===b?(0,s.jsx)("div",{role:"status","aria-busy":"true","aria-live":"polite","aria-label":u("offeringLoading"),children:t.length>0?(0,s.jsx)(t8,{methods:t,successfulOffers:o,shouldShowCashoutBoostsSection:c,skeleton:!0}):(0,s.jsx)(au,{})}):(0,s.jsx)(t8,{methods:e,successfulOffers:o,shouldShowCashoutBoostsSection:c})]}),g&&(0,s.jsx)(ah,{variant:"error",onRetry:i}),y&&(0,s.jsx)(ah,{variant:"region"}),c&&h?.variant===tf.CashoutBoostsVariants.VARIANT_1||c&&h?.variant===tf.CashoutBoostsVariants.VARIANT_2&&!p&&(0,s.jsx)(t0,{offers:o}),(0,s.jsx)(ac,{methods:a}),(0,s.jsx)(ty,{}),(0,s.jsxs)("div",{className:"flex flex-col gap-1 mt-15 mb-1",children:[(0,s.jsx)("p",{className:"m-0 mt-0 text-core-greyBlue-50 text-[12px]",children:u("genericDisclaimer")}),(0,s.jsx)("p",{className:"m-0 mt-0 text-core-greyBlue-50 text-[12px]",children:u(["KR","JP"].includes(d||"")?"genericLegalDisclaimerAlt":"genericLegalDisclaimer")})]})]})}var aT=e.i(388e3),aE=e.i(895496),aA=e.i(345425),aR=e.i(271944);let aM={[h.BankTransfer]:"showACH",[h.Airtm]:"showAirtm",[h.UberEats]:"showUberEats",[h.Doordash]:"showDoorDash",[h.Justeat]:"showJustEat",[h.Roblox]:"showRoblox",[h.Stake]:"showStake"};function a_(e){let{isSurveyLite:t}=e,{className:a}=(0,aT.default)(),{isLiteMode:r}=(0,aE.default)(),{stakeBonus:n,stakeUSBonus:i}=(0,k.useStakeBonus)(),l=(0,eR.useWithdrawMethodConfig)(),[,o]=(0,O.useState)(!1),{isLoggedIn:c}=(0,z.default)(),{country:d}=(0,aS.default)(),m=(0,j.useFeatureFlags)(e=>e.cashoutV2Settings),{isIosAppWebView:x}=(0,eO.useIosAppV2UiMode)(),f=(0,aA.isIosApp)()||(0,aA.isNewIosApp)()||x,g=!!m?.isCashoutRedesigned2024Enabled,y=(0,O.useMemo)(()=>{let e=(0,aR.default)((0,h.getMethods)(d));return m?.isTangoBackendEnabled&&m.isMastercardEnabled&&e[1].items.push(h.MastercardMethod),e},[d,m]),b=y.map(e=>e.items.some(e=>r&&h.LiteModeAllowedMethods.includes(e.name))),{isFetched:v,isStakeUSEnabled:C,hasSetStakePreference:N}=Q(),S=(0,O.useMemo)(()=>(0,u.getMethodsDisplayPerCountry)(y,d||"",l.isRevolutCashoutEnabled),[l.isRevolutCashoutEnabled,d,y]),{t:F}=(0,p.default)("_cashout"),T=!!(v&&C&&!N),E=(0,O.useMemo)(()=>C?i:n,[C,n,i]),A=()=>{o(!0)};return(0,s.jsx)("section",{id:"withdraw-cash-methods",children:g?(0,s.jsx)(aF,{}):(0,s.jsx)(s.Fragment,{children:S.map((e,n)=>r&&!b[n]?null:(0,s.jsxs)("div",{className:"mb-[24px]",children:[(0,s.jsxs)("h2",{className:"m-0 mb-[16px] flex items-center gap-[8px] text-[20px] font-bold",children:[(0,s.jsx)("img",{className:"h-[24px] w-[24px]",src:`/img/cashout/legacy/${e.prefixIcon}`,alt:""}),F(e.translationKey,e.title)]}),(0,s.jsx)("div",{className:(0,w.cn)(a,"grid grid-cols-3 md:grid-cols-[repeat(auto-fit,140px)] gap-[12px] justify-start"),children:e.items.map(e=>!function(e,t){if(!function(e,{isLiteMode:t,isSurveyLite:a}){return a?h.SurveyLiteModeAllowedMethods.includes(e):!t||h.LiteModeAllowedMethods.includes(e)}(e.name,t))return!1;let a=aM[e.name];return(!a||!1!==t.withdrawMethodConfig[a])&&!(e.name===h.Stake&&t.isIosAppUser)}(e,{isLiteMode:r,isSurveyLite:t,withdrawMethodConfig:l,isIosAppUser:f})?null:(0,s.jsx)(tx,{isLoggedIn:c,...e,shouldOpenStakePreferenceModal:T,onCashoutLimit:A,children:(0,s.jsx)(tm,{item:e,stakeBonus:"stake"===e.route?E:0})},e.name))})]},e.title+n))})})}function aI(e){return{discovery:{offerings:e.offeringResult.offerings,tremendousGiftcardBrandsName:e.offeringResult.tremendousGiftcardBrandsName,methodOrder:e.offeringResult.methodOrder,isFetched:e.offeringResult.isFetched,isCoreFetched:e.offeringResult.isCoreFetched,isCryptoFetched:e.offeringResult.isCryptoFetched,facts:e.offeringResult.facts},country:e.country,flags:{cashoutV2Settings:e.cashoutV2Settings,isTangoVenmoGiftCardsEnabled:e.isTangoVenmoGiftCardsEnabled,revolutCashoutEnabled:e.revolutCashoutEnabled,isStakeEnabled:e.isStakeEnabled,isStakeUSEnabled:e.isStakeUSEnabled,isCryptoV2CashoutEnabled:e.isCryptoV2CashoutEnabled,isKoreanGiftCardsEnabled:e.isKoreanGiftCardsEnabled,isKoreanGiftcardsV2Enabled:e.isKoreanGiftcardsV2Enabled,isJapaneseGiftCardsEnabled:e.isJapaneseGiftCardsEnabled,cashoutBoostsSection:e.cashoutBoostsSection},platform:{isIosAppUser:e.isIosAppUser,isIosAppWebView:e.isIosAppWebView},user:{hasRevolutWithdrawal:e.hasRevolutWithdrawal}}}var aP=e.i(191386),aB=e.i(847495),aU=e.i(283332);
2function aO(e,t){let a=(0,aU.getCatalogEntry)(e);if(a?.kind==="crypto"){let a;if(t.platform.isIosAppUser||(a=(0,aU.getCatalogEntry)(e),a?.kind==="crypto"&&a.fulfillableBy.includes(R.WithdrawProvider.Fireblocks)&&!t.flags.isCryptoV2CashoutEnabled))return!1}let r=(0,aP.mergeSlugPolicy)(aB.POLICY_REGISTRY.defaults,aB.POLICY_REGISTRY.bySlug[e]).visibility;return!(r?.fflag?.hidden||r?.fflag?.requiresFlag&&!function(e,t){if(!e)return!0;switch(e){case"isStashEnabled":return!!t.flags.cashoutV2Settings?.isStashEnabled;case"isGifteeEnabled":return!!t.flags.cashoutV2Settings?.isGifteeEnabled;case"isStakeEnabled":return!!t.flags.isStakeEnabled;case"isStakeUSEnabled":return!!t.flags.isStakeUSEnabled;case"revolutCashoutEnabled":return!!t.flags.revolutCashoutEnabled;case"isTangoVenmoGiftCardsEnabled":return!!t.flags.isTangoVenmoGiftCardsEnabled;case"isCryptoV2CashoutEnabled":return!!t.flags.isCryptoV2CashoutEnabled}return!1}(r.fflag.requiresFlag,t)||r?.country?.requiresCountry?.length&&!r.country.requiresCountry.includes(t.country)||r?.country?.excludeCountries?.includes(t.country)||r?.platform?.hideOnPlatform?.includes("iosApp")&&t.platform.isIosAppUser||r?.platform?.hideOnPlatform?.includes("iosWebView")&&t.platform.isIosAppWebView)}function aG(e,t){return t.discovery.offerings.has(e)&&aO(e,t)}let aL={crypto:{rows:["amount","exchangeRate","cryptoNetworkFee","withdrawalFee"],footer:"crypto"},stake:{rows:["amount","withdrawalFee","bonus"],footer:"crypto"},bank:{rows:["amount","withdrawalFee","consumerFee"],footer:"fiat"},default:{rows:["amount","consumerFee","withdrawalFee","bonus"],footer:"fiat"}},aD={kind:"emailActivation",underReviewKey:"withdrawFlow.submitted.underReviewV2",activationKey:"withdrawFlow.submitted.emailActivationV2"},aV={kind:"progressTimeline",steps:[{titleKey:"withdrawFlow.submitted.timeline.requestSubmitted",descriptionKey:"withdrawFlow.submitted.timeline.receivedJustNow"},{titleKey:"withdrawFlow.submitted.timeline.underReview",descriptionKey:"withdrawFlow.submitted.timeline.usuallyWithin1h"},{titleKey:"withdrawFlow.submitted.timeline.payoutSent",descriptionKey:"withdrawFlow.submitted.timeline.payoutSentDescription"}]},aW={kind:"progressTimeline",steps:[{titleKey:"withdrawFlow.submitted.timeline.requestSubmitted",descriptionKey:"withdrawFlow.submitted.timeline.receivedJustNow"},{titleKey:"withdrawFlow.submitted.timeline.underReview",descriptionKey:"withdrawFlow.submitted.timeline.usuallyWithin1h"},{titleKey:"withdrawFlow.submitted.timeline.payoutSent",descriptionKey:"withdrawFlow.submitted.timeline.payoutSentBlockchainDescription"}]},aK=[{i18nKey:"withdrawFlow.countryDisclaimer"},{i18nKey:"withdrawFlow.merchantDisclaimer"}],az=[{i18nKey:"withdrawFlow.revolutVerifyAccountDisclaimer"},{i18nKey:"withdrawFlow.revolutBankDisclaimer"}],aH=[{i18nKey:"withdrawFlow.countryDisclaimer"},{i18nKey:"withdrawFlow.gifteeMerchantDisclaimer"}];function aq(e,t){var a,r;let{id:s,winningProvider:n,legacyMethod:i}=e,l=(0,aP.mergeSlugPolicy)(aB.POLICY_REGISTRY.defaults,aB.POLICY_REGISTRY.bySlug[s]),o=l.presentation?.user??l.presentation?.fflag??l.presentation?.country??l.presentation?.platform,c=o?.withdraw,d=null!=n?aB.POLICY_REGISTRY.byProvider[n]:void 0,u=null!=n?aB.POLICY_REGISTRY.bySlugProvider?.[s]?.[n]:void 0,m=function(...e){return Object.assign({},...e.filter(Boolean))}(function(e){if("crypto"===e.viewMode)return{layoutFamily:"crypto",destinationKind:"cryptoWallet",submittedReviewInfoLayout:aW,amountFooterPromo:"stakeUpsell",collectEmail:!1,confirmAgreements:["nonRefundable"]};let t=e.slug===h.MethodSlug.StakeUS?"us":e.slug===h.MethodSlug.Stake?"com":void 0;return null!=t?"us"===t?{layoutFamily:"default",destinationKind:"stakeUsername",submittedReviewInfoLayout:"progressTimeline",collectEmail:!1,confirmAgreements:["nonRefundable"],stakeRoute:"us"}:{layoutFamily:"stake",destinationKind:"stakeUsername",submittedReviewInfoLayout:"progressTimeline",amountStepBanner:"stakeMinimum",collectEmail:!1,confirmAgreements:["nonRefundable"],stakeRoute:"com"}:e.slug===h.MethodSlug.Revolut?{destinationKind:"revolut",submittedReviewInfoLayout:"progressTimeline",collectEmail:!1}
2:"cryptoStakePreselected"===e.viewMode?{submittedReviewInfoLayout:"progressTimeline"}:{layoutFamily:"default",destinationKind:"email",submittedReviewInfoLayout:"emailActivation",collectEmail:!1}}(i),d,c,u),p="tangoTremendous"===(a=m.amountDisclaimer)?aK:"revolut"===a?az:"giftee"===a?aH:void 0,x=function(e,t){switch(e){case"usdPayoutInfo":return{presentation:"text",i18nKey:"withdrawFlow.amount.paypalInfo",values:{currency:"USD"}};case"bankTransferFee":return{presentation:"banner",i18nKey:"withdrawFlow.amount.bankTransferInfoValue",values:{percentage:t}};default:return}}(m.infoKind,m.bankTransferFeePercentage??aB.BANK_TRANSFER_FEE_PERCENTAGE),f=m.destinationKind??"email",g=m.collectEmail??!1,y=m.destinationAgreements??("email"===f&&g?["emailCorrect"]:[]),b=function(e,t){if(null==e||"stakeUpsell"!==e||null==t)return;let a=aG(h.MethodSlug.StakeUS,t)?"us":aG(h.MethodSlug.Stake,t)?"com":void 0;return null!=a?{kind:"stakeUpsell",stakeRoute:a}:void 0}(m.amountFooterPromo,t);return{amountSummary:{layout:m.layout?m.layout:aL[m.layoutFamily??"default"],amountLabelKey:m.amountLabelKey??"withdrawFlow.amount.summary.amount",...null!=x?{info:x}:{},...m.showConsumerFeeWhenFree?{showConsumerFeeWhenFree:!0}:{}},confirmSummary:function(e){switch(e){case"stakeUsername":return{rows:["youWillReceive","stakeUsername"]};case"bank":return{rows:["youWillReceive","bankFields"]};case"revolut":return{rows:["youWillReceive","revolutRevtag"]};case"cryptoWallet":return{rows:["youWillReceive","cryptoWallet"]};default:return{rows:["youWillReceive","email"]}}}(f),...null!=p?{amountDisclaimerLines:p}:{},...null!=b?{amountFooterPromo:b}:{},destinationKind:f,destinationCtaKey:function(e,t){if(t)return t;switch(e){case"stakeUsername":return"confirmStakeUsername";case"bank":return"confirmBankDetails";case"revolut":return"confirmRevolutDetails";case"cryptoWallet":return"confirmWalletAddress";case"email":return"confirmEmail"}}(f,m.destinationCtaKey),...null!=m.bankVariant?{bankVariant:m.bankVariant}:{},submittedReviewInfoLayout:null==(r=m.submittedReviewInfoLayout)||"emailActivation"===r?aD:"progressTimeline"===r?aV:"emailActivation"===r.kind?{kind:"emailActivation",underReviewKey:r.underReviewKey??aD.underReviewKey,activationKey:r.activationKey??aD.activationKey}:{kind:"progressTimeline",steps:r.steps??aV.steps},emailLabelKey:m.emailLabelKey??"withdrawFlow.destination.email.label",emailBannerKey:m.emailBannerKey??"withdrawFlow.destination.email.banner",confirmEmailLabelKey:m.confirmEmailLabelKey??"withdrawFlow.confirm.claimLinkSentTo",collectEmail:g,confirmAgreements:m.confirmAgreements??[],destinationAgreements:y,...null!=m.amountStepBanner?{amountStepBanner:m.amountStepBanner}:{},...null!=m.stakeRoute?{stakeRoute:m.stakeRoute}:{}}}function a$(e,t){return aq({id:e.slug,winningProvider:e.withdrawProvider,legacyMethod:e},t)}let aQ={mobileMethodRow:{bonusDisplay:"inlineTag"},methodGrid:{expandedTopPadding:!1}},aZ={mobileAnchorSlug:null,showAfterSection:!1};function aY(e,t){let a=t?function(e,t){if("mostPopular"!==e)return;let a=t.cashoutBoostsSection;return a?.enabled?a.variant===tf.CashoutBoostsVariants.VARIANT_2?{mobileAnchorSlug:h.MethodSlug.PayPal,showAfterSection:!0}:a.variant===tf.CashoutBoostsVariants.VARIANT_1?{mobileAnchorSlug:null,showAfterSection:!0}:aZ:aZ}(e,t):"mostPopular"===e?aZ:void 0;return{...aQ,...null!=a?{cashoutBoosts:a}:{}}}function aX(e){return{methods:[],presentation:aY(e)}}function aJ(e,t){let a=e.map(e=>({legacyMethod:e.legacyMethod,withdrawPresentation:aq(e,t.ctx)})),r=aY(t.section,t.ctx.flags),s=a.some(({legacyMethod:e})=>(function(e,t){if(!e.bonus||e.slug===h.MethodSlug.Revolut&&t.user.hasRevolutWithdrawal)return!1;let[a]=e.bonus();return!!a})(e,t.ctx));return{methods:a,presentation:{...r,methodGrid:{...r.methodGrid,expandedTopPadding:s}}}}var a0=e.i(782794);function a1(e,t,a){let r=new Map(e.map(e=>[e.id,e])),s=(0,aB.getOrderPrependForCountry)(t.country,{isKoreanGiftCardsEnabled:t.flags.isKoreanGiftCardsEnabled,isKoreanGiftcardsV2Enabled:t.flags.isKoreanGiftcardsV2Enabled,isJapaneseGiftCardsEnabled:t.flags.isJapaneseGiftCardsEnabled}),n=aB.POLICY_REGISTRY.orderGrouping.excludeCountries?.[t.country]??[];return[...new Set([...s,...t.discovery.methodOrder.length?t.discovery.methodOrder:a0.DEFAULT_METHODS_ORDER])].filter(e=>!n.includes(e)).map(e=>r.get(e)).filter(e=>{if(!e)return!1;
2let t=(0,aU.getCatalogEntry)(e.id);return t?.section===a})}var a2=e.i(871864);function a3(e){let t,a=function(e){let{tangoGiftCardsBrandsByStatus:t,tremendousAvailableSlugs:a}=e.discovery.facts;return t.available.length+t.unavailable.length+a.length}(e),r=(t=e.flags.cashoutV2Settings,!!(t?.isTangoBackendEnabled||t?.isTremendousEnabled)),s=function(e){let t=e.flags.cashoutV2Settings,a=!!t?.isTangoBackendEnabled,r=!!t?.isTremendousEnabled;if(!a&&!r)return!1;let s=!a||e.discovery.facts.isTangoUnavailable,n=!r||e.discovery.facts.isTremendousUnavailable;return s&&n}(e),n=e.discovery.offerings.size,i=e.discovery.isCoreFetched??e.discovery.isFetched,l=e.discovery.isCryptoFetched??e.discovery.isFetched;if(!i){let t=[...e.discovery.offerings.keys()];return{sections:{mostPopular:aX("mostPopular"),moreOptions:aX("moreOptions")},discoveredSlugCount:n,prioritizedSlugCount:0,discoveredSlugs:t,prioritizedSlugs:[],giftCardBrandCount:a,providersUnavailable:s,giftBackendsEnabled:r}}let o=(0,a2.applyProviderPrioritization)(e),c=o.filter(t=>aO(t.id,e)),d=[...e.discovery.offerings.keys()],u=o.map(e=>e.id);return{sections:{mostPopular:aJ(a1(c,e,"mostPopular"),{section:"mostPopular",ctx:e}),moreOptions:l?aJ(a1(c,e,"moreOptions"),{section:"moreOptions",ctx:e}):aX("moreOptions")},discoveredSlugCount:n,prioritizedSlugCount:o.length,discoveredSlugs:d,prioritizedSlugs:u,giftCardBrandCount:a,providersUnavailable:s,giftBackendsEnabled:r}}function a5(e,t,a=!1){return{methodId:e.slug,provider:t,giftCards:e.giftCards,limits:{minCoins:e.minimumCoinsAmount,maxCoins:e.maximumCoinsAmount},availability:a?"providerDisabled":e.isUnavailable?"unavailable":"available",legacyMethod:e}}function a4(e,t){let a=e.get(t.methodId)??[];a.push(t),e.set(t.methodId,a)}function a8(e,t){return[...e.entries()].filter(([,e])=>e.some(e=>e.provider===t&&"available"===e.availability&&!(e.giftCards?.length&&e.giftCards.every(e=>e.status===R.GiftCardStatus.Unavailable)))).map(([e])=>e)}var a6=e.i(335049),a7=e.i(526155),a9=e.i(864421),re=e.i(607671),rt=e.i(137322);e.i(436533);var ra=e.i(845938),rr=e.i(404282),rs=e.i(691541),rn=e.i(993533),ri=e.i(177846),rl=e.i(130100),ro=e.i(490764),rc=e.i(862012),rd=e.i(795450),ru=e.i(829243),rm=e.i(576955),rh=e.i(253885),rp=e.i(299855),rx=e.i(422041),rf=e.i(382015),rg=e.i(18277),ry=e.i(225185),rb=e.i(618566),rv=e.i(510830),rw=e.i(326999),rC=e.i(427509),rj=e.i(796263),rk=e.i(539644),rN=e.i(997176),rS=e.i(554460),rF=e.i(977789),rT=e.i(739557),rE=e.i(355299),rA=e.i(31129),rR=e.i(990332);let rM={xs:"w-[280px]",sm:"w-[320px]",md:"w-[400px]",lg:"w-[512px]",full:"w-screen max-w-none"},r_={xs:"max-h-[25dvh]",sm:"max-h-[33dvh]",md:"max-h-[50dvh]",lg:"max-h-[66dvh]",full:"h-dvh max-h-none"},rI={right:"inset-y-0 right-0 h-dvh border-l",left:"inset-y-0 left-0 h-dvh border-r",top:"inset-x-0 top-0 w-full rounded-b-06 border-b",bottom:"inset-x-0 bottom-0 w-full rounded-t-06 border-t"},rP={right:"top-[var(--header-height,0px)] bottom-0 right-0 h-[calc(100dvh-var(--header-height,0px))] border-l",left:"top-[var(--header-height,0px)] bottom-0 left-0 h-[calc(100dvh-var(--header-height,0px))] border-r",top:"inset-x-0 top-[var(--header-height,0px)] w-full rounded-b-06 border-b",bottom:"inset-x-0 bottom-0 w-full rounded-t-06 border-t"},rB="motion-reduce:data-[state=open]:animate-none motion-reduce:data-[state=closed]:animate-none",rU={right:(0,rC.cn)("data-[state=open]:animate-drawer-in-right data-[state=closed]:animate-drawer-out-right",rB),left:(0,rC.cn)("data-[state=open]:animate-drawer-in-left data-[state=closed]:animate-drawer-out-left",rB),top:(0,rC.cn)("data-[state=open]:animate-drawer-in-top data-[state=closed]:animate-drawer-out-top",rB),bottom:(0,rC.cn)("data-[state=open]:animate-sheet-in data-[state=closed]:animate-sheet-out",rB)},rO=({title:e,hideTitle:t,hideClose:a,ariaLabel:r})=>e?t?(0,s.jsx)(rS.SrOnlyDialogTitle,{children:e}):(0,s.jsx)("div",{className:(0,rC.cn)("shrink-0 px-4 pt-4 ds:px-6 ds:pt-6",!a&&"pr-14 ds:pr-16"),children:(0,s.jsx)(rw.Title,{asChild:!0,children:(0,s.jsx)(rR.Typography,{as:"h2",variant:"lg",weight:"semibold",color:"core.neutral.0",children:e})})}):(0,s.jsx)(rS.SrOnlyDialogTitle,{children:r??"Drawer"}),rG=({open:e,defaultOpen:t,onOpenChange:a,onClose:r,onCloseComplete:n,trigger:i,placement:l="right",size:o="md",title:c,hideTitle:d=!1,ariaLabel:u,hideClose:m=!1,closeLabel:h="Close",closeBorderless:p=!1,closeOnOverlayClick:x=!0,autoFocus:f=!0,initialFocusRef:g,zIndex:y,surface:b="base",belowHeader:v=!1,children:w,ref:C,...j})=>{let k=(0,rS.pickDataAttrs)(j),[N,S]=(0,rN.useControllableState)({value:e,defaultValue:t??!1,onChange:e=>{a?.(e),e||r?.()},name:"Drawer"}),F="left"===l||"right"===l,T=((e,t)=>{if("number"==typeof t)return;let a=e?rM[t]:r_[t];return e&&"full"!==t?(0,rC.cn)(a,"max-w-[calc(100vw-32px)]"):a})(F,o),E="number"!=typeof o?{}:F?{width:o}:{height:o},A=void 0!==y?{zIndex:y}:{},R=v?rP[l]:rI[l],M="full"===o,_=(0,rC.cn)("relative flex min-h-0 flex-col overflow-x-hidden overflow-y-auto",rk.HIDDEN_SCROLLBAR_CLASSES,F&&"flex-1",(F||"top"===l||"bottom"===l&&M)&&
2!v&&"mt-[var(--safe-area-top,0px)]",(F||"bottom"===l||"top"===l&&M)&&"mb-[var(--safe-area-bottom,0px)]"),I=O.default.useRef(null),P=(0,rS.buildOpenAutoFocusHandler)(g,f,I),B=(0,rS.buildCloseCompleteHandler)(n),U=O.default.useRef(null),G=(0,rS.buildDismissalProps)(x,f,U);return(0,rS.useCloseCompleteFallback)(N,n),(0,s.jsxs)(rw.Root,{open:N,onOpenChange:S,children:[i?(0,s.jsx)(rw.Trigger,{asChild:!0,children:i}):null,(0,s.jsxs)(rw.Portal,{children:[(0,s.jsx)(rT.OverlayScrim,{ref:U,testId:"drawer-scrim",zIndex:y,belowHeader:v}),(0,s.jsx)(rw.Content,{ref:(0,rj.mergeRefs)(C,I),"aria-describedby":void 0,"data-placement":l,...k,style:{...E,...A},onOpenAutoFocus:P,...G,onAnimationEnd:B,className:(0,rC.cn)("fixed z-[var(--z-overlay)] flex flex-col overflow-hidden outline-none","border-solid border-core-neutral-0-A10",rA.SURFACE_BG[b],R,rU[l],T),children:(0,s.jsxs)("div",{className:_,children:[(0,s.jsx)(rO,{title:c,hideTitle:d,hideClose:m,ariaLabel:u}),!m&&(0,s.jsx)(rF.OverlayCloseButton,{label:h,borderless:p}),w]})})]})]})},rL=(rE.OverlayHeader,rE.OverlayBody),rD=rE.OverlayFooter;var rV=e.i(183573),rW=e.i(247837);e.i(612386);var rK=e.i(610288),rz=e.i(69959),rH=e.i(111485),rq=e.i(156599),r$=e.i(994666);let rQ="[&_input]:autofill:shadow-[inset_0_0_0_1000px_var(--color-core-greyBlue-500)] [&_input]:autofill:[-webkit-text-fill-color:var(--color-core-neutral-0)] [&:hover_input]:autofill:shadow-[inset_0_0_0_1000px_var(--color-core-greyBlue-800)]";function rZ({coinsAmount:e,withdrawableNowBalance:t,maximumCoinsAmount:a,minimumCoinsAmount:r}){return null==e?{ok:!0}:null!=t&&e>t?{ok:!1,error:"insufficientBalance"}:null!=r&&r>0&&e<r?{ok:!1,error:"belowMinimum"}:null!=a&&a>0&&e>a?{ok:!1,error:"exceedsMaximum"}:{ok:!0}}function rY({giftCard:e,withdrawableNowBalance:t,giftCardValueToCoins:a}){return!e||!a||rZ({coinsAmount:a(e),withdrawableNowBalance:t}).ok}function rX({message:e}){return e?(0,s.jsx)(rz.FormErrorMessage,{children:(0,s.jsx)("span",{className:"text-xs font-regular",children:e})}):null}function rJ({error:e,invalidFormatMessage:t}){let{t:a}=(0,C.useTranslationTyped)("_cashout-v2"),r="required"===e?a("withdrawFlow.inputErrors.required"):e&&t;return(0,s.jsx)(rX,{message:r||null})}var r0=e.i(23106),r1=e.i(577854);function r2({visible:e,onClear:t}){let{t:a}=(0,C.useTranslationTyped)("_cashout-v2");return e?(0,s.jsx)(r0.IconButton,{variant:"overlay",borderless:!0,size:"xs",shape:"circle",icon:r1.XIcon,"aria-label":a("withdrawFlow.clearInput"),onMouseDown:e=>e.preventDefault(),onClick:t}):null}function r3(e,t,a){let r=parseFloat(e);if(!e||Number.isNaN(r))return null;let s=t({amount:r,originalCurrency:a,targetCurrency:tF.Currency.COINS}).amount;return s<1e3?Math.round(100*s)/100:Math.floor(s)}function r5({minimumCoinsAmount:e,maximumCoinsAmount:t,coinsAmount:a=null,onAmountChange:r}){let{t:n}=(0,C.useTranslationTyped)("_cashout-v2"),i=(0,O.useRef)(null),l=(0,O.useRef)(null),[o,c]=(0,O.useState)(""),d=(0,tS.useCurrencyText)(),{withdrawableNowBalance:u}=(0,x.default)(),{userCurrency:m}=(0,t2.useUserCurrencyInfo)(),h=(0,rq.default)(),p=r$.fiatCurrencySymbolMapping[m]??"$",f=d({amount:e,targetCurrency:tF.Currency.UserCurrency}).value,g=d({amount:t,targetCurrency:tF.Currency.UserCurrency}).value,y=d({amount:u??0,targetCurrency:tF.Currency.UserCurrency,roundingMode:"trunc"}).value,b=rZ({coinsAmount:r3(o,h,m),withdrawableNowBalance:u,maximumCoinsAmount:t,minimumCoinsAmount:e}),v=!b.ok,w=b.ok?null:"insufficientBalance"===b.error?n("withdrawFlow.inputErrors.notEnoughBalance"):"belowMinimum"===b.error?n("withdrawFlow.inputErrors.minWithdrawableCoins",{amount:f}):n("withdrawFlow.inputErrors.maxWithdrawableCoins",{amount:g});(0,O.useEffect)(()=>{i.current?.focus()},[]),(0,O.useEffect)(()=>{if(null==a){null!=l.current&&(l.current=null,c(""));return}a===l.current||(c(String(d({amount:a,originalCurrency:tF.Currency.COINS,targetCurrency:tF.Currency.UserCurrency}).getRoundedRawValue())),l.current=a)},[a,d]);let j=e=>{let t=function(e){let t=e.replace(/[^\d.,]/g,"");if(!t)return"";let a=t.search(/[.,]/);if(-1===a)return t;let r=t.slice(0,a).replace(/[.,]/g,""),s=t.slice(a+1).replace(/[^\d]/g,"");return s?`${r}.${s}`:`${r}.`}(e);c(t);let a=r3(t,h,m);l.current=a,r(a)};return(0,s.jsxs)(rz.FormField,{id:"withdraw-flow-amount",isInvalid:v,children:[(0,s.jsx)(rz.FormLabel,{children:(0,s.jsx)("span",{className:"text-sm text-core-neutral-0",children:n("withdrawFlow.amount.label")})}),(0,s.jsx)("div",{className:rQ,children:(0,s.jsx)(rH.InputField,{ref:i,size:"md",inputMode:"decimal",autoComplete:"off",value:o,onChange:e=>j(e.target.value),placeholder:n("withdrawFlow.amount.placeholder"),leftElement:(0,s.jsx)(rR.Typography,{variant:"sm",weight:"medium",color:"core.neutral.0",children:p}),rightElement:(0,s.jsx)(r2,{visible:!!o,onClear:()=>{j(""),i.current?.focus()}})})}),(0,s.jsx)(rX,{message:w}),!v&&(0,s.jsxs)("div",{className:"flex w-full justify-between gap-2",children:[(0,s.jsx)("div",{className:"min-w-0 flex-1",children:(0,s.jsx)(rz.FormHelperText,{children:(0,s.jsx)(rR.Typography,{variant:"micro",weight:"regular",color:"core.greyBlue.100",children:(0,s.jsx)("span",{className:"text-xs",children:n("withdrawFlow.amount.minimumToWithdraw",{amount:f})})})})}),(0,s.jsx)("div",{className:"shrink-0 whitespace-nowrap text-right",children:(0,s.jsx)(rR.Typography,{variant:"xs",weight:"regular",color:"core.greyBlue.50",children:(0,s.jsx)("span",{className:"text-xs font-regular text-core-greyBlue-25",children:(0,s.jsx)(Z.Trans,{t:n,i18nKey:"withdrawFlow.amount.balance",components:{em:(0,s.jsx)("span",{className:"text-xs font-semibold text-core-greyBlue-25"})},values:{amount:y}})})})})]})]})}var r4=e.i(392071),r8=e.i(463837),r6=e.i(30910),r7=e.i(178761),r9=e.i(495514);function se({content:e,ariaLabel:t,children:a,side:r="bottom"}){let[n,i]=(0,O.useState)(!1),l=(0,r9.useMediaQuery)("(hover: hover)"),o=(0,O.useRef)(null);(0,O.useEffect)(()=>()=>{o.current&&clearTimeout(o.current)},[]);let c=l?{onMouseEnter:()=>{o.current&&clearTimeout(o.current),i(!0)},onMouseLeave:()=>{o.current&&clearTimeout(o.current),o.current=setTimeout(()=>i(!1),120)}}:void 0,d=(0,s.jsx)("button",{type:"button","aria-label":t,className:"inline-flex shrink-0 cursor-pointer appearance-none border-0 bg-transparent p-0",...c,onClick:e=>{e.stopPropagation();let t=0===e.detail;(!l||t)&&i(e=>!e)},children:a??(0,s.jsx)(r8.Icon,{icon:r6.InfoIcon,size:"sm"})});return(0,s.jsxs)(r7.Root,{open:n,onOpenChange:e=>{e||i(!1)},children:[(0,s.jsx)(r7.Trigger,{asChild:!0,children:d}),(0,s.jsx)(r7.Portal,{children:(0,s.jsxs)(r7.Content,{side:r,sideOffset:6,avoidCollisions:!0,collisionPadding:8,sticky:"always",onOpenAutoFocus:e=>e.preventDefault(),className:"z-[1800] flex max-h-[var(--radix-popover-content-available-height)] max-w-[200px] items-center overflow-y-auto rounded-[8px] bg-core-greyBlue-300 px-[16px] py-[12px] outline-none",...c,children:["string"==typeof e?(0,s.jsx)(rR.Typography,{as:"span",weight:"regular",color:"core.greyBlue.25",children:(0,s.jsx)("span",{className:"text-xs leading-xs",children:e})}):e,(0,s.jsx)(r7.Arrow,{width:12,height:6,className:"fill-core-greyBlue-300"})]})})]})}function st({label:e,value:t,emphasize:a=!1,infoLabel:r,labelTag:n,labelSuffix:i}){let l="string"==typeof t?(0,s.jsx)(rR.Typography,{color:"core.neutral.0",weight:"semibold",children:(0,s.jsx)("span",{className:"shrink-0 text-[14px]",children:t})}):(0,s.jsx)("div",{className:"shrink-0",children:t});return(0,s.jsx)("div",{className:"w-full",children:(0,s.jsxs)(r4.Flex,{justify:"between",align:"center",gap:"sm",children:[(0,s.jsxs)("div",{className:"flex min-w-0 items-center gap-1",children:[(0,s.jsxs)("div",{className:"flex min-w-0 items-center gap-2",children:[(0,s.jsxs)("div",{className:"flex min-w-0 items-center gap-1",children:[(0,s.jsx)(rR.Typography,{color:a?"core.neutral.0":"core.greyBlue.50",weight:"medium",children:(0,s.jsx)("span",{className:(0,w.cn)("m-0 min-w-0 truncate text-[14px]"),children:e})}),i?(0,s.jsx)("span",{className:"shrink-0",children:i}):null]}),n?(0,s.jsx)("span",{className:"shrink-0",children:n}):null]}),r?(0,s.jsx)(se,{ariaLabel:r,content:r}):null]}),l]})})}function sa({text:e}){return(0,s.jsx)("div",{className:"w-full rounded-[var(--radius-03)] border border-solid border-core-blue-25-A50 bg-core-blue-25-A10 px-4 py-3",children:(0,s.jsx)(rR.Typography,{variant:"xs",weight:"regular",children:(0,s.jsx)("span",{className:"text-sm",children:e})})})}
2function sr({info:e,rows:t,footer:a}){return(0,s.jsxs)(r4.Flex,{direction:"column",gap:"lg",children:[e?.presentation==="text"&&(0,s.jsx)(rR.Typography,{variant:"xs",color:"core.blue.400",weight:"medium",children:e.content}),e?.presentation==="banner"&&(0,s.jsx)(sa,{text:e.content}),(0,s.jsx)("div",{className:"w-full",children:(0,s.jsx)(r4.Flex,{direction:"column",gap:"md",children:t.map(e=>(0,s.jsx)(st,{emphasize:e.emphasize,label:e.label,value:e.value,infoLabel:e.infoLabel,labelTag:e.labelTag,labelSuffix:e.labelSuffix},e.id))})}),(0,s.jsx)("div",{className:"w-full rounded-lg border border-solid border-core-greyBlue-400 bg-core-greyBlue-500 p-3",children:(0,s.jsxs)(r4.Flex,{align:"center",justify:"between",gap:"xs",children:[(0,s.jsx)(rR.Typography,{variant:"sm",color:"core.neutral.0",weight:"semibold",children:a.label}),a.value]})})]})}var ss=e.i(587768);let sn={1:"grid-cols-1",2:"grid-cols-2",3:"grid-cols-3",4:"grid-cols-4",5:"grid-cols-5",6:"grid-cols-6",7:"grid-cols-7",8:"grid-cols-8",9:"grid-cols-9",10:"grid-cols-10",11:"grid-cols-11",12:"grid-cols-12"},si={1:"ds:grid-cols-1",2:"ds:grid-cols-2",3:"ds:grid-cols-3",4:"ds:grid-cols-4",5:"ds:grid-cols-5",6:"ds:grid-cols-6",7:"ds:grid-cols-7",8:"ds:grid-cols-8",9:"ds:grid-cols-9",10:"ds:grid-cols-10",11:"ds:grid-cols-11",12:"ds:grid-cols-12"},sl=({as:e,cols:t,gap:a,gapX:r,gapY:n,bg:i,p:l,m:o,mx:c,my:d,grow:u,show:m,rounded:h,tone:p,position:x,inset:f,w:g,minW:y,maxW:b,h:v,minH:w,maxH:C,children:j,ref:k,...N})=>{let S;return"number"==typeof t?S=sn[t]:void 0!==t&&(S=(0,rC.cn)(sn[t.base],si[t.ds])),(0,s.jsx)(e||"div",{ref:k,className:(0,rC.cn)("grid",S,void 0!==a&&ss.GAP[a],void 0!==r&&ss.GAP_X[r],void 0!==n&&ss.GAP_Y[n],(0,ss.boxStyleClasses)({p:l,m:o,mx:c,my:d,grow:u,show:m,rounded:h,tone:p,position:x,inset:f})),style:(0,ss.resolveDimensionStyle)({w:g,minW:y,maxW:b,h:v,minH:w,maxH:C},(0,ss.resolveBgStyle)(i)),...N,children:j})};var so=e.i(456683);function sc({options:e=[],selectedId:t,onSelect:a}){let{t:r}=(0,C.useTranslationTyped)("_cashout-v2"),n=(0,tS.useCurrencyText)(),i=e.some(e=>e.hasLowerFees);return(0,s.jsxs)(r4.Flex,{direction:"column",gap:"lg",children:[(0,s.jsx)(sl,{cols:3,gap:"sm",children:e.map(({id:e,amount:r,currency:i,hasLowerFees:l,isDisabled:o})=>{let c=t===e;return(0,s.jsx)(so.SelectionCard,{type:"chip",amount:n({amount:r,originalCurrency:i,targetCurrency:i}).value,isSelected:c,isDisabled:o,showIndicator:l,onClick:()=>a(e),className:(0,w.cn)("w-full rounded-[16px]"," [&_p]:leading-none",o&&"[&_[data-testid=selection-card-indicator]]:bg-core-greyBlue-200"),size:"sm"},e)})}),i&&(0,s.jsxs)("div",{className:"flex items-center justify-center gap-2.5 rounded-lg bg-highlight-fuschia-25-A10 px-3.5 py-2.5",children:[(0,s.jsx)("div",{className:"h-2 w-2 rounded-full bg-core-neutral-0"}),(0,s.jsx)(rR.Typography,{weight:"medium",variant:"xs",children:(0,s.jsx)(Z.Trans,{t:r,i18nKey:"withdrawFlow.lowerFeesBanner",components:{lowFee:(0,s.jsx)(rR.Typography,{variant:"xs",color:"highlight.fuschia.500",as:"span",weight:"medium"})}})})]})]})}var sd=e.i(797328),su=e.i(328316);function sm({name:e,logoSrc:t,bonusPercent:a}){let{t:r}=(0,C.useTranslationTyped)("_cashout-v2");return(0,s.jsx)("div",{className:"w-full",children:(0,s.jsxs)(r4.Flex,{align:"center",justify:"between",children:[(0,s.jsxs)(r4.Flex,{align:"center",gap:"xs",children:[t?(0,s.jsx)(sd.Image,{src:t,alt:"",wrapperClassName:"size-12",aspectRatio:"1"}):null,(0,s.jsx)(rR.Typography,{variant:"lg",weight:"semibold",children:e})]}),null!=a&&(0,s.jsx)("div",{className:"shrink-0 whitespace-nowrap [&>*]:border-none [&>*]:px-4",children:(0,s.jsx)(su.Tag,{size:"sm",children:(0,s.jsx)(rR.Typography,{variant:"sm",color:"core.blue.300",weight:"semibold",children:r("withdrawFlow.stakeCryptoSelection.selectedCryptoBonus",{bonus:a})})})})]})})}let sh=[new Set(["USD","CAD","AUD"])];function sp(e){return e.trim().toUpperCase()}function sx(e,t){let a=sp(e),r=sp(t);return!!a&&!!r&&a!==r&&sh.some(e=>e.has(a)&&e.has(r))}var sf=e.i(819389);function sg({disambiguate:e,userCurrency:t,withdrawCurrency:a,targetCurrency:r}){if(e&&sx(t,a))return sp(r)||void 0}function sy({amount:e,targetCurrency:t,disambiguate:a,userCurrency:r,withdrawCurrency:n,className:i="text-[14px]",weight:l="semibold",originalCurrency:o}){return(0,s.jsx)(rR.Typography,{color:"core.neutral.0",weight:l,as:"span",children:(0,s.jsx)("span",{className:i,children:(0,s.jsx)(eD.CurrencyText,{display:"flex",alignItems:"center",fontSize:"inherit",amount:e,originalCurrency:o,targetCurrency:t,currencySymbolOverride:sg({disambiguate:a,userCurrency:r,withdrawCurrency:n,targetCurrency:t}),currencyIconProps:{width:"1.25em",height:"1.25em"},iconContainerProps:{display:"inline-flex",alignItems:"center"}})})})}
2function sb(e,t){return e?"coins"===e.type?e.value:t*e.value/100:0}function sv(e){let[t=0]=e.fee?.()??[0,to.FeeType.FIXED];return"number"==typeof t?t:0}function sw(e){let[t=0]=e.platformFee?.()??[0,to.FeeType.PERCENTAGE];return"number"==typeof t?t:0}function sC({amount:e,method:t}){let a=sv(t),r=sb({type:"percentage",value:sw(t)},e);return Math.max(0,e-a-r)}function sj({amount:e,consumerFee:t,withdrawalFee:a,bonusValue:r}){return Math.max(0,e-sb(t,e)-sb(a,e)+sb(r,e))}function sk(e,{currencyText:t,providerFeeInGiftCardCurrency:a}){if(e?.providerFee)return a?{type:"coins",value:t({amount:e.providerFee,originalCurrency:e.currency,targetCurrency:tF.Currency.COINS,autoConvertToCoins:!1}).rawValue}:{type:"coins",value:e.providerFee}}function sN(e,t,{currencyText:a}){if(!t)return;let[r=0,s=to.FeeType.FIXED]=e.fee({giftCard:t});return r?String(s).toUpperCase()===to.FeeType.PERCENTAGE?{type:"percentage",value:r}:{type:"coins",value:a({amount:r,originalCurrency:t.currency,targetCurrency:tF.Currency.COINS,autoConvertToCoins:!1}).rawValue}:void 0}function sS(e){return e.trim().toLowerCase()===tF.Currency.STAKECASH}function sF(e){return sS(e)?tF.Currency.USD:e}var sT=e.i(553827);function sE(e,t){let{t:a}=(0,C.useTranslationTyped)("_cashout-v2");return(0,O.useMemo)(()=>(function(e,t,a){let{destinationKind:r}=e.presentation,{method:s}=e;if("stakeUsername"===r){let r="com"===e.presentation.stakeRoute,n=t.stake?(0,rK.getCryptoCurrencyDisplayName)(t.stake.currency):s.displayName;return{name:r?a("withdrawFlow.amount.stakeSelectedCryptoMethodName",{selectedCryptoMethod:n}):s.displayName,logoSrc:(0,rK.getPaymentMethodLogoSrc)({withdrawalType:R.WithdrawType.Stake}),bonusPercent:t.stake?.bonusPercent}}return{name:s.displayName,logoSrc:(0,sT.getOfferingPrimaryLogo)({slug:s.slug,fallback:s.primaryLogo})}})(e,t,a),[e,t,a])}function sA(e,t,a){let{destinationKind:r}=e.presentation;return"stakeUsername"===r&&t.stake?.currency?t.stake.currency:"cryptoWallet"===r?(0,sf.getCryptoWithdrawCurrencyForSlug)(e.method.slug)??e.method.slug:t.giftCard?.currency?t.giftCard.currency:"revolut"===r?(0,ep.getWithdrawCurrency)(h.Revolut,a):"USD"}var sR=e.i(681307);let sM=[3,7,1,3,7,1,3,7,1],s_="[1-9A-HJ-NP-Za-km-z]",sI={[h.MethodSlug.Bitcoin]:/^[13][a-km-zA-HJ-NP-Z1-9]{25,34}$|^[bB][cC]1[pPqQ][a-zA-Z0-9]{38,58}$/,[h.MethodSlug.Litecoin]:RegExp(`^(L${s_}{25,61}|M${s_}{25,61}|3${s_}{25,61}|ltc1[a-zA-Z0-9]{11,59})$`),[h.MethodSlug.Ethereum]:/^0x[a-fA-F0-9]{40}$/,[h.MethodSlug.Dogecoin]:/^[DA9][1-9A-HJ-NP-Za-km-z]{33,34}$/,[h.MethodSlug.Solana]:/^[1-9A-HJ-NP-Za-km-z]{32,44}$/},sP={[h.MethodSlug.Bitcoin]:"withdrawFlow.inputErrors.cryptoAddressExample.bitcoin",[h.MethodSlug.Litecoin]:"withdrawFlow.inputErrors.cryptoAddressExample.litecoin",[h.MethodSlug.Ethereum]:"withdrawFlow.inputErrors.cryptoAddressExample.ethereum",[h.MethodSlug.Dogecoin]:"withdrawFlow.inputErrors.cryptoAddressExample.dogecoin",[h.MethodSlug.Solana]:"withdrawFlow.inputErrors.cryptoAddressExample.solana"},sB="required",sU="invalidFormat",sO=sR.z.string().min(1,sB),sG=sO.regex(/^[A-Z]{2}\d{2}[A-Z0-9]{11,30}$/i,sU).refine(function(e){let t=(e.slice(4)+e.slice(0,4)).toUpperCase(),a=0;for(let e of t)for(let t of/\d/.test(e)?e:String(e.charCodeAt(0)-55))a=(10*a+Number(t))%97;return 1===a},sU),sL=sO.regex(/^[A-Z]{4}[A-Z]{2}[A-Z0-9]{2}(?:[A-Z0-9]{3})?$/i,sU),sD=sO.regex(/^[A-Z0-9]{1,34}$/i,sU),sV=sO.regex(/^\d{4,17}$/,sU),sW=sO.regex(/^\d{9}$/,sU).refine(function(e){return sM.reduce((t,a,r)=>t+a*Number(e[r]),0)%10==0},sU),sK=sO.regex(/^\d{5}(?:-\d{4})?$/,sU),sz=sO.regex(/^(?=.{3,11}$)[A-Z0-9]+(?:[\s-][A-Z0-9]+)*$/i,sU),sH=sO.max(254,sU).regex(/^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/,sU).refine(e=>e.slice(0,e.lastIndexOf("@")).length<=64,sU),sq=sO.min(3,sU),s$=sO.regex(/^[\p{L}][\p{L}'\-.,]{1,}(?: [\p{L}][\p{L}'\-.,]+)+$/u,sU);function sQ(e){return sO.regex(sI[e],sU)}let sZ={[h.MethodSlug.Bitcoin]:sQ(h.MethodSlug.Bitcoin),[h.MethodSlug.Litecoin]:sQ(h.MethodSlug.Litecoin),[h.MethodSlug.Ethereum]:sQ(h.MethodSlug.Ethereum),[h.MethodSlug.Dogecoin]:sQ(h.MethodSlug.Dogecoin),[h.MethodSlug.Solana]:sQ(h.MethodSlug.Solana)},sY={accountHolderName:s$,accountNumber:sV,routingNumber:sW,postalCode:sK},sX={accountHolderName:sO,iban:sG,bic:sL,postalCode:sz},sJ={accountHolderName:sO,accountNumber:sD,bic:sL,postalCode:sz};function s0(e){switch(e){case"ach":return sY;case"iban":return sX;case"swift":return sJ}}function s1(e,t){let a=t?.trim()??"",r=(e??sO).safeParse(a);return r.success?null:r.error.issues[0]?.message===sB?sB:sU}function s2(e,t){return null===s1(e,t)}(0,w.cn)("w-full h-[40px] min-h-[48px] appearance-none rounded-[8px] px-[12px] py-[9.5px] text-md font-[400] leading-[21px]","bg-core-greyBlue-600 text-core-greyBlue-50 outline-hidden border border-solid border-core-greyBlue-300","shadow-[0px_1px_2px_0px_rgba(20,21,35,0.05)]","placeholder:text-core-greyBlue-50 placeholder:text-md","focus:border-core-greyBlue-25 focus:text-core-neutral-0");let s3={paypalReceivable:"withdrawFlow.confirm.paypalReceivable",emailCorrect:"withdrawFlow.confirm.emailCorrect"},s5={paypalReceivable:"agreedPaypalReceivable",emailCorrect:"agreedEmailCorrect"};function s4(e){let{presentation:t,method:a}=e,{destinationKind:r}=t;if("stakeUsername"===r)return{kind:r,inputType:"text",autoComplete:"username",formFieldId:"withdraw-flow-stake-username",stakeRoute:t.stakeRoute??"com"};if("bank"===r){var s,n;let e,a=t.bankVariant??"ach",i="iban"===a||void 0;return{kind:r,variant:a,fields:(s=a,n=i??!0,e=Object.keys(s0(s)),"iban"!==s||n?e:e.filter(e=>"postalCode"!==e)),includePostalCode:i}}return"revolut"===r?{kind:r}:"cryptoWallet"===r&&(0,sf.isCryptoMethodSlug)(a.slug)?{kind:r,inputType:"text",autoComplete:"off",formFieldId:"withdraw-flow-crypto-wallet",cryptoName:a.displayName,methodSlug:a.slug}:{kind:"email",inputType:"email",autoComplete:"email",formFieldId:"withdraw-flow-email",labelKey:t.emailLabelKey,bannerKey:t.emailBannerKey}}function s8(e,t){var a,r,s,n,i;let l=s4(e),o=!1;if("stakeUsername"===l.kind){a=l,r=t.stake,o=!!s2(sO,r?.username)&&("us"===a.stakeRoute||r?.existsVerified===!0)}else if("bank"===l.kind){let e;
2s=t.bankDetails,e=s0(l.variant),o=!!l.fields.every(t=>s2(e[t],s?.[t]))&&("iban"!==l.variant&&"swift"!==l.variant||s?.existsVerified===!0)}else if("revolut"===l.kind){n=t.revolut,o=s2(sO,n?.name)&&s2(sq,n?.revtag)&&n?.existsVerified===!0}else if("cryptoWallet"===l.kind){i=t.walletAddress,o=s2(sZ[l.methodSlug],i)}else o=s2(sH,t.email);return!!o&&e.presentation.destinationAgreements.every(e=>t[s5[e]]??!1)}function s6(e,t,a={}){let r=(e.giftCards??[]).map(t=>({id:String(t.id),amount:t.value,currency:t.currency,hasLowerFees:(0,th.isProviderFeeEnabled)(e)&&!t.providerFee,isDisabled:t.status===R.GiftCardStatus.Unavailable||!rY({giftCard:t,...a})})),s=r.length>0,n=t.giftCard?String(t.giftCard.id):null,i=s?t.giftCard&&a.giftCardValueToCoins?a.giftCardValueToCoins(t.giftCard):void 0:t.coinsAmount,l=s?null!=t.giftCard:null!=t.coinsAmount;return{amountKey:s?"giftCard":"coinsAmount",usePredefinedOptions:s,amountMode:s?"predefined":"freeform",predefinedOptions:r,selectedGiftCardId:n,amountInCoins:i,hasAmount:l}}function s7(){let e=(0,rq.default)();return(0,O.useCallback)(t=>e({amount:t.value,originalCurrency:t.currency,targetCurrency:tF.Currency.COINS}).amount,[e])}function s9(e,t){let a=s7(),{withdrawableNowBalance:r}=(0,x.default)();return(0,O.useMemo)(()=>s6(e.method,t,{giftCardValueToCoins:a,withdrawableNowBalance:r}),[e.method,t,a,r])}function ne(e,t){let a=sE(e,t);return{header:a,amountMode:s9(e,t),destinationConfig:(0,O.useMemo)(()=>s4(e),[e])}}let nt={nonRefundable:"withdrawFlow.confirm.nonRefundable"};function na(e,t){return"nonRefundable"===t&&(e.agreedNonRefundable??!1)}function nr(e){return e.steps[e.stepIndex]}function ns(e,t){return t.stake?.minimumCoinsAmount??e.method.minimumCoinsAmount}function nn(e,t,a){let{coinsAmount:r}=t;return!!(null!=r&&r>0)&&rZ({coinsAmount:r,withdrawableNowBalance:a?.withdrawableNowBalance,maximumCoinsAmount:e.method.maximumCoinsAmount,minimumCoinsAmount:ns(e,t)}).ok}function ni(e,t,a){return"stakeUsername"===e.presentation.destinationKind?nn(e,t,a):t.giftCard?rY({giftCard:t.giftCard,...a}):nn(e,t,a)}function nl(e,t){if(!e.isOpen||!e.session||!e.draft||"submitting"===e.submitStatus||"success"===e.submitStatus)return!1;let a=nr(e);
2if(!a)return!1;let{session:r,draft:s}=e;switch(a){case"amount":return ni(r,s,t);case"destination":return s8(r,s);case"stakeCryptoSelection":return!!s.stake?.currency;case"confirm":if(!ni(r,s,t))return!1;return r.presentation.confirmAgreements.every(e=>na(s,e));default:return!1}}function no(e){return!!e.isOpen&&"submitting"!==e.submitStatus&&"success"!==e.submitStatus&&e.stepIndex>0}let nc={amount:"confirmAmount",confirm:"confirmCashout"};function nd(e,t){if("success"===e.submitStatus)return{ctaLabelKey:"confirmCashout",isDisabled:!0,showCta:!1};let a=nr(e)??"amount",r=e.session?.presentation,s="destination"===a&&r?r.destinationCtaKey:nc[a],n="amount"===a?r:void 0;return{ctaLabelKey:s??"confirmAmount",isDisabled:!nl(e,t),amountDisclaimer:n?.amountDisclaimerLines,amountFooterPromo:n?.amountFooterPromo,showCta:!!s}}let nu="cubic-bezier(0.25, 0.1, 0.25, 1)",nm="fc-stagger fc-stagger-cold [&>*]:[animation-timing-function:var(--withdraw-open-ease)]",nh={"--fc-stagger-step":"60ms","--fc-stagger-y":"18px","--fc-stagger-dur":"0.48s","--fc-stagger-elapsed":"-50ms","--withdraw-open-ease":nu},np="motion-reduce:animate-none animate-fcStaggerIn [animation-fill-mode:backwards]",nx={"--fc-stagger-y":"18px","--fc-stagger-dur":"0.48s",animationDelay:"0ms",animationTimingFunction:nu},nf={"--fc-stagger-y":"18px","--fc-stagger-dur":"0.48s",animationDelay:"220ms",animationTimingFunction:nu};var ng=e.i(467516);function ny({label:e,value:t}){return(0,s.jsxs)("div",{className:"w-full flex flex-col gap-0.5 rounded-[var(--radius-03)] bg-core-greyBlue-500 px-4 py-3",children:[(0,s.jsx)(rR.Typography,{variant:"xs",color:"core.greyBlue.25",as:"span",children:(0,s.jsx)("span",{className:"text-sm",children:e})}),(0,s.jsx)(rR.Typography,{weight:"semibold",variant:"xs",color:"core.neutral.0",children:(0,s.jsx)("span",{className:"text-sm",children:t})})]})}let nb={accountHolderName:"withdrawFlow.destination.bank.fields.accountHolderName.label",accountNumber:"withdrawFlow.destination.bank.fields.accountNumber.label",routingNumber:"withdrawFlow.destination.bank.fields.routingNumber.label",iban:"withdrawFlow.destination.bank.fields.iban.label",bic:"withdrawFlow.destination.bank.fields.bic.label",postalCode:"withdrawFlow.destination.bank.fields.postalCode.label"},nv={accountHolderName:"withdrawFlow.destination.bank.fields.accountHolderName.placeholder",accountNumber:"withdrawFlow.destination.bank.fields.accountNumber.placeholder",routingNumber:"withdrawFlow.destination.bank.fields.routingNumber.placeholder",iban:"withdrawFlow.destination.bank.fields.iban.placeholder",bic:"withdrawFlow.destination.bank.fields.bic.placeholder",postalCode:"withdrawFlow.destination.bank.fields.postalCode.placeholder"};function nw(e,t){return e.replace(/[^A-Za-z0-9]/g,"").toUpperCase().slice(0,t)}function nC(e,t){return e.replace(/\D/g,"").slice(0,t)}function nj(e,t){let a=(0,tS.useCurrencyText)(),{userCurrency:r}=(0,t2.useUserCurrencyInfo)(),s=(0,j.useFeatureFlags)(e=>e.isCashoutFeeEnabled),{amountInCoins:n,hasAmount:i}=s9(e,t);return(0,O.useMemo)(()=>{let l=n??0,o="cryptoWallet"===e.presentation.destinationKind,c=sA(e,t),d=(0,rK.toCurrencyV2)(c),u=!(0,rK.isCryptoWithdrawCurrency)(c)&&sx(r,d),m=sk(t.giftCard,{currencyText:a,providerFeeInGiftCardCurrency:!!s}),h=o?void 0:sN(e.method,t.giftCard,{currencyText:a}),p=t.stake?.bonusPercent!=null?{type:"percentage",value:t.stake.bonusPercent}:void 0,x=o?sC({amount:l,method:e.method}):sj({amount:l,consumerFee:m,withdrawalFee:h,bonusValue:p}),f=e.presentation.stakeRoute;return{receiveAmount:x,targetCurrency:"us"===f?(0,rK.toCurrencyV2)(t.stake?.currency??R.WithdrawCurrency.StakeCash):d,userCurrency:r,withdrawCurrency:d,disambiguate:u,hasAmount:i,receiveCurrencyName:null!=f?(0,rK.getCryptoCurrencyDisplayName)("us"===f?t.stake?.currency??R.WithdrawCurrency.StakeCash:c):void 0}},[n,t,a,i,s,e,r])}var nk=e.i(587583),nN=e.i(780570),nS=e.i(936733);e.i(890526);var nF=e.i(840731);let nT=(0,nF.graphql)(`
3  query RevolutCardAccountExists(
4    $customerName: String!
5    $giftCardId: Float!
6    $address: RevolutCardCashoutAddressArg!
7    $accountNumber: String
8    $iban: String
9    $bic: String
10  ) {
11    revolutCardAccountExists(
12      customerName: $customerName
13      giftCardId: $giftCardId
14      address: $address
15      accountNumber: $accountNumber
16      iban: $iban
17      bic: $bic
18    ) {
19      exists
20      reason
21    }
22  }
23`);function nE(e){return{accountHolderName:e.accountHolderName?.trim()??"",accountNumber:e.accountNumber?.trim()??"",iban:e.iban?.trim()??"",bic:e.bic?.trim()??"",postalCode:e.postalCode?.trim()??""}}function nA(e,t){if(!e||!t)return!1;let a=nE(e);return a.accountHolderName===t.accountHolderName&&a.accountNumber===t.accountNumber&&a.iban===t.iban&&a.bic===t.bic&&a.postalCode===t.postalCode}let nR={accountHolderName:"name",accountNumber:"off",routingNumber:"off",iban:"off",bic:"off",postalCode:"postal-code"};function nM({error:e}){let{t}=(0,C.useTranslationTyped)("_cashout-v2");if(!e)return null;let a="enterValidField"===e.kind?t("withdrawFlow.destination.bank.errors.enterValidField",{field:t(nb[e.fieldId])}):t("required"===e.kind?"withdrawFlow.inputErrors.required":"userNotFound"===e.kind?"withdrawFlow.destination.bank.errors.userNotFound":"withdrawFlow.destination.bank.errors.checkUnavailable");return(0,s.jsx)(rX,{message:a})}
23function n_({config:e,bankDetails:t,giftCardId:a,onChange:r}){let{t:i}=(0,C.useTranslationTyped)("_cashout-v2"),{fieldInvalid:l,fieldErrors:o,isVerifying:c,setFieldValue:d,clearField:u,onFieldBlur:m}=function({config:e,bankDetails:t,giftCardId:a,onChange:r}){let[s,n]=(0,O.useState)({}),[i,l]=(0,O.useState)(null),o="iban"===e.variant||"swift"===e.variant,{status:c,reason:d}=function(e,t,a,r,s){let n,i=s?.debounceMs??800,l=("iban"===e||"swift"===e)&&null!=r&&Number.isFinite(r)&&(n=s0(e),t.every(e=>s2(n[e],a?.[e]))),o=l&&a&&null!=r?{customerName:a.accountHolderName.trim(),giftCardId:r,postcode:a.postalCode.trim(),bic:a.bic.trim(),..."iban"===e?{iban:a.iban.trim()}:{accountNumber:a.accountNumber.trim()}}:null,c=(0,nS.default)(o,i),d=l&&(null==o||null==c?o!==c:o.customerName!==c.customerName||o.giftCardId!==c.giftCardId||o.postcode!==c.postcode||o.bic!==c.bic||o.iban!==c.iban||o.accountNumber!==c.accountNumber),u=(0,q.useQuery)({queryKey:["revolutCardAccountExists",c],queryFn:async()=>{let e=await nN.default.graphql.request({query:nT,variables:{customerName:c.customerName,giftCardId:c.giftCardId,address:{postcode:c.postcode},accountNumber:c.accountNumber??null,iban:c.iban??null,bic:c.bic}}),t=e?.data?.revolutCardAccountExists;if(!t)throw Error("revolutCardAccountExists response missing");return t},enabled:!!c,retry:!1,staleTime:6e4});if(!l)return{status:"idle",reason:null};if(d||u.isFetching||u.isPending)return{status:"checking",reason:null};if(u.isError)return{status:"error",reason:null};let m=u.data;return m?{status:m.exists?"exists":"missing",reason:m.reason??null}:{status:"checking",reason:null}}(e.variant,e.fields,t,o?a:null,{debounceMs:i?400:800}),u={accountHolderName:t?.accountHolderName,accountNumber:t?.accountNumber,routingNumber:t?.routingNumber,iban:t?.
23iban,bic:t?.bic,postalCode:t?.postalCode},{fieldInvalid:m,fieldErrors:h,isVerifying:p}=function({fields:e,values:t,touched:a,status:r,reason:s,variant:n}){var i,l;let o="missing"===r&&("iban"===n||"swift"===n)?(i=s,l=n,"InvalidIbanOrSwiftDetails"===i?"iban"===l?{iban:{kind:"enterValidField",fieldId:"iban"},bic:{kind:"enterValidField",fieldId:"bic"}}:{accountNumber:{kind:"enterValidField",fieldId:"accountNumber"},bic:{kind:"enterValidField",fieldId:"bic"}}:"InvalidPostcode"===i?{postalCode:{kind:"enterValidField",fieldId:"postalCode"}}:"RevolutUserNotFound"===i?{accountHolderName:{kind:"userNotFound"}}:{accountHolderName:{kind:"checkUnavailable"}}):"error"===r&&("iban"===n||"swift"===n)?{accountHolderName:{kind:"checkUnavailable"}}:{},c=s0(n),d={},u={};for(let r of e){let e=o[r];if(e){d[r]=!0,u[r]=e;continue}if(!a[r])continue;let s=s1(c[r],t[r]);s&&(d[r]=!0,u[r]="required"===s?{kind:"required"}:{kind:"enterValidField",fieldId:r})}return{fieldInvalid:d,fieldErrors:u,isVerifying:"checking"===r}}({fields:e.fields,values:u,touched:s,status:o?c:"idle",reason:d,variant:e.variant});if(o&&"exists"===c&&t){let e=nE(t);nA(t,i)||l(e)}(0,O.useEffect)(()=>{o&&"exists"===c&&(t?.existsVerified||r({existsVerified:!0}))},[o,c,t?.existsVerified,r]);let x=e=>{let a={...t,...e};o?r({...e,existsVerified:nA(a,i)}):r(e)};return{fieldInvalid:m,fieldErrors:h,isVerifying:o&&p,setFieldValue:(e,t)=>x({[e]:t}),clearField:e=>x({[e]:""}),onFieldBlur:e=>n(t=>({...t,[e]:!0}))}}({config:e,bankDetails:t,giftCardId:a,onChange:r});return(0,s.jsx)("div",{className:"w-full",children:(0,s.jsxs)(r4.Flex,{direction:"column",gap:"sm",children:[e.fields.map(a=>{var r;let n=t?.[a]??"",c="iban"===a?nw(n,34).replace(/(.{4})/g,"$1 ").trim():n,h=!!l[a],p=`withdraw-flow-bank-${a}`;return(0,s.jsxs)(rz.FormField,{id:p,isInvalid:h,children:[(0,s.jsxs)(rz.FormLabel,{children:[(0,s.jsx)("span",{className:"text-sm text-core-neutral-0",children:i(nb[a])}),(0,s.jsx)("span",{className:"text-sm text-core-red-500",children:"*"})]}),(0,s.jsx)("div",{className:rQ,children:(0,s.jsx)(rH.InputField,{type:"text",inputMode:(r=e.variant,"routingNumber"===a||"accountNumber"===a&&"ach"===r)?"numeric":void 0,autoComplete:nR[a],size:"md",value:c,onChange:t=>d(a,function(e,t,a){switch(e){case"iban":return nw(t,34);case"bic":return nw(t,11);case"routingNumber":return nC(t,9);case"accountNumber":return"ach"===a?nC(t,17):nw(t,34);default:return t}}(a,t.target.value,e.variant)),onBlur:()=>m(a),placeholder:i(nv[a]),rightElement:(0,s.jsx)(r2,{visible:n.length>0,onClear:()=>u(a)})})}),(0,s.jsx)(nM,{error:o[a]})]},a)}),c?(0,s.jsxs)(r4.Flex,{align:"center",gap:"xs",children:[(0,s.jsx)(nk.CircleNotchIcon,{className:"animate-spin shrink-0",size:16,"aria-hidden":!0,color:(0,n.resolveColorToken)("core.neutral.0")}),(0,s.jsx)(rR.Typography,{variant:"xs",color:"core.neutral.0",children:(0,s.jsx)("span",{className:"text-sm",children:i("withdrawFlow.destination.bank.verifying")})})]}):null]})})}let nI=["gmail.com","googlemail.com","outlook.com","hotmail.com","live.com","msn.com","yahoo.com","ymail.com","rocketmail.com","icloud.com","me.com","mac.com"],nP=["mail","email"],nB=new Set(["co","cm","om","cam"]),nU=Array.from(new Set(nI.map(e=>nO(e).root)));function nO(e){let t=e.indexOf(".");return t<=0?{root:e,tld:""}:{root:e.slice(0,t),tld:e.slice(t+1)}}function nG(e,t){if(e===t)return!1;let a=e.length-t.length;if(Math.abs(a)>1)return!1;if(0===a){let a=[];for(let r=0;r<e.length;r+=1)if(e[r]!==t[r]&&a.push(r),a.length>2)return!1;if(1===a.length)return!0;if(2!==a.length)return!1;let[r,s]=a;return s===r+1&&e[r]===t[s]&&e[s]===t[r]}let r=a>0?e:t,s=a>0?t:e,n=!1;for(let e=0;e<s.length;e+=1)if(s[e]!==r[e+ +!!n]){if(n)return!1;n=!0,e-=1}return!0}var nL=e.i(385328);function nD({suggestion:e,onAccept:t}){let{t:a}=(0,C.useTranslationTyped)("_cashout-v2"),r=e.lastIndexOf("@"),n=e.slice(0,r),i=e.slice(r);return(0,s.jsxs)("div",{className:"flex items-center gap-2 rounded-02 border border-solid border-core-yellow-25-A30 bg-core-yellow-25-A10 px-3 py-2",children:[(0,s.jsx)(nL.LightbulbIcon,{size:16,weight:"fill","aria-hidden":!0,className:"shrink-0 text-core-yellow-400"}),(0,s.jsxs)("span",{className:"flex min-w-0 flex-1 items-center gap-1 text-sm leading-sm text-core-yellow-200",children:[(0,s.jsx)("span",{className:"shrink-0",children:a("withdrawFlow.destination.email.didYouMean")}),(0,s.jsxs)("q",{className:"flex min-w-0 font-semibold",children:[(0,s.jsx)("span",{className:"truncate",children:n}),(0,s.jsx)("span",{className:"shrink-0",children:i})]})]}),(0,s.jsx)("div",{className:"shrink-0",children:(0,s.jsx)(g.Button,{variant:"special",color:"gold",size:"xs",onClick:()=>t(e),"aria-label":a("withdrawFlow.destination.email.useSuggestion",{suggestion:e}),children:(0,s.jsx)("span",{children:a("withdrawFlow.destination.email.applySuggestion")})})})]})}function nV({config:e,value:t,onChange:a,warningMessage:r}){let{t:n}=(0,C.useTranslationTyped)("_cashout-v2"),i=(0,O.useRef)(null),[l,o]=(0,O.useState)(!1),{error:c,suggestedEmail:d}=function({config:e,value:t,touched:a}){let r="cryptoWallet"===e.kind,s=s1(r?sZ[e.methodSlug]:sH,t);return s?a?"required"===s?{error:{kind:"required"},suggestedEmail:null}:"cryptoWallet"===e.kind?{error:{kind:"invalidCryptoAddress",cryptoName:e.cryptoName,exampleKey:sP[e.methodSlug]},suggestedEmail:null}:{error:{kind:"invalidEmail"},suggestedEmail:null}:{error:null,suggestedEmail:null}:{error:null,suggestedEmail:r?null:function(e){var t;let a=e?.trim().toLowerCase()??"",r=a.lastIndexOf("@");if(r<=0)return null;let s=a.slice(r+1);if(nI.includes(s)||nI.some(e=>e.startsWith(s)))return null;let{root:n,tld:i}=nO(s);if(!i)return null;let l=nU.includes(n)||nP.includes(n)||n.length<4?n:nU.find(e=>nG(n,e))??n,o=(t=nU.includes(l),!nG(i,"com")||nB.has(i)&&!t?i:"com");return l===n&&o===i?null:`${a.slice(0,r)}@${l}.${o}`}(t)}}({config:e,value:t,touched:l}),u=null!=c,m="cryptoWallet"===e.kind?n("withdrawFlow.destination.cryptoWallet.label",{crypto:e.cryptoName}):n(e.labelKey),h="cryptoWallet"===e.kind?n("withdrawFlow.destination.cryptoWallet.placeholder",{crypto:e.cryptoName}):n("withdrawFlow.destination.email.placeholder"),p=null==c?null:"required"===c.kind?n("withdrawFlow.inputErrors.required"):"invalidEmail"===c.kind?n("withdrawFlow.destination.email.enterValidEmail"):n("withdrawFlow.inputErrors.invalidCryptoAddressFormat",{crypto:c.cryptoName,example:n(c.exampleKey)});return(0,O.useEffect)(()=>{i.current?.focus()},[]),(0,s.jsx)(r4.Flex,{direction:"column",gap:"sm",children:(0,s.jsxs)(rz.FormField,{id:e.formFieldId,isInvalid:u,children:[(0,s.jsx)(rz.FormLabel,{children:(0,s.jsx)("span",{className:"text-sm text-core-neutral-0",children:m})}),(0,s.jsx)("div",{className:rQ,children:(0,s.jsx)(rH.InputField,{ref:i,type:e.inputType,autoComplete:e.autoComplete,size:"md",value:t,onChange:e=>a(e.target.value),onBlur:()=>o(!0),placeholder:h,rightElement:(0,s.jsx)(r2,{visible:t.length>0,onClear:()=>{a(""),i.current?.focus()}})})}),(0,s.jsx)(rX,{message:p}),null!=d&&(0,s.jsx)(nD,{suggestion:d,onAccept:a}),!u&&null==d&&"email"===e.kind&&(0,s.jsx)(rz.FormHelperText,{"aria-live":"polite",children:r?(0,s.jsx)("span",{className:"text-xs font-regular text-core-yellow-500",children:r}):(0,s.jsx)("span",{className:"text-xs font-regular text-core-greyBlue-100",children:n("withdrawFlow.destination.email.hint")})})]})})}let nW={titleKey:null,descriptionKey:"withdrawFlow.destination.revolut.unrecognizedError"},nK={RevolutUserNotFound:{titleKey:"withdrawFlow.destination.revolut.errors.userNotFoundTitle",descriptionKey:"withdrawFlow.destination.revolut.errors.userNotFound"},InvalidRevtag:{titleKey:"withdrawFlow.destination.revolut.errors.invalidRevtagTitle",descriptionKey:"withdrawFlow.destination.revolut.errors.invalidRevtag"},CanNotServeClient:nW},nz=(0,nF.graphql)(`
24  query RevolutAccountExists($customerName: String!, $revtag: String!) {
25    revolutAccountExists(customerName: $customerName, revtag: $revtag) {
26      exists
27      reason
28    }
29  }
30`);function nH(e){return"existsError"===e.kind?`${e.kind}:${e.titleKey??""}:${e.descriptionKey}`:e.kind}function nq(e,t,a){return!!a&&e.trim()===a.name&&t.trim()===a.revtag}var n$=e.i(259976);let nQ={error:"border-core-red-600 bg-[#311F2D]",neutral:"border-core-neutral-0-A10 bg-core-greyBlue-500",info:"border-core-blue-25-A50 bg-core-blue-25-A10"};function nZ({children:e,icon:t,variant:a="neutral",className:r,contentClassName:n,iconClassName:i}){return(0,s.jsxs)("div",{className:(0,w.cn)("relative w-full overflow-hidden rounded-[var(--radius-03)] border border-solid",nQ[a],r),children:[(0,s.jsx)("div",{className:(0,w.cn)("relative z-10 p-4",n),children:e}
30),(0,s.jsx)("div",{"aria-hidden":!0,className:(0,w.cn)("pointer-events-none absolute bottom-[-18px] right-[-14px]",i),children:t})]})}let nY="absolute inset-0 transition-opacity duration-300 ease-in-out motion-reduce:transition-none";function nX(e){return"existsError"===e.kind?`${e.kind}:${e.titleKey??""}:${e.descriptionKey}`:e.kind}function nJ(e){return"tip"===e.kind||"verifying"===e.kind}function n0({callout:e}){let{t}=(0,C.useTranslationTyped)("_cashout-v2");return"verifying"===e.kind?(0,s.jsxs)(r4.Flex,{align:"center",gap:"xs",children:[(0,s.jsx)(nk.CircleNotchIcon,{className:"animate-spin shrink-0",size:16,"aria-hidden":!0,color:(0,n.resolveColorToken)("core.neutral.0")}),(0,s.jsx)(rR.Typography,{variant:"xs",color:"core.neutral.0",children:(0,s.jsx)("span",{className:"text-sm",children:t("withdrawFlow.destination.revolut.verifying")})})]}):"tip"===e.kind?(0,s.jsx)(rR.Typography,{variant:"xs",color:"core.neutral.0",children:(0,s.jsx)("span",{className:"text-sm",children:t("withdrawFlow.destination.revolut.revtagTip")})}):"checkUnavailable"===e.kind?(0,s.jsx)(rR.Typography,{variant:"xs",color:"core.neutral.0",children:(0,s.jsx)("span",{className:"text-sm text-core-neutral-0",children:t("withdrawFlow.destination.revolut.checkUnavailable")})}):(0,s.jsxs)(r4.Flex,{direction:"column",gap:"xs",children:[e.titleKey?(0,s.jsx)(rR.Typography,{variant:"xs",color:"core.neutral.0",weight:"medium",children:(0,s.jsx)("span",{className:"text-sm",children:t(e.titleKey)})}):null,(0,s.jsx)(rR.Typography,{variant:"xs",color:"core.neutral.0",weight:"regular",children:(0,s.jsx)("span",{className:"text-sm",children:t(e.descriptionKey)})})]})}function n1({callout:e}){let{displayed:t,isOpaque:a}=function(e){let t=nX(e),[a,r]=(0,O.useState)(e),[s,n]=(0,O.useState)(t),[i,l]=(0,O.useState)(!0);return(0,O.useEffect)(()=>{if(t===s)return;if(!(!window.matchMedia("(prefers-reduced-motion: reduce)").matches&&(nJ(a)!==nJ(e)||!nJ(a)&&!nJ(e)))){let a=window.requestAnimationFrame(()=>{r(e),n(t),l(!0)});return()=>window.cancelAnimationFrame(a)}let i=window.setTimeout(()=>l(!1),0),o=window.setTimeout(()=>{r(e),n(t),l(!0)},200);return()=>{window.clearTimeout(i),window.clearTimeout(o)}},[e,a,s,t]),{displayed:a,isOpaque:i}}(e),r=!nJ(t),{measureRef:i,heightStyle:l}=function(e){let t=(0,O.useRef)(null),[a,r]=(0,O.useState)(void 0),s=(0,O.useCallback)(e=>{t.current=e},[]);return(0,O.useEffect)(()=>{let e=t.current;if(!e||"u"<typeof ResizeObserver)return;let a=new ResizeObserver(()=>{r(e.scrollHeight)});return a.observe(e),()=>a.disconnect()},[e]),{measureRef:s,heightStyle:null==a?void 0:{height:a}}}(nX(t));return(0,s.jsx)(nZ,{variant:r?"error":"info",className:"transition-[border-color,background-color] duration-300 ease-in-out motion-reduce:transition-none",iconClassName:r?"bottom-[-32px] right-[-12px]":"bottom-[-32px] right-[-10px] rotate-[16deg]",icon:(0,s.jsxs)("span",{className:"relative block size-[90px]",children:[(0,s.jsx)(r6.InfoIcon,{size:90,"aria-hidden":!0,color:(0,n.resolveColorToken)("core.blue.400"),className:(0,w.cn)(nY,r?"opacity-0":"opacity-20")}),(0,s.jsx)(n$.ProhibitIcon,{size:90,"aria-hidden":!0,color:(0,n.resolveColorToken)("core.red.600"),className:(0,w.cn)(nY,r?"opacity-20":"opacity-0")})]}),children:(0,s.jsx)("div",{className:(0,w.cn)("w-[80%]","overflow-hidden transition-[height] duration-300 ease-in-out motion-reduce:transition-none"),style:l,children:(0,s.jsx)("div",{ref:i,className:(0,w.cn)("transition-opacity duration-200 ease-in-out motion-reduce:transition-none",a?"opacity-100":"opacity-40"),children:(0,s.jsx)(n0,{callout:t})})})})}function n2({revolut:e,onChange:t}){let{t:a}=(0,C.useTranslationTyped)("_cashout-v2"),r=(0,O.useRef)(null),{name:n,revtag:i,nameInvalid:l,revtagInvalid:o,nameError:c,revtagError:d,callout:m,setName:h,setRevtag:p,clearName:x,clearRevtag:f,onNameBlur:g,onRevtagBlur:y}=function({revolut:e,onChange:t}){let a=(0,O.useRef)(!1),[r,s]=(0,O.useState)({name:!1,revtag:!1}),[n,i]=(0,O.useState)({kind:"tip"}),[l,o]=(0,O.useState)(null),c=e?.name??"",d=e?.revtag??"",{status:m,reason:h}=function(e,t,a){let r=a?.debounceMs??800,s=e.trim(),n=t.trim(),i=s2(sO,s)&&s2(sq,n),l=(0,nS.default)(i?{customerName:s,revtag:n}:null,r),o=i&&(null==l||l.customerName!==s||l.revtag!==n),c=(0,q.useQuery)({queryKey:["revolutAccountExists",l?.customerName,l?.revtag],queryFn:async()=>{let e=await nN.default.graphql.request({query:nz,variables:{customerName:l.customerName,revtag:l.revtag}}
30),t=e?.data?.revolutAccountExists;if(!t)throw Error("revolutAccountExists response missing");return t},enabled:!!l,retry:!1,staleTime:6e4});if(!i)return{status:"idle",reason:null};if(o||c.isFetching||c.isPending)return{status:"checking",reason:null};if(c.isError)return{status:"error",reason:null};let d=c.data;return d?{status:d.exists?"exists":"missing",reason:d.reason??null}:{status:"checking",reason:null}}(c,d,{debounceMs:l?400:800}),p=function(e){let[t,a]=(0,O.useState)(null);return(0,O.useEffect)(()=>{if(null==e)return;let t=setTimeout(()=>a(e),250);return()=>clearTimeout(t)},[e,250]),null!=e&&t===e}("checking"===m?`${c.trim()}\0${d.trim()}`:null),{nameInvalid:x,revtagInvalid:f,nameError:g,revtagError:y,callout:b}=function({name:e,revtag:t,touched:a,status:r,reason:s}){let n,i="missing"===r,l="error"===r,o=a.name?s1(sO,e):null,c=a.revtag?s1(sq,t):null;if(l)n={kind:"checkUnavailable"};else if(i)n={kind:"existsError",...!s?nW:nK[s]??nW};else n="checking"===r?{kind:"verifying"}:{kind:"tip"};return{nameInvalid:null!=o||i&&"InvalidRevtag"!==s||l,revtagInvalid:null!=c||i||l,nameError:o,revtagError:c,callout:n}}({name:c,revtag:d,touched:r,status:m,reason:h}),v="checking"===m&&!p;v||nH(n)===nH(b)||i(b);let w=v?n:b;if("exists"===m){let e={name:c.trim(),revtag:d.trim()};nq(e.name,e.revtag,l)||o(e)}(0,O.useEffect)(()=>{if(a.current)return;if(e?.name||e?.revtag){a.current=!0;return}let r=(0,u.getRevolutRevtag)();if(!r.name&&!r.revtag){a.current=!0;return}a.current=!0,t({name:r.name,revtag:r.revtag,existsVerified:!1})},[t,e?.name,e?.revtag]),(0,O.useEffect)(()=>{"exists"===m&&((0,u.saveRevolutRevtag)(d.trim(),c.trim()),e?.existsVerified||t({existsVerified:!0}))},[m,c,d,e?.existsVerified,t]);let C=e=>{let a=void 0!==e.name?e.name:c,r=void 0!==e.revtag?e.revtag:d;t({...e,existsVerified:nq(a,r,l)})};return{name:c,revtag:d,nameInvalid:x,revtagInvalid:f,nameError:g,revtagError:y,callout:w,setName:e=>C({name:e}),setRevtag:e=>C({revtag:e}),clearName:()=>C({name:""}),clearRevtag:()=>C({revtag:""}),onNameBlur:()=>s(e=>({...e,name:!0})),onRevtagBlur:()=>s(e=>({...e,revtag:!0}))}}({revolut:e,onChange:t});return(0,O.useEffect)(()=>{r.current?.focus()},[]),(0,s.jsx)("div",{className:"w-full",children:(0,s.jsxs)(r4.Flex,{direction:"column",gap:"sm",children:[(0,s.jsx)(rR.Typography,{variant:"xs",color:"core.neutral.0",weight:"medium",children:(0,s.jsx)("span",{className:"text-sm text-core-neutral-0",children:a("withdrawFlow.destination.revolut.sectionLabel")})}),(0,s.jsxs)(rz.FormField,{id:"withdraw-flow-revolut-name",isInvalid:l,children:[(0,s.jsx)("div",{className:rQ,children:(0,s.jsx)(rH.InputField,{ref:r,type:"text",autoComplete:"name",size:"md",value:n,onChange:e=>h(e.target.value),onBlur:g,"aria-label":a("withdrawFlow.destination.revolut.nameLabel"),placeholder:a("withdrawFlow.destination.revolut.namePlaceholder"),rightElement:(0,s.jsx)(r2,{visible:n.length>0,onClear:()=>{x(),r.current?.focus()}})})}),(0,s.jsx)(rJ,{error:c,invalidFormatMessage:null})]}),(0,s.jsxs)(rz.FormField,{id:"withdraw-flow-revolut-revtag",isInvalid:o,children:[(0,s.jsx)("div",{className:rQ,children:(0,s.jsx)(rH.InputField,{type:"text",autoComplete:"off",size:"md",value:i,onChange:e=>p(e.target.value),onBlur:y,"aria-label":a("withdrawFlow.destination.revolut.revtagLabel"),placeholder:a("withdrawFlow.destination.revolut.revtagPlaceholder"),rightElement:(0,s.jsx)(r2,{visible:i.length>0,onClear:f})})}),(0,s.jsx)(rJ,{error:d,invalidFormatMessage:a("withdrawFlow.destination.revolut.errors.enterValidRevtag")})]}),(0,s.jsx)(n1,{callout:m})]})})}var n3=e.i(873332);let n5={titleKey:"withdrawFlow.destination.stake.errors.userNotFoundTitle",descriptionKey:"withdrawFlow.destination.stake.errors.userNotFound"},n4=(0,nF.graphql)(`
31  query StakeComAccountExists($stakeComUsername: String!) {
32    stakeComAccountExists(stakeComUsername: $stakeComUsername) {
33      exists
34      reason
35    }
36  }
37`);function n8({callout:e}){let{t}=(0,C.useTranslationTyped)("_cashout-v2");return"checkUnavailable"===e.kind?(0,s.jsx)(rR.Typography,{variant:"xs",color:"core.neutral.0",children:(0,s.jsx)("span",{className:"text-sm",children:t("withdrawFlow.destination.stake.checkUnavailable")})}):(0,s.jsxs)(r4.Flex,{direction:"column",gap:"xs",children:[(0,s.jsx)(rR.Typography,{variant:"xs",color:"core.neutral.0",weight:"medium",children:(0,s.jsx)("span",{className:"text-sm",children:t(e.titleKey)})}),(0,s.jsx)(rR.Typography,{variant:"xs",color:"core.neutral.0",weight:"regular",children:(0,s.jsx)("span",{className:"text-sm",children:t(e.descriptionKey)})})]})}function n6({callout:e}){let{measureRef:t,heightStyle:a}=function(e){let t=(0,O.useRef)(null),[a,r]=(0,O.useState)(void 0),s=(0,O.useCallback)(e=>{t.current=e},[]);return(0,O.useEffect)(()=>{let e=t.current;if(!e||"u"<typeof ResizeObserver)return;let a=new ResizeObserver(()=>{r(e.scrollHeight)});return a.observe(e),()=>a.disconnect()},[e]),{measureRef:s,heightStyle:null==a?void 0:{height:a}}}("existsError"===e.kind?`${e.kind}:${e.titleKey}:${e.descriptionKey}`:e.kind);return(0,s.jsx)(nZ,{variant:"error",iconClassName:"bottom-[-32px] right-[-12px]",icon:(0,s.jsx)(n$.ProhibitIcon,{size:90,"aria-hidden":!0,opacity:.2,color:(0,n.resolveColorToken)("core.red.600")}),children:(0,s.jsx)("div",{role:"status","aria-live":"polite",className:(0,w.cn)("w-[80%]","overflow-hidden transition-[height] duration-300 ease-in-out motion-reduce:transition-none"),style:a,children:(0,s.jsx)("div",{ref:t,children:(0,s.jsx)(n8,{callout:e})})})})}function n7({stake:e,stakeRoute:t,onChange:a}){let{t:r}=(0,C.useTranslationTyped)("_cashout-v2"),i=(0,O.useRef)(null),{url:l}=(0,n3.default)(),{username:o,usernameInvalid:c,usernameError:d,isVerifying:m,callout:p,setUsername:x,clearUsername:f,onUsernameBlur:g}=function({stake:e,stakeRoute:t,onChange:a}){let r=(0,O.useRef)(!1),[s,n]=(0,O.useState)(!1),[i,l]=(0,O.useState)(null),o=e?.username??"",{status:c}=function(e,t){let a=t?.debounceMs??800,r=t?.enabled??!0,s=e.trim(),n=s2(sO,s),i=(0,nS.default)(r&&n?s:null,a),l=n&&(null==i||i!==s),o=(0,q.useQuery)({queryKey:["stakeComAccountExists",i],queryFn:async()=>{let e=await nN.default.graphql.request({query:n4,variables:{stakeComUsername:i}}),t=e?.data?.stakeComAccountExists;if(!t)throw Error("stakeComAccountExists response missing");return t},enabled:r&&!!i,retry:!1,staleTime:6e4});if(!r||!n)return{status:"idle",reason:null};if(l||o.isFetching||o.isPending)return{status:"checking",reason:null};if(o.isError)return{status:"error",reason:null};let c=o.data;if(!c)return{status:"checking",reason:null};let d=c.reason??null;return c.exists?{status:"exists",reason:d}:{status:d===h.CashoutErrorCodesEnum.StakeComUserNotFound?"missing":"unverified",reason:d}}(o,{enabled:"us"!==t,debounceMs:i?400:800}),d="exists"===c||"unverified"===c,{usernameInvalid:m,usernameError:p,callout:x}=function({username:e,touched:t,status:a}){let r="missing"===a,s="error"===a,n=t?s1(sO,e):null;return{usernameInvalid:null!=n||r||s,usernameError:n,callout:s?{kind:"checkUnavailable"}:r?{kind:"existsError",...n5}:null}}({username:o,touched:s,status:c});if(d){let e=o.trim();i!==e&&l(e)}(0,O.useEffect)(()=>
37{if(r.current)return;if(e?.username){r.current=!0;return}let s="us"===t?(0,u.getStakeUSUserName)():(0,u.getStakeComUserName)();r.current=!0,s&&a({username:s,existsVerified:!1})},[a,e?.username,t]),(0,O.useEffect)(()=>{d&&(e?.existsVerified||a({existsVerified:!0}))},[d,e?.existsVerified,a]);let f=e=>{let t=void 0!==e.username?e.username:o;a({...e,existsVerified:t.trim()===i})};return{username:o,usernameInvalid:m,usernameError:p,isVerifying:"checking"===c,callout:x,setUsername:e=>f({username:e}),clearUsername:()=>f({username:""}),onUsernameBlur:()=>n(!0)}}({stake:e,stakeRoute:t,onChange:a}),y="us"===t?l:h.StakeDotComHref;return(0,O.useEffect)(()=>{i.current?.focus()},[]),(0,s.jsx)("div",{className:"w-full",children:(0,s.jsxs)(r4.Flex,{direction:"column",gap:"sm",children:[(0,s.jsxs)(rz.FormField,{id:"withdraw-flow-stake-username",isInvalid:c,children:[(0,s.jsx)(rz.FormLabel,{children:(0,s.jsx)("span",{className:"text-sm text-core-neutral-0",children:r("withdrawFlow.destination.stake.label")})}),(0,s.jsx)("div",{className:rQ,children:(0,s.jsx)(rH.InputField,{ref:i,type:"text",autoComplete:"username",size:"md",value:o,onChange:e=>x(e.target.value),onBlur:g,placeholder:r("withdrawFlow.destination.stake.placeholder"),rightElement:m?(0,s.jsx)("span",{role:"status","aria-label":r("withdrawFlow.destination.stake.verifying"),className:"inline-flex items-center",children:(0,s.jsx)(nk.CircleNotchIcon,{className:"animate-spin",size:18,"aria-hidden":!0,color:(0,n.resolveColorToken)("core.greyBlue.100")})}):(0,s.jsx)(r2,{visible:o.length>0,onClear:()=>{f(),i.current?.focus()}})})}),null!=d&&null==p?(0,s.jsx)(rJ,{error:d,invalidFormatMessage:null}):(0,s.jsx)(rz.FormHelperText,{children:(0,s.jsx)("span",{className:"text-xs font-regular text-core-greyBlue-100",children:(0,s.jsx)(Z.Trans,{t:r,i18nKey:"withdrawFlow.destination.stake.hint",components:{em:(0,s.jsx)("a",{href:y,target:"_blank",rel:"noopener noreferrer",className:"text-core-freecashGreen-500 underline"})}})})})]}),null!=p?(0,s.jsx)(n6,{callout:p}):null]})})}let n9=[R.WithdrawProvider.Tremendous],ie=new Set(Object.values(R.WithdrawType));function it(e){return e?.trim().toLowerCase()??""}let ia=(0,nF.graphql)(`
38  query CashoutEmailsUsed($type: WithdrawType!, $providerName: WithdrawProvider!) {
39    getCashoutEmailsUsed(type: $type, providerName: $providerName) {
40      items
41    }
42  }
43`),ir=[];function is({title:e,options:t,selectedId:a,onSelect:r}){let{t:n}=(0,C.useTranslationTyped)("_cashout-v2");return(0,s.jsxs)(r4.Flex,{direction:"column",gap:"sm",children:[(0,s.jsx)(rR.Typography,{variant:"sm",weight:"medium",children:(0,s.jsx)("span",{className:"text-base",children:e})}),(0,s.jsx)(sl,{cols:3,gap:"md",children:t.map(e=>(0,s.jsx)("div",{role:"button",tabIndex:0,onClick:()=>r?.(e),onKeyDown:t=>{("Enter"===t.key||" "===t.key)&&(t.preventDefault(),r?.(e))},className:(0,w.cn)("w-full cursor-pointer rounded-2xl border border-solid border-core-greyBlue-200","bg-core-greyBlue-900 py-2.5"),"data-selected":a===e.id?"true":void 0,children:(0,s.jsxs)(r4.Flex,{direction:"column",align:"center",gap:"sm",children:[(0,s.jsx)(rR.Typography,{variant:"xs",weight:"semibold",children:(0,s.jsx)("span",{className:"text-sm",children:e.name})}),(0,s.jsx)(sd.Image,{src:(0,rK.getPaymentMethodLogoSrc)({withdrawalCurrency:e.type,size:"sm"}),alt:`${e.name} logo`,aspectRatio:"1",objectFit:"contain",wrapperClassName:"size-10"}),null!=e.bonusPercent?(0,s.jsx)("div",{className:"border-none",children:(0,s.jsx)(su.Tag,{size:"sm",children:(0,s.jsx)("span",{className:"text-xs font-semibold text-core-blue-300",children:n("withdrawFlow.stakeCryptoSelection.selectedCryptoBonus",{bonus:e.bonusPercent})})})}):null]})},e.id))})]})}e.i(490790);let ii=[R.WithdrawCurrency.Ltc,R.WithdrawCurrency.Sol,R.WithdrawCurrency.Doge,R.WithdrawCurrency.Xrp,R.WithdrawCurrency.Trx],il=e=>e&&e>0?e:void 0,io={amount:{id:"amount",Component:function({session:e,draft:t,onPatch:a}){let{t:r}=(0,C.useTranslationTyped)("_cashout-v2"),n=(0,tS.useCurrencyText)(),{header:i,amountMode:{usePredefinedOptions:l,predefinedOptions:o,selectedGiftCardId:c,amountInCoins:d,hasAmount:u}}=ne(e,t),m=function(e,t,a){let{t:r}=(0,C.useTranslationTyped)("_cashout-v2"),n=(0,tS.useCurrencyText)(),{userCurrency:i}=(0,t2.useUserCurrencyInfo)(),{country:l}=(0,aS.default)(),o=(0,j.useFeatureFlags)(e=>e.isCashoutFeeEnabled),c=sE(e,t);return(0,O.useMemo)(()=>{let d=e.presentation,{layout:u,amountLabelKey:m,info:h}=d.amountSummary,p="cryptoWallet"===d.destinationKind,x=sA(e,t,l),f=(0,rK.toCurrencyV2)(x),g=(0,rK.isCryptoWithdrawCurrency)(x),y=sS(x),b=(0,rK.toCurrencyV2)(g?i:sF(f)),v=!g&&sx(i,b),w={disambiguate:v,userCurrency:i,withdrawCurrency:b},C=!g&&i!==sF(f),j=(e,t)=>n({amount:e,targetCurrency:t,currencySymbolOverride:sg({...w,targetCurrency:t})}).value,k=(0,s.jsx)(rR.Typography,{color:"core.freecashGreen.500",weight:"semibold",as:"span",children:(0,s.jsx)("span",{className:"text-sm",children:r("withdrawFlow.amount.summary.free")})}),N=(e,t=b)=>{let n,i=sb(e,a);return!e||i<=0?{value:k}:{labelSuffix:"percentage"===e.type?(n=e.value,(0,s.jsx)(rR.Typography,{color:"core.greyBlue.50",weight:"medium",as:"span",children:(0,s.jsx)("span",{className:"text-xs",children:r("withdrawFlow.amount.summary.feePercent",{percent:n})})})):void 0,value:(0,s.jsx)(sy,{amount:i,targetCurrency:t,...w})}},S=u.rows.includes("consumerFee")?sk(t.giftCard,{currencyText:n,providerFeeInGiftCardCurrency:!!o}):void 0,F=p?void 0:sN(e.method,t.giftCard,{currencyText:n}),T=t.stake?.bonusPercent!=null?{type:"percentage",value:t.stake.bonusPercent}:void 0,E=r(m),A=C?(0,s.jsx)(rR.Typography,{color:"core.greyBlue.50",weight:"medium",as:"span",children:(0,s.jsx)("span",{className:"text-xs",children:r("withdrawFlow.amount.summary.amountInUserCurrency",{amount:j(a,i)})})}):void 0,R=(0,s.jsx)(sy,{amount:a,targetCurrency:b,...w}),M=[];for(let t of u.rows)switch(t){case"amount":M.push({id:"amount",emphasize:!0,label:E,labelSuffix:A,value:R});break;
43case"exchangeRate":M.push({id:"exchangeRate",label:r("withdrawFlow.amount.summary.exchangeRate",{crypto:x}),value:(0,s.jsx)(sy,{amount:1,originalCurrency:f,targetCurrency:i,...w,disambiguate:!1})});break;case"cryptoNetworkFee":{let t=sv(e.method);M.push({id:"cryptoNetworkFee",label:r("withdrawFlow.amount.summary.cryptoFee"),infoLabel:r("withdrawFlow.amount.summary.cryptoFeeInfoLabel"),value:t>0?(0,s.jsx)(sy,{amount:t,targetCurrency:b,...w,disambiguate:!1}):k});break}case"consumerFee":{let t=!!e.presentation.amountSummary.showConsumerFeeWhenFree;if(!S&&!t)break;let{labelSuffix:s,value:n}=N(S),i=sb(S,a),l=i<=0;M.push({id:"consumerFee",label:r("withdrawFlow.amount.summary.consumerFee",{paymentMethod:c.name}),infoLabel:l?void 0:r("withdrawFlow.amount.summary.consumerFeeInfoLabel",{paymentMethod:c.name,fee:j(i,b),amount:j(a,b)}),labelSuffix:s,value:n});break}case"withdrawalFee":{let{labelSuffix:t,value:a}=N(p?{type:"percentage",value:sw(e.method)}:F);M.push({id:"withdrawalFee",label:r("withdrawFlow.amount.summary.withdrawalFee"),labelSuffix:t,value:a});break}case"bonus":{if(!T)break;let e=sb(T,a),t="percentage"===T.type?r("withdrawFlow.amount.summary.bonusPercentTag",{percent:T.value}):null;M.push({id:"bonus",label:r("withdrawFlow.amount.summary.bonus"),labelTag:(0,s.jsx)("span",{className:"[&>*]:border-none",children:(0,s.jsx)(su.Tag,{size:"sm",children:(0,s.jsx)(rR.Typography,{variant:"sm",weight:"semibold",color:"core.blue.300",as:"span",children:t??(0,s.jsxs)(s.Fragment,{children:["+",(0,s.jsx)(eD.CurrencyText,{amount:e,targetCurrency:b,currencySymbolOverride:sg({...w,targetCurrency:b})})]})})})}),value:(0,s.jsx)(sy,{amount:e,targetCurrency:b,...w})})}}let _=p?sC({amount:a,method:e.method}):sj({amount:a,consumerFee:S,withdrawalFee:F,bonusValue:T}),I="us"===d.stakeRoute?r("withdrawFlow.amount.summary.youWillReceiveStakeCoin"):"crypto"===u.footer?r("withdrawFlow.amount.summary.youWillReceiveCrypto",{cryptoCurrencyName:(0,rK.getCryptoCurrencyDisplayName)(x)}):r("withdrawFlow.amount.summary.youWillReceive");return{info:(()=>{if(h)return h.i18nKey,{presentation:h.presentation,content:r(h.i18nKey,h.values)}})(),rows:M,footer:{label:I,value:(0,s.jsx)(sy,{amount:_,targetCurrency:f,...w,disambiguate:!y&&v,className:"text-[16px]"})}}},[a,l,t,n,c.name,o,e,r,i])}(e,t,d??0),h="stakeMinimum"===e.presentation.amountStepBanner,p=ns(e,t),x=t.stake?.currency,f=n({amount:p,targetCurrency:tF.Currency.UserCurrency}).value,g=l&&e.amountPreselected;return(0,s.jsxs)("div",{className:(0,w.cn)("flex w-full flex-col gap-10",nm),style:nh,children:[(0,s.jsx)(sm,{name:i.name,logoSrc:i.logoSrc,bonusPercent:i.bonusPercent}),!g&&l&&(0,s.jsx)(sc,{options:o,selectedId:c,onSelect:t=>{let r=e.method.giftCards?.find(e=>String(e.id)===t);r&&a({giftCard:r,coinsAmount:void 0})}}),!g&&!l&&h&&(0,s.jsx)(sa,{text:r("withdrawFlow.amount.stakeSelectedCryptoAmountInfo",{selectedCryptoMethod:x?(0,rK.getCryptoCurrencyDisplayName)(x):"",amount:f})}),!g&&!l&&(0,s.jsx)(r5,{minimumCoinsAmount:p,maximumCoinsAmount:e.method.maximumCoinsAmount,coinsAmount:t.coinsAmount,onAmountChange:e=>{a({coinsAmount:e??void 0,giftCard:void 0})}}),u&&(0,s.jsx)(sr,{...m})]})}},destination:{id:"destination",Component:function({session:e,draft:t,onPatch:a}){let{t:r}=(0,C.useTranslationTyped)("_cashout-v2"),{header:n,destinationConfig:i}=ne(e,t),l=function(e,t,a){var r,s;let n,i,l=(r="email"===e.kind?function(e,t){let a=e.method.withdrawProvider,r=n9.find(e=>e===a);if(null==r)return null;let s=t.giftCard?.brand;return null!=s&&ie.has(s)?{type:s,providerName:r}:null}(t,a):null,n=(0,q.useQuery)({queryKey:["cashoutEmailsUsed",r?.type??null,r?.providerName??null],queryFn:async()=>{let{type:e,providerName:t}=r,a=await nN.default.graphql.request({query:ia,variables:{type:e,providerName:t}}),s=a?.data?.getCashoutEmailsUsed;if(!s)throw Error("getCashoutEmailsUsed response missing");return s.items},enabled:null!=r,retry:!1,staleTime:0,gcTime:0,refetchOnWindowFocus:!1,refetchOnReconnect:!1}),null==r?{status:"idle",emails:ir}:n.isError?{status:"error",emails:ir}:n.isFetching||null==n.data?{status:"loading",emails:ir}:{status:"ready",emails:n.data}),o=a.email??"",c=(0,nS.default)(o,600);return"ready"===l.status&&0!==l.emails.length&&o===c&&!!s2(sH,c)&&(s=l.emails,!((i=it(c))&&s.some(e=>it(e)===i)))}(i,e,t),o="cryptoWallet"===i.kind?t.walletAddress??"":t.email??"",c=(0,O.useCallback)(e=>
43{a({bankDetails:e})},[a]),d=String(t.giftCard?.id??"").trim(),u=""===d?NaN:Number(d),m=Number.isFinite(u)&&u>0?u:null,h=(0,O.useCallback)(e=>{a({revolut:e})},[a]),p=(0,O.useCallback)(e=>{a({stake:e})},[a]),x="bank"===i.kind?r("withdrawFlow.destination.bank.banner"):"stakeUsername"===i.kind?"us"===e.presentation.stakeRoute?r("withdrawFlow.destination.stake.bannerUsV2"):r("withdrawFlow.destination.stake.banner"):"email"===i.kind?r(i.bannerKey):"cryptoWallet"===i.kind?r("withdrawFlow.destination.cryptoWallet.banner"):null;return(0,s.jsxs)("div",{className:(0,w.cn)("flex w-full flex-col gap-10",nm),style:nh,children:[(0,s.jsx)(sm,{name:n.name,logoSrc:n.logoSrc,bonusPercent:n.bonusPercent}),null!=x&&(0,s.jsx)(sa,{text:x}),(0,s.jsxs)("div",{className:"flex flex-col gap-4 phoneMax:gap-6",children:["bank"===i.kind?(0,s.jsx)(n_,{config:i,bankDetails:t.bankDetails,giftCardId:m,onChange:c}):"revolut"===i.kind?(0,s.jsx)(n2,{revolut:t.revolut,onChange:h}):"stakeUsername"===i.kind?(0,s.jsx)(n7,{stake:t.stake,stakeRoute:i.stakeRoute,onChange:p}):(0,s.jsx)(nV,{config:i,value:o,onChange:e=>{"cryptoWallet"===i.kind?a({walletAddress:e}):a({email:e,agreedEmailCorrect:!1,agreedPaypalReceivable:!1})},warningMessage:l?r("withdrawFlow.destination.email.neverUsedWarning"):null}),e.presentation.destinationAgreements.length>0&&(0,s.jsx)("div",{className:"flex flex-col gap-4",children:e.presentation.destinationAgreements.map(e=>(0,s.jsx)(ng.Checkbox,{label:r(s3[e]),size:"sm",labelVisible:!0,isChecked:t[s5[e]]??!1,onChange:t=>{a({[s5[e]]:t})},labelColor:"core.greyBlue.25"},e))})]})]})}},confirm:{id:"confirm",Component:function({session:e,draft:t,onPatch:a}){let{t:r}=(0,C.useTranslationTyped)("_cashout-v2"),n=sE(e,t),{cards:i}=function(e,t){let{t:a}=(0,C.useTranslationTyped)("_cashout-v2"),r=(0,O.useMemo)(()=>s4(e),[e]),{receiveAmount:n,targetCurrency:i,userCurrency:l,withdrawCurrency:o,disambiguate:c,receiveCurrencyName:d}=nj(e,t);return(0,O.useMemo)(()=>{let u={disambiguate:c,userCurrency:l,withdrawCurrency:o},m=[];for(let l of e.presentation.confirmSummary.rows)switch(l){case"youWillReceive":{let e=(0,s.jsx)(sy,{amount:n,targetCurrency:i,...u,className:"text-[14px]"});m.push({id:"youWillReceive",label:a("withdrawFlow.confirm.youWillReceive"),value:d?(0,s.jsxs)("span",{className:"inline-flex items-center gap-1.5",children:[(0,s.jsx)("span",{children:d}),e]}):e});break}case"email":m.push({id:"email",label:a(e.presentation.confirmEmailLabelKey),value:t.email});break;case"stakeUsername":m.push({id:"stakeUsername",label:a("withdrawFlow.confirm.stakeUsername"),value:t.stake?.username});break;case"revolutRevtag":m.push({id:"revolutRevtag",label:a("withdrawFlow.confirm.revolutRevtag"),value:t.revolut?.revtag});break;case"cryptoWallet":m.push({id:"cryptoWallet",label:a("withdrawFlow.confirm.walletAddress",{crypto:"cryptoWallet"===r.kind?r.cryptoName:e.method.displayName}),value:t.walletAddress});break;case"bankFields":if("bank"!==r.kind)break;for(let e of r.fields)m.push({id:`bank-${e}`,label:a(nb[e]),value:function(e,t){let a=t?.[e]?.trim();if(!a)return"—";if("iban"===e){let e=nw(a,34);if(!e)return"";let t=[];for(let a=0;a<e.length;a+=4)t.push(e.slice(a,a+4));return t.length<=1?e:2===t.length?`${t[0]} ****`:t.map((e,a)=>0===a||a===t.length-1?e:"****").join(" ")}return a}(e,t.bankDetails)})}return{cards:m}},[r,c,t,n,d,i,e,a,l,o])}(e,t);return(0,s.jsxs)("div",{className:(0,w.cn)("flex w-full flex-col gap-10",nm),style:nh,children:[(0,s.jsx)(sm,{name:n.name,logoSrc:n.logoSrc,bonusPercent:n.bonusPercent}),(0,s.jsxs)("div",{className:"flex flex-col gap-4 phoneMax:gap-6",children:[(0,s.jsx)(r4.Flex,{direction:"column",gap:"md",children:i.map(e=>(0,s.jsx)(ny,{label:e.label,value:e.value},e.id))}),e.presentation.confirmAgreements.length>0&&(0,s.jsx)(r4.Flex,{direction:"column",gap:"lg",children:e.presentation.confirmAgreements.map(e=>(0,s.jsx)(ng.Checkbox,{label:r(nt[e]),size:"sm",labelVisible:!0,isChecked:na(t,e),onChange:t=>{a("nonRefundable"===e?{agreedNonRefundable:t}:{})},labelColor:"core.greyBlue.25"},e))})]})]})}},stakeCryptoSelection:{id:"stakeCryptoSelection",Component:function({session:e,draft:t,onNext:a}){let{t:r}=(0,C.useTranslationTyped)("_cashout-v2"),{data:n}=(0,ri.default)(),{stakeBonus:i}=(0,k.useStakeBonus)(),l=(0,O.useMemo)(()=>(function({currencies:e,bonusPercent:t}){let a=null!=t&&t>0?t:void 0,r=new Set(ii),s=new Map;for(let t of e){let e=String(t.currency);(0,rK.isCryptoWithdrawCurrency)(e)&&s.set(e,t)}let n=[];for(let e of ii){let t=s.get(e);if(!t)continue;let r=(0,rK.getCryptoCurrencyDisplay)(e);n.push({id:r.id,name:r.name,type:e,section:"recommended",bonusPercent:a,minimumCashoutAmount:il(t.minimumCashoutAmount)})}let i=[];for(let t of e){let e=String(t.currency);if(!(0,rK.isCryptoWithdrawCurrency)(e)||r.has(e))continue;let s=(0,rK.getCryptoCurrencyDisplay)(e);i.push({id:s.id,name:s.name,type:e,section:"other",bonusPercent:a,minimumCashoutAmount:il(t.minimumCashoutAmount)})}return[...n,...i]})({currencies:n?.currencies??[],bonusPercent:i}),[n?.currencies,i]),{recommended:o,other:c}=(0,O.useMemo)(()=>({recommended:l.filter(e=>"recommended"===e.section),other:l.filter(e=>"other"===e.section)}),[l]),d=l.find(e=>e.type===t.stake?.currency)?.id,u=t=>{a({stake:{currency:t.type,minimumCoinsAmount:t.minimumCashoutAmount??e.method.minimumCoinsAmount,bonusPercent:t.bonusPercent}})};return(0,s.jsxs)("div",{className:(0,w.cn)("flex w-full flex-col gap-10",nm),style:nh,children:[(0,s.jsx)(sm,{name:r("withdrawFlow.stakeCryptoSelection.methodName"),logoSrc:(0,rK.getPaymentMethodLogoSrc)({withdrawalType:R.WithdrawType.Stake})}),(0,s.jsx)(sa,{text:r("withdrawFlow.stakeCryptoSelection.description")}),o.length>0&&(0,s.jsx)(is,{title:r("withdrawFlow.stakeCryptoSelection.recommendedSectionTitle"),options:o,selectedId:d,onSelect:u}),c.length>0&&(0,s.jsx)(is,{title:r("withdrawFlow.stakeCryptoSelection.othersSectionTitle"),options:c,selectedId:d,onSelect:u})]})}}};e.i(413610);let ic={MaxWithdrawalCount:"withdrawalLimitReached",ConcurrentWithdrawal:"withdrawalLimitReached",RevolutFaucetAlreadyClaimed:"accountIdentityConflict",StakeComUserNotFound:"accountIdentityConflict",RevolutUserNotFound:"accountIdentityConflict",CryptoAddressIsBanned:"unableToProcessWithdrawal",RevolutAccountHasBeenUsedByAnotherUser:"unableToProcessWithdrawal",MultipleRevolutAccountsForUser:"unableToProcessWithdrawal",UsernameUsedByOtherUser:"unableToProcessWithdrawal",GiftCardIsNotAvailable:"unavailableWithdrawalMethod",CardIsNotSupportedForIban:"unavailableWithdrawalMethod",CardIsNotSupportedForSwift:"unavailableWithdrawalMethod",RevolutFaucetNotAvailable:"unavailableWithdrawalMethod",CanNotServeClient:"unavailableWithdrawalMethod",FeeExceedingAmou
43nt:"exceedingWithdrawalFee",InvalidRevtag:"invalidRevtag",InvalidACHDetails:"invalidAchDetails",InvalidIbanOrSwiftDetails:"invalidIbanOrSwiftDetails",CashoutProviderUnavailable:"cashoutProviderUnavailable"};function id(e){if(!e||"object"!=typeof e||!("code"in e))return null;let t=e.code;return"string"==typeof t&&t.length>0?t:null}function iu(e){return e?.trim()??""}async function im(e,t){switch(e.kind){case"giftCard":{let a=function(e,t){switch(t){case R.WithdrawProvider.Tango:case R.WithdrawProvider.TangoUs:return e.tangoCashoutMutation;case R.WithdrawProvider.Tremendous:return e.tremendousGiftcardCashoutMutation;case R.WithdrawProvider.Giftee:return e.gifteeCashoutMutation;default:throw Error(`Unsupported gift-card provider for withdraw submit: ${t??"undefined"}`)}}(t,e.provider);await a.mutateAsync({giftCard:e.giftCard,email:e.email});return}case"crypto":await t.cryptoMutation.mutateAsync({method:e.method,currency:e.currency,values:{cryptoAddress:e.address,amountInCoins:e.coinsAmount}});return;case"stakeCom":await t.stakeComMutation.mutateAsync({currency:e.currency,values:{stakeUserName:e.username,amountInCoins:e.coinsAmount}});return;case"stakeUs":await t.stakeUsMutation.mutateAsync({values:{stakeUserName:e.username,amountInCoins:e.coinsAmount}});return;case"revolut":await t.revolutMutation.mutateAsync({revtag:e.revtag,revname:e.name,amountInCoins:e.coinsAmount});return;case"bankAch":await t.revolutUsMutation.mutateAsync({customerName:e.bankDetails.accountHolderName,accountNumber:e.bankDetails.accountNumber,routingTransitNumber:e.bankDetails.routingNumber,giftCardId:e.giftCardId,address:{postcode:e.bankDetails.postalCode}});return;case"bankIbanSwift":await t.revolutCardMutation.mutateAsync({customerName:e.bankDetails.accountHolderName??"",accountNumber:e.bankDetails.accountNumber||null,iban:e.bankDetails.iban||null,bic:e.bankDetails.bic??"",giftCardId:e.giftCardId,address:{city:null,postcode:e.bankDetails.postalCode??""}});return;default:throw Error(`Unhandled withdraw submit plan kind: ${e.kind}`)}}async function ih(e){let{session:t,draft:a,mutations:r,giftCardValueToCoins:s,canProceed:n,onEmailRequired:i,onSubmitStart:l,onSuccess:o,onError:c,closeOnError:d,onErrorClose:m,unknownErrorMessage:h,resolveErrorMessage:p}=e,{amountInCoins:x}=s6(t.method,a,{giftCardValueToCoins:s});if(null==x||!(x>0)){c(h),d&&m?.();return}if(n&&!n(x))return;let f=function(e,t,a){if(!(a>0))return null;let{presentation:r,method:s}=e;if("email"===r.destinationKind)return t.giftCard?{kind:"giftCard",giftCard:t.giftCard,email:t.email?.trim()??"",coinsAmount:a,provider:s.withdrawProvider}:null;if(!s8(e,t))return null;switch(r.destinationKind){case"cryptoWallet":{let e=(0,sf.getCryptoWithdrawCurrencyForSlug)(s.slug);
43if(!e)return null;return{kind:"crypto",method:s,address:iu(t.walletAddress),coinsAmount:a,currency:e}}case"stakeUsername":{let e=iu(t.stake?.username);if("us"===r.stakeRoute)return{kind:"stakeUs",username:e,coinsAmount:a};if(!t.stake?.currency)return null;return{kind:"stakeCom",username:e,coinsAmount:a,currency:t.stake.currency}}case"revolut":return{kind:"revolut",name:iu(t.revolut?.name),revtag:iu(t.revolut?.revtag),coinsAmount:a};case"bank":{if(t.giftCard?.id==null||!t.bankDetails)return null;let e=Number(t.giftCard.id);if(!Number.isFinite(e))return null;let s=r.bankVariant??"ach",{bankDetails:n}=t;if("ach"===s)return{kind:"bankAch",giftCardId:e,bankDetails:{accountHolderName:iu(n.accountHolderName),accountNumber:iu(n.accountNumber),routingNumber:iu(n.routingNumber),postalCode:iu(n.postalCode)},coinsAmount:a};return{kind:"bankIbanSwift",variant:s,giftCardId:e,bankDetails:{accountHolderName:iu(n.accountHolderName),accountNumber:n.accountNumber?.trim(),iban:n.iban?.trim(),bic:n.bic?.trim(),postalCode:iu(n.postalCode)},coinsAmount:a}}}}(t,a,x);if(!f){c(h),d&&m?.();return}if("giftCard"===f.kind&&t.presentation.collectEmail&&!f.email)return void i();let g=l?.(),y="number"==typeof g?g:void 0;try{await im(f,r),"stakeCom"===f.kind?(0,u.saveStakeComUserName)(f.username):"stakeUs"===f.kind&&(0,u.saveStakeUSUserName)(f.username),o(y)}catch(e){c(p(e),y),d&&m?.()}}e.i(544752);var ip=e.i(926564),ix=e.i(648318),ig=e.i(574700),iy=e.i(812191),ib=e.i(893653),iv=e.i(841779),iw=e.i(766170),iC=e.i(184600),ij=e.i(717106),ik=e.i(538989),iN=e.i(128952);function iS({error:e}){let{t}=(0,C.useTranslationTyped)("_cashout-v2");return(0,s.jsxs)("div",{className:(0,w.cn)("flex h-full w-full flex-col items-center gap-6 pb-4 pt-20",nm),style:nh,children:[(0,s.jsxs)("span",{className:"relative inline-flex size-[110px] shrink-0 items-center justify-center",children:[(0,s.jsx)(iN.CircleIcon,{weight:"fill",className:"text-core-red-500",size:110}),(0,s.jsx)(r1.XIcon,{weight:"bold",className:"absolute text-core-neutral-0",size:55,"aria-hidden":!0})]}),(0,s.jsx)(ik.Box,{w:"190px",children:(0,s.jsx)(rR.Typography,{weight:"medium",align:"center",variant:"md",color:"core.neutral.0",children:t("withdrawFlow.submittedError.title")})}),(0,s.jsx)("div",{className:"mt-auto w-full shrink-0",children:(0,s.jsx)(nZ,{iconClassName:"bottom-[-28px] right-[-10px] rotate-[16deg]",variant:"error",icon:(0,s.jsx)(r6.InfoIcon,{className:"text-core-neutral-0-A10",size:95}),children:(0,s.jsx)(ik.Box,{w:"80%",children:(0,s.jsx)(rR.Typography,{weight:"regular",variant:"xs",color:"core.neutral.0",children:e})})})})]})}e.i(184102);var iF=e.i(594341),iT=e.i(820050),iE=e.i(813280),iA=e.i(155406);function iR({layout:e}){let{t}=(0,C.useTranslationTyped)("_cashout-v2");return(0,s.jsx)("div",{className:"w-full",children:(0,s.jsxs)(r4.Flex,{direction:"column",gap:"md",children:[(0,s.jsx)("div",{className:"w-full rounded-[var(--radius-03)] border border-solid border-core-neutral-0-A10 bg-core-greyBlue-500 px-4 py-3",children:(0,s.jsxs)(r4.Flex,{align:"center",gap:"sm",children:[(0,s.jsx)("div",{className:"shrink-0 rounded-full",children:(0,s.jsx)(iE.PulseRing,{color:"core.freecashGreen.400",size:8,rounded:8,"aria-hidden":!0,children:(0,s.jsx)("span",{className:"block size-2 rounded-full bg-core-freecashGreen-400"})})}),(0,s.jsx)(rR.Typography,{variant:"sm",color:"core.neutral.0",children:t(e.underReviewKey)})]})}),(0,s.jsx)("div",{className:"w-full rounded-[var(--radius-04)] border border-solid border-core-freecashGreen-25-A10 bg-core-freecashGreen-25-A10 p-3",children:(0,s.jsxs)(r4.Flex,{align:"center",gap:"sm",children:[(0,s.jsx)(iA.EnvelopeOpenIcon,{size:24,className:"mt-0.5 shrink-0 text-core-freecashGreen-400","aria-hidden":!0}),(0,s.jsx)(rR.Typography,{variant:"sm",color:"core.greyBlue.25",children:(0,s.jsx)(Z.Trans,{t:t,i18nKey:e.activationKey,components:{em:(0,s.jsx)("span",{className:"text-core-freecashGreen-500"})}})})]})})]})})}var iM=e.i(191024);let i_=["completed","current","pending"],iI={completed:"core.greyBlue.100",current:"core.freecashGreen.500",pending:"core.greyBlue.100"};function iP({status:e}){return"completed"===e?(0,s.jsx)("span",{className:"block size-3.5 shrink-0 rounded-full bg-core-freecashGreen-400","aria-hidden":!0}):"current"===e?(0,s.jsx)("div",{className:"shrink-0 rounded-full",children:(0,s.jsx)(iE.PulseRing,{color:"core.freecashGreen.400",size:10,rounded:8,"aria-hidden":!0,
43children:(0,s.jsx)("span",{className:"block size-3.5 rounded-full bg-core-freecashGreen-400"})})}):(0,s.jsx)("span",{className:"block size-3.5 shrink-0 rounded-full bg-core-greyBlue-100","aria-hidden":!0})}function iB({layout:e,destinationName:t}){let{t:a}=(0,C.useTranslationTyped)("_cashout-v2"),r=e.steps.map((e,r)=>{let s=i_[r]??"pending",n="withdrawFlow.submitted.timeline.payoutSentDescription"===e.descriptionKey?a(e.descriptionKey,{destination:t}):a(e.descriptionKey);return{status:s,title:a(e.titleKey),description:n,descriptionColor:iI[s]}});return(0,s.jsx)(nZ,{variant:"neutral",iconClassName:"bottom-[-22px] right-[-33px] rotate-[15deg]",icon:(0,s.jsx)(iM.ClockClockwiseIcon,{size:110,weight:"regular",opacity:.12,color:(0,n.resolveColorToken)("core.freecashGreen.400")}),children:(0,s.jsx)("ol",{className:"m-0 flex list-none flex-col gap-0 p-0",children:r.map((e,t)=>{let a=t===r.length-1,n="pending"===e.status?"core.greyBlue.100":"core.neutral.0";return(0,s.jsxs)("li",{className:"flex gap-4",children:[(0,s.jsxs)("div",{className:"flex w-3.5 shrink-0 flex-col items-center pt-1",children:[(0,s.jsx)(iP,{status:e.status}),!a&&(0,s.jsx)("div",{className:(0,w.cn)("min-h-5 w-0.5 flex-1 rounded-full","completed"===e.status?"bg-[#204246]":"bg-core-greyBlue-200"),"aria-hidden":!0})]}),(0,s.jsx)("div",{className:(0,w.cn)("min-w-0 flex-1",!a&&"pb-4"),children:(0,s.jsxs)(r4.Flex,{direction:"column",children:[(0,s.jsx)(rR.Typography,{variant:"sm",color:n,weight:"semibold",children:e.title}),(0,s.jsx)(ik.Box,{w:"85%",children:(0,s.jsx)(rR.Typography,{variant:"xs",color:e.descriptionColor,weight:"regular",children:e.description})})]})})]},e.title)})})})}var iU=e.i(548659),iO=e.i(588993);function iG({session:e,draft:t}){let{t:a}=(0,C.useTranslationTyped)("_cashout-v2"),{lng:r}=(0,iF.useLanguageContext)(),n=e.method.displayName,i=(0,j.useFeatureFlags)(e=>e.isInstantWithdrawalApprovalEnabled)??!1,l=i?function(e){if("emailActivation"===e.kind)return{...e,underReviewKey:"withdrawFlow.submitted.processing"};let[t,,a]=e.steps;return{kind:"progressTimeline",steps:[t,{titleKey:"withdrawFlow.submitted.timeline.processing",descriptionKey:"withdrawFlow.submitted.timeline.usuallyWithinMinutes"},a]}}(e.presentation.submittedReviewInfoLayout):e.presentation.submittedReviewInfoLayout,{receiveAmount:o,targetCurrency:c,userCurrency:d,withdrawCurrency:u,disambiguate:m,hasAmount:h}=nj(e,t);return(0,s.jsxs)("div",{className:(0,w.cn)("flex h-full w-full flex-col items-center gap-6",nm),style:nh,children:[(0,s.jsx)("div",{className:"h-[180px] w-[180px] shrink-0",children:(0,s.jsx)(iU.default,{animationData:iO.default,autoplay:!0,loop:!0})}),(0,s.jsxs)("div",{className:"flex w-full flex-col items-center gap-2 text-center",children:[(0,s.jsx)(rR.Typography,{weight:"semibold",variant:"xl",color:"core.neutral.0",children:a(i?"withdrawFlow.submitted.approvedTitle":"withdrawFlow.submitted.title")}),(0,s.jsx)(rR.Typography,{variant:"sm",color:"core.greyBlue.50",children:i?a("withdrawFlow.submitted.approvedSubtitle"):a("withdrawFlow.submitted.subtitleV2",{methodName:n})})]}),h?(0,s.jsx)(sy,{amount:o,targetCurrency:c,disambiguate:m,userCurrency:d,withdrawCurrency:u,className:"text-[32px] leading-none",weight:"semibold"}):null,(0,s.jsx)("div",{className:"mt-auto w-full",children:"progressTimeline"===l.kind?(0,s.jsx)(iB,{layout:l,destinationName:n}):(0,s.jsx)(iR,{layout:l})}),(0,s.jsx)(e3.default,{href:(0,iT.getLocalizedUrl)("/cashout/withdrawals",r),className:"text-[16px] font-semibold text-core-freecashGreen-500 no-underline hover:underline",children:a("tabBar.tabs.myWithdrawals")})]})}function iL({submitStatus:e,session:t,draft:a,submitError:r,StepComponent:n,onPatch:i,onNext:l}){switch(e){case"success":return(0,s.jsx)(iG,{session:t,draft:a});case"error":return(0,s.jsx)(iS,{error:r??""});default:return n?(0,s.jsx)(n,{session:t,draft:a,onPatch:i,onNext:l}):null}}var iD=e.i(487992),iV=e.i(301575);function iW({currentStepIndex:e,stepCount:t,canGoBack:a,onBack:r,onClose:n}){let{t:i}=(0,C.useTranslationTyped)("_cashout-v2");return(0,s.jsx)("div",{className:"w-full",children:(0,s.jsxs)(r4.Flex,{justify:"center",gap:"md",align:"center",children:[(0,s.jsx)("div",{className:"shrink-0",children:(0,s.jsx)(r0.IconButton,{"aria-label":i("withdrawFlow.back"),variant:"primary",color:"accent",icon:iV.ArrowLeftIcon,onClick:r,size:"sm",disabled:!a})}),(0,s.jsx)("div",{className:"min-w-0 flex-1",children:(0,s.jsx)(iD.StepIndicator,{steps:t,currentStep:e,variant:"segments"})}),(0,s.jsx)("div",{className:"shrink-0",children:(0,s.jsx)(r0.IconButton,{"aria-label":i("withdrawFlow.close"),variant:"primary",color:"accent",icon:r1.XIcon,onClick:n,size:"sm"})})]})})}var iK=e.i(982415),iz=e.i(769464);let iH=new Map([["bold",O.createElement(O.Fragment,null,O.createElement("path",{d:"M228.75,100.05c-3.52-3.67-7.15-7.46-8.34-10.33-1.06-2.56-1.14-7.83-1.21-12.47-.15-10-.34-22.44-9.18-31.27s-21.27-9-31.27-9.18c-4.64-.07-9.9-.15-12.47-1.21-2.87-1.19-6.66-4.82-10.33-8.34C148.87,20.46,140.05,12,128,12s-20.87,8.46-27.95,15.25c-3.67,3.52-7.46,7.15-10.33,8.34-2.56,1.06-7.83,1.14-12.47,1.21C67.25,37,54.81,37.14,46,46S37,67.25,36.8,77.25c-.07,4.64-.15,9.91-1.21,12.47-1.19,2.87-4.82,6.66-8.34,10.33C20.46,107.13,12,116,12,128S20.46,148.87,27.25,156c3.52,3.67,7.15,7.46,8.34,10.33,1.06,2.56,1.14,7.83,1.21,12.47.15,10,.34,22.44,9.18,31.27s21.27,9,31.27,9.18c4.64.07,9.9.15,12.47,1.21,2.87,1.19,6.66,4.82,10.33,8.34C107.13,235.54,116,244,128,244s20.87-8.46,27.95-15.25c3.67-3.52,7.46-7.15,10.33-8.34,2.56-1.06,7.83-1.14,12.47-1.21,10-.15,22.44-.34,31.27-9.18s9-21.27,9.18
43-31.27c.07-4.64.15-9.91,1.21-12.47,1.19-2.87,4.82-6.66,8.34-10.33C235.54,148.87,244,140.05,244,128S235.54,107.13,228.75,100.05Zm-17.32,39.29c-4.82,5-10.28,10.72-13.19,17.76-2.82,6.8-2.93,14.17-3,21.29-.08,5.36-.19,12.71-2.15,14.66s-9.3,2.07-14.66,2.15c-7.13.11-14.49.22-21.29,3-7,2.92-12.73,8.38-17.76,13.2C135.78,214.84,130.4,220,128,220s-7.78-5.16-11.34-8.57c-5-4.82-10.72-10.28-17.76-13.2-6.8-2.81-14.17-2.92-21.29-3-5.36-.08-12.71-.19-14.66-2.15s-2.07-9.3-2.15-14.66c-.11-7.13-.22-14.49-3-21.29-2.91-7-8.37-12.74-13.19-17.76C41.16,135.78,36,130.4,36,128s5.16-7.78,8.57-11.34c4.82-5,10.28-10.72,13.19-17.76,2.82-6.8,2.93-14.17,3-21.29C60.88,72.25,61,64.9,63,63s9.3-2.07,14.66-2.15c7.13-.11,14.49-.22,21.29-3,7-2.92,12.73-8.38,17.76-13.2C120.22,41.16,125.6,36,128,36s7.78,5.16,11.34,8.57c5,4.82,10.72,10.28,17.76,13.2,6.8,2.81,14.17,2.92,21.29,3,5.36.08,12.71.19,14.66,2.15s2.07,9.3,2.15,14.66c.11,7.13.22,14.49,3,21.29,2.91,7,8.37,12.74,13.19,17.76,3.41,3.56,8.57,8.94,8.57,11.34S214.84,135.78,211.43,139.34ZM80,96a16,16,0,1,1,16,16A16,16,0,0,1,80,96Zm96,64a16,16,0,1,1-16-16A16,16,0,0,1,176,160Zm.49-80.49a12,12,0,0,1,0,17l-80,80a12,12,0,0,1-17-17l80-80A12,12,0,0,1,176.49,79.51Z"}))],["duotone",O.createElement(O.Fragment,null,O.createElement("path",{d:"M232,128c0,12.51-17.82,21.95-22.68,33.69-4.68,11.32,1.42,30.65-7.78,39.85s-28.53,3.1-39.85,7.78C150,214.18,140.5,232,128,232s-22-17.82-33.69-22.68c-11.32-4.68-30.64,1.42-39.85-7.78s-3.1-28.53-7.78-39.85C41.82,150,24,140.5,24,128s17.82-22,22.68-33.69C51.36,83,45.26,63.66,54.46,54.46S83,51.36,94.31,46.68C106.05,41.82,115.5,24,128,24S150,41.82,161.69,46.68c11.32,4.68,30.64-1.42,39.85,7.78s3.1,28.53,7.78,39.85C214.18,106.05,232,115.5,232,128Z",opacity:"0.2"}),O.createElement("path",{d:"M225.86,102.82c-3.77-3.94-7.67-8-9.14-11.57-1.36-3.27-1.44-8.69-1.52-13.94-.15-9.76-.31-20.82-8-28.51s-18.75-7.85-28.51-8c-5.25-.08-10.67-.16-13.94-1.52-3.56-1.47-7.63-5.37-11.57-9.14C146.28,23.51,138.44,16,128,16s-18.27,7.51-25.18,14.14c-3.94,3.77-8,7.67-11.57,9.14C88,40.64,82.56,40.72,77.31,40.8c-9.76.15-20.82.31-28.51,8S41,67.55,40.8,77.31c-.08,5.25-.16,10.67-1.52,13.94-1.47,3.56-5.37,7.63-9.14,11.57C23.51,109.73,16,117.56,16,128s7.51,18.27,14.14,25.18c3.77,3.94,7.67,8,9.14,11.57,1.36,3.27,1.44,8.69,1.52,13.94.15,9.76.31,20.82,8,28.51s18.75,7.85,28.51,8c5.25.08,10.67.16,13.94,1.52,3.56,1.47,7.63,5.37,11.57,9.14C109.72,232.49,117.56,240,128,240s18.27-7.51,25.18-14.14c3.94-3.77,8-7.67,11.57-9.14,3.27-1.36,8.69-1.44,13.94-1.52,9.76-.15,20.82-.31,28.51-8s7.85-18.75,8-28.51c.08-5.25.16-10.67,1.52-13.94,1.47-3.56,5.37-7.63,9.14-11.57C232.49,146.27,240,138.44,240,128S232.49,109.73,225.86,102.82Zm-11.55,39.29c-4.79,5-9.75,10.17-12.38,16.52-2.52,6.1-2.63,13.07-2.73,19.82-.1,7-.21,14.33-3.32,17.43s-10.39,3.22-17.43,3.32c-6.75.1-13.72.21-19.82,2.73-6.35,2.63-11.52,7.59-16.52,12.38S132,224,128,224s-9.15-4.92-14.11-9.69-10.17-9.75-16.52-12.38c-6.1-2.52-13.07-2.63-19.82-2.73-7-.1-14.33-.21-17.43-3.32s-3.22-10.39-3.32-17.43c-.1-6.75-.21-13.72-2.73-19.82-2.63-6.35-7.59-11.52-12.38-16.52S32,132,32,128s4.92-9.14,9.69-14.11,9.75-10.17,12.38-16.52c2.52-6.1,2.63-13.07,2.73-19.82.1-7,.21-14.33,3.32-17.43S70.51,56.9,77.55,56.8c6.75-.1,13.72-.21,19.82-2.73,6.35-2.63,11.52-7.59,16.52-12.38S124,32,128,32s9.15,4.92,14.11,9.69,10.17,9.75,16.52,12.38c6.1,2.52,13.07,2.63,19.82,2.73,7,.1,14.33.21,17.43,3.32s3.22,10.39,3.32,17.43c.1,6.75.21,13.72,2.73,19.82,2.63,6.35,7.59,11.52,12.38,16.52S224,124,224,128,219.08,137.14,214.31,142.11ZM120,96a24,24,0,1,0-24,24A24,24,0,0,0,120,96ZM88,96a8,8,0,1,1,8,8A8,8,0,0,1,88,96Zm72,40a24,24,0,1,0,24,24A24,24,0,0,0,160,136Zm0,32a8,8,0,1,1,8-8A8,8,0,0,1,160,168Zm13.66-74.34-80,80a8,8,0,0,1-11.32-11.32l80-80a8,8,0,0,1,11.32,11.32Z"}))],["fill",O.createElement(O.Fragment,null,O.createElement("path",{d:"M96,104a8,8,0,1,1,8-8A8,8,0,0,1,96,104Zm64,48a8,8,0,1,0,8,8A8,8,0,0,0,160,152Zm80-24c0,10.44-7.51,18.27-14.14,25.18-3.77,3.94-7.67,8-9.14,11.57-1.36,3.27-1.44,8.69-1.52,13.94-.15,9.76-.31,20.82-8,28.51s-18.75,7.85-28.51,8c-5.25.08-10.67.16-13.94,1.52-3.57,1.47-7.63,5.37-11.57,9.14C146.27,232.49,138.44,240,128,240s-18.27-7.51-25.18-14.14c-3.94-3.77-8-7.67-11.57-9.14-3.27-1.36-8.69-1.44-13.94-1.52-9.76-.15-20.82-.31-28.51-8s-7.85-18.75-8-28.51c-.08-5.25-.16-10.67-1.52-13.94-1.47-3.57-5.37-7.63-9.14-11.57C23.51,146.27,16,138.44,16,128s7.51-18.27,14.14-25.18c3.77-3.94,7.67-8,9.14-11.57,1.36-3.27,1.44-8.69,1.52-13.94.15-9.76.31-20.82,8-28.51s18.75-7.85,28.51-8c5.25-.08,10.67-.16,13.94-1.52,3.57-1.47,7.63-5.37,11.57-9.14C109.73,23.51,117.56,16,128,16s18.27,7.51,25.18,14.14c3.94,3.77,8,7.67,11.57,9.14,3.27,1.36,8.69,1.44,13.94,1.52,9.76.15,20.82.31,28.51,8s7.85,18.75,8,28.51c.08,5.25.16,10.67,1.52,13.94,1.47,3.57,5.37,7.63,9.14,11.57C232.49,109.73,240,11
437.56,240,128ZM96,120A24,24,0,1,0,72,96,24,24,0,0,0,96,120Zm77.66-26.34a8,8,0,0,0-11.32-11.32l-80,80a8,8,0,0,0,11.32,11.32ZM184,160a24,24,0,1,0-24,24A24,24,0,0,0,184,160Z"}))],["light",O.createElement(O.Fragment,null,O.createElement("path",{d:"M224.42,104.2c-3.9-4.07-7.93-8.27-9.55-12.18-1.5-3.63-1.58-9-1.67-14.68-.14-9.38-.3-20-7.42-27.12S188,42.94,178.66,42.8c-5.68-.09-11-.17-14.68-1.67-3.91-1.62-8.11-5.65-12.18-9.55C145.16,25.22,137.64,18,128,18s-17.16,7.22-23.8,13.58c-4.07,3.9-8.27,7.93-12.18,9.55-3.63,1.5-9,1.58-14.68,1.67-9.38.14-20,.3-27.12,7.42S42.94,68,42.8,77.34c-.09,5.68-.17,11-1.67,14.68-1.62,3.91-5.65,8.11-9.55,12.18C25.22,110.84,18,118.36,18,128s7.22,17.16,13.58,23.8c3.9,4.07,7.93,8.27,9.55,12.18,1.5,3.63,1.58,9,1.67,14.68.14,9.38.3,20,7.42,27.12S68,213.06,77.34,213.2c5.68.09,11,.17,14.68,1.67,3.91,1.62,8.11,5.65,12.18,9.55C110.84,230.78,118.36,238,128,238s17.16-7.22,23.8-13.58c4.07-3.9,8.27-7.93,12.18-9.55,3.63-1.5,9-1.58,14.68-1.67,9.38-.14,20-.3,27.12-7.42s7.28-17.74,7.42-27.12c.09-5.68.17-11,1.67-14.68,1.62-3.91,5.65-8.11,9.55-12.18C230.78,145.16,238,137.64,238,128S230.78,110.84,224.42,104.2Zm-8.66,39.29c-4.67,4.87-9.5,9.91-12,15.91-2.38,5.74-2.48,12.52-2.58,19.08-.11,7.44-.23,15.14-3.9,18.82s-11.38,3.79-18.82,3.9c-6.56.1-13.34.2-19.08,2.58-6,2.48-11,7.31-15.91,12-5.25,5-10.68,10.24-15.49,10.24s-10.24-5.21-15.5-10.24c-4.86-4.67-9.9-9.5-15.9-12-5.74-2.38-12.52-2.48-19.08-2.58-7.44-.11-15.14-.23-18.82-3.9s-3.79-11.38-3.9-18.82c-.1-6.56-.2-13.34-2.58-19.08-2.48-6-7.31-11-12-15.91C35.21,138.24,30,132.81,30,128s5.21-10.24,10.24-15.49c4.67-4.87,9.5-9.91,12-15.91,2.38-5.74,2.48-12.52,2.58-19.08.11-7.44.23-15.14,3.9-18.82s11.38-3.79,18.82-3.9c6.56-.1,13.34-.2,19.08-2.58,6-2.48,11-7.31,15.91-12C117.76,35.21,123.19,30,128,30s10.24,5.21,15.5,10.24c4.86,4.67,9.9,9.5,15.9,12,5.74,2.38,12.52,2.48,19.08,2.58,7.44.11,15.14.23,18.82,3.9s3.79,11.38,3.9,18.82c.1,6.56.2,13.34,2.58,19.08,2.48,6,7.31,11,12,15.91,5,5.25,10.24,10.68,10.24,15.49S220.79,138.24,215.76,143.49ZM118,96a22,22,0,1,0-22,22A22,22,0,0,0,118,96ZM86,96a10,10,0,1,1,10,10A10,10,0,0,1,86,96Zm74,42a22,22,0,1,0,22,22A22,22,0,0,0,160,138Zm0,32a10,10,0,1,1,10-10A10,10,0,0,1,160,170Zm12.24-77.76-80,80a6,6,0,0,1-8.48-8.48l80-80a6,6,0,0,1,8.48,8.48Z"}))],["regular",O.createElement(O.Fragment,null,O.createElement("path",{d:"M225.86,102.82c-3.77-3.94-7.67-8-9.14-11.57-1.36-3.27-1.44-8.69-1.52-13.94-.15-9.76-.31-20.82-8-28.51s-18.75-7.85-28.51-8c-5.25-.08-10.67-.16-13.94-1.52-3.56-1.47-7.63-5.37-11.57-9.14C146.28,23.51,138.44,16,128,16s-18.27,7.51-25.18,14.14c-3.94,3.77-8,7.67-11.57,9.14C88,40.64,82.56,40.72,77.31,40.8c-9.76.15-20.82.31-28.51,8S41,67.55,40.8,77.31c-.08,5.25-.16,10.67-1.52,13.94-1.47,3.56-5.37,7.63-9.14,11.57C23.51,109.73,16,117.56,16,128s7.51,18.27,14.14,25.18c3.77,3.94,7.67,8,9.14,11.57,1.36,3.27,1.44,8.69,1.52,13.94.15,9.76.31,20.82,8,28.51s18.75,7.85,28.51,8c5.25.08,10.67.16,13.94,1.52,3.56,1.47,7.63,5.37,11.57,9.14C109.72,232.49,117.56,240,128,240s18.27-7.51,25.18-14.14c3.94-3.77,8-7.67,11.57-9.14,3.27-1.36,8.69-1.44,13.94-1.52,9.76-.15,20.82-.31,28.51-8s7.85-18.75,8-28.51c.08-5.25.16-10.67,1.52-13.94,1.47-3.56,5.37-7.63,9.14-11.57C232.49,146.27,240,138.44,240,128S232.49,109.73,225.86,102.82Zm-11.55,39.29c-4.79,5-9.75,10.17-12.38,16.52-2.52,6.1-2.63,13.07-2.73,19.82-.1,7-.21,14.33-3.32,17.43s-10.39,3.22-17.43,3.32c-6.75.1-13.72.21-19.82,2.73-6.35,2.63-11.52,7.59-16.52,12.38S132,224,128,224s-9.15-4.92-14.11-9.69-10.17-9.75-16.52-12.38c-6.1-2.52-13.07-2.63-19.82-2.73-7-.1-14.33-.21-17.43-3.32s-3.22-10.39-3.32-17.43c-.1-6.75-.21-13.72-2.73-19.82-2.63-6.35-7.59-11.52-12.38-16.52S32,132,32,128s4.92-9.14,9.69-14.11,9.75-10.17,12.38-16.52c2.52-6.1,2.63-13.07,2.73-19.82.1-7,.21-14.33,3.32-17.43S70.51,56.9,77.55,56.8c6.75-.1,13.72-.21,19.82-2.73,6.35-2.63,11.52-7.59,16.52-12.38S124,32,128,32s9.15,4.92,14.11,9.69,10.17,9.75,16.52,12.38c6.1,2.52,13.07,2.63,19.82,2.73,7,.1,14.33.21,17.43,3.32s3.22,10.39,3.32,17.43c.1,6.75.21,13.72,2.73,19.82,2.63,6.35,7.59,11.52,12.38,16.52S224,124,224,128,219.08,137.14,214.31,142.11ZM120,96a24,24,0,1,0-24,24A24,24,0,0,0,120,96ZM88,96a8,8,0,1,1,8,8A8,8,0,0,1,88,96Zm72,40a24,24,0,1,0,24,24A24,24,0,0,0,160,136Zm0,32a8,8,0,1,1,8-8A8,8,0,0,1,160,168Zm13.66-74.34-80,80a8,8,0,0,1-11.32-11.32l80-80a8,8,0,0,1,11.32,11.32Z"}))],["thin",O.createElement(O.Fragment,null,O.createElement("path",{d:"M223,105.58c-4-4.2-8.2-8.54-10-12.8-1.65-4-1.73-9.53-1.82-15.41-.14-9-.29-19.19-6.83-25.74s-16.74-6.69-25.74-6.83c-5.88-.09-11.43-.17-15.41-1.82-4.26-1.76-8.6-5.93-12.8-10-6.68-6.4-13.59-13-22.42-13s-15.74,6.62-22.42,13c-4.2,4-8.54,8.2-12.8,10-4,1.65-9.53,1.73-15.41,1.82-9,.14-19.19.29-25.74,6.83S44.94,68.37,44.8,77.37c-.09,5.88-.17,11.43-1.82,15.41-1.76,4.26-5.93,8.6-10,12.8-6.4,6.68-13,13.59-13,22.42s6.62,15.74,13,22.42c4,4.2,8.2,8.54,10,12.8,1.65,4,1.73,9.53,1.82,15.41.14,9,.29,19.19,6.83,25.74s16.74,6.69,25.74,6.83c5.88.09,11.43.17,15.41,1.82,4.26,1.76,8.6,5.93,12.8,10,6.68,6.4,13.59,13,22.42,13s15.74-6.62,22.42-13c4.2-4,8.54-8.2,12.8-10,4-1.65,9.53-1.73,15.41-1.82,9-.14,19.19-.29,25.74-6.83s6.69-16.74,6.83-25.74c.09-5.88.17-11.43,1.82-15.41,1.76-4.26,5.93-8.6,10-12.8,6.4-6.68,13-13.59,13-22.42S229.38,112.26,223,105.58Zm-5.78,39.3c-4.54,4.73-9.24,9.63-11.57,15.28-2.23,5.39-2.33,12-2.43,18.35-.12,8.2-.24,16-4.49,20.2s-12,4.37-20.2,4.49c-6.37.1-13,.2-18.35,2.43-5.65,2.34-10.55,7-15.28,11.57C139.09,222.75,133.62,228,128,228s-11.09-5.25-16.88-10.8c-4.73-4.54-9.63-9.23-15.28-11.57-5.39-2.23-12-2.33-18.35-2.43-8.2-.12-15.95-.24-20.2
43-4.49s-4.37-12-4.49-20.2c-.1-6.37-.2-13-2.43-18.35-2.33-5.65-7-10.55-11.57-15.28C33.25,139.09,28,133.62,28,128s5.25-11.09,10.8-16.88c4.54-4.73,9.24-9.63,11.57-15.28,2.23-5.39,2.33-12,2.43-18.35.12-8.2.24-15.95,4.49-20.2s12-4.37,20.2-4.49c6.37-.1,13-.2,18.35-2.43,5.65-2.34,10.55-7,15.28-11.57C116.91,33.25,122.38,28,128,28s11.09,5.25,16.88,10.8c4.73,4.54,9.63,9.23,15.28,11.57,5.39,2.23,12,2.33,18.35,2.43,8.2.12,16,.24,20.2,4.49s4.37,12,4.49,20.2c.1,6.37.2,13,2.43,18.35,2.33,5.65,7,10.55,11.57,15.28,5.55,5.79,10.8,11.26,10.8,16.88S222.75,139.09,217.2,144.88ZM116,96a20,20,0,1,0-20,20A20,20,0,0,0,116,96ZM84,96a12,12,0,1,1,12,12A12,12,0,0,1,84,96Zm76,44a20,20,0,1,0,20,20A20,20,0,0,0,160,140Zm0,32a12,12,0,1,1,12-12A12,12,0,0,1,160,172Zm10.83-81.17-80,80a4,4,0,0,1-5.66-5.66l80-80a4,4,0,1,1,5.66,5.66Z"}))]]),iq=O.forwardRef((e,t)=>O.createElement(iz.default,{ref:t,...e,weights:iH}));function i$({stakeRoute:e}){let{t}=(0,C.useTranslationTyped)("_cashout-v2"),{stakeBonus:a,stakeUSBonus:r}=(0,k.useStakeBonus)(),i="us"===e?r:a;return i<=0?null:(0,s.jsxs)("div",{className:"flex w-full items-center justify-center gap-2 rounded-lg bg-highlight-fuschia-25-A10 px-2.5 py-2.5 phoneMax:px-7",children:[(0,s.jsx)(iq,{size:20,weight:"fill",color:(0,n.resolveColorToken)("highlight.fuschia.500"),"aria-hidden":!0}),(0,s.jsx)(rR.Typography,{variant:"xs",weight:"medium",color:"core.neutral.0",children:(0,s.jsx)("span",{className:"text-sm font-medium text-core-neutral-0",children:(0,s.jsx)(Z.Trans,{t:t,i18nKey:"withdrawFlow.amount.stakeUpsellBanner",values:{percent:i},components:{em:(0,s.jsx)("span",{className:"text-sm font-semibold text-highlight-fuschia-500"})}})})})]})}function iQ({currentStep:e,currentStepMeta:t,submitError:a,ctaLabel:r,ctaDisabled:n,isLoading:i,useGhostConfirmCta:l=!1,onPrimaryCta:o,onWithdrawClick:c}){let{t:d}=(0,C.useTranslationTyped)("_cashout-v2"),u=(l?(0,s.jsx)(iK.default,{trigger:e=>(0,s.jsx)("div",{className:"min-h-[48px] w-full",children:(0,s.jsx)(g.Button,{variant:"primary",size:"lg",width:"full",isDisabled:n,onClick:e.onOpen,children:(0,s.jsx)("span",{children:r})})}),closeHandler:c}):null)??(0,s.jsx)("div",{className:"min-h-[48px] w-full",children:(0,s.jsx)(g.Button,{variant:"primary",size:"lg",width:"full",isDisabled:n,isLoading:i,onClick:o,children:(0,s.jsx)("span",{children:r})})});return(0,s.jsx)("div",{className:"shrink-0 p-0",children:(0,s.jsx)("div",{className:"w-full",children:(0,s.jsxs)(r4.Flex,{direction:"column",gap:"md",children:[t.amountFooterPromo?.kind==="stakeUpsell"&&(0,s.jsx)(i$,{stakeRoute:t.amountFooterPromo.stakeRoute}),t.amountDisclaimer&&t.amountDisclaimer.length>0&&(0,s.jsx)("div",{children:t.amountDisclaimer.map(e=>(0,s.jsx)(rR.Typography,{variant:"micro",align:"center",color:"core.greyBlue.100",weight:"regular",children:e.values?d(e.i18nKey,e.values):d(e.i18nKey)},e.i18nKey))}),a&&"confirm"===e&&(0,s.jsx)("p",{className:"m-0 text-[12px] text-core-red-600",children:a}),u]})})})}iq.displayName="SealPercentIcon";var iZ=e.i(919261);function iY({visible:e,className:t}){return(0,s.jsx)("div",{"aria-hidden":!0,className:(0,w.cn)("pointer-events-none flex size-8 shrink-0 items-center justify-center rounded-full","border-[0.5px] border-solid border-core-neutral-0-A10 bg-core-neutral-0-A10 backdrop-blur-[2px]","text-core-neutral-0 transition-opacity duration-200",e?"opacity-100 animate-scrollHintBounce motion-reduce:animate-none":"opacity-0",t),children:(0,s.jsx)(iZ.ArrowDownIcon,{size:16,weight:"bold"})})}var iX=e.i(54513);let iJ={height:16,marginTop:-16};function i0({armed:e=!0}={}){let{ref:t,inView:a}=(0,iX.useInView)({initialInView:!0}),{ref:r,inView:s}=(0,iX.useInView)({initialInView:!0}),{ref:n,inView:i}=(0,iX.useInView)({initialInView:!0});return{startRef:t,endRef:r,hintRef:n,hintSentinelStyle:iJ,fadeTop:e&&!a,fadeBottom:e&&!s,isHintVisible:e&&a&&!i}}let i1="linear-gradient(to bottom, transparent 0, #000 var(--scroll-edge-top), #000 calc(100% - var(--scroll-edge-bottom)), transparent 100%)";function i2({children:e,className:t,scrollClassName:a,contentKey:r=""}){let[n,i]=(0,O.useState)(!1),[l,o]=(0,O.useState)(r);l!==r&&(o(r),i(!1));let{startRef:c,endRef:d,hintRef:u,hintSentinelStyle:m,fadeTop:h,fadeBottom:p,isHintVisible:x}=i0({armed:n});(0,O.useEffect)(()=>{let e=window.matchMedia("(prefers-reduced-motion: reduce)").matches,t=window.setTimeout(()=>i(!0),900*!e);return()=>window.clearTimeout(t)},[r]);let f={"--scroll-edge-top":`${40*!!h}px`,"--scroll-edge-bottom":`${40*!!p}px`,maskImage:i1,WebkitMaskImage:i1};return(0,s.jsxs)("div",{className:(0,w.cn)("relative min-h-0",t),children:[(0,s.jsxs)("div",{style:f,className:(0,w.cn)("h-full min-h-0","[scrollbar-width:thin] [scrollbar-color:var(--color-core-greyBlue-500)_transparent] [&::-webkit-scrollbar]:w-1 [&::-webkit-scrollbar]:h-1 [&::-webkit-scrollbar-track]:bg-transparent [&::-webkit-scrollbar-thumb]:rounded-full [&::-webkit-scrollbar-thumb]:bg-core-greyBlue-500 [&::-webkit-scrollbar-thumb:hover]:bg-core-greyBlue-400","transition-[--scroll-edge-top,--scroll-edge-bottom] duration-200 motion-reduce:transition-none",n?"overflow-y-auto":"overflow-y-hidden",a),children:[(0,s.jsx)("div",{ref:c,className:"h-0"}),e,(0,s.jsx)("div",{ref:u,style:m}),(0,s.jsx)("div",{ref:d,className:"h-0"})]}),(0,s.jsx)("div",{className:(0,w.cn)("pointer-events-none absolute inset-x-0 bottom-2 z-2 flex justify-center",a),children:(0,s.jsx)(iY,{visible:x})})]})}var i3=e.i(606306);function i5(){let{t:e,isOpen:t,session:a,draft:r,currentStep:n,currentStepIndex:o,stepCount:c,currentStepMeta:d,canGoBack:u,closeWithdrawFlow:m,resetWithdrawFlow:h,goBack:p,goNext:x,setDraft:f,submitStatus:g,submitError:y,showHeader:b,showFooter:v,isLoading:j,ctaLabel:k,ctaDisabled:N,onPrimaryCta:S,useGhostConfirmCta:F,onWithdrawClick:T,StepComponent:E}=function(){let{t:e}=(0,C.useTranslationTyped)("_cashout-v2"),t=(0,$.useQueryClient)(),{isOpen:a,currentStep:r,session:s,draft:n,currentStepIndex:o,stepCount:c,currentStepMeta:d,canGoBack:u,closeWithdrawFlow:m,resetWithdrawFlow:h,goNext:p,goBack:x,setDraft:f,submitStatus:g,submitError:y,submitStart:b,submitSuccess:v,submitFail:w}=ln(),{onWithdrawClick:j,showSignUpTrigger:k}=(0,rW.useRefineGetghostAccount)(),{handleSubmit:N,isSubmitting:S}=function({session:e,draft:t,onSuccess:a,onError:r,onSubmitStart:s}){let{mutations:n,giftCardValueToCoins:i,onEmailRequired:o,unknownErrorMessage:c,resolveErrorMessage:d}=function(){let e,t,a,r,s,n,i,o,c,d,{t:u}=(0,C.useTranslationTyped)("_cashout"),{t:m}=(0,C.useTranslationTyped)("_cashout-v2"),{toast:h}=(0,l.useToast)(),p=(e=(0,iC.useTangoMutation)(),t=(0,ij.useTremendousMutations)(),a=(0,ix.useGifteeMutation)(),r=(0,ip.useCryptoMutation)(),s=(0,iv.useStakeComMutation)(),n=(0,iw.useStakeUsMutation)(),i=(0,iy.useRevolutMutation)(),o=(0,ib.useRevolutUsMutation)(),c=(0,ig.useRevolutCardMutation)(),d=e.isPending||t.isPending||a.isPending||r.isPending||s.isPending||n.isPending||i.isPending||o.isPending||c.isPending,{tangoCashoutMutation:e,tremendousGiftcardCashoutMutation:t,gifteeCashoutMutation:a,cryptoMutation:r,stakeComMutation:s,stakeUsMutation:n,revolutMutation:i,revolutUsMutation:o,revolutCardMutation:c,isSubmitting:d}),x=s7(),f=m("withdrawFlow.submittedError.errorDescriptions.unableToProcessWithdrawal"),g=(0,O.useMemo)(()=>({withdrawalLimitReached:m("withdrawFlow.submittedError.errorDescriptions.withdrawalLimitReached"),accountIdentityConflict:m("withdrawFlow.submittedError.errorDescriptions.accountIdentityConflict"),unableToProcessWithdrawal:m("withdrawFlow.submittedError.errorDescriptions.unableToProcessWithdrawal"),unavailableWithdrawalMethod:m("withdrawFlow.submittedError.errorDescriptions.unavailableWithdrawalMethod"),exceedingWithdrawalFee:m("withdrawFlow.submittedError.errorDescriptions.exceedingWithdrawalFee"),invalidRevtag:m("withdrawFlow.submittedError.errorDescriptions.invalidRevtag"),invalidAchDetails:m("withdrawFlow.submittedError.errorDescriptions.invalidAchDetails"),invalidIbanOrSwiftDetails:m("withdrawFlow.submittedError.errorDescriptions.invalidIbanOrSwiftDetails"),cashoutProviderUnavailable:m("withdrawFlow.submittedError.errorDescriptions.cashoutProviderUnavailable")}),[m]),y=(0,O.useCallback)(e=>{var t,a,r;let s,n;return t=e,a=g,r=f,(n=(s=function(e){if(e instanceof Error){let t=id(e.cause);if(t)return t}return id(e)}(t))?ic[s]??"unableToProcessWithdrawal":null)?a[n]??r:r},[g,f]);return{mutations:p,giftCardValueToCoins:x,onEmailRequired:(0,O.useCallback)(()=>{h({title:u("cashoutV2ErrorMessages.EmailIsRequired"),status:"error"})},[h,u]),unknownErrorMessage:f,resolveErrorMessage:y}}();return{handleSubmit:(0,O.useCallback)(async()=>{e&&t&&await ih({session:e,draft:t,mutations:n,giftCardValueToCoins:i,onEmailRequired:o,onSubmitStart:s,onSuccess:a,onError:(e,t)=>
43r?.(e,t),closeOnError:!1,unknownErrorMessage:c,resolveErrorMessage:d})},[t,e,n,i,o,c,d,a,r,s]),isSubmitting:n.isSubmitting}}({session:s,draft:n,onSuccess:e=>{t.invalidateQueries({queryKey:[i.QueryKeys.GRAPHQL_GET_WITHDRAWALS]}),null!=e&&v(e)},onError:(e,t)=>{w(t??b(),e)},onSubmitStart:b}),F=(0,O.useCallback)(async()=>{s&&n&&await N()},[s,n,N]),T=(0,O.useCallback)(()=>{"confirm"===r?F():p()},[r,F,p]),E="success"===g||"error"===g,A=!!d.showCta&&!E,R="submitting"===g||S,M=function(e,t){switch(e){case"confirmAmount":return t("withdrawFlow.cta.confirmAmount","Confirm Amount");case"confirmEmail":return t("withdrawFlow.cta.confirmEmail","Confirm Email");case"confirmPaypalEmail":return t("withdrawFlow.cta.confirmPaypalEmail","Confirm PayPal Email");case"confirmStakeUsername":return t("withdrawFlow.cta.confirmStakeUsername","Confirm Stake Username");case"confirmBankDetails":return t("withdrawFlow.cta.confirmBankDetails","Confirm Bank Details");case"confirmRevolutDetails":return t("withdrawFlow.cta.confirmRevolutDetails","Confirm Revolut Account");case"confirmWalletAddress":return t("withdrawFlow.cta.confirmWalletAddress","Confirm Wallet Address");case"confirmCashout":return t("withdrawFlow.cta.confirmCashout","Confirm Cashout")}}(d.ctaLabelKey,e),_=d.isDisabled||R,I=k&&"confirm"===r,P=r?io[r].Component:null;return{t:e,isOpen:a,session:s,draft:n,currentStep:r,currentStepIndex:o,stepCount:c,currentStepMeta:d,canGoBack:u,closeWithdrawFlow:m,resetWithdrawFlow:h,goBack:x,goNext:p,setDraft:f,submitStatus:g,submitError:y,showHeader:!E,showFooter:A,isLoading:R,ctaLabel:M,ctaDisabled:_,onPrimaryCta:T,useGhostConfirmCta:I,onWithdrawClick:j,StepComponent:P}}(),A=(0,rV.useIsMobile)();(0,i3.useHideNativeNavBar)(t);let R=[a?.method.slug,a?.presentation.destinationKind,n??"none",g].join("-");return a&&r&&("success"===g||"error"===g||n)?(0,s.jsx)(rG,{open:t,zIndex:1400,placement:"right",surface:"raised",size:A?"full":480,onOpenChange:e=>{e||m()},onCloseComplete:h,hideClose:b,closeLabel:e("withdrawFlow.close"),belowHeader:!A,children:(0,s.jsxs)("div",{className:(0,w.cn)("flex h-full min-h-0 flex-col overflow-hidden bg-core-greyBlue-800","gap-6 phoneMax:gap-8","pt-4 pb-6 pl-4 pr-0 phoneMax:pt-8 phoneMax:pb-8 phoneMax:pl-8 phoneMax:pr-0","phoneMax:top-(--header-height) phoneMax:h-[calc(100dvh-var(--header-height))]"),children:[b&&(0,s.jsx)("div",{className:(0,w.cn)("w-full shrink-0 pr-4 phoneMax:pr-8",np),style:nx,children:(0,s.jsx)(iW,{currentStepIndex:o,stepCount:c,canGoBack:u,onBack:()=>u&&p(),onClose:m})}),(0,s.jsx)(i2,{className:"flex-1",contentKey:R,scrollClassName:"pr-4 phoneMax:pr-8",children:(0,s.jsx)(iL,{submitStatus:g,session:a,draft:r,submitError:y,StepComponent:E,onPatch:f,onNext:x})},R),v&&(0,s.jsx)("div",{className:(0,w.cn)("pr-4 phoneMax:pr-10",np),style:nf,children:(0,s.jsx)(iQ,{currentStep:n,currentStepMeta:d,submitError:y,ctaLabel:k,ctaDisabled:N,isLoading:j,useGhostConfirmCta:F,onPrimaryCta:S,onWithdrawClick:T})})]},`${a.method.slug}-${a.presentation.destinationKind}`)}):null}let i4={isOpen:!1,session:null,steps:[],stepIndex:0,draft:null,submitStatus:"idle",submitError:null,submitRequestId:null},i8=["amount","destination","confirm"];function i6(e,t){if(!e)return null;if(!t)return e;let{stake:a,bankDetails:r,revolut:s,...n}=t,i=e.stake;void 0!==a&&(i=e.stake?{...e.stake,...a}:a);let l=e.bankDetails;
43void 0!==r&&(l=e.bankDetails?{...e.bankDetails,...r}:r);let o=e.revolut;return void 0!==s&&(o=e.revolut?{...e.revolut,...s}:s),{...e,...n,...void 0!==a?{stake:i}:null,...void 0!==r?{bankDetails:l}:null,...void 0!==s?{revolut:o}:null}}function i7(e,t){var a,r,s,n,i,l,o,c;switch(t.type){case"OPEN":let d,u,m;return d=(a=t.args).withdrawPresentation??a$(a.method,a.policyContext),u=function(e,t={}){let a=[...i8],r=t.withdrawPresentation??a$(e,t.policyContext);return"com"===r.stakeRoute&&(a=["stakeCryptoSelection",...a]),r.collectEmail||"email"!==r.destinationKind||(a=a.filter(e=>"destination"!==e)),a}(a.method,{withdrawPresentation:d,policyContext:a.policyContext}),m={giftCard:a.giftCard},"us"===d.stakeRoute&&(m.stake=function(e){let[t]=e.method.bonus?.()??[],a="number"==typeof t&&t>0?t:void 0;return{currency:R.WithdrawCurrency.StakeCash,minimumCoinsAmount:e.method.minimumCoinsAmount,...null!=a?{bonusPercent:a}:{}}}(a)),{isOpen:!0,session:{method:a.method,presentation:d,amountPreselected:null!=a.giftCard},steps:u,stepIndex:0,draft:m,submitStatus:"idle",submitError:null,submitRequestId:null};case"NEXT":let h,p;return r=t.patch,h=i6(e.draft,r),!nl(p={...e,draft:h})||e.stepIndex>=e.steps.length-1?p:{...p,stepIndex:e.stepIndex+1,submitStatus:"idle",submitError:null,submitRequestId:null};case"BACK":return no(e)?{...e,stepIndex:e.stepIndex-1,submitStatus:"idle",submitError:null,submitRequestId:null}:e;case"PATCH":return s=t.patch,e.isOpen&&e.draft?{...e,draft:i6(e.draft,s)}:e;case"SUBMIT_START":return n=t.requestId,e.isOpen&&e.draft?{...e,submitStatus:"submitting",submitError:null,submitRequestId:n}:e;case"SUBMIT_SUCCESS":return i=t.requestId,e.isOpen&&e.draft&&e.submitRequestId===i?{...e,submitStatus:"success",submitError:null}:e;case"SUBMIT_END":return l=t.requestId,e.submitRequestId!==l?e:{...e,submitStatus:"idle",submitError:null,submitRequestId:null};case"SUBMIT_FAIL":return o=t.requestId,c=t.error,e.isOpen&&e.submitRequestId===o?{...e,submitStatus:"error",submitError:c}:e;case"CLOSE":if(!e.isOpen)return e;return{...e,isOpen:!1};case"FINALIZE_CLOSE":if(e.isOpen)return e;return i4;case"RESET":return i4;default:return e}}var i9=e.i(642146);let le=(0,O.createContext)(null),lt=void 0===globalThis.window?O.useEffect:O.useLayoutEffect,la={ctaLabelKey:"confirmAmount",isDisabled:!0,showCta:!1};function lr({children:e,policyContext:t}){let[a,r]=(0,O.useReducer)(i7,i4),n=(0,$.useQueryClient)(),l=(0,eJ.default)(),o=(0,rb.usePathname)(),c=(0,O.useRef)(null),{withdrawableNowBalance:d}=(0,x.default)(),u=s7();(0,rv.useBodyAttribute)("data-withdraw-flow-open",!!a.session);let m=(0,O.useCallback)(e=>{l||n.invalidateQueries({queryKey:[i.QueryKeys.GRAPHQL_GET_GIFTCARDS]}),c.current=o,r({type:"OPEN",args:{...e,policyContext:e.policyContext??t}})},[l,o,t,n]),h=(0,O.useCallback)(()=>{r({type:"CLOSE"})},[]),p=(0,O.useCallback)(()=>{c.current=null,r({type:"FINALIZE_CLOSE"})},[]),f=!!a.session;lt(()=>((0,i9.setWithdrawDrawerOverlayHold)(f),()=>(0,i9.setWithdrawDrawerOverlayHold)(!1)),[f]),(0,O.useEffect)(()=>{a.isOpen&&null!==c.current&&o!==c.current&&(c.current=null,r({type:"RESET"}))},[o,a.isOpen]);let g=(0,O.useCallback)(e=>{r({type:"NEXT",patch:e})},[]),y=(0,O.useCallback)(()=>{r({type:"BACK"})},[]),b=(0,O.useCallback)(e=>{r({type:"PATCH",patch:e})},[]),v=(0,O.useRef)(0),w=(0,O.useCallback)(()=>{v.current+=1;let e=v.current;return r({type:"SUBMIT_START",requestId:e}),e},[]),C=(0,O.useCallback)(e=>{r({type:"SUBMIT_SUCCESS",requestId:e})},[]),j=(0,O.useCallback)(e=>{r({type:"SUBMIT_END",requestId:e})},[]),k=(0,O.useCallback)((e,t)=>{r({type:"SUBMIT_FAIL",requestId:e,error:t})},[]),N=(0,O.useMemo)(()=>{let e=a.steps[a.stepIndex],t=!!a.session;return{isOpen:a.isOpen,currentStep:e,steps:a.steps,session:a.session,draft:a.draft,currentStepIndex:a.stepIndex,stepCount:a.steps.length,currentStepMeta:t?nd(a,{withdrawableNowBalance:d,giftCardValueToCoins:u}):la,canGoBack:no(a),submitStatus:a.submitStatus,submitError:a.submitError,openWithdrawFlow:m,closeWithdrawFlow:h,resetWithdrawFlow:p,goNext:g,goBack:y,setDraft:b,submitStart:w,submitSuccess:C,submitEnd:j,submitFail:k}}
43,[a,d,u,m,h,p,g,y,b,w,C,j,k]);return(0,s.jsxs)(le.Provider,{value:N,children:[e,(0,s.jsx)(i5,{})]})}let ls=(r={openWithdrawFlow:()=>{},closeWithdrawFlow:()=>{},resetWithdrawFlow:()=>{},goNext:()=>{},goBack:()=>{},setDraft:()=>{},submitStart:()=>0,submitSuccess:()=>{},submitEnd:()=>{},submitFail:()=>{}},t=i4.steps[i4.stepIndex],a=!!i4.session,{isOpen:i4.isOpen,currentStep:t,steps:i4.steps,session:i4.session,draft:i4.draft,currentStepIndex:i4.stepIndex,stepCount:i4.steps.length,currentStepMeta:a?nd(i4,void 0):la,canGoBack:no(i4),submitStatus:i4.submitStatus,submitError:i4.submitError,...r});function ln(){return(0,O.useContext)(le)??ls}var li=e.i(626621);function ll(){return(0,s.jsx)("div",{className:"flex flex-wrap gap-[10px]",role:"status","aria-busy":"true",children:Array.from({length:6},(e,t)=>(0,s.jsx)(e9.Skeleton,{className:"h-[120px] w-[220px] min-w-[220px] rounded-[8px]"},t))})}function lo(e=[]){let t=function(){let{openWithdrawFlow:e}=ln();return(0,O.useCallback)(t=>{e(t)},[e])}();return(0,O.useCallback)(a=>{t(function(e,t){if(null!=e.withdrawPresentation)return e;let a=t.find(t=>t.legacyMethod.slug===e.method.slug);return a?{...e,withdrawPresentation:a.withdrawPresentation}:e}(a,e))},[t,e])}let lc=e=>"crypto"===e||"cryptoStakePreselected"===e,ld=e=>!!e.giftCards?.length,lu=[{kind:"static",id:"arcade",Component:tq},{kind:"static",id:"freeCashout",Component:function(){return(0,s.jsx)(aa,{show:!0})},isVisible:e=>e.showFreeCashout},{kind:"method",id:"mostPopular",Component:function({methods:e,presentation:t,successfulOffers:a,skeleton:r}){let{mobileMethodRow:n,methodGrid:i,cashoutBoosts:l}=t,o=(0,eJ.default)(),{withdrawableNowBalance:c}=(0,x.default)(),d=lo(e),{t:u}=(0,C.useTranslationTyped)("_cashout2024");if(0===e.length)return null;let m=(a?.length??0)>0,p=l?.mobileAnchorSlug??null,f=m&&!!l?.showAfterSection&&!(o&&null!=p);return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsxs)("div",{children:[(0,s.jsx)("p",{className:"m-0 mb-[16px] hidden text-[20px] font-bold md:block",children:u("mostPopular")}),(0,s.jsxs)("div",{className:(0,w.cn)("flex flex-wrap gap-0 pt-0 phoneMax:gap-[10px]",i.expandedTopPadding?"phoneMax:pt-[24px]":"phoneMax:pt-0"),children:[(0,s.jsx)(tY,{children:e.map(({legacyMethod:e})=>(0,s.jsx)(t3,{method:e,withdrawableNowBalance:c||0,onWithdrawClick:d,skeleton:r},e.slug))}),(0,s.jsx)(tZ,{children:(0,s.jsx)("div",{className:"flex w-full flex-col items-stretch gap-[24px]",children:e.map(({legacyMethod:e})=>{let[t]=e.bonus?.()||[0,to.BonusType.CUSTOM];return(0,s.jsxs)("div",{className:"contents",children:[m&&o&&p===e.slug&&(0,s.jsx)(t0,{offers:a}),(0,s.jsxs)("div",{children:[(0,s.jsxs)("div",{className:"mb-[10px] flex w-full items-center gap-[10px] md:w-fit",children:[(0,s.jsx)("p",{className:"m-0 text-[20px] font-bold text-white-50",children:(0,s.jsx)(tE.default,{giftCardCurrency:e?.giftCards?.[0]?.currency,badgeTextClassName:"text-[20px] font-bold",children:e.displayName})}),"bottomLabel"===n.bonusDisplay&&!!t&&(0,s.jsx)("p",{className:"m-0 text-[10px] text-primary-200",children:u("extraReward")}),"inlineTag"===n.bonusDisplay&&e.bonus&&(0,s.jsx)(tb.BonusTagDisplay,{bonus:e.bonus?.(),method:e})]}),ld(e)&&(0,s.jsx)(tQ,{trailingSpace:"24px",children:(0,s.jsx)(tD,{method:e,onWithdrawClick:d,skeleton:r},e.slug)}),!ld(e)&&(0,s.jsx)("div",{className:"w-full",children:(0,s.jsx)(tU,{method:e,withdrawableNowBalance:c||0,skeleton:r,onClick:()=>{d({method:e})}})})]}),e.slug===h.MethodSlug.PayPal&&(0,s.jsx)(tK.PortalTarget,{id:"arcade-case-mobile"})]},e.slug)})})})]})]}),f&&(0,s.jsx)(t0,{offers:a})]})},getMethods:e=>e.mostPopular.methods,getProps:e=>({successfulOffers:e.successfulOffers,presentation:e.sections.mostPopular.presentation})},{kind:"method",id:"moreOptions",Component:function({methods:e,skeleton:t}){let a=(0,j.useFeatureFlags)(e=>e.cashoutOffers),{withdrawableNowBalance:r}=(0,x.default)(),n=lo(e),{t:i}=(0,C.useTranslationTyped)("_cashout2024"),l=e.filter(({legacyMethod:e})=>lc(e.viewMode)).map(({legacyMethod:e})=>e),o=e.filter(({legacyMethod:e})=>!lc(e.viewMode)),{data:c}=(0,al.default)({slug:a?.offer},{enabled:!!a?.offer}),d=!!c&&c.status!==ar.OfferStatus.CREDITED&&c.canStart,u=l.length>0||d;return 0===e.length?null:(0,s.jsxs)("div",{className:"flex flex-col items-stretch gap-[24px] md:gap-[40px]",children:[(0,s.jsx)(tK.PortalTarget,{id:"arcade-case-desktop"}),u&&(0,s.jsxs)("div",{children:[(0,s.jsx)("div",{className:"flex items-center gap-[10px]",children:(0,s.jsx)("p",{className:"m-0 text-[20px] font-bold text-core-neutral-0",children:i("crypto")})}),(0,s.jsxs)("div",{className:"mt-[16px] flex flex-wrap gap-[10px]",children:[(0,s.jsxs)(tY,{children:[d&&c&&(0,s.jsx)(an,{offer:c,skeleton:t},c.id),l.map(e=>(0,s.jsx)(t3,{method:e,withdrawableNowBalance:r||0,onWithdrawClick:n,skeleton:t},e.slug))]}),(0,s.jsx)(tZ,{children:(0,s.jsx)(tQ,{trailingSpace:"24px",children:(0,s.jsx)(ai,{methods:l,offer:c,onWithdrawClick:n,skeleton:t})})})]})]}),o.map(({legacyMethod:e})=>(0,s.jsxs)("div",{children:[(0,s.jsxs)("div",{className:"flex items-center gap-[10px]",children:[(0,s.jsx)("p",{className:"m-0 text-[20px] font-bold text-core-neutral-0",children:(0,s.jsx)(tE.default,{giftCardCurrency:e?.giftCards?.[0]?.currency,badgeTextClassName:"text-[20px] font-bold",children:e.displayName})}),e.bonus&&(0,s.jsx)(tb.BonusTagDisplay,{bonus:e.bonus?.(),method:e})]}),(0,s.jsxs)("div",{className:"mt-[16px] flex flex-wrap gap-[10px]",children:[(0,s.jsx)(tY,{children:(0,s.jsx)(t3,{method:e,withdrawableNowBalance:r||0,onWithdrawClick:n,skeleton:t})}),(0,s.jsxs)(tZ,{children:[!!e.giftCards?.length&&(0,s.jsx)(tQ,{trailingSpace:"24px",children:(0,s.jsx)(tD,{method:e,onWithdrawClick:n,skeleton:t},e.slug)}),!e.giftCards?.length&&(0,s.jsx)("div",{className:"w-full",children:(0,s.jsx)(tU,{method:e,withdrawableNowBalance:r||0,skeleton:t,onClick:()=>n({method:e})})})]})]})]},e.displayName))]})},getMethods:e=>e.moreOptions.methods},{kind:"static",id:"loans",Component:ty}];function lm(e,{loading:t,ctx:a},r){if(t&&!r)return{rendered:"skeleton",loading:t,slugs:[]};let s=a.sections[e].methods.map(e=>e.legacyMethod.slug);return 0===s.length?{rendered:"empty",loading:t,slugs:s}:{rendered:t?"skeleton":"cards",loading:t,slugs:s}}function lh(){let{sections:e,skeletonSections:t,policyContext:a,isLoadingMostPopular:r,isLoadingMoreOptions:n}=function({enabled:e=!0}={}){let t=function({enabled:e=!0}={}){var t;let a=function({enabled:e}){let{country:t}=(0,aS.default)(),a=(0,tS.useCurrencyText)(),r=(0,j.useFeatureFlags)(e=>e.isKoreanGiftCardsEnabled),s=(0,j.useFeatureFlags)(e=>e.isKoreanGiftcardsV2Enabled),n=(0,j.useFeatureFlags)(e=>e.japaneseGiftCards),i=(0,j.useFeatureFlags)(e=>e.isRevolutUsCashoutEnabled),l=(0,rp.default)({enabled:e}),o=l.data,c=(0,O.useMemo)(()=>(0,re.getMethodOrder)(t,{isKoreanGiftCardsEnabled:r,isKoreanGiftcardsV2Enabled:s,isJapaneseGiftCardsEnabled:n?.enabled}),[t,r,s,n?.enabled]),d=(0,O.useCallback)(e=>(0,rx.filterGiftCardsForCountry)(e,t,n),[n,t]),u=(0,O.useCallback)((e,{settings:t}={})=>(0,re.isMethodTotallyUnavailable)({methodSlug:e,cashoutProviders:o,settings:t}
43),[o]),m=(0,O.useCallback)(e=>a({amount:e.value,originalCurrency:e.currency,targetCurrency:tF.Currency.COINS,autoConvertToCoins:!1}).rawValue,[a]);return{enabled:e,country:t,isRevolutUsCashoutEnabledFlag:!!i,cashoutProviders:o,cashoutProvidersFetched:!!(0,rl.isOfferingQueryReady)(l,e),methodOrder:c,checkIsMethodUnavailable:u,applyCountryFilter:d,getGiftCardCoinsValue:m}}({enabled:e}),r=function(e){let{t}=(0,C.useTranslationTyped)("_cashout-v2"),a=(0,j.useFeatureFlags)(e=>e.cashoutV2Settings),{enabled:r,country:s,applyCountryFilter:n,getGiftCardCoinsValue:i,cashoutProviders:l}=e,o=r&&!!a?.isTangoBackendEnabled,c=(0,rh.default)({providerName:R.WithdrawProvider.Tango,enabled:o}),d=r&&!!a?.isTremendousEnabled,u=(0,rh.default)({providerName:R.WithdrawProvider.Tremendous,enabled:d}),m=r&&"US"===s&&e.isRevolutUsCashoutEnabledFlag,p=(0,rh.default)({providerName:R.WithdrawProvider.RevolutUs,brand:R.GiftCardBrand.Ach,enabled:m}),x=r&&"JP"===s&&!!a?.isGifteeEnabled,f=(0,rh.default)({providerName:R.WithdrawProvider.Giftee,enabled:x,brand:R.GiftCardBrand.Giftee}),{isTangoUnavailable:g,isTangoUsUnavailable:y,isTremendousUnavailable:b,isGifteeUnavailable:v}={isTangoUnavailable:(0,re.checkIsProviderDisabled)({providerName:R.WithdrawProvider.Tango,cashoutProviders:l}),isTangoUsUnavailable:(0,re.checkIsProviderDisabled)({providerName:R.WithdrawProvider.TangoUs,cashoutProviders:l}),isTremendousUnavailable:(0,re.checkIsProviderDisabled)({providerName:R.WithdrawProvider.Tremendous,cashoutProviders:l}),isGifteeUnavailable:(0,re.checkIsProviderDisabled)({providerName:R.WithdrawProvider.Giftee,cashoutProviders:l})},w=(0,O.useMemo)(()=>(0,rm.default)(n(c.data),"brand"),[n,c.data]),k=(0,O.useMemo)(()=>Object.keys(w).map(e=>{let a=[R.GiftCardBrand.Paypal,R.GiftCardBrand.Venmo].includes(e);return(0,re.buildGiftCardMethod)({brand:e,giftCards:w[e],getGiftCardCoinsValue:i,fee:e===R.GiftCardBrand.Paypal?({giftCard:e}={})=>"number"!=typeof e?.userFee?[5,to.FeeType.PERCENTAGE]:[e.userFee,e.feeType===R.GiftCardFeeType.Fixed?to.FeeType.FIXED:to.FeeType.PERCENTAGE]:void 0,withdrawProvider:R.WithdrawProvider.Tango,isProviderUnavailable:!!(a?y:g),t})}),[w,g,i,y,t]),{tremendousGiftcardByBrand:N,tremendousGiftcardBrandsName:S}=(0,O.useMemo)(()=>{let e=(0,rm.default)(n(u.data),"brand");return{tremendousGiftcardByBrand:e,tremendousGiftcardBrandsName:Object.keys(e)}},[n,u.data]),F=(0,O.useMemo)(()=>Object.keys(N).map(e=>(0,re.buildGiftCardMethod)({brand:e,giftCards:N[e],getGiftCardCoinsValue:i,withdrawProvider:R.WithdrawProvider.Tremendous,isProviderUnavailable:!!b,t})),[i,N,b,t]);return{tangoGiftcardMethods:k,tremendousGiftcardMethods:F,tremendousGiftcardBrandsName:S,achMethod:(0,O.useMemo)(()=>{if(!p.data?.length)return null;let a=p.data,r=a[0].brand,s=a.map(e=>i(e)),n=Math.min(...s),l=Math.max(...s);return a.length&&a.some(e=>e.status===R.GiftCardStatus.Available)?{slug:a0.BrandToSlugMapping[r],displayName:(0,re.resolveMethodDisplayName)(r,t),primaryLogo:a0.BrandToLogoMapping[r],bg:a0.BrandToBackgroundMapping[r],color:a0.BrandToTextColorMapping[r],minimumCoinsAmount:n,maximumCoinsAmount:l,giftCards:(0,tW.default)(a,"value","asc"),fee:({giftCard:e}={})=>[e?.userFee??0,e?.feeType??to.FeeType.FIXED],viewMode:"default",withdrawProvider:R.WithdrawProvider.RevolutUs,isUnavailable:e.checkIsMethodUnavailable(h.MethodSlug.BankTransfer,{settings:{isRevolutUsCashoutEnabled:e.isRevolutUsCashoutEnabledFlag}})}:null},[p.data,i,e,t]),gifteeMethod:(0,O.useMemo)(()=>{if(!x||"JP"!==s||!f.data?.length)return null;let e=f.data,a=e[0].brand,r=e.map(e=>i(e)),n=Math.min(...r),l=Math.max(...r),o=e.some(e=>e.status===R.GiftCardStatus.Available);return o?{slug:a0.BrandToSlugMapping[a],displayName:(0,re.resolveMethodDisplayName)(a,t),primaryLogo:a0.BrandToLogoMapping[a],bg:a0.BrandToBackgroundMapping[a],minimumCoinsAmount:n,maximumCoinsAmount:l,giftCards:(0,tW.default)(e,"value","asc"),fee:({giftCard:e}={})=>[e?.userFee??0,e?.feeType??to.FeeType.FIXED],viewMode:"default",withdrawProvider:R.WithdrawProvider.Giftee,isUnavailable:v||!o}:null},[s,i,f.data,x,v,t]),isTangoUnavailable:g,isTangoUsUnavailable:y,isTremendousUnavailable:b,isTangoEnabled:o,isTremendousEnabled:d,isRevolutUsCashoutEnabled:!!m,isGifteeEnabled:x,isGifteeUnavailable:v,tangoFetched:(0,rl.isOfferingQueryReady)(c,o),tremendousFetched:(0,rl.isOfferingQueryReady)(u,d),revolutUsAchFetched:(0,rl.isOfferingQueryReady)(p,!!m),gifteeFetched:(0,rl.isOfferingQueryReady)(f,x)}}(a),s=function({shared:e,giftCards:t}){let a=(0,j.useFeatureFlags)(e=>e.cashoutV2Settings),r=(0,j.useFeatureFlags)(e=>e.revolutCardCashoutSettings),s=(0,j.useFeatureFlags)(e=>e.cashoutFeePayload),n=(0,j.useFeatureFlags)(e=>e.revolutCashoutSettings),{stakeBonus:i,stakeUSBonus:l}=(0,k.useStakeBonus)(),{hasRevolutWithdrawal:o}
43=(0,eR.useWithdrawMethodConfig)(),{enabled:c,country:d,checkIsMethodUnavailable:u,getGiftCardCoinsValue:m}=e,p=(0,h.getRevolutMethod)(d),x=c&&!!a?.isStashEnabled,f=(0,rs.default)({providerName:R.WithdrawProvider.RevolutUs,withdrawType:R.WithdrawType.Stash,enabled:x}),g=c&&!!a?.isStakeComEnabled,y=(0,ri.default)({enabled:g}),b=y.data,v=c&&r?.enable===!0,w=(0,rn.default)({enabled:v,country:d,getGiftCardCoinsValue:m,isUnavailable:u(h.MethodSlug.Revolut,{settings:{isRevolutUsCashoutEnabled:e.isRevolutUsCashoutEnabledFlag}})}),C=(0,O.useMemo)(()=>({slug:h.MethodSlug.Stash,displayName:h.Stash,primaryLogo:rr.CASHOUT_METHOD_LOGOS.stash,bg:"#0C1620",minimumCoinsAmount:0,maximumCoinsAmount:(0,rt.usdToCoins)(1e3),fee:()=>[0,to.FeeType.FIXED],bonus:()=>[(0,a9.stashBonusUsd)(f?.data?.countByWithdrawalFilter??0),to.BonusType.FIXED_BONUS],viewMode:"default",isUnavailable:u(h.MethodSlug.Stash)}),[u,f?.data?.countByWithdrawalFilter]),N="US"===d?R.GiftCardBrand.Ach:R.GiftCardBrand.Iban,S=(0,ep.getWithdrawCurrency)(h.Revolut,d),F=(0,O.useMemo)(()=>({slug:h.MethodSlug.Revolut,displayName:h.Revolut,primaryLogo:rr.CASHOUT_METHOD_LOGOS.revolut,bg:"white",minimumCoinsAmount:(0,rt.usdToCoins)(5),maximumCoinsAmount:(0,rt.usdToCoins)(1e3),fee:({amount:e}={})=>{let t=(0,ra.resolveUserFacingFee)(s,{brand:N,currency:S,country:d,value:e??0});return t?[t.value,t.feeType]:[0,to.FeeType.FIXED]},bonus:()=>o||n?.enableFaucet||!p.bonus?[0,to.BonusType.FIXED_BONUS]:[p.bonus,to.BonusType.FIXED_BONUS],viewMode:"default",isUnavailable:u(h.MethodSlug.Revolut)}),[s,N,S,d,o,n?.enableFaucet,p.bonus,u]),T=(0,O.useMemo)(()=>({slug:h.MethodSlug.Stake,displayName:h.Stake,primaryLogo:rr.CASHOUT_METHOD_LOGOS.stake,bg:"radial-gradient(70.71% 70.71% at 50% 50%, #3E515E 0%, #202C34 100%)",minimumCoinsAmount:(0,re.getMinimumStakeWithdrawAmount)(b?.currencies),maximumCoinsAmount:(0,rt.usdToCoins)(1e3),fee:()=>[0,to.FeeType.FIXED],bonus:()=>[Number(i),to.BonusType.PERCENTAGE_BONUS],viewMode:"default",isUnavailable:u(h.MethodSlug.Stake),withdrawProvider:R.WithdrawProvider.Stake}),[b?.currencies,i,u]),E=(0,O.useMemo)(()=>({slug:h.MethodSlug.StakeUS,displayName:h.Stake,primaryLogo:rr.CASHOUT_METHOD_LOGOS.stake,bg:"radial-gradient(70.71% 70.71% at 50% 50%, #3E515E 0%, #202C34 100%)",minimumCoinsAmount:(0,re.getMinimumStakeWithdrawAmount)(b?.currencies),maximumCoinsAmount:(0,rt.usdToCoins)(1e3),fee:()=>[0,to.FeeType.FIXED],bonus:()=>[Number(l),to.BonusType.PERCENTAGE_BONUS],viewMode:"default",isUnavailable:u(h.MethodSlug.StakeUS),withdrawProvider:R.WithdrawProvider.StakeUs}),[b?.currencies,l,u]);return{directMethods:(0,O.useMemo)(()=>({stash:C,revolut:F,stake:T,stakeUs:E,ach:t.achMethod,giftee:t.gifteeMethod,revolutCardGiftCards:w}),[C,F,T,E,t.achMethod,t.gifteeMethod,w]),isStashFeatureEnabled:x,isStakeComFeatureEnabled:g,isRevolutCardCashoutEnabled:v,stashFetched:(0,rl.isOfferingQueryReady)(f,x),stakeComFetched:(0,rl.isOfferingQueryReady)(y,g),revolutCardFetched:w.isFetched}}({shared:a,giftCards:r}),n=function({enabled:e,checkIsMethodUnavailable:t}){let a=(0,j.useFeatureFlags)(e=>e.cashoutV2Settings),r=(0,j.useFeatureFlags)(e=>e.isCryptoV2CashoutEnabled),s=e&&!!a?.isStakeComEnabled,n=function({enabled:e=!0}={}){let{isLoggedIn:t}=(0,rc.default)();return(0,q.useQuery)({queryKey:(0,rd.buildCryptoCoinsQueryKey)(),queryFn:()=>K.default.cashout.getCryptoCoins(),enabled:e&&t,...ru.offeringQueryRefetchOptions,select:e=>e.data?.getCryptoCoins})}({enabled:e&&!!r}),i=function({enabled:e=!0}={}){let{isLoggedIn:t}=(0,rc.default)();return(0,q.useQuery)({queryKey:(0,rd.buildCryptoRatesQueryKey)(),queryFn:()=>K.default.cashout.getCryptoRates(),enabled:e&&t,...ru.offeringQueryRefetchOptions,select:e=>e.data?.getCryptoRates})}({enabled:e}),l=(0,ri.default)({enabled:s});return{cryptoMethods:(0,O.useMemo)(()=>(function({cryptoRatesData:e,withdrawMinimums:t,cryptoCoinItems:a,checkIsMethodUnavailable:r}){let s={slug:h.MethodSlug.Bitcoin,displayName:h.Bitcoin,primaryLogo:rr.CASHOUT_METHOD_LOGOS.bitcoin,bg:"linear-gradient(180deg, #F9AA4B 0%, #F7931A 99.99%)",minimumCoinsAmount:e.bitcoin?.minimumCashoutAmount??(0,u.getCryptoMinimumWithdraw)(h.Bitcoin,t,!1),maximumCoinsAmount:(0,rt.usdToCoins)(1e3),fee:()=>[e?.bitcoin?.coinFee??0,to.FeeType.FIXED],platformFee:()=>[e?.bitcoin?.platformFee??0,to.FeeType.PERCENTAGE],bonus:()=>[0,to.BonusType.PERCENTAGE_BONUS],viewMode:"crypto",isUnavailable:r(h.MethodSlug.Bitcoin)},n={slug:h.MethodSlug.Litecoin,displayName:h.Litecoin,primaryLogo:rr.CASHOUT_METHOD_LOGOS.litec
43oin,bg:"linear-gradient(180deg, var(--color-core-greyBlue-25-A70) 0%, var(--color-highlight-grey-25-A70) 100%)",minimumCoinsAmount:e.litecoin?.minimumCashoutAmount??(0,u.getCryptoMinimumWithdraw)(h.Litecoin,t,!1),maximumCoinsAmount:(0,rt.usdToCoins)(1e3),fee:()=>[e?.litecoin?.coinFee??0,to.FeeType.FIXED],platformFee:()=>[e?.litecoin?.platformFee??0,to.FeeType.PERCENTAGE],bonus:()=>[0,to.BonusType.PERCENTAGE_BONUS],viewMode:"crypto",isUnavailable:r(h.MethodSlug.Litecoin)},i={slug:h.MethodSlug.Dogecoin,displayName:h.Dogecoin,primaryLogo:rr.CASHOUT_METHOD_LOGOS.dogecoin,bg:"linear-gradient(180deg, var(--color-highlight-orange-200) 0%, var(--color-core-yellow-600) 100%)",minimumCoinsAmount:e.dogecoin?.minimumCashoutAmount??(0,u.getCryptoMinimumWithdraw)(h.Dogecoin,t,!1),maximumCoinsAmount:(0,rt.usdToCoins)(1e3),fee:()=>[e?.dogecoin?.coinFee??0,to.FeeType.FIXED],platformFee:()=>[e?.dogecoin?.platformFee??0,to.FeeType.PERCENTAGE],bonus:()=>[0,to.BonusType.PERCENTAGE_BONUS],viewMode:"crypto",isUnavailable:r(h.MethodSlug.Dogecoin)};if(a?.length){let e=(0,re.buildAllowedCryptoCoins)(a);R.Currencies.Doge in e&&(i.cryptoCoinId=e[R.Currencies.Doge].id),R.Currencies.Btc in e&&(s.cryptoCoinId=e[R.Currencies.Btc].id),R.Currencies.Ltc in e&&(n.cryptoCoinId=e[R.Currencies.Ltc].id)}return[s,n,i]})({cryptoRatesData:i.data??{},withdrawMinimums:ro.webConfig.withdraw.minimums,cryptoCoinItems:n.data?.items,checkIsMethodUnavailable:t}),[i.data,n.data?.items,t]),isFetched:function({enabled:e,isCryptoV2CashoutEnabled:t,isStakeComFeatureEnabled:a,cryptoCoinsQuery:r,cryptoRatesQuery:s,stakeComCashoutMetaQuery:n}){return!e||(0,rl.isOfferingQueryReady)(s,!0)&&(0,rl.isOfferingQueryReady)(r,t)&&(0,rl.isOfferingQueryReady)(n,a)}({enabled:e,isCryptoV2CashoutEnabled:!!r,isStakeComFeatureEnabled:s,cryptoCoinsQuery:n,cryptoRatesQuery:i,stakeComCashoutMetaQuery:l})}}({enabled:e,checkIsMethodUnavailable:a.checkIsMethodUnavailable}),i=!(t={enabled:e,isTangoEnabled:r.isTangoEnabled,tangoFetched:r.tangoFetched,isTremendousEnabled:r.isTremendousEnabled,tremendousFetched:r.tremendousFetched,isRevolutUsCashoutEnabled:r.isRevolutUsCashoutEnabled,revolutUsAchFetched:r.revolutUsAchFetched,isStashEnabled:s.isStashFeatureEnabled,stashFetched:s.stashFetched,isGifteeEnabled:r.isGifteeEnabled,gifteeFetched:r.gifteeFetched,cashoutProvidersFetched:a.cashoutProvidersFetched,isStakeComEnabled:s.isStakeComFeatureEnabled,stakeComFetched:s.stakeComFetched,isRevolutCardEnabled:s.isRevolutCardCashoutEnabled,revolutCardFetched:s.revolutCardFetched}).enabled||(0,a7.isOfferingProvidersFetched)({isTangoEnabled:t.isTangoEnabled,tangoFetched:t.tangoFetched,isTremendousEnabled:t.isTremendousEnabled,tremendousFetched:t.tremendousFetched,isRevolutUsCashoutEnabled:t.isRevolutUsCashoutEnabled,revolutUsAchFetched:t.revolutUsAchFetched,isStashEnabled:t.isStashEnabled,stashFetched:t.stashFetched,isGifteeEnabled:t.isGifteeEnabled,gifteeFetched:t.gifteeFetched,isCashoutProvidersEnabled:t.enabled,cashoutProvidersFetched:t.cashoutProvidersFetched,isStakeComEnabled:t.isStakeComEnabled,stakeComFetched:t.stakeComFetched,isRevolutCardEnabled:t.isRevolutCardEnabled,revolutCardFetched:t.revolutCardFetched}),l=!e||n.isFetched,o=i&&l,c=(0,O.useMemo)(()=>({...function({tangoGiftcardMethods:e,tremendousGiftcardMethods:t,tremendousGiftcardBrandsName:a,directMethods:r,methodOrder:s,isFetched:n,isTangoUnavailable:i,isTangoUsUnavailable:l,isTremendousUnavailable:o,cryptoMethods:c=[]}){let d=new Map;for(let t of e){let e=t.slug===h.MethodSlug.PayPal||t.slug===h.MethodSlug.Venmo;a4(d,a5(t,R.WithdrawProvider.Tango,e?l:i))}for(let e of t)a4(d,a5(e,R.WithdrawProvider.Tremendous,o));for(let e of(r.ach&&a4(d,a5(r.ach,R.WithdrawProvider.RevolutUs)),r.giftee&&a4(d,a5(r.giftee,R.WithdrawProvider.Giftee)),r.revolutCardGiftCards.iban&&a4(d,a5(r.revolutCardGiftCards.iban,R.WithdrawProvider.Revolut)),r.revolutCardGiftCards.swift&&a4(d,a5(r.revolutCardGiftCards.swift,R.WithdrawProvider.Revolut)),a4(d,a5(r.stash,R.WithdrawProvider.Stash)),a4(d,a5(r.revolut,R.WithdrawProvider.Revolut)),a4(d,a5(r.stake,R.WithdrawProvider.Stake)),a4
43(d,a5(r.stakeUs,R.WithdrawProvider.StakeUs)),c))for(let t of a0.brandToProviderMapping[e.slug]??(0,aU.getCatalogEntry)(e.slug)?.fulfillableBy??[R.WithdrawProvider.Fireblocks])a4(d,a5(e,t));return{offerings:d,directMethods:r,tremendousGiftcardBrandsName:a,methodOrder:s,isFetched:n}}({tangoGiftcardMethods:r.tangoGiftcardMethods,tremendousGiftcardMethods:r.tremendousGiftcardMethods,tremendousGiftcardBrandsName:r.tremendousGiftcardBrandsName,directMethods:s.directMethods,methodOrder:a.methodOrder,isFetched:o,isTangoUnavailable:r.isTangoUnavailable,isTangoUsUnavailable:r.isTangoUsUnavailable,isTremendousUnavailable:r.isTremendousUnavailable,cryptoMethods:l?n.cryptoMethods:[]}),isCoreFetched:i,isCryptoFetched:l,isFetched:o}),[r.tangoGiftcardMethods,r.tremendousGiftcardMethods,r.tremendousGiftcardBrandsName,r.isTangoUnavailable,r.isTangoUsUnavailable,r.isTremendousUnavailable,s.directMethods,a.methodOrder,i,l,o,n.cryptoMethods]),d=(0,O.useMemo)(()=>({tangoGiftCardsBrandsByStatus:[...c.offerings.values()].flat().filter(e=>e.provider===R.WithdrawProvider.Tango).reduce((e,t)=>("unavailable"===t.availability||"providerDisabled"===t.availability||t.giftCards?.every(e=>e.status===R.GiftCardStatus.Unavailable)?e.unavailable.push(t.methodId):e.available.push(t.methodId),e),{available:[],unavailable:[]}),tremendousAvailableSlugs:a8(c.offerings,R.WithdrawProvider.Tremendous),revolutUsAvailableSlugs:a8(c.offerings,R.WithdrawProvider.RevolutUs)}),[c.offerings]),m=(0,rf.useProviderPriorityDecision)({enabled:e&&i,availability:{tangoAvailableSlugs:d.tangoGiftCardsBrandsByStatus.available,tremendousAvailableSlugs:d.tremendousAvailableSlugs,revolutUsAvailableSlugs:d.revolutUsAvailableSlugs}}),p=(0,O.useMemo)(()=>({...d,providerExclusions:m.decision,isTangoUnavailable:r.isTangoUnavailable,isTremendousUnavailable:r.isTremendousUnavailable}),[d,m.decision,r.isTangoUnavailable,r.isTremendousUnavailable]);return(0,O.useMemo)(()=>({...c,isCoreFetched:c.isCoreFetched&&m.isFetched,isFetched:c.isFetched&&m.isFetched,facts:p,provisional:{...c,facts:{...p,providerExclusions:a6.EMPTY_PROVIDER_PRIORITY_DECISION}}}),[c,p,m.isFetched])}({enabled:e}),{country:a}=(0,aS.default)(),r=(0,j.useFeatureFlags)(e=>e.cashoutV2Settings),s=(0,j.useFeatureFlags)(e=>e.isTangoVenmoGiftCardsEnabled),n=(0,j.useFeatureFlags)(e=>e.revolutCashoutSettings),i=(0,j.useFeatureFlags)(e=>e.isKoreanGiftCardsEnabled),l=(0,j.useFeatureFlags)(e=>e.isKoreanGiftcardsV2Enabled),o=(0,j.useFeatureFlags)(e=>e.japaneseGiftCards),c=(0,j.useFeatureFlags)(e=>e.isCryptoV2CashoutEnabled),d=(0,j.useFeatureFlags)(e=>e.cashoutBoostsSection),{hasRevolutWithdrawal:m}=(0,eR.useWithdrawMethodConfig)(),{isIosAppWebView:p}=(0,eO.useIosAppV2UiMode)(),x=(0,aA.isIosApp)()||(0,aA.isNewIosApp)()||p,f=(0,L.useIsStakeCashoutEnabled)(),g=(0,j.useFeatureFlags)(e=>e.isStakeUSEnabled),y=(0,O.useMemo)(()=>({country:a??"",cashoutV2Settings:r,isTangoVenmoGiftCardsEnabled:s,revolutCashoutEnabled:n?.enable,isKoreanGiftCardsEnabled:i,isKoreanGiftcardsV2Enabled:l,isJapaneseGiftCardsEnabled:o?.enabled,hasRevolutWithdrawal:m,isStakeEnabled:f,isStakeUSEnabled:g,isCryptoV2CashoutEnabled:c,isIosAppUser:x,isIosAppWebView:p,cashoutBoostsSection:d?{enabled:d.enabled,variant:d.variant}:void 0}),[a,r,s,n?.enable,m,f,g,c,x,p,i,l,o?.enabled,d]),b=(0,O.useMemo)(()=>aI({...y,offeringResult:t}),[y,t]),v=(0,O.useMemo)(()=>aI({...y,offeringResult:t.provisional}),[y,t.provisional]),w=(0,O.useMemo)(()=>e?a3(b):{sections:{mostPopular:aX("mostPopular"),moreOptions:aX("moreOptions")},discoveredSlugCount:0,prioritizedSlugCount:0,discoveredSlugs:[],prioritizedSlugs:[],giftCardBrandCount:0,providersUnavailable:!1,giftBackendsEnabled:!1},[e,b]),{sections:N}=w,S=N.mostPopular.methods.length,F=N.moreOptions.methods.length,T=(0,O.useMemo)(()=>e?a3(v).sections:N,[e,v,N]),E=(a??"")==="JP"&&!!o?.enabled&&!o?.displayedGiftcards?.length,A=(0,rg.classifyEmptyOfferingCause)({totalCount:S+F,discoveredSlugCount:w.discoveredSlugCount,prioritizedSlugCount:w.prioritizedSlugCount,giftCardBrandCount:w.giftCardBrandCount,isIosAppUser:x,giftBackendsEnabled:w.giftBackendsEnabled,providersUnavailable:w.providersUnavailable,jpWhitelistEmpty:E}),M=e&&!t.isFetched;return(0,ry.useReportCashoutOfferingAnomalies)({enabled:e,isLoading:M,offeringPath:"Cashout V2",country:a??"",isIosAppUser:x,isIosAppWebView:p,emptyCause:A,giftCardBrandCount:w.giftCardBrandCount,slugs:{discovered:w.discoveredSlugs,prioritized:w.prioritizedSlugs,mostPopular:N.mostPopular.methods.map(e=>e.legacyMethod.slug),moreOptions:N.moreOptions.methods.map(e=>e.legacyMethod.slug),methodOrder:t.methodOrder}}),{sections:N,skeletonSections:T,policyContext:b,isLoading:M,isLoadingMostPopular:e&&!t.isCoreFetched,isLoadingMoreOptions:e&&!t.isFetched}}(),{successfulOffers:i}=ak(),l=(0,j.useFeatureFlags)(e=>e.revolutCashoutSettings),{showSkeleton:o,animation:c}=(0,li.useCashoutSkeleton)(),d="none"!==c,m=!!(l?.enableFaucet&&l?.faucet?.coins&&l?.faucet?.currency),p=(0,O.useMemo)(()=>({sections:e,successfulOffers:i,showFreeCashout:m}),[e,i,m]),x=(0,O.useMemo)(()=>({sections:t,successfulOffers:[],showFreeCashout:m}),[t,m]),f=(0,O.useMemo)(()=>{let e=e=>{let t=e||o;return{loading:t,ctx:t?x:p}};return{mostPopular:e(r),moreOptions:e(n)}},[r,n,o,x,p]);return(0,aN.useRecordOfferingRender)({mostPopular:lm("mostPopular",f.mostPopular,d),moreOptions:lm("moreOptions",f.moreOptions,d)}),(0,s.jsx)(lr,{policyContext:a,children:(0,s.jsx)("div",{className:"flex flex-col items-stretch gap-[24px] md:gap-[40px]",children:lu.map(e=>{if("static"===e.kind){if(e.isVisible&&!e.isVisible(p))return null;let t=e.Component;return t?(0,s.jsx)(t,{},e.id):null}let{loading:t,ctx:a}=f[e.id];if(t&&!d)return(0,s.jsx)(ll,{}
43,`${e.id}-loading`);let r=e.getMethods(a.sections);if(0===r.length)return null;let n=t?{"aria-busy":!0,"aria-live":"polite"}:void 0;if("mostPopular"===e.id){let i=e.getProps(a),l=e.Component;return(0,s.jsx)("div",{...n,children:(0,s.jsx)(l,{methods:r,presentation:i.presentation,successfulOffers:i.successfulOffers,skeleton:t})},e.id)}let i=e.Component;return(0,s.jsx)("div",{...n,children:(0,s.jsx)(i,{methods:r,skeleton:t})},e.id)})})})}let lp=({isSurveyLite:e})=>{let t=(0,j.useFeatureFlags)(e=>e.cashoutRedesignSettings),a=!!t?.enabled,r=a&&t?.redesignPhase===tR.CashoutRedesignPhase.PHASE_2;return(0,s.jsxs)("div",{className:"font-poppins w-full overflow-hidden",style:a?void 0:{minHeight:"calc(100vh - var(--header-height))"},children:[!a&&(0,s.jsx)(tr,{}),(0,s.jsx)("div",{className:`flex flex-col items-stretch gap-[24px] md:gap-[40px] ${a?"p-[8px_16px_24px] md:p-[0px_24px_40px] bg-transparent":"p-[24px_16px] md:p-[40px_24px] bg-core-greyBlue-900"}`,style:{paddingBottom:"40px"},children:r?(0,s.jsx)(lh,{}):(0,s.jsx)(a_,{isSurveyLite:e})}),(0,s.jsx)(eP,{})]})};function lx({item:e}){let{isNonUSD:t,addCurrencySymbol:a}=(0,ep.default)(h.Revolut),{country:r}=(0,aS.default)(),{t:n}=(0,C.useTranslationTyped)("_cashout");return(0,s.jsxs)("div",{className:"p-[16px] md:p-[24px] bg-core-greyBlue-700 rounded-[12px] col-span-2",children:[(0,s.jsx)("div",{className:"flex items-center",children:(0,s.jsx)("svg",{width:"25",height:"24",viewBox:"0 0 25 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,s.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M12.98 3C8.00942 3 3.97998 7.02944 3.97998 12C3.97998 16.9706 8.00942 21 12.98 21C17.9505 21 21.98 16.9706 21.98 12C21.98 7.02944 17.9505 3 12.98 3ZM1.97998 12C1.97998 5.92487 6.90485 1 12.98 1C19.0551 1 23.98 5.92487 23.98 12C23.98 18.0751 19.0551 23 12.98 23C6.90485 23 1.97998 18.0751 1.97998 12ZM12.98 11C13.5323 11 13.98 11.4477 13.98 12V16C13.98 16.5523 13.5323 17 12.98 17C12.4277 17 11.98 16.5523 11.98 16V12C11.98 11.4477 12.4277 11 12.98 11ZM12.98 7C12.4277 7 11.98 7.44772 11.98 8C11.98 8.55228 12.4277 9 12.98 9H12.99C13.5423 9 13.99 8.55228 13.99 8C13.99 7.44772 13.5423 7 12.99 7H12.98Z",fill:"core.freecashGreen.500"})})}),(0,s.jsx)("p",{className:"m-0 text-sm font-normal text-core-greyBlue-50",children:(0,s.jsx)(Z.Trans,{t:n,i18nKey:"promotionTextV2",values:{methodName:e.name,amount:a(e.bonus,0)},components:[(0,s.jsx)("a",{target:"_blank",rel:"noopener noreferrer",className:"text-core-freecashGreen-500 underline",onClick:e=>{(0,eh.onRevoluteExternalLinkClick)(e,t?r:void 0)}},"revolut-link")]})}),"AU"===r&&(0,s.jsx)("p",{className:"m-0 text-sm font-normal text-core-greyBlue-50",children:(0,s.jsx)(Z.Trans,{t:n,i18nKey:"withdraw.revolut.promoCard.auSpecialPromo",components:{b:(0,s.jsx)("span",{className:"font-bold"})}})})]})}var lf=e.i(447869);function lg(){let{variant:e,currentStep:t,registerCoinReward:a,stakeRewardCoins:r,freecashRewardCoins:i,depositCoinReward:l,registerPromoOfferLink:o,depositPromoOfferLink:c}=(0,lf.useStakePromotionStep)(),{t:d}=(0,p.default)("_cashout"),{format:u}=(0,ex.default)();return(0,s.jsxs)("div",{className:"p-[16px] md:p-[24px] bg-core-greyBlue-700 rounded-[12px] w-full h-full",children:[(0,s.jsxs)("div",{className:"flex items-center gap-4 mb-[10px]",children:[(0,s.jsx)("svg",{width:"32",height:"32",viewBox:"0 0 32 32",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,s.jsx)("path",{d:"M13.9362 6.57875C13.7014 6.3445 13.4113 6.17318 13.0927 6.0806C12.7742 5.98802 12.4375 5.97716 12.1136 6.04903C11.7898 6.12089 11.4893 6.27317 11.2398 6.49181C10.9903 6.71044 10.7999 6.98839 10.6862 7.3L4.12497 25.3475C4.01719 25.6451 3.98237 25.9642 4.02345 26.2781C4.06452 26.5919 4.18029 26.8914 4.36104 27.1512C4.54178 27.4111 4.78222 27.6238 5.06218 27.7715C5.34215 27.9191 5.65345 27.9975 5.96997 28C6.20302 27.9984 6.43399 27.9561 6.65247 27.875L24.6987 21.3125C25.0104 21.1989 25.2885 21.0086 25.5073 20.7592C25.726 20.5098 25.8785 20.2093 25.9505 19.8855C26.0224 19.5616 26.0117 19.2248 25.9192 18.9062C25.8267 18.5876 25.6554 18.2975 25.4212 18.0625L13.9362 6.57875ZM12.895 23.48L8.51997 19.105L10.165 14.5787L17.4212 21.835L12.895 23.48ZM6.01997 25.98L7.76997 21.1787L10.8262 24.235L6.01997 25.98ZM19.5 21.08L10.92 12.5L12.545 8.01625L23.9737 19.445L19.5 21.08ZM20 9C20.0188 8.32396 20.1824 7.65983 20.48 7.0525C21.1425 5.72875 22.3925 5 24 5C24.8375 5 25.375 4.71375 25.7062 4.09875C25.8806 3.75468 25.9807 3.37777 26 2.9925C26.001 2.72728 26.1073 2.47332 26.2955 2.28649C26.4838 2.09966 26.7385 1.99526 27.0037 1.99625C27.2689 1.99724 27.5229 2.10356 27.7097 2.29179C27.8966 2.48003 28.001 2.73478 28 3C28 4.6075 26.935 7 24 7C23.1625 7 22.625 7.28625 22.2937 7.90125C22.1193 8.24532 22.0192 8.62223 22 9.0075C21.9995 9.13882 21.9731 9.26876 21.9224 9.3899C21.8717 9.51103 21.7976 9.621 21.7044 9.71351C21.6112 9.80602 21.5007 9.87926 21.3792 9.92906C21.2577 9.97886 21.1275 10.0042 20.9962 10.0037C20.8649 10.0033 20.735 9.9769 20.6138 9.92619C20.4927 9.87548 20.3827 9.80141 20.2902 9.70821C20.1977 9.615 20.1245 9.50448 20.0747 9.38297C20.0249 9.26145 19.9995 9.13132 20 9ZM17 5V2C17 1.73478 17.1053 1.48043 17.2929 1.29289C17.4804 1.10536 17.7348 1 18 1C18.2652 1 18.5195 1.10536 18.7071 1.29289C18.8946 1.48043 19 1.73478 19 2V5C19 5.26522 18.8946 5.51957 18.7071 5.70711C18.5195 5.89464 18.2652 6 18 6C17.7348 6 17.4804 5.89464 17.2929 5.70711C17.1053 5.51957 17 5.26522 17 5ZM29.7075 15.2925C29.8003 15.3854 29.8739 15.4957 29.9241 15.6171C29.9743 15.7384 30.0001 15.8685 30.0001 15.9998C30 16.1312 29.9741 16.2612 29.9238 16.3825C29.8735 16.5038 29.7998 16.614 29.7068 16.7069C29.6139 16.7997 29.5037 16.8733 29.3823 16.9235C29.2609 16.9737 29.1309 16.9995 28.9995 16.9995C28.8682 16.9994 28.7382 16.9735 28.6168 16.9232C28.4955 16.8729 28.3853 16.7992 28.2925 16.7062L2
436.2925 14.7063C26.1048 14.5186 25.9994 14.2641 25.9994 13.9987C25.9994 13.7334 26.1048 13.4789 26.2925 13.2913C26.4801 13.1036 26.7346 12.9982 27 12.9982C27.2653 12.9982 27.5198 13.1036 27.7075 13.2913L29.7075 15.2925ZM30.3162 9.94875L27.3162 10.9487C27.0646 11.0326 26.79 11.0131 26.5527 10.8945C26.3155 10.7759 26.1351 10.5679 26.0512 10.3162C25.9673 10.0646 25.9869 9.78999 26.1055 9.55276C26.2241 9.31552 26.4321 9.13513 26.6837 9.05125L29.6837 8.05125C29.9353 7.96738 30.21 7.98689 30.4472 8.10551C30.6844 8.22413 30.8648 8.43213 30.9487 8.68375C31.0326 8.93537 31.0131 9.21001 30.8945 9.44724C30.7758 9.68448 30.5678 9.86487 30.3162 9.94875Z",fill:(0,n.resolveColorToken)("core.freecashGreen.500")})}),(0,s.jsxs)("div",{children:[(0,s.jsxs)(eU.default,{as:"div",color:"core.freecashGreen.500",fontWeight:"bold",fontSize:"20px",children:[e===tf.CommonVariant.VARIANT_1&&(0,s.jsxs)(s.Fragment,{children:[t===lf.StakePromotionStep.Register&&d("stakeUs.promotionCard.title",{amount:u(a,!0,!1,!0)}),t===lf.StakePromotionStep.Other&&d("stakeUs.promotionCard.titleEarnUpTo",{amount:"$12,450"})]}),e===tf.CommonVariant.VARIANT_2&&(0,s.jsx)(s.Fragment,{children:t===lf.StakePromotionStep.Register?d("stakeUs.promotionCard.title",{amount:u(a,!0,!1,!0)}):d("stakeUs.promotionCard.titleEarnUpTo",{amount:"$12,470"})})]}),e===tf.CommonVariant.VARIANT_2&&t===lf.StakePromotionStep.Register&&i>0&&(0,s.jsx)(eU.default,{as:"div",color:"core.freecashGreen.500",fontSize:"12px",children:d("stakeUs.promotionCard.rewardBreakdownV2",{amount:u(r,!0,!1,!0),freeCashAmount:u(i,!0,!1,!0)})})]})]}),(0,s.jsxs)(eU.default,{as:"div",fontWeight:"400",fontSize:"14px",color:"core.greyBlue.50",children:[t===lf.StakePromotionStep.Register&&(0,s.jsx)(ej.Trans,{t:d,i18nKey:"_cashout:stakeUs.promotionCard.signupText",values:{amount:u(a,!0,!1,!0)},components:{em:(0,s.jsx)(eU.default,{as:"span",color:"core.neutral.0"}),regLink:(0,s.jsx)(W.default,{href:o})}}),t===lf.StakePromotionStep.Deposit&&e===tf.CommonVariant.VARIANT_1&&(0,s.jsx)(ej.Trans,{t:d,i18nKey:"_cashout:stakeUs.depositPromoCard.text",values:{amount:u(l,!0,!1,!0)},components:{emGreen:(0,s.jsx)(eU.default,{as:"span",color:"core.freecashGreen.500",whiteSpace:"nowrap"})}}),(t===lf.StakePromotionStep.Other||e===tf.CommonVariant.VARIANT_2&&t!==lf.StakePromotionStep.Register)&&(0,s.jsx)(ej.Trans,{t:d,i18nKey:"_cashout:stakeUs.promotionCard.levelUpText",components:{em:(0,s.jsx)(eU.default,{as:"span",color:"core.neutral.0"}),regLink:(0,s.jsx)(W.default,{href:c})}})]})]})}function ly(){let e=(0,eK.useAsyncPopup)(),{variant:t,currentStep:a,registerCoinReward:r,stakeRewardCoins:n,freecashRewardCoins:i,bonusOfferMaxCoins:l,depositCoinReward:o,registerPromoOfferLink:c,hasInFreecashRewards:d,slug:u,isStakeUsRelaunchEnabled:m}=(0,lf.useStakePromotionStep)(),{t:h}=(0,p.default)("_cashout"),x=(0,O.useMemo)(()=>a===lf.StakePromotionStep.Deposit?d?(0,s.jsx)(tn,{bonus:h("stakeUs.promotionCard.unlock",{amount:"$12,470"}),className:"m-auto w-fit whitespace-normal text-[10px] md:text-[12px]"}):(0,s.jsx)(tn,{bonus:(0,P.coinsToUsd)(o),type:"fixed",className:"m-auto w-fit whitespace-normal text-[12px] md:text-sm"}):a===lf.StakePromotionStep.Other?(0,s.jsx)(tn,{bonus:h("stakeUs.promotionCard.unlock",{amount:d?"$12,470":"$12,450"}),className:"m-auto w-fit whitespace-normal text-[10px] md:text-[12px]"}):(0,s.jsx)(tn,{bonus:(0,P.coinsToUsd)(r),type:"fixed",className:"m-auto w-fit whitespace-normal text-[12px] md:text-sm"}),[a,o,d,r,t]);return a===lf.StakePromotionStep.None?null:(0,s.jsxs)("div",{className:"grid gap-[12px] col-[span_3] grid-cols-[repeat(3,1fr)] md:grid-cols-[repeat(auto-fit,140px)]",children:[(0,s.jsx)("div",{className:"rounded-[12px] p-[16px_8px] md:p-[16px] h-full shadow-[0px_10px_15px_0px_var(--color-core-neutral-1000-A10)] relative flex-none md:hover:outline-solid md:hover:outline-1 md:hover:outline-core-freecashGreen-500",style:{background:"radial-gradient(70.71% 70.71% at 50% 50%, var(--color-core-blue-800) 0%, var(--color-core-blue-900) 100%)"},children:(0,s.jsx)(eC.default,{isClickable:!0,onClick:()=>{a===lf.StakePromotionStep.Register?e.trigger({name:eK.AllowedAsyncPopupName.STAKE_US_SIGNUP_V3,args:{offerLink:c,coinAmount:r,stakeRewardCoins:n,freecashRewardCoins:i,bonusOfferMaxCoins:l,isStakeUsRelaunchEnabled:m,variant:t}}):(0,tX.openOfferModal)({isLoggedIn:!0,slug:u,source:"cashout-page",offerPosition:0})},children:(0,s.jsxs)("div",{className:"text-center flex items-center justify-center flex-col w-full h-full gap-[12px] relative",children:[(0,s.jsx)("div",{className:"absolute top-0 left-0 right-0",children:x}),(0,s.jsx)("img",{className:"h-[42px] lg:h-[64px] object-contain max-w-full",src:"/img/cashout/legacy/stakeus.svg",alt:"Stake US logo"}),(0,s.jsxs)("div",{className:"absolute bottom-0",children:[(0,s.jsx)("span",{className:"m-0 leading-normal",children:"Stake US"}),(0,s.jsx)(ti,{})]})]})})}),(0,s.jsx)("div",{className:"flex-none h-full col-[span_2]",children:(0,s.jsx)(lg,{})})]})}function lb({promotionMethods:e}){let{t}=(0,p.default)("_cashout"),{isLoggedIn:a}=(0,z.default)(),{currentStep:r}=(0,lf.useStakePromotionStep)(),n=(0,O.useId)(),i=(0,j.useFeatureFlags)(e=>e.isStakePromotionEnabled);return(0,O.useMemo)(()=>!!(e.length>0)||r!==lf.StakePromotionStep.None&&!!i,[e,r,i])?(0,s.jsxs)("section",{className:"mb-[24px]","aria-labelledby":n,children:[(0,s.jsxs)("div",{className:"flex items-center",children:[(0,s.jsx)(at,{fill:"core.yellow.600"}),(0,s.jsx)("h2",{id:n,className:"m-0 ml-[8px] text-[20px] font-bold",children:t("cashoutBonuses")})]}),(0,s.jsxs)("div",{className:"grid grid-cols-[repeat(3,1fr)] md:grid-cols-[repeat(auto-fit,140px)] gap-[12px] justify-start mt-[16px]",children:[e.map(e=>(0,s.jsxs)("div",{className:"grid grid-cols-[repeat(3,1fr)] md:grid-cols-[repeat(auto-fit,140px)] gap-[12px] col-[span_3]",children:[(0,s.jsx)(tx,{isLoggedIn:a,...e,children:(0,s.jsx)(tm,{item:e})},e.name),e.name===h.Revolut&&(0,s.jsx)(lx,{item:e})]},e.name)),r!==lf.StakePromotionStep.None&&(0,s.jsx)(ly,{})]})]}):null}var lv=e.i(877957),lw=e.i(121713),lC=e.i(818211),lj=e.i(593881);function lk({name:e,value:t,checked:a,onChange:r,children:n,wrapperClassName:i}){return(0,s.jsxs)("label",{className:(0,w.cn)("relative flex cursor-pointer items-center","has-focus-visible:outline-solid has-focus-visible:outline-2 has-focus-visible:outline-offset-2 has-focus-visible:outline-core-freecashGreen-500",i),children:[(0,s.jsx)("input",{type:"radio",name:e,value:t,checked:a,onChange:()=>r(t),className:"sr-only"}),(0,s.jsx)("div",{className:(0,w.cn)("mr-[10px] flex h-[20px] w-[20px] items-center justify-center rounded-[10px] border border-solid bg-transparent",a?"border-core-freecashGreen-500":"border-core-neutral-0"),children:(0,s.jsx)("div",{className:(0,w.cn)("h-[14px] w-[14px] rounded-[9px] border border-solid border-transparent hover:bg-core-freecashGreen-500",a?"bg-core-freecashGreen-500":"bg-core-neutral-1000-A10")})}),n]})}function lN(e){let t=(0,O.useId)();return(0,s.jsx)("div",{className:"flex flex-col justify-around ga
43p-[10px] md:flex-row md:justify-start md:gap-[30px]",children:e.options.map(a=>(0,s.jsx)("div",{className:"flex gap-[10px]",children:(0,s.jsx)(lk,{name:t,value:a.value,checked:e.value===a.value,onChange:e.onChange,wrapperClassName:"flex",children:a.label})},a.value))})}function lS(){let{stakeCom:e,stakeUS:t}=function(){let e=(0,j.useFeatureFlags)(e=>e.stakeFaucetSettings),{isStakeComEnabled:t,isStakeUsEnabled:a,refetch:r,isLoading:s}=(0,lj.useStakeFaucetStatus)();return{...(0,O.useMemo)(()=>({stakeCom:{coinAmount:e?.[lC.STAKE_PROVIDER.COM]?.coinAmount||0,canClaim:t},stakeUS:{coinAmount:e?.[lC.STAKE_PROVIDER.US]?.coinAmount||0,canClaim:a}}),[e,t,a]),isStakeComEnabled:t,isStakeUsEnabled:a,refetch:r,isLoading:s}}(),{t:a}=(0,p.default)(["_cashout"]),[r,n]=(0,O.useState)(""),[i,l]=(0,O.useState)(null),o=i??function({stakeCom:e,stakeUS:t}){return e?.canClaim,t?.canClaim?R.StakeProvider.StakeUs:R.StakeProvider.StakeCom}({stakeCom:e,stakeUS:t}),{link:c}=(0,Y.useStakeOfferLink)({selectedProvider:o}),d=(0,lv.useStakeComFaucetMutation)(),u=(0,lw.useStakeUsFaucetMutation)(),m=o===R.StakeProvider.StakeCom?d.isPending:u.isPending,h=(0,j.useFeatureFlags)(e=>e.isStakeFaucetV2Enabled),x=e?.canClaim||t?.canClaim,f=(0,tS.useCurrencyText)(),{country:y}=(0,aS.default)(),{onWithdrawClick:v,showSignUpTrigger:w}=(0,rW.useRefineGetghostAccount)();(0,O.useEffect)(()=>{e?.canClaim&&tg.default.setUserProperties("User Interface Elements",{"StakeCom Faucet":!0}),t?.canClaim&&tg.default.setUserProperties("User Interface Elements",{"StakeUs Faucet":!0})},[e?.canClaim,t?.canClaim]);let C=(0,O.useMemo)(()=>x?e?.coinAmount&&o===R.StakeProvider.StakeCom?{amount:(0,rt.coinsToUsd)(e.coinAmount),coinAmount:e.coinAmount}:t?.coinAmount&&o===R.StakeProvider.StakeUs?{amount:(0,rt.coinsToUsd)(t.coinAmount),coinAmount:t.coinAmount}:null:null,[x,e,t,o]),k=f({amount:C?.coinAmount??0,targetCurrency:"USD",autoConvertToCoins:!1}).value;if(!h||!x||null===C||!(0,eR.shouldShowStake)(y||""))return null;let N=[];return e?.canClaim===!0&&N.push({label:(0,s.jsxs)("div",{className:"flex items-center gap-[5px]",children:[(0,s.jsx)("span",{className:"m-0 text-core-neutral-0",children:"Stake.com"}),(0,s.jsx)("img",{src:"/public/img/earn/global.svg",className:"w-[20px] h-[20px] ml-[10px]"})]}),value:R.StakeProvider.StakeCom.toString()}),t?.canClaim===!0&&N.push({label:(0,s.jsxs)("div",{className:"flex items-center gap-[5px]",children:[(0,s.jsx)("span",{className:"m-0 text-core-neutral-0",children:"Stake.US"}),(0,s.jsx)("img",{src:"/public/img/flags/round-flags/us.svg",className:"w-[20px] h-[20px] ml-[10px]"})]}),value:R.StakeProvider.StakeUs.toString()}),(0,s.jsxs)("div",{className:"overflow-hidden relative max-w-full md:max-w-[520px]",children:[(0,s.jsxs)("div",{className:"flex justify-between text-sm mb-[16px]",children:[(0,s.jsxs)("div",{className:"flex gap-[6px] items-center",children:[(0,s.jsx)("img",{className:"h-[18px] object-contain max-w-full",src:"/public/img/flame2.svg"}),(0,s.jsx)("p",{className:"m-0 font-bold",children:a("_cashout:stakeFaucet.flame",{usdAmount:k})})]}),(0,s.jsx)("p",{className:"m-0 p-[4px_8px] rounded-[4px] bg-[linear-gradient(125deg,#eb5c2c_0,#ff8e4f_100%)] text-xs font-semibold",children:a("_cashout:stakeFaucet.promo")})]}),(0,s.jsxs)("div",{className:"rounded-[12px] bg-core-blue-900 overflow-hidden",children:[(0,s.jsx)("div",{className:"flex justify-center items-center h-[42px]",children:(0,s.jsx)("img",{className:"h-[28px] max-w-full",src:"/img/cashout/legacy/stake.png"})}),(0,s.jsxs)("div",{className:"flex p-[12px_14px] flex-col gap-[16px] bg-core-greyBlue-700 items-start rounded-b-[12px] m-px",children:[N.length>1&&(0,s.jsx)("div",{className:"my-[10px]",children:(0,s.jsx)(lN,{options:N,value:o,onChange:e=>{l(e)}})}),(0,s.jsx)("p",{className:"m-0 text-core-greyBlue-50 text-[13px] font-medium",children:(0,s.jsx)(ej.Trans,{t:a,i18nKey:`_cashout:stakeFaucet.userNameDescription.${o===R.StakeProvider.StakeCom?"com":"us"}`,components:{em:(0,s.jsx)("span",{className:"m-0 font-bold text-core-freecashGreen-500"})},values:{usdAmount:k}})}),(0,s.jsxs)("div",{className:"flex flex-col md:flex-row gap-[10px] self-stretch",children:[(0,s.jsx)(b.default,{...I.textFieldStyle,className:"placeholder:text-sm placeholder:font-[400] placeholder:tracking-[-0.03em]",value:r,flexGrow:"1",placeholder:a(`_cashout:stakeFaucet.placeholder.${o===R.StakeProvider.StakeCom?"com":"us"}`)??"",onChange:e=>{n(e.target.value)}}),w?(0,s.jsx)(iK.default,{trigger:e=>(0,s.jsx)(g.Button,{variant:"primary",size:"lg",width:"full",onClick:e.onOpen,isDisabled:!r||m,children:a("_cashout:stakeFaucet.claimButton",{usdAmount:k})}),closeHandler:v}):(0,s.jsx)(g.Button,{variant:"primary",size:"lg",width:"full",onClick:()=>
43{if(r&&!m){if(o===R.StakeProvider.StakeCom)return d.mutate(r);if(o===R.StakeProvider.StakeUs)return u.mutate(r)}},isDisabled:!r||m,isLoading:m,children:a("_cashout:stakeFaucet.claimButton",{usdAmount:k})})]}),(0,s.jsx)("p",{className:"m-0 text-[11px] font-medium",children:(0,s.jsx)(ej.Trans,{t:a,i18nKey:`_cashout:stakeFaucet.openAccount.${o===R.StakeProvider.StakeCom?"com":"us"}`,components:{em:(0,s.jsx)("a",{href:c,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-[2px] text-core-freecashGreen-500 hover:underline"}),i:(0,s.jsx)(eQ.ExternalLinkIcon,{mx:"2px",mt:"-3px"})}})})]})]})]})}let lF=({selected:e,setSelected:t,flagSrc:a,stakePreference:r,stakeBonus:n})=>{let{t:i}=(0,p.default)("_cashout"),l=e===r;return(0,s.jsxs)("div",{className:(0,w.cn)("aspect-square relative rounded-[12px] flex-1 cursor-pointer flex flex-col items-center justify-center border border-solid",l?"border-core-freecashGreen-500":"border-core-greyBlue-200"),style:{background:"radial-gradient(70.71% 70.71% at 50% 50%, var(--color-core-blue-800) 0%, var(--color-core-blue-900) 100%)",boxShadow:"inset 0 0 10px var(--color-core-neutral-1000-A30)"},onClick:()=>t(r),children:[(0,s.jsx)("img",{src:a,className:"absolute top-[-12px] right-[-12px] block w-[48px] h-[48px] border-[5px] border-solid border-core-greyBlue-800 rounded-[99px]"}),(0,s.jsx)("img",{src:"/img/cashout/legacy/stake.png",className:"block w-[100px] h-auto mt-[-20px]"}),(0,s.jsx)("div",{className:"m-0 mt-[-15px]",children:r===R.StakeProvider.StakeUs?".us":".com"}),(n??0)>0&&(0,s.jsx)("div",{className:"bg-core-freecashGreen-900 absolute bottom-[12px] px-[12px] rounded-[4px]",children:(0,s.jsx)("span",{className:"m-0 text-core-freecashGreen-500 text-[16px] text-center capitalize",children:i("_cashout:withdraw.stake.bonus",{discount:n})})})]})};function lT(){let{t:e}=(0,p.default)("_cashout"),[t,a]=(0,O.useState)(void 0),[r,n]=(0,O.useState)(!1),[{showStakePreferenceModal:i},l]=(0,v.useRecoilState)(m.default),{stakeBonus:o,stakeUSBonus:c}=(0,k.useStakeBonus)(),{isFetched:d,stakeSettings:u,hasSetStakePreference:x,updateStakePreference:f}=Q(),y=!!i&&d&&!!u;return((0,eI.useAppOverlayEffects)(y),(0,O.useEffect)(()=>{d&&x&&r&&l(e=>({...e,selectedMethod:h.Stake,showStakePreferenceModal:!1}))},[x,r,d,l]),d&&u)?(0,s.jsx)(eM.Modal,{open:y,onClose:()=>{l(e=>({...e,showStakePreferenceModal:!1}))},title:e("stakeUs.modal.preference.title"),alignment:"centered",size:"md",surface:"raised",children:(0,s.jsxs)(eM.ModalBody,{children:[(0,s.jsx)("div",{className:"m-0 text-core-greyBlue-50 my-[12px]",children:e("stakeUs.modal.preference.description")}),(0,s.jsxs)("div",{className:"flex gap-[32px] my-[20px]",children:[(0,s.jsx)(lF,{selected:t,setSelected:a,flagSrc:"/public/img/flags/round-flags/us.svg",stakePreference:R.StakeProvider.StakeUs,stakeBonus:c}),(0,s.jsx)(lF,{selected:t,setSelected:a,flagSrc:"/public/img/earn/global.svg",stakePreference:R.StakeProvider.StakeCom,stakeBonus:o||0})]}),(0,s.jsx)(g.Button,{variant:"primary",size:"lg",width:"full",isDisabled:!t,onClick:()=>{t&&(f(t),n(!0))},children:e("stakeUs.modal.preference.cta")})]})}):null}function lE({serverIsIosAppWebView:e}={}){let{userInfo:t}=(0,tG.default)(),a=t?.isSurveyLiteUser,r=(0,j.useFeatureFlags)(e=>e.stakeFaucetQuestEnabled),l=(0,j.useFeatureFlags)(e=>e.cashoutRedesignSettings),o=!!l?.enabled,c=o&&l?.redesignPhase===tR.CashoutRedesignPhase.PHASE_2,d=(0,j.useFeatureFlags)(e=>e.revolutCashoutSettings),{hasRevolutWithdrawal:m,isRevolutCashoutEnabled:h}=(0,eR.useWithdrawMethodConfig)(),{country:p}=(0,aS.default)(),x=(0,$.useQueryClient)(),{isIosAppWebView:f,isIosModeForceEnabled:g}=(0,eO.useIosAppV2UiMode)(),y=!!(h&&!m&&!d?.enableFaucet),b=(0,u.getCashoutPromotionMethods)({shouldSeeRevolutBonus:y,countryHeader:p||""});return((0,O.useEffect)(()=>{x.invalidateQueries({queryKey:[i.QueryKeys.GRAPHQL_GET_USER_INFO]})},[x]),(e??f)||g)?(0,s.jsx)(lp,{isSurveyLite:a}):(0,s.jsxs)("div",{className:"font-poppins w-full overflow-hidden",style:{minHeight:o?void 0:"calc(100vh - var(--header-height))"},children:[!o&&(0,s.jsx)(tr,{}),(0,s.jsxs)("div",{className:(0,w.cn)("flex flex-col items-stretch gap-[24px] md:gap-[40px] px-[16px] md:px-[24px]",o?"pt-[8px] md:pt-0":"pt-[24px] md:pt-[40px]"),style:{paddingBottom:"40px",backgroundColor:o?"transparent":(0,n.resolveColorToken)("core.greyBlue.900")},children:[!r&&(0,s.jsx)(lS,{}),(0,s.jsx)(lb,{promotionMethods:b}),c?(0,s.jsx)(lh,{}):(0,s.jsx)(a_,{isSurveyLite:a})]}),(0,s.jsx)(eP,{}),(0,s.jsx)(lT,{})]})}var lA=e.i(202074),lR=e.i(488940);let lM=(0,v.atom)({key:"alert-atom",default:{banAlert:{isOpen:!1},freezeAlert:{isOpen:!1},verificationAlert:{isOpen:!1}}}),l_=({children:e,className:t,...a})=>{let{className:r,style:n,rest:i}=(0,te.splitChakraBoxProps)(a);return(0,s.jsx)("button",{type:"button",className:(0,w.cn)("inline-flex max-h-[26px] w-fit cursor-pointer items-center justify-center whitespace-nowrap rounded-[6px] border border-solid border-core-neutral-0 bg-core-neutral-1000-A10 px-4 py-[0.8em] text-[12px] font-semibold leading-[18px] tracking-[0.02em] text-core-neutral-0 focus-visible:shadow-outline md:max-h-[36px]",r,t),style:n,...i,children:(0,s.jsx)("span",{children:e})})},lI=({status:e="error",icon:t,children:a})=>{let[r,i]=(0,v.useRecoilState)(lM);return(0,s.jsxs)("div",{role:"alert",className:"relative flex w-full items-stretch gap-[14px] overflow-hidden p-[16px] md:items-center md:p-[16px_28px]",style:{background:"info"===e?(0,n.resolveColorToken)("core.blue.25-A10"):(0,n.resolveColorToken)("highlight.orange.25-A30"),border:`1px solid ${(e=>{switch(e){case"info":return(0,n.resolveColorToken)("core.blue.500");case"error":return(0,n.resolveColorToken)("highlight.orange.500");default:return(0,n.resolveColorToken)("core.red.600")}})(e)}`},children:[t&&(0,s.jsx)(lA.default,{width:20,height:20}),(0,s.jsx)("div",{className:"w-full font-medium leading-[21px] tracking-[0.02em]",children:a}),(0,s.jsx)(lR.default,{boxSize:"20px",stroke:"core.greyBlue.100",cursor:"pointer",marginLeft:"8px",right:"15px",top:"12px",onClick:()=>void("error"===e?i(e=>({...e,banAlert:{isOpen:!1}})):i(e=>({...e,freezeAlert:{isOpen:!1},verificationAlert:{isOpen:!1}})))})]})},lP="freeze",lB="tosBreach",lU=e=>"finalban"===e?"finalBanned":e===lP?"frozen":"banned",lO=e=>"tos-breach"===e?lB:"multi-accounts"===e?"multiAccount":"vpn-usage"===e?"vpnUsage":"vpn-likely"===e?"vpnLikely":"chargebacks"===e?"chargebacks":"failed-data-check"===e?"failedDataChecks":"data-check-mobile"===e?"dataCheckMobile":"data-check-wifi"===e?"dataCheckWifi":"phone-verification"===e?"phoneVerification":"final-ban"===e?"finalBan":lB;var lG=e.i(397930);let lL=({publicReason:e})=>{let{t}=(0,p.default)("_myprofile"),a=e?lO(e):null,r=lU("ban"),{openIntercomChat:n}=(0,lG.useIntercomChat)();return(0,s.jsx)(lI,{status:"error",children:(0,s.jsxs)("div",{className:"flex gap-[24px] items-start md:items-center justify-around relative flex-col md:flex-row",children:[(0,s.jsx)("span",{className:"m-0 text-sm font-medium leading-[18px] tracking-[0.02em] inline-[unset] md:inline-[73%]",children:a?(0,s.jsx)(ej.Trans,{t:t,i18nKey:`_myprofile:moderation.${a}`,values:{banTypeText:t(`moderation.${r}`)},components:{a:(0,s.jsx)(e3.default,{href:"#",className:"text-[length:inherit] underline",onClick:e=>{e.preventDefault(),n()}})}}):t("banners.banned.description")}),(0,s.jsx)("button",{type:"button",onClick:e=>{e.preventDefault(),n()},className:"inline-flex items-center justify-center appearance-none cursor-pointer border border-solid border-core-neutral-0 bg-transparent px-4 py-2 text-sm font-semibold text-core-neutral-0",children:(0,s.jsx)("span",{style:{display:"contents"},children:t("messageSupport")})})]})})},lD=()=>{let{data:e}=(0,tG.default)(),t=e?.data?.me,[{banAlert:a},r]=(0,v.useRecoilState)(lM);return(0,O.useEffect)(()=>{t?.bannedReason&&r(e=>({...e,banAlert:{isOpen:!0}}))},[t?.bannedReason,r]),(0,s.jsx)(s.Fragment,{children:a.isOpen&&t?.bannedReason?(0,s.jsx)("div",{className:"flex mt-[24px] w-full justify-center items-center",children:(0,s.jsx)("div",{className:"w-[97%] md:w-[70%]",children:(0,s.jsx)(lL,{publicReason:t?.bannedReason})})}):(0,s.jsx)(s.Fragment,{})})};var lV=e.i(410573);let lW=O.default.memo(({endDate:e})=>{let t=(0,O.useRef)(null),{minutes:a,seconds:r,hours:n,start:i,stop:l}=(0,lV.useCountdown)(()=>{t.current&&clearTimeout(t.current),t.current=setTimeout(()=>{l(),t.current=null},5e3)}),o=(0,O.useCallback)(e=>{i(e)},[i]);return(0,O.useEffect)(()=>{e&&o(new Date(e).getTime())},[e,o]),(0,O.useEffect)(()=>()=>{t.current&&clearTimeout(t.current)},[]),(0,s.jsx)("div",{className:"flex justify-center items-center gap-[6px] rounded-[4px]",children:(0,s.jsx)("div",{className:"flex items-baseline justify-center gap-[2px]",children:(0,s.jsxs)(eU.default,{as:"span",color:"core.gold.500",fontWeight:500,fontSize:"12px",children:[n,n?":":"",a,a?":":"",r]})})})}),lK=({idVerificationProvider:e,campaignApprovalExpiresAt:t,timedIdVerification:a})=>{let{t:r}=(0,p.default)("_myprofile"),{trigger:n}=(0,eK.useAsyncPopup)(),i=()=>{e===R.IdVerificationProvider.Verisoul?n({name:eK.AllowedAsyncPopupName.VERISOUL_VERIFICATION_MODAL}):window.dispatchEvent(new CustomEvent("fc:reactapp:show-veriff-verification-modal"))};return a&&t?(0,s.jsx)(lI,{status:"info",children:(0,s.jsxs)("div",{className:"flex gap-[10px] items-start md:items-center flex-col md:flex-row",children:[(0,s.jsxs)("div",{className:"flex flex-col gap-[24px]",children:[(0,s.jsx)("div",{className:"flex gap-[24px] items-start md:items-center justify-start relative flex-col md:flex-row",children:(0,s.jsx)("span",{className:"m-0 font-medium text-sm leading-[18px] tracking-[0.02em] inline-[unset] md:inline-[73%]",children:(0,s.jsx)(ej.Trans,{t:r,ns:"_myprofile",i18nKey:"banners.idVerification.descriptionV2",components:{em:(0,s.jsx)("strong",{})}})})}),(0,s.jsxs)("div",{className:"flex gap-[4px] flex-col md:flex-row items-start md:items-center",children:[(0,s.jsx)("span",{className:"m-0 font-medium text-sm text-core-neutral-0",children:r("timeRunning")}),(0,s.jsx)(lW,{endDate:t})]})]}),(0,s.jsx)(l_,{onClick:i,"data-provider":e,children:r("banners.idVerification.cta")})]})}):(0,s.jsx)(lI,{status:"info",children:(0,s.jsxs)("div",{className:"flex gap-[24px] items-start md:items-center justify-around relative flex-col md:flex-row",children:[(0,s.jsx)("span",{className:"m-0 font-medium text-sm leading-[18px] tracking-[0.02em] inline-[unset] md:inline-[73%]",children:(0,s.jsx)(ej.Trans,{t:r,ns:"_myprofile",i18nKey:"banners.idVerification.descriptionV2",components:{em:(0,s.jsx)("strong",{})}})}),(0,s.jsx)(l_,{onClick:i,"data-provider":e,children:r("banners.idVerification.cta")})]})})},lz=({publicReason:e})=>{let{t}=(0,p.default)("_myprofile"),a=e?lO(e):null,r=lU(lP),{openIntercomChat:n}=(0,lG.useIntercomChat)();return(0,s.jsx)(lI,{status:"info",children:(0,s.jsxs)("div",{className:"flex gap-[24px] items-start md:items-center justify-around relative flex-col md:flex-row",children:[(0,s.jsx)("span",{className:"m-0 font-medium text-sm leading-[18px] tracking-[0.02em] inline-[unset] md:inline-[73%]",children:a?(0,s.jsx)(ej.Trans,{t:t,i18nKey:`_myprofile:moderation.${a}`,values:{banTypeText:t(`moderation.${r}`)},components:{a:(0,s.jsx)(e3.default,{href:"#",className:"text-[length:inherit] underline",onClick:e=>{e.preventDefault(),n()}})}}):t("banners.phoneVerification.description")}),(0,s.jsx)("button",{type:"button",onClick:e=>{e.preventDefault(),n()},className:"inline-flex items-center justify-center appearance-none cursor-pointer border border-solid border-core-neutral-0 bg-transparent text-core-neutral-0 py-[8px] px-[16px] text-sm font-semibold",children:(0,s.jsx)("span",{style:{display:"contents"},children:t("messageSupport")})})]})})},lH=()=>{let{t:e}=(0,p.default)("_myprofile");return(0,s.jsx)(lI,{status:"info",children:(0,s.jsxs)("div",{className:"flex gap-[24px] items-start md:items-center justify-around relative flex-col md:flex-row",children:[(0,s.jsx)("span",{className:"m-0 font-medium text-sm leading-[18px] tracking-[0.02em] inline-[unset] md:inline-[73%]",children:e("banners.kycVerification.description","Hey there! 🙂 Before enabling withdrawals, we need you to verify your account. You can still do offers and otherwise use your account as usual. Please use the link below to complete the process. If you have any questions feel free to contact support.")}),(0,s.jsx)(l_,{onClick:()=>{window.dispatchEvent(new CustomEvent(em.CustomWindowEvents.SHOW_BIOMETRIC_VERIFICATION_MODAL))},children:e("banners.kycVerification.cta")})]})})},lq=({fromEarnPage:e})=>{let{data:t}=(0,tG.default)(),a=t?.data?.me,[{verificationAlert:r,freezeAlert:n},i]=(0,v.useRecoilState)(lM);return((0,O.useEffect)(()=>{a?.freezeReason&&!a?.bannedReason&&i(e=>({...e,freezeAlert:{isOpen:!0},verificationAlert:{isOpen:!0}}))},[a?.bannedReason,a?.freezeReason,i]),(0,O.useEffect)(()=>{a?.idVerification?.idVerificationRequired&&r.isOpen&&a?.freezeReason&&!a.bannedReason&&e&&tg.default.idVerificationBannerSeen()},[a?.idVerification?.idVerificationRequired,r.isOpen,a?.freezeReason,a?.bannedReason,e]),a?.freezeReason&&!a?.bannedReason)?(0,s.jsx)(s.Fragment,{children:(0,s.jsx)("div",{className:"flex mt-[24px] w-full justify-center items-center",children:(0,s.jsx)("div",{className:"w-[97%] md:w-[70%]",children:a?.freezeReason&&!a?.bannedReason&&(0,s.jsxs)(s.Fragment,{children:[a?.idVerification?.idVerificationRequired&&r.isOpen&&(0,s.jsx)(lK,{
43campaignApprovalExpiresAt:a?.idVerification?.campaignApprovalExpiresAt,timedIdVerification:e,idVerificationProvider:a?.idVerification?.idVerificationProvider}),a?.kycVerificationRequired&&r.isOpen&&!e&&(0,s.jsx)(lH,{}),!a?.idVerification?.idVerificationRequired&&!a?.kycVerificationRequired&&n.isOpen&&!e&&(0,s.jsx)(lz,{publicReason:a?.freezeReason})]})})})}):null};var l$=e.i(171078),lQ=e.i(749139),lZ=e.i(810296),lY=e.i(4012),lX=e.i(322831),lJ=e.i(871107),l0=e.i(949938),l1=e.i(991820);let l2="/img/cashout/marketing/cashback-promotional-banners",l3={[tf.CashoutGiftCardPromotionalBannerVariantType.EARN]:{[R.CountryCode.Us]:{i18n:{title:{key:"cashbackPromotionalBanners.earnUS.title",defaultValue:"Earn while you shop"},desc:{key:"cashbackPromotionalBanners.earnUS.descV2",defaultValue:"Get instant cashback on gift cards (Amazon, Uber & 100+)"}},imageProps:{src:`${l2}/shop-giftcard-illustration.png`,width:54,height:41}},[R.CountryCode.De]:{i18n:{title:{key:"cashbackPromotionalBanners.earnDE.title",defaultValue:"Earn while you shop"},desc:{key:"cashbackPromotionalBanners.earnDE.desc",defaultValue:"Cashback on gift cards (Rossmann, Zalando & 100+)"}},imageProps:{src:`${l2}/shop-giftcard-illustration.png`,width:54,height:41}}},[tf.CashoutGiftCardPromotionalBannerVariantType.SPECIFIC]:{[R.CountryCode.Us]:{i18n:{title:{key:"cashbackPromotionalBanners.specificUS.title",defaultValue:"{{cashbackPercentage}}% back on {{brandName}}"},desc:{key:"cashbackPromotionalBanners.specificUS.desc",defaultValue:"Enjoy food while earning money, get cashback now!"}},imageProps:{src:`${l2}/doordash-brand-logo.png`,width:46,height:24}},[R.CountryCode.De]:{i18n:{title:{key:"cashbackPromotionalBanners.specificDE.title",defaultValue:"{{cashbackPercentage}}% Cashback at {{brandName}}"},desc:{key:"cashbackPromotionalBanners.specificDE.desc",defaultValue:"Earn while fueling up, secure your cashback now!"}},imageProps:{src:`${l2}/aral-brand-logo.png`,width:58,height:58}}}};var l5=e.i(803280),l4=e.i(11034),l8=e.i(782822);let l6=()=>{let e=(0,j.useFeatureFlags)(e=>e.cashoutGiftcardPromotionalBannersSettings),t=(0,lJ.default)(),{t:a}=(0,lX.useTranslation)("_cashout"),{titleValues:r,isLoadingGiftcardOffer:n}=function({giftcardOfferId:e,isGiftcardOfferVariant:t,market:a}){let r=(0,rq.default)(),s=(0,O.useCallback)((e,t)=>{let{amount:a}=r({amount:e,originalCurrency:t,targetCurrency:tF.Currency.COINS});return a},[r]),{data:n,isLoading:l}=(({giftCardId:e,country:t,isEnabled:a=!0})=>{let{isLoggedIn:r}=(0,t6.default)(),s=(0,l5.getValidCountryCode)(t);return(0,q.useQuery)({queryKey:[i.QueryKeys.GRAPHQL_GET_GIFT_CARD_OFFER,{id:e}],queryFn:()=>K.default.cashbackGiftCard.getGiftCardOffer({id:e,countryCode:s}),select:e=>e.data?.getGiftCardOffer,enabled:a&&!!r})})({giftCardId:e,isEnabled:t,country:a}),[o,c]=(0,O.useState)(void 0);return(0,O.useEffect)(()=>{n&&c({brandName:n.brandName,cashbackPercentage:(0,l4.getGiftCardOfferCashbackPercentage)(n,s).cashbackPercentage})},[n,s]),{titleValues:o,isLoadingGiftcardOffer:l}}({giftcardOfferId:e?.giftcardOfferId??"",isGiftcardOfferVariant:e?.isGiftcardOfferVariant??!1,market:e?.market??""}),{isMuted:l,mute:o}=function({storageKey:e,muteDurationDays:t}){let[a,r]=(0,O.useState)(!0);return(0,O.useEffect)(()=>{if(!t)return void r(!1);let a=(0,en.getLocalStorage)(e);if(!a)return void r(!1);let s=Number(a);if(Number.isNaN(s))return void r(!1);let n=24*t*36e5;r(Date.now()-s<n)},[e,t]),{isMuted:a,mute:(0,O.useCallback)(()=>{(0,en.setLocalStorage)(e,String(Date.now())),r(!0)},[e])}}({storageKey:l0.BrowserStorageKeys.CASHBACK_PROMOTIONAL_BANNER_MUTED_AT,muteDurationDays:e?.muteDurationDays}),c=(0,O.useRef)(!1),{ref:d,inView:u}=(0,iX.useInView)({threshold:.75}),m=(0,l8.useBottomNavSpaceReady)(),h=!!e?.enabled&&(!e?.isGiftcardOfferVariant||!n)&&(!e?.isGiftcardOfferVariant||!!r)&&!l&&m;(0,O.useEffect)(()=>{u&&!c.current&&(c.current=!0,(0,l1.trackAmplitudeEvent)("cashout_giftcard_banner_viewed",{variant:e?.variantType,country:e?.market,giftcard_name:r?.brandName}))},[u]);let p=((e,t)=>{if(!e||!t)return;let a=l3[e];if(t in a)return a[t]})(e?.variantType,e?.market);return h&&p?(0,s.jsx)(lY.Portal,{children:(0,s.jsx)("div",{ref:d,className:"z-999 fixed bottom-[calc(var(--bottom-nav-space)+14px)] tabletMax:bottom-[14px] left-0 right-0 px-[8px] md:px-0",children:(0,s.jsxs)("div",{className:"flex items-center w-[370px] max-w-full mx-auto p-[8px_12px] gap-[10px] relative rounded-[12px] border border-solid border-core-greyBlue-300",style:{background:"linear-gradient(180deg, var(--color-core-neutral-0-A10) 0%, var(--color-core-neutral-1000-A10) 100%), linear-gradient(90deg, var(--color-core-blue-800) 0%, var(--color-core-blue-900) 30%, var(--color-core-greyBlue-400) 60%, var(--color-core-greyBlue-500) 100%)"},children:[(0,s.jsx)(lZ.default,{src:(0,lQ.getAssetUrl)(p.imageProps.src),alt:a("cashbackPromotionalBanners.shopGiftCardAlt"),imageWidth:p.imageProps.width,imageHeight:p.imageProps.height,flexShrink:0,objectFit:"cover",position:"relative",w:`${p.imageProps.width}px`,zIndex:1}),(0,s.jsxs)("div",{className:"flex flex-col items-stretch gap-[8px]",children:[(0,s.jsx)("p",{className:"text-[16px] font-bold leading-[150%] text-core-neutral-0 m-0",children:a(p.i18n.title.key,p.i18n.title.defaultValue,r)}
43),(0,s.jsxs)("div",{className:"flex items-center gap-[10px]",children:[(0,s.jsx)("p",{className:"text-[12px] leading-[150%] text-core-neutral-0 m-0",children:a(p.i18n.desc.key,p.i18n.desc.defaultValue)}),(0,s.jsx)("div",{className:"shrink-0",children:(0,s.jsx)(g.Button,{onClick:()=>{(0,l1.trackAmplitudeEvent)("cashout_giftcard_banner_cta_clicked",{country:e?.market,variant:e?.variantType,giftcard_name:r?.brandName,destination:e?.destination}),e?.isGiftcardOfferVariant&&e.giftcardOfferId?t("deals",`/deals/gift-cards?gift-card=${e.giftcardOfferId}`):e?.isGiftcardsTabVariant&&t("deals","/deals/gift-cards")},variant:"primary",size:"sm",children:a("cashbackPromotionalBanners.cta")})})]})]}),(0,s.jsx)("button",{type:"button","aria-label":a("common.close"),className:"absolute top-[4px] right-[8px] inline-flex items-center justify-center appearance-none cursor-pointer bg-transparent p-0 text-core-neutral-0",onClick:()=>{(0,l1.trackAmplitudeEvent)("cashout_giftcard_banner_dismissed",{country:e?.market,variant:e?.variantType,giftcard_name:r?.brandName}),o()},children:(0,s.jsx)("svg",{width:"16",height:"16",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"2",strokeLinecap:"round","aria-hidden":"true",children:(0,s.jsx)("path",{d:"M18 6 6 18M6 6l12 12"})})})]})})}):null};var l7=e.i(150383);let l9=e=>(0,s.jsx)(e0.default,{viewBox:"0 0 15 15",fill:"none",...e,children:(0,s.jsx)("svg",{width:"15",height:"15",viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,s.jsx)("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M7.5 1.82927C4.36814 1.82927 1.82927 4.36814 1.82927 7.5C1.82927 10.6319 4.36814 13.1707 7.5 13.1707C10.6319 13.1707 13.1707 10.6319 13.1707 7.5C13.1707 4.36814 10.6319 1.82927 7.5 1.82927ZM0 7.5C0 3.35786 3.35786 0 7.5 0C11.6421 0 15 3.35786 15 7.5C15 11.6421 11.6421 15 7.5 15C3.35786 15 0 11.6421 0 7.5ZM6.76829 3.65854C7.27343 3.65854 7.68293 4.06803 7.68293 4.57317V7.31707H10.4268C10.932 7.31707 11.3415 7.72657 11.3415 8.23171C11.3415 8.73685 10.932 9.14634 10.4268 9.14634H6.76829C6.26315 9.14634 5.85366 8.73685 5.85366 8.23171V4.57317C5.85366 4.06803 6.26315 3.65854 6.76829 3.65854Z",fill:"currentColor"})})});e.i(245110);var oe=e.i(887366);let ot="h-[60px] md:h-[91.2px]",oa="text-[50px] md:text-[76px] font-semibold text-core-neutral-0 tabular-nums",or=[0,1,2,3,4,5,6,7,8,9,0,1,2,3,4,5,6,7,8,9];function os({digit:e,delay:t=0}){let[a,r]=(0,O.useState)(!1),[n,i]=(0,O.useState)(!1),l=Number.parseInt(e,10),o=(0,O.useRef)(0);return(0,O.useEffect)(()=>{if(globalThis.matchMedia("(prefers-reduced-motion: reduce)").matches){r(!0),i(!0);return}r(!1),i(!1);let e=null,t=requestAnimationFrame(()=>{e=requestAnimationFrame(()=>{r(!0)})});return()=>{cancelAnimationFrame(t),e&&cancelAnimationFrame(e)}},[e]),(0,s.jsxs)("div",{className:`relative inline-block select-none ${ot}`,children:[(0,s.jsx)("span",{"aria-hidden":!0,className:`invisible select-none leading-none ${oa}`,children:e}),(0,s.jsx)("div",{className:"pointer-events-none absolute inset-0 select-none [clip-path:inset(0_-9999px)]",children:(0,s.jsx)("div",{className:"absolute left-1/2 top-0 flex flex-col",onTransitionEnd:e=>{"transform"===e.propertyName&&(i(!0),o.current=l)},style:{transform:`translateX(-50%) translateY(${a?-((10+l)*5):-(5*o.current)}%)`,transition:a?`transform 0.65s cubic-bezier(0.17, 0.67, 0.35, 1.1) ${t}ms`:"none",willChange:n?"auto":"transform"},children:or.map((e,t)=>(0,s.jsx)("div",{className:`flex items-center justify-center ${ot}`,children:(0,s.jsx)("span",{className:`leading-none ${oa}`,children:e})},`slot-digit-${t}`))})})]})}let on=({children:e,isOpen:t,onClose:a,onCloseComplete:r,size:n,header:i,footer:l,hideCloseButton:o})=>{let c=(0,rV.useIsMobile)();return((0,eI.useAppOverlayEffects)(t),c)?(0,s.jsxs)(eM.Modal,{variant:"bottomsheet",open:t,onClose:a,onCloseComplete:r,type:"draggable",title:i,hideClose:o,children:[e,l]}):(0,s.jsxs)(rG,{open:t,onClose:a,onCloseComplete:r,placement:"right",size:n,title:i,hideClose:o,belowHeader:!0,children:[(0,s.jsx)(rL,{children:e}),l&&(0,s.jsx)(rD,{children:l})]})};var oi=e.i(486364),ol=e.i(598410),oo=e.i(344398);function oc({ariaLabel:e,children:t}){let[a,r]=(0,O.useState)(!1),[n]=(0,oo.useMediaQuery)("(hover: hover)"),i=n?{onMouseEnter:()=>r(!0),onMouseLeave:()=>r(!1)}:{};return(0,s.jsxs)(r7.Root,{open:a,onOpenChange:e=>{e||r(!1)},children:[(0,s.jsx)(r7.Trigger,{asChild:!0,children:(0,s.jsx)("button",{type:"button","aria-label":e,className:"inline-flex h-[18px] w-[18px] min-w-[18px] curs
43or-pointer appearance-none items-center justify-center bg-transparent p-0 leading-none outline-hidden focus:outline-hidden",...i,onClick:e=>{e.stopPropagation(),n||r(e=>!e)},children:(0,s.jsx)(ol.default,{boxSize:"18px",strokeColor:"var(--color-core-greyBlue-50)"})})}),(0,s.jsx)(r7.Portal,{children:(0,s.jsxs)(r7.Content,{side:"bottom",sideOffset:4,...i,onOpenAutoFocus:e=>e.preventDefault(),className:"z-1800 max-w-[229px] rounded-md border border-solid border-transparent bg-core-greyBlue-900 px-3 py-2 text-[12px] leading-[157%] text-core-greyBlue-50 shadow-[0_1px_2px_0_var(--color-core-neutral-1000-A10)] outline-hidden focus:outline-hidden phoneMax:bg-core-greyBlue-300 phoneMax:text-[13px]",children:[t,(0,s.jsx)(r7.Arrow,{className:"fill-core-greyBlue-900 phoneMax:fill-core-greyBlue-300",width:12,height:6})]})})]})}var od=e.i(822315),ou=e.i(753045);let om="h-[32px] w-[32px] shrink-0 rounded-[3.8px] phoneMax:h-[40px] phoneMax:w-[40px]",oh={bonus:{ariaLabelKey:"pendingRewards.bonusWithdrawInfoAriaLabel",ariaLabelDefault:"More information about bonus withdrawal requirements",key:"pendingRewards.bonusWithdrawInfo",defaults:"Earn {{amount}} more to withdraw your claimed bonus codes."},nonGamingSubReward:{ariaLabelKey:"pendingRewards.nonGamingSubRewardInfoAriaLabel",ariaLabelDefault:"More information about non-gaming sub-reward",key:"pendingRewards.nonGamingSubRewardInfo",defaults:"Your bonus is on the way — we're processing your recent cashback."},affiliate:{ariaLabelKey:"pendingRewards.affiliateInfoAriaLabel",ariaLabelDefault:"More information about pending referral commission",key:"pendingRewards.affiliateInfo",defaults:"Commission from your referrals that is still clearing. It lands in your balance automatically once released."}};function op(e){let{title:t,coins:a,kind:r}=e,{t:n}=(0,C.useTranslationTyped)("_cashout-v2"),{lng:i}=(0,rb.useParams)(),l=(0,tS.useCurrencyText)(),o="offer"===r,c="offer"===e.kind?function(e){if(!e)return null;let t=(0,od.default)(e);if(!t.isValid())return null;let a=(0,od.default)();return t.isAfter(a)?Math.max(1,t.diff(a,"hour")):null}(e.dateToRelease):null,d=null===c?null:c>=24?(0,ou.formatNumberSafe)(Math.ceil(c/24),i,{style:"unit",unit:"day",unitDisplay:"long"}):(0,ou.formatNumberSafe)(c,i,{style:"unit",unit:"hour",unitDisplay:"long"}),u="offer"===r?null:oh[r];return(0,s.jsxs)("div",{className:o?"flex items-start justify-between py-2 phoneMax:items-end":"flex items-center justify-between py-2",children:[(0,s.jsxs)(r4.Flex,{align:"center",gap:"sm",children:[o?(0,s.jsx)(lZ.default,{src:e.icon||(0,lQ.getAssetUrl)("/img/profile/offerIcon.png"),alt:"withdrawal method icon",imageHeight:40,imageWidth:40,className:om}):(0,s.jsx)("div",{className:(0,w.cn)("flex items-center justify-center bg-core-greyBlue-700",om),children:(0,s.jsx)(oi.default,{boxSize:"16px",className:"phoneMax:h-[20px] phoneMax:w-[20px]",color:"core.greyBlue.50"})}),(0,s.jsxs)("div",{className:"flex flex-col items-stretch gap-0 phoneMax:gap-1",children:[o?(0,s.jsx)("p",{className:"m-0 text-sm font-semibold leading-[157%] text-core-neutral-0",children:t}):(0,s.jsxs)("div",{className:"flex items-center gap-1",children:[(0,s.jsx)("p",{className:"m-0 text-sm font-semibold leading-[157%] text-core-neutral-0",children:t}),u&&(0,s.jsx)(oc,{ariaLabel:n(u.ariaLabelKey,u.ariaLabelDefault),children:(0,s.jsx)(Z.Trans,{t:n,i18nKey:u.key,defaults:u.defaults,values:"bonus"===r?{amount:l({amount:e.bonusWithdrawableCoins}).value}:void 0})})]}),o&&(0,s.jsxs)("div",{className:"flex items-center gap-1",children:[(0,s.jsx)("p",{className:"m-0 text-sm font-normal leading-[157%] text-core-greyBlue-50",children:null!==d?n("pendingRewards.timeToAvailable",{dayToRelease:d}):n("pendingRewards.datePending")}),null===d&&(0,s.jsx)(oc,{ariaLabel:n("pendingRewards.pendingDateInfoAriaLabel"),children:(0,s.jsx)(Z.Trans,{t:n,i18nKey:"pendingRewards.pendingDateReason",components:{reasonLink:(0,s.jsx)("a",{className:"text-core-blue-200 text-[12px] no-underline hover:underline phoneMax:text-[13px]",href:`https://freecash.com/academy/${i}/support/general/platform/cashback-pending`,target:"_blank",rel:"noopener noreferrer"})}})})]})]})]}),(0,s.jsxs)("p",{className:"m-0 text-sm font-semibold leading-[157%] text-core-greyBlue-50",children:["+",l({amount:a}).value]})]})}function ox({isOpen:e,onClose:t,offers:a,userBonusRewards:r,nonGamingPendingSubRewards:n,pendingAffiliateBalance:i,totalAmount:l}){let{t:o}=(0,C.useTranslationTyped)("_cashout-v2"),c=(0,tS.useCurrencyText)(),{startRef:d,hintRef:u,hintSentinelStyle:m,isHintVisible:h}=i0();return(0,s.jsx)(on,{isOpen:e,onClose:t,size:460,children:(0,s.jsxs)("div",{className:"w-full",children:[(0,s.jsx)("div",{ref:d,className:"h-px"}),(0,s.jsxs)("div",{className:"flex flex-col items-stretch gap-2 phoneMax:gap-[15px]",children:[(0,s.jsxs)("div",{className:"sticky top-0 z-1 flex flex-col items-stretch gap-5 pt-[35px] backdrop-blur-[6px] phoneMax:static phoneMax:bg-core-greyBlue-900 phoneMax:pt-0 phoneMax:backdrop-blur-none",children:[(0,s.jsx)("p",{className:"m-0 text-[16px] font-semibold leading-[150%] text-core-greyBlue-25 phoneMax:text-core-neutral-0",children:o("pendingRewards.title")}),(0,s.jsxs)("div",{className:"flex items-center justify-between border-b border-solid border-core-neutral-0-A10 pb-3 phoneMax:hidden",children:[(0,s.jsx)("p",{className:"m-0 text-[16px] font-semibold leading-[150%] text-core-neutral-0",children:o("pendingRewards.totalPending")}),(0,s.jsxs)("p",{className:"m-0 text-[16px] font-semibold leading-[150%] text-core-freecashGreen-500",children:["+",c({amount:l}).value]})]})]}),(0,s.jsxs)("div",{className:"flex flex-col items-stretch gap-0 phoneMax:gap-[15px]",children:[i>0&&(0,s.jsx)(op,{kind:"affiliate",title:o("pendingRewards.affiliateBonusTitle"),coins:i}),!!r.bonusBalance&&(0,s.jsx)(op,{kind:"bonus",title:o("pendingRewards.bonus
43Reward"),coins:r.bonusBalance,bonusWithdrawableCoins:r.bonusWithdrawableCoins}),n.map(e=>(0,s.jsx)(op,{kind:"nonGamingSubReward",title:o("pendingRewards.nonGamingSubRewardTitle"),coins:e.coins},e.id)),a.map((e,t)=>(0,s.jsx)(op,{kind:"offer",title:e.offerName,coins:e.coins,icon:e.icon,dateToRelease:e.dateToRelease},`${e.offerName}-${t}`))]}),(0,s.jsxs)("div",{className:"hidden items-center justify-between pt-[15px] phoneMax:flex",children:[(0,s.jsx)("p",{className:"m-0 text-[16px] font-semibold leading-[150%] text-core-greyBlue-25",children:o("pendingRewards.totalPending")}),(0,s.jsxs)("p",{className:"m-0 text-[16px] font-semibold leading-[150%] text-core-freecashGreen-500",children:["+",c({amount:l}).value]})]})]}),(0,s.jsx)("div",{ref:u,style:m}),(0,s.jsx)("div",{className:"pointer-events-none sticky bottom-2 z-1 -mt-8 flex h-8 justify-center",children:(0,s.jsx)(iY,{visible:h})})]})})}var of=e.i(846118),og=e.i(9438),oy=e.i(83281),ob=e.i(667619),ov=e.i(291576),ow=e.i(424251),oC=e.i(131391),oj=e.i(268817),ok=e.i(633135),oN=e.i(233985),oS=e.i(486640),oF=e.i(731889);let oT=(0,nF.graphql)(`
44  query GetOfferTaskClaimsInfo {
45    getOfferTaskClaimsInfo {
46      totalClaimableCoins
47      latestClaimableOfferId
48    }
49  }
50`),oE=async()=>{let e=await nN.default.graphql.request({query:oT}),t=e?.data?.getOfferTaskClaimsInfo;return!t||e?.errors?.length?null:{totalCoins:t.totalClaimableCoins,latestOfferId:t.latestClaimableOfferId}};var oA=e.i(873938);let oR="flex items-center gap-[6px] rounded-[100px] border border-solid px-[12px] py-[4px] md:px-[13.5px] md:py-[9.5px]",oM="m-0 text-xs font-normal leading-[100%] text-core-neutral-0 md:text-sm";function o_(){let{t:e}=(0,C.useTranslationTyped)("_cashout-v2"),t=(0,tS.useCurrencyText)(),a=(0,ok.default)(),r=(0,oS.useClaimTaskRewardsVariant)()!==tf.ClaimTaskRewardsVariant.CONTROL,{data:n}=function({enabled:e=!0}={}){let t=(0,$.useQueryClient)(),a=(0,q.useQuery)({queryKey:[i.QueryKeys.GRAPHQL_GET_OFFER_TASK_CLAIMS_INFO],queryFn:oE,enabled:e,staleTime:3e4,retry:!1});return(0,O.useEffect)(()=>{let e=()=>t.invalidateQueries({queryKey:[i.QueryKeys.GRAPHQL_GET_OFFER_TASK_CLAIMS_INFO]});return e8.default.on(oF.SocketEvent.USER_CHANGED_BALANCE,e),()=>{e8.default.off(oF.SocketEvent.USER_CHANGED_BALANCE,e)}},[t]),a}({enabled:r}),l=r&&n&&n.totalCoins>0&&null!=n.latestOfferId?n:null;return(0,s.jsx)(oe.Collapse,{in:null!=l,animateOpacity:!0,children:l?(0,s.jsx)("div",{className:"px-1.5",children:(0,s.jsx)(of.default,{onClick:()=>{(0,oN.trackUnclaimedPillClicked)({totalCoins:l.totalCoins}),a("my-offers",`/my-offers?offerId=${l.latestOfferId}`)},children:(0,s.jsxs)("div",{className:(0,w.cn)(oR,"border-core-freecashGreen-800 bg-core-freecashGreen-25-A10"),children:[(0,s.jsx)("p",{className:oM,children:(0,s.jsx)(Z.Trans,{t:e,i18nKey:"balanceSummary.unclaimed",components:oA.TRANS_TAGS_WITH_LEGACY_ALIASES,values:{amount:t({amount:l.totalCoins}).value}})}),(0,s.jsx)(oj.CaretRightIcon,{size:15.5,"aria-hidden":!0,className:"shrink-0 text-core-freecashGreen-500"})]})})}):null})}let oI="h-[60px] md:h-[114px]";function oP(){let{t:e}=(0,C.useTranslationTyped)("_cashout-v2"),t=(0,tS.useCurrencyText)(),{showSkeleton:a,animation:r}=(0,li.useCashoutSkeleton)(),n=l7.ANIMATION_CLASSES[r],[i,l]=(0,O.useState)(!1),{ref:o,inView:c}=(0,iX.useInView)({triggerOnce:!0,threshold:.5}),{withdrawableNowBalance:d,pendingBalance:u,pendingAffiliateBalance:m,isLoading:h}=(0,x.default)(),{rewards:p,offers:f,isLoading:g}=e7(),{data:y=[]}=function({enabled:e}={}){let{isLoggedIn:t}=(0,t6.default)();return(0,q.useQuery)({queryKey:[oy.NON_GAMING_PENDING_SUB_REWARDS_QUERY_KEY],queryFn:async()=>{let e=await (0,ob.fetchCashbackSubRewards)();return(0,oC.normalizeCashbackSubRewards)(e).filter(e=>"Pending"===e.status)},retry:ow.retryTransientOnly,retryDelay:e=>(0,ov.jitteredBackoff)(e),enabled:e??t})}(),b=(u??0)+(m??0),v=b>0,j=a||"none"!==r&&g,k=t({amount:d??0,keepTrailingZeros:!0}),N=k.rawValue<1e3,S=function(e,t){let a=e.findIndex(e=>"currency"===e.type),r=e.findIndex(e=>"integer"===e.type),s=-1!==a&&a<r,n=[];for(let a of e)if("integer"===a.type||"currency"===a.type||"separator"===a.type||t&&("decimal"===a.type||"fraction"===a.type))for(let e of String(a.value))n.push({char:e,isDigit:/^\d$/.test(e),isCurrency:"currency"===a.type,isCurrencyPrefix:s});let i=0;return n.map(e=>({...e,delay:e.isDigit?60*i++:0}))}(k.parts,N);return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsxs)("div",{className:"flex flex-col items-center gap-[12px] pb-[40px] pt-[24px] md:gap-0 md:pt-[46p
50x]",children:[(0,s.jsx)("p",{className:"m-0 text-md font-medium leading-[150%] text-core-greyBlue-25",children:e("balanceSummary.availableToWithdraw")}),a||h||!c?(0,s.jsx)("div",{ref:o,className:(0,w.cn)("flex w-full items-center justify-center",oI),children:(0,s.jsx)(e9.Skeleton,{className:(0,w.cn)("h-[50px] w-[220px] rounded-[18px] md:h-[76px] md:w-[280px]",n)})}):(0,s.jsx)("div",{ref:o,className:`flex w-full items-center justify-center ${oI}`,children:(0,s.jsx)("div",{className:"flex items-end",children:S.map((e,t)=>e.isDigit?(0,s.jsx)(os,{digit:e.char,delay:e.delay},`slot-${t}`):(0,s.jsx)("span",{className:`m-0 leading-[1.2] ${oa}`,style:{marginRight:e.isCurrency&&e.isCurrencyPrefix?"-0.1em":void 0,marginLeft:e.isCurrency&&!e.isCurrencyPrefix?"-0.1em":void 0},children:e.char},`${e.char}-${t}`))})}),(0,s.jsxs)("div",{className:"flex flex-wrap items-center justify-center gap-y-3",children:[(0,s.jsx)(oe.Collapse,{in:j||!g&&v,animateOpacity:!0,unmountOnExit:!0,children:j?(0,s.jsx)("div",{className:"px-1.5",children:(0,s.jsxs)("div",{className:(0,w.cn)(oR,"border-transparent bg-core-greyBlue-600",n),children:[(0,s.jsx)("div",{className:"h-[15.5px] w-[15.5px] rounded-full bg-core-greyBlue-500"}),(0,s.jsx)("div",{className:"h-[12px] w-[72px] rounded-[8px] bg-core-greyBlue-500 md:h-[14px]"})]})}):(0,s.jsx)("div",{className:"px-1.5",children:(0,s.jsx)(of.default,{onClick:()=>{og.cashoutAnalytics.pendingRewardsDrawerOpened(b,f.length),l(!0)},children:(0,s.jsxs)("div",{className:(0,w.cn)(oR,"border-core-neutral-0-A10 bg-core-neutral-0-A10"),children:[(0,s.jsx)(l9,{boxSize:"15.5px",color:"core.neutral.0"}),(0,s.jsx)("p",{className:oM,children:(0,s.jsx)(Z.Trans,{t:e,i18nKey:"balanceSummary.pending",components:{em:(0,s.jsx)("strong",{})},values:{amount:t({amount:b}).value}})})]})})})}),(0,s.jsx)(o_,{})]})]}),(0,s.jsx)(ox,{isOpen:i,onClose:()=>l(!1),offers:f,userBonusRewards:p,nonGamingPendingSubRewards:y,pendingAffiliateBalance:m??0,totalAmount:b})]})}var oB=e.i(680453);let oU=(0,l$.default)(()=>e.A(958680),{ssr:!1}),oO=({serverIsIosAppWebView:e}={})=>{let t,a,r,n,i=(0,j.useFeatureFlags)(e=>e.showSecondaryCashoutNavigation),l=(0,j.useFeatureFlags)(e=>!!e.cashoutRedesignSettings?.enabled),o=(0,rV.useIsMobile)();return t=(0,j.useFeatureFlags)(),a=(0,O.useRef)(null),r=(0,O.useMemo)(()=>(0,oB.buildCashoutFlagUserProperties)(t),[t]),n=void 0!==t.cashoutRedesignSettings||void 0!==t.cashoutV2Settings,(0,O.useEffect)(()=>{let e;if(n){try{e=JSON.stringify(r)}catch{return}a.current!==e&&(a.current=e,og.cashoutAnalytics.cashoutFlagsSynced(r))}},[n,r]),(0,s.jsxs)(s.Fragment,{children:[(0,s.jsxs)("div",{style:{paddingTop:i&&o?"var(--secondary-header-height)":void 0},children:[!l&&(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(lq,{}),(0,s.jsx)(lD,{})]}),l&&(0,s.jsx)(oP,{}),(0,s.jsx)(lE,{serverIsIosAppWebView:e})]}),(0,s.jsx)(oU,{}),(0,s.jsx)(l6,{})]})};e.s(["LoggedInCashout",0,oO,"default",0,oO],32305)}]);
51
52//# debugId=0f4f7dab-2aca-a0b2-b2e2-256d8213bc67

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.