-
Notifications
You must be signed in to change notification settings - Fork 6.8k
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(ng-add): do not incorrectly insert custom-theme into CSS files #12711
fix(ng-add): do not incorrectly insert custom-theme into CSS files #12711
Conversation
* Currently the schematics add the custom-theme SCSS code to any project style file (`styles.EXT`). This is incorrect because the SCSS needs to be placed inside of a SCSS file. Instead of throwing an error we just create a new SCSS file with the theme and add it to the workspace config. * Aligns the global font-family statement with the current Angular Material typography font-family. * Adds missing tests for the global app styles. * Removes an accidentally committed `console.log()`.
5770507
to
43f5b19
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
@@ -16,6 +17,14 @@ describe('material-install-schematic', () => { | |||
runner = new SchematicTestRunner('schematics', collectionPath); | |||
}); | |||
|
|||
/** Expects the given file to be in the styles of the specified workspace project. */ | |||
function expectProjectStyleFile(project: WorkspaceProject, filePath: string) { | |||
expect(project.architect!['build']).toBeTruthy(); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could reduce repetition:
const architect = project.architect!;
expect(architect['build']).toBeTruthy();
...
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
styles.EXT
). This is incorrect because the SCSS needs to be placed inside of a SCSS file. Instead of throwing an error we just create a new SCSS file with the theme and add it to the workspace config.console.log()
.