commit stringlengths 40 40 | old_file stringlengths 4 264 | new_file stringlengths 4 264 | old_contents stringlengths 0 4.24k | new_contents stringlengths 1 5.44k | subject stringlengths 14 778 | message stringlengths 15 9.92k | lang stringclasses 277
values | license stringclasses 13
values | repos stringlengths 5 127k |
|---|---|---|---|---|---|---|---|---|---|
b6bf4fe2f000ffcbf21568a2095b54eef1e0abf5 | client/skr/components/LocationChooser.cjsx | client/skr/components/LocationChooser.cjsx | class Skr.Components.LocationChooser extends Lanes.React.Component
propTypes:
onModelSet: React.PropTypes.func
name: React.PropTypes.string
getDefaultProps: ->
label: 'Location', name: 'location'
dataObjects:
query: ->
new Lanes.Models.Query({
... | class Skr.Components.LocationChooser extends Lanes.React.Component
propTypes:
onModelSet: React.PropTypes.func
name: React.PropTypes.string
hideSingle: React.PropTypes.bool
getDefaultProps: ->
label: 'Location', name: 'location'
dataObjects:
query: ->
... | Allow hiding if operating as single location | Allow hiding if operating as single location
| CoffeeScript | agpl-3.0 | argosity/stockor,argosity/stockor,argosity/stockor,argosity/stockor |
d18220bcdc621edfb79c8c6059efee74530553a8 | src/init.coffee | src/init.coffee | @Infeedl ||= {}
@Infeedl.init = ->
Infeedl.$("[data-infeedl-placement]").each ->
placement = new Infeedl.Placement($(this).attr("data-infeedl-placement"), this)
placement.fetch()
Infeedl.$ = jQuery.noConflict()
@Infeedl.init()
| @Infeedl ||= {}
@Infeedl.init = ->
Infeedl.$("[data-infeedl-placement]").each ->
placement = new Infeedl.Placement(Infeedl.$(this).attr("data-infeedl-placement"), this)
placement.fetch()
Infeedl.$ = jQuery.noConflict()
@Infeedl.init()
| Fix stupid bug with jQuery reference | Fix stupid bug with jQuery reference
| CoffeeScript | mit | infeedl/infeedl-js |
06e966bfe8ac29910d3deeb45e29a434cb6acdd9 | build/gh-pages.coffee | build/gh-pages.coffee | grunt = require 'grunt'
module.exports =
'gh-pages':
options:
base: 'gh-pages'
add: yes
src: ['**']
clean: [
'gh-pages/*'
'!gh-pages/.gitignore'
'!gh-pages/template.html'
]
copy:
expand: yes
src: [
'dist/**/*'
'docs/**/*'
'lib/**/*'
'tests/**/... | grunt = require 'grunt'
module.exports =
'gh-pages':
options:
base: 'gh-pages'
add: yes
src: ['**']
clean: [
'gh-pages/*'
'!gh-pages/.gitignore'
'!gh-pages/template.html'
]
copy:
expand: yes
src: [
'dist/**/*'
'docs/**/*'
'lib/**/*'
'tests/**/... | Update Grunt pages task. | Update Grunt pages task. [ci skip] | CoffeeScript | mit | hlfcoding/hlf-jquery,hlfcoding/hlf-jquery |
ee71070f1fe682fd5b4af7c1d71c03910e6e0caa | atom/packages.cson | atom/packages.cson | packages: [
"advanced-open-file"
"atom-alignment"
"atom-beautify"
"atom-transpose"
"color-picker"
"docblockr"
"editorconfig"
"emmet"
"expand-region"
"language-apache"
"language-applescript"
"language-awk"
"language-babel"
"language-diff"
"language-env"
"language-gitattributes"
"languag... | packages: [
"advanced-open-file"
"atom-alignment"
"atom-beautify"
"atom-transpose"
"color-picker"
"docblockr"
"editorconfig"
"emmet"
"expand-region"
"language-apache"
"language-applescript"
"language-awk"
"language-babel"
"language-diff"
"language-env"
"language-gitattributes"
"languag... | Add language-pip to Atom package list | Add language-pip to Atom package list
| CoffeeScript | mit | caleb531/dotfiles,caleb531/dotfiles,caleb531/dotfiles,caleb531/dotfiles |
386c71bbf601fa60b8254a1adade93c357ad91ae | gruntfile.coffee | gruntfile.coffee | module.exports = (grunt)->
grunt.initConfig
pkg: grunt.file.readJSON('package.json')
jshint:
options:
jshintrc: '.jshintrc'
all: [
'Standards/**/*.js'
'PhantomJS/*.js'
]
uglify:
options:
banner: '/*! <%= pkg.name %> - v<%= pkg.version %> - <%= ... | module.exports = (grunt)->
grunt.initConfig
pkg: grunt.file.readJSON('package.json')
jshint:
options:
jshintrc: '.jshintrc'
all: [
'Standards/**/*.js'
'PhantomJS/*.js'
]
uglify:
options:
banner: '/*! <%= pkg.name %> - v<%= pkg.version %> - <%= ... | Include the auditor gui in the build | Include the auditor gui in the build
| CoffeeScript | bsd-3-clause | daam/HTML_CodeSniffer,squizlabs/HTML_CodeSniffer,lwright-sq/HTML_CodeSniffer,telesma/HTML_CodeSniffer,squizlabs/HTML_CodeSniffer,ironikart/HTML_CodeSniffer,adelevie/HTML_CodeSniffer,daam/HTML_CodeSniffer,daam/HTML_CodeSniffer,ironikart/HTML_CodeSniffer,ironikart/HTML_CodeSniffer,adelevie/HTML_CodeSniffer,adelevie/HTML_... |
56df435fb8806f042c98793e8fd03cc0e6787725 | src/deserializer-manager.coffee | src/deserializer-manager.coffee | {Document} = require 'telepath'
# Public: Manages the deserializers used for serialized state
module.exports =
class DeserializerManager
constructor: ->
@deserializers = {}
@deferredDeserializers = {}
# Public: Add a deserializer.
add: (klasses...) ->
@deserializers[klass.name] = klass for klass in ... | {Document} = require 'telepath'
# Public: Manages the deserializers used for serialized state
module.exports =
class DeserializerManager
constructor: ->
@deserializers = {}
@deferredDeserializers = {}
# Public: Register the given class(es) as deserializers.
add: (klasses...) ->
@deserializers[klass.... | Mark ::get as private and tweak comments | :memo: Mark ::get as private and tweak comments
| CoffeeScript | mit | FIT-CSE2410-A-Bombs/atom,anuwat121/atom,KENJU/atom,mnquintana/atom,palita01/atom,ilovezy/atom,Austen-G/BlockBuilder,jacekkopecky/atom,targeter21/atom,RuiDGoncalves/atom,kdheepak89/atom,amine7536/atom,YunchengLiao/atom,Huaraz2/atom,stinsonga/atom,vinodpanicker/atom,mostafaeweda/atom,G-Baby/atom,me6iaton/atom,liuxiong332... |
a41938982e1582a1a0822e0b807f823fffbe78e9 | app/assets/javascripts/views/phase_header_view.js.coffee | app/assets/javascripts/views/phase_header_view.js.coffee | ETahi.PhaseHeaderView = Em.View.extend
templateName: 'phase_header'
classNames: ['column-header']
classNameBindings: ['active']
active: false
focusIn: (e)->
@set('active', true)
phaseNameDidChange: (->
# race condition with binding and cancel action? :(
Em.run.later (->
Tahi.utils.resize... | ETahi.PhaseHeaderView = Em.View.extend
templateName: 'phase_header'
classNames: ['column-header']
classNameBindings: ['active']
active: false
focusIn: (e)->
@set('active', true)
phaseNameDidChange: (->
Ember.run.schedule('afterRender' , this, ->
Tahi.utils.resizeColumnHeaders()
)
).obs... | Change out Ember.run.later for Ember.run.schedule | Change out Ember.run.later for Ember.run.schedule
| CoffeeScript | mit | johan--/tahi,johan--/tahi,johan--/tahi,johan--/tahi |
de9c2ab28bc55b033159a9b9c3ea498c445fc4a2 | static/src/scripts/app/main.coffee | static/src/scripts/app/main.coffee | require [
"jquery"
"underscore"
"backbone"
"foundation"
"foundation.topbar"
"raven"
"AppRouter"
"signet"
], ($, _, Backbone, foundation, topbar, Raven, Router) ->
$ ->
# Config Sentry Raven Client
if jailbreak.sentry.enabled
Raven.config(jailbreak.sentry.dsn, {
whitelistUrls: ... | require [
"jquery"
"underscore"
"backbone"
"foundation"
"foundation.topbar"
"raven"
"AppRouter"
"signet"
"async"
], ($, _, Backbone, foundation, topbar, Raven, Router) ->
$ ->
# Config Sentry Raven Client
if jailbreak.sentry.enabled
Raven.config(jailbreak.sentry.dsn, {
white... | Fix requirejs errors for googles map in QA | Fix requirejs errors for googles map in QA
| CoffeeScript | mit | jailbreakhq/public-static,jailbreakhq/public-static |
b296adefb5fc90ccffd73fa1becdcf3749ba6916 | app/views/dashboard_dialog.coffee | app/views/dashboard_dialog.coffee | BaseView = require 'views/base_view'
Manager = require 'modules/manager'
class DashboardDialog extends BaseView
className: 'dialog'
tag: 'div'
projects: require 'config/projects_config'
template: require './templates/dashboard_dialog'
initialize: (options) ->
@parent = options.parent
@selected = M... | BaseView = require 'views/base_view'
Manager = require 'modules/manager'
class DashboardDialog extends BaseView
className: 'dialog'
tag: 'div'
projects: require 'config/projects_config'
template: require './templates/dashboard_dialog'
initialize: (options) ->
@parent = options.parent
@selected = M... | Fix bug where creating a dashboard didn't direct you to its url | Fix bug where creating a dashboard didn't direct you to its url
| CoffeeScript | apache-2.0 | zooniverse/Ubret-Dashboard |
fdc5861db622778d439a19630c5646651048a038 | dashboard_spec.coffee | dashboard_spec.coffee | #= require dashboard
#= require mock-ajax
describe "Dashboard - getData()", ->
beforeEach ->
jasmine.Ajax.useMock()
@dashboard = Dashboard
describe "when the report is ready on the first iteration", ->
it "should return the dashboard data", ->
that = this
@dashboard.getData 'lesson_leader... | #= require lib/dashboard_poller
#= require mock-ajax
describe "Dashboard - getData()", ->
beforeEach ->
jasmine.Ajax.useMock()
@dashboard = ttm.lib.DashboardPoller.build()
describe "when the report is ready on the first iteration", ->
it "should return the dashboard data", ->
that = this
... | Move the poller into the lib and mix it with the other classmixer stuffs. Update the test. | Move the poller into the lib and mix it with the other classmixer stuffs.
Update the test.
| CoffeeScript | mit | thinkthroughmath/ttm-coffeescript-math,thinkthroughmath/ttm-coffeescript-math |
a386738b7770dc2a2af72a148ff79b094c1d509c | Enumeration.coffee | Enumeration.coffee | class Enumeration
#Registered enums
@types:[]
#Static function that creates an enum object value. Uniqueness guarantied by object reference.
#This objects's unique own field is the Enumeration name. It's read only.
#string value shall be uppercase
@value:(value,enumName="Enumeration")->
prototype= id: -... | #Registered enums
enumNames=[]
class Enumeration
#Static function that creates an enum object value. Uniqueness guarantied by object reference.
#This objects's unique own field is the Enumeration name. It's read only.
#string value shall be uppercase
@value:(value,enumName="Enumeration")->
prototype= id: ->... | Move enumNames out of class | Move enumNames out of class | CoffeeScript | mit | sveinburne/enumerationjs,sveinburne/enumerationjs |
6aa7401742f3c7a470188aeacf231dbd42361390 | app/classify/subject-viewer.cjsx | app/classify/subject-viewer.cjsx | React = require 'react'
module.exports = React.createClass
displayName: 'SubjectViewer'
mediaSrcs: {}
getInitialState: ->
text: 'Loading'
componentDidMount: ->
@loadText @props.subject?.locations
componentWillReceiveProps: (newProps) ->
@loadText newProps.subject?.locations
rende... | React = require 'react'
module.exports = React.createClass
displayName: 'SubjectViewer'
mediaSrcs: {}
getInitialState: ->
text: 'Loading'
componentDidMount: ->
@loadText @props.subject?.locations
componentWillReceiveProps: (newProps) ->
@loadText newProps.subject?.locations
rende... | Remove filename debugging info from the subject viewer | Remove filename debugging info from the subject viewer
| CoffeeScript | apache-2.0 | zooniverse/wellcome,zooniverse/wellcome |
e5339beb14b0d38bfe0c378cae28bed862fc27f7 | snippets/objects.cson | snippets/objects.cson | ".source.js":
"Object.assign":
prefix: "assign"
body: "Object.assign(${1:dest}, ${2:source})"
"Object.assign +":
prefix: "Object.assign"
body: "Object.assign(${1:dest}, ${2:source})"
"Object.create":
prefix: "create"
body: "Object.create(${1:object})"
"Object.create +":
prefix: "Obj... | ".source.js":
"Object.assign":
prefix: "assign"
body: "Object.assign(${1:dest}, ${2:source})"
"Object.assign +":
prefix: "Object.assign"
body: "Object.assign(${1:dest}, ${2:source})"
"Object.create":
prefix: "create"
body: "Object.create(${1:object})"
"Object.create +":
prefix: "Obj... | Add Object.values & Object.entries snippets | Add Object.values & Object.entries snippets
| CoffeeScript | mit | kswedberg/atom-js-extras |
fe4d6733e929074587a2d3ba0cbf7589e99e8d49 | client/ide/workspace/panes/finderpane.coffee | client/ide/workspace/panes/finderpane.coffee | class FinderPane extends Pane
constructor: (options = {}, data) ->
super options, data
@createFinderController()
@bindListeners()
createFinderController: ->
finderApp = new FinderController
@finderController = finderApp.create()
@addSubView @finderController.getView()
@finde... | class FinderPane extends Pane
constructor: (options = {}, data) ->
super options, data
vmController = KD.getSingleton 'vmController'
vmController.fetchDefaultVmName (vmName) =>
@finder = new NFinderController
nodeIdPath : 'path'
nodeParentIdPath : 'parentPath'
contextMen... | Revert custom finder related logic. | Revert custom finder related logic.
| CoffeeScript | agpl-3.0 | koding/koding,mertaytore/koding,kwagdy/koding-1,sinan/koding,andrewjcasal/koding,koding/koding,jack89129/koding,sinan/koding,drewsetski/koding,gokmen/koding,usirin/koding,rjeczalik/koding,rjeczalik/koding,acbodine/koding,usirin/koding,jack89129/koding,acbodine/koding,jack89129/koding,drewsetski/koding,usirin/koding,and... |
ecbd2126cb2b784c6b59dc74c5eb86b9f349d5b3 | angular/core/services/time_service.coffee | angular/core/services/time_service.coffee | angular.module('loomioApp').factory 'TimeService', (AppConfig) ->
new class TimeService
displayDate: (m, zone) =>
if moment._f == 'YYYY-MM-DD'
m.format("D MMMM#{@sameYear(m)}")
else
@inTimeZone(m, zone).format("D MMMM#{@sameYear(m)} - h:mma")
isoDate: (m, zone) =>
@inTimeZo... | angular.module('loomioApp').factory 'TimeService', (AppConfig) ->
new class TimeService
displayDate: (m, zone) =>
if m._f == 'YYYY-MM-DD'
m.format("D MMMM#{@sameYear(m)}")
else
@inTimeZone(m, zone).format("D MMMM#{@sameYear(m)} - h:mma")
isoDate: (m, zone) =>
@inTimeZone(m,... | Fix in app date display for meeting tiems | Fix in app date display for meeting tiems
| CoffeeScript | agpl-3.0 | loomio/loomio,piratas-ar/loomio,piratas-ar/loomio,loomio/loomio,loomio/loomio,piratas-ar/loomio,loomio/loomio,piratas-ar/loomio |
cadeb7fa3603cd56f17a605fe2b68dfa9ae1ce8f | app/controllers/session-controller.coffee | app/controllers/session-controller.coffee | EmailPasswordController = require './email-password-controller'
debug = require('debug')('meshblu-email-password-authenticator:sessions-controller')
class SessionController
constructor: (uuid, meshblu) ->
@emailPasswordController = new EmailPasswordController uuid, meshblu: meshblu
create: (request, response)... | EmailPasswordController = require './email-password-controller'
debug = require('debug')('meshblu-email-password-authenticator:sessions-controller')
url = require 'url'
class SessionController
constructor: (uuid, meshblu) ->
@emailPasswordController = new EmailPasswordController uuid, meshblu: meshblu
create:... | Use the callback url to redirect the user | Use the callback url to redirect the user
| CoffeeScript | mit | octoblu/meshblu-authenticator-email-password,octoblu/meshblu-email-password-authenticator |
6cf0c73453dcf11d4719730a8361c2403103f543 | app/assets/javascripts/admin/products/controllers/variant_units_controller.js.coffee | app/assets/javascripts/admin/products/controllers/variant_units_controller.js.coffee | angular.module("admin.products").controller "variantUnitsCtrl", ($scope, VariantUnitManager, $timeout, UnitPrices) ->
$scope.unitName = (scale, type) ->
VariantUnitManager.getUnitName(scale, type)
$scope.$watchCollection "[unit_value_human, variant.price]", ->
$scope.processUnitPrice()
$scope.process... | angular.module("admin.products").controller "variantUnitsCtrl", ($scope, VariantUnitManager, $timeout, UnitPrices, unlocalizeCurrencyFilter) ->
$scope.unitName = (scale, type) ->
VariantUnitManager.getUnitName(scale, type)
$scope.$watchCollection "[unit_value_human, variant.price]", ->
$scope.processUnitP... | Use our unlocalizeCurrencyFilter to parse unit value field | Use our unlocalizeCurrencyFilter to parse unit value field
- More tolerant (can handle `,` or `.` as decimal separator, remove thousands separator) to return a `number`
| CoffeeScript | agpl-3.0 | Matt-Yorkley/openfoodnetwork,Matt-Yorkley/openfoodnetwork,lin-d-hop/openfoodnetwork,lin-d-hop/openfoodnetwork,lin-d-hop/openfoodnetwork,mkllnk/openfoodnetwork,openfoodfoundation/openfoodnetwork,lin-d-hop/openfoodnetwork,openfoodfoundation/openfoodnetwork,mkllnk/openfoodnetwork,Matt-Yorkley/openfoodnetwork,openfoodfound... |
9bdbd9c9c40b08f9e79832b53248093eb78466f1 | spec/body-parser-spec.coffee | spec/body-parser-spec.coffee | BodyParser = require '../lib/snippet-body-parser.coffee'
describe "Snippet Body Parser", ->
it "breaks a snippet body into lines, with each line containing tab stops at the appropriate position", ->
bodyTree = BodyParser.parse """
the quick brown $1fox ${2:jumped ${3:over}
}the ${4:lazy} dog
"""
... | BodyParser = require '../lib/snippet-body-parser'
describe "Snippet Body Parser", ->
it "breaks a snippet body into lines, with each line containing tab stops at the appropriate position", ->
bodyTree = BodyParser.parse """
the quick brown $1fox ${2:jumped ${3:over}
}the ${4:lazy} dog
"""
ex... | Remove .coffee extension from require path | Remove .coffee extension from require path
Refs atom/atom#4884
| CoffeeScript | mit | atom/snippets,terrycloth/atom-snippets,lpommers/snippets,bengy/snippets |
eda2088b2ab673f3572c16251f753ace65123c1b | client/landing/gulptasks/task.build.all.coffee | client/landing/gulptasks/task.build.all.coffee | fs = require 'fs'
gulp = require 'gulp'
shell = require 'gulp-shell'
module.exports = (version) ->
folders = (folder for folder in fs.readdirSync('./') when fs.statSync(folder).isDirectory())
sites = folders.filter (folder) -> folder.search(/^site\./) is 0 and folder isnt 'site.boilerplate'
comman... | fs = require 'fs'
gulp = require 'gulp'
shell = require 'gulp-shell'
module.exports = (version) ->
folders = (folder for folder in fs.readdirSync('./') when fs.statSync(folder).isDirectory())
sites = folders.filter (folder) ->
siteDir = folder.search(/^site\./) is 0 and folder isnt 'site.boilerp... | Check existence of gulpfile in landing site directory | Check existence of gulpfile in landing site directory
| CoffeeScript | agpl-3.0 | usirin/koding,rjeczalik/koding,cihangir/koding,cihangir/koding,sinan/koding,drewsetski/koding,rjeczalik/koding,sinan/koding,kwagdy/koding-1,alex-ionochkin/koding,gokmen/koding,mertaytore/koding,kwagdy/koding-1,alex-ionochkin/koding,drewsetski/koding,gokmen/koding,acbodine/koding,szkl/koding,kwagdy/koding-1,andrewjcasal... |
b37cdf8212df21dd51ae4fdd2c62d2248156f150 | atom/init.coffee | atom/init.coffee | # Your init script
#
# Atom will evaluate this file each time a new window is opened. It is run
# after packages are loaded/activated and after the previous editor state
# has been restored.
#
path = require 'path'
oldWindowDimensions = {}
oldThemes = []
atom.commands.add 'atom-workspace',
'custom:open-todo-list':... | # Your init script
#
# Atom will evaluate this file each time a new window is opened. It is run
# after packages are loaded/activated and after the previous editor state
# has been restored.
#
path = require 'path'
oldWindowDimensions = {}
atom.commands.add 'atom-workspace',
'custom:open-todo-list': ->
todoLis... | Add command for opening todo list | Add command for opening todo list
| CoffeeScript | mit | lee-dohm/dotfiles,lee-dohm/dotfiles,lee-dohm/dotfiles,lee-dohm/dotfiles |
641403bc1ef65fd02de44c627adb2c72eb258b00 | server/test/helpers.coffee | server/test/helpers.coffee | app = require('../app')
test_server = null
url = require('url')
before( (done) ->
app.start 3001, (err, server) ->
test_server = server
done()
)
after( (done) ->
test_server.close () -> done()
)
beforeEach( (done) ->
global.sequelize.sync({force: true}).success(() -> done())
)
exports.appurl = (path) ... | app = require('../app')
test_server = null
url = require('url')
before( (done) ->
app.start 3001, (err, server) ->
test_server = server
done()
)
after( (done) ->
test_server.close () -> done()
)
dropDatabase = (connection, done) ->
connection.db.dropDatabase (err) ->
if err?
console.log 'ERRO... | Drop mongodb database between tests | Drop mongodb database between tests
| CoffeeScript | bsd-3-clause | unepwcmc/NRT,unepwcmc/NRT |
6399b7490d15e88aa4e5481337d20e56975b0f0b | js/libs/github.coffee | js/libs/github.coffee | checkOuterPages = (url) =>
outerPages = ["docs", "about", "privacy", "pricing"]
for page in outerPages
if (url.match "^/#{page}.*")
return "/"
return url
CI.github =
# we encore each parammeter separately (one of them twice!) to get the right format
authUrl: (scope=["user", "repo"]) =>
destina... | checkOuterPages = (url) =>
outerPages = ["docs", "about", "privacy", "pricing"]
for page in outerPages
if (url.match "^/#{page}.*")
return "/"
return url
CI.github =
# we encore each parammeter separately (one of them twice!) to get the right format
authUrl: (scope=["user", "repo"]) =>
destina... | Fix login problems on firefox | Fix login problems on firefox
| CoffeeScript | epl-1.0 | RayRutjes/frontend,RayRutjes/frontend,prathamesh-sonpatki/frontend,circleci/frontend,prathamesh-sonpatki/frontend,circleci/frontend,circleci/frontend |
0f91dbf072c4b9a776c7319d142afbe0e417f696 | lib/models/branches/current-branch.coffee | lib/models/branches/current-branch.coffee | LocalBranch = require './local-branch'
{git} = require '../../git'
module.exports =
class CurrentBranch extends LocalBranch
initialize: ->
@reload()
reload: ->
git.branch (head) =>
@set head
git.gitNoChange "log @{u}..", (output) =>
@set unpushed: (output != "")
head: ->
"HEAD"
... | LocalBranch = require './local-branch'
{git} = require '../../git'
module.exports =
class CurrentBranch extends LocalBranch
initialize: ->
@reload()
reload: ->
git.branch (head) =>
@set head
# git.gitNoChange "log @{u}..", (output) =>
# @set unpushed: (output != "")
head: ->
"HEAD... | Remove pushed/unpushed status for now. | Remove pushed/unpushed status for now.
# Compose your commit message. Press `cmd-alt-c` to commit. Close to cancel.
| CoffeeScript | mit | aki77/atomatigit,tomekwi/atomatigit |
e133bf9abce1b6832c3b79674dcea308783b4ec7 | routes/auth.coffee | routes/auth.coffee | express = require 'express'
passport = require 'passport'
router = express.Router()
router.post '/login', passport.authenticate 'local',
successRedirect: '/app'
failureRedirect: '/'
failureFlash: 'Invalid username or password!'
module.exports = router
| express = require 'express'
passport = require 'passport'
router = express.Router()
router.post '/login', passport.authenticate 'local',
successRedirect: '/admin'
failureRedirect: '/'
failureFlash: 'Invalid username or password!'
module.exports = router
| Fix wrong redirect after logging in | Fix wrong redirect after logging in
| CoffeeScript | mit | Rezonation/sisetv,Rezonation/sisetv |
4bd4f4590a094d66dbdf993d4be8fad2046b4cd9 | layouts/Body.coffee | layouts/Body.coffee | React = require 'react'
Nav = React.createFactory require 'antwar-default-theme/Nav'
Paths = require('antwar-core/PathsMixin')
require 'antwar-default-theme/scss/main.scss'
require 'react-ghfork/gh-fork-ribbon.ie.css' # ie support
require 'react-ghfork/gh-fork-ribbon.css'
Fork = React.createFactory(require 'react-ghfo... | React = require 'react'
Nav = React.createFactory require 'antwar-default-theme/Nav'
Paths = require('antwar-core/PathsMixin')
require 'antwar-default-theme/scss/main.scss'
require 'react-ghfork/gh-fork-ribbon.ie.css' # ie support
require 'react-ghfork/gh-fork-ribbon.css'
Fork = React.createFactory(require 'react-ghfo... | Set `target: _blank` on submit feedback | Set `target: _blank` on submit feedback
Better ux.
| CoffeeScript | mit | Foxandxss/site,Foxandxss/site |
852d775a1abc90b8dab656ade29182b779d5f6a1 | client/views/login/layout.coffee | client/views/login/layout.coffee | Template.loginLayout.rendered = ->
$('html').addClass("scroll").removeClass "noscroll"
window.pJSDom = []
particlesJS.load 'particles-js', '/scripts/particles.json', -> | Template.loginLayout.rendered = ->
$('html').addClass("scroll").removeClass "noscroll"
if not Meteor.isCordova
window.pJSDom = []
particlesJS.load 'particles-js', '/scripts/particles.json', -> | Disable particles in mobile login | Disable particles in mobile login
| CoffeeScript | mit | wicked539/Rocket.Chat,celloudiallo/Rocket.Chat,Abdelhamidhenni/Rocket.Chat,galrotem1993/Rocket.Chat,ealbers/Rocket.Chat,haoyixin/Rocket.Chat,sargentsurg/Rocket.Chat,umeshrs/rocket-chat,mitar/Rocket.Chat,psadaic/Rocket.Chat,mrsimpson/Rocket.Chat,madmanteam/Rocket.Chat,Codebrahma/Rocket.Chat,intelradoux/Rocket.Chat,nishi... |
5f6a6d4a27730cb6768ccef4bf9bcbfa6469ef0d | app/assets/javascripts/cmsimple/panels/images/list.coffee | app/assets/javascripts/cmsimple/panels/images/list.coffee | #= require cmsimple/panels/images/panel
class CMSimple.Panels.ImageLibrary.List extends Spine.Controller
events:
'click .media-actions > .info' : 'toggleInfo'
'click .media-info > .close' : 'toggleInfo'
'click [data-full-url]' : 'triggerImage'
'click .delete' : 'deleteImage'
constructor: (el)->
... | #= require cmsimple/panels/images/panel
class CMSimple.Panels.ImageLibrary.List extends Spine.Controller
events:
'click .media-actions > .info' : 'toggleInfo'
'click .media-info > .close' : 'toggleInfo'
'click [data-full-url]' : 'triggerImage'
'click .delete' : 'deleteImage'
constructor: (el)->
... | Set image properties when inserting an image. | Set image properties when inserting an image. | CoffeeScript | mit | modeset/cmsimple,modeset/cmsimple,modeset/cmsimple |
e76a7f7b7d662ebcd7d6a441e1dfc39118638775 | atom/browser/api/lib/exports/electron.coffee | atom/browser/api/lib/exports/electron.coffee | # Import common modules.
module.exports = require '../../../../common/api/lib/exports/electron'
v8Util = process.atomBinding 'v8_util'
v8Util.setHiddenValue module.exports, 'electronModule', true
Object.defineProperties module.exports,
# Browser side modules, please sort with alphabet order.
app:
enumerable: ... | # Import common modules.
module.exports = require '../../../../common/api/lib/exports/electron'
v8Util = process.atomBinding 'v8_util'
v8Util.setHiddenValue module.exports, 'electronModule', true
Object.defineProperties module.exports,
# Browser side modules, please sort with alphabet order.
app:
enumerable: ... | Fix typo, tray => Tray | Fix typo, tray => Tray
| CoffeeScript | mit | gerhardberger/electron,ankitaggarwal011/electron,roadev/electron,preco21/electron,miniak/electron,lzpfmh/electron,evgenyzinoviev/electron,gerhardberger/electron,aliib/electron,brave/muon,biblerule/UMCTelnetHub,tonyganch/electron,bpasero/electron,stevekinney/electron,leethomas/electron,kcrt/electron,dongjoon-hyun/electr... |
1b2f368b51d568629d5c390f392629bc160a5b0b | app/choose-subject-set.cjsx | app/choose-subject-set.cjsx | React = require 'react'
module.exports = React.createClass
displayName: 'ChooseSubjectSet'
getInitialState: ->
subject_sets: []
componentWillMount: ->
@props.workflow?.get 'subject_sets', page_size: 40
.then (subject_sets) =>
@setState {subject_sets}
render: ->
<div classNa... | React = require 'react'
module.exports = React.createClass
displayName: 'ChooseSubjectSet'
getInitialState: ->
subject_sets: []
componentWillMount: ->
@props.workflow?.get 'subject_sets', page_size: 40
.then (subject_sets) =>
subject_sets.sort (a, b) ->
return 1 if a.metad... | Sort subject sets by borough and file id | Sort subject sets by borough and file id
| CoffeeScript | apache-2.0 | zooniverse/wellcome,zooniverse/wellcome |
56392ef13abc18bca3a2ad2e97984261ad68080d | spec/javascripts/application/seeds_store_spec.js.coffee | spec/javascripts/application/seeds_store_spec.js.coffee | describe 'PodsList', ->
subject = null
beforeEach (done) ->
subject = new SeedsStore('test')
expect(subject.clear()).eventually.notify(done)
it 'counts 0', (done) ->
expect(subject.countForAll()).eventually.equal(0).notify(done)
it 'counts n', (done) ->
subject.update([{name: 1},{name: 2},{name:... | describe 'PodsList', ->
subject = null
beforeEach (done) ->
subject = new SeedsStore('test')
expect(subject.clear()).eventually.notify(done)
it 'counts 0', (done) ->
expect(subject.countForAll()).eventually.equal(0).notify(done)
it 'counts n', (done) ->
subject.update([{name: 1},{name: 2},{name:... | Add specs for normal scope. | Add specs for normal scope.
| CoffeeScript | mit | bsingr/cocoa-tree,bsingr/cocoa-tree,bsingr/cocoa-tree |
b98df49c7eb78ef303691ae0c71e61ca7d8258b2 | lib/attachment.coffee | lib/attachment.coffee | #
Tether = require 'tether/tether'
assign = require 'object-assign'
React = require 'react'
$ = React.createElement
class Attachment extends React.Component
componentDidMount: =>
@root = document.createElement 'DIV'
document.body.appendChild @root
document.addEventListener 'mousedown', @handleEvent
... | #
Tether = require 'tether/tether'
assign = require 'object-assign'
React = require 'react'
$ = React.createElement
class Attachment extends React.Component
componentDidMount: =>
@root = document.createElement 'DIV'
document.body.appendChild @root
document.addEventListener 'mousedown', @handleEvent
... | Fix Attachment not correctly cleaning up listener | Fix Attachment not correctly cleaning up listener
| CoffeeScript | mit | jgraichen/molecule,jgraichen/molecule |
e8f699fbbe30fa179374eb3060865f2d17c7a975 | lib/status-bar.coffee | lib/status-bar.coffee | StatusBarView = require './status-bar-view'
FileInfoView = require './file-info-view'
CursorPositionView = require './cursor-position-view'
GrammarView = require './grammar-view'
GitView = require './git-view'
module.exports =
activate: ->
@statusBar = new StatusBarView()
@statusBar.attach()
@fileInfo =... | StatusBarView = require './status-bar-view'
FileInfoView = require './file-info-view'
CursorPositionView = require './cursor-position-view'
GitView = require './git-view'
module.exports =
activate: ->
@statusBar = new StatusBarView()
@statusBar.attach()
@fileInfo = new FileInfoView(@statusBar)
@stat... | Remove ref to status bar | Remove ref to status bar
| CoffeeScript | mit | devoncarew/status-bar,Abdillah/status-bar,ali/status-bar,TShapinsky/status-bar,mertkahyaoglu/status-bar,pombredanne/status-bar |
c3a269a97a88245f9200ceeaafa6fd683deeeb30 | vendor/assets/javascripts/pushable_collection.js.coffee | vendor/assets/javascripts/pushable_collection.js.coffee | class Backbone.PushableCollection extends Backbone.Collection
initialize: () ->
window.FayeClient.subscribe "/sync/#{@channel()}", _.bind(@receive, @)
receive: (message) ->
@[message.event] message.object
create: (attributes) ->
model = new @model attributes
model.fetch()
@add model
updat... | class Backbone.PushableCollection extends Backbone.Collection
initialize: () ->
window.FayeClient.subscribe "/sync/#{@channel()}", _.bind(@receive, @)
receive: (message) ->
@[message.event] message.object
create: (attributes) ->
model = new @model attributes
@add model
update: (attributes) ->... | Remove Fetch from PushableCollection Create Event | Remove Fetch from PushableCollection Create Event
| CoffeeScript | mit | billy-ran-away/pushable,billy-ran-away/pushable |
819078207d5a9b91c2fa2ab6e2e8cf7d5b8c113f | src/button/index.coffee | src/button/index.coffee | ###*
# @overview Registers the custom button tag.
#
# @module stout-ui/button
###
defaults = require 'lodash/defaults'
Button = require './Button'
ButtonView = require './ButtonView'
parser = require 'stout-client/parser'
# Read the button custom HTML tag.
TAG_NAME = vars.readPrefixed 'button/button-tag'
# ... | ###*
# @overview Registers the custom button tag.
#
# @module stout-ui/button
###
defaults = require 'lodash/defaults'
Button = require './Button'
ButtonView = require './ButtonView'
parser = require 'stout-client/parser'
# Read the button custom HTML tag.
TAG_NAME = vars.readPrefixed 'button/button-tag'
# ... | Add button interactive event proxying. | Add button interactive event proxying.
| CoffeeScript | agpl-3.0 | JoshuaToenyes/stout-ui,JoshuaToenyes/stout-ui,JoshuaToenyes/stout-ui |
dd531638f849dc66b00b0ef6a28efbd69febca56 | lib/tree.coffee | lib/tree.coffee | module.exports =
treeView: null
activate: (@state={}) ->
@createView() if @state.attached
rootView.command 'tree-view:toggle', => @createView().toggle()
rootView.command 'tree-view:reveal-active-file', => @createView().revealActiveFile()
deactivate: ->
@treeView?.deactivate()
@treeView = nul... | module.exports =
treeView: null
activate: (@state) ->
@createView() if @state.attached
rootView.command 'tree-view:toggle', => @createView().toggle()
rootView.command 'tree-view:reveal-active-file', => @createView().revealActiveFile()
deactivate: ->
@treeView?.deactivate()
@treeView = null
... | Remove unneeded param defaults from activate methods | Remove unneeded param defaults from activate methods
| CoffeeScript | mit | jarig/tree-view,rajendrant/tree-view-remote,atom/tree-view,thgaskell/tree-view,matthewbauer/tree-view,samu/tree-view,tomekwi/tree-view,cgrabowski/webgl-studio-tree-view,benjaminRomano/tree-view,ayumi/tree-view,pombredanne/tree-view-1,learn-co/learn-ide-tree,laituan245/tree-view,jasonhinkle/tree-view,tbryant/tree-view,G... |
e6160e95e3156f8de20c6fc2beea204deb59a001 | src/lib/Platform.coffee | src/lib/Platform.coffee | # NoFlo - Flow-Based Programming for JavaScript
# (c) 2014-2015 TheGrid (Rituwall Inc.)
# NoFlo may be freely distributed under the MIT license
#
# Platform detection method
exports.isBrowser = ->
if typeof process isnt 'undefined' and process.execPath and process.execPath.match /node|iojs/
return fal... | # NoFlo - Flow-Based Programming for JavaScript
# (c) 2014-2015 TheGrid (Rituwall Inc.)
# NoFlo may be freely distributed under the MIT license
#
# Platform detection method
exports.isBrowser = ->
if typeof process isnt 'undefined' and process.execPath and process.execPath.match /node|iojs/
return fal... | Add method for optionally-fatal deprecation warnings | Add method for optionally-fatal deprecation warnings
| CoffeeScript | mit | noflo/noflo |
1d1509778ae9c5b9873766ee369d775ccced89e4 | src/coffee/cilantro/ui/field/stats.coffee | src/coffee/cilantro/ui/field/stats.coffee | define [
'jquery'
'underscore'
'backbone'
'marionette'
'../base'
'../charts'
'../charts/utils'
'tpl!templates/field/stats.html'
], ($, _, Backbone, Marionette, base, charts, utils, templates...) ->
templates = _.object ['layout'], templates
class FieldStatValue extends Marione... | define [
'jquery'
'underscore'
'backbone'
'marionette'
'../base'
'../charts'
'../charts/utils'
'tpl!templates/field/stats.html'
], ($, _, Backbone, Marionette, base, charts, utils, templates...) ->
templates = _.object ['layout'], templates
class FieldStatValue extends Marione... | Add map of labels for statistical values | Add map of labels for statistical values
Currently, the only mapping is "Distinct count" --> "Unique values"
| CoffeeScript | bsd-2-clause | chop-dbhi/cilantro,chop-dbhi/cilantro,chop-dbhi/cilantro |
a8c5578d050ef62c533db6ea9163a6e19b56708a | src/scripts/app.js.coffee | src/scripts/app.js.coffee | #= require jquery/dist/jquery
#= require jquery-deparam/jquery-deparam
#= require jquery.transit/jquery.transit
#= require slow-ajax
#= require bootstrap/dist/js/bootstrap
#= require highstock-release/highstock
#= require highstock-release/modules/exporting
#= require leaflet/dist/leaflet
#= require leaflet-override
#=... | #= require jquery/dist/jquery
#= require jquery-deparam/jquery-deparam
#= require jquery.transit/jquery.transit
#= require slow-ajax
#= require bootstrap/dist/js/bootstrap
#= require highstock-release/highstock
#= require highstock-release/modules/exporting
#= require leaflet/dist/leaflet
#= require ./leaflet-override
... | Use relative path for leaflet-override | Use relative path for leaflet-override
| CoffeeScript | mit | GeoSensorWebLab/Arctic-Scholar-Portal,GeoSensorWebLab/asw-workbench,GeoSensorWebLab/Arctic-Scholar-Portal,GeoSensorWebLab/asw-workbench,GeoSensorWebLab/asw-workbench |
b917db40901a5765df359adc0822466765e8cf99 | models/collector_profile.coffee | models/collector_profile.coffee | _ = require 'underscore'
Q = require 'q'
Backbone = require 'backbone'
{ API_URL } = require('sharify').data
Relations = require './mixins/relations/collector_profile.coffee'
module.exports = class CollectorProfile extends Backbone.Model
_.extend @prototype, Relations
url: "#{API_URL}/api/v1/me/collector_profile"... | _ = require 'underscore'
Q = require 'q'
Backbone = require 'backbone'
{ API_URL } = require('sharify').data
Relations = require './mixins/relations/collector_profile.coffee'
module.exports = class CollectorProfile extends Backbone.Model
_.extend @prototype, Relations
url: "#{API_URL}/api/v1/me/collector_profile"... | Expand on hack for valid hash fields | Expand on hack for valid hash fields
| CoffeeScript | mit | TribeMedia/force-public,cavvia/force-1,kanaabe/force,izakp/force,TribeMedia/force-public,joeyAghion/force,erikdstock/force,yuki24/force,eessex/force,kanaabe/force,oxaudo/force,artsy/force-public,cavvia/force-1,damassi/force,erikdstock/force,mzikherman/force,mzikherman/force,damassi/force,joeyAghion/force,anandaroop/for... |
87b81939022e38ade9fec06afe3e40fd822d0afd | apps/show/components/related_shows/index.coffee | apps/show/components/related_shows/index.coffee | _ = require 'underscore'
{ Cities, FeaturedCities } = require 'places'
PartnerShows = require '../../../../collections/partner_shows.coffee'
RelatedShowsView = require './view.coffee'
module.exports = (type, show) ->
city = _.findWhere(Cities, name: show.formatCity())
el = $('.js-related-shows')
criteria =
... | _ = require 'underscore'
{ Cities, FeaturedCities } = require 'places'
PartnerShows = require '../../../../collections/partner_shows.coffee'
RelatedShowsView = require './view.coffee'
module.exports = (type, show) ->
city = _.findWhere(Cities, name: show.formatCity())
el = $('.js-related-shows')
criteria =
... | Change parameters by which shows are selected | Change parameters by which shows are selected
| CoffeeScript | mit | oxaudo/force,xtina-starr/force,mzikherman/force,eessex/force,joeyAghion/force,eessex/force,cavvia/force-1,dblock/force,oxaudo/force,mzikherman/force,yuki24/force,kanaabe/force,artsy/force,artsy/force,eessex/force,izakp/force,izakp/force,mzikherman/force,joeyAghion/force,artsy/force,erikdstock/force,kanaabe/force,dblock... |
c4f6cde31377465420adcfff707e02473eaef229 | src/code/views/modal-view.coffee | src/code/views/modal-view.coffee | {div} = React.DOM
module.exports = React.createClass
displayName: 'Modal'
watchForEscape: (e) ->
if e.keyCode is 27
@props.close?()
# shadow the entire viewport behind the dialog
getDimensions: ->
width: $(window).width() + 'px'
height: $(window).height() + 'px'
getInitialState: ->
... | {div} = React.DOM
module.exports = React.createClass
displayName: 'Modal'
watchForEscape: (e) ->
if e.keyCode is 27
@props.close?()
# shadow the entire viewport behind the dialog
getDimensions: ->
width: '100vw'
height: '100vh'
getInitialState: ->
dimensions = @getDimensions()
i... | Change height and width calculations to just use Viewport Width and Height | Change height and width calculations to just use Viewport Width and Height
| CoffeeScript | mit | concord-consortium/cloud-file-manager,concord-consortium/cloud-file-manager,concord-consortium/cloud-file-manager,concord-consortium/cloud-file-manager |
e2970095810418fcec0c09af6ef0b0b01dfb57b2 | client/src/views/indicator_selector_view.coffee | client/src/views/indicator_selector_view.coffee | window.Backbone ||= {}
window.Backbone.Views ||= {}
class Backbone.Views.IndicatorSelectorView extends Backbone.Diorama.NestingView
template: Handlebars.templates['indicator_selector.hbs']
className: 'modal indicator-selector'
events:
"click .close": "close"
initialize: (options = {}) ->
@currentIndi... | window.Backbone ||= {}
window.Backbone.Views ||= {}
class Backbone.Views.IndicatorSelectorView extends Backbone.Diorama.NestingView
template: Handlebars.templates['indicator_selector.hbs']
className: 'modal indicator-selector'
events:
"click .close": "close"
initialize: (options = {}) ->
@currentIndi... | Make the indicator selector only show indicators with data | Make the indicator selector only show indicators with data
| CoffeeScript | bsd-3-clause | unepwcmc/NRT,unepwcmc/NRT |
4472ba6247b03503b1c5f033135864b1b536a822 | app/assets/javascripts/components/feed_view.coffee | app/assets/javascripts/components/feed_view.coffee | {div} = React.DOM
@FeedView = React.createClass
displayName: 'FeedView'
componentWillMount: ->
Screensmart.store.dispatch Screensmart.Actions.updateResponse()
render: ->
div
className: 'feed'
@props.children.map (child) ->
div
key: child.key
className: 'item'
... | {div} = React.DOM
@FeedView = React.createClass
displayName: 'FeedView'
render: ->
div
className: 'feed'
@props.children.map (child) ->
div
key: child.key
className: 'item'
child
| Fix response loading twice on fill_out start | Fix response loading twice on fill_out start
| CoffeeScript | mit | roqua/screensmart,roqua/screensmart,roqua/screensmart |
431b14aac6c2a7e96859120b18c563b85ccf0704 | client/lanes/components/shared/FieldSet.cjsx | client/lanes/components/shared/FieldSet.cjsx | class Lanes.Components.FieldSet extends Lanes.React.Component
getDefaultProps: ->
speed: 0.4
propTypes:
title: React.PropTypes.string.isRequired
speed: React.PropTypes.number
collapsed: React.PropTypes.bool
getInitialState: ->
state = {
expanded: !@prop... | class Lanes.Components.FieldSet extends Lanes.React.Component
getDefaultProps: ->
expanded: true
propTypes:
title: React.PropTypes.string.isRequired
expanded: React.PropTypes.bool
getInitialState: ->
expanded: @props.expanded
componentWillReceiveProps: (nextProps) ->
... | Use Collapse component vs own logic | Use Collapse component vs own logic
| CoffeeScript | mit | argosity/hippo,argosity/hippo,argosity/lanes,argosity/lanes,argosity/lanes,argosity/hippo |
de7b38b2be40172ff6c4f3cd62aa39a54b0b31e4 | lib/minimap-highlight-selected-view.coffee | lib/minimap-highlight-selected-view.coffee | module.exports = ->
highlightSelectedPackage = atom.packages.getLoadedPackage('highlight-selected')
highlightSelected = require (highlightSelectedPackage.path)
HighlightedAreaView = require (highlightSelectedPackage.path + '/lib/highlighted-area-view')
class FakeEditor
constructor: (@minimap) ->
getA... | module.exports = ->
highlightSelectedPackage = atom.packages.getLoadedPackage('highlight-selected')
highlightSelected = require (highlightSelectedPackage.path)
HighlightedAreaView = require (highlightSelectedPackage.path + '/lib/highlighted-area-view')
class FakeEditor
constructor: (@minimap) ->
getA... | Fix broken plugin since highlight-selected update | :bug: Fix broken plugin since highlight-selected update
Fixes #5
| CoffeeScript | mit | atom-minimap/minimap-highlight-selected |
40f05a5181ffbf55fb3bd092a13386932690dc20 | components/iframe_popover/index.coffee | components/iframe_popover/index.coffee | _ = require 'underscore'
Backbone = require 'backbone'
router = new Backbone.Router
href = null
module.exports = ($el) ->
$el.on 'click', 'a[href]', onClick
# Make sure history is started to use our internal router
Backbone.history.start(pushState: true) unless Backbone.History.started
onClick = (e) ->
e.pre... | _ = require 'underscore'
Backbone = require 'backbone'
router = new Backbone.Router
href = null
module.exports = ($el) ->
$el.on 'click', 'a[href]', onClick
# Make sure history is started to use our internal router
Backbone.history.start(pushState: true) unless Backbone.History.started
onClick = (e) ->
retur... | Allow cmd and ctrl clicks to open links in new tabs | Allow cmd and ctrl clicks to open links in new tabs
| CoffeeScript | mit | artsy/force-public,oxaudo/force,kanaabe/force,anandaroop/force,yuki24/force,damassi/force,izakp/force,izakp/force,dblock/force,TribeMedia/force-public,izakp/force,anandaroop/force,yuki24/force,kanaabe/force,erikdstock/force,mzikherman/force,kanaabe/force,xtina-starr/force,anandaroop/force,xtina-starr/force,kanaabe/forc... |
e583763a8f166f42f177dcb7df9379827ee0ce28 | lib/main-v4.coffee | lib/main-v4.coffee | {CompositeDisposable} = require 'event-kit'
[Minimap, MinimapElement] = []
module.exports =
class V4Main
@includeInto: (base) ->
for k,v of @prototype
base::[k] = v
activateV4: ->
@editorsMinimaps = {}
@subscriptions = new CompositeDisposable
MinimapElement ?= require './minimap-element'
... | {CompositeDisposable} = require 'event-kit'
[Minimap, MinimapElement] = []
module.exports =
class V4Main
@includeInto: (base) ->
for k,v of @prototype
base::[k] = v
activateV4: ->
@editorsMinimaps = {}
@subscriptions = new CompositeDisposable
MinimapElement ?= require './minimap-element'
... | Implement minimap creation observer method for v4 | Implement minimap creation observer method for v4
| CoffeeScript | mit | xndcn/atom-minimap,atom-minimap/minimap |
feb2f9998475038f551f80aaad28e45ba76c42f7 | client/accounts.coffee | client/accounts.coffee | Template.displayIcon.userIconUrl = ->
# TODO: We should specify default URL to the image of an avatar which is generated from name initials
"https://secure.gravatar.com/avatar/#{ Meteor.person()?.gravatarHash }?s=25"
Template._loginButtonsLoggedInDropdownActions.personSlug = ->
Meteor.person()?.slug
# To close ... | Template.displayIcon.userIconUrl = ->
# TODO: We should specify default URL to the image of an avatar which is generated from name initials
"https://secure.gravatar.com/avatar/#{ Meteor.person()?.gravatarHash }?s=25"
Template._loginButtonsLoggedInDropdownActions.personSlug = ->
Meteor.person()?.slug
# To close ... | Check if originalEvent is defined | Check if originalEvent is defined
| CoffeeScript | agpl-3.0 | peerlibrary/peerlibrary,peerlibrary/peerlibrary,peerlibrary/peerlibrary |
13175c7d66a3adf20628d1f9fc5f124b9f4d0e14 | lib/incompatible-packages-status-view.coffee | lib/incompatible-packages-status-view.coffee | _ = require 'underscore-plus'
{View} = require 'atom-space-pen-views'
module.exports =
class IncompatiblePackagesStatusView extends View
@content: ->
@div class: 'incompatible-packages-status inline-block text text-error', =>
@span class: 'icon icon-bug'
@span outlet: 'countLabel', class: 'incompatib... | _ = require 'underscore-plus'
{View} = require 'atom-space-pen-views'
module.exports =
class IncompatiblePackagesStatusView extends View
@content: ->
@div class: 'incompatible-packages-status inline-block text text-error', =>
@span class: 'icon icon-bug'
@span outlet: 'countLabel', class: 'incompatib... | Use new status bar tile API | Use new status bar tile API
| CoffeeScript | mit | atom/incompatible-packages |
a4cde08807d4e7e27d6176078b026b6f1d67ae87 | models/user.coffee | models/user.coffee | # modules
Sequelize = require 'sequelize'
db = require './db'
Team = require './team'
# custom validation constraints
checkUnique = (value, next) ->
User.find
where: $or:
nickname: value
email: value
.then (user) ->
if user then return next 'Ce nom d\'utilisateu... | # modules
Sequelize = require 'sequelize'
db = require './db'
Team = require './team'
# custom validation constraints
checkUnique = (value, next) ->
User.find
where: $or:
nickname: value
email: value
.then (user) ->
if user then return next 'Ce nom d\'utilisateu... | Delete length validation for password | Delete length validation for password
| CoffeeScript | lgpl-2.1 | AlsaceDigitale/straliens-server |
506e866c63ce8914734e9b2c641bc1bced154f6f | src/styles/ui/labels.coffee | src/styles/ui/labels.coffee | label = (fontSize, options = {}) ->
options.font = _.extend {}, options.font or {},
fontSize: fontSize
_.extend {}, options,
height: Ti.UI.SIZE
width: Ti.UI.FILL
color: '#333'
bottom: options.font.fontSize * 0.5 # Similar to bottom margin of 0.5em
heading = (fontSize) ->
label fontSize,
... | label = (fontSize, options = {}) ->
options.font = _.extend {}, options.font or {},
fontSize: fontSize
_.extend {}, options,
height: Ti.UI.SIZE
width: Ti.UI.FILL
color: '#333'
bottom: options.font.fontSize * 0.5 # Similar to bottom margin of 0.5em
heading = (fontSize) ->
label fontSize,
... | Set label height to Ti.UI.SIZE | Set label height to Ti.UI.SIZE | CoffeeScript | mit | vcu/titanium-backbone,trabian/titanium-backbone,trabian/titanium-backbone,vcu/titanium-backbone |
143aa1bbc88a7fd205c814f369720ddab7931f1f | js/coffee/foundation.coffee | js/coffee/foundation.coffee | # handle background tiles
backgroundTile = undefined
tileImg = new Image()
tileImg.onload = ->
backgroundTile = cq().context.createPattern(tileImg,'repeat')
tileImg.src = '/img/tile.png'
drawBackgroundTiles = (ctx) ->
if backgroundTile?
ctx
.rect(0,0, ctx.canvas.width,ctx.canvas.height)
.fillStyle(backg... | # handle background tiles
backgroundTile = undefined
tileImg = new Image()
tileImg.onload = ->
backgroundTile = cq().context.createPattern(tileImg,'repeat')
tileImg.src = './img/tile.png'
drawBackgroundTiles = (ctx) ->
if backgroundTile?
ctx
.rect(0,0, ctx.canvas.width,ctx.canvas.height)
.fillStyle(back... | Make tile path work in GH | Make tile path work in GH
| CoffeeScript | mit | wjagodfrey/spriteBreaker |
ebe4a37079fde21bc40b25238202463a6aa03d5b | src/scripts/pages/app/modals/legacy.coffee | src/scripts/pages/app/modals/legacy.coffee | define (require) ->
$ = require('jquery')
BaseView = require('cs!helpers/backbone/views/base')
template = require('hbs!./legacy-template')
require('less!./legacy')
return class LegacyModal extends BaseView
template: template
events:
'submit': 'onSubmit'
onSubmit: (e) ->
e.preventDef... | define (require) ->
$ = require('jquery')
BaseView = require('cs!helpers/backbone/views/base')
template = require('hbs!./legacy-template')
require('less!./legacy')
require('bootstrapTransition')
require('bootstrapModal')
return class LegacyModal extends BaseView
template: template
events:
... | Add bootstrap modal and transition dependencies | Add bootstrap modal and transition dependencies
| CoffeeScript | agpl-3.0 | katalysteducation/webview,dak/webview,dak/webview,Connexions/webview,dak/webview,carolinelane10/webview,katalysteducation/webview,Connexions/webview,katalysteducation/webview,Connexions/webview,Connexions/webview,katalysteducation/webview |
d50a296d6d8e5c84ccd569c238f1de1792beaab2 | client/Main/navigation/navigationmachineitem.coffee | client/Main/navigation/navigationmachineitem.coffee | class NavigationMachineItem extends JView
{Running, Stopped} = Machine.State
stateClasses = ''
stateClasses += "#{state.toLowerCase()} " for state in Object.keys Machine.State
constructor:(options = {}, data)->
machine = data
@alias = machine.label
path = K... | class NavigationMachineItem extends JView
{Running, Stopped} = Machine.State
stateClasses = ''
stateClasses += "#{state.toLowerCase()} " for state in Object.keys Machine.State
constructor:(options = {}, data)->
machine = data
@alias = machine.getName()
path ... | Use `machine.getName()` instead of `machine.label` | NavigationMachineItem: Use `machine.getName()` instead of `machine.label`
| CoffeeScript | agpl-3.0 | kwagdy/koding-1,gokmen/koding,gokmen/koding,drewsetski/koding,gokmen/koding,sinan/koding,koding/koding,acbodine/koding,drewsetski/koding,acbodine/koding,andrewjcasal/koding,rjeczalik/koding,kwagdy/koding-1,gokmen/koding,andrewjcasal/koding,drewsetski/koding,rjeczalik/koding,andrewjcasal/koding,szkl/koding,gokmen/koding... |
fab2dbbe6ab59cb045d6b5381280687e49c17777 | scripts/resume.coffee | scripts/resume.coffee | module.exports = (robot) ->
names = ['Dana', 'Freia', 'Jhishan', 'Kyle', 'Brenton', 'Terri', 'Abhi', 'Drew']
robot.hear /Resume queen, who is next\?/i, (res) ->
res.send res.random names
| module.exports = (robot) ->
names = ['Dana', 'Freia', 'Jhishan', 'Kyle', 'Brenton', 'Terri', 'Abhi', 'Drew']
names = ['@danagilliann', '@flobot', '@jhishan', '@kwhughes', '@brentdur', '@terriburns', '@abhiagarwal', '@nydrewreynolds']
robot.hear /Resume queen, who is next\?/i, (res) ->
res.send res.random name... | Change first names to slack handles | Change first names to slack handles
| CoffeeScript | mit | TechAtNYU/hubu |
41903dd03ca50158b8e5844b4bf787139a8b9f03 | core/app/backbone/models/argument_votes.coffee | core/app/backbone/models/argument_votes.coffee | class window.ArgumentVotes extends Backbone.Model
defaults:
believes: 0
disbelieves: 0
isNew: -> @_argument.isNew()
initialize: (attributes, options) ->
@_argument = options.argument
url: ->
@_argument.url() + '/opinion'
setCurrentUserOpinion: (newOpinion) ->
previousOpinion = @get('cu... | class window.ArgumentVotes extends Backbone.Model
defaults:
believes: 0
disbelieves: 0
isNew: -> @_argument.isNew()
initialize: (attributes, options) ->
@_argument = options.argument
@_argument.on 'change:argument_votes', =>
@set @_argument.get('argument_votes')
url: ->
@_argument.... | Update ArgumentVotes when the argument changes | Update ArgumentVotes when the argument changes
| CoffeeScript | mit | Factlink/factlink-core,Factlink/factlink-core,daukantas/factlink-core,daukantas/factlink-core,Factlink/factlink-core,Factlink/factlink-core,daukantas/factlink-core,daukantas/factlink-core |
4e92d823056ee840830c2e137347a6c64a60b820 | app.coffee | app.coffee | Settings = require "settings-sharelatex"
logger = require "logger-sharelatex"
logger.initialize("track-changes")
HttpController = require "./app/js/HttpController"
express = require "express"
app = express()
app.use express.logger()
app.post "/doc/:doc_id/flush", HttpController.flushUpdatesWithLock
app.use (error, ... | Settings = require "settings-sharelatex"
logger = require "logger-sharelatex"
logger.initialize("track-changes")
HttpController = require "./app/js/HttpController"
express = require "express"
app = express()
app.use express.logger()
app.post "/doc/:doc_id/flush", HttpController.flushUpdatesWithLock
app.get "/status... | Add in /status end point | Add in /status end point
| CoffeeScript | agpl-3.0 | sharelatex/track-changes-sharelatex,sharelatex/track-changes-sharelatex |
6720deb81438cce2105d6019bdf0514050e4d415 | scripts/views/workspace/content/content-edit.coffee | scripts/views/workspace/content/content-edit.coffee | define [
'jquery'
'underscore'
'backbone'
'marionette'
'cs!views/workspace/content/aloha-edit'
'hbs!templates/workspace/content/content-edit'
], ($, _, Backbone, Marionette, AlohaEditView, contentEditTemplate) ->
# Edit Content Body
# -------
return AlohaEditView.extend
# **NOTE:** This template ... | define [
'jquery'
'underscore'
'backbone'
'marionette'
'cs!views/workspace/content/aloha-edit'
'hbs!templates/workspace/content/content-edit'
'bootstrapPopover'
], ($, _, Backbone, Marionette, AlohaEditView, contentEditTemplate) ->
# Edit Content Body
# -------
return AlohaEditView.extend
# **N... | Enable popovers in content editor | Enable popovers in content editor
| CoffeeScript | agpl-3.0 | oerpub/github-bookeditor,oerpub/github-bookeditor,oerpub/github-bookeditor,oerpub/bookish,oerpub/bookish |
95630d654626b301f51f8a654cc134bcbaf56e17 | app/assets/javascripts/followable.js.coffee | app/assets/javascripts/followable.js.coffee | App.Followable =
initialize: ->
$('.followable-content a[data-toggle]').on 'click', (event) ->
event.preventDefault()
update: (followable_id, button) ->
$("#" + followable_id + " .js-follow").html(button)
initialize_modules()
| App.Followable =
initialize: ->
$('.followable-content a[data-toggle]').on 'click', (event) ->
event.preventDefault()
update: (followable_id, button) ->
$("#" + followable_id + " .js-follow").html(button)
# Temporary line. Waiting for issue resolution: https://github.com/consul/consul/issues/173... | Add comment to temporary bugfix. | Add comment to temporary bugfix.
| CoffeeScript | agpl-3.0 | AyuntamientoPuertoReal/decidePuertoReal,artofhuman/consul,AyuntamientoPuertoReal/decidePuertoReal,CDJ11/CDJ,AyuntamientoMadrid/participacion,consul/consul,usabi/consul_san_borondon,AjuntamentdeCastello/consul,consul/consul,AyuntamientoMadrid/participacion,deivid-rodriguez/participacion,AyuntamientoMadrid/consul,Ayuntam... |
c15df79541cc7308400f2d129f2a397fa01da3a3 | client/helpers.coffee | client/helpers.coffee | isActive = (type, inverse = false) ->
name = 'is'
name = name + 'Not' if inverse
name = name + _.capitalize type
(view) ->
unless view instanceof Spacebars.kw
throw new Error "#{name} options must be key value pair such " +
"as {{#{name} regex='route/path'}}. You passed: " +
"#{JSON.s... | isActive = (type, inverse = false) ->
name = 'is'
name = name + 'Not' if inverse
name = name + 'Active' + _.capitalize type
(view) ->
unless view instanceof Spacebars.kw
throw new Error "#{name} options must be key value pair such " +
"as {{#{name} regex='route/path'}}. You passed: " +
... | Fix name of helper in error message | Fix name of helper in error message
| CoffeeScript | mit | zimme/meteor-active-route,dropfen/meteor-active-route,cafe4it/meteor-active-route |
fd42c59a5158c8c98e506b8d4e37d372db84a7f1 | client/helpers.coffee | client/helpers.coffee | # check for subscriptions to be ready
subsReady = (subs...) ->
return FlowRouter.subsReady() if subs.length is 1
subs = subs.slice(0, subs.length - 1)
_.reduce subs, (memo, sub) ->
memo and FlowRouter.subsReady(sub)
, true
# return path
pathFor = (path, view) ->
throw new Error('no path defined') unless ... | # check for subscriptions to be ready
subsReady = (subs...) ->
return FlowRouter.subsReady() if subs.length is 1
subs = subs.slice(0, subs.length - 1)
_.reduce subs, (memo, sub) ->
memo and FlowRouter.subsReady(sub)
, true
# return path
pathFor = (path, view) ->
throw new Error('no path defined') unless ... | Add hashbang option to pathFor | Add hashbang option to pathFor
| CoffeeScript | mit | arillo/meteor-flow-router-helpers,arillo/meteor-flow-router-helpers |
e9e3e4aa871f3ceecddf168aa611e2366be3f303 | src/Witness/_witness/Scripts/witness-ui/ScenarioViewModel.coffee | src/Witness/_witness/Scripts/witness-ui/ScenarioViewModel.coffee | # reference "_namespace.coffee"
# reference "PartViewModel.coffee"
{ PartViewModel } = @witness.ui
@witness.ui.ScenarioViewModel = class ScenarioViewModel
constructor: (@scenario) ->
{ @path, @url } = @scenario.parentSpecification.parentFile
@parts = (new PartViewModel part for part in [].concat @scena... | # reference "_namespace.coffee"
# reference "PartViewModel.coffee"
{ PartViewModel } = @witness.ui
@witness.ui.ScenarioViewModel = class ScenarioViewModel
constructor: (@scenario) ->
{ @path, @url } = @scenario.parentSpecification.parentFile
@parts = (new PartViewModel part for part in [].concat @scena... | Clear errors when re-running a scenario. | Clear errors when re-running a scenario.
| CoffeeScript | bsd-2-clause | andrewdavey/witness,andrewdavey/witness,andrewdavey/witness |
d52bb159aa68c0355310403d6048cdf254a50b8b | keymaps/agda-mode.cson | keymaps/agda-mode.cson | # Keybindings require three things to be fully defined: A selector that is
# matched against the focused element, the keystroke and the command to
# execute.
#}
# Below is a basic keybinding which registers on all platforms by applying to
# the root workspace element.
# For more detailed documentation see
# https://at... | # Keybindings require three things to be fully defined: A selector that is
# matched against the focused element, the keystroke and the command to
# execute.
#}
# Below is a basic keybinding which registers on all platforms by applying to
# the root workspace element.
# For more detailed documentation see
# https://at... | Use the atom-text-editor tag instead of the editor class. | Use the atom-text-editor tag instead of the editor class.
| CoffeeScript | mit | banacorn/agda-mode,banacorn/agda-mode,banacorn/agda-mode |
fb4af1b9a1fa60370769e7b8bd4126e1f6f073b6 | src/scripts/code-name-generator.coffee | src/scripts/code-name-generator.coffee | # Description:
# Generate code names for things
#
# Dependencies:
# None
#
# Configuration:
# None
#
# Commands:
# hubot codename - Generates a few potential codenames for you
#
# Author:
# Scott J Roberts - @sroberts
api_url = "https://gist.github.com"
request_url = api_url + "/sroberts/6529712/raw/1e979071... | # Description:
# Generate code names for things
#
# Dependencies:
# None
#
# Configuration:
# None
#
# Commands:
# hubot codename - Generates a few potential codenames for you
#
# Author:
# Scott J Roberts - @sroberts
api_url = "https://gist.githubusercontent.com"
request_url = api_url + "/sroberts/6529712/r... | Change api_url to reflect Gist raw file URI change | Change api_url to reflect Gist raw file URI change
https://developer.github.com/changes/2014-02-21-gist-raw-file-url-change/ | CoffeeScript | mit | sroberts/hubot-vtr-scripts,sroberts/hubot-vtr-scripts |
8ff71a7e97af7a3b5ba1b1a16d1265a52d1227f8 | client/views/CalendarItem.coffee | client/views/CalendarItem.coffee | Template.CalendarItem.helpers
style: ->
user = Meteor.user()
styles = []
itemStatus = user?.grade?[@gradeItem._id]
itemStatus ?= 'pending'
switch itemStatus
when 'done'
styles.push 'color: lightgray'
when 'doing'
styles.push 'color: orange'
return styles.join '; '
canMarkInterrest: ->
... | Template.CalendarItem.helpers
style: ->
user = Meteor.user()
styles = []
itemStatus = user?.grade?[@gradeItem._id]
itemStatus ?= 'pending'
switch itemStatus
when 'done'
styles.push 'color: lightgray'
when 'doing'
styles.push 'color: orange'
return styles.join '; '
canMarkInterrest: ->
... | Allow to mark interrest in doing subjects | Allow to mark interrest in doing subjects
| CoffeeScript | mit | rodrigok/GradeFaccat,rodrigok/GradeFaccat |
2977e445b7a33ffaec34fa7120e102d59441abea | vendor/assets/javascripts/editable/rails/editable_form.js.coffee | vendor/assets/javascripts/editable/rails/editable_form.js.coffee | unless EditableForm
EditableForm = $.fn.editableform.Constructor
EditableForm.prototype.saveWithUrlHook = (value) ->
originalUrl = @options.url
model = @options.model
nestedName = @options.nested
nestedId = @options.nid
nestedLocale = @options.locale
@options.url = (param... | unless EditableForm
EditableForm = $.fn.editableform.Constructor
EditableForm.prototype.saveWithUrlHook = (value) ->
originalUrl = @options.url
model = @options.model
nestedName = @options.nested
nestedId = @options.nid
nestedLocale = @options.locale
@options.url = (param... | Use the value as parameter when the myName field does not exist | Use the value as parameter when the myName field does not exist | CoffeeScript | mit | krsmurata/x-editable-rails,krsmurata/x-editable-rails |
eaf8a754febddae11fc4ba44c3a965ed917232f6 | app/lib/subjects.coffee | app/lib/subjects.coffee | class Subjects
queue: []
api: null
query:
sort: 'queued'
page_size: "30"
constructor: (@api, @project, @subject_set_id)->
@query.workflow_id = @project?.links.workflows[0]
@query.subject_set_id = @subject_set_id
update: (opts) ->
@[opt] = value for opt, value of opts
@query.workf... | class Subjects
queue: []
api: null
current: null
query:
sort: 'queued'
page_size: "30"
constructor: (@api, @project, @subject_set_id)->
@query.workflow_id = @project?.links.workflows[0]
@query.subject_set_id = @subject_set_id
update: (opts) ->
@[opt] = value for opt, value of opts
... | Fix incorrect reporting of current subject | Fix incorrect reporting of current subject
| CoffeeScript | apache-2.0 | zooniverse/wellcome,zooniverse/wellcome |
4d25ffd5f558f718a60b082a303eb1bb317ffdda | app/assets/javascripts/backbone/views/transition_view.js.coffee | app/assets/javascripts/backbone/views/transition_view.js.coffee |
class UIDemo.Views.TransitionView extends Backbone.View
transitionRemoveClass: (className, $el = @$el) ->
p = @_transitionPromise($el)
@_delay(=> $el.removeClass className).then -> p
transitionAddClass: (className, $el = @$el) ->
p = @_transitionPromise($el)
@_delay(=> $el.addClass className).the... |
class UIDemo.Views.TransitionView extends Backbone.View
transitionRemoveClass: (className, $el = @$el) ->
p = @_transitionPromise($el)
@_delay(=> $el.removeClass className).then -> p
transitionAddClass: (className, $el = @$el) ->
p = @_transitionPromise($el)
@_delay(=> $el.addClass className).the... | Remove asynchronous working if transitions are disabled | Remove asynchronous working if transitions are disabled
| CoffeeScript | mit | matthijsgroen/backbone-ui-transitions-demo,matthijsgroen/backbone-ui-transitions-demo |
d9095d06830f23b030a8e47a031310756863daae | app/assets/javascripts/lib/managers/select_group_manager.js.coffee | app/assets/javascripts/lib/managers/select_group_manager.js.coffee | define ['jquery'], ($) ->
class SelectGroup
constructor: (@parent = null, @callback = false) ->
@selectParent = (if @parent != null then $(@parent) else $('.js-select-group'))
@addHandlers()
addHandlers: ->
@selectParent.on 'focus', '.js-select', (e) =>
@getOverlay(e.target).addCl... | define ['jquery'], ($) ->
class SelectGroup
constructor: (@parent = null, @callback = false) ->
@selectParent = (if @parent != null then $(@parent) else $('.js-select-group'))
@selectParent.find('.js-select').each (eltIndex) =>
@setOverlay(@selectParent[eltIndex])
@addHandlers()
a... | Set the value of the overlay on initialition | Set the value of the overlay on initialition
| CoffeeScript | mit | lonelyplanet/rizzo,Lostmyname/rizzo,lonelyplanet/rizzo,lonelyplanet/rizzo,Lostmyname/rizzo,lonelyplanet/rizzo,Lostmyname/rizzo,Lostmyname/rizzo,lonelyplanet/rizzo,Lostmyname/rizzo |
07fa460c4366affee197675c30ab27b721948f4f | client/app/lib/flux/actions/user.coffee | client/app/lib/flux/actions/user.coffee | kd = require 'kd'
actions = require './actiontypes'
fetchAccount = require 'app/util/fetchAccount'
dispatch = (args...) -> kd.singletons.reactor.dispatch args...
###*
* Load account with given id.
*
* @param {string} id
###
loadAccount = (id) ->
origin = generateOrigin id
dispatch actions.LOA... | kd = require 'kd'
actions = require './actiontypes'
fetchAccount = require 'app/util/fetchAccount'
###*
* Load account with given id.
*
* @param {string} id
###
loadAccount = (id) ->
origin = generateOrigin id
{ reactor } = kd.singletons
reactor.dispatch actions.LOAD_USER_BEGIN, { id, origi... | Use reactor directly inside of action | app: Use reactor directly inside of action
| CoffeeScript | agpl-3.0 | kwagdy/koding-1,cihangir/koding,usirin/koding,mertaytore/koding,cihangir/koding,drewsetski/koding,cihangir/koding,acbodine/koding,sinan/koding,mertaytore/koding,jack89129/koding,jack89129/koding,koding/koding,gokmen/koding,usirin/koding,sinan/koding,szkl/koding,koding/koding,alex-ionochkin/koding,alex-ionochkin/koding,... |
f38c370ba973efc90300f9d7b0b6838c05776d3d | lib/find-results-view.coffee | lib/find-results-view.coffee | _ = require 'underscore-plus'
{EditorView, View} = require 'atom'
MarkerView = require './marker-view'
module.exports =
class FindResultsView extends View
@content: ->
@div class: 'search-results'
initialize: (@findModel) ->
@markerViews = {}
@subscribe @findModel, 'updated', (args...) => @markersUpd... | _ = require 'underscore-plus'
{EditorView, View} = require 'atom'
MarkerView = require './marker-view'
# TODO: remove this when marker views are in core. Hopefully soon.
module.exports =
class FindResultsView extends View
@content: ->
@div class: 'search-results'
initialize: (@findModel) ->
@markerViews... | Fix error with FindResultsView attachment and update on react editor | Fix error with FindResultsView attachment and update on react editor
When you’d split-open a file, the react editor wasn’t attached or
rendered yet. So there was no under layer, and when you’d try to request
a display update, it would call functions on objects that weren’t there.
So I hack this with a delay. This is... | CoffeeScript | mit | harai/find-and-replace,atom/find-and-replace,bmperrea/find-and-replace,trevdor/find-and-replace |
f5575743b63cb6eb5f4c11ccf28898b5225b3910 | atom/packages.cson | atom/packages.cson | packages: [
"advanced-open-file"
"atom-alignment"
"atom-beautify"
"atom-transpose"
"change-case"
"color-picker"
"docblockr"
"editorconfig"
"emmet"
"expand-region"
"language-apache"
"language-applescript"
"language-awk"
"language-babel"
"language-diff"
"language-env"
"language-gitattrib... | packages: [
"advanced-open-file"
"atom-alignment"
"atom-beautify"
"atom-transpose"
"change-case"
"color-picker"
"docblockr"
"editorconfig"
"emmet"
"expand-region"
"git-blame"
"language-apache"
"language-applescript"
"language-awk"
"language-babel"
"language-diff"
"language-env"
"lang... | Add git-blame to Atom package list | Add git-blame to Atom package list
| CoffeeScript | mit | caleb531/dotfiles,caleb531/dotfiles,caleb531/dotfiles,caleb531/dotfiles |
5a0b823397ea4219fe773363e397bfe382acde33 | src/components/contextmenu/contextmenuitem.coffee | src/components/contextmenu/contextmenuitem.coffee | KDView = require './../../core/view.coffee'
JTreeItemView = require './../tree/treeitemview.coffee'
module.exports = class JContextMenuItem extends JTreeItemView
constructor:(options = {}, data = {})->
options.type = "contextitem"
options.cssClass or= "default"
super options, data
@u... | KDView = require './../../core/view.coffee'
JTreeItemView = require './../tree/treeitemview.coffee'
module.exports = class JContextMenuItem extends JTreeItemView
constructor:(options = {}, data = {})->
options.type = "contextitem"
options.cssClass or= "default #{KD.utils.slugify data.title}"
... | Add slugified title as class name to context menu items. | ContextMenu: Add slugified title as class name to context menu items.
| CoffeeScript | mit | anonrig/kd,gokhanturunc/kd,anonrig/kd,gokhanturunc/kd,koding/kd |
ff1024c2a9735548a803a91dde643b9c72b47ae1 | coffee/document.coffee | coffee/document.coffee | "use strict"
ObjectID = require('mongodb').ObjectID
exports.param = (req, res, next, id) ->
return res.json 400, error: 'Invalid ObjectID' if not /[a-f0-9]{24}/.test id
req.id = ObjectID.createFromHexString id
next()
exports.options = (req, res, next) ->
res.setHeader 'Access-Control-Allow-Methods', 'GET, PU... | "use strict"
ObjectID = require('mongodb').ObjectID
exports.param = (req, res, next, id) ->
return res.json 400, error: 'Invalid ObjectID' if not /^[a-f0-9]{24}$/.test id
req.id = ObjectID.createFromHexString id
next()
exports.options = (req, res, next) ->
res.setHeader 'Access-Control-Allow-Methods', 'GET, ... | Fix ObjectID hex string validation | Fix ObjectID hex string validation
| CoffeeScript | mit | Turistforeningen/Turbasen,Turbasen/Turbasen |
7d2896ab972eaddbb24a408d5cb505e7badeb356 | src/index.coffee | src/index.coffee | hl = require 'highlight.js'
mousetrap = require 'mousetrap'
$ = require 'zeptojs'
processor = require './slide-pack-processor'
ui = require './slide-pack-ui'
executeHooks = ->
if f = window._slide_pack_process_slides
f $('.slide')
$('[data-slide-pack]').each ->
slides = processor.process $(@).html()
$art... | hl = require 'highlight.js'
mousetrap = require 'mousetrap'
$ = require 'zeptojs'
processor = require './slide-pack-processor'
ui = require './slide-pack-ui'
executeHooks = ->
if f = window._slide_pack_process_slides
f $('.slide')
$('[data-slide-pack]').each ->
$slidePack = $(@)
slides = processor.process... | Remove specific CSS classes for slides and slide-pack | Remove specific CSS classes for slides and slide-pack
| CoffeeScript | mit | trabe/slide-pack,trabe/slide-pack |
9c97cc67f384ab942d9085068bd86ab1c89cd08e | lib/all-headers.coffee | lib/all-headers.coffee | # s2.2.5.3
# For now, only the "Transaction Descriptor" header (s2.2.5.3.2) is supported.
TYPE =
QUERY_NOTIFICATIONS: 1
TXN_DESCRIPTOR: 2
TRACE_ACTIVITY: 3
TXNDESCRIPTOR_HEADER_DATA_LEN = 4 + 8
TXNDESCRIPTOR_HEADER_LEN = 4 + 2 + TXNDESCRIPTOR_HEADER_DATA_LEN
module.exports = (txnDescriptor, outstandingRequest... | # s2.2.5.3
# For now, only the "Transaction Descriptor" header (s2.2.5.3.2) is supported.
WritableTrackingBuffer = require('../lib/tracking-buffer/tracking-buffer').WritableTrackingBuffer
TYPE =
QUERY_NOTIFICATIONS: 1
TXN_DESCRIPTOR: 2
TRACE_ACTIVITY: 3
TXNDESCRIPTOR_HEADER_DATA_LEN = 4 + 8
TXNDESCRIPTOR_HEAD... | Use WritableTrackingBuffer to simplify the creation of AllHeaders. | Use WritableTrackingBuffer to simplify the creation of AllHeaders.
| CoffeeScript | mit | pekim/tedious,arthurschreiber/tedious,tediousjs/tedious,tediousjs/tedious,Sage-ERP-X3/tedious,LeanKit-Labs/tedious,spanditcaa/tedious |
7fa6879edb5f2c2b4d4389b76b35316728b75453 | src/type.coffee | src/type.coffee | {ArgumentError, NotImplementedError} = require './errors'
#
# 'Abstract' class for Finitio types
#
class Type
constructor: (@name)->
if @name? and typeof(@name) isnt "string"
throw new ArgumentError("String expected, got", @name)
@name ?= @defaultName()
#
# Dress `value` with this information ty... | {ArgumentError, NotImplementedError, TypeError} = require './errors'
#
# 'Abstract' class for Finitio types
#
class Type
constructor: (@name)->
if @name? and typeof(@name) isnt "string"
throw new ArgumentError("String expected, got", @name)
@name ?= @defaultName()
#
# Returns true if `value` is ... | Document Type's public API a little bit. | Document Type's public API a little bit.
| CoffeeScript | mit | llambeau/finitio.js,llambeau/finitio.js |
3e8de2d22d8ce74cc0f7ed99c03a71fb73c7b1ca | tasks/test-task.coffee | tasks/test-task.coffee | path = require 'path'
module.exports = (grunt) ->
{spawn} = require('./task-helpers')(grunt)
grunt.registerTask 'test', 'Run the specs', ->
done = @async()
commands = []
commands.push (callback) ->
spawn cmd: 'pkill', args: ['Atom'], -> callback()
commands.push (callback) ->
atomBinary... | path = require 'path'
module.exports = (grunt) ->
{spawn} = require('./task-helpers')(grunt)
grunt.registerTask 'test', 'Run the specs', ->
done = @async()
commands = []
commands.push (callback) ->
spawn cmd: 'pkill', args: ['Atom'], -> callback()
commands.push (callback) ->
atomBinary... | Use config to retrieve contents directory | Use config to retrieve contents directory
| CoffeeScript | mit | RuiDGoncalves/atom,liuderchi/atom,Dennis1978/atom,deoxilix/atom,rjattrill/atom,Galactix/atom,isghe/atom,FoldingText/atom,einarmagnus/atom,rjattrill/atom,rjattrill/atom,bcoe/atom,stinsonga/atom,brettle/atom,me6iaton/atom,darwin/atom,fedorov/atom,daxlab/atom,Austen-G/BlockBuilder,Klozz/atom,SlimeQ/atom,davideg/atom,darwi... |
85e416d53e061b3ee53759a2ce1229e87215321c | app/assets/javascripts/application-admin.js.coffee | app/assets/javascripts/application-admin.js.coffee | #= require jquery
#= require jquery_ujs
#= require bootstrap-sprockets
#= require_tree ./admin
| #= require jquery
#= require jquery_ujs
#= require bootstrap-sprockets
| Remove useless empty admin JS require | Remove useless empty admin JS require
| CoffeeScript | mit | bitzesty/qae,bitzesty/qae,bitzesty/qae,bitzesty/qae |
056bb6b0f49e98a5d44e05e14944d8fdfbbb44f7 | services/web/app/coffee/Features/Analytics/AnalyticsManager.coffee | services/web/app/coffee/Features/Analytics/AnalyticsManager.coffee | Settings = require "settings-sharelatex"
logger = require "logger-sharelatex"
_ = require "underscore"
if !Settings.analytics?.postgres?
module.exports =
recordEvent: (user_id, event, metadata, callback = () ->) ->
logger.log {user_id, event, metadata}, "no event tracking configured, logging event"
callback()... | Settings = require "settings-sharelatex"
logger = require "logger-sharelatex"
_ = require "underscore"
if !Settings.analytics?.postgres?
module.exports =
recordEvent: (user_id, event, metadata, callback = () ->) ->
logger.log {user_id, event, metadata}, "no event tracking configured, logging event"
callback()... | Use a JSON column for metadata | Use a JSON column for metadata
| CoffeeScript | agpl-3.0 | sharelatex/sharelatex |
3d1133eb6ae24f30a6b0ed5d88aa2bbeb23d331f | coffeescript/object_example.coffee | coffeescript/object_example.coffee | circle =
radius: 3
center:
x: 5
y: 4
color: 'green'
thickness: 2
lineStyle: 'dashed'
| circle =
radius: 3
center:
x: 5
y: 4
color: 'green'
fillColor: 'pink'
thickness: 2
lineStyle: 'dashed'
| Make some CoffeeScript examples more interesting | Make some CoffeeScript examples more interesting
| CoffeeScript | mit | rtoal/ple,rtoal/ple,rtoal/polyglot,rtoal/ple,rtoal/ple,rtoal/polyglot,rtoal/ple,rtoal/polyglot,rtoal/ple,rtoal/ple,rtoal/polyglot,rtoal/polyglot,rtoal/polyglot,rtoal/ple,rtoal/polyglot,rtoal/ple,rtoal/polyglot,rtoal/ple,rtoal/polyglot,rtoal/ple,rtoal/ple,rtoal/ple,rtoal/polyglot,rtoal/polyglot,rtoal/polyglot,rtoal/poly... |
12aa35f83f9a8fe38388afdccb40c73af9a4311b | src/buffered-node-process.coffee | src/buffered-node-process.coffee | BufferedProcess = require 'buffered-process'
path = require 'path'
# Private: Like BufferedProcess, but accepts a node script instead of an
# executable, on Unix which allows running scripts and executables, this seems
# unnecessary, but on Windows we have to separate scripts from executables since
# it doesn't suppor... | BufferedProcess = require 'buffered-process'
path = require 'path'
# Private: Like BufferedProcess, but accepts a node script instead of an
# executable, on Unix which allows running scripts and executables, this seems
# unnecessary, but on Windows we have to separate scripts from executables since
# it doesn't suppor... | Make BufferedNodeProcess adapt to changes of atom-shell v0.4.4. | Make BufferedNodeProcess adapt to changes of atom-shell v0.4.4.
| CoffeeScript | mit | prembasumatary/atom,mostafaeweda/atom,harshdattani/atom,Austen-G/BlockBuilder,dannyflax/atom,0x73/atom,medovob/atom,vcarrera/atom,vjeux/atom,tisu2tisu/atom,alexandergmann/atom,pkdevbox/atom,gontadu/atom,jtrose2/atom,jacekkopecky/atom,seedtigo/atom,dannyflax/atom,0x73/atom,Dennis1978/atom,jtrose2/atom,dsandstrom/atom,De... |
d56f2d32b8112820a82734db035ac66b5802277b | gulp/specs.coffee | gulp/specs.coffee | mocha = require 'gulp-mocha'
gutil = require 'gulp-util'
webpack = require 'webpack-stream'
runSequence = require 'run-sequence'
karma = require 'gulp-karma'
require 'coffee-loader'
module.exports = (gulp) ->
gulp.task 'specs', (next) ->
runSequence 'specs:server', 'specs:client', next
gulp.task 'specs:cli... | mocha = require 'gulp-mocha'
gutil = require 'gulp-util'
webpack = require 'webpack-stream'
runSequence = require 'run-sequence'
karma = require 'gulp-karma'
require 'coffee-loader'
module.exports = (gulp) ->
gulp.task 'specs', (next) ->
runSequence 'specs:server', 'specs:client', next
gulp.task 'specs:cli... | Fix globs for spec tasks, make sure spec_setup always comes first | Gulp: Fix globs for spec tasks, make sure spec_setup always comes first
| CoffeeScript | mit | efacilitation/eventric |
0f403074c10820fdc9c2110c579d5fa6f51e9b18 | resource_helper.coffee | resource_helper.coffee | ExpressHttpResource = require 'bloops/adapters/express_resource'
MongooseAdapter = require 'bloops/adapters/mongoose_adapter'
models = require('./db').models
filters = require 'bloops/filters'
cors = require 'cors'
class BaseResource extends ExpressHttpResource
adapter: MongooseAdapter
context:
models: models... | ExpressHttpResource = require 'bloops/adapters/express_resource'
MongooseAdapter = require 'bloops/adapters/mongoose_adapter'
models = require('./db').models
filters = require 'bloops/filters'
cors = require 'cors'
class BaseResource extends ExpressHttpResource
adapter: MongooseAdapter
context:
models: models... | Use provided middleware in resources by default | Use provided middleware in resources by default
| CoffeeScript | mit | bosgood/votewithme-server |
58281da6c2123458a0c3e6999bb90d0d41ce6dcd | web/src/views/main-menu.cjsx | web/src/views/main-menu.cjsx | require 'semantic-ui-css/components/icon.css'
require 'semantic-ui-css/components/menu.css'
require 'semantic-ui-css/components/sidebar.css'
require '../../css/menu.css'
api = require '../backend.coffee'
React = require 'react'
module.exports = React.createClass
displayName: 'MainMenu'
render: ->
act... | require 'semantic-ui-css/components/icon.css'
require 'semantic-ui-css/components/menu.css'
require 'semantic-ui-css/components/sidebar.css'
require '../../css/menu.css'
api = require '../backend.coffee'
React = require 'react'
module.exports = React.createClass
displayName: 'MainMenu'
render: ->
act... | Add comment for later menu entries | Add comment for later menu entries
| CoffeeScript | mit | foobert/gc,foobert/gc,foobert/gc,foobert/gc |
c7b9c1a9fb8ec37ae68de5cfb1099aaf80035f9e | konecty:nrr.coffee | konecty:nrr.coffee | if Package.templating?
Template = Package.templating.Template
Blaze = Package.blaze.Blaze
Blaze.toHTMLWithDataNonReactive = (content, data) ->
makeCursorReactive = (obj) ->
if obj instanceof Meteor.Collection.Cursor
obj._depend
added: true
removed: true
changed: true
makeCursorReactive da... | if Package.templating?
Template = Package.templating.Template
Blaze = Package.blaze.Blaze
HTML = Package.htmljs.HTML
Blaze.toHTMLWithDataNonReactive = (content, data) ->
makeCursorReactive = (obj) ->
if obj instanceof Meteor.Collection.Cursor
obj._depend
added: true
removed: true
changed: t... | Change from simple helper to block to allow track render | Change from simple helper to block to allow track render
| CoffeeScript | mit | Konecty/meteor-nrr |
5f84ef3459fe61dc9a58f5253a51bc1ce34ad581 | lib/js_refactor.coffee | lib/js_refactor.coffee | Ripper = require './ripper'
NotificationView = require './notification-view'
{ packages: packageManager } = atom
module.exports =
activate: ->
return if 'refactor' in packageManager.getAvailablePackageNames() and
!packageManager.isPackageDisabled 'refactor'
new NotificationView
deactivate: -... | Ripper = require './ripper'
NotificationView = require './notification_view'
{ packages: packageManager } = atom
module.exports =
activate: ->
return if 'refactor' in packageManager.getAvailablePackageNames() and
!packageManager.isPackageDisabled 'refactor'
new NotificationView
deactivate: -... | Rename filename to snake case | Rename filename to snake case
| CoffeeScript | mit | hax/js-refactor,minodisk/js-refactor,minodisk/js-refactor |
c510afa3f14cb2a53a42ad267c039c44cb7b8316 | lib/table-edit.coffee | lib/table-edit.coffee |
module.exports =
activate: (state) ->
atom.workspaceView.command 'table-edit:demo', ->
Table = require './table'
TableView = require './table-view'
table = new Table
table.addColumn 'key'
table.addColumn 'value'
table.addColumn 'foo'
for i in [0...100]
table.a... |
module.exports =
activate: (state) ->
atom.workspaceView.command 'table-edit:demo', ->
Table = require './table'
TableView = require './table-view'
table = new Table
table.addColumn 'key'
table.addColumn 'value', align: 'right'
table.addColumn 'foo', align: 'right'
fo... | Add an alignment on columns in demo table | Add an alignment on columns in demo table
| CoffeeScript | mit | abe33/atom-tablr |
fdb7363575bd69172a6672b9c337c6e2ffdf4877 | lib/side-view.coffee | lib/side-view.coffee | {View, $} = require 'atom'
module.exports =
class SideView extends View
@content: (side) ->
@div class: "side #{side.klass()} ui-site-#{side.site()}", =>
@div class: 'controls', =>
@label class: 'text-highlight', side.ref
@span class: 'text-subtle', "// #{side.description()}"
@butto... | {View, $} = require 'atom'
module.exports =
class SideView extends View
@content: (side) ->
@div class: "side #{side.klass()} ui-site-#{side.site()}", =>
@div class: 'controls', =>
@label class: 'text-highlight', side.ref
@span class: 'text-subtle', "// #{side.description()}"
@butto... | Add the appropriate line class. | Add the appropriate line class.
| CoffeeScript | mit | smashwilson/merge-conflicts,antcodd/merge-conflicts,smashwilson/merge-conflicts |
da1d5cd8128f2f08fcdffc715662f5b21a32ebba | app/assets/volume/editLinks.coffee | app/assets/volume/editLinks.coffee | 'use strict'
app.directive 'volumeEditLinksForm', [
'pageService',
(page) ->
restrict: 'E',
templateUrl: 'volume/editLinks.html',
link: ($scope) ->
volume = $scope.volume
form = $scope.volumeEditLinksForm
form.data = _.map volume.links, (ref) ->
head: ref.head
url: re... | 'use strict'
app.directive 'volumeEditLinksForm', [
'pageService',
(page) ->
restrict: 'E',
templateUrl: 'volume/editLinks.html',
link: ($scope) ->
volume = $scope.volume
form = $scope.volumeEditLinksForm
form.data = _.map volume.links, (ref) ->
head: ref.head
url: re... | Set unsubmitted for error case of editlinks. | Set unsubmitted for error case of editlinks.
| CoffeeScript | agpl-3.0 | databrary/databrary,databrary/databrary,databrary/databrary,databrary/databrary |
d253d93aba7dabd3a1e302596625cf1d084fe541 | layouts/Body.coffee | layouts/Body.coffee | React = require 'react'
Nav = React.createFactory require 'antwar-default-theme/Nav'
Paths = require('antwar-core/PathsMixin')
require 'antwar-default-theme/scss/main.scss'
require 'react-ghfork/gh-fork-ribbon.ie.css' # ie support
require 'react-ghfork/gh-fork-ribbon.css'
Fork = React.createFactory(require 'react-ghfo... | React = require 'react'
Nav = React.createFactory require 'antwar-default-theme/Nav'
Paths = require('antwar-core/PathsMixin')
require 'antwar-default-theme/scss/main.scss'
require 'react-ghfork/gh-fork-ribbon.ie.css' # ie support
require 'react-ghfork/gh-fork-ribbon.css'
Fork = React.createFactory(require 'react-ghfo... | Add the section name when creating a new issue | Add the section name when creating a new issue
| CoffeeScript | mit | Foxandxss/site,Foxandxss/site |
d6bd20f7ff23f293218d1c084e180d5f5b94d8a0 | lib/shuss-config.coffee | lib/shuss-config.coffee | convict = require 'convict'
config = convict {
env:
doc: 'The application environment.'
default: 'development'
env: 'NODE_ENV'
verbose:
doc: 'speak to me'
default: false
port:
doc: 'Listened port'
format: 'port'
default: '1234'
env: 'SHUSS_PORT'
dir:
doc: 'Served file di... | convict = require 'convict'
config = convict {
verbose:
doc: 'speak to me'
default: false
port:
doc: 'Listened port'
format: 'port'
default: '1234'
env: 'SHUSS_PORT'
dir:
doc: 'Served file directory'
default: '.'
env: 'SHUSS_DIR'
livereload:
doc: 'Enable livereload'
... | Remove useless env config, fix livereload settings | Remove useless env config, fix livereload settings
| CoffeeScript | mit | ArnaudRinquin/shuss |
1107b552f41da78ee3fe7dafb50ef58f7d4fabd9 | lib/tooltip-view.coffee | lib/tooltip-view.coffee | # Source: https://github.com/lukehoban/atom-ide-flow/blob/master/lib/tooltip-view.coffee
{$, View} = require 'atom'
module.exports = (Main)->
class TooltipView extends View
@content: ->
@div class: 'ide-hack-tooltip'
initialize: (@rect, @LeMessage) ->
@append LeMessage
$(document.body).app... | # Source: https://github.com/lukehoban/atom-ide-flow/blob/master/lib/tooltip-view.coffee
{$, View} = require 'atom'
module.exports = (Main)->
class TooltipView extends View
@content: ->
@div class: 'ide-hack-tooltip'
initialize: (rect, @LeMessage) ->
@append LeMessage
$(document.body).appe... | Merge updatePosition function into Initialize | :art: Merge updatePosition function into Initialize
| CoffeeScript | mit | steelbrain/Atom-Hack |
5596e8614f83b95c09eeb3aef267f7af9ad957b0 | src/coffee/run.coffee | src/coffee/run.coffee | Validator = require('../main').Validator
fs = require 'fs'
argv = require('optimist')
.usage('Usage: $0 --projectKey key --clientId id --clientSecret secret --csv file')
.demand(['projectKey', 'clientId', 'clientSecret', 'csv'])
.argv
timeout = argv.timeout
timeout or= 60000
options =
config:
project_key:... | Validator = require('../main').Validator
fs = require 'fs'
argv = require('optimist')
.usage('Usage: $0 --projectKey key --clientId id --clientSecret secret --csv file')
.describe('projectKey', 'your SPHERE.IO project-key')
.describe('clientId', 'your OAuth client id for the SPHERE.IO API')
.describe('clientSec... | Add description for command line options. | Add description for command line options.
| CoffeeScript | mit | sphereio/sphere-node-product-csv-sync,sphereio/sphere-node-product-csv-sync,sphereio/sphere-node-product-csv-sync |
3e773c9d3b221f63f2f8d9d0e595e42dc23aadb7 | app/scripts/models/command.coffee | app/scripts/models/command.coffee | define [
"jquery"
"backbone"
"app"
"lib/extension"
"lib/fuzzy-match"
], (
$
Backbone
App
Extension
FuzzyMatch
) ->
class Command extends Backbone.Model
match: null
getTemplateData: ->
$.extend {}, @toJSON(), match: @match
createMatch: (search) ->
@match = new FuzzyMatch @... | define [
"jquery"
"backbone"
"app"
"lib/extension"
"lib/fuzzy-match"
], (
$
Backbone
App
Extension
FuzzyMatch
) ->
class Command extends Backbone.Model
match: null
getTemplateData: ->
$.extend {}, @toJSON(), match: @match
createMatch: (search) ->
@match = new FuzzyMatch @... | Make sure code is url decoded before encoding it to avoid double encoding | Make sure code is url decoded before encoding it to avoid double encoding
| CoffeeScript | mit | JoelBesada/Backtick |
0c1c960f383c869e4639847545a7fc6ac01f896c | src/draggable-mixin.coffee | src/draggable-mixin.coffee | Mixin = require 'mixto'
module.exports =
class Draggable extends Mixin
# Allows for user dragging on the screen
# * `startEvent` (optional) event from a mousedown event
enableDragging: (startEvent) ->
return if @_draggingEnabled
element = @svgEl
return unless element?
element.draggable(startEven... | Mixin = require 'mixto'
module.exports =
class Draggable extends Mixin
# Allows for user dragging on the screen
# * `startEvent` (optional) event from a mousedown event
enableDragging: (startEvent) ->
return if @_draggingEnabled
element = @svgEl
return unless element?
element.draggable(startEven... | Use new model setter in draggable | Use new model setter in draggable | CoffeeScript | mit | benogle/curve,benogle/curve |
cd2c711e9ec5c4bbb3309c7ef55164225302ecbe | app/assets/javascripts/models/paper.js.coffee | app/assets/javascripts/models/paper.js.coffee | a = DS.attr
ETahi.Paper = DS.Model.extend
assignees: DS.hasMany('user')
editors: DS.hasMany('user')
reviewers: DS.hasMany('user')
editor: Ember.computed.alias('editors.firstObject')
collaborations: DS.hasMany('collaboration')
collaborators: (->
@get('collaborations').mapBy('user')
).property('collabo... | a = DS.attr
ETahi.Paper = DS.Model.extend
assignees: DS.hasMany('user') # these are admins that have been assigned to the paper.
editors: DS.hasMany('user') # these are editors that have been assigned to the paper.
reviewers: DS.hasMany('user') # these are reviewers that have been assigned to the paper.
editor:... | Add clarifying comments to model. | Add clarifying comments to model.
| CoffeeScript | mit | johan--/tahi,johan--/tahi,johan--/tahi,johan--/tahi |
e4e6823a144ddeb7a7b80211a42dfadd015bf05f | src/coffee/edsl.coffee | src/coffee/edsl.coffee | angular.module 'qbn.edsl', ['qbn.quality', 'qbn.storylet', 'qbn.choice']
.factory 'qbnEdsl', (qualities, storylets, frontalChoices, choiceFactory) ->
api =
quality: (id, name, description, args = {}) ->
{defaultValue, defaultProgress, maxProgress, hasProgress, progressEscalation,
visible} =... | angular.module 'qbn.edsl', ['qbn.quality', 'qbn.storylet', 'qbn.choice']
.factory 'qbnEdsl', (qualities, storylets, frontalChoices, choiceFactory) ->
api =
quality: (id, name, description, args = {}) ->
{defaultValue, defaultProgress, maxProgress, hasProgress, progressEscalation,
visible} =... | Fix Missing Default Param in choice EDSL | Fix Missing Default Param in choice EDSL
| CoffeeScript | unlicense | arashikou/exper3-2015 |
16d2dd8652ad4b3091f96fb718a7f0aeb3d9366c | drawing-tools/pinpoint.coffee | drawing-tools/pinpoint.coffee | BasePoint = require 'zooniverse-readymade/lib/drawing-tools/point'
ToolControls = require './tool-controls'
class Pinpoint extends BasePoint
@Controls: ToolControls
constructor: ->
super
@disc.attr 'class', 'pinpoint'
rescale: (scale) ->
super
coords: (e) ->
@markingSurface.screenPixelTo... | BasePoint = require 'zooniverse-readymade/lib/drawing-tools/point'
ToolControls = require './tool-controls'
class Pinpoint extends BasePoint
@Controls: ToolControls
constructor: ->
super
@disc.attr 'class', 'pinpoint'
rescale: (scale) ->
super
coords: (e) ->
@markingSurface.screenPixelTo... | Fix point tool controls offset when scaling image. | Fix point tool controls offset when scaling image.
| CoffeeScript | apache-2.0 | zooniverse/BHL |
0c1d9d1694ade33dab52c138ffebd58fc2cb8b64 | scripts/kerb.coffee | scripts/kerb.coffee | # Description:
# Make hubot list what tasty treats are available at Kerb Kings Cross (eat.st)
#
# Dependencies:
#
# Configuration:
# None
#
# Commands:
# hubot what's on kerb
jsdom = require "jsdom"
module.exports = (robot) ->
robot.respond /what\'s on kerb/i, (msg) ->
url = "http://www.kerbfood.com/kings... | # Description:
# Make hubot list what tasty treats are available at Kerb Kings Cross (eat.st)
#
# Dependencies:
#
# Configuration:
# None
#
# Commands:
# hubot what's on kerb
jsdom = require "jsdom"
module.exports = (robot) ->
robot.respond /what\'s on kerb/i, (msg) ->
url = "http://www.kerbfood.com/kings... | Fix days of week formatting (1 -> 01) | Fix days of week formatting (1 -> 01)
| CoffeeScript | mit | altmetric/hubot-kerb,altmetric/hubot-kerb |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.