text
stringlengths
3.07k
16k
import Vue from "vue" import { toDate, isEqual, isBefore, isAfter, sub } from "date-fns" import stringToHash from "../services/stringToHash" export const state = () => ({ eligibilityCriteria: {}, hashToCriteria: {}, preloadedResponses: {} }) export const mutations = { // payload must include a criteriaKey and...
/*=== edditor presets ===*/ // Define Presets const presets = { "default": { "color_background": "#ffffff", "color_text": "#191a23", "color_submenu": "#3d3d3d", "color_submenu_text": "#ffffff", "color_link": "#3d3d3d", "color_button": "#3d3d3d", "color_button_text": "#ffffff", "color...
import Lab from "lab" import {expect} from "code" import server from "../src/index.js" import _ from "lodash" import URL from 'url' import jwt from 'jsonwebtoken' import querystring from 'querystring' import sinon from 'sinon' import {loginAs, randomEmail} from "./test_common" export const lab = Lab.script() const ...
import PropTypes from 'prop-types'; import React from 'react'; import Link from 'react-router/lib/Link'; import IconButton from '@material-ui/core/IconButton'; import { injectIntl } from 'react-intl'; import ArrowDropDownIcon from '@material-ui/icons/ArrowDropDown'; import ArrowDropUpIcon from '@material-ui/icons/Arrow...
import React, { PureComponent } from 'react'; import PropTypes from 'prop-types'; import { Color, StdinContext } from 'ink'; import chalk from 'chalk'; const ARROW_UP = '\u001B[A'; const ARROW_DOWN = '\u001B[B'; const ARROW_LEFT = '\u001B[D'; const ARROW_RIGHT = '\u001B[C'; const ENTER = '\r'; const CTRL_C = '\x03'; c...
var keystone = require('keystone'); var i18next = require('i18next'); var _ = require('lodash'); var Types = keystone.Field.Types; var helpers = require('../lib/bkjs/helpers'); var settings = keystone.get('settings'); var has_history = ('Blog' in settings.revisions) ? true : false; var add_media = '<a class="btn btn-c...
const RESPONSES = { DEFAULT: "Well... I got confused and I forgot what we were doing. How about we start from the top?", NOT_AUTHORIZED: "Hmmmm... yeah you can't do that buddy!", NOT_AN_OPTION: "Yeah.. That\'s not an option. I am sorry.", ITEM_EMPTY: "I missed the item in your message un...
/* * Copyright 2018 Nextworks s.r.l. * * 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 w...
import React, { useRef, useEffect, useState, useContext } from 'react'; import { makeStyles } from '@material-ui/core/styles'; import Box from '@material-ui/core/Box'; import Divider from '@material-ui/core/Divider'; import Typography from '@material-ui/core/Typography'; import List from '@material-ui/core/List'; impor...
import React, { Component } from "react"; import PropTypes from "prop-types"; import Erc20 from "./Erc20"; import Erc721 from "./Erc721"; import { ListErc20, ListErc721, colours } from "../../Static"; import { ErcCalls, Erc20Contract, Erc721Contract } from "../../ContractCalls"; class TokenInfo extends Component { ...
import React from 'react' import './Discovery.css' import { List, Carousel, Card, Button, Tooltip, Modal, Input, message, Alert } from 'antd' import { SmileOutlined, HighlightOutlined, UserOutlined } from '@ant-design/icons'; import { recommendation, pal_recommendation } from '../../data'; import Avatar from 'antd/lib...
// Copyright 2016 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. var AutomationEvent = chrome.automation.AutomationEvent; var AutomationNode = chrome.automation.AutomationNode; var EventType = chrome.automation.EventTyp...
import React from 'react'; import PropTypes from 'prop-types'; import AMapContext from '../AMapContext'; import breakIfNotChildOfAMap from '../utils/breakIfNotChildOfAMap'; import isShallowEqual from '../utils/isShallowEqual'; import createEventCallback from '../utils/createEventCallback'; /** * PathNavigator binding...
import React, { Component } from "react"; import PropTypes from "prop-types"; import Helmet from "react-helmet"; import { StaticQuery, graphql, withPrefix } from "gatsby"; import linkwebLogo from "../images/linkweb-black.png"; function SEO({ description, lang, meta, keywords, title, url, article, date, slug, modified...
import React from "react" import PropTypes from "prop-types" import { graphql } from "gatsby" import { v4 } from "uuid" import Layout from "../components/Layout" import Image from "../components/elements/Image" import Row from "../components/Row" import MarkdownContent from "../components/MarkdownContent" import Signup...
import React, { Component } from 'react'; import { ButtonGroup, Container, Form, FormGroup, Label, Input, FormText, Col, Row, CardFooter, ListGroup, ListGroupItem, CardHeader,Card,CardTitle, CardText,TabContent,TabPane, CardBody, Button, Nav, NavItem, NavLink } from 'reactstrap'; import { connect } from 'react-redux'; ...
// # skyline.js "use strict"; const bsearch = require('binary-search-bounds'); const LotIndex = require('./lot-index.js'); const { FileType } = require('./enums.js'); const { hex } = require('./util.js'); const LotConfigPropertySize = 0x88edc790; const OccupantSize = 0x27812810; const OccupantGroups = 0xaa1dd396; // #...
'use strict'; var Fs = require('fs'); var Lodash = require('lodash'); var Path = require('path'); var BuildHelpers = require('./../build-helpers'); var EsprimaHelpers = require('./../esprima-helpers'); var NEWLINE = '\n'; var NEWLINE_REGEXP = /\n/g; var TAB = ' '; // 4 spaces! function indent(str) { return (...
import React, { useEffect, useState } from "react"; import "./App.css"; import { ethers } from "ethers"; //ethers is a library that helps our frontend talk to our contract import abi from "./utils/MathPortal.json"; import BeatLoader from "react-spinners/BeatLoader"; import { css, jsx } from '@emotion/react' var rando...
import React, { useState, useEffect, useContext } from "react"; import { Tabs, Button } from "antd"; import SecondPane from "./SecondPane"; import MinutePane from "./MinutePane"; import HourPane from "./HourPane"; import DayPane from "./DayPane"; import MonthPane from "./MonthPane"; import WeekPane from "./WeekPane"; i...
var config = { apiKey: "AIzaSyAYxVpEPJeu18b9yU2SsDiUexAgU5_NM7c", authDomain: "prueb-eb7a8.firebaseapp.com", databaseURL: "https://prueb-eb7a8.firebaseio.com", projectId: "prueb-eb7a8", storageBucket: "prueb-eb7a8.appspot.com", messagingSenderId: "487645823863" }; firebase.initializeApp(config);...
var editor_ob; $(document).ready(function () { SetCssParamsTopBar() $(document).on('mouseover', '.view table', function () { $(this).closest('.box-element').find('.configuration').show(); }); // $(document).on('mouseover', // ' .i_background_color, ' + // ...
// // Normalisation is an attempt to make dimension count // import * as VismaAPIClient from '../lib/api-client/visma' import * as FileClient from '../lib/api-client/files' import * as JSONConnector from '../lib/http/json' import debug from '../lib/debug' const populationQuery = { tableName: 'befolkning_hovedgruppe...
/** * processedConcepts - keeps track of processed concepts, i.e. the terms that * have been added to the map * unProcessedConcepts - keeps track of unprocessed * concepts. This is required due to the cyclic nature of the UMLS * metathesaurus. For example, term Malaria can be related to itself using any * relati...
import { Meteor } from 'meteor/meteor'; import SimpleSchema from 'simpl-schema'; import { check } from 'meteor/check'; import { _ } from 'meteor/underscore'; import BaseCollection from '../base/BaseCollection'; import { ROLE } from '../role/Role'; import { expirationStates } from '../inventory/InventoryCollection'; ex...
let liste=document.querySelector("#listemembre") let notification=document.querySelector("#listnotif") let participant=document.querySelector("#participant") let titre=document.querySelector("#titre") let date=document.querySelector("#date") let creer=document.querySelector("#creer") var tab=[] fetch("http://localhost...
const input = require('./input') // ------------------------------------- // PART 1 // ------------------------------------- const findGridSize = n => { let answer = null let size = 1 while (!answer) { const grid = size ** 2 if (grid >= n) { answer = size } size += 2 } return answer } ...
'use strict'; const metaGetFeeToPayFromFeeData = require( '../../../../../database/metadata/metaGetFeeToPayFromFeeData' ); const stringify = require( '../../../../../stringify' ); const searchDatabase = require( '../../../../dino/searchDatabase' ); const { aws: { database: { tableNames: { WITHDRAWS } } ...
// Modules // DOM Node let message = document.getElementById('message'), themeSwitch = document.getElementById('slider'), changeFolder = document.getElementById('changeFolder'), folderField = document.getElementById('folderField'), modal = document.getElementById('myModal'), modalContent = document.getElementById...
import React, { Component } from 'react' import * as THREE from 'three' import MeshLine from 'three.meshline' import smokeFile from '../../static/smoke.png' class Scene extends Component { constructor(props) { super(props) this.start = this.start.bind(this) this.stop = this.stop.bind(this) this.anim...
// add current date to top of pageS var m = document.querySelector("#currentDate"); m.textContent = moment().format('dddd[,] MMMM Do YYYY'); //clear local storage function clearDay() { localStorage.clear(); location.reload(); } // color code the past,present,and future times var now= new Date().getHours(...
import React , {Component} from "react"; import { Link } from "react-router-dom"; import { withRouter } from "react-router-dom"; import axios from 'axios'; import https from 'https'; class Login extends Component { constructor(props) { super(props); var admin = sessionStorage.getItem("admin")...
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.PersistedGraphQL = void 0; var _crypto = _interopRequireDefault(require("crypto")); var _fs = _interopRequireDefault(require("fs")); var _graphqlTools = require("graphql-tools"); var _language = require("graphql/language"); var...
var Supercharge = (function () { function Supercharge(tag, body) { var _this = this; if (body === void 0) { body = undefined; } var node; this.element = document.createElement(tag); if (typeof body == "string") { node = document.createTextNode(body); t...
var topups = []; $(document).ready(function() { getTopUps(); }); function getTopUps() { topups = []; $("#topups").find("*").remove(); showProgress("Memuat daftar transaksi top up"); $.ajax({ type: 'GET', url: PHP_PATH+'get-pending-funds.php', dataType: 'text', cache...
'use strict'; const ResizeSensor = require("resize-sensor"); //Floatygons.js //By <NAME> @ 2019 class Floatygons{ constructor(){ let defaults = { canvasId: "#floatygonCanvas", clearColor: "#1b1b1b", dotColor: "#FFFFFF", lineColor: "#FFFFFF", maxD...
const { MessageEmbed, Message, Client } = require("discord.js"); const { readdirSync } = require("fs"); const client = require('../../index') const prefix = '.'; // this one gets the prefix let color = "#A6FE00"; // this is the color of the embed const create_mh = require(`../../functions/menu.js`); //...
import React, { createContext } from "react"; import { maxResultsEntries, maxMemoryEntries, displayedMemoryEntries, displayedResultsEntries, } from "../constants"; const Big = require('big.js'); const initialState = { displayStr: "0", operand1: null, operand2: null, lastResult: null, prevResults: []...
import $ from "jquery"; import { uploadHole } from "../index.js"; const workSheet = () => { var store = window.db .transaction(window.DB_STORE_NAME, "readwrite") .objectStore(window.DB_STORE_NAME); var req; try { req = store.getAll(); } catch (e) { if (e.name === "DataCloneError") console...
// Extend the application with diff functionality // Ace editor differ code from: https://github.com/benkeen/ace-diff /* global require, diff_match_patch */ // Stylesheet modified from: https://github.com/benkeen/ace-diff/blob/master/demos/demo2/styles.css const aceDiffStyleSheet = `#flex-container { display: fl...
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.default = void 0; var _react = _interopRequireDefault(require("react")); var _zminkAxioline = _interopRequireDefault(require("@bit/zmink.axioline.plcnext-background-module")); var _reactParticlesJs = _interopRequireDefault(requir...
import React from 'react' import {connect} from 'react-redux' import { createSelector } from 'reselect' import {bindActionCreators} from 'redux' import {Card, CardActions, CardTitle, CardText} from 'material-ui/Card'; import {List, ListItem} from 'material-ui/List'; import FlatButton from 'material-ui/FlatButton'; impo...
import * as R from 'ramda'; import * as free from 'fp/free'; import * as db from 'app/database'; import { getUserId } from './user'; import { tapLog } from './utils'; const L = { id: R.lensProp('_id'), type: R.lensProp('type'), rating: R.lensProp('rating'), comment: R.lensProp('comment'), user: R.lensProp('u...
import 'intersection-observer'; import us from '../sources/us_states.json'; import * as d3 from 'd3'; class BigMap { constructor(target, race) { this.target = target; this.race = race } render() { var self = this; var width = 800, height = 500, centered; ...
import * as validations from "./validations"; import encodeCodabar from "./Codabar"; import encodeCode128 from "./Code128"; import encodeCode39 from "./Code39"; import encodeEAN from "./EAN"; import encodeFIM from "./FIM"; import encodeITF from "./ITF"; import drawBitsBarcodeToCanvas from "./canvas"; import drawBitsB...
const Bootcamp=require('../models/Bootcamp'); const path=require('path'); const ErrorResponse = require('./../utils/errorResponse'); const asyncHandler=require('./../middlewares/asyncHandler'); const geocoder = require('../utils/geocoder'); /* ** Get bootcamps ** GET /api/v1/bootcamps ** Public */ exports.getBootcamps=...
// Web Scoket 封装类方法 export default class WebSocketClass { constructor(options) { // websocket对象 this.ws = null; this.socketStatus = null; // websocket是否关闭 // 消息队列,未成功发送的队列 this.socketMsgQueue = []; // 手动记录socket状态 -1:未连接, 0:连接中, 1:已连接 (由于socket存在假死状态不推荐使用readyState) this.connectStatus = -1; // 重连定时器 ...
const Client = require('../structures/client.js'); const HostingBotUtils = require('../utils'); const Utils = new HostingBotUtils(); /** * Account API stuff from HostingBot's API. * @extends {Client} */ class Account extends Client { constructor(args) { super(args) if (!this.args) throw new Error...
import React, { PureComponent } from 'react'; import { connect } from 'dva'; import { Anchor, Card, Divider, Icon, message } from 'antd'; import { routerRedux } from 'dva/router'; import PageHeaderWrapper from '@/components/PageHeaderWrapper'; import styles from './DocDetail.less'; const { Link } = Anchor; ...
/* eslint-disable react-hooks/exhaustive-deps */ import React, { useEffect, useState } from 'react'; import styled from 'styled-components'; import dayjs from 'dayjs'; import { Modal, Input, Button as CloseButton, Col, Row, ModalHeader, ModalBody, FormGroup, Label } from 'reactstrap'; import { toastr } from 'react-redu...
import React, {useEffect, useState} from 'react'; import coopercars1_logo from '../CooperCars-logos.jpeg'; import coopercars2_logo from '../CooperCars-logos_black.png'; import '../App.css'; import NavBar from './NavBar' import TextField from "@material-ui/core/TextField"; import Button from "@material-ui/core/Button"; ...
// The URL for the OS Data Hub APIs const dataHubApi = 'https://api.os.uk/'; // // Setup the EPSG:27700 (British National Grid) projection // proj4.defs("EPSG:27700", "+proj=tmerc +lat_0=49 +lon_0=-2 +k=0.999601 +x_0=400000 +y_0=-100000 +ellps=airy +towgs84=446.448,-125.157,542.060,0.1502,0.2470,0.8421,-20.4894 +datu...
var path = require('path'); var os = require('os'); var cheerio = require('cheerio'); var mailer = require('nodemailer'); var Litmus = require('./litmus'); var Promise = require('bluebird'); var juice = Promise.promisifyAll(require('juice')); var inliner = Promise.promisifyAl...
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.routes = void 0; var login = require('./components/auth/login.vue')["default"]; var register = require('./components/auth/register.vue')["default"]; var forgot = require('./components/auth/forgot-password.vue')["default"]; var l...
/* Copyright 2011 <NAME>, <NAME>, Queensland University of Technology 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 requi...
//----------------------------------------------------------------------------- // Copyright (c) 2015, IBM Corp. // All rights reserved. // // Distributed under the terms of the BSD Simplified License. // // The full license is in the LICENSE file, distributed with this software. // // You may not use this file except ...
//*****Business Logic //cart Object and methods function Cart() { this.pizzas = []; this.grandTotal = 0; } Cart.prototype.addPizza = function(pizza) { this.pizzas.push(pizza); }; Cart.prototype.calcCartPrice = function() { this.grandTotal = 0; this.pizzas.forEach( function(pizza){ this.grandTotal +=...
// -*- mode: js; indent-tabs-mode: nil; js-basic-offset: 4 -*- // // This file is part of Genie // // Copyright 2020 The Board of Trustees of the Leland Stanford Junior University // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. //...
console.log("[INFO] Starting MyESP WebSocket Emulation Server"); const WebSocket = require("ws"); console.log("[INFO] You can connect to ws://localhost or load URL .../src/websrc/temp/index.html"); console.log("[INFO] Password is '<PASSWORD>'"); const wss = new WebSocket.Server({ port: 80 }); wss.broadcast = fu...
'use strict'; module.exports = function(less, pluginManager, options) { // ............................................................ var tree = less.tree, MixinCall = tree.mixin.Call, mergeRules = less.visitors.ToCSSVisitor.prototype._mergeRules, rootRegistry = ...
import React from 'react' import PropTypes from 'prop-types' import { Helmet } from 'react-helmet' import { graphql } from 'gatsby' import Layout from '../components/Layout' import Content, { HTMLContent } from '../components/Content' import PreviewCompatibleImage from '../components/PreviewCompatibleImage' import Feat...
import * as React from 'react'; import ProjectItem from './project-item.component'; import {getDefaultProjectEnums} from "../enums/default-project.enum"; import {ProjectService} from "../services/project-service"; import {debounce} from "lodash"; import {LocalStorageService} from "../services/localStorage-service"; co...
"use strict"; /** * Create HTML output for unit per dimension * * output: * - "check - unit per dimension after mapping" ... list per dimension Synset of linked units */ // includes var Q = require( 'q' ), Log = require( './util/log.js' ), OntoStore = require( './util/OntoStore' ), ...
const express = require('express'); const bodyParser = require('body-parser'); const cookieParser = require('cookie-parser'); const app = express(); app.use(bodyParser.urlencoded({ extended: false })); // enables use of body-parser app.use(cookieParser()); app.use('/static', express.static('public')); // serves the st...
import React, { useState, useEffect } from 'react' import { MsgBox, ActionBar, Button, FormPanel, Panel, Subtitle, Spacer, Loading, Error, Text, Decimal, Integer, LinkIcon, ButtonLink, Subtitle2, PageviewIcon, CloudDownloadIcon, ReportViewer } from 'rsi-react-web-components' const B...
'use strict'; const ForeginDefinition = require('./ForeginDefinition'); const Sequelize = require('sequelize'); function capitalize(string) { return string.charAt(0).toUpperCase() + string.slice(1); } /** * Model Definition Adapter for JSON Schema */ class JsonSchemaDefinition extends ForeginDefinition { /** *...
var CONFIG = require('config'); var ldap = require('ldapjs'); var Promise = require('promise'); var crypto = require('crypto'); var winston = require('winston'); var fs = require('fs'); const logger = winston.loggers.get('herodote'); var redis = require('redis'); var monk = require('monk'); var db = monk(CONFIG.mongo....
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.PluginsManager = void 0; const tslib_1 = require("tslib"); const drcollector_1 = require("../drcollector"); const includes_1 = require("../includes"); const _1 = require("."); const fs = tslib_1.__importStar(require("fs-extra")); const...
import React from "react"; import { compose, withHandlers } from "recompose"; import { TextValidator } from "react-material-ui-form-validator"; import FormControl from "@material-ui/core/FormControl/FormControl"; import Typography from "@material-ui/core/Typography/Typography"; import Grid from "@material-ui/core/Grid...
import React, { Component } from 'react'; import PropTypes from 'prop-types'; import ReactDOM from 'react-dom'; import Waves from './helpers/waves'; import moment from 'moment'; function getMoment(date, locale) { let value = moment(date); value.locale(locale); return value; } export default class Calendar exten...
// render a vega-lite specification over a mapbox layer import mapboxgl from 'mapbox-gl'; import 'mapbox-gl/dist/mapbox-gl.css' import geoViewport from '@mapbox/geo-viewport'; import m from 'mithril' import * as vega from 'vega'; import * as d3 from "d3"; import vegaEmbed from "vega-embed"; import * as common from ".....
'use strict'; const fp = require('fastify-plugin'); const { default: Client } = require('@immobiliarelabs/dats'); const doc = require('@dnlup/doc'); const { hrtime2us, hrtime2ns, hrtime2ms, hrtime2s, } = require('@dnlup/hrtime-utils'); const hooks = require('./lib/hooks'); const staticMode = require('....
// Generated by BUCKLESCRIPT, PLEASE EDIT WITH CARE 'use strict'; var Jest = require("@glennsl/bs-jest/src/jest.js"); var List = require("bs-platform/lib/js/list.js"); var Block = require("bs-platform/lib/js/block.js"); var Curry = require("bs-platform/lib/js/curry.js"); var Belt_List = require("bs-platform/lib/js/bel...
import React from 'react'; import { PixelRatio, StyleSheet, Text, View, PanResponder, Animated, TouchableOpacity } from 'react-native'; const REACTIONS = [ { label: "Worried", src: require('./assets/worried.png'), bigSrc: require('./assets/worried_big.png') }, { label: "Sad", src: require('./assets/sad.png'), bigS...
window.addEventListener("load", init); window.addEventListener("scroll", adjustNav); window.addEventListener("resize", resizeNav); function init() { console.log("Hey there!"); console.log("Source code: https://git.io/xNCTU"); resizeNav(); adjustNav(); updateTime(); setInterval(updateTime, 20...
const fs = require('fs') const path = require('path') const upload = require('./upload') const config = require('./config') const qiniu = require('qiniu') // 同步遍历文件 function eachFileSync(dir, findOneFile){ const stats = fs.statSync(dir) if(stats.isDirectory()){ fs.readdirSync(dir).forEach(file => { ...
'use strict'; var async = require('async'); var drivers = require('soajs.core.drivers'); var coreModules = require ("soajs.core.modules"); var core = coreModules.core; var param = null; var regEnvironment = (process.env.SOAJS_ENV || "dev"); regEnvironment = regEnvironment.toLowerCase(); var awarenessCache = {}; var...
/** * NOTE: * This API endpoint is NOT using NextJS. It is using regular expressJS to serve the segments (see server.js for the routing). * This is because NextJS will remove support for API-endpoints with more than 4MB responses in the future. We need to send * more data than 4MB to the client since this is...
/* * Copyright 2016 <NAME> for ThrustCurve.org * Licensed under the ISC License, https://opensource.org/licenses/ISC */ 'use strict'; const express = require('express'), router = express.Router(), _ = require('underscore'), path = require('path'), xmlparser = require('express-xml-bodyparser'...
import React, {useState} from 'react'; import api from '../utils/axios' import valCep from '../utils/valCep' import Swal from 'sweetalert2/dist/sweetalert2.js' function RegLocal() { const [name, setName] = useState("") const [address, setAddress] = useState("") const [number, setNumber] = useState("") ...
export const snowflakeTextArea = document.querySelector("#snowflake"); export const nonReceptivePartTextArea = document.querySelector("#non_receptive_part"); export const receptivePartTextArea = document.querySelector("#receptive_part"); export const animateButton = document.querySelector("#animate"); export const ca...
/** * A component that allows the user to select a particular image from a museum * object's image gallery. */ /** * WordPress dependencies */ import { useState, useEffect } from '@wordpress/element'; import apiFetch from "@wordpress/api-fetch"; import { IconButton, } from '@wordpress/components' import { ge...
/* Task Description */ /* * Create an object domElement, that has the following properties and methods: * use prototypal inheritance, without function constructors * method init() that gets the domElement type * i.e. `Object.create(domElement).init('div')` * property type that is the type of the domElement * a va...
const fs = require('fs') const path = require('path') // read **kern format files from corpus // https://figshare.com/articles/dataset/iRealPro_Corpus_of_Jazz_Standards/10326725 // argument should be dir with the *.jazz files const cleanBassNote = x => x.replace('-', 'b') const convertChord = x => { const alternat...
// If this syntax looks unfamiliar, don't worry, it's just JavaScript! // Learn more about ES2015 here: https://babeljs.io/docs/learn-es2015/ // // Run "npm install" and then test with this command in your shell: // node examples/bot-conversation.js const Promise = require('bluebird'); const chalk = require('chalk'); ...
import http from 'http'; import bunyan from 'bunyan'; import bunyanDebugStream from 'bunyan-debug-stream'; import { LoggingBunyan } from '@google-cloud/logging-bunyan'; /* * convert a millisecond value into a 'Duration' object, defined as * `{ seconds, nanos }`, where `nanos` is the nanosecond component of the * ti...
import React, { useEffect, useContext, useState } from "react" import styled from "styled-components" import Aos from "aos" import "aos/dist/aos.css" import { Context } from "../Context" import MailSvg from "../assets/svgs/mail.svg" import SendSvg from "../assets/svgs/sendIcon.svg" const Email = () => { const { dark...
self.importScripts("npcdata.js","npctools.js") let biomes = [] let covers = {} let timeSpen = 0 // used to generate all possible npc groups/combinations // same as itertools.combinations from python function * combinations(k, someArray, fromThisIndex=0) { if ( k === 0) { yield [] return } for (let i=from...
/* * Tencent is pleased to support the open source community by making BK-BASE 蓝鲸基础平台 available. * Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved. * BK-BASE 蓝鲸基础平台 is licensed under the MIT License. * * License for BK-BASE 蓝鲸基础平台: * ----------------------------------------------------...
const HocrPropertyParser = require('./property-parser') /** * ### HocrDOM * */ function log(options, ...args) { if (!options.debug) return console.log('# ', new Date(), ...args) } const defaultPropertyParser = new HocrPropertyParser() class HocrDOM { /** * #### Options * * All boolean options a...
/* eslint-disable complexity */ /* eslint-disable no-case-declarations */ import axios from 'axios' // Action Types const GOT_CART = 'GOT_CART' const GOT_GUEST_CART = 'GOT_GUEST_CART' const UPDATED_CART = 'UPDATED_CART' const UPDATED_GUEST_CART = 'UPDATED_GUEST_CART' const ADD_ITEM_USER = 'ADD_ITEM_USER' const REMOVED...
var Bmob = require('../../libs/bmob.js'); var config = require('../../config'); // for background image // var imageUtil = require('../../utils/util.js'); Page({ /** * 聊天室使用到的数据,主要是消息集合以及当前输入框的文本 */ data: { inputContent: '', lastTodoId: 'none', key:"", todos: [{"content":'美好的一天开始啦~'}], ...
import React, { useState } from 'react' import { useMutation } from '@apollo/react-hooks' import { makeStyles } from '@material-ui/core/styles' import { ListItem, ListItemText, ListItemSecondaryAction, ListItemIcon, Menu, MenuItem, IconButton, Tooltip } from '@material-ui/core' import { MoreVert as MoreVertIcon, Ar...
const GameModalCss = ` #white-gm-container{ -webkit-touch-callout:none; /*系统默认菜单被禁用*/ -webkit-user-select:none; /*webkit浏览器*/ -khtml-user-select:none; /*早期浏览器*/ -moz-user-select:none;/*火狐*/ -ms-user-select:none; /*IE10*/ user-select:none; position: fixed;...
OW_CHAR_UUID = '0000cc91-0000-1000-8000-00805f9b34fb'; require("Font7x11Numeric7Seg").add(Graphics); gatt = {}; cx = g.getWidth()/2; cy = 24+(g.getHeight()-24)/2; w = (g.getWidth()-24)/2; gps_course = { spd: 0 }; var settings = require("Storage").readJSON('openwindsettings.json', 1) || {}; i = 0; hullpoly = []; for ...
// @remove-file-on-eject /** * Copyright (c) 2015-present, Facebook, Inc. * * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. */ 'use strict'; const fs = require('fs'); const chalk = require('react-dev-utils/chalk'); const paths = require('...
Function.prototype.bind = function(bind) { var self = this; return function () { var args = Array.prototype.slice.call(arguments); return self.apply(bind || null, args); }; }; /** Geometry and vectors **/ function in_boundary(pos, box) { return pos[0] >= box[0] && // x1 pos[...
import React from 'react'; import classnames from 'classnames'; import {Table, TableBody, TableFooter, TableHeader, TableHeaderColumn, TableRow, TableRowColumn} from 'material-ui/Table'; // import routeTableStyles from '../../sass/components/RouteTable.scss'; let customStyles = { propContainer: { width:...
'use strict'; var Base = require('./Base'), Product = require('./Product'), util = require('util'), Signature = require('./Signature/Pingback'), querystring = require('querystring'); Pingback.PINGBACK_TYPE_REGULAR = 0; Pingback.PINGBACK_TYPE_GOODWILL = 1; Pingback.PINGBACK_TYPE_NEGATIVE = 2; function Pingback(pa...
import React from 'react'; import PropTypes from 'prop-types'; import { connect } from 'react-redux'; import shortid from 'shortid'; import ItemSelector from '../ItemSelector'; import OrderScratchPad from '../../Presentational/OrderScratchPad'; import CheckoutModal from '../../Presentational/CheckoutModal'; im...