Skip to content

Commit 6449f49

Browse files
committed
Fix count styling
1 parent 6e76dc8 commit 6449f49

File tree

2 files changed

+14
-6
lines changed

2 files changed

+14
-6
lines changed

index.html

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -28,11 +28,12 @@ <h1>
2828
[passclass(feature.score)]: true,
2929
feature: species === 'Feature',
3030
}" :data-level="level" ref="container">
31-
<support-status :score="feature.score" v-if="showScore"></support-status>
31+
<support-status :title="feature.result?.note || null" :score="feature.score" v-if="showScore"></support-status>
3232
<wrap-if v-if="feature.title || feature.code || feature.id" :is="species === 'Feature' ? '' : 'h' + level" class="title">
3333
<span class="title" v-if="feature.titleHtml" v-html="feature.titleHtml"></span>
3434
<wrap-if :is="feature.title ? 'span' : 'code'" class="title" v-else v-text="feature.title ?? feature.code ?? feature.id"></wrap-if>
3535
</wrap-if>
36+
<span class="prefix" v-if="feature.result?.prefix">{{ feature.result.prefix }}</span>
3637

3738
<div class="meta" v-if="permalink || feature.link || feature.mdnLink">
3839
<a v-if="permalink" :href="permalink" class="icon-before permalink" title="Permalink"></a>
@@ -45,15 +46,13 @@ <h1>
4546
<a v-if="feature.mdnLink" :href="feature.mdnLink" target="_blank" class="badge spec-link mdn-link">MDN</a>
4647
</div>
4748

48-
<span class="count" v-if="showFeatureCount">{{ feature.score.total }}</span>
49+
<div class="spacer"></div>
4950

50-
<span class="prefix" v-if="feature.result?.prefix">{{ feature.result.prefix }}</span>
51-
<span class="note" v-if="feature.result?.note">{{ feature.result.note }}</span>
51+
<span class="count" v-if="showFeatureCount">{{ feature.score.total }}</span>
5252
</component>
5353
<div v-if="renderedChildren.length > 0" class="feature-children">
5454
<bs-feature v-for="child, index of renderedChildren" :parent="feature" :feature="child" :key="child.uid" :level="level + 1"></bs-feature>
5555
</div>
56-
5756
</wrap-if>
5857

5958
</template>

ui/css/style.css

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -314,7 +314,6 @@ summary {
314314
&::after {
315315
content:'';
316316
display: inline-block;
317-
margin-inline-start: auto;
318317
vertical-align: -.1em;
319318
font-size: max(1em, 1rem);
320319
width: 1em;
@@ -328,6 +327,12 @@ summary {
328327
transition: transform 0.2s;
329328
}
330329

330+
&:not(:has(> .spacer)) {
331+
&::after {
332+
margin-inline-start: auto;
333+
}
334+
}
335+
331336
&:is([open] > *)::after {
332337
transform: rotate(90deg);
333338
}
@@ -420,3 +425,7 @@ footer {
420425
inset-inline-end: .5em;
421426
z-index: 1;
422427
}
428+
429+
.spacer {
430+
flex: 1;
431+
}

0 commit comments

Comments
 (0)