Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

164
Views
Animate to scale down a view on scroll

in my react-native app when scroll position is higher than 0 I want to smoothly animate a circle view to be like 25% smaller:

transform: [{ scaleX: .8 }, { scaleY: .8 }]

when user scrolls back to top I want the circle to smoothly animate back to normal size:

//import * as React from 'react';
import { View, Animated, ScrollView } from 'react-native';
import React, { useState, useEffect,useRef } from 'react'


export default CustomScrollBarOverNormalScrollBar = (props) => 
{
    const onScroll = () =>
    {
        console.log('User scrolled');
    };

    return(
    <View style={{flex:1}}>
        <ScrollView showsVerticalScrollIndicator={false} scrollEventThrottle={16} style={{flex:1,backgroundColor:'white',position:'relative'}} 
            onScroll={onScroll}>
                <View style={{ width:'100%', height:700, backgroundColor:'rgb(235,235,235)' }}></View>
        </ScrollView>
        <View style={{width:'100%',height:100,position:'absolute',bottom:0,left:0, alignItems:'center',justifyContent:'center'}}>
            {/*TI WANT TO SCALE THIS CIRCLE*/}
            <View style={{ width:100,height:100,borderRadius:100%2,backgroundColor:'red' }}>  </View>
            {/*I WANT TO SCALE THIS CIRCLE*/}
        </View>
    </View>
    );    
};
about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!