1395 Commits

Author SHA1 Message Date
soxa
8baf725a37
fix safari videos regression, overflow clipping images (#1938) 2025-03-03 14:53:02 -06:00
ekzyis
dfe0c4ad23
Fix footnotes and overflow (#1940)
* Fix missing uncollapse on footnote click

* Add comments to variables
2025-03-03 14:31:10 -06:00
Scroogey-SN
b1cdc76eec
fix #1167: allow pointer events in linkBoxParent pre for scrollbar (#1930)
Co-authored-by: Keyan <34140557+huumn@users.noreply.github.com>
2025-03-03 12:47:54 -06:00
soxa
f72af08882
fix: WebLN QR fallback for anon users (#1858)
* fix: WebLN QR fallback for anon users

* wip: clear zap color on payment fail

* reverse clearItemMeAnonSats

* webln-specific retry bypass

* cleanup

* send WebLN payment when user is Anon AND on QR

* skip wallet checking on anon

* Use WalletError for all errors in webln.sendPayment

---------

Co-authored-by: ekzyis <ek@stacker.news>
Co-authored-by: Keyan <34140557+huumn@users.noreply.github.com>
2025-03-01 16:56:18 -06:00
Edward Kung
73170ba8a2
Territory analytics (#1926)
* add territory to analytics selectors

* implement territory analytics, revert user satistics header

* fix linting errors

* disallow some territory names

* fix linting error

* minor adjustments to header

* escape input

* 404 on non-existant sub

* exclude unused queries depending on sub select

---------

Co-authored-by: Keyan <34140557+huumn@users.noreply.github.com>
Co-authored-by: k00b <k00b@stacker.news>
2025-02-28 19:15:18 -06:00
soxa
31532ff830
Dynamic loading optimizations (#1925)
* dynamic: React QR Scanner, React Datepicker; placeholder for syntax highlighting

* Loading placeholders, prevent layout shifting
2025-02-24 15:06:40 -06:00
soxa
bc3c008a6d
Dynamically import MathJax (#1910)
* Dynamically import MathJax

* Only load if there's math content; cleanup

* avoid loading RSH on Math, we have MathJax for that; cleanup

* support multiline mathjax

---------

Co-authored-by: k00b <k00b@stacker.news>
2025-02-21 15:41:27 -06:00
soxa
868847cb43
Dynamically import React Syntax Highlighter; correct theme (#1909) 2025-02-15 16:33:44 -06:00
ekzyis
0032e064b2
Automated retries (#1776)
* Poll failed invoices with visibility timeout

* Don't return intermediate failed invoices

* Don't retry too old invoices

* Retry invoices on client

* Only attempt payment 3 times

* Fix fallbacks during last retry

* Rename retry column to paymentAttempt

* Fix no index used

* Resolve TODOs

* Use expiring locks

* Better comments for constants

* Acquire lock during retry

* Use expiring lock in retry mutation

* Use now() instead of CURRENT_TIMESTAMP

* Cosmetic changes

* Immediately show failed post payments in notifications

* Update hasNewNotes

* Never retry on user cancel

For a consistent UX and less mental overhead, I decided to remove the exception for ITEM_CREATE where it would still retry in the background even though we want to show the payment failure immediately in notifications.

* Fix notifications without pending retries missing if no send wallets

If a stacker has no send wallets, they would miss notifications about failed payments because they would never get retried.

This commit fixes this by making the notifications query aware if the stacker has send wallets. This way, it can tell if a notification will be retried or not.

* Stop hiding userCancel in notifications

As mentioned in a previous commit, I want to show anything that will not be attempted anymore in notifications.

Before, I wanted to hide manually cancelled invoices but to not change experience unnecessarily and to decrease mental overhead, I changed my mind.

* Also consider invoice.cancelledAt in notifications

* Always retry failed payments, even without send wallets

* Fix notification indicator on retry timeout

* Set invoice.updated_at to date slightly in the future

* Use default job priority

* Stop retrying after one hour

* Remove special case for ITEM_CREATE

* Replace retryTimeout job with notification indicator query

* Fix sortTime

---------

Co-authored-by: Keyan <34140557+huumn@users.noreply.github.com>
2025-02-14 19:25:11 -06:00
ekzyis
87b5bb80fd
Fix missing cleanup of dark mode listeners (#1906) 2025-02-14 11:37:24 -06:00
ekzyis
3cdf5c9451
Fix comment not outlined again (#1902) 2025-02-13 11:46:35 -06:00
soxa
1afadbdf3b
enhance: referral notifications with source (#1862)
* wip: referral notification shows source of referral

* simpler approach for source info gathering

* fix territory representation; fix fragment field

* cleanup; fix UI

* better margin approach

* hotfix: null check

* add support for comments

* use Union to represent ReferralSource; clarify with switch statements

* cleanup: compact switch statement on Referral resolver

* wip use refereeLanding

* add comments; cleanup

* hotfix: backwards compatibility for Earnings calculation

* small copy and semantics changes

---------

Co-authored-by: Keyan <34140557+huumn@users.noreply.github.com>
Co-authored-by: k00b <k00b@stacker.news>
2025-02-11 20:02:04 -06:00
k00b
5af61f415f monospace font for edit countdowns 2025-02-10 19:19:22 -06:00
soxa
c01f4865dc
apply flex rules after images are loaded (#1886) 2025-02-08 13:14:42 -06:00
soxa
5c2aa979ea
feat: comment fee control (#1768)
* feat: comment fee control

* update typeDefs for unarchiving territories

* review: move functions to top level; consider saloon items

* ux: cleaner post/reply cost section

* hotfix: handle salon replies

* bios don't have subs + simplify root query

* move reply cost to accordian

---------

Co-authored-by: Keyan <34140557+huumn@users.noreply.github.com>
Co-authored-by: k00b <k00b@stacker.news>
2025-02-07 13:38:57 -06:00
k00b
ee8fe6e72a add boost badge fix #1860 2025-02-03 19:56:29 -06:00
jason-me
2dfde257d2
Update price button accessibility in header (#1857)
* Update price button accessibility

* Updated accName and accDescription for speech dictation and screen reader users.

* Update price.js

Replace double quote with single

* Update price.js

Remove trailing spaces

* make .visually-hidden global, use className rather than class

* make accessible button component

---------

Co-authored-by: Jason Hester <jhester@TPGLPT-LTC23.attlocal.net>
Co-authored-by: Keyan <34140557+huumn@users.noreply.github.com>
Co-authored-by: k00b <k00b@stacker.news>
2025-02-03 19:22:02 -06:00
soxa
be7c702602
Login with magic code (#1818)
* fix: cannot login with email on PWA

* adjust other email templates

* restore manual url on new user email

* no padding on button section

* cleanup

* generate 6-digit bechh32 token

* token needs to be fed as lower case; validator case insensitive

* delete token if user has failed 3 times

* proposal: context-independent error page

* include expiration time on email page message

* add expiration time to emails

* independent checkPWA function

* restore token deletion if successful auth

* final cleanup: remove unused function

* compact useVerificationToken

* email.js: magic code for non-PWA users

* adjust email templates

* MultiInput component; magic code via MultiInput

* hotfix: revert length testing; larger width for inputs

* manual bech32 token generation; no upperCase

* reverting to string concatenation

* layout tweaks, fix error placement

* pastable inputs

* small nit fixes

* less ambiguous error path

---------

Co-authored-by: Keyan <34140557+huumn@users.noreply.github.com>
Co-authored-by: k00b <k00b@stacker.news>
2025-02-03 18:41:01 -06:00
k00b
efdcbef733 fixes related to comment paging 2025-01-30 19:19:49 -06:00
k00b
33beb1dc52 fix history race on flat comment click 2025-01-30 17:08:16 -06:00
k00b
bb916b8669 fix comments in notifications 2025-01-30 10:54:51 -06:00
Keyan
01b021a337
comment pagination with limit/offset (#1824)
* basic query with limit/offset

* roughly working increment

* working limiting/pageable queries

* denormalize direct comments + full comments below threshold

* notifications in megathread + working nest view more buttons

* fix empty comment footer

* make comments nested resolver again

* use time in cursor to avoid duplicates

* squash migrations

* do not need item.comments undefined checks
2025-01-29 19:00:05 -06:00
soxa
bd84b8bf88
fix: Images on iOS are cropped weird (#1840)
* force sync decoding on images

* use decode() to load the image

* add comment
2025-01-28 15:30:54 -06:00
k00b
b28407ee99 remove changes from footer 2025-01-23 16:54:50 -06:00
soxa
78533bda1b
fix: downzappable pinned posts (#1841)
Co-authored-by: Keyan <34140557+huumn@users.noreply.github.com>
2025-01-22 19:15:03 -06:00
ekzyis
ca7726fda5
Fix recent sort order for retried items (#1829)
* Fix recent sort order for retried items

* Also fix for comments

* don't hide createdAt, order item query inner subquery

---------

Co-authored-by: Keyan <34140557+huumn@users.noreply.github.com>
Co-authored-by: k00b <k00b@stacker.news>
2025-01-22 17:42:18 -06:00
ekzyis
ac7bd5df7e Fix typo in CC info 2025-01-20 15:02:03 +01:00
k00b
d9932e0a27 add max fee bullet to cc modal 2025-01-14 14:43:43 -06:00
k00b
8905868a62 fix typo in CC modal 2025-01-13 15:06:03 -06:00
k00b
c40ef5a1c1 fix daily rewards link in reward sats modal 2025-01-12 15:47:21 -06:00
Keyan
4520c91179
cowboy credit modal explainers wherever they are referenced (#1815) 2025-01-12 15:15:53 -06:00
Riccardo Balbo
511b0eea40
fix tooltip blinking at the edges (#1813) 2025-01-07 08:18:35 -06:00
ekzyis
b37a12bf71
Use sats / ccs format in item details (#1805)
* Use sats / ccs format in item details

* Use row-gap and line-height
2025-01-06 17:22:56 -06:00
Riccardo Balbo
0750a7b197
add hasSendWallet to bounty pay (#1806) 2025-01-05 11:26:18 -06:00
Riccardo Balbo
95950cdff8
pass hasSendWallet to ItemAct actor (#1804) 2025-01-05 11:25:49 -06:00
soxa
a04647d304
fix: iOS check, proper AMOUNT count on iOS (#1796) 2025-01-04 19:18:15 -06:00
ekzyis
34175babb2
Fix scroll after modal close (#1798) 2025-01-04 15:32:45 -06:00
Keyan
146b60278c
cowboy credits (aka nov-5 (aka jan-3)) (#1678)
* wip adding cowboy credits

* invite gift paid action

* remove balance limit

* remove p2p zap withdrawal notifications

* credits typedefs

* squash migrations

* remove wallet limit stuff

* CCs in item detail

* comments with meCredits

* begin including CCs in item stats/notifications

* buy credits ui/mutation

* fix old /settings/wallets paths

* bios don't get sats

* fix settings

* make invites work with credits

* restore migration from master

* inform backend of send wallets on zap

* satistics header

* default receive options to true and squash migrations

* fix paidAction query

* add nav for credits

* fix forever stacked count

* ek suggested fixes

* fix lint

* fix freebies wrt CCs

* add back disable freebies

* trigger cowboy hat job on CC depletion

* fix meMsats+meMcredits

* Update api/paidAction/README.md

Co-authored-by: ekzyis <ek@stacker.news>

* remove expireBoost migration that doesn't work

---------

Co-authored-by: ekzyis <ek@stacker.news>
2025-01-03 10:33:07 -06:00
ekzyis
d53bc09773
Distinguish invoices cancelled by user (#1785) 2025-01-02 11:53:05 -06:00
ekzyis
6a02ea8c5c
Allow cancel of own invoices without hmac (#1787) 2025-01-02 10:35:54 -06:00
soxa
0ca9596310
enhance: collapse childless deleted comments (#1786) 2025-01-01 13:07:32 -06:00
ekzyis
ba2ac2c94e
Fix ignored cancel error (#1784) 2025-01-01 11:18:54 -06:00
ekzyis
a41d077c21
Fix muted parents not uncollapsed (#1775)
* Fix parents not uncollapsed of router.query.commentId

* Fix code comment

* Use descriptive fragment name

* Add cache to effect dependencies

not sure if needed since also works without but probably safer to have than not
2024-12-31 10:24:59 -06:00
k00b
211e3c136b fix lint 2024-12-28 11:16:59 -06:00
CypherCosmo
43129f7045
fit missing signup button spacing
Co-authored-by: Keyan <34140557+huumn@users.noreply.github.com>
2024-12-28 10:47:57 -06:00
Keyan
eb22fdab41
make possibly conflicting optimistic cache updates write to each other (#1772)
* make possibly conflicting optimistic cache updates write to each other

* always update optimistic caches with cache.modifying items
2024-12-27 14:52:32 -06:00
Keyan
18445b1dc1
fix 1695 by not updating ancestors on zap (#1766)
* fix 1695 by not updating ancestors on zap

* update ancestors but only onPaid
2024-12-27 10:19:49 -06:00
ekzyis
4ad54d6f5a
Fix typo in deposit notification (#1765) 2024-12-26 13:10:02 -06:00
k00b
1b1045fcd9 increase pull refresh distance 2024-12-23 19:50:51 -06:00
Keyan
2fc529419e
reduce territory price with prorated refund for actives (#1761) 2024-12-23 18:50:35 -06:00