stable

Clone or download

Read-only

feat: Display excerpt for search results

To give a little more context to the search results, we now display an extract of the document that matches the query. This is only available for fts_meilisearch, fts_db still display a generic "Content matches…". As we are still not sure if this is the way to go, this can be deactivated via a feature flag so that we can test on real data with or without the feature. It is enabled by default. To deactivate: tuleap config-set feature_flag_fts_meilisearch_display_matching_content 0 To activate: tuleap config-set feature_flag_fts_meilisearch_display_matching_content 1 This feature and the extra margin added to have less dense results will be adjusted later. Part of story #28835: have a full-text search backend based on Meilisearch Change-Id: If52306bf7baea57f119e01634c969acca2042db0

Modified Files

Name
M plugins/fts_common/include/REST/v1/SearchResultEntryRepresentation.php +3 βˆ’1 Go to diff View file
M plugins/fts_db/include/Index/SearchDAO.php +1 βˆ’1 Go to diff View file
M plugins/fts_db/tests/integration/Index/SearchDAOTest.php +2 βˆ’2 Go to diff View file
M plugins/fts_meilisearch/include/Index/MeilisearchHandler.php +29 βˆ’6 Go to diff View file
M plugins/fts_meilisearch/include/Index/MeilisearchMetadataDAO.php +2 βˆ’2 Go to diff View file
M plugins/fts_meilisearch/include/fts_meilisearchPlugin.php +1 βˆ’0 Go to diff View file
M plugins/fts_meilisearch/tests/integration/Index/MeilisearchMetadataDAOTest.php +3 βˆ’3 Go to diff View file
M plugins/fts_meilisearch/tests/unit/Index/MeilisearchHandlerTest.php +73 βˆ’4 Go to diff View file
M plugins/tracker/include/Tracker/Search/SearchResultRetriever.php +11 βˆ’11 Go to diff View file
M plugins/tracker/tests/unit/Tracker/Search/SearchResultRetrieverTest.php +12 βˆ’10 Go to diff View file
M src/common/Search/IndexedItemFound.php +1 βˆ’0 Go to diff View file
M src/common/Search/SearchResultEntry.php +1 βˆ’0 Go to diff View file
M src/scripts/switch-to/src/components/Body/Items/ItemEntry.test.ts +37 βˆ’1 Go to diff View file
M src/scripts/switch-to/src/components/Body/Items/ItemEntry.vue +12 βˆ’0 Go to diff View file
M src/scripts/switch-to/src/components/Body/Items/__snapshots__/ItemEntry.test.ts.snap +3 βˆ’0 Go to diff View file
M src/scripts/switch-to/src/type.ts +1 βˆ’0 Go to diff View file
M src/themes/common/css/utils/_switch-to.scss +5 βˆ’0 Go to diff View file
M tests/unit/common/Search/IndexedItemFoundToSearchResultTest.php +15 βˆ’4 Go to diff View file