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 |
|---|---|---|---|---|---|---|---|---|---|---|
0863e003d74035ef7fa446a370e97ab17805eaa7 | test/maml/maml-spec.ts | test/maml/maml-spec.ts | import { expect } from "chai";
import { Frame, FrameExpr, FrameString } from "../../src/frames";
import { maml } from "../../src/maml";
describe("maml", () => {
const text = "Hello, MAML!";
const body = new FrameString(text);
const result = maml.call(body);
const result_string = result.toString();
it("is a ... | import { expect } from "chai";
import { Frame, FrameExpr, FrameString } from "../../src/frames";
import { maml } from "../../src/maml";
describe("maml", () => {
const text = "Hello, MAML!";
const body = new FrameString(text);
const result = maml.call(body);
const result_string = result.toString();
it("is a ... | Disable failing spec for now | Disable failing spec for now
| TypeScript | mit | TheSwanFactory/maml,TheSwanFactory/hclang,TheSwanFactory/maml,TheSwanFactory/hclang | ---
+++
@@ -19,6 +19,6 @@
it("wraps its argument in a body tag", () => {
expect(result).to.be.instanceOf(FrameString);
- expect(result_string).to.match(/<body>([\s\S]*)<\/body>/);
+ //expect(result_string).to.match(/<body>([\s\S]*)<\/body>/);
});
}); |
b0f8421fe26754fa5ff83ac8ace9b8da91585e5e | src/app/page-not-found/page-not-found.component.spec.ts | src/app/page-not-found/page-not-found.component.spec.ts | import { async, ComponentFixture, TestBed } from '@angular/core/testing';
import { By } from '@angular/platform-browser';
import { DebugElement } from '@angular/core';
import { PageNotFoundComponent } from './page-not-found.component';
describe('PageNotFoundComponent', () => {
let componentInstance... | import { async, ComponentFixture, TestBed } from '@angular/core/testing';
import { By } from '@angular/platform-browser';
import { DebugElement } from '@angular/core';
import { PageNotFoundComponent } from './page-not-found.component';
describe('PageNotFoundComponent', () => {
let componentInstance... | Add test to verify if component is created | Add test to verify if component is created
| TypeScript | mit | pawelec/todo-list,pawelec/todo-list,pawelec/todo-list,pawelec/todo-list | ---
+++
@@ -29,6 +29,8 @@
paragraph = de.nativeElement;
});
+ it('should create component', () => expect(componentInstance).toBeDefined());
+
it("should display title", () => {
fixture.detectChanges();
expect(header.textContent).toContain(componentInstance.title); |
f0d63c745c2db8eac5b96b20531097e35c5c798c | src/utils/asset.ts | src/utils/asset.ts | export function getAssetPath(url: string | undefined): string | undefined {
return url;
}
import { ICON_ZOOM_OUT_FIXED } from "../constants/assets";
let mRoot = ICON_ZOOM_OUT_FIXED.replace("/zoom-out-fixed.png", "/../../");
export function getAssetRoot(): string {
return mRoot;
}
export function setAssetRoo... | export function getAssetPath(url: string | undefined): string | undefined {
return url;
}
import { ICON_ZOOM_OUT_FIXED } from "../constants/assets";
//HACK: url-loader has done some breaking things to how our icon asset imports are handled
//while this has been addressed for the main bundle build, this import is ... | Fix failing jest tests due to url-loader update | Fix failing jest tests due to url-loader update
| TypeScript | mit | jumpinjackie/mapguide-react-layout,jumpinjackie/mapguide-react-layout,jumpinjackie/mapguide-react-layout,jumpinjackie/mapguide-react-layout,jumpinjackie/mapguide-react-layout | ---
+++
@@ -4,7 +4,12 @@
import { ICON_ZOOM_OUT_FIXED } from "../constants/assets";
-let mRoot = ICON_ZOOM_OUT_FIXED.replace("/zoom-out-fixed.png", "/../../");
+//HACK: url-loader has done some breaking things to how our icon asset imports are handled
+//while this has been addressed for the main bundle build, t... |
513543f48df8bc300e93d601a0c32327bdf5b6a1 | test/runTest.ts | test/runTest.ts | import * as path from 'path';
import { runTests,downloadAndUnzipVSCode } from 'vscode-test';
async function main() {
try {
var vscodeExecutablePath = await downloadAndUnzipVSCode('1.35.0')
} catch (err) {
console.error(err);
}
try {
// The folder containing the Extension Manif... | import * as path from 'path';
import { runTests,downloadAndUnzipVSCode } from 'vscode-test';
async function main() {
try {
// The folder containing the Extension Manifest package.json
// Passed to `--extensionDevelopmentPath`
const extensionDevelopmentPath = path.resolve(__dirname, '../../... | Change back to compiling on latest vscode | Change back to compiling on latest vscode
| TypeScript | mit | neild3r/vscode-php-docblocker | ---
+++
@@ -3,12 +3,6 @@
import { runTests,downloadAndUnzipVSCode } from 'vscode-test';
async function main() {
- try {
- var vscodeExecutablePath = await downloadAndUnzipVSCode('1.35.0')
- } catch (err) {
- console.error(err);
- }
-
try {
// The folder containing the Extensio... |
d3a04bf69d3aa346f44e24b527e611e17ea56748 | src/mobile/lib/model/MstGoal.ts | src/mobile/lib/model/MstGoal.ts | import {MstSvt} from "../../../model/master/Master";
import {MstSkillContainer, MstSvtSkillContainer, MstCombineSkillContainer} from "../../../model/impl/MstContainer";
export interface MstGoal {
appVer: string;
svtRawData: Array<MstSvt>;
svtSkillData: MstSvtSkillContainer;
skillCombineData: MstCombine... | import {MstSvt} from "../../../model/master/Master";
import {MstSkillContainer, MstSvtSkillContainer, MstCombineSkillContainer} from "../../../model/impl/MstContainer";
export interface MstGoal {
appVer: string;
svtRawData: Array<MstSvt>;
svtSkillData: MstSvtSkillContainer;
skillCombineData: MstCombine... | Fix one bug of db saving, data of db file invalid. | Fix one bug of db saving, data of db file invalid.
| TypeScript | mit | agreatfool/fgo-handbook,agreatfool/fgo-handbook,agreatfool/fgo-handbook,agreatfool/fgo-handbook,agreatfool/fgo-handbook,agreatfool/fgo-handbook | ---
+++
@@ -36,8 +36,8 @@
export const defaultMstGoal = { // MstGoal
appVer: undefined,
- current: undefined,
- goals: [defaultCurrentGoal],
+ current: defaultCurrentGoal,
+ goals: [],
compareSourceId: "current",
compareTargetId: "current",
} as MstGoal; |
5a2890e09a74f4e4f1b62b626db150a83d9a304c | packages/components/components/button/Button.tsx | packages/components/components/button/Button.tsx | import React from 'react';
import ButtonLike, { ButtonLikeProps } from './ButtonLike';
export interface ButtonProps extends Omit<ButtonLikeProps<'button'>, 'as' | 'ref'> {}
const Button = (props: ButtonProps, ref: React.Ref<HTMLButtonElement>) => {
return <ButtonLike type="button" ref={ref} {...props} as="button... | import React from 'react';
import ButtonLike, { ButtonLikeProps } from './ButtonLike';
export interface ButtonProps extends Omit<ButtonLikeProps<'button'>, 'as' | 'ref'> {}
const Button = React.forwardRef<HTMLButtonElement, ButtonProps>(
(props: ButtonProps, ref: React.Ref<HTMLButtonElement>) => {
return... | Change usage of forwardRef to enable typescript docgen again | Change usage of forwardRef to enable typescript docgen again
| TypeScript | mit | ProtonMail/WebClient,ProtonMail/WebClient,ProtonMail/WebClient | ---
+++
@@ -4,8 +4,10 @@
export interface ButtonProps extends Omit<ButtonLikeProps<'button'>, 'as' | 'ref'> {}
-const Button = (props: ButtonProps, ref: React.Ref<HTMLButtonElement>) => {
- return <ButtonLike type="button" ref={ref} {...props} as="button" />;
-};
+const Button = React.forwardRef<HTMLButtonEle... |
5e33a23cf9b0758a21b428e9bb1d5d63cb048366 | packages/extension/src/js/components/WinList.tsx | packages/extension/src/js/components/WinList.tsx | import React, { useRef, useEffect } from 'react'
import { observer } from 'mobx-react-lite'
import Scrollbar from 'libs/Scrollbar'
import ReactResizeDetector from 'react-resize-detector'
import Loading from './Loading'
import { useStore } from './hooks/useStore'
import Window from './Window'
export default observer(()... | import React, { useRef, useEffect } from 'react'
import { observer } from 'mobx-react-lite'
import Scrollbar from 'libs/Scrollbar'
import ReactResizeDetector from 'react-resize-detector'
import Loading from './Loading'
import { useStore } from './hooks/useStore'
import Window from './Window'
export default observer(()... | Update the tab/window width to be fit all available space if possible | fix: Update the tab/window width to be fit all available space if possible
| TypeScript | mit | xcv58/Tab-Manager-v2,xcv58/Tab-Manager-v2,xcv58/Tab-Manager-v2,xcv58/Tab-Manager-v2 | ---
+++
@@ -38,8 +38,7 @@
</div>
)
}
- const width =
- visibleColumn <= 4 ? 100 / visibleColumn + '%' : `${userStore.tabWidth}rem`
+ const width = `calc(max(${100 / visibleColumn}%, ${userStore.tabWidth}rem))`
const list = windows.map((window) => (
<Window key={window.id} width={width} win... |
938ab93b44981723450d3b49c24901418c7463df | bin/www.ts | bin/www.ts | /// <reference path='../typings/tsd.d.ts' />
import logger = require('../logger');
import app = require('../app');
import https = require('https');
import fs = require('fs');
var options = {
key: fs.readFileSync('./ssl/server.key'),
cert: fs.readFileSync('./ssl/server.crt'),
requestCert: false,
rejectUnauthorize... | /// <reference path='../typings/tsd.d.ts' />
import logger = require('../logger');
import app = require('../app');
import https = require('https');
import fs = require('fs');
var options = {
key: fs.readFileSync('./ssl/server.key'),
cert: fs.readFileSync('./ssl/server.crt'),
requestCert: false,
rejectUnauthorize... | Detach from mongo on server shutdown | Detach from mongo on server shutdown
| TypeScript | mit | PaperJamTeam/bibliothek,PaperJamTeam/bibliothek | ---
+++
@@ -35,6 +35,7 @@
process.exit(-1);
logger.debug('Server is shutting down...');
+ require('mongoose').connection.close();
}
//do something when app is closing |
1caea30d739e0f38b0da8ec3af3ed1029ec79154 | src/parsers/manifest/dash/common/get_http_utc-timing_url.ts | src/parsers/manifest/dash/common/get_http_utc-timing_url.ts | /**
* Copyright 2015 CANAL+ Group
*
* 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 agreed t... | /**
* Copyright 2015 CANAL+ Group
*
* 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 agreed t... | Support UTCTiming element with the http-xsdate scheme | Support UTCTiming element with the http-xsdate scheme
While both doing the inventory of what MPD attributes handle the RxPlayer
and working on low-latency contents, I noted that the RxPlayer did not
support `UTCTiming` element with the
`urn:mpeg:dash:utc:http-xsdate:2014`.
Yet it is very simple to implement - at leas... | TypeScript | apache-2.0 | canalplus/rx-player,canalplus/rx-player,canalplus/rx-player,canalplus/rx-player,canalplus/rx-player | ---
+++
@@ -16,6 +16,16 @@
import { IMPDIntermediateRepresentation } from "../node_parser_types";
+type ISupportedHttpUtcTimingScheme =
+ {
+ schemeIdUri : "urn:mpeg:dash:utc:http-iso:2014";
+ value : string;
+ } |
+ {
+ schemeIdUri : "urn:mpeg:dash:utc:http-xsdate:2014";
+ value : string;
+ };
+... |
28f195fc5db3c0ba77c2dea6e6d61d53c59e94c4 | types/fastify-static/index.d.ts | types/fastify-static/index.d.ts | // Type definitions for fastify-static 0.14
// Project: https://github.com/fastify/fastify-static
// Definitions by: Leonhard Melzer <https://github.com/leomelzer>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 2.4
import { Server, IncomingMessage, ServerResponse } from "http... | // Type definitions for fastify-static 0.14
// Project: https://github.com/fastify/fastify-static
// Definitions by: Leonhard Melzer <https://github.com/leomelzer>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 2.4
import fastify = require("fastify");
import { Server, Incomi... | Change import * to require to align with tests | fix: Change import * to require to align with tests
| TypeScript | mit | AgentME/DefinitelyTyped,georgemarshall/DefinitelyTyped,markogresak/DefinitelyTyped,magny/DefinitelyTyped,georgemarshall/DefinitelyTyped,dsebastien/DefinitelyTyped,magny/DefinitelyTyped,AgentME/DefinitelyTyped,AgentME/DefinitelyTyped,georgemarshall/DefinitelyTyped,mcliment/DefinitelyTyped,georgemarshall/DefinitelyTyped,... | ---
+++
@@ -4,8 +4,9 @@
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 2.4
+import fastify = require("fastify");
+
import { Server, IncomingMessage, ServerResponse } from "http";
-import * as fastify from "fastify";
declare module "fastify" {
interface FastifyRe... |
f4f99e96d7b57c431c7538d31b04c2b358128815 | app/src/lib/stores/helpers/onboarding-tutorial.ts | app/src/lib/stores/helpers/onboarding-tutorial.ts | export class OnboardingTutorial {
public constructor() {
this.skipInstallEditor = false
this.skipCreatePR = false
}
getCurrentStep() {
// call all other methods to check where we're at
}
isEditorInstalled() {
if (this.skipInstallEditor) {
return true
}
return false
}
isBra... | export class OnboardingTutorial {
public constructor() {
this.skipInstallEditor = false
this.skipCreatePR = false
}
public getCurrentStep() {
// call all other methods to check where we're at
}
if (this.skipInstallEditor) {
private async isEditorInstalled(): Promise<boolean> {
return t... | Add accessibility modifier and return type | Add accessibility modifier and return type
| TypeScript | mit | j-f1/forked-desktop,desktop/desktop,kactus-io/kactus,say25/desktop,shiftkey/desktop,j-f1/forked-desktop,artivilla/desktop,say25/desktop,desktop/desktop,artivilla/desktop,desktop/desktop,shiftkey/desktop,shiftkey/desktop,kactus-io/kactus,desktop/desktop,artivilla/desktop,artivilla/desktop,kactus-io/kactus,j-f1/forked-de... | ---
+++
@@ -4,45 +4,45 @@
this.skipCreatePR = false
}
- getCurrentStep() {
+ public getCurrentStep() {
// call all other methods to check where we're at
}
- isEditorInstalled() {
if (this.skipInstallEditor) {
+ private async isEditorInstalled(): Promise<boolean> {
return true
... |
a0f07caff4e9647d9aeef9dbd85eab4e2ece8523 | angular/src/app/file/file-list.component.ts | angular/src/app/file/file-list.component.ts | import { Component, OnInit } from '@angular/core';
import { IFile } from './file';
import { ITag } from '../tag/tag';
import { FileService } from './file.service';
import { TagService } from '../tag/tag.service';
@Component({
template: `
<div class="row">
<div class="col-sm-3" *ngFor="let file of files">
... | import { AfterViewInit, Component, ElementRef, OnInit, ViewChild } from '@angular/core';
import { fromEvent } from 'rxjs/observable/fromEvent';
import { Observable } from 'rxjs/Rx';
import { IFile } from './file';
import { ITag } from '../tag/tag';
import { FileService } from './file.service';
import { TagService } f... | Add search on filename and tags | Add search on filename and tags
| TypeScript | mit | waxe/waxe-image,waxe/waxe-image,waxe/waxe-image,waxe/waxe-image,waxe/waxe-image | ---
+++
@@ -1,4 +1,7 @@
-import { Component, OnInit } from '@angular/core';
+import { AfterViewInit, Component, ElementRef, OnInit, ViewChild } from '@angular/core';
+
+import { fromEvent } from 'rxjs/observable/fromEvent';
+import { Observable } from 'rxjs/Rx';
import { IFile } from './file';
import { ITag } fro... |
30a4fa06756c3065884c8e0243f4f74cd7477668 | jovo-integrations/jovo-plugin-pulselabs/src/PulseLabs.ts | jovo-integrations/jovo-plugin-pulselabs/src/PulseLabs.ts | import { BaseApp, HandleRequest, Plugin, PluginConfig } from 'jovo-core';
import _merge = require('lodash.merge');
import PulseLabsRecorder = require('pulselabs-recorder');
import { InitOptions } from 'pulselabs-recorder/dist/interfaces/init-options.interface'; // tslint:disable-line
export interface Config extends P... | import { BaseApp, HandleRequest, Plugin, PluginConfig } from 'jovo-core';
import _merge = require('lodash.merge');
import PulseLabsRecorder = require('pulselabs-recorder');
import { InitOptions } from 'pulselabs-recorder/dist/interfaces/init-options.interface'; // tslint:disable-line
export interface Config extends P... | Change a check that caused Typescript errors | :recycle: Change a check that caused Typescript errors | TypeScript | apache-2.0 | jovotech/jovo-framework-nodejs,jovotech/jovo-framework-nodejs | ---
+++
@@ -32,9 +32,9 @@
}
async logData(handleRequest: HandleRequest) {
- if (handleRequest.jovo!.$alexaSkill) {
+ if (handleRequest.jovo.constructor.name === 'AlexaSkill') {
await this.pulse.logData(handleRequest.jovo!.$request, handleRequest.jovo!.$response);
- } else if (handleRequest.jov... |
baaa4e05e239ce710fd2492373d8dad3851a601f | test/src/test-utils.ts | test/src/test-utils.ts | import * as path from 'path';
import * as fs from 'fs';
export const rootPath = path.resolve(__dirname, '../../');
export const testRootPath = path.resolve(rootPath, 'test');
export const stagingPath = path.resolve(testRootPath, '.test');
export const testDir = path.resolve(testRootPath, 'tests');
export const testScr... | import * as path from 'path';
import * as fs from 'fs';
export const rootPath = path.resolve(__dirname, '../../');
export const testRootPath = path.resolve(rootPath, 'test');
export const stagingPath = path.resolve(testRootPath, '.test');
export const testDir = path.resolve(testRootPath, 'tests');
export const testScr... | Use fs.existsSync instead of fs.accessSync, which does not work in node prior to version 6 | Use fs.existsSync instead of fs.accessSync, which does not work in node prior to version 6
| TypeScript | mit | MortenHoustonLudvigsen/ts-css-loader,MortenHoustonLudvigsen/ts-css-loader | ---
+++
@@ -23,8 +23,7 @@
export function pathExists(path: string): boolean {
try {
- fs.accessSync(path, fs.constants.F_OK);
- return true;
+ return fs.existsSync(path);
} catch (e) {
return false;
} |
be0c9ac5b18f46c860a8d2b439dc7f92d2cf70d9 | src/util/logger.ts | src/util/logger.ts | import 'colors';
type LogColor = 'red' | 'green' | 'yellow' | 'blue' | 'magenta' | 'cyan' | 'gray';
export class Logger {
private static colors: LogColor[] = Logger.getAvailableColors();
private color: LogColor;
private label: string;
private nsp?: Logger;
private get prefix(): string {
return `${this... | import 'colors';
type LogColor = 'red' | 'green' | 'yellow' | 'blue' | 'magenta' | 'cyan' | 'gray';
export class Logger {
private static Options = {
ENV: process.env.NODE_ENV || 'production'
};
private static colors: LogColor[] = Logger.getAvailableColors();
private color: LogColor;
private label: str... | Disable console logging when NODE_ENV is set to production | Disable console logging when NODE_ENV is set to production
| TypeScript | mit | ibrahimduran/node-kaptan | ---
+++
@@ -3,6 +3,10 @@
type LogColor = 'red' | 'green' | 'yellow' | 'blue' | 'magenta' | 'cyan' | 'gray';
export class Logger {
+ private static Options = {
+ ENV: process.env.NODE_ENV || 'production'
+ };
+
private static colors: LogColor[] = Logger.getAvailableColors();
private color: LogColor;
@... |
c6d35356fb1c74849b9522bd2be307963dab8457 | src/app/shared/menu/date/date-range-summary.component.ts | src/app/shared/menu/date/date-range-summary.component.ts | import { Component, Input } from '@angular/core';
import { RouterModel, INTERVAL_DAILY } from '../../../ngrx';
import * as dateUtil from '../../util/date';
@Component({
selector: 'metrics-date-range-summary',
template: `
<div class="label">in this range</div>
<div class="range">{{beginDate}} - {{endDate}} ... | import { Component, Input } from '@angular/core';
import { RouterModel, INTERVAL_DAILY } from '../../../ngrx';
import * as dateUtil from '../../util/date';
@Component({
selector: 'metrics-date-range-summary',
template: `
<div class="label">in this range</div>
<div class="range">{{beginDate}} ― {{end... | Use horizontal bar as range separator | Use horizontal bar as range separator
| TypeScript | agpl-3.0 | PRX/metrics.prx.org,PRX/metrics.prx.org,PRX/metrics.prx.org,PRX/metrics.prx.org | ---
+++
@@ -6,7 +6,7 @@
selector: 'metrics-date-range-summary',
template: `
<div class="label">in this range</div>
- <div class="range">{{beginDate}} - {{endDate}} <span>({{numDays}})</span></div>
+ <div class="range">{{beginDate}} ― {{endDate}} <span>({{numDays}})</span></div>
`,
styleU... |
0cbfa132d55575d975fea3756d48081bec70966c | web/src/lib/components/icon.tsx | web/src/lib/components/icon.tsx | import { h, Component } from 'preact';
interface FontIcons {
[key: string]: string;
bullhorn: string;
hamburger: string;
redo: string;
play: string;
pause: string;
undo: string;
check: string;
x: string;
github: string;
firefox: string;
chrome: string;
help: string;
discourse: string;
}
co... | import { h, Component } from 'preact';
interface FontIcons {
[key: string]: string;
bullhorn: string;
hamburger: string;
redo: string;
play: string;
pause: string;
undo: string;
check: string;
x: string;
github: string;
firefox: string;
chrome: string;
help: string;
discourse: string;
}
co... | Change the back arrow to a unicode one | Change the back arrow to a unicode one
| TypeScript | mpl-2.0 | kenrick95/voice-web,gozer/voice-web,kenrick95/voice-web,common-voice/common-voice,kenrick95/voice-web,gozer/voice-web,gozer/voice-web,common-voice/common-voice,gozer/voice-web,common-voice/common-voice,gozer/voice-web,kenrick95/voice-web,kenrick95/voice-web,gozer/voice-web,common-voice/common-voice,gozer/voice-web,kenr... | ---
+++
@@ -23,7 +23,7 @@
redo: '',
play: '',
pause: '',
- undo: '',
+ undo: '←',
check: '',
x: '',
github: '', |
94b28b62489965068555c660a48303c7ac3c7f3e | launchpod/angular-launchpod/src/app/app-routing.module.ts | launchpod/angular-launchpod/src/app/app-routing.module.ts | import { NgModule } from '@angular/core';
import { Routes, RouterModule } from '@angular/router';
import { AppComponent } from './app.component';
import { CreateFormComponent } from './create-form/create-form.component';
import { Mp3FormComponent } from './mp3-form/mp3-form.component';
import { TranscribeFormComponent ... | import { NgModule } from '@angular/core';
import { Routes, RouterModule } from '@angular/router';
import { AppComponent } from './app.component';
import { CreateFormComponent } from './create-form/create-form.component';
import { EpisodeLinkFormComponent } from './episode-link-form/episode-link-form.component';
import ... | Fix import issue in front end | Fix import issue in front end
| TypeScript | apache-2.0 | googleinterns/step18-2020,googleinterns/step18-2020,googleinterns/step18-2020,googleinterns/step18-2020,googleinterns/step18-2020 | ---
+++
@@ -2,6 +2,8 @@
import { Routes, RouterModule } from '@angular/router';
import { AppComponent } from './app.component';
import { CreateFormComponent } from './create-form/create-form.component';
+import { EpisodeLinkFormComponent } from './episode-link-form/episode-link-form.component';
+import { EpisodeUp... |
635c9df70eb2ba3f7e936dfce4c8a1a35d25b14c | src/app/shared/services/settings.service.ts | src/app/shared/services/settings.service.ts | import { BehaviorSubject } from "rxjs/BehaviorSubject";
import { Injectable } from "@angular/core";
export enum SessionListMode {
CLICK_TO_OPEN_HOVER_TO_PREVIEW = "Click to open, hover to preview",
CLICK_TO_OPEN_BUTTON_TO_PREVIEW = "Click to open, button to preview",
CLICK_TO_PREVIEW_BUTTON_TO_OPEN = "Click to p... | import { Injectable } from "@angular/core";
import { BehaviorSubject } from "rxjs/BehaviorSubject";
export enum SessionListMode {
CLICK_TO_OPEN_HOVER_TO_PREVIEW = "Click to open, hover to preview",
CLICK_TO_OPEN_BUTTON_TO_PREVIEW = "Click to open, button to preview",
CLICK_TO_PREVIEW_BUTTON_TO_OPEN = "Click to p... | Change session list default mode | Change session list default mode
| TypeScript | mit | chipster/chipster-web,chipster/chipster-web,chipster/chipster-web | ---
+++
@@ -1,5 +1,5 @@
+import { Injectable } from "@angular/core";
import { BehaviorSubject } from "rxjs/BehaviorSubject";
-import { Injectable } from "@angular/core";
export enum SessionListMode {
CLICK_TO_OPEN_HOVER_TO_PREVIEW = "Click to open, hover to preview",
@@ -23,7 +23,9 @@
public sessionListMo... |
7fffcc3b634aed0b1c42658c0a7d20917edc0e80 | src/devices/components/last_seen_widget.tsx | src/devices/components/last_seen_widget.tsx | import * as React from "react";
import { Row, Col } from "../../ui/index";
import { t } from "i18next";
import * as moment from "moment";
import { TaggedDevice } from "../../resources/tagged_resources";
interface LastSeenProps {
onClick?(): void;
device: TaggedDevice;
}
export class LastSeen extends React.Compone... | import * as React from "react";
import { Row, Col } from "../../ui/index";
import { t } from "i18next";
import * as moment from "moment";
import { TaggedDevice } from "../../resources/tagged_resources";
interface LastSeenProps {
onClick?(): void;
device: TaggedDevice;
}
export class LastSeen extends React.Compone... | Make the font look like the other fonts | Make the font look like the other fonts
| TypeScript | mit | MrChristofferson/Farmbot-Web-API,FarmBot/Farmbot-Web-API,FarmBot/farmbot-web-app,FarmBot/farmbot-web-app,FarmBot/Farmbot-Web-API,RickCarlino/farmbot-web-app,gabrielburnworth/Farmbot-Web-App,RickCarlino/farmbot-web-app,RickCarlino/farmbot-web-app,gabrielburnworth/Farmbot-Web-App,FarmBot/Farmbot-Web-API,FarmBot/farmbot-w... | ---
+++
@@ -36,9 +36,9 @@
</label>
</Col>
<Col xs={7}>
- <i className="fa fa-refresh" onClick={this.props.onClick}>
- {this.show()}
- </i>
+ <p>
+ <i className="fa fa-refresh" onClick={this.props.onClick}></i>{this.show()}
+ </p>
</Col>
... |
8116543f910e2f4e45b5ddc85a3ea4a2ec387037 | src/create-action.ts | src/create-action.ts | import {Action, Stream, Subscriber, Unsubscribe} from '../index'
export function Action<T>(): Action<T> {
let sink: Subscriber<T> = null
const action = ((value: T): void => {
if (sink) {
sink(value)
}
}) as Action<T>
action.stream = (subscriber: Subscriber<T>): Unsubscribe => {
if (sink) {
... | import {Action, Stream, Subscriber, Unsubscribe} from '../index'
export function Action<T>(): Action<T> {
let sink: Subscriber<T> = null
const action = ((value: T): void => {
if (sink) {
sink(value)
}
}) as Action<T>
action.stream = (subscriber: Subscriber<T>, end: Unsubscribe): Unsubscribe => ... | Add end fn to Actions | Add end fn to Actions
| TypeScript | mit | juhohei/slope | ---
+++
@@ -9,13 +9,14 @@
}
}) as Action<T>
- action.stream = (subscriber: Subscriber<T>): Unsubscribe => {
+ action.stream = (subscriber: Subscriber<T>, end: Unsubscribe): Unsubscribe => {
if (sink) {
throw new Error('This stream has already been subscribed to. Use `fork` to allow more subscr... |
484835eb2cccd351d8332e7f4a4afddcfab97814 | src/gitignore.ts | src/gitignore.ts | /**
* @license
* Copyright (c) 2018 The Polymer Project Authors. All rights reserved.
* This code may only be used under the BSD style license found at
* http://polymer.github.io/LICENSE.txt
* The complete set of authors may be found at
* http://polymer.github.io/AUTHORS.txt
* The complete set of contributors ma... | /**
* @license
* Copyright (c) 2018 The Polymer Project Authors. All rights reserved.
* This code may only be used under the BSD style license found at
* http://polymer.github.io/LICENSE.txt
* The complete set of authors may be found at
* http://polymer.github.io/AUTHORS.txt
* The complete set of contributors ma... | Make sure to match node_modules lines with a leading slash | Make sure to match node_modules lines with a leading slash
| TypeScript | bsd-3-clause | Polymer/tools,Polymer/tools,Polymer/tools,Polymer/tools | ---
+++
@@ -16,7 +16,7 @@
import {EOL} from 'os';
const nodeModulesLine = 'node_modules';
-const searchNodeModulesLine = new RegExp(`^${nodeModulesLine}`);
+const searchNodeModulesLine = new RegExp(`^/?${nodeModulesLine}`);
export async function ignoreNodeModules(ignoreFile: string) {
let ignoreLines: strin... |
dfee963c6198de4e05374eb04f91548b5c848965 | src/components/categoryForm/categoryForm.component.ts | src/components/categoryForm/categoryForm.component.ts | import { Component, ViewEncapsulation } from '@angular/core';
@Component({
templateUrl: './categoryForm.component.html',
styleUrls: ['./categoryForm.component.scss'],
encapsulation: ViewEncapsulation.None
})
export class CategoryFormComponent {
subjects: { value: string, viewValue: string }[] = [
{value: '... | import { Component, ViewEncapsulation } from '@angular/core';
@Component({
templateUrl: './categoryForm.component.html',
styleUrls: ['./categoryForm.component.scss'],
encapsulation: ViewEncapsulation.None
})
export class CategoryFormComponent {
subjects: { value: string, viewValue: string }[] = [
{value: '... | Create object with form data | Create object with form data
| TypeScript | mit | ivanna-ostrovets/language-and-literature-admin,ivanna-ostrovets/language-and-literature-admin,ivanna-ostrovets/language-and-literature-admin | ---
+++
@@ -14,7 +14,16 @@
subject: string;
category: string;
- onSubmit() {
+ onSubmit(): {} {
+ if (this.subject != undefined) {
+ return {
+ subject: this.subject,
+ category: this.category
+ };
+ }
+ return {
+ subject: this.category
+ };
}
} |
15297c47b112d7ffd2c62c1153a811f82118c297 | ui/src/DocumentTeaser.tsx | ui/src/DocumentTeaser.tsx | import React, { CSSProperties } from 'react';
import { Card, Container, Row, Col } from 'react-bootstrap';
import { Link } from 'react-router-dom';
import CategoryIcon from './CategoryIcon';
export default ({ document }) => {
return (
<Link to={ `/documents/${document.resource.id}` } style={ linkStyle }>
... | import React, { CSSProperties } from 'react';
import { Card, Container, Row, Col } from 'react-bootstrap';
import { Link } from 'react-router-dom';
import CategoryIcon from './CategoryIcon';
export default ({ document }) => {
return (
<Link to={ `/documents/${document.resource.id}` } style={ linkStyle }>
... | Fix margins in document teaser | Fix margins in document teaser
| TypeScript | apache-2.0 | dainst/idai-field-web,dainst/idai-field-web,dainst/idai-field-web | ---
+++
@@ -9,7 +9,6 @@
<Link to={ `/documents/${document.resource.id}` } style={ linkStyle }>
<Card>
<Card.Body>
- <Container>
<Row>
<Col style={ { flex: '0 0 50px' } }>
<C... |
dddfa946969e31a4582401afe2eeb4444605ea2f | packages/core/src/core/http/contexts.ts | packages/core/src/core/http/contexts.ts | export class Context<User = any> {
state: { [key: string]: any } = {};
user: User;
constructor(public request) {}
}
| import { Request } from 'express';
interface HTTPRequest extends Request {
session: any;
csrfToken: () => string;
}
export class Context<User = any> {
state: { [key: string]: any } = {};
user: User;
request: HTTPRequest;
constructor(request) {
this.request = request;
}
}
| Add `Request` type to Context. | Add `Request` type to Context.
| TypeScript | mit | FoalTS/foal,FoalTS/foal,FoalTS/foal,FoalTS/foal | ---
+++
@@ -1,6 +1,16 @@
+import { Request } from 'express';
+
+interface HTTPRequest extends Request {
+ session: any;
+ csrfToken: () => string;
+}
+
export class Context<User = any> {
state: { [key: string]: any } = {};
user: User;
+ request: HTTPRequest;
- constructor(public request) {}
+ constructo... |
2582f6df238f0f64524027ccad84b0f951778686 | test/components/views/settings/FontScalingPanel-test.tsx | test/components/views/settings/FontScalingPanel-test.tsx | /*
Copyright 2021 The Matrix.org Foundation C.I.C.
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 agreed to in ... | /*
Copyright 2021 The Matrix.org Foundation C.I.C.
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 agreed to in ... | Replace manual mock with jest.mock | Replace manual mock with jest.mock
| TypeScript | apache-2.0 | matrix-org/matrix-react-sdk,matrix-org/matrix-react-sdk,matrix-org/matrix-react-sdk,matrix-org/matrix-react-sdk,matrix-org/matrix-react-sdk,matrix-org/matrix-react-sdk | ---
+++
@@ -23,9 +23,15 @@
const FontScalingPanel = TestUtils.wrapInMatrixClientContext(_FontScalingPanel);
-import * as randomstring from "matrix-js-sdk/src/randomstring";
-// @ts-expect-error: override random function to make results predictable
-randomstring.randomString = () => "abdefghi";
+// Fake random st... |
da5abf1829dd19272208fea2066354c70c297711 | server/src/linters/Standard.ts | server/src/linters/Standard.ts | import { Diagnostic } from 'vscode-languageserver';
import RuboCop, { IRuboCopResults } from './RuboCop';
export default class Standard extends RuboCop {
get cmd(): string {
if (this.lintConfig.command) {
return this.lintConfig.command;
} else {
const command = 'standard';
return this.isWindows() ? comma... | import { Diagnostic } from 'vscode-languageserver';
import RuboCop, { IRuboCopResults } from './RuboCop';
export default class Standard extends RuboCop {
get cmd(): string {
if (this.lintConfig.command) {
return this.lintConfig.command;
} else {
const command = 'standardrb';
return this.isWindows() ? com... | Update standard linter to use the standardrb command | Update standard linter to use the standardrb command
| TypeScript | mit | rubyide/vscode-ruby,rubyide/vscode-ruby,rubyide/vscode-ruby,rubyide/vscode-ruby,rubyide/vscode-ruby | ---
+++
@@ -6,7 +6,7 @@
if (this.lintConfig.command) {
return this.lintConfig.command;
} else {
- const command = 'standard';
+ const command = 'standardrb';
return this.isWindows() ? command + '.bat' : command;
}
} |
88ac3867e4c39bfbe911280a2f73d86c74f3c4d1 | client/LauncherViewModel.ts | client/LauncherViewModel.ts | import * as ko from "knockout";
import { env } from "./Environment";
import { Metrics } from "./Utility/Metrics";
import { Store } from "./Utility/Store";
export class LauncherViewModel {
constructor() {
const pageLoadData = {
referrer: document.referrer,
userAgent: navigator.userA... | import * as ko from "knockout";
import { env } from "./Environment";
import { Metrics } from "./Utility/Metrics";
import { Store } from "./Utility/Store";
export class LauncherViewModel {
constructor() {
const pageLoadData = {
referrer: document.referrer,
userAgent: navigator.userA... | Add stub call to transferLocalStorageToCanonicalUrl | Add stub call to transferLocalStorageToCanonicalUrl
| TypeScript | mit | cynicaloptimist/improved-initiative,cynicaloptimist/improved-initiative,cynicaloptimist/improved-initiative | ---
+++
@@ -11,10 +11,16 @@
userAgent: navigator.userAgent
};
Metrics.TrackEvent("LandingPageLoad", pageLoadData);
- const firstVisit = Store.Load(Store.User, "SkipIntro") === null;
- if (firstVisit && env.CanonicalURL.length > 0 && window.location.href != env.CanonicalURL... |
9d38a12f8a71c8f97aa2b2b91065282a5ed75727 | spec/helpers/InMemoryPlugin.ts | spec/helpers/InMemoryPlugin.ts | import { SyncPlugin } from '../../src/plugin';
export class InMemoryPlugin extends SyncPlugin {
public messages: any[] = [];
public process(message: any): Promise<any> {
this.messages.push(message);
return Promise.resolve(message);
}
} | import { SyncPlugin } from '../../src/plugin';
export class InMemoryPlugin extends SyncPlugin {
public messages: any[] = [];
public process(message: any): any {
this.messages.push(message);
return message;
}
} | Correct faulty plugin in tests | [fix] Correct faulty plugin in tests
| TypeScript | mit | Quantumplation/capillary-logger,Quantumplation/capillary-logger,Quantumplation/capillary-logger | ---
+++
@@ -2,8 +2,8 @@
export class InMemoryPlugin extends SyncPlugin {
public messages: any[] = [];
- public process(message: any): Promise<any> {
+ public process(message: any): any {
this.messages.push(message);
- return Promise.resolve(message);
+ return message;
}
} |
d6a3cc661cbc3478910a9e036c9d2a14edf896ba | src/lib/JavaScriptFormatter.ts | src/lib/JavaScriptFormatter.ts | import { ILanguageSpecificFormatter } from "./ILanguageSpecificFormatter";
import * as prettier from "prettier";
import * as highlight from "highlight.js";
export class JavaScriptFormatter implements ILanguageSpecificFormatter {
public readonly cssSelectorItems: string[] = [
"div.language-javascript > pre > code... | import { ILanguageSpecificFormatter } from "./ILanguageSpecificFormatter";
import * as prettier from "prettier";
import * as highlight from "highlight.js";
export class JavaScriptFormatter implements ILanguageSpecificFormatter {
public readonly cssSelectorItems: string[] = [
"div.language-javascript > pre > code... | Add selector from Node docs | Add selector from Node docs
| TypeScript | apache-2.0 | luhring/opinionator,luhring/opinionator | ---
+++
@@ -7,7 +7,8 @@
"div.language-javascript > pre > code",
"div.highlight-source-js > pre",
"pre > code.javascript",
- "pre.javascript > code"
+ "pre.javascript > code",
+ "pre > code.lang-js"
];
public readonly languageName: string = "JavaScript"; |
ab03f2109537eb1aecaca59a9a75666ce8aa75a1 | src/testing/index.ts | src/testing/index.ts | import { ComponentFixture } from '@angular/core/testing';
import { By } from '@angular/platform-browser';
export function selectElement<T> (fixture: ComponentFixture<T>, locator: string) {
return fixture.debugElement.query(By.css(locator)).nativeElement;
}
| import { ComponentFixture } from '@angular/core/testing';
import { By } from '@angular/platform-browser';
export function selectElement<T> (fixture: ComponentFixture<T>, locator: string) {
return fixture.debugElement.query(By.css(locator)).nativeElement;
}
export function selectElements<T> (fixture: ComponentFixtur... | Add unit test method to select multiple elements | Add unit test method to select multiple elements
| TypeScript | bsd-3-clause | cumulous/web,cumulous/web,cumulous/web,cumulous/web | ---
+++
@@ -4,3 +4,8 @@
export function selectElement<T> (fixture: ComponentFixture<T>, locator: string) {
return fixture.debugElement.query(By.css(locator)).nativeElement;
}
+
+export function selectElements<T> (fixture: ComponentFixture<T>, locator: string) {
+ return fixture.debugElement.queryAll(By.css(loca... |
2ec4a92b4023230618b083cfa041194e1ec8e6ca | polygerrit-ui/app/elements/checks/gr-hovercard-run_test.ts | polygerrit-ui/app/elements/checks/gr-hovercard-run_test.ts | /**
* @license
* Copyright 2021 Google LLC
* SPDX-License-Identifier: Apache-2.0
*/
import '../../test/common-test-setup-karma';
import './gr-hovercard-run';
import {fixture, html} from '@open-wc/testing-helpers';
import {GrHovercardRun} from './gr-hovercard-run';
suite('gr-hovercard-run tests', () => {
let elem... | /**
* @license
* Copyright 2021 Google LLC
* SPDX-License-Identifier: Apache-2.0
*/
import '../../test/common-test-setup-karma';
import './gr-hovercard-run';
import {fixture, html} from '@open-wc/testing-helpers';
import {GrHovercardRun} from './gr-hovercard-run';
import {fakeRun0} from '../../models/checks/checks-... | Add ShadowDOM tests for elements/checks components | Add ShadowDOM tests for elements/checks components
Release-Notes: skip
Google-Bug-Id: b/238288621
Change-Id: Ic80137c06635b47dd6af1fad167b4add0d66918f
| TypeScript | apache-2.0 | GerritCodeReview/gerrit,GerritCodeReview/gerrit,GerritCodeReview/gerrit,GerritCodeReview/gerrit,GerritCodeReview/gerrit,GerritCodeReview/gerrit,GerritCodeReview/gerrit,GerritCodeReview/gerrit | ---
+++
@@ -7,22 +7,49 @@
import './gr-hovercard-run';
import {fixture, html} from '@open-wc/testing-helpers';
import {GrHovercardRun} from './gr-hovercard-run';
+import {fakeRun0} from '../../models/checks/checks-fakes';
suite('gr-hovercard-run tests', () => {
let element: GrHovercardRun;
setup(async (... |
fde22ada4105d7ea802df48750256df6e1c7d298 | A2/quickstart/src/app/components/app-custom/app.custom.component.ts | A2/quickstart/src/app/components/app-custom/app.custom.component.ts | import { Component } from "@angular/core";
import { RacePart } from "../../models/race-part.model";
import { RACE_PARTS } from "../../models/mocks";
@Component({
selector: "my-app-custom-component",
templateUrl: "./app/components/app-custom/app.custom.component.html",
styleUrls: [ "./app/components/app-custom/ap... | import { Component } from "@angular/core";
import { RacePart } from "../../models/race-part.model";
import { RACE_PARTS } from "../../models/mocks";
@Component({
selector: "my-app-custom-component",
templateUrl: "./app/components/app-custom/app.custom.component.html",
styleUrls: [ "./app/components/app-custom/ap... | Add methods: upQuantity, downQuantity, cancelRace, enterRace | Add methods: upQuantity, downQuantity, cancelRace, enterRace
| TypeScript | mit | var-bin/angularjs-training,var-bin/angularjs-training,var-bin/angularjs-training,var-bin/angularjs-training | ---
+++
@@ -31,9 +31,37 @@
}
return sum;
- }
+ };
cashLeft() {
return this.cash - this.totalCost();
- }
+ };
+
+ upQuantity(race) {
+ if (race.inStock > race.quantity) {
+ return race.quantity++;
+ }
+
+ return false;
+ };
+
+ downQuantity(race) {
+ if (race.quantity > 0)... |
81416c1cc58f950414528c2f0ded4efe4625d476 | app/src/lib/fix-emoji-spacing.ts | app/src/lib/fix-emoji-spacing.ts | // This module renders an element with an emoji using
// a non system-default font to workaround an Chrome
// issue that causes unexpected spacing on emojis.
// More info:
// https://bugs.chromium.org/p/chromium/issues/detail?id=1113293
const container = document.createElement('div')
container.style.setProperty('visib... | // This module renders an element with an emoji using
// a non system-default font to workaround an Chrome
// issue that causes unexpected spacing on emojis.
// More info:
// https://bugs.chromium.org/p/chromium/issues/detail?id=1113293
const container = document.createElement('div')
container.style.setProperty('visib... | Call toString() to be able to remove eslint-disable rule | Call toString() to be able to remove eslint-disable rule
Co-authored-by: Markus Olsson <fea8a6992108b6bfda0c59222a1afb2da2ede904@gmail.com> | TypeScript | mit | shiftkey/desktop,say25/desktop,desktop/desktop,artivilla/desktop,kactus-io/kactus,kactus-io/kactus,j-f1/forked-desktop,desktop/desktop,shiftkey/desktop,kactus-io/kactus,j-f1/forked-desktop,say25/desktop,j-f1/forked-desktop,artivilla/desktop,say25/desktop,j-f1/forked-desktop,kactus-io/kactus,say25/desktop,shiftkey/deskt... | ---
+++
@@ -31,8 +31,7 @@
document.body.appendChild(container)
// Read the dimensions of the element to force the browser to do a layout.
-// eslint-disable-next-line @typescript-eslint/no-unused-expressions
-container.offsetHeight
+container.offsetHeight.toString()
// Browser has rendered the emojis, now we c... |
c188e65391e297b92bb73a6a7fd4027a08eb6576 | test/runTest.ts | test/runTest.ts | import * as path from 'path'
import * as process from 'process'
import * as glob from 'glob'
import * as tmpFile from 'tmp'
import { runTests } from 'vscode-test'
async function main() {
try {
const extensionDevelopmentPath = path.resolve(__dirname, '../../')
const extensionTestsPath = path.resolve... | import * as path from 'path'
import * as process from 'process'
import * as glob from 'glob'
import * as tmpFile from 'tmp'
import { runTests } from 'vscode-test'
async function main() {
try {
const extensionDevelopmentPath = path.resolve(__dirname, '../../')
const extensionTestsPath = path.resolve... | Use VS Code 1.42.1 since VS Code 1.43 is not stable for tests. | Use VS Code 1.42.1 since VS Code 1.43 is not stable for tests.
| TypeScript | mit | James-Yu/LaTeX-Workshop,James-Yu/LaTeX-Workshop,James-Yu/LaTeX-Workshop,James-Yu/LaTeX-Workshop,James-Yu/LaTeX-Workshop | ---
+++
@@ -23,6 +23,7 @@
for (const testWorkspace of testBuildWorkspaces) {
await runTests({
+ version: '1.42.1',
extensionDevelopmentPath,
extensionTestsPath,
launchArgs: [ |
8297607d110e0583bffbfc656c39f23423411299 | packages/components/containers/topBanners/WelcomeV5TopBanner.tsx | packages/components/containers/topBanners/WelcomeV5TopBanner.tsx | import React from 'react';
import { c } from 'ttag';
import { getStaticURL } from '@proton/shared/lib/helpers/url';
import TopBanner from './TopBanner';
import { Href } from '../../components';
const WelcomeV5TopBanner = () => {
const learnMoreLink = (
<Href key="learn-more-link" url={getStaticURL('/news/... | import React from 'react';
import { c } from 'ttag';
import { getStaticURL } from '@proton/shared/lib/helpers/url';
import TopBanner from './TopBanner';
import { Href } from '../../components';
const WelcomeV5TopBanner = () => {
const learnMoreLink = (
<Href key="learn-more-link" url={getStaticURL('/news/... | Add new plans context to welcome banner | Add new plans context to welcome banner
| TypeScript | mit | ProtonMail/WebClient,ProtonMail/WebClient,ProtonMail/WebClient | ---
+++
@@ -7,7 +7,8 @@
const WelcomeV5TopBanner = () => {
const learnMoreLink = (
- <Href key="learn-more-link" url={getStaticURL('/news/updated-proton')}>{c('Link').t`learn more`}</Href>
+ <Href key="learn-more-link" url={getStaticURL('/news/updated-proton')}>{c('new_plans: info')
+ ... |
84a131c2374f56b24f8f4484a06f6655b768058d | packages/@sanity/base/src/components/icons/Undo.tsx | packages/@sanity/base/src/components/icons/Undo.tsx | // part:@sanity/base/undo-icon
import React from 'react'
const strokeStyle = {
stroke: 'currentColor',
strokeWidth: 1.2
}
const UndoIcon = () => (
<svg
data-sanity-icon
viewBox="0 0 25 25"
fill="none"
xmlns="http://www.w3.org/2000/svg"
preserveAspectRatio="xMidYMid"
width="1em"
heig... | // part:@sanity/base/undo-icon
import React from 'react'
const strokeStyle = {
stroke: 'currentColor',
strokeWidth: 1.2
}
const UndoIcon = (): React.ReactElement => (
<svg
data-sanity-icon
viewBox="0 0 25 25"
fill="none"
xmlns="http://www.w3.org/2000/svg"
preserveAspectRatio="xMidYMid"
... | Remove unused stroke attributes from undo icon | [base] Remove unused stroke attributes from undo icon
| TypeScript | mit | sanity-io/sanity,sanity-io/sanity,sanity-io/sanity,sanity-io/sanity | ---
+++
@@ -7,7 +7,7 @@
strokeWidth: 1.2
}
-const UndoIcon = () => (
+const UndoIcon = (): React.ReactElement => (
<svg
data-sanity-icon
viewBox="0 0 25 25"
@@ -18,9 +18,9 @@
height="1em"
>
<path
- d="M5 9L14.5 9C16.9853 9 19 11.0147 19 13.5V13.5C19 15.9853 16.9853 18 14.5 18L5 ... |
0e558bfc2e5bf94f77a1d81e24975006f88daac4 | lib/util/request.ts | lib/util/request.ts | import * as requestPromise from 'request-promise-native';
import { Config, Request, TaxjarError } from '../util/types';
const proxyError = (result): Promise<never> => {
throw new TaxjarError(
result.error.error,
result.error.detail,
result.statusCode,
);
};
export default (config: Config): Request => ... | import * as requestPromise from 'request-promise-native';
import { Config, Request, TaxjarError } from '../util/types';
const proxyError = (result): never => {
throw new TaxjarError(
result.error.error,
result.error.detail,
result.statusCode,
);
};
export default (config: Config): Request => {
const... | Fix return type for `proxyError` helper | Fix return type for `proxyError` helper
| TypeScript | mit | taxjar/taxjar-node,taxjar/taxjar-node | ---
+++
@@ -1,7 +1,7 @@
import * as requestPromise from 'request-promise-native';
import { Config, Request, TaxjarError } from '../util/types';
-const proxyError = (result): Promise<never> => {
+const proxyError = (result): never => {
throw new TaxjarError(
result.error.error,
result.error.detail, |
f96dcc771b0859a365717651bb807147c29396e0 | src/handlers/Start.ts | src/handlers/Start.ts | import {Frame, ResponseContext, ResponseModel} from "../definitions/Handler";
import {Context} from "../definitions/SkillContext";
import "./Start";
let Frames = require("../definitions/FrameDirectory");
let entry = (ctx: Context) => {
let model = new ResponseModel();
model.speech = "hello";
model.repr... | import {Frame, ResponseContext, ResponseModel} from "../definitions/Handler";
import {Attributes, RequestContext} from "../definitions/SkillContext";
import * as Frames from "../definitions/FrameDirectory";
let entry = (attr: Attributes, ctx: RequestContext) => {
let model = new ResponseModel();
model.speec... | Use import instead of require. Use attributes param. | Use import instead of require. Use attributes param.
| TypeScript | agpl-3.0 | deegles/cookietime,deegles/cookietime | ---
+++
@@ -1,23 +1,28 @@
import {Frame, ResponseContext, ResponseModel} from "../definitions/Handler";
-import {Context} from "../definitions/SkillContext";
-import "./Start";
+import {Attributes, RequestContext} from "../definitions/SkillContext";
+import * as Frames from "../definitions/FrameDirectory";
-let ... |
638fccc534a9611f5a9fd457c1ba4ecfed194e46 | src/utils/cli.ts | src/utils/cli.ts | import logUpdate = require('log-update')
import spinner = require('elegant-spinner')
import chalk = require('chalk')
import Promise = require('native-or-bluebird')
import promiseFinally from 'promise-finally'
export interface Options {
verbose: boolean
}
export function wrapExecution (promise: any, options?: Option... | import logUpdate = require('log-update')
import spinner = require('elegant-spinner')
import chalk = require('chalk')
import Promise = require('native-or-bluebird')
import promiseFinally from 'promise-finally'
export interface Options {
verbose: boolean
}
export function wrapExecution (promise: any, options?: Option... | Exit with non-zero code on error | Exit with non-zero code on error | TypeScript | mit | typings/typings,typings/typings | ---
+++
@@ -22,10 +22,12 @@
return promiseFinally(Promise.resolve(promise), end)
.catch((error: Error) => {
- console.log(chalk.red(error.message))
+ console.log(chalk.red(`${error.name}: ${error.message}`))
if (options.verbose && 'stack' in error) {
console.log((<any> error).sta... |
73404b1a68c01cb57cbb20806d081f6e94c82086 | src/tasks/UploadTask.ts | src/tasks/UploadTask.ts | import {SCRIPT_DIR, TEMPLATES_DIR} from "./Task";
import {DeployTask} from "./DeployTask";
import {Config} from "../config";
import {Session, SessionResult, executeScript, copy} from "../Session";
const fs = require('fs');
const path = require('path');
const util = require('util');
export class UploadTask extends De... | import {SCRIPT_DIR, TEMPLATES_DIR} from "./Task";
import {DeployTask} from "./DeployTask";
import {Config} from "../config";
import {Session, SessionResult, executeScript, copy} from "../Session";
const fs = require('fs');
const path = require('path');
const util = require('util');
export class UploadTask extends De... | Fix upload task (vars enables the ejs compilation) | Fix upload task (vars enables the ejs compilation)
| TypeScript | mit | c9s/typeloy,c9s/typeloy | ---
+++
@@ -30,9 +30,6 @@
public run(session : Session) : Promise<SessionResult> {
return copy(session,
this.srcPath,
- this.destPath, {
- 'progressBar': this.progress,
- 'vars': this.extendArgs({ })
- });
+ this.destPath, { 'progressBar': this.progress });
}
} |
746748e949a1063a3b86697467d1880784ff2861 | src/utils/formatting.ts | src/utils/formatting.ts | const currencyFormatter = new Intl.NumberFormat('en-US', {
style: 'currency',
currency: 'USD',
minimumFractionDigits: 2
});
export const formatAsUsd = currencyFormatter.format;
/**
* Trims leading and trailing whitespace and line terminators and replaces all
* characters after character 90 with an e... | const currencyFormatter = new Intl.NumberFormat('en-US', {
style: 'currency',
currency: 'USD',
minimumFractionDigits: 2
});
export const formatAsUsd = currencyFormatter.format;
/**
* Trims leading and trailing whitespace and line terminators and replaces all
* characters after character 90 with an e... | Add function to escape special characters in string for use in new RegExp. | Add function to escape special characters in string for use in new RegExp.
| TypeScript | mit | Anveio/mturk-engine,Anveio/mturk-engine,Anveio/mturk-engine | ---
+++
@@ -24,4 +24,7 @@
pluralForm = nonPluralForm + 's'
) => (groupSize = 2) => (groupSize === 1 ? nonPluralForm : pluralForm);
+export const escapeUserInputForRegex = (userInput: string) =>
+ userInput.replace(/[.*+?^${}()|[\]\\]/g, '\\$&');
+
export const pluralizeHits = pluralize('HIT'); |
b0853f7ba504e3b757a777a4fd5248c59e98c67d | WorksheetGenerator/WorksheetViewModel.ts | WorksheetGenerator/WorksheetViewModel.ts | class WorksheetViewModel {
private _subjects: Contract.ISubject[];
get subjects() { return this._subjects; }
selectedSubject = ko.observable<Contract.ISubject>();
error = ko.observable();
topLeftColumn = ko.observable(moment().format("L"));
topCenterColumn = ko.observable("Titel");
topRig... | class WorksheetViewModel {
private _subjects: Contract.ISubject[];
get subjects() { return this._subjects; }
selectedSubject = ko.observable<Contract.ISubject>();
error = ko.observable();
topLeftColumn = ko.observable(moment().format("L"));
topCenterColumn = ko.observable("Titel");
topRig... | Remove duplicate assignment of `error` | Remove duplicate assignment of `error`
| TypeScript | mit | eggapauli/WorksheetGenerator,eggapauli/WorksheetGenerator | ---
+++
@@ -17,8 +17,6 @@
constructor(subjects: Contract.ISubject[]) {
this._subjects = subjects;
- this.error = ko.observable();
-
this.generate = () => {
var generator = this.selectedSubject().selectedExerciseGenerator();
//try { |
f189d4db3af1ea83f240e2fa7b6964a51dd5c50a | app/src/lib/dispatcher/error-handlers.ts | app/src/lib/dispatcher/error-handlers.ts | import { Dispatcher, AppStore, ErrorHandler } from './index'
import { SelectionType } from '../app-state'
import { GitError } from '../git/core'
import { GitError as GitErrorType } from 'git-kitchen-sink'
/** Handle errors by presenting them. */
export async function defaultErrorHandler(error: Error, dispatcher: Dispa... | import { Dispatcher, AppStore, ErrorHandler } from './index'
import { SelectionType } from '../app-state'
import { GitError } from '../git/core'
import { GitError as GitErrorType, RepositoryDoesNotExistErrorCode } from 'git-kitchen-sink'
/** An error which also has a code property. */
interface IErrorWithCode extends ... | Check for the repo does not exist code | Check for the repo does not exist code
| TypeScript | mit | artivilla/desktop,shiftkey/desktop,BugTesterTest/desktops,BugTesterTest/desktops,say25/desktop,say25/desktop,gengjiawen/desktop,desktop/desktop,kactus-io/kactus,hjobrien/desktop,BugTesterTest/desktops,artivilla/desktop,desktop/desktop,j-f1/forked-desktop,say25/desktop,say25/desktop,shiftkey/desktop,shiftkey/desktop,hjo... | ---
+++
@@ -1,7 +1,26 @@
import { Dispatcher, AppStore, ErrorHandler } from './index'
import { SelectionType } from '../app-state'
import { GitError } from '../git/core'
-import { GitError as GitErrorType } from 'git-kitchen-sink'
+import { GitError as GitErrorType, RepositoryDoesNotExistErrorCode } from 'git-kitc... |
72129cdcd8d5871db28bbc166c937a6152a083d7 | client/src/app/services/thing.service.ts | client/src/app/services/thing.service.ts | import { Injectable } from '@angular/core';
import { Http } from '@angular/http';
import 'rxjs/add/operator/map';
import {Configuration} from '../app.constants';
import {AuthenticationService} from './authentication.service'
@Injectable()
export class ThingService {
private actionUrl: string;
private headers: any... | import { Injectable } from '@angular/core';
import { Http } from '@angular/http';
import 'rxjs/add/operator/map';
import {Configuration} from '../app.constants';
import {AuthenticationService} from './authentication.service'
@Injectable()
export class ThingService {
private actionUrl: string;
private headers: any... | Create of dynamic get things on userID | Create of dynamic get things on userID
| TypeScript | apache-2.0 | IBMZissou/dbh17-zissou,arner/fabric-boilerplate-ts,arner/fabric-boilerplate-ts,arner/fabric-boilerplate-ts,IBMZissou/dbh17-zissou,arner/fabric-boilerplate-ts,IBMZissou/dbh17-zissou,arner/fabric-boilerplate-ts,IBMZissou/dbh17-zissou,IBMZissou/dbh17-zissou | ---
+++
@@ -18,8 +18,9 @@
}
getThings() {
+ let user: any = JSON.parse(localStorage.getItem('currentUser')).user;
return this._http
- .get(this.actionUrl + '/john', {headers: this.headers})
+ .get(this.actionUrl + '/' + user.userID, {headers: this.headers})
.map(res => res.json());
... |
9618cd026ee1a2e9ea370f6a99772acba8e3b2de | src/adhocracy/adhocracy/frontend/static/js/Packages/Embed/Embed.ts | src/adhocracy/adhocracy/frontend/static/js/Packages/Embed/Embed.ts | /// <reference path="../../../lib/DefinitelyTyped/angularjs/angular-route.d.ts"/>
import _ = require("lodash");
import Util = require("../Util/Util");
/**
* List of directive names that can be embedded. names must be in
* lower-case with dashes, but without 'adh-' prefix. (example:
* 'document-workbench' for di... | /// <reference path="../../../lib/DefinitelyTyped/angularjs/angular-route.d.ts"/>
import _ = require("lodash");
import Util = require("../Util/Util");
/**
* List of directive names that can be embedded. names must be in
* lower-case with dashes, but without 'adh-' prefix. (example:
* 'document-workbench' for di... | Allow to embed comment listing directive | Allow to embed comment listing directive
| TypeScript | agpl-3.0 | xs2maverick/adhocracy3.mercator,fhartwig/adhocracy3.mercator,xs2maverick/adhocracy3.mercator,liqd/adhocracy3.mercator,fhartwig/adhocracy3.mercator,xs2maverick/adhocracy3.mercator,xs2maverick/adhocracy3.mercator,liqd/adhocracy3.mercator,liqd/adhocracy3.mercator,liqd/adhocracy3.mercator,fhartwig/adhocracy3.mercator,fhart... | ---
+++
@@ -9,7 +9,7 @@
* lower-case with dashes, but without 'adh-' prefix. (example:
* 'document-workbench' for directive DocumentWorkbench.)
*/
-var embeddableDirectives = ["document-workbench", "paragraph-version-detail"];
+var embeddableDirectives = ["document-workbench", "paragraph-version-detail", "comm... |
4aeda431d8bc405074e9f3312360577d9c1f2f96 | src/code/utils/scale-app.ts | src/code/utils/scale-app.ts | import * as screenfull from "screenfull";
import { DOMElement } from "react";
const getWindowTransforms = () => {
const MAX_WIDTH = 2000;
const width = Math.max(window.innerWidth, Math.min(MAX_WIDTH, screen.width));
const scale = window.innerWidth / width;
const height = window.innerHeight / scale;
return... | import * as screenfull from "screenfull";
import { DOMElement } from "react";
const getWindowTransforms = () => {
const MAX_WIDTH = 2000;
const width = Math.max(window.innerWidth, Math.min(MAX_WIDTH, screen.width));
const scale = window.innerWidth / width;
const height = window.innerHeight / scale;
return... | Make help text big even at small scales | Make help text big even at small scales | TypeScript | mit | concord-consortium/building-models,concord-consortium/building-models,concord-consortium/building-models,concord-consortium/building-models,concord-consortium/building-models | ---
+++
@@ -20,6 +20,12 @@
el.style.height = trans.unscaledHeight + "px";
el.style.transformOrigin = "top left";
el.style.transform = "scale3d(" + trans.scale + "," + trans.scale + ",1)";
+
+ // if we have fullscreen help text, make it big
+ const helpText = document.getElementsByClassName("fulls... |
7613a6df0299779bd5699be3f3e45146fee877d0 | src/app/search/SearchInput.tsx | src/app/search/SearchInput.tsx | import { searchIcon } from 'app/shell/icons';
import AppIcon from 'app/shell/icons/AppIcon';
import { useIsPhonePortrait } from 'app/shell/selectors';
import { isiOSBrowser } from 'app/utils/browsers';
import React, { useEffect, useRef } from 'react';
/**
* A styled text input without fancy features like autocompleti... | import { searchIcon } from 'app/shell/icons';
import AppIcon from 'app/shell/icons/AppIcon';
import { useIsPhonePortrait } from 'app/shell/selectors';
import { isiOSBrowser } from 'app/utils/browsers';
import React from 'react';
/**
* A styled text input without fancy features like autocompletion or de-bouncing.
*/
... | Remove autofocus on iOS for simple search filters | Remove autofocus on iOS for simple search filters
Fixes #8111
| TypeScript | mit | DestinyItemManager/DIM,DestinyItemManager/DIM,DestinyItemManager/DIM,DestinyItemManager/DIM | ---
+++
@@ -2,7 +2,7 @@
import AppIcon from 'app/shell/icons/AppIcon';
import { useIsPhonePortrait } from 'app/shell/selectors';
import { isiOSBrowser } from 'app/utils/browsers';
-import React, { useEffect, useRef } from 'react';
+import React from 'react';
/**
* A styled text input without fancy features li... |
effb92e4f4bc606f659044f3300e4201bb4165cd | src/app/services/api/api.ts | src/app/services/api/api.ts | import {Injectable} from 'angular2/core';
import {Observable} from 'rxjs/Observable';
import {Recipe} from '../../models/recipe';
import {AuthApi} from '../auth-api/authentication';
import Firebase = require("firebase");
export const FIREBASEURL = "https://sizzling-fire-4278.firebaseio.com/";
@Injectable()
export cla... | import {Injectable} from 'angular2/core';
import {Observable} from 'rxjs/Observable';
import {Recipe} from '../../models/recipe';
import {AuthApi} from '../auth-api/authentication';
import Firebase = require("firebase");
export const FIREBASEURL = "https://sizzling-fire-4278.firebaseio.com/";
@Injectable()
export cla... | Add save recipe function and update get recipes function | Add save recipe function and update get recipes function
| TypeScript | mit | bspride/ModernCookbook,bspride/ModernCookbook,bspride/ModernCookbook | ---
+++
@@ -9,26 +9,37 @@
@Injectable()
export class Api {
title: string = 'Modern Cookbook';
- private _db: Firebase;
- constructor(userService: AuthApi) {
- let userId = userService.getUserId()
- this._db = new Firebase(FIREBASEURL + 'users/' + userId + '/recipes');
- }
+ constructor(private ... |
6f26929ed42fae2f686892454e129e4455a49a0b | generators/service/templates/_service.spec.ts | generators/service/templates/_service.spec.ts | /* beautify ignore:start */
import {
it,
inject,
//injectAsync,
beforeEachProviders
//TestComponentBuilder
} from 'angular2/testing';
import {<%=servicenameClass%>Service} from './<%=servicenameFile%>.service.ts';
/* beautify ignore:end */
describe('Service: <%=servicename%>' , () => {
beforeE... | /* beautify ignore:start */
import {
it,
inject,
//injectAsync,
beforeEachProviders
//TestComponentBuilder
} from 'angular2/testing';
import {<%=servicenameClass%>Service} from './<%=servicenameFile%>.service.ts';
/* beautify ignore:end */
describe('Service: <%=servicenameClass%>Service' , () => {
... | Fix name for service unit test | fix(app): Fix name for service unit test
| TypeScript | mit | mcfly-io/generator-mcfly-ng2,mcfly-io/generator-mcfly-ng2,mcfly-io/generator-mcfly-ng2 | ---
+++
@@ -9,7 +9,7 @@
import {<%=servicenameClass%>Service} from './<%=servicenameFile%>.service.ts';
/* beautify ignore:end */
-describe('Service: <%=servicename%>' , () => {
+describe('Service: <%=servicenameClass%>Service' , () => {
beforeEachProviders(() => [<%=servicenameClass %>Service]);
|
2474764f605060d0bea2874cb6448dc52d311114 | src/index.ts | src/index.ts | import {Store, StoreOptions} from './store';
import { AdapterInitializer } from "./adapter";
export * from './store';
export * from "./adapter";
export * from "./bucket";
export async function store(name: string, settings?: StoreOptions): Promise<Store>;
export async function store(settings: StoreOptions): Promise<St... | import { Store, StoreOptions } from "./store";
import { AdapterInitializer } from "./adapter";
export * from "./store";
export * from "./adapter";
export * from "./bucket";
export function store(name: string, settings?: StoreOptions): Store;
export function store(settings: StoreOptions): Store;
export function store(... | Fix store function to return Store instance directly | Fix store function to return Store instance directly
| TypeScript | mit | taoyuan/kvs,taoyuan/kvs | ---
+++
@@ -1,15 +1,13 @@
-import {Store, StoreOptions} from './store';
+import { Store, StoreOptions } from "./store";
import { AdapterInitializer } from "./adapter";
-export * from './store';
+export * from "./store";
export * from "./adapter";
export * from "./bucket";
-export async function store(name: str... |
e2e74d13bfb8e647031d670ab83435122174ba2c | src/gui/mithril-menu.ts | src/gui/mithril-menu.ts | import * as m from 'mithril'
export function makeMenuItem(title: string, callback: () => void): m.Vnode<any, any> {
const top = m('li', { onclick: callback }, title);
return top
}
export function makeMenu(
menuTitle: string,
titles: string[],
callbackFactory: (title: string) => () => void): m.Vnod... | import * as m from 'mithril'
export function makeMenuItem(title: string, callback: () => void): m.Vnode<any, any> {
const top = m('li', { onclick: callback }, title);
return top
}
export function makeMenu(
menuTitle: string,
titles: string[],
callbackFactory: (title: string) => () => void): m.Vnod... | Improve menu generation, html is somewhat working | Improve menu generation, html is somewhat working
| TypeScript | mit | sami-badawi/shapelogic-typescript,sami-badawi/shapelogic-typescript | ---
+++
@@ -10,7 +10,7 @@
titles: string[],
callbackFactory: (title: string) => () => void): m.Vnode<any, any> {
const children = titles.map(title => makeMenuItem(title, callbackFactory(title)))
- const top = m('ul', { class: "main-nav" }, children);
+ const top = m('li', [menuTitle, m('ul', { cl... |
7ed8ae874c194483ad26f129cf7f5a2f44cfed42 | src/models/BaseModel.ts | src/models/BaseModel.ts | import {SequelizeModel} from "./SequelizeModel";
import {SequelizeDB} from "../libs/SequelizeDB";
import * as Sequelize from "sequelize"
/**
* @author Humberto Machado
*/
export abstract class BaseModel implements SequelizeModel {
//Sequelize Model native instance. @see http://docs.sequelizejs.com/en/latest/docs... | import {SequelizeModel} from "./SequelizeModel";
import {SequelizeDB} from "../libs/SequelizeDB";
import * as Sequelize from "sequelize"
/**
* @author Humberto Machado
*/
export abstract class BaseModel implements SequelizeModel {
//Sequelize Model native instance. @see http://docs.sequelizejs.com/en/latest/docs... | Update to use specific types | Update to use specific types
| TypeScript | mit | linck/protontype | ---
+++
@@ -24,27 +24,27 @@
//Hook Method
}
- public getNativeInstance(): any {
+ public getNativeInstance(): Sequelize.Model<any, any> {
return this.nativeInstance;
}
- public find(params: Sequelize.FindOptions): any {
+ public find(params: Sequelize.FindOptions): Promise<... |
ad1a92628f0cdbd61d8c07ec55a3bcfbbb5297b5 | webpack.prod.ts | webpack.prod.ts | import path from 'path'
import TerserPlugin from 'terser-webpack-plugin'
import { merge } from 'webpack-merge'
import { createConfig, srcPath } from './webpack.common'
const debugMode = process.env.DEBUG === 'true'
export default merge(createConfig({ mode: 'production' }), {
bail: true,
resolve: {
alias: {
... | import path from 'path'
import TerserPlugin from 'terser-webpack-plugin'
import { merge } from 'webpack-merge'
import { createConfig, srcPath } from './webpack.common'
const debugMode = process.env.DEBUG === 'true'
export default merge(createConfig({ mode: 'production' }), {
bail: true,
resolve: {
alias: {
... | Use WebPack defaults instead of custom splitChunks | Use WebPack defaults instead of custom splitChunks
| TypeScript | mpl-2.0 | DatapuntAmsterdam/atlas,Amsterdam/atlas,DatapuntAmsterdam/atlas_prototype,DatapuntAmsterdam/atlas,DatapuntAmsterdam/atlas,DatapuntAmsterdam/atlas_prototype,Amsterdam/atlas,Amsterdam/atlas,Amsterdam/atlas | ---
+++
@@ -32,16 +32,5 @@
namedModules: true,
moduleIds: 'named',
chunkIds: 'named',
- runtimeChunk: false,
- splitChunks: {
- maxInitialRequests: 20,
- chunks: 'async',
- maxSize: 125000,
- minChunks: 1,
- name: true,
- cacheGroups: {
- default: false,
- ... |
60b04cfffea80d3687792e45d1450a1778e6b312 | calq/calq.d.ts | calq/calq.d.ts | // Type definitions for calq
// Project: https://calq.io/docs/client/javascript/reference
// Definitions by: Eirik Hoem <https://github.com/eirikhm>
// Definitions: https://github.com/borisyankov/DefinitelyTyped
interface Calq
{
action:Calq.Action;
user:Calq.User;
init(writeKey:string, options?:{[index:st... | // Type definitions for calq
// Project: https://calq.io/docs/client/javascript/reference
// Definitions by: Eirik Hoem <https://github.com/eirikhm>
// Definitions: https://github.com/borisyankov/DefinitelyTyped
interface Calq
{
action:Calq.Action;
user:Calq.User;
init(writeKey:string, options?:{[index:st... | Make property params non-options (whoops) | Make property params non-options (whoops)
| TypeScript | mit | mhegazy/DefinitelyTyped,gcastre/DefinitelyTyped,slavomirvojacek/adbrain-typescript-definitions,Ptival/DefinitelyTyped,benishouga/DefinitelyTyped,martinduparc/DefinitelyTyped,flyfishMT/DefinitelyTyped,AbraaoAlves/DefinitelyTyped,alexdresko/DefinitelyTyped,alexdresko/DefinitelyTyped,chrismbarr/DefinitelyTyped,isman-usoh/... | ---
+++
@@ -21,7 +21,7 @@
trackPageView(action?:string):void;
setGlobalProperty(name:string, value:any):void;
- setGlobalProperty(params?: {[index:string]: any}):void;
+ setGlobalProperty(params: {[index:string]: any}):void;
}
interface User |
b2aad609b1867610729cb854339d8037fc6a89b4 | packages/components/containers/filePreview/PreviewLoader.tsx | packages/components/containers/filePreview/PreviewLoader.tsx | import React from 'react';
import { c } from 'ttag';
import FullLoader from '../../components/loader/FullLoader';
import TextLoader from '../../components/loader/TextLoader';
const PreviewLoader = () => {
return (
<div className="pd-file-preview-container">
<div className="centered-absolute">
... | import React from 'react';
import { c } from 'ttag';
import FullLoader from '../../components/loader/FullLoader';
import TextLoader from '../../components/loader/TextLoader';
const PreviewLoader = () => {
return (
<div className="pd-file-preview-container">
<div className="centered-absolute ali... | Align center for preview loading | Align center for preview loading
| TypeScript | mit | ProtonMail/WebClient,ProtonMail/WebClient,ProtonMail/WebClient | ---
+++
@@ -6,7 +6,7 @@
const PreviewLoader = () => {
return (
<div className="pd-file-preview-container">
- <div className="centered-absolute">
+ <div className="centered-absolute aligncenter w100">
<FullLoader size={100} />
<TextLoader>{c('Info'... |
13c3ba7e471e8ad70d8b01cc5dd4c3a228ebdc26 | test/components/heading.spec.tsx | test/components/heading.spec.tsx | import * as React from 'react';
import { expect, ClientRenderer, sinon, simulate } from 'test-drive-react';
import { Heading } from '../../src';
describe('<Heading />', () => {
const clientRenderer = new ClientRenderer();
afterEach(() => clientRenderer.cleanup())
it('outputs an <h1 /> element by default',... | import * as React from 'react';
import { expect, ClientRenderer, sinon, simulate } from 'test-drive-react';
import { Heading } from '../../src';
describe('<Heading />', () => {
const clientRenderer = new ClientRenderer();
afterEach(() => clientRenderer.cleanup())
it('outputs an <h1 /> element by default',... | Use async/await in heading tests | Use async/await in heading tests
| TypeScript | mit | wix/stylable-components,wix/stylable-components | ---
+++
@@ -20,11 +20,11 @@
});
['H1', 'H2', 'H3', 'H4', 'H5', 'H6'].forEach((headingType: any) => {
- it(`outputs an <${headingType.toLowerCase()}> when provided with type="${headingType}"`, () => {
+ it(`outputs an <${headingType.toLowerCase()}> when provided with type="${headingType}"`, a... |
cb30eaf8b1653b12333fb2e1c29d6ef901eefcc2 | tests/cases/fourslash/completionEntryForPrimitive.ts | tests/cases/fourslash/completionEntryForPrimitive.ts | ///<reference path="fourslash.ts" />
////var x = Object.create(/**/
diagnostics.setEditValidation(IncrementalEditValidation.None);
goTo.marker();
verify.not.completionListIsEmpty();
edit.insert("nu");
verify.completionListContains("number", undefined, undefined, undefined, "primitive type"); | ///<reference path="fourslash.ts" />
////var x = Object.create(/**/
diagnostics.setEditValidation(IncrementalEditValidation.None);
goTo.marker();
verify.not.completionListIsEmpty();
edit.insert("nu");
verify.completionListContains("number", undefined, undefined, undefined, "keyword"); | Allow built in types to show up in the completion list as keywords instead of types | Allow built in types to show up in the completion list as keywords instead of types
| TypeScript | apache-2.0 | mszczepaniak/TypeScript,thr0w/Thr0wScript,TukekeSoft/TypeScript,abbasmhd/TypeScript,tinganho/TypeScript,hitesh97/TypeScript,jnetterf/typescript-react-jsx,yortus/TypeScript,AbubakerB/TypeScript,yortus/TypeScript,shovon/TypeScript,hitesh97/TypeScript,Microsoft/TypeScript,nagyistoce/TypeScript,mauricionr/TypeScript,chocol... | ---
+++
@@ -6,4 +6,4 @@
goTo.marker();
verify.not.completionListIsEmpty();
edit.insert("nu");
-verify.completionListContains("number", undefined, undefined, undefined, "primitive type");
+verify.completionListContains("number", undefined, undefined, undefined, "keyword"); |
11b791fdf621dff35566d727919affeb1c882742 | lib/startup/cleanupFtpFolder.ts | lib/startup/cleanupFtpFolder.ts | /*
* Copyright (c) 2014-2022 Bjoern Kimminich & the OWASP Juice Shop contributors.
* SPDX-License-Identifier: MIT
*/
import glob = require('glob')
const path = require('path')
const fs = require('fs-extra')
const logger = require('../logger')
const cleanupFtpFolder = () => {
glob(path.resolve('ftp/*.pdf'), (err,... | /*
* Copyright (c) 2014-2022 Bjoern Kimminich & the OWASP Juice Shop contributors.
* SPDX-License-Identifier: MIT
*/
import glob = require('glob')
const utils = require('../utils')
const path = require('path')
const fs = require('fs-extra')
const logger = require('../logger')
const cleanupFtpFolder = () => {
glo... | Fix some unreported TypeScript compiler errors | Fix some unreported TypeScript compiler errors
| TypeScript | mit | bkimminich/juice-shop,bkimminich/juice-shop,bkimminich/juice-shop,bkimminich/juice-shop,bkimminich/juice-shop,bkimminich/juice-shop | ---
+++
@@ -4,16 +4,17 @@
*/
import glob = require('glob')
+const utils = require('../utils')
const path = require('path')
const fs = require('fs-extra')
const logger = require('../logger')
const cleanupFtpFolder = () => {
- glob(path.resolve('ftp/*.pdf'), (err, files) => {
+ glob(path.resolve('ftp/*.pdf... |
d807621bab744af9eef93273b179126f56893bd9 | src/stores/store.ts | src/stores/store.ts | export const IndexedStoreMixin = {
map: {},
getInitialState: function() {
return this.map;
}
}
| export const IndexedStoreMixin = {
init: function() {
this.map = {}
},
getInitialState: function() {
return this.map;
}
}
| Fix IndexedStoreMixin share same object bug | Fix IndexedStoreMixin share same object bug
| TypeScript | apache-2.0 | lawrence0819/neptune-front,lawrence0819/neptune-front | ---
+++
@@ -1,5 +1,7 @@
export const IndexedStoreMixin = {
- map: {},
+ init: function() {
+ this.map = {}
+ },
getInitialState: function() {
return this.map;
} |
ab49bb2ed4c2744f7457520975d54455d5c06b47 | react/javascript/src/EnvelopesQueryContext.ts | react/javascript/src/EnvelopesQueryContext.ts | import React from 'react'
import { messages } from '@cucumber/messages'
export class EnvelopesQuery {
private envelopes: messages.IEnvelope[] = []
public update(envelope: messages.IEnvelope) {
this.envelopes.push(envelope)
}
public find(
callback: (envelope: messages.IEnvelope) => boolean
): messag... | import React from 'react'
import { messages } from '@cucumber/messages'
export class EnvelopesQuery {
private envelopes: messages.IEnvelope[] = []
public update(envelope: messages.IEnvelope) {
this.envelopes.push(envelope)
}
public find(
predicate: (envelope: messages.IEnvelope) => boolean
): messa... | Rename callback to predicate to better reveal intent | Rename callback to predicate to better reveal intent
| TypeScript | mit | cucumber/cucumber,cucumber/cucumber,cucumber/cucumber,cucumber/cucumber,cucumber/cucumber,cucumber/cucumber,cucumber/cucumber,cucumber/cucumber,cucumber/cucumber,cucumber/cucumber,cucumber/cucumber,cucumber/cucumber | ---
+++
@@ -9,15 +9,15 @@
}
public find(
- callback: (envelope: messages.IEnvelope) => boolean
+ predicate: (envelope: messages.IEnvelope) => boolean
): messages.IEnvelope {
- return this.envelopes.find(callback)
+ return this.envelopes.find(predicate)
}
public filter(
- callback: (e... |
aabbb695224bb56197ec35983e8513446b9d100d | types/index.ts | types/index.ts | export type CookieAttributes = object & {
path?: string
domain?: string
expires?: number | Date
sameSite?: string
secure?: boolean
[property: string]: any
}
export type ReadConverter = (value: string, name?: string) => any
export type WriteConverter = (value: any, name?: string) => string
export type Coo... | export type CookieAttributes = object & {
path?: string
domain?: string
expires?: number | Date
sameSite?: string
secure?: boolean
[property: string]: any
}
export type ReadConverter = (value: string, name?: string) => any
export type WriteConverter = (value: any, name?: string) => string
export type Coo... | Make converter props optional where necessary | Make converter props optional where necessary
| TypeScript | mit | carhartl/js-cookie,carhartl/js-cookie | ---
+++
@@ -12,8 +12,8 @@
export type WriteConverter = (value: any, name?: string) => string
export type CookieConverter = object & {
- read?: ReadConverter
- write?: WriteConverter
+ read: ReadConverter
+ write: WriteConverter
}
type CookiesConfig = object & {
@@ -32,7 +32,7 @@
) => string | undefined... |
df1d0f4e8e295c4686d101aca20b0fd3f7b1984f | addons/dexie-cloud/bin-src/index.ts | addons/dexie-cloud/bin-src/index.ts | import { program } from "commander";
import { version } from "../package.json";
program.version(version);
console.log("Hello en3", version); | import { program } from "commander";
import { version } from "../package.json";
program.version(version);
console.log("Hello en5", version); | Remove get-started because we have it on the landing page | Remove get-started because we have it on the landing page
| TypeScript | apache-2.0 | jimmywarting/Dexie.js,jimmywarting/Dexie.js,jimmywarting/Dexie.js,jimmywarting/Dexie.js,dfahlander/Dexie.js,dfahlander/Dexie.js,dfahlander/Dexie.js,dfahlander/Dexie.js | ---
+++
@@ -3,4 +3,4 @@
program.version(version);
-console.log("Hello en3", version);
+console.log("Hello en5", version); |
3639cbc331b651111be3db36d3ed4f1a41c4b247 | packages/components/containers/filePreview/helpers.ts | packages/components/containers/filePreview/helpers.ts | import { isSafari, hasPDFSupport } from 'proton-shared/lib/helpers/browser';
export const isSupportedImage = (mimeType: string) =>
[
'image/apng',
'image/bmp',
'image/gif',
'image/x-icon',
'image/vnd.microsoft.icon',
'image/jpeg',
'image/png',
'image/... | import { isSafari, hasPDFSupport } from 'proton-shared/lib/helpers/browser';
export const isSupportedImage = (mimeType: string) =>
[
'image/apng',
'image/bmp',
'image/gif',
'image/x-icon',
'image/vnd.microsoft.icon',
'image/jpeg',
'image/png',
'image/... | Add typescript and javascript files as supported for text preview | Add typescript and javascript files as supported for text preview
| TypeScript | mit | ProtonMail/WebClient,ProtonMail/WebClient,ProtonMail/WebClient | ---
+++
@@ -15,7 +15,8 @@
.filter(Boolean)
.includes(mimeType);
-export const isSupportedText = (mimeType: string) => mimeType.startsWith('text/');
+export const isSupportedText = (mimeType: string) =>
+ mimeType.startsWith('text/') || ['application/javascript', 'application/typescript'].includ... |
93fcbdf334c2ed718614ba20e38e72c79450f3aa | components/divider/index.tsx | components/divider/index.tsx | import * as React from 'react';
import classNames from 'classnames';
export default function Divider({
prefixCls = 'ant',
type = 'horizontal',
className,
children,
dashed,
...restProps,
}) {
const classString = classNames(
className, `${prefixCls}-divider`, `${prefixCls}-divider-${type}`, {
[`${p... | import * as React from 'react';
import classNames from 'classnames';
export interface DividerProps {
prefixCls?: string;
type?: 'horizontal' | 'vertical';
className?: string;
children?: React.ReactNode;
dashed?: boolean;
}
export default function Divider({
prefixCls = 'ant',
type = 'horizontal',
clas... | Fix implicit any error for Divider | Fix implicit any error for Divider
| TypeScript | mit | icaife/ant-design,havefive/ant-design,elevensky/ant-design,havefive/ant-design,havefive/ant-design,RaoHai/ant-design,ant-design/ant-design,icaife/ant-design,ant-design/ant-design,havefive/ant-design,icaife/ant-design,zheeeng/ant-design,RaoHai/ant-design,elevensky/ant-design,ant-design/ant-design,elevensky/ant-design,zh... | ---
+++
@@ -1,5 +1,14 @@
import * as React from 'react';
import classNames from 'classnames';
+
+export interface DividerProps {
+ prefixCls?: string;
+ type?: 'horizontal' | 'vertical';
+ className?: string;
+ children?: React.ReactNode;
+ dashed?: boolean;
+
+}
export default function Divider({
prefixC... |
3c9b39a54d77cb15135587ed2aae5c8254c8472b | app/components/views/RaceList.tsx | app/components/views/RaceList.tsx | import { Link } from 'react-router'
import * as React from 'react'
import { List, ListItem } from 'material-ui/List'
import Avatar from 'material-ui/Avatar'
import Subheader from 'material-ui/Subheader'
import { RaceListItem } from './RaceListItem'
import CircularProgress from 'material-ui/CircularProgress'
export f... | import { Link } from 'react-router'
import * as React from 'react'
import { List, ListItem } from 'material-ui/List'
import Avatar from 'material-ui/Avatar'
import Subheader from 'material-ui/Subheader'
import { RaceListItem } from './RaceListItem'
import CircularProgress from 'material-ui/CircularProgress'
export f... | Update the loading indicator in Race List screen | Update the loading indicator in Race List screen
| TypeScript | mit | nluo/horse-races,nluo/horse-races,nluo/horse-races | ---
+++
@@ -11,24 +11,26 @@
export function RaceList(props: RaceListContainerProps) {
return (
- props.isFetching ? (
- <CircularProgress size={100}/>
- ) : (
- <div>
- <List>
- {
- props.races.map((ra... |
35fe6371d7d94073eb76691c3c841e394f4a6ad8 | src/extension.ts | src/extension.ts | import * as vscode from 'vscode';
let mavensMateMateExtension;
export function activate(context: vscode.ExtensionContext) {
let { MavensMateExtension } = require('./mavensmateExtension');
mavensMateMateExtension = new MavensMateExtension(context);
mavensMateMateExtension.activate().catch(console.error);
}... | import * as vscode from 'vscode';
let mavensMateMateExtension;
export function activate(context: vscode.ExtensionContext) {
let { MavensMateExtension } = require('./mavensMateExtension');
mavensMateMateExtension = new MavensMateExtension(context);
mavensMateMateExtension.activate().catch(console.error);
}... | Resolve incorrectly cased require statement | Resolve incorrectly cased require statement
| TypeScript | mit | joeferraro/MavensMate-VisualStudioCode | ---
+++
@@ -3,7 +3,7 @@
let mavensMateMateExtension;
export function activate(context: vscode.ExtensionContext) {
- let { MavensMateExtension } = require('./mavensmateExtension');
+ let { MavensMateExtension } = require('./mavensMateExtension');
mavensMateMateExtension = new MavensMateExtension(context... |
72057500b5220b28e637a6a31acb86f4f4273393 | tests/cases/conformance/salsa/multipleDeclarations.ts | tests/cases/conformance/salsa/multipleDeclarations.ts | // @filename: input.js
// @out: output.js
// @allowJs: true
function C() {
this.m = null;
}
C.prototype.m = function() {
this.nothing();
}
class X {
constructor() {
this.m = this.m.bind(this);
this.mistake = 'frankly, complete nonsense';
}
m() {
}
mistake() {
}
}
let x ... | // @filename: input.js
// @out: output.js
// @allowJs: true
function C() {
this.m = null;
}
C.prototype.m = function() {
this.nothing();
}
class X {
constructor() {
this.m = this.m.bind(this);
this.mistake = 'frankly, complete nonsense';
}
m() {
}
mistake() {
}
}
let x = ... | Test that declares conflicting method first | Test that declares conflicting method first
| TypeScript | apache-2.0 | erikmcc/TypeScript,microsoft/TypeScript,donaldpipowitch/TypeScript,RyanCavanaugh/TypeScript,mihailik/TypeScript,erikmcc/TypeScript,minestarks/TypeScript,kitsonk/TypeScript,mihailik/TypeScript,SaschaNaz/TypeScript,jwbay/TypeScript,synaptek/TypeScript,weswigham/TypeScript,vilic/TypeScript,jwbay/TypeScript,Microsoft/TypeS... | ---
+++
@@ -1,14 +1,12 @@
// @filename: input.js
// @out: output.js
// @allowJs: true
-
function C() {
this.m = null;
}
C.prototype.m = function() {
this.nothing();
}
-
class X {
constructor() {
this.m = this.m.bind(this);
@@ -23,3 +21,17 @@
X.prototype.mistake = false;
x.m();
x.mis... |
66ab18544481b693a0d35f2d2a19902417f4a835 | src/files/fileContainer.ts | src/files/fileContainer.ts | import { BasicFileContainer } from "./basicFileContainer";
import * as common from "./common";
import * as utils from "../common/utils";
import * as view from "../view/common";
export class FileContainer extends BasicFileContainer {
constructor() {
super();
}
getDescriptorsAll(): view.FileStageQu... | import { BasicFileContainer } from "./basicFileContainer";
import * as common from "./common";
import * as utils from "../common/utils";
import * as view from "../view/common";
export class FileContainer extends BasicFileContainer {
constructor() {
super();
}
getDescriptorsAll(): view.FileStageQu... | Remove redundant method in FileContainer | Remove redundant method in FileContainer
| TypeScript | mit | tht13/gerrit-vscode | ---
+++
@@ -38,8 +38,4 @@
}
return descriptors;
}
-
- isDirty(): boolean {
- return this.lengthOfType([common.GitStatus.MODIFIED, common.GitStatus.DELETED]) !== 0;
- }
} |
043b22c1537cb1f4eb74e65beefdeb98ffcbbbd6 | src/app/admin/projects/projects-management/projects-management.component.ts | src/app/admin/projects/projects-management/projects-management.component.ts | import { Component, OnInit } from '@angular/core';
import { ITdDataTableColumn } from '@covalent/core';
import {AngularFire, FirebaseListObservable} from 'angularfire2';
@Component({
selector: 'app-projects-management',
templateUrl: './projects-management.component.html',
styleUrls: ['./projects-management.comp... | import { Component, OnInit, OnDestroy } from '@angular/core';
import { ITdDataTableColumn } from '@covalent/core';
import { Observable } from 'rxjs/Observable';
import { Subject } from 'rxjs/Subject';
import { BehaviorSubject } from 'rxjs/BehaviorSubject';
import {AngularFire, FirebaseListObservable} from 'angularfir... | Fix issue with value not initialized | Fix issue with value not initialized
| TypeScript | mit | idee-negocios/idee-dashboard,idee-negocios/idee-dashboard,idee-negocios/idee-dashboard | ---
+++
@@ -1,5 +1,9 @@
-import { Component, OnInit } from '@angular/core';
+import { Component, OnInit, OnDestroy } from '@angular/core';
import { ITdDataTableColumn } from '@covalent/core';
+
+import { Observable } from 'rxjs/Observable';
+import { Subject } from 'rxjs/Subject';
+import { BehaviorSubject } from 'r... |
76b6ae57db813912527a45f2604d72659cb63809 | server/data/getCurrentUrl.ts | server/data/getCurrentUrl.ts | import { PageInterface } from "../../pages";
import getBaseUrl from "./getBaseUrl";
const getCurrentUrl = (page: PageInterface): string => {
return `${getBaseUrl()}${page.action}`;
};
export default getCurrentUrl;
| import { PageInterface } from "../../pages";
import getBaseUrl from "./getBaseUrl";
const getCurrentUrl = (page: PageInterface): string => {
return page.action;
};
export default getCurrentUrl;
| Use only path for current Url | Use only path for current Url
| TypeScript | mit | drublic/vc,drublic/vc,drublic/vc | ---
+++
@@ -2,7 +2,7 @@
import getBaseUrl from "./getBaseUrl";
const getCurrentUrl = (page: PageInterface): string => {
- return `${getBaseUrl()}${page.action}`;
+ return page.action;
};
export default getCurrentUrl; |
03774253eb264b5ba3c79cff87e67d48b2cba102 | templates/AureliaSpa/ClientApp/app/components/fetchdata/fetchdata.ts | templates/AureliaSpa/ClientApp/app/components/fetchdata/fetchdata.ts | // The following line is a workaround for aurelia-fetch-client requiring the type UrlSearchParams
// to exist in global scope, but that type not being declared in any public @types/* package.
/// <reference path="../../../../node_modules/aurelia-fetch-client/doc/url.d.ts" />
import { HttpClient } from 'aurelia-fetch-c... | // The following line is a workaround for aurelia-fetch-client requiring the type UrlSearchParams
// to exist in global scope, but that type not being declared in any public @types/* package.
/// <reference path="../../../../node_modules/aurelia-fetch-client/doc/url.d.ts" />
import { HttpClient } from 'aurelia-fetch-c... | Fix AureliaSpa TypeScript compile error introduced by newer version of TypeScript | Fix AureliaSpa TypeScript compile error introduced by newer version of TypeScript
| TypeScript | apache-2.0 | aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore,aspnet/AspNetCore | ---
+++
@@ -13,7 +13,7 @@
http.fetch('/api/SampleData/WeatherForecasts')
.then(result => result.json())
.then(data => {
- this.forecasts = data;
+ this.forecasts = data as any;
});
}
} |
6f7e01dab8277a4e1b5e74f2a2734e7b126e7a5a | src/services/local-data.service.ts | src/services/local-data.service.ts | import { Injectable } from '@angular/core'
import { MonotonicTimeService } from "./monotonic-time.service";
@Injectable()
export class LocalDataService {
private _vrEnterTime : number = null; // null if not in VR
constructor(private _time: MonotonicTimeService) {
}
public toggleVr() {
if (this._vrEnter... | import { Injectable } from '@angular/core'
import { MonotonicTimeService } from "./monotonic-time.service";
@Injectable()
export class LocalDataService {
private _vrEnterTime : number = null; // null if not in VR
constructor(private _time: MonotonicTimeService) {
}
public toggleVr() {
if (this._vrEnter... | Remove spamming to error console, use debug instead | Remove spamming to error console, use debug instead
| TypeScript | apache-2.0 | sth-larp/deus-mobile,sth-larp/deus-mobile,sth-larp/deus-mobile,sth-larp/deus-mobile,sth-larp/deus-mobile | ---
+++
@@ -11,15 +11,15 @@
public toggleVr() {
if (this._vrEnterTime == null) {
- console.error("### VR: in");
+ console.debug("### VR: in");
this._vrEnterTime = this._time.getUnixTimeMs();
} else {
- console.error("### VR: out");
+ console.debug("### VR: out");
this.... |
1935123248ddef6a70d7f157ede65dc9f7d8724b | frontend/src/hacking-instructor/tutorialUnavailable.ts | frontend/src/hacking-instructor/tutorialUnavailable.ts | /*
* Copyright (c) 2014-2020 Bjoern Kimminich.
* SPDX-License-Identifier: MIT
*/
import {
waitInMs
} from './helpers/helpers'
import { ChallengeInstruction } from './'
export const TutorialUnavailableInstruction: ChallengeInstruction = {
name: null,
hints: [
{
text:
"😓 Sorry, this hacking ... | /*
* Copyright (c) 2014-2020 Bjoern Kimminich.
* SPDX-License-Identifier: MIT
*/
import {
waitInMs
} from './helpers/helpers'
import { ChallengeInstruction } from './'
export const TutorialUnavailableInstruction: ChallengeInstruction = {
name: null,
hints: [
{
text:
"😓 Sorry, this hacking ... | Add emoji to request for contribution in fallback tutorial | Add emoji to request for contribution in fallback tutorial
| TypeScript | mit | bkimminich/juice-shop,bkimminich/juice-shop,bkimminich/juice-shop,bkimminich/juice-shop,bkimminich/juice-shop,bkimminich/juice-shop | ---
+++
@@ -19,7 +19,7 @@
},
{
text:
- "Do you want to contribute a tutorial for this challenge? [Check out our documentation](https://pwning.owasp-juice.shop/part3/tutorials.html) to learn how!",
+ "✍️ Do you want to contribute a tutorial for this challenge? [Check out our documentatio... |
23cceaecc4a1958e167e55a7a95cc7ef43d3efef | public/app/core/specs/global_event_srv.jest.ts | public/app/core/specs/global_event_srv.jest.ts | import { GlobalEventSrv } from 'app/core/services/global_event_srv';
import { beforeEach } from 'test/lib/common';
jest.mock('app/core/config', () => {
return {
appSubUrl: '/subUrl'
};
});
describe('GlobalEventSrv', () => {
let searchSrv;
beforeEach(() => {
searchSrv = new GlobalEventSrv(null, null)... | import { GlobalEventSrv } from "app/core/services/global_event_srv";
import { beforeEach } from "test/lib/common";
jest.mock("app/core/config", () => {
return {
appSubUrl: "/subUrl"
};
});
describe("GlobalEventSrv", () => {
let searchSrv;
beforeEach(() => {
searchSrv = new GlobalEventSrv(null, null, ... | Update test with new component signature | test: Update test with new component signature
| TypeScript | agpl-3.0 | grafana/grafana,grafana/grafana,grafana/grafana,grafana/grafana,grafana/grafana,grafana/grafana,grafana/grafana | ---
+++
@@ -1,23 +1,23 @@
-import { GlobalEventSrv } from 'app/core/services/global_event_srv';
-import { beforeEach } from 'test/lib/common';
+import { GlobalEventSrv } from "app/core/services/global_event_srv";
+import { beforeEach } from "test/lib/common";
-jest.mock('app/core/config', () => {
+jest.mock("app/c... |
76ab9d1c5897e9c6744cef4666d96a737636e1e4 | src/placeholders/TextRow.tsx | src/placeholders/TextRow.tsx | import * as React from 'react';
export type Props = {
maxHeight?: string | number,
invisible?: boolean,
className?: string,
color: string,
style?: React.CSSProperties,
lineSpacing?: string | number
}
export default class TextRow extends React.Component<Props> {
static defaultProps = {
lineSpacing: ... | import * as React from 'react';
export type Props = {
maxHeight?: string | number,
className?: string,
color: string,
style?: React.CSSProperties,
lineSpacing?: string | number
}
export default class TextRow extends React.Component<Props> {
static defaultProps = {
lineSpacing: '0.7em'
}
render()... | Remove unused prop from interface | Remove unused prop from interface
| TypeScript | mit | buildo/react-placeholder,buildo/react-placeholder,buildo/react-placeholder | ---
+++
@@ -2,7 +2,6 @@
export type Props = {
maxHeight?: string | number,
- invisible?: boolean,
className?: string,
color: string,
style?: React.CSSProperties, |
a6b8fa968b9fc7a6517db9219c28f7d78cf56f3b | src/ts/components/errormessageoverlay.ts | src/ts/components/errormessageoverlay.ts | import {ContainerConfig, Container} from './container';
import {Label, LabelConfig} from './label';
import {UIInstanceManager} from '../uimanager';
import ErrorEvent = bitmovin.player.ErrorEvent;
import {TvNoiseCanvas} from './tvnoisecanvas';
/**
* Overlays the player and displays error messages.
*/
export class Err... | import {ContainerConfig, Container} from './container';
import {Label, LabelConfig} from './label';
import {UIInstanceManager} from '../uimanager';
import ErrorEvent = bitmovin.player.ErrorEvent;
import {TvNoiseCanvas} from './tvnoisecanvas';
import PlayerEvent = bitmovin.player.PlayerEvent;
/**
* Overlays the player... | Hide error overlay when a new source is loaded | Hide error overlay when a new source is loaded
| TypeScript | mit | bitmovin/bitmovin-player-ui,bitmovin/bitmovin-player-ui,bitmovin/bitmovin-player-ui,bitmovin/bitmovin-player-ui | ---
+++
@@ -3,6 +3,7 @@
import {UIInstanceManager} from '../uimanager';
import ErrorEvent = bitmovin.player.ErrorEvent;
import {TvNoiseCanvas} from './tvnoisecanvas';
+import PlayerEvent = bitmovin.player.PlayerEvent;
/**
* Overlays the player and displays error messages.
@@ -35,5 +36,12 @@
self.tvNois... |
110adf672f217bf1dd1bfa92eb356dde522c0928 | libweb/webutil.ts | libweb/webutil.ts | import * as http from 'http';
import * as querystring from 'querystring';
import * as fs from 'fs';
/**
* Read all the data from an HTTP request.
*/
export function body(req: http.IncomingMessage): Promise<string> {
return new Promise((resolve, reject) => {
let body = '';
req.on('data', (data) => {
b... | import * as http from 'http';
import * as querystring from 'querystring';
import * as fs from 'fs';
/**
* Read all the data from an HTTP request.
*/
export function body(req: http.IncomingMessage): Promise<string> {
return new Promise((resolve, reject) => {
let body = '';
req.on('data', (data) => {
b... | Handle errors when serving static files | Handle errors when serving static files
| TypeScript | mit | cucapra/opal-bot,cucapra/opal-bot | ---
+++
@@ -31,7 +31,20 @@
export function sendfile(res: http.ServerResponse, path: string, mime='text/html') {
res.statusCode = 200;
res.setHeader('Content-Type', mime);
- fs.createReadStream(path).pipe(res);
+
+ let stream = fs.createReadStream(path);
+ stream.on('error', (e: any) => {
+ if (e.code ===... |
7afb6f9923ee4741eddab3c561da7cc2f3daa847 | static/js/sloth.ts | static/js/sloth.ts | import "jquery-sloth-konami";
export module sloth {
function fixSlothCanvas() {
let slothCanvas: HTMLCanvasElement = <HTMLCanvasElement>$("canvas")[0];
slothCanvas.height = $("#body").height();
}
$(document).ready(function() {
$("#body").sloth({
"imageUrl": "/itrac/imag... | import "jquery-sloth-konami";
export module sloth {
function fixSlothCanvas() {
let slothCanvas: HTMLCanvasElement = <HTMLCanvasElement>$("canvas")[0];
slothCanvas.height = $("#body").height();
}
$(document).ready(function() {
(<any>$("#body")).sloth({
"imageUrl": "/itr... | Fix compile error in /static/js | Fix compile error in /static/js
| TypeScript | mit | crossroads-education/eta-front,crossroads-education/eta-front | ---
+++
@@ -7,7 +7,7 @@
}
$(document).ready(function() {
- $("#body").sloth({
+ (<any>$("#body")).sloth({
"imageUrl": "/itrac/images/signin/sloth.svg",
"zIndex": 99999
}); |
ea9677a9d9ad6eafcd776ff52e8ffce13b58189c | app/src/lib/stores/helpers/onboarding-tutorial.ts | app/src/lib/stores/helpers/onboarding-tutorial.ts | export class OnboardingTutorial {
public constructor() {
this.skipInstallEditor = false
this.skipCreatePR = false
}
getCurrentStep() {
// call all other methods to check where we're at
}
isEditorInstalled() {
if (this.skipInstallEditor) {
return true
}
return false
}
isBra... | export class OnboardingTutorial {
public constructor() {
this.skipInstallEditor = false
this.skipCreatePR = false
}
getCurrentStep() {
// call all other methods to check where we're at
}
isEditorInstalled() {
if (this.skipInstallEditor) {
return true
}
return false
}
isBra... | Add methods to skip editor installation and PR creation | Add methods to skip editor installation and PR creation
| TypeScript | mit | say25/desktop,artivilla/desktop,say25/desktop,artivilla/desktop,j-f1/forked-desktop,j-f1/forked-desktop,kactus-io/kactus,j-f1/forked-desktop,artivilla/desktop,say25/desktop,kactus-io/kactus,shiftkey/desktop,desktop/desktop,desktop/desktop,kactus-io/kactus,artivilla/desktop,kactus-io/kactus,say25/desktop,desktop/desktop... | ---
+++
@@ -37,4 +37,12 @@
}
return false
}
+
+ skipEditorInstall() {
+ this.skipEditorInstall = true
+ }
+
+ skipCreatePR() {
+ this.skipCreatePR = true
+ }
} |
570558ed8e93dc62094f5cc0d79ced4861d962d0 | src/app/dim-ui/AnimatedNumber.tsx | src/app/dim-ui/AnimatedNumber.tsx | import React from 'react';
import { animated, config, useSpring } from 'react-spring';
const spring = {
...config.stiff,
clamp: true,
};
/**
* A number that animates between values.
*/
export default function AnimatedNumber({ value }: { value: number }) {
const animatedValue = useSpring<{ val: number }>({ val... | import { animate, Spring, useMotionValue } from 'framer-motion';
import React, { useEffect, useRef } from 'react';
const spring: Spring = {
type: 'spring',
duration: 0.3,
bounce: 0,
};
/**
* A number that animates between values.
*/
export default function AnimatedNumber({ value }: { value: number }) {
cons... | Switch AnimatedValue to Framer Motion | Switch AnimatedValue to Framer Motion
| TypeScript | mit | DestinyItemManager/DIM,DestinyItemManager/DIM,DestinyItemManager/DIM,DestinyItemManager/DIM | ---
+++
@@ -1,17 +1,30 @@
-import React from 'react';
-import { animated, config, useSpring } from 'react-spring';
+import { animate, Spring, useMotionValue } from 'framer-motion';
+import React, { useEffect, useRef } from 'react';
-const spring = {
- ...config.stiff,
- clamp: true,
+const spring: Spring = {
+ t... |
e596e78f6f69878f3aef68d38d790e8e768fa98b | src/explorer.ts | src/explorer.ts | import react = require("react");
import Explorer = require("./components/explorer");
/**
* Creates and renders the API Explorer component.
*/
export function run(initial_resource?: string, initial_route?: string): void {
react.render(Explorer.create({
initial_resource_string: initial_resource,
initial_rou... | import react = require("react");
import Explorer = require("./components/explorer");
/**
* Creates and renders the API Explorer component.
*/
export function run(initial_resource?: string, initial_route?: string): void {
react.render(Explorer.create({
initial_resource_string: initial_resource,
initial_rou... | Use a different ID to output the React app | Use a different ID to output the React app | TypeScript | mit | Asana/api-explorer,Asana/api-explorer | ---
+++
@@ -9,5 +9,5 @@
react.render(Explorer.create({
initial_resource_string: initial_resource,
initial_route: initial_route
- }), document.getElementById("container"));
+ }), document.getElementById("tab-tester"));
} |
43c15097b32e3338b9b4f003f5945d5c45122c39 | console/src/app/core/services/container-server/container-server-service.ts | console/src/app/core/services/container-server/container-server-service.ts | import { Injectable } from "@angular/core";
import { HttpClient, HttpHeaders } from "@angular/common/http";
import { Constants } from "src/app/common/constants";
import { Observable } from "rxjs";
@Injectable({
providedIn: 'root'
})
// NOTE: Prometheus configuration is being send via the Node.JS server ...
// wh... | import { Injectable } from "@angular/core";
import { HttpClient, HttpHeaders } from "@angular/common/http";
import { Constants } from "src/app/common/constants";
import { Observable } from "rxjs";
@Injectable({
providedIn: 'root'
})
// NOTE: Prometheus configuration is being send via the Node.JS server ...
// wh... | Fix issue with URL address of container server. | Fix issue with URL address of container server.
| TypeScript | mit | emc-mongoose/console,emc-mongoose/console,emc-mongoose/console | ---
+++
@@ -14,7 +14,7 @@
export class ContainerServerService {
private readonly FILE_SAVE_ENDPOINT = "savefile";
- private readonly CONTAINER_SERVER_ADDRESS = `http://localhost:${Constants.Configuration.CONTAINER_SERVER_PORT}`;
+ private readonly CONTAINER_SERVER_ADDRESS = "http://localhost:" + Constan... |
52550efc036c3b71ba1f9e2a69687da22b8ed133 | src/Umbraco.Tests.AcceptanceTest/cypress/integration/Settings/languages.ts | src/Umbraco.Tests.AcceptanceTest/cypress/integration/Settings/languages.ts | /// <reference types="Cypress" />
context('Languages', () => {
beforeEach(() => {
cy.umbracoLogin(Cypress.env('username'), Cypress.env('password'));
});
it('Add language', () => {
const name = "Kyrgyz (Kyrgyzstan)"; // Must be an option in the select box
cy.umbracoEnsureLanguageNameNotExists(name)... | /// <reference types="Cypress" />
context('Languages', () => {
beforeEach(() => {
cy.umbracoLogin(Cypress.env('username'), Cypress.env('password'));
});
it('Add language', () => {
const name = "Afrikaans"; // Must be an option in the select box
cy.umbracoEnsureLanguageNameNotExists(name);
cy.... | Fix language to a language that exists in .net core | Fix language to a language that exists in .net core
Signed-off-by: Bjarke Berg <1d6e1cf70ec6f9ab28d3ea4b27a49a77654d370e@bergmania.dk>
| TypeScript | mit | umbraco/Umbraco-CMS,JimBobSquarePants/Umbraco-CMS,umbraco/Umbraco-CMS,marcemarc/Umbraco-CMS,robertjf/Umbraco-CMS,KevinJump/Umbraco-CMS,robertjf/Umbraco-CMS,KevinJump/Umbraco-CMS,marcemarc/Umbraco-CMS,abjerner/Umbraco-CMS,JimBobSquarePants/Umbraco-CMS,arknu/Umbraco-CMS,KevinJump/Umbraco-CMS,abryukhov/Umbraco-CMS,marcema... | ---
+++
@@ -6,7 +6,7 @@
});
it('Add language', () => {
- const name = "Kyrgyz (Kyrgyzstan)"; // Must be an option in the select box
+ const name = "Afrikaans"; // Must be an option in the select box
cy.umbracoEnsureLanguageNameNotExists(name);
|
fce5f5bd7d81417de0e5a5aae2762ab556a94c06 | lib/export-notebook.ts | lib/export-notebook.ts | import * as path from "path";
import { writeFile } from "fs";
import { remote } from "electron";
const { dialog } = remote;
import { stringifyNotebook } from "@nteract/commutable";
import store from "./store";
export default function exportNotebook() {
// TODO: Refactor to use promises, this is a bit "nested".
co... | import * as path from "path";
import { writeFile } from "fs";
import { remote } from "electron";
const { dialog } = remote;
import { stringifyNotebook } from "@nteract/commutable";
import store from "./store";
export default function exportNotebook() {
// TODO: Refactor to use promises, this is a bit "nested".
co... | Add TODO for fixing exportNotebook | Add TODO for fixing exportNotebook
| TypeScript | mit | nteract/hydrogen,nteract/hydrogen | ---
+++
@@ -27,6 +27,6 @@
}
});
};
-
+ // TODO this API is promisified -> should be fixed
dialog.showSaveDialog(saveNotebook);
} |
0f91f08664f304091361dc815c8fca5dae78aa31 | app/test/setup-test-framework.ts | app/test/setup-test-framework.ts | // set test timeout to 10s
jest.setTimeout(10000)
import 'jest-extended'
import 'jest-localstorage-mock'
| // set test timeout to 100s
jest.setTimeout(100000)
import 'jest-extended'
import 'jest-localstorage-mock'
| Increase Jest timeout to 100s | Increase Jest timeout to 100s
| TypeScript | mit | say25/desktop,say25/desktop,j-f1/forked-desktop,j-f1/forked-desktop,desktop/desktop,say25/desktop,shiftkey/desktop,artivilla/desktop,desktop/desktop,artivilla/desktop,desktop/desktop,artivilla/desktop,j-f1/forked-desktop,shiftkey/desktop,artivilla/desktop,desktop/desktop,j-f1/forked-desktop,say25/desktop,shiftkey/deskt... | ---
+++
@@ -1,5 +1,5 @@
-// set test timeout to 10s
-jest.setTimeout(10000)
+// set test timeout to 100s
+jest.setTimeout(100000)
import 'jest-extended'
import 'jest-localstorage-mock' |
509082191c0c2a5adaae8fe3657b3223c63c138b | ui/src/notification.ts | ui/src/notification.ts | import {thread} from "./thread";
import {IMessage} from "../../common/data";
// workaround (should be fixed)
declare let Notification: any;
Notification.requestPermission()
const notify = (msg: IMessage) => {
const options = {
body: msg.text,
icon: msg.user.iconUrl,
}
return new Notification(`New Mes... | import {thread} from "./thread";
import {IMessage} from "../../common/data";
// workaround (should be fixed)
declare let Notification: any;
if (window["Notification"]) {
Notification.requestPermission()
const notify = (msg: IMessage) => {
const options = {
body: msg.text,
icon: msg.user.iconUrl,
... | Use Notification only if available | Use Notification only if available
| TypeScript | mit | sketchglass/respass,sketchglass/respass,sketchglass/respass,sketchglass/respass | ---
+++
@@ -4,21 +4,20 @@
// workaround (should be fixed)
declare let Notification: any;
+if (window["Notification"]) {
+ Notification.requestPermission()
-Notification.requestPermission()
+ const notify = (msg: IMessage) => {
+ const options = {
+ body: msg.text,
+ icon: msg.user.iconUrl,
+ }... |
97df88ae6dbb04158a4d1415363126465e700cc7 | src/app/modules/embed/embedded-video/embedded-video.component.ts | src/app/modules/embed/embedded-video/embedded-video.component.ts | import { ChangeDetectorRef, Component, OnInit } from '@angular/core';
import { ActivatedRoute } from '@angular/router';
import { Subscription } from 'rxjs';
@Component({
selector: 'm-embedded-video',
templateUrl: './embedded-video.component.html',
})
export class EmbeddedVideoComponent implements OnInit {
guid: ... | import { ChangeDetectorRef, Component, OnInit } from '@angular/core';
import { ActivatedRoute } from '@angular/router';
import { Subscription } from 'rxjs';
@Component({
selector: 'm-embedded-video',
templateUrl: './embedded-video.component.html',
})
export class EmbeddedVideoComponent implements OnInit {
guid: ... | Set embedded video autoplay to false by default | Set embedded video autoplay to false by default | TypeScript | agpl-3.0 | Minds/front,Minds/front,Minds/front,Minds/front | ---
+++
@@ -20,7 +20,7 @@
ngOnInit() {
this.queryParamsSubscription$ = this.activatedRoute.queryParamMap.subscribe(
params => {
- this.autoplay = !!params.get('autoplay') || true;
+ this.autoplay = !!params.get('autoplay') || false;
this.detectChanges();
}
); |
f27c67f0b7c050ecb2190f3533dad45a940f24a9 | packages/editor/src/mode/ipython.ts | packages/editor/src/mode/ipython.ts | // https://github.com/nteract/nteract/issues/389
import CodeMirror, { EditorConfiguration, Mode } from "codemirror";
import "codemirror/mode/meta";
import "codemirror/mode/python/python";
// The TypeScript definitions are missing these versions
// of the codemirror define* functions that IPython uses for
// highlight... | // https://github.com/nteract/nteract/issues/389
import CodeMirror, { EditorConfiguration, Mode } from "codemirror";
import "codemirror/mode/meta";
import "codemirror/mode/python/python";
CodeMirror.defineMode(
"ipython",
(conf, parserConf) => {
const ipythonConf = Object.assign({}, parserConf, {
name: ... | Remove outdated comment; remove explicit typing (inferred works fine here); fix editor warnings | Remove outdated comment; remove explicit typing (inferred works fine here); fix editor warnings
| TypeScript | bsd-3-clause | nteract/composition,nteract/nteract,nteract/composition,nteract/nteract,nteract/nteract,nteract/composition,nteract/nteract,nteract/nteract | ---
+++
@@ -4,16 +4,12 @@
import "codemirror/mode/meta";
import "codemirror/mode/python/python";
-// The TypeScript definitions are missing these versions
-// of the codemirror define* functions that IPython uses for
-// highlighting magics
-// @ts-ignore
CodeMirror.defineMode(
"ipython",
- (conf: EditorConf... |
ce66f17eeb226e31a0239e1ad96b33e980f71411 | src/errors/unfulfilledMembersRequirementsError.ts | src/errors/unfulfilledMembersRequirementsError.ts | import { BaseError } from './baseError'
import { AliasMetadataMember } from '../aliasMetadataMember'
/**
* Represents an error triggered when a cyclic dependency has been identified.
*/
export class UnfulfilledMembersRequirementsError extends BaseError {
public unfulfilledMembers: AliasMetadataMember[]
constru... | import { BaseError } from './baseError'
import { AliasMetadataMember } from '../aliasMetadataMember'
/**
* Represents an error triggered when one or many alias metadata members requirements are unfulfilled.
*/
export class UnfulfilledMembersRequirementsError extends BaseError {
public unfulfilledMembers: AliasMet... | Fix on the class description. | Fix on the class description.
| TypeScript | mit | JemsFramework/di,JemsFramework/di | ---
+++
@@ -2,7 +2,7 @@
import { AliasMetadataMember } from '../aliasMetadataMember'
/**
- * Represents an error triggered when a cyclic dependency has been identified.
+ * Represents an error triggered when one or many alias metadata members requirements are unfulfilled.
*/
export class UnfulfilledMembersRequ... |
871033db70e7f095765116ab00cd51a1ee2a4822 | client/sharedClasses/question.ts | client/sharedClasses/question.ts | import { Answer } from './answer';
export class Question {
id: number;
qno: number
correct_ans_no: number;
question_time: number;
paper_id: number;
subject_id: number;
is_image: boolean;
image_url: string;
question: string;
answers: Answer[];
} | import { Answer } from './answer';
export class Question {
id: number;
qno: number
correct_ans_no: number;
question_time: number;
paper_id: number;
subject_id: number;
is_image: boolean;
image_url: string;
question: string;
answers: Answer[];
selectedAnswerNo: number;
} | Add support to save user selected answer | Add support to save user selected answer
| TypeScript | mit | shavindraSN/examen,shavindraSN/examen,shavindraSN/examen | ---
+++
@@ -11,4 +11,5 @@
image_url: string;
question: string;
answers: Answer[];
+ selectedAnswerNo: number;
} |
47058cd40d0fe1b42c05c8f6be197e7ff37511ba | source/filters/filter.ts | source/filters/filter.ts | module rl.utilities.filters {
'use strict';
export var moduleName: string = 'rl.utilities.filter';
export interface IFilterWithCounts extends IFilter {
updateOptionCounts<TItemType>(data: TItemType[]): void;
}
export interface IFilter {
type: string;
filter<TItemType>(item: TItemType): boolean;
}
}
| module rl.utilities.filters {
'use strict';
export interface IFilterWithCounts extends IFilter {
updateOptionCounts<TItemType>(data: TItemType[]): void;
}
export interface IFilter {
type: string;
filter<TItemType>(item: TItemType): boolean;
}
}
| Remove unused / unnecessary variable. | Remove unused / unnecessary variable.
| TypeScript | mit | SamGraber/TypeScript-Angular-Utilities,SamGraber/TypeScript-Angular-Utilities,RenovoSolutions/TypeScript-Angular-Utilities,RenovoSolutions/TypeScript-Angular-Utilities | ---
+++
@@ -1,7 +1,5 @@
module rl.utilities.filters {
'use strict';
-
- export var moduleName: string = 'rl.utilities.filter';
export interface IFilterWithCounts extends IFilter {
updateOptionCounts<TItemType>(data: TItemType[]): void; |
6cd9fd6a7429f8edd47564e4ab17a1b90a7474cb | components/compositions/dialogs/overwrite-dialog.component.ts | components/compositions/dialogs/overwrite-dialog.component.ts | import {Component, ViewRef} from '@angular/core';
import {HsCompositionsService} from '../compositions.service';
import {HsDialogComponent} from '../../layout/dialogs/dialog-component.interface';
import {HsDialogContainerService} from '../../layout/dialogs/dialog-container.service';
@Component({
selector: 'hs.composi... | import {Component, ViewRef} from '@angular/core';
import {HsCompositionsService} from '../compositions.service';
import {HsDialogComponent} from '../../layout/dialogs/dialog-component.interface';
import {HsDialogContainerService} from '../../layout/dialogs/dialog-container.service';
import {HsSaveMapManagerService} fro... | Add save function in compositions overwrite dialog | Add save function in compositions overwrite dialog
| TypeScript | mit | hslayers/hslayers-ng,hslayers/hslayers-ng,hslayers/hslayers-ng,hslayers/hslayers-ng | ---
+++
@@ -2,6 +2,7 @@
import {HsCompositionsService} from '../compositions.service';
import {HsDialogComponent} from '../../layout/dialogs/dialog-component.interface';
import {HsDialogContainerService} from '../../layout/dialogs/dialog-container.service';
+import {HsSaveMapManagerService} from '../../save-map/sa... |
9219ebea7c36ea6fc901535aa334d1063c3aab5d | resources/assets/lib/osu-layzr.ts | resources/assets/lib/osu-layzr.ts | // Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the GNU Affero General Public License v3.0.
// See the LICENCE file in the repository root for full licence text.
import Layzr, { LayzrInstance } from 'layzr';
export default class OsuLayzr {
private layzr?: LayzrInstance;
private observer: MutationObs... | // Copyright (c) ppy Pty Ltd <contact@ppy.sh>. Licensed under the GNU Affero General Public License v3.0.
// See the LICENCE file in the repository root for full licence text.
import Layzr, { LayzrInstance } from 'layzr';
export default class OsuLayzr {
private layzr?: LayzrInstance;
private observer: MutationObs... | Reduce image lazy-loading related works | Reduce image lazy-loading related works
| TypeScript | agpl-3.0 | LiquidPL/osu-web,ppy/osu-web,notbakaneko/osu-web,nanaya/osu-web,notbakaneko/osu-web,LiquidPL/osu-web,notbakaneko/osu-web,ppy/osu-web,nanaya/osu-web,LiquidPL/osu-web,nanaya/osu-web,ppy/osu-web,notbakaneko/osu-web,notbakaneko/osu-web,ppy/osu-web,nanaya/osu-web,LiquidPL/osu-web,ppy/osu-web,nanaya/osu-web,LiquidPL/osu-web | ---
+++
@@ -8,19 +8,31 @@
private observer: MutationObserver;
constructor() {
- this.observer = new MutationObserver(this.reinit);
+ this.observer = new MutationObserver(this.observePage);
+ this.observer.observe(document, { childList: true, subtree: true });
- $(document).on('turbolinks:load', ... |
7a355a7940026df45c914d26d88d669a147f185f | src/main/ts/ephox/bridge/components/dialog/ImageTools.ts | src/main/ts/ephox/bridge/components/dialog/ImageTools.ts | import { ValueSchema, FieldSchema, FieldProcessorAdt } from '@ephox/boulder';
import { Result } from '@ephox/katamari';
import { FormComponent, FormComponentApi, formComponentFields } from './FormComponent';
import { Blob } from '@ephox/dom-globals';
export interface ImageToolsState {
blob: Blob;
url: string;
};
... | import { ValueSchema, FieldSchema, FieldProcessorAdt } from '@ephox/boulder';
import { Result } from '@ephox/katamari';
import { FormComponent, FormComponentApi, formComponentFields } from './FormComponent';
import { Blob } from '@ephox/dom-globals';
export interface ImageToolsState {
blob: Blob;
url: string;
};
... | Extend value requirements for imagetools currentState property | TINY-2603: Extend value requirements for imagetools currentState property
| TypeScript | lgpl-2.1 | TeamupCom/tinymce,FernCreek/tinymce,tinymce/tinymce,FernCreek/tinymce,tinymce/tinymce,TeamupCom/tinymce,tinymce/tinymce,FernCreek/tinymce | ---
+++
@@ -19,7 +19,10 @@
}
export const imageToolsFields: FieldProcessorAdt[] = formComponentFields.concat([
- FieldSchema.strict('currentState')
+ FieldSchema.strictOf('currentState', ValueSchema.objOf([
+ FieldSchema.strict('blob'),
+ FieldSchema.strictString('url')
+ ]))
]);
export const imageTo... |
21d316f8221e49395de691fb47965e4eda625aea | src/app/model/warbandVault.model.ts | src/app/model/warbandVault.model.ts | import { Minion } from './minion.model';
///This is a repo class for the various minions that can be hired for a warband.
export class EquipmentVault {
public static items = new Array<Minion>();
constructor(){
}
static loadMinionTemplatesIntoVault(){
var minion = new Minion('War Dog');
minion.move... | import { Minion } from './minion.model';
///This is a repo class for the various minions that can be hired for a warband.
export class WarbandVault {
public static templates = new Array<Minion>();
constructor(){
}
static loadMinionTemplatesIntoVault(){
var minion = new Minion('War Dog');
minion.mo... | FIx for copy paste errors | FIx for copy paste errors
copied from another class and forgot to rename the required properties
| TypeScript | mit | ChargerIIC/Frostgrave-WarRoster,ChargerIIC/Frostgrave-WarRoster,ChargerIIC/Frostgrave-WarRoster | ---
+++
@@ -1,9 +1,9 @@
import { Minion } from './minion.model';
///This is a repo class for the various minions that can be hired for a warband.
-export class EquipmentVault {
+export class WarbandVault {
- public static items = new Array<Minion>();
+ public static templates = new Array<Minion>();
con... |
2ec048ca71b7a9e7f9f18eff7cc32a186576a1ec | types/scryptsy/scryptsy-tests.ts | types/scryptsy/scryptsy-tests.ts | import * as scrypt from 'scryptsy';
const key = 'TheKey';
const salt = 'Salty';
// Test without processCallback
const data: Buffer = scrypt(key, salt, 16384, 8, 1, 64);
// Test with processCallback
scrypt(key, salt, 16384, 8, 1, 64, (status) => {
status.current;
status.total;
status.percent;
});
| import scrypt = require('scryptsy');
const key = 'TheKey';
const salt = 'Salty';
// Test without processCallback
const data: Buffer = scrypt(key, salt, 16384, 8, 1, 64);
// Test with processCallback
scrypt(key, salt, 16384, 8, 1, 64, (status) => {
status.current;
status.total;
status.percent;
});
| Change import statement in test file | [@types/scryptsy] Change import statement in test file
| TypeScript | mit | georgemarshall/DefinitelyTyped,arusakov/DefinitelyTyped,one-pieces/DefinitelyTyped,alexdresko/DefinitelyTyped,zuzusik/DefinitelyTyped,borisyankov/DefinitelyTyped,arusakov/DefinitelyTyped,chrootsu/DefinitelyTyped,laurentiustamate94/DefinitelyTyped,AgentME/DefinitelyTyped,georgemarshall/DefinitelyTyped,georgemarshall/Def... | ---
+++
@@ -1,4 +1,4 @@
-import * as scrypt from 'scryptsy';
+import scrypt = require('scryptsy');
const key = 'TheKey';
const salt = 'Salty'; |
df3849a2c2ecc787fc2e3c6b4f51917e26868cfe | src/customer/AccountingRunningField.tsx | src/customer/AccountingRunningField.tsx | import * as React from 'react';
import Select from 'react-select';
import { Field } from 'redux-form';
import { translate } from '@waldur/i18n';
export const getOptions = () => [
{ value: null, label: translate('All') },
{ value: true, label: translate('Running accounting') },
{ value: false, label: translate('... | import * as React from 'react';
import Select from 'react-select';
import { Field } from 'redux-form';
import { translate } from '@waldur/i18n';
export const getOptions = () => [
{ value: true, label: translate('Running accounting') },
{ value: false, label: translate('Not running accounting') },
{ value: null,... | Make "Running accounting" default value for a filter in Financial overview | Make "Running accounting" default value for a filter in Financial overview [WAL-2927] | TypeScript | mit | opennode/waldur-homeport,opennode/waldur-homeport,opennode/waldur-homeport,opennode/waldur-homeport | ---
+++
@@ -5,9 +5,9 @@
import { translate } from '@waldur/i18n';
export const getOptions = () => [
- { value: null, label: translate('All') },
{ value: true, label: translate('Running accounting') },
{ value: false, label: translate('Not running accounting') },
+ { value: null, label: translate('All') },... |
36198de92382d3d4cea8c5e3bffb525dc65bac1f | scraper/config.ts | scraper/config.ts | export default {
baseUrl: "http://127.0.0.1:8080",
htmlToText: {
ignoreHref: true,
wordwrap: 500
}
}
| export default {
baseUrl: "https://lua-api.factorio.com/latest/",
htmlToText: {
ignoreHref: true,
wordwrap: 500
}
}
| Update to reference official url | Update to reference official url
| TypeScript | mit | simonvizzini/vscode-factorio-lua-api-autocomplete | ---
+++
@@ -1,5 +1,5 @@
export default {
- baseUrl: "http://127.0.0.1:8080",
+ baseUrl: "https://lua-api.factorio.com/latest/",
htmlToText: {
ignoreHref: true,
wordwrap: 500 |
fd6a681228d4fee2777ac843de5a9f237ddaea65 | src/components/Header/Header.tsx | src/components/Header/Header.tsx | import { Link, ThemeSwitch, Heading, TwitterFollowButton } from 'src/components'
import styles from './Header.module.scss'
export interface Props {
searchEngineTitle?: string
title: string
subtitle?: string
backButton?: boolean
}
const Header: React.FC<Props> = ({
searchEngineTitle,
title,
subtitle,
... | import { Link, ThemeSwitch, Heading, TwitterFollowButton } from 'src/components'
import styles from './Header.module.scss'
export interface Props {
searchEngineTitle?: string
title: string
subtitle?: string
backButton?: boolean
}
const Header: React.FC<Props> = ({
searchEngineTitle,
title,
subtitle,
... | Change how hidden title works for SEO | Change how hidden title works for SEO
| TypeScript | mit | tech-conferences/confs.tech,tech-conferences/confs.tech,tech-conferences/confs.tech | ---
+++
@@ -19,10 +19,12 @@
<header className={styles.Header}>
<div className={styles.Title}>
<hgroup>
- <h1 aria-hidden='true' className='visuallyHidden'>
- {searchEngineTitle || title}
- </h1>
- <Heading element='h1'>{title}</Heading>
+ <Heading el... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.