Skip to content

Commit 1d9e527

Browse files
committed
Quartz sync: May 19, 2025, 12:13 AM
1 parent 90deb63 commit 1d9e527

File tree

5 files changed

+318
-252
lines changed

5 files changed

+318
-252
lines changed

quartz/components/PageTitle.tsx

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,9 @@ PageTitle.css = `
2424
display: flex;
2525
align-items: center;
2626
}
27+
.page-title a {
28+
margin-left: 0.5rem;
29+
}
2730
.logo {
2831
width: 2rem;
2932
height: 2rem;

quartz/components/PageTitleWithLogo.tsx

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,22 @@ PageTitle.css = `
2323
font-family: var(--titleFont);
2424
display: flex;
2525
}
26+
2627
.page-logo {
2728
justify-content: center;
2829
align-items: center;
30+
width: 2rem;
31+
height: 2rem;
32+
padding-left: 0.25rem;
2933
margin: 0;
34+
vertical-align: text-top;
35+
36+
@media (min-width: 1400px){
37+
display: block;
38+
width: auto;
39+
height: auto;
40+
padding: 0;
41+
}
3042
}
3143
`
3244

quartz/components/Search.tsx

Lines changed: 36 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -6,48 +6,48 @@ import { classNames } from "../util/lang"
66
import { i18n } from "../i18n"
77

88
export interface SearchOptions {
9-
enablePreview: boolean
9+
enablePreview: boolean
1010
}
1111

1212
const defaultOptions: SearchOptions = {
13-
enablePreview: true,
13+
enablePreview: true,
1414
}
1515

1616
export default ((userOpts?: Partial<SearchOptions>) => {
17-
const Search: QuartzComponent = ({ displayClass, cfg }: QuartzComponentProps) => {
18-
const opts = { ...defaultOptions, ...userOpts }
19-
const searchPlaceholder = i18n(cfg.locale).components.search.searchBarPlaceholder
20-
return (
21-
<div class={classNames(displayClass, "search")}>
22-
<button class="search-button">
23-
<p>{i18n(cfg.locale).components.search.title}</p>
24-
<svg role="img" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 19.9 19.7">
25-
<title>Search</title>
26-
<g class="search-path" fill="none">
27-
<path stroke-linecap="square" d="M18.5 18.3l-5.4-5.4" />
28-
<circle cx="8" cy="8" r="7" />
29-
</g>
30-
</svg>
31-
</button>
32-
<div class="search-container">
33-
<div class="search-space">
34-
<input
35-
autocomplete="off"
36-
class="search-bar"
37-
name="search"
38-
type="text"
39-
aria-label={searchPlaceholder}
40-
placeholder={searchPlaceholder}
41-
/>
42-
<div class="search-layout" data-preview={opts.enablePreview}></div>
43-
</div>
44-
</div>
45-
</div>
46-
)
47-
}
17+
const Search: QuartzComponent = ({ displayClass, cfg }: QuartzComponentProps) => {
18+
const opts = { ...defaultOptions, ...userOpts }
19+
const searchPlaceholder = i18n(cfg.locale).components.search.searchBarPlaceholder
20+
return (
21+
<div class={classNames(displayClass, "search")}>
22+
<button class="search-button">
23+
<p class="search-label">{i18n(cfg.locale).components.search.title}</p>
24+
<svg role="img" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 19.9 19.7">
25+
<title>Search</title>
26+
<g class="search-path" fill="none">
27+
<path stroke-linecap="square" d="M18.5 18.3l-5.4-5.4" />
28+
<circle cx="8" cy="8" r="7" />
29+
</g>
30+
</svg>
31+
</button>
32+
<div class="search-container">
33+
<div class="search-space">
34+
<input
35+
autocomplete="off"
36+
class="search-bar"
37+
name="search"
38+
type="text"
39+
aria-label={searchPlaceholder}
40+
placeholder={searchPlaceholder}
41+
/>
42+
<div class="search-layout" data-preview={opts.enablePreview}></div>
43+
</div>
44+
</div>
45+
</div>
46+
)
47+
}
4848

49-
Search.afterDOMLoaded = script
50-
Search.css = style
49+
Search.afterDOMLoaded = script
50+
Search.css = style
5151

52-
return Search
52+
return Search
5353
}) satisfies QuartzComponentConstructor

0 commit comments

Comments
 (0)