diff --git a/linkerd.io/assets/js/follow-linkedin.js b/linkerd.io/assets/js/follow-linkedin.js new file mode 100644 index 0000000000..b1f0280061 --- /dev/null +++ b/linkerd.io/assets/js/follow-linkedin.js @@ -0,0 +1,9 @@ +setTimeout(function(){ + var buttonWrapper = document.querySelector('.linkedin__btn'); + widthOriginal = buttonWrapper.getBoundingClientRect().width; + //console.log("-"+widthOriginal); + + if(widthOriginal>99){ + buttonWrapper.style.display = 'none'; + } +}, 2300); diff --git a/linkerd.io/assets/scss/styles.scss b/linkerd.io/assets/scss/styles.scss index 707453135b..ed407fdb0a 100644 --- a/linkerd.io/assets/scss/styles.scss +++ b/linkerd.io/assets/scss/styles.scss @@ -925,3 +925,7 @@ blockquote { .modal-content { width: 95%; } + +.linkedin__btn{ + z-index: 999; display: block; top: 100px; right: -5px; position: fixed; +} \ No newline at end of file diff --git a/linkerd.io/layouts/partials/header.html b/linkerd.io/layouts/partials/header.html index f1a91dc849..b7c644a516 100644 --- a/linkerd.io/layouts/partials/header.html +++ b/linkerd.io/layouts/partials/header.html @@ -14,3 +14,8 @@ {{ $js := resources.Get "js/navbar.js" | resources.Minify | resources.Fingerprint }} + +
+ + +
diff --git a/linkerd.io/layouts/partials/javascript.html b/linkerd.io/layouts/partials/javascript.html index 73b4c75a37..7778aed7da 100644 --- a/linkerd.io/layouts/partials/javascript.html +++ b/linkerd.io/layouts/partials/javascript.html @@ -35,4 +35,7 @@ {{ $headingsLinkJs := resources.Get "js/docs-heading-link.js"}} +{{ $linkedinJs := resources.Get "js/follow-linkedin.js" }} + + \ No newline at end of file