Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
Is there a way to handle / modify the Qlik CurrentSelections object through the Visualisation API?
I know I can use the Selection API to create my own viz, but I wonder if I can just change some options on this grey standard selection bar from Qlik.
Thank you
Regards
Daniel
Hi @danieloberbilli ,
There's a "secret" option for getting the previous dark version of the current selection bar:
// @param {string} [options.variant] - used only when getting 'CurrentSelections', for rendering the "dark" variant. Possible values: "dark". {@x-qlik-visibility private}
app.getObject('elementId', 'CurrentSelections', {variant: 'dark'});
Modifying the CSS by overriding it works, but there's no guarantee that your styles will still work if you upgrade Qlik Sense.
Third alternative is to use the Themes API, while I am not 100% sure how much we support styling the current selection bar.
I hope this helps
What kind of changes ?
If u show it in a mashup u can make many changes to the design or hide buttons using css.
Hi @danieloberbilli ,
There's a "secret" option for getting the previous dark version of the current selection bar:
// @param {string} [options.variant] - used only when getting 'CurrentSelections', for rendering the "dark" variant. Possible values: "dark". {@x-qlik-visibility private}
app.getObject('elementId', 'CurrentSelections', {variant: 'dark'});
Modifying the CSS by overriding it works, but there's no guarantee that your styles will still work if you upgrade Qlik Sense.
Third alternative is to use the Themes API, while I am not 100% sure how much we support styling the current selection bar.
I hope this helps
Thank you for your reply, @oz_moyal. Yes, you are right, I played around with custom css as well but it feels more like a hack 🙂 But I guess that's the only way to visually modify it without rebuilding the object yourself.
Cheers
Dan
Thank you, @Aiham_Azmeh. That's interesting and maybe they extend the API a bit further in the future. I never looked at the Theme API but will investigate this next. Thanks again for your reply.
Cheers
Dan