File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -40,7 +40,7 @@ https://github.com/Nuked88/ComfyUI-N-Sidebar/blob/7ae7da4a9761009fb6629bc04c6830
4040 <div class =" _sb_col" >{{ widgetInput.name }}</div >
4141 <div class =" _sb_col middle-column" ></div >
4242 <div class =" _sb_col _sb_inherit" >
43- {{ widgetInput.default }}
43+ {{ truncateDefaultValue( widgetInput.default) }}
4444 </div >
4545 <div class =" _sb_col _sb_arrow" >▶ ; </div >
4646 </div >
@@ -73,6 +73,12 @@ const slotInputDefs = allInputDefs.filter(
7373const widgetInputDefs = allInputDefs .filter ((input ) =>
7474 nodeDefStore .inputIsWidget (input )
7575)
76+ const truncateDefaultValue = (value : any ): string => {
77+ if (value instanceof Object ) {
78+ return _ .truncate (JSON .stringify (value ), { length: 20 })
79+ }
80+ return value
81+ }
7682 </script >
7783
7884<style scoped>
You can’t perform that action at this time.
0 commit comments