Skip to content
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

[frontend] Add page titles to Data pages #8300

Open
wants to merge 1 commit into
base: release/6.4.0
Choose a base branch
from

Conversation

VerboseCat
Copy link
Contributor

@VerboseCat VerboseCat commented Sep 10, 2024

Proposed changes

This PR is a follow-up to the the PR which introduced custom page titles (#7374). This PR converts several 'Data' components from classes to functional and adds page titles. These components were not included in the original PR because they were class components and could not use the page title hook.

Impacted Pages
*

Related issues

Checklist

  • I consider the submitted work as finished
  • I tested the code for its functionality
  • I wrote test cases for the relevant uses case (coverage and e2e)
  • I added/update the relevant documentation (either on github or on notion)
  • Where necessary I refactored code to improve the overall quality

Further comments

This PR has a known issue, which has also been reported in a comment on (#7753). Every time a page renders, both the the custom page title setting function useConnectedDocumentModifier.setTitle and the default page title setting function useDocumentLangModifier run and set the title. In some instances, the default page title is set after the custom page title is set. This results in the default page title being displayed. I was unable to find a cause or pattern for which components exhibit this bug.

The following components from this PR are impacted:

  • Entities / Sectors (entities/Sectors.jsx)
  • Data / Ingestion / Connectors (data/Connectors.jsx)
  • Data / Data sharing / Live streams (data/Streams.tsx)

Copy link

codecov bot commented Sep 12, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 64.34%. Comparing base (00ce6a6) to head (7e28f0b).

Additional details and impacted files
@@              Coverage Diff               @@
##           release/6.4.0    #8300   +/-   ##
==============================================
  Coverage          64.34%   64.34%           
==============================================
  Files                608      608           
  Lines              58023    58023           
  Branches            6404     6404           
==============================================
  Hits               37332    37332           
  Misses             20691    20691           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@VerboseCat VerboseCat marked this pull request as ready for review September 12, 2024 19:21
@Jipegien Jipegien added the community use to identify PR from community label Sep 16, 2024
@VerboseCat VerboseCat force-pushed the convert_class_components_data branch 3 times, most recently from f1e9992 to e966485 Compare September 26, 2024 16:12
@VerboseCat VerboseCat force-pushed the convert_class_components_data branch from e966485 to d59591c Compare October 1, 2024 12:29
@SarahBocognano SarahBocognano self-assigned this Oct 2, 2024
@VerboseCat VerboseCat force-pushed the convert_class_components_data branch 2 times, most recently from 84adad0 to 85d2077 Compare October 17, 2024 12:02
@VerboseCat VerboseCat force-pushed the convert_class_components_data branch 2 times, most recently from c455052 to 8635ba9 Compare October 22, 2024 14:46
@VerboseCat VerboseCat changed the base branch from master to release/6.4.0 October 30, 2024 12:14
@VerboseCat VerboseCat force-pushed the convert_class_components_data branch 2 times, most recently from 8b37ab5 to 4ceaf08 Compare October 30, 2024 13:04
WIP - Adding Titles to pages

WIP - Updating Titles

WIP - Updating Titles for Functional Components only.

Updated Titles. Some class component pages have not been updated.

Revert "Updated Titles. Some class component pages have not been updated."

This reverts commit babb1cd.

Updated Titles. Some class component pages have not been updated.

Resolving Merge Conflicts

WIP - Converting class components to functional components

WIP - pushing current updates.

Fix merge issues

Fix Roles.tsx to be able to compile

Add latest version of Narratives.tsx

Replace key 'FAB_REPLACED' with 'FAB_REPLACEMENT'

Convert KillChainPhases to functional component

Updated Sectors. Need to update SectorLine and SectorsLines.

WIP - converting IngestionRss

WIP - finished IngestionRSS conversion

WIP

WIP - Modified IngestionTaxiis

WIP editing Connectors and Tasks.

WIP - one more to convert

WIP - modifying Streams.tsx and ImportContent.tsx.

WIP

Convert Connectors back to JSX functional component

WIP - updated Streams

Convert Stream to functional

Finished Import Content

Remove changes from PR 7753

Remove changes from PR 7753 (pt 2)

Remove changes from PR 7753 (pt 3)

Remove changes from PR 7753 (pt 4)

Remove duplicate Data titles

Remove duplicate Data titles (pt 3)

Remove sectors.jsx

Add translations

Convert Sectors closer to original component

Remove variant from breadcrumbs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
community use to identify PR from community
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants