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

GN-586 Rename import class to TalkShopLive #8

Draft
wants to merge 1 commit into
base: development
Choose a base branch
from
Draft
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
25 changes: 9 additions & 16 deletions TSL SDK.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,7 @@
objects = {

/* Begin PBXBuildFile section */
67A471922B79913200992992 /* Talkshoplive in Frameworks */ = {isa = PBXBuildFile; productRef = 67A471912B79913200992992 /* Talkshoplive */; };
67A471952B79950100992992 /* Talkshoplive in Frameworks */ = {isa = PBXBuildFile; productRef = 67A471942B79950100992992 /* Talkshoplive */; };
6718BDCB2B7EB86E00F841A3 /* TalkShopLive in Frameworks */ = {isa = PBXBuildFile; productRef = 6718BDCA2B7EB86E00F841A3 /* TalkShopLive */; };
D17DA7762B5F10FD00ED9BBF /* TSL_SDKApp.swift in Sources */ = {isa = PBXBuildFile; fileRef = D17DA7752B5F10FD00ED9BBF /* TSL_SDKApp.swift */; };
D17DA7782B5F10FD00ED9BBF /* ContentView.swift in Sources */ = {isa = PBXBuildFile; fileRef = D17DA7772B5F10FD00ED9BBF /* ContentView.swift */; };
D17DA77A2B5F10FE00ED9BBF /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = D17DA7792B5F10FE00ED9BBF /* Assets.xcassets */; };
Expand Down Expand Up @@ -53,8 +52,7 @@
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
67A471952B79950100992992 /* Talkshoplive in Frameworks */,
67A471922B79913200992992 /* Talkshoplive in Frameworks */,
6718BDCB2B7EB86E00F841A3 /* TalkShopLive in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
};
Expand Down Expand Up @@ -156,8 +154,7 @@
);
name = "TSL SDK";
packageProductDependencies = (
67A471912B79913200992992 /* Talkshoplive */,
67A471942B79950100992992 /* Talkshoplive */,
6718BDCA2B7EB86E00F841A3 /* TalkShopLive */,
);
productName = "TSL SDK";
productReference = D17DA7722B5F10FD00ED9BBF /* TSL SDK.app */;
Expand Down Expand Up @@ -232,7 +229,7 @@
);
mainGroup = D17DA7692B5F10FD00ED9BBF;
packageReferences = (
67A471932B79950100992992 /* XCRemoteSwiftPackageReference "ios-sdk" */,
6718BDC92B7EB86E00F841A3 /* XCRemoteSwiftPackageReference "ios-sdk" */,
);
productRefGroup = D17DA7732B5F10FD00ED9BBF /* Products */;
projectDirPath = "";
Expand Down Expand Up @@ -627,25 +624,21 @@
/* End XCConfigurationList section */

/* Begin XCRemoteSwiftPackageReference section */
67A471932B79950100992992 /* XCRemoteSwiftPackageReference "ios-sdk" */ = {
6718BDC92B7EB86E00F841A3 /* XCRemoteSwiftPackageReference "ios-sdk" */ = {
isa = XCRemoteSwiftPackageReference;
repositoryURL = "https://github.com/TalkShopLive/ios-sdk";
requirement = {
kind = revision;
revision = 4d721b4219d8fa4910da3d044888d8afa8648421;
revision = c98c973cba36d8d4895d0575331ecfdaa8b1b16d;
};
};
/* End XCRemoteSwiftPackageReference section */

/* Begin XCSwiftPackageProductDependency section */
67A471912B79913200992992 /* Talkshoplive */ = {
6718BDCA2B7EB86E00F841A3 /* TalkShopLive */ = {
isa = XCSwiftPackageProductDependency;
productName = Talkshoplive;
};
67A471942B79950100992992 /* Talkshoplive */ = {
isa = XCSwiftPackageProductDependency;
package = 67A471932B79950100992992 /* XCRemoteSwiftPackageReference "ios-sdk" */;
productName = Talkshoplive;
package = 6718BDC92B7EB86E00F841A3 /* XCRemoteSwiftPackageReference "ios-sdk" */;
productName = TalkShopLive;
};
/* End XCSwiftPackageProductDependency section */
};
Expand Down
12 changes: 5 additions & 7 deletions TSL SDK/ContentView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,14 @@
// Created by Daman Mehta on 2024-01-22.
//
import SwiftUI
import Talkshoplive
import TalkShopLive

struct ContentView: View {
@State private var showInput: String = ""
@State private var showResult: String = ""
@State private var eventResult: String = ""
@State private var eventInput: String = ""
@State private var showObject : Talkshoplive.ShowData? = nil
@State private var showObject : TalkShopLive.ShowData? = nil

var showID = "vzzg6tNu0qOv"
var eventID = "8WtAFFgRO1K0"
Expand Down Expand Up @@ -62,8 +62,6 @@ struct ContentView: View {
.background(Color.blue)
.cornerRadius(8)



Text(showResult)
.padding()
}
Expand All @@ -73,14 +71,14 @@ struct ContentView: View {

func initializeSDK() {
// Replace the API URL with your actual API endpoint
let TSL = Talkshoplive.TalkShopLive(clientKey: "0GmN76SBDdHRsGLRDcmVzpURj",debugMode: true,testMode: true)
let TSL = TalkShopLive.Authenticate(clientKey: "0GmN76SBDdHRsGLRDcmVzpURj",debugMode: true,testMode: true)
print(TSL)
}

func fetchShowData() {
// Replace the API URL with your actual API endpoint
self.showResult = showInput
let showInstance = Talkshoplive.Show()
let showInstance = TalkShopLive.Show()
showInstance.getDetails(showId: self.showID) { result in
switch result {
case .success(let show):
Expand All @@ -98,7 +96,7 @@ struct ContentView: View {
// Replace the API URL with your actual API endpoint
self.showResult = eventInput
self.showInput = eventID
let showInstance = Talkshoplive.Show()
let showInstance = TalkShopLive.Show()
let showId = eventID
showInstance.getStatus(showId: showId) { result in
switch result {
Expand Down