text stringlengths 7 3.69M |
|---|
//scrolltotop
//데스크탑 스크롤투탑
const $scrollToTop = document.querySelector("#scrollToTop");
//데스트탑일떄 스크롤투탑 기능 작성
$scrollToTop.addEventListener("click", function () {
window.scroll({
top: 0,
left: 0,
behavior: "smooth",
});})
// 윈도우에 스크롤 이벤트가 발생시,
// 스크롤 위치에 따라 scrollToTop 아이콘 투명도 변경
window.addEventLis... |
const { exec } = require('child_process');
const semver = require('semver');
console.log(`executing 'ns plugin build'`);
exec('ns plugin build', (err, stdout, stderr) => {
if (err) {
// node couldn't execute the command
console.log(`${err}`);
return;
}
});
|
// component/msgbox/msgbox.js
const DEL_WIDTH = 150;
const DEL_MOVEOFFSET = 75;
var animation = wx.createAnimation({
// 动画持续时间,单位ms,默认值 400
duration: 50,
/**
* linear 动画一直较为均匀
* ease 从匀速到加速在到匀速
* ease-in 缓慢到匀速
* ease-in-out 从缓慢到匀速再到缓慢
*
* step-start 动画一开始就跳到 100% 直到动画持续时间结束 一闪而过
* ... |
const mongoose = require('mongoose')
const Schema = mongoose.Schema
const userSchema = new Schema({
name: String,
age: Number,
size: String,
park: Boolean,
houers: TimeRanges,
owner: {
name: String,
age: Number,
smoke: Boolean,
}
}) |
var CustomersComponent = require('components/data/customers');
describe('Customer API', function() {
it('makes a request to the server with search query');
it('broadcasts results from the server');
it('cancels pending request when performing a new one');
});
|
angular.module('portfolio-module')
.controller('portfolioCtrl',['$scope',function($scope){
$scope.projects=[{
"name":"Surevelox,Inc",
"picture":"images/s-img.png",
"imgUrl":"http://www.surevelox.com/",
"descripation":"Developed from Scratch using Orchard CMS, HTML, CSS, JavaScr... |
import {
SET_REGISTRATION,
GET_REGISTRATION_SAGA,
} from '../constants';
// Added for Registration
export function setRegistration(registration) {
return {
type: SET_REGISTRATION,
payload: {
registration,
},
};
}
|
import { graphql } from 'react-relay'
const getPxpsQuery = graphql`
query getPxpsQuery {
pxps {
_id
title
content
dateCreated
dateModified
}
}
`
export default getPxpsQuery
|
'use strict';
angular
.module('sbAdminApp')
.controller('listPeopleController', function ($scope, $filter, $mdDialog, RoleService, AlertService, Account, people, options, roles) {
console.log('listPeopleController');
var vm = this;
$scope.people = people;
$scope.options = option... |
/* Copyright (c) 2017 Red Hat, Inc. */
var inherits = require('inherits');
var fsm = require('../fsm.js');
var fsm_messages = require('../fsm/messages.js');
function _State () {
}
inherits(_State, fsm._State);
function _Enabled () {
this.name = 'Enabled';
}
inherits(_Enabled, _State);
var Enabled = new _Enabled(... |
(function(){
angular
.module('weatherApp')
.controller('homeCtrl', homeCtrl);
function homeCtrl($http, weatherData){
var vm = this;
vm.location = "";
vm.onSubmit = function(cityName){
weatherData
.getByCity(cityName)
.then(function(response){
v... |
$(function() {
$('#tmpSocial').share({
networks: ['facebook','twitter','pinterest','email'],
theme: 'square'
});
});
|
import { React } from 'react';
import { useHistory, Link } from 'react-router-dom';
function NavBar() {
const history = useHistory();
const AdminPanelButton = () => {
console.log('admin panel button initialized');
return (
<Link
to={'/AdminPanel'}
className="px-3 py-2 rounded-md text-sm font-medium t... |
$(document).ready(function() {
// ADJUST THE TIME OF THE TWEET TO CLIENT'S LOCAL TIMEZONE
function adjust_to_users_timezone (time) {
var new_time = time * 1000 + utc_offset * 60000; // convert to miliseconds, get
var new_date = new Date(new_time)
return new_date.toLocaleString()
}
... |
describe('Block', function(){
var b = new Block(1,2,'specBlock');
it('has a width property that can be set', function(){
expect(b.width).toBe(1);
});
it('has a height property that can be set', function(){
expect(b.height).toBe(2);
});
it('has a id property that can be set', ... |
module.exports = {
plugins: [
require('autoprefixer')({
remove: false,
browsers: [
'ios >= 8',
'ie >= 10'
]
})
]
};
|
import React from "react";
import {shallow} from "enzyme";
import Sample from "./sample";
console.debug = jest.genMockFunction();
console.log = jest.genMockFunction();
console.info = jest.genMockFunction();
console.warn = jest.genMockFunction();
console.error = jest.genMockFunction();
test('render a basic component',... |
export const storeProducts=[
{
id:1,
title:"abc",
img:"../images/image.png",
price:10,
company:"Google",
info:
"Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim ve... |
require('babel/register')(require('./babelConfig'));
require('source-map-support').install();
require('./gulpfile.jsx');
|
// Value store
var transaction;
$(document).ready(function () {
// Global variables
var pomodoro = 25, currentTime = Date.parse(new Date()), deadline, timeInterval, breakTime = 5, longBreakTime = 15, i = 0, reward = 5
// Clock setup
var clock = document.getElementById("clock-timer");
var minutesSpan = clo... |
import React from "react";
import { Link } from 'react-router-dom';
import logo from "../images/hamburguesa.svg";
import "./styles/header.css";
class Header extends React.Component {
render() {
return (
<div className="Navbar">
<div className="container-fluid">
<a className="Navbar__brand... |
/** @jsx jsx */
import { jsx, useColorMode } from "theme-ui"
import { mapEdgesToNodes } from "../utils/mapEdgesToNodes"
import { useEffect, useState } from "react"
import { useFilterState, useGameState, useUserState } from "../state"
import { graphql, navigate } from "gatsby"
import { Spinner } from "@theme-ui/componen... |
define(function(require, exports, module) {
var getImageServerUrl = require("modules/yinyuetai/imageserverurl"),
juicer = require("juicer"),
ajax = require("ajax"),
user = require("user");
juicer.register('getImageServerUrl', getImageServerUrl);
//单个好友Model对象
var Friend = Backbone.Model;
var Friends = ... |
import React, { useState } from "react";
import {inputStyle, inputWrapperStyle, buttonStyle} from './style'
function LoginPage(props) {
const [username, setUsername] = useState("")
const [password, setPassword] = useState("")
//Handles the event of the username input field changing
const usernameInput... |
const todo = (state = {}, action) => {
console.log("Todo: ", state)
switch (action.type) {
case 'ADD':
return {
...action.payload
}
default:
return state;
}
}
export const todos = (state = [], action) => {
console.log("Todos action: ", action)
console.log("Todos: ", state)
... |
import a from './a';
const isFn = (f) => typeof f === 'function';
console.log('a', a);
export default isFn; |
console.log('it\'s working, it\'s working!');
console.log(document);
window.addEventListener('DOMContentLoaded', (event) => {
console.log('DOM fully loaded and parsed');
// Model
// initialize localStorage
// load stored values or empty string into html table
// display or set player whose turn it is - x by def... |
new_element = document.createElement("script")
new_element.setAttribute("type", "text/javascript");
new_element.setAttribute("src", "js/jsencrypt/bin/jsencrypt.min.js");
document.body.appendChild(new_element)
var encrypt = new JSEncrypt({default_key_size: 1024});
public_key = encrypt.getPublicKey();
private... |
import { createStore as reduxCreateStore } from 'redux';
import fire from '../fire';
import _ from 'lodash';
const reducer = (state, action) => {
if (action.type === `INCREMENT`) {
return Object.assign({}, state, {
count: state.count + 1
});
}
if (action.type === `SET_ENTRY_TYPE`) {
return Object.assign... |
const textContainerIndexCopy =
{
"en": {
"INDEX": {}
},
"kr": {
"INDEX": {}
},
"ch": {
"INDEX": {}
},
"jp": {
"INDEX": {}
}
}
export default textContainerIndexCopy;
|
/*
Object oriented design is commonly used in video games. For this part of the assignment
you will be implementing several classes with their correct inheritance heirarchy.
In this file you will be creating three classes: GameObject, CharacterStats, Humanoid.
At the bottom of this file are 3 objects that a... |
function submitForm(id) {
var formObject = document.getElementById(id);
YAHOO.util.Connect.setForm(formObject, false);
/*when using Yahoo.Connect to upload files, a different handler needs to be used.
* 'success' is not used. instead, 'upload' is used.
* http://developer.yahoo.com/yui/connection/... |
import React from 'react';
import styled, { css } from 'styled-components';
import { boldStyles, device, visuallyHidden } from '../../../theme';
import vars from '../../../vars';
import withFiletto from '../../../components/hoc/withFiletto';
import BaseLayout from '../../../components/layout/Base';
import Head from '..... |
'use babel';
const path = require('path');
const fs = require('fs');
/**
* Gets first root folder opened in Atom
*
* @todo Support multiple root folders etc.
*/
exports.getRootFolder = () => atom.project.getPaths()[0];
/**
* Returns true if current project is RN
*/
exports.isRNProject = () => {
const rootFol... |
import React, { useEffect, useState, useContext } from "react";
import ProfileContext from "../../Context/ProfileContext";
import "./Navbar.scss";
import { Link } from "react-router-dom";
import DropdownList from "../DropdownList/DropdownList";
import DropdownMenu from "../DropdownMenu/DropdownMenu";
import api from ".... |
let vertexShader = `
attribute vec4 a_Position;
attribute vec4 a_Color;
uniform mat4 u_Transform;
uniform mat4 u_Projection;
varying vec4 v_Color;
void main(){
v_Color = a_Color;
gl_Position = u_Projection * u_Transform * a_Position;
}`;
var fragmentShader = `
precision mediump float;
varying vec4 v_Color;
void... |
/* begin copyright text
*
* Copyright © 2016 PTC Inc., Its Subsidiary Companies, and /or its Partners. All Rights Reserved.
*
* end copyright text
*/
/* jshint node: true */
/* jshint strict: global */
'use strict';
var debug = require('debug')('vxs:proxymgr');
var express = require('express');
var lodash = requi... |
import {CSSTransition} from "react-transition-group";
import React, {useEffect, useState} from "react";
import './NavBar.css';
const NavBar = () => {
let d = new Date();
const months = ["JAN", "FEB", "MAR", "APR", "MAY", "JUN", "JUL", "AUG", "SEPT", "OCT", "NOV", "DEC"];
const [fullTime, setTime] = useState... |
import React from "react";
import {
StyleSheet,
FlatList as EventList,
View,
Pressable,
TouchableOpacity
} from "react-native";
import { Searchbar } from "react-native-paper";
//components
import { SafeArea } from "../../../components/utility/SafeArea";
import { EventCardExplore } from "../../Events/componen... |
require("../config/environment")();
const { generateKeyPair } = require("crypto");
const fs = require("fs");
const path = require("path");
function writeKey(fileName, key) {
fs.writeFile(
path.join(__dirname, `../config/keys/${fileName}`),
key,
{
encoding: "utf8",
flag: "w"
},
err =>... |
import { Contact } from './contact.js';
const romain = new Contact();
romain.hello();
|
/*
Authorization: Check if user's role is the required roles or not
(In this case, it must be admin role)
*/
const CustomError = require("../utils/custom-error");
const logger = require("../utils/logger")(__filename);
module.exports = {
isAdmin: (req, res, next) => {
if (res.locals.roles.includes("admin")... |
(function() {
var projectId = 0;
var channels = [], nodes = [], nodeLookup = {}, transitions = [];
var funnel = [];
var popoverNode = null;
var scales = {x:d3.scale.linear(), y:d3.scale.linear()};
var translation = {x:0, y:0, scale:1};
var zoom = d3.behavior.zoom()
var settings = {};
window.landmark.action = {
//--... |
import React from 'react'
import { StyleSheet } from 'quantum'
import { PlusCircleIcon, QuestionIcon, DataIcon } from 'bypass/ui/icons'
const styles = StyleSheet.create({
self: {
transition: 'all 0.3s',
background: '#546e7a',
borderTop: '1px solid #ffffff',
height: '100%',
display: 'flex',
al... |
import React from 'react';
import {compose, withHandlers, withState} from 'recompose';
import DateTimePicker from 'react-datepicker';
import "react-datepicker/dist/react-datepicker.css";
export const DatePicker = compose(
withState('date', 'setDate', new Date()),
withHandlers({
handleChange: ({setDate}) => val... |
const { web3 } = require('../misc/ethereum');
const blocks = () => {
const getBlock = async (blockNumber) => {
return new Promise((resolve, reject) => {
web3.eth.getBlock(blockNumber, (err, result) => {
if(err) {
reject(err);
} else {
resolve(result);
}
})... |
/**
* Created by ThangLD5 on 12/27/2014.
*/
app.controller('KPIController', ['$scope', '$modal', 'ReportFactory', function ($scope, $modal, ReportFactory) {
$scope.$watch(function () {
return {
UsedThemes: $scope.UsedThemes,
UsedPerspectives: $scope.UsedPerspectives,
U... |
import {
FIELD_GROUP, FIELD_ORDER, FIELD_UNICODE,
FIELD_TOKENS,
INDEX_GROUP_AND_ORDER,
STORE_EMOJI,
STORE_KEYVALUE,
STORE_FAVORITES,
INDEX_TOKENS, INDEX_COUNT, INDEX_SKIN_UNICODE, FIELD_SKIN_UNICODE
} from './constants'
function initialMigration (db) {
function createObjectStore (name, keyPath, indexes... |
import io from 'socket.io-client';
import React, { Component } from 'react';
class App extends Component {
constructor (props) {
super(props);
this.state = {
messages: ['hello', 'another msg']
}
this.eventReceived = this.eventReceived.bind(this);
}
componentDidMount () {
const socket ... |
function incluirProcesso() {
var data = {
"Identificador": $("#txt-identificador").val(),
"TempoExecucao": $("#txt-tempo-execucao").val(),
"CustoPorHora": $("#txt-custo-por-hora").val(),
};
$.ajax({
type: "POST",
url: "/api/GerenciadorFila/",
data:... |
/*
A palindromic number reads the same both ways. The largest palindrome made from
the product of two 2-digit numbers is 9009 = 91 × 99.
Find the largest palindrome made from the product of two 3-digit numbers.
*/
'use strict'
// rangeByDigits :: Integer -> [Integer]
const rangeByDigits = x => {
const start = Mat... |
// Read configuration
var config = JSON.parse(require("fs").readFileSync("config.json"));
// Change names to threadIDs
config.forward.forEach(function(f) {
if(f instanceof Array) {
for(var i = 0; i < 2; i++)
if(!f[i].match(/^[0-9]{15}$/))
f[i] = config.users[f[i]];
} else {
if(!f.from.match(/^[0-9]{15}$/)... |
const mongoose = require("mongoose");
const LevelSchema = new mongoose.Schema({
name : {
type : String,
required : [true, 'Level is required'],
unique : [true, 'Level already exist']
}
});
module.exports = mongoose.model("Level",LevelSchema); |
/*@ngInject*/
export default function cellMapController($log, $interval, Data, cellMapService) {
const ctrl = this;
ctrl.$onInit = () => {
ctrl.data = cellMapService.getServiceData();
ctrl.state = {
autoplay: false,
autoGenerationIntervalMS: 1000,
autoPlayInterval: null,
stepCount:... |
import React from 'react'
import PropTypes from 'prop-types'
import { Controlled as CodeMirror } from 'react-codemirror2'
import 'codemirror/addon/hint/show-hint.css'
import 'codemirror/addon/hint/show-hint.js'
import 'codemirror/addon/hint/anyword-hint.js'
import 'codemirror/addon/hint/javascript-hint'
import 'codemi... |
import React from 'react';
import LogoImage from "../../assets/voila_logo2.png";
import UserImage from "../../assets/user.png";
import { FiLogOut } from "react-icons/fi";
import { useHistory } from "react-router";
import { Header, Options, Title, User, UserSpan } from "./styles";
import { useDispatch, useSelector } fro... |
const express = require('express');
const postDb = require('../data/helpers/postDb');
const router = express.Router()
// GET /api/posts/:userId
router.get('/:userId', (req, res) => {
const { userId } = req.params
postDb
.get(userId)
.then(posts => {
res.send(posts);
})
.catch(err => {
... |
/* globals describe it expect */
import {
colorMiddleware,
events,
frame,
motionPath,
pause,
plainShapeObject,
play,
shape,
timeline,
unitMiddleware
} from '../src'
describe('colorMiddleware', () => {
it('should be exported', () => {
expect(typeof colorMiddleware).toBe('object')
expect(c... |
(function (angular) {
'use strict';
function profile() {
var $ctrl = this;
}
angular.module('profile', ['indexProfile', 'cretate', 'domicileService', 'chat', 'chatService'])
.component('profile', {
templateUrl: 'app/Profile/Templates/profile.html',
$routeConfig: ... |
import * as React from 'react';
import { connect } from 'react-redux';
import { getsearchSingleArtist } from '../../redux/actions/artist-actions';
class UIPlaylists extends React.Component {
constructor() {
super(...arguments);
this.searchArtist = (query) => {
this.props.getsearchSingleA... |
import React from "react";
import Navbar from "react-bootstrap/Navbar";
import Nav from "react-bootstrap/Nav";
import Form from "react-bootstrap/Form";
import Col from "react-bootstrap/Col";
import { useDispatch } from "react-redux";
import { withRouter } from "react-router-dom";
import Button from "react-bootstrap/Bu... |
import bcrypt from 'bcrypt';
import dbOperations from '../database/dbOperations.js';
const userService = {
async signInUser({email,password}){
try{
const hash = await dbOperations.getHash(email);
if(await bcrypt.compare(password, hash)){
const user = awa... |
import './styles.css';
import menuElement from './menu.json';
import menuTemplate from './templates/template-items.hbs';
const refs = {
body: document.querySelector('body'),
switch: document.querySelector('#theme-switch-toggle'),
menu: document.querySelector('ul.js-menu')
}
const Theme = {
LIGHT: 'li... |
let gulp = require('gulp');
let sass = require('gulp-sass');
let browserSync = require('browser-sync');
let useref = require('gulp-useref');
let cleanCSS = require('gulp-clean-css');
let sourcemaps = require('gulp-sourcemaps');
let imagemin = require('gulp-imagemin');
gulp.task('sass', function(){
return gulp.src('r... |
import React, { Component } from 'react';
import styled from 'styled-components';
export default class Item extends Component {
render() {
const { productUrl, image, name, priceShow, } = this.props;
console.log(image);
return(
<ItemContainer>
<Img src={image} alt... |
"use strict";
exports.VirtualRow = exports.VirtualRowProps = exports.viewFunction = void 0;
var _inferno = require("inferno");
var _vdom = require("@devextreme/vdom");
var _utils = require("../utils");
var _row = require("./row");
var _virtual_cell = require("./virtual_cell");
var _excluded = ["cellsCount", "chi... |
var photos = new Array();
window.onload = function() {
for (var i = 0; i < 10; i++) {
photos.push(new Object());
}
populate();
console.log(photos);
for (i=0; i<10; i++){
var image = document.createElement("img");
image.id = i;
image.setAttribute('src', photos[i].source);
image.style.cssText = 'heig... |
// pages/chat/hat.js
const { getTime } = require('./utils/formatTime');
const socket = require('./utils/rtcSocket').callSocket;
const log = require('./utils/log');
const { seatLog } = require('./utils/request');
const app = getApp();
let heartbeatTimer = null;
let callTimer = null;
Page({
data: {
imUserSig: null,... |
var appRouter = function(app) {
//var mymodel = require("./../models/sampleModel.js");
/*
mymodel.maluko('vei')
app.get("/", function(req, res) {
res.send("Hello World");
});
*/
/* app.get("/account", function(req, res) {
var accountMock = {
"username": "nraboy",
"password": "1234",
... |
import React from "react";
import { Helmet } from "react-helmet";
import Navigation from "./elements/Navigation";
const NotFound = () => {
return (
<div>
<Navigation />
<Helmet>
<meta name="robots" content="noindex" />
</Helmet>
<main className="page landing-page">
... |
fbFilters.filter('reviewCycle', ['Util', function(Util) {
return function(input, reviewCycleId) {
if (!Array.isArray(input)) {
return [];
} else if (!reviewCycleId || !Util.isInteger(reviewCycleId)) {
return input;
} else {
return input.filter(function (item) {
return item.cycle... |
/*******************************************************************************************************
sertal.ch file upload operations twitter-bootstrap and Live HTML template for the following features
- Template event handling for the file upload import operations
Date: 18-June-2013
Author:
*************... |
import React, { useState, useEffect } from "react";
import "./Card.css";
import illus1 from "./../../assets/illus1.png";
import illus2 from "./../../assets/illus2.png";
import illus3 from "./../../assets/illus3.png";
function Card({ activeIndex }) {
const content = [
{
title: "Title1",
description:
... |
celebinoApp.controller('acessController', function (UserService, $scope, $state, $mdToast) {
// Login user
$scope.login = function(){
UserService.loginUser($scope.input)
.then(function (response) {
// Chamado quando a resposta contém status de sucesso.
// Exibir toas com mensagem de suc... |
require("dotenv").config();
const mongoose = require("mongoose");
const host = process.env.DB_HOST;
const username = process.env.DB_USER;
const password = process.env.DB_PASSWORD;
//mongodbのポートの読み込みと、mongoDBのコレクション名(task-manager-api)をつける
mongoose.connect(`mongodb+srv://${username}:${password}@${host}/todoist`, {
us... |
// production keys
//DEV.JS
module.exports = {
googleClientID:process.env.GOOGLE_CLIENT_ID,
googleClientSecret: process.env.GOOGLE_CLIENT_SECRET,
msidClientID: process.env.MSID_CLIENT_ID,
msidClientSecret: process.env.MSID_CLIENT_SECRET,
mongoURI:process.env.MONGO_URI,
cookieKey: process.env.COO... |
import { Card, CardItem, Body, } from 'native-base';
import React, { Component } from 'react';
import {
StyleSheet,
Text,
View,
Image,
TouchableOpacity
} from 'react-native';
import { connect, useSelector } from 'react-redux';
import { SECONDARY_COLOR } from '../../utils/constants';
let UserProfile = (props... |
import React from 'react';
import styled, { css } from 'styled-components';
import { device, imagesStyles } from '../../../theme';
import PhotoDisclaimer from '../../../components/common/PhotoDisclaimer';
import Container from '../../../components/layout/Container';
import { postPhotoLink } from '../../../pages/post-ph... |
const env = process.env;
// const url = env.APP_PROTOCOL;
module.exports = {
devServer: {
proxy: {
'/secure': {
target: env.VUE_APP_SERVER_URL,
ws: false,
changeOrigin: true
},
'/auth': {
target: env.VUE_APP_... |
var sendmail_8h =
[
[ "mutt_invoke_sendmail", "sendmail_8h.html#a2d1312bbee49dda97d3c94837c4af6ab", null ]
]; |
import { dispatch } from '../dispatcher';
export default {
create() {
dispatch({type: 'sample/create'});
}
} |
import { expect } from 'chai';
import * as sinon from 'sinon';
import { Game } from '../../../../src/core';
describe('Game', () => {
describe('General', () => {
it('should be importable', () => {
expect(Game).to.be.a('function');
});
it('should be constructable', () => {
expect(new Game()).t... |
/* begin copyright text
*
* Copyright © 2016 PTC Inc., Its Subsidiary Companies, and /or its Partners. All Rights Reserved.
*
* end copyright text
*/
/* jshint node: true */
/* jshint strict: global */
'use strict';
var graceTime;
var dbHandler = null;
var debug = require("debug")("vxs:billable");
var tableName =... |
import { combineReducers } from "redux";
import QuizDataReducer from "./QuizDataReducer";
export const reducers = combineReducers({
quizData: QuizDataReducer
});
|
const Blog = require('../models/Blog.js')
module.exports = {
index: (req,res) => {
Blog.find({}, (err, blogs) => {
if (err) return console.log(err)
res.json(blogs)
})
},
show: (req, res) => {
Blog.findById(req.params.id, (err, blog) => {
var comment = blog.comments.id(req.params.cId)
... |
require('./routine.buildWithWebpack')({minify: true});
|
DV.model.Document = function(viewer){
this.viewer = viewer;
this.currentPageIndex = 0;
this.offsets = [];
this.baseHeightsPortion = [];
this.baseHeightsPortionOffsets = [];
this.paddedOffsets = [];
this.originalPageText = {};
thi... |
const issueLabelsHandler = require('./src/issueLabelsHandler');
const calculatePriority = require('./src/calculatePriority');
const addLabel = require('./src/addLabel');
module.exports = (robot) => {
const events = ['issues.labeled', 'issues.unlabeled', 'issues.opened'];
return robot.on(events, issueLabelsHan... |
const ErrorModule = require('../error');
const AppError = ErrorModule.AppError;
const AppErrorTypes = ErrorModule.AppErrorTypes;
module.exports = {};
/**
* Serialize a Sequalize Model with only the serializable fields
* that the model exposes.
* @param model - The model to serialize
* @returns {Object}
*/
const ... |
import React from 'react'
import { Button } from './Button'
import './Header.css'
import '../App.css'
import cv from '../Rainie_CV.pdf'
function Header () {
const showCV = () => {
window.open(cv)
}
return (
<div className='header-container'>
<video src='/motionplaces fire-Oct2018.mp4' autoPlay loop... |
import * as GLOBALS from './globals';
import { settings } from './userData';
import * as utilities from './utilities';
class Ticker {
constructor() {
this.tickerWrapper = document.createElement('div');
this.tickerWrapper.classList.add('ticker-wrapper');
this.ticker = document.createElement('div');
t... |
var app = new PIXI.Application(800, 600, { backgroundColor: 0xEEEEEE });
document.body.appendChild(app.view);
// create a background...
var background = PIXI.Sprite.fromImage('./assets/2.jpg');
background.width = app.screen.width;
background.height = app.screen.height;
// add background to stage...
app.stage.addChild(... |
frappe.provide("jasper");
jasper.show_banner = function(msg) {
$banner = $('<div class="toolbar-banner">'+msg+'<a class="close">×</a></div>')
.prependTo($('header .navbar'));
$("body").css({"padding-top": "70px"});
$banner.find(".close").click(function() {
$(".toolbar-banner").toggle(false);
$("body").... |
import React from "react";
export default function NavBar({ setCuisine }) {
return (
<h1
style={{
backgroundColor: "CornflowerBlue",
fontSize: "4vh",
border: "0px",
margin: "0px",
padding: "2px",
textAlign: "center",
}}
>
<ul
style={{
... |
/*
* notFoundController.js
*
* Copyright (c) 2019 HEB
* All rights reserved.
*
* This software is the confidential and proprietary information
* of HEB.
*/
'use strict';
/**
* The controller for the Not found page.
*
* @author vn70529
* @since 2.29.0
*/
(function () {
angular.module('productM... |
(function($){
$(document).ready(function() {
function reloadScripts() {
$("#research-book").empty();
var str = `<!-- Scripts for Flipbook -->
<script type="text/javascript" src="./JS/lib/jquery.min.1.7.js"></script>
<script type="text/javascript" src="... |
var _ = require("underscore");
var winston = require("winston");
var LastFmDao = (function () {
var lastfmNode;
function LastFmDao(lfmNode) {
lastfmNode = lfmNode;
}
LastFmDao.prototype.getSession = function (token, callback) {
if (!token) {
callback("Invalid token", null);
return;
}
lastfmNode.ses... |
goog.provide('animatejs.Frame');
/**
* Frame defines a state of properties at certain time
* @param {number} at defines the time value from the beginning of the animation
* @param {Object} properties current properties values (key=value pairs)
* @param {Array.<string>} changedProperties names of properties chang... |
import { compose } from 'react-apollo'
import Component from './StoryGroupSelector.component.js'
import query from '../../../apollo/queries/organization'
import { withRouter } from 'next/router'
import storyQuery from '../../../apollo/queries/story'
import editStory from '../../../apollo/mutations/editStory'
let Expor... |
'use strict';
var lib = require('./lib');
var argSetMulti = function(opt, arg, key, map) {
if(opt.multiArg) {
let existing = map.get(key);
if(!existing) {
map.set(key, [arg]);
}
else if(existing instanceof Array) {
existing.push(arg);
}
}
else {
map.set(key, arg);
}
}
var ... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.