mirror of
https://github.com/aykhans/slash-e.git
synced 2025-07-02 04:01:35 +00:00
chore: initial workspace setting proto definition
This commit is contained in:
194
frontend/extension/src/types/proto/api/v2/workspace_setting_service_pb.d.ts
vendored
Normal file
194
frontend/extension/src/types/proto/api/v2/workspace_setting_service_pb.d.ts
vendored
Normal file
@ -0,0 +1,194 @@
|
||||
// @generated by protoc-gen-es v1.3.0
|
||||
// @generated from file api/v2/workspace_setting_service.proto (package slash.api.v2, syntax proto3)
|
||||
/* eslint-disable */
|
||||
// @ts-nocheck
|
||||
|
||||
import type { BinaryReadOptions, FieldList, JsonReadOptions, JsonValue, PartialMessage, PlainMessage } from "@bufbuild/protobuf";
|
||||
import { Message, proto3 } from "@bufbuild/protobuf";
|
||||
|
||||
/**
|
||||
* @generated from message slash.api.v2.WorkspaceSetting
|
||||
*/
|
||||
export declare class WorkspaceSetting extends Message<WorkspaceSetting> {
|
||||
/**
|
||||
* Whether to enable other users to sign up.
|
||||
*
|
||||
* @generated from field: bool enable_signup = 1;
|
||||
*/
|
||||
enableSignup: boolean;
|
||||
|
||||
/**
|
||||
* The relative path of the resource directory.
|
||||
*
|
||||
* @generated from field: string resource_relative_path = 2;
|
||||
*/
|
||||
resourceRelativePath: string;
|
||||
|
||||
/**
|
||||
* The auto backup setting.
|
||||
*
|
||||
* @generated from field: slash.api.v2.AutoBackupWorkspaceSetting auto_backup = 3;
|
||||
*/
|
||||
autoBackup?: AutoBackupWorkspaceSetting;
|
||||
|
||||
constructor(data?: PartialMessage<WorkspaceSetting>);
|
||||
|
||||
static readonly runtime: typeof proto3;
|
||||
static readonly typeName = "slash.api.v2.WorkspaceSetting";
|
||||
static readonly fields: FieldList;
|
||||
|
||||
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): WorkspaceSetting;
|
||||
|
||||
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): WorkspaceSetting;
|
||||
|
||||
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): WorkspaceSetting;
|
||||
|
||||
static equals(a: WorkspaceSetting | PlainMessage<WorkspaceSetting> | undefined, b: WorkspaceSetting | PlainMessage<WorkspaceSetting> | undefined): boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
* @generated from message slash.api.v2.AutoBackupWorkspaceSetting
|
||||
*/
|
||||
export declare class AutoBackupWorkspaceSetting extends Message<AutoBackupWorkspaceSetting> {
|
||||
/**
|
||||
* Whether auto backup is enabled.
|
||||
*
|
||||
* @generated from field: bool enabled = 1;
|
||||
*/
|
||||
enabled: boolean;
|
||||
|
||||
/**
|
||||
* The cron expression for auto backup.
|
||||
* For example, "0 0 0 * * *" means backup at 00:00:00 every day.
|
||||
* See https://en.wikipedia.org/wiki/Cron for more details.
|
||||
*
|
||||
* @generated from field: string cron_expression = 2;
|
||||
*/
|
||||
cronExpression: string;
|
||||
|
||||
/**
|
||||
* The maximum number of backups to keep.
|
||||
*
|
||||
* @generated from field: int32 max_keep = 3;
|
||||
*/
|
||||
maxKeep: number;
|
||||
|
||||
constructor(data?: PartialMessage<AutoBackupWorkspaceSetting>);
|
||||
|
||||
static readonly runtime: typeof proto3;
|
||||
static readonly typeName = "slash.api.v2.AutoBackupWorkspaceSetting";
|
||||
static readonly fields: FieldList;
|
||||
|
||||
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): AutoBackupWorkspaceSetting;
|
||||
|
||||
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): AutoBackupWorkspaceSetting;
|
||||
|
||||
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): AutoBackupWorkspaceSetting;
|
||||
|
||||
static equals(a: AutoBackupWorkspaceSetting | PlainMessage<AutoBackupWorkspaceSetting> | undefined, b: AutoBackupWorkspaceSetting | PlainMessage<AutoBackupWorkspaceSetting> | undefined): boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
* @generated from message slash.api.v2.GetWorkspaceSettingRequest
|
||||
*/
|
||||
export declare class GetWorkspaceSettingRequest extends Message<GetWorkspaceSettingRequest> {
|
||||
constructor(data?: PartialMessage<GetWorkspaceSettingRequest>);
|
||||
|
||||
static readonly runtime: typeof proto3;
|
||||
static readonly typeName = "slash.api.v2.GetWorkspaceSettingRequest";
|
||||
static readonly fields: FieldList;
|
||||
|
||||
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): GetWorkspaceSettingRequest;
|
||||
|
||||
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): GetWorkspaceSettingRequest;
|
||||
|
||||
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): GetWorkspaceSettingRequest;
|
||||
|
||||
static equals(a: GetWorkspaceSettingRequest | PlainMessage<GetWorkspaceSettingRequest> | undefined, b: GetWorkspaceSettingRequest | PlainMessage<GetWorkspaceSettingRequest> | undefined): boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
* @generated from message slash.api.v2.GetWorkspaceSettingResponse
|
||||
*/
|
||||
export declare class GetWorkspaceSettingResponse extends Message<GetWorkspaceSettingResponse> {
|
||||
/**
|
||||
* The user setting.
|
||||
*
|
||||
* @generated from field: slash.api.v2.WorkspaceSetting setting = 1;
|
||||
*/
|
||||
setting?: WorkspaceSetting;
|
||||
|
||||
constructor(data?: PartialMessage<GetWorkspaceSettingResponse>);
|
||||
|
||||
static readonly runtime: typeof proto3;
|
||||
static readonly typeName = "slash.api.v2.GetWorkspaceSettingResponse";
|
||||
static readonly fields: FieldList;
|
||||
|
||||
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): GetWorkspaceSettingResponse;
|
||||
|
||||
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): GetWorkspaceSettingResponse;
|
||||
|
||||
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): GetWorkspaceSettingResponse;
|
||||
|
||||
static equals(a: GetWorkspaceSettingResponse | PlainMessage<GetWorkspaceSettingResponse> | undefined, b: GetWorkspaceSettingResponse | PlainMessage<GetWorkspaceSettingResponse> | undefined): boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
* @generated from message slash.api.v2.UpdateWorkspaceSettingRequest
|
||||
*/
|
||||
export declare class UpdateWorkspaceSettingRequest extends Message<UpdateWorkspaceSettingRequest> {
|
||||
/**
|
||||
* The user setting.
|
||||
*
|
||||
* @generated from field: slash.api.v2.WorkspaceSetting setting = 1;
|
||||
*/
|
||||
setting?: WorkspaceSetting;
|
||||
|
||||
/**
|
||||
* The update mask.
|
||||
*
|
||||
* @generated from field: repeated string update_mask = 2;
|
||||
*/
|
||||
updateMask: string[];
|
||||
|
||||
constructor(data?: PartialMessage<UpdateWorkspaceSettingRequest>);
|
||||
|
||||
static readonly runtime: typeof proto3;
|
||||
static readonly typeName = "slash.api.v2.UpdateWorkspaceSettingRequest";
|
||||
static readonly fields: FieldList;
|
||||
|
||||
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): UpdateWorkspaceSettingRequest;
|
||||
|
||||
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): UpdateWorkspaceSettingRequest;
|
||||
|
||||
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): UpdateWorkspaceSettingRequest;
|
||||
|
||||
static equals(a: UpdateWorkspaceSettingRequest | PlainMessage<UpdateWorkspaceSettingRequest> | undefined, b: UpdateWorkspaceSettingRequest | PlainMessage<UpdateWorkspaceSettingRequest> | undefined): boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
* @generated from message slash.api.v2.UpdateWorkspaceSettingResponse
|
||||
*/
|
||||
export declare class UpdateWorkspaceSettingResponse extends Message<UpdateWorkspaceSettingResponse> {
|
||||
/**
|
||||
* The user setting.
|
||||
*
|
||||
* @generated from field: slash.api.v2.WorkspaceSetting setting = 1;
|
||||
*/
|
||||
setting?: WorkspaceSetting;
|
||||
|
||||
constructor(data?: PartialMessage<UpdateWorkspaceSettingResponse>);
|
||||
|
||||
static readonly runtime: typeof proto3;
|
||||
static readonly typeName = "slash.api.v2.UpdateWorkspaceSettingResponse";
|
||||
static readonly fields: FieldList;
|
||||
|
||||
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): UpdateWorkspaceSettingResponse;
|
||||
|
||||
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): UpdateWorkspaceSettingResponse;
|
||||
|
||||
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): UpdateWorkspaceSettingResponse;
|
||||
|
||||
static equals(a: UpdateWorkspaceSettingResponse | PlainMessage<UpdateWorkspaceSettingResponse> | undefined, b: UpdateWorkspaceSettingResponse | PlainMessage<UpdateWorkspaceSettingResponse> | undefined): boolean;
|
||||
}
|
||||
|
@ -0,0 +1,70 @@
|
||||
// @generated by protoc-gen-es v1.3.0
|
||||
// @generated from file api/v2/workspace_setting_service.proto (package slash.api.v2, syntax proto3)
|
||||
/* eslint-disable */
|
||||
// @ts-nocheck
|
||||
|
||||
import { proto3 } from "@bufbuild/protobuf";
|
||||
|
||||
/**
|
||||
* @generated from message slash.api.v2.WorkspaceSetting
|
||||
*/
|
||||
export const WorkspaceSetting = proto3.makeMessageType(
|
||||
"slash.api.v2.WorkspaceSetting",
|
||||
() => [
|
||||
{ no: 1, name: "enable_signup", kind: "scalar", T: 8 /* ScalarType.BOOL */ },
|
||||
{ no: 2, name: "resource_relative_path", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
||||
{ no: 3, name: "auto_backup", kind: "message", T: AutoBackupWorkspaceSetting },
|
||||
],
|
||||
);
|
||||
|
||||
/**
|
||||
* @generated from message slash.api.v2.AutoBackupWorkspaceSetting
|
||||
*/
|
||||
export const AutoBackupWorkspaceSetting = proto3.makeMessageType(
|
||||
"slash.api.v2.AutoBackupWorkspaceSetting",
|
||||
() => [
|
||||
{ no: 1, name: "enabled", kind: "scalar", T: 8 /* ScalarType.BOOL */ },
|
||||
{ no: 2, name: "cron_expression", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
||||
{ no: 3, name: "max_keep", kind: "scalar", T: 5 /* ScalarType.INT32 */ },
|
||||
],
|
||||
);
|
||||
|
||||
/**
|
||||
* @generated from message slash.api.v2.GetWorkspaceSettingRequest
|
||||
*/
|
||||
export const GetWorkspaceSettingRequest = proto3.makeMessageType(
|
||||
"slash.api.v2.GetWorkspaceSettingRequest",
|
||||
[],
|
||||
);
|
||||
|
||||
/**
|
||||
* @generated from message slash.api.v2.GetWorkspaceSettingResponse
|
||||
*/
|
||||
export const GetWorkspaceSettingResponse = proto3.makeMessageType(
|
||||
"slash.api.v2.GetWorkspaceSettingResponse",
|
||||
() => [
|
||||
{ no: 1, name: "setting", kind: "message", T: WorkspaceSetting },
|
||||
],
|
||||
);
|
||||
|
||||
/**
|
||||
* @generated from message slash.api.v2.UpdateWorkspaceSettingRequest
|
||||
*/
|
||||
export const UpdateWorkspaceSettingRequest = proto3.makeMessageType(
|
||||
"slash.api.v2.UpdateWorkspaceSettingRequest",
|
||||
() => [
|
||||
{ no: 1, name: "setting", kind: "message", T: WorkspaceSetting },
|
||||
{ no: 2, name: "update_mask", kind: "scalar", T: 9 /* ScalarType.STRING */, repeated: true },
|
||||
],
|
||||
);
|
||||
|
||||
/**
|
||||
* @generated from message slash.api.v2.UpdateWorkspaceSettingResponse
|
||||
*/
|
||||
export const UpdateWorkspaceSettingResponse = proto3.makeMessageType(
|
||||
"slash.api.v2.UpdateWorkspaceSettingResponse",
|
||||
() => [
|
||||
{ no: 1, name: "setting", kind: "message", T: WorkspaceSetting },
|
||||
],
|
||||
);
|
||||
|
@ -16,9 +16,32 @@ export declare enum WorkspaceSettingKey {
|
||||
WORKSPACE_SETTING_KEY_UNSPECIFIED = 0,
|
||||
|
||||
/**
|
||||
* @generated from enum value: WORKSPACE_SETTING_AUTO_BACKUP = 1;
|
||||
* The secret session key used to encrypt session data.
|
||||
*
|
||||
* @generated from enum value: WORKSPACE_SETTING_SECRET_SESSION = 1;
|
||||
*/
|
||||
WORKSPACE_SETTING_AUTO_BACKUP = 1,
|
||||
WORKSPACE_SETTING_SECRET_SESSION = 1,
|
||||
|
||||
/**
|
||||
* Whether to enable other users to sign up.
|
||||
*
|
||||
* @generated from enum value: WORKSAPCE_SETTING_ENABLE_SIGNUP = 2;
|
||||
*/
|
||||
WORKSAPCE_SETTING_ENABLE_SIGNUP = 2,
|
||||
|
||||
/**
|
||||
* The relative path of the resource directory.
|
||||
*
|
||||
* @generated from enum value: WORKSPACE_SETTING_RESOURCE_RELATIVE_PATH = 3;
|
||||
*/
|
||||
WORKSPACE_SETTING_RESOURCE_RELATIVE_PATH = 3,
|
||||
|
||||
/**
|
||||
* The auto backup setting.
|
||||
*
|
||||
* @generated from enum value: WORKSPACE_SETTING_AUTO_BACKUP = 4;
|
||||
*/
|
||||
WORKSPACE_SETTING_AUTO_BACKUP = 4,
|
||||
}
|
||||
|
||||
/**
|
||||
@ -35,7 +58,25 @@ export declare class WorkspaceSetting extends Message<WorkspaceSetting> {
|
||||
*/
|
||||
value: {
|
||||
/**
|
||||
* @generated from field: slash.store.AutoBackupWorkspaceSetting auto_backup = 2;
|
||||
* @generated from field: string secret_session = 2;
|
||||
*/
|
||||
value: string;
|
||||
case: "secretSession";
|
||||
} | {
|
||||
/**
|
||||
* @generated from field: bool enable_signup = 3;
|
||||
*/
|
||||
value: boolean;
|
||||
case: "enableSignup";
|
||||
} | {
|
||||
/**
|
||||
* @generated from field: string resource_relative_path = 4;
|
||||
*/
|
||||
value: string;
|
||||
case: "resourceRelativePath";
|
||||
} | {
|
||||
/**
|
||||
* @generated from field: slash.store.AutoBackupWorkspaceSetting auto_backup = 5;
|
||||
*/
|
||||
value: AutoBackupWorkspaceSetting;
|
||||
case: "autoBackup";
|
||||
|
@ -12,7 +12,10 @@ export const WorkspaceSettingKey = proto3.makeEnum(
|
||||
"slash.store.WorkspaceSettingKey",
|
||||
[
|
||||
{no: 0, name: "WORKSPACE_SETTING_KEY_UNSPECIFIED"},
|
||||
{no: 1, name: "WORKSPACE_SETTING_AUTO_BACKUP"},
|
||||
{no: 1, name: "WORKSPACE_SETTING_SECRET_SESSION"},
|
||||
{no: 2, name: "WORKSAPCE_SETTING_ENABLE_SIGNUP"},
|
||||
{no: 3, name: "WORKSPACE_SETTING_RESOURCE_RELATIVE_PATH"},
|
||||
{no: 4, name: "WORKSPACE_SETTING_AUTO_BACKUP"},
|
||||
],
|
||||
);
|
||||
|
||||
@ -23,7 +26,10 @@ export const WorkspaceSetting = proto3.makeMessageType(
|
||||
"slash.store.WorkspaceSetting",
|
||||
() => [
|
||||
{ no: 1, name: "key", kind: "enum", T: proto3.getEnumType(WorkspaceSettingKey) },
|
||||
{ no: 2, name: "auto_backup", kind: "message", T: AutoBackupWorkspaceSetting, oneof: "value" },
|
||||
{ no: 2, name: "secret_session", kind: "scalar", T: 9 /* ScalarType.STRING */, oneof: "value" },
|
||||
{ no: 3, name: "enable_signup", kind: "scalar", T: 8 /* ScalarType.BOOL */, oneof: "value" },
|
||||
{ no: 4, name: "resource_relative_path", kind: "scalar", T: 9 /* ScalarType.STRING */, oneof: "value" },
|
||||
{ no: 5, name: "auto_backup", kind: "message", T: AutoBackupWorkspaceSetting, oneof: "value" },
|
||||
],
|
||||
);
|
||||
|
||||
|
@ -1,3 +1,4 @@
|
||||
import { Divider } from "@mui/joy";
|
||||
import PreferenceSection from "@/components/setting/PreferenceSection";
|
||||
import AccessTokenSection from "../components/setting/AccessTokenSection";
|
||||
import AccountSection from "../components/setting/AccountSection";
|
||||
@ -16,6 +17,11 @@ const Setting: React.FC = () => {
|
||||
<PreferenceSection />
|
||||
{isAdmin && (
|
||||
<>
|
||||
<Divider />
|
||||
<div>
|
||||
<h2 className="text-2xl font-bold">Workspace setting</h2>
|
||||
<p className="text-gray-500 text-sm">Manage your workspace.</p>
|
||||
</div>
|
||||
<MemberSection />
|
||||
<WorkspaceSection />
|
||||
</>
|
||||
|
194
frontend/web/src/types/proto/api/v2/workspace_setting_service_pb.d.ts
vendored
Normal file
194
frontend/web/src/types/proto/api/v2/workspace_setting_service_pb.d.ts
vendored
Normal file
@ -0,0 +1,194 @@
|
||||
// @generated by protoc-gen-es v1.3.0
|
||||
// @generated from file api/v2/workspace_setting_service.proto (package slash.api.v2, syntax proto3)
|
||||
/* eslint-disable */
|
||||
// @ts-nocheck
|
||||
|
||||
import type { BinaryReadOptions, FieldList, JsonReadOptions, JsonValue, PartialMessage, PlainMessage } from "@bufbuild/protobuf";
|
||||
import { Message, proto3 } from "@bufbuild/protobuf";
|
||||
|
||||
/**
|
||||
* @generated from message slash.api.v2.WorkspaceSetting
|
||||
*/
|
||||
export declare class WorkspaceSetting extends Message<WorkspaceSetting> {
|
||||
/**
|
||||
* Whether to enable other users to sign up.
|
||||
*
|
||||
* @generated from field: bool enable_signup = 1;
|
||||
*/
|
||||
enableSignup: boolean;
|
||||
|
||||
/**
|
||||
* The relative path of the resource directory.
|
||||
*
|
||||
* @generated from field: string resource_relative_path = 2;
|
||||
*/
|
||||
resourceRelativePath: string;
|
||||
|
||||
/**
|
||||
* The auto backup setting.
|
||||
*
|
||||
* @generated from field: slash.api.v2.AutoBackupWorkspaceSetting auto_backup = 3;
|
||||
*/
|
||||
autoBackup?: AutoBackupWorkspaceSetting;
|
||||
|
||||
constructor(data?: PartialMessage<WorkspaceSetting>);
|
||||
|
||||
static readonly runtime: typeof proto3;
|
||||
static readonly typeName = "slash.api.v2.WorkspaceSetting";
|
||||
static readonly fields: FieldList;
|
||||
|
||||
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): WorkspaceSetting;
|
||||
|
||||
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): WorkspaceSetting;
|
||||
|
||||
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): WorkspaceSetting;
|
||||
|
||||
static equals(a: WorkspaceSetting | PlainMessage<WorkspaceSetting> | undefined, b: WorkspaceSetting | PlainMessage<WorkspaceSetting> | undefined): boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
* @generated from message slash.api.v2.AutoBackupWorkspaceSetting
|
||||
*/
|
||||
export declare class AutoBackupWorkspaceSetting extends Message<AutoBackupWorkspaceSetting> {
|
||||
/**
|
||||
* Whether auto backup is enabled.
|
||||
*
|
||||
* @generated from field: bool enabled = 1;
|
||||
*/
|
||||
enabled: boolean;
|
||||
|
||||
/**
|
||||
* The cron expression for auto backup.
|
||||
* For example, "0 0 0 * * *" means backup at 00:00:00 every day.
|
||||
* See https://en.wikipedia.org/wiki/Cron for more details.
|
||||
*
|
||||
* @generated from field: string cron_expression = 2;
|
||||
*/
|
||||
cronExpression: string;
|
||||
|
||||
/**
|
||||
* The maximum number of backups to keep.
|
||||
*
|
||||
* @generated from field: int32 max_keep = 3;
|
||||
*/
|
||||
maxKeep: number;
|
||||
|
||||
constructor(data?: PartialMessage<AutoBackupWorkspaceSetting>);
|
||||
|
||||
static readonly runtime: typeof proto3;
|
||||
static readonly typeName = "slash.api.v2.AutoBackupWorkspaceSetting";
|
||||
static readonly fields: FieldList;
|
||||
|
||||
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): AutoBackupWorkspaceSetting;
|
||||
|
||||
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): AutoBackupWorkspaceSetting;
|
||||
|
||||
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): AutoBackupWorkspaceSetting;
|
||||
|
||||
static equals(a: AutoBackupWorkspaceSetting | PlainMessage<AutoBackupWorkspaceSetting> | undefined, b: AutoBackupWorkspaceSetting | PlainMessage<AutoBackupWorkspaceSetting> | undefined): boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
* @generated from message slash.api.v2.GetWorkspaceSettingRequest
|
||||
*/
|
||||
export declare class GetWorkspaceSettingRequest extends Message<GetWorkspaceSettingRequest> {
|
||||
constructor(data?: PartialMessage<GetWorkspaceSettingRequest>);
|
||||
|
||||
static readonly runtime: typeof proto3;
|
||||
static readonly typeName = "slash.api.v2.GetWorkspaceSettingRequest";
|
||||
static readonly fields: FieldList;
|
||||
|
||||
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): GetWorkspaceSettingRequest;
|
||||
|
||||
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): GetWorkspaceSettingRequest;
|
||||
|
||||
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): GetWorkspaceSettingRequest;
|
||||
|
||||
static equals(a: GetWorkspaceSettingRequest | PlainMessage<GetWorkspaceSettingRequest> | undefined, b: GetWorkspaceSettingRequest | PlainMessage<GetWorkspaceSettingRequest> | undefined): boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
* @generated from message slash.api.v2.GetWorkspaceSettingResponse
|
||||
*/
|
||||
export declare class GetWorkspaceSettingResponse extends Message<GetWorkspaceSettingResponse> {
|
||||
/**
|
||||
* The user setting.
|
||||
*
|
||||
* @generated from field: slash.api.v2.WorkspaceSetting setting = 1;
|
||||
*/
|
||||
setting?: WorkspaceSetting;
|
||||
|
||||
constructor(data?: PartialMessage<GetWorkspaceSettingResponse>);
|
||||
|
||||
static readonly runtime: typeof proto3;
|
||||
static readonly typeName = "slash.api.v2.GetWorkspaceSettingResponse";
|
||||
static readonly fields: FieldList;
|
||||
|
||||
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): GetWorkspaceSettingResponse;
|
||||
|
||||
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): GetWorkspaceSettingResponse;
|
||||
|
||||
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): GetWorkspaceSettingResponse;
|
||||
|
||||
static equals(a: GetWorkspaceSettingResponse | PlainMessage<GetWorkspaceSettingResponse> | undefined, b: GetWorkspaceSettingResponse | PlainMessage<GetWorkspaceSettingResponse> | undefined): boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
* @generated from message slash.api.v2.UpdateWorkspaceSettingRequest
|
||||
*/
|
||||
export declare class UpdateWorkspaceSettingRequest extends Message<UpdateWorkspaceSettingRequest> {
|
||||
/**
|
||||
* The user setting.
|
||||
*
|
||||
* @generated from field: slash.api.v2.WorkspaceSetting setting = 1;
|
||||
*/
|
||||
setting?: WorkspaceSetting;
|
||||
|
||||
/**
|
||||
* The update mask.
|
||||
*
|
||||
* @generated from field: repeated string update_mask = 2;
|
||||
*/
|
||||
updateMask: string[];
|
||||
|
||||
constructor(data?: PartialMessage<UpdateWorkspaceSettingRequest>);
|
||||
|
||||
static readonly runtime: typeof proto3;
|
||||
static readonly typeName = "slash.api.v2.UpdateWorkspaceSettingRequest";
|
||||
static readonly fields: FieldList;
|
||||
|
||||
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): UpdateWorkspaceSettingRequest;
|
||||
|
||||
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): UpdateWorkspaceSettingRequest;
|
||||
|
||||
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): UpdateWorkspaceSettingRequest;
|
||||
|
||||
static equals(a: UpdateWorkspaceSettingRequest | PlainMessage<UpdateWorkspaceSettingRequest> | undefined, b: UpdateWorkspaceSettingRequest | PlainMessage<UpdateWorkspaceSettingRequest> | undefined): boolean;
|
||||
}
|
||||
|
||||
/**
|
||||
* @generated from message slash.api.v2.UpdateWorkspaceSettingResponse
|
||||
*/
|
||||
export declare class UpdateWorkspaceSettingResponse extends Message<UpdateWorkspaceSettingResponse> {
|
||||
/**
|
||||
* The user setting.
|
||||
*
|
||||
* @generated from field: slash.api.v2.WorkspaceSetting setting = 1;
|
||||
*/
|
||||
setting?: WorkspaceSetting;
|
||||
|
||||
constructor(data?: PartialMessage<UpdateWorkspaceSettingResponse>);
|
||||
|
||||
static readonly runtime: typeof proto3;
|
||||
static readonly typeName = "slash.api.v2.UpdateWorkspaceSettingResponse";
|
||||
static readonly fields: FieldList;
|
||||
|
||||
static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): UpdateWorkspaceSettingResponse;
|
||||
|
||||
static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): UpdateWorkspaceSettingResponse;
|
||||
|
||||
static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): UpdateWorkspaceSettingResponse;
|
||||
|
||||
static equals(a: UpdateWorkspaceSettingResponse | PlainMessage<UpdateWorkspaceSettingResponse> | undefined, b: UpdateWorkspaceSettingResponse | PlainMessage<UpdateWorkspaceSettingResponse> | undefined): boolean;
|
||||
}
|
||||
|
@ -0,0 +1,70 @@
|
||||
// @generated by protoc-gen-es v1.3.0
|
||||
// @generated from file api/v2/workspace_setting_service.proto (package slash.api.v2, syntax proto3)
|
||||
/* eslint-disable */
|
||||
// @ts-nocheck
|
||||
|
||||
import { proto3 } from "@bufbuild/protobuf";
|
||||
|
||||
/**
|
||||
* @generated from message slash.api.v2.WorkspaceSetting
|
||||
*/
|
||||
export const WorkspaceSetting = proto3.makeMessageType(
|
||||
"slash.api.v2.WorkspaceSetting",
|
||||
() => [
|
||||
{ no: 1, name: "enable_signup", kind: "scalar", T: 8 /* ScalarType.BOOL */ },
|
||||
{ no: 2, name: "resource_relative_path", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
||||
{ no: 3, name: "auto_backup", kind: "message", T: AutoBackupWorkspaceSetting },
|
||||
],
|
||||
);
|
||||
|
||||
/**
|
||||
* @generated from message slash.api.v2.AutoBackupWorkspaceSetting
|
||||
*/
|
||||
export const AutoBackupWorkspaceSetting = proto3.makeMessageType(
|
||||
"slash.api.v2.AutoBackupWorkspaceSetting",
|
||||
() => [
|
||||
{ no: 1, name: "enabled", kind: "scalar", T: 8 /* ScalarType.BOOL */ },
|
||||
{ no: 2, name: "cron_expression", kind: "scalar", T: 9 /* ScalarType.STRING */ },
|
||||
{ no: 3, name: "max_keep", kind: "scalar", T: 5 /* ScalarType.INT32 */ },
|
||||
],
|
||||
);
|
||||
|
||||
/**
|
||||
* @generated from message slash.api.v2.GetWorkspaceSettingRequest
|
||||
*/
|
||||
export const GetWorkspaceSettingRequest = proto3.makeMessageType(
|
||||
"slash.api.v2.GetWorkspaceSettingRequest",
|
||||
[],
|
||||
);
|
||||
|
||||
/**
|
||||
* @generated from message slash.api.v2.GetWorkspaceSettingResponse
|
||||
*/
|
||||
export const GetWorkspaceSettingResponse = proto3.makeMessageType(
|
||||
"slash.api.v2.GetWorkspaceSettingResponse",
|
||||
() => [
|
||||
{ no: 1, name: "setting", kind: "message", T: WorkspaceSetting },
|
||||
],
|
||||
);
|
||||
|
||||
/**
|
||||
* @generated from message slash.api.v2.UpdateWorkspaceSettingRequest
|
||||
*/
|
||||
export const UpdateWorkspaceSettingRequest = proto3.makeMessageType(
|
||||
"slash.api.v2.UpdateWorkspaceSettingRequest",
|
||||
() => [
|
||||
{ no: 1, name: "setting", kind: "message", T: WorkspaceSetting },
|
||||
{ no: 2, name: "update_mask", kind: "scalar", T: 9 /* ScalarType.STRING */, repeated: true },
|
||||
],
|
||||
);
|
||||
|
||||
/**
|
||||
* @generated from message slash.api.v2.UpdateWorkspaceSettingResponse
|
||||
*/
|
||||
export const UpdateWorkspaceSettingResponse = proto3.makeMessageType(
|
||||
"slash.api.v2.UpdateWorkspaceSettingResponse",
|
||||
() => [
|
||||
{ no: 1, name: "setting", kind: "message", T: WorkspaceSetting },
|
||||
],
|
||||
);
|
||||
|
@ -16,9 +16,32 @@ export declare enum WorkspaceSettingKey {
|
||||
WORKSPACE_SETTING_KEY_UNSPECIFIED = 0,
|
||||
|
||||
/**
|
||||
* @generated from enum value: WORKSPACE_SETTING_AUTO_BACKUP = 1;
|
||||
* The secret session key used to encrypt session data.
|
||||
*
|
||||
* @generated from enum value: WORKSPACE_SETTING_SECRET_SESSION = 1;
|
||||
*/
|
||||
WORKSPACE_SETTING_AUTO_BACKUP = 1,
|
||||
WORKSPACE_SETTING_SECRET_SESSION = 1,
|
||||
|
||||
/**
|
||||
* Whether to enable other users to sign up.
|
||||
*
|
||||
* @generated from enum value: WORKSAPCE_SETTING_ENABLE_SIGNUP = 2;
|
||||
*/
|
||||
WORKSAPCE_SETTING_ENABLE_SIGNUP = 2,
|
||||
|
||||
/**
|
||||
* The relative path of the resource directory.
|
||||
*
|
||||
* @generated from enum value: WORKSPACE_SETTING_RESOURCE_RELATIVE_PATH = 3;
|
||||
*/
|
||||
WORKSPACE_SETTING_RESOURCE_RELATIVE_PATH = 3,
|
||||
|
||||
/**
|
||||
* The auto backup setting.
|
||||
*
|
||||
* @generated from enum value: WORKSPACE_SETTING_AUTO_BACKUP = 4;
|
||||
*/
|
||||
WORKSPACE_SETTING_AUTO_BACKUP = 4,
|
||||
}
|
||||
|
||||
/**
|
||||
@ -35,7 +58,25 @@ export declare class WorkspaceSetting extends Message<WorkspaceSetting> {
|
||||
*/
|
||||
value: {
|
||||
/**
|
||||
* @generated from field: slash.store.AutoBackupWorkspaceSetting auto_backup = 2;
|
||||
* @generated from field: string secret_session = 2;
|
||||
*/
|
||||
value: string;
|
||||
case: "secretSession";
|
||||
} | {
|
||||
/**
|
||||
* @generated from field: bool enable_signup = 3;
|
||||
*/
|
||||
value: boolean;
|
||||
case: "enableSignup";
|
||||
} | {
|
||||
/**
|
||||
* @generated from field: string resource_relative_path = 4;
|
||||
*/
|
||||
value: string;
|
||||
case: "resourceRelativePath";
|
||||
} | {
|
||||
/**
|
||||
* @generated from field: slash.store.AutoBackupWorkspaceSetting auto_backup = 5;
|
||||
*/
|
||||
value: AutoBackupWorkspaceSetting;
|
||||
case: "autoBackup";
|
||||
|
@ -12,7 +12,10 @@ export const WorkspaceSettingKey = proto3.makeEnum(
|
||||
"slash.store.WorkspaceSettingKey",
|
||||
[
|
||||
{no: 0, name: "WORKSPACE_SETTING_KEY_UNSPECIFIED"},
|
||||
{no: 1, name: "WORKSPACE_SETTING_AUTO_BACKUP"},
|
||||
{no: 1, name: "WORKSPACE_SETTING_SECRET_SESSION"},
|
||||
{no: 2, name: "WORKSAPCE_SETTING_ENABLE_SIGNUP"},
|
||||
{no: 3, name: "WORKSPACE_SETTING_RESOURCE_RELATIVE_PATH"},
|
||||
{no: 4, name: "WORKSPACE_SETTING_AUTO_BACKUP"},
|
||||
],
|
||||
);
|
||||
|
||||
@ -23,7 +26,10 @@ export const WorkspaceSetting = proto3.makeMessageType(
|
||||
"slash.store.WorkspaceSetting",
|
||||
() => [
|
||||
{ no: 1, name: "key", kind: "enum", T: proto3.getEnumType(WorkspaceSettingKey) },
|
||||
{ no: 2, name: "auto_backup", kind: "message", T: AutoBackupWorkspaceSetting, oneof: "value" },
|
||||
{ no: 2, name: "secret_session", kind: "scalar", T: 9 /* ScalarType.STRING */, oneof: "value" },
|
||||
{ no: 3, name: "enable_signup", kind: "scalar", T: 8 /* ScalarType.BOOL */, oneof: "value" },
|
||||
{ no: 4, name: "resource_relative_path", kind: "scalar", T: 9 /* ScalarType.STRING */, oneof: "value" },
|
||||
{ no: 5, name: "auto_backup", kind: "message", T: AutoBackupWorkspaceSetting, oneof: "value" },
|
||||
],
|
||||
);
|
||||
|
||||
|
Reference in New Issue
Block a user