feat: Umbrix branding - logo and name changes
- Changed app title from Hiddify to Umbrix in home page - Added custom Umbrix logo (192x192 PNG) - Updated intro page with Umbrix branding and gradient design - Updated drawer menu with Umbrix logo - Modified add profile modal with modern gradient cards - Updated Russian translations (appTitle: Umbrix)
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"general": {
|
"general": {
|
||||||
"appTitle": "Hiddify",
|
"appTitle": "Umbrix",
|
||||||
"reset": "Сброс",
|
"reset": "Сброс",
|
||||||
"toggle": {
|
"toggle": {
|
||||||
"enabled": "Включено",
|
"enabled": "Включено",
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
import 'package:fluentui_system_icons/fluentui_system_icons.dart';
|
import 'package:fluentui_system_icons/fluentui_system_icons.dart';
|
||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
import 'package:flutter_adaptive_scaffold/flutter_adaptive_scaffold.dart';
|
import 'package:flutter_adaptive_scaffold/flutter_adaptive_scaffold.dart';
|
||||||
|
import 'package:hiddify/gen/assets.gen.dart';
|
||||||
import 'package:hiddify/core/localization/translations.dart';
|
import 'package:hiddify/core/localization/translations.dart';
|
||||||
import 'package:hiddify/core/router/router.dart';
|
import 'package:hiddify/core/router/router.dart';
|
||||||
import 'package:hiddify/features/stats/widget/side_bar_stats_overview.dart';
|
import 'package:hiddify/features/stats/widget/side_bar_stats_overview.dart';
|
||||||
@@ -123,16 +124,15 @@ class _CustomAdaptiveScaffold extends HookConsumerWidget {
|
|||||||
child: Column(
|
child: Column(
|
||||||
children: [
|
children: [
|
||||||
Container(
|
Container(
|
||||||
width: 96,
|
width: 80,
|
||||||
height: 96,
|
height: 80,
|
||||||
|
padding: const EdgeInsets.all(12),
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
borderRadius: BorderRadius.circular(16),
|
borderRadius: BorderRadius.circular(20),
|
||||||
color: Theme.of(context).colorScheme.primaryContainer,
|
color: Theme.of(context).colorScheme.primaryContainer,
|
||||||
),
|
),
|
||||||
child: Icon(
|
child: Assets.images.umbrixLogo.image(
|
||||||
Icons.shield_outlined,
|
fit: BoxFit.contain,
|
||||||
size: 56,
|
|
||||||
color: Theme.of(context).colorScheme.primary,
|
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
const SizedBox(height: 16),
|
const SizedBox(height: 16),
|
||||||
|
|||||||
@@ -36,7 +36,7 @@ class HomePage extends HookConsumerWidget {
|
|||||||
title: Text.rich(
|
title: Text.rich(
|
||||||
TextSpan(
|
TextSpan(
|
||||||
children: [
|
children: [
|
||||||
TextSpan(text: t.general.appTitle),
|
const TextSpan(text: "Umbrix"),
|
||||||
const TextSpan(text: " "),
|
const TextSpan(text: " "),
|
||||||
const WidgetSpan(
|
const WidgetSpan(
|
||||||
child: AppVersionLabel(),
|
child: AppVersionLabel(),
|
||||||
|
|||||||
@@ -8,6 +8,7 @@ import 'package:hiddify/core/localization/locale_preferences.dart';
|
|||||||
import 'package:hiddify/core/localization/translations.dart';
|
import 'package:hiddify/core/localization/translations.dart';
|
||||||
import 'package:hiddify/core/model/constants.dart';
|
import 'package:hiddify/core/model/constants.dart';
|
||||||
import 'package:hiddify/core/model/region.dart';
|
import 'package:hiddify/core/model/region.dart';
|
||||||
|
import 'package:hiddify/gen/assets.gen.dart';
|
||||||
import 'package:hiddify/core/preferences/general_preferences.dart';
|
import 'package:hiddify/core/preferences/general_preferences.dart';
|
||||||
import 'package:hiddify/features/common/general_pref_tiles.dart';
|
import 'package:hiddify/features/common/general_pref_tiles.dart';
|
||||||
import 'package:hiddify/features/config_option/data/config_option_repository.dart';
|
import 'package:hiddify/features/config_option/data/config_option_repository.dart';
|
||||||
@@ -25,7 +26,7 @@ class IntroPage extends HookConsumerWidget with PresLogger {
|
|||||||
@override
|
@override
|
||||||
Widget build(BuildContext context, WidgetRef ref) {
|
Widget build(BuildContext context, WidgetRef ref) {
|
||||||
final t = ref.watch(translationsProvider);
|
final t = ref.watch(translationsProvider);
|
||||||
|
final theme = Theme.of(context);
|
||||||
final isStarting = useState(false);
|
final isStarting = useState(false);
|
||||||
|
|
||||||
if (!locationInfoLoaded) {
|
if (!locationInfoLoaded) {
|
||||||
@@ -34,37 +35,116 @@ class IntroPage extends HookConsumerWidget with PresLogger {
|
|||||||
}
|
}
|
||||||
|
|
||||||
return Scaffold(
|
return Scaffold(
|
||||||
body: SafeArea(
|
body: Container(
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
gradient: LinearGradient(
|
||||||
|
begin: Alignment.topCenter,
|
||||||
|
end: Alignment.bottomCenter,
|
||||||
|
colors: [
|
||||||
|
theme.colorScheme.surface,
|
||||||
|
theme.colorScheme.surfaceContainerHighest,
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
child: SafeArea(
|
||||||
child: CustomScrollView(
|
child: CustomScrollView(
|
||||||
shrinkWrap: true,
|
shrinkWrap: true,
|
||||||
slivers: [
|
slivers: [
|
||||||
|
// Логотип и заголовок
|
||||||
SliverToBoxAdapter(
|
SliverToBoxAdapter(
|
||||||
child: SizedBox(
|
|
||||||
width: 224,
|
|
||||||
height: 224,
|
|
||||||
child: Padding(
|
child: Padding(
|
||||||
padding: const EdgeInsets.all(24),
|
padding: const EdgeInsets.symmetric(vertical: 32, horizontal: 24),
|
||||||
child: Assets.images.logo.svg(),
|
child: Column(
|
||||||
|
children: [
|
||||||
|
// Логотип с анимацией
|
||||||
|
Hero(
|
||||||
|
tag: 'app_logo',
|
||||||
|
child: Container(
|
||||||
|
width: 120,
|
||||||
|
height: 120,
|
||||||
|
padding: const EdgeInsets.all(16),
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
color: theme.colorScheme.primaryContainer.withOpacity(0.3),
|
||||||
|
borderRadius: BorderRadius.circular(30),
|
||||||
|
boxShadow: [
|
||||||
|
BoxShadow(
|
||||||
|
color: theme.colorScheme.primary.withOpacity(0.2),
|
||||||
|
blurRadius: 20,
|
||||||
|
offset: const Offset(0, 10),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
child: Assets.images.umbrixLogo.image(
|
||||||
|
fit: BoxFit.contain,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
const Gap(24),
|
||||||
|
// Заголовок
|
||||||
|
Text(
|
||||||
|
'Welcome to Umbrix',
|
||||||
|
style: theme.textTheme.headlineMedium?.copyWith(
|
||||||
|
fontWeight: FontWeight.bold,
|
||||||
|
color: theme.colorScheme.onSurface,
|
||||||
|
),
|
||||||
|
textAlign: TextAlign.center,
|
||||||
|
),
|
||||||
|
const Gap(8),
|
||||||
|
Text(
|
||||||
|
'Fast and Secure',
|
||||||
|
style: theme.textTheme.bodyLarge?.copyWith(
|
||||||
|
color: theme.colorScheme.onSurfaceVariant,
|
||||||
|
),
|
||||||
|
textAlign: TextAlign.center,
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
|
||||||
|
// Настройки в виде карточек
|
||||||
SliverCrossAxisConstrained(
|
SliverCrossAxisConstrained(
|
||||||
maxCrossAxisExtent: 368,
|
maxCrossAxisExtent: 400,
|
||||||
child: MultiSliver(
|
child: MultiSliver(
|
||||||
children: [
|
children: [
|
||||||
const LocalePrefTile(),
|
// Язык
|
||||||
const SliverGap(4),
|
|
||||||
const RegionPrefTile(),
|
|
||||||
const SliverGap(4),
|
|
||||||
const EnableAnalyticsPrefTile(),
|
|
||||||
const SliverGap(4),
|
|
||||||
Padding(
|
Padding(
|
||||||
padding: const EdgeInsets.symmetric(horizontal: 16),
|
padding: const EdgeInsets.symmetric(horizontal: 24, vertical: 6),
|
||||||
|
child: _SettingCard(
|
||||||
|
child: const LocalePrefTile(),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
|
||||||
|
// Регион
|
||||||
|
Padding(
|
||||||
|
padding: const EdgeInsets.symmetric(horizontal: 24, vertical: 6),
|
||||||
|
child: _SettingCard(
|
||||||
|
child: const RegionPrefTile(),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
|
||||||
|
// Аналитика
|
||||||
|
Padding(
|
||||||
|
padding: const EdgeInsets.symmetric(horizontal: 24, vertical: 6),
|
||||||
|
child: _SettingCard(
|
||||||
|
child: const EnableAnalyticsPrefTile(),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
|
||||||
|
const SliverGap(16),
|
||||||
|
|
||||||
|
// Условия использования
|
||||||
|
Padding(
|
||||||
|
padding: const EdgeInsets.symmetric(horizontal: 32),
|
||||||
child: Text.rich(
|
child: Text.rich(
|
||||||
t.intro.termsAndPolicyCaution(
|
t.intro.termsAndPolicyCaution(
|
||||||
tap: (text) => TextSpan(
|
tap: (text) => TextSpan(
|
||||||
text: text,
|
text: text,
|
||||||
style: const TextStyle(color: Colors.blue),
|
style: TextStyle(
|
||||||
|
color: theme.colorScheme.primary,
|
||||||
|
fontWeight: FontWeight.w600,
|
||||||
|
decoration: TextDecoration.underline,
|
||||||
|
),
|
||||||
recognizer: TapGestureRecognizer()
|
recognizer: TapGestureRecognizer()
|
||||||
..onTap = () async {
|
..onTap = () async {
|
||||||
await UriUtils.tryLaunch(
|
await UriUtils.tryLaunch(
|
||||||
@@ -73,17 +153,39 @@ class IntroPage extends HookConsumerWidget with PresLogger {
|
|||||||
},
|
},
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
style: Theme.of(context).textTheme.bodySmall,
|
style: theme.textTheme.bodySmall?.copyWith(
|
||||||
|
color: theme.colorScheme.onSurfaceVariant,
|
||||||
|
),
|
||||||
|
textAlign: TextAlign.center,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|
||||||
|
// Кнопка начать
|
||||||
Padding(
|
Padding(
|
||||||
padding: const EdgeInsets.symmetric(
|
padding: const EdgeInsets.fromLTRB(24, 24, 24, 32),
|
||||||
horizontal: 16,
|
child: Container(
|
||||||
vertical: 24,
|
decoration: BoxDecoration(
|
||||||
|
gradient: LinearGradient(
|
||||||
|
colors: [
|
||||||
|
theme.colorScheme.primary,
|
||||||
|
theme.colorScheme.primary.withOpacity(0.8),
|
||||||
|
],
|
||||||
),
|
),
|
||||||
child: FilledButton(
|
borderRadius: BorderRadius.circular(16),
|
||||||
onPressed: () async {
|
boxShadow: [
|
||||||
if (isStarting.value) return;
|
BoxShadow(
|
||||||
|
color: theme.colorScheme.primary.withOpacity(0.4),
|
||||||
|
blurRadius: 12,
|
||||||
|
offset: const Offset(0, 6),
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
child: Material(
|
||||||
|
color: Colors.transparent,
|
||||||
|
child: InkWell(
|
||||||
|
onTap: isStarting.value
|
||||||
|
? null
|
||||||
|
: () async {
|
||||||
isStarting.value = true;
|
isStarting.value = true;
|
||||||
if (!ref.read(analyticsControllerProvider).requireValue) {
|
if (!ref.read(analyticsControllerProvider).requireValue) {
|
||||||
loggy.info("disabling analytics per user request");
|
loggy.info("disabling analytics per user request");
|
||||||
@@ -99,12 +201,41 @@ class IntroPage extends HookConsumerWidget with PresLogger {
|
|||||||
}
|
}
|
||||||
await ref.read(Preferences.introCompleted.notifier).update(true);
|
await ref.read(Preferences.introCompleted.notifier).update(true);
|
||||||
},
|
},
|
||||||
|
borderRadius: BorderRadius.circular(16),
|
||||||
|
child: Container(
|
||||||
|
height: 56,
|
||||||
|
alignment: Alignment.center,
|
||||||
child: isStarting.value
|
child: isStarting.value
|
||||||
? LinearProgressIndicator(
|
? SizedBox(
|
||||||
backgroundColor: Colors.transparent,
|
width: 24,
|
||||||
color: Theme.of(context).colorScheme.onSurface,
|
height: 24,
|
||||||
|
child: CircularProgressIndicator(
|
||||||
|
strokeWidth: 3,
|
||||||
|
valueColor: AlwaysStoppedAnimation<Color>(
|
||||||
|
theme.colorScheme.onPrimary,
|
||||||
|
),
|
||||||
|
),
|
||||||
)
|
)
|
||||||
: Text(t.intro.start),
|
: Row(
|
||||||
|
mainAxisAlignment: MainAxisAlignment.center,
|
||||||
|
children: [
|
||||||
|
Text(
|
||||||
|
t.intro.start,
|
||||||
|
style: theme.textTheme.titleMedium?.copyWith(
|
||||||
|
color: theme.colorScheme.onPrimary,
|
||||||
|
fontWeight: FontWeight.bold,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
const Gap(8),
|
||||||
|
Icon(
|
||||||
|
Icons.arrow_forward_rounded,
|
||||||
|
color: theme.colorScheme.onPrimary,
|
||||||
|
),
|
||||||
|
],
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
),
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
],
|
],
|
||||||
@@ -113,6 +244,7 @@ class IntroPage extends HookConsumerWidget with PresLogger {
|
|||||||
],
|
],
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
),
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -185,3 +317,29 @@ class RegionLocale {
|
|||||||
|
|
||||||
RegionLocale(this.region, this.locale);
|
RegionLocale(this.region, this.locale);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Карточка для настроек
|
||||||
|
class _SettingCard extends StatelessWidget {
|
||||||
|
const _SettingCard({required this.child});
|
||||||
|
|
||||||
|
final Widget child;
|
||||||
|
|
||||||
|
@override
|
||||||
|
Widget build(BuildContext context) {
|
||||||
|
final theme = Theme.of(context);
|
||||||
|
|
||||||
|
return Container(
|
||||||
|
decoration: BoxDecoration(
|
||||||
|
color: theme.colorScheme.surfaceContainerHighest.withOpacity(0.5),
|
||||||
|
borderRadius: BorderRadius.circular(16),
|
||||||
|
border: Border.all(
|
||||||
|
color: theme.colorScheme.outline.withOpacity(0.1),
|
||||||
|
),
|
||||||
|
),
|
||||||
|
child: ClipRRect(
|
||||||
|
borderRadius: BorderRadius.circular(16),
|
||||||
|
child: child,
|
||||||
|
),
|
||||||
|
);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|||||||
@@ -124,6 +124,7 @@ flutter:
|
|||||||
# - assets/core/geoip.db
|
# - assets/core/geoip.db
|
||||||
# - assets/core/geosite.db
|
# - assets/core/geosite.db
|
||||||
- assets/images/logo.svg
|
- assets/images/logo.svg
|
||||||
|
- assets/images/umbrix_logo.png
|
||||||
- assets/images/tray_icon.ico
|
- assets/images/tray_icon.ico
|
||||||
- assets/images/tray_icon.png
|
- assets/images/tray_icon.png
|
||||||
- assets/images/tray_icon_dark.ico
|
- assets/images/tray_icon_dark.ico
|
||||||
|
|||||||
Reference in New Issue
Block a user