View Source Bonfire.UI.Common.ReusableModalLive (bonfire v0.3.5-classic-beta.10)

The classic modal

properties

Properties

  • id :string, required: true - The id of the live component (required by LiveView for stateful components).

  • title_text :string, default: nil - The title of the modal. Only used if no title slot is passed.

  • title_class :css_class, default: @doc("The classes of the modal.") - The classes of the modal.

  • modal_class :string, default: nil

  • cancel_btn_class :css_class, default: nil - The classes of the close/cancel button on the modal. Only used if no close_btn slot is passed.

  • show :boolean, default: false - Force modal to be open

  • form_opts :any, default: []

  • no_actions :boolean, default: false - Optional prop to hide the actions at the bottom of the modal

  • no_header :boolean, default: false, required: false - Optional prop to hide the header at the top of the modal

  • opts :keyword, default: [] - Additional attributes to add onto the modal wrapper

  • autocomplete :list, default: []

slots

Slots

  • default, args: [:autocomplete] - Slots for the contents of the modal, title, buttons...

  • open_btn

  • action_btns

  • cancel_btn

  • title

Link to this section Summary

Link to this section Functions

Link to this function

handle_event(action, attrs, socket)

View Source

Callback implementation for Phoenix.LiveComponent.handle_event/3.

Link to this function

handle_info(info, socket)

View Source

Callback implementation for Phoenix.LiveComponent.mount/1.

Callback implementation for Phoenix.LiveComponent.render/1.

Callback implementation for Phoenix.LiveComponent.update/2.