@pequity/squirrel 5.4.0 → 5.4.2
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/cjs/chunks/p-action-bar.js +10 -11
- package/dist/cjs/chunks/p-date-picker.js +108 -0
- package/dist/cjs/chunks/p-dropdown-select.js +7 -8
- package/dist/cjs/chunks/p-inline-date-picker.js +112 -0
- package/dist/cjs/chunks/p-input-percent.js +3 -5
- package/dist/cjs/chunks/p-pagination-info.js +1 -1
- package/dist/cjs/chunks/p-pagination.js +12 -16
- package/dist/cjs/config.js +54 -54
- package/dist/cjs/index.js +47 -52
- package/dist/cjs/p-btn.js +8 -5
- package/dist/cjs/p-chips.js +3 -5
- package/dist/cjs/p-date-picker.js +2 -138
- package/dist/cjs/p-drawer.js +3 -3
- package/dist/cjs/p-info-icon.js +1 -3
- package/dist/cjs/p-inline-date-picker.js +2 -143
- package/dist/cjs/p-modal.js +3 -3
- package/dist/cjs/p-table-td.js +3 -5
- package/dist/es/chunks/p-action-bar.js +10 -11
- package/dist/es/chunks/p-date-picker.js +109 -0
- package/dist/es/chunks/p-dropdown-select.js +7 -8
- package/dist/es/chunks/p-inline-date-picker.js +113 -0
- package/dist/es/chunks/p-input-percent.js +3 -5
- package/dist/es/chunks/p-pagination-info.js +1 -1
- package/dist/es/chunks/p-pagination.js +12 -16
- package/dist/es/config.js +54 -54
- package/dist/es/index.js +96 -101
- package/dist/es/p-btn.js +8 -5
- package/dist/es/p-chips.js +4 -6
- package/dist/es/p-date-picker.js +2 -138
- package/dist/es/p-drawer.js +3 -3
- package/dist/es/p-info-icon.js +2 -4
- package/dist/es/p-inline-date-picker.js +2 -143
- package/dist/es/p-modal.js +3 -3
- package/dist/es/p-table-td.js +4 -6
- package/dist/squirrel/components/p-action-bar/p-action-bar.vue.d.ts +5 -14
- package/dist/squirrel/components/p-alert/p-alert.vue.d.ts +4 -4
- package/dist/squirrel/components/p-avatar/p-avatar.vue.d.ts +5 -5
- package/dist/squirrel/components/p-btn/p-btn.vue.d.ts +40 -5
- package/dist/squirrel/components/p-card/p-card.vue.d.ts +4 -4
- package/dist/squirrel/components/p-checkbox/p-checkbox.vue.d.ts +5 -5
- package/dist/squirrel/components/p-chips/p-chips.vue.d.ts +5 -5
- package/dist/squirrel/components/p-close-btn/p-close-btn.vue.d.ts +4 -4
- package/dist/squirrel/components/p-date-picker/p-date-picker.vue.d.ts +35 -128
- package/dist/squirrel/components/p-drawer/p-drawer.vue.d.ts +37 -5
- package/dist/squirrel/components/p-dropdown/p-dropdown.vue.d.ts +5 -5
- package/dist/squirrel/components/p-dropdown-select/p-dropdown-select.vue.d.ts +128 -29
- package/dist/squirrel/components/p-file-upload/p-file-upload.vue.d.ts +5 -5
- package/dist/squirrel/components/p-icon/p-icon.vue.d.ts +1 -10
- package/dist/squirrel/components/p-info-icon/p-info-icon.vue.d.ts +2 -23
- package/dist/squirrel/components/p-input/p-input.vue.d.ts +9 -9
- package/dist/squirrel/components/p-input-number/p-input-number.vue.d.ts +40 -10
- package/dist/squirrel/components/p-input-percent/p-input-percent.vue.d.ts +5 -5
- package/dist/squirrel/components/p-input-search/p-input-search.vue.d.ts +121 -5
- package/dist/squirrel/components/p-link/p-link.vue.d.ts +1 -10
- package/dist/squirrel/components/p-loading/p-loading.vue.d.ts +1 -1
- package/dist/squirrel/components/p-modal/p-modal.vue.d.ts +5 -5
- package/dist/squirrel/components/p-pagination/p-pagination.vue.d.ts +5 -5
- package/dist/squirrel/components/p-pagination-info/p-pagination-info.vue.d.ts +4 -4
- package/dist/squirrel/components/p-progress-bar/p-progress-bar.vue.d.ts +3 -3
- package/dist/squirrel/components/p-ring-loader/p-ring-loader.vue.d.ts +4 -4
- package/dist/squirrel/components/p-select/p-select.vue.d.ts +5 -5
- package/dist/squirrel/components/p-select-btn/p-select-btn.vue.d.ts +4 -45
- package/dist/squirrel/components/p-select-list/p-select-list.vue.d.ts +128 -29
- package/dist/squirrel/components/p-select-list/useSelectList.d.ts +4 -4
- package/dist/squirrel/components/p-select-pill/p-select-pill.vue.d.ts +5 -5
- package/dist/squirrel/components/p-skeleton-loader/p-skeleton-loader.vue.d.ts +4 -4
- package/dist/squirrel/components/p-table/p-table.vue.d.ts +10 -47
- package/dist/squirrel/components/p-table/usePTableColResize.d.ts +4 -4
- package/dist/squirrel/components/p-table/usePTableRowVirtualizer.d.ts +10 -4
- package/dist/squirrel/components/p-table-header-cell/p-table-filter-icon.vue.d.ts +4 -4
- package/dist/squirrel/components/p-table-header-cell/p-table-header-cell.vue.d.ts +48 -5
- package/dist/squirrel/components/p-table-loader/p-table-loader.vue.d.ts +4 -4
- package/dist/squirrel/components/p-table-sort/p-table-sort.vue.d.ts +5 -5
- package/dist/squirrel/components/p-table-td/p-table-td.vue.d.ts +2 -25
- package/dist/squirrel/components/p-tabs/p-tabs.vue.d.ts +5 -5
- package/dist/squirrel/components/p-textarea/p-textarea.vue.d.ts +9 -9
- package/dist/squirrel/components/p-toggle/p-toggle.vue.d.ts +9 -9
- package/dist/squirrel/composables/useInputClasses.d.ts +1 -1
- package/dist/squirrel/tailwind/config.d.ts +54 -54
- package/dist/squirrel/utils/inputClassesMixin.d.ts +4 -4
- package/dist/style.css +92 -92
- package/dist/tailwind/config.js +54 -54
- package/package.json +25 -25
- package/squirrel/assets/squirrel.css +41 -41
- package/squirrel/components/p-alert/p-alert.spec.js +1 -1
- package/squirrel/components/p-btn/p-btn.spec.js +33 -4
- package/squirrel/components/p-btn/p-btn.vue +5 -2
- package/squirrel/components/p-date-picker/p-date-picker.vue +79 -86
- package/squirrel/components/p-drawer/p-drawer.vue +1 -1
- package/squirrel/components/p-inline-date-picker/p-inline-date-picker.spec.js +12 -14
- package/squirrel/components/p-inline-date-picker/p-inline-date-picker.vue +87 -99
- package/squirrel/components/p-modal/p-modal.vue +1 -1
- package/squirrel/tailwind/config.ts +54 -54
- package/dist/squirrel/components/p-inline-date-picker/p-inline-date-picker.vue.d.ts +0 -154
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import PInlineDatePicker from '@squirrel/components/p-inline-date-picker/p-inline-date-picker.vue';
|
|
2
|
+
import { DatePicker } from 'v-calendar';
|
|
2
3
|
import { createWrapperFor } from '@tests/vitest.helpers';
|
|
3
4
|
|
|
4
5
|
const createWrapper = (props) => {
|
|
@@ -20,17 +21,17 @@ describe('PInlineDatePicker.vue', () => {
|
|
|
20
21
|
it('renders a datepicker', () => {
|
|
21
22
|
const wrapper = createWrapper();
|
|
22
23
|
|
|
23
|
-
const datePicker = wrapper.findComponent(
|
|
24
|
+
const datePicker = wrapper.findComponent(DatePicker);
|
|
24
25
|
|
|
25
|
-
expect(datePicker.props()).
|
|
26
|
+
expect(datePicker.props()).toMatchObject({
|
|
26
27
|
modelValue: null,
|
|
27
28
|
selectAttribute: { highlight: { class: 'bg-primary', contentClass: 'text-white' } },
|
|
28
29
|
minDate: null,
|
|
29
30
|
maxDate: null,
|
|
30
31
|
masks: { input: 'DD-MMM-YYYY', data: 'YYYY-MM-DD' },
|
|
31
|
-
style: {},
|
|
32
32
|
timezone: '',
|
|
33
33
|
});
|
|
34
|
+
|
|
34
35
|
expect(wrapper.find('label').exists()).toBe(false);
|
|
35
36
|
expect(wrapper.find('div.text-xs.text-on-error.mt-1').isVisible()).toBe(false);
|
|
36
37
|
});
|
|
@@ -43,7 +44,7 @@ describe('PInlineDatePicker.vue', () => {
|
|
|
43
44
|
timezone: 'UTC',
|
|
44
45
|
});
|
|
45
46
|
|
|
46
|
-
const datePicker = wrapper.findComponent(
|
|
47
|
+
const datePicker = wrapper.findComponent(DatePicker);
|
|
47
48
|
|
|
48
49
|
expect(datePicker.props().modelValue).toEqual(new Date('2024-05-19'));
|
|
49
50
|
expect(datePicker.props().minDate).toEqual(new Date('2024-05-01'));
|
|
@@ -77,7 +78,6 @@ describe('PInlineDatePicker.vue', () => {
|
|
|
77
78
|
|
|
78
79
|
expect(wrapper.props().required).toBe(true);
|
|
79
80
|
});
|
|
80
|
-
|
|
81
81
|
it('passes listeners to the datepicker', () => {
|
|
82
82
|
// Since DatePicker emits are not defined on PInlineDatePicker we need to Spy on console.warn and mock the implementation to suppress the warning:
|
|
83
83
|
// [Vue warn]: Component emitted event "update:view" but it is neither declared in the emits option nor as an "onUpdate:view" prop.
|
|
@@ -100,7 +100,7 @@ describe('PInlineDatePicker.vue', () => {
|
|
|
100
100
|
},
|
|
101
101
|
});
|
|
102
102
|
|
|
103
|
-
const datePicker = wrapper.findComponent(
|
|
103
|
+
const datePicker = wrapper.findComponent(DatePicker);
|
|
104
104
|
|
|
105
105
|
datePicker.vm.$emit('update:view');
|
|
106
106
|
|
|
@@ -112,9 +112,9 @@ describe('PInlineDatePicker.vue', () => {
|
|
|
112
112
|
it('sets the disabled state correctly', () => {
|
|
113
113
|
const wrapper = createWrapper({ label: 'test datepicker', disabled: true });
|
|
114
114
|
|
|
115
|
-
const
|
|
115
|
+
const datePickerDiv = wrapper.find('.vc-container');
|
|
116
116
|
|
|
117
|
-
expect(['pointer-events-none', 'opacity-70'].every((c) =>
|
|
117
|
+
expect(['pointer-events-none', 'opacity-70'].every((c) => datePickerDiv.classes().includes(c))).toBe(true);
|
|
118
118
|
});
|
|
119
119
|
|
|
120
120
|
it(`updates the value when a day is clicked`, async () => {
|
|
@@ -128,7 +128,7 @@ describe('PInlineDatePicker.vue', () => {
|
|
|
128
128
|
},
|
|
129
129
|
});
|
|
130
130
|
|
|
131
|
-
const datePicker = wrapper.findComponent(
|
|
131
|
+
const datePicker = wrapper.findComponent(DatePicker);
|
|
132
132
|
|
|
133
133
|
datePicker.vm.$emit('dayclick', { id: '2024-09-02' });
|
|
134
134
|
|
|
@@ -138,7 +138,7 @@ describe('PInlineDatePicker.vue', () => {
|
|
|
138
138
|
it(`updates the datepicker value when modelValue is changed`, async () => {
|
|
139
139
|
const wrapper = createWrapper({ modelValue: '2024-09-01' });
|
|
140
140
|
|
|
141
|
-
const datePicker = wrapper.findComponent(
|
|
141
|
+
const datePicker = wrapper.findComponent(DatePicker);
|
|
142
142
|
datePicker.vm.move = vi.fn();
|
|
143
143
|
|
|
144
144
|
expect(datePicker.props().modelValue).toEqual(new Date('2024-09-01'));
|
|
@@ -156,11 +156,9 @@ describe('PInlineDatePicker.vue', () => {
|
|
|
156
156
|
});
|
|
157
157
|
|
|
158
158
|
expect(wrapper.attributes()['data-has-error']).toBeDefined();
|
|
159
|
-
const
|
|
159
|
+
const datePickerDiv = wrapper.find('.vc-container');
|
|
160
160
|
|
|
161
|
-
expect(
|
|
162
|
-
border: '1px solid var(--color-on-error)',
|
|
163
|
-
});
|
|
161
|
+
expect(datePickerDiv.element.style.border).toBe('1px solid #f0453c');
|
|
164
162
|
const errorDiv = wrapper.find('div.text-xs.text-on-error.mt-1');
|
|
165
163
|
expect(errorDiv.isVisible()).toBe(true);
|
|
166
164
|
expect(errorDiv.text()).toBe('datepicker has error');
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
</label>
|
|
7
7
|
</slot>
|
|
8
8
|
<DatePicker
|
|
9
|
-
ref="
|
|
9
|
+
ref="datepickerRef"
|
|
10
10
|
:class="{ 'pointer-events-none opacity-70': $attrs.disabled }"
|
|
11
11
|
:model-value="innerValue"
|
|
12
12
|
:select-attribute="selectAttribute"
|
|
@@ -22,12 +22,17 @@
|
|
|
22
22
|
</div>
|
|
23
23
|
</template>
|
|
24
24
|
|
|
25
|
-
<script lang="ts">
|
|
25
|
+
<script setup lang="ts">
|
|
26
26
|
import dayjs from 'dayjs';
|
|
27
|
-
import inputClassesMixin from '@squirrel/utils/inputClassesMixin';
|
|
28
27
|
import { type AttributeConfig } from 'v-calendar/dist/types/src/utils/attribute.d';
|
|
29
28
|
import { DatePicker } from 'v-calendar';
|
|
30
|
-
import { type
|
|
29
|
+
import { type StyleValue, computed, ref, useAttrs, watch } from 'vue';
|
|
30
|
+
import { useInputClasses } from '@squirrel/composables/useInputClasses';
|
|
31
|
+
|
|
32
|
+
defineOptions({
|
|
33
|
+
name: 'PInlineDatePicker',
|
|
34
|
+
inheritAttrs: false,
|
|
35
|
+
});
|
|
31
36
|
|
|
32
37
|
const selectAttribute: AttributeConfig = {
|
|
33
38
|
highlight: { class: 'bg-primary', contentClass: 'text-white' },
|
|
@@ -40,100 +45,83 @@ const DEFAULT_MASKS = {
|
|
|
40
45
|
data: 'YYYY-MM-DD',
|
|
41
46
|
};
|
|
42
47
|
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
default: '',
|
|
62
|
-
},
|
|
63
|
-
required: {
|
|
64
|
-
type: Boolean,
|
|
65
|
-
default: false,
|
|
66
|
-
},
|
|
67
|
-
minDate: {
|
|
68
|
-
type: Date,
|
|
69
|
-
default: null,
|
|
70
|
-
},
|
|
71
|
-
maxDate: {
|
|
72
|
-
type: Date,
|
|
73
|
-
default: null,
|
|
74
|
-
},
|
|
75
|
-
timezone: {
|
|
76
|
-
type: String,
|
|
77
|
-
default: '',
|
|
78
|
-
},
|
|
79
|
-
},
|
|
80
|
-
emits: ['update:modelValue'],
|
|
81
|
-
data() {
|
|
82
|
-
return {
|
|
83
|
-
// innerValue is a Date object
|
|
84
|
-
innerValue: null as Date | null,
|
|
85
|
-
selectAttribute,
|
|
86
|
-
};
|
|
87
|
-
},
|
|
88
|
-
computed: {
|
|
89
|
-
masks() {
|
|
90
|
-
return Object.assign(DEFAULT_MASKS, this.$attrs.masks);
|
|
91
|
-
},
|
|
92
|
-
attrs() {
|
|
93
|
-
const { class: classes, style, ...rest } = this.$attrs;
|
|
94
|
-
|
|
95
|
-
return rest;
|
|
96
|
-
},
|
|
97
|
-
listeners() {
|
|
98
|
-
return Object.keys(this.$attrs).reduce((acc, curr) => {
|
|
99
|
-
if (curr.startsWith('on')) {
|
|
100
|
-
return { ...acc, [curr]: this.$attrs[curr] };
|
|
101
|
-
} else {
|
|
102
|
-
return acc;
|
|
103
|
-
}
|
|
104
|
-
}, {});
|
|
105
|
-
},
|
|
106
|
-
style() {
|
|
107
|
-
return this.$attrs.style as StyleValue;
|
|
108
|
-
},
|
|
109
|
-
styleDatepicker() {
|
|
110
|
-
return this.errorMsg ? { border: '1px solid var(--color-on-error)' } : {};
|
|
111
|
-
},
|
|
112
|
-
},
|
|
113
|
-
watch: {
|
|
114
|
-
modelValue: {
|
|
115
|
-
async handler(nV) {
|
|
116
|
-
const date = dayjs(nV, this.masks.data).toDate();
|
|
117
|
-
|
|
118
|
-
if (nV && date.toString() === 'Invalid Date') {
|
|
119
|
-
this.$emit('update:modelValue', null);
|
|
120
|
-
return;
|
|
121
|
-
}
|
|
122
|
-
|
|
123
|
-
this.innerValue = nV ? dayjs(nV, this.masks.data).toDate() : null;
|
|
124
|
-
const datepicker = this.$refs.datepicker as { move: (val: unknown) => void };
|
|
125
|
-
|
|
126
|
-
if (datepicker && typeof datepicker.move === 'function' && this.innerValue) {
|
|
127
|
-
await datepicker.move(this.innerValue);
|
|
128
|
-
}
|
|
129
|
-
},
|
|
130
|
-
immediate: true,
|
|
131
|
-
},
|
|
132
|
-
},
|
|
133
|
-
methods: {
|
|
134
|
-
dayclick(e: { id: string }) {
|
|
135
|
-
this.$emit('update:modelValue', e.id);
|
|
136
|
-
},
|
|
137
|
-
},
|
|
48
|
+
type Props = {
|
|
49
|
+
modelValue?: string | null;
|
|
50
|
+
label?: string;
|
|
51
|
+
errorMsg?: string;
|
|
52
|
+
required?: boolean;
|
|
53
|
+
minDate?: Date | null;
|
|
54
|
+
maxDate?: Date | null;
|
|
55
|
+
timezone?: string;
|
|
56
|
+
};
|
|
57
|
+
|
|
58
|
+
const props = withDefaults(defineProps<Props>(), {
|
|
59
|
+
modelValue: '',
|
|
60
|
+
label: '',
|
|
61
|
+
errorMsg: '',
|
|
62
|
+
required: false,
|
|
63
|
+
minDate: null,
|
|
64
|
+
maxDate: null,
|
|
65
|
+
timezone: '',
|
|
138
66
|
});
|
|
67
|
+
|
|
68
|
+
const emit = defineEmits<{
|
|
69
|
+
'update:modelValue': [value: string | null];
|
|
70
|
+
}>();
|
|
71
|
+
|
|
72
|
+
// Data
|
|
73
|
+
const { labelClasses, errorMsgClasses } = useInputClasses(props);
|
|
74
|
+
const attrs = useAttrs();
|
|
75
|
+
// innerValue is a Date object
|
|
76
|
+
const innerValue = ref<Date | null>(null);
|
|
77
|
+
const datepickerRef = ref<InstanceType<typeof DatePicker> | null>(null);
|
|
78
|
+
|
|
79
|
+
// Computed
|
|
80
|
+
const masks = computed(() => {
|
|
81
|
+
return Object.assign(DEFAULT_MASKS, attrs.masks);
|
|
82
|
+
});
|
|
83
|
+
|
|
84
|
+
const listeners = computed(() => {
|
|
85
|
+
return Object.keys(attrs).reduce((acc, curr) => {
|
|
86
|
+
if (curr.startsWith('on')) {
|
|
87
|
+
return { ...acc, [curr]: attrs[curr] };
|
|
88
|
+
} else {
|
|
89
|
+
return acc;
|
|
90
|
+
}
|
|
91
|
+
}, {});
|
|
92
|
+
});
|
|
93
|
+
|
|
94
|
+
const style = computed(() => {
|
|
95
|
+
return attrs.style as StyleValue;
|
|
96
|
+
});
|
|
97
|
+
|
|
98
|
+
const styleDatepicker = computed(() => {
|
|
99
|
+
return props.errorMsg ? { border: '1px solid #f0453c' } : {};
|
|
100
|
+
});
|
|
101
|
+
|
|
102
|
+
// Methods
|
|
103
|
+
const dayclick = (e: { id: string }) => {
|
|
104
|
+
emit('update:modelValue', e.id);
|
|
105
|
+
};
|
|
106
|
+
|
|
107
|
+
// Watch
|
|
108
|
+
watch(
|
|
109
|
+
() => props.modelValue,
|
|
110
|
+
async (nV) => {
|
|
111
|
+
const date = dayjs(nV, masks.value.data).toDate();
|
|
112
|
+
|
|
113
|
+
if (nV && date.toString() === 'Invalid Date') {
|
|
114
|
+
emit('update:modelValue', null);
|
|
115
|
+
return;
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
innerValue.value = nV ? dayjs(nV, masks.value.data).toDate() : null;
|
|
119
|
+
const datepicker = datepickerRef.value as { move: (val: unknown) => void };
|
|
120
|
+
|
|
121
|
+
if (datepicker && typeof datepicker.move === 'function' && innerValue.value) {
|
|
122
|
+
await datepicker.move(innerValue.value);
|
|
123
|
+
}
|
|
124
|
+
},
|
|
125
|
+
{ immediate: true }
|
|
126
|
+
);
|
|
139
127
|
</script>
|
|
@@ -119,7 +119,7 @@ const props = defineProps({
|
|
|
119
119
|
},
|
|
120
120
|
bgClass: {
|
|
121
121
|
type: [String, Object, Array] as PropType<StyleValue>,
|
|
122
|
-
default: 'fixed bottom-0 left-0 right-0 top-0 bg-black
|
|
122
|
+
default: 'fixed bottom-0 left-0 right-0 top-0 bg-black/20',
|
|
123
123
|
},
|
|
124
124
|
wrapperClass: {
|
|
125
125
|
type: [String, Object, Array] as PropType<StyleValue>,
|
|
@@ -7,71 +7,71 @@ export const config = {
|
|
|
7
7
|
transparent: 'transparent',
|
|
8
8
|
current: 'currentColor',
|
|
9
9
|
/* Design system colors */
|
|
10
|
-
white: '
|
|
11
|
-
black: '
|
|
12
|
-
night: 'var(--color-night)',
|
|
13
|
-
'barley-white': 'var(--color-barley-white)',
|
|
14
|
-
'horses-neck': 'var(--color-horses-neck)',
|
|
15
|
-
'active-blue': 'var(--color-active-blue)',
|
|
10
|
+
white: 'rgb(var(--color-white))',
|
|
11
|
+
black: 'rgb(var(--color-black))',
|
|
12
|
+
night: 'rgb(var(--color-night))',
|
|
13
|
+
'barley-white': 'rgb(var(--color-barley-white))',
|
|
14
|
+
'horses-neck': 'rgb(var(--color-horses-neck))',
|
|
15
|
+
'active-blue': 'rgb(var(--color-active-blue))',
|
|
16
16
|
/* Pequity colors */
|
|
17
17
|
'p-gray': {
|
|
18
|
-
10: 'var(--color-p-gray-10)',
|
|
19
|
-
20: 'var(--color-p-gray-20)',
|
|
20
|
-
30: 'var(--color-p-gray-30)',
|
|
21
|
-
40: 'var(--color-p-gray-40)',
|
|
22
|
-
50: 'var(--color-p-gray-50)',
|
|
23
|
-
60: 'var(--color-p-gray-60)',
|
|
24
|
-
70: 'var(--color-p-gray-70)',
|
|
25
|
-
80: 'var(--color-p-gray-80)',
|
|
26
|
-
90: 'var(--color-p-gray-90)',
|
|
27
|
-
100: 'var(--color-p-gray-100)',
|
|
18
|
+
10: 'rgb(var(--color-p-gray-10))',
|
|
19
|
+
20: 'rgb(var(--color-p-gray-20))',
|
|
20
|
+
30: 'rgb(var(--color-p-gray-30))',
|
|
21
|
+
40: 'rgb(var(--color-p-gray-40))',
|
|
22
|
+
50: 'rgb(var(--color-p-gray-50))',
|
|
23
|
+
60: 'rgb(var(--color-p-gray-60))',
|
|
24
|
+
70: 'rgb(var(--color-p-gray-70))',
|
|
25
|
+
80: 'rgb(var(--color-p-gray-80))',
|
|
26
|
+
90: 'rgb(var(--color-p-gray-90))',
|
|
27
|
+
100: 'rgb(var(--color-p-gray-100))',
|
|
28
28
|
},
|
|
29
29
|
'p-blue': {
|
|
30
|
-
10: 'var(--color-p-blue-10)',
|
|
31
|
-
15: 'var(--color-p-blue-15)',
|
|
32
|
-
20: 'var(--color-p-blue-20)',
|
|
33
|
-
30: 'var(--color-p-blue-30)',
|
|
34
|
-
40: 'var(--color-p-blue-40)',
|
|
35
|
-
50: 'var(--color-p-blue-50)',
|
|
36
|
-
60: 'var(--color-p-blue-60)',
|
|
37
|
-
70: 'var(--color-p-blue-70)',
|
|
38
|
-
80: 'var(--color-p-blue-80)',
|
|
30
|
+
10: 'rgb(var(--color-p-blue-10))',
|
|
31
|
+
15: 'rgb(var(--color-p-blue-15))',
|
|
32
|
+
20: 'rgb(var(--color-p-blue-20))',
|
|
33
|
+
30: 'rgb(var(--color-p-blue-30))',
|
|
34
|
+
40: 'rgb(var(--color-p-blue-40))',
|
|
35
|
+
50: 'rgb(var(--color-p-blue-50))',
|
|
36
|
+
60: 'rgb(var(--color-p-blue-60))',
|
|
37
|
+
70: 'rgb(var(--color-p-blue-70))',
|
|
38
|
+
80: 'rgb(var(--color-p-blue-80))',
|
|
39
39
|
},
|
|
40
40
|
'p-purple': {
|
|
41
|
-
10: 'var(--color-p-purple-10)',
|
|
42
|
-
20: 'var(--color-p-purple-20)',
|
|
43
|
-
30: 'var(--color-p-purple-30)',
|
|
44
|
-
40: 'var(--color-p-purple-40)',
|
|
45
|
-
50: 'var(--color-p-purple-50)',
|
|
46
|
-
60: 'var(--color-p-purple-60)',
|
|
41
|
+
10: 'rgb(var(--color-p-purple-10))',
|
|
42
|
+
20: 'rgb(var(--color-p-purple-20))',
|
|
43
|
+
30: 'rgb(var(--color-p-purple-30))',
|
|
44
|
+
40: 'rgb(var(--color-p-purple-40))',
|
|
45
|
+
50: 'rgb(var(--color-p-purple-50))',
|
|
46
|
+
60: 'rgb(var(--color-p-purple-60))',
|
|
47
47
|
},
|
|
48
48
|
'p-green': {
|
|
49
|
-
10: 'var(--color-p-green-10)',
|
|
50
|
-
20: 'var(--color-p-green-20)',
|
|
51
|
-
30: 'var(--color-p-green-30)',
|
|
52
|
-
40: 'var(--color-p-green-40)',
|
|
53
|
-
50: 'var(--color-p-green-50)',
|
|
49
|
+
10: 'rgb(var(--color-p-green-10))',
|
|
50
|
+
20: 'rgb(var(--color-p-green-20))',
|
|
51
|
+
30: 'rgb(var(--color-p-green-30))',
|
|
52
|
+
40: 'rgb(var(--color-p-green-40))',
|
|
53
|
+
50: 'rgb(var(--color-p-green-50))',
|
|
54
54
|
},
|
|
55
55
|
'p-red': {
|
|
56
|
-
10: 'var(--color-p-red-10)',
|
|
57
|
-
20: 'var(--color-p-red-20)',
|
|
58
|
-
30: 'var(--color-p-red-30)',
|
|
59
|
-
40: 'var(--color-p-red-40)',
|
|
60
|
-
50: 'var(--color-p-red-50)',
|
|
56
|
+
10: 'rgb(var(--color-p-red-10))',
|
|
57
|
+
20: 'rgb(var(--color-p-red-20))',
|
|
58
|
+
30: 'rgb(var(--color-p-red-30))',
|
|
59
|
+
40: 'rgb(var(--color-p-red-40))',
|
|
60
|
+
50: 'rgb(var(--color-p-red-50))',
|
|
61
61
|
},
|
|
62
62
|
/* Aliases */
|
|
63
|
-
primary: 'var(--color-primary)',
|
|
64
|
-
accent: 'var(--color-accent)',
|
|
65
|
-
surface: 'var(--color-surface)',
|
|
66
|
-
'on-surface': 'var(--color-on-surface)',
|
|
67
|
-
error: 'var(--color-error)',
|
|
68
|
-
'on-error': 'var(--color-on-error)',
|
|
69
|
-
info: 'var(--color-info)',
|
|
70
|
-
'on-info': 'var(--color-on-info)',
|
|
71
|
-
success: 'var(--color-success)',
|
|
72
|
-
'on-success': 'var(--color-on-success)',
|
|
73
|
-
warning: 'var(--color-warning)',
|
|
74
|
-
'on-warning': 'var(--color-on-warning)',
|
|
63
|
+
primary: 'rgb(var(--color-primary))',
|
|
64
|
+
accent: 'rgb(var(--color-accent))',
|
|
65
|
+
surface: 'rgb(var(--color-surface))',
|
|
66
|
+
'on-surface': 'rgb(var(--color-on-surface))',
|
|
67
|
+
error: 'rgb(var(--color-error))',
|
|
68
|
+
'on-error': 'rgb(var(--color-on-error))',
|
|
69
|
+
info: 'rgb(var(--color-info))',
|
|
70
|
+
'on-info': 'rgb(var(--color-on-info))',
|
|
71
|
+
success: 'rgb(var(--color-success))',
|
|
72
|
+
'on-success': 'rgb(var(--color-on-success))',
|
|
73
|
+
warning: 'rgb(var(--color-warning))',
|
|
74
|
+
'on-warning': 'rgb(var(--color-on-warning))',
|
|
75
75
|
},
|
|
76
76
|
fontFamily: {
|
|
77
77
|
sans: ['Inter', 'Helvetica', 'Arial', 'sans-serif'],
|
|
@@ -90,7 +90,7 @@ export const config = {
|
|
|
90
90
|
},
|
|
91
91
|
extend: {
|
|
92
92
|
borderColor: {
|
|
93
|
-
DEFAULT: 'var(--color-p-gray-30)',
|
|
93
|
+
DEFAULT: 'rgb(var(--color-p-gray-30))',
|
|
94
94
|
},
|
|
95
95
|
spacing: {
|
|
96
96
|
7.5: '1.875rem',
|
|
@@ -1,154 +0,0 @@
|
|
|
1
|
-
import { type PropType, type StyleValue } from 'vue';
|
|
2
|
-
declare const _default: import("vue").DefineComponent<{
|
|
3
|
-
modelValue: {
|
|
4
|
-
type: PropType<string | null | undefined>;
|
|
5
|
-
default: string;
|
|
6
|
-
};
|
|
7
|
-
label: {
|
|
8
|
-
type: StringConstructor;
|
|
9
|
-
default: string;
|
|
10
|
-
};
|
|
11
|
-
errorMsg: {
|
|
12
|
-
type: StringConstructor;
|
|
13
|
-
default: string;
|
|
14
|
-
};
|
|
15
|
-
required: {
|
|
16
|
-
type: BooleanConstructor;
|
|
17
|
-
default: boolean;
|
|
18
|
-
};
|
|
19
|
-
minDate: {
|
|
20
|
-
type: DateConstructor;
|
|
21
|
-
default: null;
|
|
22
|
-
};
|
|
23
|
-
maxDate: {
|
|
24
|
-
type: DateConstructor;
|
|
25
|
-
default: null;
|
|
26
|
-
};
|
|
27
|
-
timezone: {
|
|
28
|
-
type: StringConstructor;
|
|
29
|
-
default: string;
|
|
30
|
-
};
|
|
31
|
-
}, unknown, {
|
|
32
|
-
innerValue: Date | null;
|
|
33
|
-
selectAttribute: Partial<{
|
|
34
|
-
key: string | number;
|
|
35
|
-
hashcode: string;
|
|
36
|
-
content: import("v-calendar/dist/types/src/utils/glyph.js").ContentConfig;
|
|
37
|
-
highlight: import("v-calendar/dist/types/src/utils/glyph.js").HighlightConfig;
|
|
38
|
-
dot: import("v-calendar/dist/types/src/utils/glyph.js").DotConfig;
|
|
39
|
-
bar: import("v-calendar/dist/types/src/utils/glyph.js").BarConfig;
|
|
40
|
-
popover: import("v-calendar/dist/types/src/utils/attribute.js").PopoverConfig;
|
|
41
|
-
event: import("v-calendar/dist/types/src/utils/attribute.js").EventConfig;
|
|
42
|
-
dates: import("v-calendar/dist/types/src/utils/date/range.js").DateRangeSource[];
|
|
43
|
-
customData: any;
|
|
44
|
-
order: number;
|
|
45
|
-
pinPage: boolean;
|
|
46
|
-
}>;
|
|
47
|
-
}, {
|
|
48
|
-
masks(): {
|
|
49
|
-
input: string;
|
|
50
|
-
data: string;
|
|
51
|
-
};
|
|
52
|
-
attrs(): {
|
|
53
|
-
[x: string]: unknown;
|
|
54
|
-
};
|
|
55
|
-
listeners(): {};
|
|
56
|
-
style(): StyleValue;
|
|
57
|
-
styleDatepicker(): {
|
|
58
|
-
border: string;
|
|
59
|
-
} | {
|
|
60
|
-
border?: undefined;
|
|
61
|
-
};
|
|
62
|
-
}, {
|
|
63
|
-
dayclick(e: {
|
|
64
|
-
id: string;
|
|
65
|
-
}): void;
|
|
66
|
-
}, import("vue").DefineComponent<{
|
|
67
|
-
size: {
|
|
68
|
-
type: PropType<import("../../index.js").InputSize>;
|
|
69
|
-
default: string;
|
|
70
|
-
validator(value: import("../../index.js").InputSize): boolean;
|
|
71
|
-
};
|
|
72
|
-
errorMsg: {
|
|
73
|
-
type: StringConstructor;
|
|
74
|
-
default: string;
|
|
75
|
-
};
|
|
76
|
-
required: {
|
|
77
|
-
type: BooleanConstructor;
|
|
78
|
-
default: boolean;
|
|
79
|
-
};
|
|
80
|
-
rounded: {
|
|
81
|
-
type: BooleanConstructor;
|
|
82
|
-
default: boolean;
|
|
83
|
-
};
|
|
84
|
-
}, unknown, {
|
|
85
|
-
errorMsgClasses: string;
|
|
86
|
-
}, {
|
|
87
|
-
inputClasses(): string;
|
|
88
|
-
labelClasses(): string;
|
|
89
|
-
selectClasses(): string;
|
|
90
|
-
textareaClasses(): string;
|
|
91
|
-
}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
92
|
-
size: {
|
|
93
|
-
type: PropType<import("../../index.js").InputSize>;
|
|
94
|
-
default: string;
|
|
95
|
-
validator(value: import("../../index.js").InputSize): boolean;
|
|
96
|
-
};
|
|
97
|
-
errorMsg: {
|
|
98
|
-
type: StringConstructor;
|
|
99
|
-
default: string;
|
|
100
|
-
};
|
|
101
|
-
required: {
|
|
102
|
-
type: BooleanConstructor;
|
|
103
|
-
default: boolean;
|
|
104
|
-
};
|
|
105
|
-
rounded: {
|
|
106
|
-
type: BooleanConstructor;
|
|
107
|
-
default: boolean;
|
|
108
|
-
};
|
|
109
|
-
}>>, {
|
|
110
|
-
size: "sm" | "lg" | "md";
|
|
111
|
-
rounded: boolean;
|
|
112
|
-
required: boolean;
|
|
113
|
-
errorMsg: string;
|
|
114
|
-
}, {}>, import("vue").ComponentOptionsMixin, "update:modelValue"[], "update:modelValue", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
115
|
-
modelValue: {
|
|
116
|
-
type: PropType<string | null | undefined>;
|
|
117
|
-
default: string;
|
|
118
|
-
};
|
|
119
|
-
label: {
|
|
120
|
-
type: StringConstructor;
|
|
121
|
-
default: string;
|
|
122
|
-
};
|
|
123
|
-
errorMsg: {
|
|
124
|
-
type: StringConstructor;
|
|
125
|
-
default: string;
|
|
126
|
-
};
|
|
127
|
-
required: {
|
|
128
|
-
type: BooleanConstructor;
|
|
129
|
-
default: boolean;
|
|
130
|
-
};
|
|
131
|
-
minDate: {
|
|
132
|
-
type: DateConstructor;
|
|
133
|
-
default: null;
|
|
134
|
-
};
|
|
135
|
-
maxDate: {
|
|
136
|
-
type: DateConstructor;
|
|
137
|
-
default: null;
|
|
138
|
-
};
|
|
139
|
-
timezone: {
|
|
140
|
-
type: StringConstructor;
|
|
141
|
-
default: string;
|
|
142
|
-
};
|
|
143
|
-
}>> & {
|
|
144
|
-
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
145
|
-
}, {
|
|
146
|
-
label: string;
|
|
147
|
-
required: boolean;
|
|
148
|
-
modelValue: string | null | undefined;
|
|
149
|
-
errorMsg: string;
|
|
150
|
-
timezone: string;
|
|
151
|
-
minDate: Date;
|
|
152
|
-
maxDate: Date;
|
|
153
|
-
}, {}>;
|
|
154
|
-
export default _default;
|