@faasjs/ant-design 0.0.3-beta.34 → 0.0.3-beta.35

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
@@ -106,6 +106,7 @@ function ConfigProvider({
106
106
  }) {
107
107
  const [values, setValues] = (0, import_react2.useState)(baseConfig);
108
108
  (0, import_react2.useEffect)(() => {
109
+ console.log(config);
109
110
  if (config.lang === "zh") {
110
111
  setValues((0, import_lodash_es.defaultsDeep)(config, {
111
112
  lang: "zh",
@@ -114,7 +115,7 @@ function ConfigProvider({
114
115
  Form: { submit: { text: zh.submit } }
115
116
  }, baseConfig));
116
117
  } else
117
- setValues(values);
118
+ setValues((0, import_lodash_es.defaultsDeep)(config, values));
118
119
  }, []);
119
120
  return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ConfigContext.Provider, {
120
121
  value: values,
@@ -963,7 +964,11 @@ var import_jsx_runtime = require("react/jsx-runtime");
963
964
  function Link(props) {
964
965
  var _a, _b, _c, _d;
965
966
  const { Link: Link2 } = useConfigContext();
966
- let style = Object.assign(Link2.style || {}, { cursor: "pointer" }, props.style || {});
967
+ let style = {
968
+ ...Link2.style || {},
969
+ cursor: "pointer",
970
+ ...props.style
971
+ };
967
972
  if (props.block)
968
973
  style = Object.assign({
969
974
  display: "block",
package/dist/index.mjs CHANGED
@@ -59,6 +59,7 @@ function ConfigProvider({
59
59
  }) {
60
60
  const [values, setValues] = useState(baseConfig);
61
61
  useEffect(() => {
62
+ console.log(config);
62
63
  if (config.lang === "zh") {
63
64
  setValues(defaultsDeep(config, {
64
65
  lang: "zh",
@@ -67,7 +68,7 @@ function ConfigProvider({
67
68
  Form: { submit: { text: zh.submit } }
68
69
  }, baseConfig));
69
70
  } else
70
- setValues(values);
71
+ setValues(defaultsDeep(config, values));
71
72
  }, []);
72
73
  return /* @__PURE__ */ jsx(ConfigContext.Provider, {
73
74
  value: values,
@@ -946,7 +947,11 @@ import { jsx as jsx10 } from "react/jsx-runtime";
946
947
  function Link(props) {
947
948
  var _a, _b, _c, _d;
948
949
  const { Link: Link2 } = useConfigContext();
949
- let style = Object.assign(Link2.style || {}, { cursor: "pointer" }, props.style || {});
950
+ let style = {
951
+ ...Link2.style || {},
952
+ cursor: "pointer",
953
+ ...props.style
954
+ };
950
955
  if (props.block)
951
956
  style = Object.assign({
952
957
  display: "block",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@faasjs/ant-design",
3
- "version": "0.0.3-beta.34",
3
+ "version": "0.0.3-beta.35",
4
4
  "license": "MIT",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",
@@ -28,7 +28,7 @@
28
28
  "lodash-es": "*",
29
29
  "react": "*",
30
30
  "react-dom": "*",
31
- "@faasjs/react": "^0.0.3-beta.34",
31
+ "@faasjs/react": "^0.0.3-beta.35",
32
32
  "react-router-dom": "*",
33
33
  "dayjs": "*"
34
34
  },