frappe-ui 0.1.239 → 0.1.242
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.
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
<div class="w-[85%] lg:w-[700px] mx-auto py-12 space-y-8">
|
|
2
|
+
<div class="w-[85%] lg:w-[700px] mx-auto py-12 space-y-8 text-base">
|
|
3
3
|
<div class="flex justify-between">
|
|
4
4
|
<div class="space-y-2">
|
|
5
5
|
<div class="text-lg font-semibold text-ink-gray-9">
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
{{ data?.status }}
|
|
11
11
|
</Badge>
|
|
12
12
|
</div>
|
|
13
|
-
<div class="leading-5">
|
|
13
|
+
<div class="leading-5 text-ink-gray-7">
|
|
14
14
|
Change the mapping of columns from your file to fields in the system
|
|
15
15
|
</div>
|
|
16
16
|
</div>
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
variant="solid" @click="startImport" />
|
|
18
18
|
<Button v-else-if="listRoute" label="Done" @click="redirectToList()" />
|
|
19
19
|
</div>
|
|
20
|
-
<div class="leading-5">
|
|
20
|
+
<div class="leading-5 text-ink-gray-7">
|
|
21
21
|
Verify the data before starting the import process
|
|
22
22
|
</div>
|
|
23
23
|
</div>
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
<div class="text-ink-gray-5 text-sm">
|
|
27
27
|
Column Mapping
|
|
28
28
|
</div>
|
|
29
|
-
<div class="border rounded-md bg-surface-gray-2 p-4 space-y-4 text-sm">
|
|
29
|
+
<div class="border rounded-md bg-surface-gray-2 p-4 space-y-4 text-sm text-ink-gray-7">
|
|
30
30
|
<div v-for="map in mapping" class="grid grid-cols-[40%,10%,40%] lg:grid-cols-3 space-x-3 items-center">
|
|
31
31
|
<div class="">
|
|
32
32
|
{{ map[0] }}
|
|
@@ -48,7 +48,7 @@
|
|
|
48
48
|
<div class="rounded-md bg-surface-amber-2 p-2 space-y-2 text-xs">
|
|
49
49
|
<div v-for="warning in warnings" class="flex items-center space-x-2">
|
|
50
50
|
<FeatherIcon name="alert-circle" class="size-3 text-ink-amber-3" />
|
|
51
|
-
<div v-html="warning.message" class=""></div>
|
|
51
|
+
<div v-html="warning.message" class="text-ink-amber-3"></div>
|
|
52
52
|
</div>
|
|
53
53
|
</div>
|
|
54
54
|
</div>
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
class="hidden"
|
|
39
39
|
@change="(e) => uploadFile(e)"
|
|
40
40
|
/>
|
|
41
|
-
<div class="leading-5">
|
|
41
|
+
<div class="leading-5 text-ink-gray-9">
|
|
42
42
|
Drag and drop a CSV file, or upload from your
|
|
43
43
|
<span @click="openFileSelector" class="cursor-pointer font-semibold hover:underline">Device</span>
|
|
44
44
|
or
|
|
@@ -67,7 +67,7 @@
|
|
|
67
67
|
<div v-else-if="importFile" class="h-[300px] flex items-center justify-center bg-surface-gray-1 border border-dashed border-outline-gray-3 rounded-md">
|
|
68
68
|
<div class="w-4/5 lg:w-2/5 bg-surface-white border rounded-md p-2 flex items-center justify-between items-center">
|
|
69
69
|
<div class="space-y-2">
|
|
70
|
-
<div class="font-medium leading-5">
|
|
70
|
+
<div class="font-medium leading-5 text-ink-gray-9">
|
|
71
71
|
{{ importFile.file_name || importFile.split("/").pop() }}
|
|
72
72
|
</div>
|
|
73
73
|
<div v-if="importFile.file_size" class="text-ink-gray-6">
|
package/package.json
CHANGED
|
@@ -70,7 +70,7 @@ const selectClasses = computed(() => {
|
|
|
70
70
|
fontSizeClasses.value,
|
|
71
71
|
paddingClasses.value,
|
|
72
72
|
variantClasses,
|
|
73
|
-
'transition-colors w-full data-[state=open]:ring-2 ring-outline-gray-
|
|
73
|
+
'transition-colors w-full focus:ring-2 data-[state=open]:ring-2 ring-outline-gray-3 ',
|
|
74
74
|
]
|
|
75
75
|
})
|
|
76
76
|
|
|
@@ -84,23 +84,21 @@ const selectOptions = computed(() => {
|
|
|
84
84
|
<template>
|
|
85
85
|
<SelectRoot v-model="model">
|
|
86
86
|
<SelectTrigger
|
|
87
|
-
class="inline-flex items-center gap-2 outline-none text-base data-[placeholder]:text-ink-gray-4 data-[disabled]:text-ink-gray-4"
|
|
87
|
+
class="inline-flex items-center gap-2 outline-none text-base text-ink-gray-7 data-[placeholder]:text-ink-gray-4 data-[disabled]:text-ink-gray-4"
|
|
88
88
|
aria-label="Customise options"
|
|
89
|
-
:class="selectClasses"
|
|
90
|
-
:disabled="
|
|
89
|
+
:class="[selectClasses, $attrs.class]"
|
|
90
|
+
:disabled="disabled"
|
|
91
91
|
>
|
|
92
92
|
<slot name="prefix" />
|
|
93
|
-
<SelectValue :placeholder="
|
|
93
|
+
<SelectValue :placeholder="placeholder" class='truncate' />
|
|
94
94
|
<slot name="suffix">
|
|
95
|
-
<LucideChevronDown class="size-4 text-ink-gray-4 ml-auto" />
|
|
95
|
+
<LucideChevronDown class="size-4 text-ink-gray-4 ml-auto shrink-0" />
|
|
96
96
|
</slot>
|
|
97
97
|
</SelectTrigger>
|
|
98
98
|
|
|
99
99
|
<SelectPortal>
|
|
100
100
|
<SelectContent
|
|
101
|
-
class="bg-surface-modal border rounded-lg shadow-lg will-change-[opacity,transform] z-[100]
|
|
102
|
-
:side-offset="5"
|
|
103
|
-
position="popper"
|
|
101
|
+
class="bg-surface-modal border rounded-lg shadow-lg will-change-[opacity,transform] z-[100] overflow-hidden origin-center data-[state=open]:animate-[fadeInScale_150ms] data-[state=closed]:animate-[fadeOutScale_150ms]"
|
|
104
102
|
>
|
|
105
103
|
<SelectViewport class="p-1 flex flex-col">
|
|
106
104
|
<SelectItem
|
|
@@ -109,13 +107,16 @@ const selectOptions = computed(() => {
|
|
|
109
107
|
:key="option.value"
|
|
110
108
|
:value="option.value"
|
|
111
109
|
:class="[sizeClasses, paddingClasses, fontSizeClasses]"
|
|
112
|
-
|
|
110
|
+
class="
|
|
111
|
+
text-base text-ink-gray-9 flex items-center relative
|
|
112
|
+
data-[highlighted]:bg-surface-gray-2 border-0 [data-state=checked]:bg-surface-gray-2
|
|
113
|
+
data-[disabled]:text-ink-gray-4 select-none
|
|
114
|
+
"
|
|
113
115
|
>
|
|
114
116
|
<SelectItemText>
|
|
115
117
|
<slot name="option" v-bind="{ option }">{{ option.label }}</slot>
|
|
116
118
|
</SelectItemText>
|
|
117
119
|
</SelectItem>
|
|
118
|
-
|
|
119
120
|
<slot name="footer" />
|
|
120
121
|
</SelectViewport>
|
|
121
122
|
</SelectContent>
|
|
@@ -123,39 +124,33 @@ const selectOptions = computed(() => {
|
|
|
123
124
|
</SelectRoot>
|
|
124
125
|
</template>
|
|
125
126
|
|
|
127
|
+
<style scoped>
|
|
128
|
+
[data-highlighted],
|
|
129
|
+
[data-state='checked'] {
|
|
130
|
+
outline: none !important;
|
|
131
|
+
}
|
|
132
|
+
</style>
|
|
133
|
+
|
|
126
134
|
<style>
|
|
127
|
-
@keyframes
|
|
135
|
+
@keyframes fadeInScale {
|
|
128
136
|
from {
|
|
129
137
|
opacity: 0;
|
|
130
|
-
transform:
|
|
138
|
+
transform: scale(0.90);
|
|
131
139
|
}
|
|
132
140
|
to {
|
|
133
141
|
opacity: 1;
|
|
134
|
-
transform:
|
|
142
|
+
transform: scale(1);
|
|
135
143
|
}
|
|
136
144
|
}
|
|
137
145
|
|
|
138
|
-
@keyframes
|
|
146
|
+
@keyframes fadeOutScale {
|
|
139
147
|
from {
|
|
140
|
-
opacity:
|
|
141
|
-
transform:
|
|
148
|
+
opacity: 1;
|
|
149
|
+
transform: scale(1);
|
|
142
150
|
}
|
|
143
151
|
to {
|
|
144
|
-
opacity:
|
|
145
|
-
transform:
|
|
152
|
+
opacity: 0;
|
|
153
|
+
transform: scale(0.95);
|
|
146
154
|
}
|
|
147
155
|
}
|
|
148
|
-
|
|
149
|
-
[data-side='top'] {
|
|
150
|
-
animation: slideDownFade 280ms;
|
|
151
|
-
}
|
|
152
|
-
|
|
153
|
-
[data-side='bottom'] {
|
|
154
|
-
animation: slideUpFade 280ms;
|
|
155
|
-
}
|
|
156
|
-
|
|
157
|
-
[data-highlighted],
|
|
158
|
-
[data-state='checked'] {
|
|
159
|
-
outline: none !important;
|
|
160
|
-
}
|
|
161
156
|
</style>
|
package/src/index.ts
CHANGED
|
@@ -1,3 +1,6 @@
|
|
|
1
|
+
// old data-fetching: resources
|
|
2
|
+
export * from './resources/index.ts'
|
|
3
|
+
|
|
1
4
|
// components
|
|
2
5
|
export * from './components/Alert'
|
|
3
6
|
export * from './components/Autocomplete'
|
|
@@ -92,9 +95,6 @@ export * from './utils/theme'
|
|
|
92
95
|
export * from './components/TextEditor/extensions/image'
|
|
93
96
|
export * from './components/TextEditor/extensions/suggestion'
|
|
94
97
|
|
|
95
|
-
// old data-fetching: resources
|
|
96
|
-
export * from './resources/index.ts'
|
|
97
|
-
|
|
98
98
|
export { request } from './utils/request.js'
|
|
99
99
|
export { frappeRequest } from './utils/frappeRequest.js'
|
|
100
100
|
export { default as initSocket } from './utils/socketio.js'
|