【问题标题】:Jquery Ui Datepicker table enormously larger then expect, how to resolve this issueJquery Ui Datepicker 表比预期的要大得多,如何解决这个问题
【发布时间】:2018-07-06 16:39:21
【问题描述】:

This is a picture of how large the calendar is coming out

我已经在检查模式下对 CSS 进行了检查,以找到一个可以调整它但不成功的类或 ID,但在尝试了每种尺寸后,没有任何东西调整过尺寸,有趣的是数字按钮日期根本没有调整我是能够使框达到文本框的大小,但不能使圆形按钮完全改变其大小。如果有人对此有解决方案,请提供帮助。

 @Html.EditorFor(model => model.pickupDate, new { htmlAttributes = new { @class = "datepicker", @placeholder = "Select Date..." } })

@Html.EditorFor(model => model.dropoffDate, new { htmlAttributes = new { @class = "datepicker2", @placeholder = "Select Date..." } })

                <script>

                    $(function () {
                        $(".datepicker2").datepicker({

                            changeMonth: true,
                            changeYear: true,
                            // showOn: "both",
                            // buttonImage: "/images/cal.png",
                            //buttonImageOnly: true

                        });
                        $(".datepicker").datepicker({

                            changeMonth: true,
                            changeYear: true,
                            // showOn: "both",
                            //  buttonImage: "/images/cal.png",
                            //  buttonImageOnly: true
                        });

                    });

【问题讨论】:

标签: javascript jquery html model-view-controller jquery-ui-datepicker


【解决方案1】:

我自己解决了这个问题!

如果你的砑光机像我的一样大,然后检查页面,你会发现这个 id="ui-datepicker-div" 和 class=".ui-state-default" 然后调整到你想要的任何大小。就像我做这个尺寸一样。

#ui-datepicker-div {
    font-size: 12px;
    width:300px;
}
.ui-state-default{
    width:35px;
}

Much better size in this link check it out

【讨论】:

    猜你喜欢
    • 2013-12-19
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2019-08-04
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多