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

fix(ui5-menu-item): adjust cursor style #10353

Merged
merged 3 commits into from
Dec 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions packages/main/src/Menu.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,9 @@
<div
class="ui5-menu-dialog-title"
>
<div>
<h1>
Copy link
Contributor

Choose a reason for hiding this comment

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

The ui5-shellbar is AFAIR the only UI5 component that can render <h1> (apart from the title which can render any H tag).

Why did you change this here? Won't this create a wrong hierarchy, considering the nesting of menus?

{{headerText}}
</div>
</h1>
</div>
<ui5-button
icon="decline"
Expand Down
1 change: 1 addition & 0 deletions packages/main/src/MenuItem.ts
Original file line number Diff line number Diff line change
Expand Up @@ -255,6 +255,7 @@ class MenuItem extends ListItem implements IMenuItem {
}

onBeforeRendering() {
super.onBeforeRendering();
const siblingsWithIcon = this._menuItems.some(menuItem => !!menuItem.icon);

this._menuItems.forEach(item => {
Expand Down
4 changes: 3 additions & 1 deletion packages/main/src/themes/Menu.css
Original file line number Diff line number Diff line change
Expand Up @@ -31,14 +31,16 @@
justify-content: flex-start;
width: calc(100% - 6.5rem);
padding-right: 1rem;
font-family: var(--sapFontHeaderFamily);
}

.ui5-menu-dialog-title > div {
.ui5-menu-dialog-title > h1 {
display: inline-block;
max-width: 100%;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
font-size: var(--sapFontHeader5Size);
}

.ui5-menu-back-button {
Expand Down
Loading