Sha256: a70b1b6511b16258634d152f7790ec12fea88e9d053bf634e7eae2077cfbdf00

Contents?: true

Size: 556 Bytes

Versions: 12

Compression:

Stored size: 556 Bytes

Contents

module WebClient
  module Actions
    class Loads
      include Coprl::Presenters::WebClient::Helpers::ExpandHash

      def call(action, *)
        # Type, URL, Options, Params (passed into javascript event/action classes)
        safe_options = action.options.to_h
        [action.type, action.url,
         safe_options.merge({input_tag: safe_options.fetch(:input_tag, nil),
                                    wait_for_download: safe_options.fetch(:wait_for_download, false)}),
         expand_hash(action.dynamic_params)]
      end
    end
  end
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
coprl-3.0.0.beta.12 views/mdc/components/actions/loads.rb
coprl-3.0.0.beta.11 views/mdc/components/actions/loads.rb
coprl-3.0.0.beta.10 views/mdc/components/actions/loads.rb
coprl-3.0.0.beta.9 views/mdc/components/actions/loads.rb
coprl-3.0.0.beta.8 views/mdc/components/actions/loads.rb
coprl-3.0.0.beta.7 views/mdc/components/actions/loads.rb
coprl-3.0.0.beta.6 views/mdc/components/actions/loads.rb
coprl-3.0.0.beta.5 views/mdc/components/actions/loads.rb
coprl-3.0.0.beta.4 views/mdc/components/actions/loads.rb
coprl-3.0.0.beta.3 views/mdc/components/actions/loads.rb
coprl-3.0.0.beta.2 views/mdc/components/actions/loads.rb
coprl-3.0.0.beta.1 views/mdc/components/actions/loads.rb