Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
swamisharma
Frequent Visitor

Color Picker without color palette, need to have only conditional formatting button

Hello All,
I am currently working on custom visual formatting pane to add a color picker without the color palette button (color dropdown next to `fx` button), just need to have conditional formatting button (this fx button)
Current UI looks like

swamisharma_0-1753871634450.png

Expected (This is from Table visual > Format Pane > Cell Element Card)

swamisharma_1-1753871695632.png

I am currently using "Color Picker slice"

and this is my code in capabilities

"objects": {
        "values": {
            "properties": {
               "conditionalColor": {
                    "type": {
                        "fill": {
                            "solid": {
                                "color": true
                            }
                        }
                    }
                }
            }
        }
    }

 

3 REPLIES 3
swamisharma
Frequent Visitor

Hello @dm-p ,
We are already using the same enum while creating slices in formatting pane
Please refer the code attached

conditionalColor = new formattingSettings.ColorPicker({
        name: "conditionalColor",
        displayName: "Color",
        value: { value: undefined },
        altConstantSelector: null,
        instanceKind: powerbi.VisualEnumerationInstanceKinds.Rule,
        selector: dataViewWildcard.createDataViewWildcardSelector(dataViewWildcard.DataViewWildcardMatchingOption.InstancesAndTotals)
});

Can you please share how to create a support ticket?

That looks correct. I've just tried it myself, and it might be a quirk of how the powerbi-visuals-utils-formattingmodel classes abstract a lot of the work away and handle the rendering of the newer formatting pane components. I confess, the last time I wanted this specific situation was before these utilities were made available, and you had to construct the formatting model using the visual host directly.

 

I would indeed suggest asking the custom visuals team for an example they can give you. You can contact them at pbicvsupport@microsoft.com

 

Best of luck (and if you get a workable example, it would be great to know if it's possible!),

 

Daniel





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!


On how to ask a technical question, if you really want an answer (courtesy of SQLBI)




dm-p
Super User
Super User

Hi @swamisharma,

 

When you set up conditional formatting, you specify a VisualEnumerationInstanceKinds enum value as part of the properties. This should be set to Rule if you only wany the button and not the typical element rendered for the property.

 

If you are trying this and it doesn't work you will need to create a support issue, as it will be a bug.

 

Regards,

 

Daniel





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!


On how to ask a technical question, if you really want an answer (courtesy of SQLBI)




Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors
Top Kudoed Authors