mirror of
https://github.com/aljazceru/pear-docs.git
synced 2025-12-17 14:34:19 +01:00
tweaks
This commit is contained in:
79
index.html
79
index.html
@@ -182,33 +182,18 @@
|
|||||||
|
|
||||||
pear-ctrl[data-platform="darwin"] {
|
pear-ctrl[data-platform="darwin"] {
|
||||||
margin-top: 16px;
|
margin-top: 16px;
|
||||||
|
margin-left: 8px;
|
||||||
}
|
}
|
||||||
|
|
||||||
system-status,
|
system-status,
|
||||||
docs-viewer,
|
docs-viewer {
|
||||||
developer-tooling {
|
|
||||||
position: relative;
|
position: relative;
|
||||||
top: 156px
|
top: 156px
|
||||||
}
|
}
|
||||||
|
|
||||||
#version {
|
developer-tooling {
|
||||||
position: fixed;
|
position: relative;
|
||||||
top: 96vh;
|
top: 96px
|
||||||
font-size: .6rem;
|
|
||||||
background: #1a1a1a;
|
|
||||||
color: white;
|
|
||||||
opacity: 1;
|
|
||||||
padding: 8px;
|
|
||||||
padding-top: 0px;
|
|
||||||
padding-bottom: 0px;
|
|
||||||
transition: top 0.3s;
|
|
||||||
border-radius: .35rem;
|
|
||||||
border: 1px solid #3a4816;
|
|
||||||
}
|
|
||||||
|
|
||||||
#version:hover {
|
|
||||||
top: 92vh;
|
|
||||||
transition: top 0.3s;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
a:visited,
|
a:visited,
|
||||||
@@ -287,19 +272,55 @@
|
|||||||
</section>
|
</section>
|
||||||
<script type='module' src='./lib/docs-viewer.js'></script>
|
<script type='module' src='./lib/docs-viewer.js'></script>
|
||||||
<section>
|
<section>
|
||||||
<div class="col"><developer-tooling></devtools></div>
|
<div class="col"><developer-tooling></developer-tooling></div>
|
||||||
</section>
|
</section>
|
||||||
<section id="version">
|
<script type="module">
|
||||||
|
customElements.define('pear-version', class extends HTMLElement {
|
||||||
|
constructor () {
|
||||||
|
super()
|
||||||
|
this.template = document.createElement('template')
|
||||||
|
this.template.innerHTML = `
|
||||||
|
<style>
|
||||||
|
:host > div {
|
||||||
|
position: fixed;
|
||||||
|
top: 96vh;
|
||||||
|
font-size: .6rem;
|
||||||
|
background: #1a1a1a;
|
||||||
|
color: white;
|
||||||
|
opacity: 1;
|
||||||
|
padding: 8px;
|
||||||
|
padding-top: 0px;
|
||||||
|
padding-bottom: 0px;
|
||||||
|
border-radius: .35rem;
|
||||||
|
border: 1px solid #3a4816;
|
||||||
|
transition: top 0.3s;
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
|
||||||
|
:host > div:hover {
|
||||||
|
top: 92vh;
|
||||||
|
transition: top 0.3s;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
<div>
|
||||||
<p id="platform-version"></p>
|
<p id="platform-version"></p>
|
||||||
<p id="app-version"></p>
|
<p id="app-version"></p>
|
||||||
</section>
|
</div>
|
||||||
<script>
|
`
|
||||||
const { versions } = Pear
|
this.root = this.attachShadow({ mode: 'open' })
|
||||||
process.env.WS_NO_BUFFER_UTIL = false // ws buffer-util opt-out
|
|
||||||
versions().then(({ app, platform }) => {
|
Pear.versions().then(({ app, platform }) => {
|
||||||
document.querySelector('#platform-version').innerText = `Pear Runtime ${platform.fork}.${platform.length}.${platform.key}`
|
this.root.appendChild(this.template.content.cloneNode(true))
|
||||||
document.querySelector('#app-version').innerText = `Pear Rtm App ${app.fork}.${app.length}.${app.key}`
|
this.root.querySelector('#platform-version').innerText = `Pear Runtime ${platform.fork}.${platform.length}.${platform.key}`
|
||||||
|
this.root.querySelector('#app-version').innerText = `Pear Rtm App ${app.fork}.${app.length}.${app.key}`
|
||||||
})
|
})
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
</script>
|
||||||
|
<pear-version></pear-version>
|
||||||
|
<script>
|
||||||
|
process.env.WS_NO_BUFFER_UTIL = false // ws buffer-util opt-out
|
||||||
</script>
|
</script>
|
||||||
<script type='module' src='./lib/devtools.js'></script>
|
<script type='module' src='./lib/devtools.js'></script>
|
||||||
</app-router>
|
</app-router>
|
||||||
|
|||||||
@@ -15,6 +15,11 @@ customElements.define('developer-tooling', class extends HTMLElement {
|
|||||||
this.template.innerHTML = `
|
this.template.innerHTML = `
|
||||||
<div>
|
<div>
|
||||||
<style>
|
<style>
|
||||||
|
:host > div {
|
||||||
|
padding-bottom: 4rem;
|
||||||
|
font-size: .9em;
|
||||||
|
}
|
||||||
|
|
||||||
#add-key-input {
|
#add-key-input {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user