From 1bf950e7f324ee6a17e4eaceb5f3225d2585526c Mon Sep 17 00:00:00 2001 From: Alexis Georges Date: Mon, 4 Feb 2019 09:58:39 +0100 Subject: [PATCH] feat(stark-all): refine exports for the services ISSUES CLOSED: #1112 --- packages/stark-ui/src/modules/app-sidebar/services.ts | 2 +- packages/stark-ui/src/modules/message-pane/services.ts | 2 +- .../stark-ui/src/modules/progress-indicator/services.ts | 2 +- .../stark-ui/src/modules/toast-notification/services.ts | 2 +- .../toast-notification/testing/toast-notification.mock.ts | 8 ++++---- 5 files changed, 8 insertions(+), 8 deletions(-) diff --git a/packages/stark-ui/src/modules/app-sidebar/services.ts b/packages/stark-ui/src/modules/app-sidebar/services.ts index 443adf2c26..20f98911d9 100644 --- a/packages/stark-ui/src/modules/app-sidebar/services.ts +++ b/packages/stark-ui/src/modules/app-sidebar/services.ts @@ -1,3 +1,3 @@ export * from "./services/app-sidebar.service"; -export * from "./services/app-sidebar.service.intf"; +export { STARK_APP_SIDEBAR_SERVICE, StarkAppSidebarService } from "./services/app-sidebar.service.intf"; export * from "./services/app-sidebar-open-event.intf"; diff --git a/packages/stark-ui/src/modules/message-pane/services.ts b/packages/stark-ui/src/modules/message-pane/services.ts index 0dfb80b12b..0f8a58fecd 100644 --- a/packages/stark-ui/src/modules/message-pane/services.ts +++ b/packages/stark-ui/src/modules/message-pane/services.ts @@ -1,2 +1,2 @@ -export * from "./services/message-pane.service.intf"; +export { STARK_MESSAGE_PANE_SERVICE, StarkMessagePaneService } from "./services/message-pane.service.intf"; export * from "./services/message-pane.service"; diff --git a/packages/stark-ui/src/modules/progress-indicator/services.ts b/packages/stark-ui/src/modules/progress-indicator/services.ts index 84d6654c2c..84200275ad 100644 --- a/packages/stark-ui/src/modules/progress-indicator/services.ts +++ b/packages/stark-ui/src/modules/progress-indicator/services.ts @@ -1,2 +1,2 @@ -export * from "./services/progress-indicator.service.intf"; +export { STARK_PROGRESS_INDICATOR_SERVICE, StarkProgressIndicatorService } from "./services/progress-indicator.service.intf"; export * from "./services/progress-indicator.service"; diff --git a/packages/stark-ui/src/modules/toast-notification/services.ts b/packages/stark-ui/src/modules/toast-notification/services.ts index 8d86438169..788db62d91 100644 --- a/packages/stark-ui/src/modules/toast-notification/services.ts +++ b/packages/stark-ui/src/modules/toast-notification/services.ts @@ -1,4 +1,4 @@ -export * from "./services/toast-notification.service.intf"; +export { STARK_TOAST_NOTIFICATION_SERVICE, StarkToastNotificationService } from "./services/toast-notification.service.intf"; export * from "./services/toast-notification.service"; export * from "./services/toast-notification-result.intf"; export * from "./services/toast-notification-option.intf"; diff --git a/packages/stark-ui/src/modules/toast-notification/testing/toast-notification.mock.ts b/packages/stark-ui/src/modules/toast-notification/testing/toast-notification.mock.ts index 7a86b834ac..031a20027c 100644 --- a/packages/stark-ui/src/modules/toast-notification/testing/toast-notification.mock.ts +++ b/packages/stark-ui/src/modules/toast-notification/testing/toast-notification.mock.ts @@ -10,7 +10,7 @@ import { StarkToastMessage, StarkToastNotificationResult, StarkToastNotification * You can use it in your unit tests by providing it while configuring the testing module in the TestBed. For example: * ```typescript * import { STARK_TOAST_NOTIFICATION_SERVICE } from "@nationalbankbelgium/stark-ui"; - * import { MockToastNotificationService } from "@nationalbankbelgium/stark-ui/testing"; + * import { MockStarkToastNotificationService } from "@nationalbankbelgium/stark-ui/testing"; * * describe("Some test", () => { * @@ -20,9 +20,9 @@ import { StarkToastMessage, StarkToastNotificationResult, StarkToastNotification * declarations: [...], * providers: [ * // provide is as a value - * { provide: STARK_TOAST_NOTIFICATION_SERVICE, useValue: new MockToastNotificationService() }, + * { provide: STARK_TOAST_NOTIFICATION_SERVICE, useValue: new MockStarkToastNotificationService() }, * // or as a class - * { provide: STARK_TOAST_NOTIFICATION_SERVICE, useClass: MockToastNotificationService } + * { provide: STARK_TOAST_NOTIFICATION_SERVICE, useClass: MockStarkToastNotificationService } * ] * }).compileComponents(); * })); @@ -30,7 +30,7 @@ import { StarkToastMessage, StarkToastNotificationResult, StarkToastNotification * } * ``` */ -export class MockToastNotificationService implements StarkToastNotificationService { +export class MockStarkToastNotificationService implements StarkToastNotificationService { /** * Returns an observable that will emit one of the possible StarkToastNotificationResult after the toast is closed * @param message - Message to be shown in the toast.