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

Style errors more conspicuously and consistently #82

Open
waldyrious opened this issue Jul 13, 2024 · 0 comments
Open

Style errors more conspicuously and consistently #82

waldyrious opened this issue Jul 13, 2024 · 0 comments

Comments

@waldyrious
Copy link

Currently some errors are explicitly marked as errors:

Examples of messages explicitly marked as errors

$error = _('OAuth token was lost, please log in again.');

$error = 'Failed to create a changeset: '.$response->getBody();

$error = _('Could not aquire changeset id for a new changeset.');

...and these are styled in red:

Level0/www/page.php

Lines 13 to 15 in 390c810

<?php if( $error ): ?>
<p style="color: red;"><?=htmlspecialchars($error) ?></p>
<?php endif ?>

However, other error messages are merely assigned to $messages:

Examples of error messages that are not marked as such

$messages[] = _('Failed to open XML stream');

$messages[] = sprintf(_('Download is incomplete, maximum of %d objects has been reached'), MAX_REQUEST_OBJECTS);

...so they appear as regular text in the page rendering, which can mask the fact that there was a problem.

These error messages should also be assigned to $error, or somehow made to be shown in a similar style to make sure the problem is noticed.

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

No branches or pull requests

1 participant