Skip to content

Commit

Permalink
Apply PSR2 trailing_comma_in_multiline_array php cs fixer
Browse files Browse the repository at this point in the history
  • Loading branch information
shakaran committed Sep 17, 2017
1 parent 40449d3 commit d4b022b
Show file tree
Hide file tree
Showing 18 changed files with 49 additions and 49 deletions.
2 changes: 1 addition & 1 deletion Command/BuildAssetsCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ protected function partition($resolved)
'styles' => [],
'images' => [],
'files' => [],
'fonts' => []
'fonts' => [],
];

foreach ($resolved as $group => $files) {
Expand Down
8 changes: 4 additions & 4 deletions Command/CompactVendorCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ protected function getThemePath($type, InputInterface $input, $kernel) {
$themedir = strtr('@AvanzuAdminThemeBundle/Resources/vendor/bootflat/{type}',
[
'{theme}' => $theme,
'{type}' => $type
'{type}' => $type,
]);
$vendors = $kernel->locateResource($themedir);

Expand Down Expand Up @@ -116,7 +116,7 @@ protected function compressThemeCss(InputInterface $input, OutputInterface $outp
'font-awesome.css',
'bootflat.css',
'bootflat-extensions.css',
'bootflat-square.css'
'bootflat-square.css',
];

$process = new Process(sprintf('/usr/local/share/npm/bin/uglifycss %s > %s', implode(' ', $files), $script));
Expand Down Expand Up @@ -144,7 +144,7 @@ protected function compressThemeJs(InputInterface $input, OutputInterface $outpu

$files = [
'bootstrap.js',
'jquery.icheck.js'
'jquery.icheck.js',
];

$process = new Process(sprintf('/usr/local/bin/uglifyjs %s -c -m -o %s', implode(' ', $files), $script));
Expand Down Expand Up @@ -186,7 +186,7 @@ protected function compressVendorJs(OutputInterface $output) {
, 'momentjs/lang/de.js'
, 'spinjs/spin.js'
, 'spinjs/jquery.spin.js'
, 'holderjs/holder.js'
, 'holderjs/holder.js',
];

$process = new Process(sprintf('/usr/local/bin/uglifyjs %s -c -m -o %s', implode(' ', $files), $script));
Expand Down
2 changes: 1 addition & 1 deletion Command/InitializeCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ protected function getDirectorySetup(ContainerInterface $dic, InputInterface $in
'vendors' => $vendors,
'theme' => $theme,
'self' => $self,
'public' => $input->getOption('web-dir')
'public' => $input->getOption('web-dir'),
];
}

Expand Down
2 changes: 1 addition & 1 deletion Composer/ScriptHandler.php
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ class ScriptHandler
*/
private static $options = [
'symfony-app-dir' => 'app',
'symfony-web-dir' => 'web'
'symfony-web-dir' => 'web',
];

protected static function getOptions(CommandEvent $event)
Expand Down
2 changes: 1 addition & 1 deletion Controller/BreadcrumbController.php
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ public function breadcrumbAction(Request $request, $title = '') {

return $this->render('AvanzuAdminThemeBundle:Breadcrumb:breadcrumb.html.twig', [
'active' => $list,
'title' => $title
'title' => $title,
]);
}

Expand Down
2 changes: 1 addition & 1 deletion Controller/DefaultController.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public function formAction() {
$form = $this->createForm(FormDemoModelType::class);

return $this->render('AvanzuAdminThemeBundle:Default:form.html.twig', [
'form' => $form->createView()
'form' => $form->createView(),
]);
}

Expand Down
8 changes: 4 additions & 4 deletions Controller/NavbarController.php
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ public function notificationsAction($max = 5)
'AvanzuAdminThemeBundle:Navbar:notifications.html.twig',
[
'notifications' => $listEvent->getNotifications(),
'total' => $listEvent->getTotal()
'total' => $listEvent->getTotal(),
]
);
}
Expand All @@ -59,7 +59,7 @@ public function messagesAction($max = 5)
'AvanzuAdminThemeBundle:Navbar:messages.html.twig',
[
'messages' => $listEvent->getMessages(),
'total' => $listEvent->getTotal()
'total' => $listEvent->getTotal(),
]
);
}
Expand All @@ -80,7 +80,7 @@ public function tasksAction($max = 5)
'AvanzuAdminThemeBundle:Navbar:tasks.html.twig',
[
'tasks' => $listEvent->getTasks(),
'total' => $listEvent->getTotal()
'total' => $listEvent->getTotal(),
]
);
}
Expand All @@ -98,7 +98,7 @@ public function userAction()
return $this->render(
'AvanzuAdminThemeBundle:Navbar:user.html.twig',
[
'user' => $userEvent->getUser()
'user' => $userEvent->getUser(),
]
);
}
Expand Down
4 changes: 2 additions & 2 deletions Controller/SidebarController.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ public function userPanelAction()
return $this->render(
'AvanzuAdminThemeBundle:Sidebar:user-panel.html.twig',
[
'user' => $userEvent->getUser()
'user' => $userEvent->getUser(),
]
);
}
Expand Down Expand Up @@ -54,7 +54,7 @@ public function menuAction(Request $request)
return $this->render(
'AvanzuAdminThemeBundle:Sidebar:menu.html.twig',
[
'menu' => $event->getItems()
'menu' => $event->getItems(),
]
);
}
Expand Down
10 changes: 5 additions & 5 deletions DependencyInjection/AvanzuAdminThemeExtension.php
Original file line number Diff line number Diff line change
Expand Up @@ -43,11 +43,11 @@ public function prepend(ContainerBuilder $container)
'twig',
[
'form_theme' => [
'AvanzuAdminThemeBundle:layout:form-theme.html.twig'
'AvanzuAdminThemeBundle:layout:form-theme.html.twig',
],
'globals' => [
'admin_theme' => '@avanzu_admin_theme.theme_manager'
]
'admin_theme' => '@avanzu_admin_theme.theme_manager',
],
]
);
}
Expand All @@ -63,8 +63,8 @@ public function prepend(ContainerBuilder $container)
[
'assets' => $assets,
'bundles' => [
'AvanzuAdminThemeBundle'
]
'AvanzuAdminThemeBundle',
],
]
);
}
Expand Down
2 changes: 1 addition & 1 deletion DependencyInjection/Compiler/TwigPass.php
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ public function process(ContainerBuilder $container)

$twigDefinition->addMethodCall('addGlobal', [
'avanzu_admin_context',
new Reference('avanzu_admin_theme.context_helper')
new Reference('avanzu_admin_theme.context_helper'),
]
);
}
Expand Down
2 changes: 1 addition & 1 deletion EventListener/NavbarTaskListDemoListener.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ protected function getTasks()
return [
new TaskModel('make stuff', 30, TaskModel::COLOR_GREEN),
new TaskModel('make more stuff', 60),
new TaskModel('some more tasks to do', 10, TaskModel::COLOR_RED)
new TaskModel('some more tasks to do', 10, TaskModel::COLOR_RED),
];
}
}
2 changes: 1 addition & 1 deletion EventListener/SidebarSetupMenuDemoListener.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ protected function getMenu(Request $request)
$dash = new MenuItemModel('dashboard', 'Dashboard', 'avanzu_admin_dash_demo', $earg, 'fa fa-dashboard'),
$form = new MenuItemModel('forms', 'Forms', 'avanzu_admin_form_demo', $earg, 'fa fa-edit'),
$widgets = new MenuItemModel('widgets', 'Widgets', 'avanzu_admin_demo', $earg, 'fa fa-th', 'new'),
$ui = new MenuItemModel('ui-elements', 'UI Elements', '', $earg, 'fa fa-laptop')
$ui = new MenuItemModel('ui-elements', 'UI Elements', '', $earg, 'fa fa-laptop'),
];

$ui->addChild(new MenuItemModel('ui-elements-general', 'General', 'avanzu_admin_ui_gen_demo', $earg))
Expand Down
6 changes: 3 additions & 3 deletions Helper/ContextHelper.php
Original file line number Diff line number Diff line change
Expand Up @@ -123,11 +123,11 @@ protected function configureDefaults(OptionsResolver $resolver)
],
'button' => [
'type' => 'primary',
'size' => false
'size' => false,
],
'knp_menu' => [
'enable' => false
]
'enable' => false,
],
]);
}
}
4 changes: 2 additions & 2 deletions Menu/MenuBuilder.php
Original file line number Diff line number Diff line change
Expand Up @@ -49,13 +49,13 @@ public function __construct(
public function createMainMenu(array $options)
{
$menu = $this->factory->createItem('root', [
'childrenAttributes' => ['class' => 'sidebar-menu']
'childrenAttributes' => ['class' => 'sidebar-menu'],
]);

$childOptions = [
'attributes' => ['class' => 'treeview'],
'childrenAttributes' => ['class' => 'treeview-menu'],
'labelAttributes' => []
'labelAttributes' => [],
];

$this->eventDispatcher->dispatch(
Expand Down
36 changes: 18 additions & 18 deletions Resources/config/assets.php
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ function () {
'modernizr_js' => [
'inputs' => [
$jsAssets . 'public/vendor/modernizr/modernizr.js',
]
],
],
'common_js' => [
'inputs' => [
Expand Down Expand Up @@ -44,7 +44,7 @@ function () {
$lteJSBase . 'plugins/datatables/dataTables.bootstrap.js',
$lteJSBase . 'plugins/slimScroll/jquery.slimscroll.js',
$jsAssets . 'public/js/adminLTE.js',
]
],
],
'admin_lte_css' => [
'inputs' => [
Expand All @@ -55,17 +55,17 @@ function () {
$cssAssets . 'vendor/ionicons/css/ionicons.min.css',
$lteCssBase . 'dist/css/AdminLTE.css',
$lteCssBase . 'dist/css/skins/_all-skins.css',
]
],
],
'admin_lte_forms_js' => [
'inputs' => [
$lteJSBase . 'plugins/colorpicker/bootstrap-colorpicker.js',
$lteJSBase . 'plugins/daterangepicker/daterangepicker.js',
$lteJSBase . 'plugins/timepicker/bootstrap-timepicker.js',
$lteJSBase . 'plugins/input-mask/jquery.inputmask.js',
$lteJSBase . 'plugins/iCheck/icheck.js'
$lteJSBase . 'plugins/iCheck/icheck.js',
// $lteJs.'plugins/input-mask/*',
]
],
],
'admin_lte_forms_css' => [
'inputs' => [
Expand All @@ -74,47 +74,47 @@ function () {
$lteCssBase . 'plugins/timepicker/bootstrap-timepicker.css',
$lteCssBase . 'plugins/iCheck/all.css',
$lteCssBase . 'plugins/iCheck/square/_all.css',
]
],
],
'admin_lte_wysiwyg' => [
'inputs' => [
$lteJSBase . 'plugins/bootstrap-wysihtml5/bootstrap3-wysihtml5.all.min.js',
]
],
],
'admin_lte_wysiwyg_css' => [
'inputs' => [
$lteCssBase . 'plugins/bootstrap-wysihtml5/bootstrap3-wysihtml5.min.css',
]
],
],
'admin_lte_morris' => [
'inputs' => [
$lteJSBase . 'plugins/morris/morris.js',
]
],
],
'admin_lte_morris_css' => [
'inputs' => [
$lteCssBase . 'plugins/morris/morris.css',
]
],
],
'admin_lte_flot' => [
'inputs' => [
$lteJSBase . 'plugins/flot/*',
]
],
],
'admin_lte_calendar' => [
'inputs' => [
$jsAssets . 'public/vendor/fullcalendar/dist/fullcalendar.min.js',
]
],
],
'admin_lte_calendar_css' => [
'inputs' => [
$cssAssets . 'vendor/fullcalendar/dist/fullcalendar.css',
]
],
],
'avatar_img' => [
'inputs' => [
'@AvanzuAdminThemeBundle/Resources/public/img/avatar.png'
]
'@AvanzuAdminThemeBundle/Resources/public/img/avatar.png',
],
],
'admin_lte_all' => [
'inputs' => [
Expand All @@ -124,7 +124,7 @@ function () {
'@admin_lte_morris',
'@admin_lte_calendar',
'@admin_lte_js',
]
],
],
'admin_lte_all_css' => [
'inputs' => [
Expand All @@ -133,8 +133,8 @@ function () {
'@admin_lte_wysiwyg_css',
'@admin_lte_calendar_css',
'@admin_lte_morris_css',
]
]
],
],
];
}
);
2 changes: 1 addition & 1 deletion Theme/ThemeManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ public function registerScript($id, $src, $deps = [], $location = "bottom")
$this->javascripts[$id] = [
'src' => $src,
'deps' => $deps,
'location' => $location
'location' => $location,
];
}
}
Expand Down
2 changes: 1 addition & 1 deletion Twig/AvanzuAdminExtension.php
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ public function getFilters()
{
return [
new \Twig_SimpleFilter('body_class', [$this, 'bodyClass']),
new \Twig_SimpleFilter('route_alias', [$this->aliasRouter, 'getRouteByAlias'])
new \Twig_SimpleFilter('route_alias', [$this->aliasRouter, 'getRouteByAlias']),
];
}

Expand Down
2 changes: 1 addition & 1 deletion Twig/WidgetExtension.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ public function getFunctions()
[$this, 'renderWidget'],
[
'is_safe' => ['html'],
'needs_environment' => true
'needs_environment' => true,
]),
];
}
Expand Down

0 comments on commit d4b022b

Please sign in to comment.