-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
try for a simple rgb picker / restore gamut markers
- Loading branch information
1 parent
9026c2e
commit 2862cf4
Showing
7 changed files
with
121 additions
and
76 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,29 @@ | ||
<script lang="ts"> | ||
export let xPos: number; | ||
export let yPos: number; | ||
export let lum: number; | ||
export let selected: boolean; | ||
$: markColor = lum > 0.4 ? "#00000022" : "#ffffff55"; | ||
$: size = selected ? 7 : 3; | ||
</script> | ||
|
||
<g pointer-events="none" transform={`translate(${xPos}, ${yPos})`}> | ||
<line | ||
pointer-events="none" | ||
stroke="black" | ||
x1={-7} | ||
y1={-7} | ||
x2={7} | ||
y2={7} | ||
stroke={markColor} | ||
stroke-width="2" | ||
x1={-size} | ||
y1={-size} | ||
x2={size} | ||
y2={size} | ||
></line> | ||
<line | ||
pointer-events="none" | ||
stroke="black" | ||
x1={-7} | ||
y1={7} | ||
x2={7} | ||
y2={-7} | ||
stroke={markColor} | ||
stroke-width="2" | ||
x1={-size} | ||
y1={size} | ||
x2={size} | ||
y2={-size} | ||
></line> | ||
</g> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters