Skip to content

Commit 04b6eda

Browse files
committed
Convert Spi rx protocolos to select2
1 parent b83ccdf commit 04b6eda

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

src/js/tabs/receiver.js

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -331,6 +331,15 @@ TABS.receiver.initialize = function (callback) {
331331

332332
// select current serial RX type
333333
spiRxElement.val(FC.RX_CONFIG.rxSpiProtocol);
334+
335+
// Convert to select2 and order alphabetic
336+
spiRxElement.select2({
337+
sorter(data) {
338+
return data.sort(function(a, b) {
339+
return a.text.localeCompare(b.text);
340+
});
341+
},
342+
});
334343
}
335344

336345

0 commit comments

Comments
 (0)