Improved channel subscribe button.

This commit is contained in:
n8detar 2022-04-22 09:19:20 -07:00
parent 0f5ad25a92
commit 5bf24d1576

View File

@ -185,20 +185,20 @@ const Channel: NextPage = () => {
className="unsubscribe" className="unsubscribe"
type="button" type="button"
id="{{ channel.source.channel_id }}" id="{{ channel.source.channel_id }}"
onClick={() => console.log("unsubscribe(this.id)")} onClick={() => console.log("unsubscribe(this.id) -> toggleSubscribe()")}
title="Unsubscribe from {{ channel.source.channel_name }}" title={`${channel?.channel_subscribed ? "Unsubscribe from" : "Subscribe to"} ${channel?.channel_name}`}
> >
Unsubscribe {channel?.channel_subscribed ? "Unsubscribe" : "Subscribe"}
</button> </button>
{/* {% else %} */} {/* {% else %} */}
<button {/* <button
type="button" type="button"
id="{{ channel.source.channel_id }}" id="{{ channel.source.channel_id }}"
onClick={() => console.log("subscribe(this.id)")} onClick={() => console.log("subscribe(this.id)")}
title="Subscribe to {{ channel.source.channel_name }}" title="Subscribe to {{ channel.source.channel_name }}"
> >
Subscribe Subscribe
</button> </button> */}
{/* {% endif %} */} {/* {% endif %} */}
</div> </div>
</div> </div>