Uikit with interpolation in Angular 7

Asked

Viewed 137 times

-1

I’m using Uikit with Angular 7, and at the moment I’m trying to set the value of 'title' tooltip coming from the Angular component, something like:

<progress class="uk-progress" max="{{rodadas.length}}" value="{{rodadaVigente}}" uk-tooltip="title: {{nomeRodadaVigente}}; pos: bottom"></progress>

Plus I get an exception! Does anyone know how to get around this problem?

1 answer

1


At the angle to set a property of an html or component based on a property of your ts just use brackets instead of the normal property. Directive differences in Angular

<progress class="uk-progress" [max]="rodadas.length" [value]="rodadaVigente"
 [uk-tooltip]="nomeRodadaVigente"></progress>
  • I made the following attempts: [uk-tooltip]="title: {rodadaVigente}}; pos: bottom" / [uk-tooltip]="title: rodadaVigente; pos: bottom", unsuccessfully! I get the following exception: (Compiler.js:2427 Uncaught Error: Template parse errors: Can’t bind to 'uk-tooltip' Since it isn’t a known Property of 'Progress'. ("removes">...)

  • Did you make that component? It seems that he did not find the uk tooltip component and he will not understand this interpolation you have to create a correct property in your typescript and pass it to him.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.