From ad7f1c4b9189c974f63b75a4799f43d556dd6ac6 Mon Sep 17 00:00:00 2001 From: Ed Carroll Date: Tue, 4 Jul 2017 13:35:16 +0100 Subject: [PATCH] chore: Bumped version number --- package-lock.json | 18 ++++++------------ package.json | 6 +++--- scripts/bundle.js | 2 +- .../services/localization.service.ts | 11 +++++++---- 4 files changed, 17 insertions(+), 20 deletions(-) diff --git a/package-lock.json b/package-lock.json index 1808f358a..1ae4425d6 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "ng2-semantic-ui", - "version": "0.9.1", + "version": "0.9.2", "lockfileVersion": 1, "dependencies": { "@angular/cli": { @@ -86,10 +86,10 @@ "integrity": "sha1-tr5Y2FfUH4mZdR1rvD0h6EvJd8o=", "dev": true }, - "@types/deep-extend": { - "version": "0.4.30", - "resolved": "https://registry.npmjs.org/@types/deep-extend/-/deep-extend-0.4.30.tgz", - "integrity": "sha1-b67Uhmh+vISA0TDZyVKIhWlK8OA=", + "@types/extend": { + "version": "2.0.30", + "resolved": "https://registry.npmjs.org/@types/extend/-/extend-2.0.30.tgz", + "integrity": "sha1-WMyT9iHQo1jT/sm9bnObxg7H4nU=", "dev": true }, "@types/jasmine": { @@ -1369,11 +1369,6 @@ "integrity": "sha1-9lNNFRSCabIDUue+4m9QH5oZEpA=", "dev": true }, - "deep-extend": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/deep-extend/-/deep-extend-0.5.0.tgz", - "integrity": "sha1-bvSgmwX5iw41jW2T1Mo8rsZnKAM=" - }, "deep-is": { "version": "0.1.3", "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.3.tgz", @@ -1903,8 +1898,7 @@ "extend": { "version": "3.0.1", "resolved": "https://registry.npmjs.org/extend/-/extend-3.0.1.tgz", - "integrity": "sha1-p1Xqe8Gt/MWjHOfnYtuq3F5jZEQ=", - "dev": true + "integrity": "sha1-p1Xqe8Gt/MWjHOfnYtuq3F5jZEQ=" }, "external-editor": { "version": "2.0.4", diff --git a/package.json b/package.json index 1e786694c..f3caccd11 100644 --- a/package.json +++ b/package.json @@ -3,7 +3,7 @@ "main": "bundles/ng2-semantic-ui.umd.min.js", "module": "dist/public.js", "typings": "dist/public.d.ts", - "version": "0.9.1", + "version": "0.9.2", "description": "Angular 2 Semantic UI Components", "repository": { "type": "git", @@ -48,8 +48,8 @@ "@types/popper.js": "^1.10.0", "bowser": "^1.7.0", "date-fns": "2.0.0-alpha.1", - "deep-extend": "^0.5.0", "element-closest": "^2.0.2", + "extend": "^3.0.1", "popper.js": "^1.10.6", "rxjs": "^5.0.1" }, @@ -61,7 +61,7 @@ "@angular/platform-browser": "^4.1.3", "@angular/platform-browser-dynamic": "^4.1.3", "@angular/router": "^4.1.3", - "@types/deep-extend": "^0.4.30", + "@types/extend": "^2.0.30", "@types/jasmine": "^2.5.53", "@types/prismjs": "~1.4.18", "codelyzer": "^3.0.0", diff --git a/scripts/bundle.js b/scripts/bundle.js index 9bd330055..beb4aaa78 100644 --- a/scripts/bundle.js +++ b/scripts/bundle.js @@ -21,7 +21,7 @@ const defaultPlugins = [ "node_modules/popper.js/**", "node_modules/date-fns/**", "node_modules/bowser/src/bowser.js", - "node_modules/deep-extend/**" + "node_modules/extend/**" ] }) ] diff --git a/src/behaviors/localization/services/localization.service.ts b/src/behaviors/localization/services/localization.service.ts index 05429efed..0f79e4266 100644 --- a/src/behaviors/localization/services/localization.service.ts +++ b/src/behaviors/localization/services/localization.service.ts @@ -1,15 +1,18 @@ import { Injectable, EventEmitter } from "@angular/core"; import { ILocaleValues, IPartialLocaleValues, RecursivePartial } from "../interfaces/values"; import enGB from "../locales/en-GB"; - -// Oh rollup. -import * as $deepExtend from "deep-extend"; -const deepExtend:(target:T, source:U) => T & U = ($deepExtend as any).default || $deepExtend; +import * as $extend from "extend"; function deepClone(obj:T):T { return JSON.parse(JSON.stringify(obj)); } +function deepExtend(target:T, source:U):T & U { + // Rollup... + const extend = ($extend as any).default || $extend; + return extend(true, target, source); +} + function lang(language:string):string { return language.toLowerCase().replace("-", ""); }