Transition Property
ویژگی transition-property
مشخص میکنه که کدوم خصوصیات CSS هنگام اعمال transition انیمیشن داشته باشن.
مثلاً:
📑 کلاسهای Tailwind برای Transition Property
Tailwind چندین کلاس آماده برای کنترل این ویژگی داره:
کلاس | CSS متناظر |
---|---|
transition-none | transition-property: none; |
transition-all | transition-property: all; |
transition | transition-property: color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter; |
transition-colors | transition-property: color, background-color, border-color, text-decoration-color, fill, stroke; |
transition-opacity | transition-property: opacity; |
transition-shadow | transition-property: box-shadow; |
transition-transform | transition-property: transform; |
📌 مثال ساده
⚡ ترکیب با Duration و Ease
تو میتونی transition-property
رو با کلاسهای دیگه مثل:
-
duration-300
(مدت زمان) -
ease-in-out
(الگوی سرعت) -
delay-200
(تاخیر)
ترکیب کنی.
مثال: