@valtimo/components 13.13.0 → 13.14.0

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.
@@ -6029,8 +6029,8 @@ class CarbonListComponent {
6029
6029
  this.loadPaginationSize();
6030
6030
  }
6031
6031
  this._subscriptions.add(combineLatest([this._headerItems$, this._items$, this._skeletonRowCount$]).subscribe(([headers, items, skeletonRowCount]) => {
6032
- let rowCount = items.length > 0 ? items.length : skeletonRowCount;
6033
- if (items.length === 0 && this.pagination?.size) {
6032
+ let rowCount = items?.length > 0 ? items?.length : skeletonRowCount;
6033
+ if (items?.length === 0 && this.pagination?.size) {
6034
6034
  rowCount = this.pagination.size;
6035
6035
  }
6036
6036
  if (!this.hideToolbar) {
@@ -8442,8 +8442,11 @@ class FormioComponent {
8442
8442
  this.tagsService.reregisterTags(this.injector);
8443
8443
  }
8444
8444
  ngOnInit() {
8445
- Formio.setProjectUrl(location.origin);
8446
- Formio.authUrl = location.origin;
8445
+ if (!Formio.projectUrlSet) {
8446
+ Formio.setBaseUrl(location.origin);
8447
+ Formio.setProjectUrl(location.origin);
8448
+ Formio.authUrl = location.origin;
8449
+ }
8447
8450
  this.openRouteSubscription();
8448
8451
  this.errors$.next([]);
8449
8452
  this.setInitialToken();
@@ -8742,10 +8745,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.18", ngImpo
8742
8745
  * limitations under the License.
8743
8746
  */
8744
8747
  const getFormioAppConfig = (config) => {
8745
- const origin = window.location.origin;
8748
+ const baseUrl = UrlUtils.formatUrlTrailingSlash(`${window.location.origin}${config.valtimoApi.endpointUri}`, false);
8746
8749
  return {
8747
- appUrl: origin,
8748
- apiUrl: UrlUtils.formatUrlTrailingSlash(`${window.location.origin}${config.valtimoApi.endpointUri}`, false),
8750
+ appUrl: baseUrl,
8751
+ apiUrl: baseUrl,
8749
8752
  icons: 'fontawesome',
8750
8753
  formOnly: false,
8751
8754
  };