Skip to content

Commit 7a3f3c3

Browse files
authored
move edit link (#105)
* move edit link * tweak
1 parent d3d5ad0 commit 7a3f3c3

File tree

1 file changed

+24
-17
lines changed

1 file changed

+24
-17
lines changed

apps/svelte.dev/src/routes/docs/[...path]/+page.svelte

Lines changed: 24 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -25,21 +25,23 @@
2525
<div class="text" id="docs-content" use:ts_js_select use:copy_code_descendants use:legacy_details>
2626
<header>
2727
<h1>{data.document.metadata.title}</h1>
28+
</header>
29+
30+
<OnThisPage {content} document={data.document} />
2831

32+
<div class="content" bind:this={content}>
33+
{@html data.document.body}
34+
</div>
35+
36+
<p class="edit">
2937
<a
3038
class="edit"
3139
href="https://github.com/sveltejs/svelte.dev/edit/main/apps/svelte.dev/content/{data.document
3240
.file}"
3341
>
3442
<Icon size={50} name="edit" /> Edit this page on GitHub
3543
</a>
36-
</header>
37-
38-
<OnThisPage {content} document={data.document} />
39-
40-
<div class="content" bind:this={content}>
41-
{@html data.document.body}
42-
</div>
44+
</p>
4345
</div>
4446

4547
<div class="controls">
@@ -65,15 +67,20 @@
6567
font-size: 1.4rem;
6668
line-height: 1;
6769
z-index: 2;
68-
}
69-
70-
.edit :global(.icon) {
71-
position: relative;
72-
top: -0.1rem;
73-
left: 0.3rem;
74-
width: 1.4rem;
75-
height: 1.4rem;
76-
margin-right: 0.5rem;
70+
margin: 6rem 0 2rem 0;
71+
72+
a {
73+
text-decoration: none;
74+
}
75+
76+
:global(.icon) {
77+
position: relative;
78+
top: -0.1rem;
79+
left: 0.3rem;
80+
width: 1.4rem;
81+
height: 1.4rem;
82+
margin-right: 0.5rem;
83+
}
7784
}
7885
7986
.controls {
@@ -82,7 +89,7 @@
8289
padding: 1rem 0 0 0;
8390
display: grid;
8491
grid-template-columns: 1fr 1fr;
85-
margin: 6rem 0 0 0;
92+
margin: 1rem 0 0 0;
8693
}
8794
8895
.controls > :first-child {

0 commit comments

Comments
 (0)