What is the method for smoothly transitioning the vertical flip of an image within its current position using CSS?

Can someone help me figure out how to smoothly flip my image vertically using rotateX after a few minutes at its center position? The image is flipping, but not on its actual center. It seems to be rotating from a point above the image. I've tried adjusting the rotation coordinates with no success. Any assistance would be greatly appreciated.

You can view my code on JsFiddle:

https://jsfiddle.net/bh7x7weg/

Thank you in advance!

Answer №1

Make sure to specify your image's origin as transform-origin: center center;. Additional information on this style can be found here.

Check out this example at https://jsfiddle.net/bh7x7weg/3/

Similar questions

If you have not found the answer to your question or you are interested in this topic, then look at other similar questions below or use the search

Adjustable block with excess content

Forgive me if this question seems basic, but I'm not very familiar with CSS. I have a table with two columns that need to be equally sized and responsive when the page is resized. The header isn't an issue since it only contains a few words in ...

Tips for removing excess whitespace in a popover menu

I am having trouble removing the white margin/gutter in the popover, in order to make the yellow buttons cover the entire width of the popover. How can I accomplish this? https://i.sstatic.net/4iuRu.png Code: <button type="button" data-htm ...

Execute ReactJS function only if query parameters are configured

Provide an Explanation: Within the useEffect, I am retrieving products using the getProducts() function based on the provided data. The data contains search filters that can be updated by the user in real-time. For instance, the data consists of an object ...

Select component experiencing issue with Material Ui label breaking

I've been working on implementing a select component, which is new to me. However, I'm encountering an issue with my MUI-select component. The label of the select element is no longer syncing properly with the select component itself as shown in ...

Is it possible to make the dashboard reach 100% height?

I am struggling with designing a dashboard that needs to take up 100% of the height of any monitor. Despite reading multiple posts on Stackoverflow and trying different options like hv 100% and height: 100%, I still can't get it to work. I am using Bo ...

Battle of the Browsers: Firefox vs Chrome/IE Design

Excited to be part of this community and looking forward to tapping into so much knowledge here! I have noticed that my website, , appears differently on Firefox compared to Chrome and IE. The gray background only shows on Firefox, while Chrome and IE dis ...

The placement of the sliding navigation menu is consistently positioned beneath the header

I created a jQuery menu that's also available on JSfiddle here: $(document).ready(function () { $(".navigation_button").on('click', function () { var $panel = $(this).next('.panel'); if ($panel.is(':visible ...

Try implementing a body template when using the mailto function

Is there a way to customize an HTML template for the mailto() function body? For example, suppose I have the following link: echo "<a href="mailto:<a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="97f2faf6fefbd7f0faf6fefbb ...

Utilize JSX to dynamically insert HTML tags onto a webpage

I am trying to achieve a specific task in JSX, where I want to identify all strings enclosed within delimiters :; and wrap them with HTML Mark tags to highlight them. However, the current implementation is not rendering the tags as expected. Is there a sol ...

Unable to make a choice from the dropdown list

Recently, I started learning about selenium and encountered challenges when it comes to selecting elements from dropdown menus. The issue arises when I try to implement the code using PhantomJS - the same code that works perfectly fine with Firefox as WebD ...

Achieve full div coverage within parent container

I am seeking assistance with positioning divs correctly within my HTML structure: <div class="container"> <div class="item"> <div class="left"> lorem lorem </div> <div class="right"> ...

"Adjusting the Width of Inner Content in a Div

Here is the structure of a div: <div id="showHide"> <div>Alarm</div> <div>Alarmasdf</div> <div>Alarmasdffasdff</div> How can I obtain the width of the largest content, such as "Alarmasdffasdff"? I hav ...

Tips for preventing the parent element's height from fluctuating when displaying a child div using v-if

I have a main container and an inner container. The inner container is displayed using v-if. I want to include a transition effect on the inner element, but after the transition ends, the height of the parent container changes abruptly and looks unattracti ...

Using AJAX to update the value of a div by clicking within a PHP loop

I'm currently working on a php page where I want to dynamically change the content of a div when a specific link is clicked. The links are generated through a loop, and I need to pass multiple parameters via the URL. Since the divs are also created wi ...

After the introduction of ReactiveFormsModule, the functionality of the Angular router has ceased

I am working on setting up a reactive form in Angular for a login page. Here is my login form: <form [formGroup]="loginForm" (ngSubmit)="login(loginForm.value)"> <div class="form-group"> <label for="username">Username</label> ...

Is there a way to incorporate vue samples into an independent HTML document?

Striving to broaden my knowledge of Vue, I set out to create a page with tabs inspired by one of the Vue examples available at . However, an obvious error seems to be eluding me, as I encounter a syntax issue on the line import * as Tabs from 'vue-s ...

Arranging objects in an array based on their specific property

My DataBase collection looks like this: var items = [{ 'Name':'Michael', 'TypeId':1 } { 'Name':'Max', 'TypeId':1 } { 'Name':'Andre', 'TypeId':1 } ...

Understanding the process of reading cookies on the Angular2 side that have been set by the C# server

I'm struggling to understand how the angular code can access the cookie that was set on the server side. I found the following code snippet on GitHub. This C# function sets the cookie in the Response object with the last line of code. My question is, ...

Delineating the exact widths of columns without the need for additional wrapping columns

Below is the HTML / CSS code for a Bootstrap navbar. Take a look at the screenshot to see how I want it to appear. I want the navigation bar to align with the left side of #three and be the same width as it. I'm trying to avoid putting it inside a c ...

Converting a buffer to a string in Python 3, similar to Node.js 6.0.0

I am currently in the process of translating an old node.js library into Python and I am facing difficulties trying to replicate the behavior of Buffer.toString() in Python. The library is used in a node 6.0.0 environment. While researching, I came acros ...