text stringlengths 3.08k 15.5k |
|---|
<gh_stars>100-1000
import { RandomLoadingMessage } from '#utils/constants';
import { send } from '@sapphire/plugin-editable-commands';
import { Guild, GuildAuditLogsAction, GuildChannel, Message, MessageEmbed, Permissions, ThreadChannel, UserResolvable } from 'discord.js';
/**
* Image extensions:
* - bmp
* - jpg
*... |
import { BottomTabBarOptions, BottomTabNavigationOptions, createBottomTabNavigator } from '@react-navigation/bottom-tabs'
import { createStackNavigator, TransitionPresets } from '@react-navigation/stack'
import React from 'react'
import { StyleSheet } from 'react-native'
import Icon from 'react-native-vector-icons/Mate... |
<filename>packages/database/src/core/view/View.ts
/**
* @license
* Copyright 2017 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
*
* http://www.apache.org/licenses/LICEN... |
import { Color } from '../../../protocol/color';
import { mergePreferences, Preference } from '../../../protocol/preference/preference';
import { CumulatedStatistic } from '../../../protocol/statistic/cumulatedstatistic';
import { Statistic } from '../../../protocol/statistic/statistic';
import { StatisticType } from '... |
import { enqueueTask } from '@nishans/endpoints';
import { TBlock, TBasicBlockType, ISpace, IPage, ICollectionBlock, TData } from '@nishans/types';
import { TBlockInput, NishanArg, RepositionParams } from '../types';
import { createBlockClass, createBlockMap, generateId, Operation } from '../utils';
import Data from '... |
<reponame>d-georgiev-91/igniteui-js-blocks
import { Pipe, PipeTransform, Inject } from '@angular/core';
import { DatePipe } from '@angular/common';
import { IGX_TIME_PICKER_COMPONENT, IgxTimePickerBase } from './time-picker.common';
import { DatePart } from '../directives/date-time-editor/public_api';
const ITEMS_COUN... |
/** @jsx jsx */
import React, { RefObject, useEffect, useState } from 'react'
import { jsx, Themed } from 'theme-ui'
import { Col, Container, Row } from '@uswitch/trustyle.flex-grid'
const makeStyles = (variant?: string) => (element?: string) =>
`compounds.collection-tabs${variant ? `.variants.${variant}` : `.base`}... |
import Link from '@/components/Link'
import { PageSEO } from '@/components/SEO'
import Tag from '@/components/Tag'
import siteMetadata from '@/data/siteMetadata'
import { getAllFilesFrontMatter, getFileBySlug } from '@/lib/mdx'
import formatDate from '@/lib/utils/formatDate'
import { GetStaticProps, InferGetStaticProps... |
/* eslint-disable complexity */
/* eslint-disable max-lines-per-function */
import { List } from "./List";
import { Epsilon } from "../Epsilon";
import type { Point, Segment, XEvent, compare } from "../types";
function eventCompare(e1: XEvent, e2: XEvent): compare {
// compare the selected points first
let comp = E... |
/**
* The GherkinParser function provided by Cucumber returns the Gherkin AST representation of a feature file.
* The Gherkin AST for a feature file consists of either a GherkinDocument (when parsing is successful)
* or an array of GherkinError objects (when the file cannot be successfully parsed). The Parser servic... |
import {ChangeDetectionStrategy, ChangeDetectorRef, Component, OnInit, ViewChild} from '@angular/core';
import {
EdgeService,
GraphDataService,
NodeService,
SGEdge,
SGNode,
SmrtGraphData,
SmrtgraphCoreComponent
} from "@ncats-frontend-library/shared/smrtgraph/smrtgraph-core";
import {SctlNode, SctlNodeSer... |
import express from "express";
import compression from "compression"; // compresses requests
import session from "express-session";
import bodyParser from "body-parser";
import logger from "./util/logger";
import lusca from "lusca";
import dotenv from "dotenv";
import mongo from "connect-mongo";
import flash from "exp... |
<reponame>griffithlab/civic-v2
import { Component, OnInit, Input, OnDestroy, AfterViewInit } from '@angular/core';
import { AbstractControl, FormGroup } from '@angular/forms';
import { Subject } from 'rxjs';
import { takeUntil } from 'rxjs/operators';
import {
GeneRevisableFieldsGQL,
Organization,
SuggestGene... |
<reponame>noscripter/tsd<filename>src/xm/typeOf.ts
/// <reference path="./_ref.d.ts" />
'use strict';
import typeDetect = require('type-detect');
var toString = Object.prototype.toString;
export function get(value: any): string {
return typeDetect(value);
}
export var jsonTypes: string[] = [
'array',
'object',
... |
<gh_stars>0
import * as ts from 'typescript'
import {
ContainerType,
FieldDefinition,
InterfaceWithFields,
SyntaxType,
UnionDefinition,
} from '@creditkarma/thrift-parser'
import {
COMMON_IDENTIFIERS,
THRIFT_IDENTIFIERS,
THRIFT_TYPES,
} from '../identifiers'
import {
createNumberT... |
import { EVENTS } from './constants/index'
import { EventEmitter } from 'events'
type OperateType = 'undo' | 'redo' | 'custom'
const EXECUTOR_RESULT_NEXT = 'next'
const EXECUTOR_RESULT_BREAK = 'break'
type ExecutorResult = (typeof EXECUTOR_RESULT_NEXT) | (typeof EXECUTOR_RESULT_BREAK)
export interface Task {
type?... |
<reponame>shrinktofit/engine
/*
Copyright (c) 2017-2018 <NAME> Software Co., Ltd.
http://www.cocos.com
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated engine source code (the "Software"), a limited,
worldwide, royalty-free, non-assignable, revocable a... |
<reponame>hailbopp/DoubleTrouble<filename>src/DoubleTroubleServer/handlers.ts
import { WebsocketEvent } from "DTCore/common";
import {
ActionCase,
ActionCreators,
AppAction,
} from "DoubleTrouble/actions";
import { createDatastoreObject } from "./data";
import { getConfig } from "./config";
import * as HashLib fr... |
<gh_stars>0
import { device } from 'aws-iot-device-sdk';
import { green, yellow, magenta, blue } from 'colors';
enum JobExecutionStatus {
QUEUED = 'QUEUED',
IN_PROGRESS = 'IN_PROGRESS',
SUCCEEDED = 'SUCCEEDED',
FAILED = 'FAILED',
TIMED_OUT = 'TIMED_OUT',
REJECTED = 'REJECTED',
REMOVED = 'REMOVED',
CANC... |
import _ from 'lodash/fp';
import {SYMBOL, SIDE, ORD_TYPE, EXEC_INST} from 'redux/api/bitmex/types';
import {skewedProbabilityMap, uniformProbabilityMap} from './mathHelpers';
import {tickerRound, parseNumber} from '../general/formatting';
import {Order} from 'redux/api/bitmex/types';
export enum DISTRIBUTION {
Unif... |
import { getClient } from "azure-devops-extension-api";
import {
GitRestClient,
GitPullRequest,
GitCherryPick,
GitAsyncRefOperationParameters,
GitPullRequestMergeStrategy,
GitAsyncOperationStatus,
GitRepository,
GitPullRequestSearchCriteria,
PullRequestStatus
} from "azure-devops-extension-api/Git";
... |
<reponame>amuelle/bdeploy
import { Type } from '@angular/core';
import { SortDirection } from '@angular/material/sort';
/**
* A type hint for the colum which may (mostly in card mode) have influence on where and how information is rendered.
*/
export enum BdDataColumnTypeHint {
/* The type, an uppercased text at t... |
import { differenceWith, isEqual } from "lodash";
import { combineLatest, Observable } from "rxjs";
import {
distinctUntilChanged,
startWith,
switchMap,
tap,
filter,
scan,
pluck,
skip
} from "rxjs/operators";
import { compareString } from "../helpers";
export const combineLatestImmediate = <T>(
obser... |
/*
* Copyright 2021 <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 applicable law or agreed to in writin... |
// eslint-disable-next-line no-unused-vars
import React from 'react';
import { navigator } from 'global';
import { objectOf, string } from 'prop-types';
import { get, setAll } from './persist';
export const isMacLike = () => (navigator && navigator.platform ? !!navigator.platform.match(/(Mac|iPhone|iPod|iPad)/i) : fal... |
import * as Lint from 'tslint';
import * as utils from 'tsutils';
import * as ts from 'typescript';
const AFTER_IMPORTS = 'after-imports';
const ABOVE_CONDITIONAL = 'above-conditional';
const ABOVE_METHOD = 'above-method';
const DEFAULT_COUNT_OF_BLANK_LINES = 1;
const enum CharacterCodes {
lineFeed = 10, ... |
// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
// See LICENSE.txt for license information.
import React, {useState} from 'react';
import {useIntl} from 'react-intl';
import {useSelector} from 'react-redux';
import styled from 'styled-components';
import {Droppable, DroppableProvided} from 'react-b... |
import * as vscode from 'vscode'
import { camelCase } from 'change-case'
import { defaultJsSupersetLangsWithVue } from '@zardoy/vscode-utils/build/langs'
import { getExtensionSetting } from 'vscode-framework'
import pluralize from 'pluralize'
export const fromInsertCompletions = {
value: false,
}
export const reg... |
import React from 'react';
import { action, computed } from 'mobx';
import { observer } from 'mobx-react';
import { GameQueryType } from '../transport/GameQueryType';
import { ActorAttributes, PlayerAdaptations, PlayerSkills, PlayerInventory } from '../transport/DialogData';
import { ActorAttributesScreen } from './Cre... |
import * as functions from 'firebase-functions';
const environment = functions.config().env;
const nodeEnv = process.env.NODE_ENV || 'development';
const whitelist = nodeEnv === 'development'? ['http://localhost:4200'] : [
environment.firebase.appURL,
environment.firebase.databaseURL
];
const corsOptionsDelegate = ... |
<reponame>nigma456/AutoLispExt<filename>extension/src/process/acadPicker.ts
//
// acadPicker.ts
//
// CREATED BY: yunjian.zhang DECEMBER. 2018
//
// DESCRIPTION: Lisp vscode extension core code.
//
'use strict';
import * as vscode from 'vscode';
import * as os from 'os';
import { basename } from 'path';... |
import { Client, Event, Exception, Stat } from "node-zookeeper-client";
import dayjs from "dayjs";
import logEvent from "./LogEvent";
import { TreeNodeNormal } from "antd/es/tree/Tree";
import { message } from "antd";
const { Buffer } = window.require("buffer");
const nodeZookeeperClient = window.require("node-zookeep... |
<gh_stars>0
import { Category } from './enums';
import { Book, Logger, Author, Librarian, Magazine } from './interfaces';
import { UniversityLibrarian, ReferenceItem } from './classes';
import { CalculateLateFee as CalcFee, MaxBooksAllowed, Purge } from './lib/utilityFunctions';
import Encyclopedia from './Encyclopedia... |
import React, { Component } from 'react';
import AgoraRtcEngine from 'agora-electron-sdk';
import { List, Card, Input } from 'antd';
import config from '../../config/agora.config';
import styles from '../../config/public.scss';
import JoinChannelBar from '../../component/JoinChannelBar';
import Window from '../../compo... |
import * as React from 'react';
import { useState, useEffect, useRef, useMemo } from 'react';
import namespace from '@namespace';
import classnames from 'classnames';
import Trigger from '@components/trigger';
import Selection from './components/selection';
import Option, { OptionProps } from './components/option';
imp... |
import { FC, useRef, useState } from "react";
import { css } from "demitasse";
import cx from "clsx";
export const styles = css({
container: {
display: "inline-flex",
borderWidth: 1,
borderStyle: "solid",
borderColor: "rgb(var(--light))",
borderRadius: 4,
paddingRight: 0,
paddingLeft: 7,
... |
<gh_stars>0
import { Player, MAX_VELOCITY_X } from './player';
import { zeroAccelerationIfBlocked } from "./utils";
export class HosePlayer extends Player {
cursors: Phaser.Types.Input.Keyboard.CursorKeys;
particles: Phaser.Physics.Arcade.Group;
isAnchored: boolean;
NUM_PARTICLES = 400;
ACCELERATI... |
<filename>src/ts/menulayer.ts<gh_stars>0
import LabelButton from './labelbutton';
import MyColor from './mycolor';
import ScreenSize from './screensize';
import Cursor from './cursor';
import GamepadManager from './gamepadmanager';
// ラベルの位置、x座標
const LABEL_POS_X = Math.floor(ScreenSize.SCREEN_WIDTH * 0.5);
//... |
import { DartPlayed, Difficulty,
GameEvent, VoiceCommand, DartBaseValue, DartMultiplier, DartStatus } from './types.ts';
import { PlayerStatus, GameEngine, lastNumberOfPlayers } from './gameengine.ts';
import { Language } from './language.ts';
import { isIgnored, getDartDescription } from './utils.ts';
let lastDiffi... |
import React from "react";
import { Tag } from "./components/Tag";
import { classSelectors } from "./utils/selectors";
type Significance =
| "LIGHT"
| "SUCCESS"
| "DANGER"
| "WARNING"
| "INFO"
| "DARK";
type TagType = { name: string; significance: Significance };
type Tags = TagType[];
type Colors = { back... |
<reponame>burmecia/supabase<filename>studio/stores/content/ProjectContentStore.ts
import { makeAutoObservable } from 'mobx'
import { keyBy } from 'lodash'
import { get, post, patch, delete_ } from 'lib/common/fetch'
import { LogSqlSnippets, UserContent, UserContentMap } from 'types'
import { IRootStore } from '../Root... |
<reponame>shubanker/CodingProblems<gh_stars>0
import { runTests } from "../../test";
/**
My Calendar I
Implement a MyCalendar class to store your events. A new event can be added if adding the event will not cause a double booking.
Your class will have the method, book(int start, int end). Formally, this represents a ... |
import React from "react";
import styled from "styled-components";
import { motion, AnimatePresence } from "framer-motion";
import { Container as ContentContainer } from "../container";
import AppStore from "../../images/svg/app-store-icon.svg";
import GooglePlay from "../../images/svg/google-play-icon.svg";
import A... |
import { ITraceParent } from "../JavaScriptSDK.Interfaces/ITraceParent";
import { generateW3CId } from "./CoreUtils";
import { findMetaTag, findNamedServerTiming } from "./EnvUtils";
import { isArray, isString, strTrim } from "./HelperFuncs";
// using {0,16} for leading and trailing whitespace just to constrain the po... |
import { IAM } from 'aws-sdk';
import * as _ from 'lodash';
import { getLogger } from 'log4js';
import { Policy } from '../../types/aws';
import { ResourceClient } from '../client';
import { md5 } from '../utils';
import { IAMClient } from './aws';
import { KubernetesRole } from './kubernetes-config';
import { transl... |
import React from 'react'
import * as Elements from '../shared-elements/'
import { useRouteMatch, Route, Link, Switch } from 'react-router-dom'
import BookingDetails from './BookingDetails'
import CreateBooking from './CreateBooking'
import * as types from '../types'
import NotFound from './NotFound'
import * as helper... |
<gh_stars>0
/*! server.ts
* Flamingos are pretty badass!
* Copyright (c) 2018 <NAME>; Licensed MIT */
import {
createConnection,
TextDocuments,
TextDocument,
Diagnostic,
DiagnosticSeverity,
ProposedFeatures,
InitializeParams,
DidChangeConfigurationNotification
} from 'vscode-languageserver';
import * as Patter... |
<filename>src/core/tracker/tracker.buttons.ts
import { User, PartialUser } from "discord.js";
import { ProgTracker, ProgTrackerType, vowXp } from "./tracker.model";
import { Player, Storage } from "../discord/storage";
import { sub, add } from "./tracker.manager";
import { d, rollProgressDice } from "../dice/dice.utils... |
<filename>src/app/pages/vuupl-admin/token-request-details/token-request-details.component.ts
import { IcoService } from './../../../providers/ico/ico.service';
import { FormGroup, FormBuilder, Validators } from '@angular/forms';
import { Component, OnInit } from '@angular/core';
import { ServerApiService } from '../../... |
/*********
* TYPES *
*********/
export enum STypes {
Symbol,
Number,
Boolean,
Nil,
List,
Boxed,
}
export interface SSymbol {
_type: STypes.Symbol;
val: string;
}
export interface SNumber {
_type: STypes.Number;
val: number;
}
export interface SBoolean {
_type: STypes.Boolean;
val: boolean;... |
<filename>src/components/PlotlyChart.ts
import { CSSProperties, Component, createElement } from "react";
import { MapDispatchToProps, connect } from "react-redux";
import { bindActionCreators } from "redux";
import * as classNames from "classnames";
import deepMerge from "deepmerge";
import { ChartLoading } from "./Ch... |
import React, { Fragment, useState } from 'react';
import Image from 'next/image'
import styles from './modalPokemon.module.scss'
import { POKEMONS_TYPES_COLORS } from '../../pages/pokedex';
import { Pokemon } from '../../../types/pokedeTypes';
type ModalPokedex = {
data: Pokemon
onClose(): void
}
const ... |
<gh_stars>0
import { DataTypes, DomUtils, Utils } from '@etsoo/shared';
/**
* EOEditor Image Editor language labels
*/
export type EOImageEditorLabelLanguage = {
bgColor: string;
blur: string;
brightness: string;
bringToBack: string;
bringToFront: string;
brownie: string;
close: string;
... |
import { Command, CommandStore } from 'klasa';
import { Canvas } from 'canvas-constructor';
import fetch from 'node-fetch';
import { promises as fsp } from 'fs';
import { join } from 'path';
import { Message} from '@klasa/core';
const THEMES_FOLDER = join(__dirname, "..", "..", "assets", "public", 'img', 'banners');
... |
/**
* Wechaty Open Source Software - https://github.com/wechaty
*
* @copyright 2022 <NAME> (李卓桓) <https://github.com/huan>, and
* Wechaty Contributors <https://github.com/wechaty>.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in ... |
import React, { FunctionComponentElement, useContext, useEffect, useRef, useState } from 'react'
import classNames from 'classnames'
import ConfigContext from '../config-provider/ConfigContext'
import { getCompProps } from '../_utils'
import devWarning from '../_utils/devwarning'
import Marks from './marks'
import Step... |
<reponame>FinnbarrOC/awrtc_browser
/*
Copyright (c) 2019, because-why-not.com Limited
All rights reserved.
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright no... |
<gh_stars>0
import { Nodes } from '../nodes';
import { PositionCapableError } from '../NodeError';
import { walkPreOrder } from '../walker';
import { TokenError, IToken } from 'ebnf';
import { parser } from '../../grammar';
import { ParsingContext } from '../ParsingContext';
/// --- PARSING PHASE ---
const process = ... |
<filename>packages/solid-a11y-docs/vite-plugins/component-docs.ts
import type { TSESTree } from "@typescript-eslint/types";
import { type AST, parse } from "@typescript-eslint/typescript-estree";
import { resolve } from "path";
import type { Plugin } from "vite";
import type { ComponentPropertyDescriptor } from "../sr... |
<reponame>dtantalidis2002/netbox
import { readableColor } from 'color2k';
import { findFirstAdjacent, getElements } from '../util';
import type SlimSelect from 'slim-select';
/**
* Add or remove a class to the SlimSelect element to match Bootstrap .form-select:disabled styles.
*
* @param action `enable` or `disabl... |
<reponame>dlevs/parse-midi
/**
* Return either `offValue` or `onValue` depending on the `controlValue` passed.
*/
const onOff = <T1, T2>(controlValue: number, offValue: T1, onValue: T2) =>
controlValue < 64 ? offValue : onValue;
/**
* Return either `offValue` or `onValue` depending on the `controlValue` passed.
*... |
<gh_stars>1-10
import ShareDB from 'sharedb';
import ShareDBMingo from 'sharedb-mingo-memory';
import { Doc } from 'sharedb/lib/client';
import { anything, instance, mock, verify, when } from 'ts-mockito';
import { ConnectSession } from './connect-session';
import { MetadataDB } from './metadata-db';
import { Migration... |
import { getRandom, random } from '.';
import {
WoWClass,
PlayableRace,
Bracket,
HordeRace,
AllianceRace,
Battleground,
Battledata
} from './battleground.types';
/**
* builds a character and adds them to the roster as many times as the team size
* @param factionRaces - an array of the faction's races
... |
<filename>src/gallery.ts<gh_stars>10-100
import * as vscode from "vscode";
import {
ContextVars,
getNonce,
getWebviewResource,
insertContext,
PATHS,
WebviewResources,
} from "./globals";
import * as fs from "fs";
import * as path from "path";
import Axios from "axios";
import axios from "axios";
const VERS... |
// Copyright (c) 2022 <NAME> <<EMAIL>>
//
// 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, modify, merge, publi... |
import {injectable, inject} from 'inversify';
import {Identity} from 'openfin/_v2/main';
import {Application, AppName, AppId} from '../../client/directory';
import {Inject} from '../common/Injectables';
import {Signal0} from '../common/Signal';
import {AppWindow} from './AppWindow';
import {ContextChannel} from './Co... |
import { Game } from '@database/entity/Game';
import { TagCategory } from '@database/entity/TagCategory';
import { ParsedCurationMeta } from './parse';
import { EditCurationMeta } from './types';
/**
* Convert game into a raw object representation in the curation format.
* @param game Game to convert.
*/
export fun... |
import { FunctionalComponent, h, Fragment } from 'preact'
import { useRef, useState, useEffect } from 'preact/hooks'
import cx from 'classnames'
import * as Machine from '../machine/types'
import Button, { ButtonType } from './button'
import { toSongAndVideoTitle } from '../lib/to-title'
import ListIcon from '../icons/... |
import {
Component,
OptionsFunc,
GatherProps,
getUniqueID,
Replace,
setDefault,
StyleValue,
Visibility,
CoercableComponent
} from "features/feature";
import JobComponent from "features/job/Job.vue";
import { createResource, Resource } from "features/resources/resource";
import { Pers... |
<reponame>alistat/share-todo-list
import {ChangeDetectorRef, Component, ElementRef, EventEmitter, OnInit, Output, SecurityContext} from '@angular/core';
import { DomSanitizer, SafeHtml } from "@angular/platform-browser";
import {ListService, TodoListManager} from "../services/list.service";
import {UsersService} from "... |
import MagicString, {SourceMap as MSSourceMap} from 'magic-string'
import {Node, Parser, Options} from 'acorn'
const { extend } = require('acorn-jsx-walk')
const {base, simple} = require('acorn-walk')
const jsxParser = require('acorn-jsx')
const merge = require('merge-source-map')
export const JSXParser = Parser.exte... |
<gh_stars>1-10
import { init } from '../config';
import type { Transitions, IOptions, Easing, CustomEasing } from '../types';
import { clean } from '../utils';
import { addMediaQueries } from './mediaQueries';
import { addVendors } from './stylesGeneration';
/**
* Get the new updated styles to work both on the previo... |
<filename>src/services/lead.service.ts
import { Lead } from '../postgres/lead';
import { IActivity, ActivityService } from './activity.service';
import { Promise as Bluebird } from 'bluebird';
import * as moment from 'moment';
import * as Sequelize from 'sequelize';
import { UserService, IIUser } from './user.service';... |
'use strict';
import * as vscode from 'vscode';
import Window = vscode.window;
import QuickPickItem = vscode.QuickPickItem;
import QuickPickOptions = vscode.QuickPickOptions;
import Document = vscode.TextDocument;
import Position = vscode.Position;
import Range = vscode.Range;
import Selection = vscode.Select... |
<reponame>upvalue/meditations<filename>src/habits/main.tsx
// main.tsx - Main habits file; routing & socket handling
import * as React from "react";
import moment from "moment";
import route from "riot-route";
import { reverse, rangeRight } from "lodash";
import * as common from "../common";
import {
ScopeType,
... |
<filename>src/lib/mutuality-parser.ts<gh_stars>0
import { intersection } from 'lodash';
import {
findLocalizedStringByPredicate,
findStringByPredicate,
findStringsByPredicate,
stringToNTriples,
Triple
} from 'ntriples-collection';
import { AgentAccess } from './agent-access';
import { Mutuality } from './mutu... |
<reponame>csoszka/apicurio-studio<filename>front-end/studio/src/app/pages/apis/{apiId}/editor/_components/forms/operation/content.component.ts
/**
* @license
* Copyright 2017 JBoss Inc
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the Lice... |
<gh_stars>1-10
import { deprecated } from "aurelia-metadata";
import { deprecate } from "util";
/**
* This file is part of Webelexis
* Copyright (c) 2015-2018 by <NAME>
*/
/*
Convert consultation entries between Elexis' Samdas-Format and HTML
*/
const parser = new DOMParser();
const serializer = new XMLSeriali... |
/* spellchecker: disable */
import { vec2, vec3, GLclampf3, GLclampf4 } from '@haeley/math';
import {
rgb2srgb, srgb2rgb, srgba2rgba, srgb2xyz, xyz2srgb,
D65
} from './conversion';
import { DEFAULT_GAMMA } from './color';
/* spellchecker: enable */
/**
* "Daltonization is a procedure for adapting colors... |
import classNames from "classnames";
import { RetweetIcon } from "components/Icons";
import Image from "components/Image";
import { TweetHashtagModel, TweetModel, TweetUserMentionModel } from "models";
import React from "react";
import { connect, ConnectedProps } from "react-redux";
import { AppDispatch, AppState } fro... |
<reponame>mattiascibien/itch
import * as bluebird from "bluebird";
import * as invariant from "invariant";
import * as ospath from "path";
import sf from "../../util/sf";
import butler, {IExePropsResult} from "../../util/butler";
import os from "../../util/os";
import {filter, map, sortBy} from "underscore";
impor... |
/**
* Specification of a command line argument.
*
* Command line argument are not preceded by a hyphen, and must appear in
* order. A typeical command line argument is the input file name.
*
* Each command line argument must specify the name of the attribute under which
* its content is returned in `field`. If... |
<reponame>Tonium-io/devex<filename>proposal-47/submission-7/contracts/components/true-nft-core/tests/main.test.ts
import { TonClient } from "@tonclient/core";
import { createClient } from "@ton-contracts/utils/client";
import TonContract from "@ton-contracts/utils/ton-contract";
import { callThroughMultisig } from "@to... |
import _ = require("lodash");
import events = require("events");
import crypto = require("crypto");
import flux = require("flux");
import dispatcher = require("./dispatcher");
////////////////
export enum DataStatus { READY, INFLIGHT };
// Wrapper around items that get stored in Store
export interface StoreObject {
... |
<filename>src/index.ts
import * as core from '@actions/core';
import * as glob from '@actions/glob';
import { readFileSync, writeFile, createReadStream } from 'fs';
import * as readline from 'readline';
async function run() {
try {
const version = core.getInput('version');
let globPattern =... |
<reponame>abea/DIM
import { DimItem } from 'app/inventory/item-types';
import { DimStore } from 'app/inventory/store-types';
import { amountOfItem, getCurrentStore, getStore } from 'app/inventory/stores-helpers';
import { pullFromPostmasterAmount } from 'app/loadout-drawer/postmaster';
import { itemCanBeEquippedBy, ite... |
import * as React from "react";
import GestureView, { PagerIndex } from "react-page-controller";
import { ArrowRight, ArrowLeft } from "./Icons";
import { Indicators } from "./Indicators";
export interface GalleryProps extends React.HTMLAttributes<HTMLDivElement> {
index: PagerIndex;
onRequestChange: (i: number) =... |
import { Box, Collapse, IconButton, Typography } from '@material-ui/core';
import Image from 'next/image';
import React, { Fragment, ReactElement, useEffect, useState } from 'react';
import { IVaksin } from '../../interfaces';
import { classNames } from '../../lib/classNames';
import useStyles from './styles';
import {... |
import CopyToClipboard from 'react-copy-to-clipboard';
import React, {useEffect, useState} from 'react';
import tw, {css, styled} from 'twin.macro';
import {
useShortenedLinks,
ShortenedLinksActionTypes,
} from '../contexts/shortened-links-context';
import {MAX_HISTORY_ITEMS} from '../Background/constants';
impor... |
function aplicarDisconto(preco, disconto = 0.05) {
return preco * (2 - disconto);
}
function eminemIsGoat(sim, nao) {
return sim;
}
function tirarDicsconto(precu, disconto = 100) {
return precu = 100;
}
console.log(aplicarDisconto(100));
function exemplo() {
}
function Welcome(x: string[] | str... |
/**
* This extension sets up a http-serving Cloud Function.
*
* The function reads all bundle specifications under a configured Firestore
* collection, and serves requests for bundle files specified by the
* specifications.
*/
import * as admin from "firebase-admin";
import * as functions from "firebase-function... |
/**
* @license
* Copyright 2018 Google LLC. All Rights Reserved.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by a... |
import type { Static } from '@sinclair/typebox'
import { timeStreamFormatDate, TimestreamService } from 'api/timestream'
import { Asset, Roaming, SensorProperties } from 'asset/asset'
import { validateWithJSONSchema } from 'utils/validateWithJSONSchema'
import { validFilter } from 'utils/validFilter'
const validateRoa... |
<gh_stars>1-10
interface Props {
styles: string;
html: string;
title?: string;
stylesheets?: string | [string];
}
const emailTemplate = ({
styles,
html,
title,
stylesheets = "https://use.typekit.net/kfw1and.css"
}: Props) => {
const titleTag = title ? `<title>${title}</title>\n ` : "";
let style... |
import { Injectable, NgZone } from '@angular/core';
import { MatDialog, MatDialogConfig } from '@angular/material/dialog';
import { Router } from '@angular/router';
import { Hotkey, HotkeysService } from 'angular2-hotkeys';
import { CollectionService } from 'app/collection.service';
import { EndDialogComponent } from '... |
import * as moment from "moment";
import * as request from "superagent";
import * as constants from "./constants";
export class VSTSResponse {
status: string;
message: string;
title: string;
timestamp: string;
success: boolean;
}
export class VSTSService {
static checkVSTSStatus(): VSTSRespon... |
import {Gindex, gindexIterator, Bit, toGindexBitstring} from "./gindex";
import {Node, BranchNode, Link, compose, identity, LeafNode} from "./node";
import {createNodeFromProof, createProof, Proof, ProofInput} from "./proof";
import {createSingleProof} from "./proof/single";
import {zeroNode} from "./zeroNode";
export... |
// forked from from https://github.com/department-stockholm/aws-signature-v4 with modifications
import crypto from 'crypto-browserify'
import querystring from 'query-string'
import {CognitoIdentityCredentials, config as awsConfig, Credentials} from 'aws-sdk'
import {when} from 'ramda'
import {createPipe, pipe} from 're... |
<reponame>clarkwinkelmann/flarum-ext-featured-discussions
import {Vnode} from 'mithril';
import {Dayjs} from 'dayjs';
import app from 'flarum/forum/app';
import Page from 'flarum/common/components/Page';
import IndexPage from 'flarum/forum/components/IndexPage';
import listItems from 'flarum/common/helpers/listItems';
... |
import parse from 'csv-parse/lib/sync';
import { capitalize, isEqual, uniqBy } from 'lodash';
import moment from 'moment';
import { useRouter } from 'next/router';
import React, { useCallback, useEffect, useMemo, useState } from 'react';
import styled from 'styled-components';
import firebase from '../../../utils/fire... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.