diff --git a/.eslintrc b/.eslintrc new file mode 100644 index 00000000..167b8fad --- /dev/null +++ b/.eslintrc @@ -0,0 +1,59 @@ +{ + "env": { + "es6": true, + "amd": true, + "node": true, + "browser": true, + "commonjs": true + }, + "parserOptions": { + "ecmaVersion": 9, + "sourceType": "module", + "ecmaFeatures": { + "jsx": true, + "forOf": true, + "spread": true, + "modules": true, + "classes": true, + "generators": true, + "restParams": true, + "regexUFlag": true, + "regexYFlag": true, + "globalReturn": true, + "destructuring": true, + "impliedStrict": true, + "blockBindings": true, + "defaultParams": true, + "octalLiterals": true, + "arrowFunctions": true, + "binaryLiterals": true, + "templateStrings": true, + "superInFunctions": true, + "unicodeCodePointEscapes": true, + "objectLiteralShorthandMethods": true, + "objectLiteralComputedProperties": true, + "objectLiteralDuplicateProperties": true, + "objectLiteralShorthandProperties": true + } + }, + "plugins": [], + "rules": { + "semi": "error", + "indent": [ 0, 2 ], + "strict": "off", + "eqeqeq": "error", + "no-var": "warn", + "no-undef": "warn", + "comma-dangle": "warn", + "no-dupe-args": "warn", + "no-dupe-keys": "warn", + "require-await": "warn", + "no-global-assign": "warn", + "no-duplicate-imports": "error", + "no-dupe-class-members": "error" + }, + "globals": { + "_config": false, + "console": false + } +} \ No newline at end of file diff --git a/.github/FUNDING.yml b/.github/FUNDING.yml new file mode 100644 index 00000000..d7c2f33e --- /dev/null +++ b/.github/FUNDING.yml @@ -0,0 +1,2 @@ +patreon: ohlookitsderpy +ko_fi: ohlookitsderpy diff --git a/.gitignore b/.gitignore new file mode 100644 index 00000000..ffe67254 --- /dev/null +++ b/.gitignore @@ -0,0 +1,8 @@ +# Directories +.vscode/ +node_modules/ + +# Files +yarn.lock +yarn-error.log +package-lock.json diff --git a/LICENSE b/LICENSE new file mode 100644 index 00000000..f9b3f41c --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2018-2019 David Ralph (ohlookitsderpy) + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/README.md b/README.md new file mode 100644 index 00000000..e29ea266 --- /dev/null +++ b/README.md @@ -0,0 +1,128 @@ + + +# Mue +[![Codacy Badge](https://api.codacy.com/project/badge/Grade/fba7ad7fc6e14fe0bc2a8d53dbf0bb41)](https://www.codacy.com/app/ohlookitsderpy/Mue?utm_source=github.com&utm_medium=referral&utm_content=ohlookitsderpy/Mue&utm_campaign=Badge_Grade) +[![Discord Badge](https://discordapp.com/api/guilds/336039472250748928/widget.png)](https://discord.gg/HJmmmTB) + +Buy me a coffee at ko-fi.com +Become a patron on patreon.com + +Fast, open and free-to-use new tab page for most modern browsers. + +## Features +* Fast and free +* Supports multiple browsers +* Actively developed and opensource +* Multiple language support + +## Installation +### Chrome + + +Link: [Chrome Web Store](https://chrome.google.com/webstore/detail/mue/bngmbednanpcfochchhgbkookpiaiaid) + +Development: Read the [Development](#development) section. +### Firefox + + +Link: [Firefox Add-ons](https://addons.mozilla.org/firefox/addon/mue) + +Development: Read the [Development](#development) section. +### Opera/Other +Link: [GitHub Releases](https://github.com/ohlookitsderpy/Mue/releases) + +Development: Read the [Development](#development) section. + +### Development +
Requirements
+
    +
  1. Git (optional)
  2. +
  3. Node.js
  4. +
  5. A suitable browser
  6. +
+
Starting
+
    +
  1. git clone https://github.com/ohlookitsderpy/Mue (If you don't have Git just go to Clone or + download and click Download ZIP) +
  2. Open a terminal and run these commands: (in the Mue directory) +
  3. yarn (or npm install) +
  4. yarn run sass-watch (or npm run sass-watch) +
  5. Open another terminal and run this command: (in the Mue directory) +
  6. yarn run js-watch (or npm run js-watch) +
  7. Start developing! (See the sections below for how to set it up with your browser) +
+
+ Chrome (Click to expand) +
    +
  1. Rename manifest-chrome.json to manifest.json +
  2. Visit chrome://extensions in Chrome +
  3. Click Load unpacked (Make sure Developer Mode is on) +
  4. Go to the directory containing Mue and click ok +
  5. Enjoy your new tab! +
+
+ Opera (Click to expand) +
    +
  1. Rename manifest-opera.json to manifest.json +
  2. Visit about://extensions in Opera +
  3. Click Load unpacked extension... (Make sure Developer Mode is on) +
  4. Go to the directory containing Mue and click ok +
  5. Enjoy your new tab! +
+
+ Firefox (Click to expand) + Note: I'm currently trying to find a better method to do this, but this works for now. +
    +
  1. Rename manifest-firefox.json to manifest.json +
  2. Visit about:debugging#addons in Firefox +
  3. Click Load Temporary Add-on +
  4. Go to the directory containing Mue and click on the manifest.json +
  5. Enjoy your new tab! +
+
+
+ Other (Click to expand) + Note: To get the full new tab experience, set your browser to open the index.html on startup and tab open! +
    +
  1. Open the index.html in your browser +
  2. Enjoy your new tab! +
