diff --git a/lib/radiator_web/live/episode_live/index.ex b/lib/radiator_web/live/episode_live/index.ex index bd51b7fc..ee22f064 100644 --- a/lib/radiator_web/live/episode_live/index.ex +++ b/lib/radiator_web/live/episode_live/index.ex @@ -61,6 +61,8 @@ defmodule RadiatorWeb.EpisodeLive.Index do end @impl true + def handle_info(%NodeMovedEvent{} = event, socket), do: proxy_event(event, socket) + def handle_info(%{uuid: <<_::binary-size(36)>> <> ":" <> id} = event, %{id: id} = socket) do socket |> stream_event(event) @@ -69,7 +71,6 @@ defmodule RadiatorWeb.EpisodeLive.Index do def handle_info(%NodeInsertedEvent{} = event, socket), do: proxy_event(event, socket) def handle_info(%NodeContentChangedEvent{} = event, socket), do: proxy_event(event, socket) - def handle_info(%NodeMovedEvent{} = event, socket), do: proxy_event(event, socket) def handle_info(%NodeDeletedEvent{} = event, socket), do: proxy_event(event, socket) defp proxy_event(event, socket) do diff --git a/lib/radiator_web/live/outline_component.ex b/lib/radiator_web/live/outline_component.ex index fe0fef53..0f2d1a9a 100644 --- a/lib/radiator_web/live/outline_component.ex +++ b/lib/radiator_web/live/outline_component.ex @@ -217,12 +217,10 @@ defmodule RadiatorWeb.OutlineComponent do ) socket - |> push_event("move_node", %{uuid: uuid, parent_id: prev_parent_id, prev_id: prev_prev_id}) end defp move_down(socket, _uuid, _prev_id) do socket - # |> push_event("move_node", %{uuid: uuid, parent_id: next_parent_id, prev_id: next_uuid}) end defp indent(socket, uuid, _prev_id) do @@ -241,6 +239,5 @@ defmodule RadiatorWeb.OutlineComponent do ) socket - |> push_event("move_node", %{uuid: uuid, parent_id: nil, prev_id: parent_id}) end end