diff --git a/samples/dev/index.html b/samples/dev/index.html
index 609054f..813546f 100644
--- a/samples/dev/index.html
+++ b/samples/dev/index.html
@@ -372,7 +372,10 @@
function reactivateEditOnX() {
clearStackSelection();
if (calc.isValidIndex(0)) {
- calc.edit(0);
+ const value = getStackValue(0);
+ calc.remove(0);
+ calc.inputValue = calc.formatNumber(value);
+ calc.isEditing = true;
} else {
calc.inputValue = '';
calc.isEditing = true;
@@ -397,7 +400,7 @@
}
if (direction === 'down' && stackCursor === 0) {
- clearStackSelection();
+ reactivateEditOnX();
}
}