mirror of
				https://github.com/elyby/accounts-frontend.git
				synced 2025-05-31 14:11:58 +05:30 
			
		
		
		
	Fix scroll direction for the SlideMotion component
This commit is contained in:
		@@ -77,9 +77,8 @@ class SlideMotion extends React.PureComponent<Props, State> {
 | 
			
		||||
                        <div
 | 
			
		||||
                            className={styles.container}
 | 
			
		||||
                            style={{
 | 
			
		||||
                                // TODO: inverse for RTL language
 | 
			
		||||
                                WebkitTransform: `translateX(-${interpolatingStyle.transform}%)`,
 | 
			
		||||
                                transform: `translateX(-${interpolatingStyle.transform}%)`,
 | 
			
		||||
                                // @ts-ignore see https://stackoverflow.com/a/52013197/5184751
 | 
			
		||||
                                '--transition-progress': `${interpolatingStyle.transform}%`,
 | 
			
		||||
                            }}
 | 
			
		||||
                        >
 | 
			
		||||
                            {React.Children.map(children, (child, index) => (
 | 
			
		||||
 
 | 
			
		||||
@@ -1,5 +1,11 @@
 | 
			
		||||
.container {
 | 
			
		||||
    white-space: nowrap;
 | 
			
		||||
    transform: translate(var(--transition-progress));
 | 
			
		||||
 | 
			
		||||
    html[dir='ltr'] & {
 | 
			
		||||
        // noinspection CssInvalidFunction works fine in a browser (:
 | 
			
		||||
        transform: translate(calc(var(--transition-progress) * -1));
 | 
			
		||||
    }
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
.item {
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user