Class: Plutonium::Profile::SecuritySection
- Inherits:
-
UI::Component::Base
- Object
- UI::Component::Base
- Plutonium::Profile::SecuritySection
- Defined in:
- lib/plutonium/profile/security_section.rb
Overview
Renders security settings links based on enabled Rodauth features.
Constant Summary collapse
- FEATURES =
{ change_password: { label: "Change Password", description: "Update your account password", icon: Phlex::TablerIcons::Key, path_method: :change_password_path }, change_login: { label: "Change Email", description: "Update your email address", icon: Phlex::TablerIcons::Mail, path_method: :change_login_path }, otp: { label: "Two-Factor Authentication", description: "Add an extra layer of security", icon: Phlex::TablerIcons::DeviceMobile, path_method: :otp_setup_path }, recovery_codes: { label: "Recovery Codes", description: "View or regenerate backup codes", icon: Phlex::TablerIcons::FileCode, path_method: :recovery_codes_path }, webauthn: { label: "Security Keys", description: "Manage passkeys and security keys", icon: Phlex::TablerIcons::Fingerprint, path_method: :webauthn_setup_path }, active_sessions: { label: "Active Sessions", description: "View and manage your sessions", icon: Phlex::TablerIcons::DevicesCheck, path_method: :active_sessions_path }, close_account: { label: "Close Account", description: "Permanently delete your account", icon: Phlex::TablerIcons::Trash, path_method: :close_account_path, danger: true } }.freeze
Instance Method Summary collapse
Methods included from UI::Component::Behaviour
Methods included from UI::Component::Tokens
Methods included from UI::Component::Kit
#BuildActionButton, #BuildActionsDropdown, #BuildBlock, #BuildBreadcrumbs, #BuildBulkActionsToolbar, #BuildColorModeSelector, #BuildDynaFrameContent, #BuildDynaFrameHost, #BuildEmptyCard, #BuildFrameNavigatorPanel, #BuildPageHeader, #BuildPanel, #BuildRowActionsDropdown, #BuildSkeletonTable, #BuildTabList, #BuildTableInfo, #BuildTablePagination, #BuildTableScopesBar, #BuildTableSearchBar, #method_missing, #respond_to_missing?
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Plutonium::UI::Component::Kit
Instance Method Details
#view_template ⇒ Object
53 54 55 56 57 58 |
# File 'lib/plutonium/profile/security_section.rb', line 53 def view_template div(class: "mt-8") do render_section_header render_feature_links end end |