Skip to content

Commit

Permalink
feat: remove telegram campaign creation in fe
Browse files Browse the repository at this point in the history
  • Loading branch information
KishenKumarrrrr committed Jan 3, 2024
1 parent dd3522a commit a7d8250
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 82 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -165,33 +165,6 @@ const CreateModal = ({
</p>
)}
</div>

<div className={styles.channelContainer}>
<input
type="radio"
aria-label={ChannelType.Telegram}
id={ChannelType.Telegram}
value={ChannelType.Telegram}
checked={selectedChannel === ChannelType.Telegram}
onChange={() => setSelectedChannel(ChannelType.Telegram)}
/>
<label htmlFor={ChannelType.Telegram} className={styles.subtext}>
Telegram
</label>
{selectedChannel === ChannelType.Telegram && (
<p className={styles.infotext}>
Set up your Telegram Bot. &nbsp;
<OutboundLink
className={styles.link}
eventLabel="https://go.gov.sg/postman-telegram"
to="https://go.gov.sg/postman-telegram"
target="_blank"
>
Learn more.
</OutboundLink>
</p>
)}
</div>
{canAccessGovsg && (
<div className={styles.channelContainer}>
<input
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -162,32 +162,6 @@ const DuplicateCampaignModal = ({ campaign }: { campaign: Campaign }) => {
</p>
)}
</div>
<div className={styles.channelContainer}>
<input
type="radio"
aria-label={ChannelType.Telegram}
id={ChannelType.Telegram}
value={ChannelType.Telegram}
checked={campaign.type === ChannelType.Telegram}
disabled={true}
/>
<label htmlFor={ChannelType.Telegram} className={styles.subtext}>
Telegram
</label>
{campaign.type === ChannelType.Telegram && (
<p className={styles.infotext}>
Set up your Telegram Bot. &nbsp;
<OutboundLink
className={styles.link}
eventLabel="https://go.gov.sg/postman-telegram"
to="https://go.gov.sg/postman-telegram"
target="_blank"
>
Learn more.
</OutboundLink>
</p>
)}
</div>
{canAccessGovsg && (
<div className={styles.channelContainer}>
<input
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -123,10 +123,10 @@ const CreateDemoModal = ({
Choose the channel you want to send in
</h2>
<h5 className={styles.subtitle}>
Demo campaigns are for SMS and Telegram channels only, as the Email
channel is already free. You may send messages to at most 20
recipients in each campaign. One try will be used up only after a
demo campaign has been sent, otherwise, it will stay as a draft.
Demo campaigns are for SMS channels only, as the Email channel is
already free. You may send messages to at most 20 recipients in each
campaign. One try will be used up only after a demo campaign has
been sent, otherwise, it will stay as a draft.
</h5>
</div>

Expand All @@ -151,31 +151,6 @@ const CreateDemoModal = ({
></i>
</PrimaryButton>
</div>
<div className={styles.channelContainer}>
<PrimaryButton
className={cx(styles.button, {
[styles.active]: selectedChannel === ChannelType.Telegram,
})}
disabled={
duplicateCampaign &&
duplicateCampaign.type !== ChannelType.Telegram
}
onClick={
selectedChannel === ChannelType.Telegram
? undefined
: () => setSelectedChannel(ChannelType.Telegram)
}
>
Telegram
<i
className={cx(
'bx',
styles.icon,
channelIcons[ChannelType.Telegram]
)}
></i>
</PrimaryButton>
</div>
</div>
<div className="separator"></div>
<div className={styles.actions}>
Expand Down

0 comments on commit a7d8250

Please sign in to comment.