@archbase/core 4.0.0 → 4.0.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/dist/index.js CHANGED
@@ -103,7 +103,26 @@ function useArchbaseApp() {
103
103
  return context;
104
104
  }
105
105
 
106
- const CustomShowErrorModal = (props) => /* @__PURE__ */ jsx("div", { children: props.innerProps?.children });
106
+ const CustomShowErrorModal = (props) => {
107
+ const { context, id, innerProps } = props;
108
+ return /* @__PURE__ */ jsxs("div", { children: [
109
+ /* @__PURE__ */ jsx("div", { style: { color: "red", fontWeight: "bold", marginBottom: 8 }, children: innerProps?.message }),
110
+ innerProps?.detailMessage && /* @__PURE__ */ jsx("div", { style: { fontSize: "0.85em", color: "#666", marginBottom: 8 }, children: innerProps.detailMessage }),
111
+ /* @__PURE__ */ jsx(
112
+ "button",
113
+ {
114
+ type: "button",
115
+ onClick: () => {
116
+ if (innerProps?.onConfirm)
117
+ innerProps.onConfirm();
118
+ context?.closeModal?.(id);
119
+ },
120
+ style: { marginTop: 8 },
121
+ children: "Ok"
122
+ }
123
+ )
124
+ ] });
125
+ };
107
126
  const DefaultNavigationProvider = ({ children }) => /* @__PURE__ */ jsx(Fragment, { children });
108
127
  const ArchbaseAppContext = createContext({
109
128
  user: null,