<?php
require_once('vendor/autoload.php');
/* Start to develop here. Best regards https://php-download.com/ */
clarkwinkelmann / flarum-local-extenders example snippets
(new ClarkWinkelmann\LocalExtenders\AlterExtensionListInAdmin())
->extension('flarum-markdown', function ($extension) {
// To Hide the extension completely
$extension->hide();
// To hide select information or buttons
$extension->hideVersion();
$extension->hideSettings();
// To change the look
$extension->title = 'New title';
$extension->description = 'New description';
$extension->iconName = 'fas fa-tree';
$extension->iconColor = '#aa0000';
$extension->iconBackgroundColor = '#aa0000';
$extension->iconImage = __DIR__.'/path/to/image.png'; // SVG/PNG/JPG
// You can also chain calls via the methods
$extension
->title('New title')
->iconName('fas fa-tree');
}),
new ClarkWinkelmann\LocalExtenders\FollowAfterStart(),
new ClarkWinkelmann\LocalExtenders\FollowAfterStart(false),
(new ClarkWinkelmann\LocalExtenders\FrontendWithoutModule('admin'))
->js(__DIR__.'/local/one-file.js')
->js(__DIR__.'/local/one-other-file.js')
->css(__DIR__.'/local/you-can-also-import-css-but-its-identical-to-the-core-extender.less'),
new ClarkWinkelmann\LocalExtenders\HideExtensionVersionInAdmin(),
new ClarkWinkelmann\LocalExtenders\HideFlarumVersionInAdmin(),
new ClarkWinkelmann\LocalExtenders\HideSystemInfoInAdmin(),
(new ClarkWinkelmann\LocalExtenders\OverrideSettings())
->set('mail_driver', 'log')
->set('forum_title', 'Hello'),
(new ClarkWinkelmann\LocalExtenders\OverrideSettings())
->hide('mail_driver'),