mirror of
https://github.com/facebook/docusaurus.git
synced 2025-08-06 10:20:09 +02:00
chore(v2): replace classnames with clsx (#2895)
This commit is contained in:
parent
600ef7ae28
commit
afe9ff91a4
26 changed files with 76 additions and 80 deletions
|
@ -8,7 +8,7 @@
|
|||
import React, {useState, Children} from 'react';
|
||||
import useUserPreferencesContext from '@theme/hooks/useUserPreferencesContext';
|
||||
|
||||
import classnames from 'classnames';
|
||||
import clsx from 'clsx';
|
||||
|
||||
import styles from './styles.module.css';
|
||||
|
||||
|
@ -80,7 +80,7 @@ function Tabs(props) {
|
|||
<ul
|
||||
role="tablist"
|
||||
aria-orientation="horizontal"
|
||||
className={classnames('tabs', {
|
||||
className={clsx('tabs', {
|
||||
'tabs--block': block,
|
||||
})}>
|
||||
{values.map(({value, label}) => (
|
||||
|
@ -88,7 +88,7 @@ function Tabs(props) {
|
|||
role="tab"
|
||||
tabIndex="0"
|
||||
aria-selected={selectedValue === value}
|
||||
className={classnames('tabs__item', styles.tabItem, {
|
||||
className={clsx('tabs__item', styles.tabItem, {
|
||||
'tabs__item--active': selectedValue === value,
|
||||
})}
|
||||
key={value}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue