Skip to content

Commit

Permalink
Simplify translation code
Browse files Browse the repository at this point in the history
  • Loading branch information
RunarVestmann committed Dec 5, 2024
1 parent fafffd6 commit 7a0ae41
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions apps/web/screens/Organization/ParentSubpage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -29,11 +29,6 @@ type OrganizationParentSubpageScreenContext = ScreenContext & {

export type OrganizationParentSubpageProps = StandaloneParentSubpageProps

const LanguageToggleSetup = (props: { ids: string[] }) => {
useContentfulId(...props.ids)
return null
}

const OrganizationParentSubpage: Screen<
OrganizationParentSubpageProps,
OrganizationParentSubpageScreenContext
Expand All @@ -49,6 +44,7 @@ const OrganizationParentSubpage: Screen<
const { activeLocale } = useI18n()
const { linkResolver } = useLinkResolver()
const n = useNamespace(namespace)
useContentfulId(organizationPage.id, parentSubpage.id, subpage.id)

return (
<OrganizationWrapper
Expand Down Expand Up @@ -79,10 +75,6 @@ const OrganizationParentSubpage: Screen<
<GridContainer>
<GridRow>
<GridColumn span={['9/9', '9/9', '7/9']} offset={['0', '0', '1/9']}>
<LanguageToggleSetup
ids={[organizationPage.id, parentSubpage.id, subpage.id]}
/>

<Stack space={3}>
{parentSubpage.childLinks.length > 1 && (
<Stack space={4}>
Expand Down

0 comments on commit 7a0ae41

Please sign in to comment.