Plugin Outlet needed in User Menu

(cpradio) #1

Continuing the discussion from Should "log out" be prominent in the UI?:

Can a plugin outlet please be added to the user-menu.hbs for adding links to it?

(Jeff Atwood) #2

I think the correct outlet is in the hamburger and probably already exists. I would start there if I was you.

(cpradio) #3

But what if I want to tie other ideas into the user menu. Things that would be for users directly?

(Jeff Atwood) #4

Yeah but that menu is in flux, the outlet for hamburger already exists and probably still works. If you want it done soon (say the next 2 weeks) I’d stick it in hamburger for now.

(cpradio) #5

So can we have an outlet upon completion/finalization of the user menu? I do actually have ideas in my head that would likely benefit from one.

(Jeff Atwood) #6

Not opposed to it any way, just may take some time for that area to settle down. Like I said, if you want it done in the next weeks or month, put it in the existing hamburger extensibility point for now.

(cpradio) #7

Yep. Probably will as switching outlets looks to be trivial once they exist

(Mittineague) #8

Depending on what you have in mind and how soon you want to deploy it.
And with the caveat that you are willing to accept that things will change.
You could begin some work.if you over-ride the current app/assets/javascripts/discourse/templates/components/user-menu.hbs file.

make your own modified copy of the template with your custom plugin-outlet in it
replicate the folder structure inside your plugin folder and register-asset your template

Even though it would be a bit of a headache every time you updated source files, you would be able to do some work on any helper files, CSS, etc.

(cpradio) #9


First and foremost, thank you for adding an outlet under Notifications.

I was wondering if it may be okay to add one above notifications too.

I’m thinking at

The thought behind it, is then I could place links that may be of importance to the user (think, not Log Out/Sign Out – as I agree that should be last), but any other plugin that may be beneficial to the end-user.

From what I can tell, all that is required (based on a prior checkin I found) is adding {{plugin-outlet “unique-name-here”}}, if that is the case, when the time warrants itself do you mind if I submit a PR for that space?