Skip to content

Commit

Permalink
Fix(web-twig): Do not render class in the style attribute of the `Mod…
Browse files Browse the repository at this point in the history
…alDialog`
  • Loading branch information
crishpeen committed Nov 30, 2023
1 parent 38bcd4e commit 4adbc16
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
{%- endif -%}

{# Attributes #}
{%- set _styleAttr = _style or (_styleProps.style is not same as(null)) ? 'style="' ~ _style ~ _styleProps | join() ~ '"' -%}
{%- set _styleAttr = _style or (_styleProps.style is not same as(null)) ? 'style="' ~ _style ~ _styleProps.style | join() ~ '"' -%}

<{{ _elementType }}
{{ mainProps(props, _allowedAttributes) }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@
method="dialog"
preferredHeightOnMobile="400px"
preferredHeightFromTabletUp="500px"
UNSAFE_className="custom-class"
UNSAFE_style="outline: 5px solid blue; outline-offset: -5px;"
>
<ModalHeader
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ <h2 class="ModalHeader__title" id="modal-example-title">
<!-- Render with all props -->

<dialog class="Modal" id="modal-example-2" aria-labelledby="modal-example-2-title">
<form autocomplete="on" method="dialog" class="ModalDialog" style="--modal-max-height-tablet: 700px;--modal-preferred-height-mobile: 400px;--modal-preferred-height-tablet: 500px;outline: 5px solid blue; outline-offset: -5px;">
<form autocomplete="on" method="dialog" class="ModalDialog custom-class" style="--modal-max-height-tablet: 700px;--modal-preferred-height-mobile: 400px;--modal-preferred-height-tablet: 500px;outline: 5px solid blue; outline-offset: -5px;">
<header class="ModalHeader">
<h2 class="ModalHeader__title" id="modal-example-2-title">
Title of the Modal
Expand Down

0 comments on commit 4adbc16

Please sign in to comment.