let g_wiggle_animation_running=![];function applyWiggleAnimationToPreview(K,n){const M={'RZJLW':'#checkbox-'+'captions-g'+'raphics-wi'+'ggle','GWHyb':':checked','FMurL':function(w,R){return w!==R;},'leaHV':'Wiggle\x20can'+'vas\x20dimens'+'ions\x20chang'+'ed\x20from','HudFQ':function(w,R){return w>R;},'hOxon':'Wiggle\x20buf'+'fer\x20canvas'+'\x20not\x20ready'+',\x20skipping'+'\x20frame','EHRhQ':function(w,R){return w(R);}};if(!$(M['RZJLW'])['is'](M['GWHyb'])){g_wiggle_animation_running=![];return;}const {dx:Y,dy:g}=g_captions_styled['wiggleOffs'+'et'](n/(-0xa2*0xc+-0x23e+0xdbe)),h=document['getElement'+'ById']('captions-c'+'anvas-wigg'+'le-contain'+'er-canvas');(h['width']!==window['g_wiggle_o'+'riginal_wi'+'dth']||M['FMurL'](h['height'],window['g_wiggle_o'+'riginal_he'+'ight']))&&(console['log'](M['leaHV'],h['width'],'x',h['height'],'to',window['g_wiggle_o'+'riginal_wi'+'dth'],'x',window['g_wiggle_o'+'riginal_he'+'ight']),h['width']=window['g_wiggle_o'+'riginal_wi'+'dth'],h['height']=window['g_wiggle_o'+'riginal_he'+'ight']);const P=h['getContext']('2d');P['clearRect'](0x11ab+-0x3*-0x1cd+0x2*-0xb89,0x1*0x41f+0x3c*-0x5d+0x11ad*0x1,h['width'],h['height']);if(window['g_wiggle_b'+'uffer_canv'+'as']&&M['HudFQ'](g_wiggle_buffer_canvas['width'],0x56*0x49+0x62*-0x41+-0x17*-0x4)&&g_wiggle_buffer_canvas['height']>0xe*-0x277+-0x5*0x6e3+0x44f1)P['drawImage'](g_wiggle_buffer_canvas,Y,g);else{console['warn'](M['hOxon']),g_wiggle_animation_running=![];return;}M['EHRhQ'](requestAnimationFrame,w=>applyWiggleAnimationToPreview(K,w));}async function startWiggleAnimation(){const K={'oHxKu':function(G,D){return G(D);},'HCTfR':'#checkbox-'+'captions-g'+'raphics-wi'+'ggle','YiJDD':':checked','UguMW':'captions-c'+'anvas-cont'+'ainer-canv'+'as','DhsrU':'captions-c'+'anvas-wigg'+'le-contain'+'er-canvas','eaiWh':'Wiggle\x20can'+'vas\x20initia'+'lized\x20with'+'\x20dimension'+'s:','kNlsQ':function(G){return G();},'ANbOR':'canvas','NqoCi':'Creating\x20w'+'iggle\x20buff'+'er\x20canvas:','BEdAo':function(G,D,C,J,Q,I){return G(D,C,J,Q,I);},'aIYbH':'all','IjkIF':'Wiggle\x20buf'+'fer\x20render'+'\x20result:','FPwQI':'Wiggle\x20buf'+'fer\x20has\x20co'+'ntent:','kmyDX':function(G,D,C){return G(D,C);}};if(!K['oHxKu']($,K['HCTfR'])['is'](K['YiJDD'])||g_wiggle_animation_running)return;g_wiggle_animation_running=!![];const n=await jsxProject['sequenceWi'+'dth'](),M=document['getElement'+'ById'](K['UguMW']),Y=document['getElement'+'ById'](K['DhsrU']);Y['width']=M['width'],Y['height']=M['height'],window['g_wiggle_o'+'riginal_wi'+'dth']=Y['width'],window['g_wiggle_o'+'riginal_he'+'ight']=Y['height'],console['log'](K['eaiWh'],Y['width'],'x',Y['height']);const g=K['kNlsQ'](test_76_get_caption_render_params);window['g_wiggle_b'+'uffer_canv'+'as']=document['createElem'+'ent'](K['ANbOR']),g_wiggle_buffer_canvas['width']=Y['width'],g_wiggle_buffer_canvas['height']=Y['height'],console['log'](K['NqoCi'],g_wiggle_buffer_canvas['width'],'x',g_wiggle_buffer_canvas['height']);const h=K['BEdAo'](test_74_render_captions_by_index,g_wiggle_buffer_canvas,-0x5*-0x602+-0x37a+-0x1a90,-0xa16*0x2+-0x7*-0x30d+-0x65*0x3,g,K['aIYbH']);console['log'](K['IjkIF'],h);const P=g_wiggle_buffer_canvas['getContext']('2d'),w=P['getImageDa'+'ta'](0x22ff+-0x3b9+-0x1f46,-0x2ab*-0x2+-0x224a*0x1+0x1cf4,g_wiggle_buffer_canvas['width'],g_wiggle_buffer_canvas['height']),R=w['data']['some'](G=>G!==-0x67c+-0x5d7*0x2+-0x9b*-0x1e);console['log'](K['FPwQI'],R),K['kmyDX'](applyWiggleAnimationToPreview,n,performance['now']());}function updateWiggleBuffer(){const K={'zkaMQ':'Updating\x20w'+'iggle\x20buff'+'er\x20due\x20to\x20'+'position\x20c'+'hange','iHwYN':function(Y){return Y();}};if(!g_wiggle_animation_running||!window['g_wiggle_b'+'uffer_canv'+'as'])return;console['log'](K['zkaMQ']);const n=K['iHwYN'](test_76_get_caption_render_params),M=g_wiggle_buffer_canvas['getContext']('2d');M['clearRect'](0x2*0x6d1+0x1*-0x2071+0x12cf,0xd68+-0x522*0x5+0x20b*0x6,g_wiggle_buffer_canvas['width'],g_wiggle_buffer_canvas['height']),test_74_render_captions_by_index(g_wiggle_buffer_canvas,-0x3a*-0x5c+-0x1abc+-0x1*-0x5e4,0x57e+-0x53a+0x1*-0x44,n,'all');}