Skip to content

Commit

Permalink
chore: update ready for 1.8.6 (#203)
Browse files Browse the repository at this point in the history
* chore: update ready for 1.8.6

* chore: set min core
  • Loading branch information
imorland authored Oct 9, 2024
1 parent 69ef9f5 commit f716ad2
Show file tree
Hide file tree
Showing 7 changed files with 2,309 additions and 14 deletions.
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
],
"require": {
"php": "^8.0",
"flarum/core": "^1.7.0"
"flarum/core": "^1.8.6"
},
"extra": {
"flarum-extension": {
Expand Down
16 changes: 6 additions & 10 deletions js/src/admin/components/ByobuSettingsPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,21 +6,17 @@ import icon from 'flarum/common/helpers/icon';
import type Mithril from 'mithril';

export default class ByobuSetingsPage extends ExtensionPage {
oninit(vnode: Mithril.Vnode<any, any>) {
super.oninit(vnode);

this.badgeDefault = 'fas fa-map';
this.postActionDefault = 'far fa-map';
}
badgeDefault: string = 'fas fa-map';
postActionDefault: string = 'far fa-map';

content() {
const helpText = flarum.extensions['flarum-tags']
? app.translator.trans('flarum-tags.admin.edit_tag.icon_text', {
a: <a href="https://fontawesome.com/icons?m=free" tabindex="-1" />,
a: <a href={app.refs.fontawesome} tabindex="-1" />,
})
: '';

return [
return (
<div className="ByobuSettingsPage">
<div className="container">
<div className="Form">
Expand Down Expand Up @@ -69,7 +65,7 @@ export default class ByobuSetingsPage extends ExtensionPage {
<div className="Form-group">{this.submitButton()}</div>
</div>
</div>
</div>,
];
</div>
);
}
}
5 changes: 5 additions & 0 deletions js/src/forum/events/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import MadePublic from './MadePublic';
import RecipientLeft from './RecipientLeft';
import RecipientsModified from './RecipientsModified';

export const events = [MadePublic, RecipientLeft, RecipientsModified];
13 changes: 10 additions & 3 deletions js/src/forum/extend.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,14 @@ import RecipientsModified from './events/RecipientsModified';
import PrivateDiscussionsUserPage from './pages/PrivateDiscussionsUserPage';

export default [
new Extend.PostTypes().add('recipientsModified', RecipientsModified).add('recipientLeft', RecipientLeft).add('madePublic', MadePublic),
new Extend.PostTypes() //
.add('recipientsModified', RecipientsModified)
.add('recipientLeft', RecipientLeft)
.add('madePublic', MadePublic),

new Extend.Routes().add('byobuUserPrivate', '/u/:username/private', PrivateDiscussionsUserPage).add('byobuPrivate', '/private', IndexPage),
new Extend.Routes() //
.add('byobuUserPrivate', '/u/:username/private', PrivateDiscussionsUserPage)
.add('byobuPrivate', '/private', IndexPage),

new Extend.Model(Discussion)
.hasMany<User>('recipientUsers')
Expand All @@ -24,5 +29,7 @@ export default [
.attribute<boolean>('canMakePublic')
.attribute<boolean>('isPrivateDiscussion'),

new Extend.Model(User).attribute<boolean>('blocksPd').attribute<number>('unreadPrivateMessagesCount'),
new Extend.Model(User) //
.attribute<boolean>('blocksPd')
.attribute<number>('unreadPrivateMessagesCount'),
];
3 changes: 3 additions & 0 deletions js/src/forum/helpers/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import canStartPrivateDiscussion from './canStartPrivateDiscussion';

export const helpers = [canStartPrivateDiscussion];
2 changes: 2 additions & 0 deletions js/src/forum/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ import notifications from './notifications';

export * from './modals';
export * from './pages/discussions';
export * from './events';
export * from './helpers';

export { default as extend } from './extend';

Expand Down
2,282 changes: 2,282 additions & 0 deletions js/yarn.lock

Large diffs are not rendered by default.

0 comments on commit f716ad2

Please sign in to comment.