port calendar merge from hz

This commit is contained in:
zotlabs 2019-05-12 18:20:37 -07:00
parent 23e8c52bea
commit fe1517022c
149 changed files with 28385 additions and 260 deletions

View file

@ -66,7 +66,7 @@ class Apps {
'Channel Home',
'View Profile',
'Photos',
'Events',
'Calendar',
'Directory',
'Search',
'Profile Photo'
@ -303,6 +303,7 @@ class Apps {
'Affinity Tool' => t('Affinity Tool'),
'Articles' => t('Articles'),
'Cards' => t('Cards'),
'Calendar' => t('Calendar'),
'Categories' => t('Categories'),
'Admin' => t('Site Admin'),
'Content Filter' => t('Content Filter'),

View file

@ -85,7 +85,7 @@ class Libzotdir {
if ($directory) {
$j = Zotfinger::exec($directory);
if(array_path_exists('data/directory_mode',$j)) {
if (array_path_exists('data/directory_mode',$j)) {
if ($j['data']['directory_mode'] === 'normal') {
$isadir = false;
}
@ -240,7 +240,6 @@ class Libzotdir {
// for brand new directory servers, only load the last couple of days.
// It will take about a month for a new directory to obtain the full current repertoire of channels.
/** @FIXME Go back and pick up earlier ratings if this is a new directory server. These do not get refreshed. */
$token = get_config('system','realm_token');
@ -266,9 +265,10 @@ class Libzotdir {
$r = q("select * from updates where ud_guid = '%s' limit 1",
dbesc($t['transaction_id'])
);
if($r)
if ($r) {
continue;
}
$ud_flags = 0;
if (is_array($t['flags']) && in_array('deleted',$t['flags']))
$ud_flags |= UPDATE_FLAGS_DELETED;
@ -344,7 +344,7 @@ class Libzotdir {
logger('local_dir_update: uid: ' . $uid, LOGGER_DEBUG);
$p = q("select channel.channel_hash, channel_address, channel_timezone, profile.* from profile left join channel on channel_id = uid where uid = %d and is_default = 1",
$p = q("select channel_hash, channel_address, channel_timezone, profile.* from profile left join channel on channel_id = uid where uid = %d and is_default = 1",
intval($uid)
);
@ -384,7 +384,7 @@ class Libzotdir {
$hidden = (1 - intval($p[0]['publish']));
logger('hidden: ' . $hidden);
// logger('hidden: ' . $hidden);
$r = q("select xchan_hidden from xchan where xchan_hash = '%s' limit 1",
dbesc($p[0]['channel_hash'])
@ -554,10 +554,11 @@ class Libzotdir {
}
$d = [
'xprof' => $arr,
'xprof' => $arr,
'profile' => $profile,
'update' => $update
'update' => $update
];
/**
* @hooks import_directory_profile
* Called when processing delivery of a profile structure from an external source (usually for directory storage).
@ -565,11 +566,13 @@ class Libzotdir {
* * \e array \b profile
* * \e boolean \b update
*/
call_hooks('import_directory_profile', $d);
if (($d['update']) && (! $suppress_update))
self::update_modtime($arr['xprof_hash'],random_string() . '@' . \App::get_hostname(), $addr, $ud_flags);
if (($d['update']) && (! $suppress_update)) {
self::update_modtime($arr['xprof_hash'], new_uuid(), $addr, $ud_flags);
}
return $d['update'];
}

567
Zotlabs/Module/Calendar.php Normal file
View file

@ -0,0 +1,567 @@
<?php
namespace Zotlabs\Module;
use Zotlabs\Web\Controller;
require_once('include/conversation.php');
require_once('include/bbcode.php');
require_once('include/datetime.php');
require_once('include/event.php');
require_once('include/items.php');
require_once('include/html2plain.php');
class Calendar extends Controller {
function post() {
logger('post: ' . print_r($_REQUEST,true), LOGGER_DATA);
if(! local_channel())
return;
$event_id = ((x($_POST,'event_id')) ? intval($_POST['event_id']) : 0);
$event_hash = ((x($_POST,'event_hash')) ? $_POST['event_hash'] : '');
$xchan = ((x($_POST,'xchan')) ? dbesc($_POST['xchan']) : '');
$uid = local_channel();
$start_text = escape_tags($_REQUEST['dtstart']);
$finish_text = escape_tags($_REQUEST['dtend']);
$adjust = intval($_POST['adjust']);
$nofinish = intval($_POST['nofinish']);
$timezone = ((x($_POST,'timezone_select')) ? notags(trim($_POST['timezone_select'])) : '');
$tz = (($timezone) ? $timezone : date_default_timezone_get());
$categories = escape_tags(trim($_POST['categories']));
// only allow editing your own events.
if(($xchan) && ($xchan !== get_observer_hash()))
return;
if($start_text) {
$start = $start_text;
}
else {
$start = sprintf('%d-%d-%d %d:%d:0',$startyear,$startmonth,$startday,$starthour,$startminute);
}
if($finish_text) {
$finish = $finish_text;
}
else {
$finish = sprintf('%d-%d-%d %d:%d:0',$finishyear,$finishmonth,$finishday,$finishhour,$finishminute);
}
if($nofinish) {
$finish = NULL_DATE;
}
if($adjust) {
$start = datetime_convert($tz,'UTC',$start);
if(! $nofinish)
$finish = datetime_convert($tz,'UTC',$finish);
}
else {
$start = datetime_convert('UTC','UTC',$start);
if(! $nofinish)
$finish = datetime_convert('UTC','UTC',$finish);
}
// Don't allow the event to finish before it begins.
// It won't hurt anything, but somebody will file a bug report
// and we'll waste a bunch of time responding to it. Time that
// could've been spent doing something else.
$summary = escape_tags(trim($_POST['summary']));
$desc = escape_tags(trim($_POST['desc']));
$location = escape_tags(trim($_POST['location']));
$type = escape_tags(trim($_POST['type']));
require_once('include/text.php');
linkify_tags($desc, local_channel());
linkify_tags($location, local_channel());
if(strcmp($finish,$start) < 0 && !$nofinish) {
notice( t('Event can not end before it has started.') . EOL);
if(intval($_REQUEST['preview'])) {
echo( t('Unable to generate preview.'));
}
killme();
}
if((! $summary) || (! $start)) {
notice( t('Event title and start time are required.') . EOL);
if(intval($_REQUEST['preview'])) {
echo( t('Unable to generate preview.'));
}
killme();
}
$channel = \App::get_channel();
$acl = new \Zotlabs\Access\AccessList(false);
if($event_id) {
$x = q("select * from event where id = %d and uid = %d limit 1",
intval($event_id),
intval(local_channel())
);
if(! $x) {
notice( t('Event not found.') . EOL);
if(intval($_REQUEST['preview'])) {
echo( t('Unable to generate preview.'));
killme();
}
return;
}
$acl->set($x[0]);
$created = $x[0]['created'];
$edited = datetime_convert();
}
else {
$created = $edited = datetime_convert();
$acl->set_from_array($_POST);
}
$post_tags = array();
$channel = \App::get_channel();
$ac = $acl->get();
if(strlen($categories)) {
$cats = explode(',',$categories);
foreach($cats as $cat) {
$post_tags[] = array(
'uid' => $profile_uid,
'ttype' => TERM_CATEGORY,
'otype' => TERM_OBJ_POST,
'term' => trim($cat),
'url' => $channel['xchan_url'] . '?f=&cat=' . urlencode(trim($cat))
);
}
}
$datarray = array();
$datarray['dtstart'] = $start;
$datarray['dtend'] = $finish;
$datarray['summary'] = $summary;
$datarray['description'] = $desc;
$datarray['location'] = $location;
$datarray['etype'] = $type;
$datarray['adjust'] = $adjust;
$datarray['nofinish'] = $nofinish;
$datarray['uid'] = local_channel();
$datarray['account'] = get_account_id();
$datarray['event_xchan'] = $channel['channel_hash'];
$datarray['allow_cid'] = $ac['allow_cid'];
$datarray['allow_gid'] = $ac['allow_gid'];
$datarray['deny_cid'] = $ac['deny_cid'];
$datarray['deny_gid'] = $ac['deny_gid'];
$datarray['private'] = (($acl->is_private()) ? 1 : 0);
$datarray['id'] = $event_id;
$datarray['created'] = $created;
$datarray['edited'] = $edited;
if(intval($_REQUEST['preview'])) {
$html = format_event_html($datarray);
echo $html;
killme();
}
$event = event_store_event($datarray);
if($post_tags)
$datarray['term'] = $post_tags;
$item_id = event_store_item($datarray,$event);
if($item_id) {
$r = q("select * from item where id = %d",
intval($item_id)
);
if($r) {
xchan_query($r);
$sync_item = fetch_post_tags($r);
$z = q("select * from event where event_hash = '%s' and uid = %d limit 1",
dbesc($r[0]['resource_id']),
intval($channel['channel_id'])
);
if($z) {
build_sync_packet($channel['channel_id'],array('event_item' => array(encode_item($sync_item[0],true)),'event' => $z));
}
}
}
\Zotlabs\Daemon\Master::Summon(array('Notifier','event',$item_id));
killme();
}
function get() {
if(argc() > 2 && argv(1) == 'ical') {
$event_id = argv(2);
require_once('include/security.php');
$sql_extra = permissions_sql(local_channel());
$r = q("select * from event where event_hash = '%s' $sql_extra limit 1",
dbesc($event_id)
);
if($r) {
header('Content-type: text/calendar');
header('content-disposition: attachment; filename="' . t('event') . '-' . $event_id . '.ics"' );
echo ical_wrapper($r);
killme();
}
else {
notice( t('Event not found.') . EOL );
return;
}
}
if(! local_channel()) {
notice( t('Permission denied.') . EOL);
return;
}
if((argc() > 2) && (argv(1) === 'ignore') && intval(argv(2))) {
$r = q("update event set dismissed = 1 where id = %d and uid = %d",
intval(argv(2)),
intval(local_channel())
);
}
if((argc() > 2) && (argv(1) === 'unignore') && intval(argv(2))) {
$r = q("update event set dismissed = 0 where id = %d and uid = %d",
intval(argv(2)),
intval(local_channel())
);
}
$channel = \App::get_channel();
$mode = 'view';
$export = false;
//$y = 0;
//$m = 0;
$ignored = ((x($_REQUEST,'ignored')) ? " and dismissed = " . intval($_REQUEST['ignored']) . " " : '');
if(argc() > 1) {
if(argc() > 2 && argv(1) === 'add') {
$mode = 'add';
$item_id = intval(argv(2));
}
if(argc() > 2 && argv(1) === 'drop') {
$mode = 'drop';
$event_id = argv(2);
}
if(argc() <= 2 && argv(1) === 'export') {
$export = true;
}
if(argc() > 2 && intval(argv(1)) && intval(argv(2))) {
$mode = 'view';
//$y = intval(argv(1));
//$m = intval(argv(2));
}
if(argc() <= 2) {
$mode = 'view';
$event_id = argv(1);
}
}
if($mode === 'add') {
event_addtocal($item_id,local_channel());
killme();
}
if($mode == 'view') {
/* edit/create form */
if($event_id) {
$r = q("SELECT * FROM event WHERE event_hash = '%s' AND uid = %d LIMIT 1",
dbesc($event_id),
intval(local_channel())
);
if(count($r))
$orig_event = $r[0];
}
$channel = \App::get_channel();
/*
// Passed parameters overrides anything found in the DB
if(!x($orig_event))
$orig_event = array();
$n_checked = ((x($orig_event) && $orig_event['nofinish']) ? ' checked="checked" ' : '');
$a_checked = ((x($orig_event) && $orig_event['adjust']) ? ' checked="checked" ' : '');
$t_orig = ((x($orig_event)) ? $orig_event['summary'] : '');
$d_orig = ((x($orig_event)) ? $orig_event['description'] : '');
$l_orig = ((x($orig_event)) ? $orig_event['location'] : '');
$eid = ((x($orig_event)) ? $orig_event['id'] : 0);
$event_xchan = ((x($orig_event)) ? $orig_event['event_xchan'] : $channel['channel_hash']);
$mid = ((x($orig_event)) ? $orig_event['mid'] : '');
$sdt = ((x($orig_event)) ? $orig_event['dtstart'] : 'now');
$fdt = ((x($orig_event)) ? $orig_event['dtend'] : '+1 hour');
$tz = date_default_timezone_get();
if(x($orig_event))
$tz = (($orig_event['adjust']) ? date_default_timezone_get() : 'UTC');
$syear = datetime_convert('UTC', $tz, $sdt, 'Y');
$smonth = datetime_convert('UTC', $tz, $sdt, 'm');
$sday = datetime_convert('UTC', $tz, $sdt, 'd');
$shour = datetime_convert('UTC', $tz, $sdt, 'H');
$sminute = datetime_convert('UTC', $tz, $sdt, 'i');
$stext = datetime_convert('UTC',$tz,$sdt);
$stext = substr($stext,0,14) . "00:00";
$fyear = datetime_convert('UTC', $tz, $fdt, 'Y');
$fmonth = datetime_convert('UTC', $tz, $fdt, 'm');
$fday = datetime_convert('UTC', $tz, $fdt, 'd');
$fhour = datetime_convert('UTC', $tz, $fdt, 'H');
$fminute = datetime_convert('UTC', $tz, $fdt, 'i');
$ftext = datetime_convert('UTC',$tz,$fdt);
$ftext = substr($ftext,0,14) . "00:00";
$type = ((x($orig_event)) ? $orig_event['etype'] : 'event');
$f = get_config('system','event_input_format');
if(! $f)
$f = 'ymd';
$thisyear = datetime_convert('UTC',date_default_timezone_get(),'now','Y');
$thismonth = datetime_convert('UTC',date_default_timezone_get(),'now','m');
if(! $y)
$y = intval($thisyear);
if(! $m)
$m = intval($thismonth);
// Put some limits on dates. The PHP date functions don't seem to do so well before 1900.
// An upper limit was chosen to keep search engines from exploring links millions of years in the future.
if($y < 1901)
$y = 1900;
if($y > 2099)
$y = 2100;
$nextyear = $y;
$nextmonth = $m + 1;
if($nextmonth > 12) {
$nextmonth = 1;
$nextyear ++;
}
$prevyear = $y;
if($m > 1)
$prevmonth = $m - 1;
else {
$prevmonth = 12;
$prevyear --;
}
$dim = get_dim($y,$m);
$start = sprintf('%d-%d-%d %d:%d:%d',$y,$m,1,0,0,0);
$finish = sprintf('%d-%d-%d %d:%d:%d',$y,$m,$dim,23,59,59);
*/
if (argv(1) === 'json'){
if (x($_GET,'start')) $start = $_GET['start'];
if (x($_GET,'end')) $finish = $_GET['end'];
}
$start = datetime_convert('UTC','UTC',$start);
$finish = datetime_convert('UTC','UTC',$finish);
$adjust_start = datetime_convert('UTC', date_default_timezone_get(), $start);
$adjust_finish = datetime_convert('UTC', date_default_timezone_get(), $finish);
if (x($_GET,'id')){
$r = q("SELECT event.*, item.plink, item.item_flags, item.author_xchan, item.owner_xchan, item.id as item_id
from event left join item on item.resource_id = event.event_hash
where item.resource_type = 'event' and event.uid = %d and event.id = %d limit 1",
intval(local_channel()),
intval($_GET['id'])
);
}
elseif($export) {
$r = q("SELECT * from event where uid = %d",
intval(local_channel())
);
}
else {
// fixed an issue with "nofinish" events not showing up in the calendar.
// There's still an issue if the finish date crosses the end of month.
// Noting this for now - it will need to be fixed here and in Friendica.
// Ultimately the finish date shouldn't be involved in the query.
$r = q("SELECT event.*, item.plink, item.item_flags, item.author_xchan, item.owner_xchan, item.id as item_id
from event left join item on event.event_hash = item.resource_id
where item.resource_type = 'event' and event.uid = %d and event.uid = item.uid $ignored
AND (( event.adjust = 0 AND ( event.dtend >= '%s' or event.nofinish = 1 ) AND event.dtstart <= '%s' )
OR ( event.adjust = 1 AND ( event.dtend >= '%s' or event.nofinish = 1 ) AND event.dtstart <= '%s' )) ",
intval(local_channel()),
dbesc($start),
dbesc($finish),
dbesc($adjust_start),
dbesc($adjust_finish)
);
}
//$links = [];
if($r && ! $export) {
xchan_query($r);
$r = fetch_post_tags($r,true);
$r = sort_by_date($r);
}
/*
if($r) {
foreach($r as $rr) {
$j = (($rr['adjust']) ? datetime_convert('UTC',date_default_timezone_get(),$rr['dtstart'], 'j') : datetime_convert('UTC','UTC',$rr['dtstart'],'j'));
if(! x($links,$j))
$links[$j] = z_root() . '/' . \App::$cmd . '#link-' . $j;
}
}
*/
$events = [];
//$last_date = '';
//$fmt = t('l, F j');
if($r) {
foreach($r as $rr) {
//$j = (($rr['adjust']) ? datetime_convert('UTC',date_default_timezone_get(),$rr['dtstart'], 'j') : datetime_convert('UTC','UTC',$rr['dtstart'],'j'));
//$d = (($rr['adjust']) ? datetime_convert('UTC',date_default_timezone_get(),$rr['dtstart'], $fmt) : datetime_convert('UTC','UTC',$rr['dtstart'],$fmt));
//$d = day_translate($d);
$start = (($rr['adjust']) ? datetime_convert('UTC',date_default_timezone_get(),$rr['dtstart'], 'c') : datetime_convert('UTC','UTC',$rr['dtstart'],'c'));
if ($rr['nofinish']){
$end = null;
} else {
$end = (($rr['adjust']) ? datetime_convert('UTC',date_default_timezone_get(),$rr['dtend'], 'c') : datetime_convert('UTC','UTC',$rr['dtend'],'c'));
// give a fake end to birthdays so they get crammed into a
// single day on the calendar
if($rr['etype'] === 'birthday')
$end = null;
}
$catsenabled = feature_enabled(local_channel(),'categories');
$categories = '';
if($catsenabled){
if($rr['term']) {
$cats = get_terms_oftype($rr['term'], TERM_CATEGORY);
foreach ($cats as $cat) {
if(strlen($categories))
$categories .= ', ';
$categories .= $cat['term'];
}
}
}
$allDay = false;
// allDay event rules
if(!strpos($start, 'T') && !strpos($end, 'T'))
$allDay = true;
if(strpos($start, 'T00:00:00') && strpos($end, 'T00:00:00'))
$allDay = true;
//$is_first = ($d !== $last_date);
//$last_date = $d;
$edit = ((local_channel() && $rr['author_xchan'] == get_observer_hash()) ? array(z_root().'/events/'.$rr['event_hash'].'?expandform=1',t('Edit event'),'','') : false);
$drop = array(z_root().'/events/drop/'.$rr['event_hash'],t('Delete event'),'','');
$events[] = [
'calendar_id' => 'calendar',
'rw' => true,
'id' => $rr['id'],
'uri' => $rr['event_hash'],
'start' => $start,
'end' => $end,
'drop' => $drop,
'allDay' => $allDay,
'title' => htmlentities($rr['summary'], ENT_COMPAT, 'UTF-8'),
'editable' => $edit ? true : false,
'item' => $rr,
'plink' => [ $rr['plink'], t('Link to source') ],
'description' => htmlentities($rr['description'], ENT_COMPAT, 'UTF-8'),
'location' => htmlentities($rr['location'], ENT_COMPAT, 'UTF-8'),
'allow_cid' => expand_acl($rr['allow_cid']),
'allow_gid' => expand_acl($rr['allow_gid']),
'deny_cid' => expand_acl($rr['deny_cid']),
'deny_gid' => expand_acl($rr['deny_gid']),
'categories' => $categories
];
}
}
if($export) {
header('Content-type: text/calendar');
header('content-disposition: attachment; filename="' . t('calendar') . '-' . $channel['channel_address'] . '.ics"' );
echo ical_wrapper($r);
killme();
}
if (\App::$argv[1] === 'json'){
json_return_and_die($events);
}
}
if($mode === 'drop' && $event_id) {
$r = q("SELECT * FROM event WHERE event_hash = '%s' AND uid = %d LIMIT 1",
dbesc($event_id),
intval(local_channel())
);
$sync_event = $r[0];
if($r) {
$r = q("delete from event where event_hash = '%s' and uid = %d",
dbesc($event_id),
intval(local_channel())
);
if($r) {
$r = q("update item set resource_type = '', resource_id = '' where resource_type = 'event' and resource_id = '%s' and uid = %d",
dbesc($event_id),
intval(local_channel())
);
$sync_event['event_deleted'] = 1;
build_sync_packet(0,array('event' => array($sync_event)));
killme();
}
notice( t('Failed to remove event' ) . EOL);
killme();
}
}
}
}

View file

@ -133,10 +133,6 @@ class Cdav extends Controller {
logger('loggedin');
if((argv(1) == 'calendars') && (!Apps::system_app_installed(local_channel(), 'CalDAV'))) {
killme();
}
if((argv(1) == 'addressbooks') && (!Apps::system_app_installed(local_channel(), 'CardDAV'))) {
killme();
}
@ -221,10 +217,6 @@ class Cdav extends Controller {
if(! local_channel())
return;
if((argv(1) === 'calendar') && (! Apps::system_app_installed(local_channel(), 'CalDAV'))) {
return;
}
if((argv(1) === 'addressbook') && (! Apps::system_app_installed(local_channel(), 'CardDAV'))) {
return;
}
@ -280,9 +272,12 @@ class Cdav extends Controller {
return;
$title = $_REQUEST['title'];
$dtstart = new \DateTime($_REQUEST['dtstart']);
if($_REQUEST['dtend'])
$dtend = new \DateTime($_REQUEST['dtend']);
$start = datetime_convert(App::$timezone, 'UTC', $_REQUEST['dtstart']);
$dtstart = new \DateTime($start);
if($_REQUEST['dtend']) {
$end = datetime_convert(App::$timezone, 'UTC', $_REQUEST['dtend']);
$dtend = new \DateTime($end);
}
$description = $_REQUEST['description'];
$location = $_REQUEST['location'];
@ -306,13 +301,17 @@ class Cdav extends Controller {
'DTSTART' => $dtstart
]
]);
if($dtend)
if($dtend) {
$vcalendar->VEVENT->add('DTEND', $dtend);
$vcalendar->VEVENT->DTEND['TZID'] = App::$timezone;
}
if($description)
$vcalendar->VEVENT->add('DESCRIPTION', $description);
if($location)
$vcalendar->VEVENT->add('LOCATION', $location);
$vcalendar->VEVENT->DTSTART['TZID'] = App::$timezone;
$calendarData = $vcalendar->serialize();
$caldavBackend->createCalendarObject($id, $objectUri, $calendarData);
@ -351,8 +350,12 @@ class Cdav extends Controller {
$uri = $_REQUEST['uri'];
$title = $_REQUEST['title'];
$dtstart = new \DateTime($_REQUEST['dtstart']);
$dtend = $_REQUEST['dtend'] ? new \DateTime($_REQUEST['dtend']) : '';
$start = datetime_convert(App::$timezone, 'UTC', $_REQUEST['dtstart']);
$dtstart = new \DateTime($start);
if($_REQUEST['dtend']) {
$end = datetime_convert(App::$timezone, 'UTC', $_REQUEST['dtend']);
$dtend = new \DateTime($end);
}
$description = $_REQUEST['description'];
$location = $_REQUEST['location'];
@ -404,8 +407,12 @@ class Cdav extends Controller {
return;
$uri = $_REQUEST['uri'];
$dtstart = new \DateTime($_REQUEST['dtstart']);
$dtend = $_REQUEST['dtend'] ? new \DateTime($_REQUEST['dtend']) : '';
$start = datetime_convert(App::$timezone, 'UTC', $_REQUEST['dtstart']);
$dtstart = new \DateTime($start);
if($_REQUEST['dtend']) {
$end = datetime_convert(App::$timezone, 'UTC', $_REQUEST['dtend']);
$dtend = new \DateTime($end);
}
$object = $caldavBackend->getCalendarObject($id, $uri);
@ -747,16 +754,27 @@ class Cdav extends Controller {
//Import calendar or addressbook
if(($_FILES) && array_key_exists('userfile',$_FILES) && intval($_FILES['userfile']['size']) && $_REQUEST['target']) {
$src = @file_get_contents($_FILES['userfile']['tmp_name']);
$src = $_FILES['userfile']['tmp_name'];
if($src) {
if($_REQUEST['c_upload']) {
if($_REQUEST['target'] == 'calendar') {
$result = parse_ical_file($src,local_channel());
if($result)
info( t('Calendar entries imported.') . EOL);
else
notice( t('No calendar entries found.') . EOL);
@unlink($src);
return;
}
$id = explode(':', $_REQUEST['target']);
$ext = 'ics';
$table = 'calendarobjects';
$column = 'calendarid';
$objects = new \Sabre\VObject\Splitter\ICalendar($src);
$objects = new \Sabre\VObject\Splitter\ICalendar(@file_get_contents($src));
$profile = \Sabre\VObject\Node::PROFILE_CALDAV;
$backend = new \Sabre\CalDAV\Backend\PDO($pdo);
}
@ -766,7 +784,7 @@ class Cdav extends Controller {
$ext = 'vcf';
$table = 'cards';
$column = 'addressbookid';
$objects = new \Sabre\VObject\Splitter\VCard($src);
$objects = new \Sabre\VObject\Splitter\VCard(@file_get_contents($src));
$profile = \Sabre\VObject\Node::PROFILE_CARDDAV;
$backend = new \Sabre\CardDAV\Backend\PDO($pdo);
}
@ -832,24 +850,17 @@ class Cdav extends Controller {
if(!local_channel())
return;
if((argv(1) === 'calendar') && (! Apps::system_app_installed(local_channel(), 'CalDAV'))) {
//Do not display any associated widgets at this point
App::$pdl = '';
$o = '<b>CalDAV App (Not Installed):</b><br>';
$o .= t('CalDAV capable calendar');
return $o;
}
if((argv(1) === 'addressbook') && (! Apps::system_app_installed(local_channel(), 'CardDAV'))) {
//Do not display any associated widgets at this point
App::$pdl = '';
$o = '<b>CardDAV App (Not Installed):</b><br>';
$o = '<b>' . t('CardDAV App') . ' (' . t('Not Installed') . '):</b><br>';
$o .= t('CalDAV capable addressbook');
return $o;
}
App::$profile_uid = local_channel();
$channel = App::get_channel();
$principalUri = 'principals/' . $channel['channel_address'];
@ -867,28 +878,93 @@ class Cdav extends Controller {
}
if(argv(1) === 'calendar') {
nav_set_selected('CalDAV');
nav_set_selected('Calendar');
$caldavBackend = new \Sabre\CalDAV\Backend\PDO($pdo);
$calendars = $caldavBackend->getCalendarsForUser($principalUri);
}
//Display calendar(s) here
if(argc() == 2 && argv(1) === 'calendar') {
if(argc() <= 3 && argv(1) === 'calendar') {
head_add_css('/library/fullcalendar/fullcalendar.css');
head_add_css('/library/fullcalendar/packages/core/main.min.css');
head_add_css('/library/fullcalendar/packages/daygrid/main.min.css');
head_add_css('/library/fullcalendar/packages/timegrid/main.min.css');
head_add_css('/library/fullcalendar/packages/list/main.min.css');
head_add_css('cdav_calendar.css');
head_add_js('/library/moment/moment.min.js', 1);
head_add_js('/library/fullcalendar/fullcalendar.min.js', 1);
head_add_js('/library/fullcalendar/locale-all.js', 1);
head_add_js('/library/fullcalendar/packages/core/main.min.js');
head_add_js('/library/fullcalendar/packages/interaction/main.min.js');
head_add_js('/library/fullcalendar/packages/daygrid/main.min.js');
head_add_js('/library/fullcalendar/packages/timegrid/main.min.js');
head_add_js('/library/fullcalendar/packages/list/main.min.js');
$sources = '';
$resource_id = '';
$resource = null;
if(argc() == 3)
$resource_id = argv(2);
if($resource_id) {
$r = q("SELECT event.*, item.author_xchan, item.owner_xchan, item.plink, item.id as item_id FROM event LEFT JOIN item ON event.event_hash = item.resource_id
WHERE event.uid = %d AND event.event_hash = '%s' LIMIT 1",
intval(local_channel()),
dbesc($resource_id)
);
if($r) {
xchan_query($r);
$r = fetch_post_tags($r,true);
$r[0]['dtstart'] = (($r[0]['adjust']) ? datetime_convert('UTC',date_default_timezone_get(),$r[0]['dtstart'], 'c') : datetime_convert('UTC','UTC',$r[0]['dtstart'],'c'));
$r[0]['dtend'] = (($r[0]['adjust']) ? datetime_convert('UTC',date_default_timezone_get(),$r[0]['dtend'], 'c') : datetime_convert('UTC','UTC',$r[0]['dtend'],'c'));
$r[0]['plink'] = [$r[0]['plink'], t('Link to source')];
$resource = $r[0];
$catsenabled = feature_enabled(local_channel(),'categories');
$categories = '';
if($catsenabled){
if($r[0]['term']) {
$cats = get_terms_oftype($r[0]['term'], TERM_CATEGORY);
foreach ($cats as $cat) {
if(strlen($categories))
$categories .= ', ';
$categories .= $cat['term'];
}
}
}
if($r[0]['dismissed'] == 0) {
q("UPDATE event SET dismissed = 1 WHERE event.uid = %d AND event.event_hash = '%s'",
intval(local_channel()),
dbesc($resource_id)
);
}
}
}
if(get_pconfig(local_channel(), 'cdav_calendar', 'calendar')) {
$sources .= '{
id: \'calendar\',
url: \'/calendar/json/\',
color: \'#3a87ad\'
}, ';
}
$calendars[] = [
'displayname' => $channel['channel_name'],
'id' => 'calendar'
];
foreach($calendars as $calendar) {
$editable = (($calendar['share-access'] == 2) ? 'false' : 'true'); // false/true must be string since we're passing it to javascript
$color = (($calendar['{http://apple.com/ns/ical/}calendar-color']) ? $calendar['{http://apple.com/ns/ical/}calendar-color'] : '#3a87ad');
$color = (($calendar['{http://apple.com/ns/ical/}calendar-color']) ? $calendar['{http://apple.com/ns/ical/}calendar-color'] : '#6cad39');
$sharer = (($calendar['share-access'] == 3) ? $calendar['{urn:ietf:params:xml:ns:caldav}calendar-description'] : '');
$switch = get_pconfig(local_channel(), 'cdav_calendar', $calendar['id'][0]);
if($switch) {
$sources .= '{
id: ' . $calendar['id'][0] . ',
url: \'/cdav/calendar/json/' . $calendar['id'][0] . '/' . $calendar['id'][1] . '\',
color: \'' . $color . '\'
}, ';
@ -905,19 +981,33 @@ class Cdav extends Controller {
$sources = rtrim($sources, ', ');
$first_day = get_pconfig(local_channel(),'system','cal_first_day');
$first_day = feature_enabled(local_channel(), 'cal_first_day');
$first_day = (($first_day) ? $first_day : 0);
$title = ['title', t('Event title')];
$dtstart = ['dtstart', t('Start date and time'), '', t('Example: YYYY-MM-DD HH:mm')];
$dtend = ['dtend', t('End date and time'), '', t('Example: YYYY-MM-DD HH:mm')];
$dtstart = ['dtstart', t('Start date and time')];
$dtend = ['dtend', t('End date and time')];
$description = ['description', t('Description')];
$location = ['location', t('Location')];
$catsenabled = feature_enabled(local_channel(), 'categories');
require_once('include/acl_selectors.php');
$accesslist = new \Zotlabs\Access\AccessControl($channel);
$perm_defaults = $accesslist->get();
//$acl = (($orig_event['event_xchan']) ? '' : populate_acl(((x($orig_event)) ? $orig_event : $perm_defaults), false, \Zotlabs\Lib\PermissionDescription::fromGlobalPermission('view_stream')));
$acl = populate_acl($perm_defaults, false, \Zotlabs\Lib\PermissionDescription::fromGlobalPermission('view_stream'));
//$permissions = ((x($orig_event)) ? $orig_event : $perm_defaults);
$permissions = $perm_defaults;
$o .= replace_macros(get_markup_template('cdav_calendar.tpl'), [
'$sources' => $sources,
'$color' => $color,
'$lang' => App::$language,
'$timezone' => App::$timezone,
'$first_day' => $first_day,
'$prev' => t('Previous'),
'$next' => t('Next'),
@ -929,6 +1019,7 @@ class Cdav extends Controller {
'$list_week' => t('List week'),
'$list_day' => t('List day'),
'$title' => $title,
'$calendars' => $calendars,
'$writable_calendars' => $writable_calendars,
'$dtstart' => $dtstart,
'$dtend' => $dtend,
@ -936,11 +1027,27 @@ class Cdav extends Controller {
'$location' => $location,
'$more' => t('More'),
'$less' => t('Less'),
'$update' => t('Update'),
'$calendar_select_label' => t('Select calendar'),
'$calendar_optiopns_label' => [t('Channel Calendars'), t('CalDAV Calendars')],
'$delete' => t('Delete'),
'$delete_all' => t('Delete all'),
'$cancel' => t('Cancel'),
'$recurrence_warning' => t('Sorry! Editing of recurrent events is not yet implemented.')
'$create' => t('Create'),
'$recurrence_warning' => t('Sorry! Editing of recurrent events is not yet implemented.'),
'$channel_hash' => $channel['channel_hash'],
'$acl' => $acl,
'$lockstate' => (($accesslist->is_private()) ? 'lock' : 'unlock'),
'$allow_cid' => acl2json($permissions['allow_cid']),
'$allow_gid' => acl2json($permissions['allow_gid']),
'$deny_cid' => acl2json($permissions['deny_cid']),
'$deny_gid' => acl2json($permissions['deny_gid']),
'$catsenabled' => $catsenabled,
'$categories_label' => t('Categories'),
'$resource' => json_encode($resource),
'$categories' => $categories
]);
return $o;
@ -950,10 +1057,12 @@ class Cdav extends Controller {
//Provide json data for calendar
if(argc() == 5 && argv(1) === 'calendar' && argv(2) === 'json' && intval(argv(3)) && intval(argv(4))) {
$events = [];
$id = [argv(3), argv(4)];
if(! cdav_perms($id[0],$calendars))
killme();
json_return_and_die($events);
if (x($_GET,'start'))
$start = new \DateTime($_GET['start']);
@ -967,16 +1076,19 @@ class Cdav extends Controller {
$filters['comp-filters'][0]['time-range']['end'] = $end;
$uris = $caldavBackend->calendarQuery($id, $filters);
if($uris) {
$objects = $caldavBackend->getMultipleCalendarObjects($id, $uris);
foreach($objects as $object) {
$vcalendar = \Sabre\VObject\Reader::read($object['calendardata']);
if(isset($vcalendar->VEVENT->RRULE))
if(isset($vcalendar->VEVENT->RRULE)) {
// expanding recurrent events seems to loose timezone info
// save it here so we can add it later
$recurrent_timezone = (string)$vcalendar->VEVENT->DTSTART['TZID'];
$vcalendar = $vcalendar->expand($start, $end);
}
foreach($vcalendar->VEVENT as $vevent) {
$title = (string)$vevent->SUMMARY;
@ -984,14 +1096,15 @@ class Cdav extends Controller {
$dtend = (string)$vevent->DTEND;
$description = (string)$vevent->DESCRIPTION;
$location = (string)$vevent->LOCATION;
$timezone = (string)$vevent->DTSTART['TZID'];
$rw = ((cdav_perms($id[0],$calendars,true)) ? true : false);
$editable = $rw ? true : false;
$recurrent = ((isset($vevent->{'RECURRENCE-ID'})) ? true : false);
$editable = $rw ? true : false;
if($recurrent)
if($recurrent) {
$editable = false;
$timezone = $recurrent_timezone;
}
$allDay = false;
@ -1005,8 +1118,8 @@ class Cdav extends Controller {
'calendar_id' => $id,
'uri' => $object['uri'],
'title' => $title,
'start' => $dtstart,
'end' => $dtend,
'start' => datetime_convert($timezone, $timezone, $dtstart, 'c'),
'end' => (($dtend) ? datetime_convert($timezone, $timezone, $dtend, 'c') : ''),
'description' => $description,
'location' => $location,
'allDay' => $allDay,
@ -1016,15 +1129,12 @@ class Cdav extends Controller {
];
}
}
json_return_and_die($events);
}
else {
killme();
}
json_return_and_die($events);
}
//enable/disable calendars
if(argc() == 5 && argv(1) === 'calendar' && argv(2) === 'switch' && intval(argv(3)) && (argv(4) == 1 || argv(4) == 0)) {
if(argc() == 5 && argv(1) === 'calendar' && argv(2) === 'switch' && argv(3) && (argv(4) == 1 || argv(4) == 0)) {
$id = argv(3);
if(! cdav_perms($id,$calendars))
@ -1283,12 +1393,13 @@ class Cdav extends Controller {
$caldavBackend = new \Sabre\CalDAV\Backend\PDO($pdo);
$properties = [
'{DAV:}displayname' => t('Default Calendar'),
'{http://apple.com/ns/ical/}calendar-color' => '#3a87ad',
'{http://apple.com/ns/ical/}calendar-color' => '#6cad39',
'{urn:ietf:params:xml:ns:caldav}calendar-description' => $channel['channel_name']
];
$id = $caldavBackend->createCalendar($uri, 'default', $properties);
set_pconfig(local_channel(), 'cdav_calendar' , $id[0], 1);
set_pconfig(local_channel(), 'cdav_calendar' , 'calendar', 1);
//create default addressbook
$carddavBackend = new \Sabre\CardDAV\Backend\PDO($pdo);

View file

@ -508,7 +508,7 @@ abstract class PhotoDriver {
$arr['imgscale'] = $scale;
if(boolval(get_config('system','filesystem_storage_thumbnails', 0)) && $scale > 0) {
if(boolval(get_config('system','filesystem_storage_thumbnails', 1)) && $scale > 0) {
$channel = \App::get_channel();
$arr['os_storage'] = 1;
$arr['os_syspath'] = 'store/' . $channel['channel_address'] . '/' . $arr['os_path'] . '-' . $scale;

View file

@ -22,7 +22,7 @@ class Cdav {
$o = '';
if(argc() == 2 && argv(1) === 'calendar') {
if(argc() <= 3 && argv(1) === 'calendar') {
$caldavBackend = new \Sabre\CalDAV\Backend\PDO($pdo);
@ -57,7 +57,7 @@ class Cdav {
$switch = get_pconfig(local_channel(), 'cdav_calendar', $sabrecal['id'][0]);
$color = (($sabrecal['{http://apple.com/ns/ical/}calendar-color']) ? $sabrecal['{http://apple.com/ns/ical/}calendar-color'] : '#3a87ad');
$color = (($sabrecal['{http://apple.com/ns/ical/}calendar-color']) ? $sabrecal['{http://apple.com/ns/ical/}calendar-color'] : '#6cad39');
$editable = (($sabrecal['share-access'] == 2) ? 'false' : 'true'); // false/true must be string since we're passing it to javascript
@ -113,10 +113,22 @@ class Cdav {
}
}
$calendars[] = [
'ownernick' => $channel['channel_address'],
'displayname' => $channel['channel_name'],
'calendarid' => 'calendar',
'json_source' => '/calendar/json',
'color' => '#3a87ad',
'editable' => true,
'switch' => get_pconfig(local_channel(), 'cdav_calendar', 'calendar')
];
$o .= replace_macros(get_markup_template('cdav_widget_calendar.tpl'), [
'$my_calendars_label' => t('My Calendars'),
'$calendars_label' => t('Channel Calendar'),
'$calendars' => $calendars,
'$my_calendars_label' => t('CalDAV Calendars'),
'$my_calendars' => $my_calendars,
'$shared_calendars_label' => t('Shared Calendars'),
'$shared_calendars_label' => t('Shared CalDAV Calendars'),
'$shared_calendars' => $shared_calendars,
'$sharee_options' => $sharee_options,
'$access_options' => $access_options,
@ -124,10 +136,11 @@ class Cdav {
'$share' => t('Share'),
'$edit_label' => t('Calendar name and color'),
'$edit' => t('Edit'),
'$create_label' => t('Create new calendar'),
'$create_label' => t('Create new CalDAV calendar'),
'$create' => t('Create'),
'$create_placeholder' => t('Calendar Name'),
'$tools_label' => t('Calendar Tools'),
'$tools_options_label' => [t('Channel Calendars'), t('CalDAV Calendars')],
'$import_label' => t('Import calendar'),
'$import_placeholder' => t('Select a calendar to import to'),
'$upload' => t('Upload'),

View file

@ -1,6 +1,6 @@
version: 1
url: $baseurl/cdav/calendar
requires: local_channel
name: CalDAV
name: Calendar
photo: icon:calendar
categories: Productivity, Personal
categories: Productivity, nav_featured_app

View file

@ -1188,13 +1188,16 @@ function event_store_item($arr, $event) {
$item_arr['item_origin'] = $item_origin;
$item_arr['item_thread_top'] = $item_thread_top;
$attach = array(array(
'href' => z_root() . '/events/ical/' . urlencode($event['event_hash']),
'length' => 0,
'type' => 'text/calendar',
'title' => t('event') . '-' . $event['event_hash'],
'revision' => ''
));
$attach = [
[
'href' => z_root() . '/calendar/ical/' . urlencode($event['event_hash']),
'length' => 0,
'type' => 'text/calendar',
'title' => t('event') . '-' . $event['event_hash'],
'revision' => ''
]
];
$item_arr['attach'] = $attach;
@ -1211,7 +1214,7 @@ function event_store_item($arr, $event) {
// otherwise we'll fallback to /display/$message_id
if($wall)
$item_arr['plink'] = z_root() . '/channel/' . $z['channel_address'] . '/?f=&mid=' . urlencode($item_arr['mid']);
$item_arr['plink'] = z_root() . '/channel/' . $z['channel_address'] . '/?f=&mid=' . gen_link_id($item_arr['mid']);
else
$item_arr['plink'] = z_root() . '/display/' . gen_link_id($item_arr['mid']);
@ -1311,9 +1314,14 @@ function cdav_principal($uri) {
}
function cdav_perms($needle, $haystack, $check_rw = false) {
if ($needle === 'calendar') {
return true;
}
foreach ($haystack as $item) {
if($check_rw) {
if(is_array($item['id'])) {
if ($check_rw) {
if (is_array($item['id'])) {
if ($item['id'][0] == $needle && $item['share-access'] != 2) {
return $item['{DAV:}displayname'];
}
@ -1325,7 +1333,7 @@ function cdav_perms($needle, $haystack, $check_rw = false) {
}
}
else {
if(is_array($item['id'])) {
if (is_array($item['id'])) {
if ($item['id'][0] == $needle) {
return $item['{DAV:}displayname'];
}

View file

@ -22,11 +22,11 @@ require_once('include/text.php');
function photo_upload($channel, $observer, $args) {
$ret = array('success' => false);
$ret = [ 'success' => false ];
$channel_id = $channel['channel_id'];
$account_id = $channel['channel_account_id'];
if(! perm_is_allowed($channel_id, $observer['xchan_hash'], 'write_storage')) {
if (! perm_is_allowed($channel_id, $observer['xchan_hash'], 'write_storage')) {
$ret['message'] = t('Permission denied.');
return $ret;
}
@ -37,14 +37,15 @@ function photo_upload($channel, $observer, $args) {
$album = $args['album'];
if(intval($args['visible']) || $args['visible'] === 'true')
if (intval($args['visible']) || $args['visible'] === 'true') {
$visible = 1;
else
}
else {
$visible = 0;
}
$deliver = ((array_key_exists('deliver', $args)) ? intval($args['deliver']) : 1 );
$deliver = true;
if(array_key_exists('deliver',$args))
$deliver = intval($args['deliver']);
// Set to default channel permissions. If the parent directory (album) has permissions set,
// use those instead. If we have specific permissions supplied, they take precedence over
@ -52,11 +53,13 @@ function photo_upload($channel, $observer, $args) {
// ...messy... needs re-factoring once the photos/files integration stabilises
$acl = new AccessControl($channel);
if(array_key_exists('directory',$args) && $args['directory'])
if (array_key_exists('directory',$args) && $args['directory']) {
$acl->set($args['directory']);
if(array_key_exists('allow_cid',$args))
}
if (array_key_exists('allow_cid',$args)) {
$acl->set($args);
if( (array_key_exists('group_allow',$args))
}
if ((array_key_exists('group_allow',$args))
|| (array_key_exists('contact_allow',$args))
|| (array_key_exists('group_deny',$args))
|| (array_key_exists('contact_deny',$args))) {
@ -68,7 +71,7 @@ function photo_upload($channel, $observer, $args) {
$width = $height = 0;
if($args['getimagesize']) {
$width = $args['getimagesize'][0];
$width = $args['getimagesize'][0];
$height = $args['getimagesize'][1];
}

View file

@ -0,0 +1,20 @@
Copyright (c) 2015 Adam Shaw
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:
The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

File diff suppressed because it is too large Load diff

View file

@ -1,4 +1,4 @@
Copyright (c) 2015 Adam Shaw
Copyright (c) 2019 Adam Shaw
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the

View file

@ -0,0 +1,109 @@
<!DOCTYPE html>
<html>
<head>
<meta charset='utf-8' />
<link href='../packages/core/main.css' rel='stylesheet' />
<link href='../packages/daygrid/main.css' rel='stylesheet' />
<link href='../packages/timegrid/main.css' rel='stylesheet' />
<link href='../packages/list/main.css' rel='stylesheet' />
<script src='../packages/core/main.js'></script>
<script src='../packages/interaction/main.js'></script>
<script src='../packages/daygrid/main.js'></script>
<script src='../packages/timegrid/main.js'></script>
<script src='../packages/list/main.js'></script>
<script>
document.addEventListener('DOMContentLoaded', function() {
var calendarEl = document.getElementById('calendar');
var calendar = new FullCalendar.Calendar(calendarEl, {
plugins: [ 'interaction', 'dayGrid', 'timeGrid', 'list' ],
header: {
left: 'prev,next today',
center: 'title',
right: 'dayGridMonth,timeGridWeek,timeGridDay,listMonth'
},
defaultDate: '2019-04-12',
navLinks: true, // can click day/week names to navigate views
businessHours: true, // display business hours
editable: true,
events: [
{
title: 'Business Lunch',
start: '2019-04-03T13:00:00',
constraint: 'businessHours'
},
{
title: 'Meeting',
start: '2019-04-13T11:00:00',
constraint: 'availableForMeeting', // defined below
color: '#257e4a'
},
{
title: 'Conference',
start: '2019-04-18',
end: '2019-04-20'
},
{
title: 'Party',
start: '2019-04-29T20:00:00'
},
// areas where "Meeting" must be dropped
{
groupId: 'availableForMeeting',
start: '2019-04-11T10:00:00',
end: '2019-04-11T16:00:00',
rendering: 'background'
},
{
groupId: 'availableForMeeting',
start: '2019-04-13T10:00:00',
end: '2019-04-13T16:00:00',
rendering: 'background'
},
// red areas where no events can be dropped
{
start: '2019-04-24',
end: '2019-04-28',
overlap: false,
rendering: 'background',
color: '#ff9f89'
},
{
start: '2019-04-06',
end: '2019-04-08',
overlap: false,
rendering: 'background',
color: '#ff9f89'
}
]
});
calendar.render();
});
</script>
<style>
body {
margin: 40px 10px;
padding: 0;
font-family: Arial, Helvetica Neue, Helvetica, sans-serif;
font-size: 14px;
}
#calendar {
max-width: 900px;
margin: 0 auto;
}
</style>
</head>
<body>
<div id='calendar'></div>
</body>
</html>

View file

@ -0,0 +1,109 @@
<!DOCTYPE html>
<html>
<head>
<meta charset='utf-8' />
<link href='../packages/core/main.css' rel='stylesheet' />
<link href='../packages/daygrid/main.css' rel='stylesheet' />
<script src='../packages/core/main.js'></script>
<script src='../packages/interaction/main.js'></script>
<script src='../packages/daygrid/main.js'></script>
<script>
document.addEventListener('DOMContentLoaded', function() {
var calendarEl = document.getElementById('calendar');
var calendar = new FullCalendar.Calendar(calendarEl, {
plugins: [ 'interaction', 'dayGrid' ],
header: {
left: 'prevYear,prev,next,nextYear today',
center: 'title',
right: 'dayGridMonth,dayGridWeek,dayGridDay'
},
defaultDate: '2019-04-12',
navLinks: true, // can click day/week names to navigate views
editable: true,
eventLimit: true, // allow "more" link when too many events
events: [
{
title: 'All Day Event',
start: '2019-04-01'
},
{
title: 'Long Event',
start: '2019-04-07',
end: '2019-04-10'
},
{
groupId: 999,
title: 'Repeating Event',
start: '2019-04-09T16:00:00'
},
{
groupId: 999,
title: 'Repeating Event',
start: '2019-04-16T16:00:00'
},
{
title: 'Conference',
start: '2019-04-11',
end: '2019-04-13'
},
{
title: 'Meeting',
start: '2019-04-12T10:30:00',
end: '2019-04-12T12:30:00'
},
{
title: 'Lunch',
start: '2019-04-12T12:00:00'
},
{
title: 'Meeting',
start: '2019-04-12T14:30:00'
},
{
title: 'Happy Hour',
start: '2019-04-12T17:30:00'
},
{
title: 'Dinner',
start: '2019-04-12T20:00:00'
},
{
title: 'Birthday Party',
start: '2019-04-13T07:00:00'
},
{
title: 'Click for Google',
url: 'http://google.com/',
start: '2019-04-28'
}
]
});
calendar.render();
});
</script>
<style>
body {
margin: 40px 10px;
padding: 0;
font-family: Arial, Helvetica Neue, Helvetica, sans-serif;
font-size: 14px;
}
#calendar {
max-width: 900px;
margin: 0 auto;
}
</style>
</head>
<body>
<div id='calendar'></div>
</body>
</html>

View file

@ -0,0 +1,103 @@
<!DOCTYPE html>
<html>
<head>
<meta charset='utf-8' />
<link href='../packages/core/main.css' rel='stylesheet' />
<link href='../packages/daygrid/main.css' rel='stylesheet' />
<script src='../packages/core/main.js'></script>
<script src='../packages/interaction/main.js'></script>
<script src='../packages/daygrid/main.js'></script>
<script>
document.addEventListener('DOMContentLoaded', function() {
var calendarEl = document.getElementById('calendar');
var calendar = new FullCalendar.Calendar(calendarEl, {
plugins: [ 'interaction', 'dayGrid' ],
defaultDate: '2019-04-12',
editable: true,
eventLimit: true, // allow "more" link when too many events
events: [
{
title: 'All Day Event',
start: '2019-04-01'
},
{
title: 'Long Event',
start: '2019-04-07',
end: '2019-04-10'
},
{
groupId: 999,
title: 'Repeating Event',
start: '2019-04-09T16:00:00'
},
{
groupId: 999,
title: 'Repeating Event',
start: '2019-04-16T16:00:00'
},
{
title: 'Conference',
start: '2019-04-11',
end: '2019-04-13'
},
{
title: 'Meeting',
start: '2019-04-12T10:30:00',
end: '2019-04-12T12:30:00'
},
{
title: 'Lunch',
start: '2019-04-12T12:00:00'
},
{
title: 'Meeting',
start: '2019-04-12T14:30:00'
},
{
title: 'Happy Hour',
start: '2019-04-12T17:30:00'
},
{
title: 'Dinner',
start: '2019-04-12T20:00:00'
},
{
title: 'Birthday Party',
start: '2019-04-13T07:00:00'
},
{
title: 'Click for Google',
url: 'http://google.com/',
start: '2019-04-28'
}
]
});
calendar.render();
});
</script>
<style>
body {
margin: 40px 10px;
padding: 0;
font-family: Arial, Helvetica Neue, Helvetica, sans-serif;
font-size: 14px;
}
#calendar {
max-width: 900px;
margin: 0 auto;
}
</style>
</head>
<body>
<div id='calendar'></div>
</body>
</html>

View file

@ -0,0 +1,75 @@
<!DOCTYPE html>
<html>
<head>
<meta charset='utf-8' />
<link href='../packages/core/main.css' rel='stylesheet' />
<link href='../packages/daygrid/main.css' rel='stylesheet' />
<script src='../packages/core/main.js'></script>
<script src='../packages/interaction/main.js'></script>
<script src='../packages/daygrid/main.js'></script>
<script>
document.addEventListener('DOMContentLoaded', function() {
var srcCalendarEl = document.getElementById('source-calendar');
var destCalendarEl = document.getElementById('destination-calendar');
var srcCalendar = new FullCalendar.Calendar(srcCalendarEl, {
plugins: [ 'interaction', 'dayGrid' ],
editable: true,
defaultDate: '2019-04-12',
events: [
{
title: 'event1',
start: '2019-04-11T10:00:00',
end: '2019-04-11T16:00:00'
},
{
title: 'event2',
start: '2019-04-13T10:00:00',
end: '2019-04-13T16:00:00'
}
],
eventLeave: function(info) {
console.log('event left!', info.event);
}
});
var destCalendar = new FullCalendar.Calendar(destCalendarEl, {
plugins: [ 'interaction', 'dayGrid' ],
defaultDate: '2019-04-12',
editable: true,
droppable: true, // will let it receive events!
eventReceive: function(info) {
console.log('event received!', info.event);
}
});
srcCalendar.render();
destCalendar.render();
});
</script>
<style>
body {
margin: 20px 0 0 20px;
font-size: 14px;
font-family: Arial, Helvetica Neue, Helvetica, sans-serif;
}
#source-calendar,
#destination-calendar {
float: left;
width: 600px;
margin: 0 20px 20px 0;
}
</style>
</head>
<body>
<div id='source-calendar'></div>
<div id='destination-calendar'></div>
</body>
</html>

View file

@ -0,0 +1,149 @@
<!DOCTYPE html>
<html>
<head>
<meta charset='utf-8' />
<link href='../packages/core/main.css' rel='stylesheet' />
<link href='../packages/daygrid/main.css' rel='stylesheet' />
<link href='../packages/timegrid/main.css' rel='stylesheet' />
<link href='../packages/list/main.css' rel='stylesheet' />
<script src='../packages/core/main.js'></script>
<script src='../packages/interaction/main.js'></script>
<script src='../packages/daygrid/main.js'></script>
<script src='../packages/timegrid/main.js'></script>
<script src='../packages/list/main.js'></script>
<script>
document.addEventListener('DOMContentLoaded', function() {
var Calendar = FullCalendar.Calendar;
var Draggable = FullCalendarInteraction.Draggable
/* initialize the external events
-----------------------------------------------------------------*/
var containerEl = document.getElementById('external-events-list');
new Draggable(containerEl, {
itemSelector: '.fc-event',
eventData: function(eventEl) {
return {
title: eventEl.innerText.trim()
}
}
});
//// the individual way to do it
// var containerEl = document.getElementById('external-events-list');
// var eventEls = Array.prototype.slice.call(
// containerEl.querySelectorAll('.fc-event')
// );
// eventEls.forEach(function(eventEl) {
// new Draggable(eventEl, {
// eventData: {
// title: eventEl.innerText.trim(),
// }
// });
// });
/* initialize the calendar
-----------------------------------------------------------------*/
var calendarEl = document.getElementById('calendar');
var calendar = new Calendar(calendarEl, {
plugins: [ 'interaction', 'dayGrid', 'timeGrid', 'list' ],
header: {
left: 'prev,next today',
center: 'title',
right: 'dayGridMonth,timeGridWeek,timeGridDay,listWeek'
},
editable: true,
droppable: true, // this allows things to be dropped onto the calendar
drop: function(arg) {
// is the "remove after drop" checkbox checked?
if (document.getElementById('drop-remove').checked) {
// if so, remove the element from the "Draggable Events" list
arg.draggedEl.parentNode.removeChild(arg.draggedEl);
}
}
});
calendar.render();
});
</script>
<style>
body {
margin-top: 40px;
font-size: 14px;
font-family: Arial, Helvetica Neue, Helvetica, sans-serif;
}
#wrap {
width: 1100px;
margin: 0 auto;
}
#external-events {
float: left;
width: 150px;
padding: 0 10px;
border: 1px solid #ccc;
background: #eee;
text-align: left;
}
#external-events h4 {
font-size: 16px;
margin-top: 0;
padding-top: 1em;
}
#external-events .fc-event {
margin: 10px 0;
cursor: pointer;
}
#external-events p {
margin: 1.5em 0;
font-size: 11px;
color: #666;
}
#external-events p input {
margin: 0;
vertical-align: middle;
}
#calendar {
float: right;
width: 900px;
}
</style>
</head>
<body>
<div id='wrap'>
<div id='external-events'>
<h4>Draggable Events</h4>
<div id='external-events-list'>
<div class='fc-event'>My Event 1</div>
<div class='fc-event'>My Event 2</div>
<div class='fc-event'>My Event 3</div>
<div class='fc-event'>My Event 4</div>
<div class='fc-event'>My Event 5</div>
</div>
<p>
<input type='checkbox' id='drop-remove' />
<label for='drop-remove'>remove after drop</label>
</p>
</div>
<div id='calendar'></div>
<div style='clear:both'></div>
</div>
</body>
</html>

View file

@ -0,0 +1,129 @@
<!DOCTYPE html>
<html>
<head>
<meta charset='utf-8' />
<link href='../packages/core/main.css' rel='stylesheet' />
<link href='../packages/daygrid/main.css' rel='stylesheet' />
<link href='../packages/timegrid/main.css' rel='stylesheet' />
<link href='../packages/list/main.css' rel='stylesheet' />
<script src='../packages/core/main.js'></script>
<script src='../packages/interaction/main.js'></script>
<script src='../packages/daygrid/main.js'></script>
<script src='../packages/timegrid/main.js'></script>
<script src='../packages/list/main.js'></script>
<script>
document.addEventListener('DOMContentLoaded', function() {
var calendarEl = document.getElementById('calendar');
var calendar = new FullCalendar.Calendar(calendarEl, {
plugins: [ 'interaction', 'dayGrid', 'timeGrid', 'list' ],
height: 'parent',
header: {
left: 'prev,next today',
center: 'title',
right: 'dayGridMonth,timeGridWeek,timeGridDay,listWeek'
},
defaultView: 'dayGridMonth',
defaultDate: '2019-04-12',
navLinks: true, // can click day/week names to navigate views
editable: true,
eventLimit: true, // allow "more" link when too many events
events: [
{
title: 'All Day Event',
start: '2019-04-01',
},
{
title: 'Long Event',
start: '2019-04-07',
end: '2019-04-10'
},
{
groupId: 999,
title: 'Repeating Event',
start: '2019-04-09T16:00:00'
},
{
groupId: 999,
title: 'Repeating Event',
start: '2019-04-16T16:00:00'
},
{
title: 'Conference',
start: '2019-04-11',
end: '2019-04-13'
},
{
title: 'Meeting',
start: '2019-04-12T10:30:00',
end: '2019-04-12T12:30:00'
},
{
title: 'Lunch',
start: '2019-04-12T12:00:00'
},
{
title: 'Meeting',
start: '2019-04-12T14:30:00'
},
{
title: 'Happy Hour',
start: '2019-04-12T17:30:00'
},
{
title: 'Dinner',
start: '2019-04-12T20:00:00'
},
{
title: 'Birthday Party',
start: '2019-04-13T07:00:00'
},
{
title: 'Click for Google',
url: 'http://google.com/',
start: '2019-04-28'
}
]
});
calendar.render();
});
</script>
<style>
html, body {
overflow: hidden; /* don't do scrollbars */
font-family: Arial, Helvetica Neue, Helvetica, sans-serif;
font-size: 14px;
}
#calendar-container {
position: fixed;
top: 0;
left: 0;
right: 0;
bottom: 0;
}
.fc-header-toolbar {
/*
the calendar will be butting up against the edges,
but let's scoot in the header's buttons
*/
padding-top: 1em;
padding-left: 1em;
padding-right: 1em;
}
</style>
</head>
<body>
<div id='calendar-container'>
<div id='calendar'></div>
</div>
</body>
</html>

View file

@ -0,0 +1,86 @@
<!DOCTYPE html>
<html>
<head>
<meta charset='utf-8' />
<link href='../packages/core/main.css' rel='stylesheet' />
<link href='../packages/daygrid/main.css' rel='stylesheet' />
<link href='../packages/list/main.css' rel='stylesheet' />
<script src='../packages/core/main.js'></script>
<script src='../packages/interaction/main.js'></script>
<script src='../packages/daygrid/main.js'></script>
<script src='../packages/list/main.js'></script>
<script src='../packages/google-calendar/main.js'></script>
<script>
document.addEventListener('DOMContentLoaded', function() {
var calendarEl = document.getElementById('calendar');
var calendar = new FullCalendar.Calendar(calendarEl, {
plugins: [ 'interaction', 'dayGrid', 'list', 'googleCalendar' ],
header: {
left: 'prev,next today',
center: 'title',
right: 'dayGridMonth,listYear'
},
displayEventTime: false, // don't show the time column in list view
// THIS KEY WON'T WORK IN PRODUCTION!!!
// To make your own Google API key, follow the directions here:
// http://fullcalendar.io/docs/google_calendar/
googleCalendarApiKey: 'AIzaSyDcnW6WejpTOCffshGDDb4neIrXVUA1EAE',
// US Holidays
events: 'en.usa#holiday@group.v.calendar.google.com',
eventClick: function(arg) {
// opens events in a popup window
window.open(arg.event.url, 'google-calendar-event', 'width=700,height=600');
arg.jsEvent.preventDefault() // don't navigate in main tab
},
loading: function(bool) {
document.getElementById('loading').style.display =
bool ? 'block' : 'none';
}
});
calendar.render();
});
</script>
<style>
body {
margin: 40px 10px;
padding: 0;
font-family: Arial, Helvetica Neue, Helvetica, sans-serif;
font-size: 14px;
}
#loading {
display: none;
position: absolute;
top: 10px;
right: 10px;
}
#calendar {
max-width: 900px;
margin: 0 auto;
}
</style>
</head>
<body>
<div id='loading'>loading...</div>
<div id='calendar'></div>
</body>
</html>

View file

@ -0,0 +1,141 @@
function initThemeChooser(settings) {
var isInitialized = false;
var currentThemeSystem; // don't set this directly. use setThemeSystem
var currentStylesheetEl;
var loadingEl = document.getElementById('loading');
var systemSelectEl = document.querySelector('#theme-system-selector select');
var themeSelectWrapEls = Array.prototype.slice.call( // convert to real array
document.querySelectorAll('.selector[data-theme-system]')
);
systemSelectEl.addEventListener('change', function() {
setThemeSystem(this.value);
});
setThemeSystem(systemSelectEl.value);
themeSelectWrapEls.forEach(function(themeSelectWrapEl) {
var themeSelectEl = themeSelectWrapEl.querySelector('select');
themeSelectWrapEl.addEventListener('change', function() {
setTheme(
currentThemeSystem,
themeSelectEl.options[themeSelectEl.selectedIndex].value
);
});
});
function setThemeSystem(themeSystem) {
var selectedTheme;
currentThemeSystem = themeSystem;
themeSelectWrapEls.forEach(function(themeSelectWrapEl) {
var themeSelectEl = themeSelectWrapEl.querySelector('select');
if (themeSelectWrapEl.getAttribute('data-theme-system') === themeSystem) {
selectedTheme = themeSelectEl.options[themeSelectEl.selectedIndex].value;
themeSelectWrapEl.style.display = 'inline-block';
} else {
themeSelectWrapEl.style.display = 'none';
}
});
setTheme(themeSystem, selectedTheme);
}
function setTheme(themeSystem, themeName) {
var stylesheetUrl = generateStylesheetUrl(themeSystem, themeName);
var stylesheetEl;
function done() {
if (!isInitialized) {
isInitialized = true;
settings.init(themeSystem);
}
else {
settings.change(themeSystem);
}
showCredits(themeSystem, themeName);
}
if (stylesheetUrl) {
stylesheetEl = document.createElement('link');
stylesheetEl.setAttribute('rel', 'stylesheet');
stylesheetEl.setAttribute('href', stylesheetUrl);
document.querySelector('head').appendChild(stylesheetEl);
loadingEl.style.display = 'inline';
whenStylesheetLoaded(stylesheetEl, function() {
if (currentStylesheetEl) {
currentStylesheetEl.parentNode.removeChild(currentStylesheetEl);
}
currentStylesheetEl = stylesheetEl;
loadingEl.style.display = 'none';
done();
});
} else {
if (currentStylesheetEl) {
currentStylesheetEl.parentNode.removeChild(currentStylesheetEl);
currentStylesheetEl = null
}
done();
}
}
function generateStylesheetUrl(themeSystem, themeName) {
if (themeSystem === 'bootstrap') {
if (themeName) {
return 'https://bootswatch.com/4/' + themeName + '/bootstrap.min.css';
}
else { // the default bootstrap theme
return 'https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css';
}
}
}
function showCredits(themeSystem, themeName) {
var creditId;
if (themeSystem.match('bootstrap')) {
if (themeName) {
creditId = 'bootstrap-custom';
}
else {
creditId = 'bootstrap-standard';
}
}
Array.prototype.slice.call( // convert to real array
document.querySelectorAll('.credits')
).forEach(function(creditEl) {
if (creditEl.getAttribute('data-credit-id') === creditId) {
creditEl.style.display = 'block';
} else {
creditEl.style.display = 'none';
}
})
}
function whenStylesheetLoaded(linkNode, callback) {
var isReady = false;
function ready() {
if (!isReady) { // avoid double-call
isReady = true;
callback();
}
}
linkNode.onload = ready; // does not work cross-browser
setTimeout(ready, 2000); // max wait. also handles browsers that don't support onload
}
}

View file

@ -0,0 +1,93 @@
<!DOCTYPE html>
<html>
<head>
<meta charset='utf-8' />
<link href='../packages/core/main.css' rel='stylesheet' />
<link href='../packages/daygrid/main.css' rel='stylesheet' />
<link href='../packages/timegrid/main.css' rel='stylesheet' />
<link href='../packages/list/main.css' rel='stylesheet' />
<script src='../packages/core/main.js'></script>
<script src='../packages/interaction/main.js'></script>
<script src='../packages/daygrid/main.js'></script>
<script src='../packages/timegrid/main.js'></script>
<script src='../packages/list/main.js'></script>
<script>
document.addEventListener('DOMContentLoaded', function() {
var calendarEl = document.getElementById('calendar');
var calendar = new FullCalendar.Calendar(calendarEl, {
plugins: [ 'interaction', 'dayGrid', 'timeGrid', 'list' ],
header: {
left: 'prev,next today',
center: 'title',
right: 'dayGridMonth,timeGridWeek,timeGridDay,listWeek'
},
defaultDate: '2019-04-12',
editable: true,
navLinks: true, // can click day/week names to navigate views
eventLimit: true, // allow "more" link when too many events
events: {
url: 'php/get-events.php',
failure: function() {
document.getElementById('script-warning').style.display = 'block'
}
},
loading: function(bool) {
document.getElementById('loading').style.display =
bool ? 'block' : 'none';
}
});
calendar.render();
});
</script>
<style>
body {
margin: 0;
padding: 0;
font-family: Arial, Helvetica Neue, Helvetica, sans-serif;
font-size: 14px;
}
#script-warning {
display: none;
background: #eee;
border-bottom: 1px solid #ddd;
padding: 0 10px;
line-height: 40px;
text-align: center;
font-weight: bold;
font-size: 12px;
color: red;
}
#loading {
display: none;
position: absolute;
top: 10px;
right: 10px;
}
#calendar {
max-width: 900px;
margin: 40px auto;
padding: 0 10px;
}
</style>
</head>
<body>
<div id='script-warning'>
<code>php/get-events.php</code> must be running.
</div>
<div id='loading'>loading...</div>
<div id='calendar'></div>
</body>
</html>

View file

@ -0,0 +1,56 @@
[
{
"title": "All Day Event",
"start": "2019-04-01"
},
{
"title": "Long Event",
"start": "2019-04-07",
"end": "2019-04-10"
},
{
"id": "999",
"title": "Repeating Event",
"start": "2019-04-09T16:00:00-05:00"
},
{
"id": "999",
"title": "Repeating Event",
"start": "2019-04-16T16:00:00-05:00"
},
{
"title": "Conference",
"start": "2019-04-11",
"end": "2019-04-13"
},
{
"title": "Meeting",
"start": "2019-04-12T10:30:00-05:00",
"end": "2019-04-12T12:30:00-05:00"
},
{
"title": "Lunch",
"start": "2019-04-12T12:00:00-05:00"
},
{
"title": "Meeting",
"start": "2019-04-12T14:30:00-05:00"
},
{
"title": "Happy Hour",
"start": "2019-04-12T17:30:00-05:00"
},
{
"title": "Dinner",
"start": "2019-04-12T20:00:00"
},
{
"title": "Birthday Party",
"start": "2019-04-13T07:00:00-05:00"
},
{
"title": "Click for Google",
"url": "http://google.com/",
"start": "2019-04-28"
}
]

View file

@ -0,0 +1,118 @@
<!DOCTYPE html>
<html>
<head>
<meta charset='utf-8' />
<link href='../packages/core/main.css' rel='stylesheet' />
<link href='../packages/list/main.css' rel='stylesheet' />
<script src='../packages/core/main.js'></script>
<script src='../packages/list/main.js'></script>
<script>
document.addEventListener('DOMContentLoaded', function() {
var calendarEl = document.getElementById('calendar');
var calendar = new FullCalendar.Calendar(calendarEl, {
plugins: [ 'list' ],
header: {
left: 'prev,next today',
center: 'title',
right: 'listDay,listWeek,dayGridMonth'
},
// customize the button names,
// otherwise they'd all just say "list"
views: {
listDay: { buttonText: 'list day' },
listWeek: { buttonText: 'list week' }
},
defaultView: 'listWeek',
defaultDate: '2019-04-12',
navLinks: true, // can click day/week names to navigate views
editable: true,
eventLimit: true, // allow "more" link when too many events
events: [
{
title: 'All Day Event',
start: '2019-04-01'
},
{
title: 'Long Event',
start: '2019-04-07',
end: '2019-04-10'
},
{
groupId: 999,
title: 'Repeating Event',
start: '2019-04-09T16:00:00'
},
{
groupId: 999,
title: 'Repeating Event',
start: '2019-04-16T16:00:00'
},
{
title: 'Conference',
start: '2019-04-11',
end: '2019-04-13'
},
{
title: 'Meeting',
start: '2019-04-12T10:30:00',
end: '2019-04-12T12:30:00'
},
{
title: 'Lunch',
start: '2019-04-12T12:00:00'
},
{
title: 'Meeting',
start: '2019-04-12T14:30:00'
},
{
title: 'Happy Hour',
start: '2019-04-12T17:30:00'
},
{
title: 'Dinner',
start: '2019-04-12T20:00:00'
},
{
title: 'Birthday Party',
start: '2019-04-13T07:00:00'
},
{
title: 'Click for Google',
url: 'http://google.com/',
start: '2019-04-28'
}
]
});
calendar.render();
});
</script>
<style>
body {
margin: 40px 10px;
padding: 0;
font-family: Arial, Helvetica Neue, Helvetica, sans-serif;
font-size: 14px;
}
#calendar {
max-width: 900px;
margin: 0 auto;
}
</style>
</head>
<body>
<div id='calendar'></div>
</body>
</html>

View file

@ -0,0 +1,152 @@
<!DOCTYPE html>
<html>
<head>
<meta charset='utf-8' />
<link href='../packages/core/main.css' rel='stylesheet' />
<link href='../packages/daygrid/main.css' rel='stylesheet' />
<link href='../packages/timegrid/main.css' rel='stylesheet' />
<link href='../packages/list/main.css' rel='stylesheet' />
<script src='../packages/core/main.js'></script>
<script src='../packages/core/locales-all.js'></script>
<script src='../packages/interaction/main.js'></script>
<script src='../packages/daygrid/main.js'></script>
<script src='../packages/timegrid/main.js'></script>
<script src='../packages/list/main.js'></script>
<script>
document.addEventListener('DOMContentLoaded', function() {
var initialLocaleCode = 'en';
var localeSelectorEl = document.getElementById('locale-selector');
var calendarEl = document.getElementById('calendar');
var calendar = new FullCalendar.Calendar(calendarEl, {
plugins: [ 'interaction', 'dayGrid', 'timeGrid', 'list' ],
header: {
left: 'prev,next today',
center: 'title',
right: 'dayGridMonth,timeGridWeek,timeGridDay,listMonth'
},
defaultDate: '2019-04-12',
locale: initialLocaleCode,
buttonIcons: false, // show the prev/next text
weekNumbers: true,
navLinks: true, // can click day/week names to navigate views
editable: true,
eventLimit: true, // allow "more" link when too many events
events: [
{
title: 'All Day Event',
start: '2019-04-01'
},
{
title: 'Long Event',
start: '2019-04-07',
end: '2019-04-10'
},
{
groupId: 999,
title: 'Repeating Event',
start: '2019-04-09T16:00:00'
},
{
groupId: 999,
title: 'Repeating Event',
start: '2019-04-16T16:00:00'
},
{
title: 'Conference',
start: '2019-04-11',
end: '2019-04-13'
},
{
title: 'Meeting',
start: '2019-04-12T10:30:00',
end: '2019-04-12T12:30:00'
},
{
title: 'Lunch',
start: '2019-04-12T12:00:00'
},
{
title: 'Meeting',
start: '2019-04-12T14:30:00'
},
{
title: 'Happy Hour',
start: '2019-04-12T17:30:00'
},
{
title: 'Dinner',
start: '2019-04-12T20:00:00'
},
{
title: 'Birthday Party',
start: '2019-04-13T07:00:00'
},
{
title: 'Click for Google',
url: 'http://google.com/',
start: '2019-04-28'
}
]
});
calendar.render();
// build the locale selector's options
calendar.getAvailableLocaleCodes().forEach(function(localeCode) {
var optionEl = document.createElement('option');
optionEl.value = localeCode;
optionEl.selected = localeCode == initialLocaleCode;
optionEl.innerText = localeCode;
localeSelectorEl.appendChild(optionEl);
});
// when the selected option changes, dynamically change the calendar option
localeSelectorEl.addEventListener('change', function() {
if (this.value) {
calendar.setOption('locale', this.value);
}
});
});
</script>
<style>
body {
margin: 0;
padding: 0;
font-family: Arial, Helvetica Neue, Helvetica, sans-serif;
font-size: 14px;
}
#top {
background: #eee;
border-bottom: 1px solid #ddd;
padding: 0 10px;
line-height: 40px;
font-size: 12px;
}
#calendar {
max-width: 900px;
margin: 40px auto;
padding: 0 10px;
}
</style>
</head>
<body>
<div id='top'>
Locales:
<select id='locale-selector'></select>
</div>
<div id='calendar'></div>
</body>
</html>

View file

@ -0,0 +1,50 @@
<?php
//--------------------------------------------------------------------------------------------------
// This script reads event data from a JSON file and outputs those events which are within the range
// supplied by the "start" and "end" GET parameters.
//
// An optional "timeZone" GET parameter will force all ISO8601 date stings to a given timeZone.
//
// Requires PHP 5.2.0 or higher.
//--------------------------------------------------------------------------------------------------
// Require our Event class and datetime utilities
require dirname(__FILE__) . '/utils.php';
// Short-circuit if the client did not give us a date range.
if (!isset($_GET['start']) || !isset($_GET['end'])) {
die("Please provide a date range.");
}
// Parse the start/end parameters.
// These are assumed to be ISO8601 strings with no time nor timeZone, like "2013-12-29".
// Since no timeZone will be present, they will parsed as UTC.
$range_start = parseDateTime($_GET['start']);
$range_end = parseDateTime($_GET['end']);
// Parse the timeZone parameter if it is present.
$timeZone = null;
if (isset($_GET['timeZone'])) {
$timeZone = new DateTimeZone($_GET['timeZone']);
}
// Read and parse our events JSON file into an array of event data arrays.
$json = file_get_contents(dirname(__FILE__) . '/../json/events.json');
$input_arrays = json_decode($json, true);
// Accumulate an output array of event data arrays.
$output_arrays = array();
foreach ($input_arrays as $array) {
// Convert the input array into a useful Event object
$event = new Event($array, $timeZone);
// If the event is in-bounds, add it to the output
if ($event->isWithinDayRange($range_start, $range_end)) {
$output_arrays[] = $event->toArray();
}
}
// Send JSON to the client.
echo json_encode($output_arrays);

View file

@ -0,0 +1,9 @@
<?php
//--------------------------------------------------------------------------------------------------
// This script outputs a JSON array of all timezones (like "America/Chicago") that PHP supports.
//
// Requires PHP 5.2.0 or higher.
//--------------------------------------------------------------------------------------------------
echo json_encode(DateTimeZone::listIdentifiers());

View file

@ -0,0 +1,130 @@
<?php
//--------------------------------------------------------------------------------------------------
// Utilities for our event-fetching scripts.
//
// Requires PHP 5.2.0 or higher.
//--------------------------------------------------------------------------------------------------
// PHP will fatal error if we attempt to use the DateTime class without this being set.
date_default_timezone_set('UTC');
class Event {
// Tests whether the given ISO8601 string has a time-of-day or not
const ALL_DAY_REGEX = '/^\d{4}-\d\d-\d\d$/'; // matches strings like "2013-12-29"
public $title;
public $allDay; // a boolean
public $start; // a DateTime
public $end; // a DateTime, or null
public $properties = array(); // an array of other misc properties
// Constructs an Event object from the given array of key=>values.
// You can optionally force the timeZone of the parsed dates.
public function __construct($array, $timeZone=null) {
$this->title = $array['title'];
if (isset($array['allDay'])) {
// allDay has been explicitly specified
$this->allDay = (bool)$array['allDay'];
}
else {
// Guess allDay based off of ISO8601 date strings
$this->allDay = preg_match(self::ALL_DAY_REGEX, $array['start']) &&
(!isset($array['end']) || preg_match(self::ALL_DAY_REGEX, $array['end']));
}
if ($this->allDay) {
// If dates are allDay, we want to parse them in UTC to avoid DST issues.
$timeZone = null;
}
// Parse dates
$this->start = parseDateTime($array['start'], $timeZone);
$this->end = isset($array['end']) ? parseDateTime($array['end'], $timeZone) : null;
// Record misc properties
foreach ($array as $name => $value) {
if (!in_array($name, array('title', 'allDay', 'start', 'end'))) {
$this->properties[$name] = $value;
}
}
}
// Returns whether the date range of our event intersects with the given all-day range.
// $rangeStart and $rangeEnd are assumed to be dates in UTC with 00:00:00 time.
public function isWithinDayRange($rangeStart, $rangeEnd) {
// Normalize our event's dates for comparison with the all-day range.
$eventStart = stripTime($this->start);
if (isset($this->end)) {
$eventEnd = stripTime($this->end); // normalize
}
else {
$eventEnd = $eventStart; // consider this a zero-duration event
}
// Check if the two whole-day ranges intersect.
return $eventStart < $rangeEnd && $eventEnd >= $rangeStart;
}
// Converts this Event object back to a plain data array, to be used for generating JSON
public function toArray() {
// Start with the misc properties (don't worry, PHP won't affect the original array)
$array = $this->properties;
$array['title'] = $this->title;
// Figure out the date format. This essentially encodes allDay into the date string.
if ($this->allDay) {
$format = 'Y-m-d'; // output like "2013-12-29"
}
else {
$format = 'c'; // full ISO8601 output, like "2013-12-29T09:00:00+08:00"
}
// Serialize dates into strings
$array['start'] = $this->start->format($format);
if (isset($this->end)) {
$array['end'] = $this->end->format($format);
}
return $array;
}
}
// Date Utilities
//----------------------------------------------------------------------------------------------
// Parses a string into a DateTime object, optionally forced into the given timeZone.
function parseDateTime($string, $timeZone=null) {
$date = new DateTime(
$string,
$timeZone ? $timeZone : new DateTimeZone('UTC')
// Used only when the string is ambiguous.
// Ignored if string has a timeZone offset in it.
);
if ($timeZone) {
// If our timeZone was ignored above, force it.
$date->setTimezone($timeZone);
}
return $date;
}
// Takes the year/month/date values of the given DateTime and converts them to a new DateTime,
// but in UTC.
function stripTime($datetime) {
return new DateTime($datetime->format('Y-m-d'));
}

View file

@ -0,0 +1,73 @@
<!DOCTYPE html>
<html>
<head>
<meta charset='utf-8' />
<link href='../packages/core/main.css' rel='stylesheet' />
<link href='../packages/daygrid/main.css' rel='stylesheet' />
<link href='../packages/timegrid/main.css' rel='stylesheet' />
<link href='../packages/list/main.css' rel='stylesheet' />
<script src='../vendor/rrule.js'></script>
<script src='../packages/core/main.js'></script>
<script src='../packages/interaction/main.js'></script>
<script src='../packages/daygrid/main.js'></script>
<script src='../packages/timegrid/main.js'></script>
<script src='../packages/list/main.js'></script>
<script src='../packages/rrule/main.js'></script>
<script>
document.addEventListener('DOMContentLoaded', function() {
var calendarEl = document.getElementById('calendar');
var calendar = new FullCalendar.Calendar(calendarEl, {
plugins: [ 'interaction', 'dayGrid', 'timeGrid', 'list', 'rrule' ],
header: {
left: 'prev,next today',
center: 'title',
right: 'dayGridMonth,timeGridWeek,timeGridDay,listMonth'
},
defaultDate: '2019-04-12',
editable: true,
events: [
{
title: 'rrule event',
rrule: {
dtstart: '2019-04-09T13:00:00',
// until: '2019-04-01',
freq: 'weekly'
},
duration: '02:00'
}
],
eventClick: function(arg) {
if (confirm('delete event?')) {
arg.event.remove()
}
}
});
calendar.render();
});
</script>
<style>
body {
margin: 40px 10px;
padding: 0;
font-family: Arial, Helvetica Neue, Helvetica, sans-serif;
font-size: 14px;
}
#calendar {
max-width: 900px;
margin: 0 auto;
}
</style>
</head>
<body>
<div id='calendar'></div>
</body>
</html>

View file

@ -0,0 +1,125 @@
<!DOCTYPE html>
<html>
<head>
<meta charset='utf-8' />
<link href='../packages/core/main.css' rel='stylesheet' />
<link href='../packages/daygrid/main.css' rel='stylesheet' />
<link href='../packages/timegrid/main.css' rel='stylesheet' />
<script src='../packages/core/main.js'></script>
<script src='../packages/interaction/main.js'></script>
<script src='../packages/daygrid/main.js'></script>
<script src='../packages/timegrid/main.js'></script>
<script>
document.addEventListener('DOMContentLoaded', function() {
var calendarEl = document.getElementById('calendar');
var calendar = new FullCalendar.Calendar(calendarEl, {
plugins: [ 'interaction', 'dayGrid', 'timeGrid' ],
header: {
left: 'prev,next today',
center: 'title',
right: 'dayGridMonth,timeGridWeek,timeGridDay'
},
defaultDate: '2019-04-12',
navLinks: true, // can click day/week names to navigate views
selectable: true,
selectMirror: true,
select: function(arg) {
var title = prompt('Event Title:');
if (title) {
calendar.addEvent({
title: title,
start: arg.start,
end: arg.end,
allDay: arg.allDay
})
}
calendar.unselect()
},
editable: true,
eventLimit: true, // allow "more" link when too many events
events: [
{
title: 'All Day Event',
start: '2019-04-01'
},
{
title: 'Long Event',
start: '2019-04-07',
end: '2019-04-10'
},
{
groupId: 999,
title: 'Repeating Event',
start: '2019-04-09T16:00:00'
},
{
groupId: 999,
title: 'Repeating Event',
start: '2019-04-16T16:00:00'
},
{
title: 'Conference',
start: '2019-04-11',
end: '2019-04-13'
},
{
title: 'Meeting',
start: '2019-04-12T10:30:00',
end: '2019-04-12T12:30:00'
},
{
title: 'Lunch',
start: '2019-04-12T12:00:00'
},
{
title: 'Meeting',
start: '2019-04-12T14:30:00'
},
{
title: 'Happy Hour',
start: '2019-04-12T17:30:00'
},
{
title: 'Dinner',
start: '2019-04-12T20:00:00'
},
{
title: 'Birthday Party',
start: '2019-04-13T07:00:00'
},
{
title: 'Click for Google',
url: 'http://google.com/',
start: '2019-04-28'
}
]
});
calendar.render();
});
</script>
<style>
body {
margin: 40px 10px;
padding: 0;
font-family: Arial, Helvetica Neue, Helvetica, sans-serif;
font-size: 14px;
}
#calendar {
max-width: 900px;
margin: 0 auto;
}
</style>
</head>
<body>
<div id='calendar'></div>
</body>
</html>

View file

@ -0,0 +1,215 @@
<!DOCTYPE html>
<html>
<head>
<meta charset='utf-8' />
<link href='https://use.fontawesome.com/releases/v5.0.6/css/all.css' rel='stylesheet'>
<link href='../packages/core/main.css' rel='stylesheet' />
<link href='../packages/bootstrap/main.css' rel='stylesheet' />
<link href='../packages/timegrid/main.css' rel='stylesheet' />
<link href='../packages/daygrid/main.css' rel='stylesheet' />
<link href='../packages/list/main.css' rel='stylesheet' />
<script src='../packages/core/main.js'></script>
<script src='../packages/interaction/main.js'></script>
<script src='../packages/bootstrap/main.js'></script>
<script src='../packages/daygrid/main.js'></script>
<script src='../packages/timegrid/main.js'></script>
<script src='../packages/list/main.js'></script>
<script src='js/theme-chooser.js'></script>
<script>
document.addEventListener('DOMContentLoaded', function() {
var calendarEl = document.getElementById('calendar');
var calendar;
initThemeChooser({
init: function(themeSystem) {
calendar = new FullCalendar.Calendar(calendarEl, {
plugins: [ 'bootstrap', 'interaction', 'dayGrid', 'timeGrid', 'list' ],
themeSystem: themeSystem,
header: {
left: 'prev,next today',
center: 'title',
right: 'dayGridMonth,timeGridWeek,timeGridDay,listMonth'
},
defaultDate: '2019-04-12',
weekNumbers: true,
navLinks: true, // can click day/week names to navigate views
editable: true,
eventLimit: true, // allow "more" link when too many events
events: [
{
title: 'All Day Event',
start: '2019-04-01'
},
{
title: 'Long Event',
start: '2019-04-07',
end: '2019-04-10'
},
{
groupId: 999,
title: 'Repeating Event',
start: '2019-04-09T16:00:00'
},
{
groupId: 999,
title: 'Repeating Event',
start: '2019-04-16T16:00:00'
},
{
title: 'Conference',
start: '2019-04-11',
end: '2019-04-13'
},
{
title: 'Meeting',
start: '2019-04-12T10:30:00',
end: '2019-04-12T12:30:00'
},
{
title: 'Lunch',
start: '2019-04-12T12:00:00'
},
{
title: 'Meeting',
start: '2019-04-12T14:30:00'
},
{
title: 'Happy Hour',
start: '2019-04-12T17:30:00'
},
{
title: 'Dinner',
start: '2019-04-12T20:00:00'
},
{
title: 'Birthday Party',
start: '2019-04-13T07:00:00'
},
{
title: 'Click for Google',
url: 'http://google.com/',
start: '2019-04-28'
}
]
});
calendar.render();
},
change: function(themeSystem) {
calendar.setOption('themeSystem', themeSystem);
}
});
});
</script>
<style>
body {
margin: 0;
padding: 0;
font-size: 14px;
}
#top,
#calendar.fc-unthemed {
font-family: Arial, Helvetica Neue, Helvetica, sans-serif;
}
#top {
background: #eee;
border-bottom: 1px solid #ddd;
padding: 0 10px;
line-height: 40px;
font-size: 12px;
color: #000;
}
#top .selector {
display: inline-block;
margin-right: 10px;
}
#top select {
font: inherit; /* mock what Boostrap does, don't compete */
}
.left { float: left }
.right { float: right }
.clear { clear: both }
#calendar {
max-width: 900px;
margin: 40px auto;
padding: 0 10px;
}
</style>
</head>
<body>
<div id='top'>
<div class='left'>
<div id='theme-system-selector' class='selector'>
Theme System:
<select>
<option value='bootstrap' selected>Bootstrap 4</option>
<option value='standard'>unthemed</option>
</select>
</div>
<div data-theme-system="bootstrap" class='selector' style='display:none'>
Theme Name:
<select>
<option value='' selected>Default</option>
<option value='cerulean'>Cerulean</option>
<option value='cosmo'>Cosmo</option>
<option value='cyborg'>Cyborg</option>
<option value='darkly'>Darkly</option>
<option value='flatly'>Flatly</option>
<option value='journal'>Journal</option>
<option value='litera'>Litera</option>
<option value='lumen'>Lumen</option>
<option value='lux'>Lux</option>
<option value='materia'>Materia</option>
<option value='minty'>Minty</option>
<option value='pulse'>Pulse</option>
<option value='sandstone'>Sandstone</option>
<option value='simplex'>Simplex</option>
<option value='sketchy'>Sketchy</option>
<option value='slate'>Slate</option>
<option value='solar'>Solar</option>
<option value='spacelab'>Spacelab</option>
<option value='superhero'>Superhero</option>
<option value='united'>United</option>
<option value='yeti'>Yeti</option>
</select>
</div>
<span id='loading' style='display:none'>loading theme...</span>
</div>
<div class='right'>
<span class='credits' data-credit-id='bootstrap-standard' style='display:none'>
<a href='https://getbootstrap.com/docs/3.3/' target='_blank'>Theme by Bootstrap</a>
</span>
<span class='credits' data-credit-id='bootstrap-custom' style='display:none'>
<a href='https://bootswatch.com/' target='_blank'>Theme by Bootswatch</a>
</span>
</div>
<div class='clear'></div>
</div>
<div id='calendar'></div>
</body>
</html>

View file

@ -0,0 +1,145 @@
<!DOCTYPE html>
<html>
<head>
<meta charset='utf-8' />
<link href='../packages/core/main.css' rel='stylesheet' />
<link href='../packages/daygrid/main.css' rel='stylesheet' />
<link href='../packages/timegrid/main.css' rel='stylesheet' />
<link href='../packages/list/main.css' rel='stylesheet' />
<script src='../packages/core/main.js'></script>
<script src='../packages/interaction/main.js'></script>
<script src='../packages/daygrid/main.js'></script>
<script src='../packages/timegrid/main.js'></script>
<script src='../packages/list/main.js'></script>
<script>
document.addEventListener('DOMContentLoaded', function() {
var initialTimeZone = 'local';
var timeZoneSelectorEl = document.getElementById('time-zone-selector');
var loadingEl = document.getElementById('loading');
var calendarEl = document.getElementById('calendar');
var calendar = new FullCalendar.Calendar(calendarEl, {
plugins: [ 'interaction', 'dayGrid', 'timeGrid', 'list' ],
timeZone: initialTimeZone,
header: {
left: 'prev,next today',
center: 'title',
right: 'dayGridMonth,timeGridWeek,timeGridDay,listWeek'
},
defaultDate: '2019-04-12',
navLinks: true, // can click day/week names to navigate views
editable: true,
selectable: true,
eventLimit: true, // allow "more" link when too many events
events: {
url: 'php/get-events.php',
failure: function() {
document.getElementById('script-warning').style.display = 'inline'; // show
}
},
loading: function(bool) {
if (bool) {
loadingEl.style.display = 'inline'; // show
} else {
loadingEl.style.display = 'none'; // hide
}
},
eventTimeFormat: { hour: 'numeric', minute: '2-digit', timeZoneName: 'short' },
dateClick: function(arg) {
console.log('dateClick', calendar.formatIso(arg.date));
},
select: function(arg) {
console.log('select', calendar.formatIso(arg.start), calendar.formatIso(arg.end));
}
});
calendar.render();
// load the list of available timezones, build the <select> options
// it's HIGHLY recommended to use a different library for network requests, not this internal util func
FullCalendar.requestJson('GET', 'php/get-time-zones.php', {}, function(timeZones) {
timeZones.forEach(function(timeZone) {
var optionEl;
if (timeZone !== 'UTC') { // UTC is already in the list
optionEl = document.createElement('option');
optionEl.value = timeZone;
optionEl.innerText = timeZone;
timeZoneSelectorEl.appendChild(optionEl);
}
});
}, function() {
// TODO: handle error
});
// when the timezone selector changes, dynamically change the calendar option
timeZoneSelectorEl.addEventListener('change', function() {
calendar.setOption('timeZone', this.value);
});
});
</script>
<style>
body {
margin: 0;
padding: 0;
font-family: Arial, Helvetica Neue, Helvetica, sans-serif;
font-size: 14px;
}
#top {
background: #eee;
border-bottom: 1px solid #ddd;
padding: 0 10px;
line-height: 40px;
font-size: 12px;
}
.left { float: left }
.right { float: right }
.clear { clear: both }
#script-warning, #loading { display: none }
#script-warning { font-weight: bold; color: red }
#calendar {
max-width: 900px;
margin: 40px auto;
padding: 0 10px;
}
.tzo {
color: #000;
}
</style>
</head>
<body>
<div id='top'>
<div class='left'>
Timezone:
<select id='time-zone-selector'>
<option value='local' selected>local</option>
<option value='UTC'>UTC</option>
</select>
</div>
<div class='right'>
<span id='loading'>loading...</span>
<span id='script-warning'><code>php/get-events.php</code> must be running.</span>
</div>
<div class='clear'></div>
</div>
<div id='calendar'></div>
</body>
</html>

View file

@ -0,0 +1,113 @@
<!DOCTYPE html>
<html>
<head>
<meta charset='utf-8' />
<link href='../packages/core/main.css' rel='stylesheet' />
<link href='../packages/daygrid/main.css' rel='stylesheet' />
<link href='../packages/timegrid/main.css' rel='stylesheet' />
<link href='../packages/list/main.css' rel='stylesheet' />
<script src='../packages/core/main.js'></script>
<script src='../packages/interaction/main.js'></script>
<script src='../packages/daygrid/main.js'></script>
<script src='../packages/timegrid/main.js'></script>
<script src='../packages/list/main.js'></script>
<script>
document.addEventListener('DOMContentLoaded', function() {
var calendarEl = document.getElementById('calendar');
var calendar = new FullCalendar.Calendar(calendarEl, {
plugins: [ 'dayGrid', 'timeGrid', 'list', 'interaction' ],
header: {
left: 'prev,next today',
center: 'title',
right: 'dayGridMonth,timeGridWeek,timeGridDay,listWeek'
},
defaultDate: '2019-04-12',
navLinks: true, // can click day/week names to navigate views
editable: true,
eventLimit: true, // allow "more" link when too many events
events: [
{
title: 'All Day Event',
start: '2019-04-01',
},
{
title: 'Long Event',
start: '2019-04-07',
end: '2019-04-10'
},
{
groupId: 999,
title: 'Repeating Event',
start: '2019-04-09T16:00:00'
},
{
groupId: 999,
title: 'Repeating Event',
start: '2019-04-16T16:00:00'
},
{
title: 'Conference',
start: '2019-04-11',
end: '2019-04-13'
},
{
title: 'Meeting',
start: '2019-04-12T10:30:00',
end: '2019-04-12T12:30:00'
},
{
title: 'Lunch',
start: '2019-04-12T12:00:00'
},
{
title: 'Meeting',
start: '2019-04-12T14:30:00'
},
{
title: 'Happy Hour',
start: '2019-04-12T17:30:00'
},
{
title: 'Dinner',
start: '2019-04-12T20:00:00'
},
{
title: 'Birthday Party',
start: '2019-04-13T07:00:00'
},
{
title: 'Click for Google',
url: 'http://google.com/',
start: '2019-04-28'
}
]
});
calendar.render();
});
</script>
<style>
body {
margin: 40px 10px;
padding: 0;
font-family: Arial, Helvetica Neue, Helvetica, sans-serif;
font-size: 14px;
}
#calendar {
max-width: 900px;
margin: 0 auto;
}
</style>
</head>
<body>
<div id='calendar'></div>
</body>
</html>

View file

@ -0,0 +1,118 @@
<!DOCTYPE html>
<html>
<head>
<meta charset='utf-8' />
<link href='../packages/core/main.css' rel='stylesheet' />
<link href='../packages/daygrid/main.css' rel='stylesheet' />
<link href='../packages/timegrid/main.css' rel='stylesheet' />
<link href='../packages/list/main.css' rel='stylesheet' />
<script src='../packages/core/main.js'></script>
<script src='../packages/interaction/main.js'></script>
<script src='../packages/daygrid/main.js'></script>
<script src='../packages/timegrid/main.js'></script>
<script src='../packages/list/main.js'></script>
<script>
document.addEventListener('DOMContentLoaded', function() {
var calendarEl = document.getElementById('calendar');
var calendar = new FullCalendar.Calendar(calendarEl, {
plugins: [ 'interaction', 'dayGrid', 'timeGrid', 'list' ],
header: {
left: 'prev,next today',
center: 'title',
right: 'dayGridMonth,timeGridWeek,timeGridDay,listWeek'
},
defaultDate: '2019-04-12',
navLinks: true, // can click day/week names to navigate views
weekNumbers: true,
weekNumbersWithinDays: true,
weekNumberCalculation: 'ISO',
editable: true,
eventLimit: true, // allow "more" link when too many events
events: [
{
title: 'All Day Event',
start: '2019-04-01'
},
{
title: 'Long Event',
start: '2019-04-07',
end: '2019-04-10'
},
{
groupId: 999,
title: 'Repeating Event',
start: '2019-04-09T16:00:00'
},
{
groupId: 999,
title: 'Repeating Event',
start: '2019-04-16T16:00:00'
},
{
title: 'Conference',
start: '2019-04-11',
end: '2019-04-13'
},
{
title: 'Meeting',
start: '2019-04-12T10:30:00',
end: '2019-04-12T12:30:00'
},
{
title: 'Lunch',
start: '2019-04-12T12:00:00'
},
{
title: 'Meeting',
start: '2019-04-12T14:30:00'
},
{
title: 'Happy Hour',
start: '2019-04-12T17:30:00'
},
{
title: 'Dinner',
start: '2019-04-12T20:00:00'
},
{
title: 'Birthday Party',
start: '2019-04-13T07:00:00'
},
{
title: 'Click for Google',
url: 'http://google.com/',
start: '2019-04-28'
}
]
});
calendar.render();
});
</script>
<style>
body {
margin: 40px 10px;
padding: 0;
font-family: Arial, Helvetica Neue, Helvetica, sans-serif;
font-size: 14px;
}
#calendar {
max-width: 900px;
margin: 0 auto;
}
</style>
</head>
<body>
<div id='calendar'></div>
</body>
</html>

View file

@ -0,0 +1,33 @@
/*!
FullCalendar Bootstrap Plugin v4.0.2
Docs & License: https://fullcalendar.io/
(c) 2019 Adam Shaw
*/
.fc.fc-bootstrap a {
text-decoration: none; }
.fc.fc-bootstrap a[data-goto]:hover {
text-decoration: underline; }
.fc-bootstrap hr.fc-divider {
border-color: inherit; }
.fc-bootstrap .fc-today.alert {
border-radius: 0; }
.fc-bootstrap a.fc-event:not([href]):not([tabindex]) {
color: #fff; }
.fc-bootstrap .fc-popover.card {
position: absolute; }
/* Popover
--------------------------------------------------------------------------------------------------*/
.fc-bootstrap .fc-popover .card-body {
padding: 0; }
/* TimeGrid Slats (lines that run horizontally)
--------------------------------------------------------------------------------------------------*/
.fc-bootstrap .fc-time-grid .fc-slats table {
/* some themes have background color. see through to slats */
background: none; }

View file

@ -0,0 +1,90 @@
/*!
FullCalendar Bootstrap Plugin v4.0.2
Docs & License: https://fullcalendar.io/
(c) 2019 Adam Shaw
*/
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@fullcalendar/core')) :
typeof define === 'function' && define.amd ? define(['exports', '@fullcalendar/core'], factory) :
(global = global || self, factory(global.FullCalendarBootstrap = {}, global.FullCalendar));
}(this, function (exports, core) { 'use strict';
/*! *****************************************************************************
Copyright (c) Microsoft Corporation. All rights reserved.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
this file except in compliance with the License. You may obtain a copy of the
License at http://www.apache.org/licenses/LICENSE-2.0
THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED
WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,
MERCHANTABLITY OR NON-INFRINGEMENT.
See the Apache Version 2.0 License for specific language governing permissions
and limitations under the License.
***************************************************************************** */
/* global Reflect, Promise */
var extendStatics = function(d, b) {
extendStatics = Object.setPrototypeOf ||
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
return extendStatics(d, b);
};
function __extends(d, b) {
extendStatics(d, b);
function __() { this.constructor = d; }
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
}
var BootstrapTheme = /** @class */ (function (_super) {
__extends(BootstrapTheme, _super);
function BootstrapTheme() {
return _super !== null && _super.apply(this, arguments) || this;
}
return BootstrapTheme;
}(core.Theme));
BootstrapTheme.prototype.classes = {
widget: 'fc-bootstrap',
tableGrid: 'table-bordered',
tableList: 'table',
tableListHeading: 'table-active',
buttonGroup: 'btn-group',
button: 'btn btn-primary',
buttonActive: 'active',
today: 'alert alert-info',
popover: 'card card-primary',
popoverHeader: 'card-header',
popoverContent: 'card-body',
// day grid
// for left/right border color when border is inset from edges (all-day in timeGrid view)
// avoid `table` class b/c don't want margins/padding/structure. only border color.
headerRow: 'table-bordered',
dayRow: 'table-bordered',
// list view
listView: 'card card-primary'
};
BootstrapTheme.prototype.baseIconClass = 'fa';
BootstrapTheme.prototype.iconClasses = {
close: 'fa-times',
prev: 'fa-chevron-left',
next: 'fa-chevron-right',
prevYear: 'fa-angle-double-left',
nextYear: 'fa-angle-double-right'
};
BootstrapTheme.prototype.iconOverrideOption = 'bootstrapFontAwesome';
BootstrapTheme.prototype.iconOverrideCustomButtonOption = 'bootstrapFontAwesome';
BootstrapTheme.prototype.iconOverridePrefix = 'fa-';
var main = core.createPlugin({
themeClasses: {
bootstrap: BootstrapTheme
}
});
exports.BootstrapTheme = BootstrapTheme;
exports.default = main;
Object.defineProperty(exports, '__esModule', { value: true });
}));

View file

@ -0,0 +1,5 @@
/*!
FullCalendar Bootstrap Plugin v4.0.2
Docs & License: https://fullcalendar.io/
(c) 2019 Adam Shaw
*/.fc.fc-bootstrap a{text-decoration:none}.fc.fc-bootstrap a[data-goto]:hover{text-decoration:underline}.fc-bootstrap hr.fc-divider{border-color:inherit}.fc-bootstrap .fc-today.alert{border-radius:0}.fc-bootstrap a.fc-event:not([href]):not([tabindex]){color:#fff}.fc-bootstrap .fc-popover.card{position:absolute}.fc-bootstrap .fc-popover .card-body{padding:0}.fc-bootstrap .fc-time-grid .fc-slats table{background:0 0}

View file

@ -0,0 +1,20 @@
/*!
FullCalendar Bootstrap Plugin v4.0.2
Docs & License: https://fullcalendar.io/
(c) 2019 Adam Shaw
*/
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("@fullcalendar/core")):"function"==typeof define&&define.amd?define(["exports","@fullcalendar/core"],t):(e=e||self,t(e.FullCalendarBootstrap={},e.FullCalendar))}(this,function(e,t){"use strict";function o(e,t){function o(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(o.prototype=t.prototype,new o)}/*! *****************************************************************************
Copyright (c) Microsoft Corporation. All rights reserved.
Licensed under the Apache License, Version 2.0 (the "License"); you may not use
this file except in compliance with the License. You may obtain a copy of the
License at http://www.apache.org/licenses/LICENSE-2.0
THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED
WARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,
MERCHANTABLITY OR NON-INFRINGEMENT.
See the Apache Version 2.0 License for specific language governing permissions
and limitations under the License.
***************************************************************************** */
var r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var o in t)t.hasOwnProperty(o)&&(e[o]=t[o])})(e,t)},a=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return o(t,e),t}(t.Theme);a.prototype.classes={widget:"fc-bootstrap",tableGrid:"table-bordered",tableList:"table",tableListHeading:"table-active",buttonGroup:"btn-group",button:"btn btn-primary",buttonActive:"active",today:"alert alert-info",popover:"card card-primary",popoverHeader:"card-header",popoverContent:"card-body",headerRow:"table-bordered",dayRow:"table-bordered",listView:"card card-primary"},a.prototype.baseIconClass="fa",a.prototype.iconClasses={close:"fa-times",prev:"fa-chevron-left",next:"fa-chevron-right",prevYear:"fa-angle-double-left",nextYear:"fa-angle-double-right"},a.prototype.iconOverrideOption="bootstrapFontAwesome",a.prototype.iconOverrideCustomButtonOption="bootstrapFontAwesome",a.prototype.iconOverridePrefix="fa-";var n=t.createPlugin({themeClasses:{bootstrap:a}});e.BootstrapTheme=a,e.default=n,Object.defineProperty(e,"__esModule",{value:!0})});

File diff suppressed because it is too large Load diff

File diff suppressed because one or more lines are too long

View file

@ -0,0 +1,30 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.af = factory()));
}(this, function () { 'use strict';
var af = {
code: "af",
week: {
dow: 1,
doy: 4 // Die week wat die 4de Januarie bevat is die eerste week van die jaar.
},
buttonText: {
prev: "Vorige",
next: "Volgende",
today: "Vandag",
year: "Jaar",
month: "Maand",
week: "Week",
day: "Dag",
list: "Agenda"
},
allDayHtml: "Heeldag",
eventLimitText: "Addisionele",
noEventsMessage: "Daar is geen gebeurtenisse nie"
};
return af;
}));

View file

@ -0,0 +1,31 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales['ar-dz'] = factory()));
}(this, function () { 'use strict';
var arDz = {
code: "ar-dz",
week: {
dow: 0,
doy: 4 // The week that contains Jan 1st is the first week of the year.
},
dir: 'rtl',
buttonText: {
prev: "السابق",
next: "التالي",
today: "اليوم",
month: "شهر",
week: "أسبوع",
day: "يوم",
list: "أجندة"
},
weekLabel: "أسبوع",
allDayText: "اليوم كله",
eventLimitText: "أخرى",
noEventsMessage: "أي أحداث لعرض"
};
return arDz;
}));

View file

@ -0,0 +1,31 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales['ar-kw'] = factory()));
}(this, function () { 'use strict';
var arKw = {
code: "ar-kw",
week: {
dow: 0,
doy: 12 // The week that contains Jan 1st is the first week of the year.
},
dir: 'rtl',
buttonText: {
prev: "السابق",
next: "التالي",
today: "اليوم",
month: "شهر",
week: "أسبوع",
day: "يوم",
list: "أجندة"
},
weekLabel: "أسبوع",
allDayText: "اليوم كله",
eventLimitText: "أخرى",
noEventsMessage: "أي أحداث لعرض"
};
return arKw;
}));

View file

@ -0,0 +1,31 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales['ar-ly'] = factory()));
}(this, function () { 'use strict';
var arLy = {
code: "ar-ly",
week: {
dow: 6,
doy: 12 // The week that contains Jan 1st is the first week of the year.
},
dir: 'rtl',
buttonText: {
prev: "السابق",
next: "التالي",
today: "اليوم",
month: "شهر",
week: "أسبوع",
day: "يوم",
list: "أجندة"
},
weekLabel: "أسبوع",
allDayText: "اليوم كله",
eventLimitText: "أخرى",
noEventsMessage: "أي أحداث لعرض"
};
return arLy;
}));

View file

@ -0,0 +1,31 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales['ar-ma'] = factory()));
}(this, function () { 'use strict';
var arMa = {
code: "ar-ma",
week: {
dow: 6,
doy: 12 // The week that contains Jan 1st is the first week of the year.
},
dir: 'rtl',
buttonText: {
prev: "السابق",
next: "التالي",
today: "اليوم",
month: "شهر",
week: "أسبوع",
day: "يوم",
list: "أجندة"
},
weekLabel: "أسبوع",
allDayText: "اليوم كله",
eventLimitText: "أخرى",
noEventsMessage: "أي أحداث لعرض"
};
return arMa;
}));

