I-TECH-UW / OpenELIS-Global-2

OpenELIS 2.X is a rewrite of the original OpenELIS global with updated components and technology
http://openelis-global.org/
Mozilla Public License 2.0
76 stars 203 forks source link

Use Carbon Grid for Layout instead of Using custom css classes #978

Open mozzy11 opened 7 months ago

mozzy11 commented 7 months ago

In some of our form components , we use custom classes for the form Layout ie we use the inlineDiv class to arange elements in a row inside a form .


                     <div className="inlineDiv">
                         <div>
                              <TextInput required name="name" className="InputText"/>
                              <TextInput required name="name" className="InputText"/>
                         </div>
                      </div>
                     <div className="inlineDiv">
                        <div>
                             <TextInput required name="name" className="InputText"/>
                             <TextInput required name="name" className="InputText"/>
                         </div>
                      </div>

We can use the Carbon Grid to create the similarLayout which is easier to control responsiveness

                     <Grid>

                            <Column lg={8}>
                                <TextInput required name="name" >                    
                            </Column >
                            <Column lg={8}>
                                <TextInput required name="name"/>
                            </Column >   

                           <Column lg={8}>
                               <TextInput required name="name" "/>
                            </Column >  
                             <Column lg={8}>    
                               <TextInput required name="name" >
                             </Column >

                      <Grid>
Lovelyfin00 commented 7 months ago

Hi @mozzy11 I'd like to work on this

Muta-Jonathan commented 1 month ago

Hello @mozzy11 would like to work on this 👍🏿

Muta-Jonathan commented 1 month ago

hey @mozzy11 PR here https://github.com/I-TECH-UW/OpenELIS-Global-2/pull/1268