Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@types/plupload

Package Overview
Dependencies
Maintainers
1
Versions
14
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@types/plupload - npm Package Compare versions

Comparing version 2.0.5 to 2.0.6

301

plupload/index.d.ts

@@ -146,24 +146,168 @@ // Type definitions for Plupload 2.0

/** Properties */
/**
* Unique id for the Uploader instance.
*
* @property id
* @type String
*/
id: string;
/**
* Current state of the total uploading progress. This one can either be plupload.STARTED or plupload.STOPPED.
* These states are controlled by the stop/start methods. The default value is STOPPED.
*
* @property state
* @type Number
*/
state: number;
features: string;
/**
* Map of features that are available for the uploader runtime. Features will be filled
* before the init event is called, these features can then be used to alter the UI for the end user.
* Some of the current features that might be in this map is: dragdrop, chunks, jpgresize, pngresize.
*
* @property features
* @type Object
*/
features: any;
/**
* Current runtime name.
*
* @property runtime
* @type String
*/
runtime: string;
files: any;
/**
* Current upload queue, an array of File instances.
*
* @property files
* @type Array
* @see plupload.File
*/
files: Array<any>;
/**
* Object with name/value settings.
*
* @property settings
* @type Object
*/
settings: any;
/**
* Total progess information. How many files has been uploaded, total percent etc.
*
* @property total
* @type plupload.QueueProgress
*/
total: plupload_queue_progress;
/** Methods */
init(): any;
setOption(option: string | any, value?: any): any;
/**
* Initializes the Uploader instance and adds internal event listeners.
*
* @method init
*/
init(): void;
/**
* Set the value for the specified option(s).
*
* @method setOption
* @since 2.1
* @param {String|Object} option Name of the option to change or the set of key/value pairs
* @param {Mixed} [value] Value for the option (is ignored, if first argument is object)
*/
setOption(option: string | any, value?: any): void;
/**
* Get the value for the specified option or the whole configuration, if not specified.
*
* @method getOption
* @since 2.1
* @param {String} [option] Name of the option to get
* @return {Mixed} Value for the option or the whole set
*/
getOption(option?: string): any;
refresh(): any;
start(): any;
stop(): any;
disableBrowse(disable: boolean): any;
/**
* Refreshes the upload instance by dispatching out a refresh event to all runtimes.
* This would for example reposition flash/silverlight shims on the page.
*
* @method refresh
*/
refresh(): void;
/**
* Starts uploading the queued files.
*
* @method start
*/
start(): void;
/**
* Stops the upload of the queued files.
*
* @method stop
*/
stop(): void;
/**
* Disables/enables browse button on request.
*
* @method disableBrowse
* @param {Boolean} disable Whether to disable or enable (default: true)
*/
disableBrowse(disable: boolean): void;
// TODO: Make plupload.File typing
/**
* Returns the specified file object by id.
*
* @method getFile
* @param {String} id File id to look for.
* @return {plupload.File} File object or undefined if it wasn't found;
*/
getFile(id: string): any;
addFile(file: any, fileName?: string): any;
/**
* Adds file to the queue programmatically. Can be native file, instance of Plupload.File,
* instance of mOxie.File, input[type="file"] element, or array of these. Fires FilesAdded,
* if any files were added to the queue. Otherwise nothing happens.
*
* @method addFile
* @since 2.0
* @param {plupload.File|mOxie.File|File|Node|Array} file File or files to add to the queue.
* @param {String} [fileName] If specified, will be used as a name for the file
*/
addFile(file: any, fileName?: string): void;
/**
* Removes a specific file.
*
* @method removeFile
* @param {plupload.File|String} file File to remove from queue.
*/
removeFile(file: any): any;
/**
* Removes part of the queue and returns the files removed. This will also trigger the
* FilesRemoved and QueueChanged events.
*
* @method splice
* @param {Number} [start=0] Start index to remove from.
* @param {Number} [length] Number of files to remove (defaults to number of files in the queue).
* @return {Array} Array of files that was removed.
*/
splice(start?: number, length?: number): any;
/**
* Dispatches the specified event name and its arguments to all listeners.
* @method trigger
* @param {String} name Event name to fire.
* @param {Object..} Multiple arguments to pass along to the listener functions.
*/
trigger(name: string, Multiple: any): any;
hasEventListener(name: string): any;

@@ -178,18 +322,153 @@ bind(name: string, func: any, scope?: any): any;

/**
* The state of the queue before it has started and after it has finished
*
* @property STOPPED
* @static
* @final
*/
export const STOPPED: number;
/**
* Upload process is running
*
* @property STARTED
* @static
* @final
*/
export const STARTED: number;
/**
* File is queued for upload
*
* @property QUEUED
* @static
* @final
*/
export const QUEUED: number;
/**
* File is being uploaded
*
* @property UPLOADING
* @static
* @final
*/
export const UPLOADING: number;
/**
* File has failed to be uploaded
*
* @property FAILED
* @static
* @final
*/
export const FAILED: number;
/**
* File has been uploaded successfully
*
* @property DONE
* @static
* @final
*/
export const DONE: number;
/**
* Generic error for example if an exception is thrown inside Silverlight.
*
* @property GENERIC_ERROR
* @static
* @final
*/
export const GENERIC_ERROR: number;
/**
* HTTP transport error. For example if the server produces a HTTP status other than 200.
*
* @property HTTP_ERROR
* @static
* @final
*/
export const HTTP_ERROR: number;
/**
* Generic I/O error. For example if it wasn't possible to open the file stream on local machine.
*
* @property IO_ERROR
* @static
* @final
*/
export const IO_ERROR: number;
/**
* @property SECURITY_ERROR
* @static
* @final
*/
export const SECURITY_ERROR: number;
/**
* Initialization error. Will be triggered if no runtime was initialized.
*
* @property INIT_ERROR
* @static
* @final
*/
export const INIT_ERROR: number;
/**
* File size error. If the user selects a file that is too large or is empty it will be blocked and
* an error of this type will be triggered.
*
* @property FILE_SIZE_ERROR
* @static
* @final
*/
export const FILE_SIZE_ERROR: number;
/**
* File extension error. If the user selects a file that isn't valid according to the filters setting.
*
* @property FILE_EXTENSION_ERROR
* @static
* @final
*/
export const FILE_EXTENSION_ERROR: number;
/**
* Duplicate file error. If prevent_duplicates is set to true and user selects the same file again.
*
* @property FILE_DUPLICATE_ERROR
* @static
* @final
*/
export const FILE_DUPLICATE_ERROR: number;
/**
* Runtime will try to detect if image is proper one. Otherwise will throw this error.
*
* @property IMAGE_FORMAT_ERROR
* @static
* @final
*/
export const IMAGE_FORMAT_ERROR: number;
/**
* While working on files runtime may run out of memory and will throw this error.
*
* @since 2.1.2
* @property MEMORY_ERROR
* @static
* @final
*/
export const MEMORY_ERROR: number;
/**
* Each runtime has an upper limit on a dimension of the image it can handle. If bigger, will throw this error.
*
* @property IMAGE_DIMENSIONS_ERROR
* @static
* @final
*/
export const IMAGE_DIMENSIONS_ERROR: number;

@@ -196,0 +475,0 @@

4

plupload/package.json
{
"name": "@types/plupload",
"version": "2.0.5",
"version": "2.0.6",
"description": "TypeScript definitions for Plupload",

@@ -20,4 +20,4 @@ "license": "MIT",

"dependencies": {},
"typesPublisherContentHash": "4d7283e2337442f602fc464983b3a5143d7159072185953f30a1884b06a35080",
"typesPublisherContentHash": "b15117586a48549e0d15de4dbcf03dc88c9b3a8f36a4d88bf3e4c41da2bc48f4",
"typeScriptVersion": "2.0"
}

@@ -11,3 +11,3 @@ # Installation

Additional Details
* Last updated: Thu, 05 Apr 2018 19:55:58 GMT
* Last updated: Thu, 12 Apr 2018 17:12:54 GMT
* Dependencies: none

@@ -14,0 +14,0 @@ * Global values: plupload

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc