mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-02-24 09:52:49 +08:00
fix(ios): add AI privacy consent alert (#14421)
<!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit ## Release Notes * **New Features** * Added AI feature consent flow requiring user agreement before enabling AI capabilities. * Added calendar integration support including CalDAV account linking and management. * Expanded workspace administration capabilities with detailed workspace analytics and configuration options. * **Improvements** * Enhanced workspace sharing and configuration controls. * Added support for calendar provider presets and subscriptions. <!-- end of auto-generated comment: release notes by coderabbit.ai -->
This commit is contained in:
@@ -18,6 +18,15 @@
|
||||
"version" : "0.1.5"
|
||||
}
|
||||
},
|
||||
{
|
||||
"identity" : "highlightr",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/raspu/Highlightr",
|
||||
"state" : {
|
||||
"revision" : "05e7fcc63b33925cd0c1faaa205cdd5681e7bbef",
|
||||
"version" : "2.3.0"
|
||||
}
|
||||
},
|
||||
{
|
||||
"identity" : "listviewkit",
|
||||
"kind" : "remoteSourceControl",
|
||||
@@ -27,13 +36,22 @@
|
||||
"version" : "1.1.8"
|
||||
}
|
||||
},
|
||||
{
|
||||
"identity" : "litext",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/Lakr233/Litext",
|
||||
"state" : {
|
||||
"revision" : "c7e83f2f580ce34a102ca9ba9d2bb24e507dccd9",
|
||||
"version" : "0.5.6"
|
||||
}
|
||||
},
|
||||
{
|
||||
"identity" : "lrucache",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/nicklockwood/LRUCache",
|
||||
"state" : {
|
||||
"revision" : "542f0449556327415409ededc9c43a4bd0a397dc",
|
||||
"version" : "1.0.7"
|
||||
"revision" : "cb5b2bd0da83ad29c0bec762d39f41c8ad0eaf3e",
|
||||
"version" : "1.2.1"
|
||||
}
|
||||
},
|
||||
{
|
||||
@@ -41,8 +59,8 @@
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/Lakr233/MarkdownView",
|
||||
"state" : {
|
||||
"revision" : "20fa808889944921e8da3a1c8317e8a557db373e",
|
||||
"version" : "3.4.7"
|
||||
"revision" : "8b8c1eecd251051c5ec2bdd5f31a2243efd9be6c",
|
||||
"version" : "3.6.2"
|
||||
}
|
||||
},
|
||||
{
|
||||
@@ -59,8 +77,8 @@
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/RevenueCat/purchases-ios-spm.git",
|
||||
"state" : {
|
||||
"revision" : "6676da5c4c6a61e53b3139216a775d1224bf056e",
|
||||
"version" : "5.56.1"
|
||||
"revision" : "8f5df97653eb361a2097119479332afccf0aa816",
|
||||
"version" : "5.58.0"
|
||||
}
|
||||
},
|
||||
{
|
||||
@@ -72,15 +90,6 @@
|
||||
"version" : "5.7.1"
|
||||
}
|
||||
},
|
||||
{
|
||||
"identity" : "splash",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/Lakr233/Splash",
|
||||
"state" : {
|
||||
"revision" : "de9cde249fdb7a173a6e6b950ab18b11f6c2a557",
|
||||
"version" : "0.18.0"
|
||||
}
|
||||
},
|
||||
{
|
||||
"identity" : "springinterpolation",
|
||||
"kind" : "remoteSourceControl",
|
||||
@@ -95,8 +104,8 @@
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/swiftlang/swift-cmark",
|
||||
"state" : {
|
||||
"revision" : "b022b08312decdc46585e0b3440d97f6f22ef703",
|
||||
"version" : "0.6.0"
|
||||
"revision" : "5d9bdaa4228b381639fff09403e39a04926e2dbe",
|
||||
"version" : "0.7.1"
|
||||
}
|
||||
},
|
||||
{
|
||||
@@ -120,10 +129,10 @@
|
||||
{
|
||||
"identity" : "swiftmath",
|
||||
"kind" : "remoteSourceControl",
|
||||
"location" : "https://github.com/Lakr233/SwiftMath",
|
||||
"location" : "https://github.com/mgriebling/SwiftMath",
|
||||
"state" : {
|
||||
"revision" : "cfd646dcac0c5553e21ebf1ee05f9078277518bc",
|
||||
"version" : "1.7.2"
|
||||
"revision" : "fa8244ed032f4a1ade4cb0571bf87d2f1a9fd2d7",
|
||||
"version" : "1.7.3"
|
||||
}
|
||||
}
|
||||
],
|
||||
|
||||
@@ -9,9 +9,36 @@ import Intelligents
|
||||
import UIKit
|
||||
|
||||
extension AFFiNEViewController: IntelligentsButtonDelegate {
|
||||
private static let aiConsentKey = "com.affine.intelligents.userConsented"
|
||||
|
||||
private var hasUserConsented: Bool {
|
||||
UserDefaults.standard.bool(forKey: Self.aiConsentKey)
|
||||
}
|
||||
|
||||
func onIntelligentsButtonTapped(_: IntelligentsButton) {
|
||||
// if it shows up then we are ready to go
|
||||
if hasUserConsented {
|
||||
presentIntelligentsController()
|
||||
return
|
||||
}
|
||||
showAIConsentAlert()
|
||||
}
|
||||
|
||||
private func presentIntelligentsController() {
|
||||
let controller = IntelligentsController()
|
||||
present(controller, animated: true)
|
||||
}
|
||||
|
||||
private func showAIConsentAlert() {
|
||||
let alert = UIAlertController(
|
||||
title: "AI Feature Data Usage",
|
||||
message: "To provide AI-powered features, your input (such as document content and conversation messages) will be sent to a third-party AI service for processing. This data is used solely to generate responses and is not used for any other purpose.\n\nBy continuing, you agree to share this data with the AI service.",
|
||||
preferredStyle: .alert
|
||||
)
|
||||
alert.addAction(UIAlertAction(title: "Cancel", style: .cancel))
|
||||
alert.addAction(UIAlertAction(title: "Agree & Continue", style: .default) { [weak self] _ in
|
||||
UserDefaults.standard.set(true, forKey: Self.aiConsentKey)
|
||||
self?.presentIntelligentsController()
|
||||
})
|
||||
present(alert, animated: true)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,170 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public struct CurrentUserProfile: AffineGraphQL.SelectionSet, Fragment {
|
||||
public static var fragmentDefinition: StaticString {
|
||||
#"fragment CurrentUserProfile on UserType { __typename id name email avatarUrl emailVerified features settings { __typename receiveInvitationEmail receiveMentionEmail receiveCommentEmail } quota { __typename name blobLimit storageQuota historyPeriod memberLimit humanReadable { __typename name blobLimit storageQuota historyPeriod memberLimit } } quotaUsage { __typename storageQuota } copilot { __typename quota { __typename limit used } } }"#
|
||||
}
|
||||
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.UserType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("id", AffineGraphQL.ID.self),
|
||||
.field("name", String.self),
|
||||
.field("email", String.self),
|
||||
.field("avatarUrl", String?.self),
|
||||
.field("emailVerified", Bool.self),
|
||||
.field("features", [GraphQLEnum<AffineGraphQL.FeatureType>].self),
|
||||
.field("settings", Settings.self),
|
||||
.field("quota", Quota.self),
|
||||
.field("quotaUsage", QuotaUsage.self),
|
||||
.field("copilot", Copilot.self),
|
||||
] }
|
||||
|
||||
public var id: AffineGraphQL.ID { __data["id"] }
|
||||
/// User name
|
||||
public var name: String { __data["name"] }
|
||||
/// User email
|
||||
public var email: String { __data["email"] }
|
||||
/// User avatar url
|
||||
public var avatarUrl: String? { __data["avatarUrl"] }
|
||||
/// User email verified
|
||||
public var emailVerified: Bool { __data["emailVerified"] }
|
||||
/// Enabled features of a user
|
||||
public var features: [GraphQLEnum<AffineGraphQL.FeatureType>] { __data["features"] }
|
||||
/// Get user settings
|
||||
public var settings: Settings { __data["settings"] }
|
||||
public var quota: Quota { __data["quota"] }
|
||||
public var quotaUsage: QuotaUsage { __data["quotaUsage"] }
|
||||
public var copilot: Copilot { __data["copilot"] }
|
||||
|
||||
/// Settings
|
||||
///
|
||||
/// Parent Type: `UserSettingsType`
|
||||
public struct Settings: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.UserSettingsType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("receiveInvitationEmail", Bool.self),
|
||||
.field("receiveMentionEmail", Bool.self),
|
||||
.field("receiveCommentEmail", Bool.self),
|
||||
] }
|
||||
|
||||
/// Receive invitation email
|
||||
public var receiveInvitationEmail: Bool { __data["receiveInvitationEmail"] }
|
||||
/// Receive mention email
|
||||
public var receiveMentionEmail: Bool { __data["receiveMentionEmail"] }
|
||||
/// Receive comment email
|
||||
public var receiveCommentEmail: Bool { __data["receiveCommentEmail"] }
|
||||
}
|
||||
|
||||
/// Quota
|
||||
///
|
||||
/// Parent Type: `UserQuotaType`
|
||||
public struct Quota: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.UserQuotaType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("name", String.self),
|
||||
.field("blobLimit", AffineGraphQL.SafeInt.self),
|
||||
.field("storageQuota", AffineGraphQL.SafeInt.self),
|
||||
.field("historyPeriod", AffineGraphQL.SafeInt.self),
|
||||
.field("memberLimit", Int.self),
|
||||
.field("humanReadable", HumanReadable.self),
|
||||
] }
|
||||
|
||||
public var name: String { __data["name"] }
|
||||
public var blobLimit: AffineGraphQL.SafeInt { __data["blobLimit"] }
|
||||
public var storageQuota: AffineGraphQL.SafeInt { __data["storageQuota"] }
|
||||
public var historyPeriod: AffineGraphQL.SafeInt { __data["historyPeriod"] }
|
||||
public var memberLimit: Int { __data["memberLimit"] }
|
||||
public var humanReadable: HumanReadable { __data["humanReadable"] }
|
||||
|
||||
/// Quota.HumanReadable
|
||||
///
|
||||
/// Parent Type: `UserQuotaHumanReadableType`
|
||||
public struct HumanReadable: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.UserQuotaHumanReadableType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("name", String.self),
|
||||
.field("blobLimit", String.self),
|
||||
.field("storageQuota", String.self),
|
||||
.field("historyPeriod", String.self),
|
||||
.field("memberLimit", String.self),
|
||||
] }
|
||||
|
||||
public var name: String { __data["name"] }
|
||||
public var blobLimit: String { __data["blobLimit"] }
|
||||
public var storageQuota: String { __data["storageQuota"] }
|
||||
public var historyPeriod: String { __data["historyPeriod"] }
|
||||
public var memberLimit: String { __data["memberLimit"] }
|
||||
}
|
||||
}
|
||||
|
||||
/// QuotaUsage
|
||||
///
|
||||
/// Parent Type: `UserQuotaUsageType`
|
||||
public struct QuotaUsage: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.UserQuotaUsageType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("storageQuota", AffineGraphQL.SafeInt.self),
|
||||
] }
|
||||
|
||||
@available(*, deprecated, message: "use `UserQuotaType[\'usedStorageQuota\']` instead")
|
||||
public var storageQuota: AffineGraphQL.SafeInt { __data["storageQuota"] }
|
||||
}
|
||||
|
||||
/// Copilot
|
||||
///
|
||||
/// Parent Type: `Copilot`
|
||||
public struct Copilot: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Copilot }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("quota", Quota.self),
|
||||
] }
|
||||
|
||||
/// Get the quota of the user in the workspace
|
||||
public var quota: Quota { __data["quota"] }
|
||||
|
||||
/// Copilot.Quota
|
||||
///
|
||||
/// Parent Type: `CopilotQuota`
|
||||
public struct Quota: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.CopilotQuota }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("limit", AffineGraphQL.SafeInt?.self),
|
||||
.field("used", AffineGraphQL.SafeInt.self),
|
||||
] }
|
||||
|
||||
public var limit: AffineGraphQL.SafeInt? { __data["limit"] }
|
||||
public var used: AffineGraphQL.SafeInt { __data["used"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,103 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class AdminUpdateWorkspaceMutation: GraphQLMutation {
|
||||
public static let operationName: String = "adminUpdateWorkspace"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation adminUpdateWorkspace($input: AdminUpdateWorkspaceInput!) { adminUpdateWorkspace(input: $input) { __typename id public createdAt name avatarKey enableAi enableSharing enableUrlPreview enableDocEmbedding features owner { __typename id name email avatarUrl } memberCount publicPageCount snapshotCount snapshotSize blobCount blobSize } }"#
|
||||
))
|
||||
|
||||
public var input: AdminUpdateWorkspaceInput
|
||||
|
||||
public init(input: AdminUpdateWorkspaceInput) {
|
||||
self.input = input
|
||||
}
|
||||
|
||||
public var __variables: Variables? { ["input": input] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Mutation }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("adminUpdateWorkspace", AdminUpdateWorkspace?.self, arguments: ["input": .variable("input")]),
|
||||
] }
|
||||
|
||||
/// Update workspace flags and features for admin
|
||||
public var adminUpdateWorkspace: AdminUpdateWorkspace? { __data["adminUpdateWorkspace"] }
|
||||
|
||||
/// AdminUpdateWorkspace
|
||||
///
|
||||
/// Parent Type: `AdminWorkspace`
|
||||
public struct AdminUpdateWorkspace: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.AdminWorkspace }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("id", String.self),
|
||||
.field("public", Bool.self),
|
||||
.field("createdAt", AffineGraphQL.DateTime.self),
|
||||
.field("name", String?.self),
|
||||
.field("avatarKey", String?.self),
|
||||
.field("enableAi", Bool.self),
|
||||
.field("enableSharing", Bool.self),
|
||||
.field("enableUrlPreview", Bool.self),
|
||||
.field("enableDocEmbedding", Bool.self),
|
||||
.field("features", [GraphQLEnum<AffineGraphQL.FeatureType>].self),
|
||||
.field("owner", Owner?.self),
|
||||
.field("memberCount", Int.self),
|
||||
.field("publicPageCount", Int.self),
|
||||
.field("snapshotCount", Int.self),
|
||||
.field("snapshotSize", AffineGraphQL.SafeInt.self),
|
||||
.field("blobCount", Int.self),
|
||||
.field("blobSize", AffineGraphQL.SafeInt.self),
|
||||
] }
|
||||
|
||||
public var id: String { __data["id"] }
|
||||
public var `public`: Bool { __data["public"] }
|
||||
public var createdAt: AffineGraphQL.DateTime { __data["createdAt"] }
|
||||
public var name: String? { __data["name"] }
|
||||
public var avatarKey: String? { __data["avatarKey"] }
|
||||
public var enableAi: Bool { __data["enableAi"] }
|
||||
public var enableSharing: Bool { __data["enableSharing"] }
|
||||
public var enableUrlPreview: Bool { __data["enableUrlPreview"] }
|
||||
public var enableDocEmbedding: Bool { __data["enableDocEmbedding"] }
|
||||
public var features: [GraphQLEnum<AffineGraphQL.FeatureType>] { __data["features"] }
|
||||
public var owner: Owner? { __data["owner"] }
|
||||
public var memberCount: Int { __data["memberCount"] }
|
||||
public var publicPageCount: Int { __data["publicPageCount"] }
|
||||
public var snapshotCount: Int { __data["snapshotCount"] }
|
||||
public var snapshotSize: AffineGraphQL.SafeInt { __data["snapshotSize"] }
|
||||
public var blobCount: Int { __data["blobCount"] }
|
||||
public var blobSize: AffineGraphQL.SafeInt { __data["blobSize"] }
|
||||
|
||||
/// AdminUpdateWorkspace.Owner
|
||||
///
|
||||
/// Parent Type: `WorkspaceUserType`
|
||||
public struct Owner: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.WorkspaceUserType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("id", String.self),
|
||||
.field("name", String.self),
|
||||
.field("email", String.self),
|
||||
.field("avatarUrl", String?.self),
|
||||
] }
|
||||
|
||||
public var id: String { __data["id"] }
|
||||
public var name: String { __data["name"] }
|
||||
public var email: String { __data["email"] }
|
||||
public var avatarUrl: String? { __data["avatarUrl"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -3,11 +3,11 @@
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class ApplyDocUpdatesQuery: GraphQLQuery {
|
||||
public class ApplyDocUpdatesMutation: GraphQLMutation {
|
||||
public static let operationName: String = "applyDocUpdates"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query applyDocUpdates($workspaceId: String!, $docId: String!, $op: String!, $updates: String!) { applyDocUpdates( workspaceId: $workspaceId docId: $docId op: $op updates: $updates ) }"#
|
||||
#"mutation applyDocUpdates($workspaceId: String!, $docId: String!, $op: String!, $updates: String!) { applyDocUpdates( workspaceId: $workspaceId docId: $docId op: $op updates: $updates ) }"#
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
@@ -38,7 +38,7 @@ public class ApplyDocUpdatesQuery: GraphQLQuery {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Query }
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Mutation }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("applyDocUpdates", String.self, arguments: [
|
||||
"workspaceId": .variable("workspaceId"),
|
||||
@@ -1,73 +0,0 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class GetBlobUploadPartUrlMutation: GraphQLMutation {
|
||||
public static let operationName: String = "getBlobUploadPartUrl"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation getBlobUploadPartUrl($workspaceId: String!, $key: String!, $uploadId: String!, $partNumber: Int!) { getBlobUploadPartUrl( workspaceId: $workspaceId key: $key uploadId: $uploadId partNumber: $partNumber ) { __typename uploadUrl headers expiresAt } }"#
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
public var key: String
|
||||
public var uploadId: String
|
||||
public var partNumber: Int
|
||||
|
||||
public init(
|
||||
workspaceId: String,
|
||||
key: String,
|
||||
uploadId: String,
|
||||
partNumber: Int
|
||||
) {
|
||||
self.workspaceId = workspaceId
|
||||
self.key = key
|
||||
self.uploadId = uploadId
|
||||
self.partNumber = partNumber
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"workspaceId": workspaceId,
|
||||
"key": key,
|
||||
"uploadId": uploadId,
|
||||
"partNumber": partNumber
|
||||
] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Mutation }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("getBlobUploadPartUrl", GetBlobUploadPartUrl.self, arguments: [
|
||||
"workspaceId": .variable("workspaceId"),
|
||||
"key": .variable("key"),
|
||||
"uploadId": .variable("uploadId"),
|
||||
"partNumber": .variable("partNumber")
|
||||
]),
|
||||
] }
|
||||
|
||||
public var getBlobUploadPartUrl: GetBlobUploadPartUrl { __data["getBlobUploadPartUrl"] }
|
||||
|
||||
/// GetBlobUploadPartUrl
|
||||
///
|
||||
/// Parent Type: `BlobUploadPart`
|
||||
public struct GetBlobUploadPartUrl: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.BlobUploadPart }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("uploadUrl", String.self),
|
||||
.field("headers", AffineGraphQL.JSONObject?.self),
|
||||
.field("expiresAt", AffineGraphQL.DateTime?.self),
|
||||
] }
|
||||
|
||||
public var uploadUrl: String { __data["uploadUrl"] }
|
||||
public var headers: AffineGraphQL.JSONObject? { __data["headers"] }
|
||||
public var expiresAt: AffineGraphQL.DateTime? { __data["expiresAt"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,68 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class LinkCalDavAccountMutation: GraphQLMutation {
|
||||
public static let operationName: String = "linkCalDavAccount"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation linkCalDavAccount($input: LinkCalDAVAccountInput!) { linkCalDAVAccount(input: $input) { __typename id provider providerAccountId displayName email status lastError refreshIntervalMinutes calendarsCount createdAt updatedAt } }"#
|
||||
))
|
||||
|
||||
public var input: LinkCalDAVAccountInput
|
||||
|
||||
public init(input: LinkCalDAVAccountInput) {
|
||||
self.input = input
|
||||
}
|
||||
|
||||
public var __variables: Variables? { ["input": input] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Mutation }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("linkCalDAVAccount", LinkCalDAVAccount.self, arguments: ["input": .variable("input")]),
|
||||
] }
|
||||
|
||||
public var linkCalDAVAccount: LinkCalDAVAccount { __data["linkCalDAVAccount"] }
|
||||
|
||||
/// LinkCalDAVAccount
|
||||
///
|
||||
/// Parent Type: `CalendarAccountObjectType`
|
||||
public struct LinkCalDAVAccount: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.CalendarAccountObjectType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("id", String.self),
|
||||
.field("provider", GraphQLEnum<AffineGraphQL.CalendarProviderType>.self),
|
||||
.field("providerAccountId", String.self),
|
||||
.field("displayName", String?.self),
|
||||
.field("email", String?.self),
|
||||
.field("status", String.self),
|
||||
.field("lastError", String?.self),
|
||||
.field("refreshIntervalMinutes", Int.self),
|
||||
.field("calendarsCount", Int.self),
|
||||
.field("createdAt", AffineGraphQL.DateTime.self),
|
||||
.field("updatedAt", AffineGraphQL.DateTime.self),
|
||||
] }
|
||||
|
||||
public var id: String { __data["id"] }
|
||||
public var provider: GraphQLEnum<AffineGraphQL.CalendarProviderType> { __data["provider"] }
|
||||
public var providerAccountId: String { __data["providerAccountId"] }
|
||||
public var displayName: String? { __data["displayName"] }
|
||||
public var email: String? { __data["email"] }
|
||||
public var status: String { __data["status"] }
|
||||
public var lastError: String? { __data["lastError"] }
|
||||
public var refreshIntervalMinutes: Int { __data["refreshIntervalMinutes"] }
|
||||
public var calendarsCount: Int { __data["calendarsCount"] }
|
||||
public var createdAt: AffineGraphQL.DateTime { __data["createdAt"] }
|
||||
public var updatedAt: AffineGraphQL.DateTime { __data["updatedAt"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class LinkCalendarAccountMutation: GraphQLMutation {
|
||||
public static let operationName: String = "linkCalendarAccount"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation linkCalendarAccount($input: LinkCalendarAccountInput!) { linkCalendarAccount(input: $input) }"#
|
||||
))
|
||||
|
||||
public var input: LinkCalendarAccountInput
|
||||
|
||||
public init(input: LinkCalendarAccountInput) {
|
||||
self.input = input
|
||||
}
|
||||
|
||||
public var __variables: Variables? { ["input": input] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Mutation }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("linkCalendarAccount", String.self, arguments: ["input": .variable("input")]),
|
||||
] }
|
||||
|
||||
public var linkCalendarAccount: String { __data["linkCalendarAccount"] }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,60 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class SetEnableSharingMutation: GraphQLMutation {
|
||||
public static let operationName: String = "setEnableSharing"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation setEnableSharing($id: ID!, $enableSharing: Boolean!) { updateWorkspace(input: { id: $id, enableSharing: $enableSharing }) { __typename id } }"#
|
||||
))
|
||||
|
||||
public var id: ID
|
||||
public var enableSharing: Bool
|
||||
|
||||
public init(
|
||||
id: ID,
|
||||
enableSharing: Bool
|
||||
) {
|
||||
self.id = id
|
||||
self.enableSharing = enableSharing
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"id": id,
|
||||
"enableSharing": enableSharing
|
||||
] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Mutation }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("updateWorkspace", UpdateWorkspace.self, arguments: ["input": [
|
||||
"id": .variable("id"),
|
||||
"enableSharing": .variable("enableSharing")
|
||||
]]),
|
||||
] }
|
||||
|
||||
/// Update workspace
|
||||
public var updateWorkspace: UpdateWorkspace { __data["updateWorkspace"] }
|
||||
|
||||
/// UpdateWorkspace
|
||||
///
|
||||
/// Parent Type: `WorkspaceType`
|
||||
public struct UpdateWorkspace: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.WorkspaceType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("id", AffineGraphQL.ID.self),
|
||||
] }
|
||||
|
||||
public var id: AffineGraphQL.ID { __data["id"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class UnlinkCalendarAccountMutation: GraphQLMutation {
|
||||
public static let operationName: String = "unlinkCalendarAccount"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation unlinkCalendarAccount($accountId: String!) { unlinkCalendarAccount(accountId: $accountId) }"#
|
||||
))
|
||||
|
||||
public var accountId: String
|
||||
|
||||
public init(accountId: String) {
|
||||
self.accountId = accountId
|
||||
}
|
||||
|
||||
public var __variables: Variables? { ["accountId": accountId] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Mutation }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("unlinkCalendarAccount", Bool.self, arguments: ["accountId": .variable("accountId")]),
|
||||
] }
|
||||
|
||||
public var unlinkCalendarAccount: Bool { __data["unlinkCalendarAccount"] }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,79 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class UpdateCalendarAccountMutation: GraphQLMutation {
|
||||
public static let operationName: String = "updateCalendarAccount"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation updateCalendarAccount($accountId: String!, $refreshIntervalMinutes: Int!) { updateCalendarAccount( accountId: $accountId refreshIntervalMinutes: $refreshIntervalMinutes ) { __typename id provider providerAccountId displayName email status lastError refreshIntervalMinutes calendarsCount createdAt updatedAt } }"#
|
||||
))
|
||||
|
||||
public var accountId: String
|
||||
public var refreshIntervalMinutes: Int
|
||||
|
||||
public init(
|
||||
accountId: String,
|
||||
refreshIntervalMinutes: Int
|
||||
) {
|
||||
self.accountId = accountId
|
||||
self.refreshIntervalMinutes = refreshIntervalMinutes
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"accountId": accountId,
|
||||
"refreshIntervalMinutes": refreshIntervalMinutes
|
||||
] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Mutation }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("updateCalendarAccount", UpdateCalendarAccount?.self, arguments: [
|
||||
"accountId": .variable("accountId"),
|
||||
"refreshIntervalMinutes": .variable("refreshIntervalMinutes")
|
||||
]),
|
||||
] }
|
||||
|
||||
public var updateCalendarAccount: UpdateCalendarAccount? { __data["updateCalendarAccount"] }
|
||||
|
||||
/// UpdateCalendarAccount
|
||||
///
|
||||
/// Parent Type: `CalendarAccountObjectType`
|
||||
public struct UpdateCalendarAccount: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.CalendarAccountObjectType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("id", String.self),
|
||||
.field("provider", GraphQLEnum<AffineGraphQL.CalendarProviderType>.self),
|
||||
.field("providerAccountId", String.self),
|
||||
.field("displayName", String?.self),
|
||||
.field("email", String?.self),
|
||||
.field("status", String.self),
|
||||
.field("lastError", String?.self),
|
||||
.field("refreshIntervalMinutes", Int.self),
|
||||
.field("calendarsCount", Int.self),
|
||||
.field("createdAt", AffineGraphQL.DateTime.self),
|
||||
.field("updatedAt", AffineGraphQL.DateTime.self),
|
||||
] }
|
||||
|
||||
public var id: String { __data["id"] }
|
||||
public var provider: GraphQLEnum<AffineGraphQL.CalendarProviderType> { __data["provider"] }
|
||||
public var providerAccountId: String { __data["providerAccountId"] }
|
||||
public var displayName: String? { __data["displayName"] }
|
||||
public var email: String? { __data["email"] }
|
||||
public var status: String { __data["status"] }
|
||||
public var lastError: String? { __data["lastError"] }
|
||||
public var refreshIntervalMinutes: Int { __data["refreshIntervalMinutes"] }
|
||||
public var calendarsCount: Int { __data["calendarsCount"] }
|
||||
public var createdAt: AffineGraphQL.DateTime { __data["createdAt"] }
|
||||
public var updatedAt: AffineGraphQL.DateTime { __data["updatedAt"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,84 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class UpdateWorkspaceCalendarsMutation: GraphQLMutation {
|
||||
public static let operationName: String = "updateWorkspaceCalendars"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation updateWorkspaceCalendars($input: UpdateWorkspaceCalendarsInput!) { updateWorkspaceCalendars(input: $input) { __typename id workspaceId createdByUserId displayNameOverride colorOverride enabled items { __typename id subscriptionId sortOrder colorOverride enabled } } }"#
|
||||
))
|
||||
|
||||
public var input: UpdateWorkspaceCalendarsInput
|
||||
|
||||
public init(input: UpdateWorkspaceCalendarsInput) {
|
||||
self.input = input
|
||||
}
|
||||
|
||||
public var __variables: Variables? { ["input": input] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Mutation }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("updateWorkspaceCalendars", UpdateWorkspaceCalendars.self, arguments: ["input": .variable("input")]),
|
||||
] }
|
||||
|
||||
public var updateWorkspaceCalendars: UpdateWorkspaceCalendars { __data["updateWorkspaceCalendars"] }
|
||||
|
||||
/// UpdateWorkspaceCalendars
|
||||
///
|
||||
/// Parent Type: `WorkspaceCalendarObjectType`
|
||||
public struct UpdateWorkspaceCalendars: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.WorkspaceCalendarObjectType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("id", String.self),
|
||||
.field("workspaceId", String.self),
|
||||
.field("createdByUserId", String.self),
|
||||
.field("displayNameOverride", String?.self),
|
||||
.field("colorOverride", String?.self),
|
||||
.field("enabled", Bool.self),
|
||||
.field("items", [Item].self),
|
||||
] }
|
||||
|
||||
public var id: String { __data["id"] }
|
||||
public var workspaceId: String { __data["workspaceId"] }
|
||||
public var createdByUserId: String { __data["createdByUserId"] }
|
||||
public var displayNameOverride: String? { __data["displayNameOverride"] }
|
||||
public var colorOverride: String? { __data["colorOverride"] }
|
||||
public var enabled: Bool { __data["enabled"] }
|
||||
public var items: [Item] { __data["items"] }
|
||||
|
||||
/// UpdateWorkspaceCalendars.Item
|
||||
///
|
||||
/// Parent Type: `WorkspaceCalendarItemObjectType`
|
||||
public struct Item: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.WorkspaceCalendarItemObjectType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("id", String.self),
|
||||
.field("subscriptionId", String.self),
|
||||
.field("sortOrder", Int?.self),
|
||||
.field("colorOverride", String?.self),
|
||||
.field("enabled", Bool.self),
|
||||
] }
|
||||
|
||||
public var id: String { __data["id"] }
|
||||
public var subscriptionId: String { __data["subscriptionId"] }
|
||||
public var sortOrder: Int? { __data["sortOrder"] }
|
||||
public var colorOverride: String? { __data["colorOverride"] }
|
||||
public var enabled: Bool { __data["enabled"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -7,7 +7,7 @@ public class AdminServerConfigQuery: GraphQLQuery {
|
||||
public static let operationName: String = "adminServerConfig"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query adminServerConfig { serverConfig { __typename version baseUrl name features type initialized credentialsRequirement { __typename ...CredentialsRequirements } availableUpgrade { __typename changelog version publishedAt url } availableUserFeatures } }"#,
|
||||
#"query adminServerConfig { serverConfig { __typename version baseUrl name features type initialized credentialsRequirement { __typename ...CredentialsRequirements } availableUpgrade { __typename changelog version publishedAt url } availableUserFeatures availableWorkspaceFeatures } }"#,
|
||||
fragments: [CredentialsRequirements.self, PasswordLimits.self]
|
||||
))
|
||||
|
||||
@@ -44,6 +44,7 @@ public class AdminServerConfigQuery: GraphQLQuery {
|
||||
.field("credentialsRequirement", CredentialsRequirement.self),
|
||||
.field("availableUpgrade", AvailableUpgrade?.self),
|
||||
.field("availableUserFeatures", [GraphQLEnum<AffineGraphQL.FeatureType>].self),
|
||||
.field("availableWorkspaceFeatures", [GraphQLEnum<AffineGraphQL.FeatureType>].self),
|
||||
] }
|
||||
|
||||
/// server version
|
||||
@@ -64,6 +65,8 @@ public class AdminServerConfigQuery: GraphQLQuery {
|
||||
public var availableUpgrade: AvailableUpgrade? { __data["availableUpgrade"] }
|
||||
/// Features for user that can be configured
|
||||
public var availableUserFeatures: [GraphQLEnum<AffineGraphQL.FeatureType>] { __data["availableUserFeatures"] }
|
||||
/// Workspace features available for admin configuration
|
||||
public var availableWorkspaceFeatures: [GraphQLEnum<AffineGraphQL.FeatureType>] { __data["availableWorkspaceFeatures"] }
|
||||
|
||||
/// ServerConfig.CredentialsRequirement
|
||||
///
|
||||
|
||||
@@ -0,0 +1,174 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class AdminWorkspaceQuery: GraphQLQuery {
|
||||
public static let operationName: String = "adminWorkspace"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query adminWorkspace($id: String!, $memberSkip: Int, $memberTake: Int, $memberQuery: String) { adminWorkspace(id: $id) { __typename id public createdAt name avatarKey enableAi enableSharing enableUrlPreview enableDocEmbedding features owner { __typename id name email avatarUrl } memberCount publicPageCount snapshotCount snapshotSize blobCount blobSize sharedLinks { __typename docId title publishedAt } members(skip: $memberSkip, take: $memberTake, query: $memberQuery) { __typename id name email avatarUrl role status } } }"#
|
||||
))
|
||||
|
||||
public var id: String
|
||||
public var memberSkip: GraphQLNullable<Int>
|
||||
public var memberTake: GraphQLNullable<Int>
|
||||
public var memberQuery: GraphQLNullable<String>
|
||||
|
||||
public init(
|
||||
id: String,
|
||||
memberSkip: GraphQLNullable<Int>,
|
||||
memberTake: GraphQLNullable<Int>,
|
||||
memberQuery: GraphQLNullable<String>
|
||||
) {
|
||||
self.id = id
|
||||
self.memberSkip = memberSkip
|
||||
self.memberTake = memberTake
|
||||
self.memberQuery = memberQuery
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"id": id,
|
||||
"memberSkip": memberSkip,
|
||||
"memberTake": memberTake,
|
||||
"memberQuery": memberQuery
|
||||
] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Query }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("adminWorkspace", AdminWorkspace?.self, arguments: ["id": .variable("id")]),
|
||||
] }
|
||||
|
||||
/// Get workspace detail for admin
|
||||
public var adminWorkspace: AdminWorkspace? { __data["adminWorkspace"] }
|
||||
|
||||
/// AdminWorkspace
|
||||
///
|
||||
/// Parent Type: `AdminWorkspace`
|
||||
public struct AdminWorkspace: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.AdminWorkspace }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("id", String.self),
|
||||
.field("public", Bool.self),
|
||||
.field("createdAt", AffineGraphQL.DateTime.self),
|
||||
.field("name", String?.self),
|
||||
.field("avatarKey", String?.self),
|
||||
.field("enableAi", Bool.self),
|
||||
.field("enableSharing", Bool.self),
|
||||
.field("enableUrlPreview", Bool.self),
|
||||
.field("enableDocEmbedding", Bool.self),
|
||||
.field("features", [GraphQLEnum<AffineGraphQL.FeatureType>].self),
|
||||
.field("owner", Owner?.self),
|
||||
.field("memberCount", Int.self),
|
||||
.field("publicPageCount", Int.self),
|
||||
.field("snapshotCount", Int.self),
|
||||
.field("snapshotSize", AffineGraphQL.SafeInt.self),
|
||||
.field("blobCount", Int.self),
|
||||
.field("blobSize", AffineGraphQL.SafeInt.self),
|
||||
.field("sharedLinks", [SharedLink].self),
|
||||
.field("members", [Member].self, arguments: [
|
||||
"skip": .variable("memberSkip"),
|
||||
"take": .variable("memberTake"),
|
||||
"query": .variable("memberQuery")
|
||||
]),
|
||||
] }
|
||||
|
||||
public var id: String { __data["id"] }
|
||||
public var `public`: Bool { __data["public"] }
|
||||
public var createdAt: AffineGraphQL.DateTime { __data["createdAt"] }
|
||||
public var name: String? { __data["name"] }
|
||||
public var avatarKey: String? { __data["avatarKey"] }
|
||||
public var enableAi: Bool { __data["enableAi"] }
|
||||
public var enableSharing: Bool { __data["enableSharing"] }
|
||||
public var enableUrlPreview: Bool { __data["enableUrlPreview"] }
|
||||
public var enableDocEmbedding: Bool { __data["enableDocEmbedding"] }
|
||||
public var features: [GraphQLEnum<AffineGraphQL.FeatureType>] { __data["features"] }
|
||||
public var owner: Owner? { __data["owner"] }
|
||||
public var memberCount: Int { __data["memberCount"] }
|
||||
public var publicPageCount: Int { __data["publicPageCount"] }
|
||||
public var snapshotCount: Int { __data["snapshotCount"] }
|
||||
public var snapshotSize: AffineGraphQL.SafeInt { __data["snapshotSize"] }
|
||||
public var blobCount: Int { __data["blobCount"] }
|
||||
public var blobSize: AffineGraphQL.SafeInt { __data["blobSize"] }
|
||||
public var sharedLinks: [SharedLink] { __data["sharedLinks"] }
|
||||
/// Members of workspace
|
||||
public var members: [Member] { __data["members"] }
|
||||
|
||||
/// AdminWorkspace.Owner
|
||||
///
|
||||
/// Parent Type: `WorkspaceUserType`
|
||||
public struct Owner: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.WorkspaceUserType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("id", String.self),
|
||||
.field("name", String.self),
|
||||
.field("email", String.self),
|
||||
.field("avatarUrl", String?.self),
|
||||
] }
|
||||
|
||||
public var id: String { __data["id"] }
|
||||
public var name: String { __data["name"] }
|
||||
public var email: String { __data["email"] }
|
||||
public var avatarUrl: String? { __data["avatarUrl"] }
|
||||
}
|
||||
|
||||
/// AdminWorkspace.SharedLink
|
||||
///
|
||||
/// Parent Type: `AdminWorkspaceSharedLink`
|
||||
public struct SharedLink: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.AdminWorkspaceSharedLink }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("docId", String.self),
|
||||
.field("title", String?.self),
|
||||
.field("publishedAt", AffineGraphQL.DateTime?.self),
|
||||
] }
|
||||
|
||||
public var docId: String { __data["docId"] }
|
||||
public var title: String? { __data["title"] }
|
||||
public var publishedAt: AffineGraphQL.DateTime? { __data["publishedAt"] }
|
||||
}
|
||||
|
||||
/// AdminWorkspace.Member
|
||||
///
|
||||
/// Parent Type: `AdminWorkspaceMember`
|
||||
public struct Member: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.AdminWorkspaceMember }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("id", String.self),
|
||||
.field("name", String.self),
|
||||
.field("email", String.self),
|
||||
.field("avatarUrl", String?.self),
|
||||
.field("role", GraphQLEnum<AffineGraphQL.Permission>.self),
|
||||
.field("status", GraphQLEnum<AffineGraphQL.WorkspaceMemberStatus>.self),
|
||||
] }
|
||||
|
||||
public var id: String { __data["id"] }
|
||||
public var name: String { __data["name"] }
|
||||
public var email: String { __data["email"] }
|
||||
public var avatarUrl: String? { __data["avatarUrl"] }
|
||||
public var role: GraphQLEnum<AffineGraphQL.Permission> { __data["role"] }
|
||||
public var status: GraphQLEnum<AffineGraphQL.WorkspaceMemberStatus> { __data["status"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,33 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class AdminWorkspacesCountQuery: GraphQLQuery {
|
||||
public static let operationName: String = "adminWorkspacesCount"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query adminWorkspacesCount($filter: ListWorkspaceInput!) { adminWorkspacesCount(filter: $filter) }"#
|
||||
))
|
||||
|
||||
public var filter: ListWorkspaceInput
|
||||
|
||||
public init(filter: ListWorkspaceInput) {
|
||||
self.filter = filter
|
||||
}
|
||||
|
||||
public var __variables: Variables? { ["filter": filter] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Query }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("adminWorkspacesCount", Int.self, arguments: ["filter": .variable("filter")]),
|
||||
] }
|
||||
|
||||
/// Workspaces count for admin
|
||||
public var adminWorkspacesCount: Int { __data["adminWorkspacesCount"] }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,103 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class AdminWorkspacesQuery: GraphQLQuery {
|
||||
public static let operationName: String = "adminWorkspaces"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query adminWorkspaces($filter: ListWorkspaceInput!) { adminWorkspaces(filter: $filter) { __typename id public createdAt name avatarKey enableAi enableSharing enableUrlPreview enableDocEmbedding features owner { __typename id name email avatarUrl } memberCount publicPageCount snapshotCount snapshotSize blobCount blobSize } }"#
|
||||
))
|
||||
|
||||
public var filter: ListWorkspaceInput
|
||||
|
||||
public init(filter: ListWorkspaceInput) {
|
||||
self.filter = filter
|
||||
}
|
||||
|
||||
public var __variables: Variables? { ["filter": filter] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Query }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("adminWorkspaces", [AdminWorkspace].self, arguments: ["filter": .variable("filter")]),
|
||||
] }
|
||||
|
||||
/// List workspaces for admin
|
||||
public var adminWorkspaces: [AdminWorkspace] { __data["adminWorkspaces"] }
|
||||
|
||||
/// AdminWorkspace
|
||||
///
|
||||
/// Parent Type: `AdminWorkspace`
|
||||
public struct AdminWorkspace: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.AdminWorkspace }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("id", String.self),
|
||||
.field("public", Bool.self),
|
||||
.field("createdAt", AffineGraphQL.DateTime.self),
|
||||
.field("name", String?.self),
|
||||
.field("avatarKey", String?.self),
|
||||
.field("enableAi", Bool.self),
|
||||
.field("enableSharing", Bool.self),
|
||||
.field("enableUrlPreview", Bool.self),
|
||||
.field("enableDocEmbedding", Bool.self),
|
||||
.field("features", [GraphQLEnum<AffineGraphQL.FeatureType>].self),
|
||||
.field("owner", Owner?.self),
|
||||
.field("memberCount", Int.self),
|
||||
.field("publicPageCount", Int.self),
|
||||
.field("snapshotCount", Int.self),
|
||||
.field("snapshotSize", AffineGraphQL.SafeInt.self),
|
||||
.field("blobCount", Int.self),
|
||||
.field("blobSize", AffineGraphQL.SafeInt.self),
|
||||
] }
|
||||
|
||||
public var id: String { __data["id"] }
|
||||
public var `public`: Bool { __data["public"] }
|
||||
public var createdAt: AffineGraphQL.DateTime { __data["createdAt"] }
|
||||
public var name: String? { __data["name"] }
|
||||
public var avatarKey: String? { __data["avatarKey"] }
|
||||
public var enableAi: Bool { __data["enableAi"] }
|
||||
public var enableSharing: Bool { __data["enableSharing"] }
|
||||
public var enableUrlPreview: Bool { __data["enableUrlPreview"] }
|
||||
public var enableDocEmbedding: Bool { __data["enableDocEmbedding"] }
|
||||
public var features: [GraphQLEnum<AffineGraphQL.FeatureType>] { __data["features"] }
|
||||
public var owner: Owner? { __data["owner"] }
|
||||
public var memberCount: Int { __data["memberCount"] }
|
||||
public var publicPageCount: Int { __data["publicPageCount"] }
|
||||
public var snapshotCount: Int { __data["snapshotCount"] }
|
||||
public var snapshotSize: AffineGraphQL.SafeInt { __data["snapshotSize"] }
|
||||
public var blobCount: Int { __data["blobCount"] }
|
||||
public var blobSize: AffineGraphQL.SafeInt { __data["blobSize"] }
|
||||
|
||||
/// AdminWorkspace.Owner
|
||||
///
|
||||
/// Parent Type: `WorkspaceUserType`
|
||||
public struct Owner: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.WorkspaceUserType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("id", String.self),
|
||||
.field("name", String.self),
|
||||
.field("email", String.self),
|
||||
.field("avatarUrl", String?.self),
|
||||
] }
|
||||
|
||||
public var id: String { __data["id"] }
|
||||
public var name: String { __data["name"] }
|
||||
public var email: String { __data["email"] }
|
||||
public var avatarUrl: String? { __data["avatarUrl"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,113 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class CalendarAccountsQuery: GraphQLQuery {
|
||||
public static let operationName: String = "calendarAccounts"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query calendarAccounts { currentUser { __typename calendarAccounts { __typename id provider providerAccountId displayName email status lastError refreshIntervalMinutes calendarsCount createdAt updatedAt calendars { __typename id accountId provider externalCalendarId displayName timezone color enabled lastSyncAt } } } }"#
|
||||
))
|
||||
|
||||
public init() {}
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Query }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("currentUser", CurrentUser?.self),
|
||||
] }
|
||||
|
||||
/// Get current user
|
||||
public var currentUser: CurrentUser? { __data["currentUser"] }
|
||||
|
||||
/// CurrentUser
|
||||
///
|
||||
/// Parent Type: `UserType`
|
||||
public struct CurrentUser: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.UserType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("calendarAccounts", [CalendarAccount].self),
|
||||
] }
|
||||
|
||||
public var calendarAccounts: [CalendarAccount] { __data["calendarAccounts"] }
|
||||
|
||||
/// CurrentUser.CalendarAccount
|
||||
///
|
||||
/// Parent Type: `CalendarAccountObjectType`
|
||||
public struct CalendarAccount: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.CalendarAccountObjectType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("id", String.self),
|
||||
.field("provider", GraphQLEnum<AffineGraphQL.CalendarProviderType>.self),
|
||||
.field("providerAccountId", String.self),
|
||||
.field("displayName", String?.self),
|
||||
.field("email", String?.self),
|
||||
.field("status", String.self),
|
||||
.field("lastError", String?.self),
|
||||
.field("refreshIntervalMinutes", Int.self),
|
||||
.field("calendarsCount", Int.self),
|
||||
.field("createdAt", AffineGraphQL.DateTime.self),
|
||||
.field("updatedAt", AffineGraphQL.DateTime.self),
|
||||
.field("calendars", [Calendar].self),
|
||||
] }
|
||||
|
||||
public var id: String { __data["id"] }
|
||||
public var provider: GraphQLEnum<AffineGraphQL.CalendarProviderType> { __data["provider"] }
|
||||
public var providerAccountId: String { __data["providerAccountId"] }
|
||||
public var displayName: String? { __data["displayName"] }
|
||||
public var email: String? { __data["email"] }
|
||||
public var status: String { __data["status"] }
|
||||
public var lastError: String? { __data["lastError"] }
|
||||
public var refreshIntervalMinutes: Int { __data["refreshIntervalMinutes"] }
|
||||
public var calendarsCount: Int { __data["calendarsCount"] }
|
||||
public var createdAt: AffineGraphQL.DateTime { __data["createdAt"] }
|
||||
public var updatedAt: AffineGraphQL.DateTime { __data["updatedAt"] }
|
||||
public var calendars: [Calendar] { __data["calendars"] }
|
||||
|
||||
/// CurrentUser.CalendarAccount.Calendar
|
||||
///
|
||||
/// Parent Type: `CalendarSubscriptionObjectType`
|
||||
public struct Calendar: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.CalendarSubscriptionObjectType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("id", String.self),
|
||||
.field("accountId", String.self),
|
||||
.field("provider", GraphQLEnum<AffineGraphQL.CalendarProviderType>.self),
|
||||
.field("externalCalendarId", String.self),
|
||||
.field("displayName", String?.self),
|
||||
.field("timezone", String?.self),
|
||||
.field("color", String?.self),
|
||||
.field("enabled", Bool.self),
|
||||
.field("lastSyncAt", AffineGraphQL.DateTime?.self),
|
||||
] }
|
||||
|
||||
public var id: String { __data["id"] }
|
||||
public var accountId: String { __data["accountId"] }
|
||||
public var provider: GraphQLEnum<AffineGraphQL.CalendarProviderType> { __data["provider"] }
|
||||
public var externalCalendarId: String { __data["externalCalendarId"] }
|
||||
public var displayName: String? { __data["displayName"] }
|
||||
public var timezone: String? { __data["timezone"] }
|
||||
public var color: String? { __data["color"] }
|
||||
public var enabled: Bool { __data["enabled"] }
|
||||
public var lastSyncAt: AffineGraphQL.DateTime? { __data["lastSyncAt"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,120 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class CalendarEventsQuery: GraphQLQuery {
|
||||
public static let operationName: String = "calendarEvents"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query calendarEvents($workspaceId: String!, $from: DateTime!, $to: DateTime!) { workspace(id: $workspaceId) { __typename calendars { __typename id events(from: $from, to: $to) { __typename id subscriptionId externalEventId recurrenceId status title description location startAtUtc endAtUtc originalTimezone allDay } } } }"#
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
public var from: DateTime
|
||||
public var to: DateTime
|
||||
|
||||
public init(
|
||||
workspaceId: String,
|
||||
from: DateTime,
|
||||
to: DateTime
|
||||
) {
|
||||
self.workspaceId = workspaceId
|
||||
self.from = from
|
||||
self.to = to
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"workspaceId": workspaceId,
|
||||
"from": from,
|
||||
"to": to
|
||||
] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Query }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("workspace", Workspace.self, arguments: ["id": .variable("workspaceId")]),
|
||||
] }
|
||||
|
||||
/// Get workspace by id
|
||||
public var workspace: Workspace { __data["workspace"] }
|
||||
|
||||
/// Workspace
|
||||
///
|
||||
/// Parent Type: `WorkspaceType`
|
||||
public struct Workspace: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.WorkspaceType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("calendars", [Calendar].self),
|
||||
] }
|
||||
|
||||
public var calendars: [Calendar] { __data["calendars"] }
|
||||
|
||||
/// Workspace.Calendar
|
||||
///
|
||||
/// Parent Type: `WorkspaceCalendarObjectType`
|
||||
public struct Calendar: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.WorkspaceCalendarObjectType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("id", String.self),
|
||||
.field("events", [Event].self, arguments: [
|
||||
"from": .variable("from"),
|
||||
"to": .variable("to")
|
||||
]),
|
||||
] }
|
||||
|
||||
public var id: String { __data["id"] }
|
||||
public var events: [Event] { __data["events"] }
|
||||
|
||||
/// Workspace.Calendar.Event
|
||||
///
|
||||
/// Parent Type: `CalendarEventObjectType`
|
||||
public struct Event: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.CalendarEventObjectType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("id", String.self),
|
||||
.field("subscriptionId", String.self),
|
||||
.field("externalEventId", String.self),
|
||||
.field("recurrenceId", String?.self),
|
||||
.field("status", String?.self),
|
||||
.field("title", String?.self),
|
||||
.field("description", String?.self),
|
||||
.field("location", String?.self),
|
||||
.field("startAtUtc", AffineGraphQL.DateTime.self),
|
||||
.field("endAtUtc", AffineGraphQL.DateTime.self),
|
||||
.field("originalTimezone", String?.self),
|
||||
.field("allDay", Bool.self),
|
||||
] }
|
||||
|
||||
public var id: String { __data["id"] }
|
||||
public var subscriptionId: String { __data["subscriptionId"] }
|
||||
public var externalEventId: String { __data["externalEventId"] }
|
||||
public var recurrenceId: String? { __data["recurrenceId"] }
|
||||
public var status: String? { __data["status"] }
|
||||
public var title: String? { __data["title"] }
|
||||
public var description: String? { __data["description"] }
|
||||
public var location: String? { __data["location"] }
|
||||
public var startAtUtc: AffineGraphQL.DateTime { __data["startAtUtc"] }
|
||||
public var endAtUtc: AffineGraphQL.DateTime { __data["endAtUtc"] }
|
||||
public var originalTimezone: String? { __data["originalTimezone"] }
|
||||
public var allDay: Bool { __data["allDay"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,67 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class CalendarProvidersQuery: GraphQLQuery {
|
||||
public static let operationName: String = "calendarProviders"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query calendarProviders { serverConfig { __typename calendarCalDAVProviders { __typename id label requiresAppPassword docsUrl } calendarProviders } }"#
|
||||
))
|
||||
|
||||
public init() {}
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Query }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("serverConfig", ServerConfig.self),
|
||||
] }
|
||||
|
||||
/// server config
|
||||
public var serverConfig: ServerConfig { __data["serverConfig"] }
|
||||
|
||||
/// ServerConfig
|
||||
///
|
||||
/// Parent Type: `ServerConfigType`
|
||||
public struct ServerConfig: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.ServerConfigType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("calendarCalDAVProviders", [CalendarCalDAVProvider].self),
|
||||
.field("calendarProviders", [GraphQLEnum<AffineGraphQL.CalendarProviderType>].self),
|
||||
] }
|
||||
|
||||
public var calendarCalDAVProviders: [CalendarCalDAVProvider] { __data["calendarCalDAVProviders"] }
|
||||
public var calendarProviders: [GraphQLEnum<AffineGraphQL.CalendarProviderType>] { __data["calendarProviders"] }
|
||||
|
||||
/// ServerConfig.CalendarCalDAVProvider
|
||||
///
|
||||
/// Parent Type: `CalendarCalDAVProviderPresetObjectType`
|
||||
public struct CalendarCalDAVProvider: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.CalendarCalDAVProviderPresetObjectType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("id", String.self),
|
||||
.field("label", String.self),
|
||||
.field("requiresAppPassword", Bool?.self),
|
||||
.field("docsUrl", String?.self),
|
||||
] }
|
||||
|
||||
public var id: String { __data["id"] }
|
||||
public var label: String { __data["label"] }
|
||||
public var requiresAppPassword: Bool? { __data["requiresAppPassword"] }
|
||||
public var docsUrl: String? { __data["docsUrl"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,90 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class GetBlobUploadPartUrlQuery: GraphQLQuery {
|
||||
public static let operationName: String = "getBlobUploadPartUrl"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query getBlobUploadPartUrl($workspaceId: String!, $key: String!, $uploadId: String!, $partNumber: Int!) { workspace(id: $workspaceId) { __typename blobUploadPartUrl(key: $key, uploadId: $uploadId, partNumber: $partNumber) { __typename uploadUrl headers expiresAt } } }"#
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
public var key: String
|
||||
public var uploadId: String
|
||||
public var partNumber: Int
|
||||
|
||||
public init(
|
||||
workspaceId: String,
|
||||
key: String,
|
||||
uploadId: String,
|
||||
partNumber: Int
|
||||
) {
|
||||
self.workspaceId = workspaceId
|
||||
self.key = key
|
||||
self.uploadId = uploadId
|
||||
self.partNumber = partNumber
|
||||
}
|
||||
|
||||
public var __variables: Variables? { [
|
||||
"workspaceId": workspaceId,
|
||||
"key": key,
|
||||
"uploadId": uploadId,
|
||||
"partNumber": partNumber
|
||||
] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Query }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("workspace", Workspace.self, arguments: ["id": .variable("workspaceId")]),
|
||||
] }
|
||||
|
||||
/// Get workspace by id
|
||||
public var workspace: Workspace { __data["workspace"] }
|
||||
|
||||
/// Workspace
|
||||
///
|
||||
/// Parent Type: `WorkspaceType`
|
||||
public struct Workspace: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.WorkspaceType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("blobUploadPartUrl", BlobUploadPartUrl.self, arguments: [
|
||||
"key": .variable("key"),
|
||||
"uploadId": .variable("uploadId"),
|
||||
"partNumber": .variable("partNumber")
|
||||
]),
|
||||
] }
|
||||
|
||||
/// Get blob upload part url
|
||||
public var blobUploadPartUrl: BlobUploadPartUrl { __data["blobUploadPartUrl"] }
|
||||
|
||||
/// Workspace.BlobUploadPartUrl
|
||||
///
|
||||
/// Parent Type: `BlobUploadPart`
|
||||
public struct BlobUploadPartUrl: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.BlobUploadPart }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("uploadUrl", String.self),
|
||||
.field("headers", AffineGraphQL.JSONObject?.self),
|
||||
.field("expiresAt", AffineGraphQL.DateTime?.self),
|
||||
] }
|
||||
|
||||
public var uploadUrl: String { __data["uploadUrl"] }
|
||||
public var headers: AffineGraphQL.JSONObject? { __data["headers"] }
|
||||
public var expiresAt: AffineGraphQL.DateTime? { __data["expiresAt"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,74 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class GetCurrentUserProfileQuery: GraphQLQuery {
|
||||
public static let operationName: String = "getCurrentUserProfile"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query getCurrentUserProfile { currentUser { __typename ...CurrentUserProfile } }"#,
|
||||
fragments: [CurrentUserProfile.self]
|
||||
))
|
||||
|
||||
public init() {}
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Query }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("currentUser", CurrentUser?.self),
|
||||
] }
|
||||
|
||||
/// Get current user
|
||||
public var currentUser: CurrentUser? { __data["currentUser"] }
|
||||
|
||||
/// CurrentUser
|
||||
///
|
||||
/// Parent Type: `UserType`
|
||||
public struct CurrentUser: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.UserType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.fragment(CurrentUserProfile.self),
|
||||
] }
|
||||
|
||||
public var id: AffineGraphQL.ID { __data["id"] }
|
||||
/// User name
|
||||
public var name: String { __data["name"] }
|
||||
/// User email
|
||||
public var email: String { __data["email"] }
|
||||
/// User avatar url
|
||||
public var avatarUrl: String? { __data["avatarUrl"] }
|
||||
/// User email verified
|
||||
public var emailVerified: Bool { __data["emailVerified"] }
|
||||
/// Enabled features of a user
|
||||
public var features: [GraphQLEnum<AffineGraphQL.FeatureType>] { __data["features"] }
|
||||
/// Get user settings
|
||||
public var settings: Settings { __data["settings"] }
|
||||
public var quota: Quota { __data["quota"] }
|
||||
public var quotaUsage: QuotaUsage { __data["quotaUsage"] }
|
||||
public var copilot: Copilot { __data["copilot"] }
|
||||
|
||||
public struct Fragments: FragmentContainer {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public var currentUserProfile: CurrentUserProfile { _toFragment() }
|
||||
}
|
||||
|
||||
public typealias Settings = CurrentUserProfile.Settings
|
||||
|
||||
public typealias Quota = CurrentUserProfile.Quota
|
||||
|
||||
public typealias QuotaUsage = CurrentUserProfile.QuotaUsage
|
||||
|
||||
public typealias Copilot = CurrentUserProfile.Copilot
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -7,7 +7,7 @@ public class GetWorkspaceConfigQuery: GraphQLQuery {
|
||||
public static let operationName: String = "getWorkspaceConfig"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query getWorkspaceConfig($id: String!) { workspace(id: $id) { __typename enableAi enableUrlPreview enableDocEmbedding inviteLink { __typename link expireTime } } }"#
|
||||
#"query getWorkspaceConfig($id: String!) { workspace(id: $id) { __typename enableAi enableSharing enableUrlPreview enableDocEmbedding inviteLink { __typename link expireTime } } }"#
|
||||
))
|
||||
|
||||
public var id: String
|
||||
@@ -41,6 +41,7 @@ public class GetWorkspaceConfigQuery: GraphQLQuery {
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("enableAi", Bool.self),
|
||||
.field("enableSharing", Bool.self),
|
||||
.field("enableUrlPreview", Bool.self),
|
||||
.field("enableDocEmbedding", Bool.self),
|
||||
.field("inviteLink", InviteLink?.self),
|
||||
@@ -48,6 +49,8 @@ public class GetWorkspaceConfigQuery: GraphQLQuery {
|
||||
|
||||
/// Enable AI
|
||||
public var enableAi: Bool { __data["enableAi"] }
|
||||
/// Enable workspace sharing
|
||||
public var enableSharing: Bool { __data["enableSharing"] }
|
||||
/// Enable url previous when sharing
|
||||
public var enableUrlPreview: Bool { __data["enableUrlPreview"] }
|
||||
/// Enable doc embedding
|
||||
|
||||
@@ -7,7 +7,7 @@ public class GetWorkspaceInfoQuery: GraphQLQuery {
|
||||
public static let operationName: String = "getWorkspaceInfo"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query getWorkspaceInfo($workspaceId: String!) { workspace(id: $workspaceId) { __typename role team } }"#
|
||||
#"query getWorkspaceInfo($workspaceId: String!) { workspace(id: $workspaceId) { __typename permissions { __typename Workspace_Administrators_Manage Workspace_Blobs_List Workspace_Blobs_Read Workspace_Blobs_Write Workspace_Copilot Workspace_CreateDoc Workspace_Delete Workspace_Organize_Read Workspace_Payment_Manage Workspace_Properties_Create Workspace_Properties_Delete Workspace_Properties_Read Workspace_Properties_Update Workspace_Read Workspace_Settings_Read Workspace_Settings_Update Workspace_Sync Workspace_TransferOwner Workspace_Users_Manage Workspace_Users_Read } role team } }"#
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
@@ -40,14 +40,71 @@ public class GetWorkspaceInfoQuery: GraphQLQuery {
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.WorkspaceType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("permissions", Permissions.self),
|
||||
.field("role", GraphQLEnum<AffineGraphQL.Permission>.self),
|
||||
.field("team", Bool.self),
|
||||
] }
|
||||
|
||||
/// map of action permissions
|
||||
public var permissions: Permissions { __data["permissions"] }
|
||||
/// Role of current signed in user in workspace
|
||||
public var role: GraphQLEnum<AffineGraphQL.Permission> { __data["role"] }
|
||||
/// if workspace is team workspace
|
||||
public var team: Bool { __data["team"] }
|
||||
|
||||
/// Workspace.Permissions
|
||||
///
|
||||
/// Parent Type: `WorkspacePermissions`
|
||||
public struct Permissions: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.WorkspacePermissions }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("Workspace_Administrators_Manage", Bool.self),
|
||||
.field("Workspace_Blobs_List", Bool.self),
|
||||
.field("Workspace_Blobs_Read", Bool.self),
|
||||
.field("Workspace_Blobs_Write", Bool.self),
|
||||
.field("Workspace_Copilot", Bool.self),
|
||||
.field("Workspace_CreateDoc", Bool.self),
|
||||
.field("Workspace_Delete", Bool.self),
|
||||
.field("Workspace_Organize_Read", Bool.self),
|
||||
.field("Workspace_Payment_Manage", Bool.self),
|
||||
.field("Workspace_Properties_Create", Bool.self),
|
||||
.field("Workspace_Properties_Delete", Bool.self),
|
||||
.field("Workspace_Properties_Read", Bool.self),
|
||||
.field("Workspace_Properties_Update", Bool.self),
|
||||
.field("Workspace_Read", Bool.self),
|
||||
.field("Workspace_Settings_Read", Bool.self),
|
||||
.field("Workspace_Settings_Update", Bool.self),
|
||||
.field("Workspace_Sync", Bool.self),
|
||||
.field("Workspace_TransferOwner", Bool.self),
|
||||
.field("Workspace_Users_Manage", Bool.self),
|
||||
.field("Workspace_Users_Read", Bool.self),
|
||||
] }
|
||||
|
||||
public var workspace_Administrators_Manage: Bool { __data["Workspace_Administrators_Manage"] }
|
||||
public var workspace_Blobs_List: Bool { __data["Workspace_Blobs_List"] }
|
||||
public var workspace_Blobs_Read: Bool { __data["Workspace_Blobs_Read"] }
|
||||
public var workspace_Blobs_Write: Bool { __data["Workspace_Blobs_Write"] }
|
||||
public var workspace_Copilot: Bool { __data["Workspace_Copilot"] }
|
||||
public var workspace_CreateDoc: Bool { __data["Workspace_CreateDoc"] }
|
||||
public var workspace_Delete: Bool { __data["Workspace_Delete"] }
|
||||
public var workspace_Organize_Read: Bool { __data["Workspace_Organize_Read"] }
|
||||
public var workspace_Payment_Manage: Bool { __data["Workspace_Payment_Manage"] }
|
||||
public var workspace_Properties_Create: Bool { __data["Workspace_Properties_Create"] }
|
||||
public var workspace_Properties_Delete: Bool { __data["Workspace_Properties_Delete"] }
|
||||
public var workspace_Properties_Read: Bool { __data["Workspace_Properties_Read"] }
|
||||
public var workspace_Properties_Update: Bool { __data["Workspace_Properties_Update"] }
|
||||
public var workspace_Read: Bool { __data["Workspace_Read"] }
|
||||
public var workspace_Settings_Read: Bool { __data["Workspace_Settings_Read"] }
|
||||
public var workspace_Settings_Update: Bool { __data["Workspace_Settings_Update"] }
|
||||
public var workspace_Sync: Bool { __data["Workspace_Sync"] }
|
||||
public var workspace_TransferOwner: Bool { __data["Workspace_TransferOwner"] }
|
||||
public var workspace_Users_Manage: Bool { __data["Workspace_Users_Manage"] }
|
||||
public var workspace_Users_Read: Bool { __data["Workspace_Users_Read"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -7,7 +7,7 @@ public class ListUserAccessTokensQuery: GraphQLQuery {
|
||||
public static let operationName: String = "listUserAccessTokens"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query listUserAccessTokens { revealedAccessTokens { __typename id name createdAt expiresAt token } }"#
|
||||
#"query listUserAccessTokens { currentUser { __typename revealedAccessTokens { __typename id name createdAt expiresAt token } } }"#
|
||||
))
|
||||
|
||||
public init() {}
|
||||
@@ -18,33 +18,50 @@ public class ListUserAccessTokensQuery: GraphQLQuery {
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Query }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("revealedAccessTokens", [RevealedAccessToken].self),
|
||||
.field("currentUser", CurrentUser?.self),
|
||||
] }
|
||||
|
||||
public var revealedAccessTokens: [RevealedAccessToken] { __data["revealedAccessTokens"] }
|
||||
/// Get current user
|
||||
public var currentUser: CurrentUser? { __data["currentUser"] }
|
||||
|
||||
/// RevealedAccessToken
|
||||
/// CurrentUser
|
||||
///
|
||||
/// Parent Type: `RevealedAccessToken`
|
||||
public struct RevealedAccessToken: AffineGraphQL.SelectionSet {
|
||||
/// Parent Type: `UserType`
|
||||
public struct CurrentUser: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.RevealedAccessToken }
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.UserType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("id", String.self),
|
||||
.field("name", String.self),
|
||||
.field("createdAt", AffineGraphQL.DateTime.self),
|
||||
.field("expiresAt", AffineGraphQL.DateTime?.self),
|
||||
.field("token", String.self),
|
||||
.field("revealedAccessTokens", [RevealedAccessToken].self),
|
||||
] }
|
||||
|
||||
public var id: String { __data["id"] }
|
||||
public var name: String { __data["name"] }
|
||||
public var createdAt: AffineGraphQL.DateTime { __data["createdAt"] }
|
||||
public var expiresAt: AffineGraphQL.DateTime? { __data["expiresAt"] }
|
||||
public var token: String { __data["token"] }
|
||||
public var revealedAccessTokens: [RevealedAccessToken] { __data["revealedAccessTokens"] }
|
||||
|
||||
/// CurrentUser.RevealedAccessToken
|
||||
///
|
||||
/// Parent Type: `RevealedAccessToken`
|
||||
public struct RevealedAccessToken: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.RevealedAccessToken }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("id", String.self),
|
||||
.field("name", String.self),
|
||||
.field("createdAt", AffineGraphQL.DateTime.self),
|
||||
.field("expiresAt", AffineGraphQL.DateTime?.self),
|
||||
.field("token", String.self),
|
||||
] }
|
||||
|
||||
public var id: String { __data["id"] }
|
||||
public var name: String { __data["name"] }
|
||||
public var createdAt: AffineGraphQL.DateTime { __data["createdAt"] }
|
||||
public var expiresAt: AffineGraphQL.DateTime? { __data["expiresAt"] }
|
||||
public var token: String { __data["token"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -7,7 +7,7 @@ public class ListUsersQuery: GraphQLQuery {
|
||||
public static let operationName: String = "listUsers"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query listUsers($filter: ListUserInput!) { users(filter: $filter) { __typename id name email disabled features hasPassword emailVerified avatarUrl } usersCount }"#
|
||||
#"query listUsers($filter: ListUserInput!) { users(filter: $filter) { __typename id name email disabled features hasPassword emailVerified avatarUrl } usersCount(filter: $filter) }"#
|
||||
))
|
||||
|
||||
public var filter: ListUserInput
|
||||
@@ -25,7 +25,7 @@ public class ListUsersQuery: GraphQLQuery {
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Query }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("users", [User].self, arguments: ["filter": .variable("filter")]),
|
||||
.field("usersCount", Int.self),
|
||||
.field("usersCount", Int.self, arguments: ["filter": .variable("filter")]),
|
||||
] }
|
||||
|
||||
/// List registered users
|
||||
|
||||
@@ -7,7 +7,7 @@ public class NotificationCountQuery: GraphQLQuery {
|
||||
public static let operationName: String = "notificationCount"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query notificationCount { currentUser { __typename notificationCount } }"#
|
||||
#"query notificationCount { currentUser { __typename notifications(pagination: { first: 1 }) { __typename totalCount } } }"#
|
||||
))
|
||||
|
||||
public init() {}
|
||||
@@ -34,11 +34,27 @@ public class NotificationCountQuery: GraphQLQuery {
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.UserType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("notificationCount", Int.self),
|
||||
.field("notifications", Notifications.self, arguments: ["pagination": ["first": 1]]),
|
||||
] }
|
||||
|
||||
/// Get user notification count
|
||||
public var notificationCount: Int { __data["notificationCount"] }
|
||||
/// Get current user notifications
|
||||
public var notifications: Notifications { __data["notifications"] }
|
||||
|
||||
/// CurrentUser.Notifications
|
||||
///
|
||||
/// Parent Type: `PaginatedNotificationObjectType`
|
||||
public struct Notifications: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.PaginatedNotificationObjectType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("totalCount", Int.self),
|
||||
] }
|
||||
|
||||
public var totalCount: Int { __data["totalCount"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -7,7 +7,7 @@ public class ServerConfigQuery: GraphQLQuery {
|
||||
public static let operationName: String = "serverConfig"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query serverConfig { serverConfig { __typename version baseUrl name features type initialized credentialsRequirement { __typename ...CredentialsRequirements } } }"#,
|
||||
#"query serverConfig { serverConfig { __typename version baseUrl name features type initialized calendarProviders credentialsRequirement { __typename ...CredentialsRequirements } } }"#,
|
||||
fragments: [CredentialsRequirements.self, PasswordLimits.self]
|
||||
))
|
||||
|
||||
@@ -41,6 +41,7 @@ public class ServerConfigQuery: GraphQLQuery {
|
||||
.field("features", [GraphQLEnum<AffineGraphQL.ServerFeature>].self),
|
||||
.field("type", GraphQLEnum<AffineGraphQL.ServerDeploymentType>.self),
|
||||
.field("initialized", Bool.self),
|
||||
.field("calendarProviders", [GraphQLEnum<AffineGraphQL.CalendarProviderType>].self),
|
||||
.field("credentialsRequirement", CredentialsRequirement.self),
|
||||
] }
|
||||
|
||||
@@ -56,6 +57,7 @@ public class ServerConfigQuery: GraphQLQuery {
|
||||
public var type: GraphQLEnum<AffineGraphQL.ServerDeploymentType> { __data["type"] }
|
||||
/// whether server has been initialized
|
||||
public var initialized: Bool { __data["initialized"] }
|
||||
public var calendarProviders: [GraphQLEnum<AffineGraphQL.CalendarProviderType>] { __data["calendarProviders"] }
|
||||
/// credentials requirement
|
||||
public var credentialsRequirement: CredentialsRequirement { __data["credentialsRequirement"] }
|
||||
|
||||
|
||||
@@ -3,11 +3,11 @@
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class ValidateConfigMutation: GraphQLMutation {
|
||||
public class ValidateConfigQuery: GraphQLQuery {
|
||||
public static let operationName: String = "validateConfig"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"mutation validateConfig($updates: [UpdateAppConfigInput!]!) { validateAppConfig(updates: $updates) { __typename module key value valid error } }"#
|
||||
#"query validateConfig($updates: [UpdateAppConfigInput!]!) { validateAppConfig(updates: $updates) { __typename module key value valid error } }"#
|
||||
))
|
||||
|
||||
public var updates: [UpdateAppConfigInput]
|
||||
@@ -22,7 +22,7 @@ public class ValidateConfigMutation: GraphQLMutation {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Mutation }
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Query }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("validateAppConfig", [ValidateAppConfig].self, arguments: ["updates": .variable("updates")]),
|
||||
] }
|
||||
@@ -0,0 +1,101 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
@_exported import ApolloAPI
|
||||
|
||||
public class WorkspaceCalendarsQuery: GraphQLQuery {
|
||||
public static let operationName: String = "workspaceCalendars"
|
||||
public static let operationDocument: ApolloAPI.OperationDocument = .init(
|
||||
definition: .init(
|
||||
#"query workspaceCalendars($workspaceId: String!) { workspace(id: $workspaceId) { __typename calendars { __typename id workspaceId createdByUserId displayNameOverride colorOverride enabled items { __typename id subscriptionId sortOrder colorOverride enabled } } } }"#
|
||||
))
|
||||
|
||||
public var workspaceId: String
|
||||
|
||||
public init(workspaceId: String) {
|
||||
self.workspaceId = workspaceId
|
||||
}
|
||||
|
||||
public var __variables: Variables? { ["workspaceId": workspaceId] }
|
||||
|
||||
public struct Data: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.Query }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("workspace", Workspace.self, arguments: ["id": .variable("workspaceId")]),
|
||||
] }
|
||||
|
||||
/// Get workspace by id
|
||||
public var workspace: Workspace { __data["workspace"] }
|
||||
|
||||
/// Workspace
|
||||
///
|
||||
/// Parent Type: `WorkspaceType`
|
||||
public struct Workspace: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.WorkspaceType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("calendars", [Calendar].self),
|
||||
] }
|
||||
|
||||
public var calendars: [Calendar] { __data["calendars"] }
|
||||
|
||||
/// Workspace.Calendar
|
||||
///
|
||||
/// Parent Type: `WorkspaceCalendarObjectType`
|
||||
public struct Calendar: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.WorkspaceCalendarObjectType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("id", String.self),
|
||||
.field("workspaceId", String.self),
|
||||
.field("createdByUserId", String.self),
|
||||
.field("displayNameOverride", String?.self),
|
||||
.field("colorOverride", String?.self),
|
||||
.field("enabled", Bool.self),
|
||||
.field("items", [Item].self),
|
||||
] }
|
||||
|
||||
public var id: String { __data["id"] }
|
||||
public var workspaceId: String { __data["workspaceId"] }
|
||||
public var createdByUserId: String { __data["createdByUserId"] }
|
||||
public var displayNameOverride: String? { __data["displayNameOverride"] }
|
||||
public var colorOverride: String? { __data["colorOverride"] }
|
||||
public var enabled: Bool { __data["enabled"] }
|
||||
public var items: [Item] { __data["items"] }
|
||||
|
||||
/// Workspace.Calendar.Item
|
||||
///
|
||||
/// Parent Type: `WorkspaceCalendarItemObjectType`
|
||||
public struct Item: AffineGraphQL.SelectionSet {
|
||||
public let __data: DataDict
|
||||
public init(_dataDict: DataDict) { __data = _dataDict }
|
||||
|
||||
public static var __parentType: any ApolloAPI.ParentType { AffineGraphQL.Objects.WorkspaceCalendarItemObjectType }
|
||||
public static var __selections: [ApolloAPI.Selection] { [
|
||||
.field("__typename", String.self),
|
||||
.field("id", String.self),
|
||||
.field("subscriptionId", String.self),
|
||||
.field("sortOrder", Int?.self),
|
||||
.field("colorOverride", String?.self),
|
||||
.field("enabled", Bool.self),
|
||||
] }
|
||||
|
||||
public var id: String { __data["id"] }
|
||||
public var subscriptionId: String { __data["subscriptionId"] }
|
||||
public var sortOrder: Int? { __data["sortOrder"] }
|
||||
public var colorOverride: String? { __data["colorOverride"] }
|
||||
public var enabled: Bool { __data["enabled"] }
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -7,4 +7,5 @@
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public typealias JSON = JSONObject
|
||||
/// The `JSON` scalar type represents JSON values as specified by [ECMA-404](http://www.ecma-international.org/publications/files/ECMA-ST/ECMA-404.pdf).
|
||||
public typealias JSON = String
|
||||
|
||||
@@ -7,35 +7,5 @@
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public typealias JSONObject = CustomJSON
|
||||
|
||||
public enum CustomJSON: CustomScalarType, Hashable {
|
||||
case dictionary([String: AnyHashable])
|
||||
case array([AnyHashable])
|
||||
|
||||
public init(_jsonValue value: JSONValue) throws {
|
||||
if let dict = value as? [String: AnyHashable] {
|
||||
self = .dictionary(dict)
|
||||
} else if let array = value as? [AnyHashable] {
|
||||
self = .array(array)
|
||||
} else {
|
||||
throw JSONDecodingError.couldNotConvert(value: value, to: CustomJSON.self)
|
||||
}
|
||||
}
|
||||
|
||||
public var _jsonValue: JSONValue {
|
||||
switch self {
|
||||
case let .dictionary(json as AnyHashable),
|
||||
let .array(json as AnyHashable):
|
||||
json
|
||||
}
|
||||
}
|
||||
|
||||
public static func == (lhs: CustomJSON, rhs: CustomJSON) -> Bool {
|
||||
lhs._jsonValue == rhs._jsonValue
|
||||
}
|
||||
|
||||
public func hash(into hasher: inout Hasher) {
|
||||
hasher.combine(_jsonValue)
|
||||
}
|
||||
}
|
||||
/// The `JSONObject` scalar type represents JSON objects as specified by [ECMA-404](http://www.ecma-international.org/publications/files/ECMA-ST/ECMA-404.pdf).
|
||||
public typealias JSONObject = String
|
||||
|
||||
@@ -0,0 +1,14 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public enum AdminWorkspaceSort: String, EnumType {
|
||||
case blobCount = "BlobCount"
|
||||
case blobSize = "BlobSize"
|
||||
case createdAt = "CreatedAt"
|
||||
case memberCount = "MemberCount"
|
||||
case publicPageCount = "PublicPageCount"
|
||||
case snapshotCount = "SnapshotCount"
|
||||
case snapshotSize = "SnapshotSize"
|
||||
}
|
||||
@@ -0,0 +1,9 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public enum CalendarProviderType: String, EnumType {
|
||||
case calDAV = "CalDAV"
|
||||
case google = "Google"
|
||||
}
|
||||
@@ -11,20 +11,13 @@ public struct AddContextFileInput: InputObject {
|
||||
}
|
||||
|
||||
public init(
|
||||
blobId: GraphQLNullable<String> = nil,
|
||||
contextId: String
|
||||
) {
|
||||
__data = InputDict([
|
||||
"blobId": blobId,
|
||||
"contextId": contextId
|
||||
])
|
||||
}
|
||||
|
||||
public var blobId: GraphQLNullable<String> {
|
||||
get { __data["blobId"] }
|
||||
set { __data["blobId"] = newValue }
|
||||
}
|
||||
|
||||
public var contextId: String {
|
||||
get { __data["contextId"] }
|
||||
set { __data["contextId"] = newValue }
|
||||
|
||||
@@ -0,0 +1,81 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public struct AdminUpdateWorkspaceInput: InputObject {
|
||||
public private(set) var __data: InputDict
|
||||
|
||||
public init(_ data: InputDict) {
|
||||
__data = data
|
||||
}
|
||||
|
||||
public init(
|
||||
avatarKey: GraphQLNullable<String> = nil,
|
||||
enableAi: GraphQLNullable<Bool> = nil,
|
||||
enableDocEmbedding: GraphQLNullable<Bool> = nil,
|
||||
enableSharing: GraphQLNullable<Bool> = nil,
|
||||
enableUrlPreview: GraphQLNullable<Bool> = nil,
|
||||
features: GraphQLNullable<[GraphQLEnum<FeatureType>]> = nil,
|
||||
id: String,
|
||||
name: GraphQLNullable<String> = nil,
|
||||
`public`: GraphQLNullable<Bool> = nil
|
||||
) {
|
||||
__data = InputDict([
|
||||
"avatarKey": avatarKey,
|
||||
"enableAi": enableAi,
|
||||
"enableDocEmbedding": enableDocEmbedding,
|
||||
"enableSharing": enableSharing,
|
||||
"enableUrlPreview": enableUrlPreview,
|
||||
"features": features,
|
||||
"id": id,
|
||||
"name": name,
|
||||
"public": `public`
|
||||
])
|
||||
}
|
||||
|
||||
public var avatarKey: GraphQLNullable<String> {
|
||||
get { __data["avatarKey"] }
|
||||
set { __data["avatarKey"] = newValue }
|
||||
}
|
||||
|
||||
public var enableAi: GraphQLNullable<Bool> {
|
||||
get { __data["enableAi"] }
|
||||
set { __data["enableAi"] = newValue }
|
||||
}
|
||||
|
||||
public var enableDocEmbedding: GraphQLNullable<Bool> {
|
||||
get { __data["enableDocEmbedding"] }
|
||||
set { __data["enableDocEmbedding"] = newValue }
|
||||
}
|
||||
|
||||
public var enableSharing: GraphQLNullable<Bool> {
|
||||
get { __data["enableSharing"] }
|
||||
set { __data["enableSharing"] = newValue }
|
||||
}
|
||||
|
||||
public var enableUrlPreview: GraphQLNullable<Bool> {
|
||||
get { __data["enableUrlPreview"] }
|
||||
set { __data["enableUrlPreview"] = newValue }
|
||||
}
|
||||
|
||||
public var features: GraphQLNullable<[GraphQLEnum<FeatureType>]> {
|
||||
get { __data["features"] }
|
||||
set { __data["features"] = newValue }
|
||||
}
|
||||
|
||||
public var id: String {
|
||||
get { __data["id"] }
|
||||
set { __data["id"] = newValue }
|
||||
}
|
||||
|
||||
public var name: GraphQLNullable<String> {
|
||||
get { __data["name"] }
|
||||
set { __data["name"] = newValue }
|
||||
}
|
||||
|
||||
public var `public`: GraphQLNullable<Bool> {
|
||||
get { __data["public"] }
|
||||
set { __data["public"] = newValue }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,46 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public struct LinkCalDAVAccountInput: InputObject {
|
||||
public private(set) var __data: InputDict
|
||||
|
||||
public init(_ data: InputDict) {
|
||||
__data = data
|
||||
}
|
||||
|
||||
public init(
|
||||
displayName: GraphQLNullable<String> = nil,
|
||||
password: String,
|
||||
providerPresetId: String,
|
||||
username: String
|
||||
) {
|
||||
__data = InputDict([
|
||||
"displayName": displayName,
|
||||
"password": password,
|
||||
"providerPresetId": providerPresetId,
|
||||
"username": username
|
||||
])
|
||||
}
|
||||
|
||||
public var displayName: GraphQLNullable<String> {
|
||||
get { __data["displayName"] }
|
||||
set { __data["displayName"] = newValue }
|
||||
}
|
||||
|
||||
public var password: String {
|
||||
get { __data["password"] }
|
||||
set { __data["password"] = newValue }
|
||||
}
|
||||
|
||||
public var providerPresetId: String {
|
||||
get { __data["providerPresetId"] }
|
||||
set { __data["providerPresetId"] = newValue }
|
||||
}
|
||||
|
||||
public var username: String {
|
||||
get { __data["username"] }
|
||||
set { __data["username"] = newValue }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public struct LinkCalendarAccountInput: InputObject {
|
||||
public private(set) var __data: InputDict
|
||||
|
||||
public init(_ data: InputDict) {
|
||||
__data = data
|
||||
}
|
||||
|
||||
public init(
|
||||
provider: GraphQLEnum<CalendarProviderType>,
|
||||
redirectUri: GraphQLNullable<String> = nil
|
||||
) {
|
||||
__data = InputDict([
|
||||
"provider": provider,
|
||||
"redirectUri": redirectUri
|
||||
])
|
||||
}
|
||||
|
||||
public var provider: GraphQLEnum<CalendarProviderType> {
|
||||
get { __data["provider"] }
|
||||
set { __data["provider"] = newValue }
|
||||
}
|
||||
|
||||
public var redirectUri: GraphQLNullable<String> {
|
||||
get { __data["redirectUri"] }
|
||||
set { __data["redirectUri"] = newValue }
|
||||
}
|
||||
}
|
||||
@@ -11,20 +11,34 @@ public struct ListUserInput: InputObject {
|
||||
}
|
||||
|
||||
public init(
|
||||
features: GraphQLNullable<[GraphQLEnum<FeatureType>]> = nil,
|
||||
first: GraphQLNullable<Int> = nil,
|
||||
keyword: GraphQLNullable<String> = nil,
|
||||
skip: GraphQLNullable<Int> = nil
|
||||
) {
|
||||
__data = InputDict([
|
||||
"features": features,
|
||||
"first": first,
|
||||
"keyword": keyword,
|
||||
"skip": skip
|
||||
])
|
||||
}
|
||||
|
||||
public var features: GraphQLNullable<[GraphQLEnum<FeatureType>]> {
|
||||
get { __data["features"] }
|
||||
set { __data["features"] = newValue }
|
||||
}
|
||||
|
||||
public var first: GraphQLNullable<Int> {
|
||||
get { __data["first"] }
|
||||
set { __data["first"] = newValue }
|
||||
}
|
||||
|
||||
public var keyword: GraphQLNullable<String> {
|
||||
get { __data["keyword"] }
|
||||
set { __data["keyword"] = newValue }
|
||||
}
|
||||
|
||||
public var skip: GraphQLNullable<Int> {
|
||||
get { __data["skip"] }
|
||||
set { __data["skip"] = newValue }
|
||||
|
||||
@@ -0,0 +1,88 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public struct ListWorkspaceInput: InputObject {
|
||||
public private(set) var __data: InputDict
|
||||
|
||||
public init(_ data: InputDict) {
|
||||
__data = data
|
||||
}
|
||||
|
||||
public init(
|
||||
enableAi: GraphQLNullable<Bool> = nil,
|
||||
enableDocEmbedding: GraphQLNullable<Bool> = nil,
|
||||
enableSharing: GraphQLNullable<Bool> = nil,
|
||||
enableUrlPreview: GraphQLNullable<Bool> = nil,
|
||||
features: GraphQLNullable<[GraphQLEnum<FeatureType>]> = nil,
|
||||
first: Int? = nil,
|
||||
keyword: GraphQLNullable<String> = nil,
|
||||
orderBy: GraphQLNullable<GraphQLEnum<AdminWorkspaceSort>> = nil,
|
||||
`public`: GraphQLNullable<Bool> = nil,
|
||||
skip: Int? = nil
|
||||
) {
|
||||
__data = InputDict([
|
||||
"enableAi": enableAi,
|
||||
"enableDocEmbedding": enableDocEmbedding,
|
||||
"enableSharing": enableSharing,
|
||||
"enableUrlPreview": enableUrlPreview,
|
||||
"features": features,
|
||||
"first": first,
|
||||
"keyword": keyword,
|
||||
"orderBy": orderBy,
|
||||
"public": `public`,
|
||||
"skip": skip
|
||||
])
|
||||
}
|
||||
|
||||
public var enableAi: GraphQLNullable<Bool> {
|
||||
get { __data["enableAi"] }
|
||||
set { __data["enableAi"] = newValue }
|
||||
}
|
||||
|
||||
public var enableDocEmbedding: GraphQLNullable<Bool> {
|
||||
get { __data["enableDocEmbedding"] }
|
||||
set { __data["enableDocEmbedding"] = newValue }
|
||||
}
|
||||
|
||||
public var enableSharing: GraphQLNullable<Bool> {
|
||||
get { __data["enableSharing"] }
|
||||
set { __data["enableSharing"] = newValue }
|
||||
}
|
||||
|
||||
public var enableUrlPreview: GraphQLNullable<Bool> {
|
||||
get { __data["enableUrlPreview"] }
|
||||
set { __data["enableUrlPreview"] = newValue }
|
||||
}
|
||||
|
||||
public var features: GraphQLNullable<[GraphQLEnum<FeatureType>]> {
|
||||
get { __data["features"] }
|
||||
set { __data["features"] = newValue }
|
||||
}
|
||||
|
||||
public var first: Int? {
|
||||
get { __data["first"] }
|
||||
set { __data["first"] = newValue }
|
||||
}
|
||||
|
||||
public var keyword: GraphQLNullable<String> {
|
||||
get { __data["keyword"] }
|
||||
set { __data["keyword"] = newValue }
|
||||
}
|
||||
|
||||
public var orderBy: GraphQLNullable<GraphQLEnum<AdminWorkspaceSort>> {
|
||||
get { __data["orderBy"] }
|
||||
set { __data["orderBy"] = newValue }
|
||||
}
|
||||
|
||||
public var `public`: GraphQLNullable<Bool> {
|
||||
get { __data["public"] }
|
||||
set { __data["public"] = newValue }
|
||||
}
|
||||
|
||||
public var skip: Int? {
|
||||
get { __data["skip"] }
|
||||
set { __data["skip"] = newValue }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,32 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public struct UpdateWorkspaceCalendarsInput: InputObject {
|
||||
public private(set) var __data: InputDict
|
||||
|
||||
public init(_ data: InputDict) {
|
||||
__data = data
|
||||
}
|
||||
|
||||
public init(
|
||||
items: [WorkspaceCalendarItemInput],
|
||||
workspaceId: String
|
||||
) {
|
||||
__data = InputDict([
|
||||
"items": items,
|
||||
"workspaceId": workspaceId
|
||||
])
|
||||
}
|
||||
|
||||
public var items: [WorkspaceCalendarItemInput] {
|
||||
get { __data["items"] }
|
||||
set { __data["items"] = newValue }
|
||||
}
|
||||
|
||||
public var workspaceId: String {
|
||||
get { __data["workspaceId"] }
|
||||
set { __data["workspaceId"] = newValue }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,39 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public struct WorkspaceCalendarItemInput: InputObject {
|
||||
public private(set) var __data: InputDict
|
||||
|
||||
public init(_ data: InputDict) {
|
||||
__data = data
|
||||
}
|
||||
|
||||
public init(
|
||||
colorOverride: GraphQLNullable<String> = nil,
|
||||
sortOrder: GraphQLNullable<Int> = nil,
|
||||
subscriptionId: String
|
||||
) {
|
||||
__data = InputDict([
|
||||
"colorOverride": colorOverride,
|
||||
"sortOrder": sortOrder,
|
||||
"subscriptionId": subscriptionId
|
||||
])
|
||||
}
|
||||
|
||||
public var colorOverride: GraphQLNullable<String> {
|
||||
get { __data["colorOverride"] }
|
||||
set { __data["colorOverride"] = newValue }
|
||||
}
|
||||
|
||||
public var sortOrder: GraphQLNullable<Int> {
|
||||
get { __data["sortOrder"] }
|
||||
set { __data["sortOrder"] = newValue }
|
||||
}
|
||||
|
||||
public var subscriptionId: String {
|
||||
get { __data["subscriptionId"] }
|
||||
set { __data["subscriptionId"] = newValue }
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public extension Objects {
|
||||
static let AdminWorkspace = ApolloAPI.Object(
|
||||
typename: "AdminWorkspace",
|
||||
implementedInterfaces: [],
|
||||
keyFields: nil
|
||||
)
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public extension Objects {
|
||||
static let AdminWorkspaceMember = ApolloAPI.Object(
|
||||
typename: "AdminWorkspaceMember",
|
||||
implementedInterfaces: [],
|
||||
keyFields: nil
|
||||
)
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public extension Objects {
|
||||
static let AdminWorkspaceSharedLink = ApolloAPI.Object(
|
||||
typename: "AdminWorkspaceSharedLink",
|
||||
implementedInterfaces: [],
|
||||
keyFields: nil
|
||||
)
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public extension Objects {
|
||||
static let CalendarAccountObjectType = ApolloAPI.Object(
|
||||
typename: "CalendarAccountObjectType",
|
||||
implementedInterfaces: [],
|
||||
keyFields: nil
|
||||
)
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public extension Objects {
|
||||
static let CalendarCalDAVProviderPresetObjectType = ApolloAPI.Object(
|
||||
typename: "CalendarCalDAVProviderPresetObjectType",
|
||||
implementedInterfaces: [],
|
||||
keyFields: nil
|
||||
)
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public extension Objects {
|
||||
static let CalendarEventObjectType = ApolloAPI.Object(
|
||||
typename: "CalendarEventObjectType",
|
||||
implementedInterfaces: [],
|
||||
keyFields: nil
|
||||
)
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public extension Objects {
|
||||
static let CalendarSubscriptionObjectType = ApolloAPI.Object(
|
||||
typename: "CalendarSubscriptionObjectType",
|
||||
implementedInterfaces: [],
|
||||
keyFields: nil
|
||||
)
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public extension Objects {
|
||||
static let WorkspaceCalendarItemObjectType = ApolloAPI.Object(
|
||||
typename: "WorkspaceCalendarItemObjectType",
|
||||
implementedInterfaces: [],
|
||||
keyFields: nil
|
||||
)
|
||||
}
|
||||
@@ -0,0 +1,12 @@
|
||||
// @generated
|
||||
// This file was automatically generated and should not be edited.
|
||||
|
||||
import ApolloAPI
|
||||
|
||||
public extension Objects {
|
||||
static let WorkspaceCalendarObjectType = ApolloAPI.Object(
|
||||
typename: "WorkspaceCalendarObjectType",
|
||||
implementedInterfaces: [],
|
||||
keyFields: nil
|
||||
)
|
||||
}
|
||||
@@ -20,6 +20,9 @@ public enum SchemaMetadata: ApolloAPI.SchemaMetadata {
|
||||
|
||||
public static func objectType(forTypename typename: String) -> ApolloAPI.Object? {
|
||||
switch typename {
|
||||
case "AdminWorkspace": return AffineGraphQL.Objects.AdminWorkspace
|
||||
case "AdminWorkspaceMember": return AffineGraphQL.Objects.AdminWorkspaceMember
|
||||
case "AdminWorkspaceSharedLink": return AffineGraphQL.Objects.AdminWorkspaceSharedLink
|
||||
case "AggregateBucketHitsObjectType": return AffineGraphQL.Objects.AggregateBucketHitsObjectType
|
||||
case "AggregateBucketObjectType": return AffineGraphQL.Objects.AggregateBucketObjectType
|
||||
case "AggregateResultObjectType": return AffineGraphQL.Objects.AggregateResultObjectType
|
||||
@@ -27,6 +30,10 @@ public enum SchemaMetadata: ApolloAPI.SchemaMetadata {
|
||||
case "BlobUploadInit": return AffineGraphQL.Objects.BlobUploadInit
|
||||
case "BlobUploadPart": return AffineGraphQL.Objects.BlobUploadPart
|
||||
case "BlobUploadedPart": return AffineGraphQL.Objects.BlobUploadedPart
|
||||
case "CalendarAccountObjectType": return AffineGraphQL.Objects.CalendarAccountObjectType
|
||||
case "CalendarCalDAVProviderPresetObjectType": return AffineGraphQL.Objects.CalendarCalDAVProviderPresetObjectType
|
||||
case "CalendarEventObjectType": return AffineGraphQL.Objects.CalendarEventObjectType
|
||||
case "CalendarSubscriptionObjectType": return AffineGraphQL.Objects.CalendarSubscriptionObjectType
|
||||
case "ChatMessage": return AffineGraphQL.Objects.ChatMessage
|
||||
case "CommentChangeObjectType": return AffineGraphQL.Objects.CommentChangeObjectType
|
||||
case "CommentChangeObjectTypeEdge": return AffineGraphQL.Objects.CommentChangeObjectTypeEdge
|
||||
@@ -107,6 +114,8 @@ public enum SchemaMetadata: ApolloAPI.SchemaMetadata {
|
||||
case "UserQuotaUsageType": return AffineGraphQL.Objects.UserQuotaUsageType
|
||||
case "UserSettingsType": return AffineGraphQL.Objects.UserSettingsType
|
||||
case "UserType": return AffineGraphQL.Objects.UserType
|
||||
case "WorkspaceCalendarItemObjectType": return AffineGraphQL.Objects.WorkspaceCalendarItemObjectType
|
||||
case "WorkspaceCalendarObjectType": return AffineGraphQL.Objects.WorkspaceCalendarObjectType
|
||||
case "WorkspaceDocMeta": return AffineGraphQL.Objects.WorkspaceDocMeta
|
||||
case "WorkspacePermissions": return AffineGraphQL.Objects.WorkspacePermissions
|
||||
case "WorkspaceQuotaHumanReadableType": return AffineGraphQL.Objects.WorkspaceQuotaHumanReadableType
|
||||
|
||||
@@ -45,13 +45,13 @@ EXTERNAL SOURCES:
|
||||
:path: "../../../../../node_modules/capacitor-plugin-app-tracking-transparency"
|
||||
|
||||
SPEC CHECKSUMS:
|
||||
Capacitor: a5bf59e09f9dd82694fdcca4d107b4d215ac470f
|
||||
CapacitorApp: 3ddbd30ac18c321531c3da5e707b60873d89dd60
|
||||
CapacitorBrowser: 66aa8ff09cdca2a327ce464b113b470e6f667753
|
||||
Capacitor: 12914e6f1b7835e161a74ebd19cb361efa37a7dd
|
||||
CapacitorApp: 63b237168fc869e758481dba283315a85743ee78
|
||||
CapacitorBrowser: b98aa3db018a2ce4c68242d27e596c344f3b81b3
|
||||
CapacitorCordova: 31bbe4466000c6b86d9b7f1181ee286cff0205aa
|
||||
CapacitorHaptics: d17da7dd984cae34111b3f097ccd3e21f9feec62
|
||||
CapacitorKeyboard: 45cae3956a6f4fb1753f9a4df3e884aeaed8fe82
|
||||
CapacitorPluginAppTrackingTransparency: 2a2792623a5a72795f2e8f9ab3f1147573732fd8
|
||||
CapacitorHaptics: ce15be8f287fa2c61c7d2d9e958885b90cf0bebc
|
||||
CapacitorKeyboard: 5660c760113bfa48962817a785879373cf5339c3
|
||||
CapacitorPluginAppTrackingTransparency: 92ae9c1cfb5cf477753db9269689332a686f675a
|
||||
CryptoSwift: 967f37cea5a3294d9cce358f78861652155be483
|
||||
|
||||
PODFILE CHECKSUM: 2c1e4be82121f2d9724ecf7e31dd14e165aeb082
|
||||
|
||||
@@ -11,6 +11,25 @@ trap error_help ERR
|
||||
# XCode tries to be helpful and overwrites the PATH. Reset that.
|
||||
PATH="$(bash -l -c 'echo $PATH')"
|
||||
|
||||
# Resolve cargo binary: prefer ~/.cargo/bin, then PATH, then rustup
|
||||
CARGO=""
|
||||
if [ -x "$HOME/.cargo/bin/cargo" ]; then
|
||||
CARGO="$HOME/.cargo/bin/cargo"
|
||||
elif command -v cargo &>/dev/null; then
|
||||
CARGO="$(command -v cargo)"
|
||||
elif command -v rustup &>/dev/null; then
|
||||
CARGO="$(rustup which cargo 2>/dev/null)" || true
|
||||
fi
|
||||
if [ -z "$CARGO" ] || [ ! -x "$CARGO" ]; then
|
||||
echo "error: cargo not found. Install Rust via https://rustup.rs" >&2
|
||||
exit 1
|
||||
fi
|
||||
# Ensure rustc and other toolchain binaries are on PATH
|
||||
export PATH="$(dirname "$CARGO"):$PATH"
|
||||
|
||||
# Ensure IPHONEOS_DEPLOYMENT_TARGET is set for Rust/cc crate builds
|
||||
export IPHONEOS_DEPLOYMENT_TARGET="${IPHONEOS_DEPLOYMENT_TARGET:-16.5}"
|
||||
|
||||
# This should be invoked from inside xcode, not manually
|
||||
if [[ "${#}" -ne 3 ]]
|
||||
then
|
||||
@@ -47,20 +66,20 @@ for arch in $ARCHS; do
|
||||
|
||||
# Intel iOS simulator
|
||||
export CFLAGS_x86_64_apple_ios="-target x86_64-apple-ios"
|
||||
$HOME/.cargo/bin/cargo rustc -p "${FFI_TARGET}" --lib --crate-type staticlib --$RELFLAG --target x86_64-apple-ios --features use-as-lib
|
||||
$CARGO rustc -p "${FFI_TARGET}" --lib --crate-type staticlib --$RELFLAG --target x86_64-apple-ios --features use-as-lib
|
||||
;;
|
||||
|
||||
arm64)
|
||||
if [ $IS_SIMULATOR -eq 0 ]; then
|
||||
# Hardware iOS targets
|
||||
$HOME/.cargo/bin/cargo rustc -p "${FFI_TARGET}" --lib --crate-type staticlib --$RELFLAG --target aarch64-apple-ios --features use-as-lib
|
||||
$CARGO rustc -p "${FFI_TARGET}" --lib --crate-type staticlib --$RELFLAG --target aarch64-apple-ios --features use-as-lib
|
||||
cp $SRC_ROOT/../../../target/aarch64-apple-ios/${RELFLAG}/lib${FFI_TARGET}.a $SRCROOT/lib${FFI_TARGET}.a
|
||||
else
|
||||
# M1 iOS simulator
|
||||
$HOME/.cargo/bin/cargo rustc -p "${FFI_TARGET}" --lib --crate-type staticlib --$RELFLAG --target aarch64-apple-ios-sim --features use-as-lib
|
||||
$CARGO rustc -p "${FFI_TARGET}" --lib --crate-type staticlib --$RELFLAG --target aarch64-apple-ios-sim --features use-as-lib
|
||||
cp $SRC_ROOT/../../../target/aarch64-apple-ios-sim/${RELFLAG}/lib${FFI_TARGET}.a $SRCROOT/lib${FFI_TARGET}.a
|
||||
fi
|
||||
esac
|
||||
done
|
||||
|
||||
$HOME/.cargo/bin/cargo run -p affine_mobile_native --features use-as-lib --bin uniffi-bindgen generate --library $SRCROOT/lib${FFI_TARGET}.a --language swift --out-dir $SRCROOT/../../ios/App/App/uniffi
|
||||
$CARGO run -p affine_mobile_native --features use-as-lib --bin uniffi-bindgen generate --library $SRCROOT/lib${FFI_TARGET}.a --language swift --out-dir $SRCROOT/../../ios/App/App/uniffi
|
||||
|
||||
@@ -21,6 +21,7 @@ execSync(
|
||||
'cargo build -p affine_mobile_native --features use-as-lib --lib --release --target aarch64-apple-ios',
|
||||
{
|
||||
stdio: 'inherit',
|
||||
env: { ...process.env, IPHONEOS_DEPLOYMENT_TARGET: '16.5' },
|
||||
}
|
||||
);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user