Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ログイン/サインイン・ログアウト画面の実装 #10

Merged
merged 2 commits into from
Apr 12, 2023

Conversation

kohei-sa
Copy link
Owner

説明

  • 以下の2画面を作成

    • ログイン/サインイン
    • ログアウト
  • ログイン時動作不良を確認したため、route_auth.pyschemas.pyを修正

    • orm_modeをBaseで適応することで、sql_schema型で返ってくるオブジェクトでも処理を通過するように修正
    • validate_csrfのタイポを修正

確認したこと

  • 新規アカウント作成し、ログアウトができることを確認
  • 作成したアカウントでログインができることを確認
  • 各画面のボタンが正常に動作することを確認

@kohei-sa kohei-sa added the enhancement New feature or request label Apr 11, 2023
@kohei-sa kohei-sa linked an issue Apr 12, 2023 that may be closed by this pull request
Copy link
Collaborator

@ShimamuraMiu ShimamuraMiu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

疑問点をコメントしたので、ご回答お願いします。

@@ -1 +1,2 @@
/// <reference types="react-scripts" />
declare module '@heroicons/*';
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

この行について、調査したのですがどのような意味を持つ追加であるのか理解できませんでした。

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

React v6だと、Udemyに記載されている書き方だと該当のiconを使えなかったのでその対応として書きましたが、結果不必要だったためその消し忘れです。
エラーの原因は、iconの名称が変わっているだけだったので、正しい名称のicon名を提供元から探してimportするicon名を変えています。以下が該当行です。

import { CheckBadgeIcon } from "@heroicons/react/24/solid";
import { ArrowPathIcon } from "@heroicons/react/24/solid";

heroicons
参考

ちなみに、react-app-env.d.tsはsvgやjpegなどを読み込めるようにするためのファイルらしいですよ
react-app-env.d.tsについて

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ご丁寧にありがとうございます。
承知しました。

FARM Stack web app
</span>
</div>
<h2 className="my-6">{isLogin ? 'Login' : 'Create a new account'}</h2>
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

”と'が混在しています。

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

クラスタグはダブルクォート、文中で使う文字はシングルクォートで使用しているため、すみわけができているので問題ないという認識です

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

承知しました。問題ないです。

@ShimamuraMiu
Copy link
Collaborator

ユーザー登録時に以下のwarningが出ましたが、問題ないでしょうか。
動作上は問題ありませんでした(登録自体は出来ていました)。
Form submission canceled because the form is not connected

@kohei-sa kohei-sa removed a link to an issue Apr 12, 2023
@ShimamuraMiu ShimamuraMiu merged commit 2800fe8 into main Apr 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants