# Style problem with components not in the root module

**URL:** <https://forum.ionicframework.com/t/style-problem-with-components-not-in-the-root-module/65748>\
**Category:** ionic-v3\
**Created:** [October 4, 2016, 2:50pm UTC](https://forum.ionicframework.com/t/style-problem-with-components-not-in-the-root-module/65748 "2016-10-04T14:50:20Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Eusèbe](https://sea1.discourse-cdn.com/ionicframework/user_avatar/forum.ionicframework.com/eus%C3%A8be/32/72170_2.png) [@Eusèbe](https://forum.ionicframework.com/u/Eus%C3%A8be)\
**Post date:** [October 4, 2016, 2:50pm UTC](https://forum.ionicframework.com/t/style-problem-with-components-not-in-the-root-module/65748/1 "2016-10-04T14:50:20Z")

</div>

I’m trying to add a home-made keyboard with ion-buttons.  
The keyboard is a NG2 component, declared in a specific module (KeyboardModule), which gives the following html:

> ```
> <ion-content>
> <div class='fixed-content'>
> <ion-content>
> <custom-button-in-App-module>
> <button ion-button>a component inside AppModule</button> <!-- this one has the expected style -->
> </custom-button-in-App-module>
> <keyboard>
> <button ion-button>a component inside another module</button> <!-- this one is displayed with no style --> 
> </keyboard>
> </div>
> </ion-content>
> 
> ```

I tried to isolate the problem by creating a new button component in the AppModule (the default one): the style is correct.  
It seems the reason why I lose style is the fact that my Keyboard component is embedded in another module.

Any idea how to get the ionic style in my new module ?

[sources here](https://bitbucket.org/Eusebe/testionic/)

---

<div class="post-metadata">

**Author:** ![waybackrider](https://avatars.discourse-cdn.com/v4/letter/w/8e7dd6/32.png) [@waybackrider](https://forum.ionicframework.com/u/waybackrider)\
**Post date:** [August 2, 2017, 12:45pm UTC](https://forum.ionicframework.com/t/style-problem-with-components-not-in-the-root-module/65748/2 "2017-08-02T12:45:37Z")

</div>

Look at this answer:

> [@Ionic - Shared Component Issue](https://forum.ionicframework.com/t/ionic-3-shared-component-issue/89676):
>
> Hi, In our project, we are migrating from Ionic 2 to 3 and we face the below issue : If a component is imported as a “Shared” (shared/shared.module.ts) one, the default ion styles not getting applied on to ion tags. But, when this component is imported in only one page, the output is proper. Out put given below : Code that is placed : \<ion-navbar color=“topnav”\> After rendering of the same code, if its imported in only one page : \<ion-navbar class=“toolbar toolbar-ios toolbar-ios-topnav” c…
