Skip to content

Commit

Permalink
Merge branch 'main' into feature/session
Browse files Browse the repository at this point in the history
# Conflicts:
#	lib/features/header/ui/header_widget.dart
  • Loading branch information
blendthink committed Oct 10, 2023
2 parents fb84d73 + cddc800 commit 061ad6d
Show file tree
Hide file tree
Showing 7 changed files with 168 additions and 13 deletions.
16 changes: 16 additions & 0 deletions lib/app/home_page.dart
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import 'package:confwebsite2023/app/router/router.dart';
import 'package:confwebsite2023/core/components/responsive_widget.dart';
import 'package:confwebsite2023/core/theme.dart';
import 'package:confwebsite2023/features/access/ui/access_widget.dart';
import 'package:confwebsite2023/features/announcement/ui/announcement_section.dart';
import 'package:confwebsite2023/features/count_down/model/count_down_timer.dart';
import 'package:confwebsite2023/features/count_down/ui/count_down_section.dart';
import 'package:confwebsite2023/features/event/hands-on/ui/hands_on_event.dart';
Expand Down Expand Up @@ -33,6 +34,7 @@ class MainPage extends HookWidget {
event: GlobalObjectKey('eventSectionKey'),
ticket: GlobalObjectKey('ticketSectionKey'),
session: GlobalObjectKey('sessionSectionKey'),
announcement: GlobalObjectKey('announcementSectionKey'),
sponsor: GlobalObjectKey('sponsorSectionKey'),
staff: GlobalObjectKey('staffSectionKey'),
);
Expand Down Expand Up @@ -64,6 +66,10 @@ class MainPage extends HookWidget {
title: 'Event',
onPressed: () async => scrollToSection(sectionKeys.event),
),
HeaderItemButtonData(
title: 'Announcement',
onPressed: () async => scrollToSection(sectionKeys.announcement),
),
HeaderItemButtonData(
title: 'Sponsor',
onPressed: () async => scrollToSection(sectionKeys.sponsor),
Expand Down Expand Up @@ -112,6 +118,7 @@ class _MainPageBody extends StatelessWidget {
GlobalObjectKey event,
GlobalObjectKey ticket,
GlobalObjectKey session,
GlobalObjectKey announcement,
GlobalObjectKey sponsor,
GlobalObjectKey staff
}) sectionKeys;
Expand Down Expand Up @@ -211,6 +218,15 @@ class _MainPageBody extends StatelessWidget {
const SliverToBoxAdapter(
child: Spaces.vertical_200,
),
_Sliver(
padding: padding,
child: AnnouncementSection(
key: sectionKeys.announcement,
),
),
const SliverToBoxAdapter(
child: Spaces.vertical_200,
),
_Sliver(
padding: padding,
child: SponsorsSection(
Expand Down
17 changes: 17 additions & 0 deletions lib/core/components/list_bullet.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
import 'package:confwebsite2023/core/theme.dart';
import 'package:flutter/material.dart';

/// [ListBullet] is a primary color circle mark.
final class ListBullet extends StatelessWidget {
const ListBullet({super.key});

@override
Widget build(BuildContext context) => Container(
width: 8,
height: 8,
decoration: BoxDecoration(
color: baselineColorScheme.ref.primary.primary40,
shape: BoxShape.circle,
),
);
}
97 changes: 97 additions & 0 deletions lib/features/announcement/ui/announcement_section.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,97 @@
import 'package:confwebsite2023/core/components/list_bullet.dart';
import 'package:confwebsite2023/core/components/responsive_widget.dart';
import 'package:confwebsite2023/core/theme.dart';
import 'package:confwebsite2023/features/announcement/ui/announcement_section_header.dart';
import 'package:flutter/material.dart';

/// アナウンスセクション
final class AnnouncementSection extends StatelessWidget {
const AnnouncementSection({super.key});

@override
Widget build(BuildContext context) => const ResponsiveWidget(
largeWidget: _AnnouncementSectionContent(
verticalGap: Spaces.vertical_40,
),
smallWidget: _AnnouncementSectionContent(
verticalGap: Spaces.vertical_24,
),
);
}

/// アナウンスセクションのコンテンツ
final class _AnnouncementSectionContent extends StatelessWidget {
const _AnnouncementSectionContent({required this.verticalGap});

final SizedBox verticalGap;

@override
Widget build(BuildContext context) => Column(
children: [
const AnnouncementSectionHeader(),
verticalGap,
const _AnnouncementList(),
],
);
}

/// アナウンスのアイテム一覧
final class _AnnouncementList extends StatelessWidget {
const _AnnouncementList();

static const _verticalGap = Spaces.vertical_16;

@override
Widget build(BuildContext context) => const Column(
children: [
_AnnouncementItem('会場は禁煙です。喫煙所はありません。'),
_verticalGap,
_AnnouncementItem('クローク/ロッカーなどの用意はございません。手荷物は各自の責任により管理してください。'),
_verticalGap,
_AnnouncementItem('会場内で発生したゴミのお持ち帰りにご協力ください。会場内ではゴミの分別にご協力ください。'),
_verticalGap,
_AnnouncementItem('駐車場の用意はございません。公共交通機関(電車・バスなど)をご利用ください。'),
_verticalGap,
_AnnouncementItem('会場内におけるトラブル、事故やケガ、盗難、紛失等につきましては、会場は一切の責任を負いかねます。'),
_verticalGap,
_AnnouncementItem(
'イベントの模様は撮影される場合がございます。その場合、お客様が写り込む場合もございますので、予めご了承ください。',
),
],
);
}

/// アナウンスのアイテム
final class _AnnouncementItem extends StatelessWidget {
const _AnnouncementItem(this.text);

final String text;

@override
Widget build(BuildContext context) {
final theme = Theme.of(context);

return Padding(
padding: const EdgeInsets.all(8),
child: Row(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
const Padding(
padding: EdgeInsets.symmetric(vertical: 8),
child: ListBullet(),
),
Spaces.horizontal_16,
// text
Expanded(
child: Text(
text,
style: theme.textTheme.bodyLarge!.copyWith(
color: baselineColorScheme.ref.secondary.secondary100,
),
),
),
],
),
);
}
}
28 changes: 28 additions & 0 deletions lib/features/announcement/ui/announcement_section_header.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
import 'package:confwebsite2023/core/components/responsive_widget.dart';
import 'package:confwebsite2023/core/components/section_header.dart';
import 'package:confwebsite2023/core/theme.dart';
import 'package:flutter/material.dart';

/// アナウンスセクションのヘッダー
final class AnnouncementSectionHeader extends StatelessWidget {
const AnnouncementSectionHeader({super.key});

static const _title = 'Announcement';

@override
Widget build(BuildContext context) {
final gradient = GradientConstant.accent.primary;
return ResponsiveWidget(
largeWidget: SectionHeader.leftAlignment(
text: _title,
style: AppTextStyle.pcHeading1,
gradient: gradient,
),
smallWidget: SectionHeader.leftAlignment(
text: _title,
style: AppTextStyle.spHeading1,
gradient: gradient,
),
);
}
}
8 changes: 4 additions & 4 deletions lib/features/header/ui/header_widget.dart
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ class HeaderBar extends HookWidget implements PreferredSizeWidget {
child: logo,
);

final mobileBar = Row(
final mediumBar = Row(
children: [
const Column(),
titleWidget(
Expand Down Expand Up @@ -65,7 +65,7 @@ class HeaderBar extends HookWidget implements PreferredSizeWidget {
],
);

final desktopBar = Center(
final largeBar = Center(
child: Row(
mainAxisSize: MainAxisSize.min,
children: [
Expand Down Expand Up @@ -108,8 +108,8 @@ class HeaderBar extends HookWidget implements PreferredSizeWidget {
child: Padding(
padding: const EdgeInsets.all(10),
child: ResponsiveWidget(
largeWidget: desktopBar,
mediumWidget: mobileBar,
largeWidget: largeBar,
mediumWidget: mediumBar,
),
),
),
Expand Down
10 changes: 2 additions & 8 deletions lib/features/news/ui/news_section.dart
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import 'package:confwebsite2023/core/components/list_bullet.dart';
import 'package:confwebsite2023/core/theme.dart';
import 'package:confwebsite2023/features/news/data/news.dart';
import 'package:confwebsite2023/features/news/data/news_provider.dart';
Expand Down Expand Up @@ -44,14 +45,7 @@ class _NewsItem extends StatelessWidget {
),
// 紫丸ポチ
Spaces.horizontal_16,
Container(
width: 8,
height: 8,
decoration: BoxDecoration(
color: baselineColorScheme.ref.primary.primary40,
shape: BoxShape.circle,
),
),
const ListBullet(),
Spaces.horizontal_16,
// text
Expanded(
Expand Down
5 changes: 4 additions & 1 deletion lib/features/sponsor/data/sponsor_data_source.dart
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,9 @@ List<Sponsor> _goldSponsors(_GoldSponsorsRef ref) => [
logoAssetName: Assets.sponsors.flutter,
plan: SponsorPlan.gold,
session: null,
introduction: '''
Flutter is an open source framework by Google for building beautiful, natively compiled, multi-platform applications. Transform your app development process to launch faster with less resources by building, testing, and deploying from a single codebase.
''',
),
Sponsor(
name: 'magicpod',
Expand Down Expand Up @@ -282,7 +285,7 @@ https://www.wantedly.com/projects/1315544
plan: SponsorPlan.silver,
session: null,
introduction: '''
リクルートグループについて 1960年の創業以来、リクルートグループは、就職・結婚・進学・住宅・自動車・旅行・飲食・美容などの領域において、一 人ひとりのライフスタイルに応じたより最適な選択肢を提供してきました。現在、HRテクノロジー、マッチング&ソ リューション、人材派遣の3事業を軸に、60を超える国・地域で事業を展開しています。リクルートグループは、新しい価 値の創造を通じ、社会からの期待に応え、一人ひとりが輝く豊かな世界の実現に向けて、より多くの『まだ、ここにない、 出会い。』を提供していきます。
リクルートグループについて 1960年の創業以来、リクルートグループは、就職・結婚・進学・住宅・自動車・旅行・飲食・美容などの領域において、一 人ひとりのライフスタイルに応じたより最適な選択肢を提供してきました。現在、HRテクノロジー、マッチング&ソリューション、人材派遣の3事業を軸に、60を超える国・地域で事業を展開しています。リクルートグループは、新しい価 値の創造を通じ、社会からの期待に応え、一人ひとりが輝く豊かな世界の実現に向けて、より多くの『まだ、ここにない、 出会い。』を提供していきます。
''',
),
Sponsor(
Expand Down

0 comments on commit 061ad6d

Please sign in to comment.