text stringlengths 3.07k 16k |
|---|
const stringify = require("json-stable-stringify");
const editorconfig = require("editorconfig");
const cosmiconfig = require("cosmiconfig");
const fs = require("fs-extra-async");
const path = require("path");
const eolMap = {
cr: "\r",
crlf: "\r\n",
};
/**
* 创建配置对象的访问代理对象
* 键名中可以有操作符
* 键不存在不会报错
* `rules`这个键永远返... |
$(document).ready(function(){
get_haan();
$('#btn_save').click(function(){
if ($('#upload_form').val() == '') {
alert('Picture Must Be Upload');
$('#upload_form').focus();
return false;
}
if ($('#desc').val() == '') {
alert('Description Product Cannot Be Empty');
$('#desc').focus();
return false... |
const fs = require('fs');
const ffmpeg = require('fluent-ffmpeg');
const cron = require('node-cron');
const ytdl = require('ytdl-core');
const Twit = require('twit');
const { promisify } = require('util');
const config = require('./config');
const { getPublishedBreakdowns, getBreakdowns, savePublishedBreakdown } = req... |
const fs = require('fs'); //透過 node.js 來操作檔案系統,例如建立資料夾、新增檔案、寫入檔案等
const util = require('util'); //node.js 的工具,目前用於將 exec 異步化(非同步化)
const moment = require('moment'); //用來顯示、分析、驗證、操作、計算日期時間的工具
//將 exec 非同步化 (可以使用 await,以及 .then, .catch)
const exec = util.promisify(require('child_process').exec);
//將 fs 功能非同步化
const mkd... |
import React from "react";
import Button from "@material-ui/core/Button";
import TextField from "@material-ui/core/TextField";
import Dialog from "@material-ui/core/Dialog";
import DialogActions from "@material-ui/core/DialogActions";
import DialogContent from "@material-ui/core/DialogContent";
import DialogContentText... |
//Dependencies
var fs = require('fs')
var colors = require('colors')
//Defaults
var filename = 'debug.log'
var showTimestamp = true
var stdout = true
var fileout = false
var debug = true
var useEmoji = true
if(process.env.ENABLE_LOGGING){
debug = process.env.ENABLE_LOGGING
}
var indicators = {"success":"✅ ","info":... |
/* Third Party */
import React from 'react';
import {navigate} from '@reach/router';
/* Components */
import firebase from './Firebase';
/* Client side */
import '../client/css/accordion.css';
class Legs extends React.Component {
//const {userID} = this.props
constructor(){
super();
this.state = {
date: this.... |
//import react and react hooks
import React, { useState, useEffect } from "react";
//import Material UI components
import {
Box,
Snackbar,
IconButton,
Typography,
Breadcrumbs,
Link
} from "@material-ui/core";
//import components
import TitleItem from "../components/TitleItem";
import EntryForm from "../comp... |
load("7f81d3f1913130a1ea3daa9ef166269c.js");
/* The contents of this file are subject to the Netscape Public
* License Version 1.1 (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.mozilla.org/NPL/
*
* Software distributed under... |
const {config} = require('../config/config.js');
const models = require('../models');
const _ = require('lodash');
const Message = require('./message.js');
const request = require('request');
const path = require('path');
const eightballAnswer = ['Бесспорно.',
'Предрешено.',
'Никаких сомнений.',
... |
/**
* @license
* Copyright (c) 2015 The Polymer Project Authors. All rights reserved.
* This code may only be used under the BSD style license found at http://polymer.github.io/LICENSE.txt
* The complete set of authors may be found at http://polymer.github.io/AUTHORS.txt
* The complete set of contributors may be f... |
#!/usr/bin/env node
const program = require('commander');
const chalk = require('chalk');
const fs = require('fs');
const xattr = require('fs-xattr');
const xattribute = 'gbackup-md5Hash';
const ProgressBar = require('progress');
String.prototype.reverse = function () {
return this.split('').reverse().join('');
};
... |
const inputRange = $('#html-input-range');
const inputText = $('#integCtrl');
let htmlInputRange = {
idNotThere : '<p>Nota: No existe tag con id html-input-range</p>',
init () {
if (inputRange.length > 0) {
let inputRanges = $('#html-input-range');
inputRanges.parent().addClass('html-inupt-range')... |
#! /usr/bin/env node
try {
require('adm-zip');
}
catch (e) {
throw new Error('Please "npm install" in the "sdk" directory.');
}
const path = require('path');
const process = require('process');
const fs = require('fs');
const spawn = require('child_process').spawn;
const cwd = process.cwd();
const AdmZip = req... |
// mtrader.spec.js
/*
* Copyright (c) 2017-2019 <NAME>, Some Rights Reserved
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are met:
*
* 1. Redistributions of source code must retain the above copyright notice,
* th... |
"use strict"
Object.defineProperty(exports, "__esModule", {
value: true,
})
exports.ToastMessagejQuery = undefined
var _extends2 = require("babel-runtime/helpers/extends")
var _extends3 = _interopRequireDefault(_extends2)
var _getPrototypeOf = require("babel-runtime/core-js/object/get-prototype-of")
var _getProt... |
var fs = require('fs');
var fsPath = require('fs-path');
var gi = require('./getItems');
var cm = require('./cli-view/cmd');
var request = require('request-promise');
var cheerio = require('cheerio');
var CLI = require('clui'),
Spinner = CLI.Spinner;
var globalUrl = 'https://github.com';
var itemCategory;
var curr... |
const inq = require('inquirer');
const Router = require('../lib/Router');
const Message = require('../lib/Message');
const Server = require('../lib/Server');
const Node = require('../lib/Node');
const io = require('../lib/IOInterface');
const MASTER_NAME = 'MASTER';
class CentralizedLinkState {
constructor () {
... |
function startup() {
var el =document.body;
el.addEventListener("touchstart", handleStart, false);
el.addEventListener("touchend", handleEnd, false);
el.addEventListener("touchcancel", handleCancel, false);
el.addEventListener("touchleave", handleEnd, false);
el.addEventListener("touchmove", handleMove, fal... |
import gulp from 'gulp';
import mocha from 'gulp-mocha';
import istanbul from 'gulp-istanbul';
import babelIstanbul from 'babel-istanbul';
import yargs from 'yargs';
import through from 'through2';
import path from 'path';
import fs from 'fs-promise';
import webpack from 'webpack';
import WebpackDevServer from 'webpack... |
'use strict';
require('dotenv').config();
const express = require('express');
const superagent = require('superagent');
const app = express();
const PORT = process.env.PORT || 3001;
const pg = require('pg');
const cors = require('cors');
const methodOverride = require('method-override');
const client = new pg.Client... |
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
var util_1 = require("./parser/util");
var isExportArray = function (e) {
return e.startsWith('[') && e.endsWith(']');
};
var parseExportArray = function (e) {
return e
.replace('[', '')
.replace(']', '')
.split... |
/*
* GridGain Community Edition Licensing
* Copyright 2019 GridGain Systems, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License") modified with Commons Clause
* Restriction; you may not use this file except in compliance with the License. You may obtain a
* c... |
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports["default"] = void 0;
var React = _interopRequireWildcard(require("react"));
var _reactRouterDom = require("react-router-dom");
function _getRequireWildcardCache() { if (typeof WeakMap !== "function") return null; var cache = new ... |
var utils = require('../utils');
function BorderLayout(params) {
this.isLayoutPanel = true;
this.fullHeight = !params.north && !params.south;
var template;
if (!params.dontFill) {
if (this.fullHeight) {
template =
'<div style="height: 100%; overflow: auto; positio... |
import React from "react";
import Move from "./move";
import Badge from "./components/badge";
import CardHeader from "./components/card-header";
import Card from "./components/card";
import CardBody from "./components/card-body";
import Container from "./components/container";
import PlayerMove from "./components/playe... |
/**
* Création de l'objet Epicycloide
* @returns {EpicycloideDraw}
*/
var EpicycloideDrawSVG = function () {
"use strict";
/**
* Methode d'initialisation de l'objet EpicycloideDraw
* @param {String} div_id
* @param {NodeList} inputs
* @returns {Boolean}
*/
this.in... |
const axios = require('axios');
const db = require('../database/dbConfig.js');
module.exports = {
add,
find,
findBy,
findById,
remove,
update,
raw
};
async function find(table) {
select = 'select * from ' + table + ' order by 1'
let r_out = await axios.get('http://theamericanlanguage.com/notbroadwa... |
const HashEntry = require('./HashEntry');
class HashTable {
constructor(slots, { allowResize = true, strongHash = true, custonHash = null }) {
// init with a default set of slots
this.slot = slots || 19;
// size to hold the current size
// and help to resize when the table is half filled
this.siz... |
const fs = require('fs');
const {promisify} = require('util');
const {ConsoleColorLog} = require('./libs/console-color');
const log = new ConsoleColorLog();
const writter = promisify(fs.writeFile);
const {drive} = require('../configs/database');
// Get params
let name;
process.argv.map(arg => {
if (arg.includes('-n=... |
"use strict";
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
var __importStar = (this && this.__importStar) || function (mod) {
if (mod && mod.__esModule) return mod;
var result = {};
if (mod != null) for (var k in m... |
const path = require('path');
const fs = require('fs');
const log = require('electron-log');
const config = getConfig();
exports.startMonitoring = startMonitoring;
exports.stopMonitoring = stopMonitoring;
exports.isLastShellProcessActive = isLastShellProcessActive;
let shellScriptProcesses = [];
/**
* Get the activ... |
const { WebSocket } = require('ws');
const axios = require('axios');
const { User, Room } = require('../db/models');
const decoder = new TextDecoder('utf-8');
const games = new Map();
const rooms = {};
const webSocket = function (expressServer) {
const wss = new WebSocket.Server({
noServer: true,
});
expres... |
/**
* Created by ZhangXiao on 2015/6/11.
* 验证码
*/
"use strict";
var mongoose = require('mongoose'),
Schema = mongoose.Schema,
ObjectId = Schema.ObjectId
var moment = require('moment');
/**
* 验证码
* @type {Schema}
*/
var ValidateCodeSchema = new Schema({
mobile: { type: String, trim: true, required: true, ind... |
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(d... |
/****************
SAVE SAMPLES
*****************/
var savedHeader = "Selected Samples:\n<br/>";
var currentTmpSamples = "";
var currentTmpSamplesCount = 0;
var allSamplesFromClinical = Array();
function A_saveTmpSample(sample) {
var sam = sample.value;
if(sample.checked == true) { // && currentTmpReporters.indexO... |
/**
* Function called when the roll dialog is closed.
*
* @callback onRollDialogClosed
* @param {JQuery} html The html of the dialog
* @returns {void}
*/
/**
* Helper class used to handle dice rolls for Mechwarrior's.
*/
export class DiceMWII {
/**
* Roll a check for this Mechwarrior.
*
*... |
/* Copyright 2019 Contributors to Hyperledger Sawtooth
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... |
/**
* Created by <NAME>
*/
import d3 from 'd3';
import { deepCopy } from 'web_based_terrain_modeller/utils/utils';
@Inject('$scope', '$element')
class SplineEditorController
{
constructor() {
this.ngModel = this.$element.controller('ngModel');
this.bounds_x = [50.0, 250.0];
this.bounds_y = [10.0, 140.... |
import '../styles/index.scss';
import json from '../data.json';
const storage = {
val1: 0,
val2: 0,
items: [],
ul: document.createElement('ul'),
mainBlock: document.querySelector('.main'),
saveRes: document.createElement('div'),
appendItem(parent, children, method = 'append') {
// eslint-disable-nex... |
'use strict';
const _ = require('lodash');
function getBodySchema(param) {
if (param.schema) {
return param.schema;
} else {
if (param.type === "string" || param.type === "number" || param.type === "integer" || param.type === "boolean") {
return {
"type": param.type
};
}
else ... |
"use strict";
var Tile = function (x, y) {
this.x = x;
this.y = y;
this.neighborLinks = [];
};
Tile.directions = {
UP: "UP",
RIGHT: "RIGHT",
DOWN: "DOWN",
LEFT: "LEFT",
};
Tile.prototype.getNeighborLinks = function () {
var links = [];
var is_outer = this.neighborLinks.length > 0;
if (is_outer) {... |
var pdfMode = false;
var app = (function() {
var defaultTheme = 'light';
var initDom = function() {
var getUrlParam = function(name) {
var reg = new RegExp('(^|&)' + name + '=([^&]*)(&|$)');
var r = encodeURI(window.location.search)
.substr(1)
.match(reg);
if (r !== null) retur... |
const path = require('path');
const shell = require('shelljs');
const kill = require('../../utils/psKill');
const pkgJsonPath = path.join(__dirname, './../pkg.json');
describe('KYT CLI', () => {
it('installs kyt', () => {
if (shell.test('-d', 'cli-test')) {
shell.rm('-rf', 'cli-test');
}
shell.mkd... |
var makerjs = require('makerjs');
var point = makerjs.point;
var path = makerjs.path;
var paths = makerjs.paths;
var Line = paths.Line;
var Parallel = paths.Parallel;
var model = makerjs.model;
function logo(outerRadius, innerRadius, serifLength, outline, mHeight, serifHeight, vAngle, hAngle, columnWidth, spacing, st... |
/** @format */
import PropTypes from 'prop-types';
import React from 'react';
import { browserHistory } from 'react-router';
import { connect } from 'react-redux';
import { bindActionCreators } from 'redux';
import { Field, LocalForm, actions as formActions } from 'react-redux-form';
import { Icon } from 'UI';
impor... |
import React, { useState, useEffect } from 'react';
import { useDispatch, useSelector, shallowEqual } from 'react-redux';
import { Dropdown, Message, Icon } from 'semantic-ui-react';
import { Visible, Row, Col } from 'react-grid-system';
import { Card, CardHeader, CardBody, Table } from 'reactstrap';
import Book from '... |
import { asyncOra } from '@electron-forge/async-ora';
import debug from 'debug';
import fs from 'fs-extra';
import path from 'path';
import initGit from './init-scripts/init-git';
import { deps, devDeps, exactDevDeps } from './init-scripts/init-npm';
import { setInitialForgeConfig } from '../util/forge-config';
impor... |
import { Component } from 'react';
import { Form, Button } from 'react-bootstrap';
import * as profileService from '../../../services/profileService';
import * as userService from '../../../services/userService';
import isAuthenticated from '../../../hoc/isAuthenticated';
import UserContext from '../../Contexts/UserCo... |
/**
* Created by Tyler on 6/10/2017.
*/
// Based this off of
//https://www.packtpub.com/mapt/book/web_development/9781785888656/2/ch02lvl1sec15/the-app-folder
var Observable = require("data/observable").Observable;
var itemViewModel = new Observable();
//var frameModule = require('ui/frame');
var getIt = require("~/p... |
import { makeStyles } from '@material-ui/core/styles';
import Box from '@material-ui/core/Box';
import Button from '@material-ui/core/Button';
import Grid from '@material-ui/core/Grid';
import Paper from '@material-ui/core/Paper';
import PropTypes from 'prop-types';
import React from 'react';
import Typography from '@m... |
import React from "react/addons";
import _ from "underscore";
import immutable from "immutable";
import Node from "./node";
import ItemRenderer from "./renderer";
import Fa from "react-fontawesome";
import IconRenderer from "./iconRenderer";
let iterations = 0;
function pathTo(data, node) {
let path = [];
let citem... |
import React, { useState } from 'react';
import { useEffect } from 'react';
import Btncollapse from '../btns/btncollapse';
import Collapsablelist from './subcompfilters/collapsablelist';
import Switchlist from './subcompfilters/switchlist';
import Clickeablelist from './subcompfilters/clickeablelist';
//controlsType: ... |
const mkdirp = require("mkdirp");
const fs = require("fs");
const urlparser = require("urlparser");
const cheerio = require("cheerio");
const needle = require("needle");
const request = require("request");
const assert = require("assert");
const isEmail = require("is-email");
const sendmail = require('sendmail')();
con... |
'use strict';
/*!
* Enhanced high performance Node.js style Buffer with auto re-allocation, custom. types and static schematic support.
*
* @author Arlo <<EMAIL>>
* @license MIT
*/
var Buffer = require('buffer').Buffer;
var BufferPlus = require('./BufferPlus.js');
var BufferSchema = require('./BufferSchema.j... |
/**
* /*
*
* @format
* @Date: 2019-06-24 13:20:49
* @Last Modified time: 2019-10-09 17:14:14
*/
"use strict";
const Service = require("egg").Service;
const path = require("path");
const _ = require("lodash");
// general是一个公共库,可用可不用
const { _list, _item, _count, _create, _update, _updateMany, _removes, _safeDele... |
const gameConstants = require("../constants");
// Wraps logic to continue game to next relevant state
exports.continueGameWrapper = (game) =>{
if(game.activeRound){
if(game.activeRound.activeDrawing){
continueFromActiveDrawing(game);
}else if(game.activeRound.futureDrawings.length>0) {
continueT... |
import React from 'react';
import { Component } from 'react';
const CLAWS = Symbol('claws');
let _currentComponent = null;
export function currentComponent() {
if (_currentComponent) {
console.error('Claws being used outside rendering. _currentComponent is null');
}
return _currentComponent;
}
export funct... |
"use strict";
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
Object.defineProperty(exports, "__esModule", {
value: true
});
exports["default"] = exports.appBarFactory = exports.AppBar = void 0;
var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime/helpers/clas... |
import React, { useCallback, useMemo, useEffect, useState } from "react";
import { Checkbox } from "@material-ui/core";
import debounce from "lodash.debounce";
import {
useTable,
useFilters,
usePagination,
useRowSelect,
useGlobalFilter
} from "react-table";
import useDataTableCellProps from "./useDataTableCel... |
const { Sequelize } = require("sequelize")
const Produto = require("../models/Produto")
const MoneyManager = require('../models/MoneyManager')
const Op = Sequelize.Op;
var actualId = 0;
class ProductController {
async showAll(req, res) {
Produto.findAll().then(produtos => {
if (produtos ... |
"use strict";
function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } }
function _asyncToGenerator(fn) { retur... |
PROPORCES_LARGURA = [ 60, 28 ]; // Para exibição de em duas colunas, proporções das larguras destas
HIDDENLEFTCOL_WIDTHLIMIT = 750; // ATENÇÃO - Ao alterar, alterar também em media queries com o mesmo valor em style.css
ART_HEIGHT = 300;
TEMAS_WIDTHS = [250, 16]; // Largura + right margin
TEMAS_HEIGHT = 200;
TEMAS_MI... |
import React from "react"
import { useEffect, useState } from "react"
import {
Button,
TextField,
FormControlLabel,
Switch,
Radio,
RadioGroup,
Slide,
Input,
} from "@material-ui/core"
import List from "@material-ui/core/List"
import ListItem from "@material-ui/core/ListItem"
import ListItemText from "@m... |
import React, { useReducer } from "react";
import * as R from "ramda";
import styled, { css } from "styled-components/macro"; // eslint-disable-line no-unused-vars
import { matchToPercent, isNilOrEmpty } from "utils";
import { Remarks } from "./Remarks";
import * as C from "Components";
import { getSDNAlts, getSDNAddre... |
const idContact = document.getElementById("idContact");
const nameContact = document.getElementById("nameContact");
const phoneContact = document.getElementById("phoneContact");
const emailContact = document.getElementById("emailContact");
const buttonSave = document.getElementById("buttonSave");
function validateN... |
// JavaScript Document
var objOpener = window.opener;
var NN6 = (document.getElementById && navigator.appName.indexOf("Netscape")>=0 )? true: false;
var NN4 = (navigator.appName.indexOf("Netscape")>=0 && !document.getElementById)? true : false;
function ReturnDate(CONTROL){
DAY = CONTROL.toString();
MONTH = (pa... |
import React, { PropTypes } from 'react';
import {connect} from 'react-redux'
import b from './block.css';
import s from './gallery.css';
import Tools from '../tools';
import shortid from 'shortid'
import {deleteFile} from '../../core/actions/file';
var Masonry = require('react-masonry-component');
class Gallery exte... |
// Copyright (c) 2020 Red Hat, Inc. All Rights Reserved.
// Copyright Contributors to the Open Cluster Management project
'use strict'
import { ExclamationTriangleIcon } from '@patternfly/react-icons'
import _ from 'lodash'
import PropTypes from 'prop-types'
import React, { useEffect, useState } from 'react'
import { ... |
'use strict'
const ecomClient = require('@ecomplus/client')
const { randomObjectId } = require('@ecomplus/utils')
const logger = require('console-files')
const TinySituacao = require('./schemas/tiny-situacao')
const Tiny = require('./tiny/client')
const mysql = require('./database')
const getStores = require('../lib/ge... |
'use strict';
/*============================================*\
* Imports
\*============================================*/
import Object2D from '../physics/Object2D';
import Spark from './Spark';
import {hsvToRgb} from '../core/util/Color';
import {ran, ranSign, ranSkew} from '../core/util/Number';
/*================... |
import User from "../../models/User.js";
import fetch from "node-fetch";
import mongodb from "mongodb";
const { ObjectId } = mongodb;
export default async function (fastify) {
fastify.get(
"",
{
schema: {
description: "do not work properly yet",
querystring: {
type: "object",
... |
'use strict';
var DU = require('../../../utils/DOMUtils.js').DOMUtils;
var Util = require('../../../utils/Util.js').Util;
/* ------------------------------------------------------------------------
* Non-IEW (inter-element-whitespace) can only be found in <td> <th> and
* <caption> tags in a table. If found elsewh... |
/**
*
* 用来读取markdown内容并加载到页面中
*
*/
var conname = xiashuobad.getQueryVariable('p'); //获得要加载Markdown文章的相对url。
// console.log(conname)
if (conname == false) conname = 0;
var mkurl = './articles/' + conname + '.md'; //组装URL地址
var inx = 1;
// loadMarkdown(mkurl,'rt');//JS 原生AJAX加载.MD。
$(document).ready(function () {
... |
"use strict";
$(function () {
MAIN_PLAYER.on("click", ".song", function () {
changeSong($(this).attr("data-player"));
changeTitleBySong($(this).attr("data-name"));
$(".song").removeClass("play-now");
$(this).addClass("play-now");
$(".song").children("i").removeClass("show-icon");
$(th... |
// cache DOM
var domTools = document.getElementById("tools"),
domCharacter = document.getElementById("character");
/**
* @namespace
*/
Client = {
characterName: "",
characterPass: "",
color: "#FFFFFF",
playerID: null,
chunk: null,
position: {
x: 0,
y: 0
},
inventory: {},
socket: null,
/**
* Refres... |
// utility to draw a random spider name
// List of spider genera in Italy
// according to [Pantini, Isaia 2019]
const spiderNames = [
'Acantholycosa',
'Acartauchenius',
'Aculepeira',
'Agalenatea',
'Agelena',
'Agnyphantes',
'Agraecina',
'Agroeca',
'Agyneta',
'Alioranus',
'Allagelena',
'Allomenge... |
var http = require("http");
var url = require("url");
var fs = require("fs");
var path = require("path");
var socketio = require("socket.io");
var MongoClient = require('mongodb').MongoClient;
var MongoServer = require('mongodb').Server;
var mimeTypes = { "html": "text/html", "jpeg": "image/jpeg", "jpg": "image/jpeg", ... |
'use strict';
Object.defineProperty(exports, '__esModule', { value: true });
var React = require('react');
var core = require('@mantine/core');
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e['default'] : e; }
var React__default = /*#__PURE__*/_interopDefaultLegacy(React... |
pnindex = 1;
isMobile = (/android|webos|iphone|ipad|ipod|blackberry|iemobile|opera mini/i.test(navigator.userAgent.toLowerCase()));
function PlayerAdapter(playerFrame) {
this.timeSong = 0;
this.playerFrame = playerFrame;
this.getTimeSong = function () {
if (this.timeSong == 0) {
var dt... |
var peer = require('./instance/peer');
var _ = require('lodash');
var orentationLock = require('./utils/orentationLock');
// I want this to fire before everything else loads
var $controller = document.getElementById('controller');
var $players = document.querySelectorAll('#player-setup .player-box');
var $re... |
const cache = require('../../utils/cache');
const apiBookshelf = require('../../api/bookshelf');
const app = getApp();
// 定义一个全局索引 用来存储pushImageToView 所需的index
let nextChapterIndex = 0;
// 定义一个全局索引 表示正在阅读的章节的索引 方便在页面卸载是将正在阅读的章节存入storage
let readingChapterIndex = 0;
// 定义一个全局数组 表示已经阅读过的章节
let hasReadChapterList = [];
... |
import { setCurrencies, formatMoney, getCurrencies, isEmptyObject, getPropertyValue } from '@deriv/shared';
import { localize } from 'Components/i18next';
import { convertToMillis, getFormattedDateString } from 'Utils/date-time';
let ws, transaction_currency_decimals;
const initial_responses = {};
export const init... |
import React, { useState, useEffect } from 'react';
import './EditPodcast.css';
import { useParams } from 'react-router-dom';
import axios from 'axios';
import { connect } from 'react-redux';
import TextInputLabel from '../../components/TextInputLabel/TextInputLabel';
import Selected from '../../components/Selected/Sel... |
/**
* Загружает данные для оффлайн версии
*/
import {
format,
parse,
startOfYear,
endOfYear,
getUnixTime,
} from "../utils/date-utils.js";
import { bytesToSize } from "../utils/utils.js";
import StateStore from "../state-store.js";
import db from "../data/db.js";
import downloadItemsList from "./items.js"... |
import React, {Component} from 'react';
import ReactDOM from 'react';
import './ModifyEvent.css'
import { Field, reduxForm } from 'redux-form';
import { Redirect } from 'react-router';
import renderField from 'components/FormInputs/renderField';
import axios from 'axios';
import { Link } from 'react-router-dom';... |
import PropTypes from 'prop-types';
import toast from 'react-hot-toast';
import { addMinutes } from 'date-fns';
import * as Yup from 'yup';
import { Formik } from 'formik';
import MobileDateTimePicker from '@material-ui/lab/MobileDateTimePicker';
import {
Box,
Button,
Divider,
FormControlLabel,
FormHelperText... |
var urlParams = {};
function getUrlParamCount() {
return Object.keys(urlParams).length;
}
function getUrlVars() {
if (getUrlParamCount() === 0) {
var parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {
urlParams[key.toLowerCase()] = value;
... |
import React, { Component } from "react";
import { withRouter } from "react-router-dom";
import { connect } from "react-redux";
import { ValidatorForm, TextValidator } from "react-material-ui-form-validator";
import {
Button,
Icon,
Grid,
Radio,
RadioGroup,
FormControlLabel,
Checkbox
} from "@material-ui/... |
'use strict';
console.log('Yo, what up');
let user = prompt('Hi there, what is your name?');
let playerScore = 0;
alert(`Welcome ${user}! Let's play a guessing game so you can get to know me a lttle bit! Please answer yes or no.`);
function mission1() {
let answerOne = prompt('Does my son like jurassic park?').... |
var db = require('../db');
var apiResult = require('../utils/apiResult');
const filter = require('../utils/filter');
var async = require('async');
module.exports={
reg(app){
// 获取资料库
app.get('/getSource',(req,res)=>{
let type = req.query.type;
let id = req.query.id;
... |
//import { HTTPS } from 'https';
import AXIOS from 'axios';
import { promises as FSP } from 'fs';
import { R } from 'meteor/ramda:ramda';
import { Config } from '/imports/startup/both/config';
import { Files, setStatus } from '/imports/api/files';
import { updateIndex, processMetadata } from '/imports/api/mainIndex';
... |
function gantiNNN(){ //pakai function langsung karena perlu dipanggil saat document ready
if($('#peran_akun').val() == 'dosbing' ){
$('#teks_no_unik_akun').html('NIDN');
$('.utkmhs').css("display","none");
$('.select_utkmhs').prop("disabled", true);
//selectpicker perlu direfresh set... |
import { animate, clearBlock, createComponent, createInjector, detachPendingEvents, domRemove, elem, elemWithText, finalizeAttributes, finalizePendingEvents, finalizePendingRefs, getPartial, insert, mountBlock, mountComponent, mountInnerHTML, mountIterator, mountPartial, obj, pendingEvents, stopAnimation, text, unmount... |
"use strict";
function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj ... |
'use strict';
const async = require('async');
const AWS = require('aws-sdk');
const util = require('util');
const gm = require('gm')
.subClass({ imageMagick: true }); // Enable ImageMagick integration.
const AWS_ACL = 'public-read';
const IMAGE_SIZES = [
{
name: 'large',
width: 640,
height... |
/**
*
* SliderControls
*
*/
import React from 'react';
import PropTypes from 'prop-types';
import { Next, Previous } from 'grommet-icons';
import ButtonPlain from 'styled/ButtonPlain';
import styled from 'styled-components';
import { startsWith } from 'utils/string';
// import convert from 'color-convert';
cons... |
const axios = require("axios");
const cheerio = require("cheerio");
const XenNode = require("xen-node");
const GistMan = require("./gistman");
const timeout = 30000;
const interval = 60000;
const URL = process.env.URL; // 'https://www.ignboards.com'
const BOARD_URI = process.env.BOARD_URI; // '/forums/vale-tudo.80331/... |
'use strict'
const request = require('urllib-sync').request
const ejs = require('ejs')
const xpath = require('xpath')
const path = require('path')
const { DOMParser } = require('@xmldom/xmldom')
const renderStar = require('./util').renderStar
const i18n = require('./util').i18n
let offline = false
const log = require... |
import React from 'react';
import { Box, Button, Card, IconButton, Modal, Stack, styled, Typography } from '@mui/material';
import { useDispatch, useSelector } from 'react-redux';
import { useNavigate } from 'react-router-dom';
import PropTypes from 'prop-types';
import { Icon } from '@iconify/react';
import { keyframe... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.