Skip to content

Commit 6d27a52

Browse files
committed
Add assistant links
1 parent 7b0d071 commit 6d27a52

File tree

2 files changed

+37
-28
lines changed

2 files changed

+37
-28
lines changed

pages/maps/+Page.ts

Lines changed: 24 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -59,29 +59,31 @@ export function Page() {
5959
};
6060

6161
return h('div.maps-page', [
62-
h(AssistantLinks, { className: "assistant-links" }, [
63-
h(
64-
AnchorButton,
65-
{ icon: "flows", href: "/maps/ingestion" },
66-
"Ingestion system"
67-
),
68-
h(AnchorButton, { icon: "map", href: "/map/sources" }, "Show on map"),
69-
h(DevLinkButton, { href: "/maps/legend" }, "Legend table"),
70-
]),
7162
h(ContentPage, [
72-
h(StickyHeader, {className: "header"}, [
73-
h(PageBreadcrumbs, {
74-
title: "Maps",
75-
}),
76-
h(SearchBar, {
77-
placeholder: "Filter by name...",
78-
onChange: handleChange,
79-
}),
80-
h(Switch, {
81-
label: "Active only",
82-
checked: activeOnly,
83-
onChange: () => setActiveOnly(!activeOnly),
84-
}),
63+
h(StickyHeader, {className: "header-container"}, [
64+
h('div.header', [
65+
h(PageBreadcrumbs, {
66+
title: "Maps",
67+
}),
68+
h(SearchBar, {
69+
placeholder: "Filter by name...",
70+
onChange: handleChange,
71+
}),
72+
h(Switch, {
73+
label: "Active only",
74+
checked: activeOnly,
75+
onChange: () => setActiveOnly(!activeOnly),
76+
}),
77+
]),
78+
h(AssistantLinks, { className: "assistant-links" }, [
79+
h(
80+
AnchorButton,
81+
{ icon: "flows", href: "/maps/ingestion" },
82+
"Ingestion system"
83+
),
84+
h(AnchorButton, { icon: "map", href: "/map/sources" }, "Show on map"),
85+
h(DevLinkButton, { href: "/maps/legend" }, "Legend table"),
86+
]),
8587
]),
8688
h(
8789
"div.strat-list",

pages/maps/main.module.scss

Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -130,12 +130,6 @@ h1, h3 {
130130
background-color: #3498DB;
131131
}
132132

133-
.header {
134-
display: flex;
135-
flex-direction: column;
136-
gap: 1em;
137-
}
138-
139133
.maps-page {
140134
width: 100%;
141135
}
@@ -164,4 +158,17 @@ h1, h3 {
164158
h2 {
165159
margin: 0;
166160
}
161+
}
162+
163+
.header-container {
164+
display: flex;
165+
align-items: center;
166+
justify-content: space-between;
167+
168+
.header {
169+
display: flex;
170+
flex-direction: column;
171+
gap: 1em;
172+
width: 70%
173+
}
167174
}

0 commit comments

Comments
 (0)