fixed errors and removed dependency on flutterflowtheme. next working on getting it running.
This commit is contained in:
@@ -6,7 +6,7 @@ import 'package:flutter/material.dart';
|
||||
import 'package:google_fonts/google_fonts.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
|
||||
import '/theme.dart';
|
||||
import 'package:app/theme.dart';
|
||||
|
||||
import 'conversation_model.dart';
|
||||
export 'conversation_model.dart';
|
||||
@@ -44,37 +44,39 @@ class _ConversationWidgetState extends State<ConversationWidget> {
|
||||
: FocusScope.of(context).unfocus(),
|
||||
child: Scaffold(
|
||||
key: scaffoldKey,
|
||||
backgroundColor: myAppTheme.of(context).secondaryBackground,
|
||||
backgroundColor: AppTheme.secondaryBackground,
|
||||
appBar: AppBar(
|
||||
backgroundColor: myAppTheme.of(context).primaryBackground,
|
||||
backgroundColor: AppTheme.primaryBackground,
|
||||
automaticallyImplyLeading: false,
|
||||
leading: FlutterFlowIconButton(
|
||||
borderColor: Colors.transparent,
|
||||
borderRadius: 30,
|
||||
borderWidth: 1,
|
||||
buttonSize: 60,
|
||||
icon: Icon(
|
||||
icon: const Icon(
|
||||
Icons.arrow_back_rounded,
|
||||
color: AppTheme.primaryText,
|
||||
color: AppTheme.primaryTextColor,
|
||||
size: 30,
|
||||
),
|
||||
onPressed: () async {
|
||||
context.goNamed(
|
||||
'ConversationsList',
|
||||
extra: <String, dynamic>{
|
||||
kTransitionInfoKey: TransitionInfo(
|
||||
hasTransition: true,
|
||||
transitionType: PageTransitionType.leftToRight,
|
||||
duration: const Duration(milliseconds: 250),
|
||||
),
|
||||
},
|
||||
);
|
||||
print("something pressed in conversation_widget.dart");
|
||||
// TODO
|
||||
// context.goNamed(
|
||||
// 'ConversationsList',
|
||||
// extra: <String, dynamic>{
|
||||
// kTransitionInfoKey: TransitionInfo(
|
||||
// hasTransition: true,
|
||||
// transitionType: PageTransitionType.leftToRight,
|
||||
// duration: const Duration(milliseconds: 250),
|
||||
// ),
|
||||
// },
|
||||
// );
|
||||
},
|
||||
),
|
||||
title: wrapWithModel(
|
||||
model: _model.modelItemModel,
|
||||
updateCallback: () => setState(() {}),
|
||||
child: ModelItemWidget(),
|
||||
child: const ModelItemWidget(),
|
||||
),
|
||||
actions: [
|
||||
Padding(
|
||||
@@ -85,9 +87,9 @@ class _ConversationWidgetState extends State<ConversationWidget> {
|
||||
borderWidth: 2,
|
||||
buttonSize: 40,
|
||||
fillColor: AppTheme.primaryBackground,
|
||||
icon: Icon(
|
||||
icon: const Icon(
|
||||
Icons.more_vert,
|
||||
color: AppTheme.primaryText,
|
||||
color: AppTheme.primaryTextColor,
|
||||
size: 24,
|
||||
),
|
||||
onPressed: () async {
|
||||
@@ -104,7 +106,7 @@ class _ConversationWidgetState extends State<ConversationWidget> {
|
||||
: FocusScope.of(context).unfocus(),
|
||||
child: Padding(
|
||||
padding: MediaQuery.viewInsetsOf(context),
|
||||
child: ConversationDetailsOverlayWidget(),
|
||||
child: const ConversationDetailsOverlayWidget(),
|
||||
),
|
||||
);
|
||||
},
|
||||
@@ -121,7 +123,7 @@ class _ConversationWidgetState extends State<ConversationWidget> {
|
||||
child: wrapWithModel(
|
||||
model: _model.conversationThreadModel,
|
||||
updateCallback: () => setState(() {}),
|
||||
child: ConversationThreadWidget(),
|
||||
child: const ConversationThreadWidget(),
|
||||
),
|
||||
),
|
||||
),
|
||||
|
||||
@@ -1,9 +1,13 @@
|
||||
import 'dart:nativewrappers/_internal/vm/lib/internal_patch.dart';
|
||||
|
||||
import '/components/conversation_options/conversation_options_widget.dart';
|
||||
import 'package:flutterflow_ui/flutterflow_ui.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:google_fonts/google_fonts.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
|
||||
import 'package:app/theme.dart';
|
||||
|
||||
import 'conversations_list_model.dart';
|
||||
export 'conversations_list_model.dart';
|
||||
|
||||
@@ -60,21 +64,26 @@ class _ConversationsListWidgetState extends State<ConversationsListWidget> {
|
||||
: FocusScope.of(context).unfocus(),
|
||||
child: Padding(
|
||||
padding: MediaQuery.viewInsetsOf(context),
|
||||
child: ConversationOptionsWidget(),
|
||||
child: const ConversationOptionsWidget(),
|
||||
),
|
||||
);
|
||||
},
|
||||
).then((value) => safeSetState(() {}));
|
||||
|
||||
context.pushNamed('Conversation');
|
||||
// TODO
|
||||
//context.pushNamed('Conversation');
|
||||
},
|
||||
child: FloatingActionButton(
|
||||
onPressed: () async {
|
||||
context.pushNamed('Conversation');
|
||||
// TODO
|
||||
// onPressed: () async {
|
||||
// context.pushNamed('Conversation');
|
||||
// },
|
||||
onPressed: () {
|
||||
print("fab pressed");
|
||||
},
|
||||
backgroundColor: AppTheme.primary,
|
||||
elevation: 8,
|
||||
child: Icon(
|
||||
child: const Icon(
|
||||
Icons.add,
|
||||
color: AppTheme.info,
|
||||
size: 24,
|
||||
@@ -84,12 +93,9 @@ class _ConversationsListWidgetState extends State<ConversationsListWidget> {
|
||||
appBar: AppBar(
|
||||
backgroundColor: AppTheme.secondaryBackground,
|
||||
automaticallyImplyLeading: false,
|
||||
title: Text(
|
||||
title: const Text(
|
||||
'My Chats',
|
||||
style: AppTheme.headlineLarge.override(
|
||||
fontFamily: 'Outfit',
|
||||
letterSpacing: 0,
|
||||
),
|
||||
style: AppTheme.headlineLarge,
|
||||
),
|
||||
actions: const [],
|
||||
centerTitle: false,
|
||||
@@ -101,14 +107,11 @@ class _ConversationsListWidgetState extends State<ConversationsListWidget> {
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
Padding(
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(16, 0, 0, 0),
|
||||
const Padding(
|
||||
padding: EdgeInsetsDirectional.fromSTEB(16, 0, 0, 0),
|
||||
child: Text(
|
||||
'AI conversations',
|
||||
style: AppTheme.labelMedium.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
letterSpacing: 0,
|
||||
),
|
||||
style: AppTheme.labelMedium,
|
||||
),
|
||||
),
|
||||
Expanded(
|
||||
@@ -126,9 +129,10 @@ class _ConversationsListWidgetState extends State<ConversationsListWidget> {
|
||||
focusColor: Colors.transparent,
|
||||
hoverColor: Colors.transparent,
|
||||
highlightColor: Colors.transparent,
|
||||
onTap: () async {
|
||||
context.pushNamed('Conversation');
|
||||
},
|
||||
// TODO
|
||||
// onTap: () async {
|
||||
// context.pushNamed('Conversation');
|
||||
// },
|
||||
child: Row(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
mainAxisAlignment: MainAxisAlignment.start,
|
||||
@@ -137,12 +141,12 @@ class _ConversationsListWidgetState extends State<ConversationsListWidget> {
|
||||
Container(
|
||||
width: 100,
|
||||
height: 100,
|
||||
decoration: BoxDecoration(
|
||||
decoration: const BoxDecoration(
|
||||
color: AppTheme
|
||||
.secondaryBackground,
|
||||
),
|
||||
child: Align(
|
||||
alignment: const AlignmentDirectional(0, 0),
|
||||
child: const Align(
|
||||
alignment: AlignmentDirectional(0, 0),
|
||||
child: Icon(
|
||||
Icons.settings_outlined,
|
||||
color: AppTheme
|
||||
@@ -161,12 +165,12 @@ class _ConversationsListWidgetState extends State<ConversationsListWidget> {
|
||||
minWidth:
|
||||
MediaQuery.sizeOf(context).width,
|
||||
),
|
||||
decoration: BoxDecoration(
|
||||
decoration: const BoxDecoration(
|
||||
color: AppTheme
|
||||
.secondaryBackground,
|
||||
shape: BoxShape.rectangle,
|
||||
),
|
||||
child: Column(
|
||||
child: const Column(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
mainAxisAlignment:
|
||||
MainAxisAlignment.spaceEvenly,
|
||||
@@ -175,40 +179,27 @@ class _ConversationsListWidgetState extends State<ConversationsListWidget> {
|
||||
children: [
|
||||
Align(
|
||||
alignment:
|
||||
const AlignmentDirectional(-1, 0),
|
||||
AlignmentDirectional(-1, 0),
|
||||
child: Row(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
children: [
|
||||
Text(
|
||||
'Hello World',
|
||||
style:
|
||||
AppTheme
|
||||
.headlineLarge
|
||||
.override(
|
||||
fontFamily: 'Outfit',
|
||||
letterSpacing: 0,
|
||||
),
|
||||
style: AppTheme.headlineLarge,
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
Align(
|
||||
alignment:
|
||||
const AlignmentDirectional(-1, 0),
|
||||
AlignmentDirectional(-1, 0),
|
||||
child: Row(
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
children: [
|
||||
Expanded(
|
||||
child: Text(
|
||||
'Hello World',
|
||||
style: FlutterFlowAppTheme.of(
|
||||
context)
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily:
|
||||
'Readex Pro',
|
||||
letterSpacing: 0,
|
||||
),
|
||||
style: AppTheme.bodyMedium,
|
||||
),
|
||||
),
|
||||
],
|
||||
@@ -222,11 +213,11 @@ class _ConversationsListWidgetState extends State<ConversationsListWidget> {
|
||||
Container(
|
||||
width: 100,
|
||||
height: 100,
|
||||
decoration: BoxDecoration(
|
||||
decoration: const BoxDecoration(
|
||||
color: AppTheme
|
||||
.secondaryBackground,
|
||||
),
|
||||
child: Icon(
|
||||
child: const Icon(
|
||||
Icons.chevron_right_rounded,
|
||||
color: AppTheme
|
||||
.secondaryText,
|
||||
|
||||
@@ -6,6 +6,7 @@ import 'package:flutter_animate/flutter_animate.dart';
|
||||
import 'package:google_fonts/google_fonts.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
|
||||
import 'package:app/theme.dart';
|
||||
import 'image_details_model.dart';
|
||||
export 'image_details_model.dart';
|
||||
|
||||
@@ -106,19 +107,20 @@ class _ImageDetailsWidgetState extends State<ImageDetailsWidget>
|
||||
appBar: AppBar(
|
||||
backgroundColor: AppTheme.secondaryBackground,
|
||||
automaticallyImplyLeading: false,
|
||||
leading: FlutterFlowIconButton(
|
||||
leading: const FlutterFlowIconButton(
|
||||
borderColor: Colors.transparent,
|
||||
borderRadius: 30,
|
||||
borderWidth: 1,
|
||||
buttonSize: 60,
|
||||
icon: Icon(
|
||||
Icons.arrow_back_rounded,
|
||||
color: AppTheme.primaryText,
|
||||
color: AppTheme.primaryTextColor,
|
||||
size: 30,
|
||||
),
|
||||
onPressed: () async {
|
||||
context.pop();
|
||||
},
|
||||
// TODO
|
||||
// onPressed: () async {
|
||||
// context.pop();
|
||||
// },
|
||||
),
|
||||
actions: const [],
|
||||
centerTitle: false,
|
||||
@@ -199,47 +201,30 @@ class _ImageDetailsWidgetState extends State<ImageDetailsWidget>
|
||||
mainAxisSize: MainAxisSize.max,
|
||||
crossAxisAlignment: CrossAxisAlignment.end,
|
||||
children: [
|
||||
SelectionArea(
|
||||
const SelectionArea(
|
||||
child: AutoSizeText(
|
||||
'Thanks so much! We really do appreciate it!',
|
||||
textAlign: TextAlign.start,
|
||||
style: AppTheme
|
||||
.bodyMedium
|
||||
.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
letterSpacing: 0,
|
||||
lineHeight: 1.5,
|
||||
),
|
||||
style: AppTheme.bodyMedium,
|
||||
)),
|
||||
Padding(
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(
|
||||
const Padding(
|
||||
padding: EdgeInsetsDirectional.fromSTEB(
|
||||
0, 4, 0, 0),
|
||||
child: Text(
|
||||
'Just Now',
|
||||
style: AppTheme
|
||||
.labelSmall
|
||||
.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
letterSpacing: 0,
|
||||
),
|
||||
style: AppTheme.labelSmall,
|
||||
),
|
||||
),
|
||||
].divide(const SizedBox(width: 4)),
|
||||
),
|
||||
Padding(
|
||||
const Padding(
|
||||
padding:
|
||||
const EdgeInsetsDirectional.fromSTEB(0, 4, 0, 0),
|
||||
EdgeInsetsDirectional.fromSTEB(0, 4, 0, 0),
|
||||
child: SelectionArea(
|
||||
child: AutoSizeText(
|
||||
'Thanks so much! We really do appreciate it!',
|
||||
textAlign: TextAlign.start,
|
||||
style: AppTheme
|
||||
.labelLarge
|
||||
.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
letterSpacing: 0,
|
||||
lineHeight: 1.5,
|
||||
),
|
||||
style: AppTheme.labelLarge,
|
||||
)),
|
||||
),
|
||||
],
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -4,6 +4,8 @@ import 'package:flutter_animate/flutter_animate.dart';
|
||||
import 'package:google_fonts/google_fonts.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
|
||||
import 'package:app/theme.dart';
|
||||
|
||||
import 'setup_model.dart';
|
||||
export 'setup_model.dart';
|
||||
|
||||
@@ -155,30 +157,30 @@ class _SetupWidgetState extends State<SetupWidget>
|
||||
child: Container(
|
||||
width: double.infinity,
|
||||
height: 500,
|
||||
decoration: BoxDecoration(
|
||||
decoration: const BoxDecoration(
|
||||
gradient: LinearGradient(
|
||||
colors: [
|
||||
AppTheme.primary,
|
||||
AppTheme.error,
|
||||
AppTheme.tertiary
|
||||
],
|
||||
stops: const [0, 0.5, 1],
|
||||
begin: const AlignmentDirectional(-1, -1),
|
||||
end: const AlignmentDirectional(1, 1),
|
||||
stops: [0, 0.5, 1],
|
||||
begin: AlignmentDirectional(-1, -1),
|
||||
end: AlignmentDirectional(1, 1),
|
||||
),
|
||||
),
|
||||
child: Container(
|
||||
width: 100,
|
||||
height: 100,
|
||||
decoration: BoxDecoration(
|
||||
decoration: const BoxDecoration(
|
||||
gradient: LinearGradient(
|
||||
colors: [
|
||||
const Color(0x00FFFFFF),
|
||||
Color(0x00FFFFFF),
|
||||
AppTheme.secondaryBackground
|
||||
],
|
||||
stops: const [0, 1],
|
||||
begin: const AlignmentDirectional(0, -1),
|
||||
end: const AlignmentDirectional(0, 1),
|
||||
stops: [0, 1],
|
||||
begin: AlignmentDirectional(0, -1),
|
||||
end: AlignmentDirectional(0, 1),
|
||||
),
|
||||
),
|
||||
child: Column(
|
||||
@@ -188,7 +190,7 @@ class _SetupWidgetState extends State<SetupWidget>
|
||||
Container(
|
||||
width: 120,
|
||||
height: 120,
|
||||
decoration: BoxDecoration(
|
||||
decoration: const BoxDecoration(
|
||||
color: AppTheme.accent4,
|
||||
shape: BoxShape.circle,
|
||||
),
|
||||
@@ -205,27 +207,18 @@ class _SetupWidgetState extends State<SetupWidget>
|
||||
animationsMap['containerOnPageLoadAnimation2']!),
|
||||
Padding(
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(0, 44, 0, 0),
|
||||
child: Text(
|
||||
child: const Text(
|
||||
'Welcome!',
|
||||
style: AppTheme
|
||||
.displaySmall
|
||||
.override(
|
||||
fontFamily: 'Outfit',
|
||||
letterSpacing: 0,
|
||||
),
|
||||
style: AppTheme.displaySmall,
|
||||
).animateOnPageLoad(
|
||||
animationsMap['textOnPageLoadAnimation1']!),
|
||||
),
|
||||
Padding(
|
||||
padding: const EdgeInsetsDirectional.fromSTEB(44, 8, 44, 0),
|
||||
child: Text(
|
||||
child: const Text(
|
||||
'Thanks for joining! Access or create your account below, and get started on your journey!',
|
||||
textAlign: TextAlign.center,
|
||||
style:
|
||||
AppTheme.labelMedium.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
letterSpacing: 0,
|
||||
),
|
||||
style: AppTheme.labelMedium,
|
||||
).animateOnPageLoad(
|
||||
animationsMap['textOnPageLoadAnimation2']!),
|
||||
),
|
||||
@@ -258,13 +251,9 @@ class _SetupWidgetState extends State<SetupWidget>
|
||||
const EdgeInsetsDirectional.fromSTEB(0, 0, 0, 0),
|
||||
color: AppTheme
|
||||
.secondaryBackground,
|
||||
textStyle:
|
||||
AppTheme.bodyLarge.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
letterSpacing: 0,
|
||||
),
|
||||
textStyle: AppTheme.bodyLarge,
|
||||
elevation: 0,
|
||||
borderSide: BorderSide(
|
||||
borderSide: const BorderSide(
|
||||
color: AppTheme.alternate,
|
||||
width: 2,
|
||||
),
|
||||
@@ -291,13 +280,7 @@ class _SetupWidgetState extends State<SetupWidget>
|
||||
iconPadding:
|
||||
const EdgeInsetsDirectional.fromSTEB(0, 0, 0, 0),
|
||||
color: AppTheme.primary,
|
||||
textStyle: AppTheme
|
||||
.titleSmall
|
||||
.override(
|
||||
fontFamily: 'Readex Pro',
|
||||
color: Colors.white,
|
||||
letterSpacing: 0,
|
||||
),
|
||||
textStyle: AppTheme.titleSmall,
|
||||
elevation: 3,
|
||||
borderSide: const BorderSide(
|
||||
color: Colors.transparent,
|
||||
|
||||
@@ -131,11 +131,11 @@ class _SupportFormWidgetState extends State<SupportFormWidget>
|
||||
buttonSize: 60,
|
||||
icon: const Icon(
|
||||
Icons.arrow_back_rounded,
|
||||
color: AppTheme.primaryText,
|
||||
color: AppTheme.primaryTextColor,
|
||||
size: 30,
|
||||
),
|
||||
onPressed: () async {
|
||||
context.pop();
|
||||
//TODO: context.pop();
|
||||
},
|
||||
),
|
||||
title: const Text(
|
||||
|
||||
Reference in New Issue
Block a user