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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add index CSS variables to lines, words and chars #58

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

flayks
Copy link

@flayks flayks commented Feb 14, 2023

Regarding our discussion @lukePeavey, I gave it a go and implemented this feature as it seemed to be fairly simple for me to try 馃槃

It works pretty well imo but let me know if things need changes! I also added a setting (true by default, can be put back to false, up to you) to control this behavior

image

@flayks
Copy link
Author

flayks commented Feb 14, 2023

I just saw that it would cause issues for the indexes when text includes other markup children such as strong or em, like this example: https://lukepeavey.github.io/SplitType/?path=/story/tests-nested-elements--split-lines-words-and-chars

image

This would require more logic and work but I'm afraid this is beyond my skills 馃檲

@lukePeavey
Copy link
Owner

Thanks I'll take a look at this over the weekend.

@flayks
Copy link
Author

flayks commented Nov 13, 2023

@lukePeavey it's been a while since I started this PR, have you had a chance to look at this feature?

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.

None yet

2 participants