Skip to content

Commit a79a01d

Browse files
committed
@wordpress/components -> @automattic/components
1 parent 9cc1e5c commit a79a01d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

packages/components/src/tabs/stories/best-practices.mdx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ import * as TabsStories from './index.story';
1313
Tabs can be used in an uncontrolled mode, where the component manages its own state. In this mode, the `defaultTabId` prop can be used to set the initially selected tab. If this prop is not set, the first tab will be selected by default. In addition, in most cases where the currently active tab becomes disabled or otherwise unavailable, uncontrolled mode will automatically fall back to selecting the first available tab.
1414

1515
```jsx
16-
import { Tabs } from '@wordpress/components';
16+
import { Tabs } from '@automattic/components';
1717

1818
const onSelect = ( tabName ) => {
1919
console.log( 'Selecting tab', tabName );
@@ -50,7 +50,7 @@ const MyUncontrolledTabs = () => (
5050
Tabs can also be used in a controlled mode, where the parent component specifies the `selectedTabId` and the `onSelect` props to control tab selection. In this mode, the `defaultTabId` prop will be ignored if it is provided. If the `selectedTabId` is `null`, no tab is selected. In this mode, if the currently selected tab becomes disabled or otherwise unavailable, the component will _not_ fall back to another available tab, leaving the controlling component in charge of implementing the desired logic.
5151

5252
```tsx
53-
import { Tabs } from '@wordpress/components';
53+
import { Tabs } from '@automattic/components';
5454

5555
const [ selectedTabId, setSelectedTabId ] = useState<
5656
string | undefined | null

0 commit comments

Comments
 (0)