@ionic-native/base64-to-gallery
Advanced tools
Comparing version 4.4.2 to 5.0.0-alpha.3
@@ -21,3 +21,3 @@ import { IonicNativePlugin } from '@ionic-native/core'; | ||
*/ | ||
export declare class Base64ToGallery extends IonicNativePlugin { | ||
export declare class Base64ToGalleryOriginal extends IonicNativePlugin { | ||
/** | ||
@@ -34,1 +34,3 @@ * Converts a base64 string to an image file in the device gallery | ||
} | ||
export declare const Base64ToGallery: Base64ToGalleryOriginal; |
78
index.js
@@ -11,72 +11,18 @@ var __extends = (this && this.__extends) || (function () { | ||
})(); | ||
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) { | ||
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d; | ||
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc); | ||
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r; | ||
return c > 3 && r && Object.defineProperty(target, key, r), r; | ||
}; | ||
var __metadata = (this && this.__metadata) || function (k, v) { | ||
if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v); | ||
}; | ||
import { Injectable } from '@angular/core'; | ||
import { Cordova, Plugin, IonicNativePlugin } from '@ionic-native/core'; | ||
/** | ||
* @name Base64 To Gallery | ||
* @description This plugin allows you to save base64 data as a png image into the device | ||
* @usage | ||
* ```typescript | ||
* import { Base64ToGallery } from '@ionic-native/base64-to-gallery'; | ||
* | ||
* constructor(private base64ToGallery: Base64ToGallery) { } | ||
* | ||
* | ||
* ... | ||
* | ||
* | ||
* this.base64ToGallery.base64ToGallery(base64Data, { prefix: '_img' }).then( | ||
* res => console.log('Saved image to gallery ', res), | ||
* err => console.log('Error saving image to gallery ', err) | ||
* ); | ||
* ``` | ||
*/ | ||
var Base64ToGallery = (function (_super) { | ||
import { IonicNativePlugin, cordova, injectable } from '@ionic-native/core'; | ||
var Base64ToGalleryOriginal = /** @class */ (function (_super) { | ||
__extends(Base64ToGallery, _super); | ||
function Base64ToGallery() { | ||
function Base64ToGalleryOriginal() { | ||
return _super !== null && _super.apply(this, arguments) || this; | ||
} | ||
/** | ||
* Converts a base64 string to an image file in the device gallery | ||
* @param {string} data The actual base64 string that you want to save | ||
* @param {any} [options] An object with properties: prefix: string, mediaScanner: boolean. Prefix will be prepended to the filename. If true, mediaScanner runs Media Scanner on Android and saves to Camera Roll on iOS; if false, saves to Library folder on iOS. | ||
* @returns {Promise<any>} returns a promise that resolves when the image is saved. | ||
*/ | ||
Base64ToGallery.prototype.base64ToGallery = function (data, options) { | ||
return; | ||
}; | ||
Base64ToGallery.decorators = [ | ||
{ type: Injectable }, | ||
]; | ||
/** @nocollapse */ | ||
Base64ToGallery.ctorParameters = function () { return []; }; | ||
__decorate([ | ||
Cordova({ | ||
successIndex: 2, | ||
errorIndex: 3 | ||
}), | ||
__metadata("design:type", Function), | ||
__metadata("design:paramtypes", [String, Object]), | ||
__metadata("design:returntype", Promise) | ||
], Base64ToGallery.prototype, "base64ToGallery", null); | ||
Base64ToGallery = __decorate([ | ||
Plugin({ | ||
pluginName: 'Base64ToGallery', | ||
plugin: 'cordova-base64-to-gallery', | ||
pluginRef: 'cordova', | ||
repo: 'https://github.com/Nexxa/cordova-base64-to-gallery', | ||
platforms: ['Android', 'iOS', 'Windows Phone 8'] | ||
}) | ||
], Base64ToGallery); | ||
return Base64ToGallery; | ||
Base64ToGalleryOriginal.prototype.base64ToGallery = function (data, options) { return cordova(this, "base64ToGallery", { "successIndex": 2, "errorIndex": 3 }, arguments); }; | ||
Base64ToGalleryOriginal.pluginName = "Base64ToGallery"; | ||
Base64ToGalleryOriginal.plugin = "cordova-base64-to-gallery"; | ||
Base64ToGalleryOriginal.pluginRef = "cordova"; | ||
Base64ToGalleryOriginal.repo = "https://github.com/Nexxa/cordova-base64-to-gallery"; | ||
Base64ToGalleryOriginal.platforms = ["Android", "iOS", "Windows Phone 8"]; | ||
return Base64ToGalleryOriginal; | ||
}(IonicNativePlugin)); | ||
var Base64ToGallery = new Base64ToGalleryOriginal(); | ||
export { Base64ToGallery }; | ||
//# sourceMappingURL=index.js.map | ||
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiaW5kZXguanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi9zcmMvcGx1Z2lucy9iYXNlNjQtdG8tZ2FsbGVyeS9pbmRleC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiOzs7Ozs7Ozs7O0FBQ0EsT0FBTywwQ0FBc0MsTUFBTSxvQkFBb0IsQ0FBQzs7SUE2Qm5DLG1DQUFpQjs7OztJQVlwRCx5Q0FBZSxhQUFDLElBQVksRUFBRSxPQUFxRDs7Ozs7OzBCQTFDckY7RUE4QnFDLGlCQUFpQjtTQUF6QyxlQUFlIiwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHsgSW5qZWN0YWJsZSB9IGZyb20gJ0Bhbmd1bGFyL2NvcmUnO1xuaW1wb3J0IHsgQ29yZG92YSwgUGx1Z2luLCBJb25pY05hdGl2ZVBsdWdpbiB9IGZyb20gJ0Bpb25pYy1uYXRpdmUvY29yZSc7XG5cbi8qKlxuICogQG5hbWUgQmFzZTY0IFRvIEdhbGxlcnlcbiAqIEBkZXNjcmlwdGlvbiBUaGlzIHBsdWdpbiBhbGxvd3MgeW91IHRvIHNhdmUgYmFzZTY0IGRhdGEgYXMgYSBwbmcgaW1hZ2UgaW50byB0aGUgZGV2aWNlXG4gKiBAdXNhZ2VcbiAqIGBgYHR5cGVzY3JpcHRcbiAqIGltcG9ydCB7IEJhc2U2NFRvR2FsbGVyeSB9IGZyb20gJ0Bpb25pYy1uYXRpdmUvYmFzZTY0LXRvLWdhbGxlcnknO1xuICpcbiAqIGNvbnN0cnVjdG9yKHByaXZhdGUgYmFzZTY0VG9HYWxsZXJ5OiBCYXNlN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iBib29sZWFuLiBQcmVmaXggd2lsbCBiZSBwcmVwZW5kZWQgdG8gdGhlIGZpbGVuYW1lLiBJZiB0cnVlLCBtZWRpYVNjYW5uZXIgcnVucyBNZWRpYSBTY2FubmVyIG9uIEFuZHJvaWQgYW5kIHNhdmVzIHRvIENhbWVyYSBSb2xsIG9uIGlPUzsgaWYgZmFsc2UsIHNhdmVzIHRvIExpYnJhcnkgZm9sZGVyIG9uIGlPUy5cbiAgICogQHJldHVybnMge1Byb21pc2U8YW55Pn0gcmV0dXJucyBhIHByb21pc2UgdGhhdCByZXNvbHZlcyB3aGVuIHRoZSBpbWFnZSBpcyBzYXZlZC5cbiAgICovXG4gIEBDb3Jkb3ZhKHtcbiAgICBzdWNjZXNzSW5kZXg6IDIsXG4gICAgZXJyb3JJbmRleDogM1xuICB9KVxuICBiYXNlNjRUb0dhbGxlcnkoZGF0YTogc3RyaW5nLCBvcHRpb25zPzogeyBwcmVmaXg/OiBzdHJpbmc7IG1lZGlhU2Nhbm5lcj86IGJvb2xlYW4gfSk6IFByb21pc2U8YW55PiB7XG4gICAgcmV0dXJuO1xuICB9XG5cbn1cbiJdfQ== |
@@ -1,18 +0,1 @@ | ||
{ | ||
"name": "@ionic-native/base64-to-gallery", | ||
"version": "4.4.2", | ||
"description": "Ionic Native - Native plugins for ionic apps", | ||
"module": "index.js", | ||
"typings": "index.d.ts", | ||
"author": "ionic", | ||
"license": "MIT", | ||
"peerDependencies": { | ||
"@ionic-native/core": "^4.2.0", | ||
"@angular/core": "*", | ||
"rxjs": "^5.0.1" | ||
}, | ||
"repository": { | ||
"type": "git", | ||
"url": "https://github.com/ionic-team/ionic-native.git" | ||
} | ||
} | ||
{"description":"Ionic Native - Native plugins for ionic apps","module":"index.js","typings":"index.d.ts","author":"ionic","license":"MIT","repository":{"type":"git","url":"https://github.com/ionic-team/ionic-native.git"},"name":"@ionic-native/base64-to-gallery","peerDependencies":{"rxjs":"^5.0.1","@ionic-native/core":"5.0.0-alpha.3"},"version":"5.0.0-alpha.3"} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No README
QualityPackage does not have a README. This may indicate a failed publish or a low quality package.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
11026
2
5
95
2
2
0