mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-04-23 12:56:46 +08:00
* base-64 typings
* formatting and indenting
* feat: add typings for watchpack
* fix: improve missing typings
* Port from https://github.com/agileek/typings-vis/blob/master/vs.d.ts
* Fix travis build failures
* Port PR https://github.com/agileek/typings-vis/pull/12
* Fix travis build failures
* added tsconfig and tslint
* removed patch number
* added tests
* made it export like base64-js
* removed old code
* formatted code
* fix: add files field in tsconfig.json for expected publishment
* fix: improve most missing typings
* feat: upgrade to v3.0.0
* feat: upgrade to tapbale v0.2.5
* Types 2.0 (#13261)
* updating typing of the latest 7.0 react-autosuggest
* updating typing of react-autosuggest 7.0
* update typings for react-autosuggest 7.0
* Remove '+' from header versions, so they can be parsed (#13239)
* Updated masonry-layout to fix linting errors (#13272)
* Updated masonry-layout to fix linting errors
* Fixed the tests I could fix.
* Removed patch version
* Add redux-persist and basic transformers (#13389)
* Add definitions for redux-persist
* Add missin generic types
* Add definitions for filter transformer
* Add definitions for encrypt transformer
* Fix header
* Add definitions for compress transformer
* Delete unnecessary linter configs
* Change way of importing, fix tests
* fix: angulartics type definition for ES6 import
* fix: lint error
* fix scalar type config (#13398)
The `GraphQLScalarTypeConfig` interface had incorrect types. Correct types may be seen here: 379a308439/src/type/definition.js (L348-L350)
* [interact.js] Update module names (#13316)
Update CommonJS module name as it was changed in version 1.2.7.
AMD module name is also different from both new and old CommonJS module names, so a separate declaration was created for that as well.
* Add definitions for redux-recycle (#13424)
* Add definitions for redux-recycle
* Fix linter errors
* [jest] add type definition for toHaveBeenLastCalledWith (#13038)
* remove ajv because the package bundles its own types (#13028)
* Updated type definitions to yfiles for HTML 2.0. (#13332)
* Updated type definitions to yFiles for HTML 2.0.
* Updated type definitions to yfiles for HTML 2.0.
* Added contact in yfiles .d.ts header.
* Add redux-batched-actions typings. (#13054)
* Add types for mailgen (#13080)
* Typings for cordova-sqlite-storage (#13081)
* Add flatpickr definitions (#13083)
* Add pouch-redux-middleware typing (#13071)
* Add pouch-redux-middleware typing
* Fix <> in comment
* Add declaration for crc (#13068)
* Updated jquery.dataTables for 1.10.9 (#13099)
Release Notes: https://cdn.datatables.net/1.10.9/
* Moved legacy browser settings to its own data type.
* Added 'aIds' property on legacy settings object for mapping row ids to data indexes.
* Added 'rowIdFn' function to legacy settings object to get a row's id from the row's data.
* chore(lint): change vis typing to external module (#13399)
* Fix cordova-sqlite-storage lint
* Lint `vis`: Remove "I" prefix for namespaces
* Change cordova-sqlite-storage back. Linter was wrong.
144 lines
4.0 KiB
TypeScript
144 lines
4.0 KiB
TypeScript
// Type definitions for jsUri 1.3
|
|
// Project: https://github.com/derek-watson/jsUri
|
|
// Definitions by: Chris Charabaruk <http://github.com/coldacid>, Florian Wagner <http://github.com/flqw>
|
|
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
|
|
|
declare namespace jsuri {
|
|
type Primitive = string | number | boolean;
|
|
|
|
export class Uri {
|
|
/**
|
|
* Creates a new Uri object
|
|
* @constructor
|
|
* @param {string} str
|
|
*/
|
|
constructor(str?: string);
|
|
|
|
/**
|
|
* Define getter/setter methods
|
|
*/
|
|
protocol(val?: string): string;
|
|
userInfo(val?: string): string;
|
|
host(val?: string): string;
|
|
port(val?: number): number;
|
|
path(val?: string): string;
|
|
anchor(val?: string): string;
|
|
|
|
/**
|
|
* if there is no protocol, the leading // can be enabled or disabled
|
|
* @param {Boolean} val
|
|
* @return {Boolean}
|
|
*/
|
|
hasAuthorityPrefix(val?: boolean): boolean;
|
|
|
|
isColonUri(val?: boolean): boolean;
|
|
|
|
/**
|
|
* Serializes the internal state of the query pairs
|
|
* @param {string} [val] set a new query string
|
|
* @return {string} query string
|
|
*/
|
|
query(val?: string): string;
|
|
|
|
/**
|
|
* returns the first query param value found for the key
|
|
* @param {string} key query key
|
|
* @return {string} first value found for key
|
|
*/
|
|
getQueryParamValue(key: string): string;
|
|
|
|
/**
|
|
* returns an array of query param values for the key
|
|
* @param {string} key query key
|
|
* @return {array} array of values
|
|
*/
|
|
getQueryParamValues(key: string): string[];
|
|
|
|
/**
|
|
* removes query parameters
|
|
* @param {string} key remove values for key
|
|
* @param {val} [val] remove a specific value, otherwise removes all
|
|
* @return {Uri} returns self for fluent chaining
|
|
*/
|
|
deleteQueryParam(key: string, val?: string): Uri;
|
|
|
|
/**
|
|
* adds a query parameter
|
|
* @param {string} key add values for key
|
|
* @param {string} val value to add
|
|
* @param {integer} [index] specific index to add the value at
|
|
* @return {Uri} returns self for fluent chaining
|
|
*/
|
|
addQueryParam(key: string, val: Primitive, index?: number): Uri;
|
|
|
|
/**
|
|
* test for the existence of a query parameter
|
|
* @param {string} key check values for key
|
|
* @return {Boolean} true if key exists, otherwise false
|
|
*/
|
|
hasQueryParam(key: string): boolean;
|
|
|
|
/**
|
|
* replaces query param values
|
|
* @param {string} key key to replace value for
|
|
* @param {string} newVal new value
|
|
* @param {string} [oldVal] replace only one specific value (otherwise replaces all)
|
|
* @return {Uri} returns self for fluent chaining
|
|
*/
|
|
replaceQueryParam(key: string, newVal: Primitive, oldVal?: Primitive): Uri;
|
|
|
|
/**
|
|
* Define fluent setter methods (setProtocol, setHasAuthorityPrefix, etc)
|
|
*/
|
|
setProtocol(val: string): Uri;
|
|
setHasAuthorityPrefix(val: boolean): Uri;
|
|
setIsColonUri(val: boolean): Uri;
|
|
setUserInfo(val: string): Uri;
|
|
setHost(val: string): Uri;
|
|
setPort(val: number): Uri;
|
|
setPath(val: string): Uri;
|
|
setQuery(val: string): Uri;
|
|
setAnchor(val: string): Uri;
|
|
|
|
/**
|
|
* Scheme name, colon and doubleslash, as required
|
|
* @return {string} http:// or possibly just //
|
|
*/
|
|
scheme(): string;
|
|
|
|
/**
|
|
* Same as Mozilla nsIURI.prePath
|
|
* @return {string} scheme://user:password@host:port
|
|
* @see https://developer.mozilla.org/en/nsIURI
|
|
*/
|
|
origin(): string;
|
|
|
|
/**
|
|
* Adds a trailing slash to the path
|
|
*/
|
|
addTrailingSlash(): Uri;
|
|
|
|
/**
|
|
* Serializes the internal state of the Uri object
|
|
* @return {string}
|
|
*/
|
|
toString(): string;
|
|
|
|
/**
|
|
* Clone a Uri object
|
|
* @return {Uri} duplicate copy of the Uri
|
|
*/
|
|
clone(): Uri;
|
|
}
|
|
}
|
|
|
|
declare type Uri = jsuri.Uri;
|
|
|
|
declare module 'jsuri' {
|
|
export = jsuri.Uri;
|
|
}
|
|
|
|
declare module 'jsUri' {
|
|
export = jsuri.Uri;
|
|
}
|