Skip to content
This repository has been archived by the owner on May 5, 2020. It is now read-only.

Fix for Flarum Beta 10 + russian language #6

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
js/*/node_modules
js/node_modules
vendor/
composer.lock
14 changes: 0 additions & 14 deletions bootstrap.php

This file was deleted.

9 changes: 7 additions & 2 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,20 +16,25 @@
"name": "Clark Winkelmann",
"email": "[email protected]",
"homepage": "https://clarkwinkelmann.com/"
},
{
"name": "Evgenij Spitsyn",
"email": "[email protected]",
"homepage": "https://spitsyn.net/"
}
],
"support": {
"issues": "https://github.com/flagrow/telegram/issues",
"source": "https://github.com/flagrow/telegram"
},
"require": {
"flarum/core": "^0.1.0-beta.7"
"flarum/core": "^0.1.0-beta.10"
},
"extra": {
"flarum-extension": {
"title": "Flagrow Telegram",
"icon": {
"name": "telegram",
"name": "fab fa-telegram-plane",
"backgroundColor": "#f4f4f4",
"color": "#5f4bb6"
}
Expand Down
32 changes: 32 additions & 0 deletions extend.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
<?php

namespace Flagrow\Telegram;
use Flagrow\Telegram\Controllers\TelegramAuthController;
use Flagrow\Telegram\Controllers\TelegramBotController;
use Flarum\Extend;

use Illuminate\Contracts\Events\Dispatcher;
use Illuminate\Contracts\View\Factory;
use Flarum\Notification\Event\Sending;
use Flarum\Api\Event\Serializing;

return [
(new Extend\Frontend('forum'))
->js(__DIR__.'/js/dist/forum.js')
->css(__DIR__.'/resources/less/forum.less'),
(new Extend\Locales(__DIR__ . '/resources/locale')),
function (Dispatcher $events, Factory $view) {
$events->listen(Serializing::class, Listeners\AddUserAttributes::class);
$events->subscribe(Listeners\SendTelegramNotifications::class);
$events->subscribe(Listeners\EnableTelegramNotifications::class);
$events->subscribe(Listeners\InjectSettings::class);

},
(new Extend\Frontend('admin'))
->js(__DIR__.'/js/dist/admin.js'),

(new Extend\Routes('forum'))
->get('/auth/telegram', 'auth.telegram', TelegramAuthController::class),
];


1 change: 1 addition & 0 deletions js/admin.js
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export * from './src/admin';
7 changes: 0 additions & 7 deletions js/admin/Gulpfile.js

This file was deleted.

78 changes: 0 additions & 78 deletions js/admin/dist/extension.js

This file was deleted.

7 changes: 0 additions & 7 deletions js/admin/package.json

This file was deleted.

38 changes: 0 additions & 38 deletions js/admin/src/components/TelegramSettingsModal.js

This file was deleted.

7 changes: 0 additions & 7 deletions js/admin/src/main.js

This file was deleted.

Loading