@sisense/sdk-ui 2.3.0 → 2.3.1

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.
@@ -8545,8 +8545,11 @@ function Z4(e, t) {
8545
8545
  function K4(e) {
8546
8546
  return e && e.replace(new RegExp("(?<!\\\\)'", "g"), "\\'");
8547
8547
  }
8548
- function J4(e) {
8549
- return e.endsWith("/") ? e : `${e}/`;
8548
+ function J4(e, t) {
8549
+ if (!e || typeof e != "string")
8550
+ return e;
8551
+ const i = new URL(e);
8552
+ return i.origin + (i.pathname.endsWith("/") ? i.pathname : i.pathname + "/") + "";
8550
8553
  }
8551
8554
  var cO = typeof globalThis != "undefined" ? globalThis : typeof window != "undefined" ? window : typeof global != "undefined" ? global : typeof self != "undefined" ? self : {};
8552
8555
  function ss(e) {
@@ -1 +1 @@
1
- "use strict";const e=require("./derive-chart-family-DeTlU_Wm.cjs");class m extends e.DimensionalElement{constructor(i,t,s,a,u,o,l,h,D,r){if(super(i,u||e.MetadataTypes.Dimension,o,h,D),this._dimensions=[],this._attributes=[],this._sort=e.Sort.None,!D&&t){const{table:d,column:g}=e.parseExpression(t);this.composeCode=e.normalizeAttributeName(d,g,"",e.DATA_MODEL_MODULE_NAME)}this._sort=l||e.Sort.None,this._expression=t,this.setDimensions(a||[]),this.setAttributes(s),r&&(this.defaultAttribute=r)}static parseType(i){switch(i){case"datetime":case e.MetadataTypes.DateDimension:return e.MetadataTypes.DateDimension;case"text":case e.MetadataTypes.TextDimension:return e.MetadataTypes.TextDimension;case"numeric":case e.MetadataTypes.NumericDimension:return e.MetadataTypes.NumericDimension}return e.MetadataTypes.TextDimension}getAttachedName(i,t){let s=i;const a=e.normalizeName(i);return(a==="id"||a==="name"||Object.getOwnPropertyDescriptor(this,a)!==void 0||this[a]!==void 0)&&(s=t),s}setDimensions(i){this._dimensions=i;for(let t=0;t<i.length;t++){const s=this.getAttachedName(i[t].name,i[t].attributes[0].expression);this[e.normalizeName(s)]=i[t],s!=i[t].name&&(i[t].name=s)}}setAttributes(i){this._attributes=i||[];for(let t=0;t<i.length;t++){const s=this.getAttachedName(i[t].name,i[t].expression);this[e.normalizeName(s)]=i[t],i[t].name!=s&&(i[t].name=s)}}get id(){return this._expression}get attributes(){return this._attributes}get dimensions(){return this._dimensions}get expression(){return this._expression}getSort(){return this._sort}sort(i){return new m(this.name,this.expression,this.attributes,this.dimensions,this.type,this.description,i,this.dataSource,this.composeCode,this.defaultAttribute)}serialize(){const i=super.serialize();return i.__serializable="DimensionalDimension",i.expression=this.expression,this.getSort()!==void 0&&(i.sort=this.getSort()),i.attributes=this._attributes.map(t=>t.serialize()),i.dimensions=this._dimensions.map(t=>t.serialize()),this.defaultAttribute&&(i.defaultAttribute=this.defaultAttribute.serialize()),i}jaql(i){if(this.defaultAttribute)return this.defaultAttribute.jaql(i);if(this.dimensions.length>0)return this.dimensions[0].jaql(i);const t={jaql:{title:this.name,dim:this.expression,datatype:e.jaqlSimpleColumnType(this.type)}};return this._sort!=e.Sort.None&&(t.jaql.sort=this._sort==e.Sort.Ascending?"asc":"desc"),i===!0?t.jaql:t}}class y extends m{constructor(i,t,s,a,u,o){super(i,t,[],[],e.MetadataTypes.DateDimension,s,a,u,o),this.defaultLevel=e.DateLevels.Years,this.Years=new e.DimensionalLevelAttribute(e.DateLevels.Years,t,e.DateLevels.Years,"yyyy",s,a,u),this.Quarters=new e.DimensionalLevelAttribute(e.DateLevels.Quarters,t,e.DateLevels.Quarters,"Q yyyy",s,a,u),this.Months=new e.DimensionalLevelAttribute(e.DateLevels.Months,t,e.DateLevels.Months,"yyyy-MM",s,a,u),this.Weeks=new e.DimensionalLevelAttribute(e.DateLevels.Weeks,t,e.DateLevels.Weeks,"ww yyyy",s,a,u),this.Days=new e.DimensionalLevelAttribute(e.DateLevels.Days,t,e.DateLevels.Days,"yyyy-MM-dd",s,a,u),this.Hours=new e.DimensionalLevelAttribute(e.DateLevels.Hours,t,e.DateLevels.Hours,"yyyy-MM-dd HH:mm",s,a,u),this.MinutesRoundTo30=new e.DimensionalLevelAttribute(e.DateLevels.MinutesRoundTo30,t,e.DateLevels.MinutesRoundTo30,"yyyy-MM-dd HH:mm",s,a,u),this.MinutesRoundTo15=new e.DimensionalLevelAttribute(e.DateLevels.MinutesRoundTo15,t,e.DateLevels.MinutesRoundTo15,"yyyy-MM-dd HH:mm",s,a,u),this.Minutes=new e.DimensionalLevelAttribute(e.DateLevels.Minutes,t,e.DateLevels.Minutes,"yyyy-MM-dd HH:mm",s,a,u),this.Seconds=new e.DimensionalLevelAttribute(e.DateLevels.Seconds,t,e.DateLevels.Seconds,"yyyy-MM-dd HH:mm:ss",s,a,u),this.AggHours=new e.DimensionalLevelAttribute(e.DateLevels.AggHours,t,e.DateLevels.AggHours,"HH:mm",s,a,u),this.AggMinutesRoundTo30=new e.DimensionalLevelAttribute(e.DateLevels.AggMinutesRoundTo30,t,e.DateLevels.AggMinutesRoundTo30,"HH:mm",s,a,u),this.AggMinutesRoundTo15=new e.DimensionalLevelAttribute(e.DateLevels.AggMinutesRoundTo15,t,e.DateLevels.AggMinutesRoundTo15,"HH:mm",s,a,u),this.AggMinutesRoundTo1=new e.DimensionalLevelAttribute(e.DateLevels.AggMinutesRoundTo1,t,e.DateLevels.AggMinutesRoundTo1,"HH:mm",s,a,u),this.setAttributes([this.Years,this.Quarters,this.Months,this.Weeks,this.Days,this.Hours,this.MinutesRoundTo30,this.MinutesRoundTo15,this.Minutes,this.Seconds,this.AggHours,this.AggMinutesRoundTo30,this.AggMinutesRoundTo15,this.AggMinutesRoundTo1])}get id(){return this.expression}setDimensions(){}setAttributes(i){this._attributes=i}getSort(){return this._sort}sort(i){return new y(this.name,this.expression,this.description,i,this.dataSource,this.composeCode)}serialize(){const i=super.serialize();return i.__serializable="DimensionalDateDimension",i}jaql(i){const t=this[this.defaultLevel].jaql();return t.jaql.title=this.name,i?t.jaql:t}}function M(n){const i=n.name||n.title,t=n.desc||n.description,s=n.expression||n.dim,a=m.parseType(n.dimtype||n.type),u=n.sort,o=n.dataSource;if(a==e.MetadataTypes.DateDimension)return new y(i,s,t,u,o);const l=Object.getOwnPropertyNames(n).map(r=>n[r]).filter(r=>e.MetadataTypes.isAttribute(r==null?void 0:r.type));if(l.length==0)if(n.attributes){let r;for(let d=0;d<n.attributes.length;d++)r=n.attributes[d],l.push(new e.DimensionalAttribute(r.name,r.expression,r.type,r.description,r.sort,r.dataSource))}else s&&l.push(new e.DimensionalAttribute(i,s,a,t,u,o));const h=Object.getOwnPropertyNames(n).map(r=>n[r]).filter(r=>e.MetadataTypes.isDimension(r==null?void 0:r.type));if(h.length==0&&n.dimensions)for(let r=0;r<n.dimensions.length;r++)h.push(M(n.dimensions[r]));const D=new m(i,s,l,h,a,t,u,o);return n.defaultAttribute&&(D.defaultAttribute=l.find(r=>r.name===n.defaultAttribute)),D}function p(n){const i=n.name||n.title,t=n.expression||n.dim,s=n.desc||n.description,a=n.sort,u=n.dataSource;return new y(i,t,s,a,u)}exports.DimensionalDateDimension=y;exports.DimensionalDimension=m;exports.createDateDimension=p;exports.createDimension=M;
1
+ "use strict";const e=require("./derive-chart-family-5O0nGmIH.cjs");class m extends e.DimensionalElement{constructor(i,t,s,a,u,o,l,h,D,r){if(super(i,u||e.MetadataTypes.Dimension,o,h,D),this._dimensions=[],this._attributes=[],this._sort=e.Sort.None,!D&&t){const{table:d,column:g}=e.parseExpression(t);this.composeCode=e.normalizeAttributeName(d,g,"",e.DATA_MODEL_MODULE_NAME)}this._sort=l||e.Sort.None,this._expression=t,this.setDimensions(a||[]),this.setAttributes(s),r&&(this.defaultAttribute=r)}static parseType(i){switch(i){case"datetime":case e.MetadataTypes.DateDimension:return e.MetadataTypes.DateDimension;case"text":case e.MetadataTypes.TextDimension:return e.MetadataTypes.TextDimension;case"numeric":case e.MetadataTypes.NumericDimension:return e.MetadataTypes.NumericDimension}return e.MetadataTypes.TextDimension}getAttachedName(i,t){let s=i;const a=e.normalizeName(i);return(a==="id"||a==="name"||Object.getOwnPropertyDescriptor(this,a)!==void 0||this[a]!==void 0)&&(s=t),s}setDimensions(i){this._dimensions=i;for(let t=0;t<i.length;t++){const s=this.getAttachedName(i[t].name,i[t].attributes[0].expression);this[e.normalizeName(s)]=i[t],s!=i[t].name&&(i[t].name=s)}}setAttributes(i){this._attributes=i||[];for(let t=0;t<i.length;t++){const s=this.getAttachedName(i[t].name,i[t].expression);this[e.normalizeName(s)]=i[t],i[t].name!=s&&(i[t].name=s)}}get id(){return this._expression}get attributes(){return this._attributes}get dimensions(){return this._dimensions}get expression(){return this._expression}getSort(){return this._sort}sort(i){return new m(this.name,this.expression,this.attributes,this.dimensions,this.type,this.description,i,this.dataSource,this.composeCode,this.defaultAttribute)}serialize(){const i=super.serialize();return i.__serializable="DimensionalDimension",i.expression=this.expression,this.getSort()!==void 0&&(i.sort=this.getSort()),i.attributes=this._attributes.map(t=>t.serialize()),i.dimensions=this._dimensions.map(t=>t.serialize()),this.defaultAttribute&&(i.defaultAttribute=this.defaultAttribute.serialize()),i}jaql(i){if(this.defaultAttribute)return this.defaultAttribute.jaql(i);if(this.dimensions.length>0)return this.dimensions[0].jaql(i);const t={jaql:{title:this.name,dim:this.expression,datatype:e.jaqlSimpleColumnType(this.type)}};return this._sort!=e.Sort.None&&(t.jaql.sort=this._sort==e.Sort.Ascending?"asc":"desc"),i===!0?t.jaql:t}}class y extends m{constructor(i,t,s,a,u,o){super(i,t,[],[],e.MetadataTypes.DateDimension,s,a,u,o),this.defaultLevel=e.DateLevels.Years,this.Years=new e.DimensionalLevelAttribute(e.DateLevels.Years,t,e.DateLevels.Years,"yyyy",s,a,u),this.Quarters=new e.DimensionalLevelAttribute(e.DateLevels.Quarters,t,e.DateLevels.Quarters,"Q yyyy",s,a,u),this.Months=new e.DimensionalLevelAttribute(e.DateLevels.Months,t,e.DateLevels.Months,"yyyy-MM",s,a,u),this.Weeks=new e.DimensionalLevelAttribute(e.DateLevels.Weeks,t,e.DateLevels.Weeks,"ww yyyy",s,a,u),this.Days=new e.DimensionalLevelAttribute(e.DateLevels.Days,t,e.DateLevels.Days,"yyyy-MM-dd",s,a,u),this.Hours=new e.DimensionalLevelAttribute(e.DateLevels.Hours,t,e.DateLevels.Hours,"yyyy-MM-dd HH:mm",s,a,u),this.MinutesRoundTo30=new e.DimensionalLevelAttribute(e.DateLevels.MinutesRoundTo30,t,e.DateLevels.MinutesRoundTo30,"yyyy-MM-dd HH:mm",s,a,u),this.MinutesRoundTo15=new e.DimensionalLevelAttribute(e.DateLevels.MinutesRoundTo15,t,e.DateLevels.MinutesRoundTo15,"yyyy-MM-dd HH:mm",s,a,u),this.Minutes=new e.DimensionalLevelAttribute(e.DateLevels.Minutes,t,e.DateLevels.Minutes,"yyyy-MM-dd HH:mm",s,a,u),this.Seconds=new e.DimensionalLevelAttribute(e.DateLevels.Seconds,t,e.DateLevels.Seconds,"yyyy-MM-dd HH:mm:ss",s,a,u),this.AggHours=new e.DimensionalLevelAttribute(e.DateLevels.AggHours,t,e.DateLevels.AggHours,"HH:mm",s,a,u),this.AggMinutesRoundTo30=new e.DimensionalLevelAttribute(e.DateLevels.AggMinutesRoundTo30,t,e.DateLevels.AggMinutesRoundTo30,"HH:mm",s,a,u),this.AggMinutesRoundTo15=new e.DimensionalLevelAttribute(e.DateLevels.AggMinutesRoundTo15,t,e.DateLevels.AggMinutesRoundTo15,"HH:mm",s,a,u),this.AggMinutesRoundTo1=new e.DimensionalLevelAttribute(e.DateLevels.AggMinutesRoundTo1,t,e.DateLevels.AggMinutesRoundTo1,"HH:mm",s,a,u),this.setAttributes([this.Years,this.Quarters,this.Months,this.Weeks,this.Days,this.Hours,this.MinutesRoundTo30,this.MinutesRoundTo15,this.Minutes,this.Seconds,this.AggHours,this.AggMinutesRoundTo30,this.AggMinutesRoundTo15,this.AggMinutesRoundTo1])}get id(){return this.expression}setDimensions(){}setAttributes(i){this._attributes=i}getSort(){return this._sort}sort(i){return new y(this.name,this.expression,this.description,i,this.dataSource,this.composeCode)}serialize(){const i=super.serialize();return i.__serializable="DimensionalDateDimension",i}jaql(i){const t=this[this.defaultLevel].jaql();return t.jaql.title=this.name,i?t.jaql:t}}function M(n){const i=n.name||n.title,t=n.desc||n.description,s=n.expression||n.dim,a=m.parseType(n.dimtype||n.type),u=n.sort,o=n.dataSource;if(a==e.MetadataTypes.DateDimension)return new y(i,s,t,u,o);const l=Object.getOwnPropertyNames(n).map(r=>n[r]).filter(r=>e.MetadataTypes.isAttribute(r==null?void 0:r.type));if(l.length==0)if(n.attributes){let r;for(let d=0;d<n.attributes.length;d++)r=n.attributes[d],l.push(new e.DimensionalAttribute(r.name,r.expression,r.type,r.description,r.sort,r.dataSource))}else s&&l.push(new e.DimensionalAttribute(i,s,a,t,u,o));const h=Object.getOwnPropertyNames(n).map(r=>n[r]).filter(r=>e.MetadataTypes.isDimension(r==null?void 0:r.type));if(h.length==0&&n.dimensions)for(let r=0;r<n.dimensions.length;r++)h.push(M(n.dimensions[r]));const D=new m(i,s,l,h,a,t,u,o);return n.defaultAttribute&&(D.defaultAttribute=l.find(r=>r.name===n.defaultAttribute)),D}function p(n){const i=n.name||n.title,t=n.expression||n.dim,s=n.desc||n.description,a=n.sort,u=n.dataSource;return new y(i,t,s,a,u)}exports.DimensionalDateDimension=y;exports.DimensionalDimension=m;exports.createDateDimension=p;exports.createDimension=M;
@@ -1,4 +1,4 @@
1
- import { dW as b, m as h, al as p, dX as T, dY as w, dZ as f, d_ as H, aq as n, ap as o, d$ as _, dJ as A } from "./derive-chart-family-BtTi3OxL.js";
1
+ import { dW as b, m as h, al as p, dX as T, dY as w, dZ as f, d_ as H, aq as n, ap as o, d$ as _, dJ as A } from "./derive-chart-family-H5uuw6lv.js";
2
2
  class c extends b {
3
3
  constructor(e, t, i, r, a, m, l, d, y, u) {
4
4
  if (super(e, a || h.Dimension, m, d, y), this._dimensions = [], this._attributes = [], this._sort = p.None, !y && t) {