conversations
listlengths
2
3
source
stringclasses
1 value
stack
stringclasses
1 value
[ { "from": "system", "value": "Add support for anchors in the browser impl\n" }, { "from": "human", "value": "'use strict'\n\n[utils, Model] = ['utils', 'model'].map require\n\nexports.Request = require('./request.coffee')()\nexports.Response = require('./response.coffee')()\n\nexports.init = ->\...
coffeescript
chosen
[ { "from": "system", "value": "Set 'name' on editor view based on field key" }, { "from": "human", "value": "module.exports =\n\n build: (options) =>\n\n field = options.field\n\n fieldClass = require \"./#{field.get 'as'}\"\n\n new fieldClass\n controller: options.controller\n ...
coffeescript
chosen
[ { "from": "system", "value": "Use mainController's feature check to enable video\n" }, { "from": "human", "value": "checkFlag = require './checkFlag'\n\nmodule.exports = isVideoFeatureEnabled = ->\n\n return yes\n\n # for now we are only allowing super-admins to start video chat.\n # After we...
coffeescript
chosen
[ { "from": "system", "value": "Change API host to zooniverse.org\n" }, { "from": "human", "value": "DEFAULT_ENV = 'staging'\n\nAPI_HOSTS =\n production: 'https://panoptes.zooniverse.org'\n staging: 'https://panoptes-staging.zooniverse.org'\n\nAPI_APPLICATION_IDS =\n production: 'f79cf5ea821bb1...
coffeescript
chosen
[ { "from": "system", "value": "Make text carousel pick up where it left off\n" }, { "from": "human", "value": "class Dashing.Textcarousel extends Dashing.Widget\n\n ready: ->\n @currentIndex = 0\n @textElem = $(@node).find('p')\n @nextComment()\n @startCarousel()\n\n onData: (data) ...
coffeescript
chosen
[ { "from": "system", "value": "Add support for bigint and character varying\n" }, { "from": "human", "value": "class PgHoffTypes\n @Type:\n 1184:\n name: 'Timestamp'\n format: (value) ->\n return new Date(value).toLocaleString(atom.config.get('pg-hof...
coffeescript
chosen
[ { "from": "system", "value": "Change split to ignore tutorial\n" }, { "from": "human", "value": "translate = require 'lib/translate'\nClassification = require 'models/classification'\nUser = require 'zooniverse/lib/models/user'\n\nuserCount = -> User.count or 0\n\nnone = -> ''\nsocial = -> trans...
coffeescript
chosen
[ { "from": "system", "value": "Add specs for element-icons service\n" }, { "from": "human", "value": "DefaultFileIcons = require '../lib/default-file-icons'\ngetIconServices = require '../lib/get-icon-services'\n\ndescribe 'IconServices', ->\n describe 'FileIcons', ->\n afterEach ->\n ge...
coffeescript
chosen
[ { "from": "system", "value": "Handle list of data objects\n" }, { "from": "human", "value": "jQuery.fn.render = (data) ->\n data = [data] unless jQuery.isArray(data)\n context = this\n template = this.clone()\n\n # Iterate over data objects\n jQuery.each data, (index, object) ->\n t...
coffeescript
chosen
[ { "from": "system", "value": "Sort by received_at for merging unified collection results\n" }, { "from": "human", "value": "TentStatus.UnifiedCollection = class UnifiedCollection extends Marbles.UnifiedCollection\n\n fetchNext: (options = {}) =>\n collections = _.select @collections(), (c) =...
coffeescript
chosen
[ { "from": "system", "value": "Call constructor to initialize @cwd\n\nFixes similar error to https://github.com/AtomLinter/linter-pep8/issues/2\n" }, { "from": "human", "value": "linterPath = atom.packages.getLoadedPackage(\"linter\").path\nLinter = require \"#{linterPath}/lib/linter\"\n\nclass L...
coffeescript
chosen
[ { "from": "system", "value": "Update canvases when a bulb is pressed\n" }, { "from": "human", "value": "# Place all the behaviors and hooks related to the matching controller here.\n# All this logic will automatically be available in application.js.\n# You can use CoffeeScript in this file: http...
coffeescript
chosen
[ { "from": "system", "value": "Make finalizedquantity optional in the ofn-on-hand directive and extract avaiable quantity to a separate method for clarity\n" }, { "from": "human", "value": "Darkswarm.directive \"ofnOnHand\", ->\n restrict: 'A'\n require: \"ngModel\"\n\n link: (scope, elem, att...
coffeescript
chosen
[ { "from": "system", "value": "Remove fix for a weird browserify issue in Chrome Canary" }, { "from": "human", "value": "# WTF: Why aren't these being resolved?\nrequire 'zooniverse/views/zooniverse-logo-svg'\nrequire 'zooniverse/views/group-icon-svg'\nrequire 'zooniverse/views/language-icon-svg'...
coffeescript
chosen
[ { "from": "system", "value": "Update string scoring to be case insensitive\n" }, { "from": "human", "value": "String::score = (abbreviation) ->\n string = @\n\n return 1 if string == abbreviation\n\n index = string.indexOf(abbreviation)\n\n # only allow substrings to match\n return 0 if ind...
coffeescript
chosen
[ { "from": "system", "value": "Initialize tips in the channel route\n" }, { "from": "human", "value": "{ USER } = require(\"sharify\").data\nUser = require '../../../models/user.coffee'\nPathView = require '../../../components/path/client/path_view.coffee'\nsetupChannelsView = require '../compone...
coffeescript
chosen
[ { "from": "system", "value": "Load vex config inside a partial\n" }, { "from": "human", "value": "#= require active_admin/base\n#= require activeadmin-sortable\n#= require jquery-ui\n#= require chosen-jquery\n#= require admin/form_translation\n#= require admin/froala_editor\n#= require admin/set...
coffeescript
chosen
[ { "from": "system", "value": "Fix sort JS module crash\n" }, { "from": "human", "value": "Neighborly.Admin ?= {} if Neighborly.Admin is undefined\nNeighborly.Admin.Modules ?= {} if Neighborly.Admin.Modules is undefined\n\nNeighborly.Admin.Modules.Sort = Backbone.View.extend\n el: \".admin\"\n\n...
coffeescript
chosen
[ { "from": "system", "value": "Remove logging line from UsersNewController\n" }, { "from": "human", "value": "App.UsersNewController = Em.Controller.extend\n needs: [\"application\"]\n currentUser: Ember.computed.alias(\"controllers.application.currentUser\")\n\n validRoles: [\"member\", \"adm...
coffeescript
chosen
[ { "from": "system", "value": "Use CoffeeScript syntax for rowData check\n" }, { "from": "human", "value": "#query = require(\"pg-query\")\n\n\n\n\n#oreList = query(\"select itemName from Ore order by itemName\", (err, rows, result) ->\n#\talert rows )\n\n\n#alert oreList\n#alert \"3333\"\nrefini...
coffeescript
chosen
[ { "from": "system", "value": "Fix deprecation warning and fix indentation\n" }, { "from": "human", "value": "# For more detailed documentation see\n# https://atom.io/docs/latest/advanced/keymaps\n'.editor.python':\n 'ctrl-alt-s': 'python-isort:sortImports'\n" }, { "from": "gpt", "...
coffeescript
chosen
[ { "from": "system", "value": "Add oxygen-sans to the font list (for kde5)\n" }, { "from": "human", "value": "module.exports =\n\n config:\n fontFamily:\n description: 'Experimental: set to gtk-3 to load the font settings from ~/.config/gtk-3.0/settings.ini'\n type: 'string'\n ...
coffeescript
chosen
[ { "from": "system", "value": "Check for fair profile type before fair info app\n" }, { "from": "human", "value": "Fair = require '../../models/fair'\n\n@assignFair = (req, res, next) ->\n return next() unless res.locals.profile\n\n fair = new Fair id: res.locals.profile.get('owner').id\n fair...
coffeescript
chosen
[ { "from": "system", "value": "Fix Urban to use the Urban Dictionary API\n" }, { "from": "human", "value": "# Description:\n# Define terms via Urban Dictionary\n#\n# Dependencies:\n# None\n#\n# Configuration:\n# None\n#\n# Commands:\n# hubot urban me <term> - Searches Urban Dictio...
coffeescript
chosen
[ { "from": "system", "value": "Remove deprecation warning about Batman.View.prototype.prefix." }, { "from": "human", "value": "class Batman.ViewStore extends Batman.Object\n @prefix: 'views'\n\n constructor: ->\n super\n @_viewContents = {}\n @_requestedPaths = new Batman.SimpleSet\n\n...
coffeescript
chosen
[ { "from": "system", "value": "Create dummy admin user in test mode.\n" }, { "from": "human", "value": "util = require 'util'\nmodule.exports = (app, mongoose, options) ->\n \n models = require('./models')(mongoose)\n controllers = require('./controllers')(models)\n auth = require('./authenti...
coffeescript
chosen
[ { "from": "system", "value": "Add . after build command\n" }, { "from": "human", "value": "module.exports = (grunt) ->\n grunt.initConfig\n pkg: grunt.file.readJSON('package.json')\n\n coffee:\n glob_to_multiple:\n expand: true\n cwd: 'src'\n src: ['*.coffee']\n ...
coffeescript
chosen
[ { "from": "system", "value": "Create @wrapper in adapter constructor\n" }, { "from": "human", "value": "# Your Adapter SHOULD define:\n# * @QueryDefaults - The default parameters if no others are passed in.\n\nclass Embeditor.Adapter\n className: \"Adapter\"\n\n @QueryDefaults = {}\n\n ...
coffeescript
chosen
[ { "from": "system", "value": "Add support for sending cross-origin requests with credentials\n" }, { "from": "human", "value": "define [\n 'jquery'\n], ($) ->\n\n # Relies on the jquery-ajax-queue plugin to supply this method.\n # This ensures data is not silently lost\n $(window).on...
coffeescript
chosen
[ { "from": "system", "value": "Fix ajax pre-filter to define the xhrFields for CORS support\n\nThis is the official (per the jQuery docs) and correct way to ensure cookies\nare sent with cross-domain requests.\n" }, { "from": "human", "value": "define [\n 'jquery'\n], ($) ->\n\n # Relies on...
coffeescript
chosen
[ { "from": "system", "value": "Implement the vector based version of the compute method.\n" }, { "from": "human", "value": "_ = require \"underscore\"\nTransform = require \"./transform\"\n\nclass Jitter extends Transform.Model\n initialize: (attrs, options) ->\n super(attrs, options)\n\n de...
coffeescript
chosen
[ { "from": "system", "value": "Fix app router when there are no analytics.\n" }, { "from": "human", "value": "@AppRouter = Backbone.Router.extend\n routes:\n \"reload\": \"reload\"\n \"\": \"categories\"\n \"about\": \"about\"\n \"contribute\": \"contribute\"\n \"pods/:filter\": \...
coffeescript
chosen
[ { "from": "system", "value": "QUALITY: Remove switch tutorial from student tutorial list\n" }, { "from": "human", "value": "angular.module('doubtfire.projects.states.tutorials', [])\n\n#\n# Tasks state for projects\n#\n.config(($stateProvider) ->\n $stateProvider.state 'projects/tutorials', {\n...
coffeescript
chosen
[ { "from": "system", "value": "Fix a browser global bug.\n" }, { "from": "human", "value": "if $mate.environmentType == \"browser\"\n global.$mate = $mate\nelse if $mate.environmentType == \"node\"\n module.exports = $mate\nelse\n throw new Error()\n" }, { "from": "gpt", "val...
coffeescript
chosen
[ { "from": "system", "value": "Remove console log from o change method\n" }, { "from": "human", "value": "$ ->\n console.log 'iniciou'\n $('.reminder_active').on 'change', ->\n $('.reminder_days_before').prop \"disabled\", !@.checked\n" }, { "from": "gpt", "value": "$ ->\n $('.r...
coffeescript
chosen
[ { "from": "system", "value": "Hide forgot failure messages on submit\n" }, { "from": "human", "value": "class ForgotPasswordController\n constructor: (AuthenticatorService, $routeParams) ->\n @AuthenticatorService = AuthenticatorService\n @callbackUrl = $routeParams.callback ? 'https://ap...
coffeescript
chosen
[ { "from": "system", "value": ":art: Convert instance variable to scoped variable\n" }, { "from": "human", "value": "helpers = require '../spec-helpers'\nLatexmkBuilder = require '../../lib/builders/latexmk'\n\ndescribe \"LatexmkBuilder\", ->\n [builder] = []\n\n beforeEach ->\n builder = ne...
coffeescript
chosen
[ { "from": "system", "value": "Use the `ember-data` initializer as a target instead of the soon to be deprecated `store` initializer" }, { "from": "human", "value": "# Takes two parameters: container and app\n`import YoutubeAdapter from '../adapters/youtube'`\n`import YoutubeSerializer from '../s...
coffeescript
chosen
[ { "from": "system", "value": "Use method instead of instance var per @markijbema's comment\n" }, { "from": "human", "value": "class window.SubCommentsListView extends Backbone.Marionette.CompositeView\n className: 'evidence-sub-comments-list'\n\n itemView: SubCommentView\n itemViewContainer: ...
coffeescript
chosen
[ { "from": "system", "value": "Fix bug in Agent Spawner\n" }, { "from": "human", "value": "class AgentSpawner\n potential_agents: [] # Holds all potential customers from customers.json\n\n\nconstructor: ->\n $.ajax(\"/assets/data/agents.json\").done($.proxy((data_agents) ->\n for data_agen...
coffeescript
chosen
[ { "from": "system", "value": "Add callback to request invocation\n\nThis prevents request errors such as \"Uncaught Error: getaddrinfo ENOTFOUND\"\nfrom going to the console when errors are reported when you aren't online.\n" }, { "from": "human", "value": "request = require 'request'\n\nmodule....
coffeescript
chosen
[ { "from": "system", "value": "Add variation column to benchmark table\n" }, { "from": "human", "value": "###\nFunctions to build the benchmark table\n###\n\nbenchmark_id = (data, type, row) ->\n \"#{row.num}#{row.variations}.#{row.revisions.version}\"\n\n\nget_columns = ->\n ### Get the column...
coffeescript
chosen
[ { "from": "system", "value": "Support for running on heroku.\n" }, { "from": "human", "value": "Q = require 'q'\nrequest = require 'superagent'\nHeroku = require 'heroku-client'\n\nheroku = new Heroku token: process.env.HEROKU_API_KEY\n\nQ.ninvoke(heroku.apps(), 'list')\n .then (apps) ->\n u...
coffeescript
chosen
[ { "from": "system", "value": "Fix event bindings for variable-length keypaths.\n" }, { "from": "human", "value": "#= require ./abstract_attribute_binding\n\nclass Batman.DOM.EventBinding extends Batman.DOM.AbstractAttributeBinding\n onlyObserve: Batman.BindingDefinitionOnlyObserve.Data\n\n con...
coffeescript
chosen
[ { "from": "system", "value": "Add resetpassword route, fix alert box always being shown on reset password page\n" }, { "from": "human", "value": "express = require 'express'\nrouter = express.Router()\n\nrouter.get '/admin', (req, res) ->\n if req.user\n res.redirect '/admin/cc'\n else\n ...
coffeescript
chosen
[ { "from": "system", "value": "Make multiple loads of strut pick up latest ppt data properly.\n" }, { "from": "human", "value": "loadPpt = ->\n pptData = StrutBuilder.build(JSON.parse(localStorage.regions))\n #[\n #{ #slide 1\n #start: 0,\n #end: 2.5,\n #texts: [\n ...
coffeescript
chosen
[ { "from": "system", "value": "Set start panel with flight.launch()\n" }, { "from": "human", "value": "class AppRouter extends Backbone.Router\n\n routes:\n '': 'homePage'\n 'panel/:id': 'goToPanel'\n \n homePage: ->\n @view = new app.Views.Home \n @view.render()\n \n goToP...
coffeescript
chosen
[ { "from": "system", "value": "Replace invalid use of _.map() with a for-loop\n" }, { "from": "human", "value": "import * as _ from \"underscore\"\n\nimport * as p from \"../../core/properties\"\n\nimport {InputWidget, InputWidgetView} from \"./input_widget\"\n\nimport multiselecttemplate from \"...
coffeescript
chosen
[ { "from": "system", "value": "Fix replace all under plugin command\n" }, { "from": "human", "value": "'use strict'\n\nstripEof = require 'strip-eof'\nexec = require('child_process').exec\n\nkeywords =\n '$newVersion':\n regex: /\\$newVersion/g\n replace: '_version'\n\n '$oldVersion':\n ...
coffeescript
chosen
[ { "from": "system", "value": "Copy allowedHosts and destroy browser on every render.\n" }, { "from": "human", "value": "Browser = require 'zombie'\nfs = require 'fs'\npath = require 'path'\nURL = require 'url'\n\ncreateBrowser = (options = {}) ->\n browser = new Browser\n headers:\n \"X...
coffeescript
chosen
[ { "from": "system", "value": "Save all pane items before window is closed\n" }, { "from": "human", "value": "module.exports =\n configDefaults:\n enabled: false\n\n activate: (state) ->\n @migrateOldAutosaveConfig()\n\n rootView.on 'focusout', \".editor:not(.mini)\", (event) =>\n ...
coffeescript
chosen
[ { "from": "system", "value": "Disable the autopoll for now.\n" }, { "from": "human", "value": "# galegis-api -- Structured Importing and RESTful providing of GA General Assembly Activity.\n# Copyright (C) 2013 Matthew Farmer\n#\n# This program is free software: you can redistribute it a...
coffeescript
chosen
[ { "from": "system", "value": "Change the sidebar to use Flexbox for container\n" }, { "from": "human", "value": "_ = require 'underscore'\nReact = require 'react'\n{OutlineView, ScrollRegion} = require 'nylas-component-kit'\nAccountSwitcher = require './account-switcher'\nSidebarStore = require ...
coffeescript
chosen
[ { "from": "system", "value": "Change error formatter to red\n" }, { "from": "human", "value": "color = require('colors')\nmodule.exports = (failure) ->\n return format(failure)\n\nformat = (failure) ->\n message = shorten(failure, 5)\n colorFirstLine(message)\n\nshorten = (message, numlines) ...
coffeescript
chosen
[ { "from": "system", "value": "Store the last opened path.\n\nJust throwing stuff into localStorage seems \nsloppy. Maybe we just need some guidelines to\nfollow." }, { "from": "human", "value": "_ = require 'underscore'\n\nmodule.exports = App =\n windows: []\n root: OSX.NSBundle.mainBundle.re...
coffeescript
chosen
[ { "from": "system", "value": "Use fs.resolveOnLoadPath() to find ctags executable\n" }, { "from": "human", "value": "Point = require 'point'\n$ = require 'jquery'\nBufferedProcess = require 'buffered-process'\n\nmodule.exports =\nclass TagGenerator\n constructor: (@path) ->\n\n parseTagLine: (...
coffeescript
chosen
[ { "from": "system", "value": "Change default star size to 250px\n" }, { "from": "human", "value": "'use strict'\n\n### @ngInject ###\nmodule.exports = ($scope) ->\n $scope.star = {\n corners: 5,\n spokeRatio: 0.5,\n fill: '#f0c039',\n stroke: '#e4a91a',\n skew: 0,\n randomness...
coffeescript
chosen
[ { "from": "system", "value": ":bug: Handle undefined result from parser\n" }, { "from": "human", "value": "Logger = require '../logger'\n\nmodule.exports =\nclass ConsoleLogger extends Logger\n error: (statusCode, result, builder) ->\n console.group('LaTeX errors')\n switch statusCode\n ...
coffeescript
chosen
[ { "from": "system", "value": "Set first name in profile instance.\n" }, { "from": "human", "value": "module.exports = (account)->\n\n {firstName} = account\n\n \"\"\"\n <div id=\"activity-update-widget\" class=\"kdview activity-update-widget-wrapper\">\n <div class=\"kdview widget-holder c...
coffeescript
chosen
[ { "from": "system", "value": "Remove Correct Spelling from mini editor context menu\n" }, { "from": "human", "value": "'context-menu':\n 'atom-text-editor': [\n {label: 'Correct Spelling', command: 'spell-check:correct-misspelling'}\n ]\n" }, { "from": "gpt", "value": "'context-...
coffeescript
chosen
[ { "from": "system", "value": "Select input field's content on select event.\n" }, { "from": "human", "value": "define ['jquery', 'underscore', 'backbone', 'bootstrap', 'plugins/select_range'], ($, _, Backbone) ->\n class SearchInputView extends Backbone.View\n\n initialize: () ->\n @$el...
coffeescript
chosen
[ { "from": "system", "value": "Update HeaderCtrl to use `keywords` param instead of `search`\n" }, { "from": "human", "value": "Sprangular.controller \"HeaderCtrl\", (\n $scope,\n $location,\n Cart,\n Account,\n Catalog,\n Env,\n Flash,\n Status,\n Angularytics,\n $translate\n) ->\n\n ...
coffeescript
chosen
[ { "from": "system", "value": "Set Arnie to reply 100% of the time (for now). Update a few Arnie quotes.\n" }, { "from": "human", "value": "# Description:\n# Listens for words and sometimes replies with an Arnie quote\n#\n# Dependencies:\n# None\n#\n# Commands:\n# None\n#\n# Author:\n# Ca...
coffeescript
chosen
[ { "from": "system", "value": "Add JSX grammar to Atom\n" }, { "from": "human", "value": "packages: [\n \"advanced-open-file\"\n \"atom-alignment\"\n \"atom-beautify\"\n \"atom-transpose\"\n \"change-case\"\n \"color-picker\"\n \"docblockr\"\n \"editorconfig\"\n \"emmet\"\n \"expand-reg...
coffeescript
chosen
[ { "from": "system", "value": "Stop server and test cases on SIGINT\n" }, { "from": "human", "value": "w = require('when')\nexpress = require('express')\n\nConfig = require('./config')\nProject = require('./project')\nTestCase = require('./test_case')\n\nmodule.exports = () ->\n app = express()\...
coffeescript
chosen
[ { "from": "system", "value": "Reset the whole model when the status is changed\n" }, { "from": "human", "value": "@CodequestManager.module \"Entities\", (Entities, App, Backbone, Marionette, $, _) ->\n Entities.Order = Backbone.Model.extend\n\n urlRoot: ->\n \"/orders\"\n\n parse: (d...
coffeescript
chosen
[ { "from": "system", "value": "Fix for kublogPath, it must have a path separator.\n\nIssue on Aventones' PivotalTrack:\nhttps://www.pivotaltracker.com/story/show/21200167\n" }, { "from": "human", "value": "# Global helpers should be used in comments as well\nwindow.setErrors = (model, errors) ->\...
coffeescript
chosen
[ { "from": "system", "value": "Sort grammars by name in select list\n" }, { "from": "human", "value": "SelectList = require 'select-list'\n{$$} = require 'space-pen'\n\nmodule.exports =\nclass GrammarView extends SelectList\n\n @viewClass: -> \"#{super} grammar-view from-top overlay mini\"\n\n ...
coffeescript
chosen
[ { "from": "system", "value": "Remove Scayt and enable auto spelling from CKEditor\n\n[Finishes #61853878]\n" }, { "from": "human", "value": "window.Tahi ||= {}\n\nclass Tahi.RichEditableElement\n constructor: (@element) ->\n @instance = CKEDITOR.inline @element,\n extraPlugins: 'shareds...
coffeescript
chosen
[ { "from": "system", "value": "Set an eccessor on AssociationSets so we can do data-hideif: asssociation.loaded\n" }, { "from": "human", "value": "#= require ../../set/set_sort\n\nclass Batman.AssociationSet extends Batman.SetSort\n constructor: (@foreignKeyValue, @association) ->\n base = ne...
coffeescript
chosen
[ { "from": "system", "value": "Improve Names of Quality EDSL Parameters\n" }, { "from": "human", "value": "angular.module 'qbn.edsl', ['qbn.quality', 'qbn.storylet', 'qbn.choice']\n .factory 'qbnEdsl', (qualities, storylets, frontalChoices, choiceFactory) ->\n api =\n quality: (id, name,...
coffeescript
chosen
[ { "from": "system", "value": "Fix missing close paren in variantAutocomplete\n" }, { "from": "human", "value": "# variant autocompletion\n\nvariantTemplate = HandlebarsTemplates[\"variants/autocomplete\"]\n\nformatVariantResult = (variant) ->\n variantTemplate(\n variant: variant\n )\n\n$.f...
coffeescript
chosen
[ { "from": "system", "value": "Move tests next to their modules\n" }, { "from": "human", "value": "#\n# main.coffee\n#\n# Role: start the app\n#\n# Responsibility:\n# * load top-level modules\n# * initalize game based on query string\n# * render and append to body of HTML\n# * run tests if local\...
coffeescript
chosen
[ { "from": "system", "value": "EDSC-492: Fix URS redirect location in IE9\n" }, { "from": "human", "value": "do ($ = jQuery, config = @edsc.config) ->\n\n $(document).on 'click', 'a[data-pulse]', ->\n $dest = $($(this).attr('data-pulse'))\n $dest.animate(color: '#00ffff').animate(color: 'i...
coffeescript
chosen
[ { "from": "system", "value": "Add POST request support to client proxy\n" }, { "from": "human", "value": "Steam.Xhr = (_) ->\n createResponse = (status, data, xhr) ->\n status: status, data: data, xhr: xhr\n\n link$ _.invokeH2O, (method, path, go) ->\n $.getJSON path\n .done (data, ...
coffeescript
chosen
[ { "from": "system", "value": "Fix full name computed property\n* There was a redundant space getting added when the middle initial is absent" }, { "from": "human", "value": "a = DS.attr\nETahi.Author = DS.Model.extend\n authorGroup: DS.belongsTo('authorGroup')\n\n firstName: a('string')\n mid...
coffeescript
chosen
[ { "from": "system", "value": "Add one extra failure handling for item checkin mode.\n\nA successfull request has just been made before this call, but added\njust to be safe.\n" }, { "from": "human", "value": "class @ItemCheckInMode extends ItemCheckoutMode\n ModeSwitcher.registerEntryPoint(\"ve...
coffeescript
chosen
[ { "from": "system", "value": "Remove name attr from bookmakrk\n" }, { "from": "human", "value": "module.exports = App.Bookmark = DS.Model.extend\n name: DS.attr()\n url: DS.attr()\n" }, { "from": "gpt", "value": "module.exports = App.Bookmark = DS.Model.extend\n url: DS.attr()\n" ...
coffeescript
chosen
[ { "from": "system", "value": "Fix Manatee script: Heed location in redirect" }, { "from": "human", "value": "# Description:\n# Allows Hubot to pull down images from calmingmanatee.com\n#\n# Dependencies:\n# \"htmlparser\": \"1.7.6\"\n# \"soupselect\": \"0.2.0\"\n#\n# Configuration:\n# No...
coffeescript
chosen
[ { "from": "system", "value": "Add a FIXME for someone who wants a low hanging fruit\n" }, { "from": "human", "value": "{expect} = require \"chai\"\nutils = require \"../utils\"\n\n{Collections} = utils.require \"common/base\"\n\ndescribe \"categorical mapper\", ->\n factors = [\"foo\", \"bar\",...
coffeescript
chosen
[ { "from": "system", "value": "FIX: Make grade icon responsive to new input grades\n" }, { "from": "human", "value": "angular.module('doubtfire.common.grade-icon', [])\n\n.directive 'gradeIcon', ->\n restrict: 'E'\n replace: true\n templateUrl: 'common/partials/templates/grade-icon.tpl.html'\n...
coffeescript
chosen
[ { "from": "system", "value": "Add test for nested settings\n" }, { "from": "human", "value": "Settings = require '../lib/settings.coffee'\n\ndescribe \"Settings\", ->\n\n describe \".load(settings)\", ->\n it \"Loads the settings provided\", ->\n settings = new Settings()\n setting...
coffeescript
chosen
[ { "from": "system", "value": ":bug: Fix missing key attribute for column header cell\n" }, { "from": "human", "value": "React = require 'react-atom-fork'\n{div} = require 'reactionary-atom-fork'\n\nmodule.exports = React.createClass\n getInitialState: ->\n columnsWidths: []\n columnsAlign...
coffeescript
chosen
[ { "from": "system", "value": "Remove obsolete month shortening function" }, { "from": "human", "value": "jQuery = require 'jquery'\n_ = require 'underscore'\n\n\nexports.monthAbbr = (monthInt) ->\n switch monthInt\n when 0 then 'Jan'\n when 1 then 'Feb'\n when 2 then 'Mar...
coffeescript
chosen
[ { "from": "system", "value": "Set yourRanking to false. Use params to request model. Use new current user API.\n" }, { "from": "human", "value": "VoluntaryOnEmberjs.ProfileRankingsRoute = Ember.Route.extend\n model: (params) ->\n @controllerFor('profile.rankings').set('adjective', params.adj...
coffeescript
chosen
[ { "from": "system", "value": "Switch to mononoki font in Atom editor\n" }, { "from": "human", "value": "\"*\":\n core:\n themes: [\n \"one-light-ui\"\n \"solarized-dark-syntax\"\n ]\n editor:\n fontSize: 16\n invisibles: {}\n showIndentGuide: true\n showInvisibles: ...
coffeescript
chosen
[ { "from": "system", "value": "Correct namespace for commit request\n" }, { "from": "human", "value": "class CommitRequest extends Backbone.Model\n initialize: () ->\n # do stuff\n \n send: () =>\n $.ajax gon.commit_request_path, \n data: @request\n success: (data) => @success(...
coffeescript
chosen
[ { "from": "system", "value": "Include colon as a word boundary\n" }, { "from": "human", "value": "SpellChecker = require 'spellchecker'\n\nmodule.exports =\n findMisspellings: (text) ->\n wordRegex = /(?:^|[\\s\\[\\]])([a-zA-Z']+)(?=[\\s\\.\\[\\]]|$)/g\n row = 0\n misspellings = []\n ...
coffeescript
chosen
[ { "from": "system", "value": "Replace window.innerHeight by $(window).height to improve compatibility\n" }, { "from": "human", "value": "# USE\n# If the element is not a component, add full-height-header attribute to the tag.\n# With a component, add 'full_height_header: true' to the persisted o...
coffeescript
chosen
[ { "from": "system", "value": "Add keybindings for all platforms\n" }, { "from": "human", "value": "'.workspace':\n 'ctrl-M': 'markdown-preview:toggle'\n\n'.markdown-preview':\n 'cmd-+': 'markdown-preview:zoom-in'\n 'cmd-=': 'markdown-preview:zoom-in'\n 'cmd--': 'markdown-preview:zoom-out'\n ...
coffeescript
chosen
[ { "from": "system", "value": "Change back to using grammar name\n\nMatching against the scope name of the grammar didn't seem to work in\nall cases.\n" }, { "from": "human", "value": "# Your init script\n#\n# Atom will evaluate this file each time a new window is opened. It is run\n# after packa...
coffeescript
chosen
[ { "from": "system", "value": "Make <SocketStream> tag xml compliant\n" }, { "from": "human", "value": "# Plain HTML Formatter\n\nfs = require('fs')\n\nexports.init = ->\n\n extensions: ['html']\n assetType: 'html'\n contentType: 'text/html'\n\n compile: (path, options, cb) ->\n\n input = ...
coffeescript
chosen
[ { "from": "system", "value": "Switch to using interpretation property for color\n" }, { "from": "human", "value": "React = require 'react'\nBS = require 'react-bootstrap'\n\nChapterSectionType = require './chapter-section-type'\n\nmodule.exports = React.createClass\n displayName: 'LearningGuide...
coffeescript
chosen
[ { "from": "system", "value": "Destroy no longer exists, now it's close\n" }, { "from": "human", "value": "ScriptView = require './script-view'\n\nmodule.exports =\n scriptView: null\n\n activate: (state) ->\n @scriptView = new ScriptView(state.scriptViewState)\n\n deactivate: ->\n @scri...
coffeescript
chosen
[ { "from": "system", "value": "Add span tags to match old behaviour of React\n\nThis is what happens when you rely on non-specified behaviour ;)\n" }, { "from": "human", "value": "class Skr.Screens.TimeTracking.MiniControls extends Lanes.React.Component\n\n onEditEvent: ->\n @props.onEd...
coffeescript
chosen
[ { "from": "system", "value": "Fix doc with mock stuff\n" }, { "from": "human", "value": "\n# This provides hyperclick support for Perl 6 using hyperclick\n# Please see https://atom.io/packages/hyperclick\nmodule.exports =\nclass Perl6HyperclickProvider\n\n providerName: 'perl6-hyperclick'\n\n ...
coffeescript
chosen
[ { "from": "system", "value": "Disable authentication in development, and make routes DRYer\n" }, { "from": "human", "value": "passport = require('./initializers/authentication')\n\nnarrativeApi = require('./routes/api/narrative')\ndashboardRoutes = require('./routes/dashboard.coffee')\nindicator...
coffeescript
chosen
[ { "from": "system", "value": "Extend list of recognised indent/outdent keywords\n" }, { "from": "human", "value": "\".source.viml\":\n\teditor:\n\t\tcommentStart: '\" '\n\t\tincreaseIndentPattern: \"(?:^|\\\\s)(?:if|else|elseif|for|function!?|while)(?:\\\\s|$)\"\n\t\tdecreaseIndentPattern: \"(?:...
coffeescript
chosen
[ { "from": "system", "value": "Add a safety check to prevent an infinite loop.\n" }, { "from": "human", "value": "Impromptu = require '../impromptu'\nasync = require 'async'\n\nclass Repository extends Impromptu.Cache.Global\n prepare: (method, fn) ->\n return Impromptu.Cache.Global::[method]...
coffeescript
chosen
[ { "from": "system", "value": "Add custom command for inserting a date stamp\n" }, { "from": "human", "value": "path = require 'path'\n\n# require('web-frame').setZoomFactor(1.15)\n\noldWindowDimensions = {}\n\natom.commands.add 'atom-workspace',\n 'custom:open-todo-list': ->\n todoList = pat...
coffeescript
chosen