Select to view content in your preferred language

Custom widget match theme/text size?

2631
2
10-22-2015 09:49 AM
BenSaunders1
Regular Contributor

Is there any way when creating a custom JavaScript widget for the Operations Dashboard to have it match the theme or text size selected by the user? Obviously I can replicate specific font colors and sizes for the individual themes (Light, Medium, and Dark) and text sizes (Small, Medium, and Large), but how do we get the style of the custom widget to respond to the user changing either one of those things? For example, I can match the Dark theme and Medium text size:

But if the user changes to the Light theme and Small text size, things don't look so good:

Thanks for any assistance!

Ben

0 Kudos
2 Replies
TifPun
by
Frequent Contributor

Hi Ben,

At this point our extensibility framework isn't capable of detecting theme switching, but this is definitely one of the features we want to do in out future release. For now, you might want to consider adding background color for your extension (see our elevation profile sample).

Cheers,

Tif

BenSaunders1
Regular Contributor

Thanks for the reply, Tif! I've gone ahead and have been using some Bootstrap templates that have worked fine.

In the meantime I look forward to that enhancement!

Thanks,

Ben

0 Kudos