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

Side by Side Diff: runtime/observatory/lib/src/elements/instance_ref.html

Issue 1314763005: Change how instance/list/map references are displayed when expanded. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: move branches Created 5 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <link rel="import" href="../../../../packages/polymer/polymer.html"> 1 <link rel="import" href="../../../../packages/polymer/polymer.html">
2 <link rel="import" href="curly_block.html"> 2 <link rel="import" href="curly_block.html">
3 <link rel="import" href="observatory_element.html"> 3 <link rel="import" href="observatory_element.html">
4 <link rel="import" href="service_ref.html"> 4 <link rel="import" href="service_ref.html">
5 5
6 <polymer-element name="instance-ref" extends="service-ref"> 6 <polymer-element name="instance-ref" extends="service-ref">
7 <template> 7 <template>
8 <link rel="stylesheet" href="css/shared.css"> 8 <link rel="stylesheet" href="css/shared.css">
9 <style> 9 <style>
10 .errorBox { 10 .indented {
11 background-color: #f5f5f5; 11 margin-left: 1.5em;
12 border: 1px solid #ccc; 12 font: 400 14px 'Montserrat', sans-serif;
13 padding: 10px; 13 line-height: 150%;
14 font-family: consolas, courier, monospace;
15 font-size: 1em;
16 line-height: 1.2em;
17 white-space: pre;
18 } 14 }
19 </style> 15 </style>
20 <span> 16 <span>
21 <template if="{{ ref.isSentinel }}"> 17 <template if="{{ ref.isSentinel }}">
22 <span title="{{ hoverText }}">{{ ref.valueAsString }}</span> 18 <span title="{{ hoverText }}">{{ ref.valueAsString }}</span>
23 </template> 19 </template>
24 20
25 <template if="{{ ref.isBool || ref.isInt || 21 <template if="{{ ref.isBool || ref.isInt ||
26 ref.isDouble || ref.isNull }}"> 22 ref.isDouble || ref.isNull }}">
27 <a on-click="{{ goto }}" _href="{{ url }}">{{ ref.valueAsString }}</a> 23 <a on-click="{{ goto }}" _href="{{ url }}">{{ ref.valueAsString }}</a>
(...skipping 16 matching lines...) Expand all
44 40
45 <template if="{{ ref.isRegExp }}"> 41 <template if="{{ ref.isRegExp }}">
46 <a on-click="{{ goto }}" _href="{{ url }}"> 42 <a on-click="{{ goto }}" _href="{{ url }}">
47 <em>{{ ref.clazz.name }}</em> ({{ ref.pattern.valueAsString }}) 43 <em>{{ ref.clazz.name }}</em> ({{ ref.pattern.valueAsString }})
48 </a> 44 </a>
49 </template> 45 </template>
50 46
51 <template if="{{ ref.isPlainInstance }}"> 47 <template if="{{ ref.isPlainInstance }}">
52 <a on-click="{{ goto }}" _href="{{ url }}"><em>{{ ref.clazz.name }}</em> </a> 48 <a on-click="{{ goto }}" _href="{{ url }}"><em>{{ ref.clazz.name }}</em> </a>
53 <curly-block callback="{{ expander() }}" expandKey="{{ expandKey }}"> 49 <curly-block callback="{{ expander() }}" expandKey="{{ expandKey }}">
54 <div class="memberList"> 50 <div class="indented">
55 <template repeat="{{ field in ref.fields }}"> 51 <template repeat="{{ field in ref.fields }}">
56 <div class="memberItem"> 52 {{ field['decl'].name }}&nbsp;:&nbsp;
57 <div class="memberName"> 53 <any-service-ref ref="{{ field['value'] }}"
58 {{ field['decl'].name }} 54 expandKey="{{ makeExpandKey(field['decl'].name) } }">
59 </div> 55 </any-service-ref><br>
60 <div class="memberValue">
61 <any-service-ref ref="{{ field['value'] }}"
62 expandKey="{{ makeExpandKey(field['decl'].nam e) }}">
63 </any-service-ref>
64 </div>
65 </div>
66 </template> 56 </template>
67 </div> 57 </div>
68 </curly-block> 58 </curly-block>
69 </template> 59 </template>
70 60
71 <template if="{{ ref.isList }}"> 61 <template if="{{ ref.isList }}">
72 <a on-click="{{ goto }}" _href="{{ url }}"><em>{{ ref.clazz.name }}</em> ({{ ref.length }})</a> 62 <a on-click="{{ goto }}" _href="{{ url }}"><em>{{ ref.clazz.name }}</em> ({{ ref.length }})</a>
73 <curly-block callback="{{ expander() }}" expandKey="{{ expandKey }}"> 63 <curly-block callback="{{ expander() }}"
74 <div class="memberList"> 64 expandKey="{{ expandKey }}">
65 <div class="indented">
75 <template repeat="{{ index in ref.elements.asMap().keys }}"> 66 <template repeat="{{ index in ref.elements.asMap().keys }}">
76 <div class="memberItem"> 67 [ {{ index }} ]&nbsp;&nbsp;
77 <div class="memberName">[{{ index }}]</div> 68 <any-service-ref ref="{{ ref.elements[index] }}"
78 <div class="memberValue"> 69 expandKey="{{ makeExpandKey(index.toString()) }}" >
79 <any-service-ref ref="{{ ref.elements[index] }}" 70 </any-service-ref><br>
80 expandKey="{{ makeExpandKey(index.toString()) }}">
81 </any-service-ref>
82 </div>
83 </div>
84 </template> 71 </template>
85 </div> 72 </div>
86 </curly-block> 73 </curly-block>
87 </template> 74 </template>
88 75
89 <template if="{{ ref.isMap }}"> 76 <template if="{{ ref.isMap }}">
90 <a on-click="{{ goto }}" _href="{{ url }}"><em>{{ ref.clazz.name }}</em> ({{ ref.length }})</a> 77 <a on-click="{{ goto }}" _href="{{ url }}"><em>{{ ref.clazz.name }}</em> ({{ ref.length }})</a>
91 <curly-block callback="{{ expander() }}" expandKey="{{ expandKey }}"> 78 <curly-block callback="{{ expander() }}" expandKey="{{ expandKey }}">
92 <div class="memberList"> 79 <div class="indented">
93 <template repeat="{{ association in ref.associations }}"> 80 <template repeat="{{ association in ref.associations }}">
94 <div class="memberItem"> 81 [ <any-service-ref ref="{{ association['key'] }}"
95 <div class="memberName"> 82 expandKey="{{ makeExpandKey('key') }}">
96 [<any-service-ref ref="{{ association['key'] }}" 83 </any-service-ref> ]&nbsp;&nbsp;
97 expandKey="{{ makeExpandKey('key') }}"> 84 <any-service-ref ref="{{ association['value'] }}"
98 </any-service-ref>] 85 expandKey="{{ makeExpandKey('value') }}">
99 </div> 86 </any-service-ref><br>
100 <div class="memberValue">
101 <any-service-ref ref="{{ association['value'] }}"
102 expandKey="{{ makeExpandKey('value') }}">
103 </any-service-ref>
104 </div>
105 </div>
106 </template> 87 </template>
107 </div> 88 </div>
108 </curly-block> 89 </curly-block>
109 </template> 90 </template>
110 91
111 <template if="{{ ref.isTypedData }}"> 92 <template if="{{ ref.isTypedData }}">
112 <a on-click="{{ goto }}" _href="{{ url }}"><em>{{ ref.clazz.name }}</em> ({{ ref.length }})</a> 93 <a on-click="{{ goto }}" _href="{{ url }}"><em>{{ ref.clazz.name }}</em> ({{ ref.length }})</a>
113 <curly-block callback="{{ expander() }}" expandKey="{{ expandKey }}"> 94 <curly-block callback="{{ expander() }}" expandKey="{{ expandKey }}">
114 <div class="memberList"> 95 <div class="indented">
115 <template repeat="{{ index in ref.typedElements.asMap().keys }}"> 96 <template repeat="{{ index in ref.typedElements.asMap().keys }}">
116 <div class="memberItem"> 97 [ {{ index }} ]&nbsp;&nbsp;
117 <div class="memberName">[{{ index }}]</div> 98 {{ ref.typedElements[index].toString() }}<br>
118 <div class="memberValue">{{ ref.typedElements[index].toString() }}</div>
119 </div>
120 </template> 99 </template>
121 </div> 100 </div>
122 </curly-block> 101 </curly-block>
123 </template> 102 </template>
124 103
125 <template if="{{ ref.isMirrorReference }}"> 104 <template if="{{ ref.isMirrorReference }}">
126 <a on-click="{{ goto }}" _href="{{ url }}"><em>{{ ref.clazz.name }}</em> </a> 105 <a on-click="{{ goto }}" _href="{{ url }}"><em>{{ ref.clazz.name }}</em> </a>
127 <curly-block callback="{{ expander() }}" expandKey="{{ expandKey }}"> 106 <curly-block callback="{{ expander() }}" expandKey="{{ expandKey }}">
128 <div class="memberList"> 107 <div class="indented">
129 <div class="memberItem"> 108 &lt;referent&gt;&nbsp;:&nbsp;
130 <div class="memberName">referent</div> 109 <any-service-ref ref="{{ ref.referent }}"
131 <div class="memberValue"> 110 expandKey="{{ makeExpandKey('referent') }}">
132 <any-service-ref ref="{{ ref.referent }}" 111 </any-service-ref>
133 expandKey="{{ makeExpandKey('referent') }}">
134 </any-service-ref>
135 </div>
136 </div>
137 </div> 112 </div>
138 </curly-block> 113 </curly-block>
139 </template> 114 </template>
140 115
141 <template if="{{ ref.isWeakProperty }}"> 116 <template if="{{ ref.isWeakProperty }}">
142 <a on-click="{{ goto }}" _href="{{ url }}"><em>{{ ref.clazz.name }}</em> </a> 117 <a on-click="{{ goto }}" _href="{{ url }}"><em>{{ ref.clazz.name }}</em> </a>
143 <curly-block callback="{{ expander() }}" expandKey="{{ expandKey }}"> 118 <curly-block callback="{{ expander() }}" expandKey="{{ expandKey }}">
144 <div class="memberList"> 119 <div class="indented">
145 <div class="memberItem"> 120 &lt;key&gt;&nbsp;:&nbsp;
146 <div class="memberName">key</div> 121 <any-service-ref ref="{{ ref.key }}"
147 <div class="memberValue"> 122 expandKey="{{ makeExpandKey('key') }}">
148 <any-service-ref ref="{{ ref.key }}" 123 </any-service-ref><br>
149 expandKey="{{ makeExpandKey('key') }}"> 124 &lt;value&gt;&nbsp;:&nbsp;
150 </any-service-ref> 125 <any-service-ref ref="{{ ref.value }}"
151 </div> 126 expandKey="{{ makeExpandKey('value') }}">
152 </div> 127 </any-service-ref><br>
153 <div class="memberItem">
154 <div class="memberName">value</div>
155 <div class="memberValue">
156 <any-service-ref ref="{{ ref.value }}"
157 expandKey="{{ makeExpandKey('value') }}">
158 </any-service-ref>
159 </div>
160 </div>
161 </div> 128 </div>
162 </curly-block> 129 </curly-block>
163 </template> 130 </template>
164 </span> 131 </span>
165 </template> 132 </template>
166 </polymer-element> 133 </polymer-element>
167 134
168 <script type="application/dart" src="instance_ref.dart"></script> 135 <script type="application/dart" src="instance_ref.dart"></script>
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698