@fto-consult/expo-ui 7.4.35 → 7.4.36

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fto-consult/expo-ui",
3
- "version": "7.4.35",
3
+ "version": "7.4.36",
4
4
  "description": "Bibliothèque de composants UI Expo,react-native",
5
5
  "scripts": {
6
6
  "clear-npx-cache": "npx clear-npx-cache",
package/src/pdf/index.js CHANGED
@@ -13,7 +13,7 @@ pdfMake.createPdf = (docDefinition,...rest)=>{
13
13
  try {
14
14
  //@see : https://pdfmake.github.io/docs/0.1/getting-started/client-side/methods/
15
15
  const pdf = createPdf(docDefinition,...rest);
16
- printPdfMake(pdf);
16
+ printPdfMake(pdf,{...Object.assign({},docDefinition),...Object.assign({},rest[0])});
17
17
  return pdf;
18
18
  } catch(e){
19
19
  console.log(e," generating pdf make create eerrror");
package/src/pdf/print.js CHANGED
@@ -1,3 +1,7 @@
1
- export default function print(pdfMakeInstance,...rest){
2
- return pdfMakeInstance.print(...rest);
1
+ import {isElectron} from "$cplatform";
2
+ export default function print(pdfMakeInstance,options,...rest){
3
+ if(isElectron() && ELECTRON.printPDF){
4
+ return ELECTRON.printPDF(options);
5
+ }
6
+ return pdfMakeInstance.print(options,...rest);
3
7
  }