components icon indicating copy to clipboard operation
components copied to clipboard

Uncaught Error: Template parse errors: Can't bind to 'color' since it isn't a known property of 'mat-progress-bar'

Open cv-gh opened this issue 9 years ago • 6 comments

Bug, feature request, or proposal:

I have updated Angular Material version to latest Beta 11. After upgrading I did run the angular-material-prefix-updater.

I keep getting errors for properties of various material component. for example Uncaught Error: Template parse errors: Can't bind to 'color' since it isn't a known property of 'mat-progress-bar'.

  1. If 'mat-progress-bar' is an Angular component and it has 'color' input, then verify that it is part of this module.
  2. If 'mat-progress-bar' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message.
  3. To allow any property add 'NO_ERRORS_SCHEMA' to the '@NgModule.schemas' of this component. (" class="example-margin" *ngIf="isLoading" [ERROR ->][color]="color" [mode]="mode" [value]="value" "): ng:///AppModule/Component.html@4:0 Can't bind to 'mode' since it isn't a known property of 'mat-progress-bar'.

What is the expected behavior?

New version has completely broken the existing working applications. Need guidance or suggestion to recover from this errors and get back the application in working mode.

What is the current behavior?

Keep getting errors for various properties not known for Material Component

What are the steps to reproduce?

Upgrade to Beta 11 and existing md-progress-bar, mdPaginator all stops working with properties not known error messages.

What is the use-case or motivation for changing an existing behavior?

Which versions of Angular, Material, OS, TypeScript, browsers are affected?

@angular/cli: 1.4.3 node: 8.5.0 os: win32 x64 @angular/animations: 4.4.3 @angular/common: 4.4.3 @angular/compiler: 4.4.3 @angular/core: 4.4.3 @angular/forms: 4.4.3 @angular/http: 4.4.3 @angular/platform-browser: 4.4.3 @angular/platform-browser-dynamic: 4.4.3 @angular/platform-server: 4.4.3 @angular/router: 4.4.3 @angular/cdk: 2.0.0-beta.11 @angular/cli: 1.4.3 @angular/compiler-cli: 4.4.3 @angular/language-service: 4.4.3 @angular/material: 2.0.0-beta.11 typescript: 2.3.0

Is there anything else we should know?

You should not break exitsing builds :)

cv-gh avatar Sep 27 '17 12:09 cv-gh

Uncaught Error: Template parse errors: Can't bind to 'length' since it isn't a known property of 'mat-paginator'.

  1. If 'mat-paginator' is an Angular component and it has 'length' input, then verify that it is part of this module.
  2. If 'mat-paginator' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message.
  3. To allow any property add 'NO_ERRORS_SCHEMA' to the '@NgModule.schemas' of this component. (" <mat-paginator #paginator [ERROR ->][length]="this.TotalRows" [pageIndex]="0" [pageSize]="5" (page)="onPaginateChange($event)" [pageSizeO"): ng:///AppModule/Component.html@94:34 Can't bind to 'pageIndex' since it isn't a known property of 'mat-paginator'.

cv-gh avatar Sep 27 '17 12:09 cv-gh

From the errors you are seeing it appears that you do not have the modules for MatPaginator and MatProgressBar imported in your app's module.

Are you able to provide a reproduction of this issue?

josephperrott avatar Sep 27 '17 14:09 josephperrott

You were right, but it was working earlier. I have not added the modules explicitly in the module.ts file. I get this new error now in the application. can you suggest what could be wrong?

ERROR in Error: MdProgressBar is not an NgModule at _getNgModuleMetadata (C:\WebApp\node_modules@angular\compiler-cli\src\ngtools_impl.js:140:15) at _extractLazyRoutesFromStaticModule (C:\WebApp\node_modules@angular\compiler-cli\src\ngtools_impl.js:109:26) at C:\WebApp\node_modules@angular\compiler-cli\src\ngtools_impl.js:129:27 at Array.reduce () at _extractLazyRoutesFromStaticModule (C:\WebApp\node_modules@angular\compiler-cli\src\ngtools_impl.js:128:10) at Object.listLazyRoutesOfModule (C:\WebApp\node_modules@angular\compiler-cli\src\ngtools_impl.js:53:22) at Function.NgTools_InternalApi_NG_2.listLazyRoutes (C:\WebApp\node_modules@angular\compiler-cli\src\ngtools_api.js:91:39) at AotPlugin._getLazyRoutesFromNgtools (C:\WebApp\node_modules@ngtools\webpack\src\plugin.js:207:44) at _donePromise.Promise.resolve.then.then.then.then.then (C:\WebApp\node_modules@ngtools\webpack\src\plugin.js:443:24) at at process._tickCallback (internal/process/next_tick.js:188:7)

cv-gh avatar Sep 28 '17 13:09 cv-gh

@chetanvaja MatProgressBarModule and MatPaginatorModule

An easy way to tell is to look here https://material.angular.io/components/paginator/api

API reference for Angular Material paginator

import {MatPaginatorModule} from '@angular/material';

willshowell avatar Sep 28 '17 13:09 willshowell

We haven't been able to reproduce this issue. Feel free to open a new issue if you are able to provide a reproduction via StackBlitz.

jelbourn avatar Jan 17 '18 00:01 jelbourn

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.