@webstudio-is/react-sdk 0.168.0 → 0.174.0

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,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import { componentAttribute, idAttribute } from "../props";
3
2
  export type AnyComponent = React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLElement>, HTMLElement>, "ref"> & WebstudioComponentSystemProps & React.RefAttributes<HTMLElement>>;
4
3
  export type Components = Map<string, AnyComponent>;
@@ -1,4 +1,3 @@
1
- /// <reference types="react" />
2
1
  import type { ImageLoader } from "@webstudio-is/image";
3
2
  export type Params = {
4
3
  /**
@@ -298,4 +298,4 @@ export declare const corePropsMetas: {
298
298
  initialProps?: string[] | undefined;
299
299
  };
300
300
  };
301
- export declare const isCoreComponent: (component: string) => boolean;
301
+ export declare const isCoreComponent: (component: string) => component is "ws:collection" | "ws:descendant";
@@ -1,5 +1,5 @@
1
1
  import { type TransformValue } from "@webstudio-is/css-engine";
2
- import type { Assets, Breakpoints, Instances, Props, StyleSourceSelections, Styles } from "@webstudio-is/sdk";
2
+ import { type Assets, type Breakpoints, type Instances, type Props, type StyleSourceSelections, type Styles } from "@webstudio-is/sdk";
3
3
  import type { WsComponentMeta } from "../components/component-meta";
4
4
  export type CssConfig = {
5
5
  assets: Assets;
@@ -12,57 +12,10 @@ export type CssConfig = {
12
12
  assetBaseUrl: string;
13
13
  atomic: boolean;
14
14
  };
15
- export declare const createImageValueTransformer: (assets: Map<string, {
16
- type: "font";
17
- name: string;
18
- format: "ttf" | "woff" | "woff2";
19
- meta: ({
20
- family: string;
21
- style: "normal" | "italic" | "oblique";
22
- weight: number;
23
- } | {
24
- family: string;
25
- variationAxes: Partial<Record<"wght" | "wdth" | "slnt" | "opsz" | "ital" | "GRAD" | "XTRA" | "XOPQ" | "YOPQ" | "YTLC" | "YTUC" | "YTAS" | "YTDE" | "YTFI", {
26
- name: string;
27
- min: number;
28
- default: number;
29
- max: number;
30
- }>>;
31
- }) & ({
32
- family: string;
33
- style: "normal" | "italic" | "oblique";
34
- weight: number;
35
- } | {
36
- family: string;
37
- variationAxes: Partial<Record<"wght" | "wdth" | "slnt" | "opsz" | "ital" | "GRAD" | "XTRA" | "XOPQ" | "YOPQ" | "YTLC" | "YTUC" | "YTAS" | "YTDE" | "YTFI", {
38
- name: string;
39
- min: number;
40
- default: number;
41
- max: number;
42
- }>>;
43
- } | undefined);
44
- id: string;
45
- projectId: string;
46
- size: number;
47
- description: string | null;
48
- createdAt: string;
49
- } | {
50
- type: "image";
51
- name: string;
52
- format: string;
53
- meta: {
54
- width: number;
55
- height: number;
56
- };
57
- id: string;
58
- projectId: string;
59
- size: number;
60
- description: string | null;
61
- createdAt: string;
62
- }>, { assetBaseUrl }: {
15
+ export declare const createImageValueTransformer: (assets: Assets, { assetBaseUrl }: {
63
16
  assetBaseUrl: string;
64
17
  }) => TransformValue;
65
18
  export declare const generateCss: ({ assets, instances, props, breakpoints, styles, styleSourceSelections, componentMetas, assetBaseUrl, atomic, }: CssConfig) => {
66
19
  cssText: string;
67
- classesMap: Map<string, string[]>;
20
+ classes: Map<string, string[]>;
68
21
  };
@@ -1,3 +1,2 @@
1
1
  export * from "./global-rules";
2
- export * from "./style-rules";
3
2
  export * from "./css";