text
stringlengths
3.22k
29.5k
'use strict'; var assert = require('assert'); var dns = require('dns'); var net = require('net'); var util = require('util'); var EventEmitter = require('events').EventEmitter; var hexdump = require('hexdump-nodejs'); var TelnetUtil = require('./telnetutil'); var BufferList = require('./bufferlist'); var DEBUG = fal...
/* eslint-disable jsdoc/require-jsdoc */ import {$, $$} from '../external/jamilih/dist/jml-es.js'; // import _ from '../external/i18n/i18n.js'; import { Intersection, ShapeInfo } from '../external/kld-intersections/dist/index-esm.js'; import * as ImageMaps from './jqueryImageMaps.js'; // Todo: If completed for more...
// ========================================================================= // Copyright © 2017 T-Mobile USA, Inc. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apa...
"use strict"; var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || function (d, b) { for (var p in b) if (b.hasOwnPrope...
/* JSOCTA - Write Cube 2 Sauerbraten maps using JSON. by @SalatielSauer, licensed under ZLIB (https://www.zlib.net/zlib_license.html) */ const dataTypes = { mapvar: ["integer", "float", "string"], entity: [ "none?", "light", "mapmodel", "playerstart", "envmap", "particles", "sound", "spotlight", "shells", "bul...
// import React, { Component } from "react"; // import customer from "./customer.png"; // class Contact extends Component { // constructor(props) { // super(props); // this.state = { // isLoading: true, // users: [], // }; // } // render() { // return ( // <div className="q"> /...
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports["default"] = exports.ReduxToastr = void 0; var _react = _interopRequireDefault(require("react")); var _propTypes = _interopRequireDefault(require("prop-types")); var _reactRedux = require("react-redux"); var _classnames = _inter...
class Station { constructor(id, name, coordinates, previous = {}, next = {}) { this.id = id; this.name = name; this.coordinates = coordinates; this.lines = []; this.previous = previous; this.next = next; } } class SubwayLine { constructor(id, start, end, stations) { this.id = id; ...
var currentSong='',cnt=0; var socket; function load_home(){ $('.nav-stacked a[href="#home"]').tab('show'); return false; } function hack(){ $('.next1').click(); $('.prev1').click(); $('.next2').click(); $('.prev2').click(); $('.next3').click(); $('.prev3').click(); } $(document...
import _data from './_data'; import _onSocket from './_onSocket'; /** * socket 发送用到的一个函数 */ function stringSource(s) { let i = 0; return () => { return i < s.length ? s.charCodeAt(i++) : null; }; } let params = { timeout: 18000, timeout2: 22000, timeoutObj: null, serverTimeoutObj: null, lockReconnect : ...
var fs = require('fs'); var path = require('path'); var moment = require('moment'); var winston = require('winston'); var childProcess = require('child_process'); var common = require('../../../core/lib/common'); var misc = require('../../../core/lib/misc'); var connection = require('../../../core/lib/connection'); ...
import React,{useEffect, useState,useRef,} from 'react'; import {Link,useHistory} from 'react-router-dom'; import NavBar from '../Navbar/Navbar'; import {Button,makeStyles,Grid,Box,Paper, Typography, FormControl,InputLabel,Input,FormControlLabel, TextField,IconButton,Divider} from '@material-ui/core'; import Ale...
'use strict' const _ = require('lodash'); const env = process.env.NODE_ENV || "development" const config = require('../config/config.js')[env] const Sequelize = require('sequelize') const sequelize = new Sequelize( config.url, config ) const syllabusesCtrl = require('../controllers/syllabuses') const assignmentsCtrl =...
// Copyright (c) Jupyter Development Team. // Distributed under the terms of the Modified BSD License. import { ILabShell, ILayoutRestorer } from '@jupyterlab/application'; import { CommandToolbarButton, ICommandPalette, MainAreaWidget, WidgetTracker, ReactWidget } from '@jupyterlab/apputils'; import { ILoggerRegistry,...
import { app, ipcMain, BrowserView } from 'electron'; import { TAB_EVENTS, WINDOW_EVENTS } from 'constants/event-names'; import PermissionDialog from 'main/dialogs/PermissionDialog'; import TabPreviewDialog from 'main/dialogs/TabPreviewDialog'; import { VIEW_SOURCE, VALIANT } from 'constants/protocol'; import { DIALOG...
'use strict'; Object.defineProperty(exports, "__esModule", { value: true }); const Express = require("express"); const companionApp_1 = require("./base/companionApp"); const targetParser_1 = require("./base/targetParser"); const blockPosParser_1 = require("./base/blockPosParser"); const optionalParser_1 = require("./ba...
var seriesChart1, seriesChart2, seriesChart3, demoChart1, demoChart2; var colorNo = "#00FF00"; var colorYes = "#FF00FF"; var randomID = "5"; var underVal = 5; var est1 = 4; var est2 = 4; var isActiveState = false; var demonstration = false; var flag = true; var sendTimeout, isActiveSend; function sendGet(url, callback...
export function create () { /** * 初始一个矩阵,开始时,a, d 为 1,其它为 0 * a c e * b d f * 0 0 1 * * a 水平缩放绘图 * b 水平倾斜绘图 * c 垂直倾斜绘图 * d 垂直缩放绘图 * e 水平移动绘图 * f 垂直移动绘图 * * 1 0 0 * 0 1 0 * 0 0 1 * * */ let m = [] m[0] = 1 m[1] = 0 m[2] = 0 m[3] = 1 m[4] = ...
/* eslint-disable no-param-reassign */ /* eslint-disable no-unused-vars */ /** * @author <NAME> * @description Vuex store for the catalogues module */ import Vue from 'vue'; import Vuex from 'vuex'; Vue.use(Vuex); // Module Constants /** * @description The Default amount of Catalogues per page. * @type {number} ...
import _defer from 'lodash/defer'; let _forEach = require('lodash/forEach'); let JSZip = require('jszip'); let FileSaver = require('file-saver'); let xmlDownloadMessage = { notDownloading : 'Download XML', downloading : 'Generating XML' }; class JobsPage { constructor ( $http, ...
import PropTypes from 'prop-types' import React from 'react' class Addressfield extends React.Component { static contextTypes = { form: PropTypes.object } static propTypes = { autocomplete: PropTypes.any, geocoder: PropTypes.any, code: PropTypes.string, htmlFor: PropTypes.string, name: ...
'use strict'; console.log('proof of life'); var totalScore = 0; var userName = prompt('Howdy! What is your name?'); // console.log('It is a pleasure to meet you ' + userName + '!'); alert('It is a pleasure to meet you ' + userName + '!'); // var = var.toLowerCase(); alert('Thanks for visiting my page. Let\'s play a ...
console.log(localStorage.getItem('user')); let configGet = { headers: { 'Content-Type': 'application/json', 'Access-Control-Allow-Origin': 'http://localhost:63342' }, responseType: 'json' }; // populates the Screening Time and Date based off the movie selected const searchTimes = () => { let movieTitle = ...
/* Copyright (C) 2016 NooBaa */ import template from './buckets-table.html'; import resourcesColTooltip from './resources-col-tooltip.html'; import ConnectableViewModel from 'components/connectable'; import ko from 'knockout'; import numeral from 'numeral'; import moment from 'moment'; import { realizeUri } from 'util...
import junit from 'junit-report-builder' import WDIOReporter from '@wdio/reporter' import { limit } from './utils' /** * Reporter that converts test results from a single instance/runner into an XML JUnit report. This class * uses junit-report-builder (https://github.com/davidparsson/junit-report-builder) to build r...
/** * @file ext-storage.js * * This extension allows automatic saving of the SVG canvas contents upon * page unload (which can later be automatically retrieved upon future * editor loads). * * The functionality was originally part of the SVG Editor, but moved to a * separate extension to make the setting be...
const notRecord = notFramework.notRecord, notAPI = notFramework.notAPI, notCommon = notFramework.notCommon; let testItem = { name: 'Title', value: 'wicked sick', _id: 'sdfoqw834u5v2909-59nv237', data: { path: { to: [0, 1, 2, 3, 4, { key: 'bingo' }] } }, getLocalData: function () { c...
function globalObject() { try { return global.global } catch (x) {} try { return window.window } catch (x) {} return null; } var arraySlice = Array.prototype.slice, hasOwn = Object.prototype.hasOwnProperty, staticName = /^__static_/, Global = globalObject(); function toObject(val) { if (...
import React, { useState } from "react"; import PropTypes from "prop-types"; import { makeStyles } from "@material-ui/core/styles"; import { useSpring, animated } from "react-spring/web.cjs"; // web.cjs is required for IE 11 support import { Button } from "@material-ui/core"; import Grid from "@material-ui/core/Grid"; ...
import _orderBy from "lodash/orderBy"; import _flatten from "lodash/flatten"; import _assign from "lodash/assign"; function _toConsumableArray(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } else { return Array.from(arr); } } import ...
import React, { useMemo, useState } from 'react'; import classNames from 'classnames'; import styles from './ProfileView.module.scss'; import Camera from '../../assets/svgIcons/Camera'; import KeyValuePair from '../KeyValuePair/KeyValuePair'; import SingleValue from '../KeyValuePair/SingleValue'; import { Layout } from...
const BLOCK_SIZE = 10; var Direction = { LEFT: 0, RIGHT: 1, UP: 2, DOWN: 3 } function Point(x, y) { this.x = x; this.y = y; } function Controls(canvas) { const SIZE = 50; const GAP = 5; var left, right, up, down; var listener = null; this.updateLocation = function() { left = new Point(c...
/** * Pokémon-related utilities. */ var matchups = { // attacking -> defending types normal: { normal: 1, fighting: 1, flying: 1, poison: 1, ground: 1, rock:.5, bug: 1, ghost: 0, steel:.5, fire: 1, water: 1, grass: 1, electric: 1, psychic: 1, ice: 1, dragon: 1, dark: 1, fairy: 1 }, fighting: { normal: ...
import React from "react"; import Stars from "./stars.js"; import UploadPhotos from "./uploadPhotos.js"; import Modal from "react-bootstrap/Modal"; import Form from "react-bootstrap/Form"; import { charScales, ratingScale } from "./constants.js"; import apiMaster from "../.././apiMaster.js"; class NewReview extends Re...
/** * @file MultipleSelect component */ import React, {Component, createRef} from 'react'; import PropTypes from 'prop-types'; import {findDOMNode} from 'react-dom'; import classNames from 'classnames'; import IconButton from '../IconButton'; import TextField from '../TextField'; import Popup from '../Popup'; impor...
// DATATABLE - GENERAL OPTIONS $(document).ready( function () { $('.dataTable').DataTable({ "ordering" : false, "language" : { "sProcessing" : "Procesando...", "sLengthMenu" : "Mostrar _MENU_ registros", "sZeroRecords" : "No se encontraron resu...
// Author: <NAME> // Script: Classification Example for Landsat8 plus spectra for classes in classified region // Version: 0.1 var area = ee.FeatureCollection('ft:1ihcmnTQF2dUYTKXOIYYwYlJzFLSpO7zsIxg0Yqd5'); var landsat8_collection = ee.ImageCollection('LANDSAT/LC8_L1T').filterDate('2016-01-01', '2016-04-19').min().cl...
'use strict'; Object.defineProperty(exports, "__esModule", { value: true }); exports.Autocomplete = undefined; var _startsWith2 = require('lodash/startsWith'); var _startsWith3 = _interopRequireDefault(_startsWith2); var _some2 = require('lodash/some'); var _some3 = _interopRequireDefault(_some2); var _pullAt2 ...
// Edit DATA //--->button > edit > start $(document).on('click', '.btn_edit', function(event) { event.preventDefault(); var tbl_row = $(this).closest('tr'); var row_id = tbl_row.attr('row_id'); tbl_row.find('.btn_save').show(); tbl_row.find('.btn_cancel').show(); //hide edit button tbl_row.find('.btn_edit')...
const { readJSON } = require('../json.js'); const { MessageEmbed, MessageActionRow, MessageButton, MessageSelectMenu } = require('discord.js'); const Data = require('../classes/data.js'); const Locale = require('../classes/locale.js'); function BaseEmbed(type, num, locale, points) { return new MessageEmbed() ...
const { html, css, update, memo } = Sifrr.Template; const delay = ms => new Promise(resolve => setTimeout(resolve, ms)); const store = { backgrounds: [ { src: './wall1.jpg', height: 500, width: 500, clockPosition: { left: 31, top: 24, height: 312, width: 31...
import React, {useState, useEffect} from 'react'; import Axios from 'axios'; import {Chart} from "react-google-charts"; import Header from '../../components/Header' import Footer from '../../components/Footer' //import './styles.css' function Monitoramento() { const [q1, setQ1] = useState(0); const [q2, s...
// General import React, { PureComponent } from 'react' import { connect } from 'react-redux' import { withStyles } from '@material-ui/core/styles' import { Set } from 'immutable' // Actions import { push } from 'connected-react-router' import { resetPage, setPageState, setNav, fetchYearEvents } from '../actions' // ...
/** * Data Type 'dateTime' * * A combination of two InputFields, date & time. * * The original inputfield is hidden between them. * * Format: 'YYYY-MM-DDTHH:mm:ssZ' in UTC * * Attribute Settings: * data-time-width-ratio (default=0.5, min=.2, max=.8) * data-store-utc (default true) keeps set/get in utc time zone forma...
// Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. // Details function ShowDocument(id, index) { $.post('/home/getdocumentbyid', { id: id }, function (data) { result = data.result; var pivotLinksHTML = ""; ...
/*Capturando os objetos*/ const statusInfo = document.getElementById('topinfo') const bandaInfo = document.getElementById('midinfo') const usoInfo = document.getElementById('usoinfo') const txTransf = document.getElementById('taxatransferencia') /*Capturando o json*/ fetch('js/everyControl/json/index_data.json') ...
const platformConfig = require('../../platforms'); const addSingleQuote = require('../../utils/addSingleQuote'); function toDash(str) { return str.replace(/\B([A-Z])/g, '-$1').toLowerCase(); } /** * make kebab-case to camel case * @param {string} str * @param {boolean} big - use big camel or small camel case */...
const fs = require("fs"); const util = require("util"); try { var config = require("./config/config.json"); } catch(e) { console.error("ERROR: The configuration file is missing. Please copy config.example.json and modify it accordingly."); } try { var Discord = require("discord.js"), clearModule = require('clear-...
// var form = document.getElementsByClassName('.editProfile'); // // form.onsubmit = function(){ // var redirect = function(){ // location.href="http://localhost/AMAPOLAs/claseGit/PROYECTO/profile.php" // } // // var usuarioModificado = function(){ // var body = document.querySelector('body') // body...
'use strict'; class MapView { constructor(entities, variable, constraints, session) { this.entities = entities; this.entityIDs = entities.map(_.property('id')); this.variable = variable; this.constraints = constraints; this.constraintString = getConstraintString(constraints)...
import Keyframes from './Keyframes'; import Point from '../Point'; import Animator from '../animation/Animator'; import throttle from 'lodash.throttle'; import { calculatePercent, getElementDimensions, getElementScroll, isArray, isHtmlElement, isSet, uniqid } from '../helpers/'; import throwError from '.....
import { Selector } from 'testcafe'; const environment = process.env.ENV.toLowerCase(); export default class DesignerPage { constructor() { //left drawer menu this.leftDrawerMenu = Selector('#root > div > div > div:nth-child(2) > div:nth-child(1) > div > div > div'); this.leftMenuList = Selector('nav'); ...
/******************************************************************************* * Copyright 2015 IBM Corp. * * 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/li...
/* MIT License Copyright (c) 2018 monya-wallet zenypota Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, me...
import formatLocale, { formatRe, pad, requote } from "./locale"; var defaultLocaleDefinition = { dateTime: '%x, %X', date: '%-m/%-d/%Y', time: '%-I:%M:%S %p', periods: ['AM', 'PM'], days: ['Sunday', 'Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday', 'Saturday'], shortDays: ['Sun', 'Mon', 'T...
import React, { Component, PropTypes } from 'react'; import { Link } from 'react-router'; import config from '../../config'; import BodyClassName from 'react-body-classname'; import {bindActionCreators} from 'redux'; import {reduxForm} from 'redux-form'; import { connect } from 'react-redux'; import {Input, Label, Tabs...
/* * Copyright 2021 Adobe. All rights reserved. * This file is licensed to you under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. You may obtain a copy * of the License at http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by appli...
const { expect } = require('chai'); const { ethers } = require('hardhat'); const { BigNumber } = require('ethers'); const { NATIVE_TOKEN_ADDRESS, registry } = require('../helpers/Constants'); const Contracts = require('../../components/Contracts').default; const MAX_LOCK_LIMIT = BigNumber.from('100000000000000000000...
import styled from 'styled-components' import progressBar from '@/assets/img/progress_bar.png' import progressBarVertical from '@/assets/img/playbar_sprite.png' import bgIcon from '@/assets/img/sprite_icon.png' import bgPanel from '@/assets/img/playpanel_bg.png' import bgList from '@/assets/img/playlist_sprite.p...
/* Copyright 2016 Balena Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distribut...
import { query as domQuery } from 'min-dom'; import { appendTo as svgAppendTo, create as svgCreate, attr as svgAttr, remove as svgRemove } from 'tiny-svg'; import { RESET_SIMULATION_EVENT, PLAY_SIMULATION_EVENT, PAUSE_SIMULATION_EVENT, ANIMATION_CREATED_EVENT, ANIMATION_SPEED_CHANGED_EVENT, SCOP...
import React, { Fragment, useContext, useEffect, useCallback, useState, } from "react"; import LikePost from "../components/post/LikePost"; import Comments from "../components/post/Comments"; import CommentForm from "../components/post/CommentForm"; import { Link } from "react-router-dom"; import Profile from...
import _forEach from 'lodash/forEach'; import Express from 'express'; import compression from 'compression'; import mongoose from 'mongoose'; import bodyParser from 'body-parser'; import session from 'express-session'; import morgan from 'morgan'; import connectMongo from 'connect-mongo'; import path from 'path'; impor...
var containers = require('./containers.js'); var NginxConfFile = require('nginx-conf').NginxConfFile; const fs = require('fs') var onlineNginxNodeContainers = []; var timeOutDel = []; module.exports = { createNewNginxNode: function(absolutePath,callback) { console.log(absolutePath); let randomPhpIp = ""...
const app = getApp(); const util = require('../../utils/util.js'); Page({ /** * 页面的初始数据 */ data: { hasEmptyGrid: false, prevhasEmptyGrid: false, nexthasEmptyGrid: false, startTime: 0, endTime: 0, checkDoneList: [//打卡做作业列表 ] }, onShow:function() { wx.hideShareMenu(); t...
var TRACKERS = [ 'ws://torrent.lunik.xyz:8000', 'udp://torrent.lunik.xyz:8000', 'http://torrent.lunik.xyz:8000/announce', 'wss://tracker.webtorrent.io', 'udp://tracker.internetwarriors.net:1337', 'udp://tracker.leechers-paradise.org:6969', 'udp://tracker.coppersurfer.tk:6969', 'udp://exodus.desync.com:6...
/// <reference path="../chrome.d.ts" /> function copy(text) { var copyFrom = document.createElement('textarea'); copyFrom.textContent = text; var body = document.getElementsByTagName('body')[0]; body.appendChild(copyFrom); copyFrom.select(); document.execCommand('copy'); body.removeChild(copyFrom); } fun...
// util.js const moment = require('moment'); const superagent = require('superagent'); const fs = require('fs'); const dp = require('../app_api/helper/data.parser.helper'); module.exports = { extend : function( target, source, flag){ for(var key in source){ if (source.hasOwnProperty(key)) { flag ?...
console.log("This is Notes JAvascript") document.getElementById('addBtn').addEventListener("click", add); showNotes(); function add(e) { let addTxt = document.getElementById('addTxt'); let addTitle = document.getElementById('addTitle'); let mySelector = document.getElementById('mySelector'); let note...
/* eslint-disable no-use-before-define */ const _ = require('lodash'), async = require('async'), col = require('../../util/colutil'), fs = require('fs'), fstate = require('../../util/fstate'), json = JSON.stringify, linedumper = require('../../util/linedumper'), makeClient = require('../../util/makeClient...
const { ipcMain } = require('electron'); const { requireArgParams } = require('../infrastructure/handler-helper'); const path = require('path'); const NodeGit = require('nodegit'); const uuid = require('uuid'); var Repo; var window = null; var refreshInterval; var fileRefreshSubscriptions = {}; ipcMain.on('Repo-Open',...
let authorized = false; window.addEventListener('load', () => { const saveNewUsername = document.getElementById('saveNewUsername'); const saveNewEmail = document.getElementById('saveNewEmail'); const saveNewPassword = document.getElementById('saveNewPassword'); const deleteAccount = document.getElement...
import React from "react" import { Helmet } from 'react-helmet' import _ from 'lodash' import { graphql, Link } from "gatsby" import { parseISO, formatRelative } from 'date-fns' import Embed from 'react-embed'; import {getCLS, getFID, getLCP} from 'web-vitals'; import { Parser, ProcessNodeDefinitions } from "html-to-r...
function CMain(oData){ var _bUpdate; var _iCurResource = 0; var RESOURCE_TO_LOAD = 0; var _iState = STATE_LOADING; var _oData; var _oPreloader; var _oMenu; var _oHelp; var _oGame; this.initContainer = function(){ var canvas = document.getElementById("canvas"); ...
'use strict'; Object.defineProperty(exports, "__esModule", { value: true }); var _extends2 = require('babel-runtime/helpers/extends'); var _extends3 = _interopRequireDefault(_extends2); var _objectWithoutProperties2 = require('babel-runtime/helpers/objectWithoutProperties'); var _objectWithoutProperties3 = _inte...
import React, { Component } from "react"; import { Link, graphql } from "gatsby"; import Swiper from "swiper"; import "swiper/dist/css/swiper.min.css"; import Meta from "../components/Meta"; import Footer from "../components/Footer"; import * as app_config from "../constants/app"; // import SectionItem from "../compone...
// var generate = function() { // var opts = {}; // var markovModels = { markov: "markov", // cento: "cento", // overlap: "1-char overlap" // }; // opts.inputString = "input string"; // opts.model = markovModels.markov; // ...
import { isNil } from "@compas/stdlib"; import { AnyOfType } from "../../builders/AnyOfType.js"; import { AnyType } from "../../builders/AnyType.js"; import { ArrayType } from "../../builders/ArrayType.js"; import { BooleanType } from "../../builders/BooleanType.js"; import { ObjectType } from "../../builders/ObjectTyp...
console.log("D3 running"); var mars_yards_link = "https://gist.githubusercontent.com/gagejustins/0b16eccb13fdcc59465fe8ae35a6da53/raw/5267bbc6ceb95df07018f450110806af7f4906be/mars_yards.csv" const width = 950, height = 600, padding = 20; Y_OFFSET = 100; X_OFFSET = 150; var dataset; //Colors dictionary const colors_...
import cw from './common.js'; const keyboardButtonCheck = (e) => { const target = e.target; if (target.value != "") { if (target.value === "del") { ClickOnDel(); } else { ClickOn(target.value); } } } const ClickOn = (key) => { let Enter_Call = new Array(...
/*************************************************************** **************************************************************** ************************** 监控虚拟树 ************************* **************************************************************** ********************************************...
/*jslint indent: 4, maxstatements: 27, unused: false */ /*global d3 */ //= require d3.chart.bubble-matrix 'use strict'; var margin = {top: 10, right: 100, bottom: 100, left: 100}; function percentile(array, n) { array.sort(function(a, b) { return a - b; }); return array[parseInt(0.01 * n * arra...
const geofire = require("geofire-common"); const admin = require("firebase-admin"); const js2rdf = require("./tool/json_to_rdf") const js2xml = require("./tool/json_to_xml") // Connexion à la base de donnée admin.initializeApp({ credential: admin.credential.cert({ project_id: process.env.project_id, client_...
/* eslint-env browser */ /** * Web components. * * @module component */ import * as dom from './dom.js' import * as diff from './diff.js' import * as object from './object.js' import * as json from './json.js' import * as string from './string.js' import * as array from './array.js' import * as number from './num...
// Smart contracts const LoanTermsSignatureValidator = artifacts.require("./mock/util/LoanTermsSignatureValidator.sol"); // Util classes const ethUtil = require('ethereumjs-util') const axios = require('axios'); const { hashLoanTermsRequest } = require('../../test-old/utils/hashes'); const { tokens: tokensActions...
const logger = require('../logger'); const {Pool, Client}=require('pg'); const StringUtils=require('../utils/StringUtils'); const XmlUtils=require('../utils/XmlUtils'); const Cursor=require('pg-cursor'); const {promisify}=require('util'); const moment=require('moment'); const fetch=require('node-fetch'); //const gml2js...
import { ER_NO_SUCH_TABLE, ER_SUBQUERY_NO_1_ROW } from './constants' const commitIncrementalImport = async ( { events: { eventsTableName, connection, database }, escapeId, escape }, importId, validateAfterCommit ) => { const incrementalImportTableAsId = escapeId( `${eventsTableName}-incremental-import` )...
'use strict'; const express = require('express'); require('dotenv').config(); const cors = require('cors'); const pg=require('pg'); const server = express(); const superagent = require('superagent'); server.use(cors()); const PORT = process.env.PORT || 5000; const client = new pg.Client({ connectionString: process...
'use strict'; import React, { createElement as h, useState, useCallback, useEffect } from 'react'; import ReactDOM from 'react-dom'; import { useDropzone } from 'react-dropzone'; import * as Leaflet from 'leaflet'; import leafletImage from 'leaflet-image'; import parser from './parser.js'; const Dropzone = (...
import React from 'react'; import { AppRegistry, StyleSheet, View, Text, Dimensions, TouchableOpacity, Modal, Button, NetInfo, } from 'react-native'; import MapView, { MAP_TYPES } from 'react-native-maps'; import _ from 'lodash'; import pick from 'lodash/pick'; import {GoogleSignin, GoogleSigninButto...
var students, dates, leaves, holidays, batch, today, req, subject_id, translated, datearr; var nameTdElem=new Element('td',{ 'class':'td-name' }); var rowElem = new Element('tr',{ 'class':'tr-odd' }); var absentElem = new Element('a',{ 'class':'absent', 'id':'' }); var presentElem = new Element('a',{ ...
const knex = require("../knex.js"); const { Department } = require("../../model/Departments"); const { getRegionCode } = require("../../util/DepartementUtil"); //const whitelist = require("./whitelist"); //const ALLOWED_FILTERS = ["users.active", "users.type"]; // nombre de mesures pour le mandataire const Mandatair...
import React from 'react'; const getChildStateNodes = (children) => { if (children.length) { const childrenOfType = getChildrenOfType(React.Children.toArray(children), 'State'); if (childrenOfType.length) { return childrenOfType; } if (children.props && children.pr...
import fs from 'fs' import os from 'os' import childProcess from 'child_process' import { dialog } from 'electron' import path from 'path' import { fromatPath, mkdirsSync } from '../utils/path' import { getConfig, setConfig } from '../config' const EXT_FILES = ['.swift', '.mmp'] const sortFiles = (data) => { const...
const Canvas = require('canvas'); const Discord = require('discord.js'); const { prefix,// "ign" by default token //For security's sake, if this code were to be made public, this stored in the easy to adapt config file. } = require('./credentials.json'); var Xray = require('x-ray'); var x = Xray(); const client...
function removeFromArray(arr, elt) { for (let i = arr.length - 1; i >= 0; i--) { if (arr[i] == elt) { arr.splice(i, 1); } } } function heuristic(a,b) { return abs(a.i - b.i) + abs(a.j - b.j); } var squareSide = 20; var cols = 25; var rows = 25; var grid = new Array(cols); var openSet = []; var closed...
var turns = 0; var radius = 0; var isSelected = false; var boardAll = [[[null, null, null, null], [null, null, null, null], [null, null, null, null], [null, null, null, null]], [[null, null, null, null], [null, null, null, null], [null, null, null, null], [null, null, null, null]], [[nul...
// Copyright 2020 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. import {PostMessageAPIServer} from '../../chromeos/add_supervision/post_message_api.js'; import {AuthCompletedCredentials, Authenticator, AuthParams} from...
import React, { useEffect, useRef } from 'react'; import HeroView from './hero'; import Marquee from "react-fast-marquee"; import { useInView } from "react-intersection-observer"; import { motion, useAnimation } from "framer-motion"; import { Link } from "react-router-dom"; import gsap from 'gsap'; import { backVariant...
/* * Copyright 2021 Adobe Systems Incorporated * * 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 applica...