Commit Graph

223 Commits

Author SHA1 Message Date
Mike Dalessio 851f13a934 Render inline code in card titles (#2518)
* Remove unused marked JS dependency

* Remove unused redcarpet dependency

* Render inline code in card titles

Add card_html_title helper that HTML-escapes input then converts
backtick-wrapped text to <code> elements. Apply to card titles in
board preview, card detail, public views, and notification emails.
Style inline code elements in titles to match description styling.

Co-authored-by: Andy Smith <andy@37signals.com>

---------

Co-authored-by: Andy Smith <andy@37signals.com>
2026-02-12 12:07:40 -05:00
Andy Smith 4e5a5e1523 Use built-in lexxy styles and sprinkle in some overrides 2026-02-12 09:54:20 +01:00
Andy Smith 8cfcc6fca5 Align board name start so it doesn't get too big 2026-01-26 12:57:26 -06:00
Andy Smith 5beb413c41 Clean up card/events header layout 2026-01-26 12:53:01 -06:00
Mike Dalessio cb61b36715 Allow boosts on cards (#2411)
* Add reactions association to Card model

Adds `has_many :reactions` to Card, matching the implementation in Comment.
This allows cards to be reacted to directly with emoji reactions.

The association:
- Orders reactions chronologically
- Uses polymorphic `:reactable` interface
- Deletes reactions when card is destroyed

Includes test coverage for the new association.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* Add reactions UI to card detail view

- Create Cards::ReactionsController with turbo stream responses
- Add card reactions views (reactions list, new form, menu partial)
- Position reaction button flush-right when no reactions exist
- Show reactions on bottom-left when present, with button inline
- Handle narrow viewports by flowing button below meta section
- Add controller tests for card reactions

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* Add boost count to card preview

Display reaction count alongside comment count on card tiles in board
columns. Introduces a .card__counts wrapper to group both counts with
proper positioning on all viewport sizes.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* Consolidate reaction views for cards and comments

Extract shared views to app/views/reactions/ using polymorphic routing.
Both card and comment reactions now render the same partials, with a
helper to compute the correct path prefix for nested routes.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* Fix emoji picker width in card reactions

Override .card .popup { inline-size: 260px } for the reaction popup
so the emoji grid displays without horizontal scrollbar.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* Hide boost count where comment count is hidden

Add .card__boosts alongside .card__comments in:
- Tray view (display: none)
- Cards with background images (opacity toggle on hover)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* Fix reactions button overlap with zoom button in card footer

When a card has a background image, the footer contains both a reactions
button and a zoom button. Previously they would overlap because the
reactions button was absolutely positioned to the bottom-right.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* Tighten up previews

* Move card reactions from meta partial to container

Fixes two issues:

1. Reactions were duplicated each time a card was assigned because the
   turbo stream replaced the meta div with the full perma/meta partial,
   which included reactions outside the replaced element.

2. Draft cards incorrectly showed the boost button because the meta
   partial was shared between published and draft containers.

Moving reactions to _container.html.erb (published cards only) fixes
both issues and keeps the meta partial focused on meta content.

Fixes https://app.fizzy.do/5986089/cards/3837
Fixes https://app.fizzy.do/5986089/cards/3835

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* WIP adjust perma page

* Position and style the footer

* Render the stamp in the card body instead of the footer

* Fix undefined local variable in public cards view

Changed `card` to `@card` when rendering the stamp partial.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* Preload card reactions to avoid N+1 queries

Include reactions and their reacters in the preloaded scope, matching
what we already do for comments.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* Add model tests for card and comment reaction cleanup

Test that:
- Creating a card reaction touches the card's last_active_at
- Reactions are deleted when their parent comment is destroyed
- Reactions are deleted when their parent card is destroyed

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* Minor improvements to reactions code

- Use size instead of count in boosts partial to avoid extra SQL query
  on already-loaded collection
- Add else clause to reaction_path_prefix_for to raise ArgumentError
  for unknown reactable types instead of silently returning nil

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

* Bump specificity of reaction popup in the card perma

---------

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
Co-authored-by: Andy Smith <andy@37signals.com>
2026-01-23 13:25:55 -05:00
Andy Smith 036768fede Create popup initial alignment classes 2026-01-16 14:30:47 -06:00
Andy Smith df8f88f773 Fix class typo 2026-01-16 14:12:19 -06:00
Andy Smith 19ce79965b Align board and tag picker dialogs without using math 2026-01-16 14:00:04 -06:00
Jorge Manrubia 0278fe6ae4 Revert "Mobile app / Scoped stylesheets" (#1698)
This reverts commit 39c1906e67.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-16 17:20:18 +01:00
Adrien Maston 041ac0c28e Add conditional stylesheets for mobile apps 2025-11-24 11:52:56 +01:00
Jason Zimdars 7650bf9c33 Display stamp in cards view when it's auto-postponed by the system 2025-11-13 18:12:24 -06:00
Jason Zimdars 3625585a9d Adjust unread indicator to include unread count 2025-11-12 11:15:25 -06:00
Jason Zimdars df858fcdd0 Rework to ensure button adopts card color
Removes unecessary field class, visually downplays edit button
2025-11-11 15:55:23 -06:00
Andy Smith 490fac3067 Update maximize column icon and add focus ring for assignees 2025-11-11 13:57:45 -06:00
Andy Smith 8cc4f2ee8e Clicking assignee opens popup 2025-11-10 11:36:31 -06:00
Andy Smith f291de4dce Add syntax highlighting to public description 2025-11-06 13:16:23 -06:00
Jorge Manrubia 03a345609e Baseline replacing collection with board across code 2025-11-05 13:31:54 +01:00
Jason Zimdars 45614a07ea Tighten space between title and description editors 2025-10-22 17:27:07 -07:00
Jason Zimdars a2bba83963 Only display the stamp on the card perma 2025-10-16 19:25:23 -05:00
Jason Zimdars 940db09063 Refactor to remove workflows styles 2025-10-13 18:06:14 -05:00
Andy Smith 24eaf9ff1f Make lists in public description less weird 2025-10-08 16:52:22 -05:00
Jason Zimdars 55e4fec01f Don't display bubbles for closed or not now cards 2025-10-02 20:37:34 -05:00
Jason Zimdars 02d96473bb Actually, it needs to be like this for closed cards which don't get a specific class 2025-10-02 20:36:21 -05:00
Jason Zimdars 299ce6252f Not now cards should be grey, too 2025-10-02 20:18:37 -05:00
Jason Zimdars 8d03785cd8 Restore themed card text colors 2025-10-01 11:19:31 -05:00
Jason Zimdars 3a81c05eae Avoid scrolling in card title input, cut-off descenders
Added a note because this keeps getting changed. A value of 1.1 looks
best but has problems with our automatic field sizing and in geneneral
with Windows. Windows since forever, has simply cropped descenders when
the line-height is lower than it prefers. It's dumb but real.
2025-09-30 16:33:49 -05:00
Andy Smith 09c1f446a5 Use default text color for notifications 2025-09-26 12:07:18 -05:00
Andy Smith 906aa0d691 Fix notification text color 2025-09-25 15:40:20 -05:00
Andy Smith 56635867f3 Repair card perma text styles 2025-09-24 16:01:21 -05:00
Andy Smith 113063ada3 Add wavy BG to Stream workflow stage 2025-09-24 12:03:58 -05:00
Andy Smith 399791bddb Card design tweaks 2025-09-24 11:24:23 -05:00
Andy Smith cab6992555 Merge branch 'main' into collapsible-nav-sections
* main: (32 commits)
  Fix VCR fixtures
  Format
  Touch user on modification to invalidate cache
  Fix add card not working in the cards screen
  Submit and refresh results as you type terms
  Fix: When expanding filters, submitting filters should keep the filters expanded
  Invalidate cache when filter changes
  Switch to gpt-5-chat
  Reorded method and remove unnecessary param
  Add migration to convert accesses
  Handle filter toggles with JS
  Prevent glitch where you see the filter bar expanded when you clear it
  Remove unused templates
  Fix: all collections link not working after moving to turbo frame
  Restore cache I deleted by mistake
  Speed up filter expansion with turbo stream
  Fix: filtering collections not working after moving menu to turbo frame
  Respect params when loading the menu or they won't be reflected!
  Add HTTP cache for the menu
  Load main menu lazily with a turbo frame
  ...
2025-09-12 12:53:44 -05:00
Andy Smith a2fd470c63 Refactor popup item class names 2025-09-12 11:27:47 -05:00
Jorge Manrubia 1554c6b29f Inline :has(&) as it's REALLY slow in Safari
This makes Safari sluggish in general. A particular scenario where it chokes is when
rendering lots of local times with JS (such as in the cards screen when there are many cards).
2025-09-12 11:01:56 +02:00
Jason Zimdars a532d2d89b Adjust to there is no editing jog 2025-09-10 15:57:40 -05:00
Jason Zimdars b1c98a3eca Attempt to fix Windows line-height issue
https://fizzy.37signals.com/5986089/cards/1467
2025-09-10 15:53:00 -05:00
Jason Zimdars 0e0de36ca2 Use icons in footer meta, dump the labels in previews 2025-09-09 20:27:53 -05:00
Jason Zimdars 9d087b80e9 Needs to override mark's inherent coloring 2025-09-09 09:16:30 -05:00
Jason Zimdars e948c2ec46 Tighten card title gap 2025-09-08 17:06:48 -05:00
Jason Zimdars 888c6a0846 Highlight @mentions in notifications 2025-09-08 14:03:16 -05:00
Jorge Manrubia 5b5c698af7 Rename Action Text Lexical => Lexxy
 Conflicts:
	app/assets/stylesheets/terminals.css
2025-08-26 08:25:19 +02:00
Jason Zimdars 2384ce5d94 Simplify search results 2025-08-22 07:33:26 +02:00
Andy Smith 865c4e4915 Just hide the avatars 2025-08-20 10:03:45 -05:00
Andy Smith 1d0939b847 Use grid areas so it's easier to tell what's going on 2025-08-19 17:03:42 -05:00
Andy Smith 167434d238 Refactor meta display 2025-08-19 16:52:27 -05:00
Andy Smith 4e22780bb3 Use desktop layout, but hide avatars 2025-08-19 14:53:06 -05:00
Andy Smith 20e27541be Truncate tags on cards 2025-08-14 13:55:20 -05:00
Andy Smith efa0a56207 Show notification X on card hover 2025-08-13 13:40:08 -05:00
Andy Smith 267a5f11fa Stack meta info on mobile 2025-08-11 15:54:59 -05:00
Andy Smith 6c1a0bb5de Make changes specific to card perma 2025-08-11 11:49:31 -05:00