-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
c8202c9
commit 45305b3
Showing
5 changed files
with
21 additions
and
27 deletions.
There are no files selected for viewing
16 changes: 5 additions & 11 deletions
16
src/OnboardingSPA/components/RadioControl/RadioControlSkeleton/index.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,14 @@ | ||
/** | ||
* Renders Skeletons for Radio Control. | ||
* | ||
* @param {number} data The options to be renedered | ||
* @param {number} options The options to be renedered | ||
* | ||
*/ | ||
const RadioControlSkeleton = ({ data }) => { | ||
const buildDummyRadioControls = () => { | ||
const customItems = []; | ||
const RadioControlSkeleton = ({ options }) => { | ||
|
||
for (let idx = 0; idx < data.length; idx++) | ||
customItems.push(<div className="radio-control-skeleton-item" />); | ||
|
||
return <div className="radio-control-skeleton">{customItems}</div>; | ||
}; | ||
|
||
return buildDummyRadioControls(); | ||
return <div className="radio-control-skeleton"> | ||
{options.map((option) => (<div className="radio-control-skeleton-item" />))} | ||
</div>; | ||
}; | ||
|
||
export default RadioControlSkeleton; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,2 @@ | ||
export { default as RadioCtrlSkeleton } from './RadioControlSkeleton'; | ||
export { default as RadioCtrlStateHandler } from './RadioControlState'; | ||
export { default as RadioControlSkeleton } from './RadioControlSkeleton'; | ||
export { default as RadioControlStateHandler } from './RadioControlStateHandler'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters