commit
stringlengths
40
40
old_file
stringlengths
4
150
new_file
stringlengths
4
150
old_contents
stringlengths
0
3.26k
new_contents
stringlengths
1
4.43k
subject
stringlengths
15
501
message
stringlengths
15
4.06k
lang
stringclasses
4 values
license
stringclasses
13 values
repos
stringlengths
5
91.5k
diff
stringlengths
0
4.35k
6192011404e89449132349044a3e872f90b0f075
src/client/app/states/projects/list/list.state.js
src/client/app/states/projects/list/list.state.js
(function() { 'use strict'; angular.module('app.states') .run(appRun); /** @ngInject */ function appRun(routerHelper) { routerHelper.configureStates(getStates()); } function getStates() { return { 'projects.list': { url: '', // No url, this state is the index of projects ...
(function() { 'use strict'; angular.module('app.states') .run(appRun); /** @ngInject */ function appRun(routerHelper) { routerHelper.configureStates(getStates()); } function getStates() { return { 'projects.list': { url: '', // No url, this state is the index of projects ...
Update strings to use single quotes for jshint
Update strings to use single quotes for jshint
JavaScript
apache-2.0
mafernando/api,boozallen/projectjellyfish,sonejah21/api,AllenBW/api,sreekantch/JellyFish,sreekantch/JellyFish,AllenBW/api,sonejah21/api,boozallen/projectjellyfish,sonejah21/api,AllenBW/api,mafernando/api,stackus/api,projectjellyfish/api,projectjellyfish/api,projectjellyfish/api,stackus/api,stackus/api,boozallen/project...
--- +++ @@ -40,7 +40,7 @@ activate(); function activate() { - vm.projects = lodash.sortBy(vm.projects, "name"); + vm.projects = lodash.sortBy(vm.projects, 'name'); } } })();
27cbc851dc68c9326b4958cc3174265712679460
test/util.js
test/util.js
/* global describe it */ 'use strict' const chai = require('chai') const chaiAsPromised = require('chai-as-promised') const requireInject = require('require-inject') const sinon = require('sinon') const sinonChai = require('sinon-chai') require('sinon-as-promised') chai.use(chaiAsPromised) chai.use(sinonChai) const ...
/* global describe it beforeEach */ 'use strict' const chai = require('chai') const chaiAsPromised = require('chai-as-promised') const requireInject = require('require-inject') const sinon = require('sinon') const sinonChai = require('sinon-chai') require('sinon-as-promised') chai.use(chaiAsPromised) chai.use(sinonCh...
Refactor to reuse test case initialization code
Refactor to reuse test case initialization code
JavaScript
isc
jcollado/multitest
--- +++ @@ -1,4 +1,4 @@ -/* global describe it */ +/* global describe it beforeEach */ 'use strict' const chai = require('chai') @@ -14,25 +14,27 @@ const expect = chai.expect describe('exec', function () { - it('rejects if childProcess.exec fails', function () { - const exec = sinon.stub().yields('some e...
a6ec8b746abad9be76218e8e5dd9948aa358a1b9
GruntTasks/Options/concat.libcss.js
GruntTasks/Options/concat.libcss.js
module.exports = { src: [ 'vendor/bower_components/bootstrap/dist/css/bootstrap.css', 'vendor/bower_components/open-sans/css/open-sans.css', 'vendor/bower_components/jquery-minicolors/jquery.minicolors.css', 'vendor/bower_components/font-awesome/css/font-awesome.css', 'vendor/bowe...
module.exports = { src: [ 'vendor/bower_components/open-sans/css/open-sans.css', 'vendor/bower_components/jquery-minicolors/jquery.minicolors.css', 'web/bundles/openorchestrabackoffice/smartadmin/css/bootstrap.css', 'vendor/bower_components/font-awesome/css/font-awesome.css', 'ven...
Use smartadmin bootraps.css version instead of bower one
Use smartadmin bootraps.css version instead of bower one
JavaScript
apache-2.0
open-orchestra/open-orchestra-cms-bundle,open-orchestra/open-orchestra-cms-bundle,open-orchestra/open-orchestra-cms-bundle
--- +++ @@ -1,11 +1,11 @@ module.exports = { src: [ - 'vendor/bower_components/bootstrap/dist/css/bootstrap.css', 'vendor/bower_components/open-sans/css/open-sans.css', 'vendor/bower_components/jquery-minicolors/jquery.minicolors.css', + 'web/bundles/openorchestrabackoffice/smartadmi...
82b91b594c41774f9ea03e2538b0615efdabcfaa
lib/graph.js
lib/graph.js
import _ from 'lodash'; import { Graph, alg } from 'graphlib'; _.memoize.Cache = WeakMap; let dijkstra = _.memoize(alg.dijkstra); export function setupGraph(pairs) { let graph = new Graph({ directed: true }); _.each(pairs, ({ from, to, method }) => graph.setEdge(from, to, method)); return graph; } export function...
import _ from 'lodash'; import { Graph, alg } from 'graphlib'; _.memoize.Cache = WeakMap; let dijkstra = _.memoize(alg.dijkstra); export function setupGraph(pairs) { let graph = new Graph({ directed: true }); _.each(pairs, ({ from, to, method }) => graph.setEdge(from, to, method)); return graph; } export function...
Add a function to validate relationship objects
Add a function to validate relationship objects
JavaScript
mit
siddharthkchatterjee/graph-resolver
--- +++ @@ -20,3 +20,12 @@ return path.reverse(); } } + +export function validateRelationship({ from, to, method }) { + let validations = [ + _.isString(from), + _.isString(to), + _.isFunction(method) + ]; + return _.every(validations, Boolean); +}
14df8efec1598df37a7d6971cee3a4d176f48ea5
app/components/CellTextField/index.js
app/components/CellTextField/index.js
/** * * CellTextField * */ import React from 'react'; import TextField from 'material-ui/TextField'; import styles from './styles.css'; class CellTextField extends React.Component { // eslint-disable-line react/prefer-stateless-function static defaultProps = { label: 'test', width: '50%', }; static p...
/** * * CellTextField * */ import React from 'react'; import TextField from 'material-ui/TextField'; import styles from './styles.css'; class CellTextField extends React.Component { // eslint-disable-line react/prefer-stateless-function static defaultProps = { label: 'test', width: '50%', }; static p...
Validate if input is number
Validate if input is number
JavaScript
mit
codermango/BetCalculator,codermango/BetCalculator
--- +++ @@ -18,22 +18,51 @@ static propTypes = { label: React.PropTypes.string, + width: React.PropTypes.string, }; + checkInput = (e) => { + const textValue = Number(e.target.value); + console.log(textValue); + if (Number.isNaN(textValue)) { + this.setState({ + label: 'Please ...
706abfd07626606a8c901f4643ffcfd0fd1154c5
src/modules/confirm.js
src/modules/confirm.js
(function () { "use strict"; var moduleObj = moduler('confirm', { defaults: { message: 'Are you sure you want to perform this action?', event: 'click' }, init: function (module) { module.$element.on(module.settings.event, module, moduleObj.li...
(function () { "use strict"; var moduleObj = moduler('confirm', { defaults: { message: 'Are you sure you want to perform this action?', event: 'click' }, init: function (module) { module.$element.on(module.settings.event, module, moduleObj.li...
Fix for destroy method of Confirm
Fix for destroy method of Confirm
JavaScript
mit
simplyio/moduler.js,simplyio/moduler.js
--- +++ @@ -23,7 +23,7 @@ }) }, - destroy: function () { + destroy: function (module) { module.$element.off(module.settings.event, moduleObj.listen.showConfirm); } });
89970c235f4bae57087906c4e5346f188928ce7d
generators/app/index.js
generators/app/index.js
var generators = require('yeoman-generator'); module.exports = generators.Base.extend({ method1: function () { console.log('method 1 just ran'); }, method2: function () { console.log('method 2 just ran'); } });
var generators = require('yeoman-generator'); var inquirer = require("inquirer"); module.exports = generators.Base.extend({ bowerPackages: function() { inquirer.prompt([{ type: "checkbox", message: "Select bower packages to install", name: "Bower packages", choices: [ new inquirer.Separator("Css Fr...
Add prompt to ask for css framework install
Add prompt to ask for css framework install
JavaScript
bsd-3-clause
initios/initios-yeoman,initios/initios-yeoman
--- +++ @@ -1,10 +1,20 @@ var generators = require('yeoman-generator'); +var inquirer = require("inquirer"); module.exports = generators.Base.extend({ - method1: function () { - console.log('method 1 just ran'); - }, - method2: function () { - console.log('method 2 just ran'); - } + bowerPackages: funct...
fd792ad7cdb9881e30fd16595df87b45ebccc78a
src/components/stats/ExternalModuleLink.js
src/components/stats/ExternalModuleLink.js
/* * @flow */ import type {Module} from '../../types/Stats'; import React from 'react'; import {getClassName} from '../Bootstrap/GlyphiconNames'; import {Link} from '../Bootstrap/Button'; type Props = { prefix: ?string, module: Module, }; export default function ExternalModuleLink(props: Props) { // https:/...
/* * @flow */ import type {Module} from '../../types/Stats'; import React from 'react'; import {getClassName} from '../Bootstrap/GlyphiconNames'; import {Link} from '../Bootstrap/Button'; type Props = { prefix: ?string, module: Module, }; export default function ExternalModuleLink(props: Props) { if (props....
Add aria label to external link component
Add aria label to external link component
JavaScript
apache-2.0
pinterest/bonsai,pinterest/bonsai,pinterest/bonsai
--- +++ @@ -14,20 +14,15 @@ }; export default function ExternalModuleLink(props: Props) { - // https://phabricator.pinadmin.com/diffusion/P/browse/master/webapp/app/mobile/index.js$20 - // https://phabricator.pinadmin.com/diffusion/P/browse/master/ - // ../../../../../app/analytics/modules/SelectButtonWrapper/...
b4466bf9068b0d1515a646df091e447f3fa68c96
src/App.js
src/App.js
//@flow import { bindActionCreators } from "redux"; import { connect } from "react-redux"; import * as actionCreators from "./data/actions/actionCreators"; import insertGlobalStyles from "./global/style/globalStyles"; import { Main } from "./scenes/Main"; function mapStateToProps(): {} { return {}; } export funct...
//@flow import { bindActionCreators } from "redux"; import { connect } from "react-redux"; import * as actionCreators from "./data/actions/actionCreators"; import { Main } from "./scenes/Main"; function mapStateToProps(state: { cards: {}[] }): {} { return { cards: state.cards }; } export function mapDispatchToPro...
Remove global styles and add some dummy state (cards)
Remove global styles and add some dummy state (cards)
JavaScript
mit
slightly-askew/portfolio-2017,slightly-askew/portfolio-2017
--- +++ @@ -3,18 +3,15 @@ import { bindActionCreators } from "redux"; import { connect } from "react-redux"; import * as actionCreators from "./data/actions/actionCreators"; -import insertGlobalStyles from "./global/style/globalStyles"; import { Main } from "./scenes/Main"; -function mapStateToProps(): {} { -...
1fe48dd8228d78b124852389dbef4b564a124d37
src/App.js
src/App.js
import React from 'react'; import bukovelAPI from './dataAccess/bukovelApi'; import CardNumberInput from './CardNumberInput'; const TEST_CARD_NUMBER = '01-2167-30-92545'; export default class App extends React.Component { constructor() { super(); this.state = { html: '', cardNumber: TEST_CARD_N...
import React from 'react'; import bukovelAPI from './dataAccess/bukovelApi'; import CardNumberInput from './CardNumberInput'; const TEST_CARD_NUMBER = '01-2167-30-92545'; export default class App extends React.Component { constructor() { super(); this.state = { html: '', cardNumber: '' }; ...
Remove auto insertion of test card number.
Remove auto insertion of test card number.
JavaScript
apache-2.0
blobor/skipass.site,blobor/buka,blobor/skipass.site,blobor/buka
--- +++ @@ -10,7 +10,7 @@ this.state = { html: '', - cardNumber: TEST_CARD_NUMBER + cardNumber: '' }; this.handleCardNumberChange = this.handleCardNumberChange.bind(this); } @@ -31,6 +31,7 @@ return ( <div> <CardNumberInput onChange={this.handleCardNumberChang...
81daf4cbd5504a15536d56058e2758505222f910
src/App.js
src/App.js
import React from 'react' import styled from 'styled-components' import { Intro, CheckboxTree } from './components' import data from './data/data.json' import github from './assets/github.svg' const Main = styled.main` display: flex; flex-direction: column; width: 80%; max-width: 64rem; height: 100vh; mar...
import React from 'react' import styled from 'styled-components' import { Intro, CheckboxTree } from './components' import data from './data/data.json' import github from './assets/github.svg' const Main = styled.main` display: flex; flex-direction: column; width: 80%; max-width: 64rem; height: 100vh; mar...
Update GitHub icon alt text
Update GitHub icon alt text
JavaScript
mit
joelgeorgev/react-checkbox-tree,joelgeorgev/react-checkbox-tree
--- +++ @@ -38,7 +38,7 @@ </Section> <Footer> <a href='https://github.com/joelgeorgev/react-checkbox-tree'> - <img src={github} alt='GitHub repository' /> + <img src={github} alt='Go to GitHub repository page' /> </a> </Footer> </Main>
55634a3654b1b25d636caaa548f82ce33f89acb0
src/app.js
src/app.js
/* global fetch */ import React from 'react'; import { render } from 'react-dom'; import { Router, Route, hashHistory } from 'react-router' import Home from './home'; import CaseHandler from './caseHandler'; import Adjudicator from './adjudicator'; class App extends React.Component { render() { return ( ...
/* global fetch */ import React from 'react'; import { render } from 'react-dom'; import { Router, Route, hashHistory } from 'react-router' import Home from './home'; import CaseHandler from './caseHandler/caseHandler'; import Adjudicator from './adjudicator/adjudicator'; class App extends React.Component { rend...
Fix up file references after folder restructure
Fix up file references after folder restructure
JavaScript
mit
dgretho/adjudication,dgretho/adjudication
--- +++ @@ -4,8 +4,8 @@ import { Router, Route, hashHistory } from 'react-router' import Home from './home'; -import CaseHandler from './caseHandler'; -import Adjudicator from './adjudicator'; +import CaseHandler from './caseHandler/caseHandler'; +import Adjudicator from './adjudicator/adjudicator'; class Ap...
b3522adddaa4415c8afcd3f1f11fefd2b488d358
lib/ferrite/utility.js
lib/ferrite/utility.js
/** * copyObject(object, [recurse]) -- for all JS Objects * * Copies all properties and the prototype to a new object * Optionally set recurse to array containing the properties, on wich this function should be called recursively */ function copyObject(object, recurse) { var new_obj = Object.create(Object.getPro...
/** * copyObject(object, [recurse]) -- for all JS Objects * * Copies all properties and the prototype to a new object * Optionally set recurse to array containing the properties, on wich this function should be called recursively */ function copyObject(object, recurse) { var new_obj = Object.create(Object.getPro...
Fix calcLineNo for undefined offset
Fix calcLineNo for undefined offset - now returns -1
JavaScript
mit
marcelklehr/magnet
--- +++ @@ -26,7 +26,7 @@ } function calcLineNo(source, offset) { - return source.substr( 0, offset ).split("\n").length; + return offset ? source.substr( 0, offset ).split("\n").length : -1; }; function getLineExcerpt(source, offset) {
8d0750fb6ca50a5e07a54c17813af6d5a724b8c5
lib/jekyll-template.js
lib/jekyll-template.js
var path = require('path'); module.exports = function jekyllTemplate(answers) { return [ '---', 'layout: post', 'date: ' + answers.date, 'duration: ' + answers.duration, 'categories: ' + answers.categories, 'img: ' + path.normalize('./assets/image/speakers/' + answers.imagePath ), 'link: '...
var path = require('path'); module.exports = function jekyllTemplate(answers) { return [ '---', 'layout: post', 'title' + answers.title, 'date: ' + answers.date, 'duration: ' + answers.duration, 'tags: ' + answers.tags, 'img: ' + '/assets/image/speakers/' + answers.imagePath, 'link: ' ...
Add title and fix tags and image path in Jekyll template
Add title and fix tags and image path in Jekyll template
JavaScript
mit
free-time/freetime-cli,fdaciuk/freetime-cli
--- +++ @@ -3,10 +3,11 @@ return [ '---', 'layout: post', + 'title' + answers.title, 'date: ' + answers.date, 'duration: ' + answers.duration, - 'categories: ' + answers.categories, - 'img: ' + path.normalize('./assets/image/speakers/' + answers.imagePath ), + 'tags: ' + answers.tag...
1185b3e82cd7c3f6483a604d9348f35f16f294f0
config/index.js
config/index.js
// see http://vuejs-templates.github.io/webpack for documentation. var path = require('path') module.exports = { build: { env: require('./prod.env'), index: path.resolve(__dirname, '../dist/index.html'), assetsRoot: path.resolve(__dirname, '../dist'), assetsSubDirectory: 'static', assetsPublicPat...
// see http://vuejs-templates.github.io/webpack for documentation. var path = require('path') module.exports = { build: { env: require('./prod.env'), index: path.resolve(__dirname, '../dist/index.html'), assetsRoot: path.resolve(__dirname, '../dist'), assetsSubDirectory: 'static', assetsPublicPat...
Revert "reopen port to 80"
Revert "reopen port to 80" This reverts commit 3cfed3456cbed7f6f4a71c114b2645a278b27979.
JavaScript
mit
Cubelrti/kontent,Cubelrti/kontent
--- +++ @@ -23,7 +23,7 @@ }, dev: { env: require('./dev.env'), - port: 80, + port: 8080, autoOpenBrowser: false, assetsSubDirectory: 'static', assetsPublicPath: '/',
ad65439c6f7c21aee73c797f2be02ad861a31e8d
src/utils/constants.js
src/utils/constants.js
const PORT = '6882' const ROOT = location.href.indexOf('localhost') > 0 ? 'http://localhost:' : 'http://192.168.5.102:' export const ROOT_URL = ROOT + PORT + '/' export const ROOT_URL_API = ROOT_URL + 'api' export const YOUTUBE_CONSTS = { YOUTUBE: 'Youtube', URL: 'http://www.youtube.com/embed/', API: 'enabl...
const PORT = '6882' const ROOT = location.href.indexOf('reuvenliran') > 0 ? 'http://reuvenliran.hopto.org:' : location.href export const ROOT_URL = ROOT.indexOf('8080') ? ROOT.replace('8080', PORT) : ROOT + PORT + '/' export const ROOT_URL_API = ROOT_URL + 'api' export const YOUTUBE_CONSTS = { YOUTUBE: 'Youtube...
Fix bug with url refernce to server
Fix bug with url refernce to server
JavaScript
mit
ReuvenLiran/react-musicplayer,ReuvenLiran/react-musicplayer
--- +++ @@ -1,7 +1,7 @@ const PORT = '6882' const ROOT = - location.href.indexOf('localhost') > 0 ? 'http://localhost:' : 'http://192.168.5.102:' -export const ROOT_URL = ROOT + PORT + '/' + location.href.indexOf('reuvenliran') > 0 ? 'http://reuvenliran.hopto.org:' : location.href +export const ROOT_URL =...
5be884f967a79f852e2b7d2c5c814ca90df369cd
src/request/stores/request-detail-store.js
src/request/stores/request-detail-store.js
var glimpse = require('glimpse'), requestRepository = require('../repository/request-repository.js'), // TODO: Not sure I need to store the requests _requests = {}, _requestSelectedId = null; function requestsChanged(targetRequests) { glimpse.emit('shell.request.summary.changed', targetRequests); }...
var glimpse = require('glimpse'), requestRepository = require('../repository/request-repository.js'), // TODO: Not sure I need to store the requests _requests = {}, _requestSelectedId = null; function requestChanged(targetRequests) { glimpse.emit('shell.request.detail.changed', targetRequests); } ...
Switch over detail store to call central requestChange event
Switch over detail store to call central requestChange event
JavaScript
unknown
avanderhoorn/Glimpse.Client.Prototype,avanderhoorn/Glimpse.Client.Prototype,Glimpse/Glimpse.Client.Prototype,Glimpse/Glimpse.Client.Prototype,Glimpse/Glimpse.Client.Prototype
--- +++ @@ -4,8 +4,8 @@ _requests = {}, _requestSelectedId = null; -function requestsChanged(targetRequests) { - glimpse.emit('shell.request.summary.changed', targetRequests); +function requestChanged(targetRequests) { + glimpse.emit('shell.request.detail.changed', targetRequests); } // Clear Re...
5f104201a91614820aa8acdc6fdfe6d9dd027695
components/shared/score.js
components/shared/score.js
import React, { Component } from "react"; import { formatTime } from "../../common/util/date"; export default class extends Component { render() { const { match } = this.props; if (match.fixture) { return match.time && <span>{formatTime(match.date, match.time)}</span>; } if (match.live || mat...
import React, { Component } from "react"; import { formatTime } from "../../common/util/date"; export default class extends Component { render() { const { match } = this.props; if (match.live || match.ended) { return ( <span className={match.live && "live"}> {match.ft && (!match.et |...
Fix match time not showing for fixtures
Fix match time not showing for fixtures
JavaScript
isc
sobstel/golazon,sobstel/golazon,sobstel/golazon
--- +++ @@ -4,10 +4,6 @@ export default class extends Component { render() { const { match } = this.props; - - if (match.fixture) { - return match.time && <span>{formatTime(match.date, match.time)}</span>; - } if (match.live || match.ended) { return ( @@ -44,6 +40,10 @@ return...
d77e2510a2bcef6d0713d93fc962604c6340d461
src/components/avatar/AvatarTeam.js
src/components/avatar/AvatarTeam.js
import React, { PureComponent } from 'react'; import PropTypes from 'prop-types'; import cx from 'classnames'; import theme from './theme.css'; import Box from '../box'; import Icon from '../icon'; import { IconTeamMediumOutline, IconTeamSmallOutline } from '@teamleader/ui-icons'; class AvatarTeam extends PureComponen...
import React, { PureComponent } from 'react'; import PropTypes from 'prop-types'; import cx from 'classnames'; import theme from './theme.css'; import Box from '../box'; import Icon from '../icon'; import { IconTeamMediumOutline, IconTeamSmallOutline } from '@teamleader/ui-icons'; class AvatarTeam extends PureComponen...
Use correct background & icon colors according to design
Use correct background & icon colors according to design
JavaScript
mit
teamleadercrm/teamleader-ui
--- +++ @@ -14,13 +14,13 @@ <Box alignItems="center" backgroundColor="neutral" - backgroundTint="normal" + backgroundTint="darkest" className={cx(theme['avatar'], theme['avatar-team'])} data-teamleader-ui="avatar-team" display="flex" justifyCo...
a276e5e6324b54a75c2b32695766258920726607
src/subdomain.js
src/subdomain.js
import { routers } from './router'; const detectsubdomain = async function detectsubdomain (ctx, next) { let [subdomain = 'www'] = ctx.request.subdomains; ctx.subdomain = subdomain; if (ctx.request.origin.indexOf(configuration.server.host) > -1) { ctx.response.set('Access-Control-Allow-Origin', ctx.request.origin...
import { routers } from './router'; const detectsubdomain = async function detectsubdomain (ctx, next) { let [subdomain = 'www'] = ctx.request.subdomains; ctx.subdomain = subdomain; let origin = ctx.headers.origin ? ctx.headers.origin : ctx.request.origin; if (origin.indexOf(configuration.server.host) > -1) { ct...
Access controll allow headers will be correctly detected
fix: Access controll allow headers will be correctly detected
JavaScript
agpl-3.0
gerard2p/koaton
--- +++ @@ -3,8 +3,9 @@ const detectsubdomain = async function detectsubdomain (ctx, next) { let [subdomain = 'www'] = ctx.request.subdomains; ctx.subdomain = subdomain; - if (ctx.request.origin.indexOf(configuration.server.host) > -1) { - ctx.response.set('Access-Control-Allow-Origin', ctx.request.origin); + l...
55e40c0504b02708f544e1d464715123570b80cd
hosting/src/components/shared/Footer.js
hosting/src/components/shared/Footer.js
import React, { Component } from 'react' import styled from 'styled-components' const FooterWrapper = styled.div` display: flex; justify-content: center; align-items: center; height: 10vh; font-size: 0.85em; background: ${props => props.theme.colors.background}; color: ${props => props.theme.colors.barTe...
import React, { Component } from 'react' import styled from 'styled-components' const FooterWrapper = styled.div` display: flex; justify-content: center; align-items: center; height: 10vh; font-size: 0.85em; background: ${props => props.theme.colors.background}; color: ${props => props.theme.colors.barTe...
Fix hunters name (my fault)
Fix hunters name (my fault)
JavaScript
mit
csrf-demo/csrf-demo,csrf-demo/csrf-demo
--- +++ @@ -32,7 +32,7 @@ Fork on Github </Link> <br/> - Nick Breaton &#183; Jeremy Bohannon &#183; Hunter Aeraer + Nick Breaton &#183; Jeremy Bohannon &#183; Hunter Heavener </Content> </FooterWrapper> )
36150a42a04a3ce5cd6de20018d36f55a64f4311
static/js/app.js
static/js/app.js
$(function() { $.get('/tagovi', {csrfmiddlewaretoken: $("input[name='csrfmiddlewaretoken']").val()}, function(data) { var options = [] for (var i = 0; i < data.length; i++) { options.push(data[i].fields); } $('#id_tags').selectize({ persist: false, ...
$(function() { $.get('/tagovi', function(data) { var options = [] for (var i = 0; i < data.length; i++) { options.push(data[i].fields); } $('#id_tags').selectize({ persist: false, maxItems: 5, selectOnTab: true, valueField: ...
Fix using tokens in js.
Fix using tokens in js.
JavaScript
mit
MislavMandaric/abs-int,MislavMandaric/abs-int
--- +++ @@ -1,5 +1,5 @@ $(function() { - $.get('/tagovi', {csrfmiddlewaretoken: $("input[name='csrfmiddlewaretoken']").val()}, function(data) { + $.get('/tagovi', function(data) { var options = [] for (var i = 0; i < data.length; i++) { options.push(data[i].fields); @@ -22,7 +22,...
b673fdbdac7e5523d16904920315d4ab6c79eaf8
tennu_plugins/blt.js
tennu_plugins/blt.js
var BLTPlugin = { init: function (client, imports) { return { handlers: { '!givemeblt': function (command) { client.act(command.channel, 'gives a juicy BLT to ' + command.nickname); } }, help: { 'givemeb...
var BLTPlugin = { init: function (client, imports) { return { handlers: { '!givemeblt': function (command) { client.act(command.channel, 'gives a juicy BLT to ' + command.nickname); } }, help: { 'givemeb...
Use {{!}} instead of ! for help.
Enhancement: Use {{!}} instead of ! for help.
JavaScript
isc
Tennu/BLTBot
--- +++ @@ -9,7 +9,7 @@ help: { 'givemeblt': [ - '!givemeblt', + '{{!}}givemeblt', 'Gives the requestor a juicy BLT.' ] },
600df5d2f48c190a948cbee6c1d668db99498096
src/src.js
src/src.js
console.log("Running!"); var Library = { name: "Timmy", //Library has been called Timmy greet: function(){ alert("Hello from the " + Library.name + " library."); } /* This library is what is known as an object literal. To invoke the greet function, we would write: Library.greet(); *...
//O. M. J. This actually works. YAY!!! console.log("Running!"); var Library = { name: "John", //Library has been called Timmy greet: function(){ alert("Hello from the " + Library.name + " library."); console.log("User executed Library.greet()!" + "Hi " + name); } stop: function(text){ ...
Clean and ADD ++ (stop)
Clean and ADD ++ (stop) stop == alert
JavaScript
mit
alaskamani15/beginner.js
--- +++ @@ -1,9 +1,17 @@ +//O. M. J. This actually works. YAY!!! + console.log("Running!"); var Library = { - name: "Timmy", //Library has been called Timmy + name: "John", //Library has been called Timmy greet: function(){ alert("Hello from the " + Library.name + " library."); + consol...
b2ed3cdc9c5c12f4d93efea910e0f4f27a02eb0d
src/bar.js
src/bar.js
define(function() { var hr = codebox.require("hr/hr"); var StatusBar = hr.View.extend({ className: "component-statusbar" }); return StatusBar; });
define(function() { var hr = codebox.require("hr/hr"); var _ = codebox.require("hr/utils"); var StatusBar = hr.View.extend({ className: "component-statusbar", // Show loading indicator for a promise // Return the same promise loading: function(p, options) { va...
Add simple api for loading message
Add simple api for loading message
JavaScript
apache-2.0
CodeboxIDE/package-statusbar,etopian/codebox-package-statusbar
--- +++ @@ -1,8 +1,60 @@ define(function() { var hr = codebox.require("hr/hr"); + var _ = codebox.require("hr/utils"); var StatusBar = hr.View.extend({ - className: "component-statusbar" + className: "component-statusbar", + + + + // Show loading indicator for a promise + /...
5127fe15793fd2a35af77f7f57a71f905ddaf2a3
test/croonga.test.js
test/croonga.test.js
var http = require('http'); var should = require('should'); var spawn = require('child_process').spawn; function run(options, callback) { var command, commandPath, output; commandPath = __dirname + '/../bin/croonga'; command = spawn(commandPath, options); output = { stdout: '', stderr: '' }; comman...
var http = require('http'); var should = require('should'); var spawn = require('child_process').spawn; function run(options, callback) { var command, commandPath, output; commandPath = __dirname + '/../bin/croonga'; command = spawn(commandPath, options); output = { stdout: '', stderr: '' }; comman...
Check status code returned from croonga command
Check status code returned from croonga command
JavaScript
mit
groonga/gcs,groonga/gcs
--- +++ @@ -22,7 +22,8 @@ describe('croonga command', function() { it('should output help for --help', function(done) { run(['--help'], function(error, command, output) { - command.on('exit', function() { + command.on('exit', function(code) { + code.should.equal(0); output.stdout.sh...
5c1fa9ba4e012a25aea47d5f08302bce4a28d473
tests/dummy/app/controllers/application.js
tests/dummy/app/controllers/application.js
import Ember from 'ember'; export default Ember.Controller.extend({ toggleModal: false, actions: { testing() { window.swal("Hello World", "success"); }, toggle() { this.set('toggleModal', true); } } });
import Ember from 'ember'; export default Ember.Controller.extend({ toggleModal: false, actions: { testing() { window.swal({ title: 'Submit email to run ajax request', input: 'email', showCancelButton: true, confirmButtonText: 'Submit', preConfirm: function() { ...
Make a bit more complex dummy
Make a bit more complex dummy
JavaScript
mit
Tonkpils/ember-sweetalert,Tonkpils/ember-sweetalert
--- +++ @@ -5,7 +5,29 @@ actions: { testing() { - window.swal("Hello World", "success"); + window.swal({ + title: 'Submit email to run ajax request', + input: 'email', + showCancelButton: true, + confirmButtonText: 'Submit', + preConfirm: function() { + ...
fbec1e1a32bdda21779187391d875d58e6bd80df
lib/plugin/in/googleanalytics.js
lib/plugin/in/googleanalytics.js
var gaAnalytics = require("ga-analytics"), moment = require("moment"); var googleAnalytics = {}; googleAnalytics.load = function(args, next) { var outputs = []; // Setting before a fixed period of time if (args.timeago) { args['startDate'] = args['endDate'] = moment().add(-1 * args.timeago.ago, args.ti...
var gaAnalytics = require("ga-analytics"), moment = require("moment"), format = require('string-format'); var googleAnalytics = {}; googleAnalytics.load = function(args, next) { var outputs = []; // Setting before a fixed period of time if (args.timeago) { args['startDate'] = args['endDate'] = mome...
Update google analytics input plugin. 複数のカラムの取得対応 (resultsプロパティ追加, filterに渡すフォーマット制御プロパティ追加)
Update google analytics input plugin. 複数のカラムの取得対応 (resultsプロパティ追加, filterに渡すフォーマット制御プロパティ追加)
JavaScript
mit
hideack/evac
--- +++ @@ -1,5 +1,6 @@ var gaAnalytics = require("ga-analytics"), - moment = require("moment"); + moment = require("moment"), + format = require('string-format'); var googleAnalytics = {}; @@ -17,7 +18,20 @@ return; } - outputs.push(res.totalsForAllResults[args.metrics]); + if (arg...
b0d31962fc495128093e3a827ec725ecea567dfa
statics.js
statics.js
var express = require('express'); module.exports.init = function(app) { app.use('/js', express.static(__dirname + '/dist/js', {maxAge: 86400000 * 7})); app.use('/css', express.static(__dirname + '/dist/css', {maxAge: 86400000 * 7})); app.use('/img', express.static(__dirname + '/dist/img', {maxAge: 86400000 * 7}));...
var express = require('express'); var oneDay = 86400000; // milliseconds: 60 * 60 * 24 * 1000 var oneWeek = oneDay * 7; module.exports.init = function(app) { app.use('/css', express.static(__dirname + '/dist/css', { maxAge: oneWeek })); app.use('/font', express.static(__dirname + '/dist/font', { maxAge: oneWeek }...
Use variables for the expires date.
Use variables for the expires date.
JavaScript
mit
caktux/david-www,ecomfe/david-www,ExC0d3/david-www,caktux/david-www,wzrdtales/david-www,80xer/david-www,JoseRoman/david-www,JoseRoman/david-www,alanshaw/david-www,wzrdtales/david-www,ecomfe/david-www,80xer/david-www,ExC0d3/david-www
--- +++ @@ -1,15 +1,18 @@ var express = require('express'); + +var oneDay = 86400000; // milliseconds: 60 * 60 * 24 * 1000 +var oneWeek = oneDay * 7; module.exports.init = function(app) { - app.use('/js', express.static(__dirname + '/dist/js', {maxAge: 86400000 * 7})); - app.use('/css', express.static(__dirnam...
8568eec430b660caf4f1d59f1f67b2350234260a
webpack.config.js
webpack.config.js
/** * This config takes some basic config from conf/webpack/<dev|prod>.js * and builds the appropriate webpack config from there. * * The primary difference is that dev has webpack hot reloading * whereas dev does not. * * The 'loaders' and 'output' need to exist here, because the path needs * to exist at the r...
/** * This config takes some basic config from conf/webpack/<dev|prod>.js * and builds the appropriate webpack config from there. * * The primary difference is that dev has webpack hot reloading * whereas dev does not. * * The 'loaders' and 'output' need to exist here, because the path needs * to exist at the r...
Add verbose if else for additional logging, etc.
Add verbose if else for additional logging, etc.
JavaScript
mit
jamie-w/es6-bootstrap,jamie-w/es6-bootstrap
--- +++ @@ -14,8 +14,16 @@ var path = require('path'); +// this file is required at the root, so pass the rootDir into +// sub folders +// TODO look into cleaner ways of handling this. var rootDir = path.join(__dirname); -module.exports = settings.DEBUG ? - require('./conf/webpack/dev.js')(rootDir) : - ...
05502c29ab3e5305fb944ed8e5ca7450638c365b
blueprints/ember-cli-bootswatch/index.js
blueprints/ember-cli-bootswatch/index.js
module.exports = { description: 'Add bower dependencies for bootstrap and bootswatch to the project' afterInstall: function(options) { return this.addBowerPackagesToProject([ {name: 'bootstrap', target: '^3.3.1'}, {name: 'bootswatch', target: '^3.3.1'} ]); } };
module.exports = { description: 'Add bower dependencies for bootstrap and bootswatch to the project', normalizeEntityName: function() { // allows us to run ember -g ember-cli-bootswatch and not blow up // because ember cli normally expects the format // ember generate <entitiyName> <blueprint> }, ...
Enable running blueprint without entity name
Enable running blueprint without entity name Missed a comma after description and fix issue running blueprint without an entity name. Fixes #6
JavaScript
mit
Panman8201/ember-cli-bootswatch
--- +++ @@ -1,5 +1,11 @@ module.exports = { - description: 'Add bower dependencies for bootstrap and bootswatch to the project' + description: 'Add bower dependencies for bootstrap and bootswatch to the project', + + normalizeEntityName: function() { + // allows us to run ember -g ember-cli-bootswatch and not ...
13ec0b7104aeb85280b1adf8828b926d7cf5daad
blueprints/ember-frontmatter-md/index.js
blueprints/ember-frontmatter-md/index.js
module.exports = { description: 'Creates an initializer to load posts from the meta tag.' // locals: function(options) { // // Return custom template variables here. // return { // foo: options.entity.options.foo // }; // } // afterInstall: function(options) { // // Perform extra work he...
module.exports = { description: 'Creates an initializer to load posts from the meta tag.', // locals: function(options) { // // Return custom template variables here. // return { // foo: options.entity.options.foo // }; // } // afterInstall: function(options) { // // Perform extra work h...
Add workaroudn to let blueprints work correctly
Add workaroudn to let blueprints work correctly
JavaScript
mit
yaymukund/ember-frontmatter-md,yaymukund/ember-frontmatter-md,yaymukund/ember-frontmatter-md
--- +++ @@ -1,5 +1,5 @@ module.exports = { - description: 'Creates an initializer to load posts from the meta tag.' + description: 'Creates an initializer to load posts from the meta tag.', // locals: function(options) { // // Return custom template variables here. @@ -11,4 +11,5 @@ // afterInstall: f...
5324f5540f3950fc0acc6ade82f6c1bb49683b13
webpack.config.js
webpack.config.js
/*global module, __dirname, require */ /** * @name webpack * @type {Object} * @property NoEmitOnErrorsPlugin */ /** * @name path * @property resolve */ var webpack = require('webpack'), path = require('path'); module.exports = { entry: { bundle: './src/index' }, output: { filename: 'js/[name].js',...
/*global module, __dirname, require */ /** * @name webpack * @type {Object} * @property NoEmitOnErrorsPlugin */ /** * @name path * @property resolve */ var webpack = require('webpack'), path = require('path'); module.exports = { entry: { bundle: './src/index' }, output: { filename: 'js/[name].js',...
Add alias for core directories, update devtool property
Add alias for core directories, update devtool property
JavaScript
mit
dashukin/react-redux-template,dashukin/react-redux-template
--- +++ @@ -37,5 +37,17 @@ }, plugins: [ new webpack.NoEmitOnErrorsPlugin() - ] + ], + devtool: '#cheap-module-eval-source-map', + resolve: { + alias: { + src: path.resolve(__dirname, 'src'), + components: path.resolve(__dirname, 'src/components'), + constants: path.resolve(__dirname, 'src/constants'), ...
a571ce2b1948bdf1e5c6bcb699a323dae3632b9e
webpack.config.js
webpack.config.js
const path = require('path'); const webpack = require('webpack'); module.exports = { entry: { app: path.resolve(__dirname, 'app/Resources/assets/js/app.js') }, output: { path: path.resolve(__dirname, 'web/builds'), filename: 'bundle.js', publicPath: '/builds/' }, mod...
const path = require('path'); const webpack = require('webpack'); module.exports = { entry: { app: path.resolve(__dirname, 'app/Resources/assets/js/app.js') }, output: { path: path.resolve(__dirname, 'web/builds'), filename: 'bundle.js', publicPath: '/builds/' }, mod...
Fix module not found error on moment
Fix module not found error on moment
JavaScript
mit
alOneh/sf-live-2017-symfony-webpack,alOneh/sf-live-2017-symfony-webpack,alOneh/sf-live-2017-symfony-webpack
--- +++ @@ -41,7 +41,8 @@ resolve: { alias: { fonts: path.resolve(__dirname, 'web/fonts'), - jquery: path.resolve(__dirname, 'app/Resources/assets/js/jquery-2.1.4.min.js') + jquery: path.resolve(__dirname, 'app/Resources/assets/js/jquery-2.1.4.min.js'), + mo...
4266ec9fc365160e2d8fa828cffbd84f759b1f70
mendel/angular/src/app/core/services/auth.service.js
mendel/angular/src/app/core/services/auth.service.js
(function() { 'use strict'; angular .module('static') .factory('AuthService', function ($http, apiHost, Session) { var authService = {}; authService.login = function login(credentials) { return $http .post(apiHost + '/login/', credentials) .then(function (res) ...
(function() { 'use strict'; angular .module('static') .factory('AuthService', function ($http, $httpParamSerializerJQLike, $state, $localStorage, apiHost, Session, toastr) { var authService = {}; authService.login = function login(credentials) { return $http({ method: '...
Create login/logout/getCurrentUser functions on AuthService
Create login/logout/getCurrentUser functions on AuthService
JavaScript
agpl-3.0
Architizer/mendel,Architizer/mendel,Architizer/mendel,Architizer/mendel
--- +++ @@ -3,22 +3,100 @@ angular .module('static') - .factory('AuthService', function ($http, apiHost, Session) { + .factory('AuthService', function ($http, $httpParamSerializerJQLike, $state, $localStorage, apiHost, Session, toastr) { var authService = {}; authService.login = f...
d8245ec2c355b0f3c2189ea26e68bcd690e6de84
generators/app/templates/authentication.js
generators/app/templates/authentication.js
'use strict'; const authentication = require('feathers-authentication'); <% for (var i = 0; i < authentication.length; i++) { %> const <%= S(authentication[i].name).capitalize().s %>Strategy = require('<%= authentication[i].strategy %>').Strategy;<% if (authentication[i].tokenStrategy) { %> const <%= S(authentication[...
'use strict'; const authentication = require('feathers-authentication'); <% for (var i = 0; i < authentication.length; i++) { %> const <%= S(authentication[i].name).capitalize().s %>Strategy = require('<%= authentication[i].strategy %>').Strategy;<% if (authentication[i].tokenStrategy) { %> const <%= S(authentication[...
Fix to support token based auth strategies
Fix to support token based auth strategies
JavaScript
mit
feathersjs/generator-feathers,gradealabs/generator-feathers,feathersjs/generator-feathers,feathersjs/generator-feathers
--- +++ @@ -3,7 +3,7 @@ const authentication = require('feathers-authentication'); <% for (var i = 0; i < authentication.length; i++) { %> const <%= S(authentication[i].name).capitalize().s %>Strategy = require('<%= authentication[i].strategy %>').Strategy;<% if (authentication[i].tokenStrategy) { %> -const <%= S(...
fa5739409f1007d73202b0b48b5cea0535a7b3cc
generators/app/templates/webpack.config.js
generators/app/templates/webpack.config.js
const config = require('hjs-webpack')({ in: 'src/index.js', out: 'dist', clearBeforeBuild: true, devServer: { stats: { colors: true, }, }, }) module.exports = config
const config = require('hjs-webpack')({ in: 'src/index.js', out: 'dist', clearBeforeBuild: true, devServer: { stats: { colors: true } } }) config.resolve.modulesDirectories = [ 'web_modules', 'node_modules', 'src', 'src/modules/' ] module.exports = config
Add more directories to be resolved from
Add more directories to be resolved from
JavaScript
mit
127labs/generator-duxedo,127labs/generator-duxedo
--- +++ @@ -4,9 +4,16 @@ clearBeforeBuild: true, devServer: { stats: { - colors: true, - }, - }, + colors: true + } + } }) +config.resolve.modulesDirectories = [ + 'web_modules', + 'node_modules', + 'src', + 'src/modules/' +] + module.exports = config
ee38458c93e43cdeaa4a3a7cb3541dd792755fef
lib/dialects/sqlite/connector-manager.js
lib/dialects/sqlite/connector-manager.js
var Utils = require("../../utils") , sqlite3 = require('sqlite3').verbose() , Query = require("./query") module.exports = (function() { var ConnectorManager = function(sequelize) { this.sequelize = sequelize this.database = new sqlite3.Database(sequelize.options.storage || ':memory:') this.opene...
var Utils = require("../../utils") , sqlite3 = require('sqlite3').verbose() , Query = require("./query") module.exports = (function() { var ConnectorManager = function(sequelize) { this.sequelize = sequelize this.database = db = new sqlite3.Database(sequelize.options.storage || ':memory:', function(...
Improve pragma handling for sqlite3
Improve pragma handling for sqlite3
JavaScript
mit
IrfanBaqui/sequelize
--- +++ @@ -5,22 +5,17 @@ module.exports = (function() { var ConnectorManager = function(sequelize) { this.sequelize = sequelize - this.database = new sqlite3.Database(sequelize.options.storage || ':memory:') - this.opened = false + this.database = db = new sqlite3.Database(sequelize.options.st...
9ea03c29ffc1dac7f04f094433c9e47c2ba1c5ad
topcube.js
topcube.js
var spawn = require('child_process').spawn; var path = require('path'); module.exports = function (options) { options = options || {}; options.url = options.url || 'http://nodejs.org'; options.name = options.name || 'nodejs'; var client; switch (process.platform) { case 'win32': client...
var spawn = require('child_process').spawn; var path = require('path'); module.exports = function (options) { options = options || {}; options.url = options.url || 'http://nodejs.org'; options.name = options.name || 'nodejs'; var client; switch (process.platform) { case 'win32': client...
Allow only name, url keys for win32.
Allow only name, url keys for win32.
JavaScript
mit
creationix/topcube,creationix/topcube,creationix/topcube
--- +++ @@ -21,7 +21,13 @@ } var args = []; - for (var key in options) args.push('--' + key + '=' + options[key]); + for (var key in options) { + // Omit keys besides name & url for now until options + // parsing bugs are resolved. + if (process.platform === 'win32' && + ...
6a4a3647799cfe79363c303054a57cb4e9cbb755
web/app.js
web/app.js
'use strict' const express = require('express') const dotenv = require('dotenv') const result = dotenv.config() if (result.error) dotenv.config({ path: '../.env' }) const app = express() const port = process.env.SITE_PORT app.use(express.static('public')) app.get('/', (req, res) => { res.sendFi...
'use strict' const express = require('express') const dotenv = require('dotenv') let result = dotenv.config() if (result.error) { result = dotenv.config({ path: '../.env' }) if (result.error) throw result.error } const app = express() const port = read_env_var("SITE_PORT") app.use(expres...
Add error message for undefined envvars
Site: Add error message for undefined envvars
JavaScript
agpl-3.0
SirRade/shootr,SirRade/shootr,SirRade/shootr,SirRade/shootr,SirRade/shootr
--- +++ @@ -3,14 +3,17 @@ const express = require('express') const dotenv = require('dotenv') -const result = dotenv.config() -if (result.error) - dotenv.config({ +let result = dotenv.config() +if (result.error) { + result = dotenv.config({ path: '../.env' }) + if (result.error) + th...
9087e7280b21eee2af68653c3b633349098910de
client/src/history.js
client/src/history.js
import createHistory from 'history/createBrowserHistory' import * as qs from 'querystring' import config from './config' const history = createHistory() const navigate = path => { history.push(config.basePath + path) } const getPathname = loc => { let path = '/' + (loc.pathname + loc.hash) path = path.replace...
import createHistory from 'history/createBrowserHistory' import * as qs from 'querystring' import config from './config' const history = createHistory() const navigate = path => { history.push(config.basePath + path) } const getPathname = loc => { let path = loc.pathname + loc.hash path = path.replace(new Re...
Fix router not resolving route in some cases
Fix router not resolving route in some cases
JavaScript
mit
daGrevis/msks,daGrevis/msks,daGrevis/msks
--- +++ @@ -10,15 +10,23 @@ } const getPathname = loc => { - let path = '/' + (loc.pathname + loc.hash) + let path = loc.pathname + loc.hash + path = path.replace(new RegExp(`^${config.basePath}`), '') + if (path[0] !== '/') { + path = '/' + path + } + path = path.replace(/\?.*/, '') + return path...
db7c7ff579eed7683195d4b03754655e9f7246ba
tests/test-helper.js
tests/test-helper.js
/* globals require */ import resolver from './helpers/resolver'; import loadEmberExam from 'ember-exam/test-support/load'; const framework = require.has('ember-qunit') ? 'qunit' : 'mocha'; const oppositeFramework = !require.has('ember-qunit') ? 'qunit' : 'mocha'; Object.keys(require.entries).forEach((entry) => { i...
/* globals require */ import resolver from './helpers/resolver'; import loadEmberExam from 'ember-exam/test-support/load'; const framework = require.has('ember-qunit') ? 'qunit' : 'mocha'; const oppositeFramework = !require.has('ember-qunit') ? 'qunit' : 'mocha'; Object.keys(require.entries).forEach((entry) => { i...
Remove a change in node version to have the change in a seperated pr
Remove a change in node version to have the change in a seperated pr
JavaScript
mit
trentmwillis/ember-exam,trentmwillis/ember-exam,trentmwillis/ember-scatter,trentmwillis/ember-scatter,trentmwillis/ember-exam
--- +++ @@ -19,7 +19,5 @@ if (framework === 'qunit') { // Use string literal to prevent Babel to transpile this into ES6 import // that would break when tests run with Mocha framework. - // In ember-qunit 3.4.0, this new check was added: https://github.com/emberjs/ember-qunit/commit/a7e93c4b4b535dae62fed992b4...
e537c60751c717e3963b4a93538b117a29b70a7c
tests/test_client.js
tests/test_client.js
'use strict'; /* TODO: GET client (all/specific/sortBy/pagination/search) POST client (ok/fail) PUT client DELETE client */ exports.get = function(assert, client) { return client.clients.get().then(function(res) { assert(res.data.length === 0, 'Failed to get clients as expected'); })....
'use strict'; /* TODO: GET client (all/specific/sortBy/pagination/search) POST client (ok/fail) PUT client DELETE client */ exports.get = function(assert, client) { return client.clients.get().then(function(res) { assert(res.data.length === 0, 'Failed to get clients as expected'); })....
Add stub for posting valid client
Add stub for posting valid client
JavaScript
mit
bebraw/react-crm-backend,koodilehto/koodilehto-crm-backend
--- +++ @@ -16,11 +16,20 @@ }); }; -exports.post = function(assert, client) { +exports.postInvalid = function(assert, client) { return client.clients.post().then(function() { assert(false, 'Posted client even though shouldn\'t'); }).catch(function() { assert(true, 'Failed to post c...
08f0a1e48c86d2878b6ea548f3b9090b0e17bc8f
truffle.js
truffle.js
module.exports = { migrations_directory: "./migrations", networks: { development: { host: "localhost", port: 8545, network_id: "*" }, live: { host: "localhost", port: 8546, network_id: 1, }, Ropsten: ...
module.exports = { migrations_directory: "./migrations", networks: { development: { host: "localhost", port: 8545, network_id: "*" }, live: { host: "localhost", port: 8546, network_id: 1, }, Ropsten: ...
Deploy to Kovan test network.
Deploy to Kovan test network.
JavaScript
mit
TripleSpeeder/StandingOrderDapp,TripleSpeeder/StandingOrderDapp
--- +++ @@ -17,9 +17,15 @@ network_id: 3, gasprice: 23000000000, // 23 gwei }, + Kovan: { + host: "localhost", + port: 8548, + network_id: 42, + gasprice: 23000000000, // 23 gwei + }, Rinkeby: { host: ...
bdcd0f382efcb77415813955bc0ca4e0ece4f8c6
src/Form/FormText.js
src/Form/FormText.js
import React from 'react'; import PropTypes from 'prop-types'; import cx from 'classnames'; const propTypes = { children: PropTypes.node.isRequired, className: PropTypes.string, }; const defaultProps = { className: null, }; function FormText({ children, className }) { const classes = cx('form-text', classNam...
import React from 'react'; import PropTypes from 'prop-types'; import cx from 'classnames'; const propTypes = { children: PropTypes.node.isRequired, variant: PropTypes.oneOf([ 'black', 'muted', 'primary', 'success', 'info', 'warning', 'danger', 'white', ]), className: PropTypes....
Add variant prop to form text component
Add variant prop to form text component
JavaScript
mit
ProAI/react-essentials
--- +++ @@ -4,15 +4,26 @@ const propTypes = { children: PropTypes.node.isRequired, + variant: PropTypes.oneOf([ + 'black', + 'muted', + 'primary', + 'success', + 'info', + 'warning', + 'danger', + 'white', + ]), className: PropTypes.string, }; const defaultProps = { + variant: ...
1d11599d6d881b7cbd4a96d50aa92566e38384d2
sort/insertion_sort.js
sort/insertion_sort.js
var insert = function(array, rightIndex, value) { for(var index = rightIndex; index >= 0 && array[index] > value; index--){ array[index + 1] = array[index]; } array[index + 1] = value; };
Add insert fxn to insertion sort
Add insert fxn to insertion sort
JavaScript
mit
aftaberski/algorithms,aftaberski/algorithms
--- +++ @@ -0,0 +1,8 @@ +var insert = function(array, rightIndex, value) { + for(var index = rightIndex; + index >= 0 && array[index] > value; + index--){ + array[index + 1] = array[index]; + } + array[index + 1] = value; +};
db4c7348e66753a969de4888e6c01608c1e49129
utils/convert.js
utils/convert.js
'use strict'; var _ = require('lodash'); var fs = require('fs'); var path = require('path'); var convert = { moduleToFolder: moduleToFolder, pathToModule: pathToModule }; function pathToModule(dir, entered) { var moduleName = _.camelCase(path.basename(dir)); var moduleFilename = moduleName + '.module.js'; v...
'use strict'; var _ = require('lodash'); var fs = require('fs'); var path = require('path'); var convert = { moduleToFolder: moduleToFolder, pathToModule: pathToModule }; function pathToModule(dir, entered) { var moduleName = _.camelCase(path.basename(dir)); var moduleFilename = path.basename(dir) + '.module....
Fix passing dashed module paths to generator
Fix passing dashed module paths to generator
JavaScript
mit
sysgarage/generator-sys-angular,sysgarage/generator-sys-angular
--- +++ @@ -10,7 +10,7 @@ function pathToModule(dir, entered) { var moduleName = _.camelCase(path.basename(dir)); - var moduleFilename = moduleName + '.module.js'; + var moduleFilename = path.basename(dir) + '.module.js'; var moduleFilePath = path.resolve(dir, moduleFilename); var prefix; try {
bef736ad7309b7a1e60b8d9935e546aced0c2531
addons/options/src/preview/index.js
addons/options/src/preview/index.js
import addons from '@storybook/addons'; import { EVENT_ID } from '../shared'; // init function will be executed once when the storybook loads for the // first time. This is a good place to add global listeners on channel. export function init() { // NOTE nothing to do here } function regExpStringify(exp) { if (ty...
import addons from '@storybook/addons'; import { EVENT_ID } from '../shared'; // init function will be executed once when the storybook loads for the // first time. This is a good place to add global listeners on channel. export function init() { // NOTE nothing to do here } function regExpStringify(exp) { if (ty...
Check if hierarchySeparator presents in the options object
Check if hierarchySeparator presents in the options object
JavaScript
mit
storybooks/storybook,kadirahq/react-storybook,rhalff/storybook,storybooks/react-storybook,rhalff/storybook,rhalff/storybook,rhalff/storybook,storybooks/storybook,kadirahq/react-storybook,storybooks/storybook,storybooks/storybook,storybooks/react-storybook,storybooks/react-storybook,storybooks/storybook,storybooks/story...
--- +++ @@ -22,10 +22,17 @@ 'Failed to find addon channel. This may be due to https://github.com/storybooks/storybook/issues/1192.' ); } - const options = { - ...newOptions, - hierarchySeparator: regExpStringify(newOptions.hierarchySeparator), - }; + + let options = newOptions; + + // since '...
5184b5963cd48452546d6ff1e0df518cd8473cdf
src/base/baseTool.js
src/base/baseTool.js
export default class { constructor (name) { this.name = name; this.mode = 'disabled'; this.element = undefined; // this.data = {}; this._options = {}; this._configuration = {}; } get configuration () { return this._configuration; } set configuration (configuration) { thi...
export default class { constructor (name, strategies, defaultStrategy) { this.name = name; this.mode = 'disabled'; this.element = undefined; // Todo: should this live in baseTool? this.strategies = strategies || {}; this.defaultStrategy = defaultStrategy || Object.keys(this.strategies)[...
Add a consistent way to set and apply strategies for tools
Add a consistent way to set and apply strategies for tools
JavaScript
mit
chafey/cornerstoneTools,cornerstonejs/cornerstoneTools,cornerstonejs/cornerstoneTools,cornerstonejs/cornerstoneTools
--- +++ @@ -1,8 +1,14 @@ export default class { - constructor (name) { + constructor (name, strategies, defaultStrategy) { this.name = name; this.mode = 'disabled'; this.element = undefined; + + // Todo: should this live in baseTool? + this.strategies = strategies || {}; + this.defaultStrat...
1b96576cea9138cb95e332a1d12e3a1e1887be56
app/components/students/students.js
app/components/students/students.js
'use strict'; angular.module('myApp.students', ['ngRoute']) .config(['$routeProvider', function($routeProvider) { $routeProvider.when('/students', { templateUrl: 'components/students/students.html', controller: 'StudentsCtrl' }); }]) .controller('StudentsCtrl', [function() { // $scope.master = {}; ...
'use strict'; angular.module('myApp.students', ['ngRoute']) .config(['$routeProvider', function($routeProvider) { $routeProvider.when('/students', { templateUrl: 'components/students/students.html', controller: 'StudentsCtrl' }); }]) .controller('StudentsCtrl', ['$scope', function($scope) { $scope.m...
Make the buttons do stuff
Make the buttons do stuff
JavaScript
mit
andrewalexander/hackpsu_registration,andrewalexander/hackpsu_registration,andrewalexander/hackpsu_registration,andrewalexander/hackpsu_registration
--- +++ @@ -9,16 +9,16 @@ }); }]) -.controller('StudentsCtrl', [function() { - // $scope.master = {}; +.controller('StudentsCtrl', ['$scope', function($scope) { + $scope.master = {}; - // $scope.update = function(user) { - // $scope.master = angular.copy(user); - // }; + $scope.update ...
a9ee91d3920d0fa876bd16f5e51a7bad2f29f818
app/native.js
app/native.js
// @flow import CodePush from 'react-native-code-push'; import { AppRegistry, YellowBox } from 'react-native'; import { SingleHotelStandalonePackage, NewHotelsStandAlonePackage, } from '@kiwicom/react-native-app-hotels'; // TODO: please check if it's still needed YellowBox.ignoreWarnings([ // react-native-share...
// @flow import CodePush from 'react-native-code-push'; import { AppRegistry, YellowBox } from 'react-native'; import { SingleHotelStandalonePackage, NewHotelsStandAlonePackage, } from '@kiwicom/react-native-app-hotels'; // TODO: please check if it's still needed YellowBox.ignoreWarnings([ // react-native-share...
Set code push install mode to immediate
Set code push install mode to immediate
JavaScript
mit
mrtnzlml/native,mrtnzlml/native
--- +++ @@ -27,4 +27,6 @@ ); // This file is only used for native integration and we use CodePush there -CodePush.sync(); +CodePush.sync({ + installMode: CodePush.InstallMode.IMMEDIATE, +});
d27ae97ff6e764ac9e40c4b03b91eab8a30d32cc
web/.eslintrc.js
web/.eslintrc.js
// https://eslint.org/docs/user-guide/configuring module.exports = { root: true, parserOptions: { parser: "babel-eslint", sourceType: "module" }, env: { browser: true }, // required to lint *.vue files plugins: ["vue"], extends: ["plugin:vue/recommended", "airbnb-base"], // check if impor...
// https://eslint.org/docs/user-guide/configuring module.exports = { root: true, parserOptions: { parser: "babel-eslint", sourceType: "module" }, env: { browser: true }, // required to lint *.vue files plugins: ["vue"], extends: ["plugin:vue/recommended", "airbnb-base"], // check if impor...
Disable i++ error in loops
Disable i++ error in loops
JavaScript
mit
homoluden/fukami,homoluden/fukami,homoluden/fukami
--- +++ @@ -44,6 +44,12 @@ ] } ], + "no-plusplus": [ + "error", + { + "allowForLoopAfterthoughts": true + } + ], // allow optionalDependencies "import/no-extraneous-dependencies": [ "error",
dd123262b95f39224b7851ceaaf785399c9de0c0
implementation.js
implementation.js
'use strict'; var bind = require('function-bind'); var ES = require('es-abstract/es7'); var slice = bind.call(Function.call, String.prototype.slice); module.exports = function padLeft(maxLength) { var O = ES.RequireObjectCoercible(this); var S = ES.ToString(O); var stringLength = ES.ToLength(S.length); var fillSt...
'use strict'; var bind = require('function-bind'); var ES = require('es-abstract/es7'); var slice = bind.call(Function.call, String.prototype.slice); module.exports = function padLeft(maxLength) { var O = ES.RequireObjectCoercible(this); var S = ES.ToString(O); var stringLength = ES.ToLength(S.length); var fillSt...
Update concatenation algorithm to prevent strings larger than the max length
Update concatenation algorithm to prevent strings larger than the max length From https://github.com/ljharb/proposal-string-pad-left-right/commit/7b6261b9a23cbc00daf0b232c1b40243adcce7d8
JavaScript
mit
ljharb/String.prototype.padLeft,ljharb/String.prototype.padStart,es-shims/String.prototype.padStart,es-shims/String.prototype.padLeft
--- +++ @@ -22,7 +22,9 @@ } var fillLen = intMaxLength - stringLength; while (F.length < fillLen) { - F += F; + var fLen = F.length; + var remainingCodeUnits = fillLen - fLen; + F += fLen > remainingCodeUnits ? slice(F, 0, remainingCodeUnits) : F; } var truncatedStringFiller = F.length > fillLen ? sli...
2fa060f4dd23a5074b788330c1a8464f79bdadef
routes/edit/screens/App/screens/Project/components/CodeEditor.js
routes/edit/screens/App/screens/Project/components/CodeEditor.js
import React, { Component } from 'react'; import AceEditor from 'react-ace'; import githubTheme from 'brace/theme/github'; import markdownSyntax from 'brace/mode/markdown'; import styles from './CodeEditor.styl'; export default ({ file, onCodeChange, onSave }) => { if (!file) return <div />; const onLoad = (edit...
import React, { Component } from 'react'; import AceEditor from 'react-ace'; import githubTheme from 'brace/theme/github'; import markdownSyntax from 'brace/mode/markdown'; import styles from './CodeEditor.styl'; export default ({ file, onCodeChange, onSave }) => { if (!file) return <div />; const onLoad = (edit...
Add support for save on Ctrl/Cmd+S
Add support for save on Ctrl/Cmd+S
JavaScript
mit
Literasee/literasee,Literasee/literasee
--- +++ @@ -11,7 +11,10 @@ const onLoad = (editor) => { editor.commands.addCommand({ name: 'saveChanges', - bindKey: {win: 'Ctrl-Enter', mac: 'Ctrl-Enter|Command-Enter'}, + bindKey: { + win: 'Ctrl-Enter|Ctrl-S', + mac: 'Ctrl-Enter|Command-Enter|Command-S' + }, exec:...
ec5f0a6ded1d50773cda52d32f22238bcb019d56
src/app/main/main.controller.js
src/app/main/main.controller.js
(function() { 'use strict'; angular .module('annualTimeBlock') .controller('MainController', MainController); /** @ngInject */ function MainController($timeout, webDevTec, toastr) { var vm = this; vm.awesomeThings = []; vm.classAnimation = ''; vm.creationDate = 1456885185987; vm.s...
(function() { 'use strict'; angular .module('annualTimeBlock') .controller('MainController', MainController); /** @ngInject */ function MainController() { var vm = this; } })();
Clear out unneeded MainController stuff
Clear out unneeded MainController stuff
JavaScript
mit
EdwardHinkle/annualTimeBlock,EdwardHinkle/annualTimeBlock
--- +++ @@ -6,34 +6,9 @@ .controller('MainController', MainController); /** @ngInject */ - function MainController($timeout, webDevTec, toastr) { + function MainController() { var vm = this; - vm.awesomeThings = []; - vm.classAnimation = ''; - vm.creationDate = 1456885185987; - vm.showT...
48c22bda06a7f6ea3592c942db50d7a4236f8605
LesionTracker/client/components/viewerMain/viewerMain.js
LesionTracker/client/components/viewerMain/viewerMain.js
Template.viewerMain.helpers({ 'toolbarOptions': function() { var toolbarOptions = {}; var buttonData = []; buttonData.push({ id: 'resetViewport', title: 'Reset Viewport', classes: 'imageViewerCommand', iconClasses: 'fa fa-undo' }); ...
Template.viewerMain.helpers({ 'toolbarOptions': function() { var toolbarOptions = {}; var buttonData = []; buttonData.push({ id: 'resetViewport', title: 'Reset Viewport', classes: 'imageViewerCommand', iconClasses: 'fa fa-undo' }); ...
Change icon for non-target tool and remove length tool
Change icon for non-target tool and remove length tool
JavaScript
mit
OHIF/Viewers,HorizonPlatform/Viewers,HorizonPlatform/Viewers,HorizonPlatform/Viewers,OHIF/Viewers,HorizonPlatform/Viewers,OHIF/Viewers
--- +++ @@ -40,15 +40,8 @@ }); buttonData.push({ - id: 'length', - title: 'Length Measurement', - classes: 'imageViewerTool', - iconClasses: 'fa fa-arrows-v' - }); - - buttonData.push({ id: 'lesion', - title: 'Lesion...
4d472a8c41acd461f1f75b9c0d9d8c65cfd4c4eb
client/tests/end2end/test-custodian-first-login.js
client/tests/end2end/test-custodian-first-login.js
var utils = require('./utils.js'); var temporary_password = "typ0drome@absurd.org"; describe('receiver first login', function() { it('should redirect to /firstlogin upon successful authentication', function() { utils.login_custodian('Custodian1', utils.vars['default_password'], '/#/custodian', true); }); i...
var utils = require('./utils.js'); var temporary_password = "typ0drome@absurd.org"; describe('receiver first login', function() { it('should redirect to /firstlogin upon successful authentication', function() { utils.login_custodian('Custodian1', utils.vars['default_password'], '/#/custodian', true); }); i...
Fix test of admin/custodian password change
Fix test of admin/custodian password change
JavaScript
agpl-3.0
vodkina/GlobaLeaks,vodkina/GlobaLeaks,vodkina/GlobaLeaks,vodkina/GlobaLeaks
--- +++ @@ -20,6 +20,7 @@ }); it('should be able to change password accessing the user preferences', function() { + element(by.cssContainingText("a", "Preferences")).click(); element(by.cssContainingText("a", "Password configuration")).click(); element(by.model('preferences.old_password')).sendKe...
5684a7a2746bce64504d3ee598c9403315d3211e
js/application.js
js/application.js
$(document).ready(function(){ $(".metronome-parameters").on("submit", function(event){ event.preventDefault(); var tempo = $("#tempo-field").val(); var beatsPerMeasure = $("#beats-field").val(); metronome = new Metronome(tempo, beatsPerMeasure); metronome.start(); }); })
$(document).ready(function(){ $(".metronome-parameters").on("submit", function(event){ event.preventDefault(); if ($('#metronome-button').val() === "Start"){ var tempo = $("#tempo-field").val(); var beatsPerMeasure = $("#beats-field").val(); metronome = new Metronome(tempo, beatsPerMeasure)...
Change submit event listener to start or stop
Change submit event listener to start or stop
JavaScript
mit
dmilburn/beatrice,dmilburn/beatrice
--- +++ @@ -2,9 +2,14 @@ $(".metronome-parameters").on("submit", function(event){ event.preventDefault(); - var tempo = $("#tempo-field").val(); - var beatsPerMeasure = $("#beats-field").val(); - metronome = new Metronome(tempo, beatsPerMeasure); - metronome.start(); + if ($('#metronome-butto...
552a0ff648af26ec23415abb24de858bb229e92e
src/components/Auth.js
src/components/Auth.js
import React from "react"; import { connect } from "react-redux"; import { push } from "react-router-redux"; import { parse } from "qs"; import { downloadJournal } from "../actionCreators"; class Auth extends React.Component { componentWillMount() { const accessToken = parse(this.props.location.hash.slice(1)).ac...
import React from "react"; import { connect } from "react-redux"; import { push } from "react-router-redux"; import { parse } from "qs"; import { downloadJournal } from "../actionCreators"; const getHash = () => this.props.location.hash.slice(1); const getAccessTokenFromHash = () => parse(getHash()).access_token; cla...
Split out logic to improve readability
Split out logic to improve readability
JavaScript
mit
captbaritone/markdown.today,captbaritone/markdown.today,captbaritone/markdown.today
--- +++ @@ -4,9 +4,12 @@ import { parse } from "qs"; import { downloadJournal } from "../actionCreators"; +const getHash = () => this.props.location.hash.slice(1); +const getAccessTokenFromHash = () => parse(getHash()).access_token; + class Auth extends React.Component { componentWillMount() { - const acce...
4dc0b40c4a6f54952cf7bfaa0492872539b88d40
src/controller.spec.js
src/controller.spec.js
import { ControllerProvider } from './controller'; const testModuleName = 'hot-reload-demo'; fdescribe('ControllerProvider', () => { describe('creating a controller through the provider', () => { var ctrl; beforeEach(function() { new ControllerProvider(testModuleName) .register('UnitTestCtrl'...
import { ControllerProvider } from './controller'; const testModuleName = 'hot-reload-demo'; describe('ControllerProvider', () => { describe('creating a controller through the provider', () => { const testCtrlName = 'UnitTestController', someValue = {}; // Some value to provide for the controller var...
Add a failing test for the ControllerProvider
Add a failing test for the ControllerProvider
JavaScript
mit
noppa/ng-hot-reload,noppa/ng-hot-reload,noppa/ng-hot-reload
--- +++ @@ -2,30 +2,51 @@ const testModuleName = 'hot-reload-demo'; -fdescribe('ControllerProvider', () => { +describe('ControllerProvider', () => { describe('creating a controller through the provider', () => { - var ctrl; + const testCtrlName = 'UnitTestController', + someValue = {}; // Some valu...
1ec3d3a1c7b8b664c7d5a0455e23e4185eb3bf23
lib/node-expat.js
lib/node-expat.js
var EventEmitter = require('events').EventEmitter; var util = require('util'); var expat = require('../build/default/node-expat'); /** * Simple wrapper because EventEmitter has turned pure-JS as of node * 0.5.x. */ exports.Parser = function(encoding) { this.parser = new expat.Parser(encoding); var that = t...
var EventEmitter = require('events').EventEmitter; var util = require('util'); var expat = require('../build/Release/node-expat'); /** * Simple wrapper because EventEmitter has turned pure-JS as of node * 0.5.x. */ exports.Parser = function(encoding) { this.parser = new expat.Parser(encoding); var that = t...
Fix for Node.js 0.6.0: Build seems to be now in Release instead of default
Fix for Node.js 0.6.0: Build seems to be now in Release instead of default
JavaScript
mit
node-xmpp/node-expat,Moharu/node-expat,noahjs/node-expat,Moharu/node-expat,noahjs/node-expat,julianduque/node-expat,noahjs/node-expat,node-xmpp/node-expat,julianduque/node-expat,node-xmpp/node-expat,julianduque/node-expat,Moharu/node-expat
--- +++ @@ -1,6 +1,6 @@ var EventEmitter = require('events').EventEmitter; var util = require('util'); -var expat = require('../build/default/node-expat'); +var expat = require('../build/Release/node-expat'); /** * Simple wrapper because EventEmitter has turned pure-JS as of node
2d5bd5583ed75904284b32b7ba4ff3294267315e
scripts/single-page.js
scripts/single-page.js
$(document).on('ready', function() { $('nav a').on('click', function(event) { event.preventDefault(); var targetURI = event.target.dataset.pagePartial; $.ajax({ cache: false, url: targetURI }).done(function(response) { $('main').html(response); }); }); $('a.blog-link').on('...
$(document).on('ready', function() { $('nav a').on('click', function(event) { event.preventDefault(); var targetURI = event.target.dataset.pagePartial; $.ajax({ cache: false, url: targetURI }).done(function(response) { $('main').html(response); }); }); $('a.blog-link').on('...
Update blog link click event to make ajax request
Update blog link click event to make ajax request
JavaScript
mit
RoyTuesday/RoyTuesday.github.io,peternatewood/peternatewood.github.io,peternatewood/peternatewood.github.io,peternatewood/peternatewood.github.io,RoyTuesday/RoyTuesday.github.io
--- +++ @@ -13,7 +13,16 @@ $('a.blog-link').on('click', function(event) { event.preventDefault(); - console.log("I'm a blog link!"); + var targetURI = event.target.dataset.pagePartial; + console.log("I'm a blog link!", targetURI); + $.ajax({ + cache: false, + url: targetURI + }).don...
fb67dd5793ba6163e66f325fa3adcb12c4fc8038
gulpfile.js
gulpfile.js
var stexDev = require("stex-dev"); var gulp = stexDev.gulp(); var plugins = stexDev.gulpPlugins(); var paths = stexDev.paths; // composite gulp tasks gulp.task('default', ['test']); gulp.task('dist', ['']); gulp.task('test', ['lint', 'mocha']); // gulp.task('db:setup', ['db:ensure-created', 'db:migrate'...
var Stex = require("stex"); var stexDev = require("stex-dev"); var gulp = stexDev.gulp(); var plugins = stexDev.gulpPlugins(); var paths = stexDev.paths; paths.root = __dirname; //HACK: can't think of a better way to expose the app root prior to stex init gulp.task('default', ['test']); gulp.task('dist', ...
Move app/db tasks into stex-dev
Move app/db tasks into stex-dev
JavaScript
isc
Payshare/stellar-wallet,stellar/stellar-wallet,stellar/stellar-wallet,Payshare/stellar-wallet
--- +++ @@ -1,57 +1,15 @@ +var Stex = require("stex"); var stexDev = require("stex-dev"); var gulp = stexDev.gulp(); var plugins = stexDev.gulpPlugins(); var paths = stexDev.paths; +paths.root = __dirname; //HACK: can't think of a better way to expose the app root prior to stex init -// composite gulp...
bb913af7a765a1092233c3b73970a800e8fd8dcc
client/app/components/JewelryProducts.js
client/app/components/JewelryProducts.js
import React from 'react'; class JewelryProducts extends React.Component { render() { return ( <h1>Jewelry Products</h1> ); } } export default JewelryProducts;
import React from 'react'; import 'whatwg-fetch'; import h from '../helpers.js'; class JewelryProducts extends React.Component { constructor() { super(); this.state = { pieces: [] }; } componentDidMount() { fetch('/a/pieces') .then(h.checkStatus) .then(h.parseJSON) .the...
Make an example for data fetching
Make an example for data fetching
JavaScript
mit
jfanderson/KIM,jfanderson/KIM
--- +++ @@ -1,9 +1,48 @@ import React from 'react'; +import 'whatwg-fetch'; + +import h from '../helpers.js'; class JewelryProducts extends React.Component { + constructor() { + super(); + + this.state = { + pieces: [] + }; + } + + componentDidMount() { + fetch('/a/pieces') + .then(h.chec...
cdcf48dc3afdb347303cec910a37cf7a34bd03db
client/app/controllers/boltController.js
client/app/controllers/boltController.js
angular.module('bolt.controller', []) .controller('BoltController', function($scope, $location, $window){ $scope.session = $window.localStorage; $scope.startRun = function() { if (document.getElementById("switch_3_left").checked) { $location.path('/run'); } else if (document.getElementById("switch_3_...
angular.module('bolt.controller', []) .controller('BoltController', function ($scope, $location, $window) { $scope.session = $window.localStorage; $scope.startRun = function () { if (document.getElementById("switch_3_left").checked) { $location.path('/run'); } else if (document.getElementById("switch...
Fix and ungodly number of linter errors
Fix and ungodly number of linter errors
JavaScript
mit
thomasRhoffmann/Bolt,elliotaplant/Bolt,gm758/Bolt,elliotaplant/Bolt,boisterousSplash/Bolt,boisterousSplash/Bolt,gm758/Bolt,thomasRhoffmann/Bolt
--- +++ @@ -1,8 +1,8 @@ angular.module('bolt.controller', []) -.controller('BoltController', function($scope, $location, $window){ +.controller('BoltController', function ($scope, $location, $window) { $scope.session = $window.localStorage; - $scope.startRun = function() { + $scope.startRun = function () { ...
1ee6d04bf95b1525aed47e964934b271a05f686a
gulpfile.js
gulpfile.js
const del = require('del') const { dest, series, src } = require('gulp') const { init: sourceMapsInit, write: sourceMapsWrite, } = require('gulp-sourcemaps') const { createProject } = require('gulp-typescript') const tsProject = createProject('tsconfig.json', { declaration: true, isolatedModules: false, jsx:...
const del = require('del') const { dest, series, src } = require('gulp') const { init: sourceMapsInit, write: sourceMapsWrite, } = require('gulp-sourcemaps') const { createProject } = require('gulp-typescript') const tsProject = createProject('tsconfig.json', { declaration: true, isolatedModules: false, noEm...
Revert to old compilation format except compile JSX
Revert to old compilation format except compile JSX
JavaScript
mit
IsaacLean/bolt-ui,IsaacLean/bolt-ui
--- +++ @@ -9,10 +9,7 @@ const tsProject = createProject('tsconfig.json', { declaration: true, isolatedModules: false, - jsx: 'react', - module: 'amd', noEmit: false, - resolveJsonModule: false, sourceMap: true, })
d3367ffe1f426b18b88aa0abe11aefbb7131278d
gulpfile.js
gulpfile.js
var gulp = require('gulp'); var elixir = require('laravel-elixir'); var argv = require('yargs').argv; var bin = require('./tasks/bin'); elixir.config.assetsPath = 'source/_assets'; elixir.config.publicPath = 'source'; elixir.config.sourcemaps = false; elixir(function(mix) { var env = argv.e || argv.env || 'local'...
process.env.DISABLE_NOTIFIER = true; var gulp = require('gulp'); var elixir = require('laravel-elixir'); var argv = require('yargs').argv; var bin = require('./tasks/bin'); elixir.config.assetsPath = 'source/_assets'; elixir.config.publicPath = 'source'; elixir.config.sourcemaps = false; elixir(function(mix) { v...
Disable Elixir and BrowserSync notifications
Disable Elixir and BrowserSync notifications
JavaScript
agpl-3.0
art-institute-of-chicago/gauguin-microsite,art-institute-of-chicago/gauguin-microsite,art-institute-of-chicago/gauguin-microsite
--- +++ @@ -1,3 +1,5 @@ +process.env.DISABLE_NOTIFIER = true; + var gulp = require('gulp'); var elixir = require('laravel-elixir'); var argv = require('yargs').argv; @@ -18,7 +20,9 @@ port: port, server: { baseDir: 'build_' + env }, proxy: null, - files: [ 'build_'...
9a9e537e01b410efbe5aae0429c60a1363f431e3
gulpfile.js
gulpfile.js
var gulp = require('gulp'); var fse = require('fs-extra'); gulp.task('clean', function(done) { fse.removeSync('dist'); fse.mkdirSync('dist'); done(); }); gulp.task('default', ['clean'], function() { return gulp .src('static/*') .pipe(gulp.dest('dist')); });
var gulp = require('gulp'); var fse = require('fs-extra'); gulp.task('clean', function(done) { fse.removeSync('dist'); fse.mkdirSync('dist'); done(); }); gulp.task('default', ['clean'], function() { return gulp .src(['static/*', 'node_modules/localforage/dist/localforage.min.js']) .pipe(gulp.dest('dis...
Copy the localForage library in dist/
Copy the localForage library in dist/
JavaScript
apache-2.0
zalun/mercurius,zalun/mercurius,marco-c/mercurius,marco-c/mercurius,marco-c/mercurius
--- +++ @@ -9,6 +9,6 @@ gulp.task('default', ['clean'], function() { return gulp - .src('static/*') + .src(['static/*', 'node_modules/localforage/dist/localforage.min.js']) .pipe(gulp.dest('dist')); });
fe3c32c0361a1b6779b8ee9830df88f13e5653ab
app/components/Tap.js
app/components/Tap.js
import React, { Component, PropTypes } from 'react' import { playAudio } from '../utils/audioplayer' export default class Tap extends Component { static PropTypes = { receivedTaps: PropTypes.object, users: PropTypes.object, } shouldComponentUpdate(nextProps, nextState) { console.log(this.props.rece...
import React, { Component, PropTypes } from 'react' import { playAudio } from '../utils/audioplayer' export default class Tap extends Component { static PropTypes = { receivedTaps: PropTypes.object, users: PropTypes.object, } shouldComponentUpdate(nextProps, nextState) { console.log(this.props.rece...
Set system notification sound to silent
Set system notification sound to silent
JavaScript
apache-2.0
hbierlee/digital-shoulder-tap,hbierlee/digital-shoulder-tap
--- +++ @@ -25,7 +25,7 @@ if (displayName) { const notificationText = `You received a tap from ${displayName}` - new Notification(notificationText) + new Notification(notificationText, {silent: true}) playAudio() console.log('ping') }
ce690f942c693ef3e8083b224153f624d58b7913
lib/system_config.js
lib/system_config.js
"format cjs"; var loader = require('@loader'); var isNode = typeof process === "object" && {}.toString.call(process) === "[object process]"; if(isNode) { exports.systemConfig = { meta: { 'jquery': { "format": "global", "exports": "jQuery", "deps": ["can/util/vdom/vdom"] } } }; } else { expo...
"format cjs"; var loader = require('@loader'); var isNode = typeof process === "object" && {}.toString.call(process) === "[object process]"; if(isNode) { exports.systemConfig = { map: { "can/util/vdom/vdom": "can/util/vdom/vdom" }, meta: { 'jquery': { "format": "global", "exports": "jQuery", ...
Make sure can/util/vdom can load
Make sure can/util/vdom can load The new version of Can now maps can/util/vdom/vdom to @empty by default, so if you are using an env other than server-development or server-production can-ssr can't load. To fix this we need to map can/util/vdom/vdom onto itself so that it definitely does load on the server no matt...
JavaScript
mit
donejs/done-ssr,donejs/done-ssr
--- +++ @@ -7,6 +7,9 @@ if(isNode) { exports.systemConfig = { + map: { + "can/util/vdom/vdom": "can/util/vdom/vdom" + }, meta: { 'jquery': { "format": "global",
ace61513a0b03b9409ccdceef288f3676a6476ac
lib/tokensManager.js
lib/tokensManager.js
const fs = require("fs"); const objectEquals = require("./objectEquals"); const { DEFAULT_TOKENS_FILENAME } = require("../lib/constants"); const tokensManager = function tokensManager (filename = DEFAULT_TOKENS_FILENAME) { const tokens = (function init () { try { return JSON.parse(fs.readFileSync(filena...
const fs = require("fs"); const objectEquals = require("./objectEquals"); const { DEFAULT_TOKENS_FILENAME } = require("../lib/constants"); const tokensManager = function tokensManager (filename = DEFAULT_TOKENS_FILENAME) { const tokens = (function init () { try { return JSON.parse(fs.readFileSync(filena...
Add EOL to tokens JSON file
Add EOL to tokens JSON file
JavaScript
mit
luispablo/tokenauth
--- +++ @@ -15,7 +15,7 @@ } })(); - const persistTokens = () => fs.writeFileSync(filename, JSON.stringify(tokens, null, 2), { encoding: "utf-8" }); + const persistTokens = () => fs.writeFileSync(filename, JSON.stringify(tokens, null, 2) + "\n", { encoding: "utf-8" }); const exists = function exists (...
df36577dd72440c7e581d304cf86d6edd036bed3
src/utils/detection.js
src/utils/detection.js
/** * Detect platform-specific things. */ goog.provide('onfire.utils.detection'); /** * @type {boolean} */ onfire.utils.detection.IS_NODEJS = (typeof module !== 'undefined' && !!module.exports);
/** * Detect platform-specific things. */ goog.provide('onfire.utils.detection'); /** * @type {boolean} */ onfire.utils.detection.IS_NODEJS = (typeof module !== 'undefined' && module !== this.module && !!module.exports);
Add additional test for Node environment
Add additional test for Node environment module !== this.module in Node, but this can be true in a browser
JavaScript
mit
isabo/onfire
--- +++ @@ -9,4 +9,5 @@ /** * @type {boolean} */ -onfire.utils.detection.IS_NODEJS = (typeof module !== 'undefined' && !!module.exports); +onfire.utils.detection.IS_NODEJS = + (typeof module !== 'undefined' && module !== this.module && !!module.exports);
b38008623b2d0cd3a9912481dcafe4fe37b22d3b
src/submit-button.js
src/submit-button.js
'use strict'; module.exports = function ($interpolate, $parse) { return { require: '^bdSubmit', restrict: 'A', compile: function (element, attributes) { if (!attributes.type) { attributes.$set('type', 'submit'); } return function (scope, element, attributes, controller) { ...
'use strict'; module.exports = function ($interpolate, $parse) { return { require: '^bdSubmit', restrict: 'A', compile: function (element, attributes) { if (!attributes.type) { attributes.$set('type', 'submit'); } return function (scope, element, attributes, controller) { ...
Use a watch function instead of adding submission to scope
Use a watch function instead of adding submission to scope
JavaScript
mit
bendrucker/angular-form-state
--- +++ @@ -10,11 +10,12 @@ } return function (scope, element, attributes, controller) { var original = element.text(); - scope.submission = controller; function ngDisabled () { return attributes.ngDisabled && !!$parse(attributes.ngDisabled)(scope); } - ...
d2adb620304c51e85903f97d9015ac2e6ce340fb
app/controllers/application.js
app/controllers/application.js
import Ember from 'ember'; export default Ember.Controller.extend({ session: Ember.inject.service(), actions: { invalidateSession () { this.get('session').invalidate(); }, login () { const lockOptions = { autoclose: true, icon: 'https://s3-us-west-1.amazonaws.com/barberscore...
import Ember from 'ember'; export default Ember.Controller.extend({ session: Ember.inject.service(), actions: { invalidateSession () { this.get('session').invalidate(); }, login () { const lockOptions = { autoclose: true, icon: 'https://s3-us-west-1.amazonaws.com/barberscore...
Update notice for email sent
Update notice for email sent
JavaScript
bsd-2-clause
barberscore/barberscore-web,barberscore/barberscore-web,barberscore/barberscore-web
--- +++ @@ -22,7 +22,7 @@ footerText: "(If you aren't currently registered with the BHS, or can't remember your email, please contact <a href='mailto:support@barberscore.com'>support@barberscore.com</a> for assistance.)" }, emailSent: { - success: "We sent an email to <b...
b2eff2b6ba5ea37838a2111f0dc109c56a6b6d09
app/javascript/components/cloud-tenant-form/create-form.schema.js
app/javascript/components/cloud-tenant-form/create-form.schema.js
/** * @param {Boolean} renderEmsChoices * @param {Object} emsChoices */ function createSchema(renderEmsChoices, emsChoices) { let fields = [{ component: 'text-field', name: 'name', validate: [{ type: 'required-validator', }], label: __('Tenant Name'), maxLength: 128, validateOnMou...
import { componentTypes, validatorTypes } from '@@ddf'; /** * @param {Boolean} renderEmsChoices * @param {Object} emsChoices */ function createSchema(renderEmsChoices, emsChoices) { let fields = [{ component: componentTypes.TEXT_FIELD, name: 'name', validate: [{ type: validatorTypes.REQUIRED, ...
Use constants for component/validator types in cloud tenant form
Use constants for component/validator types in cloud tenant form
JavaScript
apache-2.0
ManageIQ/manageiq-ui-classic,ManageIQ/manageiq-ui-classic,ManageIQ/manageiq-ui-classic,ManageIQ/manageiq-ui-classic
--- +++ @@ -1,13 +1,15 @@ +import { componentTypes, validatorTypes } from '@@ddf'; + /** * @param {Boolean} renderEmsChoices * @param {Object} emsChoices */ function createSchema(renderEmsChoices, emsChoices) { let fields = [{ - component: 'text-field', + component: componentTypes.TEXT_FIELD, na...
cbcc919782649d8bcfd7e86e86a20a82fc4dd109
src/utils/animate.js
src/utils/animate.js
function easing(time) { return 1 - (--time) * time * time * time; }; /** * Given a start/end point of a scroll and time elapsed, calculate the scroll position we should be at * @param {Number} start - the initial value * @param {Number} stop - the final desired value * @param {Number} elapsed - the amount of tim...
function easing(time) { return 1 - (--time) * time * time * time; }; /** * Given a start/end point of a scroll and time elapsed, calculate the scroll position we should be at * @param {Number} start - the initial value * @param {Number} stop - the final desired value * @param {Number} elapsed - the amount of tim...
Use performance.now instead of Date.now
Use performance.now instead of Date.now
JavaScript
mit
clauderic/react-infinite-calendar
--- +++ @@ -29,10 +29,10 @@ onComplete, duration = 600, }) { - const startTime = Date.now(); + const startTime = performance.now(); const tick = () => { - const elapsed = Date.now() - startTime; + const elapsed = performance.now() - startTime; window.requestAnimationFrame(() => onUpdate( ...
df075c083b7541c32666fc71549465d97ca20c21
jobs/projects/create.js
jobs/projects/create.js
const models = require('../../models'); let Project = models.projects; module.exports = function(connection, done) { connection.createChannel(function(err, ch) { console.log(err); var ex = 'chiepherd.main'; ch.assertExchange(ex, 'topic'); ch.assertQueue('chiepherd.project.create', { exclusive: false ...
const models = require('../../models'); let Project = models.projects; module.exports = function(connection, done) { connection.createChannel(function(err, ch) { console.log(err); var ex = 'chiepherd.main'; ch.assertExchange(ex, 'topic'); ch.assertQueue('chiepherd.project.create', { exclusive: false ...
Send message to other API
Send message to other API
JavaScript
mit
CHIEPHERD/chiepherd_api,CHIEPHERD/chiepherd_api,CHIEPHERD/chiepherd_api
--- +++ @@ -23,6 +23,11 @@ ch.sendToQueue(msg.properties.replyTo, new Buffer.from(JSON.stringify(project)), { correlationId: msg.properties.correlationId }); + connection.createChannel(function(error, channel) { + var ex = 'chiepherd.project.created'; + ...
1aca5fcc9668cc9eeec2750acf4ebd1e850a1d1c
packages/react-jsx-highmaps/src/index.js
packages/react-jsx-highmaps/src/index.js
import { withSeriesType } from 'react-jsx-highcharts'; export { Chart, Credits, Debug, Loading, Legend, Series, Subtitle, Title, Tooltip, HighchartsContext, HighchartsChartContext, HighchartsAxisContext, HighchartsSeriesContext, provideHighcharts, provideChart, provideAxis, provideSeri...
import { withSeriesType } from 'react-jsx-highcharts'; export { Chart, Credits, Debug, Loading, Legend, Series, Subtitle, Title, Tooltip, HighchartsContext, HighchartsChartContext, HighchartsAxisContext, HighchartsSeriesContext, withHighcharts as withHighmaps, withSeriesType } from 'react-...
Remove missing exports from react-jsx-highmaps
Remove missing exports from react-jsx-highmaps
JavaScript
mit
whawker/react-jsx-highcharts,whawker/react-jsx-highcharts
--- +++ @@ -13,10 +13,6 @@ HighchartsChartContext, HighchartsAxisContext, HighchartsSeriesContext, - provideHighcharts, - provideChart, - provideAxis, - provideSeries, withHighcharts as withHighmaps, withSeriesType } from 'react-jsx-highcharts';
0ccd1659f8e5b4999191cf1a8a1cd1960517c46c
client/app/js/core/view-switcher.js
client/app/js/core/view-switcher.js
import Model from '../base/model'; export default class ViewSwitcher { constructor(app, element) { this.app = app; this.element = element; this.currentView = null; } switchView(ViewClass, args) { if (this.currentView instanceof ViewClass) { this.currentView.model.replace(args); ret...
import Model from '../base/model'; export default class ViewSwitcher { constructor(app, element) { this.app = app; this.element = element; this.currentView = null; } switchView(ViewClass, args) { if (this.currentView instanceof ViewClass) { this.currentView.model.replace(args); ret...
Append view's element after rendering
Append view's element after rendering This makes no difference, but seem more logical
JavaScript
mit
despawnerer/theatrics,despawnerer/theatrics,despawnerer/theatrics
--- +++ @@ -22,8 +22,9 @@ const model = new Model(args); const view = new ViewClass({app: this.app, model: model}); - this.element.appendChild(view.element) view.render(); + + this.element.appendChild(view.element); this.currentView = view; }
11a15c61e4e9ad0f4c5efe4c56bc308e37006198
lib/configure_loader.js
lib/configure_loader.js
var pkg = require("../package.json"); global.navigator = global.navigator || { userAgent: "Mozilla/5.0 " + "done-ssr/" + pkg.version }; module.exports = function(loader){ // Ensure the extension loads before the main. var loaderImport = loader.import; loader.import = function(name){ if(name === loader.main) { ...
var pkg = require("../package.json"); global.navigator = global.navigator || { userAgent: "Mozilla/5.0 " + "done-ssr/" + pkg.version }; module.exports = function(loader){ // Ensure the extension loads before the main. var loaderImport = loader.import; loader.import = function(name){ if(name === loader.main) { ...
Set renderingBaseURL on the loader
Set renderingBaseURL on the loader
JavaScript
mit
donejs/done-ssr,donejs/done-ssr
--- +++ @@ -19,7 +19,8 @@ if(baseURL.indexOf("file:") === 0) { baseURL = "/"; } - loader.renderingLoader.baseURL = baseURL; + loader.renderingLoader.baseURL = + loader.renderingBaseURL = baseURL; } return loaderImport.apply(loader, args);
e9ff9befd71167f2fe17045e8c370c70ca97b61e
js/store.js
js/store.js
import { createStore, applyMiddleware } from "redux"; import thunk from "redux-thunk"; import { composeWithDevTools } from "redux-devtools-extension"; import reducer from "./reducers"; import mediaMiddleware from "./mediaMiddleware"; import { merge } from "./utils"; import { UPDATE_TIME_ELAPSED, STEP_MARQUEE } from "./...
import { createStore, applyMiddleware } from "redux"; import thunk from "redux-thunk"; import { composeWithDevTools } from "redux-devtools-extension"; import reducer from "./reducers"; import mediaMiddleware from "./mediaMiddleware"; import { merge } from "./utils"; import { UPDATE_TIME_ELAPSED, STEP_MARQUEE } from "./...
Fix webamp.onTrackDidChange, by actually passing the action to the event emitter
Fix webamp.onTrackDidChange, by actually passing the action to the event emitter
JavaScript
mit
captbaritone/winamp2-js,captbaritone/winamp2-js,captbaritone/winamp2-js
--- +++ @@ -26,7 +26,7 @@ // eslint-disable-next-line no-unused-vars const emitterMiddleware = store => next => action => { - actionEmitter.trigger(action.type); + actionEmitter.trigger(action.type, action); return next(action); };
35a42f3873ae041e59952888ce4282a3163debe5
app/main/autoupdater.js
app/main/autoupdater.js
'use strict'; const {app, dialog} = require('electron'); const {autoUpdater} = require('electron-updater'); function appUpdater() { // Log whats happening const log = require('electron-log'); log.transports.file.level = 'info'; autoUpdater.logger = log; autoUpdater.allowPrerelease = false; // Ask the user if up...
'use strict'; const {app, dialog} = require('electron'); const {autoUpdater} = require('electron-updater'); const ConfigUtil = require('./../renderer/js/utils/config-util.js'); function appUpdater() { // Log whats happening const log = require('electron-log'); log.transports.file.level = 'info'; autoUpdater.logge...
Allow auto update for prerelease based on betaupdates setting
Allow auto update for prerelease based on betaupdates setting
JavaScript
apache-2.0
zulip/zulip-electron,zulip/zulip-desktop,zulip/zulip-desktop,zulip/zulip-desktop,zulip/zulip-electron,zulip/zulip-desktop,zulip/zulip-electron
--- +++ @@ -1,13 +1,15 @@ 'use strict'; const {app, dialog} = require('electron'); const {autoUpdater} = require('electron-updater'); + +const ConfigUtil = require('./../renderer/js/utils/config-util.js'); function appUpdater() { // Log whats happening const log = require('electron-log'); log.transports.f...
3b81a97838b7c176ad0ae1c3c0e4323780446a39
components/loadingBar/LoadingBar.js
components/loadingBar/LoadingBar.js
import React, { PureComponent } from 'react'; class LoadingBar extends PureComponent { render() { return null; } } export default LoadingBar;
import React, { PureComponent } from 'react'; class LoadingBar extends PureComponent { render() { return ( <svg version="1.1" xmlns="http://www.w3.org/2000/svg"> <rect /> </svg> ); } } export default LoadingBar;
Create SVG containing a rectangle as SVG is performance wise the best option for animation
Create SVG containing a rectangle as SVG is performance wise the best option for animation
JavaScript
mit
teamleadercrm/teamleader-ui
--- +++ @@ -2,7 +2,11 @@ class LoadingBar extends PureComponent { render() { - return null; + return ( + <svg version="1.1" xmlns="http://www.w3.org/2000/svg"> + <rect /> + </svg> + ); } }
f6b974940964241d0980b15efb3f030452c70c82
ext/open_ZIP.js
ext/open_ZIP.js
define(function() { 'use strict'; function open(item) { console.log(item); } return open; });
define(['msdos/util'], function(dosUtil) { 'use strict'; function open() { this.addExplorer(function(expedition) { var pos = 0; function onLocalFileHeader(bytes) { var localFile = new LocalFileHeaderView(bytes.buffer, bytes.byteOffset, bytes.byteLength); if (!localFile.hasValidSi...
Add some fields to local file header
Add some fields to local file header
JavaScript
mit
radishengine/drowsy,radishengine/drowsy
--- +++ @@ -1,10 +1,63 @@ -define(function() { +define(['msdos/util'], function(dosUtil) { 'use strict'; - function open(item) { - console.log(item); + function open() { + this.addExplorer(function(expedition) { + var pos = 0; + function onLocalFileHeader(bytes) { + var localFile = n...
710f79a9aba647161fca92d79af554d412fa25e8
snippets/action-search/search-action.js
snippets/action-search/search-action.js
var page = tabris.create("Page", { title: "Actions", topLevel: true }); var proposals = ["baseball", "batman", "battleship", "bangkok", "bangladesh", "banana"]; var textView = tabris.create("TextView", { layoutData: {centerX: 0, centerY: 0} }).appendTo(page); var action = tabris.create("SearchAction", { titl...
var page = tabris.create("Page", { title: "Actions", topLevel: true }); var proposals = ["baseball", "batman", "battleship", "bangkok", "bangladesh", "banana"]; var searchBox = tabris.create("Composite", { layoutData: {centerX: 0, centerY: 0} }).appendTo(page); var textView = tabris.create("TextView").appendTo...
Fix search action snippet layout
Fix search action snippet layout "Selected '...'" text was behind the button as both were centered horizontally and vertically on the screen. Wrap them in a centered container instead. Change-Id: I71ee80f5b7ba00cdb3cbf279c8fd1a413746ef28
JavaScript
bsd-3-clause
eclipsesource/tabris-js,eclipsesource/tabris-js,eclipsesource/tabris-js
--- +++ @@ -5,9 +5,11 @@ var proposals = ["baseball", "batman", "battleship", "bangkok", "bangladesh", "banana"]; -var textView = tabris.create("TextView", { +var searchBox = tabris.create("Composite", { layoutData: {centerX: 0, centerY: 0} }).appendTo(page); + +var textView = tabris.create("TextView").appen...
72b64f7e83fdfb1a20311b86e271359529dc4abf
sencha-workspace/SlateAdmin/app/view/progress/interims/Manager.js
sencha-workspace/SlateAdmin/app/view/progress/interims/Manager.js
Ext.define('SlateAdmin.view.progress.interims.Manager', { extend: 'Ext.Container', xtype: 'progress-interims-manager', requires: [ 'SlateAdmin.view.progress.interims.SectionsGrid', 'SlateAdmin.view.progress.interims.StudentsGrid', 'SlateAdmin.view.progress.interims.EditorForm' ],...
Ext.define('SlateAdmin.view.progress.interims.Manager', { extend: 'Ext.Container', xtype: 'progress-interims-manager', requires: [ 'SlateAdmin.view.progress.interims.SectionsGrid', 'SlateAdmin.view.progress.interims.StudentsGrid', 'SlateAdmin.view.progress.interims.EditorForm', ...
Add section notes form to interims manager
Add section notes form to interims manager
JavaScript
mit
SlateFoundation/slate-admin,SlateFoundation/slate,SlateFoundation/slate,SlateFoundation/slate-admin,SlateFoundation/slate-admin,SlateFoundation/slate,SlateFoundation/slate-admin,SlateFoundation/slate,SlateFoundation/slate-admin,SlateFoundation/slate
--- +++ @@ -4,7 +4,8 @@ requires: [ 'SlateAdmin.view.progress.interims.SectionsGrid', 'SlateAdmin.view.progress.interims.StudentsGrid', - 'SlateAdmin.view.progress.interims.EditorForm' + 'SlateAdmin.view.progress.interims.EditorForm', + 'SlateAdmin.view.progress.SectionNote...
df3a6e16525e2764ea018a48bc178ff75c0bb467
test/spec/element/value.spec.js
test/spec/element/value.spec.js
describe("value", function() { "use strict"; var div, input; beforeEach(function() { div = DOM.create("div>a+a"); input = DOM.create("input[value=foo]"); }); it("should replace child element(s) from node with provided element", function() { expect(div[0].childNodes.length).toBe(2); expect(d...
describe("value", function() { "use strict"; var div, input; beforeEach(function() { div = DOM.create("div>a+a"); input = DOM.create("input[value=foo]"); }); it("should replace child element(s) from node with provided element", function() { expect(div[0].childNodes.length).toBe(2); expect(d...
Add failing test case regarding input.value($Element)
Add failing test case regarding input.value($Element)
JavaScript
mit
suenot/better-dom,suenot/better-dom,chemerisuk/better-dom,chemerisuk/better-dom
--- +++ @@ -24,5 +24,11 @@ expect(input[0].value).toBe("bar"); }); + it("should set value of text input to string value of provided element", function () { + expect(input.value(DOM.create("div"))).toBe(input); + expect(input[0].value).toBe("<div>"); + expect(input[0].childNodes.length).toBe(0); + ...
5206759e482853b788126022ef4682958dccec30
lib/fs/copy.js
lib/fs/copy.js
// Copy file // Credit: Isaac Schlueter // http://groups.google.com/group/nodejs/msg/ef4de0b516f7d5b8 'use strict'; var util = require('util') , fs = require('fs'); module.exports = function (source, dest, cb) { fs.lstat(source, function (err, stats) { var read; if (err) { cb(err); return; } try {...
// Copy file // Credit: Isaac Schlueter // http://groups.google.com/group/nodejs/msg/ef4de0b516f7d5b8 'use strict'; var util = require('util') , fs = require('fs') , stat = fs.stat, createReadStream = fs.createReadStream , createWriteStream = fs.createWriteStream module.exports = function (source, dest, cb)...
Use pipe instead util.pump for file streaming
Use pipe instead util.pump for file streaming
JavaScript
mit
medikoo/node-ext
--- +++ @@ -5,18 +5,23 @@ 'use strict'; var util = require('util') - , fs = require('fs'); + , fs = require('fs') + + , stat = fs.stat, createReadStream = fs.createReadStream + , createWriteStream = fs.createWriteStream module.exports = function (source, dest, cb) { - fs.lstat(source, function (err, st...
449e510f861f56ed673613d8102f6b1a3e680ced
lib/default-encoding.js
lib/default-encoding.js
var defaultEncoding /* istanbul ignore next */ if (process.browser) { defaultEncoding = 'utf-8' } else if (process.version) { var pVersionMajor = parseInt(process.version.split('.')[0].slice(1), 10) defaultEncoding = pVersionMajor >= 6 ? 'utf-8' : 'binary' } else { defaultEncoding = 'utf-8' } module.exports = ...
var defaultEncoding /* istanbul ignore next */ if (global.process && global.process.browser) { defaultEncoding = 'utf-8' } else if (global.process && global.process.version) { var pVersionMajor = parseInt(process.version.split('.')[0].slice(1), 10) defaultEncoding = pVersionMajor >= 6 ? 'utf-8' : 'binary' } else...
Check for process before accessing
Check for process before accessing
JavaScript
mit
crypto-browserify/pbkdf2,crypto-browserify/pbkdf2
--- +++ @@ -1,8 +1,8 @@ var defaultEncoding /* istanbul ignore next */ -if (process.browser) { +if (global.process && global.process.browser) { defaultEncoding = 'utf-8' -} else if (process.version) { +} else if (global.process && global.process.version) { var pVersionMajor = parseInt(process.version.split('....
283cce3b70e3a71279bbc805c973fd5d6e8b0aa2
test/support/config.js
test/support/config.js
var _ = require('underscore'); module.exports = function(opts) { var config = { redis_pool: { max: 10, idleTimeoutMillis: 1, reapIntervalMillis: 1, port: 6336 } } _.extend(config, opts || {}); return config; }();
var _ = require('underscore'); module.exports = function(opts) { var config = { redis_pool: { max: 10, idleTimeoutMillis: 1, reapIntervalMillis: 1, port: 6337 } } _.extend(config, opts || {}); return config; }();
Use port 6337 for the test redis server
Use port 6337 for the test redis server
JavaScript
bsd-3-clause
CartoDB/node-redis-mpool
--- +++ @@ -7,7 +7,7 @@ max: 10, idleTimeoutMillis: 1, reapIntervalMillis: 1, - port: 6336 + port: 6337 } }
40f242103e201c0c8c2cb94d3b0b74d259ec52ef
examples/jsx-seconds-elapsed/src/main.js
examples/jsx-seconds-elapsed/src/main.js
/** @jsx hJSX */ import {run, Rx} from '@cycle/core'; import {makeDOMDriver, hJSX} from '@cycle/dom'; function main(drivers) { let secondsElapsed$ = Rx.Observable.interval(1000) .map(i => i + 1) .startWith(0); let vtree$ = secondsElapsed$.map(secondsElapsed => <div>{`Seconds elapsed ${secondsElapsed}`}...
/** @jsx hJSX */ import {run, Rx} from '@cycle/core'; import {makeDOMDriver, hJSX} from '@cycle/dom'; function main(drivers) { let secondsElapsed$ = Rx.Observable.interval(1000) .map(i => i + 1) .startWith(0); let vtree$ = secondsElapsed$.map(secondsElapsed => <div>Seconds elapsed {secondsElapsed}</div...
Improve code style in jsx-seconds-elapsed example
Improve code style in jsx-seconds-elapsed example
JavaScript
mit
cyclejs/cyclejs,usm4n/cyclejs,maskinoshita/cyclejs,ntilwalli/cyclejs,feliciousx-open-source/cyclejs,usm4n/cyclejs,ntilwalli/cyclejs,staltz/cycle,ntilwalli/cyclejs,maskinoshita/cyclejs,usm4n/cyclejs,cyclejs/cyclejs,feliciousx-open-source/cyclejs,maskinoshita/cyclejs,cyclejs/cycle-core,maskinoshita/cyclejs,cyclejs/cyclej...
--- +++ @@ -7,7 +7,7 @@ .map(i => i + 1) .startWith(0); let vtree$ = secondsElapsed$.map(secondsElapsed => - <div>{`Seconds elapsed ${secondsElapsed}`}</div> + <div>Seconds elapsed {secondsElapsed}</div> ); return {DOM: vtree$}; }
40403c636b6ca29e01dff10b0e761389c8f07468
app/scripts/app.js
app/scripts/app.js
/*global angular */ /*jslint browser: true */ (function () { 'use strict'; var app; app = angular.module('thin.gsApp', ['ngRoute', 'ngSanitize', 'alerts', 'auth']) .config(['$routeProvider', '$locationProvider', function ($routeProvider, $locationProvider) { $routeProvi...
/*global angular */ /*jslint browser: true */ (function () { 'use strict'; var app; app = angular.module('thin.gsApp', ['ngRoute', 'ngSanitize', 'alerts', 'auth']) .config(['$routeProvider', '$locationProvider', function ($routeProvider, $locationProvider) { $routeProvi...
Rename the Facebook service to userService
Rename the Facebook service to userService Signed-off-by: Henrique Vicente <d390f26e2f50ad5716a9c69c58de1f5df9730e3b@gmail.com>
JavaScript
mit
henvic/thin.gs
--- +++ @@ -21,8 +21,8 @@ $locationProvider.hashPrefix('!'); }]); - app.run(function ($rootScope, Facebook, alert) { - $rootScope.Facebook = Facebook; + app.run(function ($rootScope, userService, alert) { + $rootScope.userService = userService; }); }());
c270660572ec7a79c110b65622c4d14aad0c117b
meteor/server/server.js
meteor/server/server.js
//TODO setup deploySettings.json Meteor.startup(function () { var githubServiceSetup = Accounts.loginServiceConfiguration.find({service: "github"}).count() === 1; if (githubServiceSetup) { //setup authentication Provider Accounts.loginServiceConfiguration.remove({ service: "github" ...
Meteor.startup(function () { var githubServiceSetup = Accounts.loginServiceConfiguration.find({service: "github"}).count() === 1; if (!githubServiceSetup) { //setup authentication Provider Accounts.loginServiceConfiguration.remove({ service: "github" }); Accounts.log...
Fix mistake where not adding github info when needed
Fix mistake where not adding github info when needed
JavaScript
agpl-3.0
codebounty/codebounty
--- +++ @@ -1,7 +1,6 @@ -//TODO setup deploySettings.json Meteor.startup(function () { var githubServiceSetup = Accounts.loginServiceConfiguration.find({service: "github"}).count() === 1; - if (githubServiceSetup) { + if (!githubServiceSetup) { //setup authentication Provider Accounts.lo...
c3d2b30dc74391b221665849f2a32fb4c6f0ad30
proxy/server.js
proxy/server.js
var proxy = require('redbird')({port: 8080}); proxy.register('localhost/event/api/user', "http://localhost:3001/user");
var proxy = require('redbird')({port: 8080}); proxy.register('localhost/event', 'http://localhost:3000'); proxy.register('localhost/event/api/user', 'http://localhost:3001/user'); proxy.register('localhost/event/api/session', 'http://localhost:3002/session'); proxy.register('localhost/event/api/file', ...
Add API and frontend routes
Add API and frontend routes
JavaScript
mit
haimich/event,haimich/event,haimich/event
--- +++ @@ -1,3 +1,6 @@ var proxy = require('redbird')({port: 8080}); -proxy.register('localhost/event/api/user', "http://localhost:3001/user"); +proxy.register('localhost/event', 'http://localhost:3000'); +proxy.register('localhost/event/api/user', 'http://localhost:3001/user'); +proxy.register('lo...
cbacc31ddebbd2b7c8d3a809d55739ccfca962a6
tools/tool-env/install-babel.js
tools/tool-env/install-babel.js
// This file exists because it is the file in the tool that is not automatically // transpiled by Babel "use strict"; function babelRegister() { const meteorBabel = require("meteor-babel"); const path = require("path"); const toolsPath = path.dirname(__dirname); const meteorPath = path.dirname(toolsPath); c...
// This file exists because it is the file in the tool that is not automatically // transpiled by Babel "use strict"; function babelRegister() { const meteorBabel = require("meteor-babel"); const path = require("path"); const toolsPath = path.dirname(__dirname); const meteorPath = path.dirname(toolsPath); c...
Fix inline source maps in meteor/tools code.
Fix inline source maps in meteor/tools code.
JavaScript
mit
Hansoft/meteor,Hansoft/meteor,Hansoft/meteor,Hansoft/meteor,Hansoft/meteor,Hansoft/meteor,Hansoft/meteor
--- +++ @@ -13,6 +13,10 @@ nodeMajorVersion: parseInt(process.versions.node) }); + // Make sure that source maps are included in the generated code for + // meteor/tools modules. + babelOptions.sourceMap = "inline"; + meteorBabel.setCacheDir(cacheDir); require('meteor-babel/register')
754071878da574b3912710d7ea2a681bcc2a74bb
src/components/MenuScreen/MenuScreen.js
src/components/MenuScreen/MenuScreen.js
import React from "react"; import Container from "./Container.js"; import Button from "./../Shared/Button.js"; import setCurrentScreenAction from "../../actions/ScreenActions.js"; import { GAME_SCREEN } from "../../actions/ScreenActions.js"; const screenTitle = "Tic Tac Toe React"; const MenuScreen = React.createCl...
import React from "react"; import Container from "./Container.js"; import Button from "./../Shared/Button.js"; import setCurrentScreenAction from "../../actions/ScreenActions.js"; import { GAME_SCREEN } from "../../actions/ScreenActions.js"; import {setGameModeAction} from "../../actions/GameActions.js"; import {VS_...
Add actions to start vs computer
Add actions to start vs computer Change onClick action handlers for buttons
JavaScript
mit
Lingvokot/Tic-Tac-Toe-React,Lingvokot/Tic-Tac-Toe-React,Lingvokot/Tic-Tac-Toe-React
--- +++ @@ -5,6 +5,9 @@ import setCurrentScreenAction from "../../actions/ScreenActions.js"; import { GAME_SCREEN } from "../../actions/ScreenActions.js"; + +import {setGameModeAction} from "../../actions/GameActions.js"; +import {VS_HUMAN, EASY, MEDIUM, HARD} from "../../reducers/Game.js"; const screenTitle =...
4446bd48ebd8ced9f5001b202b8d0fa2b8b36a74
server/src/connectors/carriots.module.js
server/src/connectors/carriots.module.js
"use strict"; let https = require('https'); let keys = require("./secretKeys.js"); exports.init = function (mainCallback) { let options = { host: "api.carriots.com", path: "/streams/?max=1&order=-1", port: 443, method: "GET", headers: { "Accept": "application/json", "carriots.apiKey": keys.CARRIOT...
"use strict"; let https = require('https'); let keys = require("./secretKeys.js"); exports.init = function (mainCallback) { let options = { host: "api.carriots.com", path: "/streams/?max=1&order=-1", port: 443, method: "GET", headers: { "Accept": "application/json", "carriots.apiKey": keys.CARRIOT...
Set interval to 5 seconds instead of 10
Set interval to 5 seconds instead of 10
JavaScript
mit
Zenika/bottleopener_iot,Zenika/bottleopener_iot,Zenika/bottleopener_iot,Zenika/bottleopener_iot
--- +++ @@ -39,6 +39,6 @@ }); req.end(); - }, 10000); + }, 5000); };
5e1316ee48816cab9c2d8eec9c31b5054d0d801a
app/core/services/ledger-nano.js
app/core/services/ledger-nano.js
/* global angular, require */ import 'ionic-sdk/release/js/ionic.bundle'; import platformInfo from './platform-info.js'; angular.module('app.service.ledger-nano', []) .factory('LedgerNano', function ($q) { 'use strict'; let StellarLedger; if (platformInfo.isElectron) { const electron = require('electron'); St...
/* global require */ import platformInfo from './platform-info.js'; let StellarLedger; if (platformInfo.isElectron) { const electron = require('electron'); StellarLedger = electron.remote.require('stellar-ledger-api'); } const bip32Path = (index) => `44'/148'/${index}'`; const wrapper = (func, field) => new Promi...
Use native Promise instead of $q
Use native Promise instead of $q
JavaScript
agpl-3.0
johansten/stargazer,johansten/stargazer,johansten/stargazer
--- +++ @@ -1,47 +1,41 @@ -/* global angular, require */ +/* global require */ -import 'ionic-sdk/release/js/ionic.bundle'; import platformInfo from './platform-info.js'; -angular.module('app.service.ledger-nano', []) -.factory('LedgerNano', function ($q) { - 'use strict'; +let StellarLedger; +if (platformInfo.i...
ee805b8617ecbc03cef0c421124bb799890b9ef8
app/utils/service-colors.js
app/utils/service-colors.js
export default { 'CORE - METRORAIL': 'red', 'CORE - METRORAPID': '#f24d6e', 'CORE - LIMITED': '#649dce', 'CORE - RADIAL': '#5190c8', 'CORE - FEEDER': '#3d84c2', 'CORE - EXPRESS/FLYERS': '#3777ae', 'CORE - CROSSTOWN': '#77a9d4', 'SPECIAL - REVERSE COMMUTE': '#6c9452', 'SPECIAL - RAIL CONNECTORS': '#4b8...
export default { 'CORE - METRORAIL': 'red', 'CORE - METRORAPID': '#f24d6e', 'CORE - LIMITED': '#1D86A4', 'CORE - RADIAL': '#053862', 'CORE - FEEDER': '#72C6DE', 'CORE - EXPRESS/FLYERS': '#42A7C3', 'CORE - CROSSTOWN': '#105FA0', 'SPECIAL - REVERSE COMMUTE': '#6c9452', 'SPECIAL - RAIL CONNECTORS': '#4b8...
Increase contrast and color variation.
Increase contrast and color variation.
JavaScript
mit
jga/capmetrics-web,jga/capmetrics-web
--- +++ @@ -1,11 +1,11 @@ export default { 'CORE - METRORAIL': 'red', 'CORE - METRORAPID': '#f24d6e', - 'CORE - LIMITED': '#649dce', - 'CORE - RADIAL': '#5190c8', - 'CORE - FEEDER': '#3d84c2', - 'CORE - EXPRESS/FLYERS': '#3777ae', - 'CORE - CROSSTOWN': '#77a9d4', + 'CORE - LIMITED': '#1D86A4', + 'CORE -...
fd1fcc6f35f2e36290fe1143edcea2334e079267
app/assets/javascripts/_analytics.js
app/assets/javascripts/_analytics.js
(function() { "use strict"; GOVUK.Tracker.load(); var cookieDomain = (document.domain === 'www.digitalmarketplace.service.gov.uk') ? '.digitalmarketplace.service.gov.uk' : document.domain; var property = (document.domain === 'www.digitalmarketplace.service.gov.uk') ? 'UA-49258698-1' : 'UA-49258698-3'; GOVUK.a...
(function() { "use strict"; GOVUK.Analytics.load(); var cookieDomain = (document.domain === 'www.digitalmarketplace.service.gov.uk') ? '.digitalmarketplace.service.gov.uk' : document.domain; var property = (document.domain === 'www.digitalmarketplace.service.gov.uk') ? 'UA-49258698-1' : 'UA-49258698-3'; // w...
Patch GOVUK.Analytics to add 'allowLinker' option
Patch GOVUK.Analytics to add 'allowLinker' option The GOVUK.Analytics interface doesn't set the 'allowLinker' option when creating a ga tracker. In order to preserve a vendor-agnostic interface it also doesn't allow this to be sent through when creating a new GOVUK.Analytics instance. This commit patches GOVUK.Googl...
JavaScript
mit
alphagov/digitalmarketplace-buyer-frontend,AusDTO/dto-digitalmarketplace-buyer-frontend,alphagov/digitalmarketplace-buyer-frontend,AusDTO/dto-digitalmarketplace-buyer-frontend,AusDTO/dto-digitalmarketplace-buyer-frontend,alphagov/digitalmarketplace-buyer-frontend,alphagov/digitalmarketplace-buyer-frontend,AusDTO/dto-di...
--- +++ @@ -1,11 +1,35 @@ (function() { "use strict"; - GOVUK.Tracker.load(); + GOVUK.Analytics.load(); var cookieDomain = (document.domain === 'www.digitalmarketplace.service.gov.uk') ? '.digitalmarketplace.service.gov.uk' : document.domain; var property = (document.domain === 'www.digitalmarketplace.ser...