id
stringlengths
34
124
type
stringclasses
4 values
prompt
stringlengths
0
4.95k
response
stringlengths
21
4.89k
source_lang
stringclasses
3 values
target_lang
stringclasses
2 values
repo
stringclasses
75 values
path
stringlengths
10
88
license
stringclasses
1 value
commit
stringlengths
40
40
stars
int64
431
18.7k
source_url
stringlengths
86
176
line_start
int64
1
214
line_end
int64
3
253
Atraci/Atraci:coffee/_search.coffee:1:raw_corpus
raw_corpus
$ -> $('#Search input').keypress (e) -> if e.which is 13 and $(@).val() != '' userTracking.event("Search", "organic", $(@).val()).send() $('#SideBar li.active').removeClass('active') $('#ContentWrapper').empty() spinner = new Spinner(spinner_opts).spin($('#Con...
CoffeeScript
Atraci/Atraci
coffee/_search.coffee
MIT
978a3c17e1eaf3d94e0fabc8625c36ba28a482b2
800
https://github.com/Atraci/Atraci/blob/978a3c17e1eaf3d94e0fabc8625c36ba28a482b2/coffee/_search.coffee
1
22
Atraci/Atraci:coffee/_search.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript $ -> $('#Search input').keypress (e) -> if e.which is 13 and $(@).val() != '' userTracking.event("Search", "organic", $(@).val()).send() $('#SideBar li.active').removeClass('active') $('#ContentWrapper').empty() ...
$(function() { $('#Search input').keypress(function(e) { var spinner; if (e.which === 13 && $(this).val() !== '') { userTracking.event("Search", "organic", $(this).val()).send(); $('#SideBar li.active').removeClass('active'); $('#ContentWrapper').empty(); spinner = new Spinner(spinner_...
CoffeeScript
JavaScript
Atraci/Atraci
coffee/_search.coffee
MIT
978a3c17e1eaf3d94e0fabc8625c36ba28a482b2
800
https://github.com/Atraci/Atraci/blob/978a3c17e1eaf3d94e0fabc8625c36ba28a482b2/coffee/_search.coffee
1
22
Atraci/Atraci:coffee/_search.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript $(function() { $('#Search input').keypress(function(e) { var spinner; if (e.which === 13 && $(this).val() !== '') { userTracking.event("Search", "organic", $(this).val()).send(); $('#SideBar li.active').removeClass('active'); $('#Content...
$ -> $('#Search input').keypress (e) -> if e.which is 13 and $(@).val() != '' userTracking.event("Search", "organic", $(@).val()).send() $('#SideBar li.active').removeClass('active') $('#ContentWrapper').empty() spinner = new Spinner(spinner_opts).spin($('#Con...
JavaScript
CoffeeScript
Atraci/Atraci
coffee/_search.coffee
MIT
978a3c17e1eaf3d94e0fabc8625c36ba28a482b2
800
https://github.com/Atraci/Atraci/blob/978a3c17e1eaf3d94e0fabc8625c36ba28a482b2/coffee/_search.coffee
1
22
Atraci/Atraci:coffee/_search.coffee:1:completion
completion
$ -> $('#Search input').keypress (e) -> if e.which is 13 and $(@).val() != '' userTracking.event("Search", "organic", $(@).val()).send() $('#SideBar li.active').removeClass('active') $('#ContentWrapper').empty() spinner = new Spinner(spinner_opts).spin($('#Con...
)) $('#ContentWrapper').on 'click', '.track-container', -> if videojs('video_player').paused() != true && videojs('video_player').currentTime() == 0 && !$(@).find('.artist').text() || $(@).find('.artist').text() != __currentTrack.artist && !$(@).find('.title').text() || $(@).find('.title').text() != __curren...
CoffeeScript
CoffeeScript
Atraci/Atraci
coffee/_search.coffee
MIT
978a3c17e1eaf3d94e0fabc8625c36ba28a482b2
800
https://github.com/Atraci/Atraci/blob/978a3c17e1eaf3d94e0fabc8625c36ba28a482b2/coffee/_search.coffee
1
22
Atraci/Atraci:coffee/_search.coffee:1:raw_corpus
raw_corpus
$ -> $('#Search input').keypress (e) -> if e.which is 13 and $(@).val() != '' userTracking.event("Search", "organic", $(@).val()).send() $('#SideBar li.active').removeClass('active') $('#ContentWrapper').empty() spinner = new Spinner(spinner_opts).spin($('#Con...
CoffeeScript
Atraci/Atraci
coffee/_search.coffee
MIT
c536d51be7011037e486eec12783499bc80d1a57
800
https://github.com/Atraci/Atraci/blob/c536d51be7011037e486eec12783499bc80d1a57/coffee/_search.coffee
1
23
Atraci/Atraci:coffee/_search.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript $ -> $('#Search input').keypress (e) -> if e.which is 13 and $(@).val() != '' userTracking.event("Search", "organic", $(@).val()).send() $('#SideBar li.active').removeClass('active') $('#ContentWrapper').empty() ...
$(function() { $('#Search input').keypress(function(e) { var spinner; if (e.which === 13 && $(this).val() !== '') { userTracking.event("Search", "organic", $(this).val()).send(); $('#SideBar li.active').removeClass('active'); $('#ContentWrapper').empty(); spinner = new Spinner(spinner_...
CoffeeScript
JavaScript
Atraci/Atraci
coffee/_search.coffee
MIT
c536d51be7011037e486eec12783499bc80d1a57
800
https://github.com/Atraci/Atraci/blob/c536d51be7011037e486eec12783499bc80d1a57/coffee/_search.coffee
1
23
Atraci/Atraci:coffee/_search.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript $(function() { $('#Search input').keypress(function(e) { var spinner; if (e.which === 13 && $(this).val() !== '') { userTracking.event("Search", "organic", $(this).val()).send(); $('#SideBar li.active').removeClass('active'); $('#Content...
$ -> $('#Search input').keypress (e) -> if e.which is 13 and $(@).val() != '' userTracking.event("Search", "organic", $(@).val()).send() $('#SideBar li.active').removeClass('active') $('#ContentWrapper').empty() spinner = new Spinner(spinner_opts).spin($('#Con...
JavaScript
CoffeeScript
Atraci/Atraci
coffee/_search.coffee
MIT
c536d51be7011037e486eec12783499bc80d1a57
800
https://github.com/Atraci/Atraci/blob/c536d51be7011037e486eec12783499bc80d1a57/coffee/_search.coffee
1
23
Atraci/Atraci:coffee/_search.coffee:1:completion
completion
$ -> $('#Search input').keypress (e) -> if e.which is 13 and $(@).val() != '' userTracking.event("Search", "organic", $(@).val()).send() $('#SideBar li.active').removeClass('active') $('#ContentWrapper').empty() spinner = new Spinner(spinner_opts).spin($('#Con...
)) $('#ContentWrapper').on 'click', '.track-container', -> if videojs('video_player').paused() != true && videojs('video_player').currentTime() == 0 && !$(@).find('.artist').text() || $(@).find('.artist').text() != __currentTrack.artist && !$(@).find('.title').text() || $(@).find('.title').text() != __curren...
CoffeeScript
CoffeeScript
Atraci/Atraci
coffee/_search.coffee
MIT
c536d51be7011037e486eec12783499bc80d1a57
800
https://github.com/Atraci/Atraci/blob/c536d51be7011037e486eec12783499bc80d1a57/coffee/_search.coffee
1
23
Atraci/Atraci:coffee/_search.coffee:1:raw_corpus
raw_corpus
$ -> $('#Search input').keypress (e) -> if e.which is 13 and $(@).val() != '' userTracking.event("Search", "organic", $(@).val()).send() $('#SideBar li.active').removeClass('active') $('#ContentWrapper').empty() spinner = new Spinner(spinner_opts).spin($('#Con...
CoffeeScript
Atraci/Atraci
coffee/_search.coffee
MIT
b5ad2c415ec35975980aca57333c3f138246c8c6
800
https://github.com/Atraci/Atraci/blob/b5ad2c415ec35975980aca57333c3f138246c8c6/coffee/_search.coffee
1
17
Atraci/Atraci:coffee/_search.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript $ -> $('#Search input').keypress (e) -> if e.which is 13 and $(@).val() != '' userTracking.event("Search", "organic", $(@).val()).send() $('#SideBar li.active').removeClass('active') $('#ContentWrapper').empty() ...
$(function() { $('#Search input').keypress(function(e) { var spinner; if (e.which === 13 && $(this).val() !== '') { userTracking.event("Search", "organic", $(this).val()).send(); $('#SideBar li.active').removeClass('active'); $('#ContentWrapper').empty(); spinner = new Spinner(spinner_...
CoffeeScript
JavaScript
Atraci/Atraci
coffee/_search.coffee
MIT
b5ad2c415ec35975980aca57333c3f138246c8c6
800
https://github.com/Atraci/Atraci/blob/b5ad2c415ec35975980aca57333c3f138246c8c6/coffee/_search.coffee
1
17
Atraci/Atraci:coffee/_search.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript $(function() { $('#Search input').keypress(function(e) { var spinner; if (e.which === 13 && $(this).val() !== '') { userTracking.event("Search", "organic", $(this).val()).send(); $('#SideBar li.active').removeClass('active'); $('#Content...
$ -> $('#Search input').keypress (e) -> if e.which is 13 and $(@).val() != '' userTracking.event("Search", "organic", $(@).val()).send() $('#SideBar li.active').removeClass('active') $('#ContentWrapper').empty() spinner = new Spinner(spinner_opts).spin($('#Con...
JavaScript
CoffeeScript
Atraci/Atraci
coffee/_search.coffee
MIT
b5ad2c415ec35975980aca57333c3f138246c8c6
800
https://github.com/Atraci/Atraci/blob/b5ad2c415ec35975980aca57333c3f138246c8c6/coffee/_search.coffee
1
17
Atraci/Atraci:coffee/_search.coffee:1:completion
completion
$ -> $('#Search input').keypress (e) -> if e.which is 13 and $(@).val() != '' userTracking.event("Search", "organic", $(@).val()).send() $('#SideBar li.active').removeClass('active') $('#ContentWrapper').empty() spinner = new Spinner(spinner_opts).spin($('#Con...
TrackSource.search($(@).val(), ((tracks) -> spinner.stop() PopulateTrackList(tracks) )) $('#ContentWrapper').on 'click', '.track-container', -> PlayTrack($(@).find('.artist').text(), $(@).find('.title').text(), $(@).find('.cover').attr('data-cover_url_medium'), $...
CoffeeScript
CoffeeScript
Atraci/Atraci
coffee/_search.coffee
MIT
b5ad2c415ec35975980aca57333c3f138246c8c6
800
https://github.com/Atraci/Atraci/blob/b5ad2c415ec35975980aca57333c3f138246c8c6/coffee/_search.coffee
1
17
Atraci/Atraci:coffee/_search.coffee:1:raw_corpus
raw_corpus
$ -> $('#search-input').keypress (e) -> if e.which is 13 and $(@).val() != '' userTracking.event("Search", "organic", $(@).val()).send() $('#sidebar-container li.active').removeClass('active') $('#tracklist-container').empty() spinner = new Spinner(spinner_opt...
CoffeeScript
Atraci/Atraci
coffee/_search.coffee
MIT
2cf176c0e1149e4f654455b3abe35404d24a84e5
800
https://github.com/Atraci/Atraci/blob/2cf176c0e1149e4f654455b3abe35404d24a84e5/coffee/_search.coffee
1
23
Atraci/Atraci:coffee/_search.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript $ -> $('#search-input').keypress (e) -> if e.which is 13 and $(@).val() != '' userTracking.event("Search", "organic", $(@).val()).send() $('#sidebar-container li.active').removeClass('active') $('#tracklist-containe...
$(function() { $('#search-input').keypress(function(e) { var spinner; if (e.which === 13 && $(this).val() !== '') { userTracking.event("Search", "organic", $(this).val()).send(); $('#sidebar-container li.active').removeClass('active'); $('#tracklist-container').empty(); spinner = new S...
CoffeeScript
JavaScript
Atraci/Atraci
coffee/_search.coffee
MIT
2cf176c0e1149e4f654455b3abe35404d24a84e5
800
https://github.com/Atraci/Atraci/blob/2cf176c0e1149e4f654455b3abe35404d24a84e5/coffee/_search.coffee
1
23
Atraci/Atraci:coffee/_search.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript $(function() { $('#search-input').keypress(function(e) { var spinner; if (e.which === 13 && $(this).val() !== '') { userTracking.event("Search", "organic", $(this).val()).send(); $('#sidebar-container li.active').removeClass('active'); $...
$ -> $('#search-input').keypress (e) -> if e.which is 13 and $(@).val() != '' userTracking.event("Search", "organic", $(@).val()).send() $('#sidebar-container li.active').removeClass('active') $('#tracklist-container').empty() spinner = new Spinner(spinner_opt...
JavaScript
CoffeeScript
Atraci/Atraci
coffee/_search.coffee
MIT
2cf176c0e1149e4f654455b3abe35404d24a84e5
800
https://github.com/Atraci/Atraci/blob/2cf176c0e1149e4f654455b3abe35404d24a84e5/coffee/_search.coffee
1
23
Atraci/Atraci:coffee/_search.coffee:1:completion
completion
$ -> $('#search-input').keypress (e) -> if e.which is 13 and $(@).val() != '' userTracking.event("Search", "organic", $(@).val()).send() $('#sidebar-container li.active').removeClass('active') $('#tracklist-container').empty() spinner = new Spinner(spinner_opt...
)) $('#tracklist-container').on 'click', '.track-container', -> if videojs('video_player').paused() != true && videojs('video_player').currentTime() == 0 && !$(@).find('.artist').text() || $(@).find('.artist').text() != __currentTrack.artist && !$(@).find('.title').text() || $(@).find('.title').text() != _...
CoffeeScript
CoffeeScript
Atraci/Atraci
coffee/_search.coffee
MIT
2cf176c0e1149e4f654455b3abe35404d24a84e5
800
https://github.com/Atraci/Atraci/blob/2cf176c0e1149e4f654455b3abe35404d24a84e5/coffee/_search.coffee
1
23
Atraci/Atraci:coffee/_search.coffee:1:raw_corpus
raw_corpus
$ -> $('#search-input').keypress (e) -> if e.which is 13 and $(@).val() != '' userTracking.event("Search", "organic", $(@).val()).send() $('#sidebar-container li.active').removeClass('active') $('#tracklist-container').empty() spinner = new Spinner(spinner_opt...
CoffeeScript
Atraci/Atraci
coffee/_search.coffee
MIT
d4b7f952575352efeff69f232ab345bac48fe586
800
https://github.com/Atraci/Atraci/blob/d4b7f952575352efeff69f232ab345bac48fe586/coffee/_search.coffee
1
17
Atraci/Atraci:coffee/_search.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript $ -> $('#search-input').keypress (e) -> if e.which is 13 and $(@).val() != '' userTracking.event("Search", "organic", $(@).val()).send() $('#sidebar-container li.active').removeClass('active') $('#tracklist-containe...
$(function() { $('#search-input').keypress(function(e) { var spinner; if (e.which === 13 && $(this).val() !== '') { userTracking.event("Search", "organic", $(this).val()).send(); $('#sidebar-container li.active').removeClass('active'); $('#tracklist-container').empty(); spinner = new S...
CoffeeScript
JavaScript
Atraci/Atraci
coffee/_search.coffee
MIT
d4b7f952575352efeff69f232ab345bac48fe586
800
https://github.com/Atraci/Atraci/blob/d4b7f952575352efeff69f232ab345bac48fe586/coffee/_search.coffee
1
17
Atraci/Atraci:coffee/_search.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript $(function() { $('#search-input').keypress(function(e) { var spinner; if (e.which === 13 && $(this).val() !== '') { userTracking.event("Search", "organic", $(this).val()).send(); $('#sidebar-container li.active').removeClass('active'); $...
$ -> $('#search-input').keypress (e) -> if e.which is 13 and $(@).val() != '' userTracking.event("Search", "organic", $(@).val()).send() $('#sidebar-container li.active').removeClass('active') $('#tracklist-container').empty() spinner = new Spinner(spinner_opt...
JavaScript
CoffeeScript
Atraci/Atraci
coffee/_search.coffee
MIT
d4b7f952575352efeff69f232ab345bac48fe586
800
https://github.com/Atraci/Atraci/blob/d4b7f952575352efeff69f232ab345bac48fe586/coffee/_search.coffee
1
17
Atraci/Atraci:coffee/_search.coffee:1:completion
completion
$ -> $('#search-input').keypress (e) -> if e.which is 13 and $(@).val() != '' userTracking.event("Search", "organic", $(@).val()).send() $('#sidebar-container li.active').removeClass('active') $('#tracklist-container').empty() spinner = new Spinner(spinner_opt...
TrackSource.search($(@).val(), ((tracks) -> spinner.stop() PopulateTrackList(tracks) )) $('#tracklist-container').on 'click', '.track-container', -> PlayTrack($(@).find('.artist').text(), $(@).find('.title').text(), $(@).find('.cover').attr('data-cover_url_medium...
CoffeeScript
CoffeeScript
Atraci/Atraci
coffee/_search.coffee
MIT
d4b7f952575352efeff69f232ab345bac48fe586
800
https://github.com/Atraci/Atraci/blob/d4b7f952575352efeff69f232ab345bac48fe586/coffee/_search.coffee
1
17
jianliaoim/talk-os:talk-web/client/handlers/team.coffee:1:raw_corpus
raw_corpus
recorder = require 'actions-recorder' dataRely = require '../network/data-rely' lang = require '../locales/lang' dispatcher = require '../dispatcher' notifyActions = require '../actions/notify' routerHanlders = require './router' # http://talk.ci/doc/event/team.leave.html exports.leave = (removeEvent) -> _teamId =...
CoffeeScript
jianliaoim/talk-os
talk-web/client/handlers/team.coffee
MIT
2545c4497865779a55762e03963a39237df9046b
2,703
https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/handlers/team.coffee
1
36
jianliaoim/talk-os:talk-web/client/handlers/team.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript recorder = require 'actions-recorder' dataRely = require '../network/data-rely' lang = require '../locales/lang' dispatcher = require '../dispatcher' notifyActions = require '../actions/notify' routerHanlders = require './router' # http://talk.ci/doc/event/tea...
var dataRely, dispatcher, lang, notifyActions, recorder, routerHanlders; recorder = require('actions-recorder'); dataRely = require('../network/data-rely'); lang = require('../locales/lang'); dispatcher = require('../dispatcher'); notifyActions = require('../actions/notify'); routerHanlders = require('./router');...
CoffeeScript
JavaScript
jianliaoim/talk-os
talk-web/client/handlers/team.coffee
MIT
2545c4497865779a55762e03963a39237df9046b
2,703
https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/handlers/team.coffee
1
36
jianliaoim/talk-os:talk-web/client/handlers/team.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var dataRely, dispatcher, lang, notifyActions, recorder, routerHanlders; recorder = require('actions-recorder'); dataRely = require('../network/data-rely'); lang = require('../locales/lang'); dispatcher = require('../dispatcher'); notifyActions = require('../a...
recorder = require 'actions-recorder' dataRely = require '../network/data-rely' lang = require '../locales/lang' dispatcher = require '../dispatcher' notifyActions = require '../actions/notify' routerHanlders = require './router' # http://talk.ci/doc/event/team.leave.html exports.leave = (removeEvent) -> _teamId =...
JavaScript
CoffeeScript
jianliaoim/talk-os
talk-web/client/handlers/team.coffee
MIT
2545c4497865779a55762e03963a39237df9046b
2,703
https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/handlers/team.coffee
1
36
jianliaoim/talk-os:talk-web/client/handlers/team.coffee:1:completion
completion
recorder = require 'actions-recorder' dataRely = require '../network/data-rely' lang = require '../locales/lang' dispatcher = require '../dispatcher' notifyActions = require '../actions/notify' routerHanlders = require './router' # http://talk.ci/doc/event/team.leave.html exports.leave = (removeEvent) -> _teamId =...
if _contactId is _userId routerHanlders.settingTeams() warningText = lang.getText('removed-from-team-%s') .replace '%s', teamData.get('name') notifyActions.warn warningText dispatcher.handleServerAction type: 'team/leave' data: removeEvent exports.channels = (_teamId, cb) -> d = dataRely....
CoffeeScript
CoffeeScript
jianliaoim/talk-os
talk-web/client/handlers/team.coffee
MIT
2545c4497865779a55762e03963a39237df9046b
2,703
https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/handlers/team.coffee
1
36
jianliaoim/talk-os:talk-web/test/spec/actions/contact.spec.coffee:1:raw_corpus
raw_corpus
xdescribe 'Actions: contact', -> beforeEach -> @action = require 'actions/contact' @api = require 'network/api' describe 'Method: contactRemove', -> it 'should call api', -> spyOn(@api.teams.removemember, 'post').and.callThrough() teamId = 1 user = _id: 2 config = pa...
CoffeeScript
jianliaoim/talk-os
talk-web/test/spec/actions/contact.spec.coffee
MIT
2545c4497865779a55762e03963a39237df9046b
2,703
https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/test/spec/actions/contact.spec.coffee
1
37
jianliaoim/talk-os:talk-web/test/spec/actions/contact.spec.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript xdescribe 'Actions: contact', -> beforeEach -> @action = require 'actions/contact' @api = require 'network/api' describe 'Method: contactRemove', -> it 'should call api', -> spyOn(@api.teams.removemember, 'post').and.callThrough() t...
xdescribe('Actions: contact', function() { beforeEach(function() { this.action = require('actions/contact'); return this.api = require('network/api'); }); describe('Method: contactRemove', function() { return it('should call api', function() { var config, teamId, user; spyOn(this.api.teams...
CoffeeScript
JavaScript
jianliaoim/talk-os
talk-web/test/spec/actions/contact.spec.coffee
MIT
2545c4497865779a55762e03963a39237df9046b
2,703
https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/test/spec/actions/contact.spec.coffee
1
37
jianliaoim/talk-os:talk-web/test/spec/actions/contact.spec.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript xdescribe('Actions: contact', function() { beforeEach(function() { this.action = require('actions/contact'); return this.api = require('network/api'); }); describe('Method: contactRemove', function() { return it('should call api', function() { ...
xdescribe 'Actions: contact', -> beforeEach -> @action = require 'actions/contact' @api = require 'network/api' describe 'Method: contactRemove', -> it 'should call api', -> spyOn(@api.teams.removemember, 'post').and.callThrough() teamId = 1 user = _id: 2 config = pa...
JavaScript
CoffeeScript
jianliaoim/talk-os
talk-web/test/spec/actions/contact.spec.coffee
MIT
2545c4497865779a55762e03963a39237df9046b
2,703
https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/test/spec/actions/contact.spec.coffee
1
37
jianliaoim/talk-os:talk-web/test/spec/actions/contact.spec.coffee:1:completion
completion
xdescribe 'Actions: contact', -> beforeEach -> @action = require 'actions/contact' @api = require 'network/api' describe 'Method: contactRemove', -> it 'should call api', -> spyOn(@api.teams.removemember, 'post').and.callThrough() teamId = 1 user = _id: 2 config = pa...
@action.contactRemove(teamId, user) expect(@api.teams.removemember.post).toHaveBeenCalledWith config describe 'Method: contactUpdateRole', -> it 'should call api', -> spyOn(@api.teams.setmemberrole, 'post').and.callThrough() teamId = 1 userId = 2 role = 'admin' config = ...
CoffeeScript
CoffeeScript
jianliaoim/talk-os
talk-web/test/spec/actions/contact.spec.coffee
MIT
2545c4497865779a55762e03963a39237df9046b
2,703
https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/test/spec/actions/contact.spec.coffee
1
37
alekseykulikov/backbone-offline:src/backbone.offline.coffee:1:raw_corpus
raw_corpus
class window.localStorageRecords constructor: (@name) -> store = localStorage.getItem(@name) @values = (store && store.split(',')) || [] add: (itemId) -> unless _.include(@values, itemId.toString()) @values.push itemId.toString() this.save() remove: (itemId) -> @values = _.without @val...
CoffeeScript
alekseykulikov/backbone-offline
src/backbone.offline.coffee
MIT
8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a
717
https://github.com/alekseykulikov/backbone-offline/blob/8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a/src/backbone.offline.coffee
6
21
alekseykulikov/backbone-offline:src/backbone.offline.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript class window.localStorageRecords constructor: (@name) -> store = localStorage.getItem(@name) @values = (store && store.split(',')) || [] add: (itemId) -> unless _.include(@values, itemId.toString()) @values.push itemId.toString() this.s...
window.localStorageRecords = class localStorageRecords { constructor(name) { var store; this.name = name; store = localStorage.getItem(this.name); this.values = (store && store.split(',')) || []; } add(itemId) { if (!_.include(this.values, itemId.toString())) { this.values.push(itemId.t...
CoffeeScript
JavaScript
alekseykulikov/backbone-offline
src/backbone.offline.coffee
MIT
8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a
717
https://github.com/alekseykulikov/backbone-offline/blob/8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a/src/backbone.offline.coffee
6
21
alekseykulikov/backbone-offline:src/backbone.offline.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript window.localStorageRecords = class localStorageRecords { constructor(name) { var store; this.name = name; store = localStorage.getItem(this.name); this.values = (store && store.split(',')) || []; } add(itemId) { if (!_.include(this.values...
class window.localStorageRecords constructor: (@name) -> store = localStorage.getItem(@name) @values = (store && store.split(',')) || [] add: (itemId) -> unless _.include(@values, itemId.toString()) @values.push itemId.toString() this.save() remove: (itemId) -> @values = _.without @val...
JavaScript
CoffeeScript
alekseykulikov/backbone-offline
src/backbone.offline.coffee
MIT
8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a
717
https://github.com/alekseykulikov/backbone-offline/blob/8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a/src/backbone.offline.coffee
6
21
alekseykulikov/backbone-offline:src/backbone.offline.coffee:1:completion
completion
class window.localStorageRecords constructor: (@name) -> store = localStorage.getItem(@name) @values = (store && store.split(',')) || [] add: (itemId) -> unless _.include(@values, itemId.toString()) @values.push itemId.toString()
this.save() remove: (itemId) -> @values = _.without @values, itemId.toString() this.save() save: -> localStorage.setItem @name, @values.join(',') reset: -> @values = []
CoffeeScript
CoffeeScript
alekseykulikov/backbone-offline
src/backbone.offline.coffee
MIT
8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a
717
https://github.com/alekseykulikov/backbone-offline/blob/8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a/src/backbone.offline.coffee
6
21
alekseykulikov/backbone-offline:src/backbone.offline.coffee:2:raw_corpus
raw_corpus
class window.Storage constructor: (@name, @collection, options = {}) -> @autoSync = if _.isUndefined(options.autoSync) then true else options.autoSync @keys = options.keys || {} @idAttribute = Backbone.Model.prototype.idAttribute @allRecords = new localStorageRecords(@name) @destroyRecords = new ...
CoffeeScript
alekseykulikov/backbone-offline
src/backbone.offline.coffee
MIT
8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a
717
https://github.com/alekseykulikov/backbone-offline/blob/8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a/src/backbone.offline.coffee
24
73
alekseykulikov/backbone-offline:src/backbone.offline.coffee:2:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript class window.Storage constructor: (@name, @collection, options = {}) -> @autoSync = if _.isUndefined(options.autoSync) then true else options.autoSync @keys = options.keys || {} @idAttribute = Backbone.Model.prototype.idAttribute @allRecords = ...
window.Storage = class Storage { constructor(name, collection, options = {}) { this.name = name; this.collection = collection; this.autoSync = _.isUndefined(options.autoSync) ? true : options.autoSync; this.keys = options.keys || {}; this.idAttribute = Backbone.Model.prototype.idAttribute; thi...
CoffeeScript
JavaScript
alekseykulikov/backbone-offline
src/backbone.offline.coffee
MIT
8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a
717
https://github.com/alekseykulikov/backbone-offline/blob/8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a/src/backbone.offline.coffee
24
73
alekseykulikov/backbone-offline:src/backbone.offline.coffee:2:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript window.Storage = class Storage { constructor(name, collection, options = {}) { this.name = name; this.collection = collection; this.autoSync = _.isUndefined(options.autoSync) ? true : options.autoSync; this.keys = options.keys || {}; this.idAt...
class window.Storage constructor: (@name, @collection, options = {}) -> @autoSync = if _.isUndefined(options.autoSync) then true else options.autoSync @keys = options.keys || {} @idAttribute = Backbone.Model.prototype.idAttribute @allRecords = new localStorageRecords(@name) @destroyRecords = new ...
JavaScript
CoffeeScript
alekseykulikov/backbone-offline
src/backbone.offline.coffee
MIT
8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a
717
https://github.com/alekseykulikov/backbone-offline/blob/8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a/src/backbone.offline.coffee
24
73
alekseykulikov/backbone-offline:src/backbone.offline.coffee:2:completion
completion
class window.Storage constructor: (@name, @collection, options = {}) -> @autoSync = if _.isUndefined(options.autoSync) then true else options.autoSync @keys = options.keys || {} @idAttribute = Backbone.Model.prototype.idAttribute @allRecords = new localStorageRecords(@name) @destroyRecords = new ...
model.set updated_at: (new Date).toString(), dirty: true this.saveItem(model) destroy: (model, options = {}) -> unless options.local or (sid = model.get('sid')) is 'new' @destroyRecords.add(sid) this.removeItem(model) find: (model) -> JSON.parse localStorage.getItem("#{@name}-#{model.id}")...
CoffeeScript
CoffeeScript
alekseykulikov/backbone-offline
src/backbone.offline.coffee
MIT
8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a
717
https://github.com/alekseykulikov/backbone-offline/blob/8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a/src/backbone.offline.coffee
24
73
alekseykulikov/backbone-offline:src/backbone.offline.coffee:3:raw_corpus
raw_corpus
this.pull success: => this.push() pull: (options = {}) -> Backbone.ajaxSync 'read', @collection, success: (response, status, xhr) => this.removeBySid(sid) for sid in this.getRemovedIds(response) this.pullItem(item) for item in response options.success() if options.success push: -> this.p...
CoffeeScript
alekseykulikov/backbone-offline
src/backbone.offline.coffee
MIT
8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a
717
https://github.com/alekseykulikov/backbone-offline/blob/8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a/src/backbone.offline.coffee
74
123
alekseykulikov/backbone-offline:src/backbone.offline.coffee:3:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript this.pull success: => this.push() pull: (options = {}) -> Backbone.ajaxSync 'read', @collection, success: (response, status, xhr) => this.removeBySid(sid) for sid in this.getRemovedIds(response) this.pullItem(item) for item in response op...
this.pull({ success: () => { return this.push()({ pull: function(options = {}) { return Backbone.ajaxSync('read', this.collection, { success: (response, status, xhr) => { var i, item, j, len, len1, ref, sid; ref = this.getRemovedIds(response); for (i = 0...
CoffeeScript
JavaScript
alekseykulikov/backbone-offline
src/backbone.offline.coffee
MIT
8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a
717
https://github.com/alekseykulikov/backbone-offline/blob/8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a/src/backbone.offline.coffee
74
123
alekseykulikov/backbone-offline:src/backbone.offline.coffee:3:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript this.pull({ success: () => { return this.push()({ pull: function(options = {}) { return Backbone.ajaxSync('read', this.collection, { success: (response, status, xhr) => { var i, item, j, len, len1, ref, sid; ref...
this.pull success: => this.push() pull: (options = {}) -> Backbone.ajaxSync 'read', @collection, success: (response, status, xhr) => this.removeBySid(sid) for sid in this.getRemovedIds(response) this.pullItem(item) for item in response options.success() if options.success push: -> this.p...
JavaScript
CoffeeScript
alekseykulikov/backbone-offline
src/backbone.offline.coffee
MIT
8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a
717
https://github.com/alekseykulikov/backbone-offline/blob/8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a/src/backbone.offline.coffee
74
123
alekseykulikov/backbone-offline:src/backbone.offline.coffee:3:completion
completion
this.pull success: => this.push() pull: (options = {}) -> Backbone.ajaxSync 'read', @collection, success: (response, status, xhr) => this.removeBySid(sid) for sid in this.getRemovedIds(response) this.pullItem(item) for item in response options.success() if options.success push: -> this.p...
return item removeItem: (item) -> localStorage.removeItem "#{@name}-#{item.id}" @allRecords.remove(item.id) return item replaceKeyFields: (item, method) -> model = if item.attributes then item.attributes else item for field, collection of @keys replacedField = model[field] newValu...
CoffeeScript
CoffeeScript
alekseykulikov/backbone-offline
src/backbone.offline.coffee
MIT
8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a
717
https://github.com/alekseykulikov/backbone-offline/blob/8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a/src/backbone.offline.coffee
74
123
alekseykulikov/backbone-offline:src/backbone.offline.coffee:4:raw_corpus
raw_corpus
else if @autoSync this.incrementalSync() pushItem: (item) -> this.replaceKeyFields(item, 'server') localId = item.id [method, item.id] = if item.get('sid') is 'new' then ['create', null] else ['update', item.get('sid')] Backbone.ajaxSync method, item, success: (response, status, xhr) => ...
CoffeeScript
alekseykulikov/backbone-offline
src/backbone.offline.coffee
MIT
8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a
717
https://github.com/alekseykulikov/backbone-offline/blob/8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a/src/backbone.offline.coffee
124
173
alekseykulikov/backbone-offline:src/backbone.offline.coffee:4:completion
completion
else if @autoSync this.incrementalSync() pushItem: (item) -> this.replaceKeyFields(item, 'server') localId = item.id [method, item.id] = if item.get('sid') is 'new' then ['create', null] else ['update', item.get('sid')] Backbone.ajaxSync method, item, success: (response, status, xhr) => ...
keys = Object.keys(localStorage) collectionKeys = _.filter keys, (key) => (new RegExp @name).test(key) localStorage.removeItem(key) for key in collectionKeys @allRecords.reset() @destroyRecords.reset() findBySid: (sid, collection = @collection) -> collection.find (item) -> item.get('sid') is sid...
CoffeeScript
CoffeeScript
alekseykulikov/backbone-offline
src/backbone.offline.coffee
MIT
8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a
717
https://github.com/alekseykulikov/backbone-offline/blob/8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a/src/backbone.offline.coffee
124
173
alekseykulikov/backbone-offline:src/backbone.offline.coffee:5:raw_corpus
raw_corpus
if (new Date(local.get 'updated_at')) < (new Date(item.updated_at)) delete item[@idAttribute] local.save item, local: true createItem: (item) -> unless _.include(@destroyRecords.values, item[@idAttribute].toString()) item.sid = item[@idAttribute] delete item[@idAttribute] # isNew() hack ...
CoffeeScript
alekseykulikov/backbone-offline
src/backbone.offline.coffee
MIT
8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a
717
https://github.com/alekseykulikov/backbone-offline/blob/8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a/src/backbone.offline.coffee
174
185
alekseykulikov/backbone-offline:src/backbone.offline.coffee:5:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript if (new Date(local.get 'updated_at')) < (new Date(item.updated_at)) delete item[@idAttribute] local.save item, local: true createItem: (item) -> unless _.include(@destroyRecords.values, item[@idAttribute].toString()) item.sid = item[@idAt...
if ((new Date(local.get('updated_at'))) < (new Date(item.updated_at))) { delete item[this.idAttribute]; local.save(item, { local: true }); } ({ createItem: function(item) { if (!_.include(this.destroyRecords.values, item[this.idAttribute].toString())) { item.sid = item[this.idAttribute]; de...
CoffeeScript
JavaScript
alekseykulikov/backbone-offline
src/backbone.offline.coffee
MIT
8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a
717
https://github.com/alekseykulikov/backbone-offline/blob/8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a/src/backbone.offline.coffee
174
185
alekseykulikov/backbone-offline:src/backbone.offline.coffee:5:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript if ((new Date(local.get('updated_at'))) < (new Date(item.updated_at))) { delete item[this.idAttribute]; local.save(item, { local: true }); } ({ createItem: function(item) { if (!_.include(this.destroyRecords.values, item[this.idAttribute].toString(...
if (new Date(local.get 'updated_at')) < (new Date(item.updated_at)) delete item[@idAttribute] local.save item, local: true createItem: (item) -> unless _.include(@destroyRecords.values, item[@idAttribute].toString()) item.sid = item[@idAttribute] delete item[@idAttribute] # isNew() hack ...
JavaScript
CoffeeScript
alekseykulikov/backbone-offline
src/backbone.offline.coffee
MIT
8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a
717
https://github.com/alekseykulikov/backbone-offline/blob/8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a/src/backbone.offline.coffee
174
185
alekseykulikov/backbone-offline:src/backbone.offline.coffee:5:completion
completion
if (new Date(local.get 'updated_at')) < (new Date(item.updated_at)) delete item[@idAttribute] local.save item, local: true createItem: (item) -> unless _.include(@destroyRecords.values, item[@idAttribute].toString())
item.sid = item[@idAttribute] delete item[@idAttribute] # isNew() hack @collection.create(item, local: true) # Wrapper for Storage methods
CoffeeScript
CoffeeScript
alekseykulikov/backbone-offline
src/backbone.offline.coffee
MIT
8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a
717
https://github.com/alekseykulikov/backbone-offline/blob/8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a/src/backbone.offline.coffee
174
185
alekseykulikov/backbone-offline:src/backbone.offline.coffee:6:raw_corpus
raw_corpus
Backbone.localSync = (method, model, options, store) -> resp = switch(method) when 'read' if _.isUndefined(model.id) then store.findAll() else store.find(model) when 'create' then store.create(model, options) when 'update' then store.update(model, options) when 'delete' then store.destroy(model,...
CoffeeScript
alekseykulikov/backbone-offline
src/backbone.offline.coffee
MIT
8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a
717
https://github.com/alekseykulikov/backbone-offline/blob/8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a/src/backbone.offline.coffee
186
197
alekseykulikov/backbone-offline:src/backbone.offline.coffee:6:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript Backbone.localSync = (method, model, options, store) -> resp = switch(method) when 'read' if _.isUndefined(model.id) then store.findAll() else store.find(model) when 'create' then store.create(model, options) when 'update' then store.update(mo...
Backbone.localSync = function(method, model, options, store) { var resp; resp = (function() { switch (method) { case 'read': if (_.isUndefined(model.id)) { return store.findAll(); } else { return store.find(model); } break; case 'create': r...
CoffeeScript
JavaScript
alekseykulikov/backbone-offline
src/backbone.offline.coffee
MIT
8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a
717
https://github.com/alekseykulikov/backbone-offline/blob/8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a/src/backbone.offline.coffee
186
197
alekseykulikov/backbone-offline:src/backbone.offline.coffee:6:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript Backbone.localSync = function(method, model, options, store) { var resp; resp = (function() { switch (method) { case 'read': if (_.isUndefined(model.id)) { return store.findAll(); } else { return store.find(model); ...
Backbone.localSync = (method, model, options, store) -> resp = switch(method) when 'read' if _.isUndefined(model.id) then store.findAll() else store.find(model) when 'create' then store.create(model, options) when 'update' then store.update(model, options) when 'delete' then store.destroy(model,...
JavaScript
CoffeeScript
alekseykulikov/backbone-offline
src/backbone.offline.coffee
MIT
8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a
717
https://github.com/alekseykulikov/backbone-offline/blob/8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a/src/backbone.offline.coffee
186
197
alekseykulikov/backbone-offline:src/backbone.offline.coffee:6:completion
completion
Backbone.localSync = (method, model, options, store) -> resp = switch(method) when 'read' if _.isUndefined(model.id) then store.findAll() else store.find(model) when 'create' then store.create(model, options) when 'update' then store.update(model, options)
when 'delete' then store.destroy(model, options) if resp then options.success(resp) else options.error('Record not found') # Delegate request depending on the 'storage' setting
CoffeeScript
CoffeeScript
alekseykulikov/backbone-offline
src/backbone.offline.coffee
MIT
8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a
717
https://github.com/alekseykulikov/backbone-offline/blob/8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a/src/backbone.offline.coffee
186
197
alekseykulikov/backbone-offline:src/backbone.offline.coffee:7:raw_corpus
raw_corpus
Backbone.offline = (method, model, options) -> store = model.storage || model.collection?.storage if store Backbone.localSync(method, model, options, store) else Backbone.ajaxSync(method, model, options) # Override 'Backbone.sync' to default to 'Backbone.offline' # the original 'Backbone.sync' is still ...
CoffeeScript
alekseykulikov/backbone-offline
src/backbone.offline.coffee
MIT
8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a
717
https://github.com/alekseykulikov/backbone-offline/blob/8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a/src/backbone.offline.coffee
198
209
alekseykulikov/backbone-offline:src/backbone.offline.coffee:7:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript Backbone.offline = (method, model, options) -> store = model.storage || model.collection?.storage if store Backbone.localSync(method, model, options, store) else Backbone.ajaxSync(method, model, options) # Override 'Backbone.sync' to default to 'B...
Backbone.offline = function(method, model, options) { var ref, store; store = model.storage || ((ref = model.collection) != null ? ref.storage : void 0); if (store) { return Backbone.localSync(method, model, options, store); } else { return Backbone.ajaxSync(method, model, options); } }; // Override ...
CoffeeScript
JavaScript
alekseykulikov/backbone-offline
src/backbone.offline.coffee
MIT
8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a
717
https://github.com/alekseykulikov/backbone-offline/blob/8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a/src/backbone.offline.coffee
198
209
alekseykulikov/backbone-offline:src/backbone.offline.coffee:7:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript Backbone.offline = function(method, model, options) { var ref, store; store = model.storage || ((ref = model.collection) != null ? ref.storage : void 0); if (store) { return Backbone.localSync(method, model, options, store); } else { return Backbone...
Backbone.offline = (method, model, options) -> store = model.storage || model.collection?.storage if store Backbone.localSync(method, model, options, store) else Backbone.ajaxSync(method, model, options) # Override 'Backbone.sync' to default to 'Backbone.offline' # the original 'Backbone.sync' is still ...
JavaScript
CoffeeScript
alekseykulikov/backbone-offline
src/backbone.offline.coffee
MIT
8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a
717
https://github.com/alekseykulikov/backbone-offline/blob/8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a/src/backbone.offline.coffee
198
209
alekseykulikov/backbone-offline:src/backbone.offline.coffee:7:completion
completion
Backbone.offline = (method, model, options) -> store = model.storage || model.collection?.storage if store Backbone.localSync(method, model, options, store) else Backbone.ajaxSync(method, model, options)
# Override 'Backbone.sync' to default to 'Backbone.offline' # the original 'Backbone.sync' is still available in 'Backbone.ajaxSync' Backbone.ajaxSync = Backbone.sync Backbone.sync = Backbone.offline
CoffeeScript
CoffeeScript
alekseykulikov/backbone-offline
src/backbone.offline.coffee
MIT
8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a
717
https://github.com/alekseykulikov/backbone-offline/blob/8cbf709722fcbdccdcd6374eda2d8ab1eb689d9a/src/backbone.offline.coffee
198
209
jianliaoim/talk-os:talk-web/client/app/slim-modal.coffee:1:raw_corpus
raw_corpus
cx = require 'classnames' React = require 'react' keycode = require 'keycode' lang = require '../locales/lang' LightModalBeta = React.createFactory require '../module/light-modal' { a, div, span, noscript } = React.DOM T = React.PropTypes module.exports = React.createClass displayName: 'slim-modal' propTypes: ...
CoffeeScript
jianliaoim/talk-os
talk-web/client/app/slim-modal.coffee
MIT
2545c4497865779a55762e03963a39237df9046b
2,703
https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/app/slim-modal.coffee
1
50
jianliaoim/talk-os:talk-web/client/app/slim-modal.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript cx = require 'classnames' React = require 'react' keycode = require 'keycode' lang = require '../locales/lang' LightModalBeta = React.createFactory require '../module/light-modal' { a, div, span, noscript } = React.DOM T = React.PropTypes module.exports = Rea...
var LightModalBeta, React, T, a, cx, div, keycode, lang, noscript, span; cx = require('classnames'); React = require('react'); keycode = require('keycode'); lang = require('../locales/lang'); LightModalBeta = React.createFactory(require('../module/light-modal')); ({a, div, span, noscript} = React.DOM); T = React...
CoffeeScript
JavaScript
jianliaoim/talk-os
talk-web/client/app/slim-modal.coffee
MIT
2545c4497865779a55762e03963a39237df9046b
2,703
https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/app/slim-modal.coffee
1
50
jianliaoim/talk-os:talk-web/client/app/slim-modal.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript var LightModalBeta, React, T, a, cx, div, keycode, lang, noscript, span; cx = require('classnames'); React = require('react'); keycode = require('keycode'); lang = require('../locales/lang'); LightModalBeta = React.createFactory(require('../module/light-modal'...
cx = require 'classnames' React = require 'react' keycode = require 'keycode' lang = require '../locales/lang' LightModalBeta = React.createFactory require '../module/light-modal' { a, div, span, noscript } = React.DOM T = React.PropTypes module.exports = React.createClass displayName: 'slim-modal' propTypes: ...
JavaScript
CoffeeScript
jianliaoim/talk-os
talk-web/client/app/slim-modal.coffee
MIT
2545c4497865779a55762e03963a39237df9046b
2,703
https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/app/slim-modal.coffee
1
50
jianliaoim/talk-os:talk-web/client/app/slim-modal.coffee:1:completion
completion
cx = require 'classnames' React = require 'react' keycode = require 'keycode' lang = require '../locales/lang' LightModalBeta = React.createFactory require '../module/light-modal' { a, div, span, noscript } = React.DOM T = React.PropTypes module.exports = React.createClass displayName: 'slim-modal' propTypes: ...
renderHeader: -> div className: 'slim-modal-header flex-static', div className: 'navbar', if @props.onBack? div className: 'nav-left', div className: 'button is-link flex-horiz flex-vcenter back', onClick: @props.onBack, span className: 'ti ti-arrow-left' ...
CoffeeScript
CoffeeScript
jianliaoim/talk-os
talk-web/client/app/slim-modal.coffee
MIT
2545c4497865779a55762e03963a39237df9046b
2,703
https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/app/slim-modal.coffee
1
50
jianliaoim/talk-os:talk-web/client/app/slim-modal.coffee:2:raw_corpus
raw_corpus
div className: 'slim-modal flex-vert', @renderHeader() div className: cxBody, @props.children
CoffeeScript
jianliaoim/talk-os
talk-web/client/app/slim-modal.coffee
MIT
2545c4497865779a55762e03963a39237df9046b
2,703
https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/app/slim-modal.coffee
51
54
jianliaoim/talk-os:talk-web/client/app/slim-modal.coffee:2:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript div className: 'slim-modal flex-vert', @renderHeader() div className: cxBody, @props.children ```
div({ className: 'slim-modal flex-vert' }, this.renderHeader(), div({ className: cxBody }, this.props.children));
CoffeeScript
JavaScript
jianliaoim/talk-os
talk-web/client/app/slim-modal.coffee
MIT
2545c4497865779a55762e03963a39237df9046b
2,703
https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/app/slim-modal.coffee
51
54
jianliaoim/talk-os:talk-web/client/app/slim-modal.coffee:2:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript div({ className: 'slim-modal flex-vert' }, this.renderHeader(), div({ className: cxBody }, this.props.children)); ```
div className: 'slim-modal flex-vert', @renderHeader() div className: cxBody, @props.children
JavaScript
CoffeeScript
jianliaoim/talk-os
talk-web/client/app/slim-modal.coffee
MIT
2545c4497865779a55762e03963a39237df9046b
2,703
https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/app/slim-modal.coffee
51
54
jianliaoim/talk-os:talk-web/client/app/slim-modal.coffee:2:completion
completion
div className: 'slim-modal flex-vert', @renderHeader()
div className: cxBody, @props.children
CoffeeScript
CoffeeScript
jianliaoim/talk-os
talk-web/client/app/slim-modal.coffee
MIT
2545c4497865779a55762e03963a39237df9046b
2,703
https://github.com/jianliaoim/talk-os/blob/2545c4497865779a55762e03963a39237df9046b/talk-web/client/app/slim-modal.coffee
51
54
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:1:raw_corpus
raw_corpus
module.exports = comboRenderer: comboRenderer canvasRenderer: canvasRenderer switcher: switcher defaultEffect: defaultEffect defaultFlow: defaultFlow deleteFlow: deleteFlow userFileFlow: userFileFlow editorRegistry: editorRegistry screenShaker: screenShaker audioPlayer: audioPlayer screenShake: sc...
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
ac060c2476ba8b323ca932eda97da9bc0c051b34
3,570
https://github.com/JoelBesada/activate-power-mode/blob/ac060c2476ba8b323ca932eda97da9bc0c051b34/lib/plugin-manager.coffee
19
68
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript module.exports = comboRenderer: comboRenderer canvasRenderer: canvasRenderer switcher: switcher defaultEffect: defaultEffect defaultFlow: defaultFlow deleteFlow: deleteFlow userFileFlow: userFileFlow editorRegistry: editorRegistry screenShaker: ...
module.exports = { comboRenderer: comboRenderer, canvasRenderer: canvasRenderer, switcher: switcher, defaultEffect: defaultEffect, defaultFlow: defaultFlow, deleteFlow: deleteFlow, userFileFlow: userFileFlow, editorRegistry: editorRegistry, screenShaker: screenShaker, audioPlayer: audioPlayer, scr...
CoffeeScript
JavaScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
ac060c2476ba8b323ca932eda97da9bc0c051b34
3,570
https://github.com/JoelBesada/activate-power-mode/blob/ac060c2476ba8b323ca932eda97da9bc0c051b34/lib/plugin-manager.coffee
19
68
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript module.exports = { comboRenderer: comboRenderer, canvasRenderer: canvasRenderer, switcher: switcher, defaultEffect: defaultEffect, defaultFlow: defaultFlow, deleteFlow: deleteFlow, userFileFlow: userFileFlow, editorRegistry: editorRegistry, screen...
module.exports = comboRenderer: comboRenderer canvasRenderer: canvasRenderer switcher: switcher defaultEffect: defaultEffect defaultFlow: defaultFlow deleteFlow: deleteFlow userFileFlow: userFileFlow editorRegistry: editorRegistry screenShaker: screenShaker audioPlayer: audioPlayer screenShake: sc...
JavaScript
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
ac060c2476ba8b323ca932eda97da9bc0c051b34
3,570
https://github.com/JoelBesada/activate-power-mode/blob/ac060c2476ba8b323ca932eda97da9bc0c051b34/lib/plugin-manager.coffee
19
68
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:1:completion
completion
module.exports = comboRenderer: comboRenderer canvasRenderer: canvasRenderer switcher: switcher defaultEffect: defaultEffect defaultFlow: defaultFlow deleteFlow: deleteFlow userFileFlow: userFileFlow editorRegistry: editorRegistry screenShaker: screenShaker audioPlayer: audioPlayer screenShake: sc...
initApi: -> @comboRenderer.setPluginManager this @comboApi = new ComboApi(@comboRenderer) @canvasRenderer.setEffectRegistry @effectRegistry @screenShaker.init() @audioPlayer.init() @api = new Api(@editorRegistry, @comboApi, @screenShaker, @audioPlayer) initCorePlugins: -> @comboMode.setCo...
CoffeeScript
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
ac060c2476ba8b323ca932eda97da9bc0c051b34
3,570
https://github.com/JoelBesada/activate-power-mode/blob/ac060c2476ba8b323ca932eda97da9bc0c051b34/lib/plugin-manager.coffee
19
68
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:2:raw_corpus
raw_corpus
enable: -> @pluginRegistry.enable @api @flowRegistry.enable() @effectRegistry.enable() disable: -> @screenShaker.disable() @audioPlayer.disable() @flowRegistry.disable() @effectRegistry.disable() @pluginRegistry.onEnabled( (code, plugin) -> plugin.disable?() ) @pluginRe...
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
ac060c2476ba8b323ca932eda97da9bc0c051b34
3,570
https://github.com/JoelBesada/activate-power-mode/blob/ac060c2476ba8b323ca932eda97da9bc0c051b34/lib/plugin-manager.coffee
69
118
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:2:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript enable: -> @pluginRegistry.enable @api @flowRegistry.enable() @effectRegistry.enable() disable: -> @screenShaker.disable() @audioPlayer.disable() @flowRegistry.disable() @effectRegistry.disable() @pluginRegistry.onEnabled( ...
({ enable: function() { this.pluginRegistry.enable(this.api); this.flowRegistry.enable(); return this.effectRegistry.enable(); }, disable: function() { this.screenShaker.disable(); this.audioPlayer.disable(); this.flowRegistry.disable(); this.effectRegistry.disable(); this.pluginRe...
CoffeeScript
JavaScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
ac060c2476ba8b323ca932eda97da9bc0c051b34
3,570
https://github.com/JoelBesada/activate-power-mode/blob/ac060c2476ba8b323ca932eda97da9bc0c051b34/lib/plugin-manager.coffee
69
118
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:2:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript ({ enable: function() { this.pluginRegistry.enable(this.api); this.flowRegistry.enable(); return this.effectRegistry.enable(); }, disable: function() { this.screenShaker.disable(); this.audioPlayer.disable(); this.flowRegistry.disable(...
enable: -> @pluginRegistry.enable @api @flowRegistry.enable() @effectRegistry.enable() disable: -> @screenShaker.disable() @audioPlayer.disable() @flowRegistry.disable() @effectRegistry.disable() @pluginRegistry.onEnabled( (code, plugin) -> plugin.disable?() ) @pluginRe...
JavaScript
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
ac060c2476ba8b323ca932eda97da9bc0c051b34
3,570
https://github.com/JoelBesada/activate-power-mode/blob/ac060c2476ba8b323ca932eda97da9bc0c051b34/lib/plugin-manager.coffee
69
118
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:2:completion
completion
enable: -> @pluginRegistry.enable @api @flowRegistry.enable() @effectRegistry.enable() disable: -> @screenShaker.disable() @audioPlayer.disable() @flowRegistry.disable() @effectRegistry.disable() @pluginRegistry.onEnabled( (code, plugin) -> plugin.disable?() ) @pluginRe...
@pluginRegistry.onEnabled( (code, plugin) -> plugin.onNewCursor?(cursor) ) runOnInput: (cursor, screenPosition, input) -> @switcher.reset() @flowRegistry.flow.handle input, @switcher, @comboApi.getLevel() @pluginRegistry.onEnabled( (code, plugin) => return true if @switcher.isOff...
CoffeeScript
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
ac060c2476ba8b323ca932eda97da9bc0c051b34
3,570
https://github.com/JoelBesada/activate-power-mode/blob/ac060c2476ba8b323ca932eda97da9bc0c051b34/lib/plugin-manager.coffee
69
118
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:3:raw_corpus
raw_corpus
@pluginRegistry.onEnabled( (code, plugin) -> plugin.onComboEndStreak?() ) runOnComboExclamation: (text) -> @pluginRegistry.onEnabled( (code, plugin) -> plugin.onComboExclamation?(text) ) runOnComboMaxStreak: (maxStreak) -> @pluginRegistry.onEnabled( (code, plugin) -> plugin.onCom...
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
ac060c2476ba8b323ca932eda97da9bc0c051b34
3,570
https://github.com/JoelBesada/activate-power-mode/blob/ac060c2476ba8b323ca932eda97da9bc0c051b34/lib/plugin-manager.coffee
119
131
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:3:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript @pluginRegistry.onEnabled( (code, plugin) -> plugin.onComboEndStreak?() ) runOnComboExclamation: (text) -> @pluginRegistry.onEnabled( (code, plugin) -> plugin.onComboExclamation?(text) ) runOnComboMaxStreak: (maxStreak) -> @plugi...
this.pluginRegistry.onEnabled(function(code, plugin) { return typeof plugin.onComboEndStreak === "function" ? plugin.onComboEndStreak() : void 0; })({ runOnComboExclamation: function(text) { return this.pluginRegistry.onEnabled(function(code, plugin) { return typeof plugin.onComboExclamation === "function...
CoffeeScript
JavaScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
ac060c2476ba8b323ca932eda97da9bc0c051b34
3,570
https://github.com/JoelBesada/activate-power-mode/blob/ac060c2476ba8b323ca932eda97da9bc0c051b34/lib/plugin-manager.coffee
119
131
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:3:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript this.pluginRegistry.onEnabled(function(code, plugin) { return typeof plugin.onComboEndStreak === "function" ? plugin.onComboEndStreak() : void 0; })({ runOnComboExclamation: function(text) { return this.pluginRegistry.onEnabled(function(code, plugin) { ...
@pluginRegistry.onEnabled( (code, plugin) -> plugin.onComboEndStreak?() ) runOnComboExclamation: (text) -> @pluginRegistry.onEnabled( (code, plugin) -> plugin.onComboExclamation?(text) ) runOnComboMaxStreak: (maxStreak) -> @pluginRegistry.onEnabled( (code, plugin) -> plugin.onCom...
JavaScript
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
ac060c2476ba8b323ca932eda97da9bc0c051b34
3,570
https://github.com/JoelBesada/activate-power-mode/blob/ac060c2476ba8b323ca932eda97da9bc0c051b34/lib/plugin-manager.coffee
119
131
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:3:completion
completion
@pluginRegistry.onEnabled( (code, plugin) -> plugin.onComboEndStreak?() ) runOnComboExclamation: (text) -> @pluginRegistry.onEnabled(
(code, plugin) -> plugin.onComboExclamation?(text) ) runOnComboMaxStreak: (maxStreak) -> @pluginRegistry.onEnabled( (code, plugin) -> plugin.onComboMaxStreak?(maxStreak) )
CoffeeScript
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
ac060c2476ba8b323ca932eda97da9bc0c051b34
3,570
https://github.com/JoelBesada/activate-power-mode/blob/ac060c2476ba8b323ca932eda97da9bc0c051b34/lib/plugin-manager.coffee
119
131
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:1:raw_corpus
raw_corpus
module.exports = comboRenderer: comboRenderer canvasRenderer: canvasRenderer switcher: switcher defaultEffect: defaultEffect defaultFlow: defaultFlow userFileFlow: userFileFlow editorRegistry: editorRegistry screenShaker: screenShaker audioPlayer: audioPlayer screenShake: screenShake playAudio: pl...
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
a9e3581d5fd08c9ea4a05de7a8b813f0ec3d85cc
3,570
https://github.com/JoelBesada/activate-power-mode/blob/a9e3581d5fd08c9ea4a05de7a8b813f0ec3d85cc/lib/plugin-manager.coffee
18
67
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript module.exports = comboRenderer: comboRenderer canvasRenderer: canvasRenderer switcher: switcher defaultEffect: defaultEffect defaultFlow: defaultFlow userFileFlow: userFileFlow editorRegistry: editorRegistry screenShaker: screenShaker audioPlaye...
module.exports = { comboRenderer: comboRenderer, canvasRenderer: canvasRenderer, switcher: switcher, defaultEffect: defaultEffect, defaultFlow: defaultFlow, userFileFlow: userFileFlow, editorRegistry: editorRegistry, screenShaker: screenShaker, audioPlayer: audioPlayer, screenShake: screenShake, p...
CoffeeScript
JavaScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
a9e3581d5fd08c9ea4a05de7a8b813f0ec3d85cc
3,570
https://github.com/JoelBesada/activate-power-mode/blob/a9e3581d5fd08c9ea4a05de7a8b813f0ec3d85cc/lib/plugin-manager.coffee
18
67
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript module.exports = { comboRenderer: comboRenderer, canvasRenderer: canvasRenderer, switcher: switcher, defaultEffect: defaultEffect, defaultFlow: defaultFlow, userFileFlow: userFileFlow, editorRegistry: editorRegistry, screenShaker: screenShaker, au...
module.exports = comboRenderer: comboRenderer canvasRenderer: canvasRenderer switcher: switcher defaultEffect: defaultEffect defaultFlow: defaultFlow userFileFlow: userFileFlow editorRegistry: editorRegistry screenShaker: screenShaker audioPlayer: audioPlayer screenShake: screenShake playAudio: pl...
JavaScript
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
a9e3581d5fd08c9ea4a05de7a8b813f0ec3d85cc
3,570
https://github.com/JoelBesada/activate-power-mode/blob/a9e3581d5fd08c9ea4a05de7a8b813f0ec3d85cc/lib/plugin-manager.coffee
18
67
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:1:completion
completion
module.exports = comboRenderer: comboRenderer canvasRenderer: canvasRenderer switcher: switcher defaultEffect: defaultEffect defaultFlow: defaultFlow userFileFlow: userFileFlow editorRegistry: editorRegistry screenShaker: screenShaker audioPlayer: audioPlayer screenShake: screenShake playAudio: pl...
initApi: -> @comboRenderer.setPluginManager this @comboApi = new ComboApi(@comboRenderer) @canvasRenderer.setEffectRegistry @effectRegistry @screenShaker.init() @audioPlayer.init() @api = new Api(@editorRegistry, @comboApi, @screenShaker, @audioPlayer) initCorePlugins: -> @comboMode.setCo...
CoffeeScript
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
a9e3581d5fd08c9ea4a05de7a8b813f0ec3d85cc
3,570
https://github.com/JoelBesada/activate-power-mode/blob/a9e3581d5fd08c9ea4a05de7a8b813f0ec3d85cc/lib/plugin-manager.coffee
18
67
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:2:raw_corpus
raw_corpus
@pluginRegistry.enable @api @flowRegistry.enable() @effectRegistry.enable() disable: -> @screenShaker.disable() @audioPlayer.disable() @flowRegistry.disable() @effectRegistry.disable() @pluginRegistry.onEnabled( (code, plugin) -> plugin.disable?() ) @pluginRegistry.disable(...
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
a9e3581d5fd08c9ea4a05de7a8b813f0ec3d85cc
3,570
https://github.com/JoelBesada/activate-power-mode/blob/a9e3581d5fd08c9ea4a05de7a8b813f0ec3d85cc/lib/plugin-manager.coffee
68
117
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:2:completion
completion
@pluginRegistry.enable @api @flowRegistry.enable() @effectRegistry.enable() disable: -> @screenShaker.disable() @audioPlayer.disable() @flowRegistry.disable() @effectRegistry.disable() @pluginRegistry.onEnabled( (code, plugin) -> plugin.disable?() ) @pluginRegistry.disable(...
) runOnInput: (cursor, screenPosition, input) -> @switcher.reset() @flowRegistry.flow.handle input, @switcher, @comboApi.getLevel() @pluginRegistry.onEnabled( (code, plugin) => return true if @switcher.isOff code plugin.onInput?(cursor, screenPosition, input, @switcher.getData code...
CoffeeScript
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
a9e3581d5fd08c9ea4a05de7a8b813f0ec3d85cc
3,570
https://github.com/JoelBesada/activate-power-mode/blob/a9e3581d5fd08c9ea4a05de7a8b813f0ec3d85cc/lib/plugin-manager.coffee
68
117
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:3:raw_corpus
raw_corpus
) runOnComboExclamation: (text) -> @pluginRegistry.onEnabled( (code, plugin) -> plugin.onComboExclamation?(text) ) runOnComboMaxStreak: (maxStreak) -> @pluginRegistry.onEnabled( (code, plugin) -> plugin.onComboMaxStreak?(maxStreak) )
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
a9e3581d5fd08c9ea4a05de7a8b813f0ec3d85cc
3,570
https://github.com/JoelBesada/activate-power-mode/blob/a9e3581d5fd08c9ea4a05de7a8b813f0ec3d85cc/lib/plugin-manager.coffee
118
128
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:3:completion
completion
) runOnComboExclamation: (text) -> @pluginRegistry.onEnabled( (code, plugin) -> plugin.onComboExclamation?(text)
) runOnComboMaxStreak: (maxStreak) -> @pluginRegistry.onEnabled( (code, plugin) -> plugin.onComboMaxStreak?(maxStreak) )
CoffeeScript
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
a9e3581d5fd08c9ea4a05de7a8b813f0ec3d85cc
3,570
https://github.com/JoelBesada/activate-power-mode/blob/a9e3581d5fd08c9ea4a05de7a8b813f0ec3d85cc/lib/plugin-manager.coffee
118
128
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:2:raw_corpus
raw_corpus
@pluginRegistry.enable @api @flowRegistry.enable() @effectRegistry.enable() disable: -> @screenShaker.disable() @audioPlayer.disable() @flowRegistry.disable() @effectRegistry.disable() @pluginRegistry.onEnabled( (code, plugin) -> plugin.disable?() ) @pluginRegistry.disable(...
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
2d33f61abbb0dfc2634596b097b302edd0f2bd4b
3,570
https://github.com/JoelBesada/activate-power-mode/blob/2d33f61abbb0dfc2634596b097b302edd0f2bd4b/lib/plugin-manager.coffee
68
117
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:2:completion
completion
@pluginRegistry.enable @api @flowRegistry.enable() @effectRegistry.enable() disable: -> @screenShaker.disable() @audioPlayer.disable() @flowRegistry.disable() @effectRegistry.disable() @pluginRegistry.onEnabled( (code, plugin) -> plugin.disable?() ) @pluginRegistry.disable(...
(code, plugin) -> plugin.onNewCursor?(cursor) ) runOnInput: (cursor, screenPosition, input) -> @switcher.reset() @flowRegistry.flow.handle input, @switcher, @comboApi.getLevel() @pluginRegistry.onEnabled( (code, plugin) => return true if @switcher.isOff code plugin.onInput?(cur...
CoffeeScript
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
2d33f61abbb0dfc2634596b097b302edd0f2bd4b
3,570
https://github.com/JoelBesada/activate-power-mode/blob/2d33f61abbb0dfc2634596b097b302edd0f2bd4b/lib/plugin-manager.coffee
68
117
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:3:raw_corpus
raw_corpus
(code, plugin) -> plugin.onComboEndStreak?() ) runOnComboExclamation: (text) -> @pluginRegistry.onEnabled( (code, plugin) -> plugin.onComboExclamation?(text) ) runOnComboMaxStreak: (maxStreak) -> @pluginRegistry.onEnabled( (code, plugin) -> plugin.onComboMaxStreak?(maxStreak) )
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
2d33f61abbb0dfc2634596b097b302edd0f2bd4b
3,570
https://github.com/JoelBesada/activate-power-mode/blob/2d33f61abbb0dfc2634596b097b302edd0f2bd4b/lib/plugin-manager.coffee
118
129
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:3:completion
completion
(code, plugin) -> plugin.onComboEndStreak?() ) runOnComboExclamation: (text) -> @pluginRegistry.onEnabled( (code, plugin) -> plugin.onComboExclamation?(text)
) runOnComboMaxStreak: (maxStreak) -> @pluginRegistry.onEnabled( (code, plugin) -> plugin.onComboMaxStreak?(maxStreak) )
CoffeeScript
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
2d33f61abbb0dfc2634596b097b302edd0f2bd4b
3,570
https://github.com/JoelBesada/activate-power-mode/blob/2d33f61abbb0dfc2634596b097b302edd0f2bd4b/lib/plugin-manager.coffee
118
129
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:1:raw_corpus
raw_corpus
module.exports = comboRenderer: comboRenderer canvasRenderer: canvasRenderer switcher: switcher defaultEffect: defaultEffect defaultFlow: defaultFlow userFileFlow: userFileFlow editorRegistry: editorRegistry screenShaker: screenShaker audioPlayer: audioPlayer screenShake: screenShake playAudio: pl...
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
70cdc43d6acba3bde34121da4c0984bf0bf272fa
3,570
https://github.com/JoelBesada/activate-power-mode/blob/70cdc43d6acba3bde34121da4c0984bf0bf272fa/lib/plugin-manager.coffee
17
66
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript module.exports = comboRenderer: comboRenderer canvasRenderer: canvasRenderer switcher: switcher defaultEffect: defaultEffect defaultFlow: defaultFlow userFileFlow: userFileFlow editorRegistry: editorRegistry screenShaker: screenShaker audioPlaye...
module.exports = { comboRenderer: comboRenderer, canvasRenderer: canvasRenderer, switcher: switcher, defaultEffect: defaultEffect, defaultFlow: defaultFlow, userFileFlow: userFileFlow, editorRegistry: editorRegistry, screenShaker: screenShaker, audioPlayer: audioPlayer, screenShake: screenShake, p...
CoffeeScript
JavaScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
70cdc43d6acba3bde34121da4c0984bf0bf272fa
3,570
https://github.com/JoelBesada/activate-power-mode/blob/70cdc43d6acba3bde34121da4c0984bf0bf272fa/lib/plugin-manager.coffee
17
66
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript module.exports = { comboRenderer: comboRenderer, canvasRenderer: canvasRenderer, switcher: switcher, defaultEffect: defaultEffect, defaultFlow: defaultFlow, userFileFlow: userFileFlow, editorRegistry: editorRegistry, screenShaker: screenShaker, au...
module.exports = comboRenderer: comboRenderer canvasRenderer: canvasRenderer switcher: switcher defaultEffect: defaultEffect defaultFlow: defaultFlow userFileFlow: userFileFlow editorRegistry: editorRegistry screenShaker: screenShaker audioPlayer: audioPlayer screenShake: screenShake playAudio: pl...
JavaScript
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
70cdc43d6acba3bde34121da4c0984bf0bf272fa
3,570
https://github.com/JoelBesada/activate-power-mode/blob/70cdc43d6acba3bde34121da4c0984bf0bf272fa/lib/plugin-manager.coffee
17
66
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:1:completion
completion
module.exports = comboRenderer: comboRenderer canvasRenderer: canvasRenderer switcher: switcher defaultEffect: defaultEffect defaultFlow: defaultFlow userFileFlow: userFileFlow editorRegistry: editorRegistry screenShaker: screenShaker audioPlayer: audioPlayer screenShake: screenShake playAudio: pl...
initApi: -> @comboRenderer.setPluginManager this @comboApi = new ComboApi(@comboRenderer) @canvasRenderer.setEffectRegistry @effectRegistry @screenShaker.init() @audioPlayer.init() @api = new Api(@editorRegistry, @comboApi, @screenShaker, @audioPlayer) initCorePlugins: -> @comboMode.setCo...
CoffeeScript
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
70cdc43d6acba3bde34121da4c0984bf0bf272fa
3,570
https://github.com/JoelBesada/activate-power-mode/blob/70cdc43d6acba3bde34121da4c0984bf0bf272fa/lib/plugin-manager.coffee
17
66
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:2:raw_corpus
raw_corpus
@flowRegistry.enable() @effectRegistry.enable() disable: -> @screenShaker.disable() @audioPlayer.disable() @flowRegistry.disable() @effectRegistry.disable() @pluginRegistry.onEnabled( (code, plugin) -> plugin.disable?() ) @pluginRegistry.disable() runOnChangePane: (editor = ...
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
70cdc43d6acba3bde34121da4c0984bf0bf272fa
3,570
https://github.com/JoelBesada/activate-power-mode/blob/70cdc43d6acba3bde34121da4c0984bf0bf272fa/lib/plugin-manager.coffee
67
116
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:2:completion
completion
@flowRegistry.enable() @effectRegistry.enable() disable: -> @screenShaker.disable() @audioPlayer.disable() @flowRegistry.disable() @effectRegistry.disable() @pluginRegistry.onEnabled( (code, plugin) -> plugin.disable?() ) @pluginRegistry.disable() runOnChangePane: (editor = ...
) runOnInput: (cursor, screenPosition, input) -> @switcher.reset() @flowRegistry.flow.handle input, @switcher, @comboApi.getLevel() @pluginRegistry.onEnabled( (code, plugin) => return true if @switcher.isOff code plugin.onInput?(cursor, screenPosition, input, @switcher.getData code...
CoffeeScript
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
70cdc43d6acba3bde34121da4c0984bf0bf272fa
3,570
https://github.com/JoelBesada/activate-power-mode/blob/70cdc43d6acba3bde34121da4c0984bf0bf272fa/lib/plugin-manager.coffee
67
116
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:1:raw_corpus
raw_corpus
module.exports = comboRenderer: comboRenderer canvasRenderer: canvasRenderer effect: effect switcher: switcher defaultFlow: defaultFlow userFileFlow: userFileFlow editorRegistry: editorRegistry screenShaker: screenShaker audioPlayer: audioPlayer screenShake: screenShake playAudio: playAudio comb...
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
005b3f4878a4391dcf2ef1c66634610054812c92
3,570
https://github.com/JoelBesada/activate-power-mode/blob/005b3f4878a4391dcf2ef1c66634610054812c92/lib/plugin-manager.coffee
17
66
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:1:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript module.exports = comboRenderer: comboRenderer canvasRenderer: canvasRenderer effect: effect switcher: switcher defaultFlow: defaultFlow userFileFlow: userFileFlow editorRegistry: editorRegistry screenShaker: screenShaker audioPlayer: audioPlayer...
module.exports = { comboRenderer: comboRenderer, canvasRenderer: canvasRenderer, effect: effect, switcher: switcher, defaultFlow: defaultFlow, userFileFlow: userFileFlow, editorRegistry: editorRegistry, screenShaker: screenShaker, audioPlayer: audioPlayer, screenShake: screenShake, playAudio: play...
CoffeeScript
JavaScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
005b3f4878a4391dcf2ef1c66634610054812c92
3,570
https://github.com/JoelBesada/activate-power-mode/blob/005b3f4878a4391dcf2ef1c66634610054812c92/lib/plugin-manager.coffee
17
66
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:1:js_to_coffee
js_to_coffee
Convert this JavaScript to CoffeeScript. ```javascript module.exports = { comboRenderer: comboRenderer, canvasRenderer: canvasRenderer, effect: effect, switcher: switcher, defaultFlow: defaultFlow, userFileFlow: userFileFlow, editorRegistry: editorRegistry, screenShaker: screenShaker, audioPlayer: aud...
module.exports = comboRenderer: comboRenderer canvasRenderer: canvasRenderer effect: effect switcher: switcher defaultFlow: defaultFlow userFileFlow: userFileFlow editorRegistry: editorRegistry screenShaker: screenShaker audioPlayer: audioPlayer screenShake: screenShake playAudio: playAudio comb...
JavaScript
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
005b3f4878a4391dcf2ef1c66634610054812c92
3,570
https://github.com/JoelBesada/activate-power-mode/blob/005b3f4878a4391dcf2ef1c66634610054812c92/lib/plugin-manager.coffee
17
66
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:1:completion
completion
module.exports = comboRenderer: comboRenderer canvasRenderer: canvasRenderer effect: effect switcher: switcher defaultFlow: defaultFlow userFileFlow: userFileFlow editorRegistry: editorRegistry screenShaker: screenShaker audioPlayer: audioPlayer screenShake: screenShake playAudio: playAudio comb...
@comboApi = new ComboApi(@comboRenderer) @canvasRenderer.setEffect @effect @screenShaker.init() @audioPlayer.init() @api = new Api(@editorRegistry, @comboApi, @screenShaker, @audioPlayer) initCorePlugins: -> @comboMode.setComboRenderer @comboRenderer @powerCanvas.setCanvasRenderer @canvasRend...
CoffeeScript
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
005b3f4878a4391dcf2ef1c66634610054812c92
3,570
https://github.com/JoelBesada/activate-power-mode/blob/005b3f4878a4391dcf2ef1c66634610054812c92/lib/plugin-manager.coffee
17
66
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:2:raw_corpus
raw_corpus
@flowRegistry.disable() @pluginRegistry.onEnabled( (code, plugin) -> plugin.disable?() ) @pluginRegistry.disable() runOnChangePane: (editor = null, editorElement = null) -> @editorRegistry.setEditor editor @editorRegistry.setEditorElement editorElement @pluginRegistry.onEnabled( ...
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
005b3f4878a4391dcf2ef1c66634610054812c92
3,570
https://github.com/JoelBesada/activate-power-mode/blob/005b3f4878a4391dcf2ef1c66634610054812c92/lib/plugin-manager.coffee
67
116
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:2:completion
completion
@flowRegistry.disable() @pluginRegistry.onEnabled( (code, plugin) -> plugin.disable?() ) @pluginRegistry.disable() runOnChangePane: (editor = null, editorElement = null) -> @editorRegistry.setEditor editor @editorRegistry.setEditorElement editorElement @pluginRegistry.onEnabled( ...
@pluginRegistry.onEnabled( (code, plugin) => return true if @switcher.isOff code plugin.onInput?(cursor, screenPosition, input, @switcher.getData code) ) runOnComboStartStreak: -> @pluginRegistry.onEnabled( (code, plugin) -> plugin.onComboStartStreak?() ) runOnComboLevelCha...
CoffeeScript
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
005b3f4878a4391dcf2ef1c66634610054812c92
3,570
https://github.com/JoelBesada/activate-power-mode/blob/005b3f4878a4391dcf2ef1c66634610054812c92/lib/plugin-manager.coffee
67
116
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:3:raw_corpus
raw_corpus
runOnComboMaxStreak: (maxStreak) -> @pluginRegistry.onEnabled( (code, plugin) -> plugin.onComboMaxStreak?(maxStreak) )
CoffeeScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
005b3f4878a4391dcf2ef1c66634610054812c92
3,570
https://github.com/JoelBesada/activate-power-mode/blob/005b3f4878a4391dcf2ef1c66634610054812c92/lib/plugin-manager.coffee
117
120
JoelBesada/activate-power-mode:lib/plugin-manager.coffee:3:coffee_to_js
coffee_to_js
Convert this CoffeeScript to JavaScript. ```coffeescript runOnComboMaxStreak: (maxStreak) -> @pluginRegistry.onEnabled( (code, plugin) -> plugin.onComboMaxStreak?(maxStreak) ) ```
({ runOnComboMaxStreak: function(maxStreak) { return this.pluginRegistry.onEnabled(function(code, plugin) { return typeof plugin.onComboMaxStreak === "function" ? plugin.onComboMaxStreak(maxStreak) : void 0; }); } });
CoffeeScript
JavaScript
JoelBesada/activate-power-mode
lib/plugin-manager.coffee
MIT
005b3f4878a4391dcf2ef1c66634610054812c92
3,570
https://github.com/JoelBesada/activate-power-mode/blob/005b3f4878a4391dcf2ef1c66634610054812c92/lib/plugin-manager.coffee
117
120