Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Design update for extract examples #42399

Merged
merged 4 commits into from
May 15, 2024

Conversation

romeovs
Copy link
Contributor

@romeovs romeovs commented May 8, 2024

Closes #42375

Description

Render the examples for Extract Column inline instead of underneath the title.

How to verify

Describe the steps to verify that the changes are working as expected.

  1. New question -> Sample Dataset -> Custom Column
  2. Select Extract column
  3. Select a column
  4. Verify that the examples render inline, not underneath the titles

Demo

Screenshot 2024-05-07 at 18 13 41 Screenshot 2024-05-08 at 16 49 10

Notes

I updated the horizontal ClickActionsControl to use Button from metabase/ui for this, instead of the deprecated Button. I can convert the rest to use CSS modules too if that is preferred.

@romeovs romeovs added no-backport Do not backport this PR to any branch .Team/QueryingComponents labels May 8, 2024
@romeovs romeovs self-assigned this May 8, 2024
@metabase-bot metabase-bot bot added the visual Run Percy visual testing label May 8, 2024
Copy link

github-actions bot commented May 8, 2024

Codenotify: Notifying subscribers in CODENOTIFY files for diff e23e654...479dba7.

Notify File(s)
@alxnddr frontend/src/metabase/visualizations/components/ClickActions/ClickActionControl.module.css
frontend/src/metabase/visualizations/components/ClickActions/ClickActionControl.styled.tsx
frontend/src/metabase/visualizations/components/ClickActions/ClickActionControl.tsx

Copy link

replay-io bot commented May 8, 2024

Status Complete ↗︎
Commit 479dba7
Results
⚠️ 6 Flaky
2502 Passed

@romeovs romeovs force-pushed the 42375-design-update-for-extract-examples branch from 2d53129 to 1f04efc Compare May 8, 2024 15:15
@romeovs romeovs requested a review from a team May 8, 2024 15:17
width: 100%;
}

.label {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is one of the cases I discussed in the FE guild.

I need the button content to render as flex in this one usecase, do I need to override all Buttons everywhere on the site for that?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's a similar issue than in that thread, but not the same exact component.

ClickActionControl is using some deprecated components and we're adding new designs and features to it.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But you're overrides styles for a button in metabase/ui, which is new

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

True, I meant more that this seems like a very one of usecase for the button.

I'm happy to make it a custom button, so there are no overrides, but I feel like that's not the way to go either.

The only reason I switched to ui/Button was because the legacy button that was used could not be customized properly (without having a large blast radius).

But I understand the comment to be about making sure we streamline the design process into forcing a more principled approach.

I'm not sure what the next steps here should be: push back to the design team? Use a fully custom component instead of using overrides?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you ask @kdoh in ui proj channel?

Copy link
Contributor

@ranquild ranquild left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unclear style override

Copy link
Contributor

@ranquild ranquild left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't want to block this but something is clearly going wrong here

@romeovs romeovs enabled auto-merge (squash) May 15, 2024 16:08
@romeovs romeovs merged commit 3506941 into master May 15, 2024
111 of 112 checks passed
@romeovs romeovs deleted the 42375-design-update-for-extract-examples branch May 15, 2024 17:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
no-backport Do not backport this PR to any branch .Team/QueryingComponents visual Run Percy visual testing
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Design update for Extract examples
2 participants