@genspectrum/dashboard-components 0.4.3 → 0.4.5

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.
Files changed (35) hide show
  1. package/custom-elements.json +145 -12
  2. package/dist/dashboard-components.js +232 -149
  3. package/dist/dashboard-components.js.map +1 -1
  4. package/dist/genspectrum-components.d.ts +33 -0
  5. package/package.json +1 -1
  6. package/src/preact/aggregatedData/aggregate-table.tsx +3 -2
  7. package/src/preact/aggregatedData/aggregate.stories.tsx +6 -0
  8. package/src/preact/aggregatedData/aggregate.tsx +28 -6
  9. package/src/preact/components/table.stories.tsx +51 -1
  10. package/src/preact/components/table.tsx +4 -3
  11. package/src/preact/locationFilter/location-filter.stories.tsx +12 -1
  12. package/src/preact/locationFilter/location-filter.tsx +10 -3
  13. package/src/preact/mutationComparison/mutation-comparison-table.tsx +7 -2
  14. package/src/preact/mutationComparison/mutation-comparison.stories.tsx +3 -0
  15. package/src/preact/mutationComparison/mutation-comparison.tsx +25 -3
  16. package/src/preact/mutations/mutations-grid.tsx +8 -2
  17. package/src/preact/mutations/mutations-insertions-table.tsx +3 -2
  18. package/src/preact/mutations/mutations-table.tsx +3 -2
  19. package/src/preact/mutations/mutations.stories.tsx +3 -0
  20. package/src/preact/mutations/mutations.tsx +16 -6
  21. package/src/preact/prevalenceOverTime/prevalence-over-time-table.tsx +3 -2
  22. package/src/preact/prevalenceOverTime/prevalence-over-time.stories.tsx +4 -0
  23. package/src/preact/prevalenceOverTime/prevalence-over-time.tsx +8 -1
  24. package/src/query/queryAggregateData.spec.ts +117 -3
  25. package/src/query/queryAggregateData.ts +31 -2
  26. package/src/web-components/input/gs-location-filter.stories.ts +11 -0
  27. package/src/web-components/input/gs-location-filter.tsx +14 -1
  28. package/src/web-components/visualization/gs-aggregate.stories.ts +15 -0
  29. package/src/web-components/visualization/gs-aggregate.tsx +23 -0
  30. package/src/web-components/visualization/gs-mutation-comparison.stories.ts +4 -0
  31. package/src/web-components/visualization/gs-mutation-comparison.tsx +8 -0
  32. package/src/web-components/visualization/gs-mutations.stories.ts +4 -0
  33. package/src/web-components/visualization/gs-mutations.tsx +8 -0
  34. package/src/web-components/visualization/gs-prevalence-over-time.stories.ts +5 -0
  35. package/src/web-components/visualization/gs-prevalence-over-time.tsx +12 -4
@@ -53,16 +53,16 @@ export class PrevalenceOverTimeComponent extends PreactLitAdapterWithGridJsStyle
53
53
  * which will be used as the label for the variant in the views,
54
54
  * or an array of such objects.
55
55
  */
56
- @property({type: Object})
56
+ @property({ type: Object })
57
57
  numerator:
58
58
  {
59
59
  lapisFilter: Record<string, string | number | null | boolean>;
60
60
  displayName: string;
61
61
  }
62
62
  | {
63
- lapisFilter: Record<string, string | number | null | boolean>;
64
- displayName: string;
65
- }[] = { displayName: '', lapisFilter: {} };
63
+ lapisFilter: Record<string, string | number | null | boolean>;
64
+ displayName: string;
65
+ }[] = { displayName: '', lapisFilter: {} };
66
66
 
67
67
  /**
68
68
  * Required.
@@ -136,6 +136,13 @@ export class PrevalenceOverTimeComponent extends PreactLitAdapterWithGridJsStyle
136
136
  @property({ type: String })
137
137
  lapisDateField: string = 'date';
138
138
 
139
+ /**
140
+ * The maximum number of rows to display in the table view.
141
+ * Set to `false` to disable pagination. Set to `true` to enable pagination with a default limit (10).
142
+ */
143
+ @property({ type: Object })
144
+ pageSize: boolean | number = false;
145
+
139
146
  override render() {
140
147
  return (
141
148
  <PrevalenceOverTime
@@ -149,6 +156,7 @@ export class PrevalenceOverTimeComponent extends PreactLitAdapterWithGridJsStyle
149
156
  height={this.height}
150
157
  headline={this.headline}
151
158
  lapisDateField={this.lapisDateField}
159
+ pageSize={this.pageSize}
152
160
  />
153
161
  );
154
162
  }