@json-editor/json-editor 2.9.0 → 2.9.1

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.
Files changed (60) hide show
  1. package/.github/workflows/build.yml +2 -0
  2. package/CHANGELOG.md +11 -7
  3. package/config/codeceptjs_helpers.js +4 -8
  4. package/config/karma.conf.js +0 -4
  5. package/config/webpack.common.js +1 -1
  6. package/config/webpack.dev.js +1 -1
  7. package/config/webpack.nonmin.js +1 -1
  8. package/config/webpack.prod.js +0 -1
  9. package/dist/dev/jsoneditor.js +3687 -0
  10. package/dist/jsoneditor.js +2 -14
  11. package/dist/jsoneditor.js.LICENSE.txt +1 -1
  12. package/dist/jsoneditor.js.map +1 -1
  13. package/dist/nonmin/jsoneditor.js +25354 -26381
  14. package/dist/nonmin/jsoneditor.js.map +1 -1
  15. package/docs/datetime.html +37 -2
  16. package/package.json +26 -24
  17. package/src/editors/integer.js +5 -3
  18. package/src/editors/multiple.js +3 -1
  19. package/src/editors/number.js +5 -3
  20. package/src/editors/radio.js +4 -6
  21. package/src/editors/select.js +0 -6
  22. package/tests/codeceptjs/core_test.js +20 -20
  23. package/tests/codeceptjs/editors/advanced_test.js +1 -1
  24. package/tests/codeceptjs/editors/array_any_of_test.js +2 -2
  25. package/tests/codeceptjs/editors/array_test.js +15 -15
  26. package/tests/codeceptjs/editors/autocomplete_test.js +3 -3
  27. package/tests/codeceptjs/editors/button_test.js +5 -5
  28. package/tests/codeceptjs/editors/checkbox_test.js +2 -2
  29. package/tests/codeceptjs/editors/colorpicker_test.js +2 -2
  30. package/tests/codeceptjs/editors/datetime_test.js +4 -4
  31. package/tests/codeceptjs/editors/inheritance_test.js +1 -1
  32. package/tests/codeceptjs/editors/integer_test.js +6 -6
  33. package/tests/codeceptjs/editors/issues/issue-gh-1133_test.js +11 -0
  34. package/tests/codeceptjs/editors/issues/issue-gh-1158_test.js +1 -1
  35. package/tests/codeceptjs/editors/issues/issue-gh-1164_test.js +12 -0
  36. package/tests/codeceptjs/editors/issues/issue-gh-1257_test.js +1 -1
  37. package/tests/codeceptjs/editors/issues/issue-gh-812_test.js +1 -1
  38. package/tests/codeceptjs/editors/jodit_test.js +2 -2
  39. package/tests/codeceptjs/editors/multiselect_test.js +1 -1
  40. package/tests/codeceptjs/editors/number_test.js +14 -12
  41. package/tests/codeceptjs/editors/object_test.js +13 -13
  42. package/tests/codeceptjs/editors/option-no_default_values_test.js +2 -2
  43. package/tests/codeceptjs/editors/programmatic-changes_test.js +2 -2
  44. package/tests/codeceptjs/editors/radio_test.js +1 -1
  45. package/tests/codeceptjs/editors/range_test.js +1 -1
  46. package/tests/codeceptjs/editors/rating_test.js +1 -1
  47. package/tests/codeceptjs/editors/select_test.js +2 -2
  48. package/tests/codeceptjs/editors/stepper_test.js +3 -3
  49. package/tests/codeceptjs/editors/string_test.js +8 -8
  50. package/tests/codeceptjs/editors/table-confirm-delete_test.js +4 -4
  51. package/tests/codeceptjs/editors/tabs_test.js +1 -1
  52. package/tests/codeceptjs/editors/uuid_test.js +5 -5
  53. package/tests/codeceptjs/editors/validation_test.js +1 -1
  54. package/tests/codeceptjs/meta-schema_test.js +4 -4
  55. package/tests/codeceptjs/schemaloader_test.js +1 -1
  56. package/tests/codeceptjs/themes_test.js +9 -9
  57. package/tests/pages/issues/issue-gh-1133.html +64 -0
  58. package/tests/pages/issues/issue-gh-1164.html +71 -0
  59. package/tests/pages/number.html +18 -0
  60. package/tests/unit/core.spec.js +6 -5
@@ -9,6 +9,8 @@ jobs:
9
9
  runs-on: ubuntu-latest
10
10
  steps:
11
11
  - uses: actions/checkout@v1
12
+ - name: Node version
13
+ run: node -v
12
14
  - name: Install
13
15
  run: npm install
14
16
  - name: Test
package/CHANGELOG.md CHANGED
@@ -1,14 +1,18 @@
1
1
  ### Unreleased
2
2
 
3
+ ### 2.9.1
4
+
5
+ - Fixed past merge
6
+
3
7
  ### 2.9.0
