Skip to content

Commit

Permalink
Add style formating test case and bump deps to bring raffia fix
Browse files Browse the repository at this point in the history
  • Loading branch information
UnknownPlatypus committed Aug 15, 2024
1 parent 4b0169f commit 568ca68
Show file tree
Hide file tree
Showing 4 changed files with 247 additions and 36 deletions.
82 changes: 46 additions & 36 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

60 changes: 60 additions & 0 deletions dprint_plugin/tests/integration/biome/style-attr.html.snap
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,63 @@
source: dprint_plugin/tests/integration.rs
---
<div style="width: 1px; height: 1px"></div>

<div style="position: absolute"></div>
<!-- Compact style argument -->
<div
style="left: 50%; bottom: 0"
class="absolute -translate-x-1/2 data-tag data-tag--lg data-tag--borders tint-green text-24 h-36"
>
style is first arg
</div>

<div
class="flex flex-col items-center absolute z-10 {% if title|length > 30 %}w-4/5{% else %}w-1/2{% endif %}"
style="top: 60%; transform: translate(0, -50%)"
>
style is second arg
</div>

<div
class="flex flex-col items-center absolute z-10 {% if title|length > 30 %}w-4/5{% else %}w-1/2{% endif %}"
style="top: 60%; transform: translate(0, -50%)"
id="dfff"
>
style is middle arg
</div>

<div style="top: 60%; transform: translate(0, -50%)"></div>

<div
class="absolute right-0 bg-blue-020 rounded-full"
style="height: 585px; width: 585px; filter: blur(86px); top: 153px"
>
Big multiline style arg
</div>

<div style="top: 90%; transform: translate(0, -50%)">
<div style="top: 80%; transform: translate(0, -50%)">
<div style="top: 70%; transform: translate(0, -50%)">
Nested divs with multiline style attrs
</div>
</div>
</div>

<div style="color: red; display: inline"></div>
<div
style="color: red; display: inline; height: auto; position: absolute; top: 0; left: 0; right: 0; bottom: 0"
>
</div>

<div style="top: 60%; transform: translate(0, -50%)">
<div style="top: 60%; transform: translate(0, -50%)">
<div style="top: 60%; transform: translate(0, -50%)">
Nested divs with odd offsets
</div>
</div>
</div>

<div
style="color: red; display: inline; height: auto; position: absolute; top: 0; left: 0; right: 0; bottom: 0"
>
</div>
Loading

0 comments on commit 568ca68

Please sign in to comment.