Skip to content
Open
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
29 changes: 28 additions & 1 deletion Flutter/calendar/resource-view.md
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,33 @@ Widget build(BuildContext context) {

![Visible resource count](images/resourceview/visible_resource_count.png)

## Height and Width
You can customize the size of the resource view using the `height` and `width` properties of [ResourceViewSettings](https://pub.dev/documentation/syncfusion_flutter_calendar/latest/calendar/ResourceViewSettings-class.html) in the [SfCalendar](https://pub.dev/documentation/syncfusion_flutter_calendar/latest/calendar/SfCalendar-class.html).
- height controls the height of each resource.
- width controls the width of the resource panel.

{% tabs %}
{% highlight dart hl_lines="8" %}

@override
Widget build(BuildContext context) {
return MaterialApp(
home: Scaffold(
body: SfCalendar(
dataSource: _dataSource,
resourceViewSettings: ResourceViewSettings(
height: 120,
width: 150,
),
)),
);
}

{% endhighlight %}
{% endtabs %}

> When [size] is specified along with [height] or [width], [size] takes precedence. If neither [height] nor [width] is specified, [size] is used by default.

## Customization
### Show avatar
You can disable the user profile image and the circle representation of the resource by setting `false` to the [showAvatar](https://pub.dev/documentation/syncfusion_flutter_calendar/latest/calendar/ResourceViewSettings/showAvatar.html) property available in the [ResourceViewSettings](https://pub.dev/documentation/syncfusion_flutter_calendar/latest/calendar/ResourceViewSettings-class.html). This will display each resource with a resource name and the color assigned to the resource.
Expand Down Expand Up @@ -203,4 +230,4 @@ Widget build(BuildContext context) {

* [How to add appointment for the selected resources using appointment editor in Flutter event calendar (SfCalendar)?](https://support.syncfusion.com/kb/article/10550)
* [How to add resources in the Flutter event calendar (SfCalendar)](https://support.syncfusion.com/kb/article/10393/how-to-add-resources-in-the-flutter-calendar)
* [How to customize the resource view in the Flutter event calendar (SfCalendar)](https://support.syncfusion.com/kb/article/10738/how-to-customize-the-resource-view-in-the-flutter-calendar)
* [How to customize the resource view in the Flutter event calendar (SfCalendar)](https://support.syncfusion.com/kb/article/10738/how-to-customize-the-resource-view-in-the-flutter-calendar)