diff --git a/preview/pages/widgets.astro b/preview/pages/widgets.astro index 729e85b84..bff87df84 100644 --- a/preview/pages/widgets.astro +++ b/preview/pages/widgets.astro @@ -99,12 +99,12 @@ import Configuration from '@shared/components/cards/Configuration.astro'
-
-
-
-
-
-
+
+
+
+
+
+
diff --git a/shared/components/cards/ProjectKanban.astro b/shared/components/cards/ProjectKanban.astro index c19da1945..b3b8103c0 100644 --- a/shared/components/cards/ProjectKanban.astro +++ b/shared/components/cards/ProjectKanban.astro @@ -1,5 +1,4 @@ --- -// NOTE: widgets page passes `value=` but only `percentage` (default 20) drives the bar — `value` is accepted but ignored. import Progress from '@ui/Progress.astro' import AvatarList from '@ui/AvatarList.astro' import Icon from '@ui/Icon.astro' @@ -13,15 +12,14 @@ interface Props { percentage?: number | string percentageColor?: string due?: string - /** unused — see note above */ value?: number | string } -const { title = 'Task Title', badge, offset = 40, limit = 7, percentage = 20, percentageColor = 'green', due = '2 days' } = Astro.props +const { title = 'Task Title', badge, offset = 40, limit = 7, percentage, percentageColor = 'green', due = '2 days', value = 20 } = Astro.props ---
- +
{title} diff --git a/shared/components/cards/ProjectProgress.astro b/shared/components/cards/ProjectProgress.astro index 7acb10ff3..021aa0c23 100644 --- a/shared/components/cards/ProjectProgress.astro +++ b/shared/components/cards/ProjectProgress.astro @@ -1,5 +1,4 @@ --- -// NOTE: `days-ago` param accepted but unused ("Updated 2 hours ago" is hardcoded). import Progress from '@ui/Progress.astro' import CardDropdown from '@ui/CardDropdown.astro' import projects from '@data/projects.json' @@ -16,7 +15,7 @@ interface Props { daysAgo?: number } -const { projectId = 0, progress = 25 } = Astro.props +const { projectId = 0, progress = 25, daysAgo = 2 } = Astro.props const project = (projects as Project[])[projectId] --- @@ -30,7 +29,7 @@ const project = (projects as Project[])[projectId]

{project.title}

-
Updated 2 hours ago
+
Updated {daysAgo} days ago
diff --git a/shared/components/cards/UserCardBg.astro b/shared/components/cards/UserCardBg.astro index 0a9a197cb..bec5b7f4d 100644 --- a/shared/components/cards/UserCardBg.astro +++ b/shared/components/cards/UserCardBg.astro @@ -1,7 +1,5 @@ --- // person = people[person-id]; the cover photo is photos[person-id].file. -// Base card-cover already carries `card-cover-blurred`; `blurred` adds it a 2nd time -// Base card-cover already carries `card-cover-blurred`; `blurred` adds it a second time. import Avatar from '@ui/Avatar.astro' import people from '@data/people.json' import photos from '@data/photos.json' @@ -29,7 +27,7 @@ const photo = (photos as Photo[])[personId] --- -
+
diff --git a/shared/ui/Pagination.astro b/shared/ui/Pagination.astro index a72980633..0aeab977f 100644 --- a/shared/ui/Pagination.astro +++ b/shared/ui/Pagination.astro @@ -36,7 +36,7 @@ if (offset < count) { firstLast && (
  • - {!text ? : 'Previous'} + {!text ? : 'First'}
  • ) @@ -82,7 +82,7 @@ if (offset < count) { ) } -
  • +
  • { nextDescription ? ( @@ -102,7 +102,7 @@ if (offset < count) { firstLast && (
  • - {!text ? : 'Next'} + {!text ? : 'Last'}
  • ) diff --git a/shared/ui/Select.astro b/shared/ui/Select.astro index 3597abc64..5aa4f041e 100644 --- a/shared/ui/Select.astro +++ b/shared/ui/Select.astro @@ -140,7 +140,7 @@ const selectId = id ? `select-${id}` : undefined; (window.tabler_select[selectId] = new TomSelect(document.getElementById(selectId), { copyClassesToDropdown: false, dropdownParent: 'body', - ...(showSearch ? {} : { controlInput: '' }), + ...(showSearch === false ? { controlInput: null } : {}), render: { item: renderOption, option: renderOption, diff --git a/shared/ui/Tag.astro b/shared/ui/Tag.astro index 3fea8ab5f..31f05eb1c 100644 --- a/shared/ui/Tag.astro +++ b/shared/ui/Tag.astro @@ -49,7 +49,7 @@ const { text, flag, icon, person, personId, payment, status, legend, checkbox, c ) : null } {text} - {badge && } + {badge != null && }