BlockSuite API Documentation / @blocksuite/blocks / EdgelessFrameManager
Class: EdgelessFrameManager
Extends
GfxExtension
Constructors
new EdgelessFrameManager()
new EdgelessFrameManager(
gfx
):EdgelessFrameManager
Parameters
• gfx: GfxController
Returns
Overrides
GfxExtension.constructor
Defined in
packages/blocks/src/root-block/edgeless/frame-manager.ts:146
Properties
gfx
protected
readonly
gfx:GfxController
Inherited from
GfxExtension.gfx
Defined in
packages/framework/block-std/dist/gfx/extension.d.ts:11
key
static
key:string
='frame-manager'
Overrides
GfxExtension.key
Defined in
packages/blocks/src/root-block/edgeless/frame-manager.ts:133
Accessors
frames
get
frames():FrameBlockModel
[]
Get all sorted frames
Returns
Defined in
packages/blocks/src/root-block/edgeless/frame-manager.ts:140
std
get
std():BlockStdScope
Returns
Inherited from
GfxExtension.std
Defined in
packages/framework/block-std/dist/gfx/extension.d.ts:13
Methods
addElementsToFrame()
addElementsToFrame(
frame
,elements
):void
Reset parent of elements to the frame
Parameters
• frame: FrameBlockModel
• elements: GfxModel
[]
Returns
void
Defined in
packages/blocks/src/root-block/edgeless/frame-manager.ts:237
createFrameOnBound()
createFrameOnBound(
bound
):FrameBlockModel
Parameters
• bound: Bound
Returns
Defined in
packages/blocks/src/root-block/edgeless/frame-manager.ts:251
createFrameOnElements()
createFrameOnElements(
elements
):FrameBlockModel
Parameters
• elements: GfxModel
[]
Returns
Defined in
packages/blocks/src/root-block/edgeless/frame-manager.ts:269
createFrameOnSelected()
createFrameOnSelected():
FrameBlockModel
Returns
Defined in
packages/blocks/src/root-block/edgeless/frame-manager.ts:295
createFrameOnViewportCenter()
createFrameOnViewportCenter(
wh
):void
Parameters
• wh: [number
, number
]
Returns
void
Defined in
packages/blocks/src/root-block/edgeless/frame-manager.ts:299
getChildElementsInFrame()
getChildElementsInFrame(
frame
):GfxModel
[]
Get all elements in the frame, there are three cases:
- The frame doesn't have
childElements
, return all elements in the frame bound but not owned by another frame. - Return all child elements of the frame if
childElements
exists.
Parameters
• frame: FrameBlockModel
Returns
GfxModel
[]
Defined in
packages/blocks/src/root-block/edgeless/frame-manager.ts:316
getElementsInFrameBound()
getElementsInFrameBound(
frame
,fullyContained
):GfxModel
[]
Get all elements in the frame bound, whatever the element already has another parent frame or not.
Parameters
• frame: FrameBlockModel
• fullyContained: boolean
= true
Returns
GfxModel
[]
Defined in
packages/blocks/src/root-block/edgeless/frame-manager.ts:334
getFrameFromPoint()
getFrameFromPoint(
__namedParameters
,ignoreFrames
):null
|FrameBlockModel
Get most top frame from the point.
Parameters
• __namedParameters: IVec
• ignoreFrames: FrameBlockModel
[] = []
Returns
null
| FrameBlockModel
Defined in
packages/blocks/src/root-block/edgeless/frame-manager.ts:346
getParentFrame()
getParentFrame(
element
):null
|FrameBlockModel
Parameters
• element: GfxModel
Returns
null
| FrameBlockModel
Defined in
packages/blocks/src/root-block/edgeless/frame-manager.ts:356
mounted()
mounted():
void
Returns
void
Inherited from
GfxExtension.mounted
Defined in
packages/framework/block-std/dist/gfx/extension.d.ts:17
removeAllChildrenFromFrame()
removeAllChildrenFromFrame(
frame
):void
Parameters
• frame: FrameBlockModel
Returns
void
Defined in
packages/blocks/src/root-block/edgeless/frame-manager.ts:361
removeFromParentFrame()
removeFromParentFrame(
element
):void
Parameters
• element: GfxModel
Returns
void
Defined in
packages/blocks/src/root-block/edgeless/frame-manager.ts:367
unmounted()
unmounted():
void
Returns
void
Overrides
GfxExtension.unmounted
Defined in
packages/blocks/src/root-block/edgeless/frame-manager.ts:373
extendGfx()
static
extendGfx(_
):void
Parameters
• _: GfxController
Returns
void
Inherited from
GfxExtension.extendGfx
Defined in
packages/framework/block-std/dist/gfx/extension.d.ts:15
setup()
static
setup(di
):void
Parameters
• di: Container
Returns
void
Inherited from
GfxExtension.setup
Defined in
packages/framework/block-std/dist/gfx/extension.d.ts:16