A simple analog clock component for Vue 3.
This package provides a Vue 3 component to display an analog clock. It's lightweight, customizable, and easy to integrate into your Vue 3 projects.
npm install vue3-analog-clock
or go to npm package link
import { createApp } from "vue";
import App from "./App.vue";
import AnalogClock from "vue3-analog-clock";
import "vue3-analog-clock/dist/style.css";
const app = createApp(App);
app.use(AnalogClock);
app.mount("#app");
<template>
<div>
<AnalogClock />
</div>
</template>
Default Analog Clock
Customize Analog Clock
You can customize the appearance of the analog clock component using the following props:
watchFaceBackground
: Background color of the clock face. Default:#f9f9f9
.watchDigitsColor
: Color of the clock digits. Default:#000000
.watchDigitsMinuteMarksColor
: Color of the minute marks on the clock face. Default:#929394
.watchHoursHand
: Color of the hour hand. Default:#232425
.watchMinutesHand
: Color of the minute hand. Default:#343536
.watchSecondsHand
: Color of the seconds hand. Default:#c00
.
To customize the clock colors, simply pass the desired color values as props when using the component in your Vue templates:
<template>
<div>
<AnalogClock
watchFaceBackground="#673F69"
watchDigitsColor="#FFFFFF"
watchDigitsMinuteMarksColor="#FFFFFF"
watchHoursHand="#FFAF45"
watchMinutesHand="#FB6D48"
watchSecondsHand="#E72929"
/>
</div>
</template>
Vue, Vue 3, Analog Clock, Clock Component, Vue Component
This package is licensed under the MIT License