def METHOD_NAME(
    cross_section: CrossSectionSpec = "metal_routing",
    with_bbox: bool = False,
    **kwargs,
) -> Component:
    """Returns 90 degrees electrical corner wire, where all cross_section sections properly represented.
    Works well with symmetric cross_sections, not quite ready for asymmetric.
    Args:
        cross_section: spec.
        with_bbox: if True, includes the bbox layer and bbox offsets of the cross_section
        kwargs: cross_section settings.
    """
    x = gf.get_cross_section(cross_section, **kwargs)
    xmin, ymax = x.get_xmin_xmax()
    main_section = gf.cross_section.Section(
        width=x.width,
        layer=x.layer,
        offset=x.offset,
    )
    all_sections = [main_section]
    all_sections.extend(x.sections)
    c = Component()
    for section in all_sections:
        layer = section.layer
        width = section.width
        offset = section.offset
        b = width / 2
        xpts = [xmin, offset - b, offset - b, offset + b, offset + b, xmin]
        ypts = [
            -offset + b,
            -offset + b,
            ymax,
            ymax,
            -offset - b,
            -offset - b,
        ]
        c.add_polygon([xpts, ypts], layer=layer)
    corner_bbox = c.bbox
    if with_bbox:
        bbox_layers = x.bbox_layers
        bbox_offsets = x.bbox_offsets
        for bbox_layer, bbox_offset in zip(bbox_layers, bbox_offsets):
            c << gf.components.bbox(
                corner_bbox,
                layer=bbox_layer,
                top=bbox_offset,
                bottom=bbox_offset,
                left=bbox_offset,
                right=bbox_offset,
            )
    c.add_port(
        name="e1",
        center=(xmin, -(xmin + ymax) / 2),
        orientation=180,
        cross_section=x,
        layer=x.layer,
    )
    c.add_port(
        name="e2",
        center=((xmin + ymax) / 2, ymax),
        orientation=90,
        cross_section=x,
        layer=x.layer,
    )
    c.info["length"] = ymax - xmin
    c.info["dy"] = ymax - xmin
    return c