Skip to content

Commit 4c51085

Browse files
committed
Initial logic
1 parent f7ba23f commit 4c51085

36 files changed

+10980
-0
lines changed

__fixtures__/blank/issue.md

Whitespace-only changes.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
{}
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
{
2+
"name": {
3+
"label": "The Name of the Thing",
4+
"type": "input",
5+
"required": true
6+
}
7+
}

__fixtures__/blank/template.yml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
name: Example Request
2+
description: Submit an example request
3+
title: '[Request] Example'
4+
5+
body:
6+
- type: input
7+
id: name
8+
attributes:
9+
label: The Name of the Thing
10+
description: The name of the thing you want to create.
11+
placeholder: this-is-the-thing
12+
validations:
13+
required: true

__fixtures__/example/issue.md

Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
### The Name of the Thing
2+
3+
this-thing
4+
5+
### The Nickname of the Thing
6+
7+
thing
8+
9+
### The Color of the Thing
10+
11+
blue
12+
13+
### The Shape of the Thing
14+
15+
square
16+
17+
### The Sounds of the Thing
18+
19+
re, mi
20+
21+
### The Topics About the Thing
22+
23+
_No response_
24+
25+
### The Description of the Thing
26+
27+
This is a description.
28+
29+
It has multiple lines.
30+
31+
It's pretty cool!
32+
33+
### The Notes About the Thing
34+
35+
- Note
36+
- Another note
37+
- Lots of notes
38+
39+
### The Code of the Thing
40+
41+
const thing = new Thing()
42+
thing.doThing()
43+
44+
### The String Method of the Code of the Thing
45+
46+
thing.toString()
47+
48+
### Is the Thing a Thing?
49+
50+
- [x] Yes
51+
- [ ] No
52+
53+
### Is the Thing Useful?
54+
55+
- [ ] Yes
56+
- [x] Sometimes
57+
- [ ] No
58+
59+
### Read Team
60+
61+
IssueOps-Demo-Readers
62+
63+
### Write Team
64+
65+
IssueOps-Demo-Writers
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
{
2+
"name": "this-thing",
3+
"nickname": "thing",
4+
"color": ["blue"],
5+
"shape": ["square"],
6+
"sounds": ["re", "mi"],
7+
"topics": [],
8+
"description": "This is a description.\n\nIt has multiple lines.\n\nIt's pretty cool!",
9+
"notes": "- Note\n- Another note\n- Lots of notes",
10+
"code": "const thing = new Thing()\nthing.doThing()",
11+
"code-string": "thing.toString()",
12+
"is-thing": {
13+
"selected": ["Yes"],
14+
"unselected": ["No"]
15+
},
16+
"is-thing-useful": {
17+
"selected": ["Sometimes"],
18+
"unselected": ["Yes", "No"]
19+
},
20+
"read-team": "IssueOps-Demo-Readers",
21+
"write-team": "IssueOps-Demo-Writers"
22+
}
Lines changed: 90 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,90 @@
1+
{
2+
"name": {
3+
"label": "The Name of the Thing",
4+
"type": "input",
5+
"required": true
6+
},
7+
"nickname": {
8+
"label": "The Nickname of the Thing",
9+
"type": "input",
10+
"required": false
11+
},
12+
"color": {
13+
"label": "The Color of the Thing",
14+
"type": "dropdown",
15+
"required": true,
16+
"multiple": false,
17+
"options": [
18+
"blue",
19+
"black",
20+
"green",
21+
"orange",
22+
"purple",
23+
"red",
24+
"white",
25+
"yellow"
26+
]
27+
},
28+
"shape": {
29+
"label": "The Shape of the Thing",
30+
"type": "dropdown",
31+
"required": false,
32+
"multiple": false,
33+
"options": ["circle", "square", "triangle"]
34+
},
35+
"sounds": {
36+
"label": "The Sounds of the Thing",
37+
"type": "dropdown",
38+
"required": true,
39+
"multiple": true,
40+
"options": ["do", "re", "mi", "fa", "so", "la", "ti"]
41+
},
42+
"topics": {
43+
"label": "The Topics About the Thing",
44+
"type": "dropdown",
45+
"required": false,
46+
"multiple": true,
47+
"options": ["cool", "fun", "interesting", "neat"]
48+
},
49+
"description": {
50+
"label": "The Description of the Thing",
51+
"type": "textarea",
52+
"required": true
53+
},
54+
"notes": {
55+
"label": "The Notes About the Thing",
56+
"type": "textarea",
57+
"required": false
58+
},
59+
"code": {
60+
"label": "The Code of the Thing",
61+
"type": "textarea",
62+
"required": true
63+
},
64+
"code-string": {
65+
"label": "The String Method of the Code of the Thing",
66+
"type": "textarea",
67+
"required": false
68+
},
69+
"is-thing": {
70+
"label": "Is the Thing a Thing?",
71+
"type": "checkboxes",
72+
"required": false,
73+
"options": [
74+
{ "label": "Yes", "required": true },
75+
{ "label": "No", "required": false }
76+
]
77+
},
78+
"is-thing-useful": {
79+
"label": "Is the Thing Useful?",
80+
"type": "checkboxes",
81+
"required": false,
82+
"options": [
83+
{ "label": "Yes", "required": false },
84+
{ "label": "Sometimes", "required": false },
85+
{ "label": "No", "required": false }
86+
]
87+
},
88+
"read-team": { "label": "Read Team", "type": "input", "required": true },
89+
"write-team": { "label": "Write Team", "type": "input", "required": true }
90+
}

__fixtures__/example/template.yml

Lines changed: 169 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,169 @@
1+
name: Example Request
2+
description: Submit an example request
3+
title: '[Request] Example'
4+
5+
body:
6+
- type: markdown
7+
attributes:
8+
value: |
9+
# Example Request
10+
11+
This is an example request.
12+
13+
## Instructions
14+
15+
1. Fill out the form below.
16+
2. Submit the request.
17+
3. Wait for the request to be processed.
18+
- type: input
19+
id: name
20+
attributes:
21+
label: The Name of the Thing
22+
description: The name of the thing you want to create.
23+
placeholder: this-is-the-thing
24+
validations:
25+
required: true
26+
- type: input
27+
id: nickname
28+
attributes:
29+
label: The Nickname of the Thing
30+
description: (Optional) The nickname of the thing you want to create.
31+
placeholder: the-thing
32+
validations:
33+
required: false
34+
- type: dropdown
35+
id: color
36+
attributes:
37+
label: The Color of the Thing
38+
description: The color of the thing you want to create.
39+
multiple: false
40+
options:
41+
- blue
42+
- black
43+
- green
44+
- orange
45+
- purple
46+
- red
47+
- white
48+
- yellow
49+
validations:
50+
required: true
51+
- type: dropdown
52+
id: shape
53+
attributes:
54+
label: The Shape of the Thing
55+
description: (Optional) The shape of the thing you want to create.
56+
multiple: false
57+
options:
58+
- circle
59+
- square
60+
- triangle
61+
validations:
62+
required: false
63+
- type: dropdown
64+
id: sounds
65+
attributes:
66+
label: The Sounds of the Thing
67+
description: (Multiple) The sounds(s) the thing makes.
68+
multiple: true
69+
options:
70+
- do
71+
- re
72+
- mi
73+
- fa
74+
- so
75+
- la
76+
- ti
77+
validations:
78+
required: true
79+
- type: dropdown
80+
id: topics
81+
attributes:
82+
label: The Topics About the Thing
83+
description: |
84+
(Multiple / Optional) The topic(s) about the thing you want to create.
85+
multiple: true
86+
options:
87+
- cool
88+
- fun
89+
- interesting
90+
- neat
91+
validations:
92+
required: false
93+
- type: textarea
94+
id: description
95+
attributes:
96+
label: The Description of the Thing
97+
description: The description of the thing you want to create.
98+
placeholder: This is a description of the thing.
99+
validations:
100+
required: true
101+
- type: textarea
102+
id: notes
103+
attributes:
104+
label: The Notes About the Thing
105+
description: (Optional) The notes about the thing you want to create.
106+
placeholder: These are notes about the thing.
107+
validations:
108+
required: false
109+
- type: textarea
110+
id: code
111+
attributes:
112+
label: The Code of the Thing
113+
description: The code of the thing you want to create.
114+
render: js
115+
placeholder: |
116+
const thing = new Thing()
117+
thing.doSomething()
118+
validations:
119+
required: true
120+
- type: textarea
121+
id: code-string
122+
attributes:
123+
label: The String Method of the Code of the Thing
124+
description: (Optional) The method to return the thing as a string.
125+
render: js
126+
placeholder: |
127+
thing.toString()
128+
validations:
129+
required: false
130+
- type: checkboxes
131+
id: is-thing
132+
attributes:
133+
label: Is the Thing a Thing?
134+
description: Is the thing a thing?
135+
options:
136+
- label: 'Yes'
137+
required: true
138+
- label: 'No'
139+
required: false
140+
- type: checkboxes
141+
id: is-thing-useful
142+
attributes:
143+
label: Is the Thing Useful?
144+
description: (Optional) Is the thing a useful thing?
145+
options:
146+
- label: 'Yes'
147+
required: false
148+
- label: Sometimes
149+
required: false
150+
- label: 'No'
151+
required: false
152+
- type: input
153+
id: read-team
154+
attributes:
155+
label: Read Team
156+
description: |
157+
The read-only GitHub Team (hint: `IssueOps-Demo-Readers`).
158+
placeholder: IssueOps-Demo-Readers
159+
validations:
160+
required: true
161+
- type: input
162+
id: write-team
163+
attributes:
164+
label: Write Team
165+
description: |
166+
The write-access GitHub Team (hint: `IssueOps-Demo-Writers`).
167+
placeholder: IssueOps-Demo-Writers
168+
validations:
169+
required: true

__fixtures__/extra/issue.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
### Model Name
2+
3+
### Model Description
4+
5+
who's molecule is this? (we don't know)
6+
7+
### Ersilia ID
8+
9+
None
10+
11+
### This is an extra field
12+
13+
The following link is just an example:
14+
15+
`www.example.com`
16+
17+
### Code
18+
19+
None
20+
21+
### License

0 commit comments

Comments
 (0)