Skip to content

Commit 08c3633

Browse files
committed
fix: update example import method
1 parent b10f364 commit 08c3633

File tree

4 files changed

+11
-8
lines changed

4 files changed

+11
-8
lines changed

src/side-bar/_example/base.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import React, { useState, useEffect, useRef, useCallback } from 'react';
2-
import { Grid, GridItem } from '../../grid';
3-
import { SideBarProps, SideBarItemProps, SideBar, SideBarItem } from '..';
2+
import { Grid, GridItem, SideBar, SideBarItem } from 'tdesign-mobile-react';
3+
import type { SideBarProps, SideBarItemProps } from 'tdesign-mobile-react';
44
import './style/base.less';
55

66
const image = 'https://tdesign.gtimg.com/mobile/demos/example2.png';

src/side-bar/_example/custom.tsx

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import React, { useState, useEffect, useRef, useCallback } from 'react';
2-
import { Grid, GridItem } from '../../grid';
3-
import { SideBarProps, SideBarItemProps, SideBar, SideBarItem } from '..';
2+
import type { SideBarProps, SideBarItemProps } from 'tdesign-mobile-react';
3+
import { SideBar, SideBarItem, Grid, GridItem } from 'tdesign-mobile-react';
4+
45
import './style/custom.less';
56

67
const image = 'https://tdesign.gtimg.com/mobile/demos/example2.png';

src/side-bar/_example/switch.tsx

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import React, { useState, useRef } from 'react';
2-
import { Cell, Image } from 'tdesign-mobile-react';
3-
import { SideBarProps, SideBarItemProps, SideBar, SideBarItem } from '..';
2+
import type { SideBarProps, SideBarItemProps } from 'tdesign-mobile-react';
3+
import { SideBar, SideBarItem, Cell, Image } from 'tdesign-mobile-react';
4+
45
import './style/switch.less';
56

67
const image = 'https://tdesign.gtimg.com/mobile/demos/example2.png';

src/side-bar/_example/with-icon.tsx

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
import React, { useState, useEffect, useRef, useCallback } from 'react';
22
import { Icon } from 'tdesign-icons-react';
3-
import { Grid, GridItem } from '../../grid';
4-
import { SideBarProps, SideBarItemProps, SideBar, SideBarItem } from '..';
3+
import type { SideBarProps, SideBarItemProps } from 'tdesign-mobile-react';
4+
import { SideBar, SideBarItem, Grid, GridItem } from 'tdesign-mobile-react';
5+
56
import './style/base.less';
67

78
const image = 'https://tdesign.gtimg.com/mobile/demos/example2.png';

0 commit comments

Comments
 (0)