small fix
This commit is contained in:
1 parent
df2f8fe03d
commit
e0944190be
9 files changed
+77
-101
No files matched your search
+1
-1
@@ -287,7 +287,7 @@ previous button's border...
|
||||
box-shadow: 0 2px 6px rgba(0,0,0,.15);
|
||||
}
|
||||
|
||||
.fc-popover .fc-header { /* TODO: be more consistent with fc-head/fc-body */
|
||||
.fc-popover .fc-header {
|
||||
padding: 2px 4px;
|
||||
}
|
||||
|
||||
|
||||
+56
-77
@@ -558,7 +558,7 @@ function flexibleCompare(a, b) {
|
||||
|
||||
// Computes the intersection of the two ranges. Returns undefined if no intersection.
|
||||
// Expects all dates to be normalized to the same timezone beforehand.
|
||||
// TODO: move to date section?
|
||||
// TOTO: move to date section?
|
||||
function intersectRanges(subjectRange, constraintRange) {
|
||||
var subjectStart = subjectRange.start;
|
||||
var subjectEnd = subjectRange.end;
|
||||
@@ -1191,7 +1191,7 @@ newMomentProto.stripTime = function() {
|
||||
// get the values before any conversion happens
|
||||
a = this.toArray(); // array of y/m/d/h/m/s/ms
|
||||
|
||||
// TODO: use keepLocalTime in the future
|
||||
|
||||
this.utc(); // set the internal UTC flag (will clear the ambig flags)
|
||||
setUTCValues(this, a.slice(0, 3)); // set the year/month/date. time will be zero
|
||||
|
||||
@@ -1216,7 +1216,6 @@ newMomentProto.hasTime = function() {
|
||||
// Converts the moment to UTC, stripping out its timezone offset, but preserving its
|
||||
// YMD and time-of-day. A moment with a stripped timezone offset will display no
|
||||
// timezone offset when .format() is called.
|
||||
// TODO: look into Moment's keepLocalTime functionality
|
||||
newMomentProto.stripZone = function() {
|
||||
var a, wasAmbigTime;
|
||||
|
||||
@@ -1261,7 +1260,6 @@ newMomentProto.local = function() {
|
||||
if (wasAmbigZone) {
|
||||
// If the moment was ambiguously zoned, the date fields were stored as UTC.
|
||||
// We want to preserve these, but in local time.
|
||||
// TODO: look into Moment's keepLocalTime functionality
|
||||
setLocalValues(this, a);
|
||||
}
|
||||
|
||||
@@ -1425,7 +1423,6 @@ function commonlyAmbiguate(inputs, preserveTime) {
|
||||
}
|
||||
|
||||
// Transfers all the flags related to ambiguous time/zone from the `src` moment to the `dest` moment
|
||||
// TODO: look into moment.momentProperties for this.
|
||||
function transferAmbigs(src, dest) {
|
||||
if (src._ambigTime) {
|
||||
dest._ambigTime = true;
|
||||
@@ -1550,7 +1547,6 @@ function formatDateWithChunk(date, chunk) {
|
||||
|
||||
// Date Range Formatting
|
||||
// -------------------------------------------------------------------------------------------------
|
||||
// TODO: make it work with timezone offset
|
||||
|
||||
// Using a formatting string meant for a single date, generate a range string, like
|
||||
// "Sep 2 - 9 2013", that intelligently inserts a separator where the dates differ.
|
||||
@@ -1649,7 +1645,6 @@ var similarUnitMap = {
|
||||
m: 'second', // minute
|
||||
s: 'second' // second
|
||||
};
|
||||
// TODO: week maybe?
|
||||
|
||||
|
||||
// Given a formatting chunk, and given that both dates are similar in the regard the
|
||||
@@ -1695,7 +1690,7 @@ function getFormatStringChunks(formatStr) {
|
||||
// Break the formatting string into an array of chunks
|
||||
function chunkFormatString(formatStr) {
|
||||
var chunks = [];
|
||||
var chunker = /\[([^\]]*)\]|\(([^\)]*)\)|(LTS|LT|(\w)\4*o?)|([^\w\[\(]+)/g; // TODO: more descrimination
|
||||
var chunker = /\[([^\]]*)\]|\(([^\)]*)\)|(LTS|LT|(\w)\4*o?)|([^\w\[\(]+)/g;
|
||||
var match;
|
||||
|
||||
while ((match = chunker.exec(formatStr))) {
|
||||
@@ -1777,7 +1772,7 @@ function extendClass(superClass, members) {
|
||||
|
||||
|
||||
function mixIntoClass(theClass, members) {
|
||||
copyOwnProps(members.prototype || members, theClass.prototype); // TODO: copyNativeMethods?
|
||||
copyOwnProps(members.prototype || members, theClass.prototype);
|
||||
}
|
||||
;;
|
||||
|
||||
@@ -1992,7 +1987,6 @@ var Popover = Class.extend({
|
||||
|
||||
// Triggers a callback. Calls a function in the option hash of the same name.
|
||||
// Arguments beyond the first `name` are forwarded on.
|
||||
// TODO: better code reuse for this. Repeat code
|
||||
trigger: function(name) {
|
||||
if (this.options[name]) {
|
||||
this.options[name].apply(this, Array.prototype.slice.call(arguments, 1));
|
||||
@@ -2219,7 +2213,7 @@ var CoordCache = FC.CoordCache = Class.extend({
|
||||
|
||||
/* Tracks a drag's mouse movement, firing various handlers
|
||||
----------------------------------------------------------------------------------------------------------------------*/
|
||||
// TODO: use Emitter
|
||||
|
||||
|
||||
var DragListener = FC.DragListener = Class.extend({
|
||||
|
||||
@@ -2466,7 +2460,6 @@ var DragListener = FC.DragListener = Class.extend({
|
||||
var el = this.scrollEl;
|
||||
|
||||
this.scrollBounds = el ? getOuterRect(el) : null;
|
||||
// TODO: use getClientRect in future. but prevents auto scrolling when on top of scrollbars
|
||||
},
|
||||
|
||||
|
||||
@@ -2658,7 +2651,6 @@ var HitDragListener = DragListener.extend({
|
||||
if (subjectEl && this.options.subjectCenter) {
|
||||
|
||||
// only consider the area the subject overlaps the hit. best for large subjects.
|
||||
// TODO: skip this if hit didn't supply left/right/top/bottom
|
||||
if (this.origHit) {
|
||||
subjectRect = intersectRects(this.origHit, subjectRect) ||
|
||||
subjectRect; // in case there is no intersection
|
||||
@@ -3027,11 +3019,11 @@ var Grid = FC.Grid = Class.extend({
|
||||
displayEventTime: null,
|
||||
displayEventEnd: null,
|
||||
|
||||
minResizeDuration: null, // TODO: hack. set by subclasses. minumum event resize duration
|
||||
minResizeDuration: null,
|
||||
|
||||
// if defined, holds the unit identified (ex: "year" or "month") that determines the level of granularity
|
||||
// of the date areas. if not defined, assumes to be day and time granularity.
|
||||
// TODO: port isTimeScale into same system?
|
||||
|
||||
largeUnit: null,
|
||||
|
||||
|
||||
@@ -3120,8 +3112,6 @@ var Grid = FC.Grid = Class.extend({
|
||||
},
|
||||
|
||||
|
||||
// Diffs the two dates, returning a duration, based on granularity of the grid
|
||||
// TODO: port isTimeScale into this system?
|
||||
diffDates: function(a, b) {
|
||||
if (this.largeUnit) {
|
||||
return diffByUnit(a, b, this.largeUnit);
|
||||
@@ -3148,7 +3138,7 @@ var Grid = FC.Grid = Class.extend({
|
||||
|
||||
// Given coordinates from the topleft of the document, return data about the date-related area underneath.
|
||||
// Can return an object with arbitrary properties (although top/right/left/bottom are encouraged).
|
||||
// Must have a `grid` property, a reference to this current grid. TODO: avoid this
|
||||
// Must have a `grid` property, a reference to this current grid.
|
||||
// The returned object will be processed by getHitSpan and getHitEl.
|
||||
queryHit: function(leftOffset, topOffset) {
|
||||
},
|
||||
@@ -3302,9 +3292,6 @@ var Grid = FC.Grid = Class.extend({
|
||||
},
|
||||
|
||||
|
||||
/* Event Helper
|
||||
------------------------------------------------------------------------------------------------------------------*/
|
||||
// TODO: should probably move this to Grid.events, like we did event dragging / resizing
|
||||
|
||||
|
||||
// Renders a mock event at the given event location, which contains zoned start/end properties.
|
||||
@@ -3381,9 +3368,6 @@ var Grid = FC.Grid = Class.extend({
|
||||
return span;
|
||||
},
|
||||
|
||||
|
||||
// Given two spans, must return the combination of the two.
|
||||
// TODO: do this separation of concerns (combining VS validation) for event dnd/resize too.
|
||||
computeSelectionSpan: function(span0, span1) {
|
||||
var dates = [ span0.start, span0.end, span1.start, span1.end ];
|
||||
|
||||
@@ -3443,15 +3427,10 @@ var Grid = FC.Grid = Class.extend({
|
||||
},
|
||||
|
||||
|
||||
/* Fill System (highlight, background events, business hours)
|
||||
--------------------------------------------------------------------------------------------------------------------
|
||||
TODO: remove this system. like we did in TimeGrid
|
||||
*/
|
||||
|
||||
|
||||
// Renders a set of rectangles over the given segments of time.
|
||||
// MUST RETURN a subset of segs, the segs that were actually rendered.
|
||||
// Responsible for populating this.elsByFill. TODO: better API for expressing this requirement
|
||||
renderFill: function(type, segs) {
|
||||
// subclasses must implement
|
||||
},
|
||||
@@ -3580,7 +3559,7 @@ Grid.mixin({
|
||||
isDraggingSeg: false, // is a segment being dragged? boolean
|
||||
isResizingSeg: false, // is a segment being resized? boolean
|
||||
isDraggingExternal: false, // jqui-dragging an external element? boolean
|
||||
segs: null, // the *event* segments currently rendered in the grid. TODO: rename to `eventSegs`
|
||||
segs: null, // the *event* segments currently rendered in the grid. TOTO: rename to `eventSegs`
|
||||
|
||||
|
||||
// Renders the given events onto the grid
|
||||
@@ -3727,7 +3706,7 @@ Grid.mixin({
|
||||
|
||||
// Generates a semicolon-separated CSS string to be used for the default rendering of a background event.
|
||||
// Called by the fill system.
|
||||
// TODO: consolidate with getEventSkinCss?
|
||||
// TOTO: consolidate with getEventSkinCss?
|
||||
bgEventSegCss: function(seg) {
|
||||
var view = this.view;
|
||||
var event = seg.event;
|
||||
@@ -4151,7 +4130,7 @@ Grid.mixin({
|
||||
disableCursor();
|
||||
resizeLocation = null;
|
||||
}
|
||||
// no change? (TODO: how does this work with timezones?)
|
||||
// no change? (TOTO: how does this work with timezones?)
|
||||
else if (resizeLocation.start.isSame(event.start) && resizeLocation.end.isSame(eventEnd)) {
|
||||
resizeLocation = null;
|
||||
}
|
||||
@@ -4237,7 +4216,7 @@ Grid.mixin({
|
||||
if (!resizeLocation.start.isBefore(resizeLocation.end)) {
|
||||
|
||||
defaultDuration =
|
||||
this.minResizeDuration || // TODO: hack
|
||||
this.minResizeDuration || // TOTO: hack
|
||||
(event.allDay ?
|
||||
calendar.defaultAllDayEventDuration :
|
||||
calendar.defaultTimedEventDuration);
|
||||
@@ -4469,7 +4448,7 @@ Grid.mixin({
|
||||
for (i = 0; i < segs.length; i++) {
|
||||
seg = segs[i];
|
||||
seg.event = event;
|
||||
seg.eventStartMS = +span.start; // TODO: not the best name after making spans unzoned
|
||||
seg.eventStartMS = +span.start; // TOTO: not the best name after making spans unzoned
|
||||
seg.eventDurationMS = span.end - span.start;
|
||||
}
|
||||
|
||||
@@ -4827,7 +4806,7 @@ var DayTableMixin = FC.DayTableMixin = {
|
||||
|
||||
|
||||
// Slices up a date range into a segment for every day-cell it intersects with.
|
||||
// TODO: make more DRY with sliceRangeByRow somehow.
|
||||
// TOTO: make more DRY with sliceRangeByRow somehow.
|
||||
sliceRangeByDay: function(range) {
|
||||
var daysPerRow = this.daysPerRow;
|
||||
var normalRange = this.view.computeDayRange(range); // make whole-day range, considering nextDayThreshold
|
||||
@@ -4919,7 +4898,7 @@ var DayTableMixin = FC.DayTableMixin = {
|
||||
},
|
||||
|
||||
|
||||
// TODO: when internalApiVersion, accept an object for HTML attributes
|
||||
// TOTO: when internalApiVersion, accept an object for HTML attributes
|
||||
// (colspan should be no different)
|
||||
renderHeadDateCellHtml: function(date, colspan, otherAttrs) {
|
||||
var view = this.view;
|
||||
@@ -4997,7 +4976,7 @@ var DayTableMixin = FC.DayTableMixin = {
|
||||
},
|
||||
|
||||
|
||||
// TODO: a generic method for dealing with <tr>, RTL, intro
|
||||
// TOTO: a generic method for dealing with <tr>, RTL, intro
|
||||
// when increment internalApiVersion
|
||||
// wrapTr (scheduler)
|
||||
|
||||
@@ -5030,7 +5009,7 @@ var DayTableMixin = FC.DayTableMixin = {
|
||||
|
||||
var DayGrid = FC.DayGrid = Grid.extend(DayTableMixin, {
|
||||
|
||||
numbersVisible: false, // should render a row for day/week numbers? set by outside view. TODO: make internal
|
||||
numbersVisible: false, // should render a row for day/week numbers? set by outside view. TOTO: make internal
|
||||
bottomCoordPadding: 0, // hack for extending the hit area for the last row of the coordinate grid
|
||||
|
||||
rowEls: null, // set of fake row elements
|
||||
@@ -5286,7 +5265,7 @@ var DayGrid = FC.DayGrid = Grid.extend(DayTableMixin, {
|
||||
|
||||
/* Event Drag Visualization
|
||||
------------------------------------------------------------------------------------------------------------------*/
|
||||
// TODO: move to DayGrid.event, similar to what we did with Grid's drag methods
|
||||
// TOTO: move to DayGrid.event, similar to what we did with Grid's drag methods
|
||||
|
||||
|
||||
// Renders a visual indication of an event or external element being dragged.
|
||||
@@ -5814,7 +5793,7 @@ DayGrid.mixin({
|
||||
// `row` is the row number.
|
||||
computeRowLevelLimit: function(row) {
|
||||
var rowEl = this.rowEls.eq(row); // the containing "fake" row div
|
||||
var rowHeight = rowEl.height(); // TODO: cache somehow?
|
||||
var rowHeight = rowEl.height(); // TOTO: cache somehow?
|
||||
var trEls = this.rowStructs[row].tbodyEl.children();
|
||||
var i, trEl;
|
||||
var trHeight;
|
||||
@@ -6260,7 +6239,7 @@ var TimeGrid = FC.TimeGrid = Grid.extend(DayTableMixin, {
|
||||
|
||||
this.slotDuration = slotDuration;
|
||||
this.snapDuration = snapDuration;
|
||||
this.snapsPerSlot = slotDuration / snapDuration; // TODO: ensure an integer multiple?
|
||||
this.snapsPerSlot = slotDuration / snapDuration; // TOTO: ensure an integer multiple?
|
||||
|
||||
this.minResizeDuration = snapDuration; // hack
|
||||
|
||||
@@ -6420,7 +6399,7 @@ var TimeGrid = FC.TimeGrid = Grid.extend(DayTableMixin, {
|
||||
var dayRange;
|
||||
|
||||
for (dayIndex = 0; dayIndex < this.daysPerRow; dayIndex++) {
|
||||
dayDate = this.dayDates[dayIndex].clone(); // TODO: better API for this?
|
||||
dayDate = this.dayDates[dayIndex].clone(); // TOTO: better API for this?
|
||||
dayRange = {
|
||||
start: dayDate.clone().time(this.minTime),
|
||||
end: dayDate.clone().time(this.maxTime)
|
||||
@@ -6711,7 +6690,7 @@ TimeGrid.mixin({
|
||||
this.highlightContainerEls = skeletonEl.find('.fc-highlight-container');
|
||||
this.businessContainerEls = skeletonEl.find('.fc-business-container');
|
||||
|
||||
this.bookendCells(skeletonEl.find('tr')); // TODO: do this on string level
|
||||
this.bookendCells(skeletonEl.find('tr')); // TOTO: do this on string level
|
||||
this.el.append(skeletonEl);
|
||||
},
|
||||
|
||||
@@ -6770,7 +6749,7 @@ TimeGrid.mixin({
|
||||
|
||||
|
||||
renderBgSegs: function(segs) {
|
||||
segs = this.renderFillSegEls('bgEvent', segs); // TODO: old fill system
|
||||
segs = this.renderFillSegEls('bgEvent', segs); // TOTO: old fill system
|
||||
this.updateSegVerticals(segs);
|
||||
this.attachSegsByCol(this.groupSegsByCol(segs), this.bgContainerEls);
|
||||
this.bgSegs = segs;
|
||||
@@ -6788,7 +6767,7 @@ TimeGrid.mixin({
|
||||
|
||||
|
||||
renderHighlightSegs: function(segs) {
|
||||
segs = this.renderFillSegEls('highlight', segs); // TODO: old fill system
|
||||
segs = this.renderFillSegEls('highlight', segs); // TOTO: old fill system
|
||||
this.updateSegVerticals(segs);
|
||||
this.attachSegsByCol(this.groupSegsByCol(segs), this.highlightContainerEls);
|
||||
this.highlightSegs = segs;
|
||||
@@ -6805,7 +6784,7 @@ TimeGrid.mixin({
|
||||
|
||||
|
||||
renderBusinessSegs: function(segs) {
|
||||
segs = this.renderFillSegEls('businessHours', segs); // TODO: old fill system
|
||||
segs = this.renderFillSegEls('businessHours', segs); // TOTO: old fill system
|
||||
this.updateSegVerticals(segs);
|
||||
this.attachSegsByCol(this.groupSegsByCol(segs), this.businessContainerEls);
|
||||
this.businessSegs = segs;
|
||||
@@ -6953,7 +6932,7 @@ TimeGrid.mixin({
|
||||
) +
|
||||
'</div>' +
|
||||
'<div class="fc-bg"/>' +
|
||||
/* TODO: write CSS for this
|
||||
/* TOTO: write CSS for this
|
||||
(isResizableFromStart ?
|
||||
'<div class="fc-resizer fc-start-resizer" />' :
|
||||
''
|
||||
@@ -7311,7 +7290,7 @@ var View = FC.View = Class.extend({
|
||||
isHiddenDayHash: null,
|
||||
|
||||
// document handlers, bound to `this` object
|
||||
documentMousedownProxy: null, // TODO: doesn't work with touch
|
||||
documentMousedownProxy: null, // TOTO: doesn't work with touch
|
||||
|
||||
// for refresh timing of now indicator
|
||||
nowIndicatorTimeoutID: null,
|
||||
@@ -7358,7 +7337,7 @@ var View = FC.View = Class.extend({
|
||||
calendar,
|
||||
[name, thisObj || this].concat(
|
||||
Array.prototype.slice.call(arguments, 2), // arguments beyond thisObj
|
||||
[ this ] // always make the last argument a reference to the view. TODO: deprecate
|
||||
[ this ] // always make the last argument a reference to the view. TOTO: deprecate
|
||||
)
|
||||
);
|
||||
},
|
||||
@@ -7587,7 +7566,7 @@ var View = FC.View = Class.extend({
|
||||
|
||||
// If the view has already been displayed, tears it down and displays it again.
|
||||
// Will re-render the events if necessary, which display/clear DO NOT do.
|
||||
// TODO: make behavior more consistent.
|
||||
// TOTO: make behavior more consistent.
|
||||
redisplay: function() {
|
||||
if (this.isSkeletonRendered) {
|
||||
var wasEventsRendered = this.isEventsRendered;
|
||||
@@ -7613,7 +7592,7 @@ var View = FC.View = Class.extend({
|
||||
this.setDate(date);
|
||||
}
|
||||
if (this.render) {
|
||||
this.render(); // TODO: deprecate
|
||||
this.render(); // TOTO: deprecate
|
||||
}
|
||||
this.renderDates();
|
||||
this.updateSize();
|
||||
@@ -7634,7 +7613,7 @@ var View = FC.View = Class.extend({
|
||||
this.unrenderBusinessHours();
|
||||
this.unrenderDates();
|
||||
if (this.destroy) {
|
||||
this.destroy(); // TODO: deprecate
|
||||
this.destroy(); // TOTO: deprecate
|
||||
}
|
||||
},
|
||||
|
||||
@@ -7720,7 +7699,7 @@ var View = FC.View = Class.extend({
|
||||
|
||||
// Immediately render the current time indicator and begins re-rendering it at an interval,
|
||||
// which is defined by this.getNowIndicatorUnit().
|
||||
// TODO: somehow do this for the current whole day's background too
|
||||
// TOTO: somehow do this for the current whole day's background too
|
||||
startNowIndicator: function() {
|
||||
var _this = this;
|
||||
var unit = this.getNowIndicatorUnit();
|
||||
@@ -7920,12 +7899,12 @@ var View = FC.View = Class.extend({
|
||||
|
||||
if (this.isEventsRendered) {
|
||||
|
||||
// TODO: optimize: if we know this is part of a displayEvents call, don't queryScroll/setScroll
|
||||
// TOTO: optimize: if we know this is part of a displayEvents call, don't queryScroll/setScroll
|
||||
scrollState = this.queryScroll();
|
||||
|
||||
this.triggerEventUnrender();
|
||||
if (this.destroyEvents) {
|
||||
this.destroyEvents(); // TODO: deprecate
|
||||
this.destroyEvents(); // TOTO: deprecate
|
||||
}
|
||||
this.unrenderEvents();
|
||||
this.setScroll(scrollState);
|
||||
@@ -8071,7 +8050,7 @@ var View = FC.View = Class.extend({
|
||||
var eventInput;
|
||||
var event;
|
||||
|
||||
// Try to build an event object and render it. TODO: decouple the two
|
||||
// Try to build an event object and render it. TOTO: decouple the two
|
||||
if (eventProps) {
|
||||
eventInput = $.extend({}, eventProps, dropLocation);
|
||||
event = this.calendar.renderEvent(eventInput, meta.stick)[0]; // renderEvent returns an array
|
||||
@@ -8205,7 +8184,7 @@ var View = FC.View = Class.extend({
|
||||
if (this.isSelected) {
|
||||
this.isSelected = false;
|
||||
if (this.destroySelection) {
|
||||
this.destroySelection(); // TODO: deprecate
|
||||
this.destroySelection(); // TOTO: deprecate
|
||||
}
|
||||
this.unrenderSelection();
|
||||
this.trigger('unselect', null, ev);
|
||||
@@ -8462,7 +8441,7 @@ var Calendar = FC.Calendar = Class.extend({
|
||||
overrides = viewOverrides[viewType];
|
||||
viewType = null; // clear. might repopulate for another iteration
|
||||
|
||||
if (typeof spec === 'function') { // TODO: deprecate
|
||||
if (typeof spec === 'function') { // TOTO: deprecate
|
||||
spec = { 'class': spec };
|
||||
}
|
||||
|
||||
@@ -8775,7 +8754,7 @@ function Calendar_constructor(element, overrides) {
|
||||
|
||||
|
||||
// Given an event's allDay status and start date, return what its fallback end date should be.
|
||||
// TODO: rename to computeDefaultEventEnd
|
||||
// TOTO: rename to computeDefaultEventEnd
|
||||
t.getDefaultEventEnd = function(allDay, zonedStart) {
|
||||
var end = zonedStart.clone();
|
||||
|
||||
@@ -9045,7 +9024,7 @@ function Calendar_constructor(element, overrides) {
|
||||
|
||||
/* Event Fetching/Rendering
|
||||
-----------------------------------------------------------------------------*/
|
||||
// TODO: going forward, most of this stuff should be directly handled by the view
|
||||
// TOTO: going forward, most of this stuff should be directly handled by the view
|
||||
|
||||
|
||||
function refetchEvents() { // can be called as an API method
|
||||
@@ -9210,7 +9189,7 @@ function Calendar_constructor(element, overrides) {
|
||||
|
||||
/* Height "Freezing"
|
||||
-----------------------------------------------------------------------------*/
|
||||
// TODO: move this into the view
|
||||
// TOTO: move this into the view
|
||||
|
||||
t.freezeContentHeight = freezeContentHeight;
|
||||
t.unfreezeContentHeight = unfreezeContentHeight;
|
||||
@@ -9323,7 +9302,7 @@ Calendar.defaults = {
|
||||
next: "next",
|
||||
prevYear: "prev year",
|
||||
nextYear: "next year",
|
||||
year: 'year', // TODO: locale files need to specify this
|
||||
year: 'year', // TOTO: locale files need to specify this
|
||||
today: 'today',
|
||||
month: 'month',
|
||||
week: 'week',
|
||||
@@ -9375,7 +9354,7 @@ Calendar.englishDefaults = { // used by lang.js
|
||||
|
||||
|
||||
Calendar.rtlDefaults = { // right-to-left defaults
|
||||
header: { // TODO: smarter solution (first/center/last ?)
|
||||
header: { // TOTO: smarter solution (first/center/last ?)
|
||||
left: 'next,prev today',
|
||||
center: '',
|
||||
right: 'title'
|
||||
@@ -9399,8 +9378,8 @@ Calendar.rtlDefaults = { // right-to-left defaults
|
||||
var langOptionHash = FC.langs = {}; // initialize and expose
|
||||
|
||||
|
||||
// TODO: document the structure and ordering of a FullCalendar lang file
|
||||
// TODO: rename everything "lang" to "locale", like what the moment project did
|
||||
// TOTO: document the structure and ordering of a FullCalendar lang file
|
||||
// TOTO: rename everything "lang" to "locale", like what the moment project did
|
||||
|
||||
|
||||
// Initialize jQuery UI datepicker translations while using some of the translations
|
||||
@@ -9547,8 +9526,8 @@ var momComputableOptions = {
|
||||
|
||||
|
||||
// options that should be computed off live calendar options (considers override options)
|
||||
// TODO: best place for this? related to lang?
|
||||
// TODO: flipping text based on isRTL is a bad idea because the CSS `direction` might want to handle it
|
||||
// TOTO: best place for this? related to lang?
|
||||
// TOTO: flipping text based on isRTL is a bad idea because the CSS `direction` might want to handle it
|
||||
var instanceComputableOptions = {
|
||||
|
||||
// Produces format strings for results like "Mo 16"
|
||||
@@ -9600,7 +9579,7 @@ FC.lang('en', Calendar.englishDefaults);
|
||||
|
||||
/* Top toolbar area with buttons and title
|
||||
----------------------------------------------------------------------------------------------------------------------*/
|
||||
// TODO: rename all header-related things to "toolbar"
|
||||
// TOTO: rename all header-related things to "toolbar"
|
||||
|
||||
function Header(calendar, options) {
|
||||
var t = this;
|
||||
@@ -10102,7 +10081,7 @@ function EventManager(options) { // assumed to be a calendar
|
||||
|
||||
if (source) {
|
||||
|
||||
// TODO: repeat code, same code for event classNames
|
||||
// TOTO: repeat code, same code for event classNames
|
||||
if (source.className) {
|
||||
if (typeof source.className === 'string') {
|
||||
source.className = source.className.split(/\s+/);
|
||||
@@ -10408,7 +10387,7 @@ function EventManager(options) { // assumed to be a calendar
|
||||
if (eventProps.allDay) {
|
||||
eventProps.start.stripTime();
|
||||
if (eventProps.end) {
|
||||
// TODO: consider nextDayThreshold here? If so, will require a lot of testing and adjustment
|
||||
// TOTO: consider nextDayThreshold here? If so, will require a lot of testing and adjustment
|
||||
eventProps.end.stripTime();
|
||||
}
|
||||
}
|
||||
@@ -10598,7 +10577,7 @@ function EventManager(options) { // assumed to be a calendar
|
||||
//
|
||||
// Returns a function that can be called to undo all the operations.
|
||||
//
|
||||
// TODO: don't use so many closures. possible memory issues when lots of events with same ID.
|
||||
// TOTO: don't use so many closures. possible memory issues when lots of events with same ID.
|
||||
//
|
||||
function mutateEvents(events, clearEnd, allDay, dateDelta, durationDelta, miscProps) {
|
||||
var isAmbigTimezone = t.getIsAmbigTimezone();
|
||||
@@ -10794,7 +10773,7 @@ function EventManager(options) { // assumed to be a calendar
|
||||
if (constraint != null) {
|
||||
|
||||
// not treated as an event! intermediate data structure
|
||||
// TODO: use ranges in the future
|
||||
// TOTO: use ranges in the future
|
||||
constraintEvents = constraintToEvents(constraint);
|
||||
|
||||
anyContainment = false;
|
||||
@@ -10952,7 +10931,7 @@ var BasicView = FC.BasicView = View.extend({
|
||||
// Generates the DayGrid object this view needs. Draws from this.dayGridClass
|
||||
instantiateDayGrid: function() {
|
||||
// generate a subclass on the fly with BasicView-specific behavior
|
||||
// TODO: cache this subclass
|
||||
// TOTO: cache this subclass
|
||||
var subclass = this.dayGridClass.extend(basicDayGridMethods);
|
||||
|
||||
return new subclass(this);
|
||||
@@ -10991,7 +10970,7 @@ var BasicView = FC.BasicView = View.extend({
|
||||
// Renders the view into `this.el`, which should already be assigned
|
||||
renderDates: function() {
|
||||
|
||||
this.dayNumbersVisible = this.dayGrid.rowCnt > 1; // TODO: make grid responsible
|
||||
this.dayNumbersVisible = this.dayGrid.rowCnt > 1; // TOTO: make grid responsible
|
||||
this.weekNumbersVisible = this.opt('weekNumbers');
|
||||
this.dayGrid.numbersVisible = this.dayNumbersVisible || this.weekNumbersVisible;
|
||||
|
||||
@@ -11664,13 +11643,13 @@ var AgendaView = FC.AgendaView = View.extend({
|
||||
|
||||
|
||||
getHitSpan: function(hit) {
|
||||
// TODO: hit.component is set as a hack to identify where the hit came from
|
||||
// TOTO: hit.component is set as a hack to identify where the hit came from
|
||||
return hit.component.getHitSpan(hit);
|
||||
},
|
||||
|
||||
|
||||
getHitEl: function(hit) {
|
||||
// TODO: hit.component is set as a hack to identify where the hit came from
|
||||
// TOTO: hit.component is set as a hack to identify where the hit came from
|
||||
return hit.component.getHitEl(hit);
|
||||
},
|
||||
|
||||
@@ -11781,7 +11760,7 @@ var AgendaView = FC.AgendaView = View.extend({
|
||||
|
||||
|
||||
// Methods that will customize the rendering behavior of the AgendaView's timeGrid
|
||||
// TODO: move into TimeGrid
|
||||
// TOTO: move into TimeGrid
|
||||
var agendaTimeGridMethods = {
|
||||
|
||||
|
||||
|
||||
@@ -463,7 +463,6 @@
|
||||
*
|
||||
* @see http://www.w3.org/TR/css3-background/#background-position
|
||||
*
|
||||
* @todo Since both Select2 and Bootstrap 3 only support IE8 and above,
|
||||
* we could use the :after-pseudo-element to display the loading indicator.
|
||||
* Alternatively, we could supply an altered loading indicator image which already
|
||||
* contains an offset to the right.
|
||||
|
||||
Reference in new issue
Block a user