kiln / flourish-sdk

The SDK for developing Flourish templates
Other
79 stars 16 forks source link

Conditional settings based on data types do not work in the SDK #49

Open theduncanclark opened 5 years ago

theduncanclark commented 5 years ago

For example if a setting has…

show_if: data.my_binding

… the setting will never show up in the SDK, whereas in the main app the setting will show and hide as designed, based on whether the binding is set.

theduncanclark commented 4 years ago

I'd like to bump this as it continues to be very frustrating when developing templates.

animateddata commented 4 years ago

I've just encountered this one again too!

peterrcook-canva commented 2 years ago

Conditions such as:

data.points.value: true

seem to work ok in the SDK, but ones based on data types such as:

data.choropleth.value.type: number

work in the main app, but not the SDK.

peterrcook-canva commented 1 year ago

Another related case that works in published templates, but not the SDK is:

    overrides:
      - tag: discrete
        method: extend
        show_if:
          data.data.color.type: string
      - tag: numeric
        method: extend
        show_if:
          data.data.color.type: number