text stringlengths 3.08k 15.5k |
|---|
import fs from "fs";
import path from "path";
import http from "http";
import httpProxy from "http-proxy";
const proxyApp = httpProxy.createProxyServer({ autoRewrite: true });
const proxyApi = httpProxy.createProxyServer({ autoRewrite: true });
const proxyAuth = httpProxy.createProxyServer({ autoRewrite: false });
impo... |
<gh_stars>0
import { bubbleSort } from '../services/algorithm-implementations/bubble-sort';
import { heapSort } from '../services/algorithm-implementations/heap-sort';
import { insertionSort } from '../services/algorithm-implementations/insertion-sort';
import { introsort } from '../services/algorithm-implementations/i... |
// generated from terraform resource schema
import { Construct } from 'constructs';
import * as cdktf from 'cdktf';
/**
* AWS Elastic Kubernetes Service
*/
export interface DataAwsEksClusterConfig extends cdktf.TerraformMetaArguments {
/**
* Docs at Terraform Registry: {@link https://www.terraform.io/docs/provide... |
import { parse, walk } from 'svelte/compiler'
import { PreprocessorGroup } from 'svelte/types/compiler/preprocess'
import MagicString from 'magic-string'
export interface ImportAssetsOptions {
sources?: AssetSource[] | ((defaultSources: AssetSource[]) => AssetSource[])
importPrefix?: string
http?: boolean
urlF... |
/* Contains code to generate the abandoned fort. */
import {FactoryBase} from '../src/factory';
import {FactoryItem} from '../src/factory.items';
import {FactoryLevel} from '../src/factory.level';
import {ObjectShell} from '../src/objectshellparser';
import {Path} from '../src/path';
import {Builder} from '../src/buil... |
import { ServerType } from './typings';
import type { Config, DiscordConfig } from './typings';
// Discord bot configuration (optional)
export const discordConfig: DiscordConfig = {
// A bot token for Discord, obtained from https://discord.com/developers/applications
token: 'DISCORD_BOT_TOKEN_HERE',
// The prefix t... |
// This file contains a lot of functions that are called from GameRoom.ts
// These function contain game logic and other helper code. Its shortened to 'glf'
// There is a lot of debugging logging code in these functions
import { State, Player } from './State';
// This is called every time when the player sends a mess... |
import './style.less';
import { assign, isDOM } from '../utils/index';
interface Options {
baseNode: HTMLElement | null;
pageControl: number;
containerCN: string;
listCN: string;
activeListCN: string;
prevBtnCN: string;
nextBtnCN: string;
disableBtnCN: string;
pageNumCN: string;
preText: string;
... |
import Pusher from 'pusher-js'
import { Data, WithChannelName } from './models/base'
import {
PlushieBindEventCallbacksOptions,
PlushieEvent,
PlushieEventBinding,
PlushieEventBindingScoped,
PlushieEventQueueTriggerCallback,
PlushieEventScoped,
} from './models/event'
export * from './models/base'
export *... |
import { createSlice, PayloadAction } from '@reduxjs/toolkit';
import { AppThunk } from '7-app/types';
import { PersonalityArray } from '1-game-code/ncomponents/PersonalityCmpt';
import apiClient from '3-frontend-api/ApiClient';
import { createCharacter } from '1-game-code/CharacterCreation/CharacterCreationSys';
impor... |
<gh_stars>0
import {getCurrentSelectorContext, Observer, setCurrentSelectorContext} from "./Observer";
import {ProxyTarget, Target} from "./proxyObserve";
/* Memoization is an object that memoizes a particular instance of a function, either a getter
or a function with arguments.
It creates an observer to monito... |
<reponame>ciuliot/github-tracker
/// <reference path='../../interfaces/node/node.d.ts'/>
/// <reference path='../../interfaces/locomotive/locomotive.d.ts'/>
/// <reference path='../../interfaces/log4js/log4js.d.ts'/>
/// <reference path='../../interfaces/async/async.d.ts'/>
/// <reference path='../../interfaces/socket.... |
import {Server} from 'http';
import * as https from 'https';
import * as queryString from 'query-string';
//@ts-ignore
import * as koa from 'koa';
//@ts-ignore
import * as cors from 'koa-cors';
//@ts-ignore
import * as koaBody from 'koa-bodyparser';
//@ts-ignore
import * as deepEquals from 'deep-equal';
//@ts-ignore
im... |
<reponame>sitedata/glo-web-clipper<gh_stars>1-10
// tslint:disable no-implicit-dependencies
import * as execa from 'execa';
import * as fs from 'fs-extra';
import * as got from 'got';
import * as path from 'path';
import * as vm from 'vm';
function findDeep(obj: any, key: string, results: any[] = []): any[] {
Objec... |
import {Component, SimpleChanges, Input, Output, EventEmitter, OnChanges, ChangeDetectionStrategy} from '@angular/core';
import {formatLabel} from '../../utils/label.helper';
import {ColorHelper} from '../../utils/color.helper';
import {IChartData} from '../../chart.interface';
import {getTooltipLabeledText} from '../t... |
import { Color, Palette, PaletteHue } from "@apptane/react-ui-core";
import {
interpolateBlues,
interpolateBrBG,
interpolateBuGn,
interpolateBuPu,
interpolateCividis,
interpolateCool,
interpolateCubehelixDefault,
interpolateGnBu,
interpolateGreens,
interpolateGreys,
interpolateInferno,
interpola... |
/*
* Copyright (c) 2020 Universidad de Pinar del Río "<NAME>"
* All rights reserved.
*/
import { Component, OnInit, Input } from '@angular/core';
import { FilterComponent } from '../filter.component';
import { FiltersService } from '../filters.service';
import { FilterContainerService } from '../filter-contai... |
import * as fs from 'fs';
import * as commander from 'commander';
import { Util, CompletionConfig } from '@travetto/cli/src/util';
import { handleFailure, CachedAppConfig } from './lib/util';
import { AppListUtil } from './lib/app-list';
import { RunUtil } from './lib/run';
const { colorize } = Util;
interface AppC... |
import 'jest';
import { createAggregateRoot } from './AggregateRoot';
import { createCommand } from './Command';
import { DomainError, UnknownCommandError, UnknownEventError } from './errors';
import { createEvent } from './Event';
import { IAggregateDefinition } from './interfaces';
interface ICounter {
value: numb... |
import {
ryzomCodeParser,
IRyzomMessage,
IRGBA,
ryzomColorCodeToRGBA,
RGBAToRyzomColorCode,
} from './ryzom-code';
import ClipboardJS from 'clipboard';
import * as AColorPicker from 'a-color-picker';
import { predefinedPalette } from './palette';
import './app.scss';
interface IMessage {
text: string;
s... |
import * as React from 'react';
import { Modal, Form, Row, Input, Select, InputNumber, notification, Switch } from 'component/antd';
import { modal } from 'store/modal';
import { cluster } from 'store/cluster';
import { adminCreateTopic, modifyTopic } from 'lib/api';
import { ITopic, IValueLabel } from 'types/base-type... |
// ----------------------------------------------------------------------------
// Copyright (c) Microsoft Corporation. All rights reserved.
// ----------------------------------------------------------------------------
import { CodeAction, CodeActionContext, CodeLens, Command, Position, Range, Selection, Uri } from... |
<gh_stars>1-10
import { version } from "vue"
import { isMac } from "../utils/system"
const en = {
view: {
empty_text: "No Data",
explore: {
log_view_btn_text: "log",
log_rule_view_btn_text: "log rule",
log_explore: {
title: "log",
searcher_placeholder: "search log",
... |
<filename>src/app/pages/map/map.component.ts<gh_stars>0
import { Component, OnInit } from '@angular/core';
import { Router } from '@angular/router';
import { FitbitService } from '../../@core/utils/fitbit.service';
import * as tcxParse from 'tcx';
import * as dayjs from 'dayjs';
// import { } from 'environments/'
@C... |
<gh_stars>0
import { BrowserModule } from '@angular/platform-browser';
import { HttpClientModule } from '@angular/common/http';
import { AngularFireModule } from '@angular/fire';
import { AngularFireAuthModule } from '@angular/fire/auth';
import { AngularFirestoreModule, AngularFirestore } from '@angular/fire/firestore... |
import axios from "axios";
import cheerio from "cheerio";
import Logger from "../utils/logger";
import userAgent from "../config/userAgent.json";
import { IPetitionItem, IPetitionList, IPetitionListParam } from "../types/petitions.types";
import Paginate from "../utils/paginate";
import { isNil, omitBy } from "lodash";... |
import FormData from "form-data";
import { AuthLevel, TwoFactorMode } from "./enums";
import { FileCookieStore } from "tough-cookie-file-store";
import { CookieJar } from "tough-cookie";
import got from "got";
const debug = require("debug")("personalcapital");
export class PersonalCapital {
authLevel: AuthLevel = Au... |
import { Scale } from "@theme-ui/css/src/types"
import * as CSS from "csstype"
import { ColorModesScale, Theme } from "theme-ui"
import {
Colors,
MediaQuery,
ScreenBreakpoint,
SpaceAlias,
Variants,
} from "./theme.types"
const space: Array<number | string> = [
0,
"0.25em",
"0.5em",
"1em",
"1.5em",
... |
import {
LanguagesLabel,
CertificationsLabel,
MediasLabel,
TerritoriesLabel,
GenresLabel,
GENRES_LABEL,
LanguagesSlug,
GenresSlug,
GENRES_SLUG,
CertificationsSlug,
CERTIFICATIONS_SLUG,
MediasSlug,
MEDIAS_SLUG,
TerritoriesSlug,
TERRITORIES_SLUG
} from '@blockframes/movie/movie/static-model/... |
<filename>AutoChess/assets/Script/Gui/UIGameMain.ts
import { g_UserData } from "../Data/UserData";
import { g_RoomData } from "../Data/RoomData";
import { GameWorsConfig } from "../Config/GameWordsConfig";
import { g_UIManager } from "./UIManager";
import UICardPool from "./UICardPool";
import { BattleInfo, LayoutInfo ... |
<gh_stars>1-10
import { BrowserModule } from '@angular/platform-browser';
import { NgModule } from '@angular/core';
import { AppComponent } from './app.component';
import { SimulationControlComponent } from './simulation-control/simulation-control.component';
import { ChartViewComponent } from './chart-view/chart-view.... |
import { Service } from 'feathers-sequelize'
import Eth from 'web3-eth'
import { AbiItem } from 'web3-utils'
import config from 'config'
import { EventData } from 'web3-eth-contract'
import { getObject } from 'sequelize-store'
import { Application, CachedService, ServiceAddresses } from '../../definitions'
import { lo... |
<reponame>zburke/isBinaryFile
import * as fs from 'fs';
import { promisify } from 'util';
const statAsync = promisify(fs.stat);
const openAsync = promisify(fs.open);
const closeAsync = promisify(fs.close);
const MAX_BYTES = 512;
// A very basic non-exception raising reader. Read bytes and
// at the end use hasError(... |
<gh_stars>1-10
import { Component, OnInit } from '@angular/core';
import { WalletService } from '../../services/wallet.service';
import { NotificationService } from '../../services/notification.service';
import { ModalService } from '../../services/modal.service';
import { ApiService } from '../../services/api.service'... |
import type { ArrayLikeIterable, Fn, NumericArray } from "@thi.ng/api";
import { implementsFunction } from "@thi.ng/checks/implements-function";
import { isArrayLike } from "@thi.ng/checks/is-arraylike";
import { isNumber } from "@thi.ng/checks/is-number";
import { isString } from "@thi.ng/checks/is-string";
import { i... |
<reponame>KallynGowdy/RxUI
import {Observable, Subject , Subscription} from "rxjs/Rx";
import {Scheduler} from "rxjs/Scheduler";
import {RxApp} from "./rx-app";
// Implementation mostly stolen from:
// https://github.com/reactiveui/ReactiveUI/blob/rxui7-master/ReactiveUI/ReactiveCommand.cs
// All credit goes to those ... |
import { Vec3, Lifetime } from '../core';
import { SsObject } from './SsObject';
import { SsValue } from './SsValue';
import { SsRequest, SsRequestType } from './SsRequest';
import { SsSession } from './SsSession';
import { SsRTCSession } from './SsRTCSession';
import { SsWebSocketSession } from './SsWebSocketSessio... |
import React, { useState, useEffect } from "react";
import {
Currency,
Validation as ValidationInterface,
PriceStatus,
SwapStatus,
} from "../../store/models";
import useValidation from "../../hooks/Validation.hook";
import useSwap from "../../hooks/Swap.hook";
import {
formatLocal,
formatCurrency,
countD... |
import { DocumentData, DocumentReference, FirestoreError } from '@firebase/firestore-types';
import Avatar from '@material-ui/core/Avatar';
import classnames from 'classnames';
import React, { FC, Fragment, MouseEvent, useCallback, useContext, useEffect, useState } from 'react';
import { Link } from 'react-router-dom';... |
import React, { useState, useEffect, useRef } from 'react'
import Logo from '../components/Logo'
import Button from '../components/toolbox/form/Button'
import Canvas from '../components/toolbox/misc/Canvas'
import AddProperty from '../assets/svg/onboarding/add_property.svg'
import SignLease from '../assets/svg/onboar... |
<reponame>a10kiloham/firework8s
import {Construct} from 'constructs';
import {App, Chart} from 'cdk8s';
import {Deployment, PersistentVolumeClaim} from './imports/k8s'
export class VarkenChart extends Chart {
constructor(scope: Construct, name: string) {
super(scope, name);
const label = {app: 'va... |
import React, { useState } from 'react';
import Avatar from '@material-ui/core/Avatar';
import Button from '@material-ui/core/Button';
import CssBaseline from '@material-ui/core/CssBaseline';
import TextField from '@material-ui/core/TextField';
import FormControlLabel from '@material-ui/core/FormControlLabel';
import C... |
import React, {SyntheticEvent} from "react";
import {InjectedIntlProps, injectIntl} from "react-intl";
import {Vedleggsobjekt} from "typer/skjemaogvedlegg";
import {Dispatch} from "redux";
import {toggleInnsendingVedlegg, toggleValgtVedleggForSjekkbokser} from "states/reducers/vedlegg";
import {Store} from "typer/store... |
<reponame>airime/barista
/**
* @license
* Copyright 2020 Dynatrace LLC
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless require... |
import {
Basement as Base,
WHITELIST_EXTENSIONS,
BasementOptions,
assert,
GenericObject,
OSSUploadOptions,
OSSUploadHeaders,
OSSUploadHeaderList,
ErrorType,
ErrorName,
ErrorCode,
OSSUploadResponseFormat,
} from '@alicloud/mpserverless-core';
import {
DbService, FileService, AuthService, Functi... |
<filename>packages/nextools/start-preset/src/build.ts<gh_stars>0
import path from 'path'
import { StartPlugin } from '@start/plugin'
import inputFiles from '@start/plugin-input-files'
import sequence from '@start/plugin-sequence'
import env from '@start/plugin-env'
import find from '@start/plugin-find'
import read from... |
import React, { useEffect, ReactNode } from 'react';
import { observer } from 'mobx-react';
import clsx from 'clsx';
import {
CardActionArea,
Divider,
ExpansionPanel,
ExpansionPanelDetails,
ExpansionPanelSummary,
Grid,
makeStyles,
Paper,
Theme,
} from '@material-ui/core';
import { ILoadA... |
<filename>renderer/src/workspace/flow/utils.tsx
import { Flow, Story } from 'last-hit-types';
import { IUIEventEmitter } from '../../common/context';
import { EventTypes } from '../../events';
import { FlowUIStatus, FlowUIStatusEnum, WorkspaceStructure } from '../../types';
const getUIStatusOfFlow = async (
emitter: ... |
import { defineComponent, h, onUnmounted, inject, ref, Ref, provide, onMounted, PropType, createCommentVNode, reactive } from 'vue'
import XEUtils from 'xe-utils'
import GlobalConfig from '../../v-x-e-table/src/conf'
import { VXETable } from '../../v-x-e-table'
import { getFuncText, isEnableConf } from '../../tools/uti... |
// This code is very aggressive about running requests in parallel and does not use
// a task queue, because the quota limits for GCR.io are absurdly high. At the time
// of writing, we can make 50K requests per 10m.
// https://cloud.google.com/container-registry/quotas
import * as clc from "cli-color";
import { cont... |
<reponame>warhog/fpvlaptracker-app
import {Component} from '@angular/core';
import {NavController, ViewController} from 'ionic-angular';
import {ToastController} from 'ionic-angular';
import {BluetoothSerial} from '@ionic-native/bluetooth-serial';
import {Storage} from '@ionic/storage';
import {BluetoothPage} from '../... |
/**
* Copyright 2017 Google Inc. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by appli... |
/* eslint-disable react/jsx-no-bind */
import React from 'react';
import ReactDOM from 'react-dom';
import { IntlProvider } from 'react-intl';
import AnnotationPopup, {
PopupType,
} from '../component/annotation-popup/AnnotationPopup';
import Annotation from '../Annotation';
import { ContentState } from '../Annotator... |
<filename>src/worker/plugins/run.ts
import { PluginEvent } from '@posthog/plugin-scaffold'
import { Hub, PluginConfig, PluginTaskType } from '../../types'
import { processError } from '../../utils/db/error'
export class IllegalOperationError extends Error {
name = 'IllegalOperationError'
constructor(operatio... |
import dayjs from "dayjs";
import utc from "dayjs/plugin/utc";
import { Model } from "../props";
import { logger, sleep } from "../utils";
import { RequestorApi } from "ya-ts-client/dist/ya-market/api";
import * as models from "ya-ts-client/dist/ya-market/src/models";
import { Configuration } from "ya-ts-client/dist/ya... |
// TODO: Converting to wasm using https://docs.assemblyscript.org/
// For Benchmark:
// const ti_activate = window.performance.now() // start parsing
import { CompositeDisposable, Disposable, TextEditor } from "atom"
import { StatusBar } from "atom/status-bar"
import { IndentStatusItem } from "./status"
import { Se... |
<filename>src/util/math.ts
// Much of this adapted from https://www.redblobgames.com/grids/hexagons/
import { RotationInterval } from "../store"
export enum ORIENTATION {
POINTY = 'POINTY',
FLAT = 'FLAT'
}
export function worldToFlatHex(x: number, y: number, radius: number) {
let q = ((2 / 3) * x) / radius
l... |
import * as R from 'ramda';
import { IAttribute } from 'shared/models/Attribute';
import {
getKeyValuePairsDiff,
} from 'shared/utils/collection';
import {
IDatasetVersion,
IRawDatasetVersion,
IQueryDatasetVersion,
IPathBasedDatasetVersion,
IDatasetPathPartInfo,
} from 'shared/models/DatasetVer... |
<filename>src/hooks/useTable/useTableConfig.ts
import { useEffect } from "react";
import { useDebouncedCallback } from "use-debounce";
import _camelCase from "lodash/camelCase";
import _orderBy from "lodash/orderBy";
import _sortBy from "lodash/sortBy";
import useDoc, { DocActions } from "../useDoc";
import { FieldTy... |
<gh_stars>100-1000
import {
Construct, IAspect, IConstruct, Lazy, Stack, Token,
aws_ecr as ecr,
aws_codebuild as codebuild,
aws_events as events,
aws_events_targets as targets,
aws_s3_assets as s3Assets,
aws_secretsmanager as sm,
custom_resources as cr,
} from 'monocdk';
import { MirrorSource } from './... |
import styled from "@emotion/styled"
import axios from "axios"
import Cookies from "js-cookie"
import Image from "next/image"
import React, { useContext, useState } from "react"
import { API_ENDPOINT, MEDIA_QUERY_END_POINT } from "@src/constants"
import { ThemeContext } from "@pages/_app"
import { ThemeProps } from "@s... |
<filename>src/public/js/helper/collisons-functs.ts
import {Drop} from '../../../models/Drop';
import {Player} from '../../../models/Player';
import {delay} from '../../../shared/functions';
import {CustomPlayer, CustomSprite} from '../classes/game-classes';
import {togglePowerup, updateHUDText} from '../HUD';
import {r... |
<reponame>zx648383079/Angular-ZoDream
import {
Component,
ElementRef,
EventEmitter,
Input,
OnChanges,
Output,
QueryList,
SimpleChanges,
ViewChildren
} from '@angular/core';
import { DialogService } from '../../../dialog';
import { IChapter } from '../../model';
import { windowScollTo... |
import BigNumber from "bignumber.js";
// Numeric fields are represented as strings in case any Bitcoin chain has
// txindexes, amounts or heights that can't be represented using a 64-bit float.
export interface UTXO {
txid: string;
txindex: string;
amount: string;
height: string | null;
}
export inter... |
/* eslint-disable @typescript-eslint/member-ordering */
/* eslint-disable @typescript-eslint/no-unsafe-call */
/* eslint-disable @typescript-eslint/no-unsafe-member-access */
/* eslint-disable @typescript-eslint/no-implied-eval */
/* eslint-disable @typescript-eslint/no-unsafe-assignment */
import { BasicPrivateClient,... |
import * as ts from 'typescript';
import { SourceFile } from '../sourceFile';
import { Component } from './component';
import { TypescriptParser } from '../typescriptParser';
import { ConfigParser } from '../configParser';
import { logVerbose } from '../logging';
import { ComponentBinding } from './componentBindi... |
import type { MessageVisibility } from '@src/chat/create-message';
import type { SuperiorResultEffect } from '@src/data-enums';
import type { SourcedEffect, SuccessTestEffect } from '@src/features/effects';
import type { Pool, PreTestPoolAction, ReadonlyPool } from '@src/features/pool';
import { localize } from '@src/f... |
<reponame>illBeRoy/untiled<gh_stars>0
import { observable, action, computed } from 'mobx';
import Jimp from 'jimp';
export type Base64EncodedImage = string;
export type TileId = number;
export interface Document {
tileSize: number;
tileSet: TileSet;
tileMap: TileMap;
}
export interface TileSet {
width: numbe... |
import puppeteer, { ElementHandle } from 'puppeteer';
import * as path from 'path';
import { IAffiliate } from '../../../../types/__project_defs/IAffiliate';
import { generateCPF } from '@brazilian-utils/brazilian-utils';
import { initBrowserWithAdmin, integrationTestTimeout } from '../../../testUtils/appTestUtils';
im... |
<gh_stars>1-10
import * as localForage from "localforage";
import InMemoryCache from "../../util/InMemoryCache";
import {AppUrls} from "../../Constants";
import {Observable, Subject} from "rxjs";
import {RawWanikaniReviewPage} from "../models/raw/RawWanikaniReview";
// @ts-ignore
const memoryCache = new InMemoryCache<... |
<reponame>VeryCrazyDog/level-logger
import util from 'util'
const TIMESTAMP_SYMBOL: unique symbol = Symbol('timestamp')
const ISO_TIMESTAMP_SYMBOL: unique symbol = Symbol('iso-timestamp')
const MESSAGE_LEVEL_SYMBOL: unique symbol = Symbol('message-level')
export type MessageLevel = 'trace' | 'debug' | 'info' | 'warn'... |
import './Swap.less';
import { AssetInfo } from '@ergolabs/ergo-sdk/build/main/entities/assetInfo';
import { maxBy } from 'lodash';
import React, { useEffect, useMemo } from 'react';
import { useTranslation } from 'react-i18next';
import {
BehaviorSubject,
combineLatest,
debounceTime,
distinctUntilChanged,
f... |
<filename>src/js/ts/js/src/PlayingData.ts
class PlayingData extends AbstractSoundData {
private currentPosition: number;
private registerSoundData: RegisteredSoundData;
private playingStatus: PlayingStatus;
private slicedArray: Float32Array;
private playingTimeByLoop: number;
private bufferArra... |
// Copyright 2016-2019, Pulumi Corporation.
//
// 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... |
<filename>src/app/+run-tale/run-tale/modals/select-data-dialog/select-data-dialog.component.ts
import { Component, Inject, NgZone, OnInit } from '@angular/core';
import { MAT_DIALOG_DATA } from '@angular/material/dialog';
import { Dataset } from '@api/models/dataset';
import { Tale } from '@api/models/tale';
import... |
import { ChangeEvent, MouseEvent, useCallback, useEffect, useState } from 'react';
import { Link, useHistory, useLocation } from 'react-router-dom';
import {
Alert,
Button,
Container,
IconButton,
InputAdornment,
styled,
TextField,
Typography,
} from '@mui/material';
import makeStyles from '@mui/styles/m... |
import { IParameterSpec, ITypeSpec, convertGeneric, convertParameter } from "./typeSpec";
import { escapeForDoubleQuotedString } from "../cpp/escape";
import { apiNames } from "./apiNames";
export interface IMethodSpec {
/**
* The API ID.
*/
apiId: string;
/**
* The friendly name of the API.
*/
ap... |
import { SQS } from 'aws-sdk';
import { assert } from 'chai';
import * as pEvent from 'p-event';
import * as sinon from 'sinon';
import { Consumer, AwsQueueProvider } from '../src/index';
const sandbox = sinon.createSandbox();
const AUTHENTICATION_ERROR_TIMEOUT = 20;
function stubResolve(value?: any): any {
retur... |
import React, { useState, useEffect, useReducer } from "react";
import {
Contract,
createContract,
deleteContract,
getContractList,
getCountractCount,
updateContract,
} from "../../api";
import { useDebounce } from "use-debounce";
import { Modal } from "../../components/modal";
import { NetworkSelector } fr... |
import React from 'react';
import { FormattedMessage } from 'umi';
import { Row, Col, Card, Form, Slider, InputNumber, Select, Radio, Button, Spin } from 'antd';
import { CaretRightOutlined, CaretDownOutlined } from '@ant-design/icons';
import debounce from 'lodash/debounce';
import IndividualOutput from './components... |
import { EvaluatorNode } from '@openmsupply/expression-evaluator/lib/types'
import React, { useEffect, useState } from 'react'
import { Modal, Label, Icon, Header } from 'semantic-ui-react'
import { pluginProvider } from '../../../../formElementPlugins'
import { TemplateElement, TemplateElementCategory } from '../../..... |
<reponame>hikerpig/dagre-layout<gh_stars>1-10
import * as _ from './util-lodash'
import { Graph } from '@pintora/graphlib'
import { DagreGraph, DNode } from './type'
export { Graph }
/*
* Adds a dummy node to the graph and return v.
*/
export function addDummyNode(g: DagreGraph, type: string, attrs: any, name: stri... |
import { builtinModules } from 'module'
import * as vite from 'vite'
import { uniq, hashId } from './utils'
interface TransformChunk {
id: string
code: string
deps: string[]
parents: string[]
}
interface SSRTransformResult {
code: string
map: object
deps: string[]
dynamicDeps: string[]
}
async functi... |
/* eslint-disable prefer-rest-params */
import {
CacheManager,
CacheManagerSetOptions,
CACHE_DEPENDENCY_PREFIX_CACHE_KEY,
isNullOrUndefined,
parseJSON,
} from "@anchan828/nest-cache-common";
import { CacheStore, CacheStoreFactory, LiteralObject } from "@nestjs/common";
import * as Redis from "ioredis";
import... |
import { SpawnOptions } from 'child_process'
import { stripPrefix } from '../../common'
import { ExitInformation, touchFiles } from '../../unix'
import { CommandJSONConversionError, runJsonLinesCommand } from '../checks-common'
import { CargoManifestParseError } from './cargo-types'
import { CargoLocateWorkspaceError,... |
<filename>packages/core/src/background/handlers/Tabs.ts
import DotTabs from '@polkadot/extension-base/background/handlers/Tabs';
import {
MessageTypes,
RequestRpcUnsubscribe,
} from '@polkadot/extension-base/background/types';
import { InjectedAccount } from '@polkadot/extension-inject/types';
import { accounts as ... |
<filename>ui/src/scenes/Editor/Monaco/questdb-sql.ts
import * as monaco from "monaco-editor"
import { dataTypes, keywords, functions } from "@questdb/sql-grammar"
enum CompletionItemKind {
Function = 1,
Operator = 11,
Keyword = 17,
}
const operators = [
// Logical
"ALL",
"AND",
"ANY",
"BETWEEN",
"EX... |
import { AlloyType } from '../AlloyTypes';
import { AlloyAtom } from './AlloyAtom';
import { AlloyElement } from './AlloyElement';
import { AlloySignature } from './AlloySignature';
import { AlloyTuple } from './AlloyTuple';
/**
* An Alloy field paired with the ID assigned to it in the instance XML file
*/
interface... |
import { html } from "lit";
import { customElement } from "lit/decorators.js";
import { getElement } from "../../../utils";
import { transitionType } from "../../atom/transition";
import {Base, size } from "../../base";
import { HbList } from "../../molecule/list";
import { HbInput } from "../input";
export interface ... |
/* eslint-disable require-atomic-updates */
/* eslint-disable no-console */
import Chokidar from 'chokidar';
import { resolve } from 'path';
import GanacheCore from 'ganache-core';
import { spawn, ChildProcess } from 'child_process';
import { existsSync } from 'fs';
import { green, blue, red, yellow } from 'chalk';
imp... |
import { runInAction, toJS } from 'mobx'
import {
deepGet,
deepGetAllNumbers,
deepGetWithWilcard,
deepSet,
deep_for_each,
hasProp,
rightPadArray,
} from './helpers'
export type LoaderState = Map<Function, LoaderStateArgs>
// the number value is the currently running functions with these ar... |
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
import * as fsapi from 'fs-extra';
import * as minimatch from 'minimatch';
import * as path from 'path';
import { traceWarning } from '../../../../common/logger';
import { Architecture, getEnvironmentVariable } from '../../... |
import {useMutation} from '@apollo/client';
import {Colors, Switch, Tooltip} from '@blueprintjs/core';
import * as React from 'react';
import {Link} from 'react-router-dom';
import {TickTag} from 'src/jobs/JobTick';
import {RepositoryLink} from 'src/nav/RepositoryLink';
import {PipelineReference} from 'src/pipelines/P... |
export const HD_BITRATE: 2500000;
export const HD_SCALE_FACTOR: 1;
export const LD_SCALE_FACTOR: 4;
export const SD_SCALE_FACTOR: 2;
export const SIM_LAYER_RIDS: string[];
/**
* Handles track related operations on TraceablePeerConnection when browser is
* running in unified plan mode.
*/
export class TPCUtils {
... |
import React, { useState, useCallback, useContext } from 'react';
import axios from 'axios';
import { Dropdown } from '@fluentui/react';
import { EXPERIMENT } from '../../../static/datamodel';
import { toSeconds } from '../../../static/experimentConfig';
import { AppContext } from '../../../App';
import { EditExpeParam... |
import { Component } from '@nestjs/common';
import * as os from 'os';
import * as Consul from 'consul';
import { info, error } from 'winston';
import { environment } from '../../environment';
import * as GError from '@google-cloud/error-reporting';
let errors = { report: (x: any) => {} };
if (environment.envType !== '... |
import { num2hex } from "../util/strings";
/* A dictionary of all command classes as of 2018-03-30 */
export enum CommandClasses {
// "Alarm" = 0x71, // superseded by Notification
"Alarm Sensor" = 0x9c,
"Alarm Silence" = 0x9d,
"All Switch" = 0x27,
"Anti-theft" = 0x5d,
"Application Capability" = 0x57,
"Applicati... |
import {classOf, constructorOf, nameOf, Type} from "@tsed/core";
import {Container, createContainer, getConfiguration, InjectorService, IProvider, setLoggerLevel} from "@tsed/di";
import {
GlobalAcceptMimesMiddleware,
IRoute,
Platform,
PlatformApplication,
PlatformHandler,
PlatformRequest,
PlatformRespons... |
/** @format */
import bulletListIcon from '../../assets/pngicon/bullet_list/2.png'
import vegaIcon from '../../assets/pngicon/chart/2.png'
import codeIcon from '../../assets/pngicon/code/2.png'
import flowchartIcon from '../../assets/pngicon/flowchart/2.png'
import frontMatterIcon from '../../assets/pngicon/front_matt... |
import * as React from 'react';
import { sortable } from '@patternfly/react-table';
import * as _ from 'lodash';
import { useTranslation } from 'react-i18next';
import { match } from 'react-router';
import {
MultiListPage,
Table,
TableData,
Flatten,
RowFunctionArgs,
} from '@console/internal/components/factor... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.