@onekeyfe/react-native-native-list 6.7.0-1 → 6.7.0-11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (84) hide show
  1. package/android/src/main/java/com/onekey/nativelist/HybridNativeList.kt +1 -1
  2. package/docs/SPEC.md +449 -14
  3. package/ios/HybridNativeList.swift +11 -3
  4. package/ios/RNCNativeListView.swift +10 -6
  5. package/ios/tests/NativeListLifecycleTests.swift +28 -0
  6. package/lib/module/NativeList.js +42 -21
  7. package/lib/module/NativeList.web.js +163 -32
  8. package/lib/module/ScrollEdgeEffect.js +8 -0
  9. package/lib/module/index.js +1 -0
  10. package/lib/module/validation.js +358 -47
  11. package/lib/module/web/NativeListWebEngine.js +373 -67
  12. package/lib/module/web/templates/ActivityRowRenderer.js +484 -5
  13. package/lib/module/web/templates/MarketRowRenderer.js +8 -3
  14. package/lib/module/web/templates/MarketTableRowRenderer.js +577 -0
  15. package/lib/module/web/templates/MediaTileRowRenderer.js +260 -5
  16. package/lib/module/web/templates/RowRendererRegistry.js +5 -3
  17. package/lib/module/web/templates/SectionHeaderRowRenderer.js +34 -1
  18. package/lib/nitrogen/generated/android/c++/JHybridNativeListSpec.cpp +10 -6
  19. package/lib/nitrogen/generated/android/c++/JHybridNativeListSpec.hpp +2 -2
  20. package/lib/nitrogen/generated/android/c++/JNativeListScrollEdgeEffect.hpp +61 -0
  21. package/lib/nitrogen/generated/android/c++/views/JHybridNativeListStateUpdater.cpp +3 -3
  22. package/lib/nitrogen/generated/android/kotlin/com/margelo/nitro/nativelist/HybridNativeListSpec.kt +1 -1
  23. package/lib/nitrogen/generated/android/kotlin/com/margelo/nitro/nativelist/NativeListScrollEdgeEffect.kt +24 -0
  24. package/lib/nitrogen/generated/ios/NativeListModule-Swift-Cxx-Umbrella.hpp +3 -0
  25. package/lib/nitrogen/generated/ios/c++/HybridNativeListSpecSwift.hpp +8 -4
  26. package/lib/nitrogen/generated/ios/c++/views/HybridNativeListComponent.mm +4 -4
  27. package/lib/nitrogen/generated/ios/swift/HybridNativeListSpec.swift +1 -1
  28. package/lib/nitrogen/generated/ios/swift/HybridNativeListSpec_cxx.swift +3 -3
  29. package/lib/nitrogen/generated/ios/swift/NativeListScrollEdgeEffect.swift +44 -0
  30. package/lib/nitrogen/generated/shared/c++/HybridNativeListSpec.cpp +2 -2
  31. package/lib/nitrogen/generated/shared/c++/HybridNativeListSpec.hpp +5 -2
  32. package/lib/nitrogen/generated/shared/c++/NativeListScrollEdgeEffect.hpp +80 -0
  33. package/lib/nitrogen/generated/shared/c++/views/HybridNativeListComponent.cpp +2 -2
  34. package/lib/nitrogen/generated/shared/c++/views/HybridNativeListComponent.hpp +4 -3
  35. package/lib/nitrogen/generated/shared/json/NativeListConfig.json +1 -1
  36. package/lib/typescript/src/NativeList.d.ts +2 -2
  37. package/lib/typescript/src/NativeList.nitro.d.ts +2 -1
  38. package/lib/typescript/src/NativeList.types.d.ts +14 -3
  39. package/lib/typescript/src/NativeList.web.d.ts +2 -2
  40. package/lib/typescript/src/ScrollEdgeEffect.d.ts +5 -0
  41. package/lib/typescript/src/index.d.ts +1 -0
  42. package/lib/typescript/src/models.d.ts +71 -1
  43. package/lib/typescript/src/validation.d.ts +3 -0
  44. package/lib/typescript/src/web/NativeListWebEngine.d.ts +26 -1
  45. package/lib/typescript/src/web/templates/ActivityRowRenderer.d.ts +3 -3
  46. package/lib/typescript/src/web/templates/MarketTableRowRenderer.d.ts +17 -0
  47. package/lib/typescript/src/web/templates/MediaTileRowRenderer.d.ts +3 -3
  48. package/lib/typescript/src/web/templates/MessageRowRenderer.d.ts +1 -1
  49. package/lib/typescript/src/web/templates/RowRendererRegistry.d.ts +3 -1
  50. package/nitrogen/generated/android/c++/JHybridNativeListSpec.cpp +10 -6
  51. package/nitrogen/generated/android/c++/JHybridNativeListSpec.hpp +2 -2
  52. package/nitrogen/generated/android/c++/JNativeListScrollEdgeEffect.hpp +61 -0
  53. package/nitrogen/generated/android/c++/views/JHybridNativeListStateUpdater.cpp +3 -3
  54. package/nitrogen/generated/android/kotlin/com/margelo/nitro/nativelist/HybridNativeListSpec.kt +1 -1
  55. package/nitrogen/generated/android/kotlin/com/margelo/nitro/nativelist/NativeListScrollEdgeEffect.kt +24 -0
  56. package/nitrogen/generated/ios/NativeListModule-Swift-Cxx-Umbrella.hpp +3 -0
  57. package/nitrogen/generated/ios/c++/HybridNativeListSpecSwift.hpp +8 -4
  58. package/nitrogen/generated/ios/c++/views/HybridNativeListComponent.mm +4 -4
  59. package/nitrogen/generated/ios/swift/HybridNativeListSpec.swift +1 -1
  60. package/nitrogen/generated/ios/swift/HybridNativeListSpec_cxx.swift +3 -3
  61. package/nitrogen/generated/ios/swift/NativeListScrollEdgeEffect.swift +44 -0
  62. package/nitrogen/generated/shared/c++/HybridNativeListSpec.cpp +2 -2
  63. package/nitrogen/generated/shared/c++/HybridNativeListSpec.hpp +5 -2
  64. package/nitrogen/generated/shared/c++/NativeListScrollEdgeEffect.hpp +80 -0
  65. package/nitrogen/generated/shared/c++/views/HybridNativeListComponent.cpp +2 -2
  66. package/nitrogen/generated/shared/c++/views/HybridNativeListComponent.hpp +4 -3
  67. package/nitrogen/generated/shared/json/NativeListConfig.json +1 -1
  68. package/package.json +3 -3
  69. package/react-native-native-list.podspec +4 -1
  70. package/src/NativeList.nitro.ts +3 -1
  71. package/src/NativeList.tsx +102 -60
  72. package/src/NativeList.types.ts +15 -3
  73. package/src/NativeList.web.tsx +264 -65
  74. package/src/ScrollEdgeEffect.ts +4 -0
  75. package/src/index.ts +2 -0
  76. package/src/models.ts +93 -0
  77. package/src/validation.ts +785 -72
  78. package/src/web/NativeListWebEngine.ts +625 -100
  79. package/src/web/templates/ActivityRowRenderer.ts +723 -7
  80. package/src/web/templates/MarketRowRenderer.ts +19 -3
  81. package/src/web/templates/MarketTableRowRenderer.ts +755 -0
  82. package/src/web/templates/MediaTileRowRenderer.ts +313 -5
  83. package/src/web/templates/RowRendererRegistry.ts +10 -5
  84. package/src/web/templates/SectionHeaderRowRenderer.ts +42 -1
@@ -52,7 +52,7 @@ class HybridNativeList(context: ThemedReactContext) : HybridNativeListSpec() {
52
52
  snapshot?.let { hostView.applySnapshot(it) }
53
53
  }
54
54
  }
55
- override var topScrollEdgeHard: Boolean = false
55
+ override var topScrollEdgeEffect: NativeListScrollEdgeEffect = NativeListScrollEdgeEffect.NONE
56
56
  override var topOverlayHeight: Double = 0.0
57
57
 
58
58
  override var snapshotJson: String = ""
package/docs/SPEC.md CHANGED
@@ -7,7 +7,7 @@ architecture and runtime evidence.
7
7
  ## Purpose and non-goals
8
8
 
9
9
  NativeList renders bounded data with fixed row templates on iOS, Android and
10
- Web. Data rows do not render arbitrary React children. Native-only named container slots
10
+ Web. Data rows do not render arbitrary React children. Named container slots
11
11
  may render React chrome outside the data-row stream. Integrators own overflow
12
12
  prevention; there is no automatic fitting or shrinking pass.
13
13
 
@@ -28,13 +28,14 @@ prevention; there is no automatic fitting or shrinking pass.
28
28
 
29
29
  ### iOS 26 fixed top scroll-edge overlay
30
30
 
31
- Standalone `NativeList` accepts optional `topScrollEdgeEffect="hard"` and
31
+ Standalone `NativeList` accepts optional
32
+ `topScrollEdgeEffect={ScrollEdgeEffect.Hard}` or `ScrollEdgeEffect.Soft` and
32
33
  `topOverlay` React content. Both are disabled by default. On iOS 26 or newer,
33
34
  the fixed overlay is a fourth native container slot, outside the row stream and
34
35
  outside the existing scrolling `listHeader`/`listEmpty`/`listFooter` slots.
35
36
  Fabric measures its height; the list owns an equal top inset on its collection
36
37
  view and binds UIKit's `UIScrollEdgeElementContainerInteraction` to that view,
37
- using the hard top edge style. The list restores its original inset and effect
38
+ using the requested top edge style. The list restores its original inset and effect
38
39
  on removal, disposal and reuse. The UI thread owns all view and UIKit state;
39
40
  there is no persistence, background-runtime state or per-frame JS callback.
40
41
  An invisible, noninteractive native label fills the overlay host so UIKit
@@ -45,6 +46,18 @@ existing layout and scrolling. Missing overlay or style changes nothing.
45
46
  Acceptance requires actual iOS 26 initial layout, long/short/empty scrolling,
46
47
  refresh and overlay replacement/removal, including dark mode.
47
48
 
49
+ `ScrollEdgeEffect` is an exported string enum (`Hard = 'hard'`, `Soft = 'soft'`);
50
+ the corresponding string literals remain valid prop values. Hard includes
51
+ UIKit's dividing line; Soft uses the gradual blurred transition. Nitro receives
52
+ an enum (`none | hard | soft`, default `none`) rather than a hard-effect boolean.
53
+ Changing Hard ↔ Soft preserves the overlay, inset, logical scroll offset and
54
+ saved original effect. Clearing the prop, removing the overlay, detaching or
55
+ disposing restores the original effect. This bridge change requires rebuilding
56
+ the matching native host. Soft selection is implemented in the wrapper and
57
+ native host. Focused JS tests cover enum forwarding and disabling; UIKit tests
58
+ cover style switching, overlay geometry and restoring the previous style.
59
+ Visual runtime acceptance remains separate from source, type and build checks.
60
+
48
61
  [README.md](../README.md) documents the snapshot, patch, selection, events and
49
62
  imperative API; [STYLE_SPEC.md](STYLE_SPEC.md) defines normalization, omitted
50
63
  style defaults and platform differences. Height precedence is
@@ -106,8 +119,9 @@ and does not create a separate accessibility target. Clearing the field, full
106
119
  rebind, recycling and disposal stop and hide the indicator; detached native views do
107
120
  not keep a visible animation. The History template's minimum content height
108
121
  increases from 16 to 20 points while loading. Explicit caller row/container
109
- heights still take precedence and must fit their padding. Web does not render
110
- this new native-only indicator; its existing section presentation is unchanged.
122
+ heights still take precedence and must fit their padding. Web History also
123
+ consumes titleLoading, using its existing section-slot geometry and the Web
124
+ History presentation described below.
111
125
 
112
126
  Acceptance requires loading → idle → loading reuse, title color updates and
113
127
  detachment on each native platform. A title's localized confirming text remains
@@ -168,6 +182,45 @@ All twelve templates have their own renderer family: Message, Rail, MediaTile,
168
182
  Action, System, Activity, DataRow, MetricCard, Market, Identity, SectionHeader and
169
183
  WalletGroup. Same-key family changes must replace the incompatible host. OneKeyImage owns image caches; NativeList owns row/slot binding identity.
170
184
 
185
+ Keys are opaque strings and MUST contain at least one non-whitespace character.
186
+ Leading and trailing whitespace is valid and MUST be preserved in snapshots,
187
+ patches, selection and emitted events on
188
+ iOS, Android and Web. The SDK MUST NOT trim or otherwise normalize keys;
189
+ `token` and `token ` identify different rows. Duplicate checks use the exact
190
+ string. This rule applies to all key fields validated by the shared protocol;
191
+ section index titles retain their separate development-only
192
+ no-surrounding-whitespace assertion.
193
+ The 256-code-unit key limit is a development assertion, not a production limit.
194
+
195
+ ### Validation environments and rejected input
196
+
197
+ Development builds (`__DEV__ === true`) run the complete snapshot and patch
198
+ contract assertions. Production builds run only serialization, required data
199
+ shape, supported renderer, finite geometry, identity and patch consistency
200
+ guards. Display budgets and style allowlists are development assertions.
201
+ Typography token resolution runs in both environments. Production treats empty
202
+ optional image URIs as missing images, preserving the existing visual fallback.
203
+ An empty optional image field omitted from a patch is a no-op, matching its
204
+ serialized native payload. Sparkline sample arrays retain their existing
205
+ 256-sample resource bound because the Web renderer passes samples as function
206
+ arguments; this protects the runtime's argument limit.
207
+
208
+ The component and Web engine contain input validation failures in both modes:
209
+ initial invalid input renders an empty list; rejected later snapshots or patch
210
+ batches preserve the last accepted state and are not dispatched to native.
211
+ Rejection emits a diagnostic without including row keys, text or image URLs.
212
+ Explicit calls to the exported validation functions still throw on rejected
213
+ input, so development tooling can inspect the full contract failure. Rejection
214
+ does not imply that the requested update succeeded. No row identity is trimmed,
215
+ truncated or regenerated, and no invalid row is silently dropped from a batch.
216
+
217
+ Status: implemented. Development/production JS regressions pass, including
218
+ native wrappers for iOS/Android and the Web DOM engine. Real Swift XCTest on an
219
+ iOS 27 simulator and Android instrumentation on API 35 verify production
220
+ serialization, normalized typography, opaque identities and duplicate-key
221
+ protection against the shipping native parsers. Full app/device rendering and
222
+ gesture acceptance remain separate from these input-boundary checks.
223
+
171
224
  ## Platform contract
172
225
 
173
226
  All platforms expose the same bounded style properties and public semantics.
@@ -224,13 +277,15 @@ state, all templates and container text, and retained selection/scroll behavior.
224
277
  ## Failures, fallback and limits
225
278
 
226
279
  Snapshot validation rejects malformed/duplicate-key input without partial
227
- application. Template field/array bounds and image fallback behavior are defined
280
+ application, through the contained failure behavior above. Development-only
281
+ template field/array bounds and image fallback behavior are defined
228
282
  in [ROW_TEMPLATES.md](ROW_TEMPLATES.md), [README.md](../README.md) and
229
283
  [DESIGN.md](DESIGN.md). This change adds the style surface's limits, defined in
230
284
  [STYLE_SPEC.md](STYLE_SPEC.md) §3.3/§4/§5: numeric bounds, `#RRGGBB`/`#RRGGBBAA`
231
285
  colors (including `listStyle.separator.color`), `groupCornerRadius` `0…40`, and
232
- rejection of any undeclared or unknown nested style key by `validateSnapshot`
233
- and `validatePatches`, where extra keys used to be ignored. It adds no retry
286
+ development-time rejection of undeclared or unknown nested style keys by
287
+ `validateSnapshot` and `validatePatches`. Production renderers ignore unsupported
288
+ style properties while minimum protocol guards remain active. It adds no retry
234
289
  policy or automatic layout correction.
235
290
 
236
291
  ## Performance and resources
@@ -545,8 +600,8 @@ is an opt-in native-only preview descriptor: `{ source: ImageSource, probeOrder:
545
600
  ('image' | 'video')[] }`. The order contains one or two distinct candidates.
546
601
  The caller supplies the order; the renderer never guesses asset semantics.
547
602
  When provided, media takes precedence over `image`, unless `imageState` is
548
- explicitly empty/error. Web keeps its existing `image` behavior; native callers
549
- that also target Web must supply that existing image independently.
603
+ explicitly empty/error. Web gallery media probing follows the separate Web migration contract below;
604
+ legacy Web image-only tiles retain their existing behavior.
550
605
 
551
606
  Image uses the shared OneKeyImage lifecycle. Video uses a paused, muted AVPlayer
552
607
  on iOS and Media3 ExoPlayer on Android, preserving the native Video source
@@ -606,8 +661,8 @@ leaked audio/player resources. Static API checks do not prove these cases.
606
661
  `listHeader`, `listEmpty` and `listFooter` accept React nodes on iOS and Android
607
662
  vertical lists only. They are optional and default to absent. They are common
608
663
  container capabilities, not row templates, and MUST NOT be used for per-item
609
- rendering. Horizontal orientation with any supplied slot is rejected. Web ignores
610
- these new native-only props; existing Web lists and callers retain their behavior.
664
+ rendering. Horizontal orientation with any supplied slot is rejected. Web container slots follow the separate Web parent-scrolling contract below;
665
+ the native placement and lifecycle described in this section remain unchanged.
611
666
 
612
667
  The order is header, data rows (or empty slot when there are no data rows), footer.
613
668
  On iOS, after the laid-out vertical content shrinks, an offset beyond the new
@@ -722,8 +777,8 @@ visible title/description/status lines, the description measured at the identity
722
777
  column's actual width (stacked or table, including the fee column), fee height and the
723
778
  footer-action button height. Android sizes the row to its content. The existing height override contract still applies. RTL follows
724
779
  semantic leading/trailing anchors. Clearing rich fields returns to the legacy
725
- renderer, and removing amount lines recycles their visual slots. Web rendering
726
- remains unchanged; rich fields are native-only until a separate Web migration.
780
+ renderer, and removing amount lines recycles their visual slots. Web rich presentation follows the separate Web migration contract below;
781
+ legacy Activity rows without rich fields retain their existing behavior.
727
782
 
728
783
  Acceptance: 1/2/6/32 lines, changed keys/order, paired icons and network overlays,
729
784
  small-number segments in amounts/fiat/fee (ceil(0.6 × parent font size), unchanged
@@ -808,3 +863,383 @@ The consumer Gradle project compiles the actual NativeListView and passes all
808
863
  seven Kotlin alignment tests; SwiftPM compiles the shipping helper and passes
809
864
  all seven geometry tests. These are local unit/build checks, not a new
810
865
  combined-package application or physical-device acceptance run.
866
+
867
+
868
+ ## Web parent scrolling and React container slots
869
+
870
+ Status: implemented. Focused DOM/wrapper tests and controlled consuming
871
+ Home/Market Web and Electron checks cover parent ownership, slots, host
872
+ replacement, hidden tabs, and the migrated touch/reorder interactions. These
873
+ checks do not establish native runtime or complete performance acceptance.
874
+
875
+ `webScrollHost` is Web-only: omitted preserves the existing owned viewport;
876
+ `null` defers initialization until the parent host is ready; an element opts
877
+ into that explicit parent as the sole vertical scroll owner. `webStickyInset`
878
+ is a non-negative finite CSS-pixel inset, default zero. Native ignores both.
879
+ External horizontal list orientation is rejected. The host is never inferred
880
+ from class names. Its replacement disposes the old engine and exact observers,
881
+ listeners, pending commands and anchors before the next host is attached.
882
+
883
+ On Web, listHeader/listEmpty/listFooter are React-owned siblings around the
884
+ engine-owned row host. They remain normal scrolling content, never row models;
885
+ empty replaces the body only when there are no rows. listEmpty takes precedence
886
+ over snapshot.emptyState. Grid slots span the list's complete width and reserve
887
+ their actual intrinsic height. The wrapper owns an internal scroll viewport when
888
+ slots are used without an external parent; the slot-free internal path retains
889
+ its existing structure. No ReactDOM dependency or arbitrary row children exist.
890
+
891
+ The engine reads list-local width, row-host origin, host viewport intersection,
892
+ sticky inset and complete wrapper bounds together. Row-index/key scrolling is
893
+ relative to the data body; scrollToOffset starts at the complete container,
894
+ including its header, and scrollToEnd includes the final footer. End reached
895
+ is based on visible data-row indices, before footer content, as existing lists.
896
+ Hidden/zero-sized or fully offscreen lists emit no end-reached event. Resize,
897
+ slot and ancestor layout changes remeasure origin. Increasing content before a
898
+ visible row preserves that row's screen position while the parent is scrolled.
899
+ No React state updates run on scroll frames. External refresh gestures remain
900
+ owned by the parent control; only internal mode handles its own pull gesture.
901
+
902
+ The explicit external host captures scroll events from itself and descendant
903
+ scroll containers that are ancestors of the list root. Horizontal pager movement
904
+ therefore invalidates cached viewport intersection and restores visible rows on
905
+ the next scheduled frame. Scrolls within unrelated slots or list descendants do
906
+ not invalidate this list. Destroy removes the same capture listener; no second
907
+ vertical owner or scroll-position correction is introduced.
908
+
909
+ Required acceptance: unchanged slot-free internal behavior; parent content on
910
+ both sides and sticky inset; dynamic header/footer; empty to populated; grid
911
+ last row; all imperative alignments; null/ready/replaced host; hidden/visible;
912
+ unmount cleanup, mouse/touch scroll and drag autoscroll. Type/helper results do
913
+ not establish rendered product, native or performance acceptance.
914
+
915
+
916
+ ## Web Market table presentation
917
+
918
+ Status: implemented on the 6.7.0-1 source baseline. Package unit/type/build
919
+ checks and controlled Web/shared consumer backfill checks passed; consuming
920
+ Home/Market Web and Electron checks cover the migrated presentation. No native
921
+ runtime or completed performance acceptance is claimed.
922
+
923
+ MarketRow.webTable is an optional Web-only serializable presentation. It does
924
+ not change DataRow's 2..4-column contract or add a row type/native renderer.
925
+ Native parsers retain row dictionaries/JSON and read known fields; they ignore
926
+ webTable. Mobile callers continue emitting their existing Market snapshots
927
+ without this field, preserving their serialized shape. Shared validation checks
928
+ the complete declared extension on both platforms. No arbitrary React cells,
929
+ HTML, scripts or product formatting runs inside NativeList.
930
+
931
+ The presentation declares 1..12 unique keyed columns and one matching keyed
932
+ cell per column. Width/minWidth (0..4096 CSS px), flex (0..16), semantic alignment
933
+ and leading/trailing padding (0..64) are explicit. Presentation cell kinds are
934
+ favorite, asset, text and sparkline. Favorite has its own action/accessible
935
+ label/pressed state; asset uses existing leading image primitives, title/badges
936
+ and a secondary line optionally replaced on row hover/focus; text accepts at
937
+ most eight caller-formatted primary/secondary text parts with existing small
938
+ number segments and typography; sparkline accepts at most256 finite numeric
939
+ samples, explicit size and colors. Unknown fields are rejected. Table rows use
940
+ an explicit row/container height. Text is single-line with ellipsis; no automatic
941
+ multiline geometry or business numeric interpretation exists.
942
+
943
+ The consumer derives mobile fields and table cells from the same domain row.
944
+ A quote transaction changes its formatted scalar fields and table cells together.
945
+ A legacy scalar-only price/change patch on a table row is rejected unless it
946
+ also supplies its corresponding table presentation, preventing hidden/visible
947
+ values from diverging. Stable-column/same-image patches update only changed
948
+ cells, preserving body/avatar identity and avoiding geometry reads/layout.
949
+ Changes to column structure, image/badge/action identity invalidate anchors and
950
+ use normal rebind/layout. Header and body take widths from the same consumer
951
+ column calculation; React retains sorting/header/filter portals.
952
+
953
+ The Web registry separately pools market and marketTable presentations while
954
+ both retain type:market. Row keys, revisions, anchor epochs and event dispatch
955
+ remain common. Cell actions use data-native-list-action; favorite/copy/badge
956
+ buttons do not activate the row. Recycling clears actions, title/aria, hover
957
+ and styles and disposes image leases. The SDK emits copy action data; application
958
+ copyText/logging remains consumer-owned. Sparklines use bounded numeric drawing,
959
+ not arbitrary SVG/HTML input.
960
+
961
+ Acceptance: every cell kind, dynamic formatting, hover/focus/keyboard actions,
962
+ row/presentation recycling, strict validation, native dictionary safe-ignore,
963
+ header/body geometry, 100 quote ticks preserving nodes with zero geometry reads,
964
+ then a real complex Market table before expanding to all five families.
965
+
966
+
967
+ ### Web grid fractional column geometry
968
+
969
+ Status: implemented; fractional geometry verified in focused DOM/browser and
970
+ controlled consuming NFT backfill checks.
971
+ Web grid columns divide
972
+ available CSS width without flooring each cell. With non-integral division,
973
+ all column edges and width-derived tile heights retain the fractional value;
974
+ the final column reaches the content edge without accumulating discarded
975
+ pixels. Item spacing, horizontal padding and structural full-span rows retain
976
+ their existing meanings. Native rounding is unchanged. Known app Web consumers
977
+ are the migrated NFT grid and developer gallery; external SDK consumers are not
978
+ claimed audited. Required geometry coverage: 2/3/4/6/7 columns, divisible and
979
+ fractional widths, spacing, padding, row height and structural/footer boundaries.
980
+
981
+ Table column width is the CSS base width. When flex is supplied, it grows with
982
+ `flex-basis:auto`, matching the consumer's existing fixed-base React column;
983
+ without flex, width remains fixed. Pausing a Web parent-host list retains only
984
+ its last row-host height in normal flow while releasing row DOM/avatar leases.
985
+ The wrapper preserves the engine's successfully patched snapshot for host
986
+ reconstruction; inactive patches merge into one latest snapshot, with no
987
+ retained batch queue. A rejected imperative snapshot never replaces that state.
988
+
989
+ Stock asset cells additionally declare lineGap (0...8, default4), up to three
990
+ secondaryBadges limited to the existing Market badge key/text/style subset, and up to four hoverImages
991
+ using ImageSource. Secondary badges precede the company name. Hover logos follow
992
+ the variant-count text at16 CSS px with a1px page-background ring and4px overlap,
993
+ matching the consumer's existing finite logo group. Geometry/badge/image changes
994
+ use normal rebind and release replaced image leases; price-only updates retain
995
+ these nodes. No native caller emits these Web-only fields.
996
+
997
+ Web gallery media follows the shared input precedence: media wins over image,
998
+ unless an explicit empty/error imageState suppresses media probing. An empty/error
999
+ gallery without either source retains the gallery fallback surface when
1000
+ imageState explicitly selects that state.
1001
+
1002
+ Web gallery media preserves the consuming NFT card presentation: healthy image
1003
+ and exhausted fallback surfaces have a10px radius, while a healthy video surface
1004
+ has square corners. The image/video frame uses the list page background; only
1005
+ the exhausted fallback surface uses the strong background. Rebinding the same
1006
+ video key retains square corners, and failed-video fallback to an image restores
1007
+ the image radius. This is Web renderer behavior; native media presentation and
1008
+ probe-order contracts are unchanged.
1009
+
1010
+ Gallery pointer activation follows the actual media-card body; extra grid row
1011
+ height reserved between cards does not enlarge its pointer hit area. Keyboard
1012
+ row activation remains supported through the normal row keyboard handler.
1013
+
1014
+ When React listEmpty owns an empty list, content bottom padding follows that
1015
+ empty slot instead of advancing its origin. Header/top padding retain their
1016
+ positions, and populated row/footer padding semantics remain unchanged.
1017
+
1018
+ Text cells may declare partGap (0...8 CSS px, default2) for their caller-formatted
1019
+ inline parts. Favorite cells may declare hoverActionKey; hover/focus emits this
1020
+ anchored help action, while click/Enter/Space emits actionKey. No browser title
1021
+ bubble is added. Pointer leave/focus departure invalidate help anchors. Existing
1022
+ Market badge styles apply to table title pills and their title gap is4px.
1023
+
1024
+ Web table title badges accept only declared key/text/iconName/icon/colors/action/
1025
+ accessibility/style fields. The unused native tone field is not accepted in this
1026
+ presentation. Inline icon sources use image primitives and release on recycling.
1027
+
1028
+
1029
+ ### Web Market watchlist actions and reorder
1030
+
1031
+ Only a market row with `webTable.draggable:true` and list capability
1032
+ `reorderable:true` joins existing Web reorder. Other Market rows and native
1033
+ reorder semantics are unchanged. `webTable.contextMenuActionKey` declares a
1034
+ bounded row context-menu action; right click is prevented only for such rows,
1035
+ and nested cell actions retain ownership. Context menu and Market long press
1036
+ may emit `RowActionEvent.windowPoint`, finite client/window CSS pixel coordinates.
1037
+ Keyboard-triggered context menus use the row anchor rectangle when pointer
1038
+ coordinates are unavailable. Anchors retain binding epoch validation and are
1039
+ invalidated on scroll/rebind/layout/destroy; consumers close their menu on that
1040
+ invalidation. Compact Market mouse/pen long press cancels after 3px of pointer
1041
+ movement; touch follows actual touchmove as specified below. Table rows retain
1042
+ the 10px pointer threshold.
1043
+ Gallery, wallet and other row reorder eligibility stays unchanged. A gesture
1044
+ that activates row reorder cancels pending Market long press and suppresses its
1045
+ subsequent row navigation.
1046
+
1047
+ Compact Web Market network corners honor the declared ImageSource dimensions
1048
+ (default 16px), with the existing corner padding outside the image. Native image
1049
+ rendering is unchanged. Consumer Web presentation permits its original SVG image
1050
+ sources without changing default native mapper output.
1051
+
1052
+
1053
+ ### Web ordered image fallback sources
1054
+
1055
+ ImageSource.fallbackUris is an optional Web-only ordered continuation after uri.
1056
+ It retains the complete caller-provided sequence (no truncation or deduplication).
1057
+ Empty or unusable continuation entries are skipped in order until a usable URI
1058
+ is found or the complete sequence is exhausted. Exhaustion reaches the declared
1059
+ visual fallback. Skipped entries consume no retry budget; each usable URI
1060
+ uses its declared retryTimes before proceeding; Market Web callers pass the
1061
+ existing ImageV2 default of one retry per source. This array path does not change
1062
+ legacy fallbackUri switching/retry order when fallbackUris is absent. Native
1063
+ callers do not emit this field. Validation requires an array of serializable
1064
+ strings. Rebind identity includes the complete array; quote-only changes retain
1065
+ the image node, while a changed chain rebinds and cancels previous retries.
1066
+ Recycling/destroy disposes listeners, retry timers and avatar subscriptions.
1067
+ Required coverage: one/two/three+ sources, first two fail/third succeeds, terminal
1068
+ failure, empty continuation, chain replacement/cancel and legacy fallbackUri.
1069
+
1070
+ Enhanced Web History section titles retain the consumer headingXs 0.8px letter
1071
+ spacing; hover uses rowPressedBackground and pointer-active enhanced History
1072
+ uses rowSelectedBackground. Other Activity presentations are unchanged.
1073
+
1074
+ Parent-scroll compact Market rows retain the consumer's pointer states: ordinary
1075
+ token/perp cards use active opacity0.8, stock cards active selected background.
1076
+ Consumers supply the page background as hover color. New table image fallbacks
1077
+ use a28px icon in the40px image frame; compact32px frames retain24px icons.
1078
+ These styles do not change legacy internally scrolling Market rows.
1079
+
1080
+ The optional theme.imageFallbackBackground is consumed by Web only when a
1081
+ declared visual fallback is displayed; unset leaves the existing transparent
1082
+ fallback over its original frame. It never changes healthy image backgrounds,
1083
+ Stock tags or hover logo slots. Native callers do not emit it. HoverImages may
1084
+ contain explicit null entries to preserve the original16px empty round logo
1085
+ slots, including their ring/overlap/order; non-null entries remain ImageSource
1086
+ and the existing four-slot limit stays unchanged.
1087
+
1088
+ Compact Market subtitlePrefix preserves intrinsic text width with flex-shrink
1089
+ and its existing maxWidth cap; it does not grow short names to that cap.
1090
+ Its optional Web-only hoverActionKey requests anchored help only when the
1091
+ actual prefix text is truncated (scrollWidth > clientWidth + 1). The consumer
1092
+ owns the existing tooltip content/presentation. Pointer/focus departure, scroll,
1093
+ rebind and destroy invalidate its existing anchor. Text, cap or action identity
1094
+ changes use normal rebind; unchanged quote updates preserve that node/focus.
1095
+ Native callers do not emit this field and native renderers ignore it.
1096
+
1097
+
1098
+ ### Host-provided Web fonts
1099
+
1100
+ configureNativeListFonts and NativeListFontFamilies retain the source baseline
1101
+ public API and validation. In the historical controlled 3.0.177 consumer
1102
+ backfill, only Web was backported:
1103
+ empty configuration uses system families; each supplied regular/medium/semibold/
1104
+ bold name belongs to fonts already loaded by the UI host. Hosts load fonts
1105
+ before configuring the mapping; the historical consumer supplied Roobert for
1106
+ all four weights. The SDK registers no fonts. That controlled backfill retained
1107
+ the 3.0.177 native wrapper and native platform font behavior.
1108
+ Web roots, section rails, reorder previews and all finite row text presentations
1109
+ select the family matching their existing numeric weight; layout and numeric
1110
+ weights are unchanged. A live configuration change invalidates active anchors,
1111
+ cancels reorder, clears measurement caches and remeasures; the same configuration
1112
+ is a no-op. A paused/null host initializes with the latest configuration.
1113
+ The 6.7.0-1 source integration preserves its existing native font policy/API.
1114
+
1115
+ Market Web badge text uses tabular numeric glyphs, matching the consuming
1116
+ Market text style for leverage/provider labels. This rule is limited to the
1117
+ Market badge renderer class; generic Activity/time badge typography is unchanged.
1118
+
1119
+ React prop snapshots commit in the layout phase alongside React-owned slots.
1120
+ For an external host with cached viewport dimensions, recomputation calculates
1121
+ and expands the normal-flow row extent before geometry reads, avoiding an append
1122
+ plus footer-removal intermediate clamp. The calculated layout is reused when
1123
+ viewport dimensions are unchanged; changed dimensions receive a fresh layout.
1124
+ Final measured layout owns legitimate shrinking; no scroll restoration offset
1125
+ or retained minimum-height state is added. First creation without cached geometry
1126
+ and imperative snapshot acceptance retain their existing contracts.
1127
+
1128
+ Web gallery media fit consumes the existing ImageSource.contentFit values:
1129
+ cover/contain/fill map directly to CSS object-fit and center maps to none.
1130
+ When omitted, a video uses contain and an image uses cover, preserving the
1131
+ consuming Web NFT defaults. Failed-video transitions resolve the image default
1132
+ again rather than retaining video fit. Native fit/probe contracts are unchanged.
1133
+
1134
+
1135
+ ### Source integration status (2026-10-16)
1136
+
1137
+ The Web migration was integrated onto source 655789b01 (6.7.0-1), preserving
1138
+ its native font resolver, iOS 26 overlay, package metadata and native implementation.
1139
+ The PR rebases that source onto main dd0d77af3, whose independent desktop Windows
1140
+ release changes do not overlap this package. The consuming PR targets 3.0.180;
1141
+ its reproducible patch and dependency verification are separate from the
1142
+ historical 3.0.177 backfill evidence below.
1143
+ The prior 3.0.178 source integration was an intermediate validated checkpoint.
1144
+ Controlled Web/shared consumer backfill was verified against 3.0.177 while
1145
+ retaining that version's native wrapper, binary boundary and native type
1146
+ declarations. This historical backfill is separate from consumer dependency
1147
+ updates.
1148
+ Merged package tests/typecheck/build and controlled consumer backfill smoke
1149
+ passed. The final Web-focused suite passed 89 checks; broader package checks
1150
+ and consuming Web/Electron presentation checks are recorded separately. Pending
1151
+ remote-row display and the real business hook/controller navigation contract
1152
+ were verified with explicit auxiliary fixtures/stub boundaries; no real eligible
1153
+ account SendReplaceTx confirmation page, signing, or broadcast was exercised.
1154
+ The consumer backfill does not establish native runtime acceptance of this
1155
+ merged package. Final performance sampling was stopped at the user's request
1156
+ and is partial evidence, not a completed performance signoff.
1157
+
1158
+ ### Desktop/Web Market asset parity
1159
+
1160
+ The Web table asset renderer consumes the existing leading visual backgroundColor
1161
+ and borderColor descriptors without changing the schema or native primitives.
1162
+ Its token frame remains40 CSS px including an optional1px solid border; the main
1163
+ bitmap fills the content box (38px with border,40px without). Overlay visuals
1164
+ remain outside that frame and fallback surfaces retain their existing color/icon
1165
+ contract. Theme/leading changes rebind the visual and clear old border styles.
1166
+ The address-copy revealed line uses a2px text-to-action gap, while Stock hover
1167
+ logo groups retain their4px gap and overlap geometry. No other text-part gaps
1168
+ change. Regression acceptance includes Dark/Light recycled visuals, preserved
1169
+ network overlays, independent copy actions and Stock hover group spacing.
1170
+
1171
+ Gallery collection subtitles retain an 8px trailing text inset whether or not
1172
+ a network thumbnail is present. The subtitle uses border-box sizing and its row
1173
+ has no extra gap, preserving the same 8px separation with a thumbnail and the
1174
+ legacy truncation width without one. Legacy MediaTile/native rendering is
1175
+ unchanged.
1176
+
1177
+ Compact Market touch long-press cancellation follows actual `touchmove`
1178
+ events and valid touch coordinates beyond the existing 3px stationary limit.
1179
+ Pointer-only micro-movement within browser tap tolerance does not prematurely
1180
+ cancel a touch long-press. Pointer cancellation and real ancestor scrolling
1181
+ still cancel it; mouse, pen and table pointer thresholds remain unchanged.
1182
+ The passive touch listener is removed when the engine is destroyed.
1183
+
1184
+ Table secondary-line pointer hover is enabled only when the primary input
1185
+ reports `(hover: hover)`, matching the consuming Web row's hover media rule.
1186
+ Touch capability alone does not disable hover. Existing focus-within reveal
1187
+ remains available to keyboard navigation; no input-modality configuration or
1188
+ native behavior is introduced.
1189
+
1190
+ The declared table asset background remains on its outer token frame during
1191
+ source loading, matching the consumer's Token wrapper. The existing image
1192
+ placeholder/retry path and fallback span are unchanged; only the fallback span
1193
+ uses the fallback background. A solid frame border does not move external
1194
+ overlays: their primitive-generated edge positions are shifted outward by the
1195
+ 1px border once per new visual, preserving the caller's unbordered outer-anchor
1196
+ geometry. No shift is accumulated during same-visual quote patches.
1197
+
1198
+ Table secondary-line clipping uses `overflow: clip` so keyboard focus cannot
1199
+ scroll the two-line reveal viewport in addition to its existing transform.
1200
+ Focus-within and primary-hover reveal behavior remain unchanged; no scroll
1201
+ position writes or global overflow policy are introduced.
1202
+
1203
+ Web history section headers consume the existing titleLoading flag with the
1204
+ original20px spinner,8px title gap and heading casing. The declared32/52px
1205
+ section slots remain unchanged; the pending title content retains its original
1206
+ 4px intrinsic overflow. Explicit60px stacked history content fills its stated
1207
+ row height; ordinary history rows retain their existing trailing spacing.
1208
+
1209
+ Web enhanced History badges preserve the existing small Badge geometry (8px horizontal padding, 4px radius, medium text). Warning backgrounds consume the declared cautionBackground theme value with the prior fallback when absent. Native rendering is unchanged.
1210
+
1211
+
1212
+ ### Web external parent-scroll commands
1213
+
1214
+ When a caller supplies webScrollHost, scroll commands use the DOM scrollTo method from that element's document realm. React Native Web may decorate a NativeScroller node with a differently shaped React Native scrollTo method; the DOM host contract must not invoke that method with DOM options. The native/ref APIs and internally owned NativeList viewport keep their existing behavior.
1215
+
1216
+ Existing Pager command-accepted/cancel notifications use the actual external scroll owner when supplied, otherwise the internally owned viewport. A list command cancels queued Pager restoration/top work; a Pager top command cancels a pending list command and stops motion on that same owner. Listener target guards and destruction removal must match. No new public method, event name or native behavior is introduced.
1217
+
1218
+
1219
+ ### Web Pager inset notifications
1220
+
1221
+ An externally hosted list listens for the existing Pager inset notification on
1222
+ its actual scroll owner, matching the notification target and removing the same
1223
+ listener on destroy. It measures the new content origin before Pager restores
1224
+ its C+B offset; a later ResizeObserver must not add that inset a second time.
1225
+ Ordinary subsequent slot-height changes retain the existing content-anchor
1226
+ compensation. Standalone lists continue listening on their own viewport.
1227
+
1228
+ ### Web History retained visual binding
1229
+
1230
+ Implemented contract: same-source History visuals retain their image, placeholder
1231
+ and corner nodes while image styles or table/stacked presentation change. Every
1232
+ bind restores the factory geometry and applies the current image style and
1233
+ presentation, including clearing omitted radius/contentFit/shape overrides.
1234
+ Presentation wrapper changes move the existing nodes and preserve asynchronous
1235
+ loading/error visibility; they do not recreate or reload an unchanged source.
1236
+ Changing the source set retains the existing rebuild/disposal behavior.
1237
+
1238
+ ### Web slot-list scroll ownership
1239
+
1240
+ When container slots create an owned Web scroll host without `webScrollHost`,
1241
+ that actual host exposes the existing `data-collapsible-pager-scroll` marker.
1242
+ A containing Web pager therefore applies insets, collapse/top commands and route
1243
+ restoration to the owned host, with slot content as its padding target. The
1244
+ ordinary no-slot viewport and explicit external-host paths keep their existing
1245
+ ownership; no Pager dependency or new API is required.
@@ -43,19 +43,27 @@ final class HybridNativeList: HybridNativeListSpec {
43
43
  didSet { if fontFamiliesJson != oldValue { fontsChanged = true } }
44
44
  }
45
45
 
46
- var topScrollEdgeHard = false {
46
+ var topScrollEdgeEffect: NativeListScrollEdgeEffect = .none {
47
47
  didSet {
48
48
  runOnMain { [weak self] in
49
- self?.hostView?.setTopScrollEdge(hard: self?.topScrollEdgeHard ?? false,
49
+ self?.hostView?.setTopScrollEdge(effect: self?.topEdgeStyle ?? .none,
50
50
  overlayHeight: CGFloat(self?.topOverlayHeight ?? 0))
51
51
  }
52
52
  }
53
53
  }
54
54
 
55
+ private var topEdgeStyle: NativeListTopScrollEdgeEffect {
56
+ switch topScrollEdgeEffect {
57
+ case .none: return .none
58
+ case .hard: return .hard
59
+ case .soft: return .soft
60
+ }
61
+ }
62
+
55
63
  var topOverlayHeight: Double = 0 {
56
64
  didSet {
57
65
  runOnMain { [weak self] in
58
- self?.hostView?.setTopScrollEdge(hard: self?.topScrollEdgeHard ?? false,
66
+ self?.hostView?.setTopScrollEdge(effect: self?.topEdgeStyle ?? .none,
59
67
  overlayHeight: CGFloat(self?.topOverlayHeight ?? 0))
60
68
  }
61
69
  }
@@ -3,6 +3,10 @@ import CoreFoundation
3
3
  import UIKit
4
4
  import UniformTypeIdentifiers
5
5
 
6
+ enum NativeListTopScrollEdgeEffect {
7
+ case none, hard, soft
8
+ }
9
+
6
10
  final class NativeListView: UIView {
7
11
  private var fonts = NativeListFontFamilies()
8
12
 
@@ -36,7 +40,7 @@ final class NativeListView: UIView {
36
40
  private var topEdgeInteraction: UIInteraction?
37
41
  private var topEdgeMarker: UILabel?
38
42
  private var originalTopEdgeStyle: AnyObject?
39
- private var topScrollEdgeHard = false
43
+ private var topScrollEdgeEffect: NativeListTopScrollEdgeEffect = .none
40
44
  private var requestedTopOverlayHeight: CGFloat = 0
41
45
  private var appliedTopOverlayInset: CGFloat = 0
42
46
 
@@ -78,8 +82,8 @@ final class NativeListView: UIView {
78
82
  }
79
83
  }
80
84
 
81
- func setTopScrollEdge(hard: Bool, overlayHeight: CGFloat) {
82
- topScrollEdgeHard = hard
85
+ func setTopScrollEdge(effect: NativeListTopScrollEdgeEffect, overlayHeight: CGFloat) {
86
+ topScrollEdgeEffect = effect
83
87
  requestedTopOverlayHeight = overlayHeight.isFinite ? max(0, overlayHeight) : 0
84
88
  updateTopScrollEdge()
85
89
  setNeedsLayout()
@@ -87,7 +91,7 @@ final class NativeListView: UIView {
87
91
 
88
92
  private func updateTopScrollEdge() {
89
93
  if #available(iOS 26.0, *) {
90
- let hasOverlay = topScrollEdgeHard && topOverlayContent != nil
94
+ let hasOverlay = topScrollEdgeEffect != .none && topOverlayContent != nil
91
95
  let enabled = hasOverlay && window != nil
92
96
  let nextInset = hasOverlay ? requestedTopOverlayHeight : 0
93
97
  if nextInset != appliedTopOverlayInset {
@@ -134,7 +138,7 @@ final class NativeListView: UIView {
134
138
  }
135
139
  originalTopEdgeStyle = nil
136
140
  }
137
- if enabled { collectionView.topEdgeEffect.style = .hard }
141
+ if enabled { collectionView.topEdgeEffect.style = topScrollEdgeEffect == .soft ? .soft : .hard }
138
142
  }
139
143
  }
140
144
 
@@ -2107,7 +2111,7 @@ final class NativeListView: UIView {
2107
2111
 
2108
2112
  func dispose() {
2109
2113
  guard !disposed else { return }
2110
- setTopScrollEdge(hard: false, overlayHeight: 0)
2114
+ setTopScrollEdge(effect: .none, overlayHeight: 0)
2111
2115
  disposed = true
2112
2116
 
2113
2117
  disposeActionAnchor()