@gooddata/sdk-ui-ext 11.54.0-alpha.4 → 11.54.0-alpha.6
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.
- package/NOTICE +93513 -17188
- package/esm/dataLoaders/dataLoaders.test.helpers.d.ts +4 -0
- package/esm/dataLoaders/dataLoaders.test.helpers.d.ts.map +1 -0
- package/esm/dataLoaders/dataLoaders.test.helpers.js +52 -0
- package/esm/internal/components/attributeHierarchies/attributeHierarchyDialog/{utils.fixture.d.ts → utils.test.helpers.d.ts} +1 -1
- package/esm/internal/components/attributeHierarchies/attributeHierarchyDialog/utils.test.helpers.d.ts.map +1 -0
- package/esm/internal/components/configurationControls/colors/coloredItemsList/{mock.d.ts → coloredItemsList.test.helpers.d.ts} +1 -1
- package/esm/internal/components/configurationControls/colors/coloredItemsList/coloredItemsList.test.helpers.d.ts.map +1 -0
- package/esm/internal/components/pluggableVisualizations/{heatMap/getInsightWithDrillDownAppliedMock.d.ts → areaChart/getInsightWithDrillDownAppliedMock.test.helpers.d.ts} +1 -1
- package/esm/internal/components/pluggableVisualizations/areaChart/getInsightWithDrillDownAppliedMock.test.helpers.d.ts.map +1 -0
- package/esm/internal/components/pluggableVisualizations/areaChart/getInsightWithDrillDownAppliedMock.test.helpers.js +119 -0
- package/esm/internal/components/pluggableVisualizations/baseChart/getInsightWithDrillDownAppliedMock.test.helpers.d.ts +7 -0
- package/esm/internal/components/pluggableVisualizations/baseChart/getInsightWithDrillDownAppliedMock.test.helpers.d.ts.map +1 -0
- package/esm/internal/components/pluggableVisualizations/baseChart/getInsightWithDrillDownAppliedMock.test.helpers.js +98 -0
- package/esm/internal/components/pluggableVisualizations/bulletChart/getInsightWithDrillDownAppliedMock.test.helpers.d.ts +8 -0
- package/esm/internal/components/pluggableVisualizations/bulletChart/getInsightWithDrillDownAppliedMock.test.helpers.d.ts.map +1 -0
- package/esm/internal/components/pluggableVisualizations/bulletChart/getInsightWithDrillDownAppliedMock.test.helpers.js +110 -0
- package/esm/internal/components/pluggableVisualizations/geoCommon/viewportSync.test.helpers.d.ts +45 -0
- package/esm/internal/components/pluggableVisualizations/geoCommon/viewportSync.test.helpers.d.ts.map +1 -0
- package/esm/internal/components/pluggableVisualizations/geoCommon/viewportSync.test.helpers.js +48 -0
- package/esm/internal/components/pluggableVisualizations/getInsightWithDrillDownAppliedMock.test.helpers.d.ts +13 -0
- package/esm/internal/components/pluggableVisualizations/getInsightWithDrillDownAppliedMock.test.helpers.d.ts.map +1 -0
- package/esm/internal/components/pluggableVisualizations/getInsightWithDrillDownAppliedMock.test.helpers.js +132 -0
- package/esm/internal/components/pluggableVisualizations/heatMap/getInsightWithDrillDownAppliedMock.test.helpers.d.ts +8 -0
- package/esm/internal/components/pluggableVisualizations/heatMap/getInsightWithDrillDownAppliedMock.test.helpers.d.ts.map +1 -0
- package/esm/internal/components/pluggableVisualizations/mekko/MekkoDescriptor.js +1 -1
- package/esm/internal/components/pluggableVisualizations/pivotTable/{getInsightWithDrillDownAppliedMock.d.ts → getInsightWithDrillDownAppliedMock.test.helpers.d.ts} +1 -1
- package/esm/internal/components/pluggableVisualizations/pivotTable/getInsightWithDrillDownAppliedMock.test.helpers.d.ts.map +1 -0
- package/esm/internal/components/pluggableVisualizations/pivotTable/{mockReferencePoint.d.ts → mockReferencePoint.test.helpers.d.ts} +1 -1
- package/esm/internal/components/pluggableVisualizations/pivotTable/mockReferencePoint.test.helpers.d.ts.map +1 -0
- package/esm/internal/components/pluggableVisualizations/pivotTable/{sortMocks.d.ts → sortMocks.test.helpers.d.ts} +1 -1
- package/esm/internal/components/pluggableVisualizations/pivotTable/sortMocks.test.helpers.d.ts.map +1 -0
- package/esm/internal/components/pluggableVisualizations/pivotTable/{widthItemsMock.d.ts → widthItemsMock.test.helpers.d.ts} +1 -1
- package/esm/internal/components/pluggableVisualizations/pivotTable/widthItemsMock.test.helpers.d.ts.map +1 -0
- package/esm/internal/components/pluggableVisualizations/pluggableVisualizations.test.helpers.d.ts +16 -0
- package/esm/internal/components/pluggableVisualizations/pluggableVisualizations.test.helpers.d.ts.map +1 -0
- package/esm/internal/components/pluggableVisualizations/pluggableVisualizations.test.helpers.js +39 -0
- package/esm/internal/components/pluggableVisualizations/reverseAndTrimIntersectionMock.test.helpers.d.ts +10 -0
- package/esm/internal/components/pluggableVisualizations/reverseAndTrimIntersectionMock.test.helpers.d.ts.map +1 -0
- package/esm/internal/components/pluggableVisualizations/reverseAndTrimIntersectionMock.test.helpers.js +94 -0
- package/esm/internal/components/visConstruct.test.helpers.d.ts +17 -0
- package/esm/internal/components/visConstruct.test.helpers.d.ts.map +1 -0
- package/esm/internal/components/visConstruct.test.helpers.js +18 -0
- package/esm/internal/constants/bucket.d.ts +1 -0
- package/esm/internal/constants/bucket.d.ts.map +1 -1
- package/esm/internal/constants/bucket.js +2 -1
- package/esm/internal/constants/supportedProperties.d.ts.map +1 -1
- package/esm/internal/constants/supportedProperties.js +1 -0
- package/esm/internal/constants/uiConfig.js +8 -8
- package/esm/internal/index.d.ts +1 -1
- package/esm/internal/index.d.ts.map +1 -1
- package/esm/internal/index.js +1 -1
- package/esm/internal/interfaces/typeGuards.test.helpers.d.ts +6 -0
- package/esm/internal/interfaces/typeGuards.test.helpers.d.ts.map +1 -0
- package/esm/internal/interfaces/typeGuards.test.helpers.js +21 -0
- package/esm/internal/testDataProvider.d.ts +16 -0
- package/esm/internal/testDataProvider.d.ts.map +1 -0
- package/esm/internal/testDataProvider.js +36 -0
- package/esm/internal/testIntlProvider.d.ts.map +1 -0
- package/esm/internal/{tests/testIntlProvider.js → testIntlProvider.js} +2 -2
- package/esm/internal/translations/pt-BR.localization-bundle.js +2 -2
- package/esm/internal/translations/pt-PT.localization-bundle.js +2 -2
- package/esm/internal/utils/uiConfigMocks.test.helpers.d.ts +17 -0
- package/esm/internal/utils/uiConfigMocks.test.helpers.d.ts.map +1 -0
- package/esm/internal/utils/uiConfigMocks.test.helpers.js +125 -0
- package/package.json +22 -22
- package/esm/internal/components/attributeHierarchies/attributeHierarchyDialog/utils.fixture.d.ts.map +0 -1
- package/esm/internal/components/configurationControls/colors/coloredItemsList/mock.d.ts.map +0 -1
- package/esm/internal/components/pluggableVisualizations/heatMap/getInsightWithDrillDownAppliedMock.d.ts.map +0 -1
- package/esm/internal/components/pluggableVisualizations/pivotTable/getInsightWithDrillDownAppliedMock.d.ts.map +0 -1
- package/esm/internal/components/pluggableVisualizations/pivotTable/mockReferencePoint.d.ts.map +0 -1
- package/esm/internal/components/pluggableVisualizations/pivotTable/sortMocks.d.ts.map +0 -1
- package/esm/internal/components/pluggableVisualizations/pivotTable/widthItemsMock.d.ts.map +0 -1
- package/esm/internal/tests/testIntlProvider.d.ts.map +0 -1
- /package/esm/internal/components/attributeHierarchies/attributeHierarchyDialog/{utils.fixture.js → utils.test.helpers.js} +0 -0
- /package/esm/internal/components/configurationControls/colors/coloredItemsList/{mock.js → coloredItemsList.test.helpers.js} +0 -0
- /package/esm/internal/components/pluggableVisualizations/heatMap/{getInsightWithDrillDownAppliedMock.js → getInsightWithDrillDownAppliedMock.test.helpers.js} +0 -0
- /package/esm/internal/components/pluggableVisualizations/pivotTable/{getInsightWithDrillDownAppliedMock.js → getInsightWithDrillDownAppliedMock.test.helpers.js} +0 -0
- /package/esm/internal/components/pluggableVisualizations/pivotTable/{mockReferencePoint.js → mockReferencePoint.test.helpers.js} +0 -0
- /package/esm/internal/components/pluggableVisualizations/pivotTable/{sortMocks.js → sortMocks.test.helpers.js} +0 -0
- /package/esm/internal/components/pluggableVisualizations/pivotTable/{widthItemsMock.js → widthItemsMock.test.helpers.js} +0 -0
- /package/esm/internal/{tests/testIntlProvider.d.ts → testIntlProvider.d.ts} +0 -0
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
// (C) 2020-2026 GoodData Corporation
|
|
2
|
+
import { ReferenceData, ReferenceMd } from "@gooddata/reference-workspace";
|
|
3
|
+
import { modifyAttribute, newAttribute, newBucket, newInsightDefinition, newNegativeAttributeFilter, newPositiveAttributeFilter, uriRef, } from "@gooddata/sdk-model";
|
|
4
|
+
const { Department, Region, Won } = ReferenceMd;
|
|
5
|
+
export const targetUri = "target-uri";
|
|
6
|
+
export const insightDefinitionWithStackBy = newInsightDefinition("visualizationClass-url", (b) => {
|
|
7
|
+
return b
|
|
8
|
+
.title("sourceInsight")
|
|
9
|
+
.buckets([
|
|
10
|
+
newBucket("measure", Won),
|
|
11
|
+
newBucket("stack", Region.Default),
|
|
12
|
+
newBucket("view", Department.Default),
|
|
13
|
+
])
|
|
14
|
+
.filters([newNegativeAttributeFilter(Department.Default, [])]);
|
|
15
|
+
});
|
|
16
|
+
export const insightDefinition = newInsightDefinition("visualizationClass-url", (b) => {
|
|
17
|
+
return b
|
|
18
|
+
.title("sourceInsight")
|
|
19
|
+
.buckets([newBucket("measure", Won), newBucket("view", Department.Default, Region.Default)])
|
|
20
|
+
.filters([newNegativeAttributeFilter(Department.Default, [])]);
|
|
21
|
+
});
|
|
22
|
+
const departmentUri = "/gdc/md/lmnivlu3sowt63jvr2mo1wlse5fyv203/obj/1027";
|
|
23
|
+
const regionUri = "/gdc/md/lmnivlu3sowt63jvr2mo1wlse5fyv203/obj/1024";
|
|
24
|
+
const westCoastUri = ReferenceData.Region.WestCoast.uri;
|
|
25
|
+
const directSalesUri = ReferenceData.Department.DirectSales.uri;
|
|
26
|
+
export const expectedInsightDefinitionWithStackByDrillToDepartment = newInsightDefinition("visualizationClass-url", (b) => {
|
|
27
|
+
return b
|
|
28
|
+
.title("sourceInsight")
|
|
29
|
+
.buckets([
|
|
30
|
+
newBucket("measure", Won),
|
|
31
|
+
newBucket("stack", Region.Default),
|
|
32
|
+
newBucket("view", newAttribute(uriRef(targetUri), (b) => b.localId(Department.Default.attribute.localIdentifier))),
|
|
33
|
+
])
|
|
34
|
+
.filters([
|
|
35
|
+
newNegativeAttributeFilter(Department.Default, []),
|
|
36
|
+
newPositiveAttributeFilter(modifyAttribute(Department.Default, (a) => a.displayForm(uriRef(departmentUri))), { uris: [directSalesUri] }),
|
|
37
|
+
]);
|
|
38
|
+
});
|
|
39
|
+
export const expectedInsightDefinitionWithStackByDrillToRegion = newInsightDefinition("visualizationClass-url", (b) => {
|
|
40
|
+
return b
|
|
41
|
+
.title("sourceInsight")
|
|
42
|
+
.buckets([
|
|
43
|
+
newBucket("measure", Won),
|
|
44
|
+
newBucket("stack", newAttribute(uriRef(targetUri), (b) => b.localId(Region.Default.attribute.localIdentifier))),
|
|
45
|
+
newBucket("view", Department.Default),
|
|
46
|
+
])
|
|
47
|
+
.filters([
|
|
48
|
+
newNegativeAttributeFilter(Department.Default, []),
|
|
49
|
+
newPositiveAttributeFilter(modifyAttribute(Region.Default, (a) => a.displayForm(uriRef(regionUri))), { uris: [westCoastUri] }),
|
|
50
|
+
newPositiveAttributeFilter(modifyAttribute(Department.Default, (a) => a.displayForm(uriRef(departmentUri))), { uris: [directSalesUri] }),
|
|
51
|
+
]);
|
|
52
|
+
});
|
|
53
|
+
export const expectedInsightDefinitionDrillToRegion = newInsightDefinition("visualizationClass-url", (b) => {
|
|
54
|
+
return b
|
|
55
|
+
.title("sourceInsight")
|
|
56
|
+
.buckets([
|
|
57
|
+
newBucket("measure", Won),
|
|
58
|
+
newBucket("view", newAttribute(uriRef(targetUri), (b) => b.localId(Region.Default.attribute.localIdentifier))),
|
|
59
|
+
])
|
|
60
|
+
.filters([
|
|
61
|
+
newNegativeAttributeFilter(Department.Default, []),
|
|
62
|
+
newPositiveAttributeFilter(modifyAttribute(Region.Default, (a) => a.displayForm(uriRef(regionUri))), { uris: [westCoastUri] }),
|
|
63
|
+
]);
|
|
64
|
+
});
|
|
65
|
+
export const measureHeader = {
|
|
66
|
+
measureHeaderItem: {
|
|
67
|
+
name: Won.measure.title,
|
|
68
|
+
format: "#,##0.00",
|
|
69
|
+
localIdentifier: Won.measure.localIdentifier,
|
|
70
|
+
uri: "/gdc/md/lmnivlu3sowt63jvr2mo1wlse5fyv203/obj/9203",
|
|
71
|
+
identifier: undefined,
|
|
72
|
+
},
|
|
73
|
+
};
|
|
74
|
+
export const westCoastHeader = {
|
|
75
|
+
attributeHeaderItem: {
|
|
76
|
+
name: "West Coast",
|
|
77
|
+
uri: westCoastUri,
|
|
78
|
+
},
|
|
79
|
+
attributeHeader: {
|
|
80
|
+
name: Region.Default.attribute.alias,
|
|
81
|
+
localIdentifier: Region.Default.attribute.localIdentifier,
|
|
82
|
+
uri: regionUri,
|
|
83
|
+
ref: {
|
|
84
|
+
uri: regionUri,
|
|
85
|
+
},
|
|
86
|
+
identifier: "mock-identifier",
|
|
87
|
+
formOf: {
|
|
88
|
+
identifier: "mock-attribute",
|
|
89
|
+
name: "Mock Attribute",
|
|
90
|
+
ref: { uri: regionUri },
|
|
91
|
+
uri: regionUri,
|
|
92
|
+
},
|
|
93
|
+
primaryLabel: {
|
|
94
|
+
uri: regionUri,
|
|
95
|
+
},
|
|
96
|
+
},
|
|
97
|
+
};
|
|
98
|
+
export const directSalesHeader = {
|
|
99
|
+
attributeHeaderItem: {
|
|
100
|
+
name: "Direct Sales",
|
|
101
|
+
uri: directSalesUri,
|
|
102
|
+
},
|
|
103
|
+
attributeHeader: {
|
|
104
|
+
name: Department.Default.attribute.alias,
|
|
105
|
+
localIdentifier: Department.Default.attribute.localIdentifier,
|
|
106
|
+
uri: departmentUri,
|
|
107
|
+
ref: {
|
|
108
|
+
uri: departmentUri,
|
|
109
|
+
},
|
|
110
|
+
identifier: "mock-identifier",
|
|
111
|
+
formOf: {
|
|
112
|
+
identifier: "mock-attribute",
|
|
113
|
+
name: "Mock Attribute",
|
|
114
|
+
ref: { uri: departmentUri },
|
|
115
|
+
uri: departmentUri,
|
|
116
|
+
},
|
|
117
|
+
primaryLabel: {
|
|
118
|
+
uri: departmentUri,
|
|
119
|
+
},
|
|
120
|
+
},
|
|
121
|
+
};
|
|
122
|
+
export const intersection = [
|
|
123
|
+
{
|
|
124
|
+
header: measureHeader,
|
|
125
|
+
},
|
|
126
|
+
{
|
|
127
|
+
header: directSalesHeader,
|
|
128
|
+
},
|
|
129
|
+
{
|
|
130
|
+
header: westCoastHeader,
|
|
131
|
+
},
|
|
132
|
+
];
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { type IInsightDefinition } from "@gooddata/sdk-model";
|
|
2
|
+
import { type IDrillEventIntersectionElement } from "@gooddata/sdk-ui";
|
|
3
|
+
export declare const targetUri = "target-uri";
|
|
4
|
+
export declare const intersection: IDrillEventIntersectionElement[];
|
|
5
|
+
export declare const sourceInsightDef: IInsightDefinition;
|
|
6
|
+
export declare const expectedInsightDefRegion: IInsightDefinition;
|
|
7
|
+
export declare const expectedInsightDefDepartment: IInsightDefinition;
|
|
8
|
+
//# sourceMappingURL=getInsightWithDrillDownAppliedMock.test.helpers.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"getInsightWithDrillDownAppliedMock.test.helpers.d.ts","sourceRoot":"","sources":["../../../../../src/internal/components/pluggableVisualizations/heatMap/getInsightWithDrillDownAppliedMock.test.helpers.ts"],"names":[],"mappings":"AAGA,OAAO,EACH,KAAK,kBAAkB,EAO1B,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAAE,KAAK,8BAA8B,EAAE,MAAM,kBAAkB,CAAC;AAQvE,eAAO,MAAM,SAAS,eAAe,CAAC;AAEtC,eAAO,MAAM,YAAY,EAAE,8BAA8B,EAgExD,CAAC;AAEF,eAAO,MAAM,gBAAgB,EAAE,kBAS7B,CAAC;AAUH,eAAO,MAAM,wBAAwB,EAAE,kBAiBtC,CAAC;AAEF,eAAO,MAAM,4BAA4B,EAAE,kBAiB1C,CAAC"}
|
|
@@ -10,4 +10,4 @@ export declare const getInsightWithDrillDownApplied: {
|
|
|
10
10
|
expectedInsightWithTotals: IInsight;
|
|
11
11
|
intersection: IDrillEventIntersectionElement[];
|
|
12
12
|
};
|
|
13
|
-
//# sourceMappingURL=getInsightWithDrillDownAppliedMock.d.ts.map
|
|
13
|
+
//# sourceMappingURL=getInsightWithDrillDownAppliedMock.test.helpers.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"getInsightWithDrillDownAppliedMock.test.helpers.d.ts","sourceRoot":"","sources":["../../../../../src/internal/components/pluggableVisualizations/pivotTable/getInsightWithDrillDownAppliedMock.test.helpers.ts"],"names":[],"mappings":"AAGA,OAAO,EAEH,KAAK,QAAQ,EAchB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAAE,KAAK,8BAA8B,EAAwC,MAAM,kBAAkB,CAAC;AAG7G,OAAO,EACH,KAAK,oBAAoB,EACzB,KAAK,wBAAwB,EAChC,MAAM,sCAAsC,CAAC;AA0Q9C,eAAO,MAAM,8BAA8B;;;;;;;;CAQ1C,CAAC"}
|
|
@@ -2,4 +2,4 @@ import { type ISortItem } from "@gooddata/sdk-model";
|
|
|
2
2
|
import { type ColumnWidthItem } from "@gooddata/sdk-ui-pivot";
|
|
3
3
|
import { type IBucketItem, type IExtendedReferencePoint, type IFiltersBucketItem } from "../../../interfaces/Visualization.js";
|
|
4
4
|
export declare const getMockReferencePoint: (measures?: IBucketItem[], rows?: IBucketItem[], columns?: IBucketItem[], filterItems?: IFiltersBucketItem[], sortItems?: ISortItem[], measuresIsShowInPercentEnabled?: boolean, columnWidths?: ColumnWidthItem[], multipleDatesEnabled?: boolean) => IExtendedReferencePoint;
|
|
5
|
-
//# sourceMappingURL=mockReferencePoint.d.ts.map
|
|
5
|
+
//# sourceMappingURL=mockReferencePoint.test.helpers.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mockReferencePoint.test.helpers.d.ts","sourceRoot":"","sources":["../../../../../src/internal/components/pluggableVisualizations/pivotTable/mockReferencePoint.test.helpers.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,qBAAqB,CAAC;AACrD,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,wBAAwB,CAAC;AAE9D,OAAO,EACH,KAAK,WAAW,EAChB,KAAK,uBAAuB,EAC5B,KAAK,kBAAkB,EAC1B,MAAM,sCAAsC,CAAC;AAE9C,eAAO,MAAM,qBAAqB,+QAmGhC,CAAC"}
|
|
@@ -6,4 +6,4 @@ export declare const invalidMeasureSortInvalidMeasure: IMeasureSortItem;
|
|
|
6
6
|
export declare const invalidMeasureSortInvalidAttribute: IMeasureSortItem;
|
|
7
7
|
export declare const invalidMeasureSortTooManyLocators: IMeasureSortItem;
|
|
8
8
|
export declare const invalidMeasureSortLocatorsTooShort: IMeasureSortItem;
|
|
9
|
-
//# sourceMappingURL=sortMocks.d.ts.map
|
|
9
|
+
//# sourceMappingURL=sortMocks.test.helpers.d.ts.map
|
package/esm/internal/components/pluggableVisualizations/pivotTable/sortMocks.test.helpers.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sortMocks.test.helpers.d.ts","sourceRoot":"","sources":["../../../../../src/internal/components/pluggableVisualizations/pivotTable/sortMocks.test.helpers.ts"],"names":[],"mappings":"AAGA,OAAO,EACH,KAAK,kBAAkB,EACvB,KAAK,gBAAgB,EAIxB,MAAM,qBAAqB,CAAC;AAE7B,eAAO,MAAM,gBAAgB,EAAE,gBAE7B,CAAC;AACH,eAAO,MAAM,kBAAkB,EAAE,kBAAmD,CAAC;AACrF,eAAO,MAAM,oBAAoB,EAAE,kBAAwD,CAAC;AAE5F,eAAO,MAAM,gCAAgC,EAAE,gBAE7C,CAAC;AAEH,eAAO,MAAM,kCAAkC,EAAE,gBAE/C,CAAC;AAEH,eAAO,MAAM,iCAAiC,EAAE,gBAG9C,CAAC;AAEH,eAAO,MAAM,kCAAkC,EAAE,gBAA8C,CAAC"}
|
|
@@ -13,4 +13,4 @@ export declare const validSliceMeasureColumnWidthItem: ISliceMeasureColumnWidthI
|
|
|
13
13
|
export declare const invalidSliceMeasureColumnWidthItem: ISliceMeasureColumnWidthItem;
|
|
14
14
|
export declare const validMixedValuesColumnWidthItem: IMixedValuesColumnWidthItem;
|
|
15
15
|
export declare const invalidMixedValueColumnWidthItem: IMixedValuesColumnWidthItem;
|
|
16
|
-
//# sourceMappingURL=widthItemsMock.d.ts.map
|
|
16
|
+
//# sourceMappingURL=widthItemsMock.test.helpers.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"widthItemsMock.test.helpers.d.ts","sourceRoot":"","sources":["../../../../../src/internal/components/pluggableVisualizations/pivotTable/widthItemsMock.test.helpers.ts"],"names":[],"mappings":"AAEA,OAAO,EACH,KAAK,0BAA0B,EAC/B,KAAK,yBAAyB,EAC9B,KAAK,uBAAuB,EAC5B,KAAK,2BAA2B,EAChC,KAAK,4BAA4B,EACjC,KAAK,2BAA2B,EACnC,MAAM,wBAAwB,CAAC;AAEhC,eAAO,MAAM,2BAA2B,EAAE,uBAiBzC,CAAC;AAEF,eAAO,MAAM,8BAA8B,EAAE,0BAI5C,CAAC;AAEF,eAAO,MAAM,+BAA+B,EAAE,2BAS7C,CAAC;AAEF,eAAO,MAAM,6BAA6B,EAAE,yBAK3C,CAAC;AAEF,eAAO,MAAM,+BAA+B,EAAE,yBAK7C,CAAC;AAEF,eAAO,MAAM,6BAA6B,EAAE,uBAiB3C,CAAC;AAEF,eAAO,MAAM,6CAA6C,EAAE,uBAiB3D,CAAC;AAEF,eAAO,MAAM,4CAA4C,EAAE,uBAuB1D,CAAC;AAEF,eAAO,MAAM,6CAA6C,EAAE,uBAW3D,CAAC;AAEF,eAAO,MAAM,iCAAiC,EAAE,2BAS/C,CAAC;AAEF,eAAO,MAAM,gCAAgC,EAAE,4BAW9C,CAAC;AAEF,eAAO,MAAM,kCAAkC,EAAE,4BAgBhD,CAAC;AAEF,eAAO,MAAM,+BAA+B,EAAE,2BAW7C,CAAC;AAEF,eAAO,MAAM,gCAAgC,EAAE,2BAgB9C,CAAC"}
|
package/esm/internal/components/pluggableVisualizations/pluggableVisualizations.test.helpers.d.ts
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { type ReactElement } from "react";
|
|
2
|
+
import { type Mock } from "vitest";
|
|
3
|
+
import { type IAttribute, type IInsight, type IInsightDefinition } from "@gooddata/sdk-model";
|
|
4
|
+
import { type IDrillEvent, type IDrillEventIntersectionElement, type VisType } from "@gooddata/sdk-ui";
|
|
5
|
+
import { type IDrillDownDefinition } from "../../interfaces/Visualization.js";
|
|
6
|
+
export declare function createDrillDefinition(fromAttribute: IAttribute, targetUri: string): IDrillDownDefinition;
|
|
7
|
+
export declare function insightDefinitionToInsight(insightDefinition: IInsightDefinition, uri: string, identifier: string): IInsight;
|
|
8
|
+
export declare function createDrillEvent(type: VisType, intersection: IDrillEventIntersectionElement[]): IDrillEvent;
|
|
9
|
+
/**
|
|
10
|
+
* Find the last call to a render function in the mock calls that matches given mounting point
|
|
11
|
+
* This is useful when need to separate between `renderVisualization` and `renderConfigurationPanel`
|
|
12
|
+
* Using second parameter - mounting point - as a differentiator
|
|
13
|
+
* @returns a React element passed to render function
|
|
14
|
+
*/
|
|
15
|
+
export declare function getLastRenderEl<T = any>(func: Mock, element: HTMLElement): ReactElement<T> | undefined;
|
|
16
|
+
//# sourceMappingURL=pluggableVisualizations.test.helpers.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pluggableVisualizations.test.helpers.d.ts","sourceRoot":"","sources":["../../../../src/internal/components/pluggableVisualizations/pluggableVisualizations.test.helpers.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,YAAY,EAAE,MAAM,OAAO,CAAC;AAE1C,OAAO,EAAE,KAAK,IAAI,EAAE,MAAM,QAAQ,CAAC;AAGnC,OAAO,EACH,KAAK,UAAU,EACf,KAAK,QAAQ,EACb,KAAK,kBAAkB,EAG1B,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EACH,KAAK,WAAW,EAChB,KAAK,8BAA8B,EAEnC,KAAK,OAAO,EACf,MAAM,kBAAkB,CAAC;AAE1B,OAAO,EAAE,KAAK,oBAAoB,EAAE,MAAM,mCAAmC,CAAC;AAE9E,wBAAgB,qBAAqB,CAAC,aAAa,EAAE,UAAU,EAAE,SAAS,EAAE,MAAM,GAAG,oBAAoB,CAMxG;AAED,wBAAgB,0BAA0B,CACtC,iBAAiB,EAAE,kBAAkB,EACrC,GAAG,EAAE,MAAM,EACX,UAAU,EAAE,MAAM,GACnB,QAAQ,CAUV;AAED,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,OAAO,EAAE,YAAY,EAAE,8BAA8B,EAAE,GAAG,WAAW,CAS3G;AAED;;;;;GAKG;AACH,wBAAgB,eAAe,CAAC,CAAC,GAAG,GAAG,EAAE,IAAI,EAAE,IAAI,EAAE,OAAO,EAAE,WAAW,GAAG,YAAY,CAAC,CAAC,CAAC,GAAG,SAAS,CAEtG"}
|
package/esm/internal/components/pluggableVisualizations/pluggableVisualizations.test.helpers.js
ADDED
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
// (C) 2020-2026 GoodData Corporation
|
|
2
|
+
import { localIdRef, uriRef, } from "@gooddata/sdk-model";
|
|
3
|
+
export function createDrillDefinition(fromAttribute, targetUri) {
|
|
4
|
+
return {
|
|
5
|
+
type: "drillDown",
|
|
6
|
+
origin: localIdRef(fromAttribute.attribute.localIdentifier),
|
|
7
|
+
target: uriRef(targetUri),
|
|
8
|
+
};
|
|
9
|
+
}
|
|
10
|
+
export function insightDefinitionToInsight(insightDefinition, uri, identifier) {
|
|
11
|
+
return {
|
|
12
|
+
...insightDefinition,
|
|
13
|
+
insight: {
|
|
14
|
+
...insightDefinition.insight,
|
|
15
|
+
identifier,
|
|
16
|
+
uri,
|
|
17
|
+
ref: uriRef(uri),
|
|
18
|
+
},
|
|
19
|
+
};
|
|
20
|
+
}
|
|
21
|
+
export function createDrillEvent(type, intersection) {
|
|
22
|
+
return {
|
|
23
|
+
dataView: null,
|
|
24
|
+
drillContext: {
|
|
25
|
+
type,
|
|
26
|
+
intersection,
|
|
27
|
+
element: null,
|
|
28
|
+
},
|
|
29
|
+
};
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* Find the last call to a render function in the mock calls that matches given mounting point
|
|
33
|
+
* This is useful when need to separate between `renderVisualization` and `renderConfigurationPanel`
|
|
34
|
+
* Using second parameter - mounting point - as a differentiator
|
|
35
|
+
* @returns a React element passed to render function
|
|
36
|
+
*/
|
|
37
|
+
export function getLastRenderEl(func, element) {
|
|
38
|
+
return [...func.mock.calls].reverse().find((call) => call[1] === element)?.[0];
|
|
39
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { type IDrillEventIntersectionElement } from "@gooddata/sdk-ui";
|
|
2
|
+
import { type IDrillDownDefinition } from "../../interfaces/Visualization.js";
|
|
3
|
+
export declare const reverseAndTrimIntersectionMock: {
|
|
4
|
+
drillConfigRegion: IDrillDownDefinition;
|
|
5
|
+
intersectionWithOuterDepartment: IDrillEventIntersectionElement[];
|
|
6
|
+
intersectionWithOuterRegion: IDrillEventIntersectionElement[];
|
|
7
|
+
intersectionWithOuterDepartmentResult: IDrillEventIntersectionElement[];
|
|
8
|
+
intersectionWithOuterRegionResult: IDrillEventIntersectionElement[];
|
|
9
|
+
};
|
|
10
|
+
//# sourceMappingURL=reverseAndTrimIntersectionMock.test.helpers.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"reverseAndTrimIntersectionMock.test.helpers.d.ts","sourceRoot":"","sources":["../../../../src/internal/components/pluggableVisualizations/reverseAndTrimIntersectionMock.test.helpers.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,8BAA8B,EAAE,MAAM,kBAAkB,CAAC;AAEvE,OAAO,EAAE,KAAK,oBAAoB,EAAE,MAAM,mCAAmC,CAAC;AA+F9E,eAAO,MAAM,8BAA8B;;;;;;CAM1C,CAAC"}
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
// (C) 2020-2026 GoodData Corporation
|
|
2
|
+
import { ReferenceData, ReferenceMd } from "@gooddata/reference-workspace";
|
|
3
|
+
import { localIdRef } from "@gooddata/sdk-model";
|
|
4
|
+
const { Department, Region, Won } = ReferenceMd;
|
|
5
|
+
const drillConfigRegion = {
|
|
6
|
+
type: "drillDown",
|
|
7
|
+
origin: localIdRef(Region.Default.attribute.localIdentifier),
|
|
8
|
+
target: Department.Default.attribute.displayForm,
|
|
9
|
+
};
|
|
10
|
+
const regionUri = "/gdc/md/lmnivlu3sowt63jvr2mo1wlse5fyv203/obj/1024";
|
|
11
|
+
const departmentUri = "/gdc/md/lmnivlu3sowt63jvr2mo1wlse5fyv203/obj/1027";
|
|
12
|
+
const westCoastUri = ReferenceData.Region.WestCoast.uri;
|
|
13
|
+
const directSalesUri = ReferenceData.Department.DirectSales.uri;
|
|
14
|
+
const directSalesHeader = {
|
|
15
|
+
header: {
|
|
16
|
+
attributeHeaderItem: {
|
|
17
|
+
name: "Direct Sales",
|
|
18
|
+
uri: directSalesUri,
|
|
19
|
+
},
|
|
20
|
+
attributeHeader: {
|
|
21
|
+
name: Department.Default.attribute.alias,
|
|
22
|
+
localIdentifier: Department.Default.attribute.localIdentifier,
|
|
23
|
+
uri: departmentUri,
|
|
24
|
+
ref: {
|
|
25
|
+
uri: departmentUri,
|
|
26
|
+
},
|
|
27
|
+
identifier: "mock-identifier",
|
|
28
|
+
formOf: {
|
|
29
|
+
identifier: "mock-attribute",
|
|
30
|
+
name: "Mock Attribute",
|
|
31
|
+
ref: { uri: departmentUri },
|
|
32
|
+
uri: departmentUri,
|
|
33
|
+
},
|
|
34
|
+
primaryLabel: { uri: departmentUri },
|
|
35
|
+
},
|
|
36
|
+
},
|
|
37
|
+
};
|
|
38
|
+
const westCoastHeader = {
|
|
39
|
+
header: {
|
|
40
|
+
attributeHeaderItem: {
|
|
41
|
+
name: "West Coast",
|
|
42
|
+
uri: westCoastUri,
|
|
43
|
+
},
|
|
44
|
+
attributeHeader: {
|
|
45
|
+
name: Region.Default.attribute.alias,
|
|
46
|
+
localIdentifier: Region.Default.attribute.localIdentifier,
|
|
47
|
+
uri: regionUri,
|
|
48
|
+
ref: {
|
|
49
|
+
uri: regionUri,
|
|
50
|
+
},
|
|
51
|
+
identifier: "mock-identifier",
|
|
52
|
+
formOf: {
|
|
53
|
+
identifier: "mock-attribute",
|
|
54
|
+
name: "Mock Attribute",
|
|
55
|
+
ref: { uri: regionUri },
|
|
56
|
+
uri: regionUri,
|
|
57
|
+
},
|
|
58
|
+
primaryLabel: { uri: regionUri },
|
|
59
|
+
},
|
|
60
|
+
},
|
|
61
|
+
};
|
|
62
|
+
const measureHeader = {
|
|
63
|
+
header: {
|
|
64
|
+
measureHeaderItem: {
|
|
65
|
+
name: Won.measure.title,
|
|
66
|
+
format: "#,##0.00",
|
|
67
|
+
localIdentifier: Won.measure.localIdentifier,
|
|
68
|
+
uri: "/gdc/md/lmnivlu3sowt63jvr2mo1wlse5fyv203/obj/9203",
|
|
69
|
+
identifier: undefined,
|
|
70
|
+
},
|
|
71
|
+
},
|
|
72
|
+
};
|
|
73
|
+
const intersectionWithOuterDepartment = [
|
|
74
|
+
directSalesHeader,
|
|
75
|
+
westCoastHeader,
|
|
76
|
+
measureHeader,
|
|
77
|
+
];
|
|
78
|
+
const intersectionWithOuterRegion = [
|
|
79
|
+
westCoastHeader,
|
|
80
|
+
directSalesHeader,
|
|
81
|
+
measureHeader,
|
|
82
|
+
];
|
|
83
|
+
const intersectionWithOuterDepartmentResult = [
|
|
84
|
+
westCoastHeader,
|
|
85
|
+
directSalesHeader,
|
|
86
|
+
];
|
|
87
|
+
const intersectionWithOuterRegionResult = [westCoastHeader];
|
|
88
|
+
export const reverseAndTrimIntersectionMock = {
|
|
89
|
+
drillConfigRegion,
|
|
90
|
+
intersectionWithOuterDepartment,
|
|
91
|
+
intersectionWithOuterRegion,
|
|
92
|
+
intersectionWithOuterDepartmentResult,
|
|
93
|
+
intersectionWithOuterRegionResult,
|
|
94
|
+
};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
export declare const DummyVisConstruct: {
|
|
2
|
+
projectId: string;
|
|
3
|
+
backend: import("@gooddata/sdk-backend-spi").IAnalyticalBackend;
|
|
4
|
+
element: () => null;
|
|
5
|
+
configPanelElement: () => null;
|
|
6
|
+
callbacks: {
|
|
7
|
+
onError: () => void;
|
|
8
|
+
afterRender: () => void;
|
|
9
|
+
onDrill: () => void;
|
|
10
|
+
onExportReady: () => void;
|
|
11
|
+
onLoadingChanged: () => void;
|
|
12
|
+
pushData: () => void;
|
|
13
|
+
};
|
|
14
|
+
renderFun: () => void;
|
|
15
|
+
visualizationProperties: {};
|
|
16
|
+
};
|
|
17
|
+
//# sourceMappingURL=visConstruct.test.helpers.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"visConstruct.test.helpers.d.ts","sourceRoot":"","sources":["../../../src/internal/components/visConstruct.test.helpers.ts"],"names":[],"mappings":"AAIA,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;CAe7B,CAAC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
// (C) 2019-2026 GoodData Corporation
|
|
2
|
+
import { dummyBackend } from "@gooddata/sdk-backend-mockingbird";
|
|
3
|
+
export const DummyVisConstruct = {
|
|
4
|
+
projectId: "testWorkspace",
|
|
5
|
+
backend: dummyBackend(),
|
|
6
|
+
element: () => null,
|
|
7
|
+
configPanelElement: () => null,
|
|
8
|
+
callbacks: {
|
|
9
|
+
onError: () => { },
|
|
10
|
+
afterRender: () => { },
|
|
11
|
+
onDrill: () => { },
|
|
12
|
+
onExportReady: () => { },
|
|
13
|
+
onLoadingChanged: () => { },
|
|
14
|
+
pushData: () => { },
|
|
15
|
+
},
|
|
16
|
+
renderFun: () => { },
|
|
17
|
+
visualizationProperties: {},
|
|
18
|
+
};
|
|
@@ -14,5 +14,6 @@ export declare const METRIC = "metric";
|
|
|
14
14
|
export declare const FACT = "fact";
|
|
15
15
|
export declare const DATE = "date";
|
|
16
16
|
export declare const ATTRIBUTE = "attribute";
|
|
17
|
+
export declare const COMPUTED_ATTRIBUTE = "computedAttribute";
|
|
17
18
|
export declare const GEO_ATTRIBUTE = "geo_attribute";
|
|
18
19
|
//# sourceMappingURL=bucket.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"bucket.d.ts","sourceRoot":"","sources":["../../../src/internal/constants/bucket.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"bucket.d.ts","sourceRoot":"","sources":["../../../src/internal/constants/bucket.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,OAAO,YAAY,CAAC;AAEjC,eAAO,MAAM,eAAe,kBAAkB,CAAC;AAC/C,eAAO,MAAM,sBAAsB,wBAAwB,CAAC;AAE5D,eAAO,MAAM,WAAW;;;;;;CAMvB,CAAC;AACF,eAAO,MAAM,QAAQ,aAAa,CAAC;AAEnC,eAAO,MAAM,OAAO,YAAY,CAAC;AAGjC,eAAO,MAAM,MAAM,WAAW,CAAC;AAC/B,eAAO,MAAM,IAAI,SAAS,CAAC;AAC3B,eAAO,MAAM,IAAI,SAAS,CAAC;AAC3B,eAAO,MAAM,SAAS,cAAc,CAAC;AACrC,eAAO,MAAM,kBAAkB,sBAAsB,CAAC;AACtD,eAAO,MAAM,aAAa,kBAAkB,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
// (C) 2019-
|
|
1
|
+
// (C) 2019-2026 GoodData Corporation
|
|
2
2
|
// Buckets
|
|
3
3
|
export const FILTERS = "filters";
|
|
4
4
|
export const SHOW_IN_PERCENT = "showInPercent";
|
|
@@ -17,4 +17,5 @@ export const METRIC = "metric";
|
|
|
17
17
|
export const FACT = "fact";
|
|
18
18
|
export const DATE = "date";
|
|
19
19
|
export const ATTRIBUTE = "attribute";
|
|
20
|
+
export const COMPUTED_ATTRIBUTE = "computedAttribute";
|
|
20
21
|
export const GEO_ATTRIBUTE = "geo_attribute";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"supportedProperties.d.ts","sourceRoot":"","sources":["../../../src/internal/constants/supportedProperties.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,yBAAyB,EAAE,MAAM,oCAAoC,CAAC;AAuEpF,eAAO,MAAM,4BAA4B,UAA8C,CAAC;AAIxF,eAAO,MAAM,+BAA+B,UAM3C,CAAC;AAEF,eAAO,MAAM,+BAA+B,UAO3C,CAAC;AAEF,eAAO,MAAM,iCAAiC;;CAe7C,CAAC;AAEF,eAAO,MAAM,+BAA+B;;CAiC3C,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,gCAAgC,UAa5C,CAAC;AAEF,eAAO,MAAM,8BAA8B;;CAuB1C,CAAC;AAEF,eAAO,MAAM,gCAAgC;;CAqC5C,CAAC;AAEF,eAAO,MAAM,iCAAiC,UAyB7C,CAAC;AAEF,eAAO,MAAM,gCAAgC,UAkC5C,CAAC;AAEF,eAAO,MAAM,0BAA0B,
|
|
1
|
+
{"version":3,"file":"supportedProperties.d.ts","sourceRoot":"","sources":["../../../src/internal/constants/supportedProperties.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,yBAAyB,EAAE,MAAM,oCAAoC,CAAC;AAuEpF,eAAO,MAAM,4BAA4B,UAA8C,CAAC;AAIxF,eAAO,MAAM,+BAA+B,UAM3C,CAAC;AAEF,eAAO,MAAM,+BAA+B,UAO3C,CAAC;AAEF,eAAO,MAAM,iCAAiC;;CAe7C,CAAC;AAEF,eAAO,MAAM,+BAA+B;;CAiC3C,CAAC;AAEF;;GAEG;AACH,eAAO,MAAM,gCAAgC,UAa5C,CAAC;AAEF,eAAO,MAAM,8BAA8B;;CAuB1C,CAAC;AAEF,eAAO,MAAM,gCAAgC;;CAqC5C,CAAC;AAEF,eAAO,MAAM,iCAAiC,UAyB7C,CAAC;AAEF,eAAO,MAAM,gCAAgC,UAkC5C,CAAC;AAEF,eAAO,MAAM,0BAA0B,UAmBtC,CAAC;AAEF,eAAO,MAAM,6BAA6B,UAezC,CAAC;AAEF,eAAO,MAAM,gCAAgC,UAe5C,CAAC;AAEF,eAAO,MAAM,4BAA4B,UAcxC,CAAC;AAEF,eAAO,MAAM,4BAA4B,UAwBxC,CAAC;AAEF,eAAO,MAAM,iCAAiC,UA4B7C,CAAC;AAEF,eAAO,MAAM,+BAA+B,UAwB3C,CAAC;AAEF;;;;;;;GAOG;AACH,eAAO,MAAM,oCAAoC,UAGhD,CAAC;AAEF,eAAO,MAAM,4BAA4B,UAiBxC,CAAC;AAEF,eAAO,MAAM,gCAAgC,UAW5C,CAAC;AAEF,eAAO,MAAM,qCAAqC,UAgBjD,CAAC;AAEF,eAAO,MAAM,iCAAiC,UAY7C,CAAC;AAWF,eAAO,MAAM,oCAAoC,UAQhD,CAAC;AAEF,eAAO,MAAM,kCAAkC,UAW9C,CAAC;AAEF,eAAO,MAAM,6BAA6B,UAMzC,CAAC;AAEF,eAAO,MAAM,mCAAmC,EAAE,yBAIjD,CAAC;AAEF,eAAO,MAAM,6CAA6C,EAAE,yBAS3D,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// (C) 2019-2026 GoodData Corporation
|
|
2
2
|
import { BucketNames, OverTimeComparisonTypes, VisualizationTypes } from "@gooddata/sdk-ui";
|
|
3
|
-
import { ATTRIBUTE, DATE, FACT, GEO_ATTRIBUTE, METRIC } from "./bucket.js";
|
|
3
|
+
import { ATTRIBUTE, COMPUTED_ATTRIBUTE, DATE, FACT, GEO_ATTRIBUTE, METRIC } from "./bucket.js";
|
|
4
4
|
export const MAX_METRICS_COUNT = 40;
|
|
5
5
|
export const DEFAULT_PIE_METRICS_COUNT = 1;
|
|
6
6
|
export const DEFAULT_PIE_ONLY_MAX_METRICS_COUNT = 20;
|
|
@@ -34,7 +34,7 @@ export const measuresBase = {
|
|
|
34
34
|
isShowInPercentVisible: true,
|
|
35
35
|
};
|
|
36
36
|
export const viewBase = {
|
|
37
|
-
accepts: [ATTRIBUTE, DATE],
|
|
37
|
+
accepts: [ATTRIBUTE, COMPUTED_ATTRIBUTE, DATE],
|
|
38
38
|
itemsLimit: MAX_CATEGORIES_COUNT,
|
|
39
39
|
itemsLimitByType: {
|
|
40
40
|
date: 1,
|
|
@@ -45,7 +45,7 @@ export const viewBase = {
|
|
|
45
45
|
isShowInPercentEnabled: false,
|
|
46
46
|
};
|
|
47
47
|
const stackBase = {
|
|
48
|
-
accepts: [ATTRIBUTE],
|
|
48
|
+
accepts: [ATTRIBUTE, COMPUTED_ATTRIBUTE],
|
|
49
49
|
itemsLimit: MAX_STACKS_COUNT,
|
|
50
50
|
allowsSwapping: true,
|
|
51
51
|
allowsReordering: false,
|
|
@@ -54,7 +54,7 @@ const stackBase = {
|
|
|
54
54
|
};
|
|
55
55
|
const stackBaseWithDate = {
|
|
56
56
|
...stackBase,
|
|
57
|
-
accepts: [ATTRIBUTE, DATE],
|
|
57
|
+
accepts: [ATTRIBUTE, COMPUTED_ATTRIBUTE, DATE],
|
|
58
58
|
};
|
|
59
59
|
export const defaultFilters = {
|
|
60
60
|
filters: {
|
|
@@ -572,7 +572,7 @@ export const DEFAULT_HEATMAP_UICONFIG = {
|
|
|
572
572
|
allowsDuplicateItems: true,
|
|
573
573
|
},
|
|
574
574
|
view: {
|
|
575
|
-
accepts: [ATTRIBUTE, DATE],
|
|
575
|
+
accepts: [ATTRIBUTE, COMPUTED_ATTRIBUTE, DATE],
|
|
576
576
|
itemsLimit: 1,
|
|
577
577
|
allowsSwapping: true,
|
|
578
578
|
allowsReordering: false,
|
|
@@ -582,7 +582,7 @@ export const DEFAULT_HEATMAP_UICONFIG = {
|
|
|
582
582
|
canAddItems: true,
|
|
583
583
|
},
|
|
584
584
|
stack: {
|
|
585
|
-
accepts: [ATTRIBUTE, DATE],
|
|
585
|
+
accepts: [ATTRIBUTE, COMPUTED_ATTRIBUTE, DATE],
|
|
586
586
|
itemsLimit: 1,
|
|
587
587
|
allowsSwapping: true,
|
|
588
588
|
allowsReordering: false,
|
|
@@ -748,7 +748,7 @@ const geoMeasuresBase = {
|
|
|
748
748
|
};
|
|
749
749
|
const geoAttributesBase = {
|
|
750
750
|
...viewBase,
|
|
751
|
-
accepts: [ATTRIBUTE],
|
|
751
|
+
accepts: [ATTRIBUTE, COMPUTED_ATTRIBUTE],
|
|
752
752
|
canAddItems: true,
|
|
753
753
|
itemsLimit: DEFAULT_GEO_ATTRIBUTES_COUNT,
|
|
754
754
|
};
|
|
@@ -833,7 +833,7 @@ export const DEFAULT_REPEATER_UI_CONFIG = {
|
|
|
833
833
|
buckets: {
|
|
834
834
|
attribute: {
|
|
835
835
|
...viewBase,
|
|
836
|
-
accepts: [ATTRIBUTE],
|
|
836
|
+
accepts: [ATTRIBUTE, COMPUTED_ATTRIBUTE],
|
|
837
837
|
itemsLimit: 1,
|
|
838
838
|
canAddItems: true,
|
|
839
839
|
allowsSwapping: true,
|
package/esm/internal/index.d.ts
CHANGED
|
@@ -11,7 +11,7 @@ export { MinMaxControl } from "./components/configurationControls/MinMaxControl.
|
|
|
11
11
|
export { BaseVisualization, type IBaseVisualizationApi, type IBaseVisualizationProps, } from "./components/BaseVisualization.js";
|
|
12
12
|
export { DefaultVisualizationCatalog, FullVisualizationCatalog, type IVisualizationCatalog, } from "./components/VisualizationCatalog.js";
|
|
13
13
|
export { resolveMessages, DEFAULT_LANGUAGE, DEFAULT_MESSAGES } from "./utils/translations.js";
|
|
14
|
-
export { createIntlMock } from "./
|
|
14
|
+
export { createIntlMock } from "./testIntlProvider.js";
|
|
15
15
|
export { type IVisualization, type IVisConstruct, type IVisCallbacks, type IVisProps, type IVisualizationProperties, type IVisualizationOptions, type IGdcConfig, type PluggableVisualizationErrorType, type PluggableVisualizationError, type IExtendedReferencePoint, type IBucketItem, type IReferencePoint, type IFilters, type IFiltersBucketItem, type IMeasureValueFilter, type IRankingFilter, type IAttributeFilter, type IArbitraryFilterData, type IMatchFilterData, type TextModeFilterData, type IDateFilter, type IDrillDownContext, type IDrillDownDefinition, type ICustomProps, type IConfigurationPanelRenderers, ConfigPanelClassName, PluggableVisualizationErrorCodes, InvalidBucketsSdkError, EmptyAfmSdkError, isPluggableVisualizationError, isEmptyAfm, isInvalidBuckets, isDrillDownDefinition, InvalidColumnsSdkError, isInvalidColumns, } from "./interfaces/Visualization.js";
|
|
16
16
|
export { isDateFilter, isMeasureValueFilter, isAttributeFilter, isRankingFilter, } from "./utils/bucketHelper.js";
|
|
17
17
|
export { createInternalIntl, InternalIntlWrapper } from "./utils/internalIntlProvider.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/internal/index.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,IAAI,EAAE,MAAM,qBAAqB,CAAC;AAC3C,OAAO,EAAE,wBAAwB,EAAE,MAAM,gCAAgC,CAAC;AAC1E,OAAO,EAAE,oBAAoB,EAAE,MAAM,iEAAiE,CAAC;AACvG,OAAO,EAAE,eAAe,EAAE,MAAM,4DAA4D,CAAC;AAC7F,OAAO,EAAE,mBAAmB,EAAE,MAAM,gEAAgE,CAAC;AACrG,OAAO,EAAE,cAAc,EAAE,MAAM,2DAA2D,CAAC;AAC3F,OAAO,EAAE,aAAa,EAAE,MAAM,0EAA0E,CAAC;AACzG,OAAO,EAAE,kBAAkB,EAAE,MAAM,kFAAkF,CAAC;AACtH,OAAO,EAAE,aAAa,EAAE,MAAM,4DAA4D,CAAC;AAC3F,OAAO,EAAE,aAAa,EAAE,MAAM,qDAAqD,CAAC;AAEpF,OAAO,EACH,iBAAiB,EACjB,KAAK,qBAAqB,EAC1B,KAAK,uBAAuB,GAC/B,MAAM,mCAAmC,CAAC;AAE3C,OAAO,EACH,2BAA2B,EAC3B,wBAAwB,EACxB,KAAK,qBAAqB,GAC7B,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAAE,eAAe,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,MAAM,yBAAyB,CAAC;AAC9F,OAAO,EAAE,cAAc,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/internal/index.ts"],"names":[],"mappings":"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"}
|
package/esm/internal/index.js
CHANGED
|
@@ -13,7 +13,7 @@ export { MinMaxControl } from "./components/configurationControls/MinMaxControl.
|
|
|
13
13
|
export { BaseVisualization, } from "./components/BaseVisualization.js";
|
|
14
14
|
export { DefaultVisualizationCatalog, FullVisualizationCatalog, } from "./components/VisualizationCatalog.js";
|
|
15
15
|
export { resolveMessages, DEFAULT_LANGUAGE, DEFAULT_MESSAGES } from "./utils/translations.js";
|
|
16
|
-
export { createIntlMock } from "./
|
|
16
|
+
export { createIntlMock } from "./testIntlProvider.js";
|
|
17
17
|
export { ConfigPanelClassName, PluggableVisualizationErrorCodes, InvalidBucketsSdkError, EmptyAfmSdkError, isPluggableVisualizationError, isEmptyAfm, isInvalidBuckets, isDrillDownDefinition, InvalidColumnsSdkError, isInvalidColumns, } from "./interfaces/Visualization.js";
|
|
18
18
|
export { isDateFilter, isMeasureValueFilter, isAttributeFilter, isRankingFilter, } from "./utils/bucketHelper.js";
|
|
19
19
|
export { createInternalIntl, InternalIntlWrapper } from "./utils/internalIntlProvider.js";
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Specifies test scenarios with various invalid inputs for type guards. These scenarios should be
|
|
3
|
+
* tested on all type guards in sdk-model.
|
|
4
|
+
*/
|
|
5
|
+
export declare const InvalidInputTestCases: Array<[boolean, string, any]>;
|
|
6
|
+
//# sourceMappingURL=typeGuards.test.helpers.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"typeGuards.test.helpers.d.ts","sourceRoot":"","sources":["../../../src/internal/interfaces/typeGuards.test.helpers.ts"],"names":[],"mappings":"AAEA;;;GAGG;AACH,eAAO,MAAM,qBAAqB,EAAE,KAAK,CAAC,CAAC,OAAO,EAAE,MAAM,EAAE,GAAG,CAAC,CAe/D,CAAC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
// (C) 2019-2026 GoodData Corporation
|
|
2
|
+
/**
|
|
3
|
+
* Specifies test scenarios with various invalid inputs for type guards. These scenarios should be
|
|
4
|
+
* tested on all type guards in sdk-model.
|
|
5
|
+
*/
|
|
6
|
+
export const InvalidInputTestCases = [
|
|
7
|
+
[false, "null", null],
|
|
8
|
+
[false, "undefined", undefined],
|
|
9
|
+
[false, "empty object", {}],
|
|
10
|
+
[false, "array", []],
|
|
11
|
+
[false, "string", "bleh"],
|
|
12
|
+
[false, "number", 42],
|
|
13
|
+
[false, "boolean", true],
|
|
14
|
+
[
|
|
15
|
+
false,
|
|
16
|
+
"function",
|
|
17
|
+
() => {
|
|
18
|
+
/**/
|
|
19
|
+
},
|
|
20
|
+
],
|
|
21
|
+
];
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { type IBucket, type IFilter, type IInsightDefinition, type ISeparators, type ISortItem } from "@gooddata/sdk-model";
|
|
2
|
+
import { type IFormatPreset } from "@gooddata/sdk-ui-kit";
|
|
3
|
+
import { type IDefaultControlProperties } from "./interfaces/ControlProperties.js";
|
|
4
|
+
import { type IVisualizationProperties } from "./interfaces/Visualization.js";
|
|
5
|
+
export declare const TEST_DEFAULT_SEPARATOR: ISeparators;
|
|
6
|
+
export declare const TEST_DECIMAL_FORMAT_PRESET: IFormatPreset;
|
|
7
|
+
export declare const TEST_PERCENT_ROUNDED_FORMAT_PRESET: IFormatPreset;
|
|
8
|
+
export declare const createTestProperties: <T extends IDefaultControlProperties>(params: T) => IVisualizationProperties<T>;
|
|
9
|
+
export declare const newInsight: <ControlProperties extends IDefaultControlProperties = IDefaultControlProperties>(buckets: IBucket[], options?: {
|
|
10
|
+
title?: string | undefined;
|
|
11
|
+
visualizationUrl?: string | undefined;
|
|
12
|
+
properties?: IVisualizationProperties<ControlProperties> | undefined;
|
|
13
|
+
sorts?: ISortItem[] | undefined;
|
|
14
|
+
filters?: IFilter[] | undefined;
|
|
15
|
+
} | undefined) => IInsightDefinition;
|
|
16
|
+
//# sourceMappingURL=testDataProvider.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"testDataProvider.d.ts","sourceRoot":"","sources":["../../src/internal/testDataProvider.ts"],"names":[],"mappings":"AAEA,OAAO,EACH,KAAK,OAAO,EACZ,KAAK,OAAO,EACZ,KAAK,kBAAkB,EACvB,KAAK,WAAW,EAChB,KAAK,SAAS,EACjB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAAE,KAAK,aAAa,EAAE,MAAM,sBAAsB,CAAC;AAE1D,OAAO,EAAE,KAAK,yBAAyB,EAAE,MAAM,mCAAmC,CAAC;AACnF,OAAO,EAAE,KAAK,wBAAwB,EAAE,MAAM,+BAA+B,CAAC;AAE9E,eAAO,MAAM,sBAAsB,EAAE,WAGpC,CAAC;AAEF,eAAO,MAAM,0BAA0B,EAAE,aAKxC,CAAC;AAEF,eAAO,MAAM,kCAAkC,EAAE,aAKhD,CAAC;AAEF,eAAO,MAAM,oBAAoB,GAAI,CAAC,6EAQrC,CAAC;AAEF,eAAO,MAAM,UAAU,GAAI,iBAAiB;;;;;;oCAoB3C,CAAC"}
|