Skip to content

Can't center children #16

Open
Open
@bernaferrari

Description

@bernaferrari

If I have the following code and I can't figure out a way where I can make a "div w-full flex items-center justify-center" equivalent on email. All I want is to have a 100% width table that takes the full available width, then use the align attribute, but it doesn't work. Is there any easy solution?

      <ResponsiveColumn
                  style={{
                    textAlign: "center",
                    backgroundColor: "red",
                  }}
                  align="center"
                >
       <table
            cellPadding="0"
            cellSpacing="0"
            border={0}
            width="100%"
            style={{ margin: "0 auto", backgroundColor: "blue" }}
          >
            <tr>
              <td align="center">
                <table cellPadding="0" cellSpacing="0" border={0}>
                  <tr>
                    <td align="center">
                      <img
                        src={src}
                        alt={alt}
                        style={{
                          width: "100px",
                          height: "100px",
                          borderRadius: "50%",                        }}
                      />
                    </td>
                  </tr>
                  <tr>
                    <td>
                      <p> title </p>
                    </td>
                  </tr>
                </ResponsiveColumn>
image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions