mirror of
https://github.com/lubosz/overte.git
synced 2025-04-27 06:55:40 +02:00
Merge pull request #115 from kasenvr/feature/js-doc-night
API Docs now default to a brand new dark theme.
This commit is contained in:
commit
e4684baea0
11 changed files with 78066 additions and 6 deletions
tools/jsdoc/hifi-jsdoc-template
Binary file not shown.
Binary file not shown.
6
tools/jsdoc/hifi-jsdoc-template/static/scripts/vue.min.js
vendored
Normal file
6
tools/jsdoc/hifi-jsdoc-template/static/scripts/vue.min.js
vendored
Normal file
File diff suppressed because one or more lines are too long
11965
tools/jsdoc/hifi-jsdoc-template/static/scripts/vue_dev.js
Normal file
11965
tools/jsdoc/hifi-jsdoc-template/static/scripts/vue_dev.js
Normal file
File diff suppressed because it is too large
Load diff
41072
tools/jsdoc/hifi-jsdoc-template/static/scripts/vuetify.js
Normal file
41072
tools/jsdoc/hifi-jsdoc-template/static/scripts/vuetify.js
Normal file
File diff suppressed because it is too large
Load diff
|
@ -198,12 +198,12 @@ article li {
|
|||
|
||||
nav {
|
||||
position: fixed;
|
||||
top: 260px;
|
||||
top: 275px;
|
||||
bottom: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
width: 300px;
|
||||
background-color: #000000;
|
||||
background-color: #27343B;
|
||||
border-right: 1px solid #ccc;
|
||||
overflow-y: scroll;
|
||||
padding-left: 20px;
|
||||
|
@ -232,9 +232,9 @@ nav #nav-search {
|
|||
position: fixed;
|
||||
top: 0;
|
||||
left: 0;
|
||||
height: 260px;
|
||||
height: 275px;
|
||||
width: 300px;
|
||||
background-color: #000000;
|
||||
background-color: #27343B;
|
||||
color: #FFFFFF;
|
||||
text-align: center;
|
||||
margin-top: 0px;
|
||||
|
@ -374,11 +374,12 @@ nav > h2 > a {
|
|||
.search-input
|
||||
{
|
||||
font-family: 'Graphik Regular', sans-serif;
|
||||
font-size: 80%;
|
||||
font-size: 90%;
|
||||
border: 1px solid #ddd;
|
||||
box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.06);
|
||||
border-radius: 0;
|
||||
color: #3A3F3E;
|
||||
background: rgba(76,76,76,0.47) !important;
|
||||
color: white;
|
||||
width: 70%;
|
||||
padding: 10px;
|
||||
}
|
||||
|
|
3
tools/jsdoc/hifi-jsdoc-template/static/styles/materialdesignicons.min.css
vendored
Normal file
3
tools/jsdoc/hifi-jsdoc-template/static/styles/materialdesignicons.min.css
vendored
Normal file
File diff suppressed because one or more lines are too long
67
tools/jsdoc/hifi-jsdoc-template/static/styles/night.css
Normal file
67
tools/jsdoc/hifi-jsdoc-template/static/styles/night.css
Normal file
|
@ -0,0 +1,67 @@
|
|||
html {
|
||||
background-color: #061F2F;
|
||||
}
|
||||
|
||||
body h1 {
|
||||
color: #eaeaea;
|
||||
}
|
||||
|
||||
body {
|
||||
color: #d3d4d4 !important;
|
||||
}
|
||||
|
||||
section {
|
||||
background-color: #061F2F;
|
||||
}
|
||||
|
||||
code {
|
||||
background-color: #0a121b !important;
|
||||
}
|
||||
|
||||
/* Prettify */
|
||||
|
||||
.typ {
|
||||
color: #f8c555 !important;
|
||||
}
|
||||
|
||||
.pun {
|
||||
color: #c1f1f0 !important;
|
||||
}
|
||||
|
||||
.pln {
|
||||
color: #c1f1f0 !important;
|
||||
}
|
||||
|
||||
.kwd {
|
||||
color: #e8a0e8 !important;
|
||||
}
|
||||
|
||||
.str {
|
||||
color: #f08d49 !important;
|
||||
}
|
||||
|
||||
/* JSDoc */
|
||||
|
||||
thead {
|
||||
background: #1f3341 !important;
|
||||
}
|
||||
|
||||
thead tr {
|
||||
color: white !important;
|
||||
}
|
||||
|
||||
table tr:nth-child(2n) {
|
||||
background: #1f3341 !important;
|
||||
}
|
||||
|
||||
.name code {
|
||||
color: #e8a0e8 !important;
|
||||
}
|
||||
|
||||
#main a, #main a:visited, #main a:active, #main a:hover {
|
||||
color: #69d3ff !important;
|
||||
}
|
||||
|
||||
.important {
|
||||
color: #F91E1E !important;
|
||||
}
|
24874
tools/jsdoc/hifi-jsdoc-template/static/styles/vuetify.css
Normal file
24874
tools/jsdoc/hifi-jsdoc-template/static/styles/vuetify.css
Normal file
File diff suppressed because it is too large
Load diff
8
tools/jsdoc/hifi-jsdoc-template/static/styles/vuetify.min.css
vendored
Normal file
8
tools/jsdoc/hifi-jsdoc-template/static/styles/vuetify.min.css
vendored
Normal file
File diff suppressed because one or more lines are too long
|
@ -4,6 +4,9 @@
|
|||
<?js if (!env.conf.docdash) { env.conf.docdash = {};} ?>
|
||||
<meta charset="utf-8">
|
||||
<title><?js= title ?></title>
|
||||
|
||||
<script src="scripts/vue.min.js"></script>
|
||||
<script src="scripts/vuetify.js"></script>
|
||||
|
||||
<script src="scripts/prettify/prettify.js"></script>
|
||||
<script src="scripts/prettify/lang-css.js"></script>
|
||||
|
@ -12,6 +15,32 @@
|
|||
<![endif]-->
|
||||
<link type="text/css" rel="stylesheet" href="styles/prettify.css">
|
||||
<link type="text/css" rel="stylesheet" href="styles/jsdoc.css">
|
||||
<link type="text/css" rel="stylesheet" href="styles/night.css">
|
||||
<link href="https://fonts.googleapis.com/css?family=Roboto:100,300,400,500,700,900" rel="stylesheet">
|
||||
<link href="https://fonts.googleapis.com/css?family=Material+Icons|Material+Icons+Outlined|Material+Icons+Two+Tone|Material+Icons+Round|Material+Icons+Sharp" rel="stylesheet">
|
||||
<link href="styles/materialdesignicons.min.css" rel="stylesheet">
|
||||
<link href="styles/vuetify.css" rel="stylesheet">
|
||||
<style>
|
||||
.v-application--wrap {
|
||||
min-height: 0 !important;
|
||||
}
|
||||
|
||||
/** Override Vue CSS. */
|
||||
.theme--dark.v-application {
|
||||
background: #27343b !important;
|
||||
}
|
||||
</style>
|
||||
<script>
|
||||
//We are running the check here to preload the theme because it may load the incorrect one first for a split second.
|
||||
var darkDisabled = JSON.parse(localStorage.getItem('darkDisabled'));
|
||||
if (darkDisabled == null) {
|
||||
localStorage.setItem('darkDisabled', JSON.stringify("false"));
|
||||
} else {
|
||||
var nightSheet = document.querySelector('[href="styles/night.css"]');
|
||||
nightSheet.disabled = darkDisabled;
|
||||
}
|
||||
</script>
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no, minimal-ui">
|
||||
<link href="images/fav-icon.ico" rel="shortcut icon">
|
||||
</head>
|
||||
<body>
|
||||
|
@ -22,6 +51,14 @@
|
|||
<input type="text" class="search-input" id="nav-search" placeholder="Search API Docs ..." />
|
||||
<?js } ?>
|
||||
<p><a href="https://docs.projectathena.dev">Looking for <strong>Project Athena</strong><br /> Documentation?</a></p>
|
||||
<div id="app">
|
||||
<v-app dark>
|
||||
<v-btn @click="toggleNightMode" text dark>
|
||||
Toggle
|
||||
<v-icon class="ml-2">mdi-theme-light-dark</v-icon>
|
||||
</v-btn>
|
||||
</v-app>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<nav>
|
||||
|
@ -71,6 +108,33 @@
|
|||
<?js } ?>
|
||||
<?js } ?>
|
||||
|
||||
<script>
|
||||
new Vue({
|
||||
el: '#app',
|
||||
vuetify: new Vuetify({
|
||||
theme: {
|
||||
dark: true,
|
||||
},
|
||||
}),
|
||||
data: () => ({
|
||||
|
||||
}),
|
||||
created: function () {
|
||||
|
||||
},
|
||||
methods: {
|
||||
toggleNightMode: function() {
|
||||
var darkDisabled = JSON.parse(localStorage.getItem('darkDisabled'));
|
||||
localStorage.setItem('darkDisabled', JSON.stringify(!darkDisabled));
|
||||
darkDisabled = !darkDisabled;
|
||||
|
||||
var nightSheet = document.querySelector('[href="styles/night.css"]');
|
||||
nightSheet.disabled = darkDisabled;
|
||||
}
|
||||
},
|
||||
})
|
||||
</script>
|
||||
|
||||
<!-- Start Google Analytics Tag -->
|
||||
<!--
|
||||
<script>
|
||||
|
|
Loading…
Reference in a new issue