nathank
(Nathan Kershaw)
18 בפברואר, 2025, 12:50am
1
When I use the dates functionality within a poll, the dates/times do not seem to be rendering correctly in the post. Interestingly they seem fine in the preview:
2 לייקים
sam
(Sam Saffron)
18 בפברואר, 2025, 5:08am
2
Going to put a pr-welcome on this for now and let @lindsey know …
Just double checking the issue:
2025-02-17T13:00:00Z
2025-02-18T13:00:00Z
Note there is also a rendering issue after you vote that needs fixing (box with dates moves to an odd place.
My guess here is that chains decorating cooked struggle here with the poll rendering.
3 לייקים
anishlukk123
(Anish Lukkireddy)
19 בפברואר, 2025, 3:58am
3
רק רוצה לוודא, שהתוצאה הצפויה היא שהתצוגה מקדימה היא נכונה, זה נכון
sam
(Sam Saffron)
19 בפברואר, 2025, 4:51am
4
כן עלינו להיות תואמים עם התצוגה המקדימה כאן.
[sondage de type=“multiple” résultats=“toujours” public=“true” nom=“sondage2” chartType=“bar” max=“2” min=“1”]
* 2019-10-13T00:00:00Z * 2019-10-12T00:00:00Z * 2019-10-11T00:00:00Z
* 2019-10-13T00:00:00Z * * 2019-10-11T00:00:00Z
[/sondage]
היי, רק עדכון קצר. היה לי הרבה זמן לעבור על זה, אבל הצלחתי לשחזר את הבעיה בסביבתי המקומית על ידי יצירת סקר. בחנתי את הלוגיקה של discourse-local-dates ו-local dates builder, והייתה לי שאלה על מה זה site_settings שמוזכר בקוד. אני לא רוצה לנחש שזה ההעדפה של אזור הזמן בדף ההגדרות. לאור זה, הייתי בטוח שזה רק עובד על ידי הוספת תאריך. לכן, הבעיה הזו מוגבלת רק לסקרים. התיאוריה הנוכחית שלי היא שהבעיה היא באיך שמנהלים את אזורי הזמן.
2 לייקים
nathank
(Nathan Kershaw)
26 ביוני, 2025, 6:12am
12
I note that a fix to a similar problem within Polls has just been made:
Any chance of a wave of the dark magic for this too?
2 לייקים
Moin
18 בדצמבר, 2025, 5:42pm
13
Dates in polls were fixed today
main ← fix-support-local-dates-in-poll-options
merged 12:30PM - 18 Dec 25 UTC
This change enables local dates to render properly in poll options and improves … how dates are displayed in the rich editor.
What changed:
- Rich editor now displays localized, human-friendly dates (e.g., "Today at 2:30 PM") instead of raw date strings ("2021-01-01 12:00:00") by using LocalDateBuilder
- Poll options can now include local dates that are properly decorated and interactive
- Added keyboard shortcut (Cmd/Ctrl+Shift+.) to insert current date markup in poll option inputs
- Extracted reusable utilities: formatLocalDate for rendering and generateCurrentDateMarkup for BBCode generation
How it works:
- New NULL_HELPER export in decorated-html provides a null-safe helper object for contexts without a post/model, allowing HTML decorators to work in poll options
- New Ember modifiers (decorate-cooked-content, decorate-poll-option) apply decorators to poll content
- Tests updated to verify data attributes rather than text content, since formatted dates vary by timezone
Internal ref - t/155024
**BEFORE/AFTER (markdown editor)**
<img width="1699" height="1327" alt="CleanShot 2025-12-16 at 11 59 22" src="https://github.com/user-attachments/assets/ff9fbb2b-0f1b-41b7-b0fc-b59c73ed4e32" />
<img width="1699" height="1327" alt="CleanShot 2025-12-16 at 11 59 42" src="https://github.com/user-attachments/assets/6b07beab-e864-4319-b97b-fe7abe2180e6" />
**BEFORE/AFTER (rich text editor)**
<img width="1699" height="1327" alt="CleanShot 2025-12-16 at 12 00 05" src="https://github.com/user-attachments/assets/0f0e1a4b-0829-4e0e-94ac-90f16c4e52d5" />
<img width="1699" height="1327" alt="CleanShot 2025-12-16 at 11 59 52" src="https://github.com/user-attachments/assets/d8db2e7a-c110-41bd-9fbf-b4af0f5de2c5" />
When do you typically receive your Christmas gifts?
December 5, 2025
December 7, 2025
December 23, 2025
December 24, 2025
December 25, 2025
January 5, 2026
other
5 לייקים
mcwumbly
(Dave McClure)
נסגר ב־
22 בדצמבר, 2025, 1:00pm
14
This topic was automatically closed after 3 days. New replies are no longer allowed.