yh-mobile-components 1.0.5 → 1.0.6
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/form/yhmCascader.vue +5 -0
- package/form/yhmRate.vue +5 -0
- package/form/yhmSignature.vue +5 -0
- package/form/yhmSlider.vue +5 -0
- package/form/yhmStepper.vue +5 -0
- package/index.ts +12 -0
- package/info/yhmList.vue +4 -0
- package/info/yhmTable.vue +21 -0
- package/package.json +1 -1
- package/types.ts +7 -0
package/form/yhmRate.vue
ADDED
package/index.ts
CHANGED
|
@@ -3,6 +3,7 @@ import yhmDropdownItem from "./info/yhmDropdownItem.vue";
|
|
|
3
3
|
import yhmTabs from "./info/yhmTabs.vue";
|
|
4
4
|
import yhmInfo from "./info/yhmInfo.vue";
|
|
5
5
|
import yhmInfoItem from "./info/yhmInfoItem.vue";
|
|
6
|
+
import yhmTable from "./info/yhmTable.vue";
|
|
6
7
|
import yhmForm from "./form/yhm-form.vue";
|
|
7
8
|
import yhmDatetime from "./form/yhmDatetime.vue";
|
|
8
9
|
import yhmRadio from "./form/yhmRadio.vue";
|
|
@@ -11,6 +12,11 @@ import yhmSelect from "./form/yhmSelect.vue";
|
|
|
11
12
|
import yhmInput from "./form/yhmInput.vue";
|
|
12
13
|
import yhmSwitch from "./form/yhmSwitch.vue";
|
|
13
14
|
import yhmPassword from "./form/yhmPassword.vue";
|
|
15
|
+
import yhmCascader from "./form/yhmCascader.vue";
|
|
16
|
+
import yhmRate from "./form/yhmRate.vue";
|
|
17
|
+
import yhmSignature from "./form/yhmSignature.vue";
|
|
18
|
+
import yhmSlider from "./form/yhmSlider.vue";
|
|
19
|
+
import yhmStepper from "./form/yhmStepper.vue";
|
|
14
20
|
import vant from "vant";
|
|
15
21
|
import "vant/lib/index.css";
|
|
16
22
|
import "yh-mobile-components/custom.scss";
|
|
@@ -22,6 +28,7 @@ export default {
|
|
|
22
28
|
app.component("yhm-tabs", yhmTabs);
|
|
23
29
|
app.component("yhm-info", yhmInfo);
|
|
24
30
|
app.component("yhm-info-item", yhmInfoItem);
|
|
31
|
+
app.component("yhm-table", yhmTable);
|
|
25
32
|
app.component("yhm-form", yhmForm);
|
|
26
33
|
app.component("yhm-datetime", yhmDatetime);
|
|
27
34
|
app.component("yhm-radio", yhmRadio);
|
|
@@ -30,6 +37,11 @@ export default {
|
|
|
30
37
|
app.component("yhm-select", yhmSelect);
|
|
31
38
|
app.component("yhm-switch", yhmSwitch);
|
|
32
39
|
app.component("yhm-password", yhmPassword);
|
|
40
|
+
app.component("yhm-cascader", yhmCascader);
|
|
41
|
+
app.component("yhm-rate", yhmRate);
|
|
42
|
+
app.component("yhm-signature", yhmSignature);
|
|
43
|
+
app.component("yhm-slider", yhmSlider);
|
|
44
|
+
app.component("yhm-stepper", yhmStepper);
|
|
33
45
|
app.use(vant);
|
|
34
46
|
},
|
|
35
47
|
};
|
package/info/yhmList.vue
CHANGED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<section class="yhm-table-container">
|
|
3
|
+
<table>
|
|
4
|
+
<colgroup>
|
|
5
|
+
<col />
|
|
6
|
+
</colgroup>
|
|
7
|
+
<tr></tr>
|
|
8
|
+
</table>
|
|
9
|
+
</section>
|
|
10
|
+
<talbe class="yhm-talbe-"></talbe>
|
|
11
|
+
</template>
|
|
12
|
+
<script setup lang="ts">
|
|
13
|
+
const props = withDefaults(
|
|
14
|
+
defineProps<{
|
|
15
|
+
data: any[];
|
|
16
|
+
columns: ColumnItem[];
|
|
17
|
+
}>(),
|
|
18
|
+
{}
|
|
19
|
+
);
|
|
20
|
+
</script>
|
|
21
|
+
<style lang="scss"></style>
|
package/package.json
CHANGED
package/types.ts
CHANGED
|
@@ -122,3 +122,10 @@ export interface ConfigFormItem {
|
|
|
122
122
|
/** 不同类型表单项的个性化配置 */
|
|
123
123
|
config: ConfigFormItem["type"] extends DateTimeType ? DatetimeConfig : ConfigFormItem["type"] extends "checkbox" ? CheckboxConfig : ConfigFormItem["type"] extends "radio" ? RadioConfig : ConfigFormItem["type"] extends "select" ? SelectConfig : ConfigFormItem["type"] extends "switch" ? SwitchConfig : {};
|
|
124
124
|
}
|
|
125
|
+
|
|
126
|
+
/** 表格单元格 */
|
|
127
|
+
export interface ColumnItem {
|
|
128
|
+
/** 表头名 */
|
|
129
|
+
label: string;
|
|
130
|
+
prop: string;
|
|
131
|
+
}
|