This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// originally from https://dl.dropboxusercontent.com/u/52219470/Source/JSonPresentationFormatter.cs | |
public class JSonPresentationFormatter | |
{ | |
public static string Format(string text) | |
{ | |
if (string.IsNullOrEmpty(text)) return string.Empty; | |
text = text.Replace(System.Environment.NewLine, string.Empty).Replace("\t", string.Empty); | |
var offset = 0; | |
var output = new StringBuilder(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
declare module "H8/ConfigTypes" { | |
interface IMapDrawerDatasetsConfigElement { | |
DatasetsElement: IMapDrawerDatasetsElement; | |
PreferencesElement: IMapDrawerPreferencesElement; | |
DatasetGroupsElement: IMapDrawerDatasetGroupsElement; | |
DatasetLevelsElement: IMapDrawerDatasetsLevelsElement; | |
DatasetToolsElement: IMapDrawerToolsConfigElement; | |
TileCacheUrl: string; | |
JsMixin: string; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
declare module "proj4" { | |
interface Transformer { | |
forward: (p: Point) => Point; | |
inverse: (p: Point) => Point; | |
} | |
class Point { | |
x: number; | |
y: number; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Deferred = require("dojo/Deferred"); | |
class Navigation { | |
private _directions: google.maps.DirectionsResult; | |
private _ready: Deferred<Navigation>; | |
constructor(args: { | |
start?: any; | |
end?: any; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import Deferred = require('dojo/Deferred'); | |
import ContentPane = require("dijit/layout/ContentPane"); | |
import _WidgetBase = require("dijit/_WidgetBase"); | |
/* | |
dijit/layout/ContentPane wrapper as native typescript class | |
Constructor replaces itself with the underlying ContentPane | |
*/ | |
class MyContentPane implements ContentPane { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
declare module 'interfaces/json-schema' { | |
interface IDependencyDescriptor { | |
[s: string]: string; | |
} | |
interface IPropertyDescriptor { | |
[s: string]: { | |
'$ref'?: string; | |
type?: string; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<title>ArcGIS Javascript API Debugging Configuration</title> | |
<link rel="stylesheet" href="http://localhost:84/arcgis_js_api/esri/css/esri.css"> | |
<style> | |
html, body, #map { | |
height: 100%; | |
width: 100%; | |
margin: 0; | |
padding: 0; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
///<reference path="../ref.d.ts"/> | |
import declare = require("dojo/_base/declare"); | |
import lang = require("dojo/_base/lang"); | |
import ContentPane = require("dijit/layout/ContentPane"); | |
class LayerStylePane extends ContentPane { | |
constructor(options: any, container?: HTMLElement) { | |
this.baseClass = "layerStylePane"; | |
options.content = "<b>HELLO</b>"; | |
super(options, container); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Fails because return value is not HTMLElement | |
query(".symbolBuilderPane").map(node => registry.byNode(node)); | |
//NodeList isn't really an array so this also fails: | |
array.map(query(".symbolBuilderPane"), node => registry.byNode(node)); | |
//No type of node so this fails: | |
array.map(<any>query(".symbolBuilderPane"), node => registry.byNode(node)); | |
// leaving me here: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// converted from ol readers | |
declare module ogc { | |
module wms { | |
export interface ContactPersonPrimary { | |
ContactPerson: string; | |
ContactOrganization: string; | |
} |