Extends
- ember/Component
Members
(inner) actions :Object
Type:
- Object
- Source:
(inner) classNameBindings :Array.<String>
Type:
- Array.<String>
- Source:
(inner) classNames :Array.<String>
Type:
- Array.<String>
- Source:
(inner) content :Array.<Object>
Array of date value objects
Type:
- Array.<Object>
- Source:
(inner, nullable) currentMonth :Number
The currently selected/viewed month (1-12)
Type:
- Number
- Default Value:
- null
- Source:
(inner, nullable) currentYear :Number
The currently selected/viewed year
Type:
- Number
- Default Value:
- null
- Source:
(inner) dateValuePath :String
String lookup for the date value on the content objects
Type:
- String
- Default Value:
- 'date'
- Source:
(inner) layout :Object
Type:
- Object
- Source:
(inner) locale :String
The locale string to use for moment date values
Type:
- String
- Default Value:
- 'en'
- Source:
(inner) locked :Boolean
When true, the view mode is locked and users cannot navigate forward and back
Type:
- Boolean
- Default Value:
- false
- Source:
(inner) viewMode :String
The current view mode for the calendar
Type:
- String
- Default Value:
- 'days'
- Source:
Methods
(inner) actions:changeDecade(decadeMod) → {undefined}
Change the currently-viewed decade by incrementing or decrementing the decadeStart year number
Parameters:
Name | Type | Description |
---|---|---|
decadeMod |
Number | A number to adjust the decadeStart by (positive to increment, negative to decrement) |
- Source:
Returns:
- Type
- undefined
(inner) actions:changeMonth(monthMod) → {undefined}
Change the currently-viewed month by incrementing or decrementing the currentMonth (and currentYear if needed)
Parameters:
Name | Type | Description |
---|---|---|
monthMod |
Number | A number to adjust the currentMonth by (positive to increment, negative to decrement). The currentYear is adjusted as needed. |
- Source:
Returns:
- Type
- undefined
(inner) actions:changeYear(yearMod) → {undefined}
Change the currently-viewed year by increment or decrementing the currentYear
Parameters:
Name | Type | Description |
---|---|---|
yearMod |
Number | A number to adjust the currentYear by (positive to increment, negative to decrement) |
- Source:
Returns:
- Type
- undefined
(inner) actions:sendDateContent(dateContent) → {undefined}
Action to trigger component's bound action and pass back content values with dates occurring on the clicked date
Parameters:
Name | Type | Description |
---|---|---|
dateContent |
Array | Collection of content objects with date values of the clicked date |
- Source:
Returns:
- Type
- undefined
(inner) actions:setMonth(month) → {undefined}
Set the current month and change view mode to that month
Parameters:
Name | Type | Description |
---|---|---|
month |
Number | The number of the month to change view to |
- Source:
Returns:
- Type
- undefined
(inner) actions:setView(view) → {undefined}
Set the view mode of the calendar
Parameters:
Name | Type | Description |
---|---|---|
view |
String | The view mode to switch to; "days", "months", or "years" |
- Source:
Returns:
- Type
- undefined
(inner) actions:setYear(year) → {undefined}
Set the current year
Parameters:
Name | Type | Description |
---|---|---|
year |
Number | The year to set to the current value |
- Source:
Returns:
- Type
- undefined
(inner) contentDates() → {Object}
Object of nested year, month, and day values, representing the dates supplied by the calendar's content values
- Source:
Observes:
- content, dateValuePath
Returns:
- Type
- Object
(inner) currentMonthString() → {String}
Name of the currently selected/viewed month
- Source:
Observes:
- currentMonth, currentYear, locale
Returns:
- Type
- String
(inner) daysInMonth() → {Number}
The number of days in the current month
- Source:
Observes:
- currentMonth, currentYear
Returns:
- Type
- Number
(inner) decadeEnd() → {Number}
The last year in the currently selected/viewed decade
- Source:
Observes:
- decadeStart
Returns:
- Type
- Number
(inner) decadeStart() → {Number}
The first year in the currently selected/viewed decade
- Source:
Observes:
- currentYear
Returns:
- Type
- Number
(inner) initialize() → {undefined}
Initialize default property values
- Source:
Listens to Events:
- event:init
Returns:
- Type
- undefined
(inner) monthsInYearView() → {Array.<Object>}
Get an array of objects representing months in the year view
Each item contains the following values:
- {Boolean} active - Whether a content item's date occurs on this month
- {Number} month - The month number in the year (1-12)
- Source:
Observes:
- contentDates, currentYear
Returns:
- Type
- Array.<Object>
(inner) shortWeekDayNames() → {ember/Array}
An array of abbreviated, formatted day names of each week day
- Source:
Observes:
- locale
Returns:
- Type
- ember/Array
(inner) viewingDays() → {Boolean}
Whether the current view is "days"
- Source:
Observes:
- viewMode
Returns:
- Type
- Boolean
(inner) viewingMonths() → {Boolean}
Whether the current view is "months"
- Source:
Observes:
- viewMode
Returns:
- Type
- Boolean
(inner) viewingYears() → {Boolean}
Whether the current view is "years"
- Source:
Observes:
- viewMode
Returns:
- Type
- Boolean
(inner) weeksInMonthView() → {ember.Array}
An array of objects representing weeks and days in the month view
Each day object contains the following values:
- {Boolean} active - Whether a content item occurs on this date
- {Array} content - Collection of content items occurring on this date
- {Number} day - The day number of the month (1-31)
- {Boolean} new - Whether the day occurs in the next month
- {Boolean} old - Whether the day occurs in the previous month
- Source:
Observes:
- contentDates, currentMonth, currentYear, daysInMonth
Returns:
- Type
- ember.Array
(inner) yearsInDecadeView() → {Array.<Object>}
An array of objects representing years in the decade view
Each object contains the following values:
- {Boolean} active - Whether a content item occurs on this year
- {Boolean} new - Whether this year is in the next decade range
- {Boolean} old - Whether this year is in the previous decade range
- {Number} year - The year number
- Source:
Observes:
- contentDates, decadeEnd, decadeStart
Returns:
- Type
- Array.<Object>