text stringlengths 3.3k 33k |
|---|
/// <reference path="types/Chartjs.d.ts" />
interface ChartConfiguration extends Chart.ChartConfiguration {
debug: boolean;
canvasId: string;
}
interface DotNetObjectReference {
invokeMethod(methodName: string, ...args): any;
invokeMethodAsync(methodName: string, ...args): Promise<any>;
}
// maybe... |
<reponame>s3799570/P000075CSITCP<gh_stars>1-10
/*********************************************************************************************************************
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. *
* ... |
import React, { useState, useContext, useMemo, useRef, useEffect, ReactText } from 'react';
import classnames from 'classnames';
import { filter, isNil, without, findIndex } from 'lodash';
import { SizeContext } from '../config-provider/SizeContext';
import Dropdown from '../dropdown';
import Selector from './Selector'... |
<gh_stars>0
import { Neovim } from '@chemzqm/neovim'
import path from 'path'
import { severityLevel, getNameFromSeverity } from '../../diagnostic/util'
import { Range, DiagnosticSeverity, Diagnostic, Location } from 'vscode-languageserver-types'
import { URI } from 'vscode-uri'
import Document from '../../model/documen... |
import cmp from 'semver-compare'
import lowdb from 'lowdb'
import path from 'path'
import FileSync from 'lowdb/adapters/FileSync'
import _, { LoDashExplicitWrapper } from 'lodash'
import winston from 'winston'
import { Key } from 'readline'
// import winston from 'winston'
const statusAdapter = new FileSync<Status.Roo... |
import type { UserEntity } from '#lib/database';
import { LanguageKeys } from '#lib/i18n/languageKeys';
import { CanvasColors, socialFolder } from '#utils/constants';
import { container, UserError } from '@sapphire/framework';
import { fetchT } from '@sapphire/plugin-i18next';
import { roundNumber } from '@sapphire/uti... |
<reponame>JadenSimon/aws-sdk-js-v3<filename>packages/credential-provider-ini/src/index.ts
import { fromEnv } from "@aws-sdk/credential-provider-env";
import { fromContainerMetadata, fromInstanceMetadata } from "@aws-sdk/credential-provider-imds";
import { fromProcess } from "@aws-sdk/credential-provider-process";
impor... |
import fs from 'fs-extra';
import path from 'path';
import { Page } from '../utils';
import { walkAndCount, prepareSubstitutions, walkAndSubstitute } from './propCompression';
import windowsPathFix from '../utils/windowsPathFix';
const defaultElderHelpers = (decompressCode, prefix, generateLazy) => `
const $$ejs = (p... |
/*
* Licensed to Elasticsearch B.V. under one or more contributor
* license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright
* ownership. Elasticsearch B.V. licenses this file to you under
* the Apache License, Version 2.0 (the "License"); you may
* not u... |
import React from 'react'
import { Link } from 'react-router-dom'
import URI from 'urijs'
import _ from 'lodash'
import './Pagination.css'
export const Pagination = ({ location, url = '', calculated, total, cursor = 1, limit = 10 }: {
location: any;
url?: any;
calculated: any;
total?: number;
cursor?: number... |
<filename>src/utils/parsers/BaseParser.ts
import parse from 'parse-diff'
import { ParseOptions, VariableDiffMatch, Range, VariableUsageMatch } from './types'
import * as usage from '../../commands/usages/types'
import { LANGUAGE_MAP } from '../parsers'
type MatchWithRange = {
// Variable name
name: string
... |
import { List, Tabs } from 'antd';
import { Coords } from 'google-map-react';
import React, { useEffect, useState } from 'react';
import { useTranslation } from 'react-i18next';
import { useDispatch, useSelector } from 'react-redux';
import { useHistory } from 'react-router-dom';
import LoadingWrapper from 'src/compone... |
import { navigateBack } from '../public/publicAPIs';
import { validOriginRegExp } from './constants';
import { GlobalVars } from './globalVars';
import { MessageResponse, MessageRequest, ExtendedWindow, MessageEvent } from './interfaces';
// ::::::::::::::::::::MicrosoftTeams SDK Internal :::::::::::::::::
GlobalVars.... |
<filename>src/createScene.ts
import eventify, { EventedType } from 'ngraph.events';
import Element from './Element';
import onClap from './clap';
import {glMatrix, mat4, vec4, vec3, quat} from 'gl-matrix';
import ViewMatrix from './ViewMatrix';
import createMapControls from './createMapControls';
import {EventCallbac... |
import debounce from 'lodash.debounce';
import { ControlsManager, RAYCASTER_EVENTS } from 'three-freeform-controls';
import ROSLIB, { Ros, Topic } from 'roslib';
import LegacyCore from '../core';
import {
DEFAULT_OPTIONS_INTERACTIVE_MARKER,
MESSAGE_TYPE_INTERACTIVEMARKER,
MESSAGE_TYPE_INTERACTIVEMARKER_FEEDBACK,
... |
<reponame>kamiyaa/celo-web-wallet
import { BigNumber, providers } from 'ethers'
import type { RootState } from 'src/app/rootReducer'
import { getContractByAddress, getTokenContract } from 'src/blockchain/contracts'
import { isSignerLedger } from 'src/blockchain/signer'
import { sendSignedTransaction, signTransaction } ... |
import * as Parsec from '../src/Parsec';
import * as K from '../src/Kit';
import * as C from 'fast-check';
import {testProp, sampleInCharset} from './utils';
import {assert} from 'chai';
import {Parser} from '../src/Parsec';
type TestState = {counter: number; whole: string};
const P = Parsec.refine<string, TestState, ... |
/********************************************************************************
* Copyright (c) 2021-2022 STMicroelectronics and others.
*
* This program and the accompanying materials are made available under the
* terms of the Eclipse Public License v. 2.0 which is available at
* https://www.eclipse.org/legal/... |
import { expect } from 'chai'
import 'mocha'
import { arrayToStream, takeAsync } from './streams/utils'
import { deserialize, deserializeStream, serialize } from './ol'
import { IFeature } from './generic/feature'
import Feature from 'ol/Feature'
import WKT from 'ol/format/WKT'
import GeoJSON from 'ol/format/GeoJSON... |
<filename>src/nodecanvas.ts<gh_stars>0
import * as svgPanZoom from "svg-pan-zoom";
import {Point} from "./point";
import {Node} from "./node";
import {NodeConnector} from "./nodeconnector";
import {INodeArguments} from "./interfaces/INodeArguments";
import {ICodeNodesType} from "./interfaces/ICodeNodesType";
import {IN... |
// Libraries
import Papa, { ParseConfig, Parser, ParseResult } from 'papaparse';
import defaults from 'lodash/defaults';
// Types
import { DataFrame, Field, FieldConfig, FieldType } from '../types';
import { guessFieldTypeFromValue } from '../dataframe/processDataFrame';
import { MutableDataFrame } from '../dataframe/... |
<filename>utils/generate_types/overrides-test.d.ts
/**
* Copyright (c) Microsoft 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... |
import crypto from 'crypto';
import { utils } from 'ethers';
import config from '@/config';
import FTService from '@/services/FT.service';
import userService from '@/services/user.service';
import nftService from '@/services/nft.service';
import { INFT } from '@/interfaces/NFT.interface';
import { IUser } from '@/inter... |
import { EngineeringNotation } from "../engineering";
import Decimal from "break_infinity.js";
import { toFixedEngineering } from "../utils";
const UNITS = [
"zero", "one", "two", "three", "four", "five", "six", "seven", "eight", "nine",
"ten", "eleven", "twelve", "thirteen", "fourteen", "fifteen", "sixteen"... |
import {
AfterViewInit,
ChangeDetectionStrategy,
Component,
ElementRef,
EventEmitter,
Input,
NgZone,
OnDestroy,
Output,
ViewChild,
} from '@angular/core';
import { NwbDatePickerIntl } from './date-picker-intl';
import { NwbDatePickerFormat } from './date-picker-format';
import { NwbDatePickerDefault... |
/**
* @file Transform 转换并提取依赖
*/
import {AstNodeType, IAstNode, ICallAstNode} from './Parser';
import {TokenType} from './Tokenizer';
interface IPath {
readonly node: IAstNode;
readonly part: string;
readonly scopeSymbols: {[key: string]: boolean};
readonly isArray: boolean;
readonly partIndex: n... |
<filename>src/lib/Security.ts
import moment from 'moment';
import {Context} from 'koa';
import {v4 as uuid} from 'uuid';
import {inRange} from 'range_check';
import {WrappedNodeRedisClient} from 'handy-redis';
import {AccessTier} from '@archival-iiif/presentation-builder/dist/v2/Image';
import config from './Config';
... |
/*
* Copyright OpenSearch Contributors
* SPDX-License-Identifier: Apache-2.0
*/
import { UIAction, Action, Transition, ISMTemplate, State, Policy } from "../../../../models/interfaces";
import {
ActionType,
DEFAULT_ALLOCATION,
DEFAULT_CLOSE,
DEFAULT_DELETE,
DEFAULT_FORCE_MERGE,
DEFAULT_INDEX_PRIORITY,
... |
import React, { useEffect, useReducer, useMemo, useRef, useImperativeHandle } from 'react';
import MarkdownPreview, { MarkdownPreviewProps, MarkdownPreviewRef } from '@uiw/react-markdown-preview';
import TextArea, { ITextAreaProps } from './components/TextArea';
import Toolbar from './components/Toolbar';
import DragBa... |
<filename>src/FilterParser.ts
import { BerReader } from 'asn1';
import { Filter } from './filters/Filter';
import {
PresenceFilter,
AndFilter,
GreaterThanEqualsFilter,
ExtensibleFilter,
ExtensibleFilterOptions,
NotFilter,
SubstringFilter,
EqualityFilter,
ApproximateFilter,
OrFilter,
LessThanEquals... |
import {Token, Tokenizer, TOKEN_TYPES} from "./Tokenizer";
import ExpressionParsers from "./ElementParsers/expressions";
import StatementParsers from "./ElementParsers/statements";
import { AST_Node, SkipParse, AST_TYPES, AST_Id} from "./ast";
import { PassdownSettings } from "..";
import { ERROR_TYPES } from "../../... |
import PlatformDefaults from 'platform-defaults';
import Platform from 'platform';
import * as BufferUtils from 'platform-bufferutils';
import * as Utils from './utils';
import Logger from './logger';
import ErrorInfo from '../types/errorinfo';
import { version } from '../../../package.json';
import ClientOptions, { De... |
<reponame>cmkerner20/azure-functions-ux<gh_stars>0
import { Component, Output } from '@angular/core';
import { CacheService } from './../../shared/services/cache.service';
import { GlobalStateService } from '../../shared/services/global-state.service';
import { ArmSiteDescriptor } from './../../shared/resourceDescripto... |
/*
* 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 React, { useMemo, useCallback, memo } from 'react';
import {
EuiHori... |
import {
LitElement,
html,
css,
customElement,
CSSResult,
TemplateResult,
property,
internalProperty,
query,
} from 'lit-element';
import {styleMap} from 'lit-html/directives/style-map';
import {CodeEditorHistory} from './CommandHistory';
import {
insertTab,
insertNewline,
getNewlinePosList,
g... |
<gh_stars>0
// Copyright 2020-2021 ETH Zurich and the DaCe-VSCode authors.
// All rights reserved.
import * as vscode from 'vscode';
import * as cp from 'child_process';
import { EventEmitter } from 'events';
import { DaCeVSCode } from '../extension';
import { SdfgViewer, SdfgViewerProvider } from '../components/sdfgV... |
// github:tom-weatherhead/thaw-reversi-engine.ts/src/board.ts
import { createArrayFromElement } from 'thaw-common-utilities.ts';
import { TwoDimensionalVector } from './2d-vector';
import { Player } from './player';
export const boardSize = 8;
export const boardWidth = boardSize;
export const boardHeight = boardWidt... |
<filename>packages/app/src/webapp/util/ascii-to-table.ts
/*
* Copyright 2018 IBM 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-... |
import ResourceIssue, { TResourceIssueDocument } from "./ResourceIssue";
import {
TAddress,
TLegacyResource,
TResource,
TResourceScheduleData,
} from "@upswyng/types";
import {
TSubcategoryDocument,
subcategoryDocumentToSubcategory,
} from "./Subcategory";
import User, { userDocumentToUser } from "./User";
... |
import { CompositeDisposable, TextEditor } from 'atom'
import suggest from './autocomplete/suggest'
import { AutocompleteContext, Suggestion } from './autocomplete/util'
import getParserConfig, {
DefaultParserConfig,
LinterMessage,
} from './getParserConfig'
import getRulesFromAtomPackages from './rules/getRulesFr... |
<reponame>SongYuQiu/SocialNetworkPortraitAnalysisSystem
import * as matrix from './matrix';
import * as vector from './vector';
import { Dictionary } from './types';
import { logError } from './util';
const mIdentity = matrix.identity;
const EPSILON = 5e-5;
function isNotAroundZero(val: number) {
return val > EP... |
import React, { useCallback, useContext } from 'react';
import { useTooltipInPortal, defaultStyles } from '@visx/tooltip';
import { TooltipProps as BaseTooltipProps } from '@visx/tooltip/lib/tooltips/Tooltip';
import { PickD3Scale } from '@visx/scale';
import { UseTooltipPortalOptions } from '@visx/tooltip/lib/hooks/us... |
<reponame>awarecan/playwright
/**
* Copyright (c) Microsoft 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 req... |
/* eslint-disable no-undef, no-unused-vars */
import * as React from 'react';
import * as _ from 'lodash-es';
import { match, Link } from 'react-router-dom';
import { Helmet } from 'react-helmet';
import { safeLoad } from 'js-yaml';
import { NavTitle, Firehose, MsgBox, LoadingBox, withFallback } from '../utils';
impo... |
import { tzip12, Tzip12Module } from '@taquito/tzip12';
import { TezosToolkit } from '@taquito/taquito';
import { Tzip12Contract, address } from './type-aliases';
import {
SimpleAdminContract,
PausableSimpleAdminContract,
MultiAdminContract
} from './interfaces/admin';
import {
MultiAdmin,
SimpleAdmin,
Pau... |
/**
* Families index
*/
import {
getClient,
getEnvironmentDefaultLocaleCode,
getEntryByID,
getAllEntries,
getTopicDetails,
} from "../libs/contentful-cda";
import {
CfLocalizedEntryField,
TopicDetailsResponse,
AlgoliaPaginateRecords,
TopicProductFieldsResponse,
CfSys,
WrapperImageFields,
Avail... |
import type { ReactNode, RefObject } from 'react';
import { createRef, PureComponent } from 'react';
import { styled } from '@linaria/react';
import classNames from 'classnames';
import { Toast } from './Toast';
const LIMIT = 3;
const HIDE_TIMEOUT = 7000;
const HIDE_LEAVE_TIMEOUT = 5000;
const Wrapper = styled.div`... |
/*
* Copyright 2018 herd-ui contributors
*
* 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 ... |
<filename>lib/swaggerHTML.ts
function parseSimpleConfig(config: {[name: string]: any} = {}) {
return Object.keys(config).map(key => {
const value: any = config[key];
if(value === null) {
return `${key}: null,`;
}
if (typeof value === 'string') {
return `${key}... |
<gh_stars>0
//
// Copyright (c) Microsoft. All rights reserved.
// Licensed under the MIT license.
//
// Bot Auth Github:
// https://github.com/mattdot/BotAuth
//
// Copyright (c) Microsoft Corporation
// All rights reserved.
//
// MIT License:
// Permission is hereby granted, free of charge, to any person o... |
import opn from "better-opn"
import { execSync } from "child_process"
import execa from "execa"
import { sync as existsSync } from "fs-exists-cached"
import fs from "fs-extra"
import { trackCli, trackError } from "gatsby-telemetry"
import hostedGitInfo from "hosted-git-info"
import isValid from "is-valid-path"
import s... |
/* eslint-disable no-console */
/*
* Copyright OpenSearch Contributors
* SPDX-License-Identifier: Apache-2.0
*/
import _ from 'lodash';
import moment from 'moment';
import { v1 as uuid } from 'uuid';
import { HttpSetup } from '../../../../../../src/core/public';
import { TRACE_ANALYTICS_DATE_FORMAT } from '../../..... |
<reponame>benday-inc/download-artifact<filename>src/main.ts
import * as core from '@actions/core'
import * as fs from 'fs'
import axios, {AxiosInstance} from 'axios'
import {Artifact} from './artifact'
import {ArtifactsResponse} from './artifacts-response'
import path from 'path'
import {Workflow} from './workflow'
imp... |
<gh_stars>10-100
export type SubListener<T = any> = (value: T, prevValue?: T) => void
export type Thunk = () => void
export type Disposer = Thunk
// Exposed, this might be useful for third part reflection based (dev) tools
export const $RVal = typeof Symbol === "undefined" ? "$RVal" : Symbol.for('$RVal')
export int... |
import { LoadingButton } from '@mui/lab';
import AdapterMoment from '@mui/lab/AdapterMoment';
import DatePicker from '@mui/lab/DatePicker';
import LocalizationProvider from '@mui/lab/LocalizationProvider';
import Button from '@mui/material/Button';
import { SelectChangeEvent } from '@mui/material/Select';
import Stack ... |
#!/usr/bin/env node
// tslint:disable:no-console
import core = require("@actions/core");
import io = require("@actions/io");
import artifact = require("@actions/artifact");
import github = require("@actions/github");
import { exec } from "child_process";
import FormData from "form-data";
import AWS from "aws-sdk";
i... |
// Enums and Interfaces
import { AccountTypes, APIRegistrationTypes, RegistrationFlowType, RouteNames } from '@/enums'
import {
AccountProductSubscriptionIF,
AddCollateralIF,
AddPartiesIF,
ButtonConfigIF,
CertifyIF,
CourtOrderIF,
DebtorNameIF,
DraftIF,
GeneralCollateralIF,
IndividualNameIF,
Length... |
import { Direction } from './key'
import { isTextNode, isElementNode } from './dom-utils'
import { assertNotNull } from './assert'
export function clearSelection() {
const selection = window.getSelection()
selection && selection.removeAllRanges()
}
function textNodeRects(node: Text) {
let range = document.creat... |
import { ShortcutProps } from '@slimsag/react-shortcuts'
import H from 'history'
import { isArray, sortBy, uniq } from 'lodash-es'
import MenuIcon from 'mdi-react/MenuIcon'
import * as React from 'react'
import { Subscription } from 'rxjs'
import stringScore from 'string-score'
import { Key } from 'ts-key-enum'
import ... |
import { UIOptions} from "../ui-options";
import { UIDragGroup } from "../ui-drag-group";
import { buildSolver, SolverOptions } from "./solver-factory";
import { Solver } from "./solver-base";
import { HumanSolver } from "./solver-human";
import { SolverTimer } from "./solver-timer";
import { SolverStepCounter } from "... |
<gh_stars>0
import {
NormalizedChunk,
NormalizedCompilation,
NormalizedEntrypointItem,
} from '@statoscope/webpack-model/dist/normalize';
import networkListType from '@statoscope/helpers/dist/network-type-list';
import { APIFnOptions } from '@statoscope/types/types/validation/api';
import helpers, { Limit, ValueD... |
/*
* Copyright 2022 ThoughtWorks, Inc.
*
* 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 agr... |
<reponame>mhankus/glimmer-vm
import { DEBUG } from '@glimmer/env';
import { UnionToIntersection, symbol } from './utils';
import { assertTagNotConsumed } from './debug';
//////////
export type Revision = number;
export const CONSTANT: Revision = 0;
export const INITIAL: Revision = 1;
export const VOLATILE: Revision ... |
<filename>packages/augur-tools/src/flash/flash.ts
import { SDKConfiguration } from '@augurproject/artifacts';
import { EthersProvider } from '@augurproject/ethersjs-provider';
import {
Connectors,
createClient,
Events,
SubscriptionEventName,
} from '@augurproject/sdk';
import { DB } from '@augurproject/sdk/buil... |
import SectionHeadNew from '@celo/react-components/components/SectionHeadNew'
import colors from '@celo/react-components/styles/colors'
import variables from '@celo/react-components/styles/variables'
import _ from 'lodash'
import * as React from 'react'
import { WithTranslation } from 'react-i18next'
import {
NativeS... |
/**
* @license
* Copyright Google LLC All Rights Reserved.
*
* Use of this source code is governed by an MIT-style license that can be
* found in the LICENSE file at https://angular.io/license
*/
import * as ts from 'typescript';
import {absoluteFrom, absoluteFromSourceFile, AbsoluteFsPath} from '../../file_sys... |
<reponame>seebees/aws-encryption-sdk-javascript<filename>modules/cache-material/src/caching_cryptographic_materials_decorators.ts
/*
* Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License"). You may not use
* this file except in com... |
/**
* Column types where precision and scale properties are used.
*/
export type PrimaryGeneratedColumnType = "int" // mysql, mssql, oracle, sqlite
|"int2" // postgres, sqlite
|"int2" // postgres, sqlite
|"int4" // postgres
|"int8" // postgres, sqlite
|"integer" // postgres, oracle, sqlite
|"t... |
// Copyright 2020 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 ... |
/*
* Copyright 2020 ThoughtWorks, Inc.
*
* 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 agr... |
<gh_stars>0
import { flatten, get, has, merge } from "lodash";
import chalk from "chalk";
import type { AwsIamPolicyStatements } from "@serverless/typescript";
import * as path from "path";
import { readFileSync } from "fs";
import { dump } from "js-yaml";
import { DefaultTokenResolver, Lazy, StringConcat, Tokenization... |
import { defineConfig } from 'vite'
import path from 'path'
import Vue from '@vitejs/plugin-vue'
import Pages from 'vite-plugin-pages'
import Components from 'unplugin-vue-components/vite'
import ViteFonts from 'vite-plugin-fonts'
import ViteRadar from 'vite-plugin-radar'
import PurgeIcons from 'vite-plugin-purge-icons... |
<filename>packages/wholly-sheet/src/RowModel.ts
/*
MIT License
Copyright (c) 2021 Looker Data Sciences, Inc.
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 w... |
<filename>src/transformers/baseSourceMapTransformer.ts
/*---------------------------------------------------------
* Copyright (C) Microsoft Corporation. All rights reserved.
*--------------------------------------------------------*/
import * as path from 'path';
import {DebugProtocol} from 'vscode-debugprotocol';
... |
import * as audio from '../audio';
import * as display from '../display';
import * as level from '../level';
import * as kana from '../kana';
import * as util from '../util';
import * as youtube from '../youtube';
import { GameContext, Screen, ScreenManager } from './common';
import Level = level.Level;
class Typing... |
<filename>client/vue/penandpaper/src/components/server.ts
/**
* Copyright 2020 <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... |
<filename>packages/libs/core/src/images/imageOptimizer.ts
/**
* This and related code are adapted from https://github.com/vercel/next.js/blob/48acc479f3befb70de800392315831ed7defa4d8/packages/next/next-server/server/image-optimizer.ts
* The MIT License (MIT)
Copyright (c) 2020 Vercel, Inc.
Permission is hereby gr... |
<reponame>zephraph/figma-tokens
import { useDispatch, useSelector } from 'react-redux';
import { Octokit } from '@octokit/rest';
import { Dispatch, RootState } from '@/app/store';
import { MessageToPluginTypes } from '@/types/messages';
import { TokenProps } from '@/types/tokens';
import convertTokensToObject from '@/u... |
<filename>utils/functions.ts
import {Asset, MediaType, AssetsOptions, SortBy, getAssetsAsync} from 'expo-media-library';
import {
changeSortConditionAndNumColumns,
photoChunk,
sortCondition,
FlatSection,
flatMedia,
headerIndex,
layout,
story
} from '../types/interfaces';
/*
export const sectionizeMedia... |
import { Group } from "../scene/group";
import { Selection } from "../scene/selection";
import { MarkerLabel } from "./markerLabel";
import { BBox } from "../scene/bbox";
import { FontStyle, FontWeight } from "../scene/shape/text";
import { Marker } from "./marker/marker";
import { reactive, Observable } from "../util/... |
<filename>packages/provider/src/app/signer.ts<gh_stars>0
/**
* Copyright 2020, Optimism PBC
* MIT License
* https://github.com/ethereum-optimism
*
* This code is based on ethers.js
* Copyright (c) 2019 <NAME>
* MIT License
* https://github.com/ethers-io/ethers.js
*/
import {
JsonRpcSigner,
JsonRpcProvider... |
<gh_stars>0
/**
* Copyright (C) 2018 The Trustees of Indiana University
* SPDX-License-Identifier: BSD-3-Clause
*/
import * as path from 'path'
import { Pact, Matchers, Query } from '@pact-foundation/pact'
import axios, { AxiosResponse } from 'axios'
import * as traverse from 'traverse'
import { apiEndpoints } from... |
import { inspect } from '../jsutils/inspect';
import type { Maybe } from '../jsutils/Maybe';
import type { ASTNode, ASTKindToNode } from './ast';
import { isNode } from './ast';
/**
* A visitor is provided to visit, it contains the collection of
* relevant functions to be called during the visitor's traversal.
*/
... |
import React, { useState } from 'react'
import Head from 'next/head'
import { SocialIcon } from './SocialIcons'
import {
LineItemsContainer,
LineItemsCount,
} from '@commercelayer/react-components'
import ShoppingBag from './ShoppingBag'
import LayoutContext from '@context/LayoutContext'
import LanguageSelector fro... |
import React, { useMemo } from 'react'
import { SectionList, Text as TextNative, TouchableHighlight, View } from 'react-native'
import { Text } from '@ui-kitten/components'
import { CommonActions } from '@react-navigation/native'
import { EdgeInsets } from 'react-native-safe-area-context'
import { useTranslation } from... |
<filename>src/App.ts
import { createBrowserHistory } from 'history';
import _ from 'lodash';
import { loadResources } from './lib/load';
import { Event, EVENT_TYPES } from './lib/event';
import { getProjectkeyFromPath } from './lib/route';
import { Config, Option, ProjectOption, RegisterConfig, Plugin, DebugOptions } ... |
<gh_stars>10-100
import * as d3 from 'd3';
import {HierarchyNode} from 'd3';
import {BitSet, Column, DataFrame, DOCK_TYPE, GroupByBuilder, JOIN_TYPE} from 'datagrok-api/dg';
import * as grok from 'datagrok-api/grok';
export type TreeData = HierarchyNode<Branch>
type ColorValue = string;
type ColorizationMap = Map<Col... |
import { FileManager } from '../../managers/filemanager';
import { Reader } from '../reader'
export interface BLPImage {
width: number;
height: number;
encoding: BLPColorEncoding;
alphaBits: number;
mipmaps: BLPMipMap[];
data: ArrayBuffer;
}
enum BLPColorEncoding {
JPEG = 0,
PALETTE = ... |
import type { HookHub } from '@antv/xflow-hook'
import type { IArgsBase } from '@antv/xflow-core'
import type { IHooks } from '@antv/xflow-core'
import { ManaSyringe, ICommandHandler, ICommandContextProvider, delay } from '@antv/xflow-core'
import { XFlowDagCommands, GRAPH_STATUS_INFO, EDGE_PROCESSING_CLASSNAME } from ... |
// Copyright (c) Microsoft Corporation. All rights reserved. Licensed under the MIT license.
// See LICENSE in the project root for license information.
import * as semver from 'semver';
import { IPackageJson, FileConstants, Import, Enum } from '@rushstack/node-core-library';
import { CommandLineFlagParameter, Co... |
/**
@module @ember-data/store
*/
import CoreStore from './core-store';
import { assert } from '@ember/debug';
import normalizeModelName from './normalize-model-name';
import { assign } from '@ember/polyfills';
import { DEBUG } from '@glimmer/env';
import { isPresent } from '@ember/utils';
import { deprecate } from '@... |
<reponame>jasonkshar/deck
import * as spel2js from 'spel2js';
const literalExpression = (literalString: string) =>
spel2js.SpelExpressionEvaluator.compile(`'${literalString.replace(/'/g, "''")}'`);
/**
* This captures a type of bracket and the position in which it occurs in the
* expression. The positional inform... |
<gh_stars>1-10
import viewModelBase = require("viewmodels/viewModelBase");
import databasesManager = require("common/shell/databasesManager");
import certificateModel = require("models/auth/certificateModel");
import getCertificatesCommand = require("commands/auth/getCertificatesCommand");
import certificatePermiss... |
<filename>src/app/features/offers/offers.ts
import { animate, style, transition, trigger } from '@angular/animations';
import { UniqueSelectionDispatcher } from '@angular/cdk/collections';
import { AfterViewInit, Component, OnDestroy, OnInit, ViewEncapsulation } from '@angular/core';
import { MatDialog, MatDialogConfig... |
import {
getNodeBalancer,
getNodeBalancerConfigs
} from 'linode-js-sdk/lib/nodebalancers';
import { APIError } from 'linode-js-sdk/lib/types';
import { withSnackbar, WithSnackbarProps } from 'notistack';
import { any, last, pathOr } from 'ramda';
import * as React from 'react';
import {
matchPath,
Redirect,
R... |
import * as path from 'path';
import got from '../utils/got';
import { DiskFastq } from 'disk-fastq';
import { RecurrenceRule, scheduleJob } from 'node-schedule';
import * as Sentry from '@sentry/node';
import { RewriteFrames } from '@sentry/integrations';
import logger, { logHttpError } from './logger';
import { find... |
import { EventEmitter } from 'events';
import { Receiver, ReceiverEvent, ReceiverAckTimeoutError } from './types';
import { createServer, Server, Agent } from 'http';
import { SecureContextOptions } from 'tls';
import express, { Request, Response, Application, RequestHandler, NextFunction } from 'express';
import axios... |
<reponame>gogoyqj/ebit<filename>src/consumer/config/workspace-config.ts
import fs from 'fs-extra';
import R from 'ramda';
import AbstractConfig from './abstract-config';
import { Compilers, Testers } from './abstract-config';
import { BitConfigNotFound, InvalidBitJson, InvalidPackageJson } from './exceptions';
import {... |
<gh_stars>0
/* eslint-disable @typescript-eslint/no-non-null-assertion */
/* eslint-disable @typescript-eslint/no-unused-vars */
/* eslint-disable @typescript-eslint/no-explicit-any */
/* eslint-disable @typescript-eslint/camelcase */
import { LitElement, html, TemplateResult, css, CSSResultGroup } from 'lit';
import {... |
<filename>packages/common/src/services/__tests__/treeData.service.spec.ts
import { Column, SlickDataView, GridOption, SlickEventHandler, SlickGrid, SlickNamespace } from '../../interfaces/index';
import { SharedService } from '../shared.service';
import { TreeDataService } from '../treeData.service';
declare const Sli... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.