User tests: Successful: Unsuccessful:
Pull Request for Issue # .
The layout layouts/joomla/content/icons/edit_lock.php is used to display lock icon (when the item is being checked out by different user and could not be edited by the current logged in user)
For some reasons, in the code, we hardcode it to article and contact only, thus prevent other extensions (found this when checking weblinks layout) from using it.
This PR extends the code abit to make layout reusable by other extensions (weblinks in the case) by passing ariaDescribed
to display data and use it if provided. That removes the limit for article and contact only.
Code review only.
Hope it is accepted so that we can re-use this layout in com_weblinks instead of having to implement it.
Status | New | ⇒ | Pending |
Category | ⇒ | Layout |
Not sure if I missed anywhere but I searched through the whole source code and only see it is being used in two files:
https://github.com/joomla/joomla-cms/blob/4.0-dev/administrator/components/com_content/src/Service/HTML/Icon.php#L138
https://github.com/joomla/joomla-cms/blob/4.0-dev/administrator/components/com_contact/src/Service/HTML/Icon.php#L136
Yes because the function is used in the other places
@brianteeman Sorry, I don't look much at the layout, so your comment is not clear to me. From what you see, is it safe to make this change or not?
The question is not can you make the change to the layout and more do you need to?
All other components are using the function eg
Ah, no. This is used for edit icon in the frontend such as https://github.com/joomla/joomla-cms/blob/4.0-dev/components/com_contact/tmpl/category/default_items.php#L179. It is not the same with backend.
ah, i see my confusion and mistake
I have tested this item
LGTM
I have tested this item
Status | Pending | ⇒ | Ready to Commit |
Labels |
Added:
?
|
RTC
Status | Ready to Commit | ⇒ | Fixed in Code Base |
Closed_Date | 0000-00-00 00:00:00 | ⇒ | 2022-01-04 00:41:49 |
Closed_By | ⇒ | wilsonge | |
Labels |
Added:
?
|
Thanks!
There is also the function checkedout which is used in com_menus and probably elsewhere