Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release 2021-12-06 #1806

Merged
merged 44 commits into from
Dec 8, 2021
Merged
Changes from 1 commit
Commits
Show all changes
44 commits
Select commit Hold shift + click to select a range
fc48fd1
add template for pull requests (#1751)
asnaith Nov 16, 2021
b21a7b8
Bump ssri from 6.0.1 to 6.0.2 (#1747)
dependabot[bot] Nov 16, 2021
92abc31
Bump merge-deep from 3.0.2 to 3.0.3 (#1744)
dependabot[bot] Nov 16, 2021
9784c12
Bump dns-packet from 1.3.1 to 1.3.4 (#1745)
dependabot[bot] Nov 16, 2021
3599ee4
Bump tmpl from 1.0.4 to 1.0.5 (#1741)
dependabot[bot] Nov 16, 2021
6337f63
Bump path-parse from 1.0.6 to 1.0.7 (#1742)
dependabot[bot] Nov 16, 2021
71e7d7e
Bump color-string from 1.5.3 to 1.6.0 (#1743)
dependabot[bot] Nov 16, 2021
4e64f03
Bump hosted-git-info from 2.8.8 to 2.8.9 (#1746)
dependabot[bot] Nov 16, 2021
9addf3e
bump cypress to v9.0 (#1749)
asnaith Nov 16, 2021
6674c0f
Bump url-parse from 1.4.7 to 1.5.3 (#1748)
dependabot[bot] Nov 16, 2021
f994607
Link sharing redesign (#1722)
Tbaut Nov 16, 2021
328b402
Resolved (#1731)
RyRy79261 Nov 16, 2021
0062f31
Add subdirectory for pr template (#1756)
asnaith Nov 17, 2021
d80d513
add test for hotkey navigation in file preview (#1755)
asnaith Nov 17, 2021
9c52fbe
fix video preview overflow (#1752)
FSM1 Nov 17, 2021
ef5e677
Share files from browser support (#1736)
tanmoyAtb Nov 18, 2021
7170268
Revert "copy working" (#1759)
FSM1 Nov 19, 2021
9dc9db8
Translations update from Hosted Weblate (#1753)
weblate Nov 22, 2021
c2ee766
[ImgBot] Optimize images (#1767)
imgbot[bot] Nov 22, 2021
4e867ca
Report modal styles and cut off fix (#1766)
tanmoyAtb Nov 23, 2021
ea0e03f
Fix Mobile Nav Drawer blocks breadcrumb (#1768)
FSM1 Nov 23, 2021
57028b1
secondary colors update (#1769)
tanmoyAtb Nov 23, 2021
99c3cce
File info modal CID and Key copy arrangements (#1773)
tanmoyAtb Nov 24, 2021
a011e6f
fix share transfer modal alignment (#1774)
FSM1 Nov 24, 2021
d1d8b62
move pr template to .github root dir (#1776)
asnaith Nov 24, 2021
484b7f1
UI fix (#1777)
tanmoyAtb Nov 25, 2021
2c1ea37
resolve double tap (#1778)
FSM1 Nov 25, 2021
1335725
Mobile sharing folder rename modal (#1779)
RyRy79261 Nov 25, 2021
ffa9706
Rename with split extension (#1760)
RyRy79261 Nov 25, 2021
d4b978e
Add ui test coverage for link creation / deletion (#1775)
asnaith Nov 26, 2021
c50aca3
Translated using Weblate (French) (#1784)
weblate Nov 29, 2021
e2dc429
Bump Cypress to 9.1 (#1785)
Tbaut Nov 30, 2021
a31313b
removing gaming dashboard from monorepo (#1790)
FSM1 Dec 1, 2021
85401e9
Fix 0 randomly appearing (#1789)
Tbaut Dec 1, 2021
44fe032
Fix typing issues that appeared with cypress v9.1 upgrade (#1791)
Tbaut Dec 1, 2021
f8e65e3
Edit PR template (#1798)
Tbaut Dec 2, 2021
f1e3828
Heic loader (#1765)
RyRy79261 Dec 2, 2021
9149d5e
change for create (#1797)
Tbaut Dec 3, 2021
9f9e397
attempt fixing storybook build (#1801)
FSM1 Dec 3, 2021
e611241
add sorting header for mobile file browser (#1786)
FSM1 Dec 6, 2021
2139dba
Add header content for selected (#1796)
FSM1 Dec 7, 2021
4674382
Translated using Weblate (French) (#1811)
weblate Dec 7, 2021
f2922a9
fix breaking tests (#1813)
FSM1 Dec 8, 2021
e3778cf
Enforce props on a new line for multiline components (#1807)
Tbaut Dec 8, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Heic loader (#1765)
* Colors fixed

* Colors fixed

* Forced default

* Changed to transparent

* lingui extract

* resolve dark mode spinner

Co-authored-by: Michael Yankelev <12774278+FSM1@users.noreply.github.com>
Co-authored-by: Tanmoy Basak Anjan <tanmoy3399@gmail.com>
Co-authored-by: Thibaut Sardan <33178835+Tbaut@users.noreply.github.com>
Co-authored-by: GitHub Actions <actions@github.com>
Co-authored-by: Michael Yankelev <myankelev@gmail.com>
6 people authored Dec 2, 2021
commit f1e3828e8daf35eec48684c4cb0615b6210be745
2 changes: 1 addition & 1 deletion packages/common-components/src/Button/Button.tsx
Original file line number Diff line number Diff line change
@@ -361,7 +361,7 @@ const Button: React.FC<IButtonProps> = ({
{loading && (
<>
<Loading
type="inherit"
type="initial"
size={16}
/>
</>
56 changes: 42 additions & 14 deletions packages/common-components/src/Spinner/Loading.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import React from "react"
import React, { useMemo } from "react"
import { ITheme, useTheme } from "@chainsafe/common-theme"

export interface ILoadingProps {
type?: "inherit" | "primary" | "dark" | "light"
type?: "initial" | "primary" | "dark" | "light"
size?: number
className?: string
}
@@ -13,6 +13,42 @@ const Loading: React.FC<ILoadingProps> = ({
className
}) => {
const theme: ITheme = useTheme()

const uniqueKey = `${Math.random()}-${Math.random()}`

const {
start,
end
} = useMemo(() => {
switch (type) {
case "primary":
return {
start: theme.palette.primary.main,
end: "transparent"
}
case "light":
return {
start: theme.palette.common.white.main,
end: "transparent"
}
case "dark":
return {
start: theme.palette.common.black.main,
end: "transparent"
}
case "initial":
return {
start: "#FFFFFF",
end: "transparent"
}
default:
return {
start: "#FFFFFF",
end: "transparent"
}
}
}, [type, theme.palette])

return (
<svg
width={size}
@@ -22,35 +58,27 @@ const Loading: React.FC<ILoadingProps> = ({
>
<defs>
<linearGradient
id="gradient"
id={`gradient-${uniqueKey}`}
x1="0%"
y1="0%"
x2="0%"
y2="100%"
>
<stop
offset="0%"
stopColor={
type === "primary"
? theme.palette.primary.main
: type === "dark"
? theme.palette.common.black.main
: theme.palette.additional["gray"][5]
}
stopColor={start}
/>
<stop
offset="100%"
stopColor={
type === "light" ? theme.palette.common.white.main : "transparent"
}
stopColor={end}
/>
</linearGradient>
</defs>
<circle
cx="50"
cy="50"
r="47"
stroke="url(#gradient)"
stroke={`url(#gradient-${uniqueKey})`}
strokeWidth="6"
fill="none"
transform="rotate(90 50 50)"
2 changes: 1 addition & 1 deletion packages/files-ui/src/Components/Elements/MnemonicForm.tsx
Original file line number Diff line number Diff line change
@@ -137,7 +137,7 @@ const MnemonicForm = ({ buttonLabel, onComplete }: Props) => {
className={classes.loader}
>
<Loading
type="inherit"
type="initial"
size={16}
/>
<Trans>
Original file line number Diff line number Diff line change
@@ -123,7 +123,7 @@ const ShareTransferRequestModal = ({ requests }: Props) => {
requests.length > 1 && (isClearing
? <Loading
size={25}
type='inherit'
type="initial"
/>
: <Typography
className={clsx(classes.clearAll)}
Original file line number Diff line number Diff line change
@@ -240,7 +240,7 @@ const FileInfoModal = ({ filePath, close }: IFileInfoModuleProps) => {
<div className={classes.loadingContainer}>
<Loading
size={32}
type="inherit"
type="initial"
/>
</div>
</Grid>
Original file line number Diff line number Diff line change
@@ -227,7 +227,7 @@ const LinkList = ({ bucketId, bucketEncryptionKey }: Props) => {
className={classes.loader}
>
<Loading
type="inherit"
type="initial"
size={24}
/>
</Typography>
Original file line number Diff line number Diff line change
@@ -212,7 +212,7 @@ const SharingLink = ({ nonce, bucketEncryptionKey, refreshNonces }: Props) => {
className={classes.loader}
>
<Loading
type="inherit"
type="initial"
size={24}
/>
</Typography>
Original file line number Diff line number Diff line change
@@ -276,7 +276,7 @@ const ReportFileModal = ({ filePath, close }: IReportFileModalProps) => {
<div className={classes.loadingContainer}>
<Loading
size={32}
type="inherit"
type="initial"
/>
</div>
</Grid>
Original file line number Diff line number Diff line change
@@ -263,7 +263,7 @@ const SharedFileBrowser = () => {
return (
<div className={classes.messageWrapper}>
<Loading
type="inherit"
type="initial"
size={48}
/>
</div>
Original file line number Diff line number Diff line change
@@ -848,7 +848,7 @@ const FilesList = ({ isShared = false }: Props) => {
>
<Loading
size={24}
type="light"
type="initial"
/>
<Typography
variant="body2"
Original file line number Diff line number Diff line change
@@ -127,7 +127,7 @@ const LinkSharingModule = () => {
{!error && !newBucket && isValidNonce !== false && (
<>
<Loading
type="inherit"
type="initial"
size={48}
className={classes.icon}
/>
Original file line number Diff line number Diff line change
@@ -360,7 +360,7 @@ const InitialScreen = ({ className }: IInitialScreen) => {
<Loading
className={classes.loader}
size={50}
type='inherit'
type="initial"
/>
</>}
</section>
Original file line number Diff line number Diff line change
@@ -48,7 +48,7 @@ const ImagePreview: React.FC<IPreviewRendererProps> = ({ contents, contentType }
const [imageUrl, setImageUrl] = useState<string | undefined>()
const [loading, setLoading] = useState(false)
useEffect(() => {
if (contentType !== "image/heic") {
if (contentType !== "image/heic" && contentType !== "image/heif") {
setImageUrl(URL.createObjectURL(contents))
} else {
setLoading(true)
@@ -72,7 +72,7 @@ const ImagePreview: React.FC<IPreviewRendererProps> = ({ contents, contentType }
{loading
? <Loading
size={50}
type='inherit'
type="initial"
/>
: <TransformWrapper
options={{
Original file line number Diff line number Diff line change
@@ -41,7 +41,7 @@ const SavedBrowsers: React.FC<{isRefreshing: boolean}> = ({ isRefreshing }) => {
>
<Trans>Saved Browsers</Trans> {isRefreshing && <Loading
size={16}
type='inherit'
type="initial"
/>}
</Typography>
{browserShares
2 changes: 1 addition & 1 deletion packages/storage-ui/src/Components/Modules/LoginModule.tsx
Original file line number Diff line number Diff line change
@@ -319,7 +319,7 @@ const LoginModule = ({ className }: IInitialScreen) => {
<Loading
className={classes.loader}
size={50}
type='inherit'
type="initial"
/>
</>}
</section>