fix(*): 质量检查与版本发布 - 修复格式门禁和创作灵感兼容导出并发布 v1.6.2
This commit is contained in:
1 parent
04689257d2
commit
9174aae013
86 files changed
+22711
-634
No files matched your search
@@ -18,16 +18,44 @@ export function CanvasSizePicker({ value, className, onChange }: CanvasSizePicke
|
||||
};
|
||||
return (
|
||||
<div className={className} data-canvas-no-zoom onPointerDown={(event) => event.stopPropagation()}>
|
||||
<Select ariaLabel="生成比例" className="canvas-compact-control canvas-control-select h-full w-full" placeholder="比例" showSearch
|
||||
value={value || undefined} options={options} searchValue={query} open={expanded} popupMatchSelectWidth={false}
|
||||
onSearch={(text) => { draft.current = text; setQuery(text); }} onOpenChange={setExpanded}
|
||||
onChange={commit} onBlur={() => { if (draft.current.trim()) commit(draft.current); else setExpanded(false); }}
|
||||
<Select
|
||||
ariaLabel="生成比例"
|
||||
className="canvas-compact-control canvas-control-select h-full w-full"
|
||||
placeholder="比例"
|
||||
showSearch
|
||||
value={value || undefined}
|
||||
options={options}
|
||||
searchValue={query}
|
||||
open={expanded}
|
||||
popupMatchSelectWidth={false}
|
||||
onSearch={(text) => {
|
||||
draft.current = text;
|
||||
setQuery(text);
|
||||
}}
|
||||
onOpenChange={setExpanded}
|
||||
onChange={commit}
|
||||
onBlur={() => {
|
||||
if (draft.current.trim()) commit(draft.current);
|
||||
else setExpanded(false);
|
||||
}}
|
||||
onInputKeyDown={(event) => {
|
||||
if (event.nativeEvent.isComposing) return;
|
||||
if (event.key === "Enter" && draft.current.trim()) { event.preventDefault(); commit(draft.current); }
|
||||
if (event.key === "Escape") { draft.current = ""; setQuery(""); setExpanded(false); }
|
||||
if (event.key === "Enter" && draft.current.trim()) {
|
||||
event.preventDefault();
|
||||
commit(draft.current);
|
||||
}
|
||||
if (event.key === "Escape") {
|
||||
draft.current = "";
|
||||
setQuery("");
|
||||
setExpanded(false);
|
||||
}
|
||||
}}
|
||||
popupRender={(menu) => <div onPointerDown={(event) => event.stopPropagation()} onMouseDown={(event) => event.stopPropagation()}>{menu}</div>} />
|
||||
popupRender={(menu) => (
|
||||
<div onPointerDown={(event) => event.stopPropagation()} onMouseDown={(event) => event.stopPropagation()}>
|
||||
{menu}
|
||||
</div>
|
||||
)}
|
||||
/>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
Reference in new issue
Block a user