-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
update schema of manifest.json for console update v2 #23
- Loading branch information
1 parent
90dd2fa
commit b24c9cf
Showing
4 changed files
with
239 additions
and
1,905 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,90 @@ | ||
const manifestScema = { | ||
required: ["id", "name", "version", "host", "uiEntryPoints"], | ||
properties: { | ||
id: { | ||
type: "string", | ||
pattern: "(\\l|\\w|\\d){8}" | ||
}, | ||
name: { | ||
type: "string", | ||
minLength: 3, | ||
maxLength: 45 | ||
}, | ||
version: { | ||
type: "string", | ||
pattern: "^[1-9]?[0-9].[1-9]?[0-9].[1-9]?[0-9]$" | ||
}, | ||
icons: { | ||
type: "array", | ||
maxItems: 2, | ||
minItems: 2, | ||
uniqueItems: true, | ||
items: { | ||
required: ["path", "width", "height"], | ||
properties: { | ||
path: { | ||
type: "string" | ||
}, | ||
width: { | ||
type: "integer", | ||
enum: [24, 48] | ||
}, | ||
height: { | ||
type: "integer", | ||
enum: [24, 48] | ||
} | ||
} | ||
} | ||
}, | ||
host: { | ||
type: "object", | ||
required: ["app", "minVersion"], | ||
properties: { | ||
app: { | ||
type: "string", | ||
enum: ["XD"] | ||
}, | ||
minVersion: { | ||
type: "string", | ||
pattern: "^([1-9][0-9]+|[0-9])\.([0-9]+[1-9]|[0-9])$" | ||
}, | ||
maxVersion: { | ||
type: "string", | ||
pattern: "^([1-9][0-9]+|[0-9])\.([0-9]+[1-9]|[0-9])$" | ||
} | ||
} | ||
}, | ||
uiEntryPoints: { | ||
type: "array", | ||
minItems: 1, | ||
uniqueItems: true, | ||
items: { | ||
required: ["type", "label"], | ||
properties: { | ||
type: { | ||
type: "string", | ||
enum: ["menu", "panel"] | ||
}, | ||
label: { | ||
type: ["string", "object"] | ||
}, | ||
commandId: { | ||
type: "string" | ||
}, | ||
panelId: { | ||
type: "string" | ||
}, | ||
shortcut: { | ||
type: "object", | ||
properties: { | ||
mac: { type: "string" }, | ||
win: { type: "string" } | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} | ||
}; | ||
|
||
module.exports = manifestScema; |
Oops, something went wrong.