Results 1 to 3 of 3

Thread: Questions regarding responsiveConfig and implementation.

  1. #1
    Sencha User
    Join Date
    Aug 2017
    Posts
    47
    Answers
    1

    Default Answered: Questions regarding responsiveConfig and implementation.

    I have some questions about responsiveConfig and hoping Sencha community can help me with a few questions.

    1. I am using Portrait on a text field
    In the docs says,
    • portrait - True if the device orientation is portrait (always false on desktop devices)

    It says always false on Desktop but when I make my window smaller it still does change within desktop why is that?

    2. responsiveConfig is working with width, height, and margin. I cannot get it to work with labelStyle. What am I doing wrong in my code that its not changing the font-size?

    3. Like I said in #2 some of the styles are working but I don't understand why they are not reverting back to its original size when I decide to make window bigger. If i make window small, changes will work as they should, but when I make window bigger size it does not change.

    I know that these are a lot of questions, but I'm hoping the rest of the community can also benefit from them.

    Code:
     items: [
            {
                xtype: 'fieldset',
                margin: 100,
                responsiveConfig: {    ///////////FieldSet Responsive Starts Here ///////////////
                    '500 > width': {
                        width: 500,
                        height: 300,
                        margin: 30
                    }
                },
                items: [
                    {
                        xtype: 'textfield',
                        anchor: '80%',
                        height: 30,
                        margin: 15,
                        responsiveConfig: {   //////////////////textField Responsive Starts Here//////////////
                            '500 > width': {
                                width: 10,
                                height: 100,
                                labelStyle: {
                                    'font-size': '50px'
                                }
                            },                        
                        },
                        fieldLabel: 'FieldOne',
                        labelStyle: 'font-size: 10px ',
                        inputType: 'Typen in your Name',
                        plugins: [
                            {
                                ptype: 'responsive'
                            }
                        ]
                    },
                     
                ],
                plugins: [
                    {
                        ptype: 'responsive'
                    }
                ]
            }
        ]

  2. Hi,

    Answering your questions

    1) Portrait and Landscape should only change if Ext.feature.has.Orientation is true. This should always be false on desktops. So if you type this on your console and it returns false and the portrait/landscape configs still work, please report here because it is a BUG.

    2 and 3) Check the last line on the Note here: http://docs.sencha.com/extjs/6.5.2/c...sponsiveConfig .
    "For a config to participate as a
    responsiveConfig it must have a "setter" method. In the above example, a "setRegion" method must exist. "

  3. #2
    Sencha - Support Team
    Join Date
    Mar 2015
    Location
    Chicago
    Posts
    239
    Answers
    40

    Default

    Hi,

    Answering your questions

    1) Portrait and Landscape should only change if Ext.feature.has.Orientation is true. This should always be false on desktops. So if you type this on your console and it returns false and the portrait/landscape configs still work, please report here because it is a BUG.

    2 and 3) Check the last line on the Note here: http://docs.sencha.com/extjs/6.5.2/c...sponsiveConfig .
    "For a config to participate as a
    responsiveConfig it must have a "setter" method. In the above example, a "setRegion" method must exist. "
    Guilherme Lopes
    Sencha Support

  4. #3
    Sencha User
    Join Date
    Aug 2017
    Posts
    47
    Answers
    1

    Default

    Thanks for the help, friend!

Similar Threads

  1. Replies: 6
    Last Post: 4 Aug 2017, 2:41 PM
  2. wrong panels layout when using responsiveConfig
    By pkoral in forum Ext 5: Bugs
    Replies: 0
    Last Post: 9 Jun 2016, 3:56 AM
  3. Universal App and 'responsiveConfig'
    By jhoweaa in forum Ext JS 6.x Q&A
    Replies: 2
    Last Post: 9 Sep 2015, 1:54 PM
  4. ResponsiveConfig with dynamic width
    By s.noel in forum Ext 5: Q&A
    Replies: 0
    Last Post: 26 Nov 2014, 1: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
  •