String text-jquery Plugin

Source: Internet
Author: User

This is a jquery-based string effect plugin.

Have seen this effect before, have tried the idea but the skill point is not enough at that time. The day before yesterday on the train accidentally remembered this, seriously pondered, one go:D

It seems that the skill tree points are not too far off recently.

Effect Show use your mouse to cross the text below

String text string text strings string text string text string string text strings string text string text strings string text

The string words. The string words. The string words. The string words.

String text string text strings string text string text string string text strings string text string text strings string text

The string words. The string words. The string words. The string words.

String text string text strings string text string text string string text strings string text string text strings string text

The string words. The string words. The string words. The string words.

Specifically do the IE6 compatibility,, and do not know whether it is available, and then a picture:

Put the code on GitHub and welcome star ... Https://github.com/shalldie/qin

How to use:

1         $ (selector). Qin ({2             //  default, max offset 3             //  Default, Shaking time 4             //  default, offset per pixel, smaller "the tighter the strings"5         });

The container needs to give a positioning, such as: Relative,absolute

It's not a very complicated thing to tell me about my ideas.

Effect:

    1. The mouse enters the container and is able to drag text.
    2. The dragged text will drive the nearby text, there is a descending drag distance, the farther is driven the less.
    3. Drag to a certain extent, the text will bounce back, there is a shaking effect.

Ideas:

    1. The text inside the container is split into a span. Use MouseMove to monitor the mouse.
    2. How much distance the mouse moves within the container (MouseEnter to determine the initial position), the text also moves in the same direction, moving the same distance. The distance between the text in the vicinity decreases and the minimum movement is 0.
    3. Set a maximum moving distance when the mouse moves beyond this maximum to start the rebound effect. The bounce effect is done with an easing function.

Enjoy it!

String text-jquery Plugin

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.