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-bar): allow overwrite of container-type #10993

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

hinzzx
Copy link
Contributor

@hinzzx hinzzx commented Mar 4, 2025

Previously the ui5-bar web component was strictly said to be a query container as its root element had container-type: size CSS property.
However this makes it ignore its children width requirements and sometimes they might get clipped, which is not always the desired behaviour.

Because of the above explained behaviour from now on we allow the app developers to overwrite that behaviour by setting the container-type: inherit on root level.
We also change the default query container behaviour from

- container-type: size
+ container-type: inline-size

as size observes both, height and width of a container, which is not necessary for our case.

Now the container type of the ui5-bar could be easily overwritten as simple as:

e.g

[ui5-bar] {
	container-type: unset;
}

Closes: #10012

@hinzzx hinzzx requested a review from tsanislavgatev March 4, 2025 07:42
@nnaydenow
Copy link
Contributor

Does this solution keep working the responsive paddings?

@nnaydenow
Copy link
Contributor

nnaydenow commented Mar 7, 2025

Hi @hinzzx,

Could you please check why this component have responsive paddings since they are not part of the component VD specification? If they are redundant all these container queries could be removed from the component.

They seem to be introduced by #7359 but for me the paddings should be controlled by the parent component which in this case is the dialog.

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.

[Dialog]: Dialog width calculation does not take Button Text Width into consideration
2 participants