Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/main' into feature/accessibility…
Browse files Browse the repository at this point in the history
…-hook
  • Loading branch information
bluzky committed Dec 8, 2024
2 parents 2ef5118 + f72ec0a commit fce00ef
Show file tree
Hide file tree
Showing 34 changed files with 149 additions and 145 deletions.
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -141,9 +141,11 @@ It's also important to note that you must format your code with `mix format` bef
- ✅ Dropdown Menu
- ✅ Form
- ✅ Hover Card
- ✅ Icon
- ✅ Input
- [ ] Input OTP
- ✅ Label
- ✅ Menu
- ✅ Pagination
- ✅ Popover
- ✅ Progress
Expand All @@ -159,9 +161,9 @@ It's also important to note that you must format your code with `mix format` bef
- ✅ Table
- ✅ Tabs
- ✅ Textarea
- ✅ Tooltip
- ✅ Toggle
- ✅ Toggle Group
- ✅ Tooltip

## 🌟 Contributors

Expand Down
2 changes: 1 addition & 1 deletion lib/mix/tasks/salad.init.ex
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ defmodule Mix.Tasks.Salad.Init do
:ok <- maybe_write_component_module(component_path, app_name, opts),
:ok <- install_node_dependencies(node_opts) do
if opts[:as_lib] do
Mix.shell().info("Done. Now you can use any component by importSaladUI.<ComponentName> in your project.")
Mix.shell().info("Done. Now you can use any component by `import SaladUI.<ComponentName>` in your project.")
else
Mix.shell().info("Done. Now you can add components by running mix salad.add <component_name>")
end
Expand Down
8 changes: 4 additions & 4 deletions lib/salad_ui/accordion.ex
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ defmodule SaladUI.Accordion do
def accordion(assigns) do
~H"""
<div class={classes(["", @class])}>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</div>
"""
end
Expand All @@ -50,7 +50,7 @@ defmodule SaladUI.Accordion do
def accordion_item(assigns) do
~H"""
<div class={classes(["border-b", @class])}>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</div>
"""
end
Expand All @@ -70,7 +70,7 @@ defmodule SaladUI.Accordion do
])
}>
<p class="font-medium">
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</p>
<svg
Expand Down Expand Up @@ -100,7 +100,7 @@ defmodule SaladUI.Accordion do
<div class="text-sm overflow-hidden grid grid-rows-[0fr] transition-[grid-template-rows] duration-300 peer-open/accordion:grid-rows-[1fr]">
<div class="overflow-hidden">
<div class={classes(["pb-4 pt-0", @class])}>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</div>
</div>
</div>
Expand Down
6 changes: 3 additions & 3 deletions lib/salad_ui/alert.ex
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ defmodule SaladUI.Alert do
}
{@rest}
>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</div>
"""
end
Expand All @@ -55,7 +55,7 @@ defmodule SaladUI.Alert do
}
{@rest}
>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</h5>
"""
end
Expand All @@ -78,7 +78,7 @@ defmodule SaladUI.Alert do
}
{@rest}
>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</div>
"""
end
Expand Down
18 changes: 9 additions & 9 deletions lib/salad_ui/alert_dialog.ex
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ defmodule SaladUI.AlertDialog do
class="inline-block relative"
id={@id}
>
<%= render_slot(@inner_block, @builder) %>
{render_slot(@inner_block, @builder)}
</div>
"""
end
Expand All @@ -69,7 +69,7 @@ defmodule SaladUI.AlertDialog do
])
}
>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</div>
"""
end
Expand Down Expand Up @@ -98,7 +98,7 @@ defmodule SaladUI.AlertDialog do
}
{@rest}
>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</div>
</div>
</div>
Expand All @@ -123,7 +123,7 @@ defmodule SaladUI.AlertDialog do
}
{@rest}
>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</div>
"""
end
Expand All @@ -146,7 +146,7 @@ defmodule SaladUI.AlertDialog do
}
{@rest}
>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</h2>
"""
end
Expand All @@ -169,7 +169,7 @@ defmodule SaladUI.AlertDialog do
}
{@rest}
>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</p>
"""
end
Expand All @@ -192,7 +192,7 @@ defmodule SaladUI.AlertDialog do
}
{@rest}
>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</div>
"""
end
Expand Down Expand Up @@ -220,7 +220,7 @@ defmodule SaladUI.AlertDialog do
}
{@rest}
>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</button>
"""
end
Expand All @@ -245,7 +245,7 @@ defmodule SaladUI.AlertDialog do
}
{@rest}
>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</button>
"""
end
Expand Down
4 changes: 2 additions & 2 deletions lib/salad_ui/avatar.ex
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ defmodule SaladUI.Avatar do
class={classes(["relative h-10 w-10 shrink-0 overflow-hidden rounded-full", @class])}
{@rest}
>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</span>
"""
end
Expand Down Expand Up @@ -44,7 +44,7 @@ defmodule SaladUI.Avatar do
}
{@rest}
>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</span>
"""
end
Expand Down
2 changes: 1 addition & 1 deletion lib/salad_ui/badge.ex
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ defmodule SaladUI.Badge do
}
{@rest}
>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</div>
"""
end
Expand Down
10 changes: 5 additions & 5 deletions lib/salad_ui/breadcrumb.ex
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ defmodule SaladUI.Breadcrumb do
{@rest}
}
>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</nav>
"""
end
Expand All @@ -65,7 +65,7 @@ defmodule SaladUI.Breadcrumb do
{@rest}
}
>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</ol>
"""
end
Expand All @@ -88,7 +88,7 @@ defmodule SaladUI.Breadcrumb do
}
{@rest}
>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</li>
"""
end
Expand All @@ -111,7 +111,7 @@ defmodule SaladUI.Breadcrumb do
}
{@rest}
>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</.link>
"""
end
Expand All @@ -137,7 +137,7 @@ defmodule SaladUI.Breadcrumb do
}
{@rest}
>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</span>
"""
end
Expand Down
2 changes: 1 addition & 1 deletion lib/salad_ui/button.ex
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ defmodule SaladUI.Button do
}
{@rest}
>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</button>
"""
end
Expand Down
12 changes: 6 additions & 6 deletions lib/salad_ui/card.ex
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ defmodule SaladUI.Card do
def card(assigns) do
~H"""
<div class={classes(["rounded-xl border bg-card text-card-foreground shadow", @class])} {@rest}>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</div>
"""
end
Expand All @@ -42,7 +42,7 @@ defmodule SaladUI.Card do
def card_header(assigns) do
~H"""
<div class={classes(["flex flex-col space-y-1.5 p-6", @class])} {@rest}>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</div>
"""
end
Expand All @@ -54,7 +54,7 @@ defmodule SaladUI.Card do
def card_title(assigns) do
~H"""
<h3 class={classes(["text-2xl font-semibold leading-none tracking-tight", @class])} {@rest}>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</h3>
"""
end
Expand All @@ -66,7 +66,7 @@ defmodule SaladUI.Card do
def card_description(assigns) do
~H"""
<p class={classes(["text-sm text-muted-foreground", @class])} {@rest}>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</p>
"""
end
Expand All @@ -78,7 +78,7 @@ defmodule SaladUI.Card do
def card_content(assigns) do
~H"""
<div class={classes(["p-6 pt-0", @class])} {@rest}>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</div>
"""
end
Expand All @@ -90,7 +90,7 @@ defmodule SaladUI.Card do
def card_footer(assigns) do
~H"""
<div class={classes(["flex items-center justify-between p-6 pt-0 ", @class])} {@rest}>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</div>
"""
end
Expand Down
6 changes: 3 additions & 3 deletions lib/salad_ui/collapsible.ex
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ defmodule SaladUI.Collapsible do
id={@id}
{@rest}
>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</div>
"""
end
Expand All @@ -59,7 +59,7 @@ defmodule SaladUI.Collapsible do
def collapsible_trigger(assigns) do
~H"""
<.dynamic tag={@as_tag} data-part="trigger" class={@class} {@rest}>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</.dynamic>
"""
end
Expand All @@ -83,7 +83,7 @@ defmodule SaladUI.Collapsible do
}
{@rest}
>
<%= render_slot(@inner_block) %>
{render_slot(@inner_block)}
</div>
"""
end
Expand Down
Loading

0 comments on commit fce00ef

Please sign in to comment.