TF-355 Fix the empty mailbox message not correct when filtering

This commit is contained in:
dab246
2023-01-27 17:11:44 +07:00
committed by Dat Vu
parent 16d360bb00
commit c51ece70f2
9 changed files with 265 additions and 83 deletions
-9
View File
@@ -1,9 +0,0 @@
<svg width="122" height="100" viewBox="0 0 122 100" fill="none" xmlns="http://www.w3.org/2000/svg">
<path d="M60.6033 99.4921C85.237 99.4921 105.207 95.7607 105.207 91.1579C105.207 86.555 85.237 82.8237 60.6033 82.8237C35.9696 82.8237 16 86.555 16 91.1579C16 95.7607 35.9696 99.4921 60.6033 99.4921Z" fill="#F5F5F7" fill-opacity="0.8"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M96.2855 66.6737L80.5454 47.3019C79.7902 46.3901 78.6862 45.8381 77.5237 45.8381H43.6816C42.5198 45.8381 41.4158 46.3901 40.6606 47.3019L24.9211 66.6737V76.7941H96.2862V66.6737H96.2855Z" fill="#AEB8C2"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M38.2566 20.8355H82.9493C83.6473 20.8355 84.3166 21.1128 84.8102 21.6063C85.3037 22.0998 85.5809 22.7692 85.5809 23.4671V84.8776C85.5809 85.5755 85.3037 86.2449 84.8102 86.7384C84.3166 87.2319 83.6473 87.5092 82.9493 87.5092H38.2566C37.5586 87.5092 36.8893 87.2319 36.3958 86.7384C35.9023 86.2449 35.625 85.5755 35.625 84.8776V23.4671C35.625 22.7692 35.9023 22.0998 36.3958 21.6063C36.8893 21.1128 37.5586 20.8355 38.2566 20.8355V20.8355Z" fill="#F5F5F7"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M44.0777 27.3835H77.1283C77.4773 27.3835 77.812 27.5222 78.0587 27.7689C78.3055 28.0157 78.4441 28.3504 78.4441 28.6993V45.1184C78.4441 45.4674 78.3055 45.8021 78.0587 46.0488C77.812 46.2956 77.4773 46.4342 77.1283 46.4342H44.0777C43.7287 46.4342 43.394 46.2956 43.1472 46.0488C42.9005 45.8021 42.7619 45.4674 42.7619 45.1184V28.6993C42.7619 28.3504 42.9005 28.0157 43.1472 27.7689C43.394 27.5222 43.7287 27.3835 44.0777 27.3835ZM44.25 53.577H76.9559C77.3506 53.577 77.7291 53.7338 78.0082 54.0128C78.2873 54.2919 78.4441 54.6704 78.4441 55.0651C78.4441 55.4598 78.2873 55.8383 78.0082 56.1174C77.7291 56.3965 77.3506 56.5533 76.9559 56.5533H44.25C43.8553 56.5533 43.4768 56.3965 43.1977 56.1174C42.9186 55.8383 42.7619 55.4598 42.7619 55.0651C42.7619 54.6704 42.9186 54.2919 43.1977 54.0128C43.4768 53.7338 43.8553 53.577 44.25 53.577ZM44.25 61.3158H76.9559C77.3507 61.3158 77.7293 61.4726 78.0085 61.7518C78.2876 62.0309 78.4444 62.4095 78.4444 62.8043C78.4444 63.199 78.2876 63.5776 78.0085 63.8568C77.7293 64.1359 77.3507 64.2928 76.9559 64.2928H44.25C43.8552 64.2928 43.4766 64.1359 43.1975 63.8568C42.9184 63.5776 42.7615 63.199 42.7615 62.8043C42.7615 62.4095 42.9184 62.0309 43.1975 61.7518C43.4766 61.4726 43.8552 61.3158 44.25 61.3158ZM96.1402 89.9355C95.6303 91.9559 93.8395 93.4618 91.7092 93.4618H29.4967C27.3665 93.4618 25.5757 91.9553 25.0665 89.9355C24.9693 89.5505 24.9203 89.1549 24.9204 88.7579V66.6743H42.2349C44.1474 66.6743 45.6888 68.2849 45.6888 70.2401V70.2664C45.6888 72.221 47.248 73.7993 49.1605 73.7993H72.0454C73.9579 73.7993 75.5171 72.2066 75.5171 70.2513V70.2434C75.5171 68.2881 77.0586 66.6737 78.9711 66.6737H96.2855V88.7585C96.2855 89.1645 96.2349 89.5585 96.1402 89.9355Z" fill="#DCE0E6"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M98.3165 21.9026L93.823 23.6461C93.7076 23.6909 93.5818 23.7023 93.4602 23.6789C93.3386 23.6555 93.2261 23.5982 93.1356 23.5137C93.045 23.4292 92.9802 23.3208 92.9486 23.2011C92.9169 23.0813 92.9197 22.9551 92.9566 22.8368L94.2309 18.7533C92.5276 16.8164 91.5276 14.4546 91.5276 11.9059C91.5276 5.33026 98.1842 0 106.396 0C114.606 0 121.263 5.33026 121.263 11.9059C121.263 18.4816 114.607 23.8118 106.395 23.8118C103.416 23.8118 100.643 23.1105 98.3165 21.9026Z" fill="#DCE0E6"/>
<path d="M112.253 14.0559C113.288 14.0559 114.127 13.2268 114.127 12.204C114.127 11.1811 113.288 10.352 112.253 10.352C111.217 10.352 110.378 11.1811 110.378 12.204C110.378 13.2268 111.217 14.0559 112.253 14.0559Z" fill="white"/>
<path fill-rule="evenodd" clip-rule="evenodd" d="M102.413 13.8243H98.6644L100.571 10.5836L102.413 13.8243ZM104.756 10.5836H108.035V13.8243H104.756V10.5836Z" fill="white"/>
</svg>

Before

Width:  |  Height:  |  Size: 3.7 KiB

+87
View File
@@ -0,0 +1,87 @@
<svg width="212" height="212" viewBox="0 0 212 212" fill="none" xmlns="http://www.w3.org/2000/svg">
<defs>
<linearGradient id="paint0_linear_5128_231333" x1="138.5" y1="128.5" x2="138.5" y2="-13"
gradientUnits="userSpaceOnUse">
<stop stop-color="#B4BDC9" />
<stop offset="1" stop-color="#DEE6F0" />
</linearGradient>
<linearGradient id="paint1_linear_5128_231333" x1="73.8434" y1="55.5" x2="73.8434"
y2="140.921" gradientUnits="userSpaceOnUse">
<stop offset="0.00718201" stop-color="#818C99" />
<stop offset="1" stop-color="#818C99" stop-opacity="0" />
</linearGradient>
<linearGradient id="paint2_linear_5128_231333" x1="75" y1="157.702" x2="75" y2="203"
gradientUnits="userSpaceOnUse">
<stop offset="0.00718201" stop-color="#D7E0EA" />
<stop offset="1" stop-color="#9DA0A4" />
</linearGradient>
<linearGradient id="paint3_linear_5128_231333" x1="39.5" y1="158.097" x2="54" y2="197"
gradientUnits="userSpaceOnUse">
<stop offset="0.00718201" stop-color="#D7E0EA" />
<stop offset="1" stop-color="#9DA0A4" />
</linearGradient>
<linearGradient id="paint4_linear_5128_231333" x1="103" y1="179.139" x2="103" y2="215"
gradientUnits="userSpaceOnUse">
<stop offset="0.00718201" stop-color="#D7E0EA" />
<stop offset="1" stop-color="#9DA0A4" />
</linearGradient>
</defs>
<path
d="M195.991 106.095C195.991 118.72 193.419 130.725 188.702 141.635C188.464 142.254 188.178 142.826 187.893 143.445C178.841 163.311 162.834 179.319 142.92 188.275C142.348 188.513 141.777 188.799 141.205 189.037C141.157 189.037 141.11 189.085 141.062 189.085C137.632 190.514 134.107 191.8 130.486 192.801C127.818 193.563 125.15 194.182 122.435 194.706C121.672 194.849 120.91 194.992 120.1 195.088C119.433 195.183 118.719 195.278 118.052 195.373H118.004C117.242 195.469 116.48 195.564 115.717 195.659C115.384 195.707 115.098 195.707 114.764 195.755C113.955 195.85 113.145 195.897 112.335 195.945C111.954 195.993 111.573 195.993 111.191 196.04C110.239 196.088 109.238 196.136 108.285 196.183C107.476 196.183 106.666 196.231 105.856 196.231C67.4099 196.231 34.6333 172.173 21.6751 138.3C21.3416 137.347 20.9604 136.442 20.6746 135.489C17.4827 126.295 15.7676 116.386 15.7676 106.143C15.8153 56.311 56.1667 16.0071 105.903 16.0071C155.64 16.0071 195.991 56.311 195.991 106.095Z"
fill="#F2F3F5" />
<path
d="M142.968 136.299V188.275C142.396 188.513 141.824 188.799 141.253 189.037C141.205 189.037 141.157 189.085 141.11 189.085C137.68 190.514 134.154 191.8 130.534 192.801V136.299H142.968Z"
fill="#818C99" />
<path
d="M180.271 145.685C178.985 146.351 177.603 147.114 176.222 147.876C175.555 148.257 174.888 148.638 174.173 149.067C167.932 149.782 163.74 148.733 160.643 145.685H157.832C153.926 148.114 150.258 149.972 147.209 147.352C147.352 146.78 147.495 146.209 147.637 145.685H146.304C146.208 146.113 146.065 146.59 145.97 147.114C143.302 148.305 141.254 148.781 139.396 148.591C139.396 147.542 139.396 146.59 139.396 145.732H138.157C138.109 155.117 138.205 173.888 139.348 184.511C139.348 184.607 139.348 184.702 139.3 184.797H139.348C139.539 186.56 139.777 188.085 140.015 189.323L141.111 189.085L141.301 189.037C141.301 189.037 141.301 189.037 141.301 188.99C141.063 187.799 140.825 186.274 140.634 184.464C140.825 183.035 141.015 181.701 141.206 180.367L141.301 180.414C141.492 179.747 141.73 179.08 142.016 178.414L142.064 178.461C154.259 162.311 171.458 151.687 183.225 145.732H180.271V145.685ZM146.923 148.734C149.924 150.973 153.307 149.782 156.737 147.876C155.498 149.782 154.117 151.925 152.735 154.165C150.162 155.117 148.066 154.593 146.065 152.497C146.351 151.163 146.637 149.877 146.923 148.734ZM151.735 155.784C150.401 158.023 149.019 160.358 147.733 162.787C146.161 162.93 145.017 162.549 144.207 161.501C144.731 158.738 145.255 156.213 145.732 153.974C147.542 155.641 149.543 156.213 151.735 155.784ZM139.443 149.877C141.254 150.02 143.207 149.639 145.637 148.686C145.351 149.829 145.065 151.116 144.779 152.449C143.207 154.784 141.444 156.022 139.491 156.165C139.443 153.926 139.443 151.782 139.443 149.877ZM139.491 157.452C141.206 157.309 142.778 156.547 144.16 155.165C143.731 157.118 143.35 159.214 142.921 161.501C142.445 163.026 141.873 163.883 141.158 164.217C140.73 164.407 140.206 164.407 139.634 164.217C139.539 161.882 139.491 159.643 139.491 157.452ZM140.11 178.461C139.872 174.507 139.729 169.981 139.586 165.551C140.348 165.741 141.015 165.694 141.635 165.408C141.825 165.312 142.064 165.217 142.254 165.027C141.539 169.028 140.825 173.507 140.11 178.461ZM141.968 174.698C142.635 170.458 143.255 166.551 143.921 163.073C144.779 163.74 145.779 164.121 147.018 164.121C145.16 167.599 143.445 171.22 141.968 174.698ZM143.445 174.507C144.827 171.22 146.494 167.837 148.209 164.55C148.971 165.265 150.115 165.646 151.639 165.789C148.828 168.457 146.065 171.363 143.445 174.507ZM152.973 164.55C150.925 164.55 149.591 164.169 148.876 163.359C150.305 160.691 151.83 158.119 153.307 155.689C155.165 157.118 157.451 158.071 160.215 158.5C157.832 160.358 155.355 162.406 152.973 164.55ZM161.691 157.404C158.499 157.071 155.927 156.165 153.974 154.593C155.879 151.497 157.737 148.638 159.262 146.351C159.309 146.351 159.357 146.304 159.357 146.256C162.597 149.734 166.694 150.639 170.505 150.639C170.886 150.639 171.267 150.639 171.601 150.591C168.552 152.545 165.169 154.784 161.691 157.404Z"
fill="#818C99" />
<path
d="M130.534 136.299V192.801C127.866 193.563 125.198 194.182 122.483 194.706C121.721 194.849 120.958 194.992 120.148 195.087C119.481 195.183 118.767 195.278 118.1 195.373V136.299H130.534Z"
fill="#B4BDC9" />
<path opacity="0.12" d="M142.968 139.634H130.534V154.593H142.968V139.634Z" fill="black" />
<path opacity="0.06" d="M130.487 139.634H118.053V154.593H130.487V139.634Z" fill="black" />
<path
d="M198.232 88.4207V145.732H10.4807C9.81369 145.732 9.242 145.446 8.81324 145.018C8.38448 144.589 8.09863 143.969 8.09863 143.35C8.09863 142.016 9.14672 140.968 10.4807 140.968H30.442V88.4207C30.442 64.8387 49.6411 45.6396 73.2231 45.6396H155.451C179.033 45.6396 198.232 64.8387 198.232 88.4207Z"
fill="url(#paint0_linear_5128_231333)" />
<path opacity="0.06"
d="M190.372 63.7431H103.38C101.237 61.2181 98.7117 58.9314 95.9485 57.0734H184.512C186.704 59.0743 188.657 61.3134 190.372 63.7431Z"
fill="white" />
<path opacity="0.06"
d="M181.748 54.6912H91.9934C90.85 54.1195 89.7066 53.5478 88.468 53.0714H179.509C180.271 53.5954 181.033 54.1195 181.748 54.6912Z"
fill="white" />
<path opacity="0.2"
d="M139.633 106.333C144.921 106.333 149.208 102.046 149.208 96.7577C149.208 91.4692 144.921 87.182 139.633 87.182C134.344 87.182 130.057 91.4692 130.057 96.7577C130.057 102.046 134.344 106.333 139.633 106.333Z"
fill="black" />
<path
d="M141.206 104.714C146.495 104.714 150.782 100.427 150.782 95.138C150.782 89.8495 146.495 85.5623 141.206 85.5623C135.918 85.5623 131.631 89.8495 131.631 95.138C131.631 100.427 135.918 104.714 141.206 104.714Z"
fill="#B4BDC9" />
<path
d="M168.362 50.6895L159.93 40.9233L168.362 31.157H144.065H138.587H138.396V91.9462C137.491 92.7084 136.919 93.8518 136.919 95.1381C136.919 97.5201 138.825 99.4257 141.207 99.4257C143.589 99.4257 145.494 97.5201 145.494 95.1381C145.494 93.8518 144.923 92.7084 144.018 91.9462V50.6895H168.362Z"
fill="#818C99" />
<path
d="M117.243 88.4207V140.968H30.4423V88.4207C30.4423 64.8387 49.6414 45.6396 73.2234 45.6396H74.4621C98.0441 45.6396 117.243 64.8387 117.243 88.4207Z"
fill="#D2D8DF" />
<path
d="M112.48 140.921H35.207V88.4208C35.207 67.4114 52.2146 50.4038 73.224 50.4038H74.4627C95.4721 50.4038 112.48 67.4114 112.48 88.4208V140.921Z"
fill="url(#paint1_linear_5128_231333)" />
<mask id="mask0_5128_231333" style="mask-type:alpha" x="15" y="16"
width="181" height="181">
<path
d="M195.991 106.095C195.991 118.72 193.419 130.725 188.702 141.635C188.464 142.254 188.178 142.826 187.893 143.445C178.841 163.311 162.834 179.319 142.92 188.275C142.348 188.513 141.777 188.799 141.205 189.037C141.157 189.037 141.11 189.085 141.062 189.085C137.632 190.514 134.107 191.8 130.486 192.801C127.818 193.563 125.15 194.182 122.435 194.706C121.672 194.849 120.91 194.992 120.1 195.088C119.433 195.183 118.719 195.278 118.052 195.373H118.004C117.242 195.469 116.48 195.564 115.717 195.659C115.384 195.707 115.098 195.707 114.764 195.755C113.955 195.85 113.145 195.897 112.335 195.945C111.954 195.993 111.573 195.993 111.191 196.04C110.239 196.088 109.238 196.136 108.285 196.183C107.476 196.183 106.666 196.231 105.856 196.231C67.4099 196.231 34.6333 172.173 21.6751 138.3C21.3416 137.347 20.9604 136.442 20.6746 135.489C17.4827 126.295 15.7676 116.386 15.7676 106.143C15.8153 56.311 56.1667 16.0071 105.903 16.0071C155.64 16.0071 195.991 56.311 195.991 106.095Z"
fill="#F2F3F5" />
</mask>
<g mask="url(#mask0_5128_231333)">
<circle cx="75" cy="179" r="24" fill="url(#paint2_linear_5128_231333)" />
<circle cx="39.5" cy="182.5" r="27.5" fill="url(#paint3_linear_5128_231333)" />
<circle cx="103" cy="196" r="19" fill="url(#paint4_linear_5128_231333)" />
</g>
<path
d="M49 41C50.1046 41 51 40.1046 51 39V18C51 16.8954 50.1046 16 49 16C47.8954 16 47 16.8954 47 18V39C47 40.1046 47.8954 41 49 41Z"
fill="#AAB5C8" />
<path
d="M32.0294 48.0294C32.8104 47.2484 32.8104 45.9821 32.0294 45.201L17.1801 30.3518C16.3991 29.5707 15.1328 29.5707 14.3517 30.3518C13.5707 31.1328 13.5707 32.3992 14.3517 33.1802L29.201 48.0294C29.982 48.8105 31.2483 48.8105 32.0294 48.0294Z"
fill="#AAB5C8" />
<path
d="M25 65C25 63.8954 24.1046 63 23 63H2C0.895432 63 0 63.8954 0 65C0 66.1046 0.895432 67 2 67H23C24.1046 67 25 66.1046 25 65Z"
fill="#AAB5C8" />
</svg>

