getkirby / kirby

Kirby's core application folder
https://getkirby.com
Other
1.31k stars 168 forks source link

[Kirby, Panel] Number field won’t save four digits #1499

Closed robinscholz closed 5 years ago

robinscholz commented 5 years ago

Describe the bug The number field won‘t save more than three digits. Two and three are fine, but trying to save anything more than three digits results in only the first digit being saved.

To reproduce Steps to reproduce the behavior:

  1. Download the starterkit
  2. Add a number field too the files/image.yml blueprint
    title: Image
    columns:
    - width: 1/2
    sections:
      content:
        type: fields
        fields:
          caption:
            label: Caption
            type: textarea
            size: medium
          year:
            type: number
            label: Jahr
            width: 1/2
    - width: 1/2
    sections:
      meta:
        type: fields
        fields:
          alt:
            label: Alternative Text
            type: text
          photographer:
            label: Photogapher
            type: text
            width: 2/3
          license:
            label: License
            type: select
            width: 1/3
            options:
              - Unsplash
              - CC BY 4.0
              - CC BY-SA 4.0
              - CC BY-NC 4.0
              - CC BY-ND 4.0
          link:
            label: Link
            type: url
  3. Find a file and try entering a year (i.e. 2017)
  4. See error

Expected behavior Save all digits of the input.

Kirby Version 3.0.2.

Desktop (please complete the following information):

bastianallgeier commented 5 years ago