angular-docs-cn/packages/compiler/test/ml_parser
Pete Bacon Darwin 0ddf0c4895 fix(compiler): do not remove whitespace wrapping i18n expansions (#31962)
Similar to interpolation, we do not want to completely remove whitespace
nodes that are siblings of an expansion.

For example, the following template

```html
<div>
  <strong>items left<strong> {count, plural, =1 {item} other {items}}
</div>
```

was being collapsed to

```html
<div><strong>items left<strong>{count, plural, =1 {item} other {items}}</div>
```

which results in the text looking like

```
items left4
```

instead it should be collapsed to

```html
<div><strong>items left<strong> {count, plural, =1 {item} other {items}}</div>
```

which results in the text looking like

```
items left 4
```

---

**Analysis of the code and manual testing has shown that this does not cause
the generated ids to change, so there is no breaking change here.**

PR Close #31962
2019-08-09 12:03:50 -07:00
..
util test(ivy): update //packages/compiler tests for Ivy (#27301) 2018-11-29 21:31:35 -08:00
BUILD.bazel test(ivy): update //packages/compiler tests for Ivy (#27301) 2018-11-29 21:31:35 -08:00
ast_serializer_spec.ts refactor(compiler): use `options` argument for parsers (#28055) 2019-02-12 20:58:27 -08:00
ast_spec_utils.ts build: update npm dependencies (#19328) 2017-09-22 13:20:52 -07:00
html_parser_spec.ts fix(core): don't wrap `<tr>` and `<col>` elements into a required parent (#29219) 2019-03-14 03:07:01 -04:00
html_whitespaces_spec.ts fix(compiler): do not remove whitespace wrapping i18n expansions (#31962) 2019-08-09 12:03:50 -07:00
icu_ast_expander_spec.ts refactor(compiler): use `options` argument for parsers (#28055) 2019-02-12 20:58:27 -08:00
lexer_spec.ts fix(compiler): do not remove whitespace wrapping i18n expansions (#31962) 2019-08-09 12:03:50 -07:00