text
stringlengths
3.08k
15.5k
<reponame>AERX-dev/MetaBuildHackathon<gh_stars>1-10 import fs from 'fs'; import path from 'path'; import { create, IPFSHTTPClient } from 'ipfs-http-client'; import { ApiPromise, WsProvider } from '@polkadot/api'; import { typesBundleForPolkadot } from '@crustio/type-definitions'; import { Keyring } from '@polkadot/keyr...
import React, { useEffect, useRef, useState } from 'react'; import * as tf from '@tensorflow/tfjs'; import { Performance, perfInfo, PerformanceInfo } from '../../performance'; import { CLASSES } from '../labels'; import { VideoProps } from '../../types'; let activeInfer = false; export const AILabLocalVideo = ({ perf...
import { BuildInfo, Expr, Needs } from "./exprs/expr"; import { EffectLoop, UniformLocs } from "./mergepass"; import { WebGLProgramLoop, WebGLProgramLeaf } from "./webglprogramloop"; import { settings } from "./settings"; /** @ignore */ const FRAG_SET = ` gl_FragColor = texture2D(uSampler, gl_FragCoord.xy / uResoluti...
<reponame>zipper-team/elasticsearch-local<filename>src/index.ts import getDebug from 'debug'; import {execSync, exec} from 'child_process'; import {promisify} from 'util'; import {platform} from 'os'; import download from 'download-tarball'; import {access, constants} from 'fs'; import cwd from 'cwd'; const debug = ge...
import { ICards, LOCAL_STORE_NAME, ICardItem, IAddItemCard, IAddAmountItemCard } from './../constant/index'; import { LANGUAGE_CODE, SUB_FIX_PRCE } from "src/constant" import { Service } from "typedi" export const formatPrice = (number: number) => { return new Intl.NumberFormat(LANGUAGE_CODE.VN, { style: 'currency'...
<filename>src/utils/to-hex.ts import { typeOfColor } from "./type-of-color"; // normalizes non-alpha hex values // handles 000, #000, 000000 or #000000 const hexToHex = (hex: string): string => { let result = ""; // fff if (hex.length === 3) { result = `#${hex[0] + hex[0] + hex[1] + hex[1] + hex[2] + hex[2]...
import * as React from 'react' import clsx from 'clsx' import TableCell from '@material-ui/core/TableCell'; import CircularProgress from '@material-ui/core/CircularProgress' import Tooltip from '@material-ui/core/Tooltip' import IconButton from '@material-ui/core/IconButton' import DoneIcon from '@material-ui/icons/...
<reponame>barhamd/react-virtuoso import * as u from '@virtuoso.dev/urx' import { domIOSystem } from './domIOSystem' export const UP = 'up' as const export const DOWN = 'down' as const export const NONE = 'none' as const export type ScrollDirection = typeof UP | typeof DOWN | typeof NONE export interface ListBottomInf...
<gh_stars>0 import axios, { Axios, AxiosRequestConfig, AxiosResponse, Canceler, Method, } from 'axios'; /** * axios */ declare module 'axios' { /** * 覆写AxiosRequestConfig定义 */ export interface AxiosRequestConfig { /** 自定义axios策略 */ strategy?: AjaxStrategy; ...
import React from 'react'; import {BasicLayoutProps, MenuDataItem, PageLoading, Settings as LayoutSettings} from '@ant-design/pro-layout'; import {message, notification} from 'antd'; import {history, RequestConfig} from 'umi'; import RightContent from '@/components/RightContent'; import Footer from '@/components/Footer...
import { CourierFleet } from '@appjusto/types'; import { RouteProp } from '@react-navigation/native'; import { StackNavigationProp } from '@react-navigation/stack'; import firebase from 'firebase'; import { omit } from 'lodash'; import React, { useContext } from 'react'; import { ActivityIndicator, Keyboard, ScrollView...
import { createRule } from "../utils" import type { AST } from "yaml-eslint-parser" import type { YAMLToken } from "../types" import { isCommentToken, isTokenOnSameLine, isQuestion, } from "../utils/ast-utils" import { getActualIndentFromLine, incIndent, hasTabIndent, isKeyNode, } from "../u...
import React, { Fragment } from "react"; import { append, remove } from "ramda"; import Typography from "primitives/Typography"; import Wrapper from "primitives/Wrapper"; import Checkbox from "primitives/Checkbox"; import Button, { ButtonType } from "primitives/Button"; import { Aligns, backgroundColor, capital...
// Ohmura import React from 'react'; import { Link, useHistory } from "react-router-dom" import { fade, makeStyles, Theme, createStyles } from '@material-ui/core/styles'; import AssessmentIcon from '@material-ui/icons/Assessment'; import PersonIcon from '@material-ui/icons/Person'; import HomeIcon from '@material-ui/...
import isAndroid from './detectors/isAndroid'; import isChrome from './detectors/isChrome'; import isEdge from './detectors/isEdge'; import isFirefox from './detectors/isFirefox'; import isIE from './detectors/isIE'; import isIE10 from './detectors/isIE10'; import isIE11 from './detectors/isIE11'; import isIOS from './...
<reponame>DanThrane/phaser-game-off import { Entity } from "./entity"; import { FOREVER, NONE } from "phaser"; import { CharacterEntity } from "./character"; interface IAIMovementParameters { movementSpeed: number, detectionRadius: number, reach: number } interface IExternalReferences { player: Entity, map: Pha...
<reponame>binfn/codemirror.king<filename>search/src/regexp.ts import {Text, TextIterator} from "../../text/src/index.ts" const empty = {from: -1, to: -1, match: /.*/.exec("")!} const baseFlags = "gm" + (/x/.unicode == null ? "" : "u") /// This class is similar to [`SearchCursor`](#search.SearchCursor) /// but search...
<gh_stars>0 import { Aggregate, GetOptions, Filter } from '../types' import { SelvaClient } from '../..' import checkAllowed from './checkAllowed' import validateFilter from './filter' import { get } from '..' import { addExtraQuery, ExtraQueries } from '.' import validateFind from './find' import validateSort from '...
<gh_stars>1-10 import { PluginObject } from 'vue'; import Component from 'vue-class-component'; import { Emit, Prop } from 'vue-property-decorator'; import { Enums } from '../../utils/enums/enums'; import { ModulVue } from '../../utils/vue/vue'; import { ICON_BUTTON_NAME, PROGRESS_NAME, TABLE_NAME } from '../component-...
interface IPoint { x: number; y: number; } type EQSScoringFunction = (point: IEQSPoint) => void; type EQSScoringSpacedFunction = (point: IEQSPoint, grid: Array<Array<IEQSPoint>>, x: number, y: number) => void; interface IEQSOptions { /** The horizontal center of a query */ x: number; /** The verti...
<filename>projects/ontimize-web-ngx/src/lib/components/input/search-input/o-search-input.component.ts import { AfterViewInit, Component, ElementRef, EventEmitter, Injector, OnInit, ViewEncapsulation } from '@angular/core'; import { FormControl, FormGroup } from '@angular/forms'; import { FloatLabelType, MatCheckboxChan...
import React, { useCallback, useState } from 'react' import { ScrollView, StyleSheet, Text, TouchableOpacity, View, } from 'react-native' import { Card, CardDeck } from './Card' import { canIAddCard } from './common/cardUtils' import { CardState } from './common/types' import { Divider } from './Divider' impo...
import { loadWASM } from 'onigasm'; import { Registry } from 'monaco-textmate'; import { wireTmGrammars } from 'monaco-editor-textmate'; declare type monacoType = typeof import("monaco-editor"); import { ASSETSPATH } from './consts'; // import config from './eslintconfig'; declare global { interface Window { ...
<reponame>splitio/javascript-commons import { SplitIO } from '../../../types'; import { SPLIT_IMPRESSION, SPLIT_EVENT } from '../../../utils/constants'; // Mocks import { loggerMock } from '../../../logger/__tests__/sdkLogger.mock'; import { gaMock, gaRemove } from './gaMock'; // Test target import { SplitToGa } from...
import { VOArray, VOArrayUsageHints } from '../VOArray'; import { createAliases } from './createAliases'; import { createAttributes } from './createAttributes'; import { createTypedArrays } from './createTypedArrays'; import { createVO } from './createVO'; import { createVOPrototype } from './createVOPrototype'; impor...
import { truncateMiddle } from "../../utils/capitalize"; import SearchableTable from "../../components/tables/SearchableTable"; import getAccessTokens from "../queries/getAccessTokens"; import deleteAccessToken from "../mutations/deleteAccessToken"; import { ClipboardCopyIcon } from "@heroicons/react/outline"; import c...
<reponame>gristlabs/grainjs /** * Grain.js observables and computeds are similar to (and mostly inspired by) those in * Knockout.js. In fact, they can work together. * * import {fromKo} from 'kowrap' * * fromKo(koObservable) * * returns a Grain.js observable that mirrors the passed-in Knockout observable (whi...
import puppeteer from 'puppeteer'; import { Dict, Order, OrderWithCommission, OrderWithDate } from './types'; import { dateToText, isCloudEngine } from './utils'; const browserPromise = puppeteer.launch({ args: ['--no-sandbox'], headless: isCloudEngine(), }); async function getPage(cookies: puppeteer.SetCookie[] ...
import * as React from "react"; import { createPortal } from "react-dom"; import { NumberFormatValues } from "react-number-format"; import ClickOutsideContainer from "../click-outside-container/click-outside-container"; import { GridCell, GridCellKind, ProvideEditorCallback, Rectangle } from "../data-grid/data-grid-ty...
import * as CassandraLib from 'cassandra-driver'; import { ConnectionDialect, ConnectionInterface, } from '@sqltools/core/interface'; import * as Utils from '@sqltools/core/utils'; import GenericDialect from '../generic'; import Queries from './queries'; import { DatabaseInterface } from '@sqltools/core/plugin-api'; ...
import { makePageMetadata } from 'front-end/lib'; import { Route, SharedState } from 'front-end/lib/app/types'; import { ComponentView, emptyPageAlerts, emptyPageBreadcrumbs, GlobalComponentMsg, Immutable, newRoute, noPageModal, PageComponent, PageInit, Update } from 'front-end/lib/framework'; import * as api from 'fro...
import { Diagnostic, DiagnosticSeverity, Range, Position } from 'vscode-languageserver/node'; import { TextDocument } from 'vscode-languageserver-textdocument'; import * as vscode from 'vscode'; import { Uri, workspace } from 'vscode'; import * as path from 'path'; import * as fs from 'fs'; import * as assert from 'ass...
import React, { useEffect } from "react"; import { makeStyles } from "@material-ui/core/styles"; import Modal from "@material-ui/core/Modal"; import Backdrop from "@material-ui/core/Backdrop"; import Fade from "@material-ui/core/Fade"; import styled from "styled-components"; import TuneIcon from "@material-ui/icons/Tun...
import { createHash } from 'crypto'; import { Redis, RedisOptions } from 'ioredis'; import IORedis from 'ioredis'; import { LoggerFactory } from '@day1co/pebbles'; import type { Logger } from '@day1co/pebbles'; export interface FastCacheOpts { prefix?: string; ttl?: number; redis?: RedisOptions; createRedisCli...
<reponame>aalamdev/ecomm-ui-theme-eng import {Component, OnInit, OnDestroy, Input, Output, EventEmitter} from "@angular/core"; import {ActivatedRoute, Router} from "@angular/router"; import {ECommService} from "./ecomm.service"; import {StockService} from "./stock.service"; import {SettingsService} from "./settings.se...
<filename>src/app/daily-cases/phuMetadata.ts interface PhuMetadata { [k: string]: { name: string; shortName: string; id: string; population: number; } } export const phuMetadata: PhuMetadata = { "2251": { name: "Ottawa", shortName: "Ottawa", id: "2020"...
<reponame>code-to-json/code-to-json<filename>packages/core-linker/src/linker.ts import { SerializedSourceFile, SerializedSymbol, SerializedType, WalkerOutputData, DeclarationRef, TypeRef, } from '@code-to-json/core'; import { SerializedCodePoisition, SerializedCodeRange, SerializedFileReference, Ser...
<reponame>TRIPTYK/training-ecommerce /* eslint-disable @typescript-eslint/explicit-function-return-type */ import * as JSONAPISerializer from "json-api-serializer"; import SerializerInterface from "../interfaces/serializer.interface"; import { RelationMetadata, SchemaOptions } from "../decorators/serializer.decorato...
<reponame>ilcato/homebridge-arduino-cloud<filename>src/arduino-accessory.ts // MIT License // Copyright (c) 2021 ilcato // 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 restrictio...
import Q = require("q"); import TFS_Wit_Contracts = require("TFS/WorkItemTracking/Contracts"); import TFS_Wit_Client = require("TFS/WorkItemTracking/RestClient"); import TFS_Wit_Services = require("TFS/WorkItemTracking/Services"); import Tfs_Work_Contracts = require("TFS/Work/Contracts"); import Tfs_Work_WebApi = req...
import classes from './Scans.module.scss'; import React, { useCallback, useState } from 'react'; import { Button, TextInput, Label, Dropdown, ModalContainer, Overlay, Modal, Form } from '@trussworks/react-uswds'; import { Table } from 'components'; import { Column } from 'react-table'; import { Scan } f...
import * as S from './styles' import ContentAPI from 'services/content-api' import IconButton from '@material-ui/core/IconButton' import ArrowBackIosIcon from '@material-ui/icons/ArrowBackIos' import Button from '@material-ui/core/Button' import AddCircleIcon from '@material-ui/icons/AddCircle' import { DataGrid, Col...
import { MsgExecuteContract } from "@terra-money/terra.js" import { div, times } from "libs/math" import { toAmount } from "libs/parse" import { Type } from "pages/Swap" import { useEffect, useMemo, useState } from "react" import useAPI from "./useAPI" import { tokenInfos } from "./usePairs" type Params = { from: st...
/* * MIT License * * Copyright (c) 2021 <NAME>, <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 rights * to use, copy, m...
<gh_stars>1-10 /** * @license * Copyright 2017-2021 Open Ag Data Alliance * * 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 * * Unle...
<reponame>dota2wiki/dota2wiki<gh_stars>1-10 import * as fs from 'fs'; import * as ps from 'path'; import generateSprites, { SpritesOptions } from '@huiji/image/src/sprites'; import { heroGroups, heroList } from '@dota2wiki/database'; interface ScssOptions { context: string; files: string[]; columns: number; it...
import * as React from "react"; import Select, { SelectProps } from "@material-ui/core/Select"; import FormControl, { FormControlProps } from "@material-ui/core/FormControl"; import InputLabel from "@material-ui/core/InputLabel"; import MenuItem from "@material-ui/core/MenuItem"; import TextField from "@material-ui/cor...
export const DESKTOP_WIDTh = 1024; export const MOBILE_WIDTH = 767; export const IPOHNESE_WIDTH = 340; const lessThan = (maxWidth: number) => `@media (max-width: ${maxWidth}px)`; const between = (minWidth: number, maxWidth: number) => `@media (min-width: ${minWidth}px) and (max-width: ${maxWidth}px)`; const greaterT...
import { ServerlessInstance, SSMParamTypes } from './types'; import { compareParams, evaluateEnabled, validateParams } from './util'; const throwFunction = (message: string): void => { throw new Error(message); }; const logFunction = (message: string): void => { console.log(message); }; // tslint:disable-line:no-conso...
import { Canvas } from '@nativescript-community/ui-canvas'; import { BarLineScatterCandleBubbleDataSet } from '../data/BarLineScatterCandleBubbleDataSet'; import { CombinedData } from '../data/CombinedData'; import { Entry } from '../data/Entry'; import { CombinedHighlighter } from '../highlight/CombinedHighlighter'; i...
import { ref } from 'vue'; import { findValue, toString, getMobile, getUUID } from '../../../libs/utils' import { useStorage } from '../../../libs/storage' import { AxiosGeneral } from '../../../libs/http' import { InputValue, VerifyValue, BaseInfo, Section } from './type'; import { Line } from './draw' import { useSto...
import React from 'react' import ReactDOM from 'react-dom' import { Transition } from '@headlessui/react' interface ModalProps { open: boolean, closeModal: Function deleteEntry: Function } const modalRoot = document.createElement('div') modalRoot.setAttribute('id', 'modal-root') document.body.appendChild...
<gh_stars>0 import { ErrorType, errorInitialState } from '../../../lib/type'; export const ADD_COMMENT = 'Comment/ADD_COMMENT' as const; export const ADD_COMMENT_SUCCESS = 'Comment/ADD_COMMENT_SUCCESS' as const; export const ADD_COMMENT_FAILURE = 'Comment/ADD_COMMENT_FAILURE' as const; export const UPDATE_COMMENT = '...
<filename>javascript/libjoynr-js/src/main/js/joynr/proxy/ProxyEvent.ts<gh_stars>100-1000 /* * #%L * %% * Copyright (C) 2019 BMW Car IT GmbH * %% * 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 Lice...
<filename>src/implementation/service-provider.ts import { Token } from '../interfaces/token'; import { ServiceResolver } from './service-resolver'; import { SarinaDependencyInjectionError } from '../errors'; import { IServiceProvider, SERVICE_PROVIDER_INJECTION_TOKEN } from './../interfaces/service-provider.interface';...
<reponame>SFDigitalServices/bloom<gh_stars>1-10 import { HttpException, HttpStatus, Injectable, NotFoundException } from "@nestjs/common" import { InjectRepository } from "@nestjs/typeorm" import { User } from "./entities/user.entity" import { FindConditions, Repository } from "typeorm" import { scrypt, randomBytes } f...
import { queueMicroTask } from "./taskQueue"; //Describe to TS how I want my types structured, hopefully this will keep me from fucking up. //Main types type Resolvable<T> = thenable<T> | T; type Executor<T> = ( resolve: ResolveHandler<T>, reject: RejectHandler ) => void; interface thenable<T> { then<TResult>(o...
import AppBar from "@material-ui/core/AppBar"; import Badge from "@material-ui/core/Badge"; import CssBaseline from "@material-ui/core/CssBaseline"; import Divider from "@material-ui/core/Divider"; import Drawer from "@material-ui/core/Drawer"; import IconButton from "@material-ui/core/IconButton"; import List from "@m...
import { derived } from "overmind" import { Assignment, Course, Enrollment, Group, Submission, SubmissionLink, User } from "../../proto/ag/ag_pb" import { Color, isPending, isPendingGroup, isTeacher } from "../Helpers" export interface CourseGroup { courseID: number enrollments: number[] users: User[] ...
import { Component, Input, OnChanges, OnDestroy, OnInit, SimpleChanges } from '@angular/core'; import { DataService } from "../data.service"; import { Subscription } from 'rxjs'; import * as d3 from 'd3'; import * as d3Sel from 'd3-selection'; import * as d3Array from 'd3-array'; import { Team, Teams } from 'src/data/d...
<filename>registry/babel-configurer/src/babel-configurer.ts import { ConfigItem, loadOptions, loadPartialConfig, PartialConfig, PluginItem, PluginObj, TransformOptions, } from "@babel/core"; import { setDefaultBy, WebpackConfigurer, WebpackContext } from "@webpackery/core"; import { omit } from "lodash"; ...
<gh_stars>0 import { OpenCPWXCore, IApiConfig, OpenCPWXSuite, ISuiteConfig } from './OpenCPWXCore' import { MsgCrypto, MsgCryptoConfig } from './MsgCrypto' import { Cryptogram } from '@easy-front-core-sdk/kits' import { parseString } from 'xml2js' import { BaseMsg } from './entity/message/BaseMsg' import { InNotDefine...
<reponame>wangweianger/routing-controllers-to-openapi<filename>src/main.ts import * as path from 'path'; import _ from 'lodash'; import { strict as assert } from 'assert'; import type { AnyOpt, InterfaceConfig, InterfaceSchema, InterfaceServers, Openapiv3Config, PropertiesConfigItem } from './types'; import { genTsApiD...
// copy of: https://github.com/semantic-release/semantic-release/blob/master/test/helpers/git-utils.js import * as execa from 'execa'; import { dirname, join } from 'path'; import { mkdirSync, writeFileSync } from 'fs'; import { tempDir, fileUrl } from './path-utils'; /** * Initialize a new git repository. * @param ...
import dayjs from "dayjs"; import relativeTime from "dayjs/plugin/relativeTime"; import Vditor from "vditor"; import {escapeHtml} from "xss"; import pugTpl from "../pug/detail.pug"; import {config} from "./config/config"; import {getSpam} from "./utils/filterSpam"; import {genCommentItemById} from "./utils/genCommentIt...
import { Envs } from '../globals/Envs'; import { IUserInfo } from '../globals/types'; declare global { interface Window { _paq?: any; } } const baseUrl = Envs.API_BASEURL ? Envs.API_BASEURL : `http://${window.location.hostname}:3000/api`; export const createQueryParams = (obj: any): string => { const str =...
'use strict'; import * as events from 'events'; import * as sax from 'sax'; import * as coqProto from '../coq-proto'; import {StateId, EditId, Pair, StateFeedback, LtacProfTactic, LtacProfResults, UnionL, UnionR, Union, OptionState, Subgoal, Goals, Location, MessageLevel, Message, FailValue, UnfocusedGoalStack, Sen...
<gh_stars>10-100 import { addSheets } from './index'; const flexCode = { start: 'flex-start', end: 'flex-end', between: 'space-between', around: 'space-around', }; const shadowList = { sm: (rgb: any, a: any) => `{box-shadow: 0 1px 3px 0 rgba(${rgb}, ${a}), 0 1px 2px 0 rgba(${rgb}, ${a > 0 ? a / 2 : 0});...
import { MeshModel, ScatterModel, VolumeModel } from ".."; // some helper functions to quickly create widgets export async function create_model_ipyvolume(manager, name: string, id: string, args: object) { return create_model(manager, "ipyvolume", `${name}Model`, `${name}View`, id, args); } export async function...
<reponame>mopedjs/moped<gh_stars>10-100 import {Application} from 'express'; import WebpackDevServer = require('webpack-dev-server'); import prepareProxy, {ProxyConfig} from './prepareProxy'; const errorOverlayMiddleware = require('react-dev-utils/errorOverlayMiddleware'); const noopServiceWorkerMiddleware = require('...
import debug from 'debug'; import { User } from '../common'; import { omit, generateRID } from '../utils'; import * as API from '../api'; import { validateUser } from '../validation'; import * as Req from '../request'; import * as Res from '../response'; import { Config } from './Config'; /** * API endpoint. */ inte...
import { HttpClient } from '@angular/common/http'; import { UploadAdapter } from './upload-adapter'; import { Component, OnInit, ViewChild, ElementRef, Input, forwardRef, AfterViewInit, NgZone, Output, EventEmitter, OnDestroy } from '@angular/core'; import { NG_VALUE_ACCESSOR, ControlValueAccessor...
import { sprintf } from 'sprintf-js'; export const HEADER_LENGTH = 8; export const TYPE: { [key: string]: number } = { SQL_BATCH: 0x01, RPC_REQUEST: 0x03, TABULAR_RESULT: 0x04, ATTENTION: 0x06, BULK_LOAD: 0x07, TRANSACTION_MANAGER: 0x0E, LOGIN7: 0x10, NTLMAUTH_PKT: 0x11, PRELOGIN: 0x12, FEDAUTH_TO...
import { ComponentProps, Dispatch, Fragment, SetStateAction, useState } from 'react'; import styled from 'styled-components'; import { AssetIcon, Box, Currency, EthAddress, FixedSizeCollapsibleTable, Icon, TableCell, TableRow, Text, Tooltip, Typography } from '@components'; import { COLORS, SPAC...
import { log } from '@guardian/libs'; import { EventTimer } from './event-timer'; type Metric = { name: string; value: number; }; type Property = { name: string; value: string; }; type TimedEvent = { name: string; ts: number; }; type EventProperties = { type?: ConnectionType; downlink?: number; effectiveTy...
import { LatLngLiteral, CRS } from "leaflet"; // import LatLonEllipsoidal_Vincenty from "geodesy/latlon-ellipsoidal-vincenty"; // import LatLonSpherical from "geodesy/latlon-spherical"; type DistanceFunction = (p1: LatLngLiteral, p2: LatLngLiteral) => number; const radPerDeg = Math.PI / 180; const earthMeanRadiusInM ...
import { useCallback, useEffect, useState } from "react"; import styled, { css } from "styled-components"; import { Typography, SelectChangeEvent } from "@mui/material"; import { NextPage } from "next"; import { DriversNearbyEtas } from "@api/packages/splyt-taxis"; import { toast } from "react-toastify"; import { Fu...
import classNames from 'classnames'; import * as React from 'react'; import { Link } from 'react-router-dom'; import HeavenlyBucketIcon from 'src/assets/icons/promotionalOffers/heavenly-bucket.svg'; import Button from 'src/components/core/Button'; import Paper from 'src/components/core/Paper'; import { makeStyles, Them...
import fs from "fs" import { GatsbyNode } from "gatsby" import path from "path" import Prism from "prismjs" // https://prismjs.com/#supported-languages import "prismjs/components/prism-jsx" import "prismjs/components/prism-scss" import "prismjs/components/prism-typescript" import { DemoBase, DemoPageProps, DemoS...
<filename>source/all.ts // Styles // https://en.wikipedia.org/wiki/ANSI_escape_code#SGR_parameters // Colors // https://en.wikipedia.org/wiki/ANSI_escape_code#3/4_bit export enum Color { Black = 0, Red = 1, Green = 2, Yellow = 3, Blue = 4, Magenta = 5, Cyan = 6, White = 7, } /** A factory method to generate a...
import { Component, h, Element, Event, EventEmitter, ComponentInterface, Prop } from '@stencil/core'; import { MDCRipple } from '@material/ripple/index'; const win = window as any; @Component({ tag: 'o-demo-fab', styleUrl: 'o-demo-fab.scss', shadow: true }) export class DemoFabComponent implements ComponentInte...
/* eslint-disable @typescript-eslint/unified-signatures */ import { EventEmitter } from 'stream'; import { EmptyInterface, GetSetCheck } from './Util'; export abstract class BaseThrottleInstance { public id: any; public counter = 0; public readonly manager: BaseThrottleManager<BaseThrottleInstance>; public co...
<reponame>hectorhdzg/azure-sdk-for-js // Copyright (c) Microsoft Corporation. // Licensed under the MIT license. import { OperationOptions } from "@azure/core-client"; import { ErrorDetail, LogsColumnType } from "../generated/logquery/src"; import { TimeInterval } from "./timeInterval"; // https://dev.loganalytics.io...
<reponame>simllll/eslint-plugin-vue-scoped-css import { parse } from "../../parser" import { AST, SourceCode, RuleContext, LineAndColumnData } from "../../../types" import { VCSSStyleSheet, VCSSNode } from "../../ast" import { isVCSSContainerNode } from "../../utils/css-nodes" /** * Check whether the program has inva...
import { UnexpectedUrlFormatError } from "./UnexpectedUrlFormatError"; // /** // * This error is thrown by functions that expect a URL to be in a certain format // * and are given a URL (or other text string) that does not match the expected format. // * @member {string} message `Unexpected URL format. ${url} does ...
<gh_stars>0 import { Block, Hash } from "hycon-common" import { getLogger } from "log4js" import Long = require("long") import { DifficultyAdjuster } from "../consensus/difficultyAdjuster" import { hashCryptonight } from "../util/cryptonight" import { MinerServer } from "./minerServer" // tslint:disable-next-line:no-...
<gh_stars>1-10 declare var window: any; window.AudioContext = window.AudioContext || window.webkitAudioContext; window.OfflineAudioContext = window.OfflineAudioContext || window.webkitOfflineAudioContext; const KEYS: string[] = "c,db,d,eb,e,f,gb,g,ab,a,bb,b".split(","); const FREQ: number[] = []; const mixers = new ...
import * as React from 'react'; import MenuHeader from './header'; import MenuLink from './link'; import MenuAvatar from './avatar'; import MenuStatus from './status'; import MenuItem from './item'; import Button from '../button'; import './styles.story.scss'; export default { title: 'Menu', decorators: [ s...
import {shouldInterruptAfterDeadline} from "quickjs-emscripten"; import {augmentRawMailWithFolders, resolveCachedQuickJSInstance} from "src/electron-main/api/util"; import {Context} from "src/electron-main/model"; import {Folder, FsDbAccount, IndexableMailId, Mail, View} from "src/shared/model/database"; import {IpcMa...
import { isHTMLComponent } from './component.js'; import { findByModelClassOrCreat } from '../reflect/bootstrap-data.js'; import { ComponentRef } from '../elements/elements.js'; export interface AttrRef { readonly [attr: string]: string[]; } /** * @see https://html.spec.whatwg.org/multipage/indices.html#element...
import paper from 'paper' import conversions from './conversions' import layerBuilders from './layerBuilders' import uuid from 'uuid/v4' import fs from 'fs' import extract from 'extract-zip' import os from 'os' /** * Represents the contents of an svg document and any external assets which need to bundled along with i...
import { AdditiveBlending, UnsignedInt248Type, NearestFilter, RGBFormat, DepthStencilFormat, GLSL3 } from 'three/src/constants'; import { WebGLRenderTarget } from 'three/src/renderers/WebGLRenderTarget'; import { Float32BufferAttribute } from 'three/src/core/BufferAttribute'; import type { WebGLRenderer } from 'three/s...
import React, {useState, useEffect} from 'react'; import {NextPage, GetStaticPaths, GetStaticProps} from 'next'; import dynamic from 'next/dynamic'; import {useRouter} from 'next/router'; import useTranslation from 'next-translate/useTranslation'; import Skeleton from 'react-loading-skeleton'; import Container from '....
import React, { useEffect } from 'react'; import Link from 'next/link'; import { useRouter } from 'next/router'; import Image from 'next/image'; import MobileNav from './MobileNav'; import { ArrowDown, ArrowTail } from 'components/icons'; import styled from 'styled-components'; import { submenuHover, submenuClick } fro...
<gh_stars>0 import EventEmitter from '../../utils/event-emitter'; import { isIE } from '../../utils/browser'; import { parseProxyUrl } from '../../utils/url'; import * as destLocation from '../../utils/destination-location'; import nativeMethods from '../native-methods'; import { StorageProxy } from '../../../typings/c...
// Copyright 2021 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 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 { SavedObject, SavedObjectsBulkCreateObject, SavedObjectsClientC...
//@ts-nocheck import React, { useRef, useState } from 'react'; import { ReactComponent as Icon } from '../assets/icons/drag.svg'; import { Container, Draggable } from 'react-smooth-dnd'; import ConditionModal from './ConditionModal'; import ActionsModal from './ActionsModal'; import useClickOutside from '../utils/useCl...
/********************************************************************** * Copyright (C) 2022 Red Hat, 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/lic...
<reponame>voxlz/car-dealership import express from 'express'; import { MongoClient, ObjectID } from 'mongodb'; import data from '../data/data.json'; import bcrypt from 'bcrypt'; // Set up express const app = express(); app.use(express.json()); app.use(express.urlencoded()); const epPort = 5000; const dbURI = 'mongo...