File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 11"use client" ;
22
33import { invoke } from "@tauri-apps/api/core" ;
4+ import { openUrl } from "@tauri-apps/plugin-opener" ;
45import { useEffect , useState } from "react" ;
56import { useTranslation } from "react-i18next" ;
67import { LuExternalLink } from "react-icons/lu" ;
@@ -45,7 +46,7 @@ export function DeviceCodeVerifyDialog({
4546 const handleOpenLogin = async ( ) => {
4647 setIsOpeningLogin ( true ) ;
4748 try {
48- await invoke ( "handle_url_open" , { url : DEVICE_LINK_URL } ) ;
49+ await openUrl ( DEVICE_LINK_URL ) ;
4950 } catch ( error ) {
5051 console . error ( "Failed to open login link:" , error ) ;
5152 showErrorToast ( String ( error ) ) ;
Original file line number Diff line number Diff line change 11"use client" ;
22
33import { invoke } from "@tauri-apps/api/core" ;
4+ import { openUrl } from "@tauri-apps/plugin-opener" ;
45import { useCallback , useEffect , useState } from "react" ;
56import { useTranslation } from "react-i18next" ;
67import { LuEye , LuEyeOff } from "react-icons/lu" ;
@@ -206,7 +207,7 @@ export function SyncConfigDialog({
206207
207208 const handleOpenLogin = useCallback ( async ( ) => {
208209 try {
209- await invoke ( "handle_url_open" , { url : DEVICE_LINK_URL } ) ;
210+ await openUrl ( DEVICE_LINK_URL ) ;
210211 // Hand off the verify step to its own dialog so the user has a
211212 // focused place to paste the code, and so it doesn't visually
212213 // stack with this dialog or any other modal currently on screen.
You can’t perform that action at this time.
0 commit comments