From 6f8e74f79abe5b4fb677e0972dfef9cf99288485 Mon Sep 17 00:00:00 2001
From: luigser <luigser@gmail.com>
Date: Thu, 22 Oct 2015 17:47:16 +0200
Subject: [PATCH] card update

---
 controllets/data-sevc-controllet/data-sevc-controllet.html   |  4 ++--
 controllets/paper-card-controllet/paper-card-controllet.html | 63 +++++++++++++++++++++++++++++++++++++++++----------------------
 2 files changed, 43 insertions(+), 24 deletions(-)

diff --git a/controllets/data-sevc-controllet/data-sevc-controllet.html b/controllets/data-sevc-controllet/data-sevc-controllet.html
index 8870da2..e7249b2 100755
--- a/controllets/data-sevc-controllet/data-sevc-controllet.html
+++ b/controllets/data-sevc-controllet/data-sevc-controllet.html
@@ -64,8 +64,8 @@ is available every time a fields is dragged in the input data model fields area.
 
 Example:
 
-    <data-sevc-controllet deep-url="http://192.168.214.128/DatalEts-Ecosystem-Provider/DEEP/"
-                          datalets-list-url="http://192.168.214.128/DatalEts-Ecosystem-Provider/DEEP/datalets-list"
+    <data-sevc-controllet deep-url="http://192.168.36.128/DatalEts-Ecosystem-Provider/DEEP/"
+                          datalets-list-url="http://192.168.36.128/DatalEts-Ecosystem-Provider/DEEP/datalets-list"
                           datasets='{[{name : 'dataset1', url : dataset1Urls}, ... , {name : 'datasetN', url : datasetNUrls}]'>
     </data-sevc-controllet>
 
diff --git a/controllets/paper-card-controllet/paper-card-controllet.html b/controllets/paper-card-controllet/paper-card-controllet.html
index f74bec1..6dee1b7 100644
--- a/controllets/paper-card-controllet/paper-card-controllet.html
+++ b/controllets/paper-card-controllet/paper-card-controllet.html
@@ -17,6 +17,7 @@
                 line-height: 10px;
                 --paper-fab-background: var(--accent-color);
                 font-family: 'Roboto', sans-serif;
+                padding-bottom: 30px;
             }
 
             paper-material {
@@ -69,6 +70,7 @@
             #text{
                 position:relative;
                 top: -50px;
+                min-height: 50px;
                 height: auto;
                 padding: 8px 8px 8px 8px;
                 font-size: 10px;
@@ -85,43 +87,44 @@
                     <content></content>
                 </div>
 
-                <div class="footer">
+                <template is="dom-if" if="{{legend}}">
 
-                    <template is="dom-if" if="{{legend}}">
+                    <div class="legend horizontal layout center">
+                        <span>{{legend}}</span>
+                        <!-- Adding icon based on card type -->
 
-                        <div class="legend horizontal layout center">
-                            <span>{{legend}}</span>
-                            <!-- Adding icon based on card type -->
+                        <template is="dom-if" if="{{checkType(type, 'text')}}">
 
-                            <template is="dom-if" if="{{checkType(type, 'text')}}">
+                            <paper-fab mini icon="create"></paper-fab>
 
-                               <paper-fab mini icon="create"></paper-fab>
+                        </template>
 
-                             </template>
+                        <template is="dom-if" if="{{checkType(type, 'image')}}">
 
-                            <template is="dom-if" if="{{checkType(type, 'image')}}">
+                            <paper-fab mini icon="perm-media"></paper-fab>
 
-                                <paper-fab mini icon="perm-media"></paper-fab>
+                        </template>
 
-                            </template>
+                        <template is="dom-if" if="{{checkType(type, 'datalet')}}">
 
-                            <template is="dom-if" if="{{checkType(type, 'datalet')}}">
+                            <paper-fab mini icon="assessment"></paper-fab>
 
-                                <paper-fab mini icon="assessment"></paper-fab>
+                        </template>
 
-                            </template>
+                        <template is="dom-if" if="{{checkType(type, 'link')}}">
 
-                            <template is="dom-if" if="{{checkType(type, 'link')}}">
+                            <paper-fab mini icon="link"></paper-fab>
 
-                                <paper-fab mini icon="link"></paper-fab>
+                        </template>
 
-                            </template>
+                    </div>
 
-                        </div>
+                </template>
 
+                <div class="footer">
+                    <template is="dom-if" if="{{text}}">
+                       <div id="text">{{text}}</div>
                     </template>
-
-                    <div id="text">{{text}}</div>
                 </div>
 
             </div>
@@ -146,6 +149,21 @@
                 type:{
                     type: String,
                     value: "text"
+                },
+                text:{
+                    type: String,
+                    value: ""
+                },
+                legend:{
+                    type: String,
+                    value: ""
+                }
+
+            },
+
+            ready: function(){
+                if(this.type == "text"){
+                    this.$.content.style.backgroundColor = "#ffc";
                 }
             },
 
@@ -156,9 +174,10 @@
             },
 
             _changeHeight: function(data){
-                this.style.height = (data + 20) + "px";
+                this.style.height = (data) + "px";
                 this.$.content.style.height = data + "px";
-               //$(this.$.content).perfectScrollbar();
+                this.style.height = (this.height + ((this.text != "") ? 50 : 0)) + "px";
+                $(this.$.content).perfectScrollbar();
             },
 
             checkType: function(type, check){
--
libgit2 0.21.4