Ticket #3891 (closed enhancement: fixed)

Opened 20 months ago

Last modified 14 months ago

Autosize input field

Reported by: mdiaz Owned by:
Priority: minor Milestone: 1.8
Component: ui.datepicker Version: 1.6rc5
Keywords: Cc:

Description

Set the input field size attribute (if not already set) based on an estimate: the length of a formatted date (e.g. today's date). This could be disabled with a flag in the settings (e.g. autosize=true/false).

A working implementation: add the following two lines to _connectDatepicker:

if (this._get(inst, 'autosize') && !input.attr('size'))

input.attr('size', this.formatDate(this._get(inst, 'dateFormat'), new Date(), this._getFormatConfig(inst)).length);

Change History

Changed 18 months ago by rdworth

  • milestone changed from 1.7 to 1.8

Changed 14 months ago by kbwood

  • status changed from new to closed
  • resolution set to fixed

Fixed in r2957. Set the autoSize option to true.

Note: See TracTickets for help on using tickets.