Skip to content

Commit

Permalink
Merge pull request #762 from geonetwork/npm-package
Browse files Browse the repository at this point in the history
NPM package: fix exports
  • Loading branch information
fgravin authored Jan 12, 2024
2 parents 3678ce5 + 705f3a7 commit c15a456
Show file tree
Hide file tree
Showing 26 changed files with 26 additions and 27 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ testem.log
Thumbs.db

.angular
.nx

docs/.vitepress/dist
docs/.vitepress/cache
Expand Down
2 changes: 1 addition & 1 deletion apps/datahub/src/app/app.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ import {
provideRepositoryUrl,
} from '@geonetwork-ui/api/repository'
import { BrowserAnimationsModule } from '@angular/platform-browser/animations'
import { LOGIN_URL, provideGn4 } from '@geonetwork-ui/api/repository/gn4'
import { LOGIN_URL, provideGn4 } from '@geonetwork-ui/api/repository'
import { RecordRelatedRecordsComponent } from './record/record-related-records/record-related-records.component'
import { RecordMetadataComponent } from './record/record-metadata/record-metadata.component'
import { RecordOtherlinksComponent } from './record/record-otherlinks/record-otherlinks.component'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ import { By } from '@angular/platform-browser'
import { FormsModule } from '@angular/forms'
import { FieldFilters } from '@geonetwork-ui/common/domain/model/search'
import { USER_FIXTURE } from '@geonetwork-ui/common/fixtures'
import { AuthService } from '@geonetwork-ui/api/repository/gn4'
import { AuthService } from '@geonetwork-ui/api/repository'
import { PlatformServiceInterface } from '@geonetwork-ui/common/domain/platform.service.interface'

jest.mock('@geonetwork-ui/util/app-config', () => ({
Expand Down
2 changes: 1 addition & 1 deletion apps/map-viewer/src/app/app.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import { storeFreeze } from 'ngrx-store-freeze'
import { environment } from '../environments/environment'
import { provideRepositoryUrl } from '@geonetwork-ui/api/repository'
import { BrowserAnimationsModule } from '@angular/platform-browser/animations'
import { provideGn4 } from '@geonetwork-ui/api/repository/gn4'
import { provideGn4 } from '@geonetwork-ui/api/repository'
import { FeatureAuthModule } from '@geonetwork-ui/feature/auth'
import { FeatureCatalogModule } from '@geonetwork-ui/feature/catalog'

Expand Down
2 changes: 1 addition & 1 deletion apps/metadata-editor/src/app/app.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ import { extModules } from './build-specifics'
import { DashboardPageComponent } from './dashboard/dashboard-page.component'
import { EditorRouterService } from './router.service'
import { provideRepositoryUrl } from '@geonetwork-ui/api/repository'
import { provideGn4 } from '@geonetwork-ui/api/repository/gn4'
import { provideGn4 } from '@geonetwork-ui/api/repository'

@NgModule({
declarations: [AppComponent],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import { EffectsModule } from '@ngrx/effects'
import { TranslateModule } from '@ngx-translate/core'
import { TRANSLATE_DEFAULT_CONFIG } from '@geonetwork-ui/util/i18n'
import { PlatformServiceInterface } from '@geonetwork-ui/common/domain/platform.service.interface'
import { AvatarServiceInterface } from '@geonetwork-ui/api/repository/gn4'
import { AvatarServiceInterface } from '@geonetwork-ui/api/repository'

class AvatarServiceInterfaceMock {
getPlaceholder = () => of('http://placeholder.com')
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { MatIconModule } from '@angular/material/icon'
import { LetDirective } from '@ngrx/component'
import { FeatureSearchModule } from '@geonetwork-ui/feature/search'
import { UiElementsModule } from '@geonetwork-ui/ui/elements'
import { AvatarServiceInterface } from '@geonetwork-ui/api/repository/gn4'
import { AvatarServiceInterface } from '@geonetwork-ui/api/repository'
import { PlatformServiceInterface } from '@geonetwork-ui/common/domain/platform.service.interface'

@Component({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import {
USER_FIXTURE_ANON,
USERS_FIXTURE,
} from '@geonetwork-ui/common/fixtures'
import { AuthService } from '@geonetwork-ui/api/repository/gn4'
import { AuthService } from '@geonetwork-ui/api/repository'
import { SearchFacade } from '@geonetwork-ui/feature/search'

describe('MyOrgUsersComponent', () => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import {
USER_FIXTURE_ANON,
USERS_FIXTURE,
} from '@geonetwork-ui/common/fixtures'
import { AuthService } from '@geonetwork-ui/api/repository/gn4'
import { AuthService } from '@geonetwork-ui/api/repository'
import { SearchFacade } from '@geonetwork-ui/feature/search'
import { OrganizationsServiceInterface } from '@geonetwork-ui/common/domain/organizations.service.interface'
import { EditorRouterService } from '../../router.service'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import { TranslateModule } from '@ngx-translate/core'
import { RecordsListComponent } from '../records-list.component'
import { BehaviorSubject, of } from 'rxjs'
import { USER_FIXTURE } from '@geonetwork-ui/common/fixtures'
import { AuthService } from '@geonetwork-ui/api/repository/gn4'
import { AuthService } from '@geonetwork-ui/api/repository'
import { EditorRouterService } from '../../router.service'
import { PlatformServiceInterface } from '@geonetwork-ui/common/domain/platform.service.interface'

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { CommonModule } from '@angular/common'
import { TranslateModule } from '@ngx-translate/core'
import { RecordsListComponent } from '../records-list.component'
import { FieldsService, SearchFacade } from '@geonetwork-ui/feature/search'
import { AuthService } from '@geonetwork-ui/api/repository/gn4'
import { AuthService } from '@geonetwork-ui/api/repository'
import { EditorRouterService } from '../../router.service'
import { Subscription } from 'rxjs'
import { PlatformServiceInterface } from '@geonetwork-ui/common/domain/platform.service.interface'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { Router } from '@angular/router'
import { BehaviorSubject } from 'rxjs'
import { CommonModule } from '@angular/common'
import { MatIconModule } from '@angular/material/icon'
import { SelectionService } from '@geonetwork-ui/api/repository/gn4'
import { SelectionService } from '@geonetwork-ui/api/repository'
import { DATASET_RECORDS } from '@geonetwork-ui/common/fixtures'

const results = [{ md: true }]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { UiSearchModule } from '@geonetwork-ui/ui/search'
import { UiElementsModule } from '@geonetwork-ui/ui/elements'
import { SortByField } from '@geonetwork-ui/common/domain/model/search'
import { TranslateModule } from '@ngx-translate/core'
import { SelectionService } from '@geonetwork-ui/api/repository/gn4'
import { SelectionService } from '@geonetwork-ui/api/repository'
import { Subject } from 'rxjs'

const includes = [
Expand Down
2 changes: 1 addition & 1 deletion apps/webcomponents/src/app/webcomponents.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ import { GnDatasetViewChartComponent } from './components/gn-dataset-view-chart/
import { FeatureDatavizModule } from '@geonetwork-ui/feature/dataviz'
import { FeatureAuthModule } from '@geonetwork-ui/feature/auth'
import { BrowserAnimationsModule } from '@angular/platform-browser/animations'
import { provideGn4 } from '@geonetwork-ui/api/repository/gn4'
import { provideGn4 } from '@geonetwork-ui/api/repository'

const CUSTOM_ELEMENTS: [new (...args) => BaseComponent, string][] = [
[GnFacetsComponent, 'gn-facets'],
Expand Down
1 change: 1 addition & 0 deletions libs/api/repository/src/index.ts
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
export * from './lib/metadata-language'
export * from './lib/repository-url'
export * from './lib/gn4'
2 changes: 1 addition & 1 deletion libs/feature/auth/src/lib/feature-auth.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ import { CommonModule } from '@angular/common'
import {
AvatarServiceInterface,
GravatarService,
} from '@geonetwork-ui/api/repository/gn4'
} from '@geonetwork-ui/api/repository'

@NgModule({
imports: [CommonModule],
Expand Down
2 changes: 1 addition & 1 deletion libs/feature/catalog/src/lib/feature-catalog.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import {
OrganizationsFromGroupsService,
OrganizationsFromMetadataService,
OrganizationsStrategy,
} from '@geonetwork-ui/api/repository/gn4'
} from '@geonetwork-ui/api/repository'
import { PlatformServiceInterface } from '@geonetwork-ui/common/domain/platform.service.interface'

// expects the replacement key ${name}
Expand Down
2 changes: 1 addition & 1 deletion libs/feature/catalog/src/lib/my-org/my-org.service.spec.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { TestBed } from '@angular/core/testing'
import { MyOrgService } from './my-org.service'
import { AvatarServiceInterface } from '@geonetwork-ui/api/repository/gn4'
import { AvatarServiceInterface } from '@geonetwork-ui/api/repository'
import { OrganizationsServiceInterface } from '@geonetwork-ui/common/domain/organizations.service.interface'
import { BehaviorSubject, of } from 'rxjs'
import { UserApiModel } from '@geonetwork-ui/data-access/gn4'
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import { ChangeDetectionStrategy, NO_ERRORS_SCHEMA } from '@angular/core'
import { TranslateModule, TranslateService } from '@ngx-translate/core'
import tippy from 'tippy.js'
import { DATASET_RECORDS } from '@geonetwork-ui/common/fixtures'
import { FavoritesService } from '@geonetwork-ui/api/repository/gn4'
import { FavoritesService } from '@geonetwork-ui/api/repository'
import { PlatformServiceInterface } from '@geonetwork-ui/common/domain/platform.service.interface'

tippy = jest.fn()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,7 @@ import { TranslateService } from '@ngx-translate/core'
import { StarToggleComponent } from '@geonetwork-ui/ui/inputs'
import { Observable, Subscription } from 'rxjs'
import { CatalogRecord } from '@geonetwork-ui/common/domain/model/record'
import {
AuthService,
FavoritesService,
} from '@geonetwork-ui/api/repository/gn4'
import { AuthService, FavoritesService } from '@geonetwork-ui/api/repository'
import { PlatformServiceInterface } from '@geonetwork-ui/common/domain/platform.service.interface'

@Component({
Expand Down
2 changes: 1 addition & 1 deletion libs/feature/search/src/lib/feature-search.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ import { FilterDropdownComponent } from './filter-dropdown/filter-dropdown.compo
import { Geometry } from 'geojson'
import { UiWidgetsModule } from '@geonetwork-ui/ui/widgets'
import { RecordsRepositoryInterface } from '@geonetwork-ui/common/domain/repository/records-repository.interface'
import { Gn4Repository } from '@geonetwork-ui/api/repository/gn4'
import { Gn4Repository } from '@geonetwork-ui/api/repository'

// this geometry will be used to filter & boost results accordingly
export const FILTER_GEOMETRY = new InjectionToken<Promise<Geometry>>(
Expand Down
2 changes: 1 addition & 1 deletion libs/feature/search/src/lib/state/effects.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ import { delay } from 'rxjs/operators'
import { FILTER_GEOMETRY } from '../feature-search.module'
import { RecordsRepositoryInterface } from '@geonetwork-ui/common/domain/repository/records-repository.interface'
import { TestScheduler } from 'rxjs/internal/testing/TestScheduler'
import { FavoritesService } from '@geonetwork-ui/api/repository/gn4'
import { FavoritesService } from '@geonetwork-ui/api/repository'
import { PlatformServiceInterface } from '@geonetwork-ui/common/domain/platform.service.interface'

const defaultSearchState = initialState[DEFAULT_SEARCH_KEY]
Expand Down
2 changes: 1 addition & 1 deletion libs/feature/search/src/lib/state/effects.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ import { switchMapWithSearchId } from '../utils/operators/search.operator'
import { Geometry } from 'geojson'
import { FILTER_GEOMETRY } from '../feature-search.module'
import { RecordsRepositoryInterface } from '@geonetwork-ui/common/domain/repository/records-repository.interface'
import { FavoritesService } from '@geonetwork-ui/api/repository/gn4'
import { FavoritesService } from '@geonetwork-ui/api/repository'
import { PlatformServiceInterface } from '@geonetwork-ui/common/domain/platform.service.interface'
import { valid as validGeoJson } from 'geojson-validation'

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { ToolsApiService } from '@geonetwork-ui/data-access/gn4'
import { TranslateModule } from '@ngx-translate/core'
import { OrganizationsServiceInterface } from '@geonetwork-ui/common/domain/organizations.service.interface'
import { RecordsRepositoryInterface } from '@geonetwork-ui/common/domain/repository/records-repository.interface'
import { ElasticsearchService } from '@geonetwork-ui/api/repository/gn4'
import { ElasticsearchService } from '@geonetwork-ui/api/repository'
import { PlatformServiceInterface } from '@geonetwork-ui/common/domain/platform.service.interface'

class RecordsRepositoryMock {
Expand Down
2 changes: 1 addition & 1 deletion libs/feature/search/src/lib/utils/service/fields.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ import { Injector } from '@angular/core'
import { TranslateModule, TranslateService } from '@ngx-translate/core'
import { OrganizationsServiceInterface } from '@geonetwork-ui/common/domain/organizations.service.interface'
import { Organization } from '@geonetwork-ui/common/domain/model/record'
import { ElasticsearchService } from '@geonetwork-ui/api/repository/gn4'
import { ElasticsearchService } from '@geonetwork-ui/api/repository'
import { RecordsRepositoryInterface } from '@geonetwork-ui/common/domain/repository/records-repository.interface'
import { PlatformServiceInterface } from '@geonetwork-ui/common/domain/platform.service.interface'

Expand Down
2 changes: 1 addition & 1 deletion libs/feature/search/src/lib/utils/service/fields.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import {
FieldFilters,
TermBucket,
} from '@geonetwork-ui/common/domain/model/search'
import { ElasticsearchService } from '@geonetwork-ui/api/repository/gn4'
import { ElasticsearchService } from '@geonetwork-ui/api/repository'
import { LangService } from '@geonetwork-ui/util/i18n'

export type FieldValue = string | number
Expand Down

0 comments on commit c15a456

Please sign in to comment.