Twitter

Add twitter component to your extension.

Install

npx ChromeKit-Org/cli add-component twitter

This will get the twitter component. Copy the twitter directory into your react project.

Usage

Props

svg

Provide svg in html format

clickHandler

Provide a click handler function. This will be called when the custom element is clicked. It passes tweetId and twitter userName of the tweet.

iconColor

Provide the color of the icon

iconBgColor

Provide the BG color for the icon. This comes up when the user hovers over the icon. It's recommended to use the same color as icon color but with 10% opacity.

uniqueId

Provide a uniqueId

Note: You need to import tweet.css file as well along with the Tweet component import.

Last updated