Skip to content

Commit 4f3cbfe

Browse files
devversionjosephperrott
authored andcommitted
fix(tab-nav-bar): ripples still showing up when globally disabled (#11865)
1 parent 2433439 commit 4f3cbfe

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

src/lib/tabs/tab-nav-bar/tab-nav-bar.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -189,6 +189,9 @@ export class MatTabLink extends _MatTabLinkMixinBase
189189
/** Reference to the RippleRenderer for the tab-link. */
190190
protected _tabLinkRipple: RippleRenderer;
191191

192+
/** Whether the ripples are globally disabled through the RippleGlobalOptions */
193+
private _ripplesGloballyDisabled = false;
194+
192195
/** Whether the link is active. */
193196
@Input()
194197
get active(): boolean { return this._isActive; }
@@ -210,7 +213,8 @@ export class MatTabLink extends _MatTabLinkMixinBase
210213
* @docs-private
211214
*/
212215
get rippleDisabled(): boolean {
213-
return this.disabled || this.disableRipple || this._tabNavBar.disableRipple;
216+
return this.disabled || this.disableRipple || this._tabNavBar.disableRipple ||
217+
this._ripplesGloballyDisabled;
214218
}
215219

216220
constructor(private _tabNavBar: MatTabNav,
@@ -227,6 +231,7 @@ export class MatTabLink extends _MatTabLinkMixinBase
227231
this.tabIndex = parseInt(tabIndex) || 0;
228232

229233
if (globalOptions) {
234+
this._ripplesGloballyDisabled = !!globalOptions.disabled;
230235
// TODO(paul): Once the speedFactor is removed, we no longer need to copy each single option.
231236
this.rippleConfig = {
232237
terminateOnPointerUp: globalOptions.terminateOnPointerUp,

tools/gulp/tasks/screenshots.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ function setFileResult(database: Database, prNumber: string, fileName: string, r
8989

9090
/** Sets the full diff result for the current Pull Request that runs inside of Travis. */
9191
function setPullRequestResult(database: Database, prNumber: string, result: boolean) {
92-
return getPullRequestRef(database, prNumber).child('result').child(pullRequestSha).set(result);
92+
return getPullRequestRef(database, prNumber).child('result').child(pullRequestSha!).set(result);
9393
}
9494

9595
/** Returns the Firebase Reference that contains all data related to the specified PR. */

0 commit comments

Comments
 (0)