mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-05-03 10:00:07 -04:00
fractionalIndex as a byproduct or zIndex
This commit is contained in:
parent
c7ee46e7f8
commit
02dc00a47e
7 changed files with 128 additions and 24 deletions
|
@ -55,6 +55,7 @@ export type ElementConstructorOpts = MarkOptional<
|
|||
| "angle"
|
||||
| "groupIds"
|
||||
| "frameId"
|
||||
| "fractionalIndex"
|
||||
| "boundElements"
|
||||
| "seed"
|
||||
| "version"
|
||||
|
@ -88,6 +89,8 @@ const _newElementBase = <T extends ExcalidrawElement>(
|
|||
angle = 0,
|
||||
groupIds = [],
|
||||
frameId = null,
|
||||
// TODO: think about this more
|
||||
fractionalIndex = Infinity,
|
||||
roundness = null,
|
||||
boundElements = null,
|
||||
link = null,
|
||||
|
@ -113,6 +116,7 @@ const _newElementBase = <T extends ExcalidrawElement>(
|
|||
opacity,
|
||||
groupIds,
|
||||
frameId,
|
||||
fractionalIndex,
|
||||
roundness,
|
||||
seed: rest.seed ?? randomInteger(),
|
||||
version: rest.version || 1,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue