bleam 0.0.13 → 0.0.14

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.
package/dist/ai.cjs CHANGED
@@ -4,7 +4,7 @@ require('./crypto-CT3VZ7lF.cjs');
4
4
  const require_files = require('./files-lMk-CpL_.cjs');
5
5
  const require_app_storage = require('./app-storage-D8W4n8ey.cjs');
6
6
  const require_schema = require('./schema-B7SLUBLN.cjs');
7
- const require_state = require('./state-BZYyrE2-.cjs');
7
+ const require_state = require('./state-Bm9GiRnU.cjs');
8
8
  let expo = require("expo");
9
9
  expo = require_chunk.__toESM(expo);
10
10
  let react = require("react");
package/dist/ai.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import "./files-4ZEoAWiv.js";
1
+ import "./files-VrkQlKIT.js";
2
2
 
3
3
  //#region src/ai/bonsai.d.ts
4
4
  type BonsaiTextModelId = 'ternary-bonsai-1.7b' | 'ternary-bonsai-4b' | 'ternary-bonsai-8b' | 'ternary-bonsai-27b';
package/dist/ai.js CHANGED
@@ -3,7 +3,7 @@ import "./crypto-BB92-Upx.js";
3
3
  import { a as nativeCopy, i as files } from "./files-DErLhzCB.js";
4
4
  import { t as currentAppStorageKey } from "./app-storage-Isi5Bo0R.js";
5
5
  import { c as object, s as number, u as string } from "./schema-B7ELMpuI.js";
6
- import { a as transactionAtom, d as internalJotaiWritableAtom, f as internalStore, i as queryAtom, n as atomCollection, r as mutateAtom, u as internalJotaiAtom } from "./state-DkaRFkZJ.js";
6
+ import { a as transactionAtom, d as internalJotaiWritableAtom, f as internalStore, i as queryAtom, n as atomCollection, r as mutateAtom, u as internalJotaiAtom } from "./state-D8Firo9w.js";
7
7
  import { requireNativeModule } from "expo";
8
8
  import { use, useSyncExternalStore } from "react";
9
9
 
package/dist/cli.cjs CHANGED
@@ -189,7 +189,7 @@ function parseDevOptions(argv) {
189
189
  function parseNewOptions(argv) {
190
190
  const root = invocationRoot();
191
191
  let projectRoot;
192
- let template = "text-generation";
192
+ let template = "basic";
193
193
  for (let index = 0; index < argv.length; index += 1) {
194
194
  const arg = argv[index];
195
195
  if (arg === "--help" || arg === "-h") {
package/dist/cli.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  #!/usr/bin/env node
2
- import { t as BleamAppearance } from "./config-Cms0rvqg.js";
2
+ import { t as BleamAppearance } from "./config-Chi-flpJ.js";
3
3
 
4
4
  //#region src/cli.d.ts
5
5
  interface BuildOptions {
package/dist/cli.js CHANGED
@@ -177,7 +177,7 @@ function parseDevOptions(argv) {
177
177
  function parseNewOptions(argv) {
178
178
  const root = invocationRoot();
179
179
  let projectRoot;
180
- let template = "text-generation";
180
+ let template = "basic";
181
181
  for (let index = 0; index < argv.length; index += 1) {
182
182
  const arg = argv[index];
183
183
  if (arg === "--help" || arg === "-h") {
package/dist/config.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- import { a as HexColor, c as defineConfig, i as BleamUserInterfaceStyle, n as BleamConfig, o as appConfig, r as BleamInternalExpoConfig, s as createExpoConfig, t as BleamAppearance } from "./config-Cms0rvqg.js";
1
+ import { a as HexColor, c as defineConfig, i as BleamUserInterfaceStyle, n as BleamConfig, o as appConfig, r as BleamInternalExpoConfig, s as createExpoConfig, t as BleamAppearance } from "./config-Chi-flpJ.js";
2
2
  export { BleamAppearance, BleamConfig, BleamInternalExpoConfig, BleamUserInterfaceStyle, HexColor, appConfig, createExpoConfig, defineConfig };
@@ -0,0 +1,341 @@
1
+ import * as _nativescript_react_native31 from "@nativescript/react-native";
2
+ import * as react16 from "react";
3
+ import { ReactNode } from "react";
4
+ import { ColorValue, FlatListProps, PressableProps, StyleProp, TextInputProps, TextInputSubmitEditingEvent, TextProps, TextStyle, ViewProps, ViewStyle } from "react-native";
5
+
6
+ //#region src/elements/ai-status.d.ts
7
+ type MessageStatusValue = 'queued' | 'generating' | 'canceling' | 'completed' | 'failed' | 'canceled';
8
+ type MessageRole = 'user' | 'assistant';
9
+ type MessageStatusDisplay = {
10
+ symbol: string;
11
+ label: string;
12
+ color: string;
13
+ };
14
+ type ChatSubmitStatus = 'ready' | 'queued' | 'generating' | 'canceling' | 'failed' | 'canceled' | 'not-found';
15
+ declare function messageStatusDisplay(status: MessageStatusValue): MessageStatusDisplay;
16
+ declare function promptStatusGenerating(status: ChatSubmitStatus | undefined): status is "queued" | "generating" | "canceling";
17
+ declare function promptStatusSymbol(status: ChatSubmitStatus | undefined, generating: boolean): "stop.fill" | "exclamationmark.arrow.triangle.2.circlepath" | "arrow.up";
18
+ declare function promptStatusLabel(status: ChatSubmitStatus | undefined, generating: boolean): "Stop generating" | "Send after failure" | "Send after cancellation" | "Send message";
19
+ //#endregion
20
+ //#region src/elements/shared.d.ts
21
+ type NativeStyle = ViewStyle & TextStyle;
22
+ //#endregion
23
+ //#region src/elements/blur-view.d.ts
24
+ type BlurIntensity = 'ultraThin' | 'thin' | 'regular' | 'thick' | 'chrome';
25
+ type BlurColorScheme = 'auto' | 'light' | 'dark';
26
+ type BlurViewProps = {
27
+ children?: ReactNode;
28
+ style?: StyleProp<NativeStyle>;
29
+ intensity?: BlurIntensity;
30
+ colorScheme?: BlurColorScheme;
31
+ };
32
+ declare const BlurView: _nativescript_react_native31.UIKitViewComponent<BlurViewProps, _nativescript_react_native31.UIKitContainerResult<UIVisualEffectView, UIView>>;
33
+ //#endregion
34
+ //#region src/elements/glass-shared.d.ts
35
+ type GlassStyle = 'regular' | 'clear' | 'none';
36
+ type GlassEffectStyleConfig = {
37
+ style: GlassStyle;
38
+ animate?: boolean;
39
+ animationDuration?: number;
40
+ };
41
+ type GlassVisualStyle = {
42
+ cornerRadius?: number;
43
+ borderWidth?: number;
44
+ borderColor?: ColorValue;
45
+ };
46
+ type GlassViewProps = {
47
+ children?: ReactNode;
48
+ style?: StyleProp<NativeStyle>;
49
+ glassStyle?: GlassVisualStyle;
50
+ glassEffectStyle?: GlassStyle | GlassEffectStyleConfig;
51
+ tintColor?: string;
52
+ isInteractive?: boolean;
53
+ };
54
+ type GlassContainerProps = {
55
+ children?: ReactNode;
56
+ style?: StyleProp<NativeStyle>;
57
+ glassStyle?: GlassVisualStyle;
58
+ spacing?: number;
59
+ };
60
+ //#endregion
61
+ //#region src/elements/glass-view.d.ts
62
+ declare const GlassView: _nativescript_react_native31.UIKitViewComponent<GlassViewProps, _nativescript_react_native31.UIKitContainerResult<UIVisualEffectView, UIView>>;
63
+ //#endregion
64
+ //#region src/elements/button.d.ts
65
+ type ButtonVariant = 'primary' | 'secondary' | 'plain';
66
+ type ButtonSize = 'small' | 'regular' | 'large';
67
+ type ButtonBaseProps = Omit<PressableProps, 'children' | 'disabled'> & {
68
+ label?: string;
69
+ icon?: ReactNode;
70
+ loading?: boolean;
71
+ disabled?: boolean;
72
+ size?: ButtonSize;
73
+ activeOpacity?: number;
74
+ labelStyle?: StyleProp<TextStyle>;
75
+ };
76
+ type ButtonProps = ButtonBaseProps & {
77
+ variant?: ButtonVariant;
78
+ };
79
+ type GlassButtonProps = ButtonBaseProps & Pick<GlassViewProps, 'glassEffectStyle' | 'tintColor'> & {
80
+ glassStyle?: GlassVisualStyle;
81
+ };
82
+ declare function Button({
83
+ accessibilityRole,
84
+ accessibilityState,
85
+ activeOpacity,
86
+ disabled,
87
+ icon,
88
+ label,
89
+ labelStyle,
90
+ loading,
91
+ size,
92
+ style,
93
+ variant,
94
+ ...props
95
+ }: ButtonProps): react16.JSX.Element;
96
+ declare function GlassButton({
97
+ accessibilityRole,
98
+ accessibilityState,
99
+ activeOpacity,
100
+ disabled,
101
+ glassEffectStyle,
102
+ glassStyle,
103
+ icon,
104
+ label,
105
+ labelStyle,
106
+ loading,
107
+ size,
108
+ style,
109
+ tintColor,
110
+ ...props
111
+ }: GlassButtonProps): react16.JSX.Element;
112
+ //#endregion
113
+ //#region src/elements/conversation.d.ts
114
+ type ConversationProps = ViewProps & {
115
+ followOutput?: boolean;
116
+ defaultFollowOutput?: boolean;
117
+ onFollowOutputChange?: (following: boolean) => void;
118
+ };
119
+ type ConversationContentProps<ItemT> = FlatListProps<ItemT>;
120
+ type ConversationEmptyStateProps = ViewProps & {
121
+ title?: string;
122
+ description?: string;
123
+ icon?: ReactNode;
124
+ titleStyle?: TextProps['style'];
125
+ descriptionStyle?: TextProps['style'];
126
+ };
127
+ type ConversationScrollButtonProps = Omit<PressableProps, 'onPress'> & {
128
+ accessibilityLabel?: string;
129
+ activeOpacity?: number;
130
+ onPress?: () => void;
131
+ };
132
+ type ConversationContextValue = {
133
+ followGeneration: number;
134
+ following: boolean;
135
+ isAtBottom: boolean;
136
+ updateAtBottom: (value: boolean) => void;
137
+ requestFollow: () => void;
138
+ };
139
+ declare function useConversation(): ConversationContextValue;
140
+ declare function Conversation({
141
+ children,
142
+ defaultFollowOutput,
143
+ followOutput,
144
+ onFollowOutputChange,
145
+ style,
146
+ ...props
147
+ }: ConversationProps): react16.JSX.Element;
148
+ declare function ConversationContent<ItemT>({
149
+ contentContainerStyle,
150
+ data,
151
+ keyboardShouldPersistTaps,
152
+ onContentSizeChange,
153
+ onScroll,
154
+ renderItem,
155
+ scrollEventThrottle,
156
+ ...props
157
+ }: ConversationContentProps<ItemT>): react16.JSX.Element;
158
+ declare function ConversationEmptyState({
159
+ children,
160
+ description,
161
+ descriptionStyle,
162
+ icon,
163
+ style,
164
+ title,
165
+ titleStyle,
166
+ ...props
167
+ }: ConversationEmptyStateProps): react16.JSX.Element;
168
+ declare function ConversationScrollButton({
169
+ accessibilityLabel,
170
+ activeOpacity,
171
+ children,
172
+ onPress,
173
+ style,
174
+ ...props
175
+ }: ConversationScrollButtonProps): react16.JSX.Element | null;
176
+ //#endregion
177
+ //#region src/elements/glass-container.d.ts
178
+ declare const GlassContainer: _nativescript_react_native31.UIKitViewComponent<GlassContainerProps, _nativescript_react_native31.UIKitContainerResult<UIVisualEffectView, UIView>>;
179
+ //#endregion
180
+ //#region src/elements/label.d.ts
181
+ type LabelTone = 'primary' | 'secondary' | 'tertiary';
182
+ type LabelProps = {
183
+ children?: ReactNode;
184
+ text?: string;
185
+ tone?: LabelTone;
186
+ numberOfLines?: number;
187
+ style?: StyleProp<NativeStyle>;
188
+ };
189
+ declare const Label: _nativescript_react_native31.UIKitViewComponent<LabelProps, UILabel>;
190
+ //#endregion
191
+ //#region src/elements/message.d.ts
192
+ type MessageProps = ViewProps & {
193
+ from?: 'user' | 'assistant';
194
+ };
195
+ type MessageContentProps = ViewProps;
196
+ type MessageTextProps = TextProps;
197
+ type MessageStatusProps = Omit<TextProps, 'children'> & {
198
+ status: MessageStatusValue;
199
+ label?: string;
200
+ showSymbol?: boolean;
201
+ };
202
+ type MessageActionsProps = ViewProps;
203
+ declare function Message({
204
+ children,
205
+ from,
206
+ style,
207
+ ...props
208
+ }: MessageProps): react16.JSX.Element;
209
+ declare function MessageContent({
210
+ children,
211
+ style,
212
+ ...props
213
+ }: MessageContentProps): react16.JSX.Element;
214
+ declare function MessageText({
215
+ style,
216
+ ...props
217
+ }: MessageTextProps): react16.JSX.Element;
218
+ declare function MessageStatus({
219
+ label,
220
+ showSymbol,
221
+ status,
222
+ style,
223
+ ...props
224
+ }: MessageStatusProps): react16.JSX.Element;
225
+ declare function MessageActions({
226
+ children,
227
+ style,
228
+ ...props
229
+ }: MessageActionsProps): react16.JSX.Element;
230
+ //#endregion
231
+ //#region src/elements/prompt-input.d.ts
232
+ type PromptInputMessage = {
233
+ text: string;
234
+ };
235
+ type PromptInputProps = ViewProps & {
236
+ defaultValue?: string;
237
+ disabled?: boolean;
238
+ onChangeText?: (text: string) => void;
239
+ onSubmit?: (message: PromptInputMessage) => void;
240
+ status?: ChatSubmitStatus;
241
+ value?: string;
242
+ };
243
+ type PromptInputBodyProps = ViewProps;
244
+ type PromptInputFooterProps = ViewProps;
245
+ type PromptInputHeaderProps = ViewProps;
246
+ type PromptInputToolsProps = ViewProps;
247
+ type PromptInputTextareaProps = Omit<TextInputProps, 'onSubmitEditing' | 'submitBehavior'> & {
248
+ onSubmitEditing?: (event: TextInputSubmitEditingEvent) => void;
249
+ submitOnEnter?: boolean;
250
+ };
251
+ type PromptInputSubmitProps = Omit<PressableProps, 'children' | 'onPress'> & {
252
+ activeOpacity?: number;
253
+ children?: ReactNode | ((state: {
254
+ generating: boolean;
255
+ }) => ReactNode);
256
+ generating?: boolean;
257
+ loading?: boolean;
258
+ onPress?: (message: PromptInputMessage) => void;
259
+ status?: ChatSubmitStatus;
260
+ };
261
+ type PromptInputContextValue = {
262
+ disabled: boolean;
263
+ generating: boolean;
264
+ setText: (text: string) => void;
265
+ status?: ChatSubmitStatus;
266
+ submit: () => void;
267
+ text: string;
268
+ };
269
+ declare function usePromptInput(): PromptInputContextValue;
270
+ declare function PromptInput({
271
+ children,
272
+ defaultValue,
273
+ disabled,
274
+ onChangeText,
275
+ onSubmit,
276
+ status,
277
+ style,
278
+ value,
279
+ ...props
280
+ }: PromptInputProps): react16.JSX.Element;
281
+ declare function PromptInputHeader({
282
+ children,
283
+ style,
284
+ ...props
285
+ }: PromptInputHeaderProps): react16.JSX.Element;
286
+ declare function PromptInputBody({
287
+ children,
288
+ style,
289
+ ...props
290
+ }: PromptInputBodyProps): react16.JSX.Element;
291
+ declare function PromptInputFooter({
292
+ children,
293
+ style,
294
+ ...props
295
+ }: PromptInputFooterProps): react16.JSX.Element;
296
+ declare function PromptInputTools({
297
+ children,
298
+ style,
299
+ ...props
300
+ }: PromptInputToolsProps): react16.JSX.Element;
301
+ declare function PromptInputTextarea({
302
+ multiline,
303
+ onChangeText,
304
+ onSubmitEditing,
305
+ placeholder,
306
+ placeholderTextColor,
307
+ returnKeyType,
308
+ style,
309
+ submitOnEnter,
310
+ value,
311
+ ...props
312
+ }: PromptInputTextareaProps): react16.JSX.Element;
313
+ declare function PromptInputSubmit({
314
+ accessibilityLabel,
315
+ accessibilityState,
316
+ activeOpacity,
317
+ children,
318
+ disabled: disabledProp,
319
+ generating,
320
+ loading,
321
+ onPress,
322
+ status,
323
+ style,
324
+ ...props
325
+ }: PromptInputSubmitProps): react16.JSX.Element;
326
+ //#endregion
327
+ //#region src/elements/symbol.d.ts
328
+ type SymbolName = string;
329
+ type SymbolWeight = 'ultraLight' | 'thin' | 'light' | 'regular' | 'medium' | 'semibold' | 'bold' | 'heavy' | 'black';
330
+ type SymbolScale = 'small' | 'medium' | 'large';
331
+ type SymbolProps = {
332
+ symbol: SymbolName;
333
+ size?: number;
334
+ weight?: SymbolWeight;
335
+ scale?: SymbolScale;
336
+ color?: ColorValue;
337
+ style?: StyleProp<NativeStyle>;
338
+ };
339
+ declare const SFSymbol: _nativescript_react_native31.UIKitViewComponent<SymbolProps, UIImageView>;
340
+ //#endregion
341
+ export { GlassEffectStyleConfig as $, MessageText as A, ConversationEmptyStateProps as B, MessageActions as C, MessageProps as D, MessageContentProps as E, GlassContainer as F, Button as G, ConversationScrollButton as H, Conversation as I, ButtonVariant as J, ButtonProps as K, ConversationContent as L, Label as M, LabelProps as N, MessageStatus as O, LabelTone as P, GlassContainerProps as Q, ConversationContentProps as R, Message as S, MessageContent as T, ConversationScrollButtonProps as U, ConversationProps as V, useConversation as W, GlassButtonProps as X, GlassButton as Y, GlassView as Z, PromptInputTextarea as _, SymbolWeight as a, BlurView as at, PromptInputToolsProps as b, PromptInputBodyProps as c, MessageRole as ct, PromptInputHeader as d, messageStatusDisplay as dt, GlassStyle as et, PromptInputHeaderProps as f, promptStatusGenerating as ft, PromptInputSubmitProps as g, PromptInputSubmit as h, SymbolScale as i, BlurIntensity as it, MessageTextProps as j, MessageStatusProps as k, PromptInputFooter as l, MessageStatusDisplay as lt, PromptInputProps as m, promptStatusSymbol as mt, SymbolName as n, GlassVisualStyle as nt, PromptInput as o, BlurViewProps as ot, PromptInputMessage as p, promptStatusLabel as pt, ButtonSize as q, SymbolProps as r, BlurColorScheme as rt, PromptInputBody as s, ChatSubmitStatus as st, SFSymbol as t, GlassViewProps as tt, PromptInputFooterProps as u, MessageStatusValue as ut, PromptInputTextareaProps as v, MessageActionsProps as w, usePromptInput as x, PromptInputTools as y, ConversationEmptyState as z };