Sha256: 790a3ea5306285fc6988b4c7a92f8e713c4a60f9c8c29fe0cb6cf4d9d18c1a9a
Contents?: true
Size: 592 Bytes
Versions: 12
Compression:
Stored size: 592 Bytes
Contents
module Coprl::Presenters::WebClient::Helpers module DragAndDrop def draggable_attributes(comp) draggable_attributes = '' if comp.draggable draggable_attributes = "draggable=true data-drag_params='#{comp.draggable.to_h.to_json}'" end draggable_attributes end def drop_zone_attributes(comp) drop_zone_attributes = '' if comp.drop_zone zone = comp.drop_zone[:zone] drop_zone_attributes = "data-dropzone='#{zone}' data-drop_params='#{comp.drop_zone.to_h.to_json}'" end drop_zone_attributes end end end
Version data entries
12 entries across 12 versions & 1 rubygems