Trying latest sass-brunch (which happened to alphabetize our devDependencies.) Fixed bug with required/restricted items not showing up properly. Added quick links to open level editors from campaign editor.

This commit is contained in:
Nick Winter 2015-01-02 12:36:47 -08:00
parent 42166bf623
commit f66afa1dc0
4 changed files with 25 additions and 24 deletions

View file

@ -239,7 +239,7 @@ module.exports = class CampaignEditorView extends RootView
achievement.set 'rewards', newRewards
if achievement.hasLocalChanges()
@toSave.add achievement
getCampaignDropOffs: =>
# Fetch last 7 days of campaign drop-off rates
@ -251,7 +251,7 @@ module.exports = class CampaignEditorView extends RootView
return if @destroyed
# API returns all the campaign data currently
@campaignDropOffs = data[@campaignHandle]
mapFn = (item) ->
mapFn = (item) ->
item.startDropRate = (item.startDropped / item.started * 100).toFixed(2)
item.finishDropRate = (item.finishDropped / item.finished * 100).toFixed(2)
item
@ -309,6 +309,7 @@ class LevelNode extends TreemaObjectNode
if data.tasks
completion = "#{(t for t in data.tasks when t.complete).length} / #{data.tasks.length}"
valEl.append $("<a href='/editor/level/#{_.string.slugify(data.name)}' class='spr'>(e)</a>")
valEl.append $("<#{el}></#{el}>").addClass('treema-shortened').text name
if status
valEl.append $('<em class="spl"></em>').text status

View file

@ -331,7 +331,7 @@ module.exports = class CampaignView extends RootView
playAmbientSound: ->
return if @ambientSound
return unless file = @campaign.get('ambientSound')?[AudioPlayer.ext.substr 1]
return unless file = @campaign?.get('ambientSound')?[AudioPlayer.ext.substr 1]
src = "/file/#{file}"
unless AudioPlayer.getStatus(src)?.loaded
AudioPlayer.preloadSound src

View file

@ -93,8 +93,8 @@ module.exports = class InventoryModal extends ModalView
locked = not (item.get('original') in me.items())
#locked = false if me.get('slug') is 'nick'
required = item.get('slug') in _.flatten(_.values(@options.level.get('requiredGear') ? {}))
restricted = item.get('slug') in _.flatten(_.values(@options.level.get('restrictedGear') ? {}))
required = item.get('original') in _.flatten(_.values(@options.level.get('requiredGear') ? {}))
restricted = item.get('original') in _.flatten(_.values(@options.level.get('restrictedGear') ? {}))
placeholder = not item.getFrontFacingStats().props.length and not _.size(item.getFrontFacingStats().stats)
if placeholder and locked # The item is not complete, so don't put it into a collection.

View file

@ -72,35 +72,35 @@
"stripe": "~2.9.0"
},
"devDependencies": {
"jade": "0.33.x",
"javascript-brunch": "> 1.0 < 1.8",
"auto-reload-brunch": "> 1.0 < 1.8",
"bless-brunch": "https://github.com/ThomasConner/bless-brunch/tarball/master",
"bower": "~1.3.8",
"brunch": "~1.7.4",
"coffee-script-brunch": "https://github.com/brunch/coffee-script-brunch/tarball/master",
"coffeelint-brunch": "> 1.0 < 1.8",
"sass-brunch": "1.7.2",
"compressible": "~1.0.1",
"css-brunch": "> 1.0 < 1.8",
"jade": "0.33.x",
"jade-brunch": "> 1.0 < 1.8",
"uglify-js-brunch": "~1.7.4",
"auto-reload-brunch": "> 1.0 < 1.8",
"brunch": "~1.7.4",
"jasmine-node": "1.13.x",
"nodemon": "0.7.5",
"marked": "0.2.x",
"telepath-brunch": "https://github.com/nwinter/telepath-brunch/tarball/master",
"bower": "~1.3.8",
"bless-brunch": "https://github.com/ThomasConner/bless-brunch/tarball/master",
"karma-script-launcher": "~0.1.0",
"jasmine-spec-reporter": "~0.3.0",
"javascript-brunch": "> 1.0 < 1.8",
"karma": "~0.12",
"karma-chrome-launcher": "~0.1.2",
"karma-coffee-preprocessor": "~0.1.2",
"karma-coverage": "~0.1.4",
"karma-firefox-launcher": "~0.1.3",
"karma-html2js-preprocessor": "~0.1.0",
"karma-coffee-preprocessor": "~0.1.2",
"karma-jasmine": "~0.2.0",
"requirejs": "~2.1.10",
"karma-requirejs": "~0.2.1",
"karma-phantomjs-launcher": "~0.1.1",
"karma": "~0.12",
"karma-coverage": "~0.1.4",
"compressible": "~1.0.1",
"jasmine-spec-reporter": "~0.3.0"
"karma-requirejs": "~0.2.1",
"karma-script-launcher": "~0.1.0",
"marked": "0.2.x",
"nodemon": "0.7.5",
"requirejs": "~2.1.10",
"sass-brunch": "^1.8.8",
"telepath-brunch": "https://github.com/nwinter/telepath-brunch/tarball/master",
"uglify-js-brunch": "~1.7.4"
},
"license": "MIT for the code, and CC-BY for the art and music",
"private": true,