@drax/crud-vue 0.30.0 → 0.31.0

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/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "publishConfig": {
4
4
  "access": "public"
5
5
  },
6
- "version": "0.30.0",
6
+ "version": "0.31.0",
7
7
  "type": "module",
8
8
  "main": "./src/index.ts",
9
9
  "module": "./src/index.ts",
@@ -24,10 +24,10 @@
24
24
  "format": "prettier --write src/"
25
25
  },
26
26
  "dependencies": {
27
- "@drax/common-front": "^0.30.0",
28
- "@drax/crud-front": "^0.30.0",
29
- "@drax/crud-share": "^0.30.0",
30
- "@drax/media-vue": "^0.30.0"
27
+ "@drax/common-front": "^0.31.0",
28
+ "@drax/crud-front": "^0.31.0",
29
+ "@drax/crud-share": "^0.31.0",
30
+ "@drax/media-vue": "^0.31.0"
31
31
  },
32
32
  "peerDependencies": {
33
33
  "pinia": "^2.2.2",
@@ -64,5 +64,5 @@
64
64
  "vue-tsc": "^2.1.10",
65
65
  "vuetify": "^3.8.2"
66
66
  },
67
- "gitHead": "f7f06578327be29f20dcb7e2c8a2eac9e9145cab"
67
+ "gitHead": "01589f8197801c0b8ad13a10d398e41d6cb2a25a"
68
68
  }
@@ -138,6 +138,64 @@ const {xs} = useDisplay()
138
138
  </v-expansion-panels>
139
139
  </v-card-text>
140
140
 
141
+
142
+ <v-card-text v-else-if="field.arrayObjectUI === 'chips' ">
143
+ <v-row dense>
144
+ <v-col cols="12" sm="12" md="12">
145
+ <v-card variant="flat">
146
+ <v-card-text >
147
+ <v-btn color="primary" rounded="xl" @click="addItem"
148
+ class="text-blue text--darken-3 float-left mt-1 mr-2">
149
+ <v-icon>mdi-plus</v-icon> {{ label }}
150
+ </v-btn>
151
+ <v-chip-group v-model="itemSelected"
152
+ :style="{ maxHeight: menuMaxHeight, overflowY: 'auto' }"
153
+ direction="horizontal"
154
+
155
+ >
156
+ <v-chip v-for="(item,index) in valueModel" :key="index"
157
+ :value="item" @click="menuSelect(item, index)"
158
+ label closable @click:close="removeItem(index)"
159
+ >
160
+ <!-- <template v-slot:prepend>-->
161
+ <!-- <v-avatar>{{ index }}</v-avatar>-->
162
+ <!-- </template>-->
163
+ {{//@ts-ignore
164
+ valueModel[index][Object.keys(valueModel[index] as any)[0]] || index
165
+ }}
166
+ </v-chip>
167
+
168
+ </v-chip-group>
169
+
170
+ </v-card-text>
171
+ </v-card>
172
+ </v-col>
173
+ <v-col cols="12" sm="12" md="12">
174
+ <v-card v-if="itemSelected" variant="flat">
175
+ <v-card-text >
176
+ <template v-for="key in Object.keys(itemSelected as Record<string, any>)" :key="key">
177
+ <crud-form-field
178
+ v-if="hasField(key)"
179
+ :entity="entity"
180
+ :field="getField(key)"
181
+ v-model="(itemSelected as any)[key]"
182
+ :readonly="readonly"
183
+ :parentField="field.name"
184
+ :index="indexSelected"
185
+ :density="density"
186
+ :variant="variant"
187
+ :clearable="clearable"
188
+ :hide-details="hideDetails"
189
+ :single-line="singleLine"
190
+ @updateValue="$emit('updateValue')"
191
+ />
192
+ </template>
193
+ </v-card-text>
194
+ </v-card>
195
+ </v-col>
196
+ </v-row>
197
+ </v-card-text>
198
+
141
199
  <v-card-text v-else>
142
200
  <v-row>
143
201
  <v-col cols="12" sm="4" md="3">