diff --git a/src/app/collection-page/collection-item-mapper/collection-item-mapper.component.html b/src/app/collection-page/collection-item-mapper/collection-item-mapper.component.html index 042beddc84..a48c4d15bf 100644 --- a/src/app/collection-page/collection-item-mapper/collection-item-mapper.component.html +++ b/src/app/collection-page/collection-item-mapper/collection-item-mapper.component.html @@ -28,14 +28,14 @@
- - +
diff --git a/src/app/home-page/home-page.component.html b/src/app/home-page/home-page.component.html index 1000dbe9a4..87613b56d0 100644 --- a/src/app/home-page/home-page.component.html +++ b/src/app/home-page/home-page.component.html @@ -3,7 +3,7 @@ - + diff --git a/src/app/item-page/edit-item-page/item-collection-mapper/item-collection-mapper.component.html b/src/app/item-page/edit-item-page/item-collection-mapper/item-collection-mapper.component.html index c779c4aafa..507e35e630 100644 --- a/src/app/item-page/edit-item-page/item-collection-mapper/item-collection-mapper.component.html +++ b/src/app/item-page/edit-item-page/item-collection-mapper/item-collection-mapper.component.html @@ -27,13 +27,13 @@
- - +
diff --git a/src/app/shared/form/builder/ds-dynamic-form-ui/relation-lookup-modal/external-source-tab/dynamic-lookup-relation-external-source-tab.component.html b/src/app/shared/form/builder/ds-dynamic-form-ui/relation-lookup-modal/external-source-tab/dynamic-lookup-relation-external-source-tab.component.html index dac0e03444..cf8cb56577 100644 --- a/src/app/shared/form/builder/ds-dynamic-form-ui/relation-lookup-modal/external-source-tab/dynamic-lookup-relation-external-source-tab.component.html +++ b/src/app/shared/form/builder/ds-dynamic-form-ui/relation-lookup-modal/external-source-tab/dynamic-lookup-relation-external-source-tab.component.html @@ -4,10 +4,10 @@
- - +

{{ 'submission.sections.describe.relationship-lookup.selection-tab.title.' + externalSource.id | translate}}

diff --git a/src/app/shared/search-form/themed-search-form.component.ts b/src/app/shared/search-form/themed-search-form.component.ts new file mode 100644 index 0000000000..a8a511bd35 --- /dev/null +++ b/src/app/shared/search-form/themed-search-form.component.ts @@ -0,0 +1,50 @@ +import { Component, Input, Output, EventEmitter } from '@angular/core'; +import { ThemedComponent } from '../theme-support/themed.component'; +import { SearchFormComponent } from './search-form.component'; + +/** + * Themed wrapper for {@link SearchFormComponent} + */ +@Component({ + selector: 'ds-themed-search-form', + styleUrls: [], + templateUrl: '../../shared/theme-support/themed.component.html', +}) +export class ThemedSearchFormComponent extends ThemedComponent { + + @Input() query: string; + + @Input() inPlaceSearch; + + @Input() scope = ''; + + @Input() currentUrl: string; + + @Input() large = false; + + @Input() brandColor = 'primary'; + + @Input() searchPlaceholder: string; + + @Input() showScopeSelector = false; + + @Output() submitSearch = new EventEmitter(); + + protected inAndOutputNames: (keyof SearchFormComponent & keyof this)[] = [ + 'query', 'inPlaceSearch', 'scope', 'currentUrl', 'large', 'brandColor', 'searchPlaceholder', 'showScopeSelector', + 'submitSearch', + ]; + + protected getComponentName(): string { + return 'SearchFormComponent'; + } + + protected importThemedComponent(themeName: string): Promise { + return import(`../../../themes/${themeName}/app/shared/search-form/search-form.component`); + } + + protected importUnthemedComponent(): Promise { + return import('./search-form.component'); + } + +} diff --git a/src/app/shared/search/search.component.html b/src/app/shared/search/search.component.html index cdad62dcbd..4a601a6c4c 100644 --- a/src/app/shared/search/search.component.html +++ b/src/app/shared/search/search.component.html @@ -79,14 +79,14 @@ - - +
diff --git a/src/app/shared/shared.module.ts b/src/app/shared/shared.module.ts index 37bc28c233..af02d9d13a 100644 --- a/src/app/shared/shared.module.ts +++ b/src/app/shared/shared.module.ts @@ -51,6 +51,7 @@ import { LoadingComponent } from './loading/loading.component'; import { PaginationComponent } from './pagination/pagination.component'; import { ThumbnailComponent } from '../thumbnail/thumbnail.component'; import { SearchFormComponent } from './search-form/search-form.component'; +import { ThemedSearchFormComponent } from './search-form/themed-search-form.component'; import { SearchResultGridElementComponent } from './object-grid/search-result-grid-element/search-result-grid-element.component'; @@ -309,6 +310,7 @@ const COMPONENTS = [ PaginationComponent, RSSComponent, SearchFormComponent, + ThemedSearchFormComponent, PageWithSidebarComponent, SidebarDropdownComponent, ThumbnailComponent, diff --git a/src/themes/custom/app/shared/search-form/search-form.component.html b/src/themes/custom/app/shared/search-form/search-form.component.html new file mode 100644 index 0000000000..e69de29bb2 diff --git a/src/themes/custom/app/shared/search-form/search-form.component.scss b/src/themes/custom/app/shared/search-form/search-form.component.scss new file mode 100644 index 0000000000..e69de29bb2 diff --git a/src/themes/custom/app/shared/search-form/search-form.component.ts b/src/themes/custom/app/shared/search-form/search-form.component.ts new file mode 100644 index 0000000000..5721f8196c --- /dev/null +++ b/src/themes/custom/app/shared/search-form/search-form.component.ts @@ -0,0 +1,14 @@ +import { Component } from '@angular/core'; +import { + SearchFormComponent as BaseComponent, +} from '../../../../../app/shared/search-form/search-form.component'; + +@Component({ + selector: 'ds-search-form', + // styleUrls: ['./search-form.component.scss'], + styleUrls: ['../../../../../app/shared/search-form/search-form.component.scss'], + // templateUrl: './search-form.component.html', + templateUrl: '../../../../../app/shared/search-form/search-form.component.html', +}) +export class SearchFormComponent extends BaseComponent { +} diff --git a/src/themes/custom/lazy-theme.module.ts b/src/themes/custom/lazy-theme.module.ts index e0166780ac..19fc6a0a3e 100644 --- a/src/themes/custom/lazy-theme.module.ts +++ b/src/themes/custom/lazy-theme.module.ts @@ -50,6 +50,7 @@ import { BrowseBySwitcherComponent } from './app/browse-by/browse-by-switcher/br import { CommunityListPageComponent } from './app/community-list-page/community-list-page.component'; import { SearchPageComponent } from './app/search-page/search-page.component'; import { ConfigurationSearchPageComponent } from './app/search-page/configuration-search-page.component'; +import { SearchFormComponent } from './app/shared/search-form/search-form.component'; import { EndUserAgreementComponent } from './app/info/end-user-agreement/end-user-agreement.component'; import { PageNotFoundComponent } from './app/pagenotfound/pagenotfound.component'; import { ObjectNotFoundComponent } from './app/lookup-by-id/objectnotfound/objectnotfound.component'; @@ -133,6 +134,7 @@ const DECLARATIONS = [ CommunityListPageComponent, SearchPageComponent, ConfigurationSearchPageComponent, + SearchFormComponent, EndUserAgreementComponent, PageNotFoundComponent, ObjectNotFoundComponent,