| OLD | NEW |
| 1 <head> | 1 <link rel="import" href="nav_bar.html"> |
| 2 <link rel="import" href="observatory_element.html"> | 2 <link rel="import" href="observatory_element.html"> |
| 3 </head> | |
| 4 <polymer-element name="json-view" extends="observatory-element"> | 3 <polymer-element name="json-view" extends="observatory-element"> |
| 5 <template> | 4 <template> |
| 6 <template bind if="{{ valueType == 'Primitive' }}"> | 5 <nav-bar> |
| 7 <span>{{primitiveString}}</span> | 6 <top-nav-menu last="{{ true }}"></top-nav-menu> |
| 8 </template> | 7 </nav-bar> |
| 9 <template bind if="{{ valueType == 'List' }}"> | 8 <pre>{{ mapAsString }}</pre> |
| 10 <table class="table table-condensed table-bordered"> | |
| 11 <caption class="text-left">List, {{list.length}}</caption> | |
| 12 <tbody> | |
| 13 <tr template repeat="{{item in list)}}"> | |
| 14 <th>{{counter}}</th> | |
| 15 <td><json-view json="{{item}}"></json-view></td> | |
| 16 </tr> | |
| 17 </tbody> | |
| 18 </table> | |
| 19 </template> | |
| 20 <template if="{{ valueType == 'Map' }}"> | |
| 21 <table class="table table-condensed table-bordered"> | |
| 22 <caption class="text-left">Map, {{keys.length}}</caption> | |
| 23 <tbody> | |
| 24 <tr template repeat="{{key in keys}}"> | |
| 25 <th>{{key}}</th> | |
| 26 <td><json-view json="{{value(key)}}"></json-view></td> | |
| 27 </tr> | |
| 28 </tbody> | |
| 29 </table> | |
| 30 </template> | |
| 31 </template> | 9 </template> |
| 32 <script type="application/dart" src="json_view.dart"></script> | 10 <script type="application/dart" src="json_view.dart"></script> |
| 33 </polymer-element> | 11 </polymer-element> |
| OLD | NEW |