[Library & openaire-theme & Explore | explore-redesign]: Added search form in menu (navbar) in landing pages.
1. search.less: Added css for modifier .small-vertical for .input-wrapper of <search-input>. 2. layout.service.ts: Added hasMenuSearchBarSubject: BehaviorSubject<boolean> = new BehaviorSubject<boolean>(false), parsing and getter/setter methods. 3. navigationBar.module.ts: Imported SearchInputModule. 4. navigationBar.component.ts: a. Added searchMode: boolean = false; and hasSearchBar: boolean = false; (and other helpful fields) b. Subscribe to queryParams to hide search bar and reset keyword | Subscribe to layoutService.hasMenuSearchBar to check if search should be included in navbar or not. c. Added methods "openSearch()" to show the search form and "goTo()" to trigger the search action and navigate to the search page. 5. navigationBar.component.html: Added <div search-input> and search-icon button to show search bar | Added checks if searchMode is enabled (search form visible) or not. 6. app-routing.module.ts: In routes for landing pages added in data: hasMenuSearchBar: true.
This commit is contained in:
parent
bdad7dc6e6
commit
3047236d1c
|
@ -15,21 +15,21 @@ const routes: Routes = [
|
|||
{path: 'orcid', loadChildren: () => import('./orcid/orcid.module').then(m => m.LibOrcidModule)},
|
||||
{path: 'my-orcid-links', loadChildren: () => import('./orcid/my-orcid-links/myOrcidLinks.module').then(m => m.LibMyOrcidLinksModule)},
|
||||
// Landing Pages
|
||||
{path: 'search/result', loadChildren: () => import('./landingPages/result/libResult.module').then(m => m.LibResultModule), data: {hasQuickContact: false}},
|
||||
{path: 'search/publication', loadChildren: () => import('./landingPages/publication/libPublication.module').then(m => m.LibPublicationModule), data: {hasQuickContact: false}},
|
||||
{path: 'search/dataset', loadChildren: () => import('./landingPages/dataset/libDataset.module').then(m => m.LibDatasetModule), data: {hasQuickContact: false}},
|
||||
{path: 'search/software', loadChildren: () => import('./landingPages/software/libSoftware.module').then(m => m.LibSoftwareModule), data: {hasQuickContact: false}},
|
||||
{path: 'search/other', loadChildren: () => import('./landingPages/orp/libOrp.module').then(m => m.LibOrpModule), data: {hasQuickContact: false}},
|
||||
{path: 'search/project', loadChildren: () => import('./landingPages/project/libProject.module').then(m => m.LibProjectModule), data: {hasQuickContact: false}},
|
||||
{path: 'search/result', loadChildren: () => import('./landingPages/result/libResult.module').then(m => m.LibResultModule), data: {hasQuickContact: false, hasMenuSearchBar: true}},
|
||||
{path: 'search/publication', loadChildren: () => import('./landingPages/publication/libPublication.module').then(m => m.LibPublicationModule), data: {hasQuickContact: false, hasMenuSearchBar: true}},
|
||||
{path: 'search/dataset', loadChildren: () => import('./landingPages/dataset/libDataset.module').then(m => m.LibDatasetModule), data: {hasQuickContact: false, hasMenuSearchBar: true}},
|
||||
{path: 'search/software', loadChildren: () => import('./landingPages/software/libSoftware.module').then(m => m.LibSoftwareModule), data: {hasQuickContact: false, hasMenuSearchBar: true}},
|
||||
{path: 'search/other', loadChildren: () => import('./landingPages/orp/libOrp.module').then(m => m.LibOrpModule), data: {hasQuickContact: false, hasMenuSearchBar: true}},
|
||||
{path: 'search/project', loadChildren: () => import('./landingPages/project/libProject.module').then(m => m.LibProjectModule), data: {hasQuickContact: false, hasMenuSearchBar: true}},
|
||||
{
|
||||
path: 'search/dataprovider',
|
||||
loadChildren: () => import('././landingPages/dataProvider/libDataProvider.module').then(m => m.LibDataProviderModule),
|
||||
data: {hasQuickContact: false}
|
||||
data: {hasQuickContact: false, hasMenuSearchBar: true}
|
||||
},
|
||||
{
|
||||
path: 'search/organization',
|
||||
loadChildren: () => import('./landingPages/organization/libOrganization.module').then(m => m.LibOrganizationModule),
|
||||
data: {hasQuickContact: false}
|
||||
data: {hasQuickContact: false, hasMenuSearchBar: true}
|
||||
},
|
||||
{
|
||||
path: 'project-report',
|
||||
|
|
|
@ -1 +1 @@
|
|||
Subproject commit cf42f3a12298a2c99cd472aa2fd33ba00ded1f7f
|
||||
Subproject commit aef1a25a820b9a3e77780ff93eca0b086a2d32f2
|
|
@ -1 +1 @@
|
|||
Subproject commit aa1e6c9df390a4ba0919b5f8591374f7eec75089
|
||||
Subproject commit 4e9e2b25e12cf346c8553a42f012644a1fa8d16a
|
Loading…
Reference in New Issue