Skip to content

Commit

Permalink
Angular 8 update
Browse files Browse the repository at this point in the history
  • Loading branch information
bebo925 committed Aug 1, 2019
1 parent 9974937 commit 0b2892b
Show file tree
Hide file tree
Showing 11 changed files with 5,383 additions and 5,746 deletions.
File renamed without changes.
10,978 changes: 5,317 additions & 5,661 deletions package-lock.json

Large diffs are not rendered by default.

65 changes: 32 additions & 33 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,44 +12,43 @@
},
"private": true,
"dependencies": {
"@angular/animations": "^7.2.13",
"@angular/common": "^7.2.13",
"@angular/compiler": "^7.2.13",
"@angular/core": "^7.2.13",
"@angular/forms": "^7.2.13",
"@angular/http": "^7.2.13",
"@angular/platform-browser": "^7.2.13",
"@angular/platform-browser-dynamic": "^7.2.13",
"@angular/router": "^7.2.13",
"core-js": "^2.5.4",
"rxjs": "^6.5.1",
"zone.js": "^0.8.26"
"@angular/animations": "^8.2.0",
"@angular/common": "^8.2.0",
"@angular/compiler": "^8.2.0",
"@angular/core": "^8.2.0",
"@angular/forms": "^8.2.0",
"@angular/platform-browser": "^8.2.0",
"@angular/platform-browser-dynamic": "^8.2.0",
"@angular/router": "^8.2.0",
"core-js": "^3.1.4",
"rxjs": "^6.5.2",
"zone.js": "~0.9.1"
},
"devDependencies": {
"@angular-devkit/build-angular": "^0.13.8",
"@angular-devkit/build-ng-packagr": "~0.6.8",
"@angular/cli": "^7.3.8",
"@angular/compiler-cli": "^7.2.13",
"@angular/language-service": "^7.2.13",
"@types/jasmine": "~2.8.6",
"@angular-devkit/build-angular": "~0.802.0",
"@angular-devkit/build-ng-packagr": "~0.802.0",
"@angular/cli": "^8.2.0",
"@angular/compiler-cli": "^8.2.0",
"@angular/language-service": "^8.2.0",
"@types/jasmine": "~3.3.16",
"@types/jasminewd2": "~2.0.3",
"@types/node": "^8.10.46",
"@types/node": "^12.6.8",
"@types/text-encoding": "0.0.35",
"@types/w3c-web-usb": "^1.0.3",
"codelyzer": "~4.2.1",
"jasmine-core": "~2.99.1",
"codelyzer": "^5.0.1",
"jasmine-core": "~3.4.0",
"jasmine-spec-reporter": "~4.2.1",
"karma": "~1.7.1",
"karma-chrome-launcher": "~2.2.0",
"karma-coverage-istanbul-reporter": "~2.0.0",
"karma-jasmine": "~1.1.1",
"karma-jasmine-html-reporter": "^0.2.2",
"ng-packagr": "^3.0.0-rc.2",
"protractor": "~5.3.0",
"ts-node": "~5.0.1",
"tsickle": "^0.34.3",
"tslib": "^1.9.3",
"tslint": "~5.9.1",
"typescript": "3.1.6"
"karma": "~4.2.0",
"karma-chrome-launcher": "~3.0.0",
"karma-coverage-istanbul-reporter": "~2.1.0",
"karma-jasmine": "~2.0.1",
"karma-jasmine-html-reporter": "^1.4.2",
"ng-packagr": "^5.3.0",
"protractor": "~5.4.2",
"ts-node": "~8.3.0",
"tsickle": "^0.36.0",
"tslib": "^1.10.0",
"tslint": "~5.18.0",
"typescript": "3.5.3"
}
}
6 changes: 3 additions & 3 deletions projects/ng-thermal-print/package.json
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
{
"name": "ng-thermal-print",
"version": "0.1.1",
"version": "0.1.3",
"description": "An angular module to add thermal printing capabilities.",
"keywords": ["Angular", "Library", "Thermal", "Printer"],
"repository": {
"type": "git",
"url": "https://github.com/bebo925/ng-thermal-print"
},
"peerDependencies": {
"@angular/common": "^7.0.0-rc.0 || ^7.0.0",
"@angular/core": "^7.0.0-rc.0 || ^7.0.0"
"@angular/common": "^8.0.0-rc.0 || ^8.0.0",
"@angular/core": "^8.0.0-rc.0 || ^8.0.0"
}
}
4 changes: 2 additions & 2 deletions projects/ng-thermal-print/src/lib/builders/WebPrintBuilder.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,10 +43,10 @@ export class WebPrintBuilder extends PrintBuilder {
let fontSize;
switch (size) {
case 'large':
fontSize = 2
fontSize = 2;
break;
default:
fontSize = 'normal'
fontSize = 1;
break;
}
this.request += this.builder.createTextElement({ width: fontSize, height: fontSize });
Expand Down
3 changes: 1 addition & 2 deletions src/app/app.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,13 +32,12 @@ export class AppComponent {
this.printService.setDriver(this.usbPrintDriver);
}, error => {
console.log(error);

});
}

connectToWebPrint() {
this.webPrintDriver = new WebPrintDriver(this.ip);
this.printService.setDriver(this.webPrintDriver);
this.printService.setDriver(this.webPrintDriver, 'WebPRNT');
}

