You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

866 lines
14 KiB

  1. /*******************************
  2. Semantic - Transition
  3. Author: Jack Lukic
  4. CSS animation definitions for
  5. transition module
  6. *******************************/
  7. /*
  8. Some transitions adapted from Animate CSS
  9. https://github.com/daneden/animate.css
  10. */
  11. .ui.transition {
  12. -webkit-backface-visibility: hidden;
  13. -moz-backface-visibility: hidden;
  14. -ms-backface-visibility: hidden;
  15. -o-backface-visibility: hidden;
  16. backface-visibility: hidden;
  17. -webkit-animation-iteration-count: 1;
  18. -moz-animation-iteration-count: 1;
  19. -ms-animation-iteration-count: 1;
  20. -o-animation-iteration-count: 1;
  21. animation-iteration-count: 1;
  22. -webkit-animation-duration: 1s;
  23. -moz-animation-duration: 1s;
  24. -ms-animation-duration: 1s;
  25. -o-animation-duration: 1s;
  26. animation-duration: 1s;
  27. animation-timing-function: ease;
  28. -webkit-animation-timing-function: ease;
  29. -webkit-animation-fill-mode: both;
  30. -moz-animation-fill-mode: both;
  31. -ms-animation-fill-mode: both;
  32. -o-animation-fill-mode: both;
  33. animation-fill-mode: both;
  34. -webkit-transform: translateZ(0);
  35. -moz-transform: translateZ(0);
  36. -ms-transform: translateZ(0);
  37. -o-transform: translateZ(0);
  38. transform: translateZ(0);
  39. }
  40. /*******************************
  41. States
  42. *******************************/
  43. /* Loading */
  44. .ui.loading.transition {
  45. position: absolute;
  46. top: -999999px;
  47. left: -99999px;
  48. }
  49. /* Hidden */
  50. .ui.hidden.transition {
  51. display: none;
  52. }
  53. /* Visible */
  54. .ui.visible.transition {
  55. display: block;
  56. visibility: visible;
  57. }
  58. /* Direction */
  59. .ui.out.transition {
  60. -webkit-animation-direction: reverse;
  61. -moz-animation-direction: reverse;
  62. -o-animation-direction: reverse;
  63. animation-direction: reverse;
  64. }
  65. /* Disabled */
  66. .ui.disabled.transition {
  67. -webkit-animation-play-state: paused;
  68. -moz-animation-play-state: paused;
  69. -ms-animation-play-state: paused;
  70. -o-animation-play-state: paused;
  71. animation-play-state: paused;
  72. }
  73. /*******************************
  74. Variations
  75. *******************************/
  76. .ui.looping.transition {
  77. -webkit-animation-iteration-count: infinite;
  78. -moz-animation-iteration-count: infinite;
  79. -ms-animation-iteration-count: infinite;
  80. -o-animation-iteration-count: infinite;
  81. animation-iteration-count: infinite;
  82. }
  83. /*******************************
  84. Types
  85. *******************************/
  86. /*--------------
  87. Emphasis
  88. ---------------*/
  89. .ui.flash.transition {
  90. -webkit-animation-name: flash;
  91. -moz-animation-name: flash;
  92. -o-animation-name: flash;
  93. animation-name: flash;
  94. }
  95. .ui.shake.transition {
  96. -webkit-animation-name: shake;
  97. -moz-animation-name: shake;
  98. -o-animation-name: shake;
  99. animation-name: shake;
  100. }
  101. .ui.bounce.transition {
  102. -webkit-animation-name: bounce;
  103. -moz-animation-name: bounce;
  104. -o-animation-name: bounce;
  105. animation-name: bounce;
  106. }
  107. .ui.tada.transition {
  108. -webkit-animation-name: tada;
  109. -moz-animation-name: tada;
  110. -o-animation-name: tada;
  111. animation-name: tada;
  112. }
  113. /* originally authored by Nick Pettit - https://github.com/nickpettit/glide */
  114. .ui.pulse.transition {
  115. -webkit-animation-name: pulse;
  116. -moz-animation-name: pulse;
  117. -o-animation-name: pulse;
  118. animation-name: pulse;
  119. }
  120. /*--------------
  121. Flips
  122. ---------------*/
  123. .ui.flip.transition.in,
  124. .ui.flip.transition.out {
  125. -webkit-perspective: 2000px;
  126. perspective: 2000px;
  127. }
  128. .ui.horizontal.flip.transition.in,
  129. .ui.horizontal.flip.transition.out {
  130. -webkit-animation-name: horizontalFlip;
  131. -moz-animation-name: horizontalFlip;
  132. -o-animation-name: horizontalFlip;
  133. animation-name: horizontalFlip;
  134. }
  135. .ui.vertical.flip.transition.in,
  136. .ui.vertical.flip.transition.out {
  137. -webkit-animation-name: verticalFlip;
  138. -moz-animation-name: verticalFlip;
  139. -o-animation-name: verticalFlip;
  140. animation-name: verticalFlip;
  141. }
  142. /*--------------
  143. Fades
  144. ---------------*/
  145. .ui.fade.transition.in,
  146. .ui.fade.transition.out {
  147. -webkit-animation-name: fade;
  148. -moz-animation-name: fade;
  149. -o-animation-name: fade;
  150. animation-name: fade;
  151. }
  152. .ui.fade.up.transition.in {
  153. -webkit-animation-name: fadeUp;
  154. -moz-animation-name: fadeUp;
  155. -o-animation-name: fadeUp;
  156. animation-name: fadeUp;
  157. }
  158. .ui.fade.up.transition.out {
  159. -webkit-animation-name: fade;
  160. -moz-animation-name: fade;
  161. -o-animation-name: fade;
  162. animation-name: fade;
  163. }
  164. .ui.fade.down.transition.in {
  165. -webkit-animation-name: fadeDown;
  166. -moz-animation-name: fadeDown;
  167. -o-animation-name: fadeDown;
  168. animation-name: fadeDown;
  169. }
  170. .ui.fade.down.transition.out {
  171. -webkit-animation-name: fade;
  172. -moz-animation-name: fade;
  173. -o-animation-name: fade;
  174. animation-name: fade;
  175. }
  176. /*--------------
  177. Scale
  178. ---------------*/
  179. .ui.scale.transition.in,
  180. .ui.scale.transition.out {
  181. -webkit-animation-name: scale;
  182. -moz-animation-name: scale;
  183. -o-animation-name: scale;
  184. animation-name: scale;
  185. }
  186. /*--------------
  187. Slide
  188. ---------------*/
  189. .ui.slide.down.transition.in,
  190. .ui.slide.down.transition.out {
  191. -webkit-animation-name: slide;
  192. -moz-animation-name: slide;
  193. -o-animation-name: slide;
  194. animation-name: slide;
  195. transform-origin: 50% 0%;
  196. -ms-transform-origin: 50% 0%;
  197. -webkit-transform-origin: 50% 0%;
  198. }
  199. .ui.slide.up.transition.in,
  200. .ui.slide.up.transition.out {
  201. -webkit-animation-name: slide;
  202. -moz-animation-name: slide;
  203. -o-animation-name: slide;
  204. animation-name: slide;
  205. transform-origin: 50% 100%;
  206. -ms-transform-origin: 50% 100%;
  207. -webkit-transform-origin: 50% 100%;
  208. }
  209. @-moz-keyframes slide {
  210. 0% {
  211. opacity: 0;
  212. -moz-transform: scaleY(0);
  213. }
  214. 100% {
  215. opacity: 1;
  216. -moz-transform: scaleY(1);
  217. }
  218. }
  219. @-webkit-keyframes slide {
  220. 0% {
  221. opacity: 0;
  222. -webkit-transform: scaleY(0);
  223. }
  224. 100% {
  225. opacity: 1;
  226. -webkit-transform: scaleY(1);
  227. }
  228. }
  229. @keyframes slide {
  230. 0% {
  231. opacity: 0;
  232. transform: scaleY(0);
  233. }
  234. 100% {
  235. opacity: 1;
  236. transform: scaleY(1);
  237. }
  238. }
  239. /*******************************
  240. Animations
  241. *******************************/
  242. /*--------------
  243. Emphasis
  244. ---------------*/
  245. /* Flash */
  246. @-webkit-keyframes flash {
  247. 0%,
  248. 50%,
  249. 100% {
  250. opacity: 1;
  251. }
  252. 25%,
  253. 75% {
  254. opacity: 0;
  255. }
  256. }
  257. @-moz-keyframes flash {
  258. 0%,
  259. 50%,
  260. 100% {
  261. opacity: 1;
  262. }
  263. 25%,
  264. 75% {
  265. opacity: 0;
  266. }
  267. }
  268. @-o-keyframes flash {
  269. 0%,
  270. 50%,
  271. 100% {
  272. opacity: 1;
  273. }
  274. 25%,
  275. 75% {
  276. opacity: 0;
  277. }
  278. }
  279. @keyframes flash {
  280. 0%,
  281. 50%,
  282. 100% {
  283. opacity: 1;
  284. }
  285. 25%,
  286. 75% {
  287. opacity: 0;
  288. }
  289. }
  290. /* Shake */
  291. @-webkit-keyframes shake {
  292. 0%,
  293. 100% {
  294. -webkit-transform: translateX(0);
  295. }
  296. 10%,
  297. 30%,
  298. 50%,
  299. 70%,
  300. 90% {
  301. -webkit-transform: translateX(-10px);
  302. }
  303. 20%,
  304. 40%,
  305. 60%,
  306. 80% {
  307. -webkit-transform: translateX(10px);
  308. }
  309. }
  310. @-moz-keyframes shake {
  311. 0%,
  312. 100% {
  313. -moz-transform: translateX(0);
  314. }
  315. 10%,
  316. 30%,
  317. 50%,
  318. 70%,
  319. 90% {
  320. -moz-transform: translateX(-10px);
  321. }
  322. 20%,
  323. 40%,
  324. 60%,
  325. 80% {
  326. -moz-transform: translateX(10px);
  327. }
  328. }
  329. @-o-keyframes shake {
  330. 0%,
  331. 100% {
  332. -o-transform: translateX(0);
  333. }
  334. 10%,
  335. 30%,
  336. 50%,
  337. 70%,
  338. 90% {
  339. -o-transform: translateX(-10px);
  340. }
  341. 20%,
  342. 40%,
  343. 60%,
  344. 80% {
  345. -o-transform: translateX(10px);
  346. }
  347. }
  348. @keyframes shake {
  349. 0%,
  350. 100% {
  351. transform: translateX(0);
  352. }
  353. 10%,
  354. 30%,
  355. 50%,
  356. 70%,
  357. 90% {
  358. transform: translateX(-10px);
  359. }
  360. 20%,
  361. 40%,
  362. 60%,
  363. 80% {
  364. transform: translateX(10px);
  365. }
  366. }
  367. /* Bounce */
  368. @-webkit-keyframes bounce {
  369. 0%,
  370. 20%,
  371. 50%,
  372. 80%,
  373. 100% {
  374. -webkit-transform: translateY(0);
  375. }
  376. 40% {
  377. -webkit-transform: translateY(-30px);
  378. }
  379. 60% {
  380. -webkit-transform: translateY(-15px);
  381. }
  382. }
  383. @-moz-keyframes bounce {
  384. 0%,
  385. 20%,
  386. 50%,
  387. 80%,
  388. 100% {
  389. -moz-transform: translateY(0);
  390. }
  391. 40% {
  392. -moz-transform: translateY(-30px);
  393. }
  394. 60% {
  395. -moz-transform: translateY(-15px);
  396. }
  397. }
  398. @-o-keyframes bounce {
  399. 0%,
  400. 20%,
  401. 50%,
  402. 80%,
  403. 100% {
  404. -o-transform: translateY(0);
  405. }
  406. 40% {
  407. -o-transform: translateY(-30px);
  408. }
  409. 60% {
  410. -o-transform: translateY(-15px);
  411. }
  412. }
  413. @keyframes bounce {
  414. 0%,
  415. 20%,
  416. 50%,
  417. 80%,
  418. 100% {
  419. transform: translateY(0);
  420. }
  421. 40% {
  422. transform: translateY(-30px);
  423. }
  424. 60% {
  425. transform: translateY(-15px);
  426. }
  427. }
  428. /* Tada */
  429. @-webkit-keyframes tada {
  430. 0% {
  431. -webkit-transform: scale(1);
  432. }
  433. 10%,
  434. 20% {
  435. -webkit-transform: scale(0.9) rotate(-3deg);
  436. }
  437. 30%,
  438. 50%,
  439. 70%,
  440. 90% {
  441. -webkit-transform: scale(1.1) rotate(3deg);
  442. }
  443. 40%,
  444. 60%,
  445. 80% {
  446. -webkit-transform: scale(1.1) rotate(-3deg);
  447. }
  448. 100% {
  449. -webkit-transform: scale(1) rotate(0);
  450. }
  451. }
  452. @-moz-keyframes tada {
  453. 0% {
  454. -moz-transform: scale(1);
  455. }
  456. 10%,
  457. 20% {
  458. -moz-transform: scale(0.9) rotate(-3deg);
  459. }
  460. 30%,
  461. 50%,
  462. 70%,
  463. 90% {
  464. -moz-transform: scale(1.1) rotate(3deg);
  465. }
  466. 40%,
  467. 60%,
  468. 80% {
  469. -moz-transform: scale(1.1) rotate(-3deg);
  470. }
  471. 100% {
  472. -moz-transform: scale(1) rotate(0);
  473. }
  474. }
  475. @-o-keyframes tada {
  476. 0% {
  477. -o-transform: scale(1);
  478. }
  479. 10%,
  480. 20% {
  481. -o-transform: scale(0.9) rotate(-3deg);
  482. }
  483. 30%,
  484. 50%,
  485. 70%,
  486. 90% {
  487. -o-transform: scale(1.1) rotate(3deg);
  488. }
  489. 40%,
  490. 60%,
  491. 80% {
  492. -o-transform: scale(1.1) rotate(-3deg);
  493. }
  494. 100% {
  495. -o-transform: scale(1) rotate(0);
  496. }
  497. }
  498. @keyframes tada {
  499. 0% {
  500. transform: scale(1);
  501. }
  502. 10%,
  503. 20% {
  504. transform: scale(0.9) rotate(-3deg);
  505. }
  506. 30%,
  507. 50%,
  508. 70%,
  509. 90% {
  510. transform: scale(1.1) rotate(3deg);
  511. }
  512. 40%,
  513. 60%,
  514. 80% {
  515. transform: scale(1.1) rotate(-3deg);
  516. }
  517. 100% {
  518. transform: scale(1) rotate(0);
  519. }
  520. }
  521. @-webkit-keyframes pulse {
  522. 0% {
  523. -webkit-transform: scale(1);
  524. opacity: 1;
  525. }
  526. 50% {
  527. -webkit-transform: scale(0.9);
  528. opacity: 0.7;
  529. }
  530. 100% {
  531. -webkit-transform: scale(1);
  532. opacity: 1;
  533. }
  534. }
  535. @-o-keyframes pulse {
  536. 0% {
  537. -o-transform: scale(1);
  538. opacity: 1;
  539. }
  540. 50% {
  541. -o-transform: scale(0.9);
  542. opacity: 0.7;
  543. }
  544. 100% {
  545. -o-transform: scale(1);
  546. opacity: 1;
  547. }
  548. }
  549. @-moz-keyframes pulse {
  550. 0% {
  551. -moz-transform: scale(1);
  552. opacity: 1;
  553. }
  554. 50% {
  555. -moz-transform: scale(0.9);
  556. opacity: 0.7;
  557. }
  558. 100% {
  559. -moz-transform: scale(1);
  560. opacity: 1;
  561. }
  562. }
  563. @keyframes pulse {
  564. 0% {
  565. transform: scale(1);
  566. opacity: 1;
  567. }
  568. 50% {
  569. transform: scale(0.9);
  570. opacity: 0.7;
  571. }
  572. 100% {
  573. transform: scale(1);
  574. opacity: 1;
  575. }
  576. }
  577. /*--------------
  578. Flips
  579. ---------------*/
  580. /* Horizontal */
  581. @-webkit-keyframes horizontalFlip {
  582. 0% {
  583. -webkit-transform: rotateY(-90deg);
  584. opacity: 0;
  585. }
  586. 100% {
  587. -webkit-transform: rotateY(0deg);
  588. opacity: 1;
  589. }
  590. }
  591. @-moz-keyframes horizontalFlip {
  592. 0% {
  593. -moz-transform: rotateY(-90deg);
  594. opacity: 0;
  595. }
  596. 100% {
  597. -moz-transform: rotateY(0deg);
  598. opacity: 1;
  599. }
  600. }
  601. @-o-keyframes horizontalFlip {
  602. 0% {
  603. -o-transform: rotateY(-90deg);
  604. opacity: 0;
  605. }
  606. 100% {
  607. -o-transform: rotateY(0deg);
  608. opacity: 1;
  609. }
  610. }
  611. @keyframes horizontalFlip {
  612. 0% {
  613. transform: rotateY(-90deg);
  614. opacity: 0;
  615. }
  616. 100% {
  617. transform: rotateY(0deg);
  618. opacity: 1;
  619. }
  620. }
  621. /* Horizontal */
  622. @-webkit-keyframes horizontalFlipOut {
  623. 0% {
  624. -webkit-transform: rotateY(0deg);
  625. opacity: 0;
  626. }
  627. 100% {
  628. -webkit-transform: rotateY(90deg);
  629. opacity: 1;
  630. }
  631. }
  632. @-moz-keyframes horizontalFlipOut {
  633. 0% {
  634. -moz-transform: rotateY(0deg);
  635. opacity: 0;
  636. }
  637. 100% {
  638. -moz-transform: rotateY(90deg);
  639. opacity: 1;
  640. }
  641. }
  642. @-o-keyframes horizontalFlipOut {
  643. 0% {
  644. -o-transform: rotateY(0deg);
  645. opacity: 0;
  646. }
  647. 100% {
  648. -o-transform: rotateY(90deg);
  649. opacity: 1;
  650. }
  651. }
  652. @keyframes horizontalFlipOut {
  653. 0% {
  654. transform: rotateY(0deg);
  655. opacity: 0;
  656. }
  657. 100% {
  658. transform: rotateY(90deg);
  659. opacity: 1;
  660. }
  661. }
  662. /* Vertical */
  663. @-webkit-keyframes verticalFlip {
  664. 0% {
  665. -webkit-transform: rotateX(-90deg);
  666. opacity: 0;
  667. }
  668. 100% {
  669. -webkit-transform: rotateX(0deg);
  670. opacity: 1;
  671. }
  672. }
  673. @-moz-keyframes verticalFlip {
  674. 0% {
  675. -moz-transform: rotateX(-90deg);
  676. opacity: 0;
  677. }
  678. 100% {
  679. -moz-transform: rotateX(0deg);
  680. opacity: 1;
  681. }
  682. }
  683. @-o-keyframes verticalFlip {
  684. 0% {
  685. -o-transform: rotateX(-90deg);
  686. opacity: 0;
  687. }
  688. 100% {
  689. -o-transform: rotateX(0deg);
  690. opacity: 1;
  691. }
  692. }
  693. @keyframes verticalFlip {
  694. 0% {
  695. transform: rotateX(-90deg);
  696. opacity: 0;
  697. }
  698. 100% {
  699. transform: rotateX(0deg);
  700. opacity: 1;
  701. }
  702. }
  703. /*--------------
  704. Fades
  705. ---------------*/
  706. /* Fade */
  707. @-webkit-keyframes fade {
  708. 0% {
  709. opacity: 0;
  710. }
  711. 100% {
  712. opacity: 1;
  713. }
  714. }
  715. @-moz-keyframes fade {
  716. 0% {
  717. opacity: 0;
  718. }
  719. 100% {
  720. opacity: 1;
  721. }
  722. }
  723. @-o-keyframes fade {
  724. 0% {
  725. opacity: 0;
  726. }
  727. 100% {
  728. opacity: 1;
  729. }
  730. }
  731. @keyframes fade {
  732. 0% {
  733. opacity: 0;
  734. }
  735. 100% {
  736. opacity: 1;
  737. }
  738. }
  739. /* Fade Up */
  740. @-webkit-keyframes fadeUp {
  741. 0% {
  742. opacity: 0;
  743. -webkit-transform: translateY(20px);
  744. }
  745. 100% {
  746. opacity: 1;
  747. -webkit-transform: translateY(0);
  748. }
  749. }
  750. @-moz-keyframes fadeUp {
  751. 0% {
  752. opacity: 0;
  753. -moz-transform: translateY(20px);
  754. }
  755. 100% {
  756. opacity: 1;
  757. -moz-transform: translateY(0);
  758. }
  759. }
  760. @-o-keyframes fadeUp {
  761. 0% {
  762. opacity: 0;
  763. -o-transform: translateY(20px);
  764. }
  765. 100% {
  766. opacity: 1;
  767. -o-transform: translateY(0);
  768. }
  769. }
  770. @keyframes fadeUp {
  771. 0% {
  772. opacity: 0;
  773. transform: translateY(20px);
  774. }
  775. 100% {
  776. opacity: 1;
  777. transform: translateY(0);
  778. }
  779. }
  780. /* Fade Down */
  781. @-webkit-keyframes fadeDown {
  782. 0% {
  783. opacity: 0;
  784. -webkit-transform: translateY(-20px);
  785. }
  786. 100% {
  787. opacity: 1;
  788. -webkit-transform: translateY(0);
  789. }
  790. }
  791. @-moz-keyframes fadeDown {
  792. 0% {
  793. opacity: 0;
  794. -moz-transform: translateY(-20px);
  795. }
  796. 100% {
  797. opacity: 1;
  798. -moz-transform: translateY(0);
  799. }
  800. }
  801. @-o-keyframes fadeDown {
  802. 0% {
  803. opacity: 0;
  804. -o-transform: translateY(-20px);
  805. }
  806. 100% {
  807. opacity: 1;
  808. -o-transform: translateY(0);
  809. }
  810. }
  811. @keyframes fadeDown {
  812. 0% {
  813. opacity: 0;
  814. transform: translateY(-20px);
  815. }
  816. 100% {
  817. opacity: 1;
  818. transform: translateY(0);
  819. }
  820. }
  821. /*--------------
  822. Scale
  823. ---------------*/
  824. /* Scale */
  825. @-webkit-keyframes scale {
  826. 0% {
  827. opacity: 0;
  828. -webkit-transform: scale(0.7);
  829. }
  830. 100% {
  831. opacity: 1;
  832. -webkit-transform: scale(1);
  833. }
  834. }
  835. @-moz-keyframes scale {
  836. 0% {
  837. opacity: 0;
  838. -moz-transform: scale(0.7);
  839. }
  840. 100% {
  841. opacity: 1;
  842. -moz-transform: scale(1);
  843. }
  844. }
  845. @-o-keyframes scale {
  846. 0% {
  847. opacity: 0;
  848. -o-transform: scale(0.7);
  849. }
  850. 100% {
  851. opacity: 1;
  852. -o-transform: scale(1);
  853. }
  854. }
  855. @keyframes scale {
  856. 0% {
  857. opacity: 0;
  858. transform: scale(0.7);
  859. }
  860. 100% {
  861. opacity: 1;
  862. transform: scale(1);
  863. }
  864. }