Actualizar frontend/src/components/UI.jsx

This commit is contained in:
2026-08-27 16:49:29 -05:00
parent 8928c7a227
commit 0f36eed0fb

View File

@@ -35,11 +35,11 @@ export function Filters({ children }) {
return <div className="filters">{children}</div>;
}
export function Select({ label, value, options, onChange }) {
export function Select({ label, value, options, onChange, width }) {
return (
<div className="filter-group">
<div className="filter-group" style={width ? { width } : undefined}>
{label && <label>{label}</label>}
<select value={value} onChange={(e) => onChange(e.target.value)}>
<select value={value} onChange={(e) => onChange(e.target.value)} style={width ? { width: "100%" } : undefined}>
{options.map((o) => {
const val = typeof o === "object" ? o.value : o;
const txt = typeof o === "object" ? o.label : o;