View Source PhoenixDuskmoon.LeftMenu (PhoenixDuskmoon v4.5.0)

Render left menu.

Summary

Functions

Generates left menu

Generates left menu Group

Functions

Generates left menu

Example

<.dm_left_menu
  class="w-[200px] bg-[rgba(255,255,255,.7)] text-[14px]"
  active="actionbar"
>
  <:title class="text-[#A1A7C4]">Phx WebComponents</:title>
  <:menu>actionbar</:menu>
  <:menu>appbar</:menu>
</.dm_left_menu>

Attributes

  • id (:any) - html attribute id. Defaults to false.
  • class (:any) - html attribute class. Defaults to "".
  • active (:string) - actvie menu id. Defaults to "".

Slots

  • title - Render menu title. Accepts attributes:
    • class (:any)
  • menu - Render menu. Accepts attributes:
    • class (:any)
Link to this function

dm_left_menu_group(assigns)

View Source

Generates left menu Group

Example

<.dm_left_menu_group active={"mdi"}>
  <:title>Icons</:title>
  <:menu id="mdi" to={~p"/icons/mdi"}>MD Icon</:menu>
  <:menu id="bsi" to={~p"/icons/bsi"}>BS Icon</:menu>
</.dm_left_menu_group>

Attributes

  • id (:any) - html attribute id. Defaults to false.
  • class (:any) - html attribute class. Defaults to "".
  • active (:string) - actvie menu id. Defaults to "".
  • active_class (:any) - active menu html attribute class. Defaults to "bg-blue-100 text-blue-500 dark:bg-blue-900 dark:text-blue-100".

Slots

  • title (required) - Render menu title. Accepts attributes:
    • class (:any)
  • menu - Render menu. Accepts attributes:
    • id (:string)
    • class (:any)
    • to (:string)