2.7 KiB
2.7 KiB
AGENTS.md
Repository and validation
- Stage-mode HAR
@b2c/first_page: main modulebiz_firstpage, with a separatesrc/ohosTestHypium test module. RootIndex.etsis the host-facing export surface. - This checkout is not independently runnable:
hvigorfile.tsdefines HAR tasks, buthvigorw,oh_modules, and sibling../biz_quoteare absent. Sources also use host-provided modules beyond the root manifest'sbiz_quoteand theme-manager dependencies. - Do not claim local build or test success, add host dependencies, or invent standalone commands. Validate integration, including
src/ohosTestscaffolding where applicable, in the host project.
Feed wiring
- Export new host-facing symbols from root
Index.ets. - A normal feed card needs a datacenter
FirstPageConstant.KEY_*, model insertion, and aFirstPage.createNodeViewdispatch branch; metadata normally comes fromsrc/main/resources/rawfile/first_page_cards_config.json. market-rankingis special:FirstPageinserts and renders it directly underKEY_MARKET_RANKING; its loader config key ismarketRanking.- The two
FirstPageConstant.etsfiles differ:datacenter/defines cardKEY_*values;util/exportsTITLE_BAR_HEIGHTonly.
Market ranking
- Keep the two-stage data path:
MarketRankingDataFetcherobtains recommended contracts through@kit.NetworkKit, thenMarketRankingHqRequestClientsubscribes them through the hostTableRequestClient/4106 path. Do not substitute mock data or another quote client. MarketRankingConstant.etscouples UI labels, HTTP parameters, and 4106 fields inTAB_METRICSandPERIOD_RANGES; update ordering, IDs, and child-tab semantics together.- Keep 4106 frame
2201, scenarioqht_qihuo_sort, andpushtime=2.5aligned with the subscription path. Release subscriptions on invisibility, tab changes, refresh, and destruction; reconstruct on TCP reconnect from the original HTTP contract list. - Preserve HTTP/quote request and subscription version guards. Preserve contract, market, and name ordering when rows call host
jumpToQuote(). - Validate 4106 IDs and standard-price fields, HTTP environment/auth, lifecycle/reconnect behavior, and quote routing in the host; see
doc/market-ranking-known-issues.mdbefore changing this area.
Resources and release
- Put user-facing text in
src/main/resources/{base,zh_CN,en_US}/element/string.json; use$r('app.color.*')with light/dark qualifiers rather than hardcoded theme colors. - Keep
FirstPageDebugUtil.isMarketRankingUseTestUrland other test-URL switchesfalsein commits. - Preserve existing root/deep
biz_quoteimport style. For public or reflective symbols, account for release ArkGuard rules inobfuscation-rules.txtandconsumer-rules.txt.