@ezeep/ezeep-js 1.0.151 → 1.0.157

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.
Files changed (56) hide show
  1. package/dist/cjs/ezeep.cjs.js +3 -3
  2. package/dist/cjs/ezp-auth_14.cjs.entry.js +126 -71
  3. package/dist/cjs/{index-62fc857c.js → index-d547be4e.js} +23 -0
  4. package/dist/cjs/loader.cjs.js +3 -3
  5. package/dist/collection/collection-manifest.json +2 -2
  6. package/dist/collection/components/ezp-auth/ezp-auth.js +1 -3
  7. package/dist/collection/components/ezp-dialog/ezp-dialog.js +0 -2
  8. package/dist/collection/components/ezp-printer-selection/ezp-printer-selection.js +87 -52
  9. package/dist/collection/components/ezp-printing/ezp-printing.js +24 -3
  10. package/dist/collection/components/ezp-status/ezp-status.js +0 -2
  11. package/dist/collection/components/ezp-upload/ezp-upload.js +0 -2
  12. package/dist/collection/components/ezp-user-menu/ezp-user-menu.js +0 -2
  13. package/dist/collection/services/auth.js +2 -0
  14. package/dist/collection/utils/utils.js +20 -8
  15. package/dist/custom-elements/index.js +127 -72
  16. package/dist/directives/proxies.ts +2 -2
  17. package/dist/esm/ezeep.js +3 -3
  18. package/dist/esm/ezp-auth_14.entry.js +126 -71
  19. package/dist/esm/{index-265d8cca.js → index-485041ac.js} +23 -0
  20. package/dist/esm/loader.js +3 -3
  21. package/dist/esm/polyfills/css-shim.js +1 -1
  22. package/dist/esm-es5/ezeep.js +1 -1
  23. package/dist/esm-es5/ezp-auth_14.entry.js +3 -3
  24. package/dist/esm-es5/index-485041ac.js +1 -0
  25. package/dist/esm-es5/loader.js +1 -1
  26. package/dist/ezeep/ezeep.esm.js +1 -1
  27. package/dist/ezeep/ezeep.js +1 -1
  28. package/dist/ezeep/p-cc2bb341.system.js +1 -0
  29. package/dist/ezeep/p-d4dae139.system.js +1 -0
  30. package/dist/ezeep/p-e149771a.system.entry.js +21 -0
  31. package/dist/ezeep/{p-a7b7b386.entry.js → p-f310e367.entry.js} +2 -2
  32. package/dist/ezeep/{p-f3065800.js → p-fa808a39.js} +0 -0
  33. package/dist/types/components/ezp-printer-selection/ezp-printer-selection.d.ts +1 -1
  34. package/dist/types/components/ezp-printing/ezp-printing.d.ts +1 -0
  35. package/dist/types/components.d.ts +2 -0
  36. package/dist/types/stencil-public-runtime.d.ts +6 -4
  37. package/dist/types/utils/utils.d.ts +1 -1
  38. package/package.json +2 -2
  39. package/readme.md +2 -0
  40. package/www/build/ezeep.esm.js +1 -1
  41. package/www/build/ezeep.js +1 -1
  42. package/www/build/p-cc2bb341.system.js +1 -0
  43. package/www/build/p-d4dae139.system.js +1 -0
  44. package/www/build/p-e149771a.system.entry.js +21 -0
  45. package/www/build/{p-a7b7b386.entry.js → p-f310e367.entry.js} +2 -2
  46. package/www/build/{p-f3065800.js → p-fa808a39.js} +0 -0
  47. package/www/data/locales/de.json +7 -3
  48. package/www/data/locales/en.json +6 -2
  49. package/www/index.html +1 -1
  50. package/dist/esm-es5/index-265d8cca.js +0 -1
  51. package/dist/ezeep/p-98ec6965.system.js +0 -1
  52. package/dist/ezeep/p-a1b0d17a.system.entry.js +0 -21
  53. package/dist/ezeep/p-f89804ee.system.js +0 -1
  54. package/www/build/p-98ec6965.system.js +0 -1
  55. package/www/build/p-a1b0d17a.system.entry.js +0 -21
  56. package/www/build/p-f89804ee.system.js +0 -1
@@ -1,4 +1,4 @@
1
- import { g as getRenderingRef, f as forceUpdate, r as registerInstance, c as createEvent, h, H as Host, a as getElement, d as getAssetPath, F as Fragment } from './index-265d8cca.js';
1
+ import { g as getRenderingRef, f as forceUpdate, r as registerInstance, c as createEvent, h, H as Host, a as getElement, d as getAssetPath, F as Fragment } from './index-485041ac.js';
2
2
 
