-
diff --git a/lib/mishka_template_creator/components/blocks/color.ex b/lib/mishka_template_creator/components/blocks/color.ex
new file mode 100644
index 0000000..f67284f
--- /dev/null
+++ b/lib/mishka_template_creator/components/blocks/color.ex
@@ -0,0 +1,44 @@
+defmodule MishkaTemplateCreator.Components.Blocks.Color do
+ use Phoenix.Component
+ alias MishkaTemplateCreator.Data.TailwindSetting
+
+ attr(:myself, :integer, required: true)
+ attr(:classes, :list, required: true)
+ attr(:title, :string, required: false, default: "Color:")
+ attr(:type, :string, required: false, default: "text")
+ attr(:event_name, :string, required: false, default: "select_color")
+
+ attr(:class, :string,
+ required: false,
+ default: "flex flex-col w-full justify-between items-stretch pt-3 pb-5"
+ )
+
+ def select(%{type: type} = assigns) do
+ assigns =
+ assign(assigns,
+ colors:
+ TailwindSetting.get_form_options("typography", "text-color", nil, nil).form_configs
+ )
+
+ ~H"""
+
+ """
+ end
+end
diff --git a/lib/mishka_template_creator/components/elements/tab.ex b/lib/mishka_template_creator/components/elements/tab.ex
index 6b1ce0f..6f96859 100644
--- a/lib/mishka_template_creator/components/elements/tab.ex
+++ b/lib/mishka_template_creator/components/elements/tab.ex
@@ -10,6 +10,7 @@ defmodule MishkaTemplateCreator.Components.Elements.Tab do
alias Phoenix.LiveView.JS
alias MishkaTemplateCreator.Components.Blocks.Tag
alias MishkaTemplateCreator.Components.Blocks.Icon
+ alias MishkaTemplateCreator.Components.Blocks.Color
@svg_height [
"h-1",
@@ -409,7 +410,7 @@ defmodule MishkaTemplateCreator.Components.Elements.Tab do