@bildvitta/quasar-ui-asteroid 3.15.0-beta.3 → 3.15.0-beta.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.
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@bildvitta/quasar-ui-asteroid",
3
3
  "description": "Asteroid",
4
- "version": "3.15.0-beta.3",
4
+ "version": "3.15.0-beta.5",
5
5
  "author": "Bild & Vitta <systemteam@bild.com.br>",
6
6
  "license": "MIT",
7
7
  "main": "dist/asteroid.cjs.min.js",
@@ -17,7 +17,7 @@
17
17
 
18
18
  <div ref="formGenerator" class="col-12 justify-between q-col-gutter-x-md row">
19
19
  <slot :errors="transformedErrors" :fields="getFields(index, row)" :index="index" name="fields" :update-value="updateValuesFromInput">
20
- <qas-form-generator v-model="nested[index]" :class="formClasses" :columns="formColumns" :disable="isDisabledRow(row)" :errors="transformedErrors[index]" :fields="getFields(index, row)" :fields-props="getFieldsProps(index, row)" @update:model-value="updateValuesFromInput($event, index)">
20
+ <qas-form-generator v-model="nested[index]" class="col" :columns="formColumns" :disable="isDisabledRow(row)" :errors="transformedErrors[index]" :fields="getFields(index, row)" :fields-props="getFieldsProps(index, row)" :gutter="formGutter" @update:model-value="updateValuesFromInput($event, index)">
21
21
  <template v-for="(slot, key) in $slots" #[key]="scope">
22
22
  <slot v-bind="scope" :disabled="isDisabledRow(row)" :errors="transformedErrors" :index="index" :name="key" />
23
23
  </template>
@@ -67,6 +67,7 @@ import QasInput from '../input/QasInput.vue'
67
67
  import QasLabel from '../label/QasLabel.vue'
68
68
 
69
69
  import { constructObject } from '../../helpers'
70
+ import { Spacing } from '../../enums/Spacing'
70
71
 
71
72
  import { TransitionGroup } from 'vue'
72
73
  import debug from 'debug'
@@ -164,17 +165,9 @@ export default {
164
165
  },
165
166
 
166
167
  formGutter: {
167
- type: String,
168
- default: 'md',
169
- validator: value => {
170
- return [
171
- 'xs',
172
- 'sm',
173
- 'md',
174
- 'lg',
175
- 'xl'
176
- ].includes(value)
177
- }
168
+ default: Spacing.Lg,
169
+ type: [String, Boolean],
170
+ validator: value => typeof value === 'boolean' || Object.values(Spacing).includes(value)
178
171
  },
179
172
 
180
173
  identifierItemKey: {
@@ -280,13 +273,6 @@ export default {
280
273
  return this.field?.name
281
274
  },
282
275
 
283
- formClasses () {
284
- return {
285
- col: true,
286
- [`q-col-gutter-x-${this.formGutter}`]: this.useInlineActions
287
- }
288
- },
289
-
290
276
  showDestroyButton () {
291
277
  return this.nested.filter(item => !item[this.destroyKey]).length > 1 || this.hasDestroyAlways
292
278
  },
@@ -75,10 +75,10 @@ props:
75
75
  examples: ["[{ sm: 6, md: 12 }]", "{ name: { sm: 6, md: 12 } }", "12"]
76
76
 
77
77
  form-gutter:
78
- desc: Espaçamento entre cada campo.
79
- default: md
80
- type: String
81
- examples: [xs, sm, md, lg, xl]
78
+ desc: Espaçamento entre colunas do formulário.
79
+ default: lg
80
+ type: [String, Boolean]
81
+ examples: [xs, sm, md, lg, xl, false]
82
82
 
83
83
  identifier-item-key:
84
84
  desc: Define um identificador para o item. O identificador será utilizado para validar exclusão do item, por exemplo.
@@ -35,8 +35,8 @@ export default {
35
35
  computed: {
36
36
  attributes () {
37
37
  return {
38
- ...this.$attrs,
39
- inline: !this.$qas.screen.isSmall
38
+ inline: !this.$qas.screen.isSmall,
39
+ ...this.$attrs
40
40
  }
41
41
  },
42
42