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

Add title attribute to widget error data #9

Merged
merged 1 commit into from
Apr 9, 2024
Merged

Add title attribute to widget error data #9

merged 1 commit into from
Apr 9, 2024

Conversation

rokostik
Copy link
Contributor

@rokostik rokostik commented Apr 8, 2024

This PR adds the title attribute to the widget for use in https://github.com/FriendlyCaptcha/friendly-captcha/pull/1149. Wasn't sure about the naming... title seems the most correct one since it's used as a title when the widget is display with an error but on it's own it looks a bit off in WidgetErrorData.

Part of https://github.com/FriendlyCaptcha/friendly-captcha/issues/1148

@rokostik rokostik requested a review from gzuidhof April 8, 2024 13:32
@rokostik rokostik changed the title Add title attribute to widget error Add title attribute to widget error data Apr 8, 2024
Copy link
Contributor

@gzuidhof gzuidhof left a comment

Choose a reason for hiding this comment

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

Hmm. One alternative way would be to add more semantics to the error code, e.g. having it in two parts:

website_error.invalid_sitekey.

This also works, I'm happy either way 👍

@rokostik rokostik merged commit cf594db into main Apr 9, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants