Skip to content

Releases: clientIO/joint

Release v2.0.0

23 Oct 15:21
Compare
Choose a tag to compare

CHANGELOG

  • Typescript definitions refactored (breaking change of the release)
  • JointJS now compatible with Lodash v4 (see demo/lodash4 for instructions)
  • Geometry - add Polyline with pointAtLength(), length(), closestPointLength(), closestPoint() and convexHull()
  • Geometry - add cross(), dot(), squaredDistance(), closestPoint(), closestPointNormalizedLength(), vector(), vectorAngle(), angleBetween() to Point
  • Vectorizer - add children() and getBBox()
  • Vectorizer - fix parseTransformString() and matrixToTransformString()
  • Vectorizer - make the text y coordinate based on the first line line-height in text()
  • Vectorizer - add option to define the end-of-line character for text()
  • layout.DirectedLayout - add ability to position labels
  • layout.DirectedLayout - fix bug when the elements passed do not include their parents
  • dia.Paper - add clickThreshold, moveThreshold and preventDefaultBlankAction options
  • dia.Paper - add cancelRenderViews() for async mode
  • dia.CellView - do not reset node's transform attribute if no transform applied update()
  • dia.Element - position() can be called with { deep: true } option to set position of the embeds
  • dia.attributes - text attribute takes x into account
  • dia.attributes - add event for easier events handling on CellViews and resetOffset for paths to start at 0,0
  • dia.LinkView - stop triggering link:connect/link:disconnnect when connection not allowed
  • dia.LinkView - can sendToken() backwards
  • highlighters.Stroke - fix for magnets inside scalable group and with zero width or height

Release v1.1.0

31 Mar 10:45
Compare
Choose a tag to compare

CHANGELOG

  • add TypeScript definitions
  • update jQuery v3.1.1
  • Geometry - improve Point/Rect prototype.round(precision) - fix coordinates being converted to a string after round() with a precision called, allow negative precision
  • Geometry - add Rect inflate(), bottomLine(), topLine(), leftLine() and rightLine()
  • Geometry - Point offset() and difference() accept both a point and x,y coordinates
  • Geometry - add Line equals()
  • Geometry - Line intersection() renamed to intersect() and calculates intersection points with another line or rectangle
  • Vectorizer - stop accessing deprecated nodeName and nodeValue attribute properties
  • Vectorizer - add prototype.contains() method
  • Vectorizer - add matrixToTransformString() method as opposed to transformStringToMatrix()
  • Vectorizer - add ensureId() method
  • Vectorizer - add appendTo() method
  • Vectorizer - V(node); does not set automatically id on the node anymore
  • Vectorizer - text() with content doesn't set invalid display: null on node anymore
  • Vectorizer - fix convertRectToPathData() for rounded rectangles
  • dia.attributes - add namespace for defining custom attributes, allow camelCase attribute style
  • dia.attributes - new attributes sourceMarker, targetMarker, vertexMarker, textWrap, refRx, refRy, refCx, refCy, refX2, refY2
  • dia.attributes - improve text attribute performance on cellView update
  • dia.attributes - fix mixing various attributes (e.g. transform, refX and refDx now add up)
  • dia.Paper - add defineGradient(), defineFilter(), defineMarker() and isDefined() methods
  • dia.Paper - fix async rendering when cell was previously member of different graph.
  • dia.Paper - improve grid precision, added new grid patterns, update drawGrid() options definition.
  • dia.Paper - blank:pointerup event is fired only after a preceeding blank:pointerdown event
  • dia.Paper - add paperToLocalPoint(), clientToLocalPoint(), pageToLocalPoint(), localToPaperPoint(), localToPagePoint() and localToClientPoint().
  • dia.Paper - add paperToLocalRect(), clientToLocalRect(), pageToLocalRect(), localToPaperRect(), localToClientRect() and localToPageRect()
  • dia.Paper - add clientOffset() and pageOffset()
  • dia.Cell - make cell.attr() work as getter
  • dia.Cell - prop(), removeProp() accept also path defined as an array
  • dia.Element - add size(), getPortPositions() methods
  • dia.Element - rotate() doesn't translate embeddeded cells anymore
  • dia.Link - allow arbitrary shapes for labels
  • dia.LinkView - fix link translating when embedded and has no marker
  • dia.LinkView - set correct port and selector on the link
  • mvc.View - prevent extend() from modifying prototype propertires
  • ports events ports:add and ports:remove triggered when port is added to element/removed from element
  • utils - fix toggleFullScreen() in IE
  • utils - breakText() takes the lineHeight style into account
  • util - change cells() wrapper also accept a single cell
  • highlighter.Stroke - allow multiple strokes to be applied to a single cellView magnet, prevent memory leaks
  • connectors.jumpover - fix on graph reset

Release v1.0.3

22 Nov 14:04
Compare
Choose a tag to compare
  • make compatibility changes towards jQuery 3.1
  • shapes.TextBlock - fix SVGForeignObject detection
  • dia.Graph - fix graph references stored on cells (when a cell added to another graph)
  • layout.DirectedGraph - fix cell's graph references overriden by the layout
  • Vectorizer - remove deprecated attributes' nodeValue and nodeName calls

Release v1.0.2

27 Oct 07:53
Compare
Choose a tag to compare
  • Vectorizer - fix convertToPathData() for polyline.
  • add yarn.lock
  • improve documentation

Release v1.0.1

20 Sep 13:36
Compare
Choose a tag to compare
  • All joint views now use the joint- class name prefix for their class names.
  • dia.Element - make it easy to add ports to an arbitrary element, introduced API for ports manipulation
  • shapes.devs.Model - uses new port API internally. shapes.basic.PortsViewInterface, shapes.basic.PortsInterface are marked as deprecated
  • layout.Port - various layouts for positioning ports
  • layout.PortLabel - various layouts for positioning labels relatively to ports
  • joint.util.deepSupplement, joint.util.supplement, joint.util.mixin, joint.util.deepMixin marked as deprecated. Use lodash _.defaultsDeep, _.defaults, _.assign, _.mixin instead
  • layout.DirectedGraph - layout() returns a bbox
  • dia.LinkView - unify link:options event signature with the rest of events (breaking change)
  • dia.LinkView - fix perpendicular links outside the paper area
  • dia.ElementView - fix resizing without scalable group, re-render element when markup change
  • dia.ElementView - improve x-alignment and y-alignment for text
  • other bug fixes and improvements

Release v0.9.10

13 Jun 10:21
Compare
Choose a tag to compare

Fix for webpack, browserify bundling. See #339 and #334 for more information.

Release v0.9.9

31 May 12:11
Compare
Choose a tag to compare

JointJS

  • Added env namespace with env.test(name) and env.addTest(name, fn) methods
  • Added highlighters namespace with two highlighters (stroke and opacity). Highlighting now done automatically when: embedding an element, connecting a link to a port or element.
  • dia.Paper:
    • Added paper.drawGrid(opt) - draws grid lines on the paper's DOM element.
    • Added paper.setGridSize(gridSize) - changes the grid size of the paper.
    • Added paper.setInteractivity() for changing interactivity.
    • Added blank:mousewheel and cell:mousewheel events to paper
    • Added link:connect, link:disconnect paper events for easier link source/target change detection
    • Changed the link tool event signature (e.g. link:options) to be the same as the rest of the cell events.
  • dia.Cell:
    • Added isElement() and isLink() methods
  • dia.Element:
    • Added scale() for transforming element by providing a scale ratio and origin.
  • dia.Link:
    • Added scale() for transforming link by providing a scale ratio and origin.
  • dia.Graph:
    • Added resize(), resizeCells() for a group resizing
    • Added getCellsBBox() for getting a group bounding box
    • Added removeCells()
    • Can now use addCells(), removeCells(), and resetCells() with the same method signature. For example: addCells(cell, cell) addCells(cell, cell, opt) addCells([cell, cell]) addCells([cell, cell], opt) are all valid usage.
  • layout.DirectedGraph:
    • Added layout() align option for rank nodes alignment.

Vectorizer

  • Added transform() method to apply SVG matrix to SVG element
  • Added empty(), before() method
  • prepend() method now accepts single or multiple nodes
  • createSVGTransform() now accepts optionally an SVG matrix

Geometry

  • Added point.scale(), rect.scale() - scale point/rect with given origin.
  • Added point.toJSON(), rect.toJSON() - converts point/rect into JSON object.
  • Added leftMiddle(), rightMiddle(), topMiddle(), bottomMiddle() for finding middle points of rect sides.
  • Added ellipse.fromRect(), rect.fromEllipse() for rect-ellipse interchangeability.

Release v0.9.6

19 Dec 09:16
Compare
Choose a tag to compare

CHANGELOG

  • dia.Graph introduces new functions for traversing graphs: dfs(), bfs(), search(), isSuccessor(), isPredecessor(), getPredecessors(), getSuccessors(), isNeighbor(), isSource(), isSink(), getSources(), getSinks(), getSubgraph(), getFirstCell(), getLastCell() and getCells()
  • new functions for cloning cells dia.Graph.cloneCells(), dia.Graph.cloneSubgraph()
  • dia.Element resize() function has been extended with direction option allowing for resizing to any side
  • new convenient methods for getting source/target elements added to dia.Link: getSourceElement() and getTargetElement()
  • dia.Paper has a new option multiLinks that when set to false, prevents from creating multiple links between the same elements
  • dia.Paper has a new option function guard that allows for preventing the paper from handling UI events
  • dia.Paper findViewsInArea() has been extended with strict option that when set, returns only views that are contained within the area passed in the argument
  • Vectorizer adds a new method transformPoint() for a convenient way transform points via SVG transformation matrices
  • Geometry adds a new function rect.union()
  • another new utility function added: joint.util.setAttributesBySelector() for setting attributes on DOM elements referenced by a selector
  • dia.Element and dia.Link has a new function getAncestors() that returs an array of ancestor cells
  • dia.Link has a new method hasLoop() for checking whether the link is a loop-link
  • dia.LinkView enables for setting a custom markup for its secondary tools (enabled via the doubleLinkTools option)
  • dia.Graph getNeighbors() function extended with inbound and outbound options
  • dia.Graph has a new translate() method for translating all elements in the graph
  • routers.manhattan introduces new options startDirections, endDirections to control what direction a link can start/end and excludeTypes to ignore certain element types as obstacles
  • routers and connectors can now be defined directly on links as functions
  • links are now much faster when used with manhattan router
  • fixed a critical bug in upcoming Google Chrome which removed the native getTransformToElement() method on SVG elements
  • other bug fixes and improvements

Release v0.9.5

10 Sep 15:21
Compare
Choose a tag to compare

CHANGELOG

  • layout.DirectedGraph upgrades Dagre to v0.7.1
  • layout.DirectedGraph introduces new option resizeClusters to reposition and resize cluster elements (parents of other elements) so that they embody their children
  • cells get removeProp() method for removing - possibly nested - properties
  • cells get new addTo() method as a syntactic sugar for adding them to joint.dia.Graph
  • prop() methods on cells now accepts 'undefined' as a value (instead of behaving like a getter)
  • remove() method now correctly propagates the options object to all listeners
  • routers.Manhattan router was improved to cope with hierarchical diagrams with embedded elements and does not consider ancestors of elements as obstacles
  • routers.Manhattan router got smarter, finding better paths between source and target of a link
  • new router for links oneSide that always routes links to/from a certain side specified
  • new jumpover connector type
  • Vectorizer adds sample() method for interpolating any SVG path with discrete equidistant points
  • Vectorizer adds convertToPath(), convertToPathData() and findIntersection() functions
  • Vectorizer adds findAnnotationsAtIndex(), findAnnotationsBetweenIndexes() and shiftAnnotations() helper functions manipulating text annotations (see Vectorizer:text())
  • Vectorizer now sets v-line class to all text lines rendered with text() and v-empty-line for lines that are empty
  • Vectorizer find() now returns an array of vectorizer elements, not the DOM NodeList
  • Vectorizer V() function now throws an error if invalid markup is given to it making wrong shape definitons visible to the programmer
  • Vectorizer bbox() now does not round values making calculations more precise
  • Geometry adds rect:equals(), rect:snapToGrid() and rect:intersect() functions
  • Geometry adds clone() method to all objects
  • new events in joint.dia.Paper link:pointerdown, link:pointerdown, link:pointermove, link:pointerup, element:pointerdown, element:pointermove, element:pointerup
  • new events in joint.dia.Paper cell:contextmenu and blank:contextmenu
  • new maxWidth and maxHeight options in joint.dia.Paper fitToContent() method
  • joint.dia.Paper adds labelMove option to the interactive object for enabling moving labels via UI
  • joint.dia.Paper findViewByModel() significantly improved performance
  • fixes in joint.dia.Paper async rendering
  • new restrictTranslate option in joint.dia.Paper for restricting movement of elements
  • joint.dia.Paper introduces new cellViewNamespace option for declaring custom namespace for views (defaults to joint.shapes)
  • joint.dia.PaperelementView and linkView options can be now functions
  • joint.dia.Paper introduces new defaultRouter and defaultConnector options
  • joint.dia.Paper introduces new linkPinning option to disable creating links without source/target
  • joint.dia.Paper now ignores mouse events that are not relevant (events that do not target the internal SVG document or a cell)
  • joint.dia.Paper remove() make a proper cleanup of all views
  • fixed using multiple joint.dia.Paper objects on the same page so that they don't share any options
  • fixed normalization of touch events that now expose stopPropagation() and preventDefault() as all other events do
  • new method findModelsUnderElement() in joint.dia.Graph for finding elements below another element
  • joint.dia.Graph fixes the fetch() method
  • joint.dia.Graph introduces new cellNamespace option for declaring custom namespace for models (defaults to joint.shapes)
  • joint.dia.Graph adds new method getCells()
  • joint.dia.Graph getNeighbors() method improved and extended with deep option to better support hierarchical diagrams containing embedded elements
  • joint.dia.Link adds offset property on labels and implements dragging labels off the links
  • joint.dia.Element adds fitEmbeds() method for resizing the element so that it fits all the embedded elements inside it
  • joint.dia.ElementView getBBox() now returns the rect object of Geometry library that directly exposes various math functions for rectangles
  • new joint.util.getElementBBox() function for getting a bounding box of both HTML and SVG elements
  • new joint.util.normalizSides() function
  • new joint.util.sortElements() function for sorting DOM elements
  • add an optional context parameter to joint.util.nextFrame()
  • new filters joint.util.filter.outline and joint.util.filter.highlight
  • special JointJS attributes ref-x, ref-y, ref-width and ref-height can be specified in percentages
  • joint.dia.Link routers and connector can be now specified as functions
  • source code passed through JSCS checker, fixed coding style and indentation
  • Lodash upgraded to the latest version v3.10.1
  • Backbone upgraded to v1.2.1
  • make JointJS compatible with Browserify, Webpack and RequireJS
  • other fixes and improvements

v0.9.4

23 Jul 14:59
Compare
Choose a tag to compare
Release v0.9.4