mirror of
https://github.com/hedgedoc/hedgedoc.git
synced 2025-06-06 01:21:39 -04:00
Correct use selector (#515)
This commit is contained in:
parent
971421925a
commit
a41d3d1515
20 changed files with 74 additions and 205 deletions
|
@ -10,7 +10,7 @@ import { VersionInfo } from './version-info'
|
|||
export const PoweredByLinks: React.FC = () => {
|
||||
useTranslation()
|
||||
|
||||
const config = useSelector((state: ApplicationState) => state.config)
|
||||
const specialLinks = useSelector((state: ApplicationState) => Object.entries(state.config.specialLinks) as [string, string][])
|
||||
|
||||
return (
|
||||
<p>
|
||||
|
@ -20,7 +20,7 @@ export const PoweredByLinks: React.FC = () => {
|
|||
|
|
||||
<TranslatedInternalLink href='/n/release-notes' i18nKey='landing.footer.releases'/>
|
||||
{
|
||||
Object.entries({ ...config.specialLinks }).map(([i18nKey, href]) =>
|
||||
specialLinks.map(([i18nKey, href]) =>
|
||||
<Fragment key={i18nKey}>
|
||||
|
|
||||
<TranslatedExternalLink href={href} i18nKey={'landing.footer.' + i18nKey}/>
|
||||
|
|
|
@ -8,6 +8,7 @@ import frontendVersion from '../../../version.json'
|
|||
import { TranslatedExternalLink } from '../../common/links/translated-external-link'
|
||||
import { ShowIf } from '../../common/show-if/show-if'
|
||||
import { CopyableField } from '../../common/copyable-field/copyable-field'
|
||||
import equal from 'fast-deep-equal'
|
||||
|
||||
export const VersionInfo: React.FC = () => {
|
||||
const [show, setShow] = useState(false)
|
||||
|
@ -17,7 +18,7 @@ export const VersionInfo: React.FC = () => {
|
|||
|
||||
const { t } = useTranslation()
|
||||
|
||||
const serverVersion = useSelector((state: ApplicationState) => state.config.version)
|
||||
const serverVersion = useSelector((state: ApplicationState) => state.config.version, equal)
|
||||
|
||||
const column = (title: string, version: string, sourceCodeLink: string, issueTrackerLink: string) => (
|
||||
<Col md={6} className={'flex-column'}>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue