@winchsa/ui 0.1.27 → 0.1.29

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.
@@ -7,6 +7,7 @@ type __VLS_Props = {
7
7
  id?: string | number;
8
8
  title?: string;
9
9
  modelValue: ChechboxModel[];
10
+ vertical?: boolean;
10
11
  };
11
12
  declare const __VLS_export: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
12
13
  "update:modelValue": (value: ChechboxModel[]) => any;
@@ -5,7 +5,8 @@ import AppCard from "./AppCard.vue";
5
5
  const props = defineProps({
6
6
  id: { type: [String, Number], required: false, default: "" },
7
7
  title: { type: String, required: false, default: "" },
8
- modelValue: { type: Array, required: true, default: () => [] }
8
+ modelValue: { type: Array, required: true, default: () => [] },
9
+ vertical: { type: Boolean, required: false, default: false }
9
10
  });
10
11
  const data = reactive({
11
12
  selectedAll: false,
@@ -44,7 +45,12 @@ function getItemOnChange() {
44
45
  <template>
45
46
  <AppCard class="h-100">
46
47
  <!-- title card -->
47
- <VCardItem class="text-center">
48
+ <VCardItem
49
+ class="text-center"
50
+ :class="{
51
+ 'mb-0 pb-0': vertical
52
+ }"
53
+ >
48
54
  <div class="d-flex justify-space-between w-100">
49
55
  <h3 class="fw-bold">
50
56
  {{ title }}
@@ -60,17 +66,43 @@ function getItemOnChange() {
60
66
  <VDivider />
61
67
  </VCardItem>
62
68
 
63
- <VCardItem class="pt-0">
64
- <div
65
- v-for="(item, key) in data.model"
66
- :key="key"
67
- class="d-flex justify-space-between mb-2"
68
- >
69
- <span>{{ item.label }}</span>
69
+ <VCardItem
70
+ :class="{
71
+ 'pt-2': vertical,
72
+ 'pt-0 pa-0': !vertical
73
+ }"
74
+ >
75
+ <template v-if="vertical">
76
+ <VRow>
77
+ <VCol
78
+ v-for="(item, key) in data.model"
79
+ :key="key"
80
+ cols="3"
81
+ class="py-0"
82
+ >
83
+ <div class="d-flex justify-space-between align-center border pa-3 my-3 rounded">
84
+ <span>{{ item.label }}</span>
70
85
 
71
- <!-- item checkbox -->
72
- <VCheckbox v-model="item.selected" />
73
- </div>
86
+ <!-- item checkbox -->
87
+ <VCheckbox v-model="item.selected" />
88
+ </div>
89
+ </VCol>
90
+ </VRow>
91
+ </template>
92
+
93
+ <template v-else>
94
+ <VCardItem class="pt-0">
95
+ <div
96
+ v-for="(item, key) in data.model"
97
+ :key="key"
98
+ class="d-flex justify-space-between mb-2"
99
+ >
100
+ <span>{{ item.label }}</span>
101
+ <!-- item checkbox -->
102
+ <VCheckbox v-model="item.selected" />
103
+ </div>
104
+ </vcarditem>
105
+ </template>
74
106
  </VCardItem>
75
107
  </AppCard>
76
108
  </template>
@@ -7,6 +7,7 @@ type __VLS_Props = {
7
7
  id?: string | number;
8
8
  title?: string;
9
9
  modelValue: ChechboxModel[];
10
+ vertical?: boolean;
10
11
  };
11
12
  declare const __VLS_export: import("vue").DefineComponent<__VLS_Props, {}, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {} & {
12
13
  "update:modelValue": (value: ChechboxModel[]) => any;
@@ -342,6 +342,9 @@ $typography-body-1-line-height: 1.375rem;
342
342
  $alert-padding: 14.75px !default,
343
343
  $alert-prepend-margin-inline-end: 0.6rem !default,
344
344
 
345
+ // Table
346
+ $table-header-height: 60px !default,
347
+ $table-row-height: 70px !default,
345
348
  // Avatar
346
349
  $avatar-height: 38px !default,
347
350
  $avatar-width: 38px !default,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@winchsa/ui",
3
- "version": "0.1.27",
3
+ "version": "0.1.29",
4
4
  "type": "module",
5
5
  "private": false,
6
6
  "publishConfig": {