Swipe, rotate or pinch a layer between any two positions, rotations or scales, with added bouncy animations from Pop Animation.
Use the Touch button on a layer to quickly add interactions.
在任意兩個(gè)位置之間劃動(dòng)、旋轉(zhuǎn)或捏旋轉(zhuǎn)或捏一個(gè)圖層,和 Pop Animation模塊一起用添加彈性動(dòng)畫(huà)。
使用圖層右上角的Touch按鈕快速添加交互。

輸入口
Enable 啟用
A boolean that is true when the gesture is enabled.
勾選啟用這個(gè)模塊。
Layer 圖層
The layer to capture gestures from.
用來(lái)捕捉手勢(shì)的圖層。
Gesture 手勢(shì)
The gesture to detect. The options:
手勢(shì)選項(xiàng):(板栗:用什么手勢(shì)激活開(kāi)關(guān))
- Swipe X
- Swipe Y
- Pinch Scale
- Pinch Rotate
- Pinch X
- Pinch Y
- X軸向滑動(dòng)
- Y軸向滑動(dòng)
- 捏住縮放
- 捏住旋轉(zhuǎn)
- 捏X軸向
- 捏Y軸向
Start Value 開(kāi)始值
A number that represents the default position, scale or rotation of the layer.
表示圖層動(dòng)畫(huà)位置、比例或角度的初始值。
End Value 結(jié)束值
A number that represents the second position, scale or rotation of the layer that the gesture should animate towards.
表示圖層動(dòng)畫(huà)位置、比例或角度的最終值。
Flip 翻轉(zhuǎn)
A pulse that flips the state of the switch (from on to off, or vice versa), which will also animate the value to the corresponding number.
翻轉(zhuǎn)Start Value開(kāi)始值和End Value 結(jié)束值。
Turn On 打開(kāi)
A pulse that turns the switch on, which will also animate the value to the end value. If the switch is already on, the pulse has no effect.
接通開(kāi)關(guān)的操作,也將動(dòng)畫(huà)值轉(zhuǎn)化為最終值。如果開(kāi)關(guān)已經(jīng)打開(kāi)則操作無(wú)效。
Turn Off 關(guān)閉
A pulse that turns the switch off, which will also animate the value to the start value. If the switch is already off, the pulse has no effect.
關(guān)閉開(kāi)關(guān)的操作,也將動(dòng)畫(huà)的值轉(zhuǎn)化為開(kāi)始值。如果開(kāi)關(guān)已經(jīng)關(guān)閉則操作無(wú)效。
Bounciness 彈性
A number that represents the bounciness of the animation.
一個(gè)表示動(dòng)畫(huà)彈性的數(shù)字。
(板栗:值越大彈性越大)
Speed 速度
A number that represents the speed of the animation.
一個(gè)表示動(dòng)畫(huà)速度的數(shù)字。
(板栗:值越大速度越快)
輸出口
Value 值
A number that represents the current position, rotation or scale. Connect to the position X, position Y, rotation Z, or scale of the layer.
表示當(dāng)前位置、角度或比例的數(shù)字。連接到層的Position X、PositionY、Rotation Z或Scale。
Progress 進(jìn)度
A progress value that represents the animation progress between the start and end values. See Animation Basics for more information.
表示動(dòng)畫(huà)在起始值和結(jié)束值之間的進(jìn)度值。見(jiàn)動(dòng)畫(huà)基礎(chǔ)獲取更多信息。
On/Off 開(kāi)/關(guān)
A boolean that is true either: - when the current position, rotation or scale of the gesture is closer to the end value than the start value. - when the switch is flipped, turned on, or turned off with a pulse.
符合以下兩種情況中的一個(gè)時(shí)布爾值為真:
- 當(dāng)手勢(shì)的當(dāng)前位置、旋轉(zhuǎn)或比例接近起始值時(shí)。
- 當(dāng)開(kāi)關(guān)有翻轉(zhuǎn),打開(kāi),或關(guān)閉的操作。
(板栗:哎耶上面寫(xiě)的其實(shí)不知道啥哎~)
Related Examples 案例
Instagram Notifications
Switch between notifications with animation.