PHPackages                             silverware/calendar - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. silverware/calendar

ActiveSilverstripe-vendormodule

silverware/calendar
===================

SilverWare Calendar Module.

1.1.0(7y ago)1644.2k↓50%9[18 PRs](https://github.com/praxisnetau/silverware-calendar/pulls)1BSD-3-ClauseCSSPHP &gt;=5.6.0

Since Sep 18Pushed 3y ago2 watchersCompare

[ Source](https://github.com/praxisnetau/silverware-calendar)[ Packagist](https://packagist.org/packages/silverware/calendar)[ Docs](https://github.com/praxisnetau/silverware-calendar)[ RSS](/packages/silverware-calendar/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (4)Dependencies (1)Versions (23)Used By (1)

SilverWare Calendar Module
==========================

[](#silverware-calendar-module)

[![Latest Stable Version](https://camo.githubusercontent.com/9593e2b97c93f311420846d594b783e50be09057eaa24717609d87e1d96c5e8b/68747470733a2f2f706f7365722e707567782e6f72672f73696c766572776172652f63616c656e6461722f762f737461626c65)](https://packagist.org/packages/silverware/calendar)[![Latest Unstable Version](https://camo.githubusercontent.com/7d407804cf4bf8fe7c78c1c7576f82ebd8379d744bb57f94d09a9e2c95028e22/68747470733a2f2f706f7365722e707567782e6f72672f73696c766572776172652f63616c656e6461722f762f756e737461626c65)](https://packagist.org/packages/silverware/calendar)[![License](https://camo.githubusercontent.com/3d37de5faefc045bdd838ec0220cb32a37ea9412d10a63d8f4f6975a5ac9a02c/68747470733a2f2f706f7365722e707567782e6f72672f73696c766572776172652f63616c656e6461722f6c6963656e7365)](https://packagist.org/packages/silverware/calendar)

A date and time picker module for [SilverStripe v4](https://github.com/silverstripe/silverstripe-framework) which adds [flatpickr](https://github.com/chmln/flatpickr) to standard SilverStripe `DateField`, `DatetimeField` and `TimeField` instances.

[![Datepicker](https://camo.githubusercontent.com/b42bd32087d4084d72c6f05f4025e83c10e2e7c8bdb1a72885876c5de80e526a/68747470733a2f2f692e696d6775722e636f6d2f666f6458366b742e706e67)](https://camo.githubusercontent.com/b42bd32087d4084d72c6f05f4025e83c10e2e7c8bdb1a72885876c5de80e526a/68747470733a2f2f692e696d6775722e636f6d2f666f6458366b742e706e67)

Contents
--------

[](#contents)

- [Requirements](#requirements)
- [Installation](#installation)
- [Configuration](#configuration)
- [Usage](#usage)
- [Issues](#issues)
- [Contribution](#contribution)
- [Attribution](#attribution)
- [Maintainers](#maintainers)
- [License](#license)

Requirements
------------

[](#requirements)

- [SilverStripe Framework v4](https://github.com/silverstripe/silverstripe-framework)

Installation
------------

[](#installation)

Installation is via [Composer](https://getcomposer.org):

```
$ composer require silverware/calendar

```

**Note:** forms on the website will automatically make use of the datepicker if the app is using [SilverWare](https://github.com/praxisnetau/silverware). If you are using a vanilla SilverStripe project, you'll need to load the module script and styles in your app bundle (jQuery is required):

- `silverware/calendar: client/dist/js/bundle.js`
- `silverware/calendar: client/dist/styles/bundle.css`

Configuration
-------------

[](#configuration)

As with all SilverStripe modules, configuration is via YAML. Extensions to `LeftAndMain` and `ContentController` are applied via `config.yml`.

### Highlight Color

[](#highlight-color)

The module supports a custom highlight color for both the CMS and forms on the website. To define the highlight color, use the following YAML configuration:

```
# Custom highlight color for CMS:

SilverStripe\Admin\LeftAndMain:
  calendar_highlight_color: '#abc'

# Custom highlight color for website forms:

SilverStripe\CMS\Controllers\ContentController:
  calendar_highlight_color: '#cba'
```

### Datepicker Class

[](#datepicker-class)

SilverStripe will not apply it's own JavaScript to form fields which have a certain datepicker class. To prevent conflicts, use the following configuration to define the class which SilverStripe will detect:

```
SilverStripe\Forms\FormField:
  calendar_datepicker_class: 'hasDatepicker'
```

### Disabling via Configuration

[](#disabling-via-configuration)

If you need to disable the datepicker for all instances of a certain form field, use the following configuration:

```
# Disable for all date fields:

SilverStripe\Forms\DateField:
  calendar_disabled: true
```

Usage
-----

[](#usage)

Out of the box, the module will automatically add a [flatpickr](https://github.com/chmln/flatpickr) to all `DateField`, `DatetimeField` and `TimeField` instances. Each field will be configured automatically with default settings for each use case.

If you need to apply additional options supported by [flatpickr](https://github.com/chmln/flatpickr), you can do so by using the `setCalendarConfig()` method:

```
use SilverStripe\Forms\DateField;

$field = DateField::create('Date', 'Date');

$field->setCalendarConfig([
  'minDate' => date('Y-m-d'),
  'shorthandCurrentMonth' => true
]);
```

In addition to accepting an array, the `setCalendarConfig()` method also supports the setting of individual config settings:

```
$field->setCalendarConfig('weekNumbers', true);
```

To see a full list of the supported options, please refer to the [flatpickr documentation](https://chmln.github.io/flatpickr/options).

### Disabling by Instance

[](#disabling-by-instance)

If you need to disable the datepicker for a particular field instance, as opposed to all instances, you may call the `setCalendarDisabled()` method on the field:

```
$field->setCalendarDisabled(true);
```

Issues
------

[](#issues)

Please use the [GitHub issue tracker](https://github.com/praxisnetau/silverware-calendar/issues) for bug reports and feature requests.

Contribution
------------

[](#contribution)

Your contributions are gladly welcomed to help make this project better. Please see [contributing](CONTRIBUTING.md) for more information.

Attribution
-----------

[](#attribution)

- Makes use of [flatpickr](https://github.com/chmln/flatpickr) by [Gregory Petrosyan](https://github.com/chmln) and [others](https://github.com/chmln/flatpickr/graphs/contributors).

Maintainers
-----------

[](#maintainers)

[![Colin Tucker](https://avatars3.githubusercontent.com/u/1853705?s=144)](https://github.com/colintucker)[![Praxis Interactive](https://avatars2.githubusercontent.com/u/1782612?s=144)](http://www.praxis.net.au)[Colin Tucker](https://github.com/colintucker)[Praxis Interactive](http://www.praxis.net.au)License
-------

[](#license)

[BSD-3-Clause](LICENSE.md) © Praxis Interactive

###  Health Score

38

—

LowBetter than 85% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity36

Limited adoption so far

Community14

Small or concentrated contributor base

Maturity68

Established project with proven stability

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~44 days

Recently: every ~61 days

Total

7

Last Release

2898d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/f5d47a59cd183aa3f599c2b66dfce7c79c249c2eacb749f0ac8c38c4ca273d14?d=identicon)[PraxisNetAu](/maintainers/PraxisNetAu)

---

Top Contributors

[![colintucker](https://avatars.githubusercontent.com/u/1853705?v=4)](https://github.com/colintucker "colintucker (13 commits)")

---

Tags

calendardatedatepickersilverstripesilverstripe-4timetimepickersilverstripetimedatecalendartimepickerdatepickersilverware

### Embed Badge

![Health badge](/badges/silverware-calendar/health.svg)

```
[![Health](https://phpackages.com/badges/silverware-calendar/health.svg)](https://phpackages.com/packages/silverware-calendar)
```

###  Alternatives

[azuyalabs/yasumi

The easy PHP Library for calculating holidays

1.1k11.4M26](/packages/azuyalabs-yasumi)[league/period

Time range API for PHP

7335.4M21](/packages/league-period)[aeon-php/calendar

PHP type safe, immutable calendar library

2079.7M16](/packages/aeon-php-calendar)[punic/punic

PHP-Unicode CLDR

1542.9M29](/packages/punic-punic)[umulmrum/holiday

A PHP library to compute holidays. It's something :-)

92342.6k1](/packages/umulmrum-holiday)[benhall14/php-calendar

A simple PHP class to generate calendars.

9822.6k](/packages/benhall14-php-calendar)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
