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:149
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:136
Accessors
frames
get
frames():FrameBlockModel
[]
Get all sorted frames
Returns
Defined in
packages/blocks/src/root-block/edgeless/frame-manager.ts:143
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:250
createFrameOnBound()
createFrameOnBound(
bound
):FrameBlockModel
Parameters
• bound: Bound
Returns
Defined in
packages/blocks/src/root-block/edgeless/frame-manager.ts:264
createFrameOnElements()
createFrameOnElements(
elements
):FrameBlockModel
Parameters
• elements: GfxModel
[]
Returns
Defined in
packages/blocks/src/root-block/edgeless/frame-manager.ts:282
createFrameOnSelected()
createFrameOnSelected():
FrameBlockModel
Returns
Defined in
packages/blocks/src/root-block/edgeless/frame-manager.ts:308
createFrameOnViewportCenter()
createFrameOnViewportCenter(
wh
):void
Parameters
• wh: [number
, number
]
Returns
void
Defined in
packages/blocks/src/root-block/edgeless/frame-manager.ts:312
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:329
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:347
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:359
getParentFrame()
getParentFrame(
element
):null
|FrameBlockModel
Parameters
• element: GfxModel
Returns
null
| FrameBlockModel
Defined in
packages/blocks/src/root-block/edgeless/frame-manager.ts:369
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:374
removeFromParentFrame()
removeFromParentFrame(
element
):void
Parameters
• element: GfxModel
Returns
void
Defined in
packages/blocks/src/root-block/edgeless/frame-manager.ts:380
unmounted()
unmounted():
void
Returns
void
Overrides
GfxExtension.unmounted
Defined in
packages/blocks/src/root-block/edgeless/frame-manager.ts:386
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