forked from h5p/h5p-image-hotspots
-
Notifications
You must be signed in to change notification settings - Fork 0
/
semantics.json
209 lines (209 loc) · 4.72 KB
/
semantics.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
[
{
"label": "Background image",
"importance": "high",
"name": "image",
"type": "image",
"description": "Image shown on background."
},
{
"name": "backgroundImageAltText",
"type": "text",
"label": "Alternative text for background image",
"description": "If the browser can't load the image this text will be displayed instead. Also used by assistive technologies.",
"optional": true
},
{
"name": "iconType",
"type": "select",
"label": "Hotspot Icon",
"options": [
{
"value": "icon",
"label": "Predefined icon"
},
{
"value": "image",
"label": "Uploaded image"
}
],
"default": "icon"
},
{
"name": "icon",
"type": "select",
"label": "Predefined icon",
"importance": "medium",
"description": "Using a predefined icon for the hotspot.",
"widget": "showWhen",
"showWhen": {
"rules": [
{
"field": "iconType",
"equals": [
"icon"
]
}
]
},
"options": [
{
"value": "plus",
"label": "Plus"
},
{
"value": "minus",
"label": "Minus"
},
{
"value": "times",
"label": "Times"
},
{
"value": "check",
"label": "Check"
},
{
"value": "question",
"label": "Question"
},
{
"value": "info",
"label": "Info"
},
{
"value": "exclamation",
"label": "Exclamation"
}
],
"default": "plus"
},
{
"name": "iconImage",
"type": "image",
"label": "Uploaded image",
"optional": false,
"description": "Use your own image for the hotspot icon.<br>75px by 75px is recommended for your image.",
"widget": "showWhen",
"showWhen": {
"rules": [
{
"field": "iconType",
"equals": [
"image"
]
}
]
}
},
{
"name": "color",
"type": "text",
"label": "Hotspot color",
"importance": "medium",
"description": "The color of the hotspots",
"optional": true,
"default": "#981d99",
"widget": "showWhen",
"spectrum": {
"showInput": true
},
"showWhen": {
"widget": "colorSelector",
"rules": [
{
"field": "iconType",
"equals": [
"icon"
]
}
]
}
},
{
"name": "hotspots",
"type": "list",
"entity": "hotspot",
"label": "Hotspots",
"importance": "high",
"min": 1,
"defaultNum": 1,
"field": {
"name": "hotspot",
"type": "group",
"label": "Hotspot",
"importance": "high",
"fields": [
{
"name": "position",
"type": "group",
"widget": "imageCoordinateSelector",
"imageFieldPath": "../../image",
"label": "Hotspot position",
"importance": "high",
"description": "Click on the thumbnail image to place the hotspot",
"fields": [
{
"name": "x",
"type": "number"
},
{
"name": "y",
"type": "number"
},
{
"name": "legacyPositioning",
"type": "boolean"
}
]
},
{
"name": "alwaysFullscreen",
"type": "boolean",
"label": "Cover entire background image",
"importance": "low",
"description": "When the user clicks the hotspot the popup will cover the entire background image"
},
{
"name": "header",
"type": "text",
"label": "Header",
"importance": "low",
"description": "Optional header for the popup",
"optional": true
},
{
"name": "content",
"type": "list",
"label": "Popup content",
"importance": "medium",
"field": {
"name": "action",
"type": "library",
"label": "Content Item",
"options": [
"H5P.Text 1.1",
"H5P.Video 1.5",
"H5P.Image 1.1"
]
}
}
]
}
},
{
"name": "hotspotNumberLabel",
"type": "text",
"label": "Hotspot label for assistive technologies",
"default": "Hotspot #num",
"description": "Will help announce what hotspot element has been navigated to if there is no header specified for a hotspot. #num can be used to replace the hotspot number.",
"common": true
},
{
"name": "closeButtonLabel",
"type": "text",
"label": "Close button label for assistive technologies",
"default": "Close",
"common": true
}
]