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 |
|---|---|---|---|---|---|---|---|---|---|---|
aa3feeb438edc2390157f55340bf159ff5c67670 | src/elmFormat.ts | src/elmFormat.ts | import * as vscode from 'vscode'
import { Range, TextEdit } from 'vscode'
import { execCmd } from './elmUtils'
export class ElmFormatProvider implements vscode.DocumentFormattingEditProvider {
provideDocumentFormattingEdits(
document: vscode.TextDocument,
options: vscode.FormattingOptions,
token: vs... | import * as vscode from 'vscode'
import { Range, TextEdit } from 'vscode'
import { execCmd } from './elmUtils'
export class ElmFormatProvider implements vscode.DocumentFormattingEditProvider {
provideDocumentFormattingEdits(
document: vscode.TextDocument,
options: vscode.FormattingOptions,
token: vs... | Fix issue with duplicate content after elm-format on v1.1.0 | Fix issue with duplicate content after elm-format on v1.1.0
| TypeScript | mit | Krzysztof-Cieslak/vscode-elm,sbrink/vscode-elm | ---
+++
@@ -18,7 +18,7 @@
return format
.then(({ stdout }) => {
- const wholeDocument = new Range(0, 0, Number.MAX_VALUE, Number.MAX_VALUE);
+ const wholeDocument = new Range(0, 0, document.lineCount, document.getText().length);
return [TextEdit.replace(wholeDocument, stdout)]... |
8a04609bdfda87de3b2c363abfe5ce405535e555 | test/unit/core/datastore/cached/get-sorted-ids.spec.ts | test/unit/core/datastore/cached/get-sorted-ids.spec.ts | import {getSortedIds} from '../../../../../app/core/datastore/cached/get-sorted-ids';
/**
* @author Daniel de Oliveira
*/
describe('getSortedIds', () => {
it('base', () => {
const as = [{ id: 'a', identifier: '1.a' }, { id: 'b', identifier: '1' }];
const result = getSortedIds(as as any, { q: '... | import {getSortedIds} from '../../../../../app/core/datastore/cached/get-sorted-ids';
/**
* @author Daniel de Oliveira
*/
describe('getSortedIds', () => {
it('exactMatchFirst', () => {
const as = [
{ id: 'a', identifier: 'AB-C1' },
{ id: 'b', identifier: 'AB-C2' },
{... | Adjust test for intended use case | Adjust test for intended use case
| TypeScript | apache-2.0 | codarchlab/idai-field-client,codarchlab/idai-field-client,codarchlab/idai-field-client,codarchlab/idai-field-client | ---
+++
@@ -5,13 +5,22 @@
*/
describe('getSortedIds', () => {
- it('base', () => {
+ it('exactMatchFirst', () => {
- const as = [{ id: 'a', identifier: '1.a' }, { id: 'b', identifier: '1' }];
+ const as = [
+ { id: 'a', identifier: 'AB-C1' },
+ { id: 'b', identifier: '... |
e7577d7a0f6c1c91fdccc89745cf4ef484349fa3 | src/app/overview-page/store/studies/studies.reducer.ts | src/app/overview-page/store/studies/studies.reducer.ts | import { EntityAdapter, EntityState, createEntityAdapter } from '@ngrx/entity'
import { Study } from '../../../shared/models/study.model'
import * as actions from './studies.actions'
export interface State extends EntityState<Study> {
isLoaded: boolean
}
export const adapter: EntityAdapter<Study> = createEntityAda... | import { EntityAdapter, EntityState, createEntityAdapter } from '@ngrx/entity'
import { Study } from '../../../shared/models/study.model'
import * as actions from './studies.actions'
export interface State extends EntityState<Study> {
isLoaded: boolean
}
export const adapter: EntityAdapter<Study> = createEntityAda... | Change entity id to projectName | Change entity id to projectName
| TypeScript | apache-2.0 | RADAR-CNS/RADAR-Dashboard,RADAR-CNS/RADAR-Dashboard,RADAR-CNS/RADAR-Dashboard,RADAR-CNS/RADAR-Dashboard | ---
+++
@@ -7,7 +7,9 @@
isLoaded: boolean
}
-export const adapter: EntityAdapter<Study> = createEntityAdapter<Study>()
+export const adapter: EntityAdapter<Study> = createEntityAdapter<Study>({
+ selectId: (study: Study) => study.projectName
+})
export const initialState: State = adapter.getInitialState({
... |
63de6c3f5164a16e60064400899b1079afb852ba | jovo-platforms/jovo-platform-lindenbaum/src/index.ts | jovo-platforms/jovo-platform-lindenbaum/src/index.ts | import { TestSuite } from 'jovo-core';
import { LindenbaumBot } from './core/LindenbaumBot';
import { LindenbaumRequestBuilder } from './core/LindenbaumRequestBuilder';
import { LindenbaumResponseBuilder } from './core/LindenbaumResponseBuilder';
export interface LindenbaumTestSuite
extends TestSuite<LindenbaumRequ... | import { TestSuite } from 'jovo-core';
import { LindenbaumBot } from './core/LindenbaumBot';
import { LindenbaumRequestBuilder } from './core/LindenbaumRequestBuilder';
import { LindenbaumResponseBuilder } from './core/LindenbaumResponseBuilder';
export interface LindenbaumTestSuite
extends TestSuite<LindenbaumRequ... | Add change to trigger version bump | :recycle: Add change to trigger version bump
| TypeScript | apache-2.0 | jovotech/jovo-framework-nodejs,jovotech/jovo-framework-nodejs | ---
+++
@@ -16,8 +16,7 @@
declare module 'jovo-core/dist/src/Interfaces' {
export interface Output {
- // tslint:disable-next-line:no-any
- Lindenbaum: any[];
+ Lindenbaum: any[]; // tslint:disable-line:no-any
}
}
|
af55e9851843c7b31b456f58471f8c9e546a9a5c | src/name-input-list/item.tsx | src/name-input-list/item.tsx | import * as React from 'react'
import flowRight from 'lodash-es/flowRight'
import {translate} from 'react-i18next'
import {SortableElement} from 'react-sortable-hoc'
import IconButton from '@material-ui/core/IconButton'
import TextField from '@material-ui/core/TextField'
import Tooltip from '@material-ui/core/Tooltip'
... | import * as React from 'react'
import flowRight from 'lodash-es/flowRight'
import {translate} from 'react-i18next'
import {SortableElement} from 'react-sortable-hoc'
import IconButton from '@material-ui/core/IconButton'
import TextField from '@material-ui/core/TextField'
import Tooltip from '@material-ui/core/Tooltip'
... | Fix incorrect error highlight in player name input list | Fix incorrect error highlight in player name input list
| TypeScript | mit | Holi0317/bridge-calc,Holi0317/bridge-calc,Holi0317/bridge-calc | ---
+++
@@ -23,7 +23,7 @@
<DragHandle />
<TextField type="text" fullWidth label={t('Player name')}
margin="normal"
- value={value} error={error != null} helperText={error}
+ value={value} error={error != null && error !== ''} helperText={error}
... |
fd112336e4018a329fd31d9b048d4894d1cd2b6a | src/app.tsx | src/app.tsx | import 'core-js/features/array';
import 'core-js/features/promise';
import React from 'react';
import ReactDOM from 'react-dom';
import Me from './Me';
const rootEl = document.getElementById('app');
ReactDOM.render(
<Me />,
rootEl,
);
| import 'core-js/features/array';
import 'core-js/features/object';
import 'core-js/features/promise';
import React from 'react';
import ReactDOM from 'react-dom';
import Me from './Me';
const rootEl = document.getElementById('app');
ReactDOM.render(
<Me />,
rootEl,
);
| Add object polyfill for IE11 | Add object polyfill for IE11
| TypeScript | mit | durasj/website,durasj/website,durasj/website | ---
+++
@@ -1,4 +1,5 @@
import 'core-js/features/array';
+import 'core-js/features/object';
import 'core-js/features/promise';
import React from 'react'; |
c12099fd8b5c53afae4ef43caa51a8f938ecace7 | src/ts/components/audiotrackselectbox.ts | src/ts/components/audiotrackselectbox.ts | import {SelectBox} from './selectbox';
import {ListSelectorConfig} from './listselector';
import {UIInstanceManager} from '../uimanager';
/**
* A select box providing a selection between available audio tracks (e.g. different languages).
*/
export class AudioTrackSelectBox extends SelectBox {
constructor(config: ... | import {SelectBox} from './selectbox';
import {ListSelectorConfig} from './listselector';
import {UIInstanceManager} from '../uimanager';
/**
* A select box providing a selection between available audio tracks (e.g. different languages).
*/
export class AudioTrackSelectBox extends SelectBox {
constructor(config: ... | Set initial selected audio track | Set initial selected audio track
| TypeScript | mit | bitmovin/bitmovin-player-ui,bitmovin/bitmovin-player-ui,bitmovin/bitmovin-player-ui,bitmovin/bitmovin-player-ui | ---
+++
@@ -43,5 +43,9 @@
// Populate tracks at startup
updateAudioTracks();
+
+ // When `playback.audioLanguage` is set, the `ON_AUDIO_CHANGED` event for that change is triggered before the
+ // UI is created. Therefore we need to set the audio track on configure.
+ audioTrackHandler();
}
} |
fc84c81a47039d998589372eedc95efaea42bcf7 | src/lib/util.ts | src/lib/util.ts | import { Component, ComponentProps } from 'preact';
type WhenProps = ComponentProps<When> & {
value: boolean,
children?: (JSX.Element | (() => JSX.Element))[]
};
type WhenState = {
ready: boolean
};
export class When extends Component<WhenProps, WhenState> {
state: WhenState = {
ready: !!this.props.value... | import { Component, ComponentProps } from 'preact';
type WhenProps = ComponentProps<When> & {
value: boolean,
children?: (JSX.Element | (() => JSX.Element))[]
};
type WhenState = {
ready: boolean
};
export class When extends Component<WhenProps, WhenState> {
state: WhenState = {
ready: !!this.props.value... | Make `@bind` the same as Surma's implementation | Make `@bind` the same as Surma's implementation
| TypeScript | apache-2.0 | GoogleChromeLabs/squoosh,GoogleChromeLabs/squoosh,GoogleChromeLabs/squoosh,GoogleChromeLabs/squoosh,GoogleChromeLabs/squoosh,GoogleChromeLabs/squoosh | ---
+++
@@ -39,11 +39,11 @@
// define an instance property pointing to the bound function.
// This effectively "caches" the bound prototype method as an instance property.
get() {
- let boundFunction = descriptor.value.bind(this);
+ let bound = descriptor.value.bind(this);
Object.defin... |
9b4e7b9eae24cdbc5634fbe4618c39748c44e93f | test/tools.ts | test/tools.ts | let customElId = 0;
export function customElName() {
++customElId;
return `x-${customElId}`;
}
| let customElId = 0;
export function customElName() {
++customElId;
return `x-${customElId}`;
}
declare global {
interface Window {
ShadowRoot: any;
}
}
| Add global ShadowRoot declaration on Window | Add global ShadowRoot declaration on Window
| TypeScript | mit | marcoms/make-element,marcoms/make-element,marcoms/make-element | ---
+++
@@ -4,3 +4,9 @@
++customElId;
return `x-${customElId}`;
}
+
+declare global {
+ interface Window {
+ ShadowRoot: any;
+ }
+} |
c9f76c1f147f33411b0f6e7dcc6dc054d0610ef9 | components/tf-audio-dashboard/test/audioDashboardTests.ts | components/tf-audio-dashboard/test/audioDashboardTests.ts | declare function stub(el: string, obj: any): void;
describe('audio dashboard tests', function() {
var audioDash;
var reloadCount = 0;
beforeEach(function() {
audioDash = fixture('testElementFixture');
var router = TF.Backend.router('data', true);
var backend = new TF.Backe... | /* Copyright 2016 The TensorFlow Authors. All Rights Reserved.
Licensed under the Apache License, Version 2.0 (the 'License');
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or a... | Add license header to file. Change: 134564823 | Add license header to file.
Change: 134564823
| TypeScript | apache-2.0 | agrubb/tensorboard,qiuminxu/tensorboard,tensorflow/tensorboard,ioeric/tensorboard,agrubb/tensorboard,qiuminxu/tensorboard,tensorflow/tensorboard,shakedel/tensorboard,francoisluus/tensorboard-supervise,agrubb/tensorboard,tensorflow/tensorboard,francoisluus/tensorboard-supervise,qiuminxu/tensorboard,ioeric/tensorboard,te... | ---
+++
@@ -1,3 +1,17 @@
+/* Copyright 2016 The TensorFlow Authors. All Rights Reserved.
+
+Licensed under the Apache License, Version 2.0 (the 'License');
+you may not use this file except in compliance with the License.
+You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+Un... |
669a1618daf227930cbc9c7574ef17d7c2d0ad40 | packages/third-parties/schema-formio/src/decorators/index.ts | packages/third-parties/schema-formio/src/decorators/index.ts | export * from "./component";
export * from "./currency";
export * from "./dataSourceJson";
export * from "./dataSourceUrl";
export * from "./hidden";
export * from "./inputTags";
export * from "./multiple";
export * from "./password";
export * from "./select";
export * from "./tableView";
export * from "./textarea";
ex... | export * from "./component";
export * from "./currency";
export * from "./dataSourceJson";
export * from "./dataSourceUrl";
export * from "./hidden";
export * from "./inputTags";
export * from "./multiple";
export * from "./password";
export * from "./select";
export * from "./tableView";
export * from "./textarea";
ex... | Add missing export for OpenWhenEmpty | fix(schema-formio): Add missing export for OpenWhenEmpty
| TypeScript | mit | Romakita/ts-express-decorators,Romakita/ts-express-decorators,Romakita/ts-express-decorators,Romakita/ts-express-decorators | ---
+++
@@ -27,3 +27,4 @@
export * from "./textCase";
export * from "./conditional";
export * from "./customConditional";
+export * from "./openWhenEmpty"; |
4089b913035698bf23bd8d876144b0f0fe826b60 | src/modules/articles/components/extensions/MediaExtension.tsx | src/modules/articles/components/extensions/MediaExtension.tsx | import * as React from 'react';
import { IExtensionProps } from './extensions';
import { ArticleMedia } from '../ArticleMedia';
interface IParsedProps {
mediumIds: string[]
}
export const MediaExtension: React.FunctionComponent<IExtensionProps> = ({ props, article }) => {
const parsedProps = props as IParsed... | import * as React from 'react';
import { IExtensionProps } from './extensions';
import { ArticleMedia } from '../ArticleMedia';
interface IParsedProps {
mediumIds: string[]
}
export const MediaExtension: React.FunctionComponent<IExtensionProps> = ({ props, article }) => {
const parsedProps = props as IParsed... | Use set for filtering media. | Use set for filtering media.
| TypeScript | mit | stuyspec/client-app | ---
+++
@@ -11,9 +11,11 @@
const parsedProps = props as IParsedProps;
//makes a copy so media filtering doesn't affect other components
- article = Object.assign({}, article);
- if (parsedProps.mediumIds && article.media) {
- article.media = article.media.filter(m => parsedProps.mediumIds.ind... |
e70138391bbfc88a036b752621d94a6d51698e3d | ui/src/app/tasks-jobs/executions/cleanup/cleanup.component.ts | ui/src/app/tasks-jobs/executions/cleanup/cleanup.component.ts | import { Component, EventEmitter, OnInit, Output } from '@angular/core';
import { TaskExecution } from '../../../shared/model/task-execution.model';
import { TaskService } from '../../../shared/api/task.service';
import { NotificationService } from '../../../shared/service/notification.service';
@Component({
selecto... | import { Component, EventEmitter, OnInit, Output } from '@angular/core';
import { TaskExecution } from '../../../shared/model/task-execution.model';
import { TaskService } from '../../../shared/api/task.service';
import { NotificationService } from '../../../shared/service/notification.service';
@Component({
selecto... | Fix task execution clean up blocking loading | Fix task execution clean up blocking loading
Resolves #1591
| TypeScript | apache-2.0 | BoykoAlex/spring-cloud-dataflow-ui,cppwfs/spring-cloud-dataflow-ui,BoykoAlex/spring-cloud-dataflow-ui,cppwfs/spring-cloud-dataflow-ui,BoykoAlex/spring-cloud-dataflow-ui,BoykoAlex/spring-cloud-dataflow-ui,spring-cloud/spring-cloud-dataflow-ui,cppwfs/spring-cloud-dataflow-ui,spring-cloud/spring-cloud-dataflow-ui,cppwfs/s... | ---
+++
@@ -19,6 +19,7 @@
open(executions: TaskExecution[]) {
this.executions = executions;
+ this.isRunning = false;
this.isOpen = true;
}
|
2ed7a4260060614b45e206ac3f4a2db2c8923e71 | src/app/daily-queue/daily-queue-list/daily-queue-list.component.ts | src/app/daily-queue/daily-queue-list/daily-queue-list.component.ts | import { Queue } from './../shared/queue.model';
import { DailyQueueService } from '../shared/daily-queue.service';
import { QueueElement } from '../shared/queueElement.model';
import { Component, OnInit } from '@angular/core';
@Component({
selector: 'app-daily-queue-list',
templateUrl: './daily-queue-list.compone... | import { Queue } from './../shared/queue.model';
import { DailyQueueService } from '../shared/daily-queue.service';
import { Component, OnInit } from '@angular/core';
@Component({
selector: 'app-daily-queue-list',
templateUrl: './daily-queue-list.component.html',
styleUrls: ['./daily-queue-list.component.css'],
... | Use new matches element and remove QueueElement model | Use new matches element and remove QueueElement model
| TypeScript | apache-2.0 | tomek199/elo-rating,tomek199/elo-rating,tomek199/elo-rating,tomek199/elo-rating | ---
+++
@@ -1,6 +1,5 @@
import { Queue } from './../shared/queue.model';
import { DailyQueueService } from '../shared/daily-queue.service';
-import { QueueElement } from '../shared/queueElement.model';
import { Component, OnInit } from '@angular/core';
@Component({ |
8a1a962c23f0bb762d28e38601b72960ae18c897 | src/responseFormatUtility.ts | src/responseFormatUtility.ts | 'use strict'
import { window } from 'vscode';
import { MimeUtility } from './mimeUtility';
var pd = require('pretty-data').pd;
export class ResponseFormatUtility {
public static FormatBody(body: string, contentType: string): string {
if (contentType) {
let mime = MimeUtility.parse(contentType)... | 'use strict'
import { window } from 'vscode';
import { MimeUtility } from './mimeUtility';
var pd = require('pretty-data').pd;
export class ResponseFormatUtility {
public static FormatBody(body: string, contentType: string): string {
if (contentType) {
let mime = MimeUtility.parse(contentType)... | Support mime type with json suffix | Support mime type with json suffix
| TypeScript | mit | Huachao/vscode-restclient,Huachao/vscode-restclient | ---
+++
@@ -10,7 +10,8 @@
let mime = MimeUtility.parse(contentType);
let type = mime.type;
let suffix = mime.suffix;
- if (type === 'application/json') {
+ if (type === 'application/json' ||
+ suffix === '+json') {
if (Respon... |
da673b146bbaa81884c98c960f41d5a03f71081c | web/src/App.tsx | web/src/App.tsx | import * as React from 'react';
import './App.css';
import logo from './logo.svg';
class App extends React.Component<{}, { apiMessage: string }> {
constructor(props: object) {
super(props);
this.state = { apiMessage: "" };
}
public componentDidMount() {
fetch("/api").then(r => r.text()).then(apiMe... | import * as React from 'react';
import './App.css';
import logo from './logo.svg';
class App extends React.Component<{}, { apiMessage: string }> {
constructor(props: object) {
super(props);
this.state = { apiMessage: "Loading... (If this takes too long, the database might be down.)" };
}
public compon... | Improve error responses on client side | Improve error responses on client side
| TypeScript | mit | ghotiphud/rust-web-starter,ghotiphud/rust-web-starter,ghotiphud/rust-web-starter,ghotiphud/rust-web-starter | ---
+++
@@ -7,15 +7,20 @@
constructor(props: object) {
super(props);
- this.state = { apiMessage: "" };
+ this.state = { apiMessage: "Loading... (If this takes too long, the database might be down.)" };
}
public componentDidMount() {
- fetch("/api").then(r => r.text()).then(apiMessage => {
... |
ed76e5eade81e34d7847a0673d12cfdc1f744077 | tests/src/service.spec.ts | tests/src/service.spec.ts | import { expect } from 'chai';
import { DebugService } from '../../lib/service';
describe('DebugService', () => {
let service = new DebugService();
describe('#constructor()', () => {
it('should create a new instance', () => {
expect(service).to.be.an.instanceOf(DebugService);
});
});
});
| import { expect } from 'chai';
import { ClientSession, IClientSession } from '@jupyterlab/apputils';
import { createClientSession } from '@jupyterlab/testutils';
import { DebugService } from '../../lib/service';
import { DebugSession } from '../../lib/session';
import { IDebugger } from '../../lib/tokens';
descri... | Add tests for start and stop for DebugService | Add tests for start and stop for DebugService
| TypeScript | bsd-3-clause | jupyter/jupyterlab,jupyter/jupyterlab,jupyter/jupyterlab,jupyter/jupyterlab,jupyter/jupyterlab | ---
+++
@@ -1,13 +1,66 @@
import { expect } from 'chai';
+
+import { ClientSession, IClientSession } from '@jupyterlab/apputils';
+
+import { createClientSession } from '@jupyterlab/testutils';
import { DebugService } from '../../lib/service';
+import { DebugSession } from '../../lib/session';
+
+import { IDebu... |
5c808ff99ed8c701dad23cf4fbfc45217e05ee38 | polygerrit-ui/app/elements/shared/gr-avatar/gr-avatar_html.ts | polygerrit-ui/app/elements/shared/gr-avatar/gr-avatar_html.ts | /**
* @license
* Copyright (C) 2020 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless require... | /**
* @license
* Copyright (C) 2020 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless require... | Fix bug in gr-avatar which wasn't hiding avatars when "hidden" is set | Fix bug in gr-avatar which wasn't hiding avatars when "hidden" is set
This happened for sites that did not set an avatar. Seems a recent
regression as it works on gerrit 3.3.
Release-Notes: skip
Change-Id: I148716b36c3d57e3eb3f1486b9539f1741d7288b
(cherry picked from commit e0358c2e4e7db76a7efe01de9cc14ef16af03a2e)
| TypeScript | apache-2.0 | GerritCodeReview/gerrit,GerritCodeReview/gerrit,GerritCodeReview/gerrit,GerritCodeReview/gerrit,GerritCodeReview/gerrit,GerritCodeReview/gerrit,GerritCodeReview/gerrit,GerritCodeReview/gerrit | ---
+++
@@ -18,6 +18,9 @@
export const htmlTemplate = html`
<style>
+ :host([hidden]) {
+ display: none;
+ }
:host {
display: inline-block;
border-radius: 50%; |
7f4b9a5ed47d815a369dad2291181215f5e072bb | yamcs-web/src/main/webapp/src/app/appbase/pages/ContextSwitchPage.ts | yamcs-web/src/main/webapp/src/app/appbase/pages/ContextSwitchPage.ts | import { ChangeDetectionStrategy, Component, OnInit } from '@angular/core';
import { ActivatedRoute, Router } from '@angular/router';
/*
* This component is a hack around the Angular routing system. It forces a full
* reload of a component by navigating away and back to a component.
*
* Without this code, each com... | import { ChangeDetectionStrategy, Component, OnInit } from '@angular/core';
import { ActivatedRoute, Router } from '@angular/router';
/*
* This component is a hack around the Angular routing system. It forces a full
* reload of a component by navigating away and back to a component.
*
* Without this code, each com... | Fix context switcher on parameter detail pages | Fix context switcher on parameter detail pages
| TypeScript | agpl-3.0 | m-sc/yamcs,fqqb/yamcs,fqqb/yamcs,m-sc/yamcs,yamcs/yamcs,yamcs/yamcs,m-sc/yamcs,m-sc/yamcs,yamcs/yamcs,yamcs/yamcs,yamcs/yamcs,m-sc/yamcs,fqqb/yamcs,yamcs/yamcs,m-sc/yamcs,fqqb/yamcs,fqqb/yamcs,fqqb/yamcs | ---
+++
@@ -22,12 +22,26 @@
// Query params do not work, because we use skipLocationChange to get here.
const paramMap = this.route.snapshot.paramMap;
const context = paramMap.get('context');
- const url = paramMap.get('current')!;
+ let url = paramMap.get('current')!;
+ // Carefully obtain ... |
d4fa30511b6e9d27f0d87a89a8139fa9abe22ceb | DeadBaseSample/src/DeadBaseSample/TypeScriptSource/deadbase.ts | DeadBaseSample/src/DeadBaseSample/TypeScriptSource/deadbase.ts | import { bootstrap, Component, NgModel } from 'angular2/angular2';
class ConcertSet {
date: Date;
venue: string;
set: number;
}
@Component({
selector: 'deadbase-app',
template: `
<h1>{{title}}</h1>
<h2>{{concert.date.toDateString()}} -- {{concert.venue}} Details!</h2>
<di... | import { bootstrap, Component, FORM_DIRECTIVES } from 'angular2/angular2';
class ConcertSet {
date: string;
venue: string;
set: number;
}
@Component({
selector: 'deadbase-app',
template: `
<h1>{{title}}</h1>
<h2>{{concert.date}} -- {{concert.venue}} Details!</h2>
<div><la... | Add Form Directives, change date type | Add Form Directives, change date type
Because databinding doesn't work the way we want with the JS Date Type.
| TypeScript | mit | BillWagner/TypeScriptAngular2,BillWagner/TypeScriptAngular2,BillWagner/TypeScriptAngular2,BillWagner/TypeScriptAngular2 | ---
+++
@@ -1,7 +1,7 @@
-import { bootstrap, Component, NgModel } from 'angular2/angular2';
+import { bootstrap, Component, FORM_DIRECTIVES } from 'angular2/angular2';
class ConcertSet {
- date: Date;
+ date: string;
venue: string;
set: number;
}
@@ -11,17 +11,17 @@
selector: 'deadbase-app'... |
eb088e38f392f2deb19871376e535cffbb51b6ce | webpack/account/dev_mode.tsx | webpack/account/dev_mode.tsx | import * as React from "react";
import { warning } from "farmbot-toastr";
import { setWebAppConfigValue } from "../config_storage/actions";
import { BooleanConfigKey } from "farmbot/dist/resources/configs/web_app";
interface S { count: number; }
interface P { dispatch: Function; }
const clicksLeft =
(x: number) => ... | import * as React from "react";
import { warning } from "farmbot-toastr";
import { setWebAppConfigValue } from "../config_storage/actions";
import { BooleanConfigKey } from "farmbot/dist/resources/configs/web_app";
interface S { count: number; }
interface P { dispatch: Function; }
const clicksLeft =
(x: number) => ... | Increase CSS height for easier accesibility | Increase CSS height for easier accesibility
| TypeScript | mit | FarmBot/Farmbot-Web-API,RickCarlino/farmbot-web-app,FarmBot/farmbot-web-app,gabrielburnworth/Farmbot-Web-App,RickCarlino/farmbot-web-app,FarmBot/farmbot-web-app,FarmBot/Farmbot-Web-API,gabrielburnworth/Farmbot-Web-App,RickCarlino/farmbot-web-app,gabrielburnworth/Farmbot-Web-App,FarmBot/farmbot-web-app,gabrielburnworth/... | ---
+++
@@ -29,10 +29,11 @@
const cb = triggers[count];
cb && cb(this.props.dispatch);
this.setState({ count: count + 1 });
+ console.log(count);
};
render() {
- return <div onClick={this.bump}>
+ return <div style={{ height: "100px" }} onClick={this.bump}>
<hr />
</div>;
... |
3a75b00db03cf2de4df3a6760cfd394183f43c3b | sample/23-type-graphql/src/recipes/dto/new-recipe.input.ts | sample/23-type-graphql/src/recipes/dto/new-recipe.input.ts | import { Length, MaxLength } from 'class-validator';
import { Field, InputType } from 'type-graphql';
@InputType()
export class NewRecipeInput {
@Field()
@MaxLength(30)
title: string;
@Field({ nullable: true })
@Length(30, 255)
description?: string;
@Field(type => [String])
ingredients: string[];
}
| import { IsOptional, Length, MaxLength } from 'class-validator';
import { Field, InputType } from 'type-graphql';
@InputType()
export class NewRecipeInput {
@Field()
@MaxLength(30)
title: string;
@Field({ nullable: true })
@IsOptional()
@Length(30, 255)
description?: string;
@Field(type => [String])
... | Add missing isOptional on optional field in Sample-23 | Add missing isOptional on optional field in Sample-23
| TypeScript | mit | kamilmysliwiec/nest,kamilmysliwiec/nest | ---
+++
@@ -1,4 +1,4 @@
-import { Length, MaxLength } from 'class-validator';
+import { IsOptional, Length, MaxLength } from 'class-validator';
import { Field, InputType } from 'type-graphql';
@InputType()
@@ -8,6 +8,7 @@
title: string;
@Field({ nullable: true })
+ @IsOptional()
@Length(30, 255)
de... |
a2e1a18d9987d608c4987c072e32b5e1299e80da | packages/components/components/dropdown/DropdownMenu.tsx | packages/components/components/dropdown/DropdownMenu.tsx | import React from 'react';
import { classnames } from '../../helpers/component';
interface Props {
children: React.ReactNode;
className?: string;
}
const DropdownMenu = ({ children, className = '' }: Props) => {
return (
<div className="dropDown-content">
<ul className={classnames(['un... | import React from 'react';
import { classnames } from '../../helpers/component';
interface Props {
children: React.ReactNode;
className?: string;
}
const DropdownMenu = ({ children, className = '' }: Props) => {
return (
<div className="dropDown-content">
<ul className={classnames(['un... | Fix - MAILWEB-428 - hover effect in dropdown | Fix - MAILWEB-428 - hover effect in dropdown
| TypeScript | mit | ProtonMail/WebClient,ProtonMail/WebClient,ProtonMail/WebClient | ---
+++
@@ -9,10 +9,10 @@
const DropdownMenu = ({ children, className = '' }: Props) => {
return (
<div className="dropDown-content">
- <ul className={classnames(['unstyled mt0 mb0 ml1 mr1', className])}>
+ <ul className={classnames(['unstyled mt0 mb0', className])}>
... |
ea23156ab50212746f94a79961eb0a3a8c5e4761 | src/lib/Scenes/Artwork/Components/OtherWorks/ContextGridCTA.tsx | src/lib/Scenes/Artwork/Components/OtherWorks/ContextGridCTA.tsx | import { navigate } from "lib/navigation/navigate"
import { Schema, track } from "lib/utils/track"
import { ArrowRightIcon, Flex, Sans } from "palette"
import React from "react"
import { TouchableWithoutFeedback } from "react-native"
interface ContextGridCTAProps {
href?: string
contextModule?: string
label: str... | import { navigate } from "lib/navigation/navigate"
import { Schema, track } from "lib/utils/track"
import { ArrowRightIcon, Flex, Sans } from "palette"
import React from "react"
import { TouchableWithoutFeedback } from "react-native"
interface ContextGridCTAProps {
href?: string
contextModule?: string
label: str... | Align context grid CTA text with icon | fix: Align context grid CTA text with icon
| TypeScript | mit | artsy/eigen,artsy/eigen,artsy/eigen,artsy/eigen,artsy/eigen,artsy/eigen,artsy/eigen | ---
+++
@@ -31,10 +31,14 @@
return (
<TouchableWithoutFeedback onPress={() => this.openLink()}>
<Flex flexDirection="row" alignContent="center">
- <Sans size="3" textAlign="left" weight="medium">
- {label}
- </Sans>
- <ArrowRightIcon fill="black... |
15088f91513522c242552f38caee4b53015fc993 | src/components/SearchTable/SearchCard/BlockActionsPopover.tsx | src/components/SearchTable/SearchCard/BlockActionsPopover.tsx | import * as React from 'react';
import { Button } from '@shopify/polaris';
export interface Handlers {
readonly onBlockRequester: () => void;
}
class BlockActionsPopover extends React.PureComponent<Handlers, never> {
public render() {
return (
<Button destructive size="slim" onClick={this.prop... | import * as React from 'react';
import { Button, Tooltip } from '@shopify/polaris';
export interface Handlers {
readonly onBlockRequester: () => void;
}
class BlockActionsPopover extends React.PureComponent<Handlers, never> {
public render() {
return (
<Tooltip content="You can manage your blo... | Add tooltip to block requester button. | Add tooltip to block requester button.
| TypeScript | mit | Anveio/mturk-engine,Anveio/mturk-engine,Anveio/mturk-engine | ---
+++
@@ -1,5 +1,5 @@
import * as React from 'react';
-import { Button } from '@shopify/polaris';
+import { Button, Tooltip } from '@shopify/polaris';
export interface Handlers {
readonly onBlockRequester: () => void;
@@ -8,9 +8,11 @@
class BlockActionsPopover extends React.PureComponent<Handlers, never> {
... |
f777cbd4c0a53c64334b51b50c60021073ad93a2 | 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.6.0',
RELEASEVERSION: '0.6.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.7.0',
RELEASEVERSION: '0.7.0'
};
export = BaseConfig;
| Update release version to 0.7.0 | Update release version to 0.7.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.6.0',
- RELEASEVERSION: '0.6.0'
+ RELEASEURL: 'https://github.com/nie-ine/raeber-website/releases/tag/0.7.0',
+ RELEASEVERSION: '0.7.0'
... |
ddd2cd1f25b079a9559a501cc35555c461116550 | src/reducers/audioFiles.ts | src/reducers/audioFiles.ts | import { AudioFiles } from '../types';
const initial: AudioFiles = {
audioNewSearch: new Audio(
'https://k003.kiwi6.com/hotlink/85iq6xu5ul/coins.ogg'
)
};
export default (state = initial, action: {}) => {
return state;
};
| import { AudioFiles } from '../types';
const initial: AudioFiles = {
audioNewSearch: new Audio(
'https://k003.kiwi6.com/hotlink/w9aqj8az8t/ping.wav'
)
};
export default (state = initial, action: {}) => {
return state;
};
| Use new audio for new search result sound notification. | Use new audio for new search result sound notification.
| TypeScript | mit | Anveio/mturk-engine,Anveio/mturk-engine,Anveio/mturk-engine | ---
+++
@@ -2,7 +2,7 @@
const initial: AudioFiles = {
audioNewSearch: new Audio(
- 'https://k003.kiwi6.com/hotlink/85iq6xu5ul/coins.ogg'
+ 'https://k003.kiwi6.com/hotlink/w9aqj8az8t/ping.wav'
)
};
|
e81afc060726f0d77a3fe2d841138e966d5d6146 | frontend/src/app/controls/base/stringControl/stringControl.component.ts | frontend/src/app/controls/base/stringControl/stringControl.component.ts | /*
* Angular 2 decorators and services
*/
import { Component, Input } from '@angular/core';
import { FormGroup, FormControl } from '@angular/forms';
@Component({
// The selector is what angular internally uses
selector: 'cb-string-control',
styles: [``],
template: `
<div [formGroup]="inputGroup">... | /*
* Angular 2 decorators and services
*/
import { Component, Input } from '@angular/core';
import { FormGroup, FormControl } from '@angular/forms';
@Component({
// The selector is what angular internally uses
selector: 'cb-string-control',
styles: [``],
template: `
<div [formGroup]="inputGroup">... | Fix variation string input control binding | fix(variations): Fix variation string input control binding
| TypeScript | mit | joaogarin/carte-blanche-angular2,joaogarin/carte-blanche-angular2 | ---
+++
@@ -11,7 +11,7 @@
template: `
<div [formGroup]="inputGroup">
<label>{{label}}</label>
- <input type="text" [value]="value" formControlName="item" />
+ <input type="text" [(ngModel)]="value" formControlName="item" />
</div>
`,
}) |
0802fbec3bff61683cf84e6ae5bce7492e94b7a4 | packages/internal-test-helpers/lib/ember-dev/setup-qunit.ts | packages/internal-test-helpers/lib/ember-dev/setup-qunit.ts | import { getDebugFunction, setDebugFunction } from '@ember/debug';
// @ts-ignore
import EmberDevTestHelperAssert from './index';
export interface Assertion {
reset(): void;
inject(): void;
assert(): void;
restore(): void;
}
export default function setupQUnit({ runningProdBuild }: { runningProdBuild: boolean ... | import { getDebugFunction, setDebugFunction } from '@ember/debug';
// @ts-ignore
import EmberDevTestHelperAssert from './index';
export interface Assertion {
reset(): void;
inject(): void;
assert(): void;
restore(): void;
}
export default function setupQUnit({ runningProdBuild }: { runningProdBuild: boolean ... | Add nested module API support to `setupQUnit()` function | internal-test-helpers: Add nested module API support to `setupQUnit()` function
| TypeScript | mit | miguelcobain/ember.js,givanse/ember.js,mfeckie/ember.js,kellyselden/ember.js,GavinJoyce/ember.js,emberjs/ember.js,intercom/ember.js,givanse/ember.js,stefanpenner/ember.js,intercom/ember.js,intercom/ember.js,sly7-7/ember.js,bekzod/ember.js,stefanpenner/ember.js,mixonic/ember.js,qaiken/ember.js,GavinJoyce/ember.js,fpause... | ---
+++
@@ -20,6 +20,24 @@
let originalModule = QUnit.module;
QUnit.module = function(name: string, _options: any) {
+ if (typeof _options === 'function') {
+ let callback = _options;
+
+ return originalModule(name, function(hooks) {
+ hooks.beforeEach(function() {
+ assertion.res... |
216e05f2d40a99f054bbfab2a86d0cbf5ceec1ec | main/src/extension/api/ApplicationImpl.ts | main/src/extension/api/ApplicationImpl.ts | /*
* Copyright 2022 Simon Edwards <simon@simonzone.com>
*
* This source code is licensed under the MIT license which is detailed in the LICENSE.txt file.
*/
import * as open from "open";
import * as fs from "node:fs";
import * as path from "node:path";
import * as ExtensionApi from "@extraterm/extraterm-extension-a... | /*
* Copyright 2022 Simon Edwards <simon@simonzone.com>
*
* This source code is licensed under the MIT license which is detailed in the LICENSE.txt file.
*/
import open from "open";
import * as fs from "node:fs";
import * as path from "node:path";
import * as ExtensionApi from "@extraterm/extraterm-extension-api";
... | Fix `open()` in our extension API | Fix `open()` in our extension API
| TypeScript | mit | sedwards2009/extraterm,sedwards2009/extraterm,sedwards2009/extraterm,sedwards2009/extraterm,sedwards2009/extraterm | ---
+++
@@ -3,7 +3,7 @@
*
* This source code is licensed under the MIT license which is detailed in the LICENSE.txt file.
*/
-import * as open from "open";
+import open from "open";
import * as fs from "node:fs";
import * as path from "node:path";
import * as ExtensionApi from "@extraterm/extraterm-extension... |
90ce2cbe4726916eadc14fee40ce778452f4178a | src/app/global/keybindings/keybindings-actions.service.ts | src/app/global/keybindings/keybindings-actions.service.ts | import { Injectable } from '@angular/core';
import { BehaviorSubject, Observable } from 'rxjs';
import { SelectorService } from '../../controller/selector/selector.service';
import { Action } from './keybindings.service';
@Injectable()
export class KeybindingsActionsService {
constructor(private selectorService:... | import { Injectable } from '@angular/core';
import { BehaviorSubject, Observable } from 'rxjs';
import { SelectorService } from '../../controller/selector/selector.service';
import { Action } from './keybindings.service';
@Injectable()
export class KeybindingsActionsService {
constructor(private selectorService:... | Add stubs for all unimplemented keybinding actions | feat: Add stubs for all unimplemented keybinding actions
| TypeScript | mit | nb48/chart-hero,nb48/chart-hero,nb48/chart-hero | ---
+++
@@ -16,7 +16,64 @@
return () => this.selectorService.selectNext();
case Action.SelectPrevious:
return () => this.selectorService.selectPrevious();
+ case Action.AudioPlayOrPause:
+ return () => undefined;
+ case Action.AudioStop:
+ return ... |
9818dec74f94693ae4b88820bf2f72424ffb7a14 | app/scripts/modules/core/src/pagerDuty/js-worker-search.d.ts | app/scripts/modules/core/src/pagerDuty/js-worker-search.d.ts | declare module 'js-worker-search' {
type IndexMode = 'ALL_SUBSTRINGS' | 'EXACT_WORDS' | 'PREFIXES';
class SearchApi {
constructor(indexMode?: IndexMode, tokenizePattern?: RegExp, caseSensitive?: boolean);
public indexDocument(uid: any, text: string): SearchApi;
public search(query: string): Promise<Arr... | declare module 'js-worker-search' {
type IndexMode = 'ALL_SUBSTRINGS' | 'EXACT_WORDS' | 'PREFIXES';
class SearchApi {
constructor(indexMode?: IndexMode, tokenizePattern?: RegExp, caseSensitive?: boolean);
public indexDocument(uid: any, text: string): SearchApi;
public search(query: string): Promise<any... | Fix eslint warnings for @typescript-eslint/array-type | fix(eslint): Fix eslint warnings for @typescript-eslint/array-type
| TypeScript | apache-2.0 | duftler/deck,ajordens/deck,duftler/deck,icfantv/deck,spinnaker/deck,sgarlick987/deck,icfantv/deck,ajordens/deck,ajordens/deck,ajordens/deck,duftler/deck,spinnaker/deck,icfantv/deck,spinnaker/deck,sgarlick987/deck,sgarlick987/deck,duftler/deck,sgarlick987/deck,spinnaker/deck,icfantv/deck | ---
+++
@@ -4,7 +4,7 @@
class SearchApi {
constructor(indexMode?: IndexMode, tokenizePattern?: RegExp, caseSensitive?: boolean);
public indexDocument(uid: any, text: string): SearchApi;
- public search(query: string): Promise<Array<any>>;
+ public search(query: string): Promise<any[]>;
}
ex... |
5119bb7c571e885790d1e71d7b57fe584f344563 | src/v2/Apps/Partner/Components/__tests__/NavigationTabs.jest.tsx | src/v2/Apps/Partner/Components/__tests__/NavigationTabs.jest.tsx | import { NavigationTabs_Test_PartnerQueryRawResponse } from "v2/__generated__/NavigationTabs_Test_PartnerQuery.graphql"
import { NavigationTabsFragmentContainer as NavigationTabs } from "v2/Apps/Partner/Components/NavigationTabs"
import { renderRelayTree } from "v2/DevTools"
import React from "react"
import { graphql }... | import React from "react"
import { graphql } from "react-relay"
import { setupTestWrapper } from "v2/DevTools/setupTestWrapper"
import { NavigationTabs_Test_PartnerQuery } from "v2/__generated__/NavigationTabs_Test_PartnerQuery.graphql"
import { NavigationTabsFragmentContainer as NavigationTabs } from "v2/Apps/Partner/... | Update navigation tabs tests to use setupTestWrapper | Update navigation tabs tests to use setupTestWrapper
| TypeScript | mit | joeyAghion/force,artsy/force,joeyAghion/force,artsy/force-public,artsy/force-public,joeyAghion/force,artsy/force,artsy/force,artsy/force,joeyAghion/force | ---
+++
@@ -1,35 +1,30 @@
-import { NavigationTabs_Test_PartnerQueryRawResponse } from "v2/__generated__/NavigationTabs_Test_PartnerQuery.graphql"
-import { NavigationTabsFragmentContainer as NavigationTabs } from "v2/Apps/Partner/Components/NavigationTabs"
-import { renderRelayTree } from "v2/DevTools"
import React... |
56daa5974b80d786c56b596dc6bcaadc7e34f119 | NavigationReactNative/src/NavigationBackAndroid.android.ts | NavigationReactNative/src/NavigationBackAndroid.android.ts | import { StateNavigator } from 'navigation';
import * as React from 'react';
import { BackAndroid } from 'react-native';
class NavigationBackAndroid extends React.Component<any, any> {
private onBack = () => {
var stateNavigator = this.getStateNavigator();
if (stateNavigator.canNavigateBack(1)) {
... | import { StateNavigator } from 'navigation';
import * as React from 'react';
import { BackAndroid } from 'react-native';
class NavigationBackAndroid extends React.Component<any, any> {
private onBack = () => {
var stateNavigator = this.getStateNavigator();
if (this.state.state === stateNavigator.st... | Return false if context state doesn't match state | Return false if context state doesn't match state
Each scene will have its own NavigationBackAndroid component but only
the one corresponding to the current state should handle the back press
| TypeScript | apache-2.0 | grahammendick/navigation,grahammendick/navigation,grahammendick/navigation,grahammendick/navigation,grahammendick/navigation,grahammendick/navigation,grahammendick/navigation | ---
+++
@@ -5,11 +5,20 @@
class NavigationBackAndroid extends React.Component<any, any> {
private onBack = () => {
var stateNavigator = this.getStateNavigator();
- if (stateNavigator.canNavigateBack(1)) {
- stateNavigator.navigateBack(1);
+ if (this.state.state === stateNavigat... |
1d303e0be4ddc9a4b476227a2f01d923aafeda13 | client/test/buildEncounter.ts | client/test/buildEncounter.ts | import { Encounter } from "../Encounter/Encounter";
import { SpellLibrary } from "../Library/SpellLibrary";
import { PlayerViewClient } from "../Player/PlayerViewClient";
import { DefaultRules, IRules } from "../Rules/Rules";
import { TextEnricher } from "../TextEnricher/TextEnricher";
export function buildStatBlockTe... | import { Encounter } from "../Encounter/Encounter";
import { DefaultRules, IRules } from "../Rules/Rules";
export function buildEncounter() {
const rules = new DefaultRules();
const encounter = new Encounter(null, jest.fn().mockReturnValue(null), jest.fn(), rules);
return encounter;
} | Remove enricher from test encounter | Remove enricher from test encounter
| TypeScript | mit | cynicaloptimist/improved-initiative,cynicaloptimist/improved-initiative,cynicaloptimist/improved-initiative | ---
+++
@@ -1,16 +1,8 @@
import { Encounter } from "../Encounter/Encounter";
-import { SpellLibrary } from "../Library/SpellLibrary";
-import { PlayerViewClient } from "../Player/PlayerViewClient";
import { DefaultRules, IRules } from "../Rules/Rules";
-import { TextEnricher } from "../TextEnricher/TextEnricher";
-... |
2385558bea54b4abebbc5917921f1d0b477b2254 | packages/apollo-cache-control/src/__tests__/cacheControlSupport.ts | packages/apollo-cache-control/src/__tests__/cacheControlSupport.ts | import { buildSchema } from 'graphql';
import { makeExecutableSchema } from 'graphql-tools';
type FirstArg<F> = F extends (arg: infer A) => any ? A : never;
export function augmentTypeDefsWithCacheControlSupport(typeDefs) {
return (
`
enum CacheControlScope {
PUBLIC
PRIVATE
}
directive @cacheCont... | import { buildSchema } from 'graphql';
import { makeExecutableSchema } from 'graphql-tools';
type FirstArg<F> = F extends (arg: infer A) => any ? A : never;
export function augmentTypeDefsWithCacheControlSupport(typeDefs: string) {
return (
`
enum CacheControlScope {
PUBLIC
PRIVATE
}
directive @c... | Fix types in `apollo-cache-control` test helper | Fix types in `apollo-cache-control` test helper
| TypeScript | mit | apollostack/apollo-server | ---
+++
@@ -3,7 +3,7 @@
type FirstArg<F> = F extends (arg: infer A) => any ? A : never;
-export function augmentTypeDefsWithCacheControlSupport(typeDefs) {
+export function augmentTypeDefsWithCacheControlSupport(typeDefs: string) {
return (
`
enum CacheControlScope {
@@ -24,7 +24,7 @@
}
export fun... |
8eff3d4139ee947e8063c787f591e65bd1b77749 | packages/skatejs/src/name.ts | packages/skatejs/src/name.ts | function dashCase(str: string): string {
return typeof str === 'string'
? str.split(/([_A-Z])/).reduce((one, two, idx) => {
const dash = !one || idx % 2 === 0 ? '' : '-';
two = two === '_' ? '' : two;
return `${one}${dash}${two.toLowerCase()}`;
})
: str;
}
function format(prefix... | function dashcase(str: string): string {
return str.split(/([_A-Z])/).reduce((one, two, idx) => {
const dash = !one || idx % 2 === 0 ? '' : '-';
two = two === '_' ? '' : two;
return `${one}${dash}${two.toLowerCase()}`;
});
}
function format(prefix: string, suffix: number): string {
return (
(pref... | Remove redundant code from dash-casing function. Ensure 'element' is the prefix even if empty string is passed (or falsy if not using types). | Remove redundant code from dash-casing function. Ensure 'element' is the prefix even if empty string is passed (or falsy if not using types).
| TypeScript | mit | skatejs/skatejs,skatejs/skatejs,skatejs/skatejs | ---
+++
@@ -1,11 +1,9 @@
-function dashCase(str: string): string {
- return typeof str === 'string'
- ? str.split(/([_A-Z])/).reduce((one, two, idx) => {
- const dash = !one || idx % 2 === 0 ? '' : '-';
- two = two === '_' ? '' : two;
- return `${one}${dash}${two.toLowerCase()}`;
- })
- ... |
ad42e0e70fab75560b2ac67d278f6e0f1ef2681b | src/on_exit.ts | src/on_exit.ts | const signals: NodeJS.Signals[] = ['SIGINT', 'SIGHUP', 'SIGTERM', 'SIGQUIT'];
export function onExit(callback: () => Promise<void> | void) {
let callbackInvoked = false;
const callbackOnce = async () => {
if (!callbackInvoked) {
callbackInvoked = true;
await callback();
}
};
process.on('be... | const signals: NodeJS.Signals[] = ['SIGINT', 'SIGHUP', 'SIGTERM', 'SIGQUIT'];
export function onExit(callback: () => Promise<void> | void) {
let callbackInvoked = false;
const callbackOnce = async () => {
if (!callbackInvoked) {
callbackInvoked = true;
await callback();
}
};
process.on('be... | Exit with code 0 when terminated gracefully | Exit with code 0 when terminated gracefully
| TypeScript | mit | dotdoom/comicsbot,dotdoom/comicsbot | ---
+++
@@ -12,8 +12,7 @@
process.on('beforeExit', callbackOnce);
for (const signal of signals) {
process.on(signal, async signal => {
- // https://nodejs.org/api/process.html#process_signal_events
- process.exitCode = 128 /* TODO(dotdoom): + signal number */;
+ process.exitCode = 0;
... |
a8dd5da9969b88d4c28a441293ae1c805a0e974f | src/util/encode-blob.ts | src/util/encode-blob.ts | export default (blob: Blob) =>
new Promise<string>((resolve, reject) => {
const reader = new FileReader()
reader.readAsDataURL(blob)
reader.onloadend = function() {
let result = reader.result as string
if (!result) {
return // result.onerror has alrea... | export default (blob: Blob) =>
new Promise<string>((resolve, reject) => {
const reader = new FileReader()
reader.readAsDataURL(blob)
reader.onloadend = function() {
let result = reader.result as string
if (!result) {
return // result.onerror has alrea... | Add debugging line for blob encoding bug | Add debugging line for blob encoding bug
| TypeScript | mit | WorldBrain/WebMemex,WorldBrain/WebMemex | ---
+++
@@ -17,6 +17,7 @@
}
reader.onerror = function() {
+ console.log('Got error encoding this blob', blob)
reject(reader.error)
}
}) |
8b5fd086928403c22268958e7218c3d685944e01 | src/client/app/dashboard/realtime-statistic/realtime-statistic.module.ts | src/client/app/dashboard/realtime-statistic/realtime-statistic.module.ts | import { CommonModule } from '@angular/common';
import { BrowserModule } from '@angular/platform-browser';
import { HttpModule } from '@angular/http';
import { NgModule } from '@angular/core';
import { RouterModule } from '@angular/router';
import { ChartModule } from 'angular2-highcharts';
import { RealtimeStatisticC... | import { CommonModule } from '@angular/common';
import { FormsModule } from '@angular/forms';
import { BrowserModule } from '@angular/platform-browser';
import { HttpModule } from '@angular/http';
import { NgModule } from '@angular/core';
import { RouterModule } from '@angular/router';
import { ChartModule } from 'an... | Add minimap, typeahead (autocomplete for search bar) component | Add minimap, typeahead (autocomplete for search bar) component
| TypeScript | mit | CaoDuyThanh/WebAppClient,CaoDuyThanh/WebAppClient,CaoDuyThanh/WebAppClient | ---
+++
@@ -1,4 +1,5 @@
import { CommonModule } from '@angular/common';
+import { FormsModule } from '@angular/forms';
import { BrowserModule } from '@angular/platform-browser';
import { HttpModule } from '@angular/http';
import { NgModule } from '@angular/core';
@@ -9,9 +10,12 @@
// Import sub Components
i... |
06176008000a386fa6afb5c0f489576e6cdb5f0b | src/app/modules/wallet/components/guards/default-redirect-guard.component.ts | src/app/modules/wallet/components/guards/default-redirect-guard.component.ts | /**
* Redirects to route set in WalletTabHistoryService
* if one exists.
* @author Ben Hayward
*/
import { Injectable } from '@angular/core';
import { CanActivate, Router } from '@angular/router';
import { WalletTabHistoryService } from '../tab-history.service';
@Injectable()
export class DefaultRedirectGuard impl... | /**
* Redirects to route set in WalletTabHistoryService
* if one exists.
* @author Ben Hayward
*/
import { Injectable } from '@angular/core';
import { CanActivate, Router } from '@angular/router';
import { WalletTabHistoryService } from '../tab-history.service';
@Injectable()
export class DefaultRedirectGuard impl... | Change default wallet page to tokens | Change default wallet page to tokens
| TypeScript | agpl-3.0 | Minds/front,Minds/front,Minds/front,Minds/front | ---
+++
@@ -28,7 +28,7 @@
}
// default redirect
- this.router.navigateByUrl('/wallet/cash/earnings');
+ this.router.navigateByUrl('/wallet/tokens/rewards');
return true;
}
} |
968bc904766891b6d7d5dc322d1a123888331a68 | src/lib/relay/config.tsx | src/lib/relay/config.tsx | import { NativeModules } from "react-native"
const { Emission } = NativeModules
let metaphysicsURL
let gravityURL
if (Emission && Emission.gravityAPIHost && Emission.metaphysicsAPIHost) {
metaphysicsURL = Emission.metaphysicsAPIHost
gravityURL = Emission.gravityAPIHost
} else {
metaphysicsURL = "https://metaphy... | import { NativeModules } from "react-native"
const { Emission } = NativeModules
let metaphysicsURL
let gravityURL
if (Emission && Emission.gravityAPIHost && Emission.metaphysicsAPIHost) {
metaphysicsURL = Emission.metaphysicsAPIHost
gravityURL = Emission.gravityAPIHost
} else {
metaphysicsURL = "https://metaphy... | Disable recording network activity in dev tools for now. | Disable recording network activity in dev tools for now.
| TypeScript | mit | artsy/eigen,artsy/eigen,artsy/emission,artsy/emission,artsy/eigen,artsy/eigen,artsy/emission,artsy/eigen,artsy/emission,artsy/emission,artsy/emission,artsy/emission,artsy/eigen,artsy/eigen | ---
+++
@@ -21,7 +21,13 @@
//
declare var global: any
if (__DEV__ && global.originalXMLHttpRequest !== undefined) {
- global.XMLHttpRequest = global.originalXMLHttpRequest
+ /**
+ * TODO: Recording network access in Chrome Dev Tools is disabled for now.
+ *
+ * @see https://github.com/jhen0409/react-native... |
45fc9b3ea1500f89544731aa698ce9cbfaf233ae | src/app/core/sync/sync-process.ts | src/app/core/sync/sync-process.ts | import {Observable} from 'rxjs';
export interface SyncProcess {
url: string;
cancel(): void;
observer: Observable<SyncStatus>;
}
export enum SyncStatus {
Offline = "OFFLINE",
Pushing = "PUSHING",
Pulling = "PULLING",
InSync = "IN_SYNC",
Error = "ERROR",
AuthenticationError = "A... | import {Observable} from 'rxjs';
export interface SyncProcess {
url: string;
cancel(): void;
observer: Observable<SyncStatus>;
}
export enum SyncStatus {
Offline = 'OFFLINE',
Pushing = 'PUSHING',
Pulling = 'PULLING',
InSync = 'IN_SYNC',
Error = 'ERROR',
AuthenticationError = 'A... | Adjust to code style rules | Adjust to code style rules
| TypeScript | apache-2.0 | codarchlab/idai-field-client,codarchlab/idai-field-client,codarchlab/idai-field-client,codarchlab/idai-field-client | ---
+++
@@ -11,11 +11,11 @@
export enum SyncStatus {
- Offline = "OFFLINE",
- Pushing = "PUSHING",
- Pulling = "PULLING",
- InSync = "IN_SYNC",
- Error = "ERROR",
- AuthenticationError = "AUTHENTICATION_ERROR",
- AuthorizationError = "AUTHORIZATION_ERROR"
+ Offline = 'OFFLINE',
+ Pushi... |
8f8bab1cc286c946d2c3acacb46798aedb477b66 | src/components/Tabs/Tab/styled.ts | src/components/Tabs/Tab/styled.ts | import { override, styled } from "../../styles";
export interface ContainerProps {
isSelected: boolean;
theme: any;
}
export const Container = styled("div")<ContainerProps>(
{
boxSizing: "border-box",
cursor: "pointer",
display: ["inline-block", "-moz-inline-stack"],
fontSize: 16,
margin: 0,... | import { override, styled, Theme } from "../../styles";
export interface ContainerProps {
isSelected: boolean;
theme: Theme;
}
export const Container = styled("div")<ContainerProps>(
{
boxSizing: "border-box",
cursor: "pointer",
display: ["inline-block", "-moz-inline-stack"],
fontSize: 16,
m... | Use correct type as per Thanh’s feedback | Use correct type as per Thanh’s feedback
| TypeScript | mit | sajari/sajari-sdk-react,sajari/sajari-sdk-react | ---
+++
@@ -1,8 +1,8 @@
-import { override, styled } from "../../styles";
+import { override, styled, Theme } from "../../styles";
export interface ContainerProps {
isSelected: boolean;
- theme: any;
+ theme: Theme;
}
export const Container = styled("div")<ContainerProps>( |
39821ac26433fe507ecafdf3b4b0b9e66e95c6cf | packages/apollo-server-core/src/utils/isDirectiveDefined.ts | packages/apollo-server-core/src/utils/isDirectiveDefined.ts | import { DocumentNode, Kind } from 'graphql/language';
import { gql } from '../';
export const isDirectiveDefined = (
typeDefs: DocumentNode[] | string,
directiveName: string,
): boolean => {
if (typeof typeDefs === 'string') {
return isDirectiveDefined([gql(typeDefs)], directiveName);
}
return typeDefs.... | import { DocumentNode, Kind } from 'graphql/language';
import { gql } from '../';
export const isDirectiveDefined = (
typeDefs: DocumentNode[] | string,
directiveName: string,
): boolean => {
if (typeof typeDefs === 'string') {
return isDirectiveDefined([gql(typeDefs)], directiveName);
}
return typeDefs.... | Use `Object.prototype.hasOwnProperty.call` to be extra defensive. | Use `Object.prototype.hasOwnProperty.call` to be extra defensive.
| TypeScript | mit | apollostack/apollo-server | ---
+++
@@ -9,7 +9,7 @@
return isDirectiveDefined([gql(typeDefs)], directiveName);
}
return typeDefs.some(typeDef =>
- typeDef.hasOwnProperty('definitions')
+ Object.prototype.hasOwnProperty.call(typeDef, 'definitions')
? typeDef.definitions.some(
definition =>
definiti... |
ae6853c196932a6c472f6d98935d8697bb772fa8 | index.ts | index.ts | interface PolicyResult {
[key: string]: string[];
}
export = function (policy: string): PolicyResult {
return policy.split(';').reduce<PolicyResult>((result, directive) => {
const trimmed = directive.trim();
if (!trimmed) {
return result;
}
const split = trimmed.split(/\s+/g);
const key ... | interface PolicyResult {
[key: string]: string[];
}
export = (policy: string): PolicyResult =>
policy.split(';').reduce<PolicyResult>((result, directive) => {
const [directiveKey, ...directiveValue] = directive.trim().split(/\s+/g);
if (!directiveKey || Object.prototype.hasOwnProperty.call(result, directi... | Rewrite internals to reduce LOC and remove a type cast | Rewrite internals to reduce LOC and remove a type cast
| TypeScript | mit | helmetjs/content-security-policy-parser | ---
+++
@@ -2,20 +2,17 @@
[key: string]: string[];
}
-export = function (policy: string): PolicyResult {
- return policy.split(';').reduce<PolicyResult>((result, directive) => {
- const trimmed = directive.trim();
- if (!trimmed) {
+export = (policy: string): PolicyResult =>
+ policy.split(';').reduce<P... |
8d789703755de018437fc9e122f8727367959a55 | src/app/map/rainfall-map-panel/rainfall-map-panel.component.spec.ts | src/app/map/rainfall-map-panel/rainfall-map-panel.component.spec.ts | /* tslint:disable:no-unused-variable */
/*!
* Rainfall Map Panel Component Test
*
* Copyright(c) Exequiel Ceasar Navarrete <esnavarrete1@up.edu.ph>
* Licensed under MIT
*/
import { Renderer } from '@angular/core';
import { TestBed, async, inject } from '@angular/core/testing';
import { LeafletMapService } from '... | /* tslint:disable:no-unused-variable */
/*!
* Rainfall Map Panel Component Test
*
* Copyright(c) Exequiel Ceasar Navarrete <esnavarrete1@up.edu.ph>
* Licensed under MIT
*/
import { Renderer } from '@angular/core';
import { TestBed, async, inject } from '@angular/core/testing';
import { Router } from '@angular/ro... | Fix broken unit test due to newly injected dependency | Fix broken unit test due to newly injected dependency
| TypeScript | mit | ecsnavarretemit/sarai-ng2,ecsnavarretemit/sarai-interactive-maps,ecsnavarretemit/sarai-ng2,ecsnavarretemit/sarai-ng2,ecsnavarretemit/sarai-interactive-maps,ecsnavarretemit/sarai-interactive-maps | ---
+++
@@ -9,17 +9,22 @@
import { Renderer } from '@angular/core';
import { TestBed, async, inject } from '@angular/core/testing';
+import { Router } from '@angular/router';
import { LeafletMapService } from '../../leaflet';
+import { MockRouter } from '../../mocks/router';
import { RainfallMapPanelComponent }... |
68881f35fc5020b944eae6ad0cf4b9f1e4f4099a | src/dispatcher/index.tsx | src/dispatcher/index.tsx | /**
* Copyright 2018-present Facebook.
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
* @format
*/
import androidDevice from './androidDevice';
import iOSDevice from './iOSDevice';
import desktopDevice from './desktopDevice';
import appl... | /**
* Copyright 2018-present Facebook.
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
* @format
*/
import androidDevice from './androidDevice';
import iOSDevice from './iOSDevice';
import desktopDevice from './desktopDevice';
import appl... | Use androidEnabled setting in dispatcher | Use androidEnabled setting in dispatcher
Summary:
Takes the androidEnabled setting and uses it to gate the android dispatcher.
Enables people without android sdk to use flipper (e.g. iOS engineers).
Reviewed By: priteshrnandgaonkar
Differential Revision: D17829810
fbshipit-source-id: 7d25580e65dee93ebfda7c5cc4c4cea... | TypeScript | mit | facebook/flipper,facebook/flipper,facebook/flipper,facebook/flipper,facebook/flipper,facebook/flipper,facebook/flipper,facebook/flipper,facebook/flipper,facebook/flipper,facebook/flipper | ---
+++
@@ -18,11 +18,12 @@
import {Logger} from '../fb-interfaces/Logger';
import {Store} from '../reducers/index';
import {Dispatcher} from './types';
+import {notNull} from '../utils/typeUtils';
export default function(store: Store, logger: Logger): () => Promise<void> {
const dispatchers: Array<Dispatche... |
a450b9ec76f7b2770482f772a86a16e9fe880807 | src/v2/Apps/Partner/Components/PartnerHeader/PartnerHeaderAddress.tsx | src/v2/Apps/Partner/Components/PartnerHeader/PartnerHeaderAddress.tsx | import React from "react"
import styled from "styled-components"
import { uniq } from "lodash"
import { PartnerHeader_partner } from "v2/__generated__/PartnerHeader_partner.graphql"
export const TextWithNoWrap = styled.span`
white-space: nowrap;
`
export const PartnerHeaderAddress: React.FC<
PartnerHeader_partner[... | import React from "react"
import styled from "styled-components"
import { uniq } from "lodash"
import { media } from "@artsy/palette"
import { PartnerHeader_partner } from "v2/__generated__/PartnerHeader_partner.graphql"
export const TextWithNoWrap = styled.span`
white-space: nowrap;
${media.sm`
white-space: ... | Allow text wrapping for mobile | Allow text wrapping for mobile
| TypeScript | mit | artsy/force,joeyAghion/force,artsy/force-public,artsy/force-public,artsy/force,artsy/force,artsy/force,joeyAghion/force,joeyAghion/force,joeyAghion/force | ---
+++
@@ -1,10 +1,15 @@
import React from "react"
import styled from "styled-components"
import { uniq } from "lodash"
+import { media } from "@artsy/palette"
import { PartnerHeader_partner } from "v2/__generated__/PartnerHeader_partner.graphql"
export const TextWithNoWrap = styled.span`
white-space: nowr... |
593c2fe1ebe619d740dbf7b0111a091bc22fdf8c | src/main/webapp/assets/grunt/ts/filter/SeasonColorFilter.ts | src/main/webapp/assets/grunt/ts/filter/SeasonColorFilter.ts | module Filter {
"use strict";
export function SeasonColorFilter() {
return (input:any):any => {
if (input === "winter") {
return "#5141D9";
} else if (input === "spring") {
return "#B2F63D";
} else if (input === "summer") {
... | module Filter {
"use strict";
export function SeasonColorFilter() {
return (input:number):string => {
if (input === 1) {
return "#5141D9";
} else if (input === 2) {
return "#B2F63D";
} else if (input === 3) {
return "#F... | Fix season type. string to number. | Fix season type. string to number.
| TypeScript | mit | tsukaby/anime-lineup,tsukaby/anime-lineup,tsukaby/anime-lineup,tsukaby/anime-lineup | ---
+++
@@ -2,14 +2,14 @@
"use strict";
export function SeasonColorFilter() {
- return (input:any):any => {
- if (input === "winter") {
+ return (input:number):string => {
+ if (input === 1) {
return "#5141D9";
- } else if (input === "spring"... |
53752835231af5b4d837411fafc02ab157970020 | app/login/login.component.ts | app/login/login.component.ts | import { Component, OnInit, ViewChild } from "@angular/core";
import { UserService } from "../services";
import { User } from "../models";
import { Observable } from "rxjs/Observable";
import { EventData } from "data/observable";
import { Router } from "@angular/router";
@Component({
selector: "Login",
moduleI... | import { Component, OnInit, ViewChild } from "@angular/core";
import { UserService } from "../services";
import { User } from "../models";
import { Observable } from "rxjs/Observable";
import { EventData } from "data/observable";
import { Router } from "@angular/router";
import { Page } from "ui/page";
@Component({
... | Remove actionbar on login page | Remove actionbar on login page
| TypeScript | mit | etabakov/fivekmrun-app,etabakov/fivekmrun-app,etabakov/fivekmrun-app | ---
+++
@@ -4,6 +4,7 @@
import { Observable } from "rxjs/Observable";
import { EventData } from "data/observable";
import { Router } from "@angular/router";
+import { Page } from "ui/page";
@Component({
selector: "Login",
@@ -13,7 +14,8 @@
export class LoginComponent implements OnInit {
public userId... |
bcc6f3117f19dd5ee2198dc2f2caddb7883261a9 | src/webauthn.ts | src/webauthn.ts | import {base64urlToBuffer, bufferToBase64url} from "./base64url";
import {CredentialCreationOptionsJSON, CredentialRequestOptionsJSON, PublicKeyCredentialWithAssertionJSON, PublicKeyCredentialWithAttestationJSON} from "./json";
import {convert} from "./schema-format";
import {credentialCreationOptions, credentialReques... | import {base64urlToBuffer, bufferToBase64url} from "./base64url";
import {CredentialCreationOptionsJSON, CredentialRequestOptionsJSON, PublicKeyCredentialWithAssertionJSON, PublicKeyCredentialWithAttestationJSON} from "./json";
import {convert} from "./schema-format";
import {credentialCreationOptions, credentialReques... | Fix documentation: s/public credential/public key credential/ | Fix documentation: s/public credential/public key credential/
| TypeScript | mit | github/webauthn-json,github/webauthn-json,github/webauthn-json | ---
+++
@@ -22,7 +22,7 @@
}
// This function does a simple check to test for the credential management API
-// functions we need, and an indication of public credential authentication
+// functions we need, and an indication of public key credential authentication
// support.
// https://developers.google.com/we... |
8ab504cb23a256636c5a542d6eae1553ed27b56f | source/CroquetAustralia.Website/app/tournaments/scripts/Tournament.ts | source/CroquetAustralia.Website/app/tournaments/scripts/Tournament.ts | module App {
export class Tournament {
constructor(
public id: string,
public title: string,
public startsOn: Date,
public endsOn: Date,
public location: string,
public events: TournamentItem[],
public functions: TournamentI... | module App {
export class Tournament {
constructor(
public id: string,
public title: string,
public startsOn: Date,
public endsOn: Date,
public location: string,
public events: TournamentItem[],
public functions: TournamentI... | Fix 'Stop accepting entries at 4 March 2016 15:00 AEST' | Fix 'Stop accepting entries at 4 March 2016 15:00 AEST'
| TypeScript | mit | croquet-australia/website-application,croquet-australia/croquet-australia-website,croquet-australia/croquet-australia-website,croquet-australia/website-application,croquet-australia/croquet-australia-website,croquet-australia/croquet-australia.com.au,croquet-australia/croquet-australia.com.au,croquet-australia/croquet-... | ---
+++
@@ -32,7 +32,7 @@
}
isOpen(): boolean {
- return true;
+ return false;
}
totalPayable(): number { |
32115111602ceacfc55691016636215d9c1b9ca0 | packages/core/src/index.ts | packages/core/src/index.ts | /**
* FoalTS
* Copyright(c) 2017-2020 Loïc Poullain <loic.poullain@centraliens.net>
* Released under the MIT License.
*/
export * from './common';
export * from './core';
export * from './express';
export * from './openapi';
export * from './sessions';
| /**
* FoalTS
* Copyright(c) 2017-2020 Loïc Poullain <loic.poullain@centraliens.net>
* Released under the MIT License.
*/
try {
const version = process.versions.node;
const NODE_MAJOR_VERSION = parseInt(version.split('.')[0], 10);
if (NODE_MAJOR_VERSION < 10) {
console.warn(`[Warning] You are using versio... | Add warning on Node supported versions | Add warning on Node supported versions
| TypeScript | mit | FoalTS/foal,FoalTS/foal,FoalTS/foal,FoalTS/foal | ---
+++
@@ -4,6 +4,14 @@
* Released under the MIT License.
*/
+try {
+ const version = process.versions.node;
+ const NODE_MAJOR_VERSION = parseInt(version.split('.')[0], 10);
+ if (NODE_MAJOR_VERSION < 10) {
+ console.warn(`[Warning] You are using version ${version} of Node. FoalTS requires at least vers... |
8aeff70e48dc4d9221b57e9810b0e5e4a4920af8 | tests/cases/conformance/es6/Symbols/symbolDeclarationEmit11.ts | tests/cases/conformance/es6/Symbols/symbolDeclarationEmit11.ts | //@target: ES6
//@declaration: true
class C {
static [Symbol.iterator] = 0;
static [Symbol.toPrimitive]() { }
static get [Symbol.toPrimitive]() { return ""; }
static set [Symbol.toPrimitive](x) { }
} | //@target: ES6
//@declaration: true
class C {
static [Symbol.iterator] = 0;
static [Symbol.isConcatSpreadable]() { }
static get [Symbol.toPrimitive]() { return ""; }
static set [Symbol.toPrimitive](x) { }
} | Fix a test so that we don't get duplicate declaration errors. | Fix a test so that we don't get duplicate declaration errors.
| TypeScript | apache-2.0 | gdi2290/TypeScript,jwbay/TypeScript,mmoskal/TypeScript,bpowers/TypeScript,weswigham/TypeScript,synaptek/TypeScript,SaschaNaz/TypeScript,fabioparra/TypeScript,jeremyepling/TypeScript,sassson/TypeScript,alexeagle/TypeScript,billti/TypeScript,AbubakerB/TypeScript,DLehenbauer/TypeScript,nojvek/TypeScript,mihailik/TypeScrip... | ---
+++
@@ -2,7 +2,7 @@
//@declaration: true
class C {
static [Symbol.iterator] = 0;
- static [Symbol.toPrimitive]() { }
+ static [Symbol.isConcatSpreadable]() { }
static get [Symbol.toPrimitive]() { return ""; }
static set [Symbol.toPrimitive](x) { }
} |
d4e2a7d642f17addc2ede2f4672c0cd287dda90c | web/frontend/app/App.tsx | web/frontend/app/App.tsx | 'use strict';
import * as React from 'react';
import { Router, browserHistory } from 'react-router';
import { Provider } from 'react-redux'
import {routes} from './routes'
import { createStore } from './store'
import { isTokenValid, getToken, setToken, removeToken } from '../common/lib/token'
import { fetch } from '.... | 'use strict';
import * as React from 'react';
import { Router, browserHistory } from 'react-router';
import { Provider } from 'react-redux'
import {routes} from './routes'
import { createStore } from './store'
import { isTokenValid, getToken, setToken, removeToken } from '../common/lib/token'
import { fetch } from '.... | Initialize to username and accessLevel to guest if no valid token is found. | Initialize to username and accessLevel to guest if no valid token is found.
| TypeScript | mit | sainthkh/ko-academy,sainthkh/ko-academy | ---
+++
@@ -34,7 +34,18 @@
})
} else {
removeToken()
+ dispatch({
+ type: "INIT_AUTH",
+ username: "guest",
+ accessLevel: "guest",
+ })
}
+ })
+ } else {
+ dispatch({
+ type: "INIT_AUTH",
+ username: "guest",
+ accessLevel: "guest",
})
... |
7f0b70290038f48392f14e1841cd3e418bf0146c | src/invitations/RoleField.tsx | src/invitations/RoleField.tsx | import * as React from 'react';
import { Link } from '@waldur/core/Link';
import { getUUID } from '@waldur/core/utils';
import { translate } from '@waldur/i18n';
export const RoleField = ({ invitation }) => {
if (invitation.customer_role) {
return <>{translate('owner')}</>;
} else if (invitation.project_role)... | import * as React from 'react';
import { Link } from '@waldur/core/Link';
import { getUUID } from '@waldur/core/utils';
import { translate } from '@waldur/i18n';
export const RoleField = ({ invitation }) => {
if (invitation.customer_role) {
return <>{translate('owner')}</>;
} else if (invitation.project_role)... | Fix invitation role rendering if project has been deleted. | Fix invitation role rendering if project has been deleted.
| TypeScript | mit | opennode/waldur-homeport,opennode/waldur-homeport,opennode/waldur-homeport,opennode/waldur-homeport | ---
+++
@@ -8,6 +8,9 @@
if (invitation.customer_role) {
return <>{translate('owner')}</>;
} else if (invitation.project_role) {
+ if (!invitation.project) {
+ return invitation.project_role;
+ }
return (
<Link
state="project.details" |
e2ee129d34958cf0fe83427ebb937831ebea1e5d | src/utils/index.ts | src/utils/index.ts | export function getRows<T>(grid: T[]): T[][] {
const size = Math.sqrt(grid.length);
const copy = grid.concat([]);
return getArray(size).map(() => copy.splice(0, size));
}
export function getColumns<T>(grid: T[]): T[][] {
return getRows(transpose(grid));
}
export function getDiagonals<T>(grid: T[]): T[][] {
... | export function getRows<T>(grid: T[]): T[][] {
const size = Math.sqrt(grid.length);
const copy = grid.concat([]);
return getArray(size).map(() => copy.splice(0, size));
}
export function getColumns<T>(grid: T[]): T[][] {
return getRows(transpose(grid));
}
export function getDiagonals<T>(grid: T[]): T[][] {
... | Optimize filter condition to fail earlier | Optimize filter condition to fail earlier
| TypeScript | mit | artfuldev/tictactoe-ai,artfuldev/tictactoe-ai | ---
+++
@@ -14,7 +14,7 @@
const last = grid.length - 1;
return [
grid.filter((x, i) => Math.floor(i / size) === i % size),
- grid.filter((x, i) => i > 0 && i % lesser === 0 && i !== last)
+ grid.filter((x, i) => i > 0 && i < last && i % lesser === 0)
];
}
|
51fba105b7f95193ec2eb234751030e87d3b4181 | src/Components/UserSettings/TwoFactorAuthentication/Components/ApiErrorModal.tsx | src/Components/UserSettings/TwoFactorAuthentication/Components/ApiErrorModal.tsx | import { Modal, Sans } from "@artsy/palette"
import React from "react"
import { ApiError } from "../ApiError"
interface ApiErrorModalProps {
errors: ApiError[]
onClose: () => void
show?: boolean
}
export const ApiErrorModal: React.FC<ApiErrorModalProps> = props => {
const { errors, onClose, show } = props
... | import { Dialog } from "@artsy/palette"
import React from "react"
import { ApiError } from "../ApiError"
interface ApiErrorModalProps {
errors: ApiError[]
onClose: () => void
show?: boolean
}
export const ApiErrorModal: React.FC<ApiErrorModalProps> = props => {
const { errors, onClose, show } = props
const... | Update 2FA enrollment API modal to use Palette dialog | Update 2FA enrollment API modal to use Palette dialog
| TypeScript | mit | artsy/reaction-force,artsy/reaction,artsy/reaction,artsy/reaction,artsy/reaction-force | ---
+++
@@ -1,4 +1,4 @@
-import { Modal, Sans } from "@artsy/palette"
+import { Dialog } from "@artsy/palette"
import React from "react"
import { ApiError } from "../ApiError"
@@ -14,15 +14,14 @@
const errorMessage = errors.map(error => error.message).join("\n")
return (
- <Modal
- forcedScroll={f... |
43245a30fd051904f90b80cebbcc97d38c4484ee | src/runtime/animate/index.ts | src/runtime/animate/index.ts | import { cubicOut } from 'svelte/easing';
import { is_function } from 'svelte/internal';
import { TransitionConfig } from 'svelte/transition';
export interface AnimationConfig extends TransitionConfig {}
interface FlipParams {
delay: number;
duration: number | ((len: number) => number);
easing: (t: number) => numb... | import { cubicOut } from 'svelte/easing';
import { is_function } from 'svelte/internal';
// todo: same as Transition, should it be shared?
export interface AnimationConfig {
delay?: number;
duration?: number;
easing?: (t: number) => number;
css?: (t: number, u: number) => string;
tick?: (t: number, u: number) => ... | Revert "chore: resolve TODO for reusing of TransitionConfig" | Revert "chore: resolve TODO for reusing of TransitionConfig"
This reverts commit 0831887ef91b3a3a2439722bf95c0d367bac926d.
This was causing TypeScript linting errors, and can be revisited at another time.
| TypeScript | mit | sveltejs/svelte,sveltejs/svelte | ---
+++
@@ -1,8 +1,14 @@
import { cubicOut } from 'svelte/easing';
import { is_function } from 'svelte/internal';
-import { TransitionConfig } from 'svelte/transition';
-export interface AnimationConfig extends TransitionConfig {}
+// todo: same as Transition, should it be shared?
+export interface AnimationConfi... |
e18267c9b2c7867c44a2504e4a0b7915e91d8a47 | src/routes/ExpressRouter.ts | src/routes/ExpressRouter.ts | /**
* Express routes configurations
*/
export abstract class ExpressRouter {
protected express: any;
public abstract start(): void;
constructor(express: any) {
this.express = express;
this.defaultRoutes();
}
private defaultRoutes(): void {
this.express.get("/", (req, res... | /**
* Express routes configurations
*/
export abstract class ExpressRouter {
protected express: any;
public abstract start(): void;
constructor(express: any) {
this.express = express;
this.defaultRoutes();
}
private defaultRoutes(): void {
this.express.get("/", (req, res... | Add route to list available routes | Add route to list available routes
| TypeScript | mit | linck/protontype | ---
+++
@@ -15,6 +15,16 @@
this.express.get("/", (req, res) =>
res.json({ status: "NTask API TEste" }));
this.express.get("/routes", (req, res) =>
- res.json({ routes: this.express._router.stack }));
+ res.json({ routes: this.printRoutes() }));
+ }
+
+ privat... |
a1608db52decd5b99dfdd6f160305ad412fb4b23 | app/services/instagram.ts | app/services/instagram.ts | import {XHR} from '../libs/xhr';
let ENDPOINT = 'api.instagram.com'
let API_VERSION = 'v1'
let ACCESS_TOKEN = '31003280.5c1de8f.3e76027eeefe429ba5cc90f0e64ccda0'
let CLIENT_ID = '5c1de8fe2653445489b480a72803a44c'
export class InstagramClient {
endpoint: string;
protocol: string;
token: string;
xhr: XHR;... | import {XHR} from '../libs/xhr';
let ENDPOINT = 'api.instagram.com'
let API_VERSION = 'v1'
let ACCESS_TOKEN = '31003280.5c1de8f.3e76027eeefe429ba5cc90f0e64ccda0'
let CLIENT_ID = '5c1de8fe2653445489b480a72803a44c'
export class InstagramClient {
endpoint: string
protocol: string = 'https://'
xhr: XHR;
const... | Use direct style variable initilisation | Use direct style variable initilisation
| TypeScript | mit | yadomi/lastagram,yadomi/lastagram,yadomi/lastagram | ---
+++
@@ -8,14 +8,12 @@
export class InstagramClient {
- endpoint: string;
- protocol: string;
- token: string;
+ endpoint: string
+ protocol: string = 'https://'
xhr: XHR;
constructor() {
- this.protocol = 'https://'
this.xhr = new XHR();
this.endpoint = [this.protocol, ENDPOINT... |
8bc1815d567ee953e59224ee0dbb483489e1e268 | src/types.ts | src/types.ts | import * as React from 'react';
type Callback = (...args: any[]) => void;
export type ErrorCallback = (error: Error | FetchError) => void;
export type LoadCallback = (src: string, isCached: boolean) => void;
export type PreProcessorCallback = (code: string) => string;
export interface Props extends Omit<React.HTMLPr... | import * as React from 'react';
type Callback = (...args: any[]) => void;
export type ErrorCallback = (error: Error | FetchError) => void;
export type LoadCallback = (src: string, isCached: boolean) => void;
export type PreProcessorCallback = (code: string) => string;
export interface Props extends Omit<React.SVGPro... | Update typings to use React.SVGProps instead of React.HTMLProps | Update typings to use React.SVGProps instead of React.HTMLProps
| TypeScript | mit | matthewwithanm/react-inlinesvg | ---
+++
@@ -6,7 +6,7 @@
export type LoadCallback = (src: string, isCached: boolean) => void;
export type PreProcessorCallback = (code: string) => string;
-export interface Props extends Omit<React.HTMLProps<SVGElement>, 'onLoad' | 'onError' | 'ref'> {
+export interface Props extends Omit<React.SVGProps<SVGElement... |
db4f902d71a2336121ab9249d5ba9779cc52f220 | src/index.ts | src/index.ts |
import * as React from 'react';
export { React };
import * as mui from 'material-ui';
export { mui };
import * as redux from 'redux';
export { redux };
import * as reactRedux from 'react-redux';
export { reactRedux };
import * as actions from './actions';
export { actions };
export { hypract } from './hypract';
... |
import * as React from 'react';
export { React };
import * as materialUi from 'material-ui';
export { materialUi };
import * as redux from 'redux';
export { redux };
import * as reactRedux from 'react-redux';
export { reactRedux };
import * as actions from './actions';
export { actions };
export { hypract } from ... | Rename export mui to materialUi | Rename export mui to materialUi
| TypeScript | mit | Mytrill/hypract,Mytrill/hypract | ---
+++
@@ -2,8 +2,8 @@
import * as React from 'react';
export { React };
-import * as mui from 'material-ui';
-export { mui };
+import * as materialUi from 'material-ui';
+export { materialUi };
import * as redux from 'redux';
export { redux }; |
378a4cbde41bba36cce8a777b8950e1248539bb3 | src/features/CodeActions.ts | src/features/CodeActions.ts | import vscode = require('vscode');
import { LanguageClient, RequestType, NotificationType } from 'vscode-languageclient';
import Window = vscode.window;
export function registerCodeActionCommands(client: LanguageClient): void {
vscode.commands.registerCommand('PowerShell.ApplyCodeActionEdits', (edit: any) => {
... | import vscode = require('vscode');
import { LanguageClient, RequestType, NotificationType } from 'vscode-languageclient';
import Window = vscode.window;
export function registerCodeActionCommands(client: LanguageClient): void {
vscode.commands.registerCommand('PowerShell.ApplyCodeActionEdits', (edit: any) => {
... | Set file path in ApplyCodeActionEdits | Set file path in ApplyCodeActionEdits
EditorServices invokes PSScriptAnalyzer by passing `ScriptDefinition` paramter and not `Path` parameter. This results in null value of `ScriptPath` property of the returned diagnostic record which in turns leads to null value of `edit.file`. Therefore, we need to retrieve file pat... | TypeScript | mit | PowerShell/vscode-powershell | ---
+++
@@ -6,10 +6,11 @@
vscode.commands.registerCommand('PowerShell.ApplyCodeActionEdits', (edit: any) => {
console.log("Applying edits");
console.log(edit);
-
+ var editor = Window.activeTextEditor;
+ var filePath = editor.document.fileName;
var workspaceEdit = new vsc... |
ccc59d8668edb60089805d3bc65ea6935fd8304a | src/index.ts | src/index.ts | export * from './tick-tock.module';
| export { TickTockService } from './services';
export { TickTockComponent } from './components';
export { TickTockModule } from './tick-tock.module';
| Fix for AOT build in CLI. | Fix for AOT build in CLI.
| TypeScript | mit | trekhleb/ng-library-starter,trekhleb/ng-library-starter,trekhleb/angular-library-seed,nowzoo/nowzoo-angular-bootstrap-lite,nowzoo/nowzoo-angular-bootstrap-lite,trekhleb/ng-library-starter,nowzoo/nowzoo-angular-bootstrap-lite,trekhleb/angular-library-seed,trekhleb/angular-library-seed | ---
+++
@@ -1 +1,3 @@
-export * from './tick-tock.module';
+export { TickTockService } from './services';
+export { TickTockComponent } from './components';
+export { TickTockModule } from './tick-tock.module'; |
b45d5c0bcba2c63a77a57576d0beebfdcd2ef66f | applications/mail/src/app/components/message/recipients/RecipientsList.tsx | applications/mail/src/app/components/message/recipients/RecipientsList.tsx | import { ContactEditProps } from '@proton/components/containers/contacts/edit/ContactEditModal';
import { MapStatusIcons } from '../../../models/crypto';
import RecipientItem from './RecipientItem';
import { RecipientOrGroup } from '../../../models/address';
interface Props {
recipientsOrGroup: RecipientOrGroup[];... | import { Fragment } from 'react';
import { ContactEditProps } from '@proton/components/containers/contacts/edit/ContactEditModal';
import { MapStatusIcons } from '../../../models/crypto';
import RecipientItem from './RecipientItem';
import { RecipientOrGroup } from '../../../models/address';
interface Props {
reci... | Move index prop on RecipienList | Move index prop on RecipienList
| TypeScript | mit | ProtonMail/WebClient,ProtonMail/WebClient,ProtonMail/WebClient | ---
+++
@@ -1,3 +1,4 @@
+import { Fragment } from 'react';
import { ContactEditProps } from '@proton/components/containers/contacts/edit/ContactEditModal';
import { MapStatusIcons } from '../../../models/crypto';
import RecipientItem from './RecipientItem';
@@ -23,28 +24,27 @@
isPrintModal,
onContactDeta... |
f98dbdfdabd9a3773f59e11c4941e734be9b2133 | src/polyfills.ts | src/polyfills.ts | // This file includes polyfills needed by Angular 2 and is loaded before
// the app. You can add your own extra polyfills to this file.
import 'core-js/es6/symbol';
import 'core-js/es6/object';
import 'core-js/es6/function';
import 'core-js/es6/parse-int';
import 'core-js/es6/parse-float';
import 'core-js/es6/number';
... | // This file includes polyfills needed by Angular 2 and is loaded before
// the app. You can add your own extra polyfills to this file.
import 'core-js/es6/symbol';
import 'core-js/es6/object';
import 'core-js/es6/function';
import 'core-js/es6/parse-int';
import 'core-js/es6/parse-float';
import 'core-js/es6/number';
... | Remove console debug info from build | test(proxy): Remove console debug info from build
| TypeScript | mit | gund/ng-http-interceptor,gund/ng2-http-interceptor,gund/ng-http-interceptor,gund/ng2-http-interceptor,gund/ng2-http-interceptor,gund/ng-http-interceptor | ---
+++
@@ -19,9 +19,6 @@
import 'zone.js/dist/zone';
// Proxy stub
-console.log('Proxy', Proxy);
if (!('Proxy' in window)) {
- console.log('No proxy! Patching...');
window['Proxy'] = {};
- console.log('Proxy', Proxy);
} |
e8616236493468c1f736d8362429d77d2e1939b5 | app/src/ui/branches/branch.tsx | app/src/ui/branches/branch.tsx | import * as React from 'react'
import * as moment from 'moment'
import { Octicon, OcticonSymbol } from '../octicons'
interface IBranchProps {
readonly name: string
readonly isCurrentBranch: boolean
/** The date may be null if we haven't loaded the tip commit yet. */
readonly lastCommitDate: Date | null
}
/*... | import * as React from 'react'
import * as moment from 'moment'
import { Octicon, OcticonSymbol } from '../octicons'
interface IBranchProps {
readonly name: string
readonly isCurrentBranch: boolean
/** The date may be null if we haven't loaded the tip commit yet. */
readonly lastCommitDate: Date | null
}
/*... | Convert BranchListItem to class for unused-props rule | Convert BranchListItem to class for unused-props rule
The react-unused props rule currently only understands classes
| TypeScript | mit | gengjiawen/desktop,artivilla/desktop,j-f1/forked-desktop,shiftkey/desktop,BugTesterTest/desktops,artivilla/desktop,artivilla/desktop,kactus-io/kactus,j-f1/forked-desktop,j-f1/forked-desktop,BugTesterTest/desktops,shiftkey/desktop,kactus-io/kactus,shiftkey/desktop,hjobrien/desktop,hjobrien/desktop,desktop/desktop,j-f1/f... | ---
+++
@@ -12,14 +12,20 @@
}
/** The branch component. */
-export function BranchListItem({ name, isCurrentBranch, lastCommitDate }: IBranchProps) {
- const date = lastCommitDate ? moment(lastCommitDate).fromNow() : ''
- const info = isCurrentBranch ? <Octicon symbol={OcticonSymbol.check} /> : date
- const in... |
d195bdf557dfa6cbea7a73b81105c9ea5665686e | scripts/generateTagTable.ts | scripts/generateTagTable.ts | import Tags from "../src/tags";
import { getMarkdownTable } from 'markdown-table-ts';
let tags = new Tags();
let formatted: string[][] = [];
tags.list.forEach(tag => {
formatted.push([tag.tag, tag.snippet]);
});
let table = getMarkdownTable({
table: {
head: ['Tag', 'Snippet'],
body: formatted... | import * as fs from 'fs';
import Tags from "../src/tags";
import { getMarkdownTable } from 'markdown-table-ts';
let tags = new Tags();
let formatted: string[][] = [];
tags.list.forEach(tag => {
formatted.push([tag.tag, tag.snippet]);
});
let table = getMarkdownTable({
table: {
head: ['Tag', 'Snippet'... | Add output file as well | Add output file as well
| TypeScript | mit | neild3r/vscode-php-docblocker | ---
+++
@@ -1,3 +1,4 @@
+import * as fs from 'fs';
import Tags from "../src/tags";
import { getMarkdownTable } from 'markdown-table-ts';
@@ -15,4 +16,12 @@
},
});
+console.log('');
console.log(table);
+console.log('');
+
+fs.writeFile('./out/TAGS.md', table, 'utf8', function (err) {
+ if (err) {
+ ... |
ddea73671eff362ce4b3c2e34d2962be0cb4a5d7 | projects/hslayers/src/components/add-layers/add-layers.service.ts | projects/hslayers/src/components/add-layers/add-layers.service.ts | import BaseLayer from 'ol/layer/Base';
import {HsConfig} from './../../config.service';
import {HsMapService} from '../map/map.service';
import {HsUtilsService} from '../utils/utils.service';
import {Injectable} from '@angular/core';
@Injectable({
providedIn: 'root',
})
export class HsAddLayersService {
constructo... | import BaseLayer from 'ol/layer/Base';
import {HsConfig} from './../../config.service';
import {HsMapService} from '../map/map.service';
import {HsUtilsService} from '../utils/utils.service';
import {Injectable} from '@angular/core';
@Injectable({
providedIn: 'root',
})
export class HsAddLayersService {
constructo... | Simplify zIndex shifting when adding before layer | Simplify zIndex shifting when adding before layer
| TypeScript | mit | hslayers/hslayers-ng,hslayers/hslayers-ng,hslayers/hslayers-ng,hslayers/hslayers-ng | ---
+++
@@ -14,29 +14,18 @@
public HsConfig: HsConfig
) {}
- addLayer(layer: BaseLayer, addBefore?: BaseLayer) {
- if (addBefore) {
- let prevLayerZIndex: number;
- const layers = this.hsMapService.map.getLayers();
- if (this.HsConfig.reverseLayerList) {
- layer.setZIndex(addBefore... |
eb4403f7335e2759745629ee17ff1489d65f5fe2 | src/app/js/component/feed-list.tsx | src/app/js/component/feed-list.tsx | import * as ReactDOM from "react-dom";
import * as React from "react";
import { CustomComponent } from "./../custom-component";
import { ComponentsRefs } from "./../components-refs";
import { Feed, FeedProp } from "./feed";
export class FeedList extends CustomComponent<{}, FeedListState> {
feedComponents: Feed[]... | import * as ReactDOM from "react-dom";
import * as React from "react";
import { CustomComponent } from "./../custom-component";
import { ComponentsRefs } from "./../components-refs";
import { Feed, FeedProp } from "./feed";
export class FeedList extends CustomComponent<{}, FeedListState> {
feedComponents: Feed[]... | Check if UUID is already used | Check if UUID is already used
| TypeScript | mit | Xstoudi/alduin,Xstoudi/alduin,Xstoudi/alduin | ---
+++
@@ -31,6 +31,12 @@
);
}
+ isIdAlreadyUsed(uuid: string) {
+ return !!this.state.feeds.find(feed => {
+ return feed.uuid === uuid;
+ });
+ }
+
addFeed(newFeed: FeedProp) {
const newFeeds = this.state.feeds.slice(0);
newFeeds[newFeeds.length]... |
71f008559afcfaf3cc0271d1f901b96f30101121 | src/renderer/padTimestamp.ts | src/renderer/padTimestamp.ts | export function padToHoursMinutesSeconds(timestamp) {
const shortTimestampPattern = /^\d{1,2}:\d\d$/;
const paddedTimestamp = `00:${timestamp}`;
if (shortTimestampPattern.test(timestamp)) {
return (paddedTimestamp);
} else {
return (timestamp);
}
}
| const padToHoursMinutesSeconds: (s: string) => string = (timestamp: string) => {
const shortTimestampPattern: RegExp = /^\d{1,2}:\d\d$/;
const paddedTimestamp: string = `00:${timestamp}`;
if (shortTimestampPattern.test(timestamp)) {
return paddedTimestamp;
} else {
return timestamp;
}
};
export { pa... | Add type annotations to timestamp-padding function | Add type annotations to timestamp-padding function
| TypeScript | agpl-3.0 | briandk/transcriptase,briandk/transcriptase | ---
+++
@@ -1,10 +1,12 @@
-export function padToHoursMinutesSeconds(timestamp) {
- const shortTimestampPattern = /^\d{1,2}:\d\d$/;
- const paddedTimestamp = `00:${timestamp}`;
+const padToHoursMinutesSeconds: (s: string) => string = (timestamp: string) => {
+ const shortTimestampPattern: RegExp = /^\d{1,2}:\d\d$/;... |
2bfc8fa97a2da018bffbc76354576b7e6a7f73ee | src/selectors/watcherTree.ts | src/selectors/watcherTree.ts | import { createSelector } from 'reselect';
import { watcherTreeSelector } from './index';
import { normalizedWatchers } from './watchers';
export const getCurrentlySelectedWatcherIdOrNull = createSelector(
[watcherTreeSelector, normalizedWatchers],
(watcherSettings, watchers) => {
const { selectionId, s... | import { createSelector } from 'reselect';
import { watcherTreeSelector } from './index';
import { normalizedWatchers } from './watchers';
import { Watcher } from '../types';
export const getCurrentlySelectedWatcherIdOrNull = createSelector(
[watcherTreeSelector, normalizedWatchers],
(watcherSettings, watch... | Fix crash when deleting a selected watcher. | Fix crash when deleting a selected watcher.
| TypeScript | mit | Anveio/mturk-engine,Anveio/mturk-engine,Anveio/mturk-engine | ---
+++
@@ -1,6 +1,7 @@
import { createSelector } from 'reselect';
import { watcherTreeSelector } from './index';
import { normalizedWatchers } from './watchers';
+import { Watcher } from '../types';
export const getCurrentlySelectedWatcherIdOrNull = createSelector(
[watcherTreeSelector, normalizedWatchers],... |
6472e895915e84019b5edd5afcfe1b1b4616f335 | packages/react-day-picker/src/hooks/useModifiers/useModifiers.ts | packages/react-day-picker/src/hooks/useModifiers/useModifiers.ts | import { ModifierStatus } from '../../types';
import { useDayPicker } from '../useDayPicker';
import { useSelection } from '../useSelection';
import { getModifierStatus } from './utils/getModifierStatus';
/** Return the status for the modifiers given the specified date */
export function useModifiers(date: Date): Modi... | import { ModifierStatus } from '../../types';
import { useDayPicker } from '../useDayPicker';
import { useSelection } from '../useSelection';
import { getModifierStatus } from './utils/getModifierStatus';
/** Return the status for the modifiers given the specified date */
export function useModifiers(date: Date): Modi... | Fix for today modifier not being added | Fix for today modifier not being added
| TypeScript | mit | gpbl/react-day-picker,gpbl/react-day-picker,gpbl/react-day-picker | ---
+++
@@ -8,6 +8,8 @@
const context = useDayPicker();
const selection = useSelection();
const modifiers = Object.assign({}, context.modifiers);
+
+ modifiers.today = context.today;
if (context.mode !== 'uncontrolled') {
const { single, multiple, range } = selection ?? {}; |
d67708d7e293ec86cf1551c4cea5c56263803874 | components/error/page/page-components.ts | components/error/page/page-components.ts | import Vue from 'vue';
import { State } from 'vuex-class';
import { Component } from 'vue-property-decorator';
import View400 from '!view!./page-400.html';
import View403 from '!view!./page-403.html';
import View500 from '!view!./page-500.html';
import View404 from '!view!./page-404.html';
import ViewOffline from '!vie... | import Vue from 'vue';
import { State } from 'vuex-class';
import { Component } from 'vue-property-decorator';
import View400 from '!view!./page-400.html';
import View403 from '!view!./page-403.html';
import View500 from '!view!./page-500.html';
import View404 from '!view!./page-404.html';
import ViewOffline from '!vie... | Fix error page's retry button | Fix error page's retry button
| TypeScript | mit | gamejolt/frontend-lib,gamejolt/frontend-lib,gamejolt/frontend-lib,gamejolt/frontend-lib | ---
+++
@@ -27,7 +27,6 @@
@ViewOffline
@Component({})
export class AppErrorPageOffline extends Vue {
- @State
retry() {
Navigate.reload();
} |
060debc9c618a17b76ea86071dc3658407dc5c6e | src/dependument.manager.ts | src/dependument.manager.ts | import { IFileSystem } from './filesystem/filesystem.i';
import { ITemplateFileSystem } from './templates/templatefilesystem.i';
import * as Path from 'path';
export class DependumentManager {
private _fileSystem : IFileSystem;
private _templateFileSystem : ITemplateFileSystem;
constructor(fileSystem: IFileSyst... | import { IFileSystem } from './filesystem/filesystem.i';
import { ITemplateFileSystem } from './templates/templatefilesystem.i';
import * as Path from 'path';
export class DependumentManager {
private _fileSystem : IFileSystem;
private _templateFileSystem : ITemplateFileSystem;
constructor(fileSystem: IFileSyst... | Remove unnecessary code from DependumentManager constructor | Remove unnecessary code from DependumentManager constructor
| TypeScript | unlicense | dependument/dependument,Jameskmonger/dependument,Jameskmonger/dependument,dependument/dependument | ---
+++
@@ -7,12 +7,7 @@
private _templateFileSystem : ITemplateFileSystem;
constructor(fileSystem: IFileSystem, templateFileSystem: ITemplateFileSystem) {
- let rootName = Path.resolve(__dirname, '../');
-
this._fileSystem = fileSystem;
this._templateFileSystem = templateFileSystem;
-
- conso... |
b5f927e2317331c5abc4d3c64fcf931f450f7623 | projects/showcase-e2e/src/popup.e2e-spec.ts | projects/showcase-e2e/src/popup.e2e-spec.ts | import { browser, element, by, ExpectedConditions as EC } from 'protractor';
const browserLogs = require('protractor-browser-logs');
describe('Popup', () => {
let logs: any;
beforeEach(() => {
logs = browserLogs(browser);
});
afterEach(() => {
return logs.verify();
});
it('should show', async ()... | import { browser, element, by, ExpectedConditions as EC } from 'protractor';
const browserLogs = require('protractor-browser-logs');
describe('Popup', () => {
let logs: any;
beforeEach(() => {
logs = browserLogs(browser);
});
afterEach(() => {
return logs.verify();
});
it('should show', async ()... | Fix CI error "toHaveClass is not a function" | Fix CI error "toHaveClass is not a function"
| TypeScript | mit | Wykks/ngx-mapbox-gl,Wykks/ngx-mapbox-gl,Wykks/ngx-mapbox-gl,Wykks/ngx-mapbox-gl | ---
+++
@@ -19,8 +19,9 @@
const popup = element(by.className('mapboxgl-popup'));
await browser.wait(EC.presenceOf(popup), 1000);
- expect(popup).toHaveClass('custom-popup-class1');
- expect(popup).toHaveClass('custom-popup-class2');
+ const popupClasses = popup.getAttribute('class').then(c => c.s... |
0cae42913e5a0fb9bfce82053956580525d958b6 | src/rancher/template/ClusterTemplateList.tsx | src/rancher/template/ClusterTemplateList.tsx | import * as React from 'react';
import { Table, connectTable, createFetcher } from '@waldur/table-react';
const TableComponent = props => {
const { translate } = props;
return (
<Table
{...props}
columns={[
{
title: translate('Name'),
render: ({ row }) => <span>{row.nam... | import * as React from 'react';
import { Link } from '@waldur/core/Link';
import { Table, connectTable, createFetcher } from '@waldur/table-react';
const TableComponent = props => {
const { translate } = props;
return (
<Table
{...props}
columns={[
{
title: translate('Name'),
... | Allow Application creation from Application template list | Allow Application creation from Application template list [WAL-3082]
| TypeScript | mit | opennode/waldur-homeport,opennode/waldur-homeport,opennode/waldur-homeport,opennode/waldur-homeport | ---
+++
@@ -1,5 +1,6 @@
import * as React from 'react';
+import { Link } from '@waldur/core/Link';
import { Table, connectTable, createFetcher } from '@waldur/table-react';
const TableComponent = props => {
@@ -10,7 +11,18 @@
columns={[
{
title: translate('Name'),
- render: ... |
87570f71c62cb11b44d8056f1f38c9e744330970 | src/app/components/forms/dashboard/game/dev-stage-selector/dev-stage-selector-directive.ts | src/app/components/forms/dashboard/game/dev-stage-selector/dev-stage-selector-directive.ts | import { Component, Inject, Input } from 'ng-metadata/core';
import { FormDashboardGameDevStageSelectorConfirm } from './confirm-service';
import template from 'html!./dev-stage-selector.html';
@Component({
selector: 'gj-form-dashboard-game-dev-stage-selector',
template,
})
export class DevStageSelectorComponent
{
... | import { Component, Inject, Input } from 'ng-metadata/core';
import { FormDashboardGameDevStageSelectorConfirm } from './confirm-service';
import template from 'html!./dev-stage-selector.html';
@Component({
selector: 'gj-form-dashboard-game-dev-stage-selector',
template,
})
export class DevStageSelectorComponent
{
... | Add a growl when switching your dev stage. | Add a growl when switching your dev stage.
| TypeScript | mit | gamejolt/gamejolt,gamejolt/gamejolt,gamejolt/gamejolt,gamejolt/gamejolt | ---
+++
@@ -12,7 +12,9 @@
constructor(
@Inject( 'Game' ) public gameModel: any,
- @Inject( 'FormDashboardGameDevStageSelectorConfirm' ) private confirm: FormDashboardGameDevStageSelectorConfirm
+ @Inject( 'FormDashboardGameDevStageSelectorConfirm' ) private confirm: FormDashboardGameDevStageSelectorConfirm,
... |
dc3557df9449513b308d2a216f62407fb3e597d0 | src/client/components/DemographicsChart.tsx | src/client/components/DemographicsChart.tsx | /** @jsx jsx */
import mapValues from "lodash/mapValues";
import { Box, Flex, jsx } from "theme-ui";
import { demographicsColors } from "../constants/colors";
const Bar = ({ width, color }: { readonly width: string; readonly color: string }) => (
<Box
sx={{
width,
backgroundColor: color,
flex:... | /** @jsx jsx */
import mapValues from "lodash/mapValues";
import { Box, Flex, jsx } from "theme-ui";
import { demographicsColors } from "../constants/colors";
const Bar = ({ width, color }: { readonly width: string; readonly color: string }) => (
<Box
sx={{
width,
backgroundColor: color,
flex:... | Fix size for race chart | Fix size for race chart
| TypeScript | apache-2.0 | PublicMapping/DistrictBuilder,PublicMapping/DistrictBuilder,PublicMapping/DistrictBuilder,PublicMapping/DistrictBuilder,PublicMapping/DistrictBuilder | ---
+++
@@ -25,7 +25,7 @@
`${(demographics.population ? population / demographics.population : 0) * 100}%`
);
return (
- <Flex sx={{ flexDirection: "column", width: "100%", minHeight: "100%" }}>
+ <Flex sx={{ flexDirection: "column", width: "40px", minHeight: "20px", flexShrink: 0 }}>
<Bar w... |
e77d5cf1dd175040d341101cf03fd5e9542a9fb0 | source/renderer/app/components/wallet/summary/WalletSummaryHeaderRewards.spec.ts | source/renderer/app/components/wallet/summary/WalletSummaryHeaderRewards.spec.ts | import BigNumber from 'bignumber.js';
import {
discreetRewardsAmount,
getFormattedRewardAmount,
} from './WalletSummaryHeaderRewards';
describe('getFormattedRewardAmount', () => {
it('should render integer amounts without decimal places', () => {
expect(getFormattedRewardAmount(new BigNumber(1))).toEqual('1 ... | import BigNumber from 'bignumber.js';
import {
discreetRewardsAmount,
getFormattedRewardAmount,
} from './WalletSummaryHeaderRewards';
describe('getFormattedRewardAmount', () => {
it('should render integer amounts without decimal places', () => {
expect(getFormattedRewardAmount(new BigNumber(1))).toEqual('1 ... | Fix broken test case about dash | [DDW-614] Fix broken test case about dash
| TypeScript | apache-2.0 | input-output-hk/daedalus,input-output-hk/daedalus,input-output-hk/daedalus,input-output-hk/daedalus,input-output-hk/daedalus,input-output-hk/daedalus | ---
+++
@@ -19,7 +19,7 @@
const symbol = '***';
it('should replace the amount with a dash while restoring', () => {
const replacer = discreetRewardsAmount(true);
- expect(replacer(true, symbol, new BigNumber(0))).toEqual('-');
+ expect(replacer(true, symbol, new BigNumber(0))).toEqual('–');
});
... |
716a112b8d60d8b321a0894d096cd1adcef94795 | app/src/lib/editors/linux.ts | app/src/lib/editors/linux.ts | import { IFoundEditor } from './found-editor'
import { pathExists } from '../file-system'
import { assertNever } from '../fatal-error'
export enum ExternalEditor {
VisualStudioCode = 'Visual Studio Code',
}
export function parse(label: string): ExternalEditor | null {
if (label === ExternalEditor.VisualStudioCode... | import { IFoundEditor } from './found-editor'
import { pathExists } from '../file-system'
import { assertNever } from '../fatal-error'
export enum ExternalEditor {
Atom = 'Atom',
VisualStudioCode = 'Visual Studio Code',
}
export function parse(label: string): ExternalEditor | null {
if (label === ExternalEditor... | Add Atom support on Linux | Add Atom support on Linux
| TypeScript | mit | say25/desktop,artivilla/desktop,artivilla/desktop,kactus-io/kactus,j-f1/forked-desktop,desktop/desktop,desktop/desktop,desktop/desktop,shiftkey/desktop,say25/desktop,kactus-io/kactus,kactus-io/kactus,j-f1/forked-desktop,shiftkey/desktop,j-f1/forked-desktop,say25/desktop,shiftkey/desktop,artivilla/desktop,shiftkey/deskt... | ---
+++
@@ -3,10 +3,15 @@
import { assertNever } from '../fatal-error'
export enum ExternalEditor {
+ Atom = 'Atom',
VisualStudioCode = 'Visual Studio Code',
}
export function parse(label: string): ExternalEditor | null {
+ if (label === ExternalEditor.Atom) {
+ return ExternalEditor.Atom
+ }
+
if... |
967f22210dca8f79ce3894ae954393c256c04771 | components/locale-provider/it_IT.tsx | components/locale-provider/it_IT.tsx | import Pagination from 'rc-pagination/lib/locale/it_IT';
import DatePicker from '../date-picker/locale/it_IT';
import TimePicker from '../time-picker/locale/it_IT';
import Calendar from '../calendar/locale/it_IT';
export default {
locale: 'it',
Pagination,
DatePicker,
TimePicker,
Calendar,
Table: {
fil... | import Pagination from 'rc-pagination/lib/locale/it_IT';
import DatePicker from '../date-picker/locale/it_IT';
import TimePicker from '../time-picker/locale/it_IT';
import Calendar from '../calendar/locale/it_IT';
export default {
locale: 'it',
Pagination,
DatePicker,
TimePicker,
Calendar,
global: {
pl... | Add Italian localization of Icon, Text and global components | Add Italian localization of Icon, Text and global components
| TypeScript | mit | ant-design/ant-design,icaife/ant-design,icaife/ant-design,elevensky/ant-design,elevensky/ant-design,zheeeng/ant-design,elevensky/ant-design,icaife/ant-design,icaife/ant-design,ant-design/ant-design,elevensky/ant-design,ant-design/ant-design,zheeeng/ant-design,zheeeng/ant-design,zheeeng/ant-design,ant-design/ant-design | ---
+++
@@ -9,6 +9,9 @@
DatePicker,
TimePicker,
Calendar,
+ global: {
+ placeholder: 'Selezionare',
+ },
Table: {
filterTitle: 'Menù Filtro',
filterConfirm: 'OK',
@@ -40,4 +43,13 @@
Empty: {
description: 'Nessun dato',
},
+ Icon: {
+ icon: 'icona',
+ },
+ Text: {
+ edit:... |
9886dce63dfa876e00a088655bed49370466dd43 | packages/components/containers/referral/rewards/table/RewardCell.tsx | packages/components/containers/referral/rewards/table/RewardCell.tsx | import { c, msgid } from 'ttag';
import { Referral, ReferralState } from '@proton/shared/lib/interfaces';
interface Props {
referral: Referral;
}
const RewardCell = ({ referral }: Props) => {
let reward: string | React.ReactNode = '-';
const monthsRewarded = referral.RewardMonths || 0;
switch (refer... | import { c, msgid } from 'ttag';
import { Referral, ReferralState } from '@proton/shared/lib/interfaces';
interface Props {
referral: Referral;
}
const RewardCell = ({ referral }: Props) => {
let reward: string | React.ReactNode = '-';
const monthsRewarded = referral.RewardMonths || 0;
switch (refer... | Remove pending months in reward cell when signedup or trial | Remove pending months in reward cell when signedup or trial
| TypeScript | mit | ProtonMail/WebClient,ProtonMail/WebClient,ProtonMail/WebClient | ---
+++
@@ -11,7 +11,6 @@
const monthsRewarded = referral.RewardMonths || 0;
switch (referral.State) {
- case ReferralState.SIGNED_UP:
case ReferralState.COMPLETED:
/*
* translator : We are in a table cell. |
a2ab817973adb45acf67a62f2d481300e5a6b017 | src/kayenta/metricStore/stackdriver/domain/IStackdriverCanaryMetricSetQueryConfig.ts | src/kayenta/metricStore/stackdriver/domain/IStackdriverCanaryMetricSetQueryConfig.ts | import { ICanaryMetricSetQueryConfig } from 'kayenta/domain';
export interface IStackdriverCanaryMetricSetQueryConfig extends ICanaryMetricSetQueryConfig {
metricType: string;
groupByFields: string[];
}
| import { ICanaryMetricSetQueryConfig } from 'kayenta/domain';
export interface IStackdriverCanaryMetricSetQueryConfig extends ICanaryMetricSetQueryConfig {
metricType: string;
resourceType: string;
crossSeriesReducer: string;
perSeriesAligner: string;
groupByFields: string[];
}
| Add new metric config fields. | feat(stackdriver): Add new metric config fields.
| TypeScript | apache-2.0 | spinnaker/deck-kayenta,spinnaker/deck-kayenta,spinnaker/deck-kayenta,spinnaker/deck-kayenta | ---
+++
@@ -2,5 +2,8 @@
export interface IStackdriverCanaryMetricSetQueryConfig extends ICanaryMetricSetQueryConfig {
metricType: string;
+ resourceType: string;
+ crossSeriesReducer: string;
+ perSeriesAligner: string;
groupByFields: string[];
} |
a77c3a31d97fb70028c7bce6cf1fcf6abf895d6b | html/ts/reports/cmdtable.tsx | html/ts/reports/cmdtable.tsx |
function reportCmdTable(profile: Profile[], search: Prop<Search>): HTMLElement {
return cmdTableData(search.get());
}
function cmdTableData(search: Search): HTMLElement {
const res: MapString< {count: int, total: seconds, max: seconds} > = {};
search.forEachProfile(p =>
p.traces.forEach(t => {
... |
function reportCmdTable(profile: Profile[], search: Prop<Search>): HTMLElement {
const columns: Column[] =
[ {field: "name", label: "Name", width: 200}
, {field: "count", label: "Count", width: 75, alignRight: true, show: showInt}
, {field: "total", label: "Total", width: 75, alignRight: tr... | Simplify the command, split out data from UI | Simplify the command, split out data from UI
| TypeScript | bsd-3-clause | ndmitchell/shake,ndmitchell/shake,ndmitchell/shake,ndmitchell/shake,ndmitchell/shake,ndmitchell/shake | ---
+++
@@ -1,9 +1,16 @@
function reportCmdTable(profile: Profile[], search: Prop<Search>): HTMLElement {
- return cmdTableData(search.get());
+ const columns: Column[] =
+ [ {field: "name", label: "Name", width: 200}
+ , {field: "count", label: "Count", width: 75, alignRight: true, show: showI... |
9693c1ab1302d8c51f48829d6b7701b4ed580d44 | packages/machinomy/src/storage/postgresql/migrations/20180115082606-create-payment.ts | packages/machinomy/src/storage/postgresql/migrations/20180115082606-create-payment.ts | import { Base, CallbackFunction } from 'db-migrate-base'
import bigNumberColumn from './util/bigNumberColumn'
export function up (db: Base, callback: CallbackFunction) {
const createTableOptions = {
columns: {
channelId: {
type: 'string',
notNull: true,
foreignKey: {
name:... | import { Base, CallbackFunction } from 'db-migrate-base'
import bigNumberColumn from './util/bigNumberColumn'
export function up (db: Base, callback: CallbackFunction) {
const createTableOptions = {
columns: {
channelId: {
type: 'string',
notNull: true
},
kind: 'string',
t... | Remove one more constraint on db level | Remove one more constraint on db level
| TypeScript | apache-2.0 | machinomy/machinomy,machinomy/machinomy,machinomy/machinomy | ---
+++
@@ -6,15 +6,7 @@
columns: {
channelId: {
type: 'string',
- notNull: true,
- foreignKey: {
- name: 'tokens_channel_id_fk',
- table: 'channel',
- mapping: 'channelId',
- rules: {
- onDelete: 'CASCADE'
- }
- }
+ ... |
c6c31a69852893edd7aa62d64e8865d484139703 | src/actions/GrabbedAction.ts | src/actions/GrabbedAction.ts | import { Action } from "./Action";
import { ActionType } from "./ActionType";
import { StrayKittyState } from "../StrayKittyState";
import { StandingAction } from "./StandingAction";
import { ActionHelpers } from "./ActionHelpers";
export class GrabbedAction implements Action {
do(kitty: StrayKittyState, dt: numbe... | import { Action } from "./Action";
import { ActionType } from "./ActionType";
import { StrayKittyState } from "../StrayKittyState";
import { StandingAction } from "./StandingAction";
import { ActionHelpers } from "./ActionHelpers";
export class GrabbedAction implements Action {
do(kitty: StrayKittyState, dt: numbe... | Fix kitties can't be grabbed | Fix kitties can't be grabbed
| TypeScript | mit | xianbaum/StrayKitty,xianbaum/StrayKitty,xianbaum/StrayKitty | ---
+++
@@ -6,18 +6,9 @@
export class GrabbedAction implements Action {
do(kitty: StrayKittyState, dt: number) {
- if (kitty.y < window.innerHeight - 32) {
- kitty.yVector += dt / 250;
- } else {
- if (Math.abs(kitty.yVector) < dt / 100) {
- kitty.y = window.... |
b9c3c760a9dcc9884e175fa4d8ac2e841639f7f7 | app/src/config.ts | app/src/config.ts | /*
* The MIT License (MIT)
* Copyright (c) 2016 Heat Ledger Ltd.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use... | /*
* The MIT License (MIT)
* Copyright (c) 2016 Heat Ledger Ltd.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy of
* this software and associated documentation files (the "Software"), to deal in
* the Software without restriction, including without limitation the rights to
* use... | Set default theme to indigo | Set default theme to indigo
| TypeScript | mit | Heat-Ledger-Ltd/heat-ui,Heat-Ledger-Ltd/heat-ui,Heat-Ledger-Ltd/heat-ui | ---
+++
@@ -24,8 +24,8 @@
($mdThemingProvider, noCAPTCHAProvider) => {
$mdThemingProvider.theme('default')
- .primaryPalette('teal')
- .accentPalette('grey');
+ .primaryPalette('indigo')
+ .accentPalette('pink');... |
781c4563dbf7f5bff7a4fb72d663b867bfb98889 | src/ng2-restangular-helper.ts | src/ng2-restangular-helper.ts | import {URLSearchParams, Headers, RequestOptions, RequestMethod} from '@angular/http';
export class RestangularHelper {
static createRequestOptions(options) {
let requestQueryParams = RestangularHelper.createRequestQueryParams(options.params);
let requestHeaders = RestangularHelper.createRequestHeaders(op... | import {URLSearchParams, Headers, RequestOptions, RequestMethod} from '@angular/http';
export class RestangularHelper {
static createRequestOptions(options) {
let requestQueryParams = RestangularHelper.createRequestQueryParams(options.params);
let requestHeaders = RestangularHelper.createRequestHeaders(op... | Fix URLSearchParams for query params of type Array | Fix URLSearchParams for query params of type Array
| TypeScript | mit | 2muchcoffeecom/ng2-restangular,2muchcoffeecom/ng2-restangular,2muchcoffeecom/ngx-restangular,2muchcoffeecom/ngx-restangular | ---
+++
@@ -26,10 +26,18 @@
for (let key in requestQueryParams) {
let value: any = requestQueryParams[key];
- if (typeof value === 'object') {
- value = JSON.stringify(value);
+
+ if (Array.isArray(value)) {
+ value.forEach(function(val){
+ search.append(key, val);
+... |
c24131f80483d0d4ca4a3f7efff58fd43286b617 | config.service.ts | config.service.ts | export class HsConfig {
componentsEnabled: any;
mapInteractionsEnabled: boolean;
allowAddExternalDatasets: boolean;
sidebarClosed: boolean;
layer_order: string
constructor() {
}
} | export class HsConfig {
componentsEnabled: any;
mapInteractionsEnabled: boolean;
allowAddExternalDatasets: boolean;
sidebarClosed: boolean;
layer_order: string;
box_layers: Array<any>;
constructor() {
}
} | Add box layer to config class definition | Add box layer to config class definition
| TypeScript | mit | hslayers/hslayers-ng,hslayers/hslayers-ng,hslayers/hslayers-ng,hslayers/hslayers-ng | ---
+++
@@ -3,7 +3,8 @@
mapInteractionsEnabled: boolean;
allowAddExternalDatasets: boolean;
sidebarClosed: boolean;
- layer_order: string
+ layer_order: string;
+ box_layers: Array<any>;
constructor() {
} |
035be40c5869ea9e65dd89c0ea16aafac2636a3e | frontend/src/lib/StatusCalculator.ts | frontend/src/lib/StatusCalculator.ts | import Status from 'models/Status';
import Step from 'models/Step';
import Feature from 'models/Feature';
type ScenarioDetails = {
backgroundSteps: Step[];
steps: Step[];
};
const STATUS_PRIORITY_ORDER = [Status.Failed, Status.Undefined, Status.Skipped, Status.Passed];
export const calculateFeatureStatus = (featu... | import Status from 'models/Status';
import Step from 'models/Step';
import Feature from 'models/Feature';
type ScenarioDetails = {
backgroundSteps: Step[];
steps: Step[];
};
const STATUS_PRIORITY_ORDER = [Status.Failed, Status.Undefined, Status.Skipped, Status.Passed];
export const calculateFeatureStatus = (featu... | Check for null backgroundSteps just in case. | Check for null backgroundSteps just in case.
| TypeScript | apache-2.0 | orionhealth/XBDD,orionhealth/XBDD,orionhealth/XBDD,orionhealth/XBDD,orionhealth/XBDD | ---
+++
@@ -19,7 +19,9 @@
const calculateStatus = (scenario: ScenarioDetails, getStepStatus: (step: Step) => Status): Status => {
const statuses: Status[] = [];
- statuses.push(...scenario.backgroundSteps.map(getStepStatus));
+ if (scenario.backgroundSteps) {
+ statuses.push(...scenario.backgroundSteps.map... |
60b8bf7007ce05266dc5034dddba03c986a5f07d | test/lexer-spec.ts | test/lexer-spec.ts | import test from "ava";
import HclLexer from '../src/lexer';
test('Should find tokens correctly', t => {
const SOURCE_TEXT = `
foo = {
bar = "baz \$\${quux} \${var.mumble}"
quux = 42
}
// Example of a heredoc
mumble = <<EOF
foo bar \${baz(2 + 2)}
EOF
more_content = true
`;
const lex = new HclLexer(SOURCE_TEX... | import test from "ava";
import HclLexer from '../src/lexer';
function stringChars(str: string, type = 'stringChar') {
return str.split('').map((c: string) => [type, c]);
}
test('Should find tokens correctly', t => {
const SOURCE_TEXT = `
foo = {
bar = "baz \$\${quux} \${var.mumble}"
quux = 42
}
// Example of... | Make lexer test more robust | Make lexer test more robust
| TypeScript | mit | r24y/tf-hcl | ---
+++
@@ -1,5 +1,9 @@
import test from "ava";
import HclLexer from '../src/lexer';
+
+function stringChars(str: string, type = 'stringChar') {
+ return str.split('').map((c: string) => [type, c]);
+}
test('Should find tokens correctly', t => {
const SOURCE_TEXT = `
@@ -23,5 +27,49 @@
output.push(token... |
879c48c7304a766b02e926eca5b09ab45c60df4e | app/scripts/components/marketplace/offerings/OfferingConfigureStep.tsx | app/scripts/components/marketplace/offerings/OfferingConfigureStep.tsx | import * as React from 'react';
import { FieldArray } from 'redux-form';
import {
SelectAsyncField,
FormContainer,
SelectField,
} from '@waldur/form-react';
import { OfferingAttributes } from './OfferingAttributes';
import { OfferingOptions } from './OfferingOptions';
import { OfferingPlans } from './OfferingPl... | import * as React from 'react';
import { FieldArray } from 'redux-form';
import {
SelectAsyncField,
FormContainer,
SelectField,
} from '@waldur/form-react';
import { OfferingAttributes } from './OfferingAttributes';
import { OfferingOptions } from './OfferingOptions';
import { OfferingPlans } from './OfferingPl... | Make type and category fields in offering configuration form non-clearable. | Make type and category fields in offering configuration form non-clearable.
| TypeScript | mit | opennode/waldur-homeport,opennode/waldur-homeport,opennode/waldur-homeport,opennode/waldur-homeport | ---
+++
@@ -23,6 +23,7 @@
label={props.translate('Type')}
required={true}
options={props.offeringTypes}
+ clearable={false}
/>
<SelectAsyncField
name="category"
@@ -31,6 +32,7 @@
required={true}
labelKey="title"
valueKey="url"
+ ... |
7dc2daf44e2128b04141a9559c71c700d1ba64c0 | lib/msal-node/src/utils/Constants.ts | lib/msal-node/src/utils/Constants.ts | /*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License.
*/
/**
* http methods
*/
export enum HttpMethod {
GET = 'get',
POST = 'post',
}
/**
* Constant used for PKCE
*/
export const RANDOM_OCTET_SIZE = 32;
/**
* Constants used in PKCE
*/
export const Hash = {
... | /*
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License.
*/
/**
* http methods
*/
export enum HttpMethod {
GET = 'get',
POST = 'post',
}
/**
* Constant used for PKCE
*/
export const RANDOM_OCTET_SIZE = 32;
/**
* Constants used in PKCE
*/
export const Hash = {
... | Add comment to API codes | Add comment to API codes
| TypeScript | mit | AzureAD/microsoft-authentication-library-for-js,AzureAD/microsoft-authentication-library-for-js,AzureAD/microsoft-authentication-library-for-js,AzureAD/microsoft-authentication-library-for-js,AzureAD/microsoft-authentication-library-for-js,AzureAD/microsoft-authentication-library-for-js,AzureAD/microsoft-authentication... | ---
+++
@@ -46,7 +46,13 @@
MSAL_SKU: 'msal.js.node',
};
-// Telemetry Constants
+/**
+ * API Codes for Telemetry purposes.
+ * Before adding a new code you must claim it in the MSAL Telemetry tracker as these number spaces are shared across all MSALs
+ * 0-99 Silent Flow
+ * 600-699 Device Code Flow
+ * 800-... |
32434858c17adaa610f3505cea713a59c325d2c0 | src/app/components/header-navigation/header-navigation.component.ts | src/app/components/header-navigation/header-navigation.component.ts | import { Component, ViewEncapsulation } from '@angular/core';
import { Navigation } from '../../models/navigation';
@Component({
selector: 'header-navigation',
encapsulation: ViewEncapsulation.None,
styleUrls: ['./header-navigation.component.css'],
templateUrl: './header-navigation.component.html'
})
export cla... | import { Component, ViewEncapsulation } from '@angular/core';
import { Navigation } from '../../models/navigation';
@Component({
selector: 'header-navigation',
encapsulation: ViewEncapsulation.None,
styleUrls: ['./header-navigation.component.css'],
templateUrl: './header-navigation.component.html'
})
export cla... | Remove the main relationship list page | Remove the main relationship list page
| TypeScript | mit | unfetter-discover/unfetter-ui,unfetter-discover/unfetter-ui,unfetter-discover/unfetter-ui,unfetter-discover/unfetter-ui | ---
+++
@@ -14,7 +14,7 @@
{url: 'indicators', label: 'Indicators'},
{url: 'identities', label: 'Identities'},
{url: 'malwares', label: 'Malware'},
- {url: 'relationships', label: 'Relationships'},
+ // {url: 'relationships', label: 'Relationships'},
{url: 'sightings',... |
51650f462319e0aca97f59a714a107c814c5dc1f | templates/Angular2Spa/ClientApp/components/fetch-data/fetch-data.ts | templates/Angular2Spa/ClientApp/components/fetch-data/fetch-data.ts | import * as ng from 'angular2/core';
import { Http } from 'angular2/http';
@ng.Component({
selector: 'fetch-data',
template: require('./fetch-data.html')
})
export class FetchData {
public forecasts: WeatherForecast[];
constructor(http: Http) {
// TODO: Switch to relative URL once angular-universa... | import * as ng from 'angular2/core';
import { Http } from 'angular2/http';
@ng.Component({
selector: 'fetch-data',
template: require('./fetch-data.html')
})
export class FetchData {
public forecasts: WeatherForecast[];
constructor(http: Http) {
// Workaround for RC1 bug. This can be removed with A... | Clean up RC1 bug workaround | Clean up RC1 bug workaround
| TypeScript | apache-2.0 | aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore | ---
+++
@@ -9,11 +9,13 @@
public forecasts: WeatherForecast[];
constructor(http: Http) {
+ // Workaround for RC1 bug. This can be removed with ASP.NET Core 1.0 RC2.
+ let isServerSide = typeof window === 'undefined';
+ let options: any = isServerSide ? { headers: { Connection: 'keep-a... |
f33f63185aa6840cc5f2922cd696578a4007d099 | ui/src/cloud/utils/limits.ts | ui/src/cloud/utils/limits.ts | import {get} from 'lodash'
import {RATE_LIMIT_ERROR_STATUS} from 'src/cloud/constants/index'
import {LimitsState} from 'src/cloud/reducers/limits'
import {LimitStatus} from 'src/cloud/actions/limits'
export const isLimitError = (error): boolean => {
return get(error, 'response.status', '') === RATE_LIMIT_ERROR_STATU... | import {get} from 'lodash'
import {RATE_LIMIT_ERROR_STATUS} from 'src/cloud/constants/index'
import {LimitsState} from 'src/cloud/reducers/limits'
import {LimitStatus} from 'src/cloud/actions/limits'
export const isLimitError = (error): boolean => {
return get(error, 'response.status', '') === RATE_LIMIT_ERROR_STATU... | Fix reference to redux state in get | Fix reference to redux state in get
| TypeScript | mit | li-ang/influxdb,li-ang/influxdb,nooproblem/influxdb,influxdb/influxdb,nooproblem/influxdb,nooproblem/influxdb,influxdb/influxdb,influxdb/influxdb,influxdb/influxdb,mark-rushakoff/influxdb,nooproblem/influxdb,mark-rushakoff/influxdb,mark-rushakoff/influxdb,influxdata/influxdb,influxdb/influxdb,mark-rushakoff/influxdb,in... | ---
+++
@@ -20,7 +20,7 @@
}
export const extractDashboardMax = (limits: LimitsState): number => {
- return get(limits, 'dashboard.maxAllowed', Infinity)
+ return get(limits, 'dashboards.maxAllowed', Infinity)
}
export const extractTaskLimits = (limits: LimitsState): LimitStatus => {
@@ -28,5 +28,5 @@
}
... |
9b7ee514167575097046af369ae1c6389c9e9811 | 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/1.0.3',
RELEASEVERSION: '1.0.3'
};
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/1.0.4',
RELEASEVERSION: '1.0.4'
};
export = BaseConfig;
| Increase release version number to 1.0.4 | Increase release version number to 1.0.4
| 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/1.0.3',
- RELEASEVERSION: '1.0.3'
+ RELEASEURL: 'https://github.com/nie-ine/raeber-website/releases/tag/1.0.4',
+ RELEASEVERSION: '1.0.4'
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.