Skip to content

Commit

Permalink
Fix stuff
Browse files Browse the repository at this point in the history
  • Loading branch information
nastita committed Nov 1, 2024
1 parent 4342d78 commit f67a6ec
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
8 changes: 6 additions & 2 deletions domains/grid/components/GridWidgetElfsight.vue
Original file line number Diff line number Diff line change
@@ -1,12 +1,16 @@
<script setup lang="ts">
import { useScriptTag } from '@vueuse/core'
type Props = {
id: string
}
defineProps<Props>()
useScriptTag('https://static.elfsight.com/platform/platform.js')
</script>

<template>
<script src="https://static.elfsight.com/platform/platform.js" async></script>
<div :class="`elfsight-app-${id}`" data-elfsight-app-lazy></div>
<div class="relative m-3 overflow-auto">
<div :class="`elfsight-app-${id}`" data-elfsight-app-lazy></div>
</div>
</template>
4 changes: 2 additions & 2 deletions domains/schema/elfsightWidgetSchema.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@ import { z } from 'zod'

export const elfsightWidgetSchema = z
.object({
id: z.string(),
src: z.string(),
})
.transform((values, ctx) =>
platformTransform({ src: values.id }, ctx, GRID_WIDGET_TYPE.enum.ELFSIGHT)
platformTransform(values, ctx, GRID_WIDGET_TYPE.enum.ELFSIGHT)
)

export type ElfSightWidgetProperties = z.input<typeof elfsightWidgetSchema>

0 comments on commit f67a6ec

Please sign in to comment.