mirror of
https://github.com/mue/mue.git
synced 2026-07-27 02:31:06 +02:00
fix(settings): experimental flashing on sidebar search
This commit is contained in:
@@ -1,5 +0,0 @@
|
|||||||
{
|
|
||||||
"permissions": {
|
|
||||||
"allow": ["Bash(node scripts/updatetranslations.cjs:*)"]
|
|
||||||
}
|
|
||||||
}
|
|
||||||
1
.gitignore
vendored
1
.gitignore
vendored
@@ -1,6 +1,7 @@
|
|||||||
# Directories
|
# Directories
|
||||||
node_modules/
|
node_modules/
|
||||||
.history/
|
.history/
|
||||||
|
.claude/
|
||||||
.vscode/
|
.vscode/
|
||||||
build/
|
build/
|
||||||
.idea/
|
.idea/
|
||||||
|
|||||||
@@ -1,15 +1,11 @@
|
|||||||
import { memo, useState, useEffect } from 'react';
|
import { memo } from 'react';
|
||||||
import { useT } from 'contexts/TranslationContext';
|
import { useT } from 'contexts/TranslationContext';
|
||||||
import { Tooltip } from 'components/Elements';
|
import { Tooltip } from 'components/Elements';
|
||||||
import { getIconComponent, DIVIDER_LABELS } from '../constants/tabConfig';
|
import { getIconComponent, DIVIDER_LABELS } from '../constants/tabConfig';
|
||||||
|
|
||||||
function Tab({ label, currentTab, onClick, navbarTab, isCollapsed }) {
|
function Tab({ label, currentTab, onClick, navbarTab, isCollapsed }) {
|
||||||
const t = useT();
|
const t = useT();
|
||||||
const [isExperimental, setIsExperimental] = useState(true);
|
const isExperimental = localStorage.getItem('experimental') !== 'false';
|
||||||
|
|
||||||
useEffect(() => {
|
|
||||||
setIsExperimental(localStorage.getItem('experimental') !== 'false');
|
|
||||||
}, []);
|
|
||||||
|
|
||||||
// Get the icon component for this label (label is already translated)
|
// Get the icon component for this label (label is already translated)
|
||||||
const IconComponent = getIconComponent(label, { getMessage: t });
|
const IconComponent = getIconComponent(label, { getMessage: t });
|
||||||
|
|||||||
Reference in New Issue
Block a user