@stsdti/funky-ui-kit 1.7.3 → 1.7.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.
@@ -13410,7 +13410,7 @@ function useAppFormElement(props2, attributes) {
13410
13410
  return props2.name ?? props2.label ?? props2.dataVvAs;
13411
13411
  });
13412
13412
  const computedPlaceHolder = computed(() => {
13413
- return props2.placeholder ?? props2.label ?? props2.name;
13413
+ return props2.placeholder ?? props2.label;
13414
13414
  });
13415
13415
  const formElementProps = computed(() => {
13416
13416
  return {
@@ -27957,12 +27957,12 @@ function _sfc_render$1(_ctx, _cache2, $props, $setup, $data, $options) {
27957
27957
  ]);
27958
27958
  }
27959
27959
  const AppColorPicker = /* @__PURE__ */ _export_sfc(_sfc_main$1i, [["render", _sfc_render$1]]);
27960
- const _hoisted_1$W = ["disabled", "name", "placeholder", "type"];
27961
- const _hoisted_2$G = {
27962
- key: 0,
27960
+ const _hoisted_1$W = { class: "flex-center-vertical form-control p-0" };
27961
+ const _hoisted_2$G = ["disabled", "name", "placeholder", "type"];
27962
+ const _hoisted_3$r = {
27963
+ key: 1,
27963
27964
  class: "app-number-spinners"
27964
27965
  };
27965
- const _hoisted_3$r = { class: "form-control-feedback-icon" };
27966
27966
  const _sfc_main$1h = {
27967
27967
  __name: "AppInput",
27968
27968
  props: /* @__PURE__ */ mergeModels({
@@ -27985,6 +27985,10 @@ const _sfc_main$1h = {
27985
27985
  let modelValue = useModel(__props, "modelValue");
27986
27986
  const props2 = __props;
27987
27987
  const emits = __emit;
27988
+ const clearStyle = computed(() => ({
27989
+ "margin-right": isTypeNumber.value ? "2px" : "8px"
27990
+ }));
27991
+ const isTypeNumber = computed(() => props2.type === "number");
27988
27992
  const { formElementProps, computedName, computedPlaceHolder } = useAppFormElement(props2);
27989
27993
  const attrs = useAttrs();
27990
27994
  const inputAttrs = computed(() => {
@@ -28024,12 +28028,12 @@ const _sfc_main$1h = {
28024
28028
  }
28025
28029
  modelValue.value = val;
28026
28030
  };
28027
- const computedClass = computed(() => {
28031
+ computed(() => {
28028
28032
  return {
28029
- "form-control": true,
28030
- "disabled-element": props2.disabled,
28031
- "app-input--no-padding": !props2.isClearable || props2.disabled,
28032
- "app-input--has-spinners": props2.type === "number"
28033
+ // 'form-control': true,
28034
+ // 'disabled-element': props.disabled,
28035
+ // 'app-input--no-padding': !props.isClearable || props.disabled,
28036
+ // 'app-input--has-spinners': props.type === 'number'
28033
28037
  };
28034
28038
  });
28035
28039
  __expose({
@@ -28042,48 +28046,48 @@ const _sfc_main$1h = {
28042
28046
  renderSlot(_ctx.$slots, "help-block", {}, void 0, true)
28043
28047
  ]),
28044
28048
  default: withCtx(() => [
28045
- withDirectives(createElementVNode("input", mergeProps({
28046
- ref_key: "inputElement",
28047
- ref: inputElement,
28048
- "onUpdate:modelValue": _cache2[0] || (_cache2[0] = ($event) => isRef(modelValue) ? modelValue.value = $event : modelValue = $event),
28049
- disabled: _ctx.disabled,
28050
- name: unref(computedName),
28051
- placeholder: unref(computedPlaceHolder),
28052
- type: __props.type,
28053
- class: computedClass.value
28054
- }, inputAttrs.value, {
28055
- onBlur,
28056
- onKeyup: withKeys(onSubmit, ["enter"])
28057
- }), null, 16, _hoisted_1$W), [
28058
- [vModelDynamic, unref(modelValue)]
28059
- ]),
28060
- __props.type === "number" && !props2.disabled ? (openBlock(), createElementBlock("div", _hoisted_2$G, [
28061
- createElementVNode("div", {
28062
- class: "spinner-btn spinner-up",
28063
- onClick: withModifiers(increment, ["stop"])
28064
- }, [
28065
- createVNode(unref(IconCaretUpFilled), { size: 14 })
28049
+ createElementVNode("div", _hoisted_1$W, [
28050
+ withDirectives(createElementVNode("input", mergeProps({
28051
+ ref_key: "inputElement",
28052
+ ref: inputElement,
28053
+ "onUpdate:modelValue": _cache2[0] || (_cache2[0] = ($event) => isRef(modelValue) ? modelValue.value = $event : modelValue = $event),
28054
+ disabled: _ctx.disabled,
28055
+ name: unref(computedName),
28056
+ placeholder: unref(computedPlaceHolder),
28057
+ type: __props.type,
28058
+ class: "input-empty no-spinner flex-1 p-1"
28059
+ }, inputAttrs.value, {
28060
+ onBlur,
28061
+ onKeyup: withKeys(onSubmit, ["enter"])
28062
+ }), null, 16, _hoisted_2$G), [
28063
+ [vModelDynamic, unref(modelValue)]
28066
28064
  ]),
28067
- createElementVNode("div", {
28068
- class: "spinner-btn spinner-down",
28069
- onClick: withModifiers(decrement, ["stop"])
28065
+ __props.isClearable && unref(modelValue) && !props2.disabled ? (openBlock(), createElementBlock("div", {
28066
+ key: 0,
28067
+ style: normalizeStyle(clearStyle.value)
28070
28068
  }, [
28071
- createVNode(unref(IconCaretDownFilled), { size: 14 })
28072
- ])
28073
- ])) : createCommentVNode("", true),
28074
- __props.isClearable && unref(modelValue) && !props2.disabled ? (openBlock(), createElementBlock("div", {
28075
- key: 1,
28076
- class: normalizeClass(["form-control-feedback", "form-control-feedback-end", { "has-spinners-clear-icon": __props.type === "number" }])
28077
- }, [
28078
- createElementVNode("div", _hoisted_3$r, [
28079
28069
  withDirectives(createElementVNode("i", {
28080
28070
  class: "ph-x-circle app-cross-icon",
28081
28071
  onClick: withModifiers(clearOptions, ["stop"])
28082
28072
  }, null, 512), [
28083
28073
  [_directive_tippy, "Ștergeți opțiunile selectate"]
28084
28074
  ])
28085
- ])
28086
- ], 2)) : createCommentVNode("", true)
28075
+ ], 4)) : createCommentVNode("", true),
28076
+ isTypeNumber.value && !props2.disabled ? (openBlock(), createElementBlock("div", _hoisted_3$r, [
28077
+ createElementVNode("div", {
28078
+ class: "spinner-btn spinner-up no-select cursor-pointer",
28079
+ onClick: withModifiers(increment, ["stop"])
28080
+ }, [
28081
+ createVNode(unref(IconCaretUpFilled), { size: 14 })
28082
+ ]),
28083
+ createElementVNode("div", {
28084
+ class: "spinner-btn spinner-down no-select cursor-pointer",
28085
+ onClick: withModifiers(decrement, ["stop"])
28086
+ }, [
28087
+ createVNode(unref(IconCaretDownFilled), { size: 14 })
28088
+ ])
28089
+ ])) : createCommentVNode("", true)
28090
+ ])
28087
28091
  ]),
28088
28092
  _: 2
28089
28093
  }, [
@@ -28099,7 +28103,7 @@ const _sfc_main$1h = {
28099
28103
  };
28100
28104
  }
28101
28105
  };
28102
- const AppInput = /* @__PURE__ */ _export_sfc(_sfc_main$1h, [["__scopeId", "data-v-f53e2b8e"]]);
28106
+ const AppInput = /* @__PURE__ */ _export_sfc(_sfc_main$1h, [["__scopeId", "data-v-5976c38e"]]);
28103
28107
  const _hoisted_1$V = {
28104
28108
  key: 0,
28105
28109
  class: "app-link__label"