mirror of
https://github.com/muerwre/vault-frontend.git
synced 2025-04-25 04:46:40 +07:00
rotated colors
This commit is contained in:
parent
0941253b1c
commit
6547f3bed0
10 changed files with 82 additions and 43 deletions
|
@ -2,15 +2,18 @@ import React, { FC } from 'react';
|
||||||
import classNames = require("classnames");
|
import classNames = require("classnames");
|
||||||
import * as styles from './styles.scss';
|
import * as styles from './styles.scss';
|
||||||
|
|
||||||
type IProps = React.HTMLAttributes<HTMLDivElement> & {}
|
type IProps = React.HTMLAttributes<HTMLDivElement> & {
|
||||||
|
seamless?: boolean;
|
||||||
|
}
|
||||||
|
|
||||||
const Card: FC<IProps> = ({
|
const Card: FC<IProps> = ({
|
||||||
className,
|
className,
|
||||||
children,
|
children,
|
||||||
|
seamless,
|
||||||
...props
|
...props
|
||||||
}) => (
|
}) => (
|
||||||
<div
|
<div
|
||||||
className={classNames(styles.card, className)}
|
className={classNames(styles.card, className, { seamless })}
|
||||||
{...props}
|
{...props}
|
||||||
>
|
>
|
||||||
{children}
|
{children}
|
||||||
|
|
|
@ -1,6 +1,11 @@
|
||||||
.card {
|
.card {
|
||||||
background-color: #111111;
|
background-color: #111111;
|
||||||
border-radius: $panel_radius;
|
border-radius: $panel_radius;
|
||||||
|
padding: $gap;
|
||||||
|
|
||||||
@include outer_shadow();
|
@include outer_shadow();
|
||||||
|
|
||||||
|
&:global(.seamless) {
|
||||||
|
padding: 0;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -22,7 +22,7 @@ const Grid: FC<IProps> = ({
|
||||||
style = {},
|
style = {},
|
||||||
columns = 'auto',
|
columns = 'auto',
|
||||||
rows = 'auto',
|
rows = 'auto',
|
||||||
gap = 20,
|
gap = 10,
|
||||||
...props
|
...props
|
||||||
}) => (
|
}) => (
|
||||||
<div
|
<div
|
||||||
|
|
|
@ -3,15 +3,16 @@ import * as styles from './styles.scss';
|
||||||
import classNames = require("classnames");
|
import classNames = require("classnames");
|
||||||
|
|
||||||
type IProps = HTMLAttributes<HTMLDivElement> & {
|
type IProps = HTMLAttributes<HTMLDivElement> & {
|
||||||
|
seamless?: boolean;
|
||||||
}
|
}
|
||||||
|
|
||||||
const Panel: FC<IProps> = ({
|
const Panel: FC<IProps> = ({
|
||||||
className,
|
className,
|
||||||
children,
|
children,
|
||||||
|
seamless,
|
||||||
...props
|
...props
|
||||||
}) => (
|
}) => (
|
||||||
<div className={classNames(styles.panel, className)} {...props}>
|
<div className={classNames(styles.panel, className, { seamless })} {...props}>
|
||||||
{children}
|
{children}
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
|
|
|
@ -1,3 +1,7 @@
|
||||||
.panel {
|
.panel {
|
||||||
|
padding: $gap;
|
||||||
|
|
||||||
@include outer_shadow();
|
@include outer_shadow();
|
||||||
|
|
||||||
|
&:global(.seamless) { padding: 0; }
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,4 @@
|
||||||
.wrap {
|
.wrap {
|
||||||
flex: 1;
|
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: flex-start;
|
align-items: flex-start;
|
||||||
justify-content: flex-start;
|
justify-content: flex-start;
|
||||||
|
|
|
@ -8,11 +8,15 @@ import { Panel } from "~/components/containers/Panel";
|
||||||
import { TextInput } from "~/components/input/TextInput";
|
import { TextInput } from "~/components/input/TextInput";
|
||||||
import classNames = require("classnames");
|
import classNames = require("classnames");
|
||||||
import { Scroll } from "~/components/containers/Scroll";
|
import { Scroll } from "~/components/containers/Scroll";
|
||||||
|
import { Grid } from "~/components/containers/Grid";
|
||||||
|
import { Tags } from "~/components/node/Tags";
|
||||||
|
import { Button } from "~/components/input/Button";
|
||||||
|
import { Filler } from "~/components/containers/Filler";
|
||||||
|
|
||||||
interface IProps {}
|
interface IProps {}
|
||||||
|
|
||||||
const EditorExample: FC<IProps> = () => (
|
const EditorExample: FC<IProps> = () => (
|
||||||
<Card className={styles.wrap}>
|
<Card className={styles.wrap} seamless>
|
||||||
<Group horizontal className={styles.group} seamless>
|
<Group horizontal className={styles.group} seamless>
|
||||||
<div className={styles.editor}>
|
<div className={styles.editor}>
|
||||||
<Panel className={styles.editor_panel}>
|
<Panel className={styles.editor_panel}>
|
||||||
|
@ -29,20 +33,36 @@ const EditorExample: FC<IProps> = () => (
|
||||||
</CellGrid>
|
</CellGrid>
|
||||||
</Scroll>
|
</Scroll>
|
||||||
</Panel>
|
</Panel>
|
||||||
|
|
||||||
<Panel className={styles.editor_panel}>
|
|
||||||
Cover panel
|
|
||||||
</Panel>
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div className={styles.panel}>
|
<div className={styles.panel}>
|
||||||
<Group>
|
<Panel>
|
||||||
<Card>
|
<TextInput onChange={console.log} label="Название" />
|
||||||
<Padder>
|
</Panel>
|
||||||
panel
|
|
||||||
</Padder>
|
<Panel className={styles.panel_main}>
|
||||||
</Card>
|
<Group>
|
||||||
</Group>
|
<Tags
|
||||||
|
tags={[
|
||||||
|
{ title: 'Избранный', feature: 'red' },
|
||||||
|
{ title: 'Плейлист', feature: 'green' },
|
||||||
|
{ title: 'Просто' },
|
||||||
|
{ title: '+ фото', feature: 'black' },
|
||||||
|
{ title: '+ с музыкой', feature: 'black' },
|
||||||
|
]}
|
||||||
|
/>
|
||||||
|
|
||||||
|
<Filler />
|
||||||
|
|
||||||
|
<Card className={styles.feature_card}>Cover changer</Card>
|
||||||
|
|
||||||
|
<Card className={styles.feature_card}>Track</Card>
|
||||||
|
</Group>
|
||||||
|
</Panel>
|
||||||
|
|
||||||
|
<Panel>
|
||||||
|
<Button>Submit?</Button>
|
||||||
|
</Panel>
|
||||||
</div>
|
</div>
|
||||||
</Group>
|
</Group>
|
||||||
</Card>
|
</Card>
|
||||||
|
|
|
@ -17,8 +17,9 @@
|
||||||
background: $editor_panel_bg;
|
background: $editor_panel_bg;
|
||||||
flex: 0 0 33%;
|
flex: 0 0 33%;
|
||||||
border-radius: 0 $radius $radius 0;
|
border-radius: 0 $radius $radius 0;
|
||||||
padding: $gap;
|
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
@include outer_shadow();
|
@include outer_shadow();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -30,7 +31,6 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
.editor_panel {
|
.editor_panel {
|
||||||
padding: $gap;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.editor_image_panel {
|
.editor_image_panel {
|
||||||
|
@ -42,7 +42,16 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
.editor_image {
|
.editor_image {
|
||||||
background: lighten($main_bg_color, 20%);
|
background: transparentize(white, 0.95);
|
||||||
padding-bottom: 100%;
|
padding-bottom: 100%;
|
||||||
border-radius: $radius;
|
border-radius: $radius;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.feature_card {
|
||||||
|
height: 100px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.panel_main {
|
||||||
|
flex: 1;
|
||||||
|
display: flex;
|
||||||
|
}
|
||||||
|
|
|
@ -60,17 +60,15 @@ const ImageExample: FC<IProps> = () => (
|
||||||
</Group>
|
</Group>
|
||||||
</Padder>
|
</Padder>
|
||||||
|
|
||||||
{
|
<Tags
|
||||||
<Tags
|
tags={[
|
||||||
tags={[
|
{ title: 'Избранный', feature: 'red' },
|
||||||
{ title: 'Избранный', feature: 'red' },
|
{ title: 'Плейлист', feature: 'green' },
|
||||||
{ title: 'Плейлист', feature: 'green' },
|
{ title: 'Просто' },
|
||||||
{ title: 'Просто' },
|
{ title: '+ фото', feature: 'black' },
|
||||||
{ title: '+ фото', feature: 'black' },
|
{ title: '+ с музыкой', feature: 'black' },
|
||||||
{ title: '+ с музыкой', feature: 'black' },
|
]}
|
||||||
]}
|
/>
|
||||||
/>
|
|
||||||
}
|
|
||||||
|
|
||||||
<NodeRelated
|
<NodeRelated
|
||||||
title="First album"
|
title="First album"
|
||||||
|
|
|
@ -7,7 +7,7 @@ $olive: #8bc12a;
|
||||||
$orange: #ff7549;
|
$orange: #ff7549;
|
||||||
$grass: #41800d;
|
$grass: #41800d;
|
||||||
|
|
||||||
$red_gradient: linear-gradient(170deg, $orange -50%, $red 150%);
|
$red_gradient: linear-gradient(165deg, $orange -50%, $red 150%);
|
||||||
$blue_gradient: linear-gradient(170deg, $green, $dark_blue);
|
$blue_gradient: linear-gradient(170deg, $green, $dark_blue);
|
||||||
$green_gradient: linear-gradient(170deg, $olive -20%, $grass 120%);
|
$green_gradient: linear-gradient(170deg, $olive -20%, $grass 120%);
|
||||||
$purple_gradient: linear-gradient(170deg, $red, $dark_blue);
|
$purple_gradient: linear-gradient(170deg, $red, $dark_blue);
|
||||||
|
@ -15,13 +15,13 @@ $purple_gradient: linear-gradient(170deg, $red, $dark_blue);
|
||||||
//$color_yellow: yellow;
|
//$color_yellow: yellow;
|
||||||
|
|
||||||
//$main_bg_color: #161616;
|
//$main_bg_color: #161616;
|
||||||
$main_bg_color: #111111;
|
$main_bg_color: #131112;
|
||||||
$main_text_color: white;
|
$main_text_color: white;
|
||||||
|
|
||||||
$content_bg_color: #222222;
|
$content_bg_color: #222222;
|
||||||
$content_bg_secondary: darken($content_bg_color, 3%);
|
$content_bg_secondary: darken($content_bg_color, 3%);
|
||||||
|
|
||||||
$cell_bg: #222222;
|
$cell_bg: lighten($main_bg_color, 5%);
|
||||||
|
|
||||||
$text_normal: 16px;
|
$text_normal: 16px;
|
||||||
$text_small: 14px;
|
$text_small: 14px;
|
||||||
|
@ -29,16 +29,16 @@ $text_big: 20px;
|
||||||
$text_sign: 22px;
|
$text_sign: 22px;
|
||||||
|
|
||||||
$input_bg_color: transparentize(black, 0.8);
|
$input_bg_color: transparentize(black, 0.8);
|
||||||
$button_bg_color: $red;
|
$button_bg_color: $red_gradient;
|
||||||
|
|
||||||
$comment_bg: #191919;
|
$comment_bg: lighten($main_bg_color, 4%);
|
||||||
$panel_bg: #191919;
|
$panel_bg: transparent;
|
||||||
$node_bg: #111111;
|
$node_bg: $main_bg_color;
|
||||||
$node_image_bg: #131313;
|
$node_image_bg: lighten($main_bg_color, 4%);
|
||||||
$node_title_background: #191919;
|
$node_title_background: darken($main_bg_color, 4%);
|
||||||
|
|
||||||
$editor_panel_bg: lighten($main_bg_color, 5%);
|
$editor_panel_bg: transparentize(white, 0.98);
|
||||||
$editor_bg: lighten($main_bg_color, 10%);
|
$editor_bg: lighten($main_bg_color, 4%);
|
||||||
|
|
||||||
$scroll_color: $red_gradient;
|
$scroll_color: $red_gradient;
|
||||||
$scroll_inactive_opacity: 0.5;
|
$scroll_inactive_opacity: 0.5;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue