Class: Ferro::Element::Script
- Inherits:
-
BaseElement
- Object
- BaseElement
- Ferro::Element::Script
- Defined in:
- opal/opal-ferro/elements/ferro_misc.js.rb
Overview
Creates a miscellaneous element. In the DOM creates a: <script>. Specify option :invoke = false to prevent the script from being executed.
Constant Summary
Constants included from Ferro::Elementary
Ferro::Elementary::RESERVED_NAMES
Instance Attribute Summary
Attributes inherited from BaseElement
#children, #domtype, #element, #parent, #sym
Instance Method Summary collapse
-
#_after_create ⇒ Object
Internal method.
-
#_before_create ⇒ Object
Internal method.
-
#invoke ⇒ Object
Override method to specify the execution of the script.
-
#load ⇒ Object
Override method to specify the content of the Javascript.
Methods inherited from BaseElement
#add_state, #add_states, #classify_state, #component, #dom_id, #factory, #get_text, #html, #initialize, #option_replace, #remove_attribute, #root, #router, #set_attribute, #set_text, #state_active?, #toggle_state, #update_state, #value, #value=
Methods included from Ferro::Elementary
#_stylize, #add_child, #after_create, #before_create, #cascade, #create, #creation, #destroy, #each_child, #forget_children, #method_missing, #remove_child, #style, #symbolize
Constructor Details
This class inherits a constructor from Ferro::BaseElement
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Ferro::Elementary
Instance Method Details
#_after_create ⇒ Object
Internal method.
49 50 51 52 |
# File 'opal/opal-ferro/elements/ferro_misc.js.rb', line 49 def _after_create load invoke if @run end |
#_before_create ⇒ Object
Internal method.
43 44 45 46 |
# File 'opal/opal-ferro/elements/ferro_misc.js.rb', line 43 def _before_create @domtype = :script @run = option_replace :invoke, true end |
#invoke ⇒ Object
Override method to specify the execution of the script.
58 |
# File 'opal/opal-ferro/elements/ferro_misc.js.rb', line 58 def invoke;end |
#load ⇒ Object
Override method to specify the content of the Javascript.
55 |
# File 'opal/opal-ferro/elements/ferro_misc.js.rb', line 55 def load;end |