Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
breadchris committed Mar 20, 2024
1 parent 14b3e53 commit dc6db1d
Show file tree
Hide file tree
Showing 53 changed files with 2,725 additions and 1,924 deletions.
4 changes: 2 additions & 2 deletions js/dist/extension/background.js

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions js/dist/extension/background.js.map

Large diffs are not rendered by default.

16 changes: 8 additions & 8 deletions js/dist/extension/content.js

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions js/dist/extension/content.js.map

Large diffs are not rendered by default.

28 changes: 14 additions & 14 deletions js/dist/extension/options.js

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions js/dist/extension/options.js.map

Large diffs are not rendered by default.

60 changes: 30 additions & 30 deletions js/dist/extension/tab.js

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions js/dist/extension/tab.js.map

Large diffs are not rendered by default.

192 changes: 96 additions & 96 deletions js/dist/site/index.js

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions js/dist/site/index.js.map

Large diffs are not rendered by default.

86 changes: 86 additions & 0 deletions js/rpc/content/content_pb.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,92 @@ import { Conversation } from "./chatgpt/conversation_pb.js";
import { History } from "./browser/history_pb.js";
import { HugoConfig, MenuItem } from "./blog_pb.js";

/**
* @generated from message content.YouTubeVideoResponse
*/
export class YouTubeVideoResponse extends Message<YouTubeVideoResponse> {
/**
* @generated from field: string title = 1;
*/
title = "";

/**
* @generated from field: content.FilePath file_path = 2;
*/
filePath?: FilePath;

/**
* @generated from field: repeated content.Segment transcript = 3;
*/
transcript: Segment[] = [];

constructor(data?: PartialMessage<YouTubeVideoResponse>) {
super();
proto3.util.initPartial(data, this);
}

static readonly runtime: typeof proto3 = proto3;
static readonly typeName = "content.YouTubeVideoResponse";
static readonly fields: FieldList = proto3.util.newFieldList(() => [
{ no: 1, name: "title", kind: "scalar", T: 9 /* ScalarType.STRING */ },
{ no: 2, name: "file_path", kind: "message", T: FilePath },
{ no: 3, name: "transcript", kind: "message", T: Segment, repeated: true },
]);

static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): YouTubeVideoResponse {
return new YouTubeVideoResponse().fromBinary(bytes, options);
}

static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): YouTubeVideoResponse {
return new YouTubeVideoResponse().fromJson(jsonValue, options);
}

static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): YouTubeVideoResponse {
return new YouTubeVideoResponse().fromJsonString(jsonString, options);
}

static equals(a: YouTubeVideoResponse | PlainMessage<YouTubeVideoResponse> | undefined, b: YouTubeVideoResponse | PlainMessage<YouTubeVideoResponse> | undefined): boolean {
return proto3.util.equals(YouTubeVideoResponse, a, b);
}
}

/**
* @generated from message content.FilePath
*/
export class FilePath extends Message<FilePath> {
/**
* @generated from field: string file = 1;
*/
file = "";

constructor(data?: PartialMessage<FilePath>) {
super();
proto3.util.initPartial(data, this);
}

static readonly runtime: typeof proto3 = proto3;
static readonly typeName = "content.FilePath";
static readonly fields: FieldList = proto3.util.newFieldList(() => [
{ no: 1, name: "file", kind: "scalar", T: 9 /* ScalarType.STRING */ },
]);

static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): FilePath {
return new FilePath().fromBinary(bytes, options);
}

static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): FilePath {
return new FilePath().fromJson(jsonValue, options);
}

static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): FilePath {
return new FilePath().fromJsonString(jsonString, options);
}

static equals(a: FilePath | PlainMessage<FilePath> | undefined, b: FilePath | PlainMessage<FilePath> | undefined): boolean {
return proto3.util.equals(FilePath, a, b);
}
}

/**
* @generated from message content.InferRequest
*/
Expand Down
11 changes: 1 addition & 10 deletions js/rpc/protoflow_connect.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
/* eslint-disable */
// @ts-nocheck

import { AnalyzeConversationRequest, ChatRequest, ChatResponse, ConvertFileRequest, DeleteSessionRequest, FilePath, GenerateImagesRequest, GenerateImagesResponse, GetPromptsRequest, GetPromptsResponse, GetSessionRequest, GetSessionResponse, GetSessionsRequest, GetSessionsResponse, InferRequest, InferResponse, Prompt, UploadContentRequest, YouTubeVideo, YouTubeVideoResponse } from "./protoflow_pb.js";
import { AnalyzeConversationRequest, ChatRequest, ChatResponse, ConvertFileRequest, DeleteSessionRequest, FilePath, GenerateImagesRequest, GenerateImagesResponse, GetPromptsRequest, GetPromptsResponse, GetSessionRequest, GetSessionResponse, GetSessionsRequest, GetSessionsResponse, InferRequest, InferResponse, Prompt, YouTubeVideo, YouTubeVideoResponse } from "./protoflow_pb.js";
import { Empty, MethodKind } from "@bufbuild/protobuf";
import { AnalyzeConversationResponse } from "./ai_pb.js";

Expand Down Expand Up @@ -67,15 +67,6 @@ export const ProtoflowService = {
O: Prompt,
kind: MethodKind.Unary,
},
/**
* @generated from rpc protoflow.ProtoflowService.UploadContent
*/
uploadContent: {
name: "UploadContent",
I: UploadContentRequest,
O: ChatResponse,
kind: MethodKind.ServerStreaming,
},
/**
* @generated from rpc protoflow.ProtoflowService.Infer
*/
Expand Down
81 changes: 0 additions & 81 deletions js/rpc/protoflow_pb.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@

import type { BinaryReadOptions, FieldList, JsonReadOptions, JsonValue, PartialMessage, PlainMessage } from "@bufbuild/protobuf";
import { Message, proto3, protoInt64 } from "@bufbuild/protobuf";
import { Content, Segment as Segment$1 } from "./content/content_pb.js";

/**
* @generated from message protoflow.AnalyzeConversationRequest
Expand Down Expand Up @@ -346,80 +345,6 @@ export class InferResponse extends Message<InferResponse> {
}
}

/**
* @generated from message protoflow.UploadContentRequest
*/
export class UploadContentRequest extends Message<UploadContentRequest> {
/**
* @generated from field: content.Content content = 1;
*/
content?: Content;

constructor(data?: PartialMessage<UploadContentRequest>) {
super();
proto3.util.initPartial(data, this);
}

static readonly runtime: typeof proto3 = proto3;
static readonly typeName = "protoflow.UploadContentRequest";
static readonly fields: FieldList = proto3.util.newFieldList(() => [
{ no: 1, name: "content", kind: "message", T: Content },
]);

static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): UploadContentRequest {
return new UploadContentRequest().fromBinary(bytes, options);
}

static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): UploadContentRequest {
return new UploadContentRequest().fromJson(jsonValue, options);
}

static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): UploadContentRequest {
return new UploadContentRequest().fromJsonString(jsonString, options);
}

static equals(a: UploadContentRequest | PlainMessage<UploadContentRequest> | undefined, b: UploadContentRequest | PlainMessage<UploadContentRequest> | undefined): boolean {
return proto3.util.equals(UploadContentRequest, a, b);
}
}

/**
* @generated from message protoflow.UploadContentResponse
*/
export class UploadContentResponse extends Message<UploadContentResponse> {
/**
* @generated from field: string id = 1;
*/
id = "";

constructor(data?: PartialMessage<UploadContentResponse>) {
super();
proto3.util.initPartial(data, this);
}

static readonly runtime: typeof proto3 = proto3;
static readonly typeName = "protoflow.UploadContentResponse";
static readonly fields: FieldList = proto3.util.newFieldList(() => [
{ no: 1, name: "id", kind: "scalar", T: 9 /* ScalarType.STRING */ },
]);

static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): UploadContentResponse {
return new UploadContentResponse().fromBinary(bytes, options);
}

static fromJson(jsonValue: JsonValue, options?: Partial<JsonReadOptions>): UploadContentResponse {
return new UploadContentResponse().fromJson(jsonValue, options);
}

static fromJsonString(jsonString: string, options?: Partial<JsonReadOptions>): UploadContentResponse {
return new UploadContentResponse().fromJsonString(jsonString, options);
}

static equals(a: UploadContentResponse | PlainMessage<UploadContentResponse> | undefined, b: UploadContentResponse | PlainMessage<UploadContentResponse> | undefined): boolean {
return proto3.util.equals(UploadContentResponse, a, b);
}
}

/**
* @generated from message protoflow.GetSessionRequest
*/
Expand Down Expand Up @@ -1202,11 +1127,6 @@ export class YouTubeVideoResponse extends Message<YouTubeVideoResponse> {
*/
filePath?: FilePath;

/**
* @generated from field: repeated content.Segment transcript = 3;
*/
transcript: Segment$1[] = [];

constructor(data?: PartialMessage<YouTubeVideoResponse>) {
super();
proto3.util.initPartial(data, this);
Expand All @@ -1217,7 +1137,6 @@ export class YouTubeVideoResponse extends Message<YouTubeVideoResponse> {
static readonly fields: FieldList = proto3.util.newFieldList(() => [
{ no: 1, name: "title", kind: "scalar", T: 9 /* ScalarType.STRING */ },
{ no: 2, name: "file_path", kind: "message", T: FilePath },
{ no: 3, name: "transcript", kind: "message", T: Segment$1, repeated: true },
]);

static fromBinary(bytes: Uint8Array, options?: Partial<BinaryReadOptions>): YouTubeVideoResponse {
Expand Down
10 changes: 10 additions & 0 deletions js/site/auth/AuthForm.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import {useAuth} from "@/auth/state";
export const AuthForm: React.FC<{ next?: string, allowRegister?: boolean }> = ({ next, allowRegister }) => {
const [email, setEmail] = useState('');
const [password, setPassword] = useState('');
const [username, setUsername] = useState('');
const { login, register } = useAuth();

// TODO breadchris make tab component that wraps https://daisyui.com/components/tab/#radio-tab-bordered--tab-content
Expand All @@ -29,6 +30,15 @@ export const AuthForm: React.FC<{ next?: string, allowRegister?: boolean }> = ({
)}
</div>
<div className={"space-y-2 w-full mx-auto my-6"}>
{selectedTab === 'register' && (
<input
className="input input-bordered w-full"
type="text"
placeholder="username"
value={username}
onChange={(e) => setUsername(e.target.value)}
/>
)}
<input
className="input input-bordered w-full"
type="email"
Expand Down
Loading

0 comments on commit dc6db1d

Please sign in to comment.