@aurora-foundation/obsidian-next 0.4.10 → 0.4.13
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/CHANGELOG.md +18 -0
- package/dist/index.js +31 -5
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,24 @@ All notable changes to this project will be documented in this file.
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
|
|
6
6
|
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
7
|
|
|
8
|
+
## [0.4.12] - 2026-02-14
|
|
9
|
+
|
|
10
|
+
### Fixed
|
|
11
|
+
- **Message Overlapping**: Fixed critical bug where messages rendered on top of each other when viewport filled up. Removed dynamic `justifyContent` switching that was causing Ink's layout engine to break. Now uses consistent `flex-end` for proper chat-style bottom-anchored layout.
|
|
12
|
+
|
|
13
|
+
---
|
|
14
|
+
|
|
15
|
+
## [0.4.11] - 2026-02-14
|
|
16
|
+
|
|
17
|
+
### Fixed
|
|
18
|
+
- **Chat Layout**: Messages no longer stick to the bottom of the terminal when few or no messages are present. Layout dynamically switches between top-aligned (few messages) and bottom-anchored (full viewport).
|
|
19
|
+
- **Scroll Support**: Arrow keys (Up/Down) now scroll through chat history one line at a time. Shift+Arrow jumps a full page. Scroll position is preserved when new messages arrive if the user has scrolled up.
|
|
20
|
+
- **Scroll Indicator**: Yellow indicator shows current scroll position and keybind hints when scrolled up.
|
|
21
|
+
- **Scroll Reset**: Sending a message or running `/clear` automatically jumps back to the bottom of the conversation.
|
|
22
|
+
- **MessageList Boundary Guard**: Prevents crash when events are cleared while scrolled up (negative index guard).
|
|
23
|
+
|
|
24
|
+
---
|
|
25
|
+
|
|
8
26
|
## [0.4.8] - 2026-02-13
|
|
9
27
|
|
|
10
28
|
### Added
|
package/dist/index.js
CHANGED
|
@@ -951,7 +951,7 @@ var MessageListComponent = ({
|
|
|
951
951
|
maxEvents = 50,
|
|
952
952
|
scrollOffset = 0
|
|
953
953
|
}) => {
|
|
954
|
-
const end = events.length - scrollOffset;
|
|
954
|
+
const end = Math.max(0, events.length - scrollOffset);
|
|
955
955
|
const start = Math.max(0, end - maxEvents);
|
|
956
956
|
const visibleEvents = events.slice(start, end);
|
|
957
957
|
return /* @__PURE__ */ jsx9(Box9, { flexDirection: "column", children: visibleEvents.map((event, i) => {
|
|
@@ -6034,6 +6034,7 @@ var Root = () => {
|
|
|
6034
6034
|
const BANNER_HEIGHT = 6;
|
|
6035
6035
|
const INPUT_AREA_HEIGHT = 6;
|
|
6036
6036
|
const dynamicMaxEvents = Math.max(5, rows - (BANNER_HEIGHT + INPUT_AREA_HEIGHT));
|
|
6037
|
+
const contentHeight = rows - BANNER_HEIGHT - INPUT_AREA_HEIGHT;
|
|
6037
6038
|
useEffect23(() => {
|
|
6038
6039
|
if (!stdout) return;
|
|
6039
6040
|
const onResize = () => {
|
|
@@ -6150,7 +6151,10 @@ var Root = () => {
|
|
|
6150
6151
|
}
|
|
6151
6152
|
return result;
|
|
6152
6153
|
});
|
|
6153
|
-
setScrollOffset(
|
|
6154
|
+
setScrollOffset((prev) => {
|
|
6155
|
+
if (prev === 0) return 0;
|
|
6156
|
+
return prev;
|
|
6157
|
+
});
|
|
6154
6158
|
}, []);
|
|
6155
6159
|
const scheduleFlush = useCallback7((immediate) => {
|
|
6156
6160
|
if (immediate) {
|
|
@@ -6166,6 +6170,7 @@ var Root = () => {
|
|
|
6166
6170
|
const handler = (event) => {
|
|
6167
6171
|
if (event.type === "clear_history") {
|
|
6168
6172
|
setEvents([]);
|
|
6173
|
+
setScrollOffset(0);
|
|
6169
6174
|
history.clear();
|
|
6170
6175
|
setPendingPrompt(null);
|
|
6171
6176
|
return;
|
|
@@ -6363,6 +6368,18 @@ var Root = () => {
|
|
|
6363
6368
|
return;
|
|
6364
6369
|
}
|
|
6365
6370
|
if (showPalette) return;
|
|
6371
|
+
if (matches.length === 0) {
|
|
6372
|
+
if (key.upArrow) {
|
|
6373
|
+
const step = key.shift ? dynamicMaxEvents : 1;
|
|
6374
|
+
setScrollOffset((prev) => Math.min(prev + step, Math.max(0, events.length - 1)));
|
|
6375
|
+
return;
|
|
6376
|
+
}
|
|
6377
|
+
if (key.downArrow) {
|
|
6378
|
+
const step = key.shift ? dynamicMaxEvents : 1;
|
|
6379
|
+
setScrollOffset((prev) => Math.max(prev - step, 0));
|
|
6380
|
+
return;
|
|
6381
|
+
}
|
|
6382
|
+
}
|
|
6366
6383
|
if (pendingPrompt || isBusy) return;
|
|
6367
6384
|
if (matches.length > 0) {
|
|
6368
6385
|
if (key.upArrow) {
|
|
@@ -6413,6 +6430,7 @@ var Root = () => {
|
|
|
6413
6430
|
const silent = matchingCommand?.isView || false;
|
|
6414
6431
|
bus.emitUser({ type: "user_input", content: trimmed, silent });
|
|
6415
6432
|
setInput("");
|
|
6433
|
+
setScrollOffset(0);
|
|
6416
6434
|
};
|
|
6417
6435
|
useEffect23(() => {
|
|
6418
6436
|
const uiHandler = (event) => {
|
|
@@ -6537,15 +6555,14 @@ var Root = () => {
|
|
|
6537
6555
|
Box33,
|
|
6538
6556
|
{
|
|
6539
6557
|
flexDirection: "column",
|
|
6540
|
-
flexGrow: activeView
|
|
6558
|
+
flexGrow: activeView !== "chat" ? 1 : 0,
|
|
6541
6559
|
overflowY: "hidden",
|
|
6542
|
-
justifyContent: "flex-end",
|
|
6543
6560
|
children: activeView === "chat" ? /* @__PURE__ */ jsx33(
|
|
6544
6561
|
MessageList,
|
|
6545
6562
|
{
|
|
6546
6563
|
events,
|
|
6547
6564
|
maxEvents: dynamicMaxEvents,
|
|
6548
|
-
scrollOffset
|
|
6565
|
+
scrollOffset
|
|
6549
6566
|
}
|
|
6550
6567
|
) : renderView()
|
|
6551
6568
|
}
|
|
@@ -6587,6 +6604,15 @@ var Root = () => {
|
|
|
6587
6604
|
onResolve: handlePromptResolve
|
|
6588
6605
|
}
|
|
6589
6606
|
) }),
|
|
6607
|
+
scrollOffset > 0 && /* @__PURE__ */ jsxs32(Box33, { paddingX: 1, children: [
|
|
6608
|
+
/* @__PURE__ */ jsxs32(Text33, { color: "yellow", children: [
|
|
6609
|
+
"\u2191",
|
|
6610
|
+
" Scrolled up ",
|
|
6611
|
+
scrollOffset,
|
|
6612
|
+
" lines"
|
|
6613
|
+
] }),
|
|
6614
|
+
/* @__PURE__ */ jsx33(Text33, { dimColor: true, children: " \xB7 \u2193 scroll down \xB7 shift+\u2193 page down" })
|
|
6615
|
+
] }),
|
|
6590
6616
|
/* @__PURE__ */ jsxs32(Box33, { flexDirection: "column", children: [
|
|
6591
6617
|
/* @__PURE__ */ jsx33(Box33, { paddingX: 0, children: /* @__PURE__ */ jsx33(Text33, { dimColor: true, children: separatorLine }) }),
|
|
6592
6618
|
/* @__PURE__ */ jsxs32(Box33, { paddingX: 1, children: [
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aurora-foundation/obsidian-next",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.13",
|
|
4
4
|
"description": "Next-gen AI Agent CLI",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"type": "module",
|
|
@@ -83,4 +83,4 @@
|
|
|
83
83
|
"contributors": [
|
|
84
84
|
"Polyoxy <iversonbusiness3@gmail.com>"
|
|
85
85
|
]
|
|
86
|
-
}
|
|
86
|
+
}
|