Skip to content

Commit 5d639d5

Browse files
authored
refactor(web): flatten the /admin/configuration/* routes (#14149)
1 parent 7bea2e0 commit 5d639d5

53 files changed

Lines changed: 283 additions & 239 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

web/next.config.js

Lines changed: 85 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -142,14 +142,97 @@ const nextConfig = {
142142
destination: "/ee/agents/:path*",
143143
permanent: true,
144144
},
145+
// Next.js does not chain redirects, so these two point at the flattened
146+
// paths directly rather than at their old /admin/configuration/ targets.
145147
{
146148
source: "/admin/configuration/search",
147-
destination: "/admin/configuration/index-settings",
149+
destination: "/admin/index-settings",
148150
permanent: true,
149151
},
150152
{
151153
source: "/admin/configuration/llm",
152-
destination: "/admin/configuration/language-models",
154+
destination: "/admin/language-models",
155+
permanent: true,
156+
},
157+
// Legacy /admin/configuration/* → /admin/* redirects. The segment provided no additional value.
158+
{
159+
source: "/admin/configuration/chat-preferences",
160+
destination: "/admin/chat-preferences",
161+
permanent: true,
162+
},
163+
{
164+
source: "/admin/configuration/code-interpreter",
165+
destination: "/admin/code-interpreter",
166+
permanent: true,
167+
},
168+
{
169+
source: "/admin/configuration/document-processing",
170+
destination: "/admin/document-processing",
171+
permanent: true,
172+
},
173+
{
174+
source: "/admin/configuration/image-generation",
175+
destination: "/admin/image-generation",
176+
permanent: true,
177+
},
178+
{
179+
source: "/admin/configuration/index-settings",
180+
destination: "/admin/index-settings",
181+
permanent: true,
182+
},
183+
{
184+
source: "/admin/configuration/language-models",
185+
destination: "/admin/language-models",
186+
permanent: true,
187+
},
188+
{
189+
source: "/admin/configuration/voice",
190+
destination: "/admin/voice",
191+
permanent: true,
192+
},
193+
{
194+
source: "/admin/configuration/web-search",
195+
destination: "/admin/web-search",
196+
permanent: true,
197+
},
198+
// Replaces the redirect page that used to live at
199+
// /admin/configuration/craft, kept for /admin/craft/access bookmarks.
200+
{
201+
source: "/admin/configuration/craft",
202+
destination: "/admin/craft/access",
203+
permanent: true,
204+
},
205+
// Legacy /admin/actions/* → /admin/*. Only `mcp` and `open-api` held a
206+
// real page; `actions`, `new`, `edit-mcp` and `edit/:toolId` were all
207+
// redirect pages pointing at the MCP list, so they redirect there too.
208+
{
209+
source: "/admin/actions/mcp",
210+
destination: "/admin/mcp-actions",
211+
permanent: true,
212+
},
213+
{
214+
source: "/admin/actions/open-api",
215+
destination: "/admin/openapi-actions",
216+
permanent: true,
217+
},
218+
{
219+
source: "/admin/actions",
220+
destination: "/admin/mcp-actions",
221+
permanent: true,
222+
},
223+
{
224+
source: "/admin/actions/new",
225+
destination: "/admin/mcp-actions",
226+
permanent: true,
227+
},
228+
{
229+
source: "/admin/actions/edit-mcp",
230+
destination: "/admin/mcp-actions",
231+
permanent: true,
232+
},
233+
{
234+
source: "/admin/actions/edit/:toolId",
235+
destination: "/admin/mcp-actions",
153236
permanent: true,
154237
},
155238
];

web/src/app/admin/actions/edit-mcp/page.tsx

Lines changed: 0 additions & 16 deletions
This file was deleted.

web/src/app/admin/actions/edit/[toolId]/page.tsx

Lines changed: 0 additions & 16 deletions
This file was deleted.

web/src/app/admin/actions/new/page.tsx

Lines changed: 0 additions & 16 deletions
This file was deleted.

web/src/app/admin/actions/page.tsx

Lines changed: 0 additions & 16 deletions
This file was deleted.
File renamed without changes.
File renamed without changes.

web/src/app/admin/configuration/craft/page.tsx

Lines changed: 0 additions & 7 deletions
This file was deleted.
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)