-
-
Notifications
You must be signed in to change notification settings - Fork 270
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
No documentation/demo/testing for Action Text has_rich_text #2714
Comments
This issue has been marked as stale because there was no activity for the past 15 days. |
I would love to see this fixed. Lack of action text support prevents us from finishing our migration to Avo started a few months ago. |
Hey @sedubois. It's true we didn't have all of these documented. I added them now (docs link). We are a bit squeezed on time and can't add a Please let me know if there's anything else we can help you with in regards with documentation about Active Text and Action Storage, otherwise I'll close this to keep the issue queue clean. |
@adrianthedev it's great to have a first Avo demo with It does demonstrate that embed captions don't yet work, the caption text is displayed in the wrong place and breaks when re-saving the resource: It is also mentioned in this comment: The other issue is this one with custom embeds, I don't know how to fix it but provided a repro: |
For the custom embeds we'd need to dig in deeper and that takes time. Would you be open to book some paid support so we can look into it further? |
Describe the bug
I could find neither in the documentation nor in the Avo Demo nor in the test suite how to hook up a resource with Action Text
has_rich_text
attributes.Expected behavior
has_rich_text
in the Rails modelhas_rich_text :body
(*),rails g avo:resource
generates an Avo field of the correct type and with the correct parameters (currently it generatesfield :body, as: :text
). NB: The closest existing field name is:trix
but the field name:rich_text
would make more sense in my view (this field is about more than just the front-end editor, and using another name thantrix
also opens the door to other editors such as prosemirror, tiptap, rhino).attachment_key
parameter and without the presence ofhas_many_attached
on the Rails modelhas_rich_text
, with support for rich text editing and embeds of images and other media types; the corresponding Avo resource has a corresponding field defined, allowing to view and edit the rich text, without needing anattachment_key
parameteraction_text_rich_texts
table and other files generated byaction_text:install
, e.g.app/views/active_storage/blobs/_blob.html.erb
has_rich_text
Models and resource files
Additional context
The documentation and demo do make use of a
trix
Avo field (example), but only hooked up into regular:text
ActiveRecord attributes, not Action Text (example).The Avo Demo DB schema does not contain an
action_text_rich_texts
table nor other Action Text config files. It looks likerails action_text:install
was not run.Impact
Urgency
Our current workaround is to suspend our Avo migration and continuing to rely on Administrate, due to some outstanding questions with the Avo Trix field, primarily related to the management of embeds. We also tried to check the situation with the latest main commit but encountered issues. Clearer documentation/demo on the subject would be helpful.
(*) or other equivalent definitions, such as
translates :body, backend: :action_text
in the case of this gem I wrote. In all cases the rich text is available asrecord.body
orrecord.rich_text_body
and returns an object of typeActionText::RichText
.The text was updated successfully, but these errors were encountered: