Results 1 to 5 of 5

Thread: Modern: labelAlign layout in Ext.field.Text

    Success! Looks like we've fixed this one. According to our records the fix was applied for EXTJS-25954 in 6.5.2.
  1. #1
    Sencha Premium User
    Join Date
    Sep 2010
    Location
    UK
    Posts
    134

    Default Modern: labelAlign layout in Ext.field.Text

    In SA 4.2.1, the default value of labelAlign for Ext.field.Text is 'left'.

    So the default look for text fields in Sencha looks like this

    screen.png

    However, the effect is more like 'placeholder'. If I set labelAlign explicitly in the defaults config in the parent form,

    PHP Code:
    defaults: {
       
    labelAlign'left'

    , I get this
    screen1.png

    which behaves as I expect but the documentation said the default value is 'left'.

    So what is what? I am confused.

    Joe
    Attached Images Attached Images

  2. #2
    Sencha User
    Join Date
    Sep 2014
    Location
    Central Europe
    Posts
    795

    Default

    Thanks for the report. I have moved the thread to the Ext bug forums. It looks like the default value is not 'left 'but rather 'placeholder'.
    http://docs.sencha.com/extjs/6.5.1/m...cfg-labelAlign

    Testable fiddle https://fiddle.sencha.com/#view/editor&fiddle/23i6

  3. #3
    Sencha Premium User evant's Avatar
    Join Date
    Apr 2007
    Location
    Sydney, Australia
    Posts
    19,250

    Default

    It's not really a bug. The default is left, however material changes that default. I don't know if we have a good way of documenting changes made to defaults by theme.
    Twitter - @evantrimboli
    Former Sencha framework engineer, available for consulting.
    As of 2017-09-22 I am not employed by Sencha, all subsequent posts are my own and do not represent Sencha in any way.

  4. #4
    Sencha Premium User
    Join Date
    Sep 2010
    Location
    UK
    Posts
    134

    Default

    Okay I see. So I guess the bug is really on the SA side that should pick up the new default when I use the material theme. Right? Currently, SA won't let me directly set the labelAlign to 'left' because it thinks it is already the default value.

  5. #5
    Sencha User
    Join Date
    Sep 2014
    Location
    Central Europe
    Posts
    795

    Default

    There are 2 problems.

    1# It's not correctly documented. SA strictly follows documentation in the SA config definitions. EXTJS-25954
    2# SA is not prepared for this scenario. I have created a ticket DSGNR-7992

    Workarounds:
    # Use the default config as you did
    # Use data-binding from the ViewModel
    # Use process config in the SA https://youtu.be/lLmLD3unWO4
    # If you want I can send you instructions to remove the default value in your SA installation. But this would work only in your installation of SA. If you would open the project in other installation of SA the config would be deleted. If you are interested in this, please write me PM.

    Regards
    Petr

Similar Threads

  1. Modern Toolkit - Typeahead support for Text Field
    By javachap in forum Ext JS 6.x Q&A
    Replies: 1
    Last Post: 5 Jun 2017, 1:03 PM
  2. ExtJS 6 modern toolkit: How to set focus on text field
    By Boris795 in forum Ext JS 6.x Q&A
    Replies: 5
    Last Post: 14 Feb 2017, 4:45 AM
  3. [OPEN] [Modern] Ext.field.Text -> reset()
    By tobiu in forum Ext JS 6.x Bugs
    Replies: 3
    Last Post: 21 Jul 2016, 7:19 PM
  4. Replies: 2
    Last Post: 16 Sep 2015, 6:07 PM
  5. Replies: 1
    Last Post: 3 Sep 2014, 5:58 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •