class Avo::Configuration

def app_name

def app_name
  Avo::ExecutionContext.new(target: @app_name).handle
end

def authenticate_with(&block)

def authenticate_with(&block)
  @authenticate = block if block.present?
end

def branding

def branding
  Avo::Configuration::Branding.new(**@branding || {})
end

def current_user_method(&block)

def current_user_method(&block)
  @current_user = block if block.present?
end

def current_user_method=(method)

def current_user_method=(method)
  @current_user = method if method.present?
end

def feature_enabled?(feature)

def feature_enabled?(feature)
  !@disabled_features.map(&:to_sym).include?(feature.to_sym)
end

def initialize

def initialize
  @root_path = "/avo"
  @app_name = ::Rails.application.class.to_s.split("::").first.underscore.humanize(keep_id_suffix: true)
  @timezone = "UTC"
  @per_page = 24
  @per_page_steps = [12, 24, 48, 72]
  @via_per_page = 8
  @locale = nil
  @currency = "USD"
  @default_view_type = :table
  @license = "community"
  @license_key = nil
  @current_user = proc {}
  @authenticate = proc {}
  @authorization_methods = {
    index: "index?",
    show: "show?",
    edit: "edit?",
    new: "new?",
    update: "update?",
    create: "create?",
    destroy: "destroy?"
  }
  @id_links_to_resource = false
  @full_width_container = false
  @full_width_index_view = false
  @cache_resources_on_index_view = Avo::PACKED
  @cache_resource_filters = false
  @context = proc {}
  @initial_breadcrumbs = proc {
    add_breadcrumb I18n.t("avo.home").humanize, avo.root_path
  }
  @display_breadcrumbs = true
  @hide_layout_when_printing = false
  @home_path = nil
  @search_debounce = 300
  @view_component_path = "app/components"
  @display_license_request_timeout_error = true
  @current_user_resource_name = "user"
  @raise_error_on_missing_policy = false
  @disabled_features = []
  @buttons_on_form_footers = false
  @main_menu = nil
  @profile_menu = nil
  @model_resource_mapping = {}
  @resource_default_view = :show
  @authorization_client = :pundit
  @field_wrapper_layout = :inline
  @resources = nil
  @resource_parent_controller = "Avo::ResourcesController"
end

def namespace

def namespace
  if Avo.configuration.root_path.present?
    Avo.configuration.root_path.delete "/"
  else
    root_path.delete "/"
  end
end

def root_path

def root_path
  return "" if @root_path === "/"
  @root_path
end

def set_context(&block)

def set_context(&block)
  @context = block if block.present?
end

def set_initial_breadcrumbs(&block)

def set_initial_breadcrumbs(&block)
  @initial_breadcrumbs = block if block.present?
end