From 4cb5d1eaae40dc4940a12bec1f2eff6cf037a2b5 Mon Sep 17 00:00:00 2001 From: Serhat Date: Wed, 7 Oct 2020 11:14:47 +0300 Subject: [PATCH 1/5] Add a bit css improvement on dropdowns --- src/scss/modules/_settings.scss | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/scss/modules/_settings.scss b/src/scss/modules/_settings.scss index e706e458..67046816 100644 --- a/src/scss/modules/_settings.scss +++ b/src/scss/modules/_settings.scss @@ -226,12 +226,12 @@ button.remove + input[type=color].colour { } select { - background: none; + background: linear-gradient(180deg, #ffb032 0%, #dd3b67 100%); height: 34px; width: 120px; - border-image-slice: 1; - border-image-source: linear-gradient(180deg, #ffb032 0%, #dd3b67 100%); - border-left: 10px solid; + border: none; + border-radius: 5%; + padding-left: 10px; color: map-get($modal, "text"); } From cc5fa542e150e9f5ef7e1edb3eae1cc8c0ecc997 Mon Sep 17 00:00:00 2001 From: Serhat Date: Tue, 27 Oct 2020 17:59:45 +0300 Subject: [PATCH 2/5] Dropdowns are now standalone class --- src/components/modals/settings/Dropdown.jsx | 20 ++++++++++ .../settings/sections/BackgroundSettings.jsx | 17 +++++---- .../settings/sections/LanguageSettings.jsx | 23 ++++++----- .../settings/sections/SearchSettings.jsx | 38 ++++++++++--------- 4 files changed, 65 insertions(+), 33 deletions(-) create mode 100644 src/components/modals/settings/Dropdown.jsx diff --git a/src/components/modals/settings/Dropdown.jsx b/src/components/modals/settings/Dropdown.jsx new file mode 100644 index 00000000..6923da32 --- /dev/null +++ b/src/components/modals/settings/Dropdown.jsx @@ -0,0 +1,20 @@ +import React from 'react'; + +export default class Dropdown extends React.PureComponent { + getLabel() { + return this.props.label ? : null; + } + + render() { + return ( + <> + {this.getLabel()} +
+ +
+ + ); + } +} \ No newline at end of file diff --git a/src/components/modals/settings/sections/BackgroundSettings.jsx b/src/components/modals/settings/sections/BackgroundSettings.jsx index dae31f65..d52931b2 100644 --- a/src/components/modals/settings/sections/BackgroundSettings.jsx +++ b/src/components/modals/settings/sections/BackgroundSettings.jsx @@ -1,6 +1,7 @@ import React from 'react'; import { toast } from 'react-toastify'; import Checkbox from '../Checkbox'; +import Dropdown from '../Dropdown'; import Section from '../Section'; export default class BackgroundSettings extends React.PureComponent { @@ -160,13 +161,15 @@ export default class BackgroundSettings extends React.PureComponent {
    - - + localStorage.setItem('backgroundAPI', document.getElementById('backgroundAPI').value)} + > + + +

    {this.props.language.background.blur} ({this.state.blur}%) this.resetItem('blur')}>{this.props.language.reset}

    diff --git a/src/components/modals/settings/sections/LanguageSettings.jsx b/src/components/modals/settings/sections/LanguageSettings.jsx index 3c058006..2c9717cf 100644 --- a/src/components/modals/settings/sections/LanguageSettings.jsx +++ b/src/components/modals/settings/sections/LanguageSettings.jsx @@ -1,18 +1,23 @@ import React from 'react'; +import Dropdown from '../Dropdown'; export default class LanguageSettings extends React.PureComponent { render() { return ( -
    +

    {this.props.language.language}

    - -
    + localStorage.setItem('language', document.getElementById('language').value)} + > + + + + + + +
    ); } } \ No newline at end of file diff --git a/src/components/modals/settings/sections/SearchSettings.jsx b/src/components/modals/settings/sections/SearchSettings.jsx index 0003754b..e9f0ecde 100644 --- a/src/components/modals/settings/sections/SearchSettings.jsx +++ b/src/components/modals/settings/sections/SearchSettings.jsx @@ -2,6 +2,7 @@ import React from 'react'; import SettingsFunctions from '../../../../modules/settingsFunctions'; import { toast } from 'react-toastify'; import Section from '../Section'; +import Dropdown from '../Dropdown'; const searchEngines = require('../../../../modules/searchEngines.json'); @@ -25,23 +26,26 @@ export default class SearchSettings extends React.PureComponent { render() { return ( - -
    -
      - - -
    -
      -

      {this.props.language.searchbar.custom} this.resetSearch()}>{this.props.language.reset}

      - -
    -
    -
    + +
    +
      + SettingsFunctions.setSearchEngine(document.getElementById('searchEngine').value)} + > + {searchEngines.map((engine) => + + )} + + +
    +
      +

      {this.props.language.searchbar.custom} this.resetSearch()}>{this.props.language.reset}

      + +
    +
    +
    ); } } \ No newline at end of file From d455e4b63bb472c7a2c3c6b08170ae321db05730 Mon Sep 17 00:00:00 2001 From: Serhat Date: Tue, 27 Oct 2020 18:00:39 +0300 Subject: [PATCH 3/5] Add a bit more css improvement on dropdown --- src/scss/index.scss | 1 + src/scss/modules/_dropdown.scss | 16 ++++++++++++++++ src/scss/modules/_settings.scss | 14 -------------- 3 files changed, 17 insertions(+), 14 deletions(-) create mode 100644 src/scss/modules/_dropdown.scss diff --git a/src/scss/index.scss b/src/scss/index.scss index c3771153..3acd0e2d 100644 --- a/src/scss/index.scss +++ b/src/scss/index.scss @@ -13,6 +13,7 @@ @import 'modules/marketplace'; @import 'modules/checkbox'; @import 'modules/buttons'; +@import 'modules/dropdown'; @import 'modules/welcome'; body { diff --git a/src/scss/modules/_dropdown.scss b/src/scss/modules/_dropdown.scss new file mode 100644 index 00000000..c33a0f8a --- /dev/null +++ b/src/scss/modules/_dropdown.scss @@ -0,0 +1,16 @@ +.dropdown { + select { + background: linear-gradient(180deg, #ffb032 0%, #dd3b67 100%); + height: 34px; + width: 120px; + color: map-get($modal, "text"); + + border-image-source: linear-gradient(180deg, #ffb032 0%, #dd3b67 100%); + border-image-slice: 1; + border-width: 3px 4px; + } + + select#language { + float: right; + } +} diff --git a/src/scss/modules/_settings.scss b/src/scss/modules/_settings.scss index 67046816..9373e0ed 100644 --- a/src/scss/modules/_settings.scss +++ b/src/scss/modules/_settings.scss @@ -225,20 +225,6 @@ button.remove + input[type=color].colour { margin-left: 7px; } -select { - background: linear-gradient(180deg, #ffb032 0%, #dd3b67 100%); - height: 34px; - width: 120px; - border: none; - border-radius: 5%; - padding-left: 10px; - color: map-get($modal, "text"); -} - -select#language { - float: right; -} - #customBackgroundColour { cursor: pointer; } From ac60d54950c63e0f04e422e0932b7c9fed762e10 Mon Sep 17 00:00:00 2001 From: Vicente015 <33096355+Vicente015@users.noreply.github.com> Date: Wed, 28 Oct 2020 13:58:53 +0000 Subject: [PATCH 4/5] Spanish translation --- src/translations/es.json | 135 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 135 insertions(+) create mode 100644 src/translations/es.json diff --git a/src/translations/es.json b/src/translations/es.json new file mode 100644 index 00000000..3b96bf14 --- /dev/null +++ b/src/translations/es.json @@ -0,0 +1,135 @@ +{ + "greeting": { + "morning": "Buenos días", + "afternoon": "Buenas tardes", + "evening": "Buenas noches", + "christmas": "Feliz Navidad", + "newyear": "Feliz año nuevo", + "halloween": "Feliz Halloween" + }, + "credit": "Foto por", + "search": "Buscar", + "modals": { + "title": "Opciones", + "settings": "Ajustes", + "addons": "Mis complementos", + "marketplace": "Tienda" + }, + "settings": { + "time": { + "title": "Tiempo", + "seconds": "Segundos", + "twentyfourhour": "24 Horas", + "ampm": "AM/PM (12 horas)", + "zero": "Sin ceros", + "analog": "Analógico" + }, + "greeting": { + "title": "Saludos", + "events": "Eventos", + "default": "Mensaje del saludo por defecto", + "name": "Nombre para el saludo" + }, + "quote": { + "title": "Cita", + "copy": "Botón de copiar", + "tweet": "Botón de Tweet", + "favourite": "Botón de favoritos" + }, + "background": { + "title": "Fondo", + "API": "Fondos API", + "blur": "Ajustar difuminado", + "brightness": "Ajustar brillo", + "customURL": "URL del fondo personalizado", + "custombackground": "Fondo personalizado", + "customcolour": "Color del fondo personalizado", + "upload": "Subir", + "addcolour": "Añadir color", + "favourite": "Favorito", + "view": "Ver", + "refresh": "Refrescar", + "disabled": "Desactivado" + }, + "searchbar": { + "title": "Barra de búsqueda", + "searchengine": "Motor de búsqueda", + "custom": "URL de búsqueda personalizada" + }, + "offline": "Modo Offline", + "dark": "Tema Oscuro", + "experimental": { + "title": "Experimental", + "webp": "Activar WebP", + "animations": "Animaciones", + "voicesearch": "Búsqueda por voz", + "nightmode": "Modo nocturno automático" + }, + "language": "Lenguaje", + "apply": "Aplicar", + "reset": "Reiniciar", + "import": "Importar", + "export": "Exportar" + }, + "update": { + "title": "Actualizar", + "offline": { + "title": "Offline", + "description": "No se pueden obtener actualizaciones en modo sin conexión" + }, + "error": { + "title": "Error", + "description": "No se pudo conectar con el servidor" + }, + "loading": "Cargando...", + "readblog": "Leer en el blog aquí", + "contactsupport": "Contáctanos aquí" + }, + "toasts": { + "quote": "Cita copiada", + "reset": "Restablecido correctamente", + "installed": "Instalado correctamente", + "removed": "Retirado correctamente", + "error": "Algo salió mal", + "imported": "Importado correctamente" + }, + "marketplace": { + "photo_packs": "Paquetes de fotos", + "quote_packs": "Paquetes de citas", + "preset_settings": "Ajustes preestablecidos", + "themes": "Tema", + "product": { + "overview": "Visión general", + "information": "Información", + "last_updated": "Última actualización", + "version": "Versión", + "author": "Autor", + "notice": { + "title": "Aviso", + "description": "Para que se realice el cambio, la página debe actualizarse." + }, + "buttons": { + "addtomue": "Añadir a Mue", + "remove": "Remover" + }, + "quoteWarning": { + "title": "Advertencia", + "description": "¡Este paquete de citas solicita a servidores externos que pueden rastrearlo!" + } + }, + "offline": { + "title": "Parece que estás desconectado", + "description": "Por favor conéctate a Internet." + }, + "see_more": "Ver más" + }, + "addons": { + "added": "Añadido", + "empty": { + "title": "Está vacío aquí", + "description": "Dirígete a la tienda para agregar algunos.", + "button": "Llévame allí" + }, + "sideload": "Cargar complemento localmente" + } +} \ No newline at end of file From 2d128754760fba06f0cfd42b8bd6ded52a4ed864 Mon Sep 17 00:00:00 2001 From: David Ralph Date: Wed, 28 Oct 2020 17:02:01 +0000 Subject: [PATCH 5/5] Add Spanish to language dropdown --- README.md | 27 ++++++++++++------- package.json | 2 +- src/components/modals/settings/Dropdown.jsx | 6 ++--- .../settings/sections/LanguageSettings.jsx | 3 ++- src/modules/settingsFunctions.js | 2 +- 5 files changed, 25 insertions(+), 15 deletions(-) diff --git a/README.md b/README.md index e74cb52c..e3775765 100644 --- a/README.md +++ b/README.md @@ -88,6 +88,7 @@ Please see our [roadmap](https://github.com/mue/mue/projects)
  • Click Load unpacked (Make sure Developer Mode is on)
  • Go to the directory containing the built copy of Mue and click ok
  • Enjoy your new tab! +
    Opera (Click to expand) @@ -98,6 +99,7 @@ Please see our [roadmap](https://github.com/mue/mue/projects)
  • Click Load unpacked extension... (Make sure Developer Mode is on)
  • Go to the directory containing Mue and click ok
  • Enjoy your new tab! +
  • Firefox (Click to expand) @@ -113,20 +115,23 @@ Please see our [roadmap](https://github.com/mue/mue/projects)
    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. yarn run build or npm run build -
    2. Open the index.html in your browser -
    3. Enjoy your new tab! -
    +
      +
    1. yarn run build or npm run build +
    2. Open the index.html in your browser +
    3. Enjoy your new tab! +
    ## Credits -### Maintainers +### Core Team +#### Maintainers [David Ralph (ohlookitsderpy)](https://github.com/ohlookitsderpy) - Founder, Lead development, Photographer
    + [Alex Sparkes](https://github.com/alexsparkes) - Name, Lead design, Photographer
    -### Contributors +#### Developers [Wessel Tip](https://github.com/Wessel) - Development
    + [Isaac (Eartharoid)](https://github.com/eartharoid) - QA, Development, Photographer
    ### Translators @@ -138,9 +143,13 @@ Please see our [roadmap](https://github.com/mue/mue/projects) [Pronin Egor](https://github.com/MrZillaGold) - Russian -### Other +[Vicente](https://github.com/Vicente015) - Spanish + +### Resources [Pexels](https://pexels.com) - Stock photos used for offline mode [Opera Forum](https://forums.opera.com/topic/25046/how-to-disable-completely-the-speed-dial/14) - Portions of code to add Opera support -And many thanks to [Highholding](https://discord.bio/p/highholding), [Noa Shapira](#), [Roee Lupo](https://github.com/RoeeLupo), [Jeroen](#), [Glasvegas](https://twitter.com/_glasvegas), [Anders](https://github.com/FuryingFox), [Oded Shapira](https://twitter.com/dondishdev), Jacob Tyrrell and [Nikka Lai](#) for letting us use their wonderful photographs +Many thanks to [Highholding](https://discord.bio/p/highholding), [Noa Shapira](#), [Roee Lupo](https://github.com/RoeeLupo), [Jeroen](#), [Glasvegas](https://twitter.com/_glasvegas), [Anders](https://github.com/FuryingFox), [Oded Shapira](https://twitter.com/dondishdev), Jacob Tyrrell and [Nikka Lai](#) for letting us use their wonderful photographs. + +And finally, a big thank you to all the [contributors](https://github.com/mue/mue/graphs/contributors)! \ No newline at end of file diff --git a/package.json b/package.json index 9a0440dd..b13de57f 100644 --- a/package.json +++ b/package.json @@ -6,7 +6,7 @@ "David \"ohlookitsderpy\" Ralph (https://derpyenterprises.org)", "Alex \"TurboMarshmello\" Sparkes (https://github.com/alexsparkes)" ], - "description": "Fast, open and free-to-use new tab page for most modern browsers.", + "description": "Fast, open and free-to-use new tab page for modern browsers.", "repository": { "url": "github:mue/mue" }, diff --git a/src/components/modals/settings/Dropdown.jsx b/src/components/modals/settings/Dropdown.jsx index 6923da32..ea65294d 100644 --- a/src/components/modals/settings/Dropdown.jsx +++ b/src/components/modals/settings/Dropdown.jsx @@ -2,19 +2,19 @@ import React from 'react'; export default class Dropdown extends React.PureComponent { getLabel() { - return this.props.label ? : null; + return this.props.label ? : null; } render() { return ( - <> + {this.getLabel()}
    - +
    ); } } \ No newline at end of file diff --git a/src/components/modals/settings/sections/LanguageSettings.jsx b/src/components/modals/settings/sections/LanguageSettings.jsx index 2c9717cf..0bc2ec7c 100644 --- a/src/components/modals/settings/sections/LanguageSettings.jsx +++ b/src/components/modals/settings/sections/LanguageSettings.jsx @@ -12,8 +12,9 @@ export default class LanguageSettings extends React.PureComponent { onChange={() => localStorage.setItem('language', document.getElementById('language').value)} > - + + diff --git a/src/modules/settingsFunctions.js b/src/modules/settingsFunctions.js index dd3eddc6..6dfabf51 100644 --- a/src/modules/settingsFunctions.js +++ b/src/modules/settingsFunctions.js @@ -78,7 +78,7 @@ export default class SettingsFunctions { if (supportsWebP) localStorage.setItem('supportswebp', 'true'); // Languages - const languages = ['nl', 'no', 'fr', 'ru']; + const languages = ['nl', 'no', 'fr', 'ru', 'es']; const browserLanguage = (navigator.languages && navigator.languages[0]) || navigator.language; if (languages.includes(browserLanguage)) { localStorage.setItem('language', browserLanguage);