2022-06-17 17:51:59 +02:00
|
|
|
<?php
|
|
|
|
|
|
|
|
return [
|
2022-08-31 15:02:43 +02:00
|
|
|
'mixins' => ['options'],
|
|
|
|
'props' => [
|
|
|
|
/**
|
|
|
|
* Unset inherited props
|
|
|
|
*/
|
|
|
|
'after' => null,
|
|
|
|
'before' => null,
|
|
|
|
'icon' => null,
|
|
|
|
'placeholder' => null,
|
2022-06-17 17:51:59 +02:00
|
|
|
|
2022-08-31 15:02:43 +02:00
|
|
|
/**
|
|
|
|
* Arranges the radio buttons in the given number of columns
|
|
|
|
*/
|
|
|
|
'columns' => function (int $columns = 1) {
|
|
|
|
return $columns;
|
|
|
|
},
|
|
|
|
],
|
|
|
|
'computed' => [
|
|
|
|
'default' => function () {
|
2025-07-11 14:41:34 +02:00
|
|
|
$default = $this->model()->toString($this->default);
|
|
|
|
return $this->sanitizeOption($default);
|
2022-08-31 15:02:43 +02:00
|
|
|
},
|
|
|
|
'value' => function () {
|
|
|
|
return $this->sanitizeOption($this->value) ?? '';
|
|
|
|
}
|
|
|
|
]
|
2022-06-17 17:51:59 +02:00
|
|
|
];
|