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

[css-shapes-2] curve to keyword using seems a bit off #10649

Open
fantasai opened this issue Jul 31, 2024 · 12 comments
Open

[css-shapes-2] curve to keyword using seems a bit off #10649

fantasai opened this issue Jul 31, 2024 · 12 comments

Comments

@fantasai
Copy link
Collaborator

We adopted #9797 which allowed reordering and switched via to using but we typically use prepositions, not verbs, for these types of keywords and also using is a bit vague in any case. Opening this issue to look for alternatives.

My opening bid is around. :)

@Crissov
Copy link
Contributor

Crissov commented Jul 31, 2024

per, with

@noamr
Copy link
Collaborator

noamr commented Jul 31, 2024

See #10644 (comment)
Perhaps we can avoid this keyword at all and use ordering, this would also allow us to specify positions for curve control points without breaking relative positions.

@fantasai
Copy link
Collaborator Author

fantasai commented Jul 31, 2024

towards?

@noamr
Copy link
Collaborator

noamr commented Jul 31, 2024

towards?

per / with are more accurate for describing "control points"... though as (per) my previous comment we might be able to get rid of this keyword altogether.

@fantasai
Copy link
Collaborator Author

fantasai commented Aug 1, 2024

@noamr Ordering alone with a long sequence of length values is hard to understand (this is one of the problems with the existing SVG paths syntax), so I think having a keyword here is helpful to signal the start of the control points.

Also the control points should have some kind of separator themselves, as a sequence of 4 values that are actually two pairs is confusing to parse (as a human).

@noamr
Copy link
Collaborator

noamr commented Aug 1, 2024

@noamr Ordering alone with a long sequence of length values is hard to understand (this is one of the problems with the existing SVG paths syntax), so I think having a keyword here is helpful to signal the start of the control points.

Also the control points should have some kind of separator themselves, as a sequence of 4 values that are actually two pairs is confusing to parse (as a human).

Yea, using / as a separator in the example

@noamr
Copy link
Collaborator

noamr commented Aug 1, 2024

@fantasai the thing with any of these words is that they collide with the by/to that represents absolute vs relative. So using order with a separator like / instead and still allowing by/to seemed the least verbose.

@smfr
Copy link
Contributor

smfr commented Aug 1, 2024

See also #10666

@noamr
Copy link
Collaborator

noamr commented Oct 1, 2024

Seems like in the other discussion with kept being what both myself and @smfr defaulted to. Perhaps this is the right word?

Proposing the following to finish up the bezier curve saga:

  • with is the word
  • We use / to separate between the two control points in a cubic bezier, no need for it in quadratic/smooth curves.

@smfr @tabatkins @fantasai what say you?

@smfr
Copy link
Contributor

smfr commented Oct 1, 2024

Could you type out some examples of the various absolute/relative versions? I think this matches what I suggested at #10644 (comment)

@tabatkins
Copy link
Member

Okay, so curve to 10px 10px with 20px 20 / 0px 0px?

And yeah, that seems to match @smfr's suggestion in #10644, so this sounds good.

@noamr
Copy link
Collaborator

noamr commented Oct 1, 2024

Okay, so curve to 10px 10px with 20px 20 / 0px 0px?

Exactly

And yeah, that seems to match @smfr's suggestion in #10644, so this sounds good.

I stole this proposal from that comment (or more like, formalized that comment into a proposed syntax).

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

No branches or pull requests

5 participants