Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 1 addition & 11 deletions packages/patterns/array-in-cell-ast-nocomponents.tsx
Original file line number Diff line number Diff line change
@@ -1,15 +1,5 @@
/// <cts-enable />
import {
Cell,
Default,
derive,
h,
handler,
NAME,
recipe,
Stream,
UI,
} from "commontools";
import { Cell, Default, h, handler, NAME, recipe, UI } from "commontools";

interface Item {
text: Default<string, "">;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
import {
Cell,
Default,
derive,
h,
handler,
NAME,
Expand Down
12 changes: 1 addition & 11 deletions packages/patterns/array-in-cell-with-remove-editable.tsx
Original file line number Diff line number Diff line change
@@ -1,15 +1,5 @@
/// <cts-enable />
import {
Cell,
Default,
derive,
h,
handler,
NAME,
recipe,
Stream,
UI,
} from "commontools";
import { Cell, Default, h, handler, NAME, recipe, UI } from "commontools";

interface Item {
text: Default<string, "">;
Expand Down
1 change: 0 additions & 1 deletion packages/patterns/charm-ref-in-cell.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
import {
Cell,
cell,
createCell,
Default,
derive,
h,
Expand Down
1 change: 0 additions & 1 deletion packages/patterns/chatbot-list-view.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ import {
Cell,
cell,
Default,
derive,
h,
handler,
ID,
Expand Down
15 changes: 1 addition & 14 deletions packages/patterns/chatbot-note-composed.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,31 +4,18 @@ import {
Cell,
cell,
Default,
derive,
fetchData,
getRecipeEnvironment,
h,
handler,
ID,
ifElse,
JSONSchema,
lift,
llm,
llmDialog,
NAME,
navigateTo,
OpaqueRef,
recipe,
str,
Stream,
toSchema,
UI,
} from "commontools";

import Chat from "./chatbot.tsx";
import Note from "./note.tsx";
import { type BacklinksMap } from "./backlinks-index.tsx";
import Tools, {
import {
addListItem,
calculator,
ListItem,
Expand Down
10 changes: 0 additions & 10 deletions packages/patterns/chatbot-outliner.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,25 +2,15 @@
import {
BuiltInLLMMessage,
Cell,
cell,
Default,
derive,
fetchData,
getRecipeEnvironment,
h,
handler,
ID,
ifElse,
JSONSchema,
lift,
llm,
llmDialog,
NAME,
navigateTo,
OpaqueRef,
recipe,
str,
Stream,
UI,
} from "commontools";

Expand Down
5 changes: 0 additions & 5 deletions packages/patterns/chatbot.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,9 @@ import {
generateObject,
h,
handler,
ifElse,
JSONSchema,
lift,
llm,
llmDialog,
NAME,
recipe,
str,
Stream,
UI,
} from "commontools";
Expand Down
15 changes: 1 addition & 14 deletions packages/patterns/cheeseboard.tsx
Original file line number Diff line number Diff line change
@@ -1,18 +1,5 @@
/// <cts-enable />
import {
Cell,
cell,
Default,
derive,
fetchData,
h,
handler,
ifElse,
lift,
NAME,
recipe,
UI,
} from "commontools";
import { fetchData, h, lift, NAME, recipe, UI } from "commontools";

/**
* Fetch the Cheeseboard pizza schedule via Toolshed's web-read endpoint and
Expand Down
7 changes: 0 additions & 7 deletions packages/patterns/common-tools.tsx
Original file line number Diff line number Diff line change
@@ -1,20 +1,13 @@
/// <cts-enable />
import {
BuiltInLLMMessage,
BuiltInLLMTool,
Cell,
cell,
Default,
derive,
fetchData,
h,
handler,
ifElse,
llmDialog,
NAME,
recipe,
Stream,
UI,
} from "commontools";

///// COMMON TOOLS (get it?) ////
Expand Down
2 changes: 1 addition & 1 deletion packages/patterns/counter-handlers.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/// <cts-enable />
import { Cell, derive, handler } from "commontools";
import { Cell, handler } from "commontools";

export const increment = handler<
unknown,
Expand Down
10 changes: 2 additions & 8 deletions packages/patterns/counter.tsx
Original file line number Diff line number Diff line change
@@ -1,12 +1,6 @@
/// <cts-enable />
import { Default, derive, h, NAME, recipe, str, Stream, UI } from "commontools";
import {
decrement,
getValue,
increment,
nth,
previous,
} from "./counter-handlers.ts";
import { Default, h, NAME, recipe, str, Stream, UI } from "commontools";
import { decrement, increment, nth, previous } from "./counter-handlers.ts";

interface RecipeState {
value: Default<number, 0>;
Expand Down
11 changes: 1 addition & 10 deletions packages/patterns/ct-list.tsx
Original file line number Diff line number Diff line change
@@ -1,14 +1,5 @@
/// <cts-enable />
import {
Cell,
Default,
h,
handler,
NAME,
recipe,
toSchema,
UI,
} from "commontools";
import { Default, h, NAME, recipe, UI } from "commontools";

interface Item {
title: string;
Expand Down
14 changes: 1 addition & 13 deletions packages/patterns/ct-render.tsx
Original file line number Diff line number Diff line change
@@ -1,17 +1,5 @@
/// <cts-enable />
import {
Cell,
Default,
derive,
h,
handler,
NAME,
Opaque,
OpaqueRef,
recipe,
str,
UI,
} from "commontools";
import { Cell, Default, h, handler, NAME, recipe, str, UI } from "commontools";

interface RecipeState {
value: Default<number, 0>;
Expand Down
20 changes: 1 addition & 19 deletions packages/patterns/ct-select.tsx
Original file line number Diff line number Diff line change
@@ -1,24 +1,6 @@
/// <cts-enable />

import {
Cell,
cell,
compileAndRun,
Default,
derive,
h,
handler,
ifElse,
Mutable,
NAME,
navigateTo,
Opaque,
OpaqueRef,
recipe,
render,
str,
UI,
} from "commontools";
import { Default, h, NAME, OpaqueRef, recipe, UI } from "commontools";

type Input = {
selected: Default<string, "">;
Expand Down
20 changes: 1 addition & 19 deletions packages/patterns/ct-tags.tsx
Original file line number Diff line number Diff line change
@@ -1,24 +1,6 @@
/// <cts-enable />

import {
Cell,
cell,
compileAndRun,
Default,
derive,
h,
handler,
ifElse,
Mutable,
NAME,
navigateTo,
Opaque,
OpaqueRef,
recipe,
render,
str,
UI,
} from "commontools";
import { Cell, Default, h, handler, NAME, recipe, UI } from "commontools";

type Input = {
tags: string[];
Expand Down
1 change: 0 additions & 1 deletion packages/patterns/default-app.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ import {
handler,
NAME,
navigateTo,
Opaque,
OpaqueRef,
recipe,
str,
Expand Down
11 changes: 1 addition & 10 deletions packages/patterns/dice.tsx
Original file line number Diff line number Diff line change
@@ -1,14 +1,5 @@
/// <cts-enable />
import {
Default,
h,
NAME,
OpaqueRef,
recipe,
str,
Stream,
UI,
} from "commontools";
import { Default, h, NAME, recipe, Stream, UI } from "commontools";
import { getValue, roll } from "./dice-handlers.ts";

interface RecipeState {
Expand Down
5 changes: 0 additions & 5 deletions packages/patterns/fetch-data.tsx
Original file line number Diff line number Diff line change
@@ -1,17 +1,12 @@
/// <cts-enable />
import {
Cell,
cell,
Default,
derive,
fetchData,
h,
handler,
lift,
NAME,
recipe,
schema,
str,
UI,
} from "commontools";

Expand Down
1 change: 0 additions & 1 deletion packages/patterns/instantiate-recipe.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
import {
Cell,
Default,
derive,
h,
handler,
NAME,
Expand Down
3 changes: 0 additions & 3 deletions packages/patterns/list-operations.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,7 @@ import {
ID,
lift,
NAME,
Opaque,
recipe,
str,
toSchema,
UI,
} from "commontools";

Expand Down
2 changes: 1 addition & 1 deletion packages/patterns/nested-counter.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/// <cts-enable />
import { Default, derive, h, NAME, recipe, str, UI } from "commontools";
import { Default, h, NAME, recipe, str, UI } from "commontools";
import { decrement, increment, nth, previous } from "./counter-handlers.ts";

interface RecipeState {
Expand Down
1 change: 0 additions & 1 deletion packages/patterns/note.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ import {
navigateTo,
OpaqueRef,
recipe,
toSchema,
UI,
} from "commontools";
import { type BacklinksMap } from "./backlinks-index.tsx";
Expand Down
4 changes: 0 additions & 4 deletions packages/patterns/output_schema.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,10 @@
import {
Cell,
Default,
derive,
h,
handler,
NAME,
Opaque,
OpaqueRef,
recipe,
str,
UI,
VNode,
} from "commontools";
Expand Down
Loading