Skip to content

Commit 67c6b04

Browse files
targosstropitek
andauthored
chore!: upgrade to jquery 3 (#1169)
* fix: jquery-migrate 1.4.1 deprecations * wip: update jQuery to v3 * fixup * chore!: remove biojs * chore: update dependencies * feat: update katex to v0.16 * feat: update mf-parser to v3.6.0 * chore: update eslint config * feat: update fontawesome to v7.0.0 * feat: update mathjs to v14.6.0 * chore: do not update conventional-changelog * chore: remove unused d3-hierarchy * feat: update mime-types to v3.0.1 * feat: update semver to v7.7.2 * chore: update dependencies * feat: update superagent to v10.2.3 * chore: update dependencies * feat: update jsbarcode to v3.12.1 * refactor: move fancytree to npm dependencies * refactor: move numeral to npm dependencies * feat: update leaflet to v1.9.4 and move it to package.json * refactor: move moment to npm dependencies * refactor: move marked to npm dependencies * refactor: move pouchdb to npm dependencies * refactor: move papaparse to npm dependencies and update to v5 * refactor: move requirejs to npm dependencies * refactor: move json-chart to npm dependencies * chore: update dependencies * fix: use correct debug version * chore: update dependencies * chore: update dependencies * chore: update dependencies * chore: update eslint config * fixup: correct fancytree import * chore: fix build do not use superagent in init bundle and remove phantom babel dependency * fix: use newer version of jquery.event.drag and jquery.event.drop modules Those are compatible with jquery 3 * fix: update position of select fields in libform's group table element There is a breaking change in jquery in how offset positions are calculated. Previously using jquery method `offsetParent()`, now using native `offsetParent` instead which considers different offset parents. * chore: eslint fix * fix: restore closing of color selector on palette select * docs: better testcase slick grid update preferences * docs: dedupe testcase * docs: remove non-working testcase which relies on visualizer-helper * docs: move slickgrid testcases to slickgrid folder * docs: add slickgrid reorder rows testcase * docs: add failing panzoom example * fix: update panzoom to a version compatible with jquery v3 * chore: jquery-mousewheel is no longer needed with panzoom update * docs: add panzoom overlay example in testcase * docs: better fancytree testcase * docs: remove dummy testcase the dummy_module module does not exist anymore * fix: correct show / hide column implementation * fix: do not load removed jquery-mouswheel in loading_plot * fix: remove fabtastic dependency Change color picker in favor of spectrum everywhere fixes canvas_matrix, pie_chart, leaflet, dendrogram, loading_plot and spectra_displayer * docs: improve slickgrid testcases * fix: correct jquery updating breaking well-plate module * fix: correct use of `this` in $.Deferred * docs: update phylogram testcases * fix: correct hexagonal chart module * docs: add panzoom example with SVG * fix: correct reference to module id * fixup: refactor and correct canvas matrix drag handling Remove jquery dependency jquery.threedubmedia * fix(pie_chart_jit): do not use non-existing configuration options * fix: resolve race condition which can lead to failed module instantiation The problem is problably related to jquery changing their promise implementation to be spec compliant. To reproduce: - Instantiate code editor - Instantiate code executor Results (most of the time) in a crash, or a code executor component which does not have a label on its button. * chore: remove log and unused var * update dependencies * fixup: cleanup event listener in matrix module * fix: correct loading date in slick editor and use native date picker instead of jquery UI * chore: fix jquery deprecations in drag and drop module * chore: remove console.log --------- Co-authored-by: Daniel Kostro <kostro.d@gmail.com>
1 parent 90342b3 commit 67c6b04

667 files changed

Lines changed: 6326 additions & 152544 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.ncurc.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,7 @@ reject:
44
- delay
55
# Now ESM and depends on top-level await.
66
- tempfile
7+
# Version 7 had breaking changes not worth the effort.
8+
- conventional-changelog
9+
# Version 2.0.3 made a breaking change with whitespaces: https://github.com/slab/quill/issues/4509
10+
- quill

bower.json

Lines changed: 6 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -12,61 +12,36 @@
1212
},
1313
"license": "MIT",
1414
"dependencies": {
15-
"ace": "ajaxorg/ace-builds#v1.4.6",
16-
"async": "2.1.4",
17-
"babel-standalone": "6.19.0",
18-
"bowser": "1.0.0",
15+
"ace": "ajaxorg/ace-builds#v1.43.2",
1916
"chroma-js": "1.1.1",
2017
"ckeditor": "4.7.3",
2118
"colors": "3.0.0",
2219
"d3": "3.5.17",
23-
"d3-plugins": "cheminfo/d3-plugins#ea652308c616f3accde0a418f7ccc6254a932985",
2420
"eventEmitter": "^5.2.3",
25-
"fancytree": "2.20.0",
26-
"farbtastic": "2.0.0-alpha.1",
27-
"fetch": "2.0.1",
2821
"file-saver.js": "cheminfo-js/file-saver.js#6a90cb37e56fbb110f03c70c90ebceb9312650db",
2922
"flag-icon-css": "2.8.0",
3023
"jit": "2.0.2",
3124
"jqgrid_edit": "git://github.com/NPellet/jqGrid#4.5.6",
32-
"jquery": "2.2.4",
33-
"jquery-cookie": "1.4.1",
34-
"jquery-mousewheel": "3.1.13",
3525
"jquery-qrcode": "cheminfo/jquery-qrcode#efece6cf4e32d1151436a146a2ac0e2197e0837b",
3626
"jquery-tmpl": "BorisMoore/jquery-tmpl#vBeta1.0.0",
37-
"jquery-ui": "1.12.1",
38-
"jquery.panzoom": "cheminfo/jquery.panzoom#626f65a0180211aafc9b5d57696ac56350be6bf1",
39-
"jquery.threedubmedia": "git://github.com/threedubmedia/jquery.threedubmedia",
40-
"jsbarcode": "3.5.7",
27+
"jquery.panzoom": "cheminfo/jquery.panzoom#8fea7dc6539cc414419818956d8102ed47dea94b",
4128
"jsgraph": "2.2.36",
4229
"jsme": "bcdc8f0d475eb72c2d75d20afae0b7ca4ebde273",
4330
"jsmol": "v1.2.0",
44-
"json-chart": "1.1.0",
45-
"jsoneditor": "5.5.11",
4631
"jszip": "3.1.3",
47-
"leaflet": "1.0.2",
48-
"leaflet-omnivore": "0.3.2",
4932
"lodash": "4.17.5",
5033
"loglevel": "1.4.1",
51-
"marked": "0.3.6",
5234
"ml": "0.2.1",
53-
"modernizr": "2.8.3",
54-
"moment": "2.17.1",
55-
"moment-duration-format": "~1.3.0",
5635
"nmr-simulation": "0.2.1",
5736
"notifyjs": "0.4.2",
58-
"numeral": "2.0.6",
59-
"onde": "cheminfo/onde#126c1571a3b212abbefb5351ad9b192cef35e7a1",
60-
"papa-parse": "4.1.2",
61-
"pouchdb": "3.3.1",
62-
"requirejs": "2.3.6",
37+
"onde": "cheminfo/onde#9ed3407d02ca323b8dce8d2456eb54b49a804344",
6338
"select2": "4.0.3",
6439
"setImmediate": "YuzuJS/setImmediate#1.0.5",
6540
"slickgrid": "cheminfo/SlickGrid#6423d3d4c9e09180ad83a9166d149e3e4124320d",
66-
"spectrum": "1.8.0",
67-
"sprintf": "1.0.3",
41+
"spectrum": "101b05c1d977fbc529ae4c3b6865b1f7ab70c6e0",
42+
"sprintf": "1.1.3",
6843
"threejs": "r71",
69-
"ui-contextmenu": "1.14.0",
44+
"ui-contextmenu": "1.18.1",
7045
"uri.js": "1.18.4",
7146
"web-animations-js": "2.2.2",
7247
"x2js": "1.2.0",
@@ -75,7 +50,6 @@
7550
},
7651
"resolutions": {
7752
"jsgraph": "2.2.36",
78-
"jquery": "2.2.4",
7953
"eventEmitter": "^5.1.0"
8054
},
8155
"private": true

eslint.config.mjs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,9 @@ export default defineConfig(
2222
{
2323
rules: {
2424
'unicorn/consistent-function-scoping': 'off',
25+
'unicorn/no-array-reverse': 'off',
26+
'unicorn/no-array-sort': 'off',
27+
'unicorn/no-immediate-mutation': 'off',
2528
'unicorn/no-this-assignment': 'off',
2629
'unicorn/prefer-code-point': 'off',
2730
'unicorn/prefer-default-parameters': 'off',

gruntfile.js

Lines changed: 23 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -191,22 +191,11 @@ module.exports = function (grunt) {
191191
cwd: './src/components/',
192192
src: [
193193
'./d3/d3*',
194-
[
195-
'./fancytree/dist/jquery.fancytree*.js',
196-
'./fancytree/dist/skin-lion/*',
197-
],
198194
[
199195
'./jqgrid_edit/js/*.js',
200196
'./jqgrid_edit/js/i18n/grid.locale-en.js',
201197
'./jqgrid_edit/css/*.css',
202198
],
203-
'./jquery/dist/*',
204-
[
205-
'./jquery-ui/ui/*.js',
206-
'./jquery-ui/ui/effects/*.js',
207-
'./jquery-ui/ui/widgets/*.js',
208-
'./jquery-ui/themes/base/**',
209-
],
210199
'./threejs/build/three.min.js',
211200
'./ace/src/**',
212201
[
@@ -219,66 +208,38 @@ module.exports = function (grunt) {
219208
'./ckeditor/plugins/**',
220209
'./ckeditor/config.js',
221210
],
222-
'./farbtastic/src/farbtastic.js',
223-
'./jquery.threedubmedia/event.drag/jquery.event.drag.js',
224211
'./sprintf/dist/**',
225-
'./requirejs/require.js',
226212
'./x2js/xml2json*',
227-
[
228-
'./leaflet/dist/**',
229-
'./leaflet-omnivore/leaflet-omnivore.min.js',
230-
],
231-
'./jsoneditor/dist/**',
232213
'./jit/Jit/**/*',
233214
'./ui-contextmenu/jquery.ui-contextmenu*',
234-
'./papa-parse/papaparse*',
235215
'./colors/css/colors.min.css',
236-
'./pouchdb/dist/**',
237216
'./uri.js/src/*.js',
238217
'./onde/src/*',
239218
['./spectrum/spectrum.js', './spectrum/spectrum.css'],
240-
'./superagent/superagent.js',
241-
'./modernizr/modernizr.js',
242219
'./lodash/dist/**',
243-
'./bowser/bowser*',
244-
'./jquery-cookie/jquery.cookie.js',
245220
'./chemcalc/lib.js',
246221
'./jsgraph/dist/**',
247222
'./jsme/**',
248223
'./jsmol/**',
249224
'./jcampconverter/*',
250-
'./jsbarcode/dist/*.js',
251225
'./slickgrid/**',
252226
'./ml/dist/*',
253227
'./jquery-tmpl/**',
254228
'./setImmediate/setImmediate.js',
255229
'./chroma-js/chroma*',
256-
'./async/dist/**',
257230
'./loglevel/dist/**',
258-
'./marked/lib/marked.js',
259231
'./highlight.js/build/highlight.pack.js',
260232
'./jquery.panzoom/dist/*.js',
261-
'./jquery-mousewheel/*.js',
262233
'./select2/dist/**',
263234
'./jszip/dist/**',
264235
'./file-saver.js/*.js',
265-
'./json-chart/dist/*',
266-
'./d3-plugins/**',
267-
'./mime-types/**',
268236
'./notifyjs/dist/**',
269237
'./web-animations-js/*.js',
270238
'./web-animations-js/*.js.map',
271-
'./moment/moment*',
272-
'./moment-duration-format/lib/moment-duration-format.js',
273-
'./numeral/numeral*',
274239
'./flag-icon-css/css/flag-icon.min.css',
275240
'./flag-icon-css/flags/**',
276241
'./jquery-qrcode/jquery.qrcode.min.js',
277-
'./mathjs/dist/**',
278242
'./nmr-simulation/**',
279-
'./katex/dist/**',
280-
'./babel-standalone/**',
281-
'./fetch/fetch.js',
282243
'./js-yaml/dist/**',
283244
'./canvg/dist/**',
284245
'./eventEmitter/*.js',
@@ -289,18 +250,36 @@ module.exports = function (grunt) {
289250
expand: true,
290251
cwd: './node_modules',
291252
src: [
292-
'./katex/dist/**',
293253
'./angularplasmid/dist/**',
294-
'./mathjs/dist/math.min.js',
295-
'./mathjs/dist/math.min.map',
254+
'./jquery/dist/*',
255+
[
256+
'./jquery.fancytree/dist/modules/jquery.fancytree*.js',
257+
'./jquery.fancytree/dist/skin-lion/*',
258+
],
259+
['./jquery-ui/dist/*.js', './jquery-ui/themes/base/**'],
260+
'./jsbarcode/dist/*.js',
261+
'./jsoneditor/dist/**',
262+
'./jquery-migrate/dist/*',
263+
'./katex/dist/**',
264+
[
265+
'./leaflet/dist/**',
266+
'./@mapbox/leaflet-omnivore/leaflet-omnivore.min.js',
267+
],
268+
'./marked/lib/marked.js',
269+
'./mathjs/lib/browser/**',
270+
'./moment/moment.js',
271+
'./moment-duration-format/lib/moment-duration-format.js',
272+
'./numeral/min/numeral.min.js',
296273
'./openchemlib/dist/**',
274+
'./papaparse/papaparse*',
275+
'./pouchdb/dist/**',
297276
[
298277
'./quill/dist/*.js*',
299278
'./quill/dist/*.css',
300279
'./quill-resize-module/dist/resize.*',
301280
'./quill-table-better/dist/quill-table-better.*',
302281
],
303-
'./d3-hierarchy/dist/d3-hierarchy.min.js',
282+
'./requirejs/require.js',
304283
'./@fortawesome/fontawesome-free/css/all.min.css',
305284
'./@fortawesome/fontawesome-free/webfonts/*',
306285
],
@@ -459,7 +438,7 @@ module.exports = function (grunt) {
459438
modules: [
460439
{
461440
name: 'init',
462-
exclude: ['babel', 'lodash'],
441+
exclude: ['lodash'],
463442
},
464443
],
465444
},

0 commit comments

Comments
 (0)