Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
elixxir
xx messenger iOS
Commits
510dcf16
Commit
510dcf16
authored
May 23, 2022
by
Bruno Muniz
🍎
Browse files
Merge branch 'development' into 'master'
Development 2.1 version release See merge request
!29
parents
fca1754c
7276c312
Changes
189
Hide whitespace changes
Inline
Side-by-side
App/client-ios.xcodeproj/project.pbxproj
View file @
510dcf16
...
...
@@ -448,7 +448,7 @@
CODE_SIGN_ENTITLEMENTS
=
"client-ios/Resources/client-ios.entitlements"
;
CODE_SIGN_IDENTITY
=
"Apple Development"
;
CODE_SIGN_STYLE
=
Automatic
;
CURRENT_PROJECT_VERSION
=
58
;
CURRENT_PROJECT_VERSION
=
67
;
DEBUG_INFORMATION_FORMAT
=
"dwarf-with-dsym"
;
DEVELOPMENT_TEAM
=
S6JDM2WW29
;
ENABLE_BITCODE
=
NO
;
...
...
@@ -463,7 +463,7 @@
"$(inherited)"
,
"@executable_path/Frameworks"
,
);
MARKETING_VERSION
=
1.0.
8
;
MARKETING_VERSION
=
1.0.
9
;
OTHER_SWIFT_FLAGS
=
"$(inherited)"
;
PRODUCT_BUNDLE_IDENTIFIER
=
xx.messenger.mock
;
PRODUCT_NAME
=
"$(TARGET_NAME)"
;
...
...
@@ -487,7 +487,7 @@
CODE_SIGN_ENTITLEMENTS
=
"client-ios/Resources/client-ios.entitlements"
;
CODE_SIGN_IDENTITY
=
"Apple Development"
;
CODE_SIGN_STYLE
=
Automatic
;
CURRENT_PROJECT_VERSION
=
58
;
CURRENT_PROJECT_VERSION
=
67
;
DEBUG_INFORMATION_FORMAT
=
"dwarf-with-dsym"
;
DEVELOPMENT_TEAM
=
S6JDM2WW29
;
ENABLE_BITCODE
=
NO
;
...
...
@@ -503,7 +503,7 @@
"$(inherited)"
,
"@executable_path/Frameworks"
,
);
MARKETING_VERSION
=
1.0.
8
;
MARKETING_VERSION
=
1.0.
9
;
OTHER_SWIFT_FLAGS
=
""
;
PRODUCT_BUNDLE_IDENTIFIER
=
xx.messenger
;
PRODUCT_NAME
=
"$(TARGET_NAME)"
;
...
...
@@ -522,7 +522,7 @@
CODE_SIGN_ENTITLEMENTS
=
NotificationExtension/NotificationExtension.entitlements
;
CODE_SIGN_IDENTITY
=
"Apple Development"
;
CODE_SIGN_STYLE
=
Automatic
;
CURRENT_PROJECT_VERSION
=
58
;
CURRENT_PROJECT_VERSION
=
67
;
DEVELOPMENT_TEAM
=
S6JDM2WW29
;
ENABLE_BITCODE
=
NO
;
FRAMEWORK_SEARCH_PATHS
=
(
...
...
@@ -536,7 +536,7 @@
"@executable_path/Frameworks"
,
"@executable_path/../../Frameworks"
,
);
MARKETING_VERSION
=
1.0.
8
;
MARKETING_VERSION
=
1.0.
9
;
PRODUCT_BUNDLE_IDENTIFIER
=
xx.messenger.mock.notifications
;
PRODUCT_NAME
=
"$(TARGET_NAME)"
;
PROVISIONING_PROFILE_SPECIFIER
=
""
;
...
...
@@ -553,7 +553,7 @@
CODE_SIGN_ENTITLEMENTS
=
NotificationExtension/NotificationExtension.entitlements
;
CODE_SIGN_IDENTITY
=
"Apple Development"
;
CODE_SIGN_STYLE
=
Automatic
;
CURRENT_PROJECT_VERSION
=
58
;
CURRENT_PROJECT_VERSION
=
67
;
DEVELOPMENT_TEAM
=
S6JDM2WW29
;
ENABLE_BITCODE
=
NO
;
FRAMEWORK_SEARCH_PATHS
=
(
...
...
@@ -567,7 +567,7 @@
"@executable_path/Frameworks"
,
"@executable_path/../../Frameworks"
,
);
MARKETING_VERSION
=
1.0.
8
;
MARKETING_VERSION
=
1.0.
9
;
PRODUCT_BUNDLE_IDENTIFIER
=
xx.messenger.notifications
;
PRODUCT_NAME
=
"$(TARGET_NAME)"
;
PROVISIONING_PROFILE_SPECIFIER
=
""
;
...
...
Package.swift
View file @
510dcf16
...
...
@@ -11,7 +11,6 @@ let package = Package(
.
library
(
name
:
"App"
,
targets
:
[
"App"
]),
.
library
(
name
:
"HUD"
,
targets
:
[
"HUD"
]),
.
library
(
name
:
"Theme"
,
targets
:
[
"Theme"
]),
.
library
(
name
:
"Popup"
,
targets
:
[
"Popup"
]),
.
library
(
name
:
"Shared"
,
targets
:
[
"Shared"
]),
.
library
(
name
:
"Models"
,
targets
:
[
"Models"
]),
.
library
(
name
:
"XXLogger"
,
targets
:
[
"XXLogger"
]),
...
...
@@ -33,6 +32,7 @@ let package = Package(
.
library
(
name
:
"BackupFeature"
,
targets
:
[
"BackupFeature"
]),
.
library
(
name
:
"iCloudFeature"
,
targets
:
[
"iCloudFeature"
]),
.
library
(
name
:
"SearchFeature"
,
targets
:
[
"SearchFeature"
]),
.
library
(
name
:
"DrawerFeature"
,
targets
:
[
"DrawerFeature"
]),
.
library
(
name
:
"RestoreFeature"
,
targets
:
[
"RestoreFeature"
]),
.
library
(
name
:
"CrashReporting"
,
targets
:
[
"CrashReporting"
]),
.
library
(
name
:
"ProfileFeature"
,
targets
:
[
"ProfileFeature"
]),
...
...
@@ -152,6 +152,7 @@ let package = Package(
"ScanFeature"
,
"ChatFeature"
,
"MenuFeature"
,
"ToastFeature"
,
"CrashService"
,
"BackupFeature"
,
"SearchFeature"
,
...
...
@@ -163,6 +164,7 @@ let package = Package(
"CrashReporting"
,
"ChatListFeature"
,
"SettingsFeature"
,
"RequestsFeature"
,
"PushNotifications"
,
"OnboardingFeature"
,
"GoogleDriveFeature"
,
...
...
@@ -253,6 +255,15 @@ let package = Package(
]
),
// MARK: - ToastFeature
.
target
(
name
:
"ToastFeature"
,
dependencies
:
[
"Shared"
]
),
// MARK: - CrashService
.
target
(
...
...
@@ -330,12 +341,13 @@ let package = Package(
]
),
// MARK: -
Popup
// MARK: -
DrawerFeature
.
target
(
name
:
"
Popup
"
,
name
:
"
DrawerFeature
"
,
dependencies
:
[
"Shared"
,
"InputField"
,
.
product
(
name
:
"ScrollViewController"
,
package
:
"ScrollViewController"
...
...
@@ -500,15 +512,15 @@ let package = Package(
dependencies
:
[
"HUD"
,
"Theme"
,
"Popup"
,
"Shared"
,
"Defaults"
,
"Keychain"
,
"Voxophone"
,
"Integration"
,
"ChatInputFeature"
,
"Permissions"
,
"Voxophone"
,
"Presentation"
,
"DrawerFeature"
,
"ChatInputFeature"
,
"DependencyInjection"
,
.
product
(
name
:
"DifferenceKit"
,
...
...
@@ -548,6 +560,7 @@ let package = Package(
"Theme"
,
"Shared"
,
"Integration"
,
"ToastFeature"
,
"ContactFeature"
,
"DependencyInjection"
,
.
product
(
...
...
@@ -564,15 +577,16 @@ let package = Package(
dependencies
:
[
"HUD"
,
"Theme"
,
"Popup"
,
"Shared"
,
"Keychain"
,
"Defaults"
,
"Countries"
,
"InputField"
,
"MenuFeature"
,
"Permissions"
,
"Integration"
,
"Presentation"
,
"DrawerFeature"
,
"DependencyInjection"
,
.
product
(
name
:
"ScrollViewController"
,
...
...
@@ -612,7 +626,6 @@ let package = Package(
name
:
"OnboardingFeature"
,
dependencies
:
[
"HUD"
,
"Popup"
,
"Shared"
,
"Defaults"
,
"Keychain"
,
...
...
@@ -621,6 +634,7 @@ let package = Package(
"Permissions"
,
"Integration"
,
"Presentation"
,
"DrawerFeature"
,
"VersionChecking"
,
"PushNotifications"
,
"DependencyInjection"
,
...
...
@@ -640,12 +654,12 @@ let package = Package(
.
target
(
name
:
"MenuFeature"
,
dependencies
:
[
"Theme"
,
"Shared"
,
"Defaults"
,
"Integration"
,
"Presentation"
,
"ProfileFeature"
,
"RequestsFeature"
,
"SettingsFeature"
,
"ContactListFeature"
"DependencyInjection"
]
),
...
...
@@ -711,14 +725,15 @@ let package = Package(
dependencies
:
[
"HUD"
,
"Theme"
,
"Popup"
,
"Shared"
,
"Defaults"
,
"Keychain"
,
"InputField"
,
"Permissions"
,
"MenuFeature"
,
"Integration"
,
"Presentation"
,
"DrawerFeature"
,
"PushNotifications"
,
"DependencyInjection"
,
.
product
(
...
...
Sources/App/AppDelegate.swift
View file @
510dcf16
...
...
@@ -6,6 +6,7 @@ import Theme
import
XXLogger
import
Defaults
import
Integration
import
ToastFeature
import
SwiftyDropbox
import
CrashReporting
import
PushNotifications
...
...
@@ -51,8 +52,13 @@ public class AppDelegate: UIResponder, UIApplicationDelegate {
UNUserNotificationCenter
.
current
()
.
delegate
=
self
let
rootScreen
=
StatusBarViewController
(
UINavigationController
(
rootViewController
:
OnboardingLaunchController
())
let
rootScreen
=
StatusBarViewController
(
ToastViewController
(
UINavigationController
(
rootViewController
:
OnboardingLaunchController
()
)
)
)
window
=
Window
()
...
...
Sources/App/DependencyRegistrator.swift
View file @
510dcf16
...
...
@@ -18,6 +18,7 @@ import Voxophone
import
Integration
import
Permissions
import
CrashService
import
ToastFeature
import
iCloudFeature
import
CrashReporting
import
NetworkMonitor
...
...
@@ -101,13 +102,25 @@ struct DependencyRegistrator {
container
.
register
(
HUD
()
as
HUDType
)
container
.
register
(
ThemeController
()
as
ThemeControlling
)
container
.
register
(
ToastController
())
container
.
register
(
StatusBarController
()
as
StatusBarStyleControlling
)
// MARK: Coordinators
container
.
register
(
BackupCoordinator
(
passphraseFactory
:
BackupPassphraseController
.
init
(
_
:
_
:)
)
as
BackupCoordinating
)
container
.
register
(
BackupCoordinator
(
passphraseFactory
:
BackupPassphraseController
.
init
(
_
:
_
:)
)
as
BackupCoordinating
)
container
.
register
(
MenuCoordinator
(
scanFactory
:
ScanContainerController
.
init
,
chatsFactory
:
ChatListController
.
init
,
profileFactory
:
ProfileController
.
init
,
settingsFactory
:
SettingsController
.
init
,
contactsFactory
:
ContactListController
.
init
,
requestsFactory
:
RequestsContainerController
.
init
)
as
MenuCoordinating
)
container
.
register
(
SearchCoordinator
(
...
...
@@ -121,6 +134,7 @@ struct DependencyRegistrator {
phoneFactory
:
ProfilePhoneController
.
init
,
imagePickerFactory
:
UIImagePickerController
.
init
,
permissionFactory
:
RequestPermissionController
.
init
,
sideMenuFactory
:
MenuController
.
init
(
_
:
_
:),
countriesFactory
:
CountryListController
.
init
(
_
:),
codeFactory
:
ProfileCodeController
.
init
(
_
:
_
:)
)
as
ProfileCoordinating
)
...
...
@@ -129,7 +143,8 @@ struct DependencyRegistrator {
SettingsCoordinator
(
backupFactory
:
BackupController
.
init
,
advancedFactory
:
SettingsAdvancedController
.
init
,
accountDeleteFactory
:
AccountDeleteController
.
init
accountDeleteFactory
:
AccountDeleteController
.
init
,
sideMenuFactory
:
MenuController
.
init
(
_
:
_
:)
)
as
SettingsCoordinating
)
container
.
register
(
...
...
@@ -155,21 +170,24 @@ struct DependencyRegistrator {
requestsFactory
:
RequestsContainerController
.
init
,
singleChatFactory
:
SingleChatController
.
init
(
_
:),
imagePickerFactory
:
UIImagePickerController
.
init
,
nicknameFactory
:
NickameController
.
init
(
_
:
_
:)
nicknameFactory
:
Nick
n
ameController
.
init
(
_
:
_
:)
)
as
ContactCoordinating
)
container
.
register
(
RequestsCoordinator
(
searchFactory
:
SearchController
.
init
,
verifyingFactory
:
VerifyingController
.
init
,
contactFactory
:
ContactController
.
init
(
_
:),
nicknameFactory
:
NickameController
.
init
(
_
:
_
:)
singleChatFactory
:
SingleChatController
.
init
(
_
:),
groupChatFactory
:
GroupChatController
.
init
(
_
:),
sideMenuFactory
:
MenuController
.
init
(
_
:
_
:),
nicknameFactory
:
NicknameController
.
init
(
_
:
_
:)
)
as
RequestsCoordinating
)
container
.
register
(
OnboardingCoordinator
(
emailFactory
:
OnboardingEmailController
.
init
,
phoneFactory
:
OnboardingPhoneController
.
init
,
searchFactory
:
SearchController
.
init
,
welcomeFactory
:
OnboardingWelcomeController
.
init
,
chatListFactory
:
ChatListController
.
init
,
startFactory
:
OnboardingStartController
.
init
(
_
:),
...
...
@@ -188,28 +206,28 @@ struct DependencyRegistrator {
newGroupFactory
:
CreateGroupController
.
init
,
requestsFactory
:
RequestsContainerController
.
init
,
contactFactory
:
ContactController
.
init
(
_
:),
singleChatFactory
:
SingleChatController
.
init
(
_
:),
groupChatFactory
:
GroupChatController
.
init
(
_
:),
groupPopupFactory
:
CreatePopupController
.
init
(
_
:
_
:)
sideMenuFactory
:
MenuController
.
init
(
_
:
_
:),
groupDrawerFactory
:
CreateDrawerController
.
init
(
_
:
_
:)
)
as
ContactListCoordinating
)
container
.
register
(
ScanCoordinator
(
contactsFactory
:
ContactListController
.
init
,
requestsFactory
:
RequestsContainerController
.
init
,
contactFactory
:
ContactController
.
init
(
_
:)
contactFactory
:
ContactController
.
init
(
_
:),
sideMenuFactory
:
MenuController
.
init
(
_
:
_
:)
)
as
ScanCoordinating
)
container
.
register
(
ChatListCoordinator
(
scanFactory
:
ScanContainerController
.
init
,
searchFactory
:
SearchController
.
init
,
profileFactory
:
ProfileController
.
init
,
settingsFactory
:
SettingsController
.
init
,
contactsFactory
:
ContactListController
.
init
,
requestsFactory
:
RequestsContainerController
.
init
,
singleChatFactory
:
SingleChatController
.
init
(
_
:),
sideMenuFactory
:
Menu
Controller
.
init
(
_
:),
groupChatFactory
:
GroupChat
Controller
.
init
(
_
:)
groupChatFactory
:
GroupChat
Controller
.
init
(
_
:),
sideMenuFactory
:
Menu
Controller
.
init
(
_
:
_
:
)
)
as
ChatListCoordinating
)
}
}
Sources/BackupFeature/Controllers/BackupConfigController.swift
View file @
510dcf16
import
UIKit
import
Popup
import
Models
import
Shared
import
Combine
import
DrawerFeature
import
DependencyInjection
final
class
BackupConfigController
:
UIViewController
{
...
...
@@ -12,7 +12,7 @@ final class BackupConfigController: UIViewController {
private
let
viewModel
:
BackupConfigViewModel
private
var
cancellables
=
Set
<
AnyCancellable
>
()
private
var
popup
Cancellables
=
Set
<
AnyCancellable
>
()
private
var
drawer
Cancellables
=
Set
<
AnyCancellable
>
()
private
var
wifiOnly
=
false
private
var
manualBackups
=
false
...
...
@@ -82,12 +82,12 @@ final class BackupConfigController: UIViewController {
screenView
.
frequencyDetailView
.
publisher
(
for
:
.
touchUpInside
)
.
sink
{
[
unowned
self
]
in
presentFrequency
Popup
(
manual
:
manualBackups
)
}
.
sink
{
[
unowned
self
]
in
presentFrequency
Drawer
(
manual
:
manualBackups
)
}
.
store
(
in
:
&
cancellables
)
screenView
.
infrastructureDetailView
.
publisher
(
for
:
.
touchUpInside
)
.
sink
{
[
unowned
self
]
in
presentInfrastructure
Popup
(
wifiOnly
:
wifiOnly
)
}
.
sink
{
[
unowned
self
]
in
presentInfrastructure
Drawer
(
wifiOnly
:
wifiOnly
)
}
.
store
(
in
:
&
cancellables
)
screenView
.
googleDriveButton
...
...
@@ -193,16 +193,25 @@ final class BackupConfigController: UIViewController {
}
}
private
func
presentInfrastructurePopup
(
wifiOnly
:
Bool
)
{
let
cancelButton
=
CapsuleButton
()
cancelButton
.
setStyle
(
.
seeThrough
)
cancelButton
.
setTitle
(
Localized
.
ChatList
.
Dashboard
.
cancel
,
for
:
.
normal
)
let
wifiOnlyButton
=
PopupRadioButton
(
title
:
"Wi-Fi Only"
,
isSelected
:
wifiOnly
)
let
wifiAndCellularButton
=
PopupRadioButton
(
title
:
"Wi-Fi and Cellular"
,
isSelected
:
!
wifiOnly
)
let
popup
=
BottomPopup
(
with
:
[
PopupLabel
(
private
func
presentInfrastructureDrawer
(
wifiOnly
:
Bool
)
{
let
cancelButton
=
DrawerCapsuleButton
(
model
:
.
init
(
title
:
Localized
.
ChatList
.
Dashboard
.
cancel
,
style
:
.
seeThrough
))
let
wifiOnlyButton
=
DrawerRadio
(
title
:
"Wi-Fi Only"
,
isSelected
:
wifiOnly
)
let
wifiAndCellularButton
=
DrawerRadio
(
title
:
"Wi-Fi and Cellular"
,
isSelected
:
!
wifiOnly
,
spacingAfter
:
40
)
let
drawer
=
DrawerController
(
with
:
[
DrawerText
(
font
:
Fonts
.
Mulish
.
extraBold
.
font
(
size
:
28.0
),
text
:
Localized
.
Backup
.
Config
.
infrastructure
,
color
:
Asset
.
neutralActive
.
color
,
...
...
@@ -211,49 +220,57 @@ final class BackupConfigController: UIViewController {
),
wifiOnlyButton
,
wifiAndCellularButton
,
PopupEmptyView
(
height
:
20.0
),
PopupStackView
(
spacing
:
20.0
,
views
:
[
cancelButton
])
cancelButton
])
wifiOnlyButton
.
action
.
sink
{
[
unowned
self
]
in
viewModel
.
didChooseWifiOnly
(
true
)
popup
.
dismiss
(
animated
:
true
)
{
[
weak
self
]
in
self
?
.
popup
Cancellables
.
removeAll
()
drawer
.
dismiss
(
animated
:
true
)
{
[
weak
self
]
in
self
?
.
drawer
Cancellables
.
removeAll
()
}
}
.
store
(
in
:
&
popup
Cancellables
)
}
.
store
(
in
:
&
drawer
Cancellables
)
wifiAndCellularButton
.
action
.
sink
{
[
unowned
self
]
in
viewModel
.
didChooseWifiOnly
(
false
)
popup
.
dismiss
(
animated
:
true
)
{
[
weak
self
]
in
self
?
.
popup
Cancellables
.
removeAll
()
drawer
.
dismiss
(
animated
:
true
)
{
[
weak
self
]
in
self
?
.
drawer
Cancellables
.
removeAll
()
}
}
.
store
(
in
:
&
popup
Cancellables
)
}
.
store
(
in
:
&
drawer
Cancellables
)
cancelButton
.
publisher
(
for
:
.
touchUpInside
)
cancelButton
.
action
.
receive
(
on
:
DispatchQueue
.
main
)
.
sink
{
popup
.
dismiss
(
animated
:
true
)
{
[
weak
self
]
in
self
?
.
popup
Cancellables
.
removeAll
()
drawer
.
dismiss
(
animated
:
true
)
{
[
weak
self
]
in
self
?
.
drawer
Cancellables
.
removeAll
()
}
}
.
store
(
in
:
&
popup
Cancellables
)
}
.
store
(
in
:
&
drawer
Cancellables
)
coordinator
.
to
Popup
(
popup
,
from
:
self
)
coordinator
.
to
Drawer
(
drawer
,
from
:
self
)
}
private
func
presentFrequencyPopup
(
manual
:
Bool
)
{
let
cancelButton
=
CapsuleButton
()
cancelButton
.
setStyle
(
.
seeThrough
)
cancelButton
.
setTitle
(
Localized
.
ChatList
.
Dashboard
.
cancel
,
for
:
.
normal
)
let
manualButton
=
PopupRadioButton
(
title
:
"Manual"
,
isSelected
:
manual
)
let
automaticButton
=
PopupRadioButton
(
title
:
"Automatic"
,
isSelected
:
!
manual
)
let
popup
=
BottomPopup
(
with
:
[
PopupLabel
(
private
func
presentFrequencyDrawer
(
manual
:
Bool
)
{
let
cancelButton
=
DrawerCapsuleButton
(
model
:
.
init
(
title
:
Localized
.
ChatList
.
Dashboard
.
cancel
,
style
:
.
seeThrough
))
let
manualButton
=
DrawerRadio
(
title
:
"Manual"
,
isSelected
:
manual
)
let
automaticButton
=
DrawerRadio
(
title
:
"Automatic"
,
isSelected
:
!
manual
,
spacingAfter
:
40
)
let
drawer
=
DrawerController
(
with
:
[
DrawerText
(
font
:
Fonts
.
Mulish
.
extraBold
.
font
(
size
:
28.0
),
text
:
Localized
.
Backup
.
Config
.
frequency
(
serviceName
),
color
:
Asset
.
neutralActive
.
color
,
...
...
@@ -262,36 +279,35 @@ final class BackupConfigController: UIViewController {
),
manualButton
,
automaticButton
,
PopupEmptyView
(
height
:
20.0
),
PopupStackView
(
spacing
:
20.0
,
views
:
[
cancelButton
])
cancelButton
])
manualButton
.
action
.
sink
{
[
unowned
self
]
in
viewModel
.
didChooseAutomatic
(
false
)
popup
.
dismiss
(
animated
:
true
)
{
[
weak
self
]
in
self
?
.
popup
Cancellables
.
removeAll
()
drawer
.
dismiss
(
animated
:
true
)
{
[
weak
self
]
in
self
?
.
drawer
Cancellables
.
removeAll
()
}
}
.
store
(
in
:
&
popup
Cancellables
)
}
.
store
(
in
:
&
drawer
Cancellables
)
automaticButton
.
action
.
sink
{
[
unowned
self
]
in
viewModel
.
didChooseAutomatic
(
true
)
popup
.
dismiss
(
animated
:
true
)
{
[
weak
self
]
in
self
?
.
popup
Cancellables
.
removeAll
()
drawer
.
dismiss
(
animated
:
true
)
{
[
weak
self
]
in
self
?
.
drawer
Cancellables
.
removeAll
()
}
}
.
store
(
in
:
&
popup
Cancellables
)
}
.
store
(
in
:
&
drawer
Cancellables
)
cancelButton
.
publisher
(
for
:
.
touchUpInside
)
cancelButton
.
action
.
receive
(
on
:
DispatchQueue
.
main
)
.
sink
{
popup
.
dismiss
(
animated
:
true
)
{
[
weak
self
]
in
self
?
.
popup
Cancellables
.
removeAll
()
drawer
.
dismiss
(
animated
:
true
)
{
[
weak
self
]
in
self
?
.
drawer
Cancellables
.
removeAll
()
}
}
.
store
(
in
:
&
popup
Cancellables
)
}
.
store
(
in
:
&
drawer
Cancellables
)
coordinator
.
to
Popup
(
popup
,
from
:
self
)
coordinator
.
to
Drawer
(
drawer
,
from
:
self
)
}
}
Sources/BackupFeature/Coordinator/BackupCoordinator.swift
View file @
510dcf16
...
...
@@ -3,7 +3,7 @@ import Shared
import
Presentation
public
protocol
BackupCoordinating
{
func
to
Popup
(
func
to
Drawer
(
_
:
UIViewController
,
from
:
UIViewController
)
...
...
@@ -34,7 +34,7 @@ public struct BackupCoordinator: BackupCoordinating {
}
public
extension
BackupCoordinator
{
func
to
Popup
(
func
to
Drawer
(
_
screen
:
UIViewController
,
from
parent
:
UIViewController
)
{
...
...
Sources/ChatFeature/Controllers/GroupChatController.swift
View file @
510dcf16
...
...
@@ -57,7 +57,7 @@ public final class GroupChatController: UIViewController {
super
.
init
(
nibName
:
nil
,
bundle
:
nil
)
header
.
setup
(
title
:
info
.
group
.
name
,
member
s
:
info
.
members
)
header
.
setup
(
title
:
info
.
group
.
name
,
member
List
:
info
.
members
.
map
{
(
$0
.
username
,
$0
.
photo
)
}
)
}
public
required
init
?(
coder
:
NSCoder
)
{
nil
}
...
...
@@ -490,19 +490,19 @@ extension GroupChatController: UICollectionViewDelegate {
let
item
=
self
.
sections
[
indexPath
.
section
]
.
elements
[
indexPath
.
item
]
let
copy
=
UIAction
(
title
:
Localized
.
Chat
.
BubbleMenu
.
copy
,
state
:
.
o
n
)
{
_
in
let
copy
=
UIAction
(
title
:
Localized
.
Chat
.
BubbleMenu
.
copy
,
state
:
.
o
ff
)
{
_
in
UIPasteboard
.
general
.
string
=
item
.
payload
.
text
}
let
reply
=
UIAction
(
title
:
Localized
.
Chat
.
BubbleMenu
.
reply
,
state
:
.
o
n
)
{
[
weak
self
]
_
in
let
reply
=
UIAction
(
title
:
Localized
.
Chat
.
BubbleMenu
.
reply
,
state
:
.
o
ff
)
{
[
weak
self
]
_
in
self
?
.
viewModel
.
didRequestReply
(
item
)
}
let
delete
=
UIAction
(
title
:
Localized
.
Chat
.
BubbleMenu
.
delete
,
state
:
.
o
n
)
{
[
weak
self
]
_
in