Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Break out DesignKit into its own sub-package #459

Merged
merged 2 commits into from
Jan 17, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,7 @@ xcuserdata/
/Packages
xcuserdata/
DerivedData/
.swiftpm/config/registries.json
.swiftpm/xcode/package.xcworkspace/contents.xcworkspacedata
.swiftpm
.netrc

# fastlane
Expand Down
23 changes: 23 additions & 0 deletions DesignKit/Package.resolved
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"pins" : [
{
"identity" : "element-design-tokens",
"kind" : "remoteSourceControl",
"location" : "https://github.com/vector-im/element-design-tokens.git",
"state" : {
"revision" : "63e40f10b336c136d6d05f7967e4565e37d3d760",
"version" : "0.0.3"
}
},
{
"identity" : "swiftui-introspect",
"kind" : "remoteSourceControl",
"location" : "https://github.com/siteline/SwiftUI-Introspect.git",
"state" : {
"revision" : "f2616860a41f9d9932da412a8978fec79c06fe24",
"version" : "0.1.4"
}
}
],
"version" : 2
}
29 changes: 29 additions & 0 deletions DesignKit/Package.swift
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
// swift-tools-version: 5.7
// The swift-tools-version declares the minimum version of Swift required to build this package.

import PackageDescription

let package = Package(
name: "DesignKit",
platforms: [
.iOS(.v14)
],
products: [
.library(name: "DesignKit", targets: ["DesignKit"])
],
dependencies: [
.package(url: "https://github.com/vector-im/element-design-tokens.git", exact: "0.0.3"),
.package(url: "https://github.com/siteline/SwiftUI-Introspect.git", from: "0.1.4")
],
targets: [
.target(name: "DesignKit",
dependencies: [
.product(name: "DesignTokens", package: "element-design-tokens"),
.product(name: "Introspect", package: "SwiftUI-Introspect")
],
path: "Sources"),
.testTarget(name: "DesignKitTests",
dependencies: ["DesignKit"],
path: "Tests")
]
)
12 changes: 2 additions & 10 deletions ElementX.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -680,6 +680,7 @@
47111410B6E659A697D472B5 /* RoomProxyProtocol.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = RoomProxyProtocol.swift; sourceTree = "<group>"; };
471EB7D96AFEA8D787659686 /* EmoteRoomTimelineView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = EmoteRoomTimelineView.swift; sourceTree = "<group>"; };
475EB595D7527E9A8A14043E /* uz */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = uz; path = uz.lproj/Localizable.strings; sourceTree = "<group>"; };
478BE8591BD13E908EF70C0C /* DesignKit */ = {isa = PBXFileReference; lastKnownFileType = folder; name = DesignKit; path = DesignKit; sourceTree = SOURCE_ROOT; };
4798B3B7A1E8AE3901CEE8C6 /* FramePreferenceKey.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FramePreferenceKey.swift; sourceTree = "<group>"; };
47EBB5D698CE9A25BB553A2D /* Strings.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Strings.swift; sourceTree = "<group>"; };
48CE6BF18E542B32FA52CE06 /* fa */ = {isa = PBXFileReference; lastKnownFileType = text.plist.stringsdict; name = fa; path = fa.lproj/Localizable.stringsdict; sourceTree = "<group>"; };
Expand Down Expand Up @@ -964,7 +965,6 @@
D0A45283CF1DB96E583BECA6 /* ImageRoomTimelineView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ImageRoomTimelineView.swift; sourceTree = "<group>"; };
D1A9CCCF53495CF3D7B19FCE /* MockSessionVerificationControllerProxy.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MockSessionVerificationControllerProxy.swift; sourceTree = "<group>"; };
D263254AFE5B7993FFBBF324 /* NSE.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = NSE.entitlements; sourceTree = "<group>"; };
D31DC8105C6233E5FFD9B84C /* element-x-ios */ = {isa = PBXFileReference; lastKnownFileType = folder; name = "element-x-ios"; path = .; sourceTree = SOURCE_ROOT; };
D33116993D54FADC0C721C1F /* Application.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Application.swift; sourceTree = "<group>"; };
D3D455BC2423D911A62ACFB2 /* NSELogger.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = NSELogger.swift; sourceTree = "<group>"; };
D4DA544B2520BFA65D6DB4BB /* target.yml */ = {isa = PBXFileReference; lastKnownFileType = text.yaml; path = target.yml; sourceTree = "<group>"; };
Expand Down Expand Up @@ -1242,13 +1242,6 @@
path = Resources;
sourceTree = "<group>";
};
285079C24A5189C48284CC47 /* VideoPlayer */ = {
isa = PBXGroup;
children = (
);
path = VideoPlayer;
sourceTree = "<group>";
};
2D6DC9871FD7173E51D67C73 /* Cache */ = {
isa = PBXGroup;
children = (
Expand Down Expand Up @@ -1965,7 +1958,7 @@
9413F680ECDFB2B0DDB0DEF2 /* Packages */ = {
isa = PBXGroup;
children = (
D31DC8105C6233E5FFD9B84C /* element-x-ios */,
478BE8591BD13E908EF70C0C /* DesignKit */,
);
name = Packages;
sourceTree = SOURCE_ROOT;
Expand Down Expand Up @@ -2362,7 +2355,6 @@
679E9837ECA8D6776079D16E /* RoomScreen */,
D958761758AA1110476DE6A3 /* SessionVerification */,
70B74A432C241E56A7ACE610 /* Settings */,
285079C24A5189C48284CC47 /* VideoPlayer */,
);
path = Screens;
sourceTree = "<group>";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -108,15 +108,6 @@
"version" : "7.30.2"
}
},
{
"identity" : "swift-argument-parser",
"kind" : "remoteSourceControl",
"location" : "https://github.com/apple/swift-argument-parser",
"state" : {
"revision" : "fddd1c00396eed152c45a46bea9f47b98e59301d",
"version" : "1.2.0"
}
},
{
"identity" : "swift-snapshot-testing",
"kind" : "remoteSourceControl",
Expand Down Expand Up @@ -152,15 +143,6 @@
"revision" : "12b5acf96d98f91d50de447369bd18df74600f1a",
"version" : "1.9.6"
}
},
{
"identity" : "yams",
"kind" : "remoteSourceControl",
"location" : "https://github.com/jpsim/Yams",
"state" : {
"revision" : "01835dc202670b5bb90d07f3eae41867e9ed29f6",
"version" : "5.0.1"
}
}
],
"version" : 2
Expand Down
18 changes: 0 additions & 18 deletions Package.resolved
Original file line number Diff line number Diff line change
@@ -1,14 +1,5 @@
{
"pins" : [
{
"identity" : "element-design-tokens",
"kind" : "remoteSourceControl",
"location" : "https://github.com/vector-im/element-design-tokens.git",
"state" : {
"revision" : "63e40f10b336c136d6d05f7967e4565e37d3d760",
"version" : "0.0.3"
}
},
{
"identity" : "swift-argument-parser",
"kind" : "remoteSourceControl",
Expand All @@ -18,15 +9,6 @@
"version" : "1.2.0"
}
},
{
"identity" : "swiftui-introspect",
"kind" : "remoteSourceControl",
"location" : "https://github.com/siteline/SwiftUI-Introspect.git",
"state" : {
"revision" : "f2616860a41f9d9932da412a8978fec79c06fe24",
"version" : "0.1.4"
}
},
{
"identity" : "yams",
"kind" : "remoteSourceControl",
Expand Down
14 changes: 0 additions & 14 deletions Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -6,30 +6,16 @@ import PackageDescription
let package = Package(
name: "Element Swift",
platforms: [
.iOS(.v14),
.macOS(.v13)
],
products: [
.library(name: "DesignKit", targets: ["DesignKit"]),
.executable(name: "tools", targets: ["Tools"])
],
dependencies: [
.package(url: "https://github.com/vector-im/element-design-tokens.git", exact: "0.0.3"),
.package(url: "https://github.com/siteline/SwiftUI-Introspect.git", from: "0.1.4"),
/* Command line tools dependencies */
.package(url: "https://github.com/apple/swift-argument-parser", from: "1.2.0"),
.package(url: "https://github.com/jpsim/Yams", from: "5.0.1")
],
targets: [
.target(name: "DesignKit",
dependencies: [
.product(name: "DesignTokens", package: "element-design-tokens"),
.product(name: "Introspect", package: "SwiftUI-Introspect")
],
path: "DesignKit"),
.testTarget(name: "DesignKitTests",
dependencies: ["DesignKit"],
path: "DesignKitTests"),
.executableTarget(name: "Tools",
dependencies: [
.product(name: "ArgumentParser", package: "swift-argument-parser"),
Expand Down
1 change: 1 addition & 0 deletions changelog.d/pr-459.build
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
DesignKit: Move into a sub-package as long term this package will live outside of this repo.
2 changes: 1 addition & 1 deletion project.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ packages:
exactVersion: 1.0.30-alpha
# path: ../matrix-rust-sdk
DesignKit:
path: ./
path: DesignKit
AnalyticsEvents:
url: https://github.com/matrix-org/matrix-analytics-events
branch: main
Expand Down