fiatjaf / njump

mirror of https://git.njump.me/njump
MIT License
108 stars 24 forks source link

kind 31923 calendar events displaying UTC time instead the specified timezone #56

Closed vnprc closed 5 months ago

vnprc commented 6 months ago

https://njump.me/naddr1qqyrje3svf3nyetpqy8hwumn8ghj7mn0wd68ytnddaksygpc4vlncpsr9tek2dvk0jttc38dwjjxa4mz2k0fk3dzw5z2qa3frqpsgqqq0jestl36s9

This event is scheduled for 5/23 @ 6pm New York Time. The date field displays 5/24, likely because it is using UTC time instead of the timezone specified in the event.

Screenshot 2024-05-10 at 9 32 44 AM

{
  "id": "65d21a04df2cb1858c9bf629a42f8b449f9726b837245fa41689912f7189d4cc",
  "pubkey": "38ab3f3c06032af36535967c96bc44ed74a46ed762559e9b45a27504a0762918",
  "created_at": 1715344250,
  "kind": 31923,
  "tags": [
    [
      "d",
      "9f0bc2ea"
    ],
    [
      "title",
      "Bitcoin and Freedom Technologies - Freedom Tech Workshop"
    ],
    [
      "description",
      "Bitcoin is a critical technology in terms of freeing our money from the undue influence of the cantillionaires. But bitcoin alone cannot free all captured networks. This workshop will explore other freedom technologies taking shape around bitcoin and other protocols. This will be an open discussion of technologies intended to promote human freedom.\n\nTopics will include, but are not limited to:\nhttps://nostr.com/\nhttps://dsnp.org/\nhttp://impervious.ai/\nhttps://www.ethswarm.org/\nhttps://www.selfid.com/\nhttps://www.zion.fyi/\nhttps://gig-gossip.org/\n\n\nPizza will be provided. Thank you to our sponsor Lolli!\n\nhttps://www.lolli.com/"
    ],
    [
      "start",
      "1716501600"
    ],
    [
      "end",
      "1716508800"
    ],
    [
      "start_tzid",
      "America/New_York"
    ],
    [
      "p",
      "38ab3f3c06032af36535967c96bc44ed74a46ed762559e9b45a27504a0762918",
      "",
      "host"
    ],
    [
      "location",
      "The Loading Dock — Dock 1053, 1053 E Whitaker Mill Rd Suite 115, Raleigh, NC 27604, USA",
      "The Loading Dock — Dock 1053",
      "1053 E Whitaker Mill Rd Suite 115, Raleigh, NC 27604, USA"
    ],
    [
      "address",
      "The Loading Dock — Dock 1053, 1053 E Whitaker Mill Rd Suite 115, Raleigh, NC 27604, USA",
      "The Loading Dock — Dock 1053",
      "1053 E Whitaker Mill Rd Suite 115, Raleigh, NC 27604, USA"
    ],
    [
      "g",
      "dq25dyvd"
    ],
    [
      "name",
      "Bitcoin and Freedom Technologies - Freedom Tech Workshop"
    ],
    [
      "about",
      "Bitcoin is a critical technology in terms of freeing our money from the undue influence of the cantillionaires. But bitcoin alone cannot free all captured networks. This workshop will explore other freedom technologies taking shape around bitcoin and other protocols. This will be an open discussion of technologies intended to promote human freedom.\n\nTopics will include, but are not limited to:\nhttps://nostr.com/\nhttps://dsnp.org/\nhttp://impervious.ai/\nhttps://www.ethswarm.org/\nhttps://www.selfid.com/\nhttps://www.zion.fyi/\nhttps://gig-gossip.org/\n\n\nPizza will be provided. Thank you to our sponsor Lolli!\n\nhttps://www.lolli.com/"
    ],
    [
      "image",
      "https://flockstr.s3.amazonaws.com/event/IFXNyNsrOMPNMYFasBrVV"
    ]
  ],
  "content": "Bitcoin is a critical technology in terms of freeing our money from the undue influence of the cantillionaires. But bitcoin alone cannot free all captured networks. This workshop will explore other freedom technologies taking shape around bitcoin and other protocols. This will be an open discussion of technologies intended to promote human freedom.\n\nTopics will include, but are not limited to:\nhttps://nostr.com/\nhttps://dsnp.org/\nhttp://impervious.ai/\nhttps://www.ethswarm.org/\nhttps://www.selfid.com/\nhttps://www.zion.fyi/\nhttps://gig-gossip.org/\n\n\nPizza will be provided. Thank you to our sponsor Lolli!\n\nhttps://www.lolli.com/",
  "sig": "0b9c524c57ba1bca5b714e4eb0cc032ba2696d4f1199c327df4f911dadb511a58818bc70dce5281a69e63a4b3a3269f942d842c8b0f13e68654b52d65e7d9a63"
}
vnprc commented 6 months ago

Also, it would be cool to display the date and time instead of just date.

dtonon commented 6 months ago

Thanks for reporting, I will check it

cxplay commented 6 months ago

https://github.com/fiatjaf/njump/issues/32

dtonon commented 6 months ago

Fixed the date visualization, was a bug related to the 00:00 start time. But the date is still plain UTC, because CalendarEvent in go-nostr doesn't support start_tzid/end_tzid. I will work on that.

image
dtonon commented 5 months ago

Fixed.

image