@genome-spy/core 0.70.0 → 0.72.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (280) hide show
  1. package/dist/bundle/index.es.js +3923 -3598
  2. package/dist/bundle/index.js +150 -143
  3. package/dist/bundle/parquetRead-BnAGCa4_.js +1663 -0
  4. package/dist/schema.json +0 -48
  5. package/dist/src/data/formats/parquet.d.ts +12 -0
  6. package/dist/src/data/formats/parquet.d.ts.map +1 -0
  7. package/dist/src/data/formats/parquet.js +29 -0
  8. package/dist/src/data/formats/parquetRead.d.ts +18 -0
  9. package/dist/src/data/formats/parquetRead.d.ts.map +1 -0
  10. package/dist/src/data/formats/parquetRead.js +326 -0
  11. package/dist/src/data/sources/urlSource.d.ts.map +1 -1
  12. package/dist/src/data/sources/urlSource.js +8 -3
  13. package/dist/src/encoder/encoder.d.ts +2 -2
  14. package/dist/src/fonts/bmFontManager.d.ts +1 -1
  15. package/dist/src/genome/genome.d.ts +1 -1
  16. package/dist/src/genomeSpy/containerUi.d.ts.map +1 -1
  17. package/dist/src/genomeSpy/containerUi.js +0 -1
  18. package/dist/src/genomeSpy/viewHighlight.js +2 -2
  19. package/dist/src/genomeSpy.d.ts +3 -3
  20. package/dist/src/genomeSpy.d.ts.map +1 -1
  21. package/dist/src/genomeSpy.js +29 -3
  22. package/dist/src/gl/hashTable.d.ts +78 -0
  23. package/dist/src/gl/hashTable.d.ts.map +1 -0
  24. package/dist/src/gl/hashTable.js +164 -0
  25. package/dist/src/gl/includes/common.glsl.js +1 -1
  26. package/dist/src/gl/webGLHelper.d.ts.map +1 -1
  27. package/dist/src/gl/webGLHelper.js +12 -6
  28. package/dist/src/marks/mark.d.ts +2 -2
  29. package/dist/src/marks/mark.d.ts.map +1 -1
  30. package/dist/src/marks/mark.js +2 -3
  31. package/dist/src/spec/view.d.ts +0 -10
  32. package/dist/src/utils/keyboardZoomMotion.d.ts +93 -0
  33. package/dist/src/utils/keyboardZoomMotion.d.ts.map +1 -0
  34. package/dist/src/utils/keyboardZoomMotion.js +285 -0
  35. package/dist/src/utils/radixSort.d.ts.map +1 -1
  36. package/dist/src/utils/radixSort.js +26 -1
  37. package/dist/src/view/axisGridView.d.ts +1 -1
  38. package/dist/src/view/axisGridView.js +0 -1
  39. package/dist/src/view/axisView.d.ts +1 -1
  40. package/dist/src/view/concatView.d.ts +6 -3
  41. package/dist/src/view/concatView.d.ts.map +1 -1
  42. package/dist/src/view/concatView.js +9 -2
  43. package/dist/src/view/containerMutationHelper.d.ts +6 -6
  44. package/dist/src/view/containerMutationHelper.d.ts.map +1 -1
  45. package/dist/src/view/containerView.d.ts +7 -5
  46. package/dist/src/view/containerView.d.ts.map +1 -1
  47. package/dist/src/view/containerView.js +4 -1
  48. package/dist/src/view/facetView.d.ts +2 -2
  49. package/dist/src/view/flowBuilder.d.ts +1 -1
  50. package/dist/src/view/flowBuilder.d.ts.map +1 -1
  51. package/dist/src/view/gridView/gridChild.d.ts +3 -3
  52. package/dist/src/view/gridView/gridChild.d.ts.map +1 -1
  53. package/dist/src/view/gridView/gridChild.js +0 -2
  54. package/dist/src/view/gridView/gridView.d.ts +13 -11
  55. package/dist/src/view/gridView/gridView.d.ts.map +1 -1
  56. package/dist/src/view/gridView/gridView.js +17 -26
  57. package/dist/src/view/gridView/keyboardZoomController.d.ts +21 -0
  58. package/dist/src/view/gridView/keyboardZoomController.d.ts.map +1 -0
  59. package/dist/src/view/gridView/keyboardZoomController.js +202 -0
  60. package/dist/src/view/gridView/scrollbar.d.ts +1 -1
  61. package/dist/src/view/gridView/scrollbar.d.ts.map +1 -1
  62. package/dist/src/view/gridView/scrollbar.js +0 -1
  63. package/dist/src/view/gridView/selectionRect.d.ts +1 -1
  64. package/dist/src/view/gridView/selectionRect.d.ts.map +1 -1
  65. package/dist/src/view/gridView/selectionRect.js +0 -1
  66. package/dist/src/view/gridView/separatorView.js +0 -1
  67. package/dist/src/view/gridView/zoomNavigationUtils.d.ts +19 -0
  68. package/dist/src/view/gridView/zoomNavigationUtils.d.ts.map +1 -0
  69. package/dist/src/view/gridView/zoomNavigationUtils.js +51 -0
  70. package/dist/src/view/layerView.d.ts +8 -5
  71. package/dist/src/view/layerView.d.ts.map +1 -1
  72. package/dist/src/view/layerView.js +6 -2
  73. package/dist/src/view/title.d.ts.map +1 -1
  74. package/dist/src/view/title.js +0 -1
  75. package/dist/src/view/unitView.d.ts +8 -5
  76. package/dist/src/view/unitView.d.ts.map +1 -1
  77. package/dist/src/view/unitView.js +5 -1
  78. package/dist/src/view/view.d.ts +13 -9
  79. package/dist/src/view/view.d.ts.map +1 -1
  80. package/dist/src/view/view.js +7 -1
  81. package/dist/src/view/viewError.d.ts +1 -1
  82. package/dist/src/view/viewError.d.ts.map +1 -1
  83. package/dist/src/view/viewFactory.d.ts +3 -44
  84. package/dist/src/view/viewFactory.d.ts.map +1 -1
  85. package/dist/src/view/viewFactory.js +28 -69
  86. package/dist/src/view/viewSelectors.d.ts.map +1 -1
  87. package/dist/src/view/viewSelectors.js +123 -160
  88. package/dist/src/view/viewSpecGuards.d.ts +43 -0
  89. package/dist/src/view/viewSpecGuards.d.ts.map +1 -0
  90. package/dist/src/view/viewSpecGuards.js +69 -0
  91. package/dist/src/view/viewUtils.d.ts +1 -1
  92. package/dist/src/view/viewUtils.d.ts.map +1 -1
  93. package/dist/src/view/zoom.d.ts +1 -0
  94. package/dist/src/view/zoom.d.ts.map +1 -1
  95. package/dist/src/view/zoom.js +5 -1
  96. package/package.json +4 -3
  97. package/dist/src/data/collector.test.d.ts +0 -2
  98. package/dist/src/data/collector.test.d.ts.map +0 -1
  99. package/dist/src/data/dataFlow.test.d.ts +0 -2
  100. package/dist/src/data/dataFlow.test.d.ts.map +0 -1
  101. package/dist/src/data/flow.test.d.ts +0 -2
  102. package/dist/src/data/flow.test.d.ts.map +0 -1
  103. package/dist/src/data/flowInit.test.d.ts +0 -2
  104. package/dist/src/data/flowInit.test.d.ts.map +0 -1
  105. package/dist/src/data/flowNode.test.d.ts +0 -2
  106. package/dist/src/data/flowNode.test.d.ts.map +0 -1
  107. package/dist/src/data/flowOptimizer.test.d.ts +0 -2
  108. package/dist/src/data/flowOptimizer.test.d.ts.map +0 -1
  109. package/dist/src/data/formats/fasta.test.d.ts +0 -2
  110. package/dist/src/data/formats/fasta.test.d.ts.map +0 -1
  111. package/dist/src/data/keyIndex.test.d.ts +0 -2
  112. package/dist/src/data/keyIndex.test.d.ts.map +0 -1
  113. package/dist/src/data/sources/inlineSource.test.d.ts +0 -2
  114. package/dist/src/data/sources/inlineSource.test.d.ts.map +0 -1
  115. package/dist/src/data/sources/sequenceSource.test.d.ts +0 -2
  116. package/dist/src/data/sources/sequenceSource.test.d.ts.map +0 -1
  117. package/dist/src/data/transforms/aggregate.test.d.ts +0 -2
  118. package/dist/src/data/transforms/aggregate.test.d.ts.map +0 -1
  119. package/dist/src/data/transforms/clone.test.d.ts +0 -2
  120. package/dist/src/data/transforms/clone.test.d.ts.map +0 -1
  121. package/dist/src/data/transforms/coverage.test.d.ts +0 -2
  122. package/dist/src/data/transforms/coverage.test.d.ts.map +0 -1
  123. package/dist/src/data/transforms/filter.test.d.ts +0 -2
  124. package/dist/src/data/transforms/filter.test.d.ts.map +0 -1
  125. package/dist/src/data/transforms/filterScoredLabels.test.d.ts +0 -2
  126. package/dist/src/data/transforms/filterScoredLabels.test.d.ts.map +0 -1
  127. package/dist/src/data/transforms/flatten.test.d.ts +0 -2
  128. package/dist/src/data/transforms/flatten.test.d.ts.map +0 -1
  129. package/dist/src/data/transforms/flattenDelimited.test.d.ts +0 -2
  130. package/dist/src/data/transforms/flattenDelimited.test.d.ts.map +0 -1
  131. package/dist/src/data/transforms/flattenSequence.test.d.ts +0 -2
  132. package/dist/src/data/transforms/flattenSequence.test.d.ts.map +0 -1
  133. package/dist/src/data/transforms/formula.test.d.ts +0 -2
  134. package/dist/src/data/transforms/formula.test.d.ts.map +0 -1
  135. package/dist/src/data/transforms/identifier.test.d.ts +0 -2
  136. package/dist/src/data/transforms/identifier.test.d.ts.map +0 -1
  137. package/dist/src/data/transforms/pileup.test.d.ts +0 -2
  138. package/dist/src/data/transforms/pileup.test.d.ts.map +0 -1
  139. package/dist/src/data/transforms/project.test.d.ts +0 -2
  140. package/dist/src/data/transforms/project.test.d.ts.map +0 -1
  141. package/dist/src/data/transforms/regexExtract.test.d.ts +0 -2
  142. package/dist/src/data/transforms/regexExtract.test.d.ts.map +0 -1
  143. package/dist/src/data/transforms/regexFold.test.d.ts +0 -2
  144. package/dist/src/data/transforms/regexFold.test.d.ts.map +0 -1
  145. package/dist/src/data/transforms/sample.test.d.ts +0 -2
  146. package/dist/src/data/transforms/sample.test.d.ts.map +0 -1
  147. package/dist/src/data/transforms/stack.test.d.ts +0 -2
  148. package/dist/src/data/transforms/stack.test.d.ts.map +0 -1
  149. package/dist/src/encoder/accessor.test.d.ts +0 -2
  150. package/dist/src/encoder/accessor.test.d.ts.map +0 -1
  151. package/dist/src/encoder/encoder.test.d.ts +0 -2
  152. package/dist/src/encoder/encoder.test.d.ts.map +0 -1
  153. package/dist/src/encoder/metadataChannels.test.d.ts +0 -2
  154. package/dist/src/encoder/metadataChannels.test.d.ts.map +0 -1
  155. package/dist/src/genome/genome.test.d.ts +0 -2
  156. package/dist/src/genome/genome.test.d.ts.map +0 -1
  157. package/dist/src/genome/genomes.test.d.ts +0 -2
  158. package/dist/src/genome/genomes.test.d.ts.map +0 -1
  159. package/dist/src/genome/scaleIndex.test.d.ts +0 -2
  160. package/dist/src/genome/scaleIndex.test.d.ts.map +0 -1
  161. package/dist/src/genome/scaleLocus.test.d.ts +0 -2
  162. package/dist/src/genome/scaleLocus.test.d.ts.map +0 -1
  163. package/dist/src/genomeSpy/viewDataInit.test.d.ts +0 -2
  164. package/dist/src/genomeSpy/viewDataInit.test.d.ts.map +0 -1
  165. package/dist/src/gl/colorUtils.test.d.ts +0 -2
  166. package/dist/src/gl/colorUtils.test.d.ts.map +0 -1
  167. package/dist/src/paramRuntime/expressionRef.test.d.ts +0 -2
  168. package/dist/src/paramRuntime/expressionRef.test.d.ts.map +0 -1
  169. package/dist/src/paramRuntime/graphRuntime.test.d.ts +0 -2
  170. package/dist/src/paramRuntime/graphRuntime.test.d.ts.map +0 -1
  171. package/dist/src/paramRuntime/paramRuntime.test.d.ts +0 -2
  172. package/dist/src/paramRuntime/paramRuntime.test.d.ts.map +0 -1
  173. package/dist/src/paramRuntime/paramStore.test.d.ts +0 -2
  174. package/dist/src/paramRuntime/paramStore.test.d.ts.map +0 -1
  175. package/dist/src/scale/scale.test.d.ts +0 -2
  176. package/dist/src/scale/scale.test.d.ts.map +0 -1
  177. package/dist/src/scale/ticks.test.d.ts +0 -2
  178. package/dist/src/scale/ticks.test.d.ts.map +0 -1
  179. package/dist/src/scales/axisResolution.test.d.ts +0 -2
  180. package/dist/src/scales/axisResolution.test.d.ts.map +0 -1
  181. package/dist/src/scales/domainPlanner.test.d.ts +0 -2
  182. package/dist/src/scales/domainPlanner.test.d.ts.map +0 -1
  183. package/dist/src/scales/scaleInstanceManager.test.d.ts +0 -2
  184. package/dist/src/scales/scaleInstanceManager.test.d.ts.map +0 -1
  185. package/dist/src/scales/scaleInteractionController.test.d.ts +0 -2
  186. package/dist/src/scales/scaleInteractionController.test.d.ts.map +0 -1
  187. package/dist/src/scales/scaleResolution.test.d.ts +0 -2
  188. package/dist/src/scales/scaleResolution.test.d.ts.map +0 -1
  189. package/dist/src/scales/scaleRules.test.d.ts +0 -2
  190. package/dist/src/scales/scaleRules.test.d.ts.map +0 -1
  191. package/dist/src/selection/selection.test.d.ts +0 -2
  192. package/dist/src/selection/selection.test.d.ts.map +0 -1
  193. package/dist/src/tooltip/dataTooltipHandler.test.d.ts +0 -2
  194. package/dist/src/tooltip/dataTooltipHandler.test.d.ts.map +0 -1
  195. package/dist/src/tooltip/flattenDatumRows.test.d.ts +0 -2
  196. package/dist/src/tooltip/flattenDatumRows.test.d.ts.map +0 -1
  197. package/dist/src/tooltip/tooltipContext.test.d.ts +0 -2
  198. package/dist/src/tooltip/tooltipContext.test.d.ts.map +0 -1
  199. package/dist/src/utils/addBaseUrl.test.d.ts +0 -2
  200. package/dist/src/utils/addBaseUrl.test.d.ts.map +0 -1
  201. package/dist/src/utils/binnedIndex.test.d.ts +0 -2
  202. package/dist/src/utils/binnedIndex.test.d.ts.map +0 -1
  203. package/dist/src/utils/cloner.test.d.ts +0 -2
  204. package/dist/src/utils/cloner.test.d.ts.map +0 -1
  205. package/dist/src/utils/coalesce.test.d.ts +0 -2
  206. package/dist/src/utils/coalesce.test.d.ts.map +0 -1
  207. package/dist/src/utils/concatIterables.test.d.ts +0 -2
  208. package/dist/src/utils/concatIterables.test.d.ts.map +0 -1
  209. package/dist/src/utils/deepEqual.test.d.ts +0 -2
  210. package/dist/src/utils/deepEqual.test.d.ts.map +0 -1
  211. package/dist/src/utils/domainArray.test.d.ts +0 -2
  212. package/dist/src/utils/domainArray.test.d.ts.map +0 -1
  213. package/dist/src/utils/fetchUtils.test.d.ts +0 -2
  214. package/dist/src/utils/fetchUtils.test.d.ts.map +0 -1
  215. package/dist/src/utils/indexer.test.d.ts +0 -2
  216. package/dist/src/utils/indexer.test.d.ts.map +0 -1
  217. package/dist/src/utils/interactionEvent.test.d.ts +0 -2
  218. package/dist/src/utils/interactionEvent.test.d.ts.map +0 -1
  219. package/dist/src/utils/iterateNestedMaps.test.d.ts +0 -2
  220. package/dist/src/utils/iterateNestedMaps.test.d.ts.map +0 -1
  221. package/dist/src/utils/kWayMerge.test.d.ts +0 -2
  222. package/dist/src/utils/kWayMerge.test.d.ts.map +0 -1
  223. package/dist/src/utils/mergeObjects.test.d.ts +0 -2
  224. package/dist/src/utils/mergeObjects.test.d.ts.map +0 -1
  225. package/dist/src/utils/numberExtractor.test.d.ts +0 -2
  226. package/dist/src/utils/numberExtractor.test.d.ts.map +0 -1
  227. package/dist/src/utils/propertyCacher.test.d.ts +0 -2
  228. package/dist/src/utils/propertyCacher.test.d.ts.map +0 -1
  229. package/dist/src/utils/propertyCoalescer.test.d.ts +0 -2
  230. package/dist/src/utils/propertyCoalescer.test.d.ts.map +0 -1
  231. package/dist/src/utils/radixSort.test.d.ts +0 -2
  232. package/dist/src/utils/radixSort.test.d.ts.map +0 -1
  233. package/dist/src/utils/reservationMap.test.d.ts +0 -2
  234. package/dist/src/utils/reservationMap.test.d.ts.map +0 -1
  235. package/dist/src/utils/ringBuffer.test.d.ts +0 -2
  236. package/dist/src/utils/ringBuffer.test.d.ts.map +0 -1
  237. package/dist/src/utils/throttle.test.d.ts +0 -2
  238. package/dist/src/utils/throttle.test.d.ts.map +0 -1
  239. package/dist/src/utils/topK.test.d.ts +0 -2
  240. package/dist/src/utils/topK.test.d.ts.map +0 -1
  241. package/dist/src/utils/trees.test.d.ts +0 -2
  242. package/dist/src/utils/trees.test.d.ts.map +0 -1
  243. package/dist/src/utils/ui/tooltip.test.d.ts +0 -2
  244. package/dist/src/utils/ui/tooltip.test.d.ts.map +0 -1
  245. package/dist/src/utils/url.test.d.ts +0 -2
  246. package/dist/src/utils/url.test.d.ts.map +0 -1
  247. package/dist/src/utils/variableTools.test.d.ts +0 -2
  248. package/dist/src/utils/variableTools.test.d.ts.map +0 -1
  249. package/dist/src/view/concatView.test.d.ts +0 -2
  250. package/dist/src/view/concatView.test.d.ts.map +0 -1
  251. package/dist/src/view/dataReadiness.test.d.ts +0 -2
  252. package/dist/src/view/dataReadiness.test.d.ts.map +0 -1
  253. package/dist/src/view/flowBuilder.test.d.ts +0 -2
  254. package/dist/src/view/flowBuilder.test.d.ts.map +0 -1
  255. package/dist/src/view/gridView/gridView.test.d.ts +0 -2
  256. package/dist/src/view/gridView/gridView.test.d.ts.map +0 -1
  257. package/dist/src/view/gridView/selectionRect.test.d.ts +0 -2
  258. package/dist/src/view/gridView/selectionRect.test.d.ts.map +0 -1
  259. package/dist/src/view/layerView.test.d.ts +0 -2
  260. package/dist/src/view/layerView.test.d.ts.map +0 -1
  261. package/dist/src/view/layout/flexLayout.test.d.ts +0 -2
  262. package/dist/src/view/layout/flexLayout.test.d.ts.map +0 -1
  263. package/dist/src/view/layout/grid.test.d.ts +0 -2
  264. package/dist/src/view/layout/grid.test.d.ts.map +0 -1
  265. package/dist/src/view/layout/rectangle.test.d.ts +0 -2
  266. package/dist/src/view/layout/rectangle.test.d.ts.map +0 -1
  267. package/dist/src/view/multiscale.test.d.ts +0 -2
  268. package/dist/src/view/multiscale.test.d.ts.map +0 -1
  269. package/dist/src/view/view.test.d.ts +0 -2
  270. package/dist/src/view/view.test.d.ts.map +0 -1
  271. package/dist/src/view/viewDispose.test.d.ts +0 -2
  272. package/dist/src/view/viewDispose.test.d.ts.map +0 -1
  273. package/dist/src/view/viewFactory.test.d.ts +0 -2
  274. package/dist/src/view/viewFactory.test.d.ts.map +0 -1
  275. package/dist/src/view/viewParamRuntime.test.d.ts +0 -2
  276. package/dist/src/view/viewParamRuntime.test.d.ts.map +0 -1
  277. package/dist/src/view/viewSelectors.test.d.ts +0 -2
  278. package/dist/src/view/viewSelectors.test.d.ts.map +0 -1
  279. package/dist/src/view/viewUtils.test.d.ts +0 -2
  280. package/dist/src/view/viewUtils.test.d.ts.map +0 -1
package/dist/schema.json CHANGED
@@ -997,10 +997,6 @@
997
997
  },
998
998
  "type": "array"
999
999
  },
1000
- "configurableVisibility": {
1001
- "description": "Is the visibility configurable interactively from the [GenomeSpy App](https://genomespy.app/docs/sample-collections/). Configurability requires that the view has an explicitly specified name that is unique within its import scope.\n\n**Default:** `false` for children of `layer`, `true` for others.",
1002
- "type": "boolean"
1003
- },
1004
1000
  "data": {
1005
1001
  "$ref": "#/definitions/Data",
1006
1002
  "description": "Specifies a [data source](https://genomespy.app/docs/grammar/data/). If omitted, the data source is inherited from the parent view."
@@ -1571,10 +1567,6 @@
1571
1567
  "description": "The base URL for relative URL data sources and URL [imports](https://genomespy.app/docs/grammar/import/#importing-from-a-url). The base URLs are inherited in the view hierarchy unless overridden with this property. By default, the top-level view's base URL equals to the visualization specification's base URL.",
1572
1568
  "type": "string"
1573
1569
  },
1574
- "configurableVisibility": {
1575
- "description": "Is the visibility configurable interactively from the [GenomeSpy App](https://genomespy.app/docs/sample-collections/). Configurability requires that the view has an explicitly specified name that is unique within its import scope.\n\n**Default:** `false` for children of `layer`, `true` for others.",
1576
- "type": "boolean"
1577
- },
1578
1570
  "data": {
1579
1571
  "$ref": "#/definitions/Data",
1580
1572
  "description": "Specifies a [data source](https://genomespy.app/docs/grammar/data/). If omitted, the data source is inherited from the parent view."
@@ -1927,10 +1919,6 @@
1927
1919
  "description": "The base URL for relative URL data sources and URL [imports](https://genomespy.app/docs/grammar/import/#importing-from-a-url). The base URLs are inherited in the view hierarchy unless overridden with this property. By default, the top-level view's base URL equals to the visualization specification's base URL.",
1928
1920
  "type": "string"
1929
1921
  },
1930
- "configurableVisibility": {
1931
- "description": "Is the visibility configurable interactively from the [GenomeSpy App](https://genomespy.app/docs/sample-collections/). Configurability requires that the view has an explicitly specified name that is unique within its import scope.\n\n**Default:** `false` for children of `layer`, `true` for others.",
1932
- "type": "boolean"
1933
- },
1934
1922
  "data": {
1935
1923
  "$ref": "#/definitions/Data",
1936
1924
  "description": "Specifies a [data source](https://genomespy.app/docs/grammar/data/). If omitted, the data source is inherited from the parent view."
@@ -2290,10 +2278,6 @@
2290
2278
  "description": "The base URL for relative URL data sources and URL [imports](https://genomespy.app/docs/grammar/import/#importing-from-a-url). The base URLs are inherited in the view hierarchy unless overridden with this property. By default, the top-level view's base URL equals to the visualization specification's base URL.",
2291
2279
  "type": "string"
2292
2280
  },
2293
- "configurableVisibility": {
2294
- "description": "Is the visibility configurable interactively from the [GenomeSpy App](https://genomespy.app/docs/sample-collections/). Configurability requires that the view has an explicitly specified name that is unique within its import scope.\n\n**Default:** `false` for children of `layer`, `true` for others.",
2295
- "type": "boolean"
2296
- },
2297
2281
  "data": {
2298
2282
  "$ref": "#/definitions/Data",
2299
2283
  "description": "Specifies a [data source](https://genomespy.app/docs/grammar/data/). If omitted, the data source is inherited from the parent view."
@@ -2658,10 +2642,6 @@
2658
2642
  "description": "The base URL for relative URL data sources and URL [imports](https://genomespy.app/docs/grammar/import/#importing-from-a-url). The base URLs are inherited in the view hierarchy unless overridden with this property. By default, the top-level view's base URL equals to the visualization specification's base URL.",
2659
2643
  "type": "string"
2660
2644
  },
2661
- "configurableVisibility": {
2662
- "description": "Is the visibility configurable interactively from the [GenomeSpy App](https://genomespy.app/docs/sample-collections/). Configurability requires that the view has an explicitly specified name that is unique within its import scope.\n\n**Default:** `false` for children of `layer`, `true` for others.",
2663
- "type": "boolean"
2664
- },
2665
2645
  "data": {
2666
2646
  "$ref": "#/definitions/Data",
2667
2647
  "description": "Specifies a [data source](https://genomespy.app/docs/grammar/data/). If omitted, the data source is inherited from the parent view."
@@ -3023,10 +3003,6 @@
3023
3003
  "description": "The base URL for relative URL data sources and URL [imports](https://genomespy.app/docs/grammar/import/#importing-from-a-url). The base URLs are inherited in the view hierarchy unless overridden with this property. By default, the top-level view's base URL equals to the visualization specification's base URL.",
3024
3004
  "type": "string"
3025
3005
  },
3026
- "configurableVisibility": {
3027
- "description": "Is the visibility configurable interactively from the [GenomeSpy App](https://genomespy.app/docs/sample-collections/). Configurability requires that the view has an explicitly specified name that is unique within its import scope.\n\n**Default:** `false` for children of `layer`, `true` for others.",
3028
- "type": "boolean"
3029
- },
3030
3006
  "data": {
3031
3007
  "$ref": "#/definitions/Data",
3032
3008
  "description": "Specifies a [data source](https://genomespy.app/docs/grammar/data/). If omitted, the data source is inherited from the parent view."
@@ -3405,10 +3381,6 @@
3405
3381
  },
3406
3382
  "type": "array"
3407
3383
  },
3408
- "configurableVisibility": {
3409
- "description": "Is the visibility configurable interactively from the [GenomeSpy App](https://genomespy.app/docs/sample-collections/). Configurability requires that the view has an explicitly specified name that is unique within its import scope.\n\n**Default:** `false` for children of `layer`, `true` for others.",
3410
- "type": "boolean"
3411
- },
3412
3384
  "data": {
3413
3385
  "$ref": "#/definitions/Data",
3414
3386
  "description": "Specifies a [data source](https://genomespy.app/docs/grammar/data/). If omitted, the data source is inherited from the parent view."
@@ -5455,10 +5427,6 @@
5455
5427
  "description": "The base URL for relative URL data sources and URL [imports](https://genomespy.app/docs/grammar/import/#importing-from-a-url). The base URLs are inherited in the view hierarchy unless overridden with this property. By default, the top-level view's base URL equals to the visualization specification's base URL.",
5456
5428
  "type": "string"
5457
5429
  },
5458
- "configurableVisibility": {
5459
- "description": "Is the visibility configurable interactively from the [GenomeSpy App](https://genomespy.app/docs/sample-collections/). Configurability requires that the view has an explicitly specified name that is unique within its import scope.\n\n**Default:** `false` for children of `layer`, `true` for others.",
5460
- "type": "boolean"
5461
- },
5462
5430
  "data": {
5463
5431
  "$ref": "#/definitions/Data",
5464
5432
  "description": "Specifies a [data source](https://genomespy.app/docs/grammar/data/). If omitted, the data source is inherited from the parent view."
@@ -6097,10 +6065,6 @@
6097
6065
  "description": "The base URL for relative URL data sources and URL [imports](https://genomespy.app/docs/grammar/import/#importing-from-a-url). The base URLs are inherited in the view hierarchy unless overridden with this property. By default, the top-level view's base URL equals to the visualization specification's base URL.",
6098
6066
  "type": "string"
6099
6067
  },
6100
- "configurableVisibility": {
6101
- "description": "Is the visibility configurable interactively from the [GenomeSpy App](https://genomespy.app/docs/sample-collections/). Configurability requires that the view has an explicitly specified name that is unique within its import scope.\n\n**Default:** `false` for children of `layer`, `true` for others.",
6102
- "type": "boolean"
6103
- },
6104
6068
  "data": {
6105
6069
  "$ref": "#/definitions/Data",
6106
6070
  "description": "Specifies a [data source](https://genomespy.app/docs/grammar/data/). If omitted, the data source is inherited from the parent view."
@@ -6923,10 +6887,6 @@
6923
6887
  "description": "The base URL for relative URL data sources and URL [imports](https://genomespy.app/docs/grammar/import/#importing-from-a-url). The base URLs are inherited in the view hierarchy unless overridden with this property. By default, the top-level view's base URL equals to the visualization specification's base URL.",
6924
6888
  "type": "string"
6925
6889
  },
6926
- "configurableVisibility": {
6927
- "description": "Is the visibility configurable interactively from the [GenomeSpy App](https://genomespy.app/docs/sample-collections/). Configurability requires that the view has an explicitly specified name that is unique within its import scope.\n\n**Default:** `false` for children of `layer`, `true` for others.",
6928
- "type": "boolean"
6929
- },
6930
6890
  "data": {
6931
6891
  "$ref": "#/definitions/Data",
6932
6892
  "description": "Specifies a [data source](https://genomespy.app/docs/grammar/data/). If omitted, the data source is inherited from the parent view."
@@ -10140,10 +10100,6 @@
10140
10100
  "description": "The base URL for relative URL data sources and URL [imports](https://genomespy.app/docs/grammar/import/#importing-from-a-url). The base URLs are inherited in the view hierarchy unless overridden with this property. By default, the top-level view's base URL equals to the visualization specification's base URL.",
10141
10101
  "type": "string"
10142
10102
  },
10143
- "configurableVisibility": {
10144
- "description": "Is the visibility configurable interactively from the [GenomeSpy App](https://genomespy.app/docs/sample-collections/). Configurability requires that the view has an explicitly specified name that is unique within its import scope.\n\n**Default:** `false` for children of `layer`, `true` for others.",
10145
- "type": "boolean"
10146
- },
10147
10103
  "data": {
10148
10104
  "$ref": "#/definitions/Data",
10149
10105
  "description": "Specifies a [data source](https://genomespy.app/docs/grammar/data/). If omitted, the data source is inherited from the parent view."
@@ -10568,10 +10524,6 @@
10568
10524
  "description": "The base URL for relative URL data sources and URL [imports](https://genomespy.app/docs/grammar/import/#importing-from-a-url). The base URLs are inherited in the view hierarchy unless overridden with this property. By default, the top-level view's base URL equals to the visualization specification's base URL.",
10569
10525
  "type": "string"
10570
10526
  },
10571
- "configurableVisibility": {
10572
- "description": "Is the visibility configurable interactively from the [GenomeSpy App](https://genomespy.app/docs/sample-collections/). Configurability requires that the view has an explicitly specified name that is unique within its import scope.\n\n**Default:** `false` for children of `layer`, `true` for others.",
10573
- "type": "boolean"
10574
- },
10575
10527
  "data": {
10576
10528
  "$ref": "#/definitions/Data",
10577
10529
  "description": "Specifies a [data source](https://genomespy.app/docs/grammar/data/). If omitted, the data source is inherited from the parent view."
@@ -0,0 +1,12 @@
1
+ /**
2
+ * Load a data set in Apache Parquet format for use in Vega.
3
+ * @param {ArrayBuffer|Uint8Array} data Parquet binary data.
4
+ * @returns {Promise<Record<string,any>[]>} A promise that resolves to an array of data objects representing
5
+ * rows of a data table.
6
+ */
7
+ declare function parquet(data: ArrayBuffer | Uint8Array): Promise<Record<string, any>[]>;
8
+ declare namespace parquet {
9
+ let responseType: string;
10
+ }
11
+ export default parquet;
12
+ //# sourceMappingURL=parquet.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"parquet.d.ts","sourceRoot":"","sources":["../../../../src/data/formats/parquet.js"],"names":[],"mappings":"AAYA;;;;;GAKG;AACH,+BAJW,WAAW,GAAC,UAAU,GACpB,OAAO,CAAC,MAAM,CAAC,MAAM,EAAC,GAAG,CAAC,EAAE,CAAC,CAWzC"}
@@ -0,0 +1,29 @@
1
+ /*
2
+ * Adapted from: https://github.com/vega/vega-loader-parquet/blob/main/src/index.js
3
+ */
4
+
5
+ /**
6
+ * @returns {Promise<typeof import("./parquetRead.js").parquetReadObjects>}
7
+ */
8
+ async function loadParquetReadObjects() {
9
+ const { parquetReadObjects } = await import("./parquetRead.js");
10
+ return parquetReadObjects;
11
+ }
12
+
13
+ /**
14
+ * Load a data set in Apache Parquet format for use in Vega.
15
+ * @param {ArrayBuffer|Uint8Array} data Parquet binary data.
16
+ * @returns {Promise<Record<string,any>[]>} A promise that resolves to an array of data objects representing
17
+ * rows of a data table.
18
+ */
19
+ export default async function parquet(data) {
20
+ const parquetReadObjects = await loadParquetReadObjects();
21
+ const buffer =
22
+ data instanceof Uint8Array
23
+ ? /** @type {ArrayBuffer} */ (data.buffer)
24
+ : data;
25
+
26
+ return await parquetReadObjects({ file: buffer });
27
+ }
28
+
29
+ parquet.responseType = "arrayBuffer";
@@ -0,0 +1,18 @@
1
+ /**
2
+ * @param {ObjectParquetReadOptions} options
3
+ * @returns {Promise<void>}
4
+ */
5
+ export function parquetRead(options: ObjectParquetReadOptions): Promise<void>;
6
+ /**
7
+ * @param {Omit<ObjectParquetReadOptions, "onComplete">} options
8
+ * @returns {Promise<Record<string, any>[]>}
9
+ */
10
+ export function parquetReadObjects(options: Omit<ObjectParquetReadOptions, "onComplete">): Promise<Record<string, any>[]>;
11
+ /**
12
+ * Object-row variant of Parquet read options used by this trimmed reader.
13
+ */
14
+ export type ObjectParquetReadOptions = Omit<import("hyparquet").ParquetReadOptions, "rowFormat" | "filter" | "filterStrict" | "onComplete"> & {
15
+ onComplete?: (rows: Record<string, any>[]) => void;
16
+ };
17
+ export type RowGroupObjectBuilder = (groupData: Record<string, any>[], selectStart: number, selectCount: number, columnData: import("hyparquet").DecodedArray[], columnSkipped: number[]) => Record<string, any>[];
18
+ //# sourceMappingURL=parquetRead.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"parquetRead.d.ts","sourceRoot":"","sources":["../../../../src/data/formats/parquetRead.js"],"names":[],"mappings":"AAqOA;;;GAGG;AACH,qCAHW,wBAAwB,GACtB,OAAO,CAAC,IAAI,CAAC,CAiFzB;AAED;;;GAGG;AACH,4CAHW,IAAI,CAAC,wBAAwB,EAAE,YAAY,CAAC,GAC1C,OAAO,CAAC,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,EAAE,CAAC,CAS1C;;;;uCAlTY,IAAI,CAChB,OAAU,WAAW,EAAE,kBAAkB,EACzC,WAAc,GAAG,QAAQ,GAAG,cAAc,GAAG,YAAY,CACtD,GAAG;IACH,UAAU,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,EAAE,KAAK,IAAI,CAAA;CAClD;oCAIS,CACT,SAAS,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,EAAE,EAChC,WAAW,EAAE,MAAM,EACnB,WAAW,EAAE,MAAM,EACnB,UAAU,EAAE,OAAO,WAAW,EAAE,YAAY,EAAE,EAC9C,aAAa,EAAE,MAAM,EAAE,KACnB,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,EAAE"}
@@ -0,0 +1,326 @@
1
+ /*
2
+ * Adapted from hyparquet internals:
3
+ * https://github.com/hyparam/hyparquet (notably src/read.js and src/rowgroup.js).
4
+ *
5
+ * GenomeSpy-specific changes in this copy:
6
+ * - object-row output only (array row format removed)
7
+ * - filtering support removed
8
+ * - hot row transpose path optimized with cached codegen for typical schemas
9
+ * - fallback to interpreted row builder for very wide schemas
10
+ */
11
+
12
+ import { parquetMetadataAsync, parquetSchema } from "hyparquet/src/metadata.js";
13
+ import { parquetPlan, prefetchAsyncBuffer } from "hyparquet/src/plan.js";
14
+ import { assembleAsync, readRowGroup } from "hyparquet/src/rowgroup.js";
15
+ import { concat } from "hyparquet/src/utils.js";
16
+
17
+ /**
18
+ * Object-row variant of Parquet read options used by this trimmed reader.
19
+ *
20
+ * @typedef {Omit<
21
+ * import("hyparquet").ParquetReadOptions,
22
+ * "rowFormat" | "filter" | "filterStrict" | "onComplete"
23
+ * > & {
24
+ * onComplete?: (rows: Record<string, any>[]) => void
25
+ * }} ObjectParquetReadOptions
26
+ */
27
+
28
+ /**
29
+ * @typedef {(
30
+ * groupData: Record<string, any>[],
31
+ * selectStart: number,
32
+ * selectCount: number,
33
+ * columnData: import("hyparquet").DecodedArray[],
34
+ * columnSkipped: number[]
35
+ * ) => Record<string, any>[]} RowGroupObjectBuilder
36
+ */
37
+
38
+ /** @type {Map<string, RowGroupObjectBuilder>} */
39
+ const rowGroupObjectBuilderCache = new Map();
40
+
41
+ const MAX_CODEGEN_COLUMNS = 200;
42
+
43
+ /**
44
+ * @param {ObjectParquetReadOptions} options
45
+ * @returns {import("hyparquet").AsyncRowGroup[]}
46
+ */
47
+ function parquetReadAsync(options) {
48
+ if (!options.metadata) {
49
+ throw new Error("parquet requires metadata");
50
+ }
51
+
52
+ const plan = parquetPlan(options);
53
+ options.file = prefetchAsyncBuffer(options.file, plan);
54
+
55
+ return plan.groups.map((groupPlan) =>
56
+ readRowGroup(options, plan, groupPlan)
57
+ );
58
+ }
59
+
60
+ /**
61
+ * Flatten decoded data pages into a single decoded array.
62
+ * This local version avoids chunked slice/push overhead in hot paths.
63
+ *
64
+ * @param {import("hyparquet").DecodedArray[] | undefined} chunks
65
+ * @returns {import("hyparquet").DecodedArray}
66
+ */
67
+ function flattenColumnChunks(chunks) {
68
+ if (!chunks) {
69
+ return [];
70
+ }
71
+
72
+ if (chunks.length === 1) {
73
+ return chunks[0];
74
+ }
75
+
76
+ let totalLength = 0;
77
+ for (const chunk of chunks) {
78
+ totalLength += chunk.length;
79
+ }
80
+
81
+ const output = Array(totalLength);
82
+ let offset = 0;
83
+ for (const chunk of chunks) {
84
+ for (let i = 0; i < chunk.length; i++) {
85
+ output[offset + i] = chunk[i];
86
+ }
87
+ offset += chunk.length;
88
+ }
89
+
90
+ return output;
91
+ }
92
+
93
+ /**
94
+ * @param {string[]} columnNames
95
+ * @returns {RowGroupObjectBuilder}
96
+ */
97
+ function getRowGroupObjectBuilder(columnNames) {
98
+ // Compile one builder per column layout to keep object writes monomorphic.
99
+ const signature = columnNames.join("\u001f");
100
+ const cached = rowGroupObjectBuilderCache.get(signature);
101
+ if (cached) {
102
+ return cached;
103
+ }
104
+
105
+ const assignments = columnNames
106
+ .map(
107
+ (columnName, i) =>
108
+ JSON.stringify(columnName) +
109
+ ": columnData[" +
110
+ i +
111
+ "][row - columnSkipped[" +
112
+ i +
113
+ "]]"
114
+ )
115
+ .join(",\n");
116
+
117
+ const builder = /** @type {RowGroupObjectBuilder} */ (
118
+ new Function(
119
+ "groupData",
120
+ "selectStart",
121
+ "selectCount",
122
+ "columnData",
123
+ "columnSkipped",
124
+ // Keep generated code focused on the tight row loop only.
125
+ "for (let selectRow = 0; selectRow < selectCount; selectRow++) {\n" +
126
+ " const row = selectStart + selectRow;\n" +
127
+ " groupData[selectRow] = {\n" +
128
+ assignments +
129
+ "\n" +
130
+ " };\n" +
131
+ "}\n" +
132
+ "return groupData;"
133
+ )
134
+ );
135
+
136
+ rowGroupObjectBuilderCache.set(signature, builder);
137
+
138
+ return builder;
139
+ }
140
+
141
+ /**
142
+ * @param {Record<string, any>[]} groupData
143
+ * @param {number} selectStart
144
+ * @param {number} selectCount
145
+ * @param {string[]} columnNames
146
+ * @param {import("hyparquet").DecodedArray[]} columnData
147
+ * @param {number[]} columnSkipped
148
+ * @returns {Record<string, any>[]}
149
+ */
150
+ function buildRowsInterpreted(
151
+ groupData,
152
+ selectStart,
153
+ selectCount,
154
+ columnNames,
155
+ columnData,
156
+ columnSkipped
157
+ ) {
158
+ for (let selectRow = 0; selectRow < selectCount; selectRow++) {
159
+ const row = selectStart + selectRow;
160
+ /** @type {Record<string, any>} */
161
+ const rowData = {};
162
+ for (let i = 0; i < columnNames.length; i++) {
163
+ rowData[columnNames[i]] = columnData[i][row - columnSkipped[i]];
164
+ }
165
+ groupData[selectRow] = rowData;
166
+ }
167
+
168
+ return groupData;
169
+ }
170
+
171
+ /**
172
+ * Object-only copy of hyparquet's asyncGroupToRows.
173
+ *
174
+ * @param {import("hyparquet").AsyncRowGroup} asyncGroup
175
+ * @param {number} selectStart
176
+ * @param {number} selectEnd
177
+ * @returns {Promise<Record<string, any>[]>}
178
+ */
179
+ async function asyncGroupToRowsObject(
180
+ { asyncColumns },
181
+ selectStart,
182
+ selectEnd
183
+ ) {
184
+ // Resolve all async column pages once before entering the hot transpose loop.
185
+ const pages = await Promise.all(asyncColumns.map((column) => column.data));
186
+ const columnCount = asyncColumns.length;
187
+
188
+ /** @type {string[]} */
189
+ const columnNames = Array(columnCount);
190
+ /** @type {import("hyparquet").DecodedArray[]} */
191
+ const columnData = Array(columnCount);
192
+ /** @type {number[]} */
193
+ const columnSkipped = Array(columnCount);
194
+
195
+ // Precompute all indirections outside the generated function.
196
+ for (let i = 0; i < columnCount; i++) {
197
+ columnNames[i] = asyncColumns[i].pathInSchema[0];
198
+ columnData[i] = flattenColumnChunks(pages[i].data);
199
+ columnSkipped[i] = pages[i].skipped;
200
+ }
201
+
202
+ const selectCount = selectEnd - selectStart;
203
+
204
+ /** @type {Record<string, any>[]} */
205
+ const groupData = Array(selectCount);
206
+
207
+ // Avoid excessively large generated functions for very wide schemas.
208
+ if (columnCount > MAX_CODEGEN_COLUMNS) {
209
+ return buildRowsInterpreted(
210
+ groupData,
211
+ selectStart,
212
+ selectCount,
213
+ columnNames,
214
+ columnData,
215
+ columnSkipped
216
+ );
217
+ }
218
+
219
+ const buildRows = getRowGroupObjectBuilder(columnNames);
220
+
221
+ return buildRows(
222
+ groupData,
223
+ selectStart,
224
+ selectCount,
225
+ columnData,
226
+ columnSkipped
227
+ );
228
+ }
229
+
230
+ /**
231
+ * @param {ObjectParquetReadOptions} options
232
+ * @returns {Promise<void>}
233
+ */
234
+ export async function parquetRead(options) {
235
+ if ("rowFormat" in options) {
236
+ throw new Error(
237
+ 'parquetRead supports only object rows; use rowFormat: "object" implicitly'
238
+ );
239
+ }
240
+ if ("filter" in options || "filterStrict" in options) {
241
+ throw new Error("parquetRead does not support filtering");
242
+ }
243
+
244
+ options.metadata ??= await parquetMetadataAsync(options.file, options);
245
+
246
+ const { rowStart = 0, rowEnd, onChunk, onComplete } = options;
247
+
248
+ const asyncGroups = parquetReadAsync(options);
249
+
250
+ if (!onComplete && !onChunk) {
251
+ for (const { asyncColumns } of asyncGroups) {
252
+ for (const { data } of asyncColumns) {
253
+ await data;
254
+ }
255
+ }
256
+ return;
257
+ }
258
+
259
+ const schemaTree = parquetSchema(options.metadata);
260
+ const assembled = asyncGroups.map((group) =>
261
+ assembleAsync(group, schemaTree, options.parsers)
262
+ );
263
+
264
+ if (onChunk) {
265
+ for (const asyncGroup of assembled) {
266
+ for (const asyncColumn of asyncGroup.asyncColumns) {
267
+ asyncColumn.data.then(
268
+ /**
269
+ * @param {{ data: import("hyparquet").DecodedArray[]; skipped: number }} chunk
270
+ */
271
+ (chunk) => {
272
+ let chunkRowStart =
273
+ asyncGroup.groupStart + chunk.skipped;
274
+ for (const columnData of chunk.data) {
275
+ onChunk({
276
+ columnName: asyncColumn.pathInSchema[0],
277
+ columnData,
278
+ rowStart: chunkRowStart,
279
+ rowEnd: chunkRowStart + columnData.length,
280
+ });
281
+ chunkRowStart += columnData.length;
282
+ }
283
+ }
284
+ );
285
+ }
286
+ }
287
+ }
288
+
289
+ if (onComplete) {
290
+ /** @type {Record<string, any>[]} */
291
+ const rows = [];
292
+ for (const asyncGroup of assembled) {
293
+ const selectStart = Math.max(rowStart - asyncGroup.groupStart, 0);
294
+ const selectEnd = Math.min(
295
+ (rowEnd ?? Infinity) - asyncGroup.groupStart,
296
+ asyncGroup.groupRows
297
+ );
298
+ const groupData = await asyncGroupToRowsObject(
299
+ asyncGroup,
300
+ selectStart,
301
+ selectEnd
302
+ );
303
+ concat(rows, groupData);
304
+ }
305
+ onComplete(rows);
306
+ } else {
307
+ for (const { asyncColumns } of assembled) {
308
+ for (const { data } of asyncColumns) {
309
+ await data;
310
+ }
311
+ }
312
+ }
313
+ }
314
+
315
+ /**
316
+ * @param {Omit<ObjectParquetReadOptions, "onComplete">} options
317
+ * @returns {Promise<Record<string, any>[]>}
318
+ */
319
+ export function parquetReadObjects(options) {
320
+ return new Promise((onComplete, reject) => {
321
+ parquetRead({
322
+ ...options,
323
+ onComplete,
324
+ }).catch(reject);
325
+ });
326
+ }
@@ -1 +1 @@
1
- {"version":3,"file":"urlSource.d.ts","sourceRoot":"","sources":["../../../../src/data/sources/urlSource.js"],"names":[],"mappings":"AASA;;;GAGG;AACH,gCAHW,OAAO,CAAC,OAAO,oBAAoB,EAAE,IAAI,CAAC,GACxC,IAAI,IAAI,OAAO,oBAAoB,EAAE,OAAO,CAIxD;AAED;IACI;;;OAGG;IACH,oBAHW,OAAO,oBAAoB,EAAE,OAAO,QACpC,OAAO,oBAAoB,EAAE,OAAO,EAc9C;IATG,6CAMC;IAED,gBAAiC;;CAuGxC;uBAtIsB,iBAAiB"}
1
+ {"version":3,"file":"urlSource.d.ts","sourceRoot":"","sources":["../../../../src/data/sources/urlSource.js"],"names":[],"mappings":"AASA;;;GAGG;AACH,gCAHW,OAAO,CAAC,OAAO,oBAAoB,EAAE,IAAI,CAAC,GACxC,IAAI,IAAI,OAAO,oBAAoB,EAAE,OAAO,CAIxD;AAED;IACI;;;OAGG;IACH,oBAHW,OAAO,oBAAoB,EAAE,OAAO,QACpC,OAAO,oBAAoB,EAAE,OAAO,EAc9C;IATG,6CAMC;IAED,gBAAiC;;CA4GxC;uBA3IsB,iBAAiB"}
@@ -110,15 +110,20 @@ export default class UrlSource extends DataSource {
110
110
  * @param {any} content
111
111
  * @param {string} [url]
112
112
  */
113
- const readAndParse = (content, url) => {
113
+ const readAndParse = async (content, url) => {
114
114
  try {
115
- /** @type {any[]} */
116
- const data = read(content, format);
115
+ /** @type {any[] | Promise<any[]>} */
116
+ const dataOrPromise = read(content, format);
117
+ const data =
118
+ dataOrPromise instanceof Promise
119
+ ? await dataOrPromise
120
+ : dataOrPromise;
117
121
  this.beginBatch({ type: "file", url: url });
118
122
  for (const d of data) {
119
123
  this._propagate(d);
120
124
  }
121
125
  } catch (e) {
126
+ console.warn(e);
122
127
  throw new Error(`Cannot parse: ${url}: ${e.message}`);
123
128
  }
124
129
  };
@@ -54,12 +54,12 @@ export function isChannelDefWithScale(channelDef: import("../spec/channel.js").C
54
54
  /**
55
55
  * @param {import("../spec/channel.js").ChannelDef} channelDef
56
56
  */
57
- export function findChannelDefWithScale(channelDef: import("../spec/channel.js").ChannelDef): import("../spec/channel.js").FieldOrDatumDefWithCondition<import("../spec/channel.js").MarkPropFieldDef<import("../spec/channel.js").Type>, string> | import("../spec/channel.js").PositionFieldDef | import("../spec/channel.js").PositionDatumDef | import("../spec/channel.js").ChromPosDef | import("../spec/channel.js").FieldOrDatumDefWithCondition<import("../spec/channel.js").MarkPropFieldDef<import("../spec/channel.js").Type>, number> | (import("../spec/channel.js").ParameterPredicate & import("../spec/channel.js").FieldDefBase & import("../spec/channel.js").TitleMixins & import("../spec/channel.js").DomainContributionMixins & import("../spec/channel.js").ScaleMixins & import("../spec/channel.js").TypeMixins<import("../spec/channel.js").Type>) | (import("../spec/channel.js").ParameterPredicate & import("../spec/channel.js").DatumDef<import("../spec/parameter.js").ExprRef | import("../spec/channel.js").Scalar> & import("../spec/channel.js").ScaleMixins & import("../spec/channel.js").TypeMixins<import("../spec/channel.js").Type> & import("../spec/channel.js").DomainContributionMixins) | (import("../spec/channel.js").ParameterPredicate & import("../spec/channel.js").ValueDefBase<string | import("../spec/parameter.js").ExprRef> & import("../spec/channel.js").TitleMixins & import("../spec/channel.js").ScaleMixins & import("../spec/channel.js").TypeMixins<import("../spec/channel.js").Type> & import("../spec/channel.js").DomainContributionMixins) | (import("../spec/channel.js").ParameterPredicate & import("../spec/channel.js").ValueDefBase<number | import("../spec/parameter.js").ExprRef> & import("../spec/channel.js").TitleMixins & import("../spec/channel.js").ScaleMixins & import("../spec/channel.js").TypeMixins<import("../spec/channel.js").Type> & import("../spec/channel.js").DomainContributionMixins);
57
+ export function findChannelDefWithScale(channelDef: import("../spec/channel.js").ChannelDef): import("../spec/channel.js").FieldOrDatumDefWithCondition<import("../spec/channel.js").MarkPropFieldDef<import("../spec/channel.js").Type>, string> | import("../spec/channel.js").PositionFieldDef | import("../spec/channel.js").ChromPosDef | import("../spec/channel.js").PositionDatumDef | import("../spec/channel.js").FieldOrDatumDefWithCondition<import("../spec/channel.js").MarkPropFieldDef<import("../spec/channel.js").Type>, number> | (import("../spec/channel.js").ParameterPredicate & import("../spec/channel.js").ValueDefBase<string | import("../spec/parameter.js").ExprRef> & import("../spec/channel.js").TitleMixins & import("../spec/channel.js").ScaleMixins & import("../spec/channel.js").TypeMixins<import("../spec/channel.js").Type> & import("../spec/channel.js").DomainContributionMixins) | (import("../spec/channel.js").ParameterPredicate & import("../spec/channel.js").ValueDefBase<number | import("../spec/parameter.js").ExprRef> & import("../spec/channel.js").TitleMixins & import("../spec/channel.js").ScaleMixins & import("../spec/channel.js").TypeMixins<import("../spec/channel.js").Type> & import("../spec/channel.js").DomainContributionMixins) | (import("../spec/channel.js").ParameterPredicate & import("../spec/channel.js").FieldDefBase & import("../spec/channel.js").TitleMixins & import("../spec/channel.js").DomainContributionMixins & import("../spec/channel.js").ScaleMixins & import("../spec/channel.js").TypeMixins<import("../spec/channel.js").Type>) | (import("../spec/channel.js").ParameterPredicate & import("../spec/channel.js").DatumDef<import("../spec/parameter.js").ExprRef | import("../spec/channel.js").Scalar> & import("../spec/channel.js").ScaleMixins & import("../spec/channel.js").TypeMixins<import("../spec/channel.js").Type> & import("../spec/channel.js").DomainContributionMixins);
58
58
  /**
59
59
  * @param {import("../view/unitView.js").default} view
60
60
  * @param {import("../spec/channel.js").Channel} channel
61
61
  */
62
- export function getChannelDefWithScale(view: import("../view/unitView.js").default, channel: import("../spec/channel.js").Channel): import("../spec/channel.js").FieldOrDatumDefWithCondition<import("../spec/channel.js").MarkPropFieldDef<import("../spec/channel.js").Type>, string> | import("../spec/channel.js").PositionFieldDef | import("../spec/channel.js").PositionDatumDef | import("../spec/channel.js").ChromPosDef | import("../spec/channel.js").FieldOrDatumDefWithCondition<import("../spec/channel.js").MarkPropFieldDef<import("../spec/channel.js").Type>, number> | import("../spec/channel.js").FieldOrDatumDefWithCondition<import("../spec/channel.js").MarkPropFieldDef<import("../spec/channel.js").TypeForShape>, string> | (import("../spec/channel.js").FieldDefBase & import("../spec/channel.js").TitleMixins & import("../spec/channel.js").TypeMixins<import("../spec/channel.js").Type> & import("../spec/channel.js").ScaleMixins & import("../spec/channel.js").DomainContributionMixins & import("../spec/channel.js").PositionMixins & import("../spec/channel.js").XIndexDef) | (import("../spec/channel.js").ScaleMixins & import("../spec/channel.js").DatumDef<import("../spec/parameter.js").ExprRef | import("../spec/channel.js").Scalar> & import("../spec/channel.js").DomainContributionMixins & import("../spec/channel.js").TypeMixins<import("../spec/channel.js").Type> & import("../spec/channel.js").PositionMixins & import("../spec/channel.js").XIndexDef) | (import("../spec/channel.js").ChromPosDefBase & import("../spec/channel.js").TitleMixins & import("../spec/channel.js").PositionMixins & import("../spec/channel.js").DomainContributionMixins & import("../spec/channel.js").TypeMixins<"locus"> & import("../spec/channel.js").ScaleMixins & import("../spec/channel.js").XIndexDef);
62
+ export function getChannelDefWithScale(view: import("../view/unitView.js").default, channel: import("../spec/channel.js").Channel): import("../spec/channel.js").FieldOrDatumDefWithCondition<import("../spec/channel.js").MarkPropFieldDef<import("../spec/channel.js").Type>, string> | import("../spec/channel.js").PositionFieldDef | import("../spec/channel.js").ChromPosDef | import("../spec/channel.js").PositionDatumDef | (import("../spec/channel.js").FieldDefBase & import("../spec/channel.js").TitleMixins & import("../spec/channel.js").TypeMixins<import("../spec/channel.js").Type> & import("../spec/channel.js").ScaleMixins & import("../spec/channel.js").DomainContributionMixins & import("../spec/channel.js").PositionMixins & import("../spec/channel.js").XIndexDef) | (import("../spec/channel.js").ChromPosDefBase & import("../spec/channel.js").TitleMixins & import("../spec/channel.js").PositionMixins & import("../spec/channel.js").DomainContributionMixins & import("../spec/channel.js").TypeMixins<"locus"> & import("../spec/channel.js").ScaleMixins & import("../spec/channel.js").XIndexDef) | (import("../spec/channel.js").ScaleMixins & import("../spec/channel.js").DatumDef<import("../spec/parameter.js").ExprRef | import("../spec/channel.js").Scalar> & import("../spec/channel.js").DomainContributionMixins & import("../spec/channel.js").TypeMixins<import("../spec/channel.js").Type> & import("../spec/channel.js").PositionMixins & import("../spec/channel.js").XIndexDef) | import("../spec/channel.js").FieldOrDatumDefWithCondition<import("../spec/channel.js").MarkPropFieldDef<import("../spec/channel.js").Type>, number> | import("../spec/channel.js").FieldOrDatumDefWithCondition<import("../spec/channel.js").MarkPropFieldDef<import("../spec/channel.js").TypeForShape>, string>;
63
63
  /**
64
64
  * @param {import("../spec/channel.js").ChannelDef} channelDef
65
65
  * @returns {channelDef is import("../spec/channel.js").TypeMixins<import("../spec/channel.js").Type>}
@@ -51,7 +51,7 @@ export default class BmFontManager {
51
51
  * @param {FontWeight | keyof WEIGHTS} weight
52
52
  * @returns {FontEntry}
53
53
  */
54
- getFont(family: string, style?: FontStyle, weight?: FontWeight | ("bold" | "normal" | "medium" | "thin" | "light" | "regular" | "black")): FontEntry;
54
+ getFont(family: string, style?: FontStyle, weight?: FontWeight | ("bold" | "normal" | "thin" | "light" | "regular" | "medium" | "black")): FontEntry;
55
55
  /**
56
56
  *
57
57
  * @param {FontEntry} fontEntry An uninitialized font entry
@@ -60,9 +60,9 @@ export default class Genome {
60
60
  */
61
61
  constructor(config: GenomeConfig);
62
62
  config: {
63
+ url: string;
63
64
  name: string;
64
65
  } | {
65
- url: string;
66
66
  name: string;
67
67
  } | {
68
68
  contigs: import("../spec/genome.js").Contig[];
@@ -1 +1 @@
1
- {"version":3,"file":"containerUi.d.ts","sourceRoot":"","sources":["../../../src/genomeSpy/containerUi.js"],"names":[],"mappings":"AAGA;;GAEG;AACH,6CAFW,WAAW;;;;;EA6BrB;AAED;;;GAGG;AACH,4CAHW,WAAW,WACX,MAAM,QAUhB;oBA9CmB,wBAAwB"}
1
+ {"version":3,"file":"containerUi.d.ts","sourceRoot":"","sources":["../../../src/genomeSpy/containerUi.js"],"names":[],"mappings":"AAGA;;GAEG;AACH,6CAFW,WAAW;;;;;EA4BrB;AAED;;;GAGG;AACH,4CAHW,WAAW,WACX,MAAM,QAUhB;oBA7CmB,wBAAwB"}
@@ -21,7 +21,6 @@ export function createContainerUi(container) {
21
21
  const loadingIndicatorsElement = element("div", {
22
22
  class: "loading-indicators",
23
23
  });
24
- canvasWrapper.appendChild(loadingIndicatorsElement);
25
24
 
26
25
  const tooltip = new Tooltip(container);
27
26
 
@@ -8,7 +8,7 @@ export function createViewHighlighter(container) {
8
8
  return (view) => {
9
9
  container.querySelector(".view-highlight")?.remove();
10
10
  if (view) {
11
- if (!view.isConfiguredVisible()) {
11
+ if (!view.isVisible()) {
12
12
  return;
13
13
  }
14
14
  const coords = view.coords;
@@ -21,7 +21,7 @@ export function createViewHighlighter(container) {
21
21
  div.style.width = coords.width + "px";
22
22
  div.style.height = coords.height + "px";
23
23
  div.style.border = "1px solid green";
24
- div.style.backgroundColor = "rgba(0, 255, 0, 0.1)";
24
+ div.style.backgroundColor = "rgba(0, 255, 0, 0.05)";
25
25
  div.style.pointerEvents = "none";
26
26
  container.appendChild(div);
27
27
  }