Skip to content

Conversation

KaninVitaliy
Copy link
Contributor

No description provided.

@KaninVitaliy KaninVitaliy requested a review from SubvertDev March 27, 2025 11:32
@@ -1,6 +1,19 @@
{
"sourceLanguage" : "en",
"strings" : {
"" : {

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Пустая локализация, скорее всего надо просто завернуть вызов в String

"" : {

},
"%lld / %lld" : {
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Либо переводим либо заворачиваем в стрингу

@@ -20,6 +20,9 @@ struct ArticleElementView: View {
@State private var gallerySelection: Int = 0
@State private var pollSelection: ArticlePoll.Option?
@State private var pollSelections: Set<ArticlePoll.Option> = .init()
@State private var showFullScreenImage: Bool = false
@State private var showFullScreenGallery: Bool = false
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Что произойдет если мы их оба поставим на true? Мне кажется это нужно завернуть в Destination, посмотри примеры с шитами

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Оставил только showFullScreenImage

//

import SwiftUI
import UIKit
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

По идее import UIKit можно убрать


func updateUIView(_ uiView: UICollectionView, context: Context) {
let indexPath = IndexPath(item: selectedIndex, section: 0)
DispatchQueue.main.async {
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Отдаем предпочтение Task { @MainActor in
Перепроверяем что с ним все работает также

tempFileUrls[element.offset] = tempFileUrl
}
} catch {
print("Image not loaded: \(error)")
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Писал выше про ошибки

Copy link
Contributor Author

@KaninVitaliy KaninVitaliy Mar 31, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

нужно отобразить ошибку. (Tost manager)

print("Image not loaded: \(error)")
}
case .failure(let error):
print("Image not loaded: \(error)")
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Писал выше про ошибки

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

нужно отобразить ошибку. (Tost manager)

try FileManager.default.removeItem(at: fileURL)
}
} catch {
print("Error deleting temp files: \(error)")
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Писал выше про ошибки

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

нужно отобразить ошибку. (Tost manager)

.scaleEffect(0.8) // TODO: ?
.background(
Circle()
.fill(.ultraThinMaterial.opacity(backgroundOpacity)) // Материал
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Материал

func makeUIViewController(context: Context) -> UIActivityViewController {
let activityVC = UIActivityViewController(activityItems: activityItems, applicationActivities: nil)

print(activityItems)
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Если принт больше не нужен, то убери

@SubvertDev SubvertDev merged commit 30485a7 into develop Apr 5, 2025
1 check passed
@SubvertDev SubvertDev deleted the feature/image-gallery branch August 12, 2025 22:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants