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
d99736f34d2001921c487fd987ae55e3b6c05a29
lib/parse/block-element.js
lib/parse/block-element.js
import Set from 'es6-set'; import blockElements from 'block-elements'; const BLOCK_ELEMENTS = new Set(blockElements); const TEXT_ELEMENTS = { h1: 'header1', h2: 'header2', h3: 'header3', h4: 'header4', h5: 'header5', h6: 'header6', p: 'paragraph', blockquote: 'blockquote' }; const isPullQuote = (elm) ...
import Set from 'es6-set'; import blockElements from 'block-elements'; const BLOCK_ELEMENTS = new Set(blockElements); const TEXT_ELEMENTS = { h1: 'header1', h2: 'header2', h3: 'header3', h4: 'header4', h5: 'header5', h6: 'header6', p: 'paragraph', blockquote: 'blockquote' }; const isPullQuote = (elm) ...
Create new object instead of modifying, to make sure they are optimized by V8
Create new object instead of modifying, to make sure they are optimized by V8
JavaScript
mit
micnews/html-to-article-json,micnews/html-to-article-json
87f3710f43e5fd2d899de6b1b74cad716e154b5b
addon/components/lt-row.js
addon/components/lt-row.js
import Ember from 'ember'; import layout from 'ember-light-table/templates/components/lt-row'; const { Component, computed } = Ember; const Row = Component.extend({ layout, tagName: 'tr', classNames: ['lt-row'], classNameBindings: ['isSelected', 'isExpanded', 'canExpand:is-expandable', 'canSelect:is-selec...
import Ember from 'ember'; import layout from 'ember-light-table/templates/components/lt-row'; const { Component, computed } = Ember; const Row = Component.extend({ layout, tagName: 'tr', classNames: ['lt-row'], classNameBindings: ['isSelected', 'isExpanded', 'canExpand:is-expandable', 'canSelect:is-selec...
Fix typo for default colspan
Fix typo for default colspan
JavaScript
mit
offirgolan/ember-light-table,offirgolan/ember-light-table
95c064b50ff7d7d174b778a4f50dc1a9fca83925
src/activities/pizza/shared/parameters.js
src/activities/pizza/shared/parameters.js
define({ RoundCount: 2, MinPlayers: 4, RoundDuration: 90000 });
define({ RoundCount: 4, MinPlayers: 4, RoundDuration: 90000 });
Increase round count for Pizza Productivity
Increase round count for Pizza Productivity
JavaScript
mpl-2.0
councilforeconed/interactive-activities,jugglinmike/cee,councilforeconed/interactive-activities,jugglinmike/cee,councilforeconed/interactive-activities
2127952f1775686e8da53a55e23b236e0d6e67d0
src/modules/Assetic.js
src/modules/Assetic.js
import layout from '../../config/layout' const fixLocalAsset = assets => ( (Array.isArray(assets) ? assets : [assets]).map(asset => `/${asset}`) ) export const getAssets = (localAssets = []) => ( Array.concat( layout.script.map(item => item.src), layout.link.map(item => item.href), localAssets.map(ass...
import layout from '../../config/layout' const fixLocalAsset = assets => ( (Array.isArray(assets) ? assets : [assets]).map(asset => `/${asset}`) ) const normalizeAssets = assets => { let normalized = [] assets.forEach(item => { if (Array.isArray(item)) { item.forEach(asset => { normalized.pus...
Fix issue with multi dimensional arrays
Fix issue with multi dimensional arrays
JavaScript
mit
janoist1/universal-react-redux-starter-kit
2dd837ca80ea7ff8f357de0408c41f9f1cd627be
tests/functional/routes.js
tests/functional/routes.js
'use strict'; /*global describe, it*/ var path = require('path'); var request = require('supertest'); var utils = require('../../lib/utils'); var app = require('../../app'); var routes = utils.requireDir(path.join(__dirname, '../../routes/')); var host = process.env.manhattan_context__instance_hostname || ...
'use strict'; /*global describe, it*/ var path = require('path'); var request = require('supertest'); var utils = require('../../lib/utils'); var app = require('../../app'); var routes = utils.requireDir(path.join(__dirname, '../../routes/')); var host = process.env.manhattan_context__instance_hostname || '...
Revert "Log which host is being functionally tested"
Revert "Log which host is being functionally tested" This reverts commit 824ec144553499911160779833d978d282e88be6.
JavaScript
bsd-3-clause
ericf/formatjs-site,ericf/formatjs-site
e55ba7f94a1e71c372881c423c7256b4acf0eba6
web/webpack/plugins/recipes.js
web/webpack/plugins/recipes.js
const config = require('./config'); const pwaOptions = require('./pwaConfig'); const PUBLIC_PATH = config.PUBLIC_PATH; /** * optional plugins enabled by enabling their recipe. * once enabled they succeed being required and get added to plugin list. * order them in the order they should be added to the plugin lists...
const config = require('./config'); const pwaOptions = require('./pwaConfig'); const PUBLIC_PATH = config.PUBLIC_PATH; /** * optional plugins enabled by enabling their recipe. * once enabled they succeed being required and get added to plugin list. * order them in the order they should be added to the plugin lists...
Fix using preload-webpack-plugin, not resource-hints-plugin
Fix using preload-webpack-plugin, not resource-hints-plugin
JavaScript
mit
c-h-/universal-native-boilerplate,c-h-/universal-native-boilerplate,c-h-/universal-native-boilerplate,c-h-/universal-native-boilerplate,c-h-/universal-native-boilerplate
55a1f8d049c622edd4f68a6d9189c92e4adfe674
lib/normalize-condition.js
lib/normalize-condition.js
var buildMoldsSelector = require('./build-molds-selector'); module.exports = function normalizeCondition(condition, alias) { var moldsSelector = buildMoldsSelector(alias); var moldSelected; var normalized; while(moldSelected = moldsSelector.exec(condition)) { normalized = condition.replace( moldSelected[0],...
var buildMoldsSelector = require('./build-molds-selector'); module.exports = function normalizeCondition(condition, alias) { var moldsSelector = buildMoldsSelector(alias); var moldSelected; while(moldSelected = moldsSelector.exec(condition)) { condition = condition.replace( new RegExp(moldSelected[0], 'g'), ...
Add support of multiple molds per condition
Add support of multiple molds per condition
JavaScript
mit
qron/ongine
b91f38017839b3ca0928cf3f145a71f172efd49f
src/components/Header.js
src/components/Header.js
import React, { Component } from 'react'; import Button from './Button'; export default class Header extends Component { render() { return ( <div className="App-header"> <div className="header-wrap"> <div className="header-content"> <h1>Connect. Collaborate. Create.</h...
import React, { Component } from 'react'; import Button from './Button'; export default class Header extends Component { render() { return ( <div className="App-header"> <div className="header-wrap"> <div className="header-content"> <h1>Connect. Collaborate. Create.</h...
Add slashes to buttons on homepage
Add slashes to buttons on homepage
JavaScript
mit
theCoolKidsJavaScriptMeetup/cuddlyGuacamole,theCoolKidsJavaScriptMeetup/PeoriaHackathon,theCoolKidsJavaScriptMeetup/PeoriaHackathon,theCoolKidsJavaScriptMeetup/cuddlyGuacamole
662b688b40b49f0d2300f935502891dc55289541
public/docs.js
public/docs.js
var showing = null function hashChange() { var hash = document.location.hash.slice(1) var found = document.getElementById(hash), prefix, sect if (found && (prefix = /^([^\.]+)/.exec(hash)) && (sect = document.getElementById("part_" + prefix[1]))) { if (!sect.style.display) { sect.style.display = "block...
var showing = null function hashChange() { var hash = decodeURIComponent(document.location.hash.slice(1)) var found = document.getElementById(hash), prefix, sect if (found && (prefix = /^([^\.]+)/.exec(hash)) && (sect = document.getElementById("part_" + prefix[1]))) { if (!sect.style.display) { sect.st...
Fix problem with navigating to static methods in the reference guide
Fix problem with navigating to static methods in the reference guide
JavaScript
mit
ProseMirror/website,ProseMirror/website
b08a4b1fe56352ad9dc30ef1a8dbc1498db46261
core/client/components/gh-notification.js
core/client/components/gh-notification.js
var NotificationComponent = Ember.Component.extend({ classNames: ['js-bb-notification'], typeClass: function () { var classes = '', message = this.get('message'), type, dismissible; // Check to see if we're working with a DS.Model or a plain JS object ...
var NotificationComponent = Ember.Component.extend({ classNames: ['js-bb-notification'], typeClass: function () { var classes = '', message = this.get('message'), type, dismissible; // Check to see if we're working with a DS.Model or a plain JS object ...
Check the end of notification fade-out animation
Check the end of notification fade-out animation
JavaScript
mit
javorszky/Ghost,allanjsx/Ghost,francisco-filho/Ghost,mlabieniec/ghost-env,Sebastian1011/Ghost,metadevfoundation/Ghost,lanffy/Ghost,Kikobeats/Ghost,zeropaper/Ghost,v3rt1go/Ghost,epicmiller/pages,smaty1/Ghost,panezhang/Ghost,gabfssilva/Ghost,bsansouci/Ghost,thinq4yourself/Unmistakable-Blog,arvidsvensson/Ghost,Jai-Chaudha...
8fe37e614d9848352258d60339c7415bdee12a5c
tests/Resources/minify/expected/regexes.js
tests/Resources/minify/expected/regexes.js
function testIssue74(){return/'/;} !function(s){return/^[£$€?.]/.test(s);}();typeof / ' /;x=/ [/] /;1/foo;(2)/foo;function(){return/foo/};function(){return typeof/foo/};
function testIssue74(){return/'/;} !function(s){return/^[£$€?.]/.test(s);}();typeof/ ' /;x=/ [/] /;1/foo;(2)/foo;function(){return/foo/};function(){return typeof/foo/};
Remove line break between typedef and regexp to be consistent with the other code places.
Remove line break between typedef and regexp to be consistent with the other code places.
JavaScript
bsd-3-clause
mrclay/jsmin-php,mrclay/jsmin-php
e5c1148583b076e9bdfb1c35e02c579ade240e3c
index.js
index.js
var doc = require('doc-js'); module.exports = function(hoverClass, selector){ var down = [], selector = selector || 'button, a', hoverClass = hoverClass || 'hover'; doc(document).on('touchstart mousedown', selector, function(event){ var target = doc(event.target).closest(selector); ...
var doc = require('doc-js'); module.exports = function(hoverClass, selector){ var down = [], selector = selector || 'button, a', hoverClass = hoverClass || 'hover'; function setClasses(){ for(var i = 0; i < down.length; i++){ doc(down[i]).addClass(hoverClass); } ...
Allow hover to be canceled by a scroll
Allow hover to be canceled by a scroll
JavaScript
mit
KoryNunn/hoverclass
acb81229c6f704e0962bf102eb17f8cc479b9862
src/mmw/js/src/data_catalog/controllers.js
src/mmw/js/src/data_catalog/controllers.js
"use strict"; var App = require('../app'), router = require('../router').router, coreUtils = require('../core/utils'), models = require('./models'), views = require('./views'); var DataCatalogController = { dataCatalogPrepare: function() { if (!App.map.get('areaOfInterest')) { ...
"use strict"; var App = require('../app'), router = require('../router').router, coreUtils = require('../core/utils'), models = require('./models'), views = require('./views'); var DataCatalogController = { dataCatalogPrepare: function() { if (!App.map.get('areaOfInterest')) { ...
Clear results from map on datacatalog cleanup
BiGCZ: Clear results from map on datacatalog cleanup
JavaScript
apache-2.0
WikiWatershed/model-my-watershed,WikiWatershed/model-my-watershed,WikiWatershed/model-my-watershed,WikiWatershed/model-my-watershed,WikiWatershed/model-my-watershed
a15fd27717ca924eac15cda65148b691d2dc5ed7
index.js
index.js
exports.transform = require('./lib/transform') exports.estimate = require('./lib/estimate') exports.version = require('./lib/version') exports.createFromArray = function (arr) { // Create a nudged.Transform instance from an array that was // previously created with nudged.Transform#toArray(). // // Together wi...
exports.transform = require('./lib/transform') exports.estimate = require('./lib/estimate') exports.version = require('./lib/version') exports.estimate = function (type, domain, range, pivot) { // Parameter // type // string. One of the following: // 'I', 'L', 'X', 'Y', 'T', 'S', 'R', 'TS', 'TR', '...
Remove nudged.createFromArray in favor of transform.createFromArray
Remove nudged.createFromArray in favor of transform.createFromArray
JavaScript
mit
axelpale/nudged
eab61d3f8fc076b2672cb31cce5e11fc9e5f3381
web_external/Datasets/selectDatasetView.js
web_external/Datasets/selectDatasetView.js
import View from '../view'; import SelectDatasetPageTemplate from './selectDatasetPage.pug'; // View for a collection of datasets in a select tag. When user selects a // dataset, a 'changed' event is triggered with the selected dataset as a // parameter. const SelectDatasetView = View.extend({ events: { '...
import View from '../view'; import SelectDatasetPageTemplate from './selectDatasetPage.pug'; // View for a collection of datasets in a select tag. When user selects a // dataset, a 'changed' event is triggered with the selected dataset as a // parameter. const SelectDatasetView = View.extend({ events: { '...
Use a more specific event selector in SelectDatasetView
Use a more specific event selector in SelectDatasetView
JavaScript
apache-2.0
ImageMarkup/isic-archive,ImageMarkup/isic-archive,ImageMarkup/isic-archive,ImageMarkup/isic-archive
1d601875f9335bf59636cd6ecbef65c8f89d17c4
index.js
index.js
// @flow import { AppRegistry } from 'react-native'; import App from './app/App'; // import App from './app/playground/src/Navigation'; AppRegistry.registerComponent('reactNativeApp', () => App);
// @flow import { AppRegistry, YellowBox } from 'react-native'; // TODO: please check if it's still needed YellowBox.ignoreWarnings([ 'Warning: isMounted(...) is deprecated in plain JavaScript React classes.', 'Module R', // ... requires main queue setup since it overrides ... ]); import App from './app/App'; //...
Hide warnings from the React core
Hide warnings from the React core
JavaScript
mit
mrtnzlml/native,mrtnzlml/native
07efe8f7cdec6b9213668a0a9bd010beae6d689f
index.js
index.js
var bodyParser = require('body-parser') var dataUriToBuffer = require('data-uri-to-buffer') var express = require('express') var app = express() var transform = require("./transformer") // Set up some Express settings app.use(bodyParser.json({ limit: '2mb' })) app.use(express.static(__dirname + '/public')) /** * Ho...
var bodyParser = require('body-parser') var dataUriToBuffer = require('data-uri-to-buffer') var express = require('express') var app = express() /** * This is your custom transform function * move it wherever, call it whatever */ var transform = require("./transformer") // Set up some Express settings app.use(body...
Change image size limit down to 1mb per @ednapiranha
Change image size limit down to 1mb per @ednapiranha
JavaScript
mit
jasonrhodes/revisit-gifplay,revisitors/revisit.link-quickstart,florida/put-a-bird-on-it-revisit-service,jasonrhodes/H4UNT3D-H4U5
c78023ffd19f78cc9b753bcda96623323008ca08
index.js
index.js
'use strict'; var rework = require('broccoli-rework'); module.exports = { name: 'ember-cli-rework', included: function(app) { this.app = app; this.plugins = this.app.options.reworkPlugins; }, postprocessTree: function(type, tree) { if (type === 'all' || type === 'styles') { tree = autopref...
'use strict'; var rework = require('broccoli-rework'); module.exports = { name: 'ember-cli-rework', included: function(app) { this.app = app; this.plugins = this.app.options.reworkPlugins; }, postprocessTree: function(type, tree) { if (type === 'all' || type === 'styles') { tree = rework(t...
Return the tree after postprocess
Return the tree after postprocess
JavaScript
mit
johnotander/ember-cli-rework,johnotander/ember-cli-rework
e6b264d0e331489d7f713bc2e821ccc3c624158f
index.js
index.js
/*jslint node: true*/ function getCookie(req, cookieName) { var cookies = {}, output; if (req.headers.cookie) { req.headers.cookie.split(';').forEach(function (cookie) { var parts = cookie.split('='); cookies[parts[0].trim()] = parts[1].trim(); }); output ...
/*jslint node: true*/ function getCookie(req, cookieName) { var cookies = {}, cn, output; if (req.headers.cookie) { req.headers.cookie.split(';').forEach(function (cookie) { var parts = cookie.split('='); if (parts.length > 1) { cn = parts[0].trim(...
Handle domain, secure and httpOnly flags
Handle domain, secure and httpOnly flags
JavaScript
mit
Ajnasz/ajncookie
8c181f8385742ead72b4ebce3bdfd14786756162
index.js
index.js
'use strict'; const crypto = require('crypto'); // User ARN: arn:aws:iam::561178107736:user/prx-upload // Access Key ID: AKIAJZ5C7KQPL34SQ63Q const key = process.env.ACCESS_KEY; exports.handler = (event, context, callback) => { try { if (!event.queryStringParameters || !event.queryStringParameters.to_sign) { ...
'use strict'; const crypto = require('crypto'); // User ARN: arn:aws:iam::561178107736:user/prx-upload // Access Key ID: AKIAJZ5C7KQPL34SQ63Q const key = process.env.ACCESS_KEY; exports.handler = (event, context, callback) => { try { if (!event.queryStringParameters || !event.queryStringParameters.to_sign) { ...
Add CORS headers to GET response
Add CORS headers to GET response
JavaScript
agpl-3.0
PRX/upload.prx.org,PRX/upload.prx.org
dc5cf611c89c6bb4f9466f1afe0b0f81bd65ddf9
src/resolve.js
src/resolve.js
function resolve({ columns, method = () => rowData => rowData, indexKey = '_index' }) { if (!columns) { throw new Error('resolve - Missing columns!'); } return (rows = []) => { const methodsByColumnIndex = columns.map(column => method({ column })); return rows.map((rowData, rowIndex) => { ...
function resolve({ columns, method = () => rowData => rowData, indexKey = '_index' }) { if (!columns) { throw new Error('resolve - Missing columns!'); } return (rows = []) => { const methodsByColumnIndex = columns.map(column => method({ column })); return rows.map((rowData, rowIndex) => { ...
Set indexKey once per row, not per column.
Set indexKey once per row, not per column. The performance improvement depends on the number of columns, but on a real data set of 5000 rows and 11 resolved columns this improves performance by 8.7%. This does not change the result since the order of keys in the spread is unchanged.
JavaScript
mit
reactabular/table-resolver
90fc4c61301c9fd6270821e3b4af6150e8006bec
src/middleware/auth/processJWTIfExists.js
src/middleware/auth/processJWTIfExists.js
const nJwt = require('njwt'), config = require('config.js'), errors = require('feathers-errors'); function processJWTIfExists (req, res, next) { req.feathers = req.feathers || {}; let token = req.headers['authorization']; if (token == null) { let cookies = req.cookies; token = cookies.id...
const nJwt = require('njwt'), config = require('config.js'), errors = require('feathers-errors'); function processJWTIfExists (req, res, next) { req.feathers = req.feathers || {}; let token = req.headers['authorization']; console.log('line-1 ', token); if (token == null) { let cookies = r...
Add temporary console logs to help track down an auth bug sometimes found in mobile iOS Safari
Add temporary console logs to help track down an auth bug sometimes found in mobile iOS Safari
JavaScript
agpl-3.0
podverse/podverse-web,podverse/podverse-web,podverse/podverse-web,podverse/podverse-web
3cec9422a0bdfccd16f22fa1424a1bdc5a644a30
src/util/validators.js
src/util/validators.js
import validator from 'validator' import Player from '../models/player' const isValidIdForPlatform = (input, platform) => { const platformId = Player.getPlatformIdFromString(platform) return platformId !== -1 && ((platformId === 0 && isValidSteamId(input)) || (platformId === 1 && isValidPSNId(input)) || (pla...
import validator from 'validator' import Player from '../models/player' const isValidIdForPlatform = (input, platform) => { const platformId = Player.getPlatformIdFromString(platform) return platformId !== -1 && ((platformId === 0 && isValidSteamId(input)) || (platformId === 1 && isValidPSNId(input)) || (pla...
Update name validation to meet steam criteria: 2 <= length <= 32
Update name validation to meet steam criteria: 2 <= length <= 32
JavaScript
mit
hugogrochau/SAM-rank-api
5970b784543cfedc8aa09dd405ab79d50e327bdb
index.js
index.js
'use strict'; var commentMarker = require('mdast-comment-marker'); module.exports = commentconfig; /* Modify `processor` to read configuration from comments. */ function commentconfig() { var Parser = this.Parser; var Compiler = this.Compiler; var block = Parser && Parser.prototype.blockTokenizers; var inlin...
'use strict'; var commentMarker = require('mdast-comment-marker'); module.exports = commentconfig; /* Modify `processor` to read configuration from comments. */ function commentconfig() { var proto = this.Parser && this.Parser.prototype; var Compiler = this.Compiler; var block = proto && proto.blockTokenizers;...
Fix for non-remark parsers or compilers
Fix for non-remark parsers or compilers
JavaScript
mit
wooorm/mdast-comment-config,wooorm/remark-comment-config
4ae6c11508a002c4adcf23f20af5e7c8f1eb7dc3
index.js
index.js
// Constructor var RegExpParser = module.exports = {}; /** * parse * Parses a string input * * @name parse * @function * @param {String} input the string input that should be parsed as regular * expression * @return {RegExp} The parsed regular expression */ RegExpParser.parse = function (input) { // Vali...
// Constructor var RegExpParser = module.exports = {}; /** * parse * Parses a string input * * @name parse * @function * @param {String} input the string input that should be parsed as regular * expression * @return {RegExp} The parsed regular expression */ RegExpParser.parse = function(input) { // Valid...
Use a regular expression to parse regular expressions :smile:
Use a regular expression to parse regular expressions :smile:
JavaScript
mit
IonicaBizau/regex-parser.js
fee5fbe024705c8b2409b1c207f40d7bb3bc1fbe
src/js/graph/modules/focuser.js
src/js/graph/modules/focuser.js
webvowl.modules.focuser = function () { var focuser = {}, focusedElement; focuser.handle = function (clickedElement) { if (focusedElement !== undefined) { focusedElement.toggleFocus(); } if (focusedElement !== clickedElement) { clickedElement.toggleFocus(); focusedElement = clickedElement; } else...
webvowl.modules.focuser = function () { var focuser = {}, focusedElement; focuser.handle = function (clickedElement) { if (d3.event.defaultPrevented) { return; } if (focusedElement !== undefined) { focusedElement.toggleFocus(); } if (focusedElement !== clickedElement) { clickedElement.toggleFo...
Disable focusing on after dragging a node
Disable focusing on after dragging a node
JavaScript
mit
leshek-pawlak/WebVOWL,leshek-pawlak/WebVOWL,MissLoveWu/webvowl,VisualDataWeb/WebVOWL,VisualDataWeb/WebVOWL,MissLoveWu/webvowl
f0396b7679f471738e47b434543604b0ada00462
index.js
index.js
var _ = require('lodash'); var map = require('map-stream'); var pp = require('preprocess'); var path = require('path'); module.exports = function (options) { var opts = _.merge({}, options); var context = _.merge({}, process.env, opts.context); function ppStream(file, callback) { var contents, ...
var _ = require('lodash'); var map = require('map-stream'); var pp = require('preprocess'); var path = require('path'); module.exports = function (context, options) { function ppStream(file, callback) { var contents, extension; // TODO: support streaming files if (file.isNull()) return callbac...
Upgrade to new preprocess API
Upgrade to new preprocess API
JavaScript
mit
yesmeck/gulp-preprocess,patlux/gulp-preprocess,patlux/gulp-preprocess,yesmeck/gulp-preprocess
8d60c1b35b9b946915b67e9fa88107bdb22e13da
karma.conf.js
karma.conf.js
module.exports = function(config) { config.set({ basePath: '', frameworks: ['mocha', 'chai-jquery', 'jquery-2.1.0', 'chai', 'sinon-chai', 'fixture'], files: [ 'public/javascripts/vendor/d3.v3.min.js', 'public/javascripts/vendor/raphael-min.js', 'public/javascripts/vendor/morris.min.js', ...
module.exports = function(config) { config.set({ basePath: '', frameworks: ['mocha', 'chai-jquery', 'jquery-2.1.0', 'chai', 'sinon-chai', 'fixture'], files: [ 'public/javascripts/vendor/d3.v3.min.js', 'public/javascripts/vendor/raphael-min.js', 'public/javascripts/vendor/morris.min.js', ...
Remove sparkline from spec (not needed anymore)
Remove sparkline from spec (not needed anymore)
JavaScript
mit
codeforamerica/city-analytics-dashboard,codeforamerica/city-analytics-dashboard,codeforamerica/city-analytics-dashboard
53d55efbe820f9e4e8469992e2b2f193bd4de345
src/write-to-server.js
src/write-to-server.js
'use strict'; var env = require('./env.json'); function httpPost(req, cb) { var https = req.deps.https; console.log('env:', env); var postData = JSON.stringify({ metadata: req.data.s3Object.Metadata, sizes: req.data.sizes }); var options = { hostname: 'plaaant.com', port: 443, path: '/...
'use strict'; var env = require('./env.json'); function httpPost(req, cb) { var https = req.deps.https; console.log('env:', env); var postData = JSON.stringify({ metadata: req.data.s3Object.Metadata, sizes: req.data.sizes }); var options = { hostname: 'plaaant.com', port: 443, path: '/...
Add some logging to https.request
Add some logging to https.request
JavaScript
mit
guyellis/plant-image-lambda,guyellis/plant-image-lambda
831714e2bf0c396c0adcb0fe069f4d998e340889
index.js
index.js
/** * index.js * Client entry point. * * @author Francis Brito <fr.br94@gmail.com> * @license MIT */ 'use strict'; /** * Client * Provides methods to access PrintHouse's API. * * @param {String} apiKey API key identifying account owner. * @param {Object} opts Contains options to be passed to the clien...
/** * index.js * Client entry point. * * @author Francis Brito <fr.br94@gmail.com> * @license MIT */ 'use strict'; /** * Client * Provides methods to access PrintHouse's API. * * @param {String} apiKey API key identifying account owner. * @param {Object} opts Contains options to be passed to the clien...
Add default API URL for client.
Add default API URL for client.
JavaScript
mit
francisbrito/ph-node
4e543c02c682320aa46e4a90fa8fd4183e6b2588
index.js
index.js
module.exports = function() { let subscribers = [], self return self = { // remove all subscribers clear: (eventName) => { subscribers = eventName != null ? subscribers.filter(subscriber => subscriber.eventName !== eventName) : [] return self // return self to support chaining...
module.exports = function() { let subscribers = [], self return self = { // remove all subscribers clear: (eventName) => { subscribers = eventName != null ? subscribers.filter(subscriber => subscriber.eventName !== eventName) : [] return self // return self to support chaining...
Fix trigger not returning itself, but undefined
Fix trigger not returning itself, but undefined `Array.prototype.forEach` returns `undefined`
JavaScript
isc
metaraine/emitter20
8924f0f00493b836e81c09db2e161bf70a5fda48
index.js
index.js
var VOWELS = /[aeiou]/gi; var VOWELS_AND_SPACE = /[aeiou\s]/g; exports.parse = function parse(string, join){ if(typeof string !== 'string'){ throw new TypeError('Expected a string as the first option'); } var replacer = VOWELS; if (join) { replacer = VOWELS_AND_SPACE; } return string.replace(...
var VOWELS = /[aeiou]/gi; var VOWELS_AND_SPACE = /[aeiou\s]/g; exports.parse = function parse(string, join){ if(typeof string !== 'string'){ throw new TypeError('Expected a string as the first option'); } return string.replace(join ? VOWELS_AND_SPACE : VOWELS, ''); };
Move to more functional, expression-based conditionals
Move to more functional, expression-based conditionals
JavaScript
mit
lestoni/unvowel
3ca40e5d48afa58abeb523ebf9e35b7c0e7c27a2
index.js
index.js
var express = require('express'); var app = express(); var image_utils = require('./image_utils.js'); app.set('port', (process.env.PORT || 5001)); /* Search latest images search */ app.get("/api/latest/imagesearch", function(req, res) { res.end("api/latest/imagesearch/"); }); app.get("/api/imagesearch/:searchQ...
var express = require('express'); var app = express(); var image_utils = require('./image_utils.js'); app.set('port', (process.env.PORT || 5001)); /* Search latest images search */ app.get("/api/latest/imagesearch", function(req, res) { res.end("api/latest/imagesearch/"); }); app.get("/api/imagesearch/:searchQ...
Test google api on server
Test google api on server
JavaScript
mit
diegoingaramo/img-search-al
63a5bc853e2073ee7fecb3699d69ab6e6d19e5ad
index.js
index.js
'use strict'; // Global init global.Promise = require('babel-runtime/core-js/promise').default = require('bluebird'); // Exports module.exports = require('./dist/index').default;
'use strict'; // Global init global.Promise = require('babel-runtime/core-js/promise').default = require('bluebird'); // Exports module.exports = require('./dist/index').default; // eslint-disable-line import/no-unresolved
Fix failed linting during npm test on a clean directory
Fix failed linting during npm test on a clean directory
JavaScript
mit
komapijs/komapi,komapijs/komapi
e53519bbbbf593e9ec5e9ac2ce6386f12760020f
index.js
index.js
'use strict'; var fileType = require('file-type'); var through = require('through2'); var uuid = require('uuid'); var Vinyl = require('vinyl'); module.exports.file = function (buf, name) { var ext = fileType(buf) ? fileType(buf).ext : null; return new Vinyl({ contents: buf, path: (name || uuid.v4()) + (ext ||...
'use strict'; var fileType = require('file-type'); var through = require('through2'); var uuid = require('uuid'); var Vinyl = require('vinyl'); module.exports.file = function (buf, name) { var ext = fileType(buf) ? '.' + fileType(buf).ext : null; return new Vinyl({ contents: buf, path: (name || uuid.v4()) + (...
Fix missing dot before extension.
Fix missing dot before extension.
JavaScript
mit
kevva/buffer-to-vinyl
e8decae34ae5d07fdeecfd55f60f3d010c97cc10
index.js
index.js
'use strict' module.exports = trimTrailingLines var line = '\n' // Remove final newline characters from `value`. function trimTrailingLines(value) { var string = String(value) var index = string.length while (string.charAt(--index) === line) { // Empty } return string.slice(0, index + 1) }
'use strict' module.exports = trimTrailingLines // Remove final newline characters from `value`. function trimTrailingLines(value) { return String(value).replace(/\n+$/, '') }
Refactor code to improve bundle size
Refactor code to improve bundle size
JavaScript
mit
wooorm/trim-trailing-lines
a6edc68779d82e7193360d321ebdc97307e5c59f
index.js
index.js
'use strict' const _ = require('lodash') const Promise = require('bluebird') const arr = [] module.exports = function loadAllPages (callFx, opts) { opts['page'] = opts.page || 1 return Promise .resolve(callFx(opts)) .then((result) => { arr.push(result) if (_.isFunction(result.nextPage)) { ...
'use strict' const _ = require('lodash') const Promise = require('bluebird') var arr = [] module.exports = function loadAllPages (callFx, opts) { opts['page'] = opts.page || 1 return Promise .resolve(callFx(opts)) .then((result) => { arr.push(result) if (_.isFunction(result.nextPage)) { ...
Reset array after each use
Reset array after each use
JavaScript
mit
RichardLitt/depaginate
a76d316430fd9f95d9eaee90915a25a7b2ec582a
index.js
index.js
'use strict'; var yargs = require('yargs'); var uploader = require('./lib/uploader'); var version = require('./package.json').version; var argv = yargs .usage('$0 [options] <directory>') .demand(1, 1) .option('api-key', { demand: true, describe: 'Cloudinary API key', type: 'string', nargs: 1 ...
'use strict'; var yargs = require('yargs'); var uploader = require('./lib/uploader'); var version = require('./package.json').version; var argv = yargs .usage('$0 [options] <directory>') .demand(1, 1) .option('api-key', { demand: true, describe: 'Cloudinary API key', type: 'string', nargs: 1 ...
Add option to print version
Add option to print version
JavaScript
mit
kemskems/cloudinary-cli-upload
43364f8b042a3bc6b1b03f55a65fc670ae7efd2e
index.js
index.js
var postcss = require('postcss'); module.exports = postcss.plugin('postcss-property-lookup', propertyLookup); function propertyLookup() { return function(css, result) { css.eachRule(function(rule) { rule.replaceValues(/@([a-z-]+)(\s?)/g, { fast: '@' }, function(orig, prop, space) { var replacement...
var postcss = require('postcss'); module.exports = postcss.plugin('postcss-property-lookup', propertyLookup); function propertyLookup() { return function(css, result) { css.eachRule(function(rule) { rule.replaceValues(/@([a-z-]+)(\s?)/g, { fast: '@' }, function(orig, prop, space) { var replacement...
Add rule selector to console warning
Add rule selector to console warning
JavaScript
mit
jedmao/postcss-property-lookup,simonsmith/postcss-property-lookup
40e92a2240c7d764dd430ccd64cb6eaff3b5879b
lib/define.js
lib/define.js
/*jslint browser:true, node:true*/ 'use strict'; /** * Module Dependencies */ var View = require('./view'); var store = require('./store'); /** * Creates and registers a * FruitMachine view constructor. * * @param {Object|View} * @return {View} */ module.exports = function(props) { var module = props.m...
/*jslint browser:true, node:true*/ 'use strict'; /** * Module Dependencies */ var View = require('./view'); var store = require('./store'); /** * Creates and registers a * FruitMachine view constructor. * * @param {Object|View} * @return {View} */ module.exports = function(props) { var module = props.mo...
Remove API to clear stored modules
Remove API to clear stored modules
JavaScript
mit
quarterto/fruitmachine,quarterto/fruitmachine,ftlabs/fruitmachine
9a7ce192e5e13c34c6bdf97b5ac4123071978fdb
desktop/src/Settings/SettingsContainer.js
desktop/src/Settings/SettingsContainer.js
import { connect } from 'react-redux'; import { bindActionCreators } from 'redux'; import * as actionCreators from './actionCreators'; import Settings from './Settings'; const mapStateToProps = state => ({ fullscreen: state.appProperties.fullscreen, showNotYetTasks: state.appProperties.showNotYetTasks, calendar...
import { connect } from 'react-redux'; import { bindActionCreators } from 'redux'; import * as actionCreators from './actionCreators'; import Settings from './Settings'; const mapStateToProps = state => ({ fullscreen: state.appProperties.fullscreen, showNotYetTasks: state.appProperties.showNotYetTasks, calendar...
Add firstDayOfWeek to Settings mapped props
Add firstDayOfWeek to Settings mapped props
JavaScript
mit
mkermani144/wanna,mkermani144/wanna
164bcc02f7ebf73fe99e7ecb1d6d0b158cd5965c
test/logger.js
test/logger.js
'use strict'; // logger.js tests const chai = require('chai'); const expect = chai.expect; const chalk = require('chalk'); const Logger = require('../lib/logger'); // Init logger const logger = new Logger(); // Tests describe('logger.js tests', () => { it('should check if logger._getdate() works', (done) => { /...
'use strict'; // logger.js tests const chai = require('chai'); const expect = chai.expect; const chalk = require('chalk'); const Logger = require('../lib/logger'); // Init logger const logger = new Logger(); // Tests describe('logger.js tests', () => { it('should check if logger._getdate() works', (done) => { /...
Fix issue in tests where old was not defined
:bug: Fix issue in tests where old was not defined
JavaScript
mit
Gum-Joe/bedel,Gum-Joe/bedel,Gum-Joe/bedel,Gum-Joe/bedel
f3dc47b0a0e7f606aceeceb263c3c15872cb7ab5
lib/gitlab.js
lib/gitlab.js
import _ from 'underscore' import sendMessage from './sendMessage' import sendResultBy from './sendResultBy' import sendIgnore from './sendIgnore' import debug from 'debug' export default function(req, res, next) { let result = sendResultBy(res) debug('request')(req.body) if (_.isString(req.objectKind)) ...
import _ from 'underscore' import sendMessage from './sendMessage' import sendResultBy from './sendResultBy' import sendIgnore from './sendIgnore' import debug from 'debug' export default function(req, res, next) { let result = sendResultBy(res) debug('request')(JSON.stringify(req.body, null, 2)) if (_.i...
Format son in the debug print.
Format son in the debug print.
JavaScript
mit
luxiar/syamo,luxiar/syamo,ledsun/syamo,ledsun/syamo
59a6fcf57baedffd5d88042f4f3b0caa7b54ee82
static/scripts/views/event/creation.js
static/scripts/views/event/creation.js
define(['backbone', 'marionette'], function(Backbone, Marionette) { return Backbone.View.extend({ template: '#event-creation', events: { 'click button.create-event': 'create_event' }, initialize: function() {}, render: function() { var rendered_temp...
define(['backbone', 'marionette'], function(Backbone, Marionette) { return Backbone.View.extend({ template: '#event-creation', events: { 'click button.create-event': 'create_event' }, initialize: function() {}, render: function() { var rendered_temp...
Set date when creating event, not when it's require'd
Set date when creating event, not when it's require'd
JavaScript
mit
amackera/stratus
7a5a493bb83d3f6c75ec870e29f79e94a09dd479
src/js/SimpleTourItem.js
src/js/SimpleTourItem.js
import React from 'react'; class SimpleTourItem extends React.Component { render() { const containerStyle = { background: 'white', padding: '20px', color: 'black', maxWidth: '300px' }; const buttonStyle = { cursor: 'pointer', textDecoration: 'none', color: '#34...
import React from 'react'; class SimpleTourItem extends React.Component { render() { const containerStyle = { background: 'white', padding: '20px', color: 'black', maxWidth: '300px' }; const buttonStyle = { cursor: 'pointer', textDecoration: 'none', color: '#34...
Change word from Done to Next
Change word from Done to Next
JavaScript
mit
khankuan/react-tourist,khankuan/react-tourist
d1ca08ada6e949b9fb0c052b8f9a3056da8065a0
source/loosely-matches.js
source/loosely-matches.js
"use strict"; const flow = require("lodash.flow"); const deburr = require("lodash.deburr"); const toLower = require("lodash.tolower"); const looseMatchTransform = flow(deburr, toLower); /** * Function that returns true when `needle` is found in `haystack`. * The main advantages of this function are that it rem...
"use strict"; const flow = require("lodash.flow"); const deburr = require("lodash.deburr"); const toLower = require("lodash.tolower"); const looseMatchTransform = flow(deburr, toLower); /** * Function that returns true when `needle` is found in `haystack`. * The main advantages of this function are that it rem...
Add terminal . at end of sentence in looselyMatches documentation string
Add terminal . at end of sentence in looselyMatches documentation string
JavaScript
mit
tentwentyfour/helpbox
52b58f48625f7a54f4e342e263b865747137dcfa
src/Middleware/MiddlewareStack.js
src/Middleware/MiddlewareStack.js
export default class MiddlewareStack { constructor(handler, stack = []) { this._handler = handler; this._stack = stack.map(element => (typeof element === 'function' ? new element() : element)); this._regenerateMiddlewareProcess(); } push(middleware) { this._stack.push(middleware); this._regen...
export default class MiddlewareStack { constructor(handler, stack = []) { this._handler = handler; this._stack = stack.map(element => (typeof element === 'function' ? new element() : element)); this._regenerateMiddlewareProcess(); } push(middleware) { this._stack.push(middleware); this._regen...
Make the middleware regen after pops.
Make the middleware regen after pops.
JavaScript
mit
hkwu/ghastly
20542df46f1a5274c2292c9c05cf8024ab4679ad
test/react/router.spec.js
test/react/router.spec.js
var makeSignatureFromRoutes = require('../../src/react/router').makeSignatureFromRoutes describe("react: makeSignatureFromRoutes", function() { it("should correctly join paths", function() { var routes = [ {path: "/"}, {path: "/something"}, ] expect(makeSignatureFromRoutes(routes)).toBe("/someth...
var makeSignatureFromRoutes = require('../../src/react/router').makeSignatureFromRoutes var pushLocation = {action: 'PUSH'}, replaceLocation = {action: 'REPLACE'} describe("react: makeSignatureFromRoutes", function() { it("should correctly join paths", function() { var routes = [ {path: "/"}, {path: "/som...
Add test for REPLACE route
Add test for REPLACE route
JavaScript
mit
opbeat/opbeat-react,opbeat/opbeat-react,opbeat/opbeat-react
76d385139e36b3b685d73ba209e2f52ad89ebd01
client/apps/user_tool/actions/application.js
client/apps/user_tool/actions/application.js
import wrapper from 'atomic-fuel/libs/constants/wrapper'; import Network from 'atomic-fuel/libs/constants/network'; // Local actions const actions = []; // Actions that make an api request const requests = ['SEARCH_FOR_ACCOUNT_USERS', 'GET_ACCOUNT_USER', 'UPDATE_ACCOUNT_USER']; export const Constants = wrapper(actio...
import wrapper from 'atomic-fuel/libs/constants/wrapper'; import Network from 'atomic-fuel/libs/constants/network'; // Increasing timeout to accomodate slow environments. Default is 20_000. Network.TIMEOUT = 60_000; // Local actions const actions = []; // Actions that make an api request const requests = ['SEARCH_FO...
Increase client-side network timeout from 20 seconds to 60
fix: Increase client-side network timeout from 20 seconds to 60 We're having problems in the staging environment where requests are taking longer than 20 seconds and are timing out so the user can't perform certain actions. Increasing the timeout to 60 seconds won't improve the slow performance obviously, but it will ...
JavaScript
mit
atomicjolt/adhesion,atomicjolt/adhesion,atomicjolt/adhesion,atomicjolt/adhesion
fcda3bb2aa828f7f34a0fa667b43089b10786bd5
public/app/service-api.js
public/app/service-api.js
var svcMod = angular.module( "linksWeb.service-api", [] ); svcMod.factory( 'API', [ "$http", "$window", function ( $http, $window ) { var apiRequest = function ( method, path, requestData, callback ) { var headers = { "Content-Type": "application/json", "Authorization": "Token " ...
var svcMod = angular.module( "linksWeb.service-api", [] ); svcMod.factory( 'API', [ "$http", "$window", function ( $http, $window ) { var apiRequest = function ( method, path, requestData, callback ) { var headers = { "Content-Type": "application/json" }; if ( $window.sessio...
Set the Authorization header if a token exists
Set the Authorization header if a token exists
JavaScript
mit
projectweekend/Links-Web,projectweekend/Links-Web
4a31e8979533dfccd99157832def834f134f340a
test/fixtures/index.js
test/fixtures/index.js
var sample_xform = require('./sample_xform'); module.exports = function() { return [ { request: { method: "GET", url: "http://www.example.org/xform00", params: {}, }, response: { code: "200", ...
module.exports = function() { return []; };
Revert "Add fixture for getting an xform from an external server"
Revert "Add fixture for getting an xform from an external server" This reverts commit 8ef11ed11f09b9f4ce7d53234fdb6100c7fe8451.
JavaScript
bsd-3-clause
praekelt/go-jsbox-xform,praekelt/go-jsbox-xform
28929cc0260ea14c2de5ec19874c6dbba00f9100
matchMedia.js
matchMedia.js
/*! matchMedia() polyfill - Test a CSS media type/query in JS. Authors & copyright (c) 2012: Scott Jehl, Paul Irish, Nicholas Zakas. Dual MIT/BSD license */ window.matchMedia = window.matchMedia || (function( doc, undefined ) { "use strict"; var bool, docElem = doc.documentElement, refNode = docElem....
/*! matchMedia() polyfill - Test a CSS media type/query in JS. Authors & copyright (c) 2012: Scott Jehl, Paul Irish, Nicholas Zakas. Dual MIT/BSD license */ window.matchMedia || (window.matchMedia = function() { "use strict"; var styleMedia = (window.styleMedia || window.media); // For those that doen't...
Complete rewrite in an effort to gain performance
Complete rewrite in an effort to gain performance
JavaScript
mit
therealedsheenan/matchMedia.js,amitabhaghosh197/matchMedia.js,AndBicScadMedia/matchMedia.js,ababic/matchMedia.js,therealedsheenan/matchMedia.js,paulirish/matchMedia.js,zxfjessica/match-media-polyfill,CondeNast/matchMedia.js,CondeNast/matchMedia.js,ababic/matchMedia.js,dirajkumar/matchMedia.js,zxfjessica/match-media-pol...
6e648cc1f0abfd8df74f11a48682c8c177ad309d
pa11y.js
pa11y.js
// This is our options configuration for Pa11y // https://github.com/pa11y/pa11y#configuration const options = { timeout: 60000, hideElements: '.skip-to, .is-visuallyhidden' }; module.exports = options;
// This is our options configuration for Pa11y // https://github.com/pa11y/pa11y#configuration const options = { timeout: 60000, hideElements: '.skip-to, .is-visuallyhidden, .visuallyhidden' }; module.exports = options;
Add .visuallyhidden class to Pa11y test excludes
Add .visuallyhidden class to Pa11y test excludes
JavaScript
mit
AusDTO/gov-au-ui-kit,AusDTO/gov-au-ui-kit,AusDTO/gov-au-ui-kit
ad11af7002bfb7e6c0737bae5f48270010e1a42e
modules/wikipedia/index.js
modules/wikipedia/index.js
const wiki = require('wikijs').default; module.exports.commands = ['wiki', 'wikipedia']; function prettyPage(page) { return page.summary() // Get the first "sentence" (hopefully) .then(str => str.substr(0, str.indexOf('.') + 1)) // Truncate with an ellipsis if length exceeds 250 chars .then(str => (...
const wiki = require('wikijs').default; module.exports.commands = ['wiki', 'wikipedia']; const urlRegex = /^(?:https?:\/\/)?(?:en\.)?wikipedia\.org\/wiki\/(.+)/; const errorMessage = term => `No Wikipedia page found for "${term}"`; function shortSummary(page, withUrl) { return page.summary() // Get the first ...
Add URL matching to Wikipedia module
Add URL matching to Wikipedia module
JavaScript
mit
LinuxMercedes/EuIrcBot,gmackie/EuIrcBot,euank/EuIrcBot,euank/EuIrcBot,gmackie/EuIrcBot,LinuxMercedes/EuIrcBot
334c168af32f349fa8dbd1ee319611647fa44004
components/org.wso2.carbon.siddhi.editor.core/src/main/resources/web/commons/js/menu-bar/deploy-menu.js
components/org.wso2.carbon.siddhi.editor.core/src/main/resources/web/commons/js/menu-bar/deploy-menu.js
/** * Copyright (c) 2019, WSO2 Inc. (http://www.wso2.org) All Rights Reserved. * * WSO2 Inc. licenses this file to you 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.o...
/** * Copyright (c) 2019, WSO2 Inc. (http://www.wso2.org) All Rights Reserved. * * WSO2 Inc. licenses this file to you 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.o...
Change shortcut key for deploy to server
Change shortcut key for deploy to server
JavaScript
apache-2.0
tishan89/carbon-analytics,minudika/carbon-analytics,Niveathika92/carbon-analytics,erangatl/carbon-analytics,Niveathika92/carbon-analytics,minudika/carbon-analytics,minudika/carbon-analytics,tishan89/carbon-analytics,tishan89/carbon-analytics,wso2/carbon-analytics,wso2/carbon-analytics,tishan89/carbon-analytics,wso2/car...
da490e3f5353be00b9deb384813b48952a8db3cc
erpnext/stock/doctype/serial_no/serial_no.js
erpnext/stock/doctype/serial_no/serial_no.js
// Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors // License: GNU General Public License v3. See license.txt cur_frm.add_fetch("customer", "customer_name", "customer_name") cur_frm.add_fetch("supplier", "supplier_name", "supplier_name") cur_frm.add_fetch("item_code", "item_name", "item_name") c...
// Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors // License: GNU General Public License v3. See license.txt cur_frm.add_fetch("customer", "customer_name", "customer_name") cur_frm.add_fetch("supplier", "supplier_name", "supplier_name") cur_frm.add_fetch("item_code", "item_name", "item_name") c...
Set status button in serial no
Set status button in serial no
JavaScript
agpl-3.0
Tejal011089/fbd_erpnext,indictranstech/erpnext,suyashphadtare/sajil-final-erp,rohitwaghchaure/erpnext-receipher,mbauskar/Das_Erpnext,rohitwaghchaure/New_Theme_Erp,gangadharkadam/office_erp,Tejal011089/huntercamp_erpnext,suyashphadtare/gd-erp,mbauskar/helpdesk-erpnext,gangadharkadam/v5_erp,rohitwaghchaure/New_Theme_Erp,...
44f3adfdbf85467272d71cf10c9ecd4fe75b57b7
src/KeyboardObserver.js
src/KeyboardObserver.js
import {DeviceEventEmitter} from 'react-native'; class KeyboardObserver { constructor() { this.keyboardHeight = 0; this.animationWillEndAt = 0; this.listeners = {}; this.listenerId = 0; DeviceEventEmitter.addListener('keyboardWillShow', this.handleKeyboardWillShow.bind(this)); DeviceEventEmi...
import {Keyboard} from 'react-native'; class KeyboardObserver { constructor() { this.keyboardHeight = 0; this.animationWillEndAt = 0; this.listeners = {}; this.listenerId = 0; Keyboard.addListener('keyboardWillShow', this.handleKeyboardWillShow.bind(this)); Keyboard.addListener('keyboardWill...
Fix React Native Keyboard warnings
Fix React Native Keyboard warnings
JavaScript
mit
azendoo/react-native-keyboard-responsive-view
166231a4e9c666d017f6823b46f238fd50537e5a
lib/node_modules/@stdlib/math/base/special/gammaincinv/lib/index.js
lib/node_modules/@stdlib/math/base/special/gammaincinv/lib/index.js
'use strict'; /** * Computes the inverse of the lower incomplete gamma function. * * @module @stdlib/math/base/special/gammaincinv * * @example * var gammaincinv = require( '@stdlib/math/base/special/gammaincinv' ); * * var val = gammaincinv( 0.5, 2.0 ); * // returns ~1.678 * * val = gammaincinv( 0.1, 10.0 ); * // ret...
'use strict'; /** * Compute the inverse of the lower incomplete gamma function. * * @module @stdlib/math/base/special/gammaincinv * * @example * var gammaincinv = require( '@stdlib/math/base/special/gammaincinv' ); * * var val = gammaincinv( 0.5, 2.0 ); * // returns ~1.678 * * val = gammaincinv( 0.1, 10.0 ); * // retu...
Update description to imperative mood
Update description to imperative mood
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
c8639e7b8e380cbe1f68c7597de438ccdebdda77
server/instaFeed.es6.js
server/instaFeed.es6.js
Meteor.methods({ fetchInstaApi: function(){ var instaDebounce = _.debounce(Meteor.bindEnvironment(function(){ var ig = Meteor.npmRequire('instagram-node').instagram(); ig.use({ access_token: Meteor.settings.instagram.access_token }); ig.user_self_media_recent(Meteor.bindEnvironment(function(err...
Meteor.methods({ fetchInstaApi: function(){ /*var instaDebounce = _.debounce(Meteor.bindEnvironment(function(){ var ig = Meteor.npmRequire('instagram-node').instagram(); ig.use({ access_token: Meteor.settings.instagram.access_token }); ig.user_self_media_recent(Meteor.bindEnvironment(function(e...
Revert "Scaling crash testing twitFeed"
Revert "Scaling crash testing twitFeed" This reverts commit 3216af3058e496f249781cf97e94359e01d7fa82.
JavaScript
mit
Rhjulskov/webonaut,Rhjulskov/webonaut,Rhjulskov/webonaut
8c4b151b36ac5ff4d83206e19675c45932248809
src/BBM.fn.toBBM.js
src/BBM.fn.toBBM.js
(function (){ "use strict"; var BBM = require("./BBM.js"); var ENUM = BBM.ENUM; var REGSTR = [ "\"{3,}" , "--" , "\\*{2}" , "\\^{2}" , ",," , "__" , "''" , "\\?<" , "!<" , "#<" , "#\\[" , "-\\[" , "\\]" ]; var REGEX = new RegExp(REGSTR.join("|"), "g"); //Serializes this subtree into BBM. function toBBM() { } ...
(function (){ "use strict"; var BBM = require("./BBM.js"); var ENUM = BBM.ENUM; var REGSTR = [ "\\\\[\\s\\S]" , "\"{3,}" , "--" , "\\*{2}" , "\\^{2}" , ",," , "__" , "''" , "\\?<" , "!<" , "#<" , "#\\[" , "-\\[" , "\\]" ]; var REGEX = new RegExp(REGSTR.join("|"), "g"); //Serializes this subtree into BBM. functio...
Add backslash tokens to the escape list.
Add backslash tokens to the escape list.
JavaScript
mit
Preole/bbm,Preole/bbm
a8bde2cb21c53fbdcf6a4aae9124a310f9e0111f
lib/client/error_reporters/window_error.js
lib/client/error_reporters/window_error.js
var prevWindowOnError = window.onerror; window.onerror = function(message, url, line, stack) { var now = Date.now(); stack = stack || 'window@'+url+':'+line+':0'; Kadira.sendErrors([{ appId : Kadira.options.appId, name : message, source : 'client', startTime : now, type : 'window.onerror', ...
var prevWindowOnError = window.onerror; window.onerror = function(message, url, line, stack) { var now = Date.now(); stack = stack || 'window@'+url+':'+line+':0'; Kadira.sendErrors([{ appId : Kadira.options.appId, name : 'Error: ' + message, source : 'client', startTime : now, type : 'window.o...
Use 'ErrorName: message' format for name
Use 'ErrorName: message' format for name
JavaScript
mit
chatr/kadira,meteorhacks/kadira
7035a1f61994961884bc8c584b793b2f657ad242
web/frontend/pages/rich_text_editor.js
web/frontend/pages/rich_text_editor.js
import tinymce from 'tinymce/tinymce'; window.tinymce = tinymce; import 'tinymce/themes/silver'; import 'tinymce/plugins/link'; import 'tinymce/plugins/lists'; import 'tinymce/plugins/image'; import 'tinymce/plugins/table'; import 'tinymce/plugins/code'; import 'tinymce/plugins/paste'; import 'tinymce/plugins/media'; i...
import tinymce from 'tinymce/tinymce'; window.tinymce = tinymce; import 'tinymce/themes/silver'; import 'tinymce/icons/default'; import 'tinymce/plugins/link'; import 'tinymce/plugins/lists'; import 'tinymce/plugins/image'; import 'tinymce/plugins/table'; import 'tinymce/plugins/code'; import 'tinymce/plugins/paste'; i...
Include TinyMCE icons after update
Include TinyMCE icons after update
JavaScript
agpl-3.0
harvard-lil/h2o,harvard-lil/h2o,harvard-lil/h2o,harvard-lil/h2o
a06d8d4a10b0cfb5905a0dc183bf25b26dd51e69
assets/js/googlesitekit/modules/datastore/__fixtures__/index.js
assets/js/googlesitekit/modules/datastore/__fixtures__/index.js
/** * Modules datastore fixtures. * * Site Kit by Google, Copyright 2020 Google LLC * * 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 * * https://www.apache.org/licenses/LICENSE-2....
/** * Modules datastore fixtures. * * Site Kit by Google, Copyright 2020 Google LLC * * 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 * * https://www.apache.org/licenses/LICENSE-2....
Fix new docs ESLint rule violation.
Fix new docs ESLint rule violation.
JavaScript
apache-2.0
google/site-kit-wp,google/site-kit-wp,google/site-kit-wp,google/site-kit-wp
3825954db3a1f20411329f6efde9fc7b09c62f22
ifrau-client.js
ifrau-client.js
module.exports = import('ifrau').then(function(ifrau) { return ifrau.Client; });
module.exports = import('ifrau').then(function(ifrau) { return ifrau.SlimClient; });
Return slim client instead of full client
Return slim client instead of full client Co-authored-by: Owen Smith <9069d0e8b554bca3df1592c83c498c5cd0661c2e@omsmith.ca>
JavaScript
apache-2.0
Brightspace/frau-jwt
61ef41e923fe2d05f36f47ed26139fcf6e4685ae
app/components/language-picker/component.js
app/components/language-picker/component.js
import Ember from 'ember'; import countries from './countries'; export default Ember.Component.extend({ i18n: Ember.inject.service(), countries: countries, languages: Ember.computed('countries', function() { var langs = []; this.get('countries').forEach((country) => { country.language...
import Ember from 'ember'; import countries from './countries'; export default Ember.Component.extend({ i18n: Ember.inject.service(), countries: countries, languages: Ember.computed('countries', function() { var langs = []; this.get('countries').forEach((country) => { country.language...
Sort flags by country code
Sort flags by country code
JavaScript
apache-2.0
CenterForOpenScience/isp,CenterForOpenScience/isp,samanehsan/isp,samanehsan/isp,CenterForOpenScience/isp,samanehsan/isp
4f0b898c968cca08ac87638d4250c6140f354a7f
src/components/HomepagePetitions/index.js
src/components/HomepagePetitions/index.js
import React from 'react'; import TeaserGrid from 'components/TeaserGrid'; import Container from 'components/Container'; import BlockContainer from 'components/BlockContainer'; import Section from 'components/Section'; import Heading2 from 'components/Heading2'; import styles from './homepage-petitions.scss'; import Li...
import React from 'react'; import TeaserGrid from 'components/TeaserGrid'; import Container from 'components/Container'; import BlockContainer from 'components/BlockContainer'; import Section from 'components/Section'; import Heading2 from 'components/Heading2'; import styles from './homepage-petitions.scss'; import Li...
Use latest petitions on HP instead...
Use latest petitions on HP instead...
JavaScript
apache-2.0
iris-dni/iris-frontend,iris-dni/iris-frontend,iris-dni/iris-frontend
8ea1ff2f989480a77181a384d64cfdcd68a88c18
blueprints/ember-flexberry-designer/index.js
blueprints/ember-flexberry-designer/index.js
/* globals module */ module.exports = { afterInstall: function() { var _this = this; return _this.addAddonsToProject({ packages: [ { name: 'ember-flexberry', target: '0.12.3' } ] }).then(function () { return _this.addPackagesToProject([ { name: 'npm:jointjs', target: '^2.1....
/* globals module */ module.exports = { afterInstall: function() { var _this = this; return _this.addAddonsToProject({ packages: [ { name: 'ember-cli-jstree', target: '1.0.9' }, { name: 'ember-flexberry', target: '0.12.3' }, { name: 'ember-promise-helpers', target: '1.0.3' } ...
Fix default blueprint add missing dependencies
Fix default blueprint add missing dependencies
JavaScript
mit
Flexberry/ember-flexberry-designer,Flexberry/ember-flexberry-designer,Flexberry/ember-flexberry-designer
3322f2a9c5627719c552d737543a3f7f88888122
webpack.config.dist.js
webpack.config.dist.js
var config = require('./webpack.config.js'); var webpack = require('webpack'); config.devtool = 'source-map'; config.output.publicPath = './'; config.plugins.push( new webpack.DefinePlugin({ 'process.env': { 'NODE_ENV': JSON.stringify('production') } }) ); config.plugins.push( new webpack.optimi...
var config = require('./webpack.config.js'); var webpack = require('webpack'); var pkg = require('./package.json'); var banner = '@license minigrid '; banner = banner + pkg.version; banner = banner + ' – minimal cascading grid layout http://alves.im/minigrid'; config.devtool = 'source-map'; config.output.publicPath ...
Add banner comment to dis version
Add banner comment to dis version
JavaScript
mit
messinmotion/minigrid,henriquea/minigrid,henriquea/minigrid
9dd210893d6e961f89836281df4a16c056917d8f
src/TileMap.js
src/TileMap.js
function TileMap(w, h) { this.width = w; this.height = h; this.reset(); } TileMap.prototype.reset = function() { this.map = []; for(var y = 0; y < this.height; y++) { this.map[y] = []; for(var x = 0; x < this.width; x++) { this.map[y][x] = new Tile(); } } } function Tile() { } TileMap...
function TileMap(w, h) { this.width = w; this.height = h; this.reset(); } TileMap.prototype.reset = function() { this.map = []; for(var y = 0; y < this.height; y++) { this.map[y] = []; for(var x = 0; x < this.width; x++) { this.map[y][x] = new Tile(x, y); } } } function Tile(x, y) { t...
Change Tile to store its own coordinates
Change Tile to store its own coordinates
JavaScript
mit
yoo2001818/TableFlip
cd072a2e2de2213eb9450445c5a48ca5c6452335
lib/generators/half_pipe/templates/tasks/options/sass.js
lib/generators/half_pipe/templates/tasks/options/sass.js
module.exports = { options: { require: ['sass-css-importer'], loadPath: ['<%%= bowerOpts.directory || "bower_components" %>'], bundleExec: true, }, debug: { src: '<%%= dirs.tmp %>/prepare/assets/styles/main.scss', dest: '<%%= dirs.tmp %>/public/assets/styles/main.css', options: { sty...
module.exports = { options: { require: ['sass-css-importer'], loadPath: ['<%%= bowerOpts.directory || "bower_components" %>'], bundleExec: true }, debug: { src: '<%%= dirs.tmp %>/prepare/assets/styles/main.scss', dest: '<%%= dirs.tmp %>/public/assets/styles/main.css', options: { styl...
Add sourcemaps option to Sass task
Add sourcemaps option to Sass task
JavaScript
mit
half-pipe/half-pipe,half-pipe/half-pipe
5068d340bf68c03d79d3c6b9325f5557d4daa3c9
lib/libra2/app/assets/javascripts/file_upload_options.js
lib/libra2/app/assets/javascripts/file_upload_options.js
(function() { "use strict"; function initPage() { var fileTypes = [ "csv", "gif", "jpeg", "jpg", "mp3", "mp4", "pdf", "png", "tif", "tiff", "txt", "xml" ]; var list = fileTypes.join(", ").toUpperCase(); var filter = fileTypes.join("|"); // Match any file that doesn't c...
(function() { "use strict"; function initPage() { var fileTypes = [ "csv", "gif", "htm", "html", "jpeg", "jpg", "mp3", "mp4", "pdf", "png", "tif", "tiff", "txt", "xml" ]; var list = fileTypes.join(", ").toUpperCase(); var filter = fileTypes.join("|"); // Match an...
Add html and htm to list of acceptable files
LIBRA-235: Add html and htm to list of acceptable files
JavaScript
apache-2.0
uvalib/Libra2,uvalib/Libra2,uvalib/Libra2,uvalib/Libra2,uvalib/Libra2
253529d42c1ef9b7aed7b2754c77bc8a246d892e
repeat.js
repeat.js
/*! http://mths.be/repeat v0.1.0 by @mathias */ if (!String.prototype.repeat) { (function() { 'use strict'; // needed to support `apply`/`call` with `undefined`/`null` var repeat = function(count) { if (this == null) { throw TypeError(); } var string = String(this); // `ToInteger` var n = count ...
/*! http://mths.be/repeat v0.1.0 by @mathias */ if (!String.prototype.repeat) { (function() { 'use strict'; // needed to support `apply`/`call` with `undefined`/`null` var repeat = function(count) { if (this == null) { throw TypeError(); } var string = String(this); // `ToInteger` var n = count ...
Remove unnecessary check for `n == 0`
Remove unnecessary check for `n == 0` The `while` loop below handles this case anyway. The only ‘overhead’ the check avoided was a single `n--` and a `ToBoolean(0)` — so this was definitely a micro-optimization. Closes #3.
JavaScript
mit
mathiasbynens/String.prototype.repeat
c7dd9a0b4aacce1e04e9cbe4400b085cd0eb9119
src/build.js
src/build.js
var requirejs = require('requirejs'); var applicationConfig = { baseUrl: './public/js', name: 'app', out: './public/app.js', mainConfigFile: './public/js/app.js', paths: { 'socket.io': 'empty:', 'requireLib': 'require' }, include: [ 'requireLib' ] }; var mainConfig...
var requirejs = require('requirejs'); var applicationConfig = { baseUrl: './public/js', name: 'app', out: './public/app.js', mainConfigFile: './public/js/app.js', paths: { 'socket.io': 'empty:', 'requireLib': 'require' }, include: [ 'requireLib' ] }; var mainConfig...
Compress CSS into a single file
Compress CSS into a single file
JavaScript
apache-2.0
pinittome/pinitto.me,pinittome/pinitto.me,pinittome/pinitto.me
a9ed364ba26e9952a05934ac5369dce8db23c4da
public/nav_control/nav_control.js
public/nav_control/nav_control.js
import { constant, includes } from 'lodash'; import { element } from 'angular'; import uiModules from 'ui/modules'; import registry from 'ui/registry/chrome_nav_controls'; import '../components/notification_center'; import template from './nav_control.html'; import 'ui/angular-bootstrap'; registry.register(constant({ ...
import { constant, includes } from 'lodash'; import { element } from 'angular'; import uiModules from 'ui/modules'; import registry from 'ui/registry/chrome_nav_controls'; import '../components/notification_center'; import template from './nav_control.html'; import 'ui/angular-bootstrap'; registry.register(constant({ ...
Fix notification-center not to close when button clicked.
Fix notification-center not to close when button clicked.
JavaScript
mit
sw-jung/kibana_notification_center,sw-jung/kibana_notification_center
225df4bb8f5e6561161dab095c49a8b78286dbb2
src/components/Heading.js
src/components/Heading.js
/* * A reusable component to display a styled heading. */ import PropTypes from 'prop-types'; import React, {Component} from 'react'; import {StyleSheet, css} from 'aphrodite/no-important'; export default class Heading extends Component { static propTypes = { level: PropTypes.oneOf([1, 2]).isRequired, ...
/* * A reusable component to display a styled heading. */ import PropTypes from 'prop-types'; import React, {Component} from 'react'; import {StyleSheet, css} from 'aphrodite/no-important'; export default class Heading extends Component { static propTypes = { level: PropTypes.oneOf([1, 2, 3]).isRequire...
Add support for level-3 headings
Add support for level-3 headings
JavaScript
mit
wchargin/wchargin.github.io,wchargin/wchargin.github.io
641b6937f8b8b54bd654c4ca6ca5345be5ff3f0e
router.js
router.js
var httpProxy = require('http-proxy'); var http = require('http'); var proxy = httpProxy.createProxy(); var routes = { // Router 'hook.labeli.org' : 'http://localhost:9000', // Api 'api.labeli.org' : 'http://localhost:9010', 'hook.api.labeli.org' : 'http://localhost:9011', ...
var httpProxy = require('http-proxy'); var http = require('http'); var proxy = httpProxy.createProxyServer({}); var routes = { // Router 'hook.labeli.org' : 'http://localhost:9000', // Api 'api.labeli.org' : 'http://localhost:9010', 'hook.api.labeli.org' : 'http://localhost:9011', // Website ...
Add method getRouteFor() to create default route
Add method getRouteFor() to create default route
JavaScript
mit
asso-labeli/labeli-router,asso-labeli/labeli-router
3c54b4d5f8351898be26699ad9cece43318a32e3
frontend/config/dev.env.js
frontend/config/dev.env.js
var merge = require('webpack-merge') var prodEnv = require('./prod.env') module.exports = merge(prodEnv, { NODE_ENV: '"development"', API_HOST: '"http://localhost:3000"' })
var merge = require('webpack-merge') var prodEnv = require('./prod.env') module.exports = merge(prodEnv, { NODE_ENV: '"development"', API_HOST: '"http://localhost:5100"' })
Fix local api server path because of Foreman
Fix local api server path because of Foreman
JavaScript
mit
riseshia/Bonghwa,riseshia/Bonghwa,riseshia/Bonghwa,riseshia/Bonghwa
c956e63c62f17c3c671ea991f978e42218a94691
app/assets/javascripts/application.js
app/assets/javascripts/application.js
// This is a manifest file that'll be compiled into application.js, which will include all the files // listed below. // // Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts, // or vendor/assets/javascripts of plugins, if any, can be referenced here using a relative pat...
// This is a manifest file that'll be compiled into application.js, which will include all the files // listed below. // // Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts, // or vendor/assets/javascripts of plugins, if any, can be referenced here using a relative pat...
Add explicit include (early in order) for the leaflet.markercluster js file
Add explicit include (early in order) for the leaflet.markercluster js file
JavaScript
mit
codeforgso/cityvoice,ajb/cityvoice,daguar/cityvoice,ajb/cityvoice,codeforgso/cityvoice,daguar/cityvoice,codeforgso/cityvoice,codeforamerica/cityvoice,codeforamerica/cityvoice,ajb/cityvoice,codeforamerica/cityvoice,daguar/cityvoice,daguar/cityvoice,codeforamerica/cityvoice,ajb/cityvoice,codeforgso/cityvoice
d703dad4967b92c85a470b5d445a7a1fd5765352
app/assets/javascripts/osem-switch.js
app/assets/javascripts/osem-switch.js
$(function () { $("[class='switch-checkbox']").bootstrapSwitch(); $('input[class="switch-checkbox"]').on('switchChange.bootstrapSwitch', function(event, state) { var url = $(this).attr('url') + state; var method = $(this).attr('method'); $.ajax({ url: url, type: method, dataType: 'sc...
function checkboxSwitch(selector){ $(selector).bootstrapSwitch( ); $(selector).on('switchChange.bootstrapSwitch', function(event, state) { var url = $(this).attr('url') + state; var method = $(this).attr('method'); $.ajax({ url: url, type: method, dataType: 'script' }); }); ...
Add a function for initing boostrapSwitch outside of $()
Add a function for initing boostrapSwitch outside of $()
JavaScript
mit
bear454/osem,hennevogel/osem,AndrewKvalheim/osem,differentreality/osem,differentreality/osem,rishabhptr/osem,openSUSE/osem,rishabhptr/osem,bear454/osem,SeaGL/osem,openSUSE/osem,rishabhptr/osem,differentreality/osem,hennevogel/osem,hennevogel/osem,SeaGL/osem,hennevogel/osem,openSUSE/osem,bear454/osem,rishabhptr/osem,And...
23a7aefe2d78f46523bd71a25c3ceb90db254f5e
src/index.js
src/index.js
const fs = require('fs'); const path = require('path'); const { infer } = require('bayesjs'); const { json, send } = require('micro'); const htmlContent = fs .readFileSync(path.join(__dirname, 'index.html')) .toString(); module.exports = async (req, res) => { if (req.url !== '/') { return send(res, 404); ...
const fs = require('fs'); const path = require('path'); const { infer } = require('bayesjs'); const { json, send } = require('micro'); const htmlContent = fs .readFileSync(path.join(__dirname, 'index.html')) .toString(); module.exports = async (req, res) => { if (req.url !== '/') { return send(res, 404); ...
Change 'not found' to 'method not allowed'
Change 'not found' to 'method not allowed'
JavaScript
mit
fhelwanger/bayesjs-ws,fhelwanger/bayesjs-ws
73f420d634399f26a329fd66f1afc6221e1aeb8b
src/index.js
src/index.js
const Discord = require('discord.js'); const config = require('./config.json'); const manager = new Discord.ShardingManager('./bot.js'); //Spawn with a relevant number of shards automatically manager.spawn();
const Discord = require('discord.js'); const config = require('./config.json'); const API = require("./api.json"); const manager = new Discord.ShardingManager('./bot.js', { token: API.discord }); //Spawn with a relevant number of shards automatically manager.spawn();
Add token in sharding manager
Add token in sharding manager
JavaScript
mit
moustacheminer/MSS-Discord,moustacheminer/MSS-Discord,moustacheminer/MSS-Discord
5955b691f3e44cbf8224e070c1c67fdd070f5454
src/content.js
src/content.js
/* Listen for messages and get modResource meta tag*/ chrome.runtime.onMessage.addListener(function(msg, sender, sendResponse) { if (msg.command && (msg.command == "getResource")) { function getMetaContentByName(name,content){ var content = (content==null)?'content':content; var meta = document.q...
/* Listen for messages and get modResource meta tag*/ chrome.runtime.onMessage.addListener(function(msg, sender, sendResponse) { if (msg.command && (msg.command == "getResource")) { function getMetaContentByName(name,content){ var content = (content==null)?'content':content; var meta = document.q...
Change meta name for valid html output
Change meta name for valid html output
JavaScript
mit
bartholomej/modx-manager-switch,bartholomej/modx-manager-switch
490f0af6992eab28938273d91341073138082b35
test/unit/tadaboard-node-sdk.js
test/unit/tadaboard-node-sdk.js
import TB from '../../src/tadaboard-node-sdk'; describe('TB', () => { });
import TB from '../../src/tadaboard-node-sdk'; describe('TB', () => { describe('response', () => { it('is a function', () => { expect(TB.response).to.be.a('function'); }); }); });
Add simple test for TB.response
Add simple test for TB.response
JavaScript
mit
tadaboard/node-sdk,tadaboard/node-sdk
c716b8f23392e2d26c7675f193be4c54f72205cd
app/renderer/js/notification/index.js
app/renderer/js/notification/index.js
'use strict'; const { remote: { app } } = require('electron'); const DefaultNotification = require('./default-notification'); const { appId, loadBots } = require('./helpers'); // From https://github.com/felixrieseberg/electron-windows-notifications#appusermodelid // On windows 8 we have to explicitly set the appUs...
'use strict'; const { remote: { app } } = require('electron'); const DefaultNotification = require('./default-notification'); const { appId, loadBots } = require('./helpers'); // From https://github.com/felixrieseberg/electron-windows-notifications#appusermodelid // On windows 8 we have to explicitly set the appUs...
Refactor code for bot mention in reply.
notification: Refactor code for bot mention in reply.
JavaScript
apache-2.0
zulip/zulip-desktop,zulip/zulip-desktop,zulip/zulip-desktop,zulip/zulip-electron,zulip/zulip-electron,zulip/zulip-desktop,zulip/zulip-electron
39525514e4849eb514bb563e51f5cb7e5900f0ea
blueprints/flexberry-edit-form/snippets/getCellComponent-function.js
blueprints/flexberry-edit-form/snippets/getCellComponent-function.js
(attr, bindingPath, model) { let cellComponent = this._super(...arguments); if (attr.kind === 'belongsTo') { switch (<% '`${model.modelName}+${bindingPath}`' %>) { <%= bodySwitchBindingPath %> } } return cellComponent; }
(attr, bindingPath, model) { let cellComponent = this._super(...arguments); if (attr.kind === 'belongsTo') { switch (<%= '`${model.modelName}+${bindingPath}`' %>) { <%= bodySwitchBindingPath %> } } return cellComponent; }
Fix flexberry-edit-form blueprint getCellComponent template
Fix flexberry-edit-form blueprint getCellComponent template
JavaScript
mit
Flexberry/ember-flexberry,Flexberry/ember-flexberry,Flexberry/ember-flexberry,Flexberry/ember-flexberry
2237d762db94f82264d5784412720fcfe69226a0
Assets/js/init-dropzone.js
Assets/js/init-dropzone.js
$( document ).ready(function() { Dropzone.autoDiscover = false; var myDropzone = new Dropzone(".dropzone", { url: '/api/file', autoProcessQueue: true, maxFilesize: maxFilesize, acceptedFiles : acceptedFiles }); myDropzone.on("success", function(file, http) { windo...
$( document ).ready(function() { Dropzone.autoDiscover = false; var myDropzone = new Dropzone(".dropzone", { url: '/api/file', autoProcessQueue: true, maxFilesize: maxFilesize, acceptedFiles : acceptedFiles }); myDropzone.on("queuecomplete", function(file, http) { ...
Fix early redirect when uploading multiple files
Fix early redirect when uploading multiple files I had the case where I needed to upload 20+ files. Some files were uploaded others not. The others failed due to the location.reload() function triggered on the first success emit from a first successful upload. It seems by using the queuecomplete event it works in...
JavaScript
mit
zedee/Media,zedee/Media,AsgardCms/Media,oimken/Media,MentallyFriendly/Media,mikemand/Media,gabva/Media,mikemand/Media,AsgardCms/Media,mikemand/Media,AsgardCms/Media,MentallyFriendly/Media,gabva/Media,ruscon/Media,oimken/Media,zedee/Media,oimken/Media,ruscon/Media
16eadc7fd084c4d4471655aa5239b77c933529db
tasks/options/concat_sourcemap.js
tasks/options/concat_sourcemap.js
module.exports = { app: { src: ['tmp/transpiled/app/**/*.js'], dest: 'tmp/public/assets/app.js' }, test: { src: 'tmp/transpiled/tests/**/*.js', dest: 'tmp/public/tests/tests.js' } };
module.exports = { app: { src: ['tmp/transpiled/app/**/*.js'], dest: 'tmp/public/assets/app.js', options: { sourcesContent: true }, }, test: { src: 'tmp/transpiled/tests/**/*.js', dest: 'tmp/public/tests/tests.js', options: { sourcesContent: true } } };
Revert "sourceMappingURL instead of sourceContent for now"
Revert "sourceMappingURL instead of sourceContent for now" This reverts commit cd758092a64445d48c5e4ab61407a5c5b51ea8f1.
JavaScript
mit
sajt/ember-weather,mixonic/ember-app-kit,duvillierA/try_ember,grese/miner-app-OLD,cevn/tasky-web,ClockworkNet/ember-boilerplate,stefanpenner/ember-app-kit,kiwiupover/seattle-auckland-weather,kiwiupover/ember-weather,shin1ohno/want-js,tomclose/minimal_eak_test_stub_problem,ClockworkNet/ember-boilerplate,Anshdesire/ember...
c518210b525a55e01f8ec1551ec40a2d08133bac
public/js/routes/Routes.js
public/js/routes/Routes.js
define(['app', 'controllers/Today', 'controllers/History', 'services/History'], function (app) { "use strict"; return app.config(['$routeProvider', function (routes) { routes .when('/', { controller: 'TodayController', templateUrl: '/partials/today.html' }) .when('/history', {...
define(['app', 'controllers/Today', 'controllers/History', 'services/History'], function (app) { "use strict"; return app.config(['$routeProvider', function (routes) { routes .when('/', { controller: 'TodayController', templateUrl: '/partials/today.html' }) .when('/history', {...
Fix resolve for minified route controller
Fix resolve for minified route controller
JavaScript
mit
BrettBukowski/tomatar
11764092ee043286fd017da940c28df51a4eba00
client/js/directives/fancy-box-directive.js
client/js/directives/fancy-box-directive.js
"use strict"; angular.module("hikeio"). directive("fancybox", ["$rootScope", function($rootScope) { return { link: function (scope, element, attrs) { scope.$on("$routeChangeStart", function () { $.fancybox.close(); }); scope.$on("fancyboxClose", function () { $.fancybox.close(); }); ...
"use strict"; angular.module("hikeio"). directive("fancybox", ["$rootScope", function($rootScope) { return { link: function (scope, element, attrs) { var context = { afterLoad: function(current, previous) { $rootScope.$broadcast("fancyboxLoaded"); }, afterClose: function(current, previou...
Remove fancybox afterLoad / afterClose event on destroy.
Remove fancybox afterLoad / afterClose event on destroy.
JavaScript
mit
zaknelson/hike.io,zaknelson/hike.io,zaknelson/hike.io,zaknelson/hike.io
3716935789ed49ae905df0d3da6adf8c52e0f966
platform/wasm/test-server.js
platform/wasm/test-server.js
"use strict"; const http = require("http"); const express = require("express"); let app = express(); // Use Cross-Origin headers so browsers allow SharedArrayBuffer app.use(function(req, res, next) { res.header("Cross-Origin-Opener-Policy", "same-origin"); res.header("Cross-Origin-Embedder-Policy", "require-corp")...
"use strict"; const http = require("http"); const express = require("express"); let app = express(); // Add some logging on each request app.use(function(req, res, next) { const date = new Date().toISOString(); console.log( `[${date}] "${cyan(req.method)} ${cyan(req.url)}" "${req.headers["user-agent"]}"` ); ne...
Add logging to test server
muwasm: Add logging to test server
JavaScript
agpl-3.0
ArtifexSoftware/mupdf,ArtifexSoftware/mupdf,ArtifexSoftware/mupdf,ArtifexSoftware/mupdf,ArtifexSoftware/mupdf,ArtifexSoftware/mupdf,ArtifexSoftware/mupdf,ArtifexSoftware/mupdf
a1bf63b212b97d8b7e1ad90e7397ab79defe902c
generatorTests/test/directoryStructureSpec.js
generatorTests/test/directoryStructureSpec.js
var path = require('path'); var chai = require('chai'); chai.use(require('chai-fs')); chai.should(); const ROOT_DIR = path.join(process.cwd(), '..'); describe('As a dev', function() { describe('When testing generator directory structure', function() { it('then _config folder should exist', function() {...
var path = require('path'); var chai = require('chai'); chai.use(require('chai-fs')); chai.should(); const ROOT_DIR = path.join(process.cwd(), '..'); describe('As a dev', function() { describe('When testing generator directory structure', function() { var pathToTest; it('then _config folder sh...
Update directoryStructure test to include all base folders. Refactor order to mirror folder order, minor refactor
test: Update directoryStructure test to include all base folders. Refactor order to mirror folder order, minor refactor
JavaScript
mit
CodeRichardJohnston/slate-demo,cartridge/cartridge-cli,code-computerlove/quarry,code-computerlove/slate-cli,cartridge/cartridge,code-computerlove/slate,CodeRichardJohnston/slate-demo,code-computerlove/slate
eaac19a6be8c660bec896dea0c0968590e3eeee4
src/js/app/view/history.js
src/js/app/view/history.js
var Backbone = require('backbone'); var url = require('url'); "use strict"; exports.HistoryUpdate = Backbone.View.extend({ initialize : function () { console.log('HistoryUpdate:initialize'); this.listenTo(this.model, "change:asset", this.assetChanged); this.listenTo(this.model, "change:ac...
var Backbone = require('backbone'); var url = require('url'); "use strict"; exports.HistoryUpdate = Backbone.View.extend({ initialize : function () { console.log('HistoryUpdate:initialize'); this.listenTo(this.model, "change:asset", this.assetChanged); this.listenTo(this.model, "change:ac...
Allow for more flexible url pattern
Allow for more flexible url pattern
JavaScript
bsd-3-clause
menpo/landmarker.io,menpo/landmarker.io,menpo/landmarker.io
ffae6c6f7c935684a132b191b71bae1919ecffab
src/js/config/config.js
src/js/config/config.js
var url = require("url"); var packageJSON = require("../../../package.json"); var config = { // @@ENV gets replaced by build system environment: "@@ENV", // If the UI is served through a proxied URL, this can be set here. rootUrl: "", // Defines the Marathon API URL, // leave empty to use the same as the U...
var packageJSON = require("../../../package.json"); var config = { // @@ENV gets replaced by build system environment: "@@ENV", // If the UI is served through a proxied URL, this can be set here. rootUrl: "", // Defines the Marathon API URL, // leave empty to use the same as the UI is served. apiURL: ".....
Revert "Convert relative apiURL paths to absolute paths"
Revert "Convert relative apiURL paths to absolute paths" This reverts commit d4649622aecd8d1cae56963fd4f214acf45b0cf3.
JavaScript
apache-2.0
cribalik/marathon-ui,mesosphere/marathon-ui,mesosphere/marathon-ui,cribalik/marathon-ui
0703a2c971dc6fc0e0280c680e539a696fc81f2c
app/directives/player/player.js
app/directives/player/player.js
angular.module('soundmist').directive('player', function (Player) { return { restrict: 'E', scope: false, replace: false, templateUrl: 'directives/player/player.html', link: function (scope, element) { scope.Player = Player let slider = angular.element(document.querySelector('#progres...
angular.module('soundmist').directive('player', function (Player) { return { restrict: 'E', scope: false, replace: false, templateUrl: 'directives/player/player.html', link: function (scope, element) { scope.Player = Player let slider = angular.element(document.querySelector('#progres...
Increase headers background color opacity
Increase headers background color opacity
JavaScript
cc0-1.0
Kattjakt/soundmist,Kattjakt/soundmist
9f2b45cec678d106844359977968c859f1bc9c16
app/scripts/services/invitation-service.js
app/scripts/services/invitation-service.js
'use strict'; (function() { angular.module('ncsaas') .service('invitationService', ['baseServiceClass', '$http', 'ENV', invitationService]); function invitationService(baseServiceClass, $http, ENV) { /*jshint validthis: true */ var vm = this; var ServiceClass = baseServiceClass.extend({ init...
'use strict'; (function() { angular.module('ncsaas') .service('invitationService', ['baseServiceClass', '$http', 'ENV', invitationService]); function invitationService(baseServiceClass, $http, ENV) { /*jshint validthis: true */ var ServiceClass = baseServiceClass.extend({ init: function() { ...
Implement invitation data service (WAL-32)
Implement invitation data service (WAL-32)
JavaScript
mit
opennode/waldur-homeport,opennode/waldur-homeport,opennode/waldur-homeport,opennode/waldur-homeport
1e2dacf7b8946f8e97d0ae823cfd00a2cf131819
src/lib/backend/lib/find_dirs_with_entry.js
src/lib/backend/lib/find_dirs_with_entry.js
"use strict"; const fs = require("fs-extra-promise"); const path = require("path"); const log = require("log"); const findDirsWithEntry = async (baseDir, entryFile = "index.js") => { const res = []; const dirContent = await fs.readdirAsync(baseDir); for (const dirName of dirContent) { const dirPat...
"use strict"; const fs = require("fs-extra-promise"); const path = require("path"); const log = require("log"); const findDirsWithEntry = async (baseDir, entryFile = "index.js") => { const res = []; const dirContent = await fs.readdirAsync(baseDir); for (const dirName of dirContent) { const dirPat...
Fix problem with regular files in search paths
backend: Fix problem with regular files in search paths
JavaScript
mit
Combitech/codefarm,Combitech/codefarm,Combitech/codefarm
0dae84d675d76dafcde86eb1911b9c9f3cf31997
src/view/table/cell/EditableAmountCell.js
src/view/table/cell/EditableAmountCell.js
/** * Cell used for showing and allowing the editing of an AmountEntry * * Copyright 2015 Ethan Smith */ var $ = require('jquery'), AmountEntryCell = require('./AmountEntryCell'); var EditableAmountCell = AmountEntryCell.extend({ render: function() { var self = this; this._super(); this...
/** * Cell used for showing and allowing the editing of an AmountEntry * * Copyright 2015 Ethan Smith */ var $ = require('jquery'), AmountEntryCell = require('./AmountEntryCell'); var EditableAmountCell = AmountEntryCell.extend({ render: function() { var self = this; this._super(); this...
Update model and trigger edited event on blur
Update model and trigger edited event on blur
JavaScript
mit
onebytegone/banknote-client,onebytegone/banknote-client
6aa462a2d69c71f8813925b65c715d329a912ef0
packages/react/src/TransitionContainer.js
packages/react/src/TransitionContainer.js
// @flow import type { Children } from 'react'; import React from 'react'; import { addTransitionListener } from 'yubaba-core'; export default class TransitionContainer extends React.Component { _detatch: Function; props: { pair: string, children?: Children, style?: any, }; state = { visibl...
// @flow import type { Children } from 'react'; import React from 'react'; import { addTransitionListener } from 'yubaba-core'; export default class TransitionContainer extends React.Component { _detatch: Function; props: { pair: string, children?: Children, style?: any, }; state = { visibl...
Check for documents existance in transition container
Check for documents existance in transition container
JavaScript
mit
madou/yubaba,madou/yubaba
2754983001e7a5853620db4d1b13b91a944424c9
server.js
server.js
require('dotenv').config({silent: true}); const process = require('process'); const http = require('http'); const createHandler = require('github-webhook-handler'); const GitHubApi = require('github'); const Configuration = require('./lib/configuration'); const Dispatcher = require('./lib/dispatcher'); const installat...
require('dotenv').config({silent: true}); const process = require('process'); const http = require('http'); const createHandler = require('github-webhook-handler'); const Configuration = require('./lib/configuration'); const Dispatcher = require('./lib/dispatcher'); const installations = require('./lib/installations')...
Remove unused github api instance
Remove unused github api instance
JavaScript
isc
pholleran-org/probot,probot/probot,bkeepers/PRobot,probot/probot,pholleran-org/probot,probot/probot,pholleran-org/probot,bkeepers/PRobot
9f3981cd7e6ba35ee01a5a81e6cd1ba8f6e524f2
server.js
server.js
var queue = require('queue-async'); var express = require('express'); var request = require('request'); var app = express(); app.use(express.static(__dirname + '/static')); app.get('/:owner/:repo', function(req, res, next) { var q = queue(); var repoName = req.params.owner + '/' + req.params.repo; res.locals.re...
var queue = require('queue-async'); var express = require('express'); var request = require('request'); var app = express(); app.use(express.static(__dirname + '/static')); function renderStargazes(req, res, next) { var q = queue(); for (var i=1; i<=10; i++) { q.defer(request,{ url:'https://api.github.c...
Add environmental config for root repo
Add environmental config for root repo
JavaScript
mit
stuartpb/starwatchcats,stuartpb/starwatchcats