2018-02-20 18:53:34 +01:00
|
|
|
declare const fuckAdBlock: any;
|
|
|
|
|
|
|
|
export default (os) => {
|
2018-09-24 01:00:10 +02:00
|
|
|
require('fuckadblock');
|
|
|
|
|
2018-02-20 18:53:34 +01:00
|
|
|
function adBlockDetected() {
|
|
|
|
os.apis.dialog({
|
2018-08-02 12:03:31 +02:00
|
|
|
title: '%fa:exclamation-triangle%%i18n:common.adblock.detected%',
|
|
|
|
text: '%i18n:common.adblock.warning%',
|
2018-02-20 18:53:34 +01:00
|
|
|
actins: [{
|
|
|
|
text: 'OK'
|
|
|
|
}]
|
|
|
|
});
|
|
|
|
}
|
|
|
|
|
|
|
|
if (fuckAdBlock === undefined) {
|
|
|
|
adBlockDetected();
|
|
|
|
} else {
|
|
|
|
fuckAdBlock.onDetected(adBlockDetected);
|
|
|
|
}
|
|
|
|
};
|