Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using a custom theme #18

Closed
omdesignz opened this issue Apr 7, 2017 · 3 comments
Closed

Using a custom theme #18

omdesignz opened this issue Apr 7, 2017 · 3 comments

Comments

@omdesignz
Copy link

Hi there guys,

I bought a bootstrap theme and have been using it with Laracogs. I recently came across the select element and can't seem to generate a select element that uses the theme within blade.

This is because when I use @foreach directive I can't seem to be able to create a roles selection. I can only achieve it using the default installation and normal bootstrap.

Regards

@mlantz
Copy link
Member

mlantz commented Apr 30, 2017

Are you trying to make the input individually or with the form maker? Here are two examples:

FormMaker::fromTable('users', ['roles' => ['type' => 'select', 'class' => 'something-different', 'options' => $options]])

Or

InputMaker::create('roles', ['type' => 'select', 'options' => $options], null, 'something-different')

@mlantz
Copy link
Member

mlantz commented May 18, 2017

I've improved some of the customizability of the FormMaker parts - in the config you'll see:

'form-class' => 'form-control',
'group-class' => 'form-group',
'error-class' => 'has-error',
'label-class' => 'control-label',

which can be used by default - then for custom inputs you can pass whatever custom classes are needed :)

@mlantz mlantz closed this as completed May 18, 2017
@omdesignz
Copy link
Author

Thank You so much! Laracogs is awesome.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants