Déplacement pour eggification.
[Plinn.git] / Products / Plinn / skins / generic / viewCustomColorProperties.pt
diff --git a/Products/Plinn/skins/generic/viewCustomColorProperties.pt b/Products/Plinn/skins/generic/viewCustomColorProperties.pt
new file mode 100644 (file)
index 0000000..d0da846
--- /dev/null
@@ -0,0 +1,24 @@
+<html metal:use-macro="here/main_template/macros/master">
+
+  <head>
+    <meta http-equiv="content-type" content="text/html;charset=UTF-8">
+    <title>color table</title>
+  </head>
+
+  <body metal:fill-slot="main"
+                       tal:define="propsheet here/base_properties ;
+                                                                       propMap propsheet/propertyMap ;
+                                                                       strProps python:[ p for p in propMap if p['type'] == 'string' ] ;
+                                                                       colorProps python:[ p for p in strProps if p['id'].lower().find('color') >=0 or (propsheet.getProperty(p['id']).startswith('#') and propsheet.getProperty(p['id'])[1:].isalnum()  ) ]"
+                       tal:omit-tag="">
+               <h1>Color table</h1>
+    <table width="180" border="1" cellspacing="2" cellpadding="0">
+      <tr tal:repeat="prop colorProps">
+        <th tal:content="prop/id">color name</th>
+        <td tal:content="python:propsheet.getProperty(prop['id'])">#fde</td>
+        <td bgcolor="#ddd" tal:attributes="style python:'background: %s' % propsheet.getProperty(prop['id'])">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
+      </tr>
+    </table>
+  </body>
+
+</html>
\ No newline at end of file