Rollup merge of #95738 - GuillaumeGomez:item-info-switch-to-span, r=jsha
Switch item-info from div to span Following discussion in #95684. cc `@jsha` r? `@notriddle`
This commit is contained in:
commit
fe6d69f410
@ -597,11 +597,11 @@ fn document_item_info(
|
||||
) {
|
||||
let item_infos = short_item_info(item, cx, parent);
|
||||
if !item_infos.is_empty() {
|
||||
w.write_str("<div class=\"item-info\">");
|
||||
w.write_str("<span class=\"item-info\">");
|
||||
for info in item_infos {
|
||||
w.write_str(&info);
|
||||
}
|
||||
w.write_str("</div>");
|
||||
w.write_str("</span>");
|
||||
}
|
||||
}
|
||||
|
||||
@ -1772,7 +1772,7 @@ pub(crate) fn render_impl_summary(
|
||||
let is_trait = i.inner_impl().trait_.is_some();
|
||||
if is_trait {
|
||||
if let Some(portability) = portability(&i.impl_item, Some(parent)) {
|
||||
write!(w, "<div class=\"item-info\">{}</div>", portability);
|
||||
write!(w, "<span class=\"item-info\">{}</span>", portability);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -737,6 +737,10 @@ h2.location a {
|
||||
border: none;
|
||||
}
|
||||
|
||||
.item-info {
|
||||
display: block;
|
||||
}
|
||||
|
||||
.content .item-info code {
|
||||
font-size: 0.875rem;
|
||||
}
|
||||
|
@ -4,7 +4,7 @@
|
||||
|
||||
pub struct Unstable {
|
||||
// @has stability/struct.Unstable.html \
|
||||
// '//div[@class="item-info"]//div[@class="stab unstable"]' \
|
||||
// '//span[@class="item-info"]//div[@class="stab unstable"]' \
|
||||
// 'This is a nightly-only experimental API'
|
||||
// @count stability/struct.Unstable.html '//span[@class="stab unstable"]' 0
|
||||
pub foo: u32,
|
||||
|
Loading…
x
Reference in New Issue
Block a user