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 |
|---|---|---|---|---|---|---|---|---|---|
f86a481113103aea59f31deed71f089ced781ffa | src/trix/elements/trix_toolbar_element.coffee | src/trix/elements/trix_toolbar_element.coffee | {cloneFragment} = Trix
Trix.registerElement "trix-toolbar",
defaultCSS: """
%t {
white-space: collapse;
}
%t .dialog {
display: none;
}
%t .dialog.active {
display: block;
}
%t .dialog input.validate:invalid {
background-color: #ffdddd;
}
%t[native] {
... | {cloneFragment} = Trix
Trix.registerElement "trix-toolbar",
defaultCSS: """
%t {
white-space: collapse;
}
%t .dialog {
display: none;
}
%t .dialog.active {
display: block;
}
%t .dialog input.validate:invalid {
background-color: #ffdddd;
}
%t[native] {
... | Add default content when created to avoid extra DOM manipulation when attached | Add default content when created to avoid extra DOM manipulation when attached
| CoffeeScript | mit | ChenMichael/trix,GabiGrin/trix,ChenMichael/trix,basecamp/trix,urossmolnik/trix,basecamp/trix,GabiGrin/trix,basecamp/trix,ChenMichael/trix,urossmolnik/trix,basecamp/trix,urossmolnik/trix,GabiGrin/trix |
a0018670f424c3ad9ab23ab164e74e107a50b395 | menus/git.cson | menus/git.cson | 'menu': [
{
'label': 'View'
'submenu': [
{
'label': 'Toggle Git Panel'
'command': 'github:toggle-git-panel'
}
]
}
{
'label': 'Packages'
'submenu': [
{
'label': 'GitHub',
'submenu': [
{
'label': 'Toggle'
'comman... | 'menu': [
{
'label': 'View'
'submenu': [
{
'label': 'Toggle Git Panel'
'command': 'github:toggle-git-panel'
}
]
}
{
'label': 'Packages'
'submenu': [
{
'label': 'GitHub',
'submenu': [
{
'label': 'Toggle'
'comman... | Add context menu items for staging and unstaging in changed files list | Add context menu items for staging and unstaging in changed files list
| CoffeeScript | mit | atom/github,atom/github,atom/github |
4a584f1ece162d0e918fc9f307d18b070043221c | client/app/lib/util/tracker.coffee | client/app/lib/util/tracker.coffee | _ = require 'lodash'
kd = require 'kd'
remote = require('app/remote').getInstance()
globals = require 'globals'
defaults = require './tracking/defaults'
module.exports = class Tracker
_.assign this, require('./tracking/trackingtypes')
@track = (action, properties = {}) ->
return unless global... | _ = require 'lodash'
kd = require 'kd'
remote = require('app/remote').getInstance()
globals = require 'globals'
defaults = require './tracking/defaults'
module.exports = class Tracker
_.assign this, require('./tracking/trackingtypes')
@track = (action, properties = {}) ->
return unless global... | Fix condition clause of Tracker.track function | Fix condition clause of Tracker.track function
| CoffeeScript | agpl-3.0 | andrewjcasal/koding,drewsetski/koding,cihangir/koding,koding/koding,usirin/koding,usirin/koding,gokmen/koding,alex-ionochkin/koding,acbodine/koding,koding/koding,mertaytore/koding,sinan/koding,sinan/koding,kwagdy/koding-1,mertaytore/koding,drewsetski/koding,kwagdy/koding-1,jack89129/koding,mertaytore/koding,kwagdy/kodi... |
644aa8450147bba298a64a6c51a5d00fc4f3694a | lib/main.coffee | lib/main.coffee | {CompositeDisposable} = require 'atom'
module.exports =
config:
executablePath:
type: 'string'
title: 'PHP Executable Path'
default: 'php' # Let OS's $PATH handle the rest
activate: ->
@regex = '(Parse|Fatal) ' +
'(?<error>error):(\\s*(?<type>parse|syntax) error,?)?\\s*' +
... | {CompositeDisposable} = require 'atom'
module.exports =
config:
executablePath:
type: 'string'
title: 'PHP Executable Path'
default: 'php' # Let OS's $PATH handle the rest
activate: ->
@regex = '(Parse|Fatal) ' +
'(?<error>error):(\\s*(?<type>parse|syntax) error,?)?\\s*' +
... | Enable linting on the fly | Enable linting on the fly
Note that this represents a slight loss of functionality. With the
update to the new API the file was explicitly specified, which according
to the documentation enables checking for "fatal errors (like undefined
functions)".
Since we are linting on the fly we can't specify a file and thus lo... | CoffeeScript | mit | AtomLinter/linter-php,AtomLinter/linter-php |
e5896c06b9d92f86a17620ffd8de9fc08878dad4 | app/assets/javascripts/graphs.js.coffee | app/assets/javascripts/graphs.js.coffee | # Graph-stuff-code
# Generalised way to send an ajax request to load a chart when a
# link is clicked with data-load="graph"
$('body.coders.show, body.repositories.show').ready ->
$('a[data-load="graph"]').on 'shown.bs.tab', (e) ->
if !$("#chart").hasClass('google-visualization-atl container')
... | # Graph-stuff-code
# Generalised way to send an ajax request to load a chart when a
# link is clicked with data-load="graph"
$('body.coders.show, body.repositories.show').ready ->
$('a[data-load="graph"]').on 'shown.bs.tab', (e) ->
# Only initialise the chart the first time we click the tab
# Googl... | Add documentation for the if | Add documentation for the if | CoffeeScript | mit | ZeusWPI/gamification,ZeusWPI/gamification,ZeusWPI/gamification,ZeusWPI/gamification |
69d5a88e2a2ce26cd7b96a362ce8bf2a3ee75aaa | app/assets/javascripts/active_admin/cinematron.js.coffee | app/assets/javascripts/active_admin/cinematron.js.coffee | $ ->
# $('#rows').on "change", ->
# $rows = $(this).val()
# console.log $rows
# $('#columns').on "change", ->
# $columns = $(this).val()
# console.log $columns
$('#submit_details').click (e) ->
e.preventDefault()
$rows = parseInt($('#rows').val(), 10)
$columns = parseInt($('#columns'... | $ ->
# $('#rows').on "change", ->
# $rows = $(this).val()
# console.log $rows
# $('#columns').on "change", ->
# $columns = $(this).val()
# console.log $columns
$('#submit_details').click (e) ->
e.preventDefault()
$rows = parseInt($('#rows').val(), 10)
$columns = parseInt($('#columns'... | Create alleys in hall creation | Create alleys in hall creation
| CoffeeScript | mit | netguru-training/cinematron,netguru-training/cinematron |
88869b49a3c2e9727d03e6c379d0a580d8baa83b | src/scripts/workbench/views/sensor/map_view.js.coffee | src/scripts/workbench/views/sensor/map_view.js.coffee | class Workbench.Views.SensorMapView extends Backbone.Marionette.ItemView
template: false
initialize: ->
@zoom = 13
onDestroy: ->
@map.remove() if @map
onShow: ->
if @el.id is ""
console.warn "No Map Element"
else
@location = [@model.get("latitude"), @model.get("longitude")]
... | class Workbench.Views.SensorMapView extends Backbone.Marionette.ItemView
template: false
initialize: ->
@zoom = 13
onDestroy: ->
@map.remove() if @map
onShow: ->
if @el.id is ""
console.warn "No Map Element"
else
@location = [@model.get("latitude"), @model.get("longitude")]
... | Use PolarMap on sensor page | Use PolarMap on sensor page
| CoffeeScript | mit | GeoSensorWebLab/asw-workbench,GeoSensorWebLab/asw-workbench,GeoSensorWebLab/asw-workbench |
74704e242acce63e03656545e18f0fd75488b9c6 | core/app/backbone/collections/search_collection.coffee | core/app/backbone/collections/search_collection.coffee | class window.SearchCollection extends Backbone.Collection
constructor: (args...)->
super(args...)
@searchFor ''
emptyState: -> []
searchFor: (query) ->
query = $.trim(query)
return if query == @query
@query = query
@_search()
throttle = (method) -> _.throttle method, 300
_search: th... | class window.SearchCollection extends Backbone.Collection
constructor: (args...)->
super(args...)
@searchFor ''
emptyState: -> []
searchFor: (query) ->
query = $.trim(query)
return if query == @query
@query = query
@_search()
throttle = (method) -> _.throttle method, 300
_search: th... | Use reset for better performance | Use reset for better performance
| CoffeeScript | mit | Factlink/factlink-core,Factlink/factlink-core,daukantas/factlink-core,Factlink/factlink-core,daukantas/factlink-core,Factlink/factlink-core,daukantas/factlink-core,daukantas/factlink-core |
7633a2a7d757ae71e8666fc542295cdf0917c45c | 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: Add a deserializer.
add: (klasses...) ->
@deserializers[klass.name] = klass for klass in ... | Call get instead of getDeserializer | Call get instead of getDeserializer
| CoffeeScript | mit | RobinTec/atom,wiggzz/atom,jjz/atom,pombredanne/atom,scippio/atom,scippio/atom,SlimeQ/atom,MjAbuz/atom,vjeux/atom,g2p/atom,Ingramz/atom,dsandstrom/atom,RuiDGoncalves/atom,bsmr-x-script/atom,fredericksilva/atom,acontreras89/atom,davideg/atom,Andrey-Pavlov/atom,champagnez/atom,pengshp/atom,jtrose2/atom,RobinTec/atom,johnr... |
3dadfec3dbf0fd33a861f6f17afaf7f9fb113756 | app/assets/javascripts/users/notification_rules.js.coffee | app/assets/javascripts/users/notification_rules.js.coffee | # Place all the behaviors and hooks related to the matching controller here.
# All this logic will automatically be available in application.js.
# You can use CoffeeScript in this file: http://jashkenas.github.com/coffee-script/
| # Place all the behaviors and hooks related to the matching controller here.
# All this logic will automatically be available in application.js.
# You can use CoffeeScript in this file: http://jashkenas.github.com/coffee-script/
$ ->
$('select[data-reveal-section]').change(->
section = $("##{$(@).val() + $(@).attr(... | Add javascript to show section if an option with a matching value is selected | Add javascript to show section if an option with a matching value is selected
| CoffeeScript | mit | joshmcarthur/inquest,joshmcarthur/inquest |
6c7e4ef3781e9b99bd9db8f3f55ce4fcad3febe4 | app/assets/javascripts/views/question_form_view.js.coffee | app/assets/javascripts/views/question_form_view.js.coffee | # Newer view to manage Question form.
class ELMO.Views.QuestionFormView extends ELMO.Views.FormView
initialize: (options) ->
@toggleFields()
# We use $= because the start of the ID can vary depending on whether
# it's a question form or questioning form.
# Note, these events must be redefined in any child ... | # Newer view to manage Question form.
class ELMO.Views.QuestionFormView extends ELMO.Views.FormView
initialize: (options) ->
@toggleFields()
# We use $= because the start of the ID can vary depending on whether
# it's a question form or questioning form.
# Note, these events must be redefined in any child ... | Fix bug with read-only view of questioning form | 10139: Fix bug with read-only view of questioning form
| CoffeeScript | apache-2.0 | thecartercenter/elmo,thecartercenter/elmo,thecartercenter/elmo |
40a0386c12c373583f0efeb304cd3e9e553daca6 | lib/git-add.coffee | lib/git-add.coffee | {BufferedProcess} = require 'atom'
StatusView = require './status-view'
# if all param true, then 'git add .'
gitAdd = (all=false)->
dir = atom.project.getRepo().getWorkingDirectory()
currentFile = atom.workspace.getActiveEditor().getPath()
toStage = if all then '.' else currentFile
new BufferedProcess({
c... | {BufferedProcess} = require 'atom'
StatusView = require './status-view'
# if all param true, then 'git add .'
gitAdd = (all=false)->
dir = atom.project.getRepo().getWorkingDirectory()
currentFile = atom.workspace.getActiveEditor()?.getPath()
toStage = if all then '.' else currentFile
if (toStage?)
new Buff... | Fix "Git Plus: Add (all)" without open editor | Fix "Git Plus: Add (all)" without open editor
In the context, it would give a type error because
`atom.workspace.getActiveEditor()` was `undefined`.
| CoffeeScript | mit | akonwi/git-plus,akonwi/git-plus |
f34b8f305c2a96dd2f4657ef3ec0318e27f7c644 | src/cli.coffee | src/cli.coffee | path = require 'path'
fs = require 'fs-plus'
optimist = require 'optimist'
Highlights = require './highlights'
module.exports = ->
cli = optimist.describe('help', 'Show this message').alias('h', 'help')
.describe('scope', 'Scope name of grammar to use').alias('s', 'scopeName')
optimist.usage """
... | path = require 'path'
fs = require 'fs-plus'
optimist = require 'optimist'
Highlights = require './highlights'
module.exports = ->
cli = optimist.describe('help', 'Show this message').alias('h', 'help')
.describe('scope', 'Scope name of the grammar to use').alias('s', 'scopeName')
optimist.usage ""... | Add the to arg doc | Add the to arg doc
| CoffeeScript | mit | pouwerkerk/highlights,tiffon/highlights,leipert/highlights,atom/highlights,pombredanne/highlights,davidtheclark/highlights,bcoe/highlights,mathiasbynens/highlights,soldair/highlights |
22581f003cb9a5f68234bf9c9768c0236541fc35 | src/scripts/httpd.coffee | src/scripts/httpd.coffee | # Description:
# A simple interaction with the built in HTTP Daemon
#
# Dependencies:
# None
#
# Configuration:
# None
#
# Commands:
# None
#
# URLS:
# /hubot/version
# /hubot/ping
# /hubot/time
# /hubot/info
spawn = require('child_process').spawn
module.exports = (robot) ->
robot.router.get "/hubo... | # Description:
# A simple interaction with the built in HTTP Daemon
#
# Dependencies:
# None
#
# Configuration:
# None
#
# Commands:
# None
#
# URLS:
# /hubot/version
# /hubot/ping
# /hubot/time
# /hubot/info
# /hubot/ip
spawn = require('child_process').spawn
module.exports = (robot) ->
robot.rou... | Add route for knowing the IP where the bot is host | Add route for knowing the IP where the bot is host
| CoffeeScript | mit | gojee/gojee-hubot-deprecated,gojee/gojee-hubot-deprecated,gojee/gojee-hubot-deprecated |
b042f6540e0d6b77c422bdbfa9458c8fefc86acd | src/composite-disposable.coffee | src/composite-disposable.coffee | # Public: An object that aggregates multiple {Disposable} instances together
# into a single disposable, so they can all be disposed as a group.
module.exports =
class CompositeDisposable
disposed: false
constructor: ->
@disposables = []
# Public: Add a disposable to be disposed when the composite is dispos... | # Public: An object that aggregates multiple {Disposable} instances together
# into a single disposable, so they can all be disposed as a group.
module.exports =
class CompositeDisposable
disposed: false
# Public: Construct an instance, optionally with one or more
constructor: ->
@disposables = []
@add(d... | Allow CompositeDisposable to be constructed with multiple disposables | Allow CompositeDisposable to be constructed with multiple disposables | CoffeeScript | mit | NeekSandhu/event-kit,atom/event-kit |
c9a4e9a9e17cc56d11aec834713edb3cc7039db2 | lib/openers/atompdf-opener.coffee | lib/openers/atompdf-opener.coffee | Opener = require '../opener'
module.exports =
class AtomPdfOpener extends Opener
open: (filePath, texPath, lineNumber, callback) ->
# Opens PDF in a new pane -- requires pdf-view module
openPanes = atom.workspace.getPaneItems()
for pane in openPanes
if pane.filePath is filePath
# File is al... | Opener = require '../opener'
module.exports =
class AtomPdfOpener extends Opener
open: (filePath, texPath, lineNumber, callback) ->
# Opens PDF in a new pane -- requires pdf-view module
openPanes = atom.workspace.getPaneItems()
for pane in openPanes
# File is already open in another pane
retu... | Compress block, and add TODO comment | :art: Compress block, and add TODO comment
| CoffeeScript | mit | WoodyWoodsta/atom-latex,thomasjo/atom-latex,WoodyWoodsta/atom-latex,thomasjo/atom-latex,thomasjo/atom-latex |
bd987c0ea0465390969b6f42332839f40b94b55f | lib/messages.coffee | lib/messages.coffee | Helpers = require('./helpers')
{CompositeDisposable, Emitter} = require 'atom'
class MessageRegistry
constructor: (@linter)->
@messages = new Map()
@emitter = new Emitter
@subscriptions = new CompositeDisposable
@subscriptions.add atom.workspace.onDidChangeActivePaneItem =>
@messages.forEach (m... | Helpers = require('./helpers')
{Emitter} = require 'atom'
class MessageRegistry
constructor: (@linter)->
@messages = new Map()
@emitter = new Emitter
set: (linter, messages) ->
Helpers.validateMessages(messages)
@classifyMessages(messages)
@messages.set(linter, messages)
@emitter.emit 'did... | Remove all the subs from MessageRegistry | :fire: Remove all the subs from MessageRegistry
| CoffeeScript | mit | e-jigsaw/Linter,AtomLinter/Linter,JohnMurga/linter,kaeluka/linter,iam4x/linter,atom-community/linter,DanPurdy/linter,blakeembrey/linter,UltCombo/linter,mdgriffith/linter,steelbrain/linter,levity/linter,elkeis/linter,AsaAyers/linter,Arcanemagus/linter,shawninder/linter |
b39092aef946f81c38e8e9929dd458244097ea2a | packages/rocketchat-lib/server/models/_Base.coffee | packages/rocketchat-lib/server/models/_Base.coffee | RocketChat.models._Base = class
_baseName: ->
return 'rocketchat_'
_initModel: (name) ->
check name, String
@model = new Mongo.Collection @_baseName() + name
find: ->
return @model.find.apply @model, arguments
findOne: ->
return @model.findOne.apply @model, arguments
insert: ->
return @model.inser... | RocketChat.models._Base = class
_baseName: ->
return 'rocketchat_'
_initModel: (name) ->
check name, String
@model = new Mongo.Collection @_baseName() + name
find: ->
return @model.find.apply @model, arguments
findOne: ->
return @model.findOne.apply @model, arguments
insert: ->
return @model.inser... | Create new model method insertOrUpsert based on _id | Create new model method insertOrUpsert based on _id
| CoffeeScript | mit | wtsarchive/Rocket.Chat,marzieh312/Rocket.Chat,4thParty/Rocket.Chat,BorntraegerMarc/Rocket.Chat,intelradoux/Rocket.Chat,inoio/Rocket.Chat,fduraibi/Rocket.Chat,capensisma/Rocket.Chat,OtkurBiz/Rocket.Chat,ziedmahdi/Rocket.Chat,jbsavoy18/rocketchat-1,ealbers/Rocket.Chat,liuliming2008/Rocket.Chat,intelradoux/Rocket.Chat,Sin... |
05293c2c9c3f4db6fccc8393ec8135a2e56fc97c | src/src.coffee | src/src.coffee | require 'appirio-tech-ng-ui-components'
require 'appirio-tech-ng-api-services'
require './scripts/ap-file-upload.module'
require './scripts/file.controller'
require './scripts/file.directive'
require './scripts/file.service'
require './scripts/on-file-changed.directive'
require './scripts/uploaded-files.directive'
req... | require './scripts/ap-file-upload.module'
require './scripts/file.controller'
require './scripts/file.directive'
require './scripts/file.service'
require './scripts/on-file-changed.directive'
require './scripts/uploaded-files.directive'
require './scripts/uploader.controller'
require './scripts/uploader.directive'
req... | Remove requires to prep for consolidation into work-app | Remove requires to prep for consolidation into work-app
| CoffeeScript | mit | appirio-tech/ng-file-upload,appirio-tech/ng-file-upload |
5dcbcdbfb96f43d62e6ab47ce2bb69a542b7b52d | docs/source/javascripts/application.js.coffee | docs/source/javascripts/application.js.coffee | #= require "vendor/jquery-1.7.1.min" | #= require "vendor/jquery-1.7.1.min"
#= require "vendor/plugins/jquery.fittext.js" | Add fittext to asset pipeline | Add fittext to asset pipeline
| CoffeeScript | bsd-3-clause | BionicClick/susy,kaij/susy,tsi/susy,pairyo/susy,kraftner/susy,tsi/susy,lencioni/susy,gastonfig/susy,MichaelArestad/susy,justnorris/susy,leopic/susy,gonsakon/susy,katoffsky/susy,rainforestapp/susy,jinzhu/susy,leopic/susy,katoffsky/susy,acdlite/susy,Sapphire64/susy,essdot/susy,webdev1001/susy,oddbird/susy,greyhwndz/susy,... |
541b66a8babc64ed27083ca1c603d214767602b4 | app/js/jail_iframe/classes/loading_promises.coffee | app/js/jail_iframe/classes/loading_promises.coffee | setTimeout ->
if /^(interactive|complete)$/.test(document.readyState)
FactlinkJailRoot.host_ready_promise.resolve()
else
document.addEventListener('DOMContentLoaded', -> FactlinkJailRoot.host_ready_promise.resolve())
if 'complete' == document.readyState
FactlinkJailRoot.host_loaded_promise.resolve()... | setTimeout ->
ok =
loaded: true
interactive: !(document.documentMode < 11)
complete: true
if ok[document.readyState]
FactlinkJailRoot.host_ready_promise.resolve()
else
document.addEventListener('DOMContentLoaded', -> FactlinkJailRoot.host_ready_promise.resolve())
if 'complete' == document... | Fix IE 9/10 host_ready event | Fix IE 9/10 host_ready event
| CoffeeScript | mit | Factlink/js-library,Factlink/js-library,Factlink/js-library |
fd7991b56fff5b16f5409db7081f32bdcf30feec | src/coffee/app.coffee | src/coffee/app.coffee | deps = ['angular', './routes', 'angular-route', 'angular-ui', 'angular-ui-select2',
'./filters', './services', './directives', './controllers']
modules = [
'ngRoute',
'steps.controllers',
'steps.services',
'steps.filters',
'steps.directives',
'ui.bootstrap',
'ui.select2']
$providers = [
'$rout... | deps = ['angular', './routes', 'angular-route', 'angular-ui', 'angular-ui-select2',
'./filters', './services', './directives', './controllers']
modules = [
'ngRoute',
'steps.controllers',
'steps.services',
'steps.filters',
'steps.directives',
'ui.bootstrap',
'ui.select2']
$providers = [
'$rout... | Allow loading iframe tools from labs.intermine. | Allow loading iframe tools from labs.intermine.
| CoffeeScript | bsd-2-clause | yochannah/staircase,joshkh/staircase,joshkh/staircase,joshkh/staircase,yochannah/staircase,yochannah/staircase |
da1f0ede122a917b43aa75ba151aa93056e65dce | lib/polytexnic/server/views/refresh.js.coffee | lib/polytexnic/server/views/refresh.js.coffee | wait = ->
$.getJSON(window.location.pathname + '/wait', ->
$.get window.location.pathname + '.js', (html)->
$('#book').html html
initMathJax()
wait()
).fail -> wait()
initMathJax = ->
$('#mathJaxJS').remove()
delete MathJax
script = document.createElement( 'script' )
script.id = 'mat... | wait = ->
$.getJSON(window.location.pathname + '/wait', ->
$.get window.location.pathname + '.js', (html)->
$('#book').html html
initMathJax()
wait()
).fail -> wait()
initMathJax = ->
$('#mathJaxJS').remove()
delete MathJax
chapter_number = $('.chapter').attr('data-number')
script = ... | Add formatNumber using current chapter number | Add formatNumber using current chapter number
[Delivers #50579297]
| CoffeeScript | mit | softcover/softcover,minireference/softcover,softcover/softcover,softcover/softcover,minireference/softcover,minireference/softcover |
4c395fca3a30f59b5573be9d54db29d1dc196f1a | atom/config.cson | atom/config.cson | "*":
"exception-reporting":
userId: "30e6f2d0-42d3-ab77-4984-dde4c431f019"
welcome:
showOnStartup: false
core:
projectHome: "/Users/randy/src"
audioBeep: false
excludeVcsIgnoredPaths: false
editor:
invisibles: {}
fontFamily: "Hack"
showIndentGuide: true
autosave:
enabled: t... | "*":
"exception-reporting":
userId: "30e6f2d0-42d3-ab77-4984-dde4c431f019"
welcome:
showOnStartup: false
core:
projectHome: "/Users/randy/src"
audioBeep: false
excludeVcsIgnoredPaths: false
editor:
invisibles: {}
fontFamily: "Hack"
showIndentGuide: true
fontSize: 15
autosav... | Increase default font size a bit | Increase default font size a bit
| CoffeeScript | mit | randycoulman/dotfiles |
1abbb8cdf3f609d0dff40a32038cff8db9577d3d | test/routes/api_v1-spec.coffee | test/routes/api_v1-spec.coffee | assert = require 'assert'
request = require 'supertest'
resolve = require('path').resolve
req = request require '../../src/server'
base = ''
describe '/', ->
it 'should not return much', (done) ->
req.get "#{base}/"
.expect 204
.end done
describe '/upload', ->
url = "#{base}/upload"
it 'shou... | assert = require 'assert'
request = require 'supertest'
resolve = require('path').resolve
req = request require '../../src/server'
base = ''
describe '/', ->
it 'should not return much', (done) ->
req.get "#{base}/"
.expect 204
.end done
describe '/upload', ->
url = "#{base}/upload"
it 'shou... | Fix metadata assert for failing test case | Fix metadata assert for failing test case
| CoffeeScript | mit | Turistforeningen/Jotunheimr |
f78214b2c3108437c4c904a38c5ab65bbbfa6e77 | app/assets/javascripts/views/flash-messages.view.js.coffee | app/assets/javascripts/views/flash-messages.view.js.coffee | Wheelmap.FlashMessageView = Ember.View.extend
template: Ember.Handlebars.compile('{{ view.content.message }}')
classNameBindings: [':flash', 'content.type', ':fade', 'fadeIn:in']
fadeIn: false
didInsertElement: ()->
Ember.run.next @, 'toggleProperty', 'fadeIn'
Ember.run.later @, 'toggleProperty', 'fade... | Wheelmap.FlashMessageView = Ember.View.extend
template: Ember.Handlebars.compile('{{ view.content.message }}')
classNameBindings: [':flash', 'content.type', ':fade', 'fadeIn:in']
fadeIn: false
didInsertElement: ()->
Ember.run.next @, 'toggleProperty', 'fadeIn'
Ember.run.later @, 'toggleProperty', 'fade... | Fix reading time for flash messages. | Fix reading time for flash messages.
| CoffeeScript | agpl-3.0 | sozialhelden/wheelmap,sozialhelden/wheelmap,sozialhelden/wheelmap,sozialhelden/wheelmap,sozialhelden/wheelmap |
dd80d62fcd2375a72289f00427e2c2e6dea989cb | app/assets/javascripts/lib/util/flexibility_order.coffee | app/assets/javascripts/lib/util/flexibility_order.coffee | class @FlexibilityOrder
constructor: (@element) ->
@lastGood = null
url: (path) ->
"#{ App.scenario.url_path() }/flexibility_order/#{ path }"
update: (sortable) =>
options = sortable.toArray()
$.ajax
url: @url('set'),
type: 'POST',
data:
flexibility_order:
or... | class @FlexibilityOrder
constructor: (@element) ->
@lastGood = null
url: ->
"#{App.scenario.url_path()}/flexibility_order"
update: (sortable) =>
options = sortable.toArray()
$.ajax
url: @url(),
type: 'POST',
data:
flexibility_order:
order: options
succe... | Update FlexibilityOrder to use new ETEngine API | Update FlexibilityOrder to use new ETEngine API
| CoffeeScript | mit | quintel/etmodel,quintel/etmodel,quintel/etmodel,quintel/etmodel |
584ab179a0cb105a36212116949570f5f684b17f | app/talk/lib/create-subject-default-button.cjsx | app/talk/lib/create-subject-default-button.cjsx | React = require 'react'
talkClient = require 'panoptes-client/lib/talk-client'
PromiseRenderer = require '../../components/promise-renderer'
SingleSubmitButton = require '../../components/single-submit-button'
DEFAULT_BOARD_TITLE = 'Notes' # Name of board to put subject comments
DEFAULT_BOARD_DESCRIPTION = ... | React = require 'react'
talkClient = require 'panoptes-client/lib/talk-client'
SingleSubmitButton = require '../../components/single-submit-button'
DEFAULT_BOARD_TITLE = 'Notes' # Name of board to put subject comments
DEFAULT_BOARD_DESCRIPTION = 'General comment threads about individual subjects'
module.e... | Remove PromiseRenderer from subject default button | Remove PromiseRenderer from subject default button
| CoffeeScript | apache-2.0 | jelliotartz/Panoptes-Front-End,amyrebecca/Panoptes-Front-End,jelliotartz/Panoptes-Front-End,parrish/Panoptes-Front-End,zooniverse/Panoptes-Front-End,amyrebecca/Panoptes-Front-End,parrish/Panoptes-Front-End,amyrebecca/Panoptes-Front-End,jelliotartz/Panoptes-Front-End,parrish/Panoptes-Front-End |
dfc5c18ffe19aba192be6a9e163a56470c554fc6 | app/scripts/pocket.coffee | app/scripts/pocket.coffee | 'use strict'
class Pocket
constructor: ->
element = document.createElement 'div'
element.classList.add 'pocket'
element.innerText = 'Pocket'
document.body.appendChild element
pocket = new Pocket()
| 'use strict'
class Pocket
State:
OPEN: 'open'
CLOSE: 'close'
state: null
constructor: ->
@state = @State.CLOSE
element = document.createElement 'div'
element.classList.add 'pocket'
element.innerText = 'Pocket'
element.addEventListener 'mouseover', @onMouseOver.bind(@)
element.... | Add open and close states by mouse over and leave | Add open and close states by mouse over and leave
| CoffeeScript | apache-2.0 | eqot/pocket |
097dc0602614fc78bd2e27c424f7034ccf651c2c | Source/ExpectedWrite.coffee | Source/ExpectedWrite.coffee | # @Compiler-Output "../Dist/ExceptedWrite.js"
EventEmitter = require('events').EventEmitter
Promise = require('a-promise')
Buffer = require('buffer').Buffer
class ExpectedWrite extends EventEmitter
constructor: (@stream) ->
super
@status = true
@expected = null
@callback = null
@data = stdout: '... | # @Compiler-Output "../Dist/ExceptedWrite.js"
EventEmitter = require('events').EventEmitter
Promise = require('a-promise')
Buffer = require('buffer').Buffer
class ExpectedWrite extends EventEmitter
constructor: (@stream) ->
super
@status = true
@expected = null
@expectedStream = 'both' # enum{ stdou... | Implement expect, write and end | :new: Implement expect, write and end
| CoffeeScript | mit | steelbrain/node-ssh |
0e184755e234ae8a5e243a2b358c28a0ba951508 | app/controllers/Dashboard.coffee | app/controllers/Dashboard.coffee | Spine = require('spine')
class Dashboard extends Spine.Controller
constructor: ->
super
@render()
tools: []
channels: []
count: 0
render: =>
@html require('views/dashboard')() if @el.html
addTool: (tool) ->
@tools.push tool
@channels.push tool.channel
createTool: (className) ->
... | Spine = require('spine')
class Dashboard extends Spine.Controller
constructor: ->
super
@render()
tools: []
channels: []
count: 0
render: =>
@html require('views/dashboard')() if @el.html
addTool: (tool) ->
@tools.push tool
@channels.push tool.channel
createTool: (className) ->
... | Fix class name problem with divs | Fix class name problem with divs
| CoffeeScript | mit | zooniverse/Ubret,zooniverse/Ubret,willettk/Ubret |
cb9548a6ca1efdb7fbbb8e373a5c39965972a204 | home/atom/keymap.cson | home/atom/keymap.cson | # Your keymap
#
# Atom keymaps work similarly to stylesheets. Just as stylesheets use selectors
# to apply styles to elements, Atom keymaps use selectors to associate
# keystrokes with events in specific contexts.
#
# You can create a new keybinding in this file by typing "key" and then hitting
# tab.
#
# Here's an exa... | 'atom-text-editor[data-grammar="text xml"]:not([mini])':
'tab': 'emmet:expand-abbreviation-with-tab'
'.platform-darwin':
'cmd-p': 'command-palette:toggle'
| Use cmd-p to toggle command-palette | Use cmd-p to toggle command-palette
| CoffeeScript | mit | adius/dotfiles,adius/dotfiles,adius/dotfiles,adius/dotfiles |
c8a67366c652e0233588ed63dd92c517cb7a8806 | t9n.coffee | t9n.coffee | if Meteor.isClient
if Package.ui
Handlebars = Package.ui.Handlebars
Handlebars.registerHelper 't9n', (x, prefix='') ->
T9n.get(x, prefix)
class T9n
@get: (x, prefix='') ->
_get(x, prefix)
@map: (language, map) ->
if not i18n.map[language]
i18n.map[language] = {}
_extend(i18n.map[la... | if Meteor.isClient
if Package.ui
Handlebars = Package.ui.Handlebars
Handlebars.registerHelper 't9n', (x, prefix='') ->
T9n.get(x, prefix)
class T9n
@get: (x, prefix='') ->
_get(x, prefix)
@map: (language, map) ->
if not i18n.map[language]
i18n.map[language] = {}
_extend(i18n.map[la... | Comment out, still not working | Comment out, still not working
| CoffeeScript | mit | Differential/meteor-accounts-t9n |
1cc08d1a5266a5b4992351010daee9ea6efdcbd9 | lib/whitespace.coffee | lib/whitespace.coffee | {Subscriber} = require 'emissary'
module.exports =
class Whitespace
Subscriber.includeInto(this)
constructor: ->
atom.workspace.eachEditor (editor) =>
@handleEditorEvents(editor)
destroy: ->
@unsubscribe()
handleEditorEvents: (editor) ->
@subscribe editor, 'will-be-saved', =>
editor.... | {Subscriber} = require 'emissary'
module.exports =
class Whitespace
Subscriber.includeInto(this)
constructor: ->
atom.workspace.eachEditor (editor) =>
@handleEditorEvents(editor)
destroy: ->
@unsubscribe()
handleEditorEvents: (editor) ->
@subscribe editor, 'will-be-saved', =>
editor.... | Remove need for buffer in `ensureSingleTrailingNewline` | Remove need for buffer in `ensureSingleTrailingNewline` | CoffeeScript | mit | atom/whitespace |
1293cf994a7f78a51e16ba8443b6361726f11bbf | Gruntfile.coffee | Gruntfile.coffee | module.exports = (grunt) ->
grunt.initConfig
nodewebkit:
options:
build_dir: './builds'
version: '0.8.4'
mac_icns: './src/assets/icon.icns'
mac: true
win: true
linux32: true
linux64: true
src: [ './src/**/*' ]
grunt.loadNpmTasks 'grunt-node-we... | module.exports = (grunt) ->
grunt.initConfig
nodewebkit:
options:
build_dir: './builds'
version: '0.9.2'
mac_icns: './src/assets/icon.icns'
mac: true
win: true
linux32: true
linux64: true
src: [ './src/**/*' ]
grunt.loadNpmTasks 'grunt-node-we... | Update node-webkit version to 0.9.2 | Update node-webkit version to 0.9.2
| CoffeeScript | mit | MaxSvargal/syncstray |
2c45f178cbf14c7e315ec1b1db6958300297ad04 | app/assets/javascripts/foundation_extras.js.coffee | app/assets/javascripts/foundation_extras.js.coffee | App.FoundationExtras =
initialize: ->
$(document).foundation()
$(window).trigger "load.zf.sticky"
$(window).trigger "resize"
clearSticky = ->
$("[data-sticky]").foundation("destroy") if $("[data-sticky]").length
$(document).on("page:before-unload", clearSticky)
| App.FoundationExtras =
initialize: ->
$(document).foundation()
$(window).trigger "load.zf.sticky"
$(window).trigger "resize"
clearSticky = ->
$("[data-sticky]").foundation("destroy") if $("[data-sticky]").length
$(document).on("page:before-unload", clearSticky)
window.addEventListene... | Reset sticky component before clicking back button on browser | Reset sticky component before clicking back button on browser
| CoffeeScript | agpl-3.0 | usabi/consul_san_borondon,consul/consul,consul/consul,AyuntamientoPuertoReal/decidePuertoReal,usabi/consul_san_borondon,consul/consul,AyuntamientoPuertoReal/decidePuertoReal,consul/consul,usabi/consul_san_borondon,consul/consul,usabi/consul_san_borondon,AyuntamientoPuertoReal/decidePuertoReal |
4836cd2b4b7c344c69a0c50c22354858f6220062 | app/assets/javascripts/show_hide_checkboxes.coffee | app/assets/javascripts/show_hide_checkboxes.coffee | root = exports ? this
ShowHideCheckboxesModule =
expandOnLoad: ->
$('input.show-hide-checkbox:checkbox').each ->
if $(this).is(':checked')
$('#' + $(this).data('section') + '-only').toggle('hide')
bindToCheckboxes: ->
$('input.show-hide-checkbox:checkbox').on 'change', ->
$('#' + $(th... | root = exports ? this
ShowHideCheckboxesModule =
expandOnLoad: ->
$('input.show-hide-checkbox:checkbox').each ->
$(this).parents('label').toggleClass('selected', $(this).is(':checked'));
if $(this).is(':checked')
$('#' + $(this).data('section') + '-only').toggle('hide')
bindToCheckboxes: ... | Add selected to checkbox labels | Add selected to checkbox labels
| CoffeeScript | mit | ministryofjustice/fr-staffapp,ministryofjustice/fr-staffapp,ministryofjustice/fr-staffapp,ministryofjustice/fr-staffapp |
7f1f594c7f93ce01c785c9433a5885b21b425d6f | core/app/backbone/views/generic/tourstepbox.coffee | core/app/backbone/views/generic/tourstepbox.coffee | class TourStepBox extends Backbone.Marionette.ItemView
className: 'white-well tour-block'
events:
'click .next-step': 'next'
next: ->
next_button = @$el.find('.next-step')
if next_button and next_button.data('disable-with')
next_button.addClass('disabled').text(next_button.data('disable-with'... | class TourStepBox extends Backbone.Marionette.ItemView
className: 'white-well tour-block'
events:
'click .next-step': 'next'
next: ->
next_button = @$el.find('.next-step')
if next_button and next_button.data('disable-with')
next_button.addClass('disabled').text(next_button.data('disable-with'... | Revert "Added template helpers for capitalized translation" | Revert "Added template helpers for capitalized translation"
This reverts commit 7837b49e1fc34efa2071cbd331cedc58b1bbfa32.
| CoffeeScript | mit | Factlink/factlink-core,daukantas/factlink-core,Factlink/factlink-core,Factlink/factlink-core,daukantas/factlink-core,Factlink/factlink-core,daukantas/factlink-core,daukantas/factlink-core |
9b0dc1b1042ad6bc7b4395ef885a7940decd4383 | src/trix/models/managed_attachment.coffee | src/trix/models/managed_attachment.coffee | #= require trix/models/attachment
class Trix.ManagedAttachment
# Forward all Attachment methods
for own name, value of Trix.Attachment.prototype when name isnt "constructor" and typeof value is "function"
do (name, value) =>
@::[name] = -> @attachment[name].call(@attachment, arguments)
constructor: (@... | #= require trix/models/attachment
class Trix.ManagedAttachment
# Forward all Attachment methods
for own name, value of Trix.Attachment.prototype when name isnt "constructor" and typeof value is "function"
do (name, value) =>
@::[name] = -> @attachment[name].apply(@attachment, arguments)
constructor: (... | Fix ManagedAttachment method forwarding and set file property | Fix ManagedAttachment method forwarding and set file property
| CoffeeScript | mit | ChenMichael/trix,urossmolnik/trix,basecamp/trix,basecamp/trix,urossmolnik/trix,GabiGrin/trix,GabiGrin/trix,basecamp/trix,urossmolnik/trix,GabiGrin/trix,basecamp/trix,ChenMichael/trix,ChenMichael/trix |
f55e4cec9801ae70240b47d666dac7798283f6d0 | client/ide/lib/views/tabview/idetabhandleview.coffee | client/ide/lib/views/tabview/idetabhandleview.coffee | kd = require 'kd'
KDTabHandleView = kd.TabHandleView
module.exports = class IDETabHandleView extends KDTabHandleView
constructor: (options = {}, data) ->
options.bind = 'dragstart'
super options, data
dragStart: (event) ->
## FF hack.
event.originalEvent.dataTransfer.setData 't... | kd = require 'kd'
KDTabHandleView = kd.TabHandleView
module.exports = class IDETabHandleView extends KDTabHandleView
constructor: (options = {}, data) ->
options.droppable ?= yes
options.bind = 'dragstart'
super options, data
dragStart: (event) ->
## FF hack.
event.ori... | Set true to options.droppable for IDETabHandleView | Set true to options.droppable for IDETabHandleView
| CoffeeScript | agpl-3.0 | koding/koding,cihangir/koding,acbodine/koding,mertaytore/koding,cihangir/koding,kwagdy/koding-1,rjeczalik/koding,jack89129/koding,drewsetski/koding,kwagdy/koding-1,mertaytore/koding,jack89129/koding,cihangir/koding,koding/koding,jack89129/koding,szkl/koding,acbodine/koding,sinan/koding,rjeczalik/koding,sinan/koding,sin... |
a88a0336735e59e3449fc5e7d61f113d3c8d6686 | Gruntfile.coffee | Gruntfile.coffee | module.exports = (grunt) ->
# Configuration
grunt.initConfig
# Package information
pkg: grunt.file.readJSON "package.json"
# Coffeescript compilation
coffee:
glob_to_multiple:
expand: true
cwd: "src/"
src: ["*.coffee"]
dest: "lib/"
ext: ".js"
opti... | module.exports = (grunt) ->
# Configuration
grunt.initConfig
# Package information
pkg: grunt.file.readJSON "package.json"
# Coffeescript compilation
coffee:
glob_to_multiple:
expand: true
cwd: "src/"
src: ["*.coffee"]
dest: "lib/"
ext: ".js"
opti... | Make "spec" reporter the default for mocha | Make "spec" reporter the default for mocha
It was in the Gruntfile this way, just in the wrong section -- I'm just
putting it where it belongs (Per Simon M).
| CoffeeScript | mit | bugsnag/bugsnag-node,QuentinDejean/bugsnag-node,lukehansell/bugsnag-node,jacobmarshall/bugsnag-node |
81a75fd431d360acc04cf807a3db8cb1c5859820 | app/assets/javascripts/controllers/toolbar.js.coffee | app/assets/javascripts/controllers/toolbar.js.coffee | Wheelmap.ToolbarController = Ember.Controller.extend
statusFilters: ['yes', 'limited', 'no', 'unknown']
actions:
toggleFilter: (wheelchair)->
statusFilters = @get('statusFilters')
if statusFilters.contains(wheelchair)
statusFilters.removeObject(wheelchair)
else
statusFilters.... | Wheelmap.ToolbarController = Ember.Controller.extend
statusFilters: ['yes', 'limited', 'no', 'unknown']
_extraFilter: false # Flag for executing special status filter behavior only once
actions:
toggleFilter: (wheelchair)->
statusFilters = @get('statusFilters')
if !@_extraFilter && statusFilters... | Add flag for having special behavior when filtering nodes only once. | Add flag for having special behavior when filtering nodes only once. | CoffeeScript | agpl-3.0 | sozialhelden/wheelmap,sozialhelden/wheelmap,sozialhelden/wheelmap,sozialhelden/wheelmap,sozialhelden/wheelmap |
8ee078e037334d6ad11b32ba5851423a56e78122 | app/assets/javascripts/sprangular/directives/promoForm.coffee | app/assets/javascripts/sprangular/directives/promoForm.coffee | Sprangular.directive 'promoForm', ->
restrict: 'E'
templateUrl: 'promos/form.html'
scope:
order: '='
controller: ($scope, Cart, Checkout, Angularytics) ->
$scope.showPromoEntry = false
$scope.promoCode = ''
$scope.save = ->
Cart.current.promoCode = $scope.promoCode
Angularytics.trac... | Sprangular.directive 'promoForm', ->
restrict: 'E'
templateUrl: 'promos/form.html'
scope:
order: '='
controller: ($scope, Cart, Checkout, Angularytics) ->
$scope.showPromoEntry = false
$scope.promoCode = ''
$scope.save = ->
Angularytics.trackEvent("Cart", "Coupon added", $scope.promoCode)... | Clear promoCode when form submitted | Clear promoCode when form submitted
| CoffeeScript | mit | sprangular/sprangular,sprangular/sprangular,sprangular/sprangular |
a6aae0363cb5edc6dc0a99d0754943b9cea5fcce | src/app/api/models/task-alignment.coffee | src/app/api/models/task-alignment.coffee | angular.module("doubtfire.api.models.task-alignment", [])
.factory("TaskAlignment", (resourcePlus, DoubtfireConstants, currentUser, $window) ->
TaskAlignment = {}
TaskAlignment.taskAlignmentCSVUploadUrl = (unit, project_id) ->
if project_id?
"#{DoubtfireConstants.API_URL}/units/#{unit.id}/learning_alignm... | angular.module("doubtfire.api.models.task-alignment", [])
.factory("TaskAlignment", (resourcePlus, DoubtfireConstants, currentUser, $window) ->
TaskAlignment = {}
TaskAlignment.taskAlignmentCSVUploadUrl = (unit, project_id) ->
if project_id?
"#{DoubtfireConstants.API_URL}/units/#{unit.id}/learning_alignm... | Remove auth token from task alignment csv upload | FIX: Remove auth token from task alignment csv upload
| CoffeeScript | agpl-3.0 | doubtfire-lms/doubtfire-web,doubtfire-lms/doubtfire-web,doubtfire-lms/doubtfire-web,doubtfire-lms/doubtfire-web |
a9fa6fa813f5394c570041d0087a3a7e3962ae78 | spec/minimap-spec.coffee | spec/minimap-spec.coffee | Minimap = require '../lib/minimap'
{WorkspaceView} = require 'atom'
describe "Minimap", ->
beforeEach ->
runs ->
atom.workspaceView = new WorkspaceView
atom.config.set 'minimap.autoToggle', true
waitsForPromise ->
atom.workspaceView.open('sample.js')
runs ->
atom.workspaceView.... | Minimap = require '../lib/minimap'
{WorkspaceView} = require 'atom'
describe "Minimap", ->
beforeEach ->
runs ->
atom.workspaceView = new WorkspaceView
atom.config.set 'minimap.autoToggle', true
waitsForPromise ->
atom.workspaceView.open('sample.js')
runs ->
atom.workspaceView.... | Fix tests broken with last changes in Atom | :green_heart: Fix tests broken with last changes in Atom
| CoffeeScript | mit | xndcn/atom-minimap,atom-minimap/minimap |
7ea5b17caca51c1dad96a1d31d494775dd13b5ed | lib/index.coffee | lib/index.coffee |
isFunction = require 'is-function'
isObjectOrArray = require 'is-object'
isArray = require 'is-array'
###
when passed an object, returns an array of its keys.
when passed an array, returns an array of its indexes.
arrayify({a: 'aa', b: 'bb', c: 'cc'})
-> ['a', 'b', 'c']
arrayify(['one', 'two', 'three'])... |
isObjectOrArray = require 'is-object'
isArray = require 'is-array'
isFunction = require 'is-function'
###
when passed an object, returns an array of its keys.
when passed an array, returns an array of its indexes.
arrayify({a: 'aa', b: 'bb', c: 'cc'})
-> ['a', 'b', 'c']
arrayify(['one', 'two', 't... | Fix to isFunction require statement | Fix to isFunction require statement
| CoffeeScript | mit | simon-johansson/keyfinder |
09a9d800387a5d33236e562bfe8a6e5ee5a3d897 | lib/base.coffee | lib/base.coffee | class Base
emitter: null
configure: (@emitter) ->
getEmitter: -> @emitter
emit: (event, data) ->
return unless @emitter
data.event = event unless data.event
@emitter.emit event, data
log: (level, module, text) ->
@emit "logger.#{level}.#{module}", level: level, module: module, text: text,... | class Base
emitter: null
configure: (@emitter) ->
getEmitter: -> @emitter
emit: (event, data) ->
return unless @emitter
data = {} unless data
data.event = event unless data.event
@emitter.emit event, data
log: (level, module, text) ->
@emit "logger.#{level}.#{module}", level: level, m... | Fix issue calling Base.prototype.emit without any payload (data). | Fix issue calling Base.prototype.emit without any payload (data).
| CoffeeScript | mit | knalli/pi-jenkins,knalli/pi-jenkins |
e0bd7c4ff9dcdaf881dd97203a636423579f811e | lib/main.coffee | lib/main.coffee | GitDiffView = require './git-diff-view'
DiffListView = null
diffListView = null
toggleDiffList = ->
DiffListView ?= require './diff-list-view'
diffListView ?= new DiffListView()
diffListView.toggle()
module.exports =
config:
showIconsInEditorGutter:
type: 'boolean'
default: false
activate: ... | GitDiffView = require './git-diff-view'
DiffListView = null
diffListView = null
toggleDiffList = ->
DiffListView ?= require './diff-list-view'
diffListView ?= new DiffListView()
diffListView.toggle()
module.exports =
config:
showIconsInEditorGutter:
type: 'boolean'
default: false
descrip... | Add description for config setting | Add description for config setting
| CoffeeScript | mit | atom/git-diff |
3a110d27012e5258305b314f65b2a769ca08da05 | lib/main.coffee | lib/main.coffee | SpellCheckView = null
module.exports =
config:
grammars:
type: 'array'
default: [
'source.gfm'
'text.git-commit'
'text.plain'
'text.plain.null-grammar'
]
activate: ->
@editorSubscription = atom.workspace.observeTextEditors(addViewToEditor)
deactivate: -... | SpellCheckView = null
module.exports =
config:
grammars:
type: 'array'
default: [
'source.gfm'
'text.git-commit'
'text.plain'
'text.plain.null-grammar'
]
activate: ->
@disposable = atom.workspace.observeTextEditors(addViewToEditor)
deactivate: ->
@d... | Call .dispose() on deactivate instead of .off() | Call .dispose() on deactivate instead of .off() | CoffeeScript | mit | atom/spell-check |
78e5825d86bcc6f49912d3cec088468ac7501351 | client/app/CommonViews/linkviews/applinkview.coffee | client/app/CommonViews/linkviews/applinkview.coffee | class AppLinkView extends LinkView
constructor:(options = {}, data)->
options.tooltip =
title : data.body
placement : "above"
delayIn : 120
offset : 1
super options, data
# FIXME GG, Need to implement AppIsDeleted
data.on? "AppIsDeleted", =>
@destroy()
pista... | class AppLinkView extends LinkView
constructor:(options = {}, data)->
super options, data
# FIXME something wrong with setTooltip
@on "OriginLoadComplete", (data)=>
log data
@setTooltip
title : data.body
placement : "above"
delayIn : 120
offset : 1
... | Update tooltip after loadFromOrigin finished | Update tooltip after loadFromOrigin finished
| CoffeeScript | agpl-3.0 | kwagdy/koding-1,acbodine/koding,andrewjcasal/koding,sinan/koding,kwagdy/koding-1,drewsetski/koding,sinan/koding,gokmen/koding,jack89129/koding,usirin/koding,gokmen/koding,usirin/koding,koding/koding,cihangir/koding,alex-ionochkin/koding,mertaytore/koding,cihangir/koding,kwagdy/koding-1,jack89129/koding,koding/koding,rj... |
f9c3b0084bd229d44732aadf5dfd4a35efb356b8 | lib/rails/beforesend.coffee | lib/rails/beforesend.coffee | # jQuery already provides a handful of global AJAX events. However,
# there is no global version of `beforeSend`, so `ajaxBeforeSend` is
# added to complement it.
#
# Reference: http://docs.jquery.com/Ajax_Events
return unless $.ajaxSetup
$.ajaxSetup
beforeSend: (xhr, settings) ->
return unless settings.global
... | # Implements global `ajaxBeforeSend` event.
#
# jQuery already provides a handful of global AJAX events. However,
# there is no global version of `beforeSend`, so `ajaxBeforeSend` is
# added to complement it.
#
# Reference: http://docs.jquery.com/Ajax_Events
# Skip for Zepto which doesn't have ajaxSetup but does alrea... | Add some warning notes about ajaxBeforeSend | Add some warning notes about ajaxBeforeSend
| CoffeeScript | mit | josh/rails-behaviors,josh/rails-behaviors,josh/rails-behaviors,josh/rails-behaviors |
c8814756a3fda2ae2b2f9ac9f4c0004bb7b60dd2 | 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.getName()
path ... | 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 ... | Replace inline pistachio string with a KDCustomHTMLView. | NavigationMachineItem: Replace inline pistachio string with a KDCustomHTMLView.
| CoffeeScript | agpl-3.0 | andrewjcasal/koding,gokmen/koding,sinan/koding,usirin/koding,sinan/koding,mertaytore/koding,usirin/koding,alex-ionochkin/koding,koding/koding,kwagdy/koding-1,rjeczalik/koding,sinan/koding,szkl/koding,usirin/koding,kwagdy/koding-1,usirin/koding,koding/koding,drewsetski/koding,cihangir/koding,usirin/koding,mertaytore/kod... |
8dfabd8757d8bf54a925a3a191faa5991123736a | app/assets/javascripts/cartilage/application.js.coffee | app/assets/javascripts/cartilage/application.js.coffee |
class window.Cartilage.Application
@Collections: {}
@Models: {}
@Routers: {}
@Views: {}
@sharedInstance: null
@launch: ->
@sharedInstance = new @
@sharedInstance.initialize()
@hijackLinks()
@hijackLinks: ->
if Backbone.history and Backbone.history._hasPushState
$(document).deleg... |
class window.Cartilage.Application
@Collections: {}
@Models: {}
@Routers: {}
@Views: {}
@sharedInstance: null
@launch: ->
@sharedInstance = new @
@hijackLinks()
@hijackLinks: ->
if Backbone.history and Backbone.history._hasPushState
$(document).delegate "a", "click", (event) ->
... | Kill the unnecessary explicit call to initialize since new already does that for us. | Kill the unnecessary explicit call to initialize since new already does that for us.
| CoffeeScript | mit | Cartilage/cartilage,Cartilage/cartilage |
7524ce1837f135790089741715b1f4f75d6a3f11 | config/env/vars.coffee | config/env/vars.coffee | # Map of environment vars to config properties
EnvVars =
NODE_ENV: 'appMode'
PORT: 'port'
LOG_LEVEL: 'logLevel'
STORAGE_TYPE: 'storageType'
POSTGRES_URL: 'postgresUrl'
GZIP: 'gzip'
module.exports = EnvVars
| # Map of environment vars to config properties
EnvVars =
NODE_ENV: 'appMode'
BASE_URL: 'baseUrl'
PORT: 'port'
LOG_LEVEL: 'logLevel'
STORAGE_TYPE: 'storageType'
POSTGRES_URL: 'postgresUrl'
GZIP: 'gzip'
module.exports = EnvVars
| Add environment variable for BASE_URL. | Add environment variable for BASE_URL.
| CoffeeScript | mit | argumenta/argumenta,argumenta/argumenta |
12b185af7988b5dc8548c5e792cc1fd1d469d312 | src/app/atom-theme.coffee | src/app/atom-theme.coffee | fs = require 'fs'
Theme = require 'theme'
module.exports =
class AtomTheme extends Theme
loadStylesheet: (stylesheetPath)->
@stylesheets[stylesheetPath] = fs.read(stylesheetPath)
load: ->
if /\.css$/.test(@path)
@loadStylesheet @path
else
metadataPath = fs.resolveExtension(fs.join(@path, ... | fs = require 'fs'
Theme = require 'theme'
module.exports =
class AtomTheme extends Theme
loadStylesheet: (stylesheetPath)->
@stylesheets[stylesheetPath] = fs.read(stylesheetPath)
load: ->
if fs.extension(@path) is '.css'
@loadStylesheet(@path)
else
metadataPath = fs.resolveExtension(fs.jo... | Use fs.extension instead of regex | Use fs.extension instead of regex
| CoffeeScript | mit | RobinTec/atom,chengky/atom,lovesnow/atom,Hasimir/atom,hharchani/atom,vcarrera/atom,githubteacher/atom,deoxilix/atom,panuchart/atom,rxkit/atom,jtrose2/atom,Neron-X5/atom,dannyflax/atom,russlescai/atom,Jdesk/atom,abcP9110/atom,0x73/atom,liuxiong332/atom,devoncarew/atom,isghe/atom,n-riesco/atom,Dennis1978/atom,AlexxNica/a... |
1af4d5d64239d1ddea7dc54777423b8799787001 | actions/hdp_yarn_nm.coffee | actions/hdp_yarn_nm.coffee |
lifecycle = require './hdp/lifecycle'
module.exports = []
module.exports.push 'histi/actions/hdp_yarn'
module.exports.push (ctx) ->
require('./hdp_yarn').configure ctx
module.exports.push (ctx, next) ->
@name 'HDP Hadoop NM # Start'
lifecycle.nm_start ctx, (err, started) ->
next err, if started then ctx.O... |
lifecycle = require './hdp/lifecycle'
module.exports = []
module.exports.push 'histi/actions/hdp_yarn'
module.exports.push (ctx) ->
require('./hdp_yarn').configure ctx
module.exports.push (ctx, next) ->
@name 'HDP Hadoop NM # Start'
lifecycle.nm_start ctx, (err, started) ->
next err, if started then ctx.O... | Fix pass msg in nm | Fix pass msg in nm | CoffeeScript | mit | ryba-io/ryba,ryba-io/ryba,ryba-io/ryba,ryba-io/ryba,ryba-io/ryba |
779bd07b3fe63f69ded2e9bd9bee8383facbcd3a | src/app/routes/search.coffee | src/app/routes/search.coffee | express = require 'express'
router = express.Router()
# Search
router.get '/search', (req, res) ->
res.render 'search/results', (
title: req.config.title
query: req.query.q
)
module.exports = router
| express = require 'express'
xmler = require 'node-xmler'
router = express.Router()
# Search
router.get '/search', (req, res) ->
if req.query.q
# TODO: Build query and send to BaseX REST server
query = new xmler.Element 'query'
text = new xmler.Element 'text', req.query.q
query.addElement text
res... | Add base query to send to BaseX REST server | Add base query to send to BaseX REST server
The query needs to be properly formatted to xquery, but currently
serves as an example that can be built onto.
| CoffeeScript | mit | nerdenough/swen303-letterdb |
d6bfb58a9cda288cf451c3217a62f27ca09febf0 | app/talk/comment-help.cjsx | app/talk/comment-help.cjsx | React = require 'react'
module?.exports = React.createClass
displayName: 'TalkCommentHelp'
render: ->
<div className="talk-comment-help">
<h1>Guide to commenting on talk</h1>
<p>Talk comments are written in <a href='http://daringfireball.net/projects/markdown/basics'>markdown</a></p>
<p>Ment... | React = require 'react'
module?.exports = React.createClass
displayName: 'TalkCommentHelp'
render: ->
<div className="talk-comment-help">
<h1>Guide to commenting on talk</h1>
<p>Talk comments are written in <a href='http://daringfireball.net/projects/markdown/basics'>markdown</a></p>
<p>Ment... | Update help text subject mentioning syntax options | Update help text subject mentioning syntax options
| CoffeeScript | apache-2.0 | fmnhExhibits/Panoptes-Front-End,mrniaboc/Panoptes-Front-End,parrish/Panoptes-Front-End,jelliotartz/Panoptes-Front-End,edpaget/Panoptes-Front-End,camallen/Panoptes-Front-End,alexbfree/Panoptes-Front-End,mrniaboc/Panoptes-Front-End,zooniverse/Panoptes-Front-End,amyrebecca/Panoptes-Front-End,fmnhExhibits/Panoptes-Front-En... |
92fd0769b2f60621a76a847ad3fbf419be0b5d6e | raw-socket.coffee | raw-socket.coffee | net = require 'net'
server = (comp) ->
net.createServer (socket) ->
sendEvent = (event) ->
socket.write JSON.stringify(event) + "\n"
stopListening = comp.events.onValue sendEvent
for event in comp.seedRecords()
sendEvent event
socket.on 'end', ->
do stopListening
module.exports ... | net = require 'net'
server = (comp) ->
net.createServer (socket) ->
sendEvent = (event) ->
try
socket.write JSON.stringify(event) + "\n"
catch error
do stopListening
stopListening = comp.events.onValue sendEvent
for event in comp.seedRecords()
sendEvent event
sock... | Fix error on closed socket | Fix error on closed socket
| CoffeeScript | mit | prophile/srcomp-stream |
9f75f4eaa398fcb8204d3fd0479bafbca2642c7d | gulpfile.coffee | gulpfile.coffee | gulp = require 'gulp'
# Browserify
browserify = require 'browserify'
source = require 'vinyl-source-stream'
gulp.task 'build', ->
browserify('./OperationalTransform.coffee', extensions: ['.coffee'], standalone: 'OperationalTransform')
.bundle()
.pipe source 'OperationalTransform.js'
.pipe gulp... | gulp = require 'gulp'
# Browserify
browserify = require 'browserify'
source = require 'vinyl-source-stream'
gulp.task 'build', ->
browserify('./OperationalTransform.coffee', extensions: ['.coffee'], standalone: 'OperationalTransform')
.bundle()
.pipe source 'OperationalTransform.js'
.pipe gulp... | Watch by default, add "gulp nowatch" variant | Watch by default, add "gulp nowatch" variant
| CoffeeScript | mit | sparklinlabs/operational-transform,sparklinlabs/operational-transform |
d8e0cdc6cc1a0c8891b84ef2c72377cb25eb5bb9 | src/test/coffee/MeducationFrontEndSpec.coffee | src/test/coffee/MeducationFrontEndSpec.coffee | describe "Meducation Front-end Application Module", () ->
it "should be available as a module", () ->
frontEndApplicationModule = angular.module "meducationFrontEnd"
expect(frontEndApplicationModule.name).toBe "meducationFrontEnd" | describe 'Meducation Front-end Application Module', () ->
it 'should be available as a module', () ->
frontEndApplicationModule = angular.module 'meducationFrontEnd'
expect(frontEndApplicationModule.name).toBe 'meducationFrontEnd'
| Use single quotes to conform with style guide | Use single quotes to conform with style guide
| CoffeeScript | agpl-3.0 | meducation/front-end,meducation/front-end |
ae174585782b57a092ff14c65497380dd4e93aac | lib/main.coffee | lib/main.coffee | module.exports =
activate: ->
return
# deactivate: ->
provideBuildService: ->
register: (name, details) ->
console.log(name)
| module.exports =
activate: ->
@commands = atom.commands.add 'atom-workspace',
'gluon:build': =>
fn() if fn = @builders[Object.keys(@builders)?[0]]
deactivate: ->
@commands.dispose()
provideBuildService: ->
register: (name, details) =>
@builders ?= {}
@builders[name] = detai... | Add PoC register API method | Add PoC register API method
| CoffeeScript | mit | thomasjo/gluon |
0ca7113ca22a8456d547d0e40cdd944a3d7d3aee | lib/main.coffee | lib/main.coffee | SpellCheckView = null
module.exports =
configDefaults:
grammars: [
'source.gfm'
'text.git-commit'
'text.plain'
]
activate: ->
@editorSubscription = atom.workspaceView.eachEditorView(addViewToEditor)
deactivate: ->
@editorSubscription?.off()
addViewToEditor = (editorView) ->
... | SpellCheckView = null
module.exports =
configDefaults:
grammars: [
'source.gfm'
'text.git-commit'
'text.plain'
'text.plain.null-grammar'
]
activate: ->
@editorSubscription = atom.workspaceView.eachEditorView(addViewToEditor)
deactivate: ->
@editorSubscription?.off()
add... | Add null grammar to defaults | Add null grammar to defaults
| CoffeeScript | mit | atom/spell-check |
1ec89805f1631d8ad80c26a6ca5ec17119ab8104 | app/assets/javascripts/controllers/editor.coffee | app/assets/javascripts/controllers/editor.coffee | Mercury.PageEditor::setFrameSource = (url)->
newPath = "#{path}?_=#{new Date().getTime()}"
@iframe.get(0).contentWindow.document.location.href = newPath
class CMSimple.Editor extends Spine.Controller
el: 'body'
constructor: (@current_page)->
super()
@setCurrentPage(@current_page)
@initializeMercury... | Mercury.PageEditor::setFrameSource = (url)->
newUrl = "#{url}?_=#{new Date().getTime()}"
@iframe.get(0).contentWindow.document.location.href = newUrl
class CMSimple.Editor extends Spine.Controller
el: 'body'
constructor: (@current_page)->
super()
@setCurrentPage(@current_page)
@initializeMercury()
... | Fix typo in local var names for setting the iframe source | Fix typo in local var names for setting the iframe source | CoffeeScript | mit | modeset/cmsimple,modeset/cmsimple,modeset/cmsimple |
7b5bfa08892624b20c1e46f02bc9a137330bad6a | client/test/src/report_edit_visualisation_view.coffee | client/test/src/report_edit_visualisation_view.coffee | assert = chai.assert
createAndShowVisualisationViewForOptions = (options) ->
view = new Backbone.Views.ReportEditVisualisationView(options)
view.render()
$('#test-container').html(view.el)
return view
suite('ReportEditVisualisationView')
test("Shows the given indicator title", ->
indicatorTitle = "my lovel... | assert = chai.assert
createAndShowVisualisationViewForOptions = (options) ->
view = new Backbone.Views.ReportEditVisualisationView(options)
view.render()
$('#test-container').html(view.el)
return view
suite('ReportEditVisualisationView')
test("Shows the given indicator title", ->
indicatorTitle = "my lovel... | Test for visualisation edit box save-on-close | Test for visualisation edit box save-on-close
| CoffeeScript | bsd-3-clause | unepwcmc/NRT,unepwcmc/NRT |
5c29cbfa3d05dab22362bac4fc95062b83b8589a | keymaps/list-edit.cson | keymaps/list-edit.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://ato... | # 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://ato... | Add Windows & Linux key bindings | Add Windows & Linux key bindings
| CoffeeScript | mit | Oblosys/atom-list-edit |
5c2938eb5763de03d4abbfcc755cd59e6067f339 | lib/main.coffee | lib/main.coffee | module.exports =
instance: null
config:
lintOnFly:
title: 'Lint on fly'
description: 'Lint files while typing, without the need to save them'
type: 'boolean'
default: true
showErrorInline:
title: "Show Inline Tooltips"
descriptions: "Show inline tooltips for errors"
... | {Disposable} = require('atom')
module.exports =
instance: null
config:
lintOnFly:
title: 'Lint on fly'
description: 'Lint files while typing, without the need to save them'
type: 'boolean'
default: true
showErrorInline:
title: "Show Inline Tooltips"
descriptions: "Show in... | Disable deactivated packages Using the code @AsaAyers suggested | :art: Disable deactivated packages
Using the code @AsaAyers suggested
| CoffeeScript | mit | AtomLinter/Linter,DanPurdy/linter,steelbrain/linter,shawninder/linter,atom-community/linter,josa42/Linter,levity/linter,JohnMurga/linter,blakeembrey/linter,UltCombo/linter,e-jigsaw/Linter,kaeluka/linter,iam4x/linter,AsaAyers/linter,elkeis/linter,simurai/linter-plus,Arcanemagus/linter,mdgriffith/linter |
0718befb200e9ac5b2325a3adea6dc8f38312b64 | server/methods/registerUser.coffee | server/methods/registerUser.coffee | Meteor.methods
registerUser: (formData) ->
userData =
email: formData.email
password: formData.pass
userId = Accounts.createUser userData
Meteor.users.update userId,
$set:
name: formData.name
if userData.email
Accounts.sendVerificationEmail(userId, userData.email);
| Meteor.methods
registerUser: (formData) ->
userData =
email: formData.email
password: formData.pass
userId = Accounts.createUser userData
Meteor.users.update userId,
$set:
name: formData.name
active: true
if userData.email
Accounts.sendVerificationEmail(userId, userData.email);
| Set active: true on registration | Set active: true on registration
| CoffeeScript | mit | matthewshirley/Rocket.Chat,wangleihd/Rocket.Chat,flaviogrossi/Rocket.Chat,pitamar/Rocket.Chat,ndarilek/Rocket.Chat,bt/Rocket.Chat,matthewshirley/Rocket.Chat,j-ew-s/Rocket.Chat,acaronmd/Rocket.Chat,abhishekshukla0302/trico,Gyubin/Rocket.Chat,AlecTroemel/Rocket.Chat,AlecTroemel/Rocket.Chat,OtkurBiz/Rocket.Chat,j-ew-s/Roc... |
d09f7742eb3d3506fc85e0a13f3884dcc4d446d5 | src/util.coffee | src/util.coffee | module.exports = class Util
# Return true if uri string is a URI to an image
@isImageUri: (uri) ->
uri.match(/^https?\:\/\/.*\.(jpeg|jpg|gif|png)$/i)?
# Merge input objects into one object
@merge = (xs...) ->
tap = (o, fn) -> fn(o); o
if xs?.length > 0
tap {}, (m) -> m[k] = v for k, v of x f... | module.exports = class Util
# Return true if uri string is a URI to an image
@isImageUri: (uri) ->
uri.match(/^https?\:\/\/.*[\.|=](jpeg|jpg|gif|png)$/i)?
# Merge input objects into one object
@merge = (xs...) ->
tap = (o, fn) -> fn(o); o
if xs?.length > 0
tap {}, (m) -> m[k] = v for k, v of... | Change regex that determines whether a link is to an image | Change regex that determines whether a link is to an image
| CoffeeScript | mit | anroots/hubot-fleep |
57bfef26bc99e8fdd8a58298d70b7e6ccce220dd | test/api_test.coffee | test/api_test.coffee | require './setup'
db = null
describe 'api', ->
afterEach ->
Ento.object.api(undefined)
describe 'mock', ->
beforeEach ->
db = { foo: 200 }
Ento.object.api(db)
it 'api is accessible in model', ->
Model = Ento()
expect(Model.api()).eql db
it 'api is accessible in instance'... | require './setup'
db = null
describe 'api', ->
afterEach ->
Ento.object.api(undefined)
describe 'mock', ->
beforeEach ->
db = { foo: 200 }
Ento.object.api(db)
it 'api is accessible in model', ->
Model = Ento()
expect(Model.api()).eql db
it 'api is accessible in instance'... | Add test for modifying the global API after subclassing. | Add test for modifying the global API after subclassing.
| CoffeeScript | mit | rstacruz/ento |
f42cf8099d75576b170c705783a1e50894d8b428 | core/app/backbone/controllers/client_controller.coffee | core/app/backbone/controllers/client_controller.coffee | class window.ClientController
constructor: (@annotatedSiteEnvoy) ->
showFact: (fact_id) ->
@_renderDiscussion new Fact id: fact_id
showNewFact: (params={}) =>
fact = new Fact
displaystring: params.displaystring
url: params.url
site_title: params.site_title
if FactlinkApp.signedIn()... | class window.ClientController
constructor: (@annotatedSiteEnvoy) ->
showFact: (fact_id) ->
@_renderDiscussion new Fact id: fact_id
showNewFact: (params={}) =>
fact = new Fact
displaystring: params.displaystring
url: params.url
site_title: params.site_title
if FactlinkApp.signedIn()... | Make client/facts/new support asynchronous user loading | Make client/facts/new support asynchronous user loading
| CoffeeScript | mit | Factlink/factlink-core,Factlink/factlink-core,daukantas/factlink-core,Factlink/factlink-core,Factlink/factlink-core,daukantas/factlink-core,daukantas/factlink-core,daukantas/factlink-core |
361b7f641def1c5d0fd6e88505f73723a182acd8 | test/javascripts/helpers/display_line_breaks.js.coffee | test/javascripts/helpers/display_line_breaks.js.coffee | moduleFor 'helper:displayLineBreaks', 'Unit: Display line breaks',
setup: -> setupApp()
teardown: -> ETahi.reset()
test "#displayLineBreaks", ->
fn = Em.Handlebars.helpers.displayLineBreaks._rawFunction
equal fn("Tahi\nis\ncool").string, "Tahi<br>is<br>cool"
equal fn("").string, ""
| module 'helper:displayLineBreaks', 'Unit: Display line breaks',
setup: -> setupApp()
teardown: -> ETahi.reset()
test "#displayLineBreaks", ->
fn = Em.Handlebars.helpers.displayLineBreaks._rawFunction
equal fn("Tahi\nis\ncool").string, "Tahi<br>is<br>cool"
equal fn("").string, ""
| Fix display line breaks test | Fix display line breaks test
| CoffeeScript | mit | johan--/tahi,johan--/tahi,johan--/tahi,johan--/tahi |
72cda51b6b659384fe6c8aecbcec055f2b3f3989 | Gruntfile.coffee | Gruntfile.coffee | module.exports = (grunt) ->
grunt.initConfig
pkg: grunt.file.readJSON('package.json')
coffee:
glob_to_multiple:
expand: true
cwd: 'src'
src: ['*.coffee']
dest: 'lib'
ext: '.js'
coffeelint:
options:
max_line_length:
level: 'ignore'
... | module.exports = (grunt) ->
grunt.initConfig
pkg: grunt.file.readJSON('package.json')
coffee:
glob_to_multiple:
expand: true
cwd: 'src'
src: ['**/*.coffee']
dest: 'lib'
ext: '.js'
coffeelint:
options:
max_line_length:
level: 'ignore'
... | Build coffee files in source subdirs | Build coffee files in source subdirs
| CoffeeScript | mit | acrisci/simple-breakpad-server,Jimbly/simple-breakpad-server,Jimbly/simple-breakpad-server,acrisci/simple-breakpad-server |
bc84050be06a23ce31ecb4ba9dfa3559d54fc0eb | vendor/assets/javascripts/fustrate/generic_page.coffee | vendor/assets/javascripts/fustrate/generic_page.coffee | class Fustrate.GenericPage
constructor: (@root) ->
@_reloadUIElements()
@addEventListeners()
@initialize()
addEventListeners: ->
# Once the interface is loaded and the event listeners are active, run any
# other tasks.
initialize: ->
_reloadUIElements: =>
@fields = {}
@buttons = {}
... | class Fustrate.GenericPage
constructor: (@root) ->
@_reloadUIElements()
@addEventListeners()
@initialize()
addEventListeners: ->
# Once the interface is loaded and the event listeners are active, run any
# other tasks.
initialize: ->
_reloadUIElements: =>
@fields = {}
@buttons = {}
... | Add a common refresh function | Add a common refresh function
Signed-off-by: Steven Hoffman <f5bcacb8ce1651b7d1e56f2693431f20e085fdeb@valenciamgmt.com>
| CoffeeScript | mit | Fustrate/fustrate-rails |
d87ad702c921b7b5d3860f0d15b6beaec7a45034 | app/assets/javascripts/angular_app/directives/uoGraph.js.coffee | app/assets/javascripts/angular_app/directives/uoGraph.js.coffee | angular.module('InescApp').directive 'uoGraph', ['$filter', ($filter) ->
columns = [
{ sTitle: 'Entidade Orçamentária', bSortable: false }
{ sTitle: 'Orçamento Autorizado', bSortable: false, sClass: 'currency' }
{ sTitle: 'Percentual do total', bSortable: false, sClass: 'percentual' }
{ sTitle: 'Orçam... | angular.module('InescApp').directive 'uoGraph', ['$filter', ($filter) ->
columns = [
{ sTitle: 'Entidade Orçamentária', bSortable: false }
{ sTitle: 'Orçamento Autorizado', bSortable: false, sClass: 'currency' }
{ sTitle: 'Percentual do total', bSortable: false, sClass: 'percentual' }
{ sTitle: 'Orçam... | Remove rodapé da distribuição por unidade orçamentária | Remove rodapé da distribuição por unidade orçamentária
| CoffeeScript | mit | okfn-brasil/orcamento.inesc.org.br,okfn-brasil/orcamento.inesc.org.br,okfn-brasil/orcamento.inesc.org.br |
9da03d44aca066365da3965badbd938dcf9094ec | app/assets/asset/view.coffee | app/assets/asset/view.coffee | 'use strict'
app.controller 'asset/view', [
'$scope', 'displayService', 'asset',
($scope, display, asset) ->
$scope.asset = asset
display.title = asset.displayName
$scope.volume = asset.volume
$scope.hasThumbnail = (asset.format.type == 'image' || asset.format.type == 'video' && asset.duration && !... | 'use strict'
app.controller 'asset/view', [
'$scope', 'displayService', 'asset',
($scope, display, asset) ->
$scope.close = ->
window.history.back()
$scope.asset = asset
display.title = asset.displayName
$scope.volume = asset.volume
$scope.hasThumbnail = (asset.format.type == 'image' || a... | Make the "x" button work by going back. | Make the "x" button work by going back.
| CoffeeScript | agpl-3.0 | databrary/databrary,databrary/databrary,databrary/databrary,databrary/databrary |
2627f26b561c2f2b64b961aed14f8a401cd110c3 | lib/convert-options.coffee | lib/convert-options.coffee | mozilla = require('source-map')
module.exports = (old) ->
opts = { }
map = { }
for name, value of old
if name == 'map'
if value == 'inline'
map.inline = true
else if typeof(value) == 'string'
map.prev = value
else if value instanceof mozilla.SourceMapConsumer
map.... | mozilla = require('source-map')
deprected = (from, to) ->
console.warn(
"Option #{ from } is deprected and will be deleted in PostCSS 1.1.\n" +
"Use map: { #{ to } } instead.")
module.exports = (old) ->
opts = { }
map = { }
for name, value of old
if name == 'map'
if value == 'inline'
... | Add deprected warnings to old options | Add deprected warnings to old options
| CoffeeScript | mit | f/postcss,chengky/postcss,pascalduez/postcss,mxstbr/postcss,dmsanchez86/postcss,marcustisater/postcss,postcss/postcss,harrykiselev/postcss,eprincev-egor/postcss,webdev1001/postcss,sandralundgren/postcss,mahtd/postcss,longdog/postcss,jedmao/postcss,andrepolischuk/postcss,XOP/postcss,CapeSepias/postcss,gitkiselev/postcss... |
67a86ae60702f0b80e465f21d51e3b5555d35e4c | app/assets/javascripts/backbone/views/tree_view.js.coffee | app/assets/javascripts/backbone/views/tree_view.js.coffee | class Water.TreeView extends Backbone.View
initialize: () ->
@model.on("change:data", @render_tree)
@model.on("start_fetch", @render_loading)
render_tree: () =>
$("#indicator").hide()
@$el.hide()
@$el.html @model.get("data")
@$el.fadeIn("slow")
render_loading: () =>
loading_ind... | class Water.TreeView extends Backbone.View
initialize: () ->
# Bind to events in the model
@model.on("change:data", @render_tree)
@model.on("start_fetch", @render_loading)
# Re-renders the tree whenever the data in the model changes
render_tree: () =>
# Hide the activity indicator
$("#indic... | Add comments to clientside code | Add comments to clientside code
| CoffeeScript | agpl-3.0 | water/mainline,water/mainline,water/mainline |
5e05f11127f29122e8e010303d3b85002c4213ab | lib/load-paths-task.coffee | lib/load-paths-task.coffee | _ = require 'underscore'
BufferedProcess = require 'buffered-process'
module.exports =
class LoadPathsTask
constructor: (@callback) ->
start: ->
rootPath = project.getPath()
ignoredNames = config.get('fuzzyFinder.ignoredNames') ? []
ignoredNames = ignoredNames.concat(config.get('core.ignoredNames') ? ... | _ = require 'underscore'
BufferedProcess = require 'buffered-process'
module.exports =
class LoadPathsTask
constructor: (@callback) ->
start: ->
rootPath = project.getPath()
ignoredNames = config.get('fuzzyFinder.ignoredNames') ? []
ignoredNames = ignoredNames.concat(config.get('core.ignoredNames') ? ... | Use more generic core.excludeVcsIgnoredPaths config key | Use more generic core.excludeVcsIgnoredPaths config key
| CoffeeScript | mit | toshi-saito/fuzzy-finder,pombredanne/fuzzy-finder,segiddins/fuzzy-finder,gvanderest/fuzzy-finder,viddo/fuzzy-finder,nielsAD/fuzzy-finder,Kerruba/fuzzy-finder,pombredanne/fuzzy-finder,Spy-Seth/fuzzy-finder,Kerruba/fuzzy-finder,segiddins/fuzzy-finder,nielsAD/fuzzy-finder,atom/fuzzy-finder,gvanderest/fuzzy-finder,Spy-Seth... |
79dfb9ea8d049ff9884be24ad81dd4684f76aef7 | src/index.coffee | src/index.coffee |
express = require 'express'
stylus = require 'stylus'
assets = require 'connect-assets'
mongoose = require 'mongoose'
#### Basic application initialization
# Create app instance.
app = express()
# Define Port
app.port = process.env.PORT or process.env.VMC_APP_PORT or 3000
# Config module exports has `setEnvironme... |
express = require 'express'
stylus = require 'stylus'
assets = require 'connect-assets'
mongoose = require 'mongoose'
#### Basic application initialization
# Create app instance.
app = express()
# Define Port
app.port = process.env.PORT or process.env.VMC_APP_PORT or 3000
# Config module exports has `setEnvironme... | Read mongodb connection from config. | Read mongodb connection from config.
| CoffeeScript | mit | vinz243/seedbot,twilson63/express-coffee,ocef/coffee-express,pengkui/coffee-express,qas612820704/express-coffee,pengkui/coffee-express,nikezono/WYSIWIKI,twilson63/express-coffee,kuwabarahiroshi/github-push-notif,frogbotherer/mine-js,macklinu/send-a-message,kuwabarahiroshi/github-push-notif,andrewkshim/GangnamWave,tranh... |
797e00ba30a4c3a3b1c8b435c8c4cef388814059 | core/app/backbone/modules/overlay.coffee | core/app/backbone/modules/overlay.coffee | FactlinkApp.module "Overlay", (Overlay, FactlinkApp, Backbone, Marionette, $, _) ->
$overlay_elements = $('<div class="overlay"></div><div class="overlay-transparent"></div>')
.appendTo('body')
$focus_el = null
Overlay.show = ($el) ->
$overlay_elements.fadeIn 'fast'
$focus_el = $el
$focus_el?.a... | FactlinkApp.module "Overlay", (Overlay, FactlinkApp, Backbone, Marionette, $, _) ->
$overlay_elements = $('<div class="overlay"></div><div class="overlay-transparent"></div>')
.appendTo('body')
$focus_el = null
Overlay.show = ($el) ->
$overlay_elements.fadeIn 'fast'
Overlay.removeFocus()
$focus... | Remove focus when calling 'show' twice | Remove focus when calling 'show' twice
| CoffeeScript | mit | Factlink/factlink-core,daukantas/factlink-core,daukantas/factlink-core,daukantas/factlink-core,Factlink/factlink-core,Factlink/factlink-core,Factlink/factlink-core,daukantas/factlink-core |
dcc838b3d82d3cdc79b317b96b766fbcc0c3cd94 | app/assets/javascripts/budget_edit_associations.js.coffee | app/assets/javascripts/budget_edit_associations.js.coffee | App.BudgetEditAssociations =
set_text: (response)->
$(".js-budget-show-administrators-list").text(response["administrators"])
$(".js-budget-show-valuators-list").text(response["valuators"])
$(".js-budget-show-trackers-list").text(response["trackers"])
initialize: ->
$(".js-budget-list-checkbox-use... | App.BudgetEditAssociations =
set_text: (response)->
$(".js-budget-show-administrators-list").text(response["administrators"])
$(".js-budget-show-valuators-list").text(response["valuators"])
$(".js-budget-show-trackers-list").text(response["trackers"])
initialize: ->
$(".js-budget-list-checkbox-use... | Make conditions easier to read | Make conditions easier to read
Combining both the inline and "traditional" `if` styles made the code
difficult to read, particularly when compiled to JavaScript.
| CoffeeScript | agpl-3.0 | consul/consul,consul/consul,usabi/consul_san_borondon,consul/consul,usabi/consul_san_borondon,consul/consul,usabi/consul_san_borondon,consul/consul,usabi/consul_san_borondon |
b09c0a080c61a503b3df090ae0b554cffdc2b45a | test/javascripts/views/paper_edit_view_test.js.coffee | test/javascripts/views/paper_edit_view_test.js.coffee | moduleFor 'view:paperEdit', 'Unit: paperEditView',
teardown: ->
ETahi.VisualEditorService.create.restore()
ETahi.reset()
setup: ->
paper = Ember.Object.create
title: ''
shortTitle: 'Does not matter'
body: 'hello'
sinon.stub(ETahi.VisualEditorService, 'create').returns
enabl... | moduleFor 'view:paperEdit', 'Unit: paperEditView',
teardown: ->
ETahi.VisualEditorService.create.restore()
ETahi.reset()
setup: ->
paper = Ember.Object.create
id: 5
title: ''
shortTitle: 'Does not matter'
body: 'hello'
sinon.stub(ETahi.VisualEditorService, 'create').returns... | Add missing id to paper test data. | Add missing id to paper test data.
The associated tests were throwing an error when the paper id
was undefined.
| CoffeeScript | mit | johan--/tahi,johan--/tahi,johan--/tahi,johan--/tahi |
490ccc6051bc5af026dd5da8e38a4f8b095531c8 | services/web/app/coffee/Features/Project/ProjectTokenGenerator.coffee | services/web/app/coffee/Features/Project/ProjectTokenGenerator.coffee | crypto = require 'crypto'
module.exports = ProjectTokenGenerator =
readOnlyToken: () ->
length = 12
tokenAlpha = 'bcdfghjkmnpqrstvwxyz'
result = ''
crypto.randomBytes(length).map( (a) -> result += tokenAlpha[a % tokenAlpha.length] )
return result
readAndWriteToken: () ->
numerics = Math.random().toStri... | crypto = require 'crypto'
# This module mirrors the token generation in Overleaf (`random_token.rb`),
# for the purposes of implementing token-based project access, like the
# 'unlisted-projects' feature in Overleaf
module.exports = ProjectTokenGenerator =
# (From Overleaf `random_token.rb`)
# Letters (not numb... | Add commentary to token-generator, and move token-alpha to top level | Add commentary to token-generator, and move token-alpha to top level
| CoffeeScript | agpl-3.0 | sharelatex/sharelatex |
1d9e67d7f906e97ef97920805baa6acbe5158a7a | atom/config.cson | atom/config.cson | "*":
"exception-reporting":
userId: "1f6d8ded-d27b-39e5-b84e-95714f424379"
welcome:
showOnStartup: false
core:
projectHome: "/Users/Richard/Dropbox/Projects"
themes: [
"one-dark-ui"
"base16-tomorrow-dark-theme"
]
disabledPackages: [
"relative-numbers"
"timecop"
... | "*":
"exception-reporting":
userId: "1f6d8ded-d27b-39e5-b84e-95714f424379"
welcome:
showOnStartup: false
core:
projectHome: "/Users/Richard/Dropbox/Projects"
themes: [
"one-dark-ui"
"base16-tomorrow-dark-theme"
]
disabledPackages: [
"relative-numbers"
"timecop"
... | Exclude VCS ignored paths in Atom | Exclude VCS ignored paths in Atom
| CoffeeScript | mit | richardkall/dotfiles |
f40ee0404bbe01afd12f7285671bb17f30927e3b | atom/config.cson | atom/config.cson | "*":
core:
disabledPackages: [
"background-tips"
"exception-reporting"
"metrics"
"welcome"
]
editor:
invisibles: {}
showIndentGuide: true
showInvisibles: true
fontFamily: "Source Code Pro"
| "*":
core:
disabledPackages: [
"background-tips"
"exception-reporting"
"metrics"
"styleguide"
"timecop"
"welcome"
]
editor:
invisibles: {}
showIndentGuide: true
showInvisibles: true
fontFamily: "Source Code Pro"
| Disable some Atom packages by default | Disable some Atom packages by default | CoffeeScript | mit | jmlntw/dotfiles,jmlntw/dotfiles |
a2c8b48b951adb922583ab69338225d529aac932 | apps/user/profile/index.coffee | apps/user/profile/index.coffee | Backbone = require 'backbone'
mediator = require '../../../lib/mediator.coffee'
template = -> require('../templates/partials/_channel_groups.jade') arguments...
class ProfileView extends Backbone.View
loading: false
disabled: false
threshold: -500
page: 2
initialize: ->
@timer = setInterval @maybeLoad, ... | Backbone = require 'backbone'
mediator = require '../../../lib/mediator.coffee'
template = -> require('../templates/partials/_channel_groups.jade') arguments...
class ProfileView extends Backbone.View
loading: false
disabled: false
threshold: -500
page: 2
initialize: ->
@timer = setInterval @maybeLoad, ... | Disable loading after no more results | Disable loading after no more results
| CoffeeScript | mit | aredotna/ervell,aredotna/ervell,aredotna/ervell,aredotna/ervell,aredotna/ervell |
902cf833a2bcb61e4ee54b3dcc6316b2d6ac4214 | app/assets/javascripts/components/flash_bar.coffee | app/assets/javascripts/components/flash_bar.coffee | $(document)
.on("click", ".flash-bar-show", ->
$(this).removeClass("flash-bar-show")
)
| $(document)
.on("click touchstart", ".flash-bar-show", ->
$(this).removeClass("flash-bar-show")
)
| Allow touch devices to dismiss flash bar | Allow touch devices to dismiss flash bar
| CoffeeScript | mit | myapnea/www.myapnea.org,myapnea/www.myapnea.org,myapnea/www.myapnea.org |
5d1a3640edc9d18e5c9519a51f10d4ecfa63ecbf | bokehjs/src/coffee/models/transforms/jitter.coffee | bokehjs/src/coffee/models/transforms/jitter.coffee | _ = require "underscore"
Transform = require "./transform"
class Jitter extends Transform.Model
initialize: (attrs, options) ->
super(attrs, options)
defaults: ->
return _.extend({}, super(), {
width: 1
})
compute: (x) ->
# Apply the transform to a single value
return(x + ((Math.rando... | _ = require "underscore"
Transform = require "./transform"
class Jitter extends Transform.Model
initialize: (attrs, options) ->
super(attrs, options)
defaults: ->
return _.extend({}, super(), {
width: 1
})
compute: (x) ->
# Apply the transform to a single value
return(x + ((Math.rando... | Remove unessessary old commented code | Remove unessessary old commented code
| CoffeeScript | bsd-3-clause | aavanian/bokeh,ericmjl/bokeh,bokeh/bokeh,aavanian/bokeh,Karel-van-de-Plassche/bokeh,clairetang6/bokeh,schoolie/bokeh,ericmjl/bokeh,mindriot101/bokeh,mindriot101/bokeh,stonebig/bokeh,bokeh/bokeh,phobson/bokeh,timsnyder/bokeh,phobson/bokeh,DuCorey/bokeh,phobson/bokeh,Karel-van-de-Plassche/bokeh,aiguofer/bokeh,dennisobrie... |
ffae47fd69817561410755e5d5ffb21820f9ef33 | src/coffee/cilantro.coffee | src/coffee/cilantro.coffee | define [
'./cilantro/core'
'./cilantro/changelog'
'./cilantro/models'
'./cilantro/structs'
'./cilantro/ui'
], (c, changelog, models, structs, ui) ->
c.changelog = changelog
c.models = models
c.structs = structs
c.ui = ui
# Defines the minimum version of Serrano that this versio... | define [
'./cilantro/core'
'./cilantro/changelog'
'./cilantro/models'
'./cilantro/structs'
'./cilantro/ui'
], (c, changelog, models, structs, ui) ->
c.changelog = changelog
c.models = models
c.structs = structs
c.ui = ui
# Defines the minimum version of Serrano that this versio... | Drop the minimum Serrano version to >= 2.0.24 | Drop the minimum Serrano version to >= 2.0.24
| CoffeeScript | bsd-2-clause | chop-dbhi/cilantro,chop-dbhi/cilantro,chop-dbhi/cilantro |
3d5a15e547f079f4792fce8e822a5f2111533a10 | atom/config.cson | atom/config.cson | "*":
autosave:
enabled: true
core:
audioBeep: false
themes: [
"one-light-ui"
"one-light-syntax"
]
projectHome: "/Users/randy/src"
editor:
fontFamily: "Hack"
fontSize: 19
invisibles: {}
showIndentGuide: true
tabType: "soft"
emmet: {}
"exception-reporting":
... | "*":
autosave:
enabled: true
core:
audioBeep: false
]
projectHome: "/Users/randy/src"
editor:
fontFamily: "Hack"
fontSize: 19
invisibles: {}
showIndentGuide: true
tabType: "soft"
emmet: {}
"exception-reporting":
userId: "30e6f2d0-42d3-ab77-4984-dde4c431f019"
"expand-r... | Switch back to dark themes | Switch back to dark themes
| CoffeeScript | mit | randycoulman/dotfiles |
2cd68faccadb3d2e01956c23281b1dfad53a7a01 | client/landing/Workspace/panes/terminalpane.coffee | client/landing/Workspace/panes/terminalpane.coffee | class TerminalPane extends Pane
constructor: (options = {}, data) ->
options.cssClass = "terminal-pane terminal"
options.delay ?= 0
super options, data
@createWebTermView()
@webterm.on "WebTermConnected", (@remote) =>
@emit "WebtermCreated"
@onWebTermConnected()
createWebTer... | class TerminalPane extends Pane
constructor: (options = {}, data) ->
options.cssClass = "terminal-pane terminal"
options.delay ?= 0
super options, data
@createWebTermView()
createWebTermView: ->
KD.singletons.vmController.fetchDefaultVm (err, vm)=>
@webterm = new WebTe... | Fix TerminalPane until we support for multiple vms | Fix TerminalPane until we support for multiple vms
| CoffeeScript | agpl-3.0 | acbodine/koding,sinan/koding,rjeczalik/koding,drewsetski/koding,usirin/koding,sinan/koding,drewsetski/koding,koding/koding,koding/koding,mertaytore/koding,andrewjcasal/koding,gokmen/koding,kwagdy/koding-1,koding/koding,alex-ionochkin/koding,acbodine/koding,cihangir/koding,jack89129/koding,koding/koding,sinan/koding,cih... |
83c9a94ac9fc2cf0991cba0956c488da2a6b96ff | raspberrypi2.coffee | raspberrypi2.coffee | deviceTypesCommon = require '@resin.io/device-types/common'
{ networkOptions, commonImg, instructions } = deviceTypesCommon
module.exports =
version: 1
slug: 'raspberry-pi2'
aliases: [ 'raspberrypi2' ]
name: 'Raspberry Pi 2'
arch: 'armv7hf'
state: 'released'
instructions: commonImg.instructions
gettingStarted... | deviceTypesCommon = require '@resin.io/device-types/common'
{ networkOptions, commonImg, instructions } = deviceTypesCommon
module.exports =
version: 1
slug: 'raspberry-pi2'
aliases: [ 'raspberrypi2' ]
name: 'Raspberry Pi 2'
arch: 'armv7hf'
state: 'released'
imageDownloadAlerts: [
{
type: 'warning'
mes... | Add warning advising of no WiFi on Pi 2 | Add warning advising of no WiFi on Pi 2
Changelog-entry: Add warning advising of no WiFi on Pi 2
Change-type: patch
Signed-off-by: Chris Crocker-White <55144d225ecaa64cbddbc62fe6b6637fa9671c59@balena.io>
| CoffeeScript | apache-2.0 | resin-os/resin-raspberrypi,resin-os/resin-raspberrypi |
4fc2dcc4f479f0d2676004406b247548bfc64c86 | app/assets/javascripts/breakpoints.coffee | app/assets/javascripts/breakpoints.coffee | class @Breakpoints
instance = null;
class BreakpointInstance
BREAKPOINTS = ["xs", "sm", "md", "lg"]
constructor: ->
@setup()
setup: ->
allDeviceSelector = BREAKPOINTS.map (breakpoint) ->
".device-#{breakpoint}"
return if $(allDeviceSelector.join(",")).length
# Create... | class @Breakpoints
instance = null;
class BreakpointInstance
BREAKPOINTS = ["xs", "sm", "md", "lg"]
constructor: ->
@setup()
setup: ->
allDeviceSelector = BREAKPOINTS.map (breakpoint) ->
".device-#{breakpoint}"
return if $(allDeviceSelector.join(",")).length
# Create ... | Fix bug with JS error from dropdowns in filter area | Fix bug with JS error from dropdowns in filter area
| CoffeeScript | mit | shinexiao/gitlabhq,martijnvermaat/gitlabhq,shinexiao/gitlabhq,darkrasid/gitlabhq,martijnvermaat/gitlabhq,stoplightio/gitlabhq,mmkassem/gitlabhq,icedwater/gitlabhq,iiet/iiet-git,Soullivaneuh/gitlabhq,iiet/iiet-git,dwrensha/gitlabhq,allysonbarros/gitlabhq,dwrensha/gitlabhq,t-zuehlsdorff/gitlabhq,Soullivaneuh/gitlabhq,dpl... |
2b93814fb1f7cc044fe5903b97c2d27d56fd6439 | app/assets/javascripts/shared/directives/question_mark_tooltip.js.coffee | app/assets/javascripts/shared/directives/question_mark_tooltip.js.coffee |
OFNShared.directive "questionMarkWithTooltip", ($tooltip)->
# We use the $tooltip service from Angular foundation to give us boilerplate
# Subsequently we patch the scope, template and restrictions
tooltip = $tooltip 'questionMarkWithTooltip', 'questionMarkWithTooltip', 'click'
tooltip.scope =
variant: "="... |
OFNShared.directive "questionMarkWithTooltip", ($tooltip)->
# We use the $tooltip service from Angular foundation to give us boilerplate
# Subsequently we patch the scope, template and restrictions
tooltip = $tooltip 'questionMarkWithTooltip', 'questionMarkWithTooltip', 'click'
tooltip.scope =
context: "="... | Add context inside scope: used to specify display | Add context inside scope: used to specify display
- Context is used to customize some CSS specifications as sometimes display can be different (depending on the context)
- variant variable was not used: copy/paste error
| CoffeeScript | agpl-3.0 | mkllnk/openfoodnetwork,Matt-Yorkley/openfoodnetwork,lin-d-hop/openfoodnetwork,Matt-Yorkley/openfoodnetwork,lin-d-hop/openfoodnetwork,openfoodfoundation/openfoodnetwork,lin-d-hop/openfoodnetwork,openfoodfoundation/openfoodnetwork,mkllnk/openfoodnetwork,mkllnk/openfoodnetwork,openfoodfoundation/openfoodnetwork,openfoodfo... |
31f9c57c70a7121e6a7cafe628ea78a42669f4e7 | app/assets/javascripts/views/components/toolbar.js.coffee | app/assets/javascripts/views/components/toolbar.js.coffee | Wheelmap.StatusFilterButtonComponent = Wheelmap.WheelchairPopoverComponent.extend
tagName: 'button'
classNameBindings: [':btn', 'isActive:active', ':btn-info', 'wheelchair']
wheelchair: null
activeFilters: null
template: Ember.Handlebars.compile('<span></span>')
popoverOptions:
trigger: 'hover'
pla... | Wheelmap.StatusFilterButtonComponent = Wheelmap.WheelchairPopoverComponent.extend
tagName: 'button'
classNameBindings: [':btn', 'isActive:active', ':btn-info', 'wheelchair']
wheelchair: null
activeFilters: null
template: Ember.Handlebars.compile('<span></span>')
popoverOptions:
trigger: 'hover'
pla... | Add first draft for better presentation of info popups in responsive toolbar. | Add first draft for better presentation of info popups in responsive toolbar.
| CoffeeScript | agpl-3.0 | sozialhelden/wheelmap,sozialhelden/wheelmap,sozialhelden/wheelmap,sozialhelden/wheelmap,sozialhelden/wheelmap |
c275dfe386fc8430a87e0cd5649239af966a8c62 | keymaps/autocomplete-plus.cson | keymaps/autocomplete-plus.cson | ".autocomplete-plus input.hidden-input":
"tab": "autocomplete-plus:confirm"
"down": "autocomplete-plus:select-next"
"up": "autocomplete-plus:select-previous"
"escape": "autocomplete-plus:cancel"
".editor":
"ctrl-shift-space": "autocomplete-plus:activate"
| ".autocomplete-plus input.hidden-input":
"tab": "autocomplete-plus:confirm"
"down": "autocomplete-plus:select-next"
"ctrl-n": "autocomplete-plus:select-next"
"up": "autocomplete-plus:select-previous"
"ctrl-p": "autocomplete-plus:select-previous"
"escape": "autocomplete-plus:cancel"
".editor":
"ctrl-shift... | Add ctrl-n,p emacs bindings for next, previous | Add ctrl-n,p emacs bindings for next, previous
Emacs binds are supported through most of the rest of Atom. Plus it's rough having to drop down to the arrow keys in the midst of typing :) | CoffeeScript | mit | Lyleo/autocomplete-plus,atom/autocomplete-plus,lestat220255/autocomplete-plus,brntbeer/autocomplete-plus,atom-community/autocomplete-plus,kevinsawicki/autocomplete-plus,wakermahmud/autocomplete-plus,kevinsawicki/autocomplete-plus |
d60c49d97c2ae139809b3bef15a4fdb8b4be4343 | client/app/Applications/Chat.kdapplication/Views/mainchatpanel.coffee | client/app/Applications/Chat.kdapplication/Views/mainchatpanel.coffee | class MainChatPanel extends JView
constructor:->
super
cssClass : 'main-chat-panel'
@registerSingleton "chatPanel", @, yes
@conversationList = new ChatConversationListView
@conversationListController = new ChatConversationListController
view : @conversationList
viewAppended:->
@a... | class MainChatPanel extends JView
constructor:->
super
cssClass : 'main-chat-panel visible'
@registerSingleton "chatPanel", @, yes
@conversationList = new ChatConversationListView
@conversationListController = new ChatConversationListController
view : @conversationList
viewAppended:-... | Make it visible by default for testing fastly | Make it visible by default for testing fastly
| CoffeeScript | agpl-3.0 | usirin/koding,szkl/koding,acbodine/koding,szkl/koding,drewsetski/koding,szkl/koding,andrewjcasal/koding,jack89129/koding,rjeczalik/koding,jack89129/koding,kwagdy/koding-1,szkl/koding,jack89129/koding,alex-ionochkin/koding,rjeczalik/koding,rjeczalik/koding,jack89129/koding,kwagdy/koding-1,koding/koding,acbodine/koding,d... |
3916e435f9fdd3bf6cdbbc9e31ffd210ca48f292 | prod/src/coffee-script/node/camparser.coffee | prod/src/coffee-script/node/camparser.coffee | sys = require 'sys'
fs = require 'fs'
xml2js = require 'xml2js'
_ = require 'underscore'
URL = require 'url'
mongoose = require 'mongoose'
parser = new xml2js.Parser()
parser.addListener 'end', (result) ->
Camera = new mongoose.Schema
name: String
url: String
loc:
x: Number
... | sys = require 'sys'
fs = require 'fs'
xml2js = require 'xml2js'
_ = require 'underscore'
URL = require 'url'
mongoose = require 'mongoose'
parser = new xml2js.Parser()
parser.addListener 'end', (result) ->
# Define the mongoose schema
Camera = new mongoose.Schema
name: String
url: String
... | Add some comments and logging to the cam parser. | Add some comments and logging to the cam parser.
| CoffeeScript | mit | krismolendyke/traphicam,krismolendyke/traphicam |
c9fcce0e0363e63a4fc5056e587a4a6e23876e37 | app/cells/markdown_readonly/markdown_readonly.coffee | app/cells/markdown_readonly/markdown_readonly.coffee | #= require jquery
$(document).on 'uic:domchange', (e) ->
$(e.target).find('[data-toggle="markdown-readonly"]').each (_, el) ->
$el = $(el)
$el.html(marked(decodeURIComponent($el.data('markdown'))))
$el.show()
| $(document).on 'uic:domchange', (e) ->
$(e.target).find('[data-toggle="markdown-readonly"]').each (_, el) ->
$el = $(el)
$el.html(marked(decodeURIComponent($el.data('markdown'))))
$el.show()
| Remove require directive from component JS | Remove require directive from component JS
| CoffeeScript | mit | ad2games/ui_components,ad2games/ui_components,ad2games/ui_components |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.