@realiizlabs/admin 0.16.0 → 0.17.0

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.
@@ -747,7 +747,7 @@ function Tabs({ options, value, onChange, label = "Sections" }) {
747
747
  }
748
748
 
749
749
  // src/version.ts
750
- var ADMIN_VERSION = "0.16.0" ;
750
+ var ADMIN_VERSION = "0.17.0" ;
751
751
 
752
752
  // src/studio-ui/css.ts
753
753
  var STUDIO_CSS = `
@@ -3,7 +3,7 @@ import { ReactNode } from 'react';
3
3
  import { C as ContentTypeEntry } from '../types-DeHdasdP.cjs';
4
4
  import { c as SiteBranding, d as SiteMember } from '../members-nhbRSYyr.cjs';
5
5
  import { S as ShellUser, N as NavItem } from '../Sidebar-Cx9bvOYi.cjs';
6
- import { a as PullRequestStatus } from '../types-BP5G1myE.cjs';
6
+ import { a as PullRequestStatus } from '../types-Cy9UDz--.cjs';
7
7
  export { A as ADMIN_VERSION } from '../version-DMS0azUx.cjs';
8
8
  import 'zod';
9
9
  import '@supabase/supabase-js';
@@ -3,7 +3,7 @@ import { ReactNode } from 'react';
3
3
  import { C as ContentTypeEntry } from '../types-DeHdasdP.js';
4
4
  import { c as SiteBranding, d as SiteMember } from '../members-nhbRSYyr.js';
5
5
  import { S as ShellUser, N as NavItem } from '../Sidebar-Cx9bvOYi.js';
6
- import { a as PullRequestStatus } from '../types-BP5G1myE.js';
6
+ import { a as PullRequestStatus } from '../types-Cy9UDz--.js';
7
7
  export { A as ADMIN_VERSION } from '../version-DMS0azUx.js';
8
8
  import 'zod';
9
9
  import '@supabase/supabase-js';
@@ -741,7 +741,7 @@ function Tabs({ options, value, onChange, label = "Sections" }) {
741
741
  }
742
742
 
743
743
  // src/version.ts
744
- var ADMIN_VERSION = "0.16.0" ;
744
+ var ADMIN_VERSION = "0.17.0" ;
745
745
 
746
746
  // src/studio-ui/css.ts
747
747
  var STUDIO_CSS = `
@@ -11,11 +11,18 @@ interface RepoContext {
11
11
  owner: string;
12
12
  repo: string;
13
13
  /**
14
- * Fine-grained PAT scoped to this one repo. Required permissions (observed in
15
- * the ADMIN-01 probe): Contents RW, Pull requests RW, Commit statuses R.
16
- * Lives in the site's server env; never reaches a browser.
14
+ * One of two credentials, both server-only:
15
+ * - `app` — the Realiiz Studio GitHub App (preferred). The repo's owner installs
16
+ * the app once; Studio mints a repo-scoped installation token per hour.
17
+ * - `token` — a personal access token with Contents RW, Pull requests RW, Commit
18
+ * statuses R, Deployments R. The original mechanism; still supported.
19
+ * When both are present, `app` wins.
17
20
  */
18
- token: string;
21
+ app?: {
22
+ appId: string;
23
+ privateKey: string;
24
+ } | null;
25
+ token?: string | null;
19
26
  /** Default branch to branch from and merge into. Defaults to "main". */
20
27
  baseBranch?: string;
21
28
  }
@@ -11,11 +11,18 @@ interface RepoContext {
11
11
  owner: string;
12
12
  repo: string;
13
13
  /**
14
- * Fine-grained PAT scoped to this one repo. Required permissions (observed in
15
- * the ADMIN-01 probe): Contents RW, Pull requests RW, Commit statuses R.
16
- * Lives in the site's server env; never reaches a browser.
14
+ * One of two credentials, both server-only:
15
+ * - `app` — the Realiiz Studio GitHub App (preferred). The repo's owner installs
16
+ * the app once; Studio mints a repo-scoped installation token per hour.
17
+ * - `token` — a personal access token with Contents RW, Pull requests RW, Commit
18
+ * statuses R, Deployments R. The original mechanism; still supported.
19
+ * When both are present, `app` wins.
17
20
  */
18
- token: string;
21
+ app?: {
22
+ appId: string;
23
+ privateKey: string;
24
+ } | null;
25
+ token?: string | null;
19
26
  /** Default branch to branch from and merge into. Defaults to "main". */
20
27
  baseBranch?: string;
21
28
  }
package/package.json CHANGED
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "name": "@realiizlabs/admin",
3
- "version": "0.16.0",
3
+ "version": "0.17.0",
4
4
  "description": "Realiiz Studio — the publishing dashboard for websites built on site-starter-pro.",
5
- "releaseNotes": "Editing an item so that its file name changes (an event whose date moved) now renames the file instead of leaving the old one behind. Reference fields can be dropdowns of real items an event's venue lists the site's venues. The site name and logo at the top left are the link that opens your website; the word Studio is just a label beside it.",
5
+ "releaseNotes": "Studio can now reach a website's repository through the Realiiz Studio GitHub App instead of a personal access token: the repository's owner installs the app once, and nobody has to create or copy a token. Sites set GITHUB_APP_ID and GITHUB_APP_PRIVATE_KEY (the same two values everywhere); GITHUB_CONTENT_TOKEN keeps working as before.",
6
6
  "license": "SEE LICENSE IN LICENSE",
7
7
  "type": "module",
8
8
  "main": "./dist/index.cjs",