mirror of
https://github.com/DavidHDev/vue-bits.git
synced 2026-03-07 14:39:30 -07:00
feat: Stack component
This commit is contained in:
26
src/constants/code/Components/stackCode.ts
Normal file
26
src/constants/code/Components/stackCode.ts
Normal file
@@ -0,0 +1,26 @@
|
||||
import code from '@content/Components/Stack/Stack.vue?raw';
|
||||
import type { CodeObject } from '../../../types/code';
|
||||
|
||||
export const stack: CodeObject = {
|
||||
cli: `npx jsrepo add https://vue-bits.dev/ui/Components/Stack`,
|
||||
usage: `<template>
|
||||
<Stack
|
||||
:randomRotation="true"
|
||||
:sensitivity="180"
|
||||
:sendToBackOnClick="false"
|
||||
:cardDimensions="{ width: 200, height: 200 }"
|
||||
:cardsData="images"
|
||||
></Stack>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import Stack from './Stack.vue'
|
||||
const images = [
|
||||
{ id: 1, img: "https://images.unsplash.com/photo-1480074568708-e7b720bb3f09?q=80&w=500&auto=format" },
|
||||
{ id: 2, img: "https://images.unsplash.com/photo-1449844908441-8829872d2607?q=80&w=500&auto=format" },
|
||||
{ id: 3, img: "https://images.unsplash.com/photo-1452626212852-811d58933cae?q=80&w=500&auto=format" },
|
||||
{ id: 4, img: "https://images.unsplash.com/photo-1572120360610-d971b9d7767c?q=80&w=500&auto=format" }
|
||||
];
|
||||
</script>`,
|
||||
code
|
||||
};
|
||||
Reference in New Issue
Block a user