Sha256: 94452a71b755d1cf4845c5a1e943759230a0501748609a9a0eb7b4b34f1fadd1

Contents?: true

Size: 1.62 KB

Versions: 25

Compression:

Stored size: 1.62 KB

Contents

# frozen_string_literal: true

class HandlebarsHelperChild < KDirector::Directors::ChildDirector
  def initialize(parent, **opts)
    super(parent, **opts)

    builder.add_helper

    # defaults = {
    #   repo_name: opts[:repo_name], # || parent.builder.dom&[:github]&[:repo_name]
    #   username: opts[:username] || default_github_username, # || parent.builder.dom&[:github]&[:username]
    #   organization: opts[:organization] # || parent.builder.dom&[:github]&[:organization]
    # }
  end

  def name(value)
    builder.helper_setting(:name, value)
  end

  def description(value)
    builder.helper_setting(:description, value)
  end

  def result(value)
    builder.helper_setting(:result, value)
  end

  def category(value)
    builder.helper_setting(:category, value)
  end

  def category_description(value)
    builder.helper_setting(:category_description, value)
  end

  # def base_class_require(value)
  #   builder.helper_setting(:base_class_require, value)
  # end

  # def base_class(value)
  #   builder.helper_setting(:base_class, value)
  # end

  # def example_input_value(value)
  #   builder.helper_setting(:example_input_value, value)
  # end

  # def example_output_value(value)
  #   builder.helper_setting(:example_output_value, value)
  # end

  # def test_input_value(value)
  #   builder.helper_setting(:test_input_value, value)
  # end

  # def test_output_value(value)
  #   builder.helper_setting(:test_output_value, value)
  # end

  def parameter(name, description, splat: false)
    builder.add_helper_parameter(name, description, splat: splat)
  end

  def example(value)
    builder.add_helper_example(value)
  end
end

Version data entries

25 entries across 25 versions & 2 rubygems

Version Path
handlebarsjs-0.5.5 .builders/director/handlebars_helper_child.rb
handlebarsjs-0.5.4 .builders/director/handlebars_helper_child.rb
handlebarsjs-0.5.3 .builders/director/handlebars_helper_child.rb
handlebarsjs-0.5.2 .builders/director/handlebars_helper_child.rb
cmdlet-0.0.7 .builders/director/cmdlet_child.rb