mirror of
https://github.com/umami-software/umami.git
synced 2026-02-04 04:37:11 +01:00
add rtl support
This commit is contained in:
parent
0126154e39
commit
0c13f8d358
6 changed files with 28 additions and 7 deletions
|
|
@ -1,5 +1,5 @@
|
|||
import React, { useState } from 'react';
|
||||
import { FormattedMessage } from 'react-intl';
|
||||
import { FormattedMessage, useIntl } from 'react-intl';
|
||||
import { useSelector } from 'react-redux';
|
||||
import classNames from 'classnames';
|
||||
import Link from 'components/common/Link';
|
||||
|
|
@ -14,13 +14,17 @@ import styles from './Header.module.css';
|
|||
export default function Header() {
|
||||
const user = useSelector(state => state.user);
|
||||
const [active, setActive] = useState(false);
|
||||
const intl = useIntl();
|
||||
|
||||
function handleClick() {
|
||||
setActive(state => !state);
|
||||
}
|
||||
|
||||
return (
|
||||
<nav className="container">
|
||||
<nav
|
||||
className="container"
|
||||
dir={intl.formatMessage({ id: 'metrics.dir', defaultMessage: 'ltr' })}
|
||||
>
|
||||
{user?.is_admin && <UpdateNotice />}
|
||||
<div className={classNames(styles.header, 'row align-items-center')}>
|
||||
<div className={styles.nav}>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue