feat(Map): 添加只读模式支持

master
LiuJiaNan 2026-04-13 11:44:54 +08:00
parent e8aa0495c3
commit 727d27bd69
2 changed files with 4 additions and 0 deletions

View File

@ -11,6 +11,8 @@ export interface MapProps {
area?: string;
/** 是否显示所属区域 */
showArea?: boolean;
/** 是否只查看 */
disable?: boolean;
/** 确认选择回调 */
onConfirm?: (longitude: number | string, latitude: number | string, extra: { area: string }) => void;
/** 地图类型,默认 baidu */

View File

@ -13,6 +13,7 @@ const Map = (props) => {
required = true,
area = "",
showArea = false,
disable = false,
type = "baidu",
} = props;
@ -68,6 +69,7 @@ const Map = (props) => {
area={area}
type={type}
showArea={showArea}
disable={disable}
onConfirm={handleMapConfirm}
/>
</>