Solve 50+ cargo doc warnings (#24071)

Release Notes:

- N/A
This commit is contained in:
João Marcos 2025-02-01 03:19:29 -03:00 committed by GitHub
parent 39d45bcbc1
commit 5bd7eaa173
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
35 changed files with 99 additions and 89 deletions

View file

@ -349,8 +349,8 @@ impl ButtonCommon for Button {
/// Sets a tooltip for the button.
///
/// This method allows a tooltip to be set for the button. The tooltip is a function that
/// takes a mutable reference to a [`WindowContext`] and returns an [`AnyView`]. The tooltip
/// is displayed when the user hovers over the button.
/// takes a mutable references to [`Window`] and [`App`], and returns an [`AnyView`]. The
/// tooltip is displayed when the user hovers over the button.
///
/// # Examples
///

View file

@ -31,7 +31,7 @@ pub struct ContentGroup {
}
impl ContentGroup {
/// Creates a new [ContentBox].
/// Creates a new [`ContentGroup`].
pub fn new() -> Self {
Self {
base: div(),
@ -41,13 +41,13 @@ impl ContentGroup {
}
}
/// Removes the border from the [ContentBox].
/// Removes the border from the [`ContentGroup`].
pub fn borderless(mut self) -> Self {
self.border = false;
self
}
/// Removes the background fill from the [ContentBox].
/// Removes the background fill from the [`ContentGroup`].
pub fn unfilled(mut self) -> Self {
self.fill = false;
self

View file

@ -28,7 +28,7 @@ pub enum VectorName {
/// A vector image, such as an SVG.
///
/// A [`Vector`] is different from an [`Icon`] in that it is intended
/// A [`Vector`] is different from an [`crate::Icon`] in that it is intended
/// to be displayed at a specific size, or series of sizes, rather
/// than conforming to the standard size of an icon.
#[derive(IntoElement)]

View file

@ -42,8 +42,9 @@ impl Navigable {
}
/// Add a new entry that can be navigated to via keyboard.
/// The order of calls to [Navigable::entry] determines the order of traversal of elements via successive
/// uses of [menu:::SelectNext]/[menu::SelectPrev]
///
/// The order of calls to [Navigable::entry] determines the order of traversal of
/// elements via successive uses of `menu:::SelectNext/SelectPrev`
pub fn entry(mut self, child: NavigableEntry) -> Self {
self.selectable_children.push(child);
self
@ -59,6 +60,7 @@ impl Navigable {
.position(|entry| entry.focus_handle.contains_focused(window, cx))
}
}
impl RenderOnce for Navigable {
fn render(self, _window: &mut Window, _: &mut App) -> impl crate::IntoElement {
div()

View file

@ -5,6 +5,8 @@ use std::sync::Arc;
use crate::prelude::*;
/// A [`Checkbox`] that has a [`Label`].
///
/// [`Checkbox`]: crate::components::Checkbox
#[derive(IntoElement)]
pub struct RadioWithLabel {
id: ElementId,