Skip to content

Commit

Permalink
chore: 移除无用示例
Browse files Browse the repository at this point in the history
  • Loading branch information
wangxingkang committed Nov 23, 2023
1 parent 94a9bb4 commit db695fe
Show file tree
Hide file tree
Showing 10 changed files with 7 additions and 119 deletions.
2 changes: 1 addition & 1 deletion packages/amap/src/marker-cluster/index.ts
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
export { MarkerCluster } from './marker-cluster';
export { default as MarkerCluster } from './marker-cluster';
export type { MarkerClusterProps } from './types';
2 changes: 2 additions & 0 deletions packages/amap/src/marker-cluster/marker-cluster.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -108,3 +108,5 @@ const MarkerCluster = forwardRef(InternalCluster) as RefInternalCluster & {
MarkerCluster.defaultProps = {
zoomOnClick: true
}

export default MarkerCluster;
17 changes: 0 additions & 17 deletions packages/amap/src/marker/demo/demo-06/Business.tsx

This file was deleted.

4 changes: 0 additions & 4 deletions packages/amap/src/marker/demo/demo-06/Marker/index.less

This file was deleted.

18 changes: 0 additions & 18 deletions packages/amap/src/marker/demo/demo-06/Marker/index.tsx

This file was deleted.

19 changes: 0 additions & 19 deletions packages/amap/src/marker/demo/demo-06/index.tsx

This file was deleted.

34 changes: 0 additions & 34 deletions packages/amap/src/marker/demo/demo-06/useMapService.ts

This file was deleted.

19 changes: 0 additions & 19 deletions packages/amap/src/marker/demo/demo-06/utils.ts

This file was deleted.

4 changes: 0 additions & 4 deletions packages/amap/src/marker/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,6 @@ group:

<code src="./demo/demo-07.tsx"></code>

### 案例1

<code src="./demo/demo-06/index.tsx"></code>

## API

### 动态属性
Expand Down
7 changes: 4 additions & 3 deletions packages/amap/src/marker/marker.tsx
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
import React, { useRef, useEffect, useImperativeHandle } from 'react';
import React, { forwardRef, useRef, useEffect, useImperativeHandle } from 'react';
import { usePortal } from '@pansy/use-portal';
import { useMap } from '../map';
import { usePropsReactive, isFun } from '../utils';
import type { MarkerProps } from './types';
import { buildCreateOptions } from '../utils/control';
import { allProps, setterMap, converterMap } from './config';

export const Marker = React.forwardRef<AMap.Marker, React.PropsWithChildren<MarkerProps>>((props = {}, ref) => {
import type { MarkerProps } from './types';

export const Marker = forwardRef<AMap.Marker, React.PropsWithChildren<MarkerProps>>((props = {}, ref) => {
const { map, AMap } = useMap();
const { container, Portal } = usePortal();
const instanceObj = useRef<AMap.Marker>(null);
Expand Down

0 comments on commit db695fe

Please sign in to comment.