diff --git a/cps/static/css/reader.css b/cps/static/css/reader.css new file mode 100644 index 00000000..ec8054ca --- /dev/null +++ b/cps/static/css/reader.css @@ -0,0 +1,29 @@ +.fontSizeWrapper { + position: relative; +} +.slider { + position: absolute; + top: 50%; + transform: translate(0,-50%); + width: 90%; + height: 60px; + background: transparent; + border-radius: 20px; + display: flex; + align-items: center; + box-shadow: 0px 15px 40px #7E6D5766; +} +.slider label { + font-size: 20px; + font-weight: 400; + font-family: Open Sans; + padding-right: 10px; + color: white; +} +.slider input[type="range"] { + width: 80%; + height: 5px; + background: black; + border: none; + outline: none; +} diff --git a/cps/templates/read.html b/cps/templates/read.html index 1b890c33..8dc32a48 100644 --- a/cps/templates/read.html +++ b/cps/templates/read.html @@ -16,6 +16,7 @@ + +
+
+ + +
+
@@ -131,7 +138,14 @@ else if (id == "blackTheme") { document.getElementById("main").style.backgroundColor = "black"; } - } + + } + + // font size settings logic + let fontSizeFader = document.getElementById('fontSizeFader'); + fontSizeFader.addEventListener ("change", function () { + reader.rendition.themes.fontSize(`${this.value}%`) + });