Skip to content

Commit

Permalink
feat: allow boolean stagger prop values, document usage
Browse files Browse the repository at this point in the history
  • Loading branch information
mattrothenberg committed Nov 9, 2019
1 parent 413d604 commit bfc60cf
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/Flipped.vue
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ export default {
props: {
flipId: String,
inverseFlipId: String,
stagger: String,
stagger: [String, Boolean],
shouldFlip: Function,
shouldInvert: Function,
scale: {
Expand Down
3 changes: 2 additions & 1 deletion stories/List.vue
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
@click="shuffle"
>shuffle</button>
<ul class="list mt-4">
<Flipped v-for="num in list" :key="num" :flipId="num.toString()">
<Flipped v-for="num in list" :key="num" :flipId="num.toString()" :stagger="stagger">
<li>{{num}}</li>
</Flipped>
</ul>
Expand All @@ -28,6 +28,7 @@ import Flipped from "../src/Flipped";
export default {
name: "list",
props: ["stagger"],
components: {
Flipper,
Flipped
Expand Down
8 changes: 8 additions & 0 deletions stories/index.stories.js
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,14 @@ storiesOf("Examples", module)
template: `<List></List>`
};
})
.add("List Shuffle (Stagger)", () => {
return {
components: {
List
},
template: `<List :stagger="true"></List>`
};
})
.add("Scale", () => {
return {
components: {
Expand Down

0 comments on commit bfc60cf

Please sign in to comment.