generated from daviddarnes/component-template
-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
demo.html
68 lines (58 loc) · 1.46 KB
/
demo.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta name="description" content="Demo of mastodon-post Web Component" />
<title>mastodon-post Web Component Demo</title>
<style>
mastodon-post {
font-family: system-ui;
}
mastodon-post:not(:defined) figure,
mastodon-post:defined > a {
display: none;
}
mastodon-post {
display: block;
max-inline-size: max-content;
}
mastodon-post blockquote {
margin: 0;
border-inline-start: 2px solid currentColor;
padding-inline-start: 1rem;
}
mastodon-post figure {
margin: 0;
}
mastodon-post figcaption,
mastodon-post dl {
margin: 0;
display: flex;
flex-wrap: wrap;
align-items: end;
gap: 1rem;
}
mastodon-post dl {
justify-content: end;
gap: 0.25rem;
margin-inline-start: auto;
}
mastodon-post dt {
margin-inline-start: 1rem;
}
mastodon-post dd {
margin-inline-start: 0;
}
</style>
<script type="module" src="mastodon-post.js"></script>
</head>
<body>
<h2>General usage example</h2>
<mastodon-post>
<a href="https://mastodon.design/@DavidDarnes/109824258017750161">
Discuss on Mastodon
</a>
</mastodon-post>
</body>
</html>