What are the available options for `card-detail-badges` in power-ups?

Hi there.
In the current docs, card-detail-badges does not have its options explicitly defined, while card-badges does.

(for context, I spent quite some time trying to set a badge icon to no avail - no icon was displayed, but no errors were shown either)

Is anyone please able to confirm that the valid card badge details are as follows?

Property    Type         Notes
-----------------------------
dynamic     function     Must be used in isolation
refresh     number       Optional; can be set in the returned output of a `dynamic` function
Property    Type         Notes
-----------------------------
title       string       Optional
text        string       
color       string       Optional, must be one of a predefined list of color names
callback    function     Optional, mutually exclusive with `url`
url         string       Optional, see `callback`
target      string       Optional, can be used in conjunction with `url`

Thanks in advance.

You nailed it. Sorry we didn’t already have these documented. Working on adding it in now. Does the following read correctly to you?

Hi, Bentley - yup, that reads fine. :clap:
Just two things:

  • you may want to have the same definition for dynamic as the one already in the card-badges docs; that one also offers a suggestion of when it is appropriate to use dynamic.
    Up to you, of course, but at the very least I think the two should be identical, to avoid confusion;
  • you have a typo in the description for refresh (“Number the number”) :upside_down_face:
    Apologies for being picky… I guess someone has to do it :sweat_smile:

Thanks for getting back to me! :+1:

1 Like

Derp. Yeah, copying what we already have makes a lot of sense.

It took me a minute, but they’re updated: https://developer.atlassian.com/cloud/trello/power-ups/capabilities/card-detail-badges/

1 Like