mirror of
https://github.com/DavidHDev/vue-bits.git
synced 2026-03-07 22:49:31 -07:00
refactor: update PreviewColor props to be optional and adjust layout in demos
This commit is contained in:
@@ -7,7 +7,7 @@
|
|||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
defineProps<{
|
defineProps<{
|
||||||
title: string;
|
title?: string;
|
||||||
modelValue: string;
|
modelValue: string;
|
||||||
disabled?: boolean;
|
disabled?: boolean;
|
||||||
}>();
|
}>();
|
||||||
@@ -27,7 +27,6 @@ const handleColorChange = (event: Event) => {
|
|||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 0.5rem;
|
gap: 0.5rem;
|
||||||
margin-bottom: 1.5rem;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.color-label {
|
.color-label {
|
||||||
|
|||||||
@@ -31,7 +31,7 @@
|
|||||||
split-type="words"
|
split-type="words"
|
||||||
:delay="10"
|
:delay="10"
|
||||||
:duration="1"
|
:duration="1"
|
||||||
text="Eighty-plus snippets, ready to be dropped into your Vue projects"
|
text="Sixty-plus snippets, ready to be dropped into your Vue projects"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<router-link to="/text-animations/split-text" class="landing-button">
|
<router-link to="/text-animations/split-text" class="landing-button">
|
||||||
|
|||||||
@@ -14,10 +14,7 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<Customize>
|
<Customize>
|
||||||
<div class="space-y-2">
|
<div class="flex gap-2">
|
||||||
<h3 class="text-lg font-semibold text-gray-900 dark:text-gray-100">Color Stops</h3>
|
|
||||||
|
|
||||||
<div class="flex gap-4">
|
|
||||||
<PreviewColor
|
<PreviewColor
|
||||||
v-for="(color, index) in colorStops"
|
v-for="(color, index) in colorStops"
|
||||||
:key="index"
|
:key="index"
|
||||||
@@ -26,7 +23,6 @@
|
|||||||
@update:model-value="value => updateColorStop(index, value)"
|
@update:model-value="value => updateColorStop(index, value)"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
|
||||||
|
|
||||||
<PreviewSlider
|
<PreviewSlider
|
||||||
title="Amplitude"
|
title="Amplitude"
|
||||||
|
|||||||
@@ -14,7 +14,7 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<Customize>
|
<Customize>
|
||||||
<div class="flex gap-4">
|
<div class="flex gap-2">
|
||||||
<PreviewColor
|
<PreviewColor
|
||||||
v-for="(color, index) in colorStops"
|
v-for="(color, index) in colorStops"
|
||||||
:key="index"
|
:key="index"
|
||||||
@@ -24,7 +24,7 @@
|
|||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<PreviewSlider title="Pixelation" v-model="pixelation" :min="0" :max="2000" :step="10" />
|
<PreviewSlider title="Pixelation" v-model="pixelation" :min="100" :max="2000" :step="10" />
|
||||||
|
|
||||||
<PreviewSwitch title="Enable Mouse Interaction" v-model="mouseInteractionEnabled" />
|
<PreviewSwitch title="Enable Mouse Interaction" v-model="mouseInteractionEnabled" />
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user