I want to create the effect of the picture below. There are currently 6 pictures and there are two questions
1. How to start from the first or last picture without interruption after moving to the left or rightmost position
2 .How to create the maximum effect of the middle position picture?
I hope experienced students can provide ideas
Element UI’s revolving lantern has similar effects, you can refer to it. (See the [card] effect at the bottom)
Examples
1. Like the carousel picture, add one at the end that is exactly the same as the first one. For example, this structure is 1234561.
2. There are two biggest effects, one is to enlarge the entire image, and the other is to enlarge only the height and width content unchanged. The former uses scale, and the latter directly changes the width and height.
My thoughts are as above
CSS focuses on settings
.view
的overflow-x
为hidden
Also
.container
的absolute
This way, the
.container
left change can be converted into which looks like scrollingThe problem now is to make the middle one bigger
According to the routine, you also need to write
.iambig
as the enlarged styleAfter all preparations are done:
Convert the problem into a data problem
Render the data
After everything is ready, bind the exposed next pre render to the corresponding button
PS: Pre, next remember to render after changing the data
Basic knowledge required
CSS overflow, absolute width and other basic CSS postures
Array.prototype.forEach, common methods of jQuery, etc.
= = . . . . hope this helps.
Look for plug-ins on Baidu, they are everywhere on the Internet