3
3
  const appendToMap = (map, propName, value) => {
4
4
  const items = map.get(propName);
@@ -2864,7 +2864,11 @@ const printer_selection$1 = {
2864
2864
  unknown_location: "Unbekannter Standort",
2865
2865
  no_printers: "Keine Drucker gefunden.",
2866
2866
  prepare_upload: "Vorbereiten…",
2867
- uploading: "Hochladen…"
2867
+ uploading: "Hochladen…",
2868
+ duplex_none: "Keine",
2869
+ copies: "Kopien",
2870
+ duplex_long: "auf der langen Seite umdrehen",
2871
+ duplex_short: "auf der kurzen Seite umdrehen"
2868
2872
  };
2869
2873
  const button_actions$1 = {
2870
2874
  login: "Anmelden",
@@ -2881,12 +2885,12 @@ const upload$1 = {
2881
2885
  };
2882
2886
  const user_menu$1 = {
2883
2887
  theme: "Farbschema",
2884
- appearance: "Erscheinungsbild",
2888
+ appearance: "Darstellung",
2885
2889
  system: "System",
2886
2890
  light: "Hell",
2887
2891
  dark: "Dunkel",
2888
2892
  account: "Account verwalten",
2889
- help: "Hilfe & Support",
2893
+ help: "Hilfe & Unterstützung",
2890
2894
  logout: "Ausloggen"
2891
2895
  };
2892
2896
  const translationsDE = {
@@ -2922,6 +2926,9 @@ const printer_selection = {
2922
2926
  orientation: "Orientation",
2923
2927
  size: "Paper Size",
2924
2928
  duplex: "Double-sided",
2929
+ duplex_none: "None",
2930
+ duplex_long: "flip on long side",
2931
+ duplex_short: "flip on short side",
2925
2932
  quality: "Print Quality",
2926
2933
  select_printer: "Select a printer",
2927
2934
  select_color: "Select Color/Grayscale",
@@ -2934,7 +2941,8 @@ const printer_selection = {
2934
2941
  orientation_portrait: "Portrait",
2935
2942
  orientation_landscape: "Landscape",
2936
2943
  unknown_location: "Unknown location",
2937
- no_printers: "No printers found."
2944
+ no_printers: "No printers found.",
2945
+ copies: "Copies"
2938
2946
  };
2939
2947
  const button_actions = {
2940
2948
  login: "Sign In",
@@ -2956,7 +2964,7 @@ const user_menu = {
2956
2964
  light: "Light",
2957
2965
  dark: "Dark",
2958
2966
  account: "Manage account",
2959
- help: "Help & support",
2967
+ help: "Help & Support",
2960
2968
  logout: "Logout"
2961
2969
  };
2962
2970
  const translationsEN = {
@@ -2973,7 +2981,7 @@ function encodeFormData(data) {
2973
2981
  .map((key) => encodeURIComponent(key) + '=' + encodeURIComponent(data[key]))
2974
2982
  .join('&');
2975
2983
  }
2976
- function initi18n() {
2984
+ function initi18n(language) {
2977
2985
  const resources = {
2978
2986
  en: {
2979
2987
  translation: translationsEN,
@@ -2982,13 +2990,25 @@ function initi18n() {
2982
2990
  translation: translationsDE,
2983
2991
  },
2984
2992
  };
2985
- i18next.init({
2986
- resources,
2987
- lng: navigator.language,
2988
- // allow keys to be phrases having `:`, `.`
2989
- nsSeparator: false,
2990
- fallbackLng: 'en',
2991
- });
2993
+ // override browserlanguage if language is provided
2994
+ if (language != '') {
2995
+ i18next.init({
2996
+ resources,
2997
+ lng: language,
2998
+ // allow keys to be phrases having `:`, `.`
2999
+ nsSeparator: false,
3000
+ fallbackLng: 'en',
3001
+ });
3002
+ }
3003
+ else {
3004
+ i18next.init({
3005
+ resources,
3006
+ lng: navigator.language,
3007
+ // allow keys to be phrases having `:`, `.`
3008
+ nsSeparator: false,
3009
+ fallbackLng: 'en',
3010
+ });
3011
+ }
2992
3012
  }
2993
3013
  const poll = async ({ fn, validate, interval, maxAttempts }) => {
2994
3014
  let attempts = 0;
@@ -3056,6 +3076,7 @@ class EzpAuthorizationService {
3056
3076
  }
3057
3077
  getAccessToken() {
3058
3078
  return fetch(this.accessTokenURL, {
3079
+ credentials: 'include',
3059
3080
  headers: {
3060
3081
  Authorization: 'Basic ' + btoa(this.clientID + ':'),
3061
3082
  'Content-Type': 'application/x-www-form-urlencoded',
@@ -3089,6 +3110,7 @@ class EzpAuthorizationService {
3089
3110
  }
3090
3111
  refreshTokens() {
3091
3112
  fetch(this.accessTokenURL, {
3113
+ credentials: 'include',
3092
3114
  headers: {
3093
3115
  Authorization: 'Basic ' + btoa(this.clientID + ':'),
3094
3116
  'Content-Type': 'application/x-www-form-urlencoded',
@@ -3189,13 +3211,12 @@ let EzpAuth = class {
3189
3211
  }
3190
3212
  receiveMessage(event) {
3191
3213
  this.auth.code = event.data;
3192
- this.auth.getAccessToken().finally(() => {
3214
+ this.auth.getAccessToken().then(() => {
3193
3215
  this.authCancel.emit();
3194
3216
  this.authSuccess.emit();
3195
3217
  });
3196
3218
  }
3197
3219
  async componentWillLoad() {
3198
- initi18n();
3199
3220
  this.auth = new EzpAuthorizationService(this.redirectURI, this.clientID);
3200
3221
  if (authStore.state.isAuthorized === false) {
3201
3222
  this.auth.generateCodeVerifier();
@@ -3265,7 +3286,6 @@ let EzpDialog = class {
3265
3286
  *
3266
3287
  */
3267
3288
  componentWillLoad() {
3268
- initi18n();
3269
3289
  }
3270
3290
  /**
3271
3291
  *
@@ -32679,15 +32699,15 @@ let EzpPrinterSelection = class {
32679
32699
  this.duplexOptions = [
32680
32700
  {
32681
32701
  id: 1,
32682
- title: 'None',
32702
+ title: i18next.t('printer_selection.duplex_none'),
32683
32703
  },
32684
32704
  {
32685
32705
  id: 2,
32686
- title: 'Long edge binding',
32706
+ title: i18next.t('printer_selection.duplex_long'),
32687
32707
  },
32688
32708
  {
32689
32709
  id: 3,
32690
- title: 'Short edge binding',
32710
+ title: i18next.t('printer_selection.duplex_short'),
32691
32711
  },
32692
32712
  ];
32693
32713
  this.hidemenu = false;
@@ -32725,16 +32745,6 @@ let EzpPrinterSelection = class {
32725
32745
  copies: '',
32726
32746
  resolution: '',
32727
32747
  };
32728
- this.previouslySelectedProperties = {
32729
- paper: '',
32730
- paperid: '',
32731
- color: false,
32732
- duplex: false,
32733
- duplexmode: '',
32734
- orientation: '',
32735
- copies: '',
32736
- resolution: '',
32737
- };
32738
32748
  /**
32739
32749
  *
32740
32750
  * Private methods
@@ -32779,6 +32789,10 @@ let EzpPrinterSelection = class {
32779
32789
  }
32780
32790
  })
32781
32791
  .then((data) => {
32792
+ if (data.code === 804) {
32793
+ this.printFailed = true;
32794
+ this.printProcessing = false;
32795
+ }
32782
32796
  if (data.jobid) {
32783
32797
  printStore.state.jobID = data.jobid;
32784
32798
  poll({
@@ -32788,15 +32802,19 @@ let EzpPrinterSelection = class {
32788
32802
  maxAttempts: 10,
32789
32803
  }).catch((err) => {
32790
32804
  console.warn(err);
32805
+ this.printFailed = true;
32806
+ this.printProcessing = false;
32791
32807
  });
32792
32808
  }
32793
32809
  else {
32794
32810
  this.printFailed = true;
32811
+ this.printProcessing = false;
32795
32812
  }
32796
32813
  })
32797
32814
  .catch((error) => {
32798
32815
  console.log(error);
32799
32816
  this.printFailed = true;
32817
+ this.printProcessing = false;
32800
32818
  });
32801
32819
  }
32802
32820
  if (this.file) {
@@ -32804,7 +32822,6 @@ let EzpPrinterSelection = class {
32804
32822
  }
32805
32823
  localStorage.setItem('properties', JSON.stringify(this.selectedProperties));
32806
32824
  localStorage.setItem('printer', JSON.stringify(this.selectedPrinter));
32807
- localStorage.setItem('previouslySelectedProperties', JSON.stringify(this.previouslySelectedProperties));
32808
32825
  this.printStopped = false;
32809
32826
  };
32810
32827
  this.handleUserMenu = () => {
@@ -32876,9 +32893,6 @@ let EzpPrinterSelection = class {
32876
32893
  else {
32877
32894
  this.selectedPrinter = { id: '', location: '', name: '' };
32878
32895
  }
32879
- if (localStorage.getItem('previouslySelectedProperties')) {
32880
- this.previouslySelectedProperties = JSON.parse(localStorage.getItem('previouslySelectedProperties'));
32881
- }
32882
32896
  }
32883
32897
  getUserInfo() {
32884
32898
  const userService = new EzpUserService();
@@ -32895,24 +32909,20 @@ let EzpPrinterSelection = class {
32895
32909
  await this.printService
32896
32910
  .getPrinterProperties(authStore.state.accessToken, this.selectedPrinter.id)
32897
32911
  .then((data) => (this.selectedPrinterConfig = data[0]));
32912
+ this.setDefaultPaperFormat();
32898
32913
  break;
32899
32914
  case 'color':
32900
32915
  this.selectedProperties.color = !!eventDetails.id;
32901
- this.previouslySelectedProperties.color = eventDetails.title;
32902
32916
  break;
32903
32917
  case 'orientation':
32904
32918
  this.selectedProperties.orientation = eventDetails.id;
32905
- this.previouslySelectedProperties.orientation = eventDetails.title;
32906
32919
  break;
32907
32920
  case 'format':
32908
32921
  this.selectedProperties.paper = eventDetails.title;
32909
32922
  this.selectedProperties.paperid = eventDetails.id;
32910
- this.previouslySelectedProperties.paper = eventDetails.title;
32911
- this.previouslySelectedProperties.paperid = eventDetails.id;
32912
32923
  break;
32913
32924
  case 'quality':
32914
32925
  this.selectedProperties.resolution = eventDetails.title;
32915
- this.previouslySelectedProperties.resolution = eventDetails.title;
32916
32926
  break;
32917
32927
  case 'duplex':
32918
32928
  if (eventDetails.title === 'None') {
@@ -32922,7 +32932,6 @@ let EzpPrinterSelection = class {
32922
32932
  this.selectedProperties.duplex = true;
32923
32933
  }
32924
32934
  this.selectedProperties.duplexmode = eventDetails.id;
32925
- this.previouslySelectedProperties.duplexmode = eventDetails.id;
32926
32935
  break;
32927
32936
  }
32928
32937
  }
@@ -32947,6 +32956,10 @@ let EzpPrinterSelection = class {
32947
32956
  this.printService
32948
32957
  .printByFileID(authStore.state.accessToken, this.fileid, this.filetype, this.selectedPrinter.id, this.selectedProperties, this.filename)
32949
32958
  .then((data) => {
32959
+ if (data.code === 804) {
32960
+ this.printFailed = true;
32961
+ this.printProcessing = false;
32962
+ }
32950
32963
  if (data.jobid) {
32951
32964
  printStore.state.jobID = data.jobid;
32952
32965
  poll({
@@ -32957,21 +32970,40 @@ let EzpPrinterSelection = class {
32957
32970
  }).catch((err) => {
32958
32971
  console.log(err);
32959
32972
  this.printFailed = true;
32973
+ this.printProcessing = false;
32960
32974
  });
32961
32975
  }
32962
32976
  else {
32963
32977
  this.printFailed = true;
32978
+ this.printProcessing = false;
32964
32979
  }
32965
32980
  })
32966
32981
  .catch((error) => {
32967
32982
  console.log(error);
32968
32983
  this.printFailed = true;
32984
+ this.printProcessing = false;
32969
32985
  });
32970
32986
  }
32971
32987
  else {
32972
32988
  this.printFailed = true;
32989
+ this.printProcessing = false;
32973
32990
  }
32974
32991
  }
32992
+ setDefaultPaperFormat() {
32993
+ let format;
32994
+ const language = navigator.language;
32995
+ if (language === 'en-US') {
32996
+ format = 'Letter';
32997
+ }
32998
+ else if (language === 'my') {
32999
+ format = 'Letter';
33000
+ }
33001
+ else {
33002
+ format = 'A4';
33003
+ }
33004
+ this.selectedProperties.paper = this.selectedPrinterConfig.PaperFormats.find((el) => el.Name === format).Name;
33005
+ this.selectedProperties.paperid = this.selectedPrinterConfig.PaperFormats.find((el) => el.Name === format).Id;
33006
+ }
32975
33007
  /**
32976
33008
  *
32977
33009
  * Lifecycle methods
@@ -32979,11 +33011,19 @@ let EzpPrinterSelection = class {
32979
33011
  */
32980
33012
  /** Description... */
32981
33013
  async componentWillLoad() {
32982
- initi18n();
32983
33014
  this.loading = true;
32984
33015
  this.getPropertiesFromLocalStorage();
32985
33016
  this.getUserInfo();
32986
33017
  this.printService = new EzpPrintService(this.redirectURI, this.clientID);
33018
+ // if printer is stored from previous print, get the config to enable property selection
33019
+ if (this.selectedPrinter.id != '') {
33020
+ await this.printService
33021
+ .getPrinterProperties(authStore.state.accessToken, this.selectedPrinter.id)
33022
+ .then((data) => (this.selectedPrinterConfig = data[0]));
33023
+ if (this.selectedProperties.paper === '') {
33024
+ this.setDefaultPaperFormat();
33025
+ }
33026
+ }
32987
33027
  await (await this.printService.getConfig(authStore.state.accessToken))
32988
33028
  .json()
32989
33029
  .then((response) => {
@@ -33028,7 +33068,9 @@ let EzpPrinterSelection = class {
33028
33068
  ? printer.location
33029
33069
  : i18next.t('printer_selection.unknown_location'),
33030
33070
  type: 'printer',
33031
- })), preSelected: this.selectedPrinter ? this.selectedPrinter.name : null, disabled: !(this.printers.length > 0) })), 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
33071
+ })),
33072
+ // preSelected={this.selectedPrinter ? this.selectedPrinter.name : null}
33073
+ disabled: !(this.printers.length > 0) })), 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
33032
33074
  ? [
33033
33075
  {
33034
33076
  id: 1,
@@ -33052,11 +33094,25 @@ let EzpPrinterSelection = class {
33052
33094
  },
33053
33095
  ],
33054
33096
  // preSelected={
33055
- // this.previouslySelectedProperties.color
33056
- // ? this.previouslySelectedProperties.color
33057
- // : this.selectedPrinterConfig.Color
33058
- // ? i18next.t('printer_selection.color_grayscale')
33059
- // : null
33097
+ // this.selectedProperties.color ?
33098
+ // [
33099
+ // {
33100
+ // id: 1,
33101
+ // title: i18next.t('printer_selection.color'),
33102
+ // meta: '',
33103
+ // type: 'color',
33104
+ // },
33105
+ // ]
33106
+ // : !this.selectedProperties.color ?
33107
+ // [
33108
+ // {
33109
+ // id: 0,
33110
+ // title: i18next.t('printer_selection.color_grayscale'),
33111
+ // meta: '',
33112
+ // type: 'color',
33113
+ // },
33114
+ // ]
33115
+ // : null
33060
33116
  // }
33061
33117
  disabled: !this.selectedPrinterConfig.Color }), h("ezp-select", { label: i18next.t('printer_selection.duplex'), icon: "duplex", placeholder: i18next.t('printer_selection.select_duplex'), toggleFlow: "horizontal", options: this.duplexOptions.map((option) => ({
33062
33118
  id: option.id,
@@ -33065,10 +33121,10 @@ let EzpPrinterSelection = class {
33065
33121
  type: 'duplex',
33066
33122
  })),
33067
33123
  // preSelected={
33068
- // this.previouslySelectedProperties.duplex
33069
- // ? this.previouslySelectedProperties.duplex
33070
- // : this.selectedPrinterConfig.DuplexSupported
33071
- // ? 'None'
33124
+ // this.selectedProperties.duplex
33125
+ // ? this.selectedProperties.duplex
33126
+ // // : this.selectedPrinterConfig.DuplexSupported
33127
+ // // ? 'None'
33072
33128
  // : null
33073
33129
  // }
33074
33130
  disabled: !this.selectedPrinterConfig.DuplexSupported }), 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) => ({
@@ -33078,10 +33134,10 @@ let EzpPrinterSelection = class {
33078
33134
  type: 'format',
33079
33135
  })),
33080
33136
  // preSelected={
33081
- // this.previouslySelectedProperties.paper
33082
- // ? this.previouslySelectedProperties.paper
33083
- // : this.selectedPrinterConfig.PaperFormats.length > 0
33084
- // ? this.selectedPrinterConfig.PaperFormats[0].Name
33137
+ // this.selectedProperties.paper
33138
+ // ? this.selectedProperties.paper
33139
+ // // : this.selectedPrinterConfig.PaperFormats.length > 0
33140
+ // // ? this.selectedPrinterConfig.PaperFormats[0].Name
33085
33141
  // : null
33086
33142
  // }
33087
33143
  disabled: !(this.selectedPrinterConfig.PaperFormats.length > 0) }), 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) => ({
@@ -33091,12 +33147,12 @@ let EzpPrinterSelection = class {
33091
33147
  type: 'orientation',
33092
33148
  })),
33093
33149
  // preSelected={
33094
- // this.previouslySelectedProperties.orientation
33095
- // ? this.previouslySelectedProperties.orientation
33096
- // : this.selectedPrinterConfig.OrientationsSupported.length > 0
33097
- // ? i18next.t(
33098
- // `printer_selection.orientation_${this.selectedPrinterConfig.OrientationsSupported[0]}`
33099
- // )
33150
+ // this.selectedProperties.orientation
33151
+ // ? this.selectedProperties.orientation
33152
+ // // : this.selectedPrinterConfig.OrientationsSupported.length > 0
33153
+ // // ? i18next.t(
33154
+ // // `printer_selection.orientation_${this.selectedPrinterConfig.OrientationsSupported[0]}`
33155
+ // // )
33100
33156
  // : null
33101
33157
  // }
33102
33158
  disabled: !(this.selectedPrinterConfig.OrientationsSupported.length > 0) }), h("ezp-select", { label: i18next.t('printer_selection.quality'), icon: "quality", placeholder: i18next.t('printer_selection.select_quality'), toggleFlow: "horizontal", options: this.selectedPrinterConfig.Resolutions.map((option, index) => ({
@@ -33106,13 +33162,13 @@ let EzpPrinterSelection = class {
33106
33162
  type: 'quality',
33107
33163
  })),
33108
33164
  // preSelected={
33109
- // this.previouslySelectedProperties.resolution
33110
- // ? this.previouslySelectedProperties.resolution
33111
- // : this.selectedPrinterConfig.Resolutions.length > 0
33112
- // ? this.selectedPrinterConfig.Resolutions[0]
33165
+ // this.selectedProperties.resolution
33166
+ // ? this.selectedProperties.resolution
33167
+ // // : this.selectedPrinterConfig.Resolutions.length > 0
33168
+ // // ? this.selectedPrinterConfig.Resolutions[0]
33113
33169
  // : null
33114
33170
  // }
33115
- disabled: !(this.selectedPrinterConfig.Resolutions.length > 0) })), h("ezp-stepper", { label: "Copies", max: 10, icon: "copies" })), h("div", { id: "footer" }, h("ezp-text-button", { type: "button", level: "secondary", onClick: this.handleCancel, label: i18next.t('button_actions.cancel') }), h("ezp-text-button", { disabled: this.selectedPrinter.id === '', type: "button", onClick: this.handlePrint, label: i18next.t('button_actions.print') })), !this.hidemenu && h("ezp-user-menu", { open: this.userMenuOpen, name: this.userName }))));
33171
+ disabled: !(this.selectedPrinterConfig.Resolutions.length > 0) })), h("ezp-stepper", { label: i18next.t('printer_selection.copies'), max: 10, icon: "copies" })), h("div", { id: "footer" }, h("ezp-text-button", { type: "button", level: "secondary", onClick: this.handleCancel, label: i18next.t('button_actions.cancel') }), h("ezp-text-button", { disabled: this.selectedPrinter.id === '', type: "button", onClick: this.handlePrint, label: i18next.t('button_actions.print') })), !this.hidemenu && h("ezp-user-menu", { open: this.userMenuOpen, name: this.userName }))));
33116
33172
  }
