mirror of
https://github.com/SomboChea/ui
synced 2024-11-24 15:04:27 +07:00
Merge branch '4.x-master' into 4.x-adds-unit-tests-for-repository-component
This commit is contained in:
commit
157addfd00
29
CHANGELOG.md
29
CHANGELOG.md
@ -2,6 +2,35 @@
|
||||
|
||||
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
||||
|
||||
<a name="0.2.1"></a>
|
||||
## [0.2.1](https://github.com/verdaccio/ui/compare/v0.2.0...v0.2.1) (2019-07-10)
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* [@typescript-eslint](https://github.com/typescript-eslint)/explicit-function-return-type ([31c11f2](https://github.com/verdaccio/ui/commit/31c11f2))
|
||||
* [@typescript-eslint](https://github.com/typescript-eslint)/explicit-member-accessibility ([55f50e9](https://github.com/verdaccio/ui/commit/55f50e9))
|
||||
* [@typescript-eslint](https://github.com/typescript-eslint)/no-explicit-any ([2f28ade](https://github.com/verdaccio/ui/commit/2f28ade))
|
||||
* [@typescript-eslint](https://github.com/typescript-eslint)/no-explicit-any ([6eec4f4](https://github.com/verdaccio/ui/commit/6eec4f4))
|
||||
* [@typescript-eslint](https://github.com/typescript-eslint)/no-explicit-any ([ec8ed12](https://github.com/verdaccio/ui/commit/ec8ed12))
|
||||
* [@typescript-eslint](https://github.com/typescript-eslint)/no-explicit-any for file-size.ts ([b683b68](https://github.com/verdaccio/ui/commit/b683b68))
|
||||
* add missing global font-family ([c57f9dd](https://github.com/verdaccio/ui/commit/c57f9dd))
|
||||
* added packageMeta type ([3c54b11](https://github.com/verdaccio/ui/commit/3c54b11))
|
||||
* container breakpoint ([60b7161](https://github.com/verdaccio/ui/commit/60b7161))
|
||||
* incorrect logos styles ([fdad635](https://github.com/verdaccio/ui/commit/fdad635)), closes [#47](https://github.com/verdaccio/ui/issues/47)
|
||||
* logo component styled ([210bcf3](https://github.com/verdaccio/ui/commit/210bcf3))
|
||||
* remove any types and added additional component state interfaces ([116055c](https://github.com/verdaccio/ui/commit/116055c))
|
||||
* remove token from AppState ([78b4c3f](https://github.com/verdaccio/ui/commit/78b4c3f))
|
||||
* remove undefined error ([d1ed3e7](https://github.com/verdaccio/ui/commit/d1ed3e7))
|
||||
* support deprecated license object properties ([b2e420d](https://github.com/verdaccio/ui/commit/b2e420d))
|
||||
* type lint for login ([91e603e](https://github.com/verdaccio/ui/commit/91e603e))
|
||||
* typescript warnings - prefer-rest-params ([e33570b](https://github.com/verdaccio/ui/commit/e33570b))
|
||||
* update snapshot for verdaccio/jsx-no-style ([e7d145f](https://github.com/verdaccio/ui/commit/e7d145f))
|
||||
* updated type to fix unit test ([7cab3f2](https://github.com/verdaccio/ui/commit/7cab3f2))
|
||||
* verdaccio/jsx-no-style ([55b1402](https://github.com/verdaccio/ui/commit/55b1402))
|
||||
|
||||
|
||||
|
||||
<a name="0.2.0"></a>
|
||||
# [0.2.0](https://github.com/verdaccio/ui/compare/v0.1.11...v0.2.0) (2019-06-20)
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@verdaccio/ui-theme",
|
||||
"version": "0.2.0",
|
||||
"version": "0.2.1",
|
||||
"description": "Verdaccio User Interface",
|
||||
"author": {
|
||||
"name": "Verdaccio Core Team"
|
||||
|
@ -1,6 +1,6 @@
|
||||
import React from 'react';
|
||||
|
||||
import Logo from '../Logo';
|
||||
import Logo, { Size } from '../Logo';
|
||||
import Spinner from '../Spinner';
|
||||
|
||||
import { Wrapper, Badge } from './styles';
|
||||
@ -8,7 +8,7 @@ import { Wrapper, Badge } from './styles';
|
||||
const Loading: React.FC = () => (
|
||||
<Wrapper>
|
||||
<Badge>
|
||||
<Logo />
|
||||
<Logo size={Size.Big} />
|
||||
</Badge>
|
||||
<Spinner />
|
||||
</Wrapper>
|
||||
|
@ -1,3 +1,3 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
|
||||
exports[`<Loading /> component should render the component in default state 1`] = `"<div class=\\"css-1221txa eimgwje0\\"><div class=\\"css-bxochs eimgwje1\\"><div class=\\"css-1tnu3ib em793ed0\\"></div></div><div class=\\"css-vqrgi e1ag4h8b0\\"><div class=\\"MuiCircularProgress-root-1 MuiCircularProgress-colorPrimary-4 MuiCircularProgress-indeterminate-3 css-15gl0ho e1ag4h8b1\\" style=\\"width:50px;height:50px\\" role=\\"progressbar\\"><svg class=\\"MuiCircularProgress-svg-6\\" viewBox=\\"22 22 44 44\\"><circle class=\\"MuiCircularProgress-circle-7 MuiCircularProgress-circleIndeterminate-9\\" cx=\\"44\\" cy=\\"44\\" r=\\"20.2\\" fill=\\"none\\" stroke-width=\\"3.6\\"></circle></svg></div></div></div>"`;
|
||||
exports[`<Loading /> component should render the component in default state 1`] = `"<div class=\\"css-1221txa eimgwje0\\"><div class=\\"css-bxochs eimgwje1\\"><div class=\\"css-kt1gx0 em793ed0\\"></div></div><div class=\\"css-vqrgi e1ag4h8b0\\"><div class=\\"MuiCircularProgress-root-1 MuiCircularProgress-colorPrimary-4 MuiCircularProgress-indeterminate-3 css-15gl0ho e1ag4h8b1\\" style=\\"width:50px;height:50px\\" role=\\"progressbar\\"><svg class=\\"MuiCircularProgress-svg-6\\" viewBox=\\"22 22 44 44\\"><circle class=\\"MuiCircularProgress-circle-7 MuiCircularProgress-circleIndeterminate-9\\" cx=\\"44\\" cy=\\"44\\" r=\\"20.2\\" fill=\\"none\\" stroke-width=\\"3.6\\"></circle></svg></div></div></div>"`;
|
||||
|
@ -3,7 +3,16 @@ import React from 'react';
|
||||
import styled from 'react-emotion';
|
||||
import logo from './img/logo.svg';
|
||||
|
||||
const StyledLogo = styled('div')`
|
||||
export enum Size {
|
||||
Small = '40px',
|
||||
Big = '90px',
|
||||
}
|
||||
|
||||
interface Props {
|
||||
size?: Size;
|
||||
}
|
||||
|
||||
const StyledLogo = styled('div')<Props>`
|
||||
&& {
|
||||
display: inline-block;
|
||||
vertical-align: middle;
|
||||
@ -12,11 +21,11 @@ const StyledLogo = styled('div')`
|
||||
background-size: contain;
|
||||
background-image: url(${logo});
|
||||
background-repeat: no-repeat;
|
||||
width: 40px;
|
||||
height: 40px;`;
|
||||
|
||||
const Logo: React.FC = () => {
|
||||
return <StyledLogo />;
|
||||
width: ${({ size }) => size};
|
||||
height: ${({ size }) => size};
|
||||
`;
|
||||
const Logo: React.FC<Props> = ({ size = Size.Small }) => {
|
||||
return <StyledLogo size={size} />;
|
||||
};
|
||||
|
||||
export default Logo;
|
||||
|
@ -1 +1 @@
|
||||
export { default } from './Logo';
|
||||
export { default, Size } from './Logo';
|
||||
|
Loading…
Reference in New Issue
Block a user