#
vincentlu
2025-12-17 f02bb4f8cf6061851ec7c2c411629a8ae36e06b4
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
import React from "react";
import { useTranslate } from "react-admin";
import { Fab } from '@mui/material';
import CropFreeIcon from '@mui/icons-material/CropFree';
 
const AreaFab = ({ active = false, onToggle }) => {
    const translate = useTranslate();
 
    return (
        <Fab
            variant="extended"
            color={active ? 'primary' : 'default'}
            size="small"
            onClick={onToggle}
        >
            <CropFreeIcon />
            &nbsp;{translate('page.map.devices.area')}&nbsp;
        </Fab>
    );
};
 
export default AreaFab;