Removed analytics script and mscc banner

This commit is contained in:
Ahmed Sabbour 2021-10-25 16:40:12 +00:00 коммит произвёл GitHub
Родитель 71f5de6821
Коммит 01f703f0e8
2 изменённых файлов: 1 добавлений и 58 удалений

Просмотреть файл

@ -4,67 +4,17 @@
<meta name="author" content="{{ site.author }}">
<link rel="stylesheet" href="css/main.css">
<link href='https://fonts.googleapis.com/css?family=Source+Code+Pro:500,600' rel='stylesheet' type='text/css'>
<link href='https://c.s-microsoft.com/mscc/statics/mscc-0.4.1.min.css' rel='stylesheet' type='text/css'>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="css/github-markdown.css">
<script src="js/jquery-2.1.1.min.js"></script>
<script src="https://c.s-microsoft.com/mscc/statics/mscc-0.4.1.min.js"></script>
<!-- Place this tag in your head or just before your close body tag. -->
<script async defer src="https://buttons.github.io/buttons.js"></script>
<script type="text/javascript">
function loadJS(url, implementationCode, location){
var scriptTag = document.createElement('script');
scriptTag.src = url;
scriptTag.onload = implementationCode;
scriptTag.onreadystatechange = implementationCode;
location.appendChild(scriptTag);
}
function d() {
var config = {
useDefaultContentName: true,
useBeacon: true,
useShortNameForContentBlob: true,
debounceMs: {
scroll: 300,
resize: 3000
},
autoCapture: {
pageView: true,
scroll: true,
lineage: true
},
coreData: {
appId: "AROWorkshop"
}
};
awa.init(config);
}
function addTelemetryTag() {
var appInsights=window.appInsights||function(a){
function b(a){c[a]=function(){var b=arguments;c.queue.push(function(){c[a].apply(c,b)})}}var c={config:a},d=document,e=window;setTimeout(function(){var b=d.createElement("script");b.src=a.url||"https://az416426.vo.msecnd.net/scripts/a/ai.0.js",d.getElementsByTagName("script")[0].parentNode.appendChild(b)});try{c.cookie=d.cookie}catch(a){}c.queue=[];for(var f=["Event","Exception","Metric","PageView","Trace","Dependency"];f.length;)b("track"+f.pop());if(b("setAuthenticatedUserContext"),b("clearAuthenticatedUserContext"),b("startTrackEvent"),b("stopTrackEvent"),b("startTrackPage"),b("stopTrackPage"),b("flush"),!a.disableExceptionTracking){f="onerror",b("_"+f);var g=e[f];e[f]=function(a,b,d,e,h){var i=g&&g(a,b,d,e,h);return!0!==i&&c["_"+f](a,b,d,e,h),i}}return c
}({
instrumentationKey:"9d4d95c1-b8a7-4526-9e74-08baac9cbacd"
});
window.appInsights=appInsights,appInsights.queue&&0===appInsights.queue.length&&appInsights.trackPageView();
loadJS("https://az725175.vo.msecnd.net/scripts/jsll-4.js",initAWA,document.head);
}
// mscc will only exist if written by the server
if (typeof(mscc) === 'undefined' || mscc.hasConsent()) {
addTelemetryTag();
} else {
mscc.on('consent', addTelemetryTag);
}
$(document).ready(function(){
$('a').each(function(i, oldHref){
if(oldHref.href.includes("docs.microsoft.com") || oldHref.href.includes("azure.microsoft.com")) {

Просмотреть файл

@ -11,11 +11,4 @@ $(document).ready(function(){
$(this).toggleClass('active');
$(this).next().toggle();
});
$.get("https://uhf.microsoft.com/en-US/shell/api/mscc?sitename=aksworkshop.io&domain=aksworkshop.io&country=euregion", function(data, status){
if(data.IsConsentRequired) {
$("#consent-container").html(data.Markup);
$("#msccBanner").show();
}
});
});