Skip to content

Build warning: The same color styles are generated multiple times #37

@MichalK6677

Description

@MichalK6677

Describe the bug

When I use my custom theming then threre is a warning in build:
WARNING: The same color styles are generated multiple times. Read more about how style duplication can be avoided in a dedicated guide. https://github.com/angular/components/blob/master/guides/duplicate-theming-styles.md node_modules\@angular\material\core\theming\_theming.scss 312:7 private-check-duplicate-theme-styles() node_modules\@matheo\datepicker\_theming.scss 360:3 mat-datepicker-theme() src\@shs\scss\theme.scss 10:5 shs-core-theme() src\app\scss\themes\_light.theme.scss 121:5 @use src\app\scss\app.theme.scss 5:1 @use src\styles.scss 5:1 root stylesheet


WARNING: The same color styles are generated multiple times. Read more about how style duplication can be avoided in a dedicated guide. https://github.com/angular/components/blob/master/guides/duplicate-theming-styles.md node_modules\@angular\material\core\theming\_theming.scss 312:7 private-check-duplicate-theme-styles() node_modules\@matheo\datepicker\_theming.scss 360:3 mat-datepicker-theme() src\@shs\scss\theme.scss 10:5 shs-core-theme() src\app\scss\themes\_light.theme.scss 136:9 @use src\app\scss\app.theme.scss 5:1 @use src\styles.scss 5:1 root stylesheet


WARNING: The same color styles are generated multiple times. Read more about how style duplication can be avoided in a dedicated guide. https://github.com/angular/components/blob/master/guides/duplicate-theming-styles.md node_modules\@angular\material\core\theming\_theming.scss 312:7 private-check-duplicate-theme-styles() node_modules\@matheo\datepicker\_theming.scss 360:3 mat-datepicker-theme() src\@shs\scss\theme.scss 10:5 shs-core-theme() src\app\scss\themes\_dark.theme.scss 116:5 @use src\app\scss\app.theme.scss 6:1 @use src\styles.scss 5:1 root stylesheet

Minimal Reproduction

I have more themes in the application and I call "@include datePickerTheming.mat-datepicker-theme($theme)" for every theme the same way like for other components. This datepicker gives me the error during ng serve.

Expected behavior

No build warnings.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions