Skip to content

chore(deps-dev): bump to ESLint v9 #3081

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 62 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
62 commits
Select commit Hold shift + click to select a range
dae1ec8
chore(deps-dev): bump the lint group with 6 updates
dependabot[bot] Apr 15, 2024
a0c4cd2
replace the old dependencies for typescript-eslint by the new
csouchet Apr 9, 2024
f179b53
rename the eslint config file
csouchet Apr 9, 2024
cc0e70a
Migrate the plugin
csouchet Apr 9, 2024
53e3c82
migrate parserOptions
csouchet Apr 9, 2024
84f470f
migrate extends
csouchet Apr 9, 2024
8145241
migrate overrides
csouchet Apr 9, 2024
9976840
migrate ignore
csouchet Apr 9, 2024
97dec41
wip: fix conf
csouchet Apr 9, 2024
a58e0f8
bump dependencies for eslint
csouchet Oct 8, 2024
8785342
enable the configuration of eslint-plugin-import
csouchet Oct 8, 2024
09b8e2c
Apply suggestions from code review
csouchet Oct 8, 2024
9a2ff43
Update dependabot configuration
csouchet Oct 8, 2024
694a71b
update the configuration
csouchet Oct 8, 2024
aaa0152
migrate eslint-plugin-playwright configuration
csouchet Oct 29, 2024
7ea987d
migrate jest and jest-extended conf in tests
csouchet Oct 29, 2024
b004437
rename
csouchet Oct 29, 2024
d14ca16
fix config usage
csouchet Oct 29, 2024
30c733b
bump
csouchet Oct 29, 2024
3e94f10
fix config
csouchet Oct 30, 2024
30c08aa
execute eslint only on files of dev, scripts, src and test folders an…
csouchet Oct 30, 2024
c42d033
Avoid to use conf on cjs and mjs files
csouchet Oct 30, 2024
6597cb5
ignore data of performance tests
csouchet Oct 30, 2024
971305e
bump
csouchet Nov 12, 2024
1758ddb
disabled 'import/no-unresolved' for .mjs files
csouchet Dec 6, 2024
9ddc5a0
bump eslint dependencies
csouchet Jan 7, 2025
fbde9b5
fix ignored patterns
csouchet Jan 7, 2025
d717a45
fix import plugin in eslint config.
csouchet Jan 7, 2025
99c5d68
use extends feature of flat config for eslint
csouchet Jan 7, 2025
6a560bd
fix import/namespace
csouchet Jan 7, 2025
1da63f1
change configuration order
csouchet Jan 7, 2025
b2d7b2a
Disable 'unicorn/numeric-separators-style' for JS files
csouchet Jan 7, 2025
1044c22
no ?? in cjs files. replace by ||
csouchet Jan 7, 2025
be82526
replace @typescript-eslint/no-loss-of-precision by no-loss-of-precision
csouchet Jan 7, 2025
0505c73
Disable 'unicorn/prefer-optional-catch-binding' on JS files
csouchet Jan 7, 2025
6e20074
in eslint v9, we can only have one file of configuration.
csouchet Jan 7, 2025
ec652da
ignore test/typescript-support/*
csouchet Jan 7, 2025
a1dbdbe
revert some changes
csouchet Jan 7, 2025
e675e33
simplify timeout in milliseconds
csouchet Jan 13, 2025
f51263a
Merge remote-tracking branch 'origin/master' into chore/eslint9
csouchet Jan 16, 2025
16681cc
bump eslint dependencies
csouchet Jan 16, 2025
8b1de4f
Upgrade ECMA version to 2020 in ESLint to keep the usage of Nullish c…
csouchet Jan 17, 2025
63e555c
Merge branch 'master' into chore/eslint9
csouchet Jan 17, 2025
075ced6
Merge remote-tracking branch 'origin/master' into chore/eslint9
csouchet Jan 20, 2025
5f9e89c
bump eslint and dependencies
csouchet Jan 27, 2025
c949630
Merge remote-tracking branch 'origin/master' into chore/eslint9
csouchet Jan 27, 2025
fd58585
Merge branch 'master' into chore/eslint9
csouchet Jan 28, 2025
62db97d
Merge branch 'master' into chore/eslint9
csouchet Feb 3, 2025
9bf203f
bump eslint dependency
csouchet Feb 3, 2025
431c815
Merge remote-tracking branch 'origin/master' into chore/eslint9
csouchet Feb 12, 2025
c2c74dd
bump eslint dependencies
csouchet Feb 12, 2025
ba412d4
Merge branch 'master' into chore/eslint9
csouchet Feb 21, 2025
aac82e4
bump eslint dependencies
csouchet Feb 21, 2025
cedbcc8
fix lint
csouchet Feb 21, 2025
a7d8244
improve config
csouchet Feb 24, 2025
a7df48b
Merge remote-tracking branch 'origin/master' into chore/eslint9
csouchet Feb 24, 2025
7b3e944
bump eslint dependencies
csouchet Feb 24, 2025
60b21e2
bump eslint dependencies
csouchet Mar 10, 2025
fe7a875
Merge remote-tracking branch 'origin/master' into chore/eslint9
csouchet Mar 10, 2025
6ea7b45
Merge remote-tracking branch 'origin/master' into chore/eslint9
csouchet Mar 11, 2025
29c2e63
bump eslint dependencies
csouchet Mar 11, 2025
a9f24a5
Merge remote-tracking branch 'origin/master' into chore/eslint9
csouchet Mar 11, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 0 additions & 8 deletions .eslintignore

This file was deleted.

143 changes: 0 additions & 143 deletions .eslintrc.cjs

This file was deleted.

3 changes: 2 additions & 1 deletion .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,11 +39,12 @@ updates:
- "ts-jest"
lint:
patterns:
- "@typescript-eslint/*"
- "@eslint/*"
- "eslint"
- "eslint-*"
- "lint-staged"
- "prettier"
- "typescript-eslint"
rollup:
patterns:
- "@rollup/*"
Expand Down
10 changes: 5 additions & 5 deletions dev/ts/component/SvgExporter.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ limitations under the License.

import type { mxGraph, mxSvgCanvas2D as mxSvgCanvas2DType } from 'mxgraph';

import { mxgraph, mxClient, mxConstants, mxSvgCanvas2D, mxUtils } from '../../../src/component/mxgraph/initializer';
import { mxgraph, mxClient, mxConstants, mxSvgCanvas2D, mxUtilities } from '../../../src/component/mxgraph/initializer';

interface SvgExportOptions {
scale: number;
Expand Down Expand Up @@ -47,7 +47,7 @@ export class SvgExporter {

private doSvgExport(enableForeignObjectForLabel: boolean): string {
const svgDocument = this.computeSvg({ scale: 1, border: 25, enableForeignObjectForLabel: enableForeignObjectForLabel });
const svgAsString = mxUtils.getXml(svgDocument);
const svgAsString = mxUtilities.getXml(svgDocument);
return `<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
${svgAsString}
Expand All @@ -64,7 +64,7 @@ ${svgAsString}
const viewScale = this.graph.view.scale;

// Prepares SVG document that holds the output
const svgDocument = mxUtils.createXmlDocument();
const svgDocument = mxUtilities.createXmlDocument();
const root = svgDocument.createElementNS(mxConstants.NS_SVG, 'svg');

const s = scale / viewScale;
Expand Down Expand Up @@ -168,7 +168,7 @@ class CanvasForExport extends mxSvgCanvas2D {

try {
this.htmlConverter.innerHTML = content;
content = mxUtils.extractTextWithWhitespace(this.htmlConverter.childNodes);
content = mxUtilities.extractTextWithWhitespace(this.htmlConverter.childNodes);

// Workaround for substring breaking double byte UTF
const exp = Math.ceil((2 * w) / this.state.fontSize);
Expand All @@ -193,7 +193,7 @@ class CanvasForExport extends mxSvgCanvas2D {

// Uses result and adds ellipsis if more than 1 char remains
if (result.length < content.length && content.length - result.length > 1) {
content = mxUtils.trim(result.join('')) + '...';
content = mxUtilities.trim(result.join('')) + '...';
}
} catch (error) {
console.warn('Error while computing txt label', error);
Expand Down
6 changes: 3 additions & 3 deletions dev/ts/component/ThemedBpmnVisualization.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ See the License for the specific language governing permissions and
limitations under the License.
*/

import { BpmnVisualization, FlowKind, ShapeBpmnElementKind, ShapeUtil, StyleConfigurator, StyleDefault } from '../../../src/bpmn-visualization';
import { BpmnVisualization, FlowKind, ShapeBpmnElementKind, ShapeUtility, StyleConfigurator, StyleDefault } from '../../../src/bpmn-visualization';
import { mxConstants } from '../../../src/component/mxgraph/initializer';
import { logStartup } from '../shared/internal-helpers';

Expand Down Expand Up @@ -116,7 +116,7 @@ export class ThemedBpmnVisualization extends BpmnVisualization {
const styleSheet = this.graph.getStylesheet();

// EVENT
for (const kind of ShapeUtil.eventKinds()) {
for (const kind of ShapeUtility.eventKinds()) {
let fillColor;
let strokeColor;
switch (kind) {
Expand Down Expand Up @@ -149,7 +149,7 @@ export class ThemedBpmnVisualization extends BpmnVisualization {
}

// TASK
for (const kind of ShapeUtil.taskKinds()) {
for (const kind of ShapeUtility.taskKinds()) {
const style = styleSheet.styles[kind];
style.fillColor = theme.taskAndCallActivityFillColor;
}
Expand Down
2 changes: 1 addition & 1 deletion dev/ts/development-bundle-index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,4 +19,4 @@ export * from './shared/main';
export * from './shared/shared-helpers';
export * from '../../src/bpmn-visualization';
// extra code not exported by bpmn-visualization
export * from '../../src/model/bpmn/internal/edge/utils';
export * from '../../src/model/bpmn/internal/edge/utilities';
20 changes: 10 additions & 10 deletions dev/ts/pages/elements-identification.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ import {
log,
removeAllOverlays,
removeCssClasses,
ShapeUtil,
ShapeUtility,
startBpmnVisualization,
updateLoadOptions,
updateStyle,
Expand Down Expand Up @@ -63,37 +63,37 @@ function computeStyleUpdateByKind(bpmnKind: BpmnElementKind): StyleUpdate {
return style;
}

if (ShapeUtil.isTask(bpmnKind)) {
if (ShapeUtility.isTask(bpmnKind)) {
style.font.color = 'Indigo';
style.fill.color = 'gold';
style.font.size = 14;
style.fill.opacity = 20;
} else if (ShapeUtil.isEvent(bpmnKind)) {
if (ShapeUtil.isBoundaryEvent(bpmnKind)) {
} else if (ShapeUtility.isEvent(bpmnKind)) {
if (ShapeUtility.isBoundaryEvent(bpmnKind)) {
style.font.color = 'inherit';
style.fill.color = 'inherit';
style.stroke.color = 'inherit';
} else {
style.font.color = 'MediumTurquoise';
style.stroke.color = 'MediumTurquoise';
}
} else if (ShapeUtil.isGateway(bpmnKind)) {
} else if (ShapeUtility.isGateway(bpmnKind)) {
style.font.color = 'CadetBlue';
style.font.opacity = 85;
style.stroke.color = 'OrangeRed';
style.stroke.width = 4;
} else if (ShapeUtil.isPoolOrLane(bpmnKind)) {
} else if (ShapeUtility.isPoolOrLane(bpmnKind)) {
style.font.color = 'white !important';
style.fill.color = 'deeppink';
style.stroke.opacity = 80;
} else if (ShapeUtil.isCallActivity(bpmnKind)) {
} else if (ShapeUtility.isCallActivity(bpmnKind)) {
style.font.color = 'white';
style.font.family = 'Times New Roman';
style.font.isItalic = true;
style.font.isStrikeThrough = true;

style.fill.color = { startColor: 'LightYellow', endColor: 'LimeGreen', direction: 'left-to-right' };
} else if (ShapeUtil.isSubProcess(bpmnKind)) {
} else if (ShapeUtility.isSubProcess(bpmnKind)) {
style.font.color = 'white';
style.font.size = 14;
style.font.family = 'Dialog';
Expand Down Expand Up @@ -133,7 +133,7 @@ function updateStyleByAPI(bpmnIds: string[], bpmnKind: ShapeBpmnElementKind): vo
}
updateStyle(subProcessChildrenIds, { fill: { color: 'swimlane' }, stroke: { color: 'swimlane' }, font: { color: 'swimlane' } });

if (ShapeUtil.isBoundaryEvent(bpmnKind)) {
if (ShapeUtility.isBoundaryEvent(bpmnKind)) {
lastIdentifiedParentBpmnIds = getParentElementIds(otherIds);
updateStyle(lastIdentifiedParentBpmnIds, { opacity: 5, font: { color: 'green', opacity: 5 }, fill: { color: 'gold' }, stroke: { color: 'red' } });
}
Expand Down Expand Up @@ -242,7 +242,7 @@ function configureControls(): void {
}

function getOverlay(bpmnKind: BpmnElementKind): Overlay {
if (ShapeUtil.isActivity(bpmnKind)) {
if (ShapeUtility.isActivity(bpmnKind)) {
return {
position: 'top-right',
label: '30',
Expand Down
Loading
Loading