Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -297,6 +297,7 @@ These are UI components; the non-happy-path states are part of the contract.
- **StationLogin:** login screen vs. profile mode; device-type select drives dial-number input visibility; Desktop option hidden when `hideDesktopLogin`; multiple-login alert when `showMultipleLoginAlert`; error states from `loginFailure`/`saveError`; Save/Continue disabled until valid. (`src/components/StationLogin/station-login.tsx`)
- **UserState:** dropdown of idle/custom states with current state highlighted; `isSettingAgentStatus` shows a busy/disabled state; error-triggering idle codes styled distinctly; state timer renders via `formatTime`. (`src/components/UserState/user-state.tsx`)
- **CallControl / CallControlCAD:** button visibility/enablement driven by `controlVisibility`; consult/transfer popover with Agents/Queues/Dial Number/Entry Point tabs (empty-state when no results, loading spinner while fetching); auto-wrapup countdown bar; wrapup requires reason selection before submit. (`src/components/task/CallControl/`, `src/components/task/CallControlCAD/`)
- **CallControl DTMF keypad:** circular digit buttons and a reserved spinner slot inside the input keep the input, keypad, and popover width stable while tones are being sent. (`src/components/task/CallControl/call-control-dtmf-keypad.tsx`, `src/components/task/CallControl/call-control.styles.scss`)
- **IncomingTask / TaskList:** hidden (renders `<></>`) when no incoming task / empty list; per-media-type icon and label; campaign preview rows swap UI. (`src/components/task/IncomingTask/`, `src/components/task/TaskList/`)
- **OutdialCall:** dialpad / contacts tabs; invalid-number state disables dial; address-book loading spinner and infinite scroll; disabled while a telephony task is active. (`src/components/task/OutdialCall/outdial-call.tsx`)
- **RealTimeTranscript:** empty-state message ("No live transcript available.") when no entries; entries sorted chronologically; event vs. message rendering. (`src/components/task/RealTimeTranscript/real-time-transcript.tsx`)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -89,10 +89,11 @@ const CallControlDtmfKeypad: React.FunctionComponent<CallControlDtmfKeypadProps>
onKeyDown={handleKeyDown}
aria-label={DTMF_KEYPAD_PLACEHOLDER}
disabled={disabled}
/>
{pendingCount > 0 && (
<Spinner className="call-control-dtmf-spinner" size="small" data-testid="call-control-keypad-spinner" />
)}
>
<div slot="trailing-button" className="call-control-dtmf-spinner-slot">
{pendingCount > 0 && <Spinner size="small" data-testid="call-control-keypad-spinner" />}
</div>
</Input>
</div>
<ul className="call-control-dtmf-keys" data-testid="call-control-keypad-keys">
{DIALPAD_BUTTONS.map(({val, label}) => (
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
display: flex;
flex-direction: column;
gap: 0.5rem;
min-width: 12rem;
width: 12rem;
}

.call-control-dtmf-input-wrapper {
Expand All @@ -43,10 +43,19 @@

.call-control-dtmf-input {
flex: 1;
min-width: 0;

&::part(input-section) {
min-width: 0;
}
}

.call-control-dtmf-spinner {
flex-shrink: 0;
.call-control-dtmf-spinner-slot {
display: flex;
align-items: center;
flex: 0 0 1.5rem;
width: 1.5rem;
height: 1.5rem;
}

.call-control-dtmf-keys {
Expand All @@ -56,12 +65,17 @@
list-style: none;
padding: 0.5rem;
margin: 0;

li {
display: flex;
justify-content: center;
}
}

.call-control-dtmf-key {
width: 100%;
aspect-ratio: 1;
min-height: 2.75rem;
width: 3rem;
height: 3rem;
box-sizing: border-box;
border-radius: 50%;
padding: 0.25rem;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -114,12 +114,17 @@ describe('CallControlDtmfKeypad', () => {
const keypad = await screen.findByTestId('call-control-keypad-keys');
fireEvent.click(within(keypad).getByText('1', {selector: '.call-control-dtmf-key-digit'}));

expect(await screen.findByTestId('call-control-keypad-spinner')).toBeInTheDocument();
const spinner = await screen.findByTestId('call-control-keypad-spinner');
const input = await screen.findByTestId('call-control-keypad-input');
const spinnerSlot = spinner.parentElement;
expect(spinnerSlot).toHaveAttribute('slot', 'trailing-button');
expect(input).toContainElement(spinnerSlot);

resolvePress?.();
await waitFor(() => {
expect(screen.queryByTestId('call-control-keypad-spinner')).not.toBeInTheDocument();
});
expect(input).toContainElement(spinnerSlot);
});

it('serializes rapid digit presses through the transmission queue', async () => {
Expand Down
Loading