From e8e606e742be1f18c5f64dd3f4999dc13d1a729a Mon Sep 17 00:00:00 2001 From: Alex Perez Date: Tue, 10 Mar 2026 15:15:15 -0300 Subject: [PATCH 1/4] fix(api-type-document): use transparent background fallback for union buttons in dark mode Made-with: Cursor --- demo/index.html | 53 ++++++++++++++++++++++++++++++++++ package-lock.json | 4 +-- package.json | 2 +- src/TypeStyles.js | 8 ++--- test/api-type-document.test.js | 11 +++++++ 5 files changed, 71 insertions(+), 7 deletions(-) diff --git a/demo/index.html b/demo/index.html index a4b281e..176a392 100644 --- a/demo/index.html +++ b/demo/index.html @@ -61,15 +61,68 @@ .options > * { margin-left: 8px; } + + /* Dark mode: simulates theme where union/oneOf buttons use transparent/inherit */ + body.dark-mode { + background-color: #1e1e1e !important; + color: #e0e0e0; + } + body.dark-mode header { + background-color: #2d2d2d; + --iron-icon-fill-color: #e0e0e0; + --paper-input-container-focus-color: #90caf9; + --paper-input-container-label: { color: #e0e0e0; }; + } + body.dark-mode [role="main"] { + background-color: #1e1e1e; + } + .dark-mode-toggle { + position: fixed; + bottom: 12px; + right: 12px; + z-index: 9999; + padding: 6px 10px; + background: #333; + color: #fff; + border-radius: 4px; + font-size: 12px; + cursor: pointer; + box-shadow: 0 2px 8px rgba(0,0,0,0.3); + } + .dark-mode-toggle input { margin-right: 6px; }
+