mirror of
https://github.com/e107inc/e107.git
synced 2025-08-01 20:30:39 +02:00
Selectize styling
This commit is contained in:
@@ -732,27 +732,28 @@ class e_form
|
|||||||
}
|
}
|
||||||
*/
|
*/
|
||||||
|
|
||||||
if(vartrue($options['selectize']))
|
if(!empty($options['selectize']))
|
||||||
{
|
{
|
||||||
e107::js('core', 'selectize/js/selectize.min.js', 'jquery');
|
e107::js('core', 'selectize/js/selectize.min.js', 'jquery');
|
||||||
e107::css('core', 'selectize/css/selectize.css', 'jquery');
|
e107::css('core', 'selectize/css/selectize.css', 'jquery');
|
||||||
|
|
||||||
if(deftrue('BOOTSTRAP') === 3)
|
if(deftrue('BOOTSTRAP') === 3)
|
||||||
{
|
{
|
||||||
e107::css('core', 'selectize/css/selectize.bootstrap3.css', 'jquery');
|
// e107::css('core', 'selectize/css/selectize.bootstrap3.css', 'jquery');
|
||||||
}
|
}
|
||||||
elseif(deftrue('BOOTSTRAP'))
|
elseif(deftrue('BOOTSTRAP'))
|
||||||
{
|
{
|
||||||
e107::css('core', 'selectize/css/selectize.bootstrap2.css', 'jquery');
|
// e107::css('core', 'selectize/css/selectize.bootstrap2.css', 'jquery');
|
||||||
}
|
}
|
||||||
|
|
||||||
// Load selectize behavior.
|
// Load selectize behavior.
|
||||||
e107::js('core', 'selectize/js/selectize.init.js', 'jquery');
|
e107::js('core', 'selectize/js/selectize.init.js', 'jquery');
|
||||||
|
|
||||||
$options['selectize']['wrapperClass'] = 'selectize-control';
|
$options['selectize']['wrapperClass'] = 'selectize-control';
|
||||||
$options['selectize']['inputClass'] = 'selectize-input';
|
$options['selectize']['inputClass'] = 'selectize-input form-control';
|
||||||
$options['selectize']['dropdownClass'] = 'selectize-dropdown';
|
$options['selectize']['dropdownClass'] = 'selectize-dropdown';
|
||||||
$options['selectize']['dropdownContentClass'] = 'selectize-dropdown-content';
|
$options['selectize']['dropdownContentClass'] = 'selectize-dropdown-content';
|
||||||
|
$options['selectize']['copyClassesToDropdown'] = true;
|
||||||
|
|
||||||
$jsSettings = array(
|
$jsSettings = array(
|
||||||
'id' => vartrue($options['id'], $this->name2id($name)),
|
'id' => vartrue($options['id'], $this->name2id($name)),
|
||||||
@@ -765,6 +766,8 @@ class e_form
|
|||||||
|
|
||||||
// Merge field settings with other selectize field settings.
|
// Merge field settings with other selectize field settings.
|
||||||
e107::js('settings', array('selectize' => array($jsSettings)));
|
e107::js('settings', array('selectize' => array($jsSettings)));
|
||||||
|
|
||||||
|
$options['class'] = '';
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO: remove typeahead.
|
// TODO: remove typeahead.
|
||||||
|
@@ -1191,7 +1191,11 @@ li.rssRow > div {
|
|||||||
.admin-left-panel.toggled { display: none }
|
.admin-left-panel.toggled { display: none }
|
||||||
|
|
||||||
|
|
||||||
/* ######## selectize.js ######## *
|
/* ######## selectize.js ######## */
|
||||||
|
|
||||||
|
.selectize-input input { color: inherit }
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
.selectize-control.single .selectize-input,
|
.selectize-control.single .selectize-input,
|
||||||
.selectize-control.single .selectize-input.input-active,
|
.selectize-control.single .selectize-input.input-active,
|
||||||
|
@@ -102,6 +102,7 @@ var e107 = e107 || {'settings': {}, 'behaviors': {}};
|
|||||||
inputClass: item.options.inputClass || 'selectize-input',
|
inputClass: item.options.inputClass || 'selectize-input',
|
||||||
dropdownClass: item.options.dropdownClass || 'selectize-dropdown',
|
dropdownClass: item.options.dropdownClass || 'selectize-dropdown',
|
||||||
dropdownContentClass: item.options.dropdownContentClass || 'selectize-dropdown-content',
|
dropdownContentClass: item.options.dropdownContentClass || 'selectize-dropdown-content',
|
||||||
|
copyClassesToDropdown: item.options.copyClassesToDropdown ? item.options.copyClassesToDropdown : null,
|
||||||
|
|
||||||
// Callbacks.
|
// Callbacks.
|
||||||
load: function (query, callback) {
|
load: function (query, callback) {
|
||||||
|
Reference in New Issue
Block a user