diff --git a/stylesheets/components/StoriesSettingsModal.scss b/stylesheets/components/StoriesSettingsModal.scss index a2f7448e9..59e5fc82d 100644 --- a/stylesheets/components/StoriesSettingsModal.scss +++ b/stylesheets/components/StoriesSettingsModal.scss @@ -203,28 +203,9 @@ &__tags { margin: 0 -4px; - } - &__tag { - align-items: center; - background: $color-gray-75; - border-radius: 26px; - color: $color-gray-05; - display: inline-flex; - padding: 4px 0; - margin: 0 4px; - - &__name { - margin-left: 4px; - } - - &__remove { - @include button-reset; - @include color-svg('../images/icons/v2/x-24.svg', $color-gray-15); - height: 12px; - margin: 0 8px; - width: 12px; - } + // Override .module-ContactPills + padding: 0; } &__name-story-avatar-container { diff --git a/ts/components/ContactPills.tsx b/ts/components/ContactPills.tsx index 08ea6eb76..6d0da62b9 100644 --- a/ts/components/ContactPills.tsx +++ b/ts/components/ContactPills.tsx @@ -3,15 +3,20 @@ import type { FunctionComponent, ReactNode } from 'react'; import React, { useRef, useEffect, Children } from 'react'; +import classNames from 'classnames'; import { usePrevious } from '../hooks/usePrevious'; import { scrollToBottom } from '../util/scrollUtil'; type PropsType = { + moduleClassName?: string; children?: ReactNode; }; -export const ContactPills: FunctionComponent = ({ children }) => { +export const ContactPills: FunctionComponent = ({ + moduleClassName, + children, +}) => { const elRef = useRef(null); const childCount = Children.count(children); @@ -26,7 +31,10 @@ export const ContactPills: FunctionComponent = ({ children }) => { }, [childCount, previousChildCount]); return ( -
+
{children}
); diff --git a/ts/components/StoriesSettingsModal.tsx b/ts/components/StoriesSettingsModal.tsx index 1074e567c..6a5611c83 100644 --- a/ts/components/StoriesSettingsModal.tsx +++ b/ts/components/StoriesSettingsModal.tsx @@ -16,6 +16,8 @@ import { Avatar, AvatarSize } from './Avatar'; import { Button, ButtonVariant } from './Button'; import { Checkbox } from './Checkbox'; import { ConfirmationDialog } from './ConfirmationDialog'; +import { ContactPills } from './ContactPills'; +import { ContactPill } from './ContactPill'; import { ConversationList, RowType } from './ConversationList'; import { Input } from './Input'; import { Intl } from './Intl'; @@ -807,38 +809,26 @@ export const EditDistributionList = ({ value={searchTerm} /> {selectedContacts.length ? ( -
+ {selectedContacts.map(contact => ( -
- - - {contact.firstName || - contact.profileName || - contact.phoneNumber} - -
+ toggleSelectedConversation(contact.id)} + /> ))} -
+ ) : undefined} {candidateConversations.length ? (