Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: angular-ui/ui-router
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 1.0.4
Choose a base ref
...
head repository: angular-ui/ui-router
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 1.0.5
Choose a head ref
  • 7 commits
  • 8 files changed
  • 2 contributors

Commits on Jun 22, 2017

  1. fix(ngStrictDi): Detect strictDI violations in resolve

    In some scenarios, the `$injector` would be asked to annotate without
    providing it with the current `strictDi` value, making resolvables not
    complain about missing annotations.
    abyx authored and christopherthielen committed Jun 22, 2017
    Copy the full SHA
    3c3fd26 View commit details

Commits on Jun 29, 2017

  1. Copy the full SHA
    ea69994 View commit details
  2. Copy the full SHA
    5131e6c View commit details
  3. Copy the full SHA
    0718344 View commit details
  4. Updated CHANGELOG

    christopherthielen committed Jun 29, 2017
    Copy the full SHA
    d49336e View commit details
  5. Release 1.0.5

    christopherthielen committed Jun 29, 2017
    Copy the full SHA
    c5d588d View commit details
  6. Release 1.0.5

    christopherthielen committed Jun 29, 2017
    Copy the full SHA
    1d98ab8 View commit details
Showing with 458 additions and 264 deletions.
  1. +25 −2 CHANGELOG.md
  2. +1 −1 bower.json
  3. +3 −3 package.json
  4. +15 −2 scripts/artifact_tagging.js
  5. +1 −1 src/services.ts
  6. +2 −2 src/stateFilters.ts
  7. +8 −8 src/templateFactory.ts
  8. +403 −245 yarn.lock
27 changes: 25 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,26 @@
<a name="1.0.5"></a>
## [1.0.5](https://github.com/angular-ui/ui-router/compare/1.0.4...1.0.5) (2017-06-29)

Updated to @uirouter/core 5.0.5 and addressed typescript 2.4 breaking changes

## Changes in `@uirouter/core` between versions [5.0.3 and 5.0.5](https://github.com/ui-router/core/compare/5.0.3...5.0.5) (2017-06-29)


### Bug Fixes

