monkeeShark/src/client/app/common/scripts/fuck-ad-block.ts

22 lines
381 B
TypeScript
Raw Normal View History

2018-02-20 17:53:34 +00:00
declare const fuckAdBlock: any;
export default ($root: any) => {
require('fuckadblock');
2018-02-20 17:53:34 +00:00
function adBlockDetected() {
$root.$dialog({
2018-11-11 10:15:08 +00:00
title: $root.$t('@.adblock.detected'),
text: $root.$t('@.adblock.warning'),
2018-02-20 17:53:34 +00:00
actins: [{
text: 'OK'
}]
});
}
if (fuckAdBlock === undefined) {
adBlockDetected();
} else {
fuckAdBlock.onDetected(adBlockDetected);
}
};