From 0b31b48ed04ebb070e95efa13e82442c64aa9d0e Mon Sep 17 00:00:00 2001 From: Ingo Schommer Date: Fri, 31 Mar 2017 15:17:13 +1300 Subject: [PATCH] Wider TimeField styling MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Account for HTML5 time fields which have a “clear” button rendered in the field by the browser --- client/dist/js/bundle.js | 12 ++++++------ client/dist/styles/bundle.css | 2 +- client/src/styles/legacy/_forms.scss | 2 +- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/client/dist/js/bundle.js b/client/dist/js/bundle.js index 726be4215..5fd83567a 100644 --- a/client/dist/js/bundle.js +++ b/client/dist/js/bundle.js @@ -1594,13 +1594,13 @@ var t=e.prevAll("li.selected") t.length&&t.removeClass("selected") var n=e.nextAll("li.selected") n.length&&n.removeClass("selected"),(0,i.default)(this).focus()})})},function(e,t,n){"use strict" -function a(e){return e&&e.__esModule?e:{default:e}}var r=n(1),i=a(r),s=n(204),o=a(s),d=n(321),u=a(d) -n(322),i.default.entwine("ss",function(e){e("input[type=date]").entwine({onadd:function t(){if(!u.default.inputtypes.date&&!(this.prop("disabled")||this.prop("readonly")||this.hasClass("hasDatepicker"))){ +function a(e){return e&&e.__esModule?e:{default:e}}var r=n(1),i=a(r),s=n(114),o=a(s),d=n(204),u=a(d),l=n(321),c=a(l) +n(322),i.default.entwine("ss",function(e){e("input[type=date]").entwine({onadd:function t(){if(!c.default.inputtypes.date&&!(this.prop("disabled")||this.prop("readonly")||this.hasClass("hasDatepicker"))){ var n=e("",{type:"hidden",name:this.attr("name"),value:this.val()}) -this.parent().append(n),this.removeAttr("name"),o.default.locale(this.attr("lang")) -var a=this.val(),r=(0,o.default)(a).format("L") -this.val(r),this.attr("placeholder","Example: "+(0,o.default)().endOf("month").format("L")),this.updateValue()}},onchange:function e(){this.updateValue()},updateValue:function e(){var t=this.val(),n=(0, -o.default)(t,"L").format("YYYY-MM-DD") +this.parent().append(n),this.removeAttr("name"),u.default.locale(this.attr("lang")) +var a=this.val(),r=(0,u.default)(a).format("L") +this.val(r),this.attr("placeholder",o.default._t("DateField.DateFormatExample")+": "+(0,u.default)().endOf("month").format("L")),this.updateValue()}},onchange:function e(){this.updateValue()},updateValue:function e(){ +var t=this.val(),n=(0,u.default)(t,"L").format("YYYY-MM-DD") this.parent().find("input[type=hidden]").val(n)}})})},function(e,t,n){(function(e){!function(t,n){e.exports=n()}(this,function(){"use strict" function t(){return ba.apply(null,arguments)}function a(e){ba=e}function r(e){return e instanceof Array||"[object Array]"===Object.prototype.toString.call(e)}function i(e){return null!=e&&"[object Object]"===Object.prototype.toString.call(e) diff --git a/client/dist/styles/bundle.css b/client/dist/styles/bundle.css index c0d749650..a2eb461f6 100644 --- a/client/dist/styles/bundle.css +++ b/client/dist/styles/bundle.css @@ -8872,7 +8872,7 @@ fieldset{ } .field input.time{ - width:88px; + width:112px; } .field.remove-splitter{ diff --git a/client/src/styles/legacy/_forms.scss b/client/src/styles/legacy/_forms.scss index dbcb5038c..651968d65 100644 --- a/client/src/styles/legacy/_forms.scss +++ b/client/src/styles/legacy/_forms.scss @@ -305,7 +305,7 @@ form.small .field, .field.small { } input.time { - width: ($grid-x * 11); // smaller time field, since input is restricted + width: ($grid-x * 14); // smaller time field, since input is restricted } /* Hides borders in settings/access. Activated from JS */