Skip to content

Commit

Permalink
Fix
Browse files Browse the repository at this point in the history
  • Loading branch information
muukii committed Mar 27, 2021
1 parent 3299efc commit 0aab4a0
Show file tree
Hide file tree
Showing 4 changed files with 75 additions and 19 deletions.
4 changes: 2 additions & 2 deletions Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ PODS:
- TextureSwiftSupport
- Reveal-SDK (27)
- Texture/Core (3.0.0)
- TextureSwiftSupport (3.2.0):
- TextureSwiftSupport (3.4.0):
- Texture/Core (~> 3)
- TypedTextAttributes (1.1.0)

Expand All @@ -30,7 +30,7 @@ SPEC CHECKSUMS:
GlossButtonNode: 0b1471447cb4cebc8a959bbca574247ff6b0592b
Reveal-SDK: 306e2880395ee396f5a8b4c485c3a86dd19866c7
Texture: 2f109e937850d94d1d07232041c9c7313ccddb81
TextureSwiftSupport: 2dfc0320e954f549d941f630843b097ab2abdec2
TextureSwiftSupport: 9f630cd5056e90991bc0d473a3d77f05a891831c
TypedTextAttributes: fc3a5a8c4a7a28304446f8c5e8af146d11c2163a

PODFILE CHECKSUM: d0d5117b212f7b612e1da01319d0d50e755c823a
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1240"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "4B873C2123083FE5006170B1"
BuildableName = "TextureSwiftSupport.framework"
BlueprintName = "TextureSwiftSupport"
ReferencedContainer = "container:TextureSwiftSupport.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
</Testables>
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "4B873C2123083FE5006170B1"
BuildableName = "TextureSwiftSupport.framework"
BlueprintName = "TextureSwiftSupport"
ReferencedContainer = "container:TextureSwiftSupport.xcodeproj">
</BuildableReference>
</MacroExpansion>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ public struct HighlightAnimationDescriptor {
_ bodyNode: ASDisplayNode
) -> Void

fileprivate let animation: Block
fileprivate let overlayNode: ASDisplayNode?
let animation: Block
let overlayNode: ASDisplayNode?

public init(
overlayNode: () -> ASDisplayNode? = { nil },
Expand Down Expand Up @@ -60,11 +60,7 @@ extension HighlightAnimationDescriptor {
initialSpringVelocity: 0,
options: [.beginFromCurrentState, .allowUserInteraction],
animations: {
body.transform = .init(
scaleX: shrinkingScale,
y: shrinkingScale,
z: 1
)
body.transform = CATransform3DMakeScale(shrinkingScale, shrinkingScale, 1)
},
completion: nil
)
Expand All @@ -76,7 +72,7 @@ extension HighlightAnimationDescriptor {
initialSpringVelocity: 0,
options: [.beginFromCurrentState, .allowUserInteraction],
animations: {
body.transform = .identity
body.transform = CATransform3DIdentity
},
completion: nil
)
Expand Down Expand Up @@ -156,7 +152,7 @@ extension HighlightAnimationDescriptor {
],
animations: {
containerNode.layer.opacity = 0.98
containerNode.transform = .init(scaleX: 0.98, y: 0.98, z: 1)
containerNode.transform = CATransform3DMakeScale(0.98, 0.98, 1)
body.view.transform = CGAffineTransform(scaleX: 0.98, y: 0.98)
},
completion: nil
Expand All @@ -172,7 +168,7 @@ extension HighlightAnimationDescriptor {
],
animations: {
containerNode.layer.opacity = 0
containerNode.transform = .identity
containerNode.transform = CATransform3DIdentity
body.view.transform = .identity
},
completion: nil
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,14 +36,8 @@ open class InteractiveNode<D: ASDisplayNode>: NamedDisplayControlNodeBase {
return false
}

public var tap: ControlEvent<Void> {
return .init(events: _tapRelay)
}

public var longPressGestureRecognizer: UILongPressGestureRecognizer?

private let _tapRelay = PublishRelay<Void>()

public var handlers = Handlers()

public let overlayNode: ASDisplayNode?
Expand Down Expand Up @@ -124,7 +118,6 @@ open class InteractiveNode<D: ASDisplayNode>: NamedDisplayControlNodeBase {
}

@objc private func _touchUpInside(_ gesture: UITapGestureRecognizer) {
_tapRelay.accept(())
handlers.onTap()
}

Expand Down

0 comments on commit 0aab4a0

Please sign in to comment.