@capacitor/core
Advanced tools
Comparing version 0.0.3 to 0.0.7
@@ -44,5 +44,3 @@ import { Plugin, PluginListenerHandle } from './definitions'; | ||
*/ | ||
speak(options: { | ||
value: string; | ||
}): Promise<void>; | ||
speak(options: AccessibilitySpeakOptions): Promise<void>; | ||
/** | ||
@@ -53,2 +51,13 @@ * Listen for screen reader state change (on/off) | ||
} | ||
export interface AccessibilitySpeakOptions { | ||
/** | ||
* The string to speak | ||
*/ | ||
value: string; | ||
/** | ||
* The language to speak the string in, as its [ISO 639-1 Code](https://www.loc.gov/standards/iso639-2/php/code_list.php) (ex: "en"). | ||
* Currently only supported on Android. | ||
*/ | ||
language?: string; | ||
} | ||
export interface ScreenReaderEnabledResult { | ||
@@ -59,2 +68,5 @@ value: boolean; | ||
export interface AppPlugin extends Plugin { | ||
/** | ||
* Check if an app can be opened with the given URL | ||
*/ | ||
canOpenUrl(options: { | ||
@@ -65,2 +77,5 @@ url: string; | ||
}>; | ||
/** | ||
* Open an app with the given URL | ||
*/ | ||
openUrl(options: { | ||
@@ -71,10 +86,6 @@ url: string; | ||
}>; | ||
getLaunchUrl(): Promise<{ | ||
url: string; | ||
}>; | ||
/** | ||
* Listen for internal plugin errors if you'd like to have more diagnostics on | ||
* serious plugin runtime errors. | ||
* Get the URL the app was launched with, if any | ||
*/ | ||
addListener(eventName: 'pluginError', listenerFunc: (err: any, info: any) => void): PluginListenerHandle; | ||
getLaunchUrl(): Promise<AppLaunchUrl>; | ||
/** | ||
@@ -95,5 +106,8 @@ * Listen for changes in the App's active state (whether the app is in the foreground or background) | ||
url: string; | ||
annotation: any; | ||
openInPlace: boolean; | ||
iosSourceApplication?: any; | ||
iosOpenInPlace?: boolean; | ||
} | ||
export interface AppLaunchUrl { | ||
url: string; | ||
} | ||
export interface BrowserPlugin extends Plugin { | ||
@@ -112,3 +126,3 @@ /** | ||
/** | ||
* Close an open browser | ||
* Close an open browser. Only works on iOS, otherwise is a no-op | ||
*/ | ||
@@ -190,12 +204,62 @@ close(): Promise<void>; | ||
export interface DeviceInfo { | ||
/** | ||
* The device model. For example, "iPhone" | ||
*/ | ||
model: string; | ||
/** | ||
* The device platform (lowercase). For example, "ios", "android", or "web" | ||
*/ | ||
platform: string; | ||
/** | ||
* The UUID of the device as available to the app. This identifier may change | ||
* on modern mobile platforms that only allow per-app install UUIDs. | ||
*/ | ||
uuid: string; | ||
version: string; | ||
/** | ||
* The current bundle verison of the app | ||
*/ | ||
appVersion: string; | ||
/** | ||
* The version of the device OS | ||
*/ | ||
osVersion: string; | ||
/** | ||
* The manufacturer of the device | ||
*/ | ||
manufacturer: string; | ||
/** | ||
* Whether the app is running in a simulator/emulator | ||
*/ | ||
isVirtual: boolean; | ||
serial: string; | ||
/** | ||
* Approximate memory used by the current app, in bytes. Divide by | ||
* 1048576 to get the number of MBs used. | ||
*/ | ||
memUsed: number; | ||
/** | ||
* How much free disk space is available on the the normal data storage | ||
* path for the os, in bytes | ||
*/ | ||
diskFree: number; | ||
/** | ||
* The total size of the normal data storage path for the OS, in bytes | ||
*/ | ||
diskTotal: number; | ||
/** | ||
* A percentage (0 to 1) indicating how much the battery is charged | ||
*/ | ||
batteryLevel: number; | ||
/** | ||
* Whether the device is charging | ||
*/ | ||
isCharging: boolean; | ||
} | ||
export interface FilesystemPlugin extends Plugin { | ||
/** | ||
* Read a file from disk | ||
* @param options options for the file read | ||
* @return a promise that resolves with the read file data result | ||
*/ | ||
readFile(options: FileReadOptions): Promise<FileReadResult>; | ||
/** | ||
* Write a file to disk in the specified location on device | ||
@@ -213,8 +277,2 @@ * @param options options for the file write | ||
/** | ||
* Read a file from disk | ||
* @param options options for the file read | ||
* @return a promise that resolves with the read file data result | ||
*/ | ||
readFile(options: FileReadOptions): Promise<FileReadResult>; | ||
/** | ||
* Delete a file from disk | ||
@@ -221,0 +279,0 @@ * @param options options for the file delete |
{ | ||
"name": "@capacitor/core", | ||
"version": "0.0.3", | ||
"version": "0.0.7", | ||
"description": "Cordova: cross-platform mobile apps with the web", | ||
@@ -5,0 +5,0 @@ "homepage": "http://getcapacitor.com/", |
Sorry, the diff of this file is not supported yet
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
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
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
67593
1409
1