code
stringlengths
2
1.05M
var __extends = (this && this.__extends) || function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; function __() { this.constructor = d; } d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); }; define(["require", "exports", "./Container", "../../tweents/Ti...
const regAttr = /="*'*\{*([_a-z\-0-9$]+)}*'*"*/; const regStart = /^\[/; const $ = window.rb.$; /** * Finds attribute linked elements on the first element in collection. * @function external:"jQuery.fn".attrLinked * @param {String} attributeSelector Attribute selector pattern to search for. ("[aria-controls="${id}"...
import React, { Component } from 'react' ; import { connect } from 'reslice' ; import Footer from './footer' ; import AddTodo from './addtodo' ; import TodoList from './todolist' ; /** * Top-level component. Embeds the AddTodo, TodoList and Footer * (application) components. These are each passed their slice of * ...
'use strict'; Object.defineProperty(exports, '__esModule', { value: true }); var _slicedToArray = (function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s...
/** * @fileoverview Rule to flag use of Thai character * @author Chang, Che-Jen */ 'use strict'; // ------------------------------------------------------------------------------ // Requirements // ------------------------------------------------------------------------------ const rule = require('../../../lib/ru...
// Copyright 2009 the Sputnik authors. All rights reserved. // This code is governed by the BSD license found in the LICENSE file. /*--- info: > The production CharacterClass :: [ [lookahead \notin {^}] ClassRanges ] evaluates by evaluating ClassRanges to obtain a CharSet and returning that CharSet and th...
/* eslint-env mocha */ var assert = require('assert') var resolveEnv = require('./') var cases = [ ['Simple test', 'Simple test', {}], ['Hello $NAME!', 'Hello world!', { NAME: 'world' }], ['[ $a1, $a2 ]', '[ 4, 8 ]', { a1: '4', a2: '8' }], ['http://$HOST:$PORT/', 'http://google.com:80/', { HOST: 'google.com',...
import { inverse } from 'dummy/helpers/inverse'; import { module, test } from 'qunit'; module('Unit | Helper | inverse'); // Replace this with your real tests. test('it works', function(assert) { let result = inverse([42]); assert.ok(result); });
var PRAHA = {coordinates: [50.051611, 14.407032], type:"Point"} module.exports = function(map) { var geocoder = new google.maps.Geocoder(); var addrInputEl = document.getElementById('geoJumper'); addrInputEl.addEventListener('keydown', function codeAddress(ev) { if (ev.keyCode === 13) { var address = docum...
'use strict'; module.exports = function (grunt) { var files = [ "jsyg-wrapper/JSYG-wrapper.js", "jsyg-point/JSYG.Point.js", "jsyg-vect/JSYG.Vect.js", "jsyg-matrix/JSYG.Matrix.js", "jsyg-strutils/JSYG-strutils.js", "jsyg-utils/JSYG-utils.js", "jsyg-events...
'use babel'; import RspecCopy from '../lib/main'; describe('RunInIterm', function() { let workspaceElement; beforeEach(function() { workspaceElement = atom.views.getView(atom.workspace); atom.packages.activatePackage('run-in-iterm'); }); describe('when the run-in-iterm:run event is triggered', funct...
// Upload Demo // ----------------------------------- (function(window, document, $, undefined){ $(function () { 'use strict'; // Initialize the jQuery File Upload widget: $('#fileupload').fileupload({ // Uncomment the following to send cross-domain cookies: //xhrF...
import nearestVector from 'ml-nearest-vector'; /** * Calculates the distance matrix for a given array of points * @ignore * @param {Array<Array<number>>} data - the [x,y,z,...] points to cluster * @param {function} distance - Distance function to use between the points * @return {Array<Array<number>>} - matrix wi...
/* * File: jquery.dataTables.rowReordering.js * Version: 1.2.1. * Author: Jovan Popovic * * Copyright 2013 Jovan Popovic, all rights reserved. * * This source file is free software, under either the GPL v2 license or a * BSD style license, as supplied with this software. * * This source file is distr...
// nehan.tip.js // Copyright(c) 2014-, Watanabe Masaki // license: MIT /** plugin name: tip description: create link that shows popup message when clicked. tag_name: tip close_tag: required attributes: - title: tip title example: <tip title="this is tip title">this text is popuped when c...
// import third-party CSS import 'bootstrap/dist/css/bootstrap.css'; import 'bootstrap/dist/css/bootstrap-theme.css'; import 'font-awesome/css/font-awesome.min.css'; import 'react-flex/index.css'; // import our own main CSS import 'src/views/styles/styles.scss'; // import JS // import 'bootstrap'; // bootstrap JS...
var React = require('react'); var Recommend = require('./recommend/index'); var ItemList = require('./itemList/index'); var Header = require('./header/index'); var Promo = require('./promo/index'); class Floor extends React.Component { render() { var { imgUrl, title, originPrice, price } = this.props;...
import React from 'react'; import { connect } from 'react-redux'; import { importLocations } from 'lib/actions/library'; const ImportPanel = ( props ) => { const onImport = () => props.importLocations( this.textInput.value ); const saveRef = input => this.textInput = input; return ( <div className="import fo...
const chai = require('chai'), sinon = require('sinon'), sinonChai = require('sinon-chai'), mockRequire = require('mock-require'); mockRequire('jquery', { ajax: (args) => { args['success']('proper response'); } }); chai.use(sinonChai); const $ = require('jquery'), requester = require('...
/*! * Angular Material Design * https://github.com/angular/material * @license MIT * v1.0.0-rc5-master-6b1d758 */ (function( window, angular, undefined ){ "use strict"; /** * @ngdoc module * @name material.components.subheader * @description * SubHeader module * * Subheaders are special list tiles that del...
(function(){ var app = angular.module('postal', []); app.controller('ResultsController',function(){ this.items = saves; }); //I think this is the code needed to read in data from a JSON file, it doesn't work locally because of browser security. ReQuires a small change to the html ...
import React from 'react'; import createSvgIcon from './utils/createSvgIcon'; export default createSvgIcon( <path d="M10 12c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zM6 8c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm0 8c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm12-8c1.1 0 2-.9 2-2s-.9-2-2-2-2 .9-2 2 .9 2 2 2zm-4 8...
/* * MomboBox * https://github.com/luv2code/MomboBox * * Copyright (c) 2012 Matthew Taylor * Licensed under the MIT license. */ (function($, window) { var defaults = { data: [], templates: { buttonTemplate: '<button class="mombobutton">↓</button>', itemTem...
export default function isNumber(e) { return typeof e === 'number'; }
//var pppp = require("printer"); console.debug("iniciando Appp"); function ValidURL(str) { var expression = /[-a-zA-Z0-9@:%_\+.~#?&//=]{2,256}\.[a-z]{2,4}\b(\/[-a-zA-Z0-9@:%_\+.~#?&//=]*)?/gi; var pattern = new RegExp(expression); // fragment locater if(!pattern.test(str)) { alert("Please enter a valid UR...
import React from 'react' import GraphiQL from 'graphiql' import { buildClientSchema, introspectionQuery, isType, GraphQLObjectType } from 'graphql' const { POSTGRAPHQL_CONFIG } = window /** * The standard GraphiQL interface wrapped with some PostGraphQL extensions. * Including a JWT setter and live schema udpate c...
/* *Chris Samuel * ksamuel.chris@icloud.com * * October 5, 2015 * * Filename : Footer.js * * */ import React from 'react'; import {Link} from 'react-router'; import FooterStore from '../stores/FooterStore' import FooterActions from '../actions/FooterActions'; class Footer extends React.Component { constructor(...
const BaseBundle = require('./base'); class TransactionBundle extends BaseBundle { constructor (config) { super(config); this.get('/', this.index.bind(this)); this.post('/', this.create.bind(this)); } async index (ctx) { let entries = await this.ledger.getTransactions(); return { entries };...
var Type = require("@kaoscript/runtime").Type; module.exports = function() { function $format(message) { if(arguments.length < 1) { throw new SyntaxError("Wrong number of arguments (" + arguments.length + " for 1)"); } if(message === void 0 || message === null) { throw new TypeError("'message' is not nulla...
'use strict'; var agitoHttpRedirection = function() { var action = {}; /** * @type {String} */ action.name = 'http-redirection'; /** * @type {String} */ action.protocol = 'http'; /** * @param {http.ClientRequest} request - The HTTP request * @param {http.ServerResponse} response - The...
import React from 'react'; import { withTheme } from '@material-ui/core'; const MuiColorChit = (props) => { let { theme } = props; let chitStyle = { flexGrow: 0, flexShrink: 0, width: props.size === "small" ? '16px' : '24px', height: props.size === "small" ? '16px' : '24px', ...
'use strict'; import React from 'react'; import tweenState from 'react-tween-state'; import decorators from './decorators'; import assign from 'object-assign'; import ExecutionEnvironment from 'exenv'; React.initializeTouchEvents(true); const addEvent = function(elem, type, eventHandle) { if (elem == null || typeo...
/** * @author maurobuselli@gmail.com */ (function () { 'use strict'; angular.module('AngularPanelsApp.pages.form', ['ui.select', 'ngSanitize']) .config(routeConfig); /** @ngInject */ function routeConfig($stateProvider) { $stateProvider .state('form', { url: '/form', t...
var basePath = '/api'; var app = angular.module('adminApp'); app.controller('AccountController', [ '$routeParams', '$location', 'AuthService', 'ReferenceResource', 'AccountResource', 'RelationResource' , function($routeParams, $location, AuthService, ReferenceResource, AccountResource, RelationResource) { ...
/* eslint-disable */ /** * This script will extract the internationalization messages from all components and package them in the translation json files in the translations file. */ const fs = require('fs'); const nodeGlob = require('glob'); const transform = require('babel-core').transform; const animateProgress...
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); let _ = require('lodash'); let async = require('async'); const pip_services3_commons_node_1 = require("pip-services3-commons-node"); const pip_services3_commons_node_2 = require("pip-services3-commons-node"); const pip_services3_facade_node_1 ...
import 'ui/stringify/editors/color.less'; import _ from 'lodash'; import IndexPatternsFieldFormatProvider from 'ui/index_patterns/_field_format/field_format'; import colorTemplate from 'ui/stringify/editors/color.html'; export default function ColorFormatProvider(Private) { const FieldFormat = Private(IndexPatternsF...
#!/usr/bin/node // 09-timer.js //var count = 0; var timer; console.log('start...'); timer = setInterval(loop, 500); timer.unref(); function loop() { //count++; console.log('i will loop forever! times:', Date.now()); /* if(count === 10) { global.clearInterval(timer); console.log('enough! good bye!'); ...
/*global app*/ var log = require('bows')('session-users'); var Users = require('client/js/models/users'); var UserView = require('client/js/views/users/view'); var UsersArea = require('client/js/views/users/area'); var config = require('client/js/helpers/clientconfig'); module.exports = UsersArea.extend({ initialize...
'use strict'; /** * An asynchronous bootstrap function that runs before * your application gets started. * * This gives you an opportunity to set up your data model, * run jobs, or perform some special logic. */ const path = require('path'); const fs = require('fs'); const _ = require('lodash'); module.exports...
/* * @lc app=leetcode.cn id=1025 lang=javascript * * [1025] 除数博弈 */ // @lc code=start /** * @param {number} N * @return {boolean} */ var divisorGame = function (N) { return N % 2 == 0; }; // @lc code=end
import NextImage from 'next/image' import src from '../../public/test.jpg' export default function Image() { return <NextImage src={src} /> }
/* ***** BEGIN LICENSE BLOCK ***** * Distributed under the BSD license: * * Copyright (c) 2012, Ajax.org B.V. * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * Redistributions of sou...
/* =============================================================================================== Unify Project Homepage: unify-project.org License: MIT + Apache (V2) Copyright: 2011, Sebastian Fastner, Mainz, Germany, http://unify-training.com ==================================================================...
/** * "Language Key" : { * "languageDirection": "rtl or ltr" // for example english is left to right but arabic is right to left * "servicesUrl": // where we pull the services data from. This can be a local (ex. js/a.json) or an external url (ex. http://my-website/a.json) * "languageName": // The la...
// controls the loading dots and bar angular.module('homepageApp').controller('LoadingCtrl', LoadingCtrl); LoadingCtrl.$inject = ['$scope', '$rootScope', 'uiCalendarConfig', '$timeout']; function LoadingCtrl($scope, $rootScope) { // using the angular loading bar rootscope broadcast to know when all HTTP requests ...
/*jslint browser: true*/ /*global $,THREE,PLANE_LENGTH,PLANE_WIDTH,PADDING,getRandomInteger */ function HeroObject() { 'use strict'; var hero = {}, heroGeometry = {}, heroMaterial = {}; heroGeometry = new THREE.CylinderGeometry(0, 2, 5, 10); heroMaterial = new THREE.MeshLambertMaterial({ color: 0xE91E63, ...
'use strict'; var grunt = require('grunt'); /* ======== A Handy Little Nodeunit Reference ======== https://github.com/caolan/nodeunit Test methods: test.expect(numAssertions) test.done() Test assertions: test.ok(value, [message]) test.equal(actual, expected, [message]) test.notEqual(actua...
/* * Responsible for all display, page or functional control on the status page. * * - Setting refresh timers. * - Rendering HTML for table. * - Logic for action buttons. */ jQuery(document).ready(function ($) { // Get extension background page for use within the code. var backgroundPage = chrome.extensio...
//@flow import React, { Component } from 'react' import './DataForm.css' type Props = {} type State = { value: string, } class DataForm extends Component<Props, State> { state = { value: '', } handleChange = (ev: SyntheticEvent<HTMLInputElement>) => { this.setState({ value: ev.currentTarget.value })...
import { Badge } from 'antd'; export default Badge;
$(document).ready(function() { //questions var questions = [{ 'questionNum': 1, 'question': 'When was the first mobile phone, Motorola Dyna TAC 8000X manufactured?', 'answer': ['1981', '1983', '1995', '1991'], 'correctAnswer': '1983', }, { 'questionNum': 2, ...
const TextPopupWindow = require("./TextPopupWindow.js") const getRefs = require("../../utils/getRefs.js") const cssClass = require("../../utils/cssClass.js") const TextPad = require("../../TextPad.js") class LinkBlotProperties extends TextPopupWindow { constructor(window, document, mycelium) { super(wi...
var sinon = require('sinon'); var assert = require('assert'); var Listen = require('listen-js'); describe('Device Manager', function (){ it('isMobile() should return false if nav user agent is empty string', function (){ var userAgentMock = ''; var eventManagerCreateTargetStub = sinon.stub(Lis...
const MessagingResponse = require('twilio').twiml.MessagingResponse; const response = new MessagingResponse(); const message = response.message(); message.body('Store Location: 123 Easy St.'); message.media('https://demo.twilio.com/owl.png'); console.log(response.toString());
/* Copyright (c) 2015 Giffo. All rights reserved.*/ var fs = require("fs"); var path = require("path"); var sep = path.sep; //author ~ giffo, dated: 10/10/2013 /** * just load the files, parse the data and then use a simple binary search to fetch the country */ var GeoIP = module.exports = (function(dir) { i...
module.exports = Dependency1; function Dependency1() { } Dependency1.prototype.testMethod = function (callback) { setTimeout(function () { callback(null, 'success'); }, 2000); };
$("document").ready(function() { var location = window.location.href.split("?id="); var api_base = "http://192.168.160.39/api/Movies/"; var viewMovies = new function(){ var self = this; var movieID = location[1]; self.movie = ko.observableArray(); getMovie = function () { var final_link = api_base + movie...
KISSY.add(function (S, Node, ScrollView, ScrollbarPlugin) { function has3d() { var el = Node.all('<p></p>').prependTo(document.body), has3d; // Add it to the body to get the computed style. el.css('transform', "translate3d(1px,1px,1px)"); has3d = el.css('transform'); ...
(function(angular, autobahn, console){ var services = angular.module('ngWAMP', []); services.factory('wamp', function($q) { var globalDeferred; function WampClient() { this.connections = {}; } WampClient.prototype = { _newConnection:...
module.exports = [{ def:'Spacer', name:'Spacer', loadID:3, relations:{ li:[{ other:'Faction_9', goodwill:-100, hostile:true },{ other:'Faction_4', goodwill:-80 },{ other:'Faction_0', goodwill:0 ...
// Description: // This kata is designed to test your ability to extend the functionality of built-in ruby classes. In this case, we want you to extend the built-in Array class with the following methods: square(), cube(), average(), sum(), even() and odd(). // Explanation: // square() must return a copy of the arra...
require('module-alias/register'); var generators = require('yeoman-generator'); var _ = require('lodash'); var mkdirp = require('mkdirp'); var ifNotDatabase = require('/utils/if-not-database'); var writeScript = require('/utils/write-script'); var sharedInput = require('/utils/shared-input'); var wipeableGenerator = ...
const Addon_Id = "treeview"; const item = GetAddonElement(Addon_Id); Sync.TreeView = { strName: "Tree", List: item.getAttribute("List"), nPos: 0, WM: TWM_APP++, Depth: GetNum(item.getAttribute("Depth")), Collapse: GetNum(item.getAttribute("Collapse")), Exec: function (Ctrl, pt) { const FV = GetFolderView(Ctr...
/** * @ignore * TabBar for KISSY. * @author yiminghe@gmail.com */ var Toolbar = require('toolbar'); var util = require('util'); /** * tab bar container for tab tabs.xclass: 'tabs-bar'. * @class KISSY.Tabs.Bar * @extends KISSY.Toolbar */ var TabBar = Toolbar.extend({ beforeCreateDom: function (renderData) ...
/** * Owl carousel * @version 2.0.0 * @author Bartosz Wojciechowski * @license The MIT License (MIT) * @todo Lazy Load Icon * @todo prevent animationend bubling * @todo itemsScaleUp * @todo Test Zepto * @todo stagePadding calculate wrong active classes */ ;(function($, window, document, undefined) { var dra...
/* Eventually by HTML5 UP html5up.net | @n33co Free for personal and commercial use under the CCA 3.0 license (html5up.net/license) */ (function() { "use strict"; // Methods/polyfills. // classList | (c) @remy | github.com/remy/polyfills | rem.mit-license.org !function(){function t(t){this.el=t;for(var n=...
import React, { PropTypes } from 'react' import '../../styles/core.scss' import GlobalMenu from 'components/GlobalMenu/GlobalMenu' // Note: Stateless/function components *will not* hot reload! // react-transform *only* works on component classes. // // Since layouts rarely change, they are a good place to // leverage ...
import { extend } from 'lodash-es' import cheerio from 'cheerio' import serialize from 'dom-serializer' var $ = null function _createElement(data) { var options = {} if (data.root && data.root.options) { options = data.root.options } return extend({ attribs: {}, children: [], parent: null, ...
exports.TYPE_WARNING = 1; exports.TYPE_ERROR = 2; exports.ERRORS = { BASIC_VALIDATION_ERROR: 1000, MISSING_ACL: 1100 }; exports.InputError = function (errorType, errorCode) { if (typeof errorType !== 'number') { throw "errorType has to be an integer"; } if (typeof errorCode !== 'number' ...
import React, {PropTypes} from 'react'; export default class InfiniteScroll extends React.Component { static propTypes = { bufferPx: PropTypes.number, callback: PropTypes.func, autoFirstLoad: PropTypes.bool, style: PropTypes.object }; static defaultProps = { bufferPx...
/** * Created by lindem on 12/4/13. */ module.exports = function (grunt) { "use strict"; grunt.initConfig({ ts: { // use to override the default options, See: http://gruntjs.com/configuring-tasks#options // these are the default options to the typescript compiler for grunt-ts:...
define('views/modifyView', ['text!views/templates/modify.html'], function(template) { "use strict"; return Backbone.View.extend({ tagName: 'div', className: 'modalDialog visible', error: '', initialize: function(){ }, events: { 'click #closeBtn'...
(function(){ 'use strict'; var garage = require('./garage'); var util = require('util'); var events = require('events'); function GarageMonitor(){ this.interval = setInterval(function(){ garage.isOpen(function(err, open){ this.emit('update', open); }....
me.CustomImageLayer = me.ImageLayer.extend({ init: function(x, y, name, width, height, image, z, ratio) { this._super(me.ImageLayer, "init", [name, width, height, image, z, ratio]); this.x = x; this.y = y; }, draw: function(renderer, rect) { var context = renderer.getContext(); context.save(); context...
var level2_menu = { preload: function() { }, create: function() { game.input.onTap.add(this.start, this); var style = { font: "30px Arial", fill: "#ffffff" }; // Adding a text centered on the screen var text = this.game.add.text(game.world.centerX, game.world.centerY - ...
export function isUndefined(value) { return typeof value === "undefined"; } export function isString(value) { return typeof value === "string"; } export function isEmptyObject(value) { return !Object.keys(value).length; } export function isObject(value) { return value instanceof Object; } //# sourceMapp...
/* * regexp-inverse * https://github.com/dploeger/regexp-inverse * * Copyright (c) 2016 Dennis Ploeger * Licensed under the MIT license. */ 'use strict'; function RegExpInverse(pattern, flags) { this.regExp = new RegExp(pattern, flags); } RegExpInverse.prototype.exec = function (text) { var matches = ...
import Parser from "../parser"; import { types as tt } from "../tokenizer/types"; const pp = Parser.prototype; export default function(parser) { if (parser.__tryExpressionPluginInstalled) return; parser.__tryExpressionPluginInstalled = true; // c/p parseTryStatement pp.parseTry = function(node, isExpression) ...
//! moment.js //! version : 2.15.2 //! authors : Tim Wood, Iskren Chernev, Moment.js contributors //! license : MIT //! momentjs.com ;(function (global, factory) { typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() : typeof define === 'function' && define.amd ? define(fac...
//@flow const API_URL = "https://api.dribbble.com/v1/", ACCESS_TOKEN = "8d9bd601f9461955b330d88c44f2930257364de98cddc2064d93cdcb300cb91d"; function fetchData(URL) { return fetch(URL, { headers: { "Authorization": "Bearer " + ACCESS_TOKEN } }).then((response) => response.json())...
/*! jQuery UI - v1.10.4 - 2014-05-23 * http://jqueryui.com * Copyright 2014 jQuery Foundation and other contributors; Licensed MIT */ jQuery(function(e){e.datepicker.regional.el={closeText:"Κλείσιμο",prevText:"Προηγούμενος",nextText:"Επόμενος",currentText:"Τρέχων Μήνας",monthNames:["Ιανουάριος","Φεβρουάριος","Μάρτιος"...
//Products.html function addProduct(index) { var elems = $(".product" + index+""); var productName = elems[0].innerHTML; var orderProducts = $("strong.orderName"); var exist = false; for (var i=0;i<orderProducts.length && !exist;i++){ if(productName===orderProducts[i].innerHTML){ ...
'use strict'; angular.module('copayApp.controllers').controller('preferencesUnitController', function($rootScope, $scope, configService, go) { var config = configService.getSync(); this.unitName = config.wallet.settings.unitName; this.unitOpts = [ // TODO : add Satoshis to bitcore-wallet-client for...
// LinkJS // ====== // pfraze 2012 function noop() {} var Link = {};
/** * Created by invader on 06.07.16. */ import React from 'react' import s from './benefits.pcss' import {Grid, Row, Col} from 'react-flexgrid' import FaDesktop from 'react-icons/lib/fa/desktop' import FaPaperPlane from 'react-icons/lib/fa/paper-plane' import FaAnchor from 'react-icons/lib/fa/anchor' import FaCog...
/* HTML Import plugin Adapted from systemjs/plugin-css https://github.com/systemjs/plugin-css */ if (typeof window !== 'undefined') { System.import('webcomponentsjs/webcomponents-lite.min'); exports.build = false; exports.fetch = function(load) { return importHref(load); }; exports.instantiate =...
global.ArrayUtility = (function() { "use strict"; function remove(array, element) { let index = array.indexOf(element); (index >= 0) ? array.splice(index, 1) : array; } function addAll(target, array) { each(array, function(item) { target.push(item); }); } return { remove: remove, addA...
var formidable = require('formidable'), http = require('http'), sys = require('sys'); http.createServer(function(req, res) { if(req.url == '/upload' && req.method.toLowerCase() == 'post') { // parse a file upload var form = new formidable.IncomingForm(); form.parse(req, function(error, fields, fi...
Ext.define('EmergencePullTool.view.Main', { extend: 'Ext.container.Container', xtype: 'app-mainview', requires: [ 'Ext.layout.container.Border', 'EmergencePullTool.view.ChangesGrid', 'EmergencePullTool.view.DiffPanel' ], layout: { type: 'border' }, items: [{...
(function(MainService) { MainService.module .factory('RegistrationService', function($http) { return { register: function(registrationId) { $http({ headers: { 'Content-Type': 'application/json' ...
var app = angular.module('myApp', []); app.controller('myController', function($scope){ $scope.filename = ''; $scope.fileCount = -1; }); app.directive('stackchart', function(){ return{ restrict: 'E', replace: true, templateUrl: 'partials/stackchart.html', scope:{ ...
// Import modules // environment variables require('dotenv-extended').load(); // handle dates var moment = require('moment'); // bot sdks var builder = require('botbuilder'); var azure = require('botbuilder-azure'); var restify = require('restify'); // Setup Restify Server var server = restify.createServer(); server.l...
'use strict'; import parser from '../../index'; import tape from 'tape'; import util from 'util'; export let parse = (input, transform) => { return parser(transform).process(input).result; }; export let test = (spec, input, callback) => { var tree; let result = parse(input, (selectors) => {tree = select...
(function(globals){ "use strict"; globals._ = globals._ || {}; var __ = globals._; var display = function() { var found = __.dom.display("404-id"); if (!!found) { __.footer.displayChildFooter(); } }; var hide = function() { __.dom.hide("404-id"); }; var initialized = false; var ini...
angular.module('feedback', []) .directive('feedbackcount', function(FeedbackService) { return { restrict: 'A' , link: function(scope, element, attrs) { FeedbackService.get_feedback_count(); var feedback = FeedbackService.feedback; var type = $(element).attr("sh...
/** * p5.js example of HackforPlay * (c) teramotodaiki 2016 * MIT License */ // See ---- http://p5js.org var p5 = require('https://cdnjs.cloudflare.com/ajax/libs/p5.js/0.5.3/p5.min.js'); new p5(); pixelDensity(1); Hack.view = canvas; resizeCanvas(720, 400); module.exports = function (tileSize) { w = tileSize; ...
import * as React from 'react'; import createSvgIcon from './utils/createSvgIcon'; export default createSvgIcon( <path d="M3 3h8v8H3zm0 10h8v8H3zM13 3h8v8h-8zm0 10h8v8h-8z" /> , 'GridViewSharp');
var path = require('path'); var gulp = require('gulp'); var eslint = require('gulp-eslint'); var excludeGitignore = require('gulp-exclude-gitignore'); var mocha = require('gulp-mocha'); var istanbul = require('gulp-istanbul'); var nsp = require('gulp-nsp'); var plumber = require('gulp-plumber'); var coveralls = require...
/* globals describe, it */ const assert = require('assert'); const App = require('../src/app'); describe('App', function () { it('exists', function () { assert.equal(typeof App, 'function'); }); });