From e8b3b4c4cee3786bc71bd205c269f59110eac2f6 Mon Sep 17 00:00:00 2001 From: Dick van den Brink Date: Tue, 14 Jan 2014 22:19:02 +0100 Subject: [PATCH] Added JQueryMobilePath interface See http://api.jquerymobile.com/category/methods/path/ --- jquerymobile/jquerymobile.d.ts | 26 +++++++++++++++++++++++++- 1 file changed, 25 insertions(+), 1 deletion(-) diff --git a/jquerymobile/jquerymobile.d.ts b/jquerymobile/jquerymobile.d.ts index e7f92e8a2c..dfc2a1de7b 100644 --- a/jquerymobile/jquerymobile.d.ts +++ b/jquerymobile/jquerymobile.d.ts @@ -298,6 +298,30 @@ interface LoaderOptions { textonly?: boolean; } +interface JQueryMobilePath { + get(url: string): string; + getDocumentBase(asParsedObject?: boolean): any; + getDocumentUrl(asParsedObject?: boolean): any; + getLocation(): string; + isAbsoluteUrl(url: string): boolean; + isRelativeUrl(url: string): boolean; + makeUrlAbsolute(relUrl: string, absUrl: string): string; + parseLocation(): ParsedPath; + parseUrl(url): ParsedPath; +} + +interface ParsedPath { + hash: string; + host: string; + hostname: string; + href: string; + pathname: string; + port: string; + protocol: string; + search: string; +} + + interface JQueryMobile extends JQueryMobileOptions { version: string; @@ -321,7 +345,7 @@ interface JQueryMobile extends JQueryMobileOptions { touchOverflow: any; showCategory: any; - path: any; + path: JQueryMobilePath; dialog: any; popup: any;