@fastkit/vui 0.16.0 → 0.16.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/dist/vui.css +4 -2
- package/dist/vui.d.ts +1 -6
- package/dist/vui.mjs +14 -24
- package/dist/vui.mjs.map +1 -1
- package/package.json +2 -2
- package/src/components/VApp/VApp.tsx +3 -3
- package/src/components/VControlField/VControlField.tsx +13 -25
- package/src/components/VFormControl/VFormControl.tsx +3 -5
- package/src/components/VSelect/VSelect.tsx +1 -1
- package/src/components/VTooltip/VTooltip.scss +6 -2
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fastkit/vui",
|
|
3
|
-
"version": "0.16.
|
|
3
|
+
"version": "0.16.1",
|
|
4
4
|
"description": "A simple, extensible UI kit for Vue applications.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"fastkit",
|
|
@@ -66,7 +66,7 @@
|
|
|
66
66
|
"@fastkit/vue-media-match": "0.13.6",
|
|
67
67
|
"@fastkit/vue-resize": "0.1.2",
|
|
68
68
|
"@fastkit/vue-scroller": "0.14.0",
|
|
69
|
-
"@fastkit/vue-stack": "0.15.
|
|
69
|
+
"@fastkit/vue-stack": "0.15.1",
|
|
70
70
|
"@fastkit/vue-transitions": "0.1.2",
|
|
71
71
|
"@fastkit/vue-utils": "0.14.0"
|
|
72
72
|
},
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { defineComponent } from 'vue';
|
|
2
2
|
import { VAppLayout } from '@fastkit/vue-app-layout';
|
|
3
|
-
import {
|
|
3
|
+
import { VStackContainer } from '@fastkit/vue-stack';
|
|
4
4
|
import { useInjectTheme } from '@fastkit/vue-color-scheme';
|
|
5
5
|
|
|
6
6
|
export const VApp = defineComponent({
|
|
@@ -10,9 +10,9 @@ export const VApp = defineComponent({
|
|
|
10
10
|
|
|
11
11
|
return () => {
|
|
12
12
|
return (
|
|
13
|
-
<
|
|
13
|
+
<VStackContainer>
|
|
14
14
|
<VAppLayout v-slots={ctx.slots} />
|
|
15
|
-
</
|
|
15
|
+
</VStackContainer>
|
|
16
16
|
);
|
|
17
17
|
};
|
|
18
18
|
},
|
|
@@ -138,32 +138,20 @@ export const VControlField = defineComponent({
|
|
|
138
138
|
);
|
|
139
139
|
};
|
|
140
140
|
|
|
141
|
-
const handleClick = (ev: MouseEvent) =>
|
|
142
|
-
ctx.emit('click', ev);
|
|
143
|
-
// if (ev.target === hostElRef.value) {
|
|
144
|
-
// ctx.emit('clickHost', ev);
|
|
145
|
-
// }
|
|
146
|
-
};
|
|
141
|
+
const handleClick = (ev: MouseEvent) => ctx.emit('click', ev);
|
|
147
142
|
|
|
148
|
-
return {
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
143
|
+
return () => {
|
|
144
|
+
return (
|
|
145
|
+
<div
|
|
146
|
+
class={classes.value}
|
|
147
|
+
onClick={handleClick}
|
|
148
|
+
// tabindex={this.computedTabindex}
|
|
149
|
+
ref={hostElRef}>
|
|
150
|
+
{renderAdornment('start')}
|
|
151
|
+
<div class="v-control-field__body">{ctx.slots.default?.()}</div>
|
|
152
|
+
{renderAdornment('end')}
|
|
153
|
+
</div>
|
|
154
|
+
);
|
|
154
155
|
};
|
|
155
156
|
},
|
|
156
|
-
render() {
|
|
157
|
-
return (
|
|
158
|
-
<div
|
|
159
|
-
class={this.classes}
|
|
160
|
-
onClick={this.handleClick}
|
|
161
|
-
// tabindex={this.computedTabindex}
|
|
162
|
-
ref={this.hostElRef()}>
|
|
163
|
-
{this.renderAdornment('start')}
|
|
164
|
-
<div class="v-control-field__body">{this.$slots.default?.()}</div>
|
|
165
|
-
{this.renderAdornment('end')}
|
|
166
|
-
</div>
|
|
167
|
-
);
|
|
168
|
-
},
|
|
169
157
|
});
|
|
@@ -111,6 +111,8 @@ export const VFormControl = defineComponent({
|
|
|
111
111
|
vui,
|
|
112
112
|
);
|
|
113
113
|
|
|
114
|
+
const handleClick = (ev: MouseEvent) => ctx.emit('clickLabel', ev, control);
|
|
115
|
+
|
|
114
116
|
return () => {
|
|
115
117
|
const label = control.renderLabel();
|
|
116
118
|
const message = control.renderMessage();
|
|
@@ -121,11 +123,7 @@ export const VFormControl = defineComponent({
|
|
|
121
123
|
return (
|
|
122
124
|
<div class={['v-form-control', classes.value]}>
|
|
123
125
|
{label && (
|
|
124
|
-
<label
|
|
125
|
-
class="v-form-control__label"
|
|
126
|
-
onClick={(ev) => {
|
|
127
|
-
ctx.emit('clickLabel', ev, control);
|
|
128
|
-
}}>
|
|
126
|
+
<label class="v-form-control__label" onClick={handleClick}>
|
|
129
127
|
{label}
|
|
130
128
|
{getRequiredChip()}
|
|
131
129
|
{hinttip && (
|
|
@@ -119,7 +119,7 @@ export const VSelect = defineComponent({
|
|
|
119
119
|
});
|
|
120
120
|
|
|
121
121
|
const focus = (opts?: FocusOptions): void => {
|
|
122
|
-
fieldRef.value
|
|
122
|
+
fieldRef.value?.focus?.(opts);
|
|
123
123
|
};
|
|
124
124
|
|
|
125
125
|
const renderSelections = (selectedItems: FormSelectorItemControl[]) => {
|
|
@@ -2,8 +2,12 @@
|
|
|
2
2
|
--menu-shadow: var(--tooltip-shadow);
|
|
3
3
|
|
|
4
4
|
font-size: var(--tooltip-font-size);
|
|
5
|
-
|
|
6
|
-
|
|
5
|
+
|
|
6
|
+
.v-menu__body {
|
|
7
|
+
color: var(--tooltip-color) !important;
|
|
8
|
+
background: var(--tooltip-background) !important;
|
|
9
|
+
}
|
|
10
|
+
|
|
7
11
|
border-radius: var(--tooltip-radius);
|
|
8
12
|
// opacity: var(--tooltip-opacity);
|
|
9
13
|
|