Skip to content

Commit

Permalink
feat(cat-voices): f14-Comments Schema for Catalyst Proposals (#1731)
Browse files Browse the repository at this point in the history
* feat: added comments template

* fix: missing brace

* fix: comment restructued, removed in comment meta

---------

Co-authored-by: Oleksandr Prokhorenko <[email protected]>
Co-authored-by: Steven Johnson <[email protected]>
  • Loading branch information
3 people authored Feb 4, 2025
1 parent c4ab078 commit d10ea59
Show file tree
Hide file tree
Showing 2 changed files with 42 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"metadata": {
"id": "550e8400-e29b-41d4-a716-446655440000",
"proposal_id": "67e55044-10b1-426f-9247-bb680e5fe0c8",
"parent_id": "123e4567-e89b-12d3-a456-426614174000"
},
"comment": {
"content": "This is an example comment on a proposal.\nIt can contain multiple lines of plain text content.\nThe content must be between 1 and 5000 characters in length."
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
{
"$schema": "http://json-schema.org/draft-07/schema#",
"$id": "https://cardano.org/schemas/catalyst/comments",
"title": "Proposal Comments Schema",
"description": "Schema for comments on Catalyst proposals",
"definitions": {
"multiLineTextEntry": {
"$comment": "UI - Multiline text entry without any markup or rich text capability.",
"type": "string",
"pattern": "^[\\S\\s]+$",
"x-note": "Enter multiple lines of plain text. You can use line breaks but no special formatting."
}
},
"type": "object",
"required": ["comment"],
"properties": {
"comment": {
"type": "object",
"required": ["content"],
"description": "The comments on the proposal",
"properties": {
"content": {
"$ref": "#/definitions/multiLineTextEntry",
"description": "The comment text content",
"minLength": 1,
"maxLength": 5000
}
}

}
}
}

0 comments on commit d10ea59

Please sign in to comment.