FormatDigital
The FormatDigital component is designed to format numeric values into a human-readable digital format with respect to various unit prefixes such as kilo, mega, giga, etc. It offers options to customize units, display style of units and supports localization.
Basic Usage
Display formats
Byte formats
Bit formats
Attributes and Properties
unit
Description | Defines the unit for displaying values. |
Attribute | unit |
Type | "bit" | "byte" | string & Record<never, never> | undefined |
Default | bytes |
unit-display
Description | Sets the fragment size for uploading large files in bytes. |
Attribute | unit-display |
Type | "long" | "narrow" | "short" | string & Record<never, never> | undefined |
Default | short |
Events
No events available for this component.
Methods
No public methods available for this component.
CSS Shadow Parts
Name | Description |
---|---|
native | References a div element with the native-format-digital class inside the element |
CSS Custom Properties
No CSS custom properties available for this component.
Slots
Name | Description |
---|---|
`` | The contents are placed between the named slots. |
end | The content is placed to the right of the button text in LTR and to the left in RTL |
start | The content is placed to the left of the button text in LTR and to the right in RTL. |