Skip to content

Commit

Permalink
Add repeat option to countdown, plus translations
Browse files Browse the repository at this point in the history
  • Loading branch information
bluecaret committed Nov 25, 2023
1 parent bc92a7b commit c10cdb4
Show file tree
Hide file tree
Showing 19 changed files with 689 additions and 101 deletions.
22 changes: 11 additions & 11 deletions src/assets/lists.js
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,17 @@ export const widgetTypes = [
desc: 'Your portal to the web, with the freedom to choose your preferred search engine for more tailored results.',
tags: ['Free', 'Utility', 'Web', 'Productivity'],
},
{
id: 'cd',
type: 'countdown',
store: 'countdowns',
name: 'Countdown',
icon: 'fa-hourglass-start',
limit: 1,
max: 9999,
desc: 'Count down the seconds to your upcoming events, helping you manage your time and never miss a moment.',
tags: ['Premium Access', 'Time and Date', 'Utility'],
},
{
id: 'ls',
type: 'loadshedding',
Expand All @@ -141,17 +152,6 @@ export const widgetTypes = [
desc: 'Stay ahead of power outages with this informative widget, helping South African residents manage their schedules better.',
tags: ['Free', 'Information'],
},
{
id: 'cd',
type: 'countdown',
store: 'countdowns',
name: 'Countdown',
icon: 'fa-hourglass-start',
limit: 0,
max: 9999,
desc: 'Count down the seconds to your upcoming events, helping you manage your time and never miss a moment.',
tags: ['Premium Access', 'Time and Date', 'Utility'],
},
{
id: 'if',
type: 'iframe',
Expand Down
14 changes: 10 additions & 4 deletions src/components/widgets/Countdown.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,21 @@ import { baseWidgetStyles } from '@/classes/BaseWidgetStyles.js'

export class Countdown {
id = ''
target = '2050-01-01T00:00'
timezone = 'local'
target = '2024-01-01T00:00'
equalWidth = false
monospace = true
spaceBetween = 1
direction = 'horizontal'
repeat = {
on: true,
nth: 1,
recurrence: 'year',
weeklyOn: [1],
monthlyOn: 'day',
}
label = {
label: 'Countdown',
on: false,
label: 'New Years Day',
on: true,
position: 'top',
override: false,
color: [0, 0, 100, 1],
Expand Down
Loading

0 comments on commit c10cdb4

Please sign in to comment.