4
8
 
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
9
+ - Updated datetime example page
10
+ - Updated packages
11
+ - Fixed issue #1133: default values for each of the oneOf options
12
+ - Upgraded codeceptjs from 2 to 3
13
+ - Fixed npm audit issues
14
+ - Fixed unnecessary Null values included in enums
15
+ - Fixed radio editors not recognising numerical values
12
16
 
13
17
  ### 2.9.0-beta.1
14
18
 
@@ -69,32 +69,28 @@ class customHelpers extends Helper {
69
69
  // Evaluates true if xpath is checked
70
70
  async seeCheckedAttribute (xpath) {
71
71
  const helper = this.helpers['Puppeteer'] || this.helpers['WebDriver']
72
- let res = await helper.grabAttributeFrom(xpath, 'checked')
73
- return assert.ok(res !== null && typeof res !== 'undefined' && res.toString().toLowerCase() === 'true', "\x1b[31mexpected element '\x1b[91m" + xpath + "\x1b[31m' to be checked")
72
+ return await helper.waitForElement(xpath + ':checked')
74
73
  }
75
74
 
76
75
  // Custom dontSeeCheckedAttribute function.
77
76
  // Evaluates true if xpath is not checked
78
77
  async dontSeeCheckedAttribute (xpath) {
79
78
  const helper = this.helpers['Puppeteer'] || this.helpers['WebDriver']
80
- let res = await helper.grabAttributeFrom(xpath, 'checked')
81
- return assert.ok(!(res !== null && typeof res !== 'undefined' && res.toString().toLowerCase() === 'true'), "\x1b[31mexpected element '\x1b[91m" + xpath + "\x1b[31m' NOT to be checked")
79
+ return await helper.waitForInvisible(xpath + ':checked')
82
80
  }
83
81
 
84
82
  // Custom seeDisabledAttribute function.
85
83
  // Evaluates true if xpath is disabled
86
84
  async seeDisabledAttribute (xpath) {
87
85
  const helper = this.helpers['Puppeteer'] || this.helpers['WebDriver']
88
- let res = await helper.grabAttributeFrom(xpath, 'disabled')
89
- return assert.ok(res !== null && typeof res !== 'undefined' && res.toString().toLowerCase() === 'true', "\x1b[31mexpected element '\x1b[91m" + xpath + "\x1b[31m' to be disabled")
86
+ return await helper.waitForElement(xpath + ':disabled')
90
87
  }
91
88
 
92
89
  // Custom dontSeeDisabledAttributet function.
93
90
  // Evaluates true if xpath is not disabled
94
91
  async dontSeeDisabledAttribute (xpath) {
95
92
  const helper = this.helpers['Puppeteer'] || this.helpers['WebDriver']
96
- let res = await helper.grabAttributeFrom(xpath, 'disabled')
97
- return assert.ok(!(res !== null && typeof res !== 'undefined' && res.toString().toLowerCase() === 'true'), "\x1b[31mexpected element '\x1b[91m" + xpath + "\x1b[31m' NOT to be disabled")
93
+ return await helper.waitForInvisible(xpath + ':disabled')
98
94
  }
99
95
 
100
96
  // Custom seeReadOnlyAttribute function.
@@ -44,10 +44,6 @@ module.exports = function (config) {
44
44
  stats: 'errors-only'
45
45
  },
46
46
 
47
- beforeMiddleware: [
48
- 'webpackBlocker'
49
- ],
50
-
51
47
  // test results reporter to use
52
48
  // possible values: 'dots', 'progress'
53
49
  // available reporters: https://npmjs.org/browse/keyword/karma-reporter
@@ -68,7 +68,7 @@ module.exports = {
68
68
  hints: false
69
69
  },
70
70
  devServer: {
71
- contentBase: helpers.root('.'),
71
+ static: helpers.root('.'),
72
72
  historyApiFallback: true,
73
73
  port: 8080
74
74
  }
@@ -5,7 +5,7 @@ const helpers = require('./helpers')
5
5
 
6
6
  module.exports = webpackMerge(commonConfig, {
7
7
  mode: 'development',
8
- devtool: 'cheap-module-eval-source-map',
8
+ devtool: 'eval-cheap-module-source-map',
9
9
  output: {
10
10
  path: helpers.root('dist/dev'),
11
11
  publicPath: '/dist/',
@@ -6,7 +6,7 @@ const helpers = require('./helpers')
6
6
  // See https://webpack.js.org/guides/development/
7
7
  module.exports = (env) => webpackMerge(commonConfig, {
8
8
  mode: 'development',
9
- devtool: '@source-map',
9
+ devtool: 'source-map',
10
10
  output: {
11
11
  path: env && env.travis === true ? helpers.root('dist') : helpers.root('dist/nonmin'),
12
12
  publicPath: '/dist/',
@@ -17,7 +17,6 @@ module.exports = () => {
17
17
  minimize: true
18
18
  },
19
19
  plugins: [
20
- new RemoveStrictPlugin(), // I have put this in to avoid IE throwing error Assignment to read-only properties is not allowed in strict mode
21
20
  // This doesn't seem to actually be minimising the CSS!
22
21
  new webpack.NoEmitOnErrorsPlugin()
23
22
  ]