$(function() { /* glow in the gr.id campaign var grid_url = 'https://bit.ly/3DhJhkZ'; // https://gridsingapore.com/glow-in-the-gr-id/ var grid_title = 'Glow in the GR.iD'; var voucher_url = 'https://bit.ly/3rTAdQV'; // https://grid.skale.today/voucher var voucher_title = 'Voucher Wallet'; */ /* hallogr.id campaign */ var grid_url = 'https://gridsingapore.com/dragons-prosperity-at-gr-id/?utm_source=grid&utm_medium=scratchcard&utm_campaign=cny2024'; var grid_title = 'More Activities'; var grid_url_home = 'https://gridsingapore.com/?utm_source=grid&utm_medium=scratchcard&utm_campaign=cny2024'; var grid_title_home = 'Website'; var voucher_url = 'https://grid.skale.today/voucher?utm_source=grid&utm_medium=scratchcard&utm_campaign=cny2024'; var voucher_title = 'Deals'; // registration page quick links var $signup = $('#form-signup'); if($signup.length > 0){ $signup.append(`
${grid_title} ${voucher_title}
`); } // main game page quick links var $bottom = $('.bottom_ui_wrapper'); if($bottom.length > 0){ $bottom.append(`
`) $('#grid_url_btn').on('click', (e)=>{ var win = window.open(grid_url, '_blank'); if (win) { win.focus(); } }); $bottom.append(`
`) $('#grid_voucher_btn').on('click', (e)=>{ var win = window.open(voucher_url, '_blank'); if (win) { win.focus(); } }); } // top nav menu if(!window.location.pathname.includes('/voucher') && !window.location.pathname.includes('/my') ){ var $nav = $('.navbar-nav'); if($nav.length >0){ // 3rd item // $(``).insertAfter(".nav-item:first") // 2nd item $(``).insertAfter(".nav-item:first") // first item // $(``).insertAfter(".nav-item:first") } $('.nav-link:not([href="/"]):not([href="/logout"])').attr('target','_blank'); // change copy daily check in $('.popup-daily-checkin-caption').text('Check in daily to earn points!') } // change copy game titles var $title = $('.main-game-wrapper h5:first'); if($title.length > 0){ $title.html('Shop & Dine at GR.iD for Rewards'); } var $pointsLabel = $('[name=reward_point]'); if($pointsLabel.length > 0){ $(' pts').insertAfter($pointsLabel); } var $chancesLabel = $('[name=chance_balance]'); if($chancesLabel.length > 0){ $(' chance(s)').insertAfter($chancesLabel); } var hidePassAlert = document.querySelector('.alert.alert-primary.m-0'); if (hidePassAlert) { hidePassAlert.style.display = 'none'; } });