ngx-print-element
Advanced tools
Comparing version
{ | ||
"name": "ngx-print-element", | ||
"version": "2.0.13", | ||
"version": "2.0.14", | ||
"description": "This library is built to provide a solution for printing on html elements.", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
@@ -73,10 +73,22 @@ # ngx-print-element | ||
<button [print]="['demo', { | ||
<button [print]="['demo', config]">Print</button> | ||
``` | ||
```typescript | ||
import { Component } from '@angular/core'; | ||
@Component({ | ||
selector: 'app-root', | ||
templateUrl: './app.component.html', | ||
styleUrls: ['./app.component.css'] | ||
}) | ||
export class AppComponent { | ||
public config = { | ||
printMode: 'template-popup', | ||
popupProperties: 'toolbar=yes,scrollbars=yes,resizable=yes,top=500,left=500,width=1000,height=1000', | ||
popupProperties: 'toolbar=yes,scrollbars=yes,resizable=yes,top=0,left=0,fullscreen=yes', | ||
pageTitle: 'Hello World', | ||
templateString: '<header>I\'m part of the template header</header>{{printBody}}<footer>I\'m part of the template footer</footer>', | ||
stylesheets: [{rel: 'stylesheet', href: 'https://cdn.jsdelivr.net/npm/bootstrap-icons@1.3.0/font/bootstrap-icons.css'}] | ||
styles: ['.table { color: red; }', '.table td { color: green; }'], | ||
}]">Print</button> | ||
stylesheets: [{ rel: 'stylesheet', href: 'https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css' }], | ||
styles: ['.table { color: red; }', '.table td { color: green; }'] | ||
} | ||
} | ||
``` | ||
@@ -83,0 +95,0 @@ |
237691
0.1%134
9.84%