mol_plot_all 1.2.776 → 1.2.778

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/web.mjs CHANGED
@@ -2447,7 +2447,7 @@ var $;
2447
2447
  "use strict";
2448
2448
  var $;
2449
2449
  (function ($) {
2450
- $mol_style_attach("mol/view/view/view.css", "[mol_view] {\n\ttransition-property: height, width, min-height, min-width, max-width, max-height, transform;\n\ttransition-duration: .2s;\n\ttransition-timing-function: ease-out;\n\t-webkit-appearance: none;\n\tbox-sizing: border-box;\n\tdisplay: flex;\n\tflex-shrink: 0;\n\tcontain: style;\n\tscrollbar-color: var(--mol_theme_line) transparent;\n\tscrollbar-width: thin;\n}\t\n\n[mol_view]::selection {\n\tbackground: var(--mol_theme_line);\n}\t\n\n[mol_view]::-webkit-scrollbar {\n\twidth: .25rem;\n\theight: .25rem;\n}\n\n[mol_view]::-webkit-scrollbar-corner {\n\tbackground-color: var(--mol_theme_line);\n}\n\n[mol_view]::-webkit-scrollbar-track {\n\tbackground-color: transparent;\n}\n\n[mol_view]::-webkit-scrollbar-thumb {\n\tbackground-color: var(--mol_theme_line);\n\tborder-radius: var(--mol_gap_round);\n}\n\n[mol_view] > * {\n\tword-break: inherit;\n}\n\n[mol_view_root] {\n\tmargin: 0;\n\tpadding: 0;\n\twidth: 100%;\n\theight: 100%;\n\tbox-sizing: border-box;\n\tfont-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;\n\tfont-size: 1rem;\n\tline-height: 1.5rem;\n\tbackground: var(--mol_theme_back);\n\tcolor: var(--mol_theme_text);\n\tcontain: unset; /** Fixes bg ignoring when applied to body on Chrome */\n\ttab-size: 4;\n}\n\n@media print {\n\t[mol_view_root] {\n\t\theight: auto;\n\t}\n}\n\n[mol_view][mol_view_error]:not([mol_view_error=\"Promise\"]) {\n\tbackground-image: repeating-linear-gradient(\n\t\t-45deg,\n\t\t#f92323,\n\t\t#f92323 .5rem,\n\t\t#ff3d3d .5rem,\n\t\t#ff3d3d 1.5rem\n\t);\n\tcolor: black;\n\talign-items: center;\n\tjustify-content: center;\n}\n\n@keyframes mol_view_wait {\n\tfrom {\n\t\topacity: .25;\n\t}\n\t20% {\n\t\topacity: .75;\n\t}\n\tto {\n\t\topacity: .25;\n\t}\n}\n\n:where([mol_view][mol_view_error=\"Promise\"]) {\n\tbackground: var(--mol_theme_hover);\n}\n\n[mol_view][mol_view_error=\"Promise\"] {\n\tanimation: mol_view_wait 1s steps( 20, end ) infinite;\n}\n");
2450
+ $mol_style_attach("mol/view/view/view.css", "[mol_view] {\n\ttransition-property: height, width, min-height, min-width, max-width, max-height, transform;\n\ttransition-duration: .2s;\n\ttransition-timing-function: ease-out;\n\t-webkit-appearance: none;\n\tbox-sizing: border-box;\n\tdisplay: flex;\n\tflex-shrink: 0;\n\tcontain: style;\n\tscrollbar-color: var(--mol_theme_line) transparent;\n\tscrollbar-width: thin;\n}\t\n\n[mol_view]::selection {\n\tbackground: var(--mol_theme_line);\n}\t\n\n[mol_view]::-webkit-scrollbar {\n\twidth: .25rem;\n\theight: .25rem;\n}\n\n[mol_view]::-webkit-scrollbar-corner {\n\tbackground-color: var(--mol_theme_line);\n}\n\n[mol_view]::-webkit-scrollbar-track {\n\tbackground-color: transparent;\n}\n\n[mol_view]::-webkit-scrollbar-thumb {\n\tbackground-color: var(--mol_theme_line);\n\tborder-radius: var(--mol_gap_round);\n}\n\n[mol_view] > * {\n\tword-break: inherit;\n}\n\n[mol_view_root] {\n\tmargin: 0;\n\tpadding: 0;\n\twidth: 100%;\n\theight: 100%;\n\tbox-sizing: border-box;\n\tfont-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;\n\tfont-size: 1rem;\n\tline-height: 1.5rem;\n\tbackground: var(--mol_theme_back);\n\tcolor: var(--mol_theme_text);\n\tcontain: unset; /** Fixes bg ignoring when applied to body on Chrome */\n\ttab-size: 4;\n\toverscroll-behavior: contain; /** Disable navigation gestures **/\n}\n\n@media print {\n\t[mol_view_root] {\n\t\theight: auto;\n\t}\n}\n\n[mol_view][mol_view_error]:not([mol_view_error=\"Promise\"]) {\n\tbackground-image: repeating-linear-gradient(\n\t\t-45deg,\n\t\t#f92323,\n\t\t#f92323 .5rem,\n\t\t#ff3d3d .5rem,\n\t\t#ff3d3d 1.5rem\n\t);\n\tcolor: black;\n\talign-items: center;\n\tjustify-content: center;\n}\n\n@keyframes mol_view_wait {\n\tfrom {\n\t\topacity: .25;\n\t}\n\t20% {\n\t\topacity: .75;\n\t}\n\tto {\n\t\topacity: .25;\n\t}\n}\n\n:where([mol_view][mol_view_error=\"Promise\"]) {\n\tbackground: var(--mol_theme_hover);\n}\n\n[mol_view][mol_view_error=\"Promise\"] {\n\tanimation: mol_view_wait 1s steps( 20, end ) infinite;\n}\n");
2451
2451
  })($ || ($ = {}));
2452
2452
  //mol/view/view/-css/view.css.ts
2453
2453
  ;
@@ -4792,7 +4792,8 @@ var $;
4792
4792
  ...super.attr(),
4793
4793
  x: this.pos_x(),
4794
4794
  y: this.pos_y(),
4795
- "text-anchor": this.align()
4795
+ "text-anchor": this.align_hor(),
4796
+ "alignment-baseline": this.align_vert()
4796
4797
  };
4797
4798
  }
4798
4799
  sub() {
@@ -4809,6 +4810,12 @@ var $;
4809
4810
  align() {
4810
4811
  return "middle";
4811
4812
  }
4813
+ align_hor() {
4814
+ return this.align();
4815
+ }
4816
+ align_vert() {
4817
+ return "baseline";
4818
+ }
4812
4819
  text() {
4813
4820
  return "";
4814
4821
  }
@@ -5440,7 +5447,7 @@ var $;
5440
5447
  "use strict";
5441
5448
  var $;
5442
5449
  (function ($) {
5443
- $mol_style_attach("mol/svg/text/box/box.view.css", "[mol_svg_text_box_back] {\n\tstroke: none;\n\tfill: var(--mol_theme_back);\n}\n");
5450
+ $mol_style_attach("mol/svg/text/box/box.view.css", "[mol_svg_text_box_back] {\n\tstroke: none;\n\tfill: var(--mol_theme_back);\n\ttransition: none;\n}\n");
5444
5451
  })($ || ($ = {}));
5445
5452
  //mol/svg/text/box/-css/box.view.css.ts
5446
5453
  ;
@@ -5454,6 +5461,9 @@ var $;
5454
5461
  title_x_gap() {
5455
5462
  return 4;
5456
5463
  }
5464
+ title_y_gap() {
5465
+ return 22;
5466
+ }
5457
5467
  threshold() {
5458
5468
  return 16;
5459
5469
  }
@@ -5620,6 +5630,13 @@ var $;
5620
5630
  return '0';
5621
5631
  return nearest.scaled.y.toFixed(3);
5622
5632
  }
5633
+ title_y_pos_x() {
5634
+ const nearest = this.nearest();
5635
+ if (!nearest)
5636
+ return '0';
5637
+ const pos = this.title_y_gap();
5638
+ return pos.toFixed(3);
5639
+ }
5623
5640
  }
5624
5641
  __decorate([
5625
5642
  $mol_mem
@@ -5632,7 +5649,7 @@ var $;
5632
5649
  "use strict";
5633
5650
  var $;
5634
5651
  (function ($) {
5635
- $mol_style_attach("mol/plot/mark/cross/cross.view.css", "[mol_plot_mark_cross_curve] {\n\tcolor: var(--mol_theme_focus);\n\tstroke-width: 1px;\n\tstroke: currentColor;\n\tpointer-events: none;\n}\n\n[mol_plot_mark_cross_label_x], [mol_plot_mark_cross_label_y] {\n\tcolor: var(--mol_theme_focus);\n\tfont-weight: bold;\n\tpointer-events: none;\n}\n\n[mol_plot_mark_cross_label_y] {\n\ttransform: translateY( 4px );\n}\n");
5652
+ $mol_style_attach("mol/plot/mark/cross/cross.view.css", "[mol_plot_mark_cross_curve] {\n\tcolor: var(--mol_theme_focus);\n\tstroke-width: 1px;\n\tstroke: currentColor;\n\tpointer-events: none;\n}\n\n[mol_plot_mark_cross_label_x], [mol_plot_mark_cross_label_y] {\n\tcolor: var(--mol_theme_focus);\n\tpointer-events: none;\n}\n\n[mol_plot_mark_cross_label_y] {\n\ttransform: translateY( 4px );\n}\n");
5636
5653
  })($ || ($ = {}));
5637
5654
  //mol/plot/mark/cross/-css/cross.view.css.ts
5638
5655
  ;
package/web.view.tree CHANGED
@@ -318,7 +318,8 @@ $mol_svg_text $mol_svg
318
318
  ^
319
319
  x <= pos_x \
320
320
  y <= pos_y \
321
- text-anchor <= align \middle
321
+ text-anchor <= align_hor <= align \middle
322
+ alignment-baseline <= align_vert \baseline
322
323
  sub /
323
324
  <= text \
324
325
 
@@ -404,6 +405,7 @@ $mol_svg_text_box $mol_svg_group
404
405
  $mol_plot_mark_cross $mol_plot_graph
405
406
  labels /string
406
407
  title_x_gap 4
408
+ title_y_gap 22
407
409
  threshold 16
408
410
  graphs /$mol_plot_graph
409
411
  dimensions $mol_vector_2d /