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

bug(Button): container shape override not working + update docs #30318

Closed
richardsengers opened this issue Jan 13, 2025 · 1 comment
Closed
Labels
needs triage This issue needs to be triaged by the team

Comments

@richardsengers
Copy link

richardsengers commented Jan 13, 2025

Description

When setting a container shape like medium or small, the layout off the button is a square

Image

From m3 site:
For example, by default, buttons are mapped to the shape style “full.” If your product requires a smaller amount of roundedness, it can be remapped to the small or medium style in shape scale.

I think the docs should also be updated so we know which button type has which setting (is the raised button the protected-* setting?)
And offcourse which settings we can use. I now have to search https://m3.material.io/ to find out what shape settings I can use

This is the only thing the material docs say about a shape, but it apears we can use none, small, medium, etc as a value

Image

Reproduction

  1. https://stackblitz.com/edit/dqdmtecp?file=src%2Fstyles.scss
  2. change the the filled-container-shape to one of the available shape settings
    https://m3.material.io/styles/shape/overview

Expected Behavior

Make button rounded confirm the https://m3.material.io/styles/shape/overview

Actual Behavior

square buttons are shown

Environment

Angular CLI: 19.0.5
Node: 22.3.0
Package Manager: yarn 1.22.17
OS: win32 x64

Angular: 19.0.4
... animations, common, compiler, compiler-cli, core, forms
... language-service, platform-browser, platform-browser-dynamic
... platform-server, router, service-worker

Package Version

@angular-devkit/architect 0.1900.5 (cli-only)
@angular-devkit/build-angular 19.0.5
@angular-devkit/core 19.0.5
@angular-devkit/schematics 19.0.5
@angular/cdk 19.0.3
@angular/cli 19.0.5
@angular/material 19.0.3
@angular/material-date-fns-adapter 19.0.3
@schematics/angular 19.0.5
rxjs 7.8.1
typescript 5.6.3
zone.js 0.15.0

@richardsengers richardsengers added the needs triage This issue needs to be triaged by the team label Jan 13, 2025
@crisbeto
Copy link
Member

The shape needs to be a pixel value.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs triage This issue needs to be triaged by the team
Projects
None yet
Development

No branches or pull requests

2 participants