mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
Moving start-up switcher to Other tab
Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
This commit is contained in:
parent
909032a535
commit
f8db743bb6
@ -8,7 +8,6 @@ import { userStore } from "../../../common/user-store";
|
|||||||
import { isWindows } from "../../../common/vars";
|
import { isWindows } from "../../../common/vars";
|
||||||
import { appPreferenceRegistry } from "../../../extensions/registries/app-preference-registry";
|
import { appPreferenceRegistry } from "../../../extensions/registries/app-preference-registry";
|
||||||
import { themeStore } from "../../theme.store";
|
import { themeStore } from "../../theme.store";
|
||||||
import { Checkbox } from "../checkbox";
|
|
||||||
import { Input } from "../input";
|
import { Input } from "../input";
|
||||||
import { PageLayout } from "../layout/page-layout";
|
import { PageLayout } from "../layout/page-layout";
|
||||||
import { SubTitle } from "../layout/sub-title";
|
import { SubTitle } from "../layout/sub-title";
|
||||||
@ -23,7 +22,8 @@ enum PreferencesTab {
|
|||||||
Application = "application",
|
Application = "application",
|
||||||
Proxy = "proxy",
|
Proxy = "proxy",
|
||||||
Kubernetes = "kubernetes",
|
Kubernetes = "kubernetes",
|
||||||
Extensions = "extensions"
|
Extensions = "extensions",
|
||||||
|
Other = "other"
|
||||||
}
|
}
|
||||||
|
|
||||||
@observer
|
@observer
|
||||||
@ -82,6 +82,11 @@ export class Preferences extends React.Component {
|
|||||||
label="Extensions"
|
label="Extensions"
|
||||||
active={this.activeTab == PreferencesTab.Extensions}
|
active={this.activeTab == PreferencesTab.Extensions}
|
||||||
/>
|
/>
|
||||||
|
<Tab
|
||||||
|
value={PreferencesTab.Other}
|
||||||
|
label="Other"
|
||||||
|
active={this.activeTab == PreferencesTab.Other}
|
||||||
|
/>
|
||||||
</Tabs>
|
</Tabs>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@ -107,8 +112,8 @@ export class Preferences extends React.Component {
|
|||||||
>
|
>
|
||||||
{this.activeTab == PreferencesTab.Application && (
|
{this.activeTab == PreferencesTab.Application && (
|
||||||
<section id="application">
|
<section id="application">
|
||||||
|
<h2>Application</h2>
|
||||||
<section id="appearance">
|
<section id="appearance">
|
||||||
<h2>Appearance</h2>
|
|
||||||
<SubTitle title="Theme"/>
|
<SubTitle title="Theme"/>
|
||||||
<Select
|
<Select
|
||||||
options={this.themeOptions}
|
options={this.themeOptions}
|
||||||
@ -117,11 +122,10 @@ export class Preferences extends React.Component {
|
|||||||
/>
|
/>
|
||||||
</section>
|
</section>
|
||||||
|
|
||||||
<hr/>
|
<hr className="small"/>
|
||||||
|
|
||||||
<section id="shell">
|
<section id="shell" className="small">
|
||||||
<h2>Terminal Shell</h2>
|
<SubTitle title="Terminal Shell Path"/>
|
||||||
<SubTitle title="Shell Path"/>
|
|
||||||
<Input
|
<Input
|
||||||
theme="round-black"
|
theme="round-black"
|
||||||
placeholder={defaultShell}
|
placeholder={defaultShell}
|
||||||
@ -133,21 +137,6 @@ export class Preferences extends React.Component {
|
|||||||
The path of the shell that the terminal uses.
|
The path of the shell that the terminal uses.
|
||||||
</div>
|
</div>
|
||||||
</section>
|
</section>
|
||||||
|
|
||||||
<hr/>
|
|
||||||
|
|
||||||
<section id="startup">
|
|
||||||
<FormSwitch
|
|
||||||
control={
|
|
||||||
<Switcher
|
|
||||||
checked={preferences.openAtLogin}
|
|
||||||
onChange={v => preferences.openAtLogin = v.target.checked}
|
|
||||||
name="startup"
|
|
||||||
/>
|
|
||||||
}
|
|
||||||
label="Automatically start Lens on login"
|
|
||||||
/>
|
|
||||||
</section>
|
|
||||||
</section>
|
</section>
|
||||||
)}
|
)}
|
||||||
{this.activeTab == PreferencesTab.Proxy && (
|
{this.activeTab == PreferencesTab.Proxy && (
|
||||||
@ -224,6 +213,23 @@ export class Preferences extends React.Component {
|
|||||||
})}
|
})}
|
||||||
</section>
|
</section>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
|
{this.activeTab == PreferencesTab.Other && (
|
||||||
|
<section id="other">
|
||||||
|
<h2>Other</h2>
|
||||||
|
<SubTitle title="Start-up"/>
|
||||||
|
<FormSwitch
|
||||||
|
control={
|
||||||
|
<Switcher
|
||||||
|
checked={preferences.openAtLogin}
|
||||||
|
onChange={v => preferences.openAtLogin = v.target.checked}
|
||||||
|
name="startup"
|
||||||
|
/>
|
||||||
|
}
|
||||||
|
label="Automatically start Lens on login"
|
||||||
|
/>
|
||||||
|
</section>
|
||||||
|
)}
|
||||||
</PageLayout>
|
</PageLayout>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -166,7 +166,7 @@
|
|||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
|
|
||||||
&:not(:first-child) {
|
&:not(:first-of-type) {
|
||||||
margin-top: 40px;
|
margin-top: 40px;
|
||||||
|
|
||||||
&.small {
|
&.small {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user