@graphty/graph-io 0.3.48 → 0.3.49

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 (570) hide show
  1. package/dist/chunks/{approximations-C2riR4NT.js → approximations-Bzn3L-je.js} +2 -2
  2. package/dist/chunks/{approximations-C2riR4NT.js.map → approximations-Bzn3L-je.js.map} +1 -1
  3. package/dist/chunks/bends-BGXjv_U4.js +129 -0
  4. package/dist/chunks/bends-BGXjv_U4.js.map +1 -0
  5. package/dist/chunks/{block-Cu22ewuS.js → block-iptrlMBb.js} +906 -164
  6. package/dist/chunks/block-iptrlMBb.js.map +1 -0
  7. package/dist/chunks/choose-CczZJaX_.js +717 -0
  8. package/dist/chunks/choose-CczZJaX_.js.map +1 -0
  9. package/dist/chunks/{codes-CV_Bhcyi.js → codes-BE2xir2k.js} +6 -2
  10. package/dist/chunks/codes-BE2xir2k.js.map +1 -0
  11. package/dist/chunks/{constants-D0LqcsLJ.js → constants-CKkYLPtt.js} +2 -2
  12. package/dist/chunks/{constants-D0LqcsLJ.js.map → constants-CKkYLPtt.js.map} +1 -1
  13. package/dist/chunks/{context-cgmmOxZ2.js → context-C3p0RQxR.js} +5 -4
  14. package/dist/chunks/{context-cgmmOxZ2.js.map → context-C3p0RQxR.js.map} +1 -1
  15. package/dist/chunks/{convert-BcQ8_jMo.js → convert-Ct2zelbQ.js} +7 -2
  16. package/dist/chunks/convert-Ct2zelbQ.js.map +1 -0
  17. package/dist/chunks/{credentials-BiQsnMTb.js → credentials-DXHx7nwR.js} +16 -14
  18. package/dist/chunks/credentials-DXHx7nwR.js.map +1 -0
  19. package/dist/chunks/{cx-export-BEeF6ymo.js → cx-export-Bt6NoqTQ.js} +3 -3
  20. package/dist/chunks/{cx-export-BEeF6ymo.js.map → cx-export-Bt6NoqTQ.js.map} +1 -1
  21. package/dist/chunks/descriptor-B28U25x4.js +60 -0
  22. package/dist/chunks/descriptor-B28U25x4.js.map +1 -0
  23. package/dist/chunks/{descriptor-BJ-W0Jd-.js → descriptor-DLA5kINx.js} +7 -2
  24. package/dist/chunks/descriptor-DLA5kINx.js.map +1 -0
  25. package/dist/chunks/{emit-CD8xnY8s.js → emit-BwHQkZle.js} +1660 -133
  26. package/dist/chunks/emit-BwHQkZle.js.map +1 -0
  27. package/dist/chunks/{escape-DH2Egt-l.js → escape-CuCIzNMB.js} +8 -8
  28. package/dist/chunks/{escape-DH2Egt-l.js.map → escape-CuCIzNMB.js.map} +1 -1
  29. package/dist/chunks/{export-CZ7VRm4I.js → export-Cha4dRFz.js} +45 -387
  30. package/dist/chunks/export-Cha4dRFz.js.map +1 -0
  31. package/dist/chunks/{exporter-Dcw7Ldtq.js → exporter-BP6otMO6.js} +6 -6
  32. package/dist/chunks/{exporter-Dcw7Ldtq.js.map → exporter-BP6otMO6.js.map} +1 -1
  33. package/dist/chunks/{exporter-bxxjOrDZ.js → exporter-D2CETOMK.js} +1222 -156
  34. package/dist/chunks/exporter-D2CETOMK.js.map +1 -0
  35. package/dist/chunks/{exporter-BIdaoIgh.js → exporter-D9yMtocA.js} +7 -7
  36. package/dist/chunks/{exporter-BIdaoIgh.js.map → exporter-D9yMtocA.js.map} +1 -1
  37. package/dist/chunks/{exporter-DtVU80Fa.js → exporter-_jrBTnos.js} +9 -8
  38. package/dist/chunks/{exporter-DtVU80Fa.js.map → exporter-_jrBTnos.js.map} +1 -1
  39. package/dist/chunks/{exporter-ChjL5fmP.js → exporter-nDfxIK5D.js} +9 -8
  40. package/dist/chunks/{exporter-ChjL5fmP.js.map → exporter-nDfxIK5D.js.map} +1 -1
  41. package/dist/chunks/format-BXiAb-1h.js +408 -0
  42. package/dist/chunks/format-BXiAb-1h.js.map +1 -0
  43. package/dist/chunks/{generic-CP6YD34u.js → generic-ymWCETAJ.js} +387 -31
  44. package/dist/chunks/generic-ymWCETAJ.js.map +1 -0
  45. package/dist/chunks/{importer-e3huMZbm.js → importer-B92x1xY5.js} +14 -10
  46. package/dist/chunks/importer-B92x1xY5.js.map +1 -0
  47. package/dist/chunks/{importer-B87_fmVx.js → importer-CT9mJ1nn.js} +326 -84
  48. package/dist/chunks/importer-CT9mJ1nn.js.map +1 -0
  49. package/dist/chunks/{importer-CB_zV5_L.js → importer-DaLTjbds.js} +116 -1102
  50. package/dist/chunks/importer-DaLTjbds.js.map +1 -0
  51. package/dist/chunks/{importer-DPZDN40-.js → importer-GREKMdIf.js} +25 -17
  52. package/dist/chunks/importer-GREKMdIf.js.map +1 -0
  53. package/dist/chunks/{importer-Bji2MeWr.js → importer-PqaaKKnY.js} +13 -10
  54. package/dist/chunks/{importer-Bji2MeWr.js.map → importer-PqaaKKnY.js.map} +1 -1
  55. package/dist/chunks/{importer-Cyy6UseH.js → importer-Vn5QvmmJ.js} +66 -13
  56. package/dist/chunks/importer-Vn5QvmmJ.js.map +1 -0
  57. package/dist/chunks/{importer-CVT-JyDE.js → importer-vRq4h3j5.js} +1469 -356
  58. package/dist/chunks/importer-vRq4h3j5.js.map +1 -0
  59. package/dist/chunks/{input-Ccg9I22A.js → input-CAxt_aV-.js} +4 -4
  60. package/dist/chunks/{input-Ccg9I22A.js.map → input-CAxt_aV-.js.map} +1 -1
  61. package/dist/chunks/{json-elements-By172SVq.js → json-elements-Cq76WjnZ.js} +4 -4
  62. package/dist/chunks/{json-elements-By172SVq.js.map → json-elements-Cq76WjnZ.js.map} +1 -1
  63. package/dist/chunks/{lexicon-u2SI5xcx.js → lexicon-Clf4QIyl.js} +282 -74
  64. package/dist/chunks/lexicon-Clf4QIyl.js.map +1 -0
  65. package/dist/chunks/{ontology-export-BwgMyuF0.js → ontology-export-OMo91mb0.js} +4 -4
  66. package/dist/chunks/{ontology-export-BwgMyuF0.js.map → ontology-export-OMo91mb0.js.map} +1 -1
  67. package/dist/chunks/{records-Cgvxz-Vx.js → records-NJiYvekn.js} +2 -2
  68. package/dist/chunks/{records-Cgvxz-Vx.js.map → records-NJiYvekn.js.map} +1 -1
  69. package/dist/chunks/{report-CgdsL9Hb.js → report-CwMfYa9J.js} +23 -23
  70. package/dist/chunks/{report-CgdsL9Hb.js.map → report-CwMfYa9J.js.map} +1 -1
  71. package/dist/chunks/round-trip-Zm3_ivgq.js +79 -0
  72. package/dist/chunks/round-trip-Zm3_ivgq.js.map +1 -0
  73. package/dist/chunks/{sigv4-LkAzsLAu.js → sigv4-EokFic1V.js} +5 -5
  74. package/dist/chunks/sigv4-EokFic1V.js.map +1 -0
  75. package/dist/chunks/{styles-CaABMoO1.js → styles-CCs214_3.js} +1237 -138
  76. package/dist/chunks/styles-CCs214_3.js.map +1 -0
  77. package/dist/chunks/styles-Cm62yyQX.js +2812 -0
  78. package/dist/chunks/styles-Cm62yyQX.js.map +1 -0
  79. package/dist/chunks/styles-DPQQIig4.js +1928 -0
  80. package/dist/chunks/styles-DPQQIig4.js.map +1 -0
  81. package/dist/chunks/{styles-yed-Cs1nmrjn.js → styles-yed-UMFdNqze.js} +503 -172
  82. package/dist/chunks/styles-yed-UMFdNqze.js.map +1 -0
  83. package/dist/chunks/{text-BuKQVMz2.js → text-ystE2bYi.js} +2 -2
  84. package/dist/chunks/{text-BuKQVMz2.js.map → text-ystE2bYi.js.map} +1 -1
  85. package/dist/csv.js +7 -7
  86. package/dist/cx.js +2 -2
  87. package/dist/cx2.js +2 -2
  88. package/dist/cys.js +1 -1
  89. package/dist/dot.js +5 -4
  90. package/dist/dot.js.map +1 -1
  91. package/dist/gexf.js +42 -12
  92. package/dist/gexf.js.map +1 -1
  93. package/dist/gml.js +847 -193
  94. package/dist/gml.js.map +1 -1
  95. package/dist/graph-io.js +232 -220
  96. package/dist/graph-io.js.map +1 -1
  97. package/dist/graphml.js +3 -3
  98. package/dist/json.js +3 -2
  99. package/dist/neo4j.js +6 -6
  100. package/dist/obo.js +1 -1
  101. package/dist/pajek.js +1 -1
  102. package/dist/positions.js +45 -3
  103. package/dist/positions.js.map +1 -1
  104. package/dist/sources-cypher.js +138 -23
  105. package/dist/sources-cypher.js.map +1 -1
  106. package/dist/sources-ndex.js +2 -2
  107. package/dist/sources-rest.js +16 -6
  108. package/dist/sources-rest.js.map +1 -1
  109. package/dist/sources-sparql.d.ts +1 -0
  110. package/dist/sources-sparql.js +405 -0
  111. package/dist/sources-sparql.js.map +1 -0
  112. package/dist/src/formats/cx/importer.d.ts.map +1 -1
  113. package/dist/src/formats/cx/importer.js +5 -1
  114. package/dist/src/formats/cx/importer.js.map +1 -1
  115. package/dist/src/formats/cx/styles.d.ts +24 -1
  116. package/dist/src/formats/cx/styles.d.ts.map +1 -1
  117. package/dist/src/formats/cx/styles.js +117 -11
  118. package/dist/src/formats/cx/styles.js.map +1 -1
  119. package/dist/src/formats/cx2/importer.d.ts.map +1 -1
  120. package/dist/src/formats/cx2/importer.js +1 -0
  121. package/dist/src/formats/cx2/importer.js.map +1 -1
  122. package/dist/src/formats/cx2/styles.d.ts.map +1 -1
  123. package/dist/src/formats/cx2/styles.js +3 -1
  124. package/dist/src/formats/cx2/styles.js.map +1 -1
  125. package/dist/src/formats/cys/importer.d.ts.map +1 -1
  126. package/dist/src/formats/cys/importer.js +1 -0
  127. package/dist/src/formats/cys/importer.js.map +1 -1
  128. package/dist/src/formats/cys/styles.d.ts +2 -0
  129. package/dist/src/formats/cys/styles.d.ts.map +1 -1
  130. package/dist/src/formats/cys/styles.js +15 -7
  131. package/dist/src/formats/cys/styles.js.map +1 -1
  132. package/dist/src/formats/dot/drawing.d.ts +98 -0
  133. package/dist/src/formats/dot/drawing.d.ts.map +1 -0
  134. package/dist/src/formats/dot/drawing.js +734 -0
  135. package/dist/src/formats/dot/drawing.js.map +1 -0
  136. package/dist/src/formats/dot/importer.d.ts.map +1 -1
  137. package/dist/src/formats/dot/importer.js +108 -31
  138. package/dist/src/formats/dot/importer.js.map +1 -1
  139. package/dist/src/formats/dot/label-places.d.ts +34 -0
  140. package/dist/src/formats/dot/label-places.d.ts.map +1 -0
  141. package/dist/src/formats/dot/label-places.js +179 -0
  142. package/dist/src/formats/dot/label-places.js.map +1 -0
  143. package/dist/src/formats/dot/record.d.ts +50 -0
  144. package/dist/src/formats/dot/record.d.ts.map +1 -0
  145. package/dist/src/formats/dot/record.js +275 -0
  146. package/dist/src/formats/dot/record.js.map +1 -0
  147. package/dist/src/formats/dot/styles.d.ts +62 -2
  148. package/dist/src/formats/dot/styles.d.ts.map +1 -1
  149. package/dist/src/formats/dot/styles.js +1454 -119
  150. package/dist/src/formats/dot/styles.js.map +1 -1
  151. package/dist/src/formats/gexf/dialog-metrics.d.ts +15 -0
  152. package/dist/src/formats/gexf/dialog-metrics.d.ts.map +1 -0
  153. package/dist/src/formats/gexf/dialog-metrics.js +59 -0
  154. package/dist/src/formats/gexf/dialog-metrics.js.map +1 -0
  155. package/dist/src/formats/gexf/importer.d.ts +7 -0
  156. package/dist/src/formats/gexf/importer.d.ts.map +1 -1
  157. package/dist/src/formats/gexf/importer.js +41 -5
  158. package/dist/src/formats/gexf/importer.js.map +1 -1
  159. package/dist/src/formats/gexf/preview.d.ts +77 -0
  160. package/dist/src/formats/gexf/preview.d.ts.map +1 -0
  161. package/dist/src/formats/gexf/preview.js +191 -0
  162. package/dist/src/formats/gexf/preview.js.map +1 -0
  163. package/dist/src/formats/gexf/schema.d.ts.map +1 -1
  164. package/dist/src/formats/gexf/schema.js +2 -1
  165. package/dist/src/formats/gexf/schema.js.map +1 -1
  166. package/dist/src/formats/gexf/styles.d.ts +58 -31
  167. package/dist/src/formats/gexf/styles.d.ts.map +1 -1
  168. package/dist/src/formats/gexf/styles.js +848 -225
  169. package/dist/src/formats/gexf/styles.js.map +1 -1
  170. package/dist/src/formats/gml/importer.d.ts +5 -2
  171. package/dist/src/formats/gml/importer.d.ts.map +1 -1
  172. package/dist/src/formats/gml/importer.js +258 -71
  173. package/dist/src/formats/gml/importer.js.map +1 -1
  174. package/dist/src/formats/gml/index.d.ts +1 -1
  175. package/dist/src/formats/gml/index.d.ts.map +1 -1
  176. package/dist/src/formats/gml/index.js +1 -1
  177. package/dist/src/formats/gml/index.js.map +1 -1
  178. package/dist/src/formats/gml/positions.d.ts +7 -0
  179. package/dist/src/formats/gml/positions.d.ts.map +1 -1
  180. package/dist/src/formats/gml/positions.js +29 -7
  181. package/dist/src/formats/gml/positions.js.map +1 -1
  182. package/dist/src/formats/gml/styles.d.ts.map +1 -1
  183. package/dist/src/formats/gml/styles.js +753 -101
  184. package/dist/src/formats/gml/styles.js.map +1 -1
  185. package/dist/src/formats/graphml/styles-plain.d.ts.map +1 -1
  186. package/dist/src/formats/graphml/styles-plain.js +6 -10
  187. package/dist/src/formats/graphml/styles-plain.js.map +1 -1
  188. package/dist/src/formats/graphml/styles-yed.d.ts +21 -15
  189. package/dist/src/formats/graphml/styles-yed.d.ts.map +1 -1
  190. package/dist/src/formats/graphml/styles-yed.js +692 -161
  191. package/dist/src/formats/graphml/styles-yed.js.map +1 -1
  192. package/dist/src/formats/graphml/styles-yfiles3.d.ts +1 -1
  193. package/dist/src/formats/graphml/styles-yfiles3.d.ts.map +1 -1
  194. package/dist/src/formats/graphml/styles-yfiles3.js +429 -64
  195. package/dist/src/formats/graphml/styles-yfiles3.js.map +1 -1
  196. package/dist/src/formats/graphml/yfiles.d.ts +3 -3
  197. package/dist/src/formats/graphml/yfiles.d.ts.map +1 -1
  198. package/dist/src/formats/graphml/yfiles.js +16 -6
  199. package/dist/src/formats/graphml/yfiles.js.map +1 -1
  200. package/dist/src/formats/json/dialect.d.ts +3 -2
  201. package/dist/src/formats/json/dialect.d.ts.map +1 -1
  202. package/dist/src/formats/json/dialect.js +39 -5
  203. package/dist/src/formats/json/dialect.js.map +1 -1
  204. package/dist/src/formats/json/importer.d.ts +13 -2
  205. package/dist/src/formats/json/importer.d.ts.map +1 -1
  206. package/dist/src/formats/json/importer.js +42 -6
  207. package/dist/src/formats/json/importer.js.map +1 -1
  208. package/dist/src/formats/json/index.d.ts +1 -1
  209. package/dist/src/formats/json/index.d.ts.map +1 -1
  210. package/dist/src/formats/json/index.js +1 -1
  211. package/dist/src/formats/json/index.js.map +1 -1
  212. package/dist/src/formats/json/positions.d.ts +5 -2
  213. package/dist/src/formats/json/positions.d.ts.map +1 -1
  214. package/dist/src/formats/json/positions.js +20 -4
  215. package/dist/src/formats/json/positions.js.map +1 -1
  216. package/dist/src/formats/json/styles.d.ts +12 -1
  217. package/dist/src/formats/json/styles.d.ts.map +1 -1
  218. package/dist/src/formats/json/styles.js +1755 -136
  219. package/dist/src/formats/json/styles.js.map +1 -1
  220. package/dist/src/formats/pajek/draw.d.ts +96 -0
  221. package/dist/src/formats/pajek/draw.d.ts.map +1 -0
  222. package/dist/src/formats/pajek/draw.js +372 -0
  223. package/dist/src/formats/pajek/draw.js.map +1 -0
  224. package/dist/src/formats/pajek/exporter.d.ts.map +1 -1
  225. package/dist/src/formats/pajek/exporter.js +70 -51
  226. package/dist/src/formats/pajek/exporter.js.map +1 -1
  227. package/dist/src/formats/pajek/importer.d.ts +9 -0
  228. package/dist/src/formats/pajek/importer.d.ts.map +1 -1
  229. package/dist/src/formats/pajek/importer.js +233 -102
  230. package/dist/src/formats/pajek/importer.js.map +1 -1
  231. package/dist/src/formats/pajek/index.d.ts +1 -0
  232. package/dist/src/formats/pajek/index.d.ts.map +1 -1
  233. package/dist/src/formats/pajek/index.js.map +1 -1
  234. package/dist/src/formats/pajek/styles.d.ts +15 -7
  235. package/dist/src/formats/pajek/styles.d.ts.map +1 -1
  236. package/dist/src/formats/pajek/styles.js +1278 -114
  237. package/dist/src/formats/pajek/styles.js.map +1 -1
  238. package/dist/src/formats/pajek/syntax.d.ts +10 -1
  239. package/dist/src/formats/pajek/syntax.d.ts.map +1 -1
  240. package/dist/src/formats/pajek/syntax.js +26 -2
  241. package/dist/src/formats/pajek/syntax.js.map +1 -1
  242. package/dist/src/formats/xgmml/emit.d.ts +1 -0
  243. package/dist/src/formats/xgmml/emit.d.ts.map +1 -1
  244. package/dist/src/formats/xgmml/emit.js +65 -5
  245. package/dist/src/formats/xgmml/emit.js.map +1 -1
  246. package/dist/src/formats/xgmml/styles.d.ts +23 -3
  247. package/dist/src/formats/xgmml/styles.d.ts.map +1 -1
  248. package/dist/src/formats/xgmml/styles.js +277 -60
  249. package/dist/src/formats/xgmml/styles.js.map +1 -1
  250. package/dist/src/index.d.ts +4 -3
  251. package/dist/src/index.d.ts.map +1 -1
  252. package/dist/src/index.js +4 -3
  253. package/dist/src/index.js.map +1 -1
  254. package/dist/src/positions/convert.d.ts.map +1 -1
  255. package/dist/src/positions/convert.js +11 -1
  256. package/dist/src/positions/convert.js.map +1 -1
  257. package/dist/src/positions/extract.d.ts.map +1 -1
  258. package/dist/src/positions/extract.js +53 -1
  259. package/dist/src/positions/extract.js.map +1 -1
  260. package/dist/src/positions/index.d.ts +1 -1
  261. package/dist/src/positions/index.d.ts.map +1 -1
  262. package/dist/src/positions/types.d.ts +59 -0
  263. package/dist/src/positions/types.d.ts.map +1 -1
  264. package/dist/src/sources/builtins.d.ts +1 -1
  265. package/dist/src/sources/builtins.d.ts.map +1 -1
  266. package/dist/src/sources/builtins.js +8 -2
  267. package/dist/src/sources/builtins.js.map +1 -1
  268. package/dist/src/sources/context.d.ts.map +1 -1
  269. package/dist/src/sources/context.js +1 -0
  270. package/dist/src/sources/context.js.map +1 -1
  271. package/dist/src/sources/cypher/descriptor.d.ts.map +1 -1
  272. package/dist/src/sources/cypher/descriptor.js +5 -0
  273. package/dist/src/sources/cypher/descriptor.js.map +1 -1
  274. package/dist/src/sources/cypher/index.d.ts.map +1 -1
  275. package/dist/src/sources/cypher/index.js +124 -18
  276. package/dist/src/sources/cypher/index.js.map +1 -1
  277. package/dist/src/sources/cypher/params.d.ts +1 -1
  278. package/dist/src/sources/cypher/params.d.ts.map +1 -1
  279. package/dist/src/sources/cypher/query-builder.d.ts +17 -0
  280. package/dist/src/sources/cypher/query-builder.d.ts.map +1 -1
  281. package/dist/src/sources/cypher/query-builder.js +31 -0
  282. package/dist/src/sources/cypher/query-builder.js.map +1 -1
  283. package/dist/src/sources/ids.d.ts +5 -0
  284. package/dist/src/sources/ids.d.ts.map +1 -1
  285. package/dist/src/sources/ids.js +5 -0
  286. package/dist/src/sources/ids.js.map +1 -1
  287. package/dist/src/sources/params.d.ts +3 -0
  288. package/dist/src/sources/params.d.ts.map +1 -1
  289. package/dist/src/sources/rest/descriptor.d.ts.map +1 -1
  290. package/dist/src/sources/rest/descriptor.js +5 -0
  291. package/dist/src/sources/rest/descriptor.js.map +1 -1
  292. package/dist/src/sources/rest/source.d.ts.map +1 -1
  293. package/dist/src/sources/rest/source.js +15 -0
  294. package/dist/src/sources/rest/source.js.map +1 -1
  295. package/dist/src/sources/sigv4.d.ts +5 -3
  296. package/dist/src/sources/sigv4.d.ts.map +1 -1
  297. package/dist/src/sources/sigv4.js +6 -4
  298. package/dist/src/sources/sigv4.js.map +1 -1
  299. package/dist/src/sources/sparql/descriptor.d.ts +10 -0
  300. package/dist/src/sources/sparql/descriptor.d.ts.map +1 -0
  301. package/dist/src/sources/sparql/descriptor.js +64 -0
  302. package/dist/src/sources/sparql/descriptor.js.map +1 -0
  303. package/dist/src/sources/sparql/index.d.ts +28 -0
  304. package/dist/src/sources/sparql/index.d.ts.map +1 -0
  305. package/dist/src/sources/sparql/index.js +314 -0
  306. package/dist/src/sources/sparql/index.js.map +1 -0
  307. package/dist/src/sources/sparql/ntriples.d.ts +69 -0
  308. package/dist/src/sources/sparql/ntriples.d.ts.map +1 -0
  309. package/dist/src/sources/sparql/ntriples.js +180 -0
  310. package/dist/src/sources/sparql/ntriples.js.map +1 -0
  311. package/dist/src/sources/sparql/params.d.ts +27 -0
  312. package/dist/src/sources/sparql/params.d.ts.map +1 -0
  313. package/dist/src/sources/sparql/params.js +5 -0
  314. package/dist/src/sources/sparql/params.js.map +1 -0
  315. package/dist/src/sources/sparql/query.d.ts +72 -0
  316. package/dist/src/sources/sparql/query.d.ts.map +1 -0
  317. package/dist/src/sources/sparql/query.js +113 -0
  318. package/dist/src/sources/sparql/query.js.map +1 -0
  319. package/dist/src/sources/types.d.ts +31 -0
  320. package/dist/src/sources/types.d.ts.map +1 -1
  321. package/dist/src/styles/annotations.d.ts +61 -5
  322. package/dist/src/styles/annotations.d.ts.map +1 -1
  323. package/dist/src/styles/annotations.js +130 -22
  324. package/dist/src/styles/annotations.js.map +1 -1
  325. package/dist/src/styles/canon/bends.d.ts +46 -0
  326. package/dist/src/styles/canon/bends.d.ts.map +1 -1
  327. package/dist/src/styles/canon/bends.js +123 -0
  328. package/dist/src/styles/canon/bends.js.map +1 -1
  329. package/dist/src/styles/canon/color-tables.d.ts +6 -1
  330. package/dist/src/styles/canon/color-tables.d.ts.map +1 -1
  331. package/dist/src/styles/canon/color-tables.js +10 -4
  332. package/dist/src/styles/canon/color-tables.js.map +1 -1
  333. package/dist/src/styles/canon/color.d.ts +3 -1
  334. package/dist/src/styles/canon/color.d.ts.map +1 -1
  335. package/dist/src/styles/canon/color.js +103 -3
  336. package/dist/src/styles/canon/color.js.map +1 -1
  337. package/dist/src/styles/canon/enums.d.ts +2 -2
  338. package/dist/src/styles/canon/enums.d.ts.map +1 -1
  339. package/dist/src/styles/canon/enums.js +81 -7
  340. package/dist/src/styles/canon/enums.js.map +1 -1
  341. package/dist/src/styles/canon/graphviz.d.ts +12 -3
  342. package/dist/src/styles/canon/graphviz.d.ts.map +1 -1
  343. package/dist/src/styles/canon/graphviz.js +57 -9
  344. package/dist/src/styles/canon/graphviz.js.map +1 -1
  345. package/dist/src/styles/canon/number.d.ts +8 -0
  346. package/dist/src/styles/canon/number.d.ts.map +1 -1
  347. package/dist/src/styles/canon/number.js +18 -0
  348. package/dist/src/styles/canon/number.js.map +1 -1
  349. package/dist/src/styles/canon/text.d.ts +29 -2
  350. package/dist/src/styles/canon/text.d.ts.map +1 -1
  351. package/dist/src/styles/canon/text.js +156 -16
  352. package/dist/src/styles/canon/text.js.map +1 -1
  353. package/dist/src/styles/codes.d.ts +2 -0
  354. package/dist/src/styles/codes.d.ts.map +1 -1
  355. package/dist/src/styles/codes.js +2 -0
  356. package/dist/src/styles/codes.js.map +1 -1
  357. package/dist/src/styles/cyjs/cascade.d.ts.map +1 -1
  358. package/dist/src/styles/cyjs/cascade.js +1015 -79
  359. package/dist/src/styles/cyjs/cascade.js.map +1 -1
  360. package/dist/src/styles/cyjs/defaults-table.d.ts.map +1 -1
  361. package/dist/src/styles/cyjs/defaults-table.js +3 -0
  362. package/dist/src/styles/cyjs/defaults-table.js.map +1 -1
  363. package/dist/src/styles/cyjs/emit.d.ts.map +1 -1
  364. package/dist/src/styles/cyjs/emit.js +202 -9
  365. package/dist/src/styles/cyjs/emit.js.map +1 -1
  366. package/dist/src/styles/cyjs/face.d.ts +20 -0
  367. package/dist/src/styles/cyjs/face.d.ts.map +1 -0
  368. package/dist/src/styles/cyjs/face.js +332 -0
  369. package/dist/src/styles/cyjs/face.js.map +1 -0
  370. package/dist/src/styles/cyjs/mappers.d.ts +44 -1
  371. package/dist/src/styles/cyjs/mappers.d.ts.map +1 -1
  372. package/dist/src/styles/cyjs/mappers.js +461 -26
  373. package/dist/src/styles/cyjs/mappers.js.map +1 -1
  374. package/dist/src/styles/cyjs/routes.d.ts +53 -0
  375. package/dist/src/styles/cyjs/routes.d.ts.map +1 -0
  376. package/dist/src/styles/cyjs/routes.js +360 -0
  377. package/dist/src/styles/cyjs/routes.js.map +1 -0
  378. package/dist/src/styles/cytoscape/charts.d.ts +23 -0
  379. package/dist/src/styles/cytoscape/charts.d.ts.map +1 -0
  380. package/dist/src/styles/cytoscape/charts.js +560 -0
  381. package/dist/src/styles/cytoscape/charts.js.map +1 -0
  382. package/dist/src/styles/cytoscape/emit.d.ts.map +1 -1
  383. package/dist/src/styles/cytoscape/emit.js +156 -48
  384. package/dist/src/styles/cytoscape/emit.js.map +1 -1
  385. package/dist/src/styles/cytoscape/lexicon.d.ts +91 -3
  386. package/dist/src/styles/cytoscape/lexicon.d.ts.map +1 -1
  387. package/dist/src/styles/cytoscape/lexicon.js +387 -77
  388. package/dist/src/styles/cytoscape/lexicon.js.map +1 -1
  389. package/dist/src/styles/cytoscape/mappings.d.ts +30 -0
  390. package/dist/src/styles/cytoscape/mappings.d.ts.map +1 -1
  391. package/dist/src/styles/cytoscape/mappings.js +92 -0
  392. package/dist/src/styles/cytoscape/mappings.js.map +1 -1
  393. package/dist/src/styles/cytoscape/resolve.d.ts +42 -2
  394. package/dist/src/styles/cytoscape/resolve.d.ts.map +1 -1
  395. package/dist/src/styles/cytoscape/resolve.js +623 -17
  396. package/dist/src/styles/cytoscape/resolve.js.map +1 -1
  397. package/dist/src/styles/defaults.d.ts +46 -26
  398. package/dist/src/styles/defaults.d.ts.map +1 -1
  399. package/dist/src/styles/defaults.js +308 -71
  400. package/dist/src/styles/defaults.js.map +1 -1
  401. package/dist/src/styles/index.d.ts +4 -3
  402. package/dist/src/styles/index.d.ts.map +1 -1
  403. package/dist/src/styles/index.js +3 -2
  404. package/dist/src/styles/index.js.map +1 -1
  405. package/dist/src/styles/internal.d.ts +1 -0
  406. package/dist/src/styles/internal.d.ts.map +1 -1
  407. package/dist/src/styles/internal.js +1 -0
  408. package/dist/src/styles/internal.js.map +1 -1
  409. package/dist/src/styles/io/generic.d.ts.map +1 -1
  410. package/dist/src/styles/io/generic.js +56 -16
  411. package/dist/src/styles/io/generic.js.map +1 -1
  412. package/dist/src/styles/io/round-trip.d.ts +56 -0
  413. package/dist/src/styles/io/round-trip.d.ts.map +1 -0
  414. package/dist/src/styles/io/round-trip.js +138 -0
  415. package/dist/src/styles/io/round-trip.js.map +1 -0
  416. package/dist/src/styles/io/writer.d.ts.map +1 -1
  417. package/dist/src/styles/io/writer.js +6 -1
  418. package/dist/src/styles/io/writer.js.map +1 -1
  419. package/dist/src/styles/notes.d.ts.map +1 -1
  420. package/dist/src/styles/notes.js +1 -0
  421. package/dist/src/styles/notes.js.map +1 -1
  422. package/dist/src/styles/plan/features.d.ts +1 -1
  423. package/dist/src/styles/plan/features.d.ts.map +1 -1
  424. package/dist/src/styles/plan/features.js +22 -2
  425. package/dist/src/styles/plan/features.js.map +1 -1
  426. package/dist/src/styles/plan/index.d.ts +1 -1
  427. package/dist/src/styles/plan/index.d.ts.map +1 -1
  428. package/dist/src/styles/plan/index.js +1 -1
  429. package/dist/src/styles/plan/index.js.map +1 -1
  430. package/dist/src/styles/plan/plan.d.ts.map +1 -1
  431. package/dist/src/styles/plan/plan.js +61 -4
  432. package/dist/src/styles/plan/plan.js.map +1 -1
  433. package/dist/src/styles/plan/resolve.d.ts +11 -0
  434. package/dist/src/styles/plan/resolve.d.ts.map +1 -1
  435. package/dist/src/styles/plan/resolve.js +40 -4
  436. package/dist/src/styles/plan/resolve.js.map +1 -1
  437. package/dist/src/styles/slots.d.ts +14 -0
  438. package/dist/src/styles/slots.d.ts.map +1 -0
  439. package/dist/src/styles/slots.js +20 -0
  440. package/dist/src/styles/slots.js.map +1 -0
  441. package/dist/src/styles/types.d.ts +622 -6
  442. package/dist/src/styles/types.d.ts.map +1 -1
  443. package/dist/src/styles/vocabulary.d.ts +3 -2
  444. package/dist/src/styles/vocabulary.d.ts.map +1 -1
  445. package/dist/src/styles/vocabulary.js +203 -0
  446. package/dist/src/styles/vocabulary.js.map +1 -1
  447. package/dist/styles.js +30 -239
  448. package/dist/styles.js.map +1 -1
  449. package/dist/xgmml.js +3 -3
  450. package/package.json +27 -7
  451. package/src/formats/cx/importer.ts +6 -1
  452. package/src/formats/cx/styles.ts +143 -9
  453. package/src/formats/cx2/importer.ts +1 -0
  454. package/src/formats/cx2/styles.ts +3 -1
  455. package/src/formats/cys/importer.ts +1 -0
  456. package/src/formats/cys/styles.ts +27 -5
  457. package/src/formats/dot/drawing.ts +799 -0
  458. package/src/formats/dot/importer.ts +120 -35
  459. package/src/formats/dot/label-places.ts +228 -0
  460. package/src/formats/dot/record.ts +336 -0
  461. package/src/formats/dot/styles.ts +1654 -153
  462. package/src/formats/gexf/dialog-metrics.ts +61 -0
  463. package/src/formats/gexf/importer.ts +50 -5
  464. package/src/formats/gexf/preview.ts +217 -0
  465. package/src/formats/gexf/schema.ts +2 -1
  466. package/src/formats/gexf/styles.ts +1099 -245
  467. package/src/formats/gml/importer.ts +291 -76
  468. package/src/formats/gml/index.ts +1 -1
  469. package/src/formats/gml/positions.ts +29 -7
  470. package/src/formats/gml/styles.ts +851 -109
  471. package/src/formats/graphml/styles-plain.ts +6 -15
  472. package/src/formats/graphml/styles-yed.ts +762 -173
  473. package/src/formats/graphml/styles-yfiles3.ts +485 -63
  474. package/src/formats/graphml/yfiles.ts +19 -6
  475. package/src/formats/json/dialect.ts +41 -5
  476. package/src/formats/json/importer.ts +59 -7
  477. package/src/formats/json/index.ts +1 -0
  478. package/src/formats/json/positions.ts +22 -5
  479. package/src/formats/json/styles.ts +2041 -185
  480. package/src/formats/pajek/draw.ts +458 -0
  481. package/src/formats/pajek/exporter.ts +81 -49
  482. package/src/formats/pajek/importer.ts +278 -103
  483. package/src/formats/pajek/index.ts +1 -0
  484. package/src/formats/pajek/styles.ts +1381 -133
  485. package/src/formats/pajek/syntax.ts +27 -2
  486. package/src/formats/xgmml/emit.ts +73 -5
  487. package/src/formats/xgmml/styles.ts +330 -71
  488. package/src/index.ts +5 -1
  489. package/src/positions/convert.ts +12 -1
  490. package/src/positions/extract.ts +55 -1
  491. package/src/positions/index.ts +1 -0
  492. package/src/positions/types.ts +60 -0
  493. package/src/sources/builtins.ts +8 -1
  494. package/src/sources/context.ts +1 -0
  495. package/src/sources/cypher/descriptor.ts +7 -1
  496. package/src/sources/cypher/index.ts +148 -18
  497. package/src/sources/cypher/params.ts +1 -1
  498. package/src/sources/cypher/query-builder.ts +33 -0
  499. package/src/sources/ids.ts +6 -0
  500. package/src/sources/params.ts +3 -0
  501. package/src/sources/rest/descriptor.ts +5 -0
  502. package/src/sources/rest/source.ts +16 -0
  503. package/src/sources/sigv4.ts +6 -4
  504. package/src/sources/sparql/descriptor.ts +67 -0
  505. package/src/sources/sparql/index.ts +356 -0
  506. package/src/sources/sparql/ntriples.ts +219 -0
  507. package/src/sources/sparql/params.ts +28 -0
  508. package/src/sources/sparql/query.ts +162 -0
  509. package/src/sources/types.ts +35 -0
  510. package/src/styles/annotations.ts +201 -27
  511. package/src/styles/canon/bends.ts +137 -0
  512. package/src/styles/canon/color-tables.ts +10 -4
  513. package/src/styles/canon/color.ts +105 -3
  514. package/src/styles/canon/enums.ts +98 -8
  515. package/src/styles/canon/graphviz.ts +71 -10
  516. package/src/styles/canon/number.ts +19 -0
  517. package/src/styles/canon/text.ts +187 -16
  518. package/src/styles/codes.ts +2 -0
  519. package/src/styles/cyjs/cascade.ts +1160 -84
  520. package/src/styles/cyjs/defaults-table.ts +3 -0
  521. package/src/styles/cyjs/emit.ts +233 -13
  522. package/src/styles/cyjs/face.ts +372 -0
  523. package/src/styles/cyjs/mappers.ts +492 -27
  524. package/src/styles/cyjs/routes.ts +432 -0
  525. package/src/styles/cytoscape/charts.ts +684 -0
  526. package/src/styles/cytoscape/emit.ts +170 -48
  527. package/src/styles/cytoscape/lexicon.ts +431 -78
  528. package/src/styles/cytoscape/mappings.ts +108 -0
  529. package/src/styles/cytoscape/resolve.ts +741 -17
  530. package/src/styles/defaults.ts +417 -108
  531. package/src/styles/index.ts +5 -0
  532. package/src/styles/internal.ts +1 -0
  533. package/src/styles/io/generic.ts +79 -23
  534. package/src/styles/io/round-trip.ts +202 -0
  535. package/src/styles/io/writer.ts +6 -1
  536. package/src/styles/notes.ts +1 -0
  537. package/src/styles/plan/features.ts +23 -2
  538. package/src/styles/plan/index.ts +1 -1
  539. package/src/styles/plan/plan.ts +69 -5
  540. package/src/styles/plan/resolve.ts +47 -4
  541. package/src/styles/slots.ts +25 -0
  542. package/src/styles/types.ts +633 -5
  543. package/src/styles/vocabulary.ts +211 -2
  544. package/dist/chunks/block-Cu22ewuS.js.map +0 -1
  545. package/dist/chunks/choose-Cdx6Enl2.js +0 -57
  546. package/dist/chunks/choose-Cdx6Enl2.js.map +0 -1
  547. package/dist/chunks/codes-CV_Bhcyi.js.map +0 -1
  548. package/dist/chunks/convert-BcQ8_jMo.js.map +0 -1
  549. package/dist/chunks/credentials-BiQsnMTb.js.map +0 -1
  550. package/dist/chunks/descriptor-BJ-W0Jd-.js.map +0 -1
  551. package/dist/chunks/emit-CD8xnY8s.js.map +0 -1
  552. package/dist/chunks/export-CZ7VRm4I.js.map +0 -1
  553. package/dist/chunks/exporter-bxxjOrDZ.js.map +0 -1
  554. package/dist/chunks/format-BMS-1Nxb.js +0 -64
  555. package/dist/chunks/format-BMS-1Nxb.js.map +0 -1
  556. package/dist/chunks/generic-CP6YD34u.js.map +0 -1
  557. package/dist/chunks/importer-B87_fmVx.js.map +0 -1
  558. package/dist/chunks/importer-CB_zV5_L.js.map +0 -1
  559. package/dist/chunks/importer-CVT-JyDE.js.map +0 -1
  560. package/dist/chunks/importer-Cyy6UseH.js.map +0 -1
  561. package/dist/chunks/importer-DPZDN40-.js.map +0 -1
  562. package/dist/chunks/importer-e3huMZbm.js.map +0 -1
  563. package/dist/chunks/lexicon-u2SI5xcx.js.map +0 -1
  564. package/dist/chunks/sigv4-LkAzsLAu.js.map +0 -1
  565. package/dist/chunks/styles-CaABMoO1.js.map +0 -1
  566. package/dist/chunks/styles-P_gmFAOi.js +0 -770
  567. package/dist/chunks/styles-P_gmFAOi.js.map +0 -1
  568. package/dist/chunks/styles-yed-Cs1nmrjn.js.map +0 -1
  569. package/dist/chunks/writer-DvHTl36J.js +0 -449
  570. package/dist/chunks/writer-DvHTl36J.js.map +0 -1
@@ -1,5 +1,5 @@
1
- import { a0 as STYLES_NOT_IMPORTED_CODE } from "./report-CgdsL9Hb.js";
2
- import { f as formatF32 } from "./format-BMS-1Nxb.js";
1
+ import { a0 as STYLES_NOT_IMPORTED_CODE } from "./report-CwMfYa9J.js";
2
+ import { f as formatF32, p as pairFolding } from "./format-BXiAb-1h.js";
3
3
  const STYLE_ISSUE = Object.freeze({
4
4
  // ------------------------------------------------ reading values
5
5
  /** A value longer than 256 characters was not parsed. */
@@ -32,6 +32,8 @@ const STYLE_ISSUE = Object.freeze({
32
32
  INHERIT_COLOR: "W_STYLE_INHERIT_COLOR",
33
33
  /** A style property the vocabulary has no counterpart for was not carried. */
34
34
  NOT_CARRIED: "W_STYLE_NOT_CARRIED",
35
+ /** An annotation of a kind graph-io does not read (a group of annotations); its kinds are the samples. */
36
+ ANNOTATION_SKIPPED: "W_STYLE_ANNOTATION_SKIPPED",
35
37
  // ------------------------------------------------ reading declared styles
36
38
  /** A declared mapping that cannot be read. */
37
39
  BAD_MAPPING: "W_STYLE_BAD_MAPPING",
@@ -160,6 +162,17 @@ function canonNumber(raw, site, factor = 1) {
160
162
  }
161
163
  return num6$1(scaled);
162
164
  }
165
+ function canonSigned(raw, site) {
166
+ const value = finite(raw, site);
167
+ if (value === null) {
168
+ return null;
169
+ }
170
+ if (Math.abs(value) > MAX_STYLE_NUMBER) {
171
+ noteAt(site, STYLE_ISSUE.BAD_VALUE, typeof raw === "string" ? raw : String(raw));
172
+ return null;
173
+ }
174
+ return num6$1(value);
175
+ }
163
176
  function canonOpacity(raw, dialect, site) {
164
177
  const value = finite(raw, site);
165
178
  if (value === null) {
@@ -219,6 +232,7 @@ const PHRASES = /* @__PURE__ */ new Map([
219
232
  ["W_STYLE_EXTRA_LABELS", "elements have more than one label; the first was kept"],
220
233
  ["W_STYLE_INHERIT_COLOR", "inherited colors cannot be expressed"],
221
234
  ["W_STYLE_NOT_CARRIED", "style properties have no counterpart and were not carried"],
235
+ ["W_STYLE_ANNOTATION_SKIPPED", "annotations of a kind graph-io does not read were skipped"],
222
236
  ["W_STYLE_BAD_MAPPING", "mappings cannot be read"],
223
237
  ["W_STYLE_MAPPING_COLUMN_MISSING", "mappings read a column the file does not have"],
224
238
  ["W_STYLE_REFERENCE_CYCLE", "style references are circular or too deep"],
@@ -351,16 +365,34 @@ const SHAPES = {
351
365
  "roundedrectangle",
352
366
  "round-rect",
353
367
  "mrecord",
354
- "cut-rectangle",
355
368
  "round-tag",
356
- "bottom-round-rectangle"
369
+ "bottom-round-rectangle",
370
+ "bottomroundrectangle"
357
371
  ],
358
372
  triangle: ["triangle", "invtriangle", "round-triangle", "tag"],
359
373
  diamond: ["diamond", "rhombus", "mdiamond", "round-diamond"],
360
374
  pentagon: ["pentagon", "round-pentagon"],
361
- hexagon: ["hexagon", "hexagon2", "round-hexagon", "concave-hexagon", "septagon", "heptagon", "round-heptagon"],
362
- octagon: ["octagon", "doubleoctagon", "tripleoctagon", "round-octagon", "octagon2"],
363
- parallelogram: ["parallelogram", "parallelogram2", "rhomboid", "fat-arrow", "fatarrow"],
375
+ hexagon: [
376
+ "hexagon",
377
+ "hexagon2",
378
+ "round-hexagon",
379
+ "concave-hexagon",
380
+ "concavehexagon",
381
+ "septagon",
382
+ "heptagon",
383
+ "round-heptagon"
384
+ ],
385
+ // a cut rectangle is a rectangle with its four corners cut off: eight sides
386
+ octagon: [
387
+ "octagon",
388
+ "doubleoctagon",
389
+ "tripleoctagon",
390
+ "round-octagon",
391
+ "octagon2",
392
+ "cut-rectangle",
393
+ "cutrectangle"
394
+ ],
395
+ parallelogram: ["parallelogram", "parallelogram2", "rhomboid", "right-rhomboid", "fat-arrow", "fatarrow"],
364
396
  trapezoid: ["trapezoid", "trapezoid2", "invtrapezoid", "trapezium", "round-trapezoid"],
365
397
  star: ["star", "star5", "star6", "star8", "polygon"],
366
398
  vee: ["vee", "v"],
@@ -426,7 +458,32 @@ const POSITIONS = {
426
458
  "top-right": ["top-right", "north-east", "northeast"],
427
459
  "bottom-left": ["bottom-left", "south-west", "southwest"],
428
460
  "bottom-right": ["bottom-right", "south-east", "southeast"],
429
- "inside-top": ["inside-top"]
461
+ "inside-top": ["inside-top"],
462
+ "inside-bottom": ["inside-bottom"],
463
+ "inside-left": ["inside-left"],
464
+ "inside-right": ["inside-right"],
465
+ "inside-top-left": ["inside-top-left"],
466
+ "inside-top-right": ["inside-top-right"],
467
+ "inside-bottom-left": ["inside-bottom-left"],
468
+ "inside-bottom-right": ["inside-bottom-right"]
469
+ };
470
+ const BORDER_POSITIONS = {
471
+ inside: ["inside"],
472
+ center: ["center", "centre", "middle"],
473
+ outside: ["outside"]
474
+ };
475
+ const ARROW_SIDES = {
476
+ left: ["left"],
477
+ right: ["right"]
478
+ };
479
+ const TEXT_ALIGNS = {
480
+ left: ["left", "start"],
481
+ center: ["center", "centre", "middle"],
482
+ right: ["right", "end"]
483
+ };
484
+ const LABEL_FITS = {
485
+ inside: ["inside"],
486
+ bounds: ["bounds"]
430
487
  };
431
488
  const VIS$1 = {
432
489
  shape: {
@@ -435,9 +492,27 @@ const VIS$1 = {
435
492
  triangle: ["triangledown"],
436
493
  none: ["text"]
437
494
  },
438
- arrow: { inverted: ["inv-triangle"], square: ["box"] }
495
+ // curve and inv_curve: an arc at the end, bulging toward the node and away from it
496
+ arrow: { inverted: ["inv-triangle"], square: ["box"], "other:curve": ["curve"], "other:inv-curve": ["inv-curve"] }
439
497
  };
440
- const OVERRIDES = /* @__PURE__ */ new Map([["vis", VIS$1]]);
498
+ const CYJS$1 = {
499
+ arrow: {
500
+ "other:triangle-tee": ["triangle-tee"],
501
+ "other:triangle-cross": ["triangle-cross"],
502
+ "other:circle-triangle": ["circle-triangle"],
503
+ // a vee two thirds as long as its triangle (0.2 of the arrow width against 0.3)
504
+ "other:chevron": ["chevron"],
505
+ vee: ["triangle-backcurve"]
506
+ }
507
+ };
508
+ const GRAPHVIZ = {
509
+ arrow: { "other:curve": ["curve"], "other:inv-curve": ["icurve"] }
510
+ };
511
+ const OVERRIDES = /* @__PURE__ */ new Map([
512
+ ["vis", VIS$1],
513
+ ["graphviz", GRAPHVIZ],
514
+ ["cytoscape-js", CYJS$1]
515
+ ]);
441
516
  const OPEN = /* @__PURE__ */ new Set(["shape", "borderStyle", "lineStyle", "arrow"]);
442
517
  function lookup(aliases) {
443
518
  const map = /* @__PURE__ */ new Map();
@@ -453,8 +528,12 @@ const COMMON = /* @__PURE__ */ new Map([
453
528
  ["borderStyle", lookup(BORDER_STYLES)],
454
529
  ["lineStyle", lookup(LINE_STYLES)],
455
530
  ["arrow", lookup(ARROWS)],
531
+ ["arrowSide", lookup(ARROW_SIDES)],
456
532
  ["weight", lookup(WEIGHTS)],
457
- ["position", lookup(POSITIONS)]
533
+ ["position", lookup(POSITIONS)],
534
+ ["labelFit", lookup(LABEL_FITS)],
535
+ ["borderPosition", lookup(BORDER_POSITIONS)],
536
+ ["textAlign", lookup(TEXT_ALIGNS)]
458
537
  ]);
459
538
  const DIALECT = new Map(
460
539
  Array.from(OVERRIDES, ([dialect, kinds]) => [
@@ -495,6 +574,13 @@ function dotLabelText(text, names, site) {
495
574
  if (site !== void 0) {
496
575
  spendAt(site, text.length);
497
576
  }
577
+ const out = replaceEscapes(
578
+ decodeEntities(substituteNames(text, names)),
579
+ (e) => e === "n" || e === "l" || e === "r" ? "\n" : e
580
+ );
581
+ return out.endsWith("\n") ? out.slice(0, -1) : out;
582
+ }
583
+ function substituteNames(text, names) {
498
584
  const subs = {
499
585
  N: names.node,
500
586
  G: names.graph,
@@ -502,9 +588,24 @@ function dotLabelText(text, names, site) {
502
588
  T: names.tail,
503
589
  H: names.head
504
590
  };
505
- const first = replaceEscapes(text, (e) => (Object.hasOwn(subs, e) ? subs[e] : void 0) ?? `\\${e}`);
506
- const out = replaceEscapes(first, (e) => e === "n" || e === "l" || e === "r" ? "\n" : e);
507
- return out.endsWith("\n") ? out.slice(0, -1) : out;
591
+ return replaceEscapes(text, (e) => (Object.hasOwn(subs, e) ? subs[e] : void 0) ?? `\\${e}`);
592
+ }
593
+ function dotLabelAlign(text, names) {
594
+ const parts = replaceEscapes(
595
+ substituteNames(text, names),
596
+ (e) => e === "n" || e === "l" || e === "r" ? `\0${e}\0` : "x"
597
+ ).split("\0");
598
+ const ends = parts.filter((_, i) => i % 2 === 1);
599
+ if (parts.at(-1) !== "") {
600
+ ends.push("n");
601
+ }
602
+ const count = (end) => ends.filter((e) => e === end).length;
603
+ const best = ["l", "r", "n"].filter((end) => count(end) === Math.max(count("l"), count("r"), count("n")));
604
+ const winner = best.length > 1 ? ends.find((e) => best.includes(e)) ?? "n" : best[0];
605
+ if (winner === "l") {
606
+ return "left";
607
+ }
608
+ return winner === "r" ? "right" : null;
508
609
  }
509
610
  function replaceEscapes(text, replace) {
510
611
  let out = "";
@@ -544,8 +645,12 @@ function entity(body) {
544
645
  function htmlLabelText(html, site) {
545
646
  spendAt(site, html.length);
546
647
  noteAt(site, STYLE_ISSUE.HTML_LABEL, html);
648
+ return htmlLabelSpans(html).map((s) => s.text).join("").trim();
649
+ }
650
+ const FONT_TAGS = /^<(\/?)(b|i|u|o|s|sub|sup|font)\b/i;
651
+ function htmlLabelSpans(html) {
547
652
  const body = html.startsWith("<") && html.endsWith(">") ? html.slice(1, -1) : html;
548
- let out = "";
653
+ const s = { spans: [], tags: [], out: "", open: [] };
549
654
  let i = 0;
550
655
  while (i < body.length) {
551
656
  const c = body[i];
@@ -554,20 +659,72 @@ function htmlLabelText(html, site) {
554
659
  if (close < 0) {
555
660
  break;
556
661
  }
557
- if (/^<br\b/i.test(body.slice(i, i + 4))) {
558
- out += "\n";
559
- }
662
+ readTag(s, body, i, close);
560
663
  i = close + 1;
561
- } else if (c === "&") {
562
- const [text, next] = entityAt(body, i);
563
- out += text;
564
- i = next;
565
664
  } else {
566
- out += c;
567
- i++;
665
+ const [text, next] = c === "&" ? entityAt(body, i) : [c, i + 1];
666
+ emitSpan(s, s.open.at(-1) === "table" ? "" : text);
667
+ i = next;
668
+ }
669
+ }
670
+ return s.spans;
671
+ }
672
+ function emitSpan(s, text) {
673
+ s.out += text;
674
+ const last = s.spans.at(-1);
675
+ if (last?.tags === s.tags) {
676
+ s.spans[s.spans.length - 1] = { text: last.text + text, tags: s.tags };
677
+ } else if (text !== "") {
678
+ s.spans.push({ text, tags: s.tags });
679
+ }
680
+ }
681
+ function lineHasText(s) {
682
+ return s.out.slice(s.out.lastIndexOf("\n") + 1).trim() !== "";
683
+ }
684
+ function readTag(s, body, i, close) {
685
+ const tag = /^<(\/?)(br|table|tr|td)\b/i.exec(body.slice(i, i + 7));
686
+ if (tag !== null) {
687
+ layoutTag(s, tag[2].toLowerCase(), tag[1] === "/");
688
+ return;
689
+ }
690
+ const font = FONT_TAGS.exec(body.slice(i, i + 6));
691
+ if (font !== null && font[1] === "/") {
692
+ s.tags = withoutLastTag(s.tags, font[2]);
693
+ } else if (font !== null && body[close - 1] !== "/") {
694
+ s.tags = [...s.tags, body.slice(i, close + 1)];
695
+ }
696
+ }
697
+ function layoutTag(s, name2, closing) {
698
+ if (name2 === "br" || name2 === "tr") {
699
+ if (name2 === "br" || !closing && lineHasText(s)) {
700
+ emitSpan(s, "\n");
701
+ }
702
+ } else if (closing) {
703
+ s.open.pop();
704
+ } else {
705
+ if (name2 === "td" && lineHasText(s)) {
706
+ emitSpan(s, " ");
568
707
  }
708
+ s.open.push(name2 === "td" ? "td" : "table");
569
709
  }
570
- return out.trim();
710
+ }
711
+ function withoutLastTag(tags, name2) {
712
+ const lower = name2.toLowerCase();
713
+ let at = tags.length - 1;
714
+ while (at >= 0 && /^<(\w+)/.exec(tags[at])?.[1].toLowerCase() !== lower) {
715
+ at--;
716
+ }
717
+ return at < 0 ? tags : [...tags.slice(0, at), ...tags.slice(at + 1)];
718
+ }
719
+ function decodeEntities(text) {
720
+ let out = "";
721
+ let i = 0;
722
+ for (let amp = text.indexOf("&"); amp >= 0; amp = text.indexOf("&", i)) {
723
+ const [decoded, next] = entityAt(text, amp);
724
+ out += text.slice(i, amp) + decoded;
725
+ i = next;
726
+ }
727
+ return out + text.slice(i);
571
728
  }
572
729
  function entityAt(body, i) {
573
730
  const near = body.slice(i + 1, i + 10).indexOf(";");
@@ -613,24 +770,132 @@ function recordLabelText(label, site) {
613
770
  const STYLE_PROPERTIES = Object.freeze({
614
771
  node: /* @__PURE__ */ new Map([
615
772
  ["fill", "color"],
773
+ ["fillGradient", "color"],
616
774
  ["borderColor", "color"],
617
775
  ["labelColor", "color"],
618
776
  ["fillOpacity", "opacity"],
619
777
  ["opacity", "opacity"],
778
+ ["borderOpacity", "opacity"],
620
779
  ["width", "number"],
621
780
  ["height", "number"],
622
781
  ["borderWidth", "number"],
623
782
  ["cornerRadius", "number"],
783
+ ["fillGradientAngle", "number"],
784
+ ["fillGradientColors", "text"],
785
+ ["fillGradientStops", "text"],
786
+ ["fillGradientKind", "text"],
624
787
  ["labelSize", "number"],
788
+ ["labelWrapWidth", "number"],
789
+ ["labelWrapTrailingSpace", "boolean"],
790
+ ["labelWrapEllipsis", "boolean"],
791
+ ["labelWrapAnywhere", "boolean"],
792
+ ["labelWrapSpaceCount", "number"],
793
+ ["labelRunAlign", "text"],
794
+ ["labelOffsetX", "signed"],
795
+ ["labelOffsetY", "signed"],
796
+ ["labelShiftX", "signed"],
797
+ ["labelShiftY", "signed"],
798
+ ["labelOpacity", "opacity"],
799
+ ["labelBackgroundOpacity", "opacity"],
800
+ ["labelFit", "labelFit"],
801
+ ["labelPaddingX", "number"],
802
+ ["labelPaddingY", "number"],
803
+ ["labelFitSquare", "boolean"],
625
804
  ["shape", "shape"],
805
+ ["shapePoints", "text"],
806
+ ["shapePointsStretch", "boolean"],
807
+ ["shapeParts", "text"],
808
+ ["shapeLines", "text"],
809
+ ["shapeLineWidth", "number"],
810
+ ["shapeTexts", "text"],
626
811
  ["borderStyle", "borderStyle"],
812
+ ["borderPosition", "borderPosition"],
813
+ ["borderWaveAmplitude", "number"],
814
+ ["borderWavePeriod", "number"],
815
+ ["outerBorderColor", "color"],
816
+ ["outerBorderWidth", "number"],
817
+ ["outerBorderOpacity", "opacity"],
818
+ ["outerBorderStyle", "borderStyle"],
819
+ ["outerBorderOffset", "number"],
820
+ ["underlayColor", "color"],
821
+ ["underlayOpacity", "opacity"],
822
+ ["underlayPadding", "number"],
823
+ ["underlayShape", "shape"],
824
+ ["underlayCornerRadius", "number"],
825
+ ["overlayColor", "color"],
826
+ ["overlayOpacity", "opacity"],
827
+ ["overlayPadding", "number"],
828
+ ["overlayShape", "shape"],
829
+ ["overlayCornerRadius", "number"],
627
830
  ["label", "text"],
628
831
  ["tooltip", "text"],
629
832
  ["labelFont", "text"],
630
833
  ["labelWeight", "weight"],
631
834
  ["labelItalic", "boolean"],
632
835
  ["labelPosition", "position"],
836
+ ["labelTextAlign", "textAlign"],
837
+ ["labelRuns", "text"],
838
+ ["labelMinScreenSize", "number"],
839
+ ["labelAvoidOverlap", "boolean"],
840
+ ["labelMinNodeScreenSize", "number"],
841
+ ["labelGridCellSize", "number"],
842
+ ["labelOnTop", "boolean"],
843
+ ["labelRotation", "number"],
844
+ ["labelBackground", "color"],
845
+ ["labelOutlineColor", "color"],
846
+ ["labelOutlineWidth", "number"],
847
+ ["labelBorderColor", "color"],
848
+ ["labelBorderWidth", "number"],
849
+ ["labelOutlineOpacity", "opacity"],
850
+ ["labelBorderOpacity", "opacity"],
851
+ ["labelPadding", "number"],
852
+ ["labelCornerRadius", "number"],
853
+ ["labelLineHeight", "number"],
633
854
  ["image", "text"],
855
+ ["imageFit", "text"],
856
+ ["imageFallback", "text"],
857
+ ["imageWidth", "number"],
858
+ ["imageHeight", "number"],
859
+ ["imagePositionX", "number"],
860
+ ["imagePositionY", "number"],
861
+ ["imageOffsetX", "signed"],
862
+ ["imageOffsetY", "signed"],
863
+ ["imageRepeat", "text"],
864
+ ["imageClip", "text"],
865
+ ["imageSmoothing", "boolean"],
866
+ ["imageAutoSize", "text"],
867
+ ["imageOpacity", "opacity"],
868
+ ["glyph", "text"],
869
+ ["glyphFont", "text"],
870
+ ["glyphSize", "number"],
871
+ ["glyphWeight", "weight"],
872
+ ["glyphColor", "color"],
873
+ ["pieColors", "text"],
874
+ ["pieSizes", "text"],
875
+ ["pieOpacities", "text"],
876
+ ["pieRadius", "number"],
877
+ ["pieHole", "number"],
878
+ ["pieRotation", "number"],
879
+ ["pieFitBox", "boolean"],
880
+ ["pieOffsetX", "signed"],
881
+ ["pieOffsetY", "signed"],
882
+ ["stripeColors", "text"],
883
+ ["stripeSizes", "text"],
884
+ ["stripeOpacities", "text"],
885
+ ["stripeDirection", "text"],
886
+ ["stripeSize", "number"],
887
+ ["chartKind", "text"],
888
+ ["chartValues", "text"],
889
+ ["chartColors", "text"],
890
+ ["chartMin", "signed"],
891
+ ["chartMax", "signed"],
892
+ ["chartHorizontal", "boolean"],
893
+ ["chartSize", "number"],
894
+ ["chartMargin", "signed"],
895
+ ["chartGap", "number"],
896
+ ["chartLineWidth", "number"],
897
+ ["chartBorderColor", "color"],
898
+ ["chartBorderWidth", "number"],
634
899
  ["visible", "boolean"]
635
900
  ]),
636
901
  edge: /* @__PURE__ */ new Map([
@@ -640,20 +905,101 @@ const STYLE_PROPERTIES = Object.freeze({
640
905
  ["labelColor", "color"],
641
906
  ["opacity", "opacity"],
642
907
  ["width", "number"],
908
+ ["minScreenWidth", "number"],
909
+ ["outlineWidth", "number"],
910
+ ["outlineColor", "color"],
911
+ ["outlineOpacity", "opacity"],
912
+ ["outlineStyle", "lineStyle"],
913
+ ["underlayColor", "color"],
914
+ ["underlayOpacity", "opacity"],
915
+ ["underlayPadding", "number"],
916
+ ["overlayColor", "color"],
917
+ ["overlayOpacity", "opacity"],
918
+ ["overlayPadding", "number"],
919
+ ["gradientColors", "text"],
920
+ ["gradientStops", "text"],
921
+ ["gradientKind", "text"],
643
922
  ["labelSize", "number"],
644
923
  ["arrowSize", "number"],
924
+ ["sourceArrowSize", "number"],
925
+ ["sourceArrowLength", "number"],
926
+ ["targetArrowLength", "number"],
927
+ ["sourceArrowWidth", "number"],
928
+ ["targetArrowWidth", "number"],
929
+ ["sourceArrowGap", "number"],
930
+ ["targetArrowGap", "number"],
931
+ ["sourceArrowSide", "arrowSide"],
932
+ ["targetArrowSide", "arrowSide"],
933
+ ["arrowPosition", "number"],
645
934
  ["lineStyle", "lineStyle"],
935
+ ["waveAmplitude", "number"],
936
+ ["wavePeriod", "number"],
646
937
  ["sourceArrow", "arrow"],
647
938
  ["targetArrow", "arrow"],
939
+ ["midTargetArrow", "arrow"],
940
+ ["midSourceArrow", "arrow"],
941
+ ["midTargetArrowColor", "color"],
942
+ ["midSourceArrowColor", "color"],
943
+ ["targetArrowImage", "text"],
944
+ ["sourceArrowImage", "text"],
945
+ ["midTargetArrowImage", "text"],
946
+ ["targetArrowImageWidth", "number"],
947
+ ["targetArrowImageHeight", "number"],
948
+ ["sourceArrowImageWidth", "number"],
949
+ ["sourceArrowImageHeight", "number"],
950
+ ["midTargetArrowImageWidth", "number"],
951
+ ["midTargetArrowImageHeight", "number"],
648
952
  ["curved", "boolean"],
649
953
  ["bends", "text"],
954
+ ["fanSpacing", "number"],
955
+ ["fanned", "boolean"],
956
+ ["bendCurve", "text"],
957
+ ["arcRadius", "number"],
958
+ ["nodeGap", "number"],
959
+ ["sourcePort", "text"],
960
+ ["targetPort", "text"],
650
961
  ["label", "text"],
651
962
  ["tooltip", "text"],
652
963
  ["labelFont", "text"],
653
964
  ["labelWeight", "weight"],
965
+ ["labelTextAlign", "textAlign"],
966
+ ["labelRuns", "text"],
654
967
  ["labelItalic", "boolean"],
968
+ ["labelWrapWidth", "number"],
969
+ ["labelWrapEllipsis", "boolean"],
970
+ ["labelWrapAnywhere", "boolean"],
971
+ ["labelWrapSpaceCount", "number"],
972
+ ["labelRunAlign", "text"],
973
+ ["labelPosition", "position"],
974
+ ["labelRotation", "number"],
975
+ ["labelOffsetX", "signed"],
976
+ ["labelOffsetY", "signed"],
977
+ ["labelShiftX", "signed"],
978
+ ["labelShiftY", "signed"],
979
+ ["labelOpacity", "opacity"],
980
+ ["labelBackgroundOpacity", "opacity"],
981
+ ["labelBackground", "color"],
982
+ ["labelOutlineColor", "color"],
983
+ ["labelOutlineWidth", "number"],
984
+ ["labelBorderColor", "color"],
985
+ ["labelBorderWidth", "number"],
986
+ ["labelOutlineOpacity", "opacity"],
987
+ ["labelBorderOpacity", "opacity"],
988
+ ["labelPadding", "number"],
989
+ ["labelCornerRadius", "number"],
990
+ ["labelLineHeight", "number"],
655
991
  ["sourceLabel", "text"],
656
992
  ["targetLabel", "text"],
993
+ ["sourceLabelOffset", "number"],
994
+ ["targetLabelOffset", "number"],
995
+ ["sourceLabelOffsetX", "signed"],
996
+ ["sourceLabelOffsetY", "signed"],
997
+ ["targetLabelOffsetX", "signed"],
998
+ ["targetLabelOffsetY", "signed"],
999
+ ["sourceLabelRotation", "number"],
1000
+ ["targetLabelRotation", "number"],
1001
+ ["labelMinScreenSize", "number"],
1002
+ ["labelOnTop", "boolean"],
657
1003
  ["visible", "boolean"]
658
1004
  ]),
659
1005
  graph: /* @__PURE__ */ new Map([["background", "color"]])
@@ -674,10 +1020,12 @@ const STYLE_ENUMS = /* @__PURE__ */ new Map([
674
1020
  "trapezoid",
675
1021
  "star",
676
1022
  "vee",
1023
+ "polygon",
677
1024
  "none"
678
1025
  ]
679
1026
  ],
680
1027
  ["borderStyle", ["solid", "dashed", "dotted", "dash-dot", "double"]],
1028
+ ["borderPosition", ["inside", "center", "outside"]],
681
1029
  ["lineStyle", ["solid", "dashed", "dotted", "dash-dot", "long-dash", "double", "zigzag", "sinewave"]],
682
1030
  [
683
1031
  "arrow",
@@ -697,7 +1045,10 @@ const STYLE_ENUMS = /* @__PURE__ */ new Map([
697
1045
  "inverted"
698
1046
  ]
699
1047
  ],
1048
+ ["arrowSide", ["left", "right"]],
700
1049
  ["weight", ["normal", "bold"]],
1050
+ ["textAlign", ["left", "center", "right"]],
1051
+ ["labelFit", ["inside", "bounds"]],
701
1052
  [
702
1053
  "position",
703
1054
  [
@@ -710,7 +1061,14 @@ const STYLE_ENUMS = /* @__PURE__ */ new Map([
710
1061
  "top-right",
711
1062
  "bottom-left",
712
1063
  "bottom-right",
713
- "inside-top"
1064
+ "inside-top",
1065
+ "inside-bottom",
1066
+ "inside-left",
1067
+ "inside-right",
1068
+ "inside-top-left",
1069
+ "inside-top-right",
1070
+ "inside-bottom-left",
1071
+ "inside-bottom-right"
714
1072
  ]
715
1073
  ]
716
1074
  ]);
@@ -727,6 +1085,8 @@ function isStyleValue(target, property, value) {
727
1085
  return typeof value === "string" && /^#[0-9a-f]{6}$/.test(value);
728
1086
  case "number":
729
1087
  return typeof value === "number" && Number.isFinite(value) && value >= 0;
1088
+ case "signed":
1089
+ return typeof value === "number" && Number.isFinite(value);
730
1090
  case "opacity":
731
1091
  return typeof value === "number" && value >= 0 && value <= 1;
732
1092
  case "text":
@@ -898,7 +1258,18 @@ function matches(where, src, i, depth = 0) {
898
1258
  }
899
1259
  return false;
900
1260
  }
901
- const ENUM_KINDS = /* @__PURE__ */ new Set(["shape", "borderStyle", "lineStyle", "arrow", "weight", "position"]);
1261
+ const ENUM_KINDS = /* @__PURE__ */ new Set([
1262
+ "shape",
1263
+ "borderStyle",
1264
+ "lineStyle",
1265
+ "arrow",
1266
+ "arrowSide",
1267
+ "weight",
1268
+ "position",
1269
+ "labelFit",
1270
+ "borderPosition",
1271
+ "textAlign"
1272
+ ]);
902
1273
  function canonicalFor(target, property) {
903
1274
  const kind = STYLE_PROPERTIES[target].get(property);
904
1275
  const site = { notes: new StyleNotes(), target, property };
@@ -910,6 +1281,8 @@ function canonicalFor(target, property) {
910
1281
  return (raw) => typeof raw === "string" && /^#[0-9a-fA-F]{6}$/.test(raw) ? raw.toLowerCase() : null;
911
1282
  case "number":
912
1283
  return (raw) => canonNumber(raw, site);
1284
+ case "signed":
1285
+ return (raw) => canonSigned(raw, site);
913
1286
  case "opacity":
914
1287
  return (raw) => canonOpacity(raw, "css", site);
915
1288
  case "boolean":
@@ -1097,12 +1470,18 @@ function ruleValue(rule, property, canon, src, i) {
1097
1470
  return mapping2 === void 0 ? null : evalMapping(mapping2, canon, src, i);
1098
1471
  }
1099
1472
  function resolveStyles(extracted, target, property, snapshot) {
1473
+ return resolveRules(extracted.styles.rules, target, property, sourceOf(extracted, target, snapshot));
1474
+ }
1475
+ function matchPredicate(extracted, target, where, snapshot) {
1476
+ const src = sourceOf(extracted, target, snapshot);
1477
+ return Array.from({ length: src.n }, (_v, i) => matches(where, src, i));
1478
+ }
1479
+ function sourceOf(extracted, target, snapshot) {
1100
1480
  let n = extracted.fingerprint[target === "node" ? "nodes" : "edges"];
1101
1481
  if (snapshot !== void 0) {
1102
1482
  n = target === "node" ? snapshot.nodeCount : snapshot.edgeCount;
1103
1483
  }
1104
- const src = refSource(target, n, extracted.columns[target], extracted.features[target], snapshot);
1105
- return resolveRules(extracted.styles.rules, target, property, src);
1484
+ return refSource(target, n, extracted.columns[target], extracted.features[target], snapshot);
1106
1485
  }
1107
1486
  function within(a, b) {
1108
1487
  if (a === b) {
@@ -1133,10 +1512,10 @@ const CSS_COLORS = table(
1133
1512
  "aliceblue=f0f8ff antiquewhite=faebd7 aqua=00ffff aquamarine=7fffd4 azure=f0ffff beige=f5f5dc bisque=ffe4c4 black=000000 blanchedalmond=ffebcd blue=0000ff blueviolet=8a2be2 brown=a52a2a burlywood=deb887 cadetblue=5f9ea0 chartreuse=7fff00 chocolate=d2691e coral=ff7f50 cornflowerblue=6495ed cornsilk=fff8dc crimson=dc143c cyan=00ffff darkblue=00008b darkcyan=008b8b darkgoldenrod=b8860b darkgray=a9a9a9 darkgreen=006400 darkgrey=a9a9a9 darkkhaki=bdb76b darkmagenta=8b008b darkolivegreen=556b2f darkorange=ff8c00 darkorchid=9932cc darkred=8b0000 darksalmon=e9967a darkseagreen=8fbc8f darkslateblue=483d8b darkslategray=2f4f4f darkslategrey=2f4f4f darkturquoise=00ced1 darkviolet=9400d3 deeppink=ff1493 deepskyblue=00bfff dimgray=696969 dimgrey=696969 dodgerblue=1e90ff firebrick=b22222 floralwhite=fffaf0 forestgreen=228b22 fuchsia=ff00ff gainsboro=dcdcdc ghostwhite=f8f8ff gold=ffd700 goldenrod=daa520 gray=808080 green=008000 greenyellow=adff2f grey=808080 honeydew=f0fff0 hotpink=ff69b4 indianred=cd5c5c indigo=4b0082 ivory=fffff0 khaki=f0e68c lavender=e6e6fa lavenderblush=fff0f5 lawngreen=7cfc00 lemonchiffon=fffacd lightblue=add8e6 lightcoral=f08080 lightcyan=e0ffff lightgoldenrodyellow=fafad2 lightgray=d3d3d3 lightgreen=90ee90 lightgrey=d3d3d3 lightpink=ffb6c1 lightsalmon=ffa07a lightseagreen=20b2aa lightskyblue=87cefa lightslategray=778899 lightslategrey=778899 lightsteelblue=b0c4de lightyellow=ffffe0 lime=00ff00 limegreen=32cd32 linen=faf0e6 magenta=ff00ff maroon=800000 mediumaquamarine=66cdaa mediumblue=0000cd mediumorchid=ba55d3 mediumpurple=9370db mediumseagreen=3cb371 mediumslateblue=7b68ee mediumspringgreen=00fa9a mediumturquoise=48d1cc mediumvioletred=c71585 midnightblue=191970 mintcream=f5fffa mistyrose=ffe4e1 moccasin=ffe4b5 navajowhite=ffdead navy=000080 oldlace=fdf5e6 olive=808000 olivedrab=6b8e23 orange=ffa500 orangered=ff4500 orchid=da70d6 palegoldenrod=eee8aa palegreen=98fb98 paleturquoise=afeeee palevioletred=db7093 papayawhip=ffefd5 peachpuff=ffdab9 peru=cd853f pink=ffc0cb plum=dda0dd powderblue=b0e0e6 purple=800080 rebeccapurple=663399 red=ff0000 rosybrown=bc8f8f royalblue=4169e1 saddlebrown=8b4513 salmon=fa8072 sandybrown=f4a460 seagreen=2e8b57 seashell=fff5ee sienna=a0522d silver=c0c0c0 skyblue=87ceeb slateblue=6a5acd slategray=708090 slategrey=708090 snow=fffafa springgreen=00ff7f steelblue=4682b4 tan=d2b48c teal=008080 thistle=d8bfd8 tomato=ff6347 turquoise=40e0d0 violet=ee82ee wheat=f5deb3 white=ffffff whitesmoke=f5f5f5 yellow=ffff00 yellowgreen=9acd32"
1134
1513
  );
1135
1514
  const X11_COLORS = table(
1136
- "aliceblue=f0f8ff antiquewhite=faebd7 antiquewhite1=ffefdb antiquewhite2=eedfcc antiquewhite3=cdc0b0 antiquewhite4=8b8378 aqua=00ffff aquamarine=7fffd4 aquamarine1=7fffd4 aquamarine2=76eec6 aquamarine3=66cdaa aquamarine4=458b74 azure=f0ffff azure1=f0ffff azure2=e0eeee azure3=c1cdcd azure4=838b8b beige=f5f5dc bisque=ffe4c4 bisque1=ffe4c4 bisque2=eed5b7 bisque3=cdb79e bisque4=8b7d6b black=000000 blanchedalmond=ffebcd blue=0000ff blue1=0000ff blue2=0000ee blue3=0000cd blue4=00008b blueviolet=8a2be2 brown=a52a2a brown1=ff4040 brown2=ee3b3b brown3=cd3333 brown4=8b2323 burlywood=deb887 burlywood1=ffd39b burlywood2=eec591 burlywood3=cdaa7d burlywood4=8b7355 cadetblue=5f9ea0 cadetblue1=98f5ff cadetblue2=8ee5ee cadetblue3=7ac5cd cadetblue4=53868b chartreuse=7fff00 chartreuse1=7fff00 chartreuse2=76ee00 chartreuse3=66cd00 chartreuse4=458b00 chocolate=d2691e chocolate1=ff7f24 chocolate2=ee7621 chocolate3=cd661d chocolate4=8b4513 coral=ff7f50 coral1=ff7256 coral2=ee6a50 coral3=cd5b45 coral4=8b3e2f cornflowerblue=6495ed cornsilk=fff8dc cornsilk1=fff8dc cornsilk2=eee8cd cornsilk3=cdc8b1 cornsilk4=8b8878 crimson=dc143c cyan=00ffff cyan1=00ffff cyan2=00eeee cyan3=00cdcd cyan4=008b8b darkblue=00008b darkcyan=008b8b darkgoldenrod=b8860b darkgoldenrod1=ffb90f darkgoldenrod2=eead0e darkgoldenrod3=cd950c darkgoldenrod4=8b6508 darkgray=a9a9a9 darkgreen=006400 darkgrey=a9a9a9 darkkhaki=bdb76b darkmagenta=8b008b darkolivegreen=556b2f darkolivegreen1=caff70 darkolivegreen2=bcee68 darkolivegreen3=a2cd5a darkolivegreen4=6e8b3d darkorange=ff8c00 darkorange1=ff7f00 darkorange2=ee7600 darkorange3=cd6600 darkorange4=8b4500 darkorchid=9932cc darkorchid1=bf3eff darkorchid2=b23aee darkorchid3=9a32cd darkorchid4=68228b darkred=8b0000 darksalmon=e9967a darkseagreen=8fbc8f darkseagreen1=c1ffc1 darkseagreen2=b4eeb4 darkseagreen3=9bcd9b darkseagreen4=698b69 darkslateblue=483d8b darkslategray=2f4f4f darkslategray1=97ffff darkslategray2=8deeee darkslategray3=79cdcd darkslategray4=528b8b darkslategrey=2f4f4f darkturquoise=00ced1 darkviolet=9400d3 deeppink=ff1493 deeppink1=ff1493 deeppink2=ee1289 deeppink3=cd1076 deeppink4=8b0a50 deepskyblue=00bfff deepskyblue1=00bfff deepskyblue2=00b2ee deepskyblue3=009acd deepskyblue4=00688b dimgray=696969 dimgrey=696969 dodgerblue=1e90ff dodgerblue1=1e90ff dodgerblue2=1c86ee dodgerblue3=1874cd dodgerblue4=104e8b firebrick=b22222 firebrick1=ff3030 firebrick2=ee2c2c firebrick3=cd2626 firebrick4=8b1a1a floralwhite=fffaf0 forestgreen=228b22 fuchsia=ff00ff gainsboro=dcdcdc ghostwhite=f8f8ff gold=ffd700 gold1=ffd700 gold2=eec900 gold3=cdad00 gold4=8b7500 goldenrod=daa520 goldenrod1=ffc125 goldenrod2=eeb422 goldenrod3=cd9b1d goldenrod4=8b6914 gray=c0c0c0 gray0=000000 gray1=030303 gray10=1a1a1a gray100=ffffff gray11=1c1c1c gray12=1f1f1f gray13=212121 gray14=242424 gray15=262626 gray16=292929 gray17=2b2b2b gray18=2e2e2e gray19=303030 gray2=050505 gray20=333333 gray21=363636 gray22=383838 gray23=3b3b3b gray24=3d3d3d gray25=404040 gray26=424242 gray27=454545 gray28=474747 gray29=4a4a4a gray3=080808 gray30=4d4d4d gray31=4f4f4f gray32=525252 gray33=545454 gray34=575757 gray35=595959 gray36=5c5c5c gray37=5e5e5e gray38=616161 gray39=636363 gray4=0a0a0a gray40=666666 gray41=696969 gray42=6b6b6b gray43=6e6e6e gray44=707070 gray45=737373 gray46=757575 gray47=787878 gray48=7a7a7a gray49=7d7d7d gray5=0d0d0d gray50=7f7f7f gray51=828282 gray52=858585 gray53=878787 gray54=8a8a8a gray55=8c8c8c gray56=8f8f8f gray57=919191 gray58=949494 gray59=969696 gray6=0f0f0f gray60=999999 gray61=9c9c9c gray62=9e9e9e gray63=a1a1a1 gray64=a3a3a3 gray65=a6a6a6 gray66=a8a8a8 gray67=ababab gray68=adadad gray69=b0b0b0 gray7=121212 gray70=b3b3b3 gray71=b5b5b5 gray72=b8b8b8 gray73=bababa gray74=bdbdbd gray75=bfbfbf gray76=c2c2c2 gray77=c4c4c4 gray78=c7c7c7 gray79=c9c9c9 gray8=141414 gray80=cccccc gray81=cfcfcf gray82=d1d1d1 gray83=d4d4d4 gray84=d6d6d6 gray85=d9d9d9 gray86=dbdbdb gray87=dedede gray88=e0e0e0 gray89=e3e3e3 gray9=171717 gray90=e5e5e5 gray91=e8e8e8 gray92=ebebeb gray93=ededed gray94=f0f0f0 gray95=f2f2f2 gray96=f5f5f5 gray97=f7f7f7 gray98=fafafa gray99=fcfcfc green=00ff00 green1=00ff00 green2=00ee00 green3=00cd00 green4=008b00 greenyellow=adff2f grey=c0c0c0 grey0=000000 grey1=030303 grey10=1a1a1a grey100=ffffff grey11=1c1c1c grey12=1f1f1f grey13=212121 grey14=242424 grey15=262626 grey16=292929 grey17=2b2b2b grey18=2e2e2e grey19=303030 grey2=050505 grey20=333333 grey21=363636 grey22=383838 grey23=3b3b3b grey24=3d3d3d grey25=404040 grey26=424242 grey27=454545 grey28=474747 grey29=4a4a4a grey3=080808 grey30=4d4d4d grey31=4f4f4f grey32=525252 grey33=545454 grey34=575757 grey35=595959 grey36=5c5c5c grey37=5e5e5e grey38=616161 grey39=636363 grey4=0a0a0a grey40=666666 grey41=696969 grey42=6b6b6b grey43=6e6e6e grey44=707070 grey45=737373 grey46=757575 grey47=787878 grey48=7a7a7a grey49=7d7d7d grey5=0d0d0d grey50=7f7f7f grey51=828282 grey52=858585 grey53=878787 grey54=8a8a8a grey55=8c8c8c grey56=8f8f8f grey57=919191 grey58=949494 grey59=969696 grey6=0f0f0f grey60=999999 grey61=9c9c9c grey62=9e9e9e grey63=a1a1a1 grey64=a3a3a3 grey65=a6a6a6 grey66=a8a8a8 grey67=ababab grey68=adadad grey69=b0b0b0 grey7=121212 grey70=b3b3b3 grey71=b5b5b5 grey72=b8b8b8 grey73=bababa grey74=bdbdbd grey75=bfbfbf grey76=c2c2c2 grey77=c4c4c4 grey78=c7c7c7 grey79=c9c9c9 grey8=141414 grey80=cccccc grey81=cfcfcf grey82=d1d1d1 grey83=d4d4d4 grey84=d6d6d6 grey85=d9d9d9 grey86=dbdbdb grey87=dedede grey88=e0e0e0 grey89=e3e3e3 grey9=171717 grey90=e5e5e5 grey91=e8e8e8 grey92=ebebeb grey93=ededed grey94=f0f0f0 grey95=f2f2f2 grey96=f5f5f5 grey97=f7f7f7 grey98=fafafa grey99=fcfcfc honeydew=f0fff0 honeydew1=f0fff0 honeydew2=e0eee0 honeydew3=c1cdc1 honeydew4=838b83 hotpink=ff69b4 hotpink1=ff6eb4 hotpink2=ee6aa7 hotpink3=cd6090 hotpink4=8b3a62 indianred=cd5c5c indianred1=ff6a6a indianred2=ee6363 indianred3=cd5555 indianred4=8b3a3a indigo=4b0082 ivory=fffff0 ivory1=fffff0 ivory2=eeeee0 ivory3=cdcdc1 ivory4=8b8b83 khaki=f0e68c khaki1=fff68f khaki2=eee685 khaki3=cdc673 khaki4=8b864e lavender=e6e6fa lavenderblush=fff0f5 lavenderblush1=fff0f5 lavenderblush2=eee0e5 lavenderblush3=cdc1c5 lavenderblush4=8b8386 lawngreen=7cfc00 lemonchiffon=fffacd lemonchiffon1=fffacd lemonchiffon2=eee9bf lemonchiffon3=cdc9a5 lemonchiffon4=8b8970 lightblue=add8e6 lightblue1=bfefff lightblue2=b2dfee lightblue3=9ac0cd lightblue4=68838b lightcoral=f08080 lightcyan=e0ffff lightcyan1=e0ffff lightcyan2=d1eeee lightcyan3=b4cdcd lightcyan4=7a8b8b lightgoldenrod=eedd82 lightgoldenrod1=ffec8b lightgoldenrod2=eedc82 lightgoldenrod3=cdbe70 lightgoldenrod4=8b814c lightgoldenrodyellow=fafad2 lightgray=d3d3d3 lightgreen=90ee90 lightgrey=d3d3d3 lightpink=ffb6c1 lightpink1=ffaeb9 lightpink2=eea2ad lightpink3=cd8c95 lightpink4=8b5f65 lightsalmon=ffa07a lightsalmon1=ffa07a lightsalmon2=ee9572 lightsalmon3=cd8162 lightsalmon4=8b5742 lightseagreen=20b2aa lightskyblue=87cefa lightskyblue1=b0e2ff lightskyblue2=a4d3ee lightskyblue3=8db6cd lightskyblue4=607b8b lightslateblue=8470ff lightslategray=778899 lightslategrey=778899 lightsteelblue=b0c4de lightsteelblue1=cae1ff lightsteelblue2=bcd2ee lightsteelblue3=a2b5cd lightsteelblue4=6e7b8b lightyellow=ffffe0 lightyellow1=ffffe0 lightyellow2=eeeed1 lightyellow3=cdcdb4 lightyellow4=8b8b7a lime=00ff00 limegreen=32cd32 linen=faf0e6 magenta=ff00ff magenta1=ff00ff magenta2=ee00ee magenta3=cd00cd magenta4=8b008b maroon=b03060 maroon1=ff34b3 maroon2=ee30a7 maroon3=cd2990 maroon4=8b1c62 mediumaquamarine=66cdaa mediumblue=0000cd mediumorchid=ba55d3 mediumorchid1=e066ff mediumorchid2=d15fee mediumorchid3=b452cd mediumorchid4=7a378b mediumpurple=9370db mediumpurple1=ab82ff mediumpurple2=9f79ee mediumpurple3=8968cd mediumpurple4=5d478b mediumseagreen=3cb371 mediumslateblue=7b68ee mediumspringgreen=00fa9a mediumturquoise=48d1cc mediumvioletred=c71585 midnightblue=191970 mintcream=f5fffa mistyrose=ffe4e1 mistyrose1=ffe4e1 mistyrose2=eed5d2 mistyrose3=cdb7b5 mistyrose4=8b7d7b moccasin=ffe4b5 navajowhite=ffdead navajowhite1=ffdead navajowhite2=eecfa1 navajowhite3=cdb38b navajowhite4=8b795e navy=000080 navyblue=000080 oldlace=fdf5e6 olive=808000 olivedrab=6b8e23 olivedrab1=c0ff3e olivedrab2=b3ee3a olivedrab3=9acd32 olivedrab4=698b22 orange=ffa500 orange1=ffa500 orange2=ee9a00 orange3=cd8500 orange4=8b5a00 orangered=ff4500 orangered1=ff4500 orangered2=ee4000 orangered3=cd3700 orangered4=8b2500 orchid=da70d6 orchid1=ff83fa orchid2=ee7ae9 orchid3=cd69c9 orchid4=8b4789 palegoldenrod=eee8aa palegreen=98fb98 palegreen1=9aff9a palegreen2=90ee90 palegreen3=7ccd7c palegreen4=548b54 paleturquoise=afeeee paleturquoise1=bbffff paleturquoise2=aeeeee paleturquoise3=96cdcd paleturquoise4=668b8b palevioletred=db7093 palevioletred1=ff82ab palevioletred2=ee799f palevioletred3=cd6889 palevioletred4=8b475d papayawhip=ffefd5 peachpuff=ffdab9 peachpuff1=ffdab9 peachpuff2=eecbad peachpuff3=cdaf95 peachpuff4=8b7765 peru=cd853f pink=ffc0cb pink1=ffb5c5 pink2=eea9b8 pink3=cd919e pink4=8b636c plum=dda0dd plum1=ffbbff plum2=eeaeee plum3=cd96cd plum4=8b668b powderblue=b0e0e6 purple=a020f0 purple1=9b30ff purple2=912cee purple3=7d26cd purple4=551a8b rebeccapurple=663399 red=ff0000 red1=ff0000 red2=ee0000 red3=cd0000 red4=8b0000 rosybrown=bc8f8f rosybrown1=ffc1c1 rosybrown2=eeb4b4 rosybrown3=cd9b9b rosybrown4=8b6969 royalblue=4169e1 royalblue1=4876ff royalblue2=436eee royalblue3=3a5fcd royalblue4=27408b saddlebrown=8b4513 salmon=fa8072 salmon1=ff8c69 salmon2=ee8262 salmon3=cd7054 salmon4=8b4c39 sandybrown=f4a460 seagreen=2e8b57 seagreen1=54ff9f seagreen2=4eee94 seagreen3=43cd80 seagreen4=2e8b57 seashell=fff5ee seashell1=fff5ee seashell2=eee5de seashell3=cdc5bf seashell4=8b8682 sienna=a0522d sienna1=ff8247 sienna2=ee7942 sienna3=cd6839 sienna4=8b4726 silver=c0c0c0 skyblue=87ceeb skyblue1=87ceff skyblue2=7ec0ee skyblue3=6ca6cd skyblue4=4a708b slateblue=6a5acd slateblue1=836fff slateblue2=7a67ee slateblue3=6959cd slateblue4=473c8b slategray=708090 slategray1=c6e2ff slategray2=b9d3ee slategray3=9fb6cd slategray4=6c7b8b slategrey=708090 snow=fffafa snow1=fffafa snow2=eee9e9 snow3=cdc9c9 snow4=8b8989 springgreen=00ff7f springgreen1=00ff7f springgreen2=00ee76 springgreen3=00cd66 springgreen4=008b45 steelblue=4682b4 steelblue1=63b8ff steelblue2=5cacee steelblue3=4f94cd steelblue4=36648b tan=d2b48c tan1=ffa54f tan2=ee9a49 tan3=cd853f tan4=8b5a2b teal=008080 thistle=d8bfd8 thistle1=ffe1ff thistle2=eed2ee thistle3=cdb5cd thistle4=8b7b8b tomato=ff6347 tomato1=ff6347 tomato2=ee5c42 tomato3=cd4f39 tomato4=8b3626 turquoise=40e0d0 turquoise1=00f5ff turquoise2=00e5ee turquoise3=00c5cd turquoise4=00868b violet=ee82ee violetred=d02090 violetred1=ff3e96 violetred2=ee3a8c violetred3=cd3278 violetred4=8b2252 wheat=f5deb3 wheat1=ffe7ba wheat2=eed8ae wheat3=cdba96 wheat4=8b7e66 white=ffffff whitesmoke=f5f5f5 yellow=ffff00 yellow1=ffff00 yellow2=eeee00 yellow3=cdcd00 yellow4=8b8b00 yellowgreen=9acd32"
1515
+ "aliceblue=f0f8ff antiquewhite=faebd7 antiquewhite1=ffefdb antiquewhite2=eedfcc antiquewhite3=cdc0b0 antiquewhite4=8b8378 aqua=00ffff aquamarine=7fffd4 aquamarine1=7fffd4 aquamarine2=76eec6 aquamarine3=66cdaa aquamarine4=458b74 azure=f0ffff azure1=f0ffff azure2=e0eeee azure3=c1cdcd azure4=838b8b beige=f5f5dc bisque=ffe4c4 bisque1=ffe4c4 bisque2=eed5b7 bisque3=cdb79e bisque4=8b7d6b black=000000 blanchedalmond=ffebcd blue=0000ff blue1=0000ff blue2=0000ee blue3=0000cd blue4=00008b blueviolet=8a2be2 brown=a52a2a brown1=ff4040 brown2=ee3b3b brown3=cd3333 brown4=8b2323 burlywood=deb887 burlywood1=ffd39b burlywood2=eec591 burlywood3=cdaa7d burlywood4=8b7355 cadetblue=5f9ea0 cadetblue1=98f5ff cadetblue2=8ee5ee cadetblue3=7ac5cd cadetblue4=53868b chartreuse=7fff00 chartreuse1=7fff00 chartreuse2=76ee00 chartreuse3=66cd00 chartreuse4=458b00 chocolate=d2691e chocolate1=ff7f24 chocolate2=ee7621 chocolate3=cd661d chocolate4=8b4513 coral=ff7f50 coral1=ff7256 coral2=ee6a50 coral3=cd5b45 coral4=8b3e2f cornflowerblue=6495ed cornsilk=fff8dc cornsilk1=fff8dc cornsilk2=eee8cd cornsilk3=cdc8b1 cornsilk4=8b8878 crimson=dc143c cyan=00ffff cyan1=00ffff cyan2=00eeee cyan3=00cdcd cyan4=008b8b darkblue=00008b darkcyan=008b8b darkgoldenrod=b8860b darkgoldenrod1=ffb90f darkgoldenrod2=eead0e darkgoldenrod3=cd950c darkgoldenrod4=8b6508 darkgray=a9a9a9 darkgreen=006400 darkgrey=a9a9a9 darkkhaki=bdb76b darkmagenta=8b008b darkolivegreen=556b2f darkolivegreen1=caff70 darkolivegreen2=bcee68 darkolivegreen3=a2cd5a darkolivegreen4=6e8b3d darkorange=ff8c00 darkorange1=ff7f00 darkorange2=ee7600 darkorange3=cd6600 darkorange4=8b4500 darkorchid=9932cc darkorchid1=bf3eff darkorchid2=b23aee darkorchid3=9a32cd darkorchid4=68228b darkred=8b0000 darksalmon=e9967a darkseagreen=8fbc8f darkseagreen1=c1ffc1 darkseagreen2=b4eeb4 darkseagreen3=9bcd9b darkseagreen4=698b69 darkslateblue=483d8b darkslategray=2f4f4f darkslategray1=97ffff darkslategray2=8deeee darkslategray3=79cdcd darkslategray4=528b8b darkslategrey=2f4f4f darkturquoise=00ced1 darkviolet=9400d3 deeppink=ff1493 deeppink1=ff1493 deeppink2=ee1289 deeppink3=cd1076 deeppink4=8b0a50 deepskyblue=00bfff deepskyblue1=00bfff deepskyblue2=00b2ee deepskyblue3=009acd deepskyblue4=00688b dimgray=696969 dimgrey=696969 dodgerblue=1e90ff dodgerblue1=1e90ff dodgerblue2=1c86ee dodgerblue3=1874cd dodgerblue4=104e8b firebrick=b22222 firebrick1=ff3030 firebrick2=ee2c2c firebrick3=cd2626 firebrick4=8b1a1a floralwhite=fffaf0 forestgreen=228b22 fuchsia=ff00ff gainsboro=dcdcdc ghostwhite=f8f8ff gold=ffd700 gold1=ffd700 gold2=eec900 gold3=cdad00 gold4=8b7500 goldenrod=daa520 goldenrod1=ffc125 goldenrod2=eeb422 goldenrod3=cd9b1d goldenrod4=8b6914 gray=c0c0c0 gray0=000000 gray1=030303 gray10=1a1a1a gray100=ffffff gray11=1c1c1c gray12=1f1f1f gray13=212121 gray14=242424 gray15=262626 gray16=292929 gray17=2b2b2b gray18=2e2e2e gray19=303030 gray2=050505 gray20=333333 gray21=363636 gray22=383838 gray23=3b3b3b gray24=3d3d3d gray25=404040 gray26=424242 gray27=454545 gray28=474747 gray29=4a4a4a gray3=080808 gray30=4d4d4d gray31=4f4f4f gray32=525252 gray33=545454 gray34=575757 gray35=595959 gray36=5c5c5c gray37=5e5e5e gray38=616161 gray39=636363 gray4=0a0a0a gray40=666666 gray41=696969 gray42=6b6b6b gray43=6e6e6e gray44=707070 gray45=737373 gray46=757575 gray47=787878 gray48=7a7a7a gray49=7d7d7d gray5=0d0d0d gray50=7f7f7f gray51=828282 gray52=858585 gray53=878787 gray54=8a8a8a gray55=8c8c8c gray56=8f8f8f gray57=919191 gray58=949494 gray59=969696 gray6=0f0f0f gray60=999999 gray61=9c9c9c gray62=9e9e9e gray63=a1a1a1 gray64=a3a3a3 gray65=a6a6a6 gray66=a8a8a8 gray67=ababab gray68=adadad gray69=b0b0b0 gray7=121212 gray70=b3b3b3 gray71=b5b5b5 gray72=b8b8b8 gray73=bababa gray74=bdbdbd gray75=bfbfbf gray76=c2c2c2 gray77=c4c4c4 gray78=c7c7c7 gray79=c9c9c9 gray8=141414 gray80=cccccc gray81=cfcfcf gray82=d1d1d1 gray83=d4d4d4 gray84=d6d6d6 gray85=d9d9d9 gray86=dbdbdb gray87=dedede gray88=e0e0e0 gray89=e3e3e3 gray9=171717 gray90=e5e5e5 gray91=e8e8e8 gray92=ebebeb gray93=ededed gray94=f0f0f0 gray95=f2f2f2 gray96=f5f5f5 gray97=f7f7f7 gray98=fafafa gray99=fcfcfc green=00ff00 green1=00ff00 green2=00ee00 green3=00cd00 green4=008b00 greenyellow=adff2f grey=c0c0c0 grey0=000000 grey1=030303 grey10=1a1a1a grey100=ffffff grey11=1c1c1c grey12=1f1f1f grey13=212121 grey14=242424 grey15=262626 grey16=292929 grey17=2b2b2b grey18=2e2e2e grey19=303030 grey2=050505 grey20=333333 grey21=363636 grey22=383838 grey23=3b3b3b grey24=3d3d3d grey25=404040 grey26=424242 grey27=454545 grey28=474747 grey29=4a4a4a grey3=080808 grey30=4d4d4d grey31=4f4f4f grey32=525252 grey33=545454 grey34=575757 grey35=595959 grey36=5c5c5c grey37=5e5e5e grey38=616161 grey39=636363 grey4=0a0a0a grey40=666666 grey41=696969 grey42=6b6b6b grey43=6e6e6e grey44=707070 grey45=737373 grey46=757575 grey47=787878 grey48=7a7a7a grey49=7d7d7d grey5=0d0d0d grey50=7f7f7f grey51=828282 grey52=858585 grey53=878787 grey54=8a8a8a grey55=8c8c8c grey56=8f8f8f grey57=919191 grey58=949494 grey59=969696 grey6=0f0f0f grey60=999999 grey61=9c9c9c grey62=9e9e9e grey63=a1a1a1 grey64=a3a3a3 grey65=a6a6a6 grey66=a8a8a8 grey67=ababab grey68=adadad grey69=b0b0b0 grey7=121212 grey70=b3b3b3 grey71=b5b5b5 grey72=b8b8b8 grey73=bababa grey74=bdbdbd grey75=bfbfbf grey76=c2c2c2 grey77=c4c4c4 grey78=c7c7c7 grey79=c9c9c9 grey8=141414 grey80=cccccc grey81=cfcfcf grey82=d1d1d1 grey83=d4d4d4 grey84=d6d6d6 grey85=d9d9d9 grey86=dbdbdb grey87=dedede grey88=e0e0e0 grey89=e3e3e3 grey9=171717 grey90=e5e5e5 grey91=e8e8e8 grey92=ebebeb grey93=ededed grey94=f0f0f0 grey95=f2f2f2 grey96=f5f5f5 grey97=f7f7f7 grey98=fafafa grey99=fcfcfc honeydew=f0fff0 honeydew1=f0fff0 honeydew2=e0eee0 honeydew3=c1cdc1 honeydew4=838b83 hotpink=ff69b4 hotpink1=ff6eb4 hotpink2=ee6aa7 hotpink3=cd6090 hotpink4=8b3a62 indianred=cd5c5c indianred1=ff6a6a indianred2=ee6363 indianred3=cd5555 indianred4=8b3a3a indigo=4b0082 ivory=fffff0 ivory1=fffff0 ivory2=eeeee0 ivory3=cdcdc1 ivory4=8b8b83 khaki=f0e68c khaki1=fff68f khaki2=eee685 khaki3=cdc673 khaki4=8b864e lavender=e6e6fa lavenderblush=fff0f5 lavenderblush1=fff0f5 lavenderblush2=eee0e5 lavenderblush3=cdc1c5 lavenderblush4=8b8386 lawngreen=7cfc00 lemonchiffon=fffacd lemonchiffon1=fffacd lemonchiffon2=eee9bf lemonchiffon3=cdc9a5 lemonchiffon4=8b8970 lightblue=add8e6 lightblue1=bfefff lightblue2=b2dfee lightblue3=9ac0cd lightblue4=68838b lightcoral=f08080 lightcyan=e0ffff lightcyan1=e0ffff lightcyan2=d1eeee lightcyan3=b4cdcd lightcyan4=7a8b8b lightgoldenrod=eedd82 lightgoldenrod1=ffec8b lightgoldenrod2=eedc82 lightgoldenrod3=cdbe70 lightgoldenrod4=8b814c lightgoldenrodyellow=fafad2 lightgray=d3d3d3 lightgreen=90ee90 lightgrey=d3d3d3 lightpink=ffb6c1 lightpink1=ffaeb9 lightpink2=eea2ad lightpink3=cd8c95 lightpink4=8b5f65 lightsalmon=ffa07a lightsalmon1=ffa07a lightsalmon2=ee9572 lightsalmon3=cd8162 lightsalmon4=8b5742 lightseagreen=20b2aa lightskyblue=87cefa lightskyblue1=b0e2ff lightskyblue2=a4d3ee lightskyblue3=8db6cd lightskyblue4=607b8b lightslateblue=8470ff lightslategray=778899 lightslategrey=778899 lightsteelblue=b0c4de lightsteelblue1=cae1ff lightsteelblue2=bcd2ee lightsteelblue3=a2b5cd lightsteelblue4=6e7b8b lightyellow=ffffe0 lightyellow1=ffffe0 lightyellow2=eeeed1 lightyellow3=cdcdb4 lightyellow4=8b8b7a lime=00ff00 limegreen=32cd32 linen=faf0e6 magenta=ff00ff magenta1=ff00ff magenta2=ee00ee magenta3=cd00cd magenta4=8b008b maroon=b03060 maroon1=ff34b3 maroon2=ee30a7 maroon3=cd2990 maroon4=8b1c62 mediumaquamarine=66cdaa mediumblue=0000cd mediumorchid=ba55d3 mediumorchid1=e066ff mediumorchid2=d15fee mediumorchid3=b452cd mediumorchid4=7a378b mediumpurple=9370db mediumpurple1=ab82ff mediumpurple2=9f79ee mediumpurple3=8968cd mediumpurple4=5d478b mediumseagreen=3cb371 mediumslateblue=7b68ee mediumspringgreen=00fa9a mediumturquoise=48d1cc mediumvioletred=c71585 midnightblue=191970 mintcream=f5fffa mistyrose=ffe4e1 mistyrose1=ffe4e1 mistyrose2=eed5d2 mistyrose3=cdb7b5 mistyrose4=8b7d7b moccasin=ffe4b5 navajowhite=ffdead navajowhite1=ffdead navajowhite2=eecfa1 navajowhite3=cdb38b navajowhite4=8b795e navy=000080 navyblue=000080 oldlace=fdf5e6 olive=808000 olivedrab=6b8e23 olivedrab1=c0ff3e olivedrab2=b3ee3a olivedrab3=9acd32 olivedrab4=698b22 orange=ffa500 orange1=ffa500 orange2=ee9a00 orange3=cd8500 orange4=8b5a00 orangered=ff4500 orangered1=ff4500 orangered2=ee4000 orangered3=cd3700 orangered4=8b2500 orchid=da70d6 orchid1=ff83fa orchid2=ee7ae9 orchid3=cd69c9 orchid4=8b4789 palegoldenrod=eee8aa palegreen=98fb98 palegreen1=9aff9a palegreen2=90ee90 palegreen3=7ccd7c palegreen4=548b54 paleturquoise=afeeee paleturquoise1=bbffff paleturquoise2=aeeeee paleturquoise3=96cdcd paleturquoise4=668b8b palevioletred=db7093 palevioletred1=ff82ab palevioletred2=ee799f palevioletred3=cd6889 palevioletred4=8b475d papayawhip=ffefd5 peachpuff=ffdab9 peachpuff1=ffdab9 peachpuff2=eecbad peachpuff3=cdaf95 peachpuff4=8b7765 peru=cd853f pink=ffc0cb pink1=ffb5c5 pink2=eea9b8 pink3=cd919e pink4=8b636c plum=dda0dd plum1=ffbbff plum2=eeaeee plum3=cd96cd plum4=8b668b powderblue=b0e0e6 purple=a020f0 purple1=9b30ff purple2=912cee purple3=7d26cd purple4=551a8b rebeccapurple=663399 red=ff0000 red1=ff0000 red2=ee0000 red3=cd0000 red4=8b0000 rosybrown=bc8f8f rosybrown1=ffc1c1 rosybrown2=eeb4b4 rosybrown3=cd9b9b rosybrown4=8b6969 royalblue=4169e1 royalblue1=4876ff royalblue2=436eee royalblue3=3a5fcd royalblue4=27408b saddlebrown=8b4513 salmon=fa8072 salmon1=ff8c69 salmon2=ee8262 salmon3=cd7054 salmon4=8b4c39 sandybrown=f4a460 seagreen=2e8b57 seagreen1=54ff9f seagreen2=4eee94 seagreen3=43cd80 seagreen4=2e8b57 seashell=fff5ee seashell1=fff5ee seashell2=eee5de seashell3=cdc5bf seashell4=8b8682 sienna=a0522d sienna1=ff8247 sienna2=ee7942 sienna3=cd6839 sienna4=8b4726 silver=c0c0c0 skyblue=87ceeb skyblue1=87ceff skyblue2=7ec0ee skyblue3=6ca6cd skyblue4=4a708b slateblue=6a5acd slateblue1=836fff slateblue2=7a67ee slateblue3=6959cd slateblue4=473c8b slategray=708090 slategray1=c6e2ff slategray2=b9d3ee slategray3=9fb6cd slategray4=6c7b8b slategrey=708090 snow=fffafa snow1=fffafa snow2=eee9e9 snow3=cdc9c9 snow4=8b8989 springgreen=00ff7f springgreen1=00ff7f springgreen2=00ee76 springgreen3=00cd66 springgreen4=008b45 steelblue=4682b4 steelblue1=63b8ff steelblue2=5cacee steelblue3=4f94cd steelblue4=36648b tan=d2b48c tan1=ffa54f tan2=ee9a49 tan3=cd853f tan4=8b5a2b teal=008080 thistle=d8bfd8 thistle1=ffe1ff thistle2=eed2ee thistle3=cdb5cd thistle4=8b7b8b tomato=ff6347 tomato1=ff6347 tomato2=ee5c42 tomato3=cd4f39 tomato4=8b3626 turquoise=40e0d0 turquoise1=00f5ff turquoise2=00e5ee turquoise3=00c5cd turquoise4=00868b violet=ee82ee violetred=d02090 violetred1=ff3e96 violetred2=ee3a8c violetred3=cd3278 violetred4=8b2252 wheat=f5deb3 wheat1=ffe7ba wheat2=eed8ae wheat3=cdba96 wheat4=8b7e66 white=ffffff webgray=808080 webgreen=008000 webgrey=808080 webmaroon=800000 webpurple=800080 x11gray=bebebe x11green=00ff00 x11grey=bebebe x11maroon=b03060 x11purple=a020f0 whitesmoke=f5f5f5 yellow=ffff00 yellow1=ffff00 yellow2=eeee00 yellow3=cdcd00 yellow4=8b8b00 yellowgreen=9acd32"
1137
1516
  );
1138
1517
  const DVIPS_COLORS = table(
1139
- "GreenYellow=d9ff4f Yellow=ffff00 Goldenrod=ffe629 Dandelion=ffb529 Apricot=ffad7a Peach=ff804d Melon=ff8a80 YellowOrange=ff9400 Orange=ff6321 BurntOrange=ff7d00 Bittersweet=c20300 RedOrange=ff3b21 Mahogany=a60000 Maroon=ad0000 BrickRed=b80000 Red=ff0000 OrangeRed=ff0080 RubineRed=ff00de WildStrawberry=ff0a9c Salmon=ff789e CarnationPink=ff5eff Magenta=ff00ff VioletRed=ff30ff Rhodamine=ff2eff Mulberry=a314fa RedViolet=9600a8 Fuchsia=7303eb Lavender=ff85ff Thistle=e069ff Orchid=ad5cff DarkOrchid=9933cc Purple=8c24ff Plum=8000ff Violet=361fff RoyalPurple=4019ff BlueViolet=190df5 Periwinkle=6e73ff CadetBlue=616ec4 CornflowerBlue=59deff MidnightBlue=007091 NavyBlue=0f75ff RoyalBlue=0080ff Blue=0000ff Cerulean=0fe3ff Cyan=00ffff ProcessBlue=0affff SkyBlue=61ffe0 Turquoise=26ffcc TealBlue=1ffaa3 Aquamarine=2effb2 BlueGreen=26ffab Emerald=00ff80 JungleGreen=03ff7a SeaGreen=4fff80 Green=00ff00 ForestGreen=00e000 PineGreen=00bf29 LimeGreen=80ff00 YellowGreen=8fff42 SpringGreen=bdff3d OliveGreen=009900 RawSienna=8c0000 Sepia=4d0000 Brown=660000 Tan=db9470 Gray=808080 Black=000000 White=ffffff LightYellow=ffff99 LightCyan=ccffff LightMagenta=ffccff LightPurple=ccccff LightGreen=ccffb3 LightOrange=ffccb3 Canary=ffff7f LFadedGreen=e6ffcc Pink=ffd9f3 LSkyBlue=d9f3ff"
1518
+ "GreenYellow=d9ff4f Yellow=ffff00 Goldenrod=ffe629 Dandelion=ffb529 Apricot=ffad7a Peach=ff804d Melon=ff8a80 YellowOrange=ff9400 Orange=ff6321 BurntOrange=ff7d00 Bittersweet=c20300 RedOrange=ff3b21 Mahogany=a60000 Maroon=ad0000 BrickRed=b80000 Red=ff0000 OrangeRed=ff0080 RubineRed=ff00de WildStrawberry=ff0a9c Salmon=ff789e CarnationPink=ff5eff Magenta=ff00ff VioletRed=ff30ff Rhodamine=ff2eff Mulberry=a314fa RedViolet=9600a8 Fuchsia=7303eb Lavender=ff85ff Thistle=e069ff Orchid=ad5cff DarkOrchid=9933cc Purple=8c24ff Plum=8000ff Violet=361fff RoyalPurple=4019ff BlueViolet=190df5 Periwinkle=6e73ff CadetBlue=616ec4 CornflowerBlue=59deff MidnightBlue=007091 NavyBlue=0f75ff RoyalBlue=0080ff Blue=0000ff Cerulean=0fe3ff Cyan=00ffff ProcessBlue=0affff SkyBlue=61ffe0 Turquoise=26ffcc TealBlue=1ffaa3 Aquamarine=2effb2 BlueGreen=26ffab Emerald=00ff80 JungleGreen=03ff7a SeaGreen=4fff80 Green=00ff00 ForestGreen=00e000 PineGreen=00bf29 LimeGreen=80ff00 YellowGreen=8fff42 SpringGreen=bdff3d OliveGreen=009900 RawSienna=8c0000 Sepia=4d0000 Brown=660000 Tan=db9470 Gray=808080 Black=000000 White=ffffff LightYellow=ffff99 LightCyan=ccffff LightMagenta=ffccff LightPurple=ccccff LightGreen=ccffb3 LightOrange=ffd9bc Canary=ffff80 LFadedGreen=e6ffcc Pink=ffd9f2 LSkyBlue=d9f2ff"
1140
1519
  );
1141
1520
  const JAVA_COLORS = table(
1142
1521
  "black=000000 blue=0000ff cyan=00ffff darkgray=404040 dark_gray=404040 gray=808080 green=00ff00 lightgray=c0c0c0 light_gray=c0c0c0 magenta=ff00ff orange=ffc800 pink=ffafaf red=ff0000 white=ffffff yellow=ffff00"
@@ -1226,22 +1605,40 @@ function schemeColor(name2, scheme) {
1226
1605
  const index = /^\d{1,3}$/.test(name2) ? Number(name2) : 0;
1227
1606
  return colors !== void 0 && index >= 1 ? colors[index - 1] : void 0;
1228
1607
  }
1229
- function graphvizColor(raw, scheme, use) {
1608
+ function svgPenList(use) {
1609
+ return use === "line" ? { hex: "#fffffe", alpha: 0, unknown: false, list: null } : { hex: "#000000", alpha: 1, unknown: false, list: null };
1610
+ }
1611
+ function beforeSemicolon(text) {
1612
+ const semi = text.indexOf(";");
1613
+ return semi >= 0 ? text.slice(0, semi) : text;
1614
+ }
1615
+ function resolveColorText(raw, text, scheme, svgNames) {
1616
+ const svgName = svgNames && raw.startsWith(text) ? CSS_COLORS.get(text.toLowerCase()) : void 0;
1617
+ if (svgName !== void 0) {
1618
+ return { hex: svgName, alpha: 1 };
1619
+ }
1620
+ if (text === "") {
1621
+ return null;
1622
+ }
1623
+ const sc = scheme === null || scheme.trim() === "" ? "x11" : scheme.toLowerCase();
1624
+ return resolveOne(text, sc);
1625
+ }
1626
+ function graphvizColor(raw, scheme, use, svgNames = true) {
1230
1627
  let text = raw.replace(/^[ \t\r\n]+/, "");
1231
1628
  let list = null;
1232
1629
  const colon = text.indexOf(":");
1630
+ const pen = use === "line" || use === "text";
1233
1631
  if (colon >= 0) {
1234
1632
  text = text.slice(0, colon);
1235
- if (use !== "line") {
1236
- const semi = text.indexOf(";");
1237
- if (semi >= 0) {
1238
- text = text.slice(0, semi);
1239
- }
1633
+ if (svgNames && pen && raw.startsWith(text) && CSS_COLORS.has(text.toLowerCase())) {
1634
+ return svgPenList(use);
1635
+ }
1636
+ if (!pen) {
1637
+ text = beforeSemicolon(text);
1240
1638
  list = use === "fill" ? "gradient" : "lines";
1241
1639
  }
1242
1640
  }
1243
- const sc = scheme === null || scheme.trim() === "" ? "x11" : scheme.toLowerCase();
1244
- const resolved = text === "" ? null : resolveOne(text, sc);
1641
+ const resolved = resolveColorText(raw, text, scheme, svgNames);
1245
1642
  return resolved === null ? { hex: "#000000", alpha: 1, unknown: true, list } : { hex: resolved.hex, alpha: resolved.alpha, unknown: false, list };
1246
1643
  }
1247
1644
  function hex2(v2) {
@@ -1472,6 +1869,56 @@ function cssColor(text) {
1472
1869
  }
1473
1870
  return hexColor(text, false) ?? cssFunction(text);
1474
1871
  }
1872
+ function sigmaRgba(text) {
1873
+ const t = text.trim();
1874
+ const head = /^rgba?\s*\(/.exec(t);
1875
+ if (head === null || !t.endsWith(")")) {
1876
+ return null;
1877
+ }
1878
+ const parts = t.slice(head[0].length, -1).split(",");
1879
+ if (parts.length < 3) {
1880
+ return null;
1881
+ }
1882
+ const alpha = parts.slice(3).join(",").trimStart();
1883
+ const third = parts.length > 3 ? parts[2].trim() : parts[2].trimStart();
1884
+ const channels2 = [parts[0].trim(), parts[1].trim(), third];
1885
+ if (!channels2.every((c) => /^\d*$/.test(c)) || /[\n\r\u2028\u2029]/.test(alpha)) {
1886
+ return null;
1887
+ }
1888
+ return [channels2[0], channels2[1], channels2[2], alpha];
1889
+ }
1890
+ function sigmaColor(text) {
1891
+ const lower = text.toLowerCase();
1892
+ if (lower === "transparent") {
1893
+ return { color: "#000000", alpha: 0, read: true };
1894
+ }
1895
+ const named = CSS_COLORS.get(lower);
1896
+ if (named !== void 0) {
1897
+ return sigmaColor(named);
1898
+ }
1899
+ let rgb = [0, 0, 0];
1900
+ let a = 1;
1901
+ let read = false;
1902
+ if (text.startsWith("#")) {
1903
+ read = /^#(?:[\da-f]{3}|[\da-f]{6}|[\da-f]{8})$/i.test(text);
1904
+ const at = text.length === 4 ? [1, 1, 2, 2, 3, 3] : [1, 2, 3, 4, 5, 6];
1905
+ rgb = [0, 2, 4].map((k) => Number.parseInt(text.charAt(at[k]) + text.charAt(at[k + 1]), 16) || 0);
1906
+ if (text.length === 9) {
1907
+ a = Number.parseInt(text.slice(7, 9), 16) / 255;
1908
+ }
1909
+ } else {
1910
+ const m = sigmaRgba(text);
1911
+ if (m !== null) {
1912
+ read = true;
1913
+ rgb = [Number(m[0]), Number(m[1]), Number(m[2])];
1914
+ if (m[3]) {
1915
+ a = Number(m[3]);
1916
+ }
1917
+ }
1918
+ }
1919
+ const [r, g, b] = rgb.map((v2) => v2 & 255);
1920
+ return { color: rgbHex(r, g, b), alpha: (a * 255 & 255) / 255, read };
1921
+ }
1475
1922
  const PAJEK_CHANNEL = /^(?:\d+(?:\.\d*)?|\.\d+)$/;
1476
1923
  function pajekColor(text) {
1477
1924
  const named = DVIPS_COLORS.get(text);
@@ -1534,6 +1981,11 @@ function canonColor(raw, dialect, site, options = {}) {
1534
1981
  const v2 = raw >>> 0;
1535
1982
  return { color: rgbHex(v2 >>> 16 & 255, v2 >>> 8 & 255, v2 & 255), alpha: 1 };
1536
1983
  }
1984
+ if (dialect === "graphology" && typeof raw === "string" && raw.trim() === "") {
1985
+ spendAt(site, 1);
1986
+ noteAt(site, STYLE_ISSUE.BAD_VALUE, raw);
1987
+ return { color: "#000000", alpha: 1 };
1988
+ }
1537
1989
  const text = scalarText(raw, site);
1538
1990
  if (text === null) {
1539
1991
  return null;
@@ -1541,6 +1993,9 @@ function canonColor(raw, dialect, site, options = {}) {
1541
1993
  if (dialect === "graphviz" || dialect === "x11") {
1542
1994
  return graphvizCanon(text, dialect === "x11" ? "x11" : "graphviz", site, options);
1543
1995
  }
1996
+ if (dialect === "graphology") {
1997
+ return graphologyColor(raw, text, site);
1998
+ }
1544
1999
  const c = textColor(text.trim(), dialect);
1545
2000
  if (c === null) {
1546
2001
  noteAt(site, STYLE_ISSUE.BAD_VALUE, text);
@@ -1548,6 +2003,17 @@ function canonColor(raw, dialect, site, options = {}) {
1548
2003
  }
1549
2004
  return { color: c.hex, alpha: c.alpha };
1550
2005
  }
2006
+ function graphologyColor(raw, text, site) {
2007
+ if (typeof raw !== "string") {
2008
+ noteAt(site, STYLE_ISSUE.BAD_VALUE, text);
2009
+ return null;
2010
+ }
2011
+ const c = sigmaColor(text);
2012
+ if (!c.read) {
2013
+ noteAt(site, STYLE_ISSUE.BAD_VALUE, text);
2014
+ }
2015
+ return { color: c.color, alpha: c.alpha };
2016
+ }
1551
2017
  function objectColor(raw, dialect, site) {
1552
2018
  spendAt(site, 1);
1553
2019
  const c = dialect === "gexf" || dialect === "gephi" ? channels(raw) : null;
@@ -1558,10 +2024,11 @@ function objectColor(raw, dialect, site) {
1558
2024
  return { color: c.hex, alpha: c.alpha };
1559
2025
  }
1560
2026
  function graphvizCanon(text, dialect, site, options) {
1561
- const g = graphvizColor(text, dialect === "x11" ? null : options.scheme ?? null, options.use ?? "line");
2027
+ const x11 = dialect === "x11";
2028
+ const g = graphvizColor(text, x11 ? null : options.scheme ?? null, options.use ?? "line", !x11);
1562
2029
  if (g.unknown) {
1563
2030
  noteAt(site, STYLE_ISSUE.BAD_VALUE, text);
1564
- if (dialect === "x11") {
2031
+ if (x11) {
1565
2032
  return null;
1566
2033
  }
1567
2034
  }
@@ -1604,6 +2071,7 @@ function v(value, source) {
1604
2071
  }
1605
2072
  const CY = "cytoscape-impl vizmap-gui-impl default_vizmap.xml, style default, line";
1606
2073
  const CYL = "cytoscape-api BasicVisualLexicon.java line";
2074
+ const CY_WAVE = "cytoscape-impl ding-presentation-impl 3.10.5 org.cytoscape.ding.impl.strokes: ZigzagStroke (amplitude 10, a turn every 10) and SineWaveStroke (amplitude 10, wavelength 20)";
1607
2075
  const CYJS = "cytoscape.js 3.34.3 dist/cytoscape.cjs.js line";
1608
2076
  const GV = "graphviz.org/docs/attrs";
1609
2077
  const YED_QA = "yEd Q&A, How can I change the default nodes and/or default edges";
@@ -1613,18 +2081,61 @@ const YED_BG = "yFiles for Java 2.19 DefaultBackgroundRenderer API docs";
1613
2081
  const Y3 = "yFiles for HTML API docs,";
1614
2082
  const GEPHI = "gephi master 92e503df61a7";
1615
2083
  const VIS = "vis-network 10.1.2 vis-network.esm.js";
2084
+ const VIS9 = "vis-network 9.1.9 standalone/umd/vis-network.js";
1616
2085
  const SIGMA = "sigma 3.0.3 packages/sigma/src";
1617
- const GEXFJS = "github.com/raphv/gexf-js ebfd2a7213d3 js/gexfjs.js";
2086
+ const SIGMA4 = "sigma 4.0.1 dist/types-d8ce3382.esm.js";
1618
2087
  const PAJEK = "Pajek 6.02 reference manual";
1619
- const PAJEK_SHAPES = "the SHAPES.CFG Pajek writes when none exists (DrawEPS.htm), github.com/ohshane/radical-clustering 0f568f67893558035868b3db1bf365870ba52f6b shapes.cfg, SHAPE ELLIPSE";
1620
2088
  const OGDF = "ogdf master 1a40505ac006";
2089
+ const OGDF_SVG = "OGDF 2025.10 GraphIO::drawSVG with its default SVGSettings (graph-io/test/fidelity/oracles/gml-specimen-labels-p5.svg: ";
1621
2090
  const NX = "networkx 6da4704cbf32 networkx/drawing/nx_pylab.py line";
2091
+ const MEASURED = "measured in the program's own SVG export (graph-io/test/fidelity/oracles/";
2092
+ const PAJEK_SVG = `${MEASURED}pajek-`;
2093
+ const CYTOSCAPE_ARROWHEAD = {
2094
+ length: (size, width) => 2 * (6 * size + width),
2095
+ aspect: 0.5,
2096
+ shapes: {
2097
+ square: { length: 0.5, aspect: 1 },
2098
+ circle: { length: 0.5, aspect: 1 },
2099
+ "circle-open": { length: 0.5, aspect: 1 },
2100
+ // HALF_TOP's barb: 1.135 long and 1 to one side of its line
2101
+ half: { length: 0.5675, aspect: 0.881 },
2102
+ "other:half-bottom": { length: 0.5675, aspect: 0.881 },
2103
+ tee: { length: 0.1, aspect: 10 },
2104
+ // a square's outline, and a half circle (half a CIRCLE deep, as wide)
2105
+ "other:open-square": { length: 0.5, aspect: 1 },
2106
+ "other:half-circle": { length: 0.25, aspect: 2 },
2107
+ "other:open-half-circle": { length: 0.25, aspect: 2 }
2108
+ },
2109
+ source: `${MEASURED}cx-ndex-90f78bcd, cx2-u2os-hierarchy, cx2-signor-aml, cx2-syn-bypass, cx-syn-mappings: each arrow's unit glyph), Cytoscape 3.10.5`
2110
+ };
2111
+ const CYTOSCAPE_BEND_CURVE = v(
2112
+ "midpoints",
2113
+ "cytoscape-impl ding-presentation-impl GraphGraphics.java computeCubicPolyEdgePath (cubic pieces between the handles' midpoints, controls pulled toward each handle by CURVE_ELLIPTICAL)"
2114
+ );
2115
+ const CYTOSCAPE_LABEL_BOX = `${MEASURED}xgmml-specimen-labels: label-background-* boxes and the captions' two lines), Cytoscape 3.10.5`;
2116
+ const CYTOSCAPE_LABEL_PADDING = v(0, CYTOSCAPE_LABEL_BOX);
2117
+ const CYTOSCAPE_LABEL_LINE_HEIGHT = v(1, CYTOSCAPE_LABEL_BOX);
2118
+ const CYTOSCAPE_BORDER_INSIDE = v(
2119
+ "inside",
2120
+ `${MEASURED}cx2-repro-shared-interaction, cys-luad-vest-v2, cx2-synthetic-lethal), Cytoscape 3.10.5`
2121
+ );
2122
+ const DRAWIO_ARROWHEAD = {
2123
+ length: (size, width) => 6 * size + width,
2124
+ aspect: 1,
2125
+ source: `${MEASURED}graphml-*, draw.io 32.4.1 standing in for yEd)`
2126
+ };
2127
+ function cornerCap(tool) {
2128
+ const rule = `${CYJS} 4386`;
2129
+ return v(8, tool === void 0 ? rule : `${rule} (Cytoscape.js's rule; ${tool} states none)`);
2130
+ }
1622
2131
  const TOOL_DEFAULTS = new Map(
1623
2132
  [
1624
2133
  {
1625
2134
  tool: "cytoscape",
1626
2135
  version: "cytoscape-impl develop 6c63e97c5152 (3.11)",
1627
2136
  units: "px",
2137
+ roundedCornerRadius: cornerCap("cytoscape"),
2138
+ arrowhead: CYTOSCAPE_ARROWHEAD,
1628
2139
  node: {
1629
2140
  fill: v("#89d0f5", `${CY} 382`),
1630
2141
  fillOpacity: v(1, `${CY} 383`),
@@ -1634,29 +2145,44 @@ const TOOL_DEFAULTS = new Map(
1634
2145
  borderColor: v("#cccccc", `${CY} 392`),
1635
2146
  borderWidth: v(0, `${CY} 350`),
1636
2147
  borderStyle: v("solid", `${CY} 366`),
2148
+ borderPosition: CYTOSCAPE_BORDER_INSIDE,
2149
+ borderWaveAmplitude: v(10, CY_WAVE),
2150
+ borderWavePeriod: v(20, CY_WAVE),
1637
2151
  labelColor: v("#000000", `${CY} 395`),
1638
- labelFont: v("sans-serif", `${CY} 370`),
2152
+ labelFont: v("DejaVu Sans, sans-serif", `${CY} 370 (SansSerif, drawn in Java's face for it)`),
1639
2153
  labelWeight: v("normal", `${CY} 370`),
1640
2154
  labelItalic: v(false, `${CY} 370`),
1641
2155
  labelSize: v(12, `${CY} 371`),
1642
- labelPosition: v("center", `${CY} 380`)
2156
+ labelWrapWidth: v(200, `${CY} 372`),
2157
+ labelWrapTrailingSpace: v(
2158
+ true,
2159
+ `${MEASURED}cx-ndex-90f78bcd: each word is measured with the space after it), Cytoscape 3.10.5`
2160
+ ),
2161
+ labelPosition: v("center", `${CY} 380`),
2162
+ labelPadding: CYTOSCAPE_LABEL_PADDING,
2163
+ labelLineHeight: CYTOSCAPE_LABEL_LINE_HEIGHT
1643
2164
  },
1644
2165
  edge: {
1645
2166
  color: v("#848484", `${CY} 431`),
1646
2167
  width: v(2, `${CY} 417`),
1647
2168
  lineStyle: v("solid", `${CY} 438`),
2169
+ waveAmplitude: v(10, CY_WAVE),
2170
+ wavePeriod: v(20, CY_WAVE),
1648
2171
  opacity: v(1, `${CY} 423`),
1649
2172
  sourceArrow: v("none", `${CY} 437`),
1650
2173
  targetArrow: v("none", `${CY} 428`),
1651
2174
  sourceArrowColor: v("#000000", `${CY} 432`),
1652
2175
  targetArrowColor: v("#000000", `${CY} 432`),
1653
2176
  labelColor: v("#000000", `${CY} 415`),
1654
- labelFont: v("sans-serif", `${CY} 439`),
2177
+ labelFont: v("DejaVu Sans, sans-serif", `${CY} 439 (SansSerif, drawn in Java's face for it)`),
1655
2178
  labelWeight: v("normal", `${CY} 439`),
1656
2179
  labelItalic: v(false, `${CY} 439`),
1657
2180
  labelSize: v(10, `${CY} 439`),
2181
+ labelPadding: CYTOSCAPE_LABEL_PADDING,
2182
+ labelLineHeight: CYTOSCAPE_LABEL_LINE_HEIGHT,
1658
2183
  // EDGE_CURVED is true there, but it only rounds an edge's bends: an edge without bends is straight
1659
- curved: v(false, `${CY} 422`)
2184
+ curved: v(false, `${CY} 422`),
2185
+ bendCurve: CYTOSCAPE_BEND_CURVE
1660
2186
  },
1661
2187
  graph: { background: v("#ffffff", `${CY} 335`) },
1662
2188
  derived: [{ kind: "labelFromColumn", column: "name", source: `${CY} 406-408` }]
@@ -1665,6 +2191,8 @@ const TOOL_DEFAULTS = new Map(
1665
2191
  tool: "cytoscape-fallbacks",
1666
2192
  version: "cytoscape-api develop (3.11)",
1667
2193
  units: "px",
2194
+ roundedCornerRadius: cornerCap("cytoscape-fallbacks"),
2195
+ arrowhead: CYTOSCAPE_ARROWHEAD,
1668
2196
  node: {
1669
2197
  fill: v("#c80000", `${CYL} 83`),
1670
2198
  fillOpacity: v(1, `${CYL} 273`),
@@ -1673,24 +2201,39 @@ const TOOL_DEFAULTS = new Map(
1673
2201
  height: v(40, `${CYL} 163`),
1674
2202
  borderColor: v("#000000", `${CYL} 230`),
1675
2203
  borderWidth: v(2, `${CYL} 54`),
2204
+ borderPosition: CYTOSCAPE_BORDER_INSIDE,
2205
+ borderWaveAmplitude: v(10, CY_WAVE),
2206
+ borderWavePeriod: v(20, CY_WAVE),
1676
2207
  labelColor: v("#000000", `${CYL} 91`),
1677
- labelFont: v("sans-serif", `${CYL} 255`),
2208
+ labelFont: v("DejaVu Sans, sans-serif", `${CYL} 255 (SansSerif, drawn in Java's face for it)`),
1678
2209
  labelWeight: v("normal", `${CYL} 255`),
1679
2210
  labelItalic: v(false, `${CYL} 255`),
1680
2211
  labelSize: v(12, `${CYL} 55`),
1681
- labelPosition: v("center", `${CYL} 205`)
2212
+ labelWrapWidth: v(200, `${CYL} 196`),
2213
+ labelWrapTrailingSpace: v(
2214
+ true,
2215
+ `${MEASURED}cx-ndex-90f78bcd: each word is measured with the space after it), Cytoscape 3.10.5`
2216
+ ),
2217
+ labelPosition: v("center", `${CYL} 205`),
2218
+ labelPadding: CYTOSCAPE_LABEL_PADDING,
2219
+ labelLineHeight: CYTOSCAPE_LABEL_LINE_HEIGHT
1682
2220
  },
1683
2221
  edge: {
1684
2222
  color: v("#404040", `${CYL} 469`),
1685
2223
  width: v(1, `${CYL} 368`),
1686
2224
  lineStyle: v("solid", `${CYL} 392`),
2225
+ waveAmplitude: v(10, CY_WAVE),
2226
+ wavePeriod: v(20, CY_WAVE),
1687
2227
  sourceArrow: v("none", `${CYL} 487`),
1688
2228
  targetArrow: v("none", `${CYL} 493`),
1689
2229
  labelColor: v("#000000", `${CYL} 327`),
1690
- labelFont: v("sans-serif", `${CYL} 408`),
2230
+ labelFont: v("DejaVu Sans, sans-serif", `${CYL} 408 (SansSerif, drawn in Java's face for it)`),
1691
2231
  labelWeight: v("normal", `${CYL} 408`),
1692
2232
  labelItalic: v(false, `${CYL} 408`),
1693
- labelSize: v(10, `${CYL} 416`)
2233
+ labelSize: v(10, `${CYL} 416`),
2234
+ labelPadding: CYTOSCAPE_LABEL_PADDING,
2235
+ labelLineHeight: CYTOSCAPE_LABEL_LINE_HEIGHT,
2236
+ bendCurve: CYTOSCAPE_BEND_CURVE
1694
2237
  },
1695
2238
  graph: { background: v("#ffffff", `${CYL} 667`) },
1696
2239
  derived: []
@@ -1699,6 +2242,22 @@ const TOOL_DEFAULTS = new Map(
1699
2242
  tool: "cytoscape-js",
1700
2243
  version: "cytoscape.js 3.34.3",
1701
2244
  units: "px",
2245
+ roundedCornerRadius: cornerCap(),
2246
+ arrowhead: {
2247
+ // getArrowWidth, and the triangle's points at +-0.15, -0.3 of it
2248
+ length: (size, width) => 0.3 * Math.max((width * 13.37) ** 0.9, 29) * size,
2249
+ aspect: 1,
2250
+ // a tee is 0.1 of the arrow width deep, the triangle 0.3 long; triangle-tee reaches back to its bar
2251
+ // at 0.5, circle-triangle to 0.6 and triangle-cross to its cross line at 0.4 plus the line's width
2252
+ shapes: {
2253
+ tee: { length: 1 / 3, aspect: 3 },
2254
+ "other:triangle-tee": { length: 5 / 3, aspect: 0.6 },
2255
+ "other:triangle-cross": { length: 1.5, aspect: 0.66 },
2256
+ "other:circle-triangle": { length: 2, aspect: 0.5 },
2257
+ "other:chevron": { length: 2 / 3, aspect: 1.5 }
2258
+ },
2259
+ source: `${CYJS} 23497 (getArrowWidth), 22714-22716 (triangle), 22813-22814 (tee), 22627 (arrowShapeWidth)`
2260
+ },
1702
2261
  node: {
1703
2262
  fill: v("#999999", `${CYJS} 18536`),
1704
2263
  fillOpacity: v(1, `${CYJS} 18538`),
@@ -1708,17 +2267,42 @@ const TOOL_DEFAULTS = new Map(
1708
2267
  borderColor: v("#000000", `${CYJS} 18555`),
1709
2268
  borderWidth: v(0, `${CYJS} 18557`),
1710
2269
  borderStyle: v("solid", `${CYJS} 18558`),
2270
+ borderPosition: v("center", `${CYJS} 18563`),
2271
+ outerBorderColor: v("#999999", `${CYJS} 18564`),
2272
+ // the underlay and the overlay draw nothing until an opacity is set; then these
2273
+ underlayColor: v("#000000", `${CYJS} 18524`),
2274
+ underlayPadding: v(10, `${CYJS} 18525`),
2275
+ underlayShape: v("round-rectangle", `${CYJS} 18526`),
2276
+ overlayColor: v("#000000", `${CYJS} 18519`),
2277
+ overlayPadding: v(10, `${CYJS} 18520`),
2278
+ overlayShape: v("round-rectangle", `${CYJS} 18521`),
1711
2279
  opacity: v(1, `${CYJS} 18503`),
1712
2280
  labelColor: v("#000000", `${CYJS} 18474`),
1713
2281
  labelSize: v(16, `${CYJS} 18496`),
1714
2282
  labelFont: v("Helvetica Neue, Helvetica, sans-serif", `${CYJS} 18493`),
1715
2283
  labelWeight: v("normal", `${CYJS} 18495`),
1716
- labelPosition: v("top", `${CYJS} 18470-18471`)
2284
+ labelPosition: v("top", `${CYJS} 18470-18471`),
2285
+ // text-wrap: wrap measures `subline + word + wordSeparator` against text-max-width; ponytail: a
2286
+ // line's last word has no separator there, where graphty counts a space after it too
2287
+ labelWrapTrailingSpace: v(true, `${CYJS} 25218`)
1717
2288
  },
1718
2289
  edge: {
1719
2290
  color: v("#999999", `${CYJS} 18639`),
1720
2291
  sourceArrowColor: v("#999999", `${CYJS} 18639`),
1721
2292
  targetArrowColor: v("#999999", `${CYJS} 18639`),
2293
+ outlineColor: v("#000000", `${CYJS} 18644`),
2294
+ underlayColor: v("#000000", `${CYJS} 18524`),
2295
+ underlayPadding: v(10, `${CYJS} 18525`),
2296
+ overlayColor: v("#000000", `${CYJS} 18519`),
2297
+ overlayPadding: v(10, `${CYJS} 18520`),
2298
+ gradientKind: v("none", `${CYJS} 18640 (line-fill solid)`),
2299
+ midSourceArrowColor: v("#999999", `${CYJS} 18639`),
2300
+ midTargetArrowColor: v("#999999", `${CYJS} 18639`),
2301
+ // an edge's label is centered on the line's middle (recalculateEdgeLabelProjections)
2302
+ labelPosition: v("center", `${CYJS} 24942`),
2303
+ // a source or target label is centered on the line where it leaves its node, unless offset
2304
+ sourceLabelOffset: v(0, `${CYJS} 18511, 18515`),
2305
+ targetLabelOffset: v(0, `${CYJS} 18511, 18515`),
1722
2306
  width: v(3, `${CYJS} 18711`),
1723
2307
  lineStyle: v("solid", `${CYJS} 18638`),
1724
2308
  opacity: v(1, `${CYJS} 18503`),
@@ -1726,28 +2310,56 @@ const TOOL_DEFAULTS = new Map(
1726
2310
  targetArrow: v("none", `${CYJS} 18671`),
1727
2311
  arrowSize: v(1, `${CYJS} 18660`),
1728
2312
  curved: v(false, `${CYJS} 18658`),
2313
+ // control-point-step-size 40: a quadratic's middle is half as far out as its control point
2314
+ fanSpacing: v(20, `${CYJS} 18647`),
1729
2315
  labelColor: v("#000000", `${CYJS} 18474`),
1730
2316
  labelSize: v(16, `${CYJS} 18496`),
1731
2317
  labelFont: v("Helvetica Neue, Helvetica, sans-serif", `${CYJS} 18493`),
1732
2318
  labelWeight: v("normal", `${CYJS} 18495`)
1733
2319
  },
1734
- graph: {},
2320
+ graph: {
2321
+ // the canvas is cleared to transparent, so the page's default white shows through
2322
+ background: v("#ffffff", `${CYJS} 31537 (clearCanvas: clearRect)`)
2323
+ },
1735
2324
  derived: []
1736
2325
  },
1737
2326
  {
1738
2327
  tool: "graphviz",
1739
2328
  version: "graphviz main (16.1.0)",
1740
2329
  units: "px",
2330
+ roundedCornerRadius: cornerCap("graphviz"),
2331
+ arrowhead: {
2332
+ // ARROW_LENGTH 10 and the normal arrow's half width 0.35 of its length
2333
+ length: (size) => 10 * size,
2334
+ aspect: 0.7,
2335
+ // each arrow type's length factor and the half width its arrow_type_* function draws
2336
+ shapes: {
2337
+ tee: { length: 0.2, aspect: 5 },
2338
+ square: { length: 0.8, aspect: 1 },
2339
+ diamond: { length: 1.2, aspect: 2 / 3 },
2340
+ "diamond-open": { length: 1.2, aspect: 2 / 3 },
2341
+ circle: { length: 0.8, aspect: 1 },
2342
+ "circle-open": { length: 0.8, aspect: 1 },
2343
+ crow: { length: 1, aspect: 0.9 },
2344
+ vee: { length: 1, aspect: 0.9 },
2345
+ // the arc of curve and icurve, a half circle of radius half the arrow's length across its
2346
+ // stem (the stem is the line, carried on to the tip)
2347
+ "other:curve": { length: 0.5, aspect: 2 },
2348
+ "other:inv-curve": { length: 0.5, aspect: 2 }
2349
+ },
2350
+ source: "graphviz lib/common/arrows.c (ARROW_LENGTH 10, Arrowtypes lenfact, arrow_type_normal 0.35, arrow_type_crow 0.45, arrow_type_tee, arrow_type_box 0.4, arrow_type_diamond 1/3, arrow_type_dot, arrow_type_curve)"
2351
+ },
1741
2352
  node: {
1742
2353
  fillOpacity: v(0, `${GV}/style/ (default "", not filled)`),
1743
2354
  borderColor: v("#000000", `${GV}/color/`),
1744
2355
  borderWidth: v(1, `${GV}/penwidth/; lib/common/const.h line 77`),
2356
+ borderPosition: v("center", `${MEASURED}dot-synth-nodes), Graphviz strokes the node's own outline`),
1745
2357
  shape: v("ellipse", `${GV}/shape/; lib/common/const.h line 76`),
1746
2358
  width: v(54, `${GV}/width/ (0.75 inch); lib/common/const.h line 72`),
1747
2359
  height: v(36, `${GV}/height/ (0.5 inch); lib/common/const.h line 73`),
1748
2360
  labelColor: v("#000000", `${GV}/fontcolor/`),
1749
2361
  labelSize: v(14, `${GV}/fontsize/; lib/common/const.h line 61`),
1750
- labelFont: v("Times-Roman", `${GV}/fontname/; lib/common/const.h line 67`),
2362
+ labelFont: v("Times, serif", `${GV}/fontname/ (Times-Roman); lib/common/const.h line 67`),
1751
2363
  labelPosition: v("center", `${GV}/labelloc/`)
1752
2364
  },
1753
2365
  edge: {
@@ -1759,12 +2371,12 @@ const TOOL_DEFAULTS = new Map(
1759
2371
  arrowSize: v(1, `${GV}/arrowsize/`),
1760
2372
  labelColor: v("#000000", `${GV}/fontcolor/`),
1761
2373
  labelSize: v(14, `${GV}/fontsize/`),
1762
- labelFont: v("Times-Roman", `${GV}/fontname/`)
2374
+ labelFont: v("Times, serif", `${GV}/fontname/ (Times-Roman)`)
1763
2375
  },
1764
2376
  graph: {
1765
2377
  background: v(
1766
2378
  "#ffffff",
1767
- `${GV}/bgcolor/ (default none); lib/common/emit.c emit_background: no bgcolor paints white`
2379
+ `${GV}/bgcolor/ (default unset); lib/common/emit.c emit_background (an unset bgcolor paints the page white)`
1768
2380
  )
1769
2381
  },
1770
2382
  derived: [
@@ -1780,14 +2392,17 @@ const TOOL_DEFAULTS = new Map(
1780
2392
  tool: "yed",
1781
2393
  version: "yEd / yFiles for Java 2.19",
1782
2394
  units: "px",
2395
+ roundedCornerRadius: cornerCap("yed"),
2396
+ arrowhead: DRAWIO_ARROWHEAD,
1783
2397
  node: {
1784
2398
  fill: v("#ffcc00", `${YED_QA}; ${YED_CORPUS} of y:Fill color`),
1785
2399
  shape: v("rectangle", "yFiles for Java 2.19 ShapeNodeRealizer API docs"),
1786
2400
  borderColor: v("#000000", `${YED_CORPUS} of y:BorderStyle`),
1787
2401
  borderWidth: v(1, `${YED_CORPUS} of y:BorderStyle`),
1788
2402
  borderStyle: v("solid", `${YED_CORPUS} of y:BorderStyle`),
2403
+ borderPosition: v("center", `${MEASURED}graphml-*, draw.io 32.4.1 standing in for yEd)`),
1789
2404
  labelColor: v("#000000", `${YED_CORPUS} of y:NodeLabel`),
1790
- labelFont: v("Dialog", `${YED_CORPUS} of y:NodeLabel`),
2405
+ labelFont: v("DejaVu Sans, sans-serif", `${YED_CORPUS} of y:NodeLabel (Dialog's face)`),
1791
2406
  labelSize: v(12, `${YED_CORPUS} of y:NodeLabel`),
1792
2407
  labelWeight: v("normal", `${YED_CORPUS} of y:NodeLabel`),
1793
2408
  labelPosition: v("center", `${YED_CORPUS} of y:NodeLabel`)
@@ -1799,7 +2414,7 @@ const TOOL_DEFAULTS = new Map(
1799
2414
  sourceArrow: v("none", `${YED_EDGE} (defaults to Arrow.NONE)`),
1800
2415
  targetArrow: v("none", `${YED_EDGE} (defaults to Arrow.NONE)`),
1801
2416
  labelColor: v("#000000", `${YED_CORPUS} of y:EdgeLabel`),
1802
- labelFont: v("Dialog", `${YED_CORPUS} of y:EdgeLabel`),
2417
+ labelFont: v("DejaVu Sans, sans-serif", `${YED_CORPUS} of y:EdgeLabel (Dialog's face)`),
1803
2418
  labelSize: v(12, `${YED_CORPUS} of y:EdgeLabel`)
1804
2419
  },
1805
2420
  graph: {
@@ -1814,14 +2429,24 @@ const TOOL_DEFAULTS = new Map(
1814
2429
  tool: "yfiles3",
1815
2430
  version: "yFiles for HTML (API docs retrieved 2026-10-11)",
1816
2431
  units: "px",
2432
+ roundedCornerRadius: cornerCap("yfiles3"),
2433
+ arrowhead: DRAWIO_ARROWHEAD,
1817
2434
  node: {
1818
2435
  fill: v("#ffffff", `${Y3} ShapeNodeStyle fill`),
1819
2436
  borderColor: v("#000000", `${Y3} ShapeNodeStyle stroke`),
1820
2437
  borderWidth: v(1, `${Y3} ShapeNodeStyle stroke`),
2438
+ borderPosition: v(
2439
+ "center",
2440
+ `${MEASURED}graphml-yfiles-html-*, draw.io 32.4.1 standing in for yFiles)`
2441
+ ),
1821
2442
  shape: v("rectangle", `${Y3} ShapeNodeStyle shape`),
1822
2443
  labelColor: v("#000000", `${Y3} LabelStyle textFill`),
1823
2444
  labelFont: v("Arial", `${Y3} LabelStyle font`),
1824
- labelSize: v(12, `${Y3} LabelStyle font`)
2445
+ labelSize: v(12, `${Y3} LabelStyle font`),
2446
+ labelPosition: v(
2447
+ "center",
2448
+ `${Y3} IGraph.nodeDefaults labels layoutParameter (InteriorLabelModel center)`
2449
+ )
1825
2450
  },
1826
2451
  edge: {
1827
2452
  color: v("#000000", `${Y3} PolylineEdgeStyle stroke`),
@@ -1832,67 +2457,58 @@ const TOOL_DEFAULTS = new Map(
1832
2457
  labelFont: v("Arial", `${Y3} LabelStyle font`),
1833
2458
  labelSize: v(12, `${Y3} LabelStyle font`)
1834
2459
  },
1835
- graph: {},
2460
+ graph: {
2461
+ background: v("#ffffff", `${Y3} GraphComponent (a transparent canvas over the page's white)`)
2462
+ },
1836
2463
  derived: []
1837
2464
  },
1838
2465
  {
1839
2466
  tool: "gephi",
1840
2467
  version: "gephi 0.11.4-SNAPSHOT",
1841
2468
  units: "relative",
2469
+ roundedCornerRadius: cornerCap("gephi"),
2470
+ arrowhead: {
2471
+ length: (size, width) => 3.25 * width * size,
2472
+ aspect: 0.9,
2473
+ source: `${MEASURED}gexf-synth-nx-viz, widths 1 to 4), Gephi Toolkit 0.11.3`
2474
+ },
1842
2475
  node: {
1843
2476
  fill: v("#000000", "gephi/graphstore a4c790b2343e NodeImpl.java line 322"),
1844
- width: v(10, `${GEPHI} AbstractProcessor.java lines 195-198`),
1845
- height: v(10, `${GEPHI} AbstractProcessor.java lines 195-198`),
2477
+ width: v(20, `${GEPHI} AbstractProcessor.java lines 195-198 (size 10 is a radius)`),
2478
+ height: v(20, `${GEPHI} AbstractProcessor.java lines 195-198 (size 10 is a radius)`),
1846
2479
  shape: v("ellipse", "GEXF 1.3 viz shape default disc; Preview NodeRenderer"),
1847
- opacity: v(1, `${GEPHI} DefaultPreset.java line 87 (NODE_OPACITY 100)`),
1848
- // Preview hides labels (DefaultPreset.java line 106) and so does the Overview (VizConfig.java
1849
- // line 113); graph-io shows them as sigma.js and gexf-js do (see formats/gexf/styles.ts), in
1850
- // the color and font Gephi gives a label it shows
1851
- labelColor: v("#000000", `${GEPHI} DefaultPreset.java line 91 (DependantOriginalColor(BLACK))`),
1852
- labelFont: v("Arial", `${GEPHI} DefaultPreset.java line 93 (Arial plain 12)`),
1853
- // the size of a size-10 node's label; Preview scales it with the node (labelSizeFromWidth below)
1854
- labelSize: v(12, `${GEPHI} DefaultPreset.java line 93 (Arial plain 12)`),
2480
+ borderPosition: v(
2481
+ "inside",
2482
+ `${MEASURED}gexf-specimen-node-fills-borders-p3), Gephi Toolkit 0.11.3: the border is stroked on a circle of radius size - border / 2`
2483
+ ),
1855
2484
  labelPosition: v(
1856
2485
  "center",
1857
2486
  `${GEPHI} NodeLabelRenderer.java (a label is drawn centered on its node)`
2487
+ ),
2488
+ // a node drawn under another still shows its label (gexf-cns-wos n5 under n109: "Borner, K")
2489
+ labelOnTop: v(
2490
+ true,
2491
+ `${GEPHI} PreviewController (the node label items are drawn after every node); Gephi Toolkit 0.11.3 SVG export: g#node-labels after g#nodes`
1858
2492
  )
1859
2493
  },
1860
2494
  edge: {
1861
- curved: v(
1862
- true,
1863
- `${GEPHI} DefaultPreset.java line 66 (EDGE_CURVED true); EdgeRenderer.java line 117`
1864
- ),
1865
2495
  sourceArrow: v("none", `${GEPHI} DefaultPreset.java line 62`),
1866
2496
  targetArrow: v("none", `${GEPHI} DefaultPreset.java line 62`),
1867
- // the vocabulary's 1 is the tool's normal arrow: Preview's ARROW_SIZE 3, drawn 3 times the edge's
1868
- // weight long, as Cytoscape.js's arrow-scale 1 scales with the edge's width
1869
- arrowSize: v(
1870
- 1,
1871
- `${GEPHI} DefaultPreset.java line 62 (ARROW_SIZE 3); EdgeRenderer.java lines 255-256 (times the weight)`
2497
+ curved: v(true, `${GEPHI} DefaultPreset.java (EDGE_CURVED true); Gephi Toolkit 0.11.3 SVG export`),
2498
+ fanned: v(
2499
+ false,
2500
+ `${GEPHI} EdgeRenderer.java (each curved edge bows left of its own direction, siblings ignored); Gephi Toolkit 0.11.3 SVG export`
1872
2501
  ),
1873
- opacity: v(1, `${GEPHI} DefaultPreset.java line 71 (EDGE_OPACITY 100)`)
2502
+ arcRadius: v(
2503
+ 1 / 1.2,
2504
+ `${GEPHI} EdgeRenderer.java (CurvedEdgeRenderer: an arc through both node centers of radius length / ARC_CURVENESS, default 1.2)`
2505
+ )
1874
2506
  },
1875
2507
  graph: { background: v("#ffffff", `${GEPHI} VizConfig.java line 111`) },
1876
2508
  derived: [
1877
- {
1878
- kind: "labelFromColumn",
1879
- column: "label",
1880
- source: `${SIGMA}/settings.ts lines 119-126 (renderLabels); ${GEXFJS} lines 1019-1040`
1881
- },
1882
2509
  {
1883
2510
  kind: "colorFromEndNodes",
1884
- source: `${GEPHI} DefaultPreset.java line 65 (EdgeColor.Mode.MIXED); PreviewAPI types/EdgeColor.java lines 89-93`
1885
- },
1886
- {
1887
- kind: "borderFromFill",
1888
- darken: 0.498,
1889
- widthFactor: 0.08,
1890
- source: `${GEPHI} DefaultPreset.java lines 84, 86 (DependantColor DARKER, NODE_BORDER_FIXED false); PreviewAPI types/DependantColor.java lines 55, 85-86; Utils ColorUtils.java lines 22-34; PreviewPlugin renderers/SizeUtils.java lines 11, 33-38 (0.16 x size / 2 of a node drawn size x 2 wide, builders/NodeBuilder.java line 65)`
1891
- },
1892
- {
1893
- kind: "labelSizeFromWidth",
1894
- factor: 1.2,
1895
- source: `${GEPHI} DefaultPreset.java lines 93, 98 (Arial 12, NODE_LABEL_PROPORTIONAL_SIZE true); PreviewPlugin renderers/NodeLabelRenderer.java lines 165-173 (12 x the node drawn size x 2 wide x 0.05, builders/NodeBuilder.java line 65)`
2511
+ source: `${GEPHI} DefaultPreset.java (EDGE_COLOR EdgeColor.Mode.MIXED); Gephi Toolkit 0.11.3 SVG export`
1896
2512
  },
1897
2513
  {
1898
2514
  kind: "widthFromWeight",
@@ -1909,26 +2525,62 @@ const TOOL_DEFAULTS = new Map(
1909
2525
  tool: "vis-network",
1910
2526
  version: "vis-network 10.1.2",
1911
2527
  units: "px",
2528
+ roundedCornerRadius: cornerCap("vis-network"),
2529
+ arrowhead: {
2530
+ // EdgeBase.getArrowData: 15 * scaleFactor + 3 * width; ArrowHead's points at -1, +-0.3
2531
+ length: (size, width) => 15 * size + 3 * width,
2532
+ aspect: 0.6,
2533
+ // its bar is 0.15 of the arrow's length deep and as wide as the arrow is long; its box is 0.6 of the
2534
+ // length square, its circle 0.8 of the length across, and its curve and inv_curve arcs have a
2535
+ // radius of 0.4 of it
2536
+ shapes: {
2537
+ tee: { length: 0.15, aspect: 1 / 0.15 },
2538
+ square: { length: 0.6, aspect: 1 },
2539
+ circle: { length: 0.8, aspect: 1 },
2540
+ "other:curve": { length: 0.4, aspect: 2 },
2541
+ "other:inv-curve": { length: 0.4, aspect: 2 }
2542
+ },
2543
+ source: `${VIS} EdgeBase.getArrowData, ArrowHead, Bar, Box, Circle, Curve, InvertedCurve (measured on json-vis-unix, json-vis-world, json-vis-synth)`
2544
+ },
2545
+ nodeBorderOnScreen: v(
2546
+ true,
2547
+ `${VIS9} NodeBase.initContextForDraw and performStroke: borderWidth / view.scale, at most the node's width`
2548
+ ),
1912
2549
  node: {
1913
2550
  fill: v("#97c2fc", `${VIS} lines 32986-33110`),
1914
2551
  borderColor: v("#2b7ce9", `${VIS} lines 32986-33110`),
1915
2552
  borderWidth: v(1, `${VIS} lines 32986-33110`),
2553
+ // a canvas stroke along the node's own outline, half in and half out (NodeBase.performStroke)
2554
+ borderPosition: v("center", `${VIS9} NodeBase.performStroke: ctx.stroke() on the shape's own path`),
1916
2555
  shape: v("ellipse", `${VIS} lines 32986-33110`),
1917
2556
  labelColor: v("#343434", `${VIS} lines 32986-33110`),
1918
2557
  labelSize: v(14, `${VIS} lines 32986-33110`),
1919
2558
  labelFont: v("arial", `${VIS} lines 32986-33110`),
1920
- labelPosition: v("center", `${VIS} lines 32986-33110`)
2559
+ labelPosition: v("center", `${VIS} lines 32986-33110`),
2560
+ // Label.draw returns before drawing when the font is under drawThreshold - 1 px on screen
2561
+ labelMinScreenSize: v(4, `${VIS9} Label.draw, nodes scaling.label.drawThreshold 5`)
1921
2562
  },
1922
2563
  edge: {
1923
2564
  width: v(1, `${VIS} lines 25160-25290`),
2565
+ outlineColor: v("#6f6f6f", `${VIS} lines 25160-25290 (background.color)`),
1924
2566
  lineStyle: v("solid", `${VIS} lines 25160-25290 (dashes false)`),
1925
2567
  sourceArrow: v("none", `${VIS} lines 25160-25290`),
1926
2568
  targetArrow: v("none", `${VIS} lines 25160-25290`),
1927
2569
  labelColor: v("#343434", `${VIS} lines 25160-25290`),
1928
2570
  labelSize: v(14, `${VIS} lines 25160-25290`),
1929
- labelFont: v("arial", `${VIS} lines 25160-25290`)
2571
+ labelFont: v("arial", `${VIS} lines 25160-25290`),
2572
+ labelMinScreenSize: v(4, `${VIS9} Label.draw, edges scaling.label.drawThreshold 5`),
2573
+ // an edge label is drawn on the line, its letters stroked white 2 px wide (font.strokeWidth 2)
2574
+ labelPosition: v("center", `${VIS9} Edge.drawLabel (the label at the line's middle point)`),
2575
+ labelOutlineColor: v("#ffffff", `${VIS} lines 25160-25290 (font.strokeColor)`),
2576
+ labelOutlineWidth: v(2, `${VIS} lines 25160-25290 (font.strokeWidth)`)
2577
+ },
2578
+ graph: {
2579
+ background: v(
2580
+ "#ffffff",
2581
+ "vis-network 9.1.9 vis-network.esm.js line 32378 (clearRect: the page's white shows through)"
2582
+ )
1930
2583
  },
1931
- graph: {},
1932
2584
  derived: [
1933
2585
  { kind: "labelFromColumn", column: "label", source: `${VIS} lines 32986-33110` },
1934
2586
  { kind: "colorFromSourceNode", source: `${VIS} lines 25160-25290 (color.inherit "from")` }
@@ -1936,50 +2588,107 @@ const TOOL_DEFAULTS = new Map(
1936
2588
  },
1937
2589
  {
1938
2590
  tool: "sigma",
1939
- version: "sigma 3.0.3",
2591
+ version: "sigma 4.0.1",
1940
2592
  units: "relative",
2593
+ roundedCornerRadius: cornerCap("sigma"),
1941
2594
  node: {
1942
- fill: v("#999999", `${SIGMA}/settings.ts lines 119-126`),
2595
+ fill: v("#666666", `${SIGMA4} DEFAULT_NODE_DISPLAY_DATA (color "#666")`),
1943
2596
  shape: v("ellipse", `${SIGMA}/settings.ts lines 119-126`),
1944
- width: v(2, `${SIGMA}/sigma.ts line 76`),
1945
- height: v(2, `${SIGMA}/sigma.ts line 76`),
2597
+ width: v(20, `${SIGMA4} DEFAULT_NODE_DISPLAY_DATA (size 10 is a radius)`),
2598
+ height: v(20, `${SIGMA4} DEFAULT_NODE_DISPLAY_DATA (size 10 is a radius)`),
1946
2599
  labelColor: v("#000000", `${SIGMA}/settings.ts lines 119-126`),
1947
2600
  labelFont: v("Arial", `${SIGMA}/settings.ts lines 119-126`),
1948
- labelSize: v(14, `${SIGMA}/settings.ts lines 119-126`),
1949
- labelWeight: v("normal", `${SIGMA}/settings.ts lines 119-126`)
2601
+ // sigma 4 sets every node's labelSize to 12 before its styles run; the 14 in sigma.esm.js
2602
+ // (`defaultLabelSize`) is only reached by a node whose styles cleared it.
2603
+ labelSize: v(12, `${SIGMA4} DEFAULT_NODE_DISPLAY_DATA (labelSize 12)`),
2604
+ labelWeight: v("normal", `${SIGMA}/settings.ts lines 119-126`),
2605
+ labelPosition: v("right", `${SIGMA4} DEFAULT_NODE_DISPLAY_DATA (labelPosition "right")`),
2606
+ // sigma keeps the largest node's label per 100 px cell of its first framing; it avoids no overlap
2607
+ labelGridCellSize: v(
2608
+ 100,
2609
+ `${SIGMA4} LabelGrid.getLabelsToDisplay (labelDensity 1, labelGridCellSize 100)`
2610
+ ),
2611
+ labelOnTop: v(true, `${SIGMA4} labels are drawn by their own program after every node and edge`),
2612
+ // a node's label is drawn only while its node's rendered size (a radius) is 6 px or more
2613
+ labelMinNodeScreenSize: v(12, `${SIGMA4} renderLabels (labelRenderedSizeThreshold 6, a radius)`)
1950
2614
  },
1951
2615
  edge: {
1952
2616
  color: v("#cccccc", `${SIGMA}/settings.ts lines 119-126`),
1953
- width: v(0.5, `${SIGMA}/sigma.ts line 100`),
2617
+ // an edge of sigma's default size 1, drawn half as wide as its size (readSigmaRow)
2618
+ width: v(0.5, `${SIGMA4} DEFAULT_EDGE_DISPLAY_DATA (size 1)`),
2619
+ // an edge label (renderEdgeLabels) is drawn at its line's middle, 12 px, in #666
2620
+ labelColor: v("#666666", `${SIGMA4} DEFAULT_EDGE_DISPLAY_DATA (labelColor "#666")`),
2621
+ labelSize: v(12, "sigma 4.0.1 dist/sigma.esm.js line 2816 (DEFAULT_EDGE_LABEL_SIZE)"),
2622
+ labelPosition: v("center", "sigma 4.0.1 dist/sigma.esm.js line 3647 (the middle of its two ends)"),
1954
2623
  sourceArrow: v("none", `${SIGMA}/settings.ts lines 119-126 (type line)`),
1955
- targetArrow: v("none", `${SIGMA}/settings.ts lines 119-126 (type line)`)
2624
+ targetArrow: v("none", `${SIGMA}/settings.ts lines 119-126 (type line)`),
2625
+ // no edge is drawn thinner on screen, whatever its size (the shader's max(size, minEdgeThickness 1.7),
2626
+ // drawn half as wide as a node of that size is in radius, as readSigmaRow halves a size)
2627
+ minScreenWidth: v(
2628
+ 0.85,
2629
+ `${SIGMA4} edge program (pixelsThickness = max(size, minEdgeThickness 1.7))`
2630
+ )
2631
+ },
2632
+ graph: {
2633
+ background: v(
2634
+ "#ffffff",
2635
+ "sigma 4.0.1 dist/sigma.esm.js line 5202 (gl.clear to transparent: the page's white shows through)"
2636
+ )
1956
2637
  },
1957
- graph: {},
1958
2638
  derived: [{ kind: "labelFromColumn", column: "label", source: `${SIGMA}/settings.ts lines 119-126` }]
1959
2639
  },
1960
2640
  {
1961
2641
  tool: "pajek",
1962
2642
  version: "Pajek 6.02",
1963
- units: "relative",
2643
+ // PostScript points, the unit of Pajek's EPS and SVG export (formats/pajek/styles.ts)
2644
+ units: "px",
2645
+ roundedCornerRadius: cornerCap("pajek"),
2646
+ // a line's `s` (arrowSize) scales Pajek's arrowhead whatever its width: 6 x s long (tip to its back
2647
+ // corners) and 5 x s wide
2648
+ arrowhead: {
2649
+ length: (size) => 6 * size,
2650
+ aspect: 5 / 6,
2651
+ source: `${PAJEK_SVG}specimen-arrows: s 0.5, 1, 2, 3 and 5 draw arrowheads 3, 6, 12, 18 and 30 long, 2.5, 5, 10, 15 and 25 wide; football: s 4 and 9)`
2652
+ },
1964
2653
  node: {
1965
2654
  shape: v("ellipse", `${PAJEK} p. 85`),
1966
2655
  opacity: v(1, `${PAJEK} p. 87`),
1967
- borderColor: v("#000000", `${PAJEK}, vertex parameter bc (default Black)`),
1968
- borderWidth: v(0.2, `${PAJEK}, vertex parameter bw (default 1, against the default vertex size 5)`),
1969
- labelColor: v("#000000", `${PAJEK_SHAPES} (lc Black)`),
1970
- labelPosition: v("center", `${PAJEK_SHAPES} (lr 0); ${PAJEK} p. 85 (radius 0 is centered)`)
2656
+ // Pajek 6.02's own defaults, as its SVG export draws a vertex and label the file gives no
2657
+ // parameters for (the manual names these settings but not their values)
2658
+ borderColor: v("#660000", `${PAJEK_SVG}football, kdorola: every vertex without bc)`),
2659
+ borderWidth: v(0.5, `${PAJEK_SVG}football, kdorola: every vertex without bw)`),
2660
+ // an SVG stroke along the vertex's own outline, half in and half out
2661
+ borderPosition: v(
2662
+ "center",
2663
+ `${PAJEK_SVG}specimen-node-fills-borders-p3: bw 8 draws a vertex of size 36 44 across)`
2664
+ ),
2665
+ width: v(20, `${PAJEK_SVG}football, iliad: a vertex without s_size, x_fact or y_fact)`),
2666
+ height: v(20, `${PAJEK_SVG}football, iliad: a vertex without s_size, x_fact or y_fact)`),
2667
+ fill: v("#ffd9bc", `${PAJEK_SVG}football, kdorola: every vertex without ic)`),
2668
+ labelColor: v("#ad0000", `${PAJEK_SVG}football, 1crn: every label without lc)`),
2669
+ labelSize: v(15, `${PAJEK_SVG}football, 1crn: every label without fos)`),
2670
+ labelFont: v("Arial", `${PAJEK_SVG}football, 1crn: every label without font)`),
2671
+ labelWeight: v("bold", `${PAJEK_SVG}football, 1crn: every label is bold)`),
2672
+ // the text starts 20 from the center at lphi 285 and runs to the right, its baseline through
2673
+ // that point: its left edge's middle at 20 cos 285 across and 20 sin 285 less 0.3465 of its
2674
+ // size down (formats/pajek/styles.ts readLabelPosition)
2675
+ labelPosition: v("center", `${PAJEK_SVG}football, 1crn, specimen-labels: lr 20 lphi 285)`),
2676
+ labelOffsetX: v(5.176380902, `${PAJEK_SVG}football, 1crn, specimen-labels: lr 20 lphi 285)`),
2677
+ labelOffsetY: v(14.121016526, `${PAJEK_SVG}football, 1crn, specimen-labels: lr 20 lphi 285)`),
2678
+ labelShiftX: v(0.5, `${PAJEK_SVG}football, 1crn, specimen-labels: text-anchor start)`)
1971
2679
  },
1972
2680
  edge: {
1973
- color: v("#000000", `${PAJEK} p. 90`),
1974
- // No line width: Pajek's w is read as the file has it, not as a factor of the vertex size as bw is,
1975
- // so a default of 1 here, with no vertex size in the file, became the length every other length
1976
- // of the drawing was scaled by, and a border 0.2 wide was drawn far too thin to see.
2681
+ // an edge (undirected) is drawn twice the width of an arc; the arc rule below sets an arc's
2682
+ width: v(2, `${PAJEK_SVG}1crn, lin-rel4, synth-vertices: edges without w; c: w 0.5 drawn 1)`),
2683
+ color: v("#007091", `${PAJEK_SVG}1crn, lin-rel4, c: edges without c)`),
1977
2684
  lineStyle: v("solid", `${PAJEK} p. 90`),
1978
2685
  opacity: v(1, `${PAJEK} p. 87`),
1979
2686
  sourceArrow: v("none", `${PAJEK} p. 91`),
1980
2687
  targetArrow: v("none", `${PAJEK} p. 91 (edges have none)`)
1981
2688
  },
1982
- graph: {},
2689
+ graph: {
2690
+ background: v("#ffffff", `${PAJEK}, Draw window (assumed: a white background)`)
2691
+ },
1983
2692
  derived: [
1984
2693
  { kind: "labelFromColumn", column: "label", source: `${PAJEK}, vertex labels (drawn by default)` },
1985
2694
  { kind: "targetArrowOnDirected", arrow: "triangle", source: `${PAJEK} p. 91 (arcs)` }
@@ -1989,6 +2698,13 @@ const TOOL_DEFAULTS = new Map(
1989
2698
  tool: "ogdf",
1990
2699
  version: "ogdf master 1a40505ac006",
1991
2700
  units: "px",
2701
+ roundedCornerRadius: cornerCap("ogdf"),
2702
+ // OGDF's arrowhead is three times its line's width long and half as wide as it is long
2703
+ arrowhead: {
2704
+ length: (size, width) => 3 * width * size,
2705
+ aspect: 0.5,
2706
+ source: `${MEASURED}gml-specimen-arrows-p5.svg: lineWidth 1, 1.5 and 3 draw arrowheads 3, 4.5 and 9 long, 1.5, 2.25 and 4.5 wide)`
2707
+ },
1992
2708
  node: {
1993
2709
  fill: v("#ffffff", `${OGDF} LayoutStandards.cpp lines 38-45`),
1994
2710
  shape: v("rectangle", `${OGDF} LayoutStandards.cpp lines 38-45`),
@@ -1996,20 +2712,30 @@ const TOOL_DEFAULTS = new Map(
1996
2712
  height: v(20, `${OGDF} LayoutStandards.cpp lines 38-45`),
1997
2713
  borderColor: v("#000000", `${OGDF} LayoutStandards.cpp lines 38-45`),
1998
2714
  borderWidth: v(1, `${OGDF} LayoutStandards.cpp lines 38-45`),
1999
- borderStyle: v("solid", `${OGDF} LayoutStandards.cpp lines 38-45`)
2715
+ borderStyle: v("solid", `${OGDF} LayoutStandards.cpp lines 38-45`),
2716
+ // GraphIO::drawSVG's default SVGSettings: every label in one font, centered on its node
2717
+ labelColor: v("#000000", `${OGDF_SVG}fill #000000)`),
2718
+ labelFont: v("Arial", `${OGDF_SVG}font-family Arial)`),
2719
+ labelSize: v(10, `${OGDF_SVG}font-size 10)`),
2720
+ labelPosition: v("center", `${OGDF_SVG}text-anchor middle at the node's center)`)
2000
2721
  },
2001
2722
  edge: {
2002
2723
  color: v("#000000", `${OGDF} LayoutStandards.cpp lines 38-45`),
2003
2724
  width: v(1, `${OGDF} LayoutStandards.cpp lines 38-45`),
2004
- lineStyle: v("solid", `${OGDF} LayoutStandards.cpp lines 38-45`)
2725
+ lineStyle: v("solid", `${OGDF} LayoutStandards.cpp lines 38-45`),
2726
+ labelColor: v("#000000", `${OGDF_SVG}fill #000000)`),
2727
+ labelFont: v("Arial", `${OGDF_SVG}font-family Arial)`),
2728
+ labelSize: v(10, `${OGDF_SVG}font-size 10)`),
2729
+ labelPosition: v("center", `${OGDF_SVG}text-anchor middle on the line, dominant-baseline middle)`)
2005
2730
  },
2006
- graph: {},
2731
+ graph: { background: v("#ffffff", `${OGDF_SVG}no background: the page's white shows through)`) },
2007
2732
  derived: []
2008
2733
  },
2009
2734
  {
2010
2735
  tool: "networkx",
2011
2736
  version: "networkx 3.7 (main 6da4704cbf32)",
2012
2737
  units: "px",
2738
+ roundedCornerRadius: cornerCap("networkx"),
2013
2739
  node: {
2014
2740
  fill: v("#1f78b4", `${NX} 1378`),
2015
2741
  fillOpacity: v(1, `${NX} 549`),
@@ -2053,6 +2779,18 @@ const SCALAR_DTYPES = /* @__PURE__ */ new Set(["string", "dict", "bool", "i32",
2053
2779
  const COORDINATE = /^(?:x|y|z|_pos)$/i;
2054
2780
  const PARENT_COLUMN = "graphty.parent";
2055
2781
  const MIN_INDEX = 8;
2782
+ function hasFoldedPairs(snapshot) {
2783
+ const folding = pairFolding(snapshot);
2784
+ if (!folding.expanded) {
2785
+ return false;
2786
+ }
2787
+ for (let e = 0; e < snapshot.edgeCount; e++) {
2788
+ if (folding.folded(e)) {
2789
+ return true;
2790
+ }
2791
+ }
2792
+ return false;
2793
+ }
2056
2794
  function featuresOf(snapshot, target) {
2057
2795
  const table2 = target === "node" ? snapshot.nodes : snapshot.edges;
2058
2796
  const n = target === "node" ? snapshot.nodeCount : snapshot.edgeCount;
@@ -2071,7 +2809,7 @@ function featuresOf(snapshot, target) {
2071
2809
  out.push({ ref: { style: "group" }, values: group });
2072
2810
  }
2073
2811
  }
2074
- if (target === "node" && n > 0) {
2812
+ if (target === "node" && n > 0 && !hasFoldedPairs(snapshot)) {
2075
2813
  const kinds = snapshot.directed ? ["degree", "indegree", "outdegree"] : ["degree"];
2076
2814
  for (const k of kinds) {
2077
2815
  out.push({ ref: { computed: k }, values: degreeValues(snapshot, k) });
@@ -2801,54 +3539,58 @@ function blockStyles(block, snapshot, format, truth = {}, notes = [], tool = nul
2801
3539
  };
2802
3540
  }
2803
3541
  export {
2804
- MAX_STYLE_BLOCK_LENGTH as A,
2805
- STYLE_ENUMS as B,
2806
- STYLE_PROPERTIES as C,
2807
- DVIPS_COLORS as D,
2808
- htmlLabelText as E,
2809
- dotLabelText as F,
2810
- recordLabelText as G,
3542
+ writeStyleBlock as A,
3543
+ styleBlockLosses as B,
3544
+ canonicalFor as C,
3545
+ degreeValues as D,
3546
+ dataCell as E,
3547
+ htmlLabelText as F,
3548
+ dotLabelText as G,
2811
3549
  DOT_POINTS_PER_INCH as H,
2812
- interpolate as I,
2813
- within as J,
2814
- describeFeature as K,
2815
- refSource as L,
3550
+ recordLabelText as I,
3551
+ dotLabelAlign as J,
3552
+ htmlLabelSpans as K,
3553
+ DVIPS_COLORS as L,
2816
3554
  MAX_STYLE_VALUE_LENGTH as M,
2817
- isShortPredicate as N,
2818
- resolveRules as O,
2819
- matches as P,
2820
- evalContinuous as Q,
2821
- numberOf as R,
3555
+ interpolate as N,
3556
+ within as O,
3557
+ describeFeature as P,
3558
+ refSource as Q,
3559
+ isShortPredicate as R,
2822
3560
  STYLE_BLOCK_NAME as S,
2823
3561
  TOOL_DEFAULTS as T,
2824
- styleLengthUnit as U,
2825
- discreteLookup as V,
2826
- CSS_COLORS as W,
2827
- STYLE_ISSUE as a,
2828
- styleTag as b,
2829
- styleBlockLosses as c,
2830
- canonicalFor as d,
2831
- degreeValues as e,
2832
- dataCell as f,
2833
- canonColor as g,
2834
- canonNumber as h,
3562
+ resolveRules as U,
3563
+ matches as V,
3564
+ evalContinuous as W,
3565
+ numberOf as X,
3566
+ styleLengthUnit as Y,
3567
+ discreteLookup as Z,
3568
+ CSS_COLORS as _,
3569
+ canonEnum as a,
3570
+ STYLE_ISSUE as b,
3571
+ canonNumber as c,
3572
+ canonColor as d,
3573
+ colorOpacity as e,
3574
+ canonText as f,
3575
+ canonSigned as g,
3576
+ StyleNotes as h,
2835
3577
  num6$1 as i,
2836
3578
  canonOpacity as j,
2837
- scalarText as k,
2838
- canonEnum as l,
2839
- canonBoolean as m,
3579
+ canonBoolean as k,
3580
+ isStyleValue as l,
3581
+ parseStyleBlock as m,
2840
3582
  noteAt as n,
2841
- canonText as o,
3583
+ styleFingerprint as o,
2842
3584
  plainCell as p,
2843
- isStyleValue as q,
3585
+ blockStyles as q,
2844
3586
  resolveStyles as r,
2845
- styleFingerprint as s,
2846
- toolDefaults as t,
2847
- StyleNotes as u,
2848
- parseStyleBlock as v,
2849
- writeStyleBlock as w,
2850
- blockStyles as x,
2851
- colorOpacity as y,
2852
- featuresOf as z
3587
+ scalarText as s,
3588
+ featuresOf as t,
3589
+ MAX_STYLE_BLOCK_LENGTH as u,
3590
+ STYLE_ENUMS as v,
3591
+ STYLE_PROPERTIES as w,
3592
+ matchPredicate as x,
3593
+ toolDefaults as y,
3594
+ styleTag as z
2853
3595
  };
2854
- //# sourceMappingURL=block-Cu22ewuS.js.map
3596
+ //# sourceMappingURL=block-iptrlMBb.js.map