-
Notifications
You must be signed in to change notification settings - Fork 2
Description
A list of tasks to complete to create the initial release (WIP).
Tasks
Modal Config - Parser + TS Types
-
#ff0000
- Impl:react-native-ios-adaptive-modal
- TS Types - type definitions for modal config (i.e.AdaptiveModalConfig
and related types). -
#ffa500
- Impl:react-native-ios-adaptive-modal
- Swift Parser - Impl. parser for converting modal config (i.e.AdaptiveModalConfig
and related types) from JS primitives to their corresponding swift types. -
#d2691e
- Impl:react-native-ios-utilities
- TS Types - TS type definitions forComputableLayout
and related types. -
#f08080
- Impl:react-native-ios-utilities
- Swift Parser - Impl. parser for convertingComputableLayout
(and related types) from JS primitives to their corresponding swift types. -
#bdb76b
- Impl:react-native-ios-utilities
- TS Types - type definitions forUIKit
types. -
#a0522d
- Impl:react-native-ios-utilities
- Swift Parser - Impl. parser for convertingUIKit
types from their JS primitives representation, to their corresponding swift types. -
#ffd700
- Impl:react-native-ios-adaptive-modal
- Prop - Impl,modalConfig
prop, and test whether or not the config is being parsed correctly.
Examples and Testing
-
#4169e1
- Impl: Example - Impl. the demo presets in examples fromadaptive-modal
. -
#c71585
- Impl: Example - Recreate the examples fromadaptive-modal
'sAdaptiveModalConfigDemoPresets
+AdaptiveModalConfigDemoViewController
. -
#00008b
- Impl: Docs - Create the draft version of theREADME
containing videos/images showing theAdaptiveModalConfigDemoPresets
items.
Modal Content Resizing
-
#4b0082
- Fix: Modal Content Resizing -AdaptiveModal
animations will only update the size of the modal content after the animation is finished. -
#ff00ff
- Impl:react-native-ios-adaptive-modal
- Add support for adding multiple views in the modal content. -
#8b008b
- Impl:react-native-ios-adaptive-modal
- Add support different modes for positioning/resizing the modal content.
- Refactor:
react-native-ios-utilities
- UpdateRNIDummyView
- In order to support having a scroll view as the main modal content, we have to use
RNIDummyView
instead ofRNIDetachedView
. RNIDetachedView
wraps its children in a view; that wrapper view is then the one that’s used for layout.RNIDummyView
does not wrap it’s children, and exposes it directly.- Note: Since react scrollview’s are backed by
UIScrollView
under the hood (and not byYogaLayout
, there won’t be any layout-resizing issues since the autolayout constraints animations will be applied directly to the scroll view.
- In order to support having a scroll view as the main modal content, we have to use
General Tasks
-
#2f4f4f
- Impl:react-native-ios-adaptive-modal
- Modal Events: Expose modal presentation events to RN -
Impl:
react-native-ios-adaptive-modal
- Modal Focus/Blur Events + Logic- Whenever a new modal is shown, other modals will be notified with a blur event.
- Conversely, when the top modal is dismissed, the next top modal will receive a focus event.
- Note: in order for this to work, any view controller presented must emit focus/blur events (even if it’s a modal impl. by another library, or a view controller instance presented by the user).
- This logic has been implemented in
react-native-ios-modal
, however it’s in an unfinished state, and will need major refactoring to make it work. - A way to achieve this is to swizzle the
UIViewController
, and notify a singleton of modal presentation events, and then keep track of the presented view controllers.
-
Refactor:
adaptive-modal
- Complete the refactor for lessening the reliance on indexes for controlling the modal + keeping track of it's state. -
#ee82ee
- Refactor:adaptive-modal
- Re-writeAdaptiveModalSnapPointConfig
-
Refactor:
adaptive-modal
- Extract modal animation/interpolation logic fromAdaptiveModalManager
into its own type. -
Refactor:
adaptive-modal
- Optimize modal interpolation logic by caching the interpolated values. -
Impl:
adaptive-modal
- Add Error Handling - Functions that control the modal should throw an error. -
#6b8e23
- Impl:react-native-ios-adaptive-modal
- Props - Expose modal manager flags as props. -
#d2b48c
- Impl:react-native-ios-adaptive-modal
- Modal Commands - Expose modal manager commands - Impl. methods to show/hide/control the modal from RN.
Task Progress and Logging
DGSwiftUtilities
(Commits - All Changes)ComputableLayout
(Commits - All Changes)react-native-ios-utilities
(Commits - All Changes)react-native-ios-adaptive-modal
(Commits - All Changes)
# Task: #bdb76b
- Task: Impl:
react-native-ios-utilities
- TS Types - type definitions forUIKit
types. - Status: Completed
2023-12-21-06:58
:react-native-ios-utilities
(Commits)- Desc: Import
UIKit
TS types fromreact-native-ios-adaptive-modal
.
- Desc: Import
# Task: #a0522d
- Task: Impl:
react-native-ios-utilities
- Swift Parser - Impl. parser for converting UIKit types from their JS primitives representation, to their corresponding swift types. - Status: Completed
# Task: #d2691e
- Task: Impl:
react-native-ios-utilities
- TS Types - TS type definitions forComputableLayout
and related types. - Status: Completed
2023-12-21-20:28
:react-native-ios-utilities
(Commits)- Desc: Impl. TS type definitions for
ComputableLayout
, and update library exports.
- Desc: Impl. TS type definitions for
# Task: #f08080
- Task: Impl:
react-native-ios-utilities
- Swift Parser - Impl. parser for convertingComputableLayout
(and related types) from JS primitives to their corresponding swift types. - Status: Completed
2023-12-21-20:43
:ComputableLayout
(Commits)2023-12-21-22:13
:react-native-ios-utilities
(Commits)- Desc: Update min. dependency to
DGSwiftUtilities
, and add dependency toComputableLayout
.
- Desc: Update min. dependency to
2023-12-22-02:51
:DGSwiftUtilities
(Commits)2023-12-22-07:59
:ComputableLayout
(Commits)2023-12-24-22:57
: Log - Ran into a blocker with mapping swift'sKeyPath<Root, Value>
to TS/JS.- Ideally, we should be able to convert a js "keypath" string literal "origin.x" to a swift key path as
let keypath: KeyPath<CGRect, CGFloat> = \.origin.x
.- In swift, we would have to create a parser that recursively "crawls" a type, and return the "path" it took as a
KeyPath
(e.g. tree traversal). - The problem is with the limitations of
KeyPath
(e.g. restraints due to type safety at compile-time).
- In swift, we would have to create a parser that recursively "crawls" a type, and return the "path" it took as a
- If we cannot find a solution using swift's generic system, we can just hardcode all the the possible keypaths as stopgap temp. solution.
- Ideally, we should be able to convert a js "keypath" string literal "origin.x" to a swift key path as
2023-12-26-07:29
:2023-12-26-06-04-59.playground
(Code Snippet)- Desc: Initial WIP impl. for "String to
KeyPath
Parser"
- Desc: Initial WIP impl. for "String to
2023-12-26-07:43
: Recap/Summary - From2023-12-24-23:24
to2023-12-26-05:42
- Problem-01 - Trying to find a way to map a string "key path" literal (e.g.
"origin"
) to a swiftKeyPath
(e.g.\CGRect.origin
).- Objc has a lang. feature called KVC (Key Value Coding), which essentially allows you to refer/access an object's properties via a string key path.
- This is available in swift too for classes that inherit from
NSObject
. - The swift equivalent of this concept is:
KeyPath
. - The main difference between KVC and
KeyPath
is that KVC is evaluated at runtime, andKeyPath
is "constructed" at compile-time (e.g. because it heavily relies on swift's generic system). - A side-effect of this is that
KeyPath
is not codable.- Another limitation is that you cannot get a string representation of
KeyPath
(not even through reflection).
- Another limitation is that you cannot get a string representation of
- Because of this, we have to provide the mapping manually between the name of the property, and it's corresponding
KeyPath
, e.g.:Dictionary<String, PartialKeyPath<CGRect>>
["origin": \.origin]
.
- Problem-02 - Parsing a "deep" key path string (e.g.
"foo.bar.baz"
), and converting it to\.foo.bar.baz
- This can be impl. via a "crawler"; i.e. we check if the next type contains a "string to key path" map (e.g. via protocol conformance checking).
- Then for each key in the key path string literal, we produce partial key paths and then add them together to produce a key path.
- Failed Attempts:
2023-12-24-23-24-07
(Code Snippet)2023-12-25-06-03-13.playground
(Code Snippet)2023-12-25-06-55-41.playground
(Code Snippet)2023-12-25-07-57-20.playground
(Code Snippet)2023-12-25-08-11-12.playground
(Code Snippet)2023-12-25-17-51-25.playground
(Code Snippet)- Desc: This playground demonstrates that it's possible to combine
AnyKeyPath
together.
- Desc: This playground demonstrates that it's possible to combine
2023-12-25-17-54-35.playground
(Code Snippet)2023-12-25-21-56-31.playground
(Code Snippet)2023-12-25-22-14-52.playground
(Code Snippet)2023-12-26-05-42-02.playground
(Code Snippet)
- Problem-01 - Trying to find a way to map a string "key path" literal (e.g.
2023-12-26-08:47
:2023-12-26-08-30-37.playground
(Code Snippet)- Desc: This playground demonstrates that it's possible to get the metatype/type of
Value
fromKeyPath<Root, Value>
usingtype(of:)
at runtime.
- Desc: This playground demonstrates that it's possible to get the metatype/type of
2023-12-26-19:20
:2023-12-26-06-04-59.playground
(Code Snippet)- Desc: WIP impl. for "String to
KeyPath
Parser" -static var b: [B.Type]
can now be automatically impl. in a default extension usingtype(of:)
.
- Desc: WIP impl. for "String to
2023-12-26-20:01
:2023-12-26-06-04-59.playground
(Code Snippet)- Desc: WIP impl. for "String to
KeyPath
Parser" - Working demo for that shows key path string literal"origin.x"
being converted to\CGRect.origin.x
.
- Desc: WIP impl. for "String to
2023-12-26-22:26
:2023-12-26-06-04-59.playground
(Code Snippet)- Desc: WIP impl. for "String to
KeyPath
Parser" - Impl. optimization - cacheB.b
, andB.allB
values.
- Desc: WIP impl. for "String to
2023-12-26-23:26
:2023-12-26-06-04-59.playground
(Code Snippet)- Desc: WIP impl. for "String to
KeyPath
Parser" - Impl.B.getPartialKeyPath
.
- Desc: WIP impl. for "String to
2023-12-26-23:42
:2023-12-26-06-04-59.playground
(Code Snippet)- Desc: WIP impl. for "String to
KeyPath
Parser" - Impl.B.getKeyPath
.
- Desc: WIP impl. for "String to
2023-12-27-05:30
:DGSwiftUtilities
(Commits)- Desc: Impl.
StringKeyPathMapping
(based on2023-12-26-06-04-59.playground
) + impl. conformance toStringKeyPathMapping
for types:CGPoint
,CGRect
,CGSize
.
- Desc: Impl.
2023-12-27-07:02
:DGSwiftUtilities
(Commits)2023-12-28-08:32
:ComputableLayout
(Commits)2023-12-31-12:06
:react-native-ios-utilities
(Commits)- Desc: Impl.
InitializableFromDictionary
, andInitialzableFromString
+ added protocol conformance for variousUIKit
/DGSwiftUtilties
/ComputableLayout
types.
- Desc: Impl.
2023-12-27-07:02
:DGSwiftUtilities
(Commits)2024-01-01-00:15
:react-native-ios-utilities
(Commits)
# Task: #ff0000
- Task - Impl:
react-native-ios-adaptive-modal
- TS Types - type definitions for modal config (i.e.AdaptiveModalConfig
and related types). - Status: Completed
2024-01-01-06:00
:react-native-ios-adaptive-modal
(Commits)- Desc: Update dependencies, and impl. TS types for
AdaptiveModalConfig
+ related types.
- Desc: Update dependencies, and impl. TS types for
2024-01-02-10:45
:react-native-ios-adaptive-modal
(Commits)- Desc: Impl. TS types:
AdaptiveModalSnapPointPreset
,ComputableLayoutPreset
, and updatedAdaptiveModalConfig
.
- Desc: Impl. TS types:
2024-01-02-10:39
:react-native-ios-adaptive-modal
(Commits)- Desc: Impl. TS types:
DragHandlePosition
.
- Desc: Impl. TS types:
# Task: #ffa500
- Task - Impl:
react-native-ios-adaptive-modal
- Swift Parser - Impl. parser for converting modal config (i.e.AdaptiveModalConfig
and related types) from JS primitives to their corresponding swift types. - Status: Completed
2023-12-28-08:32
:adaptive-modal
(Commits)2024-01-02-10:39
:react-native-ios-adaptive-modal
(Commits)- Desc: Impl. conformance to
InitializableFromDictionary
for types:AdaptiveModalSnapPointConfig
,AdaptiveModalConfig
,AdaptiveModalKeyframeConfig
,AdaptiveModalClampingConfig
,AdaptiveModalSnapPointPreset
,AdaptiveModalLayoutValueEdgeInsets
, and impl. conformance toInitializableFromDictionary
for types:CACornerMask
.
- Desc: Impl. conformance to
2024-01-02-14:27
:DGSwiftUtilities
(Commits)2024-01-02-14:34
:react-native-ios-utilities
(Commits)2024-01-02-23:21
:react-native-ios-adaptive-modal
(Commits)- Desc: Update dependencies to
DGSwiftUtilities
, andreact-native-ios-utilities
.
- Desc: Update dependencies to
# Task: #ffd700
- Task - Impl:
react-native-ios-adaptive-modal
- Prop - Impl,modalConfig
prop, and test whether or not the config is being parsed correctly. - Status: WIP
2024-01-03-02:24
:react-native-ios-adaptive-modal
(Commits)- Desc: Impl.
AdaptiveModalView.modalConfig
prop, and update example to test themodalConfig
prop.
- Desc: Impl.
2024-01-03-02:27
- Log: Encountered bug with parsing ofmodalConfig
.2024-01-03-02:30
:AdaptiveModalConfig.snapPoints
->AdaptiveModalSnapPointConfig.layoutConfig
->ComputableLayout
- OK:
horizontalAlignment
,verticalAlignment
- Error:
width
- OK:
2024-01-03-02:34
: Check:ComputableLayoutValue(fromDict:)
- Error:
mode
- Error:
2024-01-03-02:41
: Check:ComputableLayoutValueMode(fromDict:)
- OK:
dict["mode"]
,modeString
(value: "percent"), - Error: Parsing of enum case: "percent"
- OK:
2024-01-03-02:52
:react-native-ios-utilities
(Commits)2024-01-03-03:06
:react-native-ios-adaptive-modal
(Commits) (Gif)- Desc: Updated dep. to
react-native-ios-utilities
, and updated example.
- Desc: Updated dep. to
2024-01-03-03:14
:react-native-ios-adaptive-modal
(Commit) (Gif)- Desc: Updated example's
modalConfig
, and encountered bug with snap points.
- Desc: Updated example's
2024-01-03-04:57
:react-native-ios-adaptive-modal
(Commit) (Gif)- Desc: Updated example's
modalConfig
. - Notes: Proceed with recreating the examples from
adaptive-modal
in RN.
- Desc: Updated example's
# Task: #4169e1
- Task - Impl: Example - Impl. the demo presets in examples from
adaptive-modal
. - Status: Completed
2024-01-03-09:37
:react-native-ios-adaptive-modal
(Commits) (Gif)- Desc: Added initial impl. for
AdaptiveModalViewTest01
.
- Desc: Added initial impl. for
2024-01-03-22:00
: Log- 🖼️ Example Gif — Encountered hangups of example when changing the current modal config due to parsing of the modal config in native using
init(usingDict:)
. - 🖼️ Profiler Screenshot — The profiler shows 100% CPU usage and hang when the modal config is parsed, then goes back to normal usage after a few seconds.
- 📄 Xcode Logs - 2024-01-03-22-21-35 — Added temp. logging to
Dictionary+Hepers
- Log to console for every invocation ofgetValueFromDictionary
(or related functions).- Log shows 343 invocations to parse "demo02" from
AdaptiveModalConfigPresets
.
- Log shows 343 invocations to parse "demo02" from
- 🖼️ Example Gif — Encountered hangups of example when changing the current modal config due to parsing of the modal config in native using
2024-01-04-00:01
: Log (continued)- 📄 Xcode Logs - 2024-01-04-00-11-25
- Going through the logs, there doesn't seem to be any duplicate/unnecessary calls for
getValueFromDictionary
. - The performance slowdown might be caused by error handling, i.e. each failure of
getValueFromDictionary
is creating an error instance (i.e.VerboseError
), and verbose error automatically captures the current stack trace. - As such, multiple successive invocations of
getValueFromDictionary
+init(fromDict:)
(both of which throwsVerboseError
instances), might be causing the slow down.
2024-01-05-02:16
:DGSwiftUtilities
(Commits)2024-01-05-05:41
:react-native-ios-adaptive-modal
(Commits)2024-01-11-18:37
: Log -react-native-ios-adaptive-modal
- Bug:
secondaryGestureAxisDampingPercent
is not being applied.
- Bug:
2024-01-13-14:11
: Log (Continued) -react-native-ios-adaptive-modal
AdaptiveModalConfigPresetDemo01
-> snap point (index 2) ->secondaryGestureAxisDampingPercent
(value:1
).po dict["secondaryGestureAxisDampingPercent"]
->some : 1
- Correction: Not a bug, the wrong value was set in the presets, oops.
2024-01-13-15:55
-react-native-ios-adaptive-modal
(Commit) - Desc: Ex - Impl.AdaptiveModalConfigPresetDemo03
.2024-01-13-18:09
-react-native-ios-utilities
(Release: v4.3.0-6 | changes) - Desc: Fix typeComputableLayoutValueMode
.2024-01-13-18:56
-react-native-ios-adaptive-modal
(Commits) - Desc: Ex - Impl.AdaptiveModalConfigPresetDemo04
, and update dependencies.2024-01-13-19:10
- Log: Bug -react-native-ios-adaptive-modal
-modalDragHandleColor
not working.2024-01-13-19:43
-DGSwiftUtilities
(Release: 0.12.6 | changes) - Desc: FixgetColorFromDictionary
not working.2024-01-14-07:33
-react-native-ios-adaptive-modal
(Commits) - Desc: Ex - Impl.AdaptiveModalConfigPresetDemo05
, fixedAdaptiveModalConfigPresetDemo04
, and reorderedRNIModalContentAnchorModes
.2024-01-14-07:49
- Log -react-native-ios-adaptive-modal
#- 📼 Attachment: Simulator Screen Recording - iPhone 11 - iOS 17 - 2024-01-14 at 07.43.23.mp4
- Desc:
AdaptiveModalViewTest01
- Index: 2 - Preset:AdaptiveModalConfigPresetDemo03
- Desc:
- 📼 Attachment: Simulator.Screen.Recording.-.iPhone.11.-.iOS.17.-.2024-01-14.at.07.43.54.mp4
- Desc:
AdaptiveModalViewTest01
- Index: 3 - Preset:AdaptiveModalConfigPresetDemo04
- Desc:
- 📼 Attachment: Simulator.Screen.Recording.-.iPhone.11.-.iOS.17.-.2024-01-14.at.07.52.57.mp
- Desc:
AdaptiveModalViewTest02
- Index: 1 - Preset:AdaptiveModalConfigPresetDemo01
- Desc:
- 📼 Attachment: Simulator Screen Recording - iPhone 11 - iOS 17 - 2024-01-14 at 07.45.22.mp4
- Desc:
AdaptiveModalViewTest02
- Index: 2 - Preset:AdaptiveModalConfigPresetDemo03
- Desc:
- 📼 Attachment: Simulator.Screen.Recording.-.iPhone.11.-.iOS.17.-.2024-01-14.at.07.45.55.mp4
- Desc:
AdaptiveModalViewTest02
- Index: 3 - Preset:AdaptiveModalConfigPresetDemo04
- Desc:
- 📼 Attachment: Simulator.Screen.Recording.-.iPhone.11.-.iOS.17.-.2024-01-14.at.07.46.48.mp4
- Desc:
AdaptiveModalViewTest02
- Index: 4 - Preset:AdaptiveModalConfigPresetDemo05
- Desc:
- 📼 Attachment: Simulator Screen Recording - iPhone 11 - iOS 17 - 2024-01-14 at 07.43.23.mp4
2024-01-14-08:28
- Log:react-native-ios-adaptive-modal
- Found bug w/AdaptiveModalConfigPresetDemo05
.- Desc: The overshoot/last snap point is causing the modal content + drag handle to disappear/flicker whenever the modal is dragged too far out to the right.
- 📼 Attachment: Simulator Screen Recording - iPhone 11 - iOS 17 - 2024-01-14 at 08.30.23
2024-01-14-10:53
- Log (Continued):react-native-ios-adaptive-modal
- Bug is not present in
adaptive-modal
. - Possible cause for bug:
offsetValue
oroffsetOperation
for height might not be parsed correctly, if at all.
- Bug is not present in
2024-01-16-10:43
-react-native-ios-utilities
(Release: v4.3.0-7 | changes) - Desc: FixComputableLayoutValue.offsetOperation
not being parsed correctly.2024-01-16-20:27
-react-native-ios-adaptive-modal
(Commits) - Desc: Ex - Impl.AdaptiveModalConfigPresetDemo06
, and update dependencies.2024-01-16-20:52
-react-native-ios-adaptive-modal
(Commit) - Desc: Ex - Impl.AdaptiveModalConfigPresetDemo07
2024-01-16-20:53
- Log:react-native-ios-adaptive-modal
- Found bug w/AdaptiveModalConfigPresetDemo07
- The undershoot keyframe is incorrect, or not being applied.
- E.g. the scale transform is not being applied.
2024-01-18-12:58
- Log:react-native-ios-adaptive-modal
- Found bug w/Transform3D
parsing inTransform3D+InitializableFromDictionary
.- 📄 Attachment: 2024-01-18-12-57-56.txt
- 📄 Attachment: 2024-01-18-12-57-56.txt
2024-01-18-13:04
-react-native-ios-utilities
(Release: v4.3.0-8 | changes) - Desc: Fix parsing forTransform3D
.2024-01-18-13:43
-react-native-ios-adaptive-modal
(Commits) - Desc: Ex - Update dependencies, and added logo to example homescreen header.2024-01-18-14:29
-react-native-ios-adaptive-modal
(Commit) - Desc: Ex - Impl.AdaptiveModalConfigPresetDemo08
2024-01-18-17:18
-react-native-ios-adaptive-modal
(Commit) - Desc: Ex - Impl.AdaptiveModalConfigPresetDemo09
2024-01-18-17-21
- Log: In order to test outAdaptiveModalConfigPresetDemo09
+keyboardRelativeSize
layout values, there has to be a text box inside the modal content.- Impl. diff. modal content similar to the example in
adaptive-modal
.
- Impl. diff. modal content similar to the example in
2024-01-18-22:17
-react-native-ios-adaptive-modal
(Commits) - Desc: Ex - Impl.AdaptiveModalConfigPresetsWithMetadata
, and updateAdaptiveModalViewTest01
to show diff. modal content based on the current preset item.2024-01-20-13:40
-react-native-ios-adaptive-modal
(Commit) - Desc: Ex - Impl.AdaptiveModalConfigPresetDemo10
2024-01-20-15:13
-react-native-ios-adaptive-modal
(Commit) - Desc: Ex - Impl.AdaptiveModalConfigPresetDemo11
2024-01-20-15:14
- Log:react-native-ios-adaptive-modal
- Found bug w/AdaptiveModalConfigPresetDemo11
- Observation: The padding values are not being applied correctly to the RN modal content view.
- The possible cause could be that the wrong modal size or height/width value is being used for the modal content.
- Observation: The padding is applied to the modal content correctly when it is being dragged, but is incorrect during the duration of the snap animation.
- As such the possible culprit for the bug might be related to
AdaptiveModalDisplayLinkEventsNotifiable
.
- As such the possible culprit for the bug might be related to
- Observation: The padding values are not being applied correctly to the RN modal content view.
2024-01-20-17:32
-react-native-ios-adaptive-modal
(Commit) - Desc: Fix padding for modal content not being applied during modal snapping animation.2024-01-20-17:54
-react-native-ios-adaptive-modal
(Commit) - Desc: Ex - Impl.AdaptiveModalConfigPresetDemo12
2024-01-20-20:07
-react-native-ios-adaptive-modal
(Commit) - Desc: Ex - Impl.AdaptiveModalConfigPresetDemo13
2024-01-20-20:18
-react-native-ios-adaptive-modal
(Commit) - Desc: Ex - Impl.AdaptiveModalConfigPresetDemo14
2024-01-20-20:34
-react-native-ios-adaptive-modal
(Commit) - Desc: Ex - Impl.AdaptiveModalConfigPresetDemo15
2024-01-21-21:14
-react-native-ios-adaptive-modal
(Release: v0.2.1 | changes)
# Task: #c71585
- Task - Impl: Example - Recreate the examples from
adaptive-modal
'sAdaptiveModalConfigDemoPresets
+AdaptiveModalConfigDemoViewController
. - Status: WIP
2024-01-21-14:42
- Log:react-native-ios-adaptive-modal
- The first to recreate is showing the current snap point index in the modal.
- This relies on the modal events (task:
#2f4f4f
) being impl. - However, before exposing the adaptive modal events to RN, the refactor for
adaptive-modal
's interpolation point logic should be completed first.
2024-01-30-22:03
-react-native-ios-adaptive-modal
(Commit) - Desc: Ex - UpdatedAdaptiveModalViewTest01
to show the current snap point index.2024-02-03-17:04
-react-native-ios-adaptive-modal
(Commit) - Desc: Ex - UpdatedAdaptiveModalViewTest01
- Make "modal config index" pressable so that it changes the current modal config when pressed.
- Make "snap point index index" pressable so that it changes the current snap point index when pressed.
2024-02-03-17:10
- Log:react-native-ios-adaptive-modal
- Desc: Encountered bug w/
AdaptiveModalViewTest01
— Changing the modal config while the modal is visible does not update the position of the drag handle.
- Desc: Encountered bug w/
2024-02-03-20:45
-adaptive-modal
(Release:2.1.1
| Changes)- Desc: Fix bug where the modal drag handle does not update correctly when the current modal config is changed while the modal is visible.
- Desc: Fix bug where the modal drag handle does not update correctly when the current modal config is changed while the modal is visible.
2024-02-03-21:03
-react-native-ios-adaptive-modal
(Commit) - Desc: Ex - Update example pod dependencies (i.e.AdaptiveModal
).2024-02-04-02:00
- Log:react-native-ios-adaptive-modal
- Desc: Found bug w/
AdaptiveModalViewTest01
-AdaptiveModalKeyframeConfig.modalShadowOffset
not working. - Cause: Missing parser for
CGSize
.
- Desc: Found bug w/
2024-02-04-02:05
-react-native-ios-utilities
(Release: v4.3.0-9 | changes) - Desc: Add parser forCGSize
, i.e.CGSize+InitializableFromDictionary
.2024-02-05-19:44
-adaptive-modal
(Release:2.1.2
| Changes)- Desc: Bug fix - Drag handle offset not being updated during modal config change, i.e. fix diffing - modal drag handle offset.
- Desc: Bug fix - Drag handle offset not being updated during modal config change, i.e. fix diffing - modal drag handle offset.
2024-02-06-05:30
-react-native-ios-adaptive-modal
(Commits) - Desc: Ex - Impl.AdaptiveModalViewTest04
for testingpresentModal
+RNIAdaptiveModalCommandConfigPresent
.2024-02-06-14:38
-react-native-ios-utilities
(Release: v4.3.0-10 | changes) - Desc: Fix parsing forAnimationConfig
, i.e.AnimationConfig
.
# Task: #00008b
- Task - Impl: Docs - Create the draft version of the
README
containing videos/images showing theAdaptiveModalConfigDemoPresets
items. - Status: On Hold
2024-01-18-14:47
- Log: Before recording the videos, wait for the completion of the example/test presets + missing modal features.- Modal Manager Properties:
shouldEnableOverShooting
,overrideShouldSnapToUnderShootSnapPoint
,overrideShouldSnapToOvershootSnapPoint
,shouldDismissModalOnSnapToUnderShootSnapPoint
,shouldDismissModalOnSnapToOverShootSnapPoint
,shouldDismissKeyboardOnGestureSwipe
. - Modal Manager Commands:
dismiss
,snapTo(snapPointIndex:)
,snapTo(snapPointKey:)
,snapToPrevSnapPointIndex
,snapToCurrentSnapPointIndex
,snapToNextSnapPointIndex
,snapTo(overrideSnapPointConfig:)
,clearSnapPointOverride
. AdaptiveModalViewTest01
andAdaptiveModalViewTest02
should support diff. modal content "modes" + flags.- Button Config:
showDismissButton
,showCustomSnapPointButton
,showTextInputField
- Content Mode:
buttons
,scrollview
shouldIncreaseModalIndexOnTap
- Diff.
overShootSnapPoint
forsnapTo(overrideSnapPointConfig:)
per demo preset.
- Button Config:
- Modal Manager Properties:
2024-01-19-08:44
- Log: Task on hold, waiting for the ff:
# Task: #4b0082
-
Task - Fix: Modal Content Resizing -
AdaptiveModal
animations will only update the size of the modal content after the animation is finished.- This is because the layout animations for the modal content is applied via animating its auto layout constraints, and
RN
/YGLayout
is not informed of the size changes during the duration of the animation. - We need to implement a bunch of workarounds/features to get around this.
- This is because the layout animations for the modal content is applied via animating its auto layout constraints, and
-
Status: WIP
2024-01-06-04:37
:adaptive-modal
(Commits)2024-01-11-09-06
:adaptive-modal
(Commits)- Desc: Impl.
AdaptiveModalAnimationMode
(experimental), and fixed runtime error due to constraints being set tonan
values . - Releases: Version
1.5.0
(changes), Version1.5.1
(changes). - 📼 Attachment: 2024-01-11-09-23-44.mp4, 2024-01-11-09-29-52.mp4
- The attached video shows
adaptive-modal
running w/AdaptiveModalManager.animationMode
set to.viewPropertyAnimatorDiscrete
. - However, the current impl. for
animationMode
is still very buggy. - Bug: Secondary axis animation does not work, e.g. when you drag a top to bottom modal to the left or right, it stays in place and does not snap tot the correct position.
- Bug: When invoking the
dismiss
modal command, the exit snapping animation is laggy. - Bug: Only vertical + top to bottom modal works — modal's with snap direction that are left to right, right to left, and top to bottom are broken.
- The attached video shows
- Desc: Impl.
2024-01-11-13:11
: Log -react-native-ios-adaptive-modal
- 📼 Attachment: 2024-01-11-13-14-55.mp4, 2024-01-11-13-18-02.mp4
- Shows
AdaptiveModalViewTest01
withAdaptiveModalManager.animationMode
set to.viewPropertyAnimatorDiscrete
, withmodalContentAnchorMode
set tostretch
. - There are less stutters compared to before
AdaptiveModalManager.animationMode
+AdaptiveModalAnimationMode
was impl.
- Shows
- 📼 Attachment: 2024-01-11-13-32-36.mp4, 2024-01-11-13-40-37.mp4
- Shows
AdaptiveModalViewTest01
withAdaptiveModalManager.animationMode
set to.viewPropertyAnimatorDiscrete
, withmodalContentAnchorMode
set tocenter
.
- Shows
2024-01-11-21:18:19
:adaptive-modal
(Commits)- Desc: Fix
AdaptiveModalAnimationMode.viewPropertyAnimatorDiscrete
-related bugs - Releases: Version
1.5.2
(changes), Version1.5.3
(changes), Version1.5.4
(changes). - 📼 Attachment: 2024-01-11-21-39-20.mp4
- The bugs from the initial impl. of
AdaptiveModalManager.animationMode
+AdaptiveModalAnimationMode.viewPropertyAnimatorDiscrete
has been fixed, however it's still a bit janky. - Bug: Custom snap point bug - Sometimes, when snapping to a custom snap point override, there is no animation; instead it snaps to the new snap point immediately.
- The bugs from the initial impl. of
- Desc: Fix
2024-01-12-08:06
:react-native-ios-adaptive-modal
(Commits)- Impl. prop
modalAnimationMode
. - Impl. prop
shouldEnableContinuousLayoutResizingDuringAnimation
. - Refactored
RNIAdaptiveModalView.modalManager
AdaptiveModalManager
instancing + cleanup. - Updated examples - Added more toggles to
AdaptiveModalViewTest01
for configuring the props forAdaptiveModalView
. - Releases: Version v0.2.0 (changes)
- 📼 Attachment:
01-render-2024-01-12-08-32-05.mp4
- Impl. prop
- 📼 Attachment: 2024-01-11-13-14-55.mp4, 2024-01-11-13-18-02.mp4
# Task: #8b008b
- Task - Impl:
react-native-ios-adaptive-modal
- Add support different modes for positioning/resizing the modal content.- Related to "Modal Content Resizing".
- Anchor:
left
,right
,top
,bottom
,center
. - Sizing:
stretch
,none
. - Each modal content view can be anchored individually.
- For example: this will allow you to anchor a button at the bottom of the modal content, and a close button in the top right, etc.
- This way, when the modal content resizes, these UI elements will be at the correct place.
- Status: WIP
2024-01-08-07:26
:react-native-ios-utilities
(Commits)2024-01-08-07:31
:react-native-ios-utilities
(Commits)2024-01-08-10:19
:react-native-ios-adaptive-modal
(Commits)- Desc: Refactor modal content + presentation logic, and impl,
AdaptiveModalView.modalContentAnchorMode
prop.
- Desc: Refactor modal content + presentation logic, and impl,
2024-01-08-11:17
:react-native-ios-adaptive-modal
(Commits)- Desc: Added
AdaptiveModalViewTest02
for testing scrollview.
- Desc: Added
# Task: #ee82ee
- Task - Refactor:
adaptive-modal
- Re-writeAdaptiveModalSnapPointConfig
- Extract to two separate types, e.g.
AdaptiveModalSnapPointConfig
, andAdaptiveModalSnapPoint
,- Relationship: Such that
AdaptiveModalSnapPointConfig
produces aAdaptiveModalSnapPoint
, andAdaptiveModalSnapPoint
is derived from aAdaptiveModalSnapPointConfig
. - Refactor
AdaptiveModalSnapPointConfig
from an enum w/ associated value to a standard struct.AdaptiveModalSnapPointConfig
- a property for the current snapping mode, e.g.inBetween
, andstandard
.AdaptiveModalSnapPointConfig
- Can optionally have a "snap point key" property.
- Relationship: Such that
AdaptiveModalSnapPoint
- Should have a type that tells what kind of snap point it is, e.g.undershootPoint
,overshootPoint
,standardSnapPoint
,inBetweenSnapPoint
.
- Extract to two separate types, e.g.
- Status: Completed
2024-01-21-22:13
- Log:adaptive-modal
- Created new branchwip-3
.2024-01-21-22:16
-adaptive-modal
(Commits)- Desc: Refactored
AdaptiveModalSnapPointConfig
and createdAdaptiveModalSnapPoint
.
- Desc: Refactored
2024-01-24-00:07
-adaptive-modal
(Commit)- Desc: WIP - Replace
AdaptiveModalSnapPointConfig
Usage - Ran into some type problems -
inBetween
vs.standard
snap points. layoutConfig
is optional ininBetween
snap points, but required instandard
snap points.
- Desc: WIP - Replace
2024-01-24-00:09
- Log:adaptive-modal
- Abandoning changes in branchwip-3
.2024-01-24-00:13
- Log: Created new branchwip-4
.2024-01-25-15:55
-adaptive-modal
(Commits)- Desc: Completed refactor.
- Desc: Completed refactor.
2024-01-25-15:59
- Log:adaptive-modal
- Begin testing to check and fix any regressions/bugs caused by the refactor.2024-01-25-16:02
- Log:adaptive-modal
- Found bug in example - snap point presets- Repro: Bug w/
index: 3
+.demo04
. - Desc: Modal no longer dismisses when snapping the overshoot snap point.
- Repro: Bug w/
2024-01-25-17:37
- Log:adaptive-modal
(Continued)- Might be related to
_getClosestSnapPoint
?
- Might be related to
2024-01-25-17:52
- Log:adaptive-modal
(Continued)- 📄 Attachment: Log-2024-01-25-17-52-21.txt
- Overshoot snap point has wrong index.
2024-01-25-17:58
-adaptive-modal
(Commits)- Desc: Fix overshoot snap point has wrong index.
- Desc: Fix overshoot snap point has wrong index.
2024-01-25-18:11
- Log:adaptive-modal
- Found bug in example - snap point presets- Repro: Bug w/
index: 6
+.demo07
- Desc: Custom snap point + overshoot not working.
- Bug w/
AdaptiveModalManager
commandsnapTo(overrideSnapPointConfig:)
.
- Repro: Bug w/
2024-01-25-18:22
-adaptive-modal
(Commit)- Desc: Fix
AdaptiveModalManager.snapTo(overrideSnapPointConfig:)
overshoot snap point has wrong index.
- Desc: Fix
2024-01-25-18:24
- Log:adaptive-modal
- False alarm for:
index: 6
+.demo07
. - The behavior pre-refactor and post-refactor for the custom snap point + overshoot are identical, oops.
- False alarm for:
2024-01-25-18:33
- Log:adaptive-modal
- Found bug in example - snap point presets- Repro: Bug w/
index: 7
+.demo08
- 📼 Attachment: Simulator Screen Recording - iPhone 11 - iOS 17 - 2024-01-25 at 18.32.40.mp4
- Desc: Bug w/ override snap points + overshoot snap point - When overshooting while "override snap points" is active, the modal will snap back to the "regular" snap point.
- Repro: Bug w/
2024-01-25-20:50
-adaptive-modal
(Commits)- Desc: Fix bug w/ override snap points + overshoot snap point
- Fix wrong index used for override snap point in
AdaptiveModalManager.snapTo(overrideSnapPointConfig:)
. - Fix
AdaptiveModalManager._adjustInterpolationIndex
not using override snap points when adjusting snap point index.
- Fix wrong index used for override snap point in
- 📄 Attachment: Log-2024-01-25-20-49-44.txt
- 📼 Attachment: Simulator Screen Recording - iPhone 11 - iOS 17 - 2024-01-25 at 21.00.18.mp4
- Desc: Fix bug w/ override snap points + overshoot snap point
2024-01-25-22:37
- Log:adaptive-modal
- Desc: Finished testing
AdaptiveModalConfigDemoViewController
+AdaptiveModalConfigDemoPresets
- Proceed to testing paginated modal.
- Desc: Finished testing
2024-01-25-22:40
- Log:adaptive-modal
- Desc: Finished testingAdaptiveModalPageTestViewController
+AdaptiveModalConfigDemoPresets
.2024-01-25-22:41
- Log:adaptive-modal
- Desc: Merge changes from branchwip-4
tomain
.2024-01-25-22:49
-adaptive-modal
(Commits)2024-01-25-22:52
- Log: Begin refactoringreact-native-ios-adaptive-modal
to useadaptive-modal
version2.0.0
.2024-01-25-23:36
-react-native-ios-adaptive-modal
(Commits)- Desc: Update dep. to use
adaptive-modal
version2.0.0
, and refactor + fix build errors.
- Desc: Update dep. to use
2024-01-26-14:51
-react-native-ios-adaptive-modal
(Commits)
# Task: #2f4f4f
- Task - Impl:
react-native-ios-adaptive-modal
- Modal Events: Expose modal presentation events to RN. - Status: Completed
2024-01-27-22:43
-react-native-ios-adaptive-modal
(Commit)- Desc: Expose events from
AdaptiveModalPresentationEventsNotifiable
to RN.
- Desc: Expose events from
2024-01-29-01:37
-react-native-ios-adaptive-modal
(Commit)- Desc: Examples - Added
AdaptiveModalViewTest03
to test the modal events.
- Desc: Examples - Added
2024-01-29-01:41
- Log:react-native-ios-adaptive-modal
- While testing
AdaptiveModalViewTest03
found some layout performance issues when the modal's width is being resized. - It looks like react-native can't keep up with the layout updates whenever the modal's width is being resized.
- One way to potentially reduce the appearance of lag would be to debounce the layout updates.
- While testing
2024-01-30-15:56
-react-native-ios-adaptive-modal
(Commits)- Desc: Exposed
AdaptiveModalBackgroundTapDelegate
events to RN, and updated exampleAdaptiveModalViewTest03
to testonBackgroundTapGesture
event.
- Desc: Exposed
2024-01-30-20:57
-react-native-ios-adaptive-modal
(Commits)
# Task: #6b8e23
- Task - Impl:
react-native-ios-adaptive-modal
- Props - Expose modal manager flags as props.- E.g.
shouldEnableSnapping
,shouldEnableOverShooting
,shouldDismissKeyboardOnGestureSwipe
,shouldLockAxisToModalDirection
,overrideShouldSnapToUnderShootSnapPoint
,overrideShouldSnapToOvershootSnapPoint
,shouldDismissModalOnSnapToUnderShootSnapPoint
,shouldDismissModalOnSnapToOverShootSnapPoint
,isSwipeGestureEnabled
,isModalContentSwipeGestureEnabled
,allowModalToDragWhenAtMinScrollViewOffset
,allowModalToDragWhenAtMaxScrollViewOffset
,isModalDragHandleGestureEnabled
.
- E.g.
- Status: Completed
2024-01-31-02:44
-react-native-ios-adaptive-modal
(Commits)- Desc: Exposed
AdaptiveModalManager
flags as props to RN, and updated the example'sAdaptiveModalConfigPresets
+ test items to set/test the ff. props:shouldEnableOverShooting
,overrideShouldSnapToUnderShootSnapPoint
,overrideShouldSnapToOvershootSnapPoint
shouldDismissModalOnSnapToUnderShootSnapPoint
shouldDismissModalOnSnapToOverShootSnapPoint
,shouldDismissKeyboardOnGestureSwipe
.
- Releases: Version
v0.5.0
(changes).
- Desc: Exposed
# Task: #d2b48c
-
Task - Impl:
react-native-ios-adaptive-modal
- Modal Commands - Expose modal manager commands - Impl. methods to show/hide/control the modal from RN.- E.g.
notifyDidLayoutSubviews
,clearSnapPointOverride
,presentModal
+ extra args. (e.g.snapPointIndex
/snapPointKey
,animated
,animationConfig
),dismissModal
+ extra args. (e.g.useInBetweenSnapPoints
,animated
,animationConfig
,snapPointPreset
/keyframe
/snapPointIndex
),snapTo
+ args. (e.g.snapPointInde
,isAnimated
,animationConfig
),snapToClosestSnapPoint
,snapToPrevSnapPointIndex
,snapToCurrentSnapPointIndex
,snapToNextSnapPointIndex
,snapTo(overrideSnapPointConfig:)
,snapTo(key:)
.
- E.g.
-
Status: WIP
2024-01-31-22:15
-react-native-ios-adaptive-modal
(Commits)- Desc: Impl. modal module commands -
notifyDidLayoutSubviews
,clearSnapPointOverride
.
- Desc: Impl. modal module commands -
2024-01-31-22:40
-react-native-ios-adaptive-modal
(Commit)- Desc: Impl. modal module commands -
presentModal
.
- Desc: Impl. modal module commands -
2024-01-31-22:50
-react-native-ios-adaptive-modal
(Commits)- Desc: Update
AdaptiveModalView.presentModal
+ example test items.
- Desc: Update
2024-02-01-03:21:08
-react-native-ios-adaptive-modal
(Commit)- Desc: Impl. modal module commands -
dismissModal
.
- Desc: Impl. modal module commands -
2024-02-01-03:47
-react-native-ios-adaptive-modal
(Commit)- Desc: Impl. modal module commands -
snapTo
.
- Desc: Impl. modal module commands -
2024-02-01-03:47
-react-native-ios-adaptive-modal
(Commit)- Desc: Impl. modal module commands -
snapToOverride
.
- Desc: Impl. modal module commands -
2024-02-01-22:29
-react-native-ios-adaptive-modal
(Commit)- Desc: Impl. modal module commands -
snapToClosestSnapPoint
.
- Desc: Impl. modal module commands -
2024-02-01-22:30
-react-native-ios-adaptive-modal
(Commit)- Desc: Impl. modal module commands -
snapToPrevSnapPointIndex
.
- Desc: Impl. modal module commands -
2024-02-01-22:31
-react-native-ios-adaptive-modal
(Commit)- Desc: Impl. modal module commands -
snapToCurrentSnapPointIndex
.
- Desc: Impl. modal module commands -
2024-02-01-22:31
-react-native-ios-adaptive-modal
(Commit)- Desc: Impl. modal module commands -
snapToNextSnapPointIndex
.
- Desc: Impl. modal module commands -
2024-02-02-22:44
-react-native-ios-adaptive-modal
(Commits)- Desc: Impl.
AdaptiveModalView
commands -notifyDidLayoutSubviews
,clearSnapPointOverride
,dismissModal
,snapTo
,snapToOverride
,snapToClosestSnapPoint
,snapToPrevSnapPointIndex
,snapToCurrentSnapPointIndex
,snapToNextSnapPointIndex
.
- Desc: Impl.
2024-02-03-15:03
- Log: Make test components to test the modal commands.2024-02-03-16:06
-adaptive-modal
(Release:2.1.0
| Changes)- Desc: Updated
AdaptiveModalManager.snapToClosestSnapPoint
+AdaptiveModalManager.snapTo
.
- Desc: Updated
2024-02-03-16:36
-react-native-ios-adaptive-modal
(Commits)- Desc: Update dependencies, update
RNIAdaptiveModalView
modal command function param types, and updateRNIAdaptiveModalView.modalConfigProp
so that it triggerssnapToClosestSnapPoint
.
- Desc: Update dependencies, update
Misc/General Tasks
N/A