Skip to content

Conversation

@BobPritchett
Copy link

  • Added support for additional CSS escape sequences (b, f, j, q, v, w, y) in parse-css.pegjs.
  • Updated Length type in style.ts to include new units (cm, mm, Q, in, pc, pt, px, em).
  • Refactored resolveEm function to resolveUnit for better unit conversion handling.
  • Improved unit conversion logic for various length units in resolveUnit function.
  • Added VSCode launch configuration for debugging Vite applications in Chrome and Edge.
  • Created VSCode settings to disable format on save and Prettier.

- Added support for additional CSS escape sequences (b, f, j, q, v, w, y) in parse-css.pegjs.
- Updated Length type in style.ts to include new units (cm, mm, Q, in, pc, pt, px, em).
- Refactored resolveEm function to resolveUnit for better unit conversion handling.
- Improved unit conversion logic for various length units in resolveUnit function.
- Added VSCode launch configuration for debugging Vite applications in Chrome and Edge.
- Created VSCode settings to disable format on save and Prettier.
Copy link
Owner

@chearon chearon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The biggest thing is that several tests are failing. I'll figure out how to get the tests to run when your PR is opened. Not sure what the problem is; where you put resolveUnit should be alright.

W = 'w'i / '\\' '0'? '0'? '0'? '0'? [\x57\x77] ('\r\n' / [ \t\r\n\f])? / '\\w'i { return 'w'; }
X = 'x'i / '\\' '0'? '0'? '0'? '0'? [\x58\x78] ('\r\n' / [ \t\r\n\f])? / '\\x'i { return 'x'; }
Y = 'y'i / '\\' '0'? '0'? '0'? '0'? [\x59\x79] ('\r\n' / [ \t\r\n\f])? / '\\y'i { return 'y'; }
Z = 'z'i / '\\' '0'? '0'? '0'? '0'? [\x5A\x7A] ('\r\n' / [ \t\r\n\f])? / '\\z'i { return 'z'; }
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think most of the additions here are used. Can you remove the other changes, so it just adds Q?

If you look at the pegjs output, this actually does cause dead code to be generated.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can, but I think it very likely we'll need some/all of them and having it be complete now seemed likely a way to reduce errors in the future. Maybe commenting them out till used?

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.

3 participants