@mingxy/opencode-mascot 0.4.4 → 0.4.5

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mingxy/opencode-mascot",
3
- "version": "0.4.4",
3
+ "version": "0.4.5",
4
4
  "description": "OpenCode TUI mascot plugin framework - customizable ASCII mascots for your terminal",
5
5
  "author": "mingxy",
6
6
  "license": "MIT",
@@ -57,6 +57,7 @@ export function HomeMascot(props: HomeMascotProps): JSX.Element {
57
57
  <box
58
58
  left={posX()}
59
59
  top={posY()}
60
+ alignItems="center"
60
61
  zIndex={100}
61
62
  flexDirection="column"
62
63
  onMouseDown={(e: any) => {
@@ -77,16 +78,12 @@ export function HomeMascot(props: HomeMascotProps): JSX.Element {
77
78
  renderers[currentName()].setDragging(true);
78
79
  e.preventDefault();
79
80
  e.stopPropagation();
80
- props.api.renderer.clearSelection();
81
81
  }
82
82
  }}
83
83
  onMouseDrag={(e: any) => {
84
84
  if (e.modifiers?.alt && isDragging) {
85
85
  setPosX(dragAnchorX + (e.x - dragStartX));
86
86
  setPosY(dragAnchorY + (e.y - dragStartY));
87
- e.preventDefault();
88
- e.stopPropagation();
89
- props.api.renderer.clearSelection();
90
87
  }
91
88
  }}
92
89
  onMouseUp={() => { stopDrag(); }}
@@ -218,16 +218,12 @@ export function SidebarMascot(props: SidebarMascotProps): JSX.Element {
218
218
  renderers[currentName()].setDragging(true);
219
219
  e.preventDefault();
220
220
  e.stopPropagation();
221
- props.api.renderer.clearSelection();
222
221
  }
223
222
  }}
224
223
  onMouseDrag={(e: any) => {
225
224
  if (e.modifiers?.alt && isDragging) {
226
225
  setPosX(clampX(dragAnchorX + (e.x - dragStartX)));
227
226
  setPosY(clampY(dragAnchorY + (e.y - dragStartY)));
228
- e.preventDefault();
229
- e.stopPropagation();
230
- props.api.renderer.clearSelection();
231
227
  }
232
228
  }}
233
229
  onMouseUp={() => {