@hisptz/dhis2-analytics 2.0.26 → 2.0.28

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.
@@ -13,6 +13,7 @@ const supportedDataSources = zod.z.enum([
13
13
  const scorecardSharing = zod.z.object({
14
14
  owner: zod.z.string(),
15
15
  external: zod.z.boolean(),
16
+ public: zod.z.string(),
16
17
  users: zod.z.record(
17
18
  zod.z.string(),
18
19
  zod.z.object({ access: zod.z.string(), id: zod.z.string() })
@@ -29,17 +30,17 @@ const legendDefinitionSchema = zod.z.object({
29
30
  isDefault: zod.z.boolean().optional()
30
31
  });
31
32
  const scorecardViewOptionsSchema = zod.z.object({
32
- averageColumn: zod.z.boolean(),
33
- averageDisplayType: zod.z.enum(["ALL", "ABOVE_AVERAGE", "BELOW_AVERAGE"]),
34
- averageRow: zod.z.boolean(),
35
- emptyRows: zod.z.boolean(),
36
- highlightedIndicators: zod.z.boolean(),
37
- itemNumber: zod.z.boolean(),
38
- legend: zod.z.boolean(),
39
- showHierarchy: zod.z.boolean(),
40
- title: zod.z.boolean(),
41
- arrows: zod.z.boolean(),
42
- showDataInRows: zod.z.boolean(),
33
+ averageColumn: zod.z.boolean().optional(),
34
+ averageDisplayType: zod.z.enum(["ALL", "ABOVE_AVERAGE", "BELOW_AVERAGE"]).optional(),
35
+ averageRow: zod.z.boolean().optional(),
36
+ emptyRows: zod.z.boolean().optional(),
37
+ highlightedIndicators: zod.z.boolean().optional(),
38
+ itemNumber: zod.z.boolean().optional(),
39
+ legend: zod.z.boolean().optional(),
40
+ showHierarchy: zod.z.boolean().optional(),
41
+ title: zod.z.boolean().optional(),
42
+ arrows: zod.z.boolean().optional(),
43
+ showDataInRows: zod.z.boolean().optional(),
43
44
  disableExpanding: zod.z.boolean().optional()
44
45
  });
45
46
  const organisationUnitSelectionSchema = zod.z.object({
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../src/components/Scorecard/schemas/config.ts"],"names":["ScorecardT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,EACD,QAAQ,EAAE,OAAO;AAClB,CAAC;AAMM,IAAK,4BAAL,kBAAKA,+BAAL;AACN,EAAAA,2BAAA,sBAAmB;AACnB,EAAAA,2BAAA,sBAAmB;AAFR,SAAAA;AAAA,GAAA;AAKL,IAAK,0BAAL,kBAAKC,6BAAL;AACN,EAAAA,yBAAA,WAAQ;AACR,EAAAA,yBAAA,eAAY;AACZ,EAAAA,yBAAA,aAAU;AACV,EAAAA,yBAAA,UAAO;AAJI,SAAAA;AAAA,GAAA;AAOL,IAAK,0BAAL,kBAAKC,6BAAL;AACN,EAAAA,yBAAA,QAAK;AACL,EAAAA,yBAAA,UAAO;AAFI,SAAAA;AAAA,GAAA","sourcesContent":["import { z } from \"zod\";\nimport type { RowData } from \"@tanstack/react-table\";\n\nexport const supportedDataSources = z.enum([\n\t\"indicator\",\n\t\"programIndicator\",\n\t\"dataSet\",\n\t\"dataElement\",\n\t\"customFunction\",\n\t\"sqlView\",\n]);\n\nexport const scorecardSharing = z.object({\n\towner: z.string(),\n\texternal: z.boolean(),\n\tusers: z.record(\n\t\tz.string(),\n\t\tz.object({ access: z.string(), id: z.string() }),\n\t),\n\tuserGroups: z.record(\n\t\tz.string(),\n\t\tz.object({ access: z.string(), id: z.string() }),\n\t),\n});\n\nexport type ScorecardSharing = z.infer<typeof scorecardSharing>;\n\nexport type SupportedDataSources = z.infer<typeof supportedDataSources>;\n\nexport const legendDefinitionSchema = z.object({\n\tid: z.string(),\n\tcolor: z.string(),\n\tname: z.string(),\n\tisDefault: z.boolean().optional(),\n});\n\nexport type LegendDefinition = z.infer<typeof legendDefinitionSchema>;\n\nexport const scorecardViewOptionsSchema = z.object({\n\taverageColumn: z.boolean(),\n\taverageDisplayType: z.enum([\"ALL\", \"ABOVE_AVERAGE\", \"BELOW_AVERAGE\"]),\n\taverageRow: z.boolean(),\n\temptyRows: z.boolean(),\n\thighlightedIndicators: z.boolean(),\n\titemNumber: z.boolean(),\n\tlegend: z.boolean(),\n\tshowHierarchy: z.boolean(),\n\ttitle: z.boolean(),\n\tarrows: z.boolean(),\n\tshowDataInRows: z.boolean(),\n\tdisableExpanding: z.boolean().optional(),\n});\n\nexport type ScorecardViewOptions = z.infer<typeof scorecardViewOptionsSchema>;\n\nexport const organisationUnitSelectionSchema = z.object({\n\tuserOrgUnit: z.boolean().optional(),\n\tuserSubUnit: z.boolean().optional(),\n\tuserSubX2Unit: z.boolean().optional(),\n\torgUnits: z.array(\n\t\tz.object({\n\t\t\tid: z.string(),\n\t\t}),\n\t),\n\tgroups: z.array(z.string()).optional(),\n\tlevels: z.array(z.string()).optional(),\n});\n\nexport type OrgUnitSelection = z.infer<typeof organisationUnitSelectionSchema>;\n\nexport const periodSelectionSchema = z.object({\n\tperiods: z.array(\n\t\tz.object({\n\t\t\tid: z.string(),\n\t\t}),\n\t),\n\ttype: z.string().optional(),\n});\n\nexport type PeriodSelection = z.infer<typeof periodSelectionSchema>;\n\nexport const legendSchema = z.object({\n\tlegendDefinitionId: z.string(),\n\tid: z.string(),\n\tstartValue: z.union([z.string(), z.number()]),\n\tendValue: z.union([z.string(), z.number()]),\n});\n\nexport type ScorecardLegend = z.infer<typeof legendSchema>;\n\nexport const specificTargetSchema = z.object({\n\ttype: z.enum([\"periods\", \"orgUnit\"]),\n\titems: z.array(z.string()),\n\tlegends: z.array(legendSchema),\n});\n\nexport type SpecificTarget = z.infer<typeof specificTargetSchema>;\n\nexport const orgUnitLevelLegendSchema = z.record(\n\tz.string(),\n\tz.array(legendSchema),\n);\n\nexport type OrgUnitLevelLegend = z.infer<typeof orgUnitLevelLegendSchema>;\n\nexport const dataSourceSchema = z.object({\n\tid: z.string(),\n\tname: z.string(),\n\tlabel: z.string().optional(),\n\ttype: supportedDataSources,\n\tdisplayArrows: z.boolean(),\n\thighIsGood: z.boolean(),\n\teffectiveGap: z.number(),\n\tshowColors: z.boolean(),\n\tweight: z.number(),\n\tlegends: z.union([z.array(legendSchema), orgUnitLevelLegendSchema]),\n\tspecificTargets: z.array(specificTargetSchema).optional(),\n\tspecificTargetsSet: z.boolean().optional(),\n\tdescription: z.string().optional(),\n});\n\nexport type ScorecardDataSource = z.infer<typeof dataSourceSchema>;\n\nexport const dataHolderSchema = z.object({\n\tid: z.union([z.number(), z.string()]),\n\tdataSources: z.array(dataSourceSchema),\n});\n\nexport type ScorecardDataHolder = z.infer<typeof dataHolderSchema>;\n\nexport const dataGroupSchema = z.object({\n\tid: z.union([z.number(), z.string()]),\n\tdataHolders: z.array(dataHolderSchema),\n\tstyle: z.object({}),\n\ttitle: z.string(),\n});\n\nexport type ScorecardDataGroup = z.infer<typeof dataGroupSchema>;\n\nconst scorecardConfig = z.object({\n\tid: z.string(),\n\ttitle: z.string(),\n\tsubtitle: z.string().optional(),\n\tcustomHeader: z.string().optional(),\n\tdescription: z.string().optional(),\n\tlegendDefinitions: z.array(legendDefinitionSchema),\n\toptions: scorecardViewOptionsSchema,\n\torgUnitSelection: organisationUnitSelectionSchema,\n\tperiodSelection: periodSelectionSchema,\n\tdataSelection: z.object({\n\t\tdataGroups: z.array(dataGroupSchema),\n\t}),\n\thighlightedIndicators: z.array(dataSourceSchema),\n\tadditionalLabels: z.array(z.string()).optional(),\n\tsharing: scorecardSharing,\n});\n\nexport type ScorecardConfig = z.infer<typeof scorecardConfig>;\n\nconst scorecardStateSchema = z.object({\n\torgUnitSelection: organisationUnitSelectionSchema,\n\tperiodSelection: periodSelectionSchema,\n\toptions: scorecardViewOptionsSchema,\n\tnested: z.boolean().optional(),\n\thasOnePeriod: z.boolean().optional(),\n});\n\nexport type ScorecardState = z.infer<typeof scorecardStateSchema>;\n\nexport const scorecardAnalyticsData = z.object({\n\tdx: z.string().optional(),\n\tpe: z.string().optional(),\n\tou: z.string().optional(),\n\tvalue: z.string().optional(),\n});\n\nexport type ScorecardAnalyticsData = z.infer<typeof scorecardAnalyticsData>;\n\nexport const scorecardTableData = z.object({\n\tlabel: z.string(),\n\tdataValues: z.array(scorecardAnalyticsData),\n\tdataHolder: dataHolderSchema.optional(),\n\torgUnit: z\n\t\t.object({\n\t\t\tuid: z.string(),\n\t\t\tname: z.string(),\n\t\t\thierarchy: z.string(),\n\t\t})\n\t\t.optional(),\n\texpand: z.boolean().optional(),\n});\n\nexport type ScorecardTableData = z.infer<typeof scorecardTableData> & RowData;\n\nexport const scorecardTableCellData = z.object({\n\tdataSources: z.array(\n\t\tdataSourceSchema.extend({\n\t\t\tdata: z.object({\n\t\t\t\tprevious: z.number().optional(),\n\t\t\t\tcurrent: z.number().optional(),\n\t\t\t}),\n\t\t}),\n\t),\n\torgUnit: z.object({\n\t\tuid: z.string(),\n\t\tname: z.string(),\n\t\thierarchy: z.string(),\n\t}),\n\tperiod: z.string(),\n});\n\nexport type ScorecardTableCellData = z.infer<typeof scorecardTableCellData>;\n\nexport type SanitizedScorecardTableData = z.infer<typeof scorecardTableData>;\n\nexport enum ScorecardTableOrientation {\n\tORG_UNIT_VS_DATA = \"orgUnitsVsData\",\n\tDATA_VS_ORG_UNIT = \"dataVsOrgUnits\",\n}\n\nexport enum ScorecardTableDimension {\n\tGROUP = \"group\",\n\tORG_UNITS = \"orgUnits\",\n\tPERIODS = \"periods\",\n\tDATA = \"data\",\n}\n\nexport enum ScorecardDraggableItems {\n\tou = \"ou\",\n\tdata = \"data\",\n}\n"]}
1
+ {"version":3,"sources":["../../../../src/components/Scorecard/schemas/config.ts"],"names":["ScorecardTableOrientation","ScorecardTableDimension","ScorecardDraggableItems"],"mappings":"AAAA,SAAS,SAAS;AAGX,MAAM,uBAAuB,EAAE,KAAK;AAAA,EAC1C;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACD,CAAC;AAEM,MAAM,mBAAmB,EAAE,OAAO;AAAA,EACxC,OAAO,EAAE,OAAO;AAAA,EAChB,UAAU,EAAE,QAAQ;AAAA,EACpB,QAAQ,EAAE,OAAO;AAAA,EACjB,OAAO,EAAE;AAAA,IACR,EAAE,OAAO;AAAA,IACT,EAAE,OAAO,EAAE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AA,WAAQ;AACR,EAAAA,yBAAA,eAAY;AACZ,EAAAA,yBAAA,aAAU;AACV,EAAAA,yBAAA,UAAO;AAJI,SAAAA;AAAA,GAAA;AAOL,IAAK,0BAAL,kBAAKC,6BAAL;AACN,EAAAA,yBAAA,QAAK;AACL,EAAAA,yBAAA,UAAO;AAFI,SAAAA;AAAA,GAAA","sourcesContent":["import { z } from \"zod\";\nimport type { RowData } from \"@tanstack/react-table\";\n\nexport const supportedDataSources = z.enum([\n\t\"indicator\",\n\t\"programIndicator\",\n\t\"dataSet\",\n\t\"dataElement\",\n\t\"customFunction\",\n\t\"sqlView\",\n]);\n\nexport const scorecardSharing = z.object({\n\towner: z.string(),\n\texternal: z.boolean(),\n\tpublic: z.string(),\n\tusers: z.record(\n\t\tz.string(),\n\t\tz.object({ access: z.string(), id: z.string() }),\n\t),\n\tuserGroups: z.record(\n\t\tz.string(),\n\t\tz.object({ access: z.string(), id: z.string() }),\n\t),\n});\n\nexport type ScorecardSharing = z.infer<typeof scorecardSharing>;\n\nexport type SupportedDataSources = z.infer<typeof supportedDataSources>;\n\nexport const legendDefinitionSchema = z.object({\n\tid: z.string(),\n\tcolor: z.string(),\n\tname: z.string(),\n\tisDefault: z.boolean().optional(),\n});\n\nexport type LegendDefinition = z.infer<typeof legendDefinitionSchema>;\n\nexport const scorecardViewOptionsSchema = z.object({\n\taverageColumn: z.boolean().optional(),\n\taverageDisplayType: z\n\t\t.enum([\"ALL\", \"ABOVE_AVERAGE\", \"BELOW_AVERAGE\"])\n\t\t.optional(),\n\taverageRow: z.boolean().optional(),\n\temptyRows: z.boolean().optional(),\n\thighlightedIndicators: z.boolean().optional(),\n\titemNumber: z.boolean().optional(),\n\tlegend: z.boolean().optional(),\n\tshowHierarchy: z.boolean().optional(),\n\ttitle: z.boolean().optional(),\n\tarrows: z.boolean().optional(),\n\tshowDataInRows: z.boolean().optional(),\n\tdisableExpanding: z.boolean().optional(),\n});\n\nexport type ScorecardViewOptions = z.infer<typeof scorecardViewOptionsSchema>;\n\nexport const organisationUnitSelectionSchema = z.object({\n\tuserOrgUnit: z.boolean().optional(),\n\tuserSubUnit: z.boolean().optional(),\n\tuserSubX2Unit: z.boolean().optional(),\n\torgUnits: z.array(\n\t\tz.object({\n\t\t\tid: z.string(),\n\t\t}),\n\t),\n\tgroups: z.array(z.string()).optional(),\n\tlevels: z.array(z.string()).optional(),\n});\n\nexport type OrgUnitSelection = z.infer<typeof organisationUnitSelectionSchema>;\n\nexport const periodSelectionSchema = z.object({\n\tperiods: z.array(\n\t\tz.object({\n\t\t\tid: z.string(),\n\t\t}),\n\t),\n\ttype: z.string().optional(),\n});\n\nexport type PeriodSelection = z.infer<typeof periodSelectionSchema>;\n\nexport const legendSchema = z.object({\n\tlegendDefinitionId: z.string(),\n\tid: z.string(),\n\tstartValue: z.union([z.string(), z.number()]),\n\tendValue: z.union([z.string(), z.number()]),\n});\n\nexport type ScorecardLegend = z.infer<typeof legendSchema>;\n\nexport const specificTargetSchema = z.object({\n\ttype: z.enum([\"periods\", \"orgUnit\"]),\n\titems: z.array(z.string()),\n\tlegends: z.array(legendSchema),\n});\n\nexport type SpecificTarget = z.infer<typeof specificTargetSchema>;\n\nexport const orgUnitLevelLegendSchema = z.record(\n\tz.string(),\n\tz.array(legendSchema),\n);\n\nexport type OrgUnitLevelLegend = z.infer<typeof orgUnitLevelLegendSchema>;\n\nexport const dataSourceSchema = z.object({\n\tid: z.string(),\n\tname: z.string(),\n\tlabel: z.string().optional(),\n\ttype: supportedDataSources,\n\tdisplayArrows: z.boolean(),\n\thighIsGood: z.boolean(),\n\teffectiveGap: z.number(),\n\tshowColors: z.boolean(),\n\tweight: z.number(),\n\tlegends: z.union([z.array(legendSchema), orgUnitLevelLegendSchema]),\n\tspecificTargets: z.array(specificTargetSchema).optional(),\n\tspecificTargetsSet: z.boolean().optional(),\n\tdescription: z.string().optional(),\n});\n\nexport type ScorecardDataSource = z.infer<typeof dataSourceSchema>;\n\nexport const dataHolderSchema = z.object({\n\tid: z.union([z.number(), z.string()]),\n\tdataSources: z.array(dataSourceSchema),\n});\n\nexport type ScorecardDataHolder = z.infer<typeof dataHolderSchema>;\n\nexport const dataGroupSchema = z.object({\n\tid: z.union([z.number(), z.string()]),\n\tdataHolders: z.array(dataHolderSchema),\n\tstyle: z.object({}),\n\ttitle: z.string(),\n});\n\nexport type ScorecardDataGroup = z.infer<typeof dataGroupSchema>;\n\nconst scorecardConfig = z.object({\n\tid: z.string(),\n\ttitle: z.string(),\n\tsubtitle: z.string().optional(),\n\tcustomHeader: z.string().optional(),\n\tdescription: z.string().optional(),\n\tlegendDefinitions: z.array(legendDefinitionSchema),\n\toptions: scorecardViewOptionsSchema,\n\torgUnitSelection: organisationUnitSelectionSchema,\n\tperiodSelection: periodSelectionSchema,\n\tdataSelection: z.object({\n\t\tdataGroups: z.array(dataGroupSchema),\n\t}),\n\thighlightedIndicators: z.array(dataSourceSchema),\n\tadditionalLabels: z.array(z.string()).optional(),\n\tsharing: scorecardSharing,\n});\n\nexport type ScorecardConfig = z.infer<typeof scorecardConfig>;\n\nconst scorecardStateSchema = z.object({\n\torgUnitSelection: organisationUnitSelectionSchema,\n\tperiodSelection: periodSelectionSchema,\n\toptions: scorecardViewOptionsSchema,\n\tnested: z.boolean().optional(),\n\thasOnePeriod: z.boolean().optional(),\n});\n\nexport type ScorecardState = z.infer<typeof scorecardStateSchema>;\n\nexport const scorecardAnalyticsData = z.object({\n\tdx: z.string().optional(),\n\tpe: z.string().optional(),\n\tou: z.string().optional(),\n\tvalue: z.string().optional(),\n});\n\nexport type ScorecardAnalyticsData = z.infer<typeof scorecardAnalyticsData>;\n\nexport const scorecardTableData = z.object({\n\tlabel: z.string(),\n\tdataValues: z.array(scorecardAnalyticsData),\n\tdataHolder: dataHolderSchema.optional(),\n\torgUnit: z\n\t\t.object({\n\t\t\tuid: z.string(),\n\t\t\tname: z.string(),\n\t\t\thierarchy: z.string(),\n\t\t})\n\t\t.optional(),\n\texpand: z.boolean().optional(),\n});\n\nexport type ScorecardTableData = z.infer<typeof scorecardTableData> & RowData;\n\nexport const scorecardTableCellData = z.object({\n\tdataSources: z.array(\n\t\tdataSourceSchema.extend({\n\t\t\tdata: z.object({\n\t\t\t\tprevious: z.number().optional(),\n\t\t\t\tcurrent: z.number().optional(),\n\t\t\t}),\n\t\t}),\n\t),\n\torgUnit: z.object({\n\t\tuid: z.string(),\n\t\tname: z.string(),\n\t\thierarchy: z.string(),\n\t}),\n\tperiod: z.string(),\n});\n\nexport type ScorecardTableCellData = z.infer<typeof scorecardTableCellData>;\n\nexport type SanitizedScorecardTableData = z.infer<typeof scorecardTableData>;\n\nexport enum ScorecardTableOrientation {\n\tORG_UNIT_VS_DATA = \"orgUnitsVsData\",\n\tDATA_VS_ORG_UNIT = \"dataVsOrgUnits\",\n}\n\nexport enum ScorecardTableDimension {\n\tGROUP = \"group\",\n\tORG_UNITS = \"orgUnits\",\n\tPERIODS = \"periods\",\n\tDATA = \"data\",\n}\n\nexport enum ScorecardDraggableItems {\n\tou = \"ou\",\n\tdata = \"data\",\n}\n"]}
@@ -11,6 +11,7 @@ const supportedDataSources = z.enum([
11
11
  const scorecardSharing = z.object({
12
12
  owner: z.string(),
13
13
  external: z.boolean(),
14
+ public: z.string(),
14
15
  users: z.record(
15
16
  z.string(),
16
17
  z.object({ access: z.string(), id: z.string() })
@@ -27,17 +28,17 @@ const legendDefinitionSchema = z.object({
27
28
  isDefault: z.boolean().optional()
28
29
  });
29
30
  const scorecardViewOptionsSchema = z.object({
30
- averageColumn: z.boolean(),
31
- averageDisplayType: z.enum(["ALL", "ABOVE_AVERAGE", "BELOW_AVERAGE"]),
32
- averageRow: z.boolean(),
33
- emptyRows: z.boolean(),
34
- highlightedIndicators: z.boolean(),
35
- itemNumber: z.boolean(),
36
- legend: z.boolean(),
37
- showHierarchy: z.boolean(),
38
- title: z.boolean(),
39
- arrows: z.boolean(),
40
- showDataInRows: z.boolean(),
31
+ averageColumn: z.boolean().optional(),
32
+ averageDisplayType: z.enum(["ALL", "ABOVE_AVERAGE", "BELOW_AVERAGE"]).optional(),
33
+ averageRow: z.boolean().optional(),
34
+ emptyRows: z.boolean().optional(),
35
+ highlightedIndicators: z.boolean().optional(),
36
+ itemNumber: z.boolean().optional(),
37
+ legend: z.boolean().optional(),
38
+ showHierarchy: z.boolean().optional(),
39
+ title: z.boolean().optional(),
40
+ arrows: z.boolean().optional(),
41
+ showDataInRows: z.boolean().optional(),
41
42
  disableExpanding: z.boolean().optional()
42
43
  });
43
44
  const organisationUnitSelectionSchema = z.object({
@@ -1 +1 @@
1
- {"version":3,"sources":["../../../../../src/components/Scorecard/schemas/config.ts"],"names":["ScorecardTableOrientation","ScorecardTableDimension","ScorecardDraggableItems"],"mappings":"AAAA,SAAS,SAAS;AAGX,MAAM,uBAAuB,EAAE,KAAK;AAAA,EAC1C;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACD,CAAC;AAEM,MAAM,mBAAmB,EAAE,OAAO;AAAA,EACxC,OAAO,EAAE,OAAO;AAAA,EAChB,UAAU,EAAE,QAAQ;AAAA,EACpB,OAAO,EAAE;AAAA,IACR,EAAE,OAAO;AAAA,IACT,EAAE,OAAO,EAAE,QAAQ,EAAE,OAAO,GAAG,IAAI,EAAE,OAAO,EAAE,CAAC;AAAA,EAChD;AAAA,EACA,YAAY,EAAE;AAAA,IACb,EAAE,OAAO;AAAA,IACT,EAAE,OAAO,EAAE,QAAQ,EAAE,OAAO,GAAG,IAAI,EAAE,OAAO,EAAE,CAAC;AAAA,EAChD;AACD,CAAC;AAMM,MAAM,yBAAyB,EAAE,OAAO;AAAA,EAC9C,IAAI,EAAE,OAAO;AAAA,EACb,OAAO,EAAE,OAAO;AAAA,EAChB,MAAM,EAAE,OAAO;AAAA,EACf,WAAW,EAAE,QAAQ,EAAE,SAAS;AACjC,CAAC;AAIM,MAAM,6BAA6B,EAAE,OAAO;AAAA,EAClD,eAAe,EAAE,QAAQ;AAAA,EACzB,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,QAAQ,EAAE,SAAS;AAC9B,CAAC;AAIM,MAAM,yBAAyB,EAAE,OAAO;AAAA,EAC9C,aAAa,EAAE;AAAA,IACd,iBAAiB,OAAO;AAAA,MACvB,MAAM,EAAE,OAAO;AAAA,QACd,UAAU,EAAE,OAAO,EAAE,SAAS;AAAA,QAC9B,SAAS,EAAE,OAAO,EAAE,SAAS;AAAA,MAC9B,CAAC;AAAA,IACF,CAAC;AAAA,EACF;AAAA,EACA,SAAS,EAAE,OAAO;AAAA,IACjB,KAAK,EAAE,OAAO;AAAA,IACd,MAAM,EAAE,OAAO;AAAA,IACf,WAAW,EAAE,OAAO;AAAA,EACrB,CAAC;AAAA,EACD,QAAQ,EAAE,OAAO;AAClB,CAAC;AAMM,IAAK,4BAAL,kBAAKA,+BAAL;AACN,EAAAA,2BAAA,sBAAmB;AACnB,EAAAA,2BAAA,sBAAmB;AAFR,SAAAA;AAAA,GAAA;AAKL,IAAK,0BAAL,kBAAKC,6BAAL;AACN,EAAAA,yBAAA,WAAQ;AACR,EAAAA,yBAAA,eAAY;AACZ,EAAAA,yBAAA,aAAU;AACV,EAAAA,yBAAA,UAAO;AAJI,SAAAA;AAAA,GAAA;AAOL,IAAK,0BAAL,kBAAKC,6BAAL;AACN,EAAAA,yBAAA,QAAK;AACL,EAAAA,yBAAA,UAAO;AAFI,SAAAA;AAAA,GAAA","sourcesContent":["import { z } from \"zod\";\nimport type { RowData } from \"@tanstack/react-table\";\n\nexport const supportedDataSources = z.enum([\n\t\"indicator\",\n\t\"programIndicator\",\n\t\"dataSet\",\n\t\"dataElement\",\n\t\"customFunction\",\n\t\"sqlView\",\n]);\n\nexport const scorecardSharing = z.object({\n\towner: z.string(),\n\texternal: z.boolean(),\n\tusers: z.record(\n\t\tz.string(),\n\t\tz.object({ access: z.string(), id: z.string() }),\n\t),\n\tuserGroups: z.record(\n\t\tz.string(),\n\t\tz.object({ access: z.string(), id: z.string() }),\n\t),\n});\n\nexport type ScorecardSharing = z.infer<typeof scorecardSharing>;\n\nexport type SupportedDataSources = z.infer<typeof supportedDataSources>;\n\nexport const legendDefinitionSchema = z.object({\n\tid: z.string(),\n\tcolor: z.string(),\n\tname: z.string(),\n\tisDefault: z.boolean().optional(),\n});\n\nexport type LegendDefinition = z.infer<typeof legendDefinitionSchema>;\n\nexport const scorecardViewOptionsSchema = z.object({\n\taverageColumn: z.boolean(),\n\taverageDisplayType: z.enum([\"ALL\", \"ABOVE_AVERAGE\", \"BELOW_AVERAGE\"]),\n\taverageRow: z.boolean(),\n\temptyRows: z.boolean(),\n\thighlightedIndicators: z.boolean(),\n\titemNumber: z.boolean(),\n\tlegend: z.boolean(),\n\tshowHierarchy: z.boolean(),\n\ttitle: z.boolean(),\n\tarrows: z.boolean(),\n\tshowDataInRows: z.boolean(),\n\tdisableExpanding: z.boolean().optional(),\n});\n\nexport type ScorecardViewOptions = z.infer<typeof scorecardViewOptionsSchema>;\n\nexport const organisationUnitSelectionSchema = z.object({\n\tuserOrgUnit: z.boolean().optional(),\n\tuserSubUnit: z.boolean().optional(),\n\tuserSubX2Unit: z.boolean().optional(),\n\torgUnits: z.array(\n\t\tz.object({\n\t\t\tid: z.string(),\n\t\t}),\n\t),\n\tgroups: z.array(z.string()).optional(),\n\tlevels: z.array(z.string()).optional(),\n});\n\nexport type OrgUnitSelection = z.infer<typeof organisationUnitSelectionSchema>;\n\nexport const periodSelectionSchema = z.object({\n\tperiods: z.array(\n\t\tz.object({\n\t\t\tid: z.string(),\n\t\t}),\n\t),\n\ttype: z.string().optional(),\n});\n\nexport type PeriodSelection = z.infer<typeof periodSelectionSchema>;\n\nexport const legendSchema = z.object({\n\tlegendDefinitionId: z.string(),\n\tid: z.string(),\n\tstartValue: z.union([z.string(), z.number()]),\n\tendValue: z.union([z.string(), z.number()]),\n});\n\nexport type ScorecardLegend = z.infer<typeof legendSchema>;\n\nexport const specificTargetSchema = z.object({\n\ttype: z.enum([\"periods\", \"orgUnit\"]),\n\titems: z.array(z.string()),\n\tlegends: z.array(legendSchema),\n});\n\nexport type SpecificTarget = z.infer<typeof specificTargetSchema>;\n\nexport const orgUnitLevelLegendSchema = z.record(\n\tz.string(),\n\tz.array(legendSchema),\n);\n\nexport type OrgUnitLevelLegend = z.infer<typeof orgUnitLevelLegendSchema>;\n\nexport const dataSourceSchema = z.object({\n\tid: z.string(),\n\tname: z.string(),\n\tlabel: z.string().optional(),\n\ttype: supportedDataSources,\n\tdisplayArrows: z.boolean(),\n\thighIsGood: z.boolean(),\n\teffectiveGap: z.number(),\n\tshowColors: z.boolean(),\n\tweight: z.number(),\n\tlegends: z.union([z.array(legendSchema), orgUnitLevelLegendSchema]),\n\tspecificTargets: z.array(specificTargetSchema).optional(),\n\tspecificTargetsSet: z.boolean().optional(),\n\tdescription: z.string().optional(),\n});\n\nexport type ScorecardDataSource = z.infer<typeof dataSourceSchema>;\n\nexport const dataHolderSchema = z.object({\n\tid: z.union([z.number(), z.string()]),\n\tdataSources: z.array(dataSourceSchema),\n});\n\nexport type ScorecardDataHolder = z.infer<typeof dataHolderSchema>;\n\nexport const dataGroupSchema = z.object({\n\tid: z.union([z.number(), z.string()]),\n\tdataHolders: z.array(dataHolderSchema),\n\tstyle: z.object({}),\n\ttitle: z.string(),\n});\n\nexport type ScorecardDataGroup = z.infer<typeof dataGroupSchema>;\n\nconst scorecardConfig = z.object({\n\tid: z.string(),\n\ttitle: z.string(),\n\tsubtitle: z.string().optional(),\n\tcustomHeader: z.string().optional(),\n\tdescription: z.string().optional(),\n\tlegendDefinitions: z.array(legendDefinitionSchema),\n\toptions: scorecardViewOptionsSchema,\n\torgUnitSelection: organisationUnitSelectionSchema,\n\tperiodSelection: periodSelectionSchema,\n\tdataSelection: z.object({\n\t\tdataGroups: z.array(dataGroupSchema),\n\t}),\n\thighlightedIndicators: z.array(dataSourceSchema),\n\tadditionalLabels: z.array(z.string()).optional(),\n\tsharing: scorecardSharing,\n});\n\nexport type ScorecardConfig = z.infer<typeof scorecardConfig>;\n\nconst scorecardStateSchema = z.object({\n\torgUnitSelection: organisationUnitSelectionSchema,\n\tperiodSelection: periodSelectionSchema,\n\toptions: scorecardViewOptionsSchema,\n\tnested: z.boolean().optional(),\n\thasOnePeriod: z.boolean().optional(),\n});\n\nexport type ScorecardState = z.infer<typeof scorecardStateSchema>;\n\nexport const scorecardAnalyticsData = z.object({\n\tdx: z.string().optional(),\n\tpe: z.string().optional(),\n\tou: z.string().optional(),\n\tvalue: z.string().optional(),\n});\n\nexport type ScorecardAnalyticsData = z.infer<typeof scorecardAnalyticsData>;\n\nexport const scorecardTableData = z.object({\n\tlabel: z.string(),\n\tdataValues: z.array(scorecardAnalyticsData),\n\tdataHolder: dataHolderSchema.optional(),\n\torgUnit: z\n\t\t.object({\n\t\t\tuid: z.string(),\n\t\t\tname: z.string(),\n\t\t\thierarchy: z.string(),\n\t\t})\n\t\t.optional(),\n\texpand: z.boolean().optional(),\n});\n\nexport type ScorecardTableData = z.infer<typeof scorecardTableData> & RowData;\n\nexport const scorecardTableCellData = z.object({\n\tdataSources: z.array(\n\t\tdataSourceSchema.extend({\n\t\t\tdata: z.object({\n\t\t\t\tprevious: z.number().optional(),\n\t\t\t\tcurrent: z.number().optional(),\n\t\t\t}),\n\t\t}),\n\t),\n\torgUnit: z.object({\n\t\tuid: z.string(),\n\t\tname: z.string(),\n\t\thierarchy: z.string(),\n\t}),\n\tperiod: z.string(),\n});\n\nexport type ScorecardTableCellData = z.infer<typeof scorecardTableCellData>;\n\nexport type SanitizedScorecardTableData = z.infer<typeof scorecardTableData>;\n\nexport enum ScorecardTableOrientation {\n\tORG_UNIT_VS_DATA = \"orgUnitsVsData\",\n\tDATA_VS_ORG_UNIT = \"dataVsOrgUnits\",\n}\n\nexport enum ScorecardTableDimension {\n\tGROUP = \"group\",\n\tORG_UNITS = \"orgUnits\",\n\tPERIODS = \"periods\",\n\tDATA = \"data\",\n}\n\nexport enum ScorecardDraggableItems {\n\tou = \"ou\",\n\tdata = \"data\",\n}\n"]}
1
+ {"version":3,"sources":["../../../../../src/components/Scorecard/schemas/config.ts"],"names":["ScorecardTableOrientation","ScorecardTableDimension","ScorecardDraggableItems"],"mappings":"AAAA,SAAS,SAAS;AAGX,MAAM,uBAAuB,EAAE,KAAK;AAAA,EAC1C;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACD,CAAC;AAEM,MAAM,mBAAmB,EAAE,OAAO;AAAA,EACxC,OAAO,EAAE,OAAO;AAAA,EAChB,UAAU,EAAE,QAAQ;AAAA,EACpB,QAAQ,EAAE,OAAO;AAAA,EACjB,OAAO,EAAE;AAAA,IACR,EAAE,OAAO;AAAA,IACT,EAAE,OAAO,EAAE,QAAQ,EAAE,OAAO,GAAG,IAAI,EAAE,OAAO,EAAE,CAAC;AAAA,EAChD;AAAA,EACA,YAAY,EAAE;AAAA,IACb,EAAE,OAAO;AAAA,IACT,EAAE,OAAO,EAAE,QAAQ,EAAE,OAAO,GAAG,IAAI,EAAE,OAAO,EAAE,CAAC;AAAA,EAChD;AACD,CAAC;AAMM,MAAM,yBAAyB,EAAE,OAAO;AAAA,EAC9C,IAAI,EAAE,OAAO;AAAA,EACb,OAAO,EAAE,OAAO;AAAA,EAChB,MAAM,EAAE,OAAO;AAAA,EACf,WAAW,EAAE,QAAQ,EAAE,SAAS;AACjC,CAAC;AAIM,MAAM,6BAA6B,EAAE,OAAO;AAAA,EAClD,eAAe,EAAE,QAAQ,EAAE,SAAS;AAAA,EACpC,oBAAoB,EAClB,KAAK,CAAC,OAAO,iBAAiB,eAAe,CAAC,EAC9C,SAAS;AAAA,EACX,YAAY,EAAE,QAAQ,EAAE,SAAS;AAAA,EACjC,WAAW,EAAE,QAAQ,EAAE,SAAS;AAAA,EAChC,uBAAuB,EAAE,QAAQ,EAAE,SAAS;AAAA,EAC5C,YAAY,EAAE,QAAQ,EAAE,SAAS;AAAA,EACjC,QAAQ,EAAE,QAAQ,EAAE,SAAS;AAAA,EAC7B,eAAe,EAAE,QAAQ,EAAE,SA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AS,EAAE,OAAO,EAAE,SAAS;AAAA,MAC9B,CAAC;AAAA,IACF,CAAC;AAAA,EACF;AAAA,EACA,SAAS,EAAE,OAAO;AAAA,IACjB,KAAK,EAAE,OAAO;AAAA,IACd,MAAM,EAAE,OAAO;AAAA,IACf,WAAW,EAAE,OAAO;AAAA,EACrB,CAAC;AAAA,EACD,QAAQ,EAAE,OAAO;AAClB,CAAC;AAMM,IAAK,4BAAL,kBAAKA,+BAAL;AACN,EAAAA,2BAAA,sBAAmB;AACnB,EAAAA,2BAAA,sBAAmB;AAFR,SAAAA;AAAA,GAAA;AAKL,IAAK,0BAAL,kBAAKC,6BAAL;AACN,EAAAA,yBAAA,WAAQ;AACR,EAAAA,yBAAA,eAAY;AACZ,EAAAA,yBAAA,aAAU;AACV,EAAAA,yBAAA,UAAO;AAJI,SAAAA;AAAA,GAAA;AAOL,IAAK,0BAAL,kBAAKC,6BAAL;AACN,EAAAA,yBAAA,QAAK;AACL,EAAAA,yBAAA,UAAO;AAFI,SAAAA;AAAA,GAAA","sourcesContent":["import { z } from \"zod\";\nimport type { RowData } from \"@tanstack/react-table\";\n\nexport const supportedDataSources = z.enum([\n\t\"indicator\",\n\t\"programIndicator\",\n\t\"dataSet\",\n\t\"dataElement\",\n\t\"customFunction\",\n\t\"sqlView\",\n]);\n\nexport const scorecardSharing = z.object({\n\towner: z.string(),\n\texternal: z.boolean(),\n\tpublic: z.string(),\n\tusers: z.record(\n\t\tz.string(),\n\t\tz.object({ access: z.string(), id: z.string() }),\n\t),\n\tuserGroups: z.record(\n\t\tz.string(),\n\t\tz.object({ access: z.string(), id: z.string() }),\n\t),\n});\n\nexport type ScorecardSharing = z.infer<typeof scorecardSharing>;\n\nexport type SupportedDataSources = z.infer<typeof supportedDataSources>;\n\nexport const legendDefinitionSchema = z.object({\n\tid: z.string(),\n\tcolor: z.string(),\n\tname: z.string(),\n\tisDefault: z.boolean().optional(),\n});\n\nexport type LegendDefinition = z.infer<typeof legendDefinitionSchema>;\n\nexport const scorecardViewOptionsSchema = z.object({\n\taverageColumn: z.boolean().optional(),\n\taverageDisplayType: z\n\t\t.enum([\"ALL\", \"ABOVE_AVERAGE\", \"BELOW_AVERAGE\"])\n\t\t.optional(),\n\taverageRow: z.boolean().optional(),\n\temptyRows: z.boolean().optional(),\n\thighlightedIndicators: z.boolean().optional(),\n\titemNumber: z.boolean().optional(),\n\tlegend: z.boolean().optional(),\n\tshowHierarchy: z.boolean().optional(),\n\ttitle: z.boolean().optional(),\n\tarrows: z.boolean().optional(),\n\tshowDataInRows: z.boolean().optional(),\n\tdisableExpanding: z.boolean().optional(),\n});\n\nexport type ScorecardViewOptions = z.infer<typeof scorecardViewOptionsSchema>;\n\nexport const organisationUnitSelectionSchema = z.object({\n\tuserOrgUnit: z.boolean().optional(),\n\tuserSubUnit: z.boolean().optional(),\n\tuserSubX2Unit: z.boolean().optional(),\n\torgUnits: z.array(\n\t\tz.object({\n\t\t\tid: z.string(),\n\t\t}),\n\t),\n\tgroups: z.array(z.string()).optional(),\n\tlevels: z.array(z.string()).optional(),\n});\n\nexport type OrgUnitSelection = z.infer<typeof organisationUnitSelectionSchema>;\n\nexport const periodSelectionSchema = z.object({\n\tperiods: z.array(\n\t\tz.object({\n\t\t\tid: z.string(),\n\t\t}),\n\t),\n\ttype: z.string().optional(),\n});\n\nexport type PeriodSelection = z.infer<typeof periodSelectionSchema>;\n\nexport const legendSchema = z.object({\n\tlegendDefinitionId: z.string(),\n\tid: z.string(),\n\tstartValue: z.union([z.string(), z.number()]),\n\tendValue: z.union([z.string(), z.number()]),\n});\n\nexport type ScorecardLegend = z.infer<typeof legendSchema>;\n\nexport const specificTargetSchema = z.object({\n\ttype: z.enum([\"periods\", \"orgUnit\"]),\n\titems: z.array(z.string()),\n\tlegends: z.array(legendSchema),\n});\n\nexport type SpecificTarget = z.infer<typeof specificTargetSchema>;\n\nexport const orgUnitLevelLegendSchema = z.record(\n\tz.string(),\n\tz.array(legendSchema),\n);\n\nexport type OrgUnitLevelLegend = z.infer<typeof orgUnitLevelLegendSchema>;\n\nexport const dataSourceSchema = z.object({\n\tid: z.string(),\n\tname: z.string(),\n\tlabel: z.string().optional(),\n\ttype: supportedDataSources,\n\tdisplayArrows: z.boolean(),\n\thighIsGood: z.boolean(),\n\teffectiveGap: z.number(),\n\tshowColors: z.boolean(),\n\tweight: z.number(),\n\tlegends: z.union([z.array(legendSchema), orgUnitLevelLegendSchema]),\n\tspecificTargets: z.array(specificTargetSchema).optional(),\n\tspecificTargetsSet: z.boolean().optional(),\n\tdescription: z.string().optional(),\n});\n\nexport type ScorecardDataSource = z.infer<typeof dataSourceSchema>;\n\nexport const dataHolderSchema = z.object({\n\tid: z.union([z.number(), z.string()]),\n\tdataSources: z.array(dataSourceSchema),\n});\n\nexport type ScorecardDataHolder = z.infer<typeof dataHolderSchema>;\n\nexport const dataGroupSchema = z.object({\n\tid: z.union([z.number(), z.string()]),\n\tdataHolders: z.array(dataHolderSchema),\n\tstyle: z.object({}),\n\ttitle: z.string(),\n});\n\nexport type ScorecardDataGroup = z.infer<typeof dataGroupSchema>;\n\nconst scorecardConfig = z.object({\n\tid: z.string(),\n\ttitle: z.string(),\n\tsubtitle: z.string().optional(),\n\tcustomHeader: z.string().optional(),\n\tdescription: z.string().optional(),\n\tlegendDefinitions: z.array(legendDefinitionSchema),\n\toptions: scorecardViewOptionsSchema,\n\torgUnitSelection: organisationUnitSelectionSchema,\n\tperiodSelection: periodSelectionSchema,\n\tdataSelection: z.object({\n\t\tdataGroups: z.array(dataGroupSchema),\n\t}),\n\thighlightedIndicators: z.array(dataSourceSchema),\n\tadditionalLabels: z.array(z.string()).optional(),\n\tsharing: scorecardSharing,\n});\n\nexport type ScorecardConfig = z.infer<typeof scorecardConfig>;\n\nconst scorecardStateSchema = z.object({\n\torgUnitSelection: organisationUnitSelectionSchema,\n\tperiodSelection: periodSelectionSchema,\n\toptions: scorecardViewOptionsSchema,\n\tnested: z.boolean().optional(),\n\thasOnePeriod: z.boolean().optional(),\n});\n\nexport type ScorecardState = z.infer<typeof scorecardStateSchema>;\n\nexport const scorecardAnalyticsData = z.object({\n\tdx: z.string().optional(),\n\tpe: z.string().optional(),\n\tou: z.string().optional(),\n\tvalue: z.string().optional(),\n});\n\nexport type ScorecardAnalyticsData = z.infer<typeof scorecardAnalyticsData>;\n\nexport const scorecardTableData = z.object({\n\tlabel: z.string(),\n\tdataValues: z.array(scorecardAnalyticsData),\n\tdataHolder: dataHolderSchema.optional(),\n\torgUnit: z\n\t\t.object({\n\t\t\tuid: z.string(),\n\t\t\tname: z.string(),\n\t\t\thierarchy: z.string(),\n\t\t})\n\t\t.optional(),\n\texpand: z.boolean().optional(),\n});\n\nexport type ScorecardTableData = z.infer<typeof scorecardTableData> & RowData;\n\nexport const scorecardTableCellData = z.object({\n\tdataSources: z.array(\n\t\tdataSourceSchema.extend({\n\t\t\tdata: z.object({\n\t\t\t\tprevious: z.number().optional(),\n\t\t\t\tcurrent: z.number().optional(),\n\t\t\t}),\n\t\t}),\n\t),\n\torgUnit: z.object({\n\t\tuid: z.string(),\n\t\tname: z.string(),\n\t\thierarchy: z.string(),\n\t}),\n\tperiod: z.string(),\n});\n\nexport type ScorecardTableCellData = z.infer<typeof scorecardTableCellData>;\n\nexport type SanitizedScorecardTableData = z.infer<typeof scorecardTableData>;\n\nexport enum ScorecardTableOrientation {\n\tORG_UNIT_VS_DATA = \"orgUnitsVsData\",\n\tDATA_VS_ORG_UNIT = \"dataVsOrgUnits\",\n}\n\nexport enum ScorecardTableDimension {\n\tGROUP = \"group\",\n\tORG_UNITS = \"orgUnits\",\n\tPERIODS = \"periods\",\n\tDATA = \"data\",\n}\n\nexport enum ScorecardDraggableItems {\n\tou = \"ou\",\n\tdata = \"data\",\n}\n"]}
@@ -3,17 +3,17 @@ import type { ScorecardConfig } from "../schemas/config";
3
3
  export declare function useScorecardConfig(): {
4
4
  id: string;
5
5
  options: {
6
- legend: boolean;
7
- title: boolean;
8
- averageColumn: boolean;
9
- averageDisplayType: "ALL" | "ABOVE_AVERAGE" | "BELOW_AVERAGE";
10
- averageRow: boolean;
11
- emptyRows: boolean;
12
- highlightedIndicators: boolean;
13
- itemNumber: boolean;
14
- showHierarchy: boolean;
15
- arrows: boolean;
16
- showDataInRows: boolean;
6
+ legend?: boolean | undefined;
7
+ title?: boolean | undefined;
8
+ averageColumn?: boolean | undefined;
9
+ averageDisplayType?: "ALL" | "ABOVE_AVERAGE" | "BELOW_AVERAGE" | undefined;
10
+ averageRow?: boolean | undefined;
11
+ emptyRows?: boolean | undefined;
12
+ highlightedIndicators?: boolean | undefined;
13
+ itemNumber?: boolean | undefined;
14
+ showHierarchy?: boolean | undefined;
15
+ arrows?: boolean | undefined;
16
+ showDataInRows?: boolean | undefined;
17
17
  disableExpanding?: boolean | undefined;
18
18
  };
19
19
  title: string;
@@ -120,6 +120,7 @@ export declare function useScorecardConfig(): {
120
120
  sharing: {
121
121
  external: boolean;
122
122
  owner: string;
123
+ public: string;
123
124
  users: Record<string, {
124
125
  id: string;
125
126
  access: string;
@@ -1 +1 @@
1
- {"version":3,"file":"ConfigProvider.d.ts","sourceRoot":"","sources":["../../../../../src/components/Scorecard/components/ConfigProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAoC,MAAM,OAAO,CAAC;AACzD,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAKzD,wBAAgB,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAUjC;AAED,eAAO,MAAM,uBAAuB,EAAE,KAAK,CAAC,EAAE,CAAC;IAC9C,MAAM,EAAE,eAAe,CAAC;IACxB,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAC1B,CAMA,CAAC"}
1
+ {"version":3,"file":"ConfigProvider.d.ts","sourceRoot":"","sources":["../../../../../src/components/Scorecard/components/ConfigProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAoC,MAAM,OAAO,CAAC;AACzD,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AAKzD,wBAAgB,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAUjC;AAED,eAAO,MAAM,uBAAuB,EAAE,KAAK,CAAC,EAAE,CAAC;IAC9C,MAAM,EAAE,eAAe,CAAC;IACxB,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;CAC1B,CAMA,CAAC"}
@@ -3,17 +3,17 @@ import type { ScorecardState } from "../schemas/config";
3
3
  export type ScorecardSetState = Dispatch<SetStateAction<ScorecardState>>;
4
4
  export declare function useScorecardState(): {
5
5
  options: {
6
- legend: boolean;
7
- title: boolean;
8
- averageColumn: boolean;
9
- averageDisplayType: "ALL" | "ABOVE_AVERAGE" | "BELOW_AVERAGE";
10
- averageRow: boolean;
11
- emptyRows: boolean;
12
- highlightedIndicators: boolean;
13
- itemNumber: boolean;
14
- showHierarchy: boolean;
15
- arrows: boolean;
16
- showDataInRows: boolean;
6
+ legend?: boolean | undefined;
7
+ title?: boolean | undefined;
8
+ averageColumn?: boolean | undefined;
9
+ averageDisplayType?: "ALL" | "ABOVE_AVERAGE" | "BELOW_AVERAGE" | undefined;
10
+ averageRow?: boolean | undefined;
11
+ emptyRows?: boolean | undefined;
12
+ highlightedIndicators?: boolean | undefined;
13
+ itemNumber?: boolean | undefined;
14
+ showHierarchy?: boolean | undefined;
15
+ arrows?: boolean | undefined;
16
+ showDataInRows?: boolean | undefined;
17
17
  disableExpanding?: boolean | undefined;
18
18
  };
19
19
  orgUnitSelection: {
@@ -4,6 +4,7 @@ export declare const supportedDataSources: z.ZodEnum<["indicator", "programIndic
4
4
  export declare const scorecardSharing: z.ZodObject<{
5
5
  owner: z.ZodString;
6
6
  external: z.ZodBoolean;
7
+ public: z.ZodString;
7
8
  users: z.ZodRecord<z.ZodString, z.ZodObject<{
8
9
  access: z.ZodString;
9
10
  id: z.ZodString;
@@ -27,6 +28,7 @@ export declare const scorecardSharing: z.ZodObject<{
27
28
  }, "strip", z.ZodTypeAny, {
28
29
  external: boolean;
29
30
  owner: string;
31
+ public: string;
30
32
  users: Record<string, {
31
33
  id: string;
32
34
  access: string;
@@ -38,6 +40,7 @@ export declare const scorecardSharing: z.ZodObject<{
38
40
  }, {
39
41
  external: boolean;
40
42
  owner: string;
43
+ public: string;
41
44
  users: Record<string, {
42
45
  id: string;
43
46
  access: string;
@@ -67,43 +70,43 @@ export declare const legendDefinitionSchema: z.ZodObject<{
67
70
  }>;
68
71
  export type LegendDefinition = z.infer<typeof legendDefinitionSchema>;
69
72
  export declare const scorecardViewOptionsSchema: z.ZodObject<{
70
- averageColumn: z.ZodBoolean;
71
- averageDisplayType: z.ZodEnum<["ALL", "ABOVE_AVERAGE", "BELOW_AVERAGE"]>;
72
- averageRow: z.ZodBoolean;
73
- emptyRows: z.ZodBoolean;
74
- highlightedIndicators: z.ZodBoolean;
75
- itemNumber: z.ZodBoolean;
76
- legend: z.ZodBoolean;
77
- showHierarchy: z.ZodBoolean;
78
- title: z.ZodBoolean;
79
- arrows: z.ZodBoolean;
80
- showDataInRows: z.ZodBoolean;
73
+ averageColumn: z.ZodOptional<z.ZodBoolean>;
74
+ averageDisplayType: z.ZodOptional<z.ZodEnum<["ALL", "ABOVE_AVERAGE", "BELOW_AVERAGE"]>>;
75
+ averageRow: z.ZodOptional<z.ZodBoolean>;
76
+ emptyRows: z.ZodOptional<z.ZodBoolean>;
77
+ highlightedIndicators: z.ZodOptional<z.ZodBoolean>;
78
+ itemNumber: z.ZodOptional<z.ZodBoolean>;
79
+ legend: z.ZodOptional<z.ZodBoolean>;
80
+ showHierarchy: z.ZodOptional<z.ZodBoolean>;
81
+ title: z.ZodOptional<z.ZodBoolean>;
82
+ arrows: z.ZodOptional<z.ZodBoolean>;
83
+ showDataInRows: z.ZodOptional<z.ZodBoolean>;
81
84
  disableExpanding: z.ZodOptional<z.ZodBoolean>;
82
85
  }, "strip", z.ZodTypeAny, {
83
- legend: boolean;
84
- title: boolean;
85
- averageColumn: boolean;
86
- averageDisplayType: "ALL" | "ABOVE_AVERAGE" | "BELOW_AVERAGE";
87
- averageRow: boolean;
88
- emptyRows: boolean;
89
- highlightedIndicators: boolean;
90
- itemNumber: boolean;
91
- showHierarchy: boolean;
92
- arrows: boolean;
93
- showDataInRows: boolean;
86
+ legend?: boolean | undefined;
87
+ title?: boolean | undefined;
88
+ averageColumn?: boolean | undefined;
89
+ averageDisplayType?: "ALL" | "ABOVE_AVERAGE" | "BELOW_AVERAGE" | undefined;
90
+ averageRow?: boolean | undefined;
91
+ emptyRows?: boolean | undefined;
92
+ highlightedIndicators?: boolean | undefined;
93
+ itemNumber?: boolean | undefined;
94
+ showHierarchy?: boolean | undefined;
95
+ arrows?: boolean | undefined;
96
+ showDataInRows?: boolean | undefined;
94
97
  disableExpanding?: boolean | undefined;
95
98
  }, {
96
- legend: boolean;
97
- title: boolean;
98
- averageColumn: boolean;
99
- averageDisplayType: "ALL" | "ABOVE_AVERAGE" | "BELOW_AVERAGE";
100
- averageRow: boolean;
101
- emptyRows: boolean;
102
- highlightedIndicators: boolean;
103
- itemNumber: boolean;
104
- showHierarchy: boolean;
105
- arrows: boolean;
106
- showDataInRows: boolean;
99
+ legend?: boolean | undefined;
100
+ title?: boolean | undefined;
101
+ averageColumn?: boolean | undefined;
102
+ averageDisplayType?: "ALL" | "ABOVE_AVERAGE" | "BELOW_AVERAGE" | undefined;
103
+ averageRow?: boolean | undefined;
104
+ emptyRows?: boolean | undefined;
105
+ highlightedIndicators?: boolean | undefined;
106
+ itemNumber?: boolean | undefined;
107
+ showHierarchy?: boolean | undefined;
108
+ arrows?: boolean | undefined;
109
+ showDataInRows?: boolean | undefined;
107
110
  disableExpanding?: boolean | undefined;
108
111
  }>;
109
112
  export type ScorecardViewOptions = z.infer<typeof scorecardViewOptionsSchema>;
@@ -941,43 +944,43 @@ declare const scorecardConfig: z.ZodObject<{
941
944
  isDefault?: boolean | undefined;
942
945
  }>, "many">;
943
946
  options: z.ZodObject<{
944
- averageColumn: z.ZodBoolean;
945
- averageDisplayType: z.ZodEnum<["ALL", "ABOVE_AVERAGE", "BELOW_AVERAGE"]>;
946
- averageRow: z.ZodBoolean;
947
- emptyRows: z.ZodBoolean;
948
- highlightedIndicators: z.ZodBoolean;
949
- itemNumber: z.ZodBoolean;
950
- legend: z.ZodBoolean;
951
- showHierarchy: z.ZodBoolean;
952
- title: z.ZodBoolean;
953
- arrows: z.ZodBoolean;
954
- showDataInRows: z.ZodBoolean;
947
+ averageColumn: z.ZodOptional<z.ZodBoolean>;
948
+ averageDisplayType: z.ZodOptional<z.ZodEnum<["ALL", "ABOVE_AVERAGE", "BELOW_AVERAGE"]>>;
949
+ averageRow: z.ZodOptional<z.ZodBoolean>;
950
+ emptyRows: z.ZodOptional<z.ZodBoolean>;
951
+ highlightedIndicators: z.ZodOptional<z.ZodBoolean>;
952
+ itemNumber: z.ZodOptional<z.ZodBoolean>;
953
+ legend: z.ZodOptional<z.ZodBoolean>;
954
+ showHierarchy: z.ZodOptional<z.ZodBoolean>;
955
+ title: z.ZodOptional<z.ZodBoolean>;
956
+ arrows: z.ZodOptional<z.ZodBoolean>;
957
+ showDataInRows: z.ZodOptional<z.ZodBoolean>;
955
958
  disableExpanding: z.ZodOptional<z.ZodBoolean>;
956
959
  }, "strip", z.ZodTypeAny, {
957
- legend: boolean;
958
- title: boolean;
959
- averageColumn: boolean;
960
- averageDisplayType: "ALL" | "ABOVE_AVERAGE" | "BELOW_AVERAGE";
961
- averageRow: boolean;
962
- emptyRows: boolean;
963
- highlightedIndicators: boolean;
964
- itemNumber: boolean;
965
- showHierarchy: boolean;
966
- arrows: boolean;
967
- showDataInRows: boolean;
960
+ legend?: boolean | undefined;
961
+ title?: boolean | undefined;
962
+ averageColumn?: boolean | undefined;
963
+ averageDisplayType?: "ALL" | "ABOVE_AVERAGE" | "BELOW_AVERAGE" | undefined;
964
+ averageRow?: boolean | undefined;
965
+ emptyRows?: boolean | undefined;
966
+ highlightedIndicators?: boolean | undefined;
967
+ itemNumber?: boolean | undefined;
968
+ showHierarchy?: boolean | undefined;
969
+ arrows?: boolean | undefined;
970
+ showDataInRows?: boolean | undefined;
968
971
  disableExpanding?: boolean | undefined;
969
972
  }, {
970
- legend: boolean;
971
- title: boolean;
972
- averageColumn: boolean;
973
- averageDisplayType: "ALL" | "ABOVE_AVERAGE" | "BELOW_AVERAGE";
974
- averageRow: boolean;
975
- emptyRows: boolean;
976
- highlightedIndicators: boolean;
977
- itemNumber: boolean;
978
- showHierarchy: boolean;
979
- arrows: boolean;
980
- showDataInRows: boolean;
973
+ legend?: boolean | undefined;
974
+ title?: boolean | undefined;
975
+ averageColumn?: boolean | undefined;
976
+ averageDisplayType?: "ALL" | "ABOVE_AVERAGE" | "BELOW_AVERAGE" | undefined;
977
+ averageRow?: boolean | undefined;
978
+ emptyRows?: boolean | undefined;
979
+ highlightedIndicators?: boolean | undefined;
980
+ itemNumber?: boolean | undefined;
981
+ showHierarchy?: boolean | undefined;
982
+ arrows?: boolean | undefined;
983
+ showDataInRows?: boolean | undefined;
981
984
  disableExpanding?: boolean | undefined;
982
985
  }>;
983
986
  orgUnitSelection: z.ZodObject<{
@@ -1582,6 +1585,7 @@ declare const scorecardConfig: z.ZodObject<{
1582
1585
  sharing: z.ZodObject<{
1583
1586
  owner: z.ZodString;
1584
1587
  external: z.ZodBoolean;
1588
+ public: z.ZodString;
1585
1589
  users: z.ZodRecord<z.ZodString, z.ZodObject<{
1586
1590
  access: z.ZodString;
1587
1591
  id: z.ZodString;
@@ -1605,6 +1609,7 @@ declare const scorecardConfig: z.ZodObject<{
1605
1609
  }, "strip", z.ZodTypeAny, {
1606
1610
  external: boolean;
1607
1611
  owner: string;
1612
+ public: string;
1608
1613
  users: Record<string, {
1609
1614
  id: string;
1610
1615
  access: string;
@@ -1616,6 +1621,7 @@ declare const scorecardConfig: z.ZodObject<{
1616
1621
  }, {
1617
1622
  external: boolean;
1618
1623
  owner: string;
1624
+ public: string;
1619
1625
  users: Record<string, {
1620
1626
  id: string;
1621
1627
  access: string;
@@ -1628,17 +1634,17 @@ declare const scorecardConfig: z.ZodObject<{
1628
1634
  }, "strip", z.ZodTypeAny, {
1629
1635
  id: string;
1630
1636
  options: {
1631
- legend: boolean;
1632
- title: boolean;
1633
- averageColumn: boolean;
1634
- averageDisplayType: "ALL" | "ABOVE_AVERAGE" | "BELOW_AVERAGE";
1635
- averageRow: boolean;
1636
- emptyRows: boolean;
1637
- highlightedIndicators: boolean;
1638
- itemNumber: boolean;
1639
- showHierarchy: boolean;
1640
- arrows: boolean;
1641
- showDataInRows: boolean;
1637
+ legend?: boolean | undefined;
1638
+ title?: boolean | undefined;
1639
+ averageColumn?: boolean | undefined;
1640
+ averageDisplayType?: "ALL" | "ABOVE_AVERAGE" | "BELOW_AVERAGE" | undefined;
1641
+ averageRow?: boolean | undefined;
1642
+ emptyRows?: boolean | undefined;
1643
+ highlightedIndicators?: boolean | undefined;
1644
+ itemNumber?: boolean | undefined;
1645
+ showHierarchy?: boolean | undefined;
1646
+ arrows?: boolean | undefined;
1647
+ showDataInRows?: boolean | undefined;
1642
1648
  disableExpanding?: boolean | undefined;
1643
1649
  };
1644
1650
  title: string;
@@ -1745,6 +1751,7 @@ declare const scorecardConfig: z.ZodObject<{
1745
1751
  sharing: {
1746
1752
  external: boolean;
1747
1753
  owner: string;
1754
+ public: string;
1748
1755
  users: Record<string, {
1749
1756
  id: string;
1750
1757
  access: string;
@@ -1761,17 +1768,17 @@ declare const scorecardConfig: z.ZodObject<{
1761
1768
  }, {
1762
1769
  id: string;
1763
1770
  options: {
1764
- legend: boolean;
1765
- title: boolean;
1766
- averageColumn: boolean;
1767
- averageDisplayType: "ALL" | "ABOVE_AVERAGE" | "BELOW_AVERAGE";
1768
- averageRow: boolean;
1769
- emptyRows: boolean;
1770
- highlightedIndicators: boolean;
1771
- itemNumber: boolean;
1772
- showHierarchy: boolean;
1773
- arrows: boolean;
1774
- showDataInRows: boolean;
1771
+ legend?: boolean | undefined;
1772
+ title?: boolean | undefined;
1773
+ averageColumn?: boolean | undefined;
1774
+ averageDisplayType?: "ALL" | "ABOVE_AVERAGE" | "BELOW_AVERAGE" | undefined;
1775
+ averageRow?: boolean | undefined;
1776
+ emptyRows?: boolean | undefined;
1777
+ highlightedIndicators?: boolean | undefined;
1778
+ itemNumber?: boolean | undefined;
1779
+ showHierarchy?: boolean | undefined;
1780
+ arrows?: boolean | undefined;
1781
+ showDataInRows?: boolean | undefined;
1775
1782
  disableExpanding?: boolean | undefined;
1776
1783
  };
1777
1784
  title: string;
@@ -1878,6 +1885,7 @@ declare const scorecardConfig: z.ZodObject<{
1878
1885
  sharing: {
1879
1886
  external: boolean;
1880
1887
  owner: string;
1888
+ public: string;
1881
1889
  users: Record<string, {
1882
1890
  id: string;
1883
1891
  access: string;
@@ -1947,60 +1955,60 @@ declare const scorecardStateSchema: z.ZodObject<{
1947
1955
  type?: string | undefined;
1948
1956
  }>;
1949
1957
  options: z.ZodObject<{
1950
- averageColumn: z.ZodBoolean;
1951
- averageDisplayType: z.ZodEnum<["ALL", "ABOVE_AVERAGE", "BELOW_AVERAGE"]>;
1952
- averageRow: z.ZodBoolean;
1953
- emptyRows: z.ZodBoolean;
1954
- highlightedIndicators: z.ZodBoolean;
1955
- itemNumber: z.ZodBoolean;
1956
- legend: z.ZodBoolean;
1957
- showHierarchy: z.ZodBoolean;
1958
- title: z.ZodBoolean;
1959
- arrows: z.ZodBoolean;
1960
- showDataInRows: z.ZodBoolean;
1958
+ averageColumn: z.ZodOptional<z.ZodBoolean>;
1959
+ averageDisplayType: z.ZodOptional<z.ZodEnum<["ALL", "ABOVE_AVERAGE", "BELOW_AVERAGE"]>>;
1960
+ averageRow: z.ZodOptional<z.ZodBoolean>;
1961
+ emptyRows: z.ZodOptional<z.ZodBoolean>;
1962
+ highlightedIndicators: z.ZodOptional<z.ZodBoolean>;
1963
+ itemNumber: z.ZodOptional<z.ZodBoolean>;
1964
+ legend: z.ZodOptional<z.ZodBoolean>;
1965
+ showHierarchy: z.ZodOptional<z.ZodBoolean>;
1966
+ title: z.ZodOptional<z.ZodBoolean>;
1967
+ arrows: z.ZodOptional<z.ZodBoolean>;
1968
+ showDataInRows: z.ZodOptional<z.ZodBoolean>;
1961
1969
  disableExpanding: z.ZodOptional<z.ZodBoolean>;
1962
1970
  }, "strip", z.ZodTypeAny, {
1963
- legend: boolean;
1964
- title: boolean;
1965
- averageColumn: boolean;
1966
- averageDisplayType: "ALL" | "ABOVE_AVERAGE" | "BELOW_AVERAGE";
1967
- averageRow: boolean;
1968
- emptyRows: boolean;
1969
- highlightedIndicators: boolean;
1970
- itemNumber: boolean;
1971
- showHierarchy: boolean;
1972
- arrows: boolean;
1973
- showDataInRows: boolean;
1971
+ legend?: boolean | undefined;
1972
+ title?: boolean | undefined;
1973
+ averageColumn?: boolean | undefined;
1974
+ averageDisplayType?: "ALL" | "ABOVE_AVERAGE" | "BELOW_AVERAGE" | undefined;
1975
+ averageRow?: boolean | undefined;
1976
+ emptyRows?: boolean | undefined;
1977
+ highlightedIndicators?: boolean | undefined;
1978
+ itemNumber?: boolean | undefined;
1979
+ showHierarchy?: boolean | undefined;
1980
+ arrows?: boolean | undefined;
1981
+ showDataInRows?: boolean | undefined;
1974
1982
  disableExpanding?: boolean | undefined;
1975
1983
  }, {
1976
- legend: boolean;
1977
- title: boolean;
1978
- averageColumn: boolean;
1979
- averageDisplayType: "ALL" | "ABOVE_AVERAGE" | "BELOW_AVERAGE";
1980
- averageRow: boolean;
1981
- emptyRows: boolean;
1982
- highlightedIndicators: boolean;
1983
- itemNumber: boolean;
1984
- showHierarchy: boolean;
1985
- arrows: boolean;
1986
- showDataInRows: boolean;
1984
+ legend?: boolean | undefined;
1985
+ title?: boolean | undefined;
1986
+ averageColumn?: boolean | undefined;
1987
+ averageDisplayType?: "ALL" | "ABOVE_AVERAGE" | "BELOW_AVERAGE" | undefined;
1988
+ averageRow?: boolean | undefined;
1989
+ emptyRows?: boolean | undefined;
1990
+ highlightedIndicators?: boolean | undefined;
1991
+ itemNumber?: boolean | undefined;
1992
+ showHierarchy?: boolean | undefined;
1993
+ arrows?: boolean | undefined;
1994
+ showDataInRows?: boolean | undefined;
1987
1995
  disableExpanding?: boolean | undefined;
1988
1996
  }>;
1989
1997
  nested: z.ZodOptional<z.ZodBoolean>;
1990
1998
  hasOnePeriod: z.ZodOptional<z.ZodBoolean>;
1991
1999
  }, "strip", z.ZodTypeAny, {
1992
2000
  options: {
1993
- legend: boolean;
1994
- title: boolean;
1995
- averageColumn: boolean;
1996
- averageDisplayType: "ALL" | "ABOVE_AVERAGE" | "BELOW_AVERAGE";
1997
- averageRow: boolean;
1998
- emptyRows: boolean;
1999
- highlightedIndicators: boolean;
2000
- itemNumber: boolean;
2001
- showHierarchy: boolean;
2002
- arrows: boolean;
2003
- showDataInRows: boolean;
2001
+ legend?: boolean | undefined;
2002
+ title?: boolean | undefined;
2003
+ averageColumn?: boolean | undefined;
2004
+ averageDisplayType?: "ALL" | "ABOVE_AVERAGE" | "BELOW_AVERAGE" | undefined;
2005
+ averageRow?: boolean | undefined;
2006
+ emptyRows?: boolean | undefined;
2007
+ highlightedIndicators?: boolean | undefined;
2008
+ itemNumber?: boolean | undefined;
2009
+ showHierarchy?: boolean | undefined;
2010
+ arrows?: boolean | undefined;
2011
+ showDataInRows?: boolean | undefined;
2004
2012
  disableExpanding?: boolean | undefined;
2005
2013
  };
2006
2014
  orgUnitSelection: {
@@ -2023,17 +2031,17 @@ declare const scorecardStateSchema: z.ZodObject<{
2023
2031
  hasOnePeriod?: boolean | undefined;
2024
2032
  }, {
2025
2033
  options: {
2026
- legend: boolean;
2027
- title: boolean;
2028
- averageColumn: boolean;
2029
- averageDisplayType: "ALL" | "ABOVE_AVERAGE" | "BELOW_AVERAGE";
2030
- averageRow: boolean;
2031
- emptyRows: boolean;
2032
- highlightedIndicators: boolean;
2033
- itemNumber: boolean;
2034
- showHierarchy: boolean;
2035
- arrows: boolean;
2036
- showDataInRows: boolean;
2034
+ legend?: boolean | undefined;
2035
+ title?: boolean | undefined;
2036
+ averageColumn?: boolean | undefined;
2037
+ averageDisplayType?: "ALL" | "ABOVE_AVERAGE" | "BELOW_AVERAGE" | undefined;
2038
+ averageRow?: boolean | undefined;
2039
+ emptyRows?: boolean | undefined;
2040
+ highlightedIndicators?: boolean | undefined;
2041
+ itemNumber?: boolean | undefined;
2042
+ showHierarchy?: boolean | undefined;
2043
+ arrows?: boolean | undefined;
2044
+ showDataInRows?: boolean | undefined;
2037
2045
  disableExpanding?: boolean | undefined;
2038
2046
  };
2039
2047
  orgUnitSelection: {
@@ -1 +1 @@
1
- {"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../../../../src/components/Scorecard/schemas/config.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,uBAAuB,CAAC;AAErD,eAAO,MAAM,oBAAoB,qGAO/B,CAAC;AAEH,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAW3B,CAAC;AAEH,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAEhE,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC;AAExE,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;EAKjC,CAAC;AAEH,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,sBAAsB,CAAC,C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js",
5
5
  "module": "./dist/esm/index.js",
6
6
  "types": "./dist/types/index.d.ts",
@@ -44,8 +44,8 @@
44
44
  "tsup": "^8.0.1",
45
45
  "typescript": "^5.3.3",
46
46
  "usehooks-ts": "^2.9.2",
47
- "@repo/eslint-config": "0.0.0",
48
- "@repo/typescript-config": "0.0.0"
47
+ "@repo/typescript-config": "0.0.0",
48
+ "@repo/eslint-config": "0.0.0"
49
49
  },
50
50
  "dependencies": {
51
51
  "@dnd-kit/core": "^6.1.0",
@@ -69,7 +69,7 @@
69
69
  "react-spring": "^9.6.1",
70
70
  "screenfull": "^6.0.2",
71
71
  "zod": "^3.23.8",
72
- "@hisptz/dhis2-ui": "2.0.20",
72
+ "@hisptz/dhis2-ui": "2.0.21",
73
73
  "@hisptz/dhis2-utils": "2.0.7"
74
74
  },
75
75
  "peerDependencies": {