Methods
- #
- A
- F
- G
- I
- L
- N
- R
- T
Attributes
[R] | fragment |
Class Public methods
fragment_by_canonicalizing_content(content) Link
# File actiontext/lib/action_text/content.rb, line 12 def fragment_by_canonicalizing_content(content) fragment = ActionText::Attachment.fragment_by_canonicalizing_attachments(content) fragment = ActionText::AttachmentGallery.fragment_by_canonicalizing_attachment_galleries(fragment) fragment end
new(content = nil, options = {}) Link
# File actiontext/lib/action_text/content.rb, line 19 def initialize(content = nil, options = {}) options.with_defaults! canonicalize: true if options[:canonicalize] @fragment = self.class.fragment_by_canonicalizing_content(content) else @fragment = ActionText::Fragment.wrap(content) end end
Instance Public methods
==(other) Link
append_attachables(attachables) Link
as_json(*) Link
attachables() Link
attachment_galleries() Link
attachments() Link
gallery_attachments() Link
inspect() Link
links() Link
render_attachment_galleries(&block) Link
# File actiontext/lib/action_text/content.rb, line 67 def render_attachment_galleries(&block) content = ActionText::AttachmentGallery.fragment_by_replacing_attachment_gallery_nodes(fragment) do |node| block.call(attachment_gallery_for_node(node)) end self.class.new(content, canonicalize: false) end