@seedgrid/fe-components 2026.11.0 → 2026.11.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/ai/seedgrid-components.manifest.json +1201 -4
- package/dist/generated/compiledStyles.d.ts +1 -1
- package/dist/generated/compiledStyles.d.ts.map +1 -1
- package/dist/generated/compiledStyles.js +1 -1
- package/dist/i18n/en-US.d.ts.map +1 -1
- package/dist/i18n/en-US.js +31 -0
- package/dist/i18n/es.d.ts.map +1 -1
- package/dist/i18n/es.js +31 -0
- package/dist/i18n/fr.d.ts.map +1 -1
- package/dist/i18n/fr.js +31 -0
- package/dist/i18n/pt-BR.d.ts.map +1 -1
- package/dist/i18n/pt-BR.js +31 -0
- package/dist/i18n/pt-PT.d.ts.map +1 -1
- package/dist/i18n/pt-PT.js +31 -0
- package/dist/index.d.ts +9 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +4 -0
- package/dist/inputs/SgCameraCapture.d.ts +25 -0
- package/dist/inputs/SgCameraCapture.d.ts.map +1 -0
- package/dist/inputs/SgCameraCapture.js +114 -0
- package/dist/inputs/SgCameraCapture.meta.d.ts +4 -0
- package/dist/inputs/SgCameraCapture.meta.d.ts.map +1 -0
- package/dist/inputs/SgCameraCapture.meta.js +63 -0
- package/dist/inputs/SgDatatable.d.ts +9 -1
- package/dist/inputs/SgDatatable.d.ts.map +1 -1
- package/dist/inputs/SgDatatable.js +62 -6
- package/dist/inputs/SgDatatable.meta.d.ts.map +1 -1
- package/dist/inputs/SgDatatable.meta.js +5 -3
- package/dist/inputs/SgFileUpload.d.ts +69 -0
- package/dist/inputs/SgFileUpload.d.ts.map +1 -0
- package/dist/inputs/SgFileUpload.js +234 -0
- package/dist/inputs/SgFileUpload.meta.d.ts +4 -0
- package/dist/inputs/SgFileUpload.meta.d.ts.map +1 -0
- package/dist/inputs/SgFileUpload.meta.js +71 -0
- package/dist/inputs/SgImageUpload.d.ts +20 -0
- package/dist/inputs/SgImageUpload.d.ts.map +1 -0
- package/dist/inputs/SgImageUpload.js +74 -0
- package/dist/inputs/SgImageUpload.meta.d.ts +4 -0
- package/dist/inputs/SgImageUpload.meta.d.ts.map +1 -0
- package/dist/inputs/SgImageUpload.meta.js +73 -0
- package/dist/inputs/SgInputDateTime.d.ts +29 -0
- package/dist/inputs/SgInputDateTime.d.ts.map +1 -0
- package/dist/inputs/SgInputDateTime.js +130 -0
- package/dist/inputs/SgInputDateTime.meta.d.ts +4 -0
- package/dist/inputs/SgInputDateTime.meta.d.ts.map +1 -0
- package/dist/inputs/SgInputDateTime.meta.js +73 -0
- package/dist/inputs/cameraLogic.d.ts +27 -0
- package/dist/inputs/cameraLogic.d.ts.map +1 -0
- package/dist/inputs/cameraLogic.js +57 -0
- package/dist/inputs/dateTimeLogic.d.ts +22 -0
- package/dist/inputs/dateTimeLogic.d.ts.map +1 -0
- package/dist/inputs/dateTimeLogic.js +140 -0
- package/dist/inputs/fileUploadLogic.d.ts +62 -0
- package/dist/inputs/fileUploadLogic.d.ts.map +1 -0
- package/dist/inputs/fileUploadLogic.js +254 -0
- package/dist/inputs/imageUploadLogic.d.ts +31 -0
- package/dist/inputs/imageUploadLogic.d.ts.map +1 -0
- package/dist/inputs/imageUploadLogic.js +70 -0
- package/dist/menus/SgDockMenu.d.ts.map +1 -1
- package/dist/menus/SgDockMenu.js +2 -0
- package/dist/sandbox.cjs +64 -53
- package/dist/style.css +1 -1
- package/package.json +3 -3
|
@@ -0,0 +1,234 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
|
+
import React from "react";
|
|
4
|
+
import { Controller } from "react-hook-form";
|
|
5
|
+
import { File as FileIcon, FileArchive, FileAudio, FileImage, FileSpreadsheet, FileText, FileVideo, Presentation, Upload, X } from "lucide-react";
|
|
6
|
+
import { resolveFieldError } from "../rhf";
|
|
7
|
+
import { t, useComponentsI18n } from "../i18n";
|
|
8
|
+
import { MEDIA_TYPES, formatFileSize, matchesMedia, parseSize, planAdd, resolveMime } from "./fileUploadLogic";
|
|
9
|
+
const HEAD_BYTES = 256;
|
|
10
|
+
function isNative(file) {
|
|
11
|
+
return typeof File !== "undefined" && file instanceof File;
|
|
12
|
+
}
|
|
13
|
+
function sizeOf(file) {
|
|
14
|
+
return isNative(file) ? file.size : file.size ?? 0;
|
|
15
|
+
}
|
|
16
|
+
function typeOf(file) {
|
|
17
|
+
return file.type ?? "";
|
|
18
|
+
}
|
|
19
|
+
async function readHead(file) {
|
|
20
|
+
try {
|
|
21
|
+
const slice = file.slice(0, HEAD_BYTES);
|
|
22
|
+
if (typeof slice.arrayBuffer === "function")
|
|
23
|
+
return new Uint8Array(await slice.arrayBuffer());
|
|
24
|
+
// Ambientes sem Blob.arrayBuffer (testes em jsdom, navegadores antigos).
|
|
25
|
+
return await new Promise((resolve) => {
|
|
26
|
+
const reader = new FileReader();
|
|
27
|
+
reader.onload = () => resolve(new Uint8Array(reader.result));
|
|
28
|
+
reader.onerror = () => resolve(new Uint8Array(0));
|
|
29
|
+
reader.readAsArrayBuffer(slice);
|
|
30
|
+
});
|
|
31
|
+
}
|
|
32
|
+
catch {
|
|
33
|
+
return new Uint8Array(0);
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
/** Atributo `accept` do seletor: grupos viram `image/*`, formatos viram MIME + extensoes; `all` libera tudo. */
|
|
37
|
+
export function pickerAcceptFor(mediaType, accept) {
|
|
38
|
+
const tokens = new Set();
|
|
39
|
+
for (const m of mediaType ?? []) {
|
|
40
|
+
if (m === "all")
|
|
41
|
+
return undefined;
|
|
42
|
+
const info = MEDIA_TYPES[m];
|
|
43
|
+
if (!info)
|
|
44
|
+
continue;
|
|
45
|
+
if (info.group)
|
|
46
|
+
tokens.add(`${info.group}*`);
|
|
47
|
+
if (info.mime)
|
|
48
|
+
tokens.add(info.mime);
|
|
49
|
+
for (const ext of info.extensions)
|
|
50
|
+
tokens.add(`.${ext}`);
|
|
51
|
+
}
|
|
52
|
+
for (const token of (accept ?? "").split(",")) {
|
|
53
|
+
const trimmed = token.trim();
|
|
54
|
+
if (trimmed)
|
|
55
|
+
tokens.add(trimmed);
|
|
56
|
+
}
|
|
57
|
+
return tokens.size === 0 ? undefined : Array.from(tokens).join(",");
|
|
58
|
+
}
|
|
59
|
+
function iconFor(mime) {
|
|
60
|
+
const cls = "size-5 shrink-0";
|
|
61
|
+
if (mime.startsWith("image/"))
|
|
62
|
+
return _jsx(FileImage, { className: cls, "aria-hidden": "true" });
|
|
63
|
+
if (mime.startsWith("video/"))
|
|
64
|
+
return _jsx(FileVideo, { className: cls, "aria-hidden": "true" });
|
|
65
|
+
if (mime.startsWith("audio/"))
|
|
66
|
+
return _jsx(FileAudio, { className: cls, "aria-hidden": "true" });
|
|
67
|
+
if (mime === "application/pdf")
|
|
68
|
+
return _jsx(FileText, { className: cls, "aria-hidden": "true" });
|
|
69
|
+
if (mime.includes("spreadsheet") || mime === "application/vnd.ms-excel" || mime === "text/csv") {
|
|
70
|
+
return _jsx(FileSpreadsheet, { className: cls, "aria-hidden": "true" });
|
|
71
|
+
}
|
|
72
|
+
if (mime.includes("presentation") || mime === "application/vnd.ms-powerpoint") {
|
|
73
|
+
return _jsx(Presentation, { className: cls, "aria-hidden": "true" });
|
|
74
|
+
}
|
|
75
|
+
if (mime.includes("zip"))
|
|
76
|
+
return _jsx(FileArchive, { className: cls, "aria-hidden": "true" });
|
|
77
|
+
if (mime.startsWith("text/") || mime.includes("word") || mime === "application/msword") {
|
|
78
|
+
return _jsx(FileText, { className: cls, "aria-hidden": "true" });
|
|
79
|
+
}
|
|
80
|
+
return _jsx(FileIcon, { className: cls, "aria-hidden": "true" });
|
|
81
|
+
}
|
|
82
|
+
function SgFileUploadBase(props) {
|
|
83
|
+
const i18n = useComponentsI18n();
|
|
84
|
+
const { id, label, labelText, value, defaultValue, onChange, onError, mediaType, accept, maxFiles, maxSizePerFile, maxSizeTotal, hintText, required, disabled, readOnly, className, onEnter, onExit, extraCheck, thumbnailBuilder, thumbnailSize = 96, dropTextKey, dropManyTextKey, typeNames, pickerAccept, keyPrefix = "sg-file", error } = props;
|
|
85
|
+
const max = Math.max(1, Math.floor(maxFiles ?? 1));
|
|
86
|
+
const multi = max > 1;
|
|
87
|
+
const controlled = value !== undefined;
|
|
88
|
+
const [inner, setInner] = React.useState(defaultValue ?? []);
|
|
89
|
+
const current = controlled ? value ?? [] : inner;
|
|
90
|
+
const currentRef = React.useRef(current);
|
|
91
|
+
currentRef.current = current;
|
|
92
|
+
const [internalError, setInternalError] = React.useState(null);
|
|
93
|
+
const [loading, setLoading] = React.useState(false);
|
|
94
|
+
const [dragging, setDragging] = React.useState(false);
|
|
95
|
+
const inputRef = React.useRef(null);
|
|
96
|
+
const locked = Boolean(disabled || readOnly);
|
|
97
|
+
const text = label ?? labelText ?? "";
|
|
98
|
+
const typesText = () => {
|
|
99
|
+
if (typeNames)
|
|
100
|
+
return typeNames;
|
|
101
|
+
const names = [...(mediaType ?? []), ...((accept ?? "").trim() ? [(accept ?? "").trim()] : [])];
|
|
102
|
+
return names.length === 0 ? "all" : names.join(", ");
|
|
103
|
+
};
|
|
104
|
+
const messageFor = (code) => {
|
|
105
|
+
switch (code) {
|
|
106
|
+
case "type":
|
|
107
|
+
return t(i18n, "components.inputs.fileupload.type", { types: typesText() });
|
|
108
|
+
case "size":
|
|
109
|
+
return t(i18n, "components.inputs.fileupload.size", { max: formatFileSize(parseSize(maxSizePerFile) ?? 0, i18n.locale) });
|
|
110
|
+
case "total":
|
|
111
|
+
return t(i18n, "components.inputs.fileupload.total", { max: formatFileSize(parseSize(maxSizeTotal) ?? 0, i18n.locale) });
|
|
112
|
+
case "count":
|
|
113
|
+
return t(i18n, "components.inputs.fileupload.count", { max: String(max) });
|
|
114
|
+
default:
|
|
115
|
+
return ""; // dimension e aspect so chegam por extraCheck, que traz a propria mensagem.
|
|
116
|
+
}
|
|
117
|
+
};
|
|
118
|
+
const commit = (files, errorText = null) => {
|
|
119
|
+
setInternalError(errorText);
|
|
120
|
+
if (!controlled)
|
|
121
|
+
setInner(files);
|
|
122
|
+
onChange?.(files);
|
|
123
|
+
};
|
|
124
|
+
const addFiles = async (picked) => {
|
|
125
|
+
const rejected = [];
|
|
126
|
+
const survivors = [];
|
|
127
|
+
if (extraCheck)
|
|
128
|
+
setLoading(true);
|
|
129
|
+
for (const file of picked) {
|
|
130
|
+
const head = await readHead(file);
|
|
131
|
+
const mime = resolveMime(file.name, file.type, head);
|
|
132
|
+
if (matchesMedia(file.name, mime, mediaType, accept) && extraCheck) {
|
|
133
|
+
const rejection = await extraCheck(file, { mime });
|
|
134
|
+
if (rejection) {
|
|
135
|
+
rejected.push({ file, code: rejection.code, message: rejection.message });
|
|
136
|
+
continue;
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
survivors.push({ file, head });
|
|
140
|
+
}
|
|
141
|
+
if (extraCheck)
|
|
142
|
+
setLoading(false);
|
|
143
|
+
const existing = currentRef.current;
|
|
144
|
+
const plan = planAdd(existing.map(sizeOf), survivors.map(({ file, head }) => ({ name: file.name, type: file.type, size: file.size, head })), { mediaType, accept, maxFiles: max, maxSizePerFile, maxSizeTotal });
|
|
145
|
+
for (const r of plan.rejected) {
|
|
146
|
+
const survivor = survivors[r.index];
|
|
147
|
+
if (survivor)
|
|
148
|
+
rejected.push({ file: survivor.file, code: r.code, message: messageFor(r.code) });
|
|
149
|
+
}
|
|
150
|
+
const lines = rejected.map((r) => t(i18n, "components.inputs.fileupload.file", { name: r.file.name, message: r.message }));
|
|
151
|
+
const errorText = lines.length === 0 ? null : lines.join("\n");
|
|
152
|
+
for (const r of rejected)
|
|
153
|
+
onError?.(r.code, r.message, r.file.name);
|
|
154
|
+
if (plan.accepted.length === 0) {
|
|
155
|
+
setInternalError(errorText);
|
|
156
|
+
return;
|
|
157
|
+
}
|
|
158
|
+
const added = plan.accepted.map((index) => survivors[index]?.file).filter((f) => Boolean(f));
|
|
159
|
+
commit(plan.replace ? added : [...existing, ...added], errorText);
|
|
160
|
+
};
|
|
161
|
+
const onPick = (event) => {
|
|
162
|
+
const files = Array.from(event.currentTarget.files ?? []);
|
|
163
|
+
event.currentTarget.value = ""; // permite escolher o mesmo arquivo de novo
|
|
164
|
+
if (files.length > 0)
|
|
165
|
+
void addFiles(files);
|
|
166
|
+
};
|
|
167
|
+
const onDrop = (event) => {
|
|
168
|
+
event.preventDefault();
|
|
169
|
+
setDragging(false);
|
|
170
|
+
if (locked)
|
|
171
|
+
return;
|
|
172
|
+
const files = Array.from(event.dataTransfer.files ?? []);
|
|
173
|
+
if (files.length > 0)
|
|
174
|
+
void addFiles(multi ? files : files.slice(0, 1));
|
|
175
|
+
};
|
|
176
|
+
const open = () => {
|
|
177
|
+
if (locked || loading)
|
|
178
|
+
return;
|
|
179
|
+
onEnter?.();
|
|
180
|
+
inputRef.current?.click();
|
|
181
|
+
};
|
|
182
|
+
const remove = (index) => {
|
|
183
|
+
commit(current.filter((_, i) => i !== index));
|
|
184
|
+
};
|
|
185
|
+
const shownError = resolveFieldError(error, internalError ?? undefined);
|
|
186
|
+
const hasError = Boolean(shownError);
|
|
187
|
+
const full = current.length >= max;
|
|
188
|
+
// Um arquivo so: a area some quando ha arquivo (tocar em "Trocar" escolhe outro). Varios: itens + area enquanto couber.
|
|
189
|
+
const showZone = multi ? !full : current.length === 0;
|
|
190
|
+
const dropText = multi
|
|
191
|
+
? t(i18n, dropManyTextKey ?? "components.inputs.fileupload.dropMany", { max: String(max) })
|
|
192
|
+
: t(i18n, dropTextKey ?? "components.inputs.fileupload.drop");
|
|
193
|
+
const removeLabel = t(i18n, "components.inputs.fileupload.remove");
|
|
194
|
+
const acceptAttr = pickerAccept ?? pickerAcceptFor(mediaType, accept);
|
|
195
|
+
const renderItem = (file, index) => {
|
|
196
|
+
const sizeText = formatFileSize(sizeOf(file), i18n.locale);
|
|
197
|
+
const removeButton = locked ? null : (_jsx("button", { type: "button", onClick: () => remove(index), "aria-label": removeLabel, "data-sg": `${keyPrefix}-remove-${id}-${index}`, className: "inline-flex size-6 shrink-0 items-center justify-center rounded-full hover:bg-muted/60", children: _jsx(X, { className: "size-4", "aria-hidden": "true" }) }));
|
|
198
|
+
if (thumbnailBuilder) {
|
|
199
|
+
return (_jsxs("div", { "data-sg": `${keyPrefix}-item-${id}-${index}`, style: { width: thumbnailSize }, children: [_jsxs("div", { className: "relative overflow-hidden rounded-md", style: { width: thumbnailSize, height: thumbnailSize }, children: [thumbnailBuilder(file, thumbnailSize), removeButton ? _jsx("span", { className: "absolute right-0 top-0 rounded-full bg-background/85", children: removeButton }) : null] }), _jsx("div", { className: "mt-1 truncate text-xs", children: file.name }), _jsx("div", { className: "text-[10px] text-muted-foreground", children: sizeText })] }, `${file.name}-${index}`));
|
|
200
|
+
}
|
|
201
|
+
const mime = resolveMime(file.name, typeOf(file), new Uint8Array(0));
|
|
202
|
+
return (_jsxs("div", { "data-sg": `${keyPrefix}-item-${id}-${index}`, className: "flex items-center gap-2 rounded-md border border-border px-2 py-1", children: [iconFor(mime), _jsxs("div", { className: "min-w-0 flex-1", children: [_jsx("div", { className: "truncate text-sm", children: file.name }), _jsx("div", { className: "text-[10px] text-muted-foreground", children: sizeText })] }), removeButton] }, `${file.name}-${index}`));
|
|
203
|
+
};
|
|
204
|
+
return (_jsxs("div", { className: ["w-full", className].filter(Boolean).join(" "), children: [text ? (_jsxs("label", { htmlFor: id, className: "mb-1 block text-xs font-medium text-foreground/70", children: [text, required ? _jsx("span", { "aria-hidden": "true", children: " *" }) : null] })) : null, _jsx("input", { ref: inputRef, id: id, type: "file", multiple: multi, accept: acceptAttr, className: "sr-only", disabled: locked, required: required && current.length === 0, "aria-invalid": hasError || undefined, "aria-describedby": hasError ? `${id}-error` : hintText ? `${id}-hint` : undefined, onChange: onPick, onFocus: () => onEnter?.(), onBlur: () => onExit?.() }), current.length > 0 ? (_jsx("div", { className: ["mb-2", thumbnailBuilder ? "flex flex-wrap gap-2" : "flex flex-col gap-1.5"].join(" "), "data-sg": `${keyPrefix}-list-${id}`, children: current.map(renderItem) })) : null, showZone || loading ? (_jsx("div", { role: "button", tabIndex: locked ? -1 : 0, "aria-disabled": locked || undefined, "aria-label": text || dropText, "data-sg": `${keyPrefix}-open-${id}`, "data-dragging": dragging || undefined, onClick: open, onKeyDown: (event) => {
|
|
205
|
+
if (event.key === "Enter" || event.key === " ") {
|
|
206
|
+
event.preventDefault();
|
|
207
|
+
open();
|
|
208
|
+
}
|
|
209
|
+
}, onDragOver: (event) => {
|
|
210
|
+
event.preventDefault();
|
|
211
|
+
if (!locked)
|
|
212
|
+
setDragging(true);
|
|
213
|
+
}, onDragLeave: () => setDragging(false), onDrop: onDrop, className: [
|
|
214
|
+
"relative flex min-h-24 w-full items-center justify-center overflow-hidden rounded-md border border-dashed bg-[var(--sg-input-bg,hsl(var(--background)))] text-sm shadow-sm outline-none transition-colors",
|
|
215
|
+
hasError ? "border-[hsl(var(--destructive))]" : dragging ? "border-[hsl(var(--primary))] bg-muted/40" : "border-border",
|
|
216
|
+
locked ? "cursor-not-allowed opacity-60" : "cursor-pointer focus-visible:ring-2 focus-visible:ring-[hsl(var(--primary)/0.4)]"
|
|
217
|
+
].join(" "), children: loading ? (_jsx("span", { className: "text-muted-foreground", children: t(i18n, "components.inputs.fileupload.loading") })) : (_jsxs("span", { className: "flex flex-col items-center gap-2 px-4 py-4 text-center text-muted-foreground", children: [_jsx(Upload, { className: "size-6", "aria-hidden": "true" }), dropText] })) })) : null, !multi && current.length > 0 && !locked && !loading ? (_jsx("button", { type: "button", onClick: open, "data-sg": `${keyPrefix}-change-${id}`, className: "mt-1 inline-flex items-center gap-1 rounded px-2 py-1 text-xs text-primary hover:bg-muted/40", children: t(i18n, "components.inputs.imageupload.change") })) : null, hasError ? (_jsx("p", { id: `${id}-error`, role: "alert", className: "mt-1 whitespace-pre-line text-xs text-[hsl(var(--destructive))]", children: shownError })) : hintText ? (_jsx("p", { id: `${id}-hint`, className: "mt-1 text-xs text-muted-foreground", children: hintText })) : null] }));
|
|
218
|
+
}
|
|
219
|
+
export function SgFileUpload(props) {
|
|
220
|
+
const { control, name, rules, required, requiredMessage, onChange, error } = props;
|
|
221
|
+
const i18n = useComponentsI18n();
|
|
222
|
+
if (control && name) {
|
|
223
|
+
const resolvedRules = {
|
|
224
|
+
...(required ? { required: requiredMessage ?? t(i18n, "components.inputs.required") } : {}),
|
|
225
|
+
...rules
|
|
226
|
+
};
|
|
227
|
+
return (_jsx(Controller, { name: name, control: control, rules: resolvedRules, render: ({ field, fieldState }) => (_jsx(SgFileUploadBase, { ...props, control: undefined, value: Array.isArray(field.value) ? field.value : [], onChange: (files) => {
|
|
228
|
+
// Lista vazia vira null no formulario, para o "obrigatorio" acusar o campo sem arquivo.
|
|
229
|
+
field.onChange(files.length === 0 ? null : files);
|
|
230
|
+
onChange?.(files);
|
|
231
|
+
}, error: resolveFieldError(error, fieldState.error?.message) })) }));
|
|
232
|
+
}
|
|
233
|
+
return _jsx(SgFileUploadBase, { ...props });
|
|
234
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SgFileUpload.meta.d.ts","sourceRoot":"","sources":["../../src/inputs/SgFileUpload.meta.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAE9D,eAAO,MAAM,MAAM,EAAE,QAmDpB,CAAC;AAEF,eAAO,MAAM,OAAO,EAAE,WAmBrB,CAAC"}
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
export const sgMeta = {
|
|
2
|
+
version: "0.1",
|
|
3
|
+
componentId: "form.input.file-upload",
|
|
4
|
+
package: "@seedgrid/fe-components",
|
|
5
|
+
exportName: "SgFileUpload",
|
|
6
|
+
slug: "sg-file-upload",
|
|
7
|
+
displayName: "SgFileUpload",
|
|
8
|
+
category: "input",
|
|
9
|
+
subcategory: "file",
|
|
10
|
+
description: "Seleciona um ou varios arquivos (clique ou arrastar e soltar), confere o tipo pelo conteudo e valida quantidade e tamanho (por arquivo e total). Mostra a lista com o icone do tipo e permite remover. Nao envia nada ao servidor: entrega os arquivos ao pai.",
|
|
11
|
+
tags: ["form", "file", "upload", "attachment", "document", "pdf", "spreadsheet", "rhf"],
|
|
12
|
+
capabilities: ["rhf", "controlled", "drag-and-drop", "multiple", "validation"],
|
|
13
|
+
fieldSemantics: ["file", "attachment", "document", "upload", "pdf", "spreadsheet"],
|
|
14
|
+
props: [
|
|
15
|
+
{ name: "id", type: "string", required: true, description: "Identificador unico do campo.", semanticRole: "data", bindable: false },
|
|
16
|
+
{ name: "name", type: "string", description: "Nome do campo para formularios.", semanticRole: "data", bindable: true },
|
|
17
|
+
{ name: "label", type: "string", description: "Rotulo exibido acima da area.", semanticRole: "label", bindable: true },
|
|
18
|
+
{ name: "value", type: "SgFileValue[] | null", description: "Arquivos controlados (sempre lista; um arquivo = lista de um). Um arquivo ja salvo entra como { name, url }.", semanticRole: "data", bindable: true },
|
|
19
|
+
{ name: "mediaType", type: "MediaType[]", description: "Tipos aceitos: image, video, audio, pdf, doc, docx, xls, xlsx, ppt, pptx, csv, txt, zip ou all. O tipo e conferido pelo conteudo do arquivo.", semanticRole: "validation", bindable: true },
|
|
20
|
+
{ name: "accept", type: "string", description: "Tipos extras em texto livre (.pdf, image/png, image/*), separados por virgula; soma-se ao mediaType.", semanticRole: "validation", bindable: true },
|
|
21
|
+
{ name: "maxFiles", type: "number", default: 1, description: "Quantos arquivos o campo guarda. Com 1, escolher outro substitui; maior que 1 liga a selecao multipla.", semanticRole: "validation", bindable: true },
|
|
22
|
+
{ name: "maxSizePerFile", type: "SizeLimit", description: "Tamanho maximo de cada arquivo: bytes (numero) ou texto com unidade (\"500KB\", \"1.5MB\", \"1GB\").", semanticRole: "validation", bindable: true },
|
|
23
|
+
{ name: "maxSizeTotal", type: "SizeLimit", description: "Tamanho maximo da soma dos arquivos: bytes (numero) ou texto com unidade.", semanticRole: "validation", bindable: true },
|
|
24
|
+
{ name: "disabled", type: "boolean", default: false, description: "Desabilita a escolha e a remocao.", semanticRole: "appearance", bindable: true },
|
|
25
|
+
{ name: "onChange", type: "(files: SgFileValue[]) => void", description: "Lista de arquivos validos apos escolher ou remover.", semanticRole: "event", bindable: false },
|
|
26
|
+
{ name: "onError", type: "(code: FileErrorCode, message: string, fileName: string) => void", description: "Arquivo recusado (type, size, total, count). Os demais seguem validos.", semanticRole: "event", bindable: false }
|
|
27
|
+
],
|
|
28
|
+
states: ["default", "focused", "loading", "disabled", "readOnly", "error"],
|
|
29
|
+
examples: [
|
|
30
|
+
{
|
|
31
|
+
id: "basic",
|
|
32
|
+
title: "Basico",
|
|
33
|
+
file: "apps/showcase/src/app/components/sg-file-upload/samples/basico.tsx.sample",
|
|
34
|
+
kind: "sample"
|
|
35
|
+
},
|
|
36
|
+
{
|
|
37
|
+
id: "many",
|
|
38
|
+
title: "Varios arquivos",
|
|
39
|
+
file: "apps/showcase/src/app/components/sg-file-upload/samples/varios.tsx.sample",
|
|
40
|
+
kind: "sample"
|
|
41
|
+
},
|
|
42
|
+
{
|
|
43
|
+
id: "playground",
|
|
44
|
+
title: "Playground",
|
|
45
|
+
file: "apps/showcase/src/app/components/sg-file-upload/sg-file-upload.tsx.playground",
|
|
46
|
+
kind: "playground"
|
|
47
|
+
}
|
|
48
|
+
],
|
|
49
|
+
showcase: { route: "/components/sg-file-upload", hasPlayground: true, hasPropsTable: true },
|
|
50
|
+
sdui: { rendererType: "field.file", acceptsDataBinding: true, defaultProps: {} }
|
|
51
|
+
};
|
|
52
|
+
export const aiHints = {
|
|
53
|
+
version: "0.1",
|
|
54
|
+
preferredUseCases: [
|
|
55
|
+
"Anexar um ou varios documentos (PDF, planilhas, apresentacoes, zip) a um cadastro ou solicitacao.",
|
|
56
|
+
"Escolher arquivos validando tipo (pelo conteudo), quantidade e tamanho antes de enviar.",
|
|
57
|
+
"Formularios que precisam de arquivos como campo."
|
|
58
|
+
],
|
|
59
|
+
avoidUseCases: [
|
|
60
|
+
"Fotos e imagens com miniatura, dimensao minima ou proporcao; para isso use SgImageUpload.",
|
|
61
|
+
"Capturar pela camera do dispositivo; para isso use SgCameraCapture.",
|
|
62
|
+
"Envio ao servidor ou progresso de upload; nao fazem parte do componente."
|
|
63
|
+
],
|
|
64
|
+
synonyms: ["file upload", "attachment", "anexar arquivo", "upload de arquivo", "documento", "file picker"],
|
|
65
|
+
relatedEntityFields: ["attachment", "document", "file", "contract", "invoice", "receipt"],
|
|
66
|
+
compositionHints: [
|
|
67
|
+
"Envie os arquivos recebidos em onChange pelo servico de arquivos do host; o componente nunca envia sozinho.",
|
|
68
|
+
"Para imagens com miniatura e regras de dimensao, use SgImageUpload (composicao deste componente)."
|
|
69
|
+
],
|
|
70
|
+
rankingSignals: { freeText: 0, structuredChoice: 0.1, date: 0, number: 0, denseLayout: 0.4 }
|
|
71
|
+
};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { type SgFileUploadProps } from "./SgFileUpload";
|
|
2
|
+
/**
|
|
3
|
+
* SgImageUpload (P133, refeito no P141 como COMPOSICAO do SgFileUpload): so imagens (`mediaType: ["image"]`, tipo
|
|
4
|
+
* conferido pelo conteudo), miniaturas no lugar do icone e as regras que so existem para imagem: largura/altura
|
|
5
|
+
* minimas e proporcao. Valor = lista (uma imagem = lista de uma); `maxFiles` maior que 1 mostra a grade.
|
|
6
|
+
*/
|
|
7
|
+
export type SgImageUploadProps = Omit<SgFileUploadProps, "mediaType" | "extraCheck" | "thumbnailBuilder" | "thumbnailSize" | "dropTextKey" | "dropManyTextKey" | "typeNames" | "pickerAccept" | "keyPrefix"> & {
|
|
8
|
+
/** Restringe os formatos de imagem em texto livre (`.png`, `image/jpeg`), separados por virgula. */
|
|
9
|
+
accept?: string;
|
|
10
|
+
/** Largura minima em px. */
|
|
11
|
+
minWidth?: number;
|
|
12
|
+
/** Altura minima em px. */
|
|
13
|
+
minHeight?: number;
|
|
14
|
+
/** Proporcao largura/altura exigida (1 = quadrada, 16 / 9). */
|
|
15
|
+
aspect?: number;
|
|
16
|
+
/** Altura da miniatura em px (padrao 160; na grade, no maximo 120). */
|
|
17
|
+
previewHeight?: number;
|
|
18
|
+
};
|
|
19
|
+
export declare function SgImageUpload(props: SgImageUploadProps): import("react/jsx-runtime").JSX.Element;
|
|
20
|
+
//# sourceMappingURL=SgImageUpload.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SgImageUpload.d.ts","sourceRoot":"","sources":["../../src/inputs/SgImageUpload.tsx"],"names":[],"mappings":"AAOA,OAAO,EAAsC,KAAK,iBAAiB,EAAoB,MAAM,gBAAgB,CAAC;AAE9G;;;;GAIG;AACH,MAAM,MAAM,kBAAkB,GAAG,IAAI,CACnC,iBAAiB,EACjB,WAAW,GAAG,YAAY,GAAG,kBAAkB,GAAG,eAAe,GAAG,aAAa,GAAG,iBAAiB,GAAG,WAAW,GAAG,cAAc,GAAG,WAAW,CACnJ,GAAG;IACF,oGAAoG;IACpG,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,4BAA4B;IAC5B,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,2BAA2B;IAC3B,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,+DAA+D;IAC/D,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,uEAAuE;IACvE,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB,CAAC;AAqDF,wBAAgB,aAAa,CAAC,KAAK,EAAE,kBAAkB,2CAgDtD"}
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
3
|
+
import React from "react";
|
|
4
|
+
import { ImageOff } from "lucide-react";
|
|
5
|
+
import { t, useComponentsI18n } from "../i18n";
|
|
6
|
+
import { formatAspect, validateImage } from "./imageUploadLogic";
|
|
7
|
+
import { matchesMedia } from "./fileUploadLogic";
|
|
8
|
+
import { SgFileUpload } from "./SgFileUpload";
|
|
9
|
+
function readDimensions(file) {
|
|
10
|
+
return new Promise((resolve) => {
|
|
11
|
+
const url = URL.createObjectURL(file);
|
|
12
|
+
const img = new Image();
|
|
13
|
+
img.onload = () => {
|
|
14
|
+
URL.revokeObjectURL(url);
|
|
15
|
+
resolve({ width: img.naturalWidth, height: img.naturalHeight });
|
|
16
|
+
};
|
|
17
|
+
img.onerror = () => {
|
|
18
|
+
URL.revokeObjectURL(url);
|
|
19
|
+
resolve(null);
|
|
20
|
+
};
|
|
21
|
+
img.src = url;
|
|
22
|
+
});
|
|
23
|
+
}
|
|
24
|
+
function Thumbnail(props) {
|
|
25
|
+
const { file, id, side } = props;
|
|
26
|
+
const [url, setUrl] = React.useState(null);
|
|
27
|
+
const [broken, setBroken] = React.useState(false);
|
|
28
|
+
React.useEffect(() => {
|
|
29
|
+
setBroken(false);
|
|
30
|
+
if (typeof File !== "undefined" && file instanceof File) {
|
|
31
|
+
const objectUrl = URL.createObjectURL(file);
|
|
32
|
+
setUrl(objectUrl);
|
|
33
|
+
return () => URL.revokeObjectURL(objectUrl);
|
|
34
|
+
}
|
|
35
|
+
setUrl("url" in file && file.url ? file.url : null);
|
|
36
|
+
return undefined;
|
|
37
|
+
}, [file]);
|
|
38
|
+
if (!url || broken) {
|
|
39
|
+
return (_jsx("span", { className: "flex size-full items-center justify-center bg-muted/40 text-muted-foreground", children: _jsx(ImageOff, { className: "size-5", "aria-hidden": "true" }) }));
|
|
40
|
+
}
|
|
41
|
+
return (
|
|
42
|
+
// eslint-disable-next-line @next/next/no-img-element
|
|
43
|
+
_jsx("img", { src: url, alt: file.name, "data-sg": `sg-image-preview-${id}-${file.name}`, width: side, height: side, onError: () => setBroken(true), className: "size-full object-cover" }));
|
|
44
|
+
}
|
|
45
|
+
export function SgImageUpload(props) {
|
|
46
|
+
const i18n = useComponentsI18n();
|
|
47
|
+
const { accept, minWidth, minHeight, aspect, previewHeight = 160, maxFiles, id, ...rest } = props;
|
|
48
|
+
const multi = (maxFiles ?? 1) > 1;
|
|
49
|
+
const side = multi && previewHeight > 120 ? 120 : previewHeight;
|
|
50
|
+
const check = async (file, info) => {
|
|
51
|
+
if ((accept ?? "").trim() && !matchesMedia(file.name, info.mime, undefined, accept)) {
|
|
52
|
+
return { code: "type", message: t(i18n, "components.inputs.fileupload.type", { types: (accept ?? "").trim() }) };
|
|
53
|
+
}
|
|
54
|
+
const needsDimensions = minWidth !== undefined || minHeight !== undefined || aspect !== undefined;
|
|
55
|
+
if (!needsDimensions)
|
|
56
|
+
return null;
|
|
57
|
+
const dims = await readDimensions(file);
|
|
58
|
+
const code = validateImage({ name: "", type: "", size: file.size, width: dims?.width, height: dims?.height }, { accept: "", minWidth, minHeight, aspect });
|
|
59
|
+
if (code === "dimension") {
|
|
60
|
+
return {
|
|
61
|
+
code,
|
|
62
|
+
message: t(i18n, "components.inputs.imageupload.dimension", {
|
|
63
|
+
minWidth: String(minWidth ?? 0),
|
|
64
|
+
minHeight: String(minHeight ?? 0)
|
|
65
|
+
})
|
|
66
|
+
};
|
|
67
|
+
}
|
|
68
|
+
if (code === "aspect") {
|
|
69
|
+
return { code, message: t(i18n, "components.inputs.imageupload.aspect", { aspect: formatAspect(aspect ?? 1) }) };
|
|
70
|
+
}
|
|
71
|
+
return null;
|
|
72
|
+
};
|
|
73
|
+
return (_jsx(SgFileUpload, { ...rest, id: id, maxFiles: maxFiles, keyPrefix: "sg-image", mediaType: ["image"], typeNames: (accept ?? "").trim() ? (accept ?? "").trim() : "image", dropTextKey: "components.inputs.imageupload.drop", dropManyTextKey: "components.inputs.imageupload.dropMany", pickerAccept: (accept ?? "").trim() ? (accept ?? "").trim() : "image/*", extraCheck: check, thumbnailBuilder: (file, size) => _jsx(Thumbnail, { file: file, id: id, side: size }), thumbnailSize: side }));
|
|
74
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SgImageUpload.meta.d.ts","sourceRoot":"","sources":["../../src/inputs/SgImageUpload.meta.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AAE9D,eAAO,MAAM,MAAM,EAAE,QAqDpB,CAAC;AAEF,eAAO,MAAM,OAAO,EAAE,WAmBrB,CAAC"}
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
export const sgMeta = {
|
|
2
|
+
version: "0.1",
|
|
3
|
+
componentId: "form.input.image-upload",
|
|
4
|
+
package: "@seedgrid/fe-components",
|
|
5
|
+
exportName: "SgImageUpload",
|
|
6
|
+
slug: "sg-image-upload",
|
|
7
|
+
displayName: "SgImageUpload",
|
|
8
|
+
category: "input",
|
|
9
|
+
subcategory: "file",
|
|
10
|
+
description: "Seleciona uma ou varias imagens (clique ou arrastar e soltar), valida tipo (pelo conteudo), tamanho, dimensao minima e proporcao, mostra as miniaturas e permite remover. Composicao do SgFileUpload. Nao envia nada ao servidor: entrega os arquivos ao pai.",
|
|
11
|
+
tags: ["form", "image", "upload", "photo", "avatar", "file", "rhf"],
|
|
12
|
+
capabilities: ["rhf", "controlled", "drag-and-drop", "preview", "validation"],
|
|
13
|
+
fieldSemantics: ["image", "photo", "avatar", "logo", "picture", "attachment"],
|
|
14
|
+
props: [
|
|
15
|
+
{ name: "id", type: "string", required: true, description: "Identificador unico do campo.", semanticRole: "data", bindable: false },
|
|
16
|
+
{ name: "name", type: "string", description: "Nome do campo para formularios.", semanticRole: "data", bindable: true },
|
|
17
|
+
{ name: "label", type: "string", description: "Rotulo exibido acima da area.", semanticRole: "label", bindable: true },
|
|
18
|
+
{ name: "value", type: "SgFileValue[] | null", description: "Imagens controladas (sempre lista; uma imagem = lista de uma). Uma imagem ja salva entra como { name, url }.", semanticRole: "data", bindable: true },
|
|
19
|
+
{ name: "accept", type: "string", description: "Restringe os formatos de imagem em texto livre (.png, image/jpeg), separados por virgula.", semanticRole: "validation", bindable: true },
|
|
20
|
+
{ name: "maxFiles", type: "number", default: 1, description: "Quantas imagens o campo guarda. Com 1, escolher outra substitui; maior que 1 liga a selecao multipla e a grade de miniaturas.", semanticRole: "validation", bindable: true },
|
|
21
|
+
{ name: "maxSizePerFile", type: "SizeLimit", description: "Tamanho maximo de cada imagem: bytes (numero) ou texto com unidade (\"500KB\", \"2MB\").", semanticRole: "validation", bindable: true },
|
|
22
|
+
{ name: "maxSizeTotal", type: "SizeLimit", description: "Tamanho maximo da soma das imagens: bytes (numero) ou texto com unidade.", semanticRole: "validation", bindable: true },
|
|
23
|
+
{ name: "minWidth", type: "number", description: "Largura minima em px.", semanticRole: "validation", bindable: true },
|
|
24
|
+
{ name: "minHeight", type: "number", description: "Altura minima em px.", semanticRole: "validation", bindable: true },
|
|
25
|
+
{ name: "aspect", type: "number", description: "Proporcao largura/altura exigida (1 = quadrada).", semanticRole: "validation", bindable: true },
|
|
26
|
+
{ name: "disabled", type: "boolean", default: false, description: "Desabilita a escolha e a remocao.", semanticRole: "appearance", bindable: true },
|
|
27
|
+
{ name: "onChange", type: "(files: SgFileValue[]) => void", description: "Lista de imagens validas apos escolher ou remover.", semanticRole: "event", bindable: false },
|
|
28
|
+
{ name: "onError", type: "(code: FileErrorCode, message: string, fileName: string) => void", description: "Imagem recusada (type, size, total, count, dimension, aspect). As demais seguem validas.", semanticRole: "event", bindable: false }
|
|
29
|
+
],
|
|
30
|
+
states: ["default", "focused", "loading", "disabled", "readOnly", "error"],
|
|
31
|
+
examples: [
|
|
32
|
+
{
|
|
33
|
+
id: "basic",
|
|
34
|
+
title: "Basico",
|
|
35
|
+
file: "apps/showcase/src/app/components/sg-image-upload/samples/basico.tsx.sample",
|
|
36
|
+
kind: "sample"
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
id: "many",
|
|
40
|
+
title: "Varias imagens",
|
|
41
|
+
file: "apps/showcase/src/app/components/sg-image-upload/samples/varias.tsx.sample",
|
|
42
|
+
kind: "sample"
|
|
43
|
+
},
|
|
44
|
+
{
|
|
45
|
+
id: "playground",
|
|
46
|
+
title: "Playground",
|
|
47
|
+
file: "apps/showcase/src/app/components/sg-image-upload/sg-image-upload.tsx.playground",
|
|
48
|
+
kind: "playground"
|
|
49
|
+
}
|
|
50
|
+
],
|
|
51
|
+
showcase: { route: "/components/sg-image-upload", hasPlayground: true, hasPropsTable: true },
|
|
52
|
+
sdui: { rendererType: "field.image", acceptsDataBinding: true, defaultProps: {} }
|
|
53
|
+
};
|
|
54
|
+
export const aiHints = {
|
|
55
|
+
version: "0.1",
|
|
56
|
+
preferredUseCases: [
|
|
57
|
+
"Foto de perfil, avatar, logotipo ou foto de documento com pre-visualizacao.",
|
|
58
|
+
"Escolher uma ou varias imagens validando tipo, tamanho e dimensao antes de enviar.",
|
|
59
|
+
"Formularios que precisam de imagens como campo."
|
|
60
|
+
],
|
|
61
|
+
avoidUseCases: [
|
|
62
|
+
"Arquivos que nao sao imagem (PDF, planilhas); nesses casos use SgFileUpload.",
|
|
63
|
+
"Capturar pela camera do dispositivo; para isso use SgCameraCapture.",
|
|
64
|
+
"Recorte ou compressao de imagem; nao fazem parte do componente."
|
|
65
|
+
],
|
|
66
|
+
synonyms: ["image upload", "photo upload", "avatar picker", "enviar foto", "upload de imagem", "logo upload"],
|
|
67
|
+
relatedEntityFields: ["photo", "avatar", "logo", "image", "picture", "documentPhoto"],
|
|
68
|
+
compositionHints: [
|
|
69
|
+
"Envie os arquivos recebidos em onChange pelo servico de arquivos do host; o componente nunca envia sozinho.",
|
|
70
|
+
"Combine com SgPanel e SgInputText em cadastros de pessoa ou produto."
|
|
71
|
+
],
|
|
72
|
+
rankingSignals: { freeText: 0, structuredChoice: 0.1, date: 0, number: 0, denseLayout: 0.4 }
|
|
73
|
+
};
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { type SgInputTextProps } from "./SgInputText";
|
|
2
|
+
export type SgInputDateTimeProps = Omit<SgInputTextProps, "type" | "onChange"> & {
|
|
3
|
+
/** Instante controlado: ISO 8601 (com offset ou "Z") ou `Date`. `null`/"" limpa o campo. */
|
|
4
|
+
value?: string | Date | null;
|
|
5
|
+
/** Instante inicial (campo nao controlado). */
|
|
6
|
+
defaultValue?: string | Date | null;
|
|
7
|
+
/**
|
|
8
|
+
* Disparado a cada alteracao com o instante em ISO 8601 UTC (`2026-11-03T17:30:00.000Z`) ou `null` se o
|
|
9
|
+
* campo ficou vazio/incompleto/invalido; `local` e o texto do campo (`2026-11-03T14:30`) no fuso do campo.
|
|
10
|
+
*/
|
|
11
|
+
onChange?: (value: string | null, local: string) => void;
|
|
12
|
+
/** Disparado ao receber foco — padrao seedgrid. */
|
|
13
|
+
onEnter?: () => void;
|
|
14
|
+
/** Disparado ao perder o foco (apos validacao) — padrao seedgrid. */
|
|
15
|
+
onExit?: () => void;
|
|
16
|
+
/** Menor instante permitido (ISO 8601 ou `Date`). */
|
|
17
|
+
minDate?: string | Date;
|
|
18
|
+
/** Maior instante permitido (ISO 8601 ou `Date`). */
|
|
19
|
+
maxDate?: string | Date;
|
|
20
|
+
/** Fuso em que o campo mostra e interpreta a hora: "local" (padrao), "UTC", "+03:00" ou nome IANA. */
|
|
21
|
+
timeZone?: string;
|
|
22
|
+
/** Mostra e aceita segundos. */
|
|
23
|
+
showSeconds?: boolean;
|
|
24
|
+
/** Passo dos minutos (1, 5, 10, 15, 30...). Ignorado com `showSeconds`. */
|
|
25
|
+
minuteStep?: number;
|
|
26
|
+
alwaysFloat?: boolean;
|
|
27
|
+
};
|
|
28
|
+
export declare function SgInputDateTime(props: SgInputDateTimeProps): import("react/jsx-runtime").JSX.Element;
|
|
29
|
+
//# sourceMappingURL=SgInputDateTime.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"SgInputDateTime.d.ts","sourceRoot":"","sources":["../../src/inputs/SgInputDateTime.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAe,KAAK,gBAAgB,EAAE,MAAM,eAAe,CAAC;AAYnE,MAAM,MAAM,oBAAoB,GAAG,IAAI,CAAC,gBAAgB,EAAE,MAAM,GAAG,UAAU,CAAC,GAAG;IAC/E,4FAA4F;IAC5F,KAAK,CAAC,EAAE,MAAM,GAAG,IAAI,GAAG,IAAI,CAAC;IAC7B,+CAA+C;IAC/C,YAAY,CAAC,EAAE,MAAM,GAAG,IAAI,GAAG,IAAI,CAAC;IACpC;;;OAGG;IACH,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,GAAG,IAAI,EAAE,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACzD,mDAAmD;IACnD,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IACrB,qEAAqE;IACrE,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;IACpB,qDAAqD;IACrD,OAAO,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACxB,qDAAqD;IACrD,OAAO,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACxB,sGAAsG;IACtG,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,gCAAgC;IAChC,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,2EAA2E;IAC3E,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,WAAW,CAAC,EAAE,OAAO,CAAC;CACvB,CAAC;AASF,wBAAgB,eAAe,CAAC,KAAK,EAAE,oBAAoB,2CA8J1D"}
|