-
Notifications
You must be signed in to change notification settings - Fork 39
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Jicheng Lu
committed
Oct 3, 2024
1 parent
a9d4f95
commit 6b84a85
Showing
8 changed files
with
205 additions
and
75 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
<script> | ||
/** @type {string} */ | ||
export let text; | ||
/** @type {() => void} */ | ||
export let close = () => {}; | ||
/** @type {string} */ | ||
export let containerClasses = ""; | ||
/** @type {string} */ | ||
export let containerStyles = ""; | ||
/** @type {boolean} */ | ||
export let disableDefaultStyles = false; | ||
/** @param {any} e */ | ||
function handleClose(e) { | ||
e.preventDefault(); | ||
close?.(); | ||
} | ||
</script> | ||
<div | ||
class="{disableDefaultStyles ? '' : 'chat-bubble-container'} {containerClasses}" | ||
style={`${containerStyles}`} | ||
> | ||
<div class="chat-bubble"> | ||
<!-- svelte-ignore a11y-click-events-have-key-events --> | ||
<!-- svelte-ignore a11y-no-static-element-interactions --> | ||
<div | ||
class="bubble-delete clickable" | ||
on:click={e => handleClose(e)} | ||
> | ||
<i class="mdi mdi-close" /> | ||
</div> | ||
<div class="bubble-text"> | ||
{text} | ||
</div> | ||
</div> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.