@yoyaflow/yoya-ui 0.3.0 → 0.3.2
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/README.md +46 -25
- package/README.zh-CN.md +46 -25
- package/dist/yoya-ui.umd.js +2 -2
- package/dist/yoya.core.js +104 -80
- package/dist/yoya.echart.js +12 -5
- package/dist/yoya.ssr.js +559 -536
- package/dist/yoya.ui.js +2336 -2304
- package/package.json +1 -1
- package/types/core.d.ts +24 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@yoyaflow/yoya-ui",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.2",
|
|
4
4
|
"description": "A browser-native JS UI library with declarative HTML authoring: component library, router, i18n, theming and layout, works with or without a build tool, SSR-ready.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"private": false,
|
package/types/core.d.ts
CHANGED
|
@@ -537,6 +537,30 @@ export function resolveYoyaMode(): 'light' | 'dark';
|
|
|
537
537
|
export function setYoyaTheme(name?: string, options?: ThemePersistOptions): string;
|
|
538
538
|
export function getYoyaTheme(): string;
|
|
539
539
|
|
|
540
|
+
/** Binds a document-level event listener (outside click, drag, Escape, scroll). */
|
|
541
|
+
export function bindDocumentEvent(
|
|
542
|
+
type: string,
|
|
543
|
+
handler: (event: Event) => void,
|
|
544
|
+
options?: AddEventListenerOptions | boolean
|
|
545
|
+
): () => void;
|
|
546
|
+
|
|
547
|
+
/** Removes a document-level event listener. */
|
|
548
|
+
export function unbindDocumentEvent(
|
|
549
|
+
type: string,
|
|
550
|
+
handler: (event: Event) => void,
|
|
551
|
+
options?: AddEventListenerOptions | boolean
|
|
552
|
+
): void;
|
|
553
|
+
|
|
554
|
+
/** Binds a window-level global listener (scroll / resize / popstate). */
|
|
555
|
+
export function bindWindowEvent(
|
|
556
|
+
type: string,
|
|
557
|
+
handler: (event: Event) => void,
|
|
558
|
+
options?: AddEventListenerOptions | boolean
|
|
559
|
+
): () => void;
|
|
560
|
+
|
|
561
|
+
/** Injects a <style> into <head>; dataAttribute is used for dedup and identification. */
|
|
562
|
+
export function injectDocumentStyle(styleText: string, dataAttribute?: string | null): HTMLStyleElement | null;
|
|
563
|
+
|
|
540
564
|
/** Initializes theme mode/name from explicit values or persisted storage. */
|
|
541
565
|
export function initYoyaTheme(options?: InitYoyaThemeOptions): {
|
|
542
566
|
mode: YoyaMode;
|