mirror of
https://github.com/umami-software/umami.git
synced 2026-02-12 00:27:11 +01:00
Dynamically fetch language bundles at runtime.
This commit is contained in:
parent
73e83ad767
commit
f91cc82c82
20 changed files with 95 additions and 132 deletions
|
|
@ -27,7 +27,7 @@ export default function BarChart({
|
|||
const canvas = useRef();
|
||||
const chart = useRef();
|
||||
const [tooltip, setTooltip] = useState(null);
|
||||
const [locale] = useLocale();
|
||||
const { locale } = useLocale();
|
||||
const [theme] = useTheme();
|
||||
const forceUpdate = useForceUpdate();
|
||||
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ import useCountryNames from 'hooks/useCountryNames';
|
|||
import useLocale from 'hooks/useLocale';
|
||||
|
||||
export default function CountriesTable({ websiteId, onDataLoad, ...props }) {
|
||||
const [locale] = useLocale();
|
||||
const { locale } = useLocale();
|
||||
const countryNames = useCountryNames(locale);
|
||||
|
||||
function renderLabel({ x }) {
|
||||
|
|
|
|||
|
|
@ -6,7 +6,7 @@ import styles from './Legend.module.css';
|
|||
import useForceUpdate from '../../hooks/useForceUpdate';
|
||||
|
||||
export default function Legend({ chart }) {
|
||||
const [locale] = useLocale();
|
||||
const { locale } = useLocale();
|
||||
const forceUpdate = useForceUpdate();
|
||||
|
||||
function handleClick(index) {
|
||||
|
|
|
|||
|
|
@ -31,7 +31,7 @@ const TYPE_ICONS = {
|
|||
|
||||
export default function RealtimeLog({ data, websites, websiteId }) {
|
||||
const intl = useIntl();
|
||||
const [locale] = useLocale();
|
||||
const { locale } = useLocale();
|
||||
const countryNames = useCountryNames(locale);
|
||||
const [filter, setFilter] = useState(TYPE_ALL);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue