group(function () { Route::get('styles/form/{element}', 'StylesAPIController@form'); Route::resource('styles', 'StylesAPIController'); }); if (Trans::isMultilingual()) { Route::group( [ 'prefix' => '{trans}', 'where' => ['trans' => Trans::keys('|')], ], function () { // Guard routes for theme-styles Route::prefix('{guard}/theme-style')->group(function () { Route::get('styles/form/{element}', 'StylesAPIController@form'); Route::apiResource('styles', 'StylesAPIController'); }); // Public routes for theme-styles Route::get('theme-style/Styles', 'StylesPublicController@getStyles'); } ); }