1
0
mirror of https://github.com/lensapp/lens.git synced 2025-05-20 05:10:56 +00:00

Fine-tuning page view

Signed-off-by: Alex Andreev <alex.andreev.email@gmail.com>
This commit is contained in:
Alex Andreev 2021-05-16 06:51:17 +03:00
parent 974f04a15a
commit 8fba4ee331
7 changed files with 30 additions and 10 deletions

View File

@ -574,11 +574,11 @@ export class Extensions extends React.Component {
<DropFileInput onDropFiles={installOnDrop}> <DropFileInput onDropFiles={installOnDrop}>
<PageLayout showOnTop className="Extensions" contentGaps={false}> <PageLayout showOnTop className="Extensions" contentGaps={false}>
<section> <section>
<h2>Lens Extensions</h2> <h1>Extensions</h1>
<div> {/* <div>
Add new features and functionality via Lens Extensions. Add new features and functionality via Lens Extensions.
Check out documentation to <a href={`${docsUrl}/latest/extensions/usage/`} target="_blank" rel="noreferrer">learn more</a> or see the list of <a href="https://github.com/lensapp/lens-extensions/blob/main/README.md" target="_blank" rel="noreferrer">available extensions</a>. Check out documentation to <a href={`${docsUrl}/latest/extensions/usage/`} target="_blank" rel="noreferrer">learn more</a> or see the list of <a href="https://github.com/lensapp/lens-extensions/blob/main/README.md" target="_blank" rel="noreferrer">available extensions</a>.
</div> </div> */}
<Install <Install
supportedFormats={supportedFormats} supportedFormats={supportedFormats}

View File

@ -0,0 +1,7 @@
.icon {
@apply h-5 w-5 cursor-pointer;
}
.icon:hover {
color: var(--textColorAccent);
}

View File

@ -1,3 +1,4 @@
import styles from "./install.module.css";
import React from "react"; import React from "react";
import { prevDefault } from "../../utils"; import { prevDefault } from "../../utils";
import { Button } from "../button"; import { Button } from "../button";
@ -32,8 +33,7 @@ export function Install(props: Props) {
const { installPath, supportedFormats, onChange, installFromInput, installFromSelectFileDialog } = props; const { installPath, supportedFormats, onChange, installFromInput, installFromSelectFileDialog } = props;
return ( return (
<section> <section className="mt-2">
<h2>Install</h2>
<SubTitle title={`Path or URL to an extension package (${supportedFormats.join(", ")})`}/> <SubTitle title={`Path or URL to an extension package (${supportedFormats.join(", ")})`}/>
<div className="flex"> <div className="flex">
<div className="flex-1"> <div className="flex-1">
@ -49,8 +49,9 @@ export function Install(props: Props) {
onSubmit={installFromInput} onSubmit={installFromInput}
iconRight={ iconRight={
<Icon <Icon
interactive interactive={false}
material="folder" className={styles.icon}
material="folder_open"
onClick={prevDefault(installFromSelectFileDialog)} onClick={prevDefault(installFromSelectFileDialog)}
tooltip="Browse" tooltip="Browse"
/> />
@ -62,13 +63,13 @@ export function Install(props: Props) {
primary primary
label="Install" label="Install"
className="w-80 h-full" className="w-80 h-full"
disabled={ExtensionInstallationStateStore.anyPreInstallingOrInstalling || !installInputValidator.validate(installPath)} // disabled={ExtensionInstallationStateStore.anyPreInstallingOrInstalling || !installInputValidator.validate(installPath)}
waiting={ExtensionInstallationStateStore.anyPreInstallingOrInstalling} waiting={ExtensionInstallationStateStore.anyPreInstallingOrInstalling}
onClick={installFromInput} onClick={installFromInput}
/> />
</div> </div>
</div> </div>
<small className="mt-1"> <small className="mt-3">
<b>Pro-Tip</b>: you can drag-n-drop tarball-file to this area <b>Pro-Tip</b>: you can drag-n-drop tarball-file to this area
</small> </small>
</section> </section>

View File

@ -10,3 +10,7 @@
.enabled { .enabled {
color: var(--colorOk); color: var(--colorOk);
} }
.title {
margin-bottom: 6px!important;
}

View File

@ -120,6 +120,7 @@ export function InstalledExtensions({ extensions, uninstall }: Props) {
return ( return (
<section> <section>
<h2 className={styles.title}>Installed</h2>
<List <List
title="Manage your extensions in here." title="Manage your extensions in here."
columns={columns} columns={columns}

View File

@ -170,6 +170,13 @@
color: var(--textColorAccent); color: var(--textColorAccent);
} }
h1 {
color: var(--textColorAccent);
font-size: 22px;
font-weight: bold;
margin-bottom: 10px;
}
h2 { h2 {
font-size: 18px; font-size: 18px;
line-height: 20px; line-height: 20px;

View File

@ -22,7 +22,7 @@ export function List({ columns, data, title, items, filters, }: Props) {
return ( return (
<> <>
<div className="flex align-center justify-between mb-8"> <div className="flex align-center justify-between mb-6">
<div className="mr-6"> <div className="mr-6">
{title} {title}
</div> </div>