Qlik Sense Extension - Measures property panel - Define purpose of measures
In Qlikview extensions, I could explicitly provide a label for each of the measures I wanted my user to use. In the end, this was just a clarification or my convention to make the users' life easier; as a developers I still accessed measures or measures and I had to again apply each to its specific purpose (i.e. it's not like Qlikview NAMED my measures for me; like measures['tooltip'], measures['background-color']
In Qlik Sense, there is the "measures" property panel; but I can't even clarify what the default measures should be?
Measure: title text for hover popup (optional), default title is start date
Measure: CSS class name for styling or number 1 to 10 for CSS class color-a to color-j which are configured for Qlik Sense diverging colors (blue-to-red, optional)
Measure: group name to group items in "swim lanes" (optional)
Maybe I can use the extension initialProperties instead of the definition or the measures property panel, but I can't find an example yet, so I'm still searching.
Just to be clear, I want a way to communicate user how each Measure will be used by my extension (i.e. for a tooltip, for a background color). If I could prepopulate my extension to look like this, that'd be great:
Re: Qlik Sense Extension - Measures property panel - Define purpose of measures
I'm still curious if I can force the user to fill out exactly 3 measures, each of which has a static label that defines its purpose.
Notice this solution has nothing to do with initialProperties as I speculated. Instead it uses the items property of the measures object, so I could customize what user can specify about a given measure.
While this is great, I'm not sure how to READ this property from inside my extension, so I know which measure the user wants with which treatment. Oh! Now I see: It's available on the relevant measureDef element of the array layout.hyperCube.qMeasureInfo. From the amGraph type above. Note, you must save (Ctrl+S) the configuration you apply; the "amGraph.type" you pick, in order for this behavior to continue in normal "Done" mode after a refresh!