add image buton

This commit is contained in:
Kanezoh 2021-06-30 14:03:35 +09:00
parent 6144bb8a55
commit cfd37b5374
3 changed files with 5 additions and 0 deletions

View File

@ -72,6 +72,8 @@ class MechanizeCr::Form
buttons << FormContent::SubmitButton.new(html_node, @node) buttons << FormContent::SubmitButton.new(html_node, @node)
when"reset" when"reset"
buttons << FormContent::ResetButton.new(html_node, @node) buttons << FormContent::ResetButton.new(html_node, @node)
when "image"
buttons << FormContent::ImageButton.new(html_node, @node)
when "text" when "text"
fields << FormContent::Text.new(html_node) fields << FormContent::Text.new(html_node)
when "hidden" when "hidden"

View File

@ -7,3 +7,4 @@ class MechanizeCr::FormContent::Button < MechanizeCr::FormContent::Field
end end
require "./reset_button" require "./reset_button"
require "./submit_button" require "./submit_button"
require "./image_button"

View File

@ -0,0 +1,2 @@
class MechanizeCr::FormContent::ImageButton < MechanizeCr::FormContent::Button
end