responsive

data-moveDirection

  • Available since: v1.2
  • Type: attribute
  • Data type: String
  • Allowed values: top, right, bottom or left
  • Default value: no default value

Specifies direction of movement of animated element.

Note: Opposite css property has to have value auto, e.g. data-moveDirection="top" than css property bottom has to be auto (top, right, bottom and left have default value auto so you don't have to specifically set it via css). See example below:

<!--You can set bottom: auto; in attribute style but it's not necessary. You cannot set bottom: 10; or similar value.-->
<h1 class="caption" data-initEvent="onSlideStartOpening" data-moveDirection="top" data-offset="15%" style="top: 30%;left: 25%;">
	This is just a caption.
</h1>

Dependencies

The described attribute can be used only if the below listed attributes were set.

  • data-initEvent
  • data-offset
  • animated element has to be absolutely or relatively positioned

Demo 1

Demo 1 demonstrates usage of all 4 allowed values of described attribute.

Loading content...

All four directions

t

l

c

r

b

slide1

All four directions

t

l

c

r

b

slide2

All four directions

t

l

c

r

b

slide4

All four directions

t

l

c

r

b

slide5

jAccordion by maniacpc, exclusively for CodeCanyon