app/views/sketchily/_embed.html.erb~ in sketchily-1.2.0 vs app/views/sketchily/_embed.html.erb~ in sketchily-1.3.0

- old
+ new

@@ -3,10 +3,12 @@ # value # # Additionally, they may override the following variables: width ||= "750px" height ||= "650px" + bkgd_color ||= "FFFFFF" + bkgd_url ||= "" canvas_width ||= 640 canvas_height ||= 480 canvas_expansion ||= 3 hide_rulers ||= false hide_menu ||= false @@ -17,18 +19,17 @@ %> <% iframe_src = URI.parse("/assets/svg-editor.html") query_hash = {:dimensions => [canvas_width, canvas_height].join(','), + :bkgd_color => bkgd_color, + :bkgd_url => bkgd_url, :canvas_expansion => canvas_expansion, :showRulers => !hide_rulers, :showlayers => show_layers} - if url - query_hash[:url] = url - else - query_hash[:source] = nil - end + query_hash[:url] = url if url + query_hash[:source] = nil unless url iframe_src.query = query_hash.map{|k,v| "#{k}=#{v}"}.join('&') %> <%= javascript_include_tag "sketchily_embed" %> @@ -47,5 +48,6 @@ :hide_menu => hide_menu, :hide_image_tool => hide_image_tool, :hide_hyperlink_tool => hide_hyperlink_tool, :url => url} %> </script> +