Skip to content

Commit

Permalink
Base: Add some extra conic-gradient() test cases
Browse files Browse the repository at this point in the history
This adds a test of a conic-gradient() with just a center position
and no starting angle.

This also adds a gradient that gives each quadrant a different color,
this is very sensitive to the center position being correct.
  • Loading branch information
MacDue authored and linusg committed Nov 6, 2022
1 parent b2a0d70 commit d66b219
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions Base/res/html/misc/gradients.html
Original file line number Diff line number Diff line change
Expand Up @@ -157,6 +157,14 @@
red 6deg, orange 6deg 18deg, yellow 18deg 45deg,
green 45deg 110deg, blue 110deg 200deg, purple 200deg);
}

.grad-conic-5 {
background-image: conic-gradient(at 60% 45%, red, yellow, green);
}

.grad-conic-6 {
background-image: conic-gradient(red 0deg, red 90deg, yellow 90deg, yellow 180deg, green 180deg, green 270deg, blue 270deg);
}
</style>
</head>
<body>
Expand Down Expand Up @@ -202,6 +210,8 @@ <h1>Gradients!</h1>
<div class="box grad-conic-2"></div>
<div class="box grad-conic-3"></div>
<div class="box grad-conic-4"></div>
<div class="box grad-conic-5"></div>
<div class="box grad-conic-6"></div>
</body>
<script>
const boxes = document.querySelectorAll(".box, .rect");
Expand Down

0 comments on commit d66b219

Please sign in to comment.