Skip to content

Commit c5829ab

Browse files
committed
fix: rename css variable from dim to subtle
1 parent 0ea3967 commit c5829ab

File tree

4 files changed

+38
-13
lines changed

4 files changed

+38
-13
lines changed

README.md

Lines changed: 27 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,10 +68,35 @@ import "bsky-widget";
6868
| show-banner | hide / show your banner (only applicable if you have a banner) | "true" (default) or "false" |
6969
| theme | theme of the card (`dark`, `dim`, `auto`, `auto-dim`, `light`) | "light" |
7070

71-
## Migration from v0.0 -> v0.1
72-
7371

72+
## Override Styles
73+
74+
You can go ahead and override any of these styles to customize your card further, create custom themes, or adjust the card in your website's layout
75+
76+
```css
77+
bsky-widget {
78+
--bsky-background: #fff;
79+
--bsky-primary: #1185fe;
80+
--bsky-primary-hover: #4ca2fe;
81+
--bsky-text-on-primary: #fff;
82+
--bsky-text-on-background: #0b0f14;
83+
--bsky-text-on-background-subtle: #42576c;
84+
--bsky-text-large: 1.4rem;
85+
--bsky-text-large-line-height: 1.8rem;
86+
--bsky-text-medium: 1rem;
87+
--bsky-text-small: 0.9rem;
88+
89+
font-family: Arial, Helvetica, sans-serif, -apple-system, sans-serif;
90+
width: 350px;
91+
max-width: 100%;
92+
min-height: 170px;
93+
display: inline-block;
94+
box-shadow: 1px 1px 8px 1px #0002;
95+
border-radius: 8px;
96+
}
97+
```
7498

99+
## Migration from v0.0 -> v0.1
75100

76101
> [!Note]
77102
>

lib/styles.css

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
--bsky-primary-hover: #4ca2fe;
1010
--bsky-text-on-primary: #fff;
1111
--bsky-text-on-background: #0b0f14;
12-
--bsky-text-on-background-dim: #42576c;
12+
--bsky-text-on-background-subtle: #42576c;
1313
--bsky-text-large: 1.4rem;
1414
--bsky-text-large-line-height: 1.8rem;
1515
--bsky-text-medium: 1rem;
@@ -38,26 +38,26 @@
3838
:host([theme="dark"]) {
3939
--bsky-background: #000000;
4040
--bsky-text-on-background: #F1F3F5;
41-
--bsky-text-on-background-dim: #8c9eb2;
41+
--bsky-text-on-background-subtle: #8c9eb2;
4242
}
4343

4444
:host([theme="dim"]) {
4545
--bsky-background: #171E27;
4646
--bsky-text-on-background: #F1F3F5;
47-
--bsky-text-on-background-dim: #aebbc9;
47+
--bsky-text-on-background-subtle: #aebbc9;
4848
}
4949

5050
@media (prefers-color-scheme: dark) {
5151
:host([theme="auto"]) {
5252
--bsky-background: #000000;
5353
--bsky-text-on-background: #F1F3F5;
54-
--bsky-text-on-background-dim: #8c9eb2;
54+
--bsky-text-on-background-subtle: #8c9eb2;
5555
}
5656

5757
:host([theme="auto-dim"]) {
5858
--bsky-background: #171E27;
5959
--bsky-text-on-background: #F1F3F5;
60-
--bsky-text-on-background-dim: #aebbc9;
60+
--bsky-text-on-background-subtle: #aebbc9;
6161
}
6262
}
6363

@@ -180,8 +180,8 @@ a:hover {
180180
gap: 2px;
181181
}
182182

183-
.dim-text {
184-
color: var(--bsky-text-on-background-dim);
183+
.subtle-text {
184+
color: var(--bsky-text-on-background-subtle);
185185
}
186186

187187
.followers {

lib/template.abell

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,10 @@
1616
</div>
1717
<div class="name-handle-container padded">
1818
<h2>{{ props.displayName }}</h2>
19-
<p class="handle dim-text">@{{ props.handle }}</p>
19+
<p class="handle subtle-text">@{{ props.handle }}</p>
2020
<div class="followers">
21-
<p><span class="count">{{ formatFollowCount(props.followersCount) }}</span> <span class="dim-text">Followers</span></p>
22-
<p><span class="count">{{ formatFollowCount(props.followsCount) }}</span> <span class="dim-text">Following</span></p>
21+
<p><span class="count">{{ formatFollowCount(props.followersCount) }}</span> <span class="subtle-text">Followers</span></p>
22+
<p><span class="count">{{ formatFollowCount(props.followsCount) }}</span> <span class="subtle-text">Following</span></p>
2323
</div>
2424
</div>
2525
</div>

test.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
--bsky-primary-hover: #ae75f3;
1212
--bsky-text-on-primary: #000;
1313
--bsky-text-on-background: #ddd;
14-
--bsky-text-on-background-dim: #ddd;
14+
--bsky-text-on-background-subtle: #ddd;
1515
--bsky-text-large: 1.5rem;
1616
--bsky-text-large-line-height: 1.9rem;
1717
--bsky-text-medium: 1.1rem;

0 commit comments

Comments
 (0)