text stringlengths 8.5k 48.7k |
|---|
import React, { Component } from "react";
import Button from "@material-ui/core/Button";
import "./InteractApp.css";
const ANSWER_ACTION = "answerAction";
const ANSWER_PARSING = "answerParsing";
const ANSWER_VISION = "answerVision";
const PLEASE_RESUME = " You can type a new command now.";
class InteractApp extends C... |
/*
Copyright (c) 2011-2013, EMC Corporation
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 notice, this list of conditions and the ... |
import { FrontPanel } from "./front-panel"
const CANVAS_WIDTH = 1598;
const CANVAS_HEIGHT = 530;
const CELL_RADIUS = 12;
const CONNECTORS = [
{idx: 0, col: 0, row: 0, x: 1215, y: 81, name: "OSC1", input: true},
{idx: 1, col: 0, row: 1, x: 1215, y: 131, name: "SHAPE1", input: true},
{idx: 2, col: 0, row: 2, x: 12... |
var sys = require('sys'),
GitObject = require('./git_object').GitObject,
fs = require('fs'),
LooseStorage = require('./loose_storage').LooseStorage,
PackStorage = require('./pack_storage').PackStorage,
BinaryParser = require('./binary_parser').BinaryParser;
Repository = exports.Repository = function(git_dire... |
/**
* Copyright 2014 Flipkart Internet Pvt. 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
*
* Unless required by applicable law ... |
"use strict";
/*
* Various utilities to assist in statblock parse/conversion. Formatted as a Node module, to allow external use.
*
* In all cases, the first argument, `m`, is a monster statblock.
* Additionally, `cbMan` is a callback which should accept up to two arguments representing part of the statblock which
... |
/**
* 验证输入框
* @param inputId
*/
function validateInput(inputId){
if($.trim($('#'+inputId).val()) == ''){
$('#'+inputId).closest(".form-group").removeClass("has-success").addClass("has-error");
$('#'+inputId).closest(".form-group").children("div").children("span").remove();
var message = $('#'+inputId).at... |
"use strict";
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
return new (P || (P = Promise))(function (resolve, reject) {
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
function rejected(value) { try { step(gene... |
'use strict';
Object.defineProperty(exports, '__esModule', { value: true });
var N = require('nial');
var tf = require('@tensorflow/tfjs-node');
class Normalizer {
constructor(nbInputs) {
this.n = N.zeros(nbInputs);
this.mean = N.zeros(nbInputs);
this.meanDiff = N.zeros(nbInputs);
this.va... |
/*!
=========================================================
* Material Dashboard - v2.1.1
=========================================================
* Product Page: https://www.creative-tim.com/product/material-dashboard
* Copyright 2018 Creative Tim (http://www.creative-tim.com)
* Designed by www.invisionapp... |
var dhive = require("@hiveio/dhive");
var axios = require('axios');
var hivejs = require('@hiveio/hive-js');
var hiveState = require('./processor');
var steemTransact = require('steem-transact');
var fs = require('fs');
const cors = require('cors');
const express = require('express')
const ENV = process.env;
const maxE... |
// REKAPI-GLOBALS
// These are global in development, but get wrapped in a closure at build-time.
// A hack for UglifyJS defines. Gets removes in the build process.
if (typeof REKAPI_DEBUG === 'undefined') {
REKAPI_DEBUG = true;
}
var rekapiModules = [];
/*!
* Fire an event bound to a Rekapi.
* @param {Rekapi} ... |
const PHP = {
stdClass: function() {},
stringify(val) {
const hash = new Map([
[Infinity, "d:INF;"],
[-Infinity, "d:-INF;"],
[NaN, "d:NAN;"],
[null, "N;"],
[undefined, "N;"]
]);
const utf8length = str => str ? encodeUR... |
winWid = 0;
// js for "Safari Apple browser"
function scaleFixHuck(){
var viewportmeta = document.querySelector && document.querySelector('meta[name="viewport"]'),
ua = navigator.userAgent,
gestureStart = function () {
viewportmeta.content = "width=device-width, minimum-scale=0.25, maximum-scale=1.6";
},
scaleF... |
import * as os from 'os';
import * as std from 'std';
import * as path from 'path';
import inspect from 'inspect';
import { Predicate } from 'predicate';
import { Location, Lexer, Token } from 'lexer';
import Console from '../lib/console.js';
import JSLexer from '../lib/jslexer.js';
import CLexer from '../lib/clexer.js... |
import { Picker } from './_utils';
export default function OrganizationNoun () {
return Picker(oNouns);
}
var oNouns = [
'Ability',
'Abroad',
'Abuse',
'Access',
'Accident',
'Account',
'Act',
'Action',
'Active',
'Activity',
'Actor',
'Ad',
'Addition',
'Address',
'Adult',
'Advance',
'... |
"use strict";
import { encode, decode } from "@msgpack/msgpack";
import Peer from 'peerjs';
import createAudioMeter from './lib/volume-meter.js';
import { Clamp } from "./utils.js"
import { NO_HEAR_DISTANCE, FULL_HEAR_DISTANCE, PAN_DISTANCE_START, PAN_ROLLOF, MAX_PAN } from "./constants.js"
var getUserMedia_ = (naviga... |
"use strict";
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
return new (P || (P = Promise))(function (resolve, reject) {
function fulfilled(value) { t... |
'use strict';
Object.defineProperty(exports, '__esModule', { value: true });
require('./slicedToArray-0711941d.js');
require('./unsupportedIterableToArray-68db1d3b.js');
require('react');
require('./_commonjsHelpers-72d386ba.js');
require('./index-b0606964.js');
require('./defineProperty-0921a47c.js');
require('./toC... |
'use strict';
/* ------------------------------------------------------------------------------------------------
CHALLENGE 1 - Review
First, write a function called mapCurrentEvents that maps over the current events object, runs it through a constructor function and returns the resulting array.
The constructor func... |
"use strict";
const path = require("path"),
{STATUS_CODES} = require("http"),
{URL} = require("url"),
retsu = require("retsu"),
keysort = require("keysort"),
redis = require("redis"),
session = require("express-session"),
cookie = require("cookie-parser"),
lusca = require("lusca"),
uuid = require("tiny-uuid4"... |
var CHORDCHARS = "CDEFGAH";
var MODIFIERCHARS = "sm37#2";
function initChordLengthStyles() {
var x = '';
for (var i =1; i<33; i++ ) {
x+= "#jampal .part_chords .chbox.len"+i+" { width: "+(i*7)+"vw; }\n";
x+= "#jampal.small1 .part_chords .chbox.len"+i+" { width: "+(i*6)+"vw; }\n";
x+= "#... |
var express = require('express')
var router = express.Router()
const { performance } = require('perf_hooks')
const _ = require('lodash')
const path = require('path')
const Diff = require('../../utils/diff')
const DateTime = require('../../utils/luxon')
const Crypt = require('../../utils/crypt')
const {Interval, Dura... |
import * as THREE from "three"
const multiuseSpherical = new THREE.Spherical()
const multiuseVector3 = new THREE.Vector3()
export default function createPlanet (scene) {
// Lights
const directionalLight = new THREE.DirectionalLight(0xffffff, 0.75)
directionalLight.position.set(100, 100, 150)
scene.add(directi... |
import React, { useState, useEffect } from "react";
import Link from "next/link";
import Head from 'next/head'
import IndexNavbar from "components/Navbars/IndexNavbar.js";
import Footer from "components/Footers/Footer.js";
import { makeStyles } from '@material-ui/core/styles';
import Button from '@material-ui/core/But... |
/// <reference path="./winrtrefs.d.ts"/>
/// <reference path="../built/pxtlib.d.ts"/>
var pxt;
(function (pxt) {
var winrt;
(function (winrt) {
function driveDeployCoreAsync(res) {
var drives = pxt.appTarget.compile.deployDrives;
pxt.Util.assert(!!drives);
pxt.debug("... |
// On page load, clear some structures, grab nav data,
// and then get and display current matches.
$(function() {
$.when(
getNav()
).then(getAndDisplayCurrentMatches);
});
function getParameterByName(nameTok) {
var nameTokArray = nameTok + "[]";
var query = window.loc... |
var EXPORTED_SYMBOLS = [
"Application",
"prefService",
"promptService",
"windowMediator",
"windowWatcher",
"setBrowserWindow",
"setBrowserIconOn",
"setBrowserIconOff",
"warning",
"escapeRobot",
"escapeSpace",
"getNodeValue",
"getTextFragments",
"getElementText",
"getTextBasedXPath",
"getClassBasedXPath",
"getNearTextEl... |
const { remote, ipcRenderer } = require('electron');
const fs = require('fs');
const path = require('path');
const SignaturePad = require('signature_pad');
const nodemailer = require("nodemailer");
const { exec } = require("child_process");
const { PDFDocument, rgb } = require('pdf-lib');
const app = remote.ap... |
define("sap_viz_ext_powerflowmaps-src/js/render", [], function() {
/*
* This function is a drawing function; you should put all your drawing logic in it.
* it's called in moduleFunc.prototype.render
* @param {Object} data - proceessed dataset, check dataMapping.js
* @param {Object} container - the target d3.se... |
var chartsById = {};
chartsById[graphExporter.xicChartId] = null;
chartsById[graphExporter.massPeakChartId] = null;
var imageFormats = graphExporter.supportedImageFormatIds;
var dataFormats = graphExporter.supportedDataFormatIds;
var auxPointFlag = 'aux_data';
var graphTitleKey = 'title';
var scanStartKey = 'scan_sta... |
var React = require('react');
var Router = require('react-router');
var browserHistory = Router.browserHistory;
var SingleSelectDropdown = require('../singleSelectDropdown.js');
var DatePicker = require('react-bootstrap-datetimepicker');
var Select = require('react-select');
var Moment = require('moment')
var commonUt... |
if (!Array.prototype.push) {
Array.prototype.push = function() {
var startLength = this.length;
for (var j = 0; j < arguments.length; j++) {
this[startLength + j] = arguments[j]
}
return this.length
}
};
function G() {
var elements = new Array();
for (var i =... |
function table() {
}
table.prototype.onjquery = function() {
table.selectTable('object-table','selected-table');
//para hacer focus a cualquier modal dentro de table
};
table.prototype.selectTable = function(objectClass,selectClass) {
$('.'+objectClass).click(function() {
//clear service menu
$('.se... |
'use strict';
Object.defineProperty(exports, '__esModule', { value: true });
function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; }
var React = require('react');
var React__default = _interopDefault(React);
/*! *********************************************... |
/* eslint-disable no-param-reassign, no-unused-vars */
const munkres = require('munkres-js');
// ////////////////////////////////////////
// Sketchy.js
// ////////////////////////////////////////
//
// JavaScript Shape Matching Works best with Raphael SketchPad Development
// started March 2013
//
// Imm... |
// 全站打包上传 npm,sw 并发请求 cdn
const prefix = 'volantis-community';
const cacheSuffixVersion = '00000003-::cacheSuffixVersion::';
const CACHE_NAME = prefix + '-v' + cacheSuffixVersion;
const PreCachlist = [
"/css/style.css",
"/js/app.js",
"/js/search/hexo.js",
];
let NPMMirror = true;
const NPMPackage = "@mhg/volantis... |
/*
* Lightweight RTE - jQuery Plugin, v1.2
* Basic Toolbars
* Copyright (c) 2009 <NAME> - http://www.gayvoronsky.com
*/
var rte_tag = '-rte-tmp-tag-';
var rte_toolbar = {
disable : {ignore: true},
s1 : {separator: true},
bold : {command: 'bold', tags:['b', 'strong']},
italic : {command: 'italic... |
var state = require('./state.js')
var type_id = 0
var alphabet = "abcdefghijklmnopqrstuvwxyz"
function alphanum (n) {
var a = alphabet[n%26]
if (n >= 26) {
a = alphanum(Math.floor(n/26)-1) + a
}
return a
}
function alphaslice (n) {
var arr = []
for (var i = 0; i < n; i++) {
arr.push(alphanum(i)... |
/// (name)
function js_check(name) {
return window[name] ? 1 : 0;
}
/// js_call(...args):
function js_call(name) {
var f = window[name];
if (f) {
return f.apply(this, Array.prototype.slice.call(arguments, 1));
} else return undefined;
}
///
function js_get(name) {
return window[name];
}
///
function js_set(name,... |
var Cal = function(divId) {
//Store div id
this.divId = divId;
// Days of week, starting on Sunday
this.DaysOfWeek = [
'Sun',
'Mon',
'Tue',
'Wed',
'Thu',
'Fri',
'Sat'
];
// Months, stating on January
this.Months = ['January', 'Februar... |
// We have pixi.js's to colour our screen and Phaser to challenge the player!
/* global Phaser */
// The Boss, or GameMaster
/* global gm */
// our game variables that is used with phaser.
var game;
var bg;
var map;
var ui
var tileset;
var layer;
// player information and status
var player;
var facing = 'left';
var ... |
"use strict";
/**
* MODULE:
* Helper methods to retrieve and process an ESO report
* into a stats JSON file.
*
*
* WARNINGS:
* - This module is tightly coupled with the needs
* of SJIF&R, such as the stats computed from
* the raw data.
* - this is tightly coupled to the report columns requiring
* ... |
import React, {Component, PureComponent} from 'react';
import {connect} from 'dva';
import router from 'umi/router';
import {formatMessage, FormattedMessage} from 'umi-plugin-react/locale';
import T from './../../utils/T';
import styles from './MetadataManageConfig.less';
import {
Row,
Col,
Card,
... |
import * as React from "react";
import { hashHistory } from "react-router";
import * as PIXI from "pixi.js";
import PIXI_SOUND from "pixi-sound";
window.PIXI = PIXI;
require("pixi-layers");
import { gsap } from "gsap";
import { PixiPlugin } from "gsap/PixiPlugin";
import {
getSize,
logo,
startTextStyle,
labelSt... |
import _ from 'lodash';
import config from '../config';
import constants from '../constants';
import TrailblazerHTTPStorageAdapter from '../adapter/trailblazer_http_storage_adapter';
import camelize from 'camelize';
import NodeH... |
/*jshint esversion: 6 */
/* globals document */
/* globals window */
import React from 'react';
import PropTypes from 'prop-types';
import ReactDOM from 'react-dom';
import {Glyphicon} from 'react-bootstrap';
var _ = require('underscore');
import SingleMapActions from './single-map-actions';
import CanvasActions from ... |
const DEFAULT_CONFIG = {
// the category, name, key, url, search path and color for your commands
// if none of the specified keys are matched, the '*' key is used
commands: [
[null, 'Google', '*', 'https://encrypted.google.com', '/search?q={}', '#111'],
['Work', 'Analytics', 'a', 'https://anal... |
import { GlCanvas } from './gl-canvas.js';
import {
get_default_config_from_url,
Streamer
} from './streamer.js';
import shader from './shader.js';
import {
supported_video_configs,
max_video_config,
} from './resolution.js';
const go_live_el = document.getElementById('go-live');
go_live_el.disabled = ... |
const EventEmitter = require("events");
const agora = require("./agora_node_ext");
require("./webgl-utils")
require("./AgoraRender")
class AgoraRtcEngine extends EventEmitter {
constructor() {
super();
this.rtcengine = new agora.NodeRtcEngine();
this.initEventHandler();
this.streams... |
/**
* The main plotty module.
* @module plotty
* @name plotty
* @author: <NAME>
* @web-worker port: MaxPower aka <NAME>
*/
/**
* @constant
*/
import { colorscales } from './colorscales';
import { parse as parseArithmetics } from './arithmetics-parser';
function hasOwnProperty(obj, prop) {
return Object.prot... |
import React from 'react';
import PropTypes from 'prop-types';
import moment from 'moment';
import classnames from 'classnames';
import { polyfill } from 'react-lifecycles-compat';
import KeyCode from 'rc-util/lib/KeyCode';
import CalendarPart from './range-calendar/CalendarPart';
import TodayButton from './calendar/To... |
/**
* @module og/ellipsoid/Ellipsoid
*/
"use strict";
import * as math from "../math.js";
import { Vec3 } from "../math/Vec3.js";
import { LonLat } from "../LonLat.js";
import { EPSILON10 } from "../math.js";
/**
* Class represents a plant ellipsoid.
* @class
* @param {number} equatorialSize - Equatorial ellips... |
'use strict';
const cloneDeep = require('lodash/cloneDeep');
const keyBy = require('lodash/keyBy');
const camelCase = require('lodash/camelCase');
const moment = require('moment');
const DynamoDbSearchQueue = require('@cumulus/aws-client/DynamoDbSearchQueue');
const { buildS3Uri, getJsonS3Object } = require('@cumulus/... |
/**
* Copyright 2018 <NAME> (<EMAIL>)
*
* 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 agre... |
/*******************************************************************************
* Copyright (c) 2020 Mastercard
*
* 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.ap... |
// ID des voitures affichées
var displayedID = {}
// véhicules disponibles
var cars = {
"<NAME>": {
"Thrust": {prix: 130000,selectedColor: 21, hasAnimatedImg: false, hashcode: 0x01},
"Hakuchou": {prix: 160000,selectedColor: 21, hasAnimatedImg: false, hashcode:... |
/** @jsx React.DOM */
var ReactCSSTransitionGroup = React.addons.CSSTransitionGroup;
// React Components
var Button = React.createClass({
render: function(){
return (
<div className="button"
onClick={this.props.onClick}>
{this.props.children}
</div>
);
}});
var AreaSelectBu... |
function yst_clean(str) {
if (str == '' || str == undefined)
return '';
try {
str = jQuery('<div/>').html(str).text();
str = str.replace(/<\/?[^>]+>/gi, '');
str = str.replace(/\[(.+?)\](.+?\[\/\\1\])?/g, '');
} catch (e) {
}
return str;
}
function ptest( str, p ) {
str = yst_clean( str );
str = str.t... |
import React from "react";
import ReactDOM from "react-dom";
import ReactInterval from 'react-interval';
import objectPath from "object-path";
import $ from "jquery";
import CopyToClipboard from 'react-copy-to-clipboard';
import { connect } from "react-redux";
import { Link } from "react-router";
import { push } from... |
var canvas = document.getElementById('canvas'),
canvasHeight = canvas.height,
canvasWidth = canvas.width,
ctx = canvas.getContext('2d'),
mapOriginX = canvasWidth/2;
mapOriginY = canvasHeight/2 + 100;
segment = 16,
keys = ['',''],
rotateOffset = 0,
deadlineOffset = -135,
ground = ... |
const redisType = require("ioredis");
const scripto = require('redis-scripto');
const path = require('path');
const pgp = require('pg-promise')();
const inventory_key = "Inventory";
const default_schema = "public";
pgp.pg.types.setTypeParser(20, BigInt); // This is for serialization bug of BigInts as strings.
const I... |
import PropTypes from 'prop-types';
import React, { Component } from 'react';
import Immutable from 'immutable';
import { filterElementTypes, actionButtonElementTypes, actionButtonClickFunctionality } from './types';
import { Link } from 'react-router-dom';
import Dropdown from '../Input/Dropdown';
import Input from '... |
const jsonfile = require('jsonfile')
const electron = require('electron');
const path = require('path');
const locale = require('./locale')
const utils = require('./utils')
const moment = require('moment')
const { remote } = require('electron')
const { Menu, MenuItem } = remote
const Store = require('electron-store')
c... |
'use strict';
const { Adapter, Device, Property, Event, Database } = require('gateway-addon');
const manifest = require('./manifest.json');
const dgram = require('dgram');
const fetch = require('node-fetch');
const { URLSearchParams } = require('url');
const WebEventEndpoint = require('./events');
const DINGZ_DISCOVE... |
// -*- Mode: js; indent-tabs-mode: nil; c-basic-offset: 4; tab-width: 4 -*-
//
// Copyright (C) 2014-2015 <NAME> <<EMAIL>>
//
// This program is free software; you can redistribute it and/or
// modify it under the terms of the GNU General Public License
// as published by the Free Software Foundation; either version 2... |
"use strict";
var strict_mode = true;
function testRun(id, path, description, codeString, result, error) {
if (result!=="pass") {
throw new Error("Test '" + path + "'failed: " + error);
}
}
function testFinished() {
//no-op
}
function compareArray(aExpected, aActual) {
if (aActual.length != aExpected.... |
var today = new Date();
var ac_dd = today.getDate();
var ac_mm = today.getMonth() + 1;
var yyyy = today.getFullYear();
if (ac_dd < 10) {
dd = '0' + ac_dd;
}
else{
dd = ac_dd;
}
if (ac_mm < 10) {
mm = '0' + ac_mm;
}
else{
mm = ac_mm;
}
today = yyyy + '-' + mm + '-' + dd;
! function (s) {
"use stric... |
'use strict';
exports.__esModule = true;
var _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
var _react = requi... |
const jsname = '葱花视频'
const $ = Env(jsname)
const logs = $.getdata('logbutton'); //0为关闭日志,1为开启,默认为0
const notifyInterval = $.getdata('tzbutton'); //0为关闭通知,1为所有通知,默认为0
now = new Date(new Date().getTime() + new Date().getTimezoneOffset()*60*1000 + 8*60*60*1000);
let task = '';
let tz = '';
let uid = $.getdata('uid')
let... |
/* Generate the concentration plot using d3 library. */
function draw_concentration_plot(svg_id, times, concentrations, cumulative_doses, exposed_presence_intervals) {
console.log(cumulative_doses)
var time_format = d3.timeFormat('%H:%M');
var data_for_graphs = {
'concentrations': [],
'cu... |
const {React, ReactDOM} = window;
'use strict';
class InventoryContainer extends React.Component {
constructor(props) {
super(props);
//Set default inventory state
this.state = { open: false, playerInvSize: 0, playerinv: [], otherInvSize: 0, otherinv: [] };
//Bind events
this.receiveNuiMessa... |
(function () {
search = window.location.search.substr(1)
urlObj=JSON.parse('{"' + decodeURI(search).replace(/"/g, '\\"').replace(/&/g, '","').replace(/=/g,'":"') + '"}')
//var timer = 500000;
//var count = 1;
var peerStats;
var counterIncrement = 0;
var counterIncrement1 = 0;
var counterIncrement2 = 0;
va... |
function codeToLoad () {
// My server IP
var ws = new WebSocket ("wss://tgrcode.com:9002");
var userChannelId;
var userChannelName;
// For testing
window.YOUTUBE_FEED_LOADED = true;
start ();
function polymerClone (element) {
var newElement = element.cloneNode(true);
// Copying polymer elements is diffic... |
// ##############################################################
// ###### Global letiables ######
// ##############################################################
// ----- Buttons -----//
const submitDevicesButton = document.querySelector('#submitDevices');
const submitAttributesButt... |
'use strict';
const vscode = require('vscode'); // eslint-disable-line
const path = require('path');
const cp = require('child_process');
const MAGIK_KEYWORDS = [
'self',
'return',
'unset',
'if',
'then',
'else',
'elif',
'endif',
'true',
'false',
'maybe',
'is',
'isnt',
'not',
'and',
'an... |
const {
LogisticRegressionNLU
} = require('node-nlp');
async function train() {
const classifier = new LogisticRegressionNLU({
language: 'es'
});
classifier.add('Estoy cansado', 'fatiga');
classifier.add('Estoy cansadisimo', 'fatiga');
classifier.add('Estoy cansada', 'fatiga');
cl... |
var filterStrength = 20;
var frameTime = 0, lastLoop = new Date, thisLoop;
function Client(serverAdr, idRoom) {
this.tick_counter = 0;
this.inactive_interval = 0;
this.balls = {};
this.my_balls = [];
this.myPoints = [];
this.score = 0;
this.totalScore = 0;
this... |
import * as utils from '../src/utils.js';
import { config } from '../src/config.js';
import { registerBidder } from '../src/adapters/bidderFactory.js';
import { BANNER, NATIVE } from '../src/mediaTypes.js';
const VERSION = '0.1.0';
const GVLID = 842;
const NET_REVENUE = true;
const UNDEFINED = undefined;
const DEFAULT_... |
/*
Author: <NAME>
This script is injected into Try-Its when the "Start" button in the Auto CCM menu is pressed. It initiates the automatic formatting process.
*/
// user defined blocklist/allowlist
var blockList = window.blocklist;
var allowList = window.allowlist;
var blockListStr = "";
if (blockList != null && block... |
"use strict";
var verbs = {
move: { past: "moved" },
attack: { past: "attacked" },
destroy: { past: "destroyed" },
garrison: { past: "garrisoned" },
win: { past: "won" }
}
function* iterate_board(player) {
const bound = opts.board_size;
if (player != 1) {
for (let x = bound; x >= -bound; x--) {
let y0 = -... |
import React, { PureComponent } from 'react';
import moment from 'moment';
import { connect } from 'dva';
import isEqual from 'lodash/isEqual';
import {
notification,
Form,
Input,
DatePicker,
Select,
Button,
Card,
InputNumber,
Checkbox,
Radio,
Icon,
Upload,
Spin,
Tooltip,
Modal,
Row,
... |
/**
* TODO: docstrings
* TODO: miniquery for content_script.js
*
* TODO: add advanced option to customize storage folder
*/
/**
* Get a the HTML string listing all the <option>tag</option> of all known tags,
* setting the <option>'s "selected" attribute according to the paper's own tags
* @param {object} paper... |
/*
* Copyright (c) 2016 <NAME> (https://github.com/Viglino),
* released under the MIT license (French BSD license)
*/
/*eslint no-useless-escape: "off" */
/*eslint no-constant-condition: ["error", { "checkLoops": false }]*/
import './md.css'
/** Simple markdown to html convertor
* @param {String} md the markdown ... |
/**
*
* @authors 张明臣 (<EMAIL>)
* @date 2014-11-19 17:39:26
* @version 1.0
*/
if(top.location.href != window.location.href){
top.location.href = window.location.href
}
var app = {};
(function () {
app = {
client: {
ios:'http://www.365rili.com/temp/tj.html?url=https://itunes.apple.com/us/app/pu-tao/id11160... |
/* eslint babel/semi: "error" */
import util from 'util';
import Redis from 'ioredis';
import {
cloneDeep,
compact,
flatten,
intersection,
isArray,
isFunction,
isPlainObject,
keyBy,
last,
map,
noop,
uniqBy,
} from 'lodash';
import IoServer from 'socket.io';
import redis_adapter from 'socket.io-... |
import * as React from 'react';
import memoizeOne from 'memoize-one';
import {List as ImmutableList} from 'immutable';
import {Subcontainerize, COLOR_FOR_READ_OPS, singularOrPluralRus} from './util';
import {Chapter2_HashTableFunctions} from './chapter2_hash_table_functions';
import {joinBreakpoints, BreakpointFunctio... |
function uriPolicy(value, effects, ltype, hints) {
if (value && "specialurl" === value.toString()) {
return value;
}
return 'u:' + value.toString();
}
function nmTokenPolicy(nmTokens) {
if ("specialtoken" === nmTokens) {
return nmTokens;
}
if (/[^a-z\t\n\r ]/i.test(nmTokens)) {
return null;
}... |
var count = 30;
var level = 1;
var pause = 0;
var pauseDetectEdge = 1;
var colorchange = 1;
view.zoom = 1;
var huestart = 20;
var huerange = 80;
var dtc =1;
var delay = 0;
var smokenumb = 40;
var numberOfPointCircles = 30;
// Create a symbol, which we will use to place instances of later:
var background = new Path.Rec... |
/* Escher main JS code */
var provider = new firebase.auth.GoogleAuthProvider();
var db = firebase.firestore();
// Show/hide appropriate section of UI based on login state.
firebase.auth().onAuthStateChanged(firebaseUser => {
if (firebaseUser) {
showLoggedInUI();
} else {
showLoggedOutUI();
}
});
// Im... |
'use strict';
/**
@import AmazonLogic.jsil
@import EncryptionHeaderLogic.gil
@import ListLogic.gil
@import Utf8Logic.gil
*/
/*************************
*************************
******* *******
******* needs *******
******* *******
*************************
******************... |
'use strict';
//global vars
var button = document.getElementById('submit');
var form = document.getElementById('form');
var radio = document.getElementsByClassName('color');
var sigil_array = [];
var sigil_space = document.getElementById('generator');
var ctx = sigil_space.getContext('2d');
var user_string;
//helpe... |
var $2wEZH$reactariautils = require("@react-aria/utils");
var $2wEZH$react = require("react");
var $2wEZH$reactariainteractions = require("@react-aria/interactions");
var $2wEZH$reactariatextfield = require("@react-aria/textfield");
var $2wEZH$reactariai18n = require("@react-aria/i18n");
var $2wEZH$reactariaspinbutton ... |
/* jshint -W097 */// jshint strict:false
/*jslint node: true */
'use strict';
const request = require('request');
const utils = require('@iobroker/adapter-core');
const adapter = new utils.Adapter('roadtraffic');
const objs = require('./lib/objs.js');
const schedule = require('node-schedule');
const FORBIDDEN_CHARS = ... |
// ==UserScript==
// @name TornCAT Faction Player Filters
// @namespace torncat
// @version 1.2.3
// @description This script adds player filters on various pages (see matches below).
// @author Wingmanjd[2127679]
// @match https://www.torn.com/factions.php*
// @match https://www.to... |
// this file is a modified version of https://github.com/thatisuday/ng-image-gallery/blob/master/src/js/directive.js
import angular from 'angular';
import ngAnimate from 'angular-animate';
import '../../style/fims/_imageGallery.scss';
// Key codes
const keys = {
enter: 13,
esc: 27,
left: 37,
right: 39,
};
con... |
var socketIO = require('socket.io'),
uuid = require('node-uuid'),
crypto = require('crypto'),
janusSrc = require('./janus'),
wowzaSrc = require('./wowza'),
exports = module.exports = {};
W3CWebSocket = require('websocket').w3cwebsocket;
exports.ListenSocket = function (server, config) {
var opt... |
/**
* global.js
* @name 后台系统全局js
* @author <NAME>
* @since 2018/2
* @version 2.0
*/
// const ajaxSetup = require('./Common/AjaxSetup');
var RPA = RPA || {};
RPA.prototype = {
init: function (obj) {
//event bind
this.bind.call(this);
},
config: {
modal: '#modal-lg',
ca... |
var vxl = {};
function vxlCameraState(camera){
if (!(camera instanceof vxlCamera)) {
alert('vxlCameraState needs a vxlCamera as argument');
return null;
}
this.c = camera;
this.position = new vxlVector(0,0,1);
this.focalPoint = new vxlVector(0,0,0);
this.viewUp = new vxlVector(0,1,0)... |
/*
Scripts to create interactive buttons in SVG using ECMA script
Copyright (C) <2006> <<NAME>>
Version 1.1.3, 2006-10-30
<EMAIL>
http://www.carto.net/
http://www.carto.net/neumann/
Credits:
* <NAME> and <NAME> for fixing an error with vertical positioning of the button texts
* <NAME> for suggesting a bugfix where ty... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.