From 9415c2b5d8e98c2414d5396d1bec46a6ec7f76e4 Mon Sep 17 00:00:00 2001 From: Paul Date: Mon, 20 Dec 2021 21:07:20 +0000 Subject: [PATCH] chore(settings): add dummy element for index --- external/lang | 2 +- src/pages/settings/GenericSettings.tsx | 3 +++ src/pages/settings/Settings.tsx | 4 ++++ 3 files changed, 8 insertions(+), 1 deletion(-) diff --git a/external/lang b/external/lang index 9b9858c6..59fbe7c9 160000 --- a/external/lang +++ b/external/lang @@ -1 +1 @@ -Subproject commit 9b9858c64503783364dffba18b2a5356d11cdc30 +Subproject commit 59fbe7c9437a4d2b477d72543b28174dd2b11c5f diff --git a/src/pages/settings/GenericSettings.tsx b/src/pages/settings/GenericSettings.tsx index 34f22fa0..67a14435 100644 --- a/src/pages/settings/GenericSettings.tsx +++ b/src/pages/settings/GenericSettings.tsx @@ -41,6 +41,7 @@ interface Props { showExitButton?: boolean; switchPage: (to?: string) => void; category: "pages" | "channel_pages" | "server_pages"; + indexHeader?: Children; } export function GenericSettings({ @@ -51,6 +52,7 @@ export function GenericSettings({ children, defaultPage, showExitButton, + indexHeader, }: Props) { const history = useHistory(); const theme = useContext(ThemeContext); @@ -132,6 +134,7 @@ export function GenericSettings({
+ {indexHeader} {pages.map((entry, i) => entry.hidden ? undefined : ( <> diff --git a/src/pages/settings/Settings.tsx b/src/pages/settings/Settings.tsx index f370a3cc..bb7c005b 100644 --- a/src/pages/settings/Settings.tsx +++ b/src/pages/settings/Settings.tsx @@ -20,6 +20,7 @@ import { } from "@styled-icons/boxicons-solid"; import { Route, Switch, useHistory } from "react-router-dom"; import { LIBRARY_VERSION } from "revolt.js"; +import styled from "styled-components"; import styles from "./Settings.module.scss"; import { Text } from "preact-i18n"; @@ -53,6 +54,8 @@ import { Sessions } from "./panes/Sessions"; import { Sync } from "./panes/Sync"; import { ThemeShop } from "./panes/ThemeShop"; +const IndexHeader = styled.div``; + export default function Settings() { const history = useHistory(); const client = useContext(AppContext); @@ -258,6 +261,7 @@ export default function Settings() {
} + indexHeader={{/**/}} /> ); }