code stringlengths 2 1.05M |
|---|
cl = function(msg){
if (window.console && console.log) {
console.log(msg);
}
};
ll = function(msg, prepend, type, append){
if (window.console && console.log) {
var d = performance.now();
prepend ? '': prepend = '';
console.log('=>'+prepend+': '+msg);
if(!type) type = ... |
module.exports = function(mongoose) {
var config = require(process.cwd() + '/config');
var sha256 = require('sha256');
return function(req, res) {
if(req.method == "GET") {
if(req.session.user) {
res.json(req.session.user);
console.log("User logged in: ", req.session.user.username);
} else {
... |
/* eslint-disable ember/no-mixins, ember/no-new-mixins */
import { module, test } from 'qunit';
import { setupTest } from 'ember-qunit';
import Route from '@ember/routing/route';
import ApplicationRouteMixin from 'ember-simple-auth/mixins/application-route-mixin';
module('ApplicationRoute', function(hooks) {
setupT... |
/* Jison generated parser */
var parser = (function(){
var parser = {trace: function trace() { },
yy: {},
symbols_: {"error":2,"pattern":3,"route":4,"EOF":5,"parts":6,"part":7,"OPEN_OPTIONAL":8,"CLOSE":9,"OPEN_PARAM":10,"substrings":11,"STRING":12,"$accept":0,"$end":1},
terminals_: {2:"error",5:"EOF",8:"OPEN_OPTIONAL",... |
var webpack = require('webpack');
var path = require('path');
var BUILD_DIR = path.resolve(__dirname, '../techbot_web/static');
var APP_DIR = path.resolve(__dirname, 'src/app');
var config = {
entry: APP_DIR + '/index.jsx',
output: {
path: BUILD_DIR,
filename: 'bundle.js'
},
resolve: {
... |
/**
* PipelineTimer
* Keeps track of the time left for a HIT and updates the page as necessary.
* onExpiration will be de-thunked when the timer expires.
*/
PipelineTimer.create = function(serverTimestamp, counterId, totalSeconds, endTime, onExpiration) {
var offset = new ClientOffset(serverTimestamp);
OnLoadH... |
webpackJsonp([60335399758886],{199:function(t,e){t.exports={data:{site:{siteMetadata:{title:"Ted"}}},layoutContext:{}}}});
//# sourceMappingURL=path----39eaccc68746c5e5b853.js.map |
module.exports = {
onInput: function (input) {
this.state = {
heading: input.heading || "",
message: input.message || "",
colors: input.colors || []
};
}
};
|
import { setData } from '@progress/kendo-angular-intl';
setData({
name: "es-HN",
identity: {
language: "es",
territory: "HN"
},
territory: "HN",
numbers: {
symbols: {
decimal: ".",
group: ",",
list: ";",
percentSign: "%",
... |
import React from 'react';
import ReactTestUtils from 'react-addons-test-utils';
import Pagination from '../src/Pagination';
describe('<Pagination>', () => {
it('should have class', () => {
const instance = ReactTestUtils.renderIntoDocument(
<Pagination>Item content</Pagination>
);
assert.ok(React... |
var gulp = require('gulp'),
sass = require('gulp-sass'),
gp_concat = require('gulp-concat'),
gp_uglify = require('gulp-uglify'),
rename = require('gulp-rename'),
minifyCss = require('gulp-minify-css'),
rev = require('gulp-rev'),
replace = require('gulp-replace'),
notify = require('gulp-notify'... |
var BlockView = Backbone.View.extend({
tagName : 'div',
initialize : function() {
this.render();
},
render: function() {
this.$el.attr({
class : 'block gimmick-' + this.model.get('gimmick'),
'data-gimmick' : this.model.get('gimmick')
});
},
collide: function() {
if (this.model.get('isDead'))
... |
import {
moduleForComponent,
test
} from 'ember-qunit';
moduleForComponent('plottable-chart', {
unit: true
// specify the other units that are required for this test
// needs: ['component:foo', 'helper:bar']
});
test('it renders', function(assert) {
assert.expect(2);
// creates the component instance
... |
/** @license MIT License (c) copyright 2014 original authors */
/** @author Karolis Narkevicius */
var path = require('path');
var knox = require('knox-s3');
var when = require('when');
var thunkify = require('thunkify');
var cp = require('fs-cp');
module.exports = function (config) {
return new S3(config);
};
/**... |
define( "add", [
"../core/vi"
], function( vi ) {
/**
* func Add
* @param {Int} a
* @param {Int} b
* @return {Int} a+b
*/
vi.add = function( a, b ) {
return a + b;
};
return vi.add;
});
|
/**
* Error parser for apeman.
* @module apemanerror
* @version 5.3.2
*/
'use strict';
var _assign = require('babel-runtime/core-js/object/assign');
var _assign2 = _interopRequireDefault(_assign);
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
var apemanerror = ... |
dojo.provide("t.unit.plugins.dojox.module");
try{
dojo.require("t.unit.plugins.dojox.timing.test");
}
catch(e) {
doh.debug(e);
}
|
import { moduleForModel, test } from 'ember-qunit';
moduleForModel('task', 'Unit | Model | task', {
// Specify the other units that are required for this test.
needs: ['model:unfuddle-project']
});
test('it exists', function(assert) {
let model = this.subject();
// let store = this.store();
assert.ok(!!mode... |
/**
* Factory based on OS output
*
*/
var OS = require( "os" );
//Webcam types
var FSWebcam = require( "./webcams/FSWebcam.js" );
var ImageSnapWebcam = require( "./webcams/ImageSnapWebcam.js" );
var WindowsWebcam = require( "./webcams/WindowsWebcam.js" );
//Main singleton
var Factory = new function() {
... |
// "C" is for cookie, that's good enough for me.
function getCookie(cname) {
var name = cname + "=";
var ca = document.cookie.split(";");
for (var i = 0; i < ca.length; i++) {
var c = ca[i];
while (c.charAt(0) == " ") c = c.substring(1);
if (c.indexOf(name) == 0) return c.substring(name.length, c.len... |
export default class Player extends Phaser.Sprite {
constructor(game) {
super(game, 0, 0, 'hero');
// enable physics for the player
this.game.physics.arcade.enableBody(this);
this.scale.setTo(1.1);
this.body.collideWorldBounds = true;
this.game.physics.arcade.enable(... |
//GET /quizes/question
exports.question = function(req, res){
res.render('quizes/question', {pregunta: 'Capital de Italia'});
};
//GET quizes/answer
exports.answer = function(req, res){
if(req.query.respuesta === 'Roma'){
res.render('quizes/answer', {respuesta: 'Correcto'});
}else{
res.render('quizes/answer', ... |
(function () {
window._paddingsTest = function () {
var test = function (padding) {
for (var len = 0; len <= 32; len++) {
var initialArray = random.default.getUint8Array(len);
var padded = padding.pad(initialArray, 16, random.default);
var padCount = padding.unpad(padded);
if (padCount == -1) {
... |
#!/usr/bin/env node
const NumberUtil = require("../js/lib/number-util.js");
var Z80_assemble = require('../js/Z80/assembler');
var MZ_TapeHeader = require('../js/lib/mz-tape-header');
var changeExt = require('../js/lib/change-ext.js');
var fs = require('fs');
var getPackageJson = require("./lib/get-package-json");
var ... |
var path = require('path');
var gulp = require('gulp');
var tsc = require('gulp-tsc');
var uglify = require('gulp-uglify');
var concat = require('gulp-concat');
var compass = require('gulp-compass');
const CONF_PATH = 'conf/';
const SRC_PATH = 'frontend_src/';
const PUBLIC_PATH = 'public/';
gulp.task('tsc', function(... |
/**
* Copyright (c) 2015-present, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree. An additional grant
* of patent rights can be found in the PATENTS file in the same directory.
*
* @provides... |
[25, "hi", true]
|
import Page from '../layouts/page';
import MainContent from '../layouts/main-content';
import PersonHeader from '../components/person-header';
import LevelContainer from '../components/level-container';
export default () => (
<Page>
<PersonHeader />
<MainContent>
<LevelContainer />
</MainContent>
... |
_tmpl.link_entity = function( entity, tagName, returnHTML, count ){
if( !entity )
return false
if( tagName && typeof tagName == 'object' )
return _tmpl.link_entity(
entity,
tagName['tagName'] || null,
tagName['returnHTML'] || null,
tagName['count'] || null
)
tagName = tagName || 'a'
re... |
/* eslint-disable no-await-in-loop */
const assert = require('assert');
const TestUtils = require('../utils');
const query1 = `SELECT 1 AS id, 'blue' AS color`;
function wait(ms) {
return new Promise((resolve) => setTimeout(resolve, ms));
}
async function testBatchToCompletion(config) {
const utils = new TestUti... |
import { h } from 'omi';
import createSvgIcon from './utils/createSvgIcon';
export default createSvgIcon(h("path", {
d: "M22 4H2v16h20V4zm-2 4l-8 5-8-5V6l8 5 8-5v2z"
}), 'MailSharp'); |
/* file : collection-test.js
MIT License
Copyright (c) 2016 Thomas Minier
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy... |
/*
* Kendo UI v2015.1.408 (http://www.telerik.com/kendo-ui)
* Copyright 2015 Telerik AD. All rights reserved.
*
* Kendo UI commercial licenses may be obtained at
* http://www.telerik.com/purchase/license-agreement/kendo-ui-complete
* If you do not own a commercial license, this file shall be governed by the trial licen... |
import {
VFadeTransition,
VSlideXTransition
} from '~components/transitions'
export default {
name: 'v-progress-linear',
components: {
VFadeTransition,
VSlideXTransition
},
props: {
active: {
type: Boolean,
default: true
},
buffer: Boolean,
bufferValue: Number,
err... |
"use strict";
var fs = require("fs");
var path = require("path");
var Sequelize = require("sequelize");
const appRoot = require('app-root-path');
const config = require(`${appRoot}/lib/config`)();
const sequelize = new Sequelize(config.db);
var db = {};
fs
.readdirSync(__dirname)
.filt... |
import test from 'ava'
import configureStore from 'redux-mock-store'
import { mount } from 'enzyme'
import { createElement } from 'react'
import Home from '../../src/containers/home'
const mockStore = configureStore()
test('home', t => {
const store = mockStore()
const wrapper = mount(createElement(Home, {
s... |
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.default = function (calc, node, precision) {
var str = stringify(node, precision);
if (node.type === "MathExpression") {
// if calc expression couldn't be resolved to a single value, re-wrap it as
// a calc()
str =... |
import { assert, expect } from 'chai';
import 'angular';
import 'angular-mocks/angular-mocks';
import '../src/component';
describe('User factory', ()=>{
var Client;
beforeEach(angular.mock.module('component'));
beforeEach(angular.mock.inject(function(_client_) {
Client = _client_;
}));
it('sou... |
export const flatTree = (tree, getBody = node => node.body) => {
let flatList = [];
[].concat(tree).forEach(node => {
const body = getBody(node);
if (body && body.length) {
flatList = flatList.concat(node, flatTree(body, getBody));
} else {
flatList.push(node);
... |
var People = function(names) {
this.allNames = [];
names.forEach(function(name) {
name = name.charAt(0).toUpperCase() + name.slice(1);
this.allNames.push(name);
}.bind(this));
};
People.prototype.getNames = function() {
return this.allNames;
};
People.prototype.sort = function() {
this.allNames.sort... |
var Watcher = require('./watcher')
var middleware = require('./middleware')
var http = require('http')
var connect = require('connect')
exports.serve = serve
function serve (builder, options) {
options = options || {}
console.log('Serving on http://' + options.host + ':' + options.port + '\n')
var watcher = op... |
import EmberRouter from '@ember/routing/router';
import config from './config/environment';
const Router = EmberRouter.extend({
location: config.locationType,
rootURL: config.rootURL
});
Router.map(function() {
this.route('home', { path: '/' });
this.route('apple');
this.route('banana');
this.route('cocon... |
var backgrounds = [
"url('http://res.cloudinary.com/dklyjqkxa/image/upload/v1476149119/google_hq_azlr3e.jpg')",
"url('http://res.cloudinary.com/dklyjqkxa/image/upload/v1476149119/apple_hq_bmqqhh.jpg')",
"url('http://res.cloudinary.com/dklyjqkxa/image/upload/v1476149119/microsoft_hq_c88f8g.jpg')",
"url('http://r... |
search_result['1024']=["topic_0000000000000254.html","SystemManagementController.UpdateBadge Method",""]; |
import React from 'react';
import styles from './button.css';
let Button = React.createClass({
render() {
return (
<div className={styles.container}>
<button className={styles.button}>Click me!</button>
</div>
);
}
});
React.render(<Button />, document.getElementById('content'));
|
/**
* Copyright (c) 2010 Zef Hemel <zef@zef.me>
*
* Permission is hereby granted, free of charge, to any person
* obtaining a copy of this software and associated documentation
* files (the "Software"), to deal in the Software without
* restriction, including without limitation the rights to use,
* copy, modify,... |
Package.describe({
summary: 'Meteor package to wrap TopoJSON: An extension to GeoJSON that encodes topology'
});
Package.on_use(function(api) {
api.export('topojson');
api.add_files('meteor-topojson.js', 'server');
api.add_files('topojson.js', 'client');
});
Package.on_test(function (api) {
api.use(['topojs... |
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
//# sourceMappingURL=property.js.map |
describe('ds.utils.loadGoogleMapsAPI()', function() {
this.timeout(20000);
it('should load google maps api', function(done) {
ds.utils.loadGoogleMapsAPI().done(function(google) {
expect(google).to.be.an('object');
done();
});
});
it('should not make a http reque... |
import { Resource } from '../api-resource';
import logger from 'kolibri.lib.logging';
const logging = logger.getLogger(__filename);
export default class FacilityUserResource extends Resource {
static resourceName() {
return 'facilityuser';
}
getCurrentFacility() {
const promise = new Promise(
res... |
(function(){dust.register("red-tpl.tl",body_0);function body_0(chk,ctx){return chk.write("<div class=\"col-md-8\"><div class=\"row\"><div class=\"col-md-22 col-md-offset-1 red subpagecontrolhighlight\"> </div></div></div>");}return body_0;})(); |
module.exports = (config) => {
const defaults = {
isWarmingUp: (event) => event.source === 'serverless-plugin-warmup',
onWarmup: (event) => console.log('Exiting early via warmup Middleware'),
waitForEmptyEventLoop: null
}
const options = Object.assign({}, defaults, config)
return ({
before: (h... |
'use strict'
var Transform = require('stream').Transform
, util = require('util')
, Segment = require('./segment')
, Message = require('./message')
, utils = require('./utils')
// MLP end frames
var FS = String.fromCharCode(0x1c)
, CR = String.fromCharCode(0x0d)
exports.Message = Message
exports.Segment = ... |
'use strict';
import imageSearchPage from '../../pageobjects/image-search.page';
module.exports = function() {
this.Given(/^I am on the google image search page$/, () => {
imageSearchPage.open();
});
// Enter term in search: google.js
this.Given(/^I press the image search button$/, () => {
... |
/**
* The MIT License (MIT)
*
* Copyright (c) 2022 Losant IoT, Inc.
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to... |
import React from 'react'
import { mount, shallow } from 'enzyme'
import { Dummy } from './utils'
import { withHandlers } from '..'
describe('withHandlers', () => {
it('passes immutable handlers', () => {
const enhance = withHandlers({
handler: () => () => null,
})
const EnhancedDummy = enhance(Dum... |
var lexer = require('../../index').lex.lexer;
var parser = require('../../index').parse.parser;
var $ = require('../$');
var testParser = function(stream) {
var result = parser.parseStream(stream);
return result.body[0].expression;
};
exports.empty = function(test) {
var result = testParser(lexer.lex("(... |
var locale = require('relative-time-format/locale/sr')
module.exports = {
locale: locale.locale,
// Standard styles.
long: locale.long,
short: locale.short,
narrow: locale.narrow,
// Quantifier.
quantify: locale.quantify
} |
var baseIteratee = require('./_baseIteratee'),
baseSortedIndexBy = require('./_baseSortedIndexBy');
/**
* This method is like `_.sortedLastIndex` except that it accepts `iteratee`
* which is invoked for `value` and each element of `array` to compute their
* sort ranking. The iteratee is invoked with one argumen... |
ThinMint.Mixin.Paginate = function() {
var _super = {};
_super.init = ThinMint.Util.callback( this.init );
_super.getPage = ThinMint.Util.callback( this.getPage );
_super.setPage = ThinMint.Util.callback( this.setPage );
_super.getPages = ThinMint.Util.callback( this.getPages );
_super.setPages = ThinMint... |
const expect = require('chai').expect;
const PragmaThanksSpreadsheet = require('../src/PragmaThanksSpreadsheet');
describe('PragmaThanksSpreadsheet', () => {
describe('#isEmpty', () => {
it('returns true when spreadsheet is empty', () => {
const spreadsheetContent = [];
const sheet = new PragmaThank... |
import React, { PropTypes } from 'react';
import styled from 'styled-components';
import TextInfo from '../TextInfo';
import CardImage from '../CardImage';
import { Row, Col, Card, Avatar } from 'antd';
import { Panel } from 'react-bootstrap';
/*
const CardImage = styled.div`
img {
display: block;
height:20... |
var names = [ 'Whiskers', 'Athena', 'Sir Theodore Tibblesworth', 'Rex' ];
function keyOf (name) { return name.toLowerCase().replace(/\W+/g, '-') }
module.exports = function (db) {
setInterval(function () {
var lives = Math.floor(Math.random() * 9 + 1);
var name = names[Math.floor(Math.random() * na... |
'use strict';
var CanvasRenderer = require('./main');
CanvasRenderer.prototype._prepareImages = function () {
// Creating the list of images
var imagesToPrepare = [];
var symbolList = this._extractor._symbolList;
var symbols = this._extractor._symbols;
for (var s = 0; s < symbolList.length; s += 1) {
var sym... |
module.exports = {
'1.train.spikes': {
display: '01',
indicator: 'OGB-1',
area: 'V1',
source: 'Theis et al., 2016'
},
'2.train.spikes': {
display: '02',
indicator: 'OGB-1',
area: 'V1',
source: 'Theis et al., 2016'
},
'3.train.spikes': {
display: '03',
indicator: 'GCaMP6... |
var etc=require("./etc.js"),
msgtype=require("./msgtype.js");
function constructMessage(type,args){
var len=6+args.map(function(a){return 4+a.length;}).reduce(function(a,b){return a+b;},0);
var buf=new Buffer(len);
//console.log("constructing message with len",len)
buf.writeUInt32BE(len,0);
buf.writeUInt8(typ... |
cssx(
@media screen and (min-width: `minWidthForMediaQuery`px) {
`a().reduce(b)` {
`getProperty();`: `a + b / c`%;
}
}
) |
const fs = require('fs');
const path = require('path');
const EventEmitter = require('events');
const cors = require('cors');
const bodyParser = require('body-parser');
const compression = require('compression');
const cookieParser = require(... |
Template.orderListItem.helpers({
//statusName: function(status) {
// var names = {
// ongoing: '进行',
// finished: '完成',
// canceled: '终止'
// };
// return names[status] || '未知';
//},
statusColor: function () {
var colors = {
'进行': 'bg-primary',
'完成': 'bg-success',
'终止'... |
import React from "react";
import { shallow } from "enzyme";
import TableRow from "./TableRow";
describe("TableRow", () => {
it("matches snapshot", () => {
const aTableRow = shallow(<TableRow />);
expect(aTableRow).toMatchSnapshot();
});
});
|
//Get /question
exports.question = function (req, res, next) {
var answer = req.query.answer || '';
res.render('quizzes/question', {question: "Capital de Italia", answer: answer});
};
//GET /check
exports.check = function(req,res, next) {
var answer = req.query.answer || '';
var result = ((answer === 'Roma') ? '... |
import * as util from "./util";
const path = require("path");
/**
* Creates a toc object
* @param {Array} items All items of the toc
* @param {Array} root Only the root items
* @return {Object} Toc object
*/
const createToc = function (items, root) {
if (items == null) items = [];
if (r... |
/* eslint no-console:0 */
var Hapi = require('hapi'),
Path = require('path'),
Swig = require('swig'),
Routes = require('./routes');
Swig.setDefaults({ cache: false });
var server = new Hapi.Server();
server.connection({ port: 3000 });
server.views({
engines: { swig: Swig },
path: Path.joi... |
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the Lic... |
var crime = {
"type": "FeatureCollection",
"features": [
{
"type": "Feature",
"geometry": {
"type": "Point",
"coordinates": [ -5.921416,54.579826 ]
},
"properties": {
"Month":"2016-08",
"Location":"On or near ",
"Crime type":"Bicycle theft"
}
},
{
"type": "... |
/*
Copyright (c) 2012. Adobe Systems Incorporated.
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 source code must retain the above copyright notice,
this list of con... |
import pt from './pt/pt'
const messages = {
pt
}
export default messages
|
import { validate, URL_REX, TITLE_REX } from '../validator';
import db from '../connection';
import getUserById from '../loaders/get-user-by-id';
import sanitizeHtml from 'sanitize-html';
export default async (userId, rawTitle, rawLink, rawBody) => {
const body = sanitizeHtml(rawBody, {
allowedTags: ['b', 'i', '... |
'use strict';
//NOTE:Methods used to do HTTP requests. To use an HTTP request listed here just call the method
angular.module('announcements').factory('Announcements', ['$http',
function($http) {
var methods = {
getAllAnnouncements: function(announcements) {
return $http.get('/api/announcements', ... |
//document.write("It works.");
document.write(require("./content.js")); |
/*
Copyright (c) 2003-2014, CKSource - Frederico Knabben. All rights reserved.
For licensing, see LICENSE.md or http://ckeditor.com/license
*/
CKEDITOR.plugins.setLang( 'find', 'ro', {
find: 'Găseşte',
findOptions: 'Find Options',
findWhat: 'Găseşte:',
matchCase: 'Deosebeşte majuscule de minuscule (Match c... |
/**
* @copyright
* The MIT License (MIT)
*
* Copyright (c) 2014 Cosmic Dynamo LLC
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitatio... |
import React from 'react';
import { Link } from 'react-router-dom';
export default class Combatant extends React.Component {
render() {
return (
<div key={ this.props.id }
className={this.props.index === 0 ? 'col-xs-6 col-sm-6 col-md-5 col-md-offset-1' : 'col-xs-6 col-sm-6 col-... |
/*
* This file is part of the React Redux starter repo.
*
* (c) Magnus Bergman <hello@magnus.sexy>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
import React, { PropTypes } from 'react'
import { Provider } from 'react-redux'
imp... |
var assert = require('chai').assert;
var ss = require('../../../script_sanitize');
var describe = require('mocha/lib/mocha.js').describe;
var it = require('mocha/lib/mocha.js').it;
var script_sanitize = ss.sanitize;
module.exports = function () {
describe("attributes", function () {
it('should replace the attrib... |
import resource from 'resource-router-middleware';
import model from '../models/users';
export default ({ config, db }) => resource({
/** Property name to store preloaded entity on `request`. */
id : 'user',
mergeParams: true,
/** For requests with an `id`, you can auto-load the entity.
* Errors terminat... |
;(function(dragula){
'use strict';
angular.module('angular-dragula', [])
.factory('ngDragulaFactory', ['$timeout', function($timeout){
function get(name){
return $timeout(function(){
if(name === 'get'){
throw new Error('RESERVE_WORD');
}
if(this[name]){... |
/*!
*
* Super simple WYSIWYG editor v0.8.19
* https://summernote.org
*
*
* Copyright 2013- Alan Hong and contributors
* Summernote may be freely distributed under the MIT license.
*
* Date: 2021-10-13T19:41Z
*
*/
(function webpackUniversalModuleDefinition(root, factory) {
if(typeof exports === 'object' && ... |
angular.module('contatooh').factory('Contato',function($resource){
return $resource('/contatos/:id');
}); |
import { MJMLElement } from 'mjml-core'
import React, { Component } from 'react'
const tagName = 'mj-table'
const parentTag = ['mj-column', 'mj-hero-content']
const endingTag = true
const defaultMJMLDefinition = {
content: '',
attributes: {
'align': 'left',
'cellpadding': '0',
'cellspacing': '0',
'... |
/*
* Guerilla
* Copyright 2015, Yahoo Inc.
* Copyrights licensed under the MIT License.
*
* Retrieves the Logcat from an Android device.
*/
var path = require('path');
var fs = require('fs-extra');
function Logcat (context, exec) {
this.context = context;
this.exec = exec;
this.file = path.join(context.outpu... |
(function () {
define(["jquery", "datatables", "datatables-tabletools", "datatables-colvis"], function ($) {
var achilles_heel = {};
achilles_heel.render = function (datasource) {
$('#reportAchillesHeel svg').remove();
$.ajax({
type: "GET",
url: getUrlFromData(datasource, "achil... |
scouts = new Meteor.Collection('scouts', {
schema: new SimpleSchema({
userId: {
type: String,
index: 1,
unique: true
},
scoutId: {
type: String,
optional: true
},
scoutStatusCode: {
type: String,
optional: true
},
scoutLand: {
type: S... |
/* global angular: false */
/**
* WinchJS Factory - Maintain state of winch
*
* Written by Sean Cady
*/
angular.module('winch')
.factory('winchFactory', [function() {
//Basic API structure
var API = {
_img: {}
};
/**
* Register an image
* @param URL
* @param load
* @para... |
exports.up = (knex, Promise) => {
return knex.schema.createTable('users', (table) => {
table.increments('id')
table.string('user_id')
// table.string('username')
table.string('server_id')
table.integer('quest_xp')
table.integer('message_xp')
table.dateTime('last_msg')
})
}
exports.down... |
'use strict';
/**
* Module dependencies.
*/
var coursesPolicy = require('../policies/courses.server.policy'),
courses = require('../controllers/courses.server.controller');
module.exports = function (app) {
// Articles collection routes
app.route('/api/courses').all(coursesPolicy.isAllowed)
.get(courses.l... |
/* global Flash */
export default class BlobViewer {
constructor() {
this.switcher = document.querySelector('.js-blob-viewer-switcher');
this.switcherBtns = document.querySelectorAll('.js-blob-viewer-switch-btn');
this.copySourceBtn = document.querySelector('.js-copy-blob-source-btn');
this.simpleView... |
/**
* Created by khuongdt on 12/07/2015.
* Author : khuongdt
* Copyright @ 2015 by OneSoft.,JSC
*/
goog.provide('com.onesoft.livetube.entity.SCLogout');
goog.require('bigfox.Global');
goog.require('bigfox.core.base.BaseMessage');
goog.require('com.onesoft.livetube.base.LiveTag');
com.onesoft.livetube.entity.SCL... |
/* jslint node: true */
'use strict';
var cfg = require('../../../config.json');
exports.validNick = function(nickname) {
var regex = /^\w*$/;
return regex.exec(nickname) !== null;
};
// determine mass from radius of circle
exports.massToRadius = function (mass) {
return 4 + Math.sqrt(mass) * 6;
};
//... |
export const CODE_LENGTH = 12
export const ALL_DIGITS = /^\d+$/
export const normalizedValue = (value) => {
const { length } = value
const systemDigitMissing = !value.startsWith('0')
return length == CODE_LENGTH - 1 && systemDigitMissing ? '0' + value : value
}
export const passesCheckDigitVerification = (val... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.