diff --git a/packages/app/package.json b/packages/app/package.json index d9a0bf79..ee5bca54 100755 --- a/packages/app/package.json +++ b/packages/app/package.json @@ -41,7 +41,6 @@ "@tauri-apps/api": "^1.5.4", "@tsmx/human-readable": "^1.0.7", "antd": "^5.20.6", - "antd-mobile": "^5.31.0", "axios": "^1.7.7", "bear-react-carousel": "^4.0.10-alpha.0", "capacitor-music-controls-plugin-v3": "^1.1.0", @@ -49,7 +48,6 @@ "dompurify": "^3.0.0", "evite": "^0.17.0", "fast-average-color": "^9.2.0", - "feather-reactjs": "2.0.13", "framer-motion": "^10.12.17", "fuse.js": "6.5.3", "hls.js": "^1.5.15", @@ -83,7 +81,6 @@ "react-motion": "0.5.2", "react-rnd": "10.3.5", "react-router-dom": "^6.26.2", - "react-ticker": "^1.3.2", "react-transition-group": "^4.4.5", "react-useanimations": "^2.10.0", "realtime-bpm-analyzer": "^3.2.1", diff --git a/packages/app/public/oss-licenses.json b/packages/app/public/oss-licenses.json index bc912150..aacca1a7 100644 --- a/packages/app/public/oss-licenses.json +++ b/packages/app/public/oss-licenses.json @@ -151,11 +151,6 @@ "version": "5.20.6", "license": "MIT" }, - { - "name": "antd-mobile", - "version": "5.37.1", - "license": "MIT" - }, { "name": "axios", "version": "1.7.7", @@ -201,11 +196,6 @@ "url": "https://github.com/fast-average-color/fast-average-color" } }, - { - "name": "feather-reactjs", - "version": "2.0.13", - "license": "MIT" - }, { "name": "framer-motion", "version": "10.18.0", @@ -424,12 +414,6 @@ "license": "MIT", "author": "Remix Software " }, - { - "name": "react-ticker", - "version": "1.3.2", - "license": "MIT", - "author": "https://github.com/AndreasFaust" - }, { "name": "react-transition-group", "version": "4.4.5", diff --git a/packages/app/src/components/SearchButton/index.jsx b/packages/app/src/components/SearchButton/index.jsx index e3b2929b..e46ba497 100755 --- a/packages/app/src/components/SearchButton/index.jsx +++ b/packages/app/src/components/SearchButton/index.jsx @@ -1,5 +1,5 @@ import React from "react" -import { SearchBar } from "antd-mobile" +import { Input } from "antd" import classnames from "classnames" import "./index.less" @@ -39,7 +39,7 @@ export default (props) => { className="searchButton" onClick={() => openSearchBox(true)} > - { + return
+ { + props.list.map((action, index) => { + return
{ + action.onClick() + + if (action.closeOnClick !== false) { + props.close() + } + }} + className={classnames( + "app-actions_menu-action", + { + ["danger"]: action.danger + } + )} + > +
+ {createIconRender(action.icon)} +
+ +
+ {t => t(action.label)} +
+
+ }) + } +
+} + +export default ActionsMenu \ No newline at end of file diff --git a/packages/app/src/layouts/components/@mobile/actionsMenu/index.less b/packages/app/src/layouts/components/@mobile/actionsMenu/index.less new file mode 100644 index 00000000..3426fcea --- /dev/null +++ b/packages/app/src/layouts/components/@mobile/actionsMenu/index.less @@ -0,0 +1,35 @@ +.app-actions_menu { + display: flex; + flex-direction: column; + + gap: 7px; + + color: var(--text-color); + + .app-actions_menu-action { + display: inline-flex; + flex-direction: row; + + align-items: center; + + padding: 10px; + + gap: 20px; + + border-radius: 12px; + + font-size: 1rem; + + background-color: var(--background-color-primary); + + &.danger { + color: var(--danger-color); + } + + .app-actions_menu-label {} + + .app-actions_menu-icon { + font-size: 1.2rem; + } + } +} \ No newline at end of file diff --git a/packages/app/src/layouts/components/@mobile/bottomBar/index.jsx b/packages/app/src/layouts/components/@mobile/bottomBar/index.jsx index d8c1bf2a..623a2a71 100755 --- a/packages/app/src/layouts/components/@mobile/bottomBar/index.jsx +++ b/packages/app/src/layouts/components/@mobile/bottomBar/index.jsx @@ -62,7 +62,6 @@ const PlayerButton = (props) => { const AccountButton = React.forwardRef((props, ref) => { const user = app.userData - const ActionMenu = React.useRef() const handleClick = () => { if (!user) { @@ -73,7 +72,7 @@ const AccountButton = React.forwardRef((props, ref) => { } const handleHold = () => { - ActionMenu.current = app.layout.draggable.actions({ + app.layout.draggable.actions({ list: [ { key: "settings", @@ -81,8 +80,7 @@ const AccountButton = React.forwardRef((props, ref) => { label: "Settings", onClick: () => { app.navigation.goToSettings() - ActionMenu.current.close() - } + }, }, { key: "account", @@ -90,8 +88,7 @@ const AccountButton = React.forwardRef((props, ref) => { label: "Account", onClick: () => { app.navigation.goToAccount() - ActionMenu.current.close() - } + }, }, { key: "logout", @@ -100,8 +97,7 @@ const AccountButton = React.forwardRef((props, ref) => { danger: true, onClick: () => { app.eventBus.emit("app.logout_request") - ActionMenu.current.close() - } + }, } ] }) diff --git a/packages/app/src/pages/post/[post_id].mobile.jsx b/packages/app/src/pages/post/[post_id].mobile.jsx index c955eb25..a355c374 100755 --- a/packages/app/src/pages/post/[post_id].mobile.jsx +++ b/packages/app/src/pages/post/[post_id].mobile.jsx @@ -1,6 +1,5 @@ import React from "react" import * as antd from "antd" -import { FloatingPanel } from "antd-mobile" import PostCard from "@components/PostCard" @@ -8,8 +7,6 @@ import Post from "@models/post" import "./index.less" -const floatingPanelAnchors = [160, 72 + 119, window.innerHeight * 0.8] - export default (props) => { const post_id = props.params.post_id @@ -41,9 +38,5 @@ export default (props) => { return
- - - -
} \ No newline at end of file diff --git a/packages/app/src/pages/tv/live/[id].jsx b/packages/app/src/pages/tv/live/[id].jsx index c64fbb3e..6d156553 100755 --- a/packages/app/src/pages/tv/live/[id].jsx +++ b/packages/app/src/pages/tv/live/[id].jsx @@ -1,6 +1,6 @@ import React from "react" -import Ticker from "react-ticker" import * as antd from "antd" +import Marquee from "react-fast-marquee" import classnames from "classnames" import UserPreview from "@components/UserPreview" @@ -341,13 +341,13 @@ export default class StreamViewer extends React.Component {

{this.state.stream.info?.title}

- {({ index }) => { return

{this.state.stream.info?.description}

}} -
+
} diff --git a/packages/app/src/settings/tap_share/steps/data_editor/index.jsx b/packages/app/src/settings/tap_share/steps/data_editor/index.jsx index f3b8be3f..29fef5c4 100755 --- a/packages/app/src/settings/tap_share/steps/data_editor/index.jsx +++ b/packages/app/src/settings/tap_share/steps/data_editor/index.jsx @@ -1,6 +1,6 @@ import React from "react" import * as antd from "antd" -import { Input } from "antd-mobile" +import { Input } from "antd" import { Icons } from "@components/Icons"