This patch will add a Media browser link into the Content menu and adds configuration to hide links and tabs to the Files and Media pages.
Routes are not removed, just the links and tabs are hidden visually which allows hiding items the users don't need to see anymore.

I think we should add it before full 1.0 release.

Comments

rang501 created an issue. See original summary.

ytsurk’s picture

Status: Needs review » Reviewed & tested by the community
StatusFileSize
new4.95 KB
new5.13 KB

Great work, once again @rang501!
This shall definitely go in asap.

The patch plays nicely, and the config options do work. It's good to exclude admin_toolbar menu links!

There is stuff inside this patch from the combined_upload, which I removed, also I changed the setting description text.

ytsurk’s picture

Title: Add media browser link to menu, allow hiding core media links » Add media browser link to menu, allow hiding core media_library tabs and admin_toolbar_tools links
ytsurk’s picture

Maybe the settings could be changed to

  • Hide Media tab
  • Hide File tab
  • Hide admin_toolbar_tools media links (only if module is enabled)
ytsurk’s picture

Status: Reviewed & tested by the community » Needs review
StatusFileSize
new5.82 KB
new8.74 KB

So here we go ..

ytsurk’s picture

StatusFileSize
new5.94 KB
new9.45 KB

Missed the schema ..

rang501’s picture

Status: Needs review » Reviewed & tested by the community

Seems fine. There was a small typo in the schema file, I'll fix it when committing these changes.

  • rang501 committed e099afe on 8.x-1.x
    Issue #3120400 by ytsurk, rang501: Add media browser link to menu, allow...
rang501’s picture

Status: Reviewed & tested by the community » Fixed
ytsurk’s picture

I was thinking of disabling the menu entries and removing the hook (just to reduce hooks;)). What do you mean? Shall we make a followup?

rang501’s picture

Yes, followup can be done if you think it would be better, but I think that could be a lower priority because it is more like a code polish :)

ytsurk’s picture

Let's leave that .. they will be cached ;)

ytsurk’s picture

Hmm - was thinking of removing some of this code again. Files and Media tab can be hidden via permissions ...

And then the admin_toolbar links should consequently also be hidden by role..

But also, this feature doesn't need to be used .. Maybe we should enhance the description of the setting.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.