Deep-link CL8Y DEX trade CTAs once dex.cl8y.com honors Swap query params #6
Labels
No labels
agent:implement
agent:ready
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
ready
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
code/CL8Y-web#6
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Gate (do not implement until this is true)
Blocked on cl8y-dex-terraclassic !488 (Closes DEX #711).
Do not ship a Swap query string on
dex.cl8y.comuntil that MR is merged and Coolify has deployed it. Todayhttps://dex.cl8y.comignores Uniswap/Terra aliases, and/swap/?…dropssearchon redirect to/. A deep-link shipped early would still land on the default retail pair and look broken.After merge + Coolify: confirm live
https://dex.cl8y.com/?from=uluna&to=terra16wtml2q66g82fdkx66tap0qjkahqwp4lwq3ngtygacg5q0kzycgqvhpax3selects Pay LUNC and Receive CL8Y. Only then change this repo.
Summary
The marketing site’s primary Terra Classic trade venue is a bare origin (
CANONICAL_PRODUCT_URLS.dex=https://dex.cl8y.com). Pancake/TidalDex rows already use?outputCurrency=<token>. Once DEX #711 is live, CL8Y DEX should do the same: land the visitor on LUNC → CL8Y, not the homepage default pair.This is a href + docs/skills change in CL8Y-web. No DEX app work.
Current codebase
src/content/invariants.tshttps://dex.cl8y.com— no path, query, userinfo, or trailing slash (CANONICAL_PRODUCT_URLS).src/data/products.tsPRODUCT_URLS/ that origin. Keep those origin-only.src/data/tokenDirectory.tsTRADE_VENUESrowcl8y-dexuseshref: CANONICAL_PRODUCT_URLS.dex(bare origin). TidalDex/Pancake already appendoutputCurrency.skills/cl8y-token-directory/*https://dex.cl8y.com.skills/cl8y-site-positioning/*e2e/trade.spec.ts#tokenHTML containshttps://dex.cl8y.com.DEX parser (after !488): first-party outbound should mint
/?from=&to=withuluna/uusd/ checksummedterra1. Uniswap names (inputCurrency/outputCurrency) are inbound-only on the dApp.Canonical Terra Classic CL8Y CW20 (already in this repo):
terra16wtml2q66g82fdkx66tap0qjkahqwp4lwq3ngtygacg5q0kzycgqvhpax3Pay side:
uluna(display LUNC). Do not putLUNC/CL8Ytickers in first-party execute ids.Recommended direction
CANONICAL_PRODUCT_URLS.dex/ header “CL8Y DEX” product tile ashttps://dex.cl8y.com(positioning invariant: products are origins).CL8Y_DEX_SWAP_HREF, built withURLSearchParams(from=uluna,to=<TERRA_CLASSIC_CL8Y_ADDRESS>). Never concatenate user input. Host remainsdex.cl8y.com; path/or/swap/(both valid after #711).TRADE_VENUEScl8y-dex.href at that deep-link so directory / “Trade on DEX” matches Pancake-style pair landing.skills/cl8y-token-directory(and tests) so the trade-venue href is documented as the pair URL, while the product origin stays query-free.dex.cl8y.com. Do not addjavascript:, protocol-relative, or?url=redirectors./swap/?from=uluna&to=…is equivalent; prefer/?from=&to=to match DEX first-party helpers (swapDeepLinkPath).Acceptance criteria
CANONICAL_PRODUCT_URLS.dexremainshttps://dex.cl8y.comwith no query (product CTA / positioning).URLSearchParams, notwindow.location/ visitor query.e2e/trade.spec.tsstill passes (origin substring OK; assertfrom=/to=on the trade row if useful).yarn typecheck,yarn lint,yarn buildsucceed.Out of scope
0x…CL8Y into Terra Swap (wrong chain → DEX ignores).PRODUCT_URLS.dexheader CTA to include query (homepage “open the DEX” may stay origin-only).Cross-links
skills/AGENTS_FRONTEND_SWAP_QUERY_PARAMS.md(Q711-1–Q711-8)mentioned in merge request cl8y-dex-terraclassic!488
mentioned in issue cl8y-dex-terraclassic#713
mentioned in issue cl8y-dex-terraclassic#714
mentioned in issue cl8y-dex-terraclassic#716