All Projects → praxisnetau → silverware-calendar

praxisnetau / silverware-calendar

Licence: BSD-3-Clause license
SilverWare Calendar Module

Programming Languages

CSS
56736 projects
javascript
184084 projects - #8 most used programming language
PHP
23972 projects - #3 most used programming language
scheme
763 projects

Projects that are alternatives of or similar to silverware-calendar

popoPicker
popoPicker是一个移动端3D滚轮日期时间和单项的选择器,支持无限循环滚动,不依赖第三方库
Stars: ✭ 26 (+73.33%)
Mutual labels:  time, date, timepicker, datepicker
Vue Datetime
Mobile friendly datetime picker for Vue. Supports date and datetime modes, i18n and more.
Stars: ✭ 928 (+6086.67%)
Mutual labels:  time, date, timepicker, datepicker
nativescript-datetimepicker
Plugin with date and time picking fields
Stars: ✭ 26 (+73.33%)
Mutual labels:  time, date, timepicker, datepicker
Vue Ctk Date Time Picker
VueJS component to select dates & time, including a range mode
Stars: ✭ 707 (+4613.33%)
Mutual labels:  time, date, timepicker, datepicker
Angular Moment Picker
Angular Moment Picker is an AngularJS directive for date and time picker using Moment.js.
Stars: ✭ 536 (+3473.33%)
Mutual labels:  time, date, timepicker, datepicker
react-picky-date-time
A react component for date time picker. Online demo examples
Stars: ✭ 41 (+173.33%)
Mutual labels:  time, date, datepicker
Persianrangedatepicker
Persian range date picker for android.
Stars: ✭ 48 (+220%)
Mutual labels:  date, timepicker, datepicker
Flatpickr
lightweight, powerful javascript datetimepicker with no dependencies
Stars: ✭ 14,575 (+97066.67%)
Mutual labels:  date, timepicker, datepicker
Zebra datepicker
A super-lightweight, highly configurable, cross-browser date / time picker jQuery plugin
Stars: ✭ 367 (+2346.67%)
Mutual labels:  date, timepicker, datepicker
vue-timeselector
🕒 Simply customizable powerful time picker for Vue.js
Stars: ✭ 41 (+173.33%)
Mutual labels:  time, date, timepicker
react-calendar-datetime-picker
A simple and fast date and time picker component for React
Stars: ✭ 58 (+286.67%)
Mutual labels:  date, timepicker, datepicker
React Picky Date Time
A react component for date time picker. Online demo examples
Stars: ✭ 31 (+106.67%)
Mutual labels:  time, date, datepicker
Laydate
layDate(日期与时间组件) 是 layui 独立维护的三大组件之一
Stars: ✭ 1,066 (+7006.67%)
Mutual labels:  time, date, datepicker
Brpickerview
BRPickerView 封装的是iOS中常用的选择器组件,主要包括:日期选择器(支持年月日、年月等15种日期样式选择,支持设置星期、至今等)、地址选择器(支持省市区、省市、省三种地区选择)、自定义字符串选择器(支持单列、多列、二级联动、三级联动选择)。支持自定义主题样式,适配深色模式,支持将选择器组件添加到指定容器视图。
Stars: ✭ 2,149 (+14226.67%)
Mutual labels:  time, date, datepicker
vue3-date-time-picker
Datepicker component for Vue 3
Stars: ✭ 157 (+946.67%)
Mutual labels:  timepicker, datepicker
silverstripe-mandrill
Mandrill integration for Silverstripe
Stars: ✭ 17 (+13.33%)
Mutual labels:  silverstripe, silverstripe-4
FM-JSON-Types
FileMaker Data Types in JSON
Stars: ✭ 14 (-6.67%)
Mutual labels:  time, date
duration
Parse iso8601 duration strings, and use to shift dates/times.
Stars: ✭ 51 (+240%)
Mutual labels:  time, date
ngx-mat-timepicker
A true material timepicker
Stars: ✭ 45 (+200%)
Mutual labels:  time, timepicker
date-extractor
Extract dates from text
Stars: ✭ 58 (+286.67%)
Mutual labels:  time, date

SilverWare Calendar Module

Latest Stable Version Latest Unstable Version License

A date and time picker module for SilverStripe v4 which adds flatpickr to standard SilverStripe DateField, DatetimeField and TimeField instances.

Datepicker

Contents

Requirements

Installation

Installation is via Composer:

$ composer require silverware/calendar

Note: forms on the website will automatically make use of the datepicker if the app is using 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

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

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

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

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

Out of the box, the module will automatically add a 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, 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.

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

Please use the GitHub issue tracker for bug reports and feature requests.

Contribution

Your contributions are gladly welcomed to help make this project better. Please see contributing for more information.

Attribution

Maintainers

Colin Tucker Praxis Interactive
Colin Tucker Praxis Interactive

License

BSD-3-Clause © Praxis Interactive

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].