@bagelink/vue 0.0.160 → 0.0.162
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/components/Btn.vue.d.ts +2 -2
- package/dist/components/Btn.vue.d.ts.map +1 -1
- package/dist/components/Comments.vue.d.ts.map +1 -1
- package/dist/components/DropDown.vue.d.ts.map +1 -1
- package/dist/components/FileUploader.vue.d.ts.map +1 -1
- package/dist/components/LangText.vue.d.ts.map +1 -1
- package/dist/components/NavBar.vue.d.ts.map +1 -1
- package/dist/components/PersonPreview.vue.d.ts +1 -1
- package/dist/components/PersonPreview.vue.d.ts.map +1 -1
- package/dist/components/PersonPreviewFormkit.vue.d.ts +1 -1
- package/dist/components/PersonPreviewFormkit.vue.d.ts.map +1 -1
- package/dist/components/RTXEditor.vue.d.ts.map +1 -1
- package/dist/components/TableSchema.vue.d.ts.map +1 -1
- package/dist/components/charts/BarChart.vue.d.ts.map +1 -1
- package/dist/components/dashboard/Lineart.vue.d.ts +1 -1
- package/dist/components/dashboard/Lineart.vue.d.ts.map +1 -1
- package/dist/components/form/inputs/CheckInput.vue.d.ts.map +1 -1
- package/dist/components/form/inputs/Checkbox.vue.d.ts.map +1 -1
- package/dist/components/form/inputs/PasswordInput.vue.d.ts.map +1 -1
- package/dist/components/formkit/AddressArray.vue.d.ts.map +1 -1
- package/dist/components/formkit/BankDetailsArray.vue.d.ts.map +1 -1
- package/dist/components/formkit/ContactArrayFormKit.vue.d.ts.map +1 -1
- package/dist/components/formkit/FileUploader.vue.d.ts.map +1 -1
- package/dist/components/formkit/MiscFields.vue.d.ts.map +1 -1
- package/dist/index.cjs +60 -49
- package/dist/index.mjs +60 -49
- package/dist/style.css +1468 -1402
- package/package.json +1 -1
- package/src/components/Btn.vue +127 -132
- package/src/components/Comments.vue +155 -169
- package/src/components/DropDown.vue +73 -77
- package/src/components/FileUploader.vue +133 -141
- package/src/components/FormKitTable.vue +191 -205
- package/src/components/LangText.vue +14 -14
- package/src/components/NavBar.vue +264 -261
- package/src/components/PersonPreview.vue +123 -148
- package/src/components/PersonPreviewFormkit.vue +124 -148
- package/src/components/RTXEditor.vue +91 -91
- package/src/components/TableSchema.vue +150 -156
- package/src/components/charts/BarChart.vue +212 -227
- package/src/components/dashboard/Lineart.vue +117 -130
- package/src/components/form/inputs/CheckInput.vue +90 -90
- package/src/components/form/inputs/Checkbox.vue +38 -41
- package/src/components/form/inputs/PasswordInput.vue +56 -63
- package/src/components/formkit/AddressArray.vue +150 -173
- package/src/components/formkit/BankDetailsArray.vue +175 -198
- package/src/components/formkit/ContactArrayFormKit.vue +124 -142
- package/src/components/formkit/FileUploader.vue +256 -260
- package/src/components/formkit/MiscFields.vue +42 -42
- package/src/components/formkit/Toggle.vue +97 -97
- package/src/styles/bagel.css +1 -0
- package/src/styles/buttons.css +5 -0
- package/src/styles/dark.css +46 -0
- package/src/styles/fonts/Ploni.css +8 -8
- package/src/styles/inputs.css +57 -13
- package/src/styles/layout.css +43 -0
- package/src/styles/text.css +83 -10
- package/src/styles/theme.css +25 -155
- package/src/styles/fonts/Ploni/ploni-black.eot +0 -0
- package/src/styles/fonts/Ploni/ploni-black.woff +0 -0
- package/src/styles/fonts/Ploni/ploni-black.woff2 +0 -0
- package/src/styles/fonts/Ploni/ploni-bold.eot +0 -0
- package/src/styles/fonts/Ploni/ploni-bold.woff +0 -0
- package/src/styles/fonts/Ploni/ploni-bold.woff2 +0 -0
- package/src/styles/fonts/Ploni/ploni-demibold.eot +0 -0
- package/src/styles/fonts/Ploni/ploni-demibold.woff +0 -0
- package/src/styles/fonts/Ploni/ploni-demibold.woff2 +0 -0
- package/src/styles/fonts/Ploni/ploni-light.eot +0 -0
- package/src/styles/fonts/Ploni/ploni-light.woff +0 -0
- package/src/styles/fonts/Ploni/ploni-light.woff2 +0 -0
- package/src/styles/fonts/Ploni/ploni-medium.eot +0 -0
- package/src/styles/fonts/Ploni/ploni-medium.woff +0 -0
- package/src/styles/fonts/Ploni/ploni-medium.woff2 +0 -0
- package/src/styles/fonts/Ploni/ploni-regular.eot +0 -0
- package/src/styles/fonts/Ploni/ploni-regular.woff +0 -0
- package/src/styles/fonts/Ploni/ploni-regular.woff2 +0 -0
- package/src/styles/fonts/Ploni/ploni-ultrabold.eot +0 -0
- package/src/styles/fonts/Ploni/ploni-ultrabold.woff +0 -0
- package/src/styles/fonts/Ploni/ploni-ultrabold.woff2 +0 -0
- package/src/styles/fonts/Ploni/ploni-ultralight.eot +0 -0
- package/src/styles/fonts/Ploni/ploni-ultralight.woff +0 -0
- package/src/styles/fonts/Ploni/ploni-ultralight.woff2 +0 -0
|
@@ -1,99 +1,86 @@
|
|
|
1
1
|
<template>
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
</div>
|
|
69
|
-
</div>
|
|
70
|
-
</div>
|
|
71
|
-
</div>
|
|
72
|
-
</div>
|
|
73
|
-
<input
|
|
74
|
-
class="file-input"
|
|
75
|
-
type="file"
|
|
76
|
-
@change="handleFileInput"
|
|
77
|
-
ref="fileInputEl"
|
|
78
|
-
:multiple="context?.attrs.multiple || false"
|
|
79
|
-
>
|
|
80
|
-
</div>
|
|
2
|
+
<div class="files-wrapper flex">
|
|
3
|
+
<div
|
|
4
|
+
ref="dropZoneEl"
|
|
5
|
+
class="drop-zone flex-grow"
|
|
6
|
+
@click="openFileDialog"
|
|
7
|
+
@drop.prevent.stop="onDrop"
|
|
8
|
+
@dragleave="draggingOver = false"
|
|
9
|
+
>
|
|
10
|
+
<Transition name="pop">
|
|
11
|
+
<div ref="dropCircle" v-if="draggingOver" class="drop-circle" />
|
|
12
|
+
</Transition>
|
|
13
|
+
<div class="img-label" v-if="allowUpload">
|
|
14
|
+
<p>
|
|
15
|
+
{{ dragDropLabel }} <span>{{ browseLabel }}</span>
|
|
16
|
+
</p>
|
|
17
|
+
</div>
|
|
18
|
+
<div class="uploading-wrap">
|
|
19
|
+
<div
|
|
20
|
+
v-for="(item, index) in files"
|
|
21
|
+
:class="{ uploading: item.uploading }"
|
|
22
|
+
:key="index"
|
|
23
|
+
>
|
|
24
|
+
<div class="load-file-bar">
|
|
25
|
+
<!-- Preview File if image -->
|
|
26
|
+
<img
|
|
27
|
+
width="40"
|
|
28
|
+
v-if="isImg(item)"
|
|
29
|
+
:src="item.dataUrl"
|
|
30
|
+
:alt="item.name"
|
|
31
|
+
style="margin-inline-end: 10px"
|
|
32
|
+
/>
|
|
33
|
+
<p>
|
|
34
|
+
{{ item.name }}
|
|
35
|
+
</p>
|
|
36
|
+
<div class="flex">
|
|
37
|
+
<div
|
|
38
|
+
class="pie"
|
|
39
|
+
:style="`--p:${item.progress}`"
|
|
40
|
+
style="--b: 2px"
|
|
41
|
+
:class="{ complete: item.progress === 100 }"
|
|
42
|
+
>
|
|
43
|
+
<span class="progress" v-if="item.progress < 100">{{
|
|
44
|
+
`${item.progress.toFixed(0)}`
|
|
45
|
+
}}</span>
|
|
46
|
+
<MaterialIcon class="success" icon="check" />
|
|
47
|
+
</div>
|
|
48
|
+
<Btn
|
|
49
|
+
thin
|
|
50
|
+
class="delete-btn"
|
|
51
|
+
@click.stop="deleteImg(item)"
|
|
52
|
+
icon="delete"
|
|
53
|
+
v-if="item.progress === 100"
|
|
54
|
+
/>
|
|
55
|
+
</div>
|
|
56
|
+
</div>
|
|
57
|
+
</div>
|
|
58
|
+
</div>
|
|
59
|
+
</div>
|
|
60
|
+
<input
|
|
61
|
+
class="file-input"
|
|
62
|
+
type="file"
|
|
63
|
+
@change="handleFileInput"
|
|
64
|
+
ref="fileInputEl"
|
|
65
|
+
:multiple="context?.attrs.multiple || false"
|
|
66
|
+
/>
|
|
67
|
+
</div>
|
|
81
68
|
</template>
|
|
82
69
|
|
|
83
70
|
<script setup lang="ts">
|
|
84
71
|
interface UploadFile {
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
72
|
+
dataUrl: string;
|
|
73
|
+
progress: number;
|
|
74
|
+
uploading: boolean;
|
|
75
|
+
file?: File;
|
|
76
|
+
name: string;
|
|
77
|
+
serverFile?: any;
|
|
78
|
+
uploaded: boolean;
|
|
92
79
|
}
|
|
93
80
|
|
|
94
|
-
import { onMounted, onUnmounted } from
|
|
81
|
+
import { onMounted, onUnmounted } from "vue";
|
|
95
82
|
|
|
96
|
-
import { MaterialIcon, Btn, useBagel } from
|
|
83
|
+
import { MaterialIcon, Btn, useBagel } from "@bagelink/vue";
|
|
97
84
|
|
|
98
85
|
const bagel = useBagel();
|
|
99
86
|
|
|
@@ -104,125 +91,130 @@ const fileInputEl = $ref<HTMLInputElement>();
|
|
|
104
91
|
|
|
105
92
|
const files = $ref<UploadFile[]>([]);
|
|
106
93
|
|
|
107
|
-
const props = withDefaults(
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
94
|
+
const props = withDefaults(
|
|
95
|
+
defineProps<{
|
|
96
|
+
context: Record<string, any>;
|
|
97
|
+
dragDropLabel?: string;
|
|
98
|
+
browseLabel?: string;
|
|
99
|
+
}>(),
|
|
100
|
+
{
|
|
101
|
+
dragDropLabel: "Drag and drop your files here",
|
|
102
|
+
browseLabel: "or browse",
|
|
103
|
+
}
|
|
104
|
+
);
|
|
115
105
|
|
|
116
106
|
const allowUpload = $computed(() => {
|
|
117
|
-
|
|
118
|
-
|
|
107
|
+
const tooManyFiles = !props.context?.attrs.multiple && files.length > 0;
|
|
108
|
+
return !tooManyFiles;
|
|
119
109
|
});
|
|
120
110
|
|
|
121
|
-
const openFileDialog = () => (allowUpload ? fileInputEl?.click() :
|
|
111
|
+
const openFileDialog = () => (allowUpload ? fileInputEl?.click() : "");
|
|
122
112
|
|
|
123
113
|
function animateCircle(e: DragEvent) {
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
114
|
+
e.preventDefault();
|
|
115
|
+
const zoneRect = dropZoneEl?.getBoundingClientRect?.();
|
|
116
|
+
if (!zoneRect) return;
|
|
117
|
+
draggingOver = true;
|
|
118
|
+
const left = e.clientX - zoneRect.left;
|
|
119
|
+
const top = e.clientY - zoneRect.top;
|
|
120
|
+
dropCircle?.style?.setProperty?.("left", `${left}px`);
|
|
121
|
+
dropCircle?.style?.setProperty?.("top", `${top}px`);
|
|
132
122
|
}
|
|
133
123
|
|
|
134
124
|
function emitValue() {
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
125
|
+
// const fileValues = files.map((f) => f.serverFile?.id);
|
|
126
|
+
// console.log({ files });
|
|
127
|
+
if (!props.context?.attrs.multiple)
|
|
128
|
+
props.context?.node.input(files[0].serverFile);
|
|
129
|
+
// eslint-disable-next-line no-alert
|
|
130
|
+
else alert("not implemented");
|
|
140
131
|
}
|
|
141
132
|
|
|
142
|
-
const isImg = (file: UploadFile) =>
|
|
143
|
-
|
|
144
|
-
|
|
133
|
+
const isImg = (file: UploadFile) =>
|
|
134
|
+
file.file?.type.includes("image") ||
|
|
135
|
+
file.serverFile?.mimetype?.match(/image\/|jpg|png|gif|bmp|jpeg/i) ||
|
|
136
|
+
file.serverFile.extension?.match(/jpg|png|gif|bmp|jpeg/i);
|
|
145
137
|
|
|
146
138
|
function uploadFiles() {
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
139
|
+
files.forEach(async (file) => {
|
|
140
|
+
if (file.uploaded || file.uploading || !file.file) return;
|
|
141
|
+
file.uploading = true;
|
|
142
|
+
file.serverFile = await bagel.uploadFile(file.file, {
|
|
143
|
+
onUploadProgress: (e) => (file.progress = e.progress * 100 - 1),
|
|
144
|
+
});
|
|
145
|
+
file.progress += 1;
|
|
146
|
+
emitValue();
|
|
147
|
+
file.uploaded = true;
|
|
148
|
+
file.uploading = false;
|
|
149
|
+
});
|
|
158
150
|
}
|
|
159
151
|
|
|
160
152
|
const deleteImg = async (file: UploadFile) => {
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
153
|
+
await bagel.delete(`files/${file.serverFile.id}`);
|
|
154
|
+
const index = files.indexOf(file);
|
|
155
|
+
files.splice(index, 1);
|
|
156
|
+
emitValue();
|
|
165
157
|
};
|
|
166
158
|
|
|
167
159
|
function readAsDataURL(file: File): Promise<any> {
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
160
|
+
return new Promise((resolve, reject) => {
|
|
161
|
+
const reader = new FileReader();
|
|
162
|
+
reader.onload = () => resolve(reader.result);
|
|
163
|
+
reader.onerror = reject;
|
|
164
|
+
reader.readAsDataURL(file);
|
|
165
|
+
});
|
|
174
166
|
}
|
|
175
167
|
|
|
176
168
|
async function addFiles(addedFiles: FileList) {
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
169
|
+
if (!allowUpload) return;
|
|
170
|
+
for (let i = 0; i < addedFiles.length; i++) {
|
|
171
|
+
const f = addedFiles[i];
|
|
172
|
+
const file: UploadFile = {
|
|
173
|
+
// eslint-disable-next-line no-await-in-loop
|
|
174
|
+
dataUrl: await readAsDataURL(f),
|
|
175
|
+
file: f,
|
|
176
|
+
name: f.name,
|
|
177
|
+
progress: 0,
|
|
178
|
+
uploading: false,
|
|
179
|
+
uploaded: false,
|
|
180
|
+
};
|
|
181
|
+
files.push(file);
|
|
182
|
+
}
|
|
183
|
+
uploadFiles();
|
|
192
184
|
}
|
|
193
185
|
|
|
194
186
|
onMounted(() => {
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
187
|
+
dropZoneEl?.addEventListener("dragover", animateCircle);
|
|
188
|
+
if (!props.context?.attrs.multiple && props.context?.value) {
|
|
189
|
+
files.push({
|
|
190
|
+
serverFile: props.context?.value,
|
|
191
|
+
uploaded: true,
|
|
192
|
+
uploading: false,
|
|
193
|
+
progress: 100,
|
|
194
|
+
dataUrl: props.context?.value?.url,
|
|
195
|
+
name: props.context?.value?.name,
|
|
196
|
+
});
|
|
197
|
+
}
|
|
206
198
|
});
|
|
207
|
-
onUnmounted(() => dropZoneEl?.removeEventListener(
|
|
199
|
+
onUnmounted(() => dropZoneEl?.removeEventListener("dragover", animateCircle));
|
|
208
200
|
|
|
209
201
|
function handleFileInput(e: Event) {
|
|
210
|
-
|
|
211
|
-
|
|
202
|
+
const filesToAdd: FileList = (e.target as any).files;
|
|
203
|
+
void addFiles(filesToAdd); // TODO: Nati: should be awaited?
|
|
212
204
|
}
|
|
213
205
|
|
|
214
206
|
function onDrop(e: DragEvent) {
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
207
|
+
draggingOver = false;
|
|
208
|
+
e.preventDefault();
|
|
209
|
+
const filesToAdd = e.dataTransfer?.files;
|
|
210
|
+
if (filesToAdd) void addFiles(filesToAdd); // TODO: Nati: should be awaited?
|
|
219
211
|
}
|
|
220
212
|
</script>
|
|
221
213
|
<style>
|
|
222
214
|
.uploading-wrap {
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
215
|
+
width: 100%;
|
|
216
|
+
padding-right: 5px;
|
|
217
|
+
padding-left: 5px;
|
|
226
218
|
}
|
|
227
219
|
|
|
228
220
|
/*
|
|
@@ -230,162 +222,166 @@ function onDrop(e: DragEvent) {
|
|
|
230
222
|
*/
|
|
231
223
|
|
|
232
224
|
.img-label .icon-font {
|
|
233
|
-
|
|
234
|
-
|
|
225
|
+
font-size: 30px;
|
|
226
|
+
margin-bottom: 10px;
|
|
235
227
|
}
|
|
236
228
|
|
|
237
229
|
.img-label span {
|
|
238
|
-
|
|
230
|
+
text-decoration: underline;
|
|
239
231
|
}
|
|
240
232
|
|
|
241
233
|
.file-input {
|
|
242
|
-
|
|
234
|
+
display: none;
|
|
243
235
|
}
|
|
244
236
|
|
|
245
237
|
.files-wrapper {
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
238
|
+
flex-direction: column;
|
|
239
|
+
border-radius: 10px;
|
|
240
|
+
/*overflow: hidden;*/
|
|
241
|
+
min-height: calc(var(--input-height) * 1.5);
|
|
250
242
|
|
|
251
|
-
|
|
243
|
+
font-size: var(--input-font-size);
|
|
252
244
|
}
|
|
253
245
|
|
|
254
246
|
.drop-zone {
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
247
|
+
background-color: var(--input-bg);
|
|
248
|
+
height: 100%;
|
|
249
|
+
width: 100%;
|
|
250
|
+
flex-grow: 1;
|
|
251
|
+
position: relative;
|
|
252
|
+
overflow: hidden;
|
|
253
|
+
cursor: pointer;
|
|
254
|
+
transition: var(--bgl-transition);
|
|
255
|
+
outline: dashed 1px var(--border-color);
|
|
256
|
+
border-radius: 10px;
|
|
257
|
+
padding: 1px;
|
|
258
|
+
display: flex;
|
|
259
|
+
flex-direction: column;
|
|
260
|
+
align-items: center;
|
|
261
|
+
justify-content: center;
|
|
262
|
+
color: var(--input-color);
|
|
271
263
|
}
|
|
272
264
|
|
|
273
265
|
.drop-zone:hover {
|
|
274
|
-
|
|
275
|
-
|
|
266
|
+
color: var(--bgl-primary);
|
|
267
|
+
outline: dashed 1px var(--bgl-primary-tint);
|
|
276
268
|
}
|
|
277
269
|
|
|
278
270
|
.drop-circle {
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
271
|
+
pointer-events: none;
|
|
272
|
+
position: absolute;
|
|
273
|
+
width: 100px;
|
|
274
|
+
height: 100px;
|
|
275
|
+
border-radius: 50%;
|
|
276
|
+
background-color: var(--bgl-primary-tint);
|
|
277
|
+
display: flex;
|
|
278
|
+
transform: translate(-50%, -50%) scale(1);
|
|
279
|
+
transform-origin: left top;
|
|
288
280
|
}
|
|
289
281
|
|
|
290
282
|
.load-file-bar {
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
283
|
+
display: flex;
|
|
284
|
+
align-items: center;
|
|
285
|
+
justify-content: space-between;
|
|
286
|
+
background: var(--bgl-white);
|
|
287
|
+
border-radius: var(--btn-border-radius);
|
|
288
|
+
width: 100%;
|
|
289
|
+
color: var(--input-color);
|
|
290
|
+
height: var(--btn-height);
|
|
291
|
+
padding: 0.5rem;
|
|
292
|
+
height: 46px;
|
|
293
|
+
box-shadow: 0 1px 2px 0 rgb(0 0 0 / 10%);
|
|
294
|
+
white-space: nowrap;
|
|
303
295
|
}
|
|
304
296
|
|
|
305
297
|
.load-file-bar p {
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
298
|
+
width: calc(100% - 40px);
|
|
299
|
+
overflow: hidden;
|
|
300
|
+
text-overflow: ellipsis;
|
|
309
301
|
}
|
|
310
302
|
|
|
311
303
|
.load-file-bar span {
|
|
312
|
-
|
|
304
|
+
font-size: 10px;
|
|
313
305
|
}
|
|
314
306
|
|
|
315
307
|
.pie {
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
308
|
+
width: 30px;
|
|
309
|
+
height: 30px;
|
|
310
|
+
position: relative;
|
|
311
|
+
display: flex;
|
|
312
|
+
align-items: center;
|
|
313
|
+
justify-content: center;
|
|
322
314
|
}
|
|
323
315
|
|
|
324
316
|
.pie:before {
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
317
|
+
content: "";
|
|
318
|
+
position: absolute;
|
|
319
|
+
border-radius: 50%;
|
|
320
|
+
inset: 0;
|
|
321
|
+
transition: all 0.2s ease-in-out;
|
|
322
|
+
background: conic-gradient(var(--bgl-primary) calc(var(--p) * 1%), #0000 0);
|
|
323
|
+
-webkit-mask: radial-gradient(
|
|
324
|
+
farthest-side,
|
|
325
|
+
#0000 calc(99% - var(--b)),
|
|
326
|
+
#000 calc(100% - var(--b))
|
|
327
|
+
);
|
|
328
|
+
mask: radial-gradient(
|
|
329
|
+
farthest-side,
|
|
330
|
+
#0000 calc(99% - var(--b)),
|
|
331
|
+
#000 calc(100% - var(--b))
|
|
332
|
+
);
|
|
337
333
|
}
|
|
338
334
|
|
|
339
335
|
.pie .success {
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
336
|
+
transform: scale(0);
|
|
337
|
+
opacity: 0;
|
|
338
|
+
transition: all 0.3s ease-in-out;
|
|
343
339
|
}
|
|
344
340
|
|
|
345
341
|
.pie .progress {
|
|
346
|
-
|
|
347
|
-
|
|
342
|
+
position: absolute;
|
|
343
|
+
font-size: 10px;
|
|
348
344
|
}
|
|
349
345
|
|
|
350
346
|
.pie.complete .progress {
|
|
351
|
-
|
|
347
|
+
display: none;
|
|
352
348
|
}
|
|
353
349
|
|
|
354
350
|
.pie.complete .success {
|
|
355
|
-
|
|
356
|
-
|
|
351
|
+
transform: scale(1.3);
|
|
352
|
+
opacity: 1;
|
|
357
353
|
}
|
|
358
354
|
|
|
359
355
|
.pie.complete:before {
|
|
360
|
-
|
|
356
|
+
background: conic-gradient(var(--bgl-green) calc(var(--p) * 1%), #0000 0);
|
|
361
357
|
}
|
|
362
358
|
|
|
363
359
|
.pie.complete {
|
|
364
|
-
|
|
360
|
+
color: var(--bgl-green);
|
|
365
361
|
}
|
|
366
362
|
</style>
|
|
367
363
|
<style>
|
|
368
364
|
.pop-enter-active {
|
|
369
|
-
|
|
365
|
+
transition: scale 0.2s cubic-bezier(0.55, 0, 0.1, 1);
|
|
370
366
|
}
|
|
371
367
|
|
|
372
368
|
.pop-leave-active {
|
|
373
|
-
|
|
369
|
+
transition: scale 0.2s cubic-bezier(0.55, 0, 0.1, 1);
|
|
374
370
|
}
|
|
375
371
|
|
|
376
372
|
.pop-enter-from,
|
|
377
373
|
.pop-leave-to {
|
|
378
|
-
|
|
374
|
+
scale: 0;
|
|
379
375
|
}
|
|
380
376
|
|
|
381
377
|
.delete-btn {
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
378
|
+
margin-inline-end: -30px;
|
|
379
|
+
opacity: 0;
|
|
380
|
+
margin-inline-start: 10px;
|
|
385
381
|
}
|
|
386
382
|
|
|
387
383
|
.uploading-wrap:hover .delete-btn {
|
|
388
|
-
|
|
389
|
-
|
|
384
|
+
opacity: 1;
|
|
385
|
+
margin-inline-end: 0;
|
|
390
386
|
}
|
|
391
387
|
</style>
|