Module: Iron::ApplicationHelper

Includes:
AvatarHelper, ContentTypesHelper, EntriesHelper, FieldDefinitionsHelper, FieldsHelper, IconsHelper, TransfersHelper, UiHelper
Defined in:
app/helpers/iron/application_helper.rb

Constant Summary collapse

TAILWIND_MERGER =
TailwindMerge::Merger.new.freeze

Constants included from IconsHelper

IconsHelper::SPRITE_PATH

Instance Method Summary collapse

Methods included from IconsHelper

#icon

Methods included from AvatarHelper

#avatar

Methods included from UiHelper

#back_button_to, #badge

Methods included from EntriesHelper

#current_content_page?

Methods included from ContentTypesHelper

#content_type_sidebar_url

Methods included from TransfersHelper

#button_to_copy_to_clipboard, #qr_code_image, #web_share_button

Methods included from FieldDefinitionsHelper

#field_definition_color, #field_definition_icon, #field_definition_type_options

Methods included from FieldsHelper

#file_field_fallback_icon

Instance Method Details

#email_configured?Boolean

Returns:

  • (Boolean)


16
17
18
# File 'app/helpers/iron/application_helper.rb', line 16

def email_configured?
  EmailConfiguration.available?
end

#tw(*classes) ⇒ Object



8
9
10
# File 'app/helpers/iron/application_helper.rb', line 8

def tw(*classes)
  TAILWIND_MERGER.merge(classes.reject(&:blank?).compact.join(" "))
end

#unique_idObject



12
13
14
# File 'app/helpers/iron/application_helper.rb', line 12

def unique_id
  rand(10000000..100000000)
end