translate3d() CSS Function
Description
The translate3d()
CSS function is used to move elements in a three-dimensional space.
Syntax
transform: translate3d( tx, ty, tz);
Values
- txHorizontal shift. A positive value shifts to the right, a negative value to the left.
- tyVertical shift. A positive value moves up, a negative value down.
- tzA positive value moves the element towards the viewer, and a negative value farther away.
Example
<img class="translate" src="images/nature.jpg" alt="Nature Image">
.translate {
transform: perspective(200px) translate3d(40px, 40px, 40px);
}
Browser Support
Desktop | |||||
? | ? | ? | ? | ? | ? |
Tablets / Mobile | |||||
![]() |
|||||
? | ? | ? | ? | ? | ? |
Last updated by CSSPortal on: 1st December 2019
CSS Functions
- attr()
- blur()
- brightness()
- calc()
- circle()
- contrast()
- drop-shadow()
- ellipse()
- grayscale()
- hsl()
- hsla()
- hue-rotate()
- inset()
- invert()
- linear-gradient()
- matrix()
- matrix3d()
- opacity()
- perspective()
- polygon()
- radial-gradient()
- repeating-linear-gradient()
- repeating-radial-gradient()
- rgb()
- rgba()
- rotate()
- rotate3d()
- rotateX()
- rotateY()
- rotateZ()
- saturate()
- scale()
- scale3d()
- scaleX()
- scaleY()
- scaleZ()
- sepia()
- skew()
- skewX()
- skewY()
- translate()
- translate3d()
- translateX()
- translateY()
- translateZ()