PageSourceSearch

https://redboxglobal.com/static/js/main.0b6344ca.chunk.js

js redboxglobal.com collected 2026-10-01 23:55:51 UTC 158,301 bytes, 1 lines download raw bytes

1(this.webpackJsonpclient=this.webpackJsonpclient||[]).push([[0],{226:function(e,t,n){},252:function(e,t,n){},297:function(e,t,n){},298:function(e,t,n){var c={"./0xbtc.svg":[308,3],"./1inch.svg":[309,4],"./1st.svg":[310,5],"./aave.svg":[311,6],"./abbc.svg":[312,7],"./abt.svg":[313,8],"./ac3.svg":[314,9],"./act.svg":[315,10],"./ada.svg":[316,11],"./adb.svg":[317,12],"./adx.svg":[318,13],"./ae.svg":[319,14],"./aeon.svg":[320,15],"./aergo.svg":[321,16],"./agi.svg":[322,17],"./aion.svg":[323,18],"./ait.svg":[324,19],"./akro.svg":[325,20],"./akt.svg":[326,21],"./aleph.svg":[327,22],"./algo.svg":[328,23],"./alis.svg":[329,24],"./alpha.svg":[330,25],"./alx.svg":[331,26],"./amb.svg":[332,27],"./amlt.svg":[333,28],"./ampl.svg":[334,29],"./anc.svg":[335,30],"./anj.svg":[336,31],"./ankr.svg":[337,32],"./ant.svg":[338,33],"./aph.svg":[339,34],"./apl.svg":[340,35],"./appc.svg":[341,36],"./apy.svg":[342,37],"./ar.svg":[343,38],"./ardr.svg":[344,39],"./ark.svg":[345,40],"./arn.svg":[346,41],"./aro.svg":[347,42],"./arrr.svg":[348,43],"./ast.svg":[349,44],"./atmi.svg":[350,45],"./atom.svg":[351,46],"./auc.svg":[352,47],"./aura.svg":[353,48],"./avax.svg":[354,49],"./awc.svg":[355,50],"./axp.svg":[356,51],"./bac.svg":[357,52],"./bal.svg":[358,53],"./bam.svg":[359,54],"./band.svg":[360,55],"./bao.svg":[361,56],"./bat.svg":[362,57],"./bay.svg":[363,58],"./bbr.svg":[364,59],"./bcd.svg":[365,60],"./bch.svg":[366,61],"./bcn.svg":[367,62],"./bco.svg":[368,63],"./bf.svg":[369,64],"./bifi.svg":[370,65],"./bix.svg":[371,66],"./block.svg":[372,67],"./blt.svg":[373,68],"./blue.svg":[374,69],"./blz.svg":[375,70],"./bnb.svg":[376,71],"./bnt.svg":[377,72],"./bond.svg":[378,73],"./bora.svg":[379,74],"./box.svg":[380,75],"./bpt.svg":[381,76],"./bqx.svg":[382,77],"./brd.svg":[383,78],"./btc++.svg":[384,79],"./btc.svg":[385,80],"./btcd.svg":[386,81],"./btcp.svg":[387,82],"./btg.svg":[388,83],"./btmx.svg":[389,84],"./bto.svg":[390,85],"./bts.svg":[391,86],"./btt.svg":[392,87],"./btu.svg":[393,88],"./bu.svg":[394,89],"./busd.svg":[395,90],"./bwt.svg":[396,91],"./bz.svg":[397,92],"./bznt.svg":[398,93],"./bzrx.svg":[399,94],"./c20.svg":[400,95],"./cake.svg":[401,96],"./capp.svg":[402,97],"./car.svg":[403,98],"./card.svg":[404,99],"./cbat.svg":[405,100],"./cbc.svg":[406,101],"./cbt.svg":[407,102],"./cccx.svg":[408,103],"./cdai.svg":[409,104],"./cdt.svg":[410,105],"./cel.svg":[411,106],"./celr.svg":[412,107],"./cennz.svg":[413,108],"./ceth.svg":[414,109],"./cfx.svg":[415,110],"./chai.svg":[416,111],"./chat.svg":[417,112],"./chsb.svg":[418,113],"./chz.svg":[419,114],"./ckb.svg":[420,115],"./clo.svg":[421,116],"./cloak.svg":[422,117],"./cmt.svg":[423,118],"./cnd.svg":[424,119],"./cnx.svg":[425,120],"./comp.svg":[426,121],"./coni.svg":[427,122],"./cosm.svg":[428,123],"./coti.svg":[429,124],"./cov.svg":[430,125],"./cova.svg":[431,126],"./cpc.svg":[432,127],"./cpx.svg":[433,128],"./cre.svg":[434,129],"./cream.svg":[435,130],"./cred.svg":[436,131],"./crep.svg":[437,132],"./cro.svg":[438,133],"./crpt.svg":[439,134],"./crv.svg":[440,135],"./cs.svg":[441,136],"./csai.svg":[442,137],"./csc.svg":[443,138],"./ctc.svg":[444,139],"./ctxc.svg":[445,140],"./cube.svg":[446,141],"./cusdc.svg":[447,142],"./cv.svg":[448,143],"./cvc.svg":[449,144],"./cvt.svg":[450,145],"./cwbtc.svg":[451,146],"./czrx.svg":[452,147],"./dadi.svg":[453,148],"./dag.svg":[454,149],"./dai.svg":[455,150],"./dasc.svg":[456,151],"./dash.svg":[457,152],"./dat.svg":[458,153],"./data.svg":[459,154],"./datx.svg":[460,155],"./dbc.svg":[461,156],"./dcc.svg":[462,157],"./dcn.svg":[463,158],"./dcr.svg":[464,159],"./dct.svg":[465,160],"./ddd.svg":[466,161],"./default.svg":[133],"./dent.svg":[467,162],"./dfi.svg":[468,163],"./dft.svg":[469,164],"./dgb.svg":[470,165],"./dgd.svg":[471,166],"./dgtx.svg":[472,167],"./divi.svg":[473,168],"./dlt.svg":[474,169],"./dmt.svg":[475,170],"./dnt.svg":[476,171],"./dock.svg":[477,172],"./dodo.svg":[478,173],"./doge.svg":[479,174],"./dor.svg":[480,175],"./dot.svg":[481,176],"./drgn.svg":[482,177],"./drop.svg":[483,178],"./dta.svg":[484,179],"./dtr.svg":[485,180],"./dtx.svg":[486,181],"./dxt.svg":[487,182],"./edg.svg":[488,183],"./edo.svg":[489,184],"./efx.svg":[490,185],"./egld.svg":[491,186],"./egt.svg":[492,187],"./ekg.svg":[493,188],"./ekt.svg":[494,189],"./ela.svg":[495,190],"./elec.svg":[496,191],"./elf.svg":[497,192],"./emc.svg":[498,193],"./emc2.svg":[499,194],"./eng.svg":[500,195],"./enj.svg":[501,196],"./eos.svg":[502,197],"./eosdac.svg":[503,198],"./erd.svg":[504,199],"./ern.svg":[505,200],"./esd.svg":[506,201
1],"./esp.svg":[507,202],"./ess.svg":[508,203],"./etc.svg":[509,204],"./eth.svg":[510,205],"./etn.svg":[511,206],"./etp.svg":[512,207],"./etz.svg":[513,208],"./evx.svg":[514,209],"./ewt.svg":[515,210],"./exrn.svg":[516,211],"./exy.svg":[517,212],"./fct.svg":[518,213],"./fet.svg":[519,214],"./fil.svg":[520,215],"./flow.svg":[521,216],"./fota.svg":[522,217],"./frm.svg":[523,218],"./fsn.svg":[524,219],"./ft.svg":[525,220],"./ftm.svg":[526,221],"./ftt.svg":[527,222],"./fuel.svg":[528,223],"./fun.svg":[529,224],"./fxc.svg":[530,225],"./fxt.svg":[531,226],"./gala.svg":[532,227],"./gdc.svg":[533,228],"./gem.svg":[534,229],"./gen.svg":[535,230],"./gno.svg":[536,231],"./gnt.svg":[537,232],"./gnx.svg":[538,233],"./go.svg":[539,234],"./goc.svg":[540,235],"./got.svg":[541,236],"./grin.svg":[542,237],"./grs.svg":[543,238],"./grt.svg":[544,239],"./gsc.svg":[545,240],"./gt.svg":[546,241],"./gtc.svg":[547,242],"./gto.svg":[548,243],"./gusd.svg":[549,244],"./gvt.svg":[550,245],"./gxs.svg":[551,246],"./hav.svg":[552,247],"./hbar.svg":[553,248],"./hc.svg":[554,249],"./hedg.svg":[555,250],"./her.svg":[556,251],"./hex.svg":[557,252],"./hive.svg":[558,253],"./hot-x.svg":[559,254],"./hot.svg":[560,255],"./hpb.svg":[561,256],"./hsr.svg":[562,257],"./ht.svg":[563,258],"./hum.svg":[564,259],"./husd.svg":[565,260],"./hvn.svg":[566,261],"./hydro.svg":[567,262],"./hyn.svg":[568,263],"./ibat.svg":[569,264],"./icn.svg":[570,265],"./icx.svg":[571,266],"./idai.svg":[572,267],"./idex.svg":[573,268],"./ieth.svg":[574,269],"./ignis.svg":[575,270],"./iknc.svg":[576,271],"./ilink.svg":[577,272],"./inb.svg":[578,273],"./ins.svg":[579,274],"./iost.svg":[580,275],"./iota.svg":[581,276],"./iotx.svg":[582,277],"./iq.svg":[583,278],"./irep.svg":[584,279],"./iris.svg":[585,280],"./isusd.svg":[586,281],"./iusdc.svg":[587,282],"./iwbtc.svg":[588,283],"./izrx.svg":[589,284],"./jnt.svg":[590,285],"./jrt.svg":[591,286],"./jst.svg":[592,287],"./kava.svg":[593,288],"./kcs.svg":[594,289],"./keep.svg":[595,290],"./key.svg":[596,291],"./kick.svg":[597,292],"./kin.svg":[598,293],"./klv.svg":[599,294],"./kmd.svg":[600,295],"./knc.svg":[601,296],"./ksm.svg":[602,297],"./lamb.svg":[603,298],"./land.svg":[604,299],"./lba.svg":[605,300],"./ldo.svg":[606,301],"./lend.svg":[607,302],"./leo.svg":[608,303],"./link.svg":[609,304],"./lit.svg":[610,305],"./lky.svg":[611,306],"./loki.svg":[612,307],"./lon.svg":[613,308],"./loom.svg":[614,309],"./lpt.svg":[615,310],"./lqd.svg":[616,311],"./lrc.svg":[617,312],"./lsk.svg":[618,313],"./ltc.svg":[619,314],"./lto.svg":[620,315],"./lun.svg":[621,316],"./luna.svg":[622,317],"./lxt.svg":[623,318],"./lym.svg":[624,319],"./maid.svg":[625,320],"./man.svg":[626,321],"./mana-old.svg":[627,322],"./mana.svg":[628,323],"./math.svg":[629,324],"./matic.svg":[630,325],"./mbc.svg":[631,326],"./mco.svg":[632,327],"./mcx.svg":[633,328],"./mda.svg":[634,329],"./mds.svg":[635,330],"./med.svg":[636,331],"./medx.svg":[637,332],"./met.svg":[638,333],"./mfg.svg":[639,334],"./mft.svg":[640,335],"./mir.svg":[641,336],"./mith.svg":[642,337],"./mkr.svg":[643,338],"./mln.svg":[644,339],"./mod.svg":[645,340],"./mot.svg":[646,341],"./mta.svg":[647,342],"./mth.svg":[648,343],"./mtl.svg":[649,344],"./mtn.svg":[650,345],"./mvc.svg":[651,346],"./mvl.svg":[652,347],"./mvp.svg":[653,348],"./mwat.svg":[654,349],"./mwc.svg":[655,350],"./mxm.svg":[656,351],"./myb.svg":[657,352],"./nano.svg":[658,353],"./nas.svg":[659,354],"./nav.svg":[660,355],"./ncash.svg":[661,356],"./nct.svg":[662,357],"./near.svg":[663,358],"./nebl.svg":[664,359],"./nec.svg":[665,360],"./neo.svg":[666,361],"./new.svg":[667,362],"./nex.svg":[668,363],"./nexo.svg":[669,364],"./nexxo.svg":[670,365],"./ngc.svg":[671,366],"./nkn.svg":[672,367],"./nmr.svg":[673,368],"./noia.svg":[674,369],"./nper.svg":[675,370],"./npxs.svg":[676,371],"./nrg.svg":[677,372],"./nrve.svg":[678,373],"./nu.svg":[679,374],"./nuls.svg":[680,375],"./nxs.svg":[681,376],"./nxt.svg":[682,377],"./oag.svg":[683,378],"./oax.svg":[684,379],"./ocean.svg":[685,380],"./ocn.svg":[686,381],"./ode.svg":[687,382],"./ogn.svg":[688,383],"./okb.svg":[689,384],"./olt.svg":[690,385],"./omg.svg":[691,386],"./one.svg":[692,387],"./onion.svg":[693,388],"./ont.svg":[694,389],"./open.svg":[695,390],"./orbs.svg":[696,391],"./orc.svg":[697,392],"./orn.svg":[698,393],"./ost.svg":[699,394],"./ovc.svg":[700,395],"./oxt.svg":[701,396],"./pBTC.svg":[702,397],"./pai.svg":[703,398],"./pal.svg":[704,399],"./part.svg":[705,400],"./pax.svg":[706,401],"./paxg.svg":[707,402],"./pay.svg":[708,403],"./perl.svg":[709,404],"./pivx.svg":[710,405],"./plDAI.svg":[711,406],"./plUSDC.svg":[712,407],"./play.svg":[713,408],"./plr.svg":[714,409],"./png.svg":[715,410],"./pnk.svg":[716,411],"./pnt.svg":[717,412],"./poa.svg":[718,413],"./poe.svg":[719,414],"./poly.svg":[720,415],"./pond.svg":[721,416],"./powr.svg":[722,417],"./ppay.svg":[723,418],"./ppc.svg":[724,419],"./ppp.svg":[725,420],"./ppt.svg":[726,421],"./pre.svg":[727,422],"./prl.svg":[728,423],"./pro.svg":[729,424],"./prq.svg":[730,425],"./pst.svg":[731,426],"./qash.svg":[732,427],"./qb
1it.svg":[733,428],"./qkc.svg":[734,429],"./qlc.svg":[735,430],"./qnt.svg":[736,431],"./qsp.svg":[737,432],"./qtum.svg":[738,433],"./r.svg":[739,434],"./rae.svg":[740,435],"./rari.svg":[741,436],"./ray.svg":[742,437],"./rcn.svg":[743,438],"./rdd.svg":[744,439],"./rdn.svg":[745,440],"./ren.svg":[746,441],"./rep.svg":[747,442],"./req.svg":[748,443],"./rev.svg":[749,444],"./rfox.svg":[750,445],"./rhoc.svg":[751,446],"./rif.svg":[752,447],"./rlc.svg":[753,448],"./rose.svg":[754,449],"./rpx.svg":[755,450],"./rsr.svg":[756,451],"./rsv.svg":[757,452],"./rune.svg":[758,453],"./rvn.svg":[759,454],"./s.svg":[760,455],"./sai.svg":[761,456],"./salt.svg":[762,457],"./san.svg":[763,458],"./scrl.svg":[764,459],"./scrt.svg":[765,460],"./seele.svg":[766,461],"./sem.svg":[767,462],"./sfp.svg":[768,463],"./shr.svg":[769,464],"./shuf.svg":[770,465],"./sia.svg":[771,466],"./skl.svg":[772,467],"./sky.svg":[773,468],"./slt.svg":[774,469],"./smart.svg":[775,470],"./snc.svg":[776,471],"./sngls.svg":[777,472],"./snm.svg":[778,473],"./snt.svg":[779,474],"./snx.svg":[780,475],"./sol.svg":[781,476],"./soul.svg":[782,477],"./spn.svg":[783,478],"./srm.svg":[784,479],"./stake.svg":[785,480],"./steem.svg":[786,481],"./steth.svg":[787,482],"./stmx.svg":[788,483],"./storj.svg":[789,484],"./storm.svg":[790,485],"./strat.svg":[791,486],"./stx.svg":[792,487],"./sub.svg":[793,488],"./super.svg":[794,489],"./suqa.svg":[795,490],"./sushi.svg":[796,491],"./suter.svg":[797,492],"./swap.svg":[798,493],"./swth.svg":[799,494],"./sxdt.svg":[800,495],"./sxp.svg":[801,496],"./sys.svg":[802,497],"./tct.svg":[803,498],"./tel.svg":[804,499],"./tfuel.svg":[805,500],"./thc.svg":[806,501],"./theta.svg":[807,502],"./thr.svg":[808,503],"./tio.svg":[809,504],"./titan.svg":[810,505],"./tkn.svg":[811,506],"./tky.svg":[812,507],"./tnb.svg":[813,508],"./tnc.svg":[814,509],"./tnt.svg":[815,510],"./tomo.svg":[816,511],"./tpay.svg":[817,512],"./trac.svg":[818,513],"./trb.svg":[819,514],"./trig.svg":[820,515],"./trtl.svg":[821,516],"./trx.svg":[822,517],"./tryb.svg":[823,518],"./ttc.svg":[824,519],"./tube.svg":[825,520],"./tusd.svg":[826,521],"./ubq.svg":[827,522],"./ubt.svg":[828,523],"./ult.svg":[829,524],"./uma.svg":[830,525],"./unfi.svg":[831,526],"./uni.svg":[832,527],"./unn.svg":[833,528],"./uos.svg":[834,529],"./upp.svg":[835,530],"./usd.svg":[836,531],"./usdc.svg":[837,532],"./usds.svg":[838,533],"./usdt.svg":[839,534],"./utk.svg":[840,535],"./uuu.svg":[841,536],"./veri.svg":[842,537],"./vest.svg":[843,538],"./vet.svg":[844,539],"./via.svg":[845,540],"./vib.svg":[846,541],"./vibe.svg":[847,542],"./vidt.svg":[848,543],"./vikky.svg":[849,544],"./vin.svg":[850,545],"./vite.svg":[851,546],"./viu.svg":[852,547],"./vlx.svg":[853,548],"./vrs.svg":[854,549],"./vsp.svg":[855,550],"./vsys.svg":[856,551],"./vtc.svg":[857,552],"./wabi.svg":[858,553],"./wan.svg":[859,554],"./waves.svg":[860,555],"./wbtc.svg":[861,556],"./wct.svg":[862,557],"./whale.svg":[863,558],"./wib.svg":[864,559],"./wings.svg":[865,560],"./woo.svg":[866,561],"./wpr.svg":[867,562],"./wrx.svg":[868,563],"./wtc.svg":[869,564],"./wxt.svg":[870,565],"./xas.svg":[871,566],"./xchf.svg":[872,567],"./xem.svg":[873,568],"./xin.svg":[874,569],"./xlm.svg":[875,570],"./xlq.svg":[876,571],"./xmark.svg":[877,572],"./xmr.svg":[878,573],"./xmx.svg":[879,574],"./xnk.svg":[880,575],"./xns.svg":[881,576],"./xor.svg":[882,577],"./xrp.svg":[883,578],"./xsn.svg":[884,579],"./xsr.svg":[885,580],"./xtz.svg":[886,581],"./xvg.svg":[887,582],"./xyo.svg":[888,583],"./xzc.svg":[889,584],"./yfi.svg":[890,585],"./yoyo.svg":[891,586],"./zai.svg":[892,587],"./zb.svg":[893,588],"./zco.svg":[894,589],"./zec.svg":[895,590],"./zel.svg":[896,591],"./zen.svg":[897,592],"./zil.svg":[898,593],"./zks.svg":[899,594],"./zrx.svg":[900,595]};function a(e){if(!n.o(c,e))return Promise.resolve().then((function(){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}));var t=c[e],a=t[0];return Promise.all(t.slice(1).map(n.e)).then((function(){return n(a)}))}a.keys=function(){return Object.keys(c)},a.id=298,e.exports=a},299:function(e,t,n){"use strict";n.r(t);var c=n(0),a=n.n(c),r=n(23),o=n.n(r),s=(n(226),n(32)),i=n(28),l=n(17),d=n.n(l),j=n(24),b=n(4),u=n(77),g=n.n(u),h=n(959),f=n(927),p=n(937),m=n(938),O=n(306),x=n(22),v=n(11),y=n(6),w=n(302),S=n(929),C=n(930),N=n(931),k=n(932),T=n(958),F=n(936),R=n(33),D=n.n(R),I=Object(f.a)((function(e){return{paper:{position:"absolute",width:"100%",height:"100vh",backgroundColor:"rgba(0, 0, 0, 0.7)",color:"#fff",border:"2px s
1olid #000",boxShadow:e.shadows[5],padding:e.spacing(2,4,3)},filterIcon:{marginRight:"1rem",marginLeft:"10px"},container:{display:"flex"},inputText:{width:"100%",padding:"8px 15px",display:"inline-block",borderTopRightRadius:"4px",borderBottomRightRadius:"4px",fontFamily:"Ubuntu",border:"none",fontSize:"14px","&::placeholder":{color:"#a9a9a9"}},button:{background:"#f2711c",color:"#fff",paddingLeft:"10px",fontFamily:"Ubuntu",borderTopLeftRadius:"4px",borderBottomLeftRadius:"4px",borderRadius:"0",textTransform:"capitalize","&:hover":{background:"#f26202",color:"#fff"}},closeBtn:{color:"red",position:"absolute",top:"10px",right:"140px"},searchBoxcontainer:{background:"#fff",color:"#000",padding:"1rem",marginTop:"1rem",borderRadius:"4px"},searchBoxBtn:{width:"155px",justifyContent:"flex-start",textTransform:"capitalize",backgroundColor:"#e0e0e0",boxShadow:"none","&:hover":{backgroundColor:"#e0e0e0",boxShadow:"none"}},loader:{color:"#fff",position:"absolute",backgroundColor:"rgba(0,0,0,.85)",zIndex:"1",opacity:"0.5",width:"100%",height:"100%",display:"flex",justifyContent:"center",alignItems:"center"},loaderIcon:{color:"#fff"},tableRow:{marginTop:"1.5rem",display:"block"},tableRowSearch:{marginTop:"1.5rem",display:"block",width:"100%","&:hover":{backgroundColor:"#333"}},searchContainer:{overflowY:"scroll",height:"620px",margin:"auto",display:"block",position:"relative"},scrollToTopBtnStyle:{fontSize:"1.3rem",color:"#fff"},deleteBtn:{width:"29px",height:"29px",borderRadius:"50%",backgroundColor:"#f44336","&:hover":{backgroundColor:"#f44336"}},deleteIcon:{fontSize:"20px",color:"#fff"}}})),A=n(80),E=n.n(A),B=n(51),z=n.n(B),L=n(112),M=n.n(L),Y=n(186),_=n.n(Y),P="https://apig.redboxglobal.com/api",U=(Object({NODE_ENV:"production",PUBLIC_URL:"",WDS_SOCKET_HOST:void 0,WDS_SOCKET_PATH:void 0,WDS_SOCKET_PORT:void 0,FAST_REFRESH:!0,REACT_APP_BACKEND:"https://apig.redboxglobal.com/api",REACT_APP_STOCKS_API:"https://tickers.redboxglobal.com",REACT_APP_TICKER_TOKEN:"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJfaWQiOiI2MWY0YzJjNTM2MDAwODcxMmQ0NWUyZjYiLCJpYXQiOjE2NDM0MzA2MDF9.gCndw2nkQibhVjL3-KHnQakmRR4z4gNRVqiWMmUdtVE",REACT_APP_TICKER_USER_ID:"61f4c2c5360008712d45e2f6"}).REACT_APP_SOCKET_URL,"https://tickers.redboxglobal.com"),G=function(e,t){"undefined"!==typeof window&&(localStorage.setItem("jwt",JSON.stringify(e)),t())},W=function(e){if("undefined"!==typeof window)return localStorage.removeItem("jwt"),e(),fetch("".concat(P,"/signout"),{method:"GET"}).then((function(e){return console.log("signout success")})).catch((function(e){return console.log(e)}))},H=function(){return"undefined"!=typeof window&&(!!localStorage.getItem("jwt")&&JSON.parse(localStorage.getItem("jwt")))},X=n(21),q=n.n(X),J=n(134),K=n.p+"static/media/rss.5474b73a.png",V=n(185),Q=n.n(V),$=n(1),Z=Object(c.createContext)(),ee=function(e){var t=e.children,n=Object(c.useState)(!1),a=Object(b.a)(n,2),r=a[0],o=a[1];return Object($.jsx)(Z.Provider,{value:[r,o],children:t})},te=Object(c.createContext)(),ne=function(e){var t=e.children,n=Object(c.useState)(""),a=Object(b.a)(n,2),r=a[0],o=a[1];return Object($.jsx)(te.Provider,{value:[r,o],children:t})},ce=a.a.memo((function(e){var t,n,a=e.value,r=e.news,o=Object(c.useContext)(Z),s=Object(b.a)(o,2),i=(s[0],s[1]),l=Object(c.useContext)(te),d=Object(b.a)(l,2),j=(d[0],d[1]),u="msg1"===r.messageFrom?"Default"===r.color?{color:"#ff8080"}:"Green"===r.color?{color:"#ffc14d"}:{color:"#ff8080"}:"Default"===r.color?{color:"#d9d9d9"}:"Green"===r.color?{color:"#ffc14d"}:{color:"#ff8080"},g=Object(J.useSpring)({from:{color:"#fff"},to:u,delay:500}),h=function(e){var t=/(https?:\/\/[^\s]+)/g,n=e.match(t);return{desc:e.replace(/&/g,"&").replace(t,(function(e){return" "})),url:n}},f=H(),p=f.user,m=f.token,O=function(e,t,n){var c,a,r={_id:e._id?e._id:e._doc._id,description:e.isTwitterFeed?e.payload:e.isCrawlerFeed?e.article.title:e.description,isTwitterFeed:"boolean"==typeof(null===e||void 0===e?void 0:e.isTwitterFeed)&&(null===e||void 0===e?void 0:e.isTwitterFeed),isCrawlerFeed:"boolean"==typeof(null===e||void 0===e?void 0:e.isCrawlerFeed)&&(null===e||void 0===e?void 0:e.isCrawlerFeed),isRedboxFeed:"boolean"==typeof(null===e||void 0===e?void 0:e.isRedboxFeed)&&(null===e||void 0===e?void 0:e.isRedboxFeed),createdAt:e.createdAt,category:e.color,topic:(null===e||void 0===e||null===(c=e._doc)||void 0===c?void 0:c.topic)?null===e||void 0===e||null===(a=e._doc)||void 0===a?void 0:a.topic:null===e||void 0===e?void 0:e.topic,link:e.isCrawlerFeed?e.article.link:""};i(!1),j(""),function(e,t,n){return fetch("".concat(P,"/save/news/").concat(e),{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json",Authorization:"Bearer ".concat(t)},body:JSON.stringify(n)}).then((function(e){return e.json()})).catch((function(e){return console.log(e)}))}(t,n,r).then((function(e){e.error?(j(e.error),i(!1),console.log("Error!")):i(!0)})).catch((function(e){i(!1),console.log("Error!"),j("Error")}))};return Object($.jsxs)(J.animated.td,{className:"Green"===r.color?"text__blink":"",style:(null===r||void 0===r?void 0:r.isCrawlerFeed)||(null===r||void 0===r?void 0:r.isTwitterFeed)?Object(y.a)(Object(y.a)({},g),{},{color:"#d9d9d9"}):Object(y.a)({},g),id:"grid",children:[(null===r||void 0===r?void 0:r.isTwitterFeed)&&Object($.jsxs)($.Fragment,{children:[Object($.jsx)(z.a,{style:{fontSize:"15px",color:"#0ddfff",marginRight:"3px"}}),(null===r||void 0===r||null===(t=r._doc)||void 0===t?void 0:t.topic)?null===r||void 0===r||null===(n=r._doc)||void 0===n?void 0:n.topic:null===r||void 0===r?void 0:r.topic]}),(null===r||void 0===r?void 0:r.isCrawlerFeed)&&Object($.jsx)("img",{src:K,className:"crawlerImage"}),(null===r||void 0===r?void 0:r.isTwitterFeed)?Object($.jsxs)("span",{style:{marginLeft:"5px"},children:[h(a).desc,h(a).url&&h(a).url.map((function(e){return Object($.jsx)("a",{href:e,className:"twitterLink",target:"_blank",children:e},e)}))]}):a,(null===r||void 0===r?void 0:r.isCrawlerFeed)&&Object($.jsx)("a",{href:r.article.link,className:"crawlerLink",target:"_blank",children:"Read"}),Object($.jsx)(Q.a,{className:"bookmark",style:{opacity:"0",fontSize:"17px",color:"#fff",marginLeft:"5px",cursor:"pointer",position:"relative",top:"4px"},onClick:function(){return O(r,p._id,m)}})]})})),ae=n(35),re=n(187),oe=n.n(re),se=n(111),ie=n.n(se),le=function(){return{top:"".concat(50,"%"),left:"".concat(50,"%"),transform:"translate(-".concat(50,"%, -").concat(50,"%)")}},de=function(e){var t=I(),n=Object(c.useState)(le),a=Object(b.a)(n,1)[0],r=H(),o=r.user,s=r.token,i=Object(c.useState)({redboxFeed:!0,crawlerFeed:!0,twitterFeed:!0}),l=Object(b.a)(i,2),d=l[0],j=l[1],u=Object(c.useState)(0),g=Object(b.a)(u,2),h=g[0],f=g[1],p=Object(c.useState)(1),m=Object(b.a)(p,2),O=m[0],R=m[1],A=Object(c.useState)(parseInt(o.searched)),B=Object(b.a)(A,2),L=B[0],Y=B[1],U=Object(c.useState)([]),G=Object(b.a)(U,2),W=G[0],X=G[1],J=Object(c.useState)({searchString:"",dateRangeFrom:q()().subtract(30,"days").format("YYYY-MM-DDTHH:mm"),dateRangeTo:q()().format("YYYY-MM-DDTHH:mm"),error:"",loading:!1,success:!1}),K=Object(b.a)(J,2),V=K[0],Q=K[1],Z=Object(c.useRef)(),ee=Object(c.useRef)(),te=Object(c.useRef)(),ne=V.searchString,re=V.dateRangeFrom,se=V.dateRangeTo,de=(V.error,V.loading);V.success;Object(c.useEffect)((function(){if(0===h)X([]);else{Q(Object(y.a)(Object(y.a)({},V),{},{error:!1,loading:!0}));var e={redboxFeed:d.redboxFeed,crawlerFeed:d.crawlerFeed,twitterFeed:d.twitterFeed,searchString:ne,dateRangeFrom:re,dateRangeTo:se};(function(e,t,n,c,a){return fetch("".concat(P,"/search/news/").concat(t,"/").concat(n,"/").concat(e),{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json",Authorization:"Bearer ".concat(c)},body:JSON.stringify(a)}).then((function(e){return e.json()})).catch((function(e){return console.log(e)}))})(o._id,15,h,s,e).then((function(e){e.error?Q(Object(y.a)(Object(y.a)({},V),{},{error:e.error,success:!1,loading:!1})):(Q(Object(y.a)(Object(y.a)({},V),{},{error:"",success:!0,loading:!1})),X((function(t){return Object(v.a)(new Set([].concat(Object(v.a)(t),Object(v.a)(e.data))))})),Y(e.searched))})).catch((function(e){console.log("Error in pagination")}))}}),[o._id,s,h,O]);Object(c.useEffect)((function(){console.log(h)}),[h]);var je=function(e){j(Object(y.a)(Object(y.a)({},d),{},Object(x.a)({},e.target.name,e.target.checked)))},be=function(e){return function(t){var n=t.target.value;Q(Object(y.a)(Object(y.a)({},V),{},Object(x.a)({error:!1},e,n)))}},ue=function(e){e.preventDefault(),Q(Object(y.a)(Object(y.a)({},V),{},{error:!1,loading:!0}));d.redboxFeed,d.crawlerFeed,d.twitterFeed;X([]),1===h?R((function(e){return e+1})):f(1)},ge=function(){1!==h&&(X([]),f(1))};return Object($.jsxs)("div",{style:a,className:t.paper,children:[Object($.jsx)(w.a,{onClick:function(){X([]),Q(Object(y.a)(Object(y.a)({},V),{},{error:"",loading:!1,searchString:""})),e()},className:t.closeBtn,children:Object($.jsx)(D.a,{})}),Object($.jsxs)("div",{className:t.modalContent,children:[Object($.jsx)("form",{onSubmit:ue,children:Object($.jsx)(S.a,{container:!0,justify:"center",children:Object($.jsxs)(S.a,{item:!0,xs:8,className:t.container,children:[Object($.jsx)(C.a,{variant:"contained",className:t.button,onClick:function(){Z.current.classList.toggle("openBox")},startIcon:Object($.jsx)(N.a,{style:{fontSize:"14px"},className:"fas fa-filter ".concat(t.filterIcon)}),children:"Filter"}),Object($.jsx)("input",{type:"text",className:t.inputText,value:ne,name:"searchString",onCh
1ange:be("searchString"),placeholder:"Minimum 3 words. Remaining serach result's count for today : ".concat(1e3-L)}),Object($.jsx)(w.a,{size:"small",className:t.deleteBtn,onClick:function(){X([]),Q({searchString:"",dateRangeFrom:q()().subtract(30,"days").format("YYYY-MM-DDTHH:mm"),dateRangeTo:q()().format("YYYY-MM-DDTHH:mm"),error:"",loading:!1,success:!1})},style:{position:"relative",left:"-33px",top:"4px"},children:Object($.jsx)(ie.a,{className:t.deleteIcon})})]})})}),Object($.jsx)(S.a,{container:!0,justify:"center",style:{display:"none"},ref:Z,children:Object($.jsxs)(S.a,{item:!0,xs:8,className:t.searchBoxcontainer,children:[Object($.jsxs)("table",{children:[Object($.jsxs)("tr",{className:t.tableRow,children:[Object($.jsx)("td",{children:Object($.jsx)(C.a,{variant:"contained",color:"default",startIcon:Object($.jsx)(E.a,{}),className:t.searchBoxBtn,children:"Redbox Feeds"})}),Object($.jsx)("td",{children:Object($.jsx)(k.a,{color:"secondary",name:"redboxFeed",onChange:je,checked:d.redboxFeed})})]}),Object($.jsxs)("tr",{className:t.tableRow,children:[Object($.jsx)("td",{children:Object($.jsx)(C.a,{variant:"contained",color:"default",startIcon:Object($.jsx)(M.a,{}),className:t.searchBoxBtn,children:"Crawler Feeds"})}),Object($.jsx)("td",{children:Object($.jsx)(k.a,{color:"secondary",name:"crawlerFeed",onChange:je,checked:d.crawlerFeed})})]}),Object($.jsxs)("tr",{className:t.tableRow,children:[Object($.jsx)("td",{children:Object($.jsx)(C.a,{variant:"contained",color:"default",startIcon:Object($.jsx)(z.a,{}),className:t.searchBoxBtn,children:"Twitter Feeds"})}),Object($.jsx)("td",{children:Object($.jsx)(k.a,{color:"secondary",name:"twitterFeed",onChange:je,checked:d.twitterFeed})})]}),Object($.jsxs)("tr",{className:t.tableRow,children:[Object($.jsx)("td",{children:Object($.jsx)(C.a,{variant:"contained",color:"default",startIcon:Object($.jsx)(_.a,{}),className:t.searchBoxBtn,children:"Date Range"})}),Object($.jsxs)("td",{children:[Object($.jsx)(T.a,{type:"datetime-local",style:{marginLeft:"2rem"},label:"From",size:"small",variant:"outlined",className:t.textField,onChange:be("dateRangeFrom"),value:re,InputLabelProps:{shrink:!0}}),Object($.jsx)(T.a,{type:"datetime-local",onChange:be("dateRangeTo"),style:{marginLeft:"20px"},label:"To",size:"small",variant:"outlined",className:t.textField,value:se,InputLabelProps:{shrink:!0}})]})]})]}),Object($.jsx)(C.a,{style:{float:"right"},variant:"contained",color:"secondary",onClick:function(){X([]),Q({searchString:"",dateRangeFrom:q()().subtract(30,"days").format("YYYY-MM-DDTHH:mm"),dateRangeTo:q()().format("YYYY-MM-DDTHH:mm"),error:"",loading:!1,success:!1}),j({redboxFeed:!0,crawlerFeed:!0,twitterFeed:!0})},children:"Reset"}),Object($.jsx)(C.a,{style:{marginRight:"5px",float:"right",color:"#fff"},variant:"contained",color:"primary",onClick:ue,children:"Apply"})]})})]}),Object($.jsxs)("div",{children:[de&&Object($.jsx)("div",{className:t.loader,children:Object($.jsx)(F.a,{size:40,className:t.loaderIcon})}),Object($.jsx)("table",{className:t.searchContainer,id:"scrollableSearchBoxContainer",ref:ee,onScroll:function(){var e=ee.current,t=e.scrollHeight,n=e.clientHeight,c=e.scrollTop,a=t-n;te.current.style.display=c/a>.1?"inline":"none"},children:Object($.jsx)(ae.a,{dataLength:W.length,next:function(){return f(h+1)},hasMore:!0,scrollableTarget:"scrollableSearchBoxContainer",children:W.map((function(e){return Object($.jsxs)("tr",{className:t.tableRowSearch,children:[Object($.jsx)("td",{style:(null===e||void 0===e?void 0:e.isCrawlerFeed)?{paddingRight:"10px",color:"#d9d9d9"}:{paddingRight:"10px"},children:q()(e.createdAt).calendar()}),Object($.jsx)(ce,{className:t.tableCellDesc,news:e,value:e.isTwitterFeed?e.payload:e.isCrawlerFeed?e.article.title:e.description})]},e._id)}))})}),Object($.jsx)(w.a,{onClick:function(){ee.current.scrollTo({top:0,behavior:"smooth"}),ge()},ref:te,style:{display:"none",color:"#fff",float:"right",marginTop:"10px"},children:Object($.jsx)(oe.a,{})})]})]})},je=(n(252),Object(c.createContext)()),be=function(e){var t=e.children,n=Object(c.useState)(""),a=Object(b.a)(n,2),r=a[
10],o=a[1];return Object($.jsx)(je.Provider,{value:[r,o],children:t})},ue=a.a.createContext(),ge=Object(f.a)((function(e){return{root:{background:"#000"},logoIcon:{flexGrow:1},logo:{width:"150px",marginLeft:"0.6rem"},btn:{marginRight:"10px",color:"#fff"}}})),he=Object(i.h)((function(e){var t=e.history,n=e.setWidgetShow,a=ge(),r=Object(c.useState)(!1),o=Object(b.a)(r,2),s=o[0],i=o[1],l=Object(c.useContext)(je),d=Object(b.a)(l,2),j=d[0],u=(d[1],Object(c.useContext)(ue)),g=function(){i(!1),n(!0)},h=Object($.jsx)("img",{src:"https://i.ibb.co/3WvpRDm/logo.png",alt:"",className:a.logo});return Object($.jsxs)(p.a,{className:a.root,children:[Object($.jsxs)(m.a,{variant:"dense",children:[Object($.jsx)("div",{style:{textDecoration:"none",margin:"0"},className:a.logoIcon,children:h}),Object($.jsxs)("div",{children:[H()&&Object($.jsxs)("button",{className:"ui tiny inverted animated right floated button",style:{width:"70px"},onClick:function(){W((function(){clearInterval(j),u.disconnect(),t.push("/signin")}))},children:[Object($.jsx)("div",{className:"hidden content",children:"Signout"}),Object($.jsx)("div",{className:"visible content",children:Object($.jsx)("i",{className:"fas fa-sign-out-alt",style:{fontSize:"12px",margin:"0px"}})})]}),Object($.jsxs)("button",{className:"ui tiny inverted animated right floated button",style:{width:"70px"},onClick:function(){i(!0),n(!1)},children:[Object($.jsx)("div",{className:"hidden content",children:"Search"}),Object($.jsx)("div",{className:"visible content",children:Object($.jsx)("i",{className:"fas fa-search",style:{fontSize:"12px",margin:"0px"}})})]})]})]}),Object($.jsx)(O.a,{open:s,onClose:g,"aria-labelledby":"simple-modal-title","aria-describedby":"simple-modal-description",children:de(g)})]})})),fe=n(99),pe=Object(f.a)((function(e){return{root:{marginTop:"3rem",marginBottom:"1rem",padding:"0.5rem 0.5rem",height:"89vh",display:"grid",gridTemplateColumns:"repeat(3, minmax(0, 1fr))",gap:"0.5rem","@media only screen and (max-width: 992px)":{gridTemplateColumns:"repeat(1, minmax(0, 1fr))",height:"auto"},"@media only screen and (max-height: 2880px)":{height:"96.5vh"},"@media only screen and (max-height: 1920px)":{height:"95vh"},"@media only screen and (max-height: 1800px)":{height:"94.5vh"},"@media only screen and (max-height: 1587px)":{height:"93.5vh"},"@media only screen and (max-height: 1080px)":{height:"90.5vh"},"@media only screen and (max-height: 969px)":{height:"89vh"},"@media only screen and (max-height: 950px)":{height:"86vh"},"@media only screen and (max-height: 900px)":{height:"85vh"},"@media only screen and (max-height: 870px)":{height:"87vh"},"@media only screen and (max-height: 754px)":{height:"85vh"},"@media only screen and (max-height: 720px)":{height:"84vh"},"@media only screen and (max-height: 667px)":{height:"83vh"},"@media only screen and (max-height: 625px)":{height:"82vh"}},box:{backgroundColor:"#000",borderRadius:"5px",position:"relative"},desc:{margin:"10px",color:"#fff",overflowY:"scroll",position:"relative",height:"37vh","@media only screen and (max-height: 2880px)":{height:"45vh"},"@media only screen and (max-height: 1920px)":{height:"42vh"},"@media only screen and (max-height: 1800px)":{height:"42vh"},"@media only screen and (max-height: 1080px)":{height:"38vh"},"@media only screen and (max-height: 950px)":{height:"38.5vh"},"@media only screen and (max-height: 900px)":{height:"38vh"},"@media only screen and (max-height: 870px)":{height:"35vh"},"@media only screen and (max-height: 754px)":{height:"33.5vh"},"@media only screen and (max-height: 720px)":{height:"32.5vh"}},scrollToTopBtnStyle:{fontSize:"1.3rem",float:"right",color:"rgb(255, 193, 77)"},allNewsDesc:{margin:"10px",color:"#fff",overflowY:"scroll",height:"82vh","@media only screen and (max-height: 2880px)":{height:"90vh"},"@media only screen and (max-height: 1920px)":{height:"90vh"},"@media only screen and (max-height: 1800px)":{height:"89vh"},"@media only screen and (max-height: 1080px)":{height:"85vh"},"@media only screen and (max-height: 969px)":{height:"83vh"},"@media only screen and (max-height: 950px)":{height:"82vh"},"@media only screen and (max-height: 900px)":{height:"81vh"},"@media only screen and (max-height: 870px)":{height:"80vh"},"@media only screen and (max-height: 754px)":{height:"78.5vh"},"@media only screen and (max-height: 720px)":{height:"77.5vh"},"@media only screen and (max-height: 667px)":{height:"76vh"},"@media only screen and (max-height: 625px)":{height:"74vh"}},title:{color:"#808080",margin:"10px",textTransform:"uppercase",fontFamily:"Roboto",fontWeight:"bold"},one:{gridRow:"1 / 2",gridColumn:"1 / 2","@media only screen and (max-width: 992px)":{gridColumn:"1 / 2",gridRow:"1 / 2",display:"none"}}
1,two:{gridRow:"1 / 3",gridColumn:"2 / 3","@media only screen and (max-width: 992px)":{gridColumn:"1 / 2",gridRow:"2 / 3"}},three:{gridRow:"1 / 2",gridColumn:"3 / 4","@media only screen and (max-width: 992px)":{gridColumn:"1 / 2",gridRow:"3 / 4",display:"none"}},four:{gridRow:"2 / 3",gridColumn:"1 / 2","@media only screen and (max-width: 992px)":{gridColumn:"1 / 2",gridRow:"4 / 5",display:"none"}},five:{gridRow:"2 / 3",gridColumn:"3 / 4","@media only screen and (max-width: 992px)":{gridColumn:"1 / 2",gridRow:"5 / 6",display:"none"}},tableRow:{color:"#d9d9d9",padding:"2px 2px 6px 5px",fontSize:"14px",fontFamily:"Roboto",display:"flex",alignItems:"flex-start",border:"0","@media only screen and (max-height: 2880px)":{fontSize:"25px"},"@media only screen and (max-height: 1920px)":{fontSize:"20px"},"@media only screen and (max-height: 1800px)":{fontSize:"20px"},"@media only screen and (max-height: 1587px)":{fontSize:"20px"},"@media only screen and (max-height: 950px)":{fontSize:"14px"}},tableCellDesc:{color:"rgb(255, 128, 128)"},backdrop:{zIndex:e.zIndex.drawer+1,color:"#333"},readMore:{color:"#ff9800",marginLeft:"5px",textDecoration:"none"},rssImage:{width:"13px",marginRight:"5px",paddingTop:"2px",height:"13px"},dateDivider:{fontFamily:"Roboto",fontSize:"13px",fontWeight:"500",textTransform:"uppercase",display:"grid",gridTemplateColumns:"35% auto 35%",textAlign:"center",gap:"0.5rem",marginBottom:"1rem"},dateDividerLine:{borderBottom:"1px solid #333"},loader:{color:"#fff",position:"absolute",backgroundColor:"rgba(0,0,0,.85)",zIndex:"55",opacity:"0.5",width:"100%",height:"100%",display:"flex",justifyContent:"center",alignItems:"center"},loaderIcon:{color:"#fff"}}})),me=Object(c.createContext)(),Oe=function(e){var t=e.children,n=Object(c.useState)(!1),a=Object(b.a)(n,2),r=a[0],o=a[1];return Object($.jsx)(me.Provider,{value:[r,o],children:t})}
1,xe=n.p+"static/media/notification_sound.cadf8a61.mp3",ve=function(e,t,n,c){return fetch("".concat(P,"/news/all/").concat(n,"/").concat(c,"/").concat(e),{method:"GET",headers:{Accept:"application/json","Content-Type":"application/json",Authorization:"Bearer ".concat(t)}}).then((function(e){return e.json()})).catch((function(e){return console.log(e)}))},ye=function(e,t,n,c){return fetch("".concat(P,"/news/global/").concat(n,"/").concat(c,"/").concat(e),{method:"GET",headers:{Accept:"application/json","Content-Type":"application/json",Authorization:"Bearer ".concat(t)}}).then((function(e){return e.json()})).catch((function(e){return console.log(e)}))},we=function(e,t,n,c){return fetch("".concat(P,"/news/block_details/").concat(n,"/").concat(c,"/").concat(e),{method:"GET",headers:{Accept:"application/json","Content-Type":"application/json",Authorization:"Bearer ".concat(t)}}).then((function(e){return e.json()})).catch((function(e){return console.log(e)}))},Se=function(e,t,n,c){return fetch("".concat(P,"/news/commodities/").concat(n,"/").concat(c,"/").concat(e),{method:"GET",headers:{Accept:"application/json","Content-Type":"application/json",Authorization:"Bearer ".concat(t)}}).then((function(e){return e.json()})).catch((function(e){return console.log(e)}))},Ce=function(e,t,n,c){return fetch("".concat(P,"/news/fixed_income/").concat(n,"/").concat(c,"/").concat(e),{method:"GET",headers:{Accept:"application/json","Content-Type":"application/json",Authorization:"Bearer ".concat(t)}}).then((function(e){return e.json()})).catch((function(e){return console.log(e)}))},Ne=Object(c.createContext)(),ke=function(e){var t=e.children,n=Object(c.useState)(!1),a=Object(b.a)(n,2),r=a[0],o=a[1];return Object($.jsx)(Ne.Provider,{value:[r,o],children:t})},Te=n(965),Fe=n(961);function Re(e){return Object($.jsx)(Fe.a,Object(y.a)({elevation:6,variant:"filled"},e))}var De=function(e){var t=e.message,n=(e.isBrifCase,Object(c.useState)(!0)),a=Object(b.a)(n,2),r=a[0],o=a[1],s=function(e,t){"clickaway"!==t&&o(!1)};return Object($.jsx)("div",{children:Object($.jsx)(Te.a,{anchorOrigin:{vertical:"bottom",horizontal:"left"},open:r,onClose:s,autoHideDuration:2e3,children:Object($.jsx)(Re,{onClose:s,severity:"success",children:t})})})},Ie=function(e){var t=e.message,n=(e.isBrifCase,Object(c.useState)(!0)),a=Object(b.a)(n,2),r=a[0],o=a[1],s=function(e,t){"clickaway"!==t&&o(!1)};return Object($.jsx)("div",{children:Object($.jsx)(Te.a,{anchorOrigin:{vertical:"bottom",horizontal:"left"},open:r,autoHideDuration:2e3,onClose:s,children:Object($.jsx)(Re,{onClose:s,severity:"error",children:t})})})},Ae=function(e){var t=e.message,n=Object(c.useState)(!0),a=Object(b.a)(n,2),r=a[0],o=a[1],s=function(e,t){"clickaway"!==t&&o(!1)};return Object($.jsx)("div",{children:Object($.jsx)(Te.a,{anchorOrigin:{vertical:"top",horizontal:"center"},open:r,autoHideDuration:6e3,onClose:s,message:t,action:Object($.jsx)($.Fragment,{children:Object($.jsx)(w.a,{size:"small","aria-label":"close",color:"inherit",onClick:s,children:Object($.jsx)(D.a,{fontSize:"small"})})})})})},Ee=Object(c.createContext)(),Be=function(e){var t=e.children,n=Object(c.useState)({tFeeds:!1,cFeeds:!1,rFeeds:!1,error:"",loading:!1,success:!1}),a=Object(b.a)(n,2),r=a[0],o=a[1];return Object($.jsx)(Ee.Provider,{value:[r,o],children:t})},ze=Object(c.createContext)(),Le=function(e){var t=e.children,n=Object(c.useState)(!1),a=Object(b.a)(n,2),r=a[0],o=a[1];return Object($.jsx)(ze.Provider,{value:[r,o],children:t})},Me=function(){var e=pe(),t=Object(c.useState)([]),n=Object(b.a)(t,2),a=n[0],r=n[1],o=Object(c.useState)(!0),s=Object(b.a)(o,2),i=s[0],l=s[1],u=Object(c.useState)(!1),g=Object(b.a)(u,2),h=g[0],f=g[1],p=Object(c.useState)(1),m=Object(b.a)(p,2),O=m[0],x=m[1],y=Object(c.useRef)(),w=Object(c.useRef)(),S=Object(c.useRef)(),C=Object(c.useRef)(),N=H(),k=N.user,T=N.token,R=Object(c.useContext)(me),D=Object(b.a)(R,2),I=D[0],A=D[1],E=Object(c.useContext)(Ne),B=Object(b.a)(E,2),z=B[0],L=(B[1],Object(c.useContext)(Z)),M=Object(b.a)(L,2),Y=M[0],_=(M[1],Object(c.useContext)(te)),P=Object(b.a)(_,2),U=P[0],G=(P[1],Object(c.useContext)(ue)),W=Object(c.useContext)(Ee),X=Object(b.a)(W,2),J=X[0],K=(X[1],Object(c.useContext)(ze)),V=Object(b.a)(K,2),Q=V[0];V[1];Object(c.useEffect)((function(){!0===I&&(w.current.play(),setTimeout((function(){A(!1)}),3e3))}),[I]);Object(c.useEffect)((function(){return G.on("newGlobal",function(){var e=Object(j.a)(d.a.mark((function e(t){return d.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:t.isRedboxFeed?J.rFeeds&&("Green"===t.color&&A(!0),r((function(e){return Object(v.a)(new Set([t].concat(Object(v.a)(e))))}))):t.isCrawlerFeed?J.cFeeds&&r((function(e){return Object(v.a)(new Set([t].concat(Object(v.a)(e))))})):t.isTwitterFeed&&J.tFeeds&&r((function(e){return Object(v.a)(new Set([t].concat(Object(v.a)(e))))}));case 1:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()),G.on("deletedGlobal",(function(e){ve(k._id,T,39,O).then((function(e){e.error?f(e.error):(x(1),r(Object(v.a)(new Set(Object(v.a)(e.results)))))})).catch((function(e){f("Not able to fetch")}))}
1)),function(){return G.off("newGlobal")}}),[k._id,T,k.email,G,J]),Object(c.useEffect)((function(){return G.on("newsAudioStream",function(){var e=Object(j.a)(d.a.mark((function e(t){var n,c,a,r;return d.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:Q&&J.rFeeds&&(n=new Uint8Array(t),c=n.buffer,a=new Blob([c]),r=URL.createObjectURL(a),S.current.paused?(console.log("FDFDF"),S.current.src=r,S.current.load(),S.current.play()):S.current.addEventListener("ended",(function(e){S.current.src=r,S.current.load(),S.current.play()}),{once:!0}));case 1:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()),function(){return G.off("newsAudioStream")}}),[J.rFeeds,Q]),Object(c.useEffect)((function(){l(!0),ve(k._id,T,39,O).then((function(e){e.error?(f(e.error),l(!1)):(r(1===O?e.results:function(t){return Object(v.a)(new Set([].concat(Object(v.a)(t),Object(v.a)(e.results))))}),l(!1))})).catch((function(e){l(!1),f("Not able to fetch")}))}),[k._id,T,O]),Object(c.useEffect)((function(){z&&(x(1),l(!0),ve(k._id,T,39,O).then((function(e){e.error?(f(e.error),l(!1)):(r(e.results),l(!1))})).catch((function(e){l(!1),f("Not able to fetch")})))}),[z]);var ee,ne;return Object($.jsx)($.Fragment,{children:Object($.jsxs)("div",{className:"".concat(e.box," ").concat(e.two),children:[i&&Object($.jsx)("div",{className:e.loader,children:Object($.jsx)(F.a,{size:40,className:e.loaderIcon})}),Y&&Object($.jsx)(De,{message:"Saved!"}),U&&Object($.jsx)(Ie,{message:U}),Object($.jsx)("audio",{src:xe,ref:w}),Object($.jsx)("audio",{ref:S}),Object($.jsxs)(fe.a,{color:"secondary",className:e.title,variant:"body2",children:["All News",Object($.jsx)("i",{onClick:function(){y.current.scrollTo({top:0,behavior:"smooth"}),r([]),x(0)},ref:C,className:"fas fa-angle-up ".concat(e.scrollToTopBtnStyle),style:{display:"none"}})]}),Object($.jsx)("div",{className:"".concat(e.allNewsDesc),ref:y,onScroll:function(){var e=y.current,t=e.scrollHeight,n=e.clientHeight,c=e.scrollTop,a=t-n;C.current.style.display=c/a>.1?"inline":"none"},id:"scrollableAllNewsDash",children:Object($.jsxs)(ae.a,{dataLength:a.length,next:function(){return x(O+1)},hasMore:!0,scrollableTarget:"scrollableAllNewsDash",children:[(ee=a,ne="_id",Object(v.a)(new Map(ee.map((function(e){return[e[ne],e]}))).values())).map((function(t,n,a){return Object($.jsxs)(c.Fragment,{children:[n>0?q()(t.createdAt).format("MMM DD, YYYY")!==q()(a[n-1].createdAt).format("MMM DD, YYYY")&&Object($.jsxs)("div",{className:e.dateDivider,children:[Object($.jsx)("div",{className:e.dateDividerLine}),Object($.jsx)("div",{children:q()(t.createdAt).format("MMM DD, YYYY")}),Object($.jsx)("div",{className:e.dateDividerLine})]}):"",Object($.jsxs)("tr",{className:e.tableRow,children:[Object($.jsx)("td",{style:(null===t||void 0===t?void 0:t.isCrawlerFeed)?{marginRight:"9px",color:"#d9d9d9"}:{marginRight:"9px"},children:q()(t.createdAt).format("HH:mm:ss")}),Object($.jsx)(ce,{className:e.tableCellDesc,news:t,value:t.isTwitterFeed?t.payload:t.isCrawlerFeed?t.article.title:t.description})]})]},t._id?t._id:t._doc._id)})),Object($.jsx)("div",{children:h&&"Error"})]})})]})})},Ye=function(){var e=pe(),t=Object(c.useContext)(Ne),n=Object(b.a)(t,2),a=n[0],r=(n[1],Object(c.useState)([])),o=Object(b.a)(r,2),s=o[0],i=o[1],l=Object(c.useState)(!0),u=Object(b.a)(l,2),g=u[0],h=u[1],f=Object(c.useState)(!1),p=Object(b.a)(f,2),m=p[0],O=p[1],x=Object(c.useState)(1),y=Object(b.a)(x,2),w=y[0],S=y[1],C=Object(c.useRef)(),N=Object(c.useRef)(),k=H(),T=k.user,R=k.token,D=Object(c.useContext)(ue),I=Object(c.useContext)(Ee),A=Object(b.a)(I,2),E=A[0];A[1];Object(c.useEffect)((function(){return D.on("newGlobal",function(){var e=Object(j.a)(d.a.mark((function e(t){return d.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:t.isRedboxFeed&&"Block Details"===t.category&&E.rFeeds&&i((function(e){return Object(v.a)(new Set([t].concat(Object(v.a)(e))))}));case 1:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()),D.on("deletedGlobal",(function(e){we(T._id,R,29,w).then((function(e){e.error?O(e.error):(S(1),i(Object(v.a)(new Set(Object(v.a)(e)))))})).catch((function(e){O("Not able to fetch")}))}
1)),function(){return D.off("newGlobal")}}),[T._id,R,T.email,D,E]),Object(c.useEffect)((function(){h(!0),we(T._id,R,29,w).then((function(e){e.error?(O(e.error),h(!1)):(i(1===w?e:function(t){return Object(v.a)(new Set([].concat(Object(v.a)(t),Object(v.a)(e))))}),h(!1))})).catch((function(e){h(!1),O("Not able to fetch")}))}),[T._id,R,w]),Object(c.useEffect)((function(){a&&(S(1),h(!0),we(T._id,R,29,w).then((function(e){e.error?(O(e.error),h(!1)):(i(e),h(!1))})).catch((function(e){h(!1),O("Not able to fetch")})))}),[a]);var B,z;return Object($.jsx)($.Fragment,{children:Object($.jsxs)("div",{className:"".concat(e.box," ").concat(e.three),children:[g&&Object($.jsx)("div",{className:e.loader,children:Object($.jsx)(F.a,{size:40,className:e.loaderIcon})}),Object($.jsxs)(fe.a,{color:"secondary",className:e.title,variant:"body2",children:["ANALYSIS",Object($.jsx)("i",{onClick:function(){C.current.scrollTo({top:0,behavior:"smooth"}),i([]),S(0)},ref:N,className:"fas fa-angle-up ".concat(e.scrollToTopBtnStyle),style:{display:"none"}})]}),Object($.jsx)("div",{className:e.desc,ref:C,onScroll:function(){var e=C.current,t=e.scrollHeight,n=e.clientHeight,c=e.scrollTop,a=t-n;N.current.style.display=c/a>.1?"inline":"none"},id:"scrollableAnalysisBox",children:Object($.jsxs)(ae.a,{dataLength:s.length,next:function(){return S(w+1)},hasMore:!0,scrollableTarget:"scrollableAnalysisBox",children:[(B=s,z="_id",Object(v.a)(new Map(B.map((function(e){return[e[z],e]}))).values())).map((function(t,n,a){return Object($.jsxs)(c.Fragment,{children:[n>0?q()(t.createdAt).format("MMM DD, YYYY")!==q()(a[n-1].createdAt).format("MMM DD, YYYY")&&Object($.jsxs)("div",{className:e.dateDivider,children:[Object($.jsx)("div",{className:e.dateDividerLine}),Object($.jsx)("div",{children:q()(t.createdAt).format("MMM DD, YYYY")}),Object($.jsx)("div",{className:e.dateDividerLine})]}):"",Object($.jsxs)("tr",{className:e.tableRow,children:[Object($.jsx)("td",{style:(null===t||void 0===t?void 0:t.isCrawlerFeed)?{marginRight:"9px",color:"#d9d9d9"}:{marginRight:"9px"},children:q()(t.createdAt).format("HH:mm:ss")}),Object($.jsx)(ce,{className:e.tableCellDesc,news:t,value:t.isTwitterFeed?t.payload:t.isCrawlerFeed?t.article.title:t.description})]})]},t._id)})),Object($.jsx)("div",{children:m&&"Error"})]})})]})})},_e=function(){var e=pe(),t=Object(c.useState)([]),n=Object(b.a)(t,2),a=n[0],r=n[1],o=Object(c.useState)(!1),s=Object(b.a)(o,2),i=s[0],l=s[1],u=Object(c.useState)(!1),g=Object(b.a)(u,2),h=g[0],f=g[1],p=Object(c.useState)(1),m=Object(b.a)(p,2),O=m[0],x=m[1],y=Object(c.useRef)(),w=Object(c.useRef)(),S=H(),C=S.user,N=S.token,k=Object(c.useContext)(Ne),T=Object(b.a)(k,2),R=T[0],D=(T[1],Object(c.useContext)(ue)),I=Object(c.useContext)(Ee),A=Object(b.a)(I,2),E=A[0];A[1];Object(c.useEffect)((function(){return D.on("newGlobal",function(){var e=Object(j.a)(d.a.mark((function e(t){return d.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:t.isRedboxFeed&&"Commodities"===t.category?E.rFeeds&&r((function(e){return Object(v.a)(new Set([t].concat(Object(v.a)(e))))})):t.isCrawlerFeed&&t.commodities&&E.cFeeds&&r((function(e){return Object(v.a)(new Set([t].concat(Object(v.a)(e))))}));case 1:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()),D.on("deletedGlobal",(function(e){Se(C._id,N,29,O).then((function(e){e.error?f(e.error):(x(1),r(Object(v.a)(new Set(Object(v.a)(e)))))})).catch((function(e){f("Not able to fetch")}))})),function(){return D.off("newGlobal")}}),[C._id,N,C.email,D,E]),Object(c.useEffect)((function(){l(!0),Se(C._id,N,29,O).then((function(e){e.error?(f(e.error),l(!1)):(r(1===O?e:function(t){return Object(v.a)(new Set([].concat(Object(v.a)(t),Object(v.a)(e))))}),l(!1))})).catch((function(e){l(!1),f("Not able to fetch")}))}),[C._id,N,O]),Object(c.useEffect)((function(){R&&(x(1),l(!0),Se(C._id,N,29,O).then((function(e){e.error?(f(e.error),l(!1)):(r(e),l(!1))})).catch((function(e){l(!1),f("Not able to fetch")})))}),[R]);var B,z;return Object($.jsx)($.Fragment,{children:Object($.jsxs)("div",{className:"".concat(e.box," ").concat(e.four),children:[i&&Object($.jsx)("div",{className:e.loader,children:Object($.jsx)(F.a,{size:40,className:e.loaderIcon})}),Object($.jsxs)(fe.a,{color:"secondary",className:e.title,variant:"body2",children:["COMMODITIES",Object($.jsx)("i",{onClick:function(){y.current.scrollTo({top:0,behavior:"smooth"}),r([]),x(0)},ref:w,className:"fas fa-angle-up ".concat(e.scrollToTopBtnStyle),style:{display:"none"}})]}),Object($.jsx)("div",{className:e.desc,ref:y,onScroll:function(){var e=y.current,t=e.scrollHeight,n=e.clientHeight,c=e.scrollTop,a=t-n;w.current.style.display=c/a>.1?"inline":"none"},id:"scrollableComBox",children:Object($.jsxs)(ae.a,{dataLength:a.length,next:function(){return x(O+1)},hasMore:!0,scrollableTarget:"scrollableComBox",children:[(B=a,z="_id",Object(v.a)(new Map(B.map((function(e){return[e[z],e]}
1))).values())).map((function(t,n,a){return Object($.jsxs)(c.Fragment,{children:[n>0?q()(t.createdAt).format("MMM DD, YYYY")!==q()(a[n-1].createdAt).format("MMM DD, YYYY")&&Object($.jsxs)("div",{className:e.dateDivider,children:[Object($.jsx)("div",{className:e.dateDividerLine}),Object($.jsx)("div",{children:q()(t.createdAt).format("MMM DD, YYYY")}),Object($.jsx)("div",{className:e.dateDividerLine})]}):"",Object($.jsxs)("tr",{className:e.tableRow,children:[Object($.jsx)("td",{style:(null===t||void 0===t?void 0:t.isCrawlerFeed)?{marginRight:"9px",color:"#d9d9d9"}:{marginRight:"9px"},children:q()(t.createdAt).format("HH:mm:ss")}),Object($.jsx)(ce,{className:e.tableCellDesc,news:t,value:t.isTwitterFeed?t.payload:t.isCrawlerFeed?t.article.title:t.description})]})]},t._id)})),Object($.jsx)("div",{children:h&&"Error"})]})})]})})},Pe=n(968),Ue=n(940),Ge=n(964),We=n(192),He=n.n(We),Xe=n(115),qe=n.n(Xe),Je=n(966),Ke=n(967),Ve=n(116),Qe=n.n(Ve),$e=n(939),Ze=n(114),et=n.n(Ze),tt=Object(c.createContext)(),nt=function(e){var t=e.children,n=Object(c.useState)({tFeeds:!0,cFeeds:!0,rFeeds:!0}),a=Object(b.a)(n,2),r=a[0],o=a[1];return Object($.jsx)(tt.Provider,{value:[r,o],children:t})},ct=function(){return{top:"".concat(50,"%"),left:"".concat(50,"%"),transform:"translate(-".concat(50,"%, -").concat(50,"%)")}},at=Object(f.a)((function(e){return{chipContainer:{display:"flex",justifyContent:"flex-start",flexWrap:"wrap","& > *":{margin:e.spacing(.5),color:"#000"}},paper:{position:"absolute",width:"50%",backgroundColor:e.palette.background.paper,boxShadow:e.shadows[5],padding:e.spacing(2,4,3),borderRadius:"4px"},button:{margin:"1rem 10px 0 0",color:"#fff"},settingBoxcontainer:{margin:"1rem 0 0 0"},loaderStyle:{float:"right"},email:{fontWeight:"bold"},avatarStyle:{float:"right",width:e.spacing(4),height:e.spacing(4),color:e.palette.getContrastText($e.a[500]),backgroundColor:et.a[500],fontSize:"15px"},heading:{color:"#000",borderRadius:"25px"},switchLabelBtn:{width:"155px",justifyContent:"flex-start",textTransform:"capitalize",backgroundColor:"#e0e0e0",boxShadow:"none","&:hover":{backgroundColor:"#e0e0e0",boxShadow:"none"}}}})),rt=function(e,t){var n=at(),a=Object(c.useState)(ct),r=Object(b.a)(a,1)[0],o=H(),s=o.user,l=o.token,u=Object(c.useContext)(Ee),g=Object(b.a)(u,2),h=g[0],f=g[1],p=Object(c.useContext)(Ne),m=Object(b.a)(p,2),O=(m[0],m[1]),v=Object(c.useState)(""),w=Object(b.a)(v,2),N=w[0],T=w[1],R=Object(c.useContext)(tt),I=Object(b.a)(R,2),A=I[0],B=I[1],L=h.tFeeds,Y=h.cFeeds,_=h.rFeeds,U=h.error,G=h.loading,W=h.success,X=Object(i.g)(),q=function(e){f(Object(y.a)(Object(y.a)({},h),{},Object(x.a)({},e.target.name,e.target.checked)))};Object(c.useEffect)((function(){W&&setTimeout(Object(j.a)(d.a.mark((function e(){return d.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,f(Object(y.a)(Object(y.a)({},h),{},{success:!1}));case 2:case"end":return e.stop()}}),e)}))),3e3)}),[W]),Object(c.useEffect)((function(){J(s._id,l)}),[s._id,l,t]);var J=function(e,t){(function(e,t){return fetch("".concat(P,"/get/user/info/").concat(e),{method:"GET",headers:{Accept:"application/json",Authorization:"Bearer ".concat(t)}}).then((function(e){return e.json()})).catch((function(e){return console.log(e)}))})(e,t).then((function(e){var t,n,c;(null===e||void 0===e?void 0:e.error)?f(Object(y.a)(Object(y.a)({},h),{},{error:e.error,loading:!1})):(f(Object(y.a)(Object(y.a)({},h),{},{tFeeds:null===e||void 0===e||null===(t=e.settings)||void 0===t?void 0:t.tFeeds,cFeeds:null===e||void 0===e||null===(n=e.settings)||void 0===n?void 0:n.cFeeds,rFeeds:null===e||void 0===e||null===(c=e.settings)||void 0===c?void 0:c.rFeeds,error:"",loading:!1,success:!1})),T(e))}))};return Object($.jsx)($.Fragment,{children:Object($.jsxs)("div",{style:r,className:n.paper,children:[U&&Object($.jsx)(Ae,{message:U}),W&&Object($.jsx)(Ae,{message:"Settings saved!"}),Object($.jsxs)(fe.a,{variant:"h5",children:[Object($.jsx)(C.a,{variant:"outlined",color:"secondary",className:n.heading,startIcon:Object($.jsx)(qe.a,{}),children:"Settings"}),Object($.jsx)(Je.a,{className:n.avatarStyle,children:s.name[0].toUpperCase()})]}),Object($.jsx)(S.a,{container:!0,justify:"center",children:Object($.jsxs)(S.a,{item:!0,xs:12,className:n.settingBoxcontainer,children:[Object($.jsx)(fe.a,{component:"p",className:n.email,children:s.email}),G&&Object($.jsx)(F.a,{size:"1rem",className:n.loaderStyle,color:"secondary"})]})}),Object($.jsx)(S.a,{container:!0,justify:"center",children:Object($.jsxs)(S.a,{item:!0,xs:12,className:n.settingBoxcontainer,children:[Object($.jsx)("table",{style:{margin:"10px 0 15px 0"},children:Object($.jsxs)("tbody",{children:[Object($.jsxs)("tr",{children:[Object($.jsx)("td",{children:Object($.jsx)(C.a,{variant:"contained",color:"default",startIcon:Object($.jsx)(E.a,{}),className:n.switchLabelBtn,children:"Redbox Feeds"})}),Object($.jsx)("td",{children:Object($.jsx)(k.a,{name:"rFeeds",color:"primary",onChange:q,checked:h.rFeeds})})]}),Object($.jsxs)("tr",{children:[Object($.jsx)("td",{children:Object($.jsx)(C.a,{variant:"contained",color:"default",startIcon:Object($.jsx)(M.a,{}),className:n.switchLabelBtn,children:"Crawler Feeds"})}),Object($.jsx)("td",{children:Object($.jsx)(k.a,{name:"cFeeds",color:"primary",onChange:q,checked:h.cFeeds})})]}),Object($.jsxs)("tr",{children:[Object($.jsx)("td",{children:Object($.jsx)(C.a,{variant:"contained",color:"default",startIcon:Object($.jsx)(z.a,{}),className:n.switchLabelBtn,children:"Twitter Feeds"})}),Object($.jsx)("td",{children:Object($.jsx)(k.a,{name:"tFeeds",color:"primary",onChange:q,checked:h.tFeeds})})]})]})}),Object($.jsxs)("div",{className:n.chipContainer,children:[Object($.jsx)(Ke.a,{label:"Email Sent: ".concat(null===N||void 0===N?void 0:N.emailSent),variant:"outlined"}),Object($.jsx)(Ke.a,{label:"News Searched: ".concat(null===N||void 0===N?void 0:N.searched),variant:"outlined"}),Object($.jsx)(Ke.a,{label:"Daily Email Limit: ".concat(null===N||void 0===N?void 0:N.emailBookmarkLimit),variant:"outlined"}),Object($.jsx)(Ke.a,{label:"Briefcase Limit: ".concat(null===N||void 0===N?void 0:N.bookmarkLimit),variant:"outlined"})]}),Object($.jsx)(C.a,{variant:"contained",color:"primary",className:n.button,onClick:function(e){e.preventDefault(),f(Object(y.a)(Object(y.a)({},h),{},{error:"",loading:!0})),O(!1),function(e,t,n){return fetch("".concat(P,"/settings/").concat(e),{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json",Authorization:"Bearer ".concat(t)},body:JSON.stringify(n)}).then((function(e){return e.json()})).catch((function(e){return console.log(e)}))}(s._id,l,{settings:{tFeeds:L,cFeeds:Y,rFeeds:_}}).then((function(e){var t,n,c,a,r,o;e.error?(f(Object(y.a)(Object(y.a)({},h),{},{error:e.error,loading:!1})),O(!1)):(console.log(e),f(Object(y.a)(Object(y.a)({},h),{},{tFeeds:null===e||void 0===e||null===(t=e.settings)||void 0===t?void 0:t.tFeeds,cFeeds:null===e||void 0===e||null===(n=e.settings)||void 0===n?void 0:n.cFeeds,rFeeds:null===e||void 0===e||null===(c=e.settings)||void 0===c?void 0:c.rFeeds,error:"",loading:!1,success:!0})),B(Object(y.a)(Object(y.a)({},A),{},{tFeeds:null===e||void 0===e||null===(a=e.settings)||void 0===a?void 0:a.tFeeds,cFeeds:null===e||void 0===e||null===(r=e.settings)||void 0===r?void 0:r.cFeeds,rFeeds:null===e||void 0===e||null===(o=e.settings)||void 0===o?void 0:o.rFeeds})),O(!0),X.push("/"))}))},startIcon:Object($.jsx)(Qe.a,{}),children:"Save"}),Object($.jsx)(C.a,{variant:"contained",color:"secondary",onClick:e,className:n.button,startIcon:Object($.jsx)(D.a,{}),children:"Close"})]})})]})})},ot=n(138),st=n.n(ot),it=n(139),lt=n.n(it),dt=n(61),jt=n.n(dt),bt=n(83),ut=n.n(bt),gt=n(941),ht=n(942),ft=n(943),pt=n(944),mt=n(945),Ot=function(){return{top:"".concat(50,"%"),left:"".concat(50,"%"),transform:"translate(-".concat(50,"%, -").concat(50,"%)")}},xt=Object(f.a)((function(e){return{paper:{position:"absolute",width:"70%",backgroundColor:e.palette.background.paper,boxShadow:e.shadows[5],padding:e.spacing(2,4,3),borderRadius:"4px"},button:{margin:"1rem 10px 0 0",color:"#fff"},settingBoxcontainer:Object(x.a)({margin:"1rem 0 0 0",height:"350px",overflowY:"scroll","&::-webkit-scrollbar-thumb":{backgroundColor:"red",border:"none"},"&::-webkit-scrollbar-track":{backgroundColor:"#fff",border:"none"}},"&::-webkit-scrollbar-thumb",{backgroundColor:"darkgrey",border:"none"}),loaderStyle:{float:"right"},closeBtnStyle:{float:"right",marginLeft:"15px"},tableRow:{marginBottom:"20px",borderBottom:"1px solid grey !important"},table:{minWidth:350},heading:{color:"#000",padding:"8px 40px",borderRadius:"25px"}}})),vt=function(e,t){var n=xt(),a=Object(c.useState)(Ot),r=Object(b.a)(a,1)[0],o=Object(c.useState)([]),s=Object(b.a)(o,2),i=s[0],l=s[1],d=Object(c.useState)(!1),j=Object(b.a)(d,2),u=j[0],g=j[1],h=H(),f=h.user,p=h.token;Object(c.useEffect)((function(){O(f._id,p)}),[f._id,p,t]);var m,O=function(e,t){g(!0),function(e,t){return fetch("".concat(P,"/get/bookmarks/").concat(e),{method:"GET",headers:{Accept:"application/json","Content-Type":"application/json",Authorization:"Bearer ".concat(t)}}).then((function(e){return e.json()})).catch((function(e){return console.log(e)}))}(e,t).then((function(e){(null===e||void 0===e?void 0:e.error)?(g(!1),l([])):(g(!1),l(e))}))},x=function(e){var t=/(https?:\/\/[^\s]+)/g,n=e.match(t);return{desc:e.replace(/&/g,"&").replace(t,(function(e){return" "})),url:n}},y=function(e,t,n){(function(e,t,n){return fetch("".concat(P,"/delete/bookmark/").concat(n,"/").concat(e),{method:"DELETE",headers:{Accept:"application/json","Content-Type":"application/json",Authorization:"Bearer ".concat(t)}}).then((function(e){return e.json()})).catch((function(e){return console.log(e)}))})(t,n,e).then((function(e){if(null===e||void 0===e?void 0:e.error)console.log("Not able to delete");else{var t=e.bookmarkedNewses;l(Object(v.a)(t))}}))},N=function(e,t){(function(e,t){return fetch("".concat(P,"/empty/bookmarks/").concat(e),{method:"DELETE",headers:{Accept:"application/json","Content-Type":"application/json",Authorization:"Bearer ".concat(t)}}).then((function(e){return e.json()})).catch((function(e){return console.log(e)}))})(e,t).then((function(e){(null===e||void 0===e?void 0:e.error)?console.log("Not able to delete"):l([])}))};return Object($.jsx)($.Fragment,{children:Object($.jsxs)("div",{style:r,className:n.paper,children:[Object($.jsxs)(fe.a,{variant:"h5",children:[Object($.jsx)(Ue.a,{badgeContent:"".concat(null===i||void 0===i?void 0:i.length," / ").concat(null===f||void 0===f?void 0:f.bookmarkLimit),color:"secondary",children:Object($.jsx)(C.a,{variant:"outlined",color:"secondary",className:n.heading,startIcon:Object($.jsx)(jt.a,{}),children:"Briefcase"})}),Object($.jsx)(w.a,{onClick:e,className:n.closeBtnStyle,size:"small",children:Object($.jsx)(D.a,{})}),Object($.jsx)(C.a,{variant:"outlined",color:"secondary",className:n.closeBtnStyle,size:"small",onClick:function(){return N(f._id,p)},children:"Empty briefcase"})]}),u&&Object($.jsx)(gt.a,{color:"secondary",style:{margin:"5px 0"}}),Object($.jsx)(S.a,{container:!0,justify:"center",children:Object($.jsx)(S.a,{item:!0,xs:12,className:n.settingBoxcontainer,children:Object($.jsx)(ht.a,{className:n.table,size:"small",children:Object($.jsx)(ft.a,{children:(m=i,m.sort((function(e,t){return new Date(t.createdAt)-new Date(e.createdAt)})),m).map((function(e){return Object($.jsxs)(pt.a,{children:[Object($.jsx)(mt.a,{children:Object($.jsx)("b",{children:q()(e.createdAt).calendar(
1)})}),Object($.jsxs)(mt.a,{children:[(null===e||void 0===e?void 0:e.isCrawlerFeed)&&Object($.jsx)("img",{src:K,className:"crawlerImage"}),(null===e||void 0===e?void 0:e.isTwitterFeed)?Object($.jsxs)($.Fragment,{children:[Object($.jsx)(z.a,{style:{fontSize:"15px",color:"#0ddfff",marginRight:"3px"}}),e.topic,Object($.jsxs)("span",{style:{marginLeft:"5px"},children:[x(e.description).desc,x(e.description).url&&x(e.description).url.map((function(e){return Object($.jsx)("a",{href:e,className:"twitterLink",target:"_blank",children:e},e)}))]})]}):e.description,(null===e||void 0===e?void 0:e.isCrawlerFeed)&&Object($.jsx)("a",{href:e.link,className:"crawlerLink",target:"_blank",children:"Read"})]}),Object($.jsx)(mt.a,{children:Object($.jsx)(w.a,{size:"small",color:"secondary",onClick:function(){return y(e._id,f._id,p)},children:Object($.jsx)(ie.a,{})})})]},e._id)}))})})})})]})})},yt=function(e,t,n,c){return fetch("".concat(P,"/story/").concat(n,"/").concat(c,"/").concat(e),{method:"GET",headers:{Accept:"application/json","Content-Type":"application/json",Authorization:"Bearer ".concat(t)}}).then((function(e){return e.json()})).catch((function(e){return console.log(e)}))},wt=n(188),St=function(){return{top:"".concat(50,"%"),left:"".concat(50,"%"),transform:"translate(-".concat(50,"%, -").concat(50,"%)")}},Ct=Object(f.a)((function(e){return{paper:{position:"absolute",width:"70%",height:"80vh",borderRadius:"4px",overflowY:"scroll",backgroundColor:"#000",color:"#ffa500",boxShadow:e.shadows[5],padding:e.spacing(2,4,3)},closeBtnStyle:{float:"right",marginLeft:"15px",color:"#f44336"}}})),Nt=function(e,t){var n=Ct(),a=Object(c.useState)(St),r=Object(b.a)(a,1)[0];return Object($.jsx)($.Fragment,{children:Object($.jsxs)("div",{style:r,className:n.paper,children:[Object($.jsx)(fe.a,{variant:"h5",children:Object($.jsx)(w.a,{onClick:e,className:n.closeBtnStyle,size:"small",children:Object($.jsx)(D.a,{})})}),Object($.jsx)("div",{children:Object(wt.a)(t)})]})})},kt=Object(c.createContext)(),Tt=function(e){var t=e.children,n=Object(c.useState)(!1),a=Object(b.a)(n,2),r=a[0],o=a[1];return Object($.jsx)(kt.Provider,{value:[r,o],children:t})},Ft=function(){return{top:"".concat(50,"%"),left:"".concat(50,"%"),transform:"translate(-".concat(50,"%, -").concat(50,"%)")}},Rt=Object(f.a)((function(e){return{paper:{position:"absolute",width:"60%",backgroundColor:"#fff",borderRadius:"4px",boxShadow:e.shadows[5],padding:e.spacing(2,4,3)},button:{margin:"1rem 10px 0 0",color:"#fff"},settingBoxcontainer:Object(x.a)({margin:"1rem 0 0 0",height:"350px",overflowY:"scroll","&::-webkit-scrollbar-thumb":{backgroundColor:"red",border:"none"},"&::-webkit-scrollbar-track":{backgroundColor:"#fff",border:"none"}},"&::-webkit-scrollbar-thumb",{backgroundColor:"darkgrey",border:"none"}),loaderStyle:{float:"right"},closeBtnStyle:{float:"right",marginLeft:"15px"},tableRow:{marginBottom:"20px",cursor:"pointer",border:"0","&:hover":{backgroundColor:"#f2f2f2"}},tableCell:{},table:{minWidth:350},heading:{color:"#000",padding:"8px 40px",borderRadius:"25px"}}})),Dt=function(e,t){var n=Rt(),a=Object(c.useState)(Ft),r=Object(b.a)(a,1)[0],o=Object(c.useState)([]),s=Object(b.a)(o,2),i=s[0],l=s[1],d=Object(c.useState)(!1),j=Object(b.a)(d,2),u=j[0],g=j[1],h=Object(c.useState)(""),f=Object(b.a)(h,2),p=f[0],m=f[1],x=Object(c.useState)(""),y=Object(b.a)(x,2),N=y[0],k=y[1],F=Object(c.useState)(""),R=Object(b.a)(F,2),I=R[0],A=R[1],E=Object(c.useState)(1),B=Object(b.a)(E,2),z=B[0],L=B[1],M=H(),Y=M.user,_=M.token,U=Object(c.useContext)(ue),G=Object(c.useContext)(kt),W=Object(b.a)(G,2),X=(W[0],W[1]),J=Object(c.useRef)(),K=Object(c.useState)(!1),V=Object(b.a)(K,2),Q=V[0],Z=V[1],ee=function(){Z(!1)};Object(c.useEffect)((function(){return U.on("newStoryFromGlobal",(function(e){X(!0),l((function(t){return Object(v.a)(new Set([e].concat(Object(v.a)(t))))}))})),U.on("deletedStoryFromGlobal",(function(e){yt(Y._id,_,15,z).then((function(e){e.error?m(e.error):(L(1),l(e))})).catch((function(e){m("Not able to fetch")}))})),U.on("updatedStory",(function(e){yt(Y._id,_,15,z).then((function(e){e.error?m(e.error):(L(1),l(e))})).catch((function(e){m("Not able to fetch")}))}
1)),function(){return U.off("newStoryFromGlobal")}}),[Y._id,_,Y.email,U,X]),Object(c.useEffect)((function(){g(!0),yt(Y._id,_,15,z).then((function(e){e.error?(m(e.error),g(!1)):(l((function(t){return Object(v.a)(new Set([].concat(Object(v.a)(t),Object(v.a)(e))))})),g(!1))})).catch((function(e){g(!1),m("Not able to fetch")}))}),[Y._id,_,z]),Object(c.useEffect)((function(){L(1)}),[t]);return Object($.jsx)($.Fragment,{children:Object($.jsxs)("div",{style:r,className:n.paper,children:[p&&Object($.jsx)(Ae,{message:p}),Object($.jsxs)(fe.a,{variant:"h5",children:[Object($.jsx)(C.a,{variant:"outlined",color:"secondary",className:n.heading,startIcon:Object($.jsx)(jt.a,{}),children:"Story"}),Object($.jsx)(w.a,{onClick:e,className:n.closeBtnStyle,size:"small",children:Object($.jsx)(D.a,{})}),u&&Object($.jsx)(gt.a,{color:"secondary",style:{margin:"5px 0"}}),Object($.jsxs)("form",{onSubmit:function(e){if(e.preventDefault(),""===I)return g(!0),void yt(Y._id,_,15,1).then((function(e){e.error?(m(e.error),g(!1)):(l(e),g(!1))})).catch((function(e){g(!1),m("Not able to fetch")}));g(!0),function(e,t,n,c,a){return fetch("".concat(P,"/search/story/").concat(n,"/").concat(c,"/").concat(a,"/").concat(e),{method:"GET",headers:{Accept:"application/json","Content-Type":"application/json",Authorization:"Bearer ".concat(t)}}).then((function(e){return e.json()})).catch((function(e){return console.log(e)}))}(Y._id,_,15,z,I).then((function(e){e.error?(m(e.error),g(!1)):(l(e),g(!1))})).catch((function(e){g(!1),m("Not able to fetch")}))},children:[Object($.jsx)(C.a,{variant:"contained",color:"primary",disabled:u,className:n.loaderStyle,onClick:function(){J.current.scrollTo({top:0,behavior:"smooth"}),function(){if(1===z)return l([]),A(""),L(1),g(!0),void yt(Y._id,_,15,1).then((function(e){e.error?(m(e.error),g(!1)):(l(e),g(!1))})).catch((function(e){g(!1),m("Not able to fetch")}));l([]),A(""),L(0)}()},style:{marginLeft:"5px",color:"#fff"},children:"Reset"}),Object($.jsx)(T.a,{size:"small",label:"Search",variant:"outlined",value:I,onChange:function(e){return A(e.target.value)},className:n.closeBtnStyle})]})]}),Object($.jsx)(S.a,{container:!0,justify:"center",children:Object($.jsx)(S.a,{item:!0,xs:12,className:n.settingBoxcontainer,id:"scrollableStoryDiv",ref:J,children:Object($.jsx)(ae.a,{dataLength:i.length,next:function(){return L(z+1)},hasMore:!0,scrollableTarget:"scrollableStoryDiv",children:Object($.jsx)(ht.a,{className:n.table,size:"small",children:Object($.jsx)(ft.a,{children:i.map((function(e){return Object($.jsxs)(pt.a,{className:n.tableRow,onClick:function(){k(e.description),Z(!0)},children:[Object($.jsx)(mt.a,{className:n.tableCell,children:Object($.jsx)("b",{children:q()(e.createdAt).calendar()})}),Object($.jsx)(mt.a,{className:n.tableCell,children:e.title})]},e._id)}))})})})})}),Object($.jsx)(O.a,{open:Q,onClose:ee,children:Nt(ee,N)})]})})},It=n(304),At=n(946),Et=n(963),Bt=n(189),zt=n.n(Bt),Lt=function(){return{top:"".concat(50,"%"),left:"".concat(50,"%"),transform:"translate(-".concat(50,"%, -").concat(50,"%)")}},Mt=Object(f.a)((function(e){return{paper:{position:"absolute",width:"50%",backgroundColor:e.palette.background.paper,boxShadow:e.shadows[5],padding:e.spacing(2,4,3),borderRadius:"4px"},button:{margin:"1rem 10px 0 0",color:"#fff"},settingBoxcontainer:{margin:"1rem 0 0 0"},loaderStyle:{float:"right"},email:{fontWeight:"bold"},heading:{color:"#000",padding:"8px 40px",borderRadius:"25px"}}})),Yt=function(e){var t=Mt(),n=Object(c.useState)(Lt),a=Object(b.a)(n,1)[0],r=H(),o=r.user,s=r.token,i=Object(c.useState)(!1),l=Object(b.a)(i,2),u=l[0],g=l[1],f=Object(c.useState)(""),p=Object(b.a)(f,2),m=p[0],O=p[1],N=Object(c.useState)(!1),k=Object(b.a)(N,2),R=k[0],I=k[1],A=Object(c.useState)([]),E=Object(b.a)(A,2),B=E[0],z=E[1],L=Object(c.useState)({Email:!1,Briefcase:!0}),M=Object(b.a)(L,2),Y=M[0],_=M[1],U=Object(c.useState)(""),G=Object(b.a)(U,2),W=G[0],X=G[1];Object(c.useEffect)((function(){q(o._id,s)}),[o._id,s]),Object(c.useEffect)((function(){R&&setTimeout(Object(j.a)(d.a.mark((function e(){return d.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,I(!1);case 2:case"end":return e.stop()}}),e)}))),3e3)}
1),[R,I]);var q=function(e,t){(function(e,t){return fetch("".concat(P,"/get/user/tags/").concat(e),{method:"GET",headers:{Accept:"application/json",Authorization:"Bearer ".concat(t)}}).then((function(e){return e.json()})).catch((function(e){return console.log(e)}))})(e,t).then((function(e){(null===e||void 0===e?void 0:e.error)?console.log("Not able to load tags!"):(z(e.tags),_({Email:e.snipperSettings.email,Briefcase:e.snipperSettings.brifcase}))}))};return Object($.jsx)($.Fragment,{children:Object($.jsxs)("div",{style:a,className:t.paper,children:[m&&Object($.jsx)(Ae,{message:m}),R&&Object($.jsx)(Ae,{message:"Tags saved!"}),Object($.jsxs)(fe.a,{variant:"h5",children:[Object($.jsx)(C.a,{variant:"outlined",color:"secondary",className:t.heading,startIcon:Object($.jsx)(ut.a,{}),children:"Sniper"}),u&&Object($.jsx)(F.a,{size:"1rem",className:t.loaderStyle,color:"secondary"})]}),Object($.jsx)(S.a,{container:!0,justify:"center",children:Object($.jsxs)(S.a,{item:!0,xs:12,className:t.settingBoxcontainer,children:[Object($.jsxs)("div",{style:{margin:"1rem 0"},children:[Object($.jsx)(T.a,{id:"outlined-basic",label:"Enter Tags",variant:"outlined",onChange:function(e){X(e.target.value.toLowerCase())},value:W,size:"small"}),Object($.jsx)(w.a,{variant:"contained",onClick:function(){z([].concat(Object(v.a)(B),[W])),X("")},style:{marginLeft:"10px",position:"relative",top:"-5px"},children:Object($.jsx)(zt.a,{})}),B.length>0&&Object($.jsx)(C.a,{variant:"outlined",color:"secondary",style:{float:"right"},size:"small",onClick:function(){return z([])},children:"Remove all tags"})]}),Object($.jsx)(h.a,{component:"div",style:{margin:"10px 0"},children:B.map((function(e,t){return Object($.jsx)(C.a,{variant:"contained",size:"small",endIcon:Object($.jsx)(D.a,{onClick:function(){return function(e){var t=Object(v.a)(B),n=t.indexOf(e);n>-1&&t.splice(n,1),z(t)}(e)}}),style:{marginRight:"10px"},children:e},e)}))}),Object($.jsx)(h.a,{component:"div",style:{margin:"10px 0"},children:Object($.jsx)(It.a,{row:!0,name:"catrgroy",children:["Email","Briefcase"].map((function(e,t){return Object($.jsx)(At.a,{control:Object($.jsx)(Et.a,{onChange:(n=e,function(e){_(Object(y.a)(Object(y.a)({},Y),{},Object(x.a)({},n,!Y[n])))}),size:"small",checked:Y[e],color:"primary"}),label:e},e);var n}))})}),Object($.jsx)(C.a,{variant:"contained",color:"primary",className:t.button,onClick:function(e){e.preventDefault(),z(Object(v.a)(B)),_(Object(y.a)({},Y)),g(!0),I(!1),O(""),function(e,t,n){return fetch("".concat(P,"/set/tags/").concat(e),{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json",Authorization:"Bearer ".concat(t)},body:JSON.stringify(n)}).then((function(e){return e.json()})).catch((function(e){return console.log(e)}))}(o._id,s,{tags:B,snipperSettings:{email:Y.Email,brifcase:Y.Briefcase}}).then((function(e){e.error?(O(e.error),g(!1),I(!1)):(X(""),g(!1),I(!0))}))},startIcon:Object($.jsx)(Qe.a,{}),children:"Save"}),Object($.jsx)(C.a,{variant:"contained",color:"secondary",onClick:e,className:t.button,startIcon:Object($.jsx)(D.a,{}),children:"Close"})]})})]})})},_t=n(96),Pt=n.n(_t),Ut=n(8),Gt=n(960),Wt=n(947),Ht=n(190),Xt=n.n(Ht),qt=n(120),Jt=Object(f.a)((function(e){return{root:Object(x.a)({overflowY:"scroll",width:"100%","&::-webkit-scrollbar-thumb":{backgroundColor:"red",border:"none"},"&::-webkit-scrollbar-track":{backgroundColor:"#fff",border:"none"}},"&::-webkit-scrollbar-thumb",{backgroundColor:"darkgrey",border:"none"}),button:{margin:"1rem 10px 0 0",color:"#fff"},settingBoxcontainer:Object(x.a)({margin:"1rem 0 0 0",height:"350px",overflowY:"scroll","&::-webkit-scrollbar-thumb":{backgroundColor:"red",border:"none"},"&::-webkit-scrollbar-track":{backgroundColor:"#fff",border:"none"}},"&::-webkit-scrollbar-thumb",{backgroundColor:"darkgrey",border:"none"}),loaderStyle:{float:"right"},closeBtnStyle:{float:"right",marginLeft:"15px"},tableRow:{marginBottom:"20px",borderBottom:"1px solid grey !important"},table:{width:"100%",height:"min-content"},heading:{color:"#000",padding:"8px 40px",borderRadius:"25px"}}})),Kt=function(e){var t=Jt(),n=Object(c.useState)(!1),a=Object(b.a)(n,2),r=a[
10],o=(a[1],Object(c.useState)(1)),s=Object(b.a)(o,2),i=(s[0],s[1],Object(c.useRef)()),l=(e.children,e.value),d=e.index,j=(e.tags,e.newses),u=Object(qt.a)(e,["children","value","index","tags","newses"]),g=H(),f=(g.user,g.token,function(e){if(e){var t=/(https?:\/\/[^\s]+)/g,n=null===e||void 0===e?void 0:e.match(t);return{desc:e.replace(/&amp;/g,"&").replace(t,(function(e){return" "})),url:n}}return e});return Object($.jsx)("div",Object(y.a)(Object(y.a)({role:"tabpanel",hidden:l!==d,id:"vertical-tabpanel-".concat(d),"aria-labelledby":"vertical-tab-".concat(d)},u),{},{className:t.root,ref:i,children:l===d&&Object($.jsxs)(h.a,{p:3,children:[r&&Object($.jsx)(gt.a,{color:"secondary"}),Object($.jsx)(ht.a,{className:t.table,size:"small",children:Object($.jsx)(ft.a,{children:j&&(null===j||void 0===j?void 0:j.length)>0&&j.map((function(e){var t,n,c,a;return Object($.jsxs)(pt.a,{children:[Object($.jsx)(mt.a,{children:Object($.jsx)("b",{children:q()(e.createdAt).calendar()})}),Object($.jsxs)(mt.a,{children:[(null===e||void 0===e?void 0:e.isCrawlerFeed)&&Object($.jsx)("img",{src:K,className:"crawlerImage"}),(null===e||void 0===e?void 0:e.isTwitterFeed)?Object($.jsxs)($.Fragment,{children:[Object($.jsx)(z.a,{style:{fontSize:"15px",color:"#0ddfff",marginRight:"3px"}}),null===e||void 0===e?void 0:e.topic,Object($.jsxs)("span",{style:{marginLeft:"5px"},children:[null===(t=f(null===e||void 0===e?void 0:e.payload))||void 0===t?void 0:t.desc,(null===(n=f(null===e||void 0===e?void 0:e.payload))||void 0===n?void 0:n.url)&&(null===(c=f(null===e||void 0===e?void 0:e.payload))||void 0===c||null===(a=c.url)||void 0===a?void 0:a.map((function(e){return Object($.jsx)("a",{href:e,className:"twitterLink",target:"_blank",children:e},e)})))]})]}):null===e||void 0===e?void 0:e.description,(null===e||void 0===e?void 0:e.isCrawlerFeed)&&e.article.title,(null===e||void 0===e?void 0:e.isCrawlerFeed)&&Object($.jsx)("a",{href:e.article.link,className:"crawlerLink",target:"_blank",children:"Read"})]})]},e._id)}))})})]})}))};var Vt=Object(c.createContext)(),Qt=function(e){var t=e.children,n=Object(c.useState)(0),a=Object(b.a)(n,2),r=a[0],o=a[1];return Object($.jsx)(Vt.Provider,{value:[r,o],children:t})},$t=function(){return{top:"".concat(50,"%"),left:"".concat(50,"%"),transform:"translate(-".concat(50,"%, -").concat(50,"%)")}},Zt=Object(f.a)((function(e){return{paper:{position:"absolute",width:"80%",backgroundColor:e.palette.background.paper,boxShadow:e.shadows[5],padding:e.spacing(2,0,3,0),borderRadius:"4px"},button:{margin:"1rem 10px 0 0",color:"#fff"},loaderStyle:{float:"right"},closeBtnStyle:{float:"right",marginLeft:"15px",marginRight:e.spacing(2)},heading:{color:"#000",padding:"8px 40px",borderRadius:"25px",marginLeft:e.spacing(2),textTransform:"capitalize"},tabs:{borderRight:"1px solid ".concat(e.palette.divider),minWidth:162},tabContainer:{flexGrow:1,backgroundColor:e.palette.background.paper,display:"flex",height:"75vh",marginTop:e.spacing(2)}}})),en=Object(Ut.a)({root:{minWidth:"195px"},indicator:{backgroundColor:"#fff"}})(Gt.a),tn=Object(Ut.a)((function(e){return{root:{textTransform:"none",fontWeight:e.typography.fontWeightRegular,marginRight:e.spacing(4),paddingLeft:e.spacing(3),"& span":{textAlign:"left !important",alignItems:"flex-start"},"&:hover":{color:"#efa01e",opacity:1},"&$selected":{color:"#efa01e",fontWeight:e.typography.fontWeightMedium,backgroundColor:"#ffe6b7",borderTopRightRadius:"23px",borderBottomRightRadius:"23px"},"&:focus":{color:"#efa01e"}},selected:{}}}))((function(e){return Object($.jsx)(Wt.a,Object(y.a)({disableRipple:!0},e))})),nn=function(e){var t=e.handleClose,n=(e.count,e.labels),a=Zt(),r=Object(c.useState)($t),o=Object(b.a)(r,1)[0],s=Object(c.useState)(!1),i=Object(b.a)(s,2),l=(i[0],i[1],Object(c.useContext)(Vt)),d=Object(b.a)(l,2),j=d[0],u=d[1],g=Object(c.useState)(j),h=Object(b.a)(g,2),f=h[0],p=h[1],m=H();m.user,m.token;return Object($.jsx)($.Fragment,{children:Object($.jsxs)("div",{style:o,className:a.paper,children:[Object($.jsxs)(fe.a,{variant:"h5",children:[Object($.jsx)(C.a,{variant:"outlined",className:a.heading,startIcon:Object($.jsx)(Xt.a,{}),children:"Labels"}),Object($.jsx)(w.a,{onClick:t,className:a.closeBtnStyle,size:"small",children:Object($.jsx)(D.a,{})})]}),Object($.jsxs)("div",{className:a.tabContainer,children:[Object($.jsx)(en,{orientation:"vertical",variant:"scrollable",value:j,onChange:function(e,t){u(t),p(t)},className:a.tabs,children:n&&n.map((function(e,t){return Object($.jsx)(tn,Object(y.a)({label:e.name},function(e){return{id:"vertical-tab-".concat(e),"aria-controls":"vertical-tabpanel-".concat(e)}}(t)),e._id)}))}),n&&n.map((function(e,t){return Object($.jsx)(Kt,{value:f,index:t,tags:e.tags,newses:e.newses})}))]})]})})},cn=Object(Ut.a)((function(e){return{badge:{right:"8px",top:"1px",backgroundColor:"#4caf50"}}}))(Ue.a),an=function(){return{top:"".concat(50,"%"),left:"".concat(50,"%"),transform:"translate(-".concat(50,"%, -").concat(50,"%)")}},rn=Object(f.a)((function(e){var t;return{paper:(t={position:"absolute",width:"60%",height:"450px",backgroundColor:"#f1f1f1",boxShadow:e.shadows[5],padding:e.spacing(2,4,3),borderRadius:"4px"},Object(x.a)(t,e.breakpoints.down("md"),{width:"70%"}),Object(x.a)(t,e.breakpoints.down("sm"),{width:"80%"}),Object(x.a)(t,e.breakpoints.down("xs"),{width:"90%"}),t),chipContainer:{display:"flex",justifyContent:"flex-start",maxHeight:"70%",flexWrap:"wrap","& > *":{margin:e.spacing(.5),color:"#000"}},button:{margin:"1rem 10px 0 0",color:"#fff"},settingBoxcontainer:{margin:"1rem 0 0 0"},closeBtnStyle:{float:"right",marginLeft:"15px"},loaderStyle:{float:"right"},email:{fontWeight:"bold"},heading:{color:"#000",padding:"8px 40px",borderRadius:"25px",textTransform:"capitalize"},chipStyle:{color:"#20202",backgroundColor:"#ff9800","&:hover":{backgroundColor:"#ffe6b7"},"&:active":{backgroundColor:"#ffe6b7"},"&:focus":{backgroundColor:"#ffe6b7"}}}})),on=function(e){var t=e.handleClose,n=e.count,a=rn(),r=Object(c.useState)(an),o=Object(b.a)(r,1)[0],s=H(),i=s.user,l=s.token,d=Object(c.useState)(!1),j=Object(b.a)(d,2),u=j[0],g=j[1],f=Object(c.useState)(""),p=Object(b.a)(f,2),m=p[0],x=p[1],v=Object(c.useState)([]),y=Object(b.a)(v,2),S=y[0],N=y[1],k=Object(c.useContext)(Vt),T=Object(b.a)(k,2),F=(T[0],T[1]),R=Object(c.useContext)(ue),I=Object(c.useState)(0),A=Object(b.a)(I,2),E=A[0],B=A[1],z=Object(c.useState)(!1),L=Object(b.a)(z,2),M=L[0],Y=L[1];Object(c.useRef)(0);Object(c.useEffect)((function(){_(i._id,l)}),[i._id,l,n]),Object(c.useEffect)((function(){return R.on("updateLabel",(function(e){_(i._id,l)})),R.on("deletedLabel",(function(e){N((function(t){return t.filter((function(t){return t._id!==e}))}))})),function(){R.off("updateLabel"),R.off("deletedLabel")}}),[i._id,l,R]);var _=function(e,t){g(!0),function(e,t){return fetch("".concat(P,"/label/").concat(e),{method:"GET",headers:{Accept:"application/json","Content-Type":"application/json",Authorization:"Bearer ".concat(t)}}).then((function(e){return e.json()})).catch((function(e){return console.log(e)}))}(e,t).then((function(e){(null===e||void 0===e?void 0:e.error)?(g(!1),x(e.error),N([])):(g(!1),N(e))}))},U=function(e,t,n){g(!0),function(e,t,n,c){return fetch("".concat(P,"/update/label/").concat(n,"/").concat(e),{method:"PUT",headers:{Accept:"application/json","Content-Type":"application/json",Authorization:"Bearer ".concat(t)},body:JSON.stringify(c)}).then((function(e){return e.json()})).catch((function(e){return console.log(e)}))}(e,t,n,{new:!1}).then((function(e){(null===e||void 0===e?void 0:e.error)?(x(e.error),g(!1),console.log("Not able to update dot...")):(g(!1),console.log("Dot updated..."))}))},G=function(){Y(!0),B((function(e){return e+1}))},W=function(){Y(!1)};return Object($.jsxs)($.Fragment,{children:[Object($.jsxs)("div",{style:o,className:a.paper,children:[m&&Object($.jsx)(Ae,{message:m}),Object($.jsxs)(fe.a,{variant:"h5",children:[Object($.jsx)(C.a,{variant:"outlined",className:a.heading,startIcon:Object($.jsx)(Pt.a,{}),children:"Trending"}),Object($.jsx)(w.a,{onClick:t,className:a.closeBtnStyle,size:"small",children:Object($.jsx)(D.a,{})})]}),Object($.jsx)(gt.a,{color:"secondary",style:u?{margin:"5px 0",opacity:"100%"}:{margin:"5px 0",opacity:"0"}}),Object($.jsx)(h.a,{component:"div",style:{margin:"1rem 0"},className:a.chipContainer,children:S&&S.map((function(e,t){return e.new?Object($.jsx)(cn,{color:"secondary",variant:"dot",children:Object($.jsx)(Ke.a,{label:e.name,className:a.chipStyle,onClick:function(){U(i._id,l,e._id),F(t),G()}},e._id)}):Object($.jsx)(Ke.a,{label:e.name,className:a.chipStyle,onClick:function(){F(t),G()}},e._id)}))})]}),Object($.jsx)(O.a,{open:M,onClose:W,children:Object($.jsx)(nn,{handleClose:W,count:E,labels:S})})]})},sn=n(193),ln=n.n(sn),dn=n(933),jn=function(){return fetch("".concat(U,"/data/").concat("61f4c2c5360008712d45e2f6"),{method:"GET",headers:{Accept:"application/json","Content-Type":"application/json",Authorization:"Bearer ".concat("eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJfaWQiOiI2MWY0YzJjNTM2MDAwODcxMmQ0NWUyZjYiLCJpYXQiOjE2NDM0MzA2MDF9.gCndw2nkQibhVjL3-KHnQakmRR4z4gNRVqiWMmUdtVE")}}).then((function(e){return e.json()})).catch((function(e){return console.log(e)}))},bn=n(84),un=n.n(bn),gn=Object(f.a)((function(e){return{list:{width:510,backgroundColor:"#27272e",color:"#9E9E9E",zIndex:"99999",height:"100vh",overflowY:"scroll"},loader:{margin:"0.5em 0.75em"},tableLabel:{textTransform:"uppercase",padding:"0.5em 0.75em",backgroundColor:"hsl(240, 7%, 14%)",letterSpacing:"2.5px"},table:{width:"100%",textAlign:"left",borderRadius:"5px",cursor:"pointer",backgroundColor:"#27272e",borderSpacing:"0",verticalAlign:"top","& td, th":{borderBottom:"1px solid #0a0a0a",padding:"0.5em 0.75em",verticalAlign:"top"},"& thead tr:first-child:hover":{backgroundColor:"#27272e"},"& tr:hover":{transition:"background-color 300ms linear",backgroundColor:"hsl(240, 7%, 14%)"}},textDanger:{color:"#F44336"},textSuccess:{color:"#4CAF50"},popover:{pointerEvents:"none"},paper:{padding:e.spacing(1),backgroundColor:"hsl(240, 7%, 14%)",color:"#9E9E9E"}}})),hn=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2;if(null==e)return"-";var n=parseFloat(e);return isNaN(n)?"-":n.toFixed(t)},fn=function(e){if(null==e)return"-";if("number"===typeof e){var t=e.toString().split(".");return t[0].length>=5&&(t[0]=t[0].replace(/(\d)(?=(\d{3})+$)/g,"$1,")),t[1]&&t[1].length>=5&&(t[1]=t[1].replace(/(\d{3})/g,"$1 ")),t.join(".")}return String(e)},pn=function(e){var t,n=e.company,a=e.setCompanies,r=Object(c.useState)(""),o=Object(b.a)(r,2),s=o[0],i=o[1];return Object(c.useEffect)((function(){var e,t;(null===n||void 0===n||null===(e=n.current)||void 0===e?void 0:e.price)&&(null===n||void 0===n||null===(t=n.prev)||void 0===t?void 0:t.price)?n.current.price===n.prev.price?i(""):n.current.price>n.prev.price?i("success"):n.current.price<n.prev.price&&i("danger"):i("")}),[n]),Object(c.useEffect)((function(){var e;return"success"!==s&&"danger"!==s||(e=setTimeout((function(){a((function(e){return e.map((function(e){var t,c;return(null===e||void 0===e||null===(t=e.current)||void 0===t?void 0:t.symbol)===(null===n||void 0===n||null===(c=n.current)||void 0===c?void 0:c.symbol)?{prev:Object(y.a)(Object(y.a)({},n.current),{},{price2:e.prev.price2}),current:Object(y.a)({},n.current)}:e}))})),i("")}),500)),function(){return clearTimeout(e)}}),[s,n,a]),(null===n||void 0===n||null===(t=n.current)||void 0===t?void 0:t.price)?Object($.jsxs)("td",{className:s,children:[hn(n.current.price,2),null!=n.current.price2&&null!=n.prev.price2&&Object($.jsxs)($.Fragment,{children:[n.current.price2>n.prev.price2&&Object($.jsx)("i",{className:"fas fa-chevron-up text-success float-end"}),n.current.price2<n.prev.price2&&Object($.jsx)("i",{className:"fas fa-chevron-down text-danger float-end"})]})]}):Object($.jsx)("td",{children:"-"})},mn=function(e){if(!Array.isArray(e))return[];var t=Object(v.a)(e).filter((function(e){var t;return null!=(null===e||void 0===e||null===(t=e.current)||void 0===t?void 0:t.changesPercentage)}));return t.sort((function(e,t){return(t.current.changesPercentage||0)-(e.current.changesPercentage||0)})),t},On={"^GSPC":"S&P","000001.SS":"SHANGHAI","^HSI":"HANG SENG","^AXJO":"ASX 200","^IXIC":"NASDAQ","^FCHI":"CAC","^TWII":"TAIWAN","^BSESN":"BSE","^GCUSD":"GOLD",EURUSD:"EUR/USD","^N225":"NIKKEI","^GDAXI":"DAX","^FTSE":"FTSE100","^DJI":"DOW",CLUSD:"
1CRUDE OIL","^NSEI":"NSE","^NSEBANK":"BANK NIFTY",USDINR:"USD/INR",RBUSD:"RBOB GAS","C=F":"CORN","^W1DOW":"DOW GLOBAL INDEX",BZUSD:"BRENT CRUDE","LH=F":"LEAN HOGS",HGUSD:"COPPER","^W2DOW":"DOW GLOBAL INDEX-EX",PAUSD:"PALLADIUM","BO=F":"SOYBEAN OIL","SM=F":"SOYBEAN MEAL",HOUSD:"HEATING OIL",SIUSD:"SILVER",CCUSD:"COCOA",OJUSX:"ORANGE JUICE",CTUSX:"COTTON","ZQ=F":"30-DAY FED FUND",FCUSX:"FEEDER CATTLE",KCUSX:"COFFEE",PLUSD:"PLATINUM","ZT=F":"2-YEAR T-NOTE","DX=F":"US DOLLAR",GCUSD:"GOLD",SBUSX:"SUGAR #11","ZF=F":"US 5-YEAR T-NOTE",OUSX:"OAT","ZN=F":"US 10-YEAR T-NOTE","LC=F":"LIVE CATTLE","RR=F":"ROUGH RICE",LBUSD:"RANDOM LENGTH","ZB=F":"US TREASURY BOND",NGUSD:"NATURAL GAS","LB=F":"LUMBER","KW=F":"WHEAT","FC=F":"FEEDER CATTLE","DC=F":"CLASS III MILK","O=F":"OAT","S=F":"SOYBEAN"},xn=function(e){var t=e.companies,n=e.label,a=e.filterType,r=e.classes,o=e.setCompanies,s=Object(c.useState)(null),i=Object(b.a)(s,2),l=i[0],d=i[1],j=Object(c.useState)(null),u=Object(b.a)(j,2),g=u[0],h=u[1],f=Object(c.useRef)(),p=function(){d(null),h(null)},m=Boolean(l),O={INDEX:{change:2,percentage:2},FOREX:{change:4,percentage:2},BONDS:{change:4,percentage:2},COMMODITY:{change:2,percentage:2},CRYPTO:{change:3,percentage:2}}[a]||{change:2,percentage:2};return Object($.jsxs)($.Fragment,{children:[Object($.jsx)("h4",{className:r.tableLabel,children:n}),Object($.jsxs)("table",{className:r.table,ref:f,children:[Object($.jsx)("thead",{children:Object($.jsxs)("tr",{children:[Object($.jsx)("th",{children:"Symbol"}),Object($.jsx)("th",{children:"Price"}),Object($.jsx)("th",{children:"Change"}),Object($.jsx)("th",{children:"Percentage"})]})}),Object($.jsx)("tbody",{children:mn(t).map((function(e){if(!(null===e||void 0===e?void 0:e.current))return null;if(!("BONDS"===a?"^TNX"===e.current.symbol:e.current.exchange===a&&!("INDEX"===a&&"^TNX"===e.current.symbol)))return null;var t=e.current.symbol,n="^"===(null===t||void 0===t?void 0:t[0])?t.slice(1):function(e){return On[e]||e}(t);return Object($.jsxs)("tr",{onMouseEnter:function(t){return n=t,void((c=e.current)&&(d(n.currentTarget),h(c)));var n,c},onMouseLeave:p,"aria-owns":m?"mouse-over-popover":void 0,"aria-haspopup":"true",children:[Object($.jsx)("td",{children:n}),Object($.jsx)(pn,{company:e,setCompanies:o}),Object($.jsxs)("td",{className:(e.current.change||0)>0?r.textSuccess:r.textDanger,children:[(e.current.change||0)>0?"+":"",hn(e.current.change,O.change)]}),Object($.jsxs)("td",{className:(e.current.changesPercentage||0)>0?r.textSuccess:r.textDanger,children:[(e.current.changesPercentage||0)>0?"+":"",hn(e.current.changesPercentage,O.percentage),"%"]})]},e.current._id)}))})]}),Object($.jsx)(dn.a,{id:"mouse-over-popover",className:r.popover,classes:{paper:r.paper},open:m,anchorEl:l,container:f.current,anchorOrigin:{vertical:"bottom",horizontal:"right"},transformOrigin:{vertical:"top",horizontal:"right"},onClose:p,disableRestoreFocus:!0,children:g&&Object($.jsxs)($.Fragment,{children:[Object($.jsxs)(fe.a,{children:["Name: ",g.name||"-"]}),Object($.jsxs)(fe.a,{children:["Day Low: ",hn(g.dayLow)]}),Object($.jsxs)(fe.a,{children:["Day High: ",hn(g.dayHigh)]}),Object($.jsxs)(fe.a,{children:["Year Low: ",hn(g.yearLow)]}),Object($.jsxs)(fe.a,{children:["Year High: ",hn(g.yearHigh)]}),Object($.jsxs)(fe.a,{children:["Open: ",hn(g.open)]}),Object($.jsxs)(fe.a,{children:["Previous Close: ",hn(g.previousClose)]}),Object($.jsxs)(fe.a,{children:["Volume: ",fn(g.volume)]})]})})]})},vn=function(e){var t=e.anchor,n=e.toggleDrawer,a=gn(),r=Object(c.useState)([]),o=Object(b.a)(r,2),s=o[0],i=o[1],l=Object(c.useState)(!0),d=Object(b.a)(l,2),j=d[0],u=d[1];return Object(c.useEffect)((function(){u(!0),jn().then((function(e){if(u(!1),Array.isArray(e))if(null===e||void 0===e?void 0:e.error)console.error(e.error);else{var t=e.map((function(e){return{prev:Object(y.a)(Object(y.a)({},e),{},{price2:e.price}),current:Object(y.a)(Object(y.a)({},e),{},{price2:e.price})}}));i(t)}else console.error("Invalid data format received")})).catch((function(e){console.error("Error fetching widget data:",e),u(!1)}))}),[]),Object(c.useEffect)((function(){var e=un()("".concat(U,"/socket"));return e.on("update",(function(e){(null===e||void 0===e?void 0:e._id)&&i((function(t){return t.map((function(t){var n,c;return(null===t||void 0===t||null===(n=t.current)||void 0===n?void 0:n._id)===e._id?{prev:Object(y.a)(Object(y.a)({},t.current),{},{price2:t.current.price}),current:Object(y.a)(Object(y.a)(Object(y.a)({},t.current),e),{},{price2:null!==(c=e.price)&&void 0!==c?c:t.current.price})}:t}))}))})),function(){null===e||void 0===e||e.disconnect()}}),[]),Object($.jsxs)("div",{className:a.list,role:"presentation",onClick:n(t,!1),onKeyDown:n(t,!1),children:[j&&Object($.jsx)(F.a,{color:"primary",className:a.loader,size:25}),!j&&0===(null===s||void 0===s?void 0:s.length)&&Object($.jsx)(Fe.a,{className:a.loader,severity:"info",children:"No screener found!"}),!j&&(null===s||void 0===s?void 0:s.length)>0&&Object($.jsxs)($.Fragment,{children:[Object($.jsx)(xn,{companies:s,label:"Indices",filterType:"INDEX",classes:a,setCompanies:i}),Object($.jsx)(xn,{companies:s,label:"Forex",filterType:"FOREX",classes:a,setCompanies:i}),Object($.jsx)(xn,{companies:s,label:"Bonds",filterType:"BONDS",classes:a,setCompanies:i}),Object($.jsx)(xn,{companies:s,label:"Commodities",filterType:"COMMODITY",classes:a,setCompanies:i}),Object($.jsx)(xn,{companies:s,label:"Crypto",filterType:"CRYPTO",classes:a,setCompanies:i})]})]})},yn=Object(f.a)((function(e){return{root:{flexGrow:1},menuButton:{marginRight:e.spacing(2)},footerBar:{background:"#000",top:"auto",bottom:0},title:{flexGrow:1},list:{width:450,padding:e.spacing(1),backgroundColor:"#27272e",color:"#9E9E9E",zIndex:"99999",height:"82% !important"},fullList:{width:"auto"},sidebar:{zIndex:"999999999 !important"}}})),wn=function(){var e=yn(),t=Object(c.useState)(!1),n=Object(b.a)(t,2),a=n[0],r=n[1],o=Object(c.useState)(0),s=Object(b.a)(o,2),i=s[0],l=s[1],d=Object(c.useState)(0),j=Object(b.a)(d,2),u=j[0],g=j[1],h=Object(c.useState)(0),f=Object(b.a)(h,2),v=(f[0],f[1]),S=Object(c.useState)(0),C=Object(b.a)(S,2),N=C[0],k=C[1],T=Object(c.useState)(!1),F=Object(b.a)(T,2),R=F[0],D=F[1],I=Object(c.useState)(!1),A=Object(b.a)(I,2),E=A[0],B=A[1],z=Object(c.useState)(!1),L=Object(b.a)(z,2),M=L[0],Y=L[1],_=Object(c.useState)(!1),P=Object(b.a)(_,2),U=P[0],G=P[1],W=Object(c.useState)(0),X=Object(b.a)(W,2),q=(X[0],X[1],Object(c.useState)(!1)),J=Object(b.a)(q,2),K=(J[0],J[1],Object(c.useState)({})),V=Object(b.a)(K,2),Q=(V[0],V[1],Object(c.useContext)(ze)),Z=Object(b.a)(Q,2),ee=Z[0],te=Z[1],ne=Object(c.useContext)(kt),ce=Object(b.a)(ne,2),ae=ce[0],re=ce[1],oe=H(),se=oe.user,ie=(oe.token,function(){r(!1)}),le=function(){B(!1)},de=function(){D(!1)},je=function(){Y(!1)},be=function(){G(!1)},ue=Object(c.useState)({top:!1,left:!1,bottom:!1,right:!1}),ge=Object(b.a)(ue,2),he=ge[0],pe=ge[1],me=function(e,t){return function(n){("keydown"!==n.type||"Tab"!==n.key&&"Shift"!==n.key)&&pe(Object(y.a)(Object(y.a)({},he),{},Object(x.a)({},e,t)))}};return Object($.jsxs)("div",{className:e.root,children:[Object($.jsxs)(p.a,{position:"fixed",className:e.footerBar,children:[Object($.jsxs)(m.a,{variant:"dense",children:[Object($.jsx)(fe.a,{className:e.title,variant:"h6",color:"inherit"}),"NO"===se.trial&&Object($.jsxs)($.Fragment,{children:[Object($.jsx)(Pe.a,{title:"Speech",placement:"top",children:Object($.jsx)(w.a,{color:"primary",children:ee?Object($.jsx)(He.a,{style:{color:"#fff"},onClick:function(){return te(!ee)}}):Object($.jsx)(st.a,{style:{color:"#fff"},onClick:function(){return te(!ee)}})})}),Object($.jsx)(Pe.a,{title:"Story",placement:"top",children:Object($.jsx)(w.a,{color:"primary",style:{color:"#fff"},onClick:function(){re(!1),G(!0),v((function(e){return e+1}))},children:ae?Object($.jsx)(Ue.a,{color:"secondary",variant:"dot",children:Object($.jsx)(jt.a,{})}):Object($.jsx)(jt.a,{})})}),Object($.jsx)(Pe.a,{title:"Sniper",placement:"top",children:Object($.jsx)(w.a,{color:"primary",style:{color:"#fff"},onClick:function(){B(!0)},children:Object($.jsx)(ut.a,{})})}),Object($.jsx)(Pe.a,{title:"Trending",placement:"top",children:Object($.jsx)(w.a,{color:"primary",style:{color:"#fff"},onClick:function(){D(!0),k((function(e){return e+1}))},children:Object($.jsx)(Pt.a,{})})}),Object($.jsx)(Pe.a,{title:"Briefcase",placement:"top",children:Object($.jsx)(w.a,{color:"primary",style:{color:"#fff"},onClick:function(){Y(!0),l((function(e){return e+1}))},children:Object($.jsx)(lt.a,{})})})]}),"YES"===se.trial&&Object($.jsxs)($.Fragment,{children:[Object($.jsx)(Pe.a,{title:"Speech",placement:"top",children:Object($.jsx)(w.a,{color:"primary",children:Object($.jsx)(st.a,{style:{color:"#fff"}})})}),Object($.jsx)(Pe.a,{title:"Story",placement:"top",children:Object($.jsx)(w.a,{color:"primary",style:{color:"#fff"},children:Object($.jsx)(jt.a,{})})}),Object($.jsx)(Pe.a,{title:"Sniper",placement:"top",children:Object($.jsx)(w.a,{color:"primary",style:{color:"#fff"},children:Object($.jsx)(ut.a,{})})}),Object($.jsx)(Pe.a,{title:"Trending",placement:"top",children:Object($.jsx)(w.a,{color:"primary",style:{color:"#fff"},children:Object($.jsx)(Pt.a,{})})}),Object($.jsx)(Pe.a,{title:"Briefcase",placement:"top",children:Object($.jsx)(w.a,{color:"primary",style:{color:"#fff"},children:Object($.jsx)(lt.a,{})})})]}),Object($.jsx)(Pe.a,{title:"Screener",placement:"top",children:Object($.jsx)(w.a,{color:"primary",style:{color:"#fff"},onClick:me("right",!0),children:Object($.jsx)(ln.a,{})})}),Object($.jsx)(Pe.a,{title:"Settings",placement:"top",children:Object($.jsx)(w.a,{color:"primary",style:{color:"#fff"},onClick:function(){g((function(e){return e+1})),r(!0)},children:Object($.jsx)(qe.a,{})})})]}),Object($.jsx)(Ge.a,{anchor:"right",open:he.right,onClose:me("right",!1),className:e.sidebar,children:Object($.jsx)(vn,{toggleDrawer:me,anchor:"right"})})]}),Object($.jsx)(O.a,{open:a,onClose:ie,children:rt(ie,u)}),Object($.jsx)(O.a,{open:M,onClose:je,children:vt(je,i)}),Object($.jsx)(O.a,{open:E,onClose:le,children:Yt(le)}
1),Object($.jsx)(O.a,{open:U,onClose:be,children:Dt(be)}),Object($.jsx)(O.a,{open:R,onClose:de,children:Object($.jsx)(on,{handleClose:de,count:N})})]})},Sn=function(){var e=pe(),t=Object(c.useState)([]),n=Object(b.a)(t,2),a=n[0],r=n[1],o=Object(c.useState)(!1),s=Object(b.a)(o,2),i=s[0],l=s[1],u=Object(c.useState)(!1),g=Object(b.a)(u,2),h=g[0],f=g[1],p=Object(c.useState)(1),m=Object(b.a)(p,2),O=m[0],x=m[1],y=Object(c.useRef)(),w=Object(c.useRef)(),S=H(),C=S.user,N=S.token,k=Object(c.useContext)(Ne),T=Object(b.a)(k,2),R=T[0],D=(T[1],Object(c.useContext)(ue)),I=Object(c.useContext)(Ee),A=Object(b.a)(I,2),E=A[0];A[1];Object(c.useEffect)((function(){return D.on("newGlobal",function(){var e=Object(j.a)(d.a.mark((function e(t){return d.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:t.isRedboxFeed&&"Global"===t.category?E.rFeeds&&r((function(e){return Object(v.a)(new Set([t].concat(Object(v.a)(e))))})):t.isCrawlerFeed&&t.global&&E.cFeeds&&r((function(e){return Object(v.a)(new Set([t].concat(Object(v.a)(e))))}));case 1:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()),D.on("deletedGlobal",(function(e){ye(C._id,N,29,O).then((function(e){e.error?f(e.error):(x(1),r(Object(v.a)(new Set(Object(v.a)(e)))))})).catch((function(e){f("Not able to fetch")}))})),function(){return D.off("newGlobal")}}),[C._id,N,C.email,D,E]),Object(c.useEffect)((function(){l(!0),ye(C._id,N,29,O).then((function(e){e.error?(f(e.error),l(!1)):(r(1===O?e:function(t){return Object(v.a)(new Set([].concat(Object(v.a)(t),Object(v.a)(e))))}),l(!1))})).catch((function(e){l(!1),f("Not able to fetch")}))}),[C._id,N,O]),Object(c.useEffect)((function(){R&&(x(1),l(!0),ye(C._id,N,29,O).then((function(e){e.error?(f(e.error),l(!1)):(r(e),l(!1))})).catch((function(e){l(!1),f("Not able to fetch")})))}),[R]);var B,z;return Object($.jsx)($.Fragment,{children:Object($.jsxs)("div",{className:"".concat(e.box," ").concat(e.boxContainer," ").concat(e.one),children:[i&&Object($.jsx)("div",{className:e.loader,children:Object($.jsx)(F.a,{size:40,className:e.loaderIcon})}),Object($.jsxs)(fe.a,{className:e.title,variant:"body2",children:["global",Object($.jsx)("i",{onClick:function(){y.current.scrollTo({top:0,behavior:"smooth"}),r([]),x(0)},ref:w,className:"fas fa-angle-up ".concat(e.scrollToTopBtnStyle),style:{display:"none"}})]}),Object($.jsx)("div",{className:e.desc,ref:y,onScroll:function(){var e=y.current,t=e.scrollHeight,n=e.clientHeight,c=e.scrollTop,a=t-n;w.current.style.display=c/a>.1?"inline":"none"},id:"scrollableGlobalBox",children:Object($.jsxs)(ae.a,{dataLength:a.length,next:function(){return x(O+1)},hasMore:!0,scrollableTarget:"scrollableGlobalBox",children:[(B=a,z="_id",Object(v.a)(new Map(B.map((function(e){return[e[z],e]}))).values())).map((function(t,n,a){return Object($.jsxs)(c.Fragment,{children:[n>0?q()(t.createdAt).format("MMM DD, YYYY")!==q()(a[n-1].createdAt).format("MMM DD, YYYY")&&Object($.jsxs)("div",{className:e.dateDivider,children:[Object($.jsx)("div",{className:e.dateDividerLine}),Object($.jsx)("div",{children:q()(t.createdAt).format("MMM DD, YYYY")}),Object($.jsx)("div",{className:e.dateDividerLine})]}):"",Object($.jsxs)("tr",{className:e.tableRow,children:[Object($.jsx)("td",{style:(null===t||void 0===t?void 0:t.isCrawlerFeed)?{marginRight:"9px",color:"#d9d9d9"}:{marginRight:"9px"},children:q()(t.createdAt).format("HH:mm:ss")}),Object($.jsx)(ce,{className:e.tableCellDesc,news:t,value:t.isTwitterFeed?t.payload:t.isCrawlerFeed?t.article.title:t.description})]})]},t._id)})),Object($.jsx)("div",{children:h&&"Error"})]})})]})})},Cn=function(){var e=pe(),t=Object(c.useState)([]),n=Object(b.a)(t,2),a=n[0],r=n[1],o=Object(c.useState)(!0),s=Object(b.a)(o,2),i=s[0],l=s[1],u=Object(c.useState)(!1),g=Object(b.a)(u,2),h=g[0],f=g[1],p=Object(c.useState)(1),m=Object(b.a)(p,2),O=m[0],x=m[1],y=Object(c.useRef)(),w=Object(c.useRef)(),S=H(),C=S.user,N=S.token,k=Object(c.useContext)(Ne),T=Object(b.a)(k,2),R=T[0],D=(T[1],Object(c.useContext)(ue)),I=Object(c.useContext)(Ee),A=Object(b.a)(I,2),E=A[0];A[1];Object(c.useEffect)((function(){return D.on("newGlobal",function(){var e=Object(j.a)(d.a.mark((function e(t){return d.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:t.isRedboxFeed&&"Fixed Income"===t.category?E.rFeeds&&r((function(e){return Object(v.a)(new Set([t].concat(Object(v.a)(e))))})):t.isCrawlerFeed&&t.fixedincome&&E.cFeeds&&r((function(e){return Object(v.a)(new Set([t].concat(Object(v.a)(e))))}));case 1:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()),D.on("deletedGlobal",(function(e){Ce(C._id,N,29,O).then((function(e){e.error?f(e.error):(x(1),r(Object(v.a)(new Set(Object(v.a)(e)))))})).catch((function(e){f("Not able to fetch")}))}
1)),function(){return D.off("newGlobal")}}),[C._id,N,C.email,D,E]),Object(c.useEffect)((function(){l(!0),Ce(C._id,N,29,O).then((function(e){e.error?(f(e.error),l(!1)):(r(1===O?e:function(t){return Object(v.a)(new Set([].concat(Object(v.a)(t),Object(v.a)(e))))}),l(!1))})).catch((function(e){l(!1),f("Not able to fetch")}))}),[C._id,N,O]),Object(c.useEffect)((function(){R&&(x(1),l(!0),Ce(C._id,N,29,O).then((function(e){e.error?(f(e.error),l(!1)):(r(e),l(!1))})).catch((function(e){l(!1),f("Not able to fetch")})))}),[R]);var B,z;return Object($.jsx)($.Fragment,{children:Object($.jsxs)("div",{className:"".concat(e.box," ").concat(e.five),children:[i&&Object($.jsx)("div",{className:e.loader,children:Object($.jsx)(F.a,{size:40,className:e.loaderIcon})}),Object($.jsxs)(fe.a,{color:"secondary",className:e.title,variant:"body2",children:["FIXED INCOME",Object($.jsx)("i",{onClick:function(){y.current.scrollTo({top:0,behavior:"smooth"}),r([]),x(0)},ref:w,className:"fas fa-angle-up ".concat(e.scrollToTopBtnStyle),style:{display:"none"}})]}),Object($.jsx)("div",{className:e.desc,ref:y,onScroll:function(){var e=y.current,t=e.scrollHeight,n=e.clientHeight,c=e.scrollTop,a=t-n;w.current.style.display=c/a>.1?"inline":"none"},id:"scrollableIncomeBox",children:Object($.jsxs)(ae.a,{dataLength:a.length,next:function(){return x(O+1)},hasMore:!0,scrollableTarget:"scrollableIncomeBox",children:[(B=a,z="_id",Object(v.a)(new Map(B.map((function(e){return[e[z],e]}))).values())).map((function(t,n,a){return Object($.jsxs)(c.Fragment,{children:[n>0?q()(t.createdAt).format("MMM DD, YYYY")!==q()(a[n-1].createdAt).format("MMM DD, YYYY")&&Object($.jsxs)("div",{className:e.dateDivider,children:[Object($.jsx)("div",{className:e.dateDividerLine}),Object($.jsx)("div",{children:q()(t.createdAt).format("MMM DD, YYYY")}),Object($.jsx)("div",{className:e.dateDividerLine})]}):"",Object($.jsxs)("tr",{className:e.tableRow,children:[Object($.jsx)("td",{style:(null===t||void 0===t?void 0:t.isCrawlerFeed)?{marginRight:"9px",color:"#d9d9d9"}:{marginRight:"9px"},children:q()(t.createdAt).format("HH:mm:ss")}),Object($.jsx)(ce,{className:e.tableCellDesc,news:t,value:t.isTwitterFeed?t.payload:t.isCrawlerFeed?t.article.title:t.description})]})]},t._id)})),Object($.jsx)("div",{children:h&&"Error"})]})})]})})},Nn=(n(297),Object(c.createContext)()),kn=function(e){var t=e.children,n=Object(c.useState)(!1),a=Object(b.a)(n,2),r=a[0],o=a[1];return Object($.jsx)(Nn.Provider,{value:[r,o],children:t})},Tn=n(948),Fn=n(121),Rn=n(122),Dn=n(209),In=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2;if(null==e)return"-";var n=parseFloat(e);return isNaN(n)?"-":n.toFixed(t)},An=function(e){if(null==e)return"-";if("number"===typeof e){var t=e.toString().split(".");return t[0].length>=5&&(t[0]=t[0].replace(/(\d)(?=(\d{3})+$)/g,"$1,")),t[1]&&t[1].length>=5&&(t[1]=t[1].replace(/(\d{3})/g,"$1 ")),t.join(".")}return String(e)},En=Object(f.a)((function(e){return{root:{position:"absolute",color:"#FFF",zIndex:"9999",top:"0",left:"0",right:"0",margin:"0 auto",width:"max-content",height:"48px",display:"flex"},container:{marginRight:e.spacing(1),borderRight:"1px solid #212121",cursor:"pointer",padding:e.spacing(0,1,0,1),"&:last-child":{borderRight:"0"}},row:{marginTop:e.spacing(1)},symbol:{fontSize:"12px",float:"left",marginRight:e.spacing(2),textTransform:"uppercase",color:"#F5F5F5",display:"flex"},price:{fontSize:"12px",float:"right",color:"#F5F5F5"},change:{fontSize:"12px",color:"#F44336"},percentage:{marginRight:e.spacing(2),fontSize:"12px",color:"#F44336"},fontIconRed:{color:Fn.a[500]},fontIconGreen:{color:Rn.a[500]},textRed:{color:"#F44336 !important"},textGreen:{color:"#4CAF50 !important"},popover:{pointerEvents:"none"},paper:{padding:e.spacing(1),backgroundColor:"#27272e",color:"#9E9E9E"},avatarRed:{width:e.spacing(2),height:e.spacing(2),color:e.palette.getContrastText(Fn.a[500]),backgroundColor:Fn.a[500],fontSize:"9px"},avatarGreen:{width:e.spacing(2),height:e.spacing(2),color:"#fff",backgroundColor:Rn.a[500],fontSize:"9px"}}})),Bn=Object(c.memo)((function(e){var t,n=e.company,a=e.classes,r=e.setCompanies,o=Object(c.useState)(""),s=Object(b.a)(o,2),i=s[0],l=s[1];return Object(c.useEffect)((function(){var e,t;(null===n||void 0===n||null===(e=n.current)||void 0===e?void 0:e.price)&&(null===n||void 0===n||null===(t=n.prev)||void 0===t?void 0:t.price)?n.current.price===n.prev.price?l(""):n.current.price>n.prev.price?l("success"):n.current.price<n.prev.price&&l("danger"):l("")}),[n]),Object(c.useEffect)((function(){var e;return"success"!==i&&"danger"!==i||(e=setTimeout((function(){r((function(e){return e.map((function(e){var t,c;return(null===e||void 0===e||null===(t=e.current)||void 0===t?void 0:t.symbol)===(null===n||void 0===n||null===(c=n.current)||void 0===c?void 0:c.symbol)?{prev:Object(y.a)(Object(y.a)({},n.current),{},{price2:e.prev.price2}),current:Object(y.a)({},n.current)}:e}))})),l("")}),500)),function(){return clearTimeout(e)}}),[i,n,r]),(null===n||void 0===n||null===(t=n.current)||void 0===t?void 0:t.price)?Object($.jsxs)("span",{className:"".concat(a.price," ").concat(i),children:[null!=n.current.price2&&null!=n.prev.price2&&Object($.jsxs)($.Fragment,{children:[n.current.price2>n.prev.price2&&Object($.jsx)("i",{className:"fas fa-chevron-up ".concat(a.fontIconGreen)}),n.current.price2<n.prev.price2&&Object($.jsx)("i",{className:"fas fa-chevron-down ".concat(a.fontIconRed)})]}),Object($.jsx)("span",{style:{marginLeft:"3px"},children:"EURUSD"===n.current.symbol?In(n.current.price,4):An(n.current.price)})]}):null})),zn=function(e){var t=e.widgetShow,n=Object(Tn.a)("(min-width:1275px)"),a=Object(Tn.a)("(min-width:1600px)"),r=En(),o=Object(c.useState)([]),s=Object(b.a)(o,2),i=s[0],l=s[1],d=Object(c.useState)(null),j=Object(b.a)(d,2),u=j[0],g=j[1],h=Object(c.useState)(null),f=Object(b.a)(h,2),p=f[0],m=f[1],O=Object(c.useState)(6),x=Object(b.a)(O,2),v=x[0],w=x[1],S=["^DJI","DOW FUTURES","^GSPC","^IXIC","^N225","^GDAXI","EURUSD","CLUSD","GCUSD","BTCUSD"];Object(c.useEffect)((function(){jn().then((function(e){if(Array.isArray(e)){var t=e.sort((function(e,t){return S.indexOf((null===e||void 0===e?void 0:e.symbol)||"")-S.indexOf((null===t||void 0===t?void 0:t.symbol)||"")})).map((function(e){return{prev:Object(y.a)(Object(y.a)({},e),{},{price2:e.price}),current:Object(y.a)(Object(y.a)({},e),{},{price2:e.price})}}));l(t)}else console.error("Invalid data format received")})).catch((function(e){console.error("Error fetching widget data:",e),l([])}))}),[]),Object(c.useEffect)((function(){var e=un()("".concat(U,"/socket"));return e.on("update",(function(e){(null===e||void 0===e?void 0:e._id)&&l((function(t){return t.map((function(t){var n,c;return(null===t||void 0===t||null===(n=t.current)||void 0===n?void 0:n._id)===e._id?{prev:Object(y.a)(Object(y.a)({},t.current),{},{price2:t.current.price}),current:Object(y.a)(Object(y.a)(Object(y.a)({},t.current),e),{},{price2:null!==(c=e.price)&&void 0!==c?c:t.current.price})}:t}))}))})),function(){null===e||void 0===e||e.disconnect()}}),[]),Object(c.useEffect)((function(){w(a?9:6)}
1),[a]);var C={"^GSPC":"S&P","^BSESN":"BSE","^GCUSD":"GOLD",EURUSD:"EUR/USD","^N225":"NIKKEI","^GDAXI":"DAX","DOW FUTURES":"US 30","^IXIC":"NASDAQ","^DJI":"DOW",CLUSD:"CRUDE OIL"},N=function(e){return C[e]||e},k=new Set(["BTCUSD","^N225","DOW FUTURES","^GSPC","^DJI","^GDAXI","EURUSD","GCUSD","CLUSD"]),T=function(){g(null),m(null)},F=Boolean(u);if(!n||!t)return null;var R=0;return Object($.jsxs)("div",{className:r.root,children:[i.map((function(e){var t;if(!(null===e||void 0===e||null===(t=e.current)||void 0===t?void 0:t.symbol)||R>=v)return null;if(!function(e){return k.has(e)}(e.current.symbol))return null;R++;var n=e.current.symbol,c=("^"===n[0]?n.slice(1):n)[0]||"";return Object($.jsxs)("div",{className:r.container,onMouseEnter:function(t){return n=t,void((c=e.current)&&(g(n.currentTarget),m(c)));var n,c},onMouseLeave:T,"aria-owns":F?"mouse-over-popover":void 0,"aria-haspopup":"true",children:[Object($.jsxs)("div",{className:r.row,children:[Object($.jsxs)("span",{className:r.symbol,children:["BTCUSD"===n?Object($.jsx)(Dn.a,{name:"btc",size:12}):Object($.jsx)(Je.a,{className:(e.current.changesPercentage||0)>0?r.avatarGreen:r.avatarRed,children:c}),Object($.jsx)("span",{style:{marginLeft:"5px"},children:N(n)})]}),Object($.jsx)(Bn,{company:e,classes:r,setCompanies:l})]}),Object($.jsxs)("div",{className:r.row,children:[Object($.jsx)("span",{className:r.percentage,children:Object($.jsxs)("span",{style:{marginLeft:"0px"},className:(e.current.changesPercentage||0)>0?r.textGreen:r.textRed,children:[In(e.current.changesPercentage,2),"%"]})}),Object($.jsx)("span",{className:(e.current.change||0)>0?"".concat(r.change," ").concat(r.textGreen):"".concat(r.change," ").concat(r.textRed),children:In(e.current.change,2)})]})]},e.current._id)})),Object($.jsx)(dn.a,{id:"mouse-over-popover",className:r.popover,classes:{paper:r.paper},open:F,anchorEl:u,anchorOrigin:{vertical:"bottom",horizontal:"left"},transformOrigin:{vertical:"top",horizontal:"left"},onClose:T,disableRestoreFocus:!0,children:p&&Object($.jsxs)($.Fragment,{children:[Object($.jsxs)(fe.a,{children:["Day Low: ",In(p.dayLow)]}),Object($.jsxs)(fe.a,{children:["Day High: ",In(p.dayHigh)]}),Object($.jsxs)(fe.a,{children:["Year Low: ",In(p.yearLow)]}),Object($.jsxs)(fe.a,{children:["Year High: ",In(p.yearHigh)]}),Object($.jsxs)(fe.a,{children:["Open: ",In(p.open)]}),Object($.jsxs)(fe.a,{children:["Previous Close: ",In(p.previousClose)]}),Object($.jsxs)(fe.a,{children:["Volume: ",An(p.volume)]})]})})]})},Ln=function(e){var t,n=e.history,a=pe(),r=H(),o=r.user,s=r.token,i="".concat(P,"/socket"),l=Object(c.useState)(window.navigator.onLine),u=Object(b.a)(l,2),f=u[0],p=u[1],m=Object(c.useState)(!1),O=Object(b.a)(m,2),x=O[0],v=O[1],y=Object(c.useState)(!1),w=Object(b.a)(y,2),S=w[0],C=w[1],N=Object(c.useState)(!0),k=Object(b.a)(N,2),T=k[0],F=k[1],R=Object(c.useState)("NA"),D=Object(b.a)(R,2),I=D[0],A=D[1],E=Object(c.useState)(null),B=Object(b.a)(E,2),z=B[0],L=B[1],M=Object(c.useContext)(je),Y=Object(b.a)(M,2),_=(Y[0],Y[1]),U=function(){var e=Object(j.a)(d.a.mark((function e(){var t;return d.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,g.a.get("https://api.ipify.org/?format=json");case 2:200===(null===(t=e.sent)||void 0===t?void 0:t.status)?A(t.data.ip):A("NA");case 4:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}();return Object(c.useEffect)((function(){U()}),[]),Object(c.useEffect)((function(){var e=un()(i,{query:{token:s,id:o._id,email:o.email,ip:I}});L(e)}),[I]),Object(c.useEffect)((function(){window.addEventListener("offline",(function(e){p(!1),v(!1),C(!0)})),window.addEventListener("online",(function(e){p(!0),x||v(!0)}))}),[]),Object(c.useEffect)((function(){x&&setTimeout((function(){window.location.reload()}),3e3)}),[x]),Object(c.useEffect)((function(){return t=setInterval((function(){(function(e,t){return fetch("".concat(P,"/check/double/login/").concat(e),{method:"GET",headers:{Accept:"application/json",Authorization:"Bearer ".concat(t)}}).then((function(e){return e.json()})).catch((function(e){return console.log(e)}))})(o._id,s).then((function(e){e.error&&console.log(e.error),e.status&&W((function(){z.disconnect(),clearInterval(t),n.push("/signin")}))})).catch((function(e){console.log("Not able to fetch")}))}),2e4),_(t),function(){clearInterval(t)}}),[o._id,s,z]),Object($.jsx)($.Fragment,{children:Object($.jsx)(Tt,{children:Object($.jsx)(ne,{children:Object($.jsx)(ee,{children:Object($.jsx)(ke,{children:Object($.jsx)(Le,{children:Object($.jsx)(nt,{children:Object($.jsx)(Be,{children:Object($.jsx)(Qt,{children:null!==z&&Object($.jsxs)(ue.Provider,{value:z,children:[S&&Object($.jsx)("p",{style:{position:"absolute",zIndex:"1",color:"#fff",background:f?"green":"red",padding:"1px 9px",width:"100%",top:"34px"},children:f?"You are connected!":"You are offline..."}
1),Object($.jsx)(he,{setWidgetShow:F}),Object($.jsx)(zn,{widgetShow:T}),Object($.jsx)(h.a,{className:a.root,children:Object($.jsx)(kn,{children:Object($.jsxs)(Oe,{children:[Object($.jsx)(Sn,{}),Object($.jsx)(Me,{}),Object($.jsx)(Ye,{}),Object($.jsx)(_e,{}),Object($.jsx)(Cn,{})]})})}),Object($.jsx)(wn,{})]})})})})})})})})})})},Mn=n(949),Yn=n(194),_n=n.n(Yn),Pn=n(195),Un=n.n(Pn),Gn=Object(f.a)((function(e){return{root:{color:"#fff",margin:e.spacing(2,0)},container:{width:"90%",margin:"auto"},test:{border:"2px solid #fff"},icons:{marginTop:e.spacing(4),marginBottom:e.spacing(4),margin:"auto",display:"block",fontSize:"4rem"}}})),Wn=function(){var e=Gn();return Object($.jsx)($.Fragment,{children:Object($.jsx)(h.a,{component:"div",className:e.root,children:Object($.jsxs)(S.a,{container:!0,justify:"center",className:e.container,spacing:3,children:[Object($.jsxs)(S.a,{item:!0,xs:10,sm:6,md:4,children:[Object($.jsx)(E.a,{color:"primary",className:e.icons}),Object($.jsx)(fe.a,{variant:"h6",align:"center",gutterBottom:!0,children:"REDBOX CHAT"}),Object($.jsx)(fe.a,{variant:"body2",align:"center",gutterBottom:!0,children:"Redbox has an encrypted chat facility enabling you to stay on one page, receiving any important news whilst chatting with your friends or brokers. Discussing what the news means for your trading decisions."})]}),Object($.jsxs)(S.a,{item:!0,xs:10,sm:6,md:4,children:[Object($.jsx)(_n.a,{style:{color:"#4caf50"},className:e.icons}),Object($.jsx)(fe.a,{variant:"h6",align:"center",gutterBottom:!0,children:"REDBOX ANALYSTS"}),Object($.jsx)(fe.a,{variant:"body2",align:"center",gutterBottom:!0,children:"Our Redbox Analysts have over 100 years of combined experience in the financial markets. Our analysts live and breathe the markets, seeking the best opportunity for profits."})]}),Object($.jsxs)(S.a,{item:!0,xs:10,sm:6,md:4,children:[Object($.jsx)(Un.a,{color:"secondary",className:e.icons}),Object($.jsx)(fe.a,{variant:"h6",align:"center",gutterBottom:!0,children:"REDBOX API"}),Object($.jsx)(fe.a,{variant:"body2",align:"center",gutterBottom:!0,children:"Redbox can provide you an API which can be integrated to your trading platforms and mobile applications, giving you more flexibility on how to receive your news."})]})]})})})},Hn=n(199),Xn=n.n(Hn),qn=n(196),Jn=n.n(qn),Kn=n(197),Vn=n.n(Kn),Qn=n(198),$n=n.n(Qn),Zn=n(118),ec=n.n(Zn),tc=[{label:"home",href:"/",startIcon:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default";return Object($.jsx)(Jn.a,{fontSize:e})},buttonType:"text",mobileStyle:{}},{label:"about us",href:"/aboutus",startIcon:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default";return Object($.jsx)(Vn.a,{fontSize:e})},buttonType:"text",mobileStyle:{}},{label:"pricing",href:"/pricing",startIcon:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default";return Object($.jsx)($n.a,{fontSize:e})},buttonType:"text",mobileStyle:{}},{label:"contact us",href:"/contact",startIcon:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default";return Object($.jsx)(ec.a,{fontSize:e})},buttonType:"text",mobileStyle:{}},{label:"signup",href:"/signup",startIcon:function(){},buttonType:"contained",mobileStyle:{width:"100%"}},{label:"signin",href:"/signin",startIcon:function(){},buttonType:"contained",mobileStyle:{width:"100%"}}],nc=Object(f.a)((function(){return{header:{backgroundColor:"#000","@media (max-width: 900px)":{paddingLeft:0}},logo:{width:"150px"},toolbar:{display:"flex",justifyContent:"space-between"},drawerContainer:{padding:"20px 30px"}}})),cc=function(){var e=nc(),t=e.header,n=e.logo,a=e.toolbar,r=e.drawerContainer,o=Object(c.useState)({mobileView:!1,drawerOpen:!1}),i=Object(b.a)(o,2),l=i[0],d=i[1],j=l.mobileView,u=l.drawerOpen;Object(c.useEffect)((function(){var e=function(){return window.innerWidth<900?d((function(e){return Object(y.a)(Object(y.a)({},e),{},{mobileView:!0})})):d((function(e){return Object(y.a)(Object(y.a)({},e),{},{mobileView:!1})}))};return e(),window.addEventListener("resize",(function(){return e()})),function(){window.removeEventListener("resize",(function(){return e()}))}}),[]);var g=function(){var e={marginBottom:"10px"};return tc.map((function(t,n){var c=t.label,a=t.href,r=t.startIcon,o=t.buttonType,i=t.mobileStyle;return Object($.jsx)("div",{style:e,children:Object($.jsx)(s.b,{to:a,style:{textDecoration:"none"},children:Object($.jsx)(C.a,{variant:o,style:i,color:"primary",startIcon:r("small"),children:c})})},c)}))},h=Object($.jsx)("img",{src:"https://i.ibb.co/3WvpRDm/logo.png",alt:"",className:n}),f=function(){var e={marginLeft:"10px",color:"#FFF"};return tc.map((function(t,n){var c=t.label,a=t.href,r=t.startIcon,o=t.buttonType;return Object($.jsx)(s.b,{to:a,style:{textDecoration:"none"},children:Object($.jsx)(C.a,{style:e,variant:o,startIcon:r(),color:"primary",children:c})},c)}))};return Object($.jsx)(p.a,{className:t,children:Object($.jsx)(Mn.a,{maxWidth:"lg",children:j?Object($.jsxs)(m.a,{children:[Object($.jsx)(w.a,{edge:"start","aria-label":"menu","aria-haspopup":"true",onClick:function(){return d((function(e){return Object(y.a)(Object(y.a)({},e),{},{drawerOpen:!0})}))},children:Object($.jsx)(Xn.a,{style:{color:"#fff"}})}),Object($.jsx)(Ge.a,{anchor:"right",open:u,onClose:function(){return d((function(e){return Object(y.a)(Object(y.a)({},e),{},{drawerOpen:!1})}))},children:Object($.jsx)("div",{className:r,children:g()})}),Object($.jsx)("div",{children:Object($.jsx)(s.b,{to:"/",style:{textDecoration:"none"},children:h})})]}):Object($.jsxs)(m.a,{className:a,children:[Object($.jsx)(s.b,{to:"/",style:{textDecoration:"none",margin:"0"},children:h}),Object($.jsx)("div",{children:f()})]})})})},ac=Object(f.a)((function(e){return{root:{marginTop:"5rem"},container:{backgroundColor:"#000",color:"#fff",minHeight:"90vh",borderRadius:"6px",padding:"0 24px"},title:{padding:"2rem 0 1rem 0"},copyrightText:{color:"#fff",margin:"1.5rem 0 1.5rem 0"}}})),rc=function(e){var t=e.title,n=e.children,c=ac();return Object($.jsxs)($.Fragment,{children:[Object($.jsx)(cc,{}
1),Object($.jsx)(Mn.a,{maxWidth:"lg",className:c.root,children:Object($.jsxs)(h.a,{component:"div",className:c.container,children:[Object($.jsx)(fe.a,{align:"center",variant:"h4",className:c.title,children:t}),Object($.jsx)(h.a,{component:"div",children:n})]})}),Object($.jsx)(fe.a,{className:c.copyrightText,variant:"body2",gutterBottom:!0,align:"center",children:"\xa9Redboxglobal, All rights reserved to www.redboxglobal.com"})]})},oc=Object(f.a)((function(e){return{paragraph:{margin:"1rem 0"},list:{margin:"1rem 0",fontSize:"1rem"}}})),sc=function(){var e=oc();return Object($.jsx)($.Fragment,{children:Object($.jsxs)(rc,{title:"About Us",children:[Object($.jsx)(fe.a,{align:"center",variant:"h6",children:"The Fastest News feed Service For Market Moving News"}),Object($.jsxs)(Mn.a,{maxWidth:"md",children:[Object($.jsx)(fe.a,{align:"justify",variant:"body1",className:e.paragraph,children:"Redbox is a platform which utilizes proprietary algorithms, a network of traders, brokers, journalists, and analysts helping us deliver the best information you need when it breaks. We deliver the earliest possible alerts of the real-time emerging market-moving news. Our software then uses its alert urgency ranking feature to deliver tailored insights to make decisions quickly. This helps you make better decisions within the financial markets and how best to place positions on the buy and sell side, with a better insight comes better opportunities for profitable decisions."}),Object($.jsx)(fe.a,{align:"justify",variant:"body1",className:e.paragraph,children:"Financial professionals are using Redbox to learn about market-moving events sooner and generating trading signals faster. Redbox gathers all your news in one place from USA Non-Farm Payroll data the moment it is announced to the latest agricultural production numbers. Instead of spending all day searching multiple news websites, blogs and forums we condense all of this information in one place to help you place trades more intelligently and having a better understanding of why the market may move. As well as reading the news, our fundamental and technical analysts can help guide you on where they can see emerging opportunities and good places to book your profits."}),Object($.jsx)(fe.a,{align:"justify",variant:"body1",className:e.paragraph,children:"Social media has changed the landscape of reporting news, utilizing our powerful API we have created a global sensor. No longer do you have to scroll endlessly through websites, newsletters, blogs, and reports yourself. No longer do you have to wait from the moment the news breaks for a journalist to write up an article and for it to be approved to then for it to be put on a site or sent out as a newsletter when the market has already moved. You are no longer last to know, our news comes to you direct, enabling you to act faster than ever before, cutting out middlemen and enabling you to gain an advantage over the competition."}),Object($.jsx)(fe.a,{align:"center",variant:"h4",className:e.paragraph,children:"Redbox Key Features"}),Object($.jsxs)("ul",{className:e.list,children:[Object($.jsxs)("li",{children:["Delivers news on Equities, fixed income, FX and commodities"," "]}),Object($.jsx)("li",{children:"Proprietary ranking system orders the news in market-moving importance"}),Object($.jsx)("li",{children:"We scan social media for the market moving news you need"}),Object($.jsx)("li",{children:"An alert feature on highest priority news"}),Object($.jsx)("li",{children:"An encrypted messaging service to stay in contact with brokers and fellow traders"}),Object($.jsx)("li",{children:"Our selected group of analysts don't just tell you their thoughts, they provide unrivalled country coverage, including economic, political and risk analysis"}),Object($.jsx)("li",{children:"An API available on request to integrate into mobile and trading applications"})]})]}),Object($.jsx)(Wn,{})]})})},ic=n(200),lc=n.n(ic),dc=n(201),jc=n.n(dc),bc=Object(f.a)((function(e){return{root:{color:"#fff",margin:"10rem 0"},container:{width:"80%",margin:"3rem auto"},cardContainer:{"@media (max-width: 500px)":{display:"flex",justifyContent:"flex-start"}},icons:{fontSize:"2rem"},tableCell:{paddingLeft:"10px"},listItem:{listStyleType:"none",padding:"0","& li":{margin:e.spacing(2,0)},"& li p":{margin:0}}}})),uc=function(e){var t=e.addMargin,n=void 0===t||t,c=bc();return Object($.jsx)($.Fragment,{children:Object($.jsxs)(h.a,{component:"div",className:c.root,style:n?{margin:"10rem 0"}:{margin:"0"},children:[Object($.jsx)(fe.a,{variant:"h4",align:"center",gutterBottom:!0,children:"Contact Us"}),Object($.jsx)(fe.a,{variant:"body1",align:"center",gutterBottom:!0,children:"For further information about our services please contact us"}),Object($.jsxs)(S.a,{container:!0,justify:"center",className:c.container,spacing:3,children:[Object($.jsx)(S.a,{item:!0,xs:12,sm:6,md:4,className:c.cardContainer,children:Object($.jsxs)("table",{className:c.tableContainer,children:[Object($.jsxs)("tr",{children:[Object($.jsx)("td",{children:Object($.jsx)(ec.a,{color:"primary",className:c.icons})}),Object($.jsx)("td",{className:c.tableCell,children:Object($.jsx)(fe.a,{variant:"body1",gutterBottom:!0,className:c.card,children:"General Inquiries"})})]}),Object($.jsxs)("tr",{children:[Object($.jsx)("td",{}),Object($.jsx)("td",{className:c.tableCell,children:Object($.jsx)("ul",{className:c.listItem,children:Object($.jsx)("li",{children:Object($.jsx)("p",{children:"+44 0203 4329 750"})})})})]})]})}),Object($.jsx)(S.a,{item:!0,xs:12,sm:6,md:4,className:c.cardContainer,children:Object($.jsxs)("table",{children:[Object($.jsxs)("tr",{children:[Object($.jsx)("td",{children:Object($.jsx)(lc.a,{color:"primary",className:c.icons})}),Object($.jsx)("td",{className:c.tableCell,children:Object($.jsx)(fe.a,{variant:"body1",gutterBottom:!0,className:c.card,children:"Sales and Support"})})]}),Object($.jsxs)("tr",{children:[Object($.jsx)("td",{}),Object($.jsx)("td",{className:c.tableCell,children:Object($.jsxs)("ul",{className:c.listItem,children:[Object($.jsxs)("li",{children:[Object($.jsx)("p",{children:"Technical Support"}),Object($.jsx)("p",{children:"[email protected]"})]}),Object($.jsxs)("li",{children:[Object($.jsx)("p",{children:"Sales Team"}),Object($.jsx)("p",{children:"[email protected]"})]})]})})]})]})}),Object($.jsx)(S.a,{item:!0,xs:12,sm:6,md:4,className:c.cardContainer,children:Object($.jsxs)("table",{children:[Object($.jsxs)("tr",{children:[Object($.jsx)("td",{children:Object($.jsx)(jc.a,{color:"primary",className:c.icons})}),Object($.jsx)("td",{className:c.tableCell,children:Object($.jsx)(fe.a,{variant:"body1",gutterBottom:!0,className:c.card,children:"Redbox Headquarters"})})]}),Object($.jsxs)("tr",{children:[Object($.jsx)("td",{}),Object($.jsx)("td",{className:c.tableCell,children:Object($.jsxs)("ul",{className:c.listItem,children:[Object($.jsx)("li",{children:Object($.jsx)("p",{children:"Pure Offices, 26 Bridge Road East, Welwyn Garden City, Hertfordshire AL7 1HL"})}),Object($.jsx)("li",{children:Object($.jsx)("p",{children:"[email protected]"})})]})})]})]})})]})]})})},gc=Object(f.a)((function(e){return{root:{color:"#fff",margin:"10rem 0 0 0"},container:{width:"70%",margin:"3rem auto"},textArea:{margin:"2rem 0 0 0"},submitButton:{color:"#fff",margin:"auto",display:"block"}}})),hc=Object(Ut.a)({root:{"& label.Mui-focused":{color:"#aaa"},"& label":{color:"#aaa",fontSize:"13px"},"& .MuiInput-underline:after":{borderColor:"#ff9800"},"& .MuiInput-underline:before":{borderBottom:"1px solid #fff !important"},"& .MuiInputBase-input":{color:"#fff"}}})(T.a),fc=Object(Ut.a)({root:{"& label.Mui-focused":{color:"#aaa"},"& label":{color:"#aaa",fontSize:"13px"},"& .MuiInput-underline:after":{borderColor:"#ff9800"},"& .MuiInput-underline:before":{borderBottom:"1px solid #fff !important"},"& .MuiInputBase-input":{color:"#fff",padding:"0 0 3rem 0"}}})(T.a),pc=function(){var e=gc(),t=Object(c.useState)({name:"",email:"",query:"",loading:!1,success:!1,error:""}),n=Object(b.a)(t,2),a=n[0],r=n[1],o=a.name,s=a.email,i=a.query,l=(a.error,a.loading,a.success),d=function(e){return function(t){r(Object(y.a)(Object(y.a)({},a),{},Object(x.a)({error:!1},e,t.target.value)))}};return Object($.jsx)($.Fragment,{children:Object($.jsxs)(h.a,{component:"div",className:e.root,children:[!l&&Ob
1ject($.jsxs)($.Fragment,{children:[Object($.jsx)(fe.a,{variant:"h4",align:"center",gutterBottom:!0,children:"Request More Information"}),Object($.jsxs)(S.a,{container:!0,justify:"center",className:e.container,spacing:2,children:[Object($.jsx)(S.a,{item:!0,xs:12,sm:6,children:Object($.jsx)(hc,{id:"outlined-basic",onChange:d("name"),fullWidth:!0,label:"Your Name"})}),Object($.jsx)(S.a,{item:!0,xs:12,sm:6,children:Object($.jsx)(hc,{id:"outlined-basic",onChange:d("email"),fullWidth:!0,label:"Your Email"})}),Object($.jsx)(S.a,{item:!0,xs:12,sm:12,className:e.textArea,children:Object($.jsx)(fc,{id:"outlined-basic",onChange:d("query"),fullWidth:!0,label:"Your queries and suggestions"})}),Object($.jsx)(S.a,{item:!0,xs:12,sm:12,className:e.textArea,children:Object($.jsx)(C.a,{variant:"contained",color:"primary",onClick:function(e){var t;(e.preventDefault(),r(Object(y.a)(Object(y.a)({},a),{},{error:!1,loading:!0})),""!==o&&""!==s&&""!==i)?(t={name:o,email:s,query:i},fetch("".concat(P,"/user/query/mail"),{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(t)}).then((function(e){return e.json()})).catch((function(e){return console.log(e)}))).then((function(e){e.error?r(Object(y.a)(Object(y.a)({},a),{},{error:e.error,loading:!1,success:!1})):r(Object(y.a)(Object(y.a)({},a),{},{name:"",email:"",query:"",error:"",loading:!1,success:!0}))})).catch((function(e){return console.log("Error in send email!")})):r(Object(y.a)(Object(y.a)({},a),{},{error:"Fill the form properly",loading:!1}))},className:e.submitButton,children:"Send Message"})})]})]}),l&&Object($.jsx)("h1",{style:{textAlign:"center"},children:"Thank you for contacting us. We will reply back to you soon!"})]})})},mc=Object(f.a)((function(e){return{root:{paddingBottom:"1rem",marginBottom:"1rem"}}})),Oc=function(){var e=mc();return Object($.jsx)($.Fragment,{children:Object($.jsx)(rc,{title:"",children:Object($.jsxs)(h.a,{component:"div",className:e.root,children:[Object($.jsx)(uc,{addMargin:!1}),Object($.jsx)(pc,{})]})})})},xc=function(e){var t=e.component,n=Object(qt.a)(e,["component"]);return Object($.jsx)(i.b,Object(y.a)(Object(y.a)({},n),{},{render:function(e){return H()?Object($.jsx)(t,Object(y.a)({},e)):Object($.jsx)(i.a,{to:{pathname:"/signin",state:{from:e.location}}})}}))},vc=Object(f.a)((function(e){return{root:{color:"#fff"}}})),yc=function(){var e=vc();return Object($.jsx)($.Fragment,{children:Object($.jsxs)(h.a,{component:"div",className:e.root,children:[Object($.jsx)(fe.a,{variant:"h4",align:"center",gutterBottom:!0,children:"Features and Specifications"}),Object($.jsx)(S.a,{container:!0,justify:"center",children:Object($.jsx)(S.a,{item:!0,xs:10,sm:7,children:Object($.jsxs)(fe.a,{variant:"body1",align:"center",gutterBottom:!0,children:[Object($.jsx)("b",{children:"REDBOX"})," gives you realtime news covers all the main asset classes, including equities,fixed income, FX and commodities. Redbox provides you API which can be integrated to your trading platforms. Our algorithms monitors all major newswires,televisions channels,news website,blogs and social media platforms for headlines with market moving potenial."]})})})]})})},wc=Object(f.a)((function(e){return{root:{background:"#000",padding:"6rem 0",borderRadius:"10px",position:"relative",top:"-100px"},copyrightText:{color:"#fff",margin:"0 0 1.5rem 0"},footerContainer:{background:"#333",border:"1px solid #333"}}})),Sc=function(){var e=wc();return Object($.jsxs)("div",{className:e.footerContainer,children:[Object($.jsx)(S.a,{container:!0,justify:"center",children:Object($.jsxs)(S.a,{item:!0,xs:11,className:e.root,children:[Object($.jsx)(yc,{}),Object($.jsx)(Wn,{}),Object($.jsx)(uc,{}),Object($.jsx)(pc,{})]})}),Object($.jsx)(fe.a,{className:e.copyrightText,variant:"body2",gutterBottom:!0,align:"center",children:"\xa9Redboxglobal, All rights reserved to www.redboxglobal.com"})]})},Cc=n.p+"static/media/bg1.a5ad6c14.png",Nc=Object(f.a)((function(e){return{root:{height:"95vh",marginTop:"3.4rem",background:"linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)), url(".concat(Cc,")"),backgroundRepeat:"no-repeat",backgroundSize:"cover",transformBox:"translate3d(0px, 0px, 0px)",display:"flex",alignItems:"center",position:"relative"},heroTitle:{color:"#fff",fontWeight:"bold",textTransform:"uppercase"},heroDesc:{color:"#fff"},heroButton:{margin:e.spacing(1,0),width:"246px"},link:{textDecoration:"none",color:"#fff"}}})),kc=function(){var e=Nc();return Object($.jsx)($.Fragment,{children:Object($.jsx)(h.a,{component:"div",className:e.root,children:Object($.jsxs)(Mn.a,{maxWidth:"lg",children:[Object($.jsx)(fe.a,{variant:"h2",gutterBottom:!0,className:e.heroTitle,children:"Redbox"}),Object($.jsxs)(fe.a,{variant:"body1",gutterBottom:!0,className:e.heroDesc,children:["Redbox is an accredited financial and economics news service, ",Object($.jsx)("br",{}),"specialising in up-to-the-second broadcast reports and headlines."]}),Object($.jsx)(C.a,{variant:"contained",size:"large",color:"secondary",className:e.heroButton,children:Object($.jsx)(s.b,{className:e.link,to:"/signup",children:"Sign-up for 7 day trial"})})]})})})},Tc=function(){return Object($.jsxs)($.Fragment,{children:[Object($.jsx)(cc,{}
1),Object($.jsx)(kc,{}),function(){if(H())return"IN"===H().user.userType[0]?Object($.jsx)(i.a,{to:"/india/message"}):Object($.jsx)(i.a,{to:"/global/message"})}(),Object($.jsx)(Sc,{})]})},Fc=n(950),Rc=n(951),Dc=n(935),Ic=n(952),Ac=n(953),Ec=n(954),Bc=n(202),zc=n.n(Bc),Lc=Object(f.a)((function(e){return{root:{backgroundColor:"#333",minWidth:275,color:"#fff",textAlign:"center",border:"1px solid #555",margin:e.spacing(2,0)},title:{textTransform:"uppercase"}}})),Mc=function(e){var t=e.title,n=void 0===t?"":t,c=e.price,a=void 0===c?"":c,r=e.time,o=void 0===r?"":r,s=e.listItems,i=void 0===s?[]:s,l=Lc();return Object($.jsx)(Fc.a,{className:l.root,children:Object($.jsxs)(Rc.a,{children:[Object($.jsx)(fe.a,{variant:"h4",color:"primary",align:"center",className:l.title,gutterBottom:!0,children:n}),Object($.jsxs)(fe.a,{variant:"h6",component:"p",children:["$ ",a]}),Object($.jsx)(fe.a,{variant:"body1",component:"p",children:o}),Object($.jsx)(Dc.a,{component:"nav",children:i.map((function(e,t){return Object($.jsxs)(Ic.a,{button:!0,children:[Object($.jsx)(Ac.a,{children:Object($.jsx)(zc.a,{color:"secondary"})}),Object($.jsx)(Ec.a,{primary:e})]},t)}))})]})})},Yc=n.p+"static/media/paypal.84f29ebd.svg",_c=n.p+"static/media/stripe.d25244aa.svg",Pc=Object(f.a)((function(e){return{root:{color:"#fff",margin:e.spacing(2,0)},container:{width:"90%",margin:"auto"},paymentLogo:{width:"275px",height:"138px",display:"block",margin:"auto"},contactText:{padding:"2rem 0"},icons:{marginTop:e.spacing(4),marginBottom:e.spacing(4),margin:"auto",display:"block",fontSize:"4rem"},cardContainer:{"@media (max-width: 500px)":{display:"flex",justifyContent:"center"}}}})),Uc=function(){var e=Pc(),t=["Real-Time News","Crawler Data","Twitter Feed","Save News","Sniper","Audio News","Advance Search"];return Object($.jsx)($.Fragment,{children:Object($.jsx)(rc,{title:"Pricing",children:Object($.jsxs)(h.a,{component:"div",className:e.root,children:[Object($.jsxs)(S.a,{container:!0,justify:"center",className:e.container,spacing:3,children:[Object($.jsx)(S.a,{item:!0,xs:10,sm:6,md:4,className:e.cardContainer,children:Object($.jsx)(Mc,{title:"Basic",price:"39",time:"Monthly",listItems:t})}),Object($.jsx)(S.a,{item:!0,xs:10,sm:6,md:4,className:e.cardContainer,children:Object($.jsx)(Mc,{title:"Plus",price:"110",time:"3 Months",listItems:t})}),Object($.jsx)(S.a,{item:!0,xs:10,sm:6,md:4,className:e.cardContainer,children:Object($.jsx)(Mc,{title:"Professional",price:"399",time:"12 Months",listItems:t})})]}),Object($.jsxs)(S.a,{container:!0,justify:"center",className:e.container,spacing:3,children:[Object($.jsx)(S.a,{item:!0,xs:10,sm:6,className:e.cardContainer,children:Object($.jsx)("img",{src:Yc,alt:"Paypal Logo",className:e.paymentLogo})}),Object($.jsx)(S.a,{item:!0,xs:10,sm:6,className:e.cardContainer,children:Object($.jsx)("img",{src:_c,alt:"Stripe Logo",className:e.paymentLogo})})]}),Object($.jsx)(fe.a,{align:"center",variant:"body2",className:e.contactText,children:"Contact us at [email protected]"})]})})})},Gc=Object(f.a)((function(e){return{root:{backgroundColor:"transparent",maxWidth:350,color:"#fff",textAlign:"justify",margin:"2rem auto",display:"flex",alignItems:"flex-start"},title:{textTransform:"uppercase"},icon:{color:e.palette.secondary.main,fontSize:"2rem"},cardContent:{margin:e.spacing(0,2)}}})),Wc=function(e){var t=e.title,n=e.description,c=e.icon,a=Gc();return Object($.jsx)($.Fragment,{children:Object($.jsxs)(Fc.a,{className:a.root,children:[Object($.jsx)("div",{className:a.iconContainer,children:c}),Object($.jsxs)("div",{className:a.cardContent,children:[Object($.jsx)(fe.a,{variant:"h6",className:a.title,gutterBottom:!0,children:t}),Object($.jsx)(fe.a,{variant:"body2",component:"p",children:n})]})]})})},Hc=n(203),Xc=n.n(Hc),qc=n(204),Jc=n.n(qc),Kc=n(205),Vc=n.n(Kc),Qc=function(e){var t=e.title,n=void 0===t?"Signup":t,c=e.children,a=[{title:"REDBOX CHAT",description:"Redbox has an encrypted chat facility enabling you to stay on one page, receiving any important news whilst chatting with your friends or brokers. Discussing what the news means for your trading decisions.",icon:function(){return Object($.jsx)(Xc.a,{style:{fontSize:"2rem",color:"#ff9800"}})}},{title:"REDBOX ANALYSTS",description:"Our Redbox Analysts have over 100 years of combined experience in the financial markets. Our analysts live and breathe the markets, seeking the best opportunity for profits.",icon:function(){return Object($.jsx)(Jc.a,{style:{fontSize:"2rem",color:"rgb(76, 175, 80)"}})}},{title:"REDBOX API",description:"Redbox can provide you an API which can be integrated to your trading platforms and mobile applications, giving you more flexibility on how to receive your news.",icon:function(){return Object($.jsx)(Vc.a,{style:{fontSize:"2rem",color:"#f44336"}})}}];return Object($.jsx)($.Fragment,{children:Object($.jsx)(rc,{title:n,children:Object($.jsxs)(S.a,{container:!0,justify:"center",spacing:3,children:[Object($.jsx)(S.a,{item:!0,xs:10,sm:6,children:a.map((function(e,t){return Object($.jsx)(Wc,{title:e.title,de
1scription:e.description,icon:e.icon()},t)}))}),Object($.jsx)(S.a,{item:!0,xs:10,sm:6,children:c})]})})})},$c=n(66),Zc=n.n($c),ea=n(97),ta=n.n(ea),na=function(){return{top:"".concat(50,"%"),left:"".concat(50,"%"),transform:"translate(-".concat(50,"%, -").concat(50,"%)")}},ca=Object(f.a)((function(e){return{root:{paddingBottom:"1rem"},radio:{},checkboxLabel:{fontSize:"14px"},radioCon:{display:"inline-block"},loaderStyle:{color:"#fff"},paper:Object(x.a)({position:"absolute",width:"50%",height:"450px",overflowY:"scroll",backgroundColor:e.palette.background.paper,boxShadow:e.shadows[5],padding:e.spacing(2,4,3)},e.breakpoints.down("xs"),{width:"80%"})}})),aa=Object(Ut.a)({root:{"& label.Mui-focused":{color:"#aaa"},"& label":{color:"#aaa",fontSize:"13px"},"& .MuiInput-underline:after":{borderColor:"#ff9800"},"& .MuiInput-underline:before":{borderBottom:"1px solid #fff !important"},"& .MuiInputBase-input":{color:"#fff",fontSize:"14px"}}})(T.a),ra=Object(f.a)((function(e){return{root:{},loaderStyle:{color:"#fff"}}})),oa=function(){var e=ra(),t=Object(c.useState)({email:"",password:"",error:"",loading:!1,didRedirect:!1}),n=Object(b.a)(t,2),a=n[0],r=n[1],o=a.email,l=a.password,u=a.error,h=a.loading,f=a.didRedirect,p=function(e){return function(t){r(Object(y.a)(Object(y.a)({},a),{},Object(x.a)({error:!1},e,t.target.value)))}},m=function(){var e=Object(j.a)(d.a.mark((function e(t){var n,c,s;return d.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t.preventDefault(),r(Object(y.a)(Object(y.a)({},a),{},{error:!1,loading:!0})),o&&l){e.next=5;break}return r(Object(y.a)(Object(y.a)({},a),{},{error:"There are incomplete fields in your submission!",loading:!1})),e.abrupt("return");case 5:return c="NA",e.prev=6,e.next=9,g.a.get("https://api.ipify.org/?format=json");case 9:s=e.sent,e.next=14;break;case 12:e.prev=12,e.t0=e.catch(6);case 14:c=200===(null===(n=s)||void 0===n?void 0:n.status)?s.data.ip:"NA",(i={email:o,password:l,ip:c},fetch("".concat(P,"/signin"),{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(i)}).then((function(e){return e.json()})).catch((function(e){return console.log(e)}))).then((function(e){(null===e||void 0===e?void 0:e.error)?r(Object(y.a)(Object(y.a)({},a),{},{error:e.error,loading:!1})):G(e,(function(){r(Object(y.a)(Object(y.a)({},a),{},{loading:!1,didRedirect:!0}))}))})).catch(console.log("signin request failed"));case 16:case"end":return e.stop()}var i}),e,null,[[6,12]])})));return function(t){return e.apply(this,arguments)}}();return Object($.jsxs)(Qc,{title:"Login",children:[u&&Object($.jsx)(Ie,{message:u}),Object($.jsx)("div",{className:e.root,children:Object($.jsxs)(S.a,{container:!0,spacing:2,children:[Object($.jsx)(S.a,{item:!0,xs:12,children:Object($.jsxs)(S.a,{container:!0,spacing:1,alignItems:"flex-end",children:[Object($.jsx)(S.a,{xs:2,md:1,item:!0,children:Object($.jsx)(Zc.a,{})}),Object($.jsx)(S.a,{xs:10,item:!0,children:Object($.jsx)(aa,{onChange:p("email"),value:o,label:"Email",fullWidth:!0})})]})}),Object($.jsx)(S.a,{item:!0,xs:12,children:Object($.jsxs)(S.a,{container:!0,spacing:1,alignItems:"flex-end",children:[Object($.jsx)(S.a,{xs:2,md:1,item:!0,children:Object($.jsx)(ta.a,{})}),Object($.jsx)(S.a,{xs:10,item:!0,children:Object($.jsx)(aa,{onChange:p("password"),value:l,label:"Password",type:"password",fullWidth:!0})})]})}),Object($.jsx)(S.a,{item:!0,xs:12,style:{margin:"1rem 0"},children:Object($.jsxs)(S.a,{container:!0,spacing:2,alignItems:"flex-end",children:[Object($.jsx)(S.a,{xs:12,md:6,item:!0,children:Object($.jsx)(C.a,{startIcon:h&&Object($.jsx)(F.a,{size:"1rem",className:e.loaderStyle}),style:{color:"#fff",margin:"auto"},variant:"contained",color:"primary",onClick:m,fullWidth:!0,children:"Login"})}),Object($.jsx)(S.a,{xs:12,md:6,item:!0,children:Object($.jsx)(s.b,{to:"forgot-password",style:{color:"#fff",textDecoration:"none"},children:Object($.jsx)(C.a,{style:{color:"#fff",margin:"auto"},variant:"contained",color:"secondary",fullWidth:!0,children:"Forgot Password"})})})]})})]})}),f&&H()||H()?Object($.jsx)(i.a,{to:"/global/message"}):Object($.jsx)(i.a,{to:"/signin"})]})},sa=n(955),ia=n(962),la=n(140),da=n.n(la),ja=n(206),ba=n.n(ja),ua=n(141),ga=n.n(ua),ha=n(142),fa=n.n(ha),pa=Object(f.a)((function(e){return{heading:{textAlign:"center",fontWeight:"bold",fontSize:"20px",fontFamily:"Times New Roman"},paragraph:{fontSize:"14px",margin:e.spacing(2,0)}}})),ma=function(){var e=pa();return Object($.jsxs)($.Fragment,{children:[Object($.jsx)(fe.a,{className:e.heading,children:"Terms & Conditions"}),Object($.jsx)(fe.a,{className:e.paragraph,children:"Welcome to our website. If you continue to browse and use this website, you are agreeing to comply with and be bound by the following terms and conditions of use, which together with our privacy policy govern GNS\u2019s relationship with you in relation to this website. If you disagree with any part of these terms and conditions, please do not use our website."}),Object($.jsx)(fe.a,{className:e.heading,children:"Suitability Of Service"}),Object($.jsx)(fe.a,{className:e.paragraph,children:"You acknowledge that this website does not aim to provide advice tailored to individual investors and that you can lose money on investments. This website should never be used in isolation of your individual circumstances. You must consider your financial circumstances, risk tolerance, liquidity needs and investment objectives. This website does not replace the advice of an authorised investment professional or independent financial adviser."}),Object($.jsx)(fe.a,{className:e.paragraph,children:"The content on this website is not appropriate for the purposes of making a decision to carry out a transaction or trade. You should check all information and prices immediately prior to carrying out any trade."}),Object($.jsx)(fe.a,{className:e.heading,children:"No Content On This Website Is:"}),Object($.jsx)(fe.a,{className:e.paragraph,children:"providing investment, tax or legal advice and no content on this website amounts to investment advice under Financial Services laws"}),Object($.jsx)(fe.a,{className:e.paragraph,children:"recommending any financial instrument, investment or product, including those discussed on this website"})]})},Oa=n(85),xa=n.n(Oa),va=function(){return{top:"".concat(50,"%"),left:"".concat(50,"%"),transform:"translate(-".concat(50,"%, -").concat(50,"%)")}},ya=Object(f.a)((function(e){return{paper:{position:"absolute",width:500,backgroundColor:e.palette.background.paper,boxShadow:e.shadows[5],padding:e.spacing(2,4,3),borderRadius:"4px"},modalTitle:{textAlign:"center"}
1,modalDescription:{textAlign:"center"},modalButton:{display:"block",margin:"0 auto"},modalIcon:{display:"block",margin:"0 auto",fontSize:"3rem",color:"#4caf50"}}})),wa=function(e){var t=e.isOpen,n=ya(),a=Object(c.useState)(va),r=Object(b.a)(a,1)[0],o=Object(c.useState)(t),s=Object(b.a)(o,2),l=s[0],d=s[1],j=Object(i.g)(),u=Object($.jsxs)("div",{style:r,className:n.paper,children:[Object($.jsx)(xa.a,{className:n.modalIcon}),Object($.jsx)("h2",{className:n.modalTitle,children:"Thank you for signing up. Our representative will contact you soon. Please be patient."}),Object($.jsx)("p",{className:n.modalDescription,children:"For trial queries, please contact [email protected]."}),Object($.jsx)(C.a,{variant:"outlined",color:"secondary",className:n.modalButton,onClick:function(){j.push("/signin")},children:"OK"})]});return Object($.jsx)(O.a,{open:l,onClose:function(){d(!1)},children:u})},Sa=function(){var e=ca(),t=Object(c.useState)({name:"",lastname:"",email:"",phone:"",password:"",confirmPassword:"",userType:"",occupation:"",tradingIn:[],termAnCondi:"",category:"",error:"",loading:!1,success:!1}),n=Object(b.a)(t,2),a=n[0],r=n[1],o=Object(c.useState)(na),s=Object(b.a)(o,1)[0],l=Object(c.useState)(!1),u=Object(b.a)(l,2),h=u[0],f=u[1],p=a.name,m=a.lastname,w=a.email,N=a.phone,k=a.password,T=a.confirmPassword,R=(a.userType,a.occupation),D=a.tradingIn,I=a.termAnCondi,A=a.error,E=a.loading,B=a.success,z=function(e){return function(t){var n=t.target.value;"tradingIn"===e?t.target.checked?(D.push(n),r(Object(y.a)(Object(y.a)({},a),{},Object(x.a)({error:!1},e,D)))):(D.splice(D.indexOf(n),1),r(Object(y.a)(Object(y.a)({},a),{},Object(x.a)({error:!1},e,Object(v.a)(D))))):"termAnCondi"===e?t.target.checked?r(Object(y.a)(Object(y.a)({},a),{},Object(x.a)({error:!1},e,!0))):r(Object(y.a)(Object(y.a)({},a),{},Object(x.a)({error:!1},e,!1))):r(Object(y.a)(Object(y.a)({},a),{},Object(x.a)({error:!1},e,n)))}},L=function(){f(!0)},M=function(){f(!1)},Y=Object($.jsx)("div",{style:s,className:e.paper,children:Object($.jsx)(ma,{})}),_=function(){var e=Object(j.a)(d.a.mark((function e(t){var n,c,o;return d.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t.preventDefault(),r(Object(y.a)(Object(y.a)({},a),{},{error:!1,loading:!0})),c="NA",e.prev=3,e.next=6,g.a.get("https://api.ipify.org/?format=json");case 6:o=e.sent,e.next=11;break;case 9:e.prev=9,e.t0=e.catch(3);case 11:if(c=200===(null===(n=o)||void 0===n?void 0:n.status)?o.data.ip:"NA",k===T){e.next=17;break}return r(Object(y.a)(Object(y.a)({},a),{},{error:"Password and Confirm password don't match!",loading:!1})),e.abrupt("return");case 17:if(I){e.next=22;break}return r(Object(y.a)(Object(y.a)({},a),{},{error:"Please accept terms and conditions!",loading:!1})),e.abrupt("return");case 22:if(p&&m&&w&&N&&k&&R&&D){e.next=27;break}return r(Object(y.a)(Object(y.a)({},a),{},{error:"There are incomplete fields in your submission!",loading:!1})),e.abrupt("return");case 27:(s={name:p,lastname:m,email:w,phone:N,password:k,occupation:R,tradingIn:D,ip:c},fetch("".concat(P,"/signup"),{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(s)}).then((function(e){return e.json()})).catch((function(e){return console.log(e)}))).then((function(e){e.error?r(Object(y.a)(Object(y.a)({},a),{},{error:e.error,success:!1,loading:!1})):r(Object(y.a)(Object(y.a)({},a),{},{name:"",lastname:"",email:"",phone:"",password:"",confirmPassword:"",userType:"",occupation:"",tradingIn:[],termAnCondi:"",category:"",error:"",success:!0,loading:!1}))})).catch(console.log("Error in signup"));case 28:case"end":return e.stop()}var s}),e,null,[[3,9]])})));return function(t){return e.apply(this,arguments)}}();return Object($.jsx)($.Fragment,{children:Object($.jsxs)(Qc,{title:"Register",children:[A&&Object($.jsx)(Ie,{message:A}),B&&Object($.jsx)(wa,{isOpen:B}),function(){if(H())return"IN"===H().user.userType[0]?Object($.jsx)(i.a,{to:"/india/message"}):Object($.jsx)(i.a,{to:"/global/message"})}(),Object($.jsx)("div",{className:e.root,children:Object($.jsxs)(S.a,{container:!0,spacing:2,justify:"center",children:[Object($.jsx)(S.a,{item:!0,xs:10,sm:6,children:Object($.jsxs)(S.a,{container:!0,spacing:1,alignItems:"flex-end",children:[Object($.jsx)(S.a,{item:!0,children:Object($.jsx)(da.a,{})}),Object($.jsx)(S.a,{item:!0,children:Object($.jsx)(aa,{onChange:z("name"),value:p,label:"First Name",fullWidth:!0})})]})}),Object($.jsx)(S.a,{item:!0,xs:10,sm:6,children:Object($.jsxs)(S.a,{container:!0,spacing:1,alignItems:"flex-end",children:[Object($.jsx)(S.a,{item:!0,children:Object($.jsx)(da.a,{})}),Object($.jsx)(S.a,{item:!0,children:Object($.jsx)(aa,{onChange:z("lastname"),value:m,label:"Last Name",fullWidth:!0})})]})}),Object($.jsx)(S.a,{item:!0,xs:10,sm:6,children:Object($.jsxs)(S.a,{container:!0,spacing:1,alignItems:"flex-end",children:[Object($.jsx)(S.a,{item:!0,children:Object($.jsx)(ba.a,{})}),Object($.jsx)(S.a,{item:!0,children:Object($.jsx)(aa,{onChange:z("phone"),value:N,label:"Phone",fullWidth:!0})})]})}),Object($.jsx)(S.a,{item:!0,xs:10,sm:6,children:Object($.jsxs)(S.a,{container:!0,spacing:1,alignItems:"flex-end",children:[Object($.jsx)(S.a,{item:!0,children:Object($.jsx)(Zc.a,{})}),Object($.jsx)(S.a,{item:!0,children:Object($.jsx)(aa,{onChange:z("email"),value:w,label:"Email",fullWidth:!0})})]})}),Object($.jsx)(S.a,{item:!0,xs:10,sm:6,children:Object($.jsxs)(S.a,{container:!0,spacing:1,alignItems:"flex-end",children:[Object($.jsx)(S.a,{item:!0,children:Object($.jsx)(ta.a,{})}),Object($.jsx)(S.a,{item:!0,children:Object($.jsx)(aa,{onChange:z("password"),value:k,label:"Password",type:"password",fullWidth:!0})})]})}),Object($.jsx)(S.a,{item:!0,xs:10,sm:6,children:Object($.jsxs)(S.a,{container:!0,spacing:1,alignItems:"flex-end",children:[Object($.jsx)(S.a,{item:!0,children:Object($.jsx)(ta.a,{color:"secondary"})}),Object($.jsx)(S.a,{item:!0,children:Object($.jsx)(aa,{onChange:z("confirmPassword"),value:T,label:"Confirm Password",type:"password",fullWidth:!0})})]})}),Object($.jsxs)(S.a,{item:!0,xs:12,children:[Object($.jsx)(fe.a,{variant:"body1",style:{color:"#fff"},gutterBottom:!0,children:"Occupation"}),Object($.jsx)(sa.a,{row:!0,"aria-label":"gender",name:"catrgroy",value:R,children:["Trader","Broker","Other"].map((function(t,n){return Object($.jsx)(At.a,{value:t,className:e.radioCon,onChange:z("occupation"),control:Object($.jsx)(ia.a,{className:e.radio,size:"small"}),label:t},t)}))})]}),Object($.jsxs)(S.a,{item:!0,xs:12,children:[Object($.jsx)(fe.a,{variant:"body1",style:{color:"#fff"},gutterBottom:!0,children:"Trading in"}),Object($.jsx)(It.a,{row:!0,name:"catrgroy",children:["Equities","Fixed Income","Money Markets","Commodities"].map((function(e,t){return Object($.jsx)(At.a,{control:Object($.jsx)(Et.a,{value:e,onCh
1ange:z("tradingIn"),icon:Object($.jsx)(ga.a,{fontSize:"small"}),checkedIcon:Object($.jsx)(fa.a,{fontSize:"small"}),name:"checkedI"}),label:e},e)}))})]}),Object($.jsxs)(S.a,{item:!0,xs:12,children:[Object($.jsx)(At.a,{control:Object($.jsx)(Et.a,{value:"checkedI",onChange:z("termAnCondi"),icon:Object($.jsx)(ga.a,{fontSize:"small"}),checkedIcon:Object($.jsx)(fa.a,{fontSize:"small"}),name:"checkedI"}),label:"I agree to the"}),Object($.jsxs)($.Fragment,{children:[Object($.jsx)(fe.a,{color:"primary",component:"span",onClick:L,children:"terms and conditions."}),Object($.jsx)(O.a,{open:h,onClose:M,"aria-labelledby":"simple-modal-title","aria-describedby":"simple-modal-description",children:Y})]})]}),Object($.jsx)(S.a,{item:!0,xs:12,children:Object($.jsx)(C.a,{startIcon:E&&Object($.jsx)(F.a,{size:"1rem",className:e.loaderStyle}),style:{color:"#fff"},variant:"contained",color:"primary",onClick:_,fullWidth:!0,children:"Sign Up"})})]})})]})})},Ca=function(){return{top:"".concat(50,"%"),left:"".concat(50,"%"),transform:"translate(-".concat(50,"%, -").concat(50,"%)")}},Na=Object(f.a)((function(e){return{paper:{position:"absolute",width:500,backgroundColor:e.palette.background.paper,boxShadow:e.shadows[5],padding:e.spacing(2,4,3),borderRadius:"4px"},modalTitle:{textAlign:"center"},modalDescription:{textAlign:"center"},modalButton:{display:"block",margin:"0 auto"},modalIcon:{display:"block",margin:"0 auto",fontSize:"3rem",color:"#4caf50"}}})),ka=function(e){var t=e.isOpen,n=Na(),a=Object(c.useState)(Ca),r=Object(b.a)(a,1)[0],o=Object(c.useState)(t),s=Object(b.a)(o,2),l=s[0],d=s[1],j=Object(i.g)(),u=Object($.jsxs)("div",{style:r,className:n.paper,children:[Object($.jsx)(xa.a,{className:n.modalIcon}),Object($.jsx)("h2",{className:n.modalTitle,children:"A password reset link was sent to your email account."}),Object($.jsx)("p",{className:n.modalDescription,children:"Click the link in the email to create a new password. Link will expire in 15 minutes. If you did not receive it please check your spam folder."}),Object($.jsx)(C.a,{variant:"outlined",color:"secondary",className:n.modalButton,onClick:function(){j.push("/signin")},children:"OK"})]});return Object($.jsx)(O.a,{open:l,onClose:function(){d(!1)},children:u})},Ta=Object(f.a)((function(e){return{root:{},loaderStyle:{color:"#fff"}}})),Fa=function(){var e=Ta(),t=Object(c.useState)({email:"",error:"",loading:!1,success:!1}),n=Object(b.a)(t,2),a=n[0],r=n[1],o=a.email,s=a.error,i=a.loading,l=a.success,d=function(e){e.preventDefault(),""!==o&&" "!==o?(r(Object(y.a)(Object(y.a)({},a),{},{error:!1,loading:!0})),function(e){return fetch("".concat(P,"/send/forgotpasswordmail"),{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(e)}).then((function(e){return e.json()})).catch((function(e){return console.log(e)}))}({email:o}).then((function(e){e.error?r(Object(y.a)(Object(y.a)({},a),{},{error:e.error,loading:!1,success:!1})):r(Object(y.a)(Object(y.a)({},a),{},{loading:!1,success:!0}))})).catch(console.log("send request failed"))):r(Object(y.a)(Object(y.a)({},a),{},{error:"Please enter a valid email address.",loading:!1}))};return Object($.jsxs)(Qc,{title:"Forgot Password",children:[s&&Object($.jsx)(Ie,{message:s}),l&&Object($.jsx)(ka,{isOpen:l}),function(){return Object($.jsx)("div",{className:e.root,children:Object($.jsxs)(S.a,{container:!0,spacing:2,children:[Object($.jsx)(S.a,{item:!0,xs:12,children:Object($.jsxs)(S.a,{container:!0,spacing:1,alignItems:"flex-end",children:[Object($.jsx)(S.a,{xs:2,md:1,item:!0,children:Object($.jsx)(Zc.a,{})}),Object($.jsx)(S.a,{xs:10,item:!0,children:Object($.jsx)(aa,{onChange:(t="email",function(e){r(Object(y.a)(Object(y.a)({},a),{},Object(x.a)({error:!1},t,e.target.value)))}),value:o,label:"Enter your account email...",fullWidth:!0})})]})}),Object($.jsx)(S.a,{item:!0,xs:12,style:{margin:"1rem 0"},children:Object($.jsx)(S.a,{container:!0,spacing:2,alignItems:"flex-end",children:Object($.jsx)(S.a,{xs:12,md:12,item:!0,children:Object($.jsx)(C.a,{startIcon:i&&Object($.jsx)(F.a,{size:"1rem",className:e.loaderStyle}),style:{color:"#fff",display:"block",margin:"auto"},variant:"contained",color:"primary",onClick:d,children:"Send Email"})})})})]})});var t}()]})},Ra=function(){return{top:"".concat(50,"%"),left:"".concat(50,"%"),transform:"translate(-".concat(50,"%, -").concat(50,"%)")}},Da=Object(f.a)((function(e){return{paper:{position:"absolute",width:500,backgroundColor:e.palette.background.paper,boxShadow:e.shadows[5],padding:e.spacing(2,4,3),borderRadius:"4px"},modalTitle:{textAlign:"center"}
1,modalDescription:{textAlign:"center"},modalButton:{display:"block",margin:"0 auto"},modalIcon:{display:"block",margin:"0 auto",fontSize:"3rem",color:"#4caf50"}}})),Ia=function(e){var t=e.isOpen,n=Da(),a=Object(c.useState)(Ra),r=Object(b.a)(a,1)[0],o=Object(c.useState)(t),s=Object(b.a)(o,2),l=s[0],d=s[1],j=Object(i.g)(),u=Object($.jsxs)("div",{style:r,className:n.paper,children:[Object($.jsx)(xa.a,{className:n.modalIcon}),Object($.jsx)("h2",{className:n.modalTitle,children:"Password reset successful."}),Object($.jsx)("p",{className:n.modalDescription,children:"Awesome. you've successfully updated your password."}),Object($.jsx)(C.a,{variant:"outlined",color:"secondary",className:n.modalButton,onClick:function(){j.push("/signin")},children:"OK"})]});return Object($.jsx)(O.a,{open:l,onClose:function(){d(!1)},children:u})},Aa=Object(f.a)((function(e){return{root:{},loaderStyle:{color:"#fff"}}})),Ea=function(e){var t=e.match,n=Aa(),a=Object(c.useState)({password:"",error:"",loading:!1,success:!1}),r=Object(b.a)(a,2),o=r[0],s=r[1],i=o.password,l=o.error,d=o.loading,j=o.success,u=t.params,g=u.userId,h=u.token,f=function(e){var t;(e.preventDefault(),""!==i&&" "!==i)?(s(Object(y.a)(Object(y.a)({},o),{},{error:!1,loading:!0})),(t={userId:g,token:h,password:i},console.log(t),fetch("".concat(P,"/reset/password"),{method:"PUT",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(t)}).then((function(e){return e.json()})).catch((function(e){return console.log(e)}))).then((function(e){e.error?s(Object(y.a)(Object(y.a)({},o),{},{error:e.error,loading:!1,success:!1})):s(Object(y.a)(Object(y.a)({},o),{},{loading:!1,success:!0}))})).catch(console.log("send request failed"))):s(Object(y.a)(Object(y.a)({},o),{},{error:"Fill the form properly",loading:!1}))};return Object($.jsxs)(Qc,{title:"Reset Password",children:[l&&Object($.jsx)(Ie,{message:l}),function(){return Object($.jsx)("div",{className:n.root,children:Object($.jsxs)(S.a,{container:!0,spacing:2,children:[Object($.jsx)(S.a,{item:!0,xs:12,children:Object($.jsxs)(S.a,{container:!0,spacing:1,alignItems:"flex-end",children:[Object($.jsx)(S.a,{xs:2,md:1,item:!0,children:Object($.jsx)(Zc.a,{})}),Object($.jsx)(S.a,{xs:10,item:!0,children:Object($.jsx)(aa,{onChange:(e="password",function(t){s(Object(y.a)(Object(y.a)({},o),{},Object(x.a)({error:!1},e,t.target.value)))}),value:i,label:"Enter your password...",fullWidth:!0})})]})}),Object($.jsx)(S.a,{item:!0,xs:12,style:{margin:"1rem 0"},children:Object($.jsx)(S.a,{container:!0,spacing:2,alignItems:"flex-end",children:Object($.jsx)(S.a,{xs:12,md:12,item:!0,children:Object($.jsx)(C.a,{startIcon:d&&Object($.jsx)(F.a,{size:"1rem",className:n.loaderStyle}),style:{color:"#fff",display:"block",margin:"auto"},variant:"contained",color:"primary",onClick:f,children:"Save"})})})})]})});var e}(),j&&Object($.jsx)(Ia,{isOpen:j})]})},Ba=function(){return Object($.jsx)(s.a,{children:Object($.jsx)(i.d,{children:Object($.jsxs)(be,{children:[Object($.jsx)(i.b,{path:"/",exact:!0,component:Tc}),Object($.jsx)(i.b,{path:"/aboutus",component:sc}),Object($.jsx)(i.b,{path:"/pricing",component:Uc}),Object($.jsx)(i.b,{path:"/contact",component:Oc}),Object($.jsx)(i.b,{path:"/signup",component:Sa}),Object($.jsx)(i.b,{path:"/signin",component:oa}),Object($.jsx)(i.b,{path:"/forgot-password",component:Fa}),Object($.jsx)(i.b,{path:"/reset/password/:userId/:token",component:Ea}),Object($.jsx)(xc,{path:"/global/message",component:Ln})]})})})},za=n(208),La=n(956),Ma=n(957),Ya=n(207),_a=n.n(Ya),Pa=Object(za.a)({palette:{primary:{main:et.a[500]},secondary:{main:_a.a[500]}},overrides:{MuiRadio:{root:{color:"#fff"},colorSecondary:{"&$checked":{color:"#ff9800"}}},MuiCheckbox:{root:{color:"#fff"},colorSecondary:{"&$checked":{color:"#ff9800"}},colorPrimary:{color:"#000","&$checked":{color:"#ff9800"}}}}});o.a.render(Object($.jsxs)(La.a,{theme:Pa,children:[Object($.jsx)(Ma.a,{}),Object($.jsx)(Ba,{})]}),document.getElementById("root"))}},[[299,1,2]]]);

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.