rudeshark.net/src/client/app/common/scripts/fuck-ad-block.ts
2018-08-02 19:03:31 +09:00

22 lines
402 B
TypeScript

require('fuckadblock');
declare const fuckAdBlock: any;
export default (os) => {
function adBlockDetected() {
os.apis.dialog({
title: '%fa:exclamation-triangle%%i18n:common.adblock.detected%',
text: '%i18n:common.adblock.warning%',
actins: [{
text: 'OK'
}]
});
}
if (fuckAdBlock === undefined) {
adBlockDetected();
} else {
fuckAdBlock.onDetected(adBlockDetected);
}
};