Skip to content

Commit

Permalink
fix: Fix storybook, rename phx_live_storybook to Phoniex.Storybook.
Browse files Browse the repository at this point in the history
  • Loading branch information
GSMLG-BOT committed Mar 4, 2023
1 parent 71f2a05 commit 82de3d1
Show file tree
Hide file tree
Showing 16 changed files with 217 additions and 171 deletions.

Large diffs are not rendered by default.

Expand Up @@ -11,7 +11,7 @@
phx-disconnected={show("#disconnected")}
phx-connected={hide("#disconnected")}
>
Attempting to reconnect <Heroicons.arrow_path class="ml-1 w-3 h-3 inline animate-spin" />
Attempting to reconnect <.wc_bsi name="arrow-repeat" class="ml-1 w-3 h-3 inline animate-spin" />
</.flash>
<.wc_left_menu
class="w-48 h-[calc(100vh-56px)]"
Expand Down
Expand Up @@ -17,11 +17,10 @@
```
"""}></.wc_markdown>
<div class="flex flex-row mt-4 mb-2">
<%= form_for @conn, Routes.page_path(@conn, :bsi), [method: "get", class: "flex flex-row gap-2"], fn f -> %>
<label class="flex items-center">Icon Name</label>
<%= text_input f, :filter, class: "border rounded-lg py-2 px-3" %>
<%= submit "Search", class: "broder rounded-lg bg-blue-600 text-slate-100 py-2 px-3" %>
<% end %>
<.form for={@conn} action={Routes.page_path(@conn, :bsi)} method="get" class={["flex flex-row gap-2"]}>
<.input field={:filter} label="Icon Name" />
<.button type="submit">Search</.button>
</.form>
</div>
<div class="flex flex-row flex-wrap gap-4">
<%= for icon_name <- @bsi_icons do %>
Expand Down
Expand Up @@ -17,11 +17,10 @@
```
"""}></.wc_markdown>
<div class="flex flex-row mt-4 mb-2">
<%= form_for @conn, Routes.page_path(@conn, :mdi), [method: "get", class: "flex flex-row gap-2"], fn f -> %>
<label class="flex items-center">Icon Name</label>
<%= text_input f, :filter, class: "border rounded-lg py-2 px-3" %>
<%= submit "Search", class: "broder rounded-lg bg-blue-600 text-slate-100 py-2 px-3" %>
<% end %>
<.form for={@conn} action={Routes.page_path(@conn, :mdi)} method="get" class={["flex flex-row gap-2"]}>
<.input field={:filter} label="Icon Name" />
<.button type="submit">Search</.button>
</.form>
</div>
<div class="flex flex-row flex-wrap gap-4">
<%= for icon_name <- @mdi_icons do %>
Expand Down
4 changes: 2 additions & 2 deletions apps/phx_wc_storybook_web/lib/phx_wc_storybook_web/router.ex
@@ -1,12 +1,12 @@
defmodule PhxWCStorybookWeb.Router do
use PhxWCStorybookWeb, :router
import PhxLiveStorybook.Router
import PhoenixStorybook.Router

pipeline :browser do
plug :accepts, ["html"]
plug :fetch_session
plug :fetch_live_flash
plug :put_root_layout, {PhxWCStorybookWeb.LayoutView, :root}
plug :put_root_layout, {PhxWCStorybookWeb.Layouts, :root}
plug :protect_from_forgery
plug :put_secure_browser_headers
end
Expand Down
@@ -1,6 +1,6 @@
defmodule PhxWCStorybookWeb.Storybook do
@moduledoc false
use PhxLiveStorybook,
use PhoenixStorybook,
# OTP name of your application.
otp_app: :phx_wc_storybook_web,

Expand Down
@@ -1,6 +1,6 @@
defmodule PhxWCStorybookWeb.Storybook.Components.Actionbar do
# :live_component or :page are also available
use PhxLiveStorybook.Story, :component
use PhoenixStorybook.Story, :component

def function, do: &Phoenix.WebComponent.Actionbar.wc_actionbar/1
def description, do: "A actionbar element."
Expand Down
@@ -1,6 +1,6 @@
defmodule PhxWCStorybookWeb.Storybook.Components.Breadcrumb do
# :live_component or :page are also available
use PhxLiveStorybook.Story, :component
use PhoenixStorybook.Story, :component

def function, do: &Phoenix.WebComponent.Breadcrumb.wc_breadcrumb/1
def description, do: "A breadcrumb element."
Expand Down
@@ -1,6 +1,6 @@
defmodule PhxWCStorybookWeb.Storybook.Components.Card do
# :live_component or :page are also available
use PhxLiveStorybook.Story, :component
use PhoenixStorybook.Story, :component

def function, do: &Phoenix.WebComponent.Card.wc_card/1
def description, do: "A card element."
Expand Down
@@ -1,6 +1,6 @@
defmodule PhxWCStorybookWeb.Storybook.Components.LeftMenu do
# :live_component or :page are also available
use PhxLiveStorybook.Story, :component
use PhoenixStorybook.Story, :component

def function, do: &Phoenix.WebComponent.LeftMenu.wc_left_menu/1
def description, do: "A left menu element."
Expand Down
@@ -1,6 +1,6 @@
defmodule PhxWCStorybookWeb.Storybook.Components.Link do
# :live_component or :page are also available
use PhxLiveStorybook.Story, :component
use PhoenixStorybook.Story, :component

def function, do: &Phoenix.WebComponent.Link.wc_link/1
def description, do: "Recreate Phoenix.Component.link with custom element."
Expand Down
@@ -1,6 +1,6 @@
defmodule PhxWCStorybookWeb.Storybook.Components.Markdown do
# :live_component or :page are also available
use PhxLiveStorybook.Story, :component
use PhoenixStorybook.Story, :component

def function, do: &Phoenix.WebComponent.Markdown.wc_markdown/1
def description, do: "A markdown render element."
Expand Down
@@ -1,5 +1,5 @@
defmodule PhxWCStorybookWeb.Storybook.Components.Modal do
use PhxLiveStorybook.Story, :component
use PhoenixStorybook.Story, :component

def function, do: &Phoenix.WebComponent.Modal.wc_modal/1

Expand Down
@@ -1,6 +1,6 @@
defmodule PhxWCStorybookWeb.Storybook.Components.Pagination do
# :live_component or :page are also available
use PhxLiveStorybook.Story, :component
use PhoenixStorybook.Story, :component

def function, do: &Phoenix.WebComponent.Pagination.wc_pagination/1
def description, do: "A pagination element."
Expand Down
@@ -1,6 +1,6 @@
defmodule PhxWCStorybookWeb.Storybook.Components.Table do
# :live_component or :page are also available
use PhxLiveStorybook.Story, :component
use PhoenixStorybook.Story, :component

def function, do: &Phoenix.WebComponent.Table.wc_table/1
def description, do: "A table element."
Expand Down
18 changes: 0 additions & 18 deletions apps/phx_wc_storybook_web/lib/table.exs

This file was deleted.

0 comments on commit 82de3d1

Please sign in to comment.