-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
d2fd817
commit ce8c6f8
Showing
121 changed files
with
3,725 additions
and
1,210 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,4 +9,4 @@ | |
} | ||
}, | ||
"dataconnectEmulatorConfig": {} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
11 changes: 11 additions & 0 deletions
11
BaseStyle/BaseStyle/Resource/BaseAssets.xcassets/AccentColor.colorset/Contents.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
{ | ||
"colors" : [ | ||
{ | ||
"idiom" : "universal" | ||
} | ||
], | ||
"info" : { | ||
"author" : "xcode", | ||
"version" : 1 | ||
} | ||
} |
20 changes: 0 additions & 20 deletions
20
BaseStyle/BaseStyle/Resource/BaseAssets.xcassets/Colors/AccentColor.colorset/Contents.json
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
// | ||
// RestoreButton.swift | ||
// Splito | ||
// | ||
// Created by Nirali Sonani on 24/10/24. | ||
// | ||
|
||
import SwiftUI | ||
|
||
public struct RestoreButton: View { | ||
|
||
let onClick: () -> Void | ||
|
||
public init(onClick: @escaping () -> Void) { | ||
self.onClick = onClick | ||
} | ||
|
||
public var body: some View { | ||
Button(action: onClick) { | ||
Text("Restore") | ||
.font(.subTitle3()) | ||
.foregroundStyle(primaryText) | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,84 @@ | ||
// | ||
// ActivityLog.swift | ||
// Data | ||
// | ||
// Created by Nirali Sonani on 14/10/24. | ||
// | ||
|
||
import FirebaseFirestore | ||
|
||
public struct ActivityLog: Codable, Identifiable, Hashable { | ||
|
||
@DocumentID public var id: String? // Automatically generated ID by Firestore | ||
|
||
/// The type of activity (e.g., group created, expense updated) | ||
public let type: ActivityType | ||
public let groupId: String | ||
|
||
/// The id of the activity (e.g., expense or transaction) | ||
public let activityId: String | ||
public let groupName: String | ||
|
||
/// The name of the user who performed the action | ||
public let actionUserName: String | ||
public let recordedOn: Timestamp | ||
public let previousGroupName: String? | ||
public let removedMemberName: String? | ||
public let expenseName: String? | ||
public let payerName: String? | ||
public let receiverName: String? | ||
public let amount: Double? | ||
|
||
public init(type: ActivityType, groupId: String, activityId: String, groupName: String, actionUserName: String, | ||
recordedOn: Timestamp, previousGroupName: String? = nil, removedMemberName: String? = nil, | ||
expenseName: String? = nil, payerName: String? = nil, receiverName: String? = nil, amount: Double? = nil) { | ||
self.type = type | ||
self.groupId = groupId | ||
self.activityId = activityId | ||
self.groupName = groupName | ||
self.actionUserName = actionUserName | ||
self.recordedOn = recordedOn | ||
self.previousGroupName = previousGroupName | ||
self.removedMemberName = removedMemberName | ||
self.expenseName = expenseName | ||
self.payerName = payerName | ||
self.receiverName = receiverName | ||
self.amount = amount | ||
} | ||
|
||
enum CodingKeys: String, CodingKey { | ||
case id | ||
case type | ||
case groupId = "group_id" | ||
case activityId = "activity_id" | ||
case groupName = "group_name" | ||
case actionUserName = "action_user_name" | ||
case recordedOn = "recorded_on" | ||
case previousGroupName = "previous_group_name" | ||
case removedMemberName = "removed_member_name" | ||
case expenseName = "expense_name" | ||
case payerName = "payer_name" | ||
case receiverName = "receiver_name" | ||
case amount | ||
} | ||
} | ||
|
||
public enum ActivityType: String, Codable { | ||
case none | ||
case groupCreated = "group_created" | ||
case groupUpdated = "group_updated" | ||
case groupDeleted = "group_deleted" | ||
case groupRestored = "group_restored" | ||
case groupNameUpdated = "group_name_updated" | ||
case groupImageUpdated = "group_image_updated" | ||
case groupMemberLeft = "group_member_left" | ||
case groupMemberRemoved = "group_member_removed" | ||
case expenseAdded = "expense_added" | ||
case expenseUpdated = "expense_updated" | ||
case expenseDeleted = "expense_deleted" | ||
case expenseRestored = "expense_restored" | ||
case transactionAdded = "transaction_added" | ||
case transactionUpdated = "transaction_updated" | ||
case transactionDeleted = "transaction_deleted" | ||
case transactionRestored = "transaction_restored" | ||
} |
Oops, something went wrong.