🚧 fix: OriginalDialog Modal Tooltip and Dropdown Menu Regressions from (#10975, #10952, #11008) (#11023)
Some checks are pending
Docker Dev Branch Images Build / build (Dockerfile, lc-dev, node) (push) Waiting to run
Docker Dev Branch Images Build / build (Dockerfile.multi, lc-dev-api, api-build) (push) Waiting to run

* fix: tooltips appear over z-index 100

* fix: tooltips and dropdowns now have xpected behavior again with escape

* fix: query document, not on ref, in case of portaled content, and allows escape to close dialog properly for my files modal

* fix: console warning about improperly passing props
This commit is contained in:
Dustin Healy 2025-12-18 06:28:27 -08:00 committed by GitHub
parent afb67fcf16
commit 1f695e0cdc
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
6 changed files with 200 additions and 339 deletions

View file

@ -39,10 +39,10 @@
"@marsidev/react-turnstile": "^1.1.0", "@marsidev/react-turnstile": "^1.1.0",
"@mcp-ui/client": "^5.7.0", "@mcp-ui/client": "^5.7.0",
"@radix-ui/react-accordion": "^1.1.2", "@radix-ui/react-accordion": "^1.1.2",
"@radix-ui/react-alert-dialog": "^1.1.15", "@radix-ui/react-alert-dialog": "1.0.2",
"@radix-ui/react-checkbox": "^1.0.3", "@radix-ui/react-checkbox": "^1.0.3",
"@radix-ui/react-collapsible": "^1.0.3", "@radix-ui/react-collapsible": "^1.0.3",
"@radix-ui/react-dialog": "^1.1.15", "@radix-ui/react-dialog": "1.0.2",
"@radix-ui/react-dropdown-menu": "^2.1.1", "@radix-ui/react-dropdown-menu": "^2.1.1",
"@radix-ui/react-hover-card": "^1.0.5", "@radix-ui/react-hover-card": "^1.0.5",
"@radix-ui/react-icons": "^1.3.0", "@radix-ui/react-icons": "^1.3.0",

View file

@ -2561,7 +2561,7 @@ html {
} }
.tooltip { .tooltip {
z-index: 50; z-index: 150;
cursor: pointer; cursor: pointer;
border-radius: 0.275rem; border-radius: 0.275rem;
background-color: var(--surface-primary); background-color: var(--surface-primary);
@ -2915,6 +2915,6 @@ html {
scrollbar-width: none; /* Firefox */ scrollbar-width: none; /* Firefox */
} }
.sharepoint-picker-bg{ .sharepoint-picker-bg {
background-color: #F5F5F5; background-color: #f5f5f5;
} }

491
package-lock.json generated
View file

@ -1611,10 +1611,10 @@
"@marsidev/react-turnstile": "^1.1.0", "@marsidev/react-turnstile": "^1.1.0",
"@mcp-ui/client": "^5.7.0", "@mcp-ui/client": "^5.7.0",
"@radix-ui/react-accordion": "^1.1.2", "@radix-ui/react-accordion": "^1.1.2",
"@radix-ui/react-alert-dialog": "^1.1.15", "@radix-ui/react-alert-dialog": "1.0.2",
"@radix-ui/react-checkbox": "^1.0.3", "@radix-ui/react-checkbox": "^1.0.3",
"@radix-ui/react-collapsible": "^1.0.3", "@radix-ui/react-collapsible": "^1.0.3",
"@radix-ui/react-dialog": "^1.1.15", "@radix-ui/react-dialog": "1.0.2",
"@radix-ui/react-dropdown-menu": "^2.1.1", "@radix-ui/react-dropdown-menu": "^2.1.1",
"@radix-ui/react-hover-card": "^1.0.5", "@radix-ui/react-hover-card": "^1.0.5",
"@radix-ui/react-icons": "^1.3.0", "@radix-ui/react-icons": "^1.3.0",
@ -20638,108 +20638,82 @@
} }
}, },
"node_modules/@radix-ui/react-alert-dialog": { "node_modules/@radix-ui/react-alert-dialog": {
"version": "1.1.15", "version": "1.0.2",
"resolved": "https://registry.npmjs.org/@radix-ui/react-alert-dialog/-/react-alert-dialog-1.1.15.tgz", "resolved": "https://registry.npmjs.org/@radix-ui/react-alert-dialog/-/react-alert-dialog-1.0.2.tgz",
"integrity": "sha512-oTVLkEw5GpdRe29BqJ0LSDFWI3qu0vR1M0mUkOQWDIUnY/QIkLpgDMWuKxP94c2NAC2LGcgVhG1ImF3jkZ5wXw==", "integrity": "sha512-0MtxV53FaEEBOKRgyLnEqHZKKDS5BldQ9oUBsKVXWI5FHbl2jp35qs+0aJET+K5hJDsc40kQUzP7g+wC7tqrqA==",
"license": "MIT", "license": "MIT",
"dependencies": { "dependencies": {
"@radix-ui/primitive": "1.1.3", "@babel/runtime": "^7.13.10",
"@radix-ui/react-compose-refs": "1.1.2", "@radix-ui/primitive": "1.0.0",
"@radix-ui/react-context": "1.1.2", "@radix-ui/react-compose-refs": "1.0.0",
"@radix-ui/react-dialog": "1.1.15", "@radix-ui/react-context": "1.0.0",
"@radix-ui/react-primitive": "2.1.3", "@radix-ui/react-dialog": "1.0.2",
"@radix-ui/react-slot": "1.2.3" "@radix-ui/react-primitive": "1.0.1",
"@radix-ui/react-slot": "1.0.1"
}, },
"peerDependencies": { "peerDependencies": {
"@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0",
"@types/react-dom": "*", "react-dom": "^16.8 || ^17.0 || ^18.0"
"react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc",
"react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc"
},
"peerDependenciesMeta": {
"@types/react": {
"optional": true
},
"@types/react-dom": {
"optional": true
}
} }
}, },
"node_modules/@radix-ui/react-alert-dialog/node_modules/@radix-ui/primitive": { "node_modules/@radix-ui/react-alert-dialog/node_modules/@radix-ui/primitive": {
"version": "1.1.3", "version": "1.0.0",
"resolved": "https://registry.npmjs.org/@radix-ui/primitive/-/primitive-1.1.3.tgz", "resolved": "https://registry.npmjs.org/@radix-ui/primitive/-/primitive-1.0.0.tgz",
"integrity": "sha512-JTF99U/6XIjCBo0wqkU5sK10glYe27MRRsfwoiq5zzOEZLHU3A3KCMa5X/azekYRCJ0HlwI0crAXS/5dEHTzDg==", "integrity": "sha512-3e7rn8FDMin4CgeL7Z/49smCA3rFYY3Ha2rUQ7HRWFadS5iCRw08ZgVT1LaNTCNqgvrUiyczLflrVrF0SRQtNA==",
"license": "MIT" "license": "MIT",
"dependencies": {
"@babel/runtime": "^7.13.10"
}
}, },
"node_modules/@radix-ui/react-alert-dialog/node_modules/@radix-ui/react-compose-refs": { "node_modules/@radix-ui/react-alert-dialog/node_modules/@radix-ui/react-compose-refs": {
"version": "1.1.2", "version": "1.0.0",
"resolved": "https://registry.npmjs.org/@radix-ui/react-compose-refs/-/react-compose-refs-1.1.2.tgz", "resolved": "https://registry.npmjs.org/@radix-ui/react-compose-refs/-/react-compose-refs-1.0.0.tgz",
"integrity": "sha512-z4eqJvfiNnFMHIIvXP3CY57y2WJs5g2v3X0zm9mEJkrkNv4rDxu+sg9Jh8EkXyeqBkB7SOcboo9dMVqhyrACIg==", "integrity": "sha512-0KaSv6sx787/hK3eF53iOkiSLwAGlFMx5lotrqD2pTjB18KbybKoEIgkNZTKC60YECDQTKGTRcDBILwZVqVKvA==",
"license": "MIT", "license": "MIT",
"peerDependencies": { "dependencies": {
"@types/react": "*", "@babel/runtime": "^7.13.10"
"react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc"
}, },
"peerDependenciesMeta": { "peerDependencies": {
"@types/react": { "react": "^16.8 || ^17.0 || ^18.0"
"optional": true
}
} }
}, },
"node_modules/@radix-ui/react-alert-dialog/node_modules/@radix-ui/react-context": { "node_modules/@radix-ui/react-alert-dialog/node_modules/@radix-ui/react-context": {
"version": "1.1.2", "version": "1.0.0",
"resolved": "https://registry.npmjs.org/@radix-ui/react-context/-/react-context-1.1.2.tgz", "resolved": "https://registry.npmjs.org/@radix-ui/react-context/-/react-context-1.0.0.tgz",
"integrity": "sha512-jCi/QKUM2r1Ju5a3J64TH2A5SpKAgh0LpknyqdQ4m6DCV0xJ2HG1xARRwNGPQfi1SLdLWZ1OJz6F4OMBBNiGJA==", "integrity": "sha512-1pVM9RfOQ+n/N5PJK33kRSKsr1glNxomxONs5c49MliinBY6Yw2Q995qfBUUo0/Mbg05B/sGA0gkgPI7kmSHBg==",
"license": "MIT", "license": "MIT",
"peerDependencies": { "dependencies": {
"@types/react": "*", "@babel/runtime": "^7.13.10"
"react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc"
}, },
"peerDependenciesMeta": { "peerDependencies": {
"@types/react": { "react": "^16.8 || ^17.0 || ^18.0"
"optional": true
}
} }
}, },
"node_modules/@radix-ui/react-alert-dialog/node_modules/@radix-ui/react-primitive": { "node_modules/@radix-ui/react-alert-dialog/node_modules/@radix-ui/react-primitive": {
"version": "2.1.3", "version": "1.0.1",
"resolved": "https://registry.npmjs.org/@radix-ui/react-primitive/-/react-primitive-2.1.3.tgz", "resolved": "https://registry.npmjs.org/@radix-ui/react-primitive/-/react-primitive-1.0.1.tgz",
"integrity": "sha512-m9gTwRkhy2lvCPe6QJp4d3G1TYEUHn/FzJUtq9MjH46an1wJU+GdoGC5VLof8RX8Ft/DlpshApkhswDLZzHIcQ==", "integrity": "sha512-fHbmislWVkZaIdeF6GZxF0A/NH/3BjrGIYj+Ae6eTmTCr7EB0RQAAVEiqsXK6p3/JcRqVSBQoceZroj30Jj3XA==",
"license": "MIT", "license": "MIT",
"dependencies": { "dependencies": {
"@radix-ui/react-slot": "1.2.3" "@babel/runtime": "^7.13.10",
"@radix-ui/react-slot": "1.0.1"
}, },
"peerDependencies": { "peerDependencies": {
"@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0",
"@types/react-dom": "*", "react-dom": "^16.8 || ^17.0 || ^18.0"
"react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc",
"react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc"
},
"peerDependenciesMeta": {
"@types/react": {
"optional": true
},
"@types/react-dom": {
"optional": true
}
} }
}, },
"node_modules/@radix-ui/react-alert-dialog/node_modules/@radix-ui/react-slot": { "node_modules/@radix-ui/react-alert-dialog/node_modules/@radix-ui/react-slot": {
"version": "1.2.3", "version": "1.0.1",
"resolved": "https://registry.npmjs.org/@radix-ui/react-slot/-/react-slot-1.2.3.tgz", "resolved": "https://registry.npmjs.org/@radix-ui/react-slot/-/react-slot-1.0.1.tgz",
"integrity": "sha512-aeNmHnBxbi2St0au6VBVC7JXFlhLlOnvIIlePNniyUNAClzmtAUEY8/pBiK3iHjufOlwA+c20/8jngo7xcrg8A==", "integrity": "sha512-avutXAFL1ehGvAXtPquu0YK5oz6ctS474iM3vNGQIkswrVhdrS52e3uoMQBzZhNRAIE0jBnUyXWNmSjGHhCFcw==",
"license": "MIT", "license": "MIT",
"dependencies": { "dependencies": {
"@radix-ui/react-compose-refs": "1.1.2" "@babel/runtime": "^7.13.10",
"@radix-ui/react-compose-refs": "1.0.0"
}, },
"peerDependencies": { "peerDependencies": {
"@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0"
"react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc"
},
"peerDependenciesMeta": {
"@types/react": {
"optional": true
}
} }
}, },
"node_modules/@radix-ui/react-arrow": { "node_modules/@radix-ui/react-arrow": {
@ -21039,341 +21013,228 @@
} }
}, },
"node_modules/@radix-ui/react-dialog": { "node_modules/@radix-ui/react-dialog": {
"version": "1.1.15", "version": "1.0.2",
"resolved": "https://registry.npmjs.org/@radix-ui/react-dialog/-/react-dialog-1.1.15.tgz", "resolved": "https://registry.npmjs.org/@radix-ui/react-dialog/-/react-dialog-1.0.2.tgz",
"integrity": "sha512-TCglVRtzlffRNxRMEyR36DGBLJpeusFcgMVD9PZEzAKnUs1lKCgX5u9BmC2Yg+LL9MgZDugFFs1Vl+Jp4t/PGw==", "integrity": "sha512-EKxxp2WNSmUPkx4trtWNmZ4/vAYEg7JkAfa1HKBUnaubw9eHzf1Orr9B472lJYaYz327RHDrd4R95fsw7VR8DA==",
"license": "MIT", "license": "MIT",
"dependencies": { "dependencies": {
"@radix-ui/primitive": "1.1.3", "@babel/runtime": "^7.13.10",
"@radix-ui/react-compose-refs": "1.1.2", "@radix-ui/primitive": "1.0.0",
"@radix-ui/react-context": "1.1.2", "@radix-ui/react-compose-refs": "1.0.0",
"@radix-ui/react-dismissable-layer": "1.1.11", "@radix-ui/react-context": "1.0.0",
"@radix-ui/react-focus-guards": "1.1.3", "@radix-ui/react-dismissable-layer": "1.0.2",
"@radix-ui/react-focus-scope": "1.1.7", "@radix-ui/react-focus-guards": "1.0.0",
"@radix-ui/react-id": "1.1.1", "@radix-ui/react-focus-scope": "1.0.1",
"@radix-ui/react-portal": "1.1.9", "@radix-ui/react-id": "1.0.0",
"@radix-ui/react-presence": "1.1.5", "@radix-ui/react-portal": "1.0.1",
"@radix-ui/react-primitive": "2.1.3", "@radix-ui/react-presence": "1.0.0",
"@radix-ui/react-slot": "1.2.3", "@radix-ui/react-primitive": "1.0.1",
"@radix-ui/react-use-controllable-state": "1.2.2", "@radix-ui/react-slot": "1.0.1",
"aria-hidden": "^1.2.4", "@radix-ui/react-use-controllable-state": "1.0.0",
"react-remove-scroll": "^2.6.3" "aria-hidden": "^1.1.1",
"react-remove-scroll": "2.5.5"
}, },
"peerDependencies": { "peerDependencies": {
"@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0",
"@types/react-dom": "*", "react-dom": "^16.8 || ^17.0 || ^18.0"
"react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc",
"react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc"
},
"peerDependenciesMeta": {
"@types/react": {
"optional": true
},
"@types/react-dom": {
"optional": true
}
} }
}, },
"node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/primitive": { "node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/primitive": {
"version": "1.1.3", "version": "1.0.0",
"resolved": "https://registry.npmjs.org/@radix-ui/primitive/-/primitive-1.1.3.tgz", "resolved": "https://registry.npmjs.org/@radix-ui/primitive/-/primitive-1.0.0.tgz",
"integrity": "sha512-JTF99U/6XIjCBo0wqkU5sK10glYe27MRRsfwoiq5zzOEZLHU3A3KCMa5X/azekYRCJ0HlwI0crAXS/5dEHTzDg==", "integrity": "sha512-3e7rn8FDMin4CgeL7Z/49smCA3rFYY3Ha2rUQ7HRWFadS5iCRw08ZgVT1LaNTCNqgvrUiyczLflrVrF0SRQtNA==",
"license": "MIT" "license": "MIT",
"dependencies": {
"@babel/runtime": "^7.13.10"
}
}, },
"node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-compose-refs": { "node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-compose-refs": {
"version": "1.1.2", "version": "1.0.0",
"resolved": "https://registry.npmjs.org/@radix-ui/react-compose-refs/-/react-compose-refs-1.1.2.tgz", "resolved": "https://registry.npmjs.org/@radix-ui/react-compose-refs/-/react-compose-refs-1.0.0.tgz",
"integrity": "sha512-z4eqJvfiNnFMHIIvXP3CY57y2WJs5g2v3X0zm9mEJkrkNv4rDxu+sg9Jh8EkXyeqBkB7SOcboo9dMVqhyrACIg==", "integrity": "sha512-0KaSv6sx787/hK3eF53iOkiSLwAGlFMx5lotrqD2pTjB18KbybKoEIgkNZTKC60YECDQTKGTRcDBILwZVqVKvA==",
"license": "MIT", "license": "MIT",
"peerDependencies": { "dependencies": {
"@types/react": "*", "@babel/runtime": "^7.13.10"
"react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc"
}, },
"peerDependenciesMeta": { "peerDependencies": {
"@types/react": { "react": "^16.8 || ^17.0 || ^18.0"
"optional": true
}
} }
}, },
"node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-context": { "node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-context": {
"version": "1.1.2", "version": "1.0.0",
"resolved": "https://registry.npmjs.org/@radix-ui/react-context/-/react-context-1.1.2.tgz", "resolved": "https://registry.npmjs.org/@radix-ui/react-context/-/react-context-1.0.0.tgz",
"integrity": "sha512-jCi/QKUM2r1Ju5a3J64TH2A5SpKAgh0LpknyqdQ4m6DCV0xJ2HG1xARRwNGPQfi1SLdLWZ1OJz6F4OMBBNiGJA==", "integrity": "sha512-1pVM9RfOQ+n/N5PJK33kRSKsr1glNxomxONs5c49MliinBY6Yw2Q995qfBUUo0/Mbg05B/sGA0gkgPI7kmSHBg==",
"license": "MIT", "license": "MIT",
"peerDependencies": { "dependencies": {
"@types/react": "*", "@babel/runtime": "^7.13.10"
"react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc"
}, },
"peerDependenciesMeta": { "peerDependencies": {
"@types/react": { "react": "^16.8 || ^17.0 || ^18.0"
"optional": true
}
} }
}, },
"node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-dismissable-layer": { "node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-dismissable-layer": {
"version": "1.1.11", "version": "1.0.2",
"resolved": "https://registry.npmjs.org/@radix-ui/react-dismissable-layer/-/react-dismissable-layer-1.1.11.tgz", "resolved": "https://registry.npmjs.org/@radix-ui/react-dismissable-layer/-/react-dismissable-layer-1.0.2.tgz",
"integrity": "sha512-Nqcp+t5cTB8BinFkZgXiMJniQH0PsUt2k51FUhbdfeKvc4ACcG2uQniY/8+h1Yv6Kza4Q7lD7PQV0z0oicE0Mg==", "integrity": "sha512-WjJzMrTWROozDqLB0uRWYvj4UuXsM/2L19EmQ3Au+IJWqwvwq9Bwd+P8ivo0Deg9JDPArR1I6MbWNi1CmXsskg==",
"license": "MIT", "license": "MIT",
"dependencies": { "dependencies": {
"@radix-ui/primitive": "1.1.3", "@babel/runtime": "^7.13.10",
"@radix-ui/react-compose-refs": "1.1.2", "@radix-ui/primitive": "1.0.0",
"@radix-ui/react-primitive": "2.1.3", "@radix-ui/react-compose-refs": "1.0.0",
"@radix-ui/react-use-callback-ref": "1.1.1", "@radix-ui/react-primitive": "1.0.1",
"@radix-ui/react-use-escape-keydown": "1.1.1" "@radix-ui/react-use-callback-ref": "1.0.0",
"@radix-ui/react-use-escape-keydown": "1.0.2"
}, },
"peerDependencies": { "peerDependencies": {
"@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0",
"@types/react-dom": "*", "react-dom": "^16.8 || ^17.0 || ^18.0"
"react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc",
"react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc"
},
"peerDependenciesMeta": {
"@types/react": {
"optional": true
},
"@types/react-dom": {
"optional": true
}
} }
}, },
"node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-focus-guards": { "node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-focus-guards": {
"version": "1.1.3", "version": "1.0.0",
"resolved": "https://registry.npmjs.org/@radix-ui/react-focus-guards/-/react-focus-guards-1.1.3.tgz", "resolved": "https://registry.npmjs.org/@radix-ui/react-focus-guards/-/react-focus-guards-1.0.0.tgz",
"integrity": "sha512-0rFg/Rj2Q62NCm62jZw0QX7a3sz6QCQU0LpZdNrJX8byRGaGVTqbrW9jAoIAHyMQqsNpeZ81YgSizOt5WXq0Pw==", "integrity": "sha512-UagjDk4ijOAnGu4WMUPj9ahi7/zJJqNZ9ZAiGPp7waUWJO0O1aWXi/udPphI0IUjvrhBsZJGSN66dR2dsueLWQ==",
"license": "MIT", "license": "MIT",
"peerDependencies": { "dependencies": {
"@types/react": "*", "@babel/runtime": "^7.13.10"
"react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc"
}, },
"peerDependenciesMeta": { "peerDependencies": {
"@types/react": { "react": "^16.8 || ^17.0 || ^18.0"
"optional": true
}
} }
}, },
"node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-focus-scope": { "node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-focus-scope": {
"version": "1.1.7", "version": "1.0.1",
"resolved": "https://registry.npmjs.org/@radix-ui/react-focus-scope/-/react-focus-scope-1.1.7.tgz", "resolved": "https://registry.npmjs.org/@radix-ui/react-focus-scope/-/react-focus-scope-1.0.1.tgz",
"integrity": "sha512-t2ODlkXBQyn7jkl6TNaw/MtVEVvIGelJDCG41Okq/KwUsJBwQ4XVZsHAVUkK4mBv3ewiAS3PGuUWuY2BoK4ZUw==", "integrity": "sha512-Ej2MQTit8IWJiS2uuujGUmxXjF/y5xZptIIQnyd2JHLwtV0R2j9NRVoRj/1j/gJ7e3REdaBw4Hjf4a1ImhkZcQ==",
"license": "MIT", "license": "MIT",
"dependencies": { "dependencies": {
"@radix-ui/react-compose-refs": "1.1.2", "@babel/runtime": "^7.13.10",
"@radix-ui/react-primitive": "2.1.3", "@radix-ui/react-compose-refs": "1.0.0",
"@radix-ui/react-use-callback-ref": "1.1.1" "@radix-ui/react-primitive": "1.0.1",
"@radix-ui/react-use-callback-ref": "1.0.0"
}, },
"peerDependencies": { "peerDependencies": {
"@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0",
"@types/react-dom": "*", "react-dom": "^16.8 || ^17.0 || ^18.0"
"react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc",
"react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc"
},
"peerDependenciesMeta": {
"@types/react": {
"optional": true
},
"@types/react-dom": {
"optional": true
}
} }
}, },
"node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-id": { "node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-id": {
"version": "1.1.1", "version": "1.0.0",
"resolved": "https://registry.npmjs.org/@radix-ui/react-id/-/react-id-1.1.1.tgz", "resolved": "https://registry.npmjs.org/@radix-ui/react-id/-/react-id-1.0.0.tgz",
"integrity": "sha512-kGkGegYIdQsOb4XjsfM97rXsiHaBwco+hFI66oO4s9LU+PLAC5oJ7khdOVFxkhsmlbpUqDAvXw11CluXP+jkHg==", "integrity": "sha512-Q6iAB/U7Tq3NTolBBQbHTgclPmGWE3OlktGGqrClPozSw4vkQ1DfQAOtzgRPecKsMdJINE05iaoDUG8tRzCBjw==",
"license": "MIT", "license": "MIT",
"dependencies": { "dependencies": {
"@radix-ui/react-use-layout-effect": "1.1.1" "@babel/runtime": "^7.13.10",
"@radix-ui/react-use-layout-effect": "1.0.0"
}, },
"peerDependencies": { "peerDependencies": {
"@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0"
"react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc"
},
"peerDependenciesMeta": {
"@types/react": {
"optional": true
}
} }
}, },
"node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-portal": { "node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-portal": {
"version": "1.1.9", "version": "1.0.1",
"resolved": "https://registry.npmjs.org/@radix-ui/react-portal/-/react-portal-1.1.9.tgz", "resolved": "https://registry.npmjs.org/@radix-ui/react-portal/-/react-portal-1.0.1.tgz",
"integrity": "sha512-bpIxvq03if6UNwXZ+HTK71JLh4APvnXntDc6XOX8UVq4XQOVl7lwok0AvIl+b8zgCw3fSaVTZMpAPPagXbKmHQ==", "integrity": "sha512-NY2vUWI5WENgAT1nfC6JS7RU5xRYBfjZVLq0HmgEN1Ezy3rk/UruMV4+Rd0F40PEaFC5SrLS1ixYvcYIQrb4Ig==",
"license": "MIT", "license": "MIT",
"dependencies": { "dependencies": {
"@radix-ui/react-primitive": "2.1.3", "@babel/runtime": "^7.13.10",
"@radix-ui/react-use-layout-effect": "1.1.1" "@radix-ui/react-primitive": "1.0.1"
}, },
"peerDependencies": { "peerDependencies": {
"@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0",
"@types/react-dom": "*", "react-dom": "^16.8 || ^17.0 || ^18.0"
"react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc",
"react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc"
},
"peerDependenciesMeta": {
"@types/react": {
"optional": true
},
"@types/react-dom": {
"optional": true
}
} }
}, },
"node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-presence": { "node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-presence": {
"version": "1.1.5", "version": "1.0.0",
"resolved": "https://registry.npmjs.org/@radix-ui/react-presence/-/react-presence-1.1.5.tgz", "resolved": "https://registry.npmjs.org/@radix-ui/react-presence/-/react-presence-1.0.0.tgz",
"integrity": "sha512-/jfEwNDdQVBCNvjkGit4h6pMOzq8bHkopq458dPt2lMjx+eBQUohZNG9A7DtO/O5ukSbxuaNGXMjHicgwy6rQQ==", "integrity": "sha512-A+6XEvN01NfVWiKu38ybawfHsBjWum42MRPnEuqPsBZ4eV7e/7K321B5VgYMPv3Xx5An6o1/l9ZuDBgmcmWK3w==",
"license": "MIT", "license": "MIT",
"dependencies": { "dependencies": {
"@radix-ui/react-compose-refs": "1.1.2", "@babel/runtime": "^7.13.10",
"@radix-ui/react-use-layout-effect": "1.1.1" "@radix-ui/react-compose-refs": "1.0.0",
"@radix-ui/react-use-layout-effect": "1.0.0"
}, },
"peerDependencies": { "peerDependencies": {
"@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0",
"@types/react-dom": "*", "react-dom": "^16.8 || ^17.0 || ^18.0"
"react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc",
"react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc"
},
"peerDependenciesMeta": {
"@types/react": {
"optional": true
},
"@types/react-dom": {
"optional": true
}
} }
}, },
"node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-primitive": { "node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-primitive": {
"version": "2.1.3", "version": "1.0.1",
"resolved": "https://registry.npmjs.org/@radix-ui/react-primitive/-/react-primitive-2.1.3.tgz", "resolved": "https://registry.npmjs.org/@radix-ui/react-primitive/-/react-primitive-1.0.1.tgz",
"integrity": "sha512-m9gTwRkhy2lvCPe6QJp4d3G1TYEUHn/FzJUtq9MjH46an1wJU+GdoGC5VLof8RX8Ft/DlpshApkhswDLZzHIcQ==", "integrity": "sha512-fHbmislWVkZaIdeF6GZxF0A/NH/3BjrGIYj+Ae6eTmTCr7EB0RQAAVEiqsXK6p3/JcRqVSBQoceZroj30Jj3XA==",
"license": "MIT", "license": "MIT",
"dependencies": { "dependencies": {
"@radix-ui/react-slot": "1.2.3" "@babel/runtime": "^7.13.10",
"@radix-ui/react-slot": "1.0.1"
}, },
"peerDependencies": { "peerDependencies": {
"@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0",
"@types/react-dom": "*", "react-dom": "^16.8 || ^17.0 || ^18.0"
"react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc",
"react-dom": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc"
},
"peerDependenciesMeta": {
"@types/react": {
"optional": true
},
"@types/react-dom": {
"optional": true
}
} }
}, },
"node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-slot": { "node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-slot": {
"version": "1.2.3", "version": "1.0.1",
"resolved": "https://registry.npmjs.org/@radix-ui/react-slot/-/react-slot-1.2.3.tgz", "resolved": "https://registry.npmjs.org/@radix-ui/react-slot/-/react-slot-1.0.1.tgz",
"integrity": "sha512-aeNmHnBxbi2St0au6VBVC7JXFlhLlOnvIIlePNniyUNAClzmtAUEY8/pBiK3iHjufOlwA+c20/8jngo7xcrg8A==", "integrity": "sha512-avutXAFL1ehGvAXtPquu0YK5oz6ctS474iM3vNGQIkswrVhdrS52e3uoMQBzZhNRAIE0jBnUyXWNmSjGHhCFcw==",
"license": "MIT", "license": "MIT",
"dependencies": { "dependencies": {
"@radix-ui/react-compose-refs": "1.1.2" "@babel/runtime": "^7.13.10",
"@radix-ui/react-compose-refs": "1.0.0"
}, },
"peerDependencies": { "peerDependencies": {
"@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0"
"react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc"
},
"peerDependenciesMeta": {
"@types/react": {
"optional": true
}
} }
}, },
"node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-use-callback-ref": { "node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-use-callback-ref": {
"version": "1.1.1", "version": "1.0.0",
"resolved": "https://registry.npmjs.org/@radix-ui/react-use-callback-ref/-/react-use-callback-ref-1.1.1.tgz", "resolved": "https://registry.npmjs.org/@radix-ui/react-use-callback-ref/-/react-use-callback-ref-1.0.0.tgz",
"integrity": "sha512-FkBMwD+qbGQeMu1cOHnuGB6x4yzPjho8ap5WtbEJ26umhgqVXbhekKUQO+hZEL1vU92a3wHwdp0HAcqAUF5iDg==", "integrity": "sha512-GZtyzoHz95Rhs6S63D2t/eqvdFCm7I+yHMLVQheKM7nBD8mbZIt+ct1jz4536MDnaOGKIxynJ8eHTkVGVVkoTg==",
"license": "MIT", "license": "MIT",
"peerDependencies": { "dependencies": {
"@types/react": "*", "@babel/runtime": "^7.13.10"
"react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc"
}, },
"peerDependenciesMeta": { "peerDependencies": {
"@types/react": { "react": "^16.8 || ^17.0 || ^18.0"
"optional": true
}
} }
}, },
"node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-use-controllable-state": { "node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-use-controllable-state": {
"version": "1.2.2", "version": "1.0.0",
"resolved": "https://registry.npmjs.org/@radix-ui/react-use-controllable-state/-/react-use-controllable-state-1.2.2.tgz", "resolved": "https://registry.npmjs.org/@radix-ui/react-use-controllable-state/-/react-use-controllable-state-1.0.0.tgz",
"integrity": "sha512-BjasUjixPFdS+NKkypcyyN5Pmg83Olst0+c6vGov0diwTEo6mgdqVR6hxcEgFuh4QrAs7Rc+9KuGJ9TVCj0Zzg==", "integrity": "sha512-FohDoZvk3mEXh9AWAVyRTYR4Sq7/gavuofglmiXB2g1aKyboUD4YtgWxKj8O5n+Uak52gXQ4wKz5IFST4vtJHg==",
"license": "MIT", "license": "MIT",
"dependencies": { "dependencies": {
"@radix-ui/react-use-effect-event": "0.0.2", "@babel/runtime": "^7.13.10",
"@radix-ui/react-use-layout-effect": "1.1.1" "@radix-ui/react-use-callback-ref": "1.0.0"
}, },
"peerDependencies": { "peerDependencies": {
"@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0"
"react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc"
},
"peerDependenciesMeta": {
"@types/react": {
"optional": true
}
} }
}, },
"node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-use-escape-keydown": { "node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-use-escape-keydown": {
"version": "1.1.1", "version": "1.0.2",
"resolved": "https://registry.npmjs.org/@radix-ui/react-use-escape-keydown/-/react-use-escape-keydown-1.1.1.tgz", "resolved": "https://registry.npmjs.org/@radix-ui/react-use-escape-keydown/-/react-use-escape-keydown-1.0.2.tgz",
"integrity": "sha512-Il0+boE7w/XebUHyBjroE+DbByORGR9KKmITzbR7MyQ4akpORYP/ZmbhAr0DG7RmmBqoOnZdy2QlvajJ2QA59g==", "integrity": "sha512-DXGim3x74WgUv+iMNCF+cAo8xUHHeqvjx8zs7trKf+FkQKPQXLk2sX7Gx1ysH7Q76xCpZuxIJE7HLPxRE+Q+GA==",
"license": "MIT", "license": "MIT",
"dependencies": { "dependencies": {
"@radix-ui/react-use-callback-ref": "1.1.1" "@babel/runtime": "^7.13.10",
"@radix-ui/react-use-callback-ref": "1.0.0"
}, },
"peerDependencies": { "peerDependencies": {
"@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0"
"react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc"
},
"peerDependenciesMeta": {
"@types/react": {
"optional": true
}
} }
}, },
"node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-use-layout-effect": { "node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-use-layout-effect": {
"version": "1.1.1", "version": "1.0.0",
"resolved": "https://registry.npmjs.org/@radix-ui/react-use-layout-effect/-/react-use-layout-effect-1.1.1.tgz", "resolved": "https://registry.npmjs.org/@radix-ui/react-use-layout-effect/-/react-use-layout-effect-1.0.0.tgz",
"integrity": "sha512-RbJRS4UWQFkzHTTwVymMTUv8EqYhOp8dOOviLj2ugtTiXRaRQS7GLGxZTLL1jWhMeoSCf5zmcZkqTl9IiYfXcQ==", "integrity": "sha512-6Tpkq+R6LOlmQb1R5NNETLG0B4YP0wc+klfXafpUCj6JGyaUc8il7/kUZ7m59rGbXGczE9Bs+iz2qloqsZBduQ==",
"license": "MIT",
"peerDependencies": {
"@types/react": "*",
"react": "^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc"
},
"peerDependenciesMeta": {
"@types/react": {
"optional": true
}
}
},
"node_modules/@radix-ui/react-dialog/node_modules/react-remove-scroll": {
"version": "2.7.2",
"resolved": "https://registry.npmjs.org/react-remove-scroll/-/react-remove-scroll-2.7.2.tgz",
"integrity": "sha512-Iqb9NjCCTt6Hf+vOdNIZGdTiH1QSqr27H/Ek9sv/a97gfueI/5h1s3yRi1nngzMUaOOToin5dI1dXKdXiF+u0Q==",
"license": "MIT", "license": "MIT",
"dependencies": { "dependencies": {
"react-remove-scroll-bar": "^2.3.7", "@babel/runtime": "^7.13.10"
"react-style-singleton": "^2.2.3",
"tslib": "^2.1.0",
"use-callback-ref": "^1.3.3",
"use-sidecar": "^1.1.3"
},
"engines": {
"node": ">=10"
}, },
"peerDependencies": { "peerDependencies": {
"@types/react": "*", "react": "^16.8 || ^17.0 || ^18.0"
"react": "^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc"
},
"peerDependenciesMeta": {
"@types/react": {
"optional": true
}
} }
}, },
"node_modules/@radix-ui/react-direction": { "node_modules/@radix-ui/react-direction": {
@ -49212,10 +49073,10 @@
"@dicebear/core": "^9.2.2", "@dicebear/core": "^9.2.2",
"@headlessui/react": "^2.1.2", "@headlessui/react": "^2.1.2",
"@radix-ui/react-accordion": "^1.2.11", "@radix-ui/react-accordion": "^1.2.11",
"@radix-ui/react-alert-dialog": "^1.1.15", "@radix-ui/react-alert-dialog": "1.0.2",
"@radix-ui/react-checkbox": "^1.0.3", "@radix-ui/react-checkbox": "^1.0.3",
"@radix-ui/react-collapsible": "^1.1.11", "@radix-ui/react-collapsible": "^1.1.11",
"@radix-ui/react-dialog": "^1.1.15", "@radix-ui/react-dialog": "1.0.2",
"@radix-ui/react-dropdown-menu": "^2.1.1", "@radix-ui/react-dropdown-menu": "^2.1.1",
"@radix-ui/react-hover-card": "^1.0.5", "@radix-ui/react-hover-card": "^1.0.5",
"@radix-ui/react-icons": "^1.3.0", "@radix-ui/react-icons": "^1.3.0",

View file

@ -35,10 +35,10 @@
"@dicebear/core": "^9.2.2", "@dicebear/core": "^9.2.2",
"@headlessui/react": "^2.1.2", "@headlessui/react": "^2.1.2",
"@radix-ui/react-accordion": "^1.2.11", "@radix-ui/react-accordion": "^1.2.11",
"@radix-ui/react-alert-dialog": "^1.1.15", "@radix-ui/react-alert-dialog": "1.0.2",
"@radix-ui/react-checkbox": "^1.0.3", "@radix-ui/react-checkbox": "^1.0.3",
"@radix-ui/react-collapsible": "^1.1.11", "@radix-ui/react-collapsible": "^1.1.11",
"@radix-ui/react-dialog": "^1.1.15", "@radix-ui/react-dialog": "1.0.2",
"@radix-ui/react-dropdown-menu": "^2.1.1", "@radix-ui/react-dropdown-menu": "^2.1.1",
"@radix-ui/react-hover-card": "^1.0.5", "@radix-ui/react-hover-card": "^1.0.5",
"@radix-ui/react-icons": "^1.3.0", "@radix-ui/react-icons": "^1.3.0",

View file

@ -9,7 +9,7 @@ interface OGDialogProps extends DialogPrimitive.DialogProps {
} }
const Dialog = React.forwardRef<HTMLDivElement, OGDialogProps>( const Dialog = React.forwardRef<HTMLDivElement, OGDialogProps>(
({ children, triggerRef, triggerRefs, onOpenChange, ...props }) => { ({ children, triggerRef, triggerRefs, onOpenChange, ...props }, ref) => {
const handleOpenChange = (open: boolean) => { const handleOpenChange = (open: boolean) => {
if (!open && triggerRef?.current) { if (!open && triggerRef?.current) {
setTimeout(() => { setTimeout(() => {
@ -78,26 +78,22 @@ const DialogContent = React.forwardRef<
}, },
ref, ref,
) => { ) => {
const contentRef = React.useRef<HTMLDivElement>(null);
React.useImperativeHandle(ref, () => contentRef.current as HTMLDivElement, []);
/* Handle Escape key to prevent closing dialog if a tooltip or dropdown is open /* Handle Escape key to prevent closing dialog if a tooltip or dropdown is open
(this is a workaround in order to achieve WCAG compliance which requires (this is a workaround in order to achieve WCAG compliance which requires
that our tooltips be dismissable with Escape key) */ that our tooltips be dismissable with Escape key) */
const handleEscapeKeyDown = React.useCallback( const handleEscapeKeyDown = React.useCallback(
(event: KeyboardEvent) => { (event: KeyboardEvent) => {
if (!contentRef.current) { const tooltips = document.querySelectorAll('.tooltip');
propsOnEscapeKeyDown?.(event); const dropdownMenus = document.querySelectorAll('[role="menu"]');
return;
}
const tooltips = contentRef.current.querySelectorAll('.tooltip');
const dropdownMenus = contentRef.current.querySelectorAll('[role="menu"]');
for (const tooltip of tooltips) { for (const tooltip of tooltips) {
const style = window.getComputedStyle(tooltip); const style = window.getComputedStyle(tooltip);
if (style.display !== 'none') { if (
style.display !== 'none' &&
style.visibility !== 'hidden' &&
parseFloat(style.opacity) > 0
) {
event.preventDefault(); event.preventDefault();
return; return;
} }
@ -105,7 +101,11 @@ const DialogContent = React.forwardRef<
for (const dropdownMenu of dropdownMenus) { for (const dropdownMenu of dropdownMenus) {
const style = window.getComputedStyle(dropdownMenu); const style = window.getComputedStyle(dropdownMenu);
if (style.display !== 'none') { if (
style.display !== 'none' &&
style.visibility !== 'hidden' &&
parseFloat(style.opacity) > 0
) {
event.preventDefault(); event.preventDefault();
return; return;
} }
@ -120,7 +120,7 @@ const DialogContent = React.forwardRef<
<DialogPortal> <DialogPortal>
<DialogOverlay className={overlayClassName} /> <DialogOverlay className={overlayClassName} />
<DialogPrimitive.Content <DialogPrimitive.Content
ref={contentRef} ref={ref}
onEscapeKeyDown={handleEscapeKeyDown} onEscapeKeyDown={handleEscapeKeyDown}
className={cn( className={cn(
'max-w-11/12 fixed left-[50%] top-[50%] z-[100] grid max-h-[90vh] w-full translate-x-[-50%] translate-y-[-50%] gap-4 overflow-y-auto rounded-2xl bg-background p-6 text-text-primary shadow-lg duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%]', 'max-w-11/12 fixed left-[50%] top-[50%] z-[100] grid max-h-[90vh] w-full translate-x-[-50%] translate-y-[-50%] gap-4 overflow-y-auto rounded-2xl bg-background p-6 text-text-primary shadow-lg duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%]',

View file

@ -1,5 +1,5 @@
.tooltip { .tooltip {
z-index: 50; z-index: 150;
cursor: pointer; cursor: pointer;
pointer-events: auto; pointer-events: auto;
border-radius: 0.275rem; border-radius: 0.275rem;