> For the complete documentation index, see [llms.txt](https://docs.avonnicomponents.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.avonnicomponents.com/flow/tutorials/components/calendar/how-to-customize-time-spans.md). Agents can also search and read this documentation through its [MCP server](https://docs.avonnicomponents.com/~gitbook/mcp).

# Customize the time spans

Add your own views to the Avonni Calendar, such as 3 days or 2 weeks, so a dispatcher sees exactly the stretch of time they plan each week.

A dispatcher planning field visits rarely needs a whole month, and a single day hides the rest of the week. Time spans are the views the user picks from the calendar icon in the toolbar: Day, Week and Month by default. You can add your own, for example a "3 days" view that shows the next three days for every technician.

<figure><img src="https://27923732-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F1FUd4apB9YHgCEMUFbVb%2Fuploads%2FTSeYXihLfe4DaZVRqQ6J%2Fcalendar-how-to-customize-time-spans-result.png?alt=media" alt="Avonni Calendar on a custom 3 days time span from Monday November 16 to Wednesday November 18, 2026, shown as a vertical timeline with one column per technician"><figcaption><p>A 3 days time span shows Monday to Wednesday for every technician.</p></figcaption></figure>

## Before you start

* A screen flow with an Avonni Calendar that already shows events. If you don't have one yet, follow [Calendar 101](https://docs.avonnicomponents.com/flow/tutorials/components/calendar/calendar-101-tutorial.md).
* All the settings below are in the **Properties** tab. The [Calendar reference](https://docs.avonnicomponents.com/flow/flow-components/calendar.md) lists the other ones.

## Steps

{% stepper %}
{% step %}

### Open the time spans

* In Flow Builder, open the Screen element and select the Avonni Calendar to open the Component Builder.
* In the **Properties** tab, click **Advanced Options** in the first group. The **Time spans** list appears below **Today Button Label**.
* The list holds **Day**, **Week** and **Month**. Click an item to edit it, or click **Add Time spans** to add a new one.

<figure><img src="https://27923732-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F1FUd4apB9YHgCEMUFbVb%2Fuploads%2F4mFFO6eiZIfzL2zlIOJA%2Fcalendar-how-to-customize-time-spans-panel.png?alt=media" alt="Calendar Properties tab, first group with Advanced Options open: Selected Time Span set to 3 days, and the Time spans list Day, 3 days and Week with an Add Time spans button"><figcaption></figcaption></figure>
{% endstep %}

{% step %}

### Name the view

* **Label**: the text the user picks in the calendar icon menu, for example `3 days`.
* **Name**: a unique name for the view. It fills itself from the label, so you can leave it.
* **Icon Name**: an optional icon shown with the label.
  {% endstep %}

{% step %}

### Set how much time it covers

* **Unit**: `Day`, `Week` or `Month`.
* **Span**: how many units the view shows. Day goes up to 7, Week up to 3, Month up to 12.
* Unit `Day` with Span `3` gives three days. Unit `Week` with Span `2` gives a fortnight.
  {% endstep %}

{% step %}

### Choose the timeline headers

* **Timeline headers** sets the rows of dates above the **Timeline** display. The other displays ignore it.
* The default, `Hour and Day`, suits a view of one to three days.
* For one to three weeks, `Day and Week` shows each day under its week.
* For several months, pick `Week and Month` or `Month and Year`.
  {% endstep %}

{% step %}

### Pick the view that opens first

* In the same group, above **Advanced Options**, **Selected Time Span** lists your time spans. Pick the one the user sees when the screen opens.
* Remove the views the team never uses, so the menu only offers the ones that matter.
  {% endstep %}

{% step %}

### Save and test

* Save the Component Builder, save the flow and run it in **Debug**.
* Click the calendar icon in the toolbar: your new label is listed under **Time Span**. Pick it: the calendar shows three days, with every technician's visits for those days.
  {% endstep %}
  {% endstepper %}

## Troubleshooting

<details>

<summary>The timeline headers did not change</summary>

**Timeline headers** only applies to the **Timeline** display. Check **Selected Display** in the first group of the **Properties** tab, or switch to Timeline from the calendar icon menu.

</details>

<details>

<summary>Event titles are cut to a few letters on a one-day timeline</summary>

Without working hours, a day view spreads 24 hours across the screen and each visit gets a sliver of width. Set **Time Frames** to the team's hours, as shown in [Block past dates and limit working hours](https://docs.avonnicomponents.com/flow/tutorials/components/calendar/block-past-dates-and-limit-working-hours.md).

</details>

## Related tutorials

* [Block past dates and limit working hours](https://docs.avonnicomponents.com/flow/tutorials/components/calendar/block-past-dates-and-limit-working-hours.md): hide weekends and the hours nobody works.
* [Filter and search a team calendar](https://docs.avonnicomponents.com/flow/tutorials/components/calendar/filter-and-search-a-team-calendar.md): narrow a long view down to one technician.
* [Calendar 101](https://docs.avonnicomponents.com/flow/tutorials/components/calendar/calendar-101-tutorial.md): build the calendar these views apply to.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.avonnicomponents.com/flow/tutorials/components/calendar/how-to-customize-time-spans.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
