@datocms/astro 0.1.2 → 0.1.3

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.
@@ -1,8 +1,9 @@
1
1
  ---
2
2
  import type { ResponsiveImageType } from "../../lib/types";
3
3
  import { buildSrcSet } from './buildSrcSet';
4
+ import type { JSX } from 'astro/jsx-runtime';
4
5
 
5
- type StyleAttribute = astroHTML.JSX.HTMLAttributes['style'];
6
+ type StyleAttribute = JSX.HTMLAttributes['style'];
6
7
  type StyleAttributeAsObject = Exclude<StyleAttribute, string>;
7
8
 
8
9
  interface Props {
@@ -0,0 +1,2 @@
1
+ import Component from "./index.astro";
2
+ export default Component;
@@ -12,10 +12,11 @@ import type MuxPlayerElement from "@mux/mux-player";
12
12
  import type { Tokens } from "@mux/mux-player";
13
13
  import { useVideoPlayer } from "../../lib";
14
14
  import { toHTMLAttrs } from "./toHtmlArgs";
15
+ import type { JSX } from 'astro/jsx-runtime';
15
16
 
16
17
  type ValueOf<T> = T[keyof T];
17
18
 
18
- type StyleAttribute = astroHTML.JSX.HTMLAttributes["style"];
19
+ type StyleAttribute = JSX.HTMLAttributes["style"];
19
20
 
20
21
  interface Props {
21
22
  data: Video;
@@ -0,0 +1,2 @@
1
+ import Component from "./index.astro";
2
+ export default Component;
package/lib/index.ts CHANGED
@@ -1,4 +1,4 @@
1
- export { default as Image } from "../components/Image/index.astro";
2
- export { default as VideoPlayer } from "../components/VideoPlayer/index.astro";
1
+ export { default as Image } from "../components/Image";
2
+ export { default as VideoPlayer } from "../components/VideoPlayer";
3
3
  export { useVideoPlayer } from './useVideoPlayer';
4
4
 
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@datocms/astro",
3
3
  "description": "A set of components and utilities to work faster with DatoCMS in Astro projects.",
4
4
  "type": "module",
5
- "version": "0.1.2",
5
+ "version": "0.1.3",
6
6
  "sideEffects": false,
7
7
  "repository": {
8
8
  "type": "git",
@@ -21,12 +21,9 @@
21
21
  "ui"
22
22
  ],
23
23
  "exports": {
24
- ".": "./lib/index.ts"
25
- },
26
- "typesVersions": {
27
- "*": {
28
- "*": ["lib/*"]
29
- }
24
+ ".": "./lib/index.ts",
25
+ "./VideoPlayer": "./components/VideoPlayer/index.ts",
26
+ "./Image": "./components/Image/index.ts"
30
27
  },
31
28
  "engines": {
32
29
  "node": ">=18.0.0"
package/lib/astro.d.ts DELETED
@@ -1,9 +0,0 @@
1
- /// <reference types="astro/client" />
2
-
3
- declare module "*.astro" {
4
- type Props = any;
5
- const Component: (props: Props) => any;
6
-
7
- export default Component;
8
- export type { Props };
9
- }