From 41e0c206650985bc7cd0ff65fead6ba9685e7a53 Mon Sep 17 00:00:00 2001 From: Claudio Ortolina Date: Mon, 12 May 2025 10:35:19 +0100 Subject: [PATCH] Remove unused CoreComponents Generated by Phoenix with initial scaffolding, now unused or replaced by FluxonUI --- .../components/core_components.ex | 253 ------------------ 1 file changed, 253 deletions(-) diff --git a/lib/music_library_web/components/core_components.ex b/lib/music_library_web/components/core_components.ex index f62ac220..87868791 100644 --- a/lib/music_library_web/components/core_components.ex +++ b/lib/music_library_web/components/core_components.ex @@ -16,7 +16,6 @@ defmodule MusicLibraryWeb.CoreComponents do """ use Phoenix.Component - alias Phoenix.HTML.Form alias Phoenix.LiveView.JS use Gettext, backend: MusicLibraryWeb.Gettext @@ -249,179 +248,6 @@ defmodule MusicLibraryWeb.CoreComponents do """ end - @doc """ - Renders an input with label and error messages. - - A `Phoenix.HTML.FormField` may be passed as argument, - which is used to retrieve the input name, id, and values. - Otherwise all attributes may be passed explicitly. - - ## Types - - This function accepts all HTML input types, considering that: - - * You may also set `type="select"` to render a ` - - {@label} - - <.error :for={msg <- @errors}>{msg} - - """ - end - - def input(%{type: "select"} = assigns) do - ~H""" -
- <.label for={@id}>{@label} - - <.error :for={msg <- @errors}>{msg} -
- """ - end - - def input(%{type: "textarea"} = assigns) do - ~H""" -
- <.label for={@id}>{@label} - - <.error :for={msg <- @errors}>{msg} -
- """ - end - - # All other inputs text, datetime-local, url, password, etc. are handled here... - def input(assigns) do - ~H""" -
- <.label for={@id}>{@label} - - <.error :for={msg <- @errors}>{msg} -
- """ - end - - @doc """ - Renders a label. - """ - attr :for, :string, default: nil - slot :inner_block, required: true - def label(assigns) do ~H"""