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

<span> not specified as allowed descendant of <coordinates> #215

Open
Malvoz opened this issue Sep 11, 2021 · 3 comments
Open

<span> not specified as allowed descendant of <coordinates> #215

Malvoz opened this issue Sep 11, 2021 · 3 comments

Comments

@Malvoz
Copy link
Member

Malvoz commented Sep 11, 2021

Coordinate positions can be wrapped in <span>s, as such the content model of <coordinates> should be updated to allow it.

@Malvoz
Copy link
Member Author

Malvoz commented Sep 11, 2021

Going a bit off topic:

Span elements - as defined in HTML - can take phrasing content, so I guess MapML would have to define its own <span> that has a restricted content model for coordinate positions? That doesn't seem right, shouldn't something new be used instead of <span>?

@prushforth
Copy link
Member

<span> is semantically neutral, AFAICT, so it would not be ideal to have to add a map-specific version of it, although we will have to update our schema and spec to include it, which might get messy, tbd.

@Malvoz
Copy link
Member Author

Malvoz commented Sep 12, 2021

My concern is that we're reusing HTML elements although we expect them to behave or be used differently.

For example, <iframe> is phrasing content, where:

<p>
  <span><iframe></iframe></span>
</p>

is valid HTML.

But:

<coordinates>
  <span><iframe></iframe></span>
</coordinates>

is invalid MapML.

So <span> doesn't seem to be the same thing in HTML and MapML. SVG has <tspan>, why did they not (re)use and define <span>? Perhaps because its content model is different, and they wanted to avoid confusing authors/implementers?

I think this suggests we need a new <cspan> (coordinate span) element for use in <coordinate>.

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

No branches or pull requests

2 participants