hy-app 0.1.4 → 0.1.5

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.
Files changed (102) hide show
  1. package/components/hy-address-picker/hy-address-picker.vue +20 -10
  2. package/components/hy-address-picker/props.ts +1 -3
  3. package/components/hy-address-picker/typing.d.ts +4 -11
  4. package/components/hy-avatar/typing.d.ts +1 -1
  5. package/components/hy-back-top/hy-back-top.vue +15 -1
  6. package/components/hy-back-top/props.ts +1 -6
  7. package/components/hy-back-top/typing.d.ts +4 -7
  8. package/components/hy-badge/typing.d.ts +1 -1
  9. package/components/hy-button/hy-button.vue +29 -12
  10. package/components/hy-button/props.ts +1 -2
  11. package/components/hy-button/typing.d.ts +4 -7
  12. package/components/hy-calendar/typing.d.ts +1 -1
  13. package/components/hy-card/typing.d.ts +1 -1
  14. package/components/hy-cell/hy-cell.vue +35 -6
  15. package/components/hy-cell/props.ts +2 -2
  16. package/components/hy-cell/typing.d.ts +8 -11
  17. package/components/hy-check-button/typing.d.ts +1 -1
  18. package/components/hy-checkbox/hy-checkbox.vue +3 -2
  19. package/components/hy-checkbox/props.ts +1 -1
  20. package/components/hy-checkbox/typing.d.ts +2 -2
  21. package/components/hy-count-down/typing.d.ts +1 -1
  22. package/components/hy-count-to/typing.d.ts +1 -3
  23. package/components/hy-datetime-picker/hy-datetime-picker.vue +18 -14
  24. package/components/hy-datetime-picker/props.ts +1 -3
  25. package/components/hy-datetime-picker/typing.d.ts +6 -13
  26. package/components/hy-divider/typing.d.ts +1 -1
  27. package/components/hy-dropdown/typing.d.ts +1 -1
  28. package/components/hy-dropdown-item/typing.d.ts +1 -3
  29. package/components/hy-empty/typing.d.ts +1 -1
  30. package/components/hy-float-button/typing.d.ts +1 -1
  31. package/components/hy-folding-panel/typing.d.ts +1 -1
  32. package/components/hy-form/hy-form.vue +189 -27
  33. package/components/hy-form/index.scss +1 -1
  34. package/components/hy-form/props.ts +0 -2
  35. package/components/hy-form/typing.d.ts +25 -7
  36. package/components/hy-grid/hy-grid.vue +16 -5
  37. package/components/hy-grid/props.ts +1 -3
  38. package/components/hy-grid/typing.d.ts +13 -16
  39. package/components/hy-icon/hy-icon.vue +6 -10
  40. package/components/hy-icon/typing.d.ts +1 -1
  41. package/components/hy-image/typing.d.ts +1 -1
  42. package/components/hy-input/hy-input.vue +27 -16
  43. package/components/hy-input/props.ts +2 -4
  44. package/components/hy-input/typing.d.ts +5 -12
  45. package/components/hy-line/typing.d.ts +1 -1
  46. package/components/hy-line-progress/typing.d.ts +1 -1
  47. package/components/hy-list/typing.d.ts +1 -1
  48. package/components/hy-loading/typing.d.ts +1 -2
  49. package/components/hy-login/hy-login.vue +267 -265
  50. package/components/hy-login/typing.d.ts +1 -1
  51. package/components/hy-modal/typing.d.ts +1 -1
  52. package/components/hy-navbar/typing.d.ts +1 -2
  53. package/components/hy-notice-bar/typing.d.ts +1 -1
  54. package/components/hy-number-step/hy-number-step.vue +25 -10
  55. package/components/hy-number-step/typing.d.ts +8 -3
  56. package/components/hy-overlay/typing.d.ts +1 -1
  57. package/components/hy-parse/typing.d.ts +1 -1
  58. package/components/hy-picker/hy-picker.vue +18 -8
  59. package/components/hy-picker/props.ts +1 -4
  60. package/components/hy-picker/typing.d.ts +4 -15
  61. package/components/hy-popup/typing.d.ts +1 -1
  62. package/components/hy-price/typing.d.ts +1 -1
  63. package/components/hy-qrcode/typing.d.ts +1 -1
  64. package/components/hy-radio/hy-radio.vue +6 -2
  65. package/components/hy-radio/props.ts +1 -1
  66. package/components/hy-radio/typing.d.ts +2 -2
  67. package/components/hy-rate/typing.d.ts +1 -1
  68. package/components/hy-read-more/typing.d.ts +1 -1
  69. package/components/hy-scroll-list/typing.d.ts +1 -1
  70. package/components/hy-search/hy-search.vue +12 -3
  71. package/components/hy-search/props.ts +1 -3
  72. package/components/hy-search/typing.d.ts +6 -13
  73. package/components/hy-slider/typing.d.ts +1 -1
  74. package/components/hy-status-bar/typing.d.ts +1 -1
  75. package/components/hy-steps/typing.d.ts +1 -1
  76. package/components/hy-submitBar/typing.d.ts +1 -1
  77. package/components/hy-subsection/typing.d.ts +1 -1
  78. package/components/hy-swipe-action/typing.d.ts +1 -1
  79. package/components/hy-swiper/typing.d.ts +2 -5
  80. package/components/hy-switch/hy-switch.vue +11 -2
  81. package/components/hy-switch/props.ts +0 -1
  82. package/components/hy-switch/typing.d.ts +3 -2
  83. package/components/hy-tabs/typing.d.ts +1 -1
  84. package/components/hy-tag/hy-tag.vue +25 -15
  85. package/components/hy-tag/props.ts +1 -2
  86. package/components/hy-tag/typing.d.ts +3 -10
  87. package/components/hy-text/typing.d.ts +1 -1
  88. package/components/hy-textarea/hy-textarea.vue +1 -1
  89. package/components/hy-textarea/typing.d.ts +2 -2
  90. package/components/hy-toast/hy-toast.vue +1 -1
  91. package/components/hy-toast/typing.d.ts +1 -1
  92. package/components/hy-tooltip/typing.d.ts +1 -1
  93. package/components/hy-transition/typing.d.ts +1 -1
  94. package/components/hy-upload/typing.d.ts +1 -1
  95. package/components/hy-warn/typing.d.ts +1 -1
  96. package/components/hy-waterfall/typing.d.ts +1 -3
  97. package/components/index.ts +2 -2
  98. package/package.json +3 -3
  99. package/store/userInfo.ts +25 -25
  100. package/theme.scss +1 -1
  101. package/typing/modules/common.d.ts +1 -1
  102. package/typing/modules/form.ts +29 -14
