(event)
| 828 | let configContainer; |
| 829 | |
| 830 | function openConfig(event) { |
| 831 | event.preventDefault(); |
| 832 | |
| 833 | // Reset on reopen |
| 834 | if (configContainer) { |
| 835 | resetTokenButton(configContainer); |
| 836 | } else { |
| 837 | configContainer = document.createElement("div"); |
| 838 | configContainer.id = "popup-config-container"; |
| 839 | const style = document.createElement("style"); |
| 840 | style.innerHTML = ` |
| 841 | .setting-row { |
| 842 | display: flex; |
| 843 | justify-content: space-between; |
| 844 | align-items: center; |
| 845 | } |
| 846 | .setting-row::after { |
| 847 | content: ""; |
| 848 | display: table; |
| 849 | clear: both; |
| 850 | } |
| 851 | .setting-row .col { |
| 852 | display: flex; |
| 853 | padding: 10px 0; |
| 854 | align-items: center; |
| 855 | } |
| 856 | .setting-row .col.description { |
| 857 | padding-right: 15px; |
| 858 | cursor: default; |
| 859 | width: 50%; |
| 860 | } |
| 861 | .setting-row .col.action { |
| 862 | justify-content: flex-end; |
| 863 | width: 50%; |
| 864 | } |
| 865 | .popup-config-col-margin { |
| 866 | margin-top: 10px; |
| 867 | } |
| 868 | button.switch { |
| 869 | align-items: center; |
| 870 | border: 0px; |
| 871 | border-radius: 50%; |
| 872 | background-color: rgba(var(--spice-rgb-shadow), .7); |
| 873 | color: var(--spice-text); |
| 874 | cursor: pointer; |
| 875 | display: flex; |
| 876 | margin-inline-start: 12px; |
| 877 | padding: 8px; |
| 878 | } |
| 879 | button.switch.disabled, |
| 880 | button.switch[disabled] { |
| 881 | color: rgba(var(--spice-rgb-text), .3); |
| 882 | } |
| 883 | button.switch.small { |
| 884 | width: 22px; |
| 885 | height: 22px; |
| 886 | padding: 6px; |
| 887 | } |
nothing calls this directly
no test coverage detected