Set class for DetailView::widget()


I have in my backend a table but not all the data is fitting in, I need to make the table scrollable from left to right, I tried adding ‘class’ => ‘overflow: auto’, to the widget but it does not work.

Any idea how to make the widget tables scrollable please?

<?= DetailView::widget([

    'model' =&gt; &#036;model,

    'class' =&gt; 'overflow: auto',

    'attributes' =&gt; [



















]) ?&gt;


you can do this.

‘options’ => [‘class’ => ‘detail1-view’],

<div class="detail-disposal">
<?= DetailView::widget([
    'model' => $model,
    'options' => ['class' => 'detail1-view'],
    'attributes' => [
        // cria um array com a fotografia, em que carrega a path no campo fieldName da bd
        'format' => ['image',['width'=>'230','height'=>'200']],
]) ?>

REF: css - Yii2 - DetailView widget float left - Stack Overflow