Commit Graph
92 Commits
Author SHA1 Message Date
Brenda Wallace f9d7110783 adding tests or our react components 2026-10-23 21:34:33 +13:00
Brenda Wallace e64e893b4f Merge pull request #5015 from Growstuff/job-photos
Photos on jobs, before and after
2026-10-23 13:20:46 +10:30
google-labs-jules[bot]andCloCkWeRX e2a61c000b Match Layout button padding and sizing to Add Planting button
Co-authored-by: CloCkWeRX <365751+CloCkWeRX@users.noreply.github.com>
2026-10-23 10:06:56 +10:30
Brenda Wallace a0b24381ac Refactor activities to jobs across the application
- Renamed all instances of 'Activity' to 'Job' in views, controllers, and models.
- Updated routes to reflect the change from activities to jobs.
- Modified database schema to rename the activities table to jobs and adjusted related columns.
- Updated locale files to change activity-related translations to jobs.
- Adjusted tests to ensure they reference jobs instead of activities.
- Removed the category field from jobs as they are now a plain list.
- Updated seed data and sample data generation to create jobs instead of activities.
2026-10-22 17:16:25 +13:00
Brenda Wallace eb3f10132a Add tests for AlternateNames, GbifNameInput, NameFields, and ScientificNames components 2026-10-20 16:37:56 +13:00
Brenda Wallace 389efe9af4 Fix newRow function to handle undefined values correctly 2026-10-20 16:34:07 +13:00
Brenda Wallace ed193d088d Merge remote-tracking branch 'origin/main' into remove-coffee-rails 2026-10-20 16:33:41 +13:00
Brenda Wallace 3b4e6c6dd7 adding vitest, to test our react components 2026-10-20 13:48:29 +13:00
Brenda Wallace 3c5514a0cb Enhance GbifNameInput: improve match handling by tracking user input state and adjusting search conditions 2026-10-20 13:38:54 +13:00
Brenda Wallace 5aa751f0f3 Refactor crop name fields: replace manual input handling with reusable components for scientific and alternate names, and integrate GBIF name suggestions. 2026-10-20 13:11:49 +13:00
Brenda Wallace 88624d2ac8 Implement alternate names functionality with React component and update related specs 2026-10-20 13:06:04 +13:00
Brenda Wallace e40e74e1e4 Enhance seed search functionality: implement responsive layout for seed search input and expired seeds checkbox, and update hint display for better user experience. 2026-10-18 11:33:48 +13:00
Brenda Wallace f27be9ce91 Add browser time zone support: implement timezone cookie handling in application.js and adjust ApplicationController to use browser time zone for date calculations. 2026-10-18 10:30:28 +13:00
Brenda Wallace 2d97aed868 Enhance seed packet selection and sowing process: update SeedPacketList to include expired seeds option, improve UI for seed selection, and modify SowSeedsModal to support multi-step sowing with notes. 2026-10-18 10:19:32 +13:00
Brenda Wallace 8c7eed345e Enhance transplant functionality: update JSON responses to include garden card details, implement event handling for garden card changes, and improve UI interactions in related components. 2026-10-18 10:10:25 +13:00
Brenda Wallace 225a9057c5 Implement transplant functionality: refactor planting movement to record history of gardens, update modal for transplanting, and adjust related components and tests accordingly. 2026-10-17 22:57:38 +13:00
Brenda Wallace 3cfc80450d Refactor error handling and enhance seed packet selection: move errorMessages function to a dedicated file, implement SeedPacketList component for better seed selection UI, and update related components to utilize new error handling logic. 2026-10-17 22:34:15 +13:00
Brenda Wallace b620ca1ccc Enhance nursery functionality: add panel action for refreshing nursery in place, update nursery chip to exclude harvest and save seeds actions, and implement editing capability with modal dialog for batch updates. 2026-10-17 22:29:33 +13:00
Brenda Wallace f4107e2b8d Refactor nursery management: replace plant_out functionality with transplant modal
- Removed NurseryScoped concern and associated controllers for plant_out and leftovers.
- Introduced TransplantModal component for handling the transplanting of seedlings.
- Updated PlantingsController to support transplanting with a new date handling method.
- Modified GardensHelper to provide active gardens for transplanting.
- Updated NurseryChip component to include transplant functionality.
- Removed legacy plant_out views and associated routes.
- Adjusted tests to reflect the new transplanting workflow and removed obsolete tests related to plant_out.
2026-10-17 21:10:56 +13:00
Brenda Wallace 6b1ce4df8b removing plannted plantings 2026-10-17 20:15:27 +13:00
Brenda Wallace fd1ce98dd8 Enhance NurseryChip component: add photo upload functionality and update tests for dialog interaction in nursery panel. 2026-10-17 18:13:02 +13:00
Brenda Wallace 5f12637d82 Enhance nursery functionality: update styles for gardens section, improve NurseryChip component for better readability, and add tests for batch display and menu actions in nursery panel. 2026-10-17 18:06:07 +13:00
Brenda Wallace 074a72d719 Refactor nursery and planting features: introduce planned and sown scopes, enhance nursery chip component, update views for planned plantings, and improve test coverage for nursery functionality. 2026-10-17 17:57:21 +13:00
Brenda Wallace d1ab663d7b Enhance nursery functionality: add planning feature for sowing, improve nursery editing experience, and update styles for better user interaction 2026-10-17 17:51:55 +13:00
Brenda Wallace 09d28ee103 Enhance nursery panel and seed packet display: add SeedPacket component for visual representation of seed packets, update nursery panel with new button for declining nursery, and improve styles for better user interaction. 2026-10-17 17:30:34 +13:00
Brenda Wallace a8d0ea9da3 Enhance nursery and gardens display: add styles for gardens page, integrate nursery panel with improved functionality, and update components for better user interaction and visual consistency. 2026-10-17 15:50:04 +13:00
Brenda Wallace 25988d8cbb Enhance nursery panel and sowing modal: update styles for nursery day display, add functionality for sowing directly into gardens with placement options, and improve helper methods for better grouping and display of seedlings. 2026-10-17 15:27:34 +13:00
Brenda Wallace 099f2f58c1 Merge remote-tracking branch 'origin/main' into nursery 2026-10-17 13:37:22 +13:00
Brenda Wallace c67e7f3740 Implement crop sowing information feature: add CropSowingInfoSerializer, update CropsController with sowing_info action, create CropDetails component for displaying crop details, enhance SowSeedsModal to show crop information, and add tests for new functionality. 2026-10-17 13:34:24 +13:00
Brenda Wallace 84c4c0c6ed Implement nursery plant-out functionality: enhance styles for sowing and planting out, update GardensController with new actions for managing planted batches, and create views for planted out seedlings. 2026-10-17 13:32:24 +13:00
Brenda Wallace 310d7245a3 Implement nursery sowing functionality: add SowSeedsModal component, enhance planting logic to track seed usage, and update nursery views to display sown and planned seedlings. 2026-10-17 13:11:48 +13:00
Brenda Wallace ca7fd81439 Tidy/login signup (#4958)
* Add authentication dialogs for sign in and sign up

- Implemented AuthDialog component to manage sign in and sign up modals.
- Created SignInModal and SignUpModal components for handling respective authentication processes.
- Added AuthFields component for reusable form fields and error handling.
- Updated various views to utilize the new authentication dialogs instead of traditional links.
- Enhanced user experience by allowing sign in and sign up actions to occur without full page reloads.
- Added feature specs for testing the functionality of the new dialogs.

* Refactor modals and input fields for improved accessibility and styling; adjust button sizes and text formatting

* Refactor authentication forms and modals for improved usability and accessibility; integrate reCAPTCHA handling and enhance error messaging

* Refactor SignUpModal layout for improved responsiveness and accessibility; organize fields into rows and enhance styling

* Refactor session view spec to streamline field checks; remove redundant test and retain essential content expectations
2026-10-17 09:26:39 +10:30
Brenda Wallace 747efe4b4a Implement nursery feature: add nursery management actions in GardensController, create NurseryPlanter component, update views for nursery setup, and enhance member model for nursery acceptance and decline. 2026-10-16 23:38:20 +13:00
Brenda Wallace 77f29bfab9 Remove unused post-actions styles and optimize imports in MarkFinishedModal 2026-10-16 22:21:26 +13:00
Brenda WallaceandClaude Sonnet 5.5 b7dbb84ebd Add a garden and plant from the home page without leaving it
The garden dialog now adds a garden as well as edits one (new.json and
create.json on GardensController), and a GardenPicker button opens it from the
home page. A plant_picker helper replaces the home page's separate plant
links and the plant_button partial. The plant dialog asks when it was
planted (Today, Yesterday, Enter date), using a WhenPicker shared with the
harvest dialog. Members with no garden still get the full-page plant link.

Part of #4933

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-16 22:21:26 +13:00
Brenda WallaceandClaude Sonnet 5.5 a5156f6b9e Add the garden form dialog
One dialog for adding and editing a garden, replacing the edit-only dialog
in the next commit.

Part of #4933

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-16 22:21:26 +13:00
Brenda WallaceandClaude Sonnet 5.5 64c9bd3baa Open every add-photo link in the photo dialog
The dialog is mounted once in the layout and any link marked
data-photo-dialog opens it, naming its record in the heading. The gardens
and posts menus, the old planting card and add_photo_button now use it
instead of going to the new-photo page.

Part of #4933

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-16 22:21:26 +13:00
Brenda WallaceandClaude Sonnet 5.5 5fed21e811 Keep menu icons in one place and remove unused helpers
The icon drawings were duplicated between Ruby and React; they now live in
app/javascript/menuIcons.json, read by both. Deletes the button and icon helpers
nothing calls any more, and their spec lines.

Part of #4933

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-16 22:21:26 +13:00
Brenda WallaceandClaude Sonnet 5.5 be04ef963f Give record action menus a shared three-dot menu with green icons
One actions_menu helper now builds the three-dot toggle and dropdown for
seeds, harvests, crops, gardens, posts, photos, activities and comments,
replacing the text "Actions" toggle. Every item carries a green line icon
(menu_icon), and delete uses a darker red ($danger-text, 5.6:1 on white)
so it stays readable; it is still last, under a divider, with its own icon.
The React menus draw the same icons. DESIGN.md now says menu items have icons.

Also fixes the posts menu delete, which confirmed but never sent DELETE.

Closes #4939
Closes #4940
Closes #4942
Closes #4943
Closes #4944
Closes #4945
Closes #4946
Part of #4933

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
2026-10-16 22:21:26 +13:00
Brenda Wallace c8c32014bb tidying up, as react components 2026-10-16 17:32:09 +13:00
Brenda Wallace fdebe79b7d Refactor seed management features
- Introduced `@other_count` in SeedsController to track in-stock and finished seeds based on the filter applied.
- Enhanced SeedsHelper with new methods: `seed_owner_label`, `seed_stacks`, and `seed_choice_link` for better organization and readability.
- Updated views to utilize new helper methods, improving the display of seed information and filtering options.
- Adjusted the Seed model to include methods for determining if a seed's sow-by date has passed and to return the heirloom type.
- Improved tests for filters and helper methods to ensure accurate functionality and coverage.
2026-10-16 17:32:09 +13:00
Brenda Wallace 5926047199 Implement SeedStack component and enhance seed display with owner avatars and improved styles 2026-10-16 17:32:09 +13:00
Brenda Wallace 3b06325e62 Add friends and neighbours feature with member dismissal functionality
- Implement RecentActivity service to track recent planting, harvesting, and trading events.
- Enhance TimelineService to include garden layouts in event queries.
- Update navigation menu to include a link to friends and neighbours.
- Create member card partial for displaying gardener information.
- Add follow button partial for managing follow actions.
- Refactor members index view to use the new member card partial.
- Introduce neighbours feed view with daily updates and entries.
- Implement entry partial for displaying individual neighbour activities.
- Create layout partial for visualizing garden layouts.
- Add posts section to neighbours view for displaying recent posts.
- Implement reach section to show nearby gardeners.
- Add suggestions section for recommending gardeners to follow.
- Create routes for neighbours functionality and member dismissals.
- Add migrations for member dismissals and garden layout timestamps.
- Write feature and request specs for neighbours functionality.
- Include support for creating located members in tests.
2026-10-13 17:08:18 +13:00
Brenda Wallace b94c4c437e Add filters and update GrowingTable component for improved plant and garden selection 2026-10-13 13:46:22 +13:00
Brenda Wallace b386ddace2 Add ChipToggle component and refactor HarvestChart and GrowingTable to use it 2026-10-13 13:12:24 +13:00
Brenda Wallace 31978698c2 the growing/ready on the home page should also be react, so it changes without a page reload 2026-10-13 13:10:12 +13:00
Brenda Wallace 29c9cb2ef6 show harvests by count, not weight 2026-10-13 13:08:02 +13:00
Brenda Wallace a06b281a1d overlay modal forms for the homepage 2026-10-12 21:45:53 +13:00
Brenda Wallace 54258de6c4 Refactor home dashboard and related components
- Removed unused styles and helper methods from _garden_layout.scss, _homepage.scss, and overrides.scss.
- Updated _home_dashboard.scss to enhance button styles and added new harvest picker styles.
- Introduced HarvestPicker component for improved harvest recording functionality.
- Refactored home dashboard views to utilize new home_section helper for consistent layout.
- Simplified and optimized existing methods in application_helper.rb, activity.rb, and harvest.rb.
- Removed deprecated homepage_records methods from Activity and Harvest models.
- Updated tests to reflect changes in helper methods and removed obsolete tests.
2026-10-12 19:24:55 +13:00
Brenda Wallace ef06bab74f Add crop suggestions feature and dashboard enhancements
- Introduced crop suggestions functionality allowing users to receive tailored crop recommendations based on their location and preferences.
- Implemented the ability for users to dismiss specific crop suggestions, preventing them from receiving recommendations for crops they are not interested in.
- Added a location picker for users to set their gardening location, enhancing the accuracy of crop suggestions.
- Enhanced the dashboard to display relevant statistics, including plantings and harvests, with comparisons to previous years.
- Created new views and partials for displaying statistics, crop suggestions, and user interactions on the dashboard.
- Updated routes to accommodate new features related to crop suggestions and member locations.
- Added migrations for new database tables and columns to support crop dismissal and suggestion preferences.
- Developed tests for the new features, ensuring functionality and user experience are maintained.
2026-10-12 19:12:18 +13:00