Skip to content

Commit d676013

Browse files
Merge pull request #3 from Chia-Chi-Shen/dev
remove sb style in example components
2 parents 35e2501 + d6b9c05 commit d676013

File tree

24 files changed

+35
-52
lines changed

24 files changed

+35
-52
lines changed

src/Storybook.css

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,9 @@
22
width: 700px;
33
height: 300px;
44
}
5-
6-
.atlas-map .azure-map-copyright a {
7-
font-size: 9px;
5+
@media screen and (max-width: 700px) {
6+
.defaultMap {
7+
width: 90vw;
8+
height: 200px;
9+
}
810
}

src/stories/BasicUsage/MapControls/MapControl.mdx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ These examples show all the map navigation controls on the map and how to custom
99

1010
## Style control
1111

12+
1213
<MapControl controls={[controls[0]]}/>
1314
<Source code={`
1415
import {

src/stories/BasicUsage/MapControls/MapControl.tsx

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,6 @@
1-
import React from 'react';
2-
import {
3-
IAzureMapControls,
4-
ControlOptions,
5-
IAzureMapOptions,
6-
AzureMapsProvider,
7-
AzureMap,
8-
useAzureMaps,
9-
} from 'react-azure-maps';
1+
import { IAzureMapControls, ControlOptions } from 'react-azure-maps';
102
import DefaultMap from '../../DefaultMap/DefaultMap';
11-
import atlas, { ControlPosition } from 'azure-maps-control';
123
import { mapOptions } from '../../../key';
13-
import { useEffect, useState } from 'react';
144

155
export interface ControlProps {
166
controls: IAzureMapControls[];

src/stories/BasicUsage/MapRef/MapRef.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { Canvas, Meta, Source } from '@storybook/blocks';
1+
import { Meta, Source } from '@storybook/blocks';
22
import { AzureMapsProvider } from 'react-azure-maps';
33
import SetStyle from './SetStyle';
44
import SetCenter from './SetCenter';

src/stories/BasicUsage/MapRef/SetCenter.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ const SetCenter = () => {
1818
<button style={{ color: 'dodgerblue', marginBottom: '10px' }} onClick={() => setMapCenter(getRandomPosition())}>
1919
Change Map Center
2020
</button>
21-
<div className="defaultMap">
21+
<div className="defaultMap sb-unstyled">
2222
<AzureMap options={mapOptions} />
2323
</div>
2424
</>

src/stories/BasicUsage/MapRef/SetStyle.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ const SetStyle = () => {
2525
>
2626
Toggle Tile Boundaries
2727
</button>
28-
<div className="defaultMap">
28+
<div className="defaultMap sb-unstyled">
2929
<AzureMap options={mapOptions} />
3030
</div>
3131
</>

src/stories/BasicUsage/MapStyles/MapStyles.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { Meta, Source } from '@storybook/blocks';
1+
import { Source, Meta } from '@storybook/blocks';
22

33
<Meta title="Basic Usage/Map Styles"/>
44

src/stories/BasicUsage/MapStyles/MapStyles.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ export interface MapStylesProps {
1010

1111
const MapStyles = ({ showLabels, showLogo, renderWorldCopies, showFeedbackLink }: MapStylesProps) => {
1212
return (
13-
<div className="defaultMap">
13+
<div className="defaultMap sb-unstyled">
1414
<AzureMapsProvider>
1515
<AzureMap
1616
options={mapOptions}

src/stories/DataVisualization/BubbleLayer/BubbleLayer.mdx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { Canvas, Meta, Source } from '@storybook/blocks';
1+
import { Meta, Source } from '@storybook/blocks';
22

33
import * as BubbleLayerStories from './BubbleLayer.stories';
44

@@ -14,8 +14,6 @@ For more available properties, see the documentation [BubbleLayerOptions](https:
1414

1515
<BubbleLayer/>
1616

17-
{/* <Canvas of={BubbleLayerStories.Example} sourceState="none" /> */}
18-
1917
<Source code={`
2018
<AzureMapLayerProvider
2119
type="BubbleLayer"

src/stories/DataVisualization/BubbleLayer/BubbleLayer.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ const collection = generateRandomPoints();
88
const BubbleLayer = ({ radius, color, opacity, strokeColor, strokeWidth, strokeOpacity, blur }: BubbleLayerOptions) => {
99
return (
1010
<AzureMapsProvider>
11-
<div className="defaultMap">
11+
<div className="defaultMap sb-unstyled">
1212
<AzureMap options={mapOptions}>
1313
<AzureMapDataSourceProvider id="BubbleLayer DataSourceProvider" collection={collection}>
1414
<AzureMapLayerProvider

0 commit comments

Comments
 (0)