contextual extension menu

This commit is contained in:
Mo Bitar
2017-01-06 13:44:25 -06:00
parent 1a2bcb39ca
commit 71b6e666b4
15 changed files with 258 additions and 52 deletions

View File

@@ -18,7 +18,6 @@ class Item {
}
get contentObject() {
// console.log("getting content object from content", this.content);
if(!this.content) {
return {};
}

View File

@@ -56,6 +56,12 @@ class Extension extends Item {
})
}
actionsWithContextForItem(item) {
return this.actions.filter(function(action){
return action.context == item.content_type || action.context == "Item";
})
}
mapContentToLocalProperties(contentObject) {
super.mapContentToLocalProperties(contentObject)
this.name = contentObject.name;