Hello
I have an issue with creating a custom visual in which I need to be able to set 2 different font sizes from the property pane. The issue is that the first font size control is a slider which allows values from 8-40 whereas subsequent controls allow 0-100 percent.
I can show this using the basic new visualisation
pbiviz new fontVisual
npm install
Then edit capabilities.json to include a second font size property (in this case "fontSize1")
}, "fontSize": { "displayName": "Text Size", "type": { "formatting": { "fontSize": true } } }, "fontSize1": { "displayName": "Text Size 1", "type": { "formatting": { "fontSize": true } } }
Update settings.ts to include the new property
// Text Size public fontSize: number = 12; public fontSize1: number = 12;
Then build and run
pbiviz start
This is the result
Image may be NSFW.
Clik here to view.2 different font size controls
Is this the expected behaviour? Or is the second font size meant to be a percentage of the first? If not, Is there any way I can make them the same control?
Thanks