Frozen Columns with PrimeNG - Misalignment

Discussão em 'Angular' iniciado por RyRy, Fevereiro 21, 2025.

  1. RyRy

    RyRy Guest

    Good day,

    I have followed the example code from primeng-frozen-column-example. The code below does not seem to have an effect on the table at all.

    makeRowsSameHeight() {
    setTimeout(() => {
    if ($('.ui-table-scrollable-wrapper').length) {
    let wrapper = $('.ui-table-scrollable-wrapper');
    wrapper.each(function () {
    let w = $(this);
    let frozen_rows: any = w.find('.ui-table-frozen-view tr');
    let unfrozen_rows = w.find('.ui-table-unfrozen-view tr');
    for (let i = 0; i < frozen_rows.length; i++) {
    if (frozen_rows.eq(i).height() >
    unfrozen_rows.eq(i).height()) {
    unfrozen_rows.eq(i).height(frozen_rows.eq(i).height());
    } else if (frozen_rows.eq(i).height() <
    unfrozen_rows.eq(i).height()) {
    frozen_rows.eq(i).height(unfrozen_rows.eq(i).height());
    }
    }
    });
    }
    });
    }


    The frozen columns rows are misaligned as per the image -> Frozen Column misalignment.

    The alignment of the rows is misaligned how can this issue be fixed?

    Continue reading...

Compartilhe esta Página