Skip to content

Class Animation: Document alternative object hash based signature. Fixes... #129

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions entries/addClass.xml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,12 @@
<xi:include href="../includes/animation-argument-easing.xml" xmlns:xi="http://www.w3.org/2003/XInclude"/>
<xi:include href="../includes/animation-argument-complete.xml" xmlns:xi="http://www.w3.org/2003/XInclude"/>
</signature>
<signature>
<argument name="className" type="String">
<desc>One or more class names (space separated) to be added to the class attribute of each matched element.</desc>
</argument>
<xi:include href="../includes/class-animation-argument-options.xml" xmlns:xi="http://www.w3.org/2003/XInclude"/>
</signature>
<example>
<desc>Adds the class "big-blue" to the matched elements.</desc>
<css><![CDATA[
Expand Down
6 changes: 6 additions & 0 deletions entries/removeClass.xml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,12 @@
<xi:include href="../includes/animation-argument-easing.xml" xmlns:xi="http://www.w3.org/2003/XInclude"/>
<xi:include href="../includes/animation-argument-complete.xml" xmlns:xi="http://www.w3.org/2003/XInclude"/>
</signature>
<signature>
<argument name="className" type="String">
<desc>One or more class names (space separated) to be removed from the class attribute of each matched element.</desc>
</argument>
<xi:include href="../includes/class-animation-argument-options.xml" xmlns:xi="http://www.w3.org/2003/XInclude"/>
</signature>
<example>
<desc>Removes the class "big-blue" from the matched elements.</desc>
<css><![CDATA[
Expand Down
9 changes: 9 additions & 0 deletions entries/switchClass.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,15 @@
<xi:include href="../includes/animation-argument-easing.xml" xmlns:xi="http://www.w3.org/2003/XInclude"/>
<xi:include href="../includes/animation-argument-complete.xml" xmlns:xi="http://www.w3.org/2003/XInclude"/>
</signature>
<signature>
<argument name="removeClassName" type="String">
<desc>One or more class names (space separated) to be removed from the class attribute of each matched element.</desc>
</argument>
<argument name="addClassName" type="String">
<desc>One or more class names (space separated) to be added to the class attribute of each matched element.</desc>
</argument>
<xi:include href="../includes/class-animation-argument-options.xml" xmlns:xi="http://www.w3.org/2003/XInclude"/>
</signature>
<example>
<height>220</height>
<desc>Adds the class "blue" and removes the class "big" from the matched elements.</desc>
Expand Down
9 changes: 9 additions & 0 deletions entries/toggleClass.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,15 @@
<xi:include href="../includes/animation-argument-easing.xml" xmlns:xi="http://www.w3.org/2003/XInclude"/>
<xi:include href="../includes/animation-argument-complete.xml" xmlns:xi="http://www.w3.org/2003/XInclude"/>
</signature>
<signature>
<argument name="className" type="String">
<desc>One or more class names (space separated) to be toggled for each element in the matched set.</desc>
</argument>
<argument name="switch" type="Boolean" optional="true">
<desc>A boolean value to determine whether the class should be added or removed.</desc>
</argument>
<xi:include href="../includes/class-animation-argument-options.xml" xmlns:xi="http://www.w3.org/2003/XInclude"/>
</signature>
<example>
<height>220</height>
<desc>Toggles the class "big-blue" for the matched elements.</desc>
Expand Down
22 changes: 22 additions & 0 deletions includes/class-animation-argument-options.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
<?xml version="1.0"?>
<argument name="options" type="Object" optional="true">
<desc>All animation settings. All properties are optional.</desc>
<property name="duration" default="400" optional="true">
<desc>A string or number determining how long the animation will run.</desc>
<type name="Number">
<desc>The duration in milliseconds.</desc>
</type>
<type name="String">
<desc>The strings <code>"fast"</code> and <code>"slow"</code> can be supplied to indicate durations of 200 and 600 milliseconds, respectively.</desc>
</type>
</property>
<property name="easing" type="String" default="swing" optional="true">
<desc>A string indicating which <a href="/easings/">easing</a> function to use for the transition.</desc>
</property>
<property name="complete" type="Function" optional="true">
<desc>A function to call once the animation is complete.</desc>
</property>
<property name="children" type="Boolean" default="false">
<desc>Whether the animation should additionally be applied to all children of the matched elements.</desc>
</property>
</argument>