* feat: support segment midpoints in line editor
* fix tests
* midpoints working in bezier curve
* midpoint working with non zero roughness
* calculate beizer curve control points for points >2
* unnecessary rerender
* don't show phantom points inside editor for short segments
* don't show phantom points for small curves
* improve the algo for plotting midpoints on bezier curve by taking arc lengths and doing binary search
* fix tests finally
* fix naming
* cache editor midpoints
* clear midpoint cache when undo
* fix caching
* calculate index properly when not all segments have midpoints
* make sure correct element version is fetched from cache
* chore
* fix
* direct comparison for equal points
* create arePointsEqual util
* upate name
* don't update cache except inside getter
* don't compute midpoints outside editor unless 2pointer lines
* update cache to object and burst when Zoom updated as well
* early return if midpoints not present outside editor
* don't early return
* cleanup
* Add specs
* fix
* chore: Dedupe package dependencies and webpack configs.
* Fully dedupe `src/packages` via symlinks
* Merge https://github.com/excalidraw/excalidraw into dedupe-package-deps-configs
* fix: Link `tsc` so `build:example` works in @excalidraw/excalidraw
* @excalidraw/plugins: Revert the `yarn.lock` deduping.
* Drop yarn commands from the root `package.json`.
* Remove more unneeded `package.json` additions.
* One more change to drop in `package.json` files.
* Deduping: Move even more into common webpack configs.
* renaming
Co-authored-by: Aakansha Doshi <aakansha1216@gmail.com>
* feat: Introduce ExcalidrawData provider so that app state and elements need not be passed to children
* fix
* fix zen mode
* Separate providers for data and elements
* pass appState and elements to layerUI
* pass appState and elements to selectedShapeActions
* pass appState and elements to MobileMenu
* pass appState to librarymenu
* rename
* rename to ExcalidrawAppState
* feat: enable midpoint inside linear element editor
* fix
* fix
* hack to set pointerDownState.hit.hasHitElementInside when mid point added
* remove hacks as not needed :)
* remove newline
* fix
* add doc
* feat: Add a mid point for linear elements
* fix tests
* show mid point only on hover
* hacky fix :(
* don't add mid points if present and only add outside editor
* improve styling and always show phantom point instead of just on hover
* fix tests
* fix
* only add polyfill for test
* add hover state for phantom point
* fix tests
* fix
* Add Array.at polyfill
* reuse `centerPoint()` helper
* reuse `distance2d`
* use `Point` type
Co-authored-by: dwelle <luzar.david@gmail.com>