Skip to content
This repository has been archived by the owner on Jan 15, 2024. It is now read-only.

Commit

Permalink
feat: 🎸 微修正
Browse files Browse the repository at this point in the history
  • Loading branch information
nikukyugamer committed Jun 19, 2022
1 parent 51131ba commit cc937cb
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 15 deletions.
1 change: 1 addition & 0 deletions .env.production
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# .env.production
NEXT_PUBLIC_GOOGLE_TAG_MANAGER_ID=GTM-52G88WJ
BUGSNAG_API_KEY=
NEXT_PUBLIC_UNITE_ATTACKS_API_URL=https://headquarters.suikoden.info/unite_attacks
34 changes: 19 additions & 15 deletions components/vote-to-unite-attacks/Main.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -191,43 +191,47 @@ ${uniteAttackName}
<div className="pb-0 max-w-md">
{/* TODO: item の型をつける */}
<ul className="list text-left pl-6 pr-2 max-w-md">
{apiResponse.map((item: any) => (
<li key={item.id} className="pb-4">
{apiResponse.map((uniteAttack: any) => (
<li key={uniteAttack.id} className="pb-4">
<label
htmlFor={`${item.id}`}
htmlFor={`${uniteAttack.id}`}
className="checkbox-label"
>
<input
id={`${item.id}`}
id={`${uniteAttack.id}`}
data-theme="light"
key={item.id}
value={item.name}
checked={uniteAttackName === item.name}
key={uniteAttack.id}
value={uniteAttack.name}
checked={uniteAttackName === uniteAttack.name}
type="radio"
name="radio-4"
className="radio radio-accent mr-4 checked:bg-blue-500"
onChange={(e) => {
setUniteAttackName(e.target.value)
setUniteCharacterNames(item.characterNames)
setUniteCharacterNames(
uniteAttack.characterNames
)
}}
/>
</label>
<label htmlFor={`${item.id}`}>
<label htmlFor={`${uniteAttack.id}`}>
<span className="align-top">
{lang === 'ja' ? item.name : item.name_en}
{lang === 'ja'
? uniteAttack.name
: uniteAttack.name_en}
</span>
</label>
<br />
<span className="pl-10 text-xs">
{lang === 'ja'
? item.character_names
: item.character_names_en}
{/* TODO: 英語を用意したい */}
{uniteAttack.character_names}
</span>
{item.page_annotation && (
{uniteAttack.page_annotation && (
<>
<br />
<span className="pl-10 text-xs">
{item.page_annotation}
{/* TODO: 英語を用意したい */}
{uniteAttack.page_annotation}
</span>
</>
)}
Expand Down

0 comments on commit cc937cb

Please sign in to comment.