View file

@ -0,0 +1,31 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales['ar-sa'] = factory()));
}(this, function () { 'use strict';
var arSa = {
code: "ar-sa",
week: {
dow: 0,
doy: 6 // The week that contains Jan 1st is the first week of the year.
},
dir: 'rtl',
buttonText: {
prev: "السابق",
next: "التالي",
today: "اليوم",
month: "شهر",
week: "أسبوع",
day: "يوم",
list: "أجندة"
},
weekLabel: "أسبوع",
allDayText: "اليوم كله",
eventLimitText: "أخرى",
noEventsMessage: "أي أحداث لعرض"
};
return arSa;
}));

View file

@ -0,0 +1,31 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales['ar-tn'] = factory()));
}(this, function () { 'use strict';
var arTn = {
code: "ar-tn",
week: {
dow: 1,
doy: 4 // The week that contains Jan 4th is the first week of the year.
},
dir: 'rtl',
buttonText: {
prev: "السابق",
next: "التالي",
today: "اليوم",
month: "شهر",
week: "أسبوع",
day: "يوم",
list: "أجندة"
},
weekLabel: "أسبوع",
allDayText: "اليوم كله",
eventLimitText: "أخرى",
noEventsMessage: "أي أحداث لعرض"
};
return arTn;
}));

View file

@ -0,0 +1,31 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.ar = factory()));
}(this, function () { 'use strict';
var ar = {
code: "ar",
week: {
dow: 6,
doy: 12 // The week that contains Jan 1st is the first week of the year.
},
dir: 'rtl',
buttonText: {
prev: "السابق",
next: "التالي",
today: "اليوم",
month: "شهر",
week: "أسبوع",
day: "يوم",
list: "أجندة"
},
weekLabel: "أسبوع",
allDayText: "اليوم كله",
eventLimitText: "أخرى",
noEventsMessage: "أي أحداث لعرض"
};
return ar;
}));

View file

@ -0,0 +1,31 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.bg = factory()));
}(this, function () { 'use strict';
var bg = {
code: "bg",
week: {
dow: 1,
doy: 7 // The week that contains Jan 1st is the first week of the year.
},
buttonText: {
prev: "назад",
next: "напред",
today: "днес",
month: "Месец",
week: "Седмица",
day: "Ден",
list: "График"
},
allDayText: "Цял ден",
eventLimitText: function (n) {
return "+още " + n;
},
noEventsMessage: "Няма събития за показване"
};
return bg;
}));

View file

@ -0,0 +1,32 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.bs = factory()));
}(this, function () { 'use strict';
var bs = {
code: "bs",
week: {
dow: 1,
doy: 7 // The week that contains Jan 1st is the first week of the year.
},
buttonText: {
prev: "Prošli",
next: "Sljedeći",
today: "Danas",
month: "Mjesec",
week: "Sedmica",
day: "Dan",
list: "Raspored"
},
weekLabel: "Sed",
allDayText: "Cijeli dan",
eventLimitText: function (n) {
return "+ još " + n;
},
noEventsMessage: "Nema događaja za prikazivanje"
};
return bs;
}));

View file

@ -0,0 +1,30 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.ca = factory()));
}(this, function () { 'use strict';
var ca = {
code: "ca",
week: {
dow: 1,
doy: 4 // The week that contains Jan 4th is the first week of the year.
},
buttonText: {
prev: "Anterior",
next: "Següent",
today: "Avui",
month: "Mes",
week: "Setmana",
day: "Dia",
list: "Agenda"
},
weekLabel: "Set",
allDayText: "Tot el dia",
eventLimitText: "més",
noEventsMessage: "No hi ha esdeveniments per mostrar"
};
return ca;
}));

View file

@ -0,0 +1,32 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.cs = factory()));
}(this, function () { 'use strict';
var cs = {
code: "cs",
week: {
dow: 1,
doy: 4 // The week that contains Jan 4th is the first week of the year.
},
buttonText: {
prev: "Dříve",
next: "Později",
today: "Nyní",
month: "Měsíc",
week: "Týden",
day: "Den",
list: "Agenda"
},
weekLabel: "Týd",
allDayText: "Celý den",
eventLimitText: function (n) {
return "+další: " + n;
},
noEventsMessage: "Žádné akce k zobrazení"
};
return cs;
}));

View file

@ -0,0 +1,30 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.da = factory()));
}(this, function () { 'use strict';
var da = {
code: "da",
week: {
dow: 1,
doy: 4 // The week that contains Jan 4th is the first week of the year.
},
buttonText: {
prev: "Forrige",
next: "Næste",
today: "Idag",
month: "Måned",
week: "Uge",
day: "Dag",
list: "Agenda"
},
weekLabel: "Uge",
allDayText: "Hele dagen",
eventLimitText: "flere",
noEventsMessage: "Ingen arrangementer at vise"
};
return da;
}));

View file

@ -0,0 +1,33 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.de = factory()));
}(this, function () { 'use strict';
var de = {
code: "de",
week: {
dow: 1,
doy: 4 // The week that contains Jan 4th is the first week of the year.
},
buttonText: {
prev: "Zurück",
next: "Vor",
today: "Heute",
year: "Jahr",
month: "Monat",
week: "Woche",
day: "Tag",
list: "Terminübersicht"
},
weekLabel: "KW",
allDayText: "Ganztägig",
eventLimitText: function (n) {
return "+ weitere " + n;
},
noEventsMessage: "Keine Ereignisse anzuzeigen"
};
return de;
}));

View file

@ -0,0 +1,30 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.el = factory()));
}(this, function () { 'use strict';
var el = {
code: "el",
week: {
dow: 1,
doy: 4 // The week that contains Jan 4st is the first week of the year.
},
buttonText: {
prev: "Προηγούμενος",
next: "Επόμενος",
today: "Σήμερα",
month: "Μήνας",
week: "Εβδομάδα",
day: "Ημέρα",
list: "Ατζέντα"
},
weekLabel: "Εβδ",
allDayText: "Ολοήμερο",
eventLimitText: "περισσότερα",
noEventsMessage: "Δεν υπάρχουν γεγονότα για να εμφανιστεί"
};
return el;
}));

View file

@ -0,0 +1,17 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales['en-au'] = factory()));
}(this, function () { 'use strict';
var enAu = {
code: "en-au",
week: {
dow: 1,
doy: 4 // The week that contains Jan 4th is the first week of the year.
}
};
return enAu;
}));

View file

@ -0,0 +1,17 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales['en-gb'] = factory()));
}(this, function () { 'use strict';
var enGb = {
code: "en-gb",
week: {
dow: 1,
doy: 4 // The week that contains Jan 4th is the first week of the year.
}
};
return enGb;
}));

View file

@ -0,0 +1,17 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales['en-nz'] = factory()));
}(this, function () { 'use strict';
var enNz = {
code: "en-nz",
week: {
dow: 1,
doy: 4 // The week that contains Jan 4th is the first week of the year.
}
};
return enNz;
}));

View file

@ -0,0 +1,30 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales['es-us'] = factory()));
}(this, function () { 'use strict';
var esUs = {
code: "es",
week: {
dow: 0,
doy: 6 // The week that contains Jan 1st is the first week of the year.
},
buttonText: {
prev: "Ant",
next: "Sig",
today: "Hoy",
month: "Mes",
week: "Semana",
day: "Día",
list: "Agenda"
},
weekLabel: "Sm",
allDayHtml: "Todo<br/>el día",
eventLimitText: "más",
noEventsMessage: "No hay eventos para mostrar"
};
return esUs;
}));

