Skip to content

957023: Added Missing topics in blazor UG documentation #5943

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 3 commits into
base: hotfix/hotfix-v29.1.33
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions blazor/document-editor/how-to/customize-color-picker.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,3 +37,6 @@ The following table illustrates all the possible properties for the color picker
| Mode | It is used to render the ColorPicker with the specified mode. Defaults to ‘Picker’ |
| ModeSwitcher | It is used to show / hide the mode switcher button of ColorPicker component. Defaults to true |
| ShowButtons | It is used to show / hide the control buttons (apply / cancel) of ColorPicker component. Defaults to true |


>**Note**: According to the Word document specifications, it is not possible to modify the **`Predefined Highlight colors`**. This limitation means that the range of highlight colors provided by default cannot be customized or expanded upon by the user to suit individual preferences. Consequently, users must work within the confines of the existing color palette, as no functionality currently exists to modify or personalize these predefined highlighting options.
19 changes: 14 additions & 5 deletions blazor/document-editor/how-to/get-current-word.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,9 @@ You can get the current word or paragraph content from the Blazor Document Edito

## Select and get the word in current cursor position

You can use [`SelectCurrentWordAsync`](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.DocumentEditor.SelectionModule.html#Syncfusion_Blazor_DocumentEditor_SelectionModule_SelectCurrentWordAsync_System_Boolean_) API in selection module to select the current word at cursor position and use [`GetTextAsync`](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.DocumentEditor.SelectionModule.html#Syncfusion_Blazor_DocumentEditor_SelectionModule_GetTextAsync) API to get the selected content as plain text from Blazor Document Editor component.
You can use [`SelectCurrentWordAsync`](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.DocumentEditor.SelectionModule.html#Syncfusion_Blazor_DocumentEditor_SelectionModule_SelectCurrentWordAsync_System_Boolean_) API in selection module to select the current word at cursor position.
* use [`GetTextAsync`](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.DocumentEditor.SelectionModule.html#Syncfusion_Blazor_DocumentEditor_SelectionModule_GetTextAsync) API to get the selected content as **plain text** from Blazor Document Editor component.
* use [`GetSfdtAsync`](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.DocumentEditor.SelectionModule.html#Syncfusion_Blazor_DocumentEditor_SelectionModule_GetSfdtAsync) API to get the selected content as **SFDT text** from Blazor Document Editor component.

The following example code illustrates how to select and get the current word as plain text.

Expand All @@ -34,7 +36,9 @@ The following example code illustrates how to select and get the current word as
// To select the current word in document
await container.DocumentEditor.Selection.SelectCurrentWordAsync();
// To get the selected content as text
string selectedContent = await container.DocumentEditor.Selection.GetTextAsync();
string selectedContentText = await container.DocumentEditor.Selection.GetTextAsync();
// To get the selected content as SFDT (rich text)
string selectedContentSFDT = await container.DocumentEditor.Selection.GetSfdtAsync();
}
}
```
Expand All @@ -43,7 +47,10 @@ To get the bookmark content as SFDT (rich text), check this [`link`](../../docum

## Select and get the paragraph in current cursor position

You can use [`SelectParagraphAsync`](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.DocumentEditor.SelectionModule.html#Syncfusion_Blazor_DocumentEditor_SelectionModule_SelectParagraphAsync) API in selection module to select the current paragraph at cursor position and use [`GetTextAsync`](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.DocumentEditor.SelectionModule.html#Syncfusion_Blazor_DocumentEditor_SelectionModule_GetTextAsync) API or [`GetSfdtAsync`](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.DocumentEditor.SelectionModule.html#Syncfusion_Blazor_DocumentEditor_SelectionModule_GetSfdtAsync) API to get the selected content as plain text or SFDT from Blazor Document Editor component.
You can use [`SelectParagraphAsync`](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.DocumentEditor.SelectionModule.html#Syncfusion_Blazor_DocumentEditor_SelectionModule_SelectParagraphAsync) API in selection module to select the current paragraph at cursor position.

* use [`GetTextAsync`](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.DocumentEditor.SelectionModule.html#Syncfusion_Blazor_DocumentEditor_SelectionModule_GetTextAsync) API to get the selected content as **plain text** from Blazor Document Editor component.
* use [`GetSfdtAsync`](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.DocumentEditor.SelectionModule.html#Syncfusion_Blazor_DocumentEditor_SelectionModule_GetSfdtAsync) API to get the selected content as **SFDT text** from Blazor Document Editor component.

The following example code illustrates how to select and get the current paragraph as SFDT.

Expand All @@ -63,8 +70,10 @@ The following example code illustrates how to select and get the current paragra
await container.DocumentEditor.Editor.InsertTextAsync("Document editor");
// To select the current paragraph in document
await container.DocumentEditor.Selection.SelectParagraphAsync();
// To get the selected content as SFDT
string selectedContent = await container.DocumentEditor.Selection.GetSfdtAsync();
// To get the selected content as text
string selectedContentText = await container.DocumentEditor.Selection.GetTextAsync();
// To get the selected content as SFDT (rich text)
string selectedContentSFDT = await container.DocumentEditor.Selection.GetSfdtAsync();
}
}
```
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added blazor/document-editor/images/Row_Limit_Alert.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
46 changes: 45 additions & 1 deletion blazor/document-editor/table.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,51 @@ Refer to the following sample code.
await documentEditor.Editor.InsertTableAsync(3, 3);
```

The maximum size of row and column is limited to 32767 and 63 respectively.
## Set the maximum number of rows when inserting a table

You can use the [maximumRows](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.DocumentEditor.DocumentEditorSettingsModel.html#Syncfusion_Blazor_DocumentEditor_DocumentEditorSettingsModel_MaximumRows) property to set the maximum number of rows allowed while inserting a table in the Document Editor component.


Refer to the following sample code.

```csharp
<SfDocumentEditorContainer @ref="container" EnableSpellCheck="true" EnableToolbar=true DocumentEditorSettings="settings" >
</SfDocumentEditorContainer>

@code {
SfDocumentEditorContainer container;
DocumentEditorSettingsModel settings = new DocumentEditorSettingsModel() { MaximumRows = 4 };
};
```

When the maximum row limit is reached, an alert will appear, as follow

![Row Limit Alert](images/Row_Limit_Alert.PNG)

>Note: The maximum value of Row is 32767, as per Microsoft Word application and you can set any value less than or equal to 32767 to this property.
## Set the maximum number of Columns when inserting a table


You can use the [maximumColumns](https://help.syncfusion.com/cr/blazor/Syncfusion.Blazor.DocumentEditor.DocumentEditorSettingsModel.html#Syncfusion_Blazor_DocumentEditor_DocumentEditorSettingsModel_MaximumColumns) property to set the maximum number of columns allowed while inserting a table in the Document Editor component.


Refer to the following sample code.

```csharp
<SfDocumentEditorContainer @ref="container" EnableSpellCheck="true" EnableToolbar=true DocumentEditorSettings="settings" >
</SfDocumentEditorContainer>

@code {
SfDocumentEditorContainer container;
DocumentEditorSettingsModel settings = new DocumentEditorSettingsModel() { MaximumColumns = 4 };
};
```

When the maximum column limit is reached, an alert will appear, as follow

![Column Limit Alert](images/Column_Limit_Alert.PNG)

>Note: The maximum value of Column is 63, as per Microsoft Word application and you can set any value less than or equal to 63 to this property.

## Insert rows

Expand Down