kopia lustrzana https://gitlab.com/soapbox-pub/soapbox
				
				
				
			Improve legacy Checkbox styles
							rodzic
							
								
									047c50cc02
								
							
						
					
					
						commit
						43d494d43c
					
				| 
						 | 
					@ -10,7 +10,7 @@ interface IFormGroup {
 | 
				
			||||||
  errors?: string[]
 | 
					  errors?: string[]
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
/** Input element with label and hint. */
 | 
					/** Input container with label. Renders the child. */
 | 
				
			||||||
const FormGroup: React.FC<IFormGroup> = (props) => {
 | 
					const FormGroup: React.FC<IFormGroup> = (props) => {
 | 
				
			||||||
  const { children, errors = [], labelText, hintText } = props;
 | 
					  const { children, errors = [], labelText, hintText } = props;
 | 
				
			||||||
  const formFieldId: string = useMemo(() => `field-${uuidv4()}`, []);
 | 
					  const formFieldId: string = useMemo(() => `field-${uuidv4()}`, []);
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -65,10 +65,9 @@ code {
 | 
				
			||||||
      position: relative;
 | 
					      position: relative;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
      .label_input > label {
 | 
					      .label_input > label {
 | 
				
			||||||
        @apply text-black dark:text-white;
 | 
					        @apply text-sm font-medium text-gray-700 dark:text-gray-400;
 | 
				
			||||||
        font-family: inherit;
 | 
					        font-family: inherit;
 | 
				
			||||||
        font-size: 14px;
 | 
					        font-size: 14px;
 | 
				
			||||||
        padding-top: 5px;
 | 
					 | 
				
			||||||
        display: block;
 | 
					        display: block;
 | 
				
			||||||
        width: auto;
 | 
					        width: auto;
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
| 
						 | 
					@ -84,7 +83,7 @@ code {
 | 
				
			||||||
 | 
					
 | 
				
			||||||
      input[type="checkbox"] {
 | 
					      input[type="checkbox"] {
 | 
				
			||||||
        position: absolute;
 | 
					        position: absolute;
 | 
				
			||||||
        top: 3px;
 | 
					        top: 1px;
 | 
				
			||||||
        left: 0;
 | 
					        left: 0;
 | 
				
			||||||
      }
 | 
					      }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Ładowanie…
	
		Reference in New Issue