.modal

= yield :wrapper
.modal-dialog{ class: "modal-#{size}" }
  .modal-content
    .modal-header
      = yield :header
      - if title.present?
        %h5.modal-title
          = title
          - if desc.present?
            %small.text-secondary= desc
      %button.close{"aria-label" => "Close", "data-dismiss" => "modal", :type => "button"}
        = fas_icon('times')

    = yield
    = yield :before_body
    - body_html = capture { yield :body }
    - if body_html.present?
      .modal-body= body_html
    = yield :after_body

    - footer_html = capture { yield :footer }
    - if footer_html.present?
      .modal-footer= footer_html