Commit c68a6e01 authored by Roberto Guido's avatar Roberto Guido
Browse files

added "asplaintext" attribute for input fields

parent aacc0003
......@@ -14,10 +14,12 @@ class Commons
$stack = app()->make('LarastrapStack');
if ($params['readonly'] || $params['disabled']) {
$params['classes'][] = 'form-control-plaintext';
if ($params['asplaintext']) {
$params['classes'][] = 'form-control-plaintext';
if (($key = array_search('form-control', $params['classes'])) !== false) {
unset($params['classes'][$key]);
if (($key = array_search('form-control', $params['classes'])) !== false) {
unset($params['classes'][$key]);
}
}
}
......
......@@ -38,6 +38,10 @@ abstract class Input extends Element
'type' => 'boolean',
'default' => false,
],
'asplaintext' => (object) [
'type' => 'boolean',
'default' => true,
],
'placeholder' => (object) [
'type' => 'string',
'default' => null,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment