UNPKG

1.82 kBJavaScriptView Raw
1"use strict";
2var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
3 var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4 if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
5 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;
6 return c > 3 && r && Object.defineProperty(target, key, r), r;
7};
8var plugin_1 = require('./plugin');
9/**
10 * @name Photo Viewer
11 * @description This plugin can display your image in full screen with the ability to pan, zoom, and share the image.
12 * @usage
13 * ```typescript
14 * import { PhotoViewer } from 'ionic-native';
15 *
16 * PhotoViewer.show('https://mysite.com/path/to/image.jpg');
17 *
18 * PhotoViewer.show('https://mysite.com/path/to/image.jpg', 'My image title', {share: false});
19 * ```
20 */
21var PhotoViewer = (function () {
22 function PhotoViewer() {
23 }
24 /**
25 * Shows an image in full screen
26 * @param url {string} URL or path to image
27 * @param title {string}
28 * @param options {any}
29 */
30 PhotoViewer.show = function (url, title, options) { };
31 __decorate([
32 plugin_1.Cordova({ sync: true })
33 ], PhotoViewer, "show", null);
34 PhotoViewer = __decorate([
35 plugin_1.Plugin({
36 pluginName: 'PhotoViewer',
37 plugin: 'com-sarriaroman-photoviewer',
38 pluginRef: 'PhotoViewer',
39 repo: 'https://github.com/sarriaroman/photoviewer'
40 })
41 ], PhotoViewer);
42 return PhotoViewer;
43}());
44exports.PhotoViewer = PhotoViewer;
45//# sourceMappingURL=photo-viewer.js.map
\No newline at end of file