mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-01-06 22:40:14 -05:00
Move upgrade notification to /settings/about/
Refs #5071 - Move the Upgrade notification from the top of the screen to the About page
This commit is contained in:
parent
18638d378e
commit
272f1eddaf
4 changed files with 28 additions and 5 deletions
12
core/client/app/controllers/settings/about.js
Normal file
12
core/client/app/controllers/settings/about.js
Normal file
|
@ -0,0 +1,12 @@
|
|||
import Ember from 'ember';
|
||||
var SettingsAboutController = Ember.Controller.extend({
|
||||
updateNotificationCount: 0,
|
||||
|
||||
actions: {
|
||||
updateNotificationChange: function (count) {
|
||||
this.set('updateNotificationCount', count);
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
export default SettingsAboutController;
|
|
@ -215,4 +215,13 @@
|
|||
// Hide extra space taken up by update notification
|
||||
.update-available main {
|
||||
bottom: 56px;
|
||||
}
|
||||
|
||||
.notification-upgrade {
|
||||
color: $red;
|
||||
|
||||
a {
|
||||
color: $red;
|
||||
text-decoration: underline;
|
||||
}
|
||||
}
|
|
@ -11,7 +11,10 @@
|
|||
</span>
|
||||
<span class="version blue">v{{model.version}}</span>
|
||||
</h1>
|
||||
<p>A free, open, simple publishing platform</p>
|
||||
{{gh-notifications location="settings-about-upgrade" notify="updateNotificationChange"}}
|
||||
{{#unless updateNotificationCount}}
|
||||
<p>A free, open, simple publishing platform</p>
|
||||
{{/unless}}
|
||||
|
||||
<div class="about-environment-help clearfix">
|
||||
<div class="about-environment">
|
||||
|
|
|
@ -33,12 +33,11 @@ adminControllers = {
|
|||
}
|
||||
|
||||
var notification = {
|
||||
type: 'success',
|
||||
location: 'top',
|
||||
type: 'upgrade',
|
||||
location: 'settings-about-upgrade',
|
||||
dismissible: false,
|
||||
status: 'persistent',
|
||||
message: '<a href="https://ghost.org/download">Ghost ' + updateVersion +
|
||||
'</a> is available! Hot Damn. Please <a href="http://support.ghost.org/how-to-upgrade/" target="_blank">upgrade</a> now'
|
||||
message: 'Ghost ' + updateVersion + ' is available! Hot Damn. <a href="http://support.ghost.org/how-to-upgrade/" target="_blank">Click here</a> to upgrade.'
|
||||
};
|
||||
|
||||
return api.notifications.browse({context: {internal: true}}).then(function (results) {
|
||||
|
|
Loading…
Reference in a new issue