@holoviz/panel 1.2.2-a.1 → 1.2.2-a.3
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/dist/bundled/datatabulator/luxon/build/global/luxon.min.js +1 -1
- package/dist/bundled/datatabulator/luxon/build/global/luxon.min.js.map +1 -1
- package/dist/bundled/notificationarea/panel/1.2.2-a.3/dist/bundled/font-awesome/css/all.min.css +2 -0
- package/dist/bundled/panel/1.2.2-a.3/dist/bundled/bootstrap5/css/bootstrap.min.css +2 -0
- package/dist/bundled/panel/1.2.2-a.3/dist/bundled/bootstrap5/js/bootstrap.bundle.min.js +2 -0
- package/dist/bundled/panel/1.2.2-a.3/dist/bundled/font-awesome/css/all.min.css +2 -0
- package/dist/bundled/panel/1.2.2-a.3/dist/bundled/jquery/jquery.slim.min.js +2 -0
- package/dist/bundled/plotlyplot/panel/1.2.2-a.3/dist/bundled/jquery/jquery.slim.min.js +2 -0
- package/dist/lib/models/column.d.ts +3 -0
- package/dist/lib/models/column.js +18 -14
- package/dist/lib/models/column.js.map +1 -1
- package/dist/lib/models/tabulator.d.ts +1 -1
- package/dist/lib/models/tabulator.js +21 -13
- package/dist/lib/models/tabulator.js.map +1 -1
- package/dist/panel.js +47 -33
- package/dist/panel.js.map +1 -1
- package/dist/panel.json +1 -1
- package/dist/panel.min.js +5 -5
- package/dist/wheels/{bokeh-3.2.1-py3-none-any.whl → bokeh-3.2.2-py3-none-any.whl} +0 -0
- package/dist/wheels/{panel-1.2.2a1-py3-none-any.whl → panel-1.2.2a3-py3-none-any.whl} +0 -0
- package/package.json +1 -1
- package/dist/bundled/notificationarea/panel/1.2.2-a.1/dist/bundled/font-awesome/css/all.min.css +0 -2
- package/dist/bundled/panel/1.2.2-a.1/dist/bundled/bootstrap5/css/bootstrap.min.css +0 -2
- package/dist/bundled/panel/1.2.2-a.1/dist/bundled/bootstrap5/js/bootstrap.bundle.min.js +0 -2
- package/dist/bundled/panel/1.2.2-a.1/dist/bundled/font-awesome/css/all.min.css +0 -2
- package/dist/bundled/panel/1.2.2-a.1/dist/bundled/jquery/jquery.slim.min.js +0 -2
- package/dist/bundled/plotlyplot/panel/1.2.2-a.1/dist/bundled/jquery/jquery.slim.min.js +0 -2
package/dist/panel.js
CHANGED
|
@@ -60,13 +60,13 @@
|
|
|
60
60
|
__esExport("BrowserInfo", browser_1.BrowserInfo);
|
|
61
61
|
var card_1 = require("c1e57c7e7d") /* ./card */;
|
|
62
62
|
__esExport("Card", card_1.Card);
|
|
63
|
-
var column_1 = require("
|
|
63
|
+
var column_1 = require("13afd4a31a") /* ./column */;
|
|
64
64
|
__esExport("Column", column_1.Column);
|
|
65
65
|
var comm_manager_1 = require("1e66dab844") /* ./comm_manager */;
|
|
66
66
|
__esExport("CommManager", comm_manager_1.CommManager);
|
|
67
67
|
var customselect_1 = require("9c8629b48f") /* ./customselect */;
|
|
68
68
|
__esExport("CustomSelect", customselect_1.CustomSelect);
|
|
69
|
-
var tabulator_1 = require("
|
|
69
|
+
var tabulator_1 = require("2ec00301c1") /* ./tabulator */;
|
|
70
70
|
__esExport("DataTabulator", tabulator_1.DataTabulator);
|
|
71
71
|
var datetime_picker_1 = require("6658732ce1") /* ./datetime_picker */;
|
|
72
72
|
__esExport("DatetimePicker", datetime_picker_1.DatetimePicker);
|
|
@@ -571,7 +571,7 @@
|
|
|
571
571
|
__esModule();
|
|
572
572
|
const tslib_1 = require("tslib");
|
|
573
573
|
var _a;
|
|
574
|
-
const column_1 = require("
|
|
574
|
+
const column_1 = require("13afd4a31a") /* ./column */;
|
|
575
575
|
const DOM = tslib_1.__importStar(require("@bokehjs/core/dom"));
|
|
576
576
|
class CardView extends column_1.ColumnView {
|
|
577
577
|
connect_signals() {
|
|
@@ -688,7 +688,7 @@
|
|
|
688
688
|
}));
|
|
689
689
|
})();
|
|
690
690
|
},
|
|
691
|
-
"
|
|
691
|
+
"13afd4a31a": /* models/column.js */ function _(require, module, exports, __esModule, __esExport) {
|
|
692
692
|
__esModule();
|
|
693
693
|
const tslib_1 = require("tslib");
|
|
694
694
|
var _a;
|
|
@@ -697,13 +697,19 @@
|
|
|
697
697
|
class ColumnView extends column_1.ColumnView {
|
|
698
698
|
connect_signals() {
|
|
699
699
|
super.connect_signals();
|
|
700
|
-
const { children, scroll_button_threshold } = this.model.properties;
|
|
700
|
+
const { children, scroll_position, scroll_button_threshold } = this.model.properties;
|
|
701
701
|
this.on_change(children, () => this.trigger_auto_scroll());
|
|
702
|
+
this.on_change(scroll_position, () => this.scroll_to_position());
|
|
702
703
|
this.on_change(scroll_button_threshold, () => this.toggle_scroll_button());
|
|
703
704
|
}
|
|
704
705
|
get distance_from_latest() {
|
|
705
706
|
return this.el.scrollHeight - this.el.scrollTop - this.el.clientHeight;
|
|
706
707
|
}
|
|
708
|
+
scroll_to_position() {
|
|
709
|
+
requestAnimationFrame(() => {
|
|
710
|
+
this.el.scrollTop = this.model.scroll_position;
|
|
711
|
+
});
|
|
712
|
+
}
|
|
707
713
|
scroll_to_latest() {
|
|
708
714
|
// Waits for the child to be rendered before scrolling
|
|
709
715
|
requestAnimationFrame(() => {
|
|
@@ -717,38 +723,35 @@
|
|
|
717
723
|
return;
|
|
718
724
|
this.scroll_to_latest();
|
|
719
725
|
}
|
|
726
|
+
record_scroll_position() {
|
|
727
|
+
this.model.scroll_position = this.el.scrollTop;
|
|
728
|
+
}
|
|
720
729
|
toggle_scroll_button() {
|
|
721
730
|
const threshold = this.model.scroll_button_threshold;
|
|
722
731
|
const exceeds_threshold = this.distance_from_latest >= threshold;
|
|
723
|
-
|
|
732
|
+
if (this.scroll_down_button_el) {
|
|
724
733
|
this.scroll_down_button_el.classList.toggle("visible", threshold !== 0 && exceeds_threshold);
|
|
725
|
-
}
|
|
734
|
+
}
|
|
735
|
+
;
|
|
726
736
|
}
|
|
727
737
|
render() {
|
|
728
738
|
super.render();
|
|
729
|
-
this.empty();
|
|
730
|
-
this._update_stylesheets();
|
|
731
|
-
this._update_css_classes();
|
|
732
|
-
this._apply_styles();
|
|
733
|
-
this._apply_visible();
|
|
734
|
-
this.class_list.add(...this.css_classes());
|
|
735
739
|
this.scroll_down_button_el = DOM.createElement('div', { class: 'scroll-button' });
|
|
736
740
|
this.shadow_el.appendChild(this.scroll_down_button_el);
|
|
737
741
|
this.el.addEventListener("scroll", () => {
|
|
742
|
+
this.record_scroll_position();
|
|
738
743
|
this.toggle_scroll_button();
|
|
739
744
|
});
|
|
740
745
|
this.scroll_down_button_el.addEventListener("click", () => {
|
|
741
746
|
this.scroll_to_latest();
|
|
742
747
|
});
|
|
743
|
-
for (const child_view of this.child_views) {
|
|
744
|
-
this.shadow_el.appendChild(child_view.el);
|
|
745
|
-
child_view.render();
|
|
746
|
-
child_view.after_render();
|
|
747
|
-
}
|
|
748
748
|
}
|
|
749
749
|
after_render() {
|
|
750
750
|
super.after_render();
|
|
751
751
|
requestAnimationFrame(() => {
|
|
752
|
+
if (this.model.scroll_position) {
|
|
753
|
+
this.scroll_to_position();
|
|
754
|
+
}
|
|
752
755
|
if (this.model.view_latest) {
|
|
753
756
|
this.scroll_to_latest();
|
|
754
757
|
}
|
|
@@ -770,6 +773,7 @@
|
|
|
770
773
|
(() => {
|
|
771
774
|
_a.prototype.default_view = ColumnView;
|
|
772
775
|
_a.define(({ Int, Boolean }) => ({
|
|
776
|
+
scroll_position: [Int, 0],
|
|
773
777
|
auto_scroll_limit: [Int, 0],
|
|
774
778
|
scroll_button_threshold: [Int, 0],
|
|
775
779
|
view_latest: [Boolean, false],
|
|
@@ -1001,7 +1005,7 @@
|
|
|
1001
1005
|
});
|
|
1002
1006
|
})();
|
|
1003
1007
|
},
|
|
1004
|
-
"
|
|
1008
|
+
"2ec00301c1": /* models/tabulator.js */ function _(require, module, exports, __esModule, __esExport) {
|
|
1005
1009
|
__esModule();
|
|
1006
1010
|
var _a, _b, _c;
|
|
1007
1011
|
const dom_1 = require("@bokehjs/core/dom");
|
|
@@ -1370,6 +1374,8 @@
|
|
|
1370
1374
|
el.classList.add(cls);
|
|
1371
1375
|
}
|
|
1372
1376
|
render() {
|
|
1377
|
+
if (this.tabulator != null)
|
|
1378
|
+
this.tabulator.destroy();
|
|
1373
1379
|
super.render();
|
|
1374
1380
|
this._initializing = true;
|
|
1375
1381
|
const container = (0, dom_2.div)({ style: "display: contents;" });
|
|
@@ -1524,10 +1530,12 @@
|
|
|
1524
1530
|
return Object.assign(Object.assign({}, configuration), { "data": data });
|
|
1525
1531
|
}
|
|
1526
1532
|
get child_models() {
|
|
1533
|
+
var _d, _e;
|
|
1527
1534
|
const children = [];
|
|
1528
1535
|
for (const idx of this.model.expanded) {
|
|
1529
|
-
|
|
1530
|
-
|
|
1536
|
+
const child = (_e = (_d = this.model.children).get) === null || _e === void 0 ? void 0 : _e.call(_d, idx);
|
|
1537
|
+
if (child != null)
|
|
1538
|
+
children.push(child);
|
|
1531
1539
|
}
|
|
1532
1540
|
return children;
|
|
1533
1541
|
}
|
|
@@ -1541,17 +1549,18 @@
|
|
|
1541
1549
|
this._render_row(row, false);
|
|
1542
1550
|
}
|
|
1543
1551
|
this._update_children();
|
|
1544
|
-
this.tabulator.rowManager.
|
|
1552
|
+
if (this.tabulator.rowManager.renderer != null)
|
|
1553
|
+
this.tabulator.rowManager.adjustTableSize();
|
|
1545
1554
|
this.invalidate_layout();
|
|
1546
1555
|
});
|
|
1547
1556
|
}
|
|
1548
1557
|
_render_row(row, resize = true) {
|
|
1549
1558
|
var _d;
|
|
1550
1559
|
const index = (_d = row._row) === null || _d === void 0 ? void 0 : _d.data._index;
|
|
1551
|
-
if (!this.model.expanded.includes(index) ||
|
|
1560
|
+
if (!this.model.expanded.includes(index) || this.model.children.get(index) == null)
|
|
1552
1561
|
return;
|
|
1553
1562
|
const model = this.model.children.get(index);
|
|
1554
|
-
const view = this._child_views.get(model);
|
|
1563
|
+
const view = model == null ? null : this._child_views.get(model);
|
|
1555
1564
|
if (view == null)
|
|
1556
1565
|
return;
|
|
1557
1566
|
const rowEl = row.getElement();
|
|
@@ -1561,8 +1570,10 @@
|
|
|
1561
1570
|
const viewEl = (0, dom_2.div)({ style: "background-color: " + bg + "; margin-left:" + neg_margin + "; max-width: 100%; overflow-x: hidden;" });
|
|
1562
1571
|
viewEl.appendChild(view.el);
|
|
1563
1572
|
rowEl.appendChild(viewEl);
|
|
1564
|
-
view.
|
|
1565
|
-
|
|
1573
|
+
if (!view.has_finished()) {
|
|
1574
|
+
view.render();
|
|
1575
|
+
view.after_render();
|
|
1576
|
+
}
|
|
1566
1577
|
if (resize) {
|
|
1567
1578
|
this._update_children();
|
|
1568
1579
|
this.tabulator.rowManager.adjustTableSize();
|
|
@@ -1575,6 +1586,7 @@
|
|
|
1575
1586
|
return "<i>" + icon + "</i>";
|
|
1576
1587
|
}
|
|
1577
1588
|
_update_expand(cell) {
|
|
1589
|
+
var _d, _e, _f, _g;
|
|
1578
1590
|
const index = cell._cell.row.data._index;
|
|
1579
1591
|
const expanded = [...this.model.expanded];
|
|
1580
1592
|
const exp_index = expanded.indexOf(index);
|
|
@@ -1582,8 +1594,8 @@
|
|
|
1582
1594
|
expanded.push(index);
|
|
1583
1595
|
else {
|
|
1584
1596
|
const removed = expanded.splice(exp_index, 1)[0];
|
|
1585
|
-
|
|
1586
|
-
|
|
1597
|
+
const model = (_e = (_d = this.model.children).get) === null || _e === void 0 ? void 0 : _e.call(_d, removed);
|
|
1598
|
+
if (model != null) {
|
|
1587
1599
|
const view = this._child_views.get(model);
|
|
1588
1600
|
if (view !== undefined && view.el != null)
|
|
1589
1601
|
(0, dom_1.undisplay)(view.el);
|
|
@@ -1594,7 +1606,7 @@
|
|
|
1594
1606
|
return;
|
|
1595
1607
|
let ready = true;
|
|
1596
1608
|
for (const idx of this.model.expanded) {
|
|
1597
|
-
if (
|
|
1609
|
+
if (((_g = (_f = this.model.children).get) === null || _g === void 0 ? void 0 : _g.call(_f, idx)) == null) {
|
|
1598
1610
|
ready = false;
|
|
1599
1611
|
break;
|
|
1600
1612
|
}
|
|
@@ -1798,6 +1810,8 @@
|
|
|
1798
1810
|
}
|
|
1799
1811
|
// Update table
|
|
1800
1812
|
setData() {
|
|
1813
|
+
if (this._initializing || this._building || !this.tabulator.initialized)
|
|
1814
|
+
return;
|
|
1801
1815
|
const data = this.getData();
|
|
1802
1816
|
if (this.model.pagination != null)
|
|
1803
1817
|
this.tabulator.rowManager.setData(data, true, false);
|
|
@@ -1851,7 +1865,7 @@
|
|
|
1851
1865
|
}
|
|
1852
1866
|
setStyles() {
|
|
1853
1867
|
const style_data = this.model.cell_styles.data;
|
|
1854
|
-
if (this.tabulator == null || this.tabulator.getDataCount() == 0 || !style_data.size)
|
|
1868
|
+
if (this.tabulator == null || this.tabulator.getDataCount() == 0 || style_data == null || !style_data.size)
|
|
1855
1869
|
return;
|
|
1856
1870
|
this._applied_styles = false;
|
|
1857
1871
|
for (const r of style_data.keys()) {
|
|
@@ -1909,7 +1923,7 @@
|
|
|
1909
1923
|
}
|
|
1910
1924
|
}
|
|
1911
1925
|
setSelection() {
|
|
1912
|
-
if (this.tabulator == null || this._selection_updating)
|
|
1926
|
+
if (this.tabulator == null || this._initializing || this._selection_updating || !this.tabulator.initialized)
|
|
1913
1927
|
return;
|
|
1914
1928
|
const indices = this.model.source.selected.indices;
|
|
1915
1929
|
const current_indices = this.tabulator.getSelectedData().map((row) => row._index);
|
|
@@ -2033,7 +2047,7 @@
|
|
|
2033
2047
|
_c.define(({ Any, Array, Boolean, Nullable, Number, Ref, String }) => ({
|
|
2034
2048
|
aggregators: [Any, {}],
|
|
2035
2049
|
buttons: [Any, {}],
|
|
2036
|
-
children: [Any,
|
|
2050
|
+
children: [Any, new Map()],
|
|
2037
2051
|
configuration: [Any, {}],
|
|
2038
2052
|
columns: [Array(Ref(tables_1.TableColumn)), []],
|
|
2039
2053
|
download: [Boolean, false],
|
|
@@ -19331,5 +19345,5 @@
|
|
|
19331
19345
|
}
|
|
19332
19346
|
exports.initialize_fullscreen_render = initialize_fullscreen_render;
|
|
19333
19347
|
},
|
|
19334
|
-
}, "4e90918c0a", {"index":"4e90918c0a","models/index":"6e19b31aba","models/ace":"7df2008a2e","models/layout":"ea218d1c3c","models/audio":"78153b60aa","models/browser":"6df8bf1ac7","models/card":"c1e57c7e7d","models/column":"
|
|
19348
|
+
}, "4e90918c0a", {"index":"4e90918c0a","models/index":"6e19b31aba","models/ace":"7df2008a2e","models/layout":"ea218d1c3c","models/audio":"78153b60aa","models/browser":"6df8bf1ac7","models/card":"c1e57c7e7d","models/column":"13afd4a31a","models/comm_manager":"1e66dab844","models/customselect":"9c8629b48f","models/tabulator":"2ec00301c1","models/data":"fd9108e30e","models/datetime_picker":"6658732ce1","models/deckgl":"991e3a226c","models/tooltips":"9588ab7c9e","models/echarts":"eded13f5d7","models/event-to-object":"490942d778","models/html":"6b3b0facc2","models/ipywidget":"e3556c1e99","models/json":"66846b828c","models/jsoneditor":"4b8a56c700","models/file_download":"9c15016be8","models/katex":"197cfa57e5","models/location":"00a25cf872","models/mathjax":"46a1770629","models/pdf":"d49a559fbc","models/perspective":"9f0456e5b5","models/player":"c172556ad3","models/plotly":"bb3d0ded66","models/util":"990b5dd5c7","models/progress":"b82925a928","models/quill":"e115225ba2","models/reactive_html":"b969c294f5","models/singleselect":"6b20024bba","models/speech_to_text":"cd0c80cc4c","models/state":"66717cb841","models/tabs":"67a5649f75","models/terminal":"cd4a941f8d","models/text_to_speech":"eb4ae0acfa","models/tooltip_icon":"26ffc3afe8","models/trend":"8f4ab32d74","models/vega":"3b23e1bc5c","models/video":"4ac59b8079","models/videostream":"797fd61298","models/vizzu":"e8339ee57a","models/vtk/index":"c51f25e2a7","models/vtk/vtkjs":"3bce7c9db6","models/vtk/vtklayout":"d7ded264dc","models/vtk/util":"a76a9b7c23","models/vtk/vtkcolorbar":"787f6aeecd","models/vtk/vtkaxes":"7cec459a06","models/vtk/vtkvolume":"c2892117a7","models/vtk/vtksynchronized":"40c4377615","models/vtk/panel_fullscreen_renwin_sync":"877619fe71"}, {});});
|
|
19335
19349
|
//# sourceMappingURL=panel.js.map
|