mirror of
https://github.com/Growstuff/growstuff.git
synced 2026-11-01 02:39:26 -05:00
* 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
32 lines
1.6 KiB
React
32 lines
1.6 KiB
React
// Entry point for the React "islands": small React components mounted into
|
|
// server-rendered pages. Rails renders an empty element with
|
|
// data-react-component="Name" and data-props='{...}' (see the react_component
|
|
// helper); this finds each one and mounts the matching component.
|
|
//
|
|
// To add a component: create it in ./components and register it below.
|
|
import AuthDialog from './components/AuthDialog';
|
|
import FeedMore from './components/FeedMore';
|
|
import GardenCards from './components/GardenCards';
|
|
import GardenLayout from './components/GardenLayout';
|
|
import GardenPicker from './components/GardenPicker';
|
|
import GrowingTable from './components/GrowingTable';
|
|
import HarvestChart from './components/HarvestChart';
|
|
import LocationPicker from './components/LocationPicker';
|
|
import PhotoDialog from './components/PhotoDialog';
|
|
import PhotoPicker from './components/PhotoPicker';
|
|
import PlantPicker from './components/PlantPicker';
|
|
import PlantingPicker from './components/PlantingPicker';
|
|
import PlantingActions from './components/PlantingActions';
|
|
import PlantingRating from './components/PlantingRating';
|
|
import SeedLibrary from './components/SeedLibrary';
|
|
import SeedStack from './components/SeedStack';
|
|
import {mountIslands, registerIslands} from './islands';
|
|
|
|
registerIslands({AuthDialog, FeedMore, GardenCards, GardenLayout, GardenPicker, GrowingTable, HarvestChart, LocationPicker, PhotoDialog, PhotoPicker, PlantPicker, PlantingPicker, PlantingActions, PlantingRating, SeedLibrary, SeedStack});
|
|
|
|
if (document.readyState === 'loading') {
|
|
document.addEventListener('DOMContentLoaded', () => mountIslands());
|
|
} else {
|
|
mountIslands();
|
|
}
|