-
Notifications
You must be signed in to change notification settings - Fork 38
feat(redesign): scaffold src/v1/ router boundary (Phase 1 - Foundation PR 2b) #470
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
vitorvasc
merged 9 commits into
open-telemetry:main
from
vitorvasc:feat/84-pr2b-v1-scaffolding
May 14, 2026
Merged
Changes from all commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
56f0300
feat(v1): scaffold src/v1/ and move dormant navbar/theme-toggle/icons
vitorvasc d827a19
refactor(app): extract LegacyApp into src/LegacyApp.tsx
vitorvasc 5128aa9
feat(v1): introduce <V1App /> and the V1_REDESIGN boundary read in Ap…
vitorvasc ed057d1
feat(v1): scope v1 styles via .v1-app wrapper
vitorvasc 2bf432e
docs(84): update planning artifacts for PR 2b
vitorvasc 342ae53
chore(v1): complete src/v1/ move with barrel and rewritten imports
vitorvasc 0241f21
fix(v1): apply .v1-app to <html> so body bg uses v1 surface tokens
vitorvasc a0df240
docs(v1): add route-sync warnings, log footer contrast audit
vitorvasc 99a4c18
fix(v1): remove trailing space in route-sync comment
vitorvasc File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,138 @@ | ||
| /* | ||
| * Copyright The OpenTelemetry Authors | ||
| * | ||
| * Licensed under the Apache License, Version 2.0 (the "License"); | ||
| * you may not use this file except in compliance with the License. | ||
| * You may obtain a copy of the License at | ||
| * | ||
| * https://www.apache.org/licenses/LICENSE-2.0 | ||
| * | ||
| * Unless required by applicable law or agreed to in writing, software | ||
| * distributed under the License is distributed on an "AS IS" BASIS, | ||
| * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
| * See the License for the specific language governing permissions and | ||
| * limitations under the License. | ||
| */ | ||
| import { lazy, Suspense } from "react"; | ||
| import { Routes, Route } from "react-router-dom"; | ||
| import { Header } from "@/components/layout/header"; | ||
| import { Footer } from "@/components/layout/footer"; | ||
| import { isEnabled } from "@/lib/feature-flags"; | ||
| import { ErrorBoundary } from "@/components/ui/error-boundary"; | ||
|
|
||
| const HomePage = lazy(() => | ||
| import("@/features/home/home-page").then((m) => ({ default: m.HomePage })) | ||
| ); | ||
| const JavaAgentPage = lazy(() => | ||
| import("@/features/java-agent/java-agent-page").then((m) => ({ default: m.JavaAgentPage })) | ||
| ); | ||
| const CollectorPage = lazy(() => | ||
| import("@/features/collector/collector-page").then((m) => ({ default: m.CollectorPage })) | ||
| ); | ||
| const CollectorDetailPage = lazy(() => | ||
| import("@/features/collector/collector-detail-page").then((m) => ({ | ||
| default: m.CollectorDetailPage, | ||
| })) | ||
| ); | ||
| const NotFoundPage = lazy(() => | ||
| import("@/features/not-found/not-found-page").then((m) => ({ default: m.NotFoundPage })) | ||
| ); | ||
| const JavaInstrumentationListPage = lazy(() => | ||
| import("@/features/java-agent/java-instrumentation-list-page").then((m) => ({ | ||
| default: m.JavaInstrumentationListPage, | ||
| })) | ||
| ); | ||
| const JavaConfigurationListPage = lazy(() => | ||
| import("@/features/java-agent/java-configuration-list-page").then((m) => ({ | ||
| default: m.JavaConfigurationListPage, | ||
| })) | ||
| ); | ||
| const JavaReleaseComparisonPage = lazy(() => | ||
| import("@/features/java-agent/java-release-comparison-page").then((m) => ({ | ||
| default: m.JavaReleaseComparisonPage, | ||
| })) | ||
| ); | ||
| const InstrumentationDetailPage = lazy(() => | ||
| import("@/features/java-agent/instrumentation-detail-page").then((m) => ({ | ||
| default: m.InstrumentationDetailPage, | ||
| })) | ||
| ); | ||
| const ConfigurationBuilderPage = lazy(() => | ||
| import("@/features/java-agent/configuration/configuration-builder-page").then((m) => ({ | ||
| default: m.ConfigurationBuilderPage, | ||
| })) | ||
| ); | ||
| const AboutPage = lazy(() => | ||
| import("@/features/about/about-page").then((m) => ({ default: m.AboutPage })) | ||
| ); | ||
|
|
||
| /* | ||
| * Pre-pivot router subtree, reached when `isEnabled("V1_REDESIGN")` is false in | ||
| * `src/App.tsx`. The route table below MUST stay in sync with the table in | ||
| * `src/v1/V1App.tsx` until the cleanup deletes this file. Any new global | ||
| * route added here must also be added there, otherwise it's reachable only in | ||
| * legacy builds and 404s on `feat/84-*` preview deploys. | ||
| * | ||
| * When the cleanup PR removes this file, the route-sync warning becomes moot: | ||
| * v1's table becomes the only table. | ||
| */ | ||
| export function LegacyApp() { | ||
| return ( | ||
| <div className="bg-background flex min-h-screen flex-col"> | ||
| <Header /> | ||
| <main className="flex-1 pt-16"> | ||
| <ErrorBoundary> | ||
| <Suspense | ||
| fallback={ | ||
| <div | ||
| className="flex min-h-[400px] items-center justify-center" | ||
| role="status" | ||
| aria-live="polite" | ||
| > | ||
| <div className="text-muted-foreground text-sm font-medium">Loading…</div> | ||
| </div> | ||
| } | ||
| > | ||
| <Routes> | ||
| <Route path="/" element={<HomePage />} /> | ||
| <Route path="/java-agent" element={<JavaAgentPage />} /> | ||
| <Route path="/java-agent/instrumentation" element={<JavaInstrumentationListPage />} /> | ||
| <Route | ||
| path="/java-agent/instrumentation/:version" | ||
| element={<JavaInstrumentationListPage />} | ||
| /> | ||
| <Route | ||
| path="/java-agent/instrumentation/:version/:name" | ||
| element={<InstrumentationDetailPage />} | ||
| /> | ||
| <Route path="/java-agent/configuration" element={<JavaConfigurationListPage />} /> | ||
| {isEnabled("JAVA_RELEASE_COMPARISON") && ( | ||
| <Route path="/java-agent/releases" element={<JavaReleaseComparisonPage />} /> | ||
| )} | ||
| {isEnabled("JAVA_CONFIG_BUILDER") && ( | ||
| <Route | ||
| path="/java-agent/configuration/builder" | ||
| element={<ConfigurationBuilderPage />} | ||
| /> | ||
| )} | ||
| <Route path="/collector" element={<CollectorPage />} /> | ||
| {isEnabled("COLLECTOR_PAGE") && ( | ||
| <> | ||
| <Route path="/collector/components" element={<CollectorPage />} /> | ||
| <Route path="/collector/components/:version" element={<CollectorPage />} /> | ||
| <Route | ||
| path="/collector/components/:version/:id" | ||
| element={<CollectorDetailPage />} | ||
| /> | ||
| </> | ||
| )} | ||
| <Route path="/about" element={<AboutPage />} /> | ||
| <Route path="*" element={<NotFoundPage />} /> | ||
| </Routes> | ||
| </Suspense> | ||
| </ErrorBoundary> | ||
| </main> | ||
| <Footer /> | ||
| </div> | ||
| ); | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.