text stringlengths 3 1.05M |
|---|
import stripePackage from "stripe";
import handler from "./libs/handler-lib";
import { calculateCost } from "./libs/billing-lib";
export const main = handler(async (event, context) => {
const { storage, source } = JSON.parse(event.body);
const amount = calculateCost(storage);
const description = "Scratch charge"... |
/* *******************************************************************************************
* *
* Plese read the following tutorial before implementing tasks: *
* https://developer.mozilla.org/en... |
import React from 'react';
function ShowBalance(props) {
return (
<>
{props.showBal ? (
<div
className={props.classWrapper}
style={{ width: '100%', textAlign: 'end' }}
>
{props.label && 'Balance: '}{' '}
{props.balance === 0
? '0.0000'
... |
module.exports =
/******/ (function(modules) { // webpackBootstrap
/******/ // The module cache
/******/ var installedModules = {};
/******/
/******/ // The require function
/******/ function __webpack_require__(moduleId) {
/******/
/******/ // Check if module is in cache
/******/ if(installedModules[moduleId])... |
'''
./common/lib/xmodule/xmodule/modulestore/django.py
'''
from __future__ import absolute_import
from contextlib import contextmanager
class MockCourse(object):
'''
This is a mock of the CourseDescriptor
This usually seems to be a 'xblock.internal.CourseDescriptorWithMixins'
object. Which appears ... |
/**
* Deferred Object
*
* Used for building up a Query
*/
var util = require('util');
var Promise = require('bluebird'),
_ = require('lodash'),
normalize = require('../utils/normalize'),
utils = require('../utils/helpers'),
acyclicTraversal = require('../utils/acyclicTraversal'),
hasOwnProperty... |
"""
Handle FreeBSD port audit files and map the names to OpenEmbedded
"""
class freebsd_info:
"""
Handles an entry like the one below:
vulnerability-test-port>=2000<2010.02.26|http://cvsweb.freebsd.org/ports/security/vulnerability-test-port/|Not vulnerable, just a test port (database: 2010-02-26)
"""
... |
var Readable = require('stream').Readable;
/**
* 创建一个readable流
*/
var rs = new Readable();
rs.push('beep ');
rs.push('boop\n');
/**
* 在上面的代码中rs.push(null)的作用是告诉rs输出数据应该结束了。
* 需要注意的一点是我们在将数据输出到process.stdout之前已经将内容推送进readable流rs中,但是所有的数据依然是可写的。
* 这是因为在你使用.push()将数据推进一个readable流中时,一直要到另一个东西来消耗数据之前,数据都会存在一个缓存中。
*/
r... |
export function appendDebug(
xin,
yin,
JStarArray,
scalProd,
loopoverJvalues,
result,
beforeSymSpe,
) {
if (!result.debug) {
result.debug = {
steps: [],
};
}
const data = {
x: [],
y: [],
s: [],
};
let step = {};
result.debug.steps.push(step);
for (let i = 0; i < x... |
import {config} from "../../config";
export const services = {
uploadService: null,
}
export const MOCK_FILE_ID = "mock-file-id"
export const MOCK_CREATED_PHOTO_ID = "7"
export class MockUploadService {
uploadPhotoFile(file) {
this.lastFileUploaded = file
return {
then: fn => fn(MO... |
ace.define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"], function(require, exports, module) {
"use strict";
var oop = require("../lib/oop");
var TextHighlightRules = require("./text_highlight_rules").TextHighlightRules;
var DocCommentHighlightRule... |
/*!
* ${copyright}
*/
/*global Promise*/
sap.ui.define(['sap/m/InstanceManager', 'sap/f/FlexibleColumnLayout', 'sap/ui/base/Object', 'sap/ui/core/routing/History', "sap/base/Log"],
function(InstanceManager, FlexibleColumnLayout, BaseObject, History, Log) {
"use strict";
/**
* Constructor for a new <code>T... |
/* eslint-env node */
module.exports = {
extends: 'stylelint-config-mirego'
};
|
define({
"commonMedia": {
"mediaSelector": {
"lblSelect1": "Meedia",
"lblSelect2": "Sisu",
"lblMap": "Kaart",
"lblImage": "Pilt",
"lblVideo": "Video",
"lblExternal": "Veebileht",
"lblUpload": "Laadi üles",
"lblLink": "Link",
"disabled": "See funktsionaalsus on... |
/**
* @license Copyright (c) 2003-2022, CKSource - Holding sp. z o.o. All rights reserved.
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
*/
/* globals HTMLTextAreaElement */
/**
* @module utils/dom/getdatafromelement
*/
/**
* Gets data from a given source element.
*
* @pa... |
const Engine = Matter.Engine;
const World = Matter.World;
const Bodies = Matter.Bodies;
const Body = Matter.Body;
let engine;
let world;
var ground;
var top_wall;
var ball;
var btn;
function setup() {
createCanvas(400,400);
engine = Engine.create();
world = engine.world;
groun... |
import unittest
from unittest.mock import patch
import programytest.storage.engines as Engines
from programy.security.linking.accountlinker import BasicAccountLinkerService
from programy.storage.stores.nosql.mongo.config import MongoStorageConfiguration
from programy.storage.stores.nosql.mongo.engine import MongoStorag... |
const vec3 = require('../../../math/vec3')
const measureBoundingBox = require('../poly3/measureBoundingBox')
/**
* Measure the bounding box of the given geometry.
*
* @param {Geom3} geometry - 3D geometry to measure
* @returns {Array[minpoint, maxpoint]}
*/
const measureBounds = (geometry) => {
let minpoint = v... |
# Copyright 2016 The TensorFlow Authors. 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 applica... |
/**
* Copyright 2017 The AMP HTML Authors. 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 require... |
from collections import deque
import random
class EpisodeBuffer(object):
def __init__(self, buffer_size=3000):
self.episode_buffer = deque()
self.shaped_experience_buffer = deque()
self.terminal_reward = None
self.buffer_size = buffer_size
self.count = 0
def reset_episo... |
import getMatchData from '../util/getMatchData'
import matchesStrictComparable from '../util/matchesStrictComparable'
import count from '../count'
import getKey from '../getKey'
import baseGet from './baseGet'
import baseIsMatch from './baseIsMatch'
export default function baseMatches(source) {
const matchData = get... |
#coding: utf-8
from tensorflow.examples.tutorials.mnist import input_data
import scipy.misc
import os
# 读取MNIST数据集。如果不存在会事先下载。
mnist = input_data.read_data_sets("MNIST_data/", one_hot=True)
# 我们把原始图片保存在MNIST_data/raw/文件夹下
# 如果没有这个文件夹会自动创建
save_dir = 'MNIST_data/raw/'
if os.path.exists(save_dir) is False:
os.maked... |
/**
* @license
* Copyright (c) 2015 MediaMath Inc. All rights reserved.
* This code may only be used under the BSD style license found at http://mediamath.github.io/strand/LICENSE.txt
*/
(function(scope) {
scope.Footer = Polymer({
is: 'strand-footer',
properties: {
message: {
type: String,
value: ... |
const fs = require('fs-extra');
const EventValidator = require('../validators/EventValidator');
const EventRepository = require('../repository/EventRepository');
const { ServerError } = require('../errors/ServerError');
module.exports = {
async createEvent(user, parsedEventObject) {
const eventObject = parsedEv... |
ppermutation_masks = [
[
[0x0, 0x0, 0x0],
[0x9999999999999999, 0x2222222222222222, 0x4444444444444444],
[0xA5A5A5A5A5A5A5A5, 0xA0A0A0A0A0A0A0A, 0x5050505050505050],
[0xAA55AA55AA55AA55, 0xAA00AA00AA00AA, 0x5500550055005500],
[0xAAAA5555AAAA5555, 0xAAAA0000AAAA, 0x555500005555... |
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes ... |
var request = require('../support/http')
, app = require('../../examples/mvc');
describe('mvc', function(){
describe('GET /', function(){
it('should redirect to /users', function(done){
request(app)
.get('/')
.end(function(err, res){
res.should.have.status(302);
res.headers.l... |
(function(t,e){"object"===typeof exports&&"object"===typeof module?module.exports=e():"function"===typeof define&&define.amd?define([],e):"object"===typeof exports?exports["commerce-components"]=e():t["commerce-components"]=e()})("undefined"!==typeof self?self:this,(function(){return function(t){var e={};function n(r){... |
import torch
import torchaudio
from librosa.core import load
from librosa.output import write_wav
import numpy as np
from spleeter.estimator import Estimator
es = Estimator(2, './checkpoints/2stems/model')
# load wav audio
wav, sr = torchaudio.load_wav('./audio_example.mp3')
# normalize audio
wav_torch = wav / (wa... |
import { boolean, select } from '@storybook/addon-knobs';
import { DateTime } from 'luxon';
import React, { useState } from 'react';
import {
Box,
Button,
ButtonGroup,
DataGrid,
DatePickerInput,
Dialog,
Heading3,
Heading4,
Icon,
IconMenu,
Label,
Link,
MenuItem,
Popover,
Select,
TextBody,... |
import isArray from "./isArray"
import isObject from "./isObject"
/**
* Create a copy of the given object
*
* @param {Array|Object} value The value to copy
* @returns {Array|Object} The duplicated entry
*/
export default (value) => {
let ret = null;
// Array
if (isArray(value)){
ret = [...value];
}
... |
'use strict';
Object.defineProperty(exports, "__esModule", {
value: true
});
var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("va... |
const http = require('http');
const hostname = '127.0.0.1';
const port = 3000;
const server = http.createServer((req, res) => {
res.statusCode = 200;
res.setHeader('Content-Type', 'text/html');
res.end('Hello World!\n');
... |
import React from 'react'
import { useParams, Link } from 'react-router-dom'
import { postStore } from './store'
import { formatContent } from '../../common/util'
import avatar from '../../images/logo.png'
export default function Post() {
const { id } = useParams()
const item = postStore.items.find(post => post.... |
webpackJsonp([4],{381:function(e,t,n){n(468);var a=n(2)(n(454),n(476),"data-v-04902376",null);e.exports=a.exports},386:function(e,t,n){"use strict";t.a={props:{alignment:String,config:{type:Object,default:function(){return{}}},l10n:{type:Object,default:function(){return{}}},placeholder:{type:String,default:"Pick date"}... |
/* Generated by Opal 0.11.4 */
(function(Opal) {
function $rb_gt(lhs, rhs) {
return (typeof(lhs) === 'number' && typeof(rhs) === 'number') ? lhs > rhs : lhs['$>'](rhs);
}
function $rb_lt(lhs, rhs) {
return (typeof(lhs) === 'number' && typeof(rhs) === 'number') ? lhs < rhs : lhs['$<'](rhs);
}
function ... |
import {disposeVnode} from './dispose';
import {typeNumber, noop} from './utils';
import {Com} from './component';
var _errorVnode = [];
var V_Instance = [];
var errorMsg = '';
var globalError = undefined;
/**
* 捕捉错误的核心代码,错误只会发生在用户事件回调,ref,setState回调,生命周期函数
* @param {*} Instance 需要捕捉的虚拟组件实例
* @param {*} hookname 用... |
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you ... |
const axios = require('axios')
/**
* Receives the page number and returns the formatted url string
*
* @param {string} nrPage
* @returns {string} URL
*/
const getUrl = nrPage => `https://frontend-intern-challenge-api.iurykrieger.vercel.app/products?page=${nrPage}`
/**
* Performs the query to the Api's address... |
# Pyrogram - Telegram MTProto API Client Library for Python
# Copyright (C) 2017-2020 Dan <https://github.com/delivrance>
#
# This file is part of Pyrogram.
#
# Pyrogram is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as published
# by the Free... |
from mock_data.shopify import shopify_api
class Shopify:
def __init__(self):
pass
def get_products(self):
"""Retrieves clean formatted products
:return: formatted products
:rtype: List
"""
formatted_products = []
resp = shopify_api
for product i... |
import React from "react"
import Body from "./body"
import Header from "./header"
import PostSide from "./post-side"
export default function({ post, poster }) {
const user = poster || post.poster
let className = "post"
if (user && user.rank.css_class) {
className += " post-" + user.rank.css_class
}
ret... |
import Vue from 'vue'
import Vuex from 'vuex'
import actions from './actions.js'
import getters from './getters.js'
import mutations from './mutations.js'
Vue.use(Vuex)
const store = new Vuex.Store({
state: {
user: {},
headline: {},
isLoading: false,
moreArticle: true,
load... |
const webpack = require('webpack')
const merge = require('webpack-merge')
const base = require('./webpack.base.config')
const config = require('../config')
const nodeExternals = require('webpack-node-externals')
const VueSSRServerPlugin = require('vue-server-renderer/server-plugin')
module.exports = merge(base, {
ta... |
# -*- coding: utf-8 -*-
import itertools
class Solution:
def isLongPressedName(self, name, typed):
for name_group, typed_group in itertools.zip_longest(
itertools.groupby(name), itertools.groupby(typed)):
if name_group is None or typed_group is None:
return Fal... |
XXXXXXX XXXXXXXBBBBBBB BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBXBBB BBBBBBBBBBB BBBBBBBBBBBBBB BBBBBBBBBBB BB BBBBBBBBBBBBBBBBBB BBBBBBBBBB
XXXXXXXXX XXXXXXXXXBBBBBBBB BBBBBB BB BBBBBBBBBBBBB
BBBBBBB BBBBBBBBBBBBBBBBBBBBBBBBBBBB BBBBBBBBBB
XXXXXXXXXXXBBBBBBBBBBB
XXXXXXXXX
|
import math
import numpy as np
from common.numpy_fast import interp, clip
from common.realtime import sec_since_boot
from selfdrive.modeld.constants import T_IDXS
from selfdrive.controls.lib.radar_helpers import _LEAD_ACCEL_TAU
from selfdrive.controls.lib.lead_mpc_lib import libmpc_py
from selfdrive.controls.lib.drive_... |
const inquirer = require('inquirer');
const fs = require('fs');
const generateMarkdown = require('./utils/generateMarkdown.js');
// TODO: Create an array of questions for user input
const questions = [
{
type: 'input',
name: 'title',
message: 'Project title (required):',
validate: titleInput => {
... |
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([["polyfills"],{
/***/ "./node_modules/zone.js/dist/zone-evergreen.js":
/*!*****************************************************!*\
!*** ./node_modules/zone.js/dist/zone-evergreen.js ***!
\*****************************************************/
/*! no sta... |
exports.run = (bot, msg) => {
msg.channel.send(':watch: | Ping!').then(m => {
m.edit(`:watch: | Pong! \`${m.createdTimestamp - msg.createdTimestamp}ms\``);
});
};
exports.help = {
name: 'ping',
usage: 'ping',
description: 'Pings the bot to check its connection speed.'
};
|
import React from 'react';
import Layout from "../components/layout";
import { Link } from "gatsby";
import { Banner, TextWrapper, GenereicPara, GenericH3, SectionTwo, GenereicParaAbout } from "../styles/IndexStyles";
const about = () => {
return (
<Layout>
<section style={{ position: 'relative' }}... |
"""
Code for `sarif copy` command.
"""
import copy
import datetime
import json
import os
from sarif import loader, sarif_file
from sarif.sarif_file import SarifFileSet
def generate_sarif(
input_files: SarifFileSet,
output: str,
append_timestamp: bool,
sarif_tools_version: str,
cmdline: str,
):
... |
define("ace/mode/doc_comment_highlight_rules",["require","exports","module","ace/lib/oop","ace/mode/text_highlight_rules"],function(e,t,n){"use strict";var r=e("../lib/oop"),i=e("./text_highlight_rules").TextHighlightRules,s=function(){this.$rules={start:[{token:"comment.doc.tag",regex:"@[\\w\\d_]+"},s.getTagRule(),{de... |
import React from 'react';
import { isMediumUsernameValid } from '../utils/validation'
import { icons, skills } from '../constants/skills';
const Markdown = (props) => {
const Title = (props) => {
if (props.prefix && props.title) {
return (
<>
{`<h1 align="ce... |
jQuery(document).ready(function($) {
// var baseDomain = "http://172.19.50.245";
var baseDomain = "http://localhost/temp_page";
$(".itemIcon").click(function(event) {
var $this = $(this);
toogleItem($this);
changeItemText($this);
sendHttpRequestWrapper($this);
});
function toogleItem($bulb_... |
import { Controller } from "./Controller";
export default Controller;
|
export { default } from 'ember-route-helpers/utils/mount-point';
|
import { test, patch, createClass, checkThis, _Array, _Object, isFn, _window, PROTOTYPE, removeIndex } from "./utils";
import { SYMBOL_ITERATOR } from "./Symbol";
test(_window, 'Set', function (Set) {
var set = new Set([-0, +0]);
return isFn(set.forEach) && isFn(set[SYMBOL_ITERATOR]) && set.size === 1 && set.a... |
from unittest import TestCase
from tests import get_data
from pytezos.michelson.converter import build_schema, decode_micheline, encode_micheline, micheline_to_michelson
class StorageTestKT1JW6PwhfaEJu6U3ENsxUeja48AdtqSoekd_alpha(TestCase):
@classmethod
def setUpClass(cls):
cls.maxDiff = None
... |
$(document).ready(function(){
$.ajax({
type: "GET",
headers: {
'Accept': 'application/json',
'Content-Type': 'application/json'
},
dataType: 'json',
url: "api/auth/user",
success: function(response) {
setUser(response);
... |
"use strict";
var _a;
Object.defineProperty(exports, "__esModule", { value: true });
exports.updateSessionFromResponse = exports.applySession = exports.commandSupportsReadConcern = exports.ServerSessionPool = exports.ServerSession = exports.maybeClearPinnedConnection = exports.ClientSession = void 0;
const promise_prov... |
const renderHotelCards = (data) =>
data.map((hotel, index) => (
<Card
key={`${hotel.name}-${index}`}
name={hotel.name}
description={hotel.description}
country={hotel.country}
city={hotel.city}
rooms={hotel.rooms}
image={hotel.photo}
price={hotel.price}
maxPric... |
import fetch from 'node-fetch';
const db = require('../../../../lib/db');
const cors = require('../../../../lib/cors');
const validateUser = require('../../../../lib/validateUser');
export default (req, res) => {
return new Promise(async (resolve) => {
let serieID = req.query.serie;
let poster = r... |
import logging
from typing import Union, Any
from mypy.plugin import Plugin, AnalyzeTypeContext
from mypy.types import TypedDictType
import warnings
# Raise issues here.
ISSUE_URL = "https://github.com/inspera/jsonschema-typed"
class OptionalTypedDictPlugin(Plugin):
OptionalTypedDict = "jsonschema_typed.Option... |
const { Machine, assign } = require(`xstate`)
const createPlan = require(`./create-plan`)
const applyPlan = require(`./apply-plan`)
const validateSteps = require(`./validate-steps`)
const validateRecipe = require(`./validate-recipe`)
const parser = require(`./parser`)
const recipeMachine = Machine(
{
id: `recip... |
#!/usr/bin/env python
# emacs: -*- mode: python; py-indent-offset: 4; indent-tabs-mode: nil -*-
# vi: set ft=python sts=4 ts=4 sw=4 et:
""" A simple contrast for an FMRI HRF model """
import numpy as np
from nipy.algorithms.statistics.api import Formula, make_recarray
from nipy.modalities.fmri import utils, hrf
from ... |
# -*- coding: utf-8 -*-
# Part of Odoo. See LICENSE file for full copyright and licensing details.
from . import repair_cancel
from . import repair_make_invoice
from . import stock_warn_insufficient_qty
|
exports = module.exports = new Command();
exports.Command = Command;
exports.Option = Option;
function Command(){}
function Option(){} |
module.exports = {
networks: {
development: {
host: "127.0.0.1",
port: 8545,
network_id: "*",
gas: 60000000000,
gasPrice: 1
}
}
};
|
var graphhle = (function(){
'use strict';
var diagonal = d3.svg.diagonal();
var form = d3.select('form');
var height = 800;
var width = height;
var dims = {'w': width, 'h': height};
var name = d3.select('[name="name"]');
var val = d3.select('[na... |
(window.webpackJsonp=window.webpackJsonp||[]).push([[5],{425:function(e,t,n){"use strict";n.r(t),n.d(t,"AboutPage",(function(){return x})),n.d(t,"query",(function(){return E}));n(452);var a=n(454),r=n.n(a),o=(n(233),n(162)),i=n.n(o),l=(n(161),n(32)),s=n.n(l),c=(n(234),n(92)),u=n.n(c),f=n(1),d=n.n(f),p=n(163),m=n.n(p),v... |
# pylint: disable=missing-docstring
from datetime import date
from hashlib import sha1
from io import BytesIO
from s3stash.util import make_date_prefix, make_s3_client
def make_key(content):
"""Make an S3 key string.
Format:
YYYY/MM-Month/DD/<sha1 hash of contents>
Example:
2016/09-Sep... |
"""
Show how to use a lasso to select a set of points and get the indices
of the selected points. A callback is used to change the color of the
selected points
This is currently a proof-of-concept implementation (though it is
usable as is). There will be some refinement of the API.
"""
from matplotlib.widgets import... |
/*
* Copyright (c) 2012 Adobe Systems Incorporated. All rights reserved.
*
* 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... |
/*
* This combined file was created by the DataTables downloader builder:
* https://datatables.net/download
*
* To rebuild or modify this file with the latest versions of the included
* software please visit:
* https://datatables.net/download/#bs4-4.0.0/dt-1.10.16/b-1.5.1/b-html5-1.5.1/b-print-1.5.1/sl-1.2.5
... |
/**
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*
* @format
*/
'use strict';
const lazyImports = require('./lazy-imports');
const passthroughSyntaxPlugins = require('../passthrou... |
var sky, skyImg;
var bird, birdAnimation;
function preload() {
skyImg = loadImage("assets/Sky.png");
birdAnimation = loadAnimation("assets/Bird Animation/bird1.png","assets/Bird Animation/bird2.png","assets/Bird Animation/bird3.png","assets/Bird Animation/bird4.png");
}
function setup() {
canva... |
# -*- coding: utf-8 -*-
# Copyright (C) 2001-2020 Mag. Christian Tanzer. All rights reserved
# Glasauergasse 32, A--1130 Wien, Austria. tanzer@swing.co.at
# ****************************************************************************
#
# This module is licensed under the terms of the BSD 3-Clause License
# <http://www.... |
#!/usr/bin/env python
#
# test_multibytecodec_support.py
# Common Unittest Routines for CJK codecs
#
import sys, codecs
import unittest, re
from test import support
from io import BytesIO
class TestBase:
encoding = '' # codec name
codec = None # codec tuple (with 4 elements)
tstring ... |
import dataset from "@/api/dataset";
import analysis from "@/api/analysis";
import {
PATCH_DEPOSITOR_INFO,
SET_ANALYSIS_PLAN,
SET_DATASET_INFO,
SET_DATASET_LIST,
SET_MYDATA_LIST,
SET_PROFILER_MSG,
SET_PROFILER_STATUS
} from './types';
import {
depositorSteps,
STEP_0400_PROFILING_COMP... |
import pygame
import sys
from pygame.locals import *
#initialization and window setup
pygame.init()
DISPLAYSURF = pygame.display.set_mode((290,290),0,32)
pygame.display.set_caption('tic tac toe')
#defining colors for easy use
BLACK = (0,0,0)
WHITE = (255,255,255)
RED = (255,0,0)
GREEN =(0,255,0)
BLUE = (0,0,255)
"""
... |
/*
* Backpack - Skyscanner's Design System
*
* Copyright 2016-2020 Skyscanner Ltd
*
* 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
*
... |
"""
Module for generating Arc Line lists
Should be run where it is located (for now)
"""
import numpy as np
import os, imp, glob, pdb, gzip
import subprocess
from astropy import units as u
from astropy.units.quantity import Quantity
from astropy import constants as const
from astropy.io import fits, ascii
from astro... |
!function(e){const i=e.nl=e.nl||{};i.dictionary=Object.assign(i.dictionary||{},{"%0 of %1":"0% van 1%","Align cell text to the bottom":"","Align cell text to the center":"","Align cell text to the left":"","Align cell text to the middle":"","Align cell text to the right":"","Align cell text to the top":"","Align table ... |
var gulp = require('gulp');
var babel = require('gulp-babel');
var jshint = require('gulp-jshint');
var nodemon = require('gulp-nodemon');
var uglify = require('gulp-uglify');
var util = require('gulp-util');
var mocha = require('gulp-mocha');
var todo = require('gulp-todo');
var webpack = require('webpack-stream');
va... |
const { format } = require("date-fns")
module.exports = (value) => {
const dateObject = new Date(value)
return format(dateObject, "PPP")
}
|
/**
* @author Wil Moore III
* See LICENSE file in root directory for full license.
*/
"use strict"
module.exports = {
meta: {
type: "suggestion",
docs: {
description: "disallow `new` operators with calls to `require`",
category: "Possible Errors",
recommended:... |
// MIT License - Copyright (c) 2011-2018 Felix Gnass [fgnass at gmail dot com]
var __assign = (this && this.__assign) || function () {
__assign = Object.assign || function(t) {
for (var s, i = 1, n = arguments.length; i < n; i++) {
s = arguments[i];
for (var p in s) if (Object.protot... |
import React, { Component } from "react";
import style from "./Account.module.css";
import ProfileBar from "../../../Components/ProfileBar/ProfileBar";
import { Col, Container, Input, Row } from "reactstrap";
import cameraIcon from "../../../Assets/camera.png";
class Account extends Component {
state = {
imageBa... |
# 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 writing, software
# d... |
$(document).ready(function() {
if (!_.includes(App.mode, 'events-index')) {
return;
}
new App.Common.EventsTable($('.events-table')).render();
});
|
import React from 'react';
import PropTypes from 'prop-types';
import {
Animated,
Easing
} from 'react-native';
import CircularProgress from './CircularProgress';
const AnimatedProgress = Animated.createAnimatedComponent(CircularProgress);
export default class AnimatedCircularProgress extends React.PureComponent {... |
module.exports = {
details: require('./details'),
categories: require('./categories'),
list: require('./list')
};
|
const TandingService = use('App/Services/TandingService')
const SeniService = use('App/Services/SeniService')
const _ = require('underscore');
const s = require('underscore.string');
const Server = use('Server')
const io = use('socket.io')(Server.getInstance())
const tandingService = new TandingService()
const seniServ... |
var express = require('express')
var url = require('url')
var bodyParser = require('body-parser')
var randomstring = require('randomstring')
var cons = require('consolidate')
var nosql = require('nosql').load('database.nosql')
var querystring = require('querystring')
var qs = require('qs')
var __ = require('underscore'... |
from editor.attributes.player.player_attribute import (
PlayerAttribute,
PlayerAttributeTypes,
)
class PlayerAttributeMiddleShooting(PlayerAttribute):
@classmethod
def att_class_name(cls):
return "Middle Shooting"
@classmethod
def att_class_type(cls):
return PlayerAttributeTyp... |
import React, { useState } from "react";
import { Switch, Route } from "react-router-dom";
import {
AuthRoute,
// ProtectedRoute
} from "../util/route_util";
import HomePage from "./homepage/homepage";
import LoginFormContainer from "./session/login_form_container";
import RegisterFormContainer from "./session/regi... |
/**
* Import blocks as components.
*/
import "./wpt-block-1";
import "./wpt-block-2";
import "./wpt-block-3";
import "./wpt-media-block"; |
(window.webpackJsonp=window.webpackJsonp||[]).push([[47],{255:function(t,s,a){"use strict";a.r(s);var n=a(0),r=Object(n.a)({},(function(){var t=this,s=t.$createElement,a=t._self._c||s;return a("ContentSlotsDistributor",{attrs:{"slot-key":t.$parent.slotKey}},[a("h2",{attrs:{id:"html"}},[a("a",{staticClass:"header-anchor... |