components icon indicating copy to clipboard operation
components copied to clipboard

bug(COMPONENT): The installation does not seem to work out of the box.

Open saffabook opened this issue 2 years ago • 1 comments

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

I have just installed the latest Angular and Angular material. However when I set up the theme I keep getting this error?

Also, it just seems like there are no typography styles. All this use to work on previous version when out of the box.

Here is the custom theme I am using. And the image is the result. Typography seems to work in components, but no where else.

// Custom Theming for Angular Material
// For more information: https://material.angular.io/guide/theming
@use "@angular/material" as material;

@include material.core();

$app-primary: material.define-palette(material.$purple-palette);
$app-accent: material.define-palette(material.$teal-palette, A200);
$app-warn: material.define-palette(material.$red-palette);
// extra Colors
$custom-success: material.define-palette(material.$green-palette);
$custom-danger: material.define-palette(material.$orange-palette);

$custom-theme: material.define-light-theme(
  (
    color: (
      primary: $app-primary,
      accent: $app-accent,
      warn: $app-warn,
    ),
  )
);

$my-theme: material.define-light-theme((
 color: (
    primary: $app-primary,
    accent: $app-accent,
    warn: $app-warn,
 ),
 typography: material.define-typography-config(),
 density: 0,
));


@include material.all-component-themes($my-theme);

image

Reproduction

Steps to reproduce:

  1. Basic install

Expected Behavior

Just a normal start.

Actual Behavior

Themes set up not clear.

Environment

  • Angular: latest just installed
  • CDK/Material: v15 latest
  • Browser(s): Chrome
  • Operating System (e.g. Windows): Windows.

saffabook avatar Nov 24 '22 13:11 saffabook

ok ... this seems to work. @include material.all-component-typographies();

But no where in the documents to be found.

saffabook avatar Nov 24 '22 14:11 saffabook

This issue has been automatically locked due to inactivity. Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.