commit
stringlengths
40
40
old_file
stringlengths
4
150
new_file
stringlengths
4
150
old_contents
stringlengths
0
3.26k
new_contents
stringlengths
1
4.43k
subject
stringlengths
15
501
message
stringlengths
15
4.06k
lang
stringclasses
4 values
license
stringclasses
13 values
repos
stringlengths
5
91.5k
diff
stringlengths
0
4.35k
66c9f729592c011ef59d1529a73470cabf36c4a4
src/internal/ErrorBoundary/index.tsx
src/internal/ErrorBoundary/index.tsx
import React from 'react'; import { Flex } from '../../components/Flex'; import Alert from '../../components/Alert'; interface ErrorBoundaryState { error: any; } interface ErrorBoundaryProps { getErrorDisplay?: (error: any) => JSX.Element; } const DefaultErrorDisplay = () => ( <Flex flex={1} alignItems="center" j...
import React from 'react'; import isEqual from 'lodash/isEqual'; import { Flex } from '../../components/Flex'; import Alert from '../../components/Alert'; interface ErrorBoundaryState { error: any; } interface ErrorBoundaryProps { getErrorDisplay?: (error: any) => JSX.Element; } const DefaultErrorDisplay = () => (...
Reset error boundary if props change
fix: Reset error boundary if props change Previously, the error boundary was stuck in the error state until it was unmounted and remounted. Change-type: patch Signed-off-by: Graham McCulloch <5ca27e75aea3e5e83a04c6cfa5f1b63d358cd03d@balena.io>
TypeScript
mit
resin-io-modules/resin-components,resin-io-modules/resin-components,resin-io-modules/resin-components
--- +++ @@ -1,4 +1,5 @@ import React from 'react'; +import isEqual from 'lodash/isEqual'; import { Flex } from '../../components/Flex'; import Alert from '../../components/Alert'; @@ -31,6 +32,12 @@ return { error }; } + componentDidUpdate(prevProps: any) { + if (!isEqual(prevProps, this.props)) { + th...
6085a4094a945e845f540605e21a9ac894be22bd
src/time/time.service.ts
src/time/time.service.ts
import { Injectable } from '@angular/core' import { Http, Response } from '@angular/http'; import { Observable } from 'rxjs/Rx'; import { NativeStorage } from 'ionic-native'; @Injectable() export class TimeService { private _url: string = 'https://script.google.com/macros/s/AKfycbyd5AcbAnWi2Yn0xhFRbyzS4qMq1VucMVg...
import { Injectable } from '@angular/core' import { Http, Response } from '@angular/http'; import { Observable } from 'rxjs/Rx'; import { NativeStorage } from 'ionic-native'; @Injectable() export class TimeService { private _url: string = 'https://script.google.com/macros/s/AKfycbyd5AcbAnWi2Yn0xhFRbyzS4qMq1VucMVg...
Fix UPDATE NOW button to work after fresh installation
Fix UPDATE NOW button to work after fresh installation
TypeScript
apache-2.0
sth-larp/deus-mobile,sth-larp/deus-mobile,sth-larp/deus-mobile,sth-larp/deus-mobile,sth-larp/deus-mobile
--- +++ @@ -15,7 +15,7 @@ .do(json => console.log('Received json: ' + JSON.stringify(json))) .do(json => this._cacheTime(json)); var observableLocal: Observable<any> = this._getCachedTime(); - return Observable.concat(observableLocal, observableHttp); + return Observab...
1a06e3df8f2375a6d274613d896f8f6ad29b4570
packages/lesswrong/lib/collections/tags/fragments.ts
packages/lesswrong/lib/collections/tags/fragments.ts
import { registerFragment } from '../../vulcan-lib'; registerFragment(` fragment TagBasicInfo on Tag { _id name slug oldSlugs core postCount deleted adminOnly defaultOrder suggestedAsFilter needsReview reviewedByUserId descriptionTruncationCount wikiGrade c...
import { registerFragment } from '../../vulcan-lib'; registerFragment(` fragment TagBasicInfo on Tag { _id name slug oldSlugs core postCount deleted adminOnly defaultOrder suggestedAsFilter needsReview reviewedByUserId descriptionTruncationCount wikiGrade c...
Remove tagFlagsIds from tag fragment
Remove tagFlagsIds from tag fragment
TypeScript
mit
Discordius/Lesswrong2,Discordius/Lesswrong2,Discordius/Lesswrong2,Discordius/Lesswrong2
--- +++ @@ -18,7 +18,6 @@ wikiGrade createdAt wikiOnly - tagFlagsIds lesswrongWikiImportSlug lesswrongWikiImportRevision }
23e8d93c0ea28d5d8913c860c7a9293404b2ea01
src/constants/path-info.ts
src/constants/path-info.ts
import { PathInfo } from './interfaces'; const PATH_INFOS: PathInfo[] = [ { path: /^\/$/, label: 'Home' }, { path: /^\/create-machine$/, label: 'Create Machine' }, { path: /^\/machines$/, label: 'Machines' }, { path: /^\/machines\/[a-zA-Z0-9]+$/, dynamicLabel: (route) => r...
import { PathInfo } from './interfaces'; const PATH_INFOS: PathInfo[] = [ { path: /^\/$/, label: 'Home' }, { path: /^\/create-machine$/, label: 'Create Machine' }, { path: /^\/machines$/, label: 'Machines' }, { path: /^\/machines\/[a-zA-Z0-9]+$/, dynamicLabel: (route) => r...
Add machine image path info
Add machine image path info
TypeScript
apache-2.0
lawrence0819/neptune-front,lawrence0819/neptune-front
--- +++ @@ -24,6 +24,10 @@ { path: /^\/machines\/[a-zA-Z0-9]+\/create-container$/, label: 'Create Container' + }, + { + path: /^\/machines\/[a-zA-Z0-9]+\/images$/, + label: 'Images' } ];
5ca1c5dd0f963e447ec0c0b591adb4394b793e12
src/ManifestResource.ts
src/ManifestResource.ts
module Manifesto { export class ManifestResource extends JSONLDResource implements IManifestResource { options: IManifestoOptions; constructor(jsonld: any, options: IManifestoOptions) { super(jsonld); this.options = options; } getLabel(): string { ...
module Manifesto { export class ManifestResource extends JSONLDResource implements IManifestResource { options: IManifestoOptions; constructor(jsonld: any, options: IManifestoOptions) { super(jsonld); this.options = options; } getLabel(): string { ...
Check if no metadata is present
Check if no metadata is present
TypeScript
mit
viewdir/manifesto,viewdir/manifesto
--- +++ @@ -13,6 +13,9 @@ getMetadata(): any{ var metadata: Object[] = this.getProperty('metadata'); + + if (!metadata) + return []; // get localised value for each metadata item. for (var i = 0; i < metadata.length; i++) {
d765fdbf2517c151c69b9cb5afd86eff149cbce6
koa-static/koa-static.d.ts
koa-static/koa-static.d.ts
// Type definitions for koa-static v2.x // Project: https://github.com/koajs/static // Definitions by: Jerry Chin <https://github.com/hellopao/> // Definitions: https://github.com/hellopao/DefinitelyTyped /* =================== USAGE =================== import serve = require("koa-static"); var Koa = require(...
// Type definitions for koa-static v2.x // Project: https://github.com/koajs/static // Definitions by: Jerry Chin <https://github.com/hellopao/> // Definitions: https://github.com/hellopao/DefinitelyTyped /* =================== USAGE =================== import serve = require("koa-static"); var Koa = require(...
Fix error TS2497 on import * as X from 'koa-static
Fix error TS2497 on import * as X from 'koa-static
TypeScript
mit
aciccarello/DefinitelyTyped,nainslie/DefinitelyTyped,slavomirvojacek/adbrain-typescript-definitions,yuit/DefinitelyTyped,arma-gast/DefinitelyTyped,psnider/DefinitelyTyped,mcrawshaw/DefinitelyTyped,schmuli/DefinitelyTyped,xStrom/DefinitelyTyped,progre/DefinitelyTyped,georgemarshall/DefinitelyTyped,abbasmhd/DefinitelyTyp...
--- +++ @@ -46,6 +46,6 @@ */ gzip?: boolean; }): { (ctx: Koa.Context, next?: () => any): any }; - + namespace serve{} export = serve; }
1c8cbd7b4a55b191122ad28409c346b9357688bc
.storybook/decorators.tsx
.storybook/decorators.tsx
import { FC, createElement as h } from 'react'; import { boolean, select, withKnobs } from "@storybook/addon-knobs"; import { BrowserRouter as Router } from 'react-router-dom'; const Root: FC<any> = props => ( <div id="story-root" {...props} style={{ backgroundColor: 'white', padding: '1em' }}> <Router...
import { FC, createElement as h } from 'react'; import { boolean, select, withKnobs } from "@storybook/addon-knobs"; import { BrowserRouter as Router } from 'react-router-dom'; const Root: FC<any> = props => ( <div id="story-root" {...props} style={{ padding: '1em' }}> <Router> {props.children} <...
Remove white background from stories
Remove white background from stories This doesn't work well with the design.
TypeScript
mit
eliothill/home-office-digital-patterns,eliothill/home-office-digital-patterns,eliothill/home-office-digital-patterns
--- +++ @@ -4,7 +4,6 @@ const Root: FC<any> = props => ( <div id="story-root" {...props} style={{ - backgroundColor: 'white', padding: '1em' }}> <Router>
baf18cce6552a3baf773efdb12697fc3f82c1881
src/testing/index.ts
src/testing/index.ts
import { ComponentFixture } from '@angular/core/testing'; import { By } from '@angular/platform-browser'; export function selectElement<T> (fixture: ComponentFixture<T>, locator: string) { return fixture.debugElement.query(By.css('h1')).nativeElement; }
import { ComponentFixture } from '@angular/core/testing'; import { By } from '@angular/platform-browser'; export function selectElement<T> (fixture: ComponentFixture<T>, locator: string) { return fixture.debugElement.query(By.css(locator)).nativeElement; }
Fix element selector in spec testing module
Fix element selector in spec testing module
TypeScript
bsd-3-clause
cumulous/web,cumulous/web,cumulous/web,cumulous/web
--- +++ @@ -2,5 +2,5 @@ import { By } from '@angular/platform-browser'; export function selectElement<T> (fixture: ComponentFixture<T>, locator: string) { - return fixture.debugElement.query(By.css('h1')).nativeElement; + return fixture.debugElement.query(By.css(locator)).nativeElement; }
a3a9c9ece22ed9acdd5457d4858cdce864c91e6f
src/ui/utils/utils-m3u.ts
src/ui/utils/utils-m3u.ts
import * as path from 'path'; import * as fs from 'fs'; import * as chardet from 'chardet'; import * as iconv from 'iconv-lite'; const isFile = (path: string) => fs.lstatSync(path).isFile(); export const parse = (filePath: string): string[] => { try { const baseDir = path.parse(filePath).dir; const encoding...
import * as path from 'path'; import * as fs from 'fs'; import * as chardet from 'chardet'; import * as iconv from 'iconv-lite'; const isFile = (path: string) => fs.lstatSync(path).isFile(); export const parse = (filePath: string): string[] => { try { const baseDir = path.parse(filePath).dir; const encoding...
Check for trailing carriage returns
Check for trailing carriage returns
TypeScript
mit
KeitIG/museeks,KeitIG/museeks,KeitIG/museeks
--- +++ @@ -18,7 +18,7 @@ const decodedContent = iconv.decode(content, encoding); const files = decodedContent - .split('\n') + .split(/\r?\n/) .reduce((acc, line) => { if (line.length === 0) { return acc;
d37a6a7fffe24727fd5f8a3184aaff9c35ba304c
gulp/module.ts
gulp/module.ts
import { watch, task } from 'gulp'; import { join } from 'path'; import { SRC, DIST, DEMO_DIST } from './constants'; import compileTs from './tasks/compileTs'; import clean from './tasks/clean'; const runSequence = require('run-sequence'); const src = join(SRC, '**/*.ts'); task('module:clean', clean(DIST)); task('m...
import { watch, task } from 'gulp'; import { join } from 'path'; import { SRC, DIST, DEMO_DIST } from './constants'; import compileTs from './tasks/compileTs'; import clean from './tasks/clean'; const runSequence = require('run-sequence'); const src = join(SRC, '**/*.ts'); task('module:clean', clean(DIST)); task('m...
Fix wrong demo method signature.
Fix wrong demo method signature.
TypeScript
mit
crisbeto/angular-svg-round-progressbar,crisbeto/angular-svg-round-progressbar
--- +++ @@ -10,7 +10,7 @@ task('module:clean', clean(DIST)); -task('module:ts:demo', compileTs(join(SRC, '**/*.ts'), null, DEMO_DIST)); +task('module:ts:demo', compileTs(join(SRC, '**/*.ts'), DEMO_DIST)); task('module:watch', () => { watch(join(SRC, '**/*.ts'), ['module:ts:demo']);
c5c7e9e8a1e35cf2d692f3cb30b7f6e45d5a5e15
packages/@glimmer/integration-tests/lib/modes/rehydration/builder.ts
packages/@glimmer/integration-tests/lib/modes/rehydration/builder.ts
import { RehydrateBuilder } from '@glimmer/runtime'; import { SimpleNode } from '@simple-dom/interface'; import { Environment, Cursor, ElementBuilder } from '@glimmer/interfaces'; export class DebugRehydrationBuilder extends RehydrateBuilder { clearedNodes: SimpleNode[] = []; remove(node: SimpleNode) { let ne...
import { RehydrateBuilder } from '@glimmer/runtime'; import { SimpleNode } from '@simple-dom/interface'; import { Environment, Cursor, ElementBuilder } from '@glimmer/interfaces'; export class DebugRehydrationBuilder extends RehydrateBuilder { clearedNodes: SimpleNode[] = []; remove(node: SimpleNode) { let ne...
Fix DebugRehydrationBuilder's handling of serialized cursor positions.
Fix DebugRehydrationBuilder's handling of serialized cursor positions.
TypeScript
mit
glimmerjs/glimmer-vm,tildeio/glimmer,tildeio/glimmer,glimmerjs/glimmer-vm,glimmerjs/glimmer-vm,tildeio/glimmer
--- +++ @@ -12,7 +12,7 @@ if (node.nodeType !== 8) { if (el.nodeType === 1) { // don't stat serialized cursor positions - if (el.tagName !== 'SCRIPT' && !el.getAttribute('gmlr')) { + if (el.tagName !== 'SCRIPT' || !el.getAttribute('glmr')) { this.clearedNodes.push(node); ...
f60961947fc9471024081c3c76f940b864336e5f
src/background/presenters/IndicatorPresenter.ts
src/background/presenters/IndicatorPresenter.ts
export default class IndicatorPresenter { indicate(enabled: boolean): Promise<void> { let path = enabled ? 'resources/enabled_32x32.png' : 'resources/disabled_32x32.png'; return browser.browserAction.setIcon({ path }); } onClick(listener: (arg: browser.tabs.Tab) => void): void { browser.b...
export default class IndicatorPresenter { indicate(enabled: boolean): Promise<void> { let path = enabled ? 'resources/enabled_32x32.png' : 'resources/disabled_32x32.png'; if (typeof browser.browserAction.setIcon === "function") { return browser.browserAction.setIcon({ path }); } else...
Fix setIcon warning on Android
Fix setIcon warning on Android
TypeScript
mit
ueokande/vim-vixen,ueokande/vim-vixen,ueokande/vim-vixen
--- +++ @@ -3,7 +3,13 @@ let path = enabled ? 'resources/enabled_32x32.png' : 'resources/disabled_32x32.png'; - return browser.browserAction.setIcon({ path }); + if (typeof browser.browserAction.setIcon === "function") { + return browser.browserAction.setIcon({ path }); + } + else ...
90a127d528bd09466de676126ca088cf0646b821
src/app/farming/reducer.ts
src/app/farming/reducer.ts
import { Reducer } from 'redux'; import { ActionType, getType } from 'typesafe-actions'; import * as actions from './basic-actions'; export interface FarmingState { // The actively farming store, if any readonly storeId?: string; // A counter for pending tasks that interrupt farming readonly numInterruptions: ...
import { Reducer } from 'redux'; import { ActionType, getType } from 'typesafe-actions'; import * as actions from './basic-actions'; export interface FarmingState { // The actively farming store, if any readonly storeId?: string; // A counter for pending tasks that interrupt farming readonly numInterruptions: ...
Reset farming interruptions on start/stop
Reset farming interruptions on start/stop
TypeScript
mit
delphiactual/DIM,DestinyItemManager/DIM,delphiactual/DIM,delphiactual/DIM,delphiactual/DIM,DestinyItemManager/DIM,DestinyItemManager/DIM,DestinyItemManager/DIM
--- +++ @@ -24,12 +24,14 @@ return { ...state, storeId: action.payload, + numInterruptions: 0, }; case getType(actions.stop): return { ...state, storeId: undefined, + numInterruptions: 0, }; case getType(actions.interruptFarmi...
4876c6722a3d4167f0e4d8d05876fbcaf5960e6a
test/data/User.spec.ts
test/data/User.spec.ts
import {UserSchema, IUserModel} from "../../src/server/data/User"; import {GameSchema, IGameModel} from "../../src/server/data/GameModel"; import mongoose from "mongoose"; import assert from "assert"; const connectionString = "mongodb://localhost/test" const User = mongoose.model("User", UserSchema) as IUserModel; con...
import {UserSchema, IUserModel} from "../../src/server/data/User"; import {GameSchema, IGameModel} from "../../src/server/data/GameModel"; import mongoose from "mongoose"; import assert from "assert"; const connectionString = "mongodb://localhost/test" const User = mongoose.model("User", UserSchema) as IUserModel; con...
Fix the unit test -> remove unnecessary stuff...
Fix the unit test -> remove unnecessary stuff...
TypeScript
mit
Majavapaja/Mursushakki,Majavapaja/Mursushakki,Majavapaja/Mursushakki,Majavapaja/Mursushakki,Majavapaja/Mursushakki,Majavapaja/Mursushakki
--- +++ @@ -31,7 +31,6 @@ const facebookId = "M4T4L4" let user = await User.findOrCreate(facebookId); - User.updateName(user._id, "HerraMatala"); const game = await GameModel.findOrCreate("P3L1") await User.addGame(user._id, game);
0b9f9362b94b52130e9a9f09971c4516fe503beb
ui/test/tests-index.ts
ui/test/tests-index.ts
// tslint:disable:interface-name // tslint:disable:no-empty-interface interface IWebpackRequire { context: any; } interface NodeRequire extends IWebpackRequire {} declare var require: NodeRequire; const srcContext = require.context("../src/app/", true, /\.ts$/); srcContext.keys().map(srcContext); const testContext...
// tslint:disable:interface-name // tslint:disable:no-empty-interface interface IWebpackRequire { context: any; } interface NodeRequire extends IWebpackRequire {} const srcContext = require.context("../src/app/", true, /\.ts$/); srcContext.keys().map(srcContext); const testContext = require.context("./", true, /sp...
Remove no longer needed declare.
Remove no longer needed declare.
TypeScript
mit
jp7677/hellocoreclr,jp7677/hellocoreclr,jp7677/hellocoreclr,jp7677/hellocoreclr
--- +++ @@ -3,7 +3,6 @@ interface IWebpackRequire { context: any; } interface NodeRequire extends IWebpackRequire {} -declare var require: NodeRequire; const srcContext = require.context("../src/app/", true, /\.ts$/); srcContext.keys().map(srcContext);
a5608af907a1b9d92bc23f69cecc8c191c862738
arduino-uno/tests/blink.ts
arduino-uno/tests/blink.ts
import { Sources, Sinks, HIGH, LOW, run, byte, createSinks } from '../../../src/boards/arduino-uno'; function toggle(value: byte): byte { return value == HIGH ? LOW : HIGH; } function blink(arduino: Sources): Sinks { const sinks: Sinks = createSinks(); sinks.LED$ = arduino.LED$.map(toggle); return sinks; } r...
import { Sources, Sinks, HIGH, LOW, run, byte, createSinks } from '../src/arduino-uno'; function toggle(value: byte): byte { return value == HIGH ? LOW : HIGH; } function blink(arduino: Sources): Sinks { const sinks: Sinks = createSinks(); sinks.LED$ = arduino.LED$.map(toggle); return sinks; } run(blink);
Fix relative path to source file
Fix relative path to source file
TypeScript
mit
artfuldev/RIoT
--- +++ @@ -1,4 +1,4 @@ -import { Sources, Sinks, HIGH, LOW, run, byte, createSinks } from '../../../src/boards/arduino-uno'; +import { Sources, Sinks, HIGH, LOW, run, byte, createSinks } from '../src/arduino-uno'; function toggle(value: byte): byte { return value == HIGH ? LOW : HIGH;
60ad193ffd7f5dcc8309cca6553a79dcf197d17e
tools/env/base.ts
tools/env/base.ts
import { EnvConfig } from './env-config.interface'; const BaseConfig: EnvConfig = { // Sample API url API: 'https://demo.com', RELEASEURL: 'https://github.com/nie-ine/raeber-website/releases/tag/0.9.0', RELEASEVERSION: '0.9.0' }; export = BaseConfig;
import { EnvConfig } from './env-config.interface'; const BaseConfig: EnvConfig = { // Sample API url API: 'https://demo.com', RELEASEURL: 'https://github.com/nie-ine/raeber-website/releases/tag/0.10.0', RELEASEVERSION: '0.10.0' }; export = BaseConfig;
Update release version to 0.10.0.
Update release version to 0.10.0.
TypeScript
mit
nie-ine/raeber-website,nie-ine/raeber-website,nie-ine/raeber-website,nie-ine/raeber-website
--- +++ @@ -3,8 +3,8 @@ const BaseConfig: EnvConfig = { // Sample API url API: 'https://demo.com', - RELEASEURL: 'https://github.com/nie-ine/raeber-website/releases/tag/0.9.0', - RELEASEVERSION: '0.9.0' + RELEASEURL: 'https://github.com/nie-ine/raeber-website/releases/tag/0.10.0', + RELEASEVERSION: '0.10.0...
278b4586508aebd728b027e17b526bbe29444b06
core/i18n/intl.ts
core/i18n/intl.ts
import areIntlLocalesSupported from 'intl-locales-supported' export const importIntlPolyfill = async () => { const IntlPolyfill = await import('intl') global.Intl = IntlPolyfill.default } export const checkForIntlPolyfill = async (storeView) => { if (!global.Intl || !areIntlLocalesSupported(storeView.i18n.defau...
import areIntlLocalesSupported from 'intl-locales-supported' export const importIntlPolyfill = async () => { const IntlPolyfill = await import('intl') global.Intl = IntlPolyfill.default } export const checkForIntlPolyfill = async (storeView) => { if (!(window || global).Intl || !areIntlLocalesSupported(storeVie...
Add changes of @gibkigonzo for `window` support
Add changes of @gibkigonzo for `window` support
TypeScript
mit
pkarw/vue-storefront,DivanteLtd/vue-storefront,pkarw/vue-storefront,DivanteLtd/vue-storefront,DivanteLtd/vue-storefront,pkarw/vue-storefront,DivanteLtd/vue-storefront,pkarw/vue-storefront
--- +++ @@ -6,7 +6,7 @@ } export const checkForIntlPolyfill = async (storeView) => { - if (!global.Intl || !areIntlLocalesSupported(storeView.i18n.defaultLocale)) { + if (!(window || global).Intl || !areIntlLocalesSupported(storeView.i18n.defaultLocale)) { await importIntlPolyfill() } }
55240c9e6ae7cc3eb421fd361ac2502ef9c90034
frontend/src/webpolls.component.ts
frontend/src/webpolls.component.ts
import { Component, ViewEncapsulation } from "@angular/core"; import { AccountService } from "./auth/account.service"; import { Router } from "@angular/router"; /** * Main component for the application */ @Component({ encapsulation: ViewEncapsulation.None, selector: "wp-app", styleUrls: ["webpolls.css"]...
import { Component, ViewEncapsulation } from "@angular/core"; import { AccountService } from "./auth/account.service"; import { Router } from "@angular/router"; /** * Main component for the application */ @Component({ encapsulation: ViewEncapsulation.None, selector: "wp-app", templateUrl: "webpolls.html...
Remove webpolls.css from styles in ts
Remove webpolls.css from styles in ts
TypeScript
mit
BenjaminSchubert/web-polls,BenjaminSchubert/web-polls,BenjaminSchubert/web-polls,BenjaminSchubert/web-polls,BenjaminSchubert/web-polls
--- +++ @@ -9,7 +9,6 @@ @Component({ encapsulation: ViewEncapsulation.None, selector: "wp-app", - styleUrls: ["webpolls.css"], templateUrl: "webpolls.html", }) export class WebpollsComponent {
f1e4a72edde1536ea82791c06b3a3850609b85ff
public/app/shared/stars/auth-stars.ts
public/app/shared/stars/auth-stars.ts
import { Component, Input, Output, OnInit, EventEmitter } from '@angular/core'; import { AcStars } from './stars'; import { ToastService } from '../../services/shared/toast.service'; import { AuthService } from '../../services/authentication/auth.service'; import { UserService } from '../../services/shared/user.servic...
import { Component, Input, Output, OnInit, EventEmitter } from '@angular/core'; import { AcStars } from './stars'; import { ToastService } from '../../services/shared/toast.service'; import { AuthService } from '../../services/authentication/auth.service'; import { UserService } from '../../services/shared/user.servic...
Fix stars logged in validation bug
Fix stars logged in validation bug
TypeScript
mit
ZmeiDev/stormtroopers,ZmeiDev/stormtroopers,ZmeiDev/stormtroopers
--- +++ @@ -16,7 +16,6 @@ ` }) export class AuthAcStars implements OnInit { - private _isLogged: boolean; private _isOwner: boolean; @Input() ownerUsername: boolean; @@ -31,14 +30,13 @@ ) { } ngOnInit() { - this._isLogged = this._authService.isLoggedIn(); - let logged...
51885ae979f961adc174a621e655a35069224171
demo/src/app/app.module.ts
demo/src/app/app.module.ts
import { BrowserModule } from '@angular/platform-browser'; import { PrettyJsonModule } from 'angular2-prettyjson'; import { NgModule } from '@angular/core'; import { AppComponent } from './app.component'; import { LinkedInSdkModule } from '../../temp'; @NgModule({ declarations: [ AppComponent ], imports: [ ...
import { BrowserModule } from '@angular/platform-browser'; import { PrettyJsonModule } from 'angular2-prettyjson'; import { NgModule } from '@angular/core'; import { AppComponent } from './app.component'; import { LinkedInSdkModule } from '../../temp'; @NgModule({ declarations: [ AppComponent ], imports: [ ...
Revert "TravisCI Remove script config"
Revert "TravisCI Remove script config" This reverts commit c737aaabd2b9f81ad5bd9e73a256b6bc70787d14.
TypeScript
mit
evodeck/angular-linkedin-sdk,evodeck/angular-linkedin-sdk
--- +++ @@ -14,7 +14,7 @@ LinkedInSdkModule ], providers: [ - { provide: 'apiKey', useValue: '77e6o5uw11lpyk' }, + { provide: 'apiKey', useValue: 'YOUR_API_KEY' }, { provide: 'authorize', useValue: true} ], bootstrap: [AppComponent]
fd2324be6a55dc5a72e800b5807d30e0051a2b0b
charts/covidDataExplorer/CovidRadioControl.tsx
charts/covidDataExplorer/CovidRadioControl.tsx
import React from "react" import { observer } from "mobx-react" import { action } from "mobx" export interface RadioOption { label: string checked: boolean onChange: (checked: boolean) => void } @observer export class CovidRadioControl extends React.Component<{ name: string isCheckbox?: boolean ...
import React from "react" import { observer } from "mobx-react" import { action } from "mobx" export interface RadioOption { label: string checked: boolean onChange: (checked: boolean) => void } @observer export class CovidRadioControl extends React.Component<{ name: string isCheckbox?: boolean ...
Move data-track-note to <label> to capture label text content
Move data-track-note to <label> to capture label text content
TypeScript
mit
owid/owid-grapher,OurWorldInData/owid-grapher,owid/owid-grapher,owid/owid-grapher,OurWorldInData/owid-grapher,OurWorldInData/owid-grapher,owid/owid-grapher,owid/owid-grapher,OurWorldInData/owid-grapher,OurWorldInData/owid-grapher
--- +++ @@ -31,6 +31,7 @@ className={ option.checked ? "SelectedOption" : "Option" } + data-track-note={`covid-click-${name}`} > <input ...
fb778d8acc5d2985b1495e264c12490abe6bfb72
ts/tests/boards/arduino-uno/blink.ts
ts/tests/boards/arduino-uno/blink.ts
import { Sources, Sinks, HIGH, LOW, run, byte, createSinks } from '../../../src/boards/arduino-uno'; function toggle(value: byte): byte { return value == HIGH ? LOW : HIGH; } function blink(arduino: Sources): Sinks { const sinks = createSinks(); sinks.LED$ = arduino.LED$.map(toggle); return sinks; } run(blin...
import { Sources, Sinks, HIGH, LOW, run, byte, createSinks } from '../../../src/boards/arduino-uno'; function toggle(value: byte): byte { return value == HIGH ? LOW : HIGH; } function blink(arduino: Sources): Sinks { const sinks: Sinks = createSinks(); sinks.LED$ = arduino.LED$.map(toggle); return sinks; } r...
Add type to variable declaration
Add type to variable declaration
TypeScript
mit
artfuldev/RIoT
--- +++ @@ -5,7 +5,7 @@ } function blink(arduino: Sources): Sinks { - const sinks = createSinks(); + const sinks: Sinks = createSinks(); sinks.LED$ = arduino.LED$.map(toggle); return sinks; }
48670678be9a01b7bf8451b210af9e43bef5b05e
src/types/state.ts
src/types/state.ts
import { AlphabetsData } from '@/types/alphabets' import { Sentence } from '@/types/phrases' /* * State * The Vuex store state */ export type State = { text: string alphabets: AlphabetsData phrases: Sentence[] settings: Settings } /* * Settings * Used for fine-tuning the output and stuff. Any of them ca...
import { AlphabetsData } from '@/types/alphabets' import { Sentence } from '@/types/phrases' /* * State * The Vuex store state */ export type State = { text: string alphabets: AlphabetsData phrases: Sentence[] settings: Settings } /* * Settings * Used for fine-tuning the output and stuff. Any of them ca...
Split up structure type into numeric size and string position
Split up structure type into numeric size and string position
TypeScript
mit
rossjrw/gallifreyo,rossjrw/gallifreyo,rossjrw/gallifreyo
--- +++ @@ -22,7 +22,6 @@ export type Settings = { splits: string[] selectedAlphabets: string[] - structure: string scaling: boolean watermark: boolean debug: boolean @@ -42,6 +41,8 @@ word: BlockConfig buffer: BufferConfig automatic: AutomaticConfig + sizeDependenceOnLength: number + posi...
f6a0a080f46f3b6d159b565b45458c5e066cc63d
app/navbar.component.ts
app/navbar.component.ts
import {Component, EventEmitter} from 'angular2/core'; import {NavbarTab} from './navbartab'; @Component({ selector: 'navbar', template: `<nav class="navbar"> <div class="nav"> <a *ngFor="#tab of tabs" [class.active]="tab === selectedTab" (click)="onSelect(tab)" href="#"> ...
import {Component, EventEmitter} from 'angular2/core'; import {NavbarTab} from './navbartab'; @Component({ selector: 'navbar', template: `<nav class="navbar"> <div class="nav"> <a *ngFor="#tab of tabs" [class.active]="tab === selectedTab" (click)="onSelect(tab)" href="#"> ...
Select the Reminders tab on load
Select the Reminders tab on load
TypeScript
mit
rzhw/redue,rzhw/redue,rzhw/redue
--- +++ @@ -25,7 +25,9 @@ { name: "Logged", filter: (s: number) => { return s > 2 } } ] - constructor() { + constructor() { } + + ngOnInit() { this.onSelect(this.tabs[0]); }
1b9360df5bb626c1d37e5144ef83d9da9c59a345
src/app/attribute-directives/tumblr-embedded-media.directive.ts
src/app/attribute-directives/tumblr-embedded-media.directive.ts
import {Directive, ElementRef, DoCheck} from '@angular/core'; @Directive({selector: '[tumblrEmbeddedMedia]'}) export class TumblrEmbeddedMediaDirective implements DoCheck { private el: ElementRef; constructor(el: ElementRef) { this.el = el; } ngDoCheck() { const mediaElements = this.e...
import {Directive, ElementRef, DoCheck} from '@angular/core'; @Directive({selector: '[tumblrEmbeddedMedia]'}) export class TumblrEmbeddedMediaDirective implements DoCheck { private el: ElementRef; constructor(el: ElementRef) { this.el = el; } ngDoCheck() { const mediaElements = this.e...
Add switch-target to embedded media and text following immediatly
Add switch-target to embedded media and text following immediatly
TypeScript
mit
zoehneto/tumblr-reader,zoehneto/tumblr-reader,zoehneto/tumblr-reader
--- +++ @@ -12,10 +12,21 @@ const mediaElements = this.el.nativeElement.querySelectorAll('img, video'); if (mediaElements.length > 0) { for (const mediaElement of mediaElements) { - mediaElement.parentElement.style.marginLeft = 0; - mediaElement.parentEleme...
ac6d7e02ebc68c8769d7ad8a31463ff457554d9e
frontend/src/app/application-dashboard/service/application-dashboard.service.ts
frontend/src/app/application-dashboard/service/application-dashboard.service.ts
import {Injectable} from '@angular/core'; import {HttpClient} from "@angular/common/http"; import {Observable} from "rxjs/index"; import {IPage} from "../model/page.model"; @Injectable() export class ApplicationDashboardService { constructor(private http: HttpClient) { } getPagesForJobGroup(applicationId: numb...
import {Injectable} from '@angular/core'; import {HttpClient} from "@angular/common/http"; import {Observable} from "rxjs/index"; import {IPage} from "../model/page.model"; @Injectable() export class ApplicationDashboardService { constructor(private http: HttpClient) { } getPagesForJobGroup(applicationId: numb...
Handle empty job group id in rest call for pages
[IT-2250] Handle empty job group id in rest call for pages
TypeScript
apache-2.0
IteraSpeed/OpenSpeedMonitor,iteratec/OpenSpeedMonitor,IteraSpeed/OpenSpeedMonitor,iteratec/OpenSpeedMonitor,IteraSpeed/OpenSpeedMonitor,iteratec/OpenSpeedMonitor,iteratec/OpenSpeedMonitor,iteratec/OpenSpeedMonitor
--- +++ @@ -12,7 +12,7 @@ getPagesForJobGroup(applicationId: number): Observable<IPage[]> { return this.http.get<IPage[]>("/applicationDashboard/getPagesForApplication", { params: { - applicationId: applicationId.toString() + applicationId: applicationId ? applicationId.toString() : "" ...
d82850d7e1672997e0e886e6abf08ab2c7b8cee6
src/TokenExceptions.ts
src/TokenExceptions.ts
import IToken from './IToken' import { GherkinException } from './Errors' export class UnexpectedTokenException extends GherkinException { public static create<TokenType>(token: IToken<TokenType>, expectedTokenTypes: string[]) { const message = `expected: ${expectedTokenTypes.join( ', ' )}, got '${toke...
import IToken from './IToken' import { GherkinException } from './Errors' export class UnexpectedTokenException extends GherkinException { public static create<TokenType>(token: IToken<TokenType>, expectedTokenTypes: string[]) { const message = `expected: ${expectedTokenTypes.join(', ')}, got '${token .get...
Downgrade hast-util-sanitize to 3.0.2 to avoid ESM errors
Downgrade hast-util-sanitize to 3.0.2 to avoid ESM errors
TypeScript
mit
cucumber/gherkin-javascript,cucumber/gherkin-javascript
--- +++ @@ -3,9 +3,9 @@ export class UnexpectedTokenException extends GherkinException { public static create<TokenType>(token: IToken<TokenType>, expectedTokenTypes: string[]) { - const message = `expected: ${expectedTokenTypes.join( - ', ' - )}, got '${token.getTokenValue().trim()}'` + const mes...
910a0b016ae596f3a982af1140d39895b6467f32
packages/react-cosmos-shared2/src/FixtureLoader/FixtureCapture/shared/findRelevantElementPaths.ts
packages/react-cosmos-shared2/src/FixtureLoader/FixtureCapture/shared/findRelevantElementPaths.ts
import React from 'react'; import { findElementPaths, getExpectedElementAtPath } from './nodeTree'; type ExtendedComponentClass = React.ComponentClass & { cosmosCapture?: boolean; }; export function findRelevantElementPaths(node: React.ReactNode): string[] { const elPaths = findElementPaths(node); return elPat...
import React from 'react'; import { findElementPaths, getExpectedElementAtPath } from './nodeTree'; type ExtendedComponentClass = React.ComponentClass & { cosmosCapture?: boolean; }; export function findRelevantElementPaths(node: React.ReactNode): string[] { const elPaths = findElementPaths(node); return elPat...
Enable using StrictMode in fixtures
Enable using StrictMode in fixtures
TypeScript
mit
skidding/react-cosmos,skidding/react-cosmos,skidding/cosmos,react-cosmos/react-cosmos,skidding/cosmos,react-cosmos/react-cosmos,react-cosmos/react-cosmos
--- +++ @@ -11,9 +11,11 @@ return elPaths.filter(elPath => { const { type } = getExpectedElementAtPath(node, elPath); - if (typeof type === 'string') { - return isInterestingTag(type); - } + // Ignore symbol types, like StrictMode + // https://github.com/react-cosmos/react-cosmos/issues/124...
c7608162a4dfc500c04475cf45583f0e358d0037
packages/webdriverio/src/index.ts
packages/webdriverio/src/index.ts
import { Browser } from 'mugshot'; /** * API adapter for WebdriverIO to make working with it saner. */ export default class WebdriverIOAdapter implements Browser { private browser: WebDriver.ClientAsync & WebdriverIOAsync.Browser; constructor(browser: WebDriver.ClientAsync & WebdriverIOAsync.Browser) { this...
import { Browser } from 'mugshot'; /* istanbul ignore next because this will get stringified and sent to the browser */ function getBoundingRect(selector: string): DOMRect { // @ts-ignore because querySelector can be null and we don't // care about browsers that don't support it. return document.querySelector(se...
Fix stringified function breaking under istanbul
Fix stringified function breaking under istanbul
TypeScript
mit
uberVU/mugshot,uberVU/mugshot
--- +++ @@ -1,4 +1,11 @@ import { Browser } from 'mugshot'; + +/* istanbul ignore next because this will get stringified and sent to the browser */ +function getBoundingRect(selector: string): DOMRect { + // @ts-ignore because querySelector can be null and we don't + // care about browsers that don't support it. +...
acbd8bcdef198be98c248c90868233dcf02e8ab7
src/Components/form-group-component/form-group-component.spec.ts
src/Components/form-group-component/form-group-component.spec.ts
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { FormGroupComponent } from './form-group-component'; describe('FormGroupComponent', () => { let component: FormGroupComponent; let fixture: ComponentFixture<FormGroupComponent>; beforeEach(async(() => { TestBed.configureTesti...
import {async, ComponentFixture, TestBed} from "@angular/core/testing"; import {FormGroupComponent} from "./form-group-component"; import {ErrorMessageService} from "../../Services/error-message.service"; import {CUSTOM_ERROR_MESSAGES} from "../../Tokens/tokens"; import {errorMessageService} from "../../ng-bootstrap-f...
Fix form group component test
Fix form group component test
TypeScript
mit
third774/ng-bootstrap-form-validation,third774/ng-bootstrap-form-validation,third774/ng-bootstrap-form-validation
--- +++ @@ -1,25 +1,39 @@ -import { async, ComponentFixture, TestBed } from '@angular/core/testing'; +import {async, ComponentFixture, TestBed} from "@angular/core/testing"; -import { FormGroupComponent } from './form-group-component'; +import {FormGroupComponent} from "./form-group-component"; +import {ErrorMessag...
2edee8cf9e3320ecb8a486dda36bdc18b795cbe6
java-front/languages/Java-1.5/expressions/types/bitwise-logical.ts
java-front/languages/Java-1.5/expressions/types/bitwise-logical.ts
module languages/Java-1.5/expressions/types/bitwise-logical imports include/Java lib/task/- lib/types/- lib/properties/- lib/relations/- languages/Java-1.5/types/types/primitives languages/Java-1.5/types/types/promotion type rules t@And(x, y) + t@ExcOr(x, y) + t@Or(x, y) : ty where x : x-ty and y...
module languages/Java-1.5/expressions/types/bitwise-logical imports include/Java lib/task/- lib/types/- lib/properties/- lib/relations/- languages/Java-1.5/types/types/primitives languages/Java-1.5/types/types/promotion type rules t@And(x, y) + t@ExcOr(x, y) + t@Or(x, y) : ty where x : x-ty and y...
Fix wrong type of not expression.
Fix wrong type of not expression.
TypeScript
apache-2.0
metaborg/java-front,metaborg/java-front
--- +++ @@ -36,7 +36,7 @@ and x-ty == Boolean() and y-ty == Boolean() else error "Expected booleans" on t - Not(e) : ty + Not(e) : Boolean() where e : ty and ty == Boolean() else error "Expected boolean" on e
0a6d22a4c7840f7a7ffcd3cfbeacd886e77eb9d9
app/views/sessions/session/visualization/textvisualization/textvisualization.component.ts
app/views/sessions/session/visualization/textvisualization/textvisualization.component.ts
import FileResource from "../../../../../resources/fileresource"; import SessionDataService from "../../sessiondata.service"; class TextVisualizationController { static $inject = ['FileResource', '$scope', 'SessionDataService']; datasetId: string; data: string; constructor(private fileResource: File...
import FileResource from "../../../../../resources/fileresource"; import SessionDataService from "../../sessiondata.service"; class TextVisualizationController { static $inject = ['FileResource', '$scope', 'SessionDataService']; datasetId: string; data: string; constructor(private fileResource: File...
Update view when we get the reponse
Update view when we get the reponse
TypeScript
mit
chipster/chipster-web,chipster/chipster-web,chipster/chipster-web
--- +++ @@ -13,7 +13,9 @@ $onInit() { this.fileResource.getData(this.SessionDataService.getSessionId(), this.datasetId).then( (resp: any) => { - this.data = resp.data; + this.$scope.$apply(() => { + this.data = resp.data; + }); }); }
555166bb60ce537936009bc8f886473c7e7a88cf
screensaver_ru.ts
screensaver_ru.ts
<?xml version="1.0" ?><!DOCTYPE TS><TS language="ru" version="2.0"> <context> <name>PanelScreenSaver</name> <message> <source>Panel Screensaver Global shortcut: &apos;%1&apos; cannot be registered</source> <translation>Глобальная Панель клавиш короткий путь Заставка: &apos;%1&apos; не могут быть...
<?xml version="1.0" encoding="utf-8"?> <!DOCTYPE TS> <TS version="2.1" language="ru"> <context> <name>PanelScreenSaver</name> <message> <location filename="../panelscreensaver.cpp" line="52"/> <source>Lock Screen</source> <translation>Блокировать экран</translation> </message> <m...
Revert "Commit from LXDE Pootle server by user LStranger.: 391 of 391 strings translated (0 need review)."
Revert "Commit from LXDE Pootle server by user LStranger.: 391 of 391 strings translated (0 need review)." This reverts commit d538764d91b1cf3ea993cdf0d6200eea2b2c9384. It appeared this change was wrong because it was out of sync.
TypeScript
lgpl-2.1
lxde/lxqt-l10n
--- +++ @@ -1,9 +1,17 @@ -<?xml version="1.0" ?><!DOCTYPE TS><TS language="ru" version="2.0"> +<?xml version="1.0" encoding="utf-8"?> +<!DOCTYPE TS> +<TS version="2.1" language="ru"> <context> <name>PanelScreenSaver</name> <message> - <source>Panel Screensaver Global shortcut: &apos;%1&apos; cannot ...
cf4e14adace565fb38c9fea4630ddf2a687fb3b2
generators/app/templates/src/index.ts
generators/app/templates/src/index.ts
export * from './<%- ngModuleFilename %>'; // all components that will be codegen'd need to be exported for AOT to work export * from './helloWorld.component';
export * from './<%- ngModuleFilename.replace('.ts', '') %>'; // all components that will be codegen'd need to be exported for AOT to work export * from './helloWorld.component';
Remove .ts from module filename import
Remove .ts from module filename import
TypeScript
mit
mattlewis92/generator-angular-library,mattlewis92/generator-angular-library,mattlewis92/generator-angular-library
--- +++ @@ -1,4 +1,4 @@ -export * from './<%- ngModuleFilename %>'; +export * from './<%- ngModuleFilename.replace('.ts', '') %>'; // all components that will be codegen'd need to be exported for AOT to work export * from './helloWorld.component';
b830f908ae488308596a9dd50d42e0275cab96fc
projects/angular2-cookie-law/src/lib/angular2-cookie-law.service.ts
projects/angular2-cookie-law/src/lib/angular2-cookie-law.service.ts
/** * angular2-cookie-law * * Copyright 2016-2018, @andreasonny83, All rights reserved. * * @author: @andreasonny83 <andreasonny83@gmail.com> */ import { Injectable } from '@angular/core'; @Injectable({ providedIn: 'root' }) export class Angular2CookieLawService { public seen(cookieName: string = 'cookieLaw...
/** * angular2-cookie-law * * Copyright 2016-2018, @andreasonny83, All rights reserved. * * @author: @andreasonny83 <andreasonny83@gmail.com> */ import { Inject, Injectable, PLATFORM_ID } from '@angular/core'; import { DOCUMENT, isPlatformBrowser } from '@angular/common'; @Injectable({ providedIn: 'root' }) e...
Reimplement fix for Angular Universal compatibility and make sure it doesn't break the production build
Reimplement fix for Angular Universal compatibility and make sure it doesn't break the production build
TypeScript
mit
andreasonny83/angular2-cookie-law,andreasonny83/angular2-cookie-law,andreasonny83/angular2-cookie-law
--- +++ @@ -6,14 +6,25 @@ * @author: @andreasonny83 <andreasonny83@gmail.com> */ -import { Injectable } from '@angular/core'; +import { Inject, Injectable, PLATFORM_ID } from '@angular/core'; +import { DOCUMENT, isPlatformBrowser } from '@angular/common'; @Injectable({ providedIn: 'root' }) export class...
e315e8aa4ce8acc3d4173f8b43f034b0e802c731
src/Test/Ast/Config/Image.ts
src/Test/Ast/Config/Image.ts
import { expect } from 'chai' import Up from '../../../index' import { ImageNode } from '../../../SyntaxNodes/ImageNode' import { DocumentNode } from '../../../SyntaxNodes/DocumentNode' describe('The term that represents image conventions', () => { const up = new Up({ terms: { image: 'see' } }) it('comes f...
import { expect } from 'chai' import Up from '../../../index' import { ImageNode } from '../../../SyntaxNodes/ImageNode' import { DocumentNode } from '../../../SyntaxNodes/DocumentNode' describe('The term that represents image conventions', () => { const up = new Up({ terms: { image: 'see' } }) it('comes f...
Add 2 tests, 1 failing
Add 2 tests, 1 failing
TypeScript
mit
start/up,start/up
--- +++ @@ -24,4 +24,23 @@ expect(up.toAst(mixedCase)).to.be.eql(up.toAst(lowercase)) }) + + it('ignores any regular expression syntax', () => { + const markup = '[+see+: Chrono Cross logo][https://example.com/cc.png]' + + expect(Up.toAst(markup, { terms: { image: '+see+' } })).to.be.eql( + new ...
2e0c128ba193c14bd61a2ec415eb69293e5373ae
src/utils/Urls.ts
src/utils/Urls.ts
export class Urls { public static image(key: string, size: number): string { return `https://d1cuyjsrcm0gby.cloudfront.net/${key}/thumb-${size}.jpg?origin=mapillary.webgl`; } public static mesh(key: string): string { return `https://d1cuyjsrcm0gby.cloudfront.net/${key}/sfm/v1.0/atomic_mesh....
export class Urls { public static image(key: string, size: number): string { return `https://d1cuyjsrcm0gby.cloudfront.net/${key}/thumb-${size}.jpg?origin=mapillary.webgl`; } public static mesh(key: string): string { return `https://d1cuyjsrcm0gby.cloudfront.net/${key}/sfm/v1.0/atomic_mesh....
Use cloudfront for mes2pbf address
Use cloudfront for mes2pbf address
TypeScript
mit
mapillary/mapillary-js,mapillary/mapillary-js
--- +++ @@ -8,7 +8,7 @@ } public static proto_mesh(key: string): string { - return `http://mapillary-mesh2pbf.mapillary.io/v2/mesh/${key}`; + return `https://d1brzeo354iq2l.cloudfront.net/v2/mesh/${key}`; } }
9a3b81daab3fd2ca3134eacc1425b8b42b783865
src/lib/convert.ts
src/lib/convert.ts
class Convert { static baseMIDINum = 69; // ref: // - https://github.com/watilde/beeplay/blob/master/src/modules/nn.js static keyToNote(name: string): number { var KEYS = [ "c", "c#", "d", "d#", "e", "f", "f#", "g", "g#", "a", "a#", "b" ]; var index = (name...
class Convert { /**! * Copyright (c) 2014 Daijiro Wachi <daijiro.wachi@gmail.com> * Released under the MIT license * https://github.com/watilde/beeplay/blob/master/src/modules/nn.js */ static keyToNote(name: string): number { var KEYS = [ "c", "c#", "d", "d#", "e", "f", "f#",...
Add license notation for Convert.keyToNote()
Add license notation for Convert.keyToNote()
TypeScript
mit
kubosho/ano-gakki,kubosho/ano-gakki,kubosho/ano-gakki,kubosho/ano-gakki
--- +++ @@ -1,8 +1,9 @@ class Convert { - static baseMIDINum = 69; - - // ref: - // - https://github.com/watilde/beeplay/blob/master/src/modules/nn.js + /**! + * Copyright (c) 2014 Daijiro Wachi <daijiro.wachi@gmail.com> + * Released under the MIT license + * https://github.com/watilde/beeplay/blob/master/...
bc4d08716879e837841a53174448fb9c6178498b
test/cronParser.ts
test/cronParser.ts
import chai = require("chai"); import { CronParser } from "../src/cronParser"; let assert = chai.assert; describe("CronParser", function () { describe("parse", function () { it("should parse 5 part cron", function () { assert.equal(new CronParser("* * * * *").parse().length, 7); }); ...
import chai = require("chai"); import { CronParser } from "../src/cronParser"; let assert = chai.assert; describe("CronParser", function () { describe("parse", function () { it("should parse 5 part cron", function () { assert.equal(new CronParser("* * * * *").parse().length, 7); }); ...
Make test description more elegant
Make test description more elegant
TypeScript
mit
bradyholt/cRonstrue,bradyholt/cRonstrue
--- +++ @@ -18,7 +18,7 @@ assert.equal(new CronParser("* * * * * 2015").parse()[0], ""); }); - it("should blow up if expression is crap", function () { + it("should error if expression is not valid", function () { assert.throws(function () { new CronParser("sdlksCRAP...
0950df4cb6f398f4397c265cae92b3751a858b77
packages/notebook/src/index.ts
packages/notebook/src/index.ts
// Copyright (c) Jupyter Development Team. // Distributed under the terms of the Modified BSD License. import '../style/index.css'; export * from './actions'; export * from './celltools'; export * from './default-toolbar'; export * from './model'; export * from './modelfactory'; export * from './panel'; export * from...
// Copyright (c) Jupyter Development Team. // Distributed under the terms of the Modified BSD License. import '../style/index.css'; export * from './actions'; export * from './notebooktools'; export * from './default-toolbar'; export * from './model'; export * from './modelfactory'; export * from './panel'; export * ...
Fix compile error with obsolete import
Fix compile error with obsolete import
TypeScript
bsd-3-clause
jupyter/jupyterlab,jupyter/jupyterlab,jupyter/jupyterlab,jupyter/jupyterlab,jupyter/jupyterlab
--- +++ @@ -4,7 +4,7 @@ import '../style/index.css'; export * from './actions'; -export * from './celltools'; +export * from './notebooktools'; export * from './default-toolbar'; export * from './model'; export * from './modelfactory';
849f8f306c9ea5b7b4385a9ce2ac2d50ef357300
packages/shared/lib/interfaces/calendar/Invite.ts
packages/shared/lib/interfaces/calendar/Invite.ts
import { ICAL_ATTENDEE_ROLE, ICAL_ATTENDEE_STATUS } from '../../calendar/constants'; import { CachedKey } from '../CachedKey'; import { Calendar, CalendarSettings } from './Calendar'; import { CalendarEvent } from './Event'; import { VcalAttendeeProperty, VcalOrganizerProperty, VcalVeventComponent } from './VcalModel';...
import { ICAL_ATTENDEE_ROLE, ICAL_ATTENDEE_STATUS } from '../../calendar/constants'; import { CachedKey } from '../CachedKey'; import { Calendar, CalendarSettings } from './Calendar'; import { CalendarEvent } from './Event'; import { VcalAttendeeProperty, VcalOrganizerProperty, VcalVeventComponent } from './VcalModel';...
Add new Boolean to CalendarWidgetData interface
Add new Boolean to CalendarWidgetData interface CALWEB-1475
TypeScript
mit
ProtonMail/WebClient,ProtonMail/WebClient,ProtonMail/WebClient
--- +++ @@ -15,6 +15,7 @@ export interface CalendarWidgetData { calendar: Calendar; isCalendarDisabled: boolean; + calendarNeedsUserAction: boolean; memberID?: string; addressKeys?: CachedKey[]; calendarKeys?: CachedKey[];
e0aa0ca31e99a406b852ed6686a3c24d64309301
saleor/static/dashboard-next/storybook/Stories.test.ts
saleor/static/dashboard-next/storybook/Stories.test.ts
import createGenerateClassName from "@material-ui/core/styles/createGenerateClassName"; import initStoryshots from "@storybook/addon-storyshots"; import { configure, render } from "enzyme"; import * as Adapter from "enzyme-adapter-react-16"; import toJSON from "enzyme-to-json"; configure({ adapter: new Adapter() }); ...
import createGenerateClassName from "@material-ui/core/styles/createGenerateClassName"; import initStoryshots from "@storybook/addon-storyshots"; import { configure, render } from "enzyme"; import * as Adapter from "enzyme-adapter-react-16"; import toJSON from "enzyme-to-json"; configure({ adapter: new Adapter() }); ...
Apply any to a whole argument
Apply any to a whole argument
TypeScript
bsd-3-clause
maferelo/saleor,mociepka/saleor,UITools/saleor,UITools/saleor,mociepka/saleor,mociepka/saleor,UITools/saleor,maferelo/saleor,UITools/saleor,maferelo/saleor,UITools/saleor
--- +++ @@ -16,7 +16,7 @@ initStoryshots({ configPath: "saleor/static/dashboard-next/storybook/", test({ story }) { - const result = render((story as any).render()); + const result = render(story.render() as any); expect(toJSON(result)).toMatchSnapshot(); } });
175b7bdc43fc8c5363330cc9d5630be4673b2b7a
packages/lesswrong/components/recommendations/withContinueReading.ts
packages/lesswrong/components/recommendations/withContinueReading.ts
import gql from 'graphql-tag'; import { useQuery } from 'react-apollo'; import { getFragment } from '../../lib/vulcan-lib'; export const useContinueReading = () => { // FIXME: For some unclear reason, using a ...fragment in the 'sequence' part // of this query doesn't work (leads to a 400 Bad Request), so this is ...
import gql from 'graphql-tag'; import { useQuery } from 'react-apollo'; import { getFragment } from '../../lib/vulcan-lib'; export const useContinueReading = () => { // FIXME: For some unclear reason, using a ...fragment in the 'sequence' part // of this query doesn't work (leads to a 400 Bad Request), so this is ...
Fix an error in intermediate loading states which showed up in Sentry but didn't have any visible symptoms
Fix an error in intermediate loading states which showed up in Sentry but didn't have any visible symptoms
TypeScript
mit
Discordius/Lesswrong2,Discordius/Lesswrong2,Discordius/Lesswrong2,Discordius/Lesswrong2
--- +++ @@ -37,7 +37,7 @@ }); return { - continueReading: data.ContinueReading, + continueReading: data?.ContinueReading, loading, error }; }
14f533f5f5f86609233cb37b7d22feb407899f9a
lit_nlp/examples/custom_module/potato.ts
lit_nlp/examples/custom_module/potato.ts
/** * @fileoverview They're red, they're white, they're brown, * they get that way under-ground... * * This defines a custom module, which we'll import in main.ts to include in * the LIT app. */ // tslint:disable:no-new-decorators import {customElement} from 'lit/decorators'; import { html} from 'lit'; import {s...
/** * @fileoverview They're red, they're white, they're brown, * they get that way under-ground... * * This defines a custom module, which we'll import in main.ts to include in * the LIT app. */ // tslint:disable:no-new-decorators import {customElement} from 'lit/decorators'; import { html} from 'lit'; import {s...
Add the override keyword to class members in TypeScript files
Add the override keyword to class members in TypeScript files TypeScript’s override keyword (added in 4.3) works similarly to @Override in Java. It makes the intention clear and ensures there is actually a member in the base class with the same name. This helps with things like: - Typos in the overriding member name -...
TypeScript
apache-2.0
PAIR-code/lit,pair-code/lit,pair-code/lit,pair-code/lit,PAIR-code/lit,pair-code/lit,PAIR-code/lit,PAIR-code/lit,PAIR-code/lit,pair-code/lit
--- +++ @@ -17,9 +17,9 @@ /** Custom LIT module. Delicious baked, mashed, or fried. */ @customElement('potato-module') export class PotatoModule extends LitModule { - static title = 'Potato'; + static override title = 'Potato'; static override numCols = 4; - static template = () => { + static override templ...
d4eea028016092b36d9177616c9e6bb96df9abee
client/src/app/shared/angular/timestamp-route-transformer.directive.ts
client/src/app/shared/angular/timestamp-route-transformer.directive.ts
import { Directive, EventEmitter, HostListener, Output } from '@angular/core' @Directive({ selector: '[timestampRouteTransformer]' }) export class TimestampRouteTransformerDirective { @Output() timestampClicked = new EventEmitter<number>() @HostListener('click', ['$event']) public onClick ($event: Event) { ...
import { Directive, EventEmitter, HostListener, Output } from '@angular/core' @Directive({ selector: '[timestampRouteTransformer]' }) export class TimestampRouteTransformerDirective { @Output() timestampClicked = new EventEmitter<number>() @HostListener('click', ['$event']) public onClick ($event: Event) { ...
Fix relative links in video description
Fix relative links in video description
TypeScript
agpl-3.0
Chocobozzz/PeerTube,Chocobozzz/PeerTube,Chocobozzz/PeerTube,Chocobozzz/PeerTube
--- +++ @@ -10,31 +10,30 @@ public onClick ($event: Event) { const target = $event.target as HTMLLinkElement - if (target.hasAttribute('href')) { - const ngxLink = document.createElement('a') - ngxLink.href = target.getAttribute('href') + if (target.hasAttribute('href') !== true) return - ...
f9aee6fab8256a3fdba3e66c6a260a169b8f38df
lib/theming/src/utils.ts
lib/theming/src/utils.ts
import { rgba, lighten, darken } from 'polished'; export const mkColor = (color: string) => ({ color }); // Passing arguments that can't be converted to RGB such as linear-gradient // to library polished's functions such as lighten or darken throws the error // that crashes the entire storybook. It needs to be guarde...
import { rgba, lighten, darken } from 'polished'; import { logger } from '@storybook/client-logger'; export const mkColor = (color: string) => ({ color }); // Check if it is a string. This is for the sake of warning users // and the successive guarding logics that use String methods. const isColorString = (color: st...
Add validation of user input
Add validation of user input
TypeScript
mit
storybooks/react-storybook,storybooks/storybook,storybooks/storybook,kadirahq/react-storybook,storybooks/storybook,storybooks/storybook,storybooks/storybook,storybooks/storybook,kadirahq/react-storybook,storybooks/storybook,storybooks/react-storybook,storybooks/react-storybook,storybooks/react-storybook
--- +++ @@ -1,6 +1,22 @@ import { rgba, lighten, darken } from 'polished'; +import { logger } from '@storybook/client-logger'; + export const mkColor = (color: string) => ({ color }); + +// Check if it is a string. This is for the sake of warning users +// and the successive guarding logics that use String method...
6dac157aef5b2addbabe0fb23fb091cb574e53e0
app/javascript/retrospring/features/lists/membership.ts
app/javascript/retrospring/features/lists/membership.ts
import Rails from '@rails/ujs'; import { showNotification, showErrorNotification } from 'utilities/notifications'; import I18n from 'retrospring/i18n'; export function listMembershipHandler(event: Event): void { const checkbox = event.target as HTMLInputElement; const list = checkbox.dataset.list; let memberCoun...
import Rails from '@rails/ujs'; import { showNotification, showErrorNotification } from 'utilities/notifications'; import I18n from 'retrospring/i18n'; export function listMembershipHandler(event: Event): void { const checkbox = event.target as HTMLInputElement; const list = checkbox.dataset.list; const memberCo...
Adjust TypeScript logic for list member count
Adjust TypeScript logic for list member count
TypeScript
agpl-3.0
Retrospring/retrospring,Retrospring/retrospring,Retrospring/retrospring,Retrospring/retrospring,Retrospring/retrospring
--- +++ @@ -5,7 +5,8 @@ export function listMembershipHandler(event: Event): void { const checkbox = event.target as HTMLInputElement; const list = checkbox.dataset.list; - let memberCount = Number(document.querySelector(`span#${list}-members`).innerHTML); + const memberCountElement: HTMLElement = document.q...
5c920eb71b1f53bbc43c6820edd51e29ebb0e656
directive/templates/directive.ts
directive/templates/directive.ts
/// <reference path="../../app.d.ts" /> 'use strict'; angular.module('<%= appname %>') .directive('<%= camelName %>', function () { return { restrict: 'EA', <% if (needTemplate) { %>templateUrl: 'directives/<%= dashName %>/<%= dashName %>.html', <% } %>link: function...
/// <reference path="../../app.d.ts" /> 'use strict'; module <%= capName %>App.Directives.<%= camelName %> { angular.module('<%= appname %>') .directive('<%= camelName %>', function () { return { restrict: 'EA', <% if (needTemplate) { %>templateUrl: 'directi...
Update Directive Template for Typescript
Client: Update Directive Template for Typescript
TypeScript
bsd-3-clause
NovaeWorkshop/Nova,NovaeWorkshop/Nova,NovaeWorkshop/Nova
--- +++ @@ -1,13 +1,17 @@ /// <reference path="../../app.d.ts" /> 'use strict'; -angular.module('<%= appname %>') - .directive('<%= camelName %>', function () { - return { - restrict: 'EA', - <% if (needTemplate) { %>templateUrl: 'directives/<%= dashName %>/<%= dashName %>.html...
5a3b201875e0d7b73e8b707c7aa35052c7692706
tests-integration/test-browser-umd.spec.ts
tests-integration/test-browser-umd.spec.ts
// @types/puppeteer causing a lot of conflicts with @types/node. Removing for now. //import puppeteer, { Browser, Page } from 'puppeteer'; const puppeteer = require( 'puppeteer' ); describe( 'Autolinker.js UMD file in browser', function() { let browser: any; // :Browser let page: any; // :Page beforeAll( as...
// @types/puppeteer causing a lot of conflicts with @types/node. Removing for now. //import puppeteer, { Browser, Page } from 'puppeteer'; const puppeteer = require( 'puppeteer' ); describe( 'Autolinker.js UMD file in browser', function() { let browser: any; // :Browser let page: any; // :Page beforeAll( as...
Add test for Autolinker.matcher.Matcher in browser
Add test for Autolinker.matcher.Matcher in browser
TypeScript
mit
gregjacobs/Autolinker.js,gregjacobs/Autolinker.js,gregjacobs/Autolinker.js,closeio/Autolinker.js,closeio/Autolinker.js,closeio/Autolinker.js,closeio/Autolinker.js,gregjacobs/Autolinker.js
--- +++ @@ -30,5 +30,14 @@ expect( innerHTML ).toBe( 'Go to <a href="http://google.com">google.com</a>' ); } ); + + + it( 'should expose `Autolinker.matcher.Matcher` so that it can be extended', async () => { + const typeofMatcher = await page.evaluate( () => { + return typeof ( window as any ).Autolinker...
8db66113420dbcf3e2a2d0625e164f628341aa3e
src/bonziri.ts
src/bonziri.ts
/// <reference path="bonziri.impl.ts" /> //'use strict' namespace Bonziri { export function generateScenario(jsonText: string): Scenario { return Impl.generateScenario(jsonText); } }
/// <reference path="bonziri.impl.ts" /> //'use strict' namespace Bonziri { export function generateScenario(jsonText: string): Scenario { try { return Impl.generateScenario(jsonText); } catch (e) { alert(e); throw e; } } }
Add try-catch statement in Bonziri decoding
Add try-catch statement in Bonziri decoding
TypeScript
mit
kndysfm/bonziri,kndysfm/bonziri,kndysfm/bonziri,kndysfm/bonziri
--- +++ @@ -4,7 +4,12 @@ namespace Bonziri { export function generateScenario(jsonText: string): Scenario { - return Impl.generateScenario(jsonText); + try { + return Impl.generateScenario(jsonText); + } catch (e) { + alert(e); + throw e; + } }...
84094b61ee1e204285a1123378698440f622d032
server/chat-jsx.ts
server/chat-jsx.ts
/** * PS custom HTML elements and Preact handling. * By Mia and Zarel */ import preact from 'preact'; import render from 'preact-render-to-string'; import {Utils} from '../lib'; /** For easy concenation of Preact nodes with strings */ export function html( strings: TemplateStringsArray, ...args: (preact.VNode | st...
/** * PS custom HTML elements and Preact handling. * By Mia and Zarel */ import preact from 'preact'; import render from 'preact-render-to-string'; import {Utils} from '../lib'; /** For easy concenation of Preact nodes with strings */ export function html( strings: TemplateStringsArray, ...args: (preact.VNode | st...
Fix definition for <username> in JSX
Fix definition for <username> in JSX (Apparently `children` is defined elsewhere...)
TypeScript
mit
xfix/Pokemon-Showdown,xfix/Pokemon-Showdown,svivian/Pokemon-Showdown,svivian/Pokemon-Showdown,xfix/Pokemon-Showdown,svivian/Pokemon-Showdown,xfix/Pokemon-Showdown,svivian/Pokemon-Showdown,svivian/Pokemon-Showdown,xfix/Pokemon-Showdown
--- +++ @@ -26,7 +26,7 @@ youtube: {src: string}; twitch: {src: string, width?: number, height?: number}; spotify: {src: string}; - username: {name?: string, children: string}; + username: {name?: string, class?: string}; psicon: {pokemon: string} | {item: string} | {type: string} | {category: string}; }
d1cc00981c8641e98bbd30d41c797310d498e0af
src/components/MdePreview.tsx
src/components/MdePreview.tsx
import * as React from "react"; import {GenerateMarkdownPreview} from "../types"; import {Simulate} from "react-dom/test-utils"; import load = Simulate.load; export interface ReactMdePreviewProps { className?: string; previewRef?: (ref: MdePreview) => void; emptyPreviewHtml?: string; minHeight: number;...
import * as React from "react"; import {GenerateMarkdownPreview} from "../types"; import * as classNames from "classnames"; export interface ReactMdePreviewProps { className?: string; previewRef?: (ref: MdePreview) => void; emptyPreviewHtml?: string; minHeight: number; generateMarkdownPreview: Gene...
Add CSS class loading to the preview
Add CSS class loading to the preview
TypeScript
mit
andrerpena/react-mde,andrerpena/react-mde,andrerpena/react-mde
--- +++ @@ -1,7 +1,6 @@ import * as React from "react"; import {GenerateMarkdownPreview} from "../types"; -import {Simulate} from "react-dom/test-utils"; -import load = Simulate.load; +import * as classNames from "classnames"; export interface ReactMdePreviewProps { className?: string; @@ -39,10 +38,10 @@ ...
defe9dce72e8518106ae38eeb782d133fb07f377
src/api/hosts/create.ts
src/api/hosts/create.ts
import { RequestHandler } from 'express' import { create, CreateHost } from './db' const handler: RequestHandler = async (req, res) => { const hostname = req.body.hostname || '' const vanityHostname = req.body.hostname || hostname || 'localhost' const dockerPort = req.body.dockerPort || 2375 const proxyIp = re...
import { RequestHandler } from 'express' import { create, CreateHost } from './db' const handler: RequestHandler = async (req, res) => { const hostname = req.body.hostname || '' const vanityHostname = req.body.hostname || hostname || 'localhost' const dockerPort = req.body.dockerPort || 2375 const proxyIp = re...
Remove ssh username check when providing hostname
Remove ssh username check when providing hostname
TypeScript
mit
the-concierge/concierge,the-concierge/concierge,the-concierge/concierge
--- +++ @@ -11,15 +11,6 @@ let credentialsId: number | null = Number(req.body.credentialsId) if (credentialsId < 1) { credentialsId = null - } - - const hasHostname = !!hostname.length - - if (hasHostname) { - res.status(400).json({ - message: 'Invalid SSH username provided: Must provided creden...
649348a41d5f64910f8c02633b3e5d36c4b584c0
packages/lesswrong/client/vulcan-lib/apollo-client/apolloClient.ts
packages/lesswrong/client/vulcan-lib/apollo-client/apolloClient.ts
import { ApolloClient, InMemoryCache, ApolloLink } from '@apollo/client'; import { BatchHttpLink } from '@apollo/client/link/batch-http'; import { apolloCacheVoteablePossibleTypes } from '../../../lib/make_voteable'; import meteorAccountsLink from './links/meteor'; import errorLink from './links/error'; export const c...
import { ApolloClient, InMemoryCache, ApolloLink } from '@apollo/client'; import { BatchHttpLink } from '@apollo/client/link/batch-http'; import { apolloCacheVoteablePossibleTypes } from '../../../lib/make_voteable'; import meteorAccountsLink from './links/meteor'; import errorLink from './links/error'; export const c...
Increase the maximum queries per batch in BatchHttpLink from 10 to 50
Increase the maximum queries per batch in BatchHttpLink from 10 to 50 In posts with a lot of Elicit predictions or hover-previewable links, this prevents excessive http requests and rerenders (previously it would make one http request for every 10).
TypeScript
mit
Discordius/Lesswrong2,Discordius/Lesswrong2,Discordius/Lesswrong2,Discordius/Lesswrong2
--- +++ @@ -15,6 +15,7 @@ const httpLink = new BatchHttpLink({ uri: '/graphql', credentials: 'same-origin', + batchMax: 50, }); return new ApolloClient({
0af57639ed8b9b0db032986ec0d8a0ab3cf4c8af
src/app/player-extendable-list/player-extendable-list.component.ts
src/app/player-extendable-list/player-extendable-list.component.ts
import { Component, OnInit, Input } from '@angular/core'; import { SharedModule } from '../shared/shared.module'; import { Player } from '../core/player.model'; import { PlayerService } from '../core/player.service'; @Component({ selector: 'player-extendable-list', templateUrl: './player-extendable-list.componen...
import { Component, OnInit, Input } from '@angular/core'; import { SharedModule } from '../shared/shared.module'; import { Player } from '../core/player.model'; import { PlayerService } from '../core/player.service'; @Component({ selector: 'player-extendable-list', templateUrl: './player-extendable-list.componen...
Use the same login for checking errors in addPlayer as well
Use the same login for checking errors in addPlayer as well
TypeScript
mit
hodossy/darts-scorer,hodossy/darts-scorer,hodossy/darts-scorer
--- +++ @@ -25,16 +25,15 @@ } addPlayer() { + this.hasError = false; if(!this.newPlayerName || '' == this.newPlayerName ) return; - for(let idx = 0; idx < this.players.length; idx++) { - if(this.newPlayerName == this.players[idx].name) { - this.hasError = true; - return; - }...
565959190db1a92b7244e3ae204cc7dfc247c77f
src/app/controlls/game-controll.ts
src/app/controlls/game-controll.ts
const FINISH_ZONE_KEY = 'finish-zone'; import {Boat} from '../sprites/boat'; export class GameControll { constructor(private game: Phaser.Game) { } public createBoat(x: number, y: number) { const boat = new Boat(this.game, x, y); this.game.add.existing(boat); this.game.physics.p2....
const FINISH_ZONE_KEY = 'finish-zone'; import {Boat} from '../sprites/boat'; export class GameControll { constructor(private game: Phaser.Game) { } public createBoat(x: number, y: number) { const boat = new Boat(this.game, x, y); this.game.add.existing(boat); this.game.physics.p2....
Add highscore results (part ;))
Add highscore results (part ;))
TypeScript
mit
bartoszbobin/global-game-jame-2017,bartoszbobin/global-game-jame-2017,bartoszbobin/global-game-jame-2017,bartoszbobin/global-game-jame-2017
--- +++ @@ -18,6 +18,10 @@ private completeLevel(body) { if (body.sprite.key === FINISH_ZONE_KEY) { + let highScore = JSON.parse(localStorage.getItem('highScore')); + highScore.push({userName: localStorage.getItem('userName'), score: 5}); + localStorage.setItem('highSc...
30084d7c97317747cb42cab0e570b0053deaf439
client/src/client.ts
client/src/client.ts
'use strict'; import * as path from 'path'; import { workspace, ExtensionContext } from 'vscode'; import { LanguageClient, LanguageClientOptions, ServerOptions, TransportKind } from 'vscode-languageclient'; export function activate(context: ExtensionContext) { let serverModule = context.asAbsolutePath(path....
'use strict'; import * as path from 'path'; import { workspace, ExtensionContext } from 'vscode'; import { LanguageClient, LanguageClientOptions, ServerOptions, TransportKind } from 'vscode-languageclient'; export function activate(context: ExtensionContext) { let serverModule = context.asAbsolutePath(path....
Update debug port and options
Update debug port and options
TypeScript
mit
sandhje/vscode-phpmd
--- +++ @@ -9,7 +9,7 @@ let serverModule = context.asAbsolutePath(path.join('server', 'server.js')); // Server debug options - let debugOptions = { execArgv: ["--debug=5701"] }; + let debugOptions = { execArgv: ["--nolazy", "--debug=6009"] }; // Server options let serverOptions: ServerOptions = {
55c13b22c569969d7e8e4482b9882628346944cb
modules/effects/src/actions.ts
modules/effects/src/actions.ts
import { Injectable, Inject } from '@angular/core'; import { Action, ScannedActionsSubject } from '@ngrx/store'; import { Observable } from 'rxjs/Observable'; import { Operator } from 'rxjs/Operator'; import { filter } from 'rxjs/operator/filter'; @Injectable() export class Actions<V = Action> extends Observable<V> { ...
import { Injectable, Inject } from '@angular/core'; import { Action, ScannedActionsSubject } from '@ngrx/store'; import { Observable } from 'rxjs/Observable'; import { Operator } from 'rxjs/Operator'; import { filter } from 'rxjs/operator/filter'; @Injectable() export class Actions<V = Action> extends Observable<V> { ...
Add generic type to the "ofType" operator
feat(Effects): Add generic type to the "ofType" operator
TypeScript
mit
brandonroberts/platform,brandonroberts/platform,brandonroberts/platform,brandonroberts/platform
--- +++ @@ -21,7 +21,7 @@ return observable; } - ofType(...allowedTypes: string[]): Actions<V> { + ofType<V2 extends V = V>(...allowedTypes: string[]): Actions<V2> { return filter.call(this, (action: Action) => allowedTypes.some(type => type === action.type) );
b85a69a7b83a097c2b88e82bbb308bcfc5c1a775
ui/src/ifql/components/FuncListItem.tsx
ui/src/ifql/components/FuncListItem.tsx
import React, {PureComponent} from 'react' interface Props { name: string onAddNode: (name: string) => void selectedFunc: string onSetSelectedFunc: (name: string) => void } export default class FuncListItem extends PureComponent<Props> { public render() { const {name} = this.props return ( <l...
import React, {PureComponent} from 'react' interface Props { name: string onAddNode: (name: string) => void selectedFunc: string onSetSelectedFunc: (name: string) => void } export default class FuncListItem extends PureComponent<Props> { public render() { const {name} = this.props return ( <l...
Make func list item active class into a getter
Make func list item active class into a getter
TypeScript
mit
influxdb/influxdb,mark-rushakoff/influxdb,nooproblem/influxdb,mark-rushakoff/influxdb,influxdb/influxdb,nooproblem/influxdb,influxdb/influxdb,mark-rushakoff/influxdb,nooproblem/influxdb,li-ang/influxdb,mark-rushakoff/influxdb,influxdb/influxdb,nooproblem/influxdb,influxdata/influxdb,nooproblem/influxdb,influxdb/influxd...
--- +++ @@ -15,14 +15,14 @@ <li onClick={this.handleClick} onMouseEnter={this.handleMouseEnter} - className={`ifql-func--item ${this.getActiveClass()}`} + className={`ifql-func--item ${this.activeClass}`} > {name} </li> ) } - private getActiveCl...
5e42a253807199e8f0d8af06b08aac53bb0bef15
app/src/container/App.tsx
app/src/container/App.tsx
import * as React from "react"; import { BrowserRouter, Redirect, Route } from "react-router-dom"; import SignIn from "./SignIn"; import Tasks from "./Tasks"; export default class extends React.Component { public render() { return ( <BrowserRouter> <div> <Ro...
import * as React from "react"; import { BrowserRouter, Redirect, Route } from "react-router-dom"; import SignIn from "./SignIn"; import Tasks from "./Tasks"; export default class extends React.Component { public render() { return ( <BrowserRouter> <div> <Ro...
Set exact options on routes
Set exact options on routes
TypeScript
mit
raviqqe/code2d,raviqqe/code2d,raviqqe/code2d,raviqqe/code2d
--- +++ @@ -9,11 +9,11 @@ return ( <BrowserRouter> <div> - <Route path="/" render={() => <Redirect to="/tasks" />} /> - <Route path="/tasks" render={() => <Redirect to="/tasks/todo" />} /> - <Route path="/tasks/todo" rende...
53880b782b5ec6b84d856c7eaadd530d2ebb0498
test/utils.ts
test/utils.ts
import { ChartConfig, ChartConfigProps } from "charts/ChartConfig" import * as fixtures from "./fixtures" export function createConfig(props: Partial<ChartConfigProps>) { const config = new ChartConfig(new ChartConfigProps(props)) // ensureValidConfig() is only run on non-node environments, so we have // ...
import { ChartConfig, ChartConfigProps } from "charts/ChartConfig" import * as fixtures from "./fixtures" export function createConfig(props?: Partial<ChartConfigProps>) { const config = new ChartConfig(new ChartConfigProps(props)) // ensureValidConfig() is only run on non-node environments, so we have //...
Make props optional in createConfig()
Make props optional in createConfig()
TypeScript
mit
OurWorldInData/owid-grapher,owid/owid-grapher,OurWorldInData/owid-grapher,OurWorldInData/owid-grapher,owid/owid-grapher,OurWorldInData/owid-grapher,owid/owid-grapher,owid/owid-grapher,OurWorldInData/owid-grapher,owid/owid-grapher
--- +++ @@ -2,7 +2,7 @@ import * as fixtures from "./fixtures" -export function createConfig(props: Partial<ChartConfigProps>) { +export function createConfig(props?: Partial<ChartConfigProps>) { const config = new ChartConfig(new ChartConfigProps(props)) // ensureValidConfig() is only run on non-node ...
745e63789707562e087f0e980cdb863de889ab9e
packages/react-input-feedback/src/index.ts
packages/react-input-feedback/src/index.ts
import { defaultTo, lensProp, merge, over, pipe } from 'ramda' import { ComponentClass, createElement as r, SFC } from 'react' import SequentialId from 'react-sequential-id' import { mapProps } from 'recompose' import { WrappedFieldProps } from 'redux-form' export type Component<P> = string | ComponentClass<P> | SFC<P...
import { ComponentClass, createElement as r, SFC } from 'react' import SequentialId, { ISequentialIdProps } from 'react-sequential-id' import { WrappedFieldProps } from 'redux-form' export type Component<P> = string | ComponentClass<P> | SFC<P> export interface IInputComponents { error: Component<any> input: Comp...
Stop using ramda and recompose
Stop using ramda and recompose
TypeScript
mit
thirdhand/components,thirdhand/components
--- +++ @@ -1,23 +1,30 @@ -import { defaultTo, lensProp, merge, over, pipe } from 'ramda' import { ComponentClass, createElement as r, SFC } from 'react' -import SequentialId from 'react-sequential-id' -import { mapProps } from 'recompose' +import SequentialId, { ISequentialIdProps } from 'react-sequential-id' impo...
ce4fc223ed0051dabcc3ca6d45079b7f20271962
packages/ui-interpreter/src/ui/Console.tsx
packages/ui-interpreter/src/ui/Console.tsx
import * as React from 'react' import Store from '../store' import Snapshot from './Snapshot' import { observer } from 'mobx-react' import ConsoleInput from './ConsoleInput' import Toolbar from './Toolbar' function Console({ store }: { store: Store }) { const style = { position: 'relative', overflow: 'auto' ...
import * as React from 'react' import Store from '../store' import Snapshot from './Snapshot' import { observer } from 'mobx-react' import ConsoleInput from './ConsoleInput' import Toolbar from './Toolbar' function Console({ store }: { store: Store }) { const style = { position: 'relative' } const snapshots = stor...
Remove extraneous scrollbar in console
Remove extraneous scrollbar in console
TypeScript
mit
evansb/respace,evansb/respace,evansb/respace,respace-js/respace,respace-js/respace
--- +++ @@ -6,10 +6,7 @@ import Toolbar from './Toolbar' function Console({ store }: { store: Store }) { - const style = { - position: 'relative', - overflow: 'auto' - } + const style = { position: 'relative' } const snapshots = store.snapshots.map((s, idx) => <Snapshot key={`snapshot-${idx}`} sn...
722fb44fc80cfcb3e7d47daa08fdf54cbe4531a3
src/marketplace/details/plan/actions.ts
src/marketplace/details/plan/actions.ts
import { openModalDialog } from '@waldur/modal/actions'; export const showOfferingPlanDescription = planDescription => openModalDialog('marketplaceOfferingPlanDescription', {resolve: {plan_description: planDescription}, size: 'md'}); export const showPlanDetailsDialog = resourceId => openModalDialog('marketplaceP...
import { openModalDialog } from '@waldur/modal/actions'; export const showOfferingPlanDescription = planDescription => openModalDialog('marketplaceOfferingPlanDescription', {resolve: {plan_description: planDescription}, size: 'md'}); export const showPlanDetailsDialog = resourceId => openModalDialog('marketplaceP...
Enlarge plan details dialog width to fit table
Enlarge plan details dialog width to fit table [WAL-2588]
TypeScript
mit
opennode/waldur-homeport,opennode/waldur-homeport,opennode/waldur-homeport,opennode/waldur-homeport
--- +++ @@ -4,4 +4,4 @@ openModalDialog('marketplaceOfferingPlanDescription', {resolve: {plan_description: planDescription}, size: 'md'}); export const showPlanDetailsDialog = resourceId => - openModalDialog('marketplacePlanDetailsDialog', {resolve: {resourceId}, size: 'md'}); + openModalDialog('marketplacePl...
3975095eba742a2df6ffeacaf03e50b1c8edc826
src/jpcontrol.ts
src/jpcontrol.ts
'use strict'; import * as vscode from 'vscode'; import * as jmespath from 'jmespath'; export class JMESPathController { private _outputChannel: vscode.OutputChannel; private _lastExpression: string; private _lastResult: any; constructor() { this._outputChannel = vscode.window.createOutputChan...
'use strict'; import * as vscode from 'vscode'; import * as jmespath from 'jmespath'; export class JMESPathController { private _outputChannel: vscode.OutputChannel; private _lastExpression: string; private _lastResult: any; constructor() { this._outputChannel = vscode.window.createOutputChan...
Fix bug when user cancels input text
Fix bug when user cancels input text
TypeScript
apache-2.0
jmespath/jmespath.vscode
--- +++ @@ -21,6 +21,9 @@ placeHolder: '', prompt: 'Enter a JMESPath expression' }).then(value => { + if (!value) { + return; + } let query = value; try { let result = jmespath.search(jsonDoc, query);
b7b58fa337c234b9cc21f9fa3b22a745d57ad875
components/datasource-selector/select-type-to-add-layer-dialog.component.ts
components/datasource-selector/select-type-to-add-layer-dialog.component.ts
/** * DEPRECATED * * @deprecated */ import {Component, Input} from '@angular/core'; import {HsDatasourcesService} from './datasource-selector.service'; @Component({ selector: 'hs-select-type-to-add-layer', template: require('./partials/select-type-to-add-layer-dialog.html'), }) export class HsSelectTypeToAddL...
import {Component, Input} from '@angular/core'; import {HsDatasourcesService} from './datasource-selector.service'; import {HsLayoutService} from '../layout/layout.service'; @Component({ selector: 'hs-select-type-to-add-layer', template: require('./partials/select-type-to-add-layer-dialog.html'), }) export class ...
Switch to layermanager after adding wfs layer from layman
Switch to layermanager after adding wfs layer from layman
TypeScript
mit
hslayers/hslayers-ng,hslayers/hslayers-ng,hslayers/hslayers-ng,hslayers/hslayers-ng
--- +++ @@ -1,11 +1,7 @@ -/** - * DEPRECATED - * - * @deprecated - */ import {Component, Input} from '@angular/core'; import {HsDatasourcesService} from './datasource-selector.service'; +import {HsLayoutService} from '../layout/layout.service'; @Component({ selector: 'hs-select-type-to-add-layer', @@ -20,7 ...
a74f7fabbf3661f3d002c88c51c36e5596834c16
commands/component/templates/spec.ts
commands/component/templates/spec.ts
/* ts-lint:disable:no-unused-variable */ import { TestBed, async } from '@angular/core/testing'; import { {{ componentName }} } from './{{ selector }}.component'; describe('{{ componentName }}', () => { beforeEach(() => { TestBed.configureTestingModule({ declarations: [ {{ compo...
/* ts-lint:disable:no-unused-variable */ import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { {{ componentName }} } from './{{ selector }}.component'; describe('{{ componentName }}', () => { let component: {{ componentName }}; let fixture: ComponentFixture<{{ componentName }}>; ...
Update to the testing of components.
Update to the testing of components. The setup now falls more inline with the guidelines from https://angular.io/docs/ts/latest/guide/testing.html#!#async-in-before-each
TypeScript
mit
gonzofish/angular-library-set,gonzofish/angular-librarian,gonzofish/angular-library-set,gonzofish/angular-library-set,gonzofish/angular-librarian,gonzofish/angular-librarian
--- +++ @@ -1,21 +1,26 @@ /* ts-lint:disable:no-unused-variable */ -import { TestBed, async } from '@angular/core/testing'; +import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { {{ componentName }} } from './{{ selector }}.component'; describe('{{ componentName }}', () => { - bef...
6f269ce6c879e0970c2dd2a3e1e322982f07dd04
packages/db-kit/bin/cli.ts
packages/db-kit/bin/cli.ts
import { start } from "@truffle/db-kit/cli"; async function main() { await start(); } main();
#!/usr/bin/env node import { start } from "@truffle/db-kit/cli"; async function main() { await start(); } main();
Add missing shebang and chmod +x
Add missing shebang and chmod +x
TypeScript
mit
ConsenSys/truffle
--- +++ @@ -1,3 +1,4 @@ +#!/usr/bin/env node import { start } from "@truffle/db-kit/cli"; async function main() {
0fff23dbe6fdbb9341805ba67fb307ee0bd5e1d0
pages/_document.tsx
pages/_document.tsx
import Document, { Head, Main, NextScript, NextDocumentContext } from 'next/document'; import * as http from 'http'; type MyDocumentProps = { locale: string; localeDataScript: string; }; export default class MyDocument extends Document<MyDocumentProps> { static async getInitialProps(context: NextDocumentC...
import * as React from 'react'; import Document, { Head, Main, NextScript, NextDocumentContext } from 'next/document'; import * as http from 'http'; type MyDocumentProps = { locale: string; localeDataScript: string; }; export default class MyDocument extends Document<MyDocumentProps> { static async getIni...
Add default title and meta viewport tags
Add default title and meta viewport tags
TypeScript
mit
krddevdays/krddevdays.ru,krddevdays/krddevdays.ru
--- +++ @@ -1,3 +1,4 @@ +import * as React from 'react'; import Document, { Head, Main, NextScript, NextDocumentContext } from 'next/document'; import * as http from 'http'; @@ -21,7 +22,10 @@ render() { return ( <html> - <Head /> + <Head> + ...
4d05189d8dbd6807684ff74d5ae502d05bced42a
tests/cases/conformance/classes/classDeclarations/mergedInheritedClassInterface.ts
tests/cases/conformance/classes/classDeclarations/mergedInheritedClassInterface.ts
interface BaseInterface { required: number; optional?: number; } declare class BaseClass { baseMethod(); x2: number; } interface Child extends BaseInterface { x3: number; } declare class Child extends BaseClass { x4: number; method(); } // checks if properties actually...
interface BaseInterface { required: number; optional?: number; } declare class BaseClass { baseMethod(); baseNumber: number; } interface Child extends BaseInterface { additional: number; } declare class Child extends BaseClass { classNumber: number; method(); } // chec...
Improve naming of test members
Improve naming of test members
TypeScript
apache-2.0
mmoskal/TypeScript,basarat/TypeScript,donaldpipowitch/TypeScript,Eyas/TypeScript,synaptek/TypeScript,nycdotnet/TypeScript,vilic/TypeScript,nycdotnet/TypeScript,donaldpipowitch/TypeScript,evgrud/TypeScript,kpreisser/TypeScript,ionux/TypeScript,DLehenbauer/TypeScript,basarat/TypeScript,alexeagle/TypeScript,vilic/TypeScri...
--- +++ @@ -5,15 +5,15 @@ declare class BaseClass { baseMethod(); - x2: number; + baseNumber: number; } interface Child extends BaseInterface { - x3: number; + additional: number; } declare class Child extends BaseClass { - x4: number; + classNumber: number; method(); } @@ -2...
c1ca35eac16c733262862856954a395207f7cbad
whisper/pages/index.tsx
whisper/pages/index.tsx
import {ApolloQueryResult} from "@apollo/client" import {GetStaticPropsResult} from "next" import {Fragment, FC} from "react" import PostsPayload from "type/api/PostsPayload" import getApollo from "lib/graphql/client/getApollo" import withError from "lib/error/withError" import layout from "lib/hoc/layout" import Bl...
import {ApolloQueryResult} from "@apollo/client" import {GetStaticPropsResult} from "next" import {Fragment, FC} from "react" import PostsPayload from "type/api/PostsPayload" import getApollo from "lib/graphql/client/getApollo" import withError from "lib/error/withError" import layout from "lib/hoc/layout" import Bl...
Add an option to revalidate home page
Add an option to revalidate home page
TypeScript
mit
octet-stream/eri,octet-stream/eri
--- +++ @@ -23,6 +23,7 @@ return { props, + revalidate: 60 } } )
643bb44ab4a0d1d8310ac31aba621bbe86150a02
packages/truffle-db/src/loaders/index.ts
packages/truffle-db/src/loaders/index.ts
import { TruffleDB } from "truffle-db"; import { ArtifactsLoader } from "./artifacts"; import { schema as rootSchema } from "truffle-db/schema"; import { Workspace, schema } from "truffle-db/workspace"; const tmp = require("tmp"); import { makeExecutableSchema } from "@gnd/graphql-tools"; import { gql } from "apollo-...
import { TruffleDB } from "truffle-db"; import { ArtifactsLoader } from "./artifacts"; import { schema as rootSchema } from "truffle-db/schema"; import { Workspace, schema } from "truffle-db/workspace"; const tmp = require("tmp"); import { makeExecutableSchema } from "@gnd/graphql-tools"; import { gql } from "apollo-...
Use tmp directory for build in manual truffle compile
Use tmp directory for build in manual truffle compile
TypeScript
mit
ConsenSys/truffle
--- +++ @@ -22,14 +22,17 @@ Mutation: { loadArtifacts: { resolve: async (_, args, { artifactsDirectory, contractsDirectory, db }, info) => { + const tempDir = tmp.dirSync({ unsafeCleanup: true }) const compilationConfig = { contracts_directory: contractsDirectory, - ...
06e00f620e630158c46e02e77397458394531b87
src/app/components/widgets/menu.component.ts
src/app/components/widgets/menu.component.ts
import {Renderer2} from '@angular/core'; import {MenuContext, MenuService} from '../menu-service'; /** * @author Daniel de Oliveira * @author Thomas Kleinke */ export abstract class MenuComponent { public opened: boolean = false; private removeMouseEventListener: Function|undefined; constructor(pri...
import {Renderer2} from '@angular/core'; import {MenuContext, MenuService} from '../menu-service'; /** * @author Daniel de Oliveira * @author Thomas Kleinke */ export abstract class MenuComponent { public opened: boolean = false; private removeMouseEventListener: Function|undefined; constructor(pri...
Fix closing layer & matrix menus
Fix closing layer & matrix menus
TypeScript
apache-2.0
codarchlab/idai-field-client,codarchlab/idai-field-client,codarchlab/idai-field-client,codarchlab/idai-field-client
--- +++ @@ -56,7 +56,7 @@ let inside = false; do { - if (target.id === this.buttonElementId || target.id.startsWith(this.menuElementsPrefix)) { + if (target.id && (target.id === this.buttonElementId || target.id.startsWith(this.menuElementsPrefix))) { inside ...
eb60ceab61185828f2c11a3c8b66f7703372df0b
lib/src/types.ts
lib/src/types.ts
import * as ReactNative from 'react-native'; import { LinearGradientProps } from 'react-native-linear-gradient'; export type StretchyImage = | ReactNative.ImageURISource | ReactNative.ImageRequireSource; export type StretchyOnScroll = ( position: number, reachedToBottomOfHeader: boolean, ) => void; export in...
import * as ReactNative from 'react-native'; import { LinearGradientProps } from 'react-native-linear-gradient'; export type StretchyImage = ReactNative.ImageSourcePropType export type StretchyOnScroll = ( position: number, reachedToBottomOfHeader: boolean, ) => void; export interface StretchyProps { backgroun...
Use ImageSourcePropType for StretchyImage type
Use ImageSourcePropType for StretchyImage type
TypeScript
mit
hamidhadi/react-native-stretchy,hamidhadi/react-native-stretchy,hamidhadi/react-native-stretchy,hamidhadi/react-native-stretchy
--- +++ @@ -1,9 +1,7 @@ import * as ReactNative from 'react-native'; import { LinearGradientProps } from 'react-native-linear-gradient'; -export type StretchyImage = - | ReactNative.ImageURISource - | ReactNative.ImageRequireSource; +export type StretchyImage = ReactNative.ImageSourcePropType export type Str...
029ac8c2e4b16d3532b254776c8c47f41d9c4999
src/utils/extend.ts
src/utils/extend.ts
import { Stream } from 'xstream'; export function shallowCopy(target: Object, source: Object) { for (var key in source) if (source.hasOwnProperty(key)) target[key] = source[key]; } export function shallowExtend(target: Object, ...sources: Object[]): Object { sources.forEach(source => shallowCopy(tar...
import { Stream } from 'xstream'; export function shallowCopy(target: Object, source: Object) { for (var key in source) if (source.hasOwnProperty(key)) target[key] = source[key]; } export function shallowExtend(target: Object, ...sources: Object[]): Object { sources.forEach(source => shallowCopy(tar...
Fix merge to pass tests
Fix merge to pass tests
TypeScript
mit
cyclic-ui/cyclic-ui,cyclic-ui/cyclic-ui
--- +++ @@ -12,11 +12,11 @@ } export function shallowExtendNew(target: Object, ...sources: Object[]): Object { - return shallowExtend({}, target, sources); + return shallowExtend({}, ...[target, ...sources]); } export function merge<T>(target: T, ...sources: T[]): T { - return shallowExtendNew(target, sour...
e472e1e61f452ac57a04521ae741410cce454198
app/src/ui/repository-settings/fork-contribution-target-description.tsx
app/src/ui/repository-settings/fork-contribution-target-description.tsx
import * as React from 'react' import { ForkContributionTarget } from '../../models/workflow-preferences' import { RepositoryWithForkedGitHubRepository } from '../../models/repository' interface IForkSettingsDescription { readonly repository: RepositoryWithForkedGitHubRepository readonly forkContributionTarget: Fo...
import * as React from 'react' import { ForkContributionTarget } from '../../models/workflow-preferences' import { RepositoryWithForkedGitHubRepository } from '../../models/repository' interface IForkSettingsDescription { readonly repository: RepositoryWithForkedGitHubRepository readonly forkContributionTarget: Fo...
Include line about autocomplete in fork preferences
Include line about autocomplete in fork preferences
TypeScript
mit
artivilla/desktop,say25/desktop,say25/desktop,shiftkey/desktop,desktop/desktop,j-f1/forked-desktop,kactus-io/kactus,desktop/desktop,say25/desktop,shiftkey/desktop,desktop/desktop,j-f1/forked-desktop,j-f1/forked-desktop,artivilla/desktop,kactus-io/kactus,shiftkey/desktop,shiftkey/desktop,artivilla/desktop,artivilla/desk...
--- +++ @@ -32,6 +32,10 @@ New branches will be based on{' '} <strong>{targetRepository.fullName}</strong>'s default branch. </li> + <li> + Autocompletion of user and issues will be based on{' '} + <strong>{targetRepository.fullName}</strong>. + </li> </ul> ) ...
6d8dbedcbd27f6eb2b1bc0e7b223100def826396
src/index.ts
src/index.ts
import * as express from "express" const app = express() app.get('/', (req, res) => { res.send('Hello Typescript!'); }) app.get('/:name', (req, res) => { const name: string = req.params.name; res.send('Hello ' + name + '!'); }) app.listen('8080') console.log('\nApp is running. To view it, open a web browser t...
import * as express from 'express' const app = express() app.get('/', (req, res) => { res.send('Hello Typescript!'); }) app.get('/:name', (req, res) => { const name: string = req.params.name; res.send('Hello ' + name + '!'); }) app.listen('8080') console.log('\nApp is running. To view it, open a web browser t...
Change an import statement from double quotes to single quotes.
Change an import statement from double quotes to single quotes.
TypeScript
agpl-3.0
majtom2grndctrl/hello-typescript-express
--- +++ @@ -1,4 +1,4 @@ -import * as express from "express" +import * as express from 'express' const app = express()
69d9febb874207981fac2f1d10a7f98ffbf0ce29
src/models/message.ts
src/models/message.ts
import mongoose from 'mongoose'; import Message from '@/interfaces/Message'; export interface IMessageModel extends Message, mongoose.Document { _receivers: mongoose.Types.DocumentArray<mongoose.Types.Subdocument>; } export const userRessourceSchema = new mongoose.Schema({ name: String, mail: String, language...
import mongoose from 'mongoose'; import Message from '@/interfaces/Message'; export interface IUserRessourceModel extends mongoose.Types.Subdocument { name: string, mail: string, language: string, payload: any, }; export interface IMessageModel extends Message, mongoose.Document { _receivers: mongoo...
Undo unwanted change in MessageModel
Undo unwanted change in MessageModel
TypeScript
mit
schulcloud/node-notification-service,schulcloud/node-notification-service,schulcloud/node-notification-service
--- +++ @@ -1,8 +1,15 @@ import mongoose from 'mongoose'; import Message from '@/interfaces/Message'; +export interface IUserRessourceModel extends mongoose.Types.Subdocument { + name: string, + mail: string, + language: string, + payload: any, +}; + export interface IMessageModel extends Message, mo...
ab9286c5885bbf298384ff82ad392a3474899a63
game/hud/src/gql/fragments/WeaponStatsFragment.ts
game/hud/src/gql/fragments/WeaponStatsFragment.ts
/* * This Source Code Form is subject to the terms of the Mozilla Public * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. * */ import gql from 'graphql-tag'; export const WeaponStatsFragment = gql` fragment WeaponStats on WeaponStat...
/* * This Source Code Form is subject to the terms of the Mozilla Public * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. * */ import gql from 'graphql-tag'; export const WeaponStatsFragment = gql` fragment WeaponStats on WeaponStat...
Add magicPower to WeaponStats fragment
Add magicPower to WeaponStats fragment
TypeScript
mpl-2.0
Mehuge/Camelot-Unchained,CUModSquad/Camelot-Unchained,Mehuge/Camelot-Unchained,csegames/Camelot-Unchained,csegames/Camelot-Unchained,Mehuge/Camelot-Unchained,csegames/Camelot-Unchained,CUModSquad/Camelot-Unchained,CUModSquad/Camelot-Unchained
--- +++ @@ -16,6 +16,7 @@ slashingArmorPenetration crushingDamage fallbackCrushingDamage + magicPower disruption deflectionAmount physicalProjectileSpeed
1e02cd5c638337697d2e28ce75526c050939351a
tools/utils/seed/server.ts
tools/utils/seed/server.ts
import * as express from 'express'; import * as openResource from 'open'; import * as serveStatic from 'serve-static'; import * as codeChangeTool from './code_change_tools'; import {resolve} from 'path'; import {APP_BASE, DOCS_DEST, DOCS_PORT, COVERAGE_PORT} from '../../config'; export function serveSPA() { codeChan...
import * as express from 'express'; import * as openResource from 'open'; import * as serveStatic from 'serve-static'; import * as codeChangeTool from './code_change_tools'; import {resolve} from 'path'; import {APP_BASE, DOCS_DEST, DOCS_PORT, COVERAGE_PORT} from '../../config'; export function serveSPA() { codeChan...
Add function to notify browser-sync
fix(build): Add function to notify browser-sync
TypeScript
mit
osulp/oe-ng2-seed,arun-awnics/mesomeds-ng2,idrabenia/angular2-crud,nickaranz/robinhood-ui,jigarpt/angular-seed-semi,idready/Bloody-Prophety-NG2,AnnaCasper/finance-tool,DallasAngularSuperHeroes/dash-ng2,Aurimas-Norkus/angular2-seed-arch,nlopezcenteno/angular2-seed,booleanVirus/POC,mraible/angular2-tutorial,natarajanmca1...
--- +++ @@ -7,6 +7,11 @@ export function serveSPA() { codeChangeTool.listen(); +} + +export function notifyLiveReload(e:any) { + let fileName = e.path; + codeChangeTool.changed(fileName); } export function serveDocs() {
49bd1778b60e5331a744588b6548856f98f5e651
src/app/app.component.ts
src/app/app.component.ts
import { Component } from '@angular/core'; @Component({ selector: 'app-root', templateUrl: './app.component.html', // styleUrls: ['./app.component.css'] styles: [`h3 {color: lightseagreen;}`] }) export class AppComponent { }
import {Component, ViewEncapsulation} from '@angular/core'; @Component({ selector: 'app-root', templateUrl: './app.component.html', // styleUrls: ['./app.component.css'] styles: [`h3 {color: lightseagreen;}`], encapsulation: ViewEncapsulation.Emulated // Native, None }) export class AppComponent { }
Add View Encapsulation property to App Component (l62)
Add View Encapsulation property to App Component (l62)
TypeScript
mit
topvova/angular-app,topvova/angular-app,topvova/angular-app
--- +++ @@ -1,10 +1,12 @@ -import { Component } from '@angular/core'; +import {Component, ViewEncapsulation} from '@angular/core'; @Component({ selector: 'app-root', templateUrl: './app.component.html', // styleUrls: ['./app.component.css'] - styles: [`h3 {color: lightseagreen;}`] + styles: [`h3 {color:...
e204d51c3a76559d93e99c1f2e2bd9a4a0cb328f
csComp/directives/LayersList/LayersDirectiveCtrl.ts
csComp/directives/LayersList/LayersDirectiveCtrl.ts
module LayersDirective { export interface ILayersDirectiveScope extends ng.IScope { vm: LayersDirectiveCtrl; } export class LayersDirectiveCtrl { private scope: ILayersDirectiveScope; // $inject annotation. // It provides $injector with information about dependencies to be...
module LayersDirective { export interface ILayersDirectiveScope extends ng.IScope { vm: LayersDirectiveCtrl; } export class LayersDirectiveCtrl { private scope: ILayersDirectiveScope; // $inject annotation. // It provides $injector with information about dependencies to be...
FIX Layers would no longer load.
FIX Layers would no longer load.
TypeScript
mit
rinzeb/csWeb,mkuzak/csWeb,c-martinez/csWeb,indodutch/csWeb,c-martinez/csWeb,c-martinez/csWeb,mkuzak/csWeb,TNOCS/csWeb,TNOCS/csWeb,Maartenvm/csWeb,Maartenvm/csWeb,rinzeb/csWeb,TNOCS/csWeb,rinzeb/csWeb,indodutch/csWeb,mkuzak/csWeb,indodutch/csWeb,Maartenvm/csWeb,mkuzak/csWeb,Maartenvm/csWeb
--- +++ @@ -25,7 +25,7 @@ } public toggleLayer(layer: csComp.Services.ProjectLayer): void { - layer.enabled = !layer.enabled; + //layer.enabled = !layer.enabled; if (layer.enabled) { this.$layerService.addLayer(layer); } else {
88ba78fda736fe08429948522b823e12994f8ecb
src/dart_indent_fixer.ts
src/dart_indent_fixer.ts
"use strict"; import * as vs from "vscode"; import { config } from "./config"; export class DartIndentFixer { onDidChangeActiveTextEditor(editor: vs.TextEditor) { if (editor && editor.document.languageId === "dart" && config.setIndentation) { editor.options = { insertSpaces: true, tabSize: 2 }; } ...
"use strict"; import * as vs from "vscode"; import * as path from "path"; import { config } from "./config"; export class DartIndentFixer { onDidChangeActiveTextEditor(editor: vs.TextEditor) { if (!(editor && editor.document)) return; let isDart = editor.document.languageId === "dart"; let isPubspec = edit...
Apply 2-space indents to pubspec.yaml too.
Apply 2-space indents to pubspec.yaml too. Fixes #140.
TypeScript
mit
Dart-Code/Dart-Code,Dart-Code/Dart-Code,Dart-Code/Dart-Code,Dart-Code/Dart-Code,Dart-Code/Dart-Code
--- +++ @@ -1,11 +1,17 @@ "use strict"; import * as vs from "vscode"; +import * as path from "path"; import { config } from "./config"; export class DartIndentFixer { onDidChangeActiveTextEditor(editor: vs.TextEditor) { - if (editor && editor.document.languageId === "dart" && config.setIndentation) { + if...
f18a8787adf25e16ae1e37617a760ea4093196d9
app/app.component.ts
app/app.component.ts
import { Component } from '@angular/core'; @Component({ selector: 'my-app', template: '<h1>{{title}}</h1><h2>{{hero.name}} details!</h2><div><label>id: </label>{{hero.id}}</div><div><label>name: </label>{{hero.name}}</div>' }) export class AppComponent { title = 'Tour of Heroes'; hero: Hero = { id: 10000, ...
import { Component } from '@angular/core'; @Component({ selector: 'my-app', template: <h1>{{title}}</h1> <h2>{{hero.name}} details!</h2> <div><label>id: </label>{{hero.id}}</div> <div><label>name: </label>{{hero.name}}</div> }) export class AppComponent { title = 'Tour of Heroes'; hero: Hero = { id: 1000...
Change template to multi-line. Should not change UI
Change template to multi-line. Should not change UI
TypeScript
mit
atbtm/Angular2-Pull-Repo,atbtm/Angular2-Pull-Repo,atbtm/Angular2-Pull-Repo
--- +++ @@ -2,7 +2,11 @@ @Component({ selector: 'my-app', - template: '<h1>{{title}}</h1><h2>{{hero.name}} details!</h2><div><label>id: </label>{{hero.id}}</div><div><label>name: </label>{{hero.name}}</div>' + template: + <h1>{{title}}</h1> + <h2>{{hero.name}} details!</h2> + <div><label>id: </label>{{hero.id...
3e3144eed8aab6476eefb5c8a38a451279f10fa6
app/main/index.ts
app/main/index.ts
import * as path from "path"; import * as url from "url"; // tslint:disable-next-line no-implicit-dependencies import { app } from "electron"; import * as fs from "fs-extra"; import ActionHubWindow from "./ActionHubWindow"; import { configDirPath, configName } from "./defaults"; fs.emptyDirSync(configDirPath); const...
import * as path from "path"; import * as url from "url"; // tslint:disable-next-line no-implicit-dependencies import { app } from "electron"; import * as fs from "fs-extra"; import ActionHubWindow from "./ActionHubWindow"; import { configDirPath, configName } from "./defaults"; fs.ensureDirSync(configDirPath); cons...
Fix typo emptyDirSync to ensureDirSync
Fix typo emptyDirSync to ensureDirSync
TypeScript
mit
ocboogie/action-hub,ocboogie/action-hub,ocboogie/action-hub
--- +++ @@ -8,7 +8,7 @@ import ActionHubWindow from "./ActionHubWindow"; import { configDirPath, configName } from "./defaults"; -fs.emptyDirSync(configDirPath); +fs.ensureDirSync(configDirPath); const window = new ActionHubWindow(app, path.join(configDirPath, configName)); app.on("ready", () => {
cf55a5d2f904588f205ac012e57142d800873966
src/app/journal/journal.component.spec.ts
src/app/journal/journal.component.spec.ts
import { JournalComponent } from './journal.component'; import { AnalysisService } from '../analysis/service/analysis.service'; import {DateChooserService} from '../shared/date-chooser.service'; describe('JournalComponent', () => { let component: JournalComponent; let analysisService: AnalysisService; let dateCh...
import { JournalComponent } from './journal.component'; import { Observable } from 'rxjs'; import { ConsumptionReport } from '../analysis/model/consumptionReport'; class DateChooserServiceStub { getChosenDateAsObservable(): Observable<Date> { return Observable.of(new Date()); } } class AnalysisServiceStub { ...
Write tests for the journal component
Write tests for the journal component
TypeScript
mit
stefanamport/nuba,stefanamport/nuba,stefanamport/nuba
--- +++ @@ -1,17 +1,48 @@ import { JournalComponent } from './journal.component'; -import { AnalysisService } from '../analysis/service/analysis.service'; -import {DateChooserService} from '../shared/date-chooser.service'; +import { Observable } from 'rxjs'; +import { ConsumptionReport } from '../analysis/model/cons...
1e8f0e281c9d3762e3e22a555496b418605160b7
src/app/game/join-form/game-join-form.spec.ts
src/app/game/join-form/game-join-form.spec.ts
import { GameJoinFormComponent } from './game-join-form.component'; import {TestComponentBuilder, addProviders, inject, async, ComponentFixture} from '@angular/core/testing'; import { Router } from '@angular/router'; class MockRouter {} describe('join-form game component', () => { let builder; beforeEach...
/* tslint:disable:no-unused-variable */ import { addProviders, async, inject } from '@angular/core/testing'; import { GameJoinFormComponent } from './game-join-form.component'; import { Router } from '@angular/router'; class MockRouter {} describe('GameJoinFormComponent: Testing', () => { beforeEach(() => { ad...
Add a test for the join game form component
Add a test for the join game form component
TypeScript
mit
s-robertson/things-angular,s-robertson/things-angular,s-robertson/things-angular,s-robertson/things-angular
--- +++ @@ -1,33 +1,23 @@ +/* tslint:disable:no-unused-variable */ + +import { addProviders, async, inject } from '@angular/core/testing'; import { GameJoinFormComponent } from './game-join-form.component'; -import {TestComponentBuilder, - addProviders, - inject, - async, - ComponentFixture} from '@angular/core/...
be2513b266e5bdeddb384d975eac98f5e3135d0a
tests/runners/runnerfactory.ts
tests/runners/runnerfactory.ts
///<reference path="runnerbase.ts" /> ///<reference path="compiler/runner.ts" /> ///<reference path="fourslash/fsrunner.ts" /> ///<reference path="projects/runner.ts" /> ///<reference path="unittest/unittestrunner.ts" /> class RunnerFactory { private runners = {}; public addTest(name: string) { ...
///<reference path="runnerbase.ts" /> ///<reference path="compiler/runner.ts" /> ///<reference path="fourslash/fsrunner.ts" /> ///<reference path="projects/runner.ts" /> ///<reference path="unittest/unittestrunner.ts" /> class RunnerFactory { private runners = {}; public addTest(name: string) { ...
Allow either slash type to be used in command line to harness
Allow either slash type to be used in command line to harness
TypeScript
apache-2.0
fdecampredon/jsx-typescript-old-version,popravich/typescript,tarruda/typescript,guidobouman/typescript,mbebenita/shumway.ts,mbrowne/typescript-dci,mbrowne/typescript-dci,mbebenita/shumway.ts,popravich/typescript,popravich/typescript,mbrowne/typescript-dci,hippich/typescript,rbirkby/typescript,vcsjones/typescript,fdecam...
--- +++ @@ -8,11 +8,12 @@ private runners = {}; public addTest(name: string) { - if (/tests\\cases\\compiler/.test(name)) { + var normalizedName = name.replace(/\\/g, "/"); // normalize slashes so either kind can be used on the command line + if (/tests\/cases\/compiler/.t...
c2cc79fab0d07597e835dc6399d44596ce4021bf
source/danger/peril_platform.ts
source/danger/peril_platform.ts
import { GitHub } from "danger/distribution/platforms/GitHub" import { Platform } from "danger/distribution/platforms/platform" import { dsl } from "./danger_run" const getPerilPlatformForDSL = (type: dsl, github: GitHub | null, githubEvent: any): Platform => { if (type === dsl.pr && github) { return github }...
import { GitHub } from "danger/distribution/platforms/GitHub" import { Platform } from "danger/distribution/platforms/platform" import { dsl } from "./danger_run" const getPerilPlatformForDSL = (type: dsl, github: GitHub | null, githubEvent: any): Platform => { if (type === dsl.pr && github) { return github }...
Add a check for the issue
Add a check for the issue
TypeScript
mit
danger/peril,danger/peril,danger/peril,danger/peril,danger/peril
--- +++ @@ -19,7 +19,7 @@ return {} as any }, name: "", - updateOrCreateComment: github!.updateOrCreateComment, + updateOrCreateComment: github ? github.updateOrCreateComment : nullFunc, } return platform }
c230e8d2d6f700ad205acebaf82dc8adba4f0c35
ERClient/src/app/emotion-to-color.pipe.spec.ts
ERClient/src/app/emotion-to-color.pipe.spec.ts
/* tslint:disable:no-unused-variable */ import { TestBed, async } from '@angular/core/testing'; import { EmotionToColorPipe } from './emotion-to-color.pipe'; describe('EmotionToColorPipe', () => { it('create an instance', () => { let pipe = new EmotionToColorPipe(); expect(pipe).toBeTruthy(); }); });
/* tslint:disable:no-unused-variable */ import { TestBed, async } from '@angular/core/testing'; import { EmotionToColorPipe } from './emotion-to-color.pipe'; describe('EmotionToColorPipe', () => { it('create an instance', () => { let pipe = new EmotionToColorPipe(); expect(pipe).toBeTruthy(); }); it('t...
Add test cases for EmotiontoColor pipe
Add test cases for EmotiontoColor pipe
TypeScript
apache-2.0
shioyang/EmotionalReader,shioyang/EmotionalReader,shioyang/EmotionalReader
--- +++ @@ -8,4 +8,14 @@ let pipe = new EmotionToColorPipe(); expect(pipe).toBeTruthy(); }); + + it('transform a value', () => { + let pipe = new EmotionToColorPipe(); + expect(pipe.transform('surprise')).toEqual('gold'); + }); + + it('transform an unknown value', () => { + let pipe = new Emo...
0e9a7606c2132c1d4816778df991347f708a5fcc
app/scripts/components/page/Page.tsx
app/scripts/components/page/Page.tsx
import React, { ReactNode } from 'react'; import { connect } from 'react-redux'; import { DefaultState, ThunkDispatchProp } from '../../interfaces'; import Header from './Header'; import Footer from './Footer'; type PageProps = { children: ReactNode; }; type PageStateProps = Pick<DefaultState, 'toast' | 'theme' ...
import React, { ReactNode } from 'react'; import { connect } from 'react-redux'; import { useLocation } from 'react-router'; import { DefaultState, ThunkDispatchProp } from '../../interfaces'; import Header from './Header'; import Footer from './Footer'; type PageProps = { children: ReactNode; }; type PageStateP...
Update site title with location data
Update site title with location data
TypeScript
mit
benct/tomlin-web,benct/tomlin-web
--- +++ @@ -1,5 +1,6 @@ import React, { ReactNode } from 'react'; import { connect } from 'react-redux'; +import { useLocation } from 'react-router'; import { DefaultState, ThunkDispatchProp } from '../../interfaces'; @@ -12,6 +13,12 @@ type PageStateProps = Pick<DefaultState, 'toast' | 'theme' | 'loading'>; ...
af0fa718d38ea2ae4e4a11d3bc1de848a4de8161
src/core/LogEvent.ts
src/core/LogEvent.ts
/** * @module core */ /** */ import {LogLevel} from "./LogLevel"; export class LogEvent { /** * Models a logging event. * @constructor * @param {String} _categoryName name of category * @param {LogLevel} _level level of message * @param {Array} _data objects to log * @param _context */ const...
/** * @module core */ /** */ import {LogLevel} from "./LogLevel"; export class LogEvent { /** * Models a logging event. * @constructor * @param {String} _categoryName name of category * @param {LogLevel} _level level of message * @param {Array} _data objects to log * @param _context */ const...
Add time field support to replace original startTime by a custom time
feat: Add time field support to replace original startTime by a custom time
TypeScript
mit
Romakita/ts-log-debug,Romakita/ts-log-debug
--- +++ @@ -18,7 +18,7 @@ private _startTime = new Date(); get startTime(): Date { - return this._startTime; + return this.data && this.data[0] && this.data[0].time ? this.data[0].time : this._startTime; } public get categoryName(): string {
e0ebe44331b3c52f69081fc4af9045fce9941a87
packages/@sanity/base/src/user-color/useUserColor.ts
packages/@sanity/base/src/user-color/useUserColor.ts
import {of} from 'rxjs' import {useObservable} from '../util/useObservable' import {useUserColorManager} from './provider' import {UserColor} from './types' import React from 'react' export function useUserColor(userId: string | null): Readonly<UserColor> | null { const manager = useUserColorManager() return useOb...
import {of} from 'rxjs' import {useObservable} from '../util/useObservable' import {useUserColorManager} from './provider' import {UserColor} from './types' import React from 'react' export function useUserColor(userId: string | null): UserColor | null { const manager = useUserColorManager() return useObservable( ...
Fix readonly being applied twice for user color
[base] Fix readonly being applied twice for user color
TypeScript
mit
sanity-io/sanity,sanity-io/sanity,sanity-io/sanity,sanity-io/sanity
--- +++ @@ -4,7 +4,7 @@ import {UserColor} from './types' import React from 'react' -export function useUserColor(userId: string | null): Readonly<UserColor> | null { +export function useUserColor(userId: string | null): UserColor | null { const manager = useUserColorManager() return useObservable( use...
c86f8024f9e43e90bf034ab0e4eb9babe32f603f
src/utils/content.ts
src/utils/content.ts
import { Validate } from './validate'; export interface IContentOptions { trimWhiteSpace: boolean; preserveIndentation: boolean; replaceNewLines: false | string; } export interface IContentExtractorOptions { content?: Partial<IContentOptions>; } export function validateContentOptions(options: IConten...
import { Validate } from './validate'; export interface IContentOptions { trimWhiteSpace: boolean; preserveIndentation: boolean; replaceNewLines: false | string; } export interface IContentExtractorOptions { content?: Partial<IContentOptions>; } export function validateContentOptions(options: IConten...
Normalize newlines in extracted JS string literals
Normalize newlines in extracted JS string literals
TypeScript
mit
lukasgeiter/gettext-extractor,lukasgeiter/gettext-extractor,lukasgeiter/gettext-extractor
--- +++ @@ -20,6 +20,7 @@ } export function normalizeContent(content: string, options: IContentOptions): string { + content = content.replace(/\r\n/g, '\n'); if (options.trimWhiteSpace) { content = content.replace(/^\n+|\s+$/g, ''); }
95b8da21e35669f8caa0e7e8598af2502d924804
src/utils/hitItem.ts
src/utils/hitItem.ts
import { Hit, Requester } from '../types'; import { generateBadges } from './badges'; import { truncate } from './formatting'; type ExceptionStatus = 'neutral' | 'warning' | 'critical'; export interface ExceptionDescriptor { status?: ExceptionStatus; title?: string; description?: string; } const gene...
import { Hit, Requester } from '../types'; import { generateBadges } from './badges'; import { truncate } from './formatting'; type ExceptionStatus = 'neutral' | 'warning' | 'critical'; export interface ExceptionDescriptor { status?: ExceptionStatus; title?: string; description?: string; } const gene...
Remove preview button and add text label to add hit button.
Remove preview button and add text label to add hit button.
TypeScript
mit
Anveio/mturk-engine,Anveio/mturk-engine,Anveio/mturk-engine
--- +++ @@ -19,14 +19,16 @@ const { requesterName, groupId, title } = hit; const actions = [ - { - icon: 'view', - external: true, - url: `https://www.mturk.com/mturk/preview?groupId=${groupId}` - }, + // { + // icon: 'view', + // external: true, + // url: `https://www.m...
3d0031c023f055fdb439d9033a053935f8698611
modern/src/runtime/Wac.ts
modern/src/runtime/Wac.ts
import MakiObject from "./MakiObject"; import { unimplementedWarning } from "../utils"; class Wac extends MakiObject { /** * getclassname() * * Returns the class name for the object. * @ret The class name. */ getclassname() { return "Wac"; } getguid(): string { return unimplementedWarni...
import MakiObject from "./MakiObject"; import { unimplementedWarning } from "../utils"; class Wac extends MakiObject { /** * getclassname() * * Returns the class name for the object. * @ret The class name. */ getclassname() { return "Wac"; } getguid(): string { return unimplementedWarni...
Use patched type for onnotify
Use patched type for onnotify
TypeScript
mit
captbaritone/winamp2-js,captbaritone/winamp2-js,captbaritone/winamp2-js
--- +++ @@ -41,11 +41,9 @@ return unimplementedWarning("isvisible"); } - // @ts-ignore This (deprecated) method's signature does not quite match the - // same method on MakiObject. This method is not used by any skins as far as - // we know, so we'll just ignore the issue for now. - onnotify(notifstr: s...
e408506aa89f84e922c33e207eec8499d96609ce
client/src/shared/calc.helper.ts
client/src/shared/calc.helper.ts
/** * Several static helper functions for calculations. */ export class Calc { public static maxIntegerValue = Math.pow(2, 31); public static partPercentage = (part: number, total: number) => (part / total) * 100; public static profitPercentage = (old: number, newAmount: number) => ((newAmount - old) / ...
/** * Several static helper functions for calculations. */ export class Calc { public static maxIntegerValue = 0x7FFFFFFF; public static partPercentage = (part: number, total: number) => (part / total) * 100; public static profitPercentage = (old: number, newAmount: number) => ((newAmount - old) / old) ...
Change maxIntegerValue to correct number.
Change maxIntegerValue to correct number.
TypeScript
mit
Ionaru/EVE-Track,Ionaru/EVE-Track,Ionaru/EVE-Track
--- +++ @@ -3,7 +3,7 @@ */ export class Calc { - public static maxIntegerValue = Math.pow(2, 31); + public static maxIntegerValue = 0x7FFFFFFF; public static partPercentage = (part: number, total: number) => (part / total) * 100; public static profitPercentage = (old: number, newAmount: number)...
81177b7c75672f81d74433438cfd3f04ad47d60b
app/core/datastore/pouchdb/sync-process.ts
app/core/datastore/pouchdb/sync-process.ts
import {Observable} from 'rxjs'; export interface SyncProcess { url: string; cancel(): void; observe: Observable<any>; } export enum SyncStatus { Offline = "OFFLINE", Unknown = "UNKNOWN", Pushing = "PUSHING", Pulling = "PULLING", InSync = "IN_SYNC", Error = "ERROR", Authentica...
import {Observable} from 'rxjs'; export interface SyncProcess { url: string; cancel(): void; observe: Observable<any>; } export enum SyncStatus { Offline = "OFFLINE", Pushing = "PUSHING", Pulling = "PULLING", InSync = "IN_SYNC", Error = "ERROR", AuthenticationError = "AUTHENTICATI...
Remove unknown from sync statuses
Remove unknown from sync statuses
TypeScript
apache-2.0
codarchlab/idai-field-client,codarchlab/idai-field-client,codarchlab/idai-field-client,codarchlab/idai-field-client
--- +++ @@ -9,7 +9,6 @@ export enum SyncStatus { Offline = "OFFLINE", - Unknown = "UNKNOWN", Pushing = "PUSHING", Pulling = "PULLING", InSync = "IN_SYNC",
cd2e0926f9de77fe8ef714de341a71521e51fe02
config/webpack.ts
config/webpack.ts
import path from 'path'; import options from '../utils/commandOptions'; /** * 该文件还会在客户端环境执行, 用结构赋值的方式会取不到值 * 因为客户端是基于文本匹配替换的值 */ // eslint-disable-next-line prefer-destructuring const env = process.env; function getFirstNotUndefined(...values) { for (let i = 0; i < values.length; i++) { if (values[i] !...
import path from 'path'; import options from '../utils/commandOptions'; /** * 该文件还会在客户端环境执行, 用结构赋值的方式会取不到值 * 因为客户端是基于文本匹配替换的值 */ // eslint-disable-next-line prefer-destructuring const env = process.env; function getFirstNotUndefined(...values) { for (let i = 0; i < values.length; i++) { if (values[i] !...
Solve the problem with font.woff assets file 404
chore: Solve the problem with font.woff assets file 404
TypeScript
mit
yinxin630/fiora,yinxin630/fiora,yinxin630/fiora
--- +++ @@ -32,7 +32,7 @@ }, index: path.resolve(__dirname, '../dist/index.html'), assetsRoot: path.resolve(__dirname, '../dist/fiora'), - assetsPublicPath: getFirstNotUndefined(options.publicPath, env.PublicPath, ''), + assetsPublicPath: getFirstNotUndefined(options.publicPat...