-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add landing pages to search results (#1190)
* cms now returns article permalinks * add category to documentation in search * pull fixture data into one file add documentation to storybook * add landing page to search results * add data-testid for search result preview * show landing publishedDate or updatedDate (which ever is later)
- Loading branch information
Showing
14 changed files
with
219 additions
and
143 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
import type { SearchResultRecord } from 'types/index' | ||
|
||
export const testApplicationResult: SearchResultRecord = { | ||
id: 'testBookmark123', | ||
type: 'Bookmark', | ||
title: 'MyFSS', | ||
preview: | ||
'How is Air Force Information Management System abbreviated? AFIMS stands for Air Force Information Management System. For those who have seen the Earth from space, and for the hundreds and perhaps thousands more who will, the experience most certainly changes your perspective.', | ||
permalink: 'https://www.url.com/myfss', | ||
} | ||
|
||
export const testDocumentationResult: SearchResultRecord = { | ||
id: 'testDocumentation123', | ||
type: 'Documentation', | ||
title: 'Some Documentation', | ||
preview: | ||
'Documentation posted about some important topic that you should read about.', | ||
permalink: 'https://localhost:3000/path/to/documentation', | ||
} | ||
|
||
export const testLandingPageResult: SearchResultRecord = { | ||
id: 'testLandingPage123', | ||
type: 'LandingPage', | ||
title: 'Some Landing Page', | ||
preview: | ||
'Our team landing page where you can find all the information you need to know about our team.', | ||
permalink: 'https://localhost:3000/landing/team', | ||
} | ||
|
||
export const testArticleResultNoLabels: SearchResultRecord = { | ||
id: 'testArticle124', | ||
type: 'Article', | ||
title: | ||
'Physical training: but without labels Everything you need to know about the update in requirements', | ||
preview: | ||
'There are no labels. As a steward of almost 9 million acres encompassing forests, prairies, deserts, wetlands, and coastal habitats, the Department of the Air Force recognizes the importance of protecting and sustaining the natural environment.', | ||
permalink: | ||
'https://localhost:3000/articles/physical-training-everything-you-need-to-know-no-labels', | ||
date: '2022-05-17T13:44:39.796Z', | ||
} | ||
export const testArticleResult: SearchResultRecord = { | ||
id: 'testArticle123', | ||
type: 'Article', | ||
title: | ||
'Physical training: Everything you need to know about the update in requirements', | ||
preview: | ||
'As a steward of almost 9 million acres encompassing forests, prairies, deserts, wetlands, and coastal habitats, the Department of the Air Force recognizes the importance of protecting and sustaining the natural environment.', | ||
permalink: | ||
'https://localhost:3000/articles/physical-training-everything-you-need-to-know', | ||
date: '2022-05-17T13:44:39.796Z', | ||
labels: [ | ||
{ | ||
id: 'testLabel', | ||
name: 'All Guardians', | ||
type: 'Audience', | ||
}, | ||
], | ||
} |
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Oops, something went wrong.