chore: cleanup and format

Signed-off-by: Innei <tukon479@gmail.com>
This commit is contained in:
Innei
2025-02-25 22:42:37 +08:00
parent 92fca31637
commit 4d0a1129eb
2 changed files with 3 additions and 29 deletions
+2 -5
View File
@@ -1,8 +1,5 @@
{
"platforms": [
"apple",
"android"
],
"platforms": ["apple", "android"],
"apple": {
"modules": [
"SharedWebViewModule",
@@ -14,4 +11,4 @@
"android": {
"modules": []
}
}
}
@@ -15,6 +15,7 @@ public class AppleIntelligenceGlowEffectModule: Module {
public func definition() -> ModuleDefinition {
Name("AppleIntelligenceGlowEffect")
Function("show") {
DispatchQueue.main.async { [weak self] in
guard let rootVC = Utils.getRootVC() else { return }
@@ -63,27 +64,3 @@ public class AppleIntelligenceGlowEffectModule: Module {
}
}
}
final class AppleIntelligenceGlowEffectView: UIViewControllerRepresentable {
func makeUIViewController(context: Context) -> UIViewController {
let viewController = UIViewController()
let hostingController = UIHostingController(rootView: GlowEffect())
viewController.addChild(hostingController)
viewController.view.addSubview(hostingController.view)
hostingController.didMove(toParent: viewController)
hostingController.view.translatesAutoresizingMaskIntoConstraints = false
NSLayoutConstraint.activate([
hostingController.view.topAnchor.constraint(equalTo: viewController.view.topAnchor),
hostingController.view.bottomAnchor.constraint(equalTo: viewController.view.bottomAnchor),
hostingController.view.leadingAnchor.constraint(equalTo: viewController.view.leadingAnchor),
hostingController.view.trailingAnchor.constraint(equalTo: viewController.view.trailingAnchor),
])
return viewController
}
func updateUIViewController(_ viewController: UIViewController, context: Context) {
}
}