error handling, launcher ui, read-only mode, rm plot/smooth

This commit is contained in:
bordun 2020-03-09 19:12:43 +01:00
parent cee4cb81b7
commit 4f31985930
59 changed files with 1299 additions and 781 deletions

View file

@ -71,221 +71,6 @@ body {
#launcher {
overflow: initial;
body {
background: var(--color-fg);
overflow: auto;
}
.form {
padding:8rem;
padding-top:58rem;
position: relative;
width: 100%;
background: var(--color-fg);
overflow: hidden;
opacity: 0;
transition: opacity .25s;
&.loaded {
opacity: 1;
overflow: auto;
}
}
.item-wrapper {
// margin-bottom:4rem;
label {
min-width:98rem;
}
.input-wrapper {
position: relative;
// height: 28rem;
// overflow: hidden;
// margin: 0;
box-shadow: none;
.clear {
padding:0;
height:26rem;
width: 26rem;
line-height: 26rem;
text-align: center;
position: absolute;
right:1rem;
top:2rem;
background: none;
opacity: .7;
box-shadow: none;
}
input {
padding-right:35rem;
box-shadow: none;
}
input[value="true"] {
color: inherit;
}
input[disabled] {
color:var(--color-accent);
}
.checkbox {
right: 30rem;
&.disabled {
pointer-events: none;
&.on i {
color:var(--color-text-fade);
}
}
}
}
.error-msg, .restart-msg {
transition: height .25s;
height: 0rem;
white-space:normal;
padding: 0 4rem;
margin-left:1rem;
text-transform: none;
}
&.error, &.restart {
.error-msg {
height: 28rem;
line-height: 28rem;
background: rgba(red,0.25)
}
.restart-msg {
height: 28rem;
line-height: 28rem;
background: rgba(orange,0.25)
}
}
}
.header {
position: fixed;
top:8rem;
left:8rem;
right:8rem;
background: var(--color-fg);
border: 1rem solid var(--color-bg);
margin-bottom: -1rem;
color: var(--color-accent);
cursor: default;
z-index: 2;
box-shadow: none;
box-shadow: 0 0 0 1rem var(--color-light) inset,
0 -8rem 0 0 var(--color-fg);
padding: 16rem 15rem 14rem;
#title {
text-transform: uppercase;
letter-spacing: 1rem;
font-size: 12rem;
line-height: 12rem;
}
#version {
opacity: .5;
text-transform: none;
}
#new-version {
color:yellow;
cursor: pointer;
float:right;
}
}
.start {
border: 1rem solid var(--color-bg);
z-index: 1;
margin-top: 8rem;
&:after {
content:"";
position: absolute;
top:0;
left:0;
right: 0;
bottom:0;
box-shadow: 0 0 0 1rem var(--color-light) inset;
pointer-events: none;
}
&.disabled {
opacity: .5;
}
&.started {
color:#fff;
cursor: default;
a {
cursor: pointer;
text-decoration: underline;
}
}
&.started:before {
content:"";
position: absolute;
top:0;
left:0;
right:0;
bottom:0;
background-color: var(--color-accent);
opacity: 0.25;
z-index: -1;
}
}
.save {
float:left;
width:97rem;
border-right: 0;
&:before {
transition: opacity .5s;
content:"";
position: absolute;
top:0;
left:0;
right:0;
bottom:0;
background-color: var(--color-accent);
opacity: 0;
z-index: -1;
}
&.saved:before {
transition: none;
opacity: 0.25;
}
}
.terminal {
margin-top: 8rem;
background: var(--color-bg);
font-family: 'RobotoMono';
text-transform: none;
padding:3rem;
border:2rem solid var(--color-bg);
letter-spacing: normal;
cursor: auto;
flex:1;
height: auto;
min-height: 50rem;
div {
user-select:text;
width: 100%;
white-space: pre-line;
word-wrap: break-word;
text-indent: -10px;
padding-left: 10px;
margin-top: 4rem;
}
.log {
}
.error {
color: rgba(255, 150, 50, 1)
}
}
}

View file

@ -12,3 +12,4 @@
@import 'ui/filebrowser';
@import 'ui/loading';
@import 'ui/toolbar';
@import 'ui/launcher';

View file

@ -102,7 +102,7 @@ $line-height: 30rem;
.separator{
margin: 2rem 1rem;
height: 1rem;
background-color: var(--color-ui-background);
opacity: 0.5;
background-color: var(--color-text);
opacity: 0.1;
}
}

View file

@ -24,7 +24,7 @@ osc-inspector-field {
cursor: help;
}
textarea {
textarea, input {
font-family: mono;
line-height: $field-height - 8rem;

162
src/scss/ui/launcher.scss Normal file
View file

@ -0,0 +1,162 @@
$error: rgb(249, 88, 37);
$warning: rgb(209, 154, 47);
#osc-launcher {
osc-panel-header {
background-color: var(--color-ui-background);
--alpha-fill: .75;
text-align: left;
justify-content: center;
.spacer {
flex: 1;
}
span {
opacity: 0.5;
position: absolute;
right: 12rem;
}
flex-shrink: 0;
}
flex-direction: column;
osc-panel-container.center {
background-color: var(--color-background);
min-height: 0;
osc-panel-content {
padding: 12rem 8rem 8rem;
}
}
osc-panel-content {
overflow-y: auto;
flex: 1;
}
osc-panel-container.bottom {
padding: 12rem 8rem;
&.minimized {
padding: 0;
}
background-color: var(--color-ui-background);
max-height: calc(100% - var(--nav-height));
--color-background: --color-ui-background; // scrollbar
}
.toggle-button {
display: none;
}
}
osc-settings {
// flex: 1;
display: grid;
grid-template-columns: repeat(2, 1fr);
&.disabled {
pointer-events: none;
}
}
osc-settings-field {
display: flex;
flex-direction: row;
margin: 2rem;
line-height: 20rem;
position: relative;
label {
width: 100rem;
text-align: right;
margin-right: 8rem;
position: relative;
cursor: help;
span {
opacity: 0.5;
}
}
input {
appearance: none;
background: var(--color-ui-background);
flex: 1;
padding: 0 4rem;
width: 100rem;
}
&.error label {
color: $error;
opacity: 0.75;
}
&.restart label:after {
content: "";
position: absolute;
top:0;
left:4rem;
right:-4rem;
bottom:0;
background: $warning;
opacity: 0.25;
border-radius: 4rem;
}
}
osc-settings-checkbox, osc-settings-reset, osc-settings-file {
@extend osc-inspector-checkbox;
width: 18rem;
height: 18rem;
background: var(--color-ui-background);
--widget-padding: -1rem;
i {
color: var(--color-text);
opacity: 0.5;
}
&:hover i {
opacity: .75;
}
&.on {
--alpha-fill: 0.5;
i {
color: white;
opacity: 1;
}
}
}
#osc-terminal {
line-height: 18rem;
user-select:text;
cursor: auto;
> div {
margin: 0 12rem 4rem;
}
* {
user-select:text;
cursor: auto;
white-space: pre-wrap;
}
.help {
font-style: italic;
opacity: 0.75;
}
.warning {
color: $warning;
opacity: 0.75;
}
.error {
color: $error;
opacity: 0.75;
}
a {
text-decoration: underline;
cursor: pointer;
}
}

View file

@ -12,17 +12,13 @@ osc-workspace {
flex-direction: row;
overflow: hidden;
background-image: url(../assets/logo.png);
background-size: 80rem;
background-position: center;
background-repeat: no-repeat;
}
osc-panel-container {
position: relative;
display:flex;
flex-direction: column;
&.center {
@ -58,6 +54,24 @@ osc-panel-container {
left: -1rem;
}
&.bottom {
z-index: 2;
min-height: 0;
height: 0;
&:after {
// hover trap to display toggle-button when closed
content: "";
position: absolute;
top: -1rem;
height: 1rem;
left: 0;
right: 0;
z-index: 1;
}
}
.resize-handle {
position: absolute;
top: 0;
@ -71,6 +85,14 @@ osc-panel-container {
&.left {
right: 0;
}
&.bottom {
top:0;
left:0;
right:0;
height: 4rem;
width: auto;
cursor: ns-resize;
}
}
.toggle-button {
@ -120,11 +142,33 @@ osc-panel-container {
}
}
&.bottom {
border-top-left-radius: 25rem;
border-top-right-radius: 25rem;
top: -25rem;
height: 25rem;
width: 50rem;
left: 50%;
margin-left: -25rem;
margin-top: 0;
cursor: pointer;
transform: translateY(25rem);
&:after {
content:"\f107";
margin-top: 2rem;
width: 50rem;
height: 25rem;
line-height: 25rem;
}
}
}
&:hover .toggle-button, .toggle-button:hover {
transition: transform 0.2s ease-out 0s;
transform: translateX(0);
transform: translateX(0) translateY(0);
&:after {
transition: opacity 0.1s ease-in 0.1s;
opacity: 1;
@ -138,6 +182,9 @@ osc-panel-container {
&.right:after {
content:"\f104";
}
&.bottom:after {
content:"\f106";
}
}
&.disabled .toggle-button {
@ -223,3 +270,20 @@ osc-panel-content {
}
#osc-greeting-header {
--alpha-fill: 0.75;
span {
opacity: 0.5;
position: absolute;
right: 12rem;
}
&.hidden {
display: none;
}
}
#osc-container {
background: var(--color-background)
}