/** * Copyright IBM Corp. 2026 * * This source code is licensed under the Apache-2.0 license found in the * LICENSE file in the root directory of this source tree. */ import React, { ReactNode } from 'react'; import { BigNumberSizeValues } from './constants'; export interface BigNumberProps { /** * Provide an optional class to be applied to the containing node. */ className?: string; /** * The default behavior will hide `total` if `undefined` or is the same as `value`. * * Set to `true` to ignore the default behavior and show the `total`. */ forceShowTotal?: boolean; /** * Specifies the number of fraction digits when truncating `value` and `total`. */ fractionDigits?: number; /** * Displays an icon button next to `value`. */ iconButton?: ReactNode; /** * Text label above the `value`. */ label: string; /** * When `true`, will show the loading state. */ loading?: boolean; /** * Determines how `value` and `total` will be formatted. */ locale?: string; /** * Appends a percent sign (_%_) after `value` and hides `total`. */ percentage?: boolean; /** * Controls the visual size of the component. */ size?: BigNumberSizeValues; /** * When applied, an information icon will be rendered next to the * `label` and the description will be applied to its tooltip. */ tooltipDescription?: string; /** * The number that will appear after the slash (i.e. the "denominator" of a fraction). * * This number will not be rendered if it's the same as `value` or * `percentage` is true. See also the **forceShowTotal** prop. */ total?: number; /** * When `true`, will render a "trending up" icon. */ trending?: boolean; /** * Abbreviates the number when `true`. E.g. from _1,000_ to _1K_. */ truncate?: boolean; /** * The primary value to display (or the "numerator" of a fraction). */ value?: number; } /** * BigNumber is used to display large values in a small area. The display of * values can be the value itself, or grouped in a `numerator/denominator` fashion. * Control over the total fraction decimals displayed as well as how the * values/totals are displayed are done via a locale prop. Other optional props * allow control over size, truncation, if the value is a percentage, the addition * of a button as well as tooltip functionality. * The default locale is English (`en-US`) if one is not provided or if the provided one is not supported. */ export declare const BigNumber: React.ForwardRefExoticComponent>;