text stringlengths 3.08k 15.5k |
|---|
import { css } from '@emotion/react';
import { joinUrl } from '@root/src/lib/joinUrl';
import { ElementContainer } from '@root/src/web/components/ElementContainer';
import { OnwardsData } from './OnwardsData';
import { OnwardsLayout } from './OnwardsLayout';
// This list is a direct copy from https://github.com/guar... |
<gh_stars>10-100
import fs from "fs-extra";
import path from "path";
import matter from "gray-matter";
import { MatterData, NestedFolder } from "./models";
// Wrapper to flatten and return nested path list as flat array expected by next
export async function getPathList(
folder: any,
ogPath: any,
pageFileCache: ... |
/*
* Copyright 2009 - 2016 <NAME>, <NAME>
*
* 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 app... |
/*---------------------------------------------------------------------------------------------
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
*---------------------------------------------------------------... |
declare var ethers;
import { Component, Element, Prop, State, Watch } from "@stencil/core";
import { RouterHistory } from "@stencil/router";
import CounterfactualTunnel from "../../data/counterfactual";
import { HighRollerAppState, HighRollerStage } from "../../data/game-types";
import { Address, AppInstanceInfo, cf ... |
import { AbortController, AbortSignal } from 'abort-controller'
import { execFile } from 'child_process'
import Semaphore from 'semaphore-async-await'
export interface CommitInfo {
sha1: string
author?: string
authorMail?: string
authorTime?: Date
authorTz?: string
committer?: string
commit... |
import SVGBase from './SVGBase'
import { PortDefinition, SvgData } from '../../types'
/**
* Mapping of characters to numeric digit line.
* The line index follows clockwise starting at the top left,
* with the middle line having index 6.
*
* (1)
* _
* (0) |_| (2)
* (5) |_| (3)
*
* (4)
*
* @type... |
<reponame>sfodje/perlcritic<filename>server/src/server.ts
/* --------------------------------------------------------------------------------------------
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
* ---... |
import * as THREE from 'three';
import { OrbitControls } from 'three/examples/jsm/controls/OrbitControls';
let camera: THREE.PerspectiveCamera;
let scene: THREE.Scene;
let renderer: THREE.WebGLRenderer;
let clock: THREE.Clock;
let dirLight: THREE.DirectionalLight;
let spotLight: THREE.SpotLight;
let torusKnot: THREE.... |
import type { SerializedStyles } from '@emotion/react';
import { css } from '@emotion/react';
import type { RelatedItem } from '@guardian/apps-rendering-api-models/relatedItem';
import type { ArticleFormat } from '@guardian/libs';
import { ArticleDesign, ArticleDisplay } from '@guardian/libs';
import {
from,
headline... |
// package:
// file: list.proto
/* tslint:disable */
/* eslint-disable */
import * as jspb from "google-protobuf";
import * as google_protobuf_timestamp_pb from "google-protobuf/google/protobuf/timestamp_pb";
export class Novels extends jspb.Message {
clearNovelsList(): void;
getNovelsList(): Array<Novel>;... |
/*---------------------------------------------------------------------------------------------
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
*---------------------------------------------------------------... |
/**
* Copyright (c) OpenLens Authors. All rights reserved.
* Licensed under MIT License. See LICENSE in root directory for more information.
*/
import "./pods.scss";
import React, { Fragment } from "react";
import { observer } from "mobx-react";
import { Link } from "react-router-dom";
import { KubeObjectListLayou... |
<gh_stars>0
// Clases creadas para realizar una inserción inicial al sistema
var ePropietario: Propietario = new Propietario('Rodrigo', '71047140W', 5);
var eArrendatario: Arrendatario = new Arrendatario('Hugo', '10661223X', 5);
var aPersonas: Array<Persona> = [ePropietario, eArrendatario];
/**
* Es el la varia... |
<gh_stars>100-1000
import * as sinon from "sinon"
import * as nock from "nock"
import { Probot } from "probot"
const ArgocdBot = require("..")
// test fixtures
const payloadPr1 = require("./fixtures/issue_comment.created.pr1.json")
const payloadPr1Closed = require("./fixtures/pull_request.closed.pr1.json")
const payl... |
<filename>src/js/util.ts<gh_stars>1-10
import * as config from './config';
import FuzzySet from 'fuzzyset.js';
/**
* Function that converts a string to Proper Case.
* @return {string} string with proper case
*/
// eslint-disable-next-line @typescript-eslint/unbound-method
String.prototype.toProperCase = function():... |
import Piece from '../ren/Piece';
import PieceIndex from '../ren/PieceIndex';
import Point from '../ren/Point';
import boardHelper from './boardHelper';
import { PIECE_COLOR_BLACK, PIECE_COLOR_WHITE } from './constant';
// abcdecbaooooooooffffffffoooooooooooooooommmmmmmmoooooooohijlkjih
export type OptionsType = {
... |
import React, {
ForwardedRef,
forwardRef,
MutableRefObject,
ReactNode,
useCallback,
useContext,
useEffect,
useMemo,
useRef,
useState,
} from 'react';
import { SanityDocument } from '@sanity/types';
// @ts-expect-error failed to get TS to accept this import
import sanityClient from 'part:@sanity/base... |
<filename>src/model/ImpositionCompositeColumn.ts
import {suffix, IEventListener} from '../internal/AEventDispatcher';
import {toolbar, SortByDefault} from './annotations';
import Column, {IColumnDesc, widthChanged, labelChanged, metaDataChanged, dirty, dirtyHeader, dirtyValues, rendererTypeChanged, groupRendererChanged... |
import { MULTICHAIN_DECIMAL } from 'multichain-sdk/constants'
import { Amount } from './amount'
import { Percent } from './percent'
import { Pool } from './pool'
export type WithdrawAmount = {
runeAmount: Amount
assetAmount: Amount
}
export interface ILiquidity {
readonly pool: Pool
readonly poolUnits: Amoun... |
import React, { useCallback, useState } from 'react';
import { useTranslation } from 'react-i18next';
import { toast } from 'react-toastify';
import Confirm from 'semantic-ui-react/dist/commonjs/addons/Confirm';
import Button from 'semantic-ui-react/dist/commonjs/elements/Button';
import Icon from 'semantic-ui-react/di... |
import * as path from 'path';
import { PackerOptions } from '../model/packer-options';
import { PackageConfig, PackageKeyValueLiteral } from '../model/package-config';
import { parseLicenseType } from './parser';
import {
name as sourcePackageName,
version as sourcePackageVersion,
devDependencies as sourceDevDe... |
// Copyright (c) Microsoft. All rights reserved.
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
import { CommandBuilder } from "yargs";
import {
EventProcessorHost, OnReceivedMessage, PartitionContext, OnReceivedError
} from "@azure/event-processor-host";
import ... |
import {DataTypes, FindOptions, Sequelize} from "sequelize";
import {QueueType} from "../../task-management/taskSupervisor";
import {BaseModel} from "../baseModel";
export enum ExecutionStatus {
Undefined = 0,
Initializing = 1,
Running = 2,
Zombie = 3, // Was marked initialized/running but can not l... |
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Elastic License;
* you may not use this file except in compliance with the Elastic License.
*/
import cytoscape from 'cytoscape';
import { debounce } from 'lodash';
import ... |
import React, { useState } from 'react';
import { useForm, UseFormProps, FieldValues } from 'react-hook-form';
import _isEmpty from 'lodash/isEmpty';
import {
makeStyles,
createStyles,
useTheme,
useMediaQuery,
Portal,
Dialog,
DialogProps as MuiDialogProps,
DialogTitle,
Typography,
IconButton,
Dia... |
import { Snapshots } from '../types/Snapshots';
const snapshot: Snapshots = {
'freeCodeCamp/freeCodeCamp': {
id: 'freeCodeCamp/freeCodeCamp',
description: 'The https://freeCodeCamp.org open source codebase and curriculum. Learn to code and help nonprofits.',
kStars: 294,
},
'vuejs/vue': {
id: 'vu... |
import { BitcoindClient } from "@node-lightning/bitcoind";
import { ConstantBackoff, RetryPolicy } from "@node-lightning/bitcoind";
import { TxWatcher } from "@node-lightning/chainmon";
import { RocksdbGossipStore } from "@node-lightning/gossip-rocksdb";
import { GraphManager } from "@node-lightning/graph";
import { Gr... |
import Sharp from 'sharp';
import { TileMaker, ImageFormat, TileMakerContext, Composition, TileMakerResizeKernel } from '@basemaps/tiler';
import { Metrics } from '@linzjs/metrics';
import sharp from 'sharp';
function notEmpty<T>(value: T | null | undefined): value is T {
return value != null;
}
export type SharpOve... |
<filename>uui/data/querying/__tests__/getPatternPredicate.test.ts
import { getPatternPredicate } from '../getPatternPredicate';
import { DataQueryFilter } from '../../../types';
interface Person {
name: string;
departmentId: number;
age?: number;
}
const alice = { name: "Alice", departmentId: 1, age: 25 }... |
import { Server } from 'http'
import express = require('express')
import { Express, Request, Response } from 'express'
import cors = require('cors')
import multer = require('multer')
import { urlencoded, json } from 'body-parser'
import { SlowMemoryStorage } from './slow-memory-storage'
import expressJwt = require('exp... |
import * as d3 from 'd3';
import { BoardOptions } from '@core/diagram/board.config';
import { ArchNgPonent } from '@core/arch-ngponent';
import { DiagramLinkableElement } from '@core/diagram-element-linkable';
import { DiagramElementFeature } from '@core/diagram/diagram-definition';
import { ModuleStyleList, Pad... |
<reponame>zhaomenghuan/molecule
import 'reflect-metadata';
import { container } from 'tsyringe';
import { localize } from 'monaco-editor/esm/vs/nls';
import { DisposableStore } from 'monaco-editor/esm/vs/base/common/lifecycle';
import { QuickCommandNLS } from 'monaco-editor/esm/vs/editor/common/standaloneStrings';
imp... |
import { parseLanguageTag, LanguageTag } from '@phensley/language-tag';
import { LanguageResolver, Locale } from '@phensley/locale';
import { getDistance, DEFAULT_THRESHOLD, MAX_DISTANCE } from './distance';
import { paradigmLocales } from './autogen.distance';
// Space and comma-separated bundle ids.
const TAG_SEP =... |
<reponame>csantanapr/iascable
import {default as jsYaml} from 'js-yaml';
import {Container} from 'typescript-ioc';
import deepClone from 'lodash.clonedeep';
import {ModuleSelectorApi} from './module-selector.api';
import {
BillOfMaterial,
BillOfMaterialModel,
BillOfMaterialModule,
Catalog,
CatalogCategoryMod... |
<filename>packages/tsbb/src/babel/index.ts
import path from 'path';
import semver from 'semver';
import { transformFile, BabelFileResult, TransformOptions, loadOptions } from '@babel/core';
import { outputFiles } from '../utils/output';
import { BuildOptions } from '../build';
interface TransformHandleOptions extends ... |
<reponame>PSE-TECO-2020-TEAM1/e2e-ml_client<filename>src/containers/usePredictionPage/index.ts
import { PredictionPageViewProps } from 'components/PredictionPageView';
import assert from 'lib/assert';
import { useAPI, useBoolean, usePromise } from 'lib/hooks';
import { useBareHeader } from 'lib/hooks/Header';
import { ... |
<reponame>mark-j/Caseta2Mqtt
import fs = require('fs');
import path = require('path');
import { paramCase } from "param-case";
import { EventEmitter } from 'events';
import { Logger } from '../logger';
import { ConfigModel } from './config-model';
import { IntegrationReportModel } from './integration-report-model';
imp... |
<filename>framework/types/methods.ts
// const pi = 3.14159265359;
const exponentSub = ["\u2070", "\u00b9", "\u00b2", "\u00b3", "\u2074", "\u2075", "\u2076", "\u2077", "\u2078", "\u2079"];
export const solveForDiameter: Function = (radius: number) => {
return radius * 2;
};
export const solveForCircumference: Functi... |
import type Uppy from '@uppy/core';
import type Dashboard from '@uppy/dashboard';
import UppyOverrideStyle from '../../../../assets/uppyOverride.css';
import { IFocusable } from '../../../../core/BaseTypes';
import { ISpinnerView, SpinnerView } from '../../../../form/view/SpinnerView';
import { ListenableEntity } from ... |
import React, {useState, useEffect} from 'react';
import {Text, SmallText} from 'shared/styled-components/Texts';
import {
PageContainer,
Label as BaseLabel,
Input,
} from 'shared/styled-components';
import styled from 'styled-components/native';
import {colors} from 'shared/styles';
import {TouchableOpacity, Vie... |
<filename>src/server/express.ts
import express from "express";
import { createServer as createHttp } from "http";
import { createServer as createHttps } from "https";
import { Logger } from "../logger";
import { TelegramBotModel } from "../telegram/bot";
import { HttpsOptions } from "../../certs";
import { HealthDto, H... |
<reponame>willfulbard/camphoric
// Need to use the React-specific entry point to allow generating React hooks
import { createApi, fetchBaseQuery } from '@reduxjs/toolkit/query/react';
import { getCsrfToken } from 'utils/fetch';
const apiObjectNames = [
'Organization',
'Event',
'Registration',
'RegistrationType... |
import type { PropType } from '@uni-component/core'
import {
computed,
Fragment,
h,
ref,
uni2Platform,
uniComponent,
} from '@uni-component/core'
// Styles
import './VTextField.sass'
// Components
import { filterInputProps, makeVInputProps, VInput } from '@/components/VInput/VInput'
import { filterFieldPr... |
<reponame>camelwu/muliRepo4Lib
import { EventEmitter } from 'events';
import DRAW_TYPE, { checkDrawType } from './config/drawType';
import * as util from '@mrjl/utils';
import FreeDrawController from './controllers/FreeDrawController';
import CircleDrawController from './controllers/CircleDrawController';
import Delet... |
<filename>src/router/WebBuilder.ts<gh_stars>1-10
import { pathToRegexp, Key } from 'path-to-regexp';
import { Slot } from '../slot/Slot';
import { Use } from '../slot/SlotManager';
import { Method } from '../util/Method';
import { Validator, ValidatorDataType, ValidatorTypes } from '../validator/Validator';
import { Bu... |
<gh_stars>10-100
import * as fs from 'fs';
import * as path from 'path';
export interface IPDKRubyInstances {
pdkDirectory: string;
instances: IPDKRubyInstance[];
allPuppetVersions: string[];
latest: IPDKRubyInstance;
/**
* Finds the first PDK Instance that has Puppet version `puppetVersion`
* @param ... |
import {
PlayStatus,
StepsInput,
Steps,
OptionsInput,
Subscriptions,
SequencerState,
SequencerApi,
NotifyFunction,
EndMode,
Options,
} from './types'
import Ticker from './ticker'
const ticker = new Ticker()
class Sequencer<TStepName> {
private prevState: SequencerState<TStepName>
private ste... |
<filename>packages/chats/src/Lightbox/hooks/duplicateHooks.tsx<gh_stars>0
import * as React from 'react';
import { useWindowDimensions } from 'react-native';
import Animated, {
useDerivedValue,
withSpring,
useAnimatedStyle,
interpolate,
useSharedValue,
runOnJS,
useWorkletCallback,
} from 're... |
<reponame>island-is/island.is
import { Injectable } from '@nestjs/common'
import { InjectModel } from '@nestjs/sequelize'
import { CurrentApplicationModel, ApplicationModel } from './models'
import { Op } from 'sequelize'
import { CreateApplicationDto, UpdateApplicationDto } from './dto'
import {
ApplicationEventT... |
/** @jsx h */
import { autocomplete, getAlgoliaResults } from '@algolia/autocomplete-js';
import algoliarecommend from '@algolia/recommend';
import {
frequentlyBoughtTogether,
relatedProducts,
} from '@algolia/recommend-js';
import { horizontalSlider } from '@algolia/ui-components-horizontal-slider-js';
import algo... |
<reponame>anoopk23/IonicPlacementApp
import * as path from 'path';
import * as chalk from 'chalk';
import { BowerJson, DistTag, IShellRunOptions, IonicEnvironment, PackageJson } from '../../definitions';
import { isBowerJson, isExitCodeException, isPackageJson } from '../../guards';
import { ERROR_SHELL_COMMAND_NOT_F... |
import {
Component,
FunctionalComponent,
h,
createRef,
ComponentChildren,
} from 'preact';
import { Pixel } from './utils';
const styles = `
.pixel-calculator input[type=number] {
margin: 0;
font: inherit;
line-height: 1.5;
padding: 0 0.2em;
width: 100%;
box-sizing: border-box;
padding: 0 0.4re... |
/*---------------------------------------------------------------------------------------------
* Copyright (c) Bentley Systems, Incorporated. All rights reserved.
* See LICENSE.md in the project root for license terms and full copyright notice.
*-------------------------------------------------------------------------... |
import { applyMask } from '../utils/masker'
import { Entangle } from './alpine'
export interface InitOptions {
model: Entangle
config: {
isLazy: boolean
interval: number
format: string
is12H: boolean
readonly: boolean
disabled: boolean
},
}
export interface TimePicker {
[index: string]... |
import { extname } from 'path';
import S3 from 'aws-sdk/clients/s3';
import unzipper from 'unzipper';
import {
lookup as mimeLookup,
contentType as mimeContentType,
} from 'mime-types';
import { deploymentConfigurationKey } from './constants';
import { DeploymentConfig, FileResult, LambdaDefinition } from './type... |
<filename>src/plugins/wallet/extension/wallet-controller.ts
import { ConfirmationScreenType } from './../../confirmation-screen/iconfirmation-screen-plugin';
import { browser, Runtime } from 'webextension-polyfill-ts';
import aes from 'crypto-js/aes';
import { Response, IResponseData } from '../../../utils/response';
i... |
<reponame>bhaskarvilles/cactus
import type { Express } from "express";
import OAS from "../json/openapi.json";
import {
Logger,
Checks,
LogLevelDesc,
LoggerProvider,
} from "@hyperledger/cactus-common";
import {
ICactusPlugin,
ICactusPluginOptions,
IPluginKeychain,
IPluginWebService,
IWebServiceEndp... |
<reponame>mjocampov/papeles
import { PubSubEngine } from "graphql-subscriptions";
import {
Resolver,
Query,
Mutation,
Arg,
ObjectType,
Field,
registerEnumType,
Ctx,
UseMiddleware,
Subscription,
PubSub,
InputType,
Int,
Root,
ResolverInterface,
FieldResolver
} from "type-graphql";
import {... |
import {HomeAssistant} from "custom-card-helpers/dist";
import {Alert, AlertItem, Uv} from "./types";
import {html} from "lit-html";
import {getUnit, getWeatherIcon, numFormat} from "./ha-cwc-utils";
// @ts-ignore
export const renderAlert = (hass: HomeAssistant, alert_sensor: Alert, border: boolean) => {
let alert... |
//
// HMACAuth.ts
//
// Created by <NAME> on 27 Aug 2021.
// Copyright 2021 Vircadia contributors.
//
// Distributed under the Apache License, Version 2.0.
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
//
import Uuid from "../shared/Uuid";
import UDT from "./udt/UDT";
imp... |
<filename>lib/loader.ts
import { Bootstrap } from '../app/lib/bootstrap';
import * as path from 'path';
import * as fs from 'fs';
import { Application, AppWorkerLoader as EggAppWorkerLoader } from 'egg';
const FileLoader: any = require('egg-core/lib/loader/file_loader');
import OverrideContextLoader from './context_l... |
<filename>src/IEManageSystem.Web/ClientApp/src/Common/ice-common/Theme/index.ts
import * as Themes from '@ant-design/colors';
import {IETool} from 'ice-common'
const saveName = '__IEThemeName__';
export const themeName = {
red: 'red',
volcano: 'volcano',
orange: 'orange',
gold: 'gold',
yellow: 'yel... |
/* eslint-disable complexity */
import React, { CSSProperties } from 'react';
import { getAlignmentOffset } from './utilities/style-utilities';
import { Alignment, ControlProps } from './types';
const defaultButtonStyles = (disabled: boolean): CSSProperties => ({
border: 0,
background: 'rgba(0,0,0,0.4)',
color: ... |
import { commands } from 'vscode';
import {
BreakpointEvent,
InitializedEvent,
LoggingDebugSession,
OutputEvent,
StoppedEvent,
TerminatedEvent,
Thread,
} from 'vscode-debugadapter';
import { DebugProtocol } from 'vscode-debugprotocol';
import { DebugDispatcher } from './debugDispatcher';
imp... |
<filename>src/utils/webglUtils.ts
import { Scene, PerspectiveCamera, WebGLRenderer, Mesh, PlaneGeometry, Texture, LinearFilter, ShaderMaterial, ClampToEdgeWrapping } from 'three';
import { OrbitControls } from 'three-orbitcontrols-ts';
// let tempCanvas = document.createElement("canvas");
// let tempCtx = tempCanvas.g... |
<reponame>sonrad10/while.js
import { AST_CMD, AST_EXPR, AST_PROG } from "../types/ast";
import { BinaryTree } from "../types/Trees";
import { StringBuilder } from "../utils/StringBuilder";
/**
* Produce a program string from the stored program AST
* @param prog The program AST to display
* @param indent The charac... |
<filename>src/oot3d/zar.ts
// Zelda ARchive / Grezzo ARchive
import ArrayBufferSlice from "../ArrayBufferSlice";
import { assert, readString } from "../util";
import * as CMB from './cmb';
const enum Magic {
ZAR1 = 'ZAR\x01', // OoT3D
GAR2 = 'GAR\x02', // MM3D
GAR5 = 'GAR\x05', // LM3DS
}
export interfa... |
import { Version } from '@microsoft/sp-core-library';
import {
BaseClientSideWebPart,
IPropertyPaneConfiguration,
PropertyPaneTextField,
IWebPartContext
} from '@microsoft/sp-webpart-base';
import { SPComponentLoader } from '@microsoft/sp-loader';
import { SPHttpClient, SPHttpClientResponse } from '@microsoft/s... |
<reponame>aervin/wotan
import * as ts from 'typescript';
import { resolveCachedResult, hasSupportedExtension } from './utils';
import * as path from 'path';
import { ProcessorLoader } from './services/processor-loader';
import { FileKind, CachedFileSystem } from './services/cached-file-system';
import { Configuration, ... |
import { conversionGenerator as cypressConversionGenerator } from '@nrwl/cypress';
import {
convertNxGenerator,
formatFiles,
GeneratorCallback,
logger,
Tree,
} from '@nrwl/devkit';
import { ConvertTSLintToESLintSchema, ProjectConverter } from '@nrwl/linter';
import type { Linter } from 'eslint';
import { addL... |
<reponame>sarahM0/cts<filename>src/webgpu/api/validation/queue/writeBuffer.spec.ts<gh_stars>10-100
export const description = `
Tests writeBuffer validation.
Note: destroyed buffer is tested in destroyed/.
Note: buffer map state is tested in ./buffer_mapped.spec.ts.
`;
import { makeTestGroup } from '../../../../commo... |
import React, { Component } from 'react'
import InputMask from 'react-input-mask'
import cx from 'classnames'
import { ignoreProps } from 'helpers'
const setValue = (x, e) => e.target.value
const setBoolValue = (x, e) => Boolean(e.target.checked)
const validationClasses = ({ className, invalidClass, requiredClass }, ... |
import * as Container from '../../../util/container'
import * as RouteTreeGen from '../../../actions/route-tree-gen'
import * as Chat2Gen from '../../../actions/chat2-gen'
import * as TeamConstants from '../../../constants/teams'
import * as React from 'react'
import * as Kb from '../../../common-adapters'
import * as ... |
<filename>packages/installer/liteloader.ts
import { MinecraftFolder, MinecraftLocation } from "@xmcl/core";
import { Task, task } from "@xmcl/task";
import { join } from "path";
import { errorFrom, ensureDir, InstallOptions, missing, readFile, writeFile } from "./utils";
import { getAndParseIfUpdate, Timestamped } from... |
/*---------------------------------------------------------
* Copyright (C) Microsoft Corporation. All rights reserved.
*--------------------------------------------------------*/
import { Protocol as Cdp } from 'devtools-protocol';
import { Category } from 'vscode-js-profile-core/out/esm/common/model';
import {
I... |
<reponame>MrRamka/charticulator
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT license.
import { expect, use } from "chai";
import { Application } from "../../app/index";
import { Actions } from "../../app/index";
import { ObjectItem } from "../../core/prototypes";
import {
Da... |
import React from 'react';
import { Button, IconButton, Theme, Toolbar, Tooltip } from '@mui/material';
import { createStyles, makeStyles } from '@mui/styles';
import { useTranslation } from 'react-i18next';
import { TableInstance } from 'react-table';
import ViewColumnsIcon from '@mui/icons-material/ViewColumn';
impor... |
// Copyright 2018 Google 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
//
// https://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in ... |
<gh_stars>1-10
import {Injectable} from '@angular/core'
import {bytesToHex} from '../crypto'
import {
Schema, MethodData, ConstructorData,
GZIP_CTOR, VECTOR_CTOR, TRUE_CTOR, FALSE_CTOR
} from './types'
const SUCCESS = true
export const BASE_TYPES = {
'#' : 'getInt',
'int' : 'getInt',
'long' : 'getL... |
import {
Button,
Classes,
H3,
Icon,
InputGroup,
FormGroup,
Spinner,
Switch
} from '@blueprintjs/core';
import * as React from 'react';
import { useQuery, useMutation } from 'react-apollo';
import { useSelector, useDispatch } from 'react-redux';
import { loader } from 'graphql.macro';
import { useSnackba... |
import BigNumber from "bignumber.js";
import { ASHSWAP_CONFIG } from "const/ashswapConfig";
import pools from "const/pool";
import { IN_POOL_TOKENS } from "const/tokens";
import { randomHexColor } from "helper/color";
import { fetcher } from "helper/common";
import { IToken } from "interface/token";
import Image from "... |
import * as React from 'react'
import { useRouter } from 'next/router'
import axios from 'axios'
import hexAlpha from 'hex-alpha'
import {
Flex,
VStack,
Icon,
Button,
Tabs,
TabList,
TabPanel,
TabPanels,
useToken,
useToast,
} from '@chakra-ui/react'
import { useForm, SubmitHandler } from 'react-hook-... |
import {Component, ComponentScope} from './component.js';
import {ComponentFactory, Constructor, ServiceIdentifier} from './interfaces.js';
import {Subject} from 'rxjs';
import {createModule, ModuleClass, ModuleOption, OnModuleStart, OnModuleStop} from './module.js';
import {AsyncInterceptProvider, Container} from '@se... |
<gh_stars>1-10
import {IApiHandler} from "./IApiHandler";
import {Readable} from "stream";
import {namedNode} from "@rdfjs/data-model";
import * as RdfTerm from "rdf-string";
import * as RDF from "rdf";
import {ApiClient} from "./ApiClient";
const template = require('url-template');
interface IFullTextSearchHandlerAr... |
<reponame>badsyntax/vscode-java-pack
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT license.
import * as vscode from "vscode";
import * as cp from "child_process";
import * as path from "path";
import expandTilde = require("expand-tilde");
import * as pathExists from "path-exist... |
import { MouseEvent, useEffect, useState } from 'react'
import { NextPage } from 'next'
import { useRouter } from 'next/router'
import {
Box,
Grid,
Flex,
Text,
HStack,
useDisclosure,
} from '@chakra-ui/react'
import { useRecoilState, useRecoilValue } from 'recoil'
import Lightbox from 'react-image-lightbox'... |
<reponame>viktorbezdek/basta
import {defineMIME, defineMode} from '../index';
import {Pass} from '../misc';
defineMode('modelica', function(config, parserConfig) {
const indentUnit = config.indentUnit;
const keywords = parserConfig.keywords || {};
const builtin = parserConfig.builtin || {};
const atom... |
<reponame>martin-nordberg/grestler
//
// (C) Copyright 2015 <NAME>
// Apache 2.0 License
//
/**
* Module: org/grestler/infrastructure/dependencies/injection
*/
import functionintrospection = require( '../reflection/functionintrospection')
////////////////////////////////////////////////////////////////////////////... |
import type { Entity, World } from 'ape-ecs'
import type { Animations, IGrid, IGridDirection, ITexture } from '../../typings'
import Map3D from '../../common/map-3d'
import Transform from '../components/transform'
import Texture from '../components/texture'
import Draw from '../components/draw'
import Actor from '../co... |
import * as WebSocket from 'ws';
import { getToken } from './tokens';
import { Queue } from 'typescript-collections';
/*
Todo
Debug reconnection on mobile
*/
export enum MessageType {
// General
Info, ClientError, Connect, Ping,
// Accounts
AnonymousLogin, LoginResponce,
// Queuing
JoinQueu... |
import { Dict, Eval, Query } from 'koishi'
type QueryOperators = {
[K in keyof Query.FieldExpr]?: (query: Query.FieldExpr[K], data: any) => boolean
}
const queryOperators: QueryOperators = {
// logical
$or: (query, data) => query.reduce((prev, query) => prev || executeFieldQuery(query, data), false),
$and: (q... |
<reponame>matt-from-uk/scrypted<filename>plugins/core/ui/src/common/camera.ts
import { ScryptedDevice, ScryptedMimeTypes, RTCAVMessage, MediaManager, VideoCamera, MediaStreamOptions, MediaObject, RTCAVSource, RequestMediaStreamOptions } from '@scrypted/sdk/types';
export async function streamCamera(mediaManager: Media... |
<gh_stars>0
import * as PubSub from 'pubsub-js';
import Store from '@webbitjs/store';
import { compare } from 'specificity';
import { normalizeConfig, WebbitConfig } from './element-config';
import Webbit from './webbit';
import { getWebbitIterator, filterNode } from './filter';
class WebbitConnector {
static UNIQUE... |
import { trimEnd } from "lodash";
const fs = require('fs')
let graph: Node[] = [];
class Node {
public linkedNodes: Node[];
public name: string;
constructor(name: string) {
this.linkedNodes = [];
this.name = name;
}
public hasLinkToNode(name: string): boolean {
let hasLi... |
<reponame>pinglue/pg-repo
import path from "path";
import {
Msg,
_merge,
_default
} from "@pinglue/utils";
import type {
RegistrySettings,
PackageRecord,
CustomSettings,
PackageInfo
} from "./project-loader";
import {
Loader,
LoaderSettings,
LoaderOutput
} from "./loader.js";... |
/* --------------------------------------------------------------------------------------------
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
* -------------------------------------------------------------... |
<filename>src/rtfjs/renderer/Renderer.ts
/*
The MIT License (MIT)
Copyright (c) 2015 <NAME>
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the ... |
import { TypeMetronom } from 'mssqltask'
import * as vv from 'vv-common'
import { IApp, TypeStateRow } from 'backdepot'
import path from 'path'
import fs from 'fs'
import { TStateRow } from 'backdepot/dist/src/index.env'
import { TUpsert } from './depot'
export type TDepotTask = {
path: string | undefined,
fil... |
<reponame>deanearlwright/AdventOfCode
// ======================================================================
// Internet Protocol Version 7
// Advent of Code 2016 Day 07 -- <NAME> -- https://adventofcode.com
//
// TypeScript implementation by Dr. <NAME> III
// ======================================================... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.