Search code examples
nativescriptnativescript-angular

Resize stacklayout scrollview nativescript


Hello I am trying to make a stacklayout change its size (heigth) by scrolling up or down is it possible?


Solution

  • Yes it is possible. use this way.

    <DockLayout stretchLastChild="false" class="page-background">
      <GridLayout rows="30*, 70*">
        <GridLayout row="0" borderBottomWidth="3" borderColor="#af152d" rows="auto" class="logo-container">
            <GridLayout rows="*" row="0" class="image-container"></GridLayout>
        </GridLayout>
        <GridLayout row="1" rows="*" orientation="vertical">            
            <ScrollView row="0" orientation="vertical">
                <StackLayout verticalAlignment="top">
                </StackLayout>
            </ScrollView>
        </GridLayout>
      </GridLayout>
    </DockLayout>