commit
stringlengths
40
40
old_file
stringlengths
4
264
new_file
stringlengths
4
264
old_contents
stringlengths
0
3.26k
new_contents
stringlengths
1
4.43k
subject
stringlengths
15
624
message
stringlengths
15
4.7k
lang
stringclasses
3 values
license
stringclasses
13 values
repos
stringlengths
5
91.5k
7e4320b1bb12ed9ada7c758ff2c9401b1149f7ae
modules/lists/list-empty.js
modules/lists/list-empty.js
// @flow import * as React from 'react' import {View, Text} from 'react-native' type Props = { mode: 'bug' | 'normal', } export class ListEmpty extends React.PureComponent<Props> { render() { return ( <View> <Text>List is empty</Text> </View> ) } }
// @flow import * as React from 'react' import {NoticeView} from '@frogpond/notice' type Props = { mode: 'bug' | 'normal', } export class ListEmpty extends React.PureComponent<Props> { render() { return <NoticeView text="List is empty" /> } }
Change the listempty component to be a noticeview
Change the listempty component to be a noticeview
JavaScript
agpl-3.0
StoDevX/AAO-React-Native,StoDevX/AAO-React-Native,StoDevX/AAO-React-Native,StoDevX/AAO-React-Native,StoDevX/AAO-React-Native,StoDevX/AAO-React-Native,StoDevX/AAO-React-Native,StoDevX/AAO-React-Native,StoDevX/AAO-React-Native
d13b0473314ff148146f00b60c8a3fa4dd3b26f7
tabcounter.js
tabcounter.js
'use strict'; var tabRemoved = false; browser.browserAction.setBadgeBackgroundColor({color: "gray"}); browser.tabs.onActivated.addListener(refreshCounter); browser.tabs.onCreated.addListener(refreshCounter); browser.tabs.onAttached.addListener(refreshCounter); browser.tabs.onRemoved.addListener(() => tabRemoved = tru...
'use strict'; var tabRemoved = false; browser.browserAction.setBadgeBackgroundColor({color: "gray"}); browser.tabs.onActivated.addListener(refreshCounter); browser.tabs.onRemoved.addListener(() => tabRemoved = true); initCounter(); function initCounter() { browser.tabs.query({currentWindow: true}).then(tabs => up...
Fix tab counting when moving tab between windows
Fix tab counting when moving tab between windows
JavaScript
mit
cakebaker/yet-another-tab-counter
db884e3373d9ad0440473e292dd41d41ccf93c99
test/vendor.js
test/vendor.js
;(function() { var MODULES_PATH = 'https://a.alipayobjects.com/static/arale/' if (location.href.indexOf('/~lifesinger/') > 0) { MODULES_PATH = 'http://' + location.host + '/~lifesinger/seajs/spm/modules/' } // Ref: https://github.com/miohtama/detectmobile.js function isMobile() { return Math.max(...
;(function() { var MODULES_PATH = 'https://a.alipayobjects.com/static/arale/' if (location.href.indexOf('/~lifesinger/') > 0) { MODULES_PATH = 'http://' + location.host + '/~lifesinger/seajs/spm/modules/' } // Ref: https://github.com/miohtama/detectmobile.js function isMobile() { return Math.max(...
Exclude pad from mobile device
Exclude pad from mobile device
JavaScript
mit
kaijiemo/seajs,miusuncle/seajs,miusuncle/seajs,LzhElite/seajs,yuhualingfeng/seajs,121595113/seajs,sheldonzf/seajs,FrankElean/SeaJS,13693100472/seajs,PUSEN/seajs,LzhElite/seajs,treejames/seajs,kuier/seajs,judastree/seajs,lianggaolin/seajs,FrankElean/SeaJS,moccen/seajs,sheldonzf/seajs,seajs/seajs,liupeng110112/seajs,imcy...
7a933da519e0cd556ea2e79b380978b8df9787e1
node-tests/blueprints/test-helper-test.js
node-tests/blueprints/test-helper-test.js
'use strict'; var setupTestHooks = require('ember-cli-blueprint-test-helpers/lib/helpers/setup'); var BlueprintHelpers = require('ember-cli-blueprint-test-helpers/lib/helpers/blueprint-helper'); var generateAndDestroy = BlueprintHelpers.generateAndDestroy; describe('Acceptance: ember generate and destroy test-h...
'use strict'; var blueprintHelpers = require('ember-cli-blueprint-test-helpers/helpers'); var setupTestHooks = blueprintHelpers.setupTestHooks; var emberNew = blueprintHelpers.emberNew; var emberGenerateDestroy = blueprintHelpers.emberGenerateDestroy; var chai = require('ember-cli-blueprint-test-helpers/chai'); var e...
Use alternative blueprint test helpers
tests/test-helper: Use alternative blueprint test helpers
JavaScript
mit
ember-cli/ember-cli-legacy-blueprints,ember-cli/ember-cli-legacy-blueprints
bb400919494f2805e6a4d6087602a47866d362d4
pages/article.js
pages/article.js
import React from 'react' import { connect } from 'react-redux'; import { compose } from 'redux'; import Link from 'next/link'; import app from '../components/App'; import { load } from '../redux/articleDetail'; export default compose( app((dispatch, {query: {id}}) => dispatch(load(id))), connect(({articleDetail}...
import React from 'react' import { connect } from 'react-redux'; import { compose } from 'redux'; import Link from 'next/link'; import app from '../components/App'; import { load } from '../redux/articleDetail'; export default compose( app((dispatch, {query: {id}}) => dispatch(load(id))), connect(({articleDetail}...
Remove “back to list” link because it is not accurately “back to list”
Remove “back to list” link because it is not accurately “back to list”
JavaScript
mit
cofacts/rumors-site,cofacts/rumors-site
8cea0ec1551b4b51123a6e9c25ab6fe1823c8d1e
database/seeds/users.js
database/seeds/users.js
const bcrypt = require('bcryptjs') const users = [ { username: 'kudakwashe', password: hashedPassword('kp') }, { username: 'garikai', password: hashedPassword('gg') } ] function hashedPassword (password) { return bcrypt.hashSync(password, 10) } exports.seed = (knex, Promise) => knex('users'...
const bcrypt = require('bcryptjs') const users = [ { username: 'kudakwashe', password: hashedPassword('paradzayi') }, { username: 'garikai', password: hashedPassword('rodneygg') } ] function hashedPassword (password) { return bcrypt.hashSync(password, 10) } exports.seed = (knex, Promise) =>...
Increase the length of passwords to be consistent with the vaalidation rules
Increase the length of passwords to be consistent with the vaalidation rules
JavaScript
mit
byteBridge/transcriptus-api
29abdb6ceff6038cce37e9e5761513b204a08ea0
module/json_api_request.js
module/json_api_request.js
/*! * apiai * Copyright(c) 2015 http://api.ai/ * Apache 2.0 Licensed */ 'use strict'; var Request = require('./request').Request; var util = require('util'); var ServerError = require('./exceptions').ServerError; exports.JSONApiRequest = module.exports.JSONApiRequest = JSONApiRequest; util.inherits(JSONApiRequ...
/*! * apiai * Copyright(c) 2015 http://api.ai/ * Apache 2.0 Licensed */ 'use strict'; var Request = require('./request').Request; var util = require('util'); var ServerError = require('./exceptions').ServerError; exports.JSONApiRequest = module.exports.JSONApiRequest = JSONApiRequest; util.inherits(JSONApiRequ...
Fix issue with wrong data in response
Fix issue with wrong data in response
JavaScript
apache-2.0
dialogflow/dialogflow-nodejs-client,api-ai/api-ai-node-js,api-ai/apiai-nodejs-client,api-ai/api-ai-node-js,api-ai/apiai-nodejs-client,dialogflow/dialogflow-nodejs-client
74b9cebd9c43e4a281ba642c9bcc20f24411a801
src/runner/install/package-json.js
src/runner/install/package-json.js
import path from 'path' import json from '../../util/json' const saguiScripts = { 'build': 'sagui build', 'develop': 'sagui develop --port 3000', 'dist': 'NODE_ENV=production sagui build --optimize', 'start': 'npm run develop', 'test': 'npm run test:lint && npm run test:unit', 'test:lint': 'sagui lint', ...
import path from 'path' import json from '../../util/json' const saguiScripts = { 'build': 'sagui build', 'develop': 'sagui develop --port 3000', 'dist': 'NODE_ENV=production sagui build --optimize', 'start': 'npm run develop', 'test': 'npm run test:lint && npm run test:unit', 'test:coverage': 'npm run tes...
Fix bootstrapped `test:unit:watch` npm script 🐛
Fix bootstrapped `test:unit:watch` npm script 🐛
JavaScript
mit
saguijs/sagui,saguijs/sagui
00216ffd2ba8907d5c70ff067f4bf9fa051027f8
server/controllers/Book.js
server/controllers/Book.js
import omit from 'lodash/omit'; import db from '../models'; const { User } = db; export default { create(req, res) { return User .create(req.userInput) .then((user) => { const data = omit(user.dataValues, [ 'password' ]); return res.status(201).send({ messa...
import db from '../models'; const { Book } = db; export default { create(req, res) { return Book .create(req.userInput) .then(() => { return res.status(201).send({ success: true, message: 'Book uploaded successfully', }); }) .catch(error => res.status(4...
Add book route and creator
Add book route and creator
JavaScript
mit
nosisky/Hello-Books,nosisky/Hello-Books
b4c5139d53430ae26bb869d621cfbdfa9f3124ec
src/testUtils/warningFreeBasics.js
src/testUtils/warningFreeBasics.js
/** * Test for a few basic patterns that usually should * case no warnings. * * This should not be used by rules that intentionally * warn for these cases. */ export default function (tr) { tr.ok("", "empty stylesheet") tr.ok("a {}", "empty rule set") tr.ok("@import \"foo.css\";", "blockless statement") }
/** * Test for a few basic patterns that usually should * case no warnings. * * This should not be used by rules that intentionally * warn for these cases. */ export default function (tr) { tr.ok("", "empty stylesheet") tr.ok("a {}", "empty rule set") tr.ok (":global {}", "CSS Modules global empty rule set"...
Add :global to basic tests
Add :global to basic tests
JavaScript
mit
gaidarenko/stylelint,gucong3000/stylelint,stylelint/stylelint,stylelint/stylelint,hudochenkov/stylelint,gucong3000/stylelint,heatwaveo8/stylelint,hudochenkov/stylelint,heatwaveo8/stylelint,heatwaveo8/stylelint,stylelint/stylelint,m-allanson/stylelint,gucong3000/stylelint,gaidarenko/stylelint,evilebottnawi/stylelint,sty...
c062c2af8e43790759194633fe6bff6b098d4933
src/adhocracy_frontend/adhocracy_frontend/tests/acceptance/EmbeddedSharePage.js
src/adhocracy_frontend/adhocracy_frontend/tests/acceptance/EmbeddedSharePage.js
"use strict"; var shared = require("./shared.js"); var EmbeddedSharePage = function() { this.url = "/embed/social-share"; this.dummyTweetButton = element(by.css(".tweet.dummy_btn")); this.dummyFacebookLikeButton = element(by.css(".fb_like.dummy_btn")); this.get = function() { browser.get(this...
"use strict"; var shared = require("./shared.js"); var EmbeddedSharePage = function() { this.url = "/embed/social-share"; this.dummyTweetButton = element(by.css(".tweet.dummy_btn")); this.dummyFacebookLikeButton = element(by.css(".fb_like.dummy_btn")); this.get = function() { browser.get(this...
Fix Twitter share test not deterministic
Fix Twitter share test not deterministic
JavaScript
agpl-3.0
xs2maverick/adhocracy3.mercator,fhartwig/adhocracy3.mercator,liqd/adhocracy3.mercator,fhartwig/adhocracy3.mercator,xs2maverick/adhocracy3.mercator,xs2maverick/adhocracy3.mercator,xs2maverick/adhocracy3.mercator,liqd/adhocracy3.mercator,fhartwig/adhocracy3.mercator,xs2maverick/adhocracy3.mercator,fhartwig/adhocracy3.mer...
c80bd1e6459211f35f3f7676c11e62e132f91c27
src/main/web/florence/js/functions/_makeEditSections.js
src/main/web/florence/js/functions/_makeEditSections.js
function makeEditSections(collectionName, response) { if (response.type === 'bulletin') { bulletinEditor(collectionName, response); } else { $('.fl-editor__sections').hide(); $("#addSection").remove(); $('.fl-editor__headline').show().val(JSON.stringify(response, null, 2)); $('.fl-panel--editor...
function makeEditSections(collectionName, response, path) { if (response.type === 'bulletin') { bulletinEditor(collectionName, response); } else { $('.fl-editor__sections').hide(); $("#addSection").remove(); $('.fl-editor__headline').show().val(JSON.stringify(response, null, 2)); $('.fl-pa...
Attach click handler to submit for review button to call API.
Attach click handler to submit for review button to call API.
JavaScript
mit
ONSdigital/florence,ONSdigital/florence,ONSdigital/florence,ONSdigital/florence
e130009deb5af19ae8de099dc38d81ae076f12f7
djplaces/static/js/djplaces.js
djplaces/static/js/djplaces.js
$(document).ready(function() { $("#id_place") .geocomplete({ map: "#map_location", mapOptions: { zoom: 10 }, markerOptions: { draggable: true } }) .bind("geocode:result", function(event, result) { var coordinates = result.geome...
$(document).ready(function() { $("#id_place") .geocomplete({ map: "#map_location", mapOptions: { zoom: 10 }, markerOptions: { draggable: true } }) .bind("geocode:result", function(event, result) { $('#id_location').val(result.geometry.location.lat() + ',' + resul...
Update lat and lng on marker dragged
Update lat and lng on marker dragged
JavaScript
mit
oscarmcm/django-places,oscarmcm/django-places,oscarmcm/django-places
71a1c4a3fe010a3f79ea83a4271b6240f5c9c0a8
app/models/post.js
app/models/post.js
var mongoose = require('mongoose'); var Schema = mongoose.Schema; var safeOpts = { j: 1, w: "majority", wtimeout: 10000 }; var postSchema = new Schema({ saved_at: { type: Date, default: Date.now, required: true}, created_at: { type: Date, required: true}, created_at_i: { typ...
var mongoose = require('mongoose'); var Schema = mongoose.Schema; var safeOpts = { j: 1, w: "majority", wtimeout: 10000 }; var postSchema = new Schema({ saved_at: { type: Date, default: Date.now, required: true}, created_at: { type: Date, required: true}, created_at_i: { typ...
Add model, not only the schema
Add model, not only the schema
JavaScript
mit
dburgos/HN-feed,dburgos/HN-feed
7f511555f48096c94aeaefd0254d43f8bcf672fc
app/models/task.js
app/models/task.js
import DS from "ember-data"; import Ember from "ember"; import config from '../config/environment'; export default DS.Model.extend( { prerequisities: DS.attr("prerequisite"), state: DS.attr("string"), active: Ember.computed("state", function() { return ["base", "correcting", "done"].index...
import DS from "ember-data"; import Ember from "ember"; import config from '../config/environment'; export default DS.Model.extend( { prerequisities: DS.attr("prerequisite"), state: DS.attr("string"), active: Ember.computed("state", function() { return ["base", "correcting", "done"].index...
Fix CSP violation on profile.
Fix CSP violation on profile.
JavaScript
mit
fi-ksi/web-frontend,fi-ksi/web-frontend,fi-ksi/web-frontend
e6ef64968bc99b6f8ed30fb0f1a581bc78763a97
tests/configs/modules/weather/currentweather_options.js
tests/configs/modules/weather/currentweather_options.js
/* Magic Mirror Test config default weather * * By fewieden https://github.com/fewieden * * MIT Licensed. */ let config = { port: 8080, ipWhitelist: ["127.0.0.1", "::ffff:127.0.0.1", "::1"], language: "en", timeFormat: 24, units: "metric", electronOptions: { webPreferences: { nodeIntegration: true }...
/* Magic Mirror Test config default weather * * By fewieden https://github.com/fewieden * * MIT Licensed. */ let config = { port: 8080, ipWhitelist: ["127.0.0.1", "::ffff:127.0.0.1", "::1"], language: "en", timeFormat: 24, units: "metric", electronOptions: { webPreferences: { nodeIntegration: true }...
Disable Sunrise/Sunset in Config option
Disable Sunrise/Sunset in Config option
JavaScript
mit
MichMich/MagicMirror,MichMich/MagicMirror,Tyvonne/MagicMirror,MichMich/MagicMirror,Tyvonne/MagicMirror,Tyvonne/MagicMirror,MichMich/MagicMirror,Tyvonne/MagicMirror
11e185860f52757c013f64221927f0b605805cd1
.htmlhintrc.js
.htmlhintrc.js
const htmlHintConfig = require('kolibri-tools/.htmlhintrc'); htmlHintConfig['--vue-component-conventions'] = false; module.exports = htmlHintConfig;
const htmlHintConfig = require('kolibri-tools/.htmlhintrc'); htmlHintConfig['id-class-value'] = false; htmlHintConfig['--vue-component-conventions'] = false; module.exports = htmlHintConfig;
Disable html hint class value check
Disable html hint class value check Vuetify helper classes contain double dashes, e.g. grey--text.
JavaScript
mit
DXCanas/content-curation,DXCanas/content-curation,DXCanas/content-curation,DXCanas/content-curation
144874d96097be560057901149af29fe65bf57ba
packages/test/testserver.js
packages/test/testserver.js
#!/usr/bin/env node /** * Minimal server for local, manual web page testing. */ 'use strict'; // eslint-disable-line const portfinder = require('portfinder'); const http = require('http'); const path = require('path'); const nodeStatic = require('node-static'); const webroot = path.resolve(process.argv[2]); portf...
#!/usr/bin/env node /** * Minimal server for local, manual web page testing. */ /* eslint-disable strict, no-console *//* tslint:disable no-console */ 'use strict'; const portfinder = require('portfinder'); const http = require('http'); const path = require('path'); const nodeStatic = require('node-static'); con...
Fix lint errors in test server
Fix lint errors in test server
JavaScript
isc
WeAreGenki/wag-ui
5c4981122946fbbe8c8bcece6ebc959dd942aa76
client.js
client.js
var configUtils = _altboilerScope.configUtils /* Wait until the client-side configuration has been done */ addEventListener('load', function () { var showLoader = altboiler.getConfig('showLoader') /* Clear the object */ altboiler.tmpConf = {} /* Don't do anything if the loader should be shown */ if(configUti...
var configUtils = _altboilerScope.configUtils /* Wait until the client-side configuration has been done */ addEventListener('load', function () { var showLoader = altboiler.getConfig('showLoader') var styles /* Clear the object */ altboiler.tmpConf = {} /* Don't do anything if the loader should be shown */ ...
Fix the path to the linked loader css
Fix the path to the linked loader css
JavaScript
mit
Kriegslustig/meteor-altboiler,Kriegslustig/meteor-altboiler
a288ab32b8b5c5e6e545739cbb480b16cc00da22
src/main/web/florence/js/functions/_viewTeams.js
src/main/web/florence/js/functions/_viewTeams.js
function viewTeams() { getTeams( success = function (data) { populateTeamsTable(data.teams); }, error = function (jqxhr) { handleApiError(jqxhr); } ); function populateTeamsTable(data) { var teams = _.sortBy(data, function (d) { r...
function viewTeams() { getTeams( success = function (data) { populateTeamsTable(data.teams); }, error = function (jqxhr) { handleApiError(jqxhr); } ); function populateTeamsTable(data) { var teamsHtml = templates.teamList(teams); $('....
Remove client side ordering of teams list (fixed in zebedee now)
Remove client side ordering of teams list (fixed in zebedee now)
JavaScript
mit
ONSdigital/florence,ONSdigital/florence,ONSdigital/florence,ONSdigital/florence
16737528b47ed1b7e91e06cf9927f5acb0465e6a
demos/events/06-musical-data/script.js
demos/events/06-musical-data/script.js
var pianoKeys = document.querySelectorAll('.piano-key'); for (var i = 0; i < pianoKeys.length; i++) { pianoKeys[i].addEventListener('click', function (event) { var note = this.getAttribute('data-piano-key'); playNote(note); }); }
// Write an event listener for each key that looks at the data-piano-key of the // element that was clicked and passes that note to the playNote global function
Remove solution code for data-attributes demo
Remove solution code for data-attributes demo
JavaScript
mpl-2.0
joshcass/advanced-js-fundamentals-ck,mdn/advanced-js-fundamentals-ck,mdn/advanced-js-fundamentals-ck,joshcass/advanced-js-fundamentals-ck
010fc67d6558cb35f6810d00ac4fcb62092c75fa
lib/node_modules/@stdlib/math/base/dist/betaprime/lib/index.js
lib/node_modules/@stdlib/math/base/dist/betaprime/lib/index.js
'use strict'; /* * When adding modules to the namespace, ensure that they are added in alphabetical order according to module name. */ // MODULES // var setReadOnly = require( '@stdlib/utils/define-read-only-property' ); // MAIN // /** * Top-level namespace. * * @namespace betaprime */ var betaprime = {}; /** * ...
'use strict'; /* * When adding modules to the namespace, ensure that they are added in alphabetical order according to module name. */ // MODULES // var setReadOnly = require( '@stdlib/utils/define-read-only-property' ); // MAIN // /** * Top-level namespace. * * @namespace betaprime */ var betaprime = {}; /** * ...
Add variance to beta prime namespace
Add variance to beta prime namespace
JavaScript
apache-2.0
stdlib-js/stdlib,stdlib-js/stdlib,stdlib-js/stdlib,stdlib-js/stdlib,stdlib-js/stdlib,stdlib-js/stdlib,stdlib-js/stdlib,stdlib-js/stdlib
094b42ab7dd77ead37bb8160d0001343c4347972
imports/startup/client/index.js
imports/startup/client/index.js
// PhantomJS does not support web fonts if (Meteor.isTest == false) { WebFontConfig = { google: { families: [ 'Oswald:300,400' ] } }; (function() { var wf = document.createElement('script'); wf.src = '//ajax.googleapis.com/ajax/libs/webfont/1.6.16/webfont.js'; wf.type = 'text/javascript'; wf.a...
// PhantomJS does not support web fonts WebFontConfig = { google: { families: [ 'Oswald:300,400' ] } }; (function() { var wf = document.createElement('script'); wf.src = '//ajax.googleapis.com/ajax/libs/webfont/1.6.16/webfont.js'; wf.type = 'text/javascript'; wf.async = 'true'; var s = document.getElementsB...
Remove the clause around the font loader since it wasn't working anyway.
Remove the clause around the font loader since it wasn't working anyway.
JavaScript
mit
howlround/worldtheatremap,howlround/worldtheatremap
cc5410b3b4860862d41da79a569ae8eeb268d23e
client/js/controllers/auth.js
client/js/controllers/auth.js
angular .module('app') .controller('AuthLoginController', ['$scope', 'AuthService', '$state', function ($scope, AuthService, $state) { $scope.login = function () { AuthService.login($scope.user.username, $scope.user.email, $scope.user.password) .then(function () { $state.go('area-clienti-inizio');...
angular .module('app') .controller('AuthLoginController', ['$scope', 'AuthService', '$state', function ($scope, AuthService, $state) { $scope.login = function () { AuthService.login($scope.user.username, $scope.user.email, $scope.user.password) .then(function () { $state.go('area-clienti'); }...
Fix an error on login
Fix an error on login
JavaScript
mit
dev-augmenta/vrseum-backend,dev-augmenta/vrseum-backend
d93d4dd2b4300641505509191956b42c8a132a87
static/js/drop_points.js
static/js/drop_points.js
/* vim: set expandtab ts=4 sw=4: */
var last_update = Date.now()/1000; function refresh_drop_points() { return $.ajax({ type: "POST", url: apiurl, data: { action: "dp_json", ts: last_update }, success: function (response) { last_update = Date.now() / 1000; drop_p...
Add stupid polling for changes via API
Add stupid polling for changes via API
JavaScript
mit
der-michik/c3bottles,der-michik/c3bottles,der-michik/c3bottles,der-michik/c3bottles
55230781219ec63c6e95c0fd94a632b4c9677180
stories/setup.stories.js
stories/setup.stories.js
/** * External dependencies */ import { storiesOf } from '@storybook/react'; /** * Internal dependencies */ import Setup from '../assets/js/components/setup'; storiesOf( 'Setup', module ) .add( 'Step one', () => { global.googlesitekit.setup.isSiteKitConnected = false; global.googlesitekit.setup.authenticated...
/** * External dependencies */ import { storiesOf } from '@storybook/react'; /** * Internal dependencies */ import Setup from '../assets/js/components/setup'; storiesOf( 'Setup', module ) .add( 'Step one', () => { global.googlesitekit.setup.isSiteKitConnected = false; global.googlesitekit.setup.isAuthenticat...
Revert change to global name.
Revert change to global name.
JavaScript
apache-2.0
google/site-kit-wp,google/site-kit-wp,google/site-kit-wp,google/site-kit-wp
415bf090411644dc2844b4a86a7d38b3fae6667a
packages/pg/lib/index.js
packages/pg/lib/index.js
'use strict' var Client = require('./client') var defaults = require('./defaults') var Connection = require('./connection') var Pool = require('pg-pool') const poolFactory = (Client) => { return class BoundPool extends Pool { constructor(options) { super(options, Client) } } } var PG = function (cl...
'use strict' var Client = require('./client') var defaults = require('./defaults') var Connection = require('./connection') var Pool = require('pg-pool') const poolFactory = (Client) => { return class BoundPool extends Pool { constructor(options) { super(options, Client) } } } var PG = function (cl...
Remove console.error on pg-native module not found
Remove console.error on pg-native module not found
JavaScript
mit
brianc/node-postgres,brianc/node-postgres
2094436175c4a3c2482b974700ac2202a1a4b6a8
errors.js
errors.js
(function(root) { if (typeof exports !== 'undefined') { var _ = require('underscore'); var util = require('./util') } else { var util = Substance.util; } var errors = {}; SubstanceError = function(name, code, message) { this.message = message; this.name = name; this.code = code; this.stack = util.cal...
(function(root) { if (typeof exports !== 'undefined') { var _ = require('underscore'); var util = require('./util') } else { var util = Substance.util; } var errors = {}; SubstanceError = function(name, code, message) { this.message = message; this.name = name; this.code = code; this.stack = util.cal...
Return a freshly defined error class.
Return a freshly defined error class.
JavaScript
mit
substance/util
75bbb60783f5decc00ece0cf80cb590b5dfbafef
test/scripts/preview.js
test/scripts/preview.js
const mocha = require('mocha'); const assert = require('assert'); const path = require('path'); const fs = require('fs'); const describe = mocha.describe; const it = mocha.it; const allResumes = require('./allResumes'); describe('npm run preview', () => { it('should have generated the png files', () => { const r...
const mocha = require('mocha'); const assert = require('assert'); const path = require('path'); const fs = require('fs'); const describe = mocha.describe; const it = mocha.it; const allResumes = require('./allResumes'); describe('npm run preview', () => { it('should have generated the png files', () => { setTime...
ADD sleep before running test
ADD sleep before running test
JavaScript
mit
salomonelli/best-resume-ever,salomonelli/best-resume-ever
d6f57a39a457e800a87fec02d3c5cc6800cdd6d0
test/svg-test-helper.js
test/svg-test-helper.js
import $ from "cheerio"; const SvgTestHelper = { RECTANGULAR_SEQUENCE: ["M", "L", "L", "L", "L"], expectIsRectangular(wrapper) { expect(exhibitsRectangularDirectionSequence(wrapper)).to.be.true; } }; function exhibitsRectangularDirectionSequence(wrapper) { const commands = getPathCommandsFromWrapper(wrap...
import $ from "cheerio"; const RECTANGULAR_SEQUENCE = ["M", "L", "L", "L", "L"]; const CIRCULAR_SEQUENCE = ["M", "m", "a", "a"]; const SvgTestHelper = { expectIsRectangular(wrapper) { expect(exhibitsShapeSequence(wrapper, RECTANGULAR_SEQUENCE)).to.be.true; }, expectIsCircular(wrapper) { expect(exhibits...
Refactor and add circular shape helper
Refactor and add circular shape helper
JavaScript
mit
FormidableLabs/victory-chart,GreenGremlin/victory-chart,FormidableLabs/victory-chart,GreenGremlin/victory-chart
afdf568adcb412eb2c37bb9a516696f12f381000
karma.conf.js
karma.conf.js
module.exports = function(config) { config.set({ basePath: '', frameworks: ['mocha'], webpack: { mode: 'development', module: { rules: [ { test: /\.js$/, exclude: /node_modules/, use: { loader: 'babel-loader', op...
module.exports = function(config) { const { KARMA_FILE = 'src/**/*.spec.js' } = process.env; const FILE = KARMA_FILE || 'src/**/*.spec.js'; config.set({ basePath: '', frameworks: ['mocha'], webpack: { mode: 'development', module: { rules: [ { test: /\.js$/, ...
Add ability to set karma file through env
Add ability to set karma file through env
JavaScript
mit
formio/formio.js,formio/formio.js,formio/formio.js
d2d0a8a4f911d6a46cf4def218dabc9ca2c50ed4
workshop/www/js/recipe.js
workshop/www/js/recipe.js
recipe.js
var Recipe = function(data){ this.title = data.Title; this.ingredients = []; this.instructions = data.Instructions; this.prepTime = data.TotalMinutes; this.yieldNumber = data.YieldNumber; this.yieldUnit = data.YieldUnit; this.stars = data.StarRating; this.instructions = data.Instructions; this.imageUr...
Create Recipe class to wrap desired JSON data from 2nd API call
Create Recipe class to wrap desired JSON data from 2nd API call All attributes for Recipe object, created on invocation of BigOvenGetRecipeJson function, are functional except for ingredients, which requires creation of new JS constructors.
JavaScript
mit
danasselin/line-cook,nyc-rock-doves-2015/line-cook,nyc-rock-doves-2015/line-cook,nyc-rock-doves-2015/line-cook,danasselin/line-cook,danasselin/line-cook,danasselin/line-cook,nyc-rock-doves-2015/line-cook,nyc-rock-doves-2015/line-cook,danasselin/line-cook,danasselin/line-cook,nyc-rock-doves-2015/line-cook,danasselin/lin...
a164d5fdd4ab443abd63042737d91706e7559350
js/map.js
js/map.js
var atlas = {}; function initMap() { atlas = L.map('atlas').setView([40, -100], 4); L.tileLayer('//stamen-tiles-{s}.a.ssl.fastly.net/toner-lite/{z}/{x}/{y}.png').addTo(atlas); } function buildMap() { console.log(data.maps); _.each(data.maps, function(map) { var options = { className: 'atlas--map-ar...
var atlas = {}; function initMap() { atlas = L.map('atlas').setView([40, -100], 4); L.tileLayer('//stamen-tiles-{s}.a.ssl.fastly.net/toner-lite/{z}/{x}/{y}.png').addTo(atlas); } function buildMap() { console.log(data.maps); _.each(data.maps, function(map) { var options = { className: 'atlas--map-ar...
Send correct number to highlight and select functions
Send correct number to highlight and select functions
JavaScript
mit
axismaps/tile-browser,axismaps/tile-browser
0154b921fa55444bb09dffb5e2f09382cc780def
exercises/buffer_concat/solution/solution.js
exercises/buffer_concat/solution/solution.js
var buffers = []; process.stdin.on('readable', function(chunk) { var chunk = process.stdin.read(); if (chunk !== null) { buffers.push(chunk); } }); process.stdin.on('end', function() { console.log(Buffer.concat(buffers)); });
var buffers = []; process.stdin.on('readable', function() { var chunk = process.stdin.read(); if (chunk !== null) { buffers.push(chunk); } }); process.stdin.on('end', function() { console.log(Buffer.concat(buffers)); });
Remove unnecessary argument to 'readable' callback
Remove unnecessary argument to 'readable' callback
JavaScript
bsd-2-clause
karissa/bytewiser,karissa/bytewiser,maxogden/bytewiser,maxogden/bytewiser
670580b52e520b42698ab80f02fe9fb8df6c8b50
external/amber-cli/tests/amberVersionTest.js
external/amber-cli/tests/amberVersionTest.js
// Tests if the `amber version` command returns the expected amber version number, according to the configuration file `package.json` // Displays 'ok' in green if test succeeds, else 'not ok' in red. require('shelljs/global'); require('colors'); var JSON_PACKAGE_PATH = '../package.json'; // {amber directory}/external...
// Tests if the `amber version` command returns the expected amber version number, according to the configuration file `package.json` // Displays 'ok' in green if test succeeds, else 'not ok' in red. require('shelljs/global'); require('colors'); var AMBER_VERSION_COMMAND = './support/amber-cli.js version'; var amber...
Fix amber version smoke test - cannot test actual version
Fix amber version smoke test - cannot test actual version Version presented by amber cli is the version of amber it was compiled with, not version of amber-cli itself.
JavaScript
mit
adrian-castravete/amber,adrian-castravete/amber,amber-smalltalk/amber,adrian-castravete/amber,amber-smalltalk/amber,amber-smalltalk/amber
2e357a6ac4c3b55fa5e7c0764c8d3902c058d464
RNApp/app/config.js
RNApp/app/config.js
// If you're running on a device or in the Android simulator be sure to change let METEOR_URL = 'http://localhost:3000/websocket'; if (process.env.NODE_ENV === 'production') { METEOR_URL = ''; // your production server url } const config = { env: process.env.NODE_ENV, METEOR_URL, }; export default config;
// If you're running on a device or in the Android simulator be sure to change let METEOR_URL = 'ws://localhost:3000/websocket'; if (process.env.NODE_ENV === 'production') { METEOR_URL = ''; // your production server url } const config = { env: process.env.NODE_ENV, METEOR_URL, }; export default config;
Use ws rather than http
Use ws rather than http
JavaScript
mit
blovato/sca-mobile,spencercarli/react-native-meteor-boilerplate,spencercarli/react-native-meteor-boilerplate,blovato/sca-mobile,blovato/sca-mobile,spencercarli/react-native-meteor-boilerplate,spencercarli/react-native-meteor-boilerplate
9e0abc84a05e82f28fbe8a87f5ac9fd95b41c5f7
tests/reducers/index.js
tests/reducers/index.js
import { expect } from 'chai' import types from '../../src/constants/ActionTypes' import reducer from '../../src/reducers' describe('reducers/index.js', () => { it('should handle POSTS_SUCCESS and parse posts data to posts entities', () => { expect(reducer(undefined, { type: types.POSTS_SUCCESS, dat...
import { expect } from 'chai' import types from '../../src/constants/ActionTypes' import reducer from '../../src/reducers' describe('reducers/index.js', () => { it('should handle POSTS_SUCCESS and parse posts data to posts entities', () => { const { entities } = reducer(undefined, { type: types.POSTS_SUCC...
Make root reducer expectation dynamic
Make root reducer expectation dynamic
JavaScript
mit
nomkhonwaan/nomkhonwaan.github.io
1b4f4523d42549ea08bd5be35ebd33c68ba3f459
tests/test_directory.js
tests/test_directory.js
'use strict'; const path = require('path'); const should = require('should'); const Nconfdir = require('./../index.js'); describe('Nconfdir#getDirectory', () => { it('should getDirectory include dir and expanded env', (done) => { const nconfdir = new Nconfdir({dir: path.join(__dirname, 'configs', 'env'), env...
'use strict'; const path = require('path'); const should = require('should'); const Nconfdir = require('./../index.js'); describe('Nconfdir#getDirectory', () => { it('should getDirectory include dir and expanded env', (done) => { const nconfdir = new Nconfdir({dir: path.join(__dirname, 'configs', 'env'), env...
Add tests for error handling if directory didn't exists
Add tests for error handling if directory didn't exists
JavaScript
mit
5minds/nconfetti
8fff3eceb06a181f486f0f7ba06daa9b38ac2140
examples/hello_world.js
examples/hello_world.js
"use strict"; // add timestamps in front of log messages require('console-stamp')(console, 'HH:MM:ss'); var bb = require('../bb.js'); var fs = require('fs') var progArgs = process.argv.slice(2); var sourceDir = progArgs[0]; var processors = [ function() { console.log('Hello'); return true; }, function...
"use strict"; // add timestamps in front of log messages require('console-stamp')(console, 'HH:MM:ss'); var bb = require('dpbb'); var fs = require('fs') // Get directory from command line argument var progArgs = process.argv.slice(2); var sourceDir = progArgs[0]; if (!sourceDir) { console.log('Directory must be sp...
Rename to dpbb for npm
Rename to dpbb for npm
JavaScript
mit
danio/bb
96ad74425a84f70460bb47da0b72f65d57e39455
lib/node_modules/@stdlib/utils/define-property/lib/has_define_property_support.js
lib/node_modules/@stdlib/utils/define-property/lib/has_define_property_support.js
/** * @license Apache-2.0 * * Copyright (c) 2021 The Stdlib Authors. * * 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 a...
/** * @license Apache-2.0 * * Copyright (c) 2021 The Stdlib Authors. * * 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 a...
Simplify implementation and achieve full test coverage
Simplify implementation and achieve full test coverage
JavaScript
apache-2.0
stdlib-js/stdlib,stdlib-js/stdlib,stdlib-js/stdlib,stdlib-js/stdlib,stdlib-js/stdlib,stdlib-js/stdlib,stdlib-js/stdlib,stdlib-js/stdlib
e4431fac1576b7339a827e1e5129218a4bf608eb
lib/server/livereload-server.js
lib/server/livereload-server.js
'use strict'; var RSVP = require('rsvp'); var tinylr = require('tiny-lr'); var ui = require('../ui'); exports.start = function(options) { var liveReloadServer = new tinylr.Server(); var listen = RSVP.denodeify(liveReloadServer.listen.bind(liveReloadServer)); // Reload on file changes options.watcher.on('cha...
'use strict'; var RSVP = require('rsvp'); var tinylr = require('tiny-lr'); var ui = require('../ui'); exports.start = function(options) { var liveReloadServer = new tinylr.Server(); var listen = RSVP.denodeify(liveReloadServer.listen.bind(liveReloadServer)); // Reload on file changes options.watcher.on('cha...
Remove logging of 'build' after each broccoli build
Remove logging of 'build' after each broccoli build
JavaScript
mit
mike-north/ember-cli,lancedikson/ember-cli,olegdovger/ember-cli,raycohen/ember-cli,tsing80/ember-cli,martypenner/ember-cli,williamsbdev/ember-cli,ServiceTo/ember-cli,HeroicEric/ember-cli,joliss/ember-cli,elwayman02/ember-cli,givanse/ember-cli,jasonmit/ember-cli,rtablada/ember-cli,bevacqua/ember-cli,greyhwndz/ember-cli,...
853712ab267a68858782932dafa3f8a35538586d
www/js/directives.js
www/js/directives.js
angular.module('WatchTimer') .directive('resizeTextToFill', function($document, $timeout) { return { link: function(scope, element, attrs, controller, transcludeFn) { var initial_font_size = 10; var font_size_increment = 20; var safety_counter_max = 100; function set_size(...
angular.module('WatchTimer') .directive('resizeTextToFill', function($window, $timeout) { return { link: function(scope, element, attrs, controller, transcludeFn) { var initial_font_size = 10; var font_size_increment = 20; var safety_counter_max = 100; function set_size(fo...
Use window dimensions rather than document dimensions so the sizing is more stable
Use window dimensions rather than document dimensions so the sizing is more stable
JavaScript
agpl-3.0
OmniRose/omnirose-watch-timer-app,OmniRose/omnirose-watch-timer-app
44084602901326e0d80a222aa5fc7976ab6d3742
ipywidgets/static/widgets/js/widget_state.js
ipywidgets/static/widgets/js/widget_state.js
// Copyright (c) Jupyter Development Team. // Distributed under the terms of the Modified BSD License. // npm compatibility if (typeof define !== 'function') { var define = require('./requirejs-shim')(module); } define(["base/js/namespace"], function(Jupyter) { "use strict"; var save_state = function() { ...
// Copyright (c) Jupyter Development Team. // Distributed under the terms of the Modified BSD License. define(["base/js/namespace"], function(Jupyter) { "use strict"; var save_state = function() { Jupyter.WidgetManager._managers[0].get_state().then(function(state) { var data = "text/json;c...
Create action rather than toolbar button
Create action rather than toolbar button
JavaScript
bsd-3-clause
jupyter-widgets/ipywidgets,SylvainCorlay/ipywidgets,cornhundred/ipywidgets,SylvainCorlay/ipywidgets,SylvainCorlay/ipywidgets,jupyter-widgets/ipywidgets,jupyter-widgets/ipywidgets,ipython/ipywidgets,ipython/ipywidgets,cornhundred/ipywidgets,SylvainCorlay/ipywidgets,cornhundred/ipywidgets,cornhundred/ipywidgets,cornhundr...
c8a8552487da81cd252b660ce7f774442e93b161
ParseCloud/cloud/main.js
ParseCloud/cloud/main.js
Parse.Cloud.beforeSave("Bill", function (request, response) { request.object.get("Family").fetch().then(function (family) { family.get("Writers").fetch().then(function (writers) { writers.relation("users").query().find().then(function (results) { var found = false; ...
Parse.Cloud.beforeSave("Bill", function (request, response) { request.object.get("Family").fetch().then(function (family) { family.get("Writers").fetch().then(function (writers) { writers.relation("users").query().find().then(function (results) { var found = false; ...
Send push notifications via cloud code.
Send push notifications via cloud code.
JavaScript
mit
michaellperry/BillTender_Parse,michaellperry/BillTender_Parse
200e08dc7cc29a756244be4fc4b2d17d78584d1a
animateCSS.js
animateCSS.js
(function ($) { $.fn.animateCSS = function (effect, delay, callback) { // Return this to maintain chainability return this.each(function () { // Cache $(this) for speed var $this = $(this); // Check if delay exists or if it's a callback if (!delay ...
(function ($) { $.fn.animateCSS = function (effect, delay, callback) { // Return this to maintain chainability return this.each(function () { // Cache $(this) for speed var $this = $(this); // Check if delay exists or if it's a callback if (!delay ...
Remove effect classes after animations complete so they can be added again if needed
Remove effect classes after animations complete so they can be added again if needed
JavaScript
mit
craigmdennis/animateCSS,output/animateCSS
14e6af87071c45a603302fac67deabe8d51c2dc8
Resources/ui/common/questions/DateQuestionView.js
Resources/ui/common/questions/DateQuestionView.js
//DateQuestionView Component Constructor function DateQuestionView(question, content) { var self = Ti.UI.createPicker({ type : Ti.UI.PICKER_TYPE_DATE, value : new Date(), color : '#336699', right : 5, left : 5, }); self.addEventListener('change', function(e) { this.value = e.value; }); self.getValue =...
//DateQuestionView Component Constructor function DateQuestionView(question, content) { var self = Ti.UI.createPicker({ type : Ti.UI.PICKER_TYPE_DATE, value : content ? new Date(content) : new Date(), color : '#336699', right : 5, left : 5, }); self.addEventListener('change', function(e) { this.value = ...
Fix the date-picker edit flow in Android.
Fix the date-picker edit flow in Android. Months/days were randomly getting incremented/decremented. Manually create the date instead of using `toISOString`
JavaScript
mit
nilenso/ashoka-survey-mobile,nilenso/ashoka-survey-mobile
400d359330c55bc560fcc6a54e0a0389cffda46f
tests/integration/components/language-picker/component-test.js
tests/integration/components/language-picker/component-test.js
import { moduleForComponent, test } from 'ember-qunit'; import hbs from 'htmlbars-inline-precompile'; import Ember from 'ember'; const localeStub = Ember.Service.extend({ locale: null }); moduleForComponent('language-picker', 'Integration | Component | language picker', { integration: true, beforeEach: functi...
import { moduleForComponent, test } from 'ember-qunit'; import hbs from 'htmlbars-inline-precompile'; import Ember from 'ember'; const localeStub = Ember.Service.extend({ locale: null }); moduleForComponent('language-picker', 'Integration | Component | language picker', { integration: true, beforeEach: functi...
Fix failing test when two locales used same flag icon
Fix failing test when two locales used same flag icon [#LEI-290]
JavaScript
apache-2.0
CenterForOpenScience/isp,CenterForOpenScience/isp,CenterForOpenScience/isp
21ee06a870747b29c6e256ac405153b7a5af55e2
src/activities/pizza/shared/parameters.js
src/activities/pizza/shared/parameters.js
define({ RoundCount: 2, MinPlayers: 4, RoundDuration: 20000 });
define({ RoundCount: 2, MinPlayers: 4, RoundDuration: 90000 });
Increase round duration to 90 seconds
Increase round duration to 90 seconds
JavaScript
mpl-2.0
councilforeconed/interactive-activities,councilforeconed/interactive-activities,jugglinmike/cee,jugglinmike/cee,councilforeconed/interactive-activities
c6f08f3b412cc2a13e0d50963c9fcfc1322f4943
website/app/application/core/projects/project/provenance/vis-network-directive.js
website/app/application/core/projects/project/provenance/vis-network-directive.js
Application.Directives.directive('visNetwork', visNetworkDirective); function visNetworkDirective() { return { restrict: 'E', require: '^ngModel', scope: { ngModel: '=', onSelect: '&', options: '=' }, link: function($scope, $element, $attr...
Application.Directives.directive('visNetwork', visNetworkDirective); function visNetworkDirective() { return { restrict: 'E', require: '^ngModel', scope: { ngModel: '=', onSelect: '&', options: '=', onLoaded: '&' }, link: funct...
Add on-loaded argument so applications can get ahold of the network. Fix up the watch so that it sets the data for the network rather than creating a new network.
Add on-loaded argument so applications can get ahold of the network. Fix up the watch so that it sets the data for the network rather than creating a new network.
JavaScript
mit
materials-commons/materialscommons.org,materials-commons/materialscommons.org,materials-commons/materialscommons.org,materials-commons/materialscommons.org,materials-commons/materialscommons.org
285701d9f104400ef90c8e7ef8e3513b6c3dee21
erpnext/accounts/report/cash_flow/cash_flow.js
erpnext/accounts/report/cash_flow/cash_flow.js
// Copyright (c) 2013, Frappe Technologies Pvt. Ltd. and contributors // For license information, please see license.txt frappe.require("assets/erpnext/js/financial_statements.js", function() { frappe.query_reports["Cash Flow"] = $.extend({}, erpnext.financial_statements); // The last item in the array is the def...
// Copyright (c) 2013, Frappe Technologies Pvt. Ltd. and contributors // For license information, please see license.txt frappe.require("assets/erpnext/js/financial_statements.js", function() { frappe.query_reports["Cash Flow"] = $.extend({}, erpnext.financial_statements); // The last item in the array is the def...
Add missing Cost Center filter in cash flow statement
fix: Add missing Cost Center filter in cash flow statement
JavaScript
agpl-3.0
gsnbng/erpnext,gsnbng/erpnext,gsnbng/erpnext,gsnbng/erpnext
cc9d132e29ae00825ccdea9701507f1c4bbf53ac
testem.js
testem.js
/* eslint-env node */ const Reporter = require('ember-test-utils/reporter') module.exports = { disable_watching: true, framework: 'mocha', launch_in_ci: [ 'Chrome', 'Firefox' ], launch_in_dev: [ 'Chrome' ], reporter: new Reporter(), test_page: 'tests/index.html?hidepassed' }
/* eslint-env node */ module.exports = { disable_watching: true, framework: 'mocha', launch_in_ci: [ 'Chrome', 'Firefox' ], launch_in_dev: [ 'Chrome' ], test_page: 'tests/index.html?hidepassed' }
Remove ember-test-utils/reporter to see if addresses build issue
Remove ember-test-utils/reporter to see if addresses build issue
JavaScript
mit
ciena-frost/ember-frost-bunsen,ciena-frost/ember-frost-bunsen,ciena-frost/ember-frost-bunsen
79ee4bb7b405875a29fae21f122ef83d2572450f
api/conf.js
api/conf.js
var rc = require('rc'); /*eslint-disable camelcase */ module.exports = rc('number_switcher_3000', { aws_region: 'us-east-1', aws_s3_bucket: 'let-me-in-dev', brennens_number: '222-222-2223', jeffs_number: '222-222-2222', login_token: 'login_token', user_id: 'user_id' }); /*eslint-enable camelcase */
var rc = require('rc'); /*eslint-disable camelcase */ module.exports = rc('number_switcher_3000', { aws_region: 'us-east-1', aws_s3_bucket: 'number-switcher-3000-dev', brennens_number: '222-222-2223', jeffs_number: '222-222-2222', login_token: 'login_token', user_id: 'user_id' }); /*eslint-enable camelca...
Update testing s3 bucket name
Update testing s3 bucket name
JavaScript
mit
jeffcharles/number-switcher-3000,jeffcharles/number-switcher-3000,jeffcharles/number-switcher-3000
55bbb091356f4720cb6382c0ac6c102643218321
WebApp/index.js
WebApp/index.js
'use strict'; var express = require('express'); var kraken = require('kraken-js'); var db = require('./lib/db'); var crypto = require('./lib/crypto'); var passport = require('passport'); var localStrategy = require('./lib/registration');//?? var options, app; /* * Create and configure application. Also exports ap...
'use strict'; var express = require('express'); var kraken = require('kraken-js'); var db = require('./lib/db'); var crypto = require('./lib/crypto'); var passport = require('passport'); var signUpStrategy= require('./lib/registration');//?? //var signInStrategy = require('./lib/login'); var options, app; /* * Cr...
Include signInStrategy for future updates
Include signInStrategy for future updates
JavaScript
mit
uahengojr/NCA-Web-App,uahengojr/NCA-Web-App
db50d24940ef8475c9eb9c72c3dedf29d3b55c8e
source/javascript/utilities/documentKeyboardHandler.js
source/javascript/utilities/documentKeyboardHandler.js
define(function (require) { var $ = require("jquery"); var documentKeyboardHandler = function (handler) { // keeps track of which keys have already been pressed, // so we can keep track of which key is a repeated event. var keysDown = []; this.keyboardListener = function (event) { var keyIsDown = event.t...
define(function (require) { var $ = require("jquery"); var shiftKey = 16; var dummyShiftKeyboardEvent = { type: "keyup", preventDefault: function () { }, which: shiftKey }; var documentKeyboardHandler = function (handler) { // keeps track of which keys have already been pressed, // so we can keep trac...
Handle the shift key being released outside of the document by simulating the keyup event when the mouse returns.
Handle the shift key being released outside of the document by simulating the keyup event when the mouse returns.
JavaScript
mit
stuartkeith/webaudiosequencer,stuartkeith/webaudiosequencer
5ac3987fc1560130062301ecb15dccc8e7dd1965
js/File.js
js/File.js
define([ ], function ( ) { var File = function (name, contents) { this.name = name || 'Example'; this.contents = contents; this.selected = true; }; File.prototype.findNumberAt = function (index) { var match = this.contents.substring(index).match(/-?\d+\.?\d*/); if (match) { return m...
define([ ], function ( ) { var File = function (name, contents) { this.name = name || 'Example'; this.contents = contents; this.selected = true; }; File.prototype.findNumberAt = function (index) { var match = this.contents.substring(index).match(/-?\d+\.?\d*/); if (match) { return m...
Fix error when theres no number at the cursor
Fix error when theres no number at the cursor
JavaScript
mit
brianpeiris/RiftSketch,brianpeiris/RiftSketch
90092a9471420ec98ba0e3128ad299080574472f
extensions/roc-package-webpack-dev/src/webpack/utils/rocExportWebpackPlugin.js
extensions/roc-package-webpack-dev/src/webpack/utils/rocExportWebpackPlugin.js
export default class RocExportPlugin { constructor(resolveRequest) { this.resolveRequest = resolveRequest; } apply(compiler) { // We assume that loaders will be managed in Webpack-land, that is we will not manage them in exports compiler.plugin('normal-module-factory', (normalModule...
export default class RocExportPlugin { constructor(resolveRequest) { this.resolveRequest = resolveRequest; } apply(compiler) { // We assume that loaders will be managed in Webpack-land, that is we will not manage them in exports compiler.plugin('normal-module-factory', (normalModule...
Handle the case when result is undefined
Handle the case when result is undefined
JavaScript
mit
rocjs/roc-package-webpack
d49021b9084cecf4dcd6eb960bdd62098169ffcb
js/main.js
js/main.js
$(document).ready(function (){ // smooth scrolling $(".smoothie").on('click', function(event) { var target = $(this.hash) , navOffset = $('#navbar').height() ; event.preventDefault(); return $('html, body') .animate( { scrollTop: target.offset().top - navOffset }, 600, function() { ...
$(document).ready(function (){ // smooth scrolling $(".smoothie").on('click', function(event) { var target = $(this.hash) , navOffset = $('#navbar').height() ; event.preventDefault(); return $('html, body') .animate( { scrollTop: target.offset().top - navOffset }, 600, function() { ...
Remove the randomization of mentors -- they are alphabetical by surname
Remove the randomization of mentors -- they are alphabetical by surname
JavaScript
apache-2.0
oaklandfinishup/oaklandfinishup.github.io,oaklandfinishup/oaklandfinishup.github.io
7c058000f2dc6380c36da830ebd1eea83260081b
js/main.js
js/main.js
var updatePreviewTarget = function(data, status) { $('.spinner').hide(); $('#preview-target').html(data); renderLatexExpressions(); } var renderLatexExpressions = function() { $('.latex-container').each( function(index) { katex.render( this.textContent, this, { displayMode: $(...
var updatePreviewTarget = function(data, status) { $('.spinner').hide(); $('#preview-target').html(data); $('#preview-target code').each(function(i, block) { hljs.highlightBlock(block); }); renderLatexExpressions(); } var renderLatexExpressions = function() { $('.latex-container').each( function(in...
Fix code highlighting in note previews
Fix code highlighting in note previews
JavaScript
mit
erettsegik/erettsegik.hu,erettsegik/erettsegik.hu,erettsegik/erettsegik.hu
9b759461828d79c94925b5c7f812d9df1dce0eb4
canvas-animation/js/geometry/views/path-view.js
canvas-animation/js/geometry/views/path-view.js
/*globals define*/ define([ 'geometry/views/object2d-view' ], function( Object2DView ) { 'use strict'; var PathView = Object2DView.extend({ }); return PathView; });
/*globals define*/ define([ 'jquery', 'geometry/views/object2d-view' ], function( $, Object2DView ) { 'use strict'; var PathView = Object2DView.extend({ events: { 'mousedown .handler': 'onMouseDown', 'mousemove .handler': 'onMousemMove', 'mouseup .handler': 'onMouseUp' }, initia...
Add incomplete handler implementation to PathEditView.
canvas-animation: Add incomplete handler implementation to PathEditView.
JavaScript
mit
razh/experiments-app
e08cb91560a4505927da0f0192403c0467f77206
AppleEasing.js
AppleEasing.js
/** * @flow */ 'use strict'; let { Easing } = require('react-native'); // See Apple's "CAMediaTimingFunction Class Reference" for the Bezier control // points exports.easeIn = Easing.bezier(0.42, 0, 1, 1); exports.easeOut = Easing.bezier(0, 0, 0.58, 1); exports.easeInOut = Easing.bezier(0.42, 0, 0.58, 1); exports.d...
/** * @flow */ 'use strict'; let { Easing } = require('react-native'); const EPSILON = 1e-9; // See Apple's "CAMediaTimingFunction Class Reference" for the Bezier control // points exports.easeIn = Easing.bezier(0.42, 0, 1, 1, EPSILON); exports.easeOut = Easing.bezier(0, 0, 0.58, 1, EPSILON); exports.easeInOut = E...
Adjust epsilon, setting it to 1e-9 for smoother animations
Adjust epsilon, setting it to 1e-9 for smoother animations Was getting flickering at higher values.
JavaScript
mit
exponentjs/react-apple-easing
03b043ca2bd4a2af9759b91f1287bff670336a2c
react/features/base/react/components/native/Container.js
react/features/base/react/components/native/Container.js
/* @flow */ import React from 'react'; import { TouchableHighlight, TouchableWithoutFeedback, View } from 'react-native'; import AbstractContainer from '../AbstractContainer'; /** * Represents a container of React Native/mobile {@link Component} children. * * @extends AbstractContainer */ export defa...
/* @flow */ import React from 'react'; import { TouchableHighlight, TouchableWithoutFeedback, View } from 'react-native'; import { Platform } from '../../'; import AbstractContainer from '../AbstractContainer'; /** * Represents a container of React Native/mobile {@link Component} children. * * @extend...
Destroy containes when they are not visible
[Android] Destroy containes when they are not visible Whatever I've tried so far ends up failing in really weird ways, so let's admit defeat, for now. Destroy containers only on Android. This shall be revisited when we update RN to version >= 0.43 and we have "display: 'none'" available.
JavaScript
apache-2.0
jitsi/jitsi-meet,jitsi/jitsi-meet,bgrozev/jitsi-meet,jitsi/jitsi-meet,gpolitis/jitsi-meet,bgrozev/jitsi-meet,gpolitis/jitsi-meet,gpolitis/jitsi-meet,bgrozev/jitsi-meet,gpolitis/jitsi-meet,jitsi/jitsi-meet,jitsi/jitsi-meet,gpolitis/jitsi-meet,bgrozev/jitsi-meet,gpolitis/jitsi-meet,jitsi/jitsi-meet,gpolitis/jitsi-meet,gp...
331c7f35111fd79a006db829d64027cb0d8591d2
api/blog-api.js
api/blog-api.js
// Copyright © 2017 Michael Howell. All rights reserved. // The following code is covered by the AGPL-3.0 license. const selfapi = require('selfapi'); const blog = require('../lib/blog'); const log = require('../lib/log'); // API resource to manage Janitor's Discourse-backed news section. const blogAPI = module.expo...
// Copyright © 2017 Michael Howell. All rights reserved. // The following code is covered by the AGPL-3.0 license. const selfapi = require('selfapi'); const blog = require('../lib/blog'); const log = require('../lib/log'); // API resource to manage Janitor's Discourse-backed news section. const blogAPI = module.expo...
Switch the blog handler over to POST
Switch the blog handler over to POST Makes the Discourse webhook actually work right.
JavaScript
agpl-3.0
nt1m/janitor,nt1m/janitor,jankeromnes/janitor,JanitorTechnology/janitor,JanitorTechnology/janitor,jankeromnes/janitor
b1a74db98c9724b84cc90704b43af6ab2ef61758
src/app/chat/containers/chat-page/chat-page.component.js
src/app/chat/containers/chat-page/chat-page.component.js
import template from './chat-page.html'; import { addMessage, selectThread } from '../../shared/threads/threads.actions'; import { getChannels, getDirectMessages, getCurrentThread } from '../../shared/threads/threads.selectors'; import { getCurrentUser } from '../../shared/users/users.selectors'; const ChatPageCompone...
import template from './chat-page.html'; import { addMessage, selectThread } from '../../shared/threads/threads.actions'; import { getChannels, getDirectMessages, getCurrentThread } from '../../shared/threads/threads.selectors'; import { getCurrentUser } from '../../shared/users/users.selectors'; const ChatPageCompone...
Fix param in sendMessage function
Fix param in sendMessage function
JavaScript
mit
LoganDupont/ModernAngularJS_SlackCloneApp,LoganDupont/ModernAngularJS_SlackCloneApp
6d8fa310489c313f41e2413c355f53e10e6c8874
dist/build-package.js
dist/build-package.js
var exec = require('child_process').exec; function puts(error, stdout, stderr) { console.log(stdout) } var os = require('os'); //control OS //then run command depengin on the OS if (os.type() === 'Linux') exec("dist/package.sh", puts); else if (os.type() === 'Darwin') exec("dist/package.sh", puts); else if ...
var spawn = require('child_process').spawn; var os = require('os'); if (os.type() === 'Linux') { spawn('bash', ['dist/package.sh'], {stdio: 'inherit'}); } else if (os.type() === 'Darwin') { spawn('bash', ['dist/package.sh'], {stdio: 'inherit'}); } else if (os.type() === 'Windows_NT') { spawn('powershell', ['d...
Build script: Replace `exec` with `spawn`
Build script: Replace `exec` with `spawn`
JavaScript
agpl-3.0
threema-ch/threema-web,threema-ch/threema-web,threema-ch/threema-web,threema-ch/threema-web,threema-ch/threema-web
6aa70081f55feefc106b2c2cfaae369ab8d74d60
packages/container/lib/index.js
packages/container/lib/index.js
/* Public API for the container is still in flux. The public API, specified on the application namespace should be considered the stable API. // @module container @private */ import Registry from 'container/registry'; import Container from 'container/container'; import { getOwner, setOwner } from 'container/owner'; ...
/* Public API for the container is still in flux. The public API, specified on the application namespace should be considered the stable API. // @module container @private */ import Registry from './registry'; import Container from './container'; import { getOwner, setOwner } from './owner'; export { Registry, Cont...
Use relative imports for container.
Use relative imports for container.
JavaScript
mit
jaswilli/ember.js,qaiken/ember.js,karthiick/ember.js,workmanw/ember.js,szines/ember.js,bekzod/ember.js,alexdiliberto/ember.js,patricksrobertson/ember.js,GavinJoyce/ember.js,davidpett/ember.js,Leooo/ember.js,bekzod/ember.js,miguelcobain/ember.js,mixonic/ember.js,trentmwillis/ember.js,runspired/ember.js,bantic/ember.js,S...
bb370e1138ecd46f7bcff9b3b5c28776a294913d
src/chrome/notification.js
src/chrome/notification.js
export class Notification { /** * @typedef NotificationData * @property {boolean} [read] * @property {string} title * @property {string} message * @property {('basic'|'sms')} [type='basic'] * @property {string} [date] * @property {object} [metadata] */ /** * * @param {NotificationData...
export class Notification { /** * @typedef NotificationData * @property {boolean} [read] * @property {string} title * @property {string} message * @property {('basic'|'sms')} [type='basic'] * @property {number} [date] * @property {object} [metadata] */ /** * * @param {NotificationData...
Change date to unix timestamp
Change date to unix timestamp
JavaScript
mit
nextgensparx/quantum-router,nextgensparx/quantum-router
45c8577d518fe8ef347d8bd6bde2773c0aa73447
src/rails-route-builder.js
src/rails-route-builder.js
import Axios from 'axios' import PathBuilder from './path-builder' class RailsRouteBuilder { constructor (configs = {}) { // TODO // Make an option for switching to GET for destroy actions this.pathBuilder = new PathBuilder } // // RESTful Actions // index (...args) { this.list(args) } ...
import PathBuilder from './path-builder' class RailsRouteBuilder { constructor (configs = {}) { // TODO // Make an option for switching to GET for destroy actions this.pathBuilder = new PathBuilder() } // // RESTful Actions // index (...args) { this.list(args) } list (resource, params...
Fix js style on RailsRouteBuilder
Fix js style on RailsRouteBuilder
JavaScript
mit
victor-am/rails-ranger,victor-am/rails-ranger
26b3a8b2e635d56a16b8ed745cba49ff213870bf
src/scripts/utils/fetch.js
src/scripts/utils/fetch.js
var Promise = require('es6-promise').Promise; function fetch(options) { return new Promise(function(resolve, reject) { var xhr = new XMLHttpRequest(); xhr.onload = function() { if(xhr.getResponseHeader('content-type').search('application/json') >= 0) { try { var response = JSON.par...
var Promise = require('es6-promise').Promise; function fetch(options) { return new Promise(function(resolve, reject) { var xhr = new XMLHttpRequest(); xhr.onload = function() { if(xhr.getResponseHeader('content-type').search('application/json') >= 0) { try { var response = JSON.par...
Fix Fetch util reject case
Fix Fetch util reject case
JavaScript
apache-2.0
yrezgui/dokomygp
e5edfa25835ab4f2c07d0728cbcb742c6e3574ac
app/assets/javascripts/respondent/accept_answer.js
app/assets/javascripts/respondent/accept_answer.js
$(document).ready(function() { $(document).on('click', '.accept-btn', function(e) { e.preventDefault(); answer = $(this).closest('.delegate-text-answer').find('textarea').val(); text_answer = $(this).closest('.answer_fields_wrapper').find('.text-answer') $(text_answer).find('.text-answer-field').val(a...
$(document).ready(function() { $(document).on('click', '.accept-btn', function(e) { e.preventDefault(); answer = $(this).closest('.delegate-text-answer').find('textarea').val(); text_answer = $(this).closest('.answer_fields_wrapper').find('.text-answer') text_answer_field = $(text_answer).find('.text-...
Add dirty class to text answer to trigger save afterwards
Add dirty class to text answer to trigger save afterwards
JavaScript
bsd-3-clause
unepwcmc/ORS,unepwcmc/ORS,unepwcmc/ORS,unepwcmc/ORS,unepwcmc/ORS
4d08209582575954aa0c13c7316883aa9fd63d6f
app/assets/javascripts/taskar/sections/feedback.js
app/assets/javascripts/taskar/sections/feedback.js
Taskar.Sections.Feedback = function(element){ var appear = Taskar.UI.WindowForm("feedback_form"); $("feedback_form").observe('ajax:after', function(e) { this.fade(); }); element.observe("click", function(e){ e.stop(); $("feedback_form").setStyle({ top: (e.pointerY() + 20) + "px", lef...
Taskar.Sections.Feedback = function(element){ var appear = Taskar.UI.WindowForm("feedback_form"); $("feedback_form").observe('ajax:post', function(e) { this.fade(); }); element.observe("click", function(e){ e.stop(); $("feedback_form").setStyle({ top: (e.pointerY() + 20) + "px", left: (e.p...
Remove unneeded instance of ajax:after event
Remove unneeded instance of ajax:after event
JavaScript
mit
RStankov/Taskar
711eeea3937d548c2adf9ed1ba79981f1bd52645
js/server.js
js/server.js
var http = require('http'); var util = require('./util'); var file = require('.file_system.file'); var counter=0; http.createServer(function (req, res) { var answer = util.helloWorld(); res.writeHead(200, {'Content-Type': 'text/plain'}); res.end(answer+' '+counter); counter = counter + 1; console...
var http = require('http'); var util = require('./util'); var counter=0; http.createServer(function (req, res) { var answer = util.helloWorld(); res.writeHead(200, {'Content-Type': 'text/plain'}); res.end(answer+' '+counter); counter = counter + 1; console.log(counter); }).listen(1337, '127.0.0...
FIX Delete require of non-existing file
FIX Delete require of non-existing file
JavaScript
mit
fhinkel/SimpleChatServer,fhinkel/SimpleChatServer
3f32d2e881df728b3983668b8e6a154464956e51
src/data/UserRepository.js
src/data/UserRepository.js
import { usingConnect, sql } from './pg-helpers' import Promise from 'bluebird'; import crypto from 'crypto'; import scmp from 'scmp' const pbkdf2 = Promise.promisify(crypto.pbkdf2, crypto); class User { constructor(userData) { this.id = userData.id; this.email = userData.email; this.passwordHash = user...
import { usingConnect, sql } from './pg-helpers' import Promise from 'bluebird'; import crypto from 'crypto'; import scmp from 'scmp' const pbkdf2 = Promise.promisify(crypto.pbkdf2, crypto); class User { constructor(userData) { this.id = userData.id; this.email = userData.email; this.passwordHash = user...
Fix reading of admin status for users
Fix reading of admin status for users
JavaScript
mit
googol/drinkkiarkisto,googol/drinkkiarkisto
aae3475a6fe42891175f4a6ab35224f12531f5f0
shared-styles.js
shared-styles.js
// Shared styles of highcharts-chart for polymer 3.0 import { html } from '@polymer/lit-element'; export const SharedStyles = html` <style> :host {width: 100%;display: inline-block;min-height: var(--highcharts-min-height, 26em)} :host[height-responsive] {min-height: initial} :host[height-responsive] #Chart...
// Shared styles of highcharts-chart for polymer 3.0 import { html } from '@polymer/polymer/polymer-element.js'; export const SharedStyles = html` <style> :host {width: 100%;display: inline-block;min-height: var(--highcharts-min-height, 26em)} :host[height-responsive] {min-height: initial} :host[height-res...
Use html from polymer-element.js instead
Use html from polymer-element.js instead
JavaScript
mit
avdaredevil/highcharts-chart,avdaredevil/highcharts-chart
2f8370a000f8a4718d806b55c7bff5462e29ac9d
src/encoded/static/main.js
src/encoded/static/main.js
requirejs.config({ baseUrl: '/static', paths: { antibodies: 'modules/antibodies', app: 'modules/app', assert: 'modules/assert', base: 'modules/base', home: 'modules/home', navbar: 'modules/navbar', // Plugins text: 'libs/text', // Librar...
requirejs.config({ baseUrl: '/static', paths: { antibodies: 'modules/antibodies', app: 'modules/app', assert: 'modules/assert', base: 'modules/base', home: 'modules/home', navbar: 'modules/navbar', // Plugins text: 'libs/text', // Librar...
Add backbone.hal to js module config.
Add backbone.hal to js module config.
JavaScript
mit
4dn-dcic/fourfront,philiptzou/clincoded,ENCODE-DCC/snovault,ClinGen/clincoded,hms-dbmi/fourfront,kidaa/encoded,hms-dbmi/fourfront,ClinGen/clincoded,kidaa/encoded,ENCODE-DCC/snovault,philiptzou/clincoded,4dn-dcic/fourfront,ENCODE-DCC/encoded,ENCODE-DCC/encoded,T2DREAM/t2dream-portal,kidaa/encoded,ENCODE-DCC/snovault,hms...
480ca6e607311242980aca268d2d7a20944483bd
src/serverinfo/versions.js
src/serverinfo/versions.js
import { version as nodeVersion } from 'process' import readPkgUp from 'read-pkg-up' // Caches it. // TODO: use async instead const { pkg: { version: autoserverVersion }, } = readPkgUp.sync() // Retrieve environment-specific versions export const getVersionsInfo = function() { const autoserver = `v${autoserverVe...
import { version as nodeVersion } from 'process' import readPkgUp from 'read-pkg-up' // Caches it. // TODO: use async instead const { package: { version: autoserverVersion }, } = readPkgUp.sync() // Retrieve environment-specific versions export const getVersionsInfo = function() { const autoserver = `v${autoserv...
Rename property for upgrade of read-pkg-up
Rename property for upgrade of read-pkg-up
JavaScript
apache-2.0
autoserver-org/autoserver,autoserver-org/autoserver
ef450ee7a6eabac237dd6fce63dad99153b670bf
app/reducers/meetings.js
app/reducers/meetings.js
// @flow import { Meeting } from '../actions/ActionTypes'; import { createSelector } from 'reselect'; import createEntityReducer from 'app/utils/createEntityReducer'; export default createEntityReducer({ key: 'meetings', types: { fetch: Meeting.FETCH, mutate: Meeting.CREATE }, mutate(state, action) { ...
// @flow import { Meeting } from '../actions/ActionTypes'; import { createSelector } from 'reselect'; import createEntityReducer from 'app/utils/createEntityReducer'; export default createEntityReducer({ key: 'meetings', types: { fetch: Meeting.FETCH, mutate: Meeting.CREATE }, mutate(state, action) { ...
Use js `equal value and equal type` when comparing meetingId
Use js `equal value and equal type` when comparing meetingId
JavaScript
mit
webkom/lego-webapp,webkom/lego-webapp,webkom/lego-webapp
b0137bde40fef71fb4d311fdd049d59de23d472a
server/models/locations.js
server/models/locations.js
// locations.js // caches location information from foursquare // TO-DO: Foursquare ToS says data can be stored for 30 days before it must be updated. // Any data that is older than 30 days should be removed. module.exports = function (sequelize, DataTypes) { var Location = sequelize.define('Location', { loc...
// locations.js // caches location information from foursquare // TO-DO: Foursquare ToS says data can be stored for 30 days before it must be updated. // Any data that is older than 30 days should be removed. module.exports = function (sequelize, DataTypes) { var Location = sequelize.define('Location', { fou...
Remove unnecessary locationId field from Locations table
Remove unnecessary locationId field from Locations table
JavaScript
mit
wrrnwng/partyof4,shelleywang/partyof4,wrrnwng/partyof4,Trustworthy-Hair/partyof4,shelleywang/partyof4,Trustworthy-Hair/partyof4
f7db24486663dbee912ca74a5e57d9949eff2856
ckanext/orgportals/fanstatic/goto-next-section.js
ckanext/orgportals/fanstatic/goto-next-section.js
ckan.module('orgportals_goto_next_section', function ($, _) { 'use strict'; return { initialize: function() { var nextSectionBtn = this.el; nextSectionBtn.on('click', function onNextSectionBtnClick() { var section = nextSectionBtn.closest('div[data-section]'); var nextSection, topO...
ckan.module('orgportals_goto_next_section', function ($, _) { 'use strict'; return { initialize: function() { //We don't need to go to the next section if there is only one section if ($("[data-section]").length === 1) { $(".next-section-container").hide() } var nextSectionBtn ...
Hide next section buttons if there is only one section
Hide next section buttons if there is only one section
JavaScript
agpl-3.0
ViderumGlobal/ckanext-orgportals,ViderumGlobal/ckanext-orgportals,ViderumGlobal/ckanext-orgportals,ViderumGlobal/ckanext-orgportals
fe2a52fae2539c03433cf069f513714678388c41
js/BreadCrumbService.js
js/BreadCrumbService.js
myApp.service('breadCrumbService', function($location) { this.crumbs = [ ]; this.current = { path: './', display:'Inventories' }; this.update = function(crumb) { console.log("Updating crumbs:", crumb); var index = this.crumbs.findIndex(function(c) { ret...
myApp.service('breadCrumbService', function($location) { this.crumbs = [ ]; this.current = { path: './', display:'Inventories' }; this.update = function(crumb) { console.log("Updating crumbs:", crumb); if(this.current.path === crumb.path || crumb.path === '/') ...
Add guard clause to beginning of update method
Add guard clause to beginning of update method
JavaScript
cc0-1.0
zcdunn/inventory,zcdunn/inventory
f34d0b2873b162177a92d0a5b2f0a7d9535f7492
src/js/utils/app-router.js
src/js/utils/app-router.js
import * as Backbone from 'backbone'; import SearchView from '../search/views/search-view'; import Messages from './messenger'; class AppRouter extends Backbone.Router { get routes() { return { 'search/(?q=*queryString)': 'search' }; } initialize() { this.listenTo(Messages, 'router:go', this....
import * as Backbone from 'backbone'; import SearchAppView from '../search/views/searchApp-view'; import Messages from './messenger'; class AppRouter extends Backbone.Router { get routes() { return { 'search/(?q=*queryString)': 'search' }; } initialize() { this.listenTo(Messages, 'router:go',...
Add 'app' to name of main view in search module
Add 'app' to name of main view in search module
JavaScript
mit
trevormunoz/katherine-anne,trevormunoz/katherine-anne,trevormunoz/katherine-anne
d0eb6cdbc315e750a4bed9a1520a279db1e825c1
app/js/components/translation_ui.js
app/js/components/translation_ui.js
$(document).ready(function() { function initTinyMceTextarea(event) { var targetRow = $(event.target).parents('tr'); if (targetRow.find('td:contains(".help"),td:contains(".html"),td:contains(".information.")').length) { var textarea = targetRow.find('textarea'); if (!textarea....
$(document).ready(function() { function initTinyMceTextarea(event) { var targetRow = $(event.target).parents('tr'); if (targetRow.find('td:contains(".help"),td:contains(".html"),td:contains(".information.")').length) { var textarea = targetRow.find('textarea'); if (!textarea....
Fix saving of HTML translation messages
Fix saving of HTML translation messages The messages were not saved after pressing the button. We now update the textarea manually after each tinymce change event.
JavaScript
apache-2.0
SURFnet/sp-dashboard,SURFnet/sp-dashboard,SURFnet/sp-dashboard,SURFnet/sp-dashboard,SURFnet/sp-dashboard
31b7b0aae04a99d532e7122c023bdcce19c21346
server/services/file-service/local-client.js
server/services/file-service/local-client.js
/* The Conflict of Interest (COI) module of Kuali Research Copyright © 2005-2016 Kuali, Inc. This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the Lic...
/* The Conflict of Interest (COI) module of Kuali Research Copyright © 2005-2016 Kuali, Inc. This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the Lic...
Check for characters in file path
RESCOI-876: Check for characters in file path
JavaScript
agpl-3.0
kuali/research-coi,kuali/research-coi
dd0e3b85b1ac47c3342b2a282cd5b7432481b1e6
assets/js/voting.js
assets/js/voting.js
(function ( $ ) { "use strict"; $(function () { // catch the upvote/downvote action $( 'div.karma' ).on( 'click', 'span > a', function( e ){ e.preventDefault(); var value = 0; var comment_id = $(this).data('commentId'); if ( $(this).hasClass( 'add-karma' ) ) { value = 1; } else if( $(this).ha...
(function ( $ ) { "use strict"; $(function () { // catch the upvote/downvote action $( 'div.comment-weight-container' ).on( 'click', 'span > a', function( e ){ e.preventDefault(); var value = 0; var comment_id = $(this).data('commentId'); if ( $(this).hasClass( 'vote-up' ) ) { value = 1; } el...
Use weight terminology instead of karma
Use weight terminology instead of karma Signed-off-by: Paul de Wouters <a027184a55211cd23e3f3094f1fdc728df5e0500@hmn.md>
JavaScript
mit
humanmade/comment-popularity,humanmade/comment-popularity,humanmade/comment-popularity,humanmade/comment-popularity
3e785d3fafb0a4a6f809830c0f4588db7c6bcae2
src/assets/scripts/controllers/quality-comparison-controller.js
src/assets/scripts/controllers/quality-comparison-controller.js
import { Controller } from 'stimulus' import '@ap-spectrum-web-components/slider' import '@spectrum-web-components/theme/lib/theme-lightest' import '@spectrum-web-components/theme/lib/scale-large' import '@spectrum-web-components/theme/lib/theme' export default class extends Controller { static targets = ['image'] ...
import { Controller } from 'stimulus' // import '@ap-spectrum-web-components/slider' // import '@spectrum-web-components/theme/lib/theme-lightest' // import '@spectrum-web-components/theme/lib/scale-large' // import '@spectrum-web-components/theme/lib/theme' export default class extends Controller { static targets =...
Disable troublesome imports for now
Disable troublesome imports for now
JavaScript
mpl-2.0
alexpeattie/alexpeattie.com,alexpeattie/alexpeattie.com,alexpeattie/alexpeattie.com
d252c40727f4b9e3b0ae06a4db89f4ad580b42b2
js/views/article_view.js
js/views/article_view.js
Kpcc.ArticleView = Ember.View.extend({ didInsertElement: function() { $('body').scrollTop(0).addClass('article'); } });
Kpcc.ArticleView = Ember.View.extend({ didInsertElement: function() { this.scrollToTop() this.addBodyClass() }, modelChanged: function() { this.scrollToTop() }.observes('controller.model'), scrollToTop: function() { $('body').scrollTop(0) }, addBodyClass: f...
Make page scroll to top when switching between articles
Make page scroll to top when switching between articles
JavaScript
mit
SCPR/kpcc-reader,SCPR/kpcc-reader,bricker/KPCC-Reader,bricker/KPCC-Reader,SCPR/kpcc-reader
f95e386233f99207a08a566742a02fff34828aa1
lib/index.js
lib/index.js
var Client = require('client'), Utils = require('utils'), ZAFClient = {}; /// ### ZAFClient API /// /// When you include the ZAF SDK on your website, you get access to the `ZAFClient` object. /// /// #### ZAFClient.init([callback(context)]) /// /// Returns a [`client`](#client-object) object. /// /// ##...
var Client = require('client'), Utils = require('utils'), ZAFClient = {}; /// ### ZAFClient API /// /// When you include the ZAF SDK on your website, you get access to the `ZAFClient` object. /// /// #### ZAFClient.init([callback(context)]) /// /// Returns a [`client`](#client-object) object. /// /// ##...
Support hash params for origin and app guid
Support hash params for origin and app guid
JavaScript
apache-2.0
zendesk/zendesk_app_framework_sdk,zendesk/zendesk_app_framework_sdk,zendesk/zendesk_app_framework_sdk
d4356d9a7ad1cad9fbb5ad4a8e6f2f3ae6922442
apps/store/themes/store/js/asset.js
apps/store/themes/store/js/asset.js
$(function () { $('#btn-add-gadget').click(function () { var elem = $(this); asset.process(elem.data('type'), elem.data('aid'), location.href, elem); }); $('#btn-remove-subscribe').click(function () { var elem = $(this); asset.unsubscribeBookmark(elem.data('type'), elem.data...
$(function () { $('.action-container').on( { mouseenter: function () { $(this).find("i").removeClass().addClass("fa fa-remove"); }, mouseleave: function () { $(this).find("i").removeClass().addClass("fa fa-star"); }, ...
Fix for STORE-1330: Remove direct binding of `click` API to `on`
Fix for STORE-1330: Remove direct binding of `click` API to `on`
JavaScript
apache-2.0
jeradrutnam/carbon-store,Rajith90/carbon-store,madawas/carbon-store,thushara35/carbon-store,daneshk/carbon-store,jeradrutnam/carbon-store,daneshk/carbon-store,daneshk/carbon-store,splinter/carbon-store,wso2/carbon-store,cnapagoda/carbon-store,prasa7/carbon-store,jeradrutnam/carbon-store,cnapagoda/carbon-store,madawas/c...
ff3eab83c057109b2b755cc6d32c5747997e3df4
addon/serializers/pouch.js
addon/serializers/pouch.js
import DS from 'ember-data'; export default DS.RESTSerializer.extend({ _shouldSerializeHasMany: function() { return true; }, // This fixes a failure in Ember Data 1.13 where an empty hasMany // was saving as undefined rather than []. serializeHasMany(snapshot, json, relationship) { this._super.apply...
import Ember from 'ember'; import DS from 'ember-data'; const { get } = Ember; const keys = Object.keys || Ember.keys; export default DS.RESTSerializer.extend({ _shouldSerializeHasMany: function() { return true; }, // This fixes a failure in Ember Data 1.13 where an empty hasMany // was saving as undef...
Change serializer so that attachments are passed to and from relational-couch correctly
Change serializer so that attachments are passed to and from relational-couch correctly
JavaScript
apache-2.0
nolanlawson/ember-pouch,nolanlawson/ember-pouch,pouchdb-community/ember-pouch,pouchdb-community/ember-pouch
53deb74b1fdf3dc7cb88ec54580d2d0c0b24df45
app/prelude2.js
app/prelude2.js
(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...
(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:{}};var R=(e)=>{var n=t[o][1][e];return s(n?n:e)};R.resolve=(m)=>{console.log('...
Implement require.resolve(), log and return module name given
Implement require.resolve(), log and return module name given https://github.com/deathcap/webnpm/issues/5 Implement require.resolve
JavaScript
mit
deathcap/nodeachrome,deathcap/nodeachrome,deathcap/nodeachrome
eb278fb6040eb9fc8ed4669d8afe7fffe72c3847
app/common/utils/formatUpcomingReviews.js
app/common/utils/formatUpcomingReviews.js
/* eslint-disable no-return-assign */ import { format, addHours, addDays } from 'date-fns'; const formatUpcomingReviews = (data = []) => { let extraDays = 0; const getFutureDayName = (daysAhead = 0) => format(addDays(new Date(), daysAhead), 'dddd'); const genDay = (hour) => (hour === '12am' ? getFutureDayName((e...
/* eslint-disable no-return-assign */ import { format, addHours, addDays } from 'date-fns'; const formatUpcomingReviews = (data = []) => { let extraDays = 0; const getFutureDayName = (daysAhead = 0) => format(addDays(new Date(), daysAhead), 'dddd'); const genDay = (hour) => (hour === '12am' ? getFutureDayName((e...
Remove extra hour in upcoming review formatter
Remove extra hour in upcoming review formatter
JavaScript
mit
Kaniwani/KW-Frontend,Kaniwani/KW-Frontend
9f039fdba867dca810bb293e0d6c5bc0a8473ecd
src/SearchUrl.js
src/SearchUrl.js
import React from 'react'; import './SearchUrl.css'; function SearchUrl(props) { const searchUrl = decodeURI(props.searchUrl.substring(59)); return ( <div className="SearchUrl"> {searchUrl} </div> ); } export default SearchUrl;
import React from 'react'; import './SearchUrl.css'; function SearchUrl(props) { const searchUrl = decodeURI(props.searchUrl.substring(59)); return ( <div className="SearchUrl"> <code>{searchUrl}</code> </div> ); } export default SearchUrl;
Use fixed-width font to display urls
Use fixed-width font to display urls
JavaScript
mit
bbokorney/hold-my-beer,bbokorney/hold-my-beer
dd3c9948fefe7018e535a1b49505b4bbe210ec87
module/eCampWeb/vue/webpack/config.development.js
module/eCampWeb/vue/webpack/config.development.js
const merge = require('webpack-merge') const webpack = require('webpack') const WebpackAssetsManifest = require('webpack-assets-manifest') const WEBPACK_DEV_SERVER = 'http://localhost:8080' module.exports = function () { process.env.NODE_ENV = 'development' return merge(require('./config.base.js'), { mode: '...
const merge = require('webpack-merge') const webpack = require('webpack') const WebpackAssetsManifest = require('webpack-assets-manifest') const WEBPACK_DEV_SERVER = 'http://localhost:8080' module.exports = function () { process.env.NODE_ENV = 'development' return merge(require('./config.base.js'), { mode: '...
Add bundle name in dev mode
Add bundle name in dev mode
JavaScript
agpl-3.0
pmattmann/ecamp3,ecamp/ecamp3,usu/ecamp3,pmattmann/ecamp3,usu/ecamp3,ecamp/ecamp3,pmattmann/ecamp3,ecamp/ecamp3,usu/ecamp3,pmattmann/ecamp3,ecamp/ecamp3,usu/ecamp3
95a4a2ad8f5236d7d4fefdfb30d986a73c72915a
packages/pack/webpack/optimization.js
packages/pack/webpack/optimization.js
const os = require('os'); const TerserPlugin = require('terser-webpack-plugin'); /** * parallel doesn't work yet for WSL (GNU/Linux on Windows) * cf https://github.com/webpack-contrib/terser-webpack-plugin/issues/21 * https://github.com/webpack-contrib/uglifyjs-webpack-plugin/issues/302 * @return {Boolean} true if...
const os = require('os'); const TerserPlugin = require('terser-webpack-plugin'); /** * parallel doesn't work yet for WSL (GNU/Linux on Windows) * cf https://github.com/webpack-contrib/terser-webpack-plugin/issues/21 * https://github.com/webpack-contrib/uglifyjs-webpack-plugin/issues/302 * @return {Boolean} true if...
Add back support for safari10
Add back support for safari10
JavaScript
mit
ProtonMail/WebClient,ProtonMail/WebClient,ProtonMail/WebClient
b6c6b23215158d43a4766d25e13c8ce4f7d16488
lib/gulp/tasks/server.js
lib/gulp/tasks/server.js
'use strict'; import config from '../config'; import gulp from 'gulp'; import browserSync from 'browser-sync'; var reload_delay = 1000; gulp.task('server', function() { console.log('BROWSER SYNC ENABLED ON PORT ' + config.server.port + ' & NAME: ' + config.server.name) browserSync.init({ server: ...
'use strict'; import config from '../config'; import gulp from 'gulp'; import browserSync from 'browser-sync'; var reload_delay = 1000; gulp.task('server', function() { console.log('----------------------------') console.log('BROWSER SYNC ENABLED ON PORT ' + config.server.port + ' & NAME: ' + config....
ADD CONSOLE LOG / BROWSER SYNC
ADD CONSOLE LOG / BROWSER SYNC
JavaScript
mit
russiansoon/gulp-start,russiansoon/gulp-start
76f4bffaed358b3193b5e22069c946d0575c3f9a
src/schemas/card-schema.js
src/schemas/card-schema.js
const mongoose = require('mongoose'); const Schema = mongoose.Schema; const CardSchema = new Schema({ name: { type: String, unique: true, require: true, }, idName: { type: String, unique: true, require: true, }, rarity: { type: String, enum: 'Common Rare Epic Legendary'.spl...
const mongoose = require('mongoose'); const Schema = mongoose.Schema; const CardSchema = new Schema({ name: { type: String, unique: true, require: true, }, idName: { type: String, unique: true, require: true, }, rarity: { type: String, enum: 'Common Rare Epic Legendary'.spl...
Add copyId to card schema
Add copyId to card schema
JavaScript
mit
martincarrera/clash-royale-api,martincarrera/clash-royale-api
47bcd63ceb4cc42b39c0b34432ec662e203bf4dd
packages/truffle-provisioner/index.js
packages/truffle-provisioner/index.js
var provision = function(abstraction, options) { var self = this; // eslint-disable-line no-unused-vars if (options.provider) { abstraction.setProvider(options.provider); } if (options.network_id) { abstraction.setNetwork(options.network_id); } if (options.network && options.networks) { abstr...
var provision = function(abstraction, options) { var self = this; // eslint-disable-line no-unused-vars if (options.provider) { abstraction.setProvider(options.provider); } if (options.network_id) { abstraction.setNetwork(options.network_id); } if (options.network && options.networks) { abstr...
Add ens settings to the contract objects
Add ens settings to the contract objects
JavaScript
mit
ConsenSys/truffle
066b06936ab78ddac7c1cf5f81d6ece27c7d06d0
taglibs/core/AssignNode.js
taglibs/core/AssignNode.js
/* * Copyright 2011 eBay Software Foundation * * 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 o...
/* * Copyright 2011 eBay Software Foundation * * 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 o...
Remove varNameRegExp since it's never used;
Remove varNameRegExp since it's never used;
JavaScript
mit
marko-js/marko,marko-js/marko
440886f3037d157d4bc040223263873bd264dd22
lib/helpers/retrieve.js
lib/helpers/retrieve.js
'use strict'; function retrieveContact(conn, date, limit, offset, cb) { conn.sobject("Contact") .select('Id, IsDeleted, FirstName, LastName, Name, Phone, Fax, MobilePhone, MailingStreet, HomePhone, OtherPhone, AssistantPhone, Email, Title, Birthdate, PhotoUrl, CreatedDate, LastModifiedDate') .where('LastModi...
'use strict'; function retrieveContact(conn, date, limit, offset, cb) { conn.sobject("Contact") .select('Id, IsDeleted, FirstName, LastName, Name, Phone, Fax, MobilePhone, MailingStreet, HomePhone, OtherPhone, AssistantPhone, Email, Title, Birthdate, PhotoUrl, CreatedDate, LastModifiedDate') .where('LastModi...
Stop retrieving contact with offset > 2000
Stop retrieving contact with offset > 2000
JavaScript
mit
AnyFetch/salesforce-provider.anyfetch.com
c1330b3e685ca1ab4bc41ab16bc47631afab887a
lib/mpd-child-process.js
lib/mpd-child-process.js
var Q = require('Q'), childProcess = require('child_process'); function processPath(exec) { var exec = exec || Q.denodeify(childProcess.exec); var deferred = Q.defer(); function handleDone(stdout, stderr) { var location = stdout[0].trim().replace(/\n$/, ''); deferred.resolve(location); } funct...
var Q = require('Q'), childProcess = require('child_process'); function processPath(exec) { var exec = exec || Q.denodeify(childProcess.exec); var deferred = Q.defer(); function handleDone(stdout, stderr) { var location = stdout[0].trim().replace(/\n$/, ''); deferred.resolve(location); } funct...
Add failure message when MPD path is not found
Add failure message when MPD path is not found
JavaScript
apache-2.0
radiodan/radiodan.js,radiodan/radiodan.js
4ffc4e3768e5f2044d3a3d5b6051c542fcde6765
tasks/browser-sync-init.js
tasks/browser-sync-init.js
module.exports = function(gulp, settings) { // Create the browserSync server. settings.dynamic.browserSync = require('browser-sync').create(); /** * Initialize the browser sync server (static). */ gulp.task('browser-sync-init', function() { settings.dynamic.browserSync.init({ ...
module.exports = function(gulp, settings) { // Create the browserSync server. settings.dynamic.browserSync = require('browser-sync').create(); /** * Initialize the browser sync server (static). */ gulp.task('browser-sync-init', ['build-tests'], function(cb) { settings.dynamic.browserS...
Build tests before initializing BrowserSync
Build tests before initializing BrowserSync
JavaScript
agpl-3.0
tephyr/simpleshelf,tephyr/simpleshelf,tephyr/simpleshelf,tephyr/simpleshelf