1
0
mirror of https://github.com/flarum/core.git synced 2025-07-17 14:51:19 +02:00

Recompile dist JS

This commit is contained in:
Franz Liedke
2017-02-04 00:07:50 +01:00
parent d7e4ae09b3
commit fdec2fd094
2 changed files with 51 additions and 13 deletions

View File

@@ -17437,7 +17437,7 @@ System.register('flarum/components/AddExtensionModal', ['flarum/components/Modal
}, { }, {
key: 'title', key: 'title',
value: function title() { value: function title() {
return 'Add Extension'; return app.translator.trans('core.admin.add_extension.title');
} }
}, { }, {
key: 'content', key: 'content',

62
js/forum/dist/app.js vendored
View File

@@ -22685,6 +22685,7 @@ System.register('flarum/components/EditUserModal', ['flarum/components/Modal', '
this.username = m.prop(user.username() || ''); this.username = m.prop(user.username() || '');
this.email = m.prop(user.email() || ''); this.email = m.prop(user.email() || '');
this.isActivated = m.prop(user.isActivated() || false);
this.setPassword = m.prop(false); this.setPassword = m.prop(false);
this.password = m.prop(user.password() || ''); this.password = m.prop(user.password() || '');
this.groups = {}; this.groups = {};
@@ -22722,7 +22723,7 @@ System.register('flarum/components/EditUserModal', ['flarum/components/Modal', '
m( m(
'label', 'label',
null, null,
'Username' app.translator.trans('core.forum.edit_user.username_heading')
), ),
m('input', { className: 'FormControl', placeholder: extractText(app.translator.trans('core.forum.edit_user.username_label')), m('input', { className: 'FormControl', placeholder: extractText(app.translator.trans('core.forum.edit_user.username_label')),
bidi: this.username }) bidi: this.username })
@@ -22733,21 +22734,31 @@ System.register('flarum/components/EditUserModal', ['flarum/components/Modal', '
m( m(
'label', 'label',
null, null,
'Email' app.translator.trans('core.forum.edit_user.email_heading')
), ),
m( m(
'div', 'div',
null, null,
m('input', { className: 'FormControl', placeholder: extractText(app.translator.trans('core.forum.edit_user.email_label')), m('input', { className: 'FormControl', placeholder: extractText(app.translator.trans('core.forum.edit_user.email_label')),
bidi: this.email }) bidi: this.email })
) ),
!this.isActivated() ? m(
'div',
null,
Button.component({
className: 'Button Button--block',
children: app.translator.trans('core.forum.edit_user.activate_button'),
loading: this.loading,
onclick: this.activate.bind(this)
})
) : ''
), m( ), m(
'div', 'div',
{ className: 'Form-group' }, { className: 'Form-group' },
m( m(
'label', 'label',
null, null,
'Password' app.translator.trans('core.forum.edit_user.password_heading')
), ),
m( m(
'div', 'div',
@@ -22761,7 +22772,7 @@ System.register('flarum/components/EditUserModal', ['flarum/components/Modal', '
if (e.target.checked) _this3.$('[name=password]').select(); if (e.target.checked) _this3.$('[name=password]').select();
m.redraw.strategy('none'); m.redraw.strategy('none');
} }), } }),
'Set new password' app.translator.trans('core.forum.edit_user.set_password_label')
), ),
this.setPassword() ? m('input', { className: 'FormControl', type: 'password', name: 'password', placeholder: extractText(app.translator.trans('core.forum.edit_user.password_label')), this.setPassword() ? m('input', { className: 'FormControl', type: 'password', name: 'password', placeholder: extractText(app.translator.trans('core.forum.edit_user.password_label')),
bidi: this.password }) : '' bidi: this.password }) : ''
@@ -22773,7 +22784,7 @@ System.register('flarum/components/EditUserModal', ['flarum/components/Modal', '
m( m(
'label', 'label',
null, null,
'Groups' app.translator.trans('core.forum.edit_user.groups_heading')
), ),
m( m(
'div', 'div',
@@ -22808,12 +22819,31 @@ System.register('flarum/components/EditUserModal', ['flarum/components/Modal', '
); );
} }
}, { }, {
key: 'data', key: 'activate',
value: function data() { value: function activate() {
var _this4 = this; var _this4 = this;
this.loading = true;
var data = {
username: this.username(),
isActivated: true
};
this.props.user.save(data, { errorHandler: this.onerror.bind(this) }).then(function () {
_this4.isActivated(true);
_this4.loading = false;
m.redraw();
}).catch(function () {
_this4.loading = false;
m.redraw();
});
}
}, {
key: 'data',
value: function data() {
var _this5 = this;
var groups = Object.keys(this.groups).filter(function (id) { var groups = Object.keys(this.groups).filter(function (id) {
return _this4.groups[id](); return _this5.groups[id]();
}).map(function (id) { }).map(function (id) {
return app.store.getById('groups', id); return app.store.getById('groups', id);
}); });
@@ -22836,14 +22866,14 @@ System.register('flarum/components/EditUserModal', ['flarum/components/Modal', '
}, { }, {
key: 'onsubmit', key: 'onsubmit',
value: function onsubmit(e) { value: function onsubmit(e) {
var _this5 = this; var _this6 = this;
e.preventDefault(); e.preventDefault();
this.loading = true; this.loading = true;
this.props.user.save(this.data(), { errorHandler: this.onerror.bind(this) }).then(this.hide.bind(this)).catch(function () { this.props.user.save(this.data(), { errorHandler: this.onerror.bind(this) }).then(this.hide.bind(this)).catch(function () {
_this5.loading = false; _this6.loading = false;
m.redraw(); m.redraw();
}); });
} }
@@ -23608,7 +23638,11 @@ System.register('flarum/components/IndexPage', ['flarum/extend', 'flarum/compone
icon: 'refresh', icon: 'refresh',
className: 'Button Button--icon', className: 'Button Button--icon',
onclick: function onclick() { onclick: function onclick() {
return app.cache.discussionList.refresh(); app.cache.discussionList.refresh();
if (app.session.user) {
app.store.find('users', app.session.user.id());
m.redraw();
}
} }
})); }));
@@ -29661,6 +29695,10 @@ System.register('flarum/initializers/boot', ['flarum/utils/ScrollListener', 'fla
if (e.ctrlKey || e.metaKey || e.which === 2) return; if (e.ctrlKey || e.metaKey || e.which === 2) return;
e.preventDefault(); e.preventDefault();
app.history.home(); app.history.home();
if (app.session.user) {
app.store.find('users', app.session.user.id());
m.redraw();
}
}); });
// Add a class to the body which indicates that the page has been scrolled // Add a class to the body which indicates that the page has been scrolled