def METHOD_NAME(ds: Dataset) -> str:
    out = '<tr>'
    if ds.coords:
        out += f'<th style="{CENTER}" colspan="{len(ds.coords)}">Coordinates</th>'
    for i, (_, da) in enumerate(sorted(ds.items())):
        border = '' if (i == 0) and (not ds.coords) else LEFT_BORDER
        out += f'<th style="{CENTER + border}">Data</th>'
        if da.masks:
            out += f'<th style="{CENTER}" colspan="{len(da.masks)}">Masks</th>'
        if da.attrs:
            out += f'<th style="{CENTER}" colspan="{len(da.attrs)}">Attributes</th>'
    out += '</tr>'
    return out