OLD | NEW |
(Empty) | |
| 1 <html> |
| 2 <head> |
| 3 <title>url-params-sk demo</title> |
| 4 <meta charset="utf-8"> |
| 5 <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1"> |
| 6 <meta name="viewport" content="width=device-width, minimum-scale=1.0, initial-
scale=1, user-scalable=yes"> |
| 7 <script src="/res/common/js/common.js"></script> |
| 8 <script src="/res/imp/bower_components/webcomponentsjs/webcomponents-lite.js">
</script> |
| 9 <link rel="import" href="/res/imp/bower_components/paper-input/paper-input.htm
l"></script> |
| 10 <link rel="import" href="url-params-sk.html"> |
| 11 </head> |
| 12 <body> |
| 13 <dom-module id="url-param-demo"> |
| 14 <template> |
| 15 <style is="custom-style"> |
| 16 iron-selector > * { |
| 17 padding: 8px; |
| 18 } |
| 19 .horizontal-section { |
| 20 padding: 0; |
| 21 } |
| 22 .iron-selected { |
| 23 background-color: #4285f4; |
| 24 color: white; |
| 25 } |
| 26 </style> |
| 27 <url-param-sk name="exclude" value="{{exclude}}" multi></url-param-sk> |
| 28 <paper-input value="{{exclude_value}}"></paper-input> |
| 29 </template> |
| 30 <script> |
| 31 Polymer({ |
| 32 is: 'url-param-demo', |
| 33 |
| 34 properties: { |
| 35 exclude: { |
| 36 type: Array, |
| 37 computed: "_makeArray(exclude_value)", |
| 38 }, |
| 39 exclude_value: { |
| 40 type: String, |
| 41 value: "alpha,beta", |
| 42 } |
| 43 }, |
| 44 _makeArray: function(s) { |
| 45 if (!s) { |
| 46 return []; |
| 47 } |
| 48 return s.split(','); |
| 49 } |
| 50 }); |
| 51 </script> |
| 52 </dom-module> |
| 53 |
| 54 <h1>url-param-sk demo</h1> |
| 55 <url-param-demo></url-param-demo> |
| 56 |
| 57 </body> |
| 58 </html> |
OLD | NEW |