Class: RubyUI::AdminResourceCard

Inherits:
Base
  • Object
show all
Defined in:
lib/generators/ruby_cms/templates/components/ruby_ui/admin_page/admin_resource_card.rb

Constant Summary collapse

CARD_CLASS =
"bg-white shadow-sm rounded-xl border border-[#e9e4d4] overflow-hidden"
GRID_CLASS =
"grid grid-cols-1 lg:grid-cols-3"
MAIN_CLASS =
"lg:col-span-2 space-y-5 p-4 sm:p-6"
"border-t lg:border-t-0 lg:border-l border-[#e9e4d4] bg-white space-y-5 p-4 sm:p-6"
ACTIONS_CLASS =
"flex flex-col gap-2 border-t border-[#e9e4d4] bg-white px-4 py-4 sm:flex-row sm:items-center sm:justify-end sm:gap-2 sm:px-6"
INPUT_CLASS =
"block w-full rounded-md border border-[#e9e4d4] bg-white px-3 py-2 text-[13.5px] text-[#1c1917] shadow-sm placeholder:text-[#a8a29e] focus:outline-none focus:border-blue-400 focus:ring-2 focus:ring-blue-500/20 transition-colors"
LABEL_CLASS =
"block text-[13px] font-medium text-[#1c1917] mb-1.5"
HINT_CLASS =
"mt-1 text-[11.5px] text-[#78716c]"
FILE_INPUT_CLASS =
"block w-full text-[13px] text-[#78716c] file:mr-3 file:py-1.5 file:px-3 file:rounded-md file:border-0 file:text-sm file:font-medium file:bg-blue-50 file:text-blue-700 hover:file:bg-blue-100 transition-colors"
SECTION_CLASS =
"rounded-xl border border-[#e9e4d4] bg-[#faf8f3] p-5"
SECTION_TITLE_CLASS =
"text-[10.5px] font-semibold text-[#78716c] uppercase tracking-[0.12em] mb-3"
DETAIL_LABEL_CLASS =
"text-[10.5px] font-medium text-[#78716c] uppercase tracking-[0.12em]"
DETAIL_VALUE_CLASS =
"mt-1 text-[13px] text-[#1c1917]"
CANCEL_CLASS =
"inline-flex items-center h-9 px-4 rounded-md bg-white border border-[#e9e4d4] text-[#1c1917] text-[12.5px] font-medium hover:bg-[#faf8f3] transition-colors no-underline"
SUBMIT_CLASS =
"inline-flex items-center h-9 px-4 rounded-md bg-blue-600 text-white text-[12.5px] font-medium hover:bg-blue-700 transition-colors cursor-pointer border-0"

Constants inherited from Base

Base::TAILWIND_MERGER

Instance Attribute Summary

Attributes inherited from Base

#attrs

Instance Method Summary collapse

Methods inherited from Base

#initialize

Constructor Details

This class inherits a constructor from RubyUI::Base

Instance Method Details

#view_templateObject



24
25
26
# File 'lib/generators/ruby_cms/templates/components/ruby_ui/admin_page/admin_resource_card.rb', line 24

def view_template(&)
  div(class: CARD_CLASS, &)
end