Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add move tags in the chessboard #79

Merged

Conversation

franciscoBSalgueiro
Copy link
Owner

No description provided.

@franciscoBSalgueiro franciscoBSalgueiro linked an issue Nov 10, 2023 that may be closed by this pull request
@franciscoBSalgueiro franciscoBSalgueiro merged commit 5de96cd into master Nov 10, 2023
2 checks passed
@franciscoBSalgueiro franciscoBSalgueiro deleted the 78-move-tags-mistake-brilliant-in-the-chessboard branch November 10, 2023 20:02
@dav1312
Copy link
Contributor

dav1312 commented Nov 14, 2023

The circle is sometimes cut and I'm also sometimes getting a weird underline in the moves
Also I don't like the tag itself being text... it looks bad imho
What about an svg?
image

@franciscoBSalgueiro
Copy link
Owner Author

is this on linux? I could make it an svg.

@dav1312
Copy link
Contributor

dav1312 commented Nov 14, 2023

Yes I'm testing on linux

@franciscoBSalgueiro
Copy link
Owner Author

Yeah, webkitgtk really sucks compared to the windows and mac native webviews unfortunately.

@franciscoBSalgueiro
Copy link
Owner Author

please let me know if 92a6210 helps

@dav1312
Copy link
Contributor

dav1312 commented Nov 14, 2023

please let me know if 92a6210 helps

Looks much better!! 😄

Perhaps add a little drop shadow too? wdyt? I think it gives it an interesting sense of depth

image image

This is what I used trying to imitate Lichess but it might not be the best way to do it

           <Avatar
             sx={{
               transform: "translateY(-40%) translateX(-50%)",
               zIndex: 100,
+              filter: "url(#shadow)",
+              overflow: "initial"
             }}
             radius="xl"
             color={color}
             variant="filled"
           >
             <svg viewBox="0 0 100 100" width="100%" height="100%">
+              <defs>
+                <filter id="shadow">
+                  <feDropShadow dx="0" dy="1" floodOpacity="0.3" stdDeviation="0"></feDropShadow>
+                </filter>
+              </defs>
               <g>{glyphToSvg[annotation]}</g>
             </svg>
           </Avatar>

Also, it looks like the size of the icons is not changing with the board size which can look funny
image

@franciscoBSalgueiro
Copy link
Owner Author

franciscoBSalgueiro commented Nov 15, 2023

that shadow looks good thanks! the app already looks scuffed when resized to small sizes so I'll probably fix those icons sizes later

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Move tags (mistake, brilliant...) in the chessboard
2 participants