diff --git a/packages/components-angular.zip b/packages/components-angular.zip new file mode 100644 index 0000000000..564991cba3 Binary files /dev/null and b/packages/components-angular.zip differ diff --git a/packages/components-angular/src/index.ts b/packages/components-angular/src/index.ts index 50904aa6f0..a703c7de8f 100644 --- a/packages/components-angular/src/index.ts +++ b/packages/components-angular/src/index.ts @@ -9,6 +9,7 @@ export { AngularDelegate } from './overlays/angular-delegate' // PACKAGE MODULE export { BalCoreModule } from './module' +export { BalSharedModule } from './shared' // HELPERS export { element, parseCustomEvent } from './helpers' diff --git a/packages/components-angular/src/module.ts b/packages/components-angular/src/module.ts index f957c59f4c..e85d0ab73a 100644 --- a/packages/components-angular/src/module.ts +++ b/packages/components-angular/src/module.ts @@ -3,32 +3,13 @@ import { CommonModule, DOCUMENT } from '@angular/common' import { FormsModule } from '@angular/forms' import { appInitialize, BaloiseDesignSystemAngularConfig } from './app-initialize' -import { BooleanValueAccessor } from './directives/boolean-value-accessor' -import { TextValueAccessor } from './directives/text-value-accessor' -import { SelectValueAccessor } from './directives/select-value-accessor' -import { CheckboxValueAccessor } from './directives/checkbox-accessor' -import { NumericValueAccessor } from './directives/number-value-accessor' - -import { AutoFocus } from './focus.directive' import { AngularDelegate, BalAppModule, BalNoticesModule } from '.' -const DECLARATIONS = [ - // directives - AutoFocus, - - // ngModel accessors - CheckboxValueAccessor, - BooleanValueAccessor, - TextValueAccessor, - SelectValueAccessor, - NumericValueAccessor, -] - const MODULES = [BalAppModule, BalNoticesModule] @NgModule({ - declarations: [DECLARATIONS], - exports: [DECLARATIONS, MODULES], + declarations: [], + exports: [MODULES], imports: [CommonModule, FormsModule, MODULES], providers: [AngularDelegate], }) diff --git a/packages/components-angular/src/shared.ts b/packages/components-angular/src/shared.ts new file mode 100644 index 0000000000..af4169d28e --- /dev/null +++ b/packages/components-angular/src/shared.ts @@ -0,0 +1,30 @@ +import { NgModule } from '@angular/core' +import { CommonModule } from '@angular/common' +import { FormsModule } from '@angular/forms' + +import { BooleanValueAccessor } from './directives/boolean-value-accessor' +import { TextValueAccessor } from './directives/text-value-accessor' +import { SelectValueAccessor } from './directives/select-value-accessor' +import { CheckboxValueAccessor } from './directives/checkbox-accessor' +import { NumericValueAccessor } from './directives/number-value-accessor' + +import { AutoFocus } from './focus.directive' + +const DECLARATIONS = [ + // directives + AutoFocus, + + // ngModel accessors + CheckboxValueAccessor, + BooleanValueAccessor, + TextValueAccessor, + SelectValueAccessor, + NumericValueAccessor, +] + +@NgModule({ + declarations: [DECLARATIONS], + exports: [DECLARATIONS], + imports: [CommonModule, FormsModule], +}) +export class BalSharedModule {}