Skip to content

Releases: esridc/HubTextNotesLayer

v0.7.0

03 Aug 21:16
Compare
Choose a tag to compare
  • Add support for text notes to be attached to features in a Feature Layer. #6
  • Consolidation of placement-related options into a single placement object:
    • placementHint => placement.hint
    • placementAlignments => placement.pointAlignments (clarify usage)
  • Addition of placement.outsidePolygon option to allow polygon notes to be allowed to move outside the polygon interior (default), or to be constrained to the interior.
  • Update note position when its target graphic geometry changes (position and/or shape, e.g. when using sketch tools to move or reshape a drawn graphic).

v0.6.0

25 Jun 23:07
Compare
Choose a tag to compare
  • Use note-occluded class to style occluded notes #5
  • Add a drag-stopped event when note drag-drop completes

v0.5.0

15 Jun 19:27
Compare
Choose a tag to compare
  • Add textMaxCharacters parameter to enforce max character length on text notes #4
  • Add note-dragging class to notes for drag-drop styling 8bbf748
  • Allow polygon notes to free-drag while in polygon interior (continue to snap to outer ring when outside)
    67ff216

v0.4.0

11 Jun 17:40
b21a05e
Compare
Choose a tag to compare
  • Convert rich text to plain text on paste #2
  • Add ability to drag notes #3
    • Notes can be dragged by the user, with the note location constrained according to the graphic's geometry type. The note snaps to the nearest allowable location.
      • Along the path of a line (either side)
      • Along the outer ring of a polygon (exterior side only)
      • At one of up to 8 cardinal and diagonal positions, configurable per-note (see below).
    • Notes are draggable when editable (dragging controls are hidden otherwise).
    • Editable text div is now wrapped by an outer container, which can be draggable.
    • HubTextNotesLayer constructor parameters:
      • cssClass replaces textClass
      • cssClass is used to style outer/draggable container
      • note-text is used to style the inner/text container
    • HubTextNotesLayer.addNoteForGraphic() parameters:
      • placementAlignments defines a list (array) of allowed placement positions for notes attached to point graphics. Allowed values are: right, top-right, top, top-left, left, bottom-left, bottom, bottom-right.
  • Use alpha channel when converting text notes to graphics, for Web Map export ae93362
  • Explicitly remove event listeners to guard against memory leaks 544bc3f

v0.3.2

02 Jun 05:26
Compare
Choose a tag to compare
  • Convert the placementHint parameter to a JSAPI Point instance if needed, to provide better compatibility for accepting either a JSON representation of a Point, or an actual Point instance.

v0.3.1

02 Jun 05:25
Compare
Choose a tag to compare
  • Re-publish v0.3.0 with minified build (originally mistakenly published with full build).

v0.3.0

02 Jun 05:24
Compare
Choose a tag to compare
  • Add optional placementHint parameter for better control over where notes are placed. Notes are still constrained near the perimeter of the target graphic, but placed in the direction of the placementHint.
  • When positioning notes, anchor them to 8 fixed points on the note (e.g. center top, middle right, center bottom, middle left, and each of the 4 corners) based on their direction. This provides increased stability / less jumpiness, for example when notes are rapidly re-positioned as the user types.

v0.2.0

26 May 17:45
Compare
Choose a tag to compare
  • Add HubTextNote.focus() method (and remove focus option from HubTextNotesLayer.addNoteForGraphic()).
  • Store note map point as full Point geometry instance (for easier JSAPI compatibility when auto-casting not supported).
  • Improved handling of text background color (only include background color on text when it differs from foreground).
  • Get first tests working with JSAPI dependencies.

v0.1.0

15 May 22:32
Compare
Choose a tag to compare

Initial release for Hub integration.