OSDN Git Service

add story
[pettanr/pettanr.git] / app / views / panels / _standard.html.erb
1 <div class="panel" style="width:<%= @panel.width %>px;height:<%= @panel.height %>px;overflow:hidden; border:solid black <%= @panel.border %>px; background:white;">
2   <% @panel.each_element do |elm| %>
3     <% if elm.kind_of?(PanelPicture) %>
4       <div id="vPicture<%= elm.id -%>" class="panel_picture" style="position:relative;  top:<%= elm.y -%>px; left:<%= elm.x -%>px; z-index:<%= elm.z -%>; ">
5         <img style=" position:absolute; width:<%= elm.width -%>px; height:<%= elm.height -%>px; " src="<%= elm.url -%>">
6       </div>
7     <% end %>
8     <% if elm.kind_of?(Balloon) %>
9       <div id="vballoon<%= elm.id -%>" class="balloon" style="position:relative;  top:<%= elm.y -%>px; left:<%= elm.x -%>px; z-index:<%= elm.z -%>; ">
10         <img style=" position:absolute; width:<%= elm.width -%>px; height:<%= elm.height -%>px; " src="<%= elm.system_picture.url -%>">
11         <% elm.speeches.each do |speech| %>
12           <div style="position:relative; top:<%= speech.y -%>px; left:<%= speech.x -%>px;width:<%= speech.width -%>px; height:<%= speech.height -%>px; top:1px; left:1px; z-index:1; ">
13             <%= h speech.content -%>
14           </div>
15         <% end %>
16       </div>
17     <% end %>
18   <% end %>
19 </div>
20 <span>
21 Width:<%= @panel.width %>
22 </span>
23 <span>
24 Height:<%= @panel.height %>
25 </span>
26