View file

@ -0,0 +1,30 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.es = factory()));
}(this, function () { 'use strict';
var es = {
code: "es",
week: {
dow: 1,
doy: 4 // The week that contains Jan 4th is the first week of the year.
},
buttonText: {
prev: "Ant",
next: "Sig",
today: "Hoy",
month: "Mes",
week: "Semana",
day: "Día",
list: "Agenda"
},
weekLabel: "Sm",
allDayHtml: "Todo<br/>el día",
eventLimitText: "más",
noEventsMessage: "No hay eventos para mostrar"
};
return es;
}));

View file

@ -0,0 +1,32 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.et = factory()));
}(this, function () { 'use strict';
var et = {
code: "et",
week: {
dow: 1,
doy: 4 // The week that contains Jan 4th is the first week of the year.
},
buttonText: {
prev: "Eelnev",
next: "Järgnev",
today: "Täna",
month: "Kuu",
week: "Nädal",
day: "Päev",
list: "Päevakord"
},
weekLabel: "näd",
allDayText: "Kogu päev",
eventLimitText: function (n) {
return "+ veel " + n;
},
noEventsMessage: "Kuvamiseks puuduvad sündmused"
};
return et;
}));

View file

@ -0,0 +1,30 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.eu = factory()));
}(this, function () { 'use strict';
var eu = {
code: "eu",
week: {
dow: 1,
doy: 7 // The week that contains Jan 1st is the first week of the year.
},
buttonText: {
prev: "Aur",
next: "Hur",
today: "Gaur",
month: "Hilabetea",
week: "Astea",
day: "Eguna",
list: "Agenda"
},
weekLabel: "As",
allDayHtml: "Egun<br/>osoa",
eventLimitText: "gehiago",
noEventsMessage: "Ez dago ekitaldirik erakusteko"
};
return eu;
}));

View file

@ -0,0 +1,33 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.fa = factory()));
}(this, function () { 'use strict';
var fa = {
code: "fa",
week: {
dow: 6,
doy: 12 // The week that contains Jan 1st is the first week of the year.
},
dir: 'rtl',
buttonText: {
prev: "قبلی",
next: "بعدی",
today: "امروز",
month: "ماه",
week: "هفته",
day: "روز",
list: "برنامه"
},
weekLabel: "هف",
allDayText: "تمام روز",
eventLimitText: function (n) {
return "بیش از " + n;
},
noEventsMessage: "هیچ رویدادی به نمایش"
};
return fa;
}));

View file

@ -0,0 +1,30 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.fi = factory()));
}(this, function () { 'use strict';
var fi = {
code: "fi",
week: {
dow: 1,
doy: 4 // The week that contains Jan 4th is the first week of the year.
},
buttonText: {
prev: "Edellinen",
next: "Seuraava",
today: "Tänään",
month: "Kuukausi",
week: "Viikko",
day: "Päivä",
list: "Tapahtumat"
},
weekLabel: "Vk",
allDayText: "Koko päivä",
eventLimitText: "lisää",
noEventsMessage: "Ei näytettäviä tapahtumia"
};
return fi;
}));

View file

@ -0,0 +1,27 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales['fr-ca'] = factory()));
}(this, function () { 'use strict';
var frCa = {
code: "fr",
buttonText: {
prev: "Précédent",
next: "Suivant",
today: "Aujourd'hui",
year: "Année",
month: "Mois",
week: "Semaine",
day: "Jour",
list: "Mon planning"
},
weekLabel: "Sem.",
allDayHtml: "Toute la<br/>journée",
eventLimitText: "en plus",
noEventsMessage: "Aucun événement à afficher"
};
return frCa;
}));

View file

@ -0,0 +1,31 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales['fr-ch'] = factory()));
}(this, function () { 'use strict';
var frCh = {
code: "fr-ch",
week: {
dow: 1,
doy: 4 // The week that contains Jan 4th is the first week of the year.
},
buttonText: {
prev: "Précédent",
next: "Suivant",
today: "Courant",
year: "Année",
month: "Mois",
week: "Semaine",
day: "Jour",
list: "Mon planning"
},
weekLabel: "Sm",
allDayHtml: "Toute la<br/>journée",
eventLimitText: "en plus",
noEventsMessage: "Aucun événement à afficher"
};
return frCh;
}));

View file

@ -0,0 +1,31 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.fr = factory()));
}(this, function () { 'use strict';
var fr = {
code: "fr",
week: {
dow: 1,
doy: 4 // The week that contains Jan 4th is the first week of the year.
},
buttonText: {
prev: "Précédent",
next: "Suivant",
today: "Aujourd'hui",
year: "Année",
month: "Mois",
week: "Semaine",
day: "Jour",
list: "Mon planning"
},
weekLabel: "Sem.",
allDayHtml: "Toute la<br/>journée",
eventLimitText: "en plus",
noEventsMessage: "Aucun événement à afficher"
};
return fr;
}));

View file

@ -0,0 +1,30 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.gl = factory()));
}(this, function () { 'use strict';
var gl = {
code: "gl",
week: {
dow: 1,
doy: 4 // The week that contains Jan 4th is the first week of the year.
},
buttonText: {
prev: "Ant",
next: "Seg",
today: "Hoxe",
month: "Mes",
week: "Semana",
day: "Día",
list: "Axenda"
},
weekLabel: "Sm",
allDayHtml: "Todo<br/>o día",
eventLimitText: "máis",
noEventsMessage: "Non hai eventos para amosar"
};
return gl;
}));

View file

@ -0,0 +1,27 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.he = factory()));
}(this, function () { 'use strict';
var he = {
code: "he",
dir: 'rtl',
buttonText: {
prev: "הקודם",
next: "הבא",
today: "היום",
month: "חודש",
week: "שבוע",
day: "יום",
list: "סדר יום"
},
allDayText: "כל היום",
eventLimitText: "אחר",
noEventsMessage: "אין אירועים להצגה",
weekLabel: "שבוע"
};
return he;
}));

View file

@ -0,0 +1,32 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.hi = factory()));
}(this, function () { 'use strict';
var hi = {
code: "hi",
week: {
dow: 0,
doy: 6 // The week that contains Jan 1st is the first week of the year.
},
buttonText: {
prev: "पिछला",
next: "अगला",
today: "आज",
month: "महीना",
week: "सप्ताह",
day: "दिन",
list: "कार्यसूची"
},
weekLabel: "हफ्ता",
allDayText: "सभी दिन",
eventLimitText: function (n) {
return "+अधिक " + n;
},
noEventsMessage: "कोई घटनाओं को प्रदर्शित करने के लिए"
};
return hi;
}));

View file

@ -0,0 +1,32 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.hr = factory()));
}(this, function () { 'use strict';
var hr = {
code: "hr",
week: {
dow: 1,
doy: 7 // The week that contains Jan 1st is the first week of the year.
},
buttonText: {
prev: "Prijašnji",
next: "Sljedeći",
today: "Danas",
month: "Mjesec",
week: "Tjedan",
day: "Dan",
list: "Raspored"
},
weekLabel: "Tje",
allDayText: "Cijeli dan",
eventLimitText: function (n) {
return "+ još " + n;
},
noEventsMessage: "Nema događaja za prikaz"
};
return hr;
}));

View file

@ -0,0 +1,30 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.hu = factory()));
}(this, function () { 'use strict';
var hu = {
code: "hu",
week: {
dow: 1,
doy: 4 // The week that contains Jan 4th is the first week of the year.
},
buttonText: {
prev: "vissza",
next: "előre",
today: "ma",
month: "Hónap",
week: "Hét",
day: "Nap",
list: "Napló"
},
weekLabel: "Hét",
allDayText: "Egész nap",
eventLimitText: "további",
noEventsMessage: "Nincs megjeleníthető esemény"
};
return hu;
}));

View file

@ -0,0 +1,30 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.id = factory()));
}(this, function () { 'use strict';
var id = {
code: "id",
week: {
dow: 1,
doy: 7 // The week that contains Jan 1st is the first week of the year.
},
buttonText: {
prev: "mundur",
next: "maju",
today: "hari ini",
month: "Bulan",
week: "Minggu",
day: "Hari",
list: "Agenda"
},
weekLabel: "Mg",
allDayHtml: "Sehari<br/>penuh",
eventLimitText: "lebih",
noEventsMessage: "Tidak ada acara untuk ditampilkan"
};
return id;
}));

View file

@ -0,0 +1,30 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.is = factory()));
}(this, function () { 'use strict';
var is = {
code: "is",
week: {
dow: 1,
doy: 4 // The week that contains Jan 4th is the first week of the year.
},
buttonText: {
prev: "Fyrri",
next: "Næsti",
today: "Í dag",
month: "Mánuður",
week: "Vika",
day: "Dagur",
list: "Dagskrá"
},
weekLabel: "Vika",
allDayHtml: "Allan<br/>daginn",
eventLimitText: "meira",
noEventsMessage: "Engir viðburðir til að sýna"
};
return is;
}));

View file

@ -0,0 +1,32 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.it = factory()));
}(this, function () { 'use strict';
var it = {
code: "it",
week: {
dow: 1,
doy: 4 // The week that contains Jan 4th is the first week of the year.
},
buttonText: {
prev: "Prec",
next: "Succ",
today: "Oggi",
month: "Mese",
week: "Settimana",
day: "Giorno",
list: "Agenda"
},
weekLabel: "Sm",
allDayHtml: "Tutto il<br/>giorno",
eventLimitText: function (n) {
return "+altri " + n;
},
noEventsMessage: "Non ci sono eventi da visualizzare"
};
return it;
}));

View file

@ -0,0 +1,28 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.ja = factory()));
}(this, function () { 'use strict';
var ja = {
code: "ja",
buttonText: {
prev: "前",
next: "次",
today: "今日",
month: "月",
week: "週",
day: "日",
list: "予定リスト"
},
weekLabel: "週",
allDayText: "終日",
eventLimitText: function (n) {
return "他 " + n + " 件";
},
noEventsMessage: "表示する予定はありません"
};
return ja;
}));

View file

@ -0,0 +1,32 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.ka = factory()));
}(this, function () { 'use strict';
var ka = {
code: "ka",
week: {
dow: 1,
doy: 7
},
buttonText: {
prev: "წინა",
next: "შემდეგი",
today: "დღეს",
month: "თვე",
week: "კვირა",
day: "დღე",
list: "დღის წესრიგი"
},
weekLabel: "კვ",
allDayText: "მთელი დღე",
eventLimitText: function (n) {
return "+ კიდევ " + n;
},
noEventsMessage: "ღონისძიებები არ არის"
};
return ka;
}));

View file

@ -0,0 +1,32 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.kk = factory()));
}(this, function () { 'use strict';
var kk = {
code: "kk",
week: {
dow: 1,
doy: 7 // The week that contains Jan 1st is the first week of the year.
},
buttonText: {
prev: "Алдыңғы",
next: "Келесі",
today: "Бүгін",
month: "Ай",
week: "Апта",
day: "Күн",
list: "Күн тәртібі"
},
weekLabel: "Не",
allDayText: "Күні бойы",
eventLimitText: function (n) {
return "+ тағы " + n;
},
noEventsMessage: "Көрсету үшін оқиғалар жоқ"
};
return kk;
}));

View file

@ -0,0 +1,26 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.ko = factory()));
}(this, function () { 'use strict';
var ko = {
code: "ko",
buttonText: {
prev: "이전달",
next: "다음달",
today: "오늘",
month: "월",
week: "주",
day: "일",
list: "일정목록"
},
weekLabel: "주",
allDayText: "종일",
eventLimitText: "개",
noEventsMessage: "일정이 없습니다"
};
return ko;
}));

View file

@ -0,0 +1,30 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.lb = factory()));
}(this, function () { 'use strict';
var lb = {
code: "lb",
week: {
dow: 1,
doy: 4 // The week that contains Jan 4th is the first week of the year.
},
buttonText: {
prev: "Zréck",
next: "Weider",
today: "Haut",
month: "Mount",
week: "Woch",
day: "Dag",
list: "Terminiwwersiicht"
},
weekLabel: "W",
allDayText: "Ganzen Dag",
eventLimitText: "méi",
noEventsMessage: "Nee Evenementer ze affichéieren"
};
return lb;
}));

View file

@ -0,0 +1,30 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.lt = factory()));
}(this, function () { 'use strict';
var lt = {
code: "lt",
week: {
dow: 1,
doy: 4 // The week that contains Jan 4th is the first week of the year.
},
buttonText: {
prev: "Atgal",
next: "Pirmyn",
today: "Šiandien",
month: "Mėnuo",
week: "Savaitė",
day: "Diena",
list: "Darbotvarkė"
},
weekLabel: "SAV",
allDayText: "Visą dieną",
eventLimitText: "daugiau",
noEventsMessage: "Nėra įvykių rodyti"
};
return lt;
}));

View file

@ -0,0 +1,32 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.lv = factory()));
}(this, function () { 'use strict';
var lv = {
code: "lv",
week: {
dow: 1,
doy: 4 // The week that contains Jan 4th is the first week of the year.
},
buttonText: {
prev: "Iepr.",
next: "Nāk.",
today: "Šodien",
month: "Mēnesis",
week: "Nedēļa",
day: "Diena",
list: "Dienas kārtība"
},
weekLabel: "Ned.",
allDayText: "Visu dienu",
eventLimitText: function (n) {
return "+vēl " + n;
},
noEventsMessage: "Nav notikumu"
};
return lv;
}));

View file

@ -0,0 +1,28 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.mk = factory()));
}(this, function () { 'use strict';
var mk = {
code: "mk",
buttonText: {
prev: "претходно",
next: "следно",
today: "Денес",
month: "Месец",
week: "Недела",
day: "Ден",
list: "График"
},
weekLabel: "Сед",
allDayText: "Цел ден",
eventLimitText: function (n) {
return "+повеќе " + n;
},
noEventsMessage: "Нема настани за прикажување"
};
return mk;
}));

View file

@ -0,0 +1,32 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.ms = factory()));
}(this, function () { 'use strict';
var ms = {
code: "ms",
week: {
dow: 1,
doy: 7 // The week that contains Jan 1st is the first week of the year.
},
buttonText: {
prev: "Sebelum",
next: "Selepas",
today: "hari ini",
month: "Bulan",
week: "Minggu",
day: "Hari",
list: "Agenda"
},
weekLabel: "Mg",
allDayText: "Sepanjang hari",
eventLimitText: function (n) {
return "masih ada " + n + " acara";
},
noEventsMessage: "Tiada peristiwa untuk dipaparkan"
};
return ms;
}));

View file

@ -0,0 +1,30 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.nb = factory()));
}(this, function () { 'use strict';
var nb = {
code: "nb",
week: {
dow: 1,
doy: 4 // The week that contains Jan 4th is the first week of the year.
},
buttonText: {
prev: "Forrige",
next: "Neste",
today: "I dag",
month: "Måned",
week: "Uke",
day: "Dag",
list: "Agenda"
},
weekLabel: "Uke",
allDayText: "Hele dagen",
eventLimitText: "til",
noEventsMessage: "Ingen hendelser å vise"
};
return nb;
}));

View file

@ -0,0 +1,30 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.nl = factory()));
}(this, function () { 'use strict';
var nl = {
code: "nl",
week: {
dow: 1,
doy: 4 // The week that contains Jan 4th is the first week of the year.
},
buttonText: {
prev: "Voorgaand",
next: "Volgende",
today: "Vandaag",
year: "Jaar",
month: "Maand",
week: "Week",
day: "Dag",
list: "Agenda"
},
allDayText: "Hele dag",
eventLimitText: "extra",
noEventsMessage: "Geen evenementen om te laten zien"
};
return nl;
}));

View file

@ -0,0 +1,30 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.nn = factory()));
}(this, function () { 'use strict';
var nn = {
code: "nn",
week: {
dow: 1,
doy: 4 // The week that contains Jan 4th is the first week of the year.
},
buttonText: {
prev: "Førre",
next: "Neste",
today: "I dag",
month: "Månad",
week: "Veke",
day: "Dag",
list: "Agenda"
},
weekLabel: "Veke",
allDayText: "Heile dagen",
eventLimitText: "til",
noEventsMessage: "Ingen hendelser å vise"
};
return nn;
}));

View file

@ -0,0 +1,30 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales.pl = factory()));
}(this, function () { 'use strict';
var pl = {
code: "pl",
week: {
dow: 1,
doy: 4 // The week that contains Jan 4th is the first week of the year.
},
buttonText: {
prev: "Poprzedni",
next: "Następny",
today: "Dziś",
month: "Miesiąc",
week: "Tydzień",
day: "Dzień",
list: "Plan dnia"
},
weekLabel: "Tydz",
allDayText: "Cały dzień",
eventLimitText: "więcej",
noEventsMessage: "Brak wydarzeń do wyświetlenia"
};
return pl;
}));

View file

@ -0,0 +1,28 @@
(function (global, factory) {
typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
typeof define === 'function' && define.amd ? define(factory) :
(global = global || self, (global.FullCalendarLocales = global.FullCalendarLocales || {}, global.FullCalendarLocales['pt-br'] = factory()));
}(this, function () { 'use strict';
var ptBr = {
code: "pt-br",
buttonText: {
prev: "Anterior",
next: "Próximo",
today: "Hoje",
month: "Mês",
week: "Semana",
day: "Dia",
list: "Compromissos"
},
weekLabel: "Sm",
allDayText: "dia inteiro",
eventLimitText: function (n) {
return "mais +" + n;
},
noEventsMessage: "Não há eventos para mostrar"
};
return ptBr;
}));

Some files were not shown because too many files have changed in this diff Show more