Skip to content

Conversation

@tibi2303
Copy link
Collaborator

No description provided.

@github-actions
Copy link

github-actions bot commented Oct 30, 2025

🚀 Deployed on https://preview-702--oelibrary.netlify.app

@github-actions github-actions bot temporarily deployed to pull request October 30, 2025 13:17 Inactive
Copy link
Collaborator

@donquixote donquixote left a comment

Choose a reason for hiding this comment

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

I am submitting the review now so it is not lost.
@tibi2303 already told me he is working on some changes.

</div>
</div>
{% endif %}

Copy link
Collaborator

Choose a reason for hiding this comment

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

Does this removal have any impact on websites?
-> I think not, there is no pattern for header.

However, I assume that we will do a similar change in oe_whitelabel.

It seems the goal is to remove stuff from the <header> element that would otherwise conflict with the CSS.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

no, the pattern is not used.. i just make it somehow closer to what we have now on oesa

<div
aria-labelledby="custom-trigger-mm-1"
class="bcl-mega-menu__submenu __level-2"
hidden="true"
Copy link
Collaborator

Choose a reason for hiding this comment

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

This looks wrong. The hidden attribute should not have a value, at least not in its default usage.
https://developer.mozilla.org/en-US/docs/Web/HTML/Reference/Global_attributes/hidden
(see below, I will also comment in the respective template)

Copy link
Collaborator Author

@tibi2303 tibi2303 Nov 3, 2025

Choose a reason for hiding this comment

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

fixed it by extending the drupal attributes, have a look now.. multiple test snapshots are updated because of this

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

in test snapshot are like this: hidden="" but in html of storybook is just hidden

{% set submenu_attributes = create_attribute()
.setAttribute('id', _panel_id)
.setAttribute('hidden', '')
.setAttribute('hidden', 'true')
Copy link
Collaborator

Choose a reason for hiding this comment

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

The effect of this seems wrong, I see hidden="true" in the snapshots.

I think .setAttribute() is different tech in Drupal vs BCL twig, and I am not sure what is the correct way to set a value-less attribute. Maybe '' works in Drupal but not here? That would be bad.

return Promise.resolve(resolved);
};`,
);

Copy link
Collaborator

Choose a reason for hiding this comment

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

This looks magical.
Can we add a comment explaining what we are doing here?
If you are not sure what to write, start by explaining it to me (here or in chat).

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

i added the comments to be more clear

@github-actions github-actions bot temporarily deployed to pull request November 3, 2025 21:30 Inactive
@github-actions github-actions bot temporarily deployed to pull request November 3, 2025 22:27 Inactive
@github-actions github-actions bot temporarily deployed to pull request November 3, 2025 22:49 Inactive
@github-actions github-actions bot temporarily deployed to pull request November 17, 2025 13:18 Inactive
@github-actions github-actions bot temporarily deployed to pull request November 17, 2025 19:49 Inactive
@github-actions github-actions bot temporarily deployed to pull request November 18, 2025 10:08 Inactive
@github-actions github-actions bot temporarily deployed to pull request November 18, 2025 10:31 Inactive
@github-actions github-actions bot temporarily deployed to pull request November 18, 2025 11:53 Inactive
@github-actions github-actions bot temporarily deployed to pull request November 18, 2025 12:10 Inactive
@github-actions github-actions bot temporarily deployed to pull request November 18, 2025 12:46 Inactive
@github-actions github-actions bot temporarily deployed to pull request November 18, 2025 17:10 Inactive
margin: 0;
padding-inline-start: 0;
// Add a scrollbar in desktop viewport.
.see-all-button {
Copy link
Collaborator

Choose a reason for hiding this comment

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

I don't agree with this selector hierarchy ul.bcl-mega-menu__items .see-all-button.
Yes, the .see-all-button happens to be inside of a .bcl-mega-menu__items, but that is actually the item list of the parent level. Too far removed.

More logical would be .bcl-mega-menu__submenu > .__body > .__see_all > .see-all-button, or .bcl-mega-menu__submenu > .__body > .__see_all > a or just .bcl-mega-menu__submenu .see-all-button.

Or there could be a dedicated namespaced class instead of .__see-all, so we could do .bcl-mega-menu__submenu-see-all > a.

}
@include media-breakpoint-up(lg) {
> .__body {
background: $primary-bg-subtle;
Copy link
Collaborator

Choose a reason for hiding this comment

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

This is not needed, the parent already has this background.

icon_path: _icon_path,
level: _level,
} only %}
<div class="__body">
Copy link
Collaborator

Choose a reason for hiding this comment

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

Is this __body wrapper actually necessary?
It seems that it would be simpler without.

.see-all-button {
@include mm-item-padding();
// Use flex for icon spacing.
display: flex;
Copy link
Collaborator

Choose a reason for hiding this comment

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

Note:
This used to have justify-content: space-between, which pushed the icon to the right.
By dropping that rule, we align closer with Figma.
-> good :)

@github-actions github-actions bot temporarily deployed to pull request November 18, 2025 22:14 Inactive
Copy link
Collaborator

@donquixote donquixote left a comment

Choose a reason for hiding this comment

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

@tibi2303 I left some comments but also pushed some commits.
Let me know if you agree with these.

}
}
}
}
Copy link
Collaborator

Choose a reason for hiding this comment

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

I can see why we want to do this: We want to hide links in the parent menu, when a submenu is revealed.
But I do have questions:

  • Is this for display, or for focus trapping, or to control the size of the scrollable area?
    (I think the answer is to control height of scrollable area)
  • Did we not need it before, or did we just forget to add it?

But, I guess it is ok.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

there was a bug where submenu level 2 was bigger than first menu, we would have a white page scroll, so that's why was it added

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.

3 participants