@arthony/keybook 0.4.0 → 0.4.1
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/cli.js +11 -6
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -795,7 +795,7 @@ function AddEntryForm({ apps, existingTags, onSubmit, onComplete, onCancel, reso
|
|
|
795
795
|
const idx = TYPES.indexOf(draft.type);
|
|
796
796
|
return update({ type: TYPES[key.leftArrow ? (idx + TYPES.length - 1) % TYPES.length : (idx + 1) % TYPES.length] });
|
|
797
797
|
}
|
|
798
|
-
if (key.return) return
|
|
798
|
+
if (key.return) return setFocused(2);
|
|
799
799
|
return;
|
|
800
800
|
}
|
|
801
801
|
if (focused === 3 && draft.type === "recipe") {
|
|
@@ -818,6 +818,7 @@ function AddEntryForm({ apps, existingTags, onSubmit, onComplete, onCancel, reso
|
|
|
818
818
|
if (key.backspace || key.delete) return update({ [fieldKey]: draft[fieldKey].slice(0, -1) });
|
|
819
819
|
if (input && !key.ctrl && !key.meta) return update({ [fieldKey]: draft[fieldKey] + input });
|
|
820
820
|
});
|
|
821
|
+
const enterHint = focused <= 1 ? "next" : focused === 3 && draft.type === "recipe" ? "add step" : "review";
|
|
821
822
|
if (screen === "review") return /* @__PURE__ */ jsx(ReviewScreen, {
|
|
822
823
|
app: resolvedApp(review),
|
|
823
824
|
entry: draftToEntryInput(review),
|
|
@@ -842,12 +843,16 @@ function AddEntryForm({ apps, existingTags, onSubmit, onComplete, onCancel, reso
|
|
|
842
843
|
lockedApp
|
|
843
844
|
})
|
|
844
845
|
}),
|
|
845
|
-
/* @__PURE__ */
|
|
846
|
+
/* @__PURE__ */ jsxs(Box, {
|
|
846
847
|
marginTop: 1,
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
848
|
+
flexDirection: "column",
|
|
849
|
+
children: [hint ? /* @__PURE__ */ jsx(Text, {
|
|
850
|
+
color: "red",
|
|
851
|
+
children: hint
|
|
852
|
+
}) : null, /* @__PURE__ */ jsx(Text, {
|
|
853
|
+
color: "gray",
|
|
854
|
+
children: `⌃N next · ⌃P prev · ⏎ ${enterHint} · esc cancel`
|
|
855
|
+
})]
|
|
851
856
|
})
|
|
852
857
|
]
|
|
853
858
|
});
|