Flutter upgrader
This commit is contained in:
parent
dff9255da6
commit
63f5c6d583
|
|
@ -50,7 +50,7 @@ class ActionMenuButton extends StatelessWidget {
|
|||
children: <Widget>[
|
||||
Icon(
|
||||
getEntityActionIcon(action),
|
||||
color: Theme.of(context).accentColor,
|
||||
color: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
SizedBox(width: 16.0),
|
||||
Expanded(
|
||||
|
|
|
|||
|
|
@ -148,7 +148,7 @@ class _AppBottomBarState extends State<AppBottomBar> {
|
|||
title: Text(AppLocalization.of(context).lookup('$state')),
|
||||
controlAffinity: ListTileControlAffinity.leading,
|
||||
value: stateFilters.contains(state),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
dense: true,
|
||||
onChanged: (value) {
|
||||
widget.onSelectedState(state, value);
|
||||
|
|
@ -189,7 +189,7 @@ class _AppBottomBarState extends State<AppBottomBar> {
|
|||
Text(AppLocalization.of(context).lookup(status.name)),
|
||||
controlAffinity: ListTileControlAffinity.leading,
|
||||
value: statusFilters.contains(status),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
dense: true,
|
||||
onChanged: (value) {
|
||||
widget.onSelectedStatus(status, value);
|
||||
|
|
@ -239,7 +239,7 @@ class _AppBottomBarState extends State<AppBottomBar> {
|
|||
: AppLocalization.of(context).descending)
|
||||
: null,
|
||||
groupValue: listUIState.sortField,
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
onChanged: (String value) {
|
||||
if (value == null &&
|
||||
listUIState.sortField == field) {
|
||||
|
|
@ -411,7 +411,7 @@ class _AppBottomBarState extends State<AppBottomBar> {
|
|||
color: store.state
|
||||
.getListState(widget.entityType)
|
||||
.hasStateFilters
|
||||
? Theme.of(context).accentColor
|
||||
? Theme.of(context).colorScheme.secondary
|
||||
: null,
|
||||
),
|
||||
if (widget.statuses.isNotEmpty)
|
||||
|
|
@ -422,7 +422,7 @@ class _AppBottomBarState extends State<AppBottomBar> {
|
|||
color: store.state
|
||||
.getListState(widget.entityType)
|
||||
.hasStatusFilters
|
||||
? Theme.of(context).accentColor
|
||||
? Theme.of(context).colorScheme.secondary
|
||||
: null,
|
||||
),
|
||||
if (widget.customValues1.isNotEmpty)
|
||||
|
|
@ -433,7 +433,7 @@ class _AppBottomBarState extends State<AppBottomBar> {
|
|||
color: store.state
|
||||
.getListState(widget.entityType)
|
||||
.hasCustom1Filters
|
||||
? Theme.of(context).accentColor
|
||||
? Theme.of(context).colorScheme.secondary
|
||||
: null,
|
||||
),
|
||||
if (widget.customValues2.isNotEmpty)
|
||||
|
|
@ -444,7 +444,7 @@ class _AppBottomBarState extends State<AppBottomBar> {
|
|||
color: store.state
|
||||
.getListState(widget.entityType)
|
||||
.hasCustom2Filters
|
||||
? Theme.of(context).accentColor
|
||||
? Theme.of(context).colorScheme.secondary
|
||||
: null,
|
||||
),
|
||||
if (widget.customValues3.isNotEmpty)
|
||||
|
|
@ -455,7 +455,7 @@ class _AppBottomBarState extends State<AppBottomBar> {
|
|||
color: store.state
|
||||
.getListState(widget.entityType)
|
||||
.hasCustom3Filters
|
||||
? Theme.of(context).accentColor
|
||||
? Theme.of(context).colorScheme.secondary
|
||||
: null,
|
||||
),
|
||||
if (widget.customValues4.isNotEmpty)
|
||||
|
|
@ -466,7 +466,7 @@ class _AppBottomBarState extends State<AppBottomBar> {
|
|||
color: store.state
|
||||
.getListState(widget.entityType)
|
||||
.hasCustom4Filters
|
||||
? Theme.of(context).accentColor
|
||||
? Theme.of(context).colorScheme.secondary
|
||||
: null,
|
||||
),
|
||||
if (!widget.entityType.isSetting)
|
||||
|
|
@ -556,7 +556,7 @@ class CustomFieldSelector extends StatelessWidget {
|
|||
title: Text(customField),
|
||||
controlAffinity: ListTileControlAffinity.leading,
|
||||
value: customFilters.contains(customField),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
dense: true,
|
||||
onChanged: (value) => onSelected(customField),
|
||||
);
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@ class AppButton extends StatelessWidget {
|
|||
Widget build(BuildContext context) {
|
||||
final button = ElevatedButton(
|
||||
style: ElevatedButton.styleFrom(
|
||||
primary: color ?? Theme.of(context).buttonColor,
|
||||
primary: color ?? Theme.of(context).colorScheme.secondary,
|
||||
padding: EdgeInsets.symmetric(vertical: 14, horizontal: 14),
|
||||
shape: RoundedRectangleBorder(
|
||||
borderRadius: BorderRadius.circular(kBorderRadius)),
|
||||
|
|
|
|||
|
|
@ -183,7 +183,8 @@ class EditScaffold extends StatelessWidget {
|
|||
children: <Widget>[
|
||||
Icon(
|
||||
getEntityActionIcon(action),
|
||||
color: Theme.of(context).accentColor,
|
||||
color:
|
||||
Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
SizedBox(width: 16.0),
|
||||
Text(AppLocalization.of(context)
|
||||
|
|
|
|||
|
|
@ -29,7 +29,7 @@ class AppTabBar extends StatelessWidget {
|
|||
tabs: tabs,
|
||||
controller: controller,
|
||||
isScrollable: isScrollable,
|
||||
indicatorColor: Theme.of(context).accentColor,
|
||||
indicatorColor: Theme.of(context).colorScheme.secondary,
|
||||
onTap: onTap,
|
||||
);
|
||||
|
||||
|
|
|
|||
|
|
@ -51,7 +51,7 @@ class BoolDropdownButton extends StatelessWidget {
|
|||
secondary:
|
||||
iconData != null && isDesktop(context) ? Icon(iconData) : null,
|
||||
onChanged: (value) => onChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
subtitle: helpLabel != null ? Text(helpLabel) : null,
|
||||
),
|
||||
);
|
||||
|
|
@ -104,7 +104,8 @@ class BoolDropdownButton extends StatelessWidget {
|
|||
value: false,
|
||||
onChanged: (value) => null,
|
||||
groupValue: value,
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor:
|
||||
Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
),
|
||||
Text(falseLabel),
|
||||
|
|
@ -125,7 +126,8 @@ class BoolDropdownButton extends StatelessWidget {
|
|||
value: true,
|
||||
onChanged: (value) => null,
|
||||
groupValue: value,
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor:
|
||||
Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
),
|
||||
Text(trueLabel),
|
||||
|
|
|
|||
|
|
@ -22,8 +22,8 @@ class HelpLink extends StatelessWidget {
|
|||
final localization = AppLocalization.of(context);
|
||||
final ThemeData themeData = Theme.of(context);
|
||||
final TextStyle aboutTextStyle = themeData.textTheme.bodyText2;
|
||||
final TextStyle linkStyle =
|
||||
themeData.textTheme.bodyText2.copyWith(color: themeData.accentColor);
|
||||
final TextStyle linkStyle = themeData.textTheme.bodyText2
|
||||
.copyWith(color: themeData.colorScheme.secondary);
|
||||
|
||||
return Padding(
|
||||
padding: const EdgeInsets.only(top: 20, bottom: 30),
|
||||
|
|
|
|||
|
|
@ -760,7 +760,7 @@ class SidebarFooter extends StatelessWidget {
|
|||
tooltip: localization.updateAvailable,
|
||||
icon: Icon(
|
||||
Icons.warning,
|
||||
color: Theme.of(context).accentColor,
|
||||
color: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
onPressed: () => _showUpdate(context),
|
||||
)
|
||||
|
|
@ -934,7 +934,8 @@ class SidebarFooterCollapsed extends StatelessWidget {
|
|||
state.prefState.isFilterVisible
|
||||
? PopupMenuButton<String>(
|
||||
icon: isUpdateAvailable
|
||||
? Icon(Icons.warning, color: Theme.of(context).accentColor)
|
||||
? Icon(Icons.warning,
|
||||
color: Theme.of(context).colorScheme.secondary)
|
||||
: Icon(Icons.info_outline),
|
||||
onSelected: (value) {
|
||||
if (value == localization.updateAvailable) {
|
||||
|
|
@ -951,7 +952,7 @@ class SidebarFooterCollapsed extends StatelessWidget {
|
|||
child: ListTile(
|
||||
leading: Icon(
|
||||
Icons.warning,
|
||||
color: Theme.of(context).accentColor,
|
||||
color: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
title: Text(localization.updateAvailable),
|
||||
),
|
||||
|
|
@ -1400,7 +1401,7 @@ class _ContactUsDialogState extends State<ContactUsDialog> {
|
|||
setState(() => _includeLogs = value);
|
||||
},
|
||||
title: Text(localization.includeRecentErrors),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
]
|
||||
]),
|
||||
|
|
|
|||
|
|
@ -693,14 +693,14 @@ class AppDataTable extends StatelessWidget {
|
|||
tableColumns[0] = FixedColumnWidth(
|
||||
horizontalMargin + Checkbox.width + horizontalMargin / 2.0);
|
||||
tableRows[0].children[0] = _buildCheckbox(
|
||||
color: theme.accentColor,
|
||||
color: theme.colorScheme.secondary,
|
||||
checked: allChecked,
|
||||
onCheckboxChanged: _handleSelectAll,
|
||||
);
|
||||
rowIndex = 1;
|
||||
for (final DataRow row in rows) {
|
||||
tableRows[rowIndex].children[0] = _buildCheckbox(
|
||||
color: theme.accentColor,
|
||||
color: theme.colorScheme.secondary,
|
||||
checked: row.selected,
|
||||
onRowTap: () => row.onSelectChanged != null
|
||||
? row.onSelectChanged(!row.selected)
|
||||
|
|
|
|||
|
|
@ -379,7 +379,7 @@ class _EntityListState extends State<EntityList> {
|
|||
handleEntitiesActions(
|
||||
entities, EntityAction.toggleMultiselect);
|
||||
},
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
value: entityList.length ==
|
||||
(listUIState.selectedIds ?? <String>[]).length,
|
||||
),
|
||||
|
|
@ -448,11 +448,10 @@ class _EntityListState extends State<EntityList> {
|
|||
value: action,
|
||||
child: Row(
|
||||
children: <Widget>[
|
||||
Icon(
|
||||
getEntityActionIcon(action),
|
||||
Icon(getEntityActionIcon(action),
|
||||
color: Theme.of(context)
|
||||
.accentColor,
|
||||
),
|
||||
.colorScheme
|
||||
.secondary),
|
||||
SizedBox(width: 16.0),
|
||||
Text(AppLocalization.of(context)
|
||||
.lookup(
|
||||
|
|
|
|||
|
|
@ -1,21 +1,18 @@
|
|||
// Dart imports:
|
||||
import 'dart:convert';
|
||||
import 'dart:io';
|
||||
//import 'dart:convert';
|
||||
//import 'dart:io';
|
||||
|
||||
// Flutter imports:
|
||||
import 'package:flutter/foundation.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
// Package imports:
|
||||
import 'package:flutter_redux/flutter_redux.dart';
|
||||
//import 'package:flutter_redux/flutter_redux.dart';
|
||||
|
||||
// Project imports:
|
||||
import 'package:invoiceninja_flutter/data/web_client.dart';
|
||||
import 'package:invoiceninja_flutter/redux/app/app_actions.dart';
|
||||
import 'package:invoiceninja_flutter/redux/app/app_state.dart';
|
||||
|
||||
/*
|
||||
*/
|
||||
//import 'package:invoiceninja_flutter/data/web_client.dart';
|
||||
//import 'package:invoiceninja_flutter/redux/app/app_actions.dart';
|
||||
//import 'package:invoiceninja_flutter/redux/app/app_state.dart';
|
||||
|
||||
class WebSocketRefresh extends StatefulWidget {
|
||||
const WebSocketRefresh({
|
||||
|
|
|
|||
|
|
@ -90,7 +90,8 @@ class ClientListItem extends StatelessWidget {
|
|||
MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) =>
|
||||
onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor:
|
||||
Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
),
|
||||
)
|
||||
|
|
@ -163,7 +164,7 @@ class ClientListItem extends StatelessWidget {
|
|||
materialTapTargetSize:
|
||||
MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: null,
|
||||
|
|
|
|||
|
|
@ -359,7 +359,7 @@ class ContactEditDetailsState extends State<ContactEditDetails> {
|
|||
Padding(
|
||||
padding: const EdgeInsets.only(top: 20),
|
||||
child: SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.addToInvoices),
|
||||
value: _sendEmail,
|
||||
onChanged: (value) {
|
||||
|
|
|
|||
|
|
@ -73,7 +73,7 @@ class CompanyGatewayListItem extends StatelessWidget {
|
|||
value: isChecked,
|
||||
materialTapTargetSize: MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: null,
|
||||
|
|
|
|||
|
|
@ -243,7 +243,7 @@ class _CompanyGatewayEditState extends State<CompanyGatewayEdit>
|
|||
SwitchListTile(
|
||||
title: Text(localization
|
||||
.lookup(kGatewayTypes[gatewayTypeId] ?? '')),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
value: companyGateway
|
||||
.getSettingsForGatewayTypeId(gatewayTypeId)
|
||||
.isEnabled,
|
||||
|
|
@ -267,7 +267,7 @@ class _CompanyGatewayEditState extends State<CompanyGatewayEdit>
|
|||
),
|
||||
),
|
||||
CheckboxListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.clientName),
|
||||
value: companyGateway.requireClientName,
|
||||
onChanged: (value) => viewModel.onChanged(companyGateway
|
||||
|
|
@ -275,7 +275,7 @@ class _CompanyGatewayEditState extends State<CompanyGatewayEdit>
|
|||
controlAffinity: ListTileControlAffinity.leading,
|
||||
),
|
||||
CheckboxListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.clientPhone),
|
||||
value: companyGateway.requireClientPhone,
|
||||
onChanged: (value) => viewModel.onChanged(companyGateway
|
||||
|
|
@ -283,7 +283,7 @@ class _CompanyGatewayEditState extends State<CompanyGatewayEdit>
|
|||
controlAffinity: ListTileControlAffinity.leading,
|
||||
),
|
||||
CheckboxListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.contactName),
|
||||
value: companyGateway.requireContactName,
|
||||
onChanged: (value) => viewModel.onChanged(companyGateway
|
||||
|
|
@ -291,7 +291,7 @@ class _CompanyGatewayEditState extends State<CompanyGatewayEdit>
|
|||
controlAffinity: ListTileControlAffinity.leading,
|
||||
),
|
||||
CheckboxListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.contactEmail),
|
||||
value: companyGateway.requireContactEmail,
|
||||
onChanged: (value) => viewModel.onChanged(companyGateway
|
||||
|
|
@ -299,7 +299,7 @@ class _CompanyGatewayEditState extends State<CompanyGatewayEdit>
|
|||
controlAffinity: ListTileControlAffinity.leading,
|
||||
),
|
||||
CheckboxListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.postalCode),
|
||||
value: companyGateway.requirePostalCode,
|
||||
onChanged: (value) => viewModel.onChanged(companyGateway
|
||||
|
|
@ -307,7 +307,7 @@ class _CompanyGatewayEditState extends State<CompanyGatewayEdit>
|
|||
controlAffinity: ListTileControlAffinity.leading,
|
||||
),
|
||||
CheckboxListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.cvv),
|
||||
value: companyGateway.requireCvv,
|
||||
onChanged: (value) => viewModel.onChanged(
|
||||
|
|
@ -315,7 +315,7 @@ class _CompanyGatewayEditState extends State<CompanyGatewayEdit>
|
|||
controlAffinity: ListTileControlAffinity.leading,
|
||||
),
|
||||
CheckboxListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.billingAddress),
|
||||
value: companyGateway.requireBillingAddress,
|
||||
onChanged: (value) => viewModel.onChanged(companyGateway
|
||||
|
|
@ -323,7 +323,7 @@ class _CompanyGatewayEditState extends State<CompanyGatewayEdit>
|
|||
controlAffinity: ListTileControlAffinity.leading,
|
||||
),
|
||||
CheckboxListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.shippingAddress),
|
||||
value: companyGateway.requireShippingAddress,
|
||||
onChanged: (value) => viewModel.onChanged(companyGateway
|
||||
|
|
@ -332,7 +332,7 @@ class _CompanyGatewayEditState extends State<CompanyGatewayEdit>
|
|||
),
|
||||
SizedBox(height: 16),
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.updateAddress),
|
||||
subtitle: Text(localization.updateAddressHelp),
|
||||
value: companyGateway.updateDetails,
|
||||
|
|
@ -445,7 +445,7 @@ class CardListTile extends StatelessWidget {
|
|||
|
||||
return CheckboxListTile(
|
||||
controlAffinity: ListTileControlAffinity.leading,
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(staticState.paymentTypeMap[paymentType]?.name ?? ''),
|
||||
value: companyGateway.supportsCard(cardType),
|
||||
onChanged: (value) => viewModel.onChanged(value
|
||||
|
|
@ -611,7 +611,7 @@ class _GatewayConfigFieldState extends State<GatewayConfigField> {
|
|||
} else if (widget.defaultValue.runtimeType == bool) {
|
||||
return CheckboxListTile(
|
||||
controlAffinity: ListTileControlAffinity.leading,
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(toTitleCase(widget.field)),
|
||||
value: widget.value ?? false,
|
||||
onChanged: (value) => widget.onChanged(value),
|
||||
|
|
@ -745,7 +745,7 @@ class _LimitEditorState extends State<LimitEditor> {
|
|||
CheckboxListTile(
|
||||
controlAffinity: ListTileControlAffinity.leading,
|
||||
contentPadding: const EdgeInsets.all(0),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(isDesktop(context)
|
||||
? localization.enableMin
|
||||
: localization.enable),
|
||||
|
|
@ -780,7 +780,7 @@ class _LimitEditorState extends State<LimitEditor> {
|
|||
CheckboxListTile(
|
||||
controlAffinity: ListTileControlAffinity.leading,
|
||||
contentPadding: const EdgeInsets.all(0),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(isDesktop(context)
|
||||
? localization.enableMax
|
||||
: localization.enable),
|
||||
|
|
@ -959,7 +959,7 @@ class _FeesEditorState extends State<FeesEditor> {
|
|||
..feesAndLimitsMap[widget.gatewayTypeId] =
|
||||
settings.rebuild((b) => b..adjustFeePercent = value))),
|
||||
title: Text(localization.adjustFeePercent),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
subtitle: Text(localization.adjustFeePercentHelp),
|
||||
),
|
||||
),
|
||||
|
|
|
|||
|
|
@ -98,7 +98,8 @@ class CreditListItem extends StatelessWidget {
|
|||
MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) =>
|
||||
onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor:
|
||||
Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: ActionMenuButton(
|
||||
|
|
@ -179,7 +180,7 @@ class CreditListItem extends StatelessWidget {
|
|||
materialTapTargetSize:
|
||||
MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: null,
|
||||
|
|
|
|||
|
|
@ -84,7 +84,8 @@ class _DashboardDateRangePickerState extends State<DashboardDateRangePicker> {
|
|||
Text(localization.compare),
|
||||
Switch(
|
||||
value: _settings.enableComparison,
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor:
|
||||
Theme.of(context).colorScheme.secondary,
|
||||
onChanged: (value) {
|
||||
setState(
|
||||
() => _settings.enableComparison = value);
|
||||
|
|
|
|||
|
|
@ -64,7 +64,7 @@ class DesignListItem extends StatelessWidget {
|
|||
value: isChecked,
|
||||
materialTapTargetSize: MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: null,
|
||||
|
|
|
|||
|
|
@ -473,7 +473,7 @@ class _DesignSettingsState extends State<DesignSettings> {
|
|||
if (kIsWeb || isMobileOS()) ...[
|
||||
SizedBox(height: 16),
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.draftMode),
|
||||
subtitle: Text(localization.draftModeHelp),
|
||||
value: widget.draftMode,
|
||||
|
|
|
|||
|
|
@ -69,7 +69,7 @@ class DocumentListItem extends StatelessWidget {
|
|||
value: isChecked,
|
||||
materialTapTargetSize: MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: null,
|
||||
|
|
|
|||
|
|
@ -154,7 +154,7 @@ class ExpenseEditSettingsState extends State<ExpenseEditSettings> {
|
|||
expense.isInvoiced
|
||||
? SizedBox()
|
||||
: SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.shouldBeInvoiced),
|
||||
subtitle: Text(localization.shouldBeInvoicedHelp),
|
||||
value: expense.shouldBeInvoiced,
|
||||
|
|
@ -164,7 +164,7 @@ class ExpenseEditSettingsState extends State<ExpenseEditSettings> {
|
|||
},
|
||||
),
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.markPaid),
|
||||
value: _showPaymentFields,
|
||||
subtitle: Text(localization.markPaidHelp),
|
||||
|
|
@ -219,7 +219,7 @@ class ExpenseEditSettingsState extends State<ExpenseEditSettings> {
|
|||
)
|
||||
: SizedBox(),
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.convertCurrency),
|
||||
subtitle: Text(localization.convertCurrencyHelp),
|
||||
value: _showConvertCurrencyFields,
|
||||
|
|
@ -288,7 +288,7 @@ class ExpenseEditSettingsState extends State<ExpenseEditSettings> {
|
|||
)
|
||||
: SizedBox(),
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.addDocumentsToInvoice),
|
||||
subtitle: Text(localization.addDocumentsToInvoiceHelp),
|
||||
value: expense.invoiceDocuments,
|
||||
|
|
@ -334,7 +334,7 @@ class ExpenseEditSettingsState extends State<ExpenseEditSettings> {
|
|||
),
|
||||
SizedBox(height: 16),
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.inclusiveTaxes),
|
||||
value: expense.usesInclusiveTaxes,
|
||||
subtitle: Text(
|
||||
|
|
|
|||
|
|
@ -121,7 +121,8 @@ class ExpenseListItem extends StatelessWidget {
|
|||
MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) =>
|
||||
onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor:
|
||||
Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
),
|
||||
)
|
||||
|
|
@ -202,7 +203,7 @@ class ExpenseListItem extends StatelessWidget {
|
|||
materialTapTargetSize:
|
||||
MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: null,
|
||||
|
|
|
|||
|
|
@ -69,7 +69,7 @@ class ExpenseCategoryListItem extends StatelessWidget {
|
|||
value: isChecked,
|
||||
materialTapTargetSize: MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: null,
|
||||
|
|
|
|||
|
|
@ -65,7 +65,7 @@ class GroupListItem extends StatelessWidget {
|
|||
value: isChecked,
|
||||
materialTapTargetSize: MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: null,
|
||||
|
|
|
|||
|
|
@ -82,7 +82,7 @@ class _ContactListTile extends StatelessWidget {
|
|||
onTap: onTap,
|
||||
leading: IgnorePointer(
|
||||
child: Checkbox(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
value: invitation != null,
|
||||
onChanged: (value) => null,
|
||||
),
|
||||
|
|
|
|||
|
|
@ -693,8 +693,9 @@ class InvoiceEditDesktopState extends State<InvoiceEditDesktop>
|
|||
padding:
|
||||
const EdgeInsets.only(top: 8),
|
||||
child: SwitchListTile(
|
||||
activeColor:
|
||||
Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context)
|
||||
.colorScheme
|
||||
.secondary,
|
||||
title: Text(
|
||||
localization.inclusiveTaxes),
|
||||
dense: true,
|
||||
|
|
@ -719,8 +720,9 @@ class InvoiceEditDesktopState extends State<InvoiceEditDesktop>
|
|||
padding:
|
||||
const EdgeInsets.only(top: 8),
|
||||
child: SwitchListTile(
|
||||
activeColor:
|
||||
Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context)
|
||||
.colorScheme
|
||||
.secondary,
|
||||
title: Text(
|
||||
localization.autoBillEnabled),
|
||||
dense: true,
|
||||
|
|
|
|||
|
|
@ -424,7 +424,7 @@ class InvoiceEditDetailsState extends State<InvoiceEditDetails> {
|
|||
Padding(
|
||||
padding: const EdgeInsets.only(top: 8),
|
||||
child: SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.inclusiveTaxes),
|
||||
dense: true,
|
||||
value: invoice.usesInclusiveTaxes,
|
||||
|
|
@ -438,7 +438,7 @@ class InvoiceEditDetailsState extends State<InvoiceEditDetails> {
|
|||
Padding(
|
||||
padding: const EdgeInsets.only(top: 8),
|
||||
child: SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.autoBillEnabled),
|
||||
dense: true,
|
||||
value: invoice.autoBillEnabled,
|
||||
|
|
|
|||
|
|
@ -103,8 +103,9 @@ class InvoiceListItem extends StatelessWidget {
|
|||
materialTapTargetSize:
|
||||
MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => null,
|
||||
activeColor:
|
||||
Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context)
|
||||
.colorScheme
|
||||
.secondary,
|
||||
),
|
||||
)
|
||||
: ActionMenuButton(
|
||||
|
|
@ -190,7 +191,8 @@ class InvoiceListItem extends StatelessWidget {
|
|||
materialTapTargetSize:
|
||||
MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => null,
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor:
|
||||
Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: null,
|
||||
|
|
|
|||
|
|
@ -337,7 +337,7 @@ class _PaymentEditState extends State<PaymentEdit> {
|
|||
children: [
|
||||
if (payment.isNew)
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.sendEmail),
|
||||
value: payment.sendEmail ?? false,
|
||||
subtitle: Text(localization.emailReceipt),
|
||||
|
|
@ -345,7 +345,7 @@ class _PaymentEditState extends State<PaymentEdit> {
|
|||
.onChanged(payment.rebuild((b) => b..sendEmail = value)),
|
||||
),
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.convertCurrency),
|
||||
value: _showConvertCurrency,
|
||||
onChanged: (value) {
|
||||
|
|
|
|||
|
|
@ -98,7 +98,8 @@ class PaymentListItem extends StatelessWidget {
|
|||
materialTapTargetSize:
|
||||
MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => null,
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor:
|
||||
Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: ActionMenuButton(
|
||||
|
|
@ -173,7 +174,7 @@ class PaymentListItem extends StatelessWidget {
|
|||
materialTapTargetSize:
|
||||
MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => null,
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: null,
|
||||
|
|
|
|||
|
|
@ -143,7 +143,7 @@ class _PaymentRefundState extends State<PaymentRefund> {
|
|||
FormCard(
|
||||
children: <Widget>[
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.sendEmail),
|
||||
value: payment.sendEmail ?? false,
|
||||
subtitle: Text(localization.emailReceipt),
|
||||
|
|
@ -152,7 +152,7 @@ class _PaymentRefundState extends State<PaymentRefund> {
|
|||
),
|
||||
if (gateway.supportsRefunds)
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.gatewayRefund),
|
||||
value: payment.gatewayRefund ?? false,
|
||||
subtitle: Text(localization.gatewayRefundHelp),
|
||||
|
|
|
|||
|
|
@ -73,7 +73,7 @@ class PaymentTermListItem extends StatelessWidget {
|
|||
value: isChecked,
|
||||
materialTapTargetSize: MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: null,
|
||||
|
|
|
|||
|
|
@ -90,7 +90,8 @@ class ProductListItem extends StatelessWidget {
|
|||
MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) =>
|
||||
onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor:
|
||||
Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: ActionMenuButton(
|
||||
|
|
@ -163,7 +164,7 @@ class ProductListItem extends StatelessWidget {
|
|||
materialTapTargetSize:
|
||||
MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: null,
|
||||
|
|
|
|||
|
|
@ -94,7 +94,8 @@ class ProjectListItem extends StatelessWidget {
|
|||
MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) =>
|
||||
onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor:
|
||||
Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
),
|
||||
)
|
||||
|
|
@ -175,7 +176,7 @@ class ProjectListItem extends StatelessWidget {
|
|||
materialTapTargetSize:
|
||||
MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: null,
|
||||
|
|
|
|||
|
|
@ -94,8 +94,9 @@ class QuoteListItem extends StatelessWidget {
|
|||
materialTapTargetSize:
|
||||
MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => null,
|
||||
activeColor:
|
||||
Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context)
|
||||
.colorScheme
|
||||
.secondary,
|
||||
),
|
||||
)
|
||||
: ActionMenuButton(
|
||||
|
|
@ -177,7 +178,8 @@ class QuoteListItem extends StatelessWidget {
|
|||
materialTapTargetSize:
|
||||
MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => null,
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor:
|
||||
Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: null,
|
||||
|
|
|
|||
|
|
@ -122,7 +122,8 @@ class RecurringExpenseListItem extends StatelessWidget {
|
|||
MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) =>
|
||||
onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor:
|
||||
Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
),
|
||||
)
|
||||
|
|
@ -203,7 +204,7 @@ class RecurringExpenseListItem extends StatelessWidget {
|
|||
materialTapTargetSize:
|
||||
MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: null,
|
||||
|
|
|
|||
|
|
@ -102,8 +102,9 @@ class RecurringInvoiceListItem extends StatelessWidget {
|
|||
materialTapTargetSize:
|
||||
MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => null,
|
||||
activeColor:
|
||||
Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context)
|
||||
.colorScheme
|
||||
.secondary,
|
||||
),
|
||||
)
|
||||
: ActionMenuButton(
|
||||
|
|
@ -185,7 +186,8 @@ class RecurringInvoiceListItem extends StatelessWidget {
|
|||
materialTapTargetSize:
|
||||
MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => null,
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor:
|
||||
Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: null,
|
||||
|
|
|
|||
|
|
@ -195,7 +195,7 @@ class _AccountManagementState extends State<AccountManagement>
|
|||
controlAffinity: ListTileControlAffinity.leading,
|
||||
title: Text(localization.lookup(kModules[module])),
|
||||
value: company.enabledModules & module != 0,
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
onChanged: (value) {
|
||||
int enabledModules = company.enabledModules;
|
||||
if (value) {
|
||||
|
|
@ -361,7 +361,7 @@ class _AccountOverview extends StatelessWidget {
|
|||
},
|
||||
title: Text(localization.activateCompany),
|
||||
subtitle: Text(localization.activateCompanyHelp),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
SwitchListTile(
|
||||
value: company.markdownEnabled,
|
||||
|
|
@ -371,7 +371,7 @@ class _AccountOverview extends StatelessWidget {
|
|||
},
|
||||
title: Text(localization.enableMarkdown),
|
||||
subtitle: Text(localization.enableMarkdownHelp),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
SwitchListTile(
|
||||
value: company.reportIncludeDrafts,
|
||||
|
|
@ -381,7 +381,7 @@ class _AccountOverview extends StatelessWidget {
|
|||
},
|
||||
title: Text(localization.includeDrafts),
|
||||
subtitle: Text(localization.includeDraftsHelp),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
],
|
||||
),
|
||||
|
|
|
|||
|
|
@ -494,7 +494,7 @@ class _ClientPortalState extends State<ClientPortal>
|
|||
isLast: true,
|
||||
children: company.clientRegistrationFields
|
||||
.map((field) => SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.lookup(field.key)),
|
||||
value: field.required,
|
||||
onChanged: (value) {
|
||||
|
|
|
|||
|
|
@ -414,7 +414,7 @@ class _CustomFormFieldState extends State<CustomFormField> {
|
|||
children: [
|
||||
IgnorePointer(
|
||||
child: Checkbox(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
value: widget.taxesEnabled ?? false,
|
||||
onChanged: (value) => null,
|
||||
),
|
||||
|
|
|
|||
|
|
@ -186,7 +186,7 @@ class _DeviceSettingsState extends State<DeviceSettings>
|
|||
secondary: Icon(prefState.requireAuthentication
|
||||
? MdiIcons.lock
|
||||
: MdiIcons.lockOpen),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
);
|
||||
} else {
|
||||
return SizedBox();
|
||||
|
|
@ -199,7 +199,7 @@ class _DeviceSettingsState extends State<DeviceSettings>
|
|||
value: prefState.persistUI,
|
||||
onChanged: (value) =>
|
||||
viewModel.onPersistUiChanged(context, value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
secondary: Icon(Icons.save_alt),
|
||||
),
|
||||
SwitchListTile(
|
||||
|
|
@ -208,7 +208,7 @@ class _DeviceSettingsState extends State<DeviceSettings>
|
|||
value: prefState.persistData,
|
||||
onChanged: (value) =>
|
||||
viewModel.onPersistDataChanged(context, value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
secondary: Icon(Icons.save_alt),
|
||||
),
|
||||
],
|
||||
|
|
@ -264,7 +264,7 @@ class _DeviceSettingsState extends State<DeviceSettings>
|
|||
secondary: Icon(kIsWeb
|
||||
? Icons.lightbulb_outline
|
||||
: MdiIcons.themeLightDark),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
SizedBox(height: 16),
|
||||
AppDropdownButton<String>(
|
||||
|
|
|
|||
|
|
@ -56,7 +56,7 @@ class _ExpenseSettingsState extends State<ExpenseSettings> {
|
|||
FormCard(
|
||||
children: <Widget>[
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.shouldBeInvoiced),
|
||||
value: company.markExpensesInvoiceable ?? false,
|
||||
subtitle: Text(localization.shouldBeInvoicedHelp),
|
||||
|
|
@ -64,7 +64,7 @@ class _ExpenseSettingsState extends State<ExpenseSettings> {
|
|||
company.rebuild((b) => b..markExpensesInvoiceable = value)),
|
||||
),
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.markPaid),
|
||||
value: company.markExpensesPaid ?? false,
|
||||
subtitle: Text(localization.markPaidHelp),
|
||||
|
|
@ -72,7 +72,7 @@ class _ExpenseSettingsState extends State<ExpenseSettings> {
|
|||
company.rebuild((b) => b..markExpensesPaid = value)),
|
||||
),
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.addDocumentsToInvoice),
|
||||
value: company.invoiceExpenseDocuments ?? false,
|
||||
subtitle: Text(localization.addDocumentsToInvoiceHelp),
|
||||
|
|
@ -94,7 +94,7 @@ class _ExpenseSettingsState extends State<ExpenseSettings> {
|
|||
),
|
||||
SizedBox(height: 16),
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.inclusiveTaxes),
|
||||
value: company.expenseInclusiveTaxes ?? false,
|
||||
subtitle: Text(
|
||||
|
|
|
|||
|
|
@ -333,13 +333,13 @@ class _FileImportState extends State<_FileImport> {
|
|||
if (widget.importType == ImportType.json) {
|
||||
children.addAll([
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.importSettings),
|
||||
value: _importJsonSettings,
|
||||
onChanged: (value) => setState(() => _importJsonSettings = value),
|
||||
),
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.importData),
|
||||
value: _importJsonData,
|
||||
onChanged: (value) => setState(() => _importJsonData = value),
|
||||
|
|
@ -428,7 +428,7 @@ class __FileMapperState extends State<_FileMapper> {
|
|||
|
||||
final List<Widget> children = [
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(AppLocalization.of(context).firstRowAsColumnNames),
|
||||
value: _useFirstRowAsHeaders,
|
||||
onChanged: (value) => setState(() => _useFirstRowAsHeaders = value),
|
||||
|
|
|
|||
|
|
@ -165,7 +165,7 @@ class _InvoiceDesignState extends State<InvoiceDesign>
|
|||
Padding(
|
||||
padding: const EdgeInsets.only(bottom: 8),
|
||||
child: CheckboxListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.updateAllRecords),
|
||||
value: _updateAllInvoiceDesigns,
|
||||
onChanged: (value) => setState(
|
||||
|
|
@ -192,7 +192,7 @@ class _InvoiceDesignState extends State<InvoiceDesign>
|
|||
Padding(
|
||||
padding: const EdgeInsets.only(bottom: 8),
|
||||
child: CheckboxListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.updateAllRecords),
|
||||
value: _updateAllQuoteDesigns,
|
||||
onChanged: (value) => setState(
|
||||
|
|
@ -219,7 +219,7 @@ class _InvoiceDesignState extends State<InvoiceDesign>
|
|||
Padding(
|
||||
padding: const EdgeInsets.only(bottom: 8),
|
||||
child: CheckboxListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.updateAllRecords),
|
||||
value: _updateAllCreditDesigns,
|
||||
onChanged: (value) => setState(
|
||||
|
|
|
|||
|
|
@ -221,7 +221,7 @@ class _LocalizationSettingsState extends State<LocalizationSettings>
|
|||
},
|
||||
title: Text(localization.decimalComma),
|
||||
subtitle: Text(localization.useCommaAsDecimalPlace),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
secondary: isDesktop(context)
|
||||
? Icon(MdiIcons.commaCircle)
|
||||
: null,
|
||||
|
|
|
|||
|
|
@ -54,7 +54,7 @@ class _ProductSettingsState extends State<ProductSettings> {
|
|||
FormCard(
|
||||
children: <Widget>[
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.showProductDiscount),
|
||||
value: company.enableProductDiscount,
|
||||
subtitle: Text(localization.showProductDiscountHelp),
|
||||
|
|
@ -62,7 +62,7 @@ class _ProductSettingsState extends State<ProductSettings> {
|
|||
company.rebuild((b) => b..enableProductDiscount = value)),
|
||||
),
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.showProductCost),
|
||||
value: company.enableProductCost,
|
||||
subtitle: Text(localization.showCostHelp),
|
||||
|
|
@ -70,7 +70,7 @@ class _ProductSettingsState extends State<ProductSettings> {
|
|||
company.rebuild((b) => b..enableProductCost = value)),
|
||||
),
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.showProductQuantity),
|
||||
value: company.enableProductQuantity,
|
||||
subtitle: Text(localization.showProductQuantityHelp),
|
||||
|
|
@ -78,7 +78,7 @@ class _ProductSettingsState extends State<ProductSettings> {
|
|||
company.rebuild((b) => b..enableProductQuantity = value)),
|
||||
),
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.defaultQuantity),
|
||||
value: company.defaultQuantity,
|
||||
subtitle: Text(localization.defaultQuantityHelp),
|
||||
|
|
@ -92,7 +92,7 @@ class _ProductSettingsState extends State<ProductSettings> {
|
|||
children: <Widget>[
|
||||
/*
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.showProductDetails),
|
||||
value: company.showProductDetails,
|
||||
subtitle: Text(localization.showProductDetailsHelp),
|
||||
|
|
@ -101,7 +101,7 @@ class _ProductSettingsState extends State<ProductSettings> {
|
|||
),
|
||||
*/
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.fillProducts),
|
||||
value: company.fillProducts,
|
||||
subtitle: Text(localization.fillProductsHelp),
|
||||
|
|
@ -109,7 +109,7 @@ class _ProductSettingsState extends State<ProductSettings> {
|
|||
company.rebuild((b) => b..fillProducts = value)),
|
||||
),
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.updateProducts),
|
||||
value: company.updateProducts,
|
||||
subtitle: Text(localization.updateProductsHelp),
|
||||
|
|
@ -117,7 +117,7 @@ class _ProductSettingsState extends State<ProductSettings> {
|
|||
company.rebuild((b) => b..updateProducts = value)),
|
||||
),
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.convertProducts),
|
||||
value: company.convertProductExchangeRate ?? false,
|
||||
subtitle: Text(localization.convertProductsHelp),
|
||||
|
|
|
|||
|
|
@ -104,7 +104,7 @@ class _TaskSettingsState extends State<TaskSettings> {
|
|||
if (!viewModel.state.settingsUIState.isFiltered) ...[
|
||||
SizedBox(height: 32),
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.autoStartTasks),
|
||||
value: company.autoStartTasks,
|
||||
subtitle: Text(localization.autoStartTasksHelp),
|
||||
|
|
@ -112,7 +112,7 @@ class _TaskSettingsState extends State<TaskSettings> {
|
|||
company.rebuild((b) => b..autoStartTasks = value)),
|
||||
),
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.showTaskEndDate),
|
||||
value: company.showTaskEndDate,
|
||||
subtitle: Text(localization.showTaskEndDateHelp),
|
||||
|
|
@ -125,7 +125,7 @@ class _TaskSettingsState extends State<TaskSettings> {
|
|||
children: <Widget>[
|
||||
if (!viewModel.state.settingsUIState.isFiltered) ...[
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.showTasksTable),
|
||||
value: company.showTasksTable,
|
||||
subtitle: Text(localization.showTasksTableHelp),
|
||||
|
|
@ -133,7 +133,7 @@ class _TaskSettingsState extends State<TaskSettings> {
|
|||
company.rebuild((b) => b..showTasksTable = value)),
|
||||
),
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.invoiceTaskDatelog),
|
||||
value: company.invoiceTaskDatelog,
|
||||
subtitle: Text(localization.invoiceTaskDatelogHelp),
|
||||
|
|
@ -141,7 +141,7 @@ class _TaskSettingsState extends State<TaskSettings> {
|
|||
company.rebuild((b) => b..invoiceTaskDatelog = value)),
|
||||
),
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.invoiceTaskTimelog),
|
||||
value: company.invoiceTaskTimelog,
|
||||
subtitle: Text(localization.invoiceTaskTimelogHelp),
|
||||
|
|
@ -149,7 +149,7 @@ class _TaskSettingsState extends State<TaskSettings> {
|
|||
company.rebuild((b) => b..invoiceTaskTimelog = value)),
|
||||
),
|
||||
SwitchListTile(
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
title: Text(localization.addDocumentsToInvoice),
|
||||
value: company.invoiceTaskDocuments ?? false,
|
||||
subtitle: Text(localization.addDocumentsToInvoiceHelp),
|
||||
|
|
|
|||
|
|
@ -70,7 +70,7 @@ class SubscriptionListItem extends StatelessWidget {
|
|||
value: isChecked,
|
||||
materialTapTargetSize: MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: null,
|
||||
|
|
|
|||
|
|
@ -135,7 +135,8 @@ class TaskListItem extends StatelessWidget {
|
|||
MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) =>
|
||||
onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor:
|
||||
Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
),
|
||||
)
|
||||
|
|
@ -215,7 +216,7 @@ class TaskListItem extends StatelessWidget {
|
|||
materialTapTargetSize:
|
||||
MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: null,
|
||||
|
|
|
|||
|
|
@ -70,7 +70,7 @@ class TaskStatusListItem extends StatelessWidget {
|
|||
value: isChecked,
|
||||
materialTapTargetSize: MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: null,
|
||||
|
|
|
|||
|
|
@ -66,7 +66,7 @@ class TaxRateListItem extends StatelessWidget {
|
|||
value: isChecked,
|
||||
materialTapTargetSize: MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: null,
|
||||
|
|
|
|||
|
|
@ -69,7 +69,7 @@ class TokenListItem extends StatelessWidget {
|
|||
value: isChecked,
|
||||
materialTapTargetSize: MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: null,
|
||||
|
|
|
|||
|
|
@ -279,7 +279,7 @@ class _UserEditState extends State<UserEdit>
|
|||
value: userCompany.isAdmin ?? false,
|
||||
onChanged: (value) => viewModel.onUserChanged(
|
||||
user.rebuild((b) => b..userCompany.isAdmin = value)),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
],
|
||||
),
|
||||
|
|
@ -450,7 +450,7 @@ class _PermissionCheckbox extends StatelessWidget {
|
|||
? true
|
||||
: (userCompany.permissions ?? '').contains(permission),
|
||||
onChanged: checkAll ? null : onChanged,
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -64,7 +64,7 @@ class UserListItem extends StatelessWidget {
|
|||
value: isChecked,
|
||||
materialTapTargetSize: MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: null,
|
||||
|
|
|
|||
|
|
@ -91,7 +91,8 @@ class VendorListItem extends StatelessWidget {
|
|||
MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) =>
|
||||
onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor:
|
||||
Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
),
|
||||
)
|
||||
|
|
@ -170,7 +171,7 @@ class VendorListItem extends StatelessWidget {
|
|||
materialTapTargetSize:
|
||||
MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: null,
|
||||
|
|
|
|||
|
|
@ -71,7 +71,7 @@ class WebhookListItem extends StatelessWidget {
|
|||
value: isChecked,
|
||||
materialTapTargetSize: MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: null,
|
||||
|
|
|
|||
|
|
@ -76,6 +76,7 @@ dev_dependencies:
|
|||
built_value_generator: ^8.1.1
|
||||
faker: ^2.0.0
|
||||
msix: ^2.1.3
|
||||
import_sorter: ^4.6.0
|
||||
|
||||
flutter:
|
||||
|
||||
|
|
|
|||
|
|
@ -76,6 +76,7 @@ dev_dependencies:
|
|||
built_value_generator: ^8.1.1
|
||||
faker: ^2.0.0
|
||||
msix: ^2.1.3
|
||||
import_sorter: ^4.6.0
|
||||
|
||||
flutter:
|
||||
|
||||
|
|
|
|||
|
|
@ -76,6 +76,7 @@ dev_dependencies:
|
|||
built_value_generator: ^8.1.1
|
||||
faker: ^2.0.0
|
||||
msix: ^2.1.3
|
||||
import_sorter: ^4.6.0
|
||||
|
||||
flutter:
|
||||
|
||||
|
|
|
|||
|
|
@ -63,7 +63,7 @@ class StubListItem extends StatelessWidget {
|
|||
value: isChecked,
|
||||
materialTapTargetSize: MaterialTapTargetSize.shrinkWrap,
|
||||
onChanged: (value) => onCheckboxChanged(value),
|
||||
activeColor: Theme.of(context).accentColor,
|
||||
activeColor: Theme.of(context).colorScheme.secondary,
|
||||
),
|
||||
)
|
||||
: null,
|
||||
|
|
|
|||
Loading…
Reference in New Issue