CC-2512:Small browser window causes day/week/month buttons to
overlap Calendar - fixed - also margin was adjusted to more reasonable size
This commit is contained in:
parent
8f681de498
commit
752f60bd76
|
@ -426,10 +426,12 @@ $(document).ready(function() {
|
||||||
$(window).resize(function(){
|
$(window).resize(function(){
|
||||||
var windowWidth = $(this).width();
|
var windowWidth = $(this).width();
|
||||||
// margin on showform are 16 px on each side
|
// margin on showform are 16 px on each side
|
||||||
var calendarWidth = 100-(($("#schedule-add-show").width() + (16 * 6))/windowWidth*100);
|
if(!$("#schedule-add-show").is(':hidden')){
|
||||||
var widthPercent = parseInt(calendarWidth)+"%";
|
var calendarWidth = 100-(($("#schedule-add-show").width() + (16 * 4))/windowWidth*100);
|
||||||
$("#schedule_calendar").css("width", widthPercent);
|
var widthPercent = parseInt(calendarWidth)+"%";
|
||||||
$("#schedule_calendar").fullCalendar('render');
|
$("#schedule_calendar").css("width", widthPercent);
|
||||||
|
$("#schedule_calendar").fullCalendar('render');
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
$(window).load(function() {
|
$(window).load(function() {
|
||||||
|
|
|
@ -15,7 +15,7 @@ function openAddShowForm() {
|
||||||
$("#add-show-form").show();
|
$("#add-show-form").show();
|
||||||
var windowWidth = $(window).width();
|
var windowWidth = $(window).width();
|
||||||
// margin on showform are 16 px on each side
|
// margin on showform are 16 px on each side
|
||||||
var calendarWidth = 100-(($("#schedule-add-show").width() + (16 * 6))/windowWidth*100);
|
var calendarWidth = 100-(($("#schedule-add-show").width() + (16 * 4))/windowWidth*100);
|
||||||
var widthPercent = parseInt(calendarWidth)+"%";
|
var widthPercent = parseInt(calendarWidth)+"%";
|
||||||
$("#schedule_calendar").css("width", widthPercent);
|
$("#schedule_calendar").css("width", widthPercent);
|
||||||
$("#schedule_calendar").fullCalendar('render');
|
$("#schedule_calendar").fullCalendar('render');
|
||||||
|
|
Loading…
Reference in New Issue