Floating Window in React Native?
Hallo,
villeicht nicht der beste ord um das zu fragen, aber wie könnte man ein
Foating Window(Fenster das über alle anwendungen ist, auch wen sie minimiert ist)
machen?
In welcher Programmiersprache?
javascript
z.b
export default function App() {
return (
<ScrollView>
<ListItem title="List Item" />
</ScrollView>
2 Antworten
Solche "Floating Widgets" gibt es nur auf Android, nicht auf iOS. Entsprechend geht das nicht direkt mit React Native.
Du musst da also spezifisch was für die Android-Plattform machen. Vielleicht hilft dir diese Antwort weiter: https://stackoverflow.com/questions/52542175/how-to-draw-over-other-apps-in-react-native
https://stackoverflow.com/questions/52542175/how-to-draw-over-other-apps-in-react-native
hab ich auch gesehen, sprechen mir aber in zu vielen rätzeln
HTML:
<div id= "console" class="window card z-depth-3" >
<span class="windowTitle"
>Window 1</span> <i class="material-icons" id="refreshbtn">refresh</i>
<br><br>
I am a draggable window
<a id="dragbtn" class="btn tooltipped red" onclick=drag()>Drag</a>
</div>
CSS:
#console{
width: 150px;
height: 150px;
padding: 10px;
}
body {
background-color: #212121;
}
span.windowTitle {
/*font-family: "Segoe UI";*/
font-size: 50;
width: 100px;
height: 100px;
position: relative;
font-family: "Roboto";
font-weight: bold
}
#refreshbtn{
position: absolute;
position-right: 200px
}
JavaScript:
document.ready(function(){
$(function() {
$( "#console" ).draggable();
})
});
function drag(){
$(function() { $( "#console" ).draggable() } )
$(function() { $( "#dragbtn" ).remove() } )
}
Okay. Ich verstehe es jetzt, aber da kenne ich mich zu wenig aus
Verstehst es glaube nicht ganz, es ist nicht nur html und css, es ist eine android app, die mit SO eine art js, css gemacht sind, aber nicht zu 100%
Ist auch keine Webview
Es ist halt React Native, kanst ja informieren