Skip to content

Commit

Permalink
flatpickr 24h setting is decided on the client
Browse files Browse the repository at this point in the history
  • Loading branch information
ornicar committed Oct 6, 2024
1 parent 44e31c7 commit 3dd7f5b
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions modules/ui/src/main/helper/Form3.scala
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,6 @@ final class Form3(formHelper: FormHelper & I18nHelper, flairApi: FlairApi):
)(st.legend(toggle.map(_ => tabindex := 0))(legend))

private val dataEnableTime = attr("data-enable-time")
private val dataTime24h = attr("data-time_24h")
private val dataMinDate = attr("data-mindate")

def flatpickr(
Expand All @@ -236,7 +235,6 @@ final class Form3(formHelper: FormHelper & I18nHelper, flairApi: FlairApi):
): Tag =
input(field, klass = s"flatpickr${if utc then " flatpickr-utc" else ""}")(
dataEnableTime := withTime,
dataTime24h := withTime,
dateFormat.map(df => data("date-format") := df),
dataMinDate := minDate.map:
case "today" if utc => "yesterday"
Expand Down

0 comments on commit 3dd7f5b

Please sign in to comment.