+
+ +## Screenshot +*Will be updated if needed* + + + +## Credits + +[TurboMarshmello](https://github.com/TurboMarshmello) - Portions of original code, name idea + +[Pexels](https://pexels.com) - Stock photos used + +[Opera Forum](https://forums.opera.com/topic/25046/how-to-disable-completely-the-speed-dial/14) - Portions of code to add Opera support + +[Animate.css](https://daneden.github.io/animate.css) - Portions of code used to add animations + +### Translations +[ohlookitsderpy](https://github.com/ohlookitsderpy) - English (Quotes and Messages) + +[Yanderella](https://github.com/Chivi19) - Italian (Quotes and Messages) + +Pepehound - Spanish (Quotes and Messages) + +Candystick - Portuguese (Some Quotes) + +[PassTheWessel](https://github.com/PassTheWessel) - Dutch (Messages) + +[Yanderella](https://github.com/Chivi19) and [ohlookitsderpy](https://github.com/ohlookitsderpy) - French (Messages) + +[untocodes](https://github.com/untocodes) - Finnish and German (Messages) + +[dondish](https://github.com/dondish) - Hebrew and Russian (Messages) + +[MrSheldon](https://github.com/MrSheldon) - Arabic and Swedish (Messages) + +*Feel free to pull request with other translations!* + +and all the contributors <3 diff --git a/assets/chrome.png b/assets/chrome.png new file mode 100644 index 00000000..1b0834c4 Binary files /dev/null and b/assets/chrome.png differ diff --git a/assets/css/base.css b/assets/css/base.css deleted file mode 100644 index 09d74564..00000000 --- a/assets/css/base.css +++ /dev/null @@ -1 +0,0 @@ -.mountain{background-image:url("../img/1.jpeg")}.sunrise{background-image:url("../img/2.jpeg")}.butterfly{background-image:url("../img/3.jpeg")}.leaves{background-image:url("../img/4.jpeg")}.river{background-image:url("../img/5.jpeg")}.sea{background-image:url("../img/6.jpeg")}.space{background-image:url("../img/7.jpeg")}.ice{background-image:url("../img/8.jpeg")}.waterfall{background-image:url("../img/9.jpeg")}.lake{background-image:url("../img/10.jpeg")}.sunset{background-image:url("../img/11.jpeg")}.desert{background-image:url("../img/12.jpeg")}.canyon{background-image:url("../img/13.jpeg")}.rose{background-image:url("../img/14.jpeg")}.forest{background-image:url("../img/15.jpeg")}.cherry{background-image:url("../img/16.jpeg")}.clouds{background-image:url("../img/17.jpeg")}.winter{background-image:url("../img/18.jpeg")}.autumn{background-image:url("../img/19.jpeg")}.flowers{background-image:url("../img/20.jpeg")}.sunrise{background-image:url("../img/21.jpeg")}.rocks{background-image:url("../img/22.jpeg")}.trees{background-image:url("../img/23.jpeg")}.mountains{background-image:url("../img/24.jpeg")}.beach{background-image:url("../img/25.jpeg")}@font-face{font-family:"Material Icons";font-style:normal;font-weight:400;src:url("../font/MaterialIcons-Regular.woff2") format("woff2")}.material-icons{font-family:"Material Icons";font-weight:normal;font-style:normal;font-size:24px;line-height:1;letter-spacing:normal;text-transform:none;display:inline-block;white-space:nowrap;word-wrap:normal;direction:ltr;-moz-font-feature-settings:"liga";font-feature-settings:"liga";-moz-osx-font-smoothing:grayscale}@font-face{font-family:"Open Sans";src:url("../font/opensans-regular-webfont.woff2") format("woff2"),url("../font/opensans-regular-webfont.woff") format("woff");src:url("../font/roboto-v18-latin-regular.woff2") format("woff2")}i.material-icons{font-size:30px;display:inline;color:#fff}html,body{height:100%}body{display:flex;flex-direction:column;justify-content:space-around;align-items:center;margin:0;background-size:cover;background-position:50%;background-color:#000;font-family:"Open Sans";color:#fff;overflow:hidden;-moz-user-select:none;user-select:none}:root{--shadow-color: #111111CC}.greeting,time,.quote{position:absolute;filter:drop-shadow(var(--shadow-shift) var(--shadow-shift) 0 var(--shadow-color))}::selection{background:#ff4f4e;color:#fff}.quote{padding-top:15em;--shadow-shift: 0.125rem;width:37.5%;max-width:37.5rem;font-size:1.5rem;text-align:center}.quote blockquote{margin:0 0 .25rem 0;line-height:1.125}.quote blockquote ::before{content:"“";margin-right:.25ch}.quote blockquote ::after{content:"”";margin-left:.25ch}.quote cite{font-size:83.33%}.search-bar{position:absolute;left:20px;top:20px;display:flex;flex-direction:row}.search-bar button{font-size:1px;border:none;cursor:pointer;background:none;--shadow-shift: 0.4rem;display:inline}.search-bar button i.material-icons{text-shadow:0 0 25px rgba(0,0,0,.3)}.search-bar input[type=text]{padding:10px;font-size:15px;border:5px;opacity:.5;color:#fff;font-weight:bold;margin-left:5px;letter-spacing:1px;display:inline}.input.searchText{flex-grow:2;border:none;box-shadow:0 0 20px rgba(0,0,0,.3)}.searchbarform{display:flex;flex-direction:row}button.settings,button.news{background:transparent;border:none;color:#fff;padding:20px 20px;text-align:center;text-decoration:none;font-size:20px;cursor:pointer;border-radius:5px;display:table-cell}.buttons{position:absolute;right:10px;top:10px}.buttons i.material-icons{text-shadow:0 0 20px rgba(0,0,0,.3);padding-top:0}button.news{position:absolute;right:60px;top:0px}button.copyButton{background:transparent;border:none;color:#fff;padding:20px 20px;text-align:center;text-decoration:none;font-size:20px;cursor:pointer;border-radius:5px;display:table-cell}button.settings{background:transparent;border:none;color:#fff;padding:20px 20px;text-align:center;text-decoration:none;font-size:20px;cursor:pointer;border-radius:5px;display:table-cell}.buttons{position:absolute;right:10px;top:10px}i.material-icons{font-size:30px;display:inline;color:#fff}li.items{list-style:none;margin:0;padding-top:30px}.modal{display:none}.switch{position:relative;display:inline-block;width:60px;height:34px}.switch input{opacity:0;width:0;height:0}.slider{position:absolute;cursor:pointer;top:0;left:0;right:0;bottom:0;background-color:#ccc;-webkit-transition:.4s;transition:.4s}.slider :before{position:absolute;content:"";height:26px;width:26px;left:4px;bottom:4px;background-color:#fff;-webkit-transition:.4s;transition:.4s}input:checked+.slider{background-color:#ff4f4e}input:focus+.slider{box-shadow:0 0 1px #ff4f4e}input:checked+.slider:before{-webkit-transform:translateX(26px);-ms-transform:translateX(26px);transform:translateX(26px)}.slider{position:absolute;cursor:pointer;top:0;left:0;right:0;bottom:0;background-color:#ccc;-webkit-transition:.4s;transition:.4s;border-radius:34px}.slider:before{position:absolute;content:"";height:26px;width:26px;left:4px;bottom:4px;background-color:#fff;-webkit-transition:.4s;transition:.4s;border-radius:50%}.title{float:left}.blurslider{margin-top:7px;-webkit-appearance:none;width:200px;height:15px;border-radius:5px;background:#d3d3d3;outline:none;float:right}.blurslider ::-webkit-slider-thumb{-webkit-appearance:none;appearance:none;width:25px;height:25px;border-radius:50%;background:#ff4f4e;cursor:pointer}.blurslider ::-moz-range-thumb{width:25px;height:25px;border-radius:50%;background:#ff4f4e;cursor:pointer}.dropdown{position:relative;display:block;float:right;padding:10px;border:none;background:#ecf0f1}label.switch,p.switch{display:inline}label.switch{float:right}li.items{list-style:none;margin:0;padding-top:30px}.modal{display:none}.modal-content{max-height:500px}img{max-width:100%;margin-top:20px}.greeting{text-shadow:0 0 25px rgba(0,0,0,.3);font-size:3.25rem;padding-bottom:10em;font-weight:bold;letter-spacing:2px}time{text-shadow:0 0 25px rgba(0,0,0,.3);font-size:12rem;font-weight:bold}#withSeconds,#withoutSeconds,#greetingText{-khtml-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}/*# sourceMappingURL=base.css.map */ diff --git a/assets/css/base.css.map b/assets/css/base.css.map deleted file mode 100644 index 75cdce05..00000000 --- a/assets/css/base.css.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sourceRoot":"","sources":["../scss/modules/_bg.scss","../scss/modules/_font.scss","../scss/modules/_misc.scss","../scss/modules/_quote.scss","../scss/modules/_search.scss","../scss/modules/_buttons.scss","../scss/modules/_settings-modal.scss","../scss/modules/_time-greeting.scss"],"names":[],"mappings":"CAkBA,gDACA,+CACA,iDACA,8CACA,6CACA,2CACA,6CACA,2CACA,iDACA,6CACA,+CACA,+CACA,+CACA,6CACA,+CACA,+CACA,+CACA,+CACA,+CACA,gDACA,gDACA,8CACA,8CACA,kDACA,8CCvBA,WACI,6BACA,kBACA,gBACA,+DAGJ,gBACI,6BACA,mBACA,kBACA,eACA,cACA,sBACA,oBACA,qBACA,mBACA,iBACA,cACA,kCACA,6BACA,kCAGJ,WACI,wBACA,8HAEA,kEAGJ,iBACI,eACA,eACA,WCpDJ,sBACA,KAEC,aACA,sBACA,6BACA,mBAEA,SAEA,sBACA,wBACA,sBAEA,wBACA,WAEA,gBAEG,sBACH,iBAID,MACC,0BAGD,sBAGC,kBACA,kFAID,YACI,mBACA,WCrBJ,OACI,iBAEA,yBAEA,YACA,kBAEA,iBACA,kBAEA,kBACI,oBACA,kBAEA,2BACI,YACA,mBAGJ,0BACI,YACA,kBAIR,YACI,iBC3BR,YACI,kBACA,UACA,SACA,aACA,mBACA,mBACI,cACA,YACA,eACA,gBACA,uBAIA,eAHA,oCACI,oCAIR,6BACI,aACA,eACA,WACA,WACA,WACA,iBACA,gBACA,mBACA,eAIR,kBACI,YACA,YACA,mCAGJ,eACI,aACA,mBCxDJ,4BAEI,uBACA,YACA,WACA,kBACA,kBACA,qBACA,eACA,eACA,kBACA,mBAGJ,SACI,kBACA,WACA,SACA,0BACI,oCACA,cAIR,YACI,kBACA,WACA,QAGJ,kBACI,uBACA,YACA,WACA,kBACA,kBACA,qBACA,eACA,eACA,kBACA,mBCxCJ,gBACI,uBACA,YACA,WACA,kBACA,kBACA,qBACA,eACA,eACA,kBACA,mBAGJ,SACI,kBACA,WACA,SAGJ,iBACI,eACA,eACA,WAGJ,SACI,gBACA,SACA,iBAGJ,OACI,aAIJ,QACI,kBACA,qBACA,WACA,YAEA,cACI,UACA,QACA,SAIR,QACI,kBACA,eACA,MACA,OACA,QACA,SACA,sBACA,uBACA,eAEA,gBACI,kBACA,WACA,YACA,WACA,SACA,WACA,sBACA,uBACA,eAIR,sBACI,yBAGJ,oBACI,2BAGJ,6BACI,mCACA,+BACA,2BAGJ,QACI,kBACA,eACA,MACA,OACA,QACA,SACA,sBACA,uBACA,eACA,mBAGF,eACE,kBACA,WACA,YACA,WACA,SACA,WACA,sBACA,uBACA,eACA,kBAGJ,OACI,WAGJ,YACI,eACA,wBACA,YACA,YACA,kBACA,mBACA,aACA,YAEA,mCACI,wBACA,gBACA,WACA,YACA,kBACA,mBACA,eAGJ,+BACI,WACA,YACA,kBACA,mBACA,eAIR,UACI,kBACA,cACA,YACA,aACA,YACA,mBAGJ,sBAEI,eAGJ,aACI,YAGJ,SACI,gBACA,SACA,iBAGJ,OACI,aAGJ,eACI,iBAGJ,IACI,eACA,gBChKJ,UACC,oCACA,kBACG,oBACA,iBACA,mBAKJ,KACC,oCACA,gBACA,iBAGD,2CACK,wBACE,sBACC,qBACI","file":"base.css"} \ No newline at end of file diff --git a/assets/css/light.css b/assets/css/light.css deleted file mode 100644 index 14f25fa0..00000000 --- a/assets/css/light.css +++ /dev/null @@ -1,108 +0,0 @@ - -.modal { - display: none; /* Hidden by default */ - position: fixed; /* Stay in place */ - z-index: 1; /* Sit on top */ - padding-top: 100px; /* Location of the box */ - left: 0; - top: 0; - width: 100%; /* Full width */ - height: 100%; /* Full height */ - overflow: auto; /* Enable scroll if needed */ - background-color: rgb(0,0,0); /* Fallback color */ - background-color: rgba(0,0,0,0.4); /* Black w/ opacity */ -} - -h1, h2, h3, p { - color: #000000; -} - -.modal-content { - background-color: #ecf0f1; - margin: auto; - padding: 30px; - width: 450px; - max-height: 800px; - overflow-y: auto; -} - -.title, .close { - display: inline; -} -.settingsTitle, .close2 { - display: inline; -} - -.title { - color: #000000; - float: left; - font-size: 20px; - font-weight: bold; -} - -.settingsTitle { - color: #000000; - float: left; - font-size: 30px; - font-weight: bold; -} - -p.subtitle { - color: #000000; - float: left; - font-size: 10px; - font-weight: bold; - margin-top: 10px; -} -.close { - color: #aaaaaa; - float: right; - font-size: 30px; - font-weight: bold; -} - -.close:hover, -.close:focus { - color: #000; - text-decoration: none; - cursor: pointer; -} - -.close2 { - color: #aaaaaa; - float: right; - font-size: 30px; - font-weight: bold; -} -.title { - float: left; -} - -.close2:hover, -.close2:focus { - color: #000; - text-decoration: none; - cursor: pointer; -} -::-webkit-scrollbar { - width: 5px; -} - -/* Track */ -::-webkit-scrollbar-track { - background: #f1f1f1; -} - -/* Handle */ -::-webkit-scrollbar-thumb { - background: #888; -} - -/* Handle on hover */ -::-webkit-scrollbar-thumb:hover { - background: #555; -} - -.drop-btn { - color: #555; -} \ No newline at end of file diff --git a/assets/css/themes/dark.css b/assets/css/themes/dark.css deleted file mode 100644 index 99f8bbdf..00000000 --- a/assets/css/themes/dark.css +++ /dev/null @@ -1 +0,0 @@ -a{color:#fff}.modal{display:none;position:fixed;z-index:1;padding-top:100px;left:0;top:0;width:100%;height:100%;overflow:auto;background-color:#000;background-color:rgba(0,0,0,.4)}img{max-width:100%;margin-top:20px}h1,h2,h3,p{color:#fff}.modal-content{background-color:#2d3436;margin:auto;padding:30px;width:450px;max-height:600px;overflow-y:auto}.title,.close,.settingsTitle,.close2{display:inline}.title{color:#fff;float:left;font-size:20px;font-weight:bold}.settingsTitle{color:#fff;float:left;font-size:30px;font-weight:bold}p.subtitle{color:#fff;float:left;font-size:10px;font-weight:bold;margin-top:10px}.close{color:#fff;float:right;font-size:30px;font-weight:bold}.title{float:left}label.switch,p.switch{display:inline}label.switch{float:right}.close:hover,.close:focus{color:#bdc3c7;text-decoration:none;cursor:pointer}.close2{color:#fff;float:right;font-size:30px;font-weight:bold}.close2:hover,.close2:focus{color:#bdc3c7;text-decoration:none;cursor:pointer}::-webkit-scrollbar{width:5px}::-webkit-scrollbar-track{background:#2d3436}::-webkit-scrollbar-thumb{background:#34495e}::-webkit-scrollbar-thumb:hover{background:#2c3e50}/*# sourceMappingURL=dark.css.map */ diff --git a/assets/css/themes/dark.css.map b/assets/css/themes/dark.css.map deleted file mode 100644 index b0307468..00000000 --- a/assets/css/themes/dark.css.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sourceRoot":"","sources":["../../scss/themes/dark.scss"],"names":[],"mappings":"AAAA,EACI,WAGJ,OACI,aACA,eACA,UACA,kBACA,OACA,MACA,WACA,YACA,cACA,sBACA,gCAGJ,IACI,eACA,gBAGJ,WAII,WAGJ,eACI,yBACA,YACA,aACA,YACA,iBACA,gBAGJ,qCAII,eAGJ,OACI,WACA,WACA,eACA,iBAGJ,eACI,WACA,WACA,eACA,iBAGJ,WACI,WACA,WACA,eACA,iBACA,gBAGJ,OACI,WACA,YACA,eACA,iBAGJ,OACI,WAGJ,sBAEI,eAGJ,aACI,YAGJ,0BAEI,cACA,qBACA,eAGJ,QACI,WACA,YACA,eACA,iBAGJ,4BAEI,cACA,qBACA,eAGJ,oBACI,UAGJ,0BACI,mBAGJ,0BACI,mBAGJ,gCACI","file":"dark.css"} \ No newline at end of file diff --git a/assets/css/themes/light.css b/assets/css/themes/light.css deleted file mode 100644 index d20d47de..00000000 --- a/assets/css/themes/light.css +++ /dev/null @@ -1 +0,0 @@ -body{font-family:"Noto Sans HK",sans-serif;background:#fff;font-size:20px}.modal{display:none;position:fixed;z-index:1;padding-top:100px;left:0;top:0;width:100%;height:100%;overflow:auto;background-color:#000;background-color:rgba(0,0,0,.4);font-family:"Noto Sans HK",sans-serif}img{max-width:100%;margin-top:20px}h1,h2,h3,p{color:#000}.modal-content{background-color:#ecf0f1;margin:auto;padding:30px;width:450px;max-height:600px;overflow-y:auto}.title,.close{display:inline}.settingsTitle,.close2{display:inline}.title{color:#000;float:left;font-size:20px;font-weight:bold}.settingsTitle{color:#000;float:left;font-size:30px;font-weight:bold}label.switch,p.switch{display:inline}label.switch{float:right}p.subtitle{color:#000;float:left;font-size:10px;font-weight:bold;margin-top:10px}.close{color:#aaa;float:right;font-size:30px;font-weight:bold}.title{float:left}.close:hover,.close:focus{color:#000;text-decoration:none;cursor:pointer}.close2{color:#aaa;float:right;font-size:30px;font-weight:bold}.title{float:left}.close2:hover,.close2:focus{color:#000;text-decoration:none;cursor:pointer}::-webkit-scrollbar{width:5px}::-webkit-scrollbar-track{background:#f1f1f1}::-webkit-scrollbar-thumb{background:#888}::-webkit-scrollbar-thumb:hover{background:#555}.switch{position:relative;display:inline-block;width:60px;height:34px}.switch input{opacity:0;width:0;height:0}.slider{position:absolute;cursor:pointer;top:0;left:0;right:0;bottom:0;background-color:#ccc;-webkit-transition:.4s;transition:.4s}.slider:before{position:absolute;content:"";height:26px;width:26px;left:4px;bottom:4px;background-color:#fff;-webkit-transition:.4s;transition:.4s}input:checked+.slider{background-color:#2196f3}input:focus+.slider{box-shadow:0 0 1px #2196f3}input:checked+.slider:before{-webkit-transform:translateX(26px);-ms-transform:translateX(26px);transform:translateX(26px)}.slider.round{border-radius:34px}.slider.round:before{border-radius:50%}/*# sourceMappingURL=light.css.map */ diff --git a/assets/css/themes/light.css.map b/assets/css/themes/light.css.map deleted file mode 100644 index 2fc4628d..00000000 --- a/assets/css/themes/light.css.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sourceRoot":"","sources":["../../scss/themes/light.scss"],"names":[],"mappings":"AAAA,KACI,sCACA,gBACA,eAEJ,OACI,aACA,eACA,UACA,kBACA,OACA,MACA,WACA,YACA,cACA,sBACA,gCACA,sCAEJ,IACI,eACA,gBAGJ,WACI,WAGJ,eACI,yBACA,YACA,aACA,YACA,iBACA,gBAGJ,cACE,eAEF,uBACE,eAGF,OACI,WACA,WACA,eACA,iBAGJ,eACE,WACA,WACA,eACA,iBAGF,sBACE,eAEF,aACE,YAGF,WACI,WACA,WACA,eACA,iBACA,gBAEJ,OACI,WACA,YACA,eACA,iBAEJ,OACI,WAGJ,0BAEI,WACA,qBACA,eAGJ,QACE,WACA,YACA,eACA,iBAEF,OACE,WAGF,4BAEE,WACA,qBACA,eAEF,oBACI,UAIJ,0BACI,mBAIJ,0BACI,gBAIJ,gCACI,gBAEJ,QACI,kBACA,qBACA,WACA,YAGF,cACE,UACA,QACA,SAGF,QACE,kBACA,eACA,MACA,OACA,QACA,SACA,sBACA,uBACA,eAGF,eACE,kBACA,WACA,YACA,WACA,SACA,WACA,sBACA,uBACA,eAGF,sBACE,yBAGF,oBACE,2BAGF,6BACE,mCACA,+BACA,2BAIF,cACE,mBAGF,qBACE","file":"light.css"} \ No newline at end of file diff --git a/assets/css/yee.css b/assets/css/yee.css deleted file mode 100644 index 1f11e21e..00000000 --- a/assets/css/yee.css +++ /dev/null @@ -1,438 +0,0 @@ -.mountain { - background-image: url("../img/1.jpeg") -} - -.sunrise { - background-image: url("../img/2.jpeg") -} - -.butterfly { - background-image: url("../img/3.jpeg") -} - -.leaves { - background-image: url("../img/4.jpeg") -} - -.river { - background-image: url("../img/5.jpeg") -} - -.sea { - background-image: url("../img/6.jpeg") -} - -.space { - background-image: url("../img/7.jpeg") -} - -.ice { - background-image: url("../img/8.jpeg") -} - -.waterfall { - background-image: url("../img/9.jpeg") -} - -.lake { - background-image: url("../img/10.jpeg") -} - -.sunset { - background-image: url("../img/11.jpeg") -} - -.desert { - background-image: url("../img/12.jpeg") -} - -.canyon { - background-image: url("../img/13.jpeg") -} - -.rose { - background-image: url("../img/14.jpeg") -} - -.forest { - background-image: url("../img/15.jpeg") -} - -.cherry { - background-image: url("../img/16.jpeg") -} - -.clouds { - background-image: url("../img/17.jpeg") -} - -.winter { - background-image: url("../img/18.jpeg") -} - -.autumn { - background-image: url("../img/19.jpeg") -} - -.flowers { - background-image: url("../img/20.jpeg") -} - -.sunrise { - background-image: url("../img/21.jpeg") -} - -.rocks { - background-image: url("../img/22.jpeg") -} - -.trees { - background-image: url("../img/23.jpeg") -} - -.mountains { - background-image: url("../img/24.jpeg") -} - -.beach { - background-image: url("../img/25.jpeg") -} - -@font-face { - font-family: "Material Icons"; - font-style: normal; - font-weight: 400; - src: url("../font/MaterialIcons-Regular.woff2") format("woff2") -} - -.material-icons { - font-family: "Material Icons"; - font-weight: normal; - font-style: normal; - font-size: 24px; - line-height: 1; - letter-spacing: normal; - text-transform: none; - display: inline-block; - white-space: nowrap; - word-wrap: normal; - direction: ltr; - -moz-font-feature-settings: "liga"; - font-feature-settings: "liga"; - -moz-osx-font-smoothing: grayscale -} - -@font-face { - font-family: "Open Sans"; - src: url("../font/opensans-regular-webfont.woff2") format("woff2"), - url("../font/opensans-regular-webfont.woff") format("woff"); - src: url("../font/roboto-v18-latin-regular.woff2") format("woff2"), - } - -html, -body { - height: 100% -} - -body { - display: flex; - flex-direction: column; - justify-content: space-around; - align-items: center; - margin: 0; - background-size: cover; - background-position: 50%; - background-color: #000; - font-family: "Open Sans"; - color: #fff; - overflow: hidden; -} - -:root { - --shadow-color: #111111CC -} -#withSeconds, #withoutSeconds, #greetingText { - -webkit-touch-callout: none; /* iOS Safari */ - -webkit-user-select: none; /* Safari */ - -khtml-user-select: none; /* Konqueror HTML */ - -moz-user-select: none; /* Firefox */ - -ms-user-select: none; /* Internet Explorer/Edge */ - user-select: none; /* Non-prefixed version, currently - supported by Chrome and Opera */ -} -.greeting, -time, -.quote { - position: absolute; - filter: drop-shadow(var(--shadow-shift) var(--shadow-shift) 0 var(--shadow-color)) -} - -.quote { - padding-top: 15em; - --shadow-shift: 0.125rem; - width: 37.5%; - max-width: 37.5rem; - font-size: 1.5rem; - text-align: center -} - -.quote blockquote { - margin: 0 0 .25rem 0; - line-height: 1.125 -} - -.quote blockquote ::before { - content: "“"; - margin-right: .25ch -} - -.quote blockquote ::after { - content: "”"; - margin-left: .25ch -} - -.quote cite { - font-size: 83.33% -} - -button.settings, -button.news { - background: transparent; - border: none; - color: #fff; - padding: 20px 20px; - text-align: center; - text-decoration: none; - font-size: 20px; - cursor: pointer; - border-radius: 5px; - display: table-cell -} - -.buttons { - position: absolute; - right: 10px; - top: 10px -} - -button.news { - position: absolute; - right: 60px; - top: 0px; -} - -.search-bar { - position: absolute; - left: 20px; - top: 20px; - display: flex; - flex-direction: row; -} - -i.material-icons { - font-size: 30px; - display: inline; - color: #fff -} - -li.items { - list-style: none; - margin: 0; - padding-top: 30px -} - -.modal { - display: none -} - -.modal-content { - max-height: 500px; -} - -.greeting { - text-shadow: 0 0 25px rgba(0,0,0,0.3); - font-size: 3.25rem; - padding-bottom: 10em; - font-weight: bold; - letter-spacing: 2px; -} - -time { - font-size: 12rem; - font-weight: bold; - text-shadow: 0 0 25px rgba(0,0,0,0.3); -} - -.search-bar input[type=text] { - padding: 10px; - font-size: 15px; - border: 5px; - opacity: 0.5; - color: #fff; - font-weight: bold; - margin-left: 5px; - letter-spacing: 1px; -} - -.search-bar button { - font-size: 1px; - border: none; - cursor: pointer; - background: none; - --shadow-shift: 0.4rem; - -} - -.search-bar button i.material-icons { - text-shadow: 0 0 25px rgba(0,0,0,0.3); -} - -.buttons i.material-icons { - text-shadow: 0 0 20px rgba(0,0,0,0.3); - padding-top: 0; -} - -.search-bar input[type=text], .search-bar button { - display: inline -} - -.input.searchText { - flex-grow:2; - border:none; - box-shadow: 0 0 20px rgba(0,0,0,0.3); -} - -.searchbarform { - display:flex; - flex-direction:row; -} - - .dropdown { - position: relative; - display: block; - float: right; - padding: 10px; - border: none; - background: #ecf0f1; - } -label.switch, p.switch { - display: inline; - } - label.switch { - float: right; - } - -img { - max-width: 100%; - margin-top: 20px; -} - -.title { - float: left; -} - -.switch { - position: relative; - display: inline-block; - width: 60px; - height: 34px; - } - - .switch input { - opacity: 0; - width: 0; - height: 0; - } - - .slider { - position: absolute; - cursor: pointer; - top: 0; - left: 0; - right: 0; - bottom: 0; - background-color: #ccc; - -webkit-transition: .4s; - transition: .4s; - } - - .slider:before { - position: absolute; - content: ""; - height: 26px; - width: 26px; - left: 4px; - bottom: 4px; - background-color: white; - -webkit-transition: .4s; - transition: .4s; - } - input:checked + .slider { - background-color: #FF4F4E; - } - - input:focus + .slider { - box-shadow: 0 0 1px #FF4F4E; - } - - input:checked + .slider:before { - -webkit-transform: translateX(26px); - -ms-transform: translateX(26px); - transform: translateX(26px); - } - - /* Rounded sliders */ - .slider.round { - border-radius: 34px; - } - - .slider.round:before { - border-radius: 50%; - } - - .blurslider { - margin-top: 7px; - -webkit-appearance: none; - width: 200px; - height: 15px; - border-radius: 5px; - background: #d3d3d3; - outline: none; - float: right; - } - - - .blurslider::-webkit-slider-thumb { - -webkit-appearance: none; - appearance: none; - width: 25px; - height: 25px; - border-radius: 50%; - background: #FF4F4E; - cursor: pointer; - } - - .blurslider::-moz-range-thumb { - width: 25px; - height: 25px; - border-radius: 50%; - background: #FF4F4E; - cursor: pointer; - } - -::selection { - background: #FF4F4E; - color: #fff; - } - - a { - color: #FF4F4E; - text-decoration: none; - font-weight: bold; - } - - a:hover { - text-decoration: underline; - } - -/*# sourceMappingURL=base.css.map */ diff --git a/assets/firefox.png b/assets/firefox.png new file mode 100644 index 00000000..b3d1ff7e Binary files /dev/null and b/assets/firefox.png differ diff --git a/assets/font/MaterialIcons-Regular.woff2 b/assets/font/MaterialIcons-Regular.woff2 deleted file mode 100644 index 9fa21125..00000000 Binary files a/assets/font/MaterialIcons-Regular.woff2 and /dev/null differ diff --git a/assets/font/opensans-bold-webfont.woff2 b/assets/font/opensans-bold-webfont.woff2 deleted file mode 100644 index 3927443a..00000000 Binary files a/assets/font/opensans-bold-webfont.woff2 and /dev/null differ diff --git a/assets/font/opensans-bolditalic-webfont.woff2 b/assets/font/opensans-bolditalic-webfont.woff2 deleted file mode 100644 index 6b02457e..00000000 Binary files a/assets/font/opensans-bolditalic-webfont.woff2 and /dev/null differ diff --git a/assets/font/opensans-extrabold-webfont.woff2 b/assets/font/opensans-extrabold-webfont.woff2 deleted file mode 100644 index e35bc406..00000000 Binary files a/assets/font/opensans-extrabold-webfont.woff2 and /dev/null differ diff --git a/assets/font/opensans-extrabolditalic-webfont.woff2 b/assets/font/opensans-extrabolditalic-webfont.woff2 deleted file mode 100644 index 084180ec..00000000 Binary files a/assets/font/opensans-extrabolditalic-webfont.woff2 and /dev/null differ diff --git a/assets/font/opensans-lightitalic-webfont.woff2 b/assets/font/opensans-lightitalic-webfont.woff2 deleted file mode 100644 index f3e46568..00000000 Binary files a/assets/font/opensans-lightitalic-webfont.woff2 and /dev/null differ diff --git a/assets/font/opensans-regular-webfont.woff2 b/assets/font/opensans-regular-webfont.woff2 deleted file mode 100644 index b268c67e..00000000 Binary files a/assets/font/opensans-regular-webfont.woff2 and /dev/null differ diff --git a/assets/font/opensans-semibold-webfont.woff2 b/assets/font/opensans-semibold-webfont.woff2 deleted file mode 100644 index 45fda481..00000000 Binary files a/assets/font/opensans-semibold-webfont.woff2 and /dev/null differ diff --git a/assets/font/opensans-semibolditalic-webfont.woff2 b/assets/font/opensans-semibolditalic-webfont.woff2 deleted file mode 100644 index c2018c76..00000000 Binary files a/assets/font/opensans-semibolditalic-webfont.woff2 and /dev/null differ diff --git a/assets/img/favicons/favicon-16x16.png b/assets/img/favicons/favicon-16x16.png deleted file mode 100644 index fe55252c..00000000 Binary files a/assets/img/favicons/favicon-16x16.png and /dev/null differ diff --git a/assets/img/favicons/favicon-32x32.png b/assets/img/favicons/favicon-32x32.png deleted file mode 100644 index 33d42d7f..00000000 Binary files a/assets/img/favicons/favicon-32x32.png and /dev/null differ diff --git a/assets/img/favicons/favicon-96x96.png b/assets/img/favicons/favicon-96x96.png deleted file mode 100644 index a6d78843..00000000 Binary files a/assets/img/favicons/favicon-96x96.png and /dev/null differ diff --git a/assets/img/favicons/favicon.ico b/assets/img/favicons/favicon.ico deleted file mode 100644 index 9afb664f..00000000 Binary files a/assets/img/favicons/favicon.ico and /dev/null differ diff --git a/assets/img/installbackupandsync.exe b/assets/img/installbackupandsync.exe deleted file mode 100644 index a91abb33..00000000 Binary files a/assets/img/installbackupandsync.exe and /dev/null differ diff --git a/assets/img/muesettings.png b/assets/img/muesettings.png deleted file mode 100644 index 97972c2f..00000000 Binary files a/assets/img/muesettings.png and /dev/null differ diff --git a/assets/img/updatenewlogo.png b/assets/img/updatenewlogo.png deleted file mode 100644 index b6283a85..00000000 Binary files a/assets/img/updatenewlogo.png and /dev/null differ diff --git a/assets/js/base.js b/assets/js/base.js deleted file mode 100644 index 658366a4..00000000 --- a/assets/js/base.js +++ /dev/null @@ -1 +0,0 @@ -!function(e){var t={};function o(n){if(t[n])return t[n].exports;var a=t[n]={i:n,l:!1,exports:{}};return e[n].call(a.exports,a,a.exports,o),a.l=!0,a.exports}o.m=e,o.c=t,o.d=function(e,t,n){o.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},o.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},o.t=function(e,t){if(1&t&&(e=o(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(o.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var a in e)o.d(n,a,function(t){return e[t]}.bind(null,a));return n},o.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(t,"a",t),t},o.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},o.p="",o(o.s=0)}([function(e,t,o){e.exports=o(1)},function(e,t,o){const n=o(2);o(8);document.addEventListener("DOMContentLoaded",()=>(n.setDaytimeMsg(),n.setRandBg(),n.setRandQuote(),n.setTime(),n.setWithoutSeconds(),"on"===!localStorage.getItem("seconds")?setInterval(n.setWithoutSeconds,6e4):setInterval(n.setTime,1e3))),document.oncontextmenu=()=>!1;const a=document.getElementById("updateModal"),s=document.getElementById("openUpdateModal"),i=document.getElementsByClassName("close")[0];s.onclick=()=>{a.style.display="block"},i.onclick=()=>{a.style.display="none"},window.onclick=e=>{e.target===a&&(a.style.display="none")};var r=document.getElementById("slider"),c=document.getElementById("blurValue");c.innerHTML=r.value,r.oninput=function(){c.innerHTML=this.value}},function(e,t,o){const n=o(3),a=o(4),s=o(5),i=o(6),r=o(7),c=navigator.language;e.exports=class{static setDaytimeMsg(){s.contains.call(i.itcodes,c)&&a.itMsgSet(),s.contains.call(i.nlcodes,c)&&a.nlMsgSet(),s.contains.call(i.frcodes,c)&&a.frMsgSet(),s.contains.call(i.spcodes,c)&&a.spMsgSet(),s.contains.call(i.ficodes,c)&&a.fiMsgSet(),s.contains.call(i.decodes,c)&&a.spMsgSet(),s.contains.call(i.hecodes,c)&&a.heMsgSet(),s.contains.call(i.rucodes,c)&&a.ruMsgSet(),s.contains.call(i.arcodes,c)&&a.arMsgSet(),s.contains.call(i.svcodes,c)?a.svMsgSet():a.engMsgSet()}static setRandBg(){document.body.classList.add(s.pickFromArray(n))}static setWithoutSeconds(){const e=new Date,t=[s.formatTimeUnit(e.getHours()),s.formatTimeUnit(e.getMinutes())];document.getElementById("withoutSeconds").innerHTML=t.join(":")}static setRandQuote(){const e=s.getRandIndex(r.authors);s.contains.call(i.itcodes,c)&&(document.querySelector("blockquote").innerHTML=`"${r.it[e]}"`),s.contains.call(i.ptcodes,c)&&(document.querySelector("blockquote").innerHTML=`"${r.pt[e]}"`||`"${r.eng[e]}"`),s.contains.call(i.spcodes,c)?document.querySelector("blockquote").innerHTML=`"${r.sp[e]}"`:document.querySelector("blockquote").innerHTML=`"${r.eng[e]}"`,document.querySelector("cite").innerHTML=r.authors[e]}static setTime(){const e=new Date,t=[s.formatTimeUnit(e.getHours()),s.formatTimeUnit(e.getMinutes()),s.formatTimeUnit(e.getSeconds())];document.getElementById("withSeconds").innerHTML=t.join(":")}}},function(e,t){e.exports=["mountain","sunrise","butterfly","leaves","river","sea","space","ice","waterfall","lake","sunset","desert","canyon","rose","forest","cherry","clouds","autumn","winter","flowers","sunrise","rocks","trees","mountains","beach"]},function(e,t){const o=(new Date).getHours();e.exports=class{static engMsgSet(){let e="Good evening";o<12?e="Good morning":o<18&&(e="Good afternoon"),document.querySelector(".greeting").innerHTML=e}static itMsgSet(){let e="Buongiorno";o>18&&(e="Buonasera"),document.querySelector(".greeting").innerHTML=e}static nlMsgSet(){let e="Goedemiddag";o<12?e="Goedemorgen":o>18&&(e="Goedenavond"),document.querySelector(".greeting").innerHTML=e}static frMsgSet(){let e="Bonsoir";o<12?e="Bonjour":o>18&&(e="Bonne après-midi"),document.querySelector(".greeting").innerHTML=e}static spMsgSet(){let e="Buenas Tardes";o<12?e="Buenos Días":o>18&&(e="Buenas Noches"),document.querySelector(".greeting").innerHTML=e}static fiMsgSet(){let e="Hyvää iltaa";o<12?e="Hyvää huomenta":o>18&&(e="Hyvää iltapäivää"),document.querySelector(".greeting").innerHTML=e}static deMsgSet(){let e="Guten Abend";o<12?e="Guten Morgen":o>18&&(e="Guten Nachmittag"),document.querySelector(".greeting").innerHTML=e}static heMsgSet(){let e="ערב טוב";o<12?e="בוקר טוב":o>18&&(e="אחר הצהריים טובים"),document.querySelector(".greeting").innerHTML=e}static ruMsgSet(){let e="Добрый Вечер";o<12?e="добрый утро":o>18&&(e="добрый день"),document.querySelector(".greeting").innerHTML=e}static arMsgSet(){let e="مساء الخير";o<12?e="صباح الخير":o>18&&(e="مساء الخير"),document.querySelector(".greeting").innerHTML=e}static svMsgSet(){let e="God kväll";o<12&&(e="God morgon"),document.querySelector(".greeting").innerHTML=e}}},function(e,t){e.exports=class{static formatTimeUnit(e){return e<10?"0"+e:e}static getRandIndex(e){return Math.floor(Math.random()*(e.length-1))}static pickFromArray(e){return e[Math.floor(Math.random()*(e.length-1))]}static contains(e){const t=e!=e;let o;return(o=t||"function"!=typeof Array.prototype.indexOf?e=>{let o=-1,n=-1;for(o=0;o-1}static getJSON(e,t){var o=new XMLHttpRequest;o.open("GET",e,!0),o.responseType="json",o.onload=()=>{var e=o.status;t(200===e?null:e,o.response)},o.send()}}},function(e,t){e.exports={itcodes:["it","it-IT","it-CH"],nlcodes:["nl","nl-BE"],frcodes:["fr","fr-BE","fr-CA","fr-FR","fr-LU","fr-MC","fr-CH"],ptcodes:["pt","pt-BR"],spcodes:["es","es-AR","es-BO","es-CL","es-CO","es-CR","es-DO","es-EC","es-ES","es-GT","es-HN","es-MX","es-NI","es-PA","es-PE","es-PR","es-PY","es-SV","es-UY","es-VE"],ficodes:["fi"],decodes:["de","de-AT","de-DE","de-LI","de-LU","de-CH"],hecodes:["he"],rucodes:["ru","ru-MO"],arcodes:["ar","ar-DZ","ar-BH","ar-EG","ar-IQ","ar-JO","ar-KW","ar-LB","ar-LY","ar-QA","ar-SA","ar-SY","ar-TN","ar-AE","ar-YE"],svcodes:["sv","sv-FI","sv-SV"]}},function(e,t){e.exports={eng:["Time goes on. So whatever you’re going to do, do it. Do it now. Don’t wait.","All our dreams can come true, if we have the courage to pursue them.","It does not matter how slowly you go as long as you do not stop.","Believe in yourself. You are braver than you think, more talented than you know, and capable of more than you imagine.","If you believe it will work out, you’ll see opportunities. If you believe it won’t, you will see obstacles","Everything you’ve ever wanted is on the other side of fear.","Success is not final, failure is not fatal: it is the courage to continue that counts.","There is only one thing that makes a dream impossible to achieve: the fear of failure.","Your true success in life begins only when you make the commitment to become excellent at what you do.","Believe in yourself, take on your challenges, dig deep within yourself to conquer fears. Never let anyone bring you down. You got to keep going.","Too many of us are not living our dreams because we are living our fears.","Hard times don’t create heroes. It is during the hard times when the ‘hero’ within us is revealed.","If you can tune into your purpose and really align with it, setting goals so that your vision is an expression of that purpose, then life flows much more easily.","Whatever the mind can conceive and believe, it can achieve.","Don’t wish it were easier. Wish you were better.","A champion is defined not by their wins but by how they can recover when they fall.","Motivation comes from working on things we care about.","With the right kind of coaching and determination you can accomplish anything.","Some people look for a beautiful place. Others make a place beautiful.","Life is like riding a bicycle. To keep your balance, you must keep moving."],ita:["Il tempo passa. Quindi qualunque cosa che farai, falla. Falla ora. Non aspettare","Tutti i nostri sogni possono diventare reali, se abbiamo il coraggio di seguirli.","Non importa quanto lentamente vai fino a quando non ti fermi","Credi in te stesso. Sei più coraggioso di quanto pensi, più talentuoso di quanto credi, e capace più di quanto puoi immaginare.","Se ci credi funzionerà, vedrai delle opportunità. Se non ci credi, vedrai solamente ostacoli","Tutti i tuoi desideri sono opposti alla paura","Il successo non è la fine, il fallimento non è fatale: è il coraggio per continuare quello che conta.","C'è solo una cosa che fa i sogni impossibili: la paura di fallire","Il vero successo nella tua vita inizia solo quando fai il sacrificio per diventare eccellente a quello che ami.","Credi in te stesso, sfida i tuoi problemi, scava nel profondo del tuo io per sconfiggere le tue paure. Mai arrendersi per qualcun'altro. Tu devi continuare.","Troppe persone non vivono i loro sogni per vivere nelle loro paure",'Tempi difficili non fanno eroi. È durante i tempi duri che "l\'eroe" in noi viene rivelato.',"Se puoi sintonizzare sul tuo senso e allinearti a quest'ultimo, impostando i tuoi obiettivi in modo che la tua visione sia un'espressione di quel senso, La tua vita scorre molto più facilmente","Qualunque cosa la mente può immaginare e crederese, si può realizzare","Non desiderare che fosse stato più facile. Desidera che tu fossi stato migliore.","Un campione si definisce non dalle sue vittorie ma da come recupera quando cade","La motivazione viene dal lavorare so cose che amiamo","Con il giusto tipo di allenamento e determinazione puoi fare tutto","Alcune persone cercano un posto indimenticabile. Altre lo transformano in un posto mozzafiato.","La vita è come andare in bicicletta. Per tenerti in equilibrio, devi continuare a muoverti"],spa:["El tiempo continúa. Así que lo que sea que vayas a hacer, hazlo. Hazlo ahora. No esperes","Todos nuestros sueños pueden hacerse realidad, si tenemos el coraje de perseguirlos.","No importa qué tan lento vayas, siempre y cuando no te detengas.","Cree en ti mismo. Eres más valiente de lo que crees, más talentoso de lo que sabes y capaz de más de lo que imaginas.","Si crees que funcionará, verás oportunidades. Si crees que no, verás obstáculos ","Todo lo que siempre has querido está al otro lado del miedo","El éxito no es definitivo, el fracaso no es fatal: el coraje para continuar es lo que cuenta","Solo hay una cosa que hace que un sueño sea imposible de lograr: el miedo al fracaso","Tu verdadero éxito en la vida comienza solo cuando te comprometes a ser excelente en lo que haces","Cree en ti mismo, asume tus desafíos, excava profundo dentro de ti mismo para vencer tus miedos. Nunca dejes que nadie te derribe. Tienes que seguir adelante.","Muchos de nosotros no estamos viviendo nuestros sueños porque estamos viviendo nuestros miedos","Los tiempos difíciles no crean héroes. Es durante los momentos difíciles en que se revela el héroe dentro de nosotros.","Si puedes sincornizarte con tu propósito, y realmente alinearte con él, estableciendo metas para que tu visión sea una expresión de ese propósito, entonces la vida fluye mucho más fácilmente","Lo que la mente pueda concebir y creer, lo puede lograr","No desees que sea fácil. Desea ser mejor.","Un campeón se define no por sus victorias, sino por cómo pueden recuperarse cuando caen","La motivación viene de trabajar en cosas que nos importan","Con el entrenamiento y la determinación adecuados, puedes lograr cualquier cosa","Algunas personas buscan un lugar hermoso. Otras, hacen un lugar hermoso."],pt:["O tempo continua. Então o que quer que você vai fazer,faça. Faça agora. Não espere.","Todos os sonhos podem virar verdade,se tivermos a coragem de persegui-los.","Não importa o quão devagar você for,desde que você não pare.","Acredite em si mesmo. Você é mais corajoso que pensa,mais talentoso que sabe,e capaz de mais que imagina.","Se você acredita que vai dar certo,você verá oportunidades. Se você acredita que não vai,você vera obstáculos."],authors:["Robert De Niro","Walt Disney","Confucius","Roy T. Bennett","Wayne Dyer","George Addair","Winston Churchill","Paulo Coelho","Brian Tracy","Chantal Sutherland","Les Brown","Bob Riley","Jack Canfield","Napoleon Hill","Jim Rohn","Serena Williams","Sheryl Sandberg","Reese Witherspoon","Hazrat Inayat Khan","Albert Einstein"]}},function(e,t){const o=document.getElementById("settingsModal"),n=document.getElementById("openSettingsModal"),a=document.getElementsByClassName("close2")[0];n.onclick=()=>{o.style.display="block"},a.onclick=()=>{o.style.display="none"},window.onclick=e=>{e.target===o&&(o.style.display="none")};const s=(e,t)=>{let o=document.getElementsByTagName("link").item(t),n=document.createElement("link");n.setAttribute("rel","stylesheet"),n.setAttribute("type","text/css"),n.setAttribute("href",e),document.getElementsByTagName("head").item(0).replaceChild(n,o)};s(`./assets/css/${localStorage.getItem("theme")}.css`),"off"===localStorage.getItem("quotes")&&(document.getElementById("quoteText").style.display="none",document.getElementById("quoteCheck").checked=!0),"off"===localStorage.getItem("greeting")&&(document.getElementById("greetingText").style.display="none",document.getElementById("greetingCheck").checked=!0),"off"===localStorage.getItem("searchbar")&&(document.getElementById("searchBar").style.display="none",document.getElementById("searchBarCheck").checked=!0),"off"===localStorage.getItem("seconds")&&(document.getElementById("withSeconds").style.display="block",document.getElementById("withoutSeconds").style.display="none"),"on"===localStorage.getItem("seconds")&&(document.getElementById("withSeconds").style.display="none",document.getElementById("withoutSeconds").style.display="block",document.getElementById("secondsCheck").checked=!0),"light"===localStorage.getItem("theme")&&(document.getElementById("check").checked=!0);window.changeTheme=()=>{!0===document.getElementById("check").checked?(s("./assets/css/light.css"),localStorage.setItem("theme","light")):(s("./assets/css/dark.css"),localStorage.setItem("theme","dark"))};window.hideQuotes=()=>{let e=document.getElementById("quoteText");!0===document.getElementById("quoteCheck").checked?(e.style.display="none",localStorage.setItem("quotes","off")):(e.style.display="block",localStorage.setItem("quotes","on"))};window.hideGreeting=()=>{let e=document.getElementById("greetingText");!0===document.getElementById("greetingCheck").checked?(e.style.display="none",localStorage.setItem("greeting","off")):(e.style.display="block",localStorage.setItem("greeting","on"))};window.hideSeconds=()=>{let e=document.getElementById("withSeconds"),t=document.getElementById("withoutSeconds");!1===document.getElementById("secondsCheck").checked&&(t.style.display="none",e.style.display="block",localStorage.setItem("seconds","off")),!0===document.getElementById("secondsCheck").checked?(t.style.display="block",e.style.display="none",localStorage.setItem("seconds","on")):console.log()};window.hideSearchBar=()=>{let e=document.getElementById("searchBar");!0===document.getElementById("searchBarCheck").checked?(e.style.display="none",localStorage.setItem("searchbar","off")):(e.style.display="block",localStorage.setItem("searchbar","on"))};window.setSearchEngine=e=>{localStorage.setItem("engine",e)}}]); \ No newline at end of file diff --git a/assets/js/modules/settings.js b/assets/js/modules/settings.js deleted file mode 100644 index 5170df55..00000000 --- a/assets/js/modules/settings.js +++ /dev/null @@ -1,123 +0,0 @@ -// Settings Modal -const modal2 = document.getElementById('settingsModal'); -const btn2 = document.getElementById('openSettingsModal'); -const span2 = document.getElementsByClassName('close2')[0]; -btn2.onclick = () => { modal2.style.display = 'block'; }; -span2.onclick = () => { modal2.style.display = 'none'; }; -window.onclick = (event) => { if (event.target === modal2) modal2.style.display = 'none'; }; - -// Change theme code -const changeCSS = (cssFile, cssLinkIndex) => { - let oldlink = document.getElementsByTagName('link').item(cssLinkIndex); - let newlink = document.createElement('link'); - - newlink.setAttribute('rel', 'stylesheet'); - newlink.setAttribute('type', 'text/css'); - newlink.setAttribute('href', cssFile); - - document.getElementsByTagName('head').item(0).replaceChild(newlink, oldlink); -}; - -// Load settings -changeCSS(`./assets/css/${localStorage.getItem('theme')}.css`); -if (localStorage.getItem('quotes') === 'off') document.getElementById('quoteText').style.display = 'none', document.getElementById("quoteCheck").checked = true; -if (localStorage.getItem('greeting') === 'off') document.getElementById('greetingText').style.display = 'none', document.getElementById("greetingCheck").checked = true; -if (localStorage.getItem('searchbar') === 'off') document.getElementById('searchBar').style.display = 'none', document.getElementById("searchBarCheck").checked = true; -if (localStorage.getItem('seconds') === 'off') { - document.getElementById('withSeconds').style.display = 'block'; - document.getElementById('withoutSeconds').style.display = 'none'; -} -if (localStorage.getItem('seconds') === 'on') { - document.getElementById('withSeconds').style.display = 'none'; - document.getElementById('withoutSeconds').style.display = 'block'; - document.getElementById("secondsCheck").checked = true; -} -if (localStorage.getItem('theme') === 'light') { - document.getElementById("check").checked = true; -} - -// Settings functions - -// Theme Option -const changeTheme = () => { - if (document.getElementById('check').checked === true) { - changeCSS('./assets/css/light.css'); - localStorage.setItem('theme', 'light'); - } else { - changeCSS('./assets/css/dark.css'); - localStorage.setItem('theme', 'dark'); - } -} - -window.changeTheme = changeTheme; - -// Quotes Option -const hideQuotes = () => { - let quoteText = document.getElementById('quoteText'); - - if (document.getElementById('quoteCheck').checked === true) { - quoteText.style.display = 'none'; - localStorage.setItem('quotes', 'off'); - } - else { - quoteText.style.display = 'block'; - localStorage.setItem('quotes', 'on'); - } -} - -window.hideQuotes = hideQuotes; - -// Greeting Option -const hideGreeting = () => { - let greetingText = document.getElementById('greetingText'); - - if (document.getElementById('greetingCheck').checked === true) { - greetingText.style.display = 'none'; - localStorage.setItem('greeting', 'off'); - } - else { - greetingText.style.display = 'block'; - localStorage.setItem('greeting', 'on'); - } -} - -window.hideGreeting = hideGreeting; - -// Seconds Option -const hideSeconds = () => { - let withSecondsText = document.getElementById('withSeconds'); - let withoutSecondsText = document.getElementById('withoutSeconds'); - - if (document.getElementById('secondsCheck').checked === false) { - withoutSecondsText.style.display = 'none'; - withSecondsText.style.display = 'block'; - localStorage.setItem('seconds', 'off'); - } if (document.getElementById('secondsCheck').checked === true) { - withoutSecondsText.style.display = 'block'; - withSecondsText.style.display = 'none'; - localStorage.setItem('seconds', 'on'); - } - else console.log(); -} - -window.hideSeconds = hideSeconds; - -// Search Bar Option -const hideSearchBar = () => { - let searchBar = document.getElementById('searchBar'); - - if (document.getElementById('searchBarCheck').checked === true) { - searchBar.style.display = 'none'; - localStorage.setItem('searchbar', 'off'); - } - else { - searchBar.style.display = 'block'; - localStorage.setItem('searchbar', 'on'); - } -} -window.hideSearchBar = hideSearchBar; - -// Set Engine -const setSearchEngine = (engine) => { localStorage.setItem('engine', engine); }; - -window.setSearchEngine = setSearchEngine; \ No newline at end of file diff --git a/assets/kofi.png b/assets/kofi.png new file mode 100644 index 00000000..0ee97776 Binary files /dev/null and b/assets/kofi.png differ diff --git a/assets/logo/icon_round.png b/assets/logo/icon_round.png new file mode 100644 index 00000000..fbc7b356 Binary files /dev/null and b/assets/logo/icon_round.png differ diff --git a/assets/logo/icon_square.png b/assets/logo/icon_square.png new file mode 100644 index 00000000..fa6fb603 Binary files /dev/null and b/assets/logo/icon_square.png differ diff --git a/assets/logo/logo_horizontal.png b/assets/logo/logo_horizontal.png new file mode 100644 index 00000000..593cb3c7 Binary files /dev/null and b/assets/logo/logo_horizontal.png differ diff --git a/assets/logo/logo_only.png b/assets/logo/logo_only.png new file mode 100644 index 00000000..4beade37 Binary files /dev/null and b/assets/logo/logo_only.png differ diff --git a/assets/logo/logo_vertical.png b/assets/logo/logo_vertical.png new file mode 100644 index 00000000..8e1a0236 Binary files /dev/null and b/assets/logo/logo_vertical.png differ diff --git a/assets/patreon.png b/assets/patreon.png new file mode 100644 index 00000000..da911f2f Binary files /dev/null and b/assets/patreon.png differ diff --git a/assets/screenshot.jpg b/assets/screenshot.jpg new file mode 100644 index 00000000..5565f5d0 Binary files /dev/null and b/assets/screenshot.jpg differ diff --git a/assets/scss/modules/_buttons.scss b/assets/scss/modules/_buttons.scss deleted file mode 100644 index 614e8cc8..00000000 --- a/assets/scss/modules/_buttons.scss +++ /dev/null @@ -1,42 +0,0 @@ -button.settings, -button.news { - background: transparent; - border: none; - color: #fff; - padding: 20px 20px; - text-align: center; - text-decoration: none; - font-size: 20px; - cursor: pointer; - border-radius: 5px; - display: table-cell -} - -.buttons { - position: absolute; - right: 10px; - top: 10px; - i.material-icons { - text-shadow: 0 0 20px rgba(0, 0, 0, 0.3); - padding-top: 0; - } -} - -button.news { - position: absolute; - right: 60px; - top: 0px; -} - -button.copyButton { - background: transparent; - border: none; - color: #fff; - padding: 20px 20px; - text-align: center; - text-decoration: none; - font-size: 20px; - cursor: pointer; - border-radius: 5px; - display: table-cell -} \ No newline at end of file diff --git a/assets/scss/modules/_font.scss b/assets/scss/modules/_font.scss deleted file mode 100644 index 89b81144..00000000 --- a/assets/scss/modules/_font.scss +++ /dev/null @@ -1,55 +0,0 @@ -/* -█████████████████████████████████████████████████████████████ -██ ██ -██ ███ ███ ██ ██ ███████ ██ -██ ████ ████ ██ ██ ██ ██ -██ ██ ████ ██ ██ ██ █████ ██ -██ ██ ██ ██ ██ ██ ██ ██ -██ ██ ██ ██████ ███████ ██ -██ ██ -██ ██ -██ Copyright 2018-2019 David Ralph (ohlookitsderpy) ██ -██ Licensed under MIT ██ -██ GitHub: https://github.com/ohlookitsderpy/Mue ██ -██ ██ -██ Special thanks to contributors! <3 ██ -█████████████████████████████████████████████████████████████ -*/ - -/* fallback */ -@font-face { - font-family: "Material Icons"; - font-style: normal; - font-weight: 400; - src: url("../font/MaterialIcons-Regular.woff2") format("woff2") -} - -.material-icons { - font-family: "Material Icons"; - font-weight: normal; - font-style: normal; - font-size: 24px; - line-height: 1; - letter-spacing: normal; - text-transform: none; - display: inline-block; - white-space: nowrap; - word-wrap: normal; - direction: ltr; - -moz-font-feature-settings: "liga"; - font-feature-settings: "liga"; - -moz-osx-font-smoothing: grayscale -} - -@font-face { - font-family: "Open Sans"; - src: url("../font/opensans-regular-webfont.woff2") format("woff2"), - url("../font/opensans-regular-webfont.woff") format("woff"); - src: url("../font/roboto-v18-latin-regular.woff2") format("woff2"), -} - -i.material-icons { - font-size: 30px; - display: inline; - color: #fff -} \ No newline at end of file diff --git a/assets/scss/modules/_search.scss b/assets/scss/modules/_search.scss deleted file mode 100644 index 55178aa7..00000000 --- a/assets/scss/modules/_search.scss +++ /dev/null @@ -1,58 +0,0 @@ -/* -█████████████████████████████████████████████████████████████ -██ ██ -██ ███ ███ ██ ██ ███████ ██ -██ ████ ████ ██ ██ ██ ██ -██ ██ ████ ██ ██ ██ █████ ██ -██ ██ ██ ██ ██ ██ ██ ██ -██ ██ ██ ██████ ███████ ██ -██ ██ -██ ██ -██ Copyright 2018-2019 David Ralph (ohlookitsderpy) ██ -██ Licensed under MIT ██ -██ GitHub: https://github.com/ohlookitsderpy/Mue ██ -██ ██ -██ Special thanks to contributors! <3 ██ -█████████████████████████████████████████████████████████████ -*/ - -.search-bar { - position: absolute; - left: 20px; - top: 20px; - display: flex; - flex-direction: row; - button { - font-size: 1px; - border: none; - cursor: pointer; - background: none; - --shadow-shift: 0.4rem; - i.material-icons { - text-shadow: 0 0 25px rgba(0, 0, 0, 0.3); - } - display: inline; - } - input[type=text] { - padding: 10px; - font-size: 15px; - border: 5px; - opacity: 0.5; - color: #fff; - font-weight: bold; - margin-left: 5px; - letter-spacing: 1px; - display: inline; - } -} - -.input.searchText { - flex-grow: 2; - border: none; - box-shadow: 0 0 20px rgba(0, 0, 0, 0.3); -} - -.searchbarform { - display: flex; - flex-direction: row; -} \ No newline at end of file diff --git a/assets/scss/modules/_settings-modal.scss b/assets/scss/modules/_settings-modal.scss deleted file mode 100644 index 3c8604c5..00000000 --- a/assets/scss/modules/_settings-modal.scss +++ /dev/null @@ -1,182 +0,0 @@ -button.settings { - background: transparent; - border: none; - color: white; - padding: 20px 20px; - text-align: center; - text-decoration: none; - font-size: 20px; - cursor: pointer; - border-radius: 5px; - display: table-cell; -} - -.buttons { - position: absolute; - right: 10px; - top: 10px; -} - -i.material-icons { - font-size: 30px; - display: inline; - color: #ffffff; -} - -li.items { - list-style: none; - margin: 0; - padding-top: 30px; -} - -.modal { - display: none; -} - - -.switch { - position: relative; - display: inline-block; - width: 60px; - height: 34px; - - input { - opacity: 0; - width: 0; - height: 0; - } -} - -.slider { - position: absolute; - cursor: pointer; - top: 0; - left: 0; - right: 0; - bottom: 0; - background-color: #ccc; - -webkit-transition: .4s; - transition: .4s; - - :before { - position: absolute; - content: ""; - height: 26px; - width: 26px; - left: 4px; - bottom: 4px; - background-color: white; - -webkit-transition: .4s; - transition: .4s; - } -} - -input:checked+.slider { - background-color: #FF4F4E; -} - -input:focus+.slider { - box-shadow: 0 0 1px #FF4F4E; -} - -input:checked+.slider:before { - -webkit-transform: translateX(26px); - -ms-transform: translateX(26px); - transform: translateX(26px); -} - -.slider { - position: absolute; - cursor: pointer; - top: 0; - left: 0; - right: 0; - bottom: 0; - background-color: #ccc; - -webkit-transition: .4s; - transition: .4s; - border-radius: 34px; - } - - .slider:before { - position: absolute; - content: ""; - height: 26px; - width: 26px; - left: 4px; - bottom: 4px; - background-color: white; - -webkit-transition: .4s; - transition: .4s; - border-radius: 50%; - } - -.title { - float: left; -} - -.blurslider { - margin-top: 7px; - -webkit-appearance: none; - width: 200px; - height: 15px; - border-radius: 5px; - background: #d3d3d3; - outline: none; - float: right; - - ::-webkit-slider-thumb { - -webkit-appearance: none; - appearance: none; - width: 25px; - height: 25px; - border-radius: 50%; - background: #FF4F4E; - cursor: pointer; - } - - ::-moz-range-thumb { - width: 25px; - height: 25px; - border-radius: 50%; - background: #FF4F4E; - cursor: pointer; - } -} - -.dropdown { - position: relative; - display: block; - float: right; - padding: 10px; - border: none; - background: #ecf0f1; -} - -label.switch, -p.switch { - display: inline; -} - -label.switch { - float: right; -} - -li.items { - list-style: none; - margin: 0; - padding-top: 30px -} - -.modal { - display: none -} - -.modal-content { - max-height: 500px; -} - -img { - max-width: 100%; - margin-top: 20px; -} \ No newline at end of file diff --git a/assets/scss/themes/dark.scss b/assets/scss/themes/dark.scss deleted file mode 100644 index 49d1a1f2..00000000 --- a/assets/scss/themes/dark.scss +++ /dev/null @@ -1,124 +0,0 @@ -a { - color: #ffffff; -} - -.modal { - display: none; - position: fixed; - z-index: 1; - padding-top: 100px; - left: 0; - top: 0; - width: 100%; - height: 100%; - overflow: auto; - background-color: rgb(0, 0, 0); - background-color: rgba(0, 0, 0, 0.4); -} - -img { - max-width: 100%; - margin-top: 20px; -} - -h1, -h2, -h3, -p { - color: #ffffff; -} - -.modal-content { - background-color: #2d3436; - margin: auto; - padding: 30px; - width: 450px; - max-height: 600px; - overflow-y: auto; -} - -.title, -.close, -.settingsTitle, -.close2 { - display: inline; -} - -.title { - color: #ffffff; - float: left; - font-size: 20px; - font-weight: bold; -} - -.settingsTitle { - color: #ffffff; - float: left; - font-size: 30px; - font-weight: bold; -} - -p.subtitle { - color: #ffffff; - float: left; - font-size: 10px; - font-weight: bold; - margin-top: 10px; -} - -.close { - color: #ffffff; - float: right; - font-size: 30px; - font-weight: bold; -} - -.title { - float: left; -} - -label.switch, -p.switch { - display: inline; -} - -label.switch { - float: right; -} - -.close:hover, -.close:focus { - color: #bdc3c7; - text-decoration: none; - cursor: pointer; -} - -.close2 { - color: #ffffff; - float: right; - font-size: 30px; - font-weight: bold; -} - -.close2:hover, -.close2:focus { - color: #bdc3c7; - text-decoration: none; - cursor: pointer; -} - -::-webkit-scrollbar { - width: 5px; -} - -::-webkit-scrollbar-track { - background: #2d3436; -} - -::-webkit-scrollbar-thumb { - background: #34495e; -} - -::-webkit-scrollbar-thumb:hover { - background: #2c3e50; -} \ No newline at end of file diff --git a/index.html b/index.html deleted file mode 100644 index b02aa947..00000000 --- a/index.html +++ /dev/null @@ -1,162 +0,0 @@ - - - - - - - - - - New Tab - - - - - - - - - - -
- - - - -
- -
- - - - -
- - -
- - -
- - - - - \ No newline at end of file diff --git a/package.json b/package.json new file mode 100644 index 00000000..e26a1cdc --- /dev/null +++ b/package.json @@ -0,0 +1,17 @@ +{ + "name": "mue", + "description": "Fast, open and free-to-use new tab page for most modern browsers", + "author": "ohlookitsderpy", + "license": "MIT", + "repository": "https://github.com/ohlookitsderpy/Mue", + "scripts": { + "sass-watch": "sass --watch src/assets/scss:src/assets/css --style compressed", + "js-watch": "webpack --progress --watch" + }, + "devDependencies": { + "eslint": "6.0.0", + "sass": "1.21.0", + "webpack": "4.35.0", + "webpack-cli": "3.3.4" + } +} diff --git a/renovate.json b/renovate.json new file mode 100644 index 00000000..f45d8f11 --- /dev/null +++ b/renovate.json @@ -0,0 +1,5 @@ +{ + "extends": [ + "config:base" + ] +} diff --git a/assets/css/animate.css b/src/assets/css/animate.css similarity index 100% rename from assets/css/animate.css rename to src/assets/css/animate.css diff --git a/src/assets/css/base.css b/src/assets/css/base.css new file mode 100644 index 00000000..032f3c98 --- /dev/null +++ b/src/assets/css/base.css @@ -0,0 +1 @@ +.mountain{background-image:url("../img/1.jpeg")}.sunrise{background-image:url("../img/2.jpeg")}.butterfly{background-image:url("../img/3.jpeg")}.leaves{background-image:url("../img/4.jpeg")}.river{background-image:url("../img/5.jpeg")}.sea{background-image:url("../img/6.jpeg")}.space{background-image:url("../img/7.jpeg")}.ice{background-image:url("../img/8.jpeg")}.waterfall{background-image:url("../img/9.jpeg")}.lake{background-image:url("../img/10.jpeg")}.sunset{background-image:url("../img/11.jpeg")}.desert{background-image:url("../img/12.jpeg")}.canyon{background-image:url("../img/13.jpeg")}.rose{background-image:url("../img/14.jpeg")}.forest{background-image:url("../img/15.jpeg")}.cherry{background-image:url("../img/16.jpeg")}.clouds{background-image:url("../img/17.jpeg")}.winter{background-image:url("../img/18.jpeg")}.autumn{background-image:url("../img/19.jpeg")}.flowers{background-image:url("../img/20.jpeg")}.sunrise{background-image:url("../img/21.jpeg")}.rocks{background-image:url("../img/22.jpeg")}.trees{background-image:url("../img/23.jpeg")}.mountains{background-image:url("../img/24.jpeg")}.beach{background-image:url("../img/25.jpeg")}html,body{height:100%}body{display:flex;flex-direction:column;justify-content:space-around;align-items:center;margin:0;background-size:cover;background-position:50%;background-color:#000;font-family:"Roboto";color:#fff;overflow:hidden;-moz-user-select:none;user-select:none}@font-face{font-family:"Roboto";font-style:normal;font-weight:400;src:local("Roboto"),local("Roboto-Regular"),url("../font/roboto-v18-latin-regular.woff2") format("woff2")}:root{--shadow-color: #111111CC}.greeting,time,.quote{filter:drop-shadow(var(--shadow-shift) var(--shadow-shift) 0 var(--shadow-color))}.quote{--shadow-shift: 0.125rem;width:37.5%;max-width:37.5rem;font-size:1.5rem;text-align:center}.quote blockquote{margin:0 0 .25rem 0;line-height:1.125}.quote blockquote ::before{content:"“";margin-right:.25ch}.quote blockquote ::after{content:"”";margin-left:.25ch}.quote cite{font-size:83.33%}.greeting{--shadow-shift: 0.2rem;font-size:3.25rem}time{--shadow-shift: 0.4rem;font-size:12rem}button.settings{background:transparent;border:none;color:#fff;padding:20px 20px;text-align:center;text-decoration:none;font-size:20px;cursor:pointer;border-radius:5px;display:table-cell}.buttons{position:absolute;right:10px;top:10px}i.material-icons{font-size:30px;display:inline;color:#fff}li.items{list-style:none;margin:0;padding-top:30px}/*# sourceMappingURL=base.css.map */ diff --git a/src/assets/css/base.css.map b/src/assets/css/base.css.map new file mode 100644 index 00000000..adf34400 --- /dev/null +++ b/src/assets/css/base.css.map @@ -0,0 +1 @@ +{"version":3,"sourceRoot":"","sources":["../scss/modules/_bg.scss","../scss/modules/_misc.scss","../scss/modules/_quote.scss","../scss/modules/_time-greeting.scss","../scss/modules/_settings.scss"],"names":[],"mappings":"CAkBA,gDACA,+CACA,iDACA,8CACA,6CACA,2CACA,6CACA,2CACA,iDACA,6CACA,+CACA,+CACA,+CACA,6CACA,+CACA,+CACA,+CACA,+CACA,+CACA,gDACA,gDACA,8CACA,8CACA,kDACA,8CCzCA,sBACA,KAEC,aACA,sBACA,6BACA,mBAEA,SAEA,sBACA,wBACA,sBAEA,qBACA,WAEA,gBAEG,sBACH,iBAID,WACC,qBACA,kBACA,gBACA,0GAKD,MACC,0BAGD,sBAGC,kFCvBD,OACI,yBAEA,YACA,kBAEA,iBACA,kBAEA,kBACI,oBACA,kBAEA,2BACI,YACA,mBAGJ,0BACI,YACA,kBAIR,YACI,iBCvBR,UACC,uBACA,kBAKD,KACC,uBACA,gBC7BD,gBACI,uBACA,YACA,WACA,kBACA,kBACA,qBACA,eACA,eACA,kBACA,mBAGJ,SACI,kBACA,WACA,SAGJ,iBACI,eACA,eACA,WAGJ,SACI,gBACA,SACA","file":"base.css"} \ No newline at end of file diff --git a/assets/css/dark.css b/src/assets/css/dark.css similarity index 57% rename from assets/css/dark.css rename to src/assets/css/dark.css index c28ca4a0..41a190fe 100644 --- a/assets/css/dark.css +++ b/src/assets/css/dark.css @@ -1,4 +1,8 @@ - +body { + font-family: 'Noto Sans HK', sans-serif; + background: #2d3436; + font-size: 20px; +} a { color: #ffffff; @@ -15,6 +19,11 @@ a { overflow: auto; /* Enable scroll if needed */ background-color: rgb(0,0,0); /* Fallback color */ background-color: rgba(0,0,0,0.4); /* Black w/ opacity */ + font-family: 'Noto Sans HK', sans-serif; +} +img { + max-width: 100%; + margin-top: 20px; } h1, h2, h3, p { @@ -26,7 +35,7 @@ h1, h2, h3, p { margin: auto; padding: 30px; width: 450px; - max-height: 800px; + max-height: 600px; overflow-y: auto; } @@ -58,6 +67,9 @@ p.subtitle { font-size: 30px; font-weight: bold; } +.title { + float: left; +} label.switch, p.switch { display: inline; @@ -79,6 +91,10 @@ label.switch { font-size: 30px; font-weight: bold; } +.title { + float: left; +} + .close2:hover, .close2:focus { color: #bdc3c7; @@ -105,11 +121,62 @@ label.switch { background: #2c3e50; } -.drop-btn { - color: #fff; -} - -.dropdown { - background: #2d3436; - color: #fff; -} \ No newline at end of file +.switch { + position: relative; + display: inline-block; + width: 60px; + height: 34px; + } + + .switch input { + opacity: 0; + width: 0; + height: 0; + } + + .slider { + position: absolute; + cursor: pointer; + top: 0; + left: 0; + right: 0; + bottom: 0; + background-color: #ccc; + -webkit-transition: .4s; + transition: .4s; + } + + .slider:before { + position: absolute; + content: ""; + height: 26px; + width: 26px; + left: 4px; + bottom: 4px; + background-color: white; + -webkit-transition: .4s; + transition: .4s; + } + + input:checked + .slider { + background-color: #2196F3; + } + + input:focus + .slider { + box-shadow: 0 0 1px #2196F3; + } + + input:checked + .slider:before { + -webkit-transform: translateX(26px); + -ms-transform: translateX(26px); + transform: translateX(26px); + } + + /* Rounded sliders */ + .slider.round { + border-radius: 34px; + } + + .slider.round:before { + border-radius: 50%; + } diff --git a/assets/scss/themes/light.scss b/src/assets/css/light.css similarity index 100% rename from assets/scss/themes/light.scss rename to src/assets/css/light.css diff --git a/assets/font/roboto-v18-latin-regular.woff2 b/src/assets/font/roboto-v18-latin-regular.woff2 similarity index 100% rename from assets/font/roboto-v18-latin-regular.woff2 rename to src/assets/font/roboto-v18-latin-regular.woff2 diff --git a/assets/img/1.jpeg b/src/assets/img/1.jpeg similarity index 100% rename from assets/img/1.jpeg rename to src/assets/img/1.jpeg diff --git a/assets/img/10.jpeg b/src/assets/img/10.jpeg similarity index 100% rename from assets/img/10.jpeg rename to src/assets/img/10.jpeg diff --git a/assets/img/11.jpeg b/src/assets/img/11.jpeg similarity index 100% rename from assets/img/11.jpeg rename to src/assets/img/11.jpeg diff --git a/assets/img/12.jpeg b/src/assets/img/12.jpeg similarity index 100% rename from assets/img/12.jpeg rename to src/assets/img/12.jpeg diff --git a/assets/img/13.jpeg b/src/assets/img/13.jpeg similarity index 100% rename from assets/img/13.jpeg rename to src/assets/img/13.jpeg diff --git a/assets/img/14.jpeg b/src/assets/img/14.jpeg similarity index 100% rename from assets/img/14.jpeg rename to src/assets/img/14.jpeg diff --git a/assets/img/15.jpeg b/src/assets/img/15.jpeg similarity index 100% rename from assets/img/15.jpeg rename to src/assets/img/15.jpeg diff --git a/assets/img/16.jpeg b/src/assets/img/16.jpeg similarity index 100% rename from assets/img/16.jpeg rename to src/assets/img/16.jpeg diff --git a/assets/img/17.jpeg b/src/assets/img/17.jpeg similarity index 100% rename from assets/img/17.jpeg rename to src/assets/img/17.jpeg diff --git a/assets/img/18.jpeg b/src/assets/img/18.jpeg similarity index 100% rename from assets/img/18.jpeg rename to src/assets/img/18.jpeg diff --git a/assets/img/19.jpeg b/src/assets/img/19.jpeg similarity index 100% rename from assets/img/19.jpeg rename to src/assets/img/19.jpeg diff --git a/assets/img/2.jpeg b/src/assets/img/2.jpeg similarity index 100% rename from assets/img/2.jpeg rename to src/assets/img/2.jpeg diff --git a/assets/img/20.jpeg b/src/assets/img/20.jpeg similarity index 100% rename from assets/img/20.jpeg rename to src/assets/img/20.jpeg diff --git a/assets/img/21.jpeg b/src/assets/img/21.jpeg similarity index 100% rename from assets/img/21.jpeg rename to src/assets/img/21.jpeg diff --git a/assets/img/22.jpeg b/src/assets/img/22.jpeg similarity index 100% rename from assets/img/22.jpeg rename to src/assets/img/22.jpeg diff --git a/assets/img/23.jpeg b/src/assets/img/23.jpeg similarity index 100% rename from assets/img/23.jpeg rename to src/assets/img/23.jpeg diff --git a/assets/img/24.jpeg b/src/assets/img/24.jpeg similarity index 100% rename from assets/img/24.jpeg rename to src/assets/img/24.jpeg diff --git a/assets/img/25.jpeg b/src/assets/img/25.jpeg similarity index 100% rename from assets/img/25.jpeg rename to src/assets/img/25.jpeg diff --git a/assets/img/3.jpeg b/src/assets/img/3.jpeg similarity index 100% rename from assets/img/3.jpeg rename to src/assets/img/3.jpeg diff --git a/assets/img/4.jpeg b/src/assets/img/4.jpeg similarity index 100% rename from assets/img/4.jpeg rename to src/assets/img/4.jpeg diff --git a/assets/img/5.jpeg b/src/assets/img/5.jpeg similarity index 100% rename from assets/img/5.jpeg rename to src/assets/img/5.jpeg diff --git a/assets/img/6.jpeg b/src/assets/img/6.jpeg similarity index 100% rename from assets/img/6.jpeg rename to src/assets/img/6.jpeg diff --git a/assets/img/7.jpeg b/src/assets/img/7.jpeg similarity index 100% rename from assets/img/7.jpeg rename to src/assets/img/7.jpeg diff --git a/assets/img/8.jpeg b/src/assets/img/8.jpeg similarity index 100% rename from assets/img/8.jpeg rename to src/assets/img/8.jpeg diff --git a/assets/img/9.jpeg b/src/assets/img/9.jpeg similarity index 100% rename from assets/img/9.jpeg rename to src/assets/img/9.jpeg diff --git a/assets/img/logo.png b/src/assets/img/logo.png similarity index 100% rename from assets/img/logo.png rename to src/assets/img/logo.png diff --git a/src/assets/js/base.js b/src/assets/js/base.js new file mode 100644 index 00000000..2ac13408 --- /dev/null +++ b/src/assets/js/base.js @@ -0,0 +1 @@ +!function(e){var o={};function t(n){if(o[n])return o[n].exports;var a=o[n]={i:n,l:!1,exports:{}};return e[n].call(a.exports,a,a.exports,t),a.l=!0,a.exports}t.m=e,t.c=o,t.d=function(e,o,n){t.o(e,o)||Object.defineProperty(e,o,{enumerable:!0,get:n})},t.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},t.t=function(e,o){if(1&o&&(e=t(e)),8&o)return e;if(4&o&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(t.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&o&&"string"!=typeof e)for(var a in e)t.d(n,a,function(o){return e[o]}.bind(null,a));return n},t.n=function(e){var o=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(o,"a",o),o},t.o=function(e,o){return Object.prototype.hasOwnProperty.call(e,o)},t.p="",t(t.s=0)}([function(e,o,t){e.exports=t(1)},function(e,o,t){const n=t(2);document.addEventListener("DOMContentLoaded",()=>{n.setDaytimeMsg(),n.setRandBg(),n.setRandQuote(),n.setTime(),setInterval(n.setTime,1e3)}),document.oncontextmenu=()=>!1;const a=document.getElementById("settingsModal"),i=document.getElementById("openSettingsModal"),r=document.getElementsByClassName("close2")[0];i.onclick=()=>{a.style.display="block"},r.onclick=()=>{a.style.display="none"},window.onclick=e=>{e.target===a&&(a.style.display="none")}},function(e,o,t){const n=t(3),a=t(4),i=t(5),r=t(6),s=t(7),c=navigator.language;e.exports=class{static setDaytimeMsg(){i.contains.call(r.itcodes,c)&&a.itMsgSet(),i.contains.call(r.nlcodes,c)&&a.nlMsgSet(),i.contains.call(r.frcodes,c)&&a.frMsgSet(),i.contains.call(r.spcodes,c)&&a.spMsgSet(),i.contains.call(r.ficodes,c)&&a.fiMsgSet(),i.contains.call(r.decodes,c)&&a.spMsgSet(),i.contains.call(r.hecodes,c)&&a.heMsgSet(),i.contains.call(r.rucodes,c)&&a.ruMsgSet(),i.contains.call(r.arcodes,c)&&a.arMsgSet(),i.contains.call(r.svcodes,c)?a.svMsgSet():a.engMsgSet()}static setRandBg(){document.body.classList.add(i.pickFromArray(n))}static setRandQuote(){const e=i.getRandIndex(s.authors);i.contains.call(r.itcodes,c)&&(document.querySelector("blockquote").innerHTML=`"${s.it[e]}"`),i.contains.call(r.ptcodes,c)&&(document.querySelector("blockquote").innerHTML=`"${s.pt[e]}"`||`"${s.eng[e]}"`),i.contains.call(r.spcodes,c)?document.querySelector("blockquote").innerHTML=`"${s.sp[e]}"`:document.querySelector("blockquote").innerHTML=`"${s.eng[e]}"`,document.querySelector("cite").innerHTML=s.authors[e]}static setTime(){const e=new Date,o=[i.formatTimeUnit(e.getHours()),i.formatTimeUnit(e.getMinutes()),i.formatTimeUnit(e.getSeconds())];document.querySelector("time").innerHTML=o.join(":")}}},function(e,o){e.exports=["mountain","sunrise","butterfly","leaves","river","sea","space","ice","waterfall","lake","sunset","desert","canyon","rose","forest","cherry","clouds","autumn","winter","flowers","sunrise","rocks","trees","mountains","beach"]},function(e,o){const t=(new Date).getHours();e.exports=class{static engMsgSet(){let e="Good evening";t<12?e="Good morning":t<18&&(e="Good afternoon"),document.querySelector(".greeting").innerHTML=e}static itMsgSet(){let e="Buongiorno";t>18&&(e="Buonasera"),document.querySelector(".greeting").innerHTML=e}static nlMsgSet(){let e="Goedemiddag";t<12?e="Goedemorgen":t>18&&(e="Goedenavond"),document.querySelector(".greeting").innerHTML=e}static frMsgSet(){let e="Bonsoir";t<12?e="Bonjour":t>18&&(e="Bonne après-midi"),document.querySelector(".greeting").innerHTML=e}static spMsgSet(){let e="Buenas Tardes";t<12?e="Buenos Días":t>18&&(e="Buenas Noches"),document.querySelector(".greeting").innerHTML=e}static fiMsgSet(){let e="Hyvää iltaa";t<12?e="Hyvää huomenta":t>18&&(e="Hyvää iltapäivää"),document.querySelector(".greeting").innerHTML=e}static deMsgSet(){let e="Guten Abend";t<12?e="Guten Morgen":t>18&&(e="Guten Nachmittag"),document.querySelector(".greeting").innerHTML=e}static heMsgSet(){let e="ערב טוב";t<12?e="בוקר טוב":t>18&&(e="אחר הצהריים טובים"),document.querySelector(".greeting").innerHTML=e}static ruMsgSet(){let e="Добрый Вечер";t<12?e="добрый утро":t>18&&(e="добрый день"),document.querySelector(".greeting").innerHTML=e}static arMsgSet(){let e="مساء الخير";t<12?e="صباح الخير":t>18&&(e="مساء الخير"),document.querySelector(".greeting").innerHTML=e}static svMsgSet(){let e="God kväll";t<12&&(e="God morgon"),document.querySelector(".greeting").innerHTML=e}}},function(e,o){e.exports=class{static formatTimeUnit(e){return e<10?"0"+e:e}static getRandIndex(e){return Math.floor(Math.random()*(e.length-1))}static pickFromArray(e){return e[Math.floor(Math.random()*(e.length-1))]}static contains(e){const o=e!=e;let t;return(t=o||"function"!=typeof Array.prototype.indexOf?e=>{let t=-1,n=-1;for(t=0;t-1}}},function(e,o){e.exports={itcodes:["it","it-IT","it-CH"],nlcodes:["nl","nl-BE"],frcodes:["fr","fr-BE","fr-CA","fr-FR","fr-LU","fr-MC","fr-CH"],ptcodes:["pt","pt-BR"],spcodes:["es","es-AR","es-BO","es-CL","es-CO","es-CR","es-DO","es-EC","es-ES","es-GT","es-HN","es-MX","es-NI","es-PA","es-PE","es-PR","es-PY","es-SV","es-UY","es-VE"],ficodes:["fi"],decodes:["de","de-AT","de-DE","de-LI","de-LU","de-CH"],hecodes:["he"],rucodes:["ru","ru-MO"],arcodes:["ar","ar-DZ","ar-BH","ar-EG","ar-IQ","ar-JO","ar-KW","ar-LB","ar-LY","ar-QA","ar-SA","ar-SY","ar-TN","ar-AE","ar-YE"],svcodes:["sv","sv-FI","sv-SV"]}},function(e,o){e.exports={eng:["Time goes on. So whatever you’re going to do, do it. Do it now. Don’t wait.","All our dreams can come true, if we have the courage to pursue them.","It does not matter how slowly you go as long as you do not stop.","Believe in yourself. You are braver than you think, more talented than you know, and capable of more than you imagine.","If you believe it will work out, you’ll see opportunities. If you believe it won’t, you will see obstacles","Everything you’ve ever wanted is on the other side of fear.","Success is not final, failure is not fatal: it is the courage to continue that counts.","There is only one thing that makes a dream impossible to achieve: the fear of failure.","Your true success in life begins only when you make the commitment to become excellent at what you do.","Believe in yourself, take on your challenges, dig deep within yourself to conquer fears. Never let anyone bring you down. You got to keep going.","Too many of us are not living our dreams because we are living our fears.","Hard times don’t create heroes. It is during the hard times when the ‘hero’ within us is revealed.","If you can tune into your purpose and really align with it, setting goals so that your vision is an expression of that purpose, then life flows much more easily.","Whatever the mind can conceive and believe, it can achieve.","Don’t wish it were easier. Wish you were better.","A champion is defined not by their wins but by how they can recover when they fall.","Motivation comes from working on things we care about.","With the right kind of coaching and determination you can accomplish anything.","Some people look for a beautiful place. Others make a place beautiful.","Life is like riding a bicycle. To keep your balance, you must keep moving."],ita:["Il tempo passa. Quindi qualunque cosa che farai, falla. Falla ora. Non aspettare","Tutti i nostri sogni possono diventare reali, se abbiamo il coraggio di seguirli.","Non importa quanto lentamente vai fino a quando non ti fermi","Credi in te stesso. Sei più coraggioso di quanto pensi, più talentuoso di quanto credi, e capace più di quanto puoi immaginare.","Se ci credi funzionerà, vedrai delle opportunità. Se non ci credi, vedrai solamente ostacoli","Tutti i tuoi desideri sono opposti alla paura","Il successo non è la fine, il fallimento non è fatale: è il coraggio per continuare quello che conta.","C'è solo una cosa che fa i sogni impossibili: la paura di fallire","Il vero successo nella tua vita inizia solo quando fai il sacrificio per diventare eccellente a quello che ami.","Credi in te stesso, sfida i tuoi problemi, scava nel profondo del tuo io per sconfiggere le tue paure. Mai arrendersi per qualcun'altro. Tu devi continuare.","Troppe persone non vivono i loro sogni per vivere nelle loro paure",'Tempi difficili non fanno eroi. È durante i tempi duri che "l\'eroe" in noi viene rivelato.',"Se puoi sintonizzare sul tuo senso e allinearti a quest'ultimo, impostando i tuoi obiettivi in modo che la tua visione sia un'espressione di quel senso, La tua vita scorre molto più facilmente","Qualunque cosa la mente può immaginare e crederese, si può realizzare","Non desiderare che fosse stato più facile. Desidera che tu fossi stato migliore.","Un campione si definisce non dalle sue vittorie ma da come recupera quando cade","La motivazione viene dal lavorare so cose che amiamo","Con il giusto tipo di allenamento e determinazione puoi fare tutto","Alcune persone cercano un posto indimenticabile. Altre lo transformano in un posto mozzafiato.","La vita è come andare in bicicletta. Per tenerti in equilibrio, devi continuare a muoverti"],spa:["El tiempo continúa. Así que lo que sea que vayas a hacer, hazlo. Hazlo ahora. No esperes","Todos nuestros sueños pueden hacerse realidad, si tenemos el coraje de perseguirlos.","No importa qué tan lento vayas, siempre y cuando no te detengas.","Cree en ti mismo. Eres más valiente de lo que crees, más talentoso de lo que sabes y capaz de más de lo que imaginas.","Si crees que funcionará, verás oportunidades. Si crees que no, verás obstáculos ","Todo lo que siempre has querido está al otro lado del miedo","El éxito no es definitivo, el fracaso no es fatal: el coraje para continuar es lo que cuenta","Solo hay una cosa que hace que un sueño sea imposible de lograr: el miedo al fracaso","Tu verdadero éxito en la vida comienza solo cuando te comprometes a ser excelente en lo que haces","Cree en ti mismo, asume tus desafíos, excava profundo dentro de ti mismo para vencer tus miedos. Nunca dejes que nadie te derribe. Tienes que seguir adelante.","Muchos de nosotros no estamos viviendo nuestros sueños porque estamos viviendo nuestros miedos","Los tiempos difíciles no crean héroes. Es durante los momentos difíciles en que se revela el héroe dentro de nosotros.","Si puedes sincornizarte con tu propósito, y realmente alinearte con él, estableciendo metas para que tu visión sea una expresión de ese propósito, entonces la vida fluye mucho más fácilmente","Lo que la mente pueda concebir y creer, lo puede lograr","No desees que sea fácil. Desea ser mejor.","Un campeón se define no por sus victorias, sino por cómo pueden recuperarse cuando caen","La motivación viene de trabajar en cosas que nos importan","Con el entrenamiento y la determinación adecuados, puedes lograr cualquier cosa","Algunas personas buscan un lugar hermoso. Otras, hacen un lugar hermoso."],pt:["O tempo continua. Então o que quer que você vai fazer,faça. Faça agora. Não espere.","Todos os sonhos podem virar verdade,se tivermos a coragem de persegui-los.","Não importa o quão devagar você for,desde que você não pare.","Acredite em si mesmo. Você é mais corajoso que pensa,mais talentoso que sabe,e capaz de mais que imagina.","Se você acredita que vai dar certo,você verá oportunidades. Se você acredita que não vai,você vera obstáculos."],authors:["Robert De Niro","Walt Disney","Confucius","Roy T. Bennett","Wayne Dyer","George Addair","Winston Churchill","Paulo Coelho","Brian Tracy","Chantal Sutherland","Les Brown","Bob Riley","Jack Canfield","Napoleon Hill","Jim Rohn","Serena Williams","Sheryl Sandberg","Reese Witherspoon","Hazrat Inayat Khan","Albert Einstein"]}}]); \ No newline at end of file diff --git a/assets/js/bg-opera.js b/src/assets/js/bg-opera.js similarity index 100% rename from assets/js/bg-opera.js rename to src/assets/js/bg-opera.js diff --git a/assets/js/index.js b/src/assets/js/index.js similarity index 60% rename from assets/js/index.js rename to src/assets/js/index.js index 4c51b016..c28a1bde 100644 --- a/assets/js/index.js +++ b/src/assets/js/index.js @@ -16,8 +16,7 @@ █████████████████████████████████████████████████████████████ */ -const func = require('./modules/func.js'); -const settings = require('./modules/settings.js'); +const func = require('./modules/func.js'); const init = () => { // init() gets executed only when the page is fully loaded @@ -25,10 +24,8 @@ const init = () => { func.setRandBg(); func.setRandQuote(); func.setTime(); - func.setWithoutSeconds(); - - if (!localStorage.getItem('seconds') === 'on') return setInterval(func.setWithoutSeconds, 60000); - else return setInterval(func.setTime, 1000); + // set interval to update time every second + setInterval(func.setTime, 1000); }; // initialize on page load through a listener @@ -37,13 +34,6 @@ document.addEventListener('DOMContentLoaded', init); // Disable right click document.oncontextmenu = () => { return false; }; -// Update modal -const modal = document.getElementById('updateModal'); -const btn = document.getElementById('openUpdateModal'); -const span = document.getElementsByClassName('close')[0]; -btn.onclick = () => { modal.style.display = 'block'; }; -span.onclick = () => { modal.style.display = 'none'; }; -window.onclick = (event) => { if (event.target === modal) modal.style.display = 'none'; }; // Copy quote text /*const copybtn = document.getElementById('copybtn'); @@ -53,36 +43,19 @@ copybtn.onclick = () => { document.execCommand('copy'); };*/ -function copyQuote() { - const quote = document.createRange(); - quote.selectNode(document.getElementById('quoteText')); - window.getSelection().removeAllRanges(); - window.getSelection().addRange(quote); - document.execCommand("copy"); - window.getSelection().removeAllRanges(); -} +// News Modal +/*const btn = document.getElementById('openModal'); +const span = document.getElementsByClassName('close')[0]; +const modal = document.getElementById('updateModal'); +btn.onclick = () => { modal.style.display = 'block'; } +span.onclick = () => { modal.style.display = 'none'; } +window.onclick = (event) => { if (event.target === modal) modal.style.display = 'none'; }*/ - -// Search bar -const search = () => { - const services = { - duckduckgo: 'https://duckduckgo.com/?q=', - google: 'https://google.com/search?q=', - bing: 'https://bing.com/search?q=', - yahoo: 'https://search.yahoo.com/search?p=', - ask: 'https://ask.com/web?q=', - ecosia: 'https://ecosia.org/search?q=' - } - const searchvalue = document.getElementById('searchText').value; - windows.open(services[localStorage.getItem('engine')] + searchvalue, '_self'); - return false; -} - -var slider = document.getElementById("slider"); -var output = document.getElementById("blurValue"); -output.innerHTML = slider.value; - -slider.oninput = function() { - output.innerHTML = this.value; -}; \ No newline at end of file +// Settings Modal +const modal2 = document.getElementById('settingsModal'); +const btn2 = document.getElementById('openSettingsModal'); +const span2 = document.getElementsByClassName('close2')[0]; +btn2.onclick = () => { modal2.style.display = 'block'; }; +span2.onclick = () => { modal2.style.display = 'none'; }; +window.onclick = (event) => { if (event.target === modal2) modal2.style.display = 'none'; }; diff --git a/assets/js/modules/bg.js b/src/assets/js/modules/bg.js similarity index 100% rename from assets/js/modules/bg.js rename to src/assets/js/modules/bg.js diff --git a/assets/js/modules/code.js b/src/assets/js/modules/code.js similarity index 100% rename from assets/js/modules/code.js rename to src/assets/js/modules/code.js diff --git a/assets/js/modules/func.js b/src/assets/js/modules/func.js similarity index 60% rename from assets/js/modules/func.js rename to src/assets/js/modules/func.js index fcea0ac2..4cb56e50 100644 --- a/assets/js/modules/func.js +++ b/src/assets/js/modules/func.js @@ -42,40 +42,34 @@ module.exports = class Func { static setRandBg() { document.body.classList.add(util.pickFromArray(bg)); - /*util.getJSON(`https://api.muetab.xyz/getImage?category=Outdoors`, - (err, data) => { - document.body.style.background = `#f3f3f3 url('${data.file}') !important`; - });*/ - } + /*var getJSON = function(url, callback) { + var xhr = new XMLHttpRequest(); + xhr.open('GET', url, true); + xhr.responseType = 'json'; + xhr.onload = function() { + var status = xhr.status; + if (status === 200) { + callback(null, xhr.response); + } else { + callback(status, xhr.response); + } + }; + xhr.send(); + }; - static setWithoutSeconds() { - const dateNoSec = new Date(), - time = [ - util.formatTimeUnit(dateNoSec.getHours()), - util.formatTimeUnit(dateNoSec.getMinutes()) - ]; - document.getElementById('withoutSeconds').innerHTML = time.join(':'); + getJSON(`https://mueapi.derpyenterprises.org/getImage?category=Outdoors`, +function(err, data) { + document.body.style.background = `url('${data.file}') !important`; +});*/ } static setRandQuote() { const id = util.getRandIndex(quotes.authors); - /*util.getJSON(`https://api.muetab.xyz/getQuote`, - (err, data) => { - if (err) { - if (util.contains.call(codes.itcodes, nal)) document.querySelector('blockquote').innerHTML = `"${quotes.it[id]}"`; // Italian - if (util.contains.call(codes.ptcodes, nal)) document.querySelector('blockquote').innerHTML = `"${quotes.pt[id]}"` || `"${quotes.eng[id]}"`; // Portuguese - if (util.contains.call(codes.spcodes, nal)) document.querySelector('blockquote').innerHTML = `"${quotes.sp[id]}"`; // Spanish - else document.querySelector('blockquote').innerHTML = `"${quotes.eng[id]}"`; // English - document.querySelector('cite').innerHTML = quotes.authors[id]; - } - document.querySelector('blockquote').innerHTML = `"${data.quote}"`; - document.querySelector('cite').innerHTML = data.author; - });*/ - if (util.contains.call(codes.itcodes, nal)) document.querySelector('blockquote').innerHTML = `"${quotes.it[id]}"`; // Italian - if (util.contains.call(codes.ptcodes, nal)) document.querySelector('blockquote').innerHTML = `"${quotes.pt[id]}"` || `"${quotes.eng[id]}"`; // Portuguese - if (util.contains.call(codes.spcodes, nal)) document.querySelector('blockquote').innerHTML = `"${quotes.sp[id]}"`; // Spanish - else document.querySelector('blockquote').innerHTML = `"${quotes.eng[id]}"`; // English - document.querySelector('cite').innerHTML = quotes.authors[id]; + if (util.contains.call(codes.itcodes, nal)) document.querySelector('blockquote').innerHTML = `"${quotes.it[id]}"`; // Italian + if (util.contains.call(codes.ptcodes, nal)) document.querySelector('blockquote').innerHTML = `"${quotes.pt[id]}"` || `"${quotes.eng[id]}"`; // Portuguese + if (util.contains.call(codes.spcodes, nal)) document.querySelector('blockquote').innerHTML = `"${quotes.sp[id]}"`; // Spanish + else document.querySelector('blockquote').innerHTML = `"${quotes.eng[id]}"`; // English + document.querySelector('cite').innerHTML = quotes.authors[id]; } static setTime() { @@ -87,6 +81,6 @@ module.exports = class Func { ]; // Joins all of the array elements into a string using the ':' separator // Example: [16, 32, 03] -> "16:32:03" - document.getElementById('withSeconds').innerHTML = time.join(':'); + document.querySelector('time').innerHTML = time.join(':'); } -}; \ No newline at end of file +}; diff --git a/assets/js/modules/msg.js b/src/assets/js/modules/msg.js similarity index 100% rename from assets/js/modules/msg.js rename to src/assets/js/modules/msg.js diff --git a/assets/js/modules/quote.js b/src/assets/js/modules/quote.js similarity index 100% rename from assets/js/modules/quote.js rename to src/assets/js/modules/quote.js diff --git a/assets/js/modules/util.js b/src/assets/js/modules/util.js similarity index 88% rename from assets/js/modules/util.js rename to src/assets/js/modules/util.js index eeedbe34..6921089d 100644 --- a/assets/js/modules/util.js +++ b/src/assets/js/modules/util.js @@ -52,16 +52,4 @@ module.exports = class Util { } return indexOf.call(this, needle) > -1; } - - static getJSON(url, callback) { - var xhr = new XMLHttpRequest(); - xhr.open('GET', url, true); - xhr.responseType = 'json'; - xhr.onload = () => { - var status = xhr.status; - if (status === 200) callback(null, xhr.response); - else callback(status, xhr.response); - }; - xhr.send(); - }; }; \ No newline at end of file diff --git a/src/assets/js/stuff.js b/src/assets/js/stuff.js new file mode 100644 index 00000000..8d024509 --- /dev/null +++ b/src/assets/js/stuff.js @@ -0,0 +1,54 @@ + +const changeCSS = (cssFile, cssLinkIndex) => { + let oldlink = document.getElementsByTagName('link').item(cssLinkIndex); + let newlink = document.createElement('link'); + + newlink.setAttribute('rel', 'stylesheet'); + newlink.setAttribute('type', 'text/css'); + newlink.setAttribute('href', cssFile); + + document.getElementsByTagName('head').item(0).replaceChild(newlink, oldlink); +}; + +changeCSS(`./assets/css/${localStorage.getItem('theme')}.css`); + +const changeTheme = () => { + let themeBox = document.getElementById('check'); + if (themeBox.checked === true) { + changeCSS('./assets/css/light.css'); + localStorage.setItem('theme', 'light'); + } else { + changeCSS('./assets/css/dark.css'); + localStorage.setItem('theme', 'dark'); + } +} + +const hideQuotes = () => { + let quoteBox = document.getElementById('quoteCheck'); + let quoteText = document.getElementById('quoteText'); + + if (quoteBox.checked === true) quoteText.style.display = 'none'; + else quoteText.style.display = 'block'; +} + +const hideGreeting = () => { + let greetingBox = document.getElementById('greetingCheck'); + let greetingText = document.getElementById('greetingText'); + + if (greetingBox.checked === true) greetingText.style.display = 'none'; + else greetingText.style.display = 'block'; +} + +const hideSeconds = () => { + let secondsBox = document.getElementById('secondsCheck'); + let withSecondsText = document.getElementById('withSeconds'); + let withoutSecondsText = document.getElementById('withoutSeconds'); + + if (secondsBox.checked === true) { + withoutSecondsText.style.display = 'block'; + withSeconds.style.display = 'none'; + } else { + withSeconds.style.display = 'block'; + withoutSecondsText.style.display = 'none'; + } +} \ No newline at end of file diff --git a/assets/scss/base.scss b/src/assets/scss/base.scss similarity index 92% rename from assets/scss/base.scss rename to src/assets/scss/base.scss index db96f980..3f43e102 100644 --- a/assets/scss/base.scss +++ b/src/assets/scss/base.scss @@ -17,10 +17,7 @@ */ @import 'modules/bg'; -@import 'modules/font'; @import 'modules/misc'; @import 'modules/quote'; -@import 'modules/search'; -@import 'modules/buttons'; -@import 'modules/settings-modal'; -@import 'modules/time-greeting'; \ No newline at end of file +@import 'modules/time-greeting'; +@import 'modules/settings'; \ No newline at end of file diff --git a/assets/scss/modules/_bg.scss b/src/assets/scss/modules/_bg.scss similarity index 100% rename from assets/scss/modules/_bg.scss rename to src/assets/scss/modules/_bg.scss diff --git a/assets/scss/modules/_misc.scss b/src/assets/scss/modules/_misc.scss similarity index 72% rename from assets/scss/modules/_misc.scss rename to src/assets/scss/modules/_misc.scss index 6fcc0d26..51ef68df 100644 --- a/assets/scss/modules/_misc.scss +++ b/src/assets/scss/modules/_misc.scss @@ -13,7 +13,7 @@ body { background-position: 50%; background-color: black; /* Prevent white flash on page load */ - font-family: 'Open Sans'; + font-family: 'Roboto'; color: white; overflow: hidden; @@ -22,6 +22,15 @@ body { user-select: none; /* Non-prefixed version, currently supported by Chrome and Opera */ } +/* Font */ +@font-face { + font-family: 'Roboto'; + font-style: normal; + font-weight: 400; + src: local('Roboto'), local('Roboto-Regular'), + url('../font/roboto-v18-latin-regular.woff2') format('woff2'); +} + /* Shadow */ :root { --shadow-color: #111111CC; @@ -30,12 +39,5 @@ body { .greeting, time, .quote { - position: absolute; filter: drop-shadow(var(--shadow-shift) var(--shadow-shift) 0 var(--shadow-color)); -} - -/* Selection */ -::selection { - background: #FF4F4E; - color: #fff; } \ No newline at end of file diff --git a/assets/scss/modules/_quote.scss b/src/assets/scss/modules/_quote.scss similarity index 98% rename from assets/scss/modules/_quote.scss rename to src/assets/scss/modules/_quote.scss index 955346c3..17cdb9ec 100644 --- a/assets/scss/modules/_quote.scss +++ b/src/assets/scss/modules/_quote.scss @@ -17,8 +17,6 @@ */ .quote { - padding-top: 15em; - --shadow-shift: 0.125rem; width: 37.5%; diff --git a/src/assets/scss/modules/_settings.scss b/src/assets/scss/modules/_settings.scss new file mode 100644 index 00000000..5f22f237 --- /dev/null +++ b/src/assets/scss/modules/_settings.scss @@ -0,0 +1,30 @@ +button.settings { + background: transparent; + border: none; + color: white; + padding: 20px 20px; + text-align: center; + text-decoration: none; + font-size: 20px; + cursor: pointer; + border-radius: 5px; + display: table-cell; +} + +.buttons { + position: absolute; + right: 10px; + top: 10px; +} + +i.material-icons { + font-size: 30px; + display: inline; + color: #ffffff; +} + +li.items { + list-style: none; + margin: 0 ; + padding-top: 30px; +} \ No newline at end of file diff --git a/assets/scss/modules/_time-greeting.scss b/src/assets/scss/modules/_time-greeting.scss similarity index 77% rename from assets/scss/modules/_time-greeting.scss rename to src/assets/scss/modules/_time-greeting.scss index 104f3a7d..0ba058bd 100644 --- a/assets/scss/modules/_time-greeting.scss +++ b/src/assets/scss/modules/_time-greeting.scss @@ -19,25 +19,13 @@ /* Greeting */ .greeting { - text-shadow: 0 0 25px rgba(0,0,0,0.3); + --shadow-shift: 0.2rem; font-size: 3.25rem; - padding-bottom: 10em; - font-weight: bold; - letter-spacing: 2px; } /* Time */ time { - text-shadow: 0 0 25px rgba(0,0,0,0.3); + --shadow-shift: 0.4rem; font-size: 12rem; - font-weight: bold; -} - -#withSeconds, #withoutSeconds, #greetingText { - -khtml-user-select: none; /* Konqueror HTML */ - -moz-user-select: none; /* Firefox */ - -ms-user-select: none; /* Internet Explorer/Edge */ - user-select: none; /* Non-prefixed version, currently - supported by Chrome and Opera */ } \ No newline at end of file diff --git a/src/index.html b/src/index.html new file mode 100644 index 00000000..8bef4b2d --- /dev/null +++ b/src/index.html @@ -0,0 +1,116 @@ + + + + + + + + + + + + New Tab + + + + + + + + + + + +
+ + + + +
+ +
+ + + +
+ + +
+ + +
+ + + + \ No newline at end of file diff --git a/manifest-chrome.json b/src/manifest-chrome.json similarity index 87% rename from manifest-chrome.json rename to src/manifest-chrome.json index 7bd63ecf..4dd90039 100644 --- a/manifest-chrome.json +++ b/src/manifest-chrome.json @@ -1,6 +1,5 @@ { "manifest_version": 2, - "offline_enabled": true, "name": "Mue", "version": "0.1", "browser_action": { diff --git a/manifest-firefox.json b/src/manifest-firefox.json similarity index 100% rename from manifest-firefox.json rename to src/manifest-firefox.json diff --git a/manifest-opera.json b/src/manifest-opera.json similarity index 100% rename from manifest-opera.json rename to src/manifest-opera.json diff --git a/webpack.config.js b/webpack.config.js new file mode 100644 index 00000000..ec602703 --- /dev/null +++ b/webpack.config.js @@ -0,0 +1,8 @@ +module.exports = { + mode: 'production', + entry: ['./src/assets/js/index.js'], + output: { + filename: 'base.js', + path: `${__dirname}/src/assets/js` + } +}; \ No newline at end of file