@TAXPACEE the issue is that the empty state text is displayed dynamically and the code has worked before empty state is shown.
This might work
<script>
const onRecords = (e) => {
setTimeout(() => {
if(window.logged_in_user) {
const name = window.logged_in_user.softr_user_full_name;
const firstName = name.split(' ').slice(0, -1).join(' ');
$("span:contains('{LOGGED_IN_USER:NAME}')").removeClass('d-none');
$("span:contains('{LOGGED_IN_USER:NAME}')").html(firstName);
}
}, 50);
};
window.addEventListener('get-records-table1', onRecords);
</script>
table1
is block name you see it in studio block config panel