Compare commits
No commits in common. "17e8d52a67b4670c26969ea88c81b965db2a100c" and "4db63eb05ab56ac10bdbb4b4602f12d1ffb22e26" have entirely different histories.
17e8d52a67
...
4db63eb05a
102
build_4_apks.sh
102
build_4_apks.sh
|
|
@ -1,102 +0,0 @@
|
||||||
#!/bin/bash
|
|
||||||
# ============================================================================
|
|
||||||
# Ponshu Room - 4バリアント一括ビルドスクリプト
|
|
||||||
# consumer × {maita, eiji} + business × {maita, eiji}
|
|
||||||
# Pro版は不要のため含まない
|
|
||||||
# ============================================================================
|
|
||||||
|
|
||||||
set -e
|
|
||||||
|
|
||||||
TIMESTAMP=$(date +%Y-%m-%d_%H-%M-%S)
|
|
||||||
OUTPUT_DIR="build/apk_releases/$TIMESTAMP"
|
|
||||||
mkdir -p "$OUTPUT_DIR"
|
|
||||||
|
|
||||||
# APIキー (.env から読み込む)
|
|
||||||
SCRIPT_DIR="$(cd "$(dirname "$0")" && pwd)"
|
|
||||||
if [ -f "$SCRIPT_DIR/.env" ]; then
|
|
||||||
export $(grep -v '^#' "$SCRIPT_DIR/.env" | xargs)
|
|
||||||
fi
|
|
||||||
MAITA_KEY="${MAITA_API_KEY:?MAITA_API_KEY is not set in .env}"
|
|
||||||
EIJI_KEY="${EIJI_API_KEY:?EIJI_API_KEY is not set in .env}"
|
|
||||||
|
|
||||||
GRADLE_FILE="android/app/build.gradle.kts"
|
|
||||||
BACKUP_FILE="android/app/build.gradle.kts.backup"
|
|
||||||
cp "$GRADLE_FILE" "$BACKUP_FILE"
|
|
||||||
|
|
||||||
cleanup() {
|
|
||||||
if [ -f "$BACKUP_FILE" ]; then
|
|
||||||
cp "$BACKUP_FILE" "$GRADLE_FILE"
|
|
||||||
rm "$BACKUP_FILE"
|
|
||||||
echo "Restored build.gradle.kts"
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
trap cleanup EXIT
|
|
||||||
|
|
||||||
# applicationId を Lite に固定(バックアップから毎回復元して書き換え)
|
|
||||||
set_lite_app_id() {
|
|
||||||
cp "$BACKUP_FILE" "$GRADLE_FILE"
|
|
||||||
sed -i 's/applicationId = "com.posimai.ponshu_room"/applicationId = "com.posimai.ponshu_room_lite"/' "$GRADLE_FILE"
|
|
||||||
}
|
|
||||||
|
|
||||||
echo "============================================================================"
|
|
||||||
echo "Ponshu Room - 4 Variant APK Build"
|
|
||||||
echo "Output: $OUTPUT_DIR"
|
|
||||||
echo "============================================================================"
|
|
||||||
echo ""
|
|
||||||
|
|
||||||
# --- [1/4] Consumer / Maita ---
|
|
||||||
echo "[1/4] Building Consumer - Maita..."
|
|
||||||
set_lite_app_id
|
|
||||||
flutter build apk --release \
|
|
||||||
--dart-define=GEMINI_API_KEY=$MAITA_KEY \
|
|
||||||
--dart-define=IS_BUSINESS_APP=false \
|
|
||||||
--dart-define=IS_PRO_VERSION=false \
|
|
||||||
--dart-define=USE_PROXY=false
|
|
||||||
cp build/app/outputs/flutter-apk/app-release.apk "$OUTPUT_DIR/ponshu_room_consumer_maita.apk"
|
|
||||||
echo "Saved: ponshu_room_consumer_maita.apk"
|
|
||||||
echo ""
|
|
||||||
|
|
||||||
# --- [2/4] Consumer / Eiji ---
|
|
||||||
echo "[2/4] Building Consumer - Eiji..."
|
|
||||||
set_lite_app_id
|
|
||||||
flutter build apk --release \
|
|
||||||
--dart-define=GEMINI_API_KEY=$EIJI_KEY \
|
|
||||||
--dart-define=IS_BUSINESS_APP=false \
|
|
||||||
--dart-define=IS_PRO_VERSION=false \
|
|
||||||
--dart-define=USE_PROXY=false
|
|
||||||
cp build/app/outputs/flutter-apk/app-release.apk "$OUTPUT_DIR/ponshu_room_consumer_eiji.apk"
|
|
||||||
echo "Saved: ponshu_room_consumer_eiji.apk"
|
|
||||||
echo ""
|
|
||||||
|
|
||||||
# --- [3/4] Business / Maita ---
|
|
||||||
echo "[3/4] Building Business - Maita..."
|
|
||||||
set_lite_app_id
|
|
||||||
flutter build apk --release \
|
|
||||||
--dart-define=GEMINI_API_KEY=$MAITA_KEY \
|
|
||||||
--dart-define=IS_BUSINESS_APP=true \
|
|
||||||
--dart-define=IS_PRO_VERSION=false \
|
|
||||||
--dart-define=USE_PROXY=false
|
|
||||||
cp build/app/outputs/flutter-apk/app-release.apk "$OUTPUT_DIR/ponshu_room_business_maita.apk"
|
|
||||||
echo "Saved: ponshu_room_business_maita.apk"
|
|
||||||
echo ""
|
|
||||||
|
|
||||||
# --- [4/4] Business / Eiji ---
|
|
||||||
echo "[4/4] Building Business - Eiji..."
|
|
||||||
set_lite_app_id
|
|
||||||
flutter build apk --release \
|
|
||||||
--dart-define=GEMINI_API_KEY=$EIJI_KEY \
|
|
||||||
--dart-define=IS_BUSINESS_APP=true \
|
|
||||||
--dart-define=IS_PRO_VERSION=false \
|
|
||||||
--dart-define=USE_PROXY=false
|
|
||||||
cp build/app/outputs/flutter-apk/app-release.apk "$OUTPUT_DIR/ponshu_room_business_eiji.apk"
|
|
||||||
echo "Saved: ponshu_room_business_eiji.apk"
|
|
||||||
echo ""
|
|
||||||
|
|
||||||
echo "============================================================================"
|
|
||||||
echo "All 4 variants built successfully!"
|
|
||||||
echo "============================================================================"
|
|
||||||
ls -lh "$OUTPUT_DIR"
|
|
||||||
echo ""
|
|
||||||
echo "Consumer APKs: IS_BUSINESS_APP=false (ビジネスモードトグル非表示)"
|
|
||||||
echo "Business APKs: IS_BUSINESS_APP=true (デモ・ヒアリング用)"
|
|
||||||
echo "============================================================================"
|
|
||||||
|
|
@ -91,62 +91,43 @@ class _SommelierScreenState extends ConsumerState<SommelierScreen> {
|
||||||
userProfile.gender
|
userProfile.gender
|
||||||
);
|
);
|
||||||
|
|
||||||
return Stack(
|
return SingleChildScrollView(
|
||||||
children: [
|
|
||||||
// Ambient Glow — 右上の薄い光
|
|
||||||
Positioned(
|
|
||||||
top: -60,
|
|
||||||
right: -60,
|
|
||||||
child: IgnorePointer(
|
|
||||||
child: Container(
|
|
||||||
width: 280,
|
|
||||||
height: 280,
|
|
||||||
decoration: BoxDecoration(
|
|
||||||
shape: BoxShape.circle,
|
|
||||||
gradient: RadialGradient(
|
|
||||||
colors: [
|
|
||||||
Theme.of(context).extension<AppColors>()!.brandAccent.withValues(alpha: 0.07),
|
|
||||||
Colors.transparent,
|
|
||||||
],
|
|
||||||
),
|
|
||||||
),
|
|
||||||
),
|
|
||||||
),
|
|
||||||
),
|
|
||||||
SingleChildScrollView(
|
|
||||||
padding: const EdgeInsets.symmetric(horizontal: 24.0, vertical: 16.0),
|
padding: const EdgeInsets.symmetric(horizontal: 24.0, vertical: 16.0),
|
||||||
child: Column(
|
child: Column(
|
||||||
crossAxisAlignment: CrossAxisAlignment.start,
|
|
||||||
children: [
|
children: [
|
||||||
// テイストプロフィール
|
/* Greeting Removed */
|
||||||
_buildSectionHeader(context, 'テイストプロフィール', LucideIcons.activity),
|
// const SizedBox(height: 8),
|
||||||
const SizedBox(height: 8),
|
|
||||||
Screenshot(
|
Screenshot(
|
||||||
controller: _screenshotController,
|
controller: _screenshotController,
|
||||||
child: _buildShukoCard(context, baseProfile, personalizedTitle, userProfile.nickname),
|
child: _buildShukoCard(context, baseProfile, personalizedTitle, userProfile.nickname), // Pass nickname
|
||||||
),
|
),
|
||||||
const SizedBox(height: 16),
|
const SizedBox(height: 16), // Card下
|
||||||
_buildActionButtons(context),
|
_buildActionButtons(context),
|
||||||
const SizedBox(height: 32),
|
|
||||||
|
|
||||||
// MBTI風診断
|
const SizedBox(height: 8), // ボタン下(チラ見せ強化)
|
||||||
_buildSectionHeader(context, 'MBTI風診断', LucideIcons.brainCircuit),
|
const Divider(),
|
||||||
const SizedBox(height: 8),
|
const SizedBox(height: 16), // 区切り線下
|
||||||
_buildMBTIDiagnosisSection(context, userProfile, sakeList),
|
|
||||||
const SizedBox(height: 32),
|
// --- New: MBTI Diagnosis Section ---
|
||||||
|
_buildMBTIDiagnosisSection(context, userProfile, sakeList),
|
||||||
|
|
||||||
// さけのわ おすすめ
|
const SizedBox(height: 24),
|
||||||
_buildSectionHeader(context, 'さけのわ おすすめ', LucideIcons.trendingUp),
|
const Divider(),
|
||||||
const SizedBox(height: 8),
|
const SizedBox(height: 16),
|
||||||
const SakenowaNewRecommendationSection(displayCount: 5),
|
|
||||||
const SizedBox(height: 16),
|
// --- New: New Sake Recommendations Section ---
|
||||||
const SakenowaRankingSection(displayCount: 10),
|
const SakenowaNewRecommendationSection(displayCount: 5),
|
||||||
const SizedBox(height: 32),
|
|
||||||
|
const SizedBox(height: 24),
|
||||||
|
const Divider(),
|
||||||
|
const SizedBox(height: 16),
|
||||||
|
|
||||||
|
// --- New: Sakenowa Ranking Section ---
|
||||||
|
const SakenowaRankingSection(displayCount: 10),
|
||||||
|
const SizedBox(height: 32),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
), // SingleChildScrollView
|
);
|
||||||
], // Stack children
|
|
||||||
); // Stack
|
|
||||||
},
|
},
|
||||||
loading: () => const Center(child: CircularProgressIndicator()),
|
loading: () => const Center(child: CircularProgressIndicator()),
|
||||||
error: (err, stack) => ErrorRetryWidget(
|
error: (err, stack) => ErrorRetryWidget(
|
||||||
|
|
@ -158,23 +139,6 @@ class _SommelierScreenState extends ConsumerState<SommelierScreen> {
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
Widget _buildSectionHeader(BuildContext context, String title, IconData icon) {
|
|
||||||
final appColors = Theme.of(context).extension<AppColors>()!;
|
|
||||||
return Row(
|
|
||||||
children: [
|
|
||||||
Icon(icon, size: 20, color: appColors.iconDefault),
|
|
||||||
const SizedBox(width: 8),
|
|
||||||
Text(
|
|
||||||
title,
|
|
||||||
style: Theme.of(context).textTheme.titleMedium?.copyWith(
|
|
||||||
fontWeight: FontWeight.bold,
|
|
||||||
color: appColors.textPrimary,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
],
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
Widget _buildShukoCard(BuildContext context, ShukoProfile profile, ShukoTitle titleInfo, String? nickname) {
|
Widget _buildShukoCard(BuildContext context, ShukoProfile profile, ShukoTitle titleInfo, String? nickname) {
|
||||||
final appColors = Theme.of(context).extension<AppColors>()!;
|
final appColors = Theme.of(context).extension<AppColors>()!;
|
||||||
final isDark = Theme.of(context).brightness == Brightness.dark;
|
final isDark = Theme.of(context).brightness == Brightness.dark;
|
||||||
|
|
@ -329,24 +293,26 @@ class _SommelierScreenState extends ConsumerState<SommelierScreen> {
|
||||||
|
|
||||||
Widget _buildActionButtons(BuildContext context) {
|
Widget _buildActionButtons(BuildContext context) {
|
||||||
final appColors = Theme.of(context).extension<AppColors>()!;
|
final appColors = Theme.of(context).extension<AppColors>()!;
|
||||||
return SizedBox(
|
return Column(
|
||||||
width: double.infinity,
|
children: [
|
||||||
child: FilledButton.icon(
|
// SizedBox(width: double.infinity) removed to allow button to size itself
|
||||||
onPressed: _isSharing ? null : _shareCard,
|
FilledButton.icon(
|
||||||
icon: _isSharing
|
onPressed: _isSharing ? null : _shareCard,
|
||||||
? const SizedBox(width: 20, height: 20, child: CircularProgressIndicator(color: Colors.white, strokeWidth: 2))
|
icon: _isSharing
|
||||||
: const Icon(LucideIcons.share2),
|
? const SizedBox(width: 20, height: 20, child: CircularProgressIndicator(color: Colors.white, strokeWidth: 2))
|
||||||
label: const Text(
|
: const Icon(LucideIcons.share2),
|
||||||
'シェア',
|
label: const Text(
|
||||||
style: TextStyle(fontSize: 16, fontWeight: FontWeight.bold),
|
'シェア',
|
||||||
|
style: TextStyle(fontSize: 16, fontWeight: FontWeight.bold),
|
||||||
|
),
|
||||||
|
style: FilledButton.styleFrom(
|
||||||
|
padding: const EdgeInsets.symmetric(horizontal: 48, vertical: 16), // Wide padding for "Pill" look
|
||||||
|
backgroundColor: appColors.brandPrimary,
|
||||||
|
foregroundColor: appColors.surfaceSubtle,
|
||||||
|
shape: const StadiumBorder(),
|
||||||
|
),
|
||||||
),
|
),
|
||||||
style: FilledButton.styleFrom(
|
],
|
||||||
padding: const EdgeInsets.symmetric(vertical: 16),
|
|
||||||
backgroundColor: appColors.brandPrimary,
|
|
||||||
foregroundColor: appColors.surfaceSubtle,
|
|
||||||
shape: RoundedRectangleBorder(borderRadius: BorderRadius.circular(16)),
|
|
||||||
),
|
|
||||||
),
|
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -13,7 +13,6 @@ import '../widgets/gamification/badge_case.dart';
|
||||||
import '../widgets/gamification/activity_stats.dart';
|
import '../widgets/gamification/activity_stats.dart';
|
||||||
import '../theme/app_colors.dart';
|
import '../theme/app_colors.dart';
|
||||||
import '../services/mbti_types.dart'; // Needed for type title display
|
import '../services/mbti_types.dart'; // Needed for type title display
|
||||||
import '../main.dart' show isBusinessApp;
|
|
||||||
|
|
||||||
class SoulScreen extends ConsumerStatefulWidget {
|
class SoulScreen extends ConsumerStatefulWidget {
|
||||||
const SoulScreen({super.key});
|
const SoulScreen({super.key});
|
||||||
|
|
@ -34,45 +33,39 @@ class _SoulScreenState extends ConsumerState<SoulScreen> {
|
||||||
title: Text(t['myPage']),
|
title: Text(t['myPage']),
|
||||||
centerTitle: true,
|
centerTitle: true,
|
||||||
),
|
),
|
||||||
body: Stack(
|
body: ListView(
|
||||||
children: [
|
|
||||||
// Ambient Glow — 左上の薄い光
|
|
||||||
Positioned(
|
|
||||||
top: -80,
|
|
||||||
left: -60,
|
|
||||||
child: IgnorePointer(
|
|
||||||
child: Container(
|
|
||||||
width: 320,
|
|
||||||
height: 320,
|
|
||||||
decoration: BoxDecoration(
|
|
||||||
shape: BoxShape.circle,
|
|
||||||
gradient: RadialGradient(
|
|
||||||
colors: [
|
|
||||||
appColors.brandPrimary.withValues(alpha: 0.07),
|
|
||||||
Colors.transparent,
|
|
||||||
],
|
|
||||||
),
|
|
||||||
),
|
|
||||||
),
|
|
||||||
),
|
|
||||||
),
|
|
||||||
ListView(
|
|
||||||
padding: const EdgeInsets.all(16),
|
padding: const EdgeInsets.all(16),
|
||||||
children: [
|
children: [
|
||||||
|
|
||||||
// 成長記録セクションヘッダー
|
// Gamification Section (v1.3)
|
||||||
_buildSectionHeader(context, '成長記録', LucideIcons.activity, appColors),
|
|
||||||
|
|
||||||
// Gamification Section
|
|
||||||
const LevelTitleCard(),
|
const LevelTitleCard(),
|
||||||
const SizedBox(height: 12),
|
const SizedBox(height: 16),
|
||||||
const ActivityStats(),
|
const ActivityStats(),
|
||||||
const SizedBox(height: 12),
|
const SizedBox(height: 16),
|
||||||
const BadgeCase(),
|
const BadgeCase(),
|
||||||
const SizedBox(height: 24),
|
const SizedBox(height: 16),
|
||||||
|
|
||||||
// プロフィールセクションヘッダー
|
// Identity Section
|
||||||
_buildSectionHeader(context, t['profile'], LucideIcons.fingerprint, appColors),
|
Padding(
|
||||||
|
padding: const EdgeInsets.symmetric(vertical: 8, horizontal: 4),
|
||||||
|
child: Row(
|
||||||
|
children: [
|
||||||
|
Icon(
|
||||||
|
LucideIcons.fingerprint,
|
||||||
|
size: 20,
|
||||||
|
color: appColors.iconDefault,
|
||||||
|
),
|
||||||
|
const SizedBox(width: 8),
|
||||||
|
Text(
|
||||||
|
t['profile'],
|
||||||
|
style: Theme.of(context).textTheme.titleMedium?.copyWith(
|
||||||
|
fontWeight: FontWeight.bold,
|
||||||
|
color: appColors.textPrimary,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
Card(
|
Card(
|
||||||
color: appColors.surfaceSubtle,
|
color: appColors.surfaceSubtle,
|
||||||
child: Column(
|
child: Column(
|
||||||
|
|
@ -92,18 +85,9 @@ class _SoulScreenState extends ConsumerState<SoulScreen> {
|
||||||
trailing: Icon(LucideIcons.chevronRight, color: appColors.iconSubtle),
|
trailing: Icon(LucideIcons.chevronRight, color: appColors.iconSubtle),
|
||||||
onTap: () => _showGenderDialog(context, userProfile.gender, t),
|
onTap: () => _showGenderDialog(context, userProfile.gender, t),
|
||||||
),
|
),
|
||||||
],
|
|
||||||
),
|
Divider(height: 1, color: appColors.divider),
|
||||||
),
|
// 1. Real MBTI (User Input) - Core Value for Recommendation
|
||||||
const SizedBox(height: 24),
|
|
||||||
|
|
||||||
// あなたの日本酒キャラセクションヘッダー
|
|
||||||
_buildSectionHeader(context, 'あなたの日本酒キャラ', LucideIcons.sparkles, appColors),
|
|
||||||
Card(
|
|
||||||
color: appColors.surfaceSubtle,
|
|
||||||
child: Column(
|
|
||||||
children: [
|
|
||||||
// Real MBTI (User Input)
|
|
||||||
ListTile(
|
ListTile(
|
||||||
leading: Icon(LucideIcons.brainCircuit, color: appColors.iconDefault),
|
leading: Icon(LucideIcons.brainCircuit, color: appColors.iconDefault),
|
||||||
title: Text("あなたのMBTI", style: TextStyle(color: appColors.textPrimary)),
|
title: Text("あなたのMBTI", style: TextStyle(color: appColors.textPrimary)),
|
||||||
|
|
@ -112,7 +96,7 @@ class _SoulScreenState extends ConsumerState<SoulScreen> {
|
||||||
onTap: () => _showRealMbtiDialog(context, userProfile.mbti, t),
|
onTap: () => _showRealMbtiDialog(context, userProfile.mbti, t),
|
||||||
),
|
),
|
||||||
Divider(height: 1, color: appColors.divider),
|
Divider(height: 1, color: appColors.divider),
|
||||||
// Sake Persona (AI Diagnosis)
|
// 2. Sake Persona (AI Diagnosis) - Entertainment Value
|
||||||
ListTile(
|
ListTile(
|
||||||
leading: Icon(LucideIcons.sparkles, color: appColors.brandAccent),
|
leading: Icon(LucideIcons.sparkles, color: appColors.brandAccent),
|
||||||
title: Text(t['mbtiDiagnosis'], style: TextStyle(color: appColors.textPrimary)),
|
title: Text(t['mbtiDiagnosis'], style: TextStyle(color: appColors.textPrimary)),
|
||||||
|
|
@ -126,6 +110,7 @@ class _SoulScreenState extends ConsumerState<SoulScreen> {
|
||||||
),
|
),
|
||||||
trailing: Icon(LucideIcons.chevronRight, color: appColors.iconSubtle),
|
trailing: Icon(LucideIcons.chevronRight, color: appColors.iconSubtle),
|
||||||
onTap: () {
|
onTap: () {
|
||||||
|
// Navigate to Sommelier Tab (Index 2 in BottomNavBar)
|
||||||
ref.read(currentTabIndexProvider.notifier).setIndex(2);
|
ref.read(currentTabIndexProvider.notifier).setIndex(2);
|
||||||
},
|
},
|
||||||
),
|
),
|
||||||
|
|
@ -142,33 +127,11 @@ class _SoulScreenState extends ConsumerState<SoulScreen> {
|
||||||
// other Settings
|
// other Settings
|
||||||
OtherSettingsSection(
|
OtherSettingsSection(
|
||||||
title: t['otherSettings'],
|
title: t['otherSettings'],
|
||||||
showBusinessMode: isBusinessApp,
|
|
||||||
),
|
),
|
||||||
|
|
||||||
const SizedBox(height: 24),
|
const SizedBox(height: 24),
|
||||||
BackupSettingsSection(),
|
BackupSettingsSection(),
|
||||||
],
|
],
|
||||||
), // ListView
|
|
||||||
], // Stack children
|
|
||||||
), // Stack
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
Widget _buildSectionHeader(BuildContext context, String title, IconData icon, AppColors appColors) {
|
|
||||||
return Padding(
|
|
||||||
padding: const EdgeInsets.only(bottom: 8, left: 4, right: 4),
|
|
||||||
child: Row(
|
|
||||||
children: [
|
|
||||||
Icon(icon, size: 20, color: appColors.iconDefault),
|
|
||||||
const SizedBox(width: 8),
|
|
||||||
Text(
|
|
||||||
title,
|
|
||||||
style: Theme.of(context).textTheme.titleMedium?.copyWith(
|
|
||||||
fontWeight: FontWeight.bold,
|
|
||||||
color: appColors.textPrimary,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
],
|
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,43 +0,0 @@
|
||||||
import 'package:flutter/material.dart';
|
|
||||||
|
|
||||||
/// タップ時に軽く沈み込むスケールアニメーションを付与するラッパー。
|
|
||||||
/// 既存の GestureDetector / InkWell の代わりに使用する。
|
|
||||||
class Pressable extends StatefulWidget {
|
|
||||||
const Pressable({
|
|
||||||
super.key,
|
|
||||||
required this.child,
|
|
||||||
this.onTap,
|
|
||||||
this.scale = 0.97,
|
|
||||||
this.duration = const Duration(milliseconds: 100),
|
|
||||||
});
|
|
||||||
|
|
||||||
final Widget child;
|
|
||||||
final VoidCallback? onTap;
|
|
||||||
final double scale;
|
|
||||||
final Duration duration;
|
|
||||||
|
|
||||||
@override
|
|
||||||
State<Pressable> createState() => _PressableState();
|
|
||||||
}
|
|
||||||
|
|
||||||
class _PressableState extends State<Pressable> {
|
|
||||||
bool _pressed = false;
|
|
||||||
|
|
||||||
@override
|
|
||||||
Widget build(BuildContext context) {
|
|
||||||
return GestureDetector(
|
|
||||||
onTapDown: (_) => setState(() => _pressed = true),
|
|
||||||
onTapUp: (_) {
|
|
||||||
setState(() => _pressed = false);
|
|
||||||
widget.onTap?.call();
|
|
||||||
},
|
|
||||||
onTapCancel: () => setState(() => _pressed = false),
|
|
||||||
child: AnimatedScale(
|
|
||||||
scale: _pressed ? widget.scale : 1.0,
|
|
||||||
duration: widget.duration,
|
|
||||||
curve: Curves.easeOut,
|
|
||||||
child: widget.child,
|
|
||||||
),
|
|
||||||
);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -4,7 +4,6 @@ import 'package:flutter_riverpod/flutter_riverpod.dart';
|
||||||
import '../../providers/theme_provider.dart';
|
import '../../providers/theme_provider.dart';
|
||||||
import 'package:google_fonts/google_fonts.dart';
|
import 'package:google_fonts/google_fonts.dart';
|
||||||
import '../contextual_help_icon.dart';
|
import '../contextual_help_icon.dart';
|
||||||
import '../common/pressable.dart';
|
|
||||||
import '../../theme/app_colors.dart';
|
import '../../theme/app_colors.dart';
|
||||||
|
|
||||||
class LevelTitleCard extends ConsumerWidget {
|
class LevelTitleCard extends ConsumerWidget {
|
||||||
|
|
@ -21,8 +20,7 @@ class LevelTitleCard extends ConsumerWidget {
|
||||||
final progress = userProfile.nextLevelProgress;
|
final progress = userProfile.nextLevelProgress;
|
||||||
final expToNext = userProfile.expToNextLevel;
|
final expToNext = userProfile.expToNextLevel;
|
||||||
|
|
||||||
return Pressable(
|
return Container(
|
||||||
child: Container(
|
|
||||||
width: double.infinity,
|
width: double.infinity,
|
||||||
padding: const EdgeInsets.all(20),
|
padding: const EdgeInsets.all(20),
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
|
|
@ -42,13 +40,6 @@ class LevelTitleCard extends ConsumerWidget {
|
||||||
child: Column(
|
child: Column(
|
||||||
crossAxisAlignment: CrossAxisAlignment.start,
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
children: [
|
children: [
|
||||||
if (userProfile.nickname != null && userProfile.nickname!.isNotEmpty) ...[
|
|
||||||
Text(
|
|
||||||
userProfile.nickname!,
|
|
||||||
style: TextStyle(fontSize: 13, color: appColors.textSecondary, letterSpacing: 0.3),
|
|
||||||
),
|
|
||||||
const SizedBox(height: 6),
|
|
||||||
],
|
|
||||||
Row(
|
Row(
|
||||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||||
children: [
|
children: [
|
||||||
|
|
@ -60,10 +51,8 @@ class LevelTitleCard extends ConsumerWidget {
|
||||||
children: [
|
children: [
|
||||||
Text(
|
Text(
|
||||||
'現在の称号',
|
'現在の称号',
|
||||||
style: Theme.of(context).textTheme.bodySmall?.copyWith(
|
style: Theme.of(context).textTheme.titleSmall?.copyWith(
|
||||||
fontWeight: FontWeight.w500,
|
fontWeight: FontWeight.bold,
|
||||||
color: appColors.textSecondary,
|
|
||||||
letterSpacing: 0.5,
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
const SizedBox(width: 4),
|
const SizedBox(width: 4),
|
||||||
|
|
@ -81,10 +70,9 @@ class LevelTitleCard extends ConsumerWidget {
|
||||||
child: Text(
|
child: Text(
|
||||||
title,
|
title,
|
||||||
style: GoogleFonts.zenOldMincho(
|
style: GoogleFonts.zenOldMincho(
|
||||||
fontSize: 36,
|
fontSize: 28,
|
||||||
fontWeight: FontWeight.bold,
|
fontWeight: FontWeight.bold,
|
||||||
color: appColors.brandPrimary,
|
color: appColors.brandPrimary,
|
||||||
height: 1.1,
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|
@ -147,10 +135,9 @@ class LevelTitleCard extends ConsumerWidget {
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
), // Container
|
);
|
||||||
); // Pressable
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static Widget _buildLevelHelpContent(BuildContext context) {
|
static Widget _buildLevelHelpContent(BuildContext context) {
|
||||||
return Column(
|
return Column(
|
||||||
crossAxisAlignment: CrossAxisAlignment.start,
|
crossAxisAlignment: CrossAxisAlignment.start,
|
||||||
|
|
|
||||||
|
|
@ -16,7 +16,7 @@ publish_to: 'none' # Remove this line if you wish to publish to pub.dev
|
||||||
# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
|
# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
|
||||||
# In Windows, build-name is used as the major, minor, and patch parts
|
# In Windows, build-name is used as the major, minor, and patch parts
|
||||||
# of the product and file versions while build-number is used as the build suffix.
|
# of the product and file versions while build-number is used as the build suffix.
|
||||||
version: 1.0.19+30
|
version: 1.0.18+29
|
||||||
|
|
||||||
environment:
|
environment:
|
||||||
sdk: ^3.10.1
|
sdk: ^3.10.1
|
||||||
|
|
|
||||||
|
|
@ -1,21 +1,21 @@
|
||||||
{
|
{
|
||||||
"date": "2026-04-05",
|
"date": "2026-04-05",
|
||||||
"name": "Ponshu Room 1.0.19 (2026-04-05)",
|
"name": "Ponshu Room 1.0.18 (2026-04-05)",
|
||||||
"version": "v1.0.19",
|
"version": "v1.0.18",
|
||||||
"apks": {
|
"apks": {
|
||||||
"eiji": {
|
"eiji": {
|
||||||
"lite": {
|
"lite": {
|
||||||
"url": "https://posimai-lab.tail72e846.ts.net/mai/ponshu-room-lite/releases/download/v1.0.19/ponshu_room_consumer_eiji.apk",
|
"url": "https://posimai-lab.tail72e846.ts.net/mai/ponshu-room-lite/releases/download/v1.0.18/ponshu_room_consumer_eiji.apk",
|
||||||
"size_mb": 89,
|
"size_mb": 89,
|
||||||
"filename": "ponshu_room_consumer_eiji.apk"
|
"filename": "ponshu_room_consumer_eiji.apk"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"maita": {
|
"maita": {
|
||||||
"lite": {
|
"lite": {
|
||||||
"url": "https://posimai-lab.tail72e846.ts.net/mai/ponshu-room-lite/releases/download/v1.0.19/ponshu_room_consumer_maita.apk",
|
"url": "https://posimai-lab.tail72e846.ts.net/mai/ponshu-room-lite/releases/download/v1.0.18/ponshu_room_consumer_maita.apk",
|
||||||
"size_mb": 89,
|
"size_mb": 89,
|
||||||
"filename": "ponshu_room_consumer_maita.apk"
|
"filename": "ponshu_room_consumer_maita.apk"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Loading…
Reference in New Issue