create-smoodly-app 0.0.23 → 0.0.24

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/README.md CHANGED
@@ -30,7 +30,7 @@ sign in. Spec: `docs/superpowers/specs/2026-09-04-create-smoodly-app-design.md`.
30
30
  so an app that keeps its own tables in Supabase gives them a project of
31
31
  their own, or takes Smoodly Cloud for content (DESIGN.md §1).
32
32
  4. The first editor: pick an existing Auth user or create one (email +
33
- password). The `members` row is written with role `owner`, the email
33
+ password). The `members` row is written with role `admin`, the email
34
34
  beside the id.
35
35
  If `@` does not appear when you type it (macOS, `@` on Option+2 with the
36
36
  terminal's "Option as Meta" setting on), paste the address or pass
@@ -175,7 +175,7 @@ scaffolded in hosted mode against the repo stack and `next build` only.
175
175
  (done 2026-09-05, throwaway project, `sb_secret_` + `sb_publishable_`):
176
176
  `db push` of the template migration printed no NOTICE, the CLI listed and
177
177
  created the first editor through the GoTrue admin API with the secret key
178
- as the sole `apikey`, the `members` row landed with role `owner`, `next
178
+ as the sole `apikey`, the `members` row landed with role `admin`, `next
179
179
  build` passed, `/admin` served the shell, and a password sign-in with the
180
180
  publishable key returned a session. Caveat: the link step ran by hand with
181
181
  an explicit `--project-ref` (see the next-but-one item); the CLI's own
package/dist/index.js CHANGED
@@ -82,7 +82,7 @@ async function ensureEditor(client, ask) {
82
82
  const existing = await client.listUsers();
83
83
  const choice = await ask(existing);
84
84
  const user = choice.kind === "pick" ? choice.user : await client.createUser(choice.email, choice.password);
85
- await client.upsertEditor(user.id, user.email);
85
+ await client.upsertEditor(user.id, user.email, "admin");
86
86
  return user;
87
87
  }
88
88
  function clientFor(keys) {
@@ -106,8 +106,8 @@ function supabaseEditorClient(keys) {
106
106
  if (res.error) throw fail("creating the Auth user", res.error.message);
107
107
  return { id: res.data.user.id, email: res.data.user.email ?? null };
108
108
  },
109
- async upsertEditor(userId, email) {
110
- const res = await db.from("members").upsert({ user_id: userId, email, role: "owner" }, { onConflict: "space_id,user_id" });
109
+ async upsertEditor(userId, email, role) {
110
+ const res = await db.from("members").upsert({ user_id: userId, email, role }, { onConflict: "space_id,user_id" });
111
111
  if (res.error) throw fail("inserting the members row", res.error.message);
112
112
  }
113
113
  };
@@ -503,7 +503,7 @@ ${renderEnv(keys).split("\n").filter((l) => !l.startsWith("#")).join("\n").trimE
503
503
  const editorLines = [
504
504
  "Create the first editor: add a user in Supabase Studio (Authentication \u2192 Users), then in the SQL editor:",
505
505
  "",
506
- " insert into members (user_id, email, role) values ('<the user id>', '<the email>', 'owner');"
506
+ " insert into members (user_id, email, role) values ('<the user id>', '<the email>', 'admin');"
507
507
  ].join("\n");
508
508
  switch (step) {
509
509
  case "supabaseLocal":
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-smoodly-app",
3
- "version": "0.0.23",
3
+ "version": "0.0.24",
4
4
  "description": "Create a Smoodly site: a fresh Next.js app with the admin mounted, a Supabase schema, an env file and a first editor.",
5
5
  "license": "MIT",
6
6
  "repository": {
@@ -14,7 +14,7 @@
14
14
  "next": "^16.3.4",
15
15
  "react": "^19",
16
16
  "react-dom": "^19",
17
- "smoodly": "0.0.23"
17
+ "smoodly": "0.0.24"
18
18
  },
19
19
  "devDependencies": {
20
20
  "@next/env": "^16.3.4",
@@ -14,7 +14,7 @@
14
14
  "next": "^16.3.4",
15
15
  "react": "^19",
16
16
  "react-dom": "^19",
17
- "smoodly": "0.0.23",
17
+ "smoodly": "0.0.24",
18
18
  "next-intl": "^4.14.2"
19
19
  },
20
20
  "devDependencies": {
@@ -14,7 +14,7 @@
14
14
  "next": "^16.3.4",
15
15
  "react": "^19",
16
16
  "react-dom": "^19",
17
- "smoodly": "0.0.23"
17
+ "smoodly": "0.0.24"
18
18
  },
19
19
  "devDependencies": {
20
20
  "@next/env": "^16.3.4",
@@ -14,7 +14,7 @@
14
14
  "next": "^16.3.4",
15
15
  "react": "^19",
16
16
  "react-dom": "^19",
17
- "smoodly": "0.0.23",
17
+ "smoodly": "0.0.24",
18
18
  "next-intl": "^4.14.2"
19
19
  },
20
20
  "devDependencies": {