This repository has been archived on 2023-03-18. You can view files and clone it, but cannot push or open issues or pull requests.
osr-discourse-src/app/assets/javascripts/discourse/controllers/topic_admin_menu_controller.js
Adrian Lang d4ef582f94 Correct caption of 'Make Visible' button
The variable 'visible' is also used for toggling the admin menu visibility,
so it is always true when the visibility toggle is shown. Hence, it's caption
is always 'Make Invisible', even when the topic already is invisible.
2013-07-10 10:16:39 +02:00

22 lines
420 B
JavaScript

/**
This controller supports the admin menu on topics
@class TopicAdminMenuController
@extends Discourse.ObjectController
@namespace Discourse
@module Discourse
**/
Discourse.TopicAdminMenuController = Discourse.ObjectController.extend({
menuVisible: false,
needs: ['modal'],
show: function() {
this.set('menuVisible', true);
},
hide: function() {
this.set('menuVisible', false);
}
});