mtxuilib 0.1.83 → 0.1.85

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.
@@ -24,9 +24,7 @@ export interface AppSliceState extends AppSliceProps {
24
24
  setOpenFab: (openFab: boolean) => void;
25
25
  cmdHandler: (name: string, params?: any) => boolean;
26
26
  }
27
- export declare const createAppSlice: StateCreator<AppSliceState, [
28
- ], [
29
- ], AppSliceState>;
27
+ export declare const createAppSlice: StateCreator<AppSliceState, [], [], AppSliceState>;
30
28
  type mtappState = AppSliceState;
31
29
  export declare const gomtmContext: import("react").Context<(Omit<Omit<Omit<import("zustand").StoreApi<AppSliceState>, "persist"> & {
32
30
  persist: {
@@ -42,13 +42,7 @@ const createMtAppStore = (initProps) => {
42
42
  },
43
43
  partialize: (state) => {
44
44
  return Object.fromEntries(Object.entries(state).filter(([key]) => {
45
- return ![
46
- "cookieStr",
47
- "children",
48
- "openFab",
49
- "userInfo",
50
- "_hasHydrated",
51
- ].includes(key);
45
+ return !["cookieStr", "children", "openFab", "userInfo", "_hasHydrated"].includes(key);
52
46
  }));
53
47
  },
54
48
  }));
@@ -57,7 +51,7 @@ export const gomtmContext = createContext(null);
57
51
  export const MtAppProvider = (props) => {
58
52
  const { children, ...etc } = props;
59
53
  const mystore = useMemo(() => createMtAppStore(etc), [etc]);
60
- return (_jsx(gomtmContext.Provider, { value: mystore, children: children }));
54
+ return _jsx(gomtmContext.Provider, { value: mystore, children: children });
61
55
  };
62
56
  const DEFAULT_USE_SHALLOW = true;
63
57
  export function useMtapp(selector) {
@@ -0,0 +1,7 @@
1
+ /// <reference types="react" />
2
+ export declare const LzMtEditor: import("react").ComponentType<{
3
+ content?: string | import("@tiptap/core").JSONContent | undefined;
4
+ } & import("./MtEditor").MtEditorProps & {
5
+ onValueChange?: ((content: any) => void) | undefined;
6
+ content?: import("@tiptap/core").JSONContent | null | undefined;
7
+ }>;
@@ -0,0 +1,7 @@
1
+ "use client";
2
+ import dynamic from "next/dynamic";
3
+ import { SkeletonInput } from "../ui-mt/skeleton/SkeletonInput";
4
+ export const LzMtEditor = dynamic(() => import("./MtEditor").then((x) => x.MtEditor), {
5
+ ssr: false,
6
+ loading: SkeletonInput,
7
+ });
@@ -10,7 +10,7 @@ export const TaskStatusInput = (props) => {
10
10
  const value2 = useMemo(() => {
11
11
  return taskStatusSchema.parse(form.getValues()[name]);
12
12
  }, [form]);
13
- return (_jsxs("div", { className: "flex gap-2", children: ["(", value2, "):", (value2 == TASK_STATUS.Init || value2 == TASK_STATUS.Paused) && (_jsx(MtButton, { onClick: () => {
13
+ return (_jsxs("div", { className: "flex gap-1 border shadow-sm", children: [(value2 == TASK_STATUS.Init || value2 == TASK_STATUS.Paused) && (_jsx(MtButton, { onClick: () => {
14
14
  form.setValue(name, TASK_STATUS.Padding);
15
15
  }, children: "start" })), value2 == TASK_STATUS.Terminated && (_jsx(MtButton, { onClick: () => {
16
16
  form.setValue(name, TASK_STATUS.Padding);
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "mtxuilib",
3
3
  "private": false,
4
- "version": "0.1.83",
4
+ "version": "0.1.85",
5
5
  "publishConfig": {
6
6
  "access": "public"
7
7
  },
@@ -1 +0,0 @@
1
- export declare function DemoReactUse(): import("react/jsx-runtime").JSX.Element;
@@ -1,17 +0,0 @@
1
- 'use client';
2
- import { jsx as _jsx } from "react/jsx-runtime";
3
- import { use, useMemo } from "react";
4
- let v = null;
5
- const myfetch = async () => {
6
- if (v) {
7
- return v;
8
- }
9
- v = await fetch("https://reqres.in/api/users/1?delay=1").then(x => x.json());
10
- return v;
11
- };
12
- export function DemoReactUse() {
13
- const data = useMemo(() => {
14
- return use(myfetch());
15
- }, []);
16
- return (_jsx("div", { className: " max-h24 overflow-scroll bg-red-200 p-2", children: _jsx("pre", { children: JSON.stringify(data, null, 2) }) }));
17
- }