mirror of
https://github.com/mue/mue.git
synced 2026-07-19 15:04:11 +02:00
fix: widget order tab no longer shows disabled widgets, better font for Russian, add Baidu search engine etc
This commit is contained in:
@@ -7,10 +7,23 @@ import DragHandleIcon from '@material-ui/icons/DragIndicator';
|
||||
import { sortableContainer, sortableElement } from 'react-sortable-hoc';
|
||||
import { toast } from 'react-toastify';
|
||||
|
||||
const enabled = (setting) => {
|
||||
return (localStorage.getItem(setting) === 'true');
|
||||
};
|
||||
|
||||
const settings = window.language.modals.main.settings.sections;
|
||||
const widget_name = {
|
||||
greeting: settings.greeting.title,
|
||||
time: settings.time.title,
|
||||
quicklinks: settings.quicklinks.title,
|
||||
quote: settings.quote.title,
|
||||
date: settings.time.date.title
|
||||
};
|
||||
|
||||
const SortableItem = sortableElement(({value}) => (
|
||||
<li className='sortableitem'>
|
||||
<li className='sortableitem' style={{ display: enabled(value) ? 'block' : 'none' }}>
|
||||
<DragHandleIcon style={{'verticalAlign': 'middle'}} />
|
||||
{value.charAt(0).toUpperCase() + value.slice(1)}
|
||||
{widget_name[value]}
|
||||
</li>
|
||||
));
|
||||
|
||||
|
||||
@@ -100,7 +100,7 @@ export default class Background extends React.PureComponent {
|
||||
} else {
|
||||
document.querySelector('#backgroundImage').setAttribute(
|
||||
'style',
|
||||
`${this.state.style}; -webkit-filter: blur(${localStorage.getItem('blur')}px) brightness(${localStorage.getItem('brightness')}%);`
|
||||
`${this.state.style}; -webkit-filter: brightness(${localStorage.getItem('brightness')}%);`
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -14,15 +14,30 @@
|
||||
"settingsName": "bing",
|
||||
"url": "https://bing.com/search"
|
||||
},
|
||||
{
|
||||
"name": "Ecosia",
|
||||
"settingsName": "ecosia",
|
||||
"url": "https://ecosia.org/search"
|
||||
},
|
||||
{
|
||||
"name": "Ask",
|
||||
"settingsName": "ask",
|
||||
"url": "https://ask.com/web"
|
||||
},
|
||||
{
|
||||
"name": "Yahoo",
|
||||
"settingsName": "yahoo",
|
||||
"url": "https://search.yahoo.com/search"
|
||||
},
|
||||
{
|
||||
"name": "Ecosia",
|
||||
"settingsName": "ecosia",
|
||||
"url": "https://ecosia.org/search"
|
||||
"name": "Qwant",
|
||||
"settingsName": "qwant",
|
||||
"url": "https://www.qwant.com/"
|
||||
},
|
||||
{
|
||||
"name": "Startpage",
|
||||
"settingsName": "startpage",
|
||||
"url": "https://www.startpage.com/sp/search"
|
||||
},
|
||||
{
|
||||
"name": "Яндекс",
|
||||
@@ -31,18 +46,8 @@
|
||||
"query": "text"
|
||||
},
|
||||
{
|
||||
"name": "Qwant",
|
||||
"settingsName": "qwant",
|
||||
"url": "https://www.qwant.com/"
|
||||
},
|
||||
{
|
||||
"name": "Ask",
|
||||
"settingsName": "ask",
|
||||
"url": "https://ask.com/web"
|
||||
},
|
||||
{
|
||||
"name": "Startpage",
|
||||
"settingsName": "startpage",
|
||||
"url": "https://www.startpage.com/sp/search"
|
||||
"name": "百度",
|
||||
"settingsName": "baidu",
|
||||
"url": "https://www.baidu.com/s?wd="
|
||||
}
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user