前回、前々回とHTML ドラッグ&ドロップ APIを直接用いましたが、今回はSortableJSライブラリを用いてリスト項目の入れ替え操作を行います。 下記の内容で操作対象のリストを生成します。 data-controllerで、項目を操作するStimulusのコントローラと接続する。
A simple and lightweight JavaScript library for reorderable drag-and-drop lists or items. It uses the HTML Drag and Drop API which is sadly not supported by touch ...
Drag and Drop is a user interface feature that allows users to click and hold an object, drag it to a new location, and release it to "drop" it there. In this project, it means users can reorder list ...
Droppables DraggableなDOM要素をドロップできるようにする Sortables マウス操作でDOM要素の順番を入れ替えられるようにする Selectables DOM要素をマウスで選択できるようにする Resizables DOM要素の大きさをマウスで変更できるようにする jQuery UI 1. 5bは 「jQuery UI: Widgets ...
一部の結果でアクセス不可の可能性があるため、非表示になっています。
アクセス不可の結果を表示する