0

I'm using the ng-carousel https://github.com/ng-bootstrap/ng-bootstrap/blob/master/src/carousel/carousel.ts and I want to have different prev/next icons. I'm interested in using the font-awesome ones as opposed to the ones that are there by default. Is it possible to change the template css classes that are used somehow or do I have to extend that component and write my own template (like suggested here Angular2: How to override components template?)?

Thanks

UPDATE:

Perhaps I need to rephrase the question:

I'd like to do the equivalent of changing/swapping CSS classes:

.carousel-control-prev-icon {
  /* extend FontAwesome left chevron*/
  @extend .fa-chevron-left;
}

but I'm not using Sass.

Carlos Torrecillas
  • 4,965
  • 7
  • 38
  • 69
  • What code have you attempted? what were your results? – happymacarts Aug 30 '17 at 15:04
  • Has your question anything with [this one](https://stackoverflow.com/questions/43610229/how-modify-css-of-ng-bootstrap-carousel-using-angular-2)? – skobaljic Aug 30 '17 at 15:05
  • Its totally possible, but without seeing any code its not possible to tell you how to do it in your case. – sn3ll Aug 30 '17 at 15:13
  • It's very related to the this issue: https://github.com/twbs/bootstrap/issues/21985 --> basically the solution offered by using Sass where you can replace classes with other classes is what I wanted using @extend but I have plain css, that's why I didn't know whether you can "easily" add to a third party component element without too much hassle / dirtiness. I thought of inheriting from that class and attach my custom template to it but I'm not sure if that's the best way to achieve it. – Carlos Torrecillas Aug 30 '17 at 15:17

1 Answers1

0

Look into this official documentation part on CSS special selectors : https://angular.io/guide/component-styles#special-selectors

You should be able to change the CSS using special selector (such as /deep/) to customize it to your own tastes.

Alex Beugnet
  • 4,003
  • 4
  • 23
  • 40
  • 3
    Link-only answers are discouraged as links can become obsolete over time. Please include the relevant sections of the linked page in your answer. – FluffyKitten Aug 30 '17 at 16:51