Multiple Choice and Checkboxes no longer offer "Inline", but the default views still use it

オープン
#16,064 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

@duncanmcclean がすでに取り組んでいます。

2026年11月26日 から。

  • #16065 @duncanmcclean による — オープン

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
35/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
停滞
技術スタック
laravel, php
領域
backend

調査の方向性

Start with the field configuration for Multiple Choice and Checkboxes, then compare it with the default views extend/forms/antlers/fields/multi_choice.antlers.html, checkboxes.antlers.html, and yes_no.antlers.html. Decide whether to restore the Inline option in the builder or remove its use from the views and document the change. A pull request is already open for this issue, so check its status before starting.

索引モデルが issue の本文から書いたものです。

説明

forms
Bug description

In Forms 1, the Radio and Checkboxes fields in a form had an Inline toggle. In Forms 2, the form builder offers only Options for Multiple Choice and Checkboxes, so the setting can no longer be seen or changed.

The setting still has an effect, though:

  • MultiChoice::toFieldArray() passes any extra config through, so inline: true in a form's YAML still reaches the template.
  • The default views still check it with {{ unless inline }}<br>{{ /unless }}: extend/forms/antlers/fields/multi_choice.antlers.html, checkboxes.antlers.html and yes_no.antlers.html. Yes / No never offered the option at all.

As a result:

  • Fields converted from Forms 1 with Inline turned on keep rendering inline, but editors can't see why or turn it off.
  • A new field can't be made inline without editing the YAML by hand.

I couldn't find this mentioned in the Forms 2 PR (#15039) or the upgrade notes, so it looks unintended.

Expected: either the form builder offers Inline for Multiple Choice and Checkboxes (and Yes / No), or the default views stop checking inline and the upgrade notes mention the removal.

How to reproduce
  1. Add a Multiple Choice field with inline: true to a form's YAML. A Forms 1 form with an inline Radio field, re-saved on 6.44, ends up the same way.
-
  handle: delivery
  field:
    type: multi_choice
    display: Delivery
    inline: true
    options:
      -
        key: fast
        value: Fast
      -
        key: slow
        value: Slow
  1. Open the field in the form builder. There's no Inline option, but the YAML still has inline: true.
  2. Render the form with the default field views. The options render inline (no <br> between them).
  3. Add a new Multiple Choice field. There's no way to make it inline.
Logs

Environment
Statamic 6.44.0 Pro
Laravel 12.69.3
PHP 8.4.28
Installation

Fresh statamic/statamic site via CLI

Additional details

As a workaround, the option can be added back from a service provider:

use Statamic\Forms\Fieldtypes\Checkboxes;
use Statamic\Forms\Fieldtypes\MultiChoice;

MultiChoice::appendConfigField('inline', ['type' => 'toggle', 'display' => __('Inline')]);
Checkboxes::appendConfigField('inline', ['type' => 'toggle', 'display' => __('Inline')]);
主要言語
PHP
スター
4.9k
フォーク
647
平均マージ
1日 45分
マージ済み PR(30日)
221

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

statamic/cms のほかの issue

statamic/cms の issue をすべて見る

似ている issue

PHP の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。