mirror of
https://github.com/notion-enhancer/notion-enhancer.git
synced 2025-04-08 06:29:03 +00:00
style(menu): set landing tile bg to bg-secondary for consistency with mod tiles
This commit is contained in:
parent
5640b12139
commit
0daf0a38c2
@ -547,7 +547,7 @@ const h = (type, props, ...children) => {
|
|||||||
for (const prop in props ?? {}) {
|
for (const prop in props ?? {}) {
|
||||||
if (typeof props[prop] === "undefined") continue;
|
if (typeof props[prop] === "undefined") continue;
|
||||||
if (htmlAttributes.includes(prop) || prop.startsWith("data-")) {
|
if (htmlAttributes.includes(prop) || prop.startsWith("data-")) {
|
||||||
if (typeof props[prop] === "boolean" && !prop.startsWith("data-")) {
|
if (typeof props[prop] === "boolean") {
|
||||||
if (!props[prop]) continue;
|
if (!props[prop]) continue;
|
||||||
elem.setAttribute(prop, "");
|
elem.setAttribute(prop, "");
|
||||||
} else elem.setAttribute(prop, props[prop]);
|
} else elem.setAttribute(prop, props[prop]);
|
||||||
|
@ -9,10 +9,9 @@ import { extendProps } from "../state.mjs";
|
|||||||
function Tile({ icon, title, tagName, ...props }, ...children) {
|
function Tile({ icon, title, tagName, ...props }, ...children) {
|
||||||
const { html } = globalThis.__enhancerApi;
|
const { html } = globalThis.__enhancerApi;
|
||||||
extendProps(props, {
|
extendProps(props, {
|
||||||
class: `px-[16px] py-[12px]
|
class: `flex items-center gap-[12px] px-[16px] py-[12px]
|
||||||
flex items-center gap-[12px] rounded-[4px]
|
bg-[color:var(--theme--bg-secondary)] hover:bg-[color:var(--theme--bg-hover)]
|
||||||
border-(& [color:var(--theme--fg-border)])
|
rounded-[4px] border-(& [color:var(--theme--fg-border)])`,
|
||||||
hover:bg-[color:var(--theme--bg-hover)]`,
|
|
||||||
});
|
});
|
||||||
tagName ??= props["href"] ? "a" : "button";
|
tagName ??= props["href"] ? "a" : "button";
|
||||||
return html`<${tagName} ...${props}>
|
return html`<${tagName} ...${props}>
|
||||||
|
Loading…
Reference in New Issue
Block a user