8000 Use "placeholder" consistently; remove mentions of "placeable". by stasm · Pull Request #281 · unicode-org/message-format-wg · GitHub
[go: up one dir, main page]

Skip to content

Use "placeholder" consistently; remove mentions of "placeable". #281

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

Merged
merged 1 commit into from
Jun 6, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions spec/message.ebnf
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@ Selector ::= (Variable '=')? '{' Expression '}'
/* Variants and Patterns */
Variant ::= VariantKey* Pattern
VariantKey ::= String | Nmtoken | '*'
Pattern ::= '[' (Text | Placeable)* ']' /* ws: explicit */
Pattern ::= '[' (Text | Placeholder)* ']' /* ws: explicit */

/* Placeables */
Placeable ::= '{' (Expression | MarkupStart | MarkupEnd)? '}'
/* Placeholders */
Placeholder ::= '{' (Expression | MarkupStart | MarkupEnd)? '}'

/* Expressions */
Expression ::= Operand Annotation? | Annotation
Expand Down
12 changes: 6 additions & 6 deletions spec/syntax.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
1. [Preamble](#preamble)
1. [Variants](#variants)
1. [Patterns](#patterns)
1. [Placeables](#placeables)
1. [Placeholders](#placeholders)
Copy link
Collaborator

Choose a reason for hiding this comment

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

Might make sense for us to remove the index for now, to make editing easier. But that's a separate change from this PR.

1. [Expressions](#expressions)
1. [Markup Elements](#markup-elements)
1. [Tokens](#tokens)
Expand Down Expand Up @@ -143,7 +143,7 @@ plucking the first name from the object representing a person:

### Markup Elements

A message with two markup-like element placeables, `button` and `link`,
A message with two markup-like element placeholders, `button` and `link`,
which the runtime can use to construct a document tree structure for a UI framework.

[{button}Submit{/button} or {link}cancel{/link}.]
Expand Down Expand Up @@ -306,7 +306,7 @@ This serves 3 purposes:
are translatable and which ones are part of the formatting logic definition.

```ebnf
Pattern ::= '[' (Text | Placeable)* ']' /* ws: explicit */
Pattern ::= '[' (Text | Placeholder)* ']' /* ws: explicit */
```

Examples:
Expand All @@ -315,12 +315,12 @@ Examples:
[Hello, world!]
```

### Placeables
### Placeholders

A placeable is a placeholder for an expression or an open or close markup element.
Placeholders can contain expressions and markup elements.

```ebnf
Placeable ::= '{' (Expression | MarkupStart | MarkupEnd) '}'
Placeholder ::= '{' (Expression | MarkupStart | MarkupEnd) '}'
```

### Expressions
Expand Down
0