Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[GEN-2169]: adjust title visibility for sources in overview (#2211)
This pull request includes several changes across different files to improve the handling of UI elements and notifications. The most important changes include adjustments to the title width in the `overview-drawer`, enhancements to the `useSSE` hook for better notification handling, and updates to the `DataTab` component to manage title overflow and tooltips. ### UI Improvements: * [`frontend/webapp/containers/main/overview/overview-drawer/drawer-header/index.tsx`](diffhunk://#diff-2410bbb07cf40a69a4bc6a34db093cdfcc2cb9d4b98b144a37a2c6a3e1a511ffL30-R30): Reduced the maximum width of the `Title` component from 400px to 270px to better fit the design. * [`frontend/webapp/reuseable-components/data-tab/index.tsx`](diffhunk://#diff-afbf1606ee29d25bd9273d63b66a4746dbdd1cd8406ad651cfd123ac28f72006R24-R25): Introduced a `MAX_TITLE_WIDTH` constant and updated the `Title` component to use this constant. Added logic to handle title overflow by displaying a tooltip when necessary. [[1]](diffhunk://#diff-afbf1606ee29d25bd9273d63b66a4746dbdd1cd8406ad651cfd123ac28f72006R24-R25) [[2]](diffhunk://#diff-afbf1606ee29d25bd9273d63b66a4746dbdd1cd8406ad651cfd123ac28f72006L57-R68) [[3]](diffhunk://#diff-afbf1606ee29d25bd9273d63b66a4746dbdd1cd8406ad651cfd123ac28f72006R111-R124) [[4]](diffhunk://#diff-afbf1606ee29d25bd9273d63b66a4746dbdd1cd8406ad651cfd123ac28f72006L139-R166) ### Notification Handling: * [`frontend/webapp/hooks/notification/useSSE.ts`](diffhunk://#diff-db9ebe0ce8cdabc0ede2f45de12661d55fb7aa50a5ecfc0787f5898c55b044d6L35-R36): Modified the `useSSE` hook to refetch sources for both `InstrumentationConfig` and `InstrumentationInstance` notification types, improving the handling of these notifications. ### Codebase Enhancements: * [`frontend/webapp/reuseable-components/data-tab/index.tsx`](diffhunk://#diff-afbf1606ee29d25bd9273d63b66a4746dbdd1cd8406ad651cfd123ac28f72006L1-R5): Added missing imports for `useEffect` and `useRef` to handle the new title overflow logic. * [`frontend/webapp/reuseable-components/text/index.tsx`](diffhunk://#diff-7a8404854ee4398fbaa12fe211cc58436759a7b73b299d847fb52d770c86d9aaL1-R5): Refactored the `Text` component to use `forwardRef` for better handling of refs and updated the `TextProps` interface for type consistency. [[1]](diffhunk://#diff-7a8404854ee4398fbaa12fe211cc58436759a7b73b299d847fb52d770c86d9aaL1-R5) [[2]](diffhunk://#diff-7a8404854ee4398fbaa12fe211cc58436759a7b73b299d847fb52d770c86d9aaL34-R40)
- Loading branch information