Skip to content

Commit e0684d0

Browse files
adjust article elements styles
1 parent 3eb2f16 commit e0684d0

File tree

4 files changed

+59
-34
lines changed

4 files changed

+59
-34
lines changed

src/features/common/components/article/article.module.scss

Lines changed: 55 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,8 @@
1212
.article {
1313
display: flex;
1414
flex-direction: column;
15-
1615
grid-column: span 6;
17-
max-width: 48.5rem;
16+
max-width: 46rem;
1817
justify-self: center;
1918

2019
@media #{$breakpoint-dimension-sm} {
@@ -35,7 +34,7 @@
3534
font-size: 2rem;
3635
line-height: 2.5rem;
3736
font-style: normal;
38-
font-weight: 400;
37+
font-weight: 500;
3938
letter-spacing: -0.05rem;
4039
margin-bottom: 1.5rem;
4140
font-family: var(--font-secondary), sans-serif;
@@ -56,13 +55,12 @@
5655

5756
h3 {
5857
color: var(--color_fg_bold);
59-
6058
font-size: 1.5rem;
6159
line-height: 2rem;
6260
font-style: normal;
63-
font-weight: 400;
61+
font-weight: 500;
6462
letter-spacing: -0.05rem;
65-
margin-bottom: 2rem;
63+
margin-bottom: 1.5rem;
6664
font-family: var(--font-secondary), sans-serif;
6765

6866
:global(html[lang="ja"]) & {
@@ -77,11 +75,11 @@
7775
"clig" off,
7876
"liga" off;
7977
font-size: 1rem;
80-
line-height: 1.5em;
78+
line-height: 1.45;
8179
font-style: normal;
8280
font-weight: 400;
8381
letter-spacing: -0.005rem;
84-
margin-bottom: 2rem;
82+
margin-bottom: 1rem;
8583

8684
:global(html[lang="ja"]) & {
8785
@include LocaleLineHeight("ja", 1.5rem);
@@ -95,12 +93,10 @@
9593

9694
ul,
9795
ol {
98-
list-style-position: inside;
9996
margin-top: 0;
10097

10198
ul,
10299
ol {
103-
list-style-position: inside;
104100
margin-left: 1.5rem;
105101
padding-left: 0;
106102
}
@@ -109,11 +105,11 @@
109105
li {
110106
margin-bottom: 0.75rem;
111107
font-size: 1rem;
112-
line-height: 2rem;
108+
line-height: 1.45;
113109
color: var(--color_fg_default);
114110
letter-spacing: -0.01px;
115-
text-indent: -1.5rem;
116-
padding-left: 1.5rem;
111+
margin-left: 1rem;
112+
padding-left: 1rem;
117113

118114
:global(html[lang="ja"]) & {
119115
@include LocaleLineHeight("ja", 2rem);
@@ -124,9 +120,9 @@
124120
&,
125121
&:hover,
126122
&:active {
127-
color: var(--color_fg_link_primary);
128123
text-decoration: underline;
129-
font-weight: 400;
124+
font-weight: 500;
125+
text-underline-offset: 0.25rem;
130126
}
131127
}
132128

@@ -136,42 +132,70 @@
136132
}
137133

138134
pre {
139-
margin-bottom: 2rem;
140-
background-color: var(--color_bg_code-editor);
135+
margin-bottom: 1rem;
136+
background-color: var(--color_bg_layer_alternate);
141137
color: var(--color_fg_default);
142138
font-size: 0.875rem;
143139
line-height: 1.375rem;
144140
font-style: normal;
145141
font-weight: 400;
146142
letter-spacing: 0.15px;
147-
padding: 0.75rem;
143+
padding: 0.25rem;
148144
border: 1px solid var(--color_border_bold);
149-
border-radius: 0.25rem;
145+
border-radius: 1rem;
150146

151147
code {
152-
color: var(--color_code_dark_blue2);
148+
display: block;
149+
width: 100%;
150+
color: var(--color_code_gray);
153151
background-color: var(--color_bg_code-editor);
154152
font-weight: 500;
155-
}
156-
157-
@media #{$breakpoint-dimension-sm} {
158-
border-radius: 0.5rem;
159-
padding: 1rem;
153+
font-size: 0.875rem;
154+
line-height: 1.35;
155+
border-radius: 0.75rem;
156+
padding: 0.75rem;
157+
box-shadow:
158+
0 0 0 0.5px rgba(0, 0, 0, 0.12),
159+
0 2px 2px -1px rgba(0, 0, 0, 0.04),
160+
0 4px 4px -2px rgba(0, 0, 0, 0.04),
161+
0 6px 6px -3px rgba(0, 0, 0, 0.04);
160162
}
161163
}
162164

163165
blockquote {
164-
background-color: var(--color_bg_state_info_subtle);
165-
padding: 1rem 1.5rem;
166-
margin: 2rem 0 2rem 0;
167-
border-radius: 0 0.5rem 0.5rem 0;
168-
border-left: 4px solid var(--color_border_state_info);
166+
background-color: var(--color_bg_layer);
167+
font-size: 0.875rem;
168+
padding: 1rem;
169+
margin: 2rem 0;
170+
border-radius: 1rem;
171+
border: 1px solid var(--color_border_default);
172+
box-shadow:
173+
0 0 0 0.5px rgba(0, 0, 0, 0.12),
174+
0 2px 2px -1px rgba(0, 0, 0, 0.04),
175+
0 4px 4px -2px rgba(0, 0, 0, 0.04),
176+
0 6px 6px -3px rgba(0, 0, 0, 0.04);
169177

170178
& * {
171-
color: var(--color_fg_on_state_info_subtle);
179+
color: var(--color_fg_default);
172180
padding: 0;
173181
margin: 0;
174182
}
183+
184+
p {
185+
display: flex;
186+
flex-direction: row;
187+
font-size: 0.875rem;
188+
align-items: center;
189+
gap: 0.75rem;
190+
}
191+
192+
::before {
193+
content: url("data:image/svg+xml,%3Csvg width='12' height='12' viewBox='0 0 12 12' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M6 0.5C9.03757 0.5 11.5 2.96243 11.5 6C11.5 9.03757 9.03757 11.5 6 11.5C2.96243 11.5 0.5 9.03757 0.5 6C0.5 2.96243 2.96243 0.5 6 0.5ZM6 5.25C5.72386 5.25 5.5 5.47386 5.5 5.75V8.75H6.5V5.75C6.5 5.47386 6.27614 5.25 6 5.25ZM6 3.125C5.65482 3.125 5.375 3.40482 5.375 3.75C5.375 4.09518 5.65482 4.375 6 4.375C6.34518 4.375 6.625 4.09518 6.625 3.75C6.625 3.40482 6.34518 3.125 6 3.125Z' fill='%235C5650'/%3E%3C/svg%3E%0A");
194+
display: block;
195+
padding: 0.25rem 0.4rem 0.125rem;
196+
border-radius: 9999px;
197+
background-color: var(--color_bg_layer_alternate);
198+
}
175199
}
176200

177201
*:has(+ blockquote) {

src/features/introduction/components/ebook-ad/ebook-ad.module.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
.copy {
2323
font-weight: 400;
2424
line-height: 1.25rem;
25-
font-size: 1rem;
25+
font-size: 0.875rem;
2626
color: var(--color_fg_default);
2727

2828
& strong {

src/features/introduction/components/introduction-article/introduction-article.component.tsx

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,6 @@ import { SidebarNavComponent } from "../sidebar-nav/sidebar-nav.component";
88
import { EbookAdComponent } from "../ebook-ad/ebook-ad.component";
99
import { getComponentDictionary } from "@/features/localization/services/component-dictionary.service";
1010
import { IntroductionDictionaryModel } from "@/features/localization/models/introduction-dictionary.model";
11-
import clsx from "clsx";
12-
import { getLocalizedSecondaryFont } from "@/libs/theme/fonts";
1311
import { IntroductionHeroComponent } from "../introduction-hero/introduction-hero.component";
1412

1513
interface IntroductionArticleComponentProps {

src/features/introduction/components/introduction-article/introduction-article.module.scss

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@
44
display: flex;
55
}
66

7+
.content {
8+
}
9+
710
.title {
811
color: var(--color_fg_bold);
912
font-size: 2rem;

0 commit comments

Comments
 (0)