Add accordion and fix minor issues (#742)
* Add docs v0.0.1 * Add icon size warning * Fix sourcenover caution * Fix semver descriptions * Filters fix * Quickfix quickstart * Add icon warning v2 * Fix typos * Add NovelItem * Update plugins host * Update plugins host * Remove unnecesarry .js and .dist * Update plugins host * Add host.ps1 * Fix readme.txt * Fix READNE.txt, again * Remove .js and .dist * Add accordion * Working pagination * readme update with ost * Add linux/windows hosting functions * Add tswatch * Fix fetch function * Change plugin versions * Fix chrome * Fix workflows * Fix search not showing results * remove unnecesarry code * Revert novelupdates changes * Reverted NobleMTL instead of novelupdates, fixing that * Revert nobleMTL to e346c7d0 * WTF NobleMTL?
This commit is contained in:
@@ -0,0 +1,72 @@
|
||||
:root {
|
||||
--accordion-animation: 0.4s ease;
|
||||
}
|
||||
|
||||
/** Accordion header button styles */
|
||||
accordion-box {
|
||||
display: grid;
|
||||
margin: 0.2rem 1rem;
|
||||
padding: 0.5rem;
|
||||
background-color: aliceblue;
|
||||
&:not([collapsed]) {
|
||||
accordion-header {
|
||||
button {
|
||||
color: #000;
|
||||
background-color: white;
|
||||
}
|
||||
|
||||
button:after {
|
||||
background-image: var(--mdb-accordion-btn-active-icon);
|
||||
transform: var(--mdb-accordion-btn-icon-transform);
|
||||
}
|
||||
}
|
||||
accordion-content {
|
||||
grid-template-rows: 1fr;
|
||||
}
|
||||
}
|
||||
accordion-content {
|
||||
display: grid;
|
||||
grid-template-rows: 0fr;
|
||||
padding-inline: 5px;
|
||||
transition: grid-template-rows var(--accordion-animation);
|
||||
.accordion-animation-content {
|
||||
overflow-y: hidden;
|
||||
}
|
||||
}
|
||||
accordion-header {
|
||||
display: block;
|
||||
button {
|
||||
font-weight: bolder;
|
||||
position: relative;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
width: 100%;
|
||||
padding: 5px;
|
||||
font-size: 1rem;
|
||||
text-align: left;
|
||||
background-color: white;
|
||||
color: #aaaa;
|
||||
border: 0;
|
||||
border-radius: 0;
|
||||
overflow-anchor: none;
|
||||
&:after {
|
||||
flex-shrink: 0;
|
||||
width: var(--mdb-accordion-btn-icon-width);
|
||||
height: var(--mdb-accordion-btn-icon-width);
|
||||
margin-left: auto;
|
||||
content: "";
|
||||
background-image: var(--mdb-accordion-btn-icon);
|
||||
background-repeat: no-repeat;
|
||||
background-size: var(--mdb-accordion-btn-icon-width);
|
||||
transition: var(--mdb-accordion-btn-icon-transition);
|
||||
}
|
||||
&:hover {
|
||||
z-index: 2;
|
||||
}
|
||||
&:focus {
|
||||
z-index: 3;
|
||||
box-shadow: var(--mdb-accordion-btn-focus-box-shadow);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -12,6 +12,33 @@
|
||||
.darkmode {
|
||||
color-scheme: dark;
|
||||
background-color: var(--main-bg);
|
||||
|
||||
main-accordion {
|
||||
accordion-box {
|
||||
&:not([collapsed]) {
|
||||
accordion-header {
|
||||
button {
|
||||
color: white;
|
||||
}
|
||||
}
|
||||
}
|
||||
accordion-header {
|
||||
button {
|
||||
color: #cccc;
|
||||
background-color: var(--main-bg);
|
||||
}
|
||||
}
|
||||
background-color: var(--highlight-bg);
|
||||
color: var(--text-color);
|
||||
input {
|
||||
&[type="text"] {
|
||||
background-color: var(--main-bg);
|
||||
border-color: var(--dark-border-color);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.headerinfo span[contenteditable="true"] {
|
||||
border: 1px solid #fff2;
|
||||
}
|
||||
@@ -34,6 +61,15 @@
|
||||
color: var(--text-color);
|
||||
border-color: var(--dark-border-color);
|
||||
}
|
||||
#search-results {
|
||||
color: var(--text-color);
|
||||
background-color: transparent;
|
||||
button {
|
||||
background-color: var(--hr-color);
|
||||
color: var(--dark-label-color);
|
||||
font-weight: bolder;
|
||||
}
|
||||
}
|
||||
}
|
||||
button.btn-secondary {
|
||||
background-color: var(--btn-secondary-color);
|
||||
@@ -41,15 +77,6 @@
|
||||
box-shadow: none;
|
||||
}
|
||||
}
|
||||
#search-results {
|
||||
color: var(--text-color);
|
||||
background-color: transparent;
|
||||
button {
|
||||
background-color: var(--hr-color);
|
||||
color: var(--dark-label-color);
|
||||
font-weight: bolder;
|
||||
}
|
||||
}
|
||||
#darkstyletoggle {
|
||||
color: var(--dark-label-color);
|
||||
}
|
||||
@@ -80,16 +107,6 @@
|
||||
background-color: var(--main-bg);
|
||||
border-color: var(--dark-border-color);
|
||||
}
|
||||
.test-wrapper {
|
||||
background-color: var(--highlight-bg);
|
||||
color: var(--text-color);
|
||||
input {
|
||||
&[type="text"] {
|
||||
background-color: var(--main-bg);
|
||||
border-color: var(--dark-border-color);
|
||||
}
|
||||
}
|
||||
}
|
||||
.modal-content {
|
||||
background-color: var(--main-bg);
|
||||
.close {
|
||||
|
||||
+307
-295
@@ -6,6 +6,10 @@
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
#loadedplugin {
|
||||
margin-left: 5px;
|
||||
}
|
||||
|
||||
.navbar {
|
||||
width: 100vw;
|
||||
align-items: center;
|
||||
@@ -18,25 +22,312 @@
|
||||
button.btn-secondary {
|
||||
padding-inline: 5px;
|
||||
}
|
||||
}
|
||||
|
||||
#search-results {
|
||||
position: absolute;
|
||||
top: calc(100% - 0.5rem);
|
||||
width: fit-content;
|
||||
max-height: 500%;
|
||||
overflow-y: scroll;
|
||||
overflow-x: hidden;
|
||||
padding: 0.375rem 0;
|
||||
border-radius: 5px;
|
||||
background-color: transparent;
|
||||
z-index: 3;
|
||||
button {
|
||||
background-color: white;
|
||||
text-transform: capitalize;
|
||||
.input-group {
|
||||
width: 20rem;
|
||||
}
|
||||
#search-results {
|
||||
display: none;
|
||||
position: absolute;
|
||||
top: calc(100% - 0.5rem);
|
||||
width: fit-content;
|
||||
max-height: 500%;
|
||||
overflow-y: scroll;
|
||||
overflow-x: hidden;
|
||||
padding: 0.375rem 0;
|
||||
border-radius: 5px;
|
||||
background-color: transparent;
|
||||
z-index: 3;
|
||||
button {
|
||||
background-color: white;
|
||||
text-transform: capitalize;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.btn {
|
||||
font-size: 0.75rem;
|
||||
padding: 0.25rem 0.25rem;
|
||||
&.disabled,
|
||||
&:disabled {
|
||||
opacity: 1;
|
||||
}
|
||||
}
|
||||
|
||||
@keyframes spinner-border {
|
||||
100% {
|
||||
-webkit-transform: rotate(360deg);
|
||||
transform: rotate(360deg);
|
||||
}
|
||||
}
|
||||
|
||||
.inline-container {
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
#popularNovels {
|
||||
.page-select {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
|
||||
#searchNovels {
|
||||
.page-select {
|
||||
display: none;
|
||||
}
|
||||
.searchbar {
|
||||
width: fit-content;
|
||||
display: inline-block;
|
||||
}
|
||||
}
|
||||
.page-the-same-warn {
|
||||
color: orange;
|
||||
}
|
||||
|
||||
.fetch-btn button,
|
||||
#filters-btn {
|
||||
&:disabled {
|
||||
background-color: gray;
|
||||
box-shadow: none;
|
||||
}
|
||||
}
|
||||
|
||||
.spinner-border {
|
||||
display: none;
|
||||
width: 1rem;
|
||||
height: 1rem;
|
||||
vertical-align: text-bottom;
|
||||
border: 0.25em solid currentColor;
|
||||
border-right-color: transparent;
|
||||
border-radius: 50%;
|
||||
-webkit-animation: spinner-border 0.75s linear infinite;
|
||||
animation: spinner-border 0.75s linear infinite;
|
||||
}
|
||||
|
||||
.headerinfo {
|
||||
margin-bottom: 5px;
|
||||
span[contenteditable="true"] {
|
||||
border: 1px solid black;
|
||||
padding: 3px 10px;
|
||||
display: inline;
|
||||
}
|
||||
#headersnotcopied,
|
||||
#headerscopied {
|
||||
font-size: 1.3rem;
|
||||
}
|
||||
|
||||
#headersnotcopied {
|
||||
color: red;
|
||||
display: none;
|
||||
}
|
||||
|
||||
#headerscopied {
|
||||
color: green;
|
||||
display: none;
|
||||
}
|
||||
|
||||
.headereditbutton {
|
||||
margin-left: 5px;
|
||||
border: none;
|
||||
padding-inline: 5px;
|
||||
}
|
||||
}
|
||||
|
||||
.novel-list {
|
||||
display: grid;
|
||||
overflow-x: scroll;
|
||||
width: 100%;
|
||||
margin-top: 5px;
|
||||
padding-bottom: 15px;
|
||||
padding-left: 5px;
|
||||
grid-auto-flow: column;
|
||||
gap: 5px;
|
||||
align-items: center;
|
||||
.error {
|
||||
color: red;
|
||||
grid-row: 2;
|
||||
}
|
||||
}
|
||||
.novel-item {
|
||||
display: grid;
|
||||
grid-auto-flow: column;
|
||||
display: grid;
|
||||
gap: 5px;
|
||||
}
|
||||
.novel-info {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
.novel-img {
|
||||
display: grid;
|
||||
width: fit-content;
|
||||
justify-content: center;
|
||||
align-content: center;
|
||||
img {
|
||||
max-width: 300px;
|
||||
max-height: 300px;
|
||||
}
|
||||
}
|
||||
/* comment */
|
||||
.info-item {
|
||||
display: grid;
|
||||
min-width: 300px;
|
||||
grid-auto-columns: min-content auto 50px;
|
||||
margin-top: 5px;
|
||||
grid-auto-flow: column;
|
||||
div {
|
||||
display: grid;
|
||||
align-items: center;
|
||||
}
|
||||
}
|
||||
.parse-novel-btn {
|
||||
width: 85%;
|
||||
margin-inline: auto;
|
||||
margin-top: 5px;
|
||||
}
|
||||
|
||||
.parsed-novel-info {
|
||||
display: grid;
|
||||
grid-auto-flow: column;
|
||||
gap: 20px;
|
||||
grid-auto-columns: 1.5fr 1fr;
|
||||
}
|
||||
|
||||
.chapter-list-container {
|
||||
max-height: 400px;
|
||||
overflow-y: scroll;
|
||||
}
|
||||
|
||||
.chapter-list {
|
||||
column-count: 2;
|
||||
}
|
||||
|
||||
.chapter-item {
|
||||
margin-top: 5px;
|
||||
break-inside: avoid;
|
||||
display: grid;
|
||||
grid-template-areas: "name btn1 btn2" "date btn1 btn2";
|
||||
}
|
||||
|
||||
.ci-topleft {
|
||||
grid-area: name;
|
||||
}
|
||||
|
||||
.ci-bottomleft {
|
||||
grid-area: date;
|
||||
}
|
||||
|
||||
.ci-btn1 {
|
||||
grid-area: btn1;
|
||||
}
|
||||
|
||||
.ci-btn2 {
|
||||
grid-area: btn2;
|
||||
}
|
||||
|
||||
.select-option-text {
|
||||
padding-left: 1rem;
|
||||
}
|
||||
|
||||
/* Slider checkbox */
|
||||
|
||||
.inline-slider-checkbox {
|
||||
display: inline;
|
||||
}
|
||||
|
||||
.inline-slider-checkbox,
|
||||
.slider-checkbox {
|
||||
--ball-width: 15px;
|
||||
--box-margin: 5px;
|
||||
--box-width: calc(2 * var(--ball-width) + var(--box-margin));
|
||||
input {
|
||||
display: none;
|
||||
}
|
||||
label {
|
||||
height: fit-content;
|
||||
width: fit-content;
|
||||
span {
|
||||
position: relative;
|
||||
left: calc(var(--box-margin) + var(--box-width));
|
||||
user-select: none;
|
||||
&::after {
|
||||
transition: 0.2s ease-out;
|
||||
position: absolute;
|
||||
content: "";
|
||||
top: calc((100% - var(--ball-width)) / 2);
|
||||
width: var(--ball-width);
|
||||
height: var(--ball-width);
|
||||
left: calc(-1 * (var(--box-width) + var(--box-margin)) + 2px);
|
||||
border-radius: 50%;
|
||||
display: inline-block;
|
||||
background-color: rgb(0, 60, 255);
|
||||
}
|
||||
&::before {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: calc(-1 * var(--box-width) - var(--box-margin));
|
||||
content: "";
|
||||
width: var(--box-width);
|
||||
height: 100%;
|
||||
border-radius: 10px;
|
||||
background-color: red;
|
||||
display: inline-block;
|
||||
}
|
||||
}
|
||||
input:checked ~ span::after {
|
||||
left: calc(-1 * (var(--box-margin) + var(--ball-width) + 3px));
|
||||
background-color: rgb(0, 60, 255);
|
||||
}
|
||||
input:checked ~ span::before {
|
||||
background-color: rgb(0, 255, 0);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
iframe {
|
||||
margin: 0 auto;
|
||||
border: 1px solid black;
|
||||
background-color: white;
|
||||
display: block;
|
||||
overflow: scroll;
|
||||
}
|
||||
#preview-toggler {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
gap: 50px;
|
||||
}
|
||||
#theme-picker {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(5, auto);
|
||||
gap: 10px;
|
||||
justify-content: center;
|
||||
.theme {
|
||||
width: 50px;
|
||||
height: 50px;
|
||||
padding: 5px;
|
||||
word-wrap: break-word;
|
||||
word-break: break-all;
|
||||
border-radius: 50%;
|
||||
border: 1px solid gray;
|
||||
transition-duration: 0.2s;
|
||||
display: grid;
|
||||
text-align: center;
|
||||
justify-content: center;
|
||||
align-content: center;
|
||||
&:hover {
|
||||
border: 1px solid blue;
|
||||
cursor: pointer;
|
||||
transform: translateY(-5px);
|
||||
}
|
||||
}
|
||||
}
|
||||
#size-input {
|
||||
select {
|
||||
padding: 5px;
|
||||
}
|
||||
& > div:first-child {
|
||||
margin-bottom: 5px;
|
||||
}
|
||||
}
|
||||
#turnoff-catch {
|
||||
width: 100vw;
|
||||
height: 100vh;
|
||||
@@ -218,282 +509,3 @@
|
||||
margin-inline: auto;
|
||||
}
|
||||
}
|
||||
|
||||
#test-container {
|
||||
align-items: center;
|
||||
height: max-content;
|
||||
margin-bottom: 100px;
|
||||
}
|
||||
|
||||
.test-wrapper {
|
||||
margin: 1rem;
|
||||
padding: 0.5rem;
|
||||
background-color: aliceblue;
|
||||
}
|
||||
|
||||
#popularNovels,
|
||||
#headerChanger,
|
||||
#searchNovels,
|
||||
#parseNovelAndChapters,
|
||||
#parseChapter,
|
||||
#fetchImage {
|
||||
min-width: 95%;
|
||||
max-width: 95%;
|
||||
margin-inline: auto;
|
||||
}
|
||||
|
||||
.headerinfo {
|
||||
margin-bottom: 5px;
|
||||
span[contenteditable="true"] {
|
||||
border: 1px solid black;
|
||||
padding: 3px 10px;
|
||||
display: inline;
|
||||
}
|
||||
}
|
||||
|
||||
#headersnotcopied,
|
||||
#headerscopied {
|
||||
font-size: 1.3rem;
|
||||
}
|
||||
|
||||
#headersnotcopied {
|
||||
color: red;
|
||||
display: none;
|
||||
}
|
||||
|
||||
#headerscopied {
|
||||
color: green;
|
||||
display: none;
|
||||
}
|
||||
|
||||
.headereditbutton {
|
||||
margin-left: 5px;
|
||||
border: none;
|
||||
padding-inline: 5px;
|
||||
}
|
||||
|
||||
#popularNovels,
|
||||
#searchNovels {
|
||||
height: 350px;
|
||||
overflow-y: hidden;
|
||||
overflow-x: scroll;
|
||||
}
|
||||
|
||||
.novel_info {
|
||||
display: grid;
|
||||
grid-auto-flow: row;
|
||||
grid-auto-rows: min-content;
|
||||
}
|
||||
|
||||
.parse-novel-btn {
|
||||
width: 85%;
|
||||
margin-inline: auto;
|
||||
margin-top: 5px;
|
||||
}
|
||||
|
||||
#parseNovelAndChapters {
|
||||
height: 380px;
|
||||
}
|
||||
|
||||
.title {
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
@keyframes spinner-border {
|
||||
100% {
|
||||
-webkit-transform: rotate(360deg);
|
||||
transform: rotate(360deg);
|
||||
}
|
||||
}
|
||||
|
||||
.spinner-border {
|
||||
display: none;
|
||||
width: 1rem;
|
||||
height: 1rem;
|
||||
vertical-align: text-bottom;
|
||||
border: 0.25em solid currentColor;
|
||||
border-right-color: transparent;
|
||||
border-radius: 50%;
|
||||
-webkit-animation: spinner-border 0.75s linear infinite;
|
||||
animation: spinner-border 0.75s linear infinite;
|
||||
}
|
||||
|
||||
.novel-list {
|
||||
display: flex;
|
||||
margin-top: 0.5rem;
|
||||
height: 300px;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.novel-item {
|
||||
display: flex;
|
||||
padding: 0.5rem;
|
||||
img {
|
||||
max-height: 90%;
|
||||
}
|
||||
}
|
||||
|
||||
.novel-info {
|
||||
width: 16rem;
|
||||
}
|
||||
/* comment */
|
||||
.info-item {
|
||||
display: grid;
|
||||
grid-auto-columns: min-content auto 50px;
|
||||
margin-top: 5px;
|
||||
grid-auto-flow: column;
|
||||
div {
|
||||
display: grid;
|
||||
align-items: center;
|
||||
}
|
||||
}
|
||||
|
||||
.info-value {
|
||||
width: 10rem;
|
||||
padding-inline: 0.25rem;
|
||||
font-size: 0.65rem;
|
||||
word-wrap: break-word;
|
||||
}
|
||||
|
||||
.info-copy {
|
||||
display: grid;
|
||||
align-content: center;
|
||||
}
|
||||
|
||||
.btn {
|
||||
font-size: 0.75rem;
|
||||
padding: 0.25rem 0.25rem;
|
||||
&.disabled,
|
||||
&:disabled {
|
||||
opacity: 1;
|
||||
}
|
||||
}
|
||||
|
||||
.chapter-list-container {
|
||||
max-height: 95%;
|
||||
overflow-y: scroll;
|
||||
}
|
||||
|
||||
.chapter-list {
|
||||
column-count: 2;
|
||||
}
|
||||
|
||||
.chapter-item {
|
||||
display: grid;
|
||||
grid-template-areas: "name btn1 btn2" "date btn1 btn2";
|
||||
}
|
||||
|
||||
.ci-topleft {
|
||||
grid-area: name;
|
||||
}
|
||||
|
||||
.ci-bottomleft {
|
||||
grid-area: date;
|
||||
}
|
||||
|
||||
.ci-btn1 {
|
||||
grid-area: btn1;
|
||||
}
|
||||
|
||||
.ci-btn2 {
|
||||
grid-area: btn2;
|
||||
}
|
||||
|
||||
.select-option-text {
|
||||
padding-left: 1rem;
|
||||
}
|
||||
|
||||
/* Slider checkbox */
|
||||
.slider-checkbox {
|
||||
--ball-width: 15px;
|
||||
--box-margin: 5px;
|
||||
--box-width: calc(2 * var(--ball-width) + var(--box-margin));
|
||||
input {
|
||||
display: none;
|
||||
}
|
||||
label {
|
||||
height: fit-content;
|
||||
width: fit-content;
|
||||
span {
|
||||
position: relative;
|
||||
left: calc(var(--box-margin) + var(--box-width));
|
||||
user-select: none;
|
||||
&::after {
|
||||
transition: 0.2s ease-out;
|
||||
position: absolute;
|
||||
content: "";
|
||||
top: calc((100% - var(--ball-width)) / 2);
|
||||
width: var(--ball-width);
|
||||
height: var(--ball-width);
|
||||
left: calc(-1 * (var(--box-width) + var(--box-margin)) + 2px);
|
||||
border-radius: 50%;
|
||||
display: inline-block;
|
||||
background-color: rgb(0, 60, 255);
|
||||
}
|
||||
&::before {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: calc(-1 * var(--box-width) - var(--box-margin));
|
||||
content: "";
|
||||
width: var(--box-width);
|
||||
height: 100%;
|
||||
border-radius: 10px;
|
||||
background-color: red;
|
||||
display: inline-block;
|
||||
}
|
||||
}
|
||||
input:checked ~ span::after {
|
||||
left: calc(-1 * (var(--box-margin) + var(--ball-width) + 3px));
|
||||
background-color: rgb(0, 60, 255);
|
||||
}
|
||||
input:checked ~ span::before {
|
||||
background-color: rgb(0, 255, 0);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
iframe {
|
||||
margin: 0 auto;
|
||||
border: 1px solid black;
|
||||
background-color: white;
|
||||
display: block;
|
||||
overflow: scroll;
|
||||
}
|
||||
#preview-toggler {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
gap: 50px;
|
||||
}
|
||||
#theme-picker {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(5, auto);
|
||||
gap: 10px;
|
||||
justify-content: center;
|
||||
.theme {
|
||||
width: 50px;
|
||||
height: 50px;
|
||||
padding: 5px;
|
||||
word-wrap: break-word;
|
||||
word-break: break-all;
|
||||
border-radius: 50%;
|
||||
border: 1px solid gray;
|
||||
transition-duration: 0.2s;
|
||||
display: grid;
|
||||
text-align: center;
|
||||
justify-content: center;
|
||||
align-content: center;
|
||||
&:hover {
|
||||
border: 1px solid blue;
|
||||
cursor: pointer;
|
||||
transform: translateY(-5px);
|
||||
}
|
||||
}
|
||||
}
|
||||
#size-input {
|
||||
select {
|
||||
padding: 5px;
|
||||
}
|
||||
& > div:first-child {
|
||||
margin-bottom: 5px;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,445 @@
|
||||
@import "./darkmode";
|
||||
|
||||
#search-results {
|
||||
position: absolute;
|
||||
top: calc(100% - 0.5rem);
|
||||
width: fit-content;
|
||||
max-height: 500%;
|
||||
overflow-y: scroll;
|
||||
overflow-x: hidden;
|
||||
padding: 0.375rem 0;
|
||||
border-radius: 5px;
|
||||
background-color: transparent;
|
||||
z-index: 3;
|
||||
button {
|
||||
background-color: white;
|
||||
text-transform: capitalize;
|
||||
}
|
||||
}
|
||||
|
||||
#turnoff-catch {
|
||||
width: 100vw;
|
||||
height: 100vh;
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
z-index: 2;
|
||||
}
|
||||
|
||||
.input-group {
|
||||
width: 20rem;
|
||||
}
|
||||
|
||||
.checkbox-groupbox {
|
||||
border: 1px solid rgb(182, 176, 166);
|
||||
padding: 5px;
|
||||
display: grid;
|
||||
gap: 10px;
|
||||
grid-template-columns: repeat(3, auto);
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.xcheckbox-groupbox {
|
||||
border: 1px solid rgb(182, 176, 166);
|
||||
padding: 5px;
|
||||
display: grid;
|
||||
gap: 10px;
|
||||
grid-template-columns: repeat(3, auto);
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.xcheckbox {
|
||||
display: block;
|
||||
position: relative;
|
||||
padding-left: 35px;
|
||||
margin-bottom: 12px;
|
||||
cursor: pointer;
|
||||
font-size: 22px;
|
||||
-webkit-user-select: none;
|
||||
-moz-user-select: none;
|
||||
-ms-user-select: none;
|
||||
user-select: none;
|
||||
|
||||
/* Hide the browser's default checkbox */
|
||||
input {
|
||||
position: absolute;
|
||||
opacity: 0;
|
||||
cursor: pointer;
|
||||
height: 0;
|
||||
width: 0;
|
||||
}
|
||||
span {
|
||||
position: absolute;
|
||||
top: 6px;
|
||||
left: 5px;
|
||||
height: 20px;
|
||||
width: 20px;
|
||||
background-color: #eee;
|
||||
border: 1px solid white;
|
||||
&::after {
|
||||
content: "";
|
||||
position: absolute;
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
&[data-state="i"] {
|
||||
span {
|
||||
background-color: #2196f3;
|
||||
&::after {
|
||||
left: 6px;
|
||||
top: 3px;
|
||||
width: 6px;
|
||||
height: 10px;
|
||||
border: solid white;
|
||||
border-width: 0 3px 3px 0;
|
||||
-webkit-transform: rotate(45deg);
|
||||
-ms-transform: rotate(45deg);
|
||||
transform: rotate(45deg);
|
||||
}
|
||||
}
|
||||
&:hover {
|
||||
span {
|
||||
background-color: #56a3ff;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&[dara-state="x"] {
|
||||
span {
|
||||
background-color: #f32196;
|
||||
position: absolute;
|
||||
height: 20px;
|
||||
width: 20px;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
background-color: red;
|
||||
&::after,
|
||||
&::before {
|
||||
position: absolute;
|
||||
content: "";
|
||||
width: 80%;
|
||||
left: 10%;
|
||||
height: 2px;
|
||||
background-color: white;
|
||||
}
|
||||
&::before {
|
||||
transform: rotate(45deg);
|
||||
}
|
||||
|
||||
&::after {
|
||||
transform: rotate(-45deg);
|
||||
}
|
||||
}
|
||||
&:hover {
|
||||
span {
|
||||
background-color: #ff56a3;
|
||||
}
|
||||
input ~ span {
|
||||
background-color: #ccc;
|
||||
}
|
||||
}
|
||||
}
|
||||
input:checked ~ span::after {
|
||||
display: block;
|
||||
}
|
||||
}
|
||||
|
||||
.modal-body {
|
||||
padding: 16px 50px 0 50px;
|
||||
}
|
||||
|
||||
.checkbox-groupbox input {
|
||||
margin-right: 5px;
|
||||
}
|
||||
|
||||
.SwitchFilter {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.SwitchFilter input {
|
||||
margin-left: 10px;
|
||||
}
|
||||
|
||||
.PickerFilter select {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.filter-label {
|
||||
display: block;
|
||||
text-align: center;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
#filtersModal {
|
||||
.modal-body div {
|
||||
display: grid;
|
||||
align-content: center;
|
||||
}
|
||||
hr {
|
||||
margin-bottom: 10px;
|
||||
margin-top: 10px;
|
||||
/* visibility: hidden; */
|
||||
}
|
||||
}
|
||||
|
||||
#settingsModal {
|
||||
.modal-body > div {
|
||||
display: grid;
|
||||
align-content: center;
|
||||
}
|
||||
input {
|
||||
text-align: center;
|
||||
}
|
||||
textarea {
|
||||
display: block;
|
||||
width: 100%;
|
||||
margin-inline: auto;
|
||||
}
|
||||
}
|
||||
|
||||
#test-container {
|
||||
align-items: center;
|
||||
height: max-content;
|
||||
margin-bottom: 100px;
|
||||
}
|
||||
|
||||
.accordion-box {
|
||||
margin: 1rem;
|
||||
padding: 0.5rem;
|
||||
background-color: aliceblue;
|
||||
}
|
||||
|
||||
#popularNovels,
|
||||
#headerChanger,
|
||||
#searchNovels,
|
||||
#parseNovelAndChapters,
|
||||
#parseChapter,
|
||||
#fetchImage {
|
||||
min-width: 95%;
|
||||
max-width: 95%;
|
||||
margin-inline: auto;
|
||||
}
|
||||
|
||||
#popularNovels,
|
||||
#searchNovels {
|
||||
overflow-x: scroll;
|
||||
}
|
||||
|
||||
.novel_info {
|
||||
display: grid;
|
||||
grid-auto-flow: row;
|
||||
grid-auto-rows: min-content;
|
||||
}
|
||||
|
||||
.parse-novel-btn {
|
||||
width: 85%;
|
||||
margin-inline: auto;
|
||||
margin-top: 5px;
|
||||
}
|
||||
|
||||
.title {
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
@keyframes spinner-border {
|
||||
100% {
|
||||
-webkit-transform: rotate(360deg);
|
||||
transform: rotate(360deg);
|
||||
}
|
||||
}
|
||||
|
||||
.spinner-border {
|
||||
display: none;
|
||||
width: 1rem;
|
||||
height: 1rem;
|
||||
vertical-align: text-bottom;
|
||||
border: 0.25em solid currentColor;
|
||||
border-right-color: transparent;
|
||||
border-radius: 50%;
|
||||
-webkit-animation: spinner-border 0.75s linear infinite;
|
||||
animation: spinner-border 0.75s linear infinite;
|
||||
}
|
||||
|
||||
.novel-list {
|
||||
display: flex;
|
||||
overflow-x: scroll;
|
||||
scrollbar-width: 5px;
|
||||
margin-top: 0.5rem;
|
||||
height: 300px;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.novel-item {
|
||||
display: flex;
|
||||
padding: 0.5rem;
|
||||
img {
|
||||
max-height: 90%;
|
||||
}
|
||||
}
|
||||
|
||||
.novel-info {
|
||||
width: 16rem;
|
||||
}
|
||||
/* comment */
|
||||
.info-item {
|
||||
display: grid;
|
||||
grid-auto-columns: min-content auto 50px;
|
||||
margin-top: 5px;
|
||||
grid-auto-flow: column;
|
||||
div {
|
||||
display: grid;
|
||||
align-items: center;
|
||||
}
|
||||
}
|
||||
|
||||
.info-value {
|
||||
width: 10rem;
|
||||
padding-inline: 0.25rem;
|
||||
font-size: 0.65rem;
|
||||
word-wrap: break-word;
|
||||
}
|
||||
|
||||
.info-copy {
|
||||
display: grid;
|
||||
align-content: center;
|
||||
}
|
||||
|
||||
.btn {
|
||||
font-size: 0.75rem;
|
||||
padding: 0.25rem 0.25rem;
|
||||
&.disabled,
|
||||
&:disabled {
|
||||
opacity: 1;
|
||||
}
|
||||
}
|
||||
|
||||
.chapter-list-container {
|
||||
max-height: 95%;
|
||||
overflow-y: scroll;
|
||||
}
|
||||
|
||||
.chapter-list {
|
||||
column-count: 2;
|
||||
}
|
||||
|
||||
.chapter-item {
|
||||
display: grid;
|
||||
grid-template-areas: "name btn1 btn2" "date btn1 btn2";
|
||||
}
|
||||
|
||||
.ci-topleft {
|
||||
grid-area: name;
|
||||
}
|
||||
|
||||
.ci-bottomleft {
|
||||
grid-area: date;
|
||||
}
|
||||
|
||||
.ci-btn1 {
|
||||
grid-area: btn1;
|
||||
}
|
||||
|
||||
.ci-btn2 {
|
||||
grid-area: btn2;
|
||||
}
|
||||
|
||||
.select-option-text {
|
||||
padding-left: 1rem;
|
||||
}
|
||||
|
||||
/* Slider checkbox */
|
||||
.slider-checkbox {
|
||||
--ball-width: 15px;
|
||||
--box-margin: 5px;
|
||||
--box-width: calc(2 * var(--ball-width) + var(--box-margin));
|
||||
input {
|
||||
display: none;
|
||||
}
|
||||
label {
|
||||
height: fit-content;
|
||||
width: fit-content;
|
||||
span {
|
||||
position: relative;
|
||||
left: calc(var(--box-margin) + var(--box-width));
|
||||
user-select: none;
|
||||
&::after {
|
||||
transition: 0.2s ease-out;
|
||||
position: absolute;
|
||||
content: "";
|
||||
top: calc((100% - var(--ball-width)) / 2);
|
||||
width: var(--ball-width);
|
||||
height: var(--ball-width);
|
||||
left: calc(-1 * (var(--box-width) + var(--box-margin)) + 2px);
|
||||
border-radius: 50%;
|
||||
display: inline-block;
|
||||
background-color: rgb(0, 60, 255);
|
||||
}
|
||||
&::before {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: calc(-1 * var(--box-width) - var(--box-margin));
|
||||
content: "";
|
||||
width: var(--box-width);
|
||||
height: 100%;
|
||||
border-radius: 10px;
|
||||
background-color: red;
|
||||
display: inline-block;
|
||||
}
|
||||
}
|
||||
input:checked ~ span::after {
|
||||
left: calc(-1 * (var(--box-margin) + var(--ball-width) + 3px));
|
||||
background-color: rgb(0, 60, 255);
|
||||
}
|
||||
input:checked ~ span::before {
|
||||
background-color: rgb(0, 255, 0);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
iframe {
|
||||
margin: 0 auto;
|
||||
border: 1px solid black;
|
||||
background-color: white;
|
||||
display: block;
|
||||
overflow: scroll;
|
||||
}
|
||||
#preview-toggler {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
gap: 50px;
|
||||
}
|
||||
#theme-picker {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(5, auto);
|
||||
gap: 10px;
|
||||
justify-content: center;
|
||||
.theme {
|
||||
width: 50px;
|
||||
height: 50px;
|
||||
padding: 5px;
|
||||
word-wrap: break-word;
|
||||
word-break: break-all;
|
||||
border-radius: 50%;
|
||||
border: 1px solid gray;
|
||||
transition-duration: 0.2s;
|
||||
display: grid;
|
||||
text-align: center;
|
||||
justify-content: center;
|
||||
align-content: center;
|
||||
&:hover {
|
||||
border: 1px solid blue;
|
||||
cursor: pointer;
|
||||
transform: translateY(-5px);
|
||||
}
|
||||
}
|
||||
}
|
||||
#size-input {
|
||||
select {
|
||||
padding: 5px;
|
||||
}
|
||||
& > div:first-child {
|
||||
margin-bottom: 5px;
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,92 @@
|
||||
/** @ts-check */
|
||||
|
||||
class AccordionContent extends HTMLElement {
|
||||
constructor() {
|
||||
super();
|
||||
this.gridElement = document.createElement("div");
|
||||
}
|
||||
get content() {
|
||||
return this.gridElement;
|
||||
}
|
||||
connectedCallback() {
|
||||
// create a div that'll animate the collapsing
|
||||
this.gridElement.append(...Array.from(this.childNodes));
|
||||
this.gridElement.classList.add("accordion-animation-content");
|
||||
this.innerHTML = "";
|
||||
this.append(this.gridElement);
|
||||
}
|
||||
}
|
||||
|
||||
class AccordionHeader extends HTMLElement {
|
||||
constructor() {
|
||||
super();
|
||||
console.log("contructor?");
|
||||
this.btn = document.createElement("button");
|
||||
}
|
||||
get html() {
|
||||
return this.btn.innerHTML;
|
||||
}
|
||||
set html(val) {
|
||||
this.btn.innerHTML = val;
|
||||
}
|
||||
get text() {
|
||||
return this.btn.innerText;
|
||||
}
|
||||
set text(val) {
|
||||
this.btn.innerText = val;
|
||||
}
|
||||
get parentBox() {
|
||||
return this.parentElement;
|
||||
}
|
||||
connectedCallback() {
|
||||
console.log("I AM ON THE SCREEN, DO YOUR FUCKING JOB");
|
||||
const childNodes = Array.from(this.childNodes);
|
||||
this.innerHTML = "";
|
||||
this.btn.append(...childNodes);
|
||||
this.append(this.btn);
|
||||
this.btn.addEventListener("click", this._btnClicked.bind(this));
|
||||
}
|
||||
_btnClicked() {
|
||||
this.parentBox?.toggle();
|
||||
}
|
||||
}
|
||||
|
||||
class AccordionBox extends HTMLElement {
|
||||
constructor() {
|
||||
super();
|
||||
}
|
||||
get collapsed() {
|
||||
return this.hasAttribute("collapsed");
|
||||
}
|
||||
set collapsed(val) {
|
||||
if (val) {
|
||||
this.setAttribute("collapsed", "");
|
||||
} else {
|
||||
this.removeAttribute("collapsed");
|
||||
}
|
||||
}
|
||||
toggle() {
|
||||
this.collapsed = !this.collapsed;
|
||||
}
|
||||
}
|
||||
|
||||
class Accordion extends HTMLElement {
|
||||
constructor() {
|
||||
super();
|
||||
}
|
||||
}
|
||||
|
||||
window.customElements.define("main-accordion", Accordion);
|
||||
window.customElements.define("accordion-box", AccordionBox);
|
||||
window.customElements.define("accordion-header", AccordionHeader);
|
||||
window.customElements.define("accordion-content", AccordionContent);
|
||||
|
||||
// Export types for use in index.js
|
||||
const module = {};
|
||||
|
||||
module.exports = {
|
||||
AccordionBox,
|
||||
Accordion,
|
||||
AccordionContent,
|
||||
AccordionHeader,
|
||||
};
|
||||
+1552
-1247
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
Vendored
+1
@@ -1,4 +1,5 @@
|
||||
interface Window {
|
||||
themes: Record<string, ThemeType>;
|
||||
sanitizeChapterText(html: string, options?: Options);
|
||||
encodeHTML5(html: string, options?: Options);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user