mirror of
https://github.com/ZetaKebab/japanese-conjugation-drill.git
synced 2025-01-14 22:08:44 +00:00
581 lines
9.0 KiB
CSS
581 lines
9.0 KiB
CSS
body, input {
|
|
font-family: Amaranth, sans-serif;
|
|
background: #eee;
|
|
|
|
--other: #4A2067;
|
|
--neutral-dark: #441f00;
|
|
--incorrect: #992a2a;
|
|
--correct: #217b21;
|
|
--neutral: #995c2a;
|
|
--question-furigana: white;
|
|
--input-background: white;
|
|
--input-shadow: #888;
|
|
--input-color: white;
|
|
--shake-level: 6px;
|
|
}
|
|
|
|
/* #proceed svg {
|
|
|
|
display: inline-block;
|
|
width: 48px;
|
|
height: 48px;
|
|
}
|
|
|
|
#proceed button {
|
|
color: var(--input-color);
|
|
outline-width: 0;
|
|
border: none;
|
|
padding: 12px;
|
|
background: none;
|
|
} */
|
|
|
|
.questionOuter {
|
|
background: var(--other);
|
|
}
|
|
|
|
#question {
|
|
padding-top: 40px;
|
|
padding-bottom: 40px;
|
|
font-size: 20px;
|
|
text-shadow: 2px 2px 4px var(--neutral-dark);
|
|
color: white;
|
|
}
|
|
|
|
#questionFirstHalf,
|
|
#questionSecondHalf {
|
|
margin-left: auto;
|
|
margin-right: auto;
|
|
display: table;
|
|
}
|
|
|
|
#answer {
|
|
font-size: 16px;
|
|
}
|
|
|
|
#responseButton {
|
|
font-size: 16px;
|
|
line-height: 16px;
|
|
}
|
|
|
|
/* Responsive text size */
|
|
|
|
@media (max-width: 575px) {
|
|
.navbar-brand {
|
|
font-size: 1.15rem;
|
|
}
|
|
}
|
|
|
|
/* Small devices (landscape phones, 576px and up) */
|
|
@media (min-width: 576px) {
|
|
|
|
#question {
|
|
font-size: 32px;
|
|
}
|
|
|
|
#answer, .correct, .incorrect {
|
|
font-size: 24px;
|
|
}
|
|
|
|
#responseButton {
|
|
font-size: 24px;
|
|
line-height: 24px;
|
|
}
|
|
}
|
|
|
|
/* Medium devices (tablets, 768px and up) */
|
|
@media (min-width: 768px) {
|
|
|
|
#question {
|
|
font-size: 40px;
|
|
}
|
|
|
|
#answer, .correct, .incorrect {
|
|
font-size: 30px;
|
|
}
|
|
|
|
#responseButton {
|
|
font-size: 30px;
|
|
line-height: 30px;
|
|
}
|
|
}
|
|
|
|
/* Large devices (desktops, 992px and up) */
|
|
@media (min-width: 992px) {
|
|
|
|
#question {
|
|
font-size: 40px;
|
|
}
|
|
|
|
#answer, .correct, .incorrect {
|
|
font-size: 30px;
|
|
}
|
|
|
|
#responseButton {
|
|
font-size: 30px;
|
|
line-height: 30px;
|
|
}
|
|
}
|
|
|
|
/* Extra large devices (large desktops, 1200px and up) */
|
|
@media (min-width: 1200px) {
|
|
|
|
#question {
|
|
font-size: 40px;
|
|
}
|
|
|
|
#answer, .correct, .incorrect {
|
|
font-size: 30px;
|
|
}
|
|
|
|
#responseButton {
|
|
font-size: 30px;
|
|
line-height: 30px;
|
|
}
|
|
}
|
|
|
|
/*
|
|
#explanation {
|
|
width: 960px;
|
|
margin-left: auto;
|
|
margin-right: auto;
|
|
}
|
|
*/
|
|
|
|
#inputArea {
|
|
background: var(--input-background);
|
|
}
|
|
|
|
#inputArea, .correct, .incorrect {
|
|
box-shadow: 2px 2px 4px 0px var(--input-shadow);
|
|
width: calc(100vw - 32px);
|
|
margin-left: auto;
|
|
margin-right: auto;
|
|
margin-top: 16px;
|
|
margin-bottom: 16px;
|
|
}
|
|
|
|
#answer {
|
|
background: var(--input-background);
|
|
width: 100%;
|
|
border: 0;
|
|
padding-top: 12px;
|
|
padding-bottom: 12px;
|
|
text-align: center;
|
|
}
|
|
|
|
#answer, .correct, .incorrect {
|
|
height: 54px;
|
|
}
|
|
|
|
#answer:focus {
|
|
outline-width: 0;
|
|
}
|
|
|
|
/*
|
|
|
|
#message {
|
|
margin-top: 10px;
|
|
width: 100%;
|
|
}
|
|
|
|
#message > div {
|
|
padding-top: 4px;
|
|
padding-bottom: 4px;
|
|
text-align: center;
|
|
}
|
|
|
|
*/
|
|
.correct,
|
|
.incorrect {
|
|
padding-top: 12px;
|
|
padding-bottom: 12px;
|
|
text-align: center;
|
|
color: var(--input-color);
|
|
}
|
|
|
|
.correct {
|
|
background-color: var(--correct);
|
|
}
|
|
|
|
.incorrect {
|
|
background-color: var(--incorrect);
|
|
}
|
|
|
|
#responseButton {
|
|
|
|
border: none;
|
|
box-shadow: 2px 2px 4px 0px var(--input-shadow);
|
|
width: calc(100vw - 32px);
|
|
margin-left: auto;
|
|
margin-right: auto;
|
|
|
|
padding-top: 12px;
|
|
padding-bottom: 12px;
|
|
display: table;
|
|
|
|
color: var(--input-color);
|
|
}
|
|
|
|
/*
|
|
div#history,
|
|
div#explanation {
|
|
margin-left: auto;
|
|
margin-right: auto;
|
|
display: table;
|
|
}
|
|
|
|
table.syllabary {
|
|
border-collapse: collapse;
|
|
}
|
|
|
|
table.syllabary td {
|
|
padding: 12px;
|
|
font-size: 14px;
|
|
color: gray;
|
|
border: 1px solid gray;
|
|
text-align: center;
|
|
width: 32px;
|
|
height: 32px;
|
|
}
|
|
|
|
table.syllabary td div:first-child {
|
|
color: black;
|
|
font-size: 24px;
|
|
}
|
|
|
|
table.syllabary td.empty {
|
|
background: #eee;
|
|
}
|
|
|
|
table.word td {
|
|
font-size: 36px;
|
|
color: black;
|
|
text-align: center;
|
|
}
|
|
|
|
table.word td div:first-child {
|
|
margin: 0;
|
|
color: #aaa;
|
|
font-size: 18px;
|
|
font-weight: bold;
|
|
}
|
|
|
|
table.chart span.change,
|
|
table.word span.change {
|
|
color: #f06060;
|
|
}
|
|
*/
|
|
|
|
.answer-correct {
|
|
color: red;
|
|
}
|
|
|
|
.answer-wrong {
|
|
color: blue;
|
|
}
|
|
|
|
/*
|
|
div#history table {
|
|
border-collapse: collapse;
|
|
}
|
|
|
|
div#history table th,
|
|
div#history table td {
|
|
padding: 10px 16px 10px 16px;
|
|
border: 1px solid gray;
|
|
}:
|
|
|
|
div#history table th {
|
|
text-align: left;
|
|
}
|
|
|
|
div.options > * {
|
|
display: inline-block;
|
|
vertical-align: top;
|
|
margin: 20px;
|
|
}
|
|
|
|
div#splash > *,
|
|
div#scoreSection > * {
|
|
margin-left: auto;
|
|
margin-right: auto;
|
|
display: table;
|
|
margin-bottom: 12px;
|
|
}
|
|
*/
|
|
|
|
input#numQuestions {
|
|
width: 60px;
|
|
}
|
|
|
|
div.options ul {
|
|
list-style-type: none;
|
|
margin: 0;
|
|
padding-left: 16px;
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
/* Tooltip from http://jsfiddle.net/AndreaLigios/jtLbpy62/ */
|
|
|
|
[tooltip]:before {
|
|
/* needed - do not touch */
|
|
content: attr(tooltip);
|
|
position: absolute;
|
|
opacity: 0;
|
|
|
|
/* customizable */
|
|
transition: all 0.15s ease;
|
|
color: #333;
|
|
font-size: 12px;
|
|
}
|
|
|
|
[tooltip]:hover:before,
|
|
.furiganaAlways #question [tooltip]:before {
|
|
/* needed - do not touch */
|
|
opacity: 1;
|
|
|
|
/* customizable */
|
|
margin-top: -12px;
|
|
}
|
|
|
|
[tooltip]:not([tooltip-persistent]):before {
|
|
pointer-events: none;
|
|
}
|
|
|
|
/* Custom positions for furigana */
|
|
|
|
.tooltip-w1[tooltip]:before { font-size: 8px; margin-left: 4px; }
|
|
.tooltip-w2[tooltip]:before { font-size: 8px; margin-left: 0px; }
|
|
.tooltip-w3[tooltip]:before { font-size: 8px; margin-left: -4px; }
|
|
|
|
.tooltip-w1[tooltip]:hover:before,
|
|
.tooltip-w2[tooltip]:hover:before,
|
|
.tooltip-w3[tooltip]:hover:before { margin-top: -10px; }
|
|
|
|
#question .tooltip-w1[tooltip]:before { color: var(--question-furigana); font-size: 12px; margin-left: 14px; }
|
|
#question .tooltip-w2[tooltip]:before { color: var(--question-furigana); font-size: 12px; margin-left: 8px; }
|
|
#question .tooltip-w3[tooltip]:before { color: var(--question-furigana); font-size: 12px; margin-left: 2px; }
|
|
|
|
#question .tooltip-w1[tooltip]:hover:before, .furiganaAlways #question .tooltip-w1[tooltip]:before,
|
|
#question .tooltip-w2[tooltip]:hover:before, .furiganaAlways #question .tooltip-w2[tooltip]:before,
|
|
#question .tooltip-w3[tooltip]:hover:before, .furiganaAlways #question .tooltip-w3[tooltip]:before {
|
|
color: var(--question-furigana);
|
|
margin-top: -12px;
|
|
}
|
|
|
|
/*
|
|
div#explanation p span {
|
|
}
|
|
|
|
|
|
.highlight {
|
|
font-style: italic;
|
|
}
|
|
|
|
.horizontal-transform {
|
|
text-align: center;
|
|
}
|
|
|
|
.horizontal-transform > * {
|
|
display: inline-block;
|
|
vertical-align: middle;
|
|
}
|
|
|
|
.transform-arrow {
|
|
font-size: 32px;
|
|
color: #888;
|
|
margin: 16px;
|
|
}
|
|
|
|
|
|
div.conjugation-chart {
|
|
border: 2px solid gray;
|
|
border-radius: 32px;
|
|
padding: 24px;
|
|
background: #fff8f0;
|
|
|
|
margin-left: auto;
|
|
margin-right: auto;
|
|
display: table;
|
|
}
|
|
|
|
div.conjugation-chart h2 {
|
|
font-size: 28px;
|
|
}
|
|
|
|
div.conjugation-chart > * {
|
|
text-align: center;
|
|
}
|
|
|
|
table.chart + table.chart {
|
|
margin-left: 32px;
|
|
}
|
|
|
|
table.chart {
|
|
border-collapse: collapse;
|
|
}
|
|
|
|
table.chart td {
|
|
border: 1px solid gray;
|
|
padding-left: 16px;
|
|
padding-right: 16px;
|
|
background: white;
|
|
text-align: left;
|
|
}
|
|
|
|
table.chart td.break {
|
|
height: 1em;
|
|
border: 0;
|
|
background: inherit;
|
|
}
|
|
|
|
table.chart th {
|
|
border: 1px solid gray;
|
|
background: gray;
|
|
color: white;
|
|
}
|
|
|
|
table.chart td.title {
|
|
border: 0;
|
|
background: inherit;
|
|
font-size: 22px;
|
|
text-align: center;
|
|
}
|
|
|
|
div.horiz > * {
|
|
display: inline-block;
|
|
vertical-align: top;
|
|
}
|
|
|
|
.rules table.word td {
|
|
font-size: 24px;
|
|
color: black;
|
|
text-align: center;
|
|
}
|
|
|
|
.rules table.word td div:first-child {
|
|
margin: 0;
|
|
color: #aaa;
|
|
font-size: 12px;
|
|
}
|
|
|
|
.rules table.chart span.change {
|
|
color: black;
|
|
}
|
|
|
|
.rules table.word span.change {
|
|
color: #f06060;
|
|
}
|
|
|
|
.rules .transform-arrow {
|
|
font-size: 16px;
|
|
color: #888;
|
|
margin: 16px;
|
|
}
|
|
|
|
.brace {
|
|
fill: none;
|
|
fill-rule: evenodd;
|
|
stroke: #ccc;
|
|
stroke-width: 0.5px;
|
|
stroke-linecap: butt;
|
|
stroke-linejoin: miter;
|
|
stroke-opacity: 1;
|
|
}
|
|
|
|
.arrow {
|
|
margin-left: 16px;
|
|
margin-right: 16px;
|
|
}
|
|
|
|
*/
|
|
.tag {
|
|
display: inline-block;
|
|
border-radius: 3px;
|
|
background: orange;
|
|
padding-left: 6px;
|
|
padding-right: 6px;
|
|
padding-top: 2px;
|
|
padding-bottom: 2px;
|
|
}
|
|
/*
|
|
|
|
.options li {
|
|
height: 24px;
|
|
}
|
|
|
|
*/
|
|
|
|
.specials {
|
|
font-weight: bold;
|
|
margin-top: 10px;
|
|
margin-bottom: 10px;
|
|
}
|
|
|
|
h2, h4 {
|
|
font-weight: bold;
|
|
}
|
|
|
|
/* .options h4 {
|
|
} */
|
|
/*
|
|
.explain-answer-as-list li {
|
|
list-style-type: none;
|
|
}
|
|
|
|
.explain-answer-as-list {
|
|
padding-left: 24px;
|
|
}
|
|
|
|
.centre {
|
|
display: table;
|
|
margin: 0 auto;
|
|
}
|
|
|
|
*/
|
|
|
|
@media (max-width: 420px) {
|
|
|
|
#splash h2 {
|
|
font-size: 1.3em;
|
|
margin-bottom: 1.0em
|
|
}
|
|
}
|
|
|
|
@keyframes shake {
|
|
0% { transform: translate(0px, 0px); }
|
|
12.5% { transform: translate(calc(0px - var(--shake-level)), 0px); }
|
|
25% { transform: translate(var(--shake-level), 0px); }
|
|
37.5% { transform: translate(calc(0px - var(--shake-level)), 0px); }
|
|
50% { transform: translate(var(--shake-level), 0px); }
|
|
62.5% { transform: translate(calc(0px - var(--shake-level)), 0px); }
|
|
75% { transform: translate(var(--shake-level), 0px); }
|
|
87.5% { transform: translate(calc(0px - var(--shake-level)), 0px); }
|
|
100% { transform: translate(0px, 0px); }
|
|
}
|
|
|
|
.shake {
|
|
animation: shake 0.75s;
|
|
animation-iteration-count: 1;
|
|
}
|
|
|
|
dl.questionOptions {
|
|
display: table;
|
|
}
|
|
|
|
dl.questionOptions > div {
|
|
display: table-row;
|
|
}
|
|
|
|
dl.questionOptions dt {
|
|
font-weight: 400;
|
|
display: table-cell;
|
|
}
|
|
|
|
dl.questionOptions dd {
|
|
display: table-cell;
|
|
}
|