mirror of
https://github.com/muerwre/vault-frontend.git
synced 2025-04-25 12:56:41 +07:00
ImageUpload (first attmpt)
This commit is contained in:
parent
75fb88b209
commit
af3b413903
8 changed files with 179 additions and 4 deletions
22
src/components/input/ArcProgress/index.tsx
Normal file
22
src/components/input/ArcProgress/index.tsx
Normal file
|
@ -0,0 +1,22 @@
|
|||
import React, { FC } from 'react';
|
||||
import * as styles from './styles.scss';
|
||||
import { describeArc } from '~/utils/dom';
|
||||
|
||||
interface IProps {
|
||||
size: number;
|
||||
progress: number;
|
||||
};
|
||||
|
||||
export const ArcProgress: FC<IProps> = ({ size, progress }) => (
|
||||
<svg className={styles.icon} width={size} height={size}>
|
||||
<path
|
||||
d={describeArc(
|
||||
size / 2,
|
||||
size / 2,
|
||||
size / 2 - 2,
|
||||
360 * (1 - progress),
|
||||
360,
|
||||
)}
|
||||
/>
|
||||
</svg>
|
||||
);
|
8
src/components/input/ArcProgress/styles.scss
Normal file
8
src/components/input/ArcProgress/styles.scss
Normal file
|
@ -0,0 +1,8 @@
|
|||
.icon {
|
||||
fill: $red;
|
||||
stroke: none;
|
||||
|
||||
//path {
|
||||
// transition: d 0.5s;
|
||||
//}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue