Merge remote-tracking branch 'origin/dev' into timeline

pull/4927/head
Oliver Günther 8 years ago
commit a40cadd77a
No known key found for this signature in database
GPG Key ID: 88872239EB414F99
  1. BIN
      app/assets/fonts/openproject_icon/openproject-icon-font.eot
  2. 2
      app/assets/fonts/openproject_icon/openproject-icon-font.svg
  3. BIN
      app/assets/fonts/openproject_icon/openproject-icon-font.ttf
  4. BIN
      app/assets/fonts/openproject_icon/openproject-icon-font.woff
  5. 6
      app/assets/stylesheets/fonts/_openproject_icon_definitions.scss
  6. 2
      app/assets/stylesheets/fonts/_openproject_icon_font.lsg
  7. 11
      app/assets/stylesheets/layout/_breadcrumb.sass
  8. 8
      app/assets/stylesheets/layout/_top_menu.sass
  9. 4
      app/controllers/my_controller.rb
  10. 2
      app/helpers/breadcrumb_helper.rb
  11. 9
      config/initializers/menus.rb
  12. 2
      frontend/app/components/animations/toggle-slide.animation.ts
  13. 2
      frontend/app/components/api/api-v3/hal-link/hal-link.service.ts
  14. 3
      frontend/app/components/api/api-v3/hal-resources/attachment-collection-resource.service.test.ts
  15. 2
      frontend/app/components/api/api-v3/hal-resources/error-resource.service.ts
  16. 4
      frontend/app/components/api/api-v3/hal-resources/hal-resource.service.ts
  17. 5
      frontend/app/components/api/api-v3/hal-resources/work-package-resource.service.test.ts
  18. 2
      frontend/app/components/api/api-v3/hal-resources/work-package-resource.service.ts
  19. 2
      frontend/app/components/api/op-file-upload/op-file-upload.service.ts
  20. 2
      frontend/app/components/api/path-builder/path-builder.service.ts
  21. 4
      frontend/app/components/common/notifications/notifications.service.ts
  22. 2
      frontend/app/components/filters/query-filters/query-filters.directive.ts
  23. 4
      frontend/app/components/filters/query-model/query-model.service.ts
  24. 4
      frontend/app/components/input/transformers/transform-duration.directive.ts
  25. 4
      frontend/app/components/modals/columns-modal/columns-modal.controller.ts
  26. 8
      frontend/app/components/work-packages/work-package-authorization.service.ts
  27. 1
      frontend/app/components/wp-attachments/wp-attachments-upload/wp-attachments-upload.directive.test.ts
  28. 2
      frontend/app/components/wp-buttons/wp-filter-button/wp-filter-button.directive.ts
  29. 3
      frontend/app/components/wp-edit/field-types/wp-edit-select-field.module.ts
  30. 4
      frontend/app/components/wp-fast-table/builders/rows/grouped-rows-builder.ts
  31. 2
      frontend/app/components/wp-fast-table/state/wp-table-columns.service.ts
  32. 2
      frontend/app/components/wp-fast-table/state/wp-table-metadata.service.ts
  33. 2
      frontend/app/components/wp-fast-table/wp-table.interfaces.ts
  34. 3
      frontend/app/components/wp-panels/watchers-panel/watchers-panel.controller.ts
  35. 2
      frontend/app/components/wp-relations/wp-relation-row/wp-relation-row.directive.ts
  36. 2
      frontend/app/components/wp-table/context-menu-helper/wp-context-menu-helper.service.ts
  37. 1
      frontend/app/components/wp-table/wp-virtual-scroll.directive.ts
  38. 1
      frontend/app/typings.d.ts
  39. 20
      frontend/app/typings/shims.d.ts
  40. 19
      frontend/karma.conf.js
  41. 1739
      frontend/npm-shrinkwrap.json
  42. 39
      frontend/package.json
  43. 5
      frontend/tsconfig.json
  44. 3
      frontend/tsconfig.test.json
  45. 29
      frontend/typings.json
  46. 305
      frontend/typings/globals/angular-animate/index.d.ts
  47. 8
      frontend/typings/globals/angular-animate/typings.json
  48. 313
      frontend/typings/globals/angular-mocks/index.d.ts
  49. 8
      frontend/typings/globals/angular-mocks/typings.json
  50. 350
      frontend/typings/globals/angular-ui-router/index.d.ts
  51. 8
      frontend/typings/globals/angular-ui-router/typings.json
  52. 1957
      frontend/typings/globals/angular/index.d.ts
  53. 8
      frontend/typings/globals/angular/typings.json
  54. 12
      frontend/typings/globals/assertion-error/index.d.ts
  55. 8
      frontend/typings/globals/assertion-error/typings.json
  56. 285
      frontend/typings/globals/chai-as-promised/index.d.ts
  57. 8
      frontend/typings/globals/chai-as-promised/typings.json
  58. 392
      frontend/typings/globals/chai/index.d.ts
  59. 8
      frontend/typings/globals/chai/typings.json
  60. 666
      frontend/typings/globals/es6-shim/index.d.ts
  61. 8
      frontend/typings/globals/es6-shim/typings.json
  62. 3181
      frontend/typings/globals/jquery/index.d.ts
  63. 8
      frontend/typings/globals/jquery/typings.json
  64. 1909
      frontend/typings/globals/jqueryui/index.d.ts
  65. 8
      frontend/typings/globals/jqueryui/typings.json
  66. 14988
      frontend/typings/globals/lodash/index.d.ts
  67. 8
      frontend/typings/globals/lodash/typings.json
  68. 234
      frontend/typings/globals/mocha/index.d.ts
  69. 8
      frontend/typings/globals/mocha/typings.json
  70. 675
      frontend/typings/globals/moment-node/index.d.ts
  71. 8
      frontend/typings/globals/moment-node/typings.json
  72. 3
      frontend/typings/globals/moment/index.d.ts
  73. 8
      frontend/typings/globals/moment/typings.json
  74. 29
      frontend/typings/globals/mousetrap/index.d.ts
  75. 8
      frontend/typings/globals/mousetrap/typings.json
  76. 252
      frontend/typings/globals/ng-dialog/index.d.ts
  77. 8
      frontend/typings/globals/ng-dialog/typings.json
  78. 176
      frontend/typings/globals/nouislider/index.d.ts
  79. 8
      frontend/typings/globals/nouislider/typings.json
  80. 15
      frontend/typings/globals/promises-a-plus/index.d.ts
  81. 8
      frontend/typings/globals/promises-a-plus/typings.json
  82. 199
      frontend/typings/globals/rosie/index.d.ts
  83. 8
      frontend/typings/globals/rosie/typings.json
  84. 79
      frontend/typings/globals/sinon-chai/index.d.ts
  85. 8
      frontend/typings/globals/sinon-chai/typings.json
  86. 432
      frontend/typings/globals/sinon/index.d.ts
  87. 8
      frontend/typings/globals/sinon/typings.json
  88. 242
      frontend/typings/globals/urijs/index.d.ts
  89. 8
      frontend/typings/globals/urijs/typings.json
  90. 225
      frontend/typings/globals/webpack-env/index.d.ts
  91. 8
      frontend/typings/globals/webpack-env/typings.json
  92. 23
      frontend/typings/index.d.ts
  93. 104
      frontend/webpack-main-config.js
  94. 12
      lib/redmine/menu_manager/top_menu_helper.rb
  95. 6
      spec_legacy/unit/lib/redmine_spec.rb

@ -228,4 +228,6 @@
<glyph glyph-name="cancel" unicode="&#57344;" d="M256 301l-160 160-45-48 160-157-160-157 45-48 160 160 160-160 45 48-160 157 160 157-45 48z"/>
<glyph glyph-name="design" unicode="&#57374;" d="M473 482l15-8c19-19-4-43-4-43-44-43-87-87-130-130-14-14-20-18-31-37-13-21-25-44-35-66l-78 78c0 0 68 27 92 51 34 35 69 69 104 104 14 14 27 30 43 42z m-443-435c61 15 55 65 91 151 18 42 65 54 65 54l78-78c0 0 0-167-234-127"/>
<glyph glyph-name="headset" unicode="&#57522;" d="M477 326c-26 106-115 183-221 183-106 0-195-77-221-179-19-7-32-23-32-42l0-54c0-26 19-45 45-45l51 0 0 141-32 0c26 86 99 147 189 147 90 0 163-61 189-147l-32 0 0-141 22 0c-25-61-73-106-137-122-7 16-23 29-42 29-26 0-48-22-48-48 0-13 3-22 10-29 9-13 22-19 38-19 22 0 38 16 45 35 80 16 144 77 169 154 23 3 39 22 39 45l0 51c0 19-13 38-32 41z m-221-208c74 0 131 58 131 125l0 48c0 71-57 125-131 125-74 0-131-54-131-125l0-48c0-67 57-125 131-125z"/>
<glyph glyph-name="arrow-thin" unicode="&#57565;" d="M369 285l-226 227-33-33 219-219-219-220 33-33 226 231 26 22z"/>
<glyph glyph-name="menu" unicode="&#57566;" d="M0 512l128 0 0-128-128 0z m192 0l128 0 0-128-128 0z m192 0l128 0 0-128-128 0z m-384-192l128 0 0-128-128 0z m192 0l128 0 0-128-128 0z m192 0l128 0 0-128-128 0z m-384-192l128 0 0-128-128 0z m192 0l128 0 0-128-128 0z m192 0l128 0 0-128-128 0z"/>
</font></defs></svg>

Before

Width:  |  Height:  |  Size: 84 KiB

After

Width:  |  Height:  |  Size: 84 KiB

@ -689,3 +689,9 @@
.icon-headset:before {
content: "\e0b2";
}
.icon-arrow-thin:before {
content: "\e0dd";
}
.icon-menu:before {
content: "\e0de";
}

@ -22,6 +22,7 @@
<li><span class="icon icon-arrow-right5"></span> arrow-right5</li>
<li><span class="icon icon-arrow-right6"></span> arrow-right6</li>
<li><span class="icon icon-arrow-right7"></span> arrow-right7</li>
<li><span class="icon icon-arrow-thin"></span> arrow-thin</li>
<li><span class="icon icon-arrow-up1"></span> arrow-up1</li>
<li><span class="icon icon-arrow-up2"></span> arrow-up2</li>
<li><span class="icon icon-assigned-to-me"></span> assigned-to-me</li>
@ -122,6 +123,7 @@
<li><span class="icon icon-mail2"></span> mail2</li>
<li><span class="icon icon-maintenance-support"></span> maintenance-support</li>
<li><span class="icon icon-meetings"></span> meetings</li>
<li><span class="icon icon-menu"></span> menu</li>
<li><span class="icon icon-microphone"></span> microphone</li>
<li><span class="icon icon-milestone"></span> milestone</li>
<li><span class="icon icon-minus1"></span> minus1</li>

@ -33,9 +33,9 @@
@include default-transition
height: $breadcrumb-height
overflow: hidden
background: none repeat scroll 0 0 $breadcrumb-bg-color
background: none repeat scroll 0 0
@include varprop(background-color, body-background)
border: none
border-bottom: 1px solid $breadcrumb-border-color
margin: 0 0 0 ($main-menu-width - $main-menu-item-border-width)
width: auto
overflow: hidden
@ -48,7 +48,9 @@
margin-left: $main-menu-folded-width
a
@extend %breadcrumb--default-font
font-size: 12px
@include varprop(color, content-link-color)
font-weight: normal
li
@extend %breadcrumb--default-font
@ -80,5 +82,4 @@ ul.breadcrumb
#breadcrumb ul.breadcrumb li
float: left
margin: 0 0 0 10px
padding: 0 25px 0 0
background: image-url('breadcrumb-list.png') no-repeat right center
padding: 0

@ -105,7 +105,8 @@
top: 0
z-index: 21
li.last-child > ul,
ul.drop-down--help
ul.drop-down--help,
ul.drop-down--modules
left: auto
right: 0
@ -309,12 +310,13 @@ input.top-menu-search--input
.icon-help:before
border: 2px solid $header-item-font-color
border-radius: 50%
padding: 0.25rem
.icon-help:hover:before
border-color: $header-item-font-hover-color
@include varprop(border-color, header-item-font-hover-color)
.icon-user
font-size: 18px
[class*="icon-"]:before
padding: 0.25rem
// Temporary overwrite searchfield styles for mobile view
// until we have a full responsive layout

@ -72,10 +72,6 @@ class MyController < ApplicationController
end
alias :page :index
current_menu_item :page do
:my_page
end
# Edit user's account
def account
@user = User.current

@ -45,7 +45,7 @@ module BreadcrumbHelper
breadcrumb_elements = [content_tag(:li, elements.shift.to_s, class: 'first-breadcrumb-element', style: 'list-style-image:none;')]
breadcrumb_elements += elements.map { |element|
content_tag(:li, h(element.to_s)) if element
content_tag(:li, h(element.to_s), class: 'icon-context icon-small icon-arrow-right5') if element
}
content_tag(:ul, breadcrumb_elements.join.html_safe, class: 'breadcrumb')

@ -30,11 +30,6 @@
require 'redmine/menu_manager'
Redmine::MenuManager.map :top_menu do |menu|
menu.push :my_page,
{ controller: '/my', action: 'page' },
context: :main,
html: { class: 'icon3 icon-star' },
if: Proc.new { User.current.logged? }
# projects menu will be added by
# Redmine::MenuManager::TopMenuHelper#render_projects_top_menu_node
@ -80,6 +75,10 @@ Redmine::MenuManager.map :account_menu do |menu|
{ controller: '/my', action: 'account' },
html: { class: 'hidden-for-mobile' },
if: Proc.new { User.current.logged? }
menu.push :my_page,
{ controller: '/my', action: 'page' },
html: { class: 'hidden-for-mobile' },
if: Proc.new { User.current.logged? }
menu.push :logout, :signout_path,
if: Proc.new { User.current.logged? }
end

@ -56,4 +56,4 @@ function toggleSlideAnimation($window:ng.IWindowService) {
};
}
animationsModule.animation('.toggle-slide-animation', toggleSlideAnimation);
(animationsModule as any).animation('.toggle-slide-animation', toggleSlideAnimation);

@ -87,7 +87,7 @@ export class HalLink implements HalLinkInterface {
}
let href = _.clone(this.href) || '';
_.each(templateValues, (value, key) => {
_.each(templateValues, (value:string, key:string) => {
let regexp = new RegExp('{' + key + '}');
href = href.replace(regexp, value);
});

@ -29,7 +29,6 @@
import {opApiModule, opServicesModule} from '../../../../angular-modules';
import {AttachmentCollectionResource} from './attachment-collection-resource.service';
import {OpenProjectFileUploadService} from '../../op-file-upload/op-file-upload.service';
import SinonStub = Sinon.SinonStub;
describe('AttachmentCollectionResource service', () => {
var AttachmentCollectionResource:any;
@ -58,7 +57,7 @@ describe('AttachmentCollectionResource service', () => {
});
describe('when using upload()', () => {
var uploadStub: SinonStub;
var uploadStub: sinon.SinonStub;
var params:any;
beforeEach(() => {

@ -67,7 +67,7 @@ export class ErrorResource extends HalResource {
perAttribute[this.details.attribute] = [this.message];
}
else {
_.forEach(this.errors, error => {
_.forEach(this.errors, (error:any) => {
if (perAttribute[error.details.attribute]) {
perAttribute[error.details.attribute].push(error.message);
}

@ -210,7 +210,7 @@ function initializeResource(halResource:HalResource) {
}
function proxyProperties() {
_.without(Object.keys(halResource.$source), '_links', '_embedded').forEach(property => {
_.without(Object.keys(halResource.$source), '_links', '_embedded').forEach((property:any) => {
Object.defineProperty(halResource, property, {
get() {
return halResource.$source[property];
@ -227,7 +227,7 @@ function initializeResource(halResource:HalResource) {
}
function setLinksAsProperties() {
_.without(Object.keys(halResource.$links), 'self').forEach(linkName => {
_.without(Object.keys(halResource.$links), 'self').forEach((linkName:string) => {
lazy(halResource, linkName,
() => {
const link:any = halResource.$links[linkName].$link || halResource.$links[linkName];

@ -29,7 +29,6 @@
import {opApiModule} from '../../../../angular-modules';
import {WorkPackageCacheService} from '../../../work-packages/work-package-cache.service';
import IHttpBackendService = angular.IHttpBackendService;
import SinonStub = Sinon.SinonStub;
import IQService = angular.IQService;
import IRootScopeService = angular.IRootScopeService;
import IPromise = angular.IPromise;
@ -137,7 +136,7 @@ describe('WorkPackageResource service', () => {
});
describe('when updating multiple linked resources', () => {
var updateWorkPackageStub: SinonStub;
var updateWorkPackageStub: sinon.SinonStub;
var result:Promise<any>;
const expectCacheUpdate = () => {
@ -344,7 +343,7 @@ describe('WorkPackageResource service', () => {
});
describe('when using uploadPendingAttachments', () => {
var uploadAttachmentsStub: SinonStub;
var uploadAttachmentsStub: sinon.SinonStub;
beforeEach(() => {
workPackage.pendingAttachments.push({}, {});

@ -292,7 +292,7 @@ export class WorkPackageResource extends HalResource {
public setAllowedValueFor(field:string, href:string) {
this.allowedValuesFor(field).then(allowedValues => {
(this as any)[field] = _.find(allowedValues, entry => entry.href === href);
(this as any)[field] = _.find(allowedValues, (entry:any) => entry.href === href);
wpCacheService.updateWorkPackage(this);
});
}

@ -49,7 +49,7 @@ export class OpenProjectFileUploadService {
* Ignore directories.
*/
public upload(url: string, files: UploadFile[]): UploadResult {
files = _.filter(files, file => file.type !== 'directory');
files = _.filter(files, (file:UploadFile) => file.type !== 'directory');
const uploads = _.map(files, (file: UploadFile) => {
const params = {
fields: {

@ -95,7 +95,7 @@ class PathTemplate {
*/
public build(params:any):string {
var parent:PathTemplate|undefined;
params = _.pick(params, value => !!value);
params = _.pickBy(params, (value:any) => !!value);
Object.keys(params).forEach(name => {
parent = this.parents[name];

@ -65,7 +65,7 @@ function NotificationsService($rootScope:ng.IRootScopeService, $timeout:ng.ITime
currentNotifications:any = [],
notificationAdded = function (newNotification:any) {
var toRemove = currentNotifications.slice(0);
_.each(toRemove, function (existingNotification) {
_.each(toRemove, function (existingNotification:any) {
if (newNotification.type === 'success' || newNotification.type === 'error') {
remove(existingNotification);
}
@ -74,7 +74,7 @@ function NotificationsService($rootScope:ng.IRootScopeService, $timeout:ng.ITime
currentNotifications.push(newNotification);
},
notificationRemoved = function (removedNotification:any) {
_.remove(currentNotifications, function (element) {
_.remove(currentNotifications, function (element:any) {
return element === removedNotification;
});
},

@ -88,7 +88,7 @@ function queryFiltersDirective($timeout:ng.ITimeoutService, I18n:op.I18n, ADD_FI
};
function updateRemainingFilters() {
var remainingFilters = _.map(scope.query.getRemainingFilters(), function(filter:any, key) {
var remainingFilters = _.map(scope.query.getRemainingFilters(), function(filter:any, key:any) {
return {
key: key,
value: filter.modelName,

@ -372,13 +372,13 @@ function QueryModelService(
},
getRemainingFilters: function(this:any):any {
const activeFilters = _.indexBy(this.getActiveFilters(), function(f:any) { return f.name });
const activeFilters = _.keyBy(this.getActiveFilters(), function(f:any) { return f.name });
if (!activeFilters) {
return {};
}
return _.pick(this.availableWorkPackageFilters, function(filter:any, key:string) {
return _.pickBy(this.availableWorkPackageFilters, function(filter:any, key:string) {
return !activeFilters[key];
});
},

@ -26,6 +26,8 @@
// See doc/COPYRIGHT.rdoc for more details.
//++
import {Duration} from 'moment';
function transformDuration(TimezoneService:any) {
return {
restrict:'A',
@ -35,7 +37,7 @@ function transformDuration(TimezoneService:any) {
element:ng.IAugmentedJQuery,
attrs:ng.IAttributes,
ngModelController:any) {
ngModelController.$parsers.push(function(value:any):moment.Duration|void {
ngModelController.$parsers.push(function(value:any):Duration|void {
if (!isNaN(value)) {
var minutes = Number(moment.duration(value, 'hours').asMinutes().toFixed(2));
return moment.duration(minutes, 'minutes');

@ -70,7 +70,7 @@ function ColumnsModalController(this:any,
var availableColumnNames = getColumnNames(availableColumns);
selectedColumns.forEach((column:api.ex.Column) => {
if (_.contains(availableColumnNames, column.name)) {
if (_.find(availableColumnNames, column.name)) {
vm.selectedColumns.push(column);
vm.selectedColumnMap[column.name] = true;
vm.oldSelectedColumns.push(column);
@ -100,7 +100,7 @@ function ColumnsModalController(this:any,
vm.updateUnusedColumns = (selectedColumns:api.ex.Column[]) => {
var used = getColumnNames(selectedColumns);
vm.unusedColumns = vm.availableColumns.filter((column:api.ex.Column) => !_.contains(used, column.name));
vm.unusedColumns = vm.availableColumns.filter((column:api.ex.Column) => !_.find(used, column.name));
};
vm.setSelectedColumn = (column:api.ex.Column) => {

@ -75,17 +75,17 @@ export class WorkPackageAuthorization {
}
public permittedActionKeys(allowedActions:any) {
var validActions = _.filter(allowedActions, this.isPermitted, this);
var validActions = _.filter(allowedActions, (action:any) => this.isPermitted(action));
return _.map(validActions, function (action) {
return _.map(validActions, function (action:any) {
return action.key;
});
}
public permittedActionsWithLinks(allowedActions:any) {
var validActions = _.filter(_.cloneDeep(allowedActions), this.isPermitted, this);
var validActions = _.filter(_.cloneDeep(allowedActions), (action:any) => this.isPermitted(action));
var allowed = _.map(validActions, this.linkForAction, this);
var allowed = _.map(validActions, (action:any) => this.linkForAction(action));
return allowed;
}

@ -31,7 +31,6 @@ import {WorkPackageUploadDirectiveController} from './wp-attachments-upload.dire
import ICompileService = angular.ICompileService;
import IRootScopeService = angular.IRootScopeService;
import IAugmentedJQuery = angular.IAugmentedJQuery;
import SinonStub = Sinon.SinonStub;
import IQService = angular.IQService;
import ICompileProvider = angular.ICompileProvider;

@ -63,7 +63,7 @@ export class WorkPackageFilterButtonController extends WorkPackageButtonControll
}
public get filterCount():number {
return _.size(_.where(this.filters, (filter:any) => !filter.deactivated));
return _.size(_.filter(this.filters, (filter:any) => !filter.deactivated));
}
public isActive():boolean {

@ -29,6 +29,7 @@
import {EditField} from '../wp-edit-field/wp-edit-field.module';
import {WorkPackageResourceInterface} from '../../api/api-v3/hal-resources/work-package-resource.service';
import {CollectionResource} from '../../api/api-v3/hal-resources/collection-resource.service';
import {HalResource} from '../../api/api-v3/hal-resources/hal-resource.service';
export class SelectEditField extends EditField {
public options:any[];
@ -78,7 +79,7 @@ export class SelectEditField extends EditField {
private checkCurrentValueValidity() {
this.currentValueInvalid = !!(
(this.value && !_.some(this.options, (option) => (option.href === this.value.href)))
(this.value && !_.some(this.options, (option:HalResource) => (option.href === this.value.href)))
||
(!this.value && this.schema.required)
);

@ -67,7 +67,7 @@ export class GroupedRowsBuilder extends RowsBuilder {
* The API sadly doesn't provide us with the information which group a WP belongs to.
*/
private matchingGroup(workPackage:WorkPackageResource, groups:GroupObject[], groupBy:string) {
return _.find(groups, (group) => {
return _.find(groups, (group:GroupObject) => {
// If its a linked resource, compare the href.
if (group.href) {
return workPackage.$source._links[groupBy].href === group.href;
@ -76,7 +76,7 @@ export class GroupedRowsBuilder extends RowsBuilder {
// Otherwise, fall back to simple value comparison.
let value = group.value === '' ? null : group.value;
return value === workPackage[groupBy];
});
}) as GroupObject;
}
/**

@ -28,7 +28,7 @@ export class WorkPackageTableColumnsService {
}
return this.currentState.map(name => {
return _.find(available as any[], (column) => column.name === name);
return _.find(available as any[], (column:api.ex.Column) => column.name === name);
});
}

@ -19,7 +19,7 @@ export class WorkPackageTableMetadataService {
* of groupable columns.
*/
public isGroupable(name:string):boolean {
return !!_.find(this.current.groupableColumns, (column) => column.name === name);
return !!_.find(this.current.groupableColumns, (column:api.ex.Column) => column.name === name);
}
public showSums():boolean {

@ -11,7 +11,7 @@ export interface WorkPackageTableRow {
workPackageId:string;
position:number;
element?:HTMLElement;
group?:GroupObject;
group:GroupObject|null;
}
export interface GroupableColumn {

@ -31,6 +31,7 @@ import {WorkPackageCacheService} from '../../work-packages/work-package-cache.se
import {WorkPackageNotificationService} from '../../wp-edit/wp-notification.service';
import {CollectionResource} from '../../api/api-v3/hal-resources/collection-resource.service';
import {LoadingIndicatorService} from '../../common/loading-indicator/loading-indicator.service';
import {HalResource} from '../../api/api-v3/hal-resources/hal-resource.service';
export class WatchersPanelController {
@ -170,7 +171,7 @@ export class WatchersPanelController {
public removeWatcher(watcher:any) {
this.workPackage.removeWatcher.$link.$prepare({ user_id: watcher.id })()
.then(() => {
_.remove(this.watching, (other) => { return other.href === watcher.href; });
_.remove(this.watching, (other:HalResource) => { return other.href === watcher.href; });
// Forcefully reload the resource to update the watch/unwatch links
// should the current user have been removed

@ -59,7 +59,7 @@ class WpRelationRowDirectiveController {
this.userInputs.newRelationText = this.relation.description || '';
this.availableRelationTypes = wpRelationsService.getRelationTypes(true);
this.selectedRelationType = _.find(this.availableRelationTypes, {'name': this.relation.type});
this.selectedRelationType = _.find(this.availableRelationTypes, {'name': this.relation.type}) as RelationResourceInterface;
};
/**

@ -59,7 +59,7 @@ function WorkPackageContextMenuHelper(
function getIntersectOfPermittedActions(workPackages:any) {
var bulkPermittedActions:any = [];
var permittedActions = _.filter(PERMITTED_BULK_ACTIONS, function(action) {
var permittedActions = _.filter(PERMITTED_BULK_ACTIONS, function(action:any) {
return _.every(workPackages, function(workPackage:WorkPackageResource) {
return getAllowedActions(workPackage, [action]).length >= 1;
});

@ -30,7 +30,6 @@ import {wpDirectivesModule} from "../../angular-modules";
import {scopedObservable, runInScopeDigest} from "../../helpers/angular-rx-utils";
import IScope = angular.IScope;
import IRootElementService = angular.IRootElementService;
import IAnimateProvider = angular.animate.IAnimateProvider;
import ITranscludeFunction = angular.ITranscludeFunction;
import {ReplaySubject, Subject} from "rxjs";

@ -1,4 +1,3 @@
/// <reference path="../typings/index.d.ts" />
/// <reference path="../tests/typings/tests.d.ts" />

@ -0,0 +1,20 @@
// Declare some globals
// to work around previously magical global constants
// provided by typings@global
// Active issue
// https://github.com/Microsoft/TypeScript/issues/10178
import * as TLodash from 'lodash';
import * as TAngular from 'angular';
import * as TSinon from 'sinon';
import * as TMoment from 'moment';
declare global {
const _:typeof TLodash;
const angular:typeof TAngular;
const sinon:typeof TSinon;
const moment:typeof TMoment;
}
export {};

@ -75,8 +75,7 @@ module.exports = function (config) {
// preprocess matching files before serving them to the browser
// available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor
preprocessors: {
'/templates/**/*.html': ['ng-html2js'],
'../app/assets/javascripts/*.js': ['coverage']
'/templates/**/*.html': ['ng-html2js']
},
ngHtml2JsPreprocessor: {
module: 'openproject.templates'
@ -85,7 +84,7 @@ module.exports = function (config) {
// test results reporter to use
// possible values: 'dots', 'progress'
// available reporters: https://npmjs.org/browse/keyword/karma-reporter
reporters: ['progress', 'coverage', 'junit'],
reporters: ['progress'],
// web server port
@ -112,18 +111,6 @@ module.exports = function (config) {
// Continuous Integration mode
// if true, Karma captures browsers, runs the tests and exits
singleRun: true,
junitReporter: {
outputFile: 'tests/unit/reports/test-results.xml'
},
coverageReporter: {
reporters: [
{type: 'html', dir: 'coverage/'},
{type: 'cobertura'}
]
}
singleRun: true
});
};

File diff suppressed because it is too large Load Diff

@ -14,14 +14,11 @@
"karma-chai-as-promised": "^0.1.2",
"karma-chai-sinon": "~0.1.3",
"karma-chrome-launcher": "~0.1.3",
"karma-coverage": "^0.2.3",
"karma-firefox-launcher": "~0.1.3",
"karma-junit-reporter": "~0.2.2",
"karma-mocha": "^1.3.0",
"karma-ng-html2js-preprocessor": "^0.1.2",
"karma-phantomjs-launcher": "~1.0.2",
"mocha": "~1.18.2",
"mocha-jenkins-reporter": "^0.1.2",
"mocha": "^3.2.0",
"phantomjs-prebuilt": "~2.1.7",
"sinon": "^1.17.5",
"sinon-chai": "^2.8.0",
@ -29,19 +26,39 @@
"webpack-dev-server": "^1.6.5"
},
"dependencies": {
"@types/angular": "^1.6.5",
"@types/angular-mocks": "^1.5.9",
"@types/angular-ui-router": "^1.1.36",
"@types/assertion-error": "^1.0.30",
"@types/chai": "^3.4.34",
"@types/chai-as-promised": "0.0.29",
"@types/es6-shim": "^0.31.32",
"@types/jquery": "^2.0.40",
"@types/jqueryui": "^1.11.32",
"@types/lodash": "https://registry.npmjs.org/@types/lodash/-/lodash-4.14.52.tgz",
"@types/mocha": "^2.2.39",
"@types/mousetrap": "^1.5.33",
"@types/ng-dialog": "^0.6.0",
"@types/nouislider": "^9.0.0",
"@types/promises-a-plus": "0.0.27",
"@types/rosie": "0.0.30",
"@types/sinon": "^1.16.35",
"@types/sinon-chai": "^2.7.27",
"@types/urijs": "^1.15.31",
"@types/webpack-env": "^1.13.0",
"URIjs": "^1.14.1",
"amdefine": "^1.0.0",
"angular": "~1.5.9",
"angular-animate": "~1.5.9",
"angular-aria": "~1.5.9",
"angular-cache": "~4.6.0",
"angular-context-menu": "github:opf/angular-context-menu#a908eccaec323cd66973d58af4965694bdff16a1",
"angular-context-menu": "opf/angular-context-menu#a908eccaec323cd66973d58af4965694bdff16a1",
"angular-dragula": "~1.2.8",
"angular-elastic": "2.5.0",
"angular-i18n": "~1.3.0",
"angular-modal": "github:finnlabs/angular-modal#d45eb9ceb720b8785613ba89ba0f14f8ab197569",
"angular-modal": "finnlabs/angular-modal#d45eb9ceb720b8785613ba89ba0f14f8ab197569",
"angular-sanitize": "~1.3.14",
"angular-truncate": "github:sparkalow/angular-truncate#fdf60fda265042d12e9414b5354b2cc52f1419de",
"angular-truncate": "sparkalow/angular-truncate#fdf60fda265042d12e9414b5354b2cc52f1419de",
"angular-ui-bootstrap": "^2.2.0",
"angular-ui-router": "~0.3.1",
"atoa": "^1.0.0",
@ -67,9 +84,9 @@
"jquery.caret": "^0.3.1",
"json5": "^0.5.0",
"karma": "^1.4.1",
"lodash": "^2.4.2",
"moment": "~2.10.6",
"moment-timezone": "0.4.x",
"lodash": "^4.17.4",
"moment": "^2.17.1",
"moment-timezone": "^0.5.11",
"mousetrap": "~1.6.0",
"ng-annotate-loader": "^0.2.0",
"ng-dialog": "^0.6.4",
@ -84,7 +101,7 @@
"style-loader": "^0.8.2",
"ticky": "^1.0.1",
"ts-loader": "^2.0.0",
"typescript": "2.1.1",
"typescript": "^2.1.6",
"ui-select": "~0.19.6",
"url-loader": "^0.5.7",
"webpack": "^2.2.0"

@ -15,5 +15,8 @@
"strictNullChecks": true,
"skipLibCheck": true
},
"compileOnSave": false
"compileOnSave": false,
"exclude": [
"node_modules"
]
}

@ -10,7 +10,6 @@
},
"files": [
"app/components/**/*.test.ts",
"app/typings/open-project.typings.ts",
"typings/tsd.d.ts"
"app/typings/*"
]
}

@ -1,29 +0,0 @@
{
"name": "openproject-frontend",
"globalDependencies": {
"angular": "registry:dt/angular#1.5.0+20161101124950",
"angular-animate": "registry:dt/angular-animate#1.5.0+20160709061515",
"angular-mocks": "github:DefinitelyTyped/DefinitelyTyped/angularjs/angular-mocks.d.ts#40c60850ad6c8175a62d5ab48c4e016ea5b3dffe",
"angular-ui-router": "github:DefinitelyTyped/DefinitelyTyped/angular-ui-router/angular-ui-router.d.ts#78ba6e41543e5ababbd1dda19797601be3c1f304",
"assertion-error": "github:DefinitelyTyped/DefinitelyTyped/assertion-error/assertion-error.d.ts#86bb15f6b9a3515bd9b3ca61f2a670533ac6b908",
"chai": "github:DefinitelyTyped/DefinitelyTyped/chai/chai.d.ts#86bb15f6b9a3515bd9b3ca61f2a670533ac6b908",
"chai-as-promised": "github:DefinitelyTyped/DefinitelyTyped/chai-as-promised/chai-as-promised.d.ts#86bb15f6b9a3515bd9b3ca61f2a670533ac6b908",
"dom4": "registry:dt/dom4#1.5.0+20160831020816",
"es6-shim": "registry:dt/es6-shim#0.31.2+20160726072212",
"jquery": "github:DefinitelyTyped/DefinitelyTyped/jquery/jquery.d.ts#4ec3c5bf291bc02f49eb30c1077340b235165c67",
"jqueryui": "registry:dt/jqueryui#1.11.0+20161214061125",
"lodash": "github:DefinitelyTyped/DefinitelyTyped/lodash/lodash.d.ts#627b6c158b73494c803f36fc2fe00ad75faa8fde",
"mocha": "github:DefinitelyTyped/DefinitelyTyped/mocha/mocha.d.ts#86bb15f6b9a3515bd9b3ca61f2a670533ac6b908",
"moment": "github:DefinitelyTyped/DefinitelyTyped/moment/moment.d.ts#bcd5761826eb567876c197ccc6a87c4d05731054",
"moment-node": "github:DefinitelyTyped/DefinitelyTyped/moment/moment-node.d.ts#bcd5761826eb567876c197ccc6a87c4d05731054",
"mousetrap": "registry:dt/mousetrap#1.5.0+20160725212620",
"ng-dialog": "registry:dt/ng-dialog#0.0.0+20160423145208",
"nouislider": "registry:dt/nouislider#8.0.2+20160412140110",
"promises-a-plus": "github:DefinitelyTyped/DefinitelyTyped/promises-a-plus/promises-a-plus.d.ts#86bb15f6b9a3515bd9b3ca61f2a670533ac6b908",
"rosie": "registry:dt/rosie#0.0.0+20160317120654",
"sinon": "github:DefinitelyTyped/DefinitelyTyped/sinon/sinon.d.ts#40c60850ad6c8175a62d5ab48c4e016ea5b3dffe",
"sinon-chai": "registry:dt/sinon-chai#2.7.0+20160317120654",
"urijs": "registry:dt/urijs#1.15.1+20160526132152",
"webpack-env": "github:DefinitelyTyped/DefinitelyTyped/webpack/webpack-env.d.ts#86bb15f6b9a3515bd9b3ca61f2a670533ac6b908"
}
}

@ -1,305 +0,0 @@
// Generated by typings
// Source: https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/d9e7db3b1068ec56a929624ee25f977fa38f68b7/angularjs/angular-animate.d.ts
declare module "angular-animate" {
var _: string;
export = _;
}
/**
* ngAnimate module (angular-animate.js)
*/
declare namespace angular.animate {
interface IAnimateFactory {
(...args: any[]): IAnimateCallbackObject;
}
interface IAnimateCallbackObject {
eventFn?: (element: JQuery, doneFunction: Function, options: IAnimationOptions) => any;
setClass?: (element: JQuery, addedClasses: string, removedClasses: string, doneFunction: Function, options: IAnimationOptions) => any;
addClass?: (element: JQuery, addedClasses: string, doneFunction: Function, options: IAnimationOptions) => any;
removeClass?: (element: JQuery, removedClasses: string, doneFunction: Function, options: IAnimationOptions) => any;
enter?: (element: JQuery, doneFunction: Function, options: IAnimationOptions) => any;
leave?: (element: JQuery, doneFunction: Function, options: IAnimationOptions) => any;
move?: (element: JQuery, doneFunction: Function, options: IAnimationOptions) => any;
animate?: (element: JQuery, fromStyles: string, toStyles: string, doneFunction: Function, options: IAnimationOptions) => any;
}
interface IAnimationPromise extends IPromise<void> {}
/**
* AnimateService
* see http://docs.angularjs.org/api/ngAnimate/service/$animate
*/
interface IAnimateService {
/**
* Sets up an event listener to fire whenever the animation event has fired on the given element or among any of its children.
*
* @param event the animation event that will be captured (e.g. enter, leave, move, addClass, removeClass, etc...)
* @param container the container element that will capture each of the animation events that are fired on itself as well as among its children
* @param callback the callback function that will be fired when the listener is triggered
*/
on(event: string, container: JQuery, callback: (element?: JQuery, phase?: string) => any): void;
/**
* Deregisters an event listener based on the event which has been associated with the provided element.
*
* @param event the animation event (e.g. enter, leave, move, addClass, removeClass, etc...)
* @param container the container element the event listener was placed on
* @param callback the callback function that was registered as the listener
*/
off(event: string, container?: JQuery, callback?: (element?: JQuery, phase?: string) => any): void;
/**
* Associates the provided element with a host parent element to allow the element to be animated even if it exists outside of the DOM structure of the Angular application.
*
* @param element the external element that will be pinned
* @param parentElement the host parent element that will be associated with the external element
*/
pin(element: JQuery, parentElement: JQuery): void;
/**
* Globally enables / disables animations.
*
* @param element If provided then the element will be used to represent the enable/disable operation.
* @param value If provided then set the animation on or off.
* @returns current animation state
*/
enabled(value?: boolean): boolean;
enabled(element: JQuery, value?: boolean): boolean;
/**
* Cancels the provided animation.
*/
cancel(animationPromise: IAnimationPromise): void;
/**
* Performs an inline animation on the element.
*
* @param element the element that will be the focus of the animation
* @param from a collection of CSS styles that will be applied to the element at the start of the animation
* @param to a collection of CSS styles that the element will animate towards
* @param className an optional CSS class that will be added to the element for the duration of the animation (the default class is 'ng-inline-animate')
* @param options an optional collection of styles that will be picked up by the CSS transition/animation
* @returns the animation callback promise
*/
animate(element: JQuery, from: any, to: any, className?: string, options?: IAnimationOptions): IAnimationPromise;
/**
* Appends the element to the parentElement element that resides in the document and then runs the enter animation.
*
* @param element the element that will be the focus of the enter animation
* @param parentElement the parent element of the element that will be the focus of the enter animation
* @param afterElement the sibling element (which is the previous element) of the element that will be the focus of the enter animation
* @param options an optional collection of styles that will be picked up by the CSS transition/animation
* @returns the animation callback promise
*/
enter(element: JQuery, parentElement: JQuery, afterElement?: JQuery, options?: IAnimationOptions): IAnimationPromise;
/**
* Runs the leave animation operation and, upon completion, removes the element from the DOM.
*
* @param element the element that will be the focus of the leave animation
* @param options an optional collection of styles that will be picked up by the CSS transition/animation
* @returns the animation callback promise
*/
leave(element: JQuery, options?: IAnimationOptions): IAnimationPromise;
/**
* Fires the move DOM operation. Just before the animation starts, the animate service will either append
* it into the parentElement container or add the element directly after the afterElement element if present.
* Then the move animation will be run.
*
* @param element the element that will be the focus of the move animation
* @param parentElement the parent element of the element that will be the focus of the move animation
* @param afterElement the sibling element (which is the previous element) of the element that will be the focus of the move animation
* @returns the animation callback promise
*/
move(element: JQuery, parentElement: JQuery, afterElement?: JQuery): IAnimationPromise;
/**
* Triggers a custom animation event based off the className variable and then attaches the className
* value to the element as a CSS class.
*
* @param element the element that will be animated
* @param className the CSS class that will be added to the element and then animated
* @param options an optional collection of styles that will be picked up by the CSS transition/animation
* @returns the animation callback promise
*/
addClass(element: JQuery, className: string, options?: IAnimationOptions): IAnimationPromise;
/**
* Triggers a custom animation event based off the className variable and then removes the CSS class
* provided by the className value from the element.
*
* @param element the element that will be animated
* @param className the CSS class that will be animated and then removed from the element
* @param options an optional collection of styles that will be picked up by the CSS transition/animation
* @returns the animation callback promise
*/
removeClass(element: JQuery, className: string, options?: IAnimationOptions): IAnimationPromise;
/**
* Adds and/or removes the given CSS classes to and from the element. Once complete, the done() callback
* will be fired (if provided).
*
* @param element the element which will have its CSS classes changed removed from it
* @param add the CSS classes which will be added to the element
* @param remove the CSS class which will be removed from the element CSS classes have been set on the element
* @param options an optional collection of styles that will be picked up by the CSS transition/animation
* @returns the animation callback promise
*/
setClass(element: JQuery, add: string, remove: string, options?: IAnimationOptions): IAnimationPromise;
}
/**
* AnimateProvider
* see http://docs.angularjs.org/api/ngAnimate/provider/$animateProvider
*/
interface IAnimateProvider {
/**
* Registers a new injectable animation factory function.
*
* @param name The name of the animation.
* @param factory The factory function that will be executed to return the animation object.
*/
register(name: string, factory: IAnimateFactory): void;
/**
* Gets and/or sets the CSS class expression that is checked when performing an animation.
*
* @param expression The className expression which will be checked against all animations.
* @returns The current CSS className expression value. If null then there is no expression value.
*/
classNameFilter(expression?: RegExp): RegExp;
}
/**
* Angular Animation Options
* see https://docs.angularjs.org/api/ngAnimate/#applying-directive-specific-styles-to-an-animation
*/
interface IAnimationOptions {
/**
* The DOM event (e.g. enter, leave, move). When used, a generated CSS class of ng-EVENT and
* ng-EVENT-active will be applied to the element during the animation. Multiple events can be provided when
* spaces are used as a separator. (Note that this will not perform any DOM operation.)
*/
event?: string;
/**
* Indicates that the ng-prefix will be added to the event class. Setting to false or
* omitting will turn ng-EVENT and ng-EVENT-active in EVENT and EVENT-active. Unused if event is omitted.
*/
structural?: boolean;
/**
* The CSS easing value that will be applied to the transition or keyframe animation (or both).
*/
easing?: string;
/**
* The raw CSS transition style that will be used (e.g. 1s linear all).
*/
transitionStyle?: string;
/**
* The raw CSS keyframe animation style that will be used (e.g. 1s my_animation linear).
*/
keyframeStyle?: string;
/**
* The starting CSS styles (a key/value object) that will be applied at the start of the animation.
*/
from?: Object;
/**
* The ending CSS styles (a key/value object) that will be applied across the animation via a CSS transition.
*/
to?: Object;
/**
* A space separated list of CSS classes that will be added to the element and spread across the animation.
*/
addClass?: string;
/**
* A space separated list of CSS classes that will be removed from the element and spread across
* the animation.
*/
removeClass?: string;
/**
* A number value representing the total duration of the transition and/or keyframe (note that a value
* of 1 is 1000ms). If a value of 0 is provided then the animation will be skipped entirely.
*/
duration?: number;
/**
* A number value representing the total delay of the transition and/or keyframe (note that a value of
* 1 is 1000ms). If a value of true is used then whatever delay value is detected from the CSS classes will be
* mirrored on the elements styles (e.g. by setting delay true then the style value of the element will be
* transition-delay: DETECTED_VALUE). Using true is useful when you want the CSS classes and inline styles to
* all share the same CSS delay value.
*/
delay?: number;
/**
* A numeric time value representing the delay between successively animated elements (Click here to
* learn how CSS-based staggering works in ngAnimate.)
*/
stagger?: number;
/**
* The numeric index representing the stagger item (e.g. a value of 5 is equal to the sixth item
* in the stagger; therefore when a stagger option value of 0.1 is used then there will be a stagger delay of 600ms)
*
*/
staggerIndex?: number;
/**
* Whether or not the provided from and to styles will be removed once the animation is closed. This is useful for
* when the styles are used purely for the sake of the animation and do not have a lasting visual effect on the element
* (e.g. a colapse and open animation). By default this value is set to false.
*/
cleanupStyles?: boolean;
}
interface IAnimateCssRunner {
/**
* Starts the animation
*
* @returns The animation runner with a done function for supplying a callback.
*/
start(): IAnimateCssRunnerStart;
/**
* Ends (aborts) the animation
*/
end(): void;
}
interface IAnimateCssRunnerStart extends IPromise<void> {
/**
* Allows you to add done callbacks to the running animation
*
* @param callbackFn: the callback function to be run
*/
done(callbackFn: (animationFinished: boolean) => void): void;
}
/**
* AnimateCssService
* see http://docs.angularjs.org/api/ngAnimate/service/$animateCss
*/
interface IAnimateCssService {
(element: JQuery, animateCssOptions: IAnimationOptions): IAnimateCssRunner;
}
}
declare module angular {
interface IModule {
animation(name: string, animationFactory: angular.animate.IAnimateFactory): IModule;
animation(name: string, inlineAnnotatedFunction: any[]): IModule;
animation(object: Object): IModule;
}
}

@ -1,8 +0,0 @@
{
"resolution": "main",
"tree": {
"src": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/d9e7db3b1068ec56a929624ee25f977fa38f68b7/angularjs/angular-animate.d.ts",
"raw": "registry:dt/angular-animate#1.5.0+20160709061515",
"typings": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/d9e7db3b1068ec56a929624ee25f977fa38f68b7/angularjs/angular-animate.d.ts"
}
}

@ -1,313 +0,0 @@
// Generated by typings
// Source: https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/40c60850ad6c8175a62d5ab48c4e016ea5b3dffe/angularjs/angular-mocks.d.ts
declare module "angular-mocks/ngMock" {
var _: string;
export = _;
}
declare module "angular-mocks/ngMockE2E" {
var _: string;
export = _;
}
declare module "angular-mocks/ngAnimateMock" {
var _: string;
export = _;
}
///////////////////////////////////////////////////////////////////////////////
// ngMock module (angular-mocks.js)
///////////////////////////////////////////////////////////////////////////////
declare module angular {
///////////////////////////////////////////////////////////////////////////
// AngularStatic
// We reopen it to add the MockStatic definition
///////////////////////////////////////////////////////////////////////////
interface IAngularStatic {
mock: IMockStatic;
}
// see https://docs.angularjs.org/api/ngMock/function/angular.mock.inject
interface IInjectStatic {
(...fns: Function[]): any;
(...inlineAnnotatedConstructor: any[]): any; // this overload is undocumented, but works
strictDi(val?: boolean): void;
}
interface IMockStatic {
// see https://docs.angularjs.org/api/ngMock/function/angular.mock.dump
dump(obj: any): string;
inject: IInjectStatic
// see https://docs.angularjs.org/api/ngMock/function/angular.mock.module
module(...modules: any[]): any;
// see https://docs.angularjs.org/api/ngMock/type/angular.mock.TzDate
TzDate(offset: number, timestamp: number): Date;
TzDate(offset: number, timestamp: string): Date;
}
///////////////////////////////////////////////////////////////////////////
// ExceptionHandlerService
// see https://docs.angularjs.org/api/ngMock/service/$exceptionHandler
// see https://docs.angularjs.org/api/ngMock/provider/$exceptionHandlerProvider
///////////////////////////////////////////////////////////////////////////
interface IExceptionHandlerProvider extends IServiceProvider {
mode(mode: string): void;
}
///////////////////////////////////////////////////////////////////////////
// TimeoutService
// see https://docs.angularjs.org/api/ngMock/service/$timeout
// Augments the original service
///////////////////////////////////////////////////////////////////////////
interface ITimeoutService {
flush(delay?: number): void;
flushNext(expectedDelay?: number): void;
verifyNoPendingTasks(): void;
}
///////////////////////////////////////////////////////////////////////////
// IntervalService
// see https://docs.angularjs.org/api/ngMock/service/$interval
// Augments the original service
///////////////////////////////////////////////////////////////////////////
interface IIntervalService {
flush(millis?: number): number;
}
///////////////////////////////////////////////////////////////////////////
// LogService
// see https://docs.angularjs.org/api/ngMock/service/$log
// Augments the original service
///////////////////////////////////////////////////////////////////////////
interface ILogService {
assertEmpty(): void;
reset(): void;
}
interface ILogCall {
logs: string[];
}
///////////////////////////////////////////////////////////////////////////
// HttpBackendService
// see https://docs.angularjs.org/api/ngMock/service/$httpBackend
///////////////////////////////////////////////////////////////////////////
interface IHttpBackendService {
/**
* Flushes all pending requests using the trained responses.
* @param count Number of responses to flush (in the order they arrived). If undefined, all pending requests will be flushed.
*/
flush(count?: number): void;
/**
* Resets all request expectations, but preserves all backend definitions.
*/
resetExpectations(): void;
/**
* Verifies that all of the requests defined via the expect api were made. If any of the requests were not made, verifyNoOutstandingExpectation throws an exception.
*/
verifyNoOutstandingExpectation(): void;
/**
* Verifies that there are no outstanding requests that need to be flushed.
*/
verifyNoOutstandingRequest(): void;
/**
* Creates a new request expectation.
* Throws a preformatted error if expectation(s) don't match supplied string, regular expression, object, or if function returns false.
* Returns an object with respond method that controls how a matched request is handled.
* @param method HTTP method.
* @param url HTTP url string, regular expression or function that receives a url and returns true if the url matches the current expctation.
* @param data HTTP request body string, json object, regular expression or function that receives the data and returns true if the data matches the current expectation.
* @param headers HTTP headers object or function that receives the headers and returns true if the headers match the current expectation.
*/
expect(method: string, url: string | RegExp | ((url: string) => boolean), data?: string | RegExp | Object | ((data: string) => boolean), headers?: Object | ((object: Object) => boolean)) :mock.IRequestHandler;
/**
* Creates a new request expectation for DELETE requests.
* Throws a preformatted error if expectation(s) don't match supplied string, regular expression, object, or if function returns false.
* Returns an object with respond method that controls how a matched request is handled.
* @param url HTTP url string, regular expression or function that receives a url and returns true if the url is as expected.
* @param headers HTTP headers object to be compared with the HTTP headers in the request.
*/
expectDELETE(url: string | RegExp | ((url: string) => boolean), headers?: Object): mock.IRequestHandler;
/**
* Creates a new request expectation for GET requests.
* Throws a preformatted error if expectation(s) don't match supplied string, regular expression, object, or if function returns false.
* Returns an object with respond method that controls how a matched request is handled.
* @param url HTTP url string, regular expression or function that receives a url and returns true if the url matches the current expctation.
* @param headers HTTP headers object to be compared with the HTTP headers in the request.
*/
expectGET(url: string | RegExp | ((url: string) => boolean), headers?: Object): mock.IRequestHandler;
/**
* Creates a new request expectation for HEAD requests.
* Throws a preformatted error if expectation(s) don't match supplied string, regular expression, object, or if function returns false.
* Returns an object with respond method that controls how a matched request is handled.
* @param url HTTP url string, regular expression or function that receives a url and returns true if the url matches the current expctation.
* @param headers HTTP headers object to be compared with the HTTP headers in the request.
*/
expectHEAD(url: string | RegExp | ((url: string) => boolean), headers?: Object): mock.IRequestHandler;
/**
* Creates a new request expectation for JSONP requests.
* Throws a preformatted error if expectation(s) don't match supplied string, regular expression, or if function returns false.
* Returns an object with respond method that controls how a matched request is handled.
* @param url HTTP url string, regular expression or function that receives a url and returns true if the url matches the current expctation.
*/
expectJSONP(url: string | RegExp | ((url: string) => boolean)): mock.IRequestHandler;
/**
* Creates a new request expectation for PATCH requests.
* Throws a preformatted error if expectation(s) don't match supplied string, regular expression, object, or if function returns false.
* Returns an object with respond method that controls how a matched request is handled.
* @param url HTTP url string, regular expression or function that receives a url and returns true if the url matches the current expctation.
* @param data HTTP request body string, json object, regular expression or function that receives the data and returns true if the data matches the current expectation.
* @param headers HTTP headers object or function that receives the headers and returns true if the headers match the current expectation.
*/
expectPATCH(url: string | RegExp | ((url: string) => boolean), data?: string | RegExp | Object | ((data: string) => boolean), headers?: Object): mock.IRequestHandler;
/**
* Creates a new request expectation for POST requests.
* Throws a preformatted error if expectation(s) don't match supplied string, regular expression, object, or if function returns false.
* Returns an object with respond method that controls how a matched request is handled.
* @param url HTTP url string, regular expression or function that receives a url and returns true if the url matches the current expctation.
* @param data HTTP request body string, json object, regular expression or function that receives the data and returns true if the data matches the current expectation.
* @param headers HTTP headers object or function that receives the headers and returns true if the headers match the current expectation.
*/
expectPOST(url: string | RegExp | ((url: string) => boolean), data?: string | RegExp | Object | ((data: string) => boolean), headers?: Object): mock.IRequestHandler;
/**
* Creates a new request expectation for PUT requests.
* Throws a preformatted error if expectation(s) don't match supplied string, regular expression, object, or if function returns false.
* Returns an object with respond method that controls how a matched request is handled.
* @param url HTTP url string, regular expression or function that receives a url and returns true if the url matches the current expctation.
* @param data HTTP request body string, json object, regular expression or function that receives the data and returns true if the data matches the current expectation.
* @param headers HTTP headers object or function that receives the headers and returns true if the headers match the current expectation.
*/
expectPUT(url: string | RegExp | ((url: string) => boolean), data?: string | RegExp | Object | ((data: string) => boolean), headers?: Object): mock.IRequestHandler;
/**
* Creates a new backend definition.
* Returns an object with respond method that controls how a matched request is handled.
* @param method HTTP method.
* @param url HTTP url string, regular expression or function that receives a url and returns true if the url matches the current expctation.
* @param data HTTP request body string, json object, regular expression or function that receives the data and returns true if the data matches the current expectation.
* @param headers HTTP headers object or function that receives the headers and returns true if the headers match the current expectation.
*/
when(method: string, url: string | RegExp | ((url: string) => boolean), data?: string | RegExp | Object | ((data: string) => boolean), headers?: Object | ((object: Object) => boolean)): mock.IRequestHandler;
/**
* Creates a new backend definition for DELETE requests.
* Returns an object with respond method that controls how a matched request is handled.
* @param url HTTP url string, regular expression or function that receives a url and returns true if the url matches the current expctation.
* @param headers HTTP headers object or function that receives the headers and returns true if the headers match the current expectation.
*/
whenDELETE(url: string | RegExp | ((url: string) => boolean), headers?: Object | ((object: Object) => boolean)): mock.IRequestHandler;
/**
* Creates a new backend definition for GET requests.
* Returns an object with respond method that controls how a matched request is handled.
* @param url HTTP url string, regular expression or function that receives a url and returns true if the url matches the current expctation.
* @param headers HTTP headers object or function that receives the headers and returns true if the headers match the current expectation.
*/
whenGET(url: string | RegExp | ((url: string) => boolean), headers?: Object | ((object: Object) => boolean)): mock.IRequestHandler;
/**
* Creates a new backend definition for HEAD requests.
* Returns an object with respond method that controls how a matched request is handled.
* @param url HTTP url string, regular expression or function that receives a url and returns true if the url matches the current expctation.
* @param headers HTTP headers object or function that receives the headers and returns true if the headers match the current expectation.
*/
whenHEAD(url: string | RegExp | ((url: string) => boolean), headers?: Object | ((object: Object) => boolean)): mock.IRequestHandler;
/**
* Creates a new backend definition for JSONP requests.
* Returns an object with respond method that controls how a matched request is handled.
* @param url HTTP url string, regular expression or function that receives a url and returns true if the url matches the current expctation.
* @param headers HTTP headers object or function that receives the headers and returns true if the headers match the current expectation.
*/
whenJSONP(url: string | RegExp | ((url: string) => boolean)): mock.IRequestHandler;
/**
* Creates a new backend definition for PATCH requests.
* Returns an object with respond method that controls how a matched request is handled.
* @param url HTTP url string, regular expression or function that receives a url and returns true if the url matches the current expctation.
* @param data HTTP request body string, json object, regular expression or function that receives the data and returns true if the data matches the current expectation.
* @param headers HTTP headers object or function that receives the headers and returns true if the headers match the current expectation.
*/
whenPATCH(url: string | RegExp | ((url: string) => boolean), data?: string | RegExp | Object | ((data: string) => boolean), headers?: Object | ((object: Object) => boolean)): mock.IRequestHandler;
/**
* Creates a new backend definition for POST requests.
* Returns an object with respond method that controls how a matched request is handled.
* @param url HTTP url string, regular expression or function that receives a url and returns true if the url matches the current expctation.
* @param data HTTP request body string, json object, regular expression or function that receives the data and returns true if the data matches the current expectation.
* @param headers HTTP headers object or function that receives the headers and returns true if the headers match the current expectation.
*/
whenPOST(url: string | RegExp | ((url: string) => boolean), data?: string | RegExp | Object | ((data: string) => boolean), headers?: Object | ((object: Object) => boolean)): mock.IRequestHandler;
/**
* Creates a new backend definition for PUT requests.
* Returns an object with respond method that controls how a matched request is handled.
* @param url HTTP url string, regular expression or function that receives a url and returns true if the url matches the current expctation.
* @param data HTTP request body string, json object, regular expression or function that receives the data and returns true if the data matches the current expectation.
* @param headers HTTP headers object or function that receives the headers and returns true if the headers match the current expectation.
*/
whenPUT(url: string | RegExp | ((url: string) => boolean), data?: string | RegExp | Object | ((data: string) => boolean), headers?: Object | ((object: Object) => boolean)): mock.IRequestHandler;
}
export module mock {
// returned interface by the the mocked HttpBackendService expect/when methods
interface IRequestHandler {
/**
* Controls the response for a matched request using a function to construct the response.
* Returns the RequestHandler object for possible overrides.
* @param func Function that receives the request HTTP method, url, data, and headers and returns an array containing response status (number), data, headers, and status text.
*/
respond(func: ((method: string, url: string, data: string | Object, headers: Object) => [number, string | Object, Object, string])): IRequestHandler;
/**
* Controls the response for a matched request using supplied static data to construct the response.
* Returns the RequestHandler object for possible overrides.
* @param status HTTP status code to add to the response.
* @param data Data to add to the response.
* @param headers Headers object to add to the response.
* @param responseText Response text to add to the response.
*/
respond(status: number, data: string | Object, headers?: Object, responseText?: string): IRequestHandler;
/**
* Controls the response for a matched request using the HTTP status code 200 and supplied static data to construct the response.
* Returns the RequestHandler object for possible overrides.
* @param data Data to add to the response.
* @param headers Headers object to add to the response.
* @param responseText Response text to add to the response.
*/
respond(data: string | Object, headers?: Object, responseText?: string): IRequestHandler;
// Available when ngMockE2E is loaded
/**
* Any request matching a backend definition or expectation with passThrough handler will be passed through to the real backend (an XHR request will be made to the server.)
*/
passThrough(): IRequestHandler;
}
}
}
///////////////////////////////////////////////////////////////////////////////
// functions attached to global object (window)
///////////////////////////////////////////////////////////////////////////////
//Use `angular.mock.module` instead of `module`, as `module` conflicts with commonjs.
//declare var module: (...modules: any[]) => any;
declare var inject: angular.IInjectStatic;

@ -1,8 +0,0 @@
{
"resolution": "main",
"tree": {
"src": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/40c60850ad6c8175a62d5ab48c4e016ea5b3dffe/angularjs/angular-mocks.d.ts",
"raw": "github:DefinitelyTyped/DefinitelyTyped/angularjs/angular-mocks.d.ts#40c60850ad6c8175a62d5ab48c4e016ea5b3dffe",
"typings": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/40c60850ad6c8175a62d5ab48c4e016ea5b3dffe/angularjs/angular-mocks.d.ts"
}
}

@ -1,350 +0,0 @@
// Generated by typings
// Source: https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/78ba6e41543e5ababbd1dda19797601be3c1f304/angular-ui-router/angular-ui-router.d.ts
declare module 'angular-ui-router' {
// Since angular-ui-router adds providers for a bunch of
// injectable dependencies, it doesn't really return any
// actual data except the plain string 'ui.router'.
//
// As such, I don't think anybody will ever use the actual
// default value of the module. So I've only included the
// the types. (@xogeny)
export type IState = angular.ui.IState;
export type IStateProvider = angular.ui.IStateProvider;
export type IUrlMatcher = angular.ui.IUrlMatcher;
export type IUrlRouterProvider = angular.ui.IUrlRouterProvider;
export type IStateOptions = angular.ui.IStateOptions;
export type IHrefOptions = angular.ui.IHrefOptions;
export type IStateService = angular.ui.IStateService;
export type IResolvedState = angular.ui.IResolvedState;
export type IStateParamsService = angular.ui.IStateParamsService;
export type IUrlRouterService = angular.ui.IUrlRouterService;
export type IUiViewScrollProvider = angular.ui.IUiViewScrollProvider;
export type IType = angular.ui.IType;
}
declare module angular.ui {
interface IState {
name?: string;
/**
* String HTML content, or function that returns an HTML string
*/
template?: string | {(): string};
/**
* String URL path to template file OR Function, returns URL path string
*/
templateUrl?: string | {(params: IStateParamsService): string};
/**
* Function, returns HTML content string
*/
templateProvider?: Function | Array<string|Function>;
/**
* A controller paired to the state. Function, annotated array or name as String
*/
controller?: Function|string|Array<string|Function>;
controllerAs?: string;
/**
* Function (injectable), returns the actual controller function or string.
*/
controllerProvider?: Function|Array<string|Function>;
/**
* Specifies the parent state of this state
*/
parent?: string | IState;
resolve?: { [name:string]: any };
/**
* A url with optional parameters. When a state is navigated or transitioned to, the $stateParams service will be populated with any parameters that were passed.
*/
url?: string | IUrlMatcher;
/**
* A map which optionally configures parameters declared in the url, or defines additional non-url parameters. Only use this within a state if you are not using url. Otherwise you can specify your parameters within the url. When a state is navigated or transitioned to, the $stateParams service will be populated with any parameters that were passed.
*/
params?: any;
/**
* Use the views property to set up multiple views. If you don't need multiple views within a single state this property is not needed. Tip: remember that often nested views are more useful and powerful than multiple sibling views.
*/
views?: { [name:string]: IState };
abstract?: boolean;
/**
* Callback function for when a state is entered. Good way to trigger an action or dispatch an event, such as opening a dialog.
* If minifying your scripts, make sure to explicitly annotate this function, because it won't be automatically annotated by your build tools.
*/
onEnter?: Function|Array<string|Function>;
/**
* Callback functions for when a state is entered and exited. Good way to trigger an action or dispatch an event, such as opening a dialog.
* If minifying your scripts, make sure to explicitly annotate this function, because it won't be automatically annotated by your build tools.
*/
onExit?: Function|Array<string|Function>;
/**
* Arbitrary data object, useful for custom configuration.
*/
data?: any;
/**
* Boolean (default true). If false will not re-trigger the same state just because a search/query parameter has changed. Useful for when you'd like to modify $location.search() without triggering a reload.
*/
reloadOnSearch?: boolean;
/**
* Boolean (default true). If false will reload state on everytransitions. Useful for when you'd like to restore all data to its initial state.
*/
cache?: boolean;
}
interface IStateProvider extends angular.IServiceProvider {
state(name:string, config:IState): IStateProvider;
state(config:IState): IStateProvider;
decorator(name?: string, decorator?: (state: IState, parent: Function) => any): any;
}
interface IUrlMatcher {
concat(pattern: string): IUrlMatcher;
exec(path: string, searchParams: {}): {};
parameters(): string[];
format(values: {}): string;
}
interface IUrlMatcherFactory {
/**
* Creates a UrlMatcher for the specified pattern.
*
* @param pattern {string} The URL pattern.
*
* @returns {IUrlMatcher} The UrlMatcher.
*/
compile(pattern: string): IUrlMatcher;
/**
* Returns true if the specified object is a UrlMatcher, or false otherwise.
*
* @param o {any} The object to perform the type check against.
*
* @returns {boolean} Returns true if the object matches the IUrlMatcher interface, by implementing all the same methods.
*/
isMatcher(o: any): boolean;
/**
* Returns a type definition for the specified name
*
* @param name {string} The type definition name
*
* @returns {IType} The type definition
*/
type(name: string): IType;
/**
* Registers a custom Type object that can be used to generate URLs with typed parameters.
*
* @param {IType} definition The type definition.
* @param {any[]} inlineAnnotedDefinitionFn A function that is injected before the app runtime starts. The result of this function is merged into the existing definition.
*
* @returns {IUrlMatcherFactory} Returns $urlMatcherFactoryProvider.
*/
type(name: string, definition: IType, inlineAnnotedDefinitionFn?: any[]): IUrlMatcherFactory;
/**
* Registers a custom Type object that can be used to generate URLs with typed parameters.
*
* @param {IType} definition The type definition.
* @param {any[]} inlineAnnotedDefinitionFn A function that is injected before the app runtime starts. The result of this function is merged into the existing definition.
*
* @returns {IUrlMatcherFactory} Returns $urlMatcherFactoryProvider.
*/
type(name: string, definition: IType, definitionFn?: (...args:any[]) => IType): IUrlMatcherFactory;
/**
* Defines whether URL matching should be case sensitive (the default behavior), or not.
*
* @param value {boolean} false to match URL in a case sensitive manner; otherwise true;
*
* @returns {boolean} the current value of caseInsensitive
*/
caseInsensitive(value?: boolean): boolean;
/**
* Sets the default behavior when generating or matching URLs with default parameter values
*
* @param value {string} A string that defines the default parameter URL squashing behavior. nosquash: When generating an href with a default parameter value, do not squash the parameter value from the URL slash: When generating an href with a default parameter value, squash (remove) the parameter value, and, if the parameter is surrounded by slashes, squash (remove) one slash from the URL any other string, e.g. "~": When generating an href with a default parameter value, squash (remove) the parameter value from the URL and replace it with this string.
*/
defaultSquashPolicy(value: string): void;
/**
* Defines whether URLs should match trailing slashes, or not (the default behavior).
*
* @param value {boolean} false to match trailing slashes in URLs, otherwise true.
*
* @returns {boolean} the current value of strictMode
*/
strictMode(value?: boolean): boolean;
}
interface IUrlRouterProvider extends angular.IServiceProvider {
when(whenPath: RegExp, handler: Function): IUrlRouterProvider;
when(whenPath: RegExp, handler: any[]): IUrlRouterProvider;
when(whenPath: RegExp, toPath: string): IUrlRouterProvider;
when(whenPath: IUrlMatcher, hanlder: Function): IUrlRouterProvider;
when(whenPath: IUrlMatcher, handler: any[]): IUrlRouterProvider;
when(whenPath: IUrlMatcher, toPath: string): IUrlRouterProvider;
when(whenPath: string, handler: Function): IUrlRouterProvider;
when(whenPath: string, handler: any[]): IUrlRouterProvider;
when(whenPath: string, toPath: string): IUrlRouterProvider;
otherwise(handler: Function): IUrlRouterProvider;
otherwise(handler: any[]): IUrlRouterProvider;
otherwise(path: string): IUrlRouterProvider;
rule(handler: Function): IUrlRouterProvider;
rule(handler: any[]): IUrlRouterProvider;
/**
* Disables (or enables) deferring location change interception.
*
* If you wish to customize the behavior of syncing the URL (for example, if you wish to defer a transition but maintain the current URL), call this method at configuration time. Then, at run time, call $urlRouter.listen() after you have configured your own $locationChangeSuccess event handler.
*
* @param {boolean} defer Indicates whether to defer location change interception. Passing no parameter is equivalent to true.
*/
deferIntercept(defer?: boolean): void;
}
interface IStateOptions {
/**
* {boolean=true|string=} - If true will update the url in the location bar, if false will not. If string, must be "replace", which will update url and also replace last history record.
*/
location?: boolean | string;
/**
* {boolean=true}, If true will inherit url parameters from current url.
*/
inherit?: boolean;
/**
* {object=$state.$current}, When transitioning with relative path (e.g '^'), defines which state to be relative from.
*/
relative?: IState;
/**
* {boolean=true}, If true will broadcast $stateChangeStart and $stateChangeSuccess events.
*/
notify?: boolean;
/**
* {boolean=false}, If true will force transition even if the state or params have not changed, aka a reload of the same state. It differs from reloadOnSearch because you'd use this when you want to force a reload when everything is the same, including search params.
*/
reload?: boolean;
}
interface IHrefOptions {
lossy?: boolean;
inherit?: boolean;
relative?: IState;
absolute?: boolean;
}
interface IStateService {
/**
* Convenience method for transitioning to a new state. $state.go calls $state.transitionTo internally but automatically sets options to { location: true, inherit: true, relative: $state.$current, notify: true }. This allows you to easily use an absolute or relative to path and specify only the parameters you'd like to update (while letting unspecified parameters inherit from the currently active ancestor states).
*
* @param to Absolute state name or relative state path. Some examples:
*
* $state.go('contact.detail') - will go to the contact.detail state
* $state.go('^') - will go to a parent state
* $state.go('^.sibling') - will go to a sibling state
* $state.go('.child.grandchild') - will go to grandchild state
*
* @param params A map of the parameters that will be sent to the state, will populate $stateParams. Any parameters that are not specified will be inherited from currently defined parameters. This allows, for example, going to a sibling state that shares parameters specified in a parent state. Parameter inheritance only works between common ancestor states, I.e. transitioning to a sibling will get you the parameters for all parents, transitioning to a child will get you all current parameters, etc.
*
* @param options Options object.
*/
go(to: string, params?: {}, options?: IStateOptions): angular.IPromise<any>;
go(to: IState, params?: {}, options?: IStateOptions): angular.IPromise<any>;
transitionTo(state: string, params?: {}, updateLocation?: boolean): angular.IPromise<any>;
transitionTo(state: IState, params?: {}, updateLocation?: boolean): angular.IPromise<any>;
transitionTo(state: string, params?: {}, options?: IStateOptions): angular.IPromise<any>;
transitionTo(state: IState, params?: {}, options?: IStateOptions): angular.IPromise<any>;
includes(state: string, params?: {}): boolean;
is(state:string, params?: {}): boolean;
is(state: IState, params?: {}): boolean;
href(state: IState, params?: {}, options?: IHrefOptions): string;
href(state: string, params?: {}, options?: IHrefOptions): string;
get(state: string): IState;
get(): IState[];
/** A reference to the state's config object. However you passed it in. Useful for accessing custom data. */
current: IState;
/** A param object, e.g. {sectionId: section.id)}, that you'd like to test against the current active state. */
params: IStateParamsService;
reload(): angular.IPromise<any>;
/** Currently pending transition. A promise that'll resolve or reject. */
transition: angular.IPromise<{}>;
$current: IResolvedState;
}
interface IResolvedState {
locals: {
/**
* Currently resolved "resolve" values from the current state
*/
globals: { [key: string]: any; };
};
}
interface IStateParamsService {
[key: string]: any;
}
interface IUrlRouterService {
/*
* Triggers an update; the same update that happens when the address bar
* url changes, aka $locationChangeSuccess.
*
* This method is useful when you need to use preventDefault() on the
* $locationChangeSuccess event, perform some custom logic (route protection,
* auth, config, redirection, etc) and then finally proceed with the transition
* by calling $urlRouter.sync().
*
*/
sync(): void;
listen(): void;
}
interface IUiViewScrollProvider {
/*
* Reverts back to using the core $anchorScroll service for scrolling
* based on the url anchor.
*/
useAnchorScroll(): void;
}
interface IType {
/**
* Converts a parameter value (from URL string or transition param) to a custom/native value.
*
* @param val {string} The URL parameter value to decode.
* @param key {string} The name of the parameter in which val is stored. Can be used for meta-programming of Type objects.
*
* @returns {any} Returns a custom representation of the URL parameter value.
*/
decode(val: string, key: string): any;
/**
* Encodes a custom/native type value to a string that can be embedded in a URL. Note that the return value does not need to be URL-safe (i.e. passed through encodeURIComponent()), it only needs to be a representation of val that has been coerced to a string.
*
* @param val {any} The value to encode.
* @param key {string} The name of the parameter in which val is stored. Can be used for meta-programming of Type objects.
*
* @returns {string} Returns a string representation of val that can be encoded in a URL.
*/
encode(val: any, key: string): string;
/**
* Determines whether two decoded values are equivalent.
*
* @param a {any} A value to compare against.
* @param b {any} A value to compare against.
*
* @returns {boolean} Returns true if the values are equivalent/equal, otherwise false.
*/
equals? (a: any, b: any): boolean;
/**
* Detects whether a value is of a particular type. Accepts a native (decoded) value and determines whether it matches the current Type object.
*
* @param val {any} The value to check.
* @param key {any} Optional. If the type check is happening in the context of a specific UrlMatcher object, this is the name of the parameter in which val is stored. Can be used for meta-programming of Type objects.
*
* @returns {boolean} Returns true if the value matches the type, otherwise false.
*/
is(val: any, key: string): boolean;
/**
* The regular expression pattern used to match values of this type when coming from a substring of a URL.
*/
pattern?: RegExp;
}
}

@ -1,8 +0,0 @@
{
"resolution": "main",
"tree": {
"src": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/78ba6e41543e5ababbd1dda19797601be3c1f304/angular-ui-router/angular-ui-router.d.ts",
"raw": "github:DefinitelyTyped/DefinitelyTyped/angular-ui-router/angular-ui-router.d.ts#78ba6e41543e5ababbd1dda19797601be3c1f304",
"typings": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/78ba6e41543e5ababbd1dda19797601be3c1f304/angular-ui-router/angular-ui-router.d.ts"
}
}

File diff suppressed because it is too large Load Diff

@ -1,8 +0,0 @@
{
"resolution": "main",
"tree": {
"src": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/0b5e88ac7064beb23f379bd4837e0b20356810a6/angularjs/angular.d.ts",
"raw": "registry:dt/angular#1.5.0+20161101124950",
"typings": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/0b5e88ac7064beb23f379bd4837e0b20356810a6/angularjs/angular.d.ts"
}
}

@ -1,12 +0,0 @@
// Generated by typings
// Source: https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/86bb15f6b9a3515bd9b3ca61f2a670533ac6b908/assertion-error/assertion-error.d.ts
declare module 'assertion-error' {
class AssertionError implements Error {
constructor(message: string, props?: any, ssf?: Function);
name: string;
message: string;
showDiff: boolean;
stack: string;
}
export = AssertionError;
}

@ -1,8 +0,0 @@
{
"resolution": "main",
"tree": {
"src": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/86bb15f6b9a3515bd9b3ca61f2a670533ac6b908/assertion-error/assertion-error.d.ts",
"raw": "github:DefinitelyTyped/DefinitelyTyped/assertion-error/assertion-error.d.ts#86bb15f6b9a3515bd9b3ca61f2a670533ac6b908",
"typings": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/86bb15f6b9a3515bd9b3ca61f2a670533ac6b908/assertion-error/assertion-error.d.ts"
}
}

@ -1,285 +0,0 @@
// Generated by typings
// Source: https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/86bb15f6b9a3515bd9b3ca61f2a670533ac6b908/chai-as-promised/chai-as-promised.d.ts
declare module 'chai-as-promised' {
function chaiAsPromised(chai: any, utils: any): void;
namespace chaiAsPromised {}
export = chaiAsPromised;
}
declare namespace Chai {
// For BDD API
interface Assertion extends LanguageChains, NumericComparison, TypeComparison {
eventually: PromisedAssertion;
become(expected: any): PromisedAssertion;
fulfilled: PromisedAssertion;
rejected: PromisedAssertion;
rejectedWith(expected: any, message?: string | RegExp): PromisedAssertion;
notify(fn: Function): PromisedAssertion;
}
// Eventually does not have .then(), but PromisedAssertion have.
interface Eventually extends PromisedLanguageChains, PromisedNumericComparison, PromisedTypeComparison {
// From chai-as-promised
become(expected: PromisesAPlus.Thenable<any>): PromisedAssertion;
fulfilled: PromisedAssertion;
rejected: PromisedAssertion;
rejectedWith(expected: any, message?: string | RegExp): PromisedAssertion;
notify(fn: Function): PromisedAssertion;
// From chai
not: PromisedAssertion;
deep: PromisedDeep;
all: PromisedKeyFilter;
a: PromisedTypeComparison;
an: PromisedTypeComparison;
include: PromisedInclude;
contain: PromisedInclude;
ok: PromisedAssertion;
true: PromisedAssertion;
false: PromisedAssertion;
null: PromisedAssertion;
undefined: PromisedAssertion;
exist: PromisedAssertion;
empty: PromisedAssertion;
arguments: PromisedAssertion;
Arguments: PromisedAssertion;
equal: PromisedEqual;
equals: PromisedEqual;
eq: PromisedEqual;
eql: PromisedEqual;
eqls: PromisedEqual;
property: PromisedProperty;
ownProperty: PromisedOwnProperty;
haveOwnProperty: PromisedOwnProperty;
length: PromisedLength;
lengthOf: PromisedLength;
match(regexp: RegExp|string, message?: string): PromisedAssertion;
string(string: string, message?: string): PromisedAssertion;
keys: PromisedKeys;
key(string: string): PromisedAssertion;
throw: PromisedThrow;
throws: PromisedThrow;
Throw: PromisedThrow;
respondTo(method: string, message?: string): PromisedAssertion;
itself: PromisedAssertion;
satisfy(matcher: Function, message?: string): PromisedAssertion;
closeTo(expected: number, delta: number, message?: string): PromisedAssertion;
members: PromisedMembers;
}
interface PromisedAssertion extends Eventually, PromisesAPlus.Thenable<any> {
}
interface PromisedLanguageChains {
eventually: Eventually;
// From chai
to: PromisedAssertion;
be: PromisedAssertion;
been: PromisedAssertion;
is: PromisedAssertion;
that: PromisedAssertion;
which: PromisedAssertion;
and: PromisedAssertion;
has: PromisedAssertion;
have: PromisedAssertion;
with: PromisedAssertion;
at: PromisedAssertion;
of: PromisedAssertion;
same: PromisedAssertion;
}
interface PromisedNumericComparison {
above: PromisedNumberComparer;
gt: PromisedNumberComparer;
greaterThan: PromisedNumberComparer;
least: PromisedNumberComparer;
gte: PromisedNumberComparer;
below: PromisedNumberComparer;
lt: PromisedNumberComparer;
lessThan: PromisedNumberComparer;
most: PromisedNumberComparer;
lte: PromisedNumberComparer;
within(start: number, finish: number, message?: string): PromisedAssertion;
}
interface PromisedNumberComparer {
(value: number, message?: string): PromisedAssertion;
}
interface PromisedTypeComparison {
(type: string, message?: string): PromisedAssertion;
instanceof: PromisedInstanceOf;
instanceOf: PromisedInstanceOf;
}
interface PromisedInstanceOf {
(constructor: Object, message?: string): PromisedAssertion;
}
interface PromisedDeep {
equal: PromisedEqual;
include: PromisedInclude;
property: PromisedProperty;
}
interface PromisedKeyFilter {
keys: PromisedKeys;
}
interface PromisedEqual {
(value: any, message?: string): PromisedAssertion;
}
interface PromisedProperty {
(name: string, value?: any, message?: string): PromisedAssertion;
}
interface PromisedOwnProperty {
(name: string, message?: string): PromisedAssertion;
}
interface PromisedLength extends PromisedLanguageChains, PromisedNumericComparison {
(length: number, message?: string): PromisedAssertion;
}
interface PromisedInclude {
(value: Object, message?: string): PromisedAssertion;
(value: string, message?: string): PromisedAssertion;
(value: number, message?: string): PromisedAssertion;
keys: PromisedKeys;
members: PromisedMembers;
all: PromisedKeyFilter;
}
interface PromisedKeys {
(...keys: string[]): PromisedAssertion;
(keys: any[]): PromisedAssertion;
}
interface PromisedThrow {
(): PromisedAssertion;
(expected: string, message?: string): PromisedAssertion;
(expected: RegExp, message?: string): PromisedAssertion;
(constructor: Error, expected?: string, message?: string): PromisedAssertion;
(constructor: Error, expected?: RegExp, message?: string): PromisedAssertion;
(constructor: Function, expected?: string, message?: string): PromisedAssertion;
(constructor: Function, expected?: RegExp, message?: string): PromisedAssertion;
}
interface PromisedMembers {
(set: any[], message?: string): PromisedAssertion;
}
// For Assert API
interface Assert {
eventually: PromisedAssert;
isFulfilled(promise: PromisesAPlus.Thenable<any>, message?: string): PromisesAPlus.Thenable<void>;
becomes(promise: PromisesAPlus.Thenable<any>, expected: any, message?: string): PromisesAPlus.Thenable<void>;
doesNotBecome(promise: PromisesAPlus.Thenable<any>, expected: any, message?: string): PromisesAPlus.Thenable<void>;
isRejected(promise: PromisesAPlus.Thenable<any>, message?: string): PromisesAPlus.Thenable<void>;
isRejected(promise: PromisesAPlus.Thenable<any>, expected: any, message?: string): PromisesAPlus.Thenable<void>;
isRejected(promise: PromisesAPlus.Thenable<any>, match: RegExp, message?: string): PromisesAPlus.Thenable<void>;
notify(fn: Function): PromisesAPlus.Thenable<void>;
}
export interface PromisedAssert {
fail(actual?: any, expected?: any, msg?: string, operator?: string): PromisesAPlus.Thenable<void>;
ok(val: any, msg?: string): PromisesAPlus.Thenable<void>;
notOk(val: any, msg?: string): PromisesAPlus.Thenable<void>;
equal(act: any, exp: any, msg?: string): PromisesAPlus.Thenable<void>;
notEqual(act: any, exp: any, msg?: string): PromisesAPlus.Thenable<void>;
strictEqual(act: any, exp: any, msg?: string): PromisesAPlus.Thenable<void>;
notStrictEqual(act: any, exp: any, msg?: string): PromisesAPlus.Thenable<void>;
deepEqual(act: any, exp: any, msg?: string): PromisesAPlus.Thenable<void>;
notDeepEqual(act: any, exp: any, msg?: string): PromisesAPlus.Thenable<void>;
isTrue(val: any, msg?: string): PromisesAPlus.Thenable<void>;
isFalse(val: any, msg?: string): PromisesAPlus.Thenable<void>;
isNull(val: any, msg?: string): PromisesAPlus.Thenable<void>;
isNotNull(val: any, msg?: string): PromisesAPlus.Thenable<void>;
isUndefined(val: any, msg?: string): PromisesAPlus.Thenable<void>;
isDefined(val: any, msg?: string): PromisesAPlus.Thenable<void>;
isFunction(val: any, msg?: string): PromisesAPlus.Thenable<void>;
isNotFunction(val: any, msg?: string): PromisesAPlus.Thenable<void>;
isObject(val: any, msg?: string): PromisesAPlus.Thenable<void>;
isNotObject(val: any, msg?: string): PromisesAPlus.Thenable<void>;
isArray(val: any, msg?: string): PromisesAPlus.Thenable<void>;
isNotArray(val: any, msg?: string): PromisesAPlus.Thenable<void>;
isString(val: any, msg?: string): PromisesAPlus.Thenable<void>;
isNotString(val: any, msg?: string): PromisesAPlus.Thenable<void>;
isNumber(val: any, msg?: string): PromisesAPlus.Thenable<void>;
isNotNumber(val: any, msg?: string): PromisesAPlus.Thenable<void>;
isBoolean(val: any, msg?: string): PromisesAPlus.Thenable<void>;
isNotBoolean(val: any, msg?: string): PromisesAPlus.Thenable<void>;
typeOf(val: any, type: string, msg?: string): PromisesAPlus.Thenable<void>;
notTypeOf(val: any, type: string, msg?: string): PromisesAPlus.Thenable<void>;
instanceOf(val: any, type: Function, msg?: string): PromisesAPlus.Thenable<void>;
notInstanceOf(val: any, type: Function, msg?: string): PromisesAPlus.Thenable<void>;
include(exp: string, inc: any, msg?: string): PromisesAPlus.Thenable<void>;
include(exp: any[], inc: any, msg?: string): PromisesAPlus.Thenable<void>;
notInclude(exp: string, inc: any, msg?: string): PromisesAPlus.Thenable<void>;
notInclude(exp: any[], inc: any, msg?: string): PromisesAPlus.Thenable<void>;
match(exp: any, re: RegExp, msg?: string): PromisesAPlus.Thenable<void>;
notMatch(exp: any, re: RegExp, msg?: string): PromisesAPlus.Thenable<void>;
property(obj: Object, prop: string, msg?: string): PromisesAPlus.Thenable<void>;
notProperty(obj: Object, prop: string, msg?: string): PromisesAPlus.Thenable<void>;
deepProperty(obj: Object, prop: string, msg?: string): PromisesAPlus.Thenable<void>;
notDeepProperty(obj: Object, prop: string, msg?: string): PromisesAPlus.Thenable<void>;
propertyVal(obj: Object, prop: string, val: any, msg?: string): PromisesAPlus.Thenable<void>;
propertyNotVal(obj: Object, prop: string, val: any, msg?: string): PromisesAPlus.Thenable<void>;
deepPropertyVal(obj: Object, prop: string, val: any, msg?: string): PromisesAPlus.Thenable<void>;
deepPropertyNotVal(obj: Object, prop: string, val: any, msg?: string): PromisesAPlus.Thenable<void>;
lengthOf(exp: any, len: number, msg?: string): PromisesAPlus.Thenable<void>;
//alias frenzy
throw(fn: Function, msg?: string): PromisesAPlus.Thenable<void>;
throw(fn: Function, regExp: RegExp): PromisesAPlus.Thenable<void>;
throw(fn: Function, errType: Function, msg?: string): PromisesAPlus.Thenable<void>;
throw(fn: Function, errType: Function, regExp: RegExp): PromisesAPlus.Thenable<void>;
throws(fn: Function, msg?: string): PromisesAPlus.Thenable<void>;
throws(fn: Function, regExp: RegExp): PromisesAPlus.Thenable<void>;
throws(fn: Function, errType: Function, msg?: string): PromisesAPlus.Thenable<void>;
throws(fn: Function, errType: Function, regExp: RegExp): PromisesAPlus.Thenable<void>;
Throw(fn: Function, msg?: string): PromisesAPlus.Thenable<void>;
Throw(fn: Function, regExp: RegExp): PromisesAPlus.Thenable<void>;
Throw(fn: Function, errType: Function, msg?: string): PromisesAPlus.Thenable<void>;
Throw(fn: Function, errType: Function, regExp: RegExp): PromisesAPlus.Thenable<void>;
doesNotThrow(fn: Function, msg?: string): PromisesAPlus.Thenable<void>;
doesNotThrow(fn: Function, regExp: RegExp): PromisesAPlus.Thenable<void>;
doesNotThrow(fn: Function, errType: Function, msg?: string): PromisesAPlus.Thenable<void>;
doesNotThrow(fn: Function, errType: Function, regExp: RegExp): PromisesAPlus.Thenable<void>;
operator(val: any, operator: string, val2: any, msg?: string): PromisesAPlus.Thenable<void>;
closeTo(act: number, exp: number, delta: number, msg?: string): PromisesAPlus.Thenable<void>;
sameMembers(set1: any[], set2: any[], msg?: string): PromisesAPlus.Thenable<void>;
includeMembers(set1: any[], set2: any[], msg?: string): PromisesAPlus.Thenable<void>;
ifError(val: any, msg?: string): PromisesAPlus.Thenable<void>;
}
}

@ -1,8 +0,0 @@
{
"resolution": "main",
"tree": {
"src": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/86bb15f6b9a3515bd9b3ca61f2a670533ac6b908/chai-as-promised/chai-as-promised.d.ts",
"raw": "github:DefinitelyTyped/DefinitelyTyped/chai-as-promised/chai-as-promised.d.ts#86bb15f6b9a3515bd9b3ca61f2a670533ac6b908",
"typings": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/86bb15f6b9a3515bd9b3ca61f2a670533ac6b908/chai-as-promised/chai-as-promised.d.ts"
}
}

@ -1,392 +0,0 @@
// Generated by typings
// Source: https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/86bb15f6b9a3515bd9b3ca61f2a670533ac6b908/chai/chai.d.ts
declare namespace Chai {
interface ChaiStatic {
expect: ExpectStatic;
should(): Should;
/**
* Provides a way to extend the internals of Chai
*/
use(fn: (chai: any, utils: any) => void): ChaiStatic;
assert: AssertStatic;
config: Config;
AssertionError: typeof AssertionError;
}
export interface ExpectStatic extends AssertionStatic {
fail(actual?: any, expected?: any, message?: string, operator?: string): void;
}
export interface AssertStatic extends Assert {
}
export interface AssertionStatic {
(target: any, message?: string): Assertion;
}
interface ShouldAssertion {
equal(value1: any, value2: any, message?: string): void;
Throw: ShouldThrow;
throw: ShouldThrow;
exist(value: any, message?: string): void;
}
interface Should extends ShouldAssertion {
not: ShouldAssertion;
fail(actual: any, expected: any, message?: string, operator?: string): void;
}
interface ShouldThrow {
(actual: Function): void;
(actual: Function, expected: string|RegExp, message?: string): void;
(actual: Function, constructor: Error|Function, expected?: string|RegExp, message?: string): void;
}
interface Assertion extends LanguageChains, NumericComparison, TypeComparison {
not: Assertion;
deep: Deep;
any: KeyFilter;
all: KeyFilter;
a: TypeComparison;
an: TypeComparison;
include: Include;
includes: Include;
contain: Include;
contains: Include;
ok: Assertion;
true: Assertion;
false: Assertion;
null: Assertion;
undefined: Assertion;
NaN: Assertion;
exist: Assertion;
empty: Assertion;
arguments: Assertion;
Arguments: Assertion;
equal: Equal;
equals: Equal;
eq: Equal;
eql: Equal;
eqls: Equal;
property: Property;
ownProperty: OwnProperty;
haveOwnProperty: OwnProperty;
ownPropertyDescriptor: OwnPropertyDescriptor;
haveOwnPropertyDescriptor: OwnPropertyDescriptor;
length: Length;
lengthOf: Length;
match: Match;
matches: Match;
string(string: string, message?: string): Assertion;
keys: Keys;
key(string: string): Assertion;
throw: Throw;
throws: Throw;
Throw: Throw;
respondTo: RespondTo;
respondsTo: RespondTo;
itself: Assertion;
satisfy: Satisfy;
satisfies: Satisfy;
closeTo: CloseTo;
approximately: CloseTo;
members: Members;
increase: PropertyChange;
increases: PropertyChange;
decrease: PropertyChange;
decreases: PropertyChange;
change: PropertyChange;
changes: PropertyChange;
extensible: Assertion;
sealed: Assertion;
frozen: Assertion;
oneOf(list: any[], message?: string): Assertion;
}
interface LanguageChains {
to: Assertion;
be: Assertion;
been: Assertion;
is: Assertion;
that: Assertion;
which: Assertion;
and: Assertion;
has: Assertion;
have: Assertion;
with: Assertion;
at: Assertion;
of: Assertion;
same: Assertion;
}
interface NumericComparison {
above: NumberComparer;
gt: NumberComparer;
greaterThan: NumberComparer;
least: NumberComparer;
gte: NumberComparer;
below: NumberComparer;
lt: NumberComparer;
lessThan: NumberComparer;
most: NumberComparer;
lte: NumberComparer;
within(start: number, finish: number, message?: string): Assertion;
}
interface NumberComparer {
(value: number, message?: string): Assertion;
}
interface TypeComparison {
(type: string, message?: string): Assertion;
instanceof: InstanceOf;
instanceOf: InstanceOf;
}
interface InstanceOf {
(constructor: Object, message?: string): Assertion;
}
interface CloseTo {
(expected: number, delta: number, message?: string): Assertion;
}
interface Deep {
equal: Equal;
include: Include;
property: Property;
members: Members;
}
interface KeyFilter {
keys: Keys;
}
interface Equal {
(value: any, message?: string): Assertion;
}
interface Property {
(name: string, value?: any, message?: string): Assertion;
}
interface OwnProperty {
(name: string, message?: string): Assertion;
}
interface OwnPropertyDescriptor {
(name: string, descriptor: PropertyDescriptor, message?: string): Assertion;
(name: string, message?: string): Assertion;
}
interface Length extends LanguageChains, NumericComparison {
(length: number, message?: string): Assertion;
}
interface Include {
(value: Object, message?: string): Assertion;
(value: string, message?: string): Assertion;
(value: number, message?: string): Assertion;
keys: Keys;
members: Members;
any: KeyFilter;
all: KeyFilter;
}
interface Match {
(regexp: RegExp|string, message?: string): Assertion;
}
interface Keys {
(...keys: string[]): Assertion;
(keys: any[]): Assertion;
(keys: Object): Assertion;
}
interface Throw {
(): Assertion;
(expected: string, message?: string): Assertion;
(expected: RegExp, message?: string): Assertion;
(constructor: Error, expected?: string, message?: string): Assertion;
(constructor: Error, expected?: RegExp, message?: string): Assertion;
(constructor: Function, expected?: string, message?: string): Assertion;
(constructor: Function, expected?: RegExp, message?: string): Assertion;
}
interface RespondTo {
(method: string, message?: string): Assertion;
}
interface Satisfy {
(matcher: Function, message?: string): Assertion;
}
interface Members {
(set: any[], message?: string): Assertion;
}
interface PropertyChange {
(object: Object, prop: string, msg?: string): Assertion;
}
export interface Assert {
/**
* @param expression Expression to test for truthiness.
* @param message Message to display on error.
*/
(expression: any, message?: string): void;
fail(actual?: any, expected?: any, msg?: string, operator?: string): void;
ok(val: any, msg?: string): void;
isOk(val: any, msg?: string): void;
notOk(val: any, msg?: string): void;
isNotOk(val: any, msg?: string): void;
equal(act: any, exp: any, msg?: string): void;
notEqual(act: any, exp: any, msg?: string): void;
strictEqual(act: any, exp: any, msg?: string): void;
notStrictEqual(act: any, exp: any, msg?: string): void;
deepEqual(act: any, exp: any, msg?: string): void;
notDeepEqual(act: any, exp: any, msg?: string): void;
isTrue(val: any, msg?: string): void;
isFalse(val: any, msg?: string): void;
isNotTrue(val: any, msg?: string): void;
isNotFalse(val: any, msg?: string): void;
isNull(val: any, msg?: string): void;
isNotNull(val: any, msg?: string): void;
isUndefined(val: any, msg?: string): void;
isDefined(val: any, msg?: string): void;
isNaN(val: any, msg?: string): void;
isNotNaN(val: any, msg?: string): void;
isAbove(val: number, abv: number, msg?: string): void;
isBelow(val: number, blw: number, msg?: string): void;
isAtLeast(val: number, atlst: number, msg?: string): void;
isAtMost(val: number, atmst: number, msg?: string): void;
isFunction(val: any, msg?: string): void;
isNotFunction(val: any, msg?: string): void;
isObject(val: any, msg?: string): void;
isNotObject(val: any, msg?: string): void;
isArray(val: any, msg?: string): void;
isNotArray(val: any, msg?: string): void;
isString(val: any, msg?: string): void;
isNotString(val: any, msg?: string): void;
isNumber(val: any, msg?: string): void;
isNotNumber(val: any, msg?: string): void;
isBoolean(val: any, msg?: string): void;
isNotBoolean(val: any, msg?: string): void;
typeOf(val: any, type: string, msg?: string): void;
notTypeOf(val: any, type: string, msg?: string): void;
instanceOf(val: any, type: Function, msg?: string): void;
notInstanceOf(val: any, type: Function, msg?: string): void;
include(exp: string, inc: any, msg?: string): void;
include(exp: any[], inc: any, msg?: string): void;
notInclude(exp: string, inc: any, msg?: string): void;
notInclude(exp: any[], inc: any, msg?: string): void;
match(exp: any, re: RegExp, msg?: string): void;
notMatch(exp: any, re: RegExp, msg?: string): void;
property(obj: Object, prop: string, msg?: string): void;
notProperty(obj: Object, prop: string, msg?: string): void;
deepProperty(obj: Object, prop: string, msg?: string): void;
notDeepProperty(obj: Object, prop: string, msg?: string): void;
propertyVal(obj: Object, prop: string, val: any, msg?: string): void;
propertyNotVal(obj: Object, prop: string, val: any, msg?: string): void;
deepPropertyVal(obj: Object, prop: string, val: any, msg?: string): void;
deepPropertyNotVal(obj: Object, prop: string, val: any, msg?: string): void;
lengthOf(exp: any, len: number, msg?: string): void;
//alias frenzy
throw(fn: Function, msg?: string): void;
throw(fn: Function, regExp: RegExp): void;
throw(fn: Function, errType: Function, msg?: string): void;
throw(fn: Function, errType: Function, regExp: RegExp): void;
throws(fn: Function, msg?: string): void;
throws(fn: Function, regExp: RegExp): void;
throws(fn: Function, errType: Function, msg?: string): void;
throws(fn: Function, errType: Function, regExp: RegExp): void;
Throw(fn: Function, msg?: string): void;
Throw(fn: Function, regExp: RegExp): void;
Throw(fn: Function, errType: Function, msg?: string): void;
Throw(fn: Function, errType: Function, regExp: RegExp): void;
doesNotThrow(fn: Function, msg?: string): void;
doesNotThrow(fn: Function, regExp: RegExp): void;
doesNotThrow(fn: Function, errType: Function, msg?: string): void;
doesNotThrow(fn: Function, errType: Function, regExp: RegExp): void;
operator(val: any, operator: string, val2: any, msg?: string): void;
closeTo(act: number, exp: number, delta: number, msg?: string): void;
approximately(act: number, exp: number, delta: number, msg?: string): void;
sameMembers(set1: any[], set2: any[], msg?: string): void;
sameDeepMembers(set1: any[], set2: any[], msg?: string): void;
includeMembers(superset: any[], subset: any[], msg?: string): void;
ifError(val: any, msg?: string): void;
isExtensible(obj: {}, msg?: string): void;
extensible(obj: {}, msg?: string): void;
isNotExtensible(obj: {}, msg?: string): void;
notExtensible(obj: {}, msg?: string): void;
isSealed(obj: {}, msg?: string): void;
sealed(obj: {}, msg?: string): void;
isNotSealed(obj: {}, msg?: string): void;
notSealed(obj: {}, msg?: string): void;
isFrozen(obj: Object, msg?: string): void;
frozen(obj: Object, msg?: string): void;
isNotFrozen(obj: Object, msg?: string): void;
notFrozen(obj: Object, msg?: string): void;
oneOf(inList: any, list: any[], msg?: string): void;
}
export interface Config {
includeStack: boolean;
}
export class AssertionError {
constructor(message: string, _props?: any, ssf?: Function);
name: string;
message: string;
showDiff: boolean;
stack: string;
}
}
declare var chai: Chai.ChaiStatic;
declare module "chai" {
export = chai;
}
interface Object {
should: Chai.Assertion;
}

@ -1,8 +0,0 @@
{
"resolution": "main",
"tree": {
"src": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/86bb15f6b9a3515bd9b3ca61f2a670533ac6b908/chai/chai.d.ts",
"raw": "github:DefinitelyTyped/DefinitelyTyped/chai/chai.d.ts#86bb15f6b9a3515bd9b3ca61f2a670533ac6b908",
"typings": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/86bb15f6b9a3515bd9b3ca61f2a670533ac6b908/chai/chai.d.ts"
}
}

@ -1,666 +0,0 @@
// Generated by typings
// Source: https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/5d004be8ba9a0c34e387c249f6873dc68e20ebfa/es6-shim/index.d.ts
declare type PropertyKey = string | number | symbol;
interface IteratorResult<T> {
done: boolean;
value?: T;
}
interface IterableShim<T> {
/**
* Shim for an ES6 iterable. Not intended for direct use by user code.
*/
"_es6-shim iterator_"(): Iterator<T>;
}
interface Iterator<T> {
next(value?: any): IteratorResult<T>;
return?(value?: any): IteratorResult<T>;
throw?(e?: any): IteratorResult<T>;
}
interface IterableIteratorShim<T> extends IterableShim<T>, Iterator<T> {
/**
* Shim for an ES6 iterable iterator. Not intended for direct use by user code.
*/
"_es6-shim iterator_"(): IterableIteratorShim<T>;
}
interface StringConstructor {
/**
* Return the String value whose elements are, in order, the elements in the List elements.
* If length is 0, the empty string is returned.
*/
fromCodePoint(...codePoints: number[]): string;
/**
* String.raw is intended for use as a tag function of a Tagged Template String. When called
* as such the first argument will be a well formed template call site object and the rest
* parameter will contain the substitution values.
* @param template A well-formed template string call site representation.
* @param substitutions A set of substitution values.
*/
raw(template: TemplateStringsArray, ...substitutions: any[]): string;
}
interface String {
/**
* Returns a nonnegative integer Number less than 1114112 (0x110000) that is the code point
* value of the UTF-16 encoded code point starting at the string element at position pos in
* the String resulting from converting this object to a String.
* If there is no element at that position, the result is undefined.
* If a valid UTF-16 surrogate pair does not begin at pos, the result is the code unit at pos.
*/
codePointAt(pos: number): number;
/**
* Returns true if searchString appears as a substring of the result of converting this
* object to a String, at one or more positions that are
* greater than or equal to position; otherwise, returns false.
* @param searchString search string
* @param position If position is undefined, 0 is assumed, so as to search all of the String.
*/
includes(searchString: string, position?: number): boolean;
/**
* Returns true if the sequence of elements of searchString converted to a String is the
* same as the corresponding elements of this object (converted to a String) starting at
* endPosition length(this). Otherwise returns false.
*/
endsWith(searchString: string, endPosition?: number): boolean;
/**
* Returns a String value that is made from count copies appended together. If count is 0,
* T is the empty String is returned.
* @param count number of copies to append
*/
repeat(count: number): string;
/**
* Returns true if the sequence of elements of searchString converted to a String is the
* same as the corresponding elements of this object (converted to a String) starting at
* position. Otherwise returns false.
*/
startsWith(searchString: string, position?: number): boolean;
/**
* Returns an <a> HTML anchor element and sets the name attribute to the text value
* @param name
*/
anchor(name: string): string;
/** Returns a <big> HTML element */
big(): string;
/** Returns a <blink> HTML element */
blink(): string;
/** Returns a <b> HTML element */
bold(): string;
/** Returns a <tt> HTML element */
fixed(): string
/** Returns a <font> HTML element and sets the color attribute value */
fontcolor(color: string): string
/** Returns a <font> HTML element and sets the size attribute value */
fontsize(size: number): string;
/** Returns a <font> HTML element and sets the size attribute value */
fontsize(size: string): string;
/** Returns an <i> HTML element */
italics(): string;
/** Returns an <a> HTML element and sets the href attribute value */
link(url: string): string;
/** Returns a <small> HTML element */
small(): string;
/** Returns a <strike> HTML element */
strike(): string;
/** Returns a <sub> HTML element */
sub(): string;
/** Returns a <sup> HTML element */
sup(): string;
/**
* Shim for an ES6 iterable. Not intended for direct use by user code.
*/
"_es6-shim iterator_"(): IterableIteratorShim<string>;
}
interface ArrayConstructor {
/**
* Creates an array from an array-like object.
* @param arrayLike An array-like object to convert to an array.
* @param mapfn A mapping function to call on every element of the array.
* @param thisArg Value of 'this' used to invoke the mapfn.
*/
from<T, U>(arrayLike: ArrayLike<T>, mapfn: (v: T, k: number) => U, thisArg?: any): Array<U>;
/**
* Creates an array from an iterable object.
* @param iterable An iterable object to convert to an array.
* @param mapfn A mapping function to call on every element of the array.
* @param thisArg Value of 'this' used to invoke the mapfn.
*/
from<T, U>(iterable: IterableShim<T>, mapfn: (v: T, k: number) => U, thisArg?: any): Array<U>;
/**
* Creates an array from an array-like object.
* @param arrayLike An array-like object to convert to an array.
*/
from<T>(arrayLike: ArrayLike<T>): Array<T>;
/**
* Creates an array from an iterable object.
* @param iterable An iterable object to convert to an array.
*/
from<T>(iterable: IterableShim<T>): Array<T>;
/**
* Returns a new array from a set of elements.
* @param items A set of elements to include in the new array object.
*/
of<T>(...items: T[]): Array<T>;
}
interface Array<T> {
/**
* Returns the value of the first element in the array where predicate is true, and undefined
* otherwise.
* @param predicate find calls predicate once for each element of the array, in ascending
* order, until it finds one where predicate returns true. If such an element is found, find
* immediately returns that element value. Otherwise, find returns undefined.
* @param thisArg If provided, it will be used as the this value for each invocation of
* predicate. If it is not provided, undefined is used instead.
*/
find(predicate: (value: T, index: number, obj: Array<T>) => boolean, thisArg?: any): T;
/**
* Returns the index of the first element in the array where predicate is true, and undefined
* otherwise.
* @param predicate find calls predicate once for each element of the array, in ascending
* order, until it finds one where predicate returns true. If such an element is found, find
* immediately returns that element value. Otherwise, find returns undefined.
* @param thisArg If provided, it will be used as the this value for each invocation of
* predicate. If it is not provided, undefined is used instead.
*/
findIndex(predicate: (value: T) => boolean, thisArg?: any): number;
/**
* Returns the this object after filling the section identified by start and end with value
* @param value value to fill array section with
* @param start index to start filling the array at. If start is negative, it is treated as
* length+start where length is the length of the array.
* @param end index to stop filling the array at. If end is negative, it is treated as
* length+end.
*/
fill(value: T, start?: number, end?: number): T[];
/**
* Returns the this object after copying a section of the array identified by start and end
* to the same array starting at position target
* @param target If target is negative, it is treated as length+target where length is the
* length of the array.
* @param start If start is negative, it is treated as length+start. If end is negative, it
* is treated as length+end.
* @param end If not specified, length of the this object is used as its default value.
*/
copyWithin(target: number, start: number, end?: number): T[];
/**
* Returns an array of key, value pairs for every entry in the array
*/
entries(): IterableIteratorShim<[number, T]>;
/**
* Returns an list of keys in the array
*/
keys(): IterableIteratorShim<number>;
/**
* Returns an list of values in the array
*/
values(): IterableIteratorShim<T>;
/**
* Shim for an ES6 iterable. Not intended for direct use by user code.
*/
"_es6-shim iterator_"(): IterableIteratorShim<T>;
}
interface NumberConstructor {
/**
* The value of Number.EPSILON is the difference between 1 and the smallest value greater than 1
* that is representable as a Number value, which is approximately:
* 2.2204460492503130808472633361816 x 1016.
*/
EPSILON: number;
/**
* Returns true if passed value is finite.
* Unlike the global isFininte, Number.isFinite doesn't forcibly convert the parameter to a
* number. Only finite values of the type number, result in true.
* @param number A numeric value.
*/
isFinite(number: number): boolean;
/**
* Returns true if the value passed is an integer, false otherwise.
* @param number A numeric value.
*/
isInteger(number: number): boolean;
/**
* Returns a Boolean value that indicates whether a value is the reserved value NaN (not a
* number). Unlike the global isNaN(), Number.isNaN() doesn't forcefully convert the parameter
* to a number. Only values of the type number, that are also NaN, result in true.
* @param number A numeric value.
*/
isNaN(number: number): boolean;
/**
* Returns true if the value passed is a safe integer.
* @param number A numeric value.
*/
isSafeInteger(number: number): boolean;
/**
* The value of the largest integer n such that n and n + 1 are both exactly representable as
* a Number value.
* The value of Number.MIN_SAFE_INTEGER is 9007199254740991 2^53 1.
*/
MAX_SAFE_INTEGER: number;
/**
* The value of the smallest integer n such that n and n 1 are both exactly representable as
* a Number value.
* The value of Number.MIN_SAFE_INTEGER is 9007199254740991 ((2^53 1)).
*/
MIN_SAFE_INTEGER: number;
/**
* Converts a string to a floating-point number.
* @param string A string that contains a floating-point number.
*/
parseFloat(string: string): number;
/**
* Converts A string to an integer.
* @param s A string to convert into a number.
* @param radix A value between 2 and 36 that specifies the base of the number in numString.
* If this argument is not supplied, strings with a prefix of '0x' are considered hexadecimal.
* All other strings are considered decimal.
*/
parseInt(string: string, radix?: number): number;
}
interface ObjectConstructor {
/**
* Copy the values of all of the enumerable own properties from one or more source objects to a
* target object. Returns the target object.
* @param target The target object to copy to.
* @param sources One or more source objects to copy properties from.
*/
assign(target: any, ...sources: any[]): any;
/**
* Returns true if the values are the same value, false otherwise.
* @param value1 The first value.
* @param value2 The second value.
*/
is(value1: any, value2: any): boolean;
/**
* Sets the prototype of a specified object o to object proto or null. Returns the object o.
* @param o The object to change its prototype.
* @param proto The value of the new prototype or null.
* @remarks Requires `__proto__` support.
*/
setPrototypeOf(o: any, proto: any): any;
}
interface RegExp {
/**
* Returns a string indicating the flags of the regular expression in question. This field is read-only.
* The characters in this string are sequenced and concatenated in the following order:
*
* - "g" for global
* - "i" for ignoreCase
* - "m" for multiline
* - "u" for unicode
* - "y" for sticky
*
* If no flags are set, the value is the empty string.
*/
flags: string;
}
interface Math {
/**
* Returns the number of leading zero bits in the 32-bit binary representation of a number.
* @param x A numeric expression.
*/
clz32(x: number): number;
/**
* Returns the result of 32-bit multiplication of two numbers.
* @param x First number
* @param y Second number
*/
imul(x: number, y: number): number;
/**
* Returns the sign of the x, indicating whether x is positive, negative or zero.
* @param x The numeric expression to test
*/
sign(x: number): number;
/**
* Returns the base 10 logarithm of a number.
* @param x A numeric expression.
*/
log10(x: number): number;
/**
* Returns the base 2 logarithm of a number.
* @param x A numeric expression.
*/
log2(x: number): number;
/**
* Returns the natural logarithm of 1 + x.
* @param x A numeric expression.
*/
log1p(x: number): number;
/**
* Returns the result of (e^x - 1) of x (e raised to the power of x, where e is the base of
* the natural logarithms).
* @param x A numeric expression.
*/
expm1(x: number): number;
/**
* Returns the hyperbolic cosine of a number.
* @param x A numeric expression that contains an angle measured in radians.
*/
cosh(x: number): number;
/**
* Returns the hyperbolic sine of a number.
* @param x A numeric expression that contains an angle measured in radians.
*/
sinh(x: number): number;
/**
* Returns the hyperbolic tangent of a number.
* @param x A numeric expression that contains an angle measured in radians.
*/
tanh(x: number): number;
/**
* Returns the inverse hyperbolic cosine of a number.
* @param x A numeric expression that contains an angle measured in radians.
*/
acosh(x: number): number;
/**
* Returns the inverse hyperbolic sine of a number.
* @param x A numeric expression that contains an angle measured in radians.
*/
asinh(x: number): number;
/**
* Returns the inverse hyperbolic tangent of a number.
* @param x A numeric expression that contains an angle measured in radians.
*/
atanh(x: number): number;
/**
* Returns the square root of the sum of squares of its arguments.
* @param values Values to compute the square root for.
* If no arguments are passed, the result is +0.
* If there is only one argument, the result is the absolute value.
* If any argument is +Infinity or -Infinity, the result is +Infinity.
* If any argument is NaN, the result is NaN.
* If all arguments are either +0 or 0, the result is +0.
*/
hypot(...values: number[]): number;
/**
* Returns the integral part of the a numeric expression, x, removing any fractional digits.
* If x is already an integer, the result is x.
* @param x A numeric expression.
*/
trunc(x: number): number;
/**
* Returns the nearest single precision float representation of a number.
* @param x A numeric expression.
*/
fround(x: number): number;
/**
* Returns an implementation-dependent approximation to the cube root of number.
* @param x A numeric expression.
*/
cbrt(x: number): number;
}
interface PromiseLike<T> {
/**
* Attaches callbacks for the resolution and/or rejection of the Promise.
* @param onfulfilled The callback to execute when the Promise is resolved.
* @param onrejected The callback to execute when the Promise is rejected.
* @returns A Promise for the completion of which ever callback is executed.
*/
then<TResult>(onfulfilled?: (value: T) => TResult | PromiseLike<TResult>, onrejected?: (reason: any) => TResult | PromiseLike<TResult>): PromiseLike<TResult>;
then<TResult>(onfulfilled?: (value: T) => TResult | PromiseLike<TResult>, onrejected?: (reason: any) => void): PromiseLike<TResult>;
}
/**
* Represents the completion of an asynchronous operation
*/
interface Promise<T> {
/**
* Attaches callbacks for the resolution and/or rejection of the Promise.
* @param onfulfilled The callback to execute when the Promise is resolved.
* @param onrejected The callback to execute when the Promise is rejected.
* @returns A Promise for the completion of which ever callback is executed.
*/
then<TResult>(onfulfilled?: (value: T) => TResult | PromiseLike<TResult>, onrejected?: (reason: any) => TResult | PromiseLike<TResult>): Promise<TResult>;
then<TResult>(onfulfilled?: (value: T) => TResult | PromiseLike<TResult>, onrejected?: (reason: any) => void): Promise<TResult>;
/**
* Attaches a callback for only the rejection of the Promise.
* @param onrejected The callback to execute when the Promise is rejected.
* @returns A Promise for the completion of the callback.
*/
catch(onrejected?: (reason: any) => T | PromiseLike<T>): Promise<T>;
catch(onrejected?: (reason: any) => void): Promise<T>;
}
interface PromiseConstructor {
/**
* A reference to the prototype.
*/
prototype: Promise<any>;
/**
* Creates a new Promise.
* @param executor A callback used to initialize the promise. This callback is passed two arguments:
* a resolve callback used resolve the promise with a value or the result of another promise,
* and a reject callback used to reject the promise with a provided reason or error.
*/
new <T>(executor: (resolve: (value?: T | PromiseLike<T>) => void, reject: (reason?: any) => void) => void): Promise<T>;
/**
* Creates a Promise that is resolved with an array of results when all of the provided Promises
* resolve, or rejected when any Promise is rejected.
* @param values An array of Promises.
* @returns A new Promise.
*/
all<T>(values: IterableShim<T | PromiseLike<T>>): Promise<T[]>;
/**
* Creates a Promise that is resolved or rejected when any of the provided Promises are resolved
* or rejected.
* @param values An array of Promises.
* @returns A new Promise.
*/
race<T>(values: IterableShim<T | PromiseLike<T>>): Promise<T>;
/**
* Creates a new rejected promise for the provided reason.
* @param reason The reason the promise was rejected.
* @returns A new rejected Promise.
*/
reject(reason: any): Promise<void>;
/**
* Creates a new rejected promise for the provided reason.
* @param reason The reason the promise was rejected.
* @returns A new rejected Promise.
*/
reject<T>(reason: any): Promise<T>;
/**
* Creates a new resolved promise for the provided value.
* @param value A promise.
* @returns A promise whose internal state matches the provided promise.
*/
resolve<T>(value: T | PromiseLike<T>): Promise<T>;
/**
* Creates a new resolved promise .
* @returns A resolved promise.
*/
resolve(): Promise<void>;
}
declare var Promise: PromiseConstructor;
interface Map<K, V> {
clear(): void;
delete(key: K): boolean;
forEach(callbackfn: (value: V, index: K, map: Map<K, V>) => void, thisArg?: any): void;
get(key: K): V;
has(key: K): boolean;
set(key: K, value?: V): Map<K, V>;
size: number;
entries(): IterableIteratorShim<[K, V]>;
keys(): IterableIteratorShim<K>;
values(): IterableIteratorShim<V>;
}
interface MapConstructor {
new <K, V>(): Map<K, V>;
new <K, V>(iterable: IterableShim<[K, V]>): Map<K, V>;
prototype: Map<any, any>;
}
declare var Map: MapConstructor;
interface Set<T> {
add(value: T): Set<T>;
clear(): void;
delete(value: T): boolean;
forEach(callbackfn: (value: T, index: T, set: Set<T>) => void, thisArg?: any): void;
has(value: T): boolean;
size: number;
entries(): IterableIteratorShim<[T, T]>;
keys(): IterableIteratorShim<T>;
values(): IterableIteratorShim<T>;
'_es6-shim iterator_'(): IterableIteratorShim<T>;
}
interface SetConstructor {
new <T>(): Set<T>;
new <T>(iterable: IterableShim<T>): Set<T>;
prototype: Set<any>;
}
declare var Set: SetConstructor;
interface WeakMap<K, V> {
delete(key: K): boolean;
get(key: K): V;
has(key: K): boolean;
set(key: K, value?: V): WeakMap<K, V>;
}
interface WeakMapConstructor {
new <K, V>(): WeakMap<K, V>;
new <K, V>(iterable: IterableShim<[K, V]>): WeakMap<K, V>;
prototype: WeakMap<any, any>;
}
declare var WeakMap: WeakMapConstructor;
interface WeakSet<T> {
add(value: T): WeakSet<T>;
delete(value: T): boolean;
has(value: T): boolean;
}
interface WeakSetConstructor {
new <T>(): WeakSet<T>;
new <T>(iterable: IterableShim<T>): WeakSet<T>;
prototype: WeakSet<any>;
}
declare var WeakSet: WeakSetConstructor;
declare namespace Reflect {
function apply(target: Function, thisArgument: any, argumentsList: ArrayLike<any>): any;
function construct(target: Function, argumentsList: ArrayLike<any>): any;
function defineProperty(target: any, propertyKey: PropertyKey, attributes: PropertyDescriptor): boolean;
function deleteProperty(target: any, propertyKey: PropertyKey): boolean;
function enumerate(target: any): IterableIteratorShim<any>;
function get(target: any, propertyKey: PropertyKey, receiver?: any): any;
function getOwnPropertyDescriptor(target: any, propertyKey: PropertyKey): PropertyDescriptor;
function getPrototypeOf(target: any): any;
function has(target: any, propertyKey: PropertyKey): boolean;
function isExtensible(target: any): boolean;
function ownKeys(target: any): Array<PropertyKey>;
function preventExtensions(target: any): boolean;
function set(target: any, propertyKey: PropertyKey, value: any, receiver?: any): boolean;
function setPrototypeOf(target: any, proto: any): boolean;
}
declare module "es6-shim" {
var String: StringConstructor;
var Array: ArrayConstructor;
var Number: NumberConstructor;
var Math: Math;
var Object: ObjectConstructor;
var Map: MapConstructor;
var Set: SetConstructor;
var WeakMap: WeakMapConstructor;
var WeakSet: WeakSetConstructor;
var Promise: PromiseConstructor;
namespace Reflect {
function apply(target: Function, thisArgument: any, argumentsList: ArrayLike<any>): any;
function construct(target: Function, argumentsList: ArrayLike<any>): any;
function defineProperty(target: any, propertyKey: PropertyKey, attributes: PropertyDescriptor): boolean;
function deleteProperty(target: any, propertyKey: PropertyKey): boolean;
function enumerate(target: any): Iterator<any>;
function get(target: any, propertyKey: PropertyKey, receiver?: any): any;
function getOwnPropertyDescriptor(target: any, propertyKey: PropertyKey): PropertyDescriptor;
function getPrototypeOf(target: any): any;
function has(target: any, propertyKey: PropertyKey): boolean;
function isExtensible(target: any): boolean;
function ownKeys(target: any): Array<PropertyKey>;
function preventExtensions(target: any): boolean;
function set(target: any, propertyKey: PropertyKey, value: any, receiver?: any): boolean;
function setPrototypeOf(target: any, proto: any): boolean;
}
}

@ -1,8 +0,0 @@
{
"resolution": "main",
"tree": {
"src": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/5d004be8ba9a0c34e387c249f6873dc68e20ebfa/es6-shim/index.d.ts",
"raw": "registry:dt/es6-shim#0.31.2+20160726072212",
"typings": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/5d004be8ba9a0c34e387c249f6873dc68e20ebfa/es6-shim/index.d.ts"
}
}

File diff suppressed because it is too large Load Diff

@ -1,8 +0,0 @@
{
"resolution": "main",
"tree": {
"src": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/4ec3c5bf291bc02f49eb30c1077340b235165c67/jquery/jquery.d.ts",
"raw": "github:DefinitelyTyped/DefinitelyTyped/jquery/jquery.d.ts#4ec3c5bf291bc02f49eb30c1077340b235165c67",
"typings": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/4ec3c5bf291bc02f49eb30c1077340b235165c67/jquery/jquery.d.ts"
}
}

File diff suppressed because it is too large Load Diff

@ -1,8 +0,0 @@
{
"resolution": "main",
"tree": {
"src": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/ead8376ca80553332af7872f9fe723c6fbb4e412/jqueryui/index.d.ts",
"raw": "registry:dt/jqueryui#1.11.0+20161214061125",
"typings": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/ead8376ca80553332af7872f9fe723c6fbb4e412/jqueryui/index.d.ts"
}
}

File diff suppressed because it is too large Load Diff

@ -1,8 +0,0 @@
{
"resolution": "main",
"tree": {
"src": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/627b6c158b73494c803f36fc2fe00ad75faa8fde/lodash/lodash.d.ts",
"raw": "github:DefinitelyTyped/DefinitelyTyped/lodash/lodash.d.ts#627b6c158b73494c803f36fc2fe00ad75faa8fde",
"typings": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/627b6c158b73494c803f36fc2fe00ad75faa8fde/lodash/lodash.d.ts"
}
}

@ -1,234 +0,0 @@
// Generated by typings
// Source: https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/86bb15f6b9a3515bd9b3ca61f2a670533ac6b908/mocha/mocha.d.ts
interface MochaSetupOptions {
//milliseconds to wait before considering a test slow
slow?: number;
// timeout in milliseconds
timeout?: number;
// ui name "bdd", "tdd", "exports" etc
ui?: string;
//array of accepted globals
globals?: any[];
// reporter instance (function or string), defaults to `mocha.reporters.Spec`
reporter?: any;
// bail on the first test failure
bail?: boolean;
// ignore global leaks
ignoreLeaks?: boolean;
// grep string or regexp to filter tests with
grep?: any;
}
interface MochaDone {
(error?: Error): void;
}
declare var mocha: Mocha;
declare var describe: Mocha.IContextDefinition;
declare var xdescribe: Mocha.IContextDefinition;
// alias for `describe`
declare var context: Mocha.IContextDefinition;
// alias for `describe`
declare var suite: Mocha.IContextDefinition;
declare var it: Mocha.ITestDefinition;
declare var xit: Mocha.ITestDefinition;
// alias for `it`
declare var test: Mocha.ITestDefinition;
declare var specify: Mocha.ITestDefinition;
declare function before(action: () => void): void;
declare function before(action: (done: MochaDone) => void): void;
declare function before(description: string, action: () => void): void;
declare function before(description: string, action: (done: MochaDone) => void): void;
declare function setup(action: () => void): void;
declare function setup(action: (done: MochaDone) => void): void;
declare function after(action: () => void): void;
declare function after(action: (done: MochaDone) => void): void;
declare function after(description: string, action: () => void): void;
declare function after(description: string, action: (done: MochaDone) => void): void;
declare function teardown(action: () => void): void;
declare function teardown(action: (done: MochaDone) => void): void;
declare function beforeEach(action: () => void): void;
declare function beforeEach(action: (done: MochaDone) => void): void;
declare function beforeEach(description: string, action: () => void): void;
declare function beforeEach(description: string, action: (done: MochaDone) => void): void;
declare function suiteSetup(action: () => void): void;
declare function suiteSetup(action: (done: MochaDone) => void): void;
declare function afterEach(action: () => void): void;
declare function afterEach(action: (done: MochaDone) => void): void;
declare function afterEach(description: string, action: () => void): void;
declare function afterEach(description: string, action: (done: MochaDone) => void): void;
declare function suiteTeardown(action: () => void): void;
declare function suiteTeardown(action: (done: MochaDone) => void): void;
declare class Mocha {
constructor(options?: {
grep?: RegExp;
ui?: string;
reporter?: string;
timeout?: number;
bail?: boolean;
});
/** Setup mocha with the given options. */
setup(options: MochaSetupOptions): Mocha;
bail(value?: boolean): Mocha;
addFile(file: string): Mocha;
/** Sets reporter by name, defaults to "spec". */
reporter(name: string): Mocha;
/** Sets reporter constructor, defaults to mocha.reporters.Spec. */
reporter(reporter: (runner: Mocha.IRunner, options: any) => any): Mocha;
ui(value: string): Mocha;
grep(value: string): Mocha;
grep(value: RegExp): Mocha;
invert(): Mocha;
ignoreLeaks(value: boolean): Mocha;
checkLeaks(): Mocha;
/**
* Function to allow assertion libraries to throw errors directly into mocha.
* This is useful when running tests in a browser because window.onerror will
* only receive the 'message' attribute of the Error.
*/
throwError(error: Error): void;
/** Enables growl support. */
growl(): Mocha;
globals(value: string): Mocha;
globals(values: string[]): Mocha;
useColors(value: boolean): Mocha;
useInlineDiffs(value: boolean): Mocha;
timeout(value: number): Mocha;
slow(value: number): Mocha;
enableTimeouts(value: boolean): Mocha;
asyncOnly(value: boolean): Mocha;
noHighlighting(value: boolean): Mocha;
/** Runs tests and invokes `onComplete()` when finished. */
run(onComplete?: (failures: number) => void): Mocha.IRunner;
}
// merge the Mocha class declaration with a module
declare namespace Mocha {
/** Partial interface for Mocha's `Runnable` class. */
interface IRunnable {
title: string;
fn: Function;
async: boolean;
sync: boolean;
timedOut: boolean;
}
/** Partial interface for Mocha's `Suite` class. */
interface ISuite {
parent: ISuite;
title: string;
fullTitle(): string;
}
/** Partial interface for Mocha's `Test` class. */
interface ITest extends IRunnable {
parent: ISuite;
pending: boolean;
fullTitle(): string;
}
/** Partial interface for Mocha's `Runner` class. */
interface IRunner {}
interface IContextDefinition {
(description: string, spec: () => void): ISuite;
only(description: string, spec: () => void): ISuite;
skip(description: string, spec: () => void): void;
timeout(ms: number): void;
}
interface ITestDefinition {
(expectation: string, assertion?: () => void): ITest;
(expectation: string, assertion?: (done: MochaDone) => void): ITest;
only(expectation: string, assertion?: () => void): ITest;
only(expectation: string, assertion?: (done: MochaDone) => void): ITest;
skip(expectation: string, assertion?: () => void): void;
skip(expectation: string, assertion?: (done: MochaDone) => void): void;
timeout(ms: number): void;
}
export module reporters {
export class Base {
stats: {
suites: number;
tests: number;
passes: number;
pending: number;
failures: number;
};
constructor(runner: IRunner);
}
export class Doc extends Base {}
export class Dot extends Base {}
export class HTML extends Base {}
export class HTMLCov extends Base {}
export class JSON extends Base {}
export class JSONCov extends Base {}
export class JSONStream extends Base {}
export class Landing extends Base {}
export class List extends Base {}
export class Markdown extends Base {}
export class Min extends Base {}
export class Nyan extends Base {}
export class Progress extends Base {
/**
* @param options.open String used to indicate the start of the progress bar.
* @param options.complete String used to indicate a complete test on the progress bar.
* @param options.incomplete String used to indicate an incomplete test on the progress bar.
* @param options.close String used to indicate the end of the progress bar.
*/
constructor(runner: IRunner, options?: {
open?: string;
complete?: string;
incomplete?: string;
close?: string;
});
}
export class Spec extends Base {}
export class TAP extends Base {}
export class XUnit extends Base {
constructor(runner: IRunner, options?: any);
}
}
}
declare module "mocha" {
export = Mocha;
}

@ -1,8 +0,0 @@
{
"resolution": "main",
"tree": {
"src": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/86bb15f6b9a3515bd9b3ca61f2a670533ac6b908/mocha/mocha.d.ts",
"raw": "github:DefinitelyTyped/DefinitelyTyped/mocha/mocha.d.ts#86bb15f6b9a3515bd9b3ca61f2a670533ac6b908",
"typings": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/86bb15f6b9a3515bd9b3ca61f2a670533ac6b908/mocha/mocha.d.ts"
}
}

@ -1,675 +0,0 @@
// Generated by typings
// Source: https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/bcd5761826eb567876c197ccc6a87c4d05731054/moment/moment-node.d.ts
declare module moment {
type MomentComparable = Moment | string | number | Date | number[];
interface MomentDateObject {
years?: number;
/* One digit */
months?: number;
/* Day of the month */
date?: number;
hours?: number;
minutes?: number;
seconds?: number;
milliseconds?: number;
}
interface MomentInput {
/** Year */
years?: number;
/** Year */
year?: number;
/** Year */
y?: number;
/** Month */
months?: number;
/** Month */
month?: number;
/** Month */
M?: number;
/** Week */
weeks?: number;
/** Week */
week?: number;
/** Week */
w?: number;
/** Day/Date */
days?: number;
/** Day/Date */
day?: number;
/** Day/Date */
date?: number;
/** Day/Date */
d?: number;
/** Hour */
hours?: number;
/** Hour */
hour?: number;
/** Hour */
h?: number;
/** Minute */
minutes?: number;
/** Minute */
minute?: number;
/** Minute */
m?: number;
/** Second */
seconds?: number;
/** Second */
second?: number;
/** Second */
s?: number;
/** Millisecond */
milliseconds?: number;
/** Millisecond */
millisecond?: number;
/** Millisecond */
ms?: number;
}
interface Duration {
humanize(withSuffix?: boolean): string;
as(units: string): number;
milliseconds(): number;
asMilliseconds(): number;
seconds(): number;
asSeconds(): number;
minutes(): number;
asMinutes(): number;
hours(): number;
asHours(): number;
days(): number;
asDays(): number;
weeks(): number;
asWeeks(): number;
months(): number;
asMonths(): number;
years(): number;
asYears(): number;
add(n: number, p: string): Duration;
add(n: number): Duration;
add(d: Duration): Duration;
subtract(n: number, p: string): Duration;
subtract(n: number): Duration;
subtract(d: Duration): Duration;
toISOString(): string;
toJSON(): string;
}
interface MomentLocale {
ordinal(n: number): string;
}
interface MomentCreationData {
input?: string;
format?: string;
locale: MomentLocale;
isUTC: boolean;
strict?: boolean;
}
interface Moment {
format(format: string): string;
format(): string;
fromNow(withoutSuffix?: boolean): string;
startOf(unitOfTime: string): Moment;
endOf(unitOfTime: string): Moment;
/**
* Mutates the original moment by adding time. (deprecated in 2.8.0)
*
* @param unitOfTime the unit of time you want to add (eg "years" / "hours" etc)
* @param amount the amount you want to add
*/
add(unitOfTime: string, amount: number): Moment;
/**
* Mutates the original moment by adding time.
*
* @param amount the amount you want to add
* @param unitOfTime the unit of time you want to add (eg "years" / "hours" etc)
*/
add(amount: number, unitOfTime: string): Moment;
/**
* Mutates the original moment by adding time. Note that the order of arguments can be flipped.
*
* @param amount the amount you want to add
* @param unitOfTime the unit of time you want to add (eg "years" / "hours" etc)
*/
add(amount: string, unitOfTime: string): Moment;
/**
* Mutates the original moment by adding time.
*
* @param objectLiteral an object literal that describes multiple time units {days:7,months:1}
*/
add(objectLiteral: MomentInput): Moment;
/**
* Mutates the original moment by adding time.
*
* @param duration a length of time
*/
add(duration: Duration): Moment;
/**
* Mutates the original moment by subtracting time. (deprecated in 2.8.0)
*
* @param unitOfTime the unit of time you want to subtract (eg "years" / "hours" etc)
* @param amount the amount you want to subtract
*/
subtract(unitOfTime: string, amount: number): Moment;
/**
* Mutates the original moment by subtracting time.
*
* @param unitOfTime the unit of time you want to subtract (eg "years" / "hours" etc)
* @param amount the amount you want to subtract
*/
subtract(amount: number, unitOfTime: string): Moment;
/**
* Mutates the original moment by subtracting time. Note that the order of arguments can be flipped.
*
* @param amount the amount you want to add
* @param unitOfTime the unit of time you want to subtract (eg "years" / "hours" etc)
*/
subtract(amount: string, unitOfTime: string): Moment;
/**
* Mutates the original moment by subtracting time.
*
* @param objectLiteral an object literal that describes multiple time units {days:7,months:1}
*/
subtract(objectLiteral: MomentInput): Moment;
/**
* Mutates the original moment by subtracting time.
*
* @param duration a length of time
*/
subtract(duration: Duration): Moment;
calendar(): string;
calendar(start: Moment): string;
calendar(start: Moment, formats: MomentCalendar): string;
clone(): Moment;
/**
* @return Unix timestamp, or milliseconds since the epoch.
*/
valueOf(): number;
local(): Moment; // current date/time in local mode
utc(): Moment; // current date/time in UTC mode
isValid(): boolean;
invalidAt(): number;
year(y: number): Moment;
year(): number;
quarter(): number;
quarter(q: number): Moment;
month(M: number): Moment;
month(M: string): Moment;
month(): number;
day(d: number): Moment;
day(d: string): Moment;
day(): number;
date(d: number): Moment;
date(): number;
hour(h: number): Moment;
hour(): number;
hours(h: number): Moment;
hours(): number;
minute(m: number): Moment;
minute(): number;
minutes(m: number): Moment;
minutes(): number;
second(s: number): Moment;
second(): number;
seconds(s: number): Moment;
seconds(): number;
millisecond(ms: number): Moment;
millisecond(): number;
milliseconds(ms: number): Moment;
milliseconds(): number;
weekday(): number;
weekday(d: number): Moment;
isoWeekday(): number;
isoWeekday(d: number): Moment;
weekYear(): number;
weekYear(d: number): Moment;
isoWeekYear(): number;
isoWeekYear(d: number): Moment;
week(): number;
week(d: number): Moment;
weeks(): number;
weeks(d: number): Moment;
isoWeek(): number;
isoWeek(d: number): Moment;
isoWeeks(): number;
isoWeeks(d: number): Moment;
weeksInYear(): number;
isoWeeksInYear(): number;
dayOfYear(): number;
dayOfYear(d: number): Moment;
from(f: MomentComparable, suffix?: boolean): string;
to(f: MomentComparable, suffix?: boolean): string;
toNow(withoutPrefix?: boolean): string;
diff(b: Moment): number;
diff(b: Moment, unitOfTime: string): number;
diff(b: Moment, unitOfTime: string, round: boolean): number;
toArray(): number[];
toDate(): Date;
toISOString(): string;
toJSON(): string;
unix(): number;
isLeapYear(): boolean;
zone(): number;
zone(b: number): Moment;
zone(b: string): Moment;
utcOffset(): number;
utcOffset(b: number): Moment;
utcOffset(b: string): Moment;
daysInMonth(): number;
isDST(): boolean;
isBefore(): boolean;
isBefore(b: MomentComparable, granularity?: string): boolean;
isAfter(): boolean;
isAfter(b: MomentComparable, granularity?: string): boolean;
isSame(b: MomentComparable, granularity?: string): boolean;
isBetween(a: MomentComparable, b: MomentComparable, granularity?: string): boolean;
/**
* @since 2.10.7+
*/
isSameOrBefore(b: MomentComparable, granularity?: string): boolean;
isSameOrAfter(b: MomentComparable, granularity?: string): boolean;
/**
* @deprecated since version 2.8.0
*/
lang(language: string): Moment;
lang(reset: boolean): Moment;
lang(): MomentLanguage;
locale(language: string): Moment;
locale(reset: boolean): Moment;
locale(): string;
localeData(language: string): Moment;
localeData(reset: boolean): Moment;
localeData(): MomentLanguage;
/**
* @deprecated since version 2.7.0
*/
max(date: Moment | string | number | Date | any[]): Moment;
max(date: string, format: string): Moment;
/**
* @deprecated since version 2.7.0
*/
min(date: Moment | string | number | Date | any[]): Moment;
min(date: string, format: string): Moment;
get(unit: string): number;
set(unit: string, value: number): Moment;
set(objectLiteral: MomentInput): Moment;
/**
* This returns an object containing year, month, day-of-month, hour, minute, seconds, milliseconds.
* @since 2.10.5+
*/
toObject(): MomentDateObject;
/**
* @since 2.10.7+
*/
creationData(): MomentCreationData;
}
type formatFunction = () => string;
interface MomentCalendar {
lastDay?: string | formatFunction;
sameDay?: string | formatFunction;
nextDay?: string | formatFunction;
lastWeek?: string | formatFunction;
nextWeek?: string | formatFunction;
sameElse?: string | formatFunction;
}
interface BaseMomentLanguage {
months?: any;
monthsShort?: any;
weekdays?: any;
weekdaysShort?: any;
weekdaysMin?: any;
relativeTime?: MomentRelativeTime;
meridiem?: (hour: number, minute: number, isLowercase: boolean) => string;
calendar?: MomentCalendar;
ordinal?: (num: number) => string;
}
interface MomentLanguage extends BaseMomentLanguage {
longDateFormat?: MomentLongDateFormat;
}
interface MomentLanguageData {
/**
* Get the full localized month name of a moment object
* @param {Moment} aMoment a moment object
* @return {string} full month name
*/
months(aMoment: Moment): string;
/**
* Get the short localized month name of a moment object
* @param {Moment} aMoment a moment object
* @return {string} short month name
*/
monthsShort(aMoment: Moment): string;
/**
* Parses a month name and returns the month id (0-11)
* @param {string} longOrShortMonthString string of month to parse
* @return {number} month id (0 to 11) of input
*/
monthsParse(longOrShortMonthString: string): number;
/**
* Gets the full weekday name of a moment object (eg. Monday)
* @param {Moment} aMoment a moment object
* @return {string} full weekday name
*/
weekdays(aMoment: Moment): string;
/**
* Gets the short weekday name of a moment object (eg. Mon)
* @param {Moment} aMoment a moment object
* @return {string} short weekday name
*/
weekdaysShort(aMoment: Moment): string;
/**
* Gets the min weekday name of a moment object (eg. Mo)
* @param {Moment} aMoment a moment object
* @return {string} min weekday name
*/
weekdaysMin(aMoment: Moment): string;
/**
* Parses a weekday name and returns the weekday id (0-6)
* @param {string} longOrShortMonthString string of weekday to parse
* @return {number} weekday id (0 to 6) of input
*/
weekdaysParse(longOrShortMonthString: string): number;
/**
* Returns the full format of abbreviated date-time formats
* @param {string} dateFormat date-time format such as LT, L, LL and so on
* @return {string} full date format string
*/
longDateFormat(dateFormat: string): string;
/**
* Returns whether a string represents PM
* @param {string} amPmString date string to check
* @return {boolean} true if string represents PM
*/
isPM(amPmString: string): boolean;
/**
* Returns am/pm string for particular time-of-day in upper/lower case
* @param {number} hour hour
* @param {number} minute minute
* @param {boolean} isLowercase whether to return in lowercase
* @return {string} 'am' or 'pm'
*/
meridiem(hour: number, minute: number, isLowercase: boolean): string;
/**
* Returns a format that would be used for calendar representation.
* @param {string} key one of 'sameDay', 'nextDay', 'lastDay', 'nextWeek', 'prevWeek', 'sameElse'
* @param {Moment} aMoment a moment object
* @return {string} date format string
*/
calendar(key: string, aMoment: Moment): string;
/**
* Returns relative time string (eg. a year ago)
* @param {number} number the relative number
* @param {boolean} withoutSuffix whether to drop the suffix
* @param {string} key one of 's', 'm', 'mm', 'h', 'hh', 'd', 'dd', 'M', 'MM', 'y', 'yy'. Single letter when number is 1.
* @param {boolean} isFuture whether this represents a future date
* @return {string} humanized representation of relative time
*/
relativeTime(number: number, withoutSuffix: boolean, key: string, isFuture: boolean): string;
/**
* Converts relative time string to past or future string depending on difference
* @param {number} diff positive or negative number
* @param {string} relTime relative time string
* @return {string} humanized representation of relative time
*/
pastFuture(diff: number, relTime: string): string;
/**
* Convert number to ordinal string 1 -> 1st
* @param {number} number the number
* @return {string} ordinal string
*/
ordinal(number: number): string;
/**
* Called before parsing every input string
*/
preparse(str: string): string;
/**
* Called after formatting on every string
*/
postformat(str: string): string;
/**
* Returns week-of-year of a moment object
* @param {Moment} aMoment a moment object
* @return {number} number of the week
*/
week(aMoment: Moment): number;
/**
* Returns a translation of 'Invalid date'
* @return {string} translation of 'Invalid date'
*/
invalidDate(): string;
/**
* Returns the first day of the week (0-6, Sunday to Saturday)
* @return {number} first day of the week
*/
firstDayOfWeek(): number;
/**
* This and the first day of week are used to determine which is
* the first week of the year. dow == 1 and doy == 4 means week starts
* Monday and first week that has Thursday is the first week of the
* year (but doy is NOT simply Thursday).
* @return {number} number between 0-15
*/
firstDayOfYear(): number;
}
interface MomentLongDateFormat {
L: string;
LL: string;
LLL: string;
LLLL: string;
LT: string;
LTS: string;
l?: string;
ll?: string;
lll?: string;
llll?: string;
lt?: string;
lts?: string;
}
interface MomentRelativeTime {
future: any;
past: any;
s: any;
m: any;
mm: any;
h: any;
hh: any;
d: any;
dd: any;
M: any;
MM: any;
y: any;
yy: any;
}
interface MomentStatic {
version: string;
fn: Moment;
(): Moment;
(date: number): Moment;
(date: number[]): Moment;
(date: string, format?: string, strict?: boolean): Moment;
(date: string, format?: string, language?: string, strict?: boolean): Moment;
(date: string, formats: string[], strict?: boolean): Moment;
(date: string, formats: string[], language?: string, strict?: boolean): Moment;
(date: string, specialFormat: () => void, strict?: boolean): Moment;
(date: string, specialFormat: () => void, language?: string, strict?: boolean): Moment;
(date: string, formatsIncludingSpecial: any[], strict?: boolean): Moment;
(date: string, formatsIncludingSpecial: any[], language?: string, strict?: boolean): Moment;
(date: Date): Moment;
(date: Moment): Moment;
(date: Object): Moment;
utc(): Moment;
utc(date: number): Moment;
utc(date: number[]): Moment;
utc(date: string, format?: string, strict?: boolean): Moment;
utc(date: string, format?: string, language?: string, strict?: boolean): Moment;
utc(date: string, formats: string[], strict?: boolean): Moment;
utc(date: string, formats: string[], language?: string, strict?: boolean): Moment;
utc(date: Date): Moment;
utc(date: Moment): Moment;
utc(date: Object): Moment;
unix(timestamp: number): Moment;
invalid(parsingFlags?: Object): Moment;
isMoment(): boolean;
isMoment(m: any): boolean;
isDate(m: any): boolean;
isDuration(): boolean;
isDuration(d: any): boolean;
/**
* @deprecated since version 2.8.0
*/
lang(language?: string): string;
lang(language?: string, definition?: MomentLanguage): string;
locale(language?: string): string;
locale(language?: string[]): string;
locale(language?: string, definition?: MomentLanguage): string;
localeData(language?: string): MomentLanguageData;
longDateFormat: any;
relativeTime: any;
meridiem: (hour: number, minute: number, isLowercase: boolean) => string;
calendar: any;
ordinal: (num: number) => string;
duration(milliseconds: Number): Duration;
duration(num: Number, unitOfTime: string): Duration;
duration(input: MomentInput): Duration;
duration(object: any): Duration;
duration(): Duration;
parseZone(date: string): Moment;
months(): string[];
months(index: number): string;
months(format: string): string[];
months(format: string, index: number): string;
monthsShort(): string[];
monthsShort(index: number): string;
monthsShort(format: string): string[];
monthsShort(format: string, index: number): string;
weekdays(): string[];
weekdays(index: number): string;
weekdays(format: string): string[];
weekdays(format: string, index: number): string;
weekdaysShort(): string[];
weekdaysShort(index: number): string;
weekdaysShort(format: string): string[];
weekdaysShort(format: string, index: number): string;
weekdaysMin(): string[];
weekdaysMin(index: number): string;
weekdaysMin(format: string): string[];
weekdaysMin(format: string, index: number): string;
min(...moments: Moment[]): Moment;
min(moments: Moment[]): Moment;
max(...moments: Moment[]): Moment;
max(moments: Moment[]): Moment;
normalizeUnits(unit: string): string;
relativeTimeThreshold(threshold: string): number | boolean;
relativeTimeThreshold(threshold: string, limit: number): boolean;
/**
* @since 2.10.7+
*/
now(): number;
/**
* Constant used to enable explicit ISO_8601 format parsing.
*/
ISO_8601(): void;
defaultFormat: string;
}
}
declare module 'moment' {
var moment: moment.MomentStatic;
export = moment;
}

@ -1,8 +0,0 @@
{
"resolution": "main",
"tree": {
"src": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/bcd5761826eb567876c197ccc6a87c4d05731054/moment/moment-node.d.ts",
"raw": "github:DefinitelyTyped/DefinitelyTyped/moment/moment-node.d.ts#bcd5761826eb567876c197ccc6a87c4d05731054",
"typings": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/bcd5761826eb567876c197ccc6a87c4d05731054/moment/moment-node.d.ts"
}
}

@ -1,3 +0,0 @@
// Generated by typings
// Source: https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/bcd5761826eb567876c197ccc6a87c4d05731054/moment/moment.d.ts
declare var moment: moment.MomentStatic;

@ -1,8 +0,0 @@
{
"resolution": "main",
"tree": {
"src": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/bcd5761826eb567876c197ccc6a87c4d05731054/moment/moment.d.ts",
"raw": "github:DefinitelyTyped/DefinitelyTyped/moment/moment.d.ts#bcd5761826eb567876c197ccc6a87c4d05731054",
"typings": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/bcd5761826eb567876c197ccc6a87c4d05731054/moment/moment.d.ts"
}
}

@ -1,29 +0,0 @@
// Generated by typings
// Source: https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/347311a5f0c374a05b43b98286933ccc03542f8b/mousetrap/index.d.ts
interface ExtendedKeyboardEvent extends KeyboardEvent {
returnValue: boolean; // IE returnValue
}
interface MousetrapStatic {
(el: Element): MousetrapInstance;
new (el: Element): MousetrapInstance;
stopCallback: (e: ExtendedKeyboardEvent, element: Element, combo: string) => boolean;
bind(keys: string|string[], callback: (e: ExtendedKeyboardEvent, combo: string) => any, action?: string): void;
unbind(keys: string|string[], action?: string): void;
trigger(keys: string, action?: string): void;
reset(): void;
}
interface MousetrapInstance {
stopCallback: (e: ExtendedKeyboardEvent, element: Element, combo: string) => boolean;
bind(keys: string|string[], callback: (e: ExtendedKeyboardEvent, combo: string) => any, action?: string): void;
unbind(keys: string|string[], action?: string): void;
trigger(keys: string, action?: string): void;
reset(): void;
}
declare var Mousetrap: MousetrapStatic;
declare module "mousetrap" {
export = Mousetrap;
}

@ -1,8 +0,0 @@
{
"resolution": "main",
"tree": {
"src": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/347311a5f0c374a05b43b98286933ccc03542f8b/mousetrap/index.d.ts",
"raw": "registry:dt/mousetrap#1.5.0+20160725212620",
"typings": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/347311a5f0c374a05b43b98286933ccc03542f8b/mousetrap/index.d.ts"
}
}

@ -1,252 +0,0 @@
// Generated by typings
// Source: https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/32f2a3b467d9ec6efb23b9db4a4501e24c661da1/ng-dialog/ng-dialog.d.ts
declare module "ng-dialog" {
export type IDialogService = angular.dialog.IDialogService;
export type IDialogOpenResult = angular.dialog.IDialogOpenResult;
export type IDialogClosePromise = angular.dialog.IDialogClosePromise;
export type IDialogProvider = angular.dialog.IDialogProvider;
export type IDialogScope = angular.dialog.IDialogScope;
export type IDialogConfirmScope = angular.dialog.IDialogConfirmScope;
export type IDialogOptions = angular.dialog.IDialogOptions;
export type IDialogOpenOptions = angular.dialog.IDialogOpenOptions;
export type IDialogOpenConfirmOptions = angular.dialog.IDialogOpenConfirmOptions;
}
declare namespace angular.dialog {
interface IDialogService {
getDefaults(): IDialogOptions;
open(options: IDialogOpenOptions): IDialogOpenResult;
openConfirm(options: IDialogOpenConfirmOptions): IPromise<any>;
/**
* Determine whether the specified dialog is open or not.
* @param id Dialog id to check for.
* @returns {boolean} Indicating whether it exists or not.
*/
isOpen(id: string): boolean;
close(id: string, value?: any): void;
closeAll(value?: any): void;
getOpenDialogs(): string[];
}
interface IDialogOpenResult {
id: string;
close: (value?: any) => void;
closePromise: IPromise<IDialogClosePromise>;
}
interface IDialogClosePromise {
id: string;
value: any;
}
interface IDialogProvider extends angular.IServiceProvider {
/**
* Default options for the dialogs.
* @param defaultOptions
* @returns {}
*/
setDefaults(defaultOptions: IDialogOptions): void;
/**
* Adds an additional listener on every $locationChangeSuccess event and gets update version of html into dialog.
* May be useful in some rare cases when you're dependant on DOM changes, defaults to false.
* @param {boolean} force
*/
setForceHtmlReload(force: boolean) : void;
/**
* Adds additional listener on every $locationChangeSuccess event and gets updated version of body into dialog.
* Maybe useful in some rare cases when you're dependant on DOM changes, defaults to false. Use it in module's
* config as provider instance:
* @param {boolean} force
*/
setForceBodyReload(force: boolean) : void;
}
/**
* Dialog Scope which extends the $scope.
*/
interface IDialogScope extends angular.IScope {
/**
* This allows you to close dialog straight from handler in a popup element.
* @param value Any value passed to this function will be attached to the object which resolves on the close promise for this dialog.
* For dialogs opened with the openConfirm() method the value is used as the reject reason.
*/
closeThisDialog(value?: any): void;
/**
* Any serializable data that you want to be stored in the controller's dialog scope.
* From version 0.3.6 $scope.ngDialogData keeps references to the objects instead of copying them.
*/
ngDialogData : string | {} | any[];
/**
* The id of the dialog. If you you ngDialogData, it'll be also available under ngDialogData.ngDialogId
*/
ngDialogId : string;
}
interface IDialogConfirmScope extends IDialogScope {
/**
* Use this method to close the dialog and resolve the promise that was returned when opening the modal.
*
* The function accepts a single optional parameter which is used as the value of the resolved promise.
* @param {any} [value] - The value with which the promise will resolve
*/
confirm(value?:any) : void;
}
interface IDialogOptions {
/**
* This option allows you to control the dialog's look, you can use built-in themes or create your own styled modals.
* It will be appended with the "ngdialog" class e.g. className is "default-theme flat-ui" it will be class="ngdialog default-theme flat-ui".
*/
className?: string;
/**
* If true then animation for the dialog will be disabled, default false.
*/
disableAnimation?: boolean;
/**
* If false it allows to hide overlay div behind the modals, default true.
*/
overlay?: boolean;
/**
* If false it allows to hide close button on modals, default true.
*/
showClose?: boolean;
/**
* It allows to close modals by clicking Esc button, default true.
* This will close all open modals if there several of them open at the same time.
*/
closeByEscape?: boolean;
/**
* It allows to close modals by clicking on overlay background, default true. If @see Hammer.js is loaded, it will listen for tap instead of click.
*/
closeByDocument?: boolean;
/**
* Listens for $locationChangeSuccess event and closes open dialogs if true (also handles the ui.router $stateChangeSuccess event if ui.router is used)
* default : false
*/
closeByNavigation?: boolean;
/**
* If true allows to use plain string as template, default false.
*/
plain?: boolean;
/**
* Give a name for a dialog instance. It is useful for identifying specific dialog if there are multiple dialog boxes opened.
*/
name?: string | number;
/**
* Provide either the name of a function or a function to be called before the dialog is closed.
* If the callback function specified in the option returns false then the dialog will not be closed.
* Alternatively, if the callback function returns a promise that gets resolved the dialog will be closed.
*
* more: https://github.com/likeastore/ngDialog#preclosecallback-string--function
*/
preCloseCallback?: string|Function;
/**
* Pass false to disable template caching. Useful for developing purposes, default is true.
*/
cache?: boolean;
/**
* Specify your element where to append dialog instance, accepts selector string (e.g. #yourId, .yourClass).
* If not specified appends dialog to body as default behavior.
*/
appendTo?: string;
/**
* When true, ensures that the focused element remains within the dialog to conform to accessibility recommendations.
* Default value is true
*/
trapFocus?: boolean;
/**
* When true, closing the dialog restores focus to the element that launched it. Designed to improve keyboard
* accessibility. Default value is true
*/
preserveFocus?: boolean;
/**
* When true, automatically selects appropriate values for any unspecified accessibility attributes. Default value is true
*/
ariaAuto? : boolean;
/**
* Specifies the value for the role attribute that should be applied to the dialog element. Default value is null (unspecified)
*/
ariaRole?: string;
/**
* Specifies the value for the aria-labelledby attribute that should be applied to the dialog element.
* Default value is null (unspecified)
*
* If specified, the value is not validated against the DOM
*/
ariaLabelledById?: string;
/**
* Specifies the CSS selector for the element to be referenced by the aria-labelledby attribute on the dialog element. Default value is null (unspecified)
*
* If specified, the first matching element is used.
*/
ariaLabelledBySelector?: string;
/**
* Specifies the value for the aria-describedby attribute that should be applied to the dialog element. Default value is null (unspecified)
*
* If specified, the value is not validated against the DOM.
*/
ariaDescribedById?: string;
/**
* Specifies the CSS selector for the element to be referenced by the aria-describedby attribute on the dialog element. Default value is null (unspecified)
*
* If specified, the first matching element is used.
*/
ariaDescribedBySelector?: string;
}
/**
* Options which are provided to open a dialog.
*/
interface IDialogOpenOptions extends IDialogOptions {
template: string;
controller?: string| any[] | any;
controllerAs?: string;
/**
* Scope object that will be passed to dialog. If you use controller with separate $scope service this object will be passed to $scope.$parent param.
*/
scope?: IDialogScope;
/**
* An optional map of dependencies which should be injected into the controller. If any of these dependencies
* are promises, ngDialog will wait for them all to be resolved or one to be rejected before the controller
* is instantiated.
*/
resolve?: {[key : string] : string | Function};
/**
* Any serializable data that you want to be stored in the controller's dialog scope. ($scope.ngDialogData).
* From version 0.3.6 $scope.ngDialogData keeps references to the objects instead of copying them.
*/
data?: string | {} | any[];
}
interface IDialogOpenConfirmOptions extends IDialogOpenOptions {
scope?: IDialogConfirmScope;
}
}

@ -1,8 +0,0 @@
{
"resolution": "main",
"tree": {
"src": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/32f2a3b467d9ec6efb23b9db4a4501e24c661da1/ng-dialog/ng-dialog.d.ts",
"raw": "registry:dt/ng-dialog#0.0.0+20160423145208",
"typings": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/32f2a3b467d9ec6efb23b9db4a4501e24c661da1/ng-dialog/ng-dialog.d.ts"
}
}

@ -1,176 +0,0 @@
// Generated by typings
// Source: https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/92b2c03c297b8c5c7c2c7e169134da61f8abee6a/nouislider/nouislider.d.ts
declare namespace noUiSlider {
/**
* To create a slider, call noUiSlider.create() with an element and your options.
*/
function create(target: HTMLElement, options: Options): void;
interface Options {
/**
* The start option sets the number of handles and their start positions, relative to range.
*/
start: number | number[] | number[][];
/**
* The connect setting can be used to control the bar between the handles,
* or the edges of the slider. Use "lower" to connect to the lower side,
* or "upper" to connect to the upper side. Setting true sets the bar between the handles.
*/
range: Object;
/**
* noUiSlider offers several ways to handle user interaction.
* The range can be set to drag, and handles can move to taps.
* All these effects are optional, and can be enable by adding their keyword to the behaviour option.
* This option accepts a "-" separated list of "drag", "tap", "fixed", "snap" or "none".
*/
connect?: string | boolean;
/**
* When using two handles, the minimum distance between the handles can be set using the margin option.
* The margin value is relative to the value set in 'range'.
* This option is only available on standard linear sliders.
*/
margin?: number;
/**
* The limit option is the oposite of the margin option,
* limiting the maximum distance between two handles.
* As with the margin option, the limit option can only be used on linear sliders.
*/
limit?: number;
/**
* By default, the slider slides fluently.
* In order to make the handles jump between intervals, you can use this option.
* The step option is relative to the values provided to range.
*/
step?: number;
/**
* The orientation setting can be used to set the slider to "vertical" or "horizontal".
* Set dimensions! Vertical sliders don't assume a default height, so you'll need to set one.
* You can use any unit you want, including % or px.
*/
orientation?: string;
/**
* By default the sliders are top-to-bottom and left-to-right,
* but you can change this using the direction option,
* which decides where the upper side of the slider is.
*/
direction?: string;
/**
* Set the animate option to false to prevent the slider from animating to a new value with when calling .val().
*/
animate?: boolean;
/**
* All values on the slider are part of a range. The range has a minimum and maximum value.
*/
behaviour?: string;
/**
* To format the slider output, noUiSlider offers a format option.
* Simply specify to and from functions to encode and decode the values.
* See manual formatting to the right for usage information.
* By default, noUiSlider will format output with 2 decimals.
*/
format?: Object | ((...args:any[]) => any);
/**
* Allows you to generate points along the slider.
*/
pips?: PipsOptions;
}
interface PipsOptions {
/**
* The 'range' mode uses the slider range to determine where the pips should be. A pip is generated for every percentage specified.
*
* The 'steps', like 'range', uses the slider range. In steps mode, a pip is generated for every step.
* The 'filter' option can be used to filter the generated pips from the 'steps' options'
* The filter function must return 0 (no value), 1 (large value) or 2 (small value).
*
* In 'positions' mode, pips are generated at percentage-based positions on the slider.
* Optionally, the stepped option can be set to true to match the pips to the slider steps.
*
* The 'count' mode can be used to generate a fixed number of pips. As with positions mode, the stepped option can be used.
*
* The 'values' mode is similar to positions, but it accepts values instead of percentages. The stepped option can be used for this mode.
*
*/
mode: string; // "range" | "steps" | "positions" | "count" | "values"
/**
* Range Mode: percentage for range mode
* Step Mode: step number for steps
* Positions Mode: percentage-based positions on the slider
* Count Mode: positions between pips
*/
density?: number;
/**
* Step Mode: The filter option can be used to filter the generated pips.
* The filter function must return 0 (no value), 1 (large value) or 2 (small value).
*/
filter?: (...args: any[]) => PipFilterResult;
/**
* format for step mode
* see noUiSlider format
*/
format?: Object;
/**
*
* values for positions and values mode
* number pips for count mode
*/
values?: number | number[];
/**
* stepped option for positions, values and count mode
*/
stepped?: boolean;
}
const enum PipFilterResult {
NoValue,
LargeValue,
SmallValue,
}
interface Callback {
/**
* Array for both one-handle and two-handle sliders. It contains the current slider values,
* with formatting applied.
*/
(values: any[], handle: number, unencoded: number): void
}
interface noUiSlider {
/**
* Bind event to the slider.
*/
on(eventName: string, callback: Callback): void;
/**
* Unbind event to the slider.
*/
off(eventName: string): void;
/**
* Destroy's the slider.
*/
destroy(): void;
/**
* To get the current slider value. For one-handle sliders, calling .get() will return the value.
* For two-handle sliders, an array[value, value] will be returned.
*/
get(): number | number[];
/**
* noUiSlider will keep your values within the slider range, which saves you a bunch of validation.
* If you have configured the slider to use one handle, you can change the current value by passing
* a number to the .set() method. If you have two handles, pass an array. One-handled sliders
* will also accept arrays. Within an array, you can set one position to null
* if you want to leave a handle unchanged.
*/
set(value: number | number[]): void;
}
interface Instance extends HTMLElement {
noUiSlider: noUiSlider
}
}
declare module "nouislider" {
export = noUiSlider;
}

@ -1,8 +0,0 @@
{
"resolution": "main",
"tree": {
"src": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/92b2c03c297b8c5c7c2c7e169134da61f8abee6a/nouislider/nouislider.d.ts",
"raw": "registry:dt/nouislider#8.0.2+20160412140110",
"typings": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/92b2c03c297b8c5c7c2c7e169134da61f8abee6a/nouislider/nouislider.d.ts"
}
}

@ -1,15 +0,0 @@
// Generated by typings
// Source: https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/86bb15f6b9a3515bd9b3ca61f2a670533ac6b908/promises-a-plus/promises-a-plus.d.ts
declare namespace PromisesAPlus {
interface PromiseCtor {
<T>(resolver: (resolvePromise: (value: T) => void, rejectPromise: (reason: any) => void) => void): Thenable<T>;
}
interface PromiseImpl {
new <T>(resolver: (resolvePromise: (value: T) => void, rejectPromise: (reason: any) => void) => void): Thenable<T>;
}
interface Thenable<T> {
then<R>(onFulfill?: (value: T) => Thenable<R>|R, onReject?: (error: any) => Thenable<R>|R): Thenable<R>;
}
}

@ -1,8 +0,0 @@
{
"resolution": "main",
"tree": {
"src": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/86bb15f6b9a3515bd9b3ca61f2a670533ac6b908/promises-a-plus/promises-a-plus.d.ts",
"raw": "github:DefinitelyTyped/DefinitelyTyped/promises-a-plus/promises-a-plus.d.ts#86bb15f6b9a3515bd9b3ca61f2a670533ac6b908",
"typings": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/86bb15f6b9a3515bd9b3ca61f2a670533ac6b908/promises-a-plus/promises-a-plus.d.ts"
}
}

@ -1,199 +0,0 @@
// Generated by typings
// Source: https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/7de6c3dd94feaeb21f20054b9f30d5dabc5efabd/rosie/rosie.d.ts
declare namespace rosie {
interface IFactoryStatic {
/**
* Defines a factory by name and constructor function. Call #attr and #option
* on the result to define the properties of this factory.
*
* @param {!string} name
* @param {function(object): *=} constructor
* @return {Factory}
*/
define(name: String, constructor?: Function): IFactory;
/**
* Locates a factory by name and calls #build on it.
*
* @param {string} name
* @param {object=} attributes
* @param {object=} options
* @return {*}
*/
build(name: string, attributes?: any, options?: Object): Object;
/**
* Builds a collection of objects using the named factory.
*
* @param {string} name
* @param {number} size
* @param {object=} attributes
* @param {object=} options
* @return {Array.<*>}
*/
buildList(name: string, size: number, attributes?: any, options?: Object): Object[];
/**
* Locates a factory by name and calls #attributes on it.
*
* @param {string} name
* @param {object} attributes
* @param {object} options
* @return {object}
*/
attributes(name: string, attributes: Object, options?: Object): Object;
}
interface IFactory {
/**
* Define an attribute on this factory. Attributes can optionally define a
* default value, either as a value (e.g. a string or number) or as a builder
* function. For example:
*
* // no default value for age
* Factory.define('Person').attr('age')
*
* // static default value for age
* Factory.define('Person').attr('age', 18)
*
* // dynamic default value for age
* Factory.define('Person').attr('age', function() {
* return Math.random() * 100;
* })
*
* Attributes with dynamic default values can depend on options or other
* attributes:
*
* Factory.define('Person').attr('age', ['name'], function(name) {
* return name === 'Brian' ? 30 : 18;
* });
*
* By default if the consumer of your factory provides a value for an
* attribute your builder function will not be called. You can override this
* behavior by declaring that your attribute depends on itself:
*
* Factory.define('Person').attr('spouse', ['spouse'], function(spouse) {
* return Factory.build('Person', spouse);
* });
*
* As in the example above, this can be a useful way to fill in
* partially-specified child objects.
*
* @param {string} attr
* @param {Array.<string>=} | any dependenciesOrValue
* @param any
* @return {Factory}
*/
attr(name: string, dependenciesOrValue: any | string[], value?: any): IFactory;
/**
* Define an option for this factory. Options are values that may inform
* dynamic attribute behavior but are not included in objects built by the
* factory. Like attributes, options may have dependencies. Unlike
* attributes, options may only depend on other options.
*
* Factory.define('Person')
* .option('includeRelationships', false)
* .attr(
* 'spouse',
* ['spouse', 'includeRelationships'],
* function(spouse, includeRelationships) {
* return includeRelationships ?
* Factory.build('Person', spouse) :
* null;
* });
*
* Factory.build('Person', null, { includeRelationships: true });
*
* Options may have either static or dynamic default values, just like
* attributes. Options without default values must have a value specified
* when building.
*
* @param {string} opt
* @param {Array.<string>=} | any dependencies or value
* @param {*=} value
* @return {Factory}
*/
option(name: string, dependenciesOrValue: any | string[], value?: any): IFactory;
/**
* Defines an attribute that, by default, simply has an auto-incrementing
* numeric value starting at 1. You can provide your own builder function
* that accepts the number of the sequence and returns whatever value you'd
* like it to be.
*
* Sequence values are inherited such that a factory derived from another
* with a sequence will share the state of that sequence and they will never
* conflict.
*
* Factory.define('Person').sequence('id');
*
* @param {string} attr
* @param {Array.<string>=} dependencies
* @param {function(number): *=} builder
* @return {Factory}
*/
sequence(name: string, dependencies?: string[], builder?: Function) : IFactory;
/**
* Sets a post-processor callback that will receive built objects and the
* options for the build just before they are returned from the #build
* function.
*
* @param {function(object, ?object)} callback
* @return {Factory}
*/
after(functionArg: Function): IFactory;
/**
* Sets the constructor for this factory to be another factory. This can be
* used to create more specific sub-types of factories.
*
* @param {Factory} parentFactory
* @return {Factory}
*/
inherits(functionArg: Function): IFactory;
/**
* Builds a plain object containing values for each of the declared
* attributes. The result of this is the same as the result when using #build
* when there is no constructor registered.
*
* @param {object=} attributes
* @param {object=} options
* @return {object}
*/
attributes(attributes:Object, options: Object): Object;
/**
* Generates values for all the registered options using the values given.
*
* @private
* @param {object} options
* @return {object}
*/
options(options: Object): Object;
/**
* Builds objects by getting values for all attributes and optionally passing
* the result to a constructor function.
*
* @param {object=} attributes
* @param {object=} options
* @return {*}
*/
build(attributes: Object, options: Object): Object;
buildList(size: number, attributes: Object, options: Object): Object[];
}
}
declare var rosie: { Factory: rosie.IFactoryStatic };
declare module 'rosie' {
export = rosie;
}

@ -1,8 +0,0 @@
{
"resolution": "main",
"tree": {
"src": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/7de6c3dd94feaeb21f20054b9f30d5dabc5efabd/rosie/rosie.d.ts",
"raw": "registry:dt/rosie#0.0.0+20160317120654",
"typings": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/7de6c3dd94feaeb21f20054b9f30d5dabc5efabd/rosie/rosie.d.ts"
}
}

@ -1,79 +0,0 @@
// Generated by typings
// Source: https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/7de6c3dd94feaeb21f20054b9f30d5dabc5efabd/sinon-chai/sinon-chai.d.ts
declare namespace Chai {
interface LanguageChains {
always: Assertion;
}
interface Assertion {
/**
* true if the spy was called at least once.
*/
called: Assertion;
/**
* @param count The number of recorded calls.
*/
callCount(count: number): Assertion;
/**
* true if the spy was called exactly once.
*/
calledOnce: Assertion;
/**
* true if the spy was called exactly twice.
*/
calledTwice: Assertion;
/**
* true if the spy was called exactly thrice.
*/
calledThrice: Assertion;
/**
* Returns true if the spy was called before anotherSpy.
*/
calledBefore(anotherSpy: Sinon.SinonSpy): Assertion;
/**
* Returns true if the spy was called after anotherSpy.
*/
calledAfter(anotherSpy: Sinon.SinonSpy): Assertion;
/**
* Returns true if spy/stub was called with the new operator. Beware that
* this is inferred based on the value of the this object and the spy
* function's prototype, so it may give false positives if you actively
* return the right kind of object.
*/
calledWithNew: Assertion;
/**
* Returns true if context was this for this call.
*/
calledOn(context: any): Assertion;
/**
* Returns true if call received provided arguments (and possibly others).
*/
calledWith(...args: any[]): Assertion;
/**
* Returns true if call received provided arguments and no others.
*/
calledWithExactly(...args: any[]): Assertion;
/**
* Returns true if call received matching arguments (and possibly others).
* This behaves the same as spyCall.calledWith(sinon.match(arg1), sinon.match(arg2), ...).
*/
calledWithMatch(...args: any[]): Assertion;
/**
* Returns true if spy returned the provided value at least once. Uses
* deep comparison for objects and arrays. Use spy.returned(sinon.match.same(obj))
* for strict comparison (see matchers).
*/
returned(obj: any): Assertion;
/**
* Returns true if spy threw the provided exception object at least once.
*/
thrown(obj?: Error|typeof Error|string): Assertion;
}
}
declare module "sinon-chai" {
function sinonChai(chai: any, utils: any): void;
namespace sinonChai { }
export = sinonChai;
}

@ -1,8 +0,0 @@
{
"resolution": "main",
"tree": {
"src": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/7de6c3dd94feaeb21f20054b9f30d5dabc5efabd/sinon-chai/sinon-chai.d.ts",
"raw": "registry:dt/sinon-chai#2.7.0+20160317120654",
"typings": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/7de6c3dd94feaeb21f20054b9f30d5dabc5efabd/sinon-chai/sinon-chai.d.ts"
}
}

@ -1,432 +0,0 @@
// Generated by typings
// Source: https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/40c60850ad6c8175a62d5ab48c4e016ea5b3dffe/sinon/sinon.d.ts
declare module Sinon {
interface SinonSpyCallApi {
// Properties
thisValue: any;
args: any[];
exception: any;
returnValue: any;
// Methods
calledOn(obj: any): boolean;
calledWith(...args: any[]): boolean;
calledWithExactly(...args: any[]): boolean;
calledWithMatch(...args: any[]): boolean;
notCalledWith(...args: any[]): boolean;
notCalledWithMatch(...args: any[]): boolean;
returned(value: any): boolean;
threw(): boolean;
threw(type: string): boolean;
threw(obj: any): boolean;
callArg(pos: number): void;
callArgOn(pos: number, obj: any, ...args: any[]): void;
callArgWith(pos: number, ...args: any[]): void;
callArgOnWith(pos: number, obj: any, ...args: any[]): void;
yield(...args: any[]): void;
yieldOn(obj: any, ...args: any[]): void;
yieldTo(property: string, ...args: any[]): void;
yieldToOn(property: string, obj: any, ...args: any[]): void;
}
interface SinonSpyCall extends SinonSpyCallApi {
calledBefore(call: SinonSpyCall): boolean;
calledAfter(call: SinonSpyCall): boolean;
calledWithNew(call: SinonSpyCall): boolean;
}
interface SinonSpy extends SinonSpyCallApi {
// Properties
callCount: number;
called: boolean;
notCalled: boolean;
calledOnce: boolean;
calledTwice: boolean;
calledThrice: boolean;
firstCall: SinonSpyCall;
secondCall: SinonSpyCall;
thirdCall: SinonSpyCall;
lastCall: SinonSpyCall;
thisValues: any[];
args: any[][];
exceptions: any[];
returnValues: any[];
// Methods
(...args: any[]): any;
calledBefore(anotherSpy: SinonSpy): boolean;
calledAfter(anotherSpy: SinonSpy): boolean;
calledWithNew(spy: SinonSpy): boolean;
withArgs(...args: any[]): SinonSpy;
alwaysCalledOn(obj: any): boolean;
alwaysCalledWith(...args: any[]): boolean;
alwaysCalledWithExactly(...args: any[]): boolean;
alwaysCalledWithMatch(...args: any[]): boolean;
neverCalledWith(...args: any[]): boolean;
neverCalledWithMatch(...args: any[]): boolean;
alwaysThrew(): boolean;
alwaysThrew(type: string): boolean;
alwaysThrew(obj: any): boolean;
alwaysReturned(): boolean;
invokeCallback(...args: any[]): void;
getCall(n: number): SinonSpyCall;
reset(): void;
printf(format: string, ...args: any[]): string;
restore(): void;
}
interface SinonSpyStatic {
(): SinonSpy;
(func: any): SinonSpy;
(obj: any, method: string): SinonSpy;
}
interface SinonStatic {
spy: SinonSpyStatic;
}
interface SinonStub extends SinonSpy {
resetBehavior(): void;
returns(obj: any): SinonStub;
returnsArg(index: number): SinonStub;
returnsThis(): SinonStub;
throws(type?: string): SinonStub;
throws(obj: any): SinonStub;
callsArg(index: number): SinonStub;
callsArgOn(index: number, context: any): SinonStub;
callsArgWith(index: number, ...args: any[]): SinonStub;
callsArgOnWith(index: number, context: any, ...args: any[]): SinonStub;
callsArgAsync(index: number): SinonStub;
callsArgOnAsync(index: number, context: any): SinonStub;
callsArgWithAsync(index: number, ...args: any[]): SinonStub;
callsArgOnWithAsync(index: number, context: any, ...args: any[]): SinonStub;
onCall(n: number): SinonStub;
onFirstCall(): SinonStub;
onSecondCall(): SinonStub;
onThirdCall(): SinonStub;
yields(...args: any[]): SinonStub;
yieldsOn(context: any, ...args: any[]): SinonStub;
yieldsTo(property: string, ...args: any[]): SinonStub;
yieldsToOn(property: string, context: any, ...args: any[]): SinonStub;
yieldsAsync(...args: any[]): SinonStub;
yieldsOnAsync(context: any, ...args: any[]): SinonStub;
yieldsToAsync(property: string, ...args: any[]): SinonStub;
yieldsToOnAsync(property: string, context: any, ...args: any[]): SinonStub;
withArgs(...args: any[]): SinonStub;
}
interface SinonStubStatic {
(): SinonStub;
(obj: any): SinonStub;
(obj: any, method: string): SinonStub;
(obj: any, method: string, func: any): SinonStub;
}
interface SinonStatic {
stub: SinonStubStatic;
}
interface SinonExpectation extends SinonStub {
atLeast(n: number): SinonExpectation;
atMost(n: number): SinonExpectation;
never(): SinonExpectation;
once(): SinonExpectation;
twice(): SinonExpectation;
thrice(): SinonExpectation;
exactly(n: number): SinonExpectation;
withArgs(...args: any[]): SinonExpectation;
withExactArgs(...args: any[]): SinonExpectation;
on(obj: any): SinonExpectation;
verify(): SinonExpectation;
restore(): void;
}
interface SinonExpectationStatic {
create(methodName?: string): SinonExpectation;
}
interface SinonMock {
expects(method: string): SinonExpectation;
restore(): void;
verify(): void;
}
interface SinonMockStatic {
(): SinonExpectation;
(obj: any): SinonMock;
}
interface SinonStatic {
expectation: SinonExpectationStatic;
mock: SinonMockStatic;
}
interface SinonFakeTimers {
now: number;
create(now: number): SinonFakeTimers;
setTimeout(callback: (...args: any[]) => void, timeout: number, ...args: any[]): number;
clearTimeout(id: number): void;
setInterval(callback: (...args: any[]) => void, timeout: number, ...args: any[]): number;
clearInterval(id: number): void;
tick(ms: number): number;
reset(): void;
Date(): Date;
Date(year: number): Date;
Date(year: number, month: number): Date;
Date(year: number, month: number, day: number): Date;
Date(year: number, month: number, day: number, hour: number): Date;
Date(year: number, month: number, day: number, hour: number, minute: number): Date;
Date(year: number, month: number, day: number, hour: number, minute: number, second: number): Date;
Date(year: number, month: number, day: number, hour: number, minute: number, second: number, ms: number): Date;
restore(): void;
/**
* Simulate the user changing the system clock while your program is running. It changes the 'now' timestamp
* without affecting timers, intervals or immediates.
* @param now The new 'now' in unix milliseconds
*/
setSystemTime(now: number): void;
/**
* Simulate the user changing the system clock while your program is running. It changes the 'now' timestamp
* without affecting timers, intervals or immediates.
* @param now The new 'now' as a JavaScript Date
*/
setSystemTime(date: Date): void;
}
interface SinonFakeTimersStatic {
(): SinonFakeTimers;
(...timers: string[]): SinonFakeTimers;
(now: number, ...timers: string[]): SinonFakeTimers;
}
interface SinonStatic {
useFakeTimers: SinonFakeTimersStatic;
clock: SinonFakeTimers;
}
interface SinonFakeUploadProgress {
eventListeners: {
progress: any[];
load: any[];
abort: any[];
error: any[];
};
addEventListener(event: string, listener: (e: Event) => any): void;
removeEventListener(event: string, listener: (e: Event) => any): void;
dispatchEvent(event: Event): void;
}
interface SinonFakeXMLHttpRequest {
// Properties
onCreate: (xhr: SinonFakeXMLHttpRequest) => void;
url: string;
method: string;
requestHeaders: any;
requestBody: string;
status: number;
statusText: string;
async: boolean;
username: string;
password: string;
withCredentials: boolean;
upload: SinonFakeUploadProgress;
responseXML: Document;
getResponseHeader(header: string): string;
getAllResponseHeaders(): any;
// Methods
restore(): void;
useFilters: boolean;
addFilter(filter: (method: string, url: string, async: boolean, username: string, password: string) => boolean): void;
setResponseHeaders(headers: any): void;
setResponseBody(body: string): void;
respond(status: number, headers: any, body: string): void;
autoRespond(ms: number): void;
}
interface SinonFakeXMLHttpRequestStatic {
(): SinonFakeXMLHttpRequest;
}
interface SinonStatic {
useFakeXMLHttpRequest: SinonFakeXMLHttpRequestStatic;
FakeXMLHttpRequest: SinonFakeXMLHttpRequest;
}
interface SinonFakeServer {
// Properties
autoRespond: boolean;
autoRespondAfter: number;
fakeHTTPMethods: boolean;
getHTTPMethod: (request: SinonFakeXMLHttpRequest) => string;
requests: SinonFakeXMLHttpRequest[];
respondImmediately: boolean;
// Methods
respondWith(body: string): void;
respondWith(response: any[]): void;
respondWith(fn: (xhr: SinonFakeXMLHttpRequest) => void): void;
respondWith(url: string, body: string): void;
respondWith(url: string, response: any[]): void;
respondWith(url: string, fn: (xhr: SinonFakeXMLHttpRequest) => void): void;
respondWith(method: string, url: string, body: string): void;
respondWith(method: string, url: string, response: any[]): void;
respondWith(method: string, url: string, fn: (xhr: SinonFakeXMLHttpRequest) => void): void;
respondWith(url: RegExp, body: string): void;
respondWith(url: RegExp, response: any[]): void;
respondWith(url: RegExp, fn: (xhr: SinonFakeXMLHttpRequest) => void): void;
respondWith(method: string, url: RegExp, body: string): void;
respondWith(method: string, url: RegExp, response: any[]): void;
respondWith(method: string, url: RegExp, fn: (xhr: SinonFakeXMLHttpRequest) => void): void;
respond(): void;
restore(): void;
}
interface SinonFakeServerStatic {
create(): SinonFakeServer;
}
interface SinonStatic {
fakeServer: SinonFakeServerStatic;
fakeServerWithClock: SinonFakeServerStatic;
}
interface SinonExposeOptions {
prefix?: string;
includeFail?: boolean;
}
interface SinonAssert {
// Properties
failException: string;
fail: (message?: string) => void; // Overridable
pass: (assertion: any) => void; // Overridable
// Methods
notCalled(spy: SinonSpy): void;
called(spy: SinonSpy): void;
calledOnce(spy: SinonSpy): void;
calledTwice(spy: SinonSpy): void;
calledThrice(spy: SinonSpy): void;
callCount(spy: SinonSpy, count: number): void;
callOrder(...spies: SinonSpy[]): void;
calledOn(spy: SinonSpy, obj: any): void;
alwaysCalledOn(spy: SinonSpy, obj: any): void;
calledWith(spy: SinonSpy, ...args: any[]): void;
alwaysCalledWith(spy: SinonSpy, ...args: any[]): void;
neverCalledWith(spy: SinonSpy, ...args: any[]): void;
calledWithExactly(spy: SinonSpy, ...args: any[]): void;
alwaysCalledWithExactly(spy: SinonSpy, ...args: any[]): void;
calledWithMatch(spy: SinonSpy, ...args: any[]): void;
alwaysCalledWithMatch(spy: SinonSpy, ...args: any[]): void;
neverCalledWithMatch(spy: SinonSpy, ...args: any[]): void;
threw(spy: SinonSpy): void;
threw(spy: SinonSpy, exception: string): void;
threw(spy: SinonSpy, exception: any): void;
alwaysThrew(spy: SinonSpy): void;
alwaysThrew(spy: SinonSpy, exception: string): void;
alwaysThrew(spy: SinonSpy, exception: any): void;
expose(obj: any, options?: SinonExposeOptions): void;
}
interface SinonStatic {
assert: SinonAssert;
}
interface SinonMatcher {
and(expr: SinonMatcher): SinonMatcher;
or(expr: SinonMatcher): SinonMatcher;
}
interface SinonMatch {
(value: number): SinonMatcher;
(value: string): SinonMatcher;
(expr: RegExp): SinonMatcher;
(obj: any): SinonMatcher;
(callback: (value: any) => boolean): SinonMatcher;
any: SinonMatcher;
defined: SinonMatcher;
truthy: SinonMatcher;
falsy: SinonMatcher;
bool: SinonMatcher;
number: SinonMatcher;
string: SinonMatcher;
object: SinonMatcher;
func: SinonMatcher;
array: SinonMatcher;
regexp: SinonMatcher;
date: SinonMatcher;
same(obj: any): SinonMatcher;
typeOf(type: string): SinonMatcher;
instanceOf(type: any): SinonMatcher;
has(property: string, expect?: any): SinonMatcher;
hasOwn(property: string, expect?: any): SinonMatcher;
}
interface SinonStatic {
match: SinonMatch;
}
interface SinonSandboxConfig {
injectInto?: any;
properties?: string[];
useFakeTimers?: any;
useFakeServer?: any;
}
interface SinonSandbox {
clock: SinonFakeTimers;
requests: SinonFakeXMLHttpRequest;
server: SinonFakeServer;
spy: SinonSpyStatic;
stub: SinonStubStatic;
mock: SinonMockStatic;
useFakeTimers: SinonFakeTimersStatic;
useFakeXMLHttpRequest: SinonFakeXMLHttpRequestStatic;
useFakeServer(): SinonFakeServer;
restore(): void;
}
interface SinonSandboxStatic {
create(): SinonSandbox;
create(config: SinonSandboxConfig): SinonSandbox;
}
interface SinonStatic {
sandbox: SinonSandboxStatic;
}
interface SinonTestConfig {
injectIntoThis?: boolean;
injectInto?: any;
properties?: string[];
useFakeTimers?: boolean;
useFakeServer?: boolean;
}
interface SinonTestWrapper extends SinonSandbox {
(...args: any[]): any;
}
interface SinonStatic {
config: SinonTestConfig;
test(fn: (...args: any[]) => any): SinonTestWrapper;
testCase(tests: any): any;
}
// Utility overridables
interface SinonStatic {
createStubInstance(constructor: any): SinonStub;
format(obj: any): string;
log(message: string): void;
restore(object: any): void;
}
}
declare var sinon: Sinon.SinonStatic;
declare module "sinon" {
export = sinon;
}

@ -1,8 +0,0 @@
{
"resolution": "main",
"tree": {
"src": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/40c60850ad6c8175a62d5ab48c4e016ea5b3dffe/sinon/sinon.d.ts",
"raw": "github:DefinitelyTyped/DefinitelyTyped/sinon/sinon.d.ts#40c60850ad6c8175a62d5ab48c4e016ea5b3dffe",
"typings": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/40c60850ad6c8175a62d5ab48c4e016ea5b3dffe/sinon/sinon.d.ts"
}
}

@ -1,242 +0,0 @@
// Generated by typings
// Source: https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/3e77642fd96ddef451d39d28533d78d9f87865f5/urijs/URIjs.d.ts
declare namespace uri {
interface URI {
absoluteTo(path: string): URI;
absoluteTo(path: URI): URI;
addFragment(fragment: string): URI;
addQuery(qry: string): URI;
addQuery(qry: Object): URI;
addSearch(qry: string): URI;
addSearch(key: string, value:any): URI;
addSearch(qry: Object): URI;
authority(): string;
authority(authority: string): URI;
clone(): URI;
directory(): string;
directory(dir: boolean): string;
directory(dir: string): URI;
domain(): string;
domain(domain: boolean): string;
domain(domain: string): URI;
duplicateQueryParameters(val: boolean): URI;
equals(): boolean;
equals(url: string | URI): boolean;
filename(): string;
filename(file: boolean): string;
filename(file: string): URI;
fragment(): string;
fragment(fragment: string): URI;
fragmentPrefix(prefix: string): URI;
hash(): string;
hash(hash: string): URI;
host(): string;
host(host: string): URI;
hostname(): string;
hostname(hostname: string): URI;
href(): string;
href(url: string): void;
is(qry: string): boolean;
iso8859(): URI;
joinPaths(...paths: (string | URI)[]): URI;
normalize(): URI;
normalizeFragment(): URI;
normalizeHash(): URI;
normalizeHostname(): URI;
normalizePath(): URI;
normalizePathname(): URI;
normalizePort(): URI;
normalizeProtocol(): URI;
normalizeQuery(): URI;
normalizeSearch(): URI;
origin(): string;
origin(uri: string | URI): URI;
password(): string;
password(pw: string): URI;
path(): string;
path(path: boolean): string;
path(path: string): URI;
pathname(): string;
pathname(path: boolean): string;
pathname(path: string): URI;
port(): string;
port(port: string): URI;
protocol(): string;
protocol(protocol: string): URI;
query(): string;
query(qry: string): URI;
query(qry: boolean): Object;
query(qry: Object): URI;
readable(): string;
relativeTo(path: string): URI;
removeQuery(qry: string): URI;
removeQuery(qry: Object): URI;
removeSearch(qry: string): URI;
removeSearch(qry: Object): URI;
resource(): string;
resource(resource: string): URI;
scheme(): string;
scheme(protocol: string): URI;
search(): string;
search(qry: string): URI;
search(qry: boolean): any;
search(qry: Object): URI;
segment(): string[];
segment(segments: string[]): URI;
segment(position: number): string;
segment(position: number, level: string): URI;
segment(segment: string): URI;
setQuery(key: string, value: string): URI;
setQuery(qry: Object): URI;
setSearch(key: string, value: string): URI;
setSearch(qry: Object): URI;
hasQuery(name: string | any, value?: string | number | boolean | Function | Array<string> | Array<number> | Array<boolean> | RegExp, withinArray?: boolean): boolean;
hasSearch(name: string | any, value?: string | number | boolean | Function | Array<string> | Array<number> | Array<boolean> | RegExp, withinArray?: boolean): boolean;
subdomain(): string;
subdomain(subdomain: string): URI;
suffix(): string;
suffix(suffix: boolean): string;
suffix(suffix: string): URI;
tld(): string;
tld(tld: boolean): string;
tld(tld: string): URI;
unicode(): URI;
userinfo(): string;
userinfo(userinfo: string): URI;
username(): string;
username(uname: string): URI;
valueOf(): string;
}
interface URIOptions {
protocol?: string;
username?: string;
password?: string;
hostname?: string;
port?: string;
path?: string;
query?: string;
fragment?: string;
}
interface URIStatic {
(): URI;
(value: string | URIOptions | HTMLElement): URI;
new (): URI;
new (value: string | URIOptions | HTMLElement): URI;
addQuery(data: Object, prop: string, value: string): Object;
addQuery(data: Object, qryObj: Object): Object;
build(parts: {
protocol: string;
username: string;
password: string;
hostname: string;
port: string;
path: string;
query: string;
fragment: string;
}): string;
buildAuthority(parts: {
username?: string;
password?: string;
hostname?: string;
port?: string;
}): string;
buildHost(parts: {
hostname?: string;
port?: string;
}): string;
buildQuery(qry: Object): string;
buildQuery(qry: Object, duplicates: boolean): string;
buildUserinfo(parts: {
username?: string;
password?: string;
}): string;
commonPath(path1: string, path2: string): string;
decode(str: string): string;
decodeQuery(qry: string): string;
encode(str: string): string;
encodeQuery(qry: string): string;
encodeReserved(str: string): string;
expand(template: string, vals: Object): URI;
iso8859(): void;
parse(url: string): {
protocol: string;
username: string;
password: string;
hostname: string;
port: string;
path: string;
query: string;
fragment: string;
};
parseAuthority(url: string, parts: {
username?: string;
password?: string;
hostname?: string;
port?: string;
}): string;
parseHost(url: string, parts: {
hostname?: string;
port?: string;
}): string;
parseQuery(url: string): Object;
parseUserinfo(url: string, parts: {
username?: string;
password?: string;
}): string;
removeQuery(data: Object, prop: string, value: string): Object;
removeQuery(data: Object, props: string[]): Object;
removeQuery(data: Object, props: Object): Object;
unicode(): void;
withinString(source: string, func: (url: string) => string): string;
}
}
interface JQuery {
uri(): uri.URI;
}
declare var URI: uri.URIStatic;
declare module 'URI' {
export = URI;
}
declare module 'urijs' {
export = URI;
}
declare module 'urijs/src/URITemplate' {
export = URI;
}

@ -1,8 +0,0 @@
{
"resolution": "main",
"tree": {
"src": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/3e77642fd96ddef451d39d28533d78d9f87865f5/urijs/URIjs.d.ts",
"raw": "registry:dt/urijs#1.15.1+20160526132152",
"typings": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/3e77642fd96ddef451d39d28533d78d9f87865f5/urijs/URIjs.d.ts"
}
}

@ -1,225 +0,0 @@
// Generated by typings
// Source: https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/86bb15f6b9a3515bd9b3ca61f2a670533ac6b908/webpack/webpack-env.d.ts
declare namespace __WebpackModuleApi {
interface RequireContext {
keys(): string[];
<T>(id: string): T;
resolve(id: string): string;
}
interface RequireFunction {
/**
* Returns the exports from a dependency. The call is sync. No request to the server is fired. The compiler ensures that the dependency is available.
*/
<T>(path: string): T;
/**
* Behaves similar to require.ensure, but the callback is called with the exports of each dependency in the paths array. There is no option to provide a chunk name.
*/
(paths: string[], callback: (...modules: any[]) => void): void;
/**
* Download additional dependencies on demand. The paths array lists modules that should be available. When they are, callback is called. If the callback is a function expression, dependencies in that source part are extracted and also loaded on demand. A single request is fired to the server, except if all modules are already available.
*
* This creates a chunk. The chunk can be named. If a chunk with this name already exists, the dependencies are merged into that chunk and that chunk is used.
*/
ensure: (paths: string[], callback: (require: <T>(path: string) => T) => void, chunkName?: string) => void;
context: (path: string, deep?: boolean, filter?: RegExp) => RequireContext;
/**
* Returns the module id of a dependency. The call is sync. No request to the server is fired. The compiler ensures that the dependency is available.
*
* The module id is a number in webpack (in contrast to node.js where it is a string, the filename).
*/
resolve(path: string): number;
/**
* Like require.resolve, but doesnt include the module into the bundle. Its a weak dependency.
*/
resolveWeak(path: string): number;
/**
* Ensures that the dependency is available, but dont execute it. This can be use for optimizing the position of a module in the chunks.
*/
include(path: string): void;
/**
* Multiple requires to the same module result in only one module execution and only one export. Therefore a cache in the runtime exists. Removing values from this cache cause new module execution and a new export. This is only needed in rare cases (for compatibility!).
*/
cache: {
[id: string]: any;
}
}
interface Module {
exports: any;
require(id: string): any;
id: string;
filename: string;
loaded: boolean;
parent: any;
children: any[];
hot: Hot;
}
type ModuleId = string|number;
interface Hot {
/**
* Accept code updates for the specified dependencies. The callback is called when dependencies were replaced.
* @param dependencies
* @param callback
*/
accept(dependencies: string[], callback: (updatedDependencies: ModuleId[]) => void): void;
/**
* Accept code updates for the specified dependencies. The callback is called when dependencies were replaced.
* @param dependency
* @param callback
*/
accept(dependency: string, callback: () => void): void;
/**
* Accept code updates for this module without notification of parents.
* This should only be used if the module doesnt export anything.
* The errHandler can be used to handle errors that occur while loading the updated module.
* @param errHandler
*/
accept(errHandler?: (err: Error) => void): void;
/**
* Do not accept updates for the specified dependencies. If any dependencies is updated, the code update fails with code "decline".
*/
decline(dependencies: string[]): void;
/**
* Do not accept updates for the specified dependencies. If any dependencies is updated, the code update fails with code "decline".
*/
decline(dependency: string): void;
/**
* Flag the current module as not update-able. If updated the update code would fail with code "decline".
*/
decline(): void;
/**
* Add a one time handler, which is executed when the current module code is replaced.
* Here you should destroy/remove any persistent resource you have claimed/created.
* If you want to transfer state to the new module, add it to data object.
* The data will be available at module.hot.data on the new module.
* @param callback
*/
dispose<T>(callback: (data: T) => void): void;
/**
* Add a one time handler, which is executed when the current module code is replaced.
* Here you should destroy/remove any persistent resource you have claimed/created.
* If you want to transfer state to the new module, add it to data object.
* The data will be available at module.hot.data on the new module.
* @param callback
*/
addDisposeHandler<T>(callback: (data: T) => void): void;
/**
* Remove a handler.
* This can useful to add a temporary dispose handler. You could i. e. replace code while in the middle of a multi-step async function.
* @param callback
*/
removeDisposeHandler<T>(callback: (data: T) => void): void;
/**
* Throws an exceptions if status() is not idle.
* Check all currently loaded modules for updates and apply updates if found.
* If no update was found, the callback is called with null.
* If autoApply is truthy the callback will be called with all modules that were disposed.
* apply() is automatically called with autoApply as options parameter.
* If autoApply is not set the callback will be called with all modules that will be disposed on apply().
* @param autoApply
* @param callback
*/
check(autoApply: boolean, callback: (err: Error, outdatedModules: ModuleId[]) => void): void;
/**
* Throws an exceptions if status() is not idle.
* Check all currently loaded modules for updates and apply updates if found.
* If no update was found, the callback is called with null.
* The callback will be called with all modules that will be disposed on apply().
* @param callback
*/
check(callback: (err: Error, outdatedModules: ModuleId[]) => void): void;
/**
* If status() != "ready" it throws an error.
* Continue the update process.
* @param options
* @param callback
*/
apply(options: AcceptOptions, callback: (err: Error, outdatedModules: ModuleId[]) => void): void;
/**
* If status() != "ready" it throws an error.
* Continue the update process.
* @param callback
*/
apply(callback: (err: Error, outdatedModules: ModuleId[]) => void): void;
/**
* Return one of idle, check, watch, watch-delay, prepare, ready, dispose, apply, abort or fail.
*/
status(): string;
/** Register a callback on status change. */
status(callback: (status: string) => void): void;
/** Register a callback on status change. */
addStatusHandler(callback: (status: string) => void): void;
/**
* Remove a registered status change handler.
* @param callback
*/
removeStatusHandler(callback: (status: string) => void): void;
active: boolean;
data: {};
}
interface AcceptOptions {
/**
* If true the update process continues even if some modules are not accepted (and would bubble to the entry point).
*/
ignoreUnaccepted?: boolean;
/**
* Indicates that apply() is automatically called by check function
*/
autoApply?: boolean;
}
}
declare var require: __WebpackModuleApi.RequireFunction;
/**
* The resource query of the current module.
*
* e.g. __resourceQuery === "?test" // Inside "file.js?test"
*/
declare var __resourceQuery: string;
/**
* Equals the config options output.publicPath.
*/
declare var __webpack_public_path__: string;
/**
* The raw require function. This expression isnt parsed by the Parser for dependencies.
*/
declare var __webpack_require__: any;
/**
* The internal chunk loading function
*
* @param chunkId The id for the chunk to load.
* @param callback A callback function called once the chunk is loaded.
*/
declare var __webpack_chunk_load__: (chunkId: any, callback: (require: (id: string) => any) => void) => void;
/**
* Access to the internal object of all modules.
*/
declare var __webpack_modules__: any[];
/**
* Access to the hash of the compilation.
*
* Only available with the HotModuleReplacementPlugin or the ExtendedAPIPlugin
*/
declare var __webpack_hash__: any;
/**
* Generates a require function that is not parsed by webpack. Can be used to do cool stuff with a global require function if available.
*/
declare var __non_webpack_require__: any;
/**
* Equals the config option debug
*/
declare var DEBUG: boolean;
declare var module: __WebpackModuleApi.Module;

@ -1,8 +0,0 @@
{
"resolution": "main",
"tree": {
"src": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/86bb15f6b9a3515bd9b3ca61f2a670533ac6b908/webpack/webpack-env.d.ts",
"raw": "github:DefinitelyTyped/DefinitelyTyped/webpack/webpack-env.d.ts#86bb15f6b9a3515bd9b3ca61f2a670533ac6b908",
"typings": "https://raw.githubusercontent.com/DefinitelyTyped/DefinitelyTyped/86bb15f6b9a3515bd9b3ca61f2a670533ac6b908/webpack/webpack-env.d.ts"
}
}

@ -1,23 +0,0 @@
/// <reference path="globals/angular-animate/index.d.ts" />
/// <reference path="globals/angular-mocks/index.d.ts" />
/// <reference path="globals/angular-ui-router/index.d.ts" />
/// <reference path="globals/angular/index.d.ts" />
/// <reference path="globals/assertion-error/index.d.ts" />
/// <reference path="globals/chai-as-promised/index.d.ts" />
/// <reference path="globals/chai/index.d.ts" />
/// <reference path="globals/es6-shim/index.d.ts" />
/// <reference path="globals/jquery/index.d.ts" />
/// <reference path="globals/jqueryui/index.d.ts" />
/// <reference path="globals/lodash/index.d.ts" />
/// <reference path="globals/mocha/index.d.ts" />
/// <reference path="globals/moment-node/index.d.ts" />
/// <reference path="globals/moment/index.d.ts" />
/// <reference path="globals/mousetrap/index.d.ts" />
/// <reference path="globals/ng-dialog/index.d.ts" />
/// <reference path="globals/nouislider/index.d.ts" />
/// <reference path="globals/promises-a-plus/index.d.ts" />
/// <reference path="globals/rosie/index.d.ts" />
/// <reference path="globals/sinon-chai/index.d.ts" />
/// <reference path="globals/sinon/index.d.ts" />
/// <reference path="globals/urijs/index.d.ts" />
/// <reference path="globals/webpack-env/index.d.ts" />

@ -42,8 +42,8 @@ var debug_output = (!production || !!process.env['OP_FRONTEND_DEBUG_OUTPUT']);
var node_root = path.resolve(__dirname, 'node_modules');
var pluginEntries = _.reduce(pathConfig.pluginNamesPaths, function (entries, path, name) {
entries[name.replace(/^openproject\-/, '')] = name;
var pluginEntries = _.reduce(pathConfig.pluginNamesPaths, function (entries, pluginPath, name) {
entries[name.replace(/^openproject\-/, '')] = path.resolve(pluginPath, 'frontend', 'app', name + '-app.js');
return entries;
}, {});
@ -63,35 +63,107 @@ fs.readdirSync(translations).forEach(function (file) {
});
var loaders = [
{ test: /\.tsx?$/, loader: 'ng-annotate-loader!ts-loader'},
{
test: /\.tsx?$/,
include: [
path.resolve(__dirname, 'app'),
path.resolve(__dirname, 'tests')
],
use: [
{
loader: 'ng-annotate-loader'
},
{
loader: 'ts-loader',
options: {
logLevel: 'info',
configFileName: path.resolve(__dirname, 'tsconfig.json')
}
}
]
},
{
test: /\.css$/,
loader: ExtractTextPlugin.extract({
use: ExtractTextPlugin.extract({
fallbackLoader: 'style-loader',
loader: 'css-loader!postcss-loader',
loader: [
'css-loader',
'postcss-loader'
],
publicPath: '/assets/bundles/'
})
},
{test: /\.png$/, loader: 'url-loader?limit=100000&mimetype=image/png'},
{test: /\.gif$/, loader: 'file-loader'},
{test: /\.jpg$/, loader: 'file-loader'},
{test: /[\/].*\.js$/, loader: 'ng-annotate-loader?map=true'}
{
test: /\.png$/,
use: [
{
loader: 'url-loader',
options: {
limit: '100000',
mimetype: 'image/png'
}
}
]
},
{
test: /\.gif$/,
use: ['file-loader']
},
{
test: /\.jpg$/,
use: ['file-loader']
},
{
test: /[\/].*\.js$/,
use: [
{
loader: 'ng-annotate-loader',
options: { map: true }
}
]
}
];
for (var k in pathConfig.pluginNamesPaths) {
if (pathConfig.pluginNamesPaths.hasOwnProperty(k)) {
loaders.push({
test: new RegExp('templates/plugin-' + k.replace(/^openproject\-/, '') + '/.*\.html$'),
loader: 'ngtemplate-loader?module=openproject.templates&relativeTo=' +
path.join(pathConfig.pluginNamesPaths[k], 'frontend', 'app') + '!html-loader?-minimize'
use: [
{
loader: 'ngtemplate-loader',
options: {
module: 'openproject.templates',
relativeTo: path.join(pathConfig.pluginNamesPaths[k], 'frontend', 'app')
}
},
{
loader: 'html-loader',
options: {
minimize: false
}
}
]
});
}
}
loaders.push({
test: /^((?!templates\/plugin).)*\.html$/,
loader: 'ngtemplate-loader?module=openproject.templates&relativeTo=' +
path.resolve(__dirname, './app') + '!html-loader?-minimize'
use: [
{
loader: 'ngtemplate-loader',
options: {
module: 'openproject.templates',
relativeTo: path.resolve(__dirname, './app')
}
},
{
loader: 'html-loader',
options: {
minimize: false
}
}
]
});
function getWebpackMainConfig() {
@ -110,11 +182,11 @@ function getWebpackMainConfig() {
},
module: {
loaders: loaders
rules: loaders
},
resolve: {
modules: ['node_modules'].concat(pathConfig.pluginDirectories),
modules: ['node_modules'],
extensions: ['.ts', '.tsx', '.js'],
@ -131,7 +203,7 @@ function getWebpackMainConfig() {
'angular-context-menu': 'angular-context-menu/dist/angular-context-menu.js',
'mousetrap': 'mousetrap/mousetrap.js',
'ngFileUpload': 'ng-file-upload/dist/ng-file-upload.min.js',
'lodash': path.resolve(node_root, 'lodash', 'dist', 'lodash.min.js'),
'lodash': path.resolve(node_root, 'lodash', 'lodash.min.js'),
// prevents using crossvent from dist and by that
// reenables debugging in the browser console.
// https://github.com/bevacqua/dragula/issues/102#issuecomment-123296868

@ -35,14 +35,14 @@ module Redmine::MenuManager::TopMenuHelper
def render_top_menu_left
content_tag :ul, id: 'account-nav-left', class: 'menu_root account-nav hidden-for-mobile' do
[render_main_top_menu_nodes,
render_projects_top_menu_node,
render_module_top_menu_node].join.html_safe
render_projects_top_menu_node].join.html_safe
end
end
def render_top_menu_right
content_tag :ul, id: 'account-nav-right', class: 'menu_root account-nav' do
[render_help_top_menu_node,
[render_module_top_menu_node,
render_help_top_menu_node,
render_user_top_menu_node].join.html_safe
end
end
@ -106,10 +106,10 @@ module Redmine::MenuManager::TopMenuHelper
def render_module_top_menu_node(items = more_top_menu_items)
render_menu_dropdown_with_items(
label: l(:label_modules),
label_options: { class: 'icon3 icon-modules' },
label: '',
label_options: { class: 'icon-menu', title: I18n.t('label_modules') },
items: items,
options: { drop_down_id: 'more-menu' }
options: { drop_down_id: 'more-menu', drop_down_class: 'drop-down--modules ', menu_item_class: '-hide-icon' }
)
end

@ -48,8 +48,7 @@ describe Redmine do
include RedmineMenuTestHelper
it 'should top_menu' do
assert_number_of_items_in_menu :top_menu, 6
assert_menu_contains_item_named :top_menu, :my_page
assert_number_of_items_in_menu :top_menu, 5
assert_menu_contains_item_named :top_menu, :work_packages
assert_menu_contains_item_named :top_menu, :news
assert_menu_contains_item_named :top_menu, :time_sheet
@ -58,9 +57,10 @@ describe Redmine do
end
it 'should account_menu' do
assert_number_of_items_in_menu :account_menu, 3
assert_number_of_items_in_menu :account_menu, 4
assert_menu_contains_item_named :account_menu, :administration
assert_menu_contains_item_named :account_menu, :my_account
assert_menu_contains_item_named :account_menu, :my_page
assert_menu_contains_item_named :account_menu, :logout
end

Loading…
Cancel
Save