After

Width:  |  Height:  |  Size: 9.9 KiB

@@ -171,6 +171,7 @@ extension AppColor on Color {
static const colorThumbScrollBar = Color(0xFFAEB7C2);
static const colorCreateNewIdentityButton = Color(0xFFEBEDF0);
static const colorSpamReportBox = Color(0xFFBFDEFF);
static const colorSubtitle = Color(0xFF6D7885);
static const mapGradientColor = [
[Color(0xFF21D4FD), Color(0xFFB721FF)],
@@ -12,7 +12,7 @@ class ImagePaths {
String get icDownload => _getImagePath('ic_download.svg');
String get icMore => _getImagePath('ic_more.svg');
String get icPhotoLibrary => _getImagePath('ic_photo_library.svg');
String get icEmptyImageDefault => _getImagePath('empty_image_default.svg');
String get icEmptyEmail => _getImagePath('ic_empty_email.svg');
String get icStar => _getImagePath('ic_star.svg');
String get icUnStar => _getImagePath('ic_unstar.svg');
String get icAttachment => _getImagePath('ic_attachment.svg');
@@ -1,55 +1,85 @@
import 'package:core/core.dart';
import 'package:flutter/widgets.dart';
import 'package:core/presentation/extensions/color_extension.dart';
import 'package:core/presentation/utils/responsive_utils.dart';
import 'package:flutter/material.dart';
import 'package:flutter_svg/flutter_svg.dart';
class BackgroundWidgetBuilder {
Key? _key;
SvgPicture? _image;
String? _text;
class BackgroundWidgetBuilder extends StatelessWidget {
final BuildContext _context;
final ResponsiveUtils responsiveUtils;
final String title;
final String? iconSVG;
final String? subTitle;
final double? maxWidth;
BackgroundWidgetBuilder(this._context);
const BackgroundWidgetBuilder(
this.title,
this.responsiveUtils, {
Key? key,
this.iconSVG,
this.subTitle,
this.maxWidth
}) : super(key: key);
void key(Key key) {
_key = key;
}
void image(SvgPicture image) {
_image = image;
}
void text(String text) {
_text = text;
}
Widget build() {
@override
Widget build(BuildContext context) {
return Center(
key: _key ?? const Key('BackgroundWidgetBuilder'),
child: CustomScrollView(
slivers: [
SliverFillRemaining(
child: SizedBox(
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
crossAxisAlignment: CrossAxisAlignment.center,
children: [
_image ?? const SizedBox.shrink(),
Padding(
padding: EdgeInsets.only(top: _image != null ? 16 : 0),
child: Text(
_text ?? '',
style: const TextStyle(color: AppColor.baseTextColor, fontSize: 16),
textAlign: TextAlign.center,
key: const Key('background_widget'),
child: SizedBox(
width: maxWidth ?? 360,
child: CustomScrollView(
slivers: [
SliverFillRemaining(
child: Container(
color: Colors.transparent,
padding: const EdgeInsets.symmetric(horizontal: 12),
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
crossAxisAlignment: CrossAxisAlignment.center,
children: [
if (iconSVG != null)
SvgPicture.asset(
iconSVG!,
width: responsiveUtils.isLandscapeMobile(context)
? 120
: 212,
height: responsiveUtils.isLandscapeMobile(context)
? 120
: 212,
fit: BoxFit.fill
),
Padding(
padding: EdgeInsets.only(top: iconSVG != null ? 12 : 0),
child: Text(
title,
style: const TextStyle(
color: Colors.black,
fontSize: 20,
fontWeight: FontWeight.normal
),
textAlign: TextAlign.center,
),
),
),
],
if (subTitle != null)
Padding(
padding: const EdgeInsets.only(top: 12),
child: Text(
subTitle!,
style: const TextStyle(
color: AppColor.colorSubtitle,
fontSize: 15,
fontWeight: FontWeight.normal
),
textAlign: TextAlign.center,
),
)
],
),
height: MediaQuery.of(context).size.height,
),
height: MediaQuery.of(_context).size.height,
),
)
]
)
]
),
)
);
}
@@ -392,14 +392,11 @@ class SearchEmailView extends GetWidget<SearchEmailController>
return Obx(() => controller.viewState.value.fold(
(failure) => const SizedBox.shrink(),
(success) => success is! SearchingState
? (BackgroundWidgetBuilder(context)
..image(SvgPicture.asset(
_imagePaths.icEmptyImageDefault,
width: 120,
height: 120,
fit: BoxFit.fill))
..text(AppLocalizations.of(context).no_emails_matching_your_search))
.build()
? BackgroundWidgetBuilder(
AppLocalizations.of(context).no_emails_matching_your_search,
controller.responsiveUtils,
iconSVG: _imagePaths.icEmptyEmail
)
: const SizedBox.shrink())
);
}
@@ -289,7 +289,6 @@ class ThreadView extends GetWidget<ThreadController>
padding: EdgeInsets.zero,
color: Colors.white,
child: Obx(() {
log('ThreadView::_buildListEmail():');
return Visibility(
visible: controller.openingEmail.isFalse,
child: _buildResultListEmail(context, controller.mailboxDashBoardController.emailsInCurrentMailbox));
@@ -429,17 +428,37 @@ class ThreadView extends GetWidget<ThreadController>
return Obx(() => controller.viewState.value.fold(
(failure) => const SizedBox.shrink(),
(success) => success is! LoadingState && success is! SearchingState
? (BackgroundWidgetBuilder(context)
..key(const Key('empty_email_background'))
..image(SvgPicture.asset(_imagePaths.icEmptyImageDefault, width: 120, height: 120, fit: BoxFit.fill))
..text(controller.isSearchActive()
? AppLocalizations.of(context).no_emails_matching_your_search
: AppLocalizations.of(context).no_emails))
.build()
? BackgroundWidgetBuilder(
_getMessageEmptyEmail(context),
controller.responsiveUtils,
iconSVG: _imagePaths.icEmptyEmail,
subTitle: _getSubMessageEmptyEmail(context),
)
: const SizedBox.shrink())
);
}
String _getMessageEmptyEmail(BuildContext context) {
if (controller.isSearchActive()) {
return AppLocalizations.of(context).no_emails_matching_your_search;
} else {
if (controller.mailboxDashBoardController.filterMessageOption.value == FilterMessageOption.all) {
return AppLocalizations.of(context).noEmailInYourCurrentMailbox;
} else {
return AppLocalizations.of(context).noEmailMatchYourCurrentFilter;
}
}
}
String? _getSubMessageEmptyEmail(BuildContext context) {
if (!controller.isSearchActive()
&& controller.mailboxDashBoardController.filterMessageOption.value != FilterMessageOption.all) {
return AppLocalizations.of(context).reduceSomeFiltersAndTryAgain;
} else {
return null;
}
}
bool supportEmptyTrash(BuildContext context) {
return controller.isMailboxTrash
&& controller.mailboxDashBoardController.emailsInCurrentMailbox.isNotEmpty
+53 -7
View File
@@ -1,5 +1,5 @@
{
"@@last_modified": "2023-01-16T10:06:45.070370",
"@@last_modified": "2023-01-27T17:10:17.205660",
"initializing_data": "Initializing data...",
"@initializing_data": {
"type": "text",
@@ -150,12 +150,6 @@
"placeholders_order": [],
"placeholders": {}
},
"no_emails": "No emails in this mailbox",
"@no_emails": {
"type": "text",
"placeholders_order": [],
"placeholders": {}
},
"no_mail_selected": "No email selected",
"@no_mail_selected": {
"type": "text",
@@ -2598,10 +2592,62 @@
"placeholders_order": [],
"placeholders": {}
},
"countNewSpamEmails": "You have {count} new spam emails!",
"@countNewSpamEmails": {
"type": "text",
"placeholders_order": [
"count"
],
"placeholders": {
"count": {}
}
},
"showDetails": "Show Details",
"@showDetails": {
"type": "text",
"placeholders_order": [],
"placeholders": {}
},
"dismiss": "Dismiss",
"@dismiss": {
"type": "text",
"placeholders_order": [],
"placeholders": {}
},
"disableSpamReport": "Disable Spam report",
"@disableSpamReport": {
"type": "text",
"placeholders_order": [],
"placeholders": {}
},
"enableSpamReport": "Enable Spam report",
"@enableSpamReport": {
"type": "text",
"placeholders_order": [],
"placeholders": {}
},
"required": "required",
"@required": {
"type": "text",
"placeholders_order": [],
"placeholders": {}
},
"noEmailInYourCurrentMailbox": "We're sorry, there are no emails in your current mailbox",
"@noEmailInYourCurrentMailbox": {
"type": "text",
"placeholders_order": [],
"placeholders": {}
},
"noEmailMatchYourCurrentFilter": "We're sorry, there are no emails that match your current filter.",
"@noEmailMatchYourCurrentFilter": {
"type": "text",
"placeholders_order": [],
"placeholders": {}
},
"reduceSomeFiltersAndTryAgain": "Let's reduce some filters and try again",
"@reduceSomeFiltersAndTryAgain": {
"type": "text",
"placeholders_order": [],
"placeholders": {}
}
}
+18 -7
View File
@@ -152,13 +152,6 @@ class AppLocalizations {
);
}
String get no_emails {
return Intl.message(
'No emails in this mailbox',
name: 'no_emails',
);
}
String get no_mail_selected {
return Intl.message(
'No email selected',
@@ -2708,4 +2701,22 @@ class AppLocalizations {
'required',
name: 'required');
}
String get noEmailInYourCurrentMailbox {
return Intl.message(
'We\'re sorry, there are no emails in your current mailbox',
name: 'noEmailInYourCurrentMailbox');
}
String get noEmailMatchYourCurrentFilter {
return Intl.message(
'We\'re sorry, there are no emails that match your current filter.',
name: 'noEmailMatchYourCurrentFilter');
}
String get reduceSomeFiltersAndTryAgain {
return Intl.message(
'Let\'s reduce some filters and try again',
name: 'reduceSomeFiltersAndTryAgain');
}
}