@plank-cms/plank 0.30.0 → 0.31.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.
@@ -12,7 +12,7 @@
12
12
  href="https://fonts.googleapis.com/css2?family=Google+Sans:ital,opsz,wght@0,17..18,400..700;1,17..18,400..700&display=swap"
13
13
  rel="stylesheet"
14
14
  />
15
- <script type="module" crossorigin src="/admin/assets/index-DAy_fJkl.js"></script>
15
+ <script type="module" crossorigin src="/admin/assets/index-BJDe4Mkj.js"></script>
16
16
  <link rel="stylesheet" crossorigin href="/admin/assets/index-CHJ8C--M.css">
17
17
  </head>
18
18
  <body>
@@ -0,0 +1,38 @@
1
+ #!/usr/bin/env node
2
+ var __create = Object.create;
3
+ var __defProp = Object.defineProperty;
4
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
+ var __getOwnPropNames = Object.getOwnPropertyNames;
6
+ var __getProtoOf = Object.getPrototypeOf;
7
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
8
+ var __require = /* @__PURE__ */ ((x) => typeof require !== "undefined" ? require : typeof Proxy !== "undefined" ? new Proxy(x, {
9
+ get: (a, b) => (typeof require !== "undefined" ? require : a)[b]
10
+ }) : x)(function(x) {
11
+ if (typeof require !== "undefined") return require.apply(this, arguments);
12
+ throw Error('Dynamic require of "' + x + '" is not supported');
13
+ });
14
+ var __commonJS = (cb, mod) => function __require2() {
15
+ return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
16
+ };
17
+ var __copyProps = (to, from, except, desc) => {
18
+ if (from && typeof from === "object" || typeof from === "function") {
19
+ for (let key of __getOwnPropNames(from))
20
+ if (!__hasOwnProp.call(to, key) && key !== except)
21
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
22
+ }
23
+ return to;
24
+ };
25
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
26
+ // If the importer is in node compatibility mode or this is not an ESM
27
+ // file that has been converted to a CommonJS file using a Babel-
28
+ // compatible transform (i.e. "__esModule" has not been set), then set
29
+ // "default" to the CommonJS "module.exports" for node compatibility.
30
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
31
+ mod
32
+ ));
33
+
34
+ export {
35
+ __require,
36
+ __commonJS,
37
+ __toESM
38
+ };
package/dist/index.js CHANGED
@@ -1,4 +1,5 @@
1
1
  #!/usr/bin/env node
2
+ import "./chunk-MO4EEYFW.js";
2
3
 
3
4
  // src/commands/init.ts
4
5
  import { intro, outro, text, spinner, note, isCancel, cancel } from "@clack/prompts";
@@ -93,7 +94,7 @@ function getUpdateScriptCommand(name) {
93
94
  }
94
95
 
95
96
  // src/commands/init.ts
96
- var PACKAGE_VERSION = "0.30.0";
97
+ var PACKAGE_VERSION = "0.31.0";
97
98
  function generateSecret() {
98
99
  return randomBytes(32).toString("hex");
99
100
  }
@@ -203,7 +204,7 @@ import { dirname, join as join3, resolve as resolve2 } from "path";
203
204
  async function start() {
204
205
  config({ path: resolve2(process.cwd(), ".env") });
205
206
  process.env.PLANK_ADMIN_DIST = join3(dirname(fileURLToPath(import.meta.url)), "admin");
206
- const { start: startServer } = await import("./server-BDQYF2ZA.js");
207
+ const { start: startServer } = await import("./server-RRA5ZKNZ.js");
207
208
  await startServer();
208
209
  }
209
210
 
@@ -0,0 +1,14 @@
1
+ CREATE TABLE IF NOT EXISTS plank_password_reset_tokens (
2
+ id TEXT PRIMARY KEY,
3
+ user_id TEXT NOT NULL REFERENCES plank_users(id) ON DELETE CASCADE,
4
+ token_hash VARCHAR(255) NOT NULL UNIQUE,
5
+ expires_at TIMESTAMP NOT NULL,
6
+ used_at TIMESTAMP,
7
+ created_at TIMESTAMP NOT NULL DEFAULT NOW()
8
+ );
9
+
10
+ CREATE INDEX IF NOT EXISTS idx_plank_password_reset_tokens_user_id
11
+ ON plank_password_reset_tokens(user_id);
12
+
13
+ CREATE INDEX IF NOT EXISTS idx_plank_password_reset_tokens_expires_at
14
+ ON plank_password_reset_tokens(expires_at);