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

Only set .drawer__item-title margin if followed by .drawer__item-body #487

Merged
merged 1 commit into from
Jan 22, 2024

Conversation

kirsty-hames
Copy link
Contributor

Instead of applying margin-bottom to .drawer__item-title directly, apply margin-top to .drawer__item-body when needed.

Most Drawer plugin items only include a title. It's a minor issue but the addition of margin makes the title display off-center vertically.

Fixes #486

Test PR
In your course, go to PageLevelProgress and inspect .drawer__item-title. No margin should be applied. Same goes for Glossary or LanguagePicker.

Go to Drawer Resources and inspect .drawer__item-title. Margin should be applied to the top of .drawer__item-body, creating space between title and body.

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

@joe-allen-89 joe-allen-89 left a comment

Choose a reason for hiding this comment

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

👍

Copy link
Contributor

@guywillis guywillis left a comment

Choose a reason for hiding this comment

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

👀

@kirsty-hames kirsty-hames merged commit 1354de8 into master Jan 22, 2024
1 check passed
@kirsty-hames kirsty-hames deleted the issue/486 branch January 22, 2024 16:26
Copy link

🎉 This PR is included in version 9.15.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

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

Successfully merging this pull request may close these issues.

Drawer item title margin offsets item alignment
4 participants