@pedidopago/ui 1.13.21 → 1.13.22

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.
@@ -1,7 +1,7 @@
1
1
  import { HTMLAttributes } from 'react';
2
2
  import { DropzoneOptions, FileRejection } from 'react-dropzone';
3
3
  import { DropzoneFileParams } from '../types';
4
- export type AcceptImageTypes = 'jpeg' | 'png' | 'webp' | 'gif';
4
+ export type AcceptImageTypes = 'jpeg' | 'png' | 'webp' | 'gif' | 'svg+xml';
5
5
  export type AcceptVideoTypes = 'mp4' | '3gp';
6
6
  export type AcceptTextTypes = 'csv' | 'txt';
7
7
  export type AcceptDocumentTypes = 'pdf' | 'msword' | 'docx' | 'xlsx';
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/components/NewDropzone/DropzoneButton/types.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,cAAc,EAAE,MAAM,OAAO,CAAC;AACvC,OAAO,EAAE,eAAe,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAC;AAGhE,OAAO,EAAE,kBAAkB,EAAE,MAAM,UAAU,CAAC;AAE9C,MAAM,MAAM,gBAAgB,GAAG,MAAM,GAAG,KAAK,GAAG,MAAM,GAAG,KAAK,CAAC;AAC/D,MAAM,MAAM,gBAAgB,GAAG,KAAK,GAAG,KAAK,CAAC;AAC7C,MAAM,MAAM,eAAe,GAAG,KAAK,GAAG,KAAK,CAAC;AAC5C,MAAM,MAAM,mBAAmB,GAAG,KAAK,GAAG,QAAQ,GAAG,MAAM,GAAG,MAAM,CAAC;AAErE,MAAM,MAAM,WAAW,GAAG;IACxB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,KAAK,CAAC,EAAE,gBAAgB,EAAE,CAAC;IAC3B,IAA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,EAAE,OAAO,CAAC;IAClB,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,KAAK,CAAC,EAAE,gBAAgB,EAAE,CAAC;IAC3B,IAAI,CAAC,EAAE,eAAe,EAAE,CAAC;IACzB,QAAQ,CAAC,EAAE,mBAAmB,EAAE,CAAC;IACjC,KAAK,CAAC,EAAE,gBAAgB,EAAE,CAAC;CAC5B,CAAC;AAEF,MAAM,MAAM,mBAAmB,GAAG;IAChC,eAAe,CAAC,EAAE,IAAI,CAAC,eAAe,EAAE,QAAQ,CAAC,CAAC;IAClD,WAAW,CAAC,EAAE,cAAc,CAAC,iBAAiB,CAAC,CAAC;IAChD,cAAc,EAAE,CAAC,IAAI,EAAE,kBAAkB,EAAE,KAAK,IAAI,CAAC;IACrD,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC3B,MAAM,CAAC,EAAE,WAAW,CAAC;IACrB,cAAc,CAAC,EAAE,CAAC,aAAa,EAAE,aAAa,EAAE,KAAK,IAAI,CAAC;CAC3D,CAAC"}
@@ -1,6 +1,6 @@
1
1
  import { DropzoneFileParams } from '../../types';
2
2
  export declare function convertDropzoneFile(file: File): Promise<DropzoneFileParams>;
3
- export declare const ACCEPTED_IMAGE_TYPES = "image/jpeg,image/png,image/webp,image/gif";
3
+ export declare const ACCEPTED_IMAGE_TYPES = "image/jpeg,image/png,image/webp,image/gif,image/svg+xml";
4
4
  export declare const ACCEPTED_VIDEO_TYPES = "video/mp4";
5
5
  export declare const ACCEPTED_PDF_TYPES = "application/pdf";
6
6
  export declare const ACCEPTED_OTHER_TYPES = "text/plain,application/vnd.ms-powerpoint,application/msword,application/vnd.ms-excel,application/vnd.openxmlformats-officedocument.wordprocessingml.document,application/vnd.openxmlformats-officedocument.presentationml.presentation,application/vnd.openxmlformats-officedocument.spreadsheetml.sheet,text/csv";
