File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed
Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change 11//trim leading / trailing spaces form input fields
2- export default function trimInput ( ) {
2+ export default function handleAutoTrimInputs ( ) {
33 document . querySelectorAll ( 'input[type="text"]' ) . forEach ( ( input ) => {
44 input . addEventListener ( 'change' , function ( ) {
55 this . value = this . value . trim ( ) ;
Original file line number Diff line number Diff line change 11import alpineInit from './alpineInit' ;
22import focusFirstInput from './focusFirstInput' ;
33import handleAddIpLists from './addIpLists' ;
4+ import handleAutoTrimInputs from './autoTrimInputs' ;
45import handleConfirmAction from './confirmAction' ;
56import handleCopyCreds from './copyCreds' ;
67import handleClipboardCopy from './clipboardCopy' ;
@@ -24,7 +25,6 @@ import handleStickyToolbar from './stickyToolbar';
2425import handleSyncEmailValues from './syncEmailValues' ;
2526import handleTabPanels from './tabPanels' ;
2627import handleToggleAdvanced from './toggleAdvanced' ;
27- import trimInput from './trimInput' ;
2828import handleUnlimitedInput from './unlimitedInput' ;
2929import initRrdCharts from './rrdCharts' ;
3030import initWebTerminal from './webTerminal' ;
@@ -34,6 +34,7 @@ focusFirstInput();
3434
3535function initListeners ( ) {
3636 handleAddIpLists ( ) ;
37+ handleAutoTrimInputs ( ) ;
3738 handleConfirmAction ( ) ;
3839 handleCopyCreds ( ) ;
3940 handleClipboardCopy ( ) ;
@@ -52,7 +53,6 @@ function initListeners() {
5253 handleSyncEmailValues ( ) ;
5354 handleTabPanels ( ) ;
5455 handleToggleAdvanced ( ) ;
55- trimInput ( ) ;
5656 initRrdCharts ( ) ;
5757 initWebTerminal ( ) ;
5858}
You can’t perform that action at this time.
0 commit comments