Repository navigation
docs android forum
The product contract owns behavior. Preserve current root modules, com.anpfuel, MIT notices and bottom navigation.
-
CommunityScreen
renders a LazyColumn: city → contribution card → price activity → filters →
existing station price rows. Insert exactly one Forum item between the first
two existing items. Do not replace
FeedPriceCardor its actions. - CommunityFeedViewModel owns city/fuel/sort, foreground refresh and cancellation. It remains the price feed owner; Forum gets separate ViewModels and no price refresh loop.
- Routes and AnpNavGraph own navigation. The graph already renders a common bottom bar on ordinary child destinations; Forum must not mount a second bar or Scaffold inset stack.
-
AbastevoBottomBar
owns exactly Explore, Community, Map and Profile. Its route classifier may
require a minimal
forum/→ COMMUNITY mapping to keep selection correct on children; do not add/reorder tabs, change icons or alter tab-base behavior. -
ActionCardButton,
Theme and
container guidelines supply current controls,
active app theme (Energia brand palette or opt-in dynamic colors) and shared
AnpContainerDefaultsborder/shape. - AnpFuelDatabase is version 36 at inspection; allocate next Room version on current main, update explicit migrations/schema export without destructive fallback.
- Existing
domain,application,data,appmodules remain the dependency direction. Reusedata/diHilt conventions and existing configured backend origin/session/signer; do not add a hardcoded origin or/v1twice.
Proposed routes: forum/feed, forum/posts/{postId}, forum/new,
forum/posts/{postId}/edit. UUID arguments validate before request. Entry uses
singleTop without clearing Community. Detail/form use normal push/pop. Back and
gesture return to the previous entry's city/filter/list position; a deliberate
bottom-tab action keeps current navigateToTabBase semantics. External article
opening returns to the same detail, not a new app root. No public deep links in
baseline; add only if a verified distribution need and host contract exist.
Use navigation-entry-scoped Hilt ViewModels, immutable StateFlow UiState and
collectAsStateWithLifecycle. State distinguishes initial loading, refreshing,
loading next page, empty, content, offline/stale, terminal error, cursor expiry,
auth-needed, pending-review receipt and write-unknown outcome. SavedStateHandle
stores filter, selected post ID and scroll anchor only. Keep a rememberSaveable LazyListState
per navigation entry and filter scope; do not recreate the Community back-stack
entry merely to return from Forum. User draft is memory-only
and cleared on account change/logout; process death explains draft loss rather
than persisting private text silently. No raw post text in analytics or logs.
Every query has normalized scope + request generation. Filter changes, refresh, account/origin changes and navigation disposal cancel obsolete requests and refuse their late results. One first-page and one next-page operation per scope; append de-duplicates IDs while preserving server order. Refresh replaces snapshot and cursor atomically. Repeated submit taps share one operation UUID; unknown network result offers retry of the same operation, never optimistic duplication. No timer/poll loop: load on entry, explicit refresh or one network recovery event when stale and foreground. Preserve successful content on non-authoritative network failure; a live 404/erasure clears it.
Purpose: discover the new destination without competing with price contribution.
Use one full-width neutral surfaceContainerLow card with shared shape and
borderStroke(effectiveFill); 16dp padding and existing 12dp inter-item spacing.
Leading Material conversation icon is decorative. Title “Fórum Abastevo”,
description “Notícias, novidades e discussões sobre o mundo automotivo.”, CTA
“Explorar fórum”. Existing ActionCardButton may provide the action only if it
does not add nested redundant outlines; otherwise use the existing Material
button style inside the card. One clear focusable CTA; no double clickable card
and button announcing the same action. Visible even without city selection.
Data/dependency: Forum feature-read capability only, no feed fetch from this card. Show it only for an enabled compatible backend. Default-off gate avoids a dead route in unsupported releases. Failure disables Forum entry availability through config, never price contribution. Match app-selected light/dark/dynamic theme; no fixed colors, heights, badge pile, banner artwork or emoji asset.
Purpose: discover content. Top app bar “Fórum Abastevo”, back and refresh actions; one compact category selector, then reading-first LazyColumn. Each item shows kind label, readable title, optional permitted short introduction, source/author and original date. No image slot in MVP, no like counter, no giant stacked CTA. News shows source date; editorial/topics show first publication date; changes are labeled updated/corrected rather than silently replacing original time.
Data: GET categories/posts; repository public cache. Filter default is all Brazil, not a hidden GPS/city restriction. Regional subject filtering becomes explicit in FOR-24. Optional text search is debounced 400ms and cancellable; recent order stays predictable. Add “Novo tópico” only after FOR-23 and writes enabled; visitor opens existing sign-in and returns without auto-posting.
States: skeleton for first load; honest empty category/no content; retained list with inline retry for page failure; explicit load-more initially (no unbounded autofetch); refresh indicator separate from initial skeleton. Expired cursor offers reload. Offline shows age and cached editorial rows, no cached user rows. One explanatory error/retry replaces an empty inaccessible route.
Purpose: read and understand provenance, then discuss. Title, type, source/alias, original time, update/correction label, original introduction/body with generous line spacing; explicit “Ler na fonte” with hostname for news. A bulletin uses a compact methodology/provenance block, not an invented chart. Related station uses existing UUID route when present; it does not override map selection.
Data: public post plus separately paginated comments/replies; no N+1 network call per card/author. Text only; long-form reading does not use WebView. Comments are a section of the same LazyColumn, with stable IDs and bounded one-level replies opened on demand. Composer remains reachable above IME/navigation insets. Owner actions use a separate private owner read; public alias comparison is never authorization. “Denunciar” is available for eligible signed accounts, with a simple reason dialog and safe receipt.
States: 404/hidden removes stale local copy and shows unavailable; transport error can show eligible cached editorial with age. Social section offline offers retry without claiming zero comments. Pending submission shows a review receipt, not a new public comment. Expired session prompts existing auth, preserving only memory draft for the same owner. Review rejection/hide reason and appeal contact are shown in the private receipt view when applicable, not public report data.
Purpose: intentional, bounded publication. Topic form: title/body/category, optional explicit region, counter/help and submit. Comment editor: plain text and counter; reply target is named without recursive nesting. No attachment, private location, automatic publisher link card or forced GPS/account payment.
Data: signed POST commands with server-derived identity, operation UUID and expected revision; private owner read on edit. Disabled submit until valid; while sending, retain the same intent and expose progress. Server limits remain authoritative. 409 offers reload/copy current draft, never overwrites silently; 429 shows retry time; 401 routes to sign-in; foreign 404 closes editor safely; unknown outcome retries same intent; cancellation does not falsely show failure or create a second submission. Back with unsent text asks to discard; no silent send. Delete has explicit confirmation and scrubs current/cached text on success.
New domain/.../forum types and ports; application/.../forum use cases where
current analogous use cases live (confirm exact placement in FOR-06);
data/remote/ForumHttpClient.kt, data/repository/ForumRepositoryImpl.kt,
data/di/ForumModule.kt; app/ui/forum/{ForumFeed,ForumPost,ForumEditor}ViewModel.kt
and corresponding Compose routes/content. These are proposed new files, not
claims that these classes already exist. Reuse existing HTTP cancellation,
bounded decoding, coroutine dispatcher and auth refresh patterns; no new
networking/paging library is assumed.
Room entities: one cached post per origin/id/revision plus bounded feed scope membership/order. Cache only public editorial/news/bulletin records. Limit five scopes ×20 summaries and twenty details, maximum 2 MiB text total, 24h TTL; LRU/expiry cleanup before admitting more. Do not store full unlimited cursor chains. Filters/origin define cache scope; origin switch cannot reuse another backend's UUID/content. Online refresh replaces memberships transactionally; never return a remembered old cursor as live. Social public/private results remain memory-only; logout clears drafts/private state and cancels owned work. Future privacy/legal policy may demand a shorter cache horizon before launch.
Use existing typography and Material tokens with >=48dp touch targets; title heading semantics, logical source/date/body/comment reading order, meaningful button labels, decorative icon descriptions null. Do not truncate important source attribution or reduce font size to fit. Support 320dp, long translated labels, 100/130/200% font, light/dark/fixed/dynamic themes and IME/system bars. Display device-local date/time with a timezone-accessible full timestamp; source date stays unchanged in the API. No machine translation of source articles.
All new strings belong in default and every currently supported locale
(values, pt-BR, es, de, fr, ja, ru, zh-rCN at inspection); verify resource
directories on current main before editing. Tests cover keys/plurals/long labels;
editorial content remains its source language, marked when different.
Extend actual CommunityFeedScreenTest and BottomTabNavigationDeviceTest, plus Forum-specific JVM/HTTP/Room/native tests in the validation plan. Native controller navigation, screenshots, font/theme/IME and TalkBack traversal are distinct from JVM tests or APK compilation. The final union/device batch remains OWED until executed; preserve existing user deferral policy and report its state honestly.
- Home
- Roadmap
- docs-README
- docs-android-build
- docs-android-design-system
- docs-android-forum
- docs-android-games
- docs-android-map-engine
- docs-android-navigation
- docs-android-ocr-image
- docs-android-ocr-live-framing
- docs-android-premium-area
- docs-android-premium-integration
- docs-android-release
- docs-android-ui-containers
- docs-architecture-android-stack
- docs-architecture-android
- docs-architecture-backend
- docs-architecture-data-sources
- docs-architecture-overview
- docs-architecture-sources-ev-research
- docs-architecture-sources-national-limits
- docs-architecture-sources-national-stations
- docs-architecture-sources-register
- docs-assets-app-tutorial-CAPTURE_CONTRACT
- docs-assets-app-tutorial-FABLE_LANDING_POLISH_PROMPT
- docs-assets-app-tutorial-README
- docs-assets-attribution
- docs-assets-brand-README
- docs-assets-flags-ATTRIBUTION
- docs-assets-fuel-icons-README
- docs-assets-games-fuel-v1-README
- docs-assets-home-icons-README
- docs-assets-landing-fleet-android-20261012-BRIEF
- docs-assets-landing-hero-20261011-BRIEF
- docs-assets-landing-illustrated-20261012-BRIEF
- docs-assets-landing-illustrated-20261012-README
- docs-assets-landing-minimal-20261012-BRIEF
- docs-assets-landing-open-data-20261026-BRIEF
- docs-assets-landing-redesign-20261011-PREPARATION_EVIDENCE
- docs-assets-landing-redesign-20261011-README
- docs-assets-landing-redesign-20261011-REFERENCE_BRIEF
- docs-assets-landing-sync-20261012-BRIEF
- docs-assets-map-icons-README
- docs-backend-anp-ingestion
- docs-backend-api
- docs-backend-community-pricing
- docs-backend-data-model
- docs-backend-domain-model
- docs-backend-driver-private-data
- docs-backend-forum-architecture
- docs-backend-forum-bulletins
- docs-backend-forum-sources
- docs-backend-payments-provider-admission
- docs-backend-payments-provider-register
- docs-backend-photos-capture
- docs-backend-photos-subset-submission
- docs-backend-premium-api
- docs-backend-premium-cloud-protocol
- docs-backend-testing
- docs-backend-toolchain
- docs-brand-app-icons
- docs-brand-identity
- docs-decisions-001-kotlin-compose-stack
- docs-decisions-002-price-import-immutability
- docs-decisions-003-nominatim-reverse-geocode
- docs-decisions-005-modular-monolith-and-postgresql
- docs-decisions-006-official-catalog-and-exact-contracts
- docs-decisions-007-anonymous-proof-of-possession
- docs-decisions-008-privacy-and-retention
- docs-decisions-009-community-consensus-and-projections
- docs-decisions-010-private-object-evidence
- docs-decisions-012-licensing-and-hosted-business
- docs-decisions-015-kotlin-multiplatform-shared-domain
- docs-decisions-016-android-commercial-community-ios-deferred
- docs-decisions-017-station-profile-and-verified-representation
- docs-decisions-021-community-first-contribution
- docs-decisions-022-comaps-derived-native-map-engine
- docs-decisions-023-admin-suite-granted-tiers-contributors
- docs-decisions-025-private-abastevo-empresas-organization-boundary
- docs-decisions-026-multilingual-public-site
- docs-decisions-README
- docs-enterprise-README
- docs-enterprise-architecture
- docs-enterprise-backlog-INDEX
- docs-enterprise-backlog-ep00-governance
- docs-enterprise-backlog-ep01-platform
- docs-enterprise-backlog-ep02-organizations
- docs-enterprise-backlog-ep03-identity-access
- docs-enterprise-backlog-ep04-sync
- docs-enterprise-backlog-ep05-fleet-meters
- docs-enterprise-backlog-ep06-trips
- docs-enterprise-backlog-ep07-gps-navigation
- docs-enterprise-backlog-ep08-fuelings
- docs-enterprise-backlog-ep09-documents
- docs-enterprise-backlog-ep10-expenses-finance
- docs-enterprise-backlog-ep11-maintenance
- docs-enterprise-backlog-ep12-fuel-stock
- docs-enterprise-backlog-ep13-intelligence
- docs-enterprise-backlog-ep14-station-claims
- docs-enterprise-backlog-ep15-station-commerce
- docs-enterprise-backlog-ep16-subscriptions
- docs-enterprise-backlog-ep17-data
- docs-enterprise-backlog-ep18-imports-notifications-integrations
- docs-enterprise-backlog-ep19-back-office
- docs-enterprise-backlog-ep20-release
- docs-enterprise-business-rules
- docs-enterprise-contract
- docs-enterprise-conventions
- docs-enterprise-data-offering
- docs-enterprise-decisions
- docs-enterprise-domain-model
- docs-enterprise-glossary
- docs-enterprise-journeys
- docs-enterprise-modules-back-office
- docs-enterprise-modules-data
- docs-enterprise-modules-documents
- docs-enterprise-modules-expenses-finance
- docs-enterprise-modules-fleet
- docs-enterprise-modules-fuel-stock
- docs-enterprise-modules-fuelings
- docs-enterprise-modules-gps-navigation
- docs-enterprise-modules-identity
- docs-enterprise-modules-imports-notifications-integrations
- docs-enterprise-modules-intelligence
- docs-enterprise-modules-maintenance
- docs-enterprise-modules-organizations
- docs-enterprise-modules-station-claims
- docs-enterprise-modules-station-commerce
- docs-enterprise-modules-subscriptions
- docs-enterprise-modules-trips
- docs-enterprise-offline-sync
- docs-enterprise-permissions
- docs-enterprise-portal-routes
- docs-enterprise-privacy-security
- docs-enterprise-product-vision
- docs-enterprise-source-admission
- docs-enterprise-state-model
- docs-enterprise-testing
- docs-enterprise-ux-app
- docs-enterprise-ux-web
- docs-operations-README
- docs-operations-backup
- docs-operations-deploy-agent
- docs-operations-dou-editions
- docs-operations-edge-cache
- docs-operations-enterprise-activation
- docs-operations-map-static-overlay
- docs-operations-moderation-feedback
- docs-operations-moderation-profiles
- docs-operations-monitoring
- docs-operations-operator-access
- docs-operations-payments
- docs-operations-premium-billing
- docs-operations-recovery
- docs-operations-registry-daily-sync
- docs-operations-registry-runs
- docs-product-README
- docs-product-admin-tiers
- docs-product-community-community-first
- docs-product-community-experience
- docs-product-community-metrics
- docs-product-community-moderation
- docs-product-community-safety
- docs-product-community-terms-pt-br
- docs-product-driver-suite-README
- docs-product-driver-suite-android-state
- docs-product-driver-suite-cloud-sync
- docs-product-driver-suite-cost-profiles-and-maintenance
- docs-product-driver-suite-driver-model-and-earnings
- docs-product-driver-suite-foundation-decisions
- docs-product-driver-suite-gps-lifecycle
- docs-product-driver-suite-mobile-hub
- docs-product-driver-suite-odometer-review
- docs-product-driver-suite-outbox-wire
- docs-product-driver-suite-quick-refuel
- docs-product-driver-suite-reports
- docs-product-driver-suite-shifts-and-distance
- docs-product-driver-suite-signed-commands
- docs-product-ev-README
- docs-product-ev-charging-stop-planner
- docs-product-ev-energy-model
- docs-product-ev-financial-method
- docs-product-ev-journey-ui
- docs-product-ev-preparation
- docs-product-ev-typed-data
- docs-product-exploration
- docs-product-forum-contract
- docs-product-forum-policies
- docs-product-glossary
- docs-product-landing-content
- docs-product-landing-guides
- docs-product-landing-organic-growth-i18n-plan
- docs-product-licensing
- docs-product-map-discovery
- docs-product-map-favorites-and-trips
- docs-product-map-reports-routing-guidance
- docs-product-notification-content
- docs-product-official-prices
- docs-product-open-source-business
- docs-product-overview
- docs-product-payments-README
- docs-product-payments-offer-policy
- docs-product-premium-README
- docs-product-premium-financial-method
- docs-product-premium-source-policy
- docs-product-stations-catalog
- docs-product-stations-fuel-feedback
- docs-product-stations-fuel-quality
- docs-product-stations-identity-and-ev-catalog
- docs-product-stations-profile-contract
- docs-product-stations-profile-representation
- docs-product-stations-registry-sources
- docs-product-vehicle-registration
- docs-product-vehicles-and-occurrences
- docs-security-android-terms-acceptance
- docs-security-free-account-access
- docs-security-identity-profile
- docs-security-media-location-policy
- docs-security-privacy-notice
- docs-security-privacy-policy
- docs-security-retention
- docs-security-risks
- docs-security-security-privacy
- docs-store-README
- docs-store-play-readiness
- docs-store-play-store-listing
- docs-store-ugc-safety
Source: AlexandreZanata/Abastevo @ e4a67580fc368a59bc1c0f1e0466fc011313f330