Skip to content

Instantly share code, notes, and snippets.

@shaydoc
Last active May 13, 2020 06:35
Show Gist options
  • Save shaydoc/3d52670c7874f52f79ca14fbc9e29bdd to your computer and use it in GitHub Desktop.
Save shaydoc/3d52670c7874f52f79ca14fbc9e29bdd to your computer and use it in GitHub Desktop.
plugin sdk manifest
{
"manifest": {
"schemaVersion":0.0.1,
"id": "{{devportal-id}}",
"name": "tw-spaces-core",
"description": "This is a Teamwork core plugin package including the Checklist and Desk Demo modules",
"extendedDescription": "s3://tw-spaces-core.html",
"version": "0.2.5",
"author": "Spaces team",
"organisation": "teamwork",
"repository": "https://github.com/Teamwork/tw-spaces-core-widgets",
"marketplace":{
"coverImage":"plugin-cover.png",
"moduleImages":{
"checkList":['checklist-img1.png','checklist-img2.png','checklist-img3.png'],
"fullContact":['full-contact-img1.png','full-contact-img2.png','full-contact-img3.png']
}
},
"settings": {
"fullContact.apiKey": {
"displayName": 'The API key for FullContact',
"type": 'string',
"defaultValue": '',
"isPublic": false
},
"fullContact.authScheme": {
"displayName": "The Auth Scheme for FullContact",
"type": "string",
"defaultValue": "Bearer",
"isPublic": false
},
"fullContact.host": {
"displayName": "The endpoint address for FullContact",
"type": "string",
"defaultValue": "https://api.fullcontact.com",
"isPublic": false
},
"fullContant.httpMethod": {
"displayName": "The http method for calling FullContact",
"type": "string",
"defaultValue":"POST",
"isPublic": false
}
},
"modules": [{
"name": "Checklist",
"type": "custom-element",
"url": "js://Checklist",
"placements": {
spaces:['editor', 'inline-comments']
projects: ['notebooks','tasks-comments']
},
"configuration": {
"customElementName": "tw-spaces-core-checklist",
"description": "Checklist Component for Spaces Editor",
"extendedDescription": "s3://full-contact.html",
"keywords": "[]",
"editorConfiguration":{
"attributes": "[]",
"childNodeNames": "['tw-json']",
"shouldIncludeInPrint": true,
"isInlineElement": false,
"requiresProjects": false,
},
"icons": ["checklist-icon-sm", "checklist-icon-md", "checklist-icon-lg"]
}
},
{
"name": "FullContact",
"type": "custom-element",
"url": "js://FullContact",
"placements": {
"desk": ["ticket"]
},
"configuration": {
"customElementName": "tw-desk-full-contact",
"description": "Desk Full Contact for embedding on Tickets",
"keywords": "[]",
"extendedDescription": "s3://full-contact.html",
"editorConfiguration":{},
"icons": ["full-contact-icon-sm", "full-contact-demo-icon-md", "full-contact-icon-lg"]
}
}
}
]
}
}
@ready4god2513
Copy link

Can we change this

 "placements": [
        { "app": "spaces", "location": "editor" }
      ],

to a map instead? This means each app could only have one entry and an array for each location the plugin is supported. Would also make it a bit faster to access the locations for a specific app

"placements":{
"spaces":["editor","comments","inlinecomments"]
}

I'd like to echo this. It also allows us to get rid of marketplace/supportedApplications. If the key spaces is provided then it's available for spaces, otherwise not. There is a bit of duplication in having both. Additionally when they are keys rather than values it's more clear to describe.

@gkubisa
Copy link

gkubisa commented May 13, 2020

We have already stopped using this gist and moved the information to this Spaces page.

PS. I see the placements property was already updated as you suggested.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment