From 14c84452707d19d773198a5a87e7c36f04f5c6eb Mon Sep 17 00:00:00 2001 From: pvictor Date: Tue, 26 Sep 2023 13:55:49 +0200 Subject: [PATCH] updated calendar week & month options args --- DESCRIPTION | 2 +- R/calendar-options.R | 21 ++++++++++++--------- man/cal_month_options.Rd | 7 ++----- man/cal_week_options.Rd | 10 ++++++++-- 4 files changed, 23 insertions(+), 17 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index 41ae16c2..ee0a3048 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,6 +1,6 @@ Package: toastui Title: Interactive Tables, Calendars and Charts for the Web -Version: 0.3.0 +Version: 0.3.0.9000 Authors@R: c( person("Victor", "Perrier", email = "victor.perrier@dreamrs.fr", role = c("aut", "cre", "cph")), person("Fanny", "Meyer", role = "aut"), diff --git a/R/calendar-options.R b/R/calendar-options.R index 3585141c..1f1560fd 100644 --- a/R/calendar-options.R +++ b/R/calendar-options.R @@ -8,14 +8,16 @@ #' @param daynames Vector. The day names in weekly and daily. Default values are 'Sun', 'Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat'. #' @param narrowWeekend Logical. Make weekend column narrow(1/2 width). #' @param workweek Logical. Show only 5 days except for weekend. +#' @param showNowIndicator Display or not the current time indicator in the weekly/daily view. #' @param showTimezoneCollapseButton Logical. Show a collapse button to close multiple timezones #' @param timezonesCollapsed Logical. An initial multiple timezones collapsed state. #' @param hourStart Numeric. Can limit of render hour start. #' @param hourEnd Numeric. Can limit of render hour end. #' @param taskView Show the milestone and task in weekly, daily view. #' The default value is `FALSE`. If the value is a vector, it can be `"milestone"`, `"task"`. -#' @param scheduleView Show the all day and time grid in weekly, daily view. +#' @param eventView Show the all day and time grid in weekly, daily view. #' The default value is `TRUE`. If the value is a vector, it can be `"allday"`, `"time"`. +#' @param collapseDuplicateEvents Collapse duplicate events in the daily/weekly view. #' @param ... Additional options. #' #' @note Online JavaScript documentation: \url{https://github.com/nhn/tui.calendar/blob/main/docs/en/apis/options.md#week} @@ -30,12 +32,14 @@ cal_week_options <- function(cal, daynames = NULL, narrowWeekend = NULL, workweek = NULL, + showNowIndicator = NULL, showTimezoneCollapseButton = NULL, timezonesCollapsed = NULL, hourStart = NULL, hourEnd = NULL, - scheduleView = TRUE, + eventView = TRUE, taskView = FALSE, + collapseDuplicateEvents = NULL, ...) { check_cal(cal, "cal_week_options") .widget_options( @@ -45,12 +49,14 @@ cal_week_options <- function(cal, dayNames = daynames, narrowWeekend = narrowWeekend, workweek = workweek, + showNowIndicator = showNowIndicator, showTimezoneCollapseButton = showTimezoneCollapseButton, timezonesCollapsed = timezonesCollapsed, hourStart = hourStart, hourEnd = hourEnd, - scheduleView = list1(scheduleView), + eventView = list1(eventView), taskView = list1(taskView), + collapseDuplicateEvents = collapseDuplicateEvents, ... ) } @@ -68,8 +74,7 @@ cal_week_options <- function(cal, #' @param visibleWeeksCount Numeric. The visible week count in monthly(0 or null are same with 6). #' @param isAlways6Week Logical. Always show 6 weeks. If false, show 5 weeks or 6 weeks based on the month. #' @param workweek Logical. Show only 5 days except for weekend. -#' @param visibleScheduleCount Numeric. The visible schedule count in monthly grid. -#' @param scheduleFilter List of parameters, see online documentation. +#' @param visibleEventCount Numeric. The visible schedule count in monthly grid. #' @param ... Additional options. #' #' @note Online JavaScript documentation: \url{https://github.com/nhn/tui.calendar/blob/main/docs/en/apis/options.md#month} @@ -86,8 +91,7 @@ cal_month_options <- function(cal, visibleWeeksCount = NULL, isAlways6Week = NULL, workweek = NULL, - visibleScheduleCount = NULL, - scheduleFilter = NULL, + visibleEventCount = NULL, ...) { check_cal(cal, "cal_month_options") .widget_options( @@ -99,8 +103,7 @@ cal_month_options <- function(cal, visibleWeeksCount = visibleWeeksCount, isAlways6Weeks = isAlways6Week, workweek = workweek, - visibleScheduleCount = visibleScheduleCount, - scheduleFilter = scheduleFilter, + visibleEventCount = visibleEventCount, ... ) } diff --git a/man/cal_month_options.Rd b/man/cal_month_options.Rd index 25a50c40..f28c99d0 100644 --- a/man/cal_month_options.Rd +++ b/man/cal_month_options.Rd @@ -12,8 +12,7 @@ cal_month_options( visibleWeeksCount = NULL, isAlways6Week = NULL, workweek = NULL, - visibleScheduleCount = NULL, - scheduleFilter = NULL, + visibleEventCount = NULL, ... ) } @@ -32,9 +31,7 @@ cal_month_options( \item{workweek}{Logical. Show only 5 days except for weekend.} -\item{visibleScheduleCount}{Numeric. The visible schedule count in monthly grid.} - -\item{scheduleFilter}{List of parameters, see online documentation.} +\item{visibleEventCount}{Numeric. The visible schedule count in monthly grid.} \item{...}{Additional options.} } diff --git a/man/cal_week_options.Rd b/man/cal_week_options.Rd index b8e8190b..e630862e 100644 --- a/man/cal_week_options.Rd +++ b/man/cal_week_options.Rd @@ -10,12 +10,14 @@ cal_week_options( daynames = NULL, narrowWeekend = NULL, workweek = NULL, + showNowIndicator = NULL, showTimezoneCollapseButton = NULL, timezonesCollapsed = NULL, hourStart = NULL, hourEnd = NULL, - scheduleView = TRUE, + eventView = TRUE, taskView = FALSE, + collapseDuplicateEvents = NULL, ... ) } @@ -30,6 +32,8 @@ cal_week_options( \item{workweek}{Logical. Show only 5 days except for weekend.} +\item{showNowIndicator}{Display or not the current time indicator in the weekly/daily view.} + \item{showTimezoneCollapseButton}{Logical. Show a collapse button to close multiple timezones} \item{timezonesCollapsed}{Logical. An initial multiple timezones collapsed state.} @@ -38,12 +42,14 @@ cal_week_options( \item{hourEnd}{Numeric. Can limit of render hour end.} -\item{scheduleView}{Show the all day and time grid in weekly, daily view. +\item{eventView}{Show the all day and time grid in weekly, daily view. The default value is \code{TRUE}. If the value is a vector, it can be \code{"allday"}, \code{"time"}.} \item{taskView}{Show the milestone and task in weekly, daily view. The default value is \code{FALSE}. If the value is a vector, it can be \code{"milestone"}, \code{"task"}.} +\item{collapseDuplicateEvents}{Collapse duplicate events in the daily/weekly view.} + \item{...}{Additional options.} } \value{