Skip to content
This repository has been archived by the owner on Dec 27, 2020. It is now read-only.

Commit

Permalink
Products (#64)
Browse files Browse the repository at this point in the history
* products

* tests

* badge

* ci
  • Loading branch information
ay42 authored Dec 30, 2019
1 parent c875b98 commit 40bf1ea
Show file tree
Hide file tree
Showing 89 changed files with 49 additions and 45 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/swift.yml → .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: CI
name: ci

on: [push, pull_request]

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import SwiftUI
import SwiftUIExtensions

struct ContentView: View {
var body: some View {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import SwiftUI
import SwiftUIExtensions
import Grid

struct ModularGridView: View {
@State var selection: Int = 0
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import SwiftUI
import SwiftUIExtensions
import Grid

struct StaggeredGridView: View {
var body: some View {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import SwiftUI
import SwiftUIExtensions
import Grid

struct ModularGridView: View {
@State var selection: Int = 0
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import SwiftUI
import SwiftUIExtensions
import Grid

struct StaggeredGridView: View {
var body: some View {
Expand Down
40 changes: 20 additions & 20 deletions Demo/SwiftUIExtensionsDemo.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -17,12 +17,10 @@
FA2C327823A35EA1002DF6F7 /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = FA2C327623A35EA1002DF6F7 /* LaunchScreen.storyboard */; };
FA2C328123A35F58002DF6F7 /* StaggeredGridView.swift in Sources */ = {isa = PBXBuildFile; fileRef = FA2C328023A35F58002DF6F7 /* StaggeredGridView.swift */; };
FA2C328323A35F73002DF6F7 /* ModularGridView.swift in Sources */ = {isa = PBXBuildFile; fileRef = FA2C328223A35F73002DF6F7 /* ModularGridView.swift */; };
FA2C328523A35FD2002DF6F7 /* SwiftUIExtensions in Frameworks */ = {isa = PBXBuildFile; productRef = FA2C328423A35FD2002DF6F7 /* SwiftUIExtensions */; };
FA2C328623A35FE6002DF6F7 /* Color+Random.swift in Sources */ = {isa = PBXBuildFile; fileRef = FA37C458239DE7330037BFE3 /* Color+Random.swift */; };
FA2C328723A35FE6002DF6F7 /* Item.swift in Sources */ = {isa = PBXBuildFile; fileRef = FA37C459239DE7330037BFE3 /* Item.swift */; };
FA2C328823A35FE6002DF6F7 /* Card.swift in Sources */ = {isa = PBXBuildFile; fileRef = FA37C45B239DE7330037BFE3 /* Card.swift */; };
FA2C328923A35FE6002DF6F7 /* SharedAssets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = FA37C45A239DE7330037BFE3 /* SharedAssets.xcassets */; };
FA2C328C23A36DB5002DF6F7 /* SwiftUIExtensions in Frameworks */ = {isa = PBXBuildFile; productRef = FA2C328B23A36DB5002DF6F7 /* SwiftUIExtensions */; };
FA2C329123A3704B002DF6F7 /* PatternsView.swift in Sources */ = {isa = PBXBuildFile; fileRef = FA2C328E23A3704B002DF6F7 /* PatternsView.swift */; };
FA2C329223A3704B002DF6F7 /* RegularPolygonsView.swift in Sources */ = {isa = PBXBuildFile; fileRef = FA2C328F23A3704B002DF6F7 /* RegularPolygonsView.swift */; };
FA2C329323A3704B002DF6F7 /* LinesView.swift in Sources */ = {isa = PBXBuildFile; fileRef = FA2C329023A3704B002DF6F7 /* LinesView.swift */; };
Expand Down Expand Up @@ -59,6 +57,9 @@
FA37C485239DEB2C0037BFE3 /* Item.swift in Sources */ = {isa = PBXBuildFile; fileRef = FA37C459239DE7330037BFE3 /* Item.swift */; };
FA37C486239DEB2C0037BFE3 /* Card.swift in Sources */ = {isa = PBXBuildFile; fileRef = FA37C45B239DE7330037BFE3 /* Card.swift */; };
FA37C487239DEB2C0037BFE3 /* SharedAssets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = FA37C45A239DE7330037BFE3 /* SharedAssets.xcassets */; };
FA4AB23423B96F61007B0422 /* SwiftUIExtensions in Frameworks */ = {isa = PBXBuildFile; productRef = FA4AB23323B96F61007B0422 /* SwiftUIExtensions */; };
FA90447823B975620090B6DA /* Grid in Frameworks */ = {isa = PBXBuildFile; productRef = FA90447723B975620090B6DA /* Grid */; };
FA90447A23B975CA0090B6DA /* Grid in Frameworks */ = {isa = PBXBuildFile; productRef = FA90447923B975CA0090B6DA /* Grid */; };
FAB94A0823A37B7500EBEB8C /* ChartsView.swift in Sources */ = {isa = PBXBuildFile; fileRef = FAB94A0723A37B7500EBEB8C /* ChartsView.swift */; };
FAB94A1323A384BA00EBEB8C /* HalfCapsule.swift in Sources */ = {isa = PBXBuildFile; fileRef = FAB94A1123A384B900EBEB8C /* HalfCapsule.swift */; };
FAB94A1423A384BA00EBEB8C /* HalfCapsule.swift in Sources */ = {isa = PBXBuildFile; fileRef = FAB94A1123A384B900EBEB8C /* HalfCapsule.swift */; };
Expand All @@ -78,7 +79,6 @@
FAD4B57323A35A2800308E28 /* NotificationView.swift in Sources */ = {isa = PBXBuildFile; fileRef = FAD4B57223A35A2800308E28 /* NotificationView.swift */; };
FAD4B57523A35A2900308E28 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = FAD4B57423A35A2900308E28 /* Assets.xcassets */; };
FAD4B57823A35A2900308E28 /* Preview Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = FAD4B57723A35A2900308E28 /* Preview Assets.xcassets */; };
FAD4B58723A35BCA00308E28 /* SwiftUIExtensions in Frameworks */ = {isa = PBXBuildFile; productRef = FAD4B58623A35BCA00308E28 /* SwiftUIExtensions */; };
FAD4B58C23A35C8300308E28 /* ModularGridView.swift in Sources */ = {isa = PBXBuildFile; fileRef = FAD4B58B23A35C8300308E28 /* ModularGridView.swift */; };
FAD4B58E23A35C9500308E28 /* StaggeredGridView.swift in Sources */ = {isa = PBXBuildFile; fileRef = FAD4B58D23A35C9500308E28 /* StaggeredGridView.swift */; };
FAD4B58F23A35CC400308E28 /* Color+Random.swift in Sources */ = {isa = PBXBuildFile; fileRef = FA37C458239DE7330037BFE3 /* Color+Random.swift */; };
Expand Down Expand Up @@ -208,15 +208,15 @@
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
FA2C328523A35FD2002DF6F7 /* SwiftUIExtensions in Frameworks */,
FA90447A23B975CA0090B6DA /* Grid in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
FA37C430239DE2560037BFE3 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
FA2C328C23A36DB5002DF6F7 /* SwiftUIExtensions in Frameworks */,
FA4AB23423B96F61007B0422 /* SwiftUIExtensions in Frameworks */,
FA37C455239DE6B60037BFE3 /* SwiftUIExtensions in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
Expand All @@ -233,7 +233,7 @@
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
FAD4B58723A35BCA00308E28 /* SwiftUIExtensions in Frameworks */,
FA90447823B975620090B6DA /* Grid in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
Expand Down Expand Up @@ -590,7 +590,7 @@
);
name = "SwiftUIExtensionsDemo tvOS";
packageProductDependencies = (
FA2C328423A35FD2002DF6F7 /* SwiftUIExtensions */,
FA90447923B975CA0090B6DA /* Grid */,
);
productName = "SwiftUIExtensionsDemo tvOS";
productReference = FA2C326B23A35EA0002DF6F7 /* SwiftUIExtensionsDemo tvOS.app */;
Expand All @@ -611,7 +611,7 @@
name = "SwiftUIExtensionsDemo iOS";
packageProductDependencies = (
FA37C454239DE6B60037BFE3 /* SwiftUIExtensions */,
FA2C328B23A36DB5002DF6F7 /* SwiftUIExtensions */,
FA4AB23323B96F61007B0422 /* SwiftUIExtensions */,
);
productName = "SwiftUIExtensionsDemo iOS";
productReference = FA37C433239DE2560037BFE3 /* SwiftUIExtensionsDemo iOS.app */;
Expand Down Expand Up @@ -685,7 +685,7 @@
);
name = "SwiftUIExtensionsDemo WatchKit Extension";
packageProductDependencies = (
FAD4B58623A35BCA00308E28 /* SwiftUIExtensions */,
FA90447723B975620090B6DA /* Grid */,
);
productName = "SwiftUIExtensionsDemo WatchKit Extension";
productReference = FAD4B56523A35A2800308E28 /* SwiftUIExtensionsDemo WatchKit Extension.appex */;
Expand Down Expand Up @@ -730,7 +730,7 @@
);
mainGroup = FA800E28239DE09A005D2211;
packageReferences = (
FA2C328A23A36DB5002DF6F7 /* XCRemoteSwiftPackageReference "SwiftUIExtensions" */,
FA4AB23223B96F61007B0422 /* XCRemoteSwiftPackageReference "swiftui-extensions" */,
);
productRefGroup = FA37C434239DE2560037BFE3 /* Products */;
projectDirPath = "";
Expand Down Expand Up @@ -1710,9 +1710,9 @@
/* End XCConfigurationList section */

/* Begin XCRemoteSwiftPackageReference section */
FA2C328A23A36DB5002DF6F7 /* XCRemoteSwiftPackageReference "SwiftUIExtensions" */ = {
FA4AB23223B96F61007B0422 /* XCRemoteSwiftPackageReference "swiftui-extensions" */ = {
isa = XCRemoteSwiftPackageReference;
repositoryURL = "[email protected]:SwiftExtensions/SwiftUIExtensions.git";
repositoryURL = "[email protected]:swift-extensions/swiftui-extensions.git";
requirement = {
branch = master;
kind = branch;
Expand All @@ -1721,26 +1721,26 @@
/* End XCRemoteSwiftPackageReference section */

/* Begin XCSwiftPackageProductDependency section */
FA2C328423A35FD2002DF6F7 /* SwiftUIExtensions */ = {
FA37C454239DE6B60037BFE3 /* SwiftUIExtensions */ = {
isa = XCSwiftPackageProductDependency;
productName = SwiftUIExtensions;
};
FA2C328B23A36DB5002DF6F7 /* SwiftUIExtensions */ = {
FA37C477239DE9A50037BFE3 /* SwiftUIExtensions */ = {
isa = XCSwiftPackageProductDependency;
package = FA2C328A23A36DB5002DF6F7 /* XCRemoteSwiftPackageReference "SwiftUIExtensions" */;
productName = SwiftUIExtensions;
};
FA37C454239DE6B60037BFE3 /* SwiftUIExtensions */ = {
FA4AB23323B96F61007B0422 /* SwiftUIExtensions */ = {
isa = XCSwiftPackageProductDependency;
package = FA4AB23223B96F61007B0422 /* XCRemoteSwiftPackageReference "swiftui-extensions" */;
productName = SwiftUIExtensions;
};
FA37C477239DE9A50037BFE3 /* SwiftUIExtensions */ = {
FA90447723B975620090B6DA /* Grid */ = {
isa = XCSwiftPackageProductDependency;
productName = SwiftUIExtensions;
productName = Grid;
};
FAD4B58623A35BCA00308E28 /* SwiftUIExtensions */ = {
FA90447923B975CA0090B6DA /* Grid */ = {
isa = XCSwiftPackageProductDependency;
productName = SwiftUIExtensions;
productName = Grid;
};
/* End XCSwiftPackageProductDependency section */
};
Expand Down
25 changes: 12 additions & 13 deletions Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -4,24 +4,23 @@
import PackageDescription

let package = Package(
name: "SwiftUIExtensions",
name: "swiftui-extensions",
platforms: [
.iOS(.v13), .macOS(.v10_15), .watchOS(.v6), .tvOS(.v13)
],
products: [
.library(
name: "SwiftUIExtensions",
targets: ["SwiftUIExtensions"]),
.library(name: "SwiftUIExtensions", targets: ["SwiftUIExtensions"]),
.library(name: "Grid", targets: ["Grid"]),
.library(name: "Sliders", targets: ["Sliders"]),
.library(name: "Shapes", targets: ["Shapes"]),
.library(name: "Chart", targets: ["Chart"]),
],
targets: [
.target(
name: "SwiftUIExtensions",
dependencies: [],
exclude: ["Demo", "Resources"]
),
.testTarget(
name: "SwiftUIExtensionsTests",
dependencies: ["SwiftUIExtensions"]
)
.target(name: "SwiftUIExtensions", dependencies: ["Grid", "Sliders", "Shapes", "Chart"]),
.target(name: "Grid", dependencies: []),
.target(name: "Sliders", dependencies: []),
.target(name: "Shapes", dependencies: []),
.target(name: "Chart", dependencies: ["Shapes"]),
.testTarget(name: "SwiftUIExtensionsTests", dependencies: ["SwiftUIExtensions"])
]
)
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# SwiftUI Extensions
Collection of useful SwiftUI extensions and elements

[![Build Status](https://github.com/SwiftExtensions/SwiftUIExtensions/workflows/CI/badge.svg)](https://github.com/SwiftExtensions/SwiftUIExtensions/actions)
[![Build Status](https://github.com/swift-extensions/swiftui-extensions/workflows/ci/badge.svg)](https://github.com/swift-extensions/swiftui-extensions/actions)

- Grid based layouts
- Sliders (horizontal, vertical, point)
Expand All @@ -13,7 +13,7 @@ Collection of useful SwiftUI extensions and elements

Open `/Demo/SwiftUIExtensionsDemo.xcodeproj` for more examples for iOS, macOS, watchOS and tvOS

## Layouts
## Grid

### Modular Grid
<center>
Expand Down Expand Up @@ -198,7 +198,7 @@ XYSlider(x: $x, y: $y,
.padding()
```

## Data Visualization
## Chart

Build custom charts with SwiftUI

Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import SwiftUI
import Shapes

public struct LineChartStyle: ChartStyle {
private let lineType: LineType
Expand Down
File renamed without changes.
5 changes: 5 additions & 0 deletions Sources/SwiftUIExtensions/SwiftUIExtensions.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
@_exported import SwiftUI
@_exported import Grid
@_exported import Sliders
@_exported import Shapes
@_exported import Chart
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@testable import SwiftUIExtensions
@testable import Sliders
import XCTest

class DistanceFromValueTests: XCTestCase {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@testable import SwiftUIExtensions
@testable import Sliders
import XCTest

class RangeDistanceTests: XCTestCase {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
@testable import SwiftUIExtensions
@testable import Sliders
import XCTest

class ValueFromDistanceTests: XCTestCase {
Expand Down

0 comments on commit 40bf1ea

Please sign in to comment.