import React from 'react';
import { TextView } from '@wix/patterns-fields';
import type { CellViewProps } from '../../types';
import { CellViewLayout } from '../CellViewLayout';
import { classes } from './View.st.css.js';

export const NumberView: React.FC<CellViewProps<number | null>> = ({
  value,
}) => (
  <CellViewLayout>
    <TextView data={value != null ? value : ''} className={classes.textView} />
  </CellViewLayout>
);
