diff options
Diffstat (limited to 'chromium/chrome/browser/resources/tab_strip/alert_indicator.js')
-rw-r--r-- | chromium/chrome/browser/resources/tab_strip/alert_indicator.js | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/chromium/chrome/browser/resources/tab_strip/alert_indicator.js b/chromium/chrome/browser/resources/tab_strip/alert_indicator.js new file mode 100644 index 00000000000..2d41eab42f6 --- /dev/null +++ b/chromium/chrome/browser/resources/tab_strip/alert_indicator.js @@ -0,0 +1,19 @@ +// Copyright 2019 The Chromium Authors. All rights reserved. +// Use of this source code is governed by a BSD-style license that can be +// found in the LICENSE file. + +import {CustomElement} from './custom_element.js'; + +export class AlertIndicatorElement extends CustomElement { + static get template() { + return `{__html_template__}`; + } + + /** @override */ + remove() { + this.toggleAttribute('fade-out', true); + this.addEventListener('animationend', () => super.remove(), {once: true}); + } +} + +customElements.define('tabstrip-alert-indicator', AlertIndicatorElement); |