From 874d99a7cc581ac64261ab8956c4319ded6b434b Mon Sep 17 00:00:00 2001 From: Axel Vyrn Date: Wed, 4 Jun 2025 16:47:30 +0530 Subject: [PATCH 1/8] Update index.js added info tooltip for LNURL-auth button --- pages/settings/index.js | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/pages/settings/index.js b/pages/settings/index.js index 5ad2f813c..81ef23668 100644 --- a/pages/settings/index.js +++ b/pages/settings/index.js @@ -861,10 +861,28 @@ function AuthMethods ({ methods, apiKeyEnabled }) { :
} else if (provider === 'lightning') { return ( +
await unlink(provider)} /> + +
    +
  • + This is an LNURL-auth. Not sure what it is? Check here +
  • +
  • + Linking your Lightning wallet allows you to quickly sign in and zap directly from your wallet. +
  • +
  • + You can unlink your wallet at any time. +
  • +
  • + Tip: Use a wallet that supports LNURL-auth for seamless experience. Check the list of supported wallets +
  • +
+
+
) } else if (provider === 'nostr') { return await unlink(provider)} /> From 1ef41f8c0209cda6cd2774fc92ddfcc19887b4a2 Mon Sep 17 00:00:00 2001 From: Axel Vyrn Date: Tue, 10 Jun 2025 13:09:50 +0530 Subject: [PATCH 2/8] Update index.js --- pages/settings/index.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pages/settings/index.js b/pages/settings/index.js index 81ef23668..af4b67c9c 100644 --- a/pages/settings/index.js +++ b/pages/settings/index.js @@ -861,12 +861,12 @@ function AuthMethods ({ methods, apiKeyEnabled }) { :
} else if (provider === 'lightning') { return ( -
+
await unlink(provider)} /> - +
  • This is an LNURL-auth. Not sure what it is? Check here From 8dce2b8584120f3c52f90866d21e1a46a44dcc7e Mon Sep 17 00:00:00 2001 From: Axel Vyrn Date: Thu, 12 Jun 2025 14:06:40 +0530 Subject: [PATCH 3/8] Update index.js --- pages/settings/index.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pages/settings/index.js b/pages/settings/index.js index af4b67c9c..5caf2f94b 100644 --- a/pages/settings/index.js +++ b/pages/settings/index.js @@ -861,12 +861,12 @@ function AuthMethods ({ methods, apiKeyEnabled }) { :
    } else if (provider === 'lightning') { return ( -
    +
    await unlink(provider)} /> - +
    • This is an LNURL-auth. Not sure what it is? Check here From 88755313643d7245aac532aa63e5b0ea025e2b1d Mon Sep 17 00:00:00 2001 From: Axel Vyrn Date: Thu, 12 Jun 2025 20:41:51 +0530 Subject: [PATCH 4/8] Update index.js --- pages/settings/index.js | 3 --- 1 file changed, 3 deletions(-) diff --git a/pages/settings/index.js b/pages/settings/index.js index 5caf2f94b..a1c4ab467 100644 --- a/pages/settings/index.js +++ b/pages/settings/index.js @@ -871,9 +871,6 @@ function AuthMethods ({ methods, apiKeyEnabled }) {
    • This is an LNURL-auth. Not sure what it is? Check here
    • -
    • - Linking your Lightning wallet allows you to quickly sign in and zap directly from your wallet. -
    • You can unlink your wallet at any time.
    • From f342c020faffdfcf79b16e02241c0bbebc9e36fa Mon Sep 17 00:00:00 2001 From: Axel Vyrn Date: Thu, 12 Jun 2025 22:41:25 +0530 Subject: [PATCH 5/8] Update index.js --- pages/settings/index.js | 41 ++++++++++++++++++++++------------------- 1 file changed, 22 insertions(+), 19 deletions(-) diff --git a/pages/settings/index.js b/pages/settings/index.js index a1c4ab467..889115c0b 100644 --- a/pages/settings/index.js +++ b/pages/settings/index.js @@ -861,25 +861,28 @@ function AuthMethods ({ methods, apiKeyEnabled }) { :
      } else if (provider === 'lightning') { return ( -
      - await unlink(provider)} - /> - -
        -
      • - This is an LNURL-auth. Not sure what it is? Check here -
      • -
      • - You can unlink your wallet at any time. -
      • -
      • - Tip: Use a wallet that supports LNURL-auth for seamless experience. Check the list of supported wallets -
      • -
      -
      -
      +
      + await unlink(provider)} + /> + +
        +
      • + This is an LNURL-auth. Not sure what it is? Check here +
      • +
      • + Linking your Lightning wallet allows you to quickly sign in and zap directly from your wallet. +
      • +
      • + You can unlink your wallet at any time. +
      • +
      • + Tip: Use a wallet that supports LNURL-auth for seamless experience. Check the list of supported wallets +
      • +
      +
      +
      ) } else if (provider === 'nostr') { return await unlink(provider)} /> From 4e2ce50dd1ccd86dc2d4596f242541c9f6e43df0 Mon Sep 17 00:00:00 2001 From: Axel Vyrn Date: Fri, 13 Jun 2025 08:03:59 +0530 Subject: [PATCH 6/8] Update index.js --- pages/settings/index.js | 3 --- 1 file changed, 3 deletions(-) diff --git a/pages/settings/index.js b/pages/settings/index.js index 889115c0b..1b91818fd 100644 --- a/pages/settings/index.js +++ b/pages/settings/index.js @@ -871,9 +871,6 @@ function AuthMethods ({ methods, apiKeyEnabled }) {
    • This is an LNURL-auth. Not sure what it is? Check here
    • -
    • - Linking your Lightning wallet allows you to quickly sign in and zap directly from your wallet. -
    • You can unlink your wallet at any time.
    • From a6ea95b3f74eaae668452f50be57f60dd4fa33be Mon Sep 17 00:00:00 2001 From: Axel Vyrn Date: Fri, 13 Jun 2025 15:21:58 +0530 Subject: [PATCH 7/8] Update index.js --- pages/settings/index.js | 40 ++++++++++++++++++++++------------------ 1 file changed, 22 insertions(+), 18 deletions(-) diff --git a/pages/settings/index.js b/pages/settings/index.js index 1b91818fd..ae6f5ca4b 100644 --- a/pages/settings/index.js +++ b/pages/settings/index.js @@ -861,24 +861,28 @@ function AuthMethods ({ methods, apiKeyEnabled }) { :
      } else if (provider === 'lightning') { return ( -
      - await unlink(provider)} - /> - -
        -
      • - This is an LNURL-auth. Not sure what it is? Check here -
      • -
      • - You can unlink your wallet at any time. -
      • -
      • - Tip: Use a wallet that supports LNURL-auth for seamless experience. Check the list of supported wallets -
      • -
      -
      +
      +
      + await unlink(provider)} + /> +
      +
      + +
        +
      • + This is an LNURL-auth. Not sure what it is? Check here +
      • +
      • + You can unlink your wallet at any time. +
      • +
      • + Tip: Use a wallet that supports LNURL-auth for seamless experience. Check the list of supported wallets +
      • +
      +
      +
      ) } else if (provider === 'nostr') { From 8413ca97b68ade998212bfc23a1c84e8d02ba277 Mon Sep 17 00:00:00 2001 From: k00b Date: Fri, 13 Jun 2025 23:07:10 -0500 Subject: [PATCH 8/8] use existing lightning explainer --- components/lightning-auth.js | 12 ++++++------ pages/settings/index.js | 31 ++++++------------------------- 2 files changed, 12 insertions(+), 31 deletions(-) diff --git a/components/lightning-auth.js b/components/lightning-auth.js index 8f7118f4b..bfb3c9289 100644 --- a/components/lightning-auth.js +++ b/components/lightning-auth.js @@ -45,18 +45,18 @@ function QrAuth ({ k1, encodedUrl, callbackUrl, multiAuth }) { ) } -function LightningExplainer ({ text, children }) { +function LightningExplainer ({ text, children, backButton, md = 12, lg = 6 }) { const router = useRouter() return (
      -
      router.back()}>
      + {backButton &&
      router.back()}>
      }

      {text || 'Login'} with Lightning

      This is the most private way to use Stacker News. Just open your Lightning wallet and scan the QR code.
      - + - + {children} @@ -101,9 +101,9 @@ function LightningExplainer ({ text, children }) { ) } -export function LightningAuthWithExplainer ({ text, callbackUrl, multiAuth }) { +export function LightningAuthWithExplainer ({ text, callbackUrl, multiAuth, backButton = true, md = 12, lg = 6 }) { return ( - + ) diff --git a/pages/settings/index.js b/pages/settings/index.js index 16ced5741..9fb98bf31 100644 --- a/pages/settings/index.js +++ b/pages/settings/index.js @@ -9,7 +9,7 @@ import { gql, useMutation, useQuery } from '@apollo/client' import { getGetServerSideProps } from '@/api/ssrApollo' import LoginButton from '@/components/login-button' import { signIn } from 'next-auth/react' -import { LightningAuth } from '@/components/lightning-auth' +import { LightningAuthWithExplainer } from '@/components/lightning-auth' import { SETTINGS, SET_SETTINGS } from '@/fragments/users' import { useRouter } from 'next/router' import Info from '@/components/info' @@ -706,7 +706,7 @@ function QRLinkButton ({ provider, unlink, status }) { ? unlink : () => showModal(onClose =>
      - +
      ) return ( @@ -861,29 +861,10 @@ function AuthMethods ({ methods, apiKeyEnabled }) { :
      } else if (provider === 'lightning') { return ( -
      -
      - await unlink(provider)} - /> -
      -
      - -
        -
      • - This is an LNURL-auth. Not sure what it is? Check here -
      • -
      • - You can unlink your wallet at any time. -
      • -
      • - Tip: Use a wallet that supports LNURL-auth for seamless experience. Check the list of supported wallets -
      • -
      -
      -
      -
      + await unlink(provider)} + /> ) } else if (provider === 'nostr') { return await unlink(provider)} />