mirror of
https://github.com/mue/mue.git
synced 2026-07-16 21:44:22 +02:00
feat: locally store stats so users can see them (no ui yet)
This commit is contained in:
@@ -28,7 +28,7 @@ export default class AdvancedSettings extends React.PureComponent {
|
||||
});
|
||||
|
||||
toast(window.language.toasts.imported);
|
||||
window.analytics.postEvent('tab', 'Settings imported');
|
||||
window.stats.postEvent('tab', 'Settings imported');
|
||||
}
|
||||
|
||||
render() {
|
||||
|
||||
@@ -10,6 +10,9 @@ export default function ExperimentalSettings() {
|
||||
<h2>{experimental.title}</h2>
|
||||
<p>{experimental.warning}</p>
|
||||
<Checkbox name='animations' text={window.language.modals.main.settings.sections.appearance.animations} element='.other'/>
|
||||
<h3>Usage Stats</h3>
|
||||
<p>Allows you to see stats such as how many tabs you have opened, quotes favourited etc. It also sends this data anonymously to our<a className='modalLink' href='https://github.com/mue/umami'>umami</a> instance.</p>
|
||||
<Checkbox name='stats' text='Enable Usage Stats' element='.other'/>
|
||||
<h3>{experimental.developer}</h3>
|
||||
<Checkbox name='debug' text='Debug hotkey (Ctrl + #)' element='.other'/>
|
||||
<Slider title='Debug timeout' name='debugtimeout' min='0' max='5000' default='0' step='100' display=' miliseconds' element='.other' />
|
||||
|
||||
@@ -83,7 +83,7 @@ export default class OrderSettings extends React.PureComponent {
|
||||
|
||||
componentDidUpdate() {
|
||||
localStorage.setItem('order', JSON.stringify(this.state.items));
|
||||
window.analytics.postEvent('setting', 'Widget order');
|
||||
window.stats.postEvent('setting', 'Widget order');
|
||||
EventBus.dispatch('refresh', 'widgets');
|
||||
}
|
||||
|
||||
|
||||
@@ -104,7 +104,7 @@ export default class ColourSettings extends React.PureComponent {
|
||||
return newState;
|
||||
});
|
||||
|
||||
window.analytics.postEvent('setting', 'Changed backgroundtype from colour to gradient');
|
||||
window.stats.postEvent('setting', 'Changed backgroundtype from colour to gradient');
|
||||
}
|
||||
|
||||
currentGradientSettings = () => {
|
||||
|
||||
Reference in New Issue
Block a user