UNPKG

chrome-devtools-frontend

Version:
29 lines (25 loc) 926 B
// Copyright 2018 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 * as Common from '../common/common.js'; import {VBox} from './Widget.js'; export class TargetCrashedScreen extends VBox { /** * @param {function():*} hideCallback */ constructor(hideCallback) { super(true); this.registerRequiredCSS('ui/targetCrashedScreen.css', {enableLegacyPatching: false}); this.contentElement.createChild('div', 'message').textContent = Common.UIString.UIString('DevTools was disconnected from the page.'); this.contentElement.createChild('div', 'message').textContent = Common.UIString.UIString('Once page is reloaded, DevTools will automatically reconnect.'); this._hideCallback = hideCallback; } /** * @override */ willHide() { this._hideCallback.call(null); } }