Commit a7a8578 pompurin404
committed
1 parent 644390f commit a7a8578 Copy full SHA for a7a8578
File tree 1 file changed +20
-18
lines changed
1 file changed +20
-18
lines changed Original file line number Diff line number Diff line change @@ -65,6 +65,25 @@ const Tun: React.FC = () => {
65
65
}
66
66
>
67
67
< SettingCard >
68
+ { platform === 'win32' && (
69
+ < SettingItem title = "重设防火墙" divider >
70
+ < Button
71
+ size = "sm"
72
+ color = "primary"
73
+ isLoading = { loading }
74
+ onPress = { ( ) => {
75
+ setLoading ( true )
76
+ setupFirewall ( )
77
+ . then ( ( ) => {
78
+ new Notification ( '防火墙重设成功' )
79
+ } )
80
+ . finally ( ( ) => setLoading ( false ) )
81
+ } }
82
+ >
83
+ 重设防火墙
84
+ </ Button >
85
+ </ SettingItem >
86
+ ) }
68
87
< SettingItem title = "Tun 模式堆栈" divider >
69
88
< Tabs
70
89
size = "sm"
@@ -135,7 +154,7 @@ const Tun: React.FC = () => {
135
154
} }
136
155
/>
137
156
</ SettingItem >
138
- < SettingItem title = "DNS 劫持" divider >
157
+ < SettingItem title = "DNS 劫持" >
139
158
< Input
140
159
size = "sm"
141
160
className = "w-[50%]"
@@ -145,23 +164,6 @@ const Tun: React.FC = () => {
145
164
} }
146
165
/>
147
166
</ SettingItem >
148
- < SettingItem title = "重设防火墙" >
149
- < Button
150
- size = "sm"
151
- color = "primary"
152
- isLoading = { loading }
153
- onPress = { ( ) => {
154
- setLoading ( true )
155
- setupFirewall ( )
156
- . then ( ( ) => {
157
- new Notification ( '防火墙重设成功' )
158
- } )
159
- . finally ( ( ) => setLoading ( false ) )
160
- } }
161
- >
162
- 重设防火墙
163
- </ Button >
164
- </ SettingItem >
165
167
</ SettingCard >
166
168
</ BasePage >
167
169
)
You can’t perform that action at this time.
0 commit comments