fix(app): list What's new with About in settings (#59471)

This commit is contained in:
Luke Parker
2026-10-27 12:47:26 +10:00
committed by GitHub
Unverified
parent 758cf5adbe
commit 19d87a72e6
3 changed files with 16 additions and 6 deletions
+10 -6
View File
@@ -279,6 +279,12 @@ function RootSettings() {
const addServer = () => void dialog.push(() => <DialogServer mode="add" onSave={selectServer} />)
const pluginTabs = (group?: "about") =>
surface.plugins
.pages()
.filter((item) => item.value.group === group)
.map((item) => ({ value: item.value.id, icon: item.value.icon ?? pageIcons.extensions, label: item.value.title }))
const groups = createMemo<SettingsNavGroup[]>(() => [
{
items: serverTabs.map((item) => ({
@@ -290,11 +296,7 @@ function RootSettings() {
{
items: [
...rootClientTabs.map((item) => ({ ...item, label: language.t(item.label) })),
...surface.plugins.pages().map((item) => ({
value: item.value.id,
icon: item.value.icon ?? pageIcons.extensions,
label: item.value.title,
})),
...pluginTabs(),
],
},
{
@@ -310,7 +312,9 @@ function RootSettings() {
? [{ items: experimentalTab.map((item) => ({ ...item, label: language.t(item.label) })) }]
: []),
...(showPlugins ? [{ items: pluginsTab.map((item) => ({ ...item, label: language.t(item.label) })) }] : []),
{ items: aboutTab.map((item) => ({ ...item, label: language.t(item.label) })) },
{
items: [...aboutTab.map((item) => ({ ...item, label: language.t(item.label) })), ...pluginTabs("about")],
},
])
const change = (value: string) => {
@@ -87,6 +87,7 @@ function betaNotes(ctx: SetupContext<typeof definition>) {
ctx.add(SettingsPage, {
id: "whats-new",
icon: "flask",
group: "about",
get title() {
return ctx.t("beta.title")
},
+5
View File
@@ -391,6 +391,11 @@ export interface SettingsPage {
* section.
*/
readonly section?: "general"
/**
* The nav group of a page. Omit it to list the page after the app's own pages, such as Shortcuts.
* - `about`: below About, in its group, for pages about the app itself such as release notes.
*/
readonly group?: "about"
/** Nav label of a page; search shows it as the section of every entry, except rows placed in a host `section`. */
readonly title: string
/** The page's nav icon. */