Home | History | Annotate | Download | only in jstemplate
      1 <!--
      2 Copyright 2006 Google Inc.
      3 
      4 Licensed under the Apache License, Version 2.0 (the "License");
      5 you may not use this file except in compliance with the License.
      6 You may obtain a copy of the License at
      7 
      8      http://www.apache.org/licenses/LICENSE-2.0
      9 
     10 Unless required by applicable law or agreed to in writing, software
     11 distributed under the License is distributed on an "AS IS" BASIS,
     12 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     13 See the License for the specific language governing permissions and
     14 limitations under the License.
     15 -->
     16 <!--
     17 Fileoverview: JsUnit test runner page for jstemplates. 
     18 
     19 Author: Steffen Meschkat (mesch (a] google.com)
     20 -->
     21 <html>
     22   <head>
     23     <title>jstemplate jsunit tests</title>
     24     <script src="jsunit/app/jsUnitCore.js"></script>
     25     <script src="util.js"></script>
     26     <script src="jsevalcontext.js"></script>
     27     <script src="jstemplate.js"></script>
     28     <script src="jstemplate_unittest.js"></script>
     29   </head>
     30   <body>
     31 
     32 <!-- jsselect, jscontent, $this -->
     33 <div id="t1">
     34   <div jsselect="items" jscontent="$this"></div>
     35 </div>
     36 
     37 <!-- jsdisplay -->
     38 <div id="t2">
     39   <div jsdisplay="display">display</div>
     40 </div>
     41 <div id="t2a">
     42   <div jsdisplay="this.id == showId" id="x">x</div>
     43 </div>
     44 
     45 <!-- variables, jsvalues -->
     46 <div id="t3" jsvalues="$href:'http://maps.google.com/'">
     47   <a href="http://www.google.com/" id="t3a"
     48   jsvalues="href:$href;.foo.bar.baz:$href;.style.backgroundColor:'red';.bar:$href">link here</a>
     49 </div>
     50 
     51 <div id="testJseval1" jseval="callback1()"></div>
     52 <div id="testJseval2" jseval="callback1();callback2();"></div>
     53 
     54 <!-- transclude -->
     55 <div id="parent">
     56   <div id="t4" transclude="t4a"></div>
     57 </div>
     58 <div id="t4a" jsvalues="$href:'http://maps.google.com/'">
     59   <a href="http://www.google.com/" jsvalues="href:$href">link here</a>
     60 </div>
     61 
     62 <!-- scalar values as context -->
     63 <div id="testScalarContext">
     64   <div jscontent="$this"></div>
     65 </div>
     66   </body>
     67 </html>