@univerjs/core v0.4.2 • Docs
Class: Styles
Styles in a workbook, cells locate styles based on style IDs
Constructors
new Styles()
new Styles(styles): Styles
Parameters
Parameter | Type |
---|---|
styles | IKeyType <Nullable <IStyleData >> |
Returns
Defined in
submodules/univer/packages/core/src/sheets/styles.ts:31 (opens in a new tab)
Methods
add()
add(data, styleObject): string
Parameters
Parameter | Type |
---|---|
data | IStyleData |
styleObject | string |
Returns
string
Defined in
submodules/univer/packages/core/src/sheets/styles.ts:70 (opens in a new tab)
each()
each(callback): Styles
Parameters
Parameter | Type |
---|---|
callback | (value , index , array ) => void |
Returns
Defined in
submodules/univer/packages/core/src/sheets/styles.ts:37 (opens in a new tab)
get()
get(id): Nullable<IStyleData>
Parameters
Parameter | Type |
---|---|
id | string | Nullable <IStyleData > |
Returns
Defined in
submodules/univer/packages/core/src/sheets/styles.ts:63 (opens in a new tab)
getStyleByCell()
getStyleByCell(cell): Nullable<IStyleData>
Parameters
Parameter | Type |
---|---|
cell | Nullable <ICellDataForSheetInterceptor > |
Returns
Defined in
submodules/univer/packages/core/src/sheets/styles.ts:93 (opens in a new tab)
search()
search(data, styleObject): string
Parameters
Parameter | Type |
---|---|
data | IStyleData |
styleObject | string |
Returns
string
Defined in
submodules/univer/packages/core/src/sheets/styles.ts:48 (opens in a new tab)
setValue()
setValue(data): Nullable<string>
Parameters
Parameter | Type |
---|---|
data | Nullable <IStyleData > |
Returns
Nullable
<string
>
Defined in
submodules/univer/packages/core/src/sheets/styles.ts:79 (opens in a new tab)
toJSON()
toJSON(): IKeyType<Nullable<IStyleData>>
Returns
IKeyType
<Nullable
<IStyleData
>>
Defined in
submodules/univer/packages/core/src/sheets/styles.ts:89 (opens in a new tab)