Skip to content

Conversation

@eemeli
Copy link
Collaborator

@eemeli eemeli commented Nov 17, 2024

See #916 for some of the preceding discussion.

In addition to changing the directionality of a placeholder, we should treat an explicitly set u:dir option as a request to isolate the placeholder, even if the direction matches the message's direction.

This requires a small change to our default bidi strategy.

The inheritance of the option is not specified when it's set on a value that's used as a function operand, so e.g. a message like

.local $world = {world :string u:dir=ltr}
{{hello {$world :string}}}

might or might not have the placeholder isolated (depending on the implementation), while it would always be isolated in messages like

hello {world :string u:dir=ltr}

and

.local $world = {world :string u:dir=ltr}
{{hello {$world}}}

@eemeli eemeli added Agenda+ Requested for upcoming teleconference formatting Issue pertains to the formatting section of the spec labels Nov 17, 2024
@eemeli eemeli requested a review from aphillips November 17, 2024 14:01
Copy link
Member

@aphillips aphillips left a comment

Choose a reason for hiding this comment

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

I think this is an important and quite useful improvement.

]
},
{
"src": ".local $world = {world :string u:dir=ltr u:id=foo} {{hello {$world}}}",
Copy link
Member

Choose a reason for hiding this comment

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

This is intended as the transitivity text, I think? Should we have one with mulitple .local declarations? or .input followed by .local?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Eh, not sure if it's necessary. I think the important part is making sure that moving the option from the placeholder to a declaration works.

Co-authored-by: Addison Phillips <[email protected]>
Copy link
Member

@aphillips aphillips left a comment

Choose a reason for hiding this comment

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

LGTM

@aphillips aphillips merged commit 5ca5247 into main Nov 18, 2024
2 checks passed
@aphillips aphillips deleted the udir-isolates branch November 18, 2024 17:58
eemeli added a commit to messageformat/messageformat that referenced this pull request Nov 19, 2024
XM5jDcsHTyGJtQqlCi added a commit to XM5jDcsHTyGJtQqlCi/messageformat that referenced this pull request Oct 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Agenda+ Requested for upcoming teleconference formatting Issue pertains to the formatting section of the spec

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants