@netless/telebox-insider 0.2.30 → 0.2.31-beta.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1556,6 +1556,11 @@ class TeleBox {
1556
1556
  const containerRect$ = createVal(containerRect, shallowequal);
1557
1557
  const collectorRect$ = createVal(collectorRect, shallowequal);
1558
1558
  const title$ = createVal(title);
1559
+ title$.reaction((title2, _, skipUpdate) => {
1560
+ if (!skipUpdate) {
1561
+ this.titleBar.setTitle(title2);
1562
+ }
1563
+ });
1559
1564
  const visible$ = createVal(visible);
1560
1565
  visible$.reaction((visible2, _, skipUpdate) => {
1561
1566
  if (!skipUpdate && !visible2) {
@@ -1960,7 +1965,11 @@ class TeleBox {
1960
1965
  });
1961
1966
  });
1962
1967
  this._renderSideEffect.add(() => this._visible$.subscribe((visible) => {
1963
- this.$box.style.display = visible ? "block" : "none";
1968
+ if (visible) {
1969
+ this.$box.style.removeProperty("display");
1970
+ } else {
1971
+ this.$box.style.display = "none";
1972
+ }
1964
1973
  }));
1965
1974
  this._renderSideEffect.add(() => this._zIndex$.subscribe((zIndex) => {
1966
1975
  this.$box.style.zIndex = String(zIndex);