@@ -6,13 +6,22 @@
6
6
  <view class="hy-input__content">
7
7
  <view
8
8
  class="hy-input__content__prefix-icon"
9
- v-if="prefixIcon || $slots.prefix"
9
+ v-if="prefixIcon?.name || $slots.prefix"
10
10
  >
11
11
  <slot name="prefix">
12
12
  <HyIcon
13
- :name="prefixIcon"
14
- size="18"
15
- :customStyle="prefixIconStyle"
13
+ :name="prefixIcon?.name"
14
+ :size="prefixIcon?.size"
15
+ :color="prefixIcon?.color"
16
+ :bold="prefixIcon?.bold"
17
+ :customPrefix="prefixIcon?.customPrefix"
18
+ :imgMode="prefixIcon?.imgMode"
19
+ :width="prefixIcon?.width"
20
+ :height="prefixIcon?.height"
21
+ :top="prefixIcon?.top"
22
+ :stop="prefixIcon?.stop"
23
+ :round="prefixIcon?.round"
24
+ :customStyle="prefixIcon?.customStyle"
16
25
  ></HyIcon>
17
26
  </slot>
18
27
  </view>
@@ -65,13 +74,22 @@
65
74
  </view>
66
75
  <view
67
76
  class="hy-input__content__subfix-icon"
68
- v-if="suffixIcon || $slots.suffix"
77
+ v-if="suffixIcon?.name || $slots.suffix"
69
78
  >
70
79
  <slot name="suffix">
71
80
  <HyIcon
72
- :name="suffixIcon"
73
- size="18"
74
- :customStyle="suffixIconStyle"
81
+ :name="suffixIcon?.name"
82
+ :size="suffixIcon?.size"
83
+ :color="suffixIcon?.color"
84
+ :bold="suffixIcon?.bold"
85
+ :customPrefix="suffixIcon?.customPrefix"
86
+ :imgMode="suffixIcon?.imgMode"
87
+ :width="suffixIcon?.width"
88
+ :height="suffixIcon?.height"
89
+ :top="suffixIcon?.top"
90
+ :stop="suffixIcon?.stop"
91
+ :round="suffixIcon?.round"
92
+ :customStyle="suffixIcon?.customStyle"
75
93
  ></HyIcon>
