text stringlengths 8.5k 48.7k |
|---|
// D3
import { ribbon as d3Ribbon } from 'd3-chord';
import { drag as d3Drag } from 'd3-drag';
import { easeLinear as d3EaseLinear } from 'd3-ease';
import {
event as d3Event,
mouse as d3Mouse,
select as d3Select,
selectAll as d3SelectAll
} from 'd3-selection';
// Lodash
import find from 'lodash/find';
// Un... |
"use strict";
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 ("value" in descriptor) descriptor.writable = true; Object.defineProp... |
//Library
// TODO: font handler, reset, save profiles
let keysPressed = [];
let mouseIsPressed = false;
var xscroll = 0;
var yscroll = 0;
var tileSize;
var programStart = new Date();
function keyPressed(){}
function mousedown(){}
function OnKeyDown(event){
if(!keysPressed.includes(event.key)){
keysPressed.push... |
"use strict";
var __extends = (this && this.__extends) || (function () {
var extendStatics = function (d, b) {
extendStatics = Object.setPrototypeOf ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
function (d, b) { for (var p in b) if (b.hasOwnPrope... |
'use strict';
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
// patch node-lightify to get & set the mac-value as hex string
Buffer.prototype.writeDoubleLE = function (val /*, pos*/) {
return this.write(val.toLowerCase(), 0, 8, 'hex');
};
... |
////
//// gulpfile.js for AmiGO.
////
//// Comprehensive for more flexible programmatic replacement for
//// Makefile (which depended to much on weird hard-coded chains of
//// ENV vars).
////
//// Usage: npm install && node ./node_modules/.bin/gulp doc|build|test|watch|clean
////
var us = require('underscore');
var f... |
class PValue {
constructor(_key, _default) {
this.key = _key
this.default = _default
}
get pValue() {
return BStorage.get(this.key)
}
set pValue(value) {
return BStorage.set(this.key, value)
}
get input() {
let input = document.createElement('input'... |
carto_quotables = [
'text-face-name'
];
carto_variables = [
'text-name'
];
var carto_functionMap= {
'Equal Interval': 'quartiles',
'Jenks': 'jenkBins',
'Heads/Tails': 'headTails',
'Quantile': 'quantileBins'
};
DEFAULT_QFUNCTION = 'Quantile';
/**
* Manage some carto properties depending on
* type (... |
/*
* Copyright © 2017 <NAME>, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to i... |
// To integrate the simulation to some HTML page, copy the table handling the simulation from the randomMathAddition page.
/*
* Here is the code you need to copy:
* <!-- Comments explaining the steps -->
<label id="commentSimulation" class="simVal"></label>
<input type="button" id="restartSimulation" value="Restart... |
//Constant colors used for rendering
//TODO - Consider a quote mode and a quote free mode
//Showing quotes in full is more visually appealing,
//but not showing them unless in a special mode seems more /useful/
//const QUOTE_COLOR = 0xAA000000;
const QUOTE_COLOR = 0xFF0000FF;
const QUOTE_COLOR_DIM = 0xFF000033;
const R... |
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
/*** requires cordova plugin add https://github.com/leecrossley/cordova-plugin-social-message.git
*
* @param {string} subject
* @par... |
/**
* pixelate: select part of a canvas to pixelate it.
*
* Usage:
* ------
*
* var pixelateInstance = pixelate(canvas, [options])
*
* options by default:
* {
* radius: 10,
* selector: {
* masked: true, // masked on select
* strokeStyle: 'black'
* },
*
* //TODO(hoatle): nice to have:
* ... |
/*
Copyright 2016 Google Inc. 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 applicable law or agreed to in ... |
/*!
* This module contains various server utility and helper functions.
* Note that it automatically exports functions from utilities.client.js
*
* Author: <NAME> (<EMAIL>)
* Copyright(c) 2015 Apify. All rights reserved.
*
*/
const crypto = require('crypto');
const request = require('request');
const cherow = r... |
var _ = require('underscore');
var exec = require('child_process').exec;
var express = require('express');
var gulp = require('gulp');
var s3 = require('gulp-s3');
var browserify = require('gulp-browserify');
var concat = require('gulp-concat');
var uglify = require('gulp-uglify')
var rename = require('gulp-rename');
v... |
var yearfacetedlst = [];
var makefacetedlst = [];
var modelfacetedlst = [];
var engineliterslst = [];
var enginecylinderlst = [];
var enginecclst = [];
var engineboreinchlst = [];
var enginestrokeinchlst = [];
var productfacetedlst = [];
var yearfacetedselectedlst = [];
var makefacetedselectedlst = [];
var modelfacet... |
/**
* @license
* Copyright 2019 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
*
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by ... |
import Vue from 'vue';
import App from '../src/components/app.vue';
import Spinner from '../src/components/spinner.vue';
import router from '../src/router';
import store from '../src/store';
import testData from './data';
import { beforeEachNav } from './router';
import { mountAndMark } from './destroy';
import { setR... |
const testCases = [];
function add_unit_test(format, adjustments, date, expection) {
testCases.push({
format: format.replace(/\\/g, '\\\\'),
adjustments,
date,
expection
});
}
function test() {
let testResults = {
total: 0,
success: 0,
fail: 0,
... |
import { Events, Internal } from "../../../../common/Events";
import { inRange } from "../../../../common/Util";
import { WildEmitter } from "./WildEmitter";
import { Message } from "./Message";
import { Metadata } from "./Metadata";
import { ChatUtility } from "./ChatUtility";
import { iCrypto } from "./iCrypto";
im... |
import React, { Component } from 'react';
import { translate } from 'react-i18next';
import { Col, Row, Tooltip, Menu, Tabs, Modal, Avatar, Button, Dropdown } from 'antd';
import resource from '../../Resource';
import { getClassDef } from '../../model.js';
import createComponent from '../Components'
import update from ... |
"use strict";
var ok = require("assert").ok;
var path = require("path");
var complain = require("complain");
var taglib = require("../taglib");
var charProps = require("char-props");
var UniqueVars = require("./util/UniqueVars");
var PosInfo = require("./util/PosInfo");
var CompileError = require("./CompileError");
v... |
// Licensed to Cloudera, Inc. under one
// or more contributor license agreements. See the NOTICE file
// distributed with this work for additional information
// regarding copyright ownership. Cloudera, Inc. licenses this file
// to you under the Apache License, Version 2.0 (the
// "License"); you may not use this f... |
var prefs = (function (Gtk3, Gtk4, Gio, GLib, GObject) {
'use strict';
const extensionUtils = imports.misc.extensionUtils;
if (!extensionUtils.gettext) {
// backport from v41
// https://gitlab.gnome.org/GNOME/gnome-shell/-/blob/1deb13e1aaabfd04b2641976a224b6fc2be3b9ec/js/misc/extensionUtils... |
'use strict';
import dateUtil from './date';
/**
* @param { Object, String } el 对象选择符或结点对象
*/
export const focusInput = (el) => {
function focus(elm) {
let inputEl = null;
if (elm.tagName === 'INPUT') {
inputEl = elm;
} else if (elm.querySelector) {
inputEl = elm.querySelector('input') ... |
// Copyright (c) 2015 - 2017 Uber Technologies, Inc.
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify... |
// # xml-to-es.js
/**
* author: jbroglio
* Date: 10/6/13
* Time: 10:30 AM
*/
var //mongo = require('mongoskin'),
util = require('util'),
xml2js = require('xml2js'),
parser = new xml2js.Parser({explicitArray: false, attrkey: "@", charkey: "#"}),
path = require('path'),
fs = require('fs'),
ha = require('... |
var assert = require("assert");
var sourceMap = require("source-map");
var normalizeOptions = require("./options").normalize;
var secretKey = require("private").makeUniqueKey();
var types = require("./types");
var isString = types.builtInTypes.string;
var comparePos = require("./util").comparePos;
var Mapping = require... |
/*Copyright 2019 Dynatrace 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/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distribut... |
/**
* Created by Elly on 2016/5/26.
* EL Table
* Author: <NAME>
*/
import React, {Component} from 'react';
import PropTypes from 'prop-types';
import classSet from 'classnames';
import Row from './Row';
import Header from './Header';
import NestedHeader from './Ne... |
const schedule = require('node-schedule');
const fb_constant = require('../../utils/firebase_constants');
const slack_constants = require('../../utils/slack_constants');
const mqtt_publish = require('../../mqtt/mqtt_publish');
const admin = require('firebase-admin');
// Slack integration
const slack = new slack_consta... |
/*jshint globalstrict:true, strict:true, esnext: true */
/* global global */
"use strict";
////////////////////////////////////////////////////////////////////////////////
/// DISCLAIMER
///
/// Copyright 2018 ArangoDB GmbH, Cologne, Germany
///
/// Licensed under the Apache License, Version 2.0 (the "License");
/// ... |
/* global $ d3 less L turf */
'use strict';
var App = App || {};
let documentPromise = new Promise(function(resolve) {
$(document).ready(function() {
console.debug('$(document).ready done');
resolve();
});
});
let windowPromise = new Promise(function(resolve) {
$(window).on('load', function() {
con... |
/*
* == BSD2 LICENSE ==
* Copyright (c) 2017, Tidepool Project
*
* This program is free software; you can redistribute it and/or modify it under
* the terms of the associated License, which is identical to the BSD 2-Clause
* License as published by the Open Source Initiative at opensource.org.
*
* This program ... |
import React, { useState, useEffect, useRef } from "react"
import { Text, Flex, Box } from "rebass"
import styled from "@emotion/styled"
import { useForm } from "react-hook-form"
import Pill from "../../../../components/pill"
import Modal from "../../../../components/modal"
import ImageUpload from "../../../../compone... |
/* jshint node: true */
'use strict';
require('./services/app.services.js');
//-- from vendors :: start
// require('jquery');
// require('jquery-ui');
// require('jquery-easing');
// require('angular');
// require('bootstrap/dist/css/bootstrap.min.css');
// require('bootstrap/dist/js/bootstrap.min.js');
// require("... |
// https://localhost:3000/map?building=food-space
import gsap from "gsap";
import * as THREE from "three";
import { OrbitControls } from "three/examples/jsm/controls/OrbitControls.js";
import { GLTFLoader } from "three/examples/jsm/loaders/GLTFLoader.js";
import { DRACOLoader } from "three/examples/jsm/loaders/DRACOLoa... |
$(document).ready(function () {
// Check every 20 seconds
setInterval(function () {
checkTwitchStatus();
}, 1000 * 20);
// Perform first update
checkTwitchStatus();
// Add countries to modal select
for (const country of countries) {
if (country["alpha-2"] == "GB") {
$("#c... |
import '../../css/menu_left.css';
import { SplitPanel, Widget } from '@phosphor/widgets';
import fuzzysearch from 'fuzzysearch';
import { GeoJSON } from 'ol/format';
import DB from '../DB';
import createBoxClue from '../clue_panel';
import { makeSectionTarget } from '../clue_transformation';
import commands from '../co... |
var isIntlTransaction = false;
var fixApiRefNav = function() {
if ($('#the-nav li').length >= 22) {
$('#the-nav').data('offset-bottom', '160');
}
};
var fixDropDownMenuLargePosition = function() {
setTimeout(function() {
$('.dropdown-large').each(function() {
var left = $(this)... |
/* global palette */
/* global $ */
/* global Chart */
var CONNECT_STATUS_NO = 0;
var CONNECT_STATUS_CONNECTING = 1;
var CONNECT_STATUS_RECONNECTING = 2;
var CONNECT_STATUS_CONNECTED = 3;
var CONNECT_STATUS_UNRESPONSIVE = 4;
var CONNECT_STATUS_DISCONNECTED = 5;
$(document).ready(function () {
window... |
const chai = require("chai");
const paillier = require('../node_modules/paillier-bignum/src/paillier.js');
const { encryptWithProof, verifyProof } = require('paillier-in-set-zkp');
const bignum = require('big-integer');
const zkSnark = require('snarkjs');
const { stringifyBigInts, unstringifyBigInts } = require("../nod... |
/* THINGS I HAVE ACCOMPLISHED
1. Change gameplan and collision
2. Make a system for enemies to spawn on both sides of the screen randomly and come towards the middle
3. create stages or waves of the enemies spawning
4. used Mr. Cozort's timer system with the addition of having it stop when collision takes place as a f... |
"use strict";
function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); }
function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must... |
// Based on https://github.com/KaTeX/KaTeX/blob/v0.11.1/contrib/render-a11y-string/render-a11y-string.js
/**
* renderA11yString returns a readable string.
*
* In some cases the string will have the proper semantic math
* meaning,:
* renderA11yString("\\frac{a}{b}"")
* -> "start fraction, a, divided by, b, end... |
/**Inicijalna deklaracija vrijednosti koje se korite u stranici*/
const domainUrl = location.origin;
//const domainUrl = "http://localhost:8088";
//const domainUrl = "http://172.16.31.10";
const wmsUrl = domainUrl + "/geoserver/winsoft/wms";
const wfsUrl = domainUrl + "/geoserver/winsoft/wfs";
const imageUrl = domainUr... |
/** @preventMunge */
/* ^ see http://stackoverflow.com/questions/30110437/leading-underscore-transpiled-wrong-with-es6-classes */
'use strict';
import React from 'react';
import PropTypes from 'prop-types';
import _ from 'underscore';
import Modal from 'react-bootstrap/esm/Modal';
import FormControl from 'react-boots... |
import React, { Component } from "react";
// import '../Chat.css'
import moment from "moment";
import axios from "axios";
import { toJS, observable } from "mobx";
import { observer } from "mobx-react";
import store from "../store/store";
import ReactHtmlParser from "react-html-parser";
import jss from "jss";
import pre... |
import React, { Component } from 'react';
class Test extends Component {
constructor(){
super();
this.state = {
answers: { q1: '',
q2: '',
q3: '',
q4: '',
q5: '',
q6: '',
q7: '',
q8: '',
q9: '',
q10: '',
q11: '',
q12: '',
q1... |
/* eslint-disable eqeqeq */
/* eslint-disable react/jsx-indent */
/* eslint-disable react/no-unused-state */
/* eslint-disable camelcase */
/* eslint-disable no-nested-ternary */
import React, { PureComponent } from 'react';
import { connect } from 'dva';
import { routerRedux } from 'dva/router';
import {
Row,
Col,... |
OpenJsCad = function() {
};
var viewer, show_axis, show_grid;
var DEFAULT_COLORSCHEME = { backgroundColor: [0.93, 0.93, 0.93], faceColor: [0.8,0.8,0.8] };
// A viewer is a WebGL canvas that lets the user view a mesh. The user can
// tumble it around by dragging the mouse.
OpenJsCad.Viewer = function(containerelement... |
const {
getChargeText
} = require('./UtilityFunctions');
const Line = require('./Line');
const Vector2 = require('./Vector2');
const MathHelper = require('./MathHelper');
function makeid(length) {
var result = '';
var characters = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxy... |
const Discord = require("discord.js");
const config = require("./config.json");
const bot = new Discord.Client();
//TEXT VARIABLES
const graves = '```';
const padding = '\n\n\nControls:';
const pickaxe = 'Ͳ';
var playerChar = {'w':'▲Ͳ','a':'Ͳ◀','s':'Ͳ▼','d':'▶Ͳ','▲Ͳ':'w','◀Ͳ':'a','Ͳ▼':'s','▶Ͳ':'d'};
var empty = ['e','... |
var _gaq = _gaq || []; // if not defined yet
/*
if (window.console) {
_gaq.push = function(arr) {
arr.shift();
var msg = "TRACK: " + arr[0] + " - " + arr[1];
if (arr.length > 2) {
msg = msg + " (" + arr[2] + ")";
}
console.log(msg);
}
} */
/**
* LifeSizeScr... |
'use strict';
function _interopDefault (ex) { return (ex && (typeof ex === 'object') && 'default' in ex) ? ex['default'] : ex; }
var _regeneratorRuntime = _interopDefault(require('@babel/runtime/regenerator'));
var _asyncToGenerator = _interopDefault(require('@babel/runtime/helpers/asyncToGenerator'));
var _classCall... |
var parser = require('./parser.js'),
path = require('path'),
fs = require('fs'),
spaces = ' ',
export_list = [],
need_utils = false,
compile_directory = false,
identifier_regexp = /^[_$a-zA-Z][_$a-zA-Z0-9]*$/;
active_loops = 0;
var alias = {
"and" : "&&",
"or" : "||",
"is" : "===",
"is not" : "!==",
... |
/*
* Copyright (c) 2017 Cornell University
*
* 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 o... |
// jshint -W041
/*
\x1b[<seq1>;<seq2>...m
dark - 30-37 40-47
bright - 90-97 100-107
*/
let c8d = [0x000000, 0x800000, 0x008000, 0x808000, 0x000080, 0x800080, 0x008080, 0xc0c0c0];
let c8b = [0x808080, 0xff0000, 0x00ff00, 0xffff00, 0x0000ff, 0xff00ff, 0x00ffff, 0xffffff];
let c256 = [
0x000000, 0x800000, 0x008000, 0x80... |
/*
worldpx_pertile = 128;
renderpx_pertile = 16;
worldpx_to_renderpx = function(n) {
return ((n / worldpx_pertile) * renderpx_pertile);
};
renderpx_to_worldpx = function(n) {
return ((n / worldpx_pertile) * renderpx_pertile);
};
drawcircle_render = function() {
drawx *= scale;
drawy *= scale;
drawr... |
const fs=require('fs');
const Discord=require("discord.js");
const client=new Discord.Client();
const db = require('quick.db')
const moment = require("moment");
const ayarlar=require("./ayarlar.json");
const express = require('express');
/////
const app = express()
app.get('/', (req, res) => res.send("Bot Aktif"))
app.... |
let fruitNinjaRunning = false;
let whackAMoleRunning = false;
function startFromChoppingTable() {
const ingredientsToPlayWith = [];
const cuttingSurface = document.getElementById("cuttingSurface");
cuttingSurface.setAttribute("style", "outline: ");
for (let i = 0; i < existingDraggableIngredientInst... |
/*
TODO:
- Agregar porcentaje de barra de PESO.
- Completar código con comentarios.
- Refactor a todo jaja.
- Agregar más ingredientes y recetas.
- Poner una indicación de ingredientes procesados.
- Agregarle peso a todos los ingredientes y recetas.
- Agregarle precio default a ... |
/*
* Copyright 2021 Adobe. All rights reserved.
* This file is licensed to you 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 appli... |
import * as THREE from 'three';
import { CONSTANTS, EquirectangularAdapter, PSVError, utils } from '../..';
import { Queue } from '../shared/Queue';
import { Task } from '../shared/Task';
import { buildErrorMaterial, createBaseTexture } from '../shared/tiles-utils';
/**
* @callback TileUrl
* @summary Function calle... |
//-----------------------------------------------------------------------------
// Galv's Custom Title
//-----------------------------------------------------------------------------
// For: RPGMAKER MV
// GALV_CustomTitle.js
//-----------------------------------------------------------------------------
// 2... |
'use strict';
// ---------------------------------------------------------------------------
const Exchange = require ('./base/Exchange');
const { ArgumentsRequired, OrderNotFound, InvalidOrder, NotSupported, BadRequest } = require ('./base/errors');
const { TICK_SIZE } = require ('./base/functions/number');
// --... |
/* global i18n */
/* eslint-disable max-len */
import { LitElement, html } from 'lit';
const IconCommon = (val) => `<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 20 20" width="20px" height="20px" fill="currentColor">${val}</svg>`;
const boldIcon = () => IconCommon('<path d="M10.187 17H5.773c-.637 0-1.092-.138-... |
/****************************************************************************
** @license
** This demo file is part of yFiles for HTML 2.2.
** Copyright (c) 2000-2019 by yWorks GmbH, Vor dem Kreuzberg 28,
** 72070 Tuebingen, Germany. All rights reserved.
**
** yFiles demo files exhibit yFiles for HTML functionali... |
// Slack chat data to solid
// See https://api.slack.com/methods
// See https://www.npmjs.com/package/slack
// and https://api.slack.com/methods/conversations.list
// and https://www.npmjs.com/package/slack
const command = process.argv[2]
const targetRoomName = process.argv[3] // solid/chat
const archiveBaseURI = pr... |
import * as d3 from 'd3';
import { get_id, get_class } from '../../config/id.config';
import { yTrans } from '../sc-graph/utils';
import store from '../../models/store/index';
// 1, 计算总bbox
// bbox: [[xmin, ymin], [xmax, ymax]];
function calculate_bbox_from_navigation(navigation) {
let bbox0 = navigation[0].bbox;
... |
require('styles.scss');
class FourCorners {
constructor(opts = {}) {
let embeds = [];
if(opts.elem instanceof Element) {
embeds = [opts.elem];
} else if(NodeList.prototype.isPrototypeOf(opts.elem)) {
embeds = Array.from(opts.elem);
} else {
const selector = (typeof opts.selector == 'string' ? opts.se... |
/*
@author <NAME>
MIT License
Copyright (c) 2017 <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, modify, merge, ... |
var STATUS_POLLING_INTERVAL_MILLIS = 60 * 1000; // One minute.
/*
Copyright 2015 Google Inc. 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/L... |
/**
* Ingestor Driver code
* *************************************************************************************************
* ** Description
* *************************************************************************************************
* The Ingestor driver code is basically responsible for ensuring that ... |
function ScatterPlotMatrix( axes_matrix, ranges_matrix, intervals, dataid, data_matrix, scale, isBinned, datakeys )
{
this.matrix = {};
this.graph = new THREE.Group();
this.isBinned = isBinned;
this.scale = scale;
var axis = Object.keys(SERVICE).sort();
var axisNo = axis.length
for( var p=0... |
/* eslint-disable */
// TODO: remove once refactored
import NoDataOverlay from '../components/nodataoverlay'
const d3 = Object.assign(
{},
require('d3-array'),
require('d3-axis'),
require('d3-collection'),
require('d3-format'),
require('d3-selection'),
require('d3-scale'),
);
var getSymbolFromCurrency =... |
const {
Scene, Mesh, WebGLRenderer, PerspectiveCamera,
CubeGeometry, PlaneGeometry, MeshLambertMaterial,
AmbientLight, DirectionalLight, PointLight, Raycaster, Vector3, Vector2,
Projector, Texture, UVMapping, RepeatWrapping, NearestFilter,
LinearMipMapLinearFilter, ClampToEdgeWrapping, Clock
} = THREE;
const... |
/**
* @license
* Copyright 2011 <NAME> (<EMAIL>)
* MIT-licensed (http://opensource.org/licenses/MIT)
*/
/*global Dygraph:false,TouchEvent:false */
/**
* @fileoverview This file contains the RangeSelector plugin used to provide
* a timeline range selector widget for dygraphs.
*/
/*global Dygraph:false */
"use s... |
/**
* A fast javascript implementation of simplex noise by <NAME>
*
* Based on a speed-improved simplex noise algorithm for 2D, 3D and 4D in Java.
* Which is based on example code by <NAME> (<EMAIL>).
* With Optimisations by <NAME> (<EMAIL>).
* Better rank ordering method by <NAME> in 2012.
*
* Copyright (c) 20... |
/* eslint camelcase: "off", eqeqeq: "off" */
import Config from './session/config'
/*
* Saved references to long variable names, so that closure compiler can
* minimize file size.
*/
const ArrayProto = Array.prototype,
FuncProto = Function.prototype,
ObjProto = Object.prototype,
slice = ArrayProto.slic... |
// Model position
// const posX = 0.0;
// const posY = -650;
// const posZ = 2.0;
const posX = 0;
// const posX = 0;
// const posY = 100;
const posY = -1;
const posZ = -5.0;
// const posZ = -2.0;
// Model size
const scale = 5;
// const scale = 575; //ortho
let renderer, scene, camera;
let loading;
function worldToSc... |
'use strict';
function earcut(data, holeIndices, dim) {
dim = dim || 2;
var hasHoles = holeIndices && holeIndices.length,
outerLen = hasHoles ? holeIndices[0] * dim : data.length,
outerNode = linkedList(data, 0, outerLen, dim, true),
triangles = [];
if (!outerNode) return triangl... |
/**
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"... |
/**
* @author <NAME>
* */
// Show detail from server
function newPerson(imageURL, passportURL, workpermitURL, visaURL) {
// Get all field value
let { name_en, name_th, nationality,
passportNumber, datepickerPassport,
datepickerWorkpermit, visaType,
datepickerVisa,
dateApplicationExtendsion,
... |
'use strict';
Object.defineProperty(exports, '__esModule', { value: true });
var React = require('react');
var PropTypes = require('prop-types');
/*! *****************************************************************************
Copyright (c) Microsoft Corporation. All rights reserved.
Licensed under the Apache Lic... |
// Copyright Joyent, Inc. and other Node contributors.
//
// 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, modi... |
const {defaultSchema: schema} = require("../schema")
const {doc, blockquote, pre, h1, h2, p, li, ol, ul, em, strong, code, a, a2, img, img2, dataImage, br, hr} = require("./build")
const {defTest} = require("./tests")
const {tr, testTransform} = require("./trans")
function add(name, doc, expect, mark) {
defTest("a... |
/*
* A simple chess AI, by someone who doesn't know how to play chess.
* Uses the chessboard.js and chess.js libraries.
*
* Copyright (c) 2020 <NAME>
*/
var STACK_SIZE = 100; // maximum size of undo stack
var board = null;
var $board = $('#myBoard');
var game = new Chess();
var globalSum = 0; // always from blac... |
// Define game board dimensions
const dimension=8;
const gridsize=50;
// Game state is global to prevent it going out of scope
var gs={
// Arsenal of weapons
arsenal:{used:0, total:24},
// Record of ammo used during best successful clearance
record:0,
// Has the initial game board generation been done
ge... |
// constants
var kSVGScale = 0.1 // how bmuch metrics are scaled in the SVGs
var kGlyphSize = 346 // at kSVGScale. In sync with CSS and SVGs
var kUPM = 2816
function pxround(n) {
return Math.round(n * 2) / 2
}
// forEachElement(selector, fun)
// forEachElement(parent, selector, fun)
function eachElement(par... |
/* Name: <NAME>
Project: programmeerproject minor programmeren
Studentnumber: 10811834
'createScatterPlot.js'
This script creates the scatterplot visualisation and contains the functions to
update the scatterplot to show data of a different year.
*/
var sunburstData;
var hygieneData;
var geographics;
var regionOptio... |
// karma - reward good and penalize bad mail senders
var ipaddr = require('ipaddr.js');
var redis = require('redis');
var phase_prefixes = ['connect','helo','mail_from','rcpt_to','data'];
exports.register = function () {
var plugin = this;
plugin.deny_hooks = ['unrecognized_command','helo','data','data_post'... |
/**
* ██╗ ██╗██╗███╗ ██╗ ██████╗ ██████╗ ██████╗ ██████╗ ███████╗███████╗██╗███████╗██╗ ██╗
* ██║ ██╔╝██║████╗ ██║██╔════╝ ██╔════╝██╔═══██╗██╔══██╗██╔════╝██╔════╝██║██╔════╝██║ ██║
* █████╔╝ ██║██╔██╗ ██║██║ ███╗██║ ██║ ██║██║ ██║█████╗ █████╗ ██║███████╗███████║
* ██╔═██╗ ██║██║╚██╗██║██║ ██║█... |
import assert from "assert";
import {inspect} from "util";
import {Script} from "vm";
import {
isString, isEmpty, has, keys, each, map, omit,
} from "underscore";
import {sha1} from "../fs/watch.js";
import {matches as archMatches} from "../utils/archinfo.js";
import {findImportedModuleIdentifiers} from "./js-analyze... |
import { findIndex, uniq, get, clamp, isPlainObject, isNumber } from 'lodash'
import { resolveOffset } from './helper'
/**
*
* @param {Element} element 参考元素
* @param {string} selectors 用来查找目标元素的选择器
* @returns {?Element} 查找到的元素
*/
export function closest (element, selectors) {
if (element.closest) {
return e... |
function Inspection() {
this.lastTime = false;
this.tape = () => {
app.progress = true;
$('#loading-data').show();
let data = {
page: app.page,
};
app.ajax(`/api/token${app.token}/inspection/tape`, data, json => {
$('#loading-data').hide();
... |
"use strict";
/**
* ## Retrieving the configuration files and merge them into the final configuration structure
*
* @packageDocumentation
*/
Object.defineProperty(exports, "__esModule", { value: true });
exports.Converter = void 0;
const issues = require("./issues");
const utils = require("./utils");
const front_ma... |
/*
* ButtheadScript by AvatarKava - beavisbot(at)phpmonkeys(dot)com
* adapted from SimplePlugScript by Enyxx - arkaenyx(at)gmail(dot)com
* This work is under CreativeCommons BY-NC-SA 3.0
* http://creativecommons.org/licenses/by-nc-sa/3.0/legalcode*/
// "use strict";
var nxVersion = "2.4";
var notice = "ButtheadScr... |
/*
* Copyright 2013 Jive Software
*
* 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 l... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.