@builder.io/mitosis 0.0.135 → 0.0.136

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.
Files changed (65) hide show
  1. package/dist/src/constants/media-sizes.d.ts +1 -1
  2. package/dist/src/generators/builder.d.ts +1 -1
  3. package/dist/src/generators/context/qwik.d.ts +1 -1
  4. package/dist/src/generators/context/react.d.ts +1 -1
  5. package/dist/src/generators/context/rsc.d.ts +1 -1
  6. package/dist/src/generators/context/solid.d.ts +1 -1
  7. package/dist/src/generators/qwik/component.d.ts +1 -1
  8. package/dist/src/generators/qwik/helpers/state.d.ts +5 -5
  9. package/dist/src/generators/qwik/helpers/styles.d.ts +1 -1
  10. package/dist/src/generators/qwik/src-generator.d.ts +1 -1
  11. package/dist/src/generators/react/generator.js +1 -1
  12. package/dist/src/generators/react-native/sanitize-react-native-block-styles.d.ts +1 -1
  13. package/dist/src/generators/rsc.d.ts +1 -1
  14. package/dist/src/generators/solid/state/state.d.ts +1 -1
  15. package/dist/src/generators/solid/types.d.ts +1 -1
  16. package/dist/src/generators/svelte/blocks.d.ts +1 -1
  17. package/dist/src/generators/svelte/types.d.ts +1 -1
  18. package/dist/src/generators/swift-ui.d.ts +1 -1
  19. package/dist/src/generators/taro.d.ts +1 -1
  20. package/dist/src/generators/vue/blocks.d.ts +1 -1
  21. package/dist/src/generators/vue/helpers.d.ts +1 -1
  22. package/dist/src/generators/vue/types.d.ts +3 -3
  23. package/dist/src/helpers/babel-transform.d.ts +1 -1
  24. package/dist/src/helpers/component-file-extensions.d.ts +1 -1
  25. package/dist/src/helpers/create-mitosis-component.d.ts +1 -1
  26. package/dist/src/helpers/get-state-object-string.d.ts +1 -1
  27. package/dist/src/helpers/json.d.ts +1 -1
  28. package/dist/src/helpers/map-refs.d.ts +1 -1
  29. package/dist/src/helpers/nullable.d.ts +1 -1
  30. package/dist/src/helpers/plugins/process-code/index.d.ts +1 -1
  31. package/dist/src/helpers/plugins/process-code/types.d.ts +2 -2
  32. package/dist/src/helpers/plugins/process-signals.js +2 -0
  33. package/dist/src/helpers/render-imports.d.ts +1 -1
  34. package/dist/src/helpers/replace-identifiers.d.ts +2 -2
  35. package/dist/src/helpers/slots.d.ts +1 -1
  36. package/dist/src/helpers/strip-state-and-props-refs.d.ts +2 -2
  37. package/dist/src/helpers/styles/collect-css.d.ts +1 -1
  38. package/dist/src/helpers/styles/helpers.d.ts +2 -2
  39. package/dist/src/helpers/transform-state-setters.d.ts +1 -1
  40. package/dist/src/helpers/typescript.d.ts +4 -4
  41. package/dist/src/index.d.ts +2 -2
  42. package/dist/src/parsers/builder/builder.d.ts +2 -2
  43. package/dist/src/parsers/context.d.ts +1 -1
  44. package/dist/src/parsers/jsx/index.d.ts +1 -0
  45. package/dist/src/parsers/jsx/types.d.ts +2 -2
  46. package/dist/src/parsers/svelte/helpers/post-process.d.ts +1 -1
  47. package/dist/src/parsers/svelte/index.js +1 -1
  48. package/dist/src/parsers/svelte/types/index.d.ts +1 -1
  49. package/dist/src/plugins/compile-away-builder-components.d.ts +2 -2
  50. package/dist/src/plugins/compile-away-builder-components.js +1 -2
  51. package/dist/src/plugins/compile-away-components.d.ts +1 -1
  52. package/dist/src/plugins/map-styles.d.ts +1 -1
  53. package/dist/src/symbols/symbol-processor.d.ts +1 -1
  54. package/dist/src/targets.d.ts +21 -21
  55. package/dist/src/types/config.d.ts +6 -6
  56. package/dist/src/types/json.d.ts +6 -6
  57. package/dist/src/types/metadata.d.ts +3 -3
  58. package/dist/src/types/mitosis-component.d.ts +14 -14
  59. package/dist/src/types/mitosis-context.d.ts +1 -1
  60. package/dist/src/types/mitosis-node.d.ts +7 -7
  61. package/dist/src/types/mitosis-styles.d.ts +1 -1
  62. package/dist/src/types/plugins.d.ts +1 -1
  63. package/dist/src/types/transpiler.d.ts +2 -2
  64. package/dist/tsconfig.build.tsbuildinfo +1 -1
  65. package/package.json +3 -3
