From 8c59441b06da5a37f44d41e8a2877277b930f441 Mon Sep 17 00:00:00 2001 From: OdenTakashi Date: Sat, 11 Nov 2023 11:24:11 +0900 Subject: [PATCH 1/7] =?UTF-8?q?=E9=96=8B=E5=82=AC=E4=B8=AD=E3=83=A9?= =?UTF-8?q?=E3=83=99=E3=83=AB=E3=81=AE=E8=89=B2=E3=82=92=E7=9B=AE=E7=AB=8B?= =?UTF-8?q?=E3=81=A4=E3=82=88=E3=81=86=E3=81=AB=E4=BF=AE=E6=AD=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/lotteries/index.html.slim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/views/lotteries/index.html.slim b/app/views/lotteries/index.html.slim index aa4ab6a..6da091a 100644 --- a/app/views/lotteries/index.html.slim +++ b/app/views/lotteries/index.html.slim @@ -25,7 +25,7 @@ .bg-gray-500.rounded-full.text-xs.h-4 | 終了 - else - .bg-blue-900.rounded-full.text-xs.h-4 + .bg-red-800.rounded-full.text-xs.h-4 | 開催中 .text-left.w-full.p-1 .text-zinc-500 From 3666f6e03e53bcf20eb14022390e5753159e94dd Mon Sep 17 00:00:00 2001 From: OdenTakashi Date: Sat, 11 Nov 2023 11:35:45 +0900 Subject: [PATCH 2/7] =?UTF-8?q?=E5=BD=93=E9=81=B8=E8=80=85=E6=95=B0?= =?UTF-8?q?=E3=81=AE=E8=A1=A8=E7=A4=BA=E3=82=92=E4=BF=AE=E6=AD=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 当選者数: N人 -> 当選者数(N) --- app/views/lotteries/_lottery.html.slim | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/app/views/lotteries/_lottery.html.slim b/app/views/lotteries/_lottery.html.slim index d0cbba0..8c3789a 100644 --- a/app/views/lotteries/_lottery.html.slim +++ b/app/views/lotteries/_lottery.html.slim @@ -28,11 +28,9 @@ div .font-bold.text-lg = prize.name - .flex.mt-3 + .mt-3 label.w-1/2.md:w-1/3 - = "#{Prize.human_attribute_name(:winners_count)}:" - .w-1/2.md:w-2/3 - = prize.winners_count + = "#{Prize.human_attribute_name(:winners_count)}(#{prize.winners_count})" .flex.mt-3 label.w-1/2.md:w-1/3 = "#{Prize.human_attribute_name(:winning_email_subject)}:" From af1b6a76d9d45c5a0f88116bf0d7e6310ce4d419 Mon Sep 17 00:00:00 2001 From: OdenTakashi Date: Sat, 11 Nov 2023 11:49:40 +0900 Subject: [PATCH 3/7] =?UTF-8?q?=E6=96=87=E5=AD=97=E3=82=B5=E3=82=A4?= =?UTF-8?q?=E3=82=BA=E3=82=92=E8=AA=BF=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/lotteries/_lottery.html.slim | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/app/views/lotteries/_lottery.html.slim b/app/views/lotteries/_lottery.html.slim index 8c3789a..a98ca64 100644 --- a/app/views/lotteries/_lottery.html.slim +++ b/app/views/lotteries/_lottery.html.slim @@ -24,22 +24,22 @@ .font-semibold.text-lg | 抽選会賞品 - lottery.prizes.each do |prize| - .border.border-gray.rounded.mt-3.p-6.text-zinc-800.text-sm.md:text-base + .border.border-gray.rounded.mt-3.p-6.text-zinc-800 div .font-bold.text-lg = prize.name .mt-3 - label.w-1/2.md:w-1/3 + label.text-sm.w-1/2.md:w-1/3 = "#{Prize.human_attribute_name(:winners_count)}(#{prize.winners_count})" - .flex.mt-3 - label.w-1/2.md:w-1/3 - = "#{Prize.human_attribute_name(:winning_email_subject)}:" - .w-1/2.md:w-2/3 + .mt-3 + label.w-1/2.text-sm.border-b.border-dashed.border-gray-500.md:w-1/3 + = "#{Prize.human_attribute_name(:winning_email_subject)}" + .font-bold.mt-3.w-1/2.md:w-2/3 = prize.winning_email_subject - .flex.mt-3 - label.w-1/2.md:w-1/3 - = "#{Prize.human_attribute_name(:winning_email_body)}:" - .break-all.w-1/2.md:w-2/3 + .mt-3 + label.text-sm.w-1/2.md:w-1/3 + = "#{Prize.human_attribute_name(:winning_email_body)}" + .mt-3.break-all.w-1/2.md:w-2/3 = simple_format(h(prize.winning_email_body)) - if lottery_executed?(lottery) && closed?(lottery) From 04fbcd1d9d75400ed13949920fc6dc097c921095 Mon Sep 17 00:00:00 2001 From: OdenTakashi Date: Sat, 11 Nov 2023 11:51:09 +0900 Subject: [PATCH 4/7] =?UTF-8?q?width=E3=81=AE=E6=8C=87=E5=AE=9A=E3=82=92?= =?UTF-8?q?=E5=A4=89=E6=9B=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/lotteries/_lottery.html.slim | 10 +++++----- app/views/lotteries/show.html.slim | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/app/views/lotteries/_lottery.html.slim b/app/views/lotteries/_lottery.html.slim index a98ca64..5e89bf8 100644 --- a/app/views/lotteries/_lottery.html.slim +++ b/app/views/lotteries/_lottery.html.slim @@ -29,17 +29,17 @@ .font-bold.text-lg = prize.name .mt-3 - label.text-sm.w-1/2.md:w-1/3 + label.text-sm = "#{Prize.human_attribute_name(:winners_count)}(#{prize.winners_count})" .mt-3 - label.w-1/2.text-sm.border-b.border-dashed.border-gray-500.md:w-1/3 + label.text-sm.border-b.border-dashed.border-gray-500 = "#{Prize.human_attribute_name(:winning_email_subject)}" - .font-bold.mt-3.w-1/2.md:w-2/3 + .font-bold.mt-3. = prize.winning_email_subject .mt-3 - label.text-sm.w-1/2.md:w-1/3 + label.text-sm = "#{Prize.human_attribute_name(:winning_email_body)}" - .mt-3.break-all.w-1/2.md:w-2/3 + .mt-3.break-all = simple_format(h(prize.winning_email_body)) - if lottery_executed?(lottery) && closed?(lottery) diff --git a/app/views/lotteries/show.html.slim b/app/views/lotteries/show.html.slim index e0718eb..cba8ee8 100644 --- a/app/views/lotteries/show.html.slim +++ b/app/views/lotteries/show.html.slim @@ -1,6 +1,6 @@ - set_meta_tags(title: '抽選会詳細') -.p-2.m-auto.w-full.md:w-7/12 +.p-2.m-auto.w-full.md:w-5/12 h1.mt-6.font-semibold.text-2xl.text-center.text-zinc-800 = @lottery.name - unless closed?(@lottery) From 4237b04a8a89ed26f0802c3d6928deea60f7f1c6 Mon Sep 17 00:00:00 2001 From: OdenTakashi Date: Sat, 11 Nov 2023 12:03:29 +0900 Subject: [PATCH 5/7] bin/lint --- app/views/lotteries/_lottery.html.slim | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/views/lotteries/_lottery.html.slim b/app/views/lotteries/_lottery.html.slim index 5e89bf8..3928e08 100644 --- a/app/views/lotteries/_lottery.html.slim +++ b/app/views/lotteries/_lottery.html.slim @@ -33,12 +33,12 @@ = "#{Prize.human_attribute_name(:winners_count)}(#{prize.winners_count})" .mt-3 label.text-sm.border-b.border-dashed.border-gray-500 - = "#{Prize.human_attribute_name(:winning_email_subject)}" + = Prize.human_attribute_name(:winning_email_subject) .font-bold.mt-3. = prize.winning_email_subject .mt-3 label.text-sm - = "#{Prize.human_attribute_name(:winning_email_body)}" + = Prize.human_attribute_name(:winning_email_body) .mt-3.break-all = simple_format(h(prize.winning_email_body)) From 1c6dbde98a3b22521f046e2970e29093bd67e26d Mon Sep 17 00:00:00 2001 From: OdenTakashi Date: Sat, 11 Nov 2023 12:08:01 +0900 Subject: [PATCH 6/7] =?UTF-8?q?=E3=83=A9=E3=83=99=E3=83=AB=E3=81=A8?= =?UTF-8?q?=E6=9C=AC=E6=96=87=E3=81=AEmargin=E3=82=92=E8=AA=BF=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/lotteries/_lottery.html.slim | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/views/lotteries/_lottery.html.slim b/app/views/lotteries/_lottery.html.slim index 3928e08..f1280e2 100644 --- a/app/views/lotteries/_lottery.html.slim +++ b/app/views/lotteries/_lottery.html.slim @@ -34,12 +34,12 @@ .mt-3 label.text-sm.border-b.border-dashed.border-gray-500 = Prize.human_attribute_name(:winning_email_subject) - .font-bold.mt-3. + .font-semibold.mt-1 = prize.winning_email_subject .mt-3 - label.text-sm + label.text-sm.border-b.border-dashed.border-gray-500 = Prize.human_attribute_name(:winning_email_body) - .mt-3.break-all + .font-semibold.mt-1.break-all = simple_format(h(prize.winning_email_body)) - if lottery_executed?(lottery) && closed?(lottery) From b1efd1eb240a3129f5ee60e029b372927eb355c6 Mon Sep 17 00:00:00 2001 From: OdenTakashi Date: Sat, 11 Nov 2023 12:24:13 +0900 Subject: [PATCH 7/7] =?UTF-8?q?=E5=BD=93=E9=81=B8=E8=80=85=E3=81=AE?= =?UTF-8?q?=E8=A1=A8=E7=A4=BA=E3=82=92=E8=B3=9E=E5=93=81=E6=83=85=E5=A0=B1?= =?UTF-8?q?=E3=81=AE=E8=A1=A8=E7=A4=BA=E3=81=AB=E6=8F=83=E3=81=88=E3=81=9F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/views/lotteries/_lottery.html.slim | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/app/views/lotteries/_lottery.html.slim b/app/views/lotteries/_lottery.html.slim index f1280e2..f56ab0b 100644 --- a/app/views/lotteries/_lottery.html.slim +++ b/app/views/lotteries/_lottery.html.slim @@ -43,22 +43,22 @@ = simple_format(h(prize.winning_email_body)) - if lottery_executed?(lottery) && closed?(lottery) - .mt-3 - .font-bold + .mt-6 + .font-semibold = "当選者一覧(#{prize.entries.size})" - prize.entries.each do |winner| - .flex.mt-3 - label.w-1/2.md:w-1/3 - = "#{Entry.human_attribute_name(:email)}:" - .break-all.w-1/2.md:w-2/3 + .mt-3 + label.text-xs + = Entry.human_attribute_name(:email) + .break-all = winner.email - if lottery.name_field_enabled - label.w-1/2.md:w-1/3 - = "#{Entry.human_attribute_name(:email)}:" - .break-all.w-1/2.md:w-2/3 - = winner.email + label.text-xs + = Entry.human_attribute_name(:name) + .break-all + = winner.name - if lottery.name_field_enabled - label.w-1/2.md:w-1/3 - = "#{Entry.human_attribute_name(:note)}:" - .break-all.w-1/2.md:w-2/3 + label.text-xs + = Entry.human_attribute_name(:note) + .break-all = winner.note