Revert "feat: migrate /apps/routing-forms/forms to /routing (#18001)"

This reverts commit 1de007ad21.
This commit is contained in:
Alex van Andel committed 2024-12-11 22:16:50 +00:00
1 parent 187a2c576e
commit 9c127cbfc2
10 files changed
+7 -223

No files matched your search

@@ -55,10 +55,6 @@ export async function getServerSideProps(
context: GetServerSidePropsContext,
...rest: GetServerSidePropsRestArgs
) {
//add forms to be the default page, if no pages are found
//this is useful when rendering /routing as no params would be available
const defaultPage = "forms";
const page = context.params?.pages?.[0] || defaultPage;
const component = getComponent(page);
const component = getComponent(context.params?.pages?.[0] || "");
return component.getServerSideProps?.(context, ...rest) || { props: {} };
}
@@ -84,7 +84,7 @@ test.describe("Routing Forms", () => {
test("should be able to add a new form and view it", async ({ page }) => {
const formId = await addForm(page);
await page.click('[href="/routing"]');
await page.click('[href*="/forms"]');
await page.waitForSelector('[data-testid="routing-forms-list"]');
// Ensure that it's visible in forms list
@@ -87,10 +87,10 @@ const getNavigationItems = (orgBranding: OrganizationBranding): NavigationItemTy
icon: "ellipsis",
},
{
name: "routing",
href: "/routing",
icon: "split",
isCurrent: ({ pathname }) => pathname?.startsWith("/routing") ?? false,
name: "routing_forms",
href: "/apps/routing-forms/forms",
icon: "file-text",
isCurrent: ({ pathname }) => pathname?.startsWith("/apps/routing-forms/") ?? false,
moreOnMobile: true,
},
{
@@ -114,7 +114,6 @@ export const lucideIconList = new Set([
"sliders-vertical",
"smartphone",
"sparkles",
"split",
"square-check",
"star",
"sun",
@@ -115,7 +115,6 @@ export type IconName =
| "sliders-vertical"
| "smartphone"
| "sparkles"
| "split"
| "square-check"
| "star"
| "sun"