coer-elements 0.0.84 → 0.0.85

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -3451,12 +3451,18 @@ class CoerToolbar {
3451
3451
  this.onClickUser = output();
3452
3452
  //computed
3453
3453
  this.userName = computed(() => {
3454
- const name = Tools.IsNotNull(this.user()) && Tools.IsNotOnlyWhiteSpace(this.user()?.name) ? this.user().name : '';
3455
- const firstName = Tools.IsNotNull(this.user()) && Tools.IsNotOnlyWhiteSpace(this.user()?.firstName) ? this.user().firstName : '';
3456
- const middleName = Tools.IsNotNull(this.user()) && Tools.IsNotOnlyWhiteSpace(this.user()?.middleName) ? this.user().middleName : '';
3457
- const lastName = Tools.IsNotNull(this.user()) && Tools.IsNotOnlyWhiteSpace(this.user()?.lastName) ? this.user().lastName : '';
3458
- const secondLastName = Tools.IsNotNull(this.user()) && Tools.IsNotOnlyWhiteSpace(this.user()?.secondName) ? this.user().secondLastName : '';
3459
- return `${name} ${firstName} ${middleName} ${lastName} ${secondLastName}`.trim();
3454
+ const user = this.user();
3455
+ if (Tools.IsNotNull(user)) {
3456
+ if (Tools.IsNotOnlyWhiteSpace(user?.fullName))
3457
+ return user?.fullName;
3458
+ const name = Tools.IsNotNull(this.user()) && Tools.IsNotOnlyWhiteSpace(this.user()?.name) ? this.user().name : '';
3459
+ const firstName = Tools.IsNotNull(this.user()) && Tools.IsNotOnlyWhiteSpace(this.user()?.firstName) ? this.user().firstName : '';
3460
+ const middleName = Tools.IsNotNull(this.user()) && Tools.IsNotOnlyWhiteSpace(this.user()?.middleName) ? this.user().middleName : '';
3461
+ const lastName = Tools.IsNotNull(this.user()) && Tools.IsNotOnlyWhiteSpace(this.user()?.lastName) ? this.user().lastName : '';
3462
+ const secondLastName = Tools.IsNotNull(this.user()) && Tools.IsNotOnlyWhiteSpace(this.user()?.secondName) ? this.user().secondLastName : '';
3463
+ return `${name} ${firstName} ${middleName} ${lastName} ${secondLastName}`;
3464
+ }
3465
+ return '';
3460
3466
  });
3461
3467
  //computed
3462
3468
  this.userTitle = computed(() => {