feat: add clickable activity cards with comment anchor links to profile tab

Add `url` field to profile activity items so post cards link to `/posts/{slug}` and comment cards link to the parent post with a `#comment-{uid}` anchor, matching notification click behavior. Include the shared `_card_link.html` overlay in the template, fix XP bar rendering for missing `xp` key, and add API + e2e tests verifying the link structure and navigation.
This commit is contained in:
2026-07-04 20:24:59 +00:00
parent c79dfd0291
commit 7002b23eeb
11 changed files with 213 additions and 13 deletions
+2 -2
View File
@@ -72,8 +72,8 @@ def test_prestige_multiplier():
def test_fertilize_cost_has_floor():
assert economy.fertilize_cost(1) == economy.FERTILIZE_MIN_COST
assert economy.fertilize_cost(10000) > economy.FERTILIZE_MIN_COST
assert economy.fertilize_click_cost(1, 1, 1_000_000) == 1
assert economy.fertilize_click_cost(10_000, 50, 100) > 1
def test_crop_payload_locked_flag():
+2
View File
@@ -32,6 +32,8 @@ def _reset(username, coins=100000):
get_table("game_plots").delete(farm_uid=farm["uid"])
get_table("game_quests").delete(farm_uid=farm["uid"])
get_table("game_farms").delete(uid=farm["uid"])
get_table("game_steals").delete(thief_uid=user["uid"])
get_table("game_steals").delete(owner_uid=user["uid"])
farm = store.ensure_farm(user["uid"])
get_table("game_farms").update({"uid": farm["uid"], "coins": coins}, ["uid"])
return user