Skip to content

Commit

Permalink
add shadow props to frame.
Browse files Browse the repository at this point in the history
  • Loading branch information
codepert committed Jul 18, 2024
1 parent 376ec7f commit edb32f3
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/lib/frame/frame.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@
let divClass;
// $:divClass = twMerge('ms-frame ', $$props.rounded && 'rounded-lg', hoverTransform && "hover", $$props.class, imgHoverTransform && ("img-hover"))
$:divClass = twMerge('ms-frame ', $$props.rounded && 'rounded-lg', $$props.class)
$:divClass = twMerge('ms-frame ', $$props.rounded && 'rounded-lg', $$props.class, $$props.shadow && 'shadow')
</script>

Expand Down
2 changes: 2 additions & 0 deletions src/lib/frame/style.css
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
.ms-frame {
cursor: pointer;
}
.ms-frame.shadow {
box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
}
.ms-frame.hover:hover {
Expand Down
16 changes: 15 additions & 1 deletion src/routes/+page.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,8 @@
dataURL="http://localhost/api"
intervalData={intervalData}
hoverTransform
shadow
rounded
>
<h5 class="mb-2 text-xl tracking-tight text-gray-900 ">Meta stellar card</h5>
<p class="mb-3 font-normal text-gray-700 leading-tight">Lorem ipsum dolor sit amet consectetur adipisicing elit. Vitae accusantium praesentium ullam alias aut quod cum perferendis maiores.</p>
Expand All @@ -57,6 +59,8 @@
hoverTransform
imgHoverTransform
reverse
shadow
rounded
>
<h5 class="mb-2 text-xl tracking-tight text-gray-900 ">Meta stellar card(reverse)</h5>
<p class="mb-3 font-normal text-gray-700 leading-tight">Lorem ipsum dolor sit amet consectetur adipisicing elit. Vitae accusantium praesentium ullam alias aut quod cum perferendis maiores.</p>
Expand All @@ -69,6 +73,8 @@
dataURL="http://localhost/api"
intervalData={intervalData}
hoverTransform
shadow
rounded
>
<h5 class="mb-2 text-xl tracking-tight text-gray-900 ">Meta stellar card(no image)</h5>
<p class="mb-3 font-normal text-gray-700 leading-tight">Lorem ipsum dolor sit amet consectetur adipisicing elit. Vitae accusantium praesentium ullam alias aut quod cum perferendis maiores.</p>
Expand All @@ -81,7 +87,9 @@
intervalData={intervalData}
hoverTransform
class="rounded-lg"
imgClass="rounded-lg">
imgClass="rounded-lg"
shadow
rounded>
</ImagePoster>
<h3 class="mt-4">
Image poster card
Expand All @@ -92,6 +100,8 @@
yutubeURL="/video/1.mp4"
thumnailURL="/images/1.jpg"
type="video/mp4"
shadow
rounded
>
<div class="">
<a href="/video/1.mp4" class="mt-2">
Expand All @@ -112,6 +122,8 @@
imgHoverTransform
assetAccount={nftInfo}
getNFTAssetInfo={getNFTAssetInfo}
shadow
rounded
>
</NftPoster>

Expand All @@ -130,6 +142,8 @@
imgHoverTransform
assetAccount={tokenInfo}
getTokenAssetInfo={getTokenAssetInfo}
shadow
rounded
>
</TokenPoster>
<h3 class="mt-4">
Expand Down

0 comments on commit edb32f3

Please sign in to comment.