-
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtypography.html
More file actions
148 lines (130 loc) · 4.44 KB
/
typography.html
File metadata and controls
148 lines (130 loc) · 4.44 KB
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
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Demo: Typography & Text Features</title>
<style>
* { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: Arial, sans-serif; padding: 20px; }
h2 { margin: 15px 0 8px; font-size: 18px; }
.text-wrap {
width: 250px;
padding: 10px;
background: #fff3e0;
border: 1px solid #ffcc80;
border-radius: 6px;
margin: 10px 0;
font-size: 14px;
line-height: 1.6;
color: #333;
}
.text-large {
font-size: 32px;
font-weight: 900;
color: #1a237e;
margin: 8px 0;
}
.text-italic {
font-style: italic;
font-size: 16px;
color: #4a148c;
margin: 8px 0;
}
.text-underline {
text-decoration: underline;
font-size: 16px;
color: #b71c1c;
margin: 8px 0;
}
.text-strikethrough {
text-decoration: line-through;
font-size: 16px;
color: #757575;
margin: 8px 0;
}
.text-shadow-demo {
font-size: 28px;
font-weight: bold;
color: #1e88e5;
text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
margin: 8px 0;
}
.text-overflow-ellipsis {
width: 200px;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
background: #e8eaf6;
padding: 8px;
border-radius: 4px;
margin: 8px 0;
}
.text-multicolumn {
column-count: 2;
column-gap: 20px;
width: 400px;
font-size: 12px;
line-height: 1.5;
padding: 10px;
background: #f5f5f5;
border: 1px solid #ddd;
margin: 10px 0;
}
.text-right { text-align: right; margin: 4px 0; font-size: 14px; }
.text-center { text-align: center; margin: 4px 0; font-size: 14px; }
.text-justify { text-align: justify; margin: 4px 0; font-size: 14px; width: 300px; }
.inline-formatting {
margin: 10px 0;
font-size: 15px;
line-height: 1.8;
}
.inline-formatting em { color: #d32f2f; }
.inline-formatting strong { color: #1565c0; }
.inline-formatting code {
background: #263238;
color: #80cbc4;
padding: 2px 6px;
border-radius: 3px;
font-family: monospace;
font-size: 13px;
}
</style>
</head>
<body>
<div id="root">
<h2>Text Wrapping</h2>
<div class="text-wrap">
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.
</div>
<h2>Font Sizes & Weights</h2>
<div class="text-large">Large Bold Title</div>
<div class="text-italic">Italic text content</div>
<h2>Text Decorations</h2>
<div class="text-underline">Underlined text</div>
<div class="text-strikethrough">Strikethrough text</div>
<h2>Text Shadow</h2>
<div class="text-shadow-demo">Shadow Text</div>
<h2>Text Overflow</h2>
<div class="text-overflow-ellipsis">This is a very long text that should be truncated with an ellipsis at the end</div>
<h2>Text Alignment</h2>
<div style="width: 300px; background: #e8f5e9; padding: 10px; border: 1px solid #c8e6c9;">
<div class="text-right">Right aligned</div>
<div class="text-center">Center aligned</div>
<div class="text-justify">Justified text that spans across the full width of the container element here.</div>
</div>
<h2>Multi-column Text</h2>
<div class="text-multicolumn">
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla facilisi. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident.
</div>
<h2>Inline Formatting</h2>
<div class="inline-formatting">
This has <em>italic emphasis</em> and <strong>bold text</strong> and <code>inline code</code> mixed together in a single paragraph.
</div>
<h2>Multi-column Text 2</h2>
<div class="text-multicolumn" style="rotate: -30deg; position: relative; top: 50px;">
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nulla facilisi. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident.
</div>
</div>
</body>
</html>