0
0
Fork 0
mirror of https://github.com/discourse/discourse.git synced 2026-08-06 05:42:36 +08:00
discourse/plugins/discourse-calendar/lib
Kris 2f9f4e8401
FEATURE: render links to event topics as interactive cards (#40953)
When a link to an event topic is oneboxed from another post, it will now
render the event's interactive card instead of a generic quote, which
would sometimes be empty if the only content of the topic was the event.
This covers replies, the composer markdown preview, and the composer
rich text editor. When a card can't render it falls back to the standard
onebox quote.

This mirrors core's `localized_oneboxes` pattern for the event data, and
uses a cooked decorator to swap the quote for `<DiscoursePostEvent>`. In
the rich text editor a ProseMirror NodeView renders the read-only card.

Before:
<img width="828" height="298" alt="image"
src="https://github.com/user-attachments/assets/41df1ece-ca38-4747-8c5a-3dda0b06998a"
/>

After:
<img width="757" height="540" alt="image"
src="https://github.com/user-attachments/assets/6312242d-f7c1-43e3-b641-0d471680c107"
/>

A pared down read-only card is rendered in the composer for preview.

<img width="600" alt="image"
src="https://github.com/user-attachments/assets/c06cd020-6acb-4a45-87be-4621ff2bf308"
/>


<img width="800" alt="image"
src="https://github.com/user-attachments/assets/8250458b-0082-4be8-980a-bfb69a5191d3"
/>
2026-07-17 10:36:54 -04:00
..
discourse_calendar FEATURE: Embedded Zoom webinar for livestream events (#40973) 2026-07-16 10:58:56 +10:00
discourse_post_event FEATURE: render links to event topics as interactive cards (#40953) 2026-07-17 10:36:54 -04:00
tasks DEV: Fix javascript:update_constants task (#35994) 2025-11-12 20:01:29 +01:00
calendar.rb
calendar_custom_fields_validator.rb FIX: Support uppercase and separators in event custom field names (#40995) 2026-06-24 17:02:32 +02:00
calendar_first_day_of_week.rb FEATURE: allow picking first day of week in calendar (#34670) 2025-09-02 12:44:50 +02:00
calendar_settings_validator.rb
calendar_upcoming_events_default_view.rb FEATURE: adds calendar_upcoming_events_default_view setting (#36014) 2025-11-13 19:19:13 +08:00
calendar_validator.rb
event_validator.rb FIX: Whisper messages should not create calendar events (#40282) 2026-06-01 12:04:51 -03:00
group_timezones.rb
holiday_status.rb DEV: Update rubocop-discourse to 3.13 and autofix issues (#35073) 2025-10-06 16:11:01 +02:00
time_sniffer.rb DEV: Enable Style/RedundantSelf rubocop rule (#40098) 2026-05-19 19:27:45 +02:00
users_on_holiday.rb