Skip to content

Commit

Permalink
Export more type aliases
Browse files Browse the repository at this point in the history
  • Loading branch information
kitsonk committed May 4, 2016
1 parent 6644932 commit 6b27f1f
Show file tree
Hide file tree
Showing 6 changed files with 68 additions and 16 deletions.
8 changes: 6 additions & 2 deletions dijit/1.11/dijit.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -699,8 +699,8 @@ declare namespace dijit {
defer(fcn: Function, delay?: number): dojo.Handle;
}

interface _WidgetBaseConstructor<T> extends dojo._base.DeclareConstructor<T> {
new (params: Object, srcNodeRef: dojo.NodeOrString): T;
interface _WidgetBaseConstructor<W> extends dojo._base.DeclareConstructor<W> {
new (params: Object, srcNodeRef: dojo.NodeOrString): W;
}

/* dijit/_WidgetsInTemplateMixin */
Expand All @@ -715,6 +715,10 @@ declare namespace dijit {
startup(): void;
}

interface _WidgetsInTemplateMixinConstructor extends dojo._base.DeclareConstructor<_WidgetsInTemplateMixin> {
new (params: Object, srcNodeRef: dojo.NodeOrString): _WidgetsInTemplateMixin;
}

/* dijit/a11yclick */

interface A11yClick {
Expand Down
2 changes: 2 additions & 0 deletions dijit/1.11/layout.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,8 @@ declare namespace dijit {
layout(): void;
}

interface _LayoutWidgetConstructor extends _WidgetBaseConstructor<_LayoutWidget> { }

/* dijit/layout/_TabContainerBase */

interface _TabContainerBase extends StackContainer, _TemplatedMixin {
Expand Down
64 changes: 51 additions & 13 deletions dijit/1.11/modules.d.ts
Original file line number Diff line number Diff line change
@@ -1,206 +1,244 @@
/// <reference path="index.d.ts" />

declare module 'dijit/_WidgetBase' {
let _WidgetBase: dijit._WidgetBase;
type _WidgetBase = dijit._WidgetBase;
const _WidgetBase: dijit._WidgetBaseConstructor<any>;
export = _WidgetBase;
}

declare module 'dijit/_TemplatedMixin' {
let _TemplatedMixin: dijit._TemplatedMixin;
type _TemplatedMixin = dijit._TemplatedMixin;
const _TemplatedMixin: dijit._TemplatedMixinConstructor;
export = _TemplatedMixin;
}

declare module 'dijit/_WidgetsInTemplateMixin' {
let _WidgetsInTemplateMixin: dijit._WidgetsInTemplateMixin;
type _WidgetsInTemplateMixin = dijit._WidgetsInTemplateMixin
const _WidgetsInTemplateMixin: dijit._WidgetsInTemplateMixinConstructor;
export = _WidgetsInTemplateMixin;
}

declare module 'dijit/ConfirmDialog' {
let ConfirmDialog: dijit.ConfirmDialogConstructor;
type ConfirmDialog = dijit.ConfirmDialog;
const ConfirmDialog: dijit.ConfirmDialogConstructor;
export = ConfirmDialog;
}

declare module 'dijit/Calendar' {
let Calendar: dijit.CalendarConstructor;
type Calendar = dijit.Calendar;
const Calendar: dijit.CalendarConstructor;
export = Calendar;
}

declare module 'dijit/CalendarLite' {
let CalendarLite: dijit.CalendarLiteConstructor;
type CalendarLite = dijit.CalendarLite;
const CalendarLite: dijit.CalendarLiteConstructor;
export = CalendarLite;
}

declare module 'dijit/Dialog' {
let Dialog: dijit.DialogConstructor;
type Dialog = dijit.Dialog;
const Dialog: dijit.DialogConstructor;
export = Dialog;
}

declare module 'dijit/place' {
let place: dijit.Place;
const place: dijit.Place;
export = place;
}

declare module 'dijit/popup' {
let popup: dijit.PopupManager;
const popup: dijit.PopupManager;
export = popup;
}

declare module 'dijit/form/_FormMixin' {
let _FormMixin: dijit.form._FormMixin;
const _FormMixin: dijit.form._FormMixin;
export = _FormMixin;
}

declare module 'dijit/form/Button' {
type Button = dijit.form.Button;
const Button: dijit.form.ButtonConstructor;
export = Button;
}

declare module 'dijit/form/CheckBox' {
type CheckBox = dijit.form.CheckBox;
const CheckBox: dijit.form.CheckBoxConstructor;
export = CheckBox;
}

declare module 'dijit/form/ComboBox' {
type ComboBox = dijit.form.TextBox;
const ComboBox: dijit.form.ComboBoxConstructor;
export = ComboBox;
}

declare module 'dijit/form/CurrencyTextBox' {
type CurrencyTextBox = dijit.form.CurrencyTextBox;
const CurrencyTextBox: dijit.form.CurrencyTextBoxConstructor;
export = CurrencyTextBox;
}

declare module 'dijit/form/DataList' {
type DataList<T> = dijit.form.DataList<T>;
const DataList: dijit.form.DataListConstructor;
export = DataList;
}

declare module 'dijit/form/DateTextBox' {
type DateTextBox = dijit.form.DateTextBox;
const DateTextBox: dijit.form.DateTextBoxConstructor;
export = DateTextBox;
}

declare module 'dijit/form/DropDownButton' {
type DropDownButton<T extends dijit._WidgetBase> = dijit.form.DropDownButton<T>;
const DropDownButton: dijit.form.DropDownButtonConstructor;
export = DropDownButton;
}

declare module 'dijit/form/FilteringSelect' {
type FilteringSelect<C extends dijit.form.Constraints, T extends Object, Q extends string | Object | Function, O extends dojo.store.api.QueryOptions> = dijit.form.FilteringSelect<C, T, Q, O>;
const FilteringSelect: dijit.form.FilteringSelectConstructor;
export = FilteringSelect;
}

declare module 'dijit/form/Form' {
type Form = dijit.form.Form;
const Form: dijit.form.FormConstructor;
export = Form;
}

declare module 'dijit/form/MappedTextBox' {
type MappedTextBox<C extends dijit.form.Constraints> = dijit.form.MappedTextBox<C>;
const MappedTextBox: dijit.form.MappedTextBoxConstructor;
export = MappedTextBox;
}

declare module 'dijit/form/NumberSpinner' {
type NumberSpinner = dijit.form.NumberSpinner;
const NumberSpinner: dijit.form.NumberSpinnerConstructor;
export = NumberSpinner;
}

declare module 'dijit/form/NumberTextBox' {
type NumberTextBox = dijit.form.NumberTextBox;
const NumberTextBox: dijit.form.NumberTextBoxConstructor;
export = NumberTextBox;
}

declare module 'dijit/form/RadioButton' {
type RadioButton = dijit.form.RadioButton;
const RadioButton: dijit.form.RadioButtonConstructor;
export = RadioButton;
}

declare module 'dijit/form/RangeBoundTextBox' {
type RangeBoundTextBox = dijit.form.RangeBoundTextBox;
const RangeBoundTextBox: dijit.form.RangeBoundTextBoxConstructor;
export = RangeBoundTextBox;
}

declare module 'dijit/form/SimpleTextarea' {
const SimpleTextarea: dijit.form.SimpleTextarea;
declare module 'dijit/form/Simpconstextarea' {

This comment has been minimized.

Copy link
@jkieboom

jkieboom Nov 4, 2016

Contributor

Looks like a let->const search/replace issue.

This comment has been minimized.

Copy link
@dasa

dasa Nov 11, 2016

Contributor

Issue #49 created for this

type SimpleTextarea = dijit.form.SimpleTextarea;
const SimpleTextarea: dijit.form.SimpleTextareaConstructor;
export = SimpleTextarea;
}

declare module 'dijit/form/Textarea' {
type Textarea = dijit.form.Textarea;
const Textarea: dijit.form.TextareaConstructor;
export = Textarea;
}

declare module 'dijit/form/TextBox' {
type TextBox = dijit.form.TextBox;
const TextBox: dijit.form.TextBoxConstructor;
export = TextBox;
}

declare module 'dijit/form/ToggleButton' {
type ToggleButton = dijit.form.ToggleButton;
const ToggleButton: dijit.form.ToggleButtonConstructor;
export = ToggleButton;
}

declare module 'dijit/form/ValidationTextBox' {
type ValidationTextBox<C extends dijit.form.Constraints> = dijit.form.ValidationTextBox<C>;
const ValidationTextBox: dijit.form.ValidationTextBoxConstructor;
export = ValidationTextBox;
}

declare module 'dijit/layout/_LayoutWidget' {
const _LayoutWidget: dijit.layout._LayoutWidget;
type _LayoutWidget = dijit.layout._LayoutWidget;
const _LayoutWidget: dijit.layout._LayoutWidgetConstructor;
export = _LayoutWidget;
}

declare module 'dijit/layout/AccordionContainer' {
type AccordionContainer = dijit.layout.AccordionContainer;
const AccordionContainer: dijit.layout.AccordionContainerConstructor;
export = AccordionContainer;
}

declare module 'dijit/layout/AccordionPane' {
type AccordionPane = dijit.layout.AccordionPane;
const AccordionPane: dijit.layout.AccordionPaneConstructor;
export = AccordionPane;
}

declare module 'dijit/layout/ContentPane' {
type ContentPane = dijit.layout.ContentPane;
const ContentPane: dijit.layout.ContentPaneConstructor;
export = ContentPane;
}

declare module 'dijit/layout/BorderContainer' {
type BorderContainer = dijit.layout.BorderContainer;
const BorderContainer: dijit.layout.BorderContainerConstructor;
export = BorderContainer;
}

declare module 'dijit/layout/LayoutContainer' {
type LayoutContainer = dijit.layout.LayoutContainer;
const LayoutContainer: dijit.layout.LayoutContainerConstructor;
export = LayoutContainer;
}

declare module 'dijit/layout/LinkPane' {
type LinkPane = dijit.layout.LinkPane;
const LinkPane: dijit.layout.LinkPaneConstructor;
export = LinkPane;
}

declare module 'dijit/layout/ScrollingTabController' {
type ScrollingTabController = dijit.layout.ScrollingTabController;
const ScrollingTabController: dijit.layout.ScrollingTabControllerConstructor;
export = ScrollingTabController;
}

declare module 'dijit/layout/StackContainer' {
type StackContainer = dijit.layout.StackContainer;
const StackContainer: dijit.layout.StackContainerConstructor;
export = StackContainer;
}

declare module 'dijit/layout/StackController' {
type StackController = dijit.layout.StackController;
const StackController: dijit.layout.StackControllerConstructor;
export = StackController;
}

declare module 'dijit/layout/TabContainer' {
type TabContainer = dijit.layout.TabContainer;
const TabContainer: dijit.layout.TabContainerConstructor;
export = TabContainer;
}

declare module 'dijit/layout/TabController' {
type TabController = dijit.layout.TabController;
const TabController: dijit.layout.TabControllerConstructor;
export = TabController;
}
2 changes: 1 addition & 1 deletion dojo/1.11/on.d.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/// <reference path="dojo" />
/// <reference path="dojo.d.ts" />

declare namespace dojo {
namespace on {
Expand Down
1 change: 1 addition & 0 deletions dojox/1.11/color.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -187,6 +187,7 @@ declare namespace dojo {
}

declare module 'dojox/color/api/ColorModel' {
type ColorModel = dojox.color.api.ColorModel;
const ColorModel: dojox.color.api.ColorModelConstructor;
export = ColorModel;
}
Expand Down
7 changes: 7 additions & 0 deletions dojox/1.11/modules.d.ts
Original file line number Diff line number Diff line change
@@ -1,36 +1,43 @@
/// <reference path="index.d.ts" />

declare module 'dojox/layout/ContentPane' {
type ContentPane = dojox.layout.ContentPane;
const ContentPane: dojox.layout.ContentPaneConstructor;
export = ContentPane;
}

declare module 'dojox/layout/GridContainer' {
type GridContainer = dojox.layout.GridContainer;
const GridContainer: dojox.layout.GridContainerConstructor;
export = GridContainer;
}

declare module 'dojox/layout/GridContainerLite' {
type GridContainerLite = dojox.layout.GridContainerLite;
const GridContainerLite: dojox.layout.GridContainerLiteConstructor;
export = GridContainerLite;
}

declare module 'dojox/layout/TableContainer' {
type TableContainer = dojox.layout.TableContainer;
const TableContainer: dojox.layout.TableContainerConstructor;
export = TableContainer;
}

declare module 'dojox/widget/DialogSimple' {
type DialogSimple = dojox.widget.DialogSimple;
const DialogSimple: dojox.widget.DialogSimpleConstructor;
export = DialogSimple;
}

declare module 'dojox/widget/Dialog' {
type Dialog = dojox.widget.Dialog;
const Dialog: dojox.widget.DialogConstructor;
export = Dialog;
}

declare module 'dojox/widget/Toaster' {
type Toaster = dojox.widget.Toaster;
const Toaster: dojox.widget.ToasterConstructor;
export = Toaster;
}

0 comments on commit 6b27f1f

Please sign in to comment.