text stringlengths 65 6.05M | lang stringclasses 8
values | type stringclasses 2
values | id stringlengths 64 64 |
|---|---|---|---|
(function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.ex... | JavaScript | CL | 447eba1981150b9cd94ea870329639d69ad71fbdc6f4c3e850450225b40b6ab1 |
import React from "react";
import { HashRouter as Router, Switch, Route } from "react-router-dom";
import { Container, Box, Breadcrumbs, Typography } from "@material-ui/core";
import Menu from "./Layout/Menu";
import CustomAppBar from "./Layout/CustomAppBar";
import Home from "./views/Home";
import HeapSort from "./v... | JavaScript | CL | 12a1773ff8b9ec0969ea50dd5790422af63b3ddc5627ecba9abcd311177c0458 |
import Vue from "vue";
import Router from "vue-router";
import Home from "./Home";
import uploadBD from "./uploadBD";
import Login from "./Login";
import Signup from "./Signup";
import { checkUser } from "@/api/auth";
import AddMaster from "./addMaster";
import AddPublisher from "./AddPublisher";
import AddArtist from ... | JavaScript | CL | bfad1ab2f56f10044c833f0d48d1c89c4ed6104536f147170a175ac31241e597 |
import React from 'react';
import { Field, reduxForm } from 'redux-form';
//Field is a Component, reduxForm is a function
class StreamForm extends React.Component {
renderInput = formProps => {
// formProps object which was senf by redux form
// console.log(formProps);
// {input: {…}, meta: {…}} // !inpu... | JavaScript | CL | 33c36aedee6a684abace7ce02a5d6c9b37f96396fef482449c5ebef9f7fef38d |
import { GET_BUSINESSES } from "@gql/getBusinesses";
import { initializeApollo } from "../libs/apolloClient";
import BusinessesContainer from "@components/Containers/BusinessesContainer";
import { Box, Text } from "@chakra-ui/react";
import Error from "next/error";
import { initializeStore } from "libs/redux";
const S... | JavaScript | CL | f55a1b2b9fbaff87922e1c121deb89432c8298c8797419617d40fe9ca47f3a06 |
/*!
* @namespace BAT
* @element bat.keep
* @homepage batjs.github.io
*
* @status beta
* @version 0.0.1
* @author Jo Santana
* @license Released under the MIT license
*
* @usage:
*
* Bat.keep.set('batman', 'hero', 7);
* Bat.keep.get('batman'); // Returns "hero".
*... | JavaScript | CL | 29dfca2e09f4bcf3e4337db66d8e217e9b6478ae9e3672035837b75b31b6a61e |
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT license.
import { parseKeyVaultKeyIdentifier } from "./identifier";
/**
* @internal
* Shapes the exposed {@link KeyVaultKey} based on either a received key bundle or deleted key bundle.
*/
export function getKeyFromKeyBundle(bundle) {
const keyBun... | JavaScript | CL | 93988900f2d691655de5149e73b71be4b8f13b5052f39d3a2a86f35a9e4aff7a |
const { authenticate } = require('@feathersjs/authentication').hooks;
const { setField } = require('feathers-authentication-hooks');
const { iff, isProvider, preventChanges } = require('feathers-hooks-common');
const { setDefaultSort, getFullModel, protectUserFields } = require('../common_hooks.js');
const {buildHtmlEm... | JavaScript | CL | 896311e40211f7e0aab3839cadc1777f28eb69cadc5a4097fd42293be98702ed |
const express = require("express");
const request = require("request");
const fs = require('fs');
const fsPromises = fs.promises;
var cors = require('cors');
const axios = require('axios')
const {PythonShell} =require('python-shell');
const router = express.Router();
router.get("/", cors(),(req, res) => {
res.rende... | JavaScript | CL | 70cab11afabb808b540239c7a57b812fcbba9f07303ae2a6be152404342795d7 |
/**文档相关接口*/
import $axios from "@/service/httpServer";
// 获取文档列表
export const getDocsList = p => $axios.get('/inkwash/dos/list', p);
// 获取文档详情
export const getDocumentDetail = p => $axios.get('/inkwash/dos/detail', p);
// 创建文件夹
export const newFolder = p => $axios.post('/inkwash/docs/newFolder', p);
// 新增文档
export... | JavaScript | CL | 0ab91acdc6963fe8208d596de8dec1d246ea3c744d496f132e8aa86fed330403 |
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... | JavaScript | CL | 118b445fc0fd63065ee836f0cc6f56b2dade7cad28acc06763693213247f3cbb |
export default class alap {
alapConfig;
alapElem = null;
curTimerID = 0;
theBody = null;
listType = "ol";
mode = "vanilla"; // vanilla, vue, react, etc
menuTimeout = 5000;
ESC_KEYCODE = 27;
constructor(config = undefined, mode = "vanilla") {
if (config && Object.keys(config).length) {
this.... | JavaScript | CL | 8ace7566c6616dd25cb75c444262be76c1a60fe3d00252bda2a15e027817d9b9 |
require('dotenv').config()
module.exports = {
/*
** Nuxt rendering mode
** See https://nuxtjs.org/api/configuration-mode
*/
mode: 'universal',
/*
** Nuxt target
** See https://nuxtjs.org/api/configuration-target
*/
target: 'server',
/*
** Headers of the page
** See https://nuxtjs.org/api/confi... | JavaScript | CL | fd29057dd2723975751eb60088416d8aff5ee2ac30016214548b1ba4731f0dab |
/*
* eIDPluginHelper
*
* Copyright (c) 2014 The Third Research Institute of The Ministry of Public Security
*
* Version 3.7.5.154
*/
var eID = null;
var onPluginLoad = null;
eID = new eIDPluginHelper();
function eIDPluginHelper() {
//控件对象
var eIDpuginObject = null;
//是否插件已加载
var is... | JavaScript | CL | 7c4535efdf9f520413bb1715090dbe1c7c61b36494b4a07d795e62c30ed51619 |
(function () {
'use strict';
angular.module('app.setting').config(config);
/** @ngInject */
function config($stateProvider) {
$stateProvider.state(
'settingList', {
parent: 'root',
url: '/setting/capDo-list',
templateUrl: 'app/setting/c... | JavaScript | CL | b07b233342d151e71cf821ec254aae9d246079a2d2813e1cc335687a876fe697 |
//模块化思想
//1 启动server webpack-dev-server
//2 模块化开发commonjs
//3 版本号控制 hash或者chunkhash
//4 css,sass引入
//5 html自定义模板
//6 抽离css
//7 压缩合并JS
//8 用babel编译es6,需要创建.babelrc文件
//9 mock数据(npm i json-server -g 搭建虚拟服务器)
//10 external外部配置文件(开发依赖),例如项目用到jQuery
var webpack=require('webpack');
//4 配置HTML 模板 ,插件
var HtmlWebpackPlugin =... | JavaScript | CL | dbac61c27c26748946061bde4b33e8623b9d4ca353beed2c4a53b7409ed1a200 |
import {
LEAGUE_REQUEST_BY_ID,
LEAGUE_RECEIVE_BY_ID,
REQUEST_FIXTURES_BY_LEAGUE,
RECEIVE_FIXTURES_BY_LEAGUE,
LEAGUE_REQUEST_TEAMS,
LEAGUE_RECEIVE_TEAMS,
LEAGUE_RECEIVE_MULTIPLE_LEAGUES,
} from '../types/leagues'
import { getAllSeasonsForLeague } from '../../fetch/League'
import { getTeamsByLeagueID } from... | JavaScript | CL | 92a7833d3c7726f8cebbc55a0da5a12e9c709977cf9eee1fd776c3b035e8c1b7 |
'use strict';
//
const child_process = require('child_process');
const aws = require('aws-sdk');
const s3 = new aws.S3();
const lambda = new aws.Lambda({
region: 'us-east-1' //change to your region
});
const exec = require('child_process').execSync;
const fs = require('fs');
function systemSync(cmd) {
return exe... | JavaScript | CL | c672c3634f32427f63f84c6d3bc3ed14d89eb337232cdf01398b8a61f0b73edc |
import { connect } from "react-redux";
import { compose } from "redux";
import { createStructuredSelector } from "reselect";
import { collectionsFetchingSelector } from "../../redux/shop/shop.selectors";
import { WithSpinner } from "../../components/with-spinner/with-spinner.component";
import CollectionPage from "../... | JavaScript | CL | dd517b7ed05bc08f0c3c08633870d68c5f9f7a1fafe973aa246819774b292589 |
/* eslint-disable import/no-unresolved, import/extensions */
import Entypo from 'react-native-vector-icons/Entypo';
import EvilIcons from 'react-native-vector-icons/EvilIcons';
import Feather from 'react-native-vector-icons/Feather';
import FontAwesome from 'react-native-vector-icons/FontAwesome';
import Foundation fro... | JavaScript | CL | e78b91f32698eaacf64b0879ebdbf87f0a88c39341eeff03c6f22cde63f470d8 |
'use strict';var Vue=require('vue');function _interopDefaultLegacy(e){return e&&typeof e==='object'&&'default'in e?e:{'default':e}}var Vue__default=/*#__PURE__*/_interopDefaultLegacy(Vue);function _slicedToArray(arr, i) {
return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr,... | JavaScript | CL | 868fab039ce6cb75fd2ab35e07fbab04921e7fbef0251ed95b3dceb95c9f1226 |
let util = require("util");
let Room = require("./Room.js").Room;
let ProtoID = require("../../../net/CSProto.js").ProtoID;
let CommFuc = require("../../../util/CommonFuc.js");
///////////////////////////////////////////////////////////////////////////////
//>> 斗地主
function SubGame() {
this.protoMap = {}... | JavaScript | CL | 74c88a9786452cd9ad4df5a3fd4e9e9c144898714fb48a15a3ac97a742238b3b |
/**
* jKif - 2015
* conjunctionnode.js
* @file AST ConjunctionNode constructor for representing conjunctions
* @author Clark Feusier - cfeusier@gmail.com
* @copyright Copyright (C) Clark Feusier - All Rights Reserved
*/
var BaseNode = require('./ast_constructor_base');
/**
*
* @param {Object} locationData
... | JavaScript | CL | 5c4c1f03073ef272930fb9462830266b750b9d20df53d7526f97bf708eaa2c12 |
import { graphqlKoa, graphiqlKoa } from 'graphql-server-koa';
import schema from '../../data/schema';
import { authJwt, vertifyToken } from '../../auth';
export default (router) => {
router.post('/graphql', authJwt(), vertifyToken, graphqlKoa(ctx => ({
schema,
context: {
user: ctx.req.user,
... | JavaScript | CL | 55c3a7d0559f5ef29cf6efdbf3b2dbc99c17367cfe62415705833b71a5337372 |
let createError = require('http-errors'),
express = require('express'),
child_process = require('child_process'),
path = require('path'),
cookieParser = require('cookie-parser'),
logger = require('morgan'),
debug = require('debug')('server-media-server:server'),
http = require('http'),
inde... | JavaScript | CL | a7447325f2b5bc2f6a85c96f10fdaa070af8268e953cb4eeb2b0786ff6ce2905 |
(window["webpackJsonp"] = window["webpackJsonp"] || []).push([["main"],{
/***/ "./$$_lazy_route_resource lazy recursive":
/*!******************************************************!*\
!*** ./$$_lazy_route_resource lazy namespace object ***!
\******************************************************/
/*! no static expo... | JavaScript | CL | c0e3a73ebd56dfedcde94c77c3371a22bf2667d1c52b71ba29e105f7647f12c6 |
/**
* Getting telemetry data of the Crazyflie
*/
const { Crazyradio } = require('../dist/index');
// Because you can only use `await` within an async function...
main();
async function main() {
const radio = new Crazyradio();
try {
await radio.init();
radio.on('console line', console.log);
radio.on('err... | JavaScript | CL | cb3ecfb76b67fa3ff3af7396c8e8cd95aa8d5a8110a07108505a0c7ed95bf725 |
module.exports =
/******/ (function(modules) { // webpackBootstrap
/******/ // The module cache
/******/ var installedModules = {};
/******/
/******/ // The require function
/******/ function __webpack_require__(moduleId) {
/******/
/******/ // Check if module is in cache
/******/ if(installedModules[moduleId])... | JavaScript | CL | 96188283dcba942eaa49a7cbfc0562bf336285e2d8f3b2bf25265ae25ac903a6 |
'use strict';
(function() {
// Crudms Controller Spec
describe('Crudms Controller Tests', function() {
// Initialize global variables
var CrudmsController,
scope,
$httpBackend,
$stateParams,
$location;
// The $resource service augments the response object with methods for updating and deleting the res... | JavaScript | CL | e64a3ea9b9b13ce2630803c59ead9073724e4e14fdcee8bd0cef83a0f3e949b2 |
import React from 'react';
import { act } from 'react-dom/test-utils';
import { fireEvent } from '@testing-library/react';
import OptionsList from '..';
const options = [
{ value: 'velociraptor', label: 'Velociraptor' },
{ value: 't-rex', label: 'Tyrannosaurus rex' },
{ value: 'diplodocus', label: 'Diplodocus' ... | JavaScript | CL | 51455740c6b3e4492ebfe39019efd54fa92838f3bce4e2823d0c8af15ce6ee97 |
/* eslint-disable react/prop-types */
/* eslint-disable no-underscore-dangle */
import React from 'react';
import { useHistory } from 'react-router-dom';
import { useStoreState, useStoreActions } from 'easy-peasy';
import { useSnackbar } from 'notistack';
import Button from '@material-ui/core/Button';
import CardMedia... | JavaScript | CL | 65018754607ad1b8cb71eae59749eeb437499dd24d69d90696cad18d33aff5d0 |
#!/usr/bin/env node
/**
* Copyright (c) 2018-present, Lmntrx Tech.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
// ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
// /!\ DO NOT MODIFY THIS FILE /!\
... | JavaScript | CL | 0738559b34434b3a85b3046546c06e459fbcd41856e5fe8c273cdf89d555d1d9 |
import axios from 'axios';
import React, { useEffect, useState } from 'react';
import NumberFormat from 'react-number-format';
import CheckCircleIcon from '@material-ui/icons/CheckCircle';
import ArrowDownwardIcon from '@material-ui/icons/ArrowDownward';
import ArrowUpwardIcon from '@material-ui/icons/ArrowUpward';
imp... | JavaScript | CL | 0102dda88a48591a17d31175efcf9ac61f20ed8b44a48d28ccf9a517e7fe9516 |
LineChart.prototype = new DexComponent();
LineChart.constructor = LineChart;
function LineChart(userConfig)
{
DexComponent.call(this, userConfig,
{
'parent' : null,
'csv' :
{
'header' : [ "X", "Y" ],
'data' : [[0,0],[1,1],[2,4],[3,9],[4,16]]
},
'width' : 600,
... | JavaScript | CL | 4f0c45f268ae664f9b98113175166824ea8f119c48aca848f98d1a034e2124ea |
; (function (ng) {
'use strict';
ng.module('grastin', [])
.controller('GrastinCtrl', ['$scope', 'modalService', function ($scope, modalService) {
var ctrl = this;
ctrl.init = function () {
if (!window.isGrastinLoaded) {
jQuery.getScript((window.locat... | JavaScript | CL | 6e240400f90e4e9680871cc7dd1a75190688d4ab5fce6f3dc7ca4457cc2bbf7b |
/**
* checkbox group component define
* @author fengpeng
*/
import controller from './checkbox.group';
import template from './template.html';
/**
* @type {Object}
* @property {Boolean} disabled - binding symbol is <, 禁用状态, 在组上禁用则全部禁用, 实际上是对ng-disabled的包装
* @property {Array.<Object>} model ... | JavaScript | CL | a42552a55431d0fa072713fcfefc9d1156da725baf8b27bc0356f3056cba7286 |
const _ = require('lodash');
const DEBUG = process.env.DEBUG || 0;
// many to many
function makeAgg(knex, k, field) {
return knex.raw('json_agg(x' + k + ') AS "' + field + '"');
}
// Many to many select field with only _id field
function makeAggId(knex, k, field) {
return knex.raw('json_agg(x' + k + '._id) AS "' ... | JavaScript | CL | c686f0b98e65b461f6b3b2059221849e7a6ba0daa666933df50840802502e886 |
import React from 'react';
import PropTypes from 'prop-types';
import { Redirect } from 'react-router-dom';
import DashboardPanel from './dashboardPanel.js';
import Map from './map.js';
import Profile from './profile.js';
// The Dashboard component lays out the bootstrap containers for its children
// components. It i... | JavaScript | CL | 862b03bbdff671ab897903b61919f7d86c02e70b81e613a5e73762c9b81c6121 |
// Import the ORM to create functions that will interact with the database.
var orm = require("../config/orm.js");
var Sequelize = require("sequelize");
var sequelize = require("../config/connection.js");
var burger = sequelize.define("buger", {
burger_name: Sequelize.STRING,
devoured: Sequelize.BOOLEAN
});
... | JavaScript | CL | 9670705fadb3082a353ff548ae752fc785e9fc158b289f5bf90fc3d1105c385e |
import { PropTypes } from 'react';
import Helmet from 'react-helmet';
import NotFoundHandler from '../routes/not_found_handler';
import ProjectsList from '../projects/list';
import BreadcrumbsList from '../breadcrumbs/list';
import { getAllProjects, getTechnology } from '../data/store';
import { getPositionText } from ... | JavaScript | CL | feeea908379f9af16418837b079f52eab8ac616dabb77ca64fd99bde7b6d4533 |
/*!
* main.js
* Uses jQuery and dataTables.js to create a responsive design for tabular data.
*
* @project Mobile Grid Evaluation
* @date 2012-11-28
* @author Andrew Rota
*
*/
$(document).ready(function () {
var table;
/**
* Formatted Numbers Sorting Plug-in for DataTables
*
* @a... | JavaScript | CL | e940ac5b9a87426d1468c16f708c1ecf9653c75e7cddbd0f203ba2c531d852f1 |
/**
* Fido / Webauthn and all the functions to create / edit / delete it ...
*/
import psonoServer from './api-server';
import store from './store';
import helperService from './helper';
/**
* Returns the current origin
*
* @returns {string} Returns the current origin
*/
function getOrigin() {
const parsedU... | JavaScript | CL | 510d1e850393dabb24e0660e13de30bfd515886d85c0df86ceb4a74fce88e2b8 |
/**
* Class for working with numbers and numerical data.
* @property {Numbers}
*/
export { Numbers } from "./api/Numbers";
/**
* Class for working with arrays of any types
* @property {Arrays}
*/
export { Arrays } from "./api/Arrays";
/**
* Class for working with arrays containing objects with key/value data.
*... | JavaScript | CL | 330e464f97634c705a8b8938bf1eccf6b9bece47007e9cd27be7192567a3dbc1 |
import React, { Component } from 'react';
import { Text } from 'react-native';
import { SafeAreaView, NavigationEvents } from 'react-navigation';
import PropTypes from 'prop-types';
import AuthForm from '../../components/AuthForm';
import NavLink from '../../components/NavLink';
export class Screen extends Component ... | JavaScript | CL | 0db597989549625bcc898619802d1fefee166d99d001ea9f1c1ac60dee7520de |
const qs = require('qs')
const fetch = require('node-fetch')
const Bluebird = require('bluebird')
const { forEach, replace } = require('lodash')
// const consola = require('../utils/consola')
// const { logError2CloudWatch } = require('../utils/logger')
// const {
// API_URL_BACKEND,
// GOOGLE_MAP_API_URL,
// API... | JavaScript | CL | 9af2daf0656435c6120191246ccbccbfe708d8af9d9c7fdce10e422057ea4706 |
import { CALL_API, Schemas } from '../../middleware/api';
import ApiRoutes from '../../../../shared/routes/api';
import {
defaultOpts,
postOpts,
putOpts,
deleteOpts,
makeGetUrl,
} from '../../actions/reqHelpers';
import { Map } from 'immutable';
import moment from 'moment';
const ARCHIVED_MESSAGES_LIMIT = 10... | JavaScript | CL | d2ab7036efe3932191eaecd17ea3e73507d9df485a2c614f63e5bbd821741099 |
// Copyright 2018 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.
goog.provide('viz.mojom.FrameDeadline');
viz.mojom.FrameDeadline = class {
constructor() {
/** @type { !mojoBase.mojom.TimeTicks } */
this.fr... | JavaScript | CL | b626807c83592e5a4c075da2671f3733fb3cba582b44970819da1064ca4774c6 |
áfrica y la historia que le fue sustraída
Nairobi - La noticia de que la Universidad de yale se ha comprometido a devolver miles de artefactos que uno de su-fem-sg investigadores llevó a esta universidad desde Perú el año 1911 , dummy-she hizo que dummy-she recordara una fiesta a la que dummy-I asistí hace poco - una... | JavaScript | CL | a17556731ef5a67613dd4ecbf2296a10f1106e23f6a433b78187f62df6c2adb9 |
const { errors } = require('arsenal');
const collectCorsHeaders = require('../utilities/collectCorsHeaders');
const deleteBucket = require('./apiUtils/bucket/bucketDeletion');
const { metadataValidateBucket } = require('../metadata/metadataUtils');
const { pushMetric } = require('../utapi/utilities');
const monitoring... | JavaScript | CL | 50efa5457ee43d80cc417e438f7adf8b890bf54d7f300a01d4a7e9a23cdab835 |
'use strict'
const swapper = require('../utils/tokenSwapper')
const { deployContract} = require('../utils/setupHelper')
const {ethers} = require('hardhat')
const {defaultAbiCoder} = ethers.utils
const {deposit} = require('../utils/poolOps')
const {expect} = require('chai')
const time = require('../utils/time')
const {... | JavaScript | CL | c707be6890f925737e6d4de8ab152ea1c1ec0ac590912e988d37c850f4f20937 |
'use strict';
var dbm;
var type;
var seed;
/**
* We receive the dbmigrate dependency from dbmigrate initially.
* This enables us to not have to rely on NODE_PATH.
*/
exports.setup = function(options, seedLink) {
dbm = options.dbmigrate;
type = dbm.dataType;
seed = seedLink;
};
exports.up = function(db, c... | JavaScript | CL | 618c206e04a8fb0ff8d91a3d5aa5df8f3bd471492d00bc5bb4bf5dd950640e68 |
const object1 = {}
Object.defineProperties(object1, {
property1: {
value: 42,
writable: true
},
property2: {}
})
// define a single property
const object2 = {};
Object.defineProperty(object2, 'property1', {
value: 42,
writable: false
});
object2.property1 = 77;
// throws an error in strict mode
c... | JavaScript | CL | 6a97ab600d0fd154bc49fba9f0241fe0df113efec33dbfa3c2cdc491bf33846f |
import Vue from 'vue'
import globalTable from '@/components/base/global-table/table.vue' // 全局表格组件
import globalSearch from '@/components/base/global-search.vue' // 全局筛选/查询组件
import globalMinPage from '@/components/base/global-table/min-page.vue' // 全局筛选/查询组件
import globalPage from '@/components/base/global-table/page.... | JavaScript | CL | 9c605220c7ed0af554869304c5634343c03cb647c0491745283fdfde238bfcfc |
'use strict';
define(['services/utils/routeResolver' ], function() {
angular.isUndefinedOrNull = function(val) {
return angular.isUndefined(val) || val === null
};
var app = angular.module('ocrApp', ['localization', 'ngSanitize', 'ngRoute', 'ngAnimate', 'ngResource',
'ngCookies', 'ui.bootstrap', 'ui',... | JavaScript | CL | bf140d284ae2534fdb8dc79f35d452d7e99af07c901ca31d08d9a1d9f3d1f309 |
/** @wordpress */
import { __ } from "@wordpress/i18n";
import { useEffect } from "@wordpress/element";
import {
InnerBlocks,
InspectorControls,
RichText,
} from "@wordpress/block-editor";
/** components */
import TextColumnsPanel from "./panels/text-columns";
const edit = ({ className, attributes, setAttribute... | JavaScript | CL | 1c494cae33816453380534bb7f766f5a840f30edacf28c9e070ef6fe8cae9d72 |
import Vue from 'vue'
import App from './App.vue'
import Vuetify from 'vuetify'
import VueRouter from 'vue-router'
import 'vuetify/dist/vuetify.min.css'
import * as VueGoogleMaps from "vue2-google-maps";
import store from './store'
import compdefault from './components/default/Default2.vue'
import googleMap from './c... | JavaScript | CL | 2c1895e345d295215c5a2246d6561f17c1e5e6d40c49b04b7b448d66cb6cddb9 |
/**
* 思路:
* 1、先用require插件通过依赖关系压缩合并js
* 2、cssMini方法合并index.html引用的css样式
* 3、图片压缩
* 4、读取requirejsMain。js的path配置文件并存储
* */
var
rjs = require('requirejs')
,fs = require('fs')
,connect=require('gulp-connect')
,httpUrl = require('url')
,mock=require('mockjs')
,Tool = require('./tool')//md5 工具
... | JavaScript | CL | d131004a5b2141e3208463582f01a67c58970fd993b0daf83fe59d9ae8bea6b2 |
var path = require('path');
var webpack = require('webpack');
var HtmlWebpackPlugin = require('html-webpack-plugin');
var CopyWebpackPlugin = require('copy-webpack-plugin');
var TsConfigPathsPlugin = require('awesome-typescript-loader').TsConfigPathsPlugin;
const p = (f)=>path.resolve(__dirname + f)
module.exports = ... | JavaScript | CL | 3ee3be20554773001f3f7c73376e1253e3e18b9183765023dc6e56dbfbb66c69 |
/*!
* Copyright 2010 - 2021 Hitachi Vantara. All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required b... | JavaScript | CL | 56f15a23348a5da706a595493d6877d3a46423b31104887e4bb692e95e4e8bc8 |
/**
* @license
* Copyright Google LLC All Rights Reserved.
*
* Use of this source code is governed by an MIT-style license that can be
* found in the LICENSE file at https://angular.io/license
*/
import { __awaiter } from "tslib";
import { semverInc } from '../../../utils/semver';
import { ReleaseAction } from '.... | JavaScript | CL | 53b3320f94eb92ca27caa75662dae03e5baf3719d1de2214bbb63c461045ed59 |
import React from 'react'
import Link from 'next/link'
import { gql, useMutation, useApolloClient } from '@apollo/client'
import { createStyles, makeStyles } from '@material-ui/core/styles'
import Button from '@material-ui/core/Button'
import TextField from '@material-ui/core/TextField'
import Paper from '@material-ui/... | JavaScript | CL | b970aa664b1644daad0d1cf5dcdb95223397fcab73116f3f7361569485417f16 |
#!/usr/bin/env node
var fs = require('fs'),
path = require('path'),
exec = require('child_process').exec,
xcode = require('xcode'),
plist = require('plist'),
_ = require('underscore'),
util = require('util'),
xcconfig,
codeSignJSON,
xcBuildConfiguration,
nativeTarget,
projec... | JavaScript | CL | 54fb7387ee196f450d9751c19d95543801b81e86a2427644e2e1e34ba735b70a |
"use strict";
var __assign = (this && this.__assign) || function () {
__assign = Object.assign || function(t) {
for (var s, i = 1, n = arguments.length; i < n; i++) {
s = arguments[i];
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
t[p] = s[p];
... | JavaScript | CL | 6a48b3149d55316a7f954179183aebe68c220fefcb86e66c978f3809fb066e8b |
/**
* Return a integer between 0 and max
* @param max
* @returns {number}
*/
function getRandomInt(max) {
return Math.floor(Math.random() * max);
}
/**
* Resolve a promise after x ms
* @param ms
* @returns {Promise<unknown>}
*/
function delay(ms) {
return new Promise(resolve => setTimeout(resolve, ms))... | JavaScript | CL | ce47d80501b7d2f33f884c19f046bab78098b428c1bd217f31b58a56ddaec86d |
/**
* Copyright (c) Baidu Inc. All rights reserved.
*
* This source code is licensed under the MIT license.
* See LICENSE file in the project root for license information.
*
* @file friendly errors plugin
* @author wangyongqing <wangyongqing01@baidu.com>
*/
const FriendlyErrorsPlugin = require('friendly-errors... | JavaScript | CL | b3093dde304a37c961b7bfcbcd90e3ef5478e95b92be3ace07bd46ba1176c307 |
// http://paulirish.com/2011/requestanimationframe-for-smart-animating/
// http://my.opera.com/emoller/blog/2011/12/20/requestanimationframe-for-smart-er-animating
// requestAnimationFrame polyfill by Erik Möller. fixes from Paul Irish and Tino Zijdel
// MIT license
(function() {
var lastTime = 0;
var vendor... | JavaScript | CL | 2027a7df0fbbe0d6830f73a85437a49bc86f2617089c3e8f013f643979854330 |
import React from "react";
import Head from "next/head";
import Nav from "../components/Nav/nav";
import Header from "../components/Header/header";
import Production from "../components/Production/production";
import Goods from "../components/Goods/goods";
import style from '../styles/Home.module.sass'
import FeedBackS... | JavaScript | CL | ff2e442e18c552cf1d3f535e78c04cc0da1f53da01151c913cbb8d46da22b920 |
/**
* Copyright 2009 Google 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.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed t... | JavaScript | CL | 38b0087394e599fcbc2e53350a5820bc8448e2070f2c912bc56ceec7a5404ebb |
const { BotFrameworkAdapter, MemoryStorage, ConversationState, MessageFactory, ActionTypes, CardFactory, ActivityTypes } = require('botbuilder')
const restify = require('restify')
const botbuilder_dialogs = require('botbuilder-dialogs')
const dialogs = new botbuilder_dialogs.DialogSet()
let infoCard = require('./cards/... | JavaScript | CL | c8c92d9be70a3d11a90958bd88f34ede2ef3bde0175080087208c08afd335142 |
const doctrine = require('doctrine');
function getType(tag) {
if (!tag.type) {
return null;
}
if (tag.type.type === 'UnionType') {
return {
name: 'union',
value: tag.type.elements.map(element => element.name)
};
}
if (tag.type.type === 'AllLiteral') {
return {
name: 'mixed... | JavaScript | CL | 4caa688311f643089cdea2b32b8e9eb6e78868ce4183cb152d53c5ccb1b8859a |
'use strict';
import bcrypt from 'bcryptjs';
import {newMessage} from '../actions/message-actions.js';
import {createNew, setFirstPassword, incrementCreationStep, setUsername, setCreationStep} from '../actions/login-actions.js';
export default function loginHandler(command, args, props) {
// props.creatingNew check... | JavaScript | CL | d8afe12696c2918d2ea39bbc9b28f13909fa1648fcb20459a865ac4a12f022ee |
// this is just a testing room, which creates a text channel UI to test the functions of the server side rooms thing
const html = require('nanohtml')
const nanocomponent = require('nanocomponent')
const TextComposer = require('./component-text-composer')
const VideoCrossbar = require('./component-video-crossbar')
cons... | JavaScript | CL | a79525b58ec664eeb1c858e29cac2f817b6197d56711a40f2b74a7467fdac4af |
/** Messaging gateways and service base classes, which form
a network of gateways for messages to propogate across.
This module has two main types of classes:
A. Gateways: These relay messages to their connected services (children)
and also to other gateways that will also relay the message.
Gateways exist to abst... | JavaScript | CL | 2fa9f8dee17295e7aa3302d824e2b05ea317fd1032b5c3a0de0cf450602164e0 |
"use strict";
var thingsToLoad = ["images/alien.png", "images/monsterNormal.png", "images/monsterAngry.png"];
//Create a new Hexi instance, and start it.
var g = hexi(704, 512, setup, thingsToLoad);
//Set the background color and scale the canvas
//g.backgroundColor = "black";
g.scaleToWindow();
//Start Hexi
g.star... | JavaScript | CL | 51e72c38bf902090bcf12234e622220fe0482d954c03fc6b0608d3cf5b525217 |
import * as constants from 'modules/Lectures/UpdateRate/constants';
import * as actions from 'modules/Lectures/UpdateRate/actions';
import reducers from 'modules/Lectures/UpdateRate/reducers';
import * as selectors from 'modules/Lectures/UpdateRate/selectors';
import sagas from 'modules/Lectures/UpdateRate/sagas';
con... | JavaScript | CL | 498db0b97fdff9b3c33fedb73961d827da1cf852bec7a0278f1312b2a6e05539 |
app
/**
* Controller per la visualizzazione delle informazioni del progetto corrente
* @module infoProject
* @param {Object} $scope L'oggetto {@link https://docs.angularjs.org/guide/scope|$scope} indica il contesto in cui sono
* salvati i dati e valutate le espressioni
* @param {Object} $http Il servizio AngularJS... | JavaScript | CL | f7f09424107d9548ffcdef84b069b99e3fe51adb4c1b78dbfabaf0469e5aa37b |
/*
* Copyright © 2018 Lisk Foundation
*
* See the LICENSE file at the top-level directory of this distribution
* for licensing information.
*
* Unless otherwise agreed in a custom licensing agreement with the Lisk Foundation,
* no part of this software, including this file, may be copied, modified,
* propagated... | JavaScript | CL | 1eb96f1685d69970b91c4c1f8b66452015aa5b1ec8dc3d4693fa430d483177ba |
// Copyright 2020 The OpenZipkin Authors; licensed to You under the Apache License, Version 2.0.
const path = require('path');
const testMiddleware = require('./test/middleware');
module.exports = function(config) {
if (process.env.TEST_SUITE === 'nodejs') {
/* eslint-disable no-console */
console.log('WARN:... | JavaScript | CL | 42da1ffec09f3f052fe2decec559029e3b7747f35f325822195447cfbd9f88d7 |
import React from 'react';
import ReactDOM from 'react-dom';
import { expect } from 'chai';
import { spy } from 'sinon';
import { mount } from 'enzyme';
import axios from 'axios';
import MockAdapter from 'axios-mock-adapter';
import App from './App';
// MOCKS
// have to mock local storage because it's not available i... | JavaScript | CL | 282d41a32b6b42571273e0604c18c35db5ef2848588565648deeec9c9a307c4c |
/* eslint-disable import/order */
import { applyMiddleware, compose, createStore } from 'redux';
import { routerMiddleware as createRouterMiddleware } from 'connected-react-router';
import createSagaMiddleware from 'redux-saga';
import { createRootReducer, sagas } from './';
/* connected-react-router */
import { cre... | JavaScript | CL | 47bb39ec175d4c679de5c02282052c6b4761c99c000865e55760e8769f6aac0c |
import { createMemoryHistory } from 'history';
import i18n from 'i18next';
import React from 'react';
import { useIdentityContext } from 'react-netlify-identity';
import { ENABLED_LANGUAGES } from '../../constants/env';
import { render } from '../../utils/testUtils';
import LanguageRoute from '.';
jest.mock('react-n... | JavaScript | CL | b42cee0f5ac140c064cd33612b8891d0de2816a8840ce7789588b11177c49fdd |
import React from "react";
import { Timeline } from "antd";
export default function Experience() {
const windowsize =
window.innerWidth ||
document.documentElement.clientWidth ||
document.body.clientWidth;
if (windowsize > 780) {
return (
<Timeline mode="alternate">
<Timeline.Item la... | JavaScript | CL | 99e41e86c254c3628a864b254569895c04eb1a6db61731e70b675aa30247cbb2 |
const { handleResponse, successResponse, errorResponseBadRequest, errorResponseServerError } = require('../apiHelpers')
const txRelay = require('../txRelay')
module.exports = function (app) {
// TODO(roneilr): authenticate that user controls senderAddress somehow, potentially validate that
// method sig has come f... | JavaScript | CL | 9f36c4bab9ea73fb7278aa65364b79751fa50be4e9761dd2e987ebc970772008 |
// LICENSE : MIT
"use strict";
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
var RuleHelper = require("textlint-rule-helper").RuleHelper;
var japaneseRegE... | JavaScript | CL | c82b1c7cf0b3a4e2bdfabe287800957b671a74823426ac0dca497f5dd2743563 |
// Copyright 2011-2016 Global Software Innovation Pty Ltd
/*global angular, _, console, sp, Showdown, spResource, spEntity */
(function () {
'use strict';
/**
* AngularJS controller function for the entity explorer.
*
* note - if you change the parameters here then ensure you change the control... | JavaScript | CL | 0a16f7d784b9e2e2a321df7d9ef0189c48320a583679ec717977d76652671b93 |
/**
* This module will contain everything related to preloading.
*
* @module preloader
*/
var Class = require('js-oop');
var LoaderBase = require('./LoaderBase');
var UtilArrayBuffer = require('./util/UtilArrayBuffer');
var UtilHTTP = require('./util/UtilHTTP');
var FileMeta = require('./FileMeta');
/**
* Loader... | JavaScript | CL | e53d8131f9b7dcd5ee09b7dc1653e9c9572ed8eace09a1b3309feca5bcdfc168 |
import {AppRegistry} from 'react-native';
import checkForUpdates from '../libs/checkForUpdates';
import Config from '../CONFIG';
import HttpUtils from '../libs/HttpUtils';
import DateUtils from '../libs/DateUtils';
import {version as currentVersion} from '../../package.json';
import Visibility from '../libs/Visibility'... | JavaScript | CL | a7a2ee15e444c8e7cec9e8c2ff3f3b684b7e1738db12f9ea173ec4228e905cd4 |
'use strict';
let fs = require('fs');
let path = require('path');
let fse = require('fs-extra');
let moment = require('moment');
let webpack = require('webpack');
let autoprefixer = require('autoprefixer');
let CopyWebpackPlugin = require('copy-webpack-plugin');
let HtmlWebpackPlugin = require('html-webpack-plugin');
... | JavaScript | CL | f27d1c524408cd79d54a6d48f321fd429383b25012bbe9ef7461b6e2132ca857 |
const path = require('path')
module.exports = api => {
const { setSharedData, removeSharedData } = api.namespace('vue-apollo-')
api.onProjectOpen(() => {
setSharedData('urls', null)
})
function onGraphqlServerMessage ({ data }) {
if (data.vueApollo) {
setSharedData('urls', data.vueApollo.urls)
... | JavaScript | CL | 8995ce3054a671dbf690c08ff661559280bb56dba1f99d0e346dc0d8bf018c3a |
import React from "react";
function MainContent() {
return (
<main>
<h3>From this h3 element down to the footer is MainContent.js </h3>
<p>Breaking out each section into <em>components</em> (aka separate JS files)</p>
<ul>
<li>It makes our code less verbose and more easily read.... | JavaScript | CL | 6b4090ac2763f2ff16aa96d119e554af20fa8a5280e6cc6fcb6294dba275428e |
import React, { Component } from "react";
import { Segment, Header, Input, Button, Form } from "semantic-ui-react";
import web3 from "../ethereum/web3";
import ipfs from "../utils/ipfs";
import FileInstance from "../ethereum/fileInstance";
import { getMultihashFromBytes32 } from "../utils/multihash";
import EthCrypto f... | JavaScript | CL | ffe75fbd86250f4de4ae6dfc3aa0ee4a300530b0c8c50d8b30af46da0c764538 |
#if UNITY_EDITOR
#pragma strict
@script ExecuteInEditMode
var myID : int = 0;
var isActive : boolean = false;
var isSelected : boolean = false;
var myMesh : Mesh;
var tileUVs : boolean = true;
var UVW_TopBottom : boolean = false;
var UVW_LeftRight : boolean = false;
var UVW_FrontBack : boolean = false;
var textureO... | JavaScript | CL | 7e4400c81d64d9391760532353fa8ad7b42bf30ab7f2fbc88659e0e8a773fb16 |
import {Link} from "./link.js";
import marked from "../node_modules/marked/marked.min.js"
export class MarkedConverter {
/**
* Creates an instance of MarkedConfig.
* @param {(Link) => void} linkFoundCallback
*
* @memberof MarkedConfig
*/
constructor(linkFoundCallback) {
this... | JavaScript | CL | eb0ed688554d80cccbe2a3cfeac4cef55a0ba3bd6b0d72f666cc6e71cc4b7f70 |
import {useContentEditorContext} from '~/contexts/ContentEditor';
import {useFormikContext} from 'formik';
import {Constants} from '~/ContentEditor.constants';
import React from 'react';
import styles from './PublishMenu.scss';
import {DisplayAction} from '@jahia/ui-extender';
import {getButtonRenderer, isDirty} from '... | JavaScript | CL | 04a34d49220974bb4e56677fb5cbeeaa375a5c80527b24cf6f758b7e94975133 |
/*jshint -W106 */
(function() {
'use strict';
angular
.module('googlePlus')
.provider('googlePlusService', GooglePlus);
function GooglePlus (CONFIG) {
var clientid;
var scope;
var auth2;
this.setConfig = function (params){
clientid = params.cli... | JavaScript | CL | 189cfff17d57c0d2b65d2c948d68f1165ba2bfe6161b523af9e9b59766ff76b8 |
setup.createAdventure = (town, base) => {
// Tables used later
const adventure = {
location: setup.adventure.location.random(),
introduction: setup.adventure.introduction.random(),
climax: setup.adventure.climax.random(),
otherGoal: setup.adventure.otherGoal.random(),
backdrop: setup.adventure.... | JavaScript | CL | 39117a0d7f7d72c2de684d617ccda436543cf28c47772905699e2a04c8989005 |
/* jshint browser: true */
var isElement = require( "lodash/lang/isElement" );
var clone = require( "lodash/lang/clone" );
var defaultsDeep = require( "lodash/object/defaultsDeep" );
var Jed = require( "jed" );
var imageDisplayMode = require( "./helpers/imageDisplayMode" );
var renderDescription = require( "./helper... | JavaScript | CL | 2243f85de2447eb66be724333cfaa403c91ddfeb57c0cdf13d85095855b728bb |
import React from 'react';
import ReactDOM from 'react-dom';
import { BrowserRouter as Router, Route, Redirect } from "react-router-dom";
import './index.css';
// Project Component and containers
import Layout from './Layout/Layout';
import Main from './Layout/Main/Main';
import Sidebar from './Layout/Aux/Sidebar';
im... | JavaScript | CL | 5d62a353ff7eaa23f857424350ace39032afcc516cafda7669ab5042ce9ae76b |
import React, { useState } from 'react';
import styled from 'styled-components';
import axios from 'axios';
import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
// import { fab } from '@fortawesome/free-brands-svg-icons';
import { faInstagram, faFacebook, faPinterest, faTwitter } from '@fortawesome/free-br... | JavaScript | CL | 6ac8238f428c1b673ef4d11e61e409aab6fc8bfa158e70eccb4a62004ce39909 |
var quotes = [
"I think success has no rules, but you can learn a lot from failure.(Jean Kerr)",
"Do you love life ? Then do not squander time for that's the stuff5 life is made of .(Benjamin Franklin , American president )",
"To choose time is to save time .( Francis Bacon , British philosopher )",
"A man can fail... | JavaScript | CL | 941ca2c034bbc6909aa5f64ede0213fdcf98bfeaa82a00d3db11d5c6312b6e68 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.