76
94
  </slot>
77
95
  </view>
@@ -312,17 +330,10 @@ const onClear = () => {
312
330
  * 无法触发u-form-item的点击事件,这里通过手动调用u-form-item的方法进行触发
313
331
  */
314
332
  const clickHandler = () => {
333
+ // 隐藏键盘
315
334
  if (disabled.value || readonly.value) {
316
335
  uni.hideKeyboard();
317
336
  }
318
- // #ifdef APP-NVUE
319
- if (os() === "android") {
320
- const formItem = $parent.call(this, "u-form-item");
321
- if (formItem) {
322
- formItem.clickHandler();
323
- }
324
- }
325
- // #endif
326
337
  };
327
338
  </script>
328
339
 
@@ -27,10 +27,8 @@ const defaultProps: IProps = {
27
27
  inputAlign: "left",
28
28
  fontSize: "15px",
29
29
  color: "#303133",
30
- prefixIcon: "",
31
- prefixIconStyle: {},
32
- suffixIcon: "",
33
- suffixIconStyle: {},
30
+ prefixIcon: {},
31
+ suffixIcon: {},
34
32
  border: "surround",
35
33
  readonly: false,
36
34
  shape: "square",
@@ -1,6 +1,7 @@
1
1
  import type { CSSProperties } from "vue";
2
+ import type HyIconProps from "../hy-icon/typing";
2
3
 
3
- export default interface IProps {
4
+ export default interface HyInputProps {
4
5
  /**
5
6
  * @description 输入的值
6
7
  * */
@@ -96,7 +97,7 @@ export default interface IProps {
96
97
  /**
97
98
  * @description 输入框内容对齐方式( 默认 'left' )
98
99
  * */
99
- inputAlign?: "center" | HyApp.LeftRightType;
100
+ inputAlign?: HyApp.RowCenterType;
100
101
  /**
101
102
  * @description 输入框字体的大小 ( 默认 '15px' )
102
103
  * */
@@ -108,19 +109,11 @@ export default interface IProps {
108
109
  /**
109
110
  * @description 输入框前置图标
110
111
  * */
111
- prefixIcon?: string;
112
- /**
113
- * @description 前置图标样式,对象或字符串
114
- * */
115
- prefixIconStyle?: CSSProperties;
112
+ prefixIcon?: Partial<HyIconProps>;
116
113
  /**
117
114
  * @description 输入框后置图标
118
115
  * */
119
- suffixIcon?: string;
120
- /**
121
- * @description 后置图标样式,对象或字符串
122
- * */
123
- suffixIconStyle?: CSSProperties;
116
+ suffixIcon?: Partial<HyIconProps>;
124
117
  /**
125
118
  * @description 边框类型,surround-四周边框,bottom-底部边框,none-无边框 ( 默认 'surround' )
126
119
  * */
@@ -1,6 +1,6 @@
1
1
  import type { CSSProperties } from "vue";
2
2
 
3
- export default interface IProps {
3
+ export default interface HyLineProps {
4
4
  /**
5
5
  * @description 线条的颜色 ( 默认 '#d6d7d9' )
6
6
  * */
@@ -1,6 +1,6 @@
1
1
  import type { CSSProperties } from "vue";
2
2
 
3
- export default interface IProps {
3
+ export default interface HyLineProgressProps {
4
4
  /**
5
5
  * @description 激活部分的颜色 ( 默认 '#19be6b' )
6
6
  * */
@@ -1,4 +1,4 @@
1
- export default interface IProps {
1
+ export default interface HyListProps {
2
2
  /**
3
3
  * @description 数据列表
4
4
  * */
@@ -1,7 +1,6 @@
1
1
  import type { CSSProperties } from "vue";
2
- import type { LoadingMode } from "@/package/typing/modules/common";
3
2
 
4
- export default interface IProps {
3
+ export default interface HyLoadingProps {
5
4
  /**
6
5
  * @description 是否显示组件 (默认 true)
7
6
  * */