@@ -1,4 +1,4 @@
1
- export declare type Size = 'large' | 'medium' | 'small';
1
+ export type Size = 'large' | 'medium' | 'small';
2
2
  export declare const sizeNames: Size[];
3
3
  export declare const sizes: {
4
4
  small: {
@@ -4,7 +4,7 @@ import { BaseTranspilerOptions, TranspilerArgs } from '../types/transpiler';
4
4
  export interface ToBuilderOptions extends BaseTranspilerOptions {
5
5
  includeIds?: boolean;
6
6
  }
7
- declare type InternalOptions = {
7
+ type InternalOptions = {
8
8
  skipMapper?: boolean;
9
9
  };
10
10
  export declare const blockToBuilder: (json: MitosisNode, options?: ToBuilderOptions, _internalOptions?: InternalOptions) => BuilderElement;
@@ -1,5 +1,5 @@
1
1
  import { MitosisContext } from '../../types/mitosis-context';
2
- declare type ContextToQwikOptions = {
2
+ type ContextToQwikOptions = {
3
3
  format?: boolean;
4
4
  };
5
5
  export declare const contextToQwik: (options?: ContextToQwikOptions) => ({ context }: {
@@ -1,5 +1,5 @@
1
1
  import { MitosisContext } from '../../types/mitosis-context';
2
- declare type ContextToReactOptions = {
2
+ type ContextToReactOptions = {
3
3
  format?: boolean;
4
4
  preact?: boolean;
5
5
  typescript?: boolean;
@@ -1,5 +1,5 @@
1
1
  import { MitosisContext } from '../../types/mitosis-context';
2
- declare type ContextToRscOptions = {
2
+ type ContextToRscOptions = {
3
3
  format?: boolean;
4
4
  };
5
5
  /**
@@ -1,5 +1,5 @@
1
1
  import { MitosisContext } from '../../types/mitosis-context';
2
- declare type ContextToSolidOptions = {
2
+ type ContextToSolidOptions = {
3
3
  format?: boolean;
4
4
  };
5
5
  export declare const contextToSolid: (options?: ContextToSolidOptions) => ({ context }: {
@@ -1,6 +1,6 @@
1
1
  import { MitosisComponent } from '../../types/mitosis-component';
2
2
  import { File, SrcBuilder } from './src-generator';
3
- export declare type QwikOptions = {
3
+ export type QwikOptions = {
4
4
  qwikLib?: string;
5
5
  qrlPrefix?: string;
6
6
  output?: 'ts' | 'cjs' | 'mjs';
@@ -4,19 +4,19 @@ import { File } from '../src-generator';
4
4
  /**
5
5
  * Stores getters and initialization map.
6
6
  */
7
- export declare type StateInit = [
7
+ export type StateInit = [
8
8
  StateValues,
9
9
  /**
10
10
  * Set of state initializers.
11
11
  */
12
12
  ...string[]
13
13
  ];
14
- export declare type PropertyName = string;
15
- export declare type StateValue = string;
14
+ export type PropertyName = string;
15
+ export type StateValue = string;
16
16
  /**
17
17
  * Map of getters that need to be rewritten to function invocations.
18
18
  */
19
- export declare type StateValues = Record<PropertyName, StateValue>;
19
+ export type StateValues = Record<PropertyName, StateValue>;
20
20
  /**
21
21
  * @param file
22
22
  * @param stateInit
@@ -28,5 +28,5 @@ export declare function emitUseStore({ file, stateInit, isDeep, }: {
28
28
  }): void;
29
29
  export declare function emitStateMethodsAndRewriteBindings(file: File, component: MitosisComponent, metadata?: ComponentMetadata): StateInit;
30
30
  export declare function getLexicalScopeVars(component: MitosisComponent): string[];
31
- export declare type MethodMap = Record<string, 'method' | 'getter'>;
31
+ export type MethodMap = Record<string, 'method' | 'getter'>;
32
32
  export declare function getStateMethodsAndGetters(state: MitosisComponent['state']): MethodMap;
@@ -1,6 +1,6 @@
1
1
  import { MitosisNode } from '../../..';
2
2
  import { SrcBuilder } from '../src-generator';
3
- export declare type CssStyles = {
3
+ export type CssStyles = {
4
4
  CLASS_NAME: string;
5
5
  } & Record<string, string>;
6
6
  export declare function collectStyles(children: MitosisNode[], styleMap: Map<string, CssStyles>): Map<string, CssStyles>;
@@ -5,7 +5,7 @@ export interface SrcBuilderOptions {
5
5
  isJSX: boolean;
6
6
  isBuilder: boolean;
7
7
  }
8
- export declare type EmitFn = (this: SrcBuilder) => void;
8
+ export type EmitFn = (this: SrcBuilder) => void;
9
9
  export declare class File {
10
10
  filename: string;
11
11
  imports: Imports;
@@ -215,7 +215,7 @@ var componentToReact = function (reactOptions) {
215
215
  str = (0, standalone_1.format)(str, {
216
216
  parser: 'typescript',
217
217
  plugins: [
218
- require('prettier/parser-typescript'),
218
+ require('prettier/parser-typescript'), // To support running in browsers
219
219
  require('prettier/parser-postcss'),
220
220
  ],
221
221
  })
@@ -1,3 +1,3 @@
1
- declare type Styles = Record<string, string | number>;
1
+ type Styles = Record<string, string | number>;
2
2
  export declare const sanitizeReactNativeBlockStyles: (styles: Styles) => Styles;
3
3
  export {};
@@ -1,4 +1,4 @@
1
1
  import { TranspilerGenerator } from '../types/transpiler';
2
2
  import { ToReactOptions } from './react';
3
- export declare type ToRscOptions = ToReactOptions;
3
+ export type ToRscOptions = ToReactOptions;
4
4
  export declare const componentToRsc: TranspilerGenerator<Partial<ToRscOptions>>;
@@ -1,6 +1,6 @@
1
1
  import { MitosisComponent } from '../../../types/mitosis-component';
2
2
  import { ToSolidOptions } from '../types';
3
- declare type State = {
3
+ type State = {
4
4
  str: string;
5
5
  import: {
6
6
  store?: string[];
@@ -1,5 +1,5 @@
1
1
  import { BaseTranspilerOptions } from '../../types/transpiler';
2
- export declare type SolidState = 'mutable' | 'signals' | 'store';
2
+ export type SolidState = 'mutable' | 'signals' | 'store';
3
3
  export interface ToSolidOptions extends BaseTranspilerOptions {
4
4
  state: SolidState;
5
5
  stylesType?: 'styled-components' | 'style-tag';
@@ -1,7 +1,7 @@
1
1
  import { MitosisComponent } from '../../types/mitosis-component';
2
2
  import { BaseNode, MitosisNode } from '../../types/mitosis-node';
3
3
  import { ToSvelteOptions } from './types';
4
- declare type BlockToSvelte<T extends BaseNode = MitosisNode> = (props: {
4
+ type BlockToSvelte<T extends BaseNode = MitosisNode> = (props: {
5
5
  json: T;
6
6
  options: ToSvelteOptions;
7
7
  parentComponent: MitosisComponent;
@@ -1,4 +1,4 @@
1
1
  import { BaseTranspilerOptions } from '../../types/transpiler';
2
- export declare type ToSvelteOptions = BaseTranspilerOptions & {
2
+ export type ToSvelteOptions = BaseTranspilerOptions & {
3
3
  stateType?: 'proxies' | 'variables';
4
4
  };
@@ -1,3 +1,3 @@
1
1
  import { BaseTranspilerOptions, TranspilerGenerator } from '../types/transpiler';
2
- export declare type ToSwiftOptions = BaseTranspilerOptions;
2
+ export type ToSwiftOptions = BaseTranspilerOptions;
3
3
  export declare const componentToSwift: TranspilerGenerator<ToSwiftOptions>;
@@ -3,7 +3,7 @@ import { MitosisComponent } from '../types/mitosis-component';
3
3
  import { TranspilerGenerator } from '../types/transpiler';
4
4
  import { ToReactOptions } from './react';
5
5
  export declare const DEFAULT_Component_SET: Set<string>;
6
- export declare type ToTaroOptions = ToReactOptions;
6
+ export type ToTaroOptions = ToReactOptions;
7
7
  export declare const collectTaroStyles: (json: MitosisComponent) => ClassStyleMap;
8
8
  export declare const TagMap: Record<string, string>;
9
9
  export declare const componentToTaro: TranspilerGenerator<Partial<ToTaroOptions>>;
@@ -1,6 +1,6 @@
1
1
  import { MitosisNode } from '../../types/mitosis-node';
2
2
  import { ToVueOptions } from './types';
3
- declare type BlockRenderer = (json: MitosisNode, options: ToVueOptions, scope?: Scope) => string;
3
+ type BlockRenderer = (json: MitosisNode, options: ToVueOptions, scope?: Scope) => string;
4
4
  interface Scope {
5
5
  isRootNode?: boolean;
6
6
  }
@@ -10,7 +10,7 @@ export declare function encodeQuotes(string: string): string;
10
10
  export declare const mapMitosisComponentToKebabCase: (componentName: string) => string;
11
11
  export declare const renameMitosisComponentsToKebabCase: (str: string) => string;
12
12
  export declare function getContextNames(json: MitosisComponent): string[];
13
- declare type ProcessBinding = {
13
+ type ProcessBinding = {
14
14
  code: string;
15
15
  options: ToVueOptions;
16
16
  json: MitosisComponent;
@@ -1,7 +1,7 @@
1
1
  import { OmitObj } from '../../helpers/typescript';
2
2
  import { BaseTranspilerOptions } from '../../types/transpiler';
3
- export declare type VueVersion = 2 | 3;
4
- export declare type Api = 'options' | 'composition';
3
+ export type VueVersion = 2 | 3;
4
+ export type Api = 'options' | 'composition';
5
5
  interface VueVersionOpt {
6
6
  vueVersion: VueVersion;
7
7
  }
@@ -12,5 +12,5 @@ export interface ToVueOptions extends BaseTranspilerOptions, VueVersionOpt {
12
12
  defineComponent?: boolean;
13
13
  api: Api;
14
14
  }
15
- export declare type VueOptsWithoutVersion = OmitObj<ToVueOptions, VueVersionOpt>;
15
+ export type VueOptsWithoutVersion = OmitObj<ToVueOptions, VueVersionOpt>;
16
16
  export {};
@@ -1,7 +1,7 @@
1
1
  import * as babel from '@babel/core';
2
2
  import type { Visitor } from '@babel/traverse';
3
3
  export declare const babelTransformCode: <VisitorContextType = any>(code: string, visitor?: babel.Visitor<VisitorContextType> | undefined, stripTypes?: boolean) => string;
4
- declare type ExpressionType = 'expression' | 'unknown' | 'block' | 'functionBody';
4
+ type ExpressionType = 'expression' | 'unknown' | 'block' | 'functionBody';
5
5
  export declare const babelTransformExpression: <VisitorContextType = any>(code: string, visitor: babel.Visitor<VisitorContextType>, initialType?: ExpressionType, stripTypes?: boolean) => string;
6
6
  export declare const convertTypeScriptToJS: (code: string) => string;
7
7
  export {};
@@ -17,7 +17,7 @@ export declare const renameImport: ({ importPath, target, explicitImportFileExte
17
17
  target: Target;
18
18
  explicitImportFileExtension: boolean;
19
19
  }) => string;
20
- declare type Args = {
20
+ type Args = {
21
21
  target: Target;
22
22
  } & ({
23
23
  /**
@@ -1,6 +1,6 @@
1
1
  import { MitosisComponent } from '../types/mitosis-component';
2
2
  import { Overwrite, Prettify } from './typescript';
3
- declare type PartialMitosisComponent = Prettify<Overwrite<Partial<MitosisComponent>, {
3
+ type PartialMitosisComponent = Prettify<Overwrite<Partial<MitosisComponent>, {
4
4
  hooks: Partial<MitosisComponent['hooks']>;
5
5
  }>>;
6
6
  export declare const createMitosisComponent: (options?: PartialMitosisComponent) => MitosisComponent;
@@ -1,6 +1,6 @@
1
1
  import { MitosisComponent } from '../types/mitosis-component';
2
2
  import { MitosisContext } from '../types/mitosis-context';
3
- declare type ValueMapper = (code: string, type: 'data' | 'function' | 'getter', typeParameter: string | undefined, key: string | undefined) => string;
3
+ type ValueMapper = (code: string, type: 'data' | 'function' | 'getter', typeParameter: string | undefined, key: string | undefined) => string;
4
4
  interface GetStateObjectStringOptions {
5
5
  data?: boolean;
6
6
  functions?: boolean;
@@ -1,3 +1,3 @@
1
- declare type ParsedJson = any;
1
+ type ParsedJson = any;
2
2
  export declare const tryParseJson: (jsonStr: string) => ParsedJson;
3
3
  export {};
@@ -1,3 +1,3 @@
1
1
  import { MitosisComponent } from '../types/mitosis-component';
2
- export declare type RefMapper = (refName: string) => string;
2
+ export type RefMapper = (refName: string) => string;
3
3
  export declare const mapRefs: (component: MitosisComponent, mapper: RefMapper) => void;
@@ -1,2 +1,2 @@
1
- export declare type Nullable<X> = X | null | undefined;
1
+ export type Nullable<X> = X | null | undefined;
2
2
  export declare const checkIsDefined: <T>(value: Nullable<T>) => value is NonNullable<T>;
@@ -7,6 +7,6 @@ export declare const createCodeProcessorPlugin: (codeProcessor: CodeProcessor, {
7
7
  /**
8
8
  * Given a `codeProcessor` function, processes all code expressions within a Mitosis component.
9
9
  */
10
- export declare const CODE_PROCESSOR_PLUGIN: (a_0: (codeType: import("./types").CodeType, json: MitosisComponent, node?: import("../../..").MitosisNode | undefined) => (code: string, hookType: string) => string | (() => void), a_1?: {
10
+ export declare const CODE_PROCESSOR_PLUGIN: (codeProcessor: (codeType: import("./types").CodeType, json: MitosisComponent, node?: import("../../..").MitosisNode | undefined) => (code: string, hookType: string) => string | (() => void), a_1?: {
11
11
  processProperties?: boolean | undefined;
12
12
  } | undefined) => Plugin;
@@ -1,6 +1,6 @@
1
1
  import { MitosisComponent } from '../../../types/mitosis-component';
2
2
  import { MitosisNode } from '../../../types/mitosis-node';
3
- export declare type CodeType = 'hooks' | 'hooks-deps' | 'bindings' | 'properties' | 'state' | 'types' | 'context-set' | 'dynamic-jsx-elements';
3
+ export type CodeType = 'hooks' | 'hooks-deps' | 'bindings' | 'properties' | 'state' | 'types' | 'context-set' | 'dynamic-jsx-elements';
4
4
  declare function codeProcessor(codeType: CodeType, json: MitosisComponent, node?: MitosisNode): (code: string, hookType: string) => string | (() => void);
5
- export declare type CodeProcessor = typeof codeProcessor;
5
+ export type CodeProcessor = typeof codeProcessor;
6
6
  export {};
@@ -103,6 +103,8 @@ var getSignalMapperForTarget = function (target) {
103
103
  return {
104
104
  getter: function (name) { return core_1.types.identifier('$' + name); },
105
105
  };
106
+ case 'preact':
107
+ case 'reactNative':
106
108
  case 'react':
107
109
  case 'solid':
108
110
  return {
@@ -7,7 +7,7 @@ export declare const transformImportPath: ({ theImport, target, preserveFileExte
7
7
  preserveFileExtensions: boolean;
8
8
  explicitImportFileExtension: boolean;
9
9
  }) => string;
10
- declare type ImportArgs = {
10
+ type ImportArgs = {
11
11
  target: Target;
12
12
  asyncComponentImports: boolean;
13
13
  preserveFileExtensions?: boolean;
@@ -1,6 +1,6 @@
1
1
  import { types } from '@babel/core';
2
- export declare type ReplaceTo = string | ((accessedProperty: string, matchedIdentifier: string) => string) | null;
3
- declare type ReplaceArgs = {
2
+ export type ReplaceTo = string | ((accessedProperty: string, matchedIdentifier: string) => string) | null;
3
+ type ReplaceArgs = {
4
4
  code: string;
5
5
  from: string | string[];
6
6
  to: ReplaceTo;
@@ -1,4 +1,4 @@
1
- export declare type SlotMapper = (slotName: string) => string;
1
+ export type SlotMapper = (slotName: string) => string;
2
2
  export declare const isSlotProperty: (key: string, slotPrefix?: string) => boolean;
3
3
  export declare const stripSlotPrefix: (key: string, slotPrefix?: string) => string;
4
4
  export declare function replaceSlotsInString(code: string, mapper: SlotMapper): string;
@@ -1,4 +1,4 @@
1
- export declare type StripStateAndPropsRefsOptions = {
1
+ export type StripStateAndPropsRefsOptions = {
2
2
  replaceWith?: string | ((name: string) => string);
3
3
  includeProps?: boolean;
4
4
  includeState?: boolean;
@@ -14,7 +14,7 @@ export declare const DO_NOT_USE_CONTEXT_VARS_TRANSFORMS: ({ code, contextVars, c
14
14
  contextVars?: string[] | undefined;
15
15
  context: string;
16
16
  }) => string;
17
- export declare type DO_NOT_USE_ARGS = {
17
+ export type DO_NOT_USE_ARGS = {
18
18
  outputVars?: string[];
19
19
  domRefs?: string[];
20
20
  stateVars?: string[];
@@ -1,5 +1,5 @@
1
1
  import { MitosisComponent } from '../../types/mitosis-component';
2
- declare type CollectStyleOptions = {
2
+ type CollectStyleOptions = {
3
3
  prefix?: string;
4
4
  };
5
5
  export declare const collectCss: (json: MitosisComponent, options?: CollectStyleOptions) => string;
@@ -16,7 +16,7 @@ export declare const hasStyle: (component: MitosisComponent) => boolean;
16
16
  * }
17
17
  * }
18
18
  */
19
- export declare type StyleMap = {
19
+ export type StyleMap = {
20
20
  [className: string]: CSS.Properties | StyleMap;
21
21
  };
22
22
  export declare const getNestedSelectors: (map: StyleMap) => import("lodash").Dictionary<CSS.Properties<0 | (string & {}), string & {}> | StyleMap>;
@@ -24,7 +24,7 @@ export declare const getStylesOnly: (map: StyleMap) => import("lodash").Dictiona
24
24
  /**
25
25
  * { 'my-class': { display: 'block', '&.foo': { display: 'none' } }}
26
26
  */
27
- export declare type ClassStyleMap = {
27
+ export type ClassStyleMap = {
28
28
  [key: string]: StyleMap;
29
29
  };
30
30
  export declare const parseCssObject: (css: string) => any;
@@ -1,5 +1,5 @@
1
1
  import { types } from '@babel/core';
2
- declare type StateSetterTransformer = ({ path, propertyName, }: {
2
+ type StateSetterTransformer = ({ path, propertyName, }: {
3
3
  path: babel.NodePath<types.AssignmentExpression>;
4
4
  propertyName: string;
5
5
  }) => types.CallExpression;
@@ -1,9 +1,9 @@
1
- export declare type Overwrite<T, U> = keyof U extends keyof T ? Pick<T, Exclude<keyof T, keyof U>> & U : never;
2
- export declare type Prettify<T> = {
1
+ export type Overwrite<T, U> = keyof U extends keyof T ? Pick<T, Exclude<keyof T, keyof U>> & U : never;
2
+ export type Prettify<T> = {
3
3
  [K in keyof T]: T[K];
4
4
  } & {};
5
- export declare type OmitObj<T, U> = T extends U ? Omit<T, keyof U> : never;
6
- export declare type Dictionary<T> = {
5
+ export type OmitObj<T, U> = T extends U ? Omit<T, keyof U> : never;
6
+ export type Dictionary<T> = {
7
7
  [key: string]: T;
8
8
  };
9
9
  export declare const objectHasKey: <T>(object: T, key: PropertyKey) => key is keyof T;
@@ -53,10 +53,10 @@ declare function Provider<T>(props: {
53
53
  value: T;
54
54
  children: JSX.Element;
55
55
  }): any;
56
- export declare type Context<T> = {
56
+ export type Context<T> = {
57
57
  Provider: typeof Provider<T>;
58
58
  };
59
- export declare type Signal<T> = {
59
+ export type Signal<T> = {
60
60
  value: T;
61
61
  };
62
62
  export declare function useStore<T>(obj: T): T;
@@ -1,11 +1,11 @@
1
1
  import { BuilderContent, BuilderElement } from '@builder.io/sdk';
2
2
  import { MitosisComponent, MitosisState } from '../..';
3
3
  import { MitosisNode } from '../../types/mitosis-node';
4
- declare type InternalOptions = {
4
+ type InternalOptions = {
5
5
  skipMapper?: boolean;
6
6
  };
7
7
  export declare const symbolBlocksAsChildren = false;
8
- declare type BuilderToMitosisOptions = {
8
+ type BuilderToMitosisOptions = {
9
9
  context?: {
10
10
  [key: string]: any;
11
11
  };
@@ -1,5 +1,5 @@
1
1
  import { MitosisContext } from '../types/mitosis-context';
2
- declare type ParseContextOptions = {
2
+ type ParseContextOptions = {
3
3
  name: string;
4
4
  };
5
5
  export declare function parseContext(code: string, options: ParseContextOptions): MitosisContext | null;
@@ -1 +1,2 @@
1
1
  export { parseJsx } from './jsx';
2
+ export { ParseMitosisOptions } from './types';
@@ -1,6 +1,6 @@
1
1
  import { Project } from 'ts-morph';
2
2
  import { MitosisComponent } from '../../types/mitosis-component';
3
- export declare type ParseMitosisOptions = {
3
+ export type ParseMitosisOptions = {
4
4
  jsonHookNames?: string[];
5
5
  compileAwayPackages?: string[];
6
6
  typescript: boolean;
@@ -9,7 +9,7 @@ export declare type ParseMitosisOptions = {
9
9
  };
10
10
  filePath?: string;
11
11
  };
12
- export declare type Context = {
12
+ export type Context = {
13
13
  builder: {
14
14
  component: MitosisComponent;
15
15
  };
@@ -1,6 +1,6 @@
1
1
  import type { StateValue } from '../../../types/mitosis-component';
2
2
  import type { SveltosisComponent } from '../types';
3
- declare type SveltosisStateValue = StateValue & {
3
+ type SveltosisStateValue = StateValue & {
4
4
  arguments?: string[];
5
5
  type: string;
6
6
  };
@@ -14,7 +14,7 @@ var __generator = (this && this.__generator) || function (thisArg, body) {
14
14
  function verb(n) { return function (v) { return step([n, v]); }; }
15
15
  function step(op) {
16
16
  if (f) throw new TypeError("Generator is already executing.");
17
- while (_) try {
17
+ while (g && (g = 0, op[0] && (_ = 0)), _) try {
18
18
  if (f = 1, y && (t = op[0] & 2 ? y["return"] : op[0] ? y["throw"] || ((t = y["return"]) && t.call(y), 0) : y.next) && !(t = t.call(y, op[1])).done) return t;
19
19
  if (y = 0, t) op = [op[0] & 2, t.value];
20
20
  switch (op[0]) {
@@ -1,4 +1,4 @@
1
1
  import { MitosisComponent } from '../../../types/mitosis-component';
2
- export declare type SveltosisComponent = MitosisComponent & {
2
+ export type SveltosisComponent = MitosisComponent & {
3
3
  props: any;
4
4
  };
@@ -2,11 +2,11 @@ import { type Plugin } from '..';
2
2
  import { TraverseContext } from 'traverse';
3
3
  import { MitosisComponent } from '../types/mitosis-component';
4
4
  import { MitosisNode } from '../types/mitosis-node';
5
- declare type CompileAwayComponentsMap = {
5
+ type CompileAwayComponentsMap = {
6
6
  [key: string]: (node: MitosisNode, context: TraverseContext, components: CompileAwayComponentsMap) => MitosisNode | void;
7
7
  };
8
8
  export declare const components: CompileAwayComponentsMap;
9
- declare type CompileAwayBuilderComponentsOptions = {
9
+ type CompileAwayBuilderComponentsOptions = {
10
10
  only?: string[];
11
11
  omit?: string[];
12
12
  };
@@ -301,8 +301,7 @@ exports.components = {
301
301
  __assign(__assign({}, img), { bindings: __assign(__assign({}, img.bindings), { css: (0, bindings_1.createSingleBinding)({
302
302
  code: JSON.stringify({
303
303
  position: 'absolute',
304
- inset: 0,
305
- zIndex: -1,
304
+ inset: '0',
306
305
  height: '100%',
307
306
  width: '100%',
308
307
  objectFit: backgroundSize || 'cover',
@@ -4,7 +4,7 @@ import { MitosisNode } from '../types/mitosis-node';
4
4
  export declare const getRenderOptions: (node: MitosisNode) => {
5
5
  [x: string]: string;
6
6
  };
7
- declare type CompileAwayComponentsOptions = {
7
+ type CompileAwayComponentsOptions = {
8
8
  components: {
9
9
  [key: string]: (node: MitosisNode, context: TraverseContext) => MitosisNode | void;
10
10
  };
@@ -1,7 +1,7 @@
1
1
  import { TraverseContext } from 'traverse';
2
2
  import { MitosisComponent } from '../types/mitosis-component';
3
3
  import { MitosisStyles } from '../types/mitosis-styles';
4
- declare type MapStylesOptions = {
4
+ type MapStylesOptions = {
5
5
  map: (styles: MitosisStyles, context: TraverseContext) => MitosisStyles;
6
6
  };
7
7
  export declare const mapStyles: (pluginOptions: MapStylesOptions) => (options: any) => {
@@ -1,6 +1,6 @@
1
1
  import { BuilderContent, BuilderElement } from '@builder.io/sdk';
2
2
  import { MitosisComponent } from '../types/mitosis-component';
3
- export declare type SymbolHierarchy = {
3
+ export type SymbolHierarchy = {
4
4
  depthFirstSymbols: BuilderElement[];
5
5
  } & {
6
6
  [id: string]: string[];
@@ -1,27 +1,27 @@
1
1
  export declare const builder: (options?: import("./generators/builder").ToBuilderOptions) => ({ component }: import(".").TranspilerArgs) => import("@builder.io/sdk").BuilderContent;
2
2
  export declare const targets: {
3
- readonly alpine: import(".").TranspilerGenerator<import("./generators/alpine").ToAlpineOptions, string>;
4
- readonly angular: import(".").TranspilerGenerator<import("./generators/angular").ToAngularOptions, string>;
5
- readonly customElement: import(".").TranspilerGenerator<import("./generators/html").ToHtmlOptions, string>;
6
- readonly html: import(".").TranspilerGenerator<import("./generators/html").ToHtmlOptions, string>;
7
- readonly mitosis: import(".").TranspilerGenerator<Partial<import("./generators/mitosis").ToMitosisOptions>, string>;
8
- readonly liquid: import(".").TranspilerGenerator<import("./generators/liquid").ToLiquidOptions, string>;
9
- readonly react: import(".").TranspilerGenerator<Partial<import("./generators/react").ToReactOptions>, string>;
10
- readonly reactNative: import(".").TranspilerGenerator<Partial<import("./generators/react-native").ToReactNativeOptions>, string>;
11
- readonly solid: import(".").TranspilerGenerator<Partial<import("./generators/solid/types").ToSolidOptions>, string>;
12
- readonly svelte: import(".").TranspilerGenerator<import("./generators/svelte/types").ToSvelteOptions, string>;
13
- readonly swift: import(".").TranspilerGenerator<import(".").BaseTranspilerOptions, string>;
14
- readonly template: import(".").TranspilerGenerator<import("./generators/template").ToTemplateOptions, string>;
15
- readonly webcomponent: import(".").TranspilerGenerator<import("./generators/html").ToHtmlOptions, string>;
3
+ readonly alpine: import(".").TranspilerGenerator<import("./generators/alpine").ToAlpineOptions>;
4
+ readonly angular: import(".").TranspilerGenerator<import("./generators/angular").ToAngularOptions>;
5
+ readonly customElement: import(".").TranspilerGenerator<import("./generators/html").ToHtmlOptions>;
6
+ readonly html: import(".").TranspilerGenerator<import("./generators/html").ToHtmlOptions>;
7
+ readonly mitosis: import(".").TranspilerGenerator<Partial<import("./generators/mitosis").ToMitosisOptions>>;
8
+ readonly liquid: import(".").TranspilerGenerator<import("./generators/liquid").ToLiquidOptions>;
9
+ readonly react: import(".").TranspilerGenerator<Partial<import("./generators/react").ToReactOptions>>;
10
+ readonly reactNative: import(".").TranspilerGenerator<Partial<import("./generators/react-native").ToReactNativeOptions>>;
11
+ readonly solid: import(".").TranspilerGenerator<Partial<import("./generators/solid/types").ToSolidOptions>>;
12
+ readonly svelte: import(".").TranspilerGenerator<import("./generators/svelte/types").ToSvelteOptions>;
13
+ readonly swift: import(".").TranspilerGenerator<import(".").BaseTranspilerOptions>;
14
+ readonly template: import(".").TranspilerGenerator<import("./generators/template").ToTemplateOptions>;
15
+ readonly webcomponent: import(".").TranspilerGenerator<import("./generators/html").ToHtmlOptions>;
16
16
  readonly vue: (vueOptions?: Omit<import("./generators/vue").ToVueOptions, "vueVersion"> | undefined) => import(".").Transpiler<string>;
17
17
  readonly vue2: (vueOptions?: Omit<import("./generators/vue").ToVueOptions, "vueVersion"> | undefined) => import(".").Transpiler<string>;
18
18
  readonly vue3: (vueOptions?: Omit<import("./generators/vue").ToVueOptions, "vueVersion"> | undefined) => import(".").Transpiler<string>;
19
- readonly stencil: import(".").TranspilerGenerator<import("./generators/stencil").ToStencilOptions, string>;
20
- readonly qwik: import(".").TranspilerGenerator<import("./generators/qwik/component-generator").ToQwikOptions, string>;
21
- readonly marko: import(".").TranspilerGenerator<import("./generators/marko").ToMarkoOptions, string>;
22
- readonly preact: import(".").TranspilerGenerator<Partial<import("./generators/react").ToReactOptions>, string>;
23
- readonly lit: import(".").TranspilerGenerator<import("./generators/lit").ToLitOptions, string>;
24
- readonly rsc: import(".").TranspilerGenerator<Partial<import("./generators/react").ToReactOptions>, string>;
25
- readonly taro: import(".").TranspilerGenerator<Partial<import("./generators/react").ToReactOptions>, string>;
19
+ readonly stencil: import(".").TranspilerGenerator<import("./generators/stencil").ToStencilOptions>;
20
+ readonly qwik: import(".").TranspilerGenerator<import("./generators/qwik/component-generator").ToQwikOptions>;
21
+ readonly marko: import(".").TranspilerGenerator<import("./generators/marko").ToMarkoOptions>;
22
+ readonly preact: import(".").TranspilerGenerator<Partial<import("./generators/react").ToReactOptions>>;
23
+ readonly lit: import(".").TranspilerGenerator<import("./generators/lit").ToLitOptions>;
24
+ readonly rsc: import(".").TranspilerGenerator<Partial<import("./generators/react").ToReactOptions>>;
25
+ readonly taro: import(".").TranspilerGenerator<Partial<import("./generators/react").ToReactOptions>>;
26
26
  };
27
- export declare type Targets = keyof typeof targets;
27
+ export type Targets = keyof typeof targets;