Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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: 4 additions & 4 deletions eslint.config.mjs
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import { fixupPluginRules } from "@eslint/compat";
import { FlatCompat } from "@eslint/eslintrc";
import js from "@eslint/js";
import typescriptEslint from "@typescript-eslint/eslint-plugin";
import tsParser from "@typescript-eslint/parser";
import react from "eslint-plugin-react";
import reactHooks from "eslint-plugin-react-hooks";
import simpleImportSort from "eslint-plugin-simple-import-sort";
import { fixupPluginRules } from "@eslint/compat";
import tsParser from "@typescript-eslint/parser";
import path from "node:path";
import { fileURLToPath } from "node:url";
import js from "@eslint/js";
import { FlatCompat } from "@eslint/eslintrc";

const __filename = fileURLToPath(import.meta.url);
const __dirname = path.dirname(__filename);
Expand Down
99 changes: 49 additions & 50 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -68,37 +68,37 @@
"autolint:all": "yarn autolint:scripts && yarn autolint:styles && yarn autolint:prettier"
},
"dependencies": {
"@blueprintjs/colors": "^5.1.8",
"@blueprintjs/core": "^5.18.0",
"@blueprintjs/select": "^5.3.19",
"@carbon/icons": "^11.58.0",
"@carbon/react": "^1.80.1",
"@codemirror/lang-html": "^6.4.9",
"@codemirror/lang-javascript": "^6.2.3",
"@codemirror/lang-json": "^6.0.1",
"@codemirror/lang-markdown": "^6.3.2",
"@codemirror/lang-sql": "^6.8.0",
"@blueprintjs/colors": "^5.1.11",
"@blueprintjs/core": "^5.19.1",
"@blueprintjs/select": "^5.3.21",
"@carbon/icons": "^11.70.0",
"@carbon/react": "^1.96.0",
"@codemirror/lang-html": "^6.4.11",
"@codemirror/lang-javascript": "^6.2.4",
"@codemirror/lang-json": "^6.0.2",
"@codemirror/lang-markdown": "^6.5.0",
"@codemirror/lang-sql": "^6.10.0",
"@codemirror/lang-xml": "^6.1.0",
"@codemirror/lang-yaml": "^6.1.2",
"@codemirror/legacy-modes": "^6.5.0",
"@codemirror/legacy-modes": "^6.5.2",
"@mavrin/remark-typograf": "^2.2.0",
"@xyflow/react": "^12.6.0",
"@xyflow/react": "^12.9.3",
"classnames": "^2.5.1",
"codemirror": "^6.0.1",
"codemirror": "^6.0.2",
"color": "^4.2.3",
"compute-scroll-into-view": "^3.1.1",
"he": "^1.2.0",
"jshint": "^2.13.6",
"lodash": "^4.17.21",
"n3": "^1.25.1",
"n3": "^1.26.0",
"re-resizable": "^6.10.3",
"react": "^16.13.1",
"react-dom": "^16.14.0",
"react-flow-renderer": "9.7.4",
"react-inlinesvg": "^3.0.3",
"react-is": "^16.13.1",
"react-markdown": "^10.1.0",
"react-syntax-highlighter": "^15.6.1",
"react-syntax-highlighter": "^15.6.6",
"rehype-external-links": "^3.0.0",
"rehype-raw": "^7.0.0",
"remark-definition-list": "^2.0.0",
Expand All @@ -107,55 +107,54 @@
"reset-css": "^5.0.2",
"unified": "^11.0.5",
"wicg-inert": "^3.1.3",
"xml-formatter": "^3.6.5"
"xml-formatter": "^3.6.7"
},
"devDependencies": {
"@babel/core": "^7.26.10",
"@babel/plugin-transform-class-properties": "^7.25.9",
"@babel/plugin-transform-private-methods": "^7.25.9",
"@babel/plugin-transform-private-property-in-object": "^7.25.9",
"@babel/preset-env": "^7.26.9",
"@babel/preset-flow": "^7.25.9",
"@babel/preset-react": "^7.26.3",
"@babel/preset-typescript": "^7.27.0",
"@eslint/compat": "^1.2.8",
"@babel/core": "^7.28.5",
"@babel/plugin-transform-class-properties": "^7.27.1",
"@babel/plugin-transform-private-methods": "^7.27.1",
"@babel/plugin-transform-private-property-in-object": "^7.27.1",
"@babel/preset-env": "^7.28.5",
"@babel/preset-flow": "^7.27.1",
"@babel/preset-react": "^7.28.5",
"@babel/preset-typescript": "^7.28.5",
"@eslint/compat": "^1.4.1",
"@eslint/eslintrc": "^3.3.1",
"@eslint/js": "^9.24.0",
"@storybook/addon-actions": "^8.6.12",
"@storybook/addon-essentials": "^8.6.12",
"@storybook/addon-jest": "^8.6.12",
"@storybook/addon-links": "^8.6.12",
"@eslint/js": "^9.39.1",
"@storybook/addon-actions": "^8.6.14",
"@storybook/addon-essentials": "^8.6.14",
"@storybook/addon-jest": "^8.6.14",
"@storybook/addon-links": "^8.6.14",
"@storybook/addon-webpack5-compiler-babel": "^3.0.6",
"@storybook/cli": "^8.6.12",
"@storybook/cli": "^8.6.14",
"@storybook/preset-scss": "^1.0.3",
"@storybook/react": "^8.6.12",
"@storybook/react-webpack5": "^8.6.12",
"@storybook/test": "^8.6.12",
"@testing-library/jest-dom": "^6.6.3",
"@storybook/react": "^8.6.14",
"@storybook/react-webpack5": "^8.6.14",
"@storybook/test": "^8.6.14",
"@testing-library/jest-dom": "^6.9.1",
"@testing-library/react": "^12.1.5",
"@types/codemirror": "^5.60.15",
"@types/color": "^3.0.6",
"@types/he": "^1.2.3",
"@types/jest": "^29.5.14",
"@types/jest": "^30.0.0",
"@types/jshint": "^2.12.4",
"@types/lodash": "^4.17.16",
"@types/n3": "^1.24.2",
"@types/react-is": "^19.0.0",
"@types/lodash": "^4.17.21",
"@types/n3": "^1.26.1",
"@types/react-is": "^19.2.0",
"@types/react-syntax-highlighter": "^15.5.13",
"@typescript-eslint/eslint-plugin": "^8.30.1",
"@typescript-eslint/parser": "^8.30.1",
"babel-jest": "^29.7.0",
"chromatic": "^11.28.0",
"eslint": "^9.24.0",
"@typescript-eslint/eslint-plugin": "^8.47.0",
"@typescript-eslint/parser": "^8.47.0",
"babel-jest": "^30.2.0",
"chromatic": "^13.3.4",
"eslint": "^9.39.1",
"eslint-plugin-react": "^7.37.5",
"eslint-plugin-react-hooks": "^5.2.0",
"eslint-plugin-react-hooks": "^7.0.1",
"eslint-plugin-simple-import-sort": "^12.1.1",
"husky": "4",
"identity-obj-proxy": "^3.0.0",
"jest": "^30.2.0",
"jest-environment-jsdom": "^30.2.0",
"jest-pnp-resolver": "^1.2.3",
"lint-staged": "^15.5.1",
"lint-staged": "^15.5.2",
"node-sass-package-importer": "^5.3.3",
"path": "^0.12.7",
"prettier": "^2.8.8",
Expand All @@ -165,7 +164,7 @@
"rimraf": "^5.0.10",
"sass": "1.62.1",
"sass-loader": "10.3.1",
"storybook": "^8.6.12",
"storybook": "^8.6.14",
"stylelint": "^16.18.0",
"stylelint-config-recess-order": "^6.0.0",
"stylelint-config-standard-scss": "^14.0.0",
Expand All @@ -180,8 +179,8 @@
"react": ">=16"
},
"resolutions": {
"**/@types/react": "^17.0.85",
"node-sass-package-importer/**/postcss": "^8.4.49",
"**/@types/react": "^17.0.90",
"node-sass-package-importer/**/postcss": "^8.5.6",
"string-width": "^4.2.3",
"wrap-ansi": "^7.0.0",
"hast-util-from-parse5": "8.0.0"
Expand Down
2 changes: 1 addition & 1 deletion src/cmem/ActivityControl/SilkActivityControl.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ export function useSilkActivityControl({
registerForUpdates(updateActivityStatus);
return unregisterFromUpdates;
},
// eslint-disable-next-line react-hooks/exhaustive-deps
[]
);

Expand Down
1 change: 1 addition & 0 deletions src/cmem/react-flow/ReactFlow/ReactFlowV12.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import {
} from "@xyflow/react";

import { CLASSPREFIX as eccgui } from "../../../configuration/constants";

import { EdgeNew } from "./../../../extensions/react-flow/edges/EdgeNew";

export type ReactFlowV12ContainerProps = ReactFlowV12Props;
Expand Down
3 changes: 2 additions & 1 deletion src/common/Intent/index.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import { CLASSPREFIX as eccgui } from "../../configuration/constants";
import { Intent as BlueprintIntent } from "@blueprintjs/core";

import { CLASSPREFIX as eccgui } from "../../configuration/constants";

export type IntentBlueprint = BlueprintIntent;
export const DefinitionsBlueprint = BlueprintIntent;

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import React from "react";
import { render } from "@testing-library/react";
import { EditorView } from "@codemirror/view";
import { render } from "@testing-library/react";

import "@testing-library/jest-dom";

Expand Down
2 changes: 1 addition & 1 deletion src/components/Icon/IconButton.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@ import React from "react";

import { CLASSPREFIX as eccgui } from "../../configuration/constants";
import Button, { ButtonProps } from "../Button/Button";
import {TestableComponent} from "../interfaces";

import { ValidIconName } from "./canonicalIconNames";
import Icon, { IconProps } from "./Icon";
import { TestIconProps } from "./TestIcon";
import {TestableComponent} from "../interfaces";

interface ExtendedButtonProps
extends Omit<ButtonProps, "name" | "icon" | "rightIcon" | "text" | "minimal" | "tooltip">, TestableComponent {
Expand Down
6 changes: 3 additions & 3 deletions src/components/TextReducer/TextReducer.test.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React from "react";
import {render, RenderResult} from "@testing-library/react";
import { render, RenderResult } from "@testing-library/react";

import "@testing-library/jest-dom";

Expand All @@ -9,10 +9,10 @@ import { Default as TextReducerStory } from "./TextReducer.stories";
describe("TextReducer", () => {
const textMustExist = (queryByText: RenderResult["queryByText"], text: string) => {
expect(queryByText(text, { exact: false })).not.toBeNull();
}
};
const textMustNotExist = (queryByText: RenderResult["queryByText"], text: string) => {
expect(queryByText(text, { exact: false })).toBeNull();
}
};
it("should display encoded HTML entities by default if they are used in the transformed markup", () => {
const { queryByText } = render(<TextReducer {...TextReducerStory.args} />);
textMustExist(queryByText, "&#x27;entities&#x27; &amp; &quot;quotes&quot;");
Expand Down
8 changes: 4 additions & 4 deletions src/extensions/codemirror/CodeMirror.tsx
Original file line number Diff line number Diff line change
@@ -1,15 +1,14 @@
import React, { useMemo, useRef } from "react";
import { defaultKeymap, indentWithTab } from "@codemirror/commands";
import { defaultHighlightStyle, foldKeymap } from "@codemirror/language";
import { EditorState, Extension, Compartment } from "@codemirror/state";
import { Compartment,EditorState, Extension } from "@codemirror/state";
import { DOMEventHandlers, EditorView, KeyBinding, keymap, Rect, ViewUpdate } from "@codemirror/view";
import { minimalSetup } from "codemirror";

import { Markdown } from "../../cmem/markdown/Markdown";
import { IntentTypes } from "../../common/Intent";
import { markField } from "../../components/AutoSuggestion/extensions/markText";
import { TestableComponent } from "../../components/interfaces";
import { MarkdownToolbar } from "./toolbars/markdown.toolbar";
import { Markdown } from "../../cmem/markdown/Markdown";
import { CLASSPREFIX as eccgui } from "../../configuration/constants";

//hooks
Expand All @@ -31,9 +30,10 @@ import {
adaptedLineNumbers,
adaptedLintGutter,
adaptedPlaceholder,
compartment,
adaptedSyntaxHighlighting,
compartment,
} from "./tests/codemirrorTestHelper";
import { MarkdownToolbar } from "./toolbars/markdown.toolbar";
import { ExtensionCreator } from "./types";

export interface CodeEditorProps extends Omit<React.HTMLAttributes<HTMLDivElement>, "translate" | "onChange" | "onKeyDown" | "onMouseDown" | "onScroll">, TestableComponent {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
//adapted v6 modes imports
import {html} from "@codemirror/lang-html"
import { javascript } from "@codemirror/lang-javascript";
import { json } from "@codemirror/lang-json";
import { markdown } from "@codemirror/lang-markdown";
import { sql } from "@codemirror/lang-sql";
import { xml } from "@codemirror/lang-xml";
import { yaml } from "@codemirror/lang-yaml";
import {html} from "@codemirror/lang-html"

import { defaultHighlightStyle, LanguageSupport, StreamLanguage, StreamParser } from "@codemirror/language";
//legacy mode imports
import { jinja2 } from "@codemirror/legacy-modes/mode/jinja2";
Expand Down
6 changes: 3 additions & 3 deletions src/extensions/codemirror/tests/codemirrorTestHelper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@
*/
//Todo this should become redundant with later patches that avoid this error

import { EditorView, placeholder, highlightSpecialChars, lineNumbers, highlightActiveLine } from "@codemirror/view";
import { syntaxHighlighting, foldGutter, codeFolding } from "@codemirror/language";
import {Extension, Compartment, StateEffect, EditorState} from "@codemirror/state";
import { codeFolding,foldGutter, syntaxHighlighting } from "@codemirror/language";
import { lintGutter } from "@codemirror/lint";
import {Compartment, EditorState,Extension, StateEffect} from "@codemirror/state";
import { EditorView, highlightActiveLine,highlightSpecialChars, lineNumbers, placeholder } from "@codemirror/view";

/** placeholder extension, current error '_view.placeholder is not a function' */
export const adaptedPlaceholder = (text?: string) =>
Expand Down
3 changes: 2 additions & 1 deletion src/extensions/react-flow/edges/EdgeNew.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,11 @@ import {
ConnectionLineComponentProps,
ConnectionLineType,
} from "@xyflow/react";
import { EdgeStraight, EdgeStep, EdgeBezier, EdgeDefaultV12Props } from "./../index";

import { CLASSPREFIX as eccgui } from "../../../configuration/constants";

import { EdgeBezier, EdgeDefaultV12Props,EdgeStep, EdgeStraight } from "./../index";

export const EdgeNew = (edgeNewProps: ConnectionLineComponentProps) => {

const {
Expand Down
4 changes: 2 additions & 2 deletions src/extensions/react-flow/handles/HandleDefault.tsx
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
import React, { memo } from "react";
import { Handle as HandleV9, HandleProps as ReactFlowHandleV9Props } from "react-flow-renderer";
import { Handle as HandleV12, HandleProps as ReactFlowHandleV12Props } from "@xyflow/react";
import { Classes as BlueprintClasses } from "@blueprintjs/core";
import {Intent} from "@blueprintjs/core/src/common/intent";
import { Handle as HandleV12, HandleProps as ReactFlowHandleV12Props } from "@xyflow/react";

import { intentClassName, IntentTypes } from "../../../common/Intent";
import { CLASSPREFIX as eccgui } from "../../../configuration/constants";
import { TooltipProps } from "../../../index";
import { ReacFlowVersionSupportProps, useReactFlowVersion } from "../versionsupport";

import { HandleContent, HandleContentProps } from "./HandleContent";
import {Intent} from "@blueprintjs/core/src/common/intent";

export type HandleCategory = "configuration" | "flexible" | "fixed" | "unknown" | "dependency";

Expand Down
3 changes: 2 additions & 1 deletion src/extensions/react-flow/minimap/MiniMap.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,10 @@ import {
} from "react-flow-renderer";
import { FlowTransform } from "react-flow-renderer/dist/types";

import { miniMapUtils } from "./utils";
import { ReacFlowVersionSupportProps, ReactFlowVersions, useReactFlowVersion } from "../versionsupport";

import { MiniMapV12, MiniMapV12Props } from "./MiniMapV12";
import { miniMapUtils } from "./utils";

export interface MiniMapBasicProps {
/**
Expand Down
2 changes: 1 addition & 1 deletion src/extensions/react-flow/minimap/MiniMapV12.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import React, { memo } from "react";
import { MiniMap as ReactFlowMiniMap, MiniMapProps as ReactFlowMiniMapProps } from "@xyflow/react";

import { miniMapUtils } from "./utils";
import { MiniMapBasicProps } from "./MiniMap";
import { miniMapUtils } from "./utils";

export interface MiniMapV12Props extends MiniMapBasicProps, Omit<ReactFlowMiniMapProps, "maskColor"> {
}
Expand Down
1 change: 1 addition & 0 deletions src/extensions/react-flow/nodes/nodeUtils.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ import { CSSProperties } from "react";
import {Node as NodeV9, XYPosition as XYPositionV9} from "react-flow-renderer";
import {Node as NodeV12, XYPosition as XYPositionV12} from "@xyflow/react";
import Color from "color";

import {NodeDimensions} from "./NodeContent";

interface StickyNoteBase {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@ import {
HtmlContentBlock,
IconButton,
MenuItem,
NodeContent,
NodeContentExtension,
OverflowText,
Tag,
TagList,
NodeContent,
NodeContentExtension,
} from "./../../../../index";
import {
Default as ContentExtensionExample,
Expand Down
Loading