BlockSuite API Documentation / @blocksuite/inline / AttributeService
Class: AttributeService<TextAttributes>
Type parameters
• TextAttributes extends BaseTextAttributes
Constructors
new AttributeService(editor)
new AttributeService<
TextAttributes>(editor):AttributeService<TextAttributes>
Parameters
• editor: InlineEditor<TextAttributes>
Returns
AttributeService<TextAttributes>
Source
packages/framework/inline/src/services/attribute.ts:21
Properties
_attributeRenderer
private_attributeRenderer:AttributeRenderer<TextAttributes>
Source
packages/framework/inline/src/services/attribute.ts:15
_attributeSchema
private_attributeSchema:ZodType<TextAttributes,ZodTypeDef,unknown>
Source
packages/framework/inline/src/services/attribute.ts:18
_marks
private_marks:null|TextAttributes=null
Source
packages/framework/inline/src/services/attribute.ts:13
editor
readonlyeditor:InlineEditor<TextAttributes>
Source
packages/framework/inline/src/services/attribute.ts:21
Accessors
attributeRenderer
getattributeRenderer():AttributeRenderer<TextAttributes>
Returns
AttributeRenderer<TextAttributes>
Source
packages/framework/inline/src/services/attribute.ts:27
marks
getmarks():null|TextAttributes
Returns
null | TextAttributes
Source
packages/framework/inline/src/services/attribute.ts:23
Methods
getFormat()
getFormat(
inlineRange,loose):TextAttributes
Parameters
• inlineRange: InlineRange
• loose: boolean= false
Returns
TextAttributes
Source
packages/framework/inline/src/services/attribute.ts:49
normalizeAttributes()
normalizeAttributes(
textAttributes?):undefined|TextAttributes
Parameters
• textAttributes?: TextAttributes
Returns
undefined | TextAttributes
Source
packages/framework/inline/src/services/attribute.ts:89
resetMarks()
resetMarks():
void
Returns
void
Source
packages/framework/inline/src/services/attribute.ts:35
setAttributeRenderer()
setAttributeRenderer(
renderer):void
Parameters
• renderer: AttributeRenderer<TextAttributes>
Returns
void
Source
packages/framework/inline/src/services/attribute.ts:45
setAttributeSchema()
setAttributeSchema(
schema):void
Parameters
• schema: ZodType<TextAttributes, ZodTypeDef, unknown>
Returns
void
Source
packages/framework/inline/src/services/attribute.ts:39
setMarks()
setMarks(
marks):void
Parameters
• marks: TextAttributes
Returns
void
Source
packages/framework/inline/src/services/attribute.ts:31
Generated using TypeDoc and typedoc-plugin-markdown.