@fortawesome/free-solid-svg-icons APIs
- faTimes
- faCheck
- faTrash
- faCog
- faInfoCircle
- faPlus
- faSearch
- faSpinner
- faArrowLeft
- faCopy
- faChevronDown
- faExclamationTriangle
- faUser
- faEdit
- faBars
- faHome
- faCheckCircle
- faExclamationCircle
- faQuestionCircle
- faPlay
- faTrashAlt
- faArrowRight
- faChevronRight
- faChevronUp
- fas
- faEye
- faSignOutAlt
- faLink
- faPen
- faSync
- faEyeSlash
- faStar
- faChevronLeft
- faLock
- faDownload
- faCaretDown
- faClock
- IconDefinition
- faEllipsisV
- faHeart
- faCode
- faAngleDown
- faTimesCircle
- faGlobe
- faFilter
- faSave
- faBell
- faList
- faSortDown
- faSortUp
- faUsers
- faArrowDown
- faArrowUp
- faPause
- faUndo
- faMoon
- faWindowMaximize
- faSyncAlt
- faExternalLinkAlt
- faAngleUp
- faAngleLeft
- faUpload
- faClipboard
- faBook
- faComments
- faSquare
- faCheckDouble
- faPlusCircle
- faComment
- faRandom
- faStop
- faFolderPlus
- faCamera
- faBan
- faEnvelope
- faGavel
- faPalette
- faPlane
- faTasks
- faPencilAlt
- faExchangeAlt
- faMapMarkerAlt
- faAngleRight
- faSun
- faMicrophone
- faMicrophoneSlash
- faVideo
- faVideoSlash
- faFile
- faLanguage
- faCogs
- faUserEdit
- faUserPlus
- faMinus
- faFolderOpen
- faCircleNotch
- faUserAlt
- faCodeBranch
- faCube
- faLaptopCode
- faMap
- faChartArea
- faHistory
- faShare
- faCloudDownloadAlt
- faFileUpload
- faCalendarAlt
- faLightbulb
- faPaperPlane
- faPaintBrush
- faExclamation
- faAnchor
- faBomb
- faMusic
- faCompress
- faExpand
- faRegistered
- faWifi
- faDrawPolygon
- faPhone
- faCommentDots
- faVolumeUp
- faCaretUp
- faBug
- faUserCircle
- faWallet
- faFileContract
- faTag
- faSearchPlus
- faSort
- faKey
- faVolumeMute
- faPowerOff
- faBolt
- faRedoAlt
- faSortAmountDown
- faCloudUploadAlt
- faShapes
- faSortAmountUp
- faTools
- faFileCode
- faRedo
- faAlignLeft
- faUserFriends
- faBookOpen
- faChartBar
- faFileExport
- faFileImport
- faSadCry
- faRocket
- faLinkSlash
- faTh
- faLongArrowAltRight
- faTags
- faDog
- faTv
- faCartPlus
- faMicrochip
- faNetworkWired
- faCommentSlash
- faAddressBook
- faCalendar
- faToggleOff
- faToggleOn
- faUserClock
- faHourglass
- faQuestion
- faStamp
- faAddressCard
- faPoo
- faAppleAlt
- faBible
- faBone
- faCar
- faCat
- faChess
- faSkull
- faFeatherAlt
- faFire
- faWindowMinimize
- faReplyAll
- faSignInAlt
- faBold
- faItalic
- faUnderline
- faHeading
- faQuoteRight
- faListOl
- faListUl
- faLevelDownAlt
- faLevelUpAlt
- faUndoAlt
- faPlug
- faBullhorn
- faPlaneDeparture
- faSimCard
- faBrush
- faAngleDoubleDown
- faCoins
- faCompressArrowsAlt
- faDiceD6
- faNewspaper
- faMinimize
- faUpRightFromSquare
- faCubes
- faRetweet
- faHandPeace
- faSpaceShuttle
- faXmark
- faFileAudio
- faStopwatch
- faDragon
- faSortNumericDown
- faSortNumericDownAlt
- faArrowUpRightFromSquare
- faArrowDown19
- faArrowDown91
- faHashtag
- faRepeat
- faLaptop
- faCloud
- faPiggyBank
- faRunning
- faBiking
- faBicycle
- faShareAlt
- faRuler
- faVial
- faUserTimes
- faUserMinus
- faCalendarDay
- faStepBackward
- faStepForward
- faDotCircle
- faUserLock
- faUserCog
- faTrophy
- faShareSquare
- faHandPointRight
- faChartLine
- faUserShield
- faCheckSquare
- faSortAmountDownAlt
- faIdCard
- faUserSlash
- faCalculator
- faEllipsisH
- faRulerCombined
- faSoap
- faMousePointer
- faHandRock
- faDroplet
- faThumbtack
- faReply
- faLayerGroup
- faMask
- faWindowRestore
- faThLarge
- faDesktop
- faInfo
- faHandsHelping
- faKeyboard
- faChartPie
- faColumns
- faTable
- faTachometerAlt
- faClipboardList
- faHammer
- faLockOpen
- faCity
- faChessRook
- faMountain
- faCampground
- faUniversity
- faCrosshairs
- faWrench
- faArrowCircleLeft
- faIdCardAlt
- faCreditCard
- faDollarSign
- faIdBadge
- faSlidersH
- faEuroSign
- faPoundSign
- faSearchDollar
- faPlayCircle
- faStream
- faFilm
- faSmile
- faPhoneAlt
- faArrowsAltV
- faUserAltSlash
- faLongArrowAltLeft
- faHdd
- faUnlink
- faInbox
- faMagic
- faImage
- faCalendarCheck
- faUserCheck
- faFolder
- faThermometerEmpty
- faCut
- faPaste
- faCircle
- faMobile
- faClipboardCheck
- faSortAlphaUp
- faSortAlphaDown
- faRss
- faPaw
Other Related APIs
@fortawesome/free-solid-svg-icons#faDesktop TypeScript Examples
The following examples show how to use
@fortawesome/free-solid-svg-icons#faDesktop.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: ControlsView.tsx From livekit-react with Apache License 2.0 | 4 votes |
ControlsView = ({
room,
enableScreenShare,
enableAudio,
enableVideo,
onLeave,
}: ControlsProps) => {
const { cameraPublication: camPub, microphonePublication: micPub } = useParticipant(
room.localParticipant,
);
if (enableScreenShare === undefined) {
enableScreenShare = true;
}
if (enableVideo === undefined) {
enableVideo = true;
}
if (enableAudio === undefined) {
enableAudio = true;
}
const [audioButtonDisabled, setAudioButtonDisabled] = React.useState(false);
let muteButton: ReactElement | undefined;
if (enableAudio) {
const enabled = !(micPub?.isMuted ?? true);
muteButton = (
<AudioSelectButton
isMuted={!enabled}
isButtonDisabled={audioButtonDisabled}
onClick={async () => {
setAudioButtonDisabled(true);
room.localParticipant
.setMicrophoneEnabled(!enabled)
.finally(() => setAudioButtonDisabled(false));
}}
onSourceSelected={(device) => {
setAudioButtonDisabled(true);
room
.switchActiveDevice('audioinput', device.deviceId)
.finally(() => setAudioButtonDisabled(false));
}}
/>
);
}
const [videoButtonDisabled, setVideoButtonDisabled] = React.useState(false);
let videoButton: ReactElement | undefined;
if (enableVideo) {
const enabled = !(camPub?.isMuted ?? true);
videoButton = (
<VideoSelectButton
isEnabled={enabled}
isButtonDisabled={videoButtonDisabled}
onClick={() => {
setVideoButtonDisabled(true);
room.localParticipant
.setCameraEnabled(!enabled)
.finally(() => setVideoButtonDisabled(false));
}}
onSourceSelected={(device) => {
setVideoButtonDisabled(true);
room
.switchActiveDevice('videoinput', device.deviceId)
.finally(() => setVideoButtonDisabled(false));
}}
/>
);
}
const [screenButtonDisabled, setScreenButtonDisabled] = React.useState(false);
let screenButton: ReactElement | undefined;
if (enableScreenShare) {
const enabled = room.localParticipant.isScreenShareEnabled;
screenButton = (
<ControlButton
label={enabled ? 'Stop sharing' : 'Share screen'}
icon={enabled ? faStop : faDesktop}
disabled={screenButtonDisabled}
onClick={() => {
setScreenButtonDisabled(true);
room.localParticipant
.setScreenShareEnabled(!enabled)
.finally(() => setScreenButtonDisabled(false));
}}
/>
);
}
return (
<div className={styles.controlsWrapper}>
{muteButton}
{videoButton}
{screenButton}
{onLeave && (
<ControlButton
label="End"
className={styles.dangerButton}
onClick={() => {
room.disconnect();
onLeave(room);
}}
/>
)}
</div>
);
}