Giter Site home page Giter Site logo

Comments (6)

ka215 avatar ka215 commented on September 27, 2024

I have a way to do that. I will show you how to do it as a demonstration in the near future. Please wait.

from jquery.timeline.

ka215 avatar ka215 commented on September 27, 2024

Hi there,

I have been released the demo page below.

CRUD System for jQuery.Timeline

Please try to see so.

from jquery.timeline.

robibuckley avatar robibuckley commented on September 27, 2024

Hi - that example seems to be broken. Did you ever come up with a solution for this? i.e. click on an empty area of the timeline to add a new event

from jquery.timeline.

ka215 avatar ka215 commented on September 27, 2024

No, that example is working fine.
Firstly select "Create Event" from the Change Mode pull-down in the upper left corner, then "double-click" anywhere you want on the timeline. A dialog will open for adding a new event.

from jquery.timeline.

robibuckley avatar robibuckley commented on September 27, 2024

Aaah yes - all sorted now. Although I think I have spotted a bug. If you set the timezone to another timezone (such as Asia/Makassar) the present time marker doesn't update? Because the _nowDt var within the _viewPresentTime() method is being set as new Date() with no timeZone passed in. Does it not need a toLocaleString adding to set the timeZone?

from jquery.timeline.

ka215 avatar ka215 commented on September 27, 2024

JavaScript's Date object handles local time depending on the host machine's time zone, unless you explicitly use a UTC-related method. In other words, the date and time normally retrieved from a Date object instantiated with new Date() will be in local time.
jQuery.Timeline does not have time zone information in the instantiated component itself. Therefore, the vertical line indicator for the current point in time in the timeline container will show the current time in local time, which depends on the time zone of the host machine.
I made some changes to the time zone of the host machine to check the display.

  • UTC+08:00 : Singapore Standard Time
tzutil /s "Singapore Standard Time"

UTC+08:00

The time zone offset for Asia/Makassar is UTC+8:00, which is the same as Singapore. Therefore, on a Windows PC, you can change the time zone to Singapore Standard Time to see if it works.
Later, I changed to the time zone Tokyo or Samoa and displayed the same timeline, and the indicator at the current time was displayed normally according to each time zone.

  • UTC+09:00 : Tokyo Standard time
tzutil /s "Tokyo Standard Time"

UTC+09:00

  • UTC+13:00 : Samoa Standerd Time
tzutil /s "Samoa Standerd Time"

UTC+13:00

As per the plugin specifications, it works without any problems.

Thank you,

from jquery.timeline.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.