33117
33173
  };
33118
33174
  EzpPrinterSelection.style = ezpPrinterSelectionCss;
@@ -33129,9 +33185,11 @@ const ezpPrintingCss = ":host{font-family:\"Inter\", sans-serif;-webkit-font-fea
33129
33185
  let EzpPrinting = class {
33130
33186
  constructor(hostRef) {
33131
33187
  registerInstance(this, hostRef);
33188
+ this.filename = '';
33132
33189
  this.hidemenu = false;
33133
33190
  this.theme = 'cyan';
33134
33191
  this.appearance = 'system';
33192
+ this.language = '';
33135
33193
  /**
33136
33194
  *
33137
33195
  * States
@@ -33160,7 +33218,7 @@ let EzpPrinting = class {
33160
33218
  this.authOpen = false;
33161
33219
  }
33162
33220
  listenAuthSuccess() {
33163
- if (this.filename) {
33221
+ if (this.filename != '') {
33164
33222
  this.printOpen = true;
33165
33223
  }
33166
33224
  else {
@@ -33246,7 +33304,7 @@ let EzpPrinting = class {
33246
33304
  else {
33247
33305
  printStore.state.printApiHostUrl = config.printingApiHostUrl;
33248
33306
  }
33249
- initi18n();
33307
+ initi18n(this.language);
33250
33308
  sendCodeToParentWindow();
33251
33309
  this.checkAuth();
33252
33310
  }
@@ -33445,7 +33503,6 @@ let EzpStatus = class {
33445
33503
  *
33446
33504
  */
33447
33505
  componentWillLoad() {
33448
- initi18n();
33449
33506
  }
33450
33507
  /**
33451
33508
  *
@@ -33626,7 +33683,6 @@ let EzpUpload = class {
33626
33683
  *
33627
33684
  */
33628
33685
  componentWillLoad() {
33629
- initi18n();
33630
33686
  }
33631
33687
  /**
33632
33688
  *
@@ -33708,7 +33764,6 @@ let EzpUserMenu = class {
33708
33764
  *
33709
33765
  */
33710
33766
  componentWillLoad() {
33711
- initi18n();
33712
33767
  this.container = this.component.closest('[data-backdrop-surface]');
33713
33768
  this.backdrop.addEventListener('backdropHideStart', () => {
33714
33769
  this.open = false;
@@ -911,6 +911,29 @@ const then = (promise, thenFn) => {
911
911
  };
912
912
  const addHydratedFlag = (elm) => elm.classList.add('hydrated')
913
913
  ;
914
+ /**
915
+ * Parse a new property value for a given property type.
916
+ *
917
+ * While the prop value can reasonably be expected to be of `any` type as far as TypeScript's type checker is concerned,
918
+ * it is not safe to assume that the string returned by evaluating `typeof propValue` matches:
919
+ * 1. `any`, the type given to `propValue` in the function signature
920
+ * 2. the type stored from `propType`.
921
+ *
922
+ * This function provides the capability to parse/coerce a property's value to potentially any other JavaScript type.
923
+ *
924
+ * Property values represented in TSX preserve their type information. In the example below, the number 0 is passed to
925
+ * a component. This `propValue` will preserve its type information (`typeof propValue === 'number'`). Note that is
926
+ * based on the type of the value being passed in, not the type declared of the class member decorated with `@Prop`.
927
+ * ```tsx
928
+ * <my-cmp prop-val={0}></my-cmp>
929
+ * ```
930
+ *
931
+ * HTML prop values on the other hand, will always a string
932
+ *
933
+ * @param propValue the new value to coerce to some type
934
+ * @param propType the type of the prop, expressed as a binary number
935
+ * @returns the parsed/coerced value
936
+ */
914
937
  const parsePropertyValue = (propValue, propType) => {
915
938
  // ensure this value is of the correct prop type
916
939
  if (propValue != null && !isComplexType(propValue)) {
@@ -1,8 +1,8 @@
1
- import { p as promiseResolve, b as bootstrapLazy } from './index-265d8cca.js';
1
+ import { p as promiseResolve, b as bootstrapLazy } from './index-485041ac.js';
2
2
  import { g as globalScripts } from './app-globals-28960cbc.js';
3
3
 
4
4
  /*
5
- Stencil Client Patch Esm v2.11.0 | MIT Licensed | https://stenciljs.com
5
+ Stencil Client Patch Esm v2.14.0 | MIT Licensed | https://stenciljs.com
6
6
  */
7
7
  const patchEsm = () => {
8
8
  return promiseResolve();
@@ -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_14",[[1,"ezp-printing",{"clientid":[1],"redirecturi":[1],"filename":[1025],"fileurl":[1],"filetype":[1],"custom":[4],"hidelogin":[4],"hidemenu":[4],"authapihosturl":[1],"printapihosturl":[1],"theme":[1],"fileid":[1],"appearance":[1],"trigger":[1],"printOpen":[32],"authOpen":[32],"noDocumentOpen":[32],"systemAppearance":[32],"open":[64]},[[0,"printCancel","listenPrintCancel"],[0,"printSubmit","listenPrintSubmit"],[0,"authCancel","listenAuthCancel"],[0,"authSuccess","listenAuthSuccess"],[0,"uploadFile","listenUploadFile"],[0,"dialogClose","listenDialogClose"],[0,"dialogAction","listenDialogAction"]]],[1,"ezp-printer-selection",{"clientID":[1,"client-i-d"],"redirectURI":[1,"redirect-u-r-i"],"filename":[1025],"fileurl":[1],"filetype":[1025],"fileid":[1025],"file":[16],"hidemenu":[4],"loading":[32],"options":[32],"printProcessing":[32],"uploading":[32],"preparingUpload":[32],"printSuccess":[32],"printFailed":[32],"notSupported":[32],"noPrinters":[32],"userMenuOpen":[32],"printStopped":[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"],[0,"statusCancel","listenStatusCancel"],[0,"statusClose","listenStatusClose"],[0,"statusRetry","listenStatusRetry"]]],[1,"ezp-auth",{"clientID":[1025,"client-i-d"],"redirectURI":[1025,"redirect-u-r-i"],"hidelogin":[4],"auth":[32],"authURI":[32],"accessToken":[32]},[[0,"dialogAction","listenDialogAction"],[0,"dialogClose","listenDialogClose"]]],[1,"ezp-upload",{"dragging":[32]},[[1,"dragenter","handleDragEnter"],[0,"dragover","handleDragOver"],[1,"dragleave","handleDragLeave"],[0,"drop","handleDrop"]]],[1,"ezp-dialog",{"heading":[1],"description":[1],"action":[1],"iconName":[1,"icon-name"],"iconSize":[1,"icon-size"],"iconFramed":[4,"icon-framed"],"instance":[1]}],[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"],"disabled":[4],"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-status",{"description":[1],"processing":[4],"instance":[1],"icon":[1],"cancel":[8],"close":[8],"retry":[8]}],[1,"ezp-backdrop",{"visible":[1028]},[[0,"animationend","listenAnimationEnd"]]],[1,"ezp-icon-button",{"blank":[4],"disabled":[4],"href":[1],"icon":[1],"level":[1],"type":[1]}],[1,"ezp-text-button",{"blank":[4],"disabled":[4],"href":[1],"level":[1],"label":[1],"type":[1],"small":[4]}],[1,"ezp-icon",{"name":[1],"size":[1],"framed":[4]}],[1,"ezp-label",{"ellipsis":[4],"level":[1],"noWrap":[4,"no-wrap"],"text":[1],"weight":[1]}]]]], options);
15
+ return bootstrapLazy([["ezp-auth_14",[[1,"ezp-printing",{"clientid":[1],"redirecturi":[1],"filename":[1025],"fileurl":[1],"filetype":[1],"custom":[4],"hidelogin":[4],"hidemenu":[4],"authapihosturl":[1],"printapihosturl":[1],"theme":[1],"fileid":[1],"appearance":[1],"trigger":[1],"language":[1],"printOpen":[32],"authOpen":[32],"noDocumentOpen":[32],"systemAppearance":[32],"open":[64]},[[0,"printCancel","listenPrintCancel"],[0,"printSubmit","listenPrintSubmit"],[0,"authCancel","listenAuthCancel"],[0,"authSuccess","listenAuthSuccess"],[0,"uploadFile","listenUploadFile"],[0,"dialogClose","listenDialogClose"],[0,"dialogAction","listenDialogAction"]]],[1,"ezp-printer-selection",{"clientID":[1,"client-i-d"],"redirectURI":[1,"redirect-u-r-i"],"filename":[1025],"fileurl":[1],"filetype":[1025],"fileid":[1025],"file":[16],"hidemenu":[4],"loading":[32],"options":[32],"printProcessing":[32],"uploading":[32],"preparingUpload":[32],"printSuccess":[32],"printFailed":[32],"notSupported":[32],"noPrinters":[32],"userMenuOpen":[32],"printStopped":[32],"userName":[32],"printers":[32],"selectedPrinter":[32],"printerConfig":[32],"selectedPrinterConfig":[32],"selectedProperties":[32]},[[0,"selectSelection","listenSelectSelection"],[0,"stepperChanged","listenStepperChanged"],[0,"userMenuClosure","listenUserMenuClosure"],[0,"logoutEmitter","listenLogout"],[0,"statusCancel","listenStatusCancel"],[0,"statusClose","listenStatusClose"],[0,"statusRetry","listenStatusRetry"]]],[1,"ezp-auth",{"clientID":[1025,"client-i-d"],"redirectURI":[1025,"redirect-u-r-i"],"hidelogin":[4],"auth":[32],"authURI":[32],"accessToken":[32]},[[0,"dialogAction","listenDialogAction"],[0,"dialogClose","listenDialogClose"]]],[1,"ezp-upload",{"dragging":[32]},[[1,"dragenter","handleDragEnter"],[0,"dragover","handleDragOver"],[1,"dragleave","handleDragLeave"],[0,"drop","handleDrop"]]],[1,"ezp-dialog",{"heading":[1],"description":[1],"action":[1],"iconName":[1,"icon-name"],"iconSize":[1,"icon-size"],"iconFramed":[4,"icon-framed"],"instance":[1]}],[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"],"disabled":[4],"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-status",{"description":[1],"processing":[4],"instance":[1],"icon":[1],"cancel":[8],"close":[8],"retry":[8]}],[1,"ezp-backdrop",{"visible":[1028]},[[0,"animationend","listenAnimationEnd"]]],[1,"ezp-icon-button",{"blank":[4],"disabled":[4],"href":[1],"icon":[1],"level":[1],"type":[1]}],[1,"ezp-text-button",{"blank":[4],"disabled":[4],"href":[1],"level":[1],"label":[1],"type":[1],"small":[4]}],[1,"ezp-icon",{"name":[1],"size":[1],"framed":[4]}],[1,"ezp-label",{"ellipsis":[4],"level":[1],"noWrap":[4,"no-wrap"],"text":[1],"weight":[1]}]]]], options);
16
16
  });
17
17
  };
18
18
 
@@ -1 +1 @@
1
- var __assign=this&&this.__assign||function(){return(__assign=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var s in t=arguments[r])Object.prototype.hasOwnProperty.call(t,s)&&(e[s]=t[s]);return e}).apply(this,arguments)},StyleNode=function(){this.start=0,this.end=0,this.previous=null,this.parent=null,this.rules=null,this.parsedCssText="",this.cssText="",this.atRule=!1,this.type=0,this.keyframesName="",this.selector="",this.parsedSelector=""};function parse(e){return parseCss(lex(e=clean(e)),e)}function clean(e){return e.replace(RX.comments,"").replace(RX.port,"")}function lex(e){var t=new StyleNode;t.start=0,t.end=e.length;for(var r=t,n=0,s=e.length;n<s;n++)if(e[n]===OPEN_BRACE){r.rules||(r.rules=[]);var o=r,a=o.rules[o.rules.length-1]||null;(r=new StyleNode).start=n+1,r.parent=o,r.previous=a,o.rules.push(r)}else e[n]===CLOSE_BRACE&&(r.end=n+1,r=r.parent||t);return t}function parseCss(e,t){var r=t.substring(e.start,e.end-1);if(e.parsedCssText=e.cssText=r.trim(),e.parent){var n=e.previous?e.previous.end:e.parent.start;r=(r=(r=_expandUnicodeEscapes(r=t.substring(n,e.start-1))).replace(RX.multipleSpaces," ")).substring(r.lastIndexOf(";")+1);var s=e.parsedSelector=e.selector=r.trim();e.atRule=0===s.indexOf(AT_START),e.atRule?0===s.indexOf(MEDIA_START)?e.type=types.MEDIA_RULE:s.match(RX.keyframesRule)&&(e.type=types.KEYFRAMES_RULE,e.keyframesName=e.selector.split(RX.multipleSpaces).pop()):0===s.indexOf(VAR_START)?e.type=types.MIXIN_RULE:e.type=types.STYLE_RULE}var o=e.rules;if(o)for(var a=0,i=o.length,l=void 0;a<i&&(l=o[a]);a++)parseCss(l,t);return e}function _expandUnicodeEscapes(e){return e.replace(/\\([0-9a-f]{1,6})\s/gi,(function(){for(var e=arguments[1],t=6-e.length;t--;)e="0"+e;return"\\"+e}))}var types={STYLE_RULE:1,KEYFRAMES_RULE:7,MEDIA_RULE:4,MIXIN_RULE:1e3},OPEN_BRACE="{",CLOSE_BRACE="}",RX={comments:/\/\*[^*]*\*+([^/*][^*]*\*+)*\//gim,port:/@import[^;]*;/gim,customProp:/(?:^[^;\-\s}]+)?--[^;{}]*?:[^{};]*?(?:[;\n]|$)/gim,mixinProp:/(?:^[^;\-\s}]+)?--[^;{}]*?:[^{};]*?{[^}]*?}(?:[;\n]|$)?/gim,mixinApply:/@apply\s*\(?[^);]*\)?\s*(?:[;\n]|$)?/gim,varApply:/[^;:]*?:[^;]*?var\([^;]*\)(?:[;\n]|$)?/gim,keyframesRule:/^@[^\s]*keyframes/,multipleSpaces:/\s+/g},VAR_START="--",MEDIA_START="@media",AT_START="@";function findRegex(e,t,r){e.lastIndex=0;var n=t.substring(r).match(e);if(n){var s=r+n.index;return{start:s,end:s+n[0].length}}return null}var VAR_USAGE_START=/\bvar\(/,VAR_ASSIGN_START=/\B--[\w-]+\s*:/,COMMENTS=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//gim,TRAILING_LINES=/^[\t ]+\n/gm;function resolveVar(e,t,r){return e[t]?e[t]:r?executeTemplate(r,e):""}function findVarEndIndex(e,t){for(var r=0,n=t;n<e.length;n++){var s=e[n];if("("===s)r++;else if(")"===s&&--r<=0)return n+1}return n}function parseVar(e,t){var r=findRegex(VAR_USAGE_START,e,t);if(!r)return null;var n=findVarEndIndex(e,r.start),s=e.substring(r.end,n-1).split(","),o=s[0],a=s.slice(1);return{start:r.start,end:n,propName:o.trim(),fallback:a.length>0?a.join(",").trim():void 0}}function compileVar(e,t,r){var n=parseVar(e,r);if(!n)return t.push(e.substring(r,e.length)),e.length;var s=n.propName,o=null!=n.fallback?compileTemplate(n.fallback):void 0;return t.push(e.substring(r,n.start),(function(e){return resolveVar(e,s,o)})),n.end}function executeTemplate(e,t){for(var r="",n=0;n<e.length;n++){var s=e[n];r+="string"==typeof s?s:s(t)}return r}function findEndValue(e,t){for(var r=!1,n=!1,s=t;s<e.length;s++){var o=e[s];if(r)n&&'"'===o&&(r=!1),n||"'"!==o||(r=!1);else if('"'===o)r=!0,n=!0;else if("'"===o)r=!0,n=!1;else{if(";"===o)return s+1;if("}"===o)return s}}return s}function removeCustomAssigns(e){for(var t="",r=0;;){var n=findRegex(VAR_ASSIGN_START,e,r),s=n?n.start:e.length;if(t+=e.substring(r,s),!n)break;r=findEndValue(e,s)}return t}function compileTemplate(e){var t=0;e=removeCustomAssigns(e=e.replace(COMMENTS,"")).replace(TRAILING_LINES,"");for(var r=[];t<e.length;)t=compileVar(e,r,t);return r}function resolveValues(e){var t={};e.forEach((function(e){e.declarations.forEach((function(e){t[e.prop]=e.value}))}));for(var r={},n=Object.entries(t),s=function(e){var t=!1;if(n.forEach((function(e){var n=e[0],s=executeTemplate(e[1],r);s!==r[n]&&(r[n]=s,t=!0)})),!t)return"break"},o=0;o<10;o++){if("break"===s())break}return r}function getSelectors(e,t){if(void 0===t&&(t=0),!e.rules)return[];var r=[];return e.rules.filter((function(e){return e.type===types.STYLE_RULE})).forEach((function(e){var n=getDeclarations(e.cssText);n.length>0&&e.parsedSelector.split(",").forEach((function(e){e=e.trim(),r.push({selector:e,declarations:n,specificity:computeSpecificity(),nu:t})})),t++})),r}function computeSpecificity(e){return 1}var IMPORTANT="!important",FIND_DECLARATIONS=/(?:^|[;\s{]\s*)(--[\w-]*?)\s*:\s*(?:((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};{])+)|\{([^}]*)\}(?:(?=[;\s}])|$))/gm;function getDeclarations(e){for(var t,r=[];t=FIND_DECLARATIONS.exec(e.trim());){var n=normalizeValue(t[2]),s=n.value,o=n.important;r.push({prop:t[1].trim(),value:compileTemplate(s),important:o})}return r}function normalizeValue(e){var t=(e=e.replace(/\s+/gim," ").trim()).endsWith(IMPORTANT);return t&&(e=e.substr(0,e.length-IMPORTANT.length).trim()),{value:e,important:t}}function getActiveSelectors(e,t,r){var n=[],s=getScopesForElement(t,e);return r.forEach((function(e){return n.push(e)})),s.forEach((function(e){return n.push(e)})),sortSelectors(getSelectorsForScopes(n).filter((function(t){return matches(e,t.selector)})))}function getScopesForElement(e,t){for(var r=[];t;){var n=e.get(t);n&&r.push(n),t=t.parentElement}return r}function getSelectorsForScopes(e){var t=[];return e.forEach((function(e){t.push.apply(t,e.selectors)})),t}function sortSelectors(e){return e.sort((function(e,t){return e.specificity===t.specificity?e.nu-t.nu:e.specificity-t.specificity})),e}function matches(e,t){return":root"===t||"html"===t||e.matches(t)}function parseCSS(e){var t=parse(e),r=compileTemplate(e);return{original:e,template:r,selectors:getSelectors(t),usesCssVars:r.length>1}}function addGlobalStyle(e,t){if(e.some((function(e){return e.styleEl===t})))return!1;var r=parseCSS(t.textContent);return r.styleEl=t,e.push(r),!0}function updateGlobalScopes(e){var t=resolveValues(getSelectorsForScopes(e));e.forEach((function(e){e.usesCssVars&&(e.styleEl.textContent=executeTemplate(e.template,t))}))}function reScope(e,t){var r=e.template.map((function(r){return"string"==typeof r?replaceScope(r,e.scopeId,t):r})),n=e.selectors.map((function(r){return __assign(__assign({},r),{selector:replaceScope(r.selector,e.scopeId,t)})}));return __assign(__assign({},e),{template:r,selectors:n,scopeId:t})}function replaceScope(e,t,r){return e=replaceAll(e,"\\."+t,"."+r)}function replaceAll(e,t,r){return e.replace(new RegExp(t,"g"),r)}function loadDocument(e,t){return loadDocumentStyles(e,t),loadDocumentLinks(e,t).then((function(){updateGlobalScopes(t)}))}function startWatcher(e,t){"undefined"!=typeof MutationObserver&&new MutationObserver((function(){loadDocumentStyles(e,t)&&updateGlobalScopes(t)})).observe(document.head,{childList:!0})}function loadDocumentLinks(e,t){for(var r=[],n=e.querySelectorAll('link[rel="stylesheet"][href]:not([data-no-shim])'),s=0;s<n.length;s++)r.push(addGlobalLink(e,t,n[s]));return Promise.all(r)}function loadDocumentStyles(e,t){return Array.from(e.querySelectorAll("style:not([data-styles]):not([data-no-shim])")).map((function(e){return addGlobalStyle(t,e)})).some(Boolean)}function addGlobalLink(e,t,r){var n=r.href;return fetch(n).then((function(e){return e.text()})).then((function(s){if(hasCssVariables(s)&&r.parentNode){hasRelativeUrls(s)&&(s=fixRelativeUrls(s,n));var o=e.createElement("style");o.setAttribute("data-styles",""),o.textContent=s,addGlobalStyle(t,o),r.parentNode.insertBefore(o,r),r.remove()}})).catch((function(e){console.error(e)}))}var CSS_VARIABLE_REGEXP=/[\s;{]--[-a-zA-Z0-9]+\s*:/m;function hasCssVariables(e){return e.indexOf("var(")>-1||CSS_VARIABLE_REGEXP.test(e)}var CSS_URL_REGEXP=/url[\s]*\([\s]*['"]?(?!(?:https?|data)\:|\/)([^\'\"\)]*)[\s]*['"]?\)[\s]*/gim;function hasRelativeUrls(e){return CSS_URL_REGEXP.lastIndex=0,CSS_URL_REGEXP.test(e)}function fixRelativeUrls(e,t){var r=t.replace(/[^/]*$/,"");return e.replace(CSS_URL_REGEXP,(function(e,t){var n=r+t;return e.replace(t,n)}))}var CustomStyle=function(){function e(e,t){this.win=e,this.doc=t,this.count=0,this.hostStyleMap=new WeakMap,this.hostScopeMap=new WeakMap,this.globalScopes=[],this.scopesMap=new Map,this.didInit=!1}return e.prototype.i=function(){var e=this;return this.didInit||!this.win.requestAnimationFrame?Promise.resolve():(this.didInit=!0,new Promise((function(t){e.win.requestAnimationFrame((function(){startWatcher(e.doc,e.globalScopes),loadDocument(e.doc,e.globalScopes).then((function(){return t()}))}))})))},e.prototype.addLink=function(e){var t=this;return addGlobalLink(this.doc,this.globalScopes,e).then((function(){t.updateGlobal()}))},e.prototype.addGlobalStyle=function(e){addGlobalStyle(this.globalScopes,e)&&this.updateGlobal()},e.prototype.createHostStyle=function(e,t,r,n){if(this.hostScopeMap.has(e))throw new Error("host style already created");var s=this.registerHostTemplate(r,t,n),o=this.doc.createElement("style");return o.setAttribute("data-no-shim",""),s.usesCssVars?n?(o["s-sc"]=t=s.scopeId+"-"+this.count,o.textContent="/*needs update*/",this.hostStyleMap.set(e,o),this.hostScopeMap.set(e,reScope(s,t)),this.count++):(s.styleEl=o,s.usesCssVars||(o.textContent=executeTemplate(s.template,{})),this.globalScopes.push(s),this.updateGlobal(),this.hostScopeMap.set(e,s)):o.textContent=r,o},e.prototype.removeHost=function(e){var t=this.hostStyleMap.get(e);t&&t.remove(),this.hostStyleMap.delete(e),this.hostScopeMap.delete(e)},e.prototype.updateHost=function(e){var t=this.hostScopeMap.get(e);if(t&&t.usesCssVars&&t.isScoped){var r=this.hostStyleMap.get(e);if(r){var n=resolveValues(getActiveSelectors(e,this.hostScopeMap,this.globalScopes));r.textContent=executeTemplate(t.template,n)}}},e.prototype.updateGlobal=function(){updateGlobalScopes(this.globalScopes)},e.prototype.registerHostTemplate=function(e,t,r){var n=this.scopesMap.get(t);return n||((n=parseCSS(e)).scopeId=t,n.isScoped=r,this.scopesMap.set(t,n)),n},e}();!function(e){!e||e.__cssshim||e.CSS&&e.CSS.supports&&e.CSS.supports("color","var(--c)")||(e.__cssshim=new CustomStyle(e,e.document))}("undefined"!=typeof window&&window);
1
+ var __assign=this&&this.__assign||function(){return(__assign=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var s in t=arguments[r])Object.prototype.hasOwnProperty.call(t,s)&&(e[s]=t[s]);return e}).apply(this,arguments)},StyleNode=function(){this.start=0,this.end=0,this.previous=null,this.parent=null,this.rules=null,this.parsedCssText="",this.cssText="",this.atRule=!1,this.type=0,this.keyframesName="",this.selector="",this.parsedSelector=""};function parse(e){return parseCss(lex(e=clean(e)),e)}function clean(e){return e.replace(RX.comments,"").replace(RX.port,"")}function lex(e){var t=new StyleNode;t.start=0,t.end=e.length;for(var r=t,n=0,s=e.length;n<s;n++)if(e[n]===OPEN_BRACE){r.rules||(r.rules=[]);var o=r,a=o.rules[o.rules.length-1]||null;(r=new StyleNode).start=n+1,r.parent=o,r.previous=a,o.rules.push(r)}else e[n]===CLOSE_BRACE&&(r.end=n+1,r=r.parent||t);return t}function parseCss(e,t){var r=t.substring(e.start,e.end-1);if(e.parsedCssText=e.cssText=r.trim(),e.parent){var n=e.previous?e.previous.end:e.parent.start;r=(r=(r=_expandUnicodeEscapes(r=t.substring(n,e.start-1))).replace(RX.multipleSpaces," ")).substring(r.lastIndexOf(";")+1);var s=e.parsedSelector=e.selector=r.trim();e.atRule=0===s.indexOf(AT_START),e.atRule?0===s.indexOf(MEDIA_START)?e.type=types.MEDIA_RULE:s.match(RX.keyframesRule)&&(e.type=types.KEYFRAMES_RULE,e.keyframesName=e.selector.split(RX.multipleSpaces).pop()):0===s.indexOf(VAR_START)?e.type=types.MIXIN_RULE:e.type=types.STYLE_RULE}var o=e.rules;if(o)for(var a=0,i=o.length,l=void 0;a<i&&(l=o[a]);a++)parseCss(l,t);return e}function _expandUnicodeEscapes(e){return e.replace(/\\([0-9a-f]{1,6})\s/gi,(function(){for(var e=arguments[1],t=6-e.length;t--;)e="0"+e;return"\\"+e}))}var types={STYLE_RULE:1,KEYFRAMES_RULE:7,MEDIA_RULE:4,MIXIN_RULE:1e3},OPEN_BRACE="{",CLOSE_BRACE="}",RX={comments:/\/\*[^*]*\*+([^/*][^*]*\*+)*\//gim,port:/@import[^;]*;/gim,customProp:/(?:^[^;\-\s}]+)?--[^;{}]*?:[^{};]*?(?:[;\n]|$)/gim,mixinProp:/(?:^[^;\-\s}]+)?--[^;{}]*?:[^{};]*?{[^}]*?}(?:[;\n]|$)?/gim,mixinApply:/@apply\s*\(?[^);]*\)?\s*(?:[;\n]|$)?/gim,varApply:/[^;:]*?:[^;]*?var\([^;]*\)(?:[;\n]|$)?/gim,keyframesRule:/^@[^\s]*keyframes/,multipleSpaces:/\s+/g},VAR_START="--",MEDIA_START="@media",AT_START="@";function findRegex(e,t,r){e.lastIndex=0;var n=t.substring(r).match(e);if(n){var s=r+n.index;return{start:s,end:s+n[0].length}}return null}var VAR_USAGE_START=/\bvar\(/,VAR_ASSIGN_START=/\B--[\w-]+\s*:/,COMMENTS=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//gim,TRAILING_LINES=/^[\t ]+\n/gm;function resolveVar(e,t,r){return e[t]?e[t]:r?executeTemplate(r,e):""}function findVarEndIndex(e,t){for(var r=0,n=t;n<e.length;n++){var s=e[n];if("("===s)r++;else if(")"===s&&--r<=0)return n+1}return n}function parseVar(e,t){var r=findRegex(VAR_USAGE_START,e,t);if(!r)return null;var n=findVarEndIndex(e,r.start),s=e.substring(r.end,n-1).split(","),o=s[0],a=s.slice(1);return{start:r.start,end:n,propName:o.trim(),fallback:a.length>0?a.join(",").trim():void 0}}function compileVar(e,t,r){var n=parseVar(e,r);if(!n)return t.push(e.substring(r,e.length)),e.length;var s=n.propName,o=null!=n.fallback?compileTemplate(n.fallback):void 0;return t.push(e.substring(r,n.start),(function(e){return resolveVar(e,s,o)})),n.end}function executeTemplate(e,t){for(var r="",n=0;n<e.length;n++){var s=e[n];r+="string"==typeof s?s:s(t)}return r}function findEndValue(e,t){for(var r=!1,n=!1,s=t;s<e.length;s++){var o=e[s];if(r)n&&'"'===o&&(r=!1),n||"'"!==o||(r=!1);else if('"'===o)r=!0,n=!0;else if("'"===o)r=!0,n=!1;else{if(";"===o)return s+1;if("}"===o)return s}}return s}function removeCustomAssigns(e){for(var t="",r=0;;){var n=findRegex(VAR_ASSIGN_START,e,r),s=n?n.start:e.length;if(t+=e.substring(r,s),!n)break;r=findEndValue(e,s)}return t}function compileTemplate(e){var t=0;e=removeCustomAssigns(e=e.replace(COMMENTS,"")).replace(TRAILING_LINES,"");for(var r=[];t<e.length;)t=compileVar(e,r,t);return r}function resolveValues(e){var t={};e.forEach((function(e){e.declarations.forEach((function(e){t[e.prop]=e.value}))}));for(var r={},n=Object.entries(t),s=function(e){var t=!1;if(n.forEach((function(e){var n=e[0],s=executeTemplate(e[1],r);s!==r[n]&&(r[n]=s,t=!0)})),!t)return"break"},o=0;o<10;o++){if("break"===s())break}return r}function getSelectors(e,t){if(void 0===t&&(t=0),!e.rules)return[];var r=[];return e.rules.filter((function(e){return e.type===types.STYLE_RULE})).forEach((function(e){var n=getDeclarations(e.cssText);n.length>0&&e.parsedSelector.split(",").forEach((function(e){e=e.trim(),r.push({selector:e,declarations:n,specificity:computeSpecificity(),nu:t})})),t++})),r}function computeSpecificity(e){return 1}var IMPORTANT="!important",FIND_DECLARATIONS=/(?:^|[;\s{]\s*)(--[\w-]*?)\s*:\s*(?:((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};{])+)|\{([^}]*)\}(?:(?=[;\s}])|$))/gm;function getDeclarations(e){for(var t,r=[];t=FIND_DECLARATIONS.exec(e.trim());){var n=normalizeValue(t[2]),s=n.value,o=n.important;r.push({prop:t[1].trim(),value:compileTemplate(s),important:o})}return r}function normalizeValue(e){var t=(e=e.replace(/\s+/gim," ").trim()).endsWith(IMPORTANT);return t&&(e=e.substr(0,e.length-IMPORTANT.length).trim()),{value:e,important:t}}function getActiveSelectors(e,t,r){var n=[],s=getScopesForElement(t,e);return r.forEach((function(e){return n.push(e)})),s.forEach((function(e){return n.push(e)})),sortSelectors(getSelectorsForScopes(n).filter((function(t){return matches(e,t.selector)})))}function getScopesForElement(e,t){for(var r=[];t;){var n=e.get(t);n&&r.push(n),t=t.parentElement}return r}function getSelectorsForScopes(e){var t=[];return e.forEach((function(e){t.push.apply(t,e.selectors)})),t}function sortSelectors(e){return e.sort((function(e,t){return e.specificity===t.specificity?e.nu-t.nu:e.specificity-t.specificity})),e}function matches(e,t){return":root"===t||"html"===t||e.matches(t)}function parseCSS(e){var t=parse(e),r=compileTemplate(e);return{original:e,template:r,selectors:getSelectors(t),usesCssVars:r.length>1}}function addGlobalStyle(e,t){if(e.some((function(e){return e.styleEl===t})))return!1;var r=parseCSS(t.textContent);return r.styleEl=t,e.push(r),!0}function updateGlobalScopes(e){var t=resolveValues(getSelectorsForScopes(e));e.forEach((function(e){e.usesCssVars&&(e.styleEl.textContent=executeTemplate(e.template,t))}))}function reScope(e,t){var r=e.template.map((function(r){return"string"==typeof r?replaceScope(r,e.scopeId,t):r})),n=e.selectors.map((function(r){return __assign(__assign({},r),{selector:replaceScope(r.selector,e.scopeId,t)})}));return __assign(__assign({},e),{template:r,selectors:n,scopeId:t})}function replaceScope(e,t,r){return e=replaceAll(e,"\\.".concat(t),".".concat(r))}function replaceAll(e,t,r){return e.replace(new RegExp(t,"g"),r)}function loadDocument(e,t){return loadDocumentStyles(e,t),loadDocumentLinks(e,t).then((function(){updateGlobalScopes(t)}))}function startWatcher(e,t){"undefined"!=typeof MutationObserver&&new MutationObserver((function(){loadDocumentStyles(e,t)&&updateGlobalScopes(t)})).observe(document.head,{childList:!0})}function loadDocumentLinks(e,t){for(var r=[],n=e.querySelectorAll('link[rel="stylesheet"][href]:not([data-no-shim])'),s=0;s<n.length;s++)r.push(addGlobalLink(e,t,n[s]));return Promise.all(r)}function loadDocumentStyles(e,t){return Array.from(e.querySelectorAll("style:not([data-styles]):not([data-no-shim])")).map((function(e){return addGlobalStyle(t,e)})).some(Boolean)}function addGlobalLink(e,t,r){var n=r.href;return fetch(n).then((function(e){return e.text()})).then((function(s){if(hasCssVariables(s)&&r.parentNode){hasRelativeUrls(s)&&(s=fixRelativeUrls(s,n));var o=e.createElement("style");o.setAttribute("data-styles",""),o.textContent=s,addGlobalStyle(t,o),r.parentNode.insertBefore(o,r),r.remove()}})).catch((function(e){console.error(e)}))}var CSS_VARIABLE_REGEXP=/[\s;{]--[-a-zA-Z0-9]+\s*:/m;function hasCssVariables(e){return e.indexOf("var(")>-1||CSS_VARIABLE_REGEXP.test(e)}var CSS_URL_REGEXP=/url[\s]*\([\s]*['"]?(?!(?:https?|data)\:|\/)([^\'\"\)]*)[\s]*['"]?\)[\s]*/gim;function hasRelativeUrls(e){return CSS_URL_REGEXP.lastIndex=0,CSS_URL_REGEXP.test(e)}function fixRelativeUrls(e,t){var r=t.replace(/[^/]*$/,"");return e.replace(CSS_URL_REGEXP,(function(e,t){var n=r+t;return e.replace(t,n)}))}var CustomStyle=function(){function e(e,t){this.win=e,this.doc=t,this.count=0,this.hostStyleMap=new WeakMap,this.hostScopeMap=new WeakMap,this.globalScopes=[],this.scopesMap=new Map,this.didInit=!1}return e.prototype.i=function(){var e=this;return this.didInit||!this.win.requestAnimationFrame?Promise.resolve():(this.didInit=!0,new Promise((function(t){e.win.requestAnimationFrame((function(){startWatcher(e.doc,e.globalScopes),loadDocument(e.doc,e.globalScopes).then((function(){return t()}))}))})))},e.prototype.addLink=function(e){var t=this;return addGlobalLink(this.doc,this.globalScopes,e).then((function(){t.updateGlobal()}))},e.prototype.addGlobalStyle=function(e){addGlobalStyle(this.globalScopes,e)&&this.updateGlobal()},e.prototype.createHostStyle=function(e,t,r,n){if(this.hostScopeMap.has(e))throw new Error("host style already created");var s=this.registerHostTemplate(r,t,n),o=this.doc.createElement("style");return o.setAttribute("data-no-shim",""),s.usesCssVars?n?(o["s-sc"]=t="".concat(s.scopeId,"-").concat(this.count),o.textContent="/*needs update*/",this.hostStyleMap.set(e,o),this.hostScopeMap.set(e,reScope(s,t)),this.count++):(s.styleEl=o,s.usesCssVars||(o.textContent=executeTemplate(s.template,{})),this.globalScopes.push(s),this.updateGlobal(),this.hostScopeMap.set(e,s)):o.textContent=r,o},e.prototype.removeHost=function(e){var t=this.hostStyleMap.get(e);t&&t.remove(),this.hostStyleMap.delete(e),this.hostScopeMap.delete(e)},e.prototype.updateHost=function(e){var t=this.hostScopeMap.get(e);if(t&&t.usesCssVars&&t.isScoped){var r=this.hostStyleMap.get(e);if(r){var n=resolveValues(getActiveSelectors(e,this.hostScopeMap,this.globalScopes));r.textContent=executeTemplate(t.template,n)}}},e.prototype.updateGlobal=function(){updateGlobalScopes(this.globalScopes)},e.prototype.registerHostTemplate=function(e,t,r){var n=this.scopesMap.get(t);return n||((n=parseCSS(e)).scopeId=t,n.isScoped=r,this.scopesMap.set(t,n)),n},e}();!function(e){!e||e.__cssshim||e.CSS&&e.CSS.supports&&e.CSS.supports("color","var(--c)")||(e.__cssshim=new CustomStyle(e,e.document))}("undefined"!=typeof window&&window);
@@ -1 +1 @@
1
- import{p as promiseResolve,b as bootstrapLazy}from"./index-265d8cca.js";import{g as globalScripts}from"./app-globals-28960cbc.js";var patchBrowser=function(){var e=import.meta.url;var i={};if(e!==""){i.resourcesUrl=new URL(".",e).href}return promiseResolve(i)};patchBrowser().then((function(e){globalScripts();return bootstrapLazy([["ezp-auth_14",[[1,"ezp-printing",{clientid:[1],redirecturi:[1],filename:[1025],fileurl:[1],filetype:[1],custom:[4],hidelogin:[4],hidemenu:[4],authapihosturl:[1],printapihosturl:[1],theme:[1],fileid:[1],appearance:[1],trigger:[1],printOpen:[32],authOpen:[32],noDocumentOpen:[32],systemAppearance:[32],open:[64]},[[0,"printCancel","listenPrintCancel"],[0,"printSubmit","listenPrintSubmit"],[0,"authCancel","listenAuthCancel"],[0,"authSuccess","listenAuthSuccess"],[0,"uploadFile","listenUploadFile"],[0,"dialogClose","listenDialogClose"],[0,"dialogAction","listenDialogAction"]]],[1,"ezp-printer-selection",{clientID:[1,"client-i-d"],redirectURI:[1,"redirect-u-r-i"],filename:[1025],fileurl:[1],filetype:[1025],fileid:[1025],file:[16],hidemenu:[4],loading:[32],options:[32],printProcessing:[32],uploading:[32],preparingUpload:[32],printSuccess:[32],printFailed:[32],notSupported:[32],noPrinters:[32],userMenuOpen:[32],printStopped:[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"],[0,"statusCancel","listenStatusCancel"],[0,"statusClose","listenStatusClose"],[0,"statusRetry","listenStatusRetry"]]],[1,"ezp-auth",{clientID:[1025,"client-i-d"],redirectURI:[1025,"redirect-u-r-i"],hidelogin:[4],auth:[32],authURI:[32],accessToken:[32]},[[0,"dialogAction","listenDialogAction"],[0,"dialogClose","listenDialogClose"]]],[1,"ezp-upload",{dragging:[32]},[[1,"dragenter","handleDragEnter"],[0,"dragover","handleDragOver"],[1,"dragleave","handleDragLeave"],[0,"drop","handleDrop"]]],[1,"ezp-dialog",{heading:[1],description:[1],action:[1],iconName:[1,"icon-name"],iconSize:[1,"icon-size"],iconFramed:[4,"icon-framed"],instance:[1]}],[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"],disabled:[4],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-status",{description:[1],processing:[4],instance:[1],icon:[1],cancel:[8],close:[8],retry:[8]}],[1,"ezp-backdrop",{visible:[1028]},[[0,"animationend","listenAnimationEnd"]]],[1,"ezp-icon-button",{blank:[4],disabled:[4],href:[1],icon:[1],level:[1],type:[1]}],[1,"ezp-text-button",{blank:[4],disabled:[4],href:[1],level:[1],label:[1],type:[1],small:[4]}],[1,"ezp-icon",{name:[1],size:[1],framed:[4]}],[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-485041ac.js";import{g as globalScripts}from"./app-globals-28960cbc.js";var patchBrowser=function(){var e=import.meta.url;var i={};if(e!==""){i.resourcesUrl=new URL(".",e).href}return promiseResolve(i)};patchBrowser().then((function(e){globalScripts();return bootstrapLazy([["ezp-auth_14",[[1,"ezp-printing",{clientid:[1],redirecturi:[1],filename:[1025],fileurl:[1],filetype:[1],custom:[4],hidelogin:[4],hidemenu:[4],authapihosturl:[1],printapihosturl:[1],theme:[1],fileid:[1],appearance:[1],trigger:[1],language:[1],printOpen:[32],authOpen:[32],noDocumentOpen:[32],systemAppearance:[32],open:[64]},[[0,"printCancel","listenPrintCancel"],[0,"printSubmit","listenPrintSubmit"],[0,"authCancel","listenAuthCancel"],[0,"authSuccess","listenAuthSuccess"],[0,"uploadFile","listenUploadFile"],[0,"dialogClose","listenDialogClose"],[0,"dialogAction","listenDialogAction"]]],[1,"ezp-printer-selection",{clientID:[1,"client-i-d"],redirectURI:[1,"redirect-u-r-i"],filename:[1025],fileurl:[1],filetype:[1025],fileid:[1025],file:[16],hidemenu:[4],loading:[32],options:[32],printProcessing:[32],uploading:[32],preparingUpload:[32],printSuccess:[32],printFailed:[32],notSupported:[32],noPrinters:[32],userMenuOpen:[32],printStopped:[32],userName:[32],printers:[32],selectedPrinter:[32],printerConfig:[32],selectedPrinterConfig:[32],selectedProperties:[32]},[[0,"selectSelection","listenSelectSelection"],[0,"stepperChanged","listenStepperChanged"],[0,"userMenuClosure","listenUserMenuClosure"],[0,"logoutEmitter","listenLogout"],[0,"statusCancel","listenStatusCancel"],[0,"statusClose","listenStatusClose"],[0,"statusRetry","listenStatusRetry"]]],[1,"ezp-auth",{clientID:[1025,"client-i-d"],redirectURI:[1025,"redirect-u-r-i"],hidelogin:[4],auth:[32],authURI:[32],accessToken:[32]},[[0,"dialogAction","listenDialogAction"],[0,"dialogClose","listenDialogClose"]]],[1,"ezp-upload",{dragging:[32]},[[1,"dragenter","handleDragEnter"],[0,"dragover","handleDragOver"],[1,"dragleave","handleDragLeave"],[0,"drop","handleDrop"]]],[1,"ezp-dialog",{heading:[1],description:[1],action:[1],iconName:[1,"icon-name"],iconSize:[1,"icon-size"],iconFramed:[4,"icon-framed"],instance:[1]}],[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"],disabled:[4],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-status",{description:[1],processing:[4],instance:[1],icon:[1],cancel:[8],close:[8],retry:[8]}],[1,"ezp-backdrop",{visible:[1028]},[[0,"animationend","listenAnimationEnd"]]],[1,"ezp-icon-button",{blank:[4],disabled:[4],href:[1],icon:[1],level:[1],type:[1]}],[1,"ezp-text-button",{blank:[4],disabled:[4],href:[1],level:[1],label:[1],type:[1],small:[4]}],[1,"ezp-icon",{name:[1],size:[1],framed:[4]}],[1,"ezp-label",{ellipsis:[4],level:[1],noWrap:[4,"no-wrap"],text:[1],weight:[1]}]]]],e)}));