Browse Source

change component from jsx to tsx

Tatsuya Ise 2 years ago
parent
commit
253fd918ed
1 changed files with 3 additions and 4 deletions
  1. 3 4
      apps/app/src/components/LoadingSpinnerPulse.tsx

+ 3 - 4
apps/app/src/components/LoadingSpinnerPulse.jsx → apps/app/src/components/LoadingSpinnerPulse.tsx

@@ -1,10 +1,9 @@
-import React from 'react';
+import React, { type ComponentPropsWithoutRef } from 'react';
 
 
 import styles from './LoadingSpinnerPulse.module.scss';
 import styles from './LoadingSpinnerPulse.module.scss';
 
 
-export const LoadingSpinnerPulse = () => (
-  // If you want to use a large spinner icon, call this component with a larger font size (e.g. <span className="fs-3"><LoadingSpinnerPulse /></span>)
-  <div className={`align-bottom ms-1 me-1 ${styles['lds-default']}`}>
+export const LoadingSpinnerPulse = ({ className }: ComponentPropsWithoutRef<'div'>): JSX.Element => (
+  <div className={`align-bottom ms-1 me-1 ${styles['lds-default']} ${className}`}>
     <div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div>
     <div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div><div></div>
   </div>
   </div>
 );
 );