@@ -1 +1 @@
1
- {"version":3,"file":"convertFile.d.ts","sourceRoot":"","sources":["../../../../../src/components/NewDropzone/DropzoneButton/utils/convertFile.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,kBAAkB,EAAE,MAAM,aAAa,CAAC;AAEjD,wBAAgB,mBAAmB,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAAC,kBAAkB,CAAC,CAkB3E;AAED,eAAO,MAAM,oBAAoB,8CAA8C,CAAC;AAChF,eAAO,MAAM,oBAAoB,cAAc,CAAC;AAChD,eAAO,MAAM,kBAAkB,oBAAoB,CAAC;AACpD,eAAO,MAAM,oBAAoB,sTACoR,CAAC;AAEtT,eAAO,MAAM,iBAAiB,QAKnB,CAAC"}
1
+ {"version":3,"file":"convertFile.d.ts","sourceRoot":"","sources":["../../../../../src/components/NewDropzone/DropzoneButton/utils/convertFile.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,kBAAkB,EAAE,MAAM,aAAa,CAAC;AAEjD,wBAAgB,mBAAmB,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAAC,kBAAkB,CAAC,CAkB3E;AAED,eAAO,MAAM,oBAAoB,4DAA4D,CAAC;AAC9F,eAAO,MAAM,oBAAoB,cAAc,CAAC;AAChD,eAAO,MAAM,kBAAkB,oBAAoB,CAAC;AACpD,eAAO,MAAM,oBAAoB,sTACoR,CAAC;AAEtT,eAAO,MAAM,iBAAiB,QAKnB,CAAC"}
@@ -1,3 +1,3 @@
1
1
  "use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.ACCEPT_FILE_TYPES=exports.ACCEPTED_VIDEO_TYPES=exports.ACCEPTED_PDF_TYPES=exports.ACCEPTED_OTHER_TYPES=exports.ACCEPTED_IMAGE_TYPES=void 0,exports.convertDropzoneFile=convertDropzoneFile;var _generateUUID=require("../../../../utils/generateUUID"),_Toast=require("../../../Toast");function _toConsumableArray(arr){return _arrayWithoutHoles(arr)||_iterableToArray(arr)||_unsupportedIterableToArray(arr)||_nonIterableSpread()}function _nonIterableSpread(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function _unsupportedIterableToArray(o,minLen){if(o){if("string"==typeof o)return _arrayLikeToArray(o,minLen);var n=Object.prototype.toString.call(o).slice(8,-1);return"Object"===n&&o.constructor&&(n=o.constructor.name),"Map"===n||"Set"===n?Array.from(o):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?_arrayLikeToArray(o,minLen):void 0}}function _iterableToArray(iter){if("undefined"!=typeof Symbol&&null!=iter[Symbol.iterator]||null!=iter["@@iterator"])return Array.from(iter)}function _arrayWithoutHoles(arr){if(Array.isArray(arr))return _arrayLikeToArray(arr)}function _arrayLikeToArray(arr,len){(null==len||len>arr.length)&&(len=arr.length);for(var i=0,arr2=Array(len);i<len;i++)arr2[i]=arr[i];return arr2}// Utils
2
2
  // Types
3
- function convertDropzoneFile(file){return new Promise(function(resolve,reject){if(ACCEPT_FILE_TYPES.length&&!ACCEPT_FILE_TYPES.includes(file.type))return void reject(_Toast.toast.error("Tipo de arquivo n\xE3o suportado"));var reader=new FileReader;reader.readAsDataURL(file),reader.onload=function(){resolve({url:reader.result+"",fileName:file.name,target:file,id:(0,_generateUUID.generateUUID)()})}})}var ACCEPTED_IMAGE_TYPES="image/jpeg,image/png,image/webp,image/gif";exports.ACCEPTED_IMAGE_TYPES=ACCEPTED_IMAGE_TYPES;var ACCEPTED_VIDEO_TYPES="video/mp4";exports.ACCEPTED_VIDEO_TYPES=ACCEPTED_VIDEO_TYPES;var ACCEPTED_PDF_TYPES="application/pdf";exports.ACCEPTED_PDF_TYPES=ACCEPTED_PDF_TYPES;var ACCEPTED_OTHER_TYPES="text/plain,application/vnd.ms-powerpoint,application/msword,application/vnd.ms-excel,application/vnd.openxmlformats-officedocument.wordprocessingml.document,application/vnd.openxmlformats-officedocument.presentationml.presentation,application/vnd.openxmlformats-officedocument.spreadsheetml.sheet,text/csv";exports.ACCEPTED_OTHER_TYPES=ACCEPTED_OTHER_TYPES;var ACCEPT_FILE_TYPES=[].concat(_toConsumableArray(ACCEPTED_IMAGE_TYPES.split(",")),_toConsumableArray(ACCEPTED_VIDEO_TYPES.split(",")),_toConsumableArray(ACCEPTED_PDF_TYPES.split(",")),_toConsumableArray(ACCEPTED_OTHER_TYPES.split(","))).join(",");exports.ACCEPT_FILE_TYPES=ACCEPT_FILE_TYPES;
3
+ function convertDropzoneFile(file){return new Promise(function(resolve,reject){if(ACCEPT_FILE_TYPES.length&&!ACCEPT_FILE_TYPES.includes(file.type))return void reject(_Toast.toast.error("Tipo de arquivo n\xE3o suportado"));var reader=new FileReader;reader.readAsDataURL(file),reader.onload=function(){resolve({url:reader.result+"",fileName:file.name,target:file,id:(0,_generateUUID.generateUUID)()})}})}var ACCEPTED_IMAGE_TYPES="image/jpeg,image/png,image/webp,image/gif,image/svg+xml";exports.ACCEPTED_IMAGE_TYPES=ACCEPTED_IMAGE_TYPES;var ACCEPTED_VIDEO_TYPES="video/mp4";exports.ACCEPTED_VIDEO_TYPES=ACCEPTED_VIDEO_TYPES;var ACCEPTED_PDF_TYPES="application/pdf";exports.ACCEPTED_PDF_TYPES=ACCEPTED_PDF_TYPES;var ACCEPTED_OTHER_TYPES="text/plain,application/vnd.ms-powerpoint,application/msword,application/vnd.ms-excel,application/vnd.openxmlformats-officedocument.wordprocessingml.document,application/vnd.openxmlformats-officedocument.presentationml.presentation,application/vnd.openxmlformats-officedocument.spreadsheetml.sheet,text/csv";exports.ACCEPTED_OTHER_TYPES=ACCEPTED_OTHER_TYPES;var ACCEPT_FILE_TYPES=[].concat(_toConsumableArray(ACCEPTED_IMAGE_TYPES.split(",")),_toConsumableArray(ACCEPTED_VIDEO_TYPES.split(",")),_toConsumableArray(ACCEPTED_PDF_TYPES.split(",")),_toConsumableArray(ACCEPTED_OTHER_TYPES.split(","))).join(",");exports.ACCEPT_FILE_TYPES=ACCEPT_FILE_TYPES;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pedidopago/ui",
3
- "version": "1.13.21",
3
+ "version": "1.13.22",
4
4
  "description": "Quick build beatiful Pedido Pago apps",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",