This commit is contained in:
@@ -5,7 +5,9 @@ export const ClockModule: DashboardModule = {
|
||||
name: 'clock',
|
||||
width: 2,
|
||||
height: 1,
|
||||
render() {
|
||||
render(params) {
|
||||
const label = params.label || 'Local Time';
|
||||
|
||||
return h(defineComponent({
|
||||
setup() {
|
||||
const time = ref(new Date().toLocaleTimeString());
|
||||
@@ -25,7 +27,7 @@ export const ClockModule: DashboardModule = {
|
||||
'div',
|
||||
{ class: 'w-full h-full flex flex-col items-center justify-center p-5 rounded-2xl bg-white/10 backdrop-blur-md border border-white/10 shadow-lg text-white group cursor-default transition-all' },
|
||||
[
|
||||
h('span', { class: 'text-sm text-white/50 mb-1 uppercase tracking-widest' }, 'Local Time'),
|
||||
h('span', { class: 'text-sm text-white/50 mb-1 uppercase tracking-widest' }, label),
|
||||
h('span', { class: 'text-3xl font-light tracking-tight text-shadow' }, time.value)
|
||||
]
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user