text stringlengths 3.07k 16k |
|---|
import { Game, PlayerView } from 'boardgame.io/core';
import { currentPlayer, getState, discard } from '../utils';
import { getTopPhase, playCardFromHand, buyCard, drawCard, createPlayer, populateCardMap, populateMoves } from './utils';
import phases from './phases';
import baseModule from './base/module';
import cor... |
import uuid from "uuid-random";
import PropTypes from "prop-types";
import { apiError } from "./errors";
import { apiInteractionStart, apiInteractionEnd } from "./status";
/**
* Turn an array of items into a hash of items indexed
* by the value of `indexBy`
*
* @export
* @param {array} l
* @param {string} [index... |
function setLang(mode) {
var langEl = $(".language");
if (mode != langEl.val()) {
langEl.val(mode);
}
if (mode == "okp") {
mode = "python";
}
if (mode == "python2" || mode == "python3") {
mode = "python"
}
var md = CodeMirror.findModeByName(mode);
if (md) {
cm.setOption("mode", md.... |
var PR = require('packrattle');
const g = module.exports.grammar = {};
g.whitespace = PR(/[ \t]+/).optional().drop();
function lexeme(p) {
return PR.seq(p, g.whitespace).map(function (match) {
return match[0][0];
});
}
g.lparen = lexeme(PR('('));
g.rparen = lexeme(PR(')'));
g.lbrack = lexeme(PR('[')... |
/******************************************************************************
*
* Copyright 2019 IBM Corporation and others.
*
* 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
*
* ... |
'use strict'
const path = require('path')
const electron = require('electron');
const model = require(path.join(__dirname, 'model.js'))
const dialog = electron.remote;
const request = require('request');
const rp = require('request-promise');
module.exports.openFile = function () {
dialog.dialog.showOpenDialog(function... |
/**
* Created by jiachenpan on 16/11/18.
*/
export function isvalidUsername(str) {
const valid_map = ['admin', 'editor', 'admin01', 'seller01', 'employee01']
return valid_map.indexOf(str.trim()) >= 0
}
/* 合法uri*/
export function validateURL(textval) {
const urlregex = /^(https?|ftp):\/\/([a-zA-Z0-9.-]+(:[a-zA-Z0... |
import React, { Component } from 'react';
import Cookie from 'js-cookie';
import {
Form,
Input,
Button,
Row,
Col,
Card,
Radio,
Avatar,
Select,
message,
Divider
} from 'antd';
import { connect } from 'dva';
import styles from './BaseView.less';
const FormItem = Form.Item;
con... |
/**
* @providesModule WeFit.Components.IntroScreen
*/
import React from 'react';
import PropTypes from 'prop-types';
import { Animated, Image, StyleSheet, Text, View } from 'react-native';
import I18n from 'react-native-i18n';
import LinearGradient from 'react-native-linear-gradient';
import { DeviceUtils, FontUtils... |
"use strict";
var earthR = 6378137.0;
function outOfChina(lat, lng) {
if ((lng < 72.004) || (lng > 137.8347)) {
return true;
}
if ((lat < 0.8293) || (lat > 55.8271)) {
return true;
}
return false;
}
function transform(x, y) {
var xy = x * y;
var absX = Math.sqrt(Math.abs(x));
var xPi = x * Math.PI;
var... |
import * as CANNON from '../../dist/cannon-es.js'
/**
* @author schteppe / https://github.com/schteppe
*/
var VoxelLandscape = function (world, nx, ny, nz, sx, sy, sz) {
this.nx = nx
this.ny = ny
this.nz = nz
this.sx = sx
this.sy = sy
this.sz = sz
this.world = world
this.map = []
this.boxified = ... |
import React, { Component, PropTypes } from 'react';
import ReactDOM from 'react-dom';
import calculateTextareaHeight from '../utils/calculate-textarea-height';
import { injectStyles, removeStyle } from '../utils/inject-style';
import unionClassNames from '../utils/union-class-names';
import { omit, has, uniqueId } fro... |
import React, { useEffect, useState } from 'react';
import "./user-profile.scss";
import Locations from "./../../../facts/locations";
import Departments from "./../../../facts/departments";
import Languages from "./../../../facts/languages";
import {
followUser,
getFollowInfo,
getInterestsList,
getUserProfileIn... |
import React from "react"
import Markdown from "react-remarkable"
import styled from "styled-components"
import Layout from "../components/Layout"
import SEO from "../components/SEO"
import { scale } from "../utils/typography"
const StyledResume = styled.div`
${scale(-1 / 8)};
`
const StyledTable = styled.table`
... |
/* eslint-disable no-undef */
const { Elements } = require('../../../../utils/Elements');
const { saveTagConfig } = require('../../../../utils/settings');
const { getImage, loadDirectory } = require('../../../../utils/userInterface');
const { loadMenuTags } = require('../left-menu/index');
function getTagData() {
co... |
import React from 'react';
import ReactDOM from 'react-dom';
import './index.css';
const SIZE = 49;
const ROW_LENGTH = 7;
const ROW_NUM = SIZE / ROW_LENGTH;
var HALL_OF_CHADS = []
function Square(props){
return (
<button className="square" onClick={props.onClick}>
{props.value}
</button>
)... |
const indicator_statuses = [ "indicator-off", "indicator-on", "indicator-error"];
function disableControls() {
document.getElementById("start-btn").disabled = true;
document.getElementById("stop-btn").disabled = true;
document.getElementById("upload-btn").disabled = true;
docu... |
import React from "react"
import { css } from '@emotion/react'
import { Link, graphql } from "gatsby"
import Image from "gatsby-image"
import parse from "html-react-parser"
import Layout from "../components/layout"
import Seo from "../components/seo"
import Header from "../components/header"
const getKeyword = () => {... |
/* jshint node: true */
'use strict';
let path = require('path');
let fs = require('fs');
let DeployPluginBase = require('ember-cli-deploy-plugin');
module.exports = {
name: 'ember-cli-deploy-redis',
createDeployPlugin(options) {
var Redis = require('./lib/redis');
var DeployPlugin = DeployPluginBase.e... |
/**
* @filename : Search.js
* @author : 김우영 (https://github.com/0x000613)
* @description : 검색 컴포넌트
*/
// Cores
import React, { useState } from 'react';
import styled from 'styled-components';
import { Link, useParams } from 'react-router-dom';
// Components
import Button from '../common/Button';
import St... |
import React from "react";
import PropTypes from 'prop-types';
import CheckCircle from '@material-ui/icons/CheckCircle';
import BettingIcon from '@material-ui/icons/Receipt';
import WaitingIcon from '@material-ui/icons/Timelapse';
import RankingIcon from '@material-ui/icons/BarChart';
import ClaimingIcon from '@materia... |
/*
#### ##### ##### #### ### # # ###### ###### ## ## ##### # # ######## ## # # #####
# # # # ### # # ##### ### ## ## ## # ## # # # # ## # ##### ### ###
### # # ##### #### # # # ###### ## ######### ##### ... |
function GetPluginSettings()
{
return {
"name": "Geocoding",
"id": "Rex_Geocoding",
"version": "0.1",
"description": "Converting between geographic coordinates and human-readable address.",
"author": "Rex.Rainbow",
"help url": "https://rexrainbow.github.io/C2RexDoc/c2rexpluginsACE/plugin_re... |
import React, { useEffect } from 'react';
import { createHeap, xco, yco } from '../../helpers/createHeap';
import { createTable, moveVertex } from '../../common/utils';
import $ from 'jquery';
import Numbers from '../../components/numbers/numbers';
import { Colors } from '../../common/constants';
var a, n, v, k;
var p... |
let displayAllListPart = 'all';
let displayStatus = document.getElementById('display-status');
const URL = 'http://localhost:3000/tasks';
function getTodosList() {
return getTodosApi()
.then(date => {
return date;
});
}
function DisplayTodos(todosArr) {
let todos = document.getEle... |
#!/usr/bin/env node
'use strict'
// Necessary libs
const express = require('express')
const parser = require('body-parser')
const msg = require('gulp-messenger')
const chalk = require('chalk')
const fs = require('fs')
const _ = require('lodash')
const cmd = require('commander')
const async = re... |
/*
* Copyright (c) Microsoft. All rights reserved. Licensed under the MIT license.
* See LICENSE in the project root for license information.
*/
// The initialize function must be run each time a new page is loaded
(function() {
Office.initialize = function(reason) {
//If you need to initialize somethin... |
import React from 'react';
import { View, StyleSheet, Text, TouchableOpacity, ScrollView, StatusBar, ActivityIndicator } from 'react-native';
import { createStaackNavigator, ThemeColors } from 'react-navigation';
import Theme from '../assets/theme'
import Icon from 'react-native-vector-icons/FontAwesome';
import getUse... |
'use strict';
require('dotenv').config()
const express = require("express");
const app = express();
const axios = require('axios')
const Sentry = require('@sentry/node');
const Tracing = require('@sentry/tracing');
const { gameMessages } = require('./constant')
Sentry.init({
dsn: process.env.SENTRY_DSN,
integrat... |
import {mkdir, readFile, writeFile} from 'fs';
import {platform} from 'os';
import {basename, dirname, join, relative, resolve} from 'path';
import * as mhl from 'minify-html-literals';
import {minify as terserMinify} from 'terser';
import umap from 'umap';
import umeta from 'umeta';
import compressed from './compres... |
/*
* Project: ZilPay-wallet
* Author: Rinat(lich666dead)
* -----
* Modified By: the developer formerly known as Rinat(lich666dead) at <<EMAIL>>
* -----
* Copyright (c) 2019 ZilPay
*/
import { API, FIELDS, DEFAULT, DEFAULT_TOKEN } from 'config'
import {
ZilliqaControl,
PromptService,
NotificationsControl
}... |
import React, {useState, useCallback, useMemo, useEffect} from 'react';
import {useHistory, useLocation} from 'react-router-dom';
import styled, {keyframes} from 'styled-components';
import LoginModal from 'components/Modal/LoginModal';
import SignupModal from 'components/Modal/SignupModal';
import useVisible from 'h... |
import React, { useState, useEffect, useRef } from 'react'
import { List as VList, AutoSizer, List } from 'react-virtualized'
import * as pdfjs from 'pdfjs-dist'
import pdfjsWorker from 'pdfjs-dist/build/pdf.worker.entry'
pdfjs.GlobalWorkerOptions.workerSrc = pdfjsWorker
import "./VirtualizedPDF.less"
import ScaleBut... |
// Import
var bcrypt = require('bcrypt');
var jwtutils = require ('../utils/jwt.utils');
var models = require('../models');
var asyncLib = require('async');
// Contantes
const Email_Regexp = /^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-... |
/* eslint-env mocha */
'use strict';
const fs = require('fs');
const path = require('path');
const tmp = require('tmp');
const prepareFs = require('./utils/fsUtils').prepareFs;
var responses = require('./utils/responses');
const RESULTS_PATH = path.resolve(__dirname, 'data', 'mock-bin.json');
const RESULTS = require(... |
#!/usr/bin/osascript
ObjC.import('stdlib')
var waitFor = function (loop, fun) {
for (; loop > 0; loop--) {
try {
if (fun()) break
} catch (err) {}
delay(1)
}
}
var findWindow = function (process, windowName) {
let condition
if (typeof windowName === 'string') {
console.log('Find window... |
/**
* A collection of javascript helper functions.
*
* Items that belong here:
* * Things that are not related to angular
* * Things that need to be globally accessable
* * Adding on to the prototype of native js things (like adding Array.foreach
* * Or things that need to run in an angular module.config (you ca... |
let mysql = require('mysql');
let express = require('express');
let session = require('express-session');
let bodyParser = require('body-parser');
let path = require('path');
let id, data, lastVisited, jobtitle, selector;
let shouldGetQuestions = true;
let total = 0;
let app = express();
app.set('view engine', 'pug'... |
/* eslint-disable prefer-const,react/jsx-indent,react/no-unused-state,comma-dangle,guard-for-in, no-param-reassign, react/destructuring-assignment, react/button-has-type, react/no-access-state-in-setstate */
/**
*author: wangxiang
*desc: treeSelect 和 模糊查询 (组织机构)
*date: 2019/11/28
*/
import React, { Component } from... |
var categoryCounter = 0;
var notesCounter = 0;
function btnDeleteNote(e){
$(e).parent().children("input").each(function(){
store.remove($(this).attr("id"));
});
$(e).parent().remove();
notesCounter -= 1;
store.set("notesCounter", notesCounter);
}
function saveInputs(){
$('#noteForm >di... |
import React from 'react';
import PropTypes from 'prop-types';
import {Layout, Icon, Affix, BackTop} from 'antd';
import DocumentTitle from 'react-document-title';
import {connect} from 'dva';
import NProgress from 'nprogress';
import jQuery from 'jquery';
import 'nprogress/nprogress.css';
import {Route, Redirect, Swit... |
import { useEffect, useState } from "react";
import FormAdd from "../../elements/formAdd";
import ModalGlobalCount from "../../elements/modal/ModalGlobalCount";
import Table from "../../elements/table/Table";
import { ConnectionsModal, ChannelsModal, ExchangesModal, QueuesModal } from "../modalDetails/";
import SeeMore... |
/*
Different possible ways of creating a spinner
$("#el").spin(); // Produces default Spinner
$("#el").spin("small"); // Produces a 'small' Spinner
$("#el").spin("large", "white"); // Produces a 'large' Spinner in white (or any valid CSS color).
$("#el").spin({ ... }); // Produces a Spinner using your custom settings.
... |
"use strict";
let Phrasex = require("../Phrasex.js");
let slotFiller = require("slot-filler");
let UserData = require("../UserData.js");
let DefaultDatabase = require("../standardphrasedb/Test.js")
//let DefaultDatabase = require("../standardphrasedb/Standard.js")
let pd = require("../BasicPhrasexDatabase.js")
let p... |
import React, { useState, useEffect } from "react"
import { Link, graphql } from "gatsby"
import { getUser } from "../services/auth"
import {
addCartProduct,
getCartProducts,
removeCartProduct,
changeCartQuantity,
} from "../services/cart"
import Layout from "../components/layout"
import SEO from "../componen... |
var DateTime = require('./DateTime')
var DateFormat = require('./DateFormat')
var DateParse = require('./DateParse')
function DateRange(date1, date2) {
if (!date1 || !date2) {
throw('two dates must be specified, date1=' + date1 + ', date2=' + date2)
}
this.start = (date1.compareTo(date2) > 0 ? date2 : date1)... |
/* eslint-disable no-console, import/no-extraneous-dependencies */
import { httpPort, httpsPort } from 'config';
import Koa from 'koa';
import koaStatic from 'koa-static';
import createRouterClass from 'generic-router';
import bodyParser from 'koa-bodyparser';
import { RestfulError } from 'az-restful-helpers';
import h... |
var index = 0;
jQuery.noConflict();
var pim = angular.module('pim', [ 'socket.io','ngRoute' ]);
pim.factory('sock', function(){
var socket = io.connect('http://192.168.1.3:3001')
// console.log(socket);
return socket;
});
pim.controller('GeneralController', ['$scope', '$interval','$http','sock' , fun... |
import _ from 'lodash';
import levenshtein from 'fast-levenshtein';
import randomString from './src/random-string';
import virtualVim from './src/virtual-vim';
import stringSplice from './src/string-splice';
import xs from 'xstream';
function generateCommand () {
return virtualVim.generateCommand();
}
function ge... |
/* eslint-disable */
// see http://vuejs-templates.github.io/webpack for documentation.
require('babel-register');
var path = require('path');
var fs = require('fs');
require('shelljs/global');
// 创建临时入口文件供打包使用
var tmpDir = path.resolve(__dirname, '../tmp');
rm('-rf', tmpDir);
mkdir(tmpDir); // 删除并重新创建临时目录
var global... |
'use strict';
const {join} = require('path');
// eslint-disable-next-line import/no-extraneous-dependencies
const {BrowserWindow, ipcMain} = require('electron');
const deepAssign = require('deep-assign');
module.exports = function (options, callback) {
if (process.env.NODESCREENSHOT_SHOW === '1') {
options.show = ... |
import biography from './biography'
import Notification from '../../src/js/sketch-common/Notification'
const sketch = (p5) => {
let canvas,
upscale,
t = 0,
portraitId = 0,
numRow = 0,
muhammad_ali_portrait = [],
rippleCenter = [false, false],
letters = [],
... |
/*global module, require, console*/
var Config = require("./config.js");
var List = require(Config.PATH_LIST);
var User = require(Config.PATH_USER);
var ServerSocket = require(Config.PATH_SOCKETIO);
var EmitEvents = require(Config.PATH_EMIT_EVENTS);
var Room = require(Config.PATH_ROOM);
var Dictionary = require(Config... |
const { Player } = require("../classes/Player.js")
const { Client } = require("../classes/Client.js")
const npmpackage = require("../package.json")
module.exports.onJoin = function(ws, req) { // fired when a player joins
playerID++
ws.client = new Client(ws, req, playerID)
ws.player = new Player(ws.client, ws.clien... |
const { encode, decode } = require("isomorphic-textencoder");
const debounce = require("just-debounce-it");
const CacheFS = require("./CacheFS.js");
const { ENOENT, ENOTEMPTY, ETIMEDOUT } = require("./errors.js");
const IdbBackend = require("./IdbBackend.js");
const Mutex = require("./Mutex.js");
const Mutex2 = requir... |
import React, { useState, useContext } from "react";
import Typography from "@material-ui/core/Typography";
import Button from "@material-ui/core/Button";
import Checkbox from "@material-ui/core/Checkbox";
import { List, ListItem, makeStyles } from "@material-ui/core";
import SvgIcon from "@material-ui/core/SvgIcon";
i... |
import React, { Component } from 'react';
import CategoryType from '../../static/CategoryType';
import TaskStatus from '../../static/TaskStatus';
import NotificationType from '../../static/NotificationType';
import axios from '../../axios-orders';
import classes from './HomeBody.module.css';
import CategoryItems from... |
/*
* 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.
*/
//NOTA: PARA LA ALTA SE USA EL FORMULARIO DE REGISTRO
//EL USUARIO HACE CLICK EN <AGREGAR> Y SE LO REENVIA A FORMULARIO_I
//POR EL M... |
import React from 'react'
import { Alert, Button, StyleSheet, Text, View, ScrollView, Image } from 'react-native'
export default class App extends React.Component {
constructor(props){
super(props)
}
render() {
return (
<View style={ styles.container }>
<View style={ styles.hea... |
import React, { Component } from "react";
import axios from "axios";
import { PLAYER_1, PLAYER_2, selectGameover } from "territories-core";
import Board from "../Board";
import Congratulations from "../Congratulations";
import { Container, Item } from "../libs/territories-ui/Grid";
import LinearProgress from "../libs/... |
/*
yLogger
AUTHOR <NAME>
https://twitter.com/FRYTG
https://github.com/FRYTG
*/
const fetch = require('node-fetch');
const os = require('os');
const stringify = require('json-stringify-safe');
var logAgent;
var errorAgent;
var yLoggerSessionOptions;
// Helpers
const helpers = {
removeNonWord: function (s... |
import Root from './root';
import { DATA_CHANGES_AFFECTING } from './shared/constants';
import common from './shared/utils.common';
const formatShorthand = (def) => {
if(def && def.lifecycle) {
const segments = ['pre', 'on', 'post'];
def.lifecycle = Object.assign({
pre: {},
... |
/* eslint-disable arrow-body-style */
import differenceInMilliseconds from 'date-fns/difference_in_milliseconds';
import * as turf from '@turf/turf';
import crossfilter from 'crossfilter2';
import {
pointToGeoJSONFeature,
getDateFromHHMMSS,
flattenArray,
featuresToGeoJSON,
} from './utils';
import VirtualClock ... |
var _main;
var _view;
var portal = require('ui/common/Portal');
var login = require('ui/common/Login');
var _menu = require('ui/common/wall/Menu');
var _pid;
var _closeWinFunc;
exports.init = function(placeObj,closeWinFunc){
_closeWinFunc = closeWinFunc;
_main = Ti.UI.createWindow({
backgroundColor:"#eee",navBarHid... |
import _ from 'lodash';
import chalk from 'chalk';
import Table from 'cli-table3';
import beautify from 'json-beautify';
import { format, formatISO } from 'date-fns';
import fs from 'fs';
import geoip from 'geoip-lite';
import { width, height } from 'window-size';
import shortHumanizeTime from './helpers';
const PUBLI... |
const _ = require(`lodash/fp`);
const path = require(`path`);
const apiV2 = require(`../api-v2`);
const api = require(`../api-v1`);
// eslint-disable-next-line no-undef
const getFilePath = (fileName) => path.resolve(__dirname, `../data`, fileName);
const isNotifiableResponse = (res) => res.body.result && res.body.noti... |
'use strict';
Object.defineProperty(exports, "__esModule", {
value: true
});
var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("va... |
const parseExtensions = require('./parse-extensions');
const parseCandidates = require('./parse-candidates');
const parseBreakpoints = require('./parse-breakpoints');
const parsePublicPath = require('./parse-public-path');
const parseAlt = require('./parse-alt');
const parseClassName = require('./parse-class-name'... |
import React from "react"
import styled from "styled-components"
import { gray, blue, Button } from "@vschool/lotus"
import { useStaticQuery, graphql } from "gatsby"
import Form from '../form'
import { FormContext } from "../formContext"
const Container = styled.section`
background-color: ${gray.lighter};
`
const... |
var PIXI = require('pixi.js');
var Config = require('../Config');
var Balloon = require('./Balloon');
var Random = require('../utils/Random');
var Movie = require('../utils/Movie');
var Alien = function() {
var self = this;
this.view = new PIXI.DisplayObjectContainer();
this.image = new PIXI.DisplayObjectContai... |
import React, { Component } from 'react';
import $ from 'jquery';
class WidgetBuilder extends Component {
constructor(props){
super(props);
this.state = {
properties: [], // kind of a misnomer, this is indeed an array of properties, but we refer to this by "name" when
// sending to the mixpanel API
... |
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.hasOwnProperty(p)) d[p] =... |
'use strict';
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.DebuggerThreadsComponent = undefined;
var _react = _interopRequireDefault(require('react'));
var _reactDom = _interopRequireDefault(require('react-dom'));
var _Icon;
function _load_Icon() {
return _Icon = require('nuclide-comm... |
const moment = require('moment');
const FastHedgedOrders = require('../orders/fast_hedged_orders');
var me;
module.exports = class CreateOrderListener {
constructor(tickers, orderExecutor, exchangeManager, logger) {
this.tickers = tickers;
this.orderExecutor = orderExecutor;
this.exchangeManager = exc... |
import React from "react";
import withStyles from "@material-ui/core/styles/withStyles";
import GridItem from "components/Grid/GridItem.jsx";
import GridContainer from "components/Grid/GridContainer.jsx";
import Card from "components/Card/Card.jsx";
import Table from "components/Table/Table.jsx";
import CardBody from "... |
/* JS1k Julia Fractal Browser
Written for the 2013 Spring JS1k Competition
Live entry: http://js1k.com/2013-spring/demo/1509
Blog post: http://www.leshylabs.com/blog/posts/2015-08-05-JS1k-Julia-Fractal_Browser_Explained.html
GitHub: https://github.com/leshylabs/js1k-Julia-Fractal-Browser
Copyright (C) ... |
/*
PrivateNetworks
*/
import React from 'react';
import ReactDOM from 'react-dom';
import autobind from 'autobind-decorator';
import Paper from 'material-ui/lib/paper';
import reactMixin from 'react-mixin';
import LinkedStateMixin from 'react-addons-linked-state-mixin';
import helpers from '../../helpers';
import Li... |
export const number = `
<svg class="number-svg" version="1.1" viewBox="0 0 13.6 21.7" xmlns="http://www.w3.org/2000/svg">
<g transform="translate(.75 .85)" fill="#dd405d" stroke-linecap="round" stroke-linejoin="round">
<path class="number-svg-segment bottomH" d="m0.65 19.55h8.7l0.65 0.65-0.65 0.... |
import React from "react";
import PropTypes from "prop-types";
import { graphql } from "gatsby";
import Layout from "../components/Layout";
import Features from "../components/Features";
import Testimonials from "../components/Testimonials";
import Pricing from "../components/Pricing";
import PreviewCompatibleImage fro... |
/**
* Name : callbackAndroidRegister
* Author : Kony
* Purpose : This function register the senderID on the google cloud.
**/
function callbackAndroidRegister()
{
KMSPROP.senderID=frmUrl.txtBoxSenderID.text;
kony.print("senid:"+KMSPROP.senderID)
var configToRegister = {senderid:KMSPROP.senderID};
kony.push.re... |
import React, {Component} from 'react'
import axios from 'axios'
class Form extends Component {
state = {
body: '',
email: '',
validEmail: false,
phone: '',
validPhone: false,
method: 'email',
focus: null,
success: null
}
handleFocus = focus => {
this.setState({ focus })
}... |
"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.definePrope... |
/*
Copyright (C) 2020, <NAME>
All rights reserved.
01/09/2021
last modified 01/09/2021
*/
const ARROW_UNICODE = String.fromCharCode(8594);
class factorialAnimation {
constructor() {
let rect;
let height = 30;
let text;
this.ani = new Animation();
this.ani.step_by_step = $("#step... |
import {timeStart, timeEnd} from "./utils.js"
function capitalizeFirstLetter(string) {
return string.charAt(0).toUpperCase() + string.slice(1)
}
// Oof, why is this not standardized?
let apiLocations = {
"/w/api.php": ["wikipedia.org", "wikimedia.org"],
"/api.php": ["fandom.com"],
"/mediawiki/api.php"... |
class Enemy{
constructor(x, y, speed) {
// Variables applied to each of our instances go here,
// we've provided one for you to get started
this.x = x;
this.y = y;
this.speed = speed;
// The image/sprite for our enemies, this uses
// a helper we've provi... |
/* webshark-filter.js
*
* Copyright (C) 2016 <NAME>
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This ... |
const path = require("path");
const fs = require("fs");
const { exec } = require("child_process");
const os = require('os');
const Vacuum = require("./miio/Vacuum");
const Dummycloud = require("./miio/Dummycloud");
const Webserver = require("./webserver/WebServer");
const MqttClient = require("./MqttClient");
const C... |
'use strict';
/**
* @ngdoc directive
* @name ui.elements:uiSankeyDiagram
*
* @description Creates a Sankey Diagram.
*
* @restrict E
* @element ANY
*
* @param {Object}
* data Node and link data
* @param {Object}
* domain svg container width,height,top,bottom,left and right data
* @par... |
const express = require('express')
const path = require('path')
const webpack = require('webpack')
const logger = require('../build/lib/logger')
const webpackConfig = require('../build/webpack.config')
const project = require('../project.config')
const compress = require('compression')
const bodyParser = require('body-... |
import Vue from 'vue'
import Router from 'vue-router'
import Home from '../views/home'
import store from '../store'
// //前台页面
// import homePage from '../views/home/homePage'
// import tech from '../views/tech/tech'
// import music from '../views/music/music'
// import sense from '../views/sense/sense'
// import sortF... |
import React, { useContext, useEffect, useState } from "react"
import PropTypes from "prop-types"
import { useTranslation } from "react-i18next"
import { Link as RouterLink } from "react-router-dom"
// chakra-ui
import { Badge, Flex, Link, Text, Image, Box, Kbd } from "@chakra-ui/react"
// routes
import { ROUTES } from... |
// Copyright 2018 ODK Central Developers
// See the NOTICE file at the top-level directory of this distribution and at
// https://github.com/getodk/central-backend/blob/master/NOTICE.
// This file is part of ODK Central. It is subject to the license terms in
// the LICENSE file found in the top-level directory of this ... |
import React from 'react';
import ReactDOM from 'react-dom';
import './page_action/index.css';
import config from './page_action/pure-password-manager/src/config';
import App from './page_action/pure-password-manager/src/App';
import Paper from 'material-ui/Paper';
import { MuiThemeProvider, createMuiTheme } from 'mat... |
"use strict";
function heatmap(url, div, count) {
return function() {
let x=d3.select(div).node().getBoundingClientRect().width;
// set the dimensions and margins of the graph
let margin = {top: 5, right: 30, bottom: 55, left: 35},
width = x - margin.left - margin.right,
... |
'use strict'; // eslint-disable-line strict
/**
* Encode a stream of data with a Reed-Solomon (k, m) systematic code
*
* Overall operation is done in 3 steps:
* 1/ Striping and buffering the stream
* 2/ Actual encoding
* 3/ Redispatch onto output streams
*
* Example: k = 3, m = 2
* ddddddddddddddddddddddddddd... |
import { Rocket, Alien } from '../sprites'
import {
MAX_BULLETS, TRAVEL_TIME_MS, WORLD_HEIGHT, PLAYER_DEATH_TINT,
ENEMY_WIN_TINT, WORLD_WIDTH, FACE_DOWN, FACE_RIGHT, FACE_LEFT,
FACE_UP, LEVEL_2_SCORE, LEVEL_3_SCORE, LEVEL_4_SCORE, GAME_TEXT_OFFSET
} from '../constants'
/***
* Main Scene where all the game logi... |
var React = require("react")
var HtmlToReact = require("html-to-react")
var HtmlToReactParser = require("html-to-react").Parser
var ReactDOMServer = require("react-dom/server")
class HtmlNode {
constructor(type, props = {}) {
this.children = []
this.type = type
this.props = props
this.level = 0
}
... |
import { Controller } from 'stimulus'
const debounce = require('lodash.debounce')
export default class extends Controller {
static targets = ['input', 'hidden', 'results']
connect() {
this.toggleDropDown(true)
this.inputTarget.setAttribute('autocomplete', 'off')
this.inputTarget.setAttribute('spellch... |
const { createRemoteFileNode } = require(`gatsby-source-filesystem`);
const get = require('lodash/get');
exports.onCreateNode = async (
{ node, actions, store, cache, createNodeId, reporter },
options
) => {
const { createNode } = actions;
const {
nodeType,
imagePath,
name = 'localImage',
auth ... |
import http from 'http';
import path, { resolve } from 'path';
import fs from 'fs';
import crypto from 'crypto';
let srvpath = process.env.npm_package_config_http;
let port = process.env.npm_package_config_port;
let watch = process.env.npm_package_config_watch;
let websocketPort = process.env.npm_package_config_websoc... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.