aurelia-ui-toolkits / aurelia-kendoui-bridge

MIT License
117 stars 31 forks source link

ak controls inside ak-tooltip not rendering #786

Open aletiro opened 6 years ago

aletiro commented 6 years ago

I'm trying to show an ak-chart inside of an ak-tooltip. The ak-chart is being loaded through an ak-template.

When I hover over the target, the tooltip shows, but it is blank. It can display some text and images, but the ak-chart does not render. If I take the ak-chart out of the ak-template, and put it elsewhere it displays fine, so I suppose that all resources loaded correctly. I can even see the HTML loaded fine in the page source but the controls are not rendering in the tooltip. I tried it with other controls like the ak-barcode, and with the content-template instead of aurelia-template, but it's not showing.

Here is the gist.run to reproduce the issue:

With kendoUI this should be possible, as seen here

arnederuwe commented 6 years ago

I couldn't immediately figure out why the gist doesn't work, so I tried reproducing this locally, and there it works fine.. Can you tell me what version of kendo/bridge you are using? Perhaps the issue lies there

aletiro commented 6 years ago

the Gist is same as the one used for the tooltip with aurelia-template, i just added the barcode inside the template. I've got a kendo pro license, shouldn't be the issue, since the chart or barcode display when put somewhere else but inside of the tooltip. Would you be able to share your code?

arnederuwe commented 6 years ago

it seems that the loaded wrappers are not recognized in the ak-template. You can work around this by loading the wrappers manually in main.ts, see: https://gist.run/?id=de7b9a981cd73d28b0132331a5cffbb0 @JeroenVinke , is there any way to require stuff inside ak-templates? As the above workaround is not suitable for each project

JeroenVinke commented 6 years ago

I don't think Aurelia's enhance processes <require> elements. Currently you either have to globally register the things that you'd like to use in the ak-template (from main.js) or use require in the view which contains the ak-template, as @arnederuwe said

JeroenVinke commented 6 years ago

I tried to do this but that doesn't work for some reason

aletiro commented 6 years ago

So what are we going to do with this issue? Should I leave it open to be fixed, or close it? I'm fine with preloading the components, it's not that big of a deal in my case, but someone might have performance issues.