text
stringlengths
3.07k
16k
let Board = [ ] function bootBoard() { //Add Corners Board.push({ x: 0, y: 0, name: "Go", type: "Corner" }) Board.push({ x: 10, y: 0, name: "Jail", type: "Corner" }) Board.push({ x: 10, y: 10, name: "Free Parking", type: "Corner" }) Board.push({ x: 0, y: 10, name: "Go to Jail", type: "Corner" }) //Draw ...
import _ from 'lodash'; import {Room, FakeRoom} from './room'; import {Evented} from './evented'; import {log, defer} from './util'; const TYPE_ACKERR = 0; const TYPE_ACK = 1; const TYPE_PING = 2; const TYPE_PONG = 3; const TYPE_MESSAGE = 4; export const CLOSE_REPLACED = 3001; export const CLOSE_TIMEOUT = 3002; cons...
import styled from "styled-components"; const StyledSection = styled.section` display: flex; flex-flow: column nowrap; width: calc(100vw - 32px); padding: 0 16px; & .imagecontainer { position: relative; top: -24px; left: -24px; width: 80vw; height: 80vw; margin-bottom: 24px; background: ${(props) =...
// https://www.khanacademy.org/computer-programming/tree-fractal-v2/2367763251 /** * <NAME> * I realized how complicated I made my original program * after seeing <NAME>'s tree generator.. * https://www.khanacademy.org/cs/tree-generator/822944839 * I twiddled with rotate and translate and (finally) * figured th...
import React, {Component} from 'react'; import {Container,Button,Card,Segment,Dimmer,Loader, Message, Form} from 'semantic-ui-react'; import styles from "../../styles/pages/INDEX.module.scss"; // Styles import TravelerLoot from '../../ethereum/build/TravelerLoot.sol.json'; class Claim extends Component{ state = { ...
import React, { useState } from "react"; import { Link } from "react-router-dom"; import Form from "utilities/Forms"; import { signin } from 'actions/auth'; import { useHistory } from 'react-router-dom'; import { useDispatch, useSelector } from 'react-redux'; import { adminsignin } from "actions/auth"; const initialSt...
var yaml = require('js-yaml'); var last = require('lodash/last'); var trim = require('lodash/trim'); var sortBy = require('lodash/sortBy'); var encrypt = require('donejs-travis-encrypt'); var isObject = require('lodash/isObject'); var Generator = require('yeoman-generator'); var parseGithubUrl = require('parse-github-u...
import React, {Component} from "react"; import {Dimensions, FlatList, StyleSheet, Text, View, WebView, Platform} from "react-native"; import IconFa from "react-native-vector-icons/FontAwesome"; import IconEv from "react-native-vector-icons/EvilIcons"; import PropTypes from "prop-types"; import {NavigationActions} from ...
/* * @Author: czy0729 * @Date: 2019-03-22 08:49:20 * @Last Modified by: czy0729 * @Last Modified time: 2022-05-18 11:32:50 */ import { observable, computed } from 'mobx' import { systemStore, calendarStore, userStore, discoveryStore, usersStore } from '@stores' import { date, getTimestamp, appNavigate, a...
const main = () => { const canvas = document.querySelector("#canvas"); const gl = canvas.getContext("webgl"); if (gl === null) { alert("Unable to initialize WebGL. Your browser or machine may not support it"); return; } const vsSource = ` attribute vec4 aVertexPos...
'use strict'; // https://dom.spec.whatwg.org/#interface-parentnode // Document, DocumentFragment, Element const { ATTRIBUTE_NODE, DOCUMENT_FRAGMENT_NODE, ELEMENT_NODE, TEXT_NODE, NODE_END, COMMENT_NODE } = require('../shared/constants.js'); const {PRIVATE, END, NEXT, PREV, START, VALUE} = require('../shar...
import * as d3 from 'd3' import {store, util} from '../config' import DotPlotScale from '../vis/dot_plot_scale' import _ from 'lodash' class InferStackingPlot { constructor () { this.outerWidth = 1050 this.outerHeight = 250 this.margin = { top: 2, right: 20, bottom: 30, left: 20 ...
// == BSD2 LICENSE == // Copyright (c) 2014, 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 is ...
const fs = require('fs'); const fsext = require('fs-extra'); const path = require('path'); const TransformPackage = require('graphql-transformer-core'); const S3 = require('../src/aws-utils/aws-s3'); const ROOT_APPSYNC_S3_KEY = 'amplify-appsync-files'; const providerName = require('./constants').ProviderName; const {...
// @flow // Express is our HTTP server. const express = require("express"); /* This is how we can export our routes into app.js the mergeParams argument is required here because in app.js, we have a route param in the app.use() prefix. */ const router = express.Router({mergeParams: true}); const Nutrition = req...
'use strict'; /** * world.js is loaded by the cucumber framework before loading the step definitions and feature files * it is responsible for setting up and exposing the driver/browser/expect/assert etc required within each step definition */ var fs = require('fs-plus'); var path = require('path'); var requireDir...
/* * Copyright © 2016-2019 The Thingsboard Authors * * 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 applicabl...
import MarkdownIt from "markdown-it"; const md = new MarkdownIt({ html: false }); class PageComments { constructor(elem) { this.elem = elem; this.pageId = Number(elem.getAttribute('page-id')); this.editingComment = null; this.parentId = null; this.container = elem.querySel...
const { inquirer, ora, chalk } = require('schemium-api').essentials; const path = require('path'); const file = require('fs'); const config = require('../../../config') const clear = require('clear'); const Case = require('case'); class TemplatePrompt { constructor(){ this.boilerplate = {}; ...
var roleHarvester = require('role.harvester'); var roleStaticHarvester = require('role.static_harvester'); var roleUpgrader = require('role.upgrader'); var roleBuilder = require('role.builder'); var roleCarry = require('role.carry') var roleTower = require('role.tower') var attack_room2 = require('role.attack_room2') v...
import * as d3 from 'd3' import * as R from 'ramda' import React, { useEffect, useRef, useCallback } from 'react' import { backgroundColor, zircon, primaryColor } from 'src/styling/variables' const transactionProfit = tx => { const cashInFee = tx.cashInFee ? Number.parseFloat(tx.cashInFee) : 0 const commission = ...
/* eslint-disable global-require */ const AssetsPlugin = require('assets-webpack-plugin'); const CopyWebpackPlugin = require('copy-webpack-plugin'); const MomentTimezoneDataPlugin = require('moment-timezone-data-webpack-plugin'); const webpack = require('webpack'); const dotenv = require('dotenv'); const { getClientEnv...
import React from 'react'; import PropTypes from 'prop-types'; import { graphql } from 'react-apollo'; import { FormattedMessage, defineMessages, injectIntl } from 'react-intl'; import gql from 'graphql-tag'; import InputField from '../InputField'; import SmallButton from '../SmallButton'; import { cloneDeep, pick } fr...
const { doesNotMatch } = require('assert'); var assert = require('assert'); const chai = require("chai") const chaiHttp = require("chai-http"); const { NOTIMP } = require('dns'); const { resolve } = require('path'); const expect = chai.expect const app = require('../Backend/routes.js') chai.use(require('chai-like')) ch...
#!/usr/local/bin/nodejs const fs = require("fs"); const Canvas = require('canvas'); const Image = Canvas.Image; const palette = // fs.readFileSync('paletteFinal.hex', 'utf-8') `181c20 4a5052 a4a19c ffffff 202c9c 5255ff 08a18b 39b2de 8b20ac f691a4 a42010 ff8518 ffde39 734429 527d10 83ce18` .split('\n') .fi...
var ww = window.innerWidth; var wh = window.innerHeight; function Tunnel(texture) { this.init(); this.createMesh(texture); this.handleEvents(); this.initAnimation(); window.requestAnimationFrame(this.render.bind(this)); } Tunnel.prototype.init = function() { this.speed = 8; this.mouse = { positi...
/** * @param {string} value * @returns {RegExp} * */ /** * @param {RegExp | string } re * @returns {string} */ function source(re) { if (!re) return null; if (typeof re === "string") return re; return re.source; } /** * @param {...(RegExp | string) } args * @returns {string} */ function concat(...args...
import { traverse, traverseBreak } from "../lib/xast.js"; import { parseName } from "../lib/svgo/tools.js"; export const type = "full"; export const active = true; export const description = "removes unused IDs and minifies used"; export const params = { remove: true, minify: true, prefix: "", preserve: [],...
$(document).ready(function(){ $("input, select").focus(function(){ $("p").text(""); $("input, select").css("border-color", ""); }); }); function cleanModal(){ $("#titulo-modal").text(NUEVA_REGLA); $(".form-edit").prop("disabled",false); $(".form-edit").val(""); $("#parametro-1").text(""); $("#parametro-2"...
/* * node-frame: script/bootstrap.js * * Copyright (c) 2014, <NAME>. All rights reserved. * * @author: spolu * * @log: * - 2014-07-18 spolu Creation */ "use strict" var async = require('async'); var mkdirp = require('mkdirp'); var path = require('path'); var fs = require('fs-extra'); var os = require('os');...
var __rest = (this && this.__rest) || function (s, e) { var t = {}; for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p]; if (s != null && typeof Object.getOwnPropertySymbols === "function") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < ...
/** * Hermes: Module AJAX * author: <NAME> * since: 25/05/2018 */ const METHOD = { GET: "GET", POST: "POST", PUT: "PUT", HEAD: "HEAD", DELETE: "DELETE" }; var Hermes = (function() { var httpConfigurationStorage; var HttpRequestConfiguration = function(name, method, uri) { var...
/* * Licensed to Elasticsearch B.V. under one or more contributor * license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright * ownership. Elasticsearch B.V. licenses this file to you under * the Apache License, Version 2.0 (the "License"); you may * not u...
import FileData from "/emcJS/storage/FileData.js"; import EventBus from "/emcJS/util/events/EventBus.js"; import StateStorage from "/script/storage/StateStorage.js"; import Logic from "/script/util/logic/Logic.js"; import ExitRegistry from "/script/util/world/ExitRegistry.js"; const OPTIONS = { "option.shuffle_gro...
import React, { useCallback } from 'react'; import { makeStyles, TextField, Grid, Button, Select, MenuItem } from '@material-ui/core'; import { AddCircle, Close } from '@material-ui/icons'; import { Formik, FieldArray } from 'formik'; import { useDispatch, useSelector } from 'react-redux'; import { colors } from 'Const...
import axios from "axios"; export const FETCHING_ARTICLES = "FETCHING_ARTICLES"; export const FETCHING_ARTICLES_SUCCESS = "FETCHING_ARTICLES_SUCCESS"; export const FETCHING_ARTICLES_FAILURE = "FETCHING_ARTICLES_FAILURE"; export const ADDING_ARTICLES_REQUEST = "ADDING_ARTICLES_REQUEST"; export const ADDING_ARTICLES_SU...
// This is heavily based on https://github.com/sindresorhus/electron-context-menu // ❤ @sindresorhus import { clipboard, remote, ipcRenderer, shell, } from 'electron'; import { isDevMode, isMac } from '../environment'; import { SPELLCHECKER_LOCALES } from '../i18n/languages'; const debug = require('debug')('Franz:...
import debounce from 'underscore/modules/debounce' import Vue from 'vue' const debounceThreshold = 500 const defaultState = () => { return { config: { name: undefined }, publicMode: false, loadingCrates: false, currentCrate: undefined, crates: [], externalCrates: [], currentCrateLinks: [], curre...
//function generateData() { var constituencies = ["Belfast East", "Belfast North", "Belfast South", "Belfast West", "East Antrim", "East Londonderry", "Fermanagh and South Tyrone", "Foyle", "Lagan Valley", "Mid Ulster", "Newry and Armagh", "North Antrim", "North Down", "South Antrim", "South Down", "Strangford",...
function addTranslateButton() { if (configs.debugMode) console.log('Checking if its needed to add Translate button...'); // var selectedText = selection.toString().trim(); function proccessButton(shouldTranslate, languageOfSelectedText) { if (shouldTranslate == true) { const tr...
// @ts-check /* * Imported from <NAME>'s reference implementation with minimum modification * to handle Int64. * * https://github.com/douglascrockford/JSON-js/blob/c98948ae1944a28e2e8ebc3717894e580aeaaa05/json_parse.js * * Original license header: * * json_parse.js * 2015-05-02 * Public Domain. * NO WARRANT...
import {useContext, useState} from 'react' import PropTypes from 'prop-types' import Link from 'next/link' import colors from '@/styles/colors' import theme from '@/styles/theme' import Alert from '@/components/alert' import {getNumeroComplet} from '@/lib/ban' import Certification from '../certification' import Parc...
/* * Copyright 2020 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 React, { Component, useEffect } from "react"; // import styled from "styled-components"; // import { DisplayArea } from "./DisplayArea"; // import { Annotation } from "./Annotation"; import { // MdEdit, // MdFileDownload, // MdFileUpload, MdSave, MdInfoOutline, } from "react-icons/md"; // import { FiBo...
import { GLOBAL, STRICT } from '../helpers/constants'; import { patchRegExp$exec } from '../helpers/helpers'; const Symbol = GLOBAL.Symbol || {}; const run = assert => { assert.isFunction(''.search); assert.arity(''.search, 1); assert.name(''.search, 'search'); assert.looksNative(''.search); assert.nonEnume...
"use strict"; var pivot_dataset = [ { Amount: 100, Country: "Canada", Date: "FY 2005", Product: "Bike", Quantity: 2, State: "Alberta" }, { Amount: 200, Country: "Canada", Date: "FY 2006", Product: "Van", Quantity: 3, State: "British Columbia" }, { Amount: 300, Country: "Canada", Date: "FY 2007", Product: "...
import { PureComponent } from 'react'; import PropTypes from 'prop-types'; import { Map, Set } from 'immutable'; import { connect } from 'react-redux'; import { createSelector } from 'reselect'; import { ArrowKeyStepper, CellMeasurer, CellMeasurerCache, InfiniteLoader, AutoSizer, List } from 'react-virtualized'; import...
var _ = require('lodash'); var url = require('url'); var util = require('util'); var m2m = require('m2m-ota-javascript'); var Watcher = require('../lib/watcher'); var UdpListener = require('../lib/udp-listener'); var schema = require('../lib/redis-schema'); var logger = require('../lib/logger')('proxy'); function Ga...
var _ = require('./lodash-local') var util = require('./util') module.exports = {} module.exports.getPipesObject = function(Flexio) { return new function() { this.create = function(pipe, callback) { var data if (_.isPlainObject(pipe)) { data = pipe } else if (pipe instanceof F...
/* Keep in mind that you can't use browser specific calls. Use following calls --Loading httpContents-- loadURL(method,url,headers); --Logging to the Console-- log(value); --Base64-- base64Encode(string); Expected result is a JSON representation of an array. [ {"startDate":"2015-05-24T17:49:27+02:0...
"use strict" var o = require("ospec") var parseQueryString = require("../../querystring/parse") o.spec("parseQueryString", function() { o("works", function() { var data = parseQueryString("?aaa=bbb") o(data).deepEquals({aaa: "bbb"}) }) o("parses empty string", function() { var data = parseQueryString("") o...
/* eslint-env mocha */ /* global artifacts */ const Eth = require('ethjs'); const HttpProvider = require('ethjs-provider-http'); const EthRPC = require('ethjs-rpc'); const abi = require('ethereumjs-abi'); const fs = require('fs'); const ethRPC = new EthRPC(new HttpProvider('http://localhost:7545')); const ethQuery = ...
var stringUtils = require('../helper/stringUtils'); var normalize = stringUtils.normalize; var removeSpaces = stringUtils.removeSpaces; /* Jaro-Winkler algo returns 1.0 only when strings are identical Totally different strings return 0. */ var jw = function (s1, s2) { var m = 0; // Exit early if either are e...
const Discord = require('discord.js'); const request = require('node-superfetch'); const moment = require('moment'); require('moment-duration-format'); module.exports.run = async (client, msg, args) => { const aylar = { "01": "Ocak", "02": "Şubat", "03": "Mart", "04": "Nisan", "05": "M...
var fs = require('fs'); var path = require('path'); var util = require('util'); var http = require('http'); var events = require('events'); var WebSocket = require('ws'); var endpoint = require('endpoint'); // Load library var library = {}; fs.readdirSync(path.resolve(__dirname, 'lib')) .filter(function (filename...
import React, { Component } from 'react'; import Reflux from 'reflux'; import { StyleSheet, Text, View, Animated, Dimensions, PanResponder, TouchableHighlight } from 'react-native'; import color from 'color'; import Palette from 'google-material-color/dist/palette'; import Icon from 'react-native-vector-i...
import { setFieldProperty, handleFieldChange } from "egov-ui-kit/redux/form/actions"; import get from "lodash/get"; import { getUserInfo, getLocale } from "egov-ui-kit/utils/localStorageUtils"; import { getTranslatedLabel } from "egov-ui-kit/utils/commons"; import { fetchLocalizationLabel } from "egov-ui-kit/redux/app/...
var SpotifyWebApi = require('spotify-web-api-node'); var creds = { clientId: process.env.SPOTIFY_CLIENT_ID, clientSecret: process.env.SPOTIFY_CLIENT_SECRET }; var spotifyApi = new SpotifyWebApi(creds); var spotifyUser = process.env.SPOTIFY_USERNAME; var spotifyPlaylistId = process.env.SPOTIFY_PLAYLIST; var slack = ...
"use strict"; /** * Copyright (c) 2017-present, Ephox, Inc. * * This source code is licensed under the Apache 2 license found in the * LICENSE file in the root directory of this source tree. * */ var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendSta...
'use strict'; /** * Created by gimm on 3/13/2015. */ var util = require('util'), path = require('path'), assert = require('assert'), spawn = require('child_process').spawn, merge = require('deepmerge'), tinylr = require('tiny-lr'), es = require('event-stream'), Q = require('q'), chalk...
import React from 'react'; import PropTypes from 'prop-types'; import Icon from 'react-native-vector-icons/Ionicons'; import moment from 'moment'; import { Formik } from 'formik'; import { connect } from 'react-redux'; import { View, TouchableOpacity, Text, TextInput, Alert, } from 'react-native'; import styles from ...
import React, { useState, useEffect } from 'react'; import { Redirect, useParams } from 'react-router-dom'; import { useDispatch, useSelector } from 'react-redux'; import { Spin, Layout } from 'antd'; import { addPlayerToBattle, getBattleDetail, streamBattleDetail, streamBattlePlayersDetail, stream...
import {useState, useEffect} from "react" import {BrowserRouter,Route,Link} from "react-router-dom" // reactstrap components import { Button, Card, CardHeader, CardBody, CardFooter, CardText, FormGroup, Form, Input, Row, Col, } from "reactstrap"; function Editar(props) { console.log(props) us...
function init2D(values, width, height) { let matrix = []; if(values == null) { // If no values are provided, create an identity matrix (if rectangular), else just an empty matrix for(let i=0; i<width; i++) { let column = Array(height); column.fill(0); if(width...
/** * @noflow */ import Upload from './Upload' jest.mock('@rails/activestorage', () => { return { DirectUpload: jest.fn(file => ({ id: 'id', file, create(cb) { cb(null, { signed_id: 'signedId', key: 'key' }) }, })), } }) const file = new File([], 'file') const options = ...
const { Minimatch } = require('minimatch') const sm = require('sitemap') const isHTTPS = require('is-https') const unionBy = require('lodash.unionby') const path = require('path') const fs = require('fs-extra') const AsyncCache = require('async-cache') const consola = require('consola') const { promisify } = require('u...
'use strict'; var defaults = require('../core/core.defaults'); var Element = require('../core/core.element'); defaults._set('global', { elements: { rectangle: { backgroundColor: defaults.global.defaultColor, borderColor: defaults.global.defaultColor, borderSkipped: 'bottom', borderWidth: 0 ...
/** * Copyright 2015 IBM Corp. 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 b...
'use strict'; // array to store all product instances Product.allProducts = []; //creat a var to hold the vote events var events = 0; //get the ul to display the results statements var ulEl = document.getElementById('results'); //arrays to store product names and votes var productNames = []; var productVotes = []; ...
const config = require('../config.json') const trello = require('../modules/trello.js') const Discord = require('discord.js') const boards = ['desktop', 'ios', 'linux', 'android', 'store', 'web', 'overlay'] module.exports.run = async (client, message, args) => { if (!message.guild.me.hasPermission('EMBED_LINKS')) { ...
const _ = require(`lodash`) const { getOptions } = require(`loader-utils`) const grayMatter = require(`gray-matter`) const unified = require(`unified`) const babel = require(`@babel/core`) const { createRequireFromPath, slash } = require(`gatsby-core-utils`) const { interopDefault } = require(`../utils/interop-default`...
/* title: RGB to HSL and RGB to HSV Color Model Conversion Algorithms in JavaScript author: <NAME> published: 2008-02-10 16:01 updated: 2009-01-03 00:52 tags: [color, javascript] --- Here is a set of additive color model conversion algorithms that I found published on [Wikipedia][wp] and have implemented in JavaScript...
// Global jQuery references var $commentCount = null; var config = { "options": { "dataSource": { "url": "1n14ZaURHoFteL7CqtKbz_FlfeGa_XFftwpz0PTscIQ0", "type": "google" } }, "dataDestination": "https://docs.google.com/forms/d/1jPGH-2dhcOzXLbiEpdAuNkz13SM4RWtxkbxkw5_g...
// // https://p5js.org/examples/simulate-soft-body.html let bods = []; const smallnum = 0.5; const nodes = 7; const alph = 120; let rmax; let filled = 1; function setup() { createCanvas(600, 400); // rmax = sqrt(width * height / PI); rmax = height; const specs = make_specs(); specs.forEach((spec) => bods.pu...
'use strict'; const path = require('path'); const Crypto = require('crypto'); const { tmpdir } = require('os'); const ffmpeg = require('fluent-ffmpeg'); const webp = require('node-webpmux'); const fs = require('fs').promises; const sharp = require('sharp'); const has = (o, k) => Object.prototype.hasOwnProperty.call(o...
"use strict"; var __importDefault = (this && this.__importDefault) || function (mod) { return (mod && mod.__esModule) ? mod : { "default": mod }; }; Object.defineProperty(exports, "__esModule", { value: true }); const stream_1 = require("stream"); const raw_body_1 = __importDefault(require("raw-body")); const conte...
'use strict'; var _ = require('underscore'), $ = require('jquery'), ko = require('knockout'), CustomTooltip = require('%PathToCoreWebclientModule%/js/CustomTooltip.js'), ModulesManager = require('%PathToCoreWebclientModule%/js/ModulesManager.js'), Screens = require('%PathToCoreWebclientModule%/js/Screens.js'),...
'use strict'; const beautify = require('js-beautify').js_beautify; /** * A basic JSON editor for any object * * @memberof HashBrown.Client.Views.Editors */ class JSONEditor extends Crisp.View { constructor(params) { super(params); this.$error = _.div({class: 'editor__footer__error'}, ...
/** @jsx jsx */ import { jsx, Box, Container, Heading, Text, Image } from 'theme-ui'; import Tabs, { TabPane } from 'rc-tabs'; import { RiCheckboxCircleFill } from 'react-icons/ri'; import { rgba } from 'polished'; import { LearnMore } from 'components/link'; import tabImage1 from 'assets/images/tab-illustration-1.png'...
'use strict'; /** @namespace DevKit */ var DevKit; (function (DevKit) { 'use strict'; DevKit.PostRoleApi = function (e) { var EMPTY_STRING = ''; var f = '@OData.Community.Display.V1.FormattedValue'; function webApiField(entity, logicalName, schemaName, entityLogicalCollectionName, entityLogicalName, read...
/** * This is a function which returns an instance of * [request-promise](https://www.npmjs.com/package/request-promise) initialized with * defaults often used in connector development. * * ```js * // Showing defaults * req = requestFactory({ * cheerio: false, * jar: true, * json: true * }) * ``` * ...
'use strict'; const assert = require('assert'); const AllocateMessageQueueAveragely = require('../../../lib/consumer/rebalance/allocate_message_queue_averagely'); describe('test/allocate_message_queue_averagely.test.js', function() { const allocator = new AllocateMessageQueueAveragely(); it('should allocate queue...
/** * Copyright 2019 Penn State University * @license Apache-2.0, see License.md for full text. */ import { LitElement, html, css } from "lit"; import { RichTextEditorButtonBehaviors } from "./rich-text-editor-button.js"; import "@lrnwebcomponents/simple-picker/simple-picker.js"; /** * RichTextEditorPickerBehavior...
// NormalPass will generate normal and depth data. // TODO Animation import Texture2D from 'claygl/src/Texture2D'; import Texture from 'claygl/src/Texture'; import Shader from 'claygl/src/Shader'; import FrameBuffer from 'claygl/src/FrameBuffer'; import Material from 'claygl/src/Material'; import Pass from 'claygl/src/...
$('.catalogo-1').slick({ centerMode: true, centerPadding: '60px', slidesToShow: 3, responsive: [ { breakpoint: 768, settings: { arrows: false, centerMode: true, centerPadding: '40px', slidesToShow: 1 } }, { breakpo...
/** * Copyright 2018 The Pennsylvania State University * @license Apache-2.0, see License.md for full text. */ import { LitElement, html, css } from "lit-element/lit-element.js"; import { cellBehaviors, editableTableCellStyles, } from "./editable-table-behaviors.js"; import { A11yMenuButton } from "@lrnwebcompon...
import Metadata from "../metadata/Metadata"; import WebAPI from "../webapi/WebAPI"; const read = superclass => class extends superclass { static get queryElements() { return ["attribute", "filters", "select", "expand", "orders", "maxpagesize", "top", "count"]; } static async get(logicalName = this...
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.ChartLabel = exports.ChartLabelPlacement = exports.ChartLabelDirection = void 0; var _propTypes = _interopRequireDefault(require("prop-types")); var React = _interopRequireWildcard(require("react")); var _hoistNonReactStatics = _...
/** * Created by Maurizio on 14/01/2017. */ $(function () { var WORKING = false; $("form#chat").submit(inviaMessaggioChat); setInterval(function () { console.log("WORKING: " + WORKING); if (!WORKING) { console.log("Start working"); WORKING = true; $.whe...
const {textSync} = require('figlet'), {red} = require('colors'), pr_ms = require('parse-ms') const verif = require('./verif'); module.exports = { wait: function wait(ms) { const start = new Date().getTime(); let end = start; while (end < start + ms) { end = new Date()...
/** * Copyright 2015, GeoSolutions Sas. * All rights reserved. * * This source code is licensed under the BSD-style license found in the * LICENSE file in the root directory of this source tree. */ const ol = require('openlayers'); const popUp = require('./OlPopUp')(); const assign = require('object-assign'); class O...
/*eslint-disable*/ import React, { Component, Fragment } from 'react'; import { connect } from 'dva'; import router from 'umi/router'; import {resMessage,transPingTreeToChildren,recursionTopToObj} from '@/utils/utils' import {Divider, Popconfirm, message, Form, Card, Row, Col, Button, Input, Tag, Table, Tree} from 'ant...
const _ = require('lodash'); const moment = require('moment'); const socket = require('socket.io-client')('http://localhost:3001/'); const Class = require('../models/Class'); const User = require('../models/Users'); const ClassRequest = require('../models/ClassRequest'); const RejectedRequest = require('../models/Rejec...
// This javascript executes on any page that matches the content_scripts.matches const hideOptions = [ { description: "5 sec", duration: 1000 * 5 }, { description: "15 sec", duration: 1000 * 15 }, { description: "30 sec", duration: 1000 * 30 }, ...
var express = require("express"); var bodyParser = require("body-parser"); var logger = require("morgan"); var mongoose = require("mongoose"); var exphbs = require("express-handlebars"); var favicon = require('serve-favicon'); // Connect to the Mongo DB var MONGODB_URI = process.env.MONGODB_URI || "mongodb://localhost...
/* Copyright (C) 2014-2016 <NAME> This library is published under the MIT License and is part of the Encapsule Project System in Cloud (SiC) open service architecture. Please follow https://twitter.com/Encapsule for news and updates about jsgraph and other time saving libraries that do amazing things with ...
const express = require('express'); const needle = require('needle'); const boolean = require('boolean'); const http = require('http'); const path = require('path'); const E = process.env; const PORT = parseInt(E['PORT']||'8001', 10); const ADDRESS = E['ADDRESS']||'192.168.1.7:'+PORT; const ASSETS = path.join(__dirn...
'use strict'; const TelegramBot = require('node-telegram-bot-api'); class Player { constructor(id, name) { this.id = id; this.name = name; } } class Game { construsctor(numPlayers, player1, player2, word, guess) { this.numPlayers = numPlayers; this.player1 = player1; this.player2 = player2;...
'use strict'; var ObjUtils = require('./../../../utilities/object'); var Component = require('./../component/component'); var DataStore = require('./../data-store/data-store'); var PathingHelpers = require('./../../../../shared/builder/lib/storage-helpers/pathing'); var SLASH = '/'; function Deployer() { this.o...
const iconUnicodes = { add: "\\e940", admin: "\\e94f", alert: "\\e90b", analysis: "\\e912", arrow_down: "\\e901", arrow_left_small: "\\e963", arrow_left: "\\e902", arrow_left_boxed: "\\e988", arrow_right_small: "\\e962", arrow_right: "\\e904", arrow_up: "\\e907", arrow: "\\e904", attach: "\\e9...