[MM-58326] Remove aria-disabled for disabled tooltip in calls button following WithTooltip integration (#27094)
Этот коммит содержится в:
коммит произвёл
GitHub
родитель
f4a3a2ec07
Коммит
f0601b67e8
@@ -223,12 +223,5 @@
|
||||
row-gap: 4px;
|
||||
}
|
||||
}
|
||||
|
||||
button#startCallButton {
|
||||
&.icon-btn-disabled {
|
||||
cursor: not-allowed;
|
||||
opacity: 0.65;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -315,7 +315,7 @@ describe('components/ProfilePopover', () => {
|
||||
|
||||
renderWithPluginReducers(<ProfilePopover {...props}/>, initialState);
|
||||
const button = (await screen.findByLabelText('Call with user is ongoing')).closest('button');
|
||||
expect(button?.getAttribute('aria-disabled')).toBe('true');
|
||||
expect(button).toBeDisabled();
|
||||
});
|
||||
|
||||
test('should not show the start call button when callsChannelState.enabled is false', async () => {
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
|
||||
// See LICENSE.txt for license information.
|
||||
|
||||
import classNames from 'classnames';
|
||||
import React, {useCallback, useEffect, useState} from 'react';
|
||||
import {useIntl} from 'react-intl';
|
||||
import {useSelector} from 'react-redux';
|
||||
@@ -95,7 +94,6 @@ const CallButton = ({
|
||||
id: 'webapp.mattermost.feature.start_call',
|
||||
defaultMessage: 'Start Call',
|
||||
});
|
||||
const iconButtonClassName = classNames('btn btn-icon btn-sm style--none', {'icon-btn-disabled': disabled});
|
||||
const callButton = (
|
||||
<WithTooltip
|
||||
id='startCallTooltip'
|
||||
@@ -105,8 +103,8 @@ const CallButton = ({
|
||||
<button
|
||||
id='startCallButton'
|
||||
type='button'
|
||||
aria-disabled={disabled}
|
||||
className={iconButtonClassName}
|
||||
disabled={disabled}
|
||||
className='btn btn-icon btn-sm style--none'
|
||||
aria-label={startCallMessage}
|
||||
>
|
||||
<span
|
||||
|
||||
Ссылка в новой задаче
Block a user