Class: Crm::ContentLinkEditorComponent
- Inherits:
-
ApplicationComponent
- Object
- ViewComponent::Base
- ApplicationComponent
- Crm::ContentLinkEditorComponent
- Includes:
- ActionView::Helpers::FormTagHelper, ActionView::RecordIdentifier
- Defined in:
- app/components/crm/content_link_editor_component.rb
Overview
ViewComponent: renders the content link editor block.
Renders grouped content links for a source record, either from live
ContentLink rows or from an ArticleRevision's staged link data,
together with the Stimulus-driven form used to add and reorder links.
Defined Under Namespace
Classes: Entry
Instance Method Summary collapse
-
#initialize(source:, revision: nil) ⇒ ContentLinkEditorComponent
constructor
A new instance of ContentLinkEditorComponent.
Methods inherited from ApplicationComponent
#cms_link, #fetch_or_fallback, #image_asset_tag, #image_tag, #number_to_currency, #number_with_delimiter, #post_path, #post_url, #strip_tags
Constructor Details
#initialize(source:, revision: nil) ⇒ ContentLinkEditorComponent
Returns a new instance of ContentLinkEditorComponent.
25 26 27 28 29 |
# File 'app/components/crm/content_link_editor_component.rb', line 25 def initialize(source:, revision: nil) super() @source = source @revision = revision end |