@skyhook-io/radar-app 0.2.0 → 0.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -181,15 +181,14 @@ export function ResourcesView({ namespaces, selectedResource, onResourceClick, o
|
|
|
181
181
|
pinned={pinned}
|
|
182
182
|
togglePin={togglePin}
|
|
183
183
|
isPinned={(kind: string, group?: string) => isPinned(kind, group ?? '')}
|
|
184
|
-
// Navigation. basePath is
|
|
185
|
-
//
|
|
186
|
-
//
|
|
187
|
-
//
|
|
188
|
-
//
|
|
189
|
-
//
|
|
190
|
-
//
|
|
191
|
-
|
|
192
|
-
basePath={getBasename() + '/resources'}
|
|
184
|
+
// Navigation. basePath is basename-relative. React Router's useLocation
|
|
185
|
+
// strips the basename from `location.pathname`, so reading the current
|
|
186
|
+
// kind compares basename-relative paths on both sides. URL writes go
|
|
187
|
+
// through `handleNavigate`, which strips any leading basename before
|
|
188
|
+
// handing off to react-router (which re-applies it). Embedding hosts
|
|
189
|
+
// (e.g. Radar Cloud at /c/{cluster}/resources) work without ResourcesView
|
|
190
|
+
// needing to know the basename.
|
|
191
|
+
basePath="/resources"
|
|
193
192
|
locationSearch={location.search}
|
|
194
193
|
locationPathname={location.pathname}
|
|
195
194
|
onNavigate={handleNavigate}
|