Skip to content

Commit 5d31b54

Browse files
author
DavidQ
committed
Adding common TBA header/image to pages
1 parent 32540ae commit 5d31b54

8 files changed

Lines changed: 21 additions & 13 deletions

docs/pr/BUILD_PR_LEVEL_24_6_TOOLBOXAID_SHARED_THEME_HEADER.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
Provide the shared Toolbox Aid header as real importable source under `src/engine/theme`.
55

66
## Required Shared Source
7-
- `src/engine/theme/toolboxaid-header.template.html`
7+
- `src/engine/theme/toolboxaid-header.html`
88
- `src/engine/theme/toolboxaid-header.css`
99
- `src/engine/theme/toolboxaid-header.js`
1010
- `src/engine/theme/index.js`

samples/index.html

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -167,14 +167,16 @@
167167
<div class="wrap">
168168
<div class="hideme">
169169
<div id="shared-theme-header"></div>
170-
<section class="samples-favorites" aria-label="Pinned samples">
171-
<h2>Pinned Samples</h2>
172-
<p class="hint">Pin samples with the star button to keep quick access between visits.</p>
173-
<div class="grid" id="samples-favorites-grid"></div>
174-
<p class="empty" id="samples-favorites-empty">No pinned samples yet.</p>
175-
</section>
170+
<p></p>
176171
</div>
177172

173+
<section class="samples-favorites" aria-label="Pinned samples">
174+
<h2>Pinned Samples</h2>
175+
<p class="hint">Pin samples with the star button to keep quick access between visits.</p>
176+
<div class="grid" id="samples-favorites-grid"></div>
177+
<p class="empty" id="samples-favorites-empty">No pinned samples yet.</p>
178+
</section>
179+
178180
<section class="samples-filters" aria-label="Sample filters">
179181
<div>
180182
<label for="sample-phase-filter">Phase</label>

src/engine/theme/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
This folder now contains the raw shared header source plus the importable module.
44

55
## Files
6-
- `toolboxaid-header.template.html` → raw shared header markup
6+
- `toolboxaid-header.html` → raw shared header markup
77
- `toolboxaid-header.css` → shared styling
88
- `toolboxaid-header.js` → importable module that exports the HTML and mount helpers
99
- `index.js` → re-export entry

src/engine/theme/toolboxaid-header.css

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,12 @@
1010
--toolboxaid-max-width: 1200px;
1111
}
1212

13+
.header-image{
14+
background-color: #3600af;
15+
background-image: url('/src/engine/theme/toolboxaid-header.png') !important;
16+
border-bottom: 8px solid #3600af;
17+
}
18+
1319
.toolboxaid-theme-header {
1420
box-sizing: border-box;
1521
width: 100%;

src/engine/theme/toolboxaid-header.template.html renamed to src/engine/theme/toolboxaid-header.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
</div> -->
77

88
<div id="image" class="header-image bg-image-fill site-tagline">
9-
<h1 class="site-name align-center"><a href="__TITLE_URL__">__TITLE__</a></h1>
9+
<!-- <h1 class="site-name align-center"><a href="__TITLE_URL__">__TITLE__</a></h1> -->
1010
</div>
1111

1212
<div id="tagline" class="site-tagline site-tagline-alt align-center">

src/engine/theme/toolboxaid-header.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,10 @@ async function loadTemplate() {
2626
return templateCache;
2727
}
2828

29-
const templateUrl = new URL('./toolboxaid-header.template.html', import.meta.url);
29+
const templateUrl = new URL('./toolboxaid-header.html', import.meta.url);
3030
const response = await fetch(templateUrl);
3131
if (!response.ok) {
32-
throw new Error('Failed to load toolboxaid-header.template.html');
32+
throw new Error('Failed to load toolboxaid-header.html');
3333
}
3434

3535
templateCache = await response.text();
140 KB
Loading

src/engine/ui/baseLayout.css

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ body::before {
2929
inset: 0;
3030
z-index: -1;
3131
background-color: #4c1d95;
32-
background-image: linear-gradient(
32+
/* background-image: linear-gradient(
3333
to bottom,
3434
#c4b5fd,
3535
#a78bfa,
@@ -38,7 +38,7 @@ body::before {
3838
#6d28d9,
3939
#5b21b6,
4040
#4c1d95
41-
);
41+
); */
4242
background-repeat: no-repeat;
4343
pointer-events: none;
4444
}

0 commit comments

Comments
 (0)