diff --git a/client/index.html b/client/index.html index 49bfb58..3f0a2a7 100644 --- a/client/index.html +++ b/client/index.html @@ -103,6 +103,11 @@ window.addEventListener('resize', onResize) onResize() + function shadowInnerInit(event) { + let v = event.currentTarget + $(v.parentElement.shadowRoot).append(v.children) + v.parentNode.removeChild(v) + } diff --git a/client/ui/App.jsx b/client/ui/App.jsx index 1c10a3f..c6510bf 100644 --- a/client/ui/App.jsx +++ b/client/ui/App.jsx @@ -3,6 +3,7 @@ import MessageContainer from "./chat/MessageContainer.js" import ContactsListItem from "./main/ContactsListItem.js" import RecentsListItem from "./main/RecentsListItem.js" import useEventListener from './useEventListener.js' +import ShadowInner from './ShadowInner.js' export default function App() { const [recentsList, setRecentsList] = React.useState([ @@ -168,7 +169,8 @@ export default function App() { // 分割线 }
@@ -193,6 +195,7 @@ export default function App() {
+ { + // 输入框 + } +
+ + + + +
+ {/* + + Title +
+ +
*/}
diff --git a/client/ui/ShadowInner.jsx b/client/ui/ShadowInner.jsx new file mode 100644 index 0000000..2e90312 --- /dev/null +++ b/client/ui/ShadowInner.jsx @@ -0,0 +1,7 @@ +export default function ShadowInner({ children }) { + return ( +
+ {children} +
+ ) +}