feat: add support for app url variables (#915)

* feat: add support for app url variables

* fix: test not working

* fix: format issue
This commit is contained in:
Meier Lukas
2024-08-06 21:43:12 +02:00
committed by GitHub
parent 693e319e26
commit c4c4d41e4d
13 changed files with 95 additions and 17 deletions

View File

@@ -4,6 +4,7 @@ import { IconApps, IconPencil } from "@tabler/icons-react";
import type { RouterOutputs } from "@homarr/api";
import { api } from "@homarr/api/server";
import { parseAppHrefWithVariablesServer } from "@homarr/common/server";
import { getI18n, getScopedI18n } from "@homarr/translation/server";
import { ManageContainer } from "~/components/manage/manage-container";
@@ -69,8 +70,8 @@ const AppCard = async ({ app }: AppCardProps) => {
</Text>
)}
{app.href && (
<Anchor href={app.href} lineClamp={1} size="sm" w="min-content">
{app.href}
<Anchor href={parseAppHrefWithVariablesServer(app.href)} lineClamp={1} size="sm" w="min-content">
{parseAppHrefWithVariablesServer(app.href)}
</Anchor>
)}
</Stack>