@mui/icons-material APIs
- Close
- Add
- Delete
- ExpandMore
- Settings
- Check
- Update
- GitHub
- MoreVert
- HelpOutline
- ChevronRight
- ExpandLess
- Menu
- FileCopy
- CheckBox
- CheckBoxOutlineBlank
- ArrowBack
- DeleteForever
- Visibility
- VisibilityOff
- Save
- Person
- Edit
- People
- ChevronLeft
- PlayArrow
- Home
- ExitToApp
- MoreHoriz
- WbSunny
- Download
- Upload
- Search
- HighlightOffOutlined
- ContentCopy
- Calculate
- ShoppingCart
- AccountBalance
- BarChart
- Paid
- Clear
- Cancel
- ArrowDownward
- ArrowUpward
- PhotoCamera
- Folder
- InfoOutlined
- Code
- KeyboardArrowDown
- Lock
- LockOpen
- Replay
- Favorite
- Build
- Refresh
- AssignmentInd
- Pets
- Public
- Group
- Brush
- KeyboardTab
- Phone
- HelpOutlineOutlined
- NetworkWifi
- CompareArrows
- AdminPanelSettings
- BugReport
- Logout
- Message
- AddCircle
- LockOutlined
- HomeOutlined
- BarChartOutlined
- MusicNote
- MusicNoteOutlined
- Album
- AlbumOutlined
- PersonOutlined
- SettingsOutlined
- Share
- ShareOutlined
- FastRewind
- Help
- Loop
- VolumeDown
- VolumeUp
- PauseCircle
- PlayCircle
- VolumeOff
- ChatBubbleOutline
- LockRounded
- WifiOffRounded
- VideocamOutlined
- AddRounded
- MoreVertRounded
- SyncProblem
- VideoCallOutlined
- GetAppRounded
- SaveAlt
- ErrorRounded
- InsertDriveFileRounded
- CheckCircleOutline
- CloudOff
- ClearAll
- CloseOutlined
- Link
- AttachmentOutlined
- CodeOutlined
- MailOutlineRounded
- Brightness7Rounded
- MenuRounded
- NightsStayRounded
- ArrowForward
- BrushRounded
- VisibilityRounded
- FileCopyRounded
- FavoriteRounded
- DesktopMacRounded
- PhoneAndroidRounded
- TabletMac
- ThumbUpOutlined
- ThumbDownOutlined
- AssistantPhotoOutlined
- Publish
- Create
- WbCloudy
- Computer
- KeyboardArrowUp
- BusinessCenter
- FavoriteBorder
- Groups
- Shuffle
- Difference
- SwapHoriz
- Info
- KeyboardDoubleArrowDown
- KeyboardDoubleArrowUp
- PersonAdd
- Checkroom
- FactCheck
- ArrowRightAlt
- Scanner
- Brightness4
- Brightness7
- Translate
- Backpack
- SettingsBrightness
- Equalizer
- Handyman
- SentimentVerySatisfied
- SentimentDissatisfied
- SentimentSatisfied
- AccessTime
- Remove
- ArrowDropDown
- ArrowRight
- Undo
- Redo
- CreateNewFolder
- Description
- Outbox
- Inbox
- DriveFileRenameOutline
- ContentPaste
- Block
- Star
- StarBorder
- Security
- Today
- Event
- Login
- Sick
- FaceRetouchingOff
- Fireplace
- ErrorOutline
- Stop
- ViewList
- Send
- PlayCircleFilledWhite
- PlaylistAddCheck
- Telegram
- VerifiedUser
- Notifications
- MenuOpen
- GppGood
- ContactPhone
- Payment
- FolderShared
- Class
- Shield
- MoveUp
- VolunteerActivism
- DisplaySettings
- Apartment
- BusAlert
- Category
- FilterNone
- Forest
- MedicalServices
- School
- SportsTennis
- TheaterComedy
- ReportGmailerrorred
- ArrowCircleUp
- UploadFile
- YouTube
- Web
- AccountCircle
- AccessibilityNew
- Chat
- FolderOpen
- FileCopyOutlined
- KeyboardBackspace
- CheckCircleOutlined
- ReportProblemOutlined
- ManageAccounts
- PhotoLibrary
- SettingsBackupRestore
- SupervisorAccount
- Api
- FeaturedPlayList
- BugReportOutlined
- NewReleases
- ColorLens
- FolderOutlined
- Apps
- SpeakerNotes
- LocalCafe
- BurstModeSharp
- DevicesOther
- VideoLibrary
- AddOutlined
- DeleteOutlineOutlined
- EditOutlined
- MoreHorizOutlined
- Bookmarks
- CopyAll
- InsertComment
- KeyboardArrowRight
- FileDownload
- Done
- PendingOutlined
- HelpOutlineRounded
- ReportProblem
- HelpOutlined
Other Related APIs
@mui/icons-material#AddOutlined TypeScript Examples
The following examples show how to use
@mui/icons-material#AddOutlined.
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: siteCard.tsx From Search-Next with GNU General Public License v3.0 | 4 votes |
SiteCard: React.FC<SiteCardPropTypes> = ({
type = 'view',
item,
onClick,
onAdd,
onEdit,
onRemove,
}) => {
const [anchorEl, setAnchorEl] = React.useState<null | HTMLElement>(null);
const onMenuOpen = (event: React.MouseEvent<HTMLButtonElement>) => {
event.stopPropagation();
setAnchorEl(event.currentTarget);
};
const onMenuClose = (event: React.MouseEvent<HTMLButtonElement>) => {
event.stopPropagation();
setAnchorEl(null);
};
const siteClick = () => {
if (onClick) onClick();
};
const handleEdit = () => {
setAnchorEl(null);
if (onEdit && item) onEdit(item);
};
const handleRemove = () => {
setAnchorEl(null);
if (onRemove && item) onRemove(item._id);
};
return (
<>
<div
className={classNames(
'cursor-pointer bg-transparent rounded shadow-none relative w-28 h-20 transition-all hover:bg-rgba-gray-3',
css`
&:hover {
.handle-container {
opacity: 1 !important;
}
}
`,
)}
onClick={onClick}
>
<div
className={classNames([
'content-container transition-all box-border flex flex-col items-center w-full h-full px-3 py-2 rounded',
type === 'add' ? 'justify-start text-primary' : 'justify-end',
])}
>
<Avatar
className={classNames(
'bg-white rounded mx-auto',
{
'text-primary': type === 'add',
},
css`
img {
max-width: 24px;
height: 24px;
}
`,
)}
variant="rounded"
src={item?.iconUrl ? item?.iconUrl : getWebIconByUrl(item?.url)}
onClick={onAdd ? onAdd : undefined}
>
{type === 'add' && <AddOutlined />}
</Avatar>
<p className="text-center flex justify-center mt-1 w-full text-var-main-10">
<a className="overflow-hidden text-ellipsis">{item?.name}</a>
</p>
</div>
{type === 'view' && (
<span className="handle-container w-6 h-6 flex justify-center absolute top-1 right-1 z-10 opacity-0 transition-all">
<IconButton
className="rounded"
size="small"
aria-controls={`site-${item?.name}-menu`}
aria-haspopup="true"
onClick={onMenuOpen}
>
<MoreHorizOutlined className="text-var-main-10" />
</IconButton>
</span>
)}
</div>
<Menu
id={`site-${item?.name}-menu`}
open={Boolean(anchorEl)}
anchorEl={anchorEl}
onClose={onMenuClose}
config={[
{
label: '修改',
onClick: handleEdit,
icon: EditOutlined,
},
{
label: '删除',
onClick: handleRemove,
icon: DeleteOutlineOutlined,
},
]}
/>
</>
);
}