Skip to content

Fixing disabled styling of search submit button.#26592

Open
linuspahl wants to merge 6 commits into
masterfrom
fix-disabled-search-submit-button
Open

Fixing disabled styling of search submit button.#26592
linuspahl wants to merge 6 commits into
masterfrom
fix-disabled-search-submit-button

Conversation

@linuspahl

@linuspahl linuspahl commented Jul 6, 2026

Copy link
Copy Markdown
Contributor

Description

The disabled styling for the search submit button is currently missing.

image

The reason:

The styling has been applied in the SearchButton by setting the disabled class, instead of the disabled prop for the button., We did this because we still want to trigger the onClick event, when the button is disabled to show a dialog which explains why the button is disable. The onClick event is usually not being triggered when a button is disabled.

The problem is that the button disabled styling is no longer applied via the CSS class in the Button component. I assume since we migrate from react-bootstrap to Mantine.

This PR implements a cleaner solution to achieve the desired behavior. We are extending the Button component with a prop that allows to trigger the onClick event when the button is disabled.

image

/prd Graylog2/graylog-plugin-enterprise#14797,Graylog2/e2e-tests#1682
/nocl - fixes a small visual regression

@linuspahl linuspahl added the e2e-tests Run PR build with e2e tests. label Jul 6, 2026
@maxiadlovskii

Copy link
Copy Markdown
Contributor

@linuspahl, we have disabled styles while just typing the query. Is that desirable behaviour?

@linuspahl

Copy link
Copy Markdown
Contributor Author

Yes, because you can't submit while the query validation is happening.

@maxiadlovskii

Copy link
Copy Markdown
Contributor

@linuspahl Ok. My main concern was that the button is blinking while you are typing

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

e2e-tests Run PR build with e2e tests.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants