Commit Graph

3383 Commits

Author SHA1 Message Date
vsavkin 8daa9b202d cleanup(testing): create top level files for mocks
Closes #5381
2015-11-24 19:29:52 +00:00
vsavkin 89eefcd7b5 cleanup(tooling): move tooling to the browser platform and rename profile into instrumentation
BREAKING CHANGE

Before

import * as p from 'angular2/profile';
import * as t from 'angular2/tools';

After

import * as p from 'angular2/instrumentation';
import * as t from 'angular2/platform/browser';
2015-11-24 19:29:52 +00:00
Tim Blasi 9ae171e0c8 refactor(dart/transform): Improve logging
Ensure that, where possible, log messages include an [AssetId].

Closes #5369
2015-11-24 18:41:24 +00:00
Alex Rickabaugh cee67e6fe0 Revert "feat(router): allow linking to auxiliary routes"
This reverts commit 0b1ff2db9e.
2015-11-23 16:34:40 -08:00
Alex Rickabaugh a3353a5e28 Revert "test(router): remove View decorator in router link fixtures"
This reverts commit 422a7b18f6.
2015-11-23 16:34:06 -08:00
Alex Rickabaugh c5294c77d9 Revert "refactor(router): improve recognition and generation pipeline"
This reverts commit cf7292fcb1.

This commit triggered an existing race condition in Google code. More work is needed on the Router to fix this condition before this refactor can land.
2015-11-23 16:26:47 -08:00
vsavkin ba64b5ea5a fix(forms): scope value accessors, validators, and async validators to self
Closes #5440
2015-11-23 23:48:54 +00:00
mlaval 230aad4047 chore(build): remove iOS9 from CI
Closes #5409
2015-11-23 22:44:49 +00:00
Matias Niemelä 564642d859 chore(core): rename `classname` to `className`
Closes #5371
2015-11-23 22:43:01 +00:00
Matias Niemelä 87549c77d4 chore(core): proper camelcasing for `styleName` and `styleValue` 2015-11-23 22:43:01 +00:00
Matias Niemelä fad354904d test(matchers): add support for `toHaveCssStyle` matcher 2015-11-23 22:43:01 +00:00
Rob Wormald e1d7bdcfe7 fix(http): Fix all requests defaulting to Get
Honor method parameter passed to http.request().

Closes #5309

Closes #5397
2015-11-23 22:17:13 +00:00
Rob Wormald 46fc153f39 fix(http): return URL in Response
Attach reponseURL or X-Request-URL to Response.

Closes  #5165
2015-11-23 22:17:13 +00:00
Rob Wormald 4332ccf72c fix(http): return Response headers
Properly parse and add response Headers to Response.

Closes #5237
2015-11-23 22:17:13 +00:00
Rob Wormald 201f189d0e fix(http): error on non-200 status codes
BREAKING CHANGE:

previously http would only error on network errors to match the fetch
specification. Now status codes less than 200 and greater than 299 will
cause Http's Observable to error.

Closes #5130.
2015-11-23 22:17:13 +00:00
Tim Blasi a35a93d0da chore(analytics): Include all of angular2 in hello_world
Import dependencies from `angular2/angular2.dart` in `hello_world` to
ensure that any size regressions are caught by our checks.

Update to avoid regressions like #5419.

Closes #5394
2015-11-23 20:10:04 +00:00
Tim Blasi 163164cb79 chore(analytics): Travis job testing Dart payload size
Add a job to the Travis build matrix that checks the size of the
`hello_world` app against targets hard-coded in the gulpfile.

Closes #5314
2015-11-23 20:10:04 +00:00
Tim Blasi 31f85f0297 chore(analytics): Build hello_world, check constraints
Create gulp targets to build `hello_world` and check its gzipped size
against size constraints.

See #5312, #5314
2015-11-23 20:10:04 +00:00
Tim Blasi 225b9d306b chore(analytics): Generalize file size analytics
Move file size analytics code into a reusable module.

See #5312, #5314
2015-11-23 20:10:04 +00:00
Tim Ruffles 9ca8a35553 docs(core): @View annotations are no longer mandatory
@View is [now optional](angular@bd31b01).

Closes #5413
2015-11-23 19:55:43 +00:00
mlaval 5806babb0b chore(build): increase timeout of the 5 most flaky tests
Closes #5410
2015-11-23 19:23:25 +00:00
vsavkin 30d35b5046 fix(build): do not reexport compiler from angular2/angular2
Closes #5422
2015-11-23 18:57:15 +00:00
Alex Rickabaugh 88afae15a8 chore(ci): Allow failures in Dart dev channel test until dartdoc bug is fixed. 2015-11-23 09:54:19 -08:00
Brian Ford cf7292fcb1 refactor(router): improve recognition and generation pipeline
This is a big change. @matsko also deserves much of the credit for the implementation.

Previously, `ComponentInstruction`s held all the state for async components.
Now, we introduce several subclasses for `Instruction` to describe each type of navigation.

BREAKING CHANGE:

Redirects now use the Link DSL syntax. Before:

```
@RouteConfig([
  { path: '/foo', redirectTo: '/bar' },
  { path: '/bar', component: BarCmp }
])
```

After:

```
@RouteConfig([
  { path: '/foo', redirectTo: ['Bar'] },
  { path: '/bar', component: BarCmp, name: 'Bar' }
])
```

BREAKING CHANGE:

This also introduces `useAsDefault` in the RouteConfig, which makes cases like lazy-loading
and encapsulating large routes with sub-routes easier.

Previously, you could use `redirectTo` like this to expand a URL like `/tab` to `/tab/posts`:

@RouteConfig([
  { path: '/tab', redirectTo: '/tab/users' }
  { path: '/tab', component: TabsCmp, name: 'Tab' }
])
AppCmp { ... }

Now the recommended way to handle this is case is to use `useAsDefault` like so:

```
@RouteConfig([
  { path: '/tab', component: TabsCmp, name: 'Tab' }
])
AppCmp { ... }

@RouteConfig([
  { path: '/posts', component: PostsCmp, useAsDefault: true, name: 'Posts' },
  { path: '/users', component: UsersCmp, name: 'Users' }
])
TabsCmp { ... }
```

In the above example, you can write just `['/Tab']` and the route `Users` is automatically selected as a child route.

Closes #4170
Closes #4490
Closes #4694
Closes #5200

Closes #5352
2015-11-20 23:18:43 +00:00
Brian Ford 422a7b18f6 test(router): remove View decorator in router link fixtures 2015-11-20 23:18:43 +00:00
Brian Ford 0b1ff2db9e feat(router): allow linking to auxiliary routes
Closes #4694
2015-11-20 23:18:43 +00:00
Yegor Jbanov a43ed79ee7 feat(parser): allows users install custom AST transformers
Closes #5382
2015-11-20 19:46:02 +00:00
vsavkin 125fa3885e cleanup: removes the render and lifecycle_hooks modules
BREAKING CHANGE

Before

import {Renderer} from 'angular2/render';

After

import {Renderer} form 'angular2/core';

Closes #5367
2015-11-20 19:16:38 +00:00
Olivier Combe ae58934d52 docs(async): adding type to EventEmitter now that it is generic
Closes #5391
2015-11-20 00:20:12 +00:00
vsavkin 3c8fa8c50d cleanup: move DomAdapter from angular2/core into angular2/platform/common_dom
BREAKING CHANGE

Before

import {DomAdapter} from 'angular2/core';

After

import {DomAdapter} from 'angular2/platform/common_dom';

Closes #5370
2015-11-20 00:14:24 +00:00
Marc Laval 4d59985b74 chore(build): use Chrome by default for all JS tests
Fixes #5380

Closes #5387
2015-11-19 23:27:42 +00:00
Olivier Chafik 4e12b0831e Make Angular2 transformers lazy in debug mode when option `lazy_transformers: true` is set.
This make apps to load quicker with pub serve (only builds what is
needed).
Note that lazy transformers seem to make pub build slower, so we wrap
transformers to force them to be eager in release mode.

