@xy-planning-network/trees 0.11.9 → 0.12.1

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,6 +1,6 @@
1
1
  {
2
2
  "name": "@xy-planning-network/trees",
3
- "version": "0.11.9",
3
+ "version": "0.12.1",
4
4
  "description": "",
5
5
  "license": "MIT",
6
6
  "repository": "github:xy-planning-network/trees",
@@ -37,7 +37,7 @@ const labelDisplay = computed((): string => {
37
37
  class="block text-sm leading-6 font-semibold text-gray-800"
38
38
  v-bind="$attrs"
39
39
  >
40
- {{ labelDisplay }}
41
- <span v-if="props.required" class="text-red-700/80">*</span>
40
+ {{ labelDisplay
41
+ }}<span v-if="props.required" class="text-red-700/80">*</span>
42
42
  </component>
43
43
  </template>
@@ -37,7 +37,7 @@ const labelDisplay = computed((): string => {
37
37
  class="block text-sm leading-snug font-medium text-gray-800"
38
38
  v-bind="$attrs"
39
39
  >
40
- {{ labelDisplay }}
41
- <span v-if="props.required" class="text-red-700/80" aria-hidden>*</span>
40
+ {{ labelDisplay
41
+ }}<span v-if="props.required" class="text-red-700/80" aria-hidden>*</span>
42
42
  </component>
43
43
  </template>
@@ -53,23 +53,26 @@ const onUpdate = (val: unknown) => {
53
53
  <template>
54
54
  <RadioGroup
55
55
  v-model="modelState"
56
+ class="space-y-6"
56
57
  :disabled="isDisabled"
57
58
  :aria-invalid="errorState ? 'true' : null"
58
59
  :aria-errormessage="aria.errormessage"
59
60
  @update:model-value="onUpdate"
60
61
  >
61
- <RadioGroupLabel v-if="label" class="block">
62
- <FieldsetLegend tag="div" :label="label" :required="isRequired" />
63
- </RadioGroupLabel>
62
+ <div v-if="label || help || errorState">
63
+ <RadioGroupLabel v-if="label" class="block">
64
+ <FieldsetLegend tag="div" :label="label" :required="isRequired" />
65
+ </RadioGroupLabel>
64
66
 
65
- <RadioGroupDescription v-if="help" class="mt-1">
66
- <InputHelp :text="help" />
67
- </RadioGroupDescription>
67
+ <RadioGroupDescription v-if="help" class="mt-1">
68
+ <InputHelp :text="help" />
69
+ </RadioGroupDescription>
68
70
 
69
- <InputError :id="aria.errormessage" class="mt-1" :text="errorState" />
71
+ <InputError :id="aria.errormessage" class="mt-1" :text="errorState" />
72
+ </div>
70
73
 
71
74
  <div
72
- class="mt-6 grid grid-cols-1 gap-y-5 gap-x-4 relative"
75
+ class="grid grid-cols-1 gap-y-5 gap-x-4 relative"
73
76
  :class="{
74
77
  'sm:grid-cols-2': columns === 2,
75
78
  'sm:grid-cols-3': columns === 3,
@@ -32,7 +32,7 @@ const { aria, inputID, isRequired, errorState, onInvalid, inputValidation } =
32
32
  />
33
33
  <textarea
34
34
  :id="inputID"
35
- v-model="modelState"
35
+ v-model.trim="modelState"
36
36
  :aria-labelledby="aria.labelledby"
37
37
  :aria-describedby="aria.describedby"
38
38
  :aria-errormessage="aria.errormessage"