kieranb662 / partitionkit Goto Github PK
View Code? Open in Web Editor NEWA SwiftUI Library for creating resizable partitions for View Content.
License: MIT License
A SwiftUI Library for creating resizable partitions for View Content.
License: MIT License
Hey,
I love your all packages. Too much to learn from your code.
I was in need to implement something like your package Interact. When I came to this source kieranb662/Interact, I was not able to find it.
Can you update me on this please!
( I found this library while researching this: https://stackoverflow.com/questions/67403140/drag-separators-in-swiftui )
Is there a way to keep the other lines from moving, so that only the line being moved with handle (or the two lines being moved with crosshair) moves?
Also, is there a way to stop handle lines overlapping other areas, so each section has a minimum size (10 pixels square, for example)? So that the Console doesn't spit out this:
PartitionKitExample[34446:1101291] [SwiftUI] Invalid frame dimension (negative or non-finite).
With the advent of Swift Package Manager (SPM) included in XCode 11, it would be amazing to have this code as a package/framework to easily include it in your project.
Description on how to set it up is available here
I'm having problems using your package as version range in Xcode, checking the repo I'm observing that you don't have define any tag on the repo, and XCode use this as version identifier.
I'm asking you to define a version number (0.0.0) to mark the initial release (for development) and permit us to use it in Xcode as Version Range. Thanks
Hey there,
I am playing with the DragGesture in VPart and encountered in undefined behavior of partition layers. For example, when I drag a rectangle from the top partition to the bottom one using offset, it appears beneath the bottom's partition rectangle. I am looking for the way to implement the opposite behavior but as of now I cannot understand what influences it.
here's the example VPart:
@GestureState var isLongPressed = false
@State private var offset: CGSize = .zero
var body: some View {
VPart(top: {
HStack {
Rectangle()
.fill(Color.green)
.cornerRadius(10)
.frame(minWidth: 20, maxWidth: 200, minHeight: 20, maxHeight: 200)
.offset(offset)
.gesture(DragGesture()
.onChanged { self.offset = $0.translation }
.onEnded { _ in self.offset = .zero }
)`
}
}, bottom: {
Rectangle()
.fill(Color.red)
.cornerRadius(10)
.frame(minWidth: 20, maxWidth: 200, minHeight: 20, maxHeight: 200)
})
}
Please think of adding a license so that this can be used by others.
Quoting opensource.org:
Can I call my program "Open Source" even if I don't use an approved license?
Please don't do that. If you call it "Open Source" without using an approved license, you will confuse people. This is not merely a theoretical concern โ we have seen this confusion happen in the past, and it's part of the reason we have a formal license approval process. See also our page on license proliferation for why this is a problem.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.