Problem/Motivation
I would like to introduce a setting for the field formatter, that hides the operations links for each table row (view, edit, etc.). Right now this is decided by permission (if user has permission to edit the paragraph in the row, edit button will appear). This is perfectly valid. But there maybe use cases, where you want to remove those operation links from the frontend (formatter view), i. e. to unclutter the frontend UI a bit. A setting for the field formatter could hide the operations links in that case.
Steps to reproduce
Use the paragraphs_table field formatter and see that there are operations links (view, edit, etc.) near every line of the table. Imagine that you want to hide these operations links.
Proposed resolution
Introduce a setting on the field formatter, that hides/disables the operations links.
Remaining tasks
Provide a patch
User interface changes
- Additional setting for field formatter
- Hide the operations links in frontend
API changes
additonal formatter setting
Data model changes
none
Remark:
the config schema should be addresse too. But since there is a bug with the config schema (#3198546: Config schema for formatter and widget missing/incomplete), this would only make sense after that bug is fixed. I will happily provide a revised patch after #3198546: Config schema for formatter and widget missing/incomplete is fixed.
| Comment | File | Size | Author |
|---|---|---|---|
| #6 | hide_line_operations_patch-3198557-006.patch | 544 bytes | stefan.korn |
| #2 | hide_line_operations_patch-3198557-002.patch | 2.38 KB | stefan.korn |
Comments
Comment #2
stefan.kornComment #3
stefan.kornComment #5
lazzyvn commentedadd this feature in version 8.x-1.4
Comment #6
stefan.kornThanks for adding this feature.
Now that #3198546: Config schema for formatter and widget missing/incomplete was fixed and this is added to 8.x-1.4 there should be one more small fix on the config schema, see this patch
Comment #8
lazzyvn commentedadded in version 1.5