```
import flet as ft
from flet import Icons
from flet.core.colors import Colors


class RemovableTextInput(ft.Card):
    def __init__(self, on_delete=None, on_duplicate=None, on_reorder=None, index=0, **kwargs):
        super().__init__(expand=True)
        self.on_delete = on_delete
        self.on_duplicate = on_duplicate
        self.on_reorder = on_reorder
        self.index = index

        # ドラッグハンドル
        self.drag_handle = ft.Draggable(
            group="fields",
            content=ft.Container(
                content=ft.Icon(Icons.DRAG_HANDLE, size=24),
                alignment=ft.alignment.center,
                width=40,
                height=40,
            ),
            content_when_dragging=ft.Container(
                width=40,
                height=40,
                bgcolor=Colors.BLUE_200,
                border_radius=5,
            ),
            on_drag_start=self._on_drag_start,
            on_drag_complete=self._on_drag_complete,
        )

        self.title_field = ft.TextField(hint_text="タイトル", expand=True, **kwargs)
        self.content_field = ft.TextField(hint_text="内容", multiline=True, expand=True, **kwargs)

        duplicate_button = ft.IconButton(
            icon=Icons.COPY_OUTLINED,
            tooltip="コピー",
            on_click=self._on_duplicate_click,
        )

        delete_button = ft.IconButton(
            icon=Icons.CLOSE,
            icon_size=20,
            tooltip="削除",
            on_click=self._on_delete_click,
        )

        # ドラッグターゲット（カード全体）
        self.drag_target = ft.DragTarget(
            group="fields",
            content=ft.Row(
                controls=[
                    self.drag_handle,
                    ft.Column(
                        controls=[self.title_field, self.content_field],
                        expand=True
                    ),
                    ft.Column(
                        controls=[duplicate_button, delete_button],
                    )
                ],
                spacing=5,
            ),
            on_will_accept=self._on_will_accept,
            on_accept=self._on_accept,
            on_leave=self._on_leave,
        )

        self.content = self.drag_target

    def _on_drag_start(self, e):
        if self.on_reorder:
            self.on_reorder("start", self)

    def _on_drag_complete(self, e):
        if self.on_reorder:
            self.on_reorder("complete", self)

    def _on_will_accept(self, e):
        if self.on_reorder:
            self.on_reorder("hover", self)
        e.control.update()

    def _on_accept(self, e):
        if self.on_reorder:
            self.on_reorder("drop", self)

    def _on_leave(self, e):
        if self.on_reorder:
            self.on_reorder("leave", self)

    def _on_delete_click(self, e):
        if self.on_delete:
            self.on_delete(self)

    def _on_duplicate_click(self, e):
        if self.on_duplicate:
            self.on_duplicate(self)

    def get_values(self):
        return {
            "title": self.title_field.value,
            "content": self.content_field.value
        }


def main(page: ft.Page):
    page.title = "削除可能なTextField（ドラッグ&ドロップ対応）"
    page.padding = 20

    field_container = ft.Column(spacing=10)

    # ドラッグ中の情報を保持
    drag_state = {
        "dragging_field": None,
        "original_index": None,
        "current_hover_index": None
    }

    def update_indices():
        """各フィールドのインデックスを更新"""
        for i, field in enumerate(field_container.controls):
            field.index = i

    def reorder_fields(action, target_field):
        """フィールドの並び替え処理"""
        if action == "start":
            # ドラッグ開始
            drag_state["dragging_field"] = target_field
            drag_state["original_index"] = field_container.controls.index(target_field)
            drag_state["current_hover_index"] = drag_state["original_index"]

        elif action == "hover" and drag_state["dragging_field"]:
            # ホバー中（リアルタイムで入れ替え）
            dragging_field = drag_state["dragging_field"]
            if dragging_field != target_field:
                dragging_index = field_container.controls.index(dragging_field)
                target_index = field_container.controls.index(target_field)

                # フィールドを入れ替え
                field_container.controls.pop(dragging_index)
                field_container.controls.insert(target_index, dragging_field)
                drag_state["current_hover_index"] = target_index

                update_indices()
                page.update()

        elif action == "complete":
            # ドラッグ完了（状態をリセット）
            drag_state["dragging_field"] = None
            drag_state["original_index"] = None
            drag_state["current_hover_index"] = None
            update_indices()
            page.update()

    # 削除確認ダイアログ
    def confirm_delete(field):
        def close_dialog(e):
            dialog.open = False
            page.update()

        def yes_click(e):
            field_container.controls.remove(field)
            dialog.open = False
            update_indices()
            page.update()

        dialog = ft.AlertDialog(
            modal=True,
            title=ft.Text("削除の確認"),
            content=ft.Text("このフィールドを削除してもよろしいですか？"),
            actions=[
                ft.TextButton("いいえ", on_click=close_dialog),
                ft.TextButton("はい", on_click=yes_click),
            ],
            actions_alignment=ft.MainAxisAlignment.END,
        )

        page.overlay.append(dialog)
        dialog.open = True
        page.update()

    def duplicate_field(field):
        values = field.get_values()
        new_field = RemovableTextInput(
            on_delete=confirm_delete,
            on_duplicate=duplicate_field,
            on_reorder=reorder_fields,
            index=field.index + 1
        )
        new_field.title_field.value = values["title"]
        new_field.content_field.value = values["content"]

        # 元のフィールドの次に挿入
        index = field_container.controls.index(field)
        field_container.controls.insert(index + 1, new_field)
        update_indices()
        page.update()

    def add_field(e):
        new_field = RemovableTextInput(
            on_delete=confirm_delete,
            on_duplicate=duplicate_field,
            on_reorder=reorder_fields,
            index=len(field_container.controls)
        )
        field_container.controls.append(new_field)
        update_indices()
        page.update()

    # 初期フィールドを3つ追加
    for i in range(3):
        field_container.controls.append(
            RemovableTextInput(
                on_delete=confirm_delete,
                on_duplicate=duplicate_field,
                on_reorder=reorder_fields,
                index=i
            )
        )

    page.add(
        ft.Text(
            "ハンドルをドラッグしてフィールドを並び替え",
            size=20,
            weight=ft.FontWeight.BOLD
        ),
        field_container,
        ft.ElevatedButton("フィールドを追加", on_click=add_field),
    )


ft.app(target=main)
```

ドラッグ中に要素全体を半透明にしてカーソルに追従させたい。現在はハンドルのアイコンだけが追従する。
どこを変更するべき？コードは部分ではなく全体を提示して。