-
Notifications
You must be signed in to change notification settings - Fork 6.8k
Open
Labels
P3An issue that is relevant to core functions, but does not impede progress. Important, but not urgentAn issue that is relevant to core functions, but does not impede progress. Important, but not urgentarea: themingdocsThis issue is related to documentationThis issue is related to documentation
Description
Is this a regression?
- Yes, this behavior used to work in the previous version
The previous version in which this bug was not present was
No response
Description
Documentation about define-theme seems to be outdated.
@use '@angular/material' as mat;
html {
@include mat.theme((
color: mat.$violet-palette,
typography: Roboto,
density: -2,
));
}
Reproduction
You can check at:
https://material.angular.io/guide/theming#density
Expected Behavior
The corret code should be:
$theme: mat.define-theme(
(
color: (
primary: mat.$azure-palette,
tertiary: mat.$violet-palette,
theme-type: light,
),
density: (
scale: -2,
),
)
);
Actual Behavior
This code results in the following error:
$config.density should be a density configuration object.
I believe this error also occours with typography config.
Environment
- Angular: 19
- CDK/Material: 19
Metadata
Metadata
Assignees
Labels
P3An issue that is relevant to core functions, but does not impede progress. Important, but not urgentAn issue that is relevant to core functions, but does not impede progress. Important, but not urgentarea: themingdocsThis issue is related to documentationThis issue is related to documentation