Releases: elyra-ai/canvas
v13.2.0
Feature Enhancements
Common Canvas
#1987 Enable options to allow link lines to be drawn over nodes
A new boolean configuration field called enableLinksOverNodes
has been that defaults to false. If set to true
links are placed above nodes in the canvas.
Issues Resolved
- #1987 Enable option to allow link lines to be drawn over nodes using
enableLinksOverNodes
config. by @srikant-ch5 in #1988 - #1932 Publish v13 Docs using mike by @srikant-ch5 in #1967
- #2006 Use React Testing Library for icons tests by @mikieyx in #2002
- #2003 Open Link in Tooltip in Safari browser. by @srikant-ch5 in #2004
- #2008 Node's overflow menu items are unclickable if the page is scrol… by @tomlyn in #2009
v13.1.0
Common Canvas
#1943 Feature request: Allow categories[0].node_types[0].app_data.ui_data.image to receive an object as well
Node images can now be provided as JSX objects.
See documentation here:
https://elyra-ai.github.io/canvas/01.01.01-nodes/#node-image
https://elyra-ai.github.io/canvas/03.06.01-node-customization/#node-image-as-jsx
#1997 Apply class to objects being moved by dragging
A class called "d3-is-moving" is now applied to the group <g>
object of nodes and/or comments when they are being dragged to a new position.
Common Properties
#1908 Added Table toolbar for properties tables
- Common-properties tables will show a toolbar when 1+ rows are selected in tables which have either Add/remove buttons, row move buttons, or multi select editable tables.
- Table toolbar replaces table header (which has Add button and Search container). To see the Add button again, user will have to click
Cancel
button in Table toolbar to clear row selections. - In case of multi select edit rows,
Edit
button will show up in the toolbar. Clicking onEdit
button in table toolbar will open a subpanel where users can edit multi-select editable fields. At this time, edit button in selected rows will be disabled.
- For list control in small flyout, showing # item in table toolbar -
- For Fieldpicker and Expression field/function tables, Table toolbar is not shown because there aren't any batch actions (delete, row move) possible for these tables -
#1993 Removed deprecated formData and inputDataModel code from common-properties
We have removed deprecated propertiesInfo.formData
code from common-properties. If your application is still using formData, please replace it with propertiesInfo.parameterDef
.
Here’s the documentation about parameter definition - https://elyra-ai.github.io/canvas/04.01-parameter-definition/
You can also refer to the example parameter definitions in test harness.
Test Harness
#1947 Toggle between Light and Dark Mode in Test Harness.
A new Toggle is added in Test Harness which can be used to switch between Light mode and Dark mode.
Default state is light mode and when clicked it will switch to dark mode.
Issues Resolved
- #1902 Comment text truncated in sample apps and canvas test files by @tomlyn in #1903
- #1891 Enable multiple undo/redo button and panel by @tomlyn in #1904
- #1912 Fix unit tests after @carbon/react 1.56.0 upgrade by @nmgokhale in #1913
- #1909 New common-canvas documentation required (part 2) by @tomlyn in #1910
- #1915 When publish 12.x versions add a tag to avoid defaulting to
latest
by @Paul-Kawalkowski in #1916 - #1911 Add a Docs button to the test harness by @tomlyn in #1914
- #1893 New common-canvas documentation required - toolbar by @tomlyn in #1917
- #1900 Use RTL in notification-panel tests by @srikant-ch5 in #1901
- #1893 New common-canvas documentation required - node & comment custo… by @tomlyn in #1921
- #1923 Palette node tooltips not working in Tiny App by @tomlyn in #1926
- #1893 New common-canvas documentation required - tidy up, new footer,… by @tomlyn in #1929
- #1893 New common-canvas documentation required - supernodes change by @tomlyn in #1930
- #1925 Delta Translations by @Paul-Kawalkowski in #1924
- #1893 New common-canvas documentation required - final cleanup by @tomlyn in #1934
- #1935 Show/Hide password label is not translated in Passwordfield v13 by @srikant-ch5 in #1936
- #1945 Fixed multiselect infinite loop after after Carbon v11.57.0 update by @nmgokhale in #1946
- #1919 Scroll Alert into view in Common Properties when clicked on an Alert Link by @srikant-ch5 in #1920
- #1938 Add GIFs to docs for different selection gestures by @tomlyn in #1939
- #1951 Miscellaneous documentation improvements by @tomlyn in #1952
- #1941 Fix warning in console in harness right flyout by @srikant-ch5 in #1942
- #1943 Feature request: Allow categories[0].node_types[0].app_data.ui_… by @tomlyn in #1944
- #1943 Feature request: Allow categories[0].node_types[0].app_data.ui_… by @tomlyn in #1953
- 1954 Documentation for JSX Icons by @tomlyn in #1955
- #1954 Documentation for JSX Icons - part 2 by @tomlyn in #1956
- #1961 Ensure common-canvas uses for focus color by @tomlyn in #1962
- #1963 In Elyra Canvas v13.0.0 node labels and decoration labels have … by @tomlyn in #1964
- #1959 Cascade chevron in context toolbar overflow menu is low for Edi… by @tomlyn in #1960
- #1957 Notification Center becomes hidden when zooming with side panel… by @tomlyn in #1958
- #1965 The tip config checkboxes in the test harness don't work on v13 by @tomlyn in #1966
- #1970 Replace light prop with Layer component in Carbon components by @nmgokhale in #1971
- #1968 Canvas background context toolbar should disappear when mouse c… by @tomlyn in #1969
- #1949 Code-mirror-replacement text and highlighting doesn't look correct in dark mode by @veenas1 in #1950
- #1947 Test Harness should support Light and Dark Mode. by @srikant-ch5 in #1948
- #1974 Errors appear when editing Cypress files by @tomlyn in #1975
- #1977 Select appropriate color tokens for vertical nodes in test harn… by @tomlyn in #1978
- #1908 Added table toolbar for properties tables by @nmgokhale in #1922
- #1972 Resolve Error message during validations in Common Properties by @srikant-ch5 in #1973
- #1979 In Safari, error occurs when moving mouse over open edit area by @tomlyn in #1980
- #1976 Miscellaneous docs changes by @tomlyn in #1983
- #1981 Fixed unable to see tooltip for table headers having checkbox by @nmgokhale in #1982
- #1984 Update readme for @elyra/canvas for NPM documentation by @nmgokhale in #1985
- #1976 Miscellaneous docs changes by @tomlyn in #1986
- #1989 Fix Typo in Elyra docs. by @srikant-ch5 in #1990
- #1991 Cabon React Nodes sample app -- cannot reconnect links from/to … by @tomlyn in #1992
- #1995 deprecation findDOMNode in React.StrictMode prevents edit by @tomlyn in #1996
- #1993 Removed deprecated formData and inputDataModel code from common-properties by @nmgokhale in #1994
- #1997 Apply class to objects being moved by dragging by @tomlyn in #1998
Full Changelog: v13.0.0...v13.1.0
v12.47.0
Common Canvas
#1891 Enable multiple undo/redo button and panel
The common-canvas toolbar now supports a “dual-purpose” button. That is, a single button that has two parts, the left side of the button can be clicked to perform the action indicated by the button’s icon and the right side of the button, shown as a chevron, can be clicked to open a panel underneath the chevron that will allow what ever additional function the application developer wishes to present to the user that is connected with the action.
For example, this dual-purpose button, which can be seen in the ‘Stages’ sample app in the test harness, will perform the ‘undo’ action if clicked on the left-hand side:
and will display an additional panel when clicked on the right-hand side:
A dual-purpose button can be specified in the toolbar config like this:
const toolbarConfig = {
leftBar: [
{
action: "undo",
label: "Undo",
purpose: "dual",
subPanel: MultiUndoPanel,
subPanelData: { canvasController: this.canvasController }
}
],
rightBar: []
};
where:
purpose
can be either “single” (the default) or “dual”subPanel
is the React object to be inserted into the panelsubPanelData
is an object that is passed into the panel when it is created
Common Properties
Just bug fixes.
Issues Resolved
- #1891 Enable multiple undo/redo button and panel (#1904) by @tomlyn in #1907
- #1902 Comment text truncated in sample apps and canvas test files (#1… by @tomlyn in #1906
- #1927 Fixed Checkbox error/warning message showing incorrectly by @nmgokhale in #1928
Full Changelog: v12.46.0...v12.47.0
v13.0.0
Feature Enhancements
In this new major version, Elyra Canvas supports:
- Carbon 11
- React 18
- Node 20
Documentation
The Elyra Canvas documentation has moved and is now available at a new location: https://elyra-ai.github.io/canvas/ .
We are using GitHub pages for the documentation. Users can now easily search for a word in the entire documentation. Each page shows index on left-side and contents within the page on right-side for better navigation.
The Elyra Canvas Wiki is deprecated and will be removed soon. Please start using the new link.
Elyra.canvas.documentation.mov
Developer Notes
We will continue to support two versions of @elyra/canvas
until September 2024. All consuming applications should plan to upgrade to Carbon 11 within this time.
- @elyra/canvas - v12.x uses Carbon 10 - Support will end on 30 September 2024
- @elyra/canvas - v13.x uses Carbon 11
12.x versions will be in maintenance mode supporting bugs and security fixes. Any new features will be available in 13.x versions. Both versions support consuming applications running on React 16, 17 and 18.
General
Carbon 11 and React 18 for elyra-canvas
Carbon has been updated to the latest version v1.55.0. All the consuming applications using @elyra/canvas v13.x must be using Carbon 11. @carbon/react package is added as a peerDependency in v13.x. Please follow carbon v10 to v11 migration guide for more details.
Elyra canvas is now using React 18. However, we continue to support consuming applications running on React 16, 17 and 18.
Upgrade Elyra canvas and Test harness to Node 20.x.
Elyra Canvas has been upgraded from Node 16.x to 20.x.
Common-Canvas
#1865 Add dividers for the context toolbar
Dividers are now supported in the context toolbar. To add a divider, specify the following in the array returned by the contextMenuHandler
callback:
<divider: true, toolbarItem: true />
See details here: https://elyra-ai.github.io/canvas/03.03.01-context-menu-handler/#return-array-for-context-toolbar
#1891 Enable multiple undo/redo button and panel
The common-canvas toolbar now supports a “dual-purpose” button. That is, a single button that has two parts, the left side of the button can be clicked to perform the action indicated by the button’s icon and the right side of the button, shown as a chevron, can be clicked to open a panel underneath the chevron that will allow what ever additional function the application developer wishes to present to the user that is connected with the action.
For example, this dual-purpose button, which can be seen in the ‘Stages’ sample app in the test harness, will perform the ‘undo’ action if clicked on the left-hand side:
and will display an additional panel when clicked on the right-hand side:
A dual-purpose button can be specified in the toolbar config like this:
const toolbarConfig = {
leftBar: [
{
action: "undo",
label: "Undo",
purpose: "dual",
subPanel: MultiUndoPanel,
subPanelData: { canvasController: this.canvasController }
}
],
rightBar: []
};
where:
purpose
can be either “single” (the default) or “dual”subPanel
is the React object to be inserted into the panelsubPanelData
is an object that is passed into the panel when it is created
#1888 Enable HTML code in Comments when Markdown is Enabled
When the enableMarkdownInComments
config field is set to true
, common-canvas allows the user to enter markdown syntax into the comment text which is used to format the text output.
The Markdown support in comments has been extended in this release, to allow the user to enter HTML into the markdown text. This is then run, when the comment is presented in display mode. HTML support allows the user more extensive customization capabilities including the specification of CSS for the text.
For example, specifying this will color the word Red:
Some <span style="color: red">Red</span> text
Common-Properties
#1646 Use Carbon 11 Accordions in Common Properties Panels
Common properties now uses Carbon 11 Accordions for displaying categories in flyout view. Multiple categories can be opened at once.
Note - If consuming application has added any unit tests related to right flyout categories, please update them as now Common Properties is using Carbon 11 Accordion so class names should be updated if needed.
Issues Resolved
- #1851 Tiny app not working by @tomlyn in #1852
- #1855 generated_values with start_value=0 works by @nmgokhale in #1856
- #1854 Fix Annotation Warnings by @Paul-Kawalkowski in #1853
- #1860 Improvements to docs by @tomlyn in #1861
- #1862 Fix docs - home page not coming up when running on github.io by @tomlyn in #1863
- #1862 Fix docs - home page not coming up when running on github.io by @tomlyn in #1864
- #1772 Replace React-hot-loader with React-fast-refresh by @srikant-ch5 in #1773
- #1865 Add dividers for the context toolbar by @tomlyn in #1866
- #1872 Use React Testing Library for Toolbar Tests by @srikant-ch5 in #1873
- More docs changes by @tomlyn in #1871
- #1867 Fixed left nav subtabs CSS in tearsheet by @nmgokhale in #1875
- #1878 Don't createRoot every time node data changes in SvgCanvasExternal by @tomlyn in #1879
- #1876 'Cannot read properties of null' errors in console using contex… by @tomlyn in #1877
- #1881 Added Layer component at control level by @nmgokhale in #1882
- #1883 Fix Tooltips Test Harness Top Toolbar icons in v13 by @srikant-ch5 in #1885
- #1886 Don't run jest tests while deploying test harness by @nmgokhale in #1887
- #1635 use Carbon RadioButtonGroup in RadiosetControl instead of custom grouping code by @veenas1 in #1814
- #1888 Enable HTML in Markdown by @JesusGuerrero in #1889
- #1646 Panel accordions are not using the carbon standards by @srikant-ch5 in #1648
- #1828 Resolve Cypress Test Issues by @srikant-ch5 in #1843
- #1891 Enable multiple undo/redo button and panel by @tomlyn in #1892
- #1893 New common-canvas documentation required by @tomlyn in #1894
- Fix image URLs in docs by @tomlyn in #1898
Full Changelog: v13.0.0-alpha.1...v13.0.0
v12.46.0
Common-Canvas
#1865 Add dividers for the context toolbar
Dividers are now supported in the context toolbar. To add a divider, specify the following in the array returned by the contextMenuHandler callback:
<divider: true, toolbarItem: true />
See details here: https://elyra-ai.github.io/canvas/03.03.01-context-menu-handler/#return-array-for-context-toolbar
#1891 Enable multiple undo/redo button and panel
The common-canvas toolbar now supports a “dual-purpose” button. That is, a single button that has two parts, the left side of the button can be clicked to perform the action indicated by the button’s icon and the right side of the button, shown as a chevron, can be clicked to open a panel underneath the chevron that will allow what ever additional function the application developer wishes to present to the user that is connected with the action.
For example, this dual-purpose button, which can be seen in the ‘Stages’ sample app in the test harness, will perform the ‘undo’ action if clicked on the left-hand side:
and will display an additional panel when clicked on the right-hand side:
A dual-purpose button can be specified in the toolbar config like this:
const toolbarConfig = {
leftBar: [
{
action: "undo",
label: "Undo",
purpose: "dual",
subPanel: MultiUndoPanel,
subPanelData: { canvasController: this.canvasController }
}
],
rightBar: []
};
where:
purpose
can be either “single” (the default) or “dual”subPanel
is the React object to be inserted into the panelsubPanelData
is an object that is passed into the panel when it is created
#1888 Enable HTML code in Comments when Markdown is Enabled
When the enableMarkdownInComments
config field is set to true
, common-canvas allows the user to enter markdown syntax into the comment text which is used to format the text output.
The Markdown support in comments has been extended in this release, to allow the user to enter HTML into the markdown text. This is then run, when the comment is presented in display mode. HTML support allows the user more extensive customization capabilities including the specification of CSS for the text.
For example, specifying this will color the word Red:
Some <span style="color: red">Red</span> text
Issues Resolved
- Theses 6 commits get mkdocs back in sync with main: by @tomlyn in #1869
- #1865 Add dividers for the context toolbar (#1866) by @tomlyn in #1870
- More docs changes (#1871) by @tomlyn in #1874
- #1876 'Cannot read properties of null' errors in console using contex… by @tomlyn in #1880
- #1888 v12 Enable HTML in Markdown by @JesusGuerrero in #1890
- #1891 Enable multiple undo/redo button and panel (#1892) by @tomlyn in #1896
- #1893 New common-canvas documentation required (#1894) by @tomlyn in #1897
- Fix image URLs in docs (#1898) by @tomlyn in #1899
Full Changelog: v12.45.1...v12.46.0
v12.45.1
v13.0.0-alpha.1
Feature Enhancements
Build
#1576 Removed react-redux from peerDependencies
react-redux
is no longer a peerDependency. We have moved it under dependencies so that elyra canvas can have its own version of react-redux
as a production dependency.
Common-Canvas
#1846 Enable zoomTo function to execute with animation
The canvas controller zoomTo method can now be called with an animateTime parameter which is the amount of time in milliseconds the zoom action will take. If omitted the animation will default to 500ms. Set it to 0 for no animation.
canvasController.zoomTo(zoomObject, animateTime)
Common-Properties
Just bug fixes.
Issues Resolved
- #1768 Improve format of mkdocs version of Elyra Canvas Help (part 2) by @tomlyn in #1771
- #1766 Fixed ibm/plex errors in console by @nmgokhale in #1767
- #1775 Update test harness dependencies to latest by @matthoward366 in #1776
- #1780 Link guide icon in Stages sample app in wrong position by @tomlyn in #1781
- #1576 Add react-redux@8 in peerDependencies by @nmgokhale in #1774
- #1786 Command label for sizeAndPositionObjectsAction incorrect for com… by @tomlyn in #1787
- #1784 Two size node events being redone as one by @tomlyn in #1785
- #1782 Toolbar CSS styles are applied in sub-panels by @tomlyn in #1783
- #1811 First right-side toolbar item is displayed in overflow menu by @tomlyn in #1812
- #1815 Create a prototype of multiple-undo capability by @tomlyn in #1816
- #1778 Use React Testing Library for Palette tests by @srikant-ch5 in #1779
- #1821 Update styling documentation for Carbon 11 by @nmgokhale in #1823
- #1822 Change version number to instead be deployment date by @Paul-Kawalkowski in #1797
- #1826 Context toolbar is partly off the screen by @tomlyn in #1827
- #1824 Delta Translations by @sara-akhtar in #1825
- #1829 editActionHandler not called with multi-undo prototype by @tomlyn in #1830
- #1834 Unable to move around the canvas or make any drag selections if only… by @tomlyn in #1835
- #1832 Background color of selected toolbar icons has been lost by @tomlyn in #1833
- #1768 Improve format of mkdocs version of Elyra Canvas Help by @tomlyn in #1842
- #1818 Enable jest-enzyme tests using React 17 adapter by @nmgokhale in #1819
- #1846 Enable zoomTo function to execute with animation by @tomlyn in #1847
- #1844 Broken layout handler and palette open/close in v12.44.0 and hi… by @tomlyn in #1845
Full Changelog: v13.0.0-alpha.0...v13.0.0-alpha.1
v12.45.0
Feature enhancements
Build
#1748 Upgrade Elyra canvas and Test harness to Node 20.x.
Elyra Canvas has been upgraded from Node 16.x to 20.x.
Common Canvas
#1846 Enable zoomTo function to execute with animation
The canvas controller zoomTo method can now be called with an animateTime parameter which is the amount of time in milliseconds the zoom action will take. If omitted the animation will default to 500ms. Set it to 0 for no animation.
canvasController.zoomTo(zoomObject, animateTime)
Common Properties
Just bug fixes
Issues resolved
- #1748 Upgrade Elyra Canvas to Node 20.x by @srikant-ch5 in #1749
- #1758 Typo in Readme by @srikant-ch5 in #1760
- #1761 Add Elyra documentation link in readme and npm by @nmgokhale in #1762
- #1761 Add Elyra documentation link in readme and npm (#1762) by @nmgokhale in #1764
- #1703 Carbon 11, React 18, Webpack 5 for Elyra canvas by @nmgokhale in #1704
- Bump webpack-dev-middleware from 7.0.0 to 7.1.0 in /canvas_modules/harness by @dependabot in #1765
- #1768 Improve format of mkdocs version of Elyra Canvas Help by @tomlyn in #1769
- #1766 Fixed ibm/plex errors in console by @nmgokhale in #1767
- #1775 Update test harness dependencies to latest by @matthoward366 in #1776
- #1780 Link guide icon in Stages sample app in wrong position by @tomlyn in #1781
- #1576 Add react-redux@8 in peerDependencies by @nmgokhale in #1774
- #1786 Command label for sizeAndPositionObjectsAction incorrect for com… by @tomlyn in #1808
- #1784 Two size node events being redone as one (#1785) by @tomlyn in #1809
- #1811 First right-side toolbar item is displayed in overflow menu by @tomlyn in #1813
- #1782 Toolbar CSS styles are applied in sub-panels by @tomlyn in #1783
- #1815 Create a prototype of multiple-undo capability (#1816) by @tomlyn in #1820
- #1826 Context toolbar is partly off the screen (#1827) by @tomlyn in #1836
- #1829 editActionHandler not called with multi-undo prototype (#1830) by @tomlyn in #1839
- #1834 Unable to move around the canvas or make any drag selections if… by @tomlyn in #1840
- #1832 Background color of selected toolbar icons has been lost (#1833) by @tomlyn in #1841
- #1846 Enable zoomTo function to execute with animation (#1847) by @tomlyn in #1848
- #1844 Broken layout handler and palette open/close in v12.44.0 and hi… by @tomlyn in #1849
Full Changelog: v12.44.0...v12.45.0
v13.0.0-alpha.0
Feature Enhancements
This new major version of Elyra Canvas is an alpha
release. In it Elyra Canvas now supports:
- Carbon 11
- React 18
- Node 20
Note - We are releasing an alpha
version because all the unit tests are currently disabled because React 18 no longer supports enzyme testing library. We are actively working on finding a replacement for enzyme. Unit tests will be enabled in the upcoming 13.x version.
Developer Notes
We will continue to support two versions of @elyra/canvas
until September 2024. All consuming applications should plan to upgrade to Carbon 11 within this time.
- @elyra/canvas - v12.x uses Carbon 10 - Support will end on 30 September 2024
- @elyra/canvas - v13.x uses Carbon 11
12.x versions will be in maintenance mode supporting bugs and security fixes. Any new features will be available in 13.x versions. Both versions support consuming applications running on React 16, 17 and 18.
General
#1703 Carbon 11 and React 18 for elyra-canvas
Carbon has been updated to the latest version v1.53.1. All the consuming applications using @elyra/canvas v13.x must be using Carbon 11. @carbon/react package is added as a peerDependency in v13.x. Please follow carbon v10 to v11 migration guide for more details.
Elyra canvas is now using React 18. However, we continue to support consuming applications running on React 16, 17 and 18.
#1748 Upgrade Elyra canvas and Test harness to Node 20.x.
Elyra Canvas has been upgraded from Node 16.x to 20.x.
Issues Resolved
- #1748 Upgrade Elyra Canvas to Node 20.x by @srikant-ch5 in #1749
- #1758 : Typo in Readme by @srikant-ch5 in #1760
- #1761 Add Elyra documentation link in readme and npm by @nmgokhale in #1762
- #1703 Carbon 11, React 18, Webpack 5 for Elyra canvas by @nmgokhale in #1704
- Bump webpack-dev-middleware from 7.0.0 to 7.1.0 in /canvas_modules/harness by @dependabot in #1765
- #1768 Improve format of mkdocs version of Elyra Canvas Help by @tomlyn in #1769
Full Changelog: v12.44.0...v13.0.0-alpha.0
v12.44.0
Feature Enhancements
Common-Canvas
#1744 Palette icon should show selected (blue underline) highlighting when displayed in wide state
Note: The implementation of this issue required a change to the Notifications icon in the toolbar. The class that specifies the severity of the notifications (info. success, warning or error) has moved from the toolbar-content-item to its ancestor class toolbar-item.
#1750 Setting input port positions for nodes with multiple inputs
Applications are now able to programmatically position either single or multiple input/output ports anywhere relative to the node boundary: either inside or outside the node. Previously, applications could only position single input/output nodes. Multiple nodes were always arranged by the common-canvas layout code.
The following layout fields have been introduced. They can be overridden in the config passed to <CommonCanvas>
, by specifying them in the config.enableNodeLayout
object, or in the layout object returned from the layoutHandler
callback.
For input ports:
-
inputPortAutoPosition
- This is a boolean. If set to true (the default) multiple input ports are automatically arranged by common-canvas also single input ports are automatically positioned by common-canvas when the node height is greater than the default height which it might be with resizable nodes. If set to false, the entries in the
inputPortPositions
array will be used to position single and multiple input ports.
- This is a boolean. If set to true (the default) multiple input ports are automatically arranged by common-canvas also single input ports are automatically positioned by common-canvas when the node height is greater than the default height which it might be with resizable nodes. If set to false, the entries in the
-
inputPortPositions
-
This is an array. Each element of the array looks like this:
{ pos: “topLeft”, x_pos: 10, y_pos: 10 }
Thepos
field can be one of the nine points around the node:"topLeft", "topCenter", "topRight",
"middleLeft", "middleCenter", "middleRight",
"bottomLeft", "bottomCenter", "bottomRight".
-
while x_pos
and y_pos
are additional offsets (in pixels) from that position. Specifying a position (pos
) for a port ties that port to that position on the node which means, with resizable nodes, the port will move with the position it is attached to as the node is sized.
If a node has a single input port and the node is the default height, common-canvas will use the zeroth element from inputPortPositions
to position it, regardless of what inputPortAutoPosition
is set to. If the node is greater than the default height, the single port will be positioned by common-canvas automatically when inputPortAutoPosition
is set to true
and will use the position from the array when inputPortAutoPosition
is set to false
.
If a node has more than one input port and inputPortAutoPosition
is false
, common-canvas will use the elements from the inputPortPositions
array to position the ports in the same order that they appear for the node’s inputs array in the pipeline flow. If inputPortAutoPosition
is set to true
, common-canvas will automatically position the ports vertically (in the y direction) however it will use the pos
and x_pos
from the zeroth element of the array to position the nodes horizontally (in the x direction) - this is to maintain historic behavior.
Note: the behavior described above is slightly different if config.enableLinkDirection
is set to either TopBottom
or BottomTop
. With those settings the behaviors are transposed between vertical and horizontal as might be expected. So for example, a single port is positioned based on whether the width of the node is wider than the default width rather that it based on height.
For output ports:
These two fields have been added. These behave in the same way as their input port equivalents.
- outputPortAutoPosition
- ouputPortPositions
The following 12 node layout fields have been deprecated and support for them will be removed in a future major release. If you have overridden them in your application’s config (in config.enableNodeLayout
) or in what is returned from the layoutHandler
callback, they will continue to work as before but it is recommended that you convert to use the new approach now by specifying a single entry in the inputPortPositions
and/or outputPortPositions
array containing the appropriate pos
, x_pos
and y_pos
values.
inputPortLeftPosX
inputPortLeftPosY
inputPortTopPosX
inputPortTopPosY
inputPortBottomPosX
inputPortBottomPosY
outputPortRightPosX
outputPortRightPosY
outputPortTopPosX
outputPortTopPosY
outputPortBottomPosX
outputPortBottomPosY
Common-Properties
Just bug fixes.
Issues Resolved
- #1742 Overflow menu is not closed when canvas width is increased by @tomlyn in #1743
- #1744 Palette icon should show selected (blue underline) highlighting… by @tomlyn in #1745
- #1746 Refactor node preparation code in object model by @tomlyn in #1747
- #1752 Common-canvas mapping relation adjusting port position performa… by @tomlyn in #1753
- #1750 Setting input port positions for nodes with multiple inputs by @tomlyn in #1751
- #1754 Tooltip information icon should use -02 color by @tomlyn in #1755
- #1756 Switching between show and hide comments causes focus to move a… by @tomlyn in #1757
Full Changelog: v12.43.0...v12.44.0