Implement desktop client layout
This commit is contained in:
parent
5a8566854b
commit
afd2bd6ca1
|
|
@ -250,6 +250,8 @@ abstract class UIState implements Built<UIState, UIStateBuilder> {
|
||||||
|
|
||||||
bool get isPreviewing => previewStack.isNotEmpty;
|
bool get isPreviewing => previewStack.isNotEmpty;
|
||||||
|
|
||||||
|
bool get isList => !isEditing && !isEmailing && !isPDF && !isInSettings;
|
||||||
|
|
||||||
bool get hasRecentActivity {
|
bool get hasRecentActivity {
|
||||||
if (lastActivityAt == 0) {
|
if (lastActivityAt == 0) {
|
||||||
return false;
|
return false;
|
||||||
|
|
|
||||||
|
|
@ -713,7 +713,7 @@ class EntityScreens extends StatelessWidget {
|
||||||
child: AppBorder(
|
child: AppBorder(
|
||||||
child: AppBorder(
|
child: AppBorder(
|
||||||
child: child,
|
child: child,
|
||||||
isTop: isFullScreen && uiState.filterEntityType != null,
|
isTop: isFullScreen,
|
||||||
),
|
),
|
||||||
isLeft: true,
|
isLeft: true,
|
||||||
),
|
),
|
||||||
|
|
|
||||||
|
|
@ -618,7 +618,8 @@ class _DrawerTileState extends State<DrawerTile> {
|
||||||
}
|
}
|
||||||
|
|
||||||
final isSelected = uiState.filterEntityType != null &&
|
final isSelected = uiState.filterEntityType != null &&
|
||||||
prefState.isViewerFullScreen(uiState.filterEntityType)
|
prefState.isViewerFullScreen(uiState.filterEntityType) &&
|
||||||
|
uiState.isList
|
||||||
? widget.entityType == uiState.filterEntityType
|
? widget.entityType == uiState.filterEntityType
|
||||||
: uiState.currentRoute.startsWith('/${toSnakeCase(route)}');
|
: uiState.currentRoute.startsWith('/${toSnakeCase(route)}');
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -267,11 +267,7 @@ class InvoiceEditDesktopState extends State<InvoiceEditDesktop>
|
||||||
viewModel.onAddClientPressed(context, completer),
|
viewModel.onAddClientPressed(context, completer),
|
||||||
)
|
)
|
||||||
else
|
else
|
||||||
InkWell(
|
ConstrainedBox(
|
||||||
onTap: () {
|
|
||||||
filterByEntity(context: context, entity: client);
|
|
||||||
},
|
|
||||||
child: ConstrainedBox(
|
|
||||||
constraints: BoxConstraints(
|
constraints: BoxConstraints(
|
||||||
minWidth: double.infinity, minHeight: 40),
|
minWidth: double.infinity, minHeight: 40),
|
||||||
child: Padding(
|
child: Padding(
|
||||||
|
|
@ -286,7 +282,6 @@ class InvoiceEditDesktopState extends State<InvoiceEditDesktop>
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
|
||||||
SizedBox(height: 8),
|
SizedBox(height: 8),
|
||||||
ConstrainedBox(
|
ConstrainedBox(
|
||||||
constraints: BoxConstraints(maxHeight: 186),
|
constraints: BoxConstraints(maxHeight: 186),
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue