Skip to content

Commit

Permalink
[core/src/ui/Base/TwitterEmbed][xs]: Twitter embed fix
Browse files Browse the repository at this point in the history
  • Loading branch information
PhilippeduPreez committed Feb 15, 2023
1 parent 1e2722f commit 267b3cf
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
5 changes: 5 additions & 0 deletions .changeset/great-gorillas-cross.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@flowershow/core": patch
---

Fix: remove twitter url from displaying after embed
3 changes: 1 addition & 2 deletions packages/core/src/ui/Base/TwitterEmbed.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
// TODO dark and light theme

import { useEffect, useCallback, useState, useRef, RefObject } from "react";
import { useEffect, useState, useRef, RefObject } from "react";

const twitterWidgetJs = "https://platform.twitter.com/widgets.js";
enum TweetState {
Expand Down Expand Up @@ -100,7 +100,6 @@ export default function TwitterEmbed({ url, ...props }) {
</div>
)}
<div className="twitter-tweet" ref={ref} />
{tweetState === TweetState.LOADED && <p {...props} />}
</>
);
}

0 comments on commit 267b3cf

Please sign in to comment.