Class: Scarpe::WebviewStack

Inherits:
WebviewSlot show all
Defined in:
lib/scarpe/wv/stack.rb

Constant Summary

Constants included from WebviewSpacing

Scarpe::WebviewSpacing::SPACING_DIRECTIONS

Constants included from Log

Log::DEFAULT_DEBUG_LOG_CONFIG, Log::DEFAULT_LOG_CONFIG

Instance Attribute Summary

Attributes inherited from WebviewWidget

#children, #parent, #shoes_linkable_id

Attributes inherited from Shoes::Linkable

#linkable_id

Instance Method Summary collapse

Methods inherited from WebviewSlot

#attributes, #element, #initialize, #remove_event_callback, #remove_event_callbacks, #set_event_callback, #update_dom_event

Methods included from WebviewSpacing

#extract_spacing_styles_for, #spacing_values_from_options

Methods included from Base64

#encode_file_to_base64, #valid_url?

Methods inherited from WebviewWidget

#add_child, #bind, #destroy_self, display_class_for, #handler_js_code, #html_element, #html_id, #initialize, #inspect, #needs_update!, #promise_update, #properties_changed, #remove_child, #rgb_to_hex, #set_parent, #to_html

Methods included from Log

#log_init

Methods inherited from Shoes::Linkable

#bind_shoes_event, #initialize, #send_self_event, #send_shoes_event, #unsub_shoes_event

Constructor Details

This class inherits a constructor from Scarpe::WebviewSlot

Instance Method Details

#get_styleObject



5
6
7
# File 'lib/scarpe/wv/stack.rb', line 5

def get_style
  style
end

#styleObject (protected)



11
12
13
14
15
16
17
18
19
20
21
22
# File 'lib/scarpe/wv/stack.rb', line 11

def style
  styles = super

  styles[:display] = "flex"
  styles["flex-direction"] = "column"
  styles["align-content"] = "flex-start"
  styles["justify-content"] = "flex-start"
  styles["align-items"] = "flex-start"
  styles["overflow"] = "auto" if @scroll

  styles
end