Closes #5372
2015-11-19 20:58:12 +00:00
vsavkin 5ba9ced1ab cleanup(core): stop reexporting angular2/common from angular2/core
All common directives, forms, and pipes have been moved out of angular2/core,
but we kept reexporting them to make transition easier.

This commit removes the reexports.

BREAKING CHANGE

Before

import {NgIf} from 'angular2/core';

After

import {NgIf} from 'angular2/common';

Closes #5362
2015-11-19 19:54:27 +00:00
Victor Berchet 36a423fac8 feat(Compiler): case sensitive html parser
close #4417
Closes #5264
2015-11-19 18:55:04 +00:00
Tobias Bosch adb87562bb feat(Compiler): case sensitive html parser 2015-11-19 18:55:04 +00:00
Tim Blasi 0db02523d3 fix(dart/transform): Omit bootstrap.dart in ng_deps
Special-case to avoid copying the bootstrap{,_static}.dart
import when creating `.ng_deps.dart` files.

Closes #5315

Closes #5348
2015-11-18 22:46:29 +00:00
vsavkin 3c43a8c549 feat(bootstrap): add platform and app initializers
Often some init logic needs to run when a platform or an application is boostrapped.
For example, boostraping a platform requires initializing the dom adapter.
Now, it can be done as follows:

new Provider(PLATFORM_INITIALIZER, {useValue: initDomAdapter, multi: true}),

All platform initializers will be run after the platform injector has been created.

Similarly, all application initializers will be run after the app injector has been
created.

Closes #5355
2015-11-18 22:22:32 +00:00
Rob Wormald 3fa287aae2 refactor(EventEmitter): rename .next() to .emit()
BREAKING CHANGE:

EventEmitter#next(value) is deprecated, use EventEmitter#emit(value)
instead.

Closes #4287

Closes #5302
2015-11-18 22:16:40 +00:00
Jeremy Elbourn 929abb9aa3 chore(router): add tests for interaction between router-outer and
@ViewChild.

Closes #5164
2015-11-18 21:23:08 +00:00
Pawel Kozlowski 837efc2a0f chore(bundles): properly publish router.min.js bundle
Fixes #5244

Closes #5253
2015-11-18 19:13:23 +00:00
Yegor Jbanov 3eced6e1a9 chore(publish): use pub/npm_prepare.sh script to prep published builds
Closes #5356
2015-11-18 19:02:51 +00:00
Yegor Jbanov c53a63acca chore(build): spin off pub_prepare.sh from pub_publish.sh 2015-11-18 19:02:51 +00:00
Yegor Jbanov 621fa490c7 chore(build): spin off npm_prepare.sh from npm_publish.sh 2015-11-18 19:02:51 +00:00
Yegor Jbanov 9691c045a7 chore(build): move publish-build-artifacts.sh to scripts/publish 2015-11-18 19:02:51 +00:00
mlaval c855c5ddc2 chore(saucelabs): update browser versions
Closes #5336
2015-11-18 18:33:09 +00:00
vsavkin 2c8fcec432 refactor(core): move render/dom from core
Currently, core depends on DomRenderer, which depends on the browser.
This means that if you depend on angular2/core, you will always
pull in the browser dom adapter and the browser render, regardless
if you need them or not.

This PR moves the browser dom adapter and the browser renderer out of core.

BREAKING CHANGE

If you import browser adapter or dom renderer directly (not via angular2/core),
you will have to change the import path.
2015-11-17 15:53:55 -08:00
Yegor Jbanov 60a2bbb226 chore(build): git config prior to committing 2015-11-17 14:57:22 -08:00
Naomi Black d013fc7604 docs(cleanup): fix bad h3 markup and normalize headings
Closes #5341
2015-11-17 22:10:20 +00:00
Yegor Jbanov dd1e212402 chore(build): revert presubmit-queue-setup.sh; fix git login in publish-build-artifacts.sh 2015-11-17 13:53:57 -08:00
Brian Ford ac38812809 fix(router): apply APP_BASE_HREF when using PathLocationStrategy
Correctly initializes APP_BASE_HREF, and falls back to the `<base>` tag in the absence
of an APP_BASE_HREF provider.

Closes #5028
2015-11-17 21:19:22 +00:00