client/shared note info bar: improve appearance

This commit is contained in:
Adorian Doran 2025-11-09 02:14:43 +02:00
parent c4603fce25
commit 50869d29db
4 changed files with 6 additions and 13 deletions

View File

@ -1328,14 +1328,6 @@ body.mobile .note-title {
border-bottom: 2px solid #0000001c !important; border-bottom: 2px solid #0000001c !important;
} }
/*
* Read-only note info bar
*/
.read-only-note-info-bar-widget {
--link-color: var(--main-text-color);
}
/* /*
* Promoted attributes * Promoted attributes
*/ */

View File

@ -1,10 +1,11 @@
.info-bar { .info-bar {
--link-color: var(--main-text-color);
margin-top: 4px; margin-top: 4px;
contain: unset !important; contain: unset !important;
padding: 8px 20px; padding: 8px 20px;
color: var(--read-only-note-info-bar-color); color: var(--read-only-note-info-bar-color);
font-size: .9em; font-size: .9em;
} }
.info-bar-prominent { .info-bar-prominent {

View File

@ -1,15 +1,15 @@
import { ComponentChildren } from "preact";
import "./InfoBar.css"; import "./InfoBar.css";
import { ComponentChildren, CSSProperties } from "preact";
export type InfoBarParams = { export type InfoBarParams = {
type: "prominent" | "subtle", type: "prominent" | "subtle",
className: string; className: string;
style: CSSProperties
children: ComponentChildren; children: ComponentChildren;
}; };
export default function InfoBar(props: InfoBarParams) { export default function InfoBar(props: InfoBarParams) {
return <div className={`info-bar ${props.className} info-bar-${props.type}`}> return <div className={`info-bar ${props.className} info-bar-${props.type}`} style={props.style}>
{props?.children} {props?.children}
</div> </div>
} }

View File

@ -49,7 +49,7 @@ export default function SharedInfo() {
}); });
return ( return (
<InfoBar className="shared-info-widget" type="subtle"> <InfoBar className="shared-info-widget" type="subtle" style={{display: (!link) ? "none" : undefined}}>
{link && ( {link && (
<RawHtml html={syncServerHost <RawHtml html={syncServerHost
? t("shared_info.shared_publicly", { link }) ? t("shared_info.shared_publicly", { link })