@krak-stack/registry 0.10.15 → 0.10.16

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,65 @@
1
+ import { Effect, FileSystem, Schema } from "effect";
2
+ import { Multipart } from "effect/http";
3
+ import { HttpApiSchema } from "effect/http-api";
4
+ import { type ReactElement } from "react";
5
+ export declare const SupportReplyEmail: Schema.Trim;
6
+ export declare const SupportRequestSchema: Schema.Struct<{
7
+ readonly message: Schema.Trim;
8
+ readonly replyEmail: Schema.optionalKey<Schema.Trim>;
9
+ readonly errorDetails: Schema.optionalKey<Schema.String>;
10
+ readonly attachments: Schema.$Array<Schema.File>;
11
+ }>;
12
+ export type SupportRequest = typeof SupportRequestSchema.Type;
13
+ export declare const SupportMultipartPayload: HttpApiSchema.asMultipart<Schema.Struct<{
14
+ readonly message: Schema.Trim;
15
+ readonly replyEmail: Schema.optionalKey<Schema.Trim>;
16
+ readonly errorDetails: Schema.optionalKey<Schema.String>;
17
+ readonly attachments: Schema.optionalKey<Schema.$Array<Multipart.PersistedFileSchema>>;
18
+ }>>;
19
+ declare const InvalidSupportScreenshot_base: Schema.Class<InvalidSupportScreenshot, Schema.TaggedStruct<"InvalidSupportScreenshot", {}>, import("effect/Cause").YieldableError & {
20
+ readonly brand: unique symbol;
21
+ }>;
22
+ export declare class InvalidSupportScreenshot extends InvalidSupportScreenshot_base {
23
+ }
24
+ /** Read bounded temporary files from SupportMultipartPayload and check their signatures. */
25
+ export declare const readSupportScreenshots: (files: readonly Multipart.PersistedFile[]) => Effect.Effect<{
26
+ content: Uint8Array<ArrayBufferLike>;
27
+ contentType: string;
28
+ filename: string;
29
+ }[], InvalidSupportScreenshot | import("effect/PlatformError").PlatformError, FileSystem.FileSystem>;
30
+ export type SupportFormMessages = {
31
+ title: string;
32
+ description?: string;
33
+ placeholder?: string;
34
+ replyEmail: string;
35
+ replyEmailPlaceholder?: string;
36
+ attach: string;
37
+ invalidAttachments: string;
38
+ removeAttachment: string;
39
+ submit: string;
40
+ pending: string;
41
+ success: string;
42
+ successDescription?: string;
43
+ close: string;
44
+ invalid: string;
45
+ failed: string;
46
+ includeErrorDetails?: string;
47
+ optional?: string;
48
+ directEmail?: string;
49
+ };
50
+ export type SupportFormProps = {
51
+ locale?: string;
52
+ messages?: Partial<Record<string, Partial<SupportFormMessages>>>;
53
+ askForReplyEmail?: boolean;
54
+ defaultReplyEmail?: string;
55
+ supportEmail?: string;
56
+ errorDetails?: string;
57
+ onSubmit: (request: SupportRequest) => void | Promise<void>;
58
+ };
59
+ export declare const SupportForm: ({ locale, messages, askForReplyEmail, defaultReplyEmail, supportEmail, errorDetails, onSubmit, }: SupportFormProps) => import("react").JSX.Element;
60
+ export type SupportDialogMessages = SupportFormMessages;
61
+ export type SupportDialogProps = SupportFormProps & {
62
+ trigger?: ReactElement;
63
+ };
64
+ export declare const SupportDialog: ({ trigger, ...props }: SupportDialogProps) => import("react").JSX.Element;
65
+ export {};