From 8c34d09861f7ee31640a018515d2fe2756f7520b Mon Sep 17 00:00:00 2001 From: rolux Date: Wed, 30 Nov 2011 15:43:47 +0100 Subject: [PATCH] in Input, allow for setting labelWidth option --- source/Ox.UI/js/Form/Ox.Input.js | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/source/Ox.UI/js/Form/Ox.Input.js b/source/Ox.UI/js/Form/Ox.Input.js index b46cdca3..b46ae749 100644 --- a/source/Ox.UI/js/Form/Ox.Input.js +++ b/source/Ox.UI/js/Form/Ox.Input.js @@ -834,6 +834,15 @@ Ox.Input = function(options, self) { self.$input.css({ height: value + 'px' }); + } else if (key == 'labelWidth') { + self.$label.options({width: value}); + inputWidth = getInputWidth(); + self.$input.css({ + width: inputWidth + 'px' + }); + self.hasPasswordPlaceholder && self.$placeholder.css({ + width: inputWidth + 'px' + }); } else if (key == 'placeholder') { setPlaceholder(); } else if (key == 'value') {