print(driver: PrintDriver) {
Expand Down
59 changes: 21 additions & 38 deletions src/polyfills.ts
Original file line number Diff line number Diff line change
Expand Up @@ -11,70 +11,53 @@
* automatically update themselves. This includes Safari >= 10, Chrome >= 55 (including Opera),
* Edge >= 13 on the desktop, and iOS 10 and Chrome on mobile.
*
* Learn more in https://angular.io/docs/ts/latest/guide/browser-support.html
* Learn more in https://angular.io/guide/browser-support
*/

/***************************************************************************************************
* BROWSER POLYFILLS
*/

/** IE9, IE10 and IE11 requires all of the following polyfills. **/
// import 'core-js/es6/symbol';
// import 'core-js/es6/object';
// import 'core-js/es6/function';
// import 'core-js/es6/parse-int';
// import 'core-js/es6/parse-float';
// import 'core-js/es6/number';
// import 'core-js/es6/math';
// import 'core-js/es6/string';
// import 'core-js/es6/date';
// import 'core-js/es6/array';
// import 'core-js/es6/regexp';
// import 'core-js/es6/map';
// import 'core-js/es6/weak-map';
// import 'core-js/es6/set';

/** IE10 and IE11 requires the following for NgClass support on SVG elements */
// import 'classlist.js'; // Run `npm install --save classlist.js`.

/** IE10 and IE11 requires the following for the Reflect API. */
// import 'core-js/es6/reflect';


/** Evergreen browsers require these. **/
// Used for reflect-metadata in JIT. If you use AOT (and only Angular decorators), you can remove.
import 'core-js/es7/reflect';


/**
* Web Animations `@angular/platform-browser/animations`
* Only required if AnimationBuilder is used within the application and using IE/Edge or Safari.
* Standard animation support in Angular DOES NOT require any polyfills (as of Angular 6.0).
**/
*/
// import 'web-animations-js'; // Run `npm install --save web-animations-js`.

/**
* By default, zone.js will patch all possible macroTask and DomEvents
* user can disable parts of macroTask/DomEvents patch by setting following flags
* because those flags need to be set before `zone.js` being loaded, and webpack
* will put import in the top of bundle, so user need to create a separate file
* in this directory (for example: zone-flags.ts), and put the following flags
* into that file, and then add the following code before importing zone.js.
* import './zone-flags.ts';
*
* The flags allowed in zone-flags.ts are listed here.
*
* The following flags will work for all browsers.
*
* (window as any).__Zone_disable_requestAnimationFrame = true; // disable patch requestAnimationFrame
* (window as any).__Zone_disable_on_property = true; // disable patch onProperty such as onclick
* (window as any).__zone_symbol__UNPATCHED_EVENTS = ['scroll', 'mousemove']; // disable patch specified eventNames
*
* in IE/Edge developer tools, the addEventListener will also be wrapped by zone.js
* with the following flag, it will bypass `zone.js` patch for IE/Edge
*
* (window as any).__Zone_enable_cross_context_check = true;
*
*/

// (window as any).__Zone_disable_requestAnimationFrame = true; // disable patch requestAnimationFrame
// (window as any).__Zone_disable_on_property = true; // disable patch onProperty such as onclick
// (window as any).__zone_symbol__BLACK_LISTED_EVENTS = ['scroll', 'mousemove']; // disable patch specified eventNames

/*
* in IE/Edge developer tools, the addEventListener will also be wrapped by zone.js
* with the following flag, it will bypass `zone.js` patch for IE/Edge
*/
// (window as any).__Zone_enable_cross_context_check = true;

/***************************************************************************************************
* Zone JS is required by default for Angular itself.
*/
import 'zone.js/dist/zone'; // Included with Angular CLI.



/***************************************************************************************************
* APPLICATION IMPORTS
*/
1 change: 0 additions & 1 deletion src/tsconfig.app.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
"extends": "../tsconfig.json",
"compilerOptions": {
"outDir": "../out-tsc/app",
"module": "es2015",
"types": []
},
"exclude": [
Expand Down
1 change: 0 additions & 1 deletion src/tsconfig.spec.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
"extends": "../tsconfig.json",
"compilerOptions": {
"outDir": "../out-tsc/spec",
"module": "commonjs",
"types": [
"jasmine",
"node"
Expand Down
4 changes: 3 additions & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,15 @@
"compileOnSave": false,
"compilerOptions": {
"baseUrl": "./",
"downlevelIteration": true,
"module": "esnext",
"outDir": "./dist/out-tsc",
"sourceMap": true,
"declaration": true,
"moduleResolution": "node",
"emitDecoratorMetadata": true,
"experimentalDecorators": true,
"target": "es5",
"target": "es2015",
"typeRoots": [
"node_modules/@types"
],
Expand Down
8 changes: 4 additions & 4 deletions tslint.json
Original file line number Diff line number Diff line change
Expand Up @@ -117,12 +117,12 @@
"check-type"
],
"no-output-on-prefix": true,
"use-input-property-decorator": true,
"use-output-property-decorator": true,
"use-host-property-decorator": true,
"no-inputs-metadata-property": true,
"no-outputs-metadata-property": true,
"no-host-metadata-property": true,
"no-input-rename": true,
"no-output-rename": true,
"use-life-cycle-interface": true,
"use-lifecycle-interface": true,
"use-pipe-transform-interface": true,
"component-class-suffix": true,
"directive-class-suffix": true
Expand Down

0 comments on commit 0b2892b

Please sign in to comment.