mirror of
https://github.com/He4eT/elseifplayer.git
synced 2026-05-05 01:17:22 +00:00
Themes: add themes
This commit is contained in:
parent
ab69dff04d
commit
26760082f9
6 changed files with 132 additions and 17 deletions
|
|
@ -84,7 +84,7 @@ export default function ({ currentWindow, inputType, sendMessage }) {
|
||||||
value={inputText}
|
value={inputText}
|
||||||
placeholder={placeholder[inputType]}
|
placeholder={placeholder[inputType]}
|
||||||
autofocus
|
autofocus
|
||||||
autocomplete="off"
|
autocomplete='off'
|
||||||
onDblClick={enterFullscreen}
|
onDblClick={enterFullscreen}
|
||||||
onInput={({ target: { value } }) => setInputText(value)}
|
onInput={({ target: { value } }) => setInputText(value)}
|
||||||
type='search' />
|
type='search' />
|
||||||
|
|
|
||||||
|
|
@ -57,7 +57,7 @@ export default function ({ inbox, currentWindow }) {
|
||||||
const inputs =
|
const inputs =
|
||||||
textBufferEl.current.querySelectorAll('.message.input')
|
textBufferEl.current.querySelectorAll('.message.input')
|
||||||
const lastInput =
|
const lastInput =
|
||||||
inputs[inputs.length- 1]
|
inputs[inputs.length - 1]
|
||||||
|
|
||||||
textBufferEl.current.scrollTop =
|
textBufferEl.current.scrollTop =
|
||||||
lastInput
|
lastInput
|
||||||
|
|
|
||||||
|
|
@ -4,17 +4,22 @@
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
|
|
||||||
padding: 8px;
|
background-color: var(--bg-color);
|
||||||
color: hsl(0, 0%, 0%, 0.8);
|
color: var(--main-color);
|
||||||
|
padding: var(--outer-padding);
|
||||||
}
|
}
|
||||||
|
|
||||||
.inputBox {
|
.inputBox {
|
||||||
flex: 0 1 auto;
|
flex: 0 1 auto;
|
||||||
|
|
||||||
font: inherit;
|
font: inherit;
|
||||||
|
color: inherit;
|
||||||
outline: 0;
|
outline: 0;
|
||||||
border: 2px solid hsl(0, 0%, 0%, 0.8);;
|
|
||||||
padding: 8px;
|
background-color: var(--bg-color);
|
||||||
|
border: var(--border-width) solid var(--main-color);
|
||||||
|
padding: var(--inner-padding);
|
||||||
|
margin-top: var(--input-box-margin);
|
||||||
}
|
}
|
||||||
|
|
||||||
.textBuffer {
|
.textBuffer {
|
||||||
|
|
@ -22,9 +27,11 @@
|
||||||
overflow-y: scroll;
|
overflow-y: scroll;
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
|
|
||||||
border: 2px solid hsl(0, 0%, 0%, 0.8);;
|
border: var(--border-width) solid var(--main-color);
|
||||||
padding: 8px;
|
padding: var(--inner-padding);
|
||||||
margin-bottom: 8px;
|
|
||||||
|
scrollbar-color: hsl(0, 0%, 50%, 0.5) var(--bg-color);
|
||||||
|
scrollbar-width: thin;
|
||||||
}
|
}
|
||||||
|
|
||||||
.textBuffer > br:first-child,
|
.textBuffer > br:first-child,
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,14 @@ html, body {
|
||||||
font-family: 'Open Sans', sans-serif;
|
font-family: 'Open Sans', sans-serif;
|
||||||
}
|
}
|
||||||
|
|
||||||
body {
|
#root {
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.app {
|
||||||
|
height: 100%;
|
||||||
|
box-sizing: border-box;
|
||||||
|
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
|
|
@ -13,23 +20,23 @@ body {
|
||||||
font-size: 18px;
|
font-size: 18px;
|
||||||
line-height: 27px;
|
line-height: 27px;
|
||||||
|
|
||||||
|
background-color: var(--bg-color);
|
||||||
|
color: var(--main-color);
|
||||||
|
padding: var(--outer-padding);
|
||||||
}
|
}
|
||||||
|
|
||||||
#root {
|
.app > main {
|
||||||
flex: 1 1 auto;
|
flex: 1 1 auto;
|
||||||
|
|
||||||
height: 100%;
|
height: 100%;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
box-sizing: border-box;
|
||||||
}
|
}
|
||||||
@media (min-width: 800px) {
|
@media (min-width: 800px) {
|
||||||
#root {
|
.app > main {
|
||||||
height: 90%;
|
height: 90%;
|
||||||
max-height: 90%;
|
max-height: 90%;
|
||||||
|
|
||||||
max-width: 800px;
|
max-width: 800px;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.app {
|
|
||||||
height: 100%;
|
|
||||||
}
|
|
||||||
|
|
|
||||||
|
|
@ -1 +1,98 @@
|
||||||
|
.default {
|
||||||
|
--bg-color: #ffffff;
|
||||||
|
--main-color: hsl(0, 0%, 0%, 0.8);
|
||||||
|
--outer-padding: 0px;
|
||||||
|
--inner-padding: 8px;
|
||||||
|
--border-width: 0px;
|
||||||
|
--input-box-margin: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.default-borders {
|
||||||
|
--bg-color: #ffffff;
|
||||||
|
--main-color: hsl(0, 0%, 0%, 0.8);
|
||||||
|
--outer-padding: 8px;
|
||||||
|
--inner-padding: 8px;
|
||||||
|
--border-width: 2px;
|
||||||
|
--input-box-margin: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.default-dim {
|
||||||
|
--bg-color: hsl(0, 0%, 20%);
|
||||||
|
--main-color: hsl(0, 0%, 100%, 0.8);
|
||||||
|
--outer-padding: 0px;
|
||||||
|
--inner-padding: 8px;
|
||||||
|
--border-width: 0px;
|
||||||
|
--input-box-margin: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.default-dim-borders {
|
||||||
|
--bg-color: hsl(0, 0%, 20%);
|
||||||
|
--main-color: hsl(0, 0%, 100%, 0.8);
|
||||||
|
--outer-padding: 8px;
|
||||||
|
--inner-padding: 8px;
|
||||||
|
--border-width: 2px;
|
||||||
|
--input-box-margin: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.default-dark {
|
||||||
|
--bg-color: #000000;
|
||||||
|
--main-color: #ffffff;
|
||||||
|
--outer-padding: 0px;
|
||||||
|
--inner-padding: 8px;
|
||||||
|
--border-width: 0px;
|
||||||
|
--input-box-margin: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.default-dark-borders {
|
||||||
|
--bg-color: #000000;
|
||||||
|
--main-color: #ffffff;
|
||||||
|
--outer-padding: 8px;
|
||||||
|
--inner-padding: 8px;
|
||||||
|
--border-width: 2px;
|
||||||
|
--input-box-margin: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* solarized */
|
||||||
|
|
||||||
|
.solarized-light,
|
||||||
|
.solarized-light-borders,
|
||||||
|
.solarized-dark,
|
||||||
|
.solarized-dark-borders {
|
||||||
|
--outer-padding: 0px;
|
||||||
|
--inner-padding: 8px;
|
||||||
|
--border-width: 0px;
|
||||||
|
--input-box-margin: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.solarized-light-borders,
|
||||||
|
.solarized-dark-borders {
|
||||||
|
--outer-padding: 8px;
|
||||||
|
--inner-padding: 8px;
|
||||||
|
--border-width: 2px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.solarized-light,
|
||||||
|
.solarized-light-borders {
|
||||||
|
--main-color: #586e75;
|
||||||
|
--bg-color: #eee8d5;
|
||||||
|
}
|
||||||
|
|
||||||
|
.solarized-dark,
|
||||||
|
.solarized-dark-borders {
|
||||||
|
--main-color: #93a1a1;
|
||||||
|
--bg-color: #073642;
|
||||||
|
}
|
||||||
|
|
||||||
|
.solarized-light strong,
|
||||||
|
.solarized-light-borders strong,
|
||||||
|
.solarized-dark strong,
|
||||||
|
.solarized-dark-borders strong{
|
||||||
|
color: #b58900;
|
||||||
|
}
|
||||||
|
|
||||||
|
.solarized-light .message.input,
|
||||||
|
.solarized-light-borders .message.input,
|
||||||
|
.solarized-dark .message.input,
|
||||||
|
.solarized-dark-borders .message.input{
|
||||||
|
color: #2aa198;
|
||||||
|
}
|
||||||
|
|
|
||||||
|
|
@ -14,5 +14,9 @@ export default function ({ setTheme, theme, encodedUrl }) {
|
||||||
setTargetUrl(decode(encodedUrl))
|
setTargetUrl(decode(encodedUrl))
|
||||||
}, [encodedUrl])
|
}, [encodedUrl])
|
||||||
|
|
||||||
return (<UrlPlayer url={targetUrl} />)
|
return (
|
||||||
|
<main>
|
||||||
|
<UrlPlayer url={targetUrl} />
|
||||||
|
</main>
|
||||||
|
)
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue