@lvce-editor/renderer-process 12.3.0 → 12.5.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.
- package/dist/rendererProcessMain.js +19 -1
- package/package.json +1 -1
|
@@ -1690,6 +1690,16 @@ const applyPatch = ($Element, patches) => {
|
|
|
1690
1690
|
}
|
|
1691
1691
|
}
|
|
1692
1692
|
};
|
|
1693
|
+
let ignore = false;
|
|
1694
|
+
const startIgnore = () => {
|
|
1695
|
+
ignore = true;
|
|
1696
|
+
};
|
|
1697
|
+
const stopIgnore = () => {
|
|
1698
|
+
ignore = false;
|
|
1699
|
+
};
|
|
1700
|
+
const enabled = () => {
|
|
1701
|
+
return ignore;
|
|
1702
|
+
};
|
|
1693
1703
|
let id = 0;
|
|
1694
1704
|
const create$H = () => {
|
|
1695
1705
|
return ++id;
|
|
@@ -1777,6 +1787,9 @@ const getEventListenerArgs = (params, event) => {
|
|
|
1777
1787
|
};
|
|
1778
1788
|
const createFn = info => {
|
|
1779
1789
|
const fn = event => {
|
|
1790
|
+
if (enabled()) {
|
|
1791
|
+
return;
|
|
1792
|
+
}
|
|
1780
1793
|
if (info.preventDefault) {
|
|
1781
1794
|
event.preventDefault(event);
|
|
1782
1795
|
}
|
|
@@ -1830,6 +1843,7 @@ const render = (elements, eventMap = {}, newEventMap = {}) => {
|
|
|
1830
1843
|
return $Root;
|
|
1831
1844
|
};
|
|
1832
1845
|
const rememberFocus$1 = ($Viewlet, dom, eventMap, uid = 0) => {
|
|
1846
|
+
startIgnore();
|
|
1833
1847
|
const oldLeft = $Viewlet.style.left;
|
|
1834
1848
|
const oldTop = $Viewlet.style.top;
|
|
1835
1849
|
const oldWidth = $Viewlet.style.width;
|
|
@@ -1866,7 +1880,10 @@ const rememberFocus$1 = ($Viewlet, dom, eventMap, uid = 0) => {
|
|
|
1866
1880
|
if (focused) {
|
|
1867
1881
|
const $NewFocused = $New.querySelector(`[name="${focused}"]`);
|
|
1868
1882
|
if ($NewFocused) {
|
|
1869
|
-
$
|
|
1883
|
+
const $Previous = $Hidden.firstChild;
|
|
1884
|
+
$Previous.className = $NewFocused.className;
|
|
1885
|
+
$Previous.placeholder = $NewFocused.placeholder;
|
|
1886
|
+
$NewFocused.replaceWith($Previous);
|
|
1870
1887
|
}
|
|
1871
1888
|
}
|
|
1872
1889
|
$Hidden.remove();
|
|
@@ -1893,6 +1910,7 @@ const rememberFocus$1 = ($Viewlet, dom, eventMap, uid = 0) => {
|
|
|
1893
1910
|
$Viewlet.style.left = oldLeft;
|
|
1894
1911
|
$Viewlet.style.height = oldHeight;
|
|
1895
1912
|
$Viewlet.style.width = oldWidth;
|
|
1913
|
+
stopIgnore();
|
|
1896
1914
|
return $Viewlet;
|
|
1897
1915
|
};
|
|
1898
1916
|
|