Things I learned today

<Typography variant=”caption”>

Photography <HelpOutlineIcon style={{ position: ‘relative’, top: ‘8px’ }} />


This is one way to get an image and text to line up. Both position and top are important. Top will apply from the top of this line allowing the image to line up correctly. Position relative is also important to help lining things as the images will attempt to more or less stay in line relative to the the line it is in. This can also be done in the following way.

<InputLabel onClick={()=>console.log(‘clickerty clack’)} shrink={true} >Promo Type <AdminQuestionMark thisName={‘promo_type_cn’} /></InputLabel>

This talks about record which is useful for having one object have the same keys as another object

export const questionsIconInfoMainPageHtml: Record<keyof fullDataOfEachPromotion, JSX.Element> = {

JSX.Element also is the property of the key in this case.

\’ is what you use to escape out of a quote system to get add certain things that are difficult to add to a string.

(Object.keys(MyEnum) as Array<keyof typeof MyEnum>).map((key) => {})

mapping an enum can be done like so. Can be useful to get the keys

export default function SimpleDialogDemo() {
const [open, setOpen] = React.useState(false);
const [selectedValue, setSelectedValue] = React.useState(emails[1]);

const handleClickOpen = () => {

const handleClose = (value) => {

return (
<Typography variant="subtitle1">Selected: {selectedValue}</Typography>
<br />
<Button variant="outlined" color="primary" onClick={handleClickOpen}>
Open simple dialog
<SimpleDialog selectedValue={selectedValue} open={open} onClose={handleClose} />

This one details for text fields



Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store