Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Visual overhaul #2

Draft
wants to merge 3 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions logic/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -953,6 +953,7 @@ function updateCheatsheetStyling(level) {
n.classList.remove('active');
n.classList.add('punctuation');
}else if(i==0){
n.classList.add('active');
n.classList.add('homeRow');
}else if(i==6){
// all words selected
Expand All @@ -963,6 +964,10 @@ function updateCheatsheetStyling(level) {
n.classList.add('active');
}
}

if(i==1) {
n.classList.remove('homeRow');
}
}

}
Expand Down
41 changes: 35 additions & 6 deletions logic/main.css
Original file line number Diff line number Diff line change
Expand Up @@ -471,6 +471,7 @@ input:checked + .slider:before {
-webkit-box-align: center;
-ms-flex-align: center;
align-items: center;
color: #222222;
background-color: transparent;
border: .2vh solid var(--accent-color);
height: 75%;
Expand All @@ -484,6 +485,26 @@ input:checked + .slider:before {
vertical-align: top;
}

#KeyQ, #KeyA, #KeyZ, #KeyP, #Semicolon, #Slash {
background-color: #80c4c4;
}

#KeyW, #KeyS, #KeyX, #KeyO, #KeyL, #Period {
background-color: #ca80ca;
}

#KeyE, #KeyD, #KeyC, #KeyI, #KeyK, #Comma {
background-color: #80b780;
}

#KeyR, #KeyF, #KeyV, #KeyT, #KeyG, #KeyB {
background-color: #7a93c0;
}

#KeyY, #KeyH, #KeyN, #KeyU, #KeyJ, #KeyM {
background-color: #8080ca;
}

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm thinking, so you want a certain colour for the proper fingering right, and then when active for that level, it would change colour?

If we created classes like finger-01 (through to 10) and assigned them in the layoutDivs file, then we could colour them according to .finger-01 and .finger-01.active right?

Especially if you just want it to be darker, and then when active become light, you could actually just do

.finger-01 {
    background-color: somecolour;
    color: black;
    opacity: 0.5;
}

.active {
    color: white;
    opacity: 1;
}

right?

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That is essentially the goal, yes. That system should also make it easy to change at runtime for layouts that require different fingering like DH.

On a related note, I'd also like to be able to highlight/brighten the keys that are currently being learned (which is currently working now, albeit with a not-so-clean implementation).

.letter {
display: block;
font-size: 2.2vh;
Expand Down Expand Up @@ -527,28 +548,36 @@ input:checked + .slider:before {

.currentLevelKeys {
border-color: var(--tertiary-accent-color);
color: var(--tertiary-accent-color);
color: #ffffff;
opacity: 1;
-webkit-filter: brightness(1.2);
filter: brightness(1.2);
}

.homeRow {
/*.homeRow {
border-color: var(--secondary-accent-color);
color: var(--secondary-accent-color);
opacity: 1;
}
}*/

.restingPosition {
text-decoration: underline;
}

.active {
border-color: var(--accent-color);
color: var(--accent-color);
color: #222222;
opacity: 1;
-webkit-filter: brightness(1.5);
filter: brightness(1.5);
/*-webkit-filter: brightness(1.5);
filter: brightness(1.5);*/
}

.homeRow {
border-color: var(--tertiary-accent-color) !important;
color: #ffffff !important;
opacity: 1 !important;
-webkit-filter: brightness(1.2) !important;
filter: brightness(1.2) !important;
}


Expand Down