@uzum-tech/ui 2.0.3 → 2.0.4

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.
@@ -1,4 +1,4 @@
1
- import { computed, defineComponent, getCurrentInstance, h, ref } from 'vue';
1
+ import { defineComponent, getCurrentInstance, h, ref } from 'vue';
2
2
  import { configProviderInjectionKey } from "../config-provider/src/context.mjs";
3
3
  import useExposeProxy from "./composable/use-expose-proxy.mjs";
4
4
  function findConfig(instance) {
@@ -22,18 +22,20 @@ export function wrap(component) {
22
22
  const instance = getCurrentInstance();
23
23
  const config = instance ? findConfig(instance) : null;
24
24
  const componentRef = ref(null);
25
- const mergedProps = computed(() => {
26
- var _a, _b, _c;
27
- if (!config) return props;
28
- const defaults = (_c = (_b = (_a = config.mergedComponentPropsRef) === null || _a === void 0 ? void 0 : _a.value) === null || _b === void 0 ? void 0 : _b[component.name]) !== null && _c !== void 0 ? _c : {};
29
- return Object.assign(Object.assign({}, defaults), props);
30
- });
31
25
  if (ctx.expose) {
32
26
  ctx.expose(useExposeProxy(componentRef));
33
27
  }
34
- return () => h(component, Object.assign(Object.assign({
35
- ref: componentRef
36
- }, mergedProps.value), ctx.attrs), ctx.slots);
28
+ return () => {
29
+ var _a, _b, _c;
30
+ let finalProps = props;
31
+ if (config) {
32
+ const defaults = (_c = (_b = (_a = config.mergedComponentPropsRef) === null || _a === void 0 ? void 0 : _a.value) === null || _b === void 0 ? void 0 : _b[component.name]) !== null && _c !== void 0 ? _c : {};
33
+ finalProps = Object.assign(Object.assign({}, defaults), props);
34
+ }
35
+ return h(component, Object.assign(Object.assign({
36
+ ref: componentRef
37
+ }, finalProps), ctx.attrs), ctx.slots);
38
+ };
37
39
  }
38
40
  });
39
41
  wrapped.__wrapped__ = true;
package/es/version.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- declare const _default: "2.0.3";
1
+ declare const _default: "2.0.4";
2
2
  export default _default;
package/es/version.mjs CHANGED
@@ -1 +1 @@
1
- export default '2.0.3';
1
+ export default '2.0.4';
@@ -30,17 +30,18 @@ function wrap(component) {
30
30
  const instance = (0, vue_1.getCurrentInstance)();
31
31
  const config = instance ? findConfig(instance) : null;
32
32
  const componentRef = (0, vue_1.ref)(null);
33
- const mergedProps = (0, vue_1.computed)(() => {
34
- var _a, _b, _c;
35
- if (!config)
36
- return props;
37
- const defaults = (_c = (_b = (_a = config.mergedComponentPropsRef) === null || _a === void 0 ? void 0 : _a.value) === null || _b === void 0 ? void 0 : _b[component.name]) !== null && _c !== void 0 ? _c : {};
38
- return Object.assign(Object.assign({}, defaults), props);
39
- });
40
33
  if (ctx.expose) {
41
34
  ctx.expose((0, use_expose_proxy_1.default)(componentRef));
42
35
  }
43
- return () => (0, vue_1.h)(component, Object.assign(Object.assign({ ref: componentRef }, mergedProps.value), ctx.attrs), ctx.slots);
36
+ return () => {
37
+ var _a, _b, _c;
38
+ let finalProps = props;
39
+ if (config) {
40
+ const defaults = (_c = (_b = (_a = config.mergedComponentPropsRef) === null || _a === void 0 ? void 0 : _a.value) === null || _b === void 0 ? void 0 : _b[component.name]) !== null && _c !== void 0 ? _c : {};
41
+ finalProps = Object.assign(Object.assign({}, defaults), props);
42
+ }
43
+ return (0, vue_1.h)(component, Object.assign(Object.assign({ ref: componentRef }, finalProps), ctx.attrs), ctx.slots);
44
+ };
44
45
  }
45
46
  });
46
47
  wrapped.__wrapped__ = true;
package/lib/version.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- declare const _default: "2.0.3";
1
+ declare const _default: "2.0.4";
2
2
  export default _default;
package/lib/version.js CHANGED
@@ -1,3 +1,3 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.default = '2.0.3';
3
+ exports.default = '2.0.4';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@uzum-tech/ui",
3
- "version": "2.0.3",
3
+ "version": "2.0.4",
4
4
  "description": "A Vue 3 Component Library. Fairly Complete, Theme Customizable, Uses TypeScript, Fast",
5
5
  "author": {
6
6
  "name": "KapitalLab",
package/web-types.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "$schema": "https://raw.githubusercontent.com/JetBrains/web-types/master/schema/web-types.json",
3
3
  "framework": "vue",
4
4
  "name": "@uzum-tech/ui",
5
- "version": "2.0.3",
5
+ "version": "2.0.4",
6
6
  "js-types-syntax": "typescript",
7
7
  "contributions": {
8
8
  "html": {