enso-org / enso

Enso Analytics is a self-service data prep and analysis platform designed for data teams.
https://ensoanalytics.com
Apache License 2.0
7.38k stars 323 forks source link

Setting headers option for Delimited_Format.Delimited doesn't render correctly #9002

Closed AdRiley closed 8 months ago

AdRiley commented 9 months ago

Use Case:

I have a csv file that has a header row that the auto-detect mechanism doesn't detect. So I switch to Delimited_Format.Delimited so I can manually set the headers value.

I click headers

image

So far so good. And choose True.

image

I get the result I want in the data, but there are now two issues:

  1. header= is missing image
  2. There is no way to switch the option back to Infer. I can toggle it between True and False, but not to Infer.
farmaazon commented 9 months ago

After today @vitvakatu's fixes, you see the arrow down which allows you to pick Infer...

...however, the actual design does not expect clicking at arrows. Boolean widget does not have "editing" state. Perhaps we should just forbid somehow checkbox inside drop downs?

header is still gone.

AdRiley commented 9 months ago

How about rendering as a checkbox, but when you click it opens the dropdown menu again?

farmaazon commented 9 months ago

Ok, header caption is hidden by default - because we display argument name only when it's not set or when it's a top-level argument. Here, the headers is not (top-level arguments are those of Data.read), and once we set value, well, the value is set.

I'm not sure how to proceed @jdunkerley @wdanilo . This design is taken from the old GUI (but there we don't display checkbox widgets). I could:

  1. display not the argument name in placeholders (without value) with widgets if they would not with value set (to keep consistency)
  2. always display argument name in checkbox widget
  3. always display argument name, also for non-toplevel ones with value set.
jdunkerley commented 9 months ago

You are correct old IDE didn't show once we had chosen a value.

If it wasn't the first argument we did get "labels" in the old one: image

Especially on Boolean values we need it (e.g. skip rows just becomes a tick box).

Up to @wdanilo for design but I think a label of some form is useful

farmaazon commented 9 months ago

For this task scope, I will just always display header in boolean widget (expecting that other widgets may need label as well)