From 5da2d680c66b0a005f36d799d0f1f26acd06d0a4 Mon Sep 17 00:00:00 2001 From: Christopher Date: Thu, 4 Feb 2021 20:42:53 +0100 Subject: [PATCH 1/3] fix(zoom): inital commit on possbile fix --- phone/src/Phone.css | 5 ++++ phone/src/Phone.tsx | 4 +-- .../apps/settings/components/SettingItem.tsx | 2 +- phone/src/config/default.json | 4 +-- phone/src/ui/components/GridMenu.tsx | 26 +++++++++---------- 5 files changed, 22 insertions(+), 19 deletions(-) diff --git a/phone/src/Phone.css b/phone/src/Phone.css index 616c518..593f50e 100644 --- a/phone/src/Phone.css +++ b/phone/src/Phone.css @@ -58,3 +58,8 @@ *::-webkit-scrollbar-thumb { background-color: #666; } + + +.zoomProp { + transform: scale(10); +} \ No newline at end of file diff --git a/phone/src/Phone.tsx b/phone/src/Phone.tsx index b507192..76093f1 100644 --- a/phone/src/Phone.tsx +++ b/phone/src/Phone.tsx @@ -323,8 +323,8 @@ function Phone() { return ( -
-
+
+
({ width: '20%', }, tooltip: { - bottom: -8, + bottom: 0, fontSize: 12, }, })); export const GridMenu = ({ items, Component = AppIcon }) => { + const { t } = useTranslation(); const setKey = useKeyboard(); const classes = useStyles(); - useEffect(function registerKeyHandlers() { setKey('ArrowLeft', () => { console.log(':v'); }); - // eslint-disable-next-line + // eslint-disable-next-linep }, []); return ( @@ -35,15 +36,12 @@ export const GridMenu = ({ items, Component = AppIcon }) => { {items && items.length && items.map((item) => ( - // + { > - // + ))} From 28b2599e75507d56c835ed27e0e7c7eb7bfb3563 Mon Sep 17 00:00:00 2001 From: J Francisco Rader Date: Fri, 5 Feb 2021 16:09:31 -0500 Subject: [PATCH 2/3] Fix zoom origin --- phone/src/Phone.css | 5 +++-- phone/src/Phone.tsx | 7 +++++-- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/phone/src/Phone.css b/phone/src/Phone.css index 593f50e..bd517ae 100644 --- a/phone/src/Phone.css +++ b/phone/src/Phone.css @@ -1,12 +1,13 @@ .PhoneWrapper { width: 100vw; height: 100vh; + position: relative; } .Phone { position: absolute; - bottom: 0vh; - right: 0vh; + bottom: 0; + right: 0; width: 500px; height: 1000px; background-size: cover; diff --git a/phone/src/Phone.tsx b/phone/src/Phone.tsx index 76093f1..e2a7d94 100644 --- a/phone/src/Phone.tsx +++ b/phone/src/Phone.tsx @@ -323,9 +323,12 @@ function Phone() { return ( -
+
-
+
Date: Sat, 6 Feb 2021 13:32:43 -0500 Subject: [PATCH 3/3] tweak(phone/app-grid): Tweaked tooltip styling --- phone/src/ui/components/GridMenu.tsx | 34 +++++++++++++++------------- 1 file changed, 18 insertions(+), 16 deletions(-) diff --git a/phone/src/ui/components/GridMenu.tsx b/phone/src/ui/components/GridMenu.tsx index 0d64c87..df9610c 100644 --- a/phone/src/ui/components/GridMenu.tsx +++ b/phone/src/ui/components/GridMenu.tsx @@ -1,7 +1,7 @@ import React, { useEffect } from 'react'; import { AppIcon } from './AppIcon'; import { useTranslation } from 'react-i18next'; -import { Grid, makeStyles, Tooltip } from '@material-ui/core'; +import { Grid, makeStyles, Tooltip, Zoom } from '@material-ui/core'; import { Link } from 'react-router-dom'; import { useKeyboard } from '../../os/keyboard/hooks/useKeyboard'; @@ -14,22 +14,22 @@ const useStyles = makeStyles((theme) => ({ width: '20%', }, tooltip: { - bottom: 0, fontSize: 12, }, })); export const GridMenu = ({ items, Component = AppIcon }) => { - const { t } = useTranslation(); const setKey = useKeyboard(); const classes = useStyles(); + const { t } = useTranslation(); + useEffect(function registerKeyHandlers() { setKey('ArrowLeft', () => { console.log(':v'); }); - // eslint-disable-next-linep + // eslint-disable-next-line }, []); - + // TODO: Fix tooltip position to be closer to app icon return ( @@ -37,21 +37,23 @@ export const GridMenu = ({ items, Component = AppIcon }) => { items.length && items.map((item) => ( - - - - + + + + ))}