mdehoog / Semantic-UI-Calendar

Calendar module for Semantic UI
MIT License
804 stars 126 forks source link

Passing existing time value ignores minutes and only displays hours #129

Open cliveportman opened 6 years ago

cliveportman commented 6 years ago

The following works fine apart from the initial displayed value within the time field being 10:00 when it should be 10:25. Turning on AM/PM makes no difference. Is this a known issue or something only I'm experiencing?

<div class="ui calendar time">
  <div class="ui input left icon">
    <i class="calendar icon"></i>
    <input type="text" class="calendar-text" value="10:25" placeholder="Select time">
  </div>
</div>
<input type="hidden" name="fieldname" class="calendar-time" value="10:25">

$('.ui.calendar.time').calendar({
   type: 'time',
   ampm: false
 });
lubber-de commented 4 years ago

The Calendar component was merged into https://github.com/fomantic/Fomantic-UI and is further maintained there. Using Fomantic-UI and your code, i cannot reproduce your issue anymore. 10:25 is displayed on initialization just fine See https://jsfiddle.net/lubber/neqgy3x6/1/