New material theme, additional fonts, more complete theme coverage, and bug fixes

This commit is contained in:
Alicia Sykes 2021-06-01 22:44:59 +01:00
parent b60b8db884
commit 9cf720e711
16 changed files with 248 additions and 64 deletions

View File

@ -82,6 +82,7 @@ export default {
@import '@/styles/global-styles.scss';
@import '@/styles/color-palette.scss';
@import '@/styles/color-themes.scss';
@import '@/styles/typography.scss';
body {
background: var(--background);

Binary file not shown.

Binary file not shown.

View File

@ -192,9 +192,9 @@ a.config-button, button.config-button {
div.code-container {
background: var(--config-code-background);
#conf-yaml {
font-family: 'Inconsolata', sans-serif;
.hljs-attr {
#conf-yaml span {
font-family: var(--font-monospace), monospace !important;
&.hljs-attr {
font-weight: bold !important;
}
}
@ -252,7 +252,7 @@ a.hyperlink-wrapper {
display: flex;
flex-direction: column;
padding-top: 2rem;
background: var(--background-darker);
background: var(--config-settings-background);
height: calc(100% - 2rem);
h2 {
margin: 1rem auto;

View File

@ -3,6 +3,7 @@
<prism-editor class="my-editor" v-model="customCss" :highlight="highlighter" line-numbers />
<button class="save-button" @click="save()">Save Changes</button>
<p>Note, you will need to refresh the page for your changes to take effect</p>
<p>To remove all custom styles, delete the contents and hit Save Changes</p>
</div>
</template>
@ -30,7 +31,7 @@ export default {
},
methods: {
validate(css) {
return css.match(/((?:^\s*)([\w#.@*,:\-.:>,*\s]+)\s*{(?:[\s]*)((?:[A-Za-z\- \s]+[:]\s*['"0-9\w .,/()\-!%]+;?)*)*\s*}(?:\s*))/gmi);
return css === '' || css.match(/((?:^\s*)([\w#.@*,:\-.:>,*\s]+)\s*{(?:[\s]*)((?:[A-Za-z\- \s]+[:]\s*['"0-9\w .,/()\-!%]+;?)*)*\s*}(?:\s*))/gmi);
},
save() {
let msg = '';
@ -40,6 +41,7 @@ export default {
localStorage.setItem(localStorageKeys.APP_CONFIG, JSON.stringify(appConfig));
msg = 'Changes saved succesfully';
this.inject(this.customCss);
if (this.customCss === '') setTimeout(() => { location.reload(); }, 1500); // eslint-disable-line no-restricted-globals
} else {
msg = 'Error - Invalid CSS';
}

View File

@ -89,7 +89,7 @@ export default {
display: flex;
flex-direction: column;
padding: 1rem 0;
background: var(--background-darker);
background: var(--config-settings-background);
height: calc(100% - 1rem);
h2 {
margin: 1rem auto;
@ -117,6 +117,7 @@ div.form {
min-width: 24rem;
span {
font-size: 1.2rem;
color: var(--config-settings-color);
}
input {
color: var(--config-settings-color);

View File

@ -12,6 +12,7 @@
<div class="tile-title" :id="`tile-${id}`" >
<span class="text">{{ title }}</span>
<div class="overflow-dots">...</div>
<p class="description">{{ description }}</p>
</div>
<!-- Item Icon -->
<Icon :icon="icon" :url="url" :size="itemSize" :color="color" v-bind:style="customStyles" />
@ -205,7 +206,7 @@ export default {
}
.tile-title {
height: fit-content;
min-height: 1rem;
min-height: 1.2rem;
span.text {
text-align: left;
padding-left: 10%;
@ -228,6 +229,10 @@ export default {
&.size-large {
height: 100px;
}
p.description {
display: none;
}
}
</style>

View File

@ -126,5 +126,19 @@ export default {
@include big-screen-up { grid-template-columns: repeat(5, 1fr); }
}
}
.orientation-horizontal {
display: flex;
flex-direction: column;
.there-are-items {
display: grid;
grid-template-columns: repeat(5, 1fr);
@include phone { grid-template-columns: repeat(2, 1fr); }
@include tablet { grid-template-columns: repeat(4, 1fr); }
@include laptop { grid-template-columns: repeat(6, 1fr); }
@include monitor { grid-template-columns: repeat(8, 1fr); }
@include big-screen { grid-template-columns: repeat(10, 1fr); }
@include big-screen-up { grid-template-columns: repeat(12, 1fr); }
}
}
</style>

View File

@ -3,11 +3,11 @@
<span class="options-label">Icon Size</span>
<div class="display-options">
<IconSmall @click="updateIconSize('small')" v-tooltip="tooltip('Small')"
:class="`layout-icon ${iconSize === 'small' ? 'selected' : ''}`" tabindex="2" />
:class="`layout-icon ${iconSize === 'small' ? 'selected' : ''}`" tabindex="-2" />
<IconMedium @click="updateIconSize('medium')" v-tooltip="tooltip('Medium')"
:class="`layout-icon ${iconSize === 'medium' ? 'selected' : ''}`" tabindex="2" />
:class="`layout-icon ${iconSize === 'medium' ? 'selected' : ''}`" tabindex="-2" />
<IconLarge @click="updateIconSize('large')" v-tooltip="tooltip('Large')"
:class="`layout-icon ${iconSize === 'large' ? 'selected' : ''}`" tabindex="2" />
:class="`layout-icon ${iconSize === 'large' ? 'selected' : ''}`" tabindex="-2" />
</div>
</div>
</template>

View File

@ -3,11 +3,11 @@
<span class="options-label">Layout</span>
<div class="display-options">
<IconDeafault @click="updateDisplayLayout('auto')" v-tooltip="tooltip('Auto')"
:class="`layout-icon ${displayLayout === 'auto' ? 'selected' : ''}`" tabindex="2" />
:class="`layout-icon ${displayLayout === 'auto' ? 'selected' : ''}`" tabindex="-2" />
<IconHorizontal @click="updateDisplayLayout('horizontal')" v-tooltip="tooltip('Horizontal')"
:class="`layout-icon ${displayLayout === 'horizontal' ? 'selected' : ''}`" tabindex="2" />
:class="`layout-icon ${displayLayout === 'horizontal' ? 'selected' : ''}`" tabindex="-2" />
<IconVertical @click="updateDisplayLayout('vertical')" v-tooltip="tooltip('Vertical')"
:class="`layout-icon ${displayLayout === 'vertical' ? 'selected' : ''}`" tabindex="2" />
:class="`layout-icon ${displayLayout === 'vertical' ? 'selected' : ''}`" tabindex="-2" />
</div>
</div>
</template>

View File

@ -5,7 +5,7 @@
id="filter-tiles"
v-model="input"
ref="filter"
placeholder="Start typing to filter tiles..."
placeholder="Start typing to filter..."
v-on:input="userIsTypingSomething"
@keydown.esc="clearFilterInput" />
<i v-if="input.length > 0"

View File

@ -1,11 +1,11 @@
<template>
<div class="theme-selector-section" v-if="themes" >
<span class="theme-label">Themes</span>
<span class="theme-label">Theme</span>
<v-select
:options="themeNames"
v-model="selectedTheme"
class="theme-dropdown"
:tabindex="2"
:tabindex="-2"
/>
</div>
</template>

View File

@ -7,6 +7,8 @@ html[data-theme='callisto'] {
--item-background-hover: #060913;
--item-hover-shadow: 0 1px 3px #00ccb4b3, 0 1px 2px #00ccb4bf;
--primary: #00CCB4;
--font-body: 'Inconsolata', 'Georgia', sans-serif;
--font-headings: 'PTMono', 'Courier New', monospace;
}
html[data-theme='thebe'] {
@ -19,9 +21,11 @@ html[data-theme='thebe'] {
--primary: #9660ec;
--item-group-outer-background: #9660EC
linear-gradient(45deg, #9660ec 2%,#5f60ea 51%,#9660ec 100%);
--font-headings: 'PTMono', 'Courier New', monospace;
}
html[data-theme='dracula'] {
--font-headings: 'Allerta Stencil', sans-serif;
--background: #44475a;
--background-darker: #282a36;
--item-group-background: #282a36;
@ -43,6 +47,7 @@ html[data-theme='bee'] {
--item-background: #1c2636;
--item-group-background: #0b1021;
--nav-link-background-color: #0b1021;
--font-headings: 'Sniglet', cursive;
}
html[data-theme='raspberry-jam'] {
@ -52,6 +57,7 @@ html[data-theme='raspberry-jam'] {
--nav-link-background-color: #0b1021;
--config-code-background: #0b1021;
--config-code-color: #eb2d6c;
--font-headings: 'Sniglet', cursive;
}
html[data-theme='tiger'] {
@ -59,6 +65,7 @@ html[data-theme='tiger'] {
--item-background: #1c2636;
--item-group-background: #0b1021;
--nav-link-background-color: #0b1021;
--font-headings: 'Sniglet', cursive;
}
html[data-theme='matrix-red'] {
@ -67,6 +74,8 @@ html[data-theme='matrix-red'] {
--primary: red;
--outline-color: red;
--curve-factor: 0px;
--font-body: 'Cutive Mono', monospace;
--font-headings: 'VT323', monospace;
}
html[data-theme='matrix'] {
@ -75,6 +84,8 @@ html[data-theme='matrix'] {
--primary: #2bca2b;
--outline-color: #2bca2b;
--curve-factor: 0px;
--font-body: 'Cutive Mono', monospace;
--font-headings: 'VT323', monospace;
}
html[data-theme='hacker-girl'] {
@ -83,6 +94,8 @@ html[data-theme='hacker-girl'] {
--primary: #e435f1;
--outline-color: #e435f1;
--curve-factor: 0px;
--font-body: 'Cutive Mono', monospace;
--font-headings: 'VT323', monospace;
}
html[data-theme='high-contrast-light'] {
@ -94,6 +107,7 @@ html[data-theme='high-contrast-light'] {
--outline-color: #000;
--curve-factor: 0px;
--config-code-color: #000;
--font-headings: 'PTMono', 'Courier New', monospace;
}
html[data-theme='high-contrast-dark'] {
@ -103,6 +117,7 @@ html[data-theme='high-contrast-dark'] {
--primary: #fff;
--outline-color: #fff;
--curve-factor: 0px;
--font-headings: 'PTMono', 'Courier New', monospace;
}
html[data-theme='nord'] {
@ -135,7 +150,9 @@ html[data-theme='material'] {
--background: #e2e1e0;
--background-darker: #01579B;
--settings-background: #01579B;
--item-group-background: #f8f8f8;
--item-group-shadow: none;
--item-group-outer-background: none;
--item-group-background: none;
--item-background: #fff;
--item-background-hover: #fff;
--settings-background: #29B6F6;
@ -151,6 +168,10 @@ html[data-theme='material'] {
--welcome-popup-background: #01579b;
--welcome-popup-text-color: #ffffff;
--config-code-color: #000;
--item-group-heading-text-color-hover: #01579b;
--config-settings-background: #01579b;
--config-settings-color: #fff;
--heading-text-color: #fff;
}
html[data-theme='material-dark'] {
@ -189,7 +210,108 @@ html[data-theme='material-dark'] {
}
}
html[data-theme='material-2'] {
--font-body: 'Roboto', serif;
--font-headings: 'Francois One', serif;
--primary: #363636;
--background: #e2e1e0;
--background-darker: #4285f4;
--item-group-outer-background: none;
--item-group-shadow: none;
--item-group-background: none;
--item-background: #fff;
--item-background-hover: #fff;
--item-shadow: 0 1px 3px #0000001f, 0 1px 2px #0000003d;
--item-hover-shadow: 0 1px 4px #00000029, 0 2px 4px #0000002a;
--item-text-color: #363636;
--item-group-heading-text-color-hover: #363636;
--item-icon-transform-hover: none;
--nav-link-border-color-hover: #1341a6;
--settings-text-color: #363636;
--config-code-color: #363636;
--heading-text-color: #fff;
--curve-factor: 4px;
--curve-factor-navbar: 8px;
--search-container-background: linear-gradient(to bottom, #3367d6 0%,#4285f4 5%);
header {
background: #3367d6;
color: #fff;
.page-titles span.subtitle {
text-shadow: none;
}
}
footer {
opacity: 1;
color: #fff;
}
section.filter-container form label {
color: var(--primary);
}
.item:not(.size-small) {
display: flex;
flex-direction: row-reverse;
justify-content: flex-end;
text-align: left;
overflow: hidden;
align-items: end;
width: 15rem;
min-width: 15rem;
max-height: 4rem;
margin: 0.2rem;
.overflow-dots {
display: none;
}
img {
padding: 0.1rem 0.25rem;
}
.tile-title {
height: auto;
padding: 0.1rem 0.25rem;
span.text {
position: relative;
font-weight: bold;
font-size: 1.1rem;
width: 100%;
}
p.description {
display: block;
margin: 0;
white-space: pre-wrap;
}
}
}
.item.size-large {
width: 18rem;
min-width: 18rem;
max-height: 5rem;
margin: 0.4rem;
img {
padding: 0.2rem 0.5rem;
}
}
.tooltip {
display: none !important;
}
.orientation-horizontal {
display: flex;
flex-direction: column;
.there-are-items {
display: grid;
grid-template-columns: repeat(5, 1fr);
@include phone { grid-template-columns: repeat(1, 1fr); }
@include tablet { grid-template-columns: repeat(2, 1fr); }
@include laptop { grid-template-columns: repeat(3, 1fr); }
@include monitor { grid-template-columns: repeat(4, 1fr); }
@include big-screen { grid-template-columns: repeat(5, 1fr); }
@include big-screen-up { grid-template-columns: repeat(6, 1fr); }
}
}
}
html[data-theme='colorful'] {
--font-headings: 'Podkova', monospace;
--primary: #e8eae1;
--background: #0b1021;
--item-background: #05070e;
@ -215,33 +337,19 @@ html[data-theme='colorful'] {
svg path { fill: #05070e; }
i.fas, i.fab, i.far, i.fal, i.fad { color: #05070e; }
}
h1, h2, h3, h4 {
font-weight: normal;
}
}
html[data-theme='minimal-light'], html[data-theme='minimal-dark'] {
.item-group-container:not(.item-size-small):not(.orientation-vertical) {
display: flex;
flex-direction: column;
.there-are-items {
display: grid;
grid-template-columns: repeat(5, 1fr);
@include phone { grid-template-columns: repeat(2, 1fr); }
@include tablet { grid-template-columns: repeat(4, 1fr); }
@include laptop { grid-template-columns: repeat(6, 1fr); }
@include monitor { grid-template-columns: repeat(8, 1fr); }
@include big-screen { grid-template-columns: repeat(10, 1fr); }
@include big-screen-up { grid-template-columns: repeat(12, 1fr); }
}
.collapsable {
border-bottom: 1px dashed #ffffff38;
border-radius: 0;
}
}
--font-body: 'PTMono-Regular', 'Courier New', monospace;
--font-headings: 'PTMono-Regular', 'Courier New', monospace;
label.lbl-toggle h3 {
font-size: 1.8rem;
}
.tile-title span.text {
font-size: 1.2rem;
font-size: 1.1rem;
font-weight: bold;
}
@ -261,7 +369,10 @@ html[data-theme='minimal-light'], html[data-theme='minimal-dark'] {
box-shadow: none;
}
}
.item-group-container.orientation-horizontal .collapsable {
border-bottom: 1px dashed #ffffff38;
border-radius: 0;
}
}
html[data-theme='minimal-light'] {
@ -296,12 +407,12 @@ html[data-theme='minimal-light'] {
html[data-theme='minimal-dark'] {
--primary: #a5a5a5;
--background: #14171e;
--background-darker: #000;
--background-darker: #090b0e;
--item-group-outer-background: none;
--item-group-shadow: none;
--item-group-background: none;
--item-background: none;
--item-background-hover: #14171e;
--item-background-hover: #090b0e;
--item-shadow: none;
--item-hover-shadow: none;
--item-text-color: #fff;

View File

@ -1,25 +1,14 @@
@import '@/styles/style-helpers.scss';
@font-face {
font-family: 'Inconsolata';
src: url('./assets/fonts/Inconsolata-Light.ttf');
}
html {
margin: 0;
padding: 0;
transition: all 1s;
margin-top: -3px;
@extend .scroll-bar;
}
/* Default app font face */
body, div, p, a, span, label, input, button {
font-family: 'Inconsolata', sans-serif;
}
/* Headings font face */
h1, h2, h3, h4, h5 {
font-family: 'Inconsolata', sans-serif;
margin: 0;
padding: 0;
transition: all 1s;
margin-top: -3px;
@extend .scroll-bar;
box-sizing: border-box;
input[type=button], button, a {
cursor: pointer;
}
}

View File

@ -0,0 +1,60 @@
@font-face {
font-family: 'Inconsolata';
src: url('./assets/fonts/Inconsolata-Light.ttf');
}
@font-face {
font-family: 'Raleway';
src: url('./assets/fonts/Raleway-Variable.ttf');
}
@font-face {
font-family: 'PTMono';
src: url('./assets/fonts/PTMono-Regular.ttf');
}
html {
--font-body: 'Raleway', 'Trebuchet MS', sans-serif;
--font-headings: 'Inconsolata', 'Georgia', sans-serif;
--font-monospace: 'PTMono', 'Courier New', monospace;
font-size: 1rem;
font-weight: normal;
text-decoration: none;
background: transparent;
vertical-align: baseline;
/* Default app font face */
body, div, p, a, span, label, input, button {
font-family: var(--font-body);
}
/* Headings font face */
h1, h2, h3, h4, h5 {
font-family: var(--font-headings);
}
/* Monospace, for code and raw data output */
code, pre, pre *, .jsoneditor *, .mono * {
font-family: var(--font-monospace);
font-weight: normal;
}
}
/* Fonts used for external themes */
/* Material Design Themes */
@import url('https://fonts.googleapis.com/css2?family=Francois+One&family=Roboto:wght@300&display=swap');
/* Matrix, Hacker, Nerd Themes */
@import url('https://fonts.googleapis.com/css2?family=Cutive+Mono&family=VT323&display=swap');
/* Colourful */
@import url('https://fonts.googleapis.com/css2?family=Podkova:wght@500&display=swap');
/* Dracula */
@import url('https://fonts.googleapis.com/css2?family=Allerta+Stencil&display=swap');
/* Jam */
@import url('https://fonts.googleapis.com/css2?family=Sniglet&display=swap');

View File

@ -18,18 +18,19 @@ module.exports = {
'nord-frost',
'callisto',
'thebe',
'dracula',
'material',
'material-dark',
'dracula',
'minimal-dark',
'minimal-light',
'material-2',
'colorful',
'matrix',
'matrix-red',
'hacker-girl',
'bee',
'raspberry-jam',
'tiger',
'colorful',
'minimal-dark',
'minimal-light',
'high-contrast-dark',
'high-contrast-light',
],