Skip to content

Commit b8e7265

Browse files
committed
fix(tui): handle 4-5 codes too in c to copy logic
1 parent 95632d8 commit b8e7265

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

packages/opencode/src/cli/cmd/tui/component/dialog-provider.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ function AutoMethod(props: AutoMethodProps) {
127127

128128
useKeyboard((evt) => {
129129
if (evt.name === "c" && !evt.ctrl && !evt.meta) {
130-
const code = props.authorization.instructions.match(/[A-Z0-9]{4}-[A-Z0-9]{4}/)?.[0] ?? props.authorization.url
130+
const code = props.authorization.instructions.match(/[A-Z0-9]{4}-[A-Z0-9]{4,5}/)?.[0] ?? props.authorization.url
131131
Clipboard.copy(code)
132132
.then(() => toast.show({ message: "Copied to clipboard", variant: "info" }))
133133
.catch(toast.error)

0 commit comments

Comments
 (0)