diff --git a/doc/static/acrn-custom.css b/doc/static/acrn-custom.css index 044383d0a..444d5634a 100644 --- a/doc/static/acrn-custom.css +++ b/doc/static/acrn-custom.css @@ -299,3 +299,10 @@ div.numbered-step h2::before { .rst-content .toctree-l1 > a { font-weight: bold; } + +/* add icon on external links */ +a.reference.external::after { + font-family: 'FontAwesome'; + font-size: 80%; + content: " \f08e"; +} diff --git a/doc/static/acrn-custom.js b/doc/static/acrn-custom.js index e0e235899..f602e1d6f 100644 --- a/doc/static/acrn-custom.js +++ b/doc/static/acrn-custom.js @@ -1,7 +1,11 @@ -/* tweak logo link */ +/* Extra acrn-specific javascript */ $(document).ready(function(){ - $( ".icon-home" ).attr("href", "https://projectacrn.org/"); + /* tweak logo link to the marketing site instead of doc site */ + $( ".icon-home" ).attr({href: "https://projectacrn.org/", target: "_blank"}); + + /* open external links in a new tab */ + $('a[class*=external]').attr({target: '_blank', rel: 'noopener'}); }); /* Global site tag (gtag.js) - Google Analytics */