Module ActivityIndicator-BsReactNative

let make: ?⁠animating:bool => ?⁠color:BsReactNative.Style.color => ?⁠size:[ `large | `small | `exact(int) ] => ?⁠hidesWhenStopped:bool => ?⁠accessibilityLabel:ReasonReact.reactElement => ?⁠accessible:bool => ?⁠hitSlop:BsReactNative.Types.insets => ?⁠onAccessibilityTap:(unit => unit) => ?⁠onLayout:(BsReactNative.RNEvent.NativeLayoutEvent.t => unit) => ?⁠onMagicTap:(unit => unit) => ?⁠responderHandlers:BsReactNative.Types.touchResponderHandlers => ?⁠pointerEvents:BsReactNative.Types.pointerEvents => ?⁠removeClippedSubviews:bool => ?⁠style:BsReactNative.Style.t => ?⁠testID:string => ?⁠accessibilityComponentType:BsReactNative.Types.accessibilityComponentType => ?⁠accessibilityLiveRegion:BsReactNative.Types.accessibilityLiveRegion => ?⁠collapsable:bool => ?⁠importantForAccessibility:BsReactNative.Types.importantForAccessibility => ?⁠needsOffscreenAlphaCompositing:bool => ?⁠renderToHardwareTextureAndroid:bool => ?⁠accessibilityTraits:list(BsReactNative.Types.accessibilityTrait) => ?⁠accessibilityRole:BsReactNative.Types.accessibilityRole => ?⁠accessibilityStates:list(BsReactNative.Types.accessibilityState) => ?⁠accessibilityHint:string => ?⁠accessibilityIgnoresInvertColors:bool => ?⁠accessibilityViewIsModal:bool => ?⁠shouldRasterizeIOS:bool => array(ReasonReact.reactElement) => ReasonReact.component(ReasonReact.stateless, ReasonReact.noRetainedProps, unit);

Displays a circular loading indicator. Check React Native docs for details.

Example

let component = ReasonReact.statelessComponent("MyComponent");

let make = _children => {
  ...component,
  render: _self => <ActivityIndicator />,
};

To render a default ActivityIndicator (spinner) you don't need to pass any props:

Props

All View props are accepted.

animating

~animating: bool=?

color

Changes the color of the indicator. Can be either a named color "tomato", hex "#ff0ff" or an rgb "rgb(255, 34, 11)".

~color: Style.color=?

size

In order to change the size of the indicator pass one of the polymorphic variants:

~size: [ | `large | `small | `exact(int)]=?

Note: exact is only supported on Android. On iOS, it defaults to `small.