vasille-web 4.1.1 → 4.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.
@@ -4,7 +4,8 @@ import type { StyleProps } from "../spec/css.d.ts";
4
4
  import type { ScreenProps } from "vasille-router";
5
5
  import type { Router } from "vasille-router/web-router";
6
6
 
7
- export type { StyleProps } from "../spec/css.d.ts";
7
+ export type { RawStyleProps as StyleProps } from "../spec/css.d.ts";
8
+ export type ClassItem = string | Record<string, boolean> | false;
8
9
  export type { FallbackScreenProps, ErrorScreenProps } from "vasille-router";
9
10
 
10
11
  /** Set a handler for component errors */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vasille-web",
3
- "version": "4.1.1",
3
+ "version": "4.1.3",
4
4
  "description": "The same framework which is designed to build bulletproof frontends.",
5
5
  "main": "index.js",
6
6
  "types": "./index.d.ts",
package/types/index.d.ts CHANGED
@@ -2,7 +2,8 @@ import { Fragment } from "vasille";
2
2
  import { StyleProps } from "../spec/css.js";
3
3
  import { TagOptions } from "vasille/web-runner";
4
4
  import { WebRouterInitialization } from "vasille-router/web-router";
5
- export type { StyleProps } from "../spec/css.js";
5
+ export type { RawStyleProps as StyleProps } from "../spec/css.js";
6
+ export type { ClassItem } from "./jsx-runtime.js";
6
7
  export { view, view as component, view as compose, forward, backward, ensure, ref, expr, expr as bind, expr as calculate, expr as watch, set, Debug, Delay, For, Slot, Watch, awaited, store, model, setModel, mapModel, arrayModel, Switch, setErrorHandler, match, } from "vasille-jsx";
7
8
  export { type QueryParams, type ScreenProps, type RouteParameters, screen, screen as page, type FallbackScreenProps, type ErrorScreenProps, } from "vasille-router";
8
9
  export { Router, type WebRouterInitialization, type NavigationMode, routeApp } from "vasille-router/web-router";
@@ -6,9 +6,10 @@ type prefixedObject<T, P extends string> = {
6
6
  type EventHandlers<T> = {
7
7
  [K in keyof T]: T[K] | [T[K], boolean | AddEventListenerOptions];
8
8
  };
9
+ export type ClassItem = string | Record<string, boolean> | false;
9
10
  type HtmlInput<K extends keyof HTMLElementTagNameMap & keyof HtmlTagMap> = {
10
11
  callback?: (node: HTMLElementTagNameMap[K]) => unknown;
11
- class?: (string | Record<string, boolean> | false)[] | string;
12
+ class?: ClassItem[] | string;
12
13
  style?: RawStyleProps | string;
13
14
  slot?: unknown;
14
15
  } & Partial<HtmlTagMap[K]["attrs"]> & prefixedObject<EventHandlers<HtmlTagMap[K]["events"]>, "on"> & Partial<prefixedObject<HtmlTagMap[K]["props"], "bind:">>;