@ezeep/ezeep-js 1.0.139 → 1.0.140
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/ezeep.cjs.js +1 -1
- package/dist/cjs/ezp-auth_12.cjs.entry.js +108 -39
- package/dist/cjs/loader.cjs.js +1 -1
- package/dist/collection/components/ezp-printer-selection/ezp-printer-selection.js +108 -37
- package/dist/collection/components/ezp-printing/ezp-printing.js +18 -1
- package/dist/collection/services/print.js +17 -1
- package/dist/custom-elements/index.js +110 -41
- package/dist/directives/proxies.ts +4 -4
- package/dist/esm/ezeep.js +1 -1
- package/dist/esm/ezp-auth_12.entry.js +108 -39
- package/dist/esm/loader.js +1 -1
- package/dist/esm-es5/ezeep.js +1 -1
- package/dist/esm-es5/ezp-auth_12.entry.js +1 -1
- package/dist/esm-es5/loader.js +1 -1
- package/dist/ezeep/ezeep.esm.js +1 -1
- package/dist/ezeep/p-0711b970.entry.js +1 -0
- package/dist/ezeep/p-c488ee3f.system.js +1 -1
- package/dist/ezeep/{p-1922e5fe.system.entry.js → p-e8c8adc1.system.entry.js} +1 -1
- package/dist/types/components/ezp-printer-selection/ezp-printer-selection.d.ts +3 -1
- package/dist/types/components/ezp-printing/ezp-printing.d.ts +1 -0
- package/dist/types/components.d.ts +4 -0
- package/dist/types/services/print.d.ts +8 -1
- package/package.json +1 -1
- package/www/build/ezeep.esm.js +1 -1
- package/www/build/p-0711b970.entry.js +1 -0
- package/www/build/p-c488ee3f.system.js +1 -1
- package/www/build/{p-1922e5fe.system.entry.js → p-e8c8adc1.system.entry.js} +1 -1
- package/dist/ezeep/p-649f6d96.entry.js +0 -1
- package/www/build/p-649f6d96.entry.js +0 -1
|
@@ -4171,7 +4171,17 @@ class EzpPrintService {
|
|
|
4171
4171
|
'Content-Type': 'application/json',
|
|
4172
4172
|
},
|
|
4173
4173
|
body: JSON.stringify(Object.assign(Object.assign(Object.assign({ fileurl: fileUrl, type: fileType, printerid: printerID }, (filename && { alias: filename })), (printAndDelete && { printanddelete: printAndDelete })), { properties })),
|
|
4174
|
-
})
|
|
4174
|
+
});
|
|
4175
|
+
}
|
|
4176
|
+
printByFileID(accessToken, fileID, fileType, printerID, properties, filename, printAndDelete) {
|
|
4177
|
+
return fetch(`https://${this.printingApi}/sfapi/Print/`, {
|
|
4178
|
+
method: 'POST',
|
|
4179
|
+
headers: {
|
|
4180
|
+
Authorization: 'Bearer ' + accessToken,
|
|
4181
|
+
'Content-Type': 'application/json',
|
|
4182
|
+
},
|
|
4183
|
+
body: JSON.stringify(Object.assign(Object.assign(Object.assign({ fileid: fileID, type: fileType, printerid: printerID }, (filename && { alias: filename })), (printAndDelete && { printanddelete: printAndDelete })), { properties })),
|
|
4184
|
+
});
|
|
4175
4185
|
}
|
|
4176
4186
|
}
|
|
4177
4187
|
const printStore = createStore({
|
|
@@ -4179,6 +4189,12 @@ const printStore = createStore({
|
|
|
4179
4189
|
jobID: '',
|
|
4180
4190
|
printFinished: false,
|
|
4181
4191
|
printApiHostUrl: '',
|
|
4192
|
+
printerProperties: {},
|
|
4193
|
+
fileID: '',
|
|
4194
|
+
fileUrl: '',
|
|
4195
|
+
fileType: '',
|
|
4196
|
+
printerID: '',
|
|
4197
|
+
fileName: ''
|
|
4182
4198
|
});
|
|
4183
4199
|
|
|
4184
4200
|
class EzpUserService {
|
|
@@ -4315,7 +4331,7 @@ let EzpPrinterSelection$1 = class extends HTMLElement {
|
|
|
4315
4331
|
this.selectedProperties = {
|
|
4316
4332
|
paper: '',
|
|
4317
4333
|
paperid: '',
|
|
4318
|
-
color:
|
|
4334
|
+
color: false,
|
|
4319
4335
|
duplex: false,
|
|
4320
4336
|
duplexmode: '',
|
|
4321
4337
|
orientation: '',
|
|
@@ -4325,7 +4341,7 @@ let EzpPrinterSelection$1 = class extends HTMLElement {
|
|
|
4325
4341
|
this.previouslySelectedProperties = {
|
|
4326
4342
|
paper: '',
|
|
4327
4343
|
paperid: '',
|
|
4328
|
-
color:
|
|
4344
|
+
color: false,
|
|
4329
4345
|
duplex: false,
|
|
4330
4346
|
duplexmode: '',
|
|
4331
4347
|
orientation: '',
|
|
@@ -4343,39 +4359,88 @@ let EzpPrinterSelection$1 = class extends HTMLElement {
|
|
|
4343
4359
|
};
|
|
4344
4360
|
/** Description... */
|
|
4345
4361
|
this.handlePrint = () => {
|
|
4362
|
+
const validateData = (data) => {
|
|
4363
|
+
if (data.jobstatus === 0) {
|
|
4364
|
+
this.printInProgress = false;
|
|
4365
|
+
return true;
|
|
4366
|
+
}
|
|
4367
|
+
return false;
|
|
4368
|
+
};
|
|
4369
|
+
const POLL_INTERVAL = 2000;
|
|
4346
4370
|
this.printInProgress = true;
|
|
4347
|
-
this.printService
|
|
4348
|
-
.printFileByUrl(authStore.state.accessToken, this.fileurl, this.filetype, this.selectedPrinter.id,
|
|
4349
4371
|
// we have to initialse this obj with empty strings to display the select component
|
|
4350
4372
|
// but don't want to send any attributes with empty strings to the API
|
|
4351
|
-
removeEmptyStrings(this.selectedProperties)
|
|
4352
|
-
|
|
4353
|
-
|
|
4354
|
-
|
|
4355
|
-
|
|
4356
|
-
|
|
4357
|
-
|
|
4373
|
+
removeEmptyStrings(this.selectedProperties);
|
|
4374
|
+
// put it in store for further use
|
|
4375
|
+
printStore.state.fileUrl = this.fileurl;
|
|
4376
|
+
printStore.state.fileID = this.fileid;
|
|
4377
|
+
printStore.state.fileType = this.filetype;
|
|
4378
|
+
printStore.state.printerID = this.selectedPrinter.id;
|
|
4379
|
+
printStore.state.printerProperties = this.selectedProperties;
|
|
4380
|
+
printStore.state.fileName = this.filename;
|
|
4381
|
+
if (this.fileurl) {
|
|
4382
|
+
this.printService
|
|
4383
|
+
.printFileByUrl(authStore.state.accessToken, this.fileurl, this.filetype, this.selectedPrinter.id, this.selectedProperties, this.filename)
|
|
4384
|
+
.then((response) => {
|
|
4385
|
+
if (response.status === 412) {
|
|
4386
|
+
response.json().then(data => this.fileid = data.fileid);
|
|
4387
|
+
this.printService.printByFileID(authStore.state.accessToken, this.fileid, this.filetype, this.selectedPrinter.id, this.selectedProperties, this.filename).finally(() => this.printInProgress = false);
|
|
4388
|
+
}
|
|
4389
|
+
else {
|
|
4390
|
+
return response.json();
|
|
4391
|
+
}
|
|
4392
|
+
})
|
|
4393
|
+
.then((data) => {
|
|
4394
|
+
if (data.jobid) {
|
|
4395
|
+
printStore.state.jobID = data.jobid;
|
|
4396
|
+
poll({
|
|
4397
|
+
fn: this.printService.getPrintStatus,
|
|
4398
|
+
validate: validateData,
|
|
4399
|
+
interval: POLL_INTERVAL,
|
|
4400
|
+
maxAttempts: 10,
|
|
4401
|
+
})
|
|
4402
|
+
.then(data)
|
|
4403
|
+
.catch((err) => {
|
|
4404
|
+
console.warn(err);
|
|
4358
4405
|
this.printInProgress = false;
|
|
4359
|
-
|
|
4360
|
-
|
|
4361
|
-
|
|
4362
|
-
};
|
|
4363
|
-
poll({
|
|
4364
|
-
fn: this.printService.getPrintStatus,
|
|
4365
|
-
validate: validateData,
|
|
4366
|
-
interval: POLL_INTERVAL,
|
|
4367
|
-
maxAttempts: 10,
|
|
4368
|
-
})
|
|
4369
|
-
.then(data)
|
|
4370
|
-
.catch((err) => {
|
|
4371
|
-
console.warn(err);
|
|
4406
|
+
});
|
|
4407
|
+
}
|
|
4408
|
+
else {
|
|
4372
4409
|
this.printInProgress = false;
|
|
4373
|
-
}
|
|
4374
|
-
}
|
|
4375
|
-
|
|
4410
|
+
}
|
|
4411
|
+
})
|
|
4412
|
+
.catch(error => {
|
|
4413
|
+
console.log(error);
|
|
4376
4414
|
this.printInProgress = false;
|
|
4377
|
-
}
|
|
4378
|
-
}
|
|
4415
|
+
});
|
|
4416
|
+
}
|
|
4417
|
+
else if (this.fileid) {
|
|
4418
|
+
this.printService.printByFileID(authStore.state.accessToken, this.fileid, this.filetype, this.selectedPrinter.id, this.selectedProperties, this.filename)
|
|
4419
|
+
.then((response) => response.json())
|
|
4420
|
+
.then((data) => {
|
|
4421
|
+
if (data.jobid) {
|
|
4422
|
+
printStore.state.jobID = data.jobid;
|
|
4423
|
+
poll({
|
|
4424
|
+
fn: this.printService.getPrintStatus,
|
|
4425
|
+
validate: validateData,
|
|
4426
|
+
interval: POLL_INTERVAL,
|
|
4427
|
+
maxAttempts: 10,
|
|
4428
|
+
})
|
|
4429
|
+
.then(data)
|
|
4430
|
+
.catch((err) => {
|
|
4431
|
+
console.warn(err);
|
|
4432
|
+
this.printInProgress = false;
|
|
4433
|
+
});
|
|
4434
|
+
}
|
|
4435
|
+
else {
|
|
4436
|
+
this.printInProgress = false;
|
|
4437
|
+
}
|
|
4438
|
+
})
|
|
4439
|
+
.catch(error => {
|
|
4440
|
+
console.log(error);
|
|
4441
|
+
this.printInProgress = false;
|
|
4442
|
+
});
|
|
4443
|
+
}
|
|
4379
4444
|
localStorage.setItem('properties', JSON.stringify(this.selectedProperties));
|
|
4380
4445
|
localStorage.setItem('printer', JSON.stringify(this.selectedPrinter));
|
|
4381
4446
|
localStorage.setItem('previouslySelectedProperties', JSON.stringify(this.previouslySelectedProperties));
|
|
@@ -4423,11 +4488,14 @@ let EzpPrinterSelection$1 = class extends HTMLElement {
|
|
|
4423
4488
|
this.userName = userStore.state.user.display_name;
|
|
4424
4489
|
});
|
|
4425
4490
|
}
|
|
4426
|
-
setSelectedProperties(eventDetails) {
|
|
4491
|
+
async setSelectedProperties(eventDetails) {
|
|
4427
4492
|
switch (eventDetails.type) {
|
|
4428
4493
|
case 'printer':
|
|
4429
4494
|
this.selectedPrinter.id = eventDetails.id;
|
|
4430
4495
|
this.selectedPrinter.name = eventDetails.title;
|
|
4496
|
+
await this.printService.getPrinterProperties(authStore.state.accessToken, this.selectedPrinter.id).then(data => this.selectedPrinterConfig = data[0]);
|
|
4497
|
+
console.log('selected printer config:');
|
|
4498
|
+
console.log(this.selectedPrinterConfig);
|
|
4431
4499
|
break;
|
|
4432
4500
|
case 'color':
|
|
4433
4501
|
this.selectedProperties.color = !!eventDetails.id;
|
|
@@ -4479,7 +4547,8 @@ let EzpPrinterSelection$1 = class extends HTMLElement {
|
|
|
4479
4547
|
await this.printService
|
|
4480
4548
|
.getAllPrinterProperties(authStore.state.accessToken)
|
|
4481
4549
|
.then((printerConfig) => {
|
|
4482
|
-
this.printerConfig = printerConfig
|
|
4550
|
+
this.printerConfig = printerConfig;
|
|
4551
|
+
console.log(this.printerConfig);
|
|
4483
4552
|
});
|
|
4484
4553
|
this.loading = false;
|
|
4485
4554
|
}
|
|
@@ -4496,7 +4565,7 @@ let EzpPrinterSelection$1 = class extends HTMLElement {
|
|
|
4496
4565
|
? printer.location
|
|
4497
4566
|
: i18next.t('printer_selection.unknown_location'),
|
|
4498
4567
|
type: 'printer',
|
|
4499
|
-
})), preSelected: this.selectedPrinter.name })), h("div", { id: "options" }, h("ezp-select", { label: i18next.t('printer_selection.color'), icon: "color", placeholder: i18next.t('printer_selection.select_color'), toggleFlow: "horizontal", options: this.
|
|
4568
|
+
})), preSelected: this.selectedPrinter.name })), h("div", { id: "options" }, h("ezp-select", { label: i18next.t('printer_selection.color'), icon: "color", placeholder: i18next.t('printer_selection.select_color'), toggleFlow: "horizontal", options: this.selectedPrinterConfig.Color
|
|
4500
4569
|
? [
|
|
4501
4570
|
{
|
|
4502
4571
|
id: 1,
|
|
@@ -4518,24 +4587,24 @@ let EzpPrinterSelection$1 = class extends HTMLElement {
|
|
|
4518
4587
|
meta: '',
|
|
4519
4588
|
type: 'color',
|
|
4520
4589
|
},
|
|
4521
|
-
], preSelected: this.previouslySelectedProperties.color }), h("ezp-select", { label: i18next.t('printer_selection.orientation'), icon: "orientation", placeholder: i18next.t('printer_selection.select_orientation'), toggleFlow: "horizontal", options: this.
|
|
4590
|
+
], preSelected: this.previouslySelectedProperties.color }), h("ezp-select", { label: i18next.t('printer_selection.orientation'), icon: "orientation", placeholder: i18next.t('printer_selection.select_orientation'), toggleFlow: "horizontal", options: this.selectedPrinterConfig.OrientationsSupported.map((orientation, index) => ({
|
|
4522
4591
|
id: index,
|
|
4523
4592
|
title: i18next.t(`printer_selection.orientation_${orientation}`),
|
|
4524
4593
|
meta: '',
|
|
4525
4594
|
type: 'orientation',
|
|
4526
|
-
})), preSelected: this.previouslySelectedProperties.orientation }), h("ezp-select", { label: i18next.t('printer_selection.size'), icon: "size", placeholder: i18next.t('printer_selection.select_size'), toggleFlow: "horizontal", optionFlow: "horizontal", options: this.
|
|
4595
|
+
})), preSelected: this.previouslySelectedProperties.orientation }), h("ezp-select", { label: i18next.t('printer_selection.size'), icon: "size", placeholder: i18next.t('printer_selection.select_size'), toggleFlow: "horizontal", optionFlow: "horizontal", options: this.selectedPrinterConfig.PaperFormats.map((format) => ({
|
|
4527
4596
|
id: format.Id,
|
|
4528
4597
|
title: format.Name,
|
|
4529
4598
|
meta: `${format.XRes} x ${format.YRes}`,
|
|
4530
4599
|
type: 'format',
|
|
4531
|
-
})), preSelected: this.previouslySelectedProperties.paper }), h("ezp-select", { label: i18next.t('printer_selection.quality'), icon: "quality", toggleFlow: "horizontal", options: this.
|
|
4600
|
+
})), preSelected: this.previouslySelectedProperties.paper }), h("ezp-select", { label: i18next.t('printer_selection.quality'), icon: "quality", toggleFlow: "horizontal", options: this.selectedPrinterConfig.Resolutions.map((option, index) => ({
|
|
4532
4601
|
id: index,
|
|
4533
4602
|
title: option,
|
|
4534
4603
|
meta: '',
|
|
4535
4604
|
type: 'quality',
|
|
4536
4605
|
})), preSelected: !this.previouslySelectedProperties.resolution
|
|
4537
|
-
? this.
|
|
4538
|
-
: this.previouslySelectedProperties.resolution }), this.
|
|
4606
|
+
? this.selectedPrinterConfig.Resolutions[0]
|
|
4607
|
+
: this.previouslySelectedProperties.resolution }), this.selectedPrinterConfig.DuplexSupported ? (h("ezp-select", { label: i18next.t('printer_selection.duplex'), icon: "duplex", toggleFlow: "horizontal", options: this.duplexOptions.map((option) => ({
|
|
4539
4608
|
id: option.id,
|
|
4540
4609
|
title: option.title,
|
|
4541
4610
|
meta: '',
|
|
@@ -4648,7 +4717,7 @@ let EzpPrinting$1 = class extends HTMLElement {
|
|
|
4648
4717
|
*
|
|
4649
4718
|
*/
|
|
4650
4719
|
render() {
|
|
4651
|
-
return (h(Host, { class: `${userStore.state.theme} ${userStore.state.appearance}` }, this.authOpen ? (h("ezp-auth", { clientID: this.clientid, redirectURI: this.redirecturi, hidelogin: this.hidelogin })) : this.printOpen ? (h("ezp-printer-selection", { clientID: this.clientid, redirectURI: this.redirecturi, filename: this.filename, fileurl: this.fileurl, filetype: this.filetype })) : this.custom ? (h("slot", null)) : (h("ezp-icon-button", { id: "print-trigger", icon: "printer", slot: "trigger", type: "button", onClick: () => this.open() }))));
|
|
4720
|
+
return (h(Host, { class: `${userStore.state.theme} ${userStore.state.appearance}` }, this.authOpen ? (h("ezp-auth", { clientID: this.clientid, redirectURI: this.redirecturi, hidelogin: this.hidelogin })) : this.printOpen ? (h("ezp-printer-selection", { clientID: this.clientid, redirectURI: this.redirecturi, filename: this.filename, fileurl: this.fileurl, filetype: this.filetype, fileid: this.fileid })) : this.custom ? (h("slot", null)) : (h("ezp-icon-button", { id: "print-trigger", icon: "printer", slot: "trigger", type: "button", onClick: () => this.open() }))));
|
|
4652
4721
|
}
|
|
4653
4722
|
static get style() { return ezpPrintingCss; }
|
|
4654
4723
|
};
|
|
@@ -5035,8 +5104,8 @@ const EzpBackdrop = /*@__PURE__*/proxyCustomElement(EzpBackdrop$1, [1,"ezp-backd
|
|
|
5035
5104
|
const EzpIcon = /*@__PURE__*/proxyCustomElement(EzpIcon$1, [1,"ezp-icon",{"name":[1],"size":[1]}]);
|
|
5036
5105
|
const EzpIconButton = /*@__PURE__*/proxyCustomElement(EzpIconButton$1, [1,"ezp-icon-button",{"blank":[4],"disabled":[4],"href":[1],"icon":[1],"level":[1],"type":[1]}]);
|
|
5037
5106
|
const EzpLabel = /*@__PURE__*/proxyCustomElement(EzpLabel$1, [1,"ezp-label",{"ellipsis":[4],"level":[1],"noWrap":[4,"no-wrap"],"text":[1],"weight":[1]}]);
|
|
5038
|
-
const EzpPrinterSelection = /*@__PURE__*/proxyCustomElement(EzpPrinterSelection$1, [1,"ezp-printer-selection",{"clientID":[1,"client-i-d"],"redirectURI":[1,"redirect-u-r-i"],"filename":[1],"fileurl":[1],"filetype":[1],"loading":[32],"options":[32],"printInProgress":[32],"userMenuOpen":[32],"userName":[32],"printers":[32],"selectedPrinter":[32],"printerConfig":[32],"selectedProperties":[32],"previouslySelectedProperties":[32]},[[0,"selectSelection","listenSelectSelection"],[0,"stepperChanged","listenStepperChanged"],[0,"userMenuClosure","listenUserMenuClosure"],[0,"logoutEmitter","listenLogout"]]]);
|
|
5039
|
-
const EzpPrinting = /*@__PURE__*/proxyCustomElement(EzpPrinting$1, [1,"ezp-printing",{"clientid":[1],"redirecturi":[1],"filename":[1],"fileurl":[1],"filetype":[1],"custom":[4],"hidelogin":[4],"authapihosturl":[1],"printapihosturl":[1],"theme":[1],"appearance":[1],"printOpen":[32],"authOpen":[32]},[[0,"printCancel","listenPrintCancel"],[0,"printSubmit","listenPrintSubmit"],[0,"authCancel","listenAuthCancel"],[0,"authShow","listenAuthShow"],[0,"printShow","listenPrintShow"]]]);
|
|
5107
|
+
const EzpPrinterSelection = /*@__PURE__*/proxyCustomElement(EzpPrinterSelection$1, [1,"ezp-printer-selection",{"clientID":[1,"client-i-d"],"redirectURI":[1,"redirect-u-r-i"],"filename":[1],"fileurl":[1],"filetype":[1],"fileid":[1],"loading":[32],"options":[32],"printInProgress":[32],"userMenuOpen":[32],"userName":[32],"printers":[32],"selectedPrinter":[32],"printerConfig":[32],"selectedPrinterConfig":[32],"selectedProperties":[32],"previouslySelectedProperties":[32]},[[0,"selectSelection","listenSelectSelection"],[0,"stepperChanged","listenStepperChanged"],[0,"userMenuClosure","listenUserMenuClosure"],[0,"logoutEmitter","listenLogout"]]]);
|
|
5108
|
+
const EzpPrinting = /*@__PURE__*/proxyCustomElement(EzpPrinting$1, [1,"ezp-printing",{"clientid":[1],"redirecturi":[1],"filename":[1],"fileurl":[1],"filetype":[1],"custom":[4],"hidelogin":[4],"authapihosturl":[1],"printapihosturl":[1],"theme":[1],"fileid":[1],"appearance":[1],"printOpen":[32],"authOpen":[32]},[[0,"printCancel","listenPrintCancel"],[0,"printSubmit","listenPrintSubmit"],[0,"authCancel","listenAuthCancel"],[0,"authShow","listenAuthShow"],[0,"printShow","listenPrintShow"]]]);
|
|
5040
5109
|
const EzpProgress = /*@__PURE__*/proxyCustomElement(EzpProgress$1, [1,"ezp-progress",{"status":[1]}]);
|
|
5041
5110
|
const EzpSelect = /*@__PURE__*/proxyCustomElement(EzpSelect$1, [1,"ezp-select",{"icon":[1],"label":[1],"optionFlow":[1,"option-flow"],"options":[16],"placeholder":[1],"preSelected":[8,"pre-selected"],"toggleFlow":[1,"toggle-flow"],"expanded":[32],"selected":[32]}]);
|
|
5042
5111
|
const EzpStepper = /*@__PURE__*/proxyCustomElement(EzpStepper$1, [1,"ezp-stepper",{"icon":[1],"label":[1],"max":[2],"min":[2],"canDecrease":[32],"canIncrease":[32],"focused":[32],"value":[32]}]);
|
|
@@ -115,13 +115,13 @@ export class EzpLabel {
|
|
|
115
115
|
|
|
116
116
|
export declare interface EzpPrinterSelection extends Components.EzpPrinterSelection {}
|
|
117
117
|
@ProxyCmp({
|
|
118
|
-
inputs: ['clientID', 'filename', 'filetype', 'fileurl', 'redirectURI']
|
|
118
|
+
inputs: ['clientID', 'fileid', 'filename', 'filetype', 'fileurl', 'redirectURI']
|
|
119
119
|
})
|
|
120
120
|
@Component({
|
|
121
121
|
selector: 'ezp-printer-selection',
|
|
122
122
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
123
123
|
template: '<ng-content></ng-content>',
|
|
124
|
-
inputs: ['clientID', 'filename', 'filetype', 'fileurl', 'redirectURI'],
|
|
124
|
+
inputs: ['clientID', 'fileid', 'filename', 'filetype', 'fileurl', 'redirectURI'],
|
|
125
125
|
outputs: ['printCancel', 'printSubmit']
|
|
126
126
|
})
|
|
127
127
|
export class EzpPrinterSelection {
|
|
@@ -140,14 +140,14 @@ export class EzpPrinterSelection {
|
|
|
140
140
|
|
|
141
141
|
export declare interface EzpPrinting extends Components.EzpPrinting {}
|
|
142
142
|
@ProxyCmp({
|
|
143
|
-
inputs: ['appearance', 'authapihosturl', 'clientid', 'custom', 'filename', 'filetype', 'fileurl', 'hidelogin', 'printapihosturl', 'redirecturi', 'theme'],
|
|
143
|
+
inputs: ['appearance', 'authapihosturl', 'clientid', 'custom', 'fileid', 'filename', 'filetype', 'fileurl', 'hidelogin', 'printapihosturl', 'redirecturi', 'theme'],
|
|
144
144
|
methods: ['open']
|
|
145
145
|
})
|
|
146
146
|
@Component({
|
|
147
147
|
selector: 'ezp-printing',
|
|
148
148
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
149
149
|
template: '<ng-content></ng-content>',
|
|
150
|
-
inputs: ['appearance', 'authapihosturl', 'clientid', 'custom', 'filename', 'filetype', 'fileurl', 'hidelogin', 'printapihosturl', 'redirecturi', 'theme']
|
|
150
|
+
inputs: ['appearance', 'authapihosturl', 'clientid', 'custom', 'fileid', 'filename', 'filetype', 'fileurl', 'hidelogin', 'printapihosturl', 'redirecturi', 'theme']
|
|
151
151
|
})
|
|
152
152
|
export class EzpPrinting {
|
|
153
153
|
protected el: HTMLElement;
|
package/dist/esm/ezeep.js
CHANGED
|
@@ -15,5 +15,5 @@ const patchBrowser = () => {
|
|
|
15
15
|
|
|
16
16
|
patchBrowser().then(options => {
|
|
17
17
|
globalScripts();
|
|
18
|
-
return bootstrapLazy([["ezp-auth_12",[[1,"ezp-printing",{"clientid":[1],"redirecturi":[1],"filename":[1],"fileurl":[1],"filetype":[1],"custom":[4],"hidelogin":[4],"authapihosturl":[1],"printapihosturl":[1],"theme":[1],"appearance":[1],"printOpen":[32],"authOpen":[32],"open":[64]},[[0,"printCancel","listenPrintCancel"],[0,"printSubmit","listenPrintSubmit"],[0,"authCancel","listenAuthCancel"],[0,"authShow","listenAuthShow"],[0,"printShow","listenPrintShow"]]],[1,"ezp-printer-selection",{"clientID":[1,"client-i-d"],"redirectURI":[1,"redirect-u-r-i"],"filename":[1],"fileurl":[1],"filetype":[1],"loading":[32],"options":[32],"printInProgress":[32],"userMenuOpen":[32],"userName":[32],"printers":[32],"selectedPrinter":[32],"printerConfig":[32],"selectedProperties":[32],"previouslySelectedProperties":[32]},[[0,"selectSelection","listenSelectSelection"],[0,"stepperChanged","listenStepperChanged"],[0,"userMenuClosure","listenUserMenuClosure"],[0,"logoutEmitter","listenLogout"]]],[1,"ezp-auth",{"clientID":[1025,"client-i-d"],"redirectURI":[1025,"redirect-u-r-i"],"hidelogin":[4],"auth":[32],"authURI":[32],"accessToken":[32]}],[1,"ezp-user-menu",{"name":[1],"open":[1028]}],[1,"ezp-select",{"icon":[1],"label":[1],"optionFlow":[1,"option-flow"],"options":[16],"placeholder":[1],"preSelected":[8,"pre-selected"],"toggleFlow":[1,"toggle-flow"],"expanded":[32],"selected":[32]}],[1,"ezp-stepper",{"icon":[1],"label":[1],"max":[2],"min":[2],"canDecrease":[32],"canIncrease":[32],"focused":[32],"value":[32]}],[1,"ezp-progress",{"status":[1]}],[1,"ezp-text-button",{"blank":[4],"disabled":[4],"href":[1],"level":[1],"label":[1],"type":[1]}],[1,"ezp-icon-button",{"blank":[4],"disabled":[4],"href":[1],"icon":[1],"level":[1],"type":[1]}],[1,"ezp-backdrop",{"visible":[1028]},[[0,"animationend","listenAnimationEnd"]]],[1,"ezp-icon",{"name":[1],"size":[1]}],[1,"ezp-label",{"ellipsis":[4],"level":[1],"noWrap":[4,"no-wrap"],"text":[1],"weight":[1]}]]]], options);
|
|
18
|
+
return bootstrapLazy([["ezp-auth_12",[[1,"ezp-printing",{"clientid":[1],"redirecturi":[1],"filename":[1],"fileurl":[1],"filetype":[1],"custom":[4],"hidelogin":[4],"authapihosturl":[1],"printapihosturl":[1],"theme":[1],"fileid":[1],"appearance":[1],"printOpen":[32],"authOpen":[32],"open":[64]},[[0,"printCancel","listenPrintCancel"],[0,"printSubmit","listenPrintSubmit"],[0,"authCancel","listenAuthCancel"],[0,"authShow","listenAuthShow"],[0,"printShow","listenPrintShow"]]],[1,"ezp-printer-selection",{"clientID":[1,"client-i-d"],"redirectURI":[1,"redirect-u-r-i"],"filename":[1],"fileurl":[1],"filetype":[1],"fileid":[1],"loading":[32],"options":[32],"printInProgress":[32],"userMenuOpen":[32],"userName":[32],"printers":[32],"selectedPrinter":[32],"printerConfig":[32],"selectedPrinterConfig":[32],"selectedProperties":[32],"previouslySelectedProperties":[32]},[[0,"selectSelection","listenSelectSelection"],[0,"stepperChanged","listenStepperChanged"],[0,"userMenuClosure","listenUserMenuClosure"],[0,"logoutEmitter","listenLogout"]]],[1,"ezp-auth",{"clientID":[1025,"client-i-d"],"redirectURI":[1025,"redirect-u-r-i"],"hidelogin":[4],"auth":[32],"authURI":[32],"accessToken":[32]}],[1,"ezp-user-menu",{"name":[1],"open":[1028]}],[1,"ezp-select",{"icon":[1],"label":[1],"optionFlow":[1,"option-flow"],"options":[16],"placeholder":[1],"preSelected":[8,"pre-selected"],"toggleFlow":[1,"toggle-flow"],"expanded":[32],"selected":[32]}],[1,"ezp-stepper",{"icon":[1],"label":[1],"max":[2],"min":[2],"canDecrease":[32],"canIncrease":[32],"focused":[32],"value":[32]}],[1,"ezp-progress",{"status":[1]}],[1,"ezp-text-button",{"blank":[4],"disabled":[4],"href":[1],"level":[1],"label":[1],"type":[1]}],[1,"ezp-icon-button",{"blank":[4],"disabled":[4],"href":[1],"icon":[1],"level":[1],"type":[1]}],[1,"ezp-backdrop",{"visible":[1028]},[[0,"animationend","listenAnimationEnd"]]],[1,"ezp-icon",{"name":[1],"size":[1]}],[1,"ezp-label",{"ellipsis":[4],"level":[1],"noWrap":[4,"no-wrap"],"text":[1],"weight":[1]}]]]], options);
|
|
19
19
|
});
|
|
@@ -4148,7 +4148,17 @@ class EzpPrintService {
|
|
|
4148
4148
|
'Content-Type': 'application/json',
|
|
4149
4149
|
},
|
|
4150
4150
|
body: JSON.stringify(Object.assign(Object.assign(Object.assign({ fileurl: fileUrl, type: fileType, printerid: printerID }, (filename && { alias: filename })), (printAndDelete && { printanddelete: printAndDelete })), { properties })),
|
|
4151
|
-
})
|
|
4151
|
+
});
|
|
4152
|
+
}
|
|
4153
|
+
printByFileID(accessToken, fileID, fileType, printerID, properties, filename, printAndDelete) {
|
|
4154
|
+
return fetch(`https://${this.printingApi}/sfapi/Print/`, {
|
|
4155
|
+
method: 'POST',
|
|
4156
|
+
headers: {
|
|
4157
|
+
Authorization: 'Bearer ' + accessToken,
|
|
4158
|
+
'Content-Type': 'application/json',
|
|
4159
|
+
},
|
|
4160
|
+
body: JSON.stringify(Object.assign(Object.assign(Object.assign({ fileid: fileID, type: fileType, printerid: printerID }, (filename && { alias: filename })), (printAndDelete && { printanddelete: printAndDelete })), { properties })),
|
|
4161
|
+
});
|
|
4152
4162
|
}
|
|
4153
4163
|
}
|
|
4154
4164
|
const printStore = createStore({
|
|
@@ -4156,6 +4166,12 @@ const printStore = createStore({
|
|
|
4156
4166
|
jobID: '',
|
|
4157
4167
|
printFinished: false,
|
|
4158
4168
|
printApiHostUrl: '',
|
|
4169
|
+
printerProperties: {},
|
|
4170
|
+
fileID: '',
|
|
4171
|
+
fileUrl: '',
|
|
4172
|
+
fileType: '',
|
|
4173
|
+
printerID: '',
|
|
4174
|
+
fileName: ''
|
|
4159
4175
|
});
|
|
4160
4176
|
|
|
4161
4177
|
class EzpUserService {
|
|
@@ -4290,7 +4306,7 @@ let EzpPrinterSelection = class {
|
|
|
4290
4306
|
this.selectedProperties = {
|
|
4291
4307
|
paper: '',
|
|
4292
4308
|
paperid: '',
|
|
4293
|
-
color:
|
|
4309
|
+
color: false,
|
|
4294
4310
|
duplex: false,
|
|
4295
4311
|
duplexmode: '',
|
|
4296
4312
|
orientation: '',
|
|
@@ -4300,7 +4316,7 @@ let EzpPrinterSelection = class {
|
|
|
4300
4316
|
this.previouslySelectedProperties = {
|
|
4301
4317
|
paper: '',
|
|
4302
4318
|
paperid: '',
|
|
4303
|
-
color:
|
|
4319
|
+
color: false,
|
|
4304
4320
|
duplex: false,
|
|
4305
4321
|
duplexmode: '',
|
|
4306
4322
|
orientation: '',
|
|
@@ -4318,39 +4334,88 @@ let EzpPrinterSelection = class {
|
|
|
4318
4334
|
};
|
|
4319
4335
|
/** Description... */
|
|
4320
4336
|
this.handlePrint = () => {
|
|
4337
|
+
const validateData = (data) => {
|
|
4338
|
+
if (data.jobstatus === 0) {
|
|
4339
|
+
this.printInProgress = false;
|
|
4340
|
+
return true;
|
|
4341
|
+
}
|
|
4342
|
+
return false;
|
|
4343
|
+
};
|
|
4344
|
+
const POLL_INTERVAL = 2000;
|
|
4321
4345
|
this.printInProgress = true;
|
|
4322
|
-
this.printService
|
|
4323
|
-
.printFileByUrl(authStore.state.accessToken, this.fileurl, this.filetype, this.selectedPrinter.id,
|
|
4324
4346
|
// we have to initialse this obj with empty strings to display the select component
|
|
4325
4347
|
// but don't want to send any attributes with empty strings to the API
|
|
4326
|
-
removeEmptyStrings(this.selectedProperties)
|
|
4327
|
-
|
|
4328
|
-
|
|
4329
|
-
|
|
4330
|
-
|
|
4331
|
-
|
|
4332
|
-
|
|
4348
|
+
removeEmptyStrings(this.selectedProperties);
|
|
4349
|
+
// put it in store for further use
|
|
4350
|
+
printStore.state.fileUrl = this.fileurl;
|
|
4351
|
+
printStore.state.fileID = this.fileid;
|
|
4352
|
+
printStore.state.fileType = this.filetype;
|
|
4353
|
+
printStore.state.printerID = this.selectedPrinter.id;
|
|
4354
|
+
printStore.state.printerProperties = this.selectedProperties;
|
|
4355
|
+
printStore.state.fileName = this.filename;
|
|
4356
|
+
if (this.fileurl) {
|
|
4357
|
+
this.printService
|
|
4358
|
+
.printFileByUrl(authStore.state.accessToken, this.fileurl, this.filetype, this.selectedPrinter.id, this.selectedProperties, this.filename)
|
|
4359
|
+
.then((response) => {
|
|
4360
|
+
if (response.status === 412) {
|
|
4361
|
+
response.json().then(data => this.fileid = data.fileid);
|
|
4362
|
+
this.printService.printByFileID(authStore.state.accessToken, this.fileid, this.filetype, this.selectedPrinter.id, this.selectedProperties, this.filename).finally(() => this.printInProgress = false);
|
|
4363
|
+
}
|
|
4364
|
+
else {
|
|
4365
|
+
return response.json();
|
|
4366
|
+
}
|
|
4367
|
+
})
|
|
4368
|
+
.then((data) => {
|
|
4369
|
+
if (data.jobid) {
|
|
4370
|
+
printStore.state.jobID = data.jobid;
|
|
4371
|
+
poll({
|
|
4372
|
+
fn: this.printService.getPrintStatus,
|
|
4373
|
+
validate: validateData,
|
|
4374
|
+
interval: POLL_INTERVAL,
|
|
4375
|
+
maxAttempts: 10,
|
|
4376
|
+
})
|
|
4377
|
+
.then(data)
|
|
4378
|
+
.catch((err) => {
|
|
4379
|
+
console.warn(err);
|
|
4333
4380
|
this.printInProgress = false;
|
|
4334
|
-
|
|
4335
|
-
|
|
4336
|
-
|
|
4337
|
-
};
|
|
4338
|
-
poll({
|
|
4339
|
-
fn: this.printService.getPrintStatus,
|
|
4340
|
-
validate: validateData,
|
|
4341
|
-
interval: POLL_INTERVAL,
|
|
4342
|
-
maxAttempts: 10,
|
|
4343
|
-
})
|
|
4344
|
-
.then(data)
|
|
4345
|
-
.catch((err) => {
|
|
4346
|
-
console.warn(err);
|
|
4381
|
+
});
|
|
4382
|
+
}
|
|
4383
|
+
else {
|
|
4347
4384
|
this.printInProgress = false;
|
|
4348
|
-
}
|
|
4349
|
-
}
|
|
4350
|
-
|
|
4385
|
+
}
|
|
4386
|
+
})
|
|
4387
|
+
.catch(error => {
|
|
4388
|
+
console.log(error);
|
|
4351
4389
|
this.printInProgress = false;
|
|
4352
|
-
}
|
|
4353
|
-
}
|
|
4390
|
+
});
|
|
4391
|
+
}
|
|
4392
|
+
else if (this.fileid) {
|
|
4393
|
+
this.printService.printByFileID(authStore.state.accessToken, this.fileid, this.filetype, this.selectedPrinter.id, this.selectedProperties, this.filename)
|
|
4394
|
+
.then((response) => response.json())
|
|
4395
|
+
.then((data) => {
|
|
4396
|
+
if (data.jobid) {
|
|
4397
|
+
printStore.state.jobID = data.jobid;
|
|
4398
|
+
poll({
|
|
4399
|
+
fn: this.printService.getPrintStatus,
|
|
4400
|
+
validate: validateData,
|
|
4401
|
+
interval: POLL_INTERVAL,
|
|
4402
|
+
maxAttempts: 10,
|
|
4403
|
+
})
|
|
4404
|
+
.then(data)
|
|
4405
|
+
.catch((err) => {
|
|
4406
|
+
console.warn(err);
|
|
4407
|
+
this.printInProgress = false;
|
|
4408
|
+
});
|
|
4409
|
+
}
|
|
4410
|
+
else {
|
|
4411
|
+
this.printInProgress = false;
|
|
4412
|
+
}
|
|
4413
|
+
})
|
|
4414
|
+
.catch(error => {
|
|
4415
|
+
console.log(error);
|
|
4416
|
+
this.printInProgress = false;
|
|
4417
|
+
});
|
|
4418
|
+
}
|
|
4354
4419
|
localStorage.setItem('properties', JSON.stringify(this.selectedProperties));
|
|
4355
4420
|
localStorage.setItem('printer', JSON.stringify(this.selectedPrinter));
|
|
4356
4421
|
localStorage.setItem('previouslySelectedProperties', JSON.stringify(this.previouslySelectedProperties));
|
|
@@ -4398,11 +4463,14 @@ let EzpPrinterSelection = class {
|
|
|
4398
4463
|
this.userName = userStore.state.user.display_name;
|
|
4399
4464
|
});
|
|
4400
4465
|
}
|
|
4401
|
-
setSelectedProperties(eventDetails) {
|
|
4466
|
+
async setSelectedProperties(eventDetails) {
|
|
4402
4467
|
switch (eventDetails.type) {
|
|
4403
4468
|
case 'printer':
|
|
4404
4469
|
this.selectedPrinter.id = eventDetails.id;
|
|
4405
4470
|
this.selectedPrinter.name = eventDetails.title;
|
|
4471
|
+
await this.printService.getPrinterProperties(authStore.state.accessToken, this.selectedPrinter.id).then(data => this.selectedPrinterConfig = data[0]);
|
|
4472
|
+
console.log('selected printer config:');
|
|
4473
|
+
console.log(this.selectedPrinterConfig);
|
|
4406
4474
|
break;
|
|
4407
4475
|
case 'color':
|
|
4408
4476
|
this.selectedProperties.color = !!eventDetails.id;
|
|
@@ -4454,7 +4522,8 @@ let EzpPrinterSelection = class {
|
|
|
4454
4522
|
await this.printService
|
|
4455
4523
|
.getAllPrinterProperties(authStore.state.accessToken)
|
|
4456
4524
|
.then((printerConfig) => {
|
|
4457
|
-
this.printerConfig = printerConfig
|
|
4525
|
+
this.printerConfig = printerConfig;
|
|
4526
|
+
console.log(this.printerConfig);
|
|
4458
4527
|
});
|
|
4459
4528
|
this.loading = false;
|
|
4460
4529
|
}
|
|
@@ -4471,7 +4540,7 @@ let EzpPrinterSelection = class {
|
|
|
4471
4540
|
? printer.location
|
|
4472
4541
|
: i18next.t('printer_selection.unknown_location'),
|
|
4473
4542
|
type: 'printer',
|
|
4474
|
-
})), preSelected: this.selectedPrinter.name })), h("div", { id: "options" }, h("ezp-select", { label: i18next.t('printer_selection.color'), icon: "color", placeholder: i18next.t('printer_selection.select_color'), toggleFlow: "horizontal", options: this.
|
|
4543
|
+
})), preSelected: this.selectedPrinter.name })), h("div", { id: "options" }, h("ezp-select", { label: i18next.t('printer_selection.color'), icon: "color", placeholder: i18next.t('printer_selection.select_color'), toggleFlow: "horizontal", options: this.selectedPrinterConfig.Color
|
|
4475
4544
|
? [
|
|
4476
4545
|
{
|
|
4477
4546
|
id: 1,
|
|
@@ -4493,24 +4562,24 @@ let EzpPrinterSelection = class {
|
|
|
4493
4562
|
meta: '',
|
|
4494
4563
|
type: 'color',
|
|
4495
4564
|
},
|
|
4496
|
-
], preSelected: this.previouslySelectedProperties.color }), h("ezp-select", { label: i18next.t('printer_selection.orientation'), icon: "orientation", placeholder: i18next.t('printer_selection.select_orientation'), toggleFlow: "horizontal", options: this.
|
|
4565
|
+
], preSelected: this.previouslySelectedProperties.color }), h("ezp-select", { label: i18next.t('printer_selection.orientation'), icon: "orientation", placeholder: i18next.t('printer_selection.select_orientation'), toggleFlow: "horizontal", options: this.selectedPrinterConfig.OrientationsSupported.map((orientation, index) => ({
|
|
4497
4566
|
id: index,
|
|
4498
4567
|
title: i18next.t(`printer_selection.orientation_${orientation}`),
|
|
4499
4568
|
meta: '',
|
|
4500
4569
|
type: 'orientation',
|
|
4501
|
-
})), preSelected: this.previouslySelectedProperties.orientation }), h("ezp-select", { label: i18next.t('printer_selection.size'), icon: "size", placeholder: i18next.t('printer_selection.select_size'), toggleFlow: "horizontal", optionFlow: "horizontal", options: this.
|
|
4570
|
+
})), preSelected: this.previouslySelectedProperties.orientation }), h("ezp-select", { label: i18next.t('printer_selection.size'), icon: "size", placeholder: i18next.t('printer_selection.select_size'), toggleFlow: "horizontal", optionFlow: "horizontal", options: this.selectedPrinterConfig.PaperFormats.map((format) => ({
|
|
4502
4571
|
id: format.Id,
|
|
4503
4572
|
title: format.Name,
|
|
4504
4573
|
meta: `${format.XRes} x ${format.YRes}`,
|
|
4505
4574
|
type: 'format',
|
|
4506
|
-
})), preSelected: this.previouslySelectedProperties.paper }), h("ezp-select", { label: i18next.t('printer_selection.quality'), icon: "quality", toggleFlow: "horizontal", options: this.
|
|
4575
|
+
})), preSelected: this.previouslySelectedProperties.paper }), h("ezp-select", { label: i18next.t('printer_selection.quality'), icon: "quality", toggleFlow: "horizontal", options: this.selectedPrinterConfig.Resolutions.map((option, index) => ({
|
|
4507
4576
|
id: index,
|
|
4508
4577
|
title: option,
|
|
4509
4578
|
meta: '',
|
|
4510
4579
|
type: 'quality',
|
|
4511
4580
|
})), preSelected: !this.previouslySelectedProperties.resolution
|
|
4512
|
-
? this.
|
|
4513
|
-
: this.previouslySelectedProperties.resolution }), this.
|
|
4581
|
+
? this.selectedPrinterConfig.Resolutions[0]
|
|
4582
|
+
: this.previouslySelectedProperties.resolution }), this.selectedPrinterConfig.DuplexSupported ? (h("ezp-select", { label: i18next.t('printer_selection.duplex'), icon: "duplex", toggleFlow: "horizontal", options: this.duplexOptions.map((option) => ({
|
|
4514
4583
|
id: option.id,
|
|
4515
4584
|
title: option.title,
|
|
4516
4585
|
meta: '',
|
|
@@ -4621,7 +4690,7 @@ let EzpPrinting = class {
|
|
|
4621
4690
|
*
|
|
4622
4691
|
*/
|
|
4623
4692
|
render() {
|
|
4624
|
-
return (h(Host, { class: `${userStore.state.theme} ${userStore.state.appearance}` }, this.authOpen ? (h("ezp-auth", { clientID: this.clientid, redirectURI: this.redirecturi, hidelogin: this.hidelogin })) : this.printOpen ? (h("ezp-printer-selection", { clientID: this.clientid, redirectURI: this.redirecturi, filename: this.filename, fileurl: this.fileurl, filetype: this.filetype })) : this.custom ? (h("slot", null)) : (h("ezp-icon-button", { id: "print-trigger", icon: "printer", slot: "trigger", type: "button", onClick: () => this.open() }))));
|
|
4693
|
+
return (h(Host, { class: `${userStore.state.theme} ${userStore.state.appearance}` }, this.authOpen ? (h("ezp-auth", { clientID: this.clientid, redirectURI: this.redirecturi, hidelogin: this.hidelogin })) : this.printOpen ? (h("ezp-printer-selection", { clientID: this.clientid, redirectURI: this.redirecturi, filename: this.filename, fileurl: this.fileurl, filetype: this.filetype, fileid: this.fileid })) : this.custom ? (h("slot", null)) : (h("ezp-icon-button", { id: "print-trigger", icon: "printer", slot: "trigger", type: "button", onClick: () => this.open() }))));
|
|
4625
4694
|
}
|
|
4626
4695
|
};
|
|
4627
4696
|
EzpPrinting.style = ezpPrintingCss;
|
package/dist/esm/loader.js
CHANGED
|
@@ -12,7 +12,7 @@ const defineCustomElements = (win, options) => {
|
|
|
12
12
|
if (typeof window === 'undefined') return Promise.resolve();
|
|
13
13
|
return patchEsm().then(() => {
|
|
14
14
|
globalScripts();
|
|
15
|
-
return bootstrapLazy([["ezp-auth_12",[[1,"ezp-printing",{"clientid":[1],"redirecturi":[1],"filename":[1],"fileurl":[1],"filetype":[1],"custom":[4],"hidelogin":[4],"authapihosturl":[1],"printapihosturl":[1],"theme":[1],"appearance":[1],"printOpen":[32],"authOpen":[32],"open":[64]},[[0,"printCancel","listenPrintCancel"],[0,"printSubmit","listenPrintSubmit"],[0,"authCancel","listenAuthCancel"],[0,"authShow","listenAuthShow"],[0,"printShow","listenPrintShow"]]],[1,"ezp-printer-selection",{"clientID":[1,"client-i-d"],"redirectURI":[1,"redirect-u-r-i"],"filename":[1],"fileurl":[1],"filetype":[1],"loading":[32],"options":[32],"printInProgress":[32],"userMenuOpen":[32],"userName":[32],"printers":[32],"selectedPrinter":[32],"printerConfig":[32],"selectedProperties":[32],"previouslySelectedProperties":[32]},[[0,"selectSelection","listenSelectSelection"],[0,"stepperChanged","listenStepperChanged"],[0,"userMenuClosure","listenUserMenuClosure"],[0,"logoutEmitter","listenLogout"]]],[1,"ezp-auth",{"clientID":[1025,"client-i-d"],"redirectURI":[1025,"redirect-u-r-i"],"hidelogin":[4],"auth":[32],"authURI":[32],"accessToken":[32]}],[1,"ezp-user-menu",{"name":[1],"open":[1028]}],[1,"ezp-select",{"icon":[1],"label":[1],"optionFlow":[1,"option-flow"],"options":[16],"placeholder":[1],"preSelected":[8,"pre-selected"],"toggleFlow":[1,"toggle-flow"],"expanded":[32],"selected":[32]}],[1,"ezp-stepper",{"icon":[1],"label":[1],"max":[2],"min":[2],"canDecrease":[32],"canIncrease":[32],"focused":[32],"value":[32]}],[1,"ezp-progress",{"status":[1]}],[1,"ezp-text-button",{"blank":[4],"disabled":[4],"href":[1],"level":[1],"label":[1],"type":[1]}],[1,"ezp-icon-button",{"blank":[4],"disabled":[4],"href":[1],"icon":[1],"level":[1],"type":[1]}],[1,"ezp-backdrop",{"visible":[1028]},[[0,"animationend","listenAnimationEnd"]]],[1,"ezp-icon",{"name":[1],"size":[1]}],[1,"ezp-label",{"ellipsis":[4],"level":[1],"noWrap":[4,"no-wrap"],"text":[1],"weight":[1]}]]]], options);
|
|
15
|
+
return bootstrapLazy([["ezp-auth_12",[[1,"ezp-printing",{"clientid":[1],"redirecturi":[1],"filename":[1],"fileurl":[1],"filetype":[1],"custom":[4],"hidelogin":[4],"authapihosturl":[1],"printapihosturl":[1],"theme":[1],"fileid":[1],"appearance":[1],"printOpen":[32],"authOpen":[32],"open":[64]},[[0,"printCancel","listenPrintCancel"],[0,"printSubmit","listenPrintSubmit"],[0,"authCancel","listenAuthCancel"],[0,"authShow","listenAuthShow"],[0,"printShow","listenPrintShow"]]],[1,"ezp-printer-selection",{"clientID":[1,"client-i-d"],"redirectURI":[1,"redirect-u-r-i"],"filename":[1],"fileurl":[1],"filetype":[1],"fileid":[1],"loading":[32],"options":[32],"printInProgress":[32],"userMenuOpen":[32],"userName":[32],"printers":[32],"selectedPrinter":[32],"printerConfig":[32],"selectedPrinterConfig":[32],"selectedProperties":[32],"previouslySelectedProperties":[32]},[[0,"selectSelection","listenSelectSelection"],[0,"stepperChanged","listenStepperChanged"],[0,"userMenuClosure","listenUserMenuClosure"],[0,"logoutEmitter","listenLogout"]]],[1,"ezp-auth",{"clientID":[1025,"client-i-d"],"redirectURI":[1025,"redirect-u-r-i"],"hidelogin":[4],"auth":[32],"authURI":[32],"accessToken":[32]}],[1,"ezp-user-menu",{"name":[1],"open":[1028]}],[1,"ezp-select",{"icon":[1],"label":[1],"optionFlow":[1,"option-flow"],"options":[16],"placeholder":[1],"preSelected":[8,"pre-selected"],"toggleFlow":[1,"toggle-flow"],"expanded":[32],"selected":[32]}],[1,"ezp-stepper",{"icon":[1],"label":[1],"max":[2],"min":[2],"canDecrease":[32],"canIncrease":[32],"focused":[32],"value":[32]}],[1,"ezp-progress",{"status":[1]}],[1,"ezp-text-button",{"blank":[4],"disabled":[4],"href":[1],"level":[1],"label":[1],"type":[1]}],[1,"ezp-icon-button",{"blank":[4],"disabled":[4],"href":[1],"icon":[1],"level":[1],"type":[1]}],[1,"ezp-backdrop",{"visible":[1028]},[[0,"animationend","listenAnimationEnd"]]],[1,"ezp-icon",{"name":[1],"size":[1]}],[1,"ezp-label",{"ellipsis":[4],"level":[1],"noWrap":[4,"no-wrap"],"text":[1],"weight":[1]}]]]], options);
|
|
16
16
|
});
|
|
17
17
|
};
|
|
18
18
|
|
package/dist/esm-es5/ezeep.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{p as promiseResolve,b as bootstrapLazy}from"./index-9ecf6ae0.js";import{g as globalScripts}from"./app-globals-28960cbc.js";var patchBrowser=function(){var e=import.meta.url;var t={};if(e!==""){t.resourcesUrl=new URL(".",e).href}return promiseResolve(t)};patchBrowser().then((function(e){globalScripts();return bootstrapLazy([["ezp-auth_12",[[1,"ezp-printing",{clientid:[1],redirecturi:[1],filename:[1],fileurl:[1],filetype:[1],custom:[4],hidelogin:[4],authapihosturl:[1],printapihosturl:[1],theme:[1],appearance:[1],printOpen:[32],authOpen:[32],open:[64]},[[0,"printCancel","listenPrintCancel"],[0,"printSubmit","listenPrintSubmit"],[0,"authCancel","listenAuthCancel"],[0,"authShow","listenAuthShow"],[0,"printShow","listenPrintShow"]]],[1,"ezp-printer-selection",{clientID:[1,"client-i-d"],redirectURI:[1,"redirect-u-r-i"],filename:[1],fileurl:[1],filetype:[1],loading:[32],options:[32],printInProgress:[32],userMenuOpen:[32],userName:[32],printers:[32],selectedPrinter:[32],printerConfig:[32],selectedProperties:[32],previouslySelectedProperties:[32]},[[0,"selectSelection","listenSelectSelection"],[0,"stepperChanged","listenStepperChanged"],[0,"userMenuClosure","listenUserMenuClosure"],[0,"logoutEmitter","listenLogout"]]],[1,"ezp-auth",{clientID:[1025,"client-i-d"],redirectURI:[1025,"redirect-u-r-i"],hidelogin:[4],auth:[32],authURI:[32],accessToken:[32]}],[1,"ezp-user-menu",{name:[1],open:[1028]}],[1,"ezp-select",{icon:[1],label:[1],optionFlow:[1,"option-flow"],options:[16],placeholder:[1],preSelected:[8,"pre-selected"],toggleFlow:[1,"toggle-flow"],expanded:[32],selected:[32]}],[1,"ezp-stepper",{icon:[1],label:[1],max:[2],min:[2],canDecrease:[32],canIncrease:[32],focused:[32],value:[32]}],[1,"ezp-progress",{status:[1]}],[1,"ezp-text-button",{blank:[4],disabled:[4],href:[1],level:[1],label:[1],type:[1]}],[1,"ezp-icon-button",{blank:[4],disabled:[4],href:[1],icon:[1],level:[1],type:[1]}],[1,"ezp-backdrop",{visible:[1028]},[[0,"animationend","listenAnimationEnd"]]],[1,"ezp-icon",{name:[1],size:[1]}],[1,"ezp-label",{ellipsis:[4],level:[1],noWrap:[4,"no-wrap"],text:[1],weight:[1]}]]]],e)}));
|
|
1
|
+
import{p as promiseResolve,b as bootstrapLazy}from"./index-9ecf6ae0.js";import{g as globalScripts}from"./app-globals-28960cbc.js";var patchBrowser=function(){var e=import.meta.url;var t={};if(e!==""){t.resourcesUrl=new URL(".",e).href}return promiseResolve(t)};patchBrowser().then((function(e){globalScripts();return bootstrapLazy([["ezp-auth_12",[[1,"ezp-printing",{clientid:[1],redirecturi:[1],filename:[1],fileurl:[1],filetype:[1],custom:[4],hidelogin:[4],authapihosturl:[1],printapihosturl:[1],theme:[1],fileid:[1],appearance:[1],printOpen:[32],authOpen:[32],open:[64]},[[0,"printCancel","listenPrintCancel"],[0,"printSubmit","listenPrintSubmit"],[0,"authCancel","listenAuthCancel"],[0,"authShow","listenAuthShow"],[0,"printShow","listenPrintShow"]]],[1,"ezp-printer-selection",{clientID:[1,"client-i-d"],redirectURI:[1,"redirect-u-r-i"],filename:[1],fileurl:[1],filetype:[1],fileid:[1],loading:[32],options:[32],printInProgress:[32],userMenuOpen:[32],userName:[32],printers:[32],selectedPrinter:[32],printerConfig:[32],selectedPrinterConfig:[32],selectedProperties:[32],previouslySelectedProperties:[32]},[[0,"selectSelection","listenSelectSelection"],[0,"stepperChanged","listenStepperChanged"],[0,"userMenuClosure","listenUserMenuClosure"],[0,"logoutEmitter","listenLogout"]]],[1,"ezp-auth",{clientID:[1025,"client-i-d"],redirectURI:[1025,"redirect-u-r-i"],hidelogin:[4],auth:[32],authURI:[32],accessToken:[32]}],[1,"ezp-user-menu",{name:[1],open:[1028]}],[1,"ezp-select",{icon:[1],label:[1],optionFlow:[1,"option-flow"],options:[16],placeholder:[1],preSelected:[8,"pre-selected"],toggleFlow:[1,"toggle-flow"],expanded:[32],selected:[32]}],[1,"ezp-stepper",{icon:[1],label:[1],max:[2],min:[2],canDecrease:[32],canIncrease:[32],focused:[32],value:[32]}],[1,"ezp-progress",{status:[1]}],[1,"ezp-text-button",{blank:[4],disabled:[4],href:[1],level:[1],label:[1],type:[1]}],[1,"ezp-icon-button",{blank:[4],disabled:[4],href:[1],icon:[1],level:[1],type:[1]}],[1,"ezp-backdrop",{visible:[1028]},[[0,"animationend","listenAnimationEnd"]]],[1,"ezp-icon",{name:[1],size:[1]}],[1,"ezp-label",{ellipsis:[4],level:[1],noWrap:[4,"no-wrap"],text:[1],weight:[1]}]]]],e)}));
|