Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(382)

Side by Side Diff: runtime/bin/vmservice/observatory/lib/src/elements/eval_box.html

Issue 532063002: Teach the Observatory about Contexts. Factor out object graph information from the instance view. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 <link rel="import" href="../../../../packages/polymer/polymer.html"> 1 <link rel="import" href="../../../../packages/polymer/polymer.html">
2 <link rel="import" href="instance_ref.html"> 2 <link rel="import" href="instance_ref.html">
3 <link rel="import" href="error_ref.html"> 3 <link rel="import" href="error_ref.html">
4 <link rel="import" href="observatory_element.html"> 4 <link rel="import" href="observatory_element.html">
5 5
6 <polymer-element name="eval-box" extends="observatory-element"> 6 <polymer-element name="eval-box" extends="observatory-element">
7 <template> 7 <template>
8 <style> 8 <style>
9 .textbox { 9 .textbox {
10 width: 80ex; 10 flex-grow: 1;
11 font: 400 16px 'Montserrat', sans-serif; 11 font: 400 16px 'Montserrat', sans-serif;
12 } 12 }
13 .bigtextbox { 13 .bigtextbox {
14 font: 400 16px 'Montserrat', sans-serif; 14 font: 400 16px 'Montserrat', sans-serif;
15 } 15 }
16 .button { 16 .button {
17 font: 400 16px 'Montserrat', sans-serif; 17 font: 400 16px 'Montserrat', sans-serif;
18 } 18 }
19 .radios { 19 .radios {
20 display: inline; 20 display: inline;
21 padding-right: 30px;
21 } 22 }
22 .radios label{ 23 .radios label{
23 padding-left: 15px; 24 padding-left: 10px;
24 } 25 }
25 .historyExpr, .historyValue { 26 .historyExpr, .historyValue {
26 vertical-align: text-top; 27 vertical-align: text-top;
27 font: 400 14px 'Montserrat', sans-serif; 28 font: 400 14px 'Montserrat', sans-serif;
28 } 29 }
29 .historyExpr a { 30 .historyExpr a {
30 display: block; 31 display: block;
31 color: black; 32 color: black;
32 text-decoration: none; 33 text-decoration: none;
33 padding: 6px 6px; 34 padding: 6px 6px;
34 cursor: pointer; 35 cursor: pointer;
35 white-space: pre-line; 36 white-space: pre-line;
36 } 37 }
37 .historyExpr a:hover { 38 .historyExpr a:hover {
38 background-color: #fff3e3; 39 background-color: #fff3e3;
39 } 40 }
40 .historyValue { 41 .historyValue {
41 display: block; 42 display: block;
42 padding: 6px 6px; 43 padding: 6px 6px;
43 } 44 }
44 </style> 45 </style>
45 <form> 46 <form style="display:flex; flex-direction:row; align-items:flex-end">
46 <template if="{{ lineMode == '1-line' }}"> 47 <template if="{{ lineMode == '1-line' }}">
47 <input class="textbox" type="text" value="{{ text }}"> 48 <input class="textbox" type="text" value="{{ text }}">
48 </template> 49 </template>
49 <template if="{{ lineMode == 'N-line' }}"> 50 <template if="{{ lineMode == 'N-line' }}">
50 <textarea class="bigtextbox" rows="5" cols="80" 51 <textarea class="bigtextbox" rows="5" cols="80"
51 value="{{ text }}"></textarea> 52 value="{{ text }}"></textarea>
52 </template> 53 </template>
53 54
54 <input class="button" type="submit" value="Evaluate" on-click="{{ eval }}" > 55 <input class="button" type="submit" value="Evaluate" on-click="{{ eval }}" >
55 <div class="radios" on-change="{{ updateLineMode }}"> 56 <div class="radios" on-change="{{ updateLineMode }}">
56 <label for="1-line">1-line 57 <label for="1-line">
57 <input type="radio" name="lineMode" value="1-line" checked> 58 <input type="radio" name="lineMode" value="1-line" checked>
59 1-line
58 </label> 60 </label>
59 <label for="N-line">N-line 61 <label for="N-line">
60 <input type="radio" name="lineMode" value="N-line"> 62 <input type="radio" name="lineMode" value="N-line">
63 N-line
61 </label> 64 </label>
62 </div> 65 </div>
63 </form> 66 </form>
64 67
65 <br> 68 <br>
66 <template if="{{ results.isNotEmpty }}"> 69 <template if="{{ results.isNotEmpty }}">
67 <table> 70 <table>
68 <tr template repeat="{{ result in results }}"> 71 <tr template repeat="{{ result in results }}">
69 <td class="historyExpr"> 72 <td class="historyExpr">
70 <a class="expr" on-click="{{ selectExpr }}" 73 <a class="expr" on-click="{{ selectExpr }}"
71 expr="{{ result['expr'] }}">{{ result['expr'] }}</a> 74 expr="{{ result['expr'] }}">{{ result['expr'] }}</a>
72 </td> 75 </td>
73 <td class="historyValue"> 76 <td class="historyValue">
74 <template if="{{ result['value'] == null }}"> 77 <template if="{{ result['value'] == null }}">
75 <div style="color:#aaa;cursor:wait;">&lt;pending&gt;</div> 78 <div style="color:#aaa;cursor:wait;">&lt;pending&gt;</div>
76 </template> 79 </template>
77 <template if="{{ result['value'] != null }}"> 80 <template if="{{ result['value'] != null }}">
78 <any-service-ref ref="{{ result['value'] }}"></any-service-ref> 81 <any-service-ref ref="{{ result['value'] }}"></any-service-ref>
79 </template> 82 </template>
80 </td> 83 </td>
81 </tr> 84 </tr>
82 </table> 85 </table>
83 </template> 86 </template>
84 </template> 87 </template>
85 </polymer-element> 88 </polymer-element>
86 89
87 <script type="application/dart" src="eval_box.dart"></script> 90 <script type="application/dart" src="eval_box.dart"></script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698