* **future:** Allow future states to specify a `parent:` ([828fe1b](https://github.com/ui-router/core/commit/828fe1b))
* **typescript:** Update to typescript 2.4 ([ce1669b](https://github.com/ui-router/core/commit/ce1669b))
* **view:** only sync views which are of the same name *and type* ([c48da4a](https://github.com/ui-router/core/commit/c48da4a))


### Features

* **invalidTransition:** Better error messaging when param values are invalid ([2a15d1a](https://github.com/ui-router/core/commit/2a15d1a))
* **trace:** Trace view synchronization. Allow trace.enable(...string) ([284392d](https://github.com/ui-router/core/commit/284392d))
* **urlMatcher:** add support for multiline urls ([5b11ce0](https://github.com/ui-router/core/commit/5b11ce0))



<a name="1.0.4"></a>
## [1.0.4](https://github.com/angular-ui/ui-router/compare/1.0.3...1.0.4) (2017-06-09)

@@ -97,8 +120,8 @@
UI-Router for AngularJS version 1.0.0 updates `ui-router-core@3.1.0` to `@uirouter/core@5.0.1`.
Please keep reading to see if the breaking changes from core between 3.1.0 and 5.0.1 affect you.

### @uirouter/core changes
# [5.0.0](https://github.com/ui-router/core/compare/3.1.0...5.0.1) (2017-04-30)
### `@uirouter/core` changes
# [diff to 3.1.0](https://github.com/ui-router/core/compare/3.1.0...5.0.1) (2017-04-30)

### Bug Fixes

2 changes: 1 addition & 1 deletion bower.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"name":"angular-ui-router","description":"State-based routing for AngularJS","license":"MIT","main":"./release/angular-ui-router.js","dependencies":{"angular":">= 1.2.0"},"ignore":["**/.*","**/tsconfig.json","**/tsconfig.typedoc.json","**/webpack.config.js","**/node_modules","package.json","scripts","test","src"],"version":"1.0.4"}
{"name":"angular-ui-router","description":"State-based routing for AngularJS","license":"MIT","main":"./release/angular-ui-router.js","dependencies":{"angular":">= 1.2.0"},"ignore":["**/.*","**/tsconfig.json","**/tsconfig.typedoc.json","**/webpack.config.js","**/node_modules","package.json","scripts","test","src"],"version":"1.0.5"}
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@uirouter/angularjs",
"description": "State-based routing for AngularJS 1.x",
"version": "1.0.4",
"version": "1.0.5",
"scripts": {
"clean": "shx rm -rf lib lib-esm _doc build release *.log",
"build": "tsc && tsc -m es6 --outDir lib-esm && npm run fixdts",
@@ -69,7 +69,7 @@
"jsnext:main": "lib-esm/index.js",
"typings": "lib/index.d.ts",
"dependencies": {
"@uirouter/core": "5.0.3"
"@uirouter/core": "5.0.5"
},
"peerDependencies": {
"angular": ">=1.2.0"
@@ -115,7 +115,7 @@
"typedoc-plugin-external-module-name": "^1.0.2",
"typedoc-plugin-internal-external": "^1.0.0",
"typedoc-plugin-ui-router": "^1.0.0",
"typescript": "^2.1.4",
"typescript": "~2.4.0",
"ui-router-typedoc-themes": "^1.0.1",
"watch": "^0.18.0",
"webpack": "1.x",
17 changes: 15 additions & 2 deletions scripts/artifact_tagging.js
Original file line number Diff line number Diff line change
@@ -23,7 +23,20 @@ if (isNarrow && readlineSync.keyInYN('Widen @uirouter/core dependency from ' + c
widen = false;
}

let tagname = `${version}-hybrid-${hybridVersion}`;
const YYYYMMDD = (function() {
var date = new Date();
var year = date.getFullYear();

var month = date.getMonth() + 1;
month = (month < 10 ? "0" : "") + month;

var day = date.getDate();
day = (day < 10 ? "0" : "") + day;

return year + month + day;
})();

let tagname = `SNAPSHOT-${YYYYMMDD}`;
tagname += readlineSync.question(`Suffix for tag ${tagname} (optional)?`);

if (!readlineSync.keyInYN(`Ready to publish ${tagname} tag?`)) {
@@ -36,7 +49,7 @@ util.ensureCleanMaster('master');
_exec(`git checkout -b ${tagname}-prep`);

pkg.dependencies['@uirouter/core'] = widenedDep;
pkg.version = tagname;
// pkg.version = tagname;

fs.writeFileSync("package.json", JSON.stringify(pkg, undefined, 2));
_exec('git commit -m "Widening @uirouter/core dependency range to ' + widenedDep + '" package.json');
2 changes: 1 addition & 1 deletion src/services.ts
Original file line number Diff line number Diff line change
@@ -96,7 +96,7 @@ function runBlock($injector: IInjectorService, $q: IQService, $uiRouter: UIRoute
.map(x => x.$$state().resolvables)
.reduce(unnestR, [])
.filter(x => x.deps === "deferred")
.forEach(resolvable => resolvable.deps = $injector.annotate(resolvable.resolveFn));
.forEach(resolvable => resolvable.deps = $injector.annotate(resolvable.resolveFn, $injector.strictDi));
}

// $urlRouter service and $urlRouterProvider
4 changes: 2 additions & 2 deletions src/stateFilters.ts
Original file line number Diff line number Diff line change
@@ -15,7 +15,7 @@ import { Obj, StateService, StateOrName } from "@uirouter/core";
*/
$IsStateFilter.$inject = ['$state'];
export function $IsStateFilter($state: StateService) {
var isFilter: any = function(state: StateOrName, params: Obj, options?: { relative?: boolean }) {
var isFilter: any = function(state: StateOrName, params: Obj, options?: { relative?: StateOrName }) {
return $state.is(state, params, options);
};
isFilter.$stateful = true;
@@ -34,7 +34,7 @@ export function $IsStateFilter($state: StateService) {
*/
$IncludedByStateFilter.$inject = ['$state'];
export function $IncludedByStateFilter($state: StateService) {
var includesFilter: any = function(state: StateOrName, params: Obj, options: Obj) {
var includesFilter: any = function(state: StateOrName, params: Obj, options: { relative?: StateOrName }) {
return $state.includes(state, params, options);
};
includesFilter.$stateful = true;
16 changes: 8 additions & 8 deletions src/templateFactory.ts
Original file line number Diff line number Diff line change
@@ -42,19 +42,19 @@ export class TemplateFactory implements TemplateFactoryProvider {
* @return {string|object} The template html as a string, or a promise for
* that string,or `null` if no template is configured.
*/
fromConfig(config: Ng1ViewDeclaration, params: any, context: ResolveContext) {
fromConfig(config: Ng1ViewDeclaration, params: any, context: ResolveContext): Promise<{ template?: string, component?: string }> {
const defaultTemplate = "<ui-view></ui-view>";

const asTemplate = (result) => services.$q.when(result).then(str => ({ template: str }));
const asTemplate = (result) => services.$q.when(result).then(str => ({ template: str }));
const asComponent = (result) => services.$q.when(result).then(str => ({ component: str }));

return (
isDefined(config.template) ? asTemplate(this.fromString(config.template, params)) :
isDefined(config.templateUrl) ? asTemplate(this.fromUrl(config.templateUrl, params)) :
isDefined(config.templateProvider) ? asTemplate(this.fromProvider(config.templateProvider, params, context)) :
isDefined(config.component) ? asComponent(config.component) :
isDefined(config.componentProvider) ? asComponent(this.fromComponentProvider(config.componentProvider, params, context)) :
asTemplate(defaultTemplate)
isDefined(config.template) ? asTemplate(this.fromString(config.template, params)) :
isDefined(config.templateUrl) ? asTemplate(this.fromUrl(config.templateUrl, params)) :
isDefined(config.templateProvider) ? asTemplate(this.fromProvider(config.templateProvider, params, context)) :
isDefined(config.component) ? asComponent(config.component) :
isDefined(config.componentProvider) ? asComponent(this.fromComponentProvider(config.componentProvider, params, context)) :
asTemplate(defaultTemplate)
);
};

648 changes: 403 additions & 245 deletions yarn.lock

Large diffs are not rendered by default.