mirror of
https://github.com/khoaliber/khoj.git
synced 2026-03-05 13:21:18 +00:00
Make the Khoj Obsidian plugin more user theme friendly
Use the CSS variables from the theme for the Khoj UI components
This commit is contained in:
committed by
Debanjum Singh Solanky
parent
d6fe5d9a63
commit
c4a1ae9375
@@ -226,7 +226,7 @@ export async function populateHeaderPane(headerEl: Element, setting: KhojSetting
|
||||
// Add Khoj title to header element
|
||||
const titleEl = headerEl.createDiv();
|
||||
titleEl.className = 'khoj-logo';
|
||||
titleEl.textContent = "KHOJ"
|
||||
titleEl.textContent = "Khoj"
|
||||
|
||||
// Populate the header element with the navigation pane
|
||||
// Create the nav element
|
||||
|
||||
@@ -74,16 +74,17 @@ If your plugin does not need CSS, delete this file.
|
||||
padding: 10px;
|
||||
position: relative;
|
||||
display: inline-block;
|
||||
max-width: 80%;
|
||||
text-align: left;
|
||||
user-select: text;
|
||||
color: var(--text-normal);
|
||||
}
|
||||
/* color chat bubble by khoj blue */
|
||||
.khoj-chat-message-text.khoj {
|
||||
color: var(--khoj-storm-grey);
|
||||
background: var(--khoj-winter-sun);
|
||||
color: var(--text-normal);
|
||||
margin-left: auto;
|
||||
white-space: pre-line;
|
||||
background-color: var(--code-background);
|
||||
/* background-color: var(--background-modifier-active-hover); */
|
||||
}
|
||||
/* add left protrusion to khoj chat bubble */
|
||||
.khoj-chat-message-text.khoj:after {
|
||||
@@ -92,14 +93,12 @@ If your plugin does not need CSS, delete this file.
|
||||
bottom: -2px;
|
||||
left: -7px;
|
||||
border: 10px solid transparent;
|
||||
border-top-color: var(--khoj-winter-sun);
|
||||
border-bottom: 0;
|
||||
transform: rotate(-60deg);
|
||||
}
|
||||
/* color chat bubble by you dark grey */
|
||||
.khoj-chat-message-text.you {
|
||||
color: var(--text-on-accent);
|
||||
background: var(--khoj-storm-grey);
|
||||
color: var(--text-normal);
|
||||
margin-right: auto;
|
||||
}
|
||||
/* add right protrusion to you chat bubble */
|
||||
@@ -109,7 +108,6 @@ If your plugin does not need CSS, delete this file.
|
||||
top: 91%;
|
||||
right: -2px;
|
||||
border: 10px solid transparent;
|
||||
border-left-color: var(--khoj-storm-grey);
|
||||
border-right: 0;
|
||||
margin-top: -10px;
|
||||
transform: rotate(-60deg)
|
||||
@@ -488,7 +486,7 @@ div.khoj-logo {
|
||||
}
|
||||
|
||||
.khoj-nav a {
|
||||
color: var(--main-text-color);
|
||||
color: var(--text-normal);
|
||||
text-decoration: none;
|
||||
font-size: small;
|
||||
font-weight: normal;
|
||||
@@ -498,11 +496,11 @@ div.khoj-logo {
|
||||
margin: 0;
|
||||
}
|
||||
.khoj-nav a:hover {
|
||||
background-color: var(--khoj-sun);
|
||||
background-color: var(--background-modifier-active-hover);
|
||||
color: var(--main-text-color);
|
||||
}
|
||||
a.khoj-nav-selected {
|
||||
background-color: var(--khoj-winter-sun);
|
||||
background-color: var(--background-modifier-active-hover);
|
||||
}
|
||||
#similar-nav-icon-svg,
|
||||
.khoj-nav-icon {
|
||||
@@ -542,12 +540,7 @@ img.copy-icon {
|
||||
width: 16px;
|
||||
height: 16px;
|
||||
}
|
||||
.you button.copy-button {
|
||||
color: var(--text-on-accent);
|
||||
}
|
||||
.khoj button.copy-button {
|
||||
color: var(--khoj-storm-grey);
|
||||
}
|
||||
|
||||
.you button.copy-button:hover {
|
||||
color: var(--khoj-storm-grey);
|
||||
background: var(--text-on-accent);
|
||||
|
||||
@@ -215,6 +215,21 @@ esbuild-darwin-64@0.14.47:
|
||||
resolved "https://registry.yarnpkg.com/esbuild-darwin-64/-/esbuild-darwin-64-0.14.47.tgz#e0da6c244f497192f951807f003f6a423ed23188"
|
||||
integrity sha512-R6oaW0y5/u6Eccti/TS6c/2c1xYTb1izwK3gajJwi4vIfNs1s8B1dQzI1UiC9T61YovOQVuePDcfqHLT3mUZJA==
|
||||
|
||||
esbuild-android-64@0.14.47:
|
||||
version "0.14.47"
|
||||
resolved "https://registry.yarnpkg.com/esbuild-android-64/-/esbuild-android-64-0.14.47.tgz#ef95b42c67bcf4268c869153fa3ad1466c4cea6b"
|
||||
integrity sha512-R13Bd9+tqLVFndncMHssZrPWe6/0Kpv2/dt4aA69soX4PRxlzsVpCvoJeFE8sOEoeVEiBkI0myjlkDodXlHa0g==
|
||||
|
||||
esbuild-android-arm64@0.14.47:
|
||||
version "0.14.47"
|
||||
resolved "https://registry.yarnpkg.com/esbuild-android-arm64/-/esbuild-android-arm64-0.14.47.tgz#4ebd7ce9fb250b4695faa3ee46fd3b0754ecd9e6"
|
||||
integrity sha512-OkwOjj7ts4lBp/TL6hdd8HftIzOy/pdtbrNA4+0oVWgGG64HrdVzAF5gxtJufAPOsEjkyh1oIYvKAUinKKQRSQ==
|
||||
|
||||
esbuild-darwin-64@0.14.47:
|
||||
version "0.14.47"
|
||||
resolved "https://registry.yarnpkg.com/esbuild-darwin-64/-/esbuild-darwin-64-0.14.47.tgz#e0da6c244f497192f951807f003f6a423ed23188"
|
||||
integrity sha512-R6oaW0y5/u6Eccti/TS6c/2c1xYTb1izwK3gajJwi4vIfNs1s8B1dQzI1UiC9T61YovOQVuePDcfqHLT3mUZJA==
|
||||
|
||||
esbuild-darwin-arm64@0.14.47:
|
||||
version "0.14.47"
|
||||
resolved "https://registry.yarnpkg.com/esbuild-darwin-arm64/-/esbuild-darwin-arm64-0.14.47.tgz#cd40fd49a672fca581ed202834239dfe540a9028"
|
||||
|
||||
Reference in New Issue
Block a user