make author merge description visible
Implement Author Description on Merge Page
Closes #9429
Description
This PR introduces the display of author descriptions on the merge page. The author descriptions will provide more context about each author during the merge process, improving the usability and user experience and helping librarians disambiguate authors, and avoid accidentally merging authors that shouldn't be merged.
Changes
-
Conditional Display of Author Description:
- Added logic to conditionally display the author description if it exists. If no description is available, a placeholder message "No description." will be shown.
- Used the
TruncateStringmacro to limit the displayed author description to 250 characters for better readability and to ensure a consistent layout.
-
Updated Template:
- Modified the HTML template to include the new logic for displaying author descriptions.
- Maintained the existing template structure and ensured compatibility with the current styling and layout.
How to Test
-
Run the Application: Ensure the application is running locally.
-
Navigate to the Merge Page: Go to the merge page where authors are listed for merging.
-
Verify Author Descriptions:
- Check that authors with descriptions have their descriptions displayed, truncated to 250 characters.
- Verify that authors without descriptions show the placeholder text "No description."
-
Check for Errors: Ensure there are no errors or layout issues introduced by these changes.
Related Issues
- Issue #9429
Notes
- This implementation uses the
TruncateStringmacro to ensure descriptions are concise and fit within the layout. - The change has been tested across different browsers and screen sizes to ensure compatibility.
Checklist
- [x] Code follows the project's style guidelines.
- [x] Code is self-documented where necessary.
- [x] Tests have been added/updated to cover the changes.
- [x] All tests pass locally (docker compose run --rm home make test).
Additional Comments
Please review the changes and provide feedback. If there are any questions or further modifications required, let me know. Thank you!