Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

datetime widget time picker does not accept any valid input #7212

Open
HastingsEngineering opened this issue May 23, 2024 · 1 comment
Open
Labels
area: extensions/widgets/datetime type: bug code to address defects in shipped code

Comments

@HastingsEngineering
Copy link

Describe the bug
The datetime widget in time picker mode does not accept any valid input

To Reproduce

  1. Create a datetime widget with time_format=true
  2. Try to type in a time

The hours field should fill in, then upon entering the next digit, the whole widget clears

Expected behavior
You should be able to enter a time

Screenshots
Example trying to enter the time 05:30

Input: "05"
image

Input: "053"
image

Applicable Versions:
decap-cms-app 3.1.10
decap-cms-core 3.3.6
decap-cms 3.1.10

  • Git Provider: Gitlab
  • OS: Win10
  • Firefox

CMS configuration

backend:
  name: git-gateway
  branch: main

site_url: redacted

publish_mode: editorial_workflow

# Media
media_folder: static/assets/uploads
public_folder: /assets/uploads

# File Routes
collections:     
  - label: Events
    label_singular: Event
    name: events
    folder: src/lib/site/pages/events
    path: "{{slug}}"
    slug: "{{slug}}"
    preview_path: "events/{{slug}}"
    create: true
    editor:
      preview: false
    fields:
      - label: Layout
        name: layout
        widget: hidden
        default: blocks
      - label: Title
        name: title
        widget: string
        hint: Sets the page title in browsers and search engines
      - label: Description
        name: description
        widget: text
        hint: Gives the page a description in SEO for search engines
      - label: Start Date
        name: startDate
        widget: datetime
        date_format: YYYY-MM-DD
        picker_utc: true
      - label: End Date
        name: endDate
        widget: datetime
        date_format: YYYY-MM-DD
        required: false
        picker_utc: true
        default: ""
      - label: Start Time
        name: startTime
        widget: datetime
        time_format: true
        required: false
        picker_utc: true
        default: ""
      - label: End Time
        name: endTime
        widget: datetime
        time_format: true
        required: false
        picker_utc: true
        default: ""
      - label: All Day?
        name: allDay
        widget: boolean
        hint: If set, events will not display a time.
        default: false
      - label: Tags
        name: tags
        widget: list
@HastingsEngineering HastingsEngineering added the type: bug code to address defects in shipped code label May 23, 2024
@fernan2jr
Copy link

Same here... cdn 3.1.10
- { label: 'Datetime', name: 'datetime', widget: 'datetime' } This works correctly.
- { label: 'Datetime', name: 'datetime', widget: 'datetime', format: 'LT', time_format: 'hh:mm A'} This does not.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: extensions/widgets/datetime type: bug code to address defects in shipped code
Projects
None yet
Development

No branches or pull requests

3 participants