From abb1291a18e8af39402631d1d3719fc62404a7e1 Mon Sep 17 00:00:00 2001 From: wwsun Date: Wed, 7 Aug 2024 16:05:25 +0800 Subject: [PATCH 1/3] fix: update mobile simulator styles --- packages/designer/src/simulator/simulator.tsx | 47 ++++++++++++++----- 1 file changed, 35 insertions(+), 12 deletions(-) diff --git a/packages/designer/src/simulator/simulator.tsx b/packages/designer/src/simulator/simulator.tsx index 78ed1fde..061633f3 100644 --- a/packages/designer/src/simulator/simulator.tsx +++ b/packages/designer/src/simulator/simulator.tsx @@ -25,22 +25,45 @@ function DesktopSimulator({ children }: HTMLCoralProps<'div'>) { } const mobileStyle = css` - --device-viewport-width: 375px; - --device-viewport-height: 812px; - --device-frame-width: 13px; - background-image: url(https://p5.music.126.net/obj/wonDlsKUwrLClGjCm8Kx/21897838692/b1c5/2665/56db/10558c1bb2030d55ceabbcc74431de99.png); - background-repeat: no-repeat; - background-size: 100% 100%; - box-shadow: 0 2px 8px rgb(2 8 20 / 10%), 0 8px 16px rgb(2 8 20 / 8%); - border-radius: 62px; - overflow: hidden; + --device-viewport-width: 360px; + --device-viewport-height: 640px; + position: relative; + margin: auto; + border: 16px black solid; + border-top-width: 60px; + border-bottom-width: 60px; + border-radius: 36px; + + &::before { + content: ''; + display: block; + width: 60px; + height: 5px; + position: absolute; + top: -30px; + left: 50%; + transform: translate(-50%, -50%); + background: #333; + border-radius: 10px; + } + + &::after { + content: ''; + display: block; + width: 35px; + height: 35px; + position: absolute; + left: 50%; + bottom: -65px; + transform: translate(-50%, -50%); + background: #333; + border-radius: 50%; + } .MobileSimulatorDeviceFrame { - border-radius: 50px; width: var(--device-viewport-width); height: var(--device-viewport-height); - margin: var(--device-frame-width); - overflow: hidden; + background: white; } `; From ac298c5c6e61b6e33791a2cf89dc39aab69d2c3e Mon Sep 17 00:00:00 2001 From: wwsun Date: Wed, 7 Aug 2024 16:20:31 +0800 Subject: [PATCH 2/3] docs: update --- apps/playground/src/helpers/index.tsx | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/apps/playground/src/helpers/index.tsx b/apps/playground/src/helpers/index.tsx index 1c9ac06d..37813e14 100644 --- a/apps/playground/src/helpers/index.tsx +++ b/apps/playground/src/helpers/index.tsx @@ -1,5 +1,5 @@ import React from 'react'; -import { Box, Group } from 'coral-system'; +import { Box, Group, Text } from 'coral-system'; import { Avatar, Space, Switch } from 'antd'; import { BranchesOutlined, MenuOutlined, QuestionCircleOutlined } from '@ant-design/icons'; import { registerSetter } from '@music163/tango-designer'; @@ -66,12 +66,12 @@ export function Logo() { export function ProjectDetail() { return ( - + community-test - - + + feature/list - + ); } From 7f9d8005d1fe6f52e27360aea7ec71e9d5aca5c5 Mon Sep 17 00:00:00 2001 From: wwsun Date: Wed, 7 Aug 2024 16:53:37 +0800 Subject: [PATCH 3/3] fix: update icon --- packages/ui/src/icons/dual-outlined.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/ui/src/icons/dual-outlined.tsx b/packages/ui/src/icons/dual-outlined.tsx index 7366a7d1..466170ae 100644 --- a/packages/ui/src/icons/dual-outlined.tsx +++ b/packages/ui/src/icons/dual-outlined.tsx @@ -3,7 +3,7 @@ import { createIcon } from './create-icon'; const DualOutlinedSvg = () => (