구성 요소 2단계 인증 Two-Factor Authentication 구성 요소

Two-Factor Authentication 구성 요소

그라데이션 무지개 액센트가 있는 간단한 산업 테마의 이중 인증 구성 요소로, 비즈니스/기업 웹 사이트에 적합합니다. 반응성 및 다크 모드 지원이 특징입니다.

미리 보기

HTML 코드

<div class="min-h-screen bg-gray-100 dark:bg-gray-900 flex items-center justify-center p-4">
  <div class="w-full max-w-md bg-white dark:bg-gray-800 rounded-lg shadow-xl overflow-hidden border border-gray-200 dark:border-gray-700">
    <div class="p-6 space-y-6">
      <div class="flex items-center justify-center mb-4">
        <div class="w-16 h-16 bg-gradient-to-r from-red-500 via-yellow-500 to-green-500 dark:from-red-600 dark:via-yellow-600 dark:to-green-600 rounded-full flex items-center justify-center shadow-lg">
          <svg class="w-8 h-8 text-white" fill="none" stroke="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
            <path stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M12 15v2m-6 4h12a2 2 0 002-2v-6a2 2 0 00-2-2H6a2 2 0 00-2 2v6a2 2 0 002 2zm10-10V7a4 4 0 00-8 0v4h8z"></path>
          </svg>
        </div>
      </div>
      <h2 class="text-2xl font-extrabold text-center text-gray-900 dark:text-gray-100 uppercase tracking-wide">Two-Factor Authentication</h2>
      <p class="text-center text-gray-600 dark:text-gray-400 text-sm">
        Please enter the 6-digit code from your authenticator app.
      </p>
      <form class="space-y-4">
        <div class="flex justify-center space-x-2">
          <input type="text" maxlength="1" class="w-12 h-14 text-center text-2xl font-bold bg-gray-50 dark:bg-gray-700 text-gray-900 dark:text-gray-100 border border-gray-300 dark:border-gray-600 rounded-lg focus:ring-2 focus:ring-blue-500 focus:border-blue-500 outline-none transition-all duration-200 ease-in-out sm:w-14 sm:h-16"
          aria-label="Digit 1" oninput="this.value=this.value.replace(/[^0-9]/g,''); if(this.value.length===this.maxLength) this.nextElementSibling.focus();">
          <input type="text" maxlength="1" class="w-12 h-14 text-center text-2xl font-bold bg-gray-50 dark:bg-gray-700 text-gray-900 dark:text-gray-100 border border-gray-300 dark:border-gray-600 rounded-lg focus:ring-2 focus:ring-blue-500 focus:border-blue-500 outline-none transition-all duration-200 ease-in-out sm:w-14 sm:h-16"
          aria-label="Digit 2" oninput="this.value=this.value.replace(/[^0-9]/g,''); if(this.value.length===this.maxLength) this.nextElementSibling.focus();">
          <input type="text" maxlength="1" class="w-12 h-14 text-center text-2xl font-bold bg-gray-50 dark:bg-gray-700 text-gray-900 dark:text-gray-100 border border-gray-300 dark:border-gray-600 rounded-lg focus:ring-2 focus:ring-blue-500 focus:border-blue-500 outline-none transition-all duration-200 ease-in-out sm:w-14 sm:h-16"
          aria-label="Digit 3" oninput="this.value=this.value.replace(/[^0-9]/g,''); if(this.value.length===this.maxLength) this.nextElementSibling.focus();">
          <input type="text" maxlength="1" class="w-12 h-14 text-center text-2xl font-bold bg-gray-50 dark:bg-gray-700 text-gray-900 dark:text-gray-100 border border-gray-300 dark:border-gray-600 rounded-lg focus:ring-2 focus:ring-blue-500 focus:border-blue-500 outline-none transition-all duration-200 ease-in-out sm:w-14 sm:h-16"
          aria-label="Digit 4" oninput="this.value=this.value.replace(/[^0-9]/g,''); if(this.value.length===this.maxLength) this.nextElementSibling.focus();">
          <input type="text" maxlength="1" class="w-12 h-14 text-center text-2xl font-bold bg-gray-50 dark:bg-gray-700 text-gray-900 dark:text-gray-100 border border-gray-300 dark:border-gray-600 rounded-lg focus:ring-2 focus:ring-blue-500 focus:border-blue-500 outline-none transition-all duration-200 ease-in-out sm:w-14 sm:h-16"
          aria-label="Digit 5" oninput="this.value=this.value.replace(/[^0-9]/g,''); if(this.value.length===this.maxLength) this.nextElementSibling.focus();">
          <input type="text" maxlength="1" class="w-12 h-14 text-center text-2xl font-bold bg-gray-50 dark:bg-gray-700 text-gray-900 dark:text-gray-100 border border-gray-300 dark:border-gray-600 rounded-lg focus:ring-2 focus:ring-blue-500 focus:border-blue-500 outline-none transition-all duration-200 ease-in-out sm:w-14 sm:h-16"
          aria-label="Digit 6" oninput="this.value=this.value.replace(/[^0-9]/g,'');">
        </div>
        <button type="submit" class="w-full py-3 px-4 rounded-lg text-white font-semibold shadow-md
        bg-gradient-to-r from-purple-600 via-pink-500 to-red-500
        hover:from-purple-700 hover:via-pink-600 hover:to-red-600
        focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-red-500
        dark:focus:ring-offset-gray-900 transition-all duration-300 ease-in-out text-lg">
          Verify Code
        </button>
      </form>
      <div class="text-center">
        <a href="#" class="text-sm text-gray-500 dark:text-gray-400 hover:text-gray-700 dark:hover:text-gray-200 transition-colors duration-200">
          Having trouble? Try another method
        </a>
      </div>
    </div>
  </div>
</div>

관련 구성 요소

Two-Factor Authentication 구성 요소

생생하고 단순한 디자인의 2단계 인증 구성 요소입니다. 미묘한 버튼 애니메이션 및 입력 필드 전환과 같은 마이크로 상호 작용이 특징입니다. 다크 모드 지원으로 반응형. 포트폴리오를 위한 설계.

열다

Two-Factor Authentication 구성 요소

소셜 미디어 애플리케이션을 위한 복잡하고 반응형이 빠른 레트로 테마의 2단계 인증 구성 요소로, Tailwind CSS를 사용하는 다크 모드와 유사한 색 구성표를 사용합니다. 여러 대화형 요소를 포함하며 picsum.photos 및 randomuser.me 의 이미지를 사용합니다.

열다

Two-Factor Authentication 구성 요소

스큐어모픽 스타일로 설계된 Two-Factor Authentication Component로, 전자 상거래 애플리케이션에 적합하며 회색조 색 구성표와 복잡한 대화형 요소를 사용합니다. Tailwind CSS를 사용하여 반응형 디자인과 다크 모드 지원이 특징입니다.

열다