@json-editor/json-editor 2.9.0-beta.0 → 2.9.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/CHANGELOG.md +35 -1
- package/README.md +16 -7
- package/dist/jsoneditor.js +2 -2
- package/dist/jsoneditor.js.LICENSE.txt +15 -0
- package/dist/jsoneditor.js.map +1 -0
- package/dist/nonmin/jsoneditor.js +989 -127
- package/dist/nonmin/jsoneditor.js.map +1 -1
- package/docs/index.html +22 -10
- package/docs/meta_schema.json +3 -2
- package/docs/starrating.html +2 -6
- package/package.json +4 -2
- package/src/defaults.js +9 -1
- package/src/editor.js +17 -3
- package/src/editors/array.js +7 -4
- package/src/editors/multiselect.js +1 -0
- package/src/editors/object.css +3 -3
- package/src/editors/object.css.js +1 -1
- package/src/editors/object.js +5 -2
- package/src/editors/table.js +11 -4
- package/src/editors/upload.js +3 -2
- package/src/themes/barebones.js +3 -1
- package/src/themes/bootstrap5.css +97 -0
- package/src/themes/bootstrap5.css.js +3 -0
- package/src/themes/bootstrap5.js +623 -0
- package/src/themes/index.js +2 -0
- package/src/themes/tailwind.js +2 -2
- package/tests/codeceptjs/core_test.js +107 -17
- package/tests/codeceptjs/editors/array_test.js +6 -5
- package/tests/codeceptjs/editors/button_test.js +7 -6
- package/tests/codeceptjs/editors/checkbox_test.js +3 -2
- package/tests/codeceptjs/editors/integer_test.js +3 -2
- package/tests/codeceptjs/editors/issues/issue-gh-1158_test.js +10 -0
- package/tests/codeceptjs/editors/issues/issue-gh-1257_test.js +13 -0
- package/tests/codeceptjs/editors/number_test.js +2 -1
- package/tests/codeceptjs/editors/object_test.js +39 -38
- package/tests/codeceptjs/editors/option-no_default_values_test.js +1 -1
- package/tests/codeceptjs/editors/programmatic-changes_test.js +3 -2
- package/tests/codeceptjs/editors/tabs_test.js +5 -3
- package/tests/codeceptjs/editors/validation_test.js +3 -1
- package/tests/codeceptjs/meta-schema_test.js +72 -4
- package/tests/codeceptjs/schemaloader_test.js +2 -1
- package/tests/codeceptjs/test-config.js +3 -0
- package/tests/codeceptjs/themes_test.js +14 -0
- package/tests/pages/anyof-2.html +90 -0
- package/tests/pages/anyof.html +1 -1
- package/tests/pages/container-attributes.html +50 -0
- package/tests/pages/issues/issue-gh-1158.html +50 -0
- package/tests/pages/issues/issue-gh-1233-failing.html +46 -0
- package/tests/pages/issues/issue-gh-1233-passing.html +49 -0
- package/tests/pages/issues/issue-gh-1257.html +77 -0
- package/tests/pages/meta-schema.html +747 -0
- package/tests/pages/meta_schema.json +3 -16
- package/tests/pages/oneof-2.html +90 -0
- package/tests/pages/per-editor-options.html +44 -0
- package/tests/pages/stepper.html +2 -2
- package/tests/pages/themes.html +2 -0
- /package/tests/pages/{table-move-events.html → array-events-table.html} +0 -0
- /package/tests/pages/{array-move-events.html → array-events.html} +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,8 +1,42 @@
|
|
|
1
1
|
### Unreleased
|
|
2
2
|
|
|
3
|
-
###
|
|
3
|
+
### 2.9.0
|
|
4
|
+
|
|
5
|
+
Updated datetime example page
|
|
6
|
+
Updated packages
|
|
7
|
+
Fixed issue #1133: default values for each of the oneOf options
|
|
8
|
+
Upgraded codeceptjs from 2 to 3
|
|
9
|
+
Fixed npm audit issues
|
|
10
|
+
Fixed unnecessary Null values included in enums
|
|
11
|
+
Fixed radio editors not recognising numerical values
|
|
12
|
+
|
|
13
|
+
### 2.9.0-beta.1
|
|
14
|
+
|
|
15
|
+
- Fixed editors default values bug
|
|
16
|
+
- Fixed typo in example schema
|
|
17
|
+
- Fixed color editors default value bug
|
|
18
|
+
- Improved docs page UI with ACE editor and some spacing
|
|
19
|
+
- Fixed hidden option for upload editor
|
|
20
|
+
- Fixed array editors events and callbacks params
|
|
21
|
+
- Added link to GitHub repo in docs page
|
|
22
|
+
- Fixed typo in code
|
|
23
|
+
- Added test for meta-schema scenario
|
|
24
|
+
- Added test for $ref schema with oneOf/anyOf scenario
|
|
25
|
+
- Added Bootstrap 5 theme
|
|
26
|
+
- Removed !important flags from CSS
|
|
27
|
+
- Added upload translations
|
|
28
|
+
- Updated SCEditor documentation
|
|
29
|
+
- Fixed test waits
|
|
30
|
+
- Fixed per editor Options
|
|
31
|
+
- Fixed bug in tailwind and barebones theme. Append errors to element that exist.
|
|
32
|
+
- Fixed #1194 Event listener removed after destroy
|
|
33
|
+
- Added setContainerAttributes option
|
|
34
|
+
- Fixed select2/selectize cannnot add new option
|
|
35
|
+
|
|
36
|
+
### 2.9.0-beta.0
|
|
4
37
|
|
|
5
38
|
- Enh #1162 Added cache system for schema loader (chhill-redhat)
|
|
39
|
+
- Added warnings undefined callbacks
|
|
6
40
|
|
|
7
41
|
### 2.8.0
|
|
8
42
|
|
package/README.md
CHANGED
|
@@ -463,6 +463,7 @@ The currently supported themes are:
|
|
|
463
463
|
* barebones
|
|
464
464
|
* html (the default)
|
|
465
465
|
* bootstrap4
|
|
466
|
+
* bootstrap5
|
|
466
467
|
* spectre
|
|
467
468
|
* tailwind
|
|
468
469
|
|
|
@@ -724,7 +725,8 @@ Here is an example that will show a color picker in browsers that support it:
|
|
|
724
725
|
|
|
725
726
|
#### String Editors Input Attributes
|
|
726
727
|
|
|
727
|
-
You can set custom attributes such as **placeholder**, **class** and **data-** on the input field
|
|
728
|
+
You can set custom attributes such as **placeholder**, **class** and **data-** on the input field and on the editor container
|
|
729
|
+
using the special options keyword `inputAttributes` and `containerAttributes`.
|
|
728
730
|
|
|
729
731
|
Like this:
|
|
730
732
|
|
|
@@ -738,6 +740,10 @@ Like this:
|
|
|
738
740
|
"inputAttributes": {
|
|
739
741
|
"placeholder": "your name here...",
|
|
740
742
|
"class": "myclass"
|
|
743
|
+
},
|
|
744
|
+
"containerAttributes": {
|
|
745
|
+
"data-container": "my-container",
|
|
746
|
+
"class": "my-container-class"
|
|
741
747
|
}
|
|
742
748
|
}
|
|
743
749
|
}
|
|
@@ -749,12 +755,12 @@ Like this:
|
|
|
749
755
|
|
|
750
756
|
In addition to the standard HTML input formats, JSON Editor can also integrate with several 3rd party specialized editors. These libraries are not included in JSON Editor and you must load them on the page yourself.
|
|
751
757
|
|
|
752
|
-
__SCEditor__ provides WYSIWYG editing of HTML and BBCode. To use it, set the format to `
|
|
758
|
+
__SCEditor__ provides WYSIWYG editing of HTML and BBCode. To use it, set the format to `xhtml` or `bbcode` and set the `wysiwyg` option to `true`:
|
|
753
759
|
|
|
754
760
|
```json
|
|
755
761
|
{
|
|
756
762
|
"type": "string",
|
|
757
|
-
"format": "
|
|
763
|
+
"format": "xhtml",
|
|
758
764
|
"options": {
|
|
759
765
|
"wysiwyg": true
|
|
760
766
|
}
|
|
@@ -1012,14 +1018,17 @@ When an array item is added, removed, moved up, moved or removed the json editor
|
|
|
1012
1018
|
editor.on('moveRow', editor => {
|
|
1013
1019
|
console.log('moveRow', editor)
|
|
1014
1020
|
});
|
|
1021
|
+
|
|
1015
1022
|
editor.on('addRow', editor => {
|
|
1016
1023
|
console.log('addRow', editor)
|
|
1017
1024
|
});
|
|
1018
|
-
|
|
1019
|
-
|
|
1025
|
+
|
|
1026
|
+
editor.on('deleteRow', deletedValue => {
|
|
1027
|
+
console.log('deleteRow', deletedValue)
|
|
1020
1028
|
});
|
|
1021
|
-
|
|
1022
|
-
|
|
1029
|
+
|
|
1030
|
+
editor.on('deleteAllRows', deletedValues => {
|
|
1031
|
+
console.log('deleteAllRows', deletedValues)
|
|
1023
1032
|
});
|
|
1024
1033
|
```
|
|
1025
1034
|
|