import * as React from 'react'; export type ContainerProps = Readonly>; export const Container = React.forwardRef( ({ children, style = {}, ...props }, ref) => { // Split padding styles to improve compatibility with Klaviyo and Outlook, // while preserving user-provided style property order without allocating // entry arrays on each render. const tdStyle: React.CSSProperties = {}; const tableStyle: React.CSSProperties = {}; const styleRecord = style as Record; for (const key in styleRecord) { if (!Object.hasOwn(styleRecord, key)) { continue; } const value = styleRecord[key]; if ( key === 'padding' || key === 'paddingTop' || key === 'paddingRight' || key === 'paddingBottom' || key === 'paddingLeft' ) { (tdStyle as Record)[key] = value; } else { (tableStyle as Record)[key] = value; } } return (
{children}
); }, ); Container.displayName = 'Container';