@ekg.training/ekg-video-player 1.1.1 → 1.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +99 -0
- package/README.npm.md +99 -0
- package/dist/ekg_video_player.bundle.js +1 -1
- package/package.json +2 -1
package/README.md
CHANGED
|
@@ -155,6 +155,7 @@ See [`examples/React/src/App.js`](examples/React/src/App.js) or [`examples/Javas
|
|
|
155
155
|
- `translations` (object): UI translations
|
|
156
156
|
- `infoLink` (string): The link (image or video) to player information (e.g. instructions to use player)
|
|
157
157
|
- `ecgLinks` (string or array): Array of an ECG image links or url of single ECG image link
|
|
158
|
+
- `ecgNotes` (object): `{ title, content }` for ECG Notes
|
|
158
159
|
- `allowPiP` (boolean): Enable/disable availability of PIP feature
|
|
159
160
|
|
|
160
161
|
### thumbnails (object)
|
|
@@ -210,11 +211,109 @@ The `translations` object allows you to customize UI text labels and messages. A
|
|
|
210
211
|
| hideInfoLabel | Hide toolbar info label |
|
|
211
212
|
| hideECGLabel | Hide ECG |
|
|
212
213
|
| showECGLabel | Show ECG |
|
|
214
|
+
| ekgGraphLabel | ECG |
|
|
215
|
+
| openECGNotesLbl | Open Notes |
|
|
216
|
+
| closeECGNotesLbl | Close Notes |
|
|
213
217
|
| warningLabel | WARNING text |
|
|
214
218
|
| slowInternetSpeedWarning | Slow internet speed warning |
|
|
219
|
+
| popupBlockedWarning | Popup or redirects blocked warning |
|
|
220
|
+
| pipBlockedWarning | PiP blocked warning |
|
|
221
|
+
| thumbnailsLabel | Thumbnails |
|
|
222
|
+
| onLabel | On |
|
|
223
|
+
| offLabel | Off |
|
|
215
224
|
|
|
216
225
|
See [examples/React/src/App.js](https://github.com/close2realtraining/ekg-video-player/blob/main/examples/React/src/App.js) and [src/index.tsx](https://github.com/close2realtraining/ekg-video-player/blob/main/src/index.tsx) for real-world usage.
|
|
217
226
|
|
|
227
|
+
### ecgNotes (object)
|
|
228
|
+
|
|
229
|
+
#### Extended ECG Notes Format (With JSON-driven UI Support)
|
|
230
|
+
|
|
231
|
+
The `ecgNotes.content` field supports a dynamic JSON structure used by **ContentDrivenUI**.
|
|
232
|
+
|
|
233
|
+
Example supported keys inside `content`:
|
|
234
|
+
|
|
235
|
+
- **text**: WhatsApp-style rich text (`*bold*`, `_italic_`, `~strike~`, code blocks, links, `
|
|
236
|
+
`, ` `)
|
|
237
|
+
- **html**: Raw HTML rendered using `dangerouslySetInnerHTML`
|
|
238
|
+
- **tabs**: Array of tab objects (`{ id, label, content }`)
|
|
239
|
+
- **accordion**: Accordion sections (`{ head, content }`)
|
|
240
|
+
- **content**: Nested container enabling recursive structure (content → tabs → accordion → content → …)
|
|
241
|
+
|
|
242
|
+
Example:
|
|
243
|
+
|
|
244
|
+
```json
|
|
245
|
+
{
|
|
246
|
+
"ecgNotes": {
|
|
247
|
+
"title": "ECG Interpretation Notes",
|
|
248
|
+
"content": {
|
|
249
|
+
"text": "*Bold text*, _italic_, and a link: https://example.com",
|
|
250
|
+
"html": "<div style='color:red'>Important alert</div>",
|
|
251
|
+
"tabs": [
|
|
252
|
+
{
|
|
253
|
+
"id": "tab1",
|
|
254
|
+
"label": "Overview",
|
|
255
|
+
"content": { "text": "Overview content" }
|
|
256
|
+
}
|
|
257
|
+
],
|
|
258
|
+
"accordion": {
|
|
259
|
+
"head": "Detailed Analysis",
|
|
260
|
+
"content": {
|
|
261
|
+
"text": "Nested details",
|
|
262
|
+
"html": "<span>More info</span>"
|
|
263
|
+
}
|
|
264
|
+
}
|
|
265
|
+
}
|
|
266
|
+
}
|
|
267
|
+
}
|
|
268
|
+
```
|
|
269
|
+
|
|
270
|
+
<details>
|
|
271
|
+
<summary><strong>WhatsApp Text Markup Reference</strong></summary>
|
|
272
|
+
|
|
273
|
+
### WhatsApp-style Markup Table
|
|
274
|
+
|
|
275
|
+
| Format | Example | Output |
|
|
276
|
+
| ------------- | ------------ | ---------- |
|
|
277
|
+
| Bold | `*text*` | **text** |
|
|
278
|
+
| Italic | `_text_` | _text_ |
|
|
279
|
+
| Strikethrough | `~text~` | ~~text~~ |
|
|
280
|
+
| Inline Code | `` `code` `` | `code` |
|
|
281
|
+
| Newline | `\n` | line break |
|
|
282
|
+
| Tab | `\t` | 4 spaces |
|
|
283
|
+
|
|
284
|
+
---
|
|
285
|
+
|
|
286
|
+
**Example 1 — Links**
|
|
287
|
+
|
|
288
|
+
```
|
|
289
|
+
Check this: https://example.com
|
|
290
|
+
Or visit [Google](https://google.com)
|
|
291
|
+
Or [[https://openai.com|OpenAI]]
|
|
292
|
+
```
|
|
293
|
+
|
|
294
|
+
Output: <br/>
|
|
295
|
+
Check this: https://example.com
|
|
296
|
+
Or visit [Google](https://google.com)
|
|
297
|
+
Or [OpenAI](https://openai.com)
|
|
298
|
+
|
|
299
|
+
---
|
|
300
|
+
|
|
301
|
+
**Example 2 — Newlines & Tabs**
|
|
302
|
+
|
|
303
|
+
```
|
|
304
|
+
Line 1\nLine 2\n\tIndented Line
|
|
305
|
+
```
|
|
306
|
+
|
|
307
|
+
Output:
|
|
308
|
+
|
|
309
|
+
```
|
|
310
|
+
Line 1
|
|
311
|
+
Line 2
|
|
312
|
+
Indented Line
|
|
313
|
+
```
|
|
314
|
+
|
|
315
|
+
</details>
|
|
316
|
+
|
|
218
317
|
---
|
|
219
318
|
|
|
220
319
|
## Documentation & Examples
|
package/README.npm.md
CHANGED
|
@@ -155,6 +155,7 @@ See [`examples/React/src/App.js`](examples/React/src/App.js) or [`examples/Javas
|
|
|
155
155
|
- `translations` (object): UI translations
|
|
156
156
|
- `infoLink` (string): The link (image or video) to player information (e.g. instructions to use player)
|
|
157
157
|
- `ecgLinks` (string or array): Array of an ECG image links or url of single ECG image link
|
|
158
|
+
- `ecgNotes` (object): `{ title, content }` for ECG Notes
|
|
158
159
|
- `allowPiP` (boolean): Enable/disable availability of PIP feature
|
|
159
160
|
|
|
160
161
|
### thumbnails (object)
|
|
@@ -210,11 +211,109 @@ The `translations` object allows you to customize UI text labels and messages. A
|
|
|
210
211
|
| hideInfoLabel | Hide toolbar info label |
|
|
211
212
|
| hideECGLabel | Hide ECG |
|
|
212
213
|
| showECGLabel | Show ECG |
|
|
214
|
+
| ekgGraphLabel | ECG |
|
|
215
|
+
| openECGNotesLbl | Open Notes |
|
|
216
|
+
| closeECGNotesLbl | Close Notes |
|
|
213
217
|
| warningLabel | WARNING text |
|
|
214
218
|
| slowInternetSpeedWarning | Slow internet speed warning |
|
|
219
|
+
| popupBlockedWarning | Popup or redirects blocked warning |
|
|
220
|
+
| pipBlockedWarning | PiP blocked warning |
|
|
221
|
+
| thumbnailsLabel | Thumbnails |
|
|
222
|
+
| onLabel | On |
|
|
223
|
+
| offLabel | Off |
|
|
215
224
|
|
|
216
225
|
See [examples/React/src/App.js](https://github.com/close2realtraining/ekg-video-player/blob/main/examples/React/src/App.js) and [src/index.tsx](https://github.com/close2realtraining/ekg-video-player/blob/main/src/index.tsx) for real-world usage.
|
|
217
226
|
|
|
227
|
+
### ecgNotes (object)
|
|
228
|
+
|
|
229
|
+
#### Extended ECG Notes Format (With JSON-driven UI Support)
|
|
230
|
+
|
|
231
|
+
The `ecgNotes.content` field supports a dynamic JSON structure used by **ContentDrivenUI**.
|
|
232
|
+
|
|
233
|
+
Example supported keys inside `content`:
|
|
234
|
+
|
|
235
|
+
- **text**: WhatsApp-style rich text (`*bold*`, `_italic_`, `~strike~`, code blocks, links, `
|
|
236
|
+
`, ` `)
|
|
237
|
+
- **html**: Raw HTML rendered using `dangerouslySetInnerHTML`
|
|
238
|
+
- **tabs**: Array of tab objects (`{ id, label, content }`)
|
|
239
|
+
- **accordion**: Accordion sections (`{ head, content }`)
|
|
240
|
+
- **content**: Nested container enabling recursive structure (content → tabs → accordion → content → …)
|
|
241
|
+
|
|
242
|
+
Example:
|
|
243
|
+
|
|
244
|
+
```json
|
|
245
|
+
{
|
|
246
|
+
"ecgNotes": {
|
|
247
|
+
"title": "ECG Interpretation Notes",
|
|
248
|
+
"content": {
|
|
249
|
+
"text": "*Bold text*, _italic_, and a link: https://example.com",
|
|
250
|
+
"html": "<div style='color:red'>Important alert</div>",
|
|
251
|
+
"tabs": [
|
|
252
|
+
{
|
|
253
|
+
"id": "tab1",
|
|
254
|
+
"label": "Overview",
|
|
255
|
+
"content": { "text": "Overview content" }
|
|
256
|
+
}
|
|
257
|
+
],
|
|
258
|
+
"accordion": {
|
|
259
|
+
"head": "Detailed Analysis",
|
|
260
|
+
"content": {
|
|
261
|
+
"text": "Nested details",
|
|
262
|
+
"html": "<span>More info</span>"
|
|
263
|
+
}
|
|
264
|
+
}
|
|
265
|
+
}
|
|
266
|
+
}
|
|
267
|
+
}
|
|
268
|
+
```
|
|
269
|
+
|
|
270
|
+
<details>
|
|
271
|
+
<summary><strong>WhatsApp Text Markup Reference</strong></summary>
|
|
272
|
+
|
|
273
|
+
### WhatsApp-style Markup Table
|
|
274
|
+
|
|
275
|
+
| Format | Example | Output |
|
|
276
|
+
| ------------- | ------------ | ---------- |
|
|
277
|
+
| Bold | `*text*` | **text** |
|
|
278
|
+
| Italic | `_text_` | _text_ |
|
|
279
|
+
| Strikethrough | `~text~` | ~~text~~ |
|
|
280
|
+
| Inline Code | `` `code` `` | `code` |
|
|
281
|
+
| Newline | `\n` | line break |
|
|
282
|
+
| Tab | `\t` | 4 spaces |
|
|
283
|
+
|
|
284
|
+
---
|
|
285
|
+
|
|
286
|
+
**Example 1 — Links**
|
|
287
|
+
|
|
288
|
+
```
|
|
289
|
+
Check this: https://example.com
|
|
290
|
+
Or visit [Google](https://google.com)
|
|
291
|
+
Or [[https://openai.com|OpenAI]]
|
|
292
|
+
```
|
|
293
|
+
|
|
294
|
+
Output: <br/>
|
|
295
|
+
Check this: https://example.com
|
|
296
|
+
Or visit [Google](https://google.com)
|
|
297
|
+
Or [OpenAI](https://openai.com)
|
|
298
|
+
|
|
299
|
+
---
|
|
300
|
+
|
|
301
|
+
**Example 2 — Newlines & Tabs**
|
|
302
|
+
|
|
303
|
+
```
|
|
304
|
+
Line 1\nLine 2\n\tIndented Line
|
|
305
|
+
```
|
|
306
|
+
|
|
307
|
+
Output:
|
|
308
|
+
|
|
309
|
+
```
|
|
310
|
+
Line 1
|
|
311
|
+
Line 2
|
|
312
|
+
Indented Line
|
|
313
|
+
```
|
|
314
|
+
|
|
315
|
+
</details>
|
|
316
|
+
|
|
218
317
|
---
|
|
219
318
|
|
|
220
319
|
## Documentation & Examples
|