Skip to content

feat(activity-days): add view's scaffolding#1133

Merged
simon-the-shark merged 16 commits into
mainfrom
das-scaffolding
May 24, 2026
Merged

feat(activity-days): add view's scaffolding#1133
simon-the-shark merged 16 commits into
mainfrom
das-scaffolding

Conversation

@MarmoPL
Copy link
Copy Markdown
Member

@MarmoPL MarmoPL commented May 3, 2026

No description provided.

@MarmoPL
Copy link
Copy Markdown
Member Author

MarmoPL commented May 3, 2026

@greptile

@greptile-apps
Copy link
Copy Markdown
Contributor

greptile-apps Bot commented May 3, 2026

Greptile Summary

Elo żelo solvrowiczu! This PR scaffolds the Activity Days feature, wiring up a new route (/activity-days), Freezed models, a Riverpod repository (with intentional if (true) mock while the API is unavailable), and a HookConsumerWidget view with a three-tab layout. NavActionsSection is also refactored from a Wrap to a Row layout to conditionally surface the Activity Days button when an event is active.

  • New feature scaffolding: Adds ActivityDaysView with tab navigation (Stands, Timetable, Information), route registration, and localization keys for both English and Polish.
  • Conditional home button: NavActionsSection now watches isActivityDaysActiveProvider and renders an accent-colored Activity Days button only during active events, using replaceFirst(\" \", \"\ \") on the title for the two-line nav label.
  • Mock-first development: The repository returns hardcoded mock data via if (true) with suppressed lint warnings — intentional scaffolding while the /das API endpoint is not yet available.

Confidence Score: 5/5

Safe to merge as scaffolding; the mock guard and placeholder tabs are intentional and the structural changes are sound.

All changes are well-scoped scaffolding. The Freezed models, route registration, and nav bar integration follow existing patterns correctly. The if(true) mock is acknowledged intentional scaffolding while the API is unavailable. Remaining nits are non-blocking for a scaffolding PR.

lib/features/activity_days/presentation/activity_days_view.dart (needs a widgetbook story) and packages/widgetbook/lib/features/home_view/widgets/nav_actions_section.stories.dart (needs provider mocking for the new isActivityDaysActive dependency).

Important Files Changed

Filename Overview
lib/features/activity_days/presentation/activity_days_view.dart New HookConsumerWidget view with TabBar scaffold; missing widgetbook story per project rules
lib/features/activity_days/data/repository/activity_days_repository.dart New Riverpod provider with intentional if(true) mock guard; real API path is scaffolded but unreachable
lib/features/activity_days/data/models/activity_days_response.dart Freezed models with correct IList collections; follows project patterns
lib/features/home_view/widgets/nav_actions_section.dart Refactored from Wrap to Row layout, adds conditional Activity Days button; widgetbook story not updated to mock new provider
lib/features/navigator/utils/navigation_commands.dart Adds navigateActivityDays(); missing trackEvent call unlike other navigation commands

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    HomeView --> NavActionsSection
    NavActionsSection -->|watches| isActivityDaysActiveProvider
    isActivityDaysActiveProvider -->|watches| activityDaysRepositoryProvider
    activityDaysRepositoryProvider -->|if true mock| MockData[Mock ActivityDaysResponse]
    activityDaysRepositoryProvider -.->|future: real API| DAS["/das endpoint"]
    NavActionsSection -->|isActive == true| ActivityDaysButton[Activity Days Nav Button]
    ActivityDaysButton -->|tap| navigateActivityDays
    navigateActivityDays --> ActivityDaysRoute
    ActivityDaysRoute --> ActivityDaysView
    ActivityDaysView --> TabBar["TabBar (Stands / Timetable / Info)"]
    TabBar --> PlaceholderTab["_PlaceholderTab x3"]
Loading

Reviews (6): Last reviewed commit: "Merge branch 'das-scaffolding' of github..." | Re-trigger Greptile

Comment thread lib/features/activity_days/data/models/activity_days_response.dart
Comment thread lib/features/activity_days/presentation/activity_days_view.dart
Comment on lines +314 to +316
Future<void> navigateActivityDays() async {
await _router.push(const ActivityDaysRoute());
}
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Missing analytics tracking event

All other feature-navigation commands in this extension call trackEvent(ClarityEvents.…) before pushing the route (e.g. navigateToSksMenu, navigateAboutUs, navigateToNotifications). navigateActivityDays skips this, so Activity Days usage will be invisible in Clarity analytics.

Comment thread lib/l10n/app_pl.arb
@MarmoPL MarmoPL linked an issue May 3, 2026 that may be closed by this pull request
@MarmoPL MarmoPL self-assigned this May 3, 2026
@simon-the-shark simon-the-shark force-pushed the main branch 10 times, most recently from 48b0e96 to 7811fd7 Compare May 10, 2026 00:27
@MarmoPL MarmoPL marked this pull request as ready for review May 15, 2026 22:44
@MarmoPL MarmoPL requested a review from simon-the-shark May 15, 2026 22:46
Comment thread lib/features/home_view/widgets/nav_actions_section.dart Outdated
Comment thread lib/features/home_view/widgets/nav_actions_section.dart
Copy link
Copy Markdown
Member

@simon-the-shark simon-the-shark left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

generally very nicely done. I've left few comments + tests are failling

Comment thread lib/features/activity_days/data/repository/activity_days_repository.dart Outdated
Comment on lines +56 to +58
} on DioException {
return null;
}
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

also this catch is not desired, we should just use getAndCacheData

Comment thread lib/features/home_view/widgets/nav_actions_section.dart Outdated
@simon-the-shark simon-the-shark changed the title feat: das scaffolding feat(activity-days): add view's scaffolding May 16, 2026
@simon-the-shark simon-the-shark force-pushed the main branch 4 times, most recently from cc32eb0 to 6740f6d Compare May 19, 2026 22:08
MarmoPL and others added 4 commits May 24, 2026 14:57
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
@MarmoPL MarmoPL requested a review from simon-the-shark May 24, 2026 19:10
@simon-the-shark simon-the-shark merged commit dc57c30 into main May 24, 2026
9 of 10 checks passed
@simon-the-shark simon-the-shark deleted the das-scaffolding branch May 24, 2026 19:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(activity-days): set up scaffolding for a new view

2 participants