serviceworker_internals.html revision 0529e5d033099cbfc42635f6f6183833b09dff6e
1<!DOCTYPE html>
2<html i18n-values="dir:textdirection;">
3<head>
4  <meta charset="utf-8">
5  <title>ServiceWorker registrations</title>
6  <link rel="stylesheet" href="chrome://resources/css/tabs.css">
7  <link rel="stylesheet" href="chrome://resources/css/widgets.css">
8  <link rel="stylesheet" href="serviceworker_internals.css">
9</head>
10<body i18n-values=".style.fontFamily:fontfamily;.style.fontSize:fontsize">
11    <!-- templates -->
12    <div style="display:none">
13        <div id="serviceworker-version-template" class="serviceworker-version">
14            <div class="serviceworker-status">
15                <span>Installation Status:</span>
16                <span jscontent="$this.status"></span>
17            </div>
18            <div class="serviceworker-running-status">
19                <span>Running Status:</span>
20                <span jscontent="$this.running_status"></span>
21            </div>
22            <div class="serviceworker-vid">
23                <span>Version ID:</span>
24                <span jscontent="$this.version_id"></span>
25            </div>
26            <div class="serviceworker-pid">
27                <span>Renderer process ID:</span>
28                <span jscontent="$this.process_id"></span>
29            </div>
30            <div class="serviceworker-tid">
31                <span>Renderer thread ID:</span>
32                <span jscontent="$this.thread_id"></span>
33            </div>
34            <div>
35                <div>Log:</div>
36                <textarea class="serviceworker-log"
37                  jsvalues=".partition_id:$partition_id;.version_id:$this.version_id"
38                  rows="10" cols="120" readonly jscontent="$this.log"></textarea>
39            </div>
40        </div>
41        <div id="serviceworker-list-template"
42             jsvalues="$partition_id:$this.partition_id;$partition_path:$this.partition_path;.partition_path:$this.partition_path">
43            <div class="serviceworker-summary">
44                <span>Instances in: </span>
45                <span jscontent="$this.partition_path"></span>
46                <span jscontent="'(' + $this.registrations.length + ')'"></span>
47            </div>
48            <div class="serviceworker-item" jsselect="$this.registrations">
49                <div class="serviceworker-scope">
50                    <span>Scope:</span>
51                    <span jscontent="scope"></span>
52                </div>
53                <div class="serviceworker-script_url">
54                    <span>Script:</span>
55                    <span jscontent="script_url"></span>
56                </div>
57                <div jsselect="$this.active">
58                    Active worker:
59                    <div transclude="serviceworker-version-template"></div>
60                </div>
61                <div jsselect="$this.pending">
62                    Pending worker:
63                    <div transclude="serviceworker-version-template"></div>
64                </div>
65                <div class="controls">
66                    <button class="stop" jsdisplay="$this.active.running_status == 'RUNNING'"
67                       jsvalues=".scope:scope;.partition_path:$partition_path">Stop</button>
68                    <button href="#" class="start" jsdisplay="$this.active.running_status != 'RUNNING'"
69                       jsvalues=".scope:scope;.partition_path:$partition_path">Start</button>
70                    <button href="#" class="unregister"
71                       jsvalues=".scope:scope;.partition_path:$partition_path">Unregister</button>
72                    <button href="#" class="sync" jsdisplay="$this.active.running_status == 'RUNNING'"
73                       jsvalues=".scope:scope;.partition_path:$partition_path">Sync</button>
74                    <span class="operation-status" style="display: none">Running...</span>
75                </div>
76            </div>
77        </div>
78    </div>
79    <h1>ServiceWorker registrations</h1>
80    <div class="content">
81        <div id="serviceworker-list"></div>
82    </div>
83    <script src="chrome://resources/js/util.js"></script>
84    <script src="chrome://resources/js/cr.js"></script>
85    <script src="serviceworker_internals.js"></script>
86    <script src="chrome://resources/js/load_time_data.js"></script>
87    <script src="chrome://resources/js/jstemplate_compiled.js"></script>
88    <script src="strings.js"></script>
89    <script src="chrome://resources/js/i18n_template2.js"></script>
90</body>
91</html>
92