Skip to content

Commit 4ddd900

Browse files
committed
verify(ui): carry objectui's overrides and focus-scope patch at the workspace root (objectstack#25697)
pnpm reads overrides and patchedDependencies only from the root pnpm-workspace.yaml, so the `pnpm` field removed from ui/package.json has to land here for the imported tree to resolve as it does in objectui: - the react 19.3.0 line (react, react-dom, @types/react, @types/react-dom); objectstack manifests still carry ^19.2.x ranges, which would otherwise resolve a second react next to objectui's exact 19.3.0 pins - objectui's security floors for qs, shell-quote, tmp and uuid (dompurify is already pinned at the root) - the @radix-ui/react-focus-scope patch, keyed to 1.1.16 and copied to patches/ next to the other root patches Verification branch only; not for merge. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01RSDL3SFtJaKzcymvCD8RsU
1 parent 0dad5c2 commit 4ddd900

2 files changed

Lines changed: 65 additions & 0 deletions

File tree

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
diff --git a/dist/index.js b/dist/index.js
2+
index e8906db3b1e87bfc568b75d72b7ed3d8d1d3c09a..7a05e0e4cffba466301ba1fb67067c0861af0a4d 100644
3+
--- a/dist/index.js
4+
+++ b/dist/index.js
5+
@@ -110,6 +110,10 @@ var FocusScope = /* @__PURE__ */ React.forwardRef(
6+
}, [trapped, container, focusScope.paused]);
7+
React.useEffect(() => {
8+
if (container) {
9+
+ if (focusScope.__pendingStackRemove !== void 0) {
10+
+ clearTimeout(focusScope.__pendingStackRemove);
11+
+ focusScope.__pendingStackRemove = void 0;
12+
+ }
13+
focusScopesStack.add(focusScope);
14+
const previouslyFocusedElement = document.activeElement;
15+
const hasFocusedCandidate = container.contains(previouslyFocusedElement);
16+
@@ -126,7 +130,8 @@ var FocusScope = /* @__PURE__ */ React.forwardRef(
17+
}
18+
return () => {
19+
container.removeEventListener(AUTOFOCUS_ON_MOUNT, onMountAutoFocus);
20+
- setTimeout(() => {
21+
+ focusScope.__pendingStackRemove = setTimeout(() => {
22+
+ focusScope.__pendingStackRemove = void 0;
23+
const unmountEvent = new CustomEvent(AUTOFOCUS_ON_UNMOUNT, EVENT_OPTIONS);
24+
container.addEventListener(AUTOFOCUS_ON_UNMOUNT, onUnmountAutoFocus);
25+
container.dispatchEvent(unmountEvent);
26+
diff --git a/dist/index.mjs b/dist/index.mjs
27+
index 030ff1a4d2383c9a0a1ba850aa4591890f028784..3dd39a90db9886bc495014a6e4136773e3548448 100644
28+
--- a/dist/index.mjs
29+
+++ b/dist/index.mjs
30+
@@ -75,6 +75,10 @@ var FocusScope = /* @__PURE__ */ React.forwardRef(
31+
}, [trapped, container, focusScope.paused]);
32+
React.useEffect(() => {
33+
if (container) {
34+
+ if (focusScope.__pendingStackRemove !== void 0) {
35+
+ clearTimeout(focusScope.__pendingStackRemove);
36+
+ focusScope.__pendingStackRemove = void 0;
37+
+ }
38+
focusScopesStack.add(focusScope);
39+
const previouslyFocusedElement = document.activeElement;
40+
const hasFocusedCandidate = container.contains(previouslyFocusedElement);
41+
@@ -91,7 +95,8 @@ var FocusScope = /* @__PURE__ */ React.forwardRef(
42+
}
43+
return () => {
44+
container.removeEventListener(AUTOFOCUS_ON_MOUNT, onMountAutoFocus);
45+
- setTimeout(() => {
46+
+ focusScope.__pendingStackRemove = setTimeout(() => {
47+
+ focusScope.__pendingStackRemove = void 0;
48+
const unmountEvent = new CustomEvent(AUTOFOCUS_ON_UNMOUNT, EVENT_OPTIONS);
49+
container.addEventListener(AUTOFOCUS_ON_UNMOUNT, onUnmountAutoFocus);
50+
container.dispatchEvent(unmountEvent);

‎pnpm-workspace.yaml‎

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,9 @@ onlyBuiltDependencies:
7575
patchedDependencies:
7676
tsup@8.5.1: patches/tsup@8.5.1.patch
7777
tsx@4.23.15: patches/tsx@4.23.15.patch
78+
# objectui's focus-scope patch (verification branch for objectstack#25697);
79+
# it was keyed unversioned in ui/package.json's ignored `pnpm` field.
80+
'@radix-ui/react-focus-scope@1.1.16': patches/@radix-ui__react-focus-scope.patch
7881

7982
# Transitive-dependency version pins. pnpm v10 reads `overrides` from THIS file
8083
# — the `pnpm.overrides` block in package.json is silently ignored — so all
@@ -233,6 +236,18 @@ patchedDependencies:
233236
# legacy agent chain; force the patched 2.0.1 line.
234237
overrides:
235238
esbuild: '>=0.28.1'
239+
# objectui's security floors, from ui/package.json's ignored `pnpm` field
240+
# (verification branch for objectstack#25697; dompurify is already pinned).
241+
'qs@<6.15.2': '^6.15.2'
242+
'shell-quote@<1.8.4': '^1.8.4'
243+
'tmp@<0.2.6': '^0.2.6'
244+
'uuid@<11.1.1': '^11.1.1'
245+
# objectui's single react line (verification branch for objectstack#25697):
246+
# objectui pins 19.3.0 exactly; objectstack manifests still carry ^19.2.x ranges.
247+
react: 19.3.0
248+
react-dom: 19.3.0
249+
'@types/react': 19.3.0
250+
'@types/react-dom': 19.3.0
236251
'minimatch@<11.0.0': '^10.2.3'
237252
'tar@>=2.0.0 <8.0.0': '^7.5.11'
238253
'form-data@<5.0.0': '>=4.0.6'

0 commit comments

Comments
 (0)