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

docs(material-experimental): fix scss examples #21740

Merged
merged 1 commit into from
Jan 30, 2021
Merged

docs(material-experimental): fix scss examples #21740

merged 1 commit into from
Jan 30, 2021

Conversation

macjohnny
Copy link
Contributor

@macjohnny macjohnny commented Jan 29, 2021

Fixes the error

Error: ./src/styles.scss
Module build failed (from ./node_modules/mini-css-extract-plugin/dist/loader.js):
ModuleBuildError: Module build failed (from ./node_modules/sass-loader/dist/cjs.js):
SassError: Missing argument $config-or-theme.
   ┌──> src\styles.scss
14 │ @include mat-mdc-select-typography();
   │ ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ invocation
   ╵
   ┌──> node_modules\@angular\material-experimental\mdc-select\_select-theme.scss
82 │ @mixin mat-mdc-select-typography($config-or-theme) {
   │        ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ declaration
   ╵
  src\styles.scss 14:1  mat-mdc-select-typography()

Note: the same problem also occurs in

src\material-experimental\mdc-autocomplete  (1 usage found)
            README.md  (1 usage found)
                73 @include mat-mdc-autocomplete-typography();
        src\material-experimental\mdc-checkbox  (1 usage found)
            README.md  (1 usage found)
                69 @include mat-mdc-checkbox-typography();
        src\material-experimental\mdc-menu  (1 usage found)
            README.md  (1 usage found)
                73 @include mat-mdc-menu-typography();
        src\material-experimental\mdc-paginator  (1 usage found)
            README.md  (1 usage found)
                69 @include mat-mdc-paginator-typography();
        src\material-experimental\mdc-progress-bar  (1 usage found)
            README.md  (1 usage found)
                70 @include mat-mdc-progress-bar-typography();
        src\material-experimental\mdc-progress-spinner  (1 usage found)
            README.md  (1 usage found)
                70 @include mat-mdc-progress-spinner-typography();
        src\material-experimental\mdc-select  (1 usage found)
            README.md  (1 usage found)
                77 @include mat-mdc-select-typography();
        src\material-experimental\mdc-slide-toggle  (1 usage found)
            README.md  (1 usage found)
                69 @include mat-mdc-slide-toggle-typography();
        src\material-experimental\mdc-tabs  (1 usage found)
            README.md  (1 usage found)
                73 @include mat-mdc-tabs-typography();

@google-cla google-cla bot added the cla: yes PR author has agreed to Google's Contributor License Agreement label Jan 29, 2021
@macjohnny
Copy link
Contributor Author

alternatively, the default parameter could be set to null, similar to

@mixin angular-material-mdc-typography($config-or-theme: null) {
$config: if(mat-private-is-theme-object($config-or-theme),
mat-get-typography-config($config-or-theme), $config-or-theme);
// If no actual color configuration has been specified, create a default one.
@if $config == null {
$config: mat-typography-config();
}

Copy link
Member

@crisbeto crisbeto left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@crisbeto crisbeto added docs This issue is related to documentation action: merge The PR is ready for merge by the caretaker merge safe target: patch This PR is targeted for the next patch release labels Jan 29, 2021
@macjohnny
Copy link
Contributor Author

macjohnny commented Jan 29, 2021

@crisbeto should I open a separate PR that fixes all other docs, too, or should I update this PR?

@crisbeto
Copy link
Member

It's your call, docs PRs don't need to run through our presubmit process so it doesn't really matter if it's separate PRs or one large PR.

@macjohnny
Copy link
Contributor Author

@crisbeto ok so I will add the additional doc fixes to this PR

@macjohnny macjohnny changed the title docs(material-experimental/mdc-select): fix scss example docs(material-experimental): fix scss examples Jan 29, 2021
@wagnermaciel wagnermaciel merged commit ccf2b60 into angular:master Jan 30, 2021
wagnermaciel pushed a commit that referenced this pull request Jan 30, 2021
wagnermaciel pushed a commit to wagnermaciel/components that referenced this pull request Feb 8, 2021
wagnermaciel pushed a commit to wagnermaciel/components that referenced this pull request Feb 8, 2021
@angular-automatic-lock-bot
Copy link

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.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Mar 2, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
action: merge The PR is ready for merge by the caretaker cla: yes PR author has agreed to Google's Contributor License Agreement docs This issue is related to documentation target: patch This PR is targeted for the next patch release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants