-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
improve translations, add admin status widget (#4)
- Loading branch information
Showing
7 changed files
with
79 additions
and
62 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
import app from 'flarum/admin/app'; | ||
import { extend } from 'flarum/common/extend'; | ||
import StatusWidget from 'flarum/admin/components/StatusWidget'; | ||
|
||
export default function addCDNToWidgets() { | ||
extend(StatusWidget.prototype, 'items', function (items) { | ||
items.add('cdn', [<strong>CDN</strong>, <br />, app.data.cdn], 50); | ||
}); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,9 @@ | ||
import app from 'flarum/admin/app'; | ||
import S3SettingsPage from './components/S3SettingsPage'; | ||
import addCDNToWidgets from './extenders/addCDNToWidgets'; | ||
|
||
app.initializers.add('fof/s3-assets', () => { | ||
app.extensionData.for('fof-s3-assets').registerPage(S3SettingsPage); | ||
|
||
addCDNToWidgets(); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters