Conversation
marcbon
commented
Jul 7, 2026
Collaborator
- tab navigation
…ggestedHubs component
Un 2889 v2 - Hub Performance
… for improved navigation handling
…-2893) EntityPageContent becomes a generic dispatcher over an ENTITY_TABS registry instead of a hard-coded per-tab branch. Each remaining tab migration (overview/bug-list/media-list/insights, campaign and hub) registers its own content module and appends one registry entry, so the subtasks can be developed in parallel without editing EntityPageContent or the wrapper. The registry starts empty, preserving the shell's placeholder behaviour (no tab body until one is registered).
…ed state handling
Add the overview tab body as a self-contained module and register it in ENTITY_TABS. Reuses CampaignWidgets plus a content-only CampaignMetaRow (status/duration/devices, no action buttons — those live in the shared EntityPageHeader). EntityPageContent dispatches to it via the registry, so no edits to the dispatcher or wrapper are needed.
Campaign root now enters the wrapper and defaults to the overview tab (the existing effect redirects to ?tab=overview). Hub root stays on the legacy Videos content until UN-2897.
…der header in CampaignOverview
…ry (UN-2896) Add contentHeader slot to VideosPageContent/InsightsPageContent, extract content-only MediaListMetaRow (video count/date/devices/severities/status), and add MediaListTab/InsightsTab modules registered in ENTITY_TABS for the campaign context.
…UN-2896) Redirect /campaigns/:id/videos and /campaigns/:id/insights to the canonical ?tab=media-list / ?tab=insights entity route, merging existing query params. Hub routes are untouched (UN-2897). Also fixes a race in EntityPageWrapper where a deep link to a non-default tab (e.g. ?tab=media-list) was clobbered back to the fallback tab by the URL-correction effect, because enabledTabs was computed from an undefined campaign before entity data finished loading.
UN-2893 — Entity page shell: header unificato + tab navigation
UN-2894 — Subtask 2: campaign overview tab under entity wrapper
UN-2896 — Migrazione campaign media-list + insights + redirect
feat: add BugListTab and BugsMetaRow components
Extract the video-count/device-breakdown/severity-tags computation shared between MediaListMetaRow (campaign) and the upcoming hub meta row into useMediaDeviceAndSeverityMetas, preserving MediaListMetaRow's existing behavior exactly.
… (UN-2897) Add an optional onOpenImportMediaModal prop so a parent can supply a shared modal-open handler instead of the component's own local state/instance. The legacy standalone page keeps its current behavior when the prop isn't passed.
Register hub variants of media-list and insights in ENTITY_TABS (HubMediaListTab, HubInsightsTab), reusing the existing content-only VideosPageContent/InsightsPageContent. Add HubMediaListMetaRow (video count/devices/severities) and HubInsightsEmptyState (soft navigation hint back to media-list) with new i18n keys.
Remove the legacy fallback entirely so /hubs/:id always enters the wrapper (default media-list tab), and centralize the import-media modal so the header CTA and the media-list empty-state CTA open the same instance.
…2897) ImportMediaModal now merges ?tab=media-list into the current query params instead of hardcoding the retired standalone route.
Generalize LegacyEntityTabRedirect to hub routes (derives the campaigns/hubs prefix from the current path) and wire /hubs/:id/videos and /hubs/:id/insights to redirect to the canonical ?tab= entity route.
The header "Upload media" CTA in EntityPageWrapper lost the mediaUploadModalOpened analytics event that the legacy Metas.tsx header fired before opening the import modal. Restore it with source: 'media_list' to match the pre-migration behavior; the empty-state CTA already tracks its own event separately (source: 'empty_state').
HubInsightsTab previously had no handling for a failed observations fetch — isLoading/isError both false with no data fell through silently to the "No insights yet" empty state, indistinguishable from a genuinely empty hub. Add an error toast (same pattern as PlanPageContent) so a load failure is surfaced to the user instead of masquerading as empty content.
…e (UN-2897) The CTA rendered a <Button> inside a <Link>, nesting two interactive elements — invalid HTML. Replace with a single Button using onClick/navigate to change the tab query param. Also reuse the existing __HUB_INSIGHTS_EMPTY_STATE_TITLE translation for the image title instead of a hardcoded string, since the same text is already shown right below it.
The comment claimed the dedup was against Collection's query, but Collection queries with groupBy: 'usecase-grapes' — a different cache key. The actual dedup is against the ungrouped query Widgets' useSeveritiesDistributionData makes. The practical conclusion (no extra network call) was correct, just for the wrong reason.
isImportMediaModalOpen/ImportMediaModal are unreachable for hubs in practice now: the hub media-list tab always passes onOpenImportMediaModal, and the only route that wouldn't (legacy standalone /hubs/:id/videos) is itself unrouted since the redirect landed. Left in place for standalone use; flagged for removal in the UN-2898 cleanup.
UN-2897 — Migrazione hub media-list/insights + handoff root
… components - Deleted Campaign page and its components including EditableTitle, Meta, and Header. - Removed Insights page and its components including PageHeader and index. - Cleaned up Videos page and its related components, including Metas and PageHeader. - Removed unused loading components and related hooks.
… in multiple components
…oks for campaign bugs and unique bugs
…for insights and media lists
…hance empty state handling
…ieval across components
- Added new SVG asset for empty insights hub. - Updated CampaignSettings button size to small. - Enhanced EditableEntityTitle with color from app theme. - Introduced a vertical divider in EntityPageHeader for better layout. - Replaced InboxFill icon with InboxStroke in buildCampaignMenuSections. - Increased padding in BugListTab and OverviewTab for improved spacing. - Wrapped HubInsightsTab content in LayoutWrapper for consistent styling. - Updated HubInsightsEmptyState to use new SVG and improved subtitle with link. - Modified MediaListMetaRow to remove start_date display and adjusted icon sizes. - Changed WatcherList size to small for consistency. - Updated CampaignOverview to include translations for title and subtitle. - Adjusted HubMediaListMetaRow for consistent styling and icon sizes.
…abTitle prop types
- Enhance WatcherList with dynamic top offset for tooltip positioning - Updated PositionedTooltipModal to accept a topOffset prop for dynamic margin adjustment. - Modified WatcherList component to pass topOffset value to PositionedTooltipModal. - Refactored MemberAddAutocomplete to accept data and loading state as props. - Introduced buildHubMenuSections to create action menu for hubs. - Adjusted EntityPageWrapper to utilize buildHubMenuSections for hub context. - Improved layout and spacing across various tabs and components for consistency. - Removed unnecessary LayoutWrapper in HubInsightsTab for cleaner rendering. - Updated MoveCampaignModal to handle both campaigns and hubs seamlessly. - Enhanced HubInsightsEmptyState for better link styling and structure.
…hodology section title
Un 2921 - Riorganizzazione cartelle in src/pages/Campaign
Un 2842 merge hubs campaigns
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.