Chuck Jazdzewski
388afa414e
test(compiler): add integration like tests to compiler unit tests ( #14157 )
...
Closes PR #14157
PR Close #14157
2017-02-03 15:06:51 -06:00
Chuck Jazdzewski
69e14b500b
feat(compiler): generate type parameters for generic type references ( #14104 )
2017-02-01 09:29:51 -06:00
Alex Eagle
b4214d60a6
fix(compiler): allow expressions or functions in extends ( #14158 )
...
Fixes #14154
PR Close #14158
2017-01-31 18:35:10 -06:00
Victor Berchet
5921c872b6
fix(compiler): only lex messages that are needed by angular ( #14208 )
...
To avoid the lexer erroring on syntax not supported by Angular.
PR Close #14208
2017-01-31 16:21:55 -06:00
Victor Berchet
827c3fe199
fix(compiler): fix missing translations handling ( #14113 )
...
PR Close #14113
2017-01-27 12:12:06 -06:00
Gion Kunz
8775ab9495
feat(compiler): allow missing translations ( #14113 )
...
closes #13861
2017-01-27 12:10:59 -06:00
Victor Berchet
f7fba74c58
feat(compiler): do not parse xtb messages not needed by angular ( #14111 )
...
fixes #14046
PR Close #14111
2017-01-27 11:52:57 -06:00
Bowen Ni
665dde2e5c
refactor(compiler): improve error messages in aot compiler ( #14017 )
...
Previously aot compiler prints stack traces when it fails to resolve.
New behavior: aot compiler outputs the error message.
Example: https://gist.github.com/bowenni/a7fe81d916e8cd4a06b0e133436f40fb
PR Close #14017
2017-01-27 11:49:38 -06:00
Victor Berchet
05b2b49711
fix(compiler): allow empty translations for attributes ( #14085 )
...
fixes #13897
2017-01-25 17:43:19 -08:00
Victor Berchet
1c24271daf
refactor(compiler): [i18n] integrate review feedback
2017-01-24 14:47:04 -08:00
Victor Berchet
c3e5ddbe20
refactor(compiler): [i18n] move dedup and placeholder mapping to the MessageBundle
...
It makes implementing a `Serializer` simpler as implementations do not have to
care any more about message dedup and placeholder mapping.
2017-01-24 14:47:04 -08:00
Victor Berchet
d02eab498f
fix(compiler): [i18n] XMB/XTB placeholder names can contain only A-Z, 0-9, _n
...
There are restrictions on the character set that can be used for xmb and xtb
placeholder names.
However because changing the placeholder names would change the message IDs it
is not possible to add those restrictions to the names used internally. Then we
have to map internal name to public names when generating an xmb file and back
when translating using an xtb file.
Note for implementors of `Serializer`:
- When writing a file, the implementor should take care of converting the
internal names to public names while visiting the message nodes - this is
required because the original nodes are needed to compute the message ID.
- When reading a file, the implementor does not need to take care of the mapping
back to internal names as this is handled in the `I18nToHtmlVisitor` used by the
`TranslationBundle`.
fixes b/34339636
2017-01-24 14:47:04 -08:00
Victor Berchet
424e6c4cb9
fix(i18n): translate attributes inside elements marked for translation
...
fixes #13796
fixes #13814
2017-01-09 19:33:03 -05:00
Chuck Jazdzewski
d061adc02d
fix(compiler): avoid evaluating arguments to unknown decorators
...
Fixes #13605
2017-01-09 16:30:31 -05:00
Victor Berchet
e5c6bb4286
fix(Compiler): fix template binding parsing (*directive="-...")
...
fixes #13800
2017-01-09 15:00:40 -05:00
Victor Berchet
1bd04e95de
refactor: remove unused imports
2017-01-05 11:18:34 -08:00
Dzmitry Shylovich
6b02b80a03
fix(compiler): improve error message for undefined providers ( #13546 )
...
Closes #10835
2016-12-27 17:05:14 -08:00
Dzmitry Shylovich
2c0c86e3ce
fix(compiler): improve the error when template is not a string
...
Closes #8708
Closes #13377
2016-12-27 17:04:16 -08:00
Victor Berchet
0ac8e102de
test(i18n): add extraction to integration specs
...
Closes #13648 .
2016-12-27 15:32:54 -08:00
Victor Berchet
e74d8aaf92
fix(i18n): parse ICU messages while normalizing templates
...
Fixes:
- Inject the i18n specific HtmlParser into the directive normalizer,
- Parse ICU messages while normalizing templates,
- Normalize (visit) the content of ICU messages.
🎄 🎁 🎅
2016-12-27 15:32:43 -08:00
Victor Berchet
881eb894bc
fix(Compiler): allow "." in attribute selectors ( #13653 )
...
fixes #13645
2016-12-27 15:23:49 -08:00
Victor Berchet
eed83443b8
chore(tslint): update tslint to 4.x ( #13603 )
2016-12-27 14:55:58 -08:00
Dzmitry Shylovich
445ed43b9a
fix(compiler): throw an error for invalid provider ( #13544 )
...
Closes #8870
2016-12-27 14:02:28 -08:00
Tobias Bosch
9c697030e6
feat(compiler): generate proper reexports in .ngfactory.ts files to not need transitive deps for compiling .ngfactory.ts files. ( #13524 )
...
Note: This checks the constructors of `@Injectable` classes more strictly.
E.g this will fail now as the constructor argument has no `@Inject` nor is
the type of the argument a DI token.
```
@Injectable()
class MyService {
constructor(dep: string) {}
}
```
Last part of #12787
Closes #12787
2016-12-27 09:36:47 -08:00
Matias Niemelä
f49ab56160
fix(animations): always quote string map key values in AOT code ( #13602 )
2016-12-20 18:17:58 -08:00
Dzmitry Shylovich
c0f750af4e
fix(compiler): ignore @import in comments ( #13368 )
...
* refactor(compiler): clean up style url resolver
* fix(compiler): ignore @import in css comments
Closes #12196
2016-12-20 17:51:02 -08:00
Victor Berchet
e78508507d
fix(compiler): do not lex }} when interpolation is disabled ( #13531 )
...
* doc(compiler): fix the ICU expander API docs
* test(compiler): add lexer and parser specs
* fix(compiler): do not lex `}}` when interpolation is disabled
fix #13525
2016-12-16 15:33:16 -08:00
Victor Berchet
0fe3cd9a4c
fix(i18n): add a default example to xmb placeholders ( #13507 )
...
Otherwise the TC would not be able to load the message
2016-12-15 15:33:42 -08:00
Bowen Ni
f0e092515c
refactor(compiler): don't print stack trace on template parse errors ( #13390 )
2016-12-15 13:07:12 -08:00
Tobias Bosch
33910ddfc9
refactor(compiler): store metadata of top level symbols also in summaries ( #13289 )
...
This allows a build using summaries to not need .metadata.json files at all
any more.
Part of #12787
2016-12-15 09:12:40 -08:00