"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "src/dev-app/snack-bar/snack-bar-demo.ts" between
material2-7.3.5.tar.gz and material2-7.3.6.tar.gz

About: material2 offers Material Design components for Angular.

snack-bar-demo.ts  (material2-7.3.5):snack-bar-demo.ts  (material2-7.3.6)
/** /**
* @license * @license
* Copyright Google LLC All Rights Reserved. * Copyright Google LLC All Rights Reserved.
* *
* Use of this source code is governed by an MIT-style license that can be * Use of this source code is governed by an MIT-style license that can be
* found in the LICENSE file at https://angular.io/license * found in the LICENSE file at https://angular.io/license
*/ */
import {Dir} from '@angular/cdk/bidi'; import {Directionality} from '@angular/cdk/bidi';
import {Component, TemplateRef, ViewChild} from '@angular/core'; import {Component, TemplateRef, ViewChild} from '@angular/core';
import { import {
MatSnackBar, MatSnackBar,
MatSnackBarConfig, MatSnackBarConfig,
MatSnackBarHorizontalPosition, MatSnackBarHorizontalPosition,
MatSnackBarVerticalPosition, MatSnackBarVerticalPosition,
} from '@angular/material'; } from '@angular/material';
@Component({ @Component({
moduleId: module.id, moduleId: module.id,
skipping to change at line 35 skipping to change at line 35
@ViewChild('template') template: TemplateRef<any>; @ViewChild('template') template: TemplateRef<any>;
message = 'Snack Bar opened.'; message = 'Snack Bar opened.';
actionButtonLabel = 'Retry'; actionButtonLabel = 'Retry';
action = false; action = false;
setAutoHide = true; setAutoHide = true;
autoHide = 10000; autoHide = 10000;
addExtraClass = false; addExtraClass = false;
horizontalPosition: MatSnackBarHorizontalPosition = 'center'; horizontalPosition: MatSnackBarHorizontalPosition = 'center';
verticalPosition: MatSnackBarVerticalPosition = 'bottom'; verticalPosition: MatSnackBarVerticalPosition = 'bottom';
constructor(public snackBar: MatSnackBar, private dir: Dir) { constructor(public snackBar: MatSnackBar, private dir: Directionality) {}
}
open() { open() {
const config = this._createConfig(); const config = this._createConfig();
this.snackBar.open(this.message, this.action ? this.actionButtonLabel : unde fined, config); this.snackBar.open(this.message, this.action ? this.actionButtonLabel : unde fined, config);
} }
openTemplate() { openTemplate() {
const config = this._createConfig(); const config = this._createConfig();
this.snackBar.openFromTemplate(this.template, config); this.snackBar.openFromTemplate(this.template, config);
} }
 End of changes. 2 change blocks. 
3 lines changed or deleted 2 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)