Skip to content

Conversation

@ellyxir
Copy link
Contributor

@ellyxir ellyxir commented Sep 12, 2025

UI to navigate to each charm created in the array


Summary by cubic

Adds a Charms Launcher pattern that stores an array of charm references in a named cell and lets users create and navigate to each charm. Addresses CT-865 by providing a persistent charm list with navigation.

  • New Features
    • New Charms Launcher recipe with a named cell (charmsArray) to store charm instances.
    • Create New Charm button adds a SimpleRecipe once per click and navigates to it.
    • Renders a list of stored charms with Go to Charm buttons for quick navigation.

@linear
Copy link

linear bot commented Sep 12, 2025

UI to navigate to each charm created in the array
properties: {
charm: { type: "object" },
cellRef: { type: "array", asCell: true },
isInitialized: { type: "boolean", asCell: true },
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

add a default: false here, and then this becomes optional as input (see other comment)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oh! there is a chance this doesn't work yet, i realize (internal: recipes treat inputs as cells by defaults, lifts as static data and i'm not sure whether we're taking the hint here correctly to make a dynamic cell, i think it might create a read-only cell)

but instead of having to do the gymnastics for the isInitalized here in the calling recipe, you could use createCell inside the lift. The static cause you provide it makes sure that you are getting the latest value on every run.

const charm = SimpleRecipe({});

// Store the charm in the array and navigate
return addCharmAndNavigate({ charm, cellRef, isInitialized });
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

by making it default false you can omit it here and so don't even need to create this cell.

@ellyxir ellyxir merged commit fe7fb56 into main Sep 12, 2025
7 checks passed
@ellyxir ellyxir deleted the ellyse/ct-865-charms-ref-in-cell branch September 12, 2025 19:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants