This repository has been archived by the owner on Dec 1, 2017. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' of github.com:mozilla/napkin
- Loading branch information
Showing
87 changed files
with
2,171 additions
and
5,110 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
define(['jquery', 'backbone', './extended', 'models/component'], | ||
function($, Backbone, ExtendedCollection, ComponentModel) { | ||
return ExtendedCollection.extend({ | ||
url: function() { | ||
return '/projects/' + this.options.projectId + '/screens/' + | ||
this.options.screenId + '/components'; | ||
}, | ||
|
||
model: ComponentModel | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
define(['jquery', 'backbone', './extended', 'models/element'], | ||
function($, Backbone, ExtendedCollection, ElementModel) { | ||
return ExtendedCollection.extend({ | ||
url: function() { | ||
return '/projects/' + this.options.projectId + '/screens/' + | ||
this.options.screenId + '/components/' + this.options.componentId + | ||
'/elements'; | ||
}, | ||
|
||
model: ElementModel | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
define(['jquery', 'backbone'], | ||
function($, Backbone) { | ||
var ExtendedCollection = Backbone.Collection.extend({ | ||
initialize: function(models, options) { | ||
this.options = options; | ||
}, | ||
|
||
constructParent: function(args) { | ||
args = Array.prototype.slice.call(args, 0); | ||
ExtendedCollection.prototype.initialize.apply(this, args); | ||
} | ||
}); | ||
|
||
return ExtendedCollection; | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
define(['jquery', 'backbone', './extended', 'models/project'], | ||
function($, Backbone, ExtendedCollection, ProjectModel) { | ||
return ExtendedCollection.extend({ | ||
url: '/projects', | ||
model: ProjectModel, | ||
|
||
comparator: function(project) { | ||
return project.get('id'); | ||
} | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
define(['jquery', 'backbone', './extended', 'models/screen'], | ||
function($, Backbone, ExtendedCollection, ScreenModel) { | ||
return ExtendedCollection.extend({ | ||
url: function() { | ||
return '/projects/' + this.options.projectId + '/screens'; | ||
}, | ||
|
||
model: ScreenModel, | ||
comparator: function(screen) { | ||
return screen.get('id'); | ||
} | ||
}); | ||
}); |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.