Commit 7705e54aa1b968308312aba8bfe5b0f4257bfb9d
1 parent
f81cb81f
plugin updates
Showing
1 changed file
with
22 additions
and
11 deletions
controllets/document-card-controllet/document-card-controllet.html
@@ -21,10 +21,11 @@ | @@ -21,10 +21,11 @@ | ||
21 | } | 21 | } |
22 | 22 | ||
23 | #content { | 23 | #content { |
24 | - padding: 4px 4px 0px 4px; | ||
25 | position:relative; | 24 | position:relative; |
25 | + padding: 2px; | ||
26 | + /*padding: 4px 4px 0px 4px; | ||
26 | width: 98%; | 27 | width: 98%; |
27 | - height: 90%; | 28 | + height: 90%;*/ |
28 | } | 29 | } |
29 | 30 | ||
30 | .footer { | 31 | .footer { |
@@ -115,17 +116,19 @@ | @@ -115,17 +116,19 @@ | ||
115 | <paper-material id="paper_card_container" elevation="{{elevation}}"> | 116 | <paper-material id="paper_card_container" elevation="{{elevation}}"> |
116 | 117 | ||
117 | <div id="content"> | 118 | <div id="content"> |
118 | - <iframe id="resource" src="{{resourceUrl}}?userName={{userName}}"></iframe> | 119 | + <iframe id="resource" src="{{resourceUrl}}?userName={{userName}}&showControls={{showControls}}&showLineNumbers=false&readOnly={{readOnly}}"></iframe> |
119 | <!--<iframe id="resource" src="{{resourceUrl}}"></iframe>--> | 120 | <!--<iframe id="resource" src="{{resourceUrl}}"></iframe>--> |
120 | </div> | 121 | </div> |
121 | 122 | ||
122 | - <paper-fab id="fullscreen-button" class="open" mini icon="fullscreen" on-click="_handleOpenClick"></paper-fab> | 123 | + <template id="dom-if" if="{{showControls}}"> |
124 | + <paper-fab id="fullscreen-button" class="open" mini icon="fullscreen" on-click="_handleOpenClick"></paper-fab> | ||
123 | 125 | ||
124 | - <paper-dialog id="fullscreen_container" entry-animation="scale-up-animation" exit-animation="fade-out-animation"> | ||
125 | - <!--with-backdrop--> | ||
126 | - <div id="fullscreen_content"></div> | ||
127 | - <paper-button id="info_close_button" dialog-confirm autofocus>x</paper-button> | ||
128 | - </paper-dialog> | 126 | + <paper-dialog id="fullscreen_container" entry-animation="scale-up-animation" exit-animation="fade-out-animation"> |
127 | + <!--with-backdrop--> | ||
128 | + <div id="fullscreen_content"></div> | ||
129 | + <paper-button id="info_close_button" dialog-confirm autofocus>x</paper-button> | ||
130 | + </paper-dialog> | ||
131 | + </template> | ||
129 | 132 | ||
130 | </paper-material> | 133 | </paper-material> |
131 | 134 | ||
@@ -134,7 +137,6 @@ | @@ -134,7 +137,6 @@ | ||
134 | <script src="../shared_js/perfect-scrollbar/js/min/perfect-scrollbar.jquery.min.js"></script> | 137 | <script src="../shared_js/perfect-scrollbar/js/min/perfect-scrollbar.jquery.min.js"></script> |
135 | 138 | ||
136 | <script> | 139 | <script> |
137 | - _this = null; | ||
138 | 140 | ||
139 | Polymer({ | 141 | Polymer({ |
140 | is: "document-card-controllet", | 142 | is: "document-card-controllet", |
@@ -174,6 +176,16 @@ | @@ -174,6 +176,16 @@ | ||
174 | type: String, | 176 | type: String, |
175 | value: undefined | 177 | value: undefined |
176 | }, | 178 | }, |
179 | + | ||
180 | + showControls: { | ||
181 | + type: Boolean, | ||
182 | + value: false | ||
183 | + }, | ||
184 | + readOnly: { | ||
185 | + type: Boolean, | ||
186 | + value: false | ||
187 | + }, | ||
188 | + | ||
177 | lang:{ | 189 | lang:{ |
178 | type: String, | 190 | type: String, |
179 | value: navigator.language | 191 | value: navigator.language |
@@ -187,7 +199,6 @@ | @@ -187,7 +199,6 @@ | ||
187 | $(this.$.fullscreen_container).perfectScrollbar(); | 199 | $(this.$.fullscreen_container).perfectScrollbar(); |
188 | }, | 200 | }, |
189 | 201 | ||
190 | - | ||
191 | _changeWidth: function(){ | 202 | _changeWidth: function(){ |
192 | //this.style.width = this.width + "px"; | 203 | //this.style.width = this.width + "px"; |
193 | //this.$.paper_card_container.style.width = this.width + "px"; | 204 | //this.$.paper_card_container.style.width = this.width + "px"; |