liquid
Bugfix Patch
用Liquid()創建一個微妙而有趣的後擋板。嘗試在藝術品,按鈕,甚至用自己的形狀後面嘗試液體。只需在您的視圖中添加Liquid()即可開始!
文件> swift軟件包>添加軟件包依賴關係:https://github.com/maustinstar/liquid
在您的Package.swift中添加依賴性。
. package ( url : " https://github.com/maustinstar/liquid.git " , from : " 0.0.1 " ) , 只需進口液體,然後將其添加到您的視圖中以開始。
struct ContentView : View {
var body : some View {
Liquid ( ) . frame ( width : 200 , height : 200 )
}
}請參閱完整的參考指南。
struct ContentView : View {
var body : some View {
ZStack {
Liquid ( )
. frame ( width : 240 , height : 240 )
. foregroundColor ( . blue )
. opacity ( 0.3 )
Liquid ( )
. frame ( width : 220 , height : 220 )
. foregroundColor ( . blue )
. opacity ( 0.6 )
Liquid ( samples : 5 )
. frame ( width : 200 , height : 200 )
. foregroundColor ( . blue )
Text ( " Liquid " ) . font ( . largeTitle ) . foregroundColor ( . white )
}
}
}查看更多示例。
要開始,請閱讀完整的實施指南。
參見貢獻。
使用這些軟件包將您的SwiftUi應用程序提升到一個新的水平!