@meduza/ui-kit-2 1.0.9 → 1.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "1.0.9",
2
+ "version": "1.1.1",
3
3
  "license": "MIT",
4
4
  "description": "UIKit for Meduza",
5
5
  "repository": "https://github.com/meduza-corp/ui-kit-2.git",
@@ -13,19 +13,6 @@ import { EmbedBlockProps } from './EmbedBlock.types'
13
13
 
14
14
  import styles from './EmbedBlock.module.css'
15
15
 
16
- const thumbnailToImagePath = (url: string | undefined): string | undefined => {
17
- if (!url) {
18
- return undefined
19
- }
20
- const indexImage = url.indexOf('/image')
21
-
22
- if (indexImage >= 0) {
23
- return url.slice(indexImage)
24
- }
25
-
26
- return url
27
- }
28
-
29
16
  export const EmbedBlock: React.FC<EmbedBlockProps> = ({
30
17
  block,
31
18
  block: {
@@ -126,9 +113,10 @@ export const EmbedBlock: React.FC<EmbedBlockProps> = ({
126
113
  >
127
114
  <video
128
115
  src={videoFileUrl}
129
- poster={thumbnailToImagePath(thumbnailUrl)}
116
+ poster={thumbnailUrl}
130
117
  controls
131
118
  playsInline
119
+ preload="none"
132
120
  />
133
121
  </div>
134
122
  </div>