Struct OlBuilder

Source
pub struct OlBuilder(/* private fields */);

Implementations§

Source§

impl OlBuilder

Source

pub fn id(self, value: impl AttributeValue<String>) -> Self

Source

pub fn class(self, value: impl AttributeValue<String>) -> Self

Source

pub fn reversed(self, value: impl AttributeValue<bool>) -> Self

Specifies that the list’s items are in reverse order. Items will be numbered from high to low.

Source

pub fn start(self, value: impl AttributeValue<u32>) -> Self

An integer to start counting from for the list items. Always an Arabic numeral (1, 2, 3, etc.), even when the numbering type is letters or Roman numerals. For example, to start numbering elements from the letter “d” or the Roman numeral “iv,” use start=“4”.

Source

pub fn type_(self, value: impl AttributeValue<String>) -> Self

Sets the numbering type:

  • a for lowercase letters
  • A for uppercase letters
  • i for lowercase Roman numerals
  • I for uppercase Roman numerals
  • 1 for numbers (default)

The specified type is used for the entire list unless a different type attribute is used on an enclosed <li> element.

Note: Unless the type of the list number matters (like legal or technical documents where items are referenced by their number/letter), use the CSS list-style-type property instead.

Source§

impl OlBuilder

Source

pub fn on_blur( self, f: impl 'static + FnMut(FocusEvent, HtmlOListElement), ) -> Self

Source

pub fn on_click( self, f: impl 'static + FnMut(MouseEvent, HtmlOListElement), ) -> Self

Source

pub fn on_change(self, f: impl 'static + FnMut(Event, HtmlOListElement)) -> Self

Source

pub fn on_dblclick( self, f: impl 'static + FnMut(MouseEvent, HtmlOListElement), ) -> Self

Source

pub fn on_focusout( self, f: impl 'static + FnMut(FocusEvent, HtmlOListElement), ) -> Self

Source

pub fn on_input( self, f: impl 'static + FnMut(InputEvent, HtmlOListElement), ) -> Self

Source

pub fn on_keydown( self, f: impl 'static + FnMut(KeyboardEvent, HtmlOListElement), ) -> Self

Source

pub fn on_keyup( self, f: impl 'static + FnMut(KeyboardEvent, HtmlOListElement), ) -> Self

Source

pub fn effect(self, f: impl Effect<HtmlOListElement>) -> Self

Source§

impl OlBuilder

Source

pub fn text(self, child: impl Text) -> Self

Source

pub fn child<Child>(self, c: Child) -> Self
where Child: Into<Element>,

Trait Implementations§

Source§

impl Builder for OlBuilder

Source§

impl DomElement for OlBuilder

Source§

impl From<OlBuilder> for Element

Source§

fn from(builder: OlBuilder) -> Self

Converts to this type from the input type.
Source§

impl From<OlBuilder> for ElementBuilder

Source§

fn from(builder: OlBuilder) -> Self

Converts to this type from the input type.

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.