@latex-kit/sign-web 0.0.0-stage → 0.6.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.
- package/LICENSE +23 -0
- package/README.md +46 -2
- package/dist/assets/index-CMd3KXBu.css +1 -0
- package/dist/assets/index-miAI7zRO.js +54 -0
- package/dist/assets/pdf.worker.min-yatZIOMy.mjs +21 -0
- package/dist/index.html +13 -0
- package/package.json +44 -4
package/LICENSE
ADDED
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
The MIT License (MIT)
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Dan Lynch <pyramation@gmail.com>
|
|
4
|
+
Copyright (c) 2026 Constructive <developers@constructive.io>
|
|
5
|
+
Copyright (c) 2020-present, Interweb, Inc.
|
|
6
|
+
|
|
7
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
8
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
9
|
+
in the Software without restriction, including without limitation the rights
|
|
10
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
11
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
12
|
+
furnished to do so, subject to the following conditions:
|
|
13
|
+
|
|
14
|
+
The above copyright notice and this permission notice shall be included in all
|
|
15
|
+
copies or substantial portions of the Software.
|
|
16
|
+
|
|
17
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
18
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
19
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
20
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
21
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
22
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
23
|
+
SOFTWARE.
|
package/README.md
CHANGED
|
@@ -1,3 +1,47 @@
|
|
|
1
|
-
#
|
|
1
|
+
# @latex-kit/sign-web
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
<p align="center" width="100%">
|
|
4
|
+
<img height="250" src="https://raw.githubusercontent.com/constructive-io/constructive/refs/heads/main/assets/outline-logo.svg" />
|
|
5
|
+
</p>
|
|
6
|
+
|
|
7
|
+
<p align="center" width="100%">
|
|
8
|
+
<a href="https://github.com/constructive-io/latex-kit/actions/workflows/ci.yml">
|
|
9
|
+
<img height="20" src="https://github.com/constructive-io/latex-kit/actions/workflows/ci.yml/badge.svg" />
|
|
10
|
+
</a>
|
|
11
|
+
<a href="https://github.com/constructive-io/latex-kit/blob/main/LICENSE">
|
|
12
|
+
<img height="20" src="https://img.shields.io/badge/license-MIT-blue.svg"/>
|
|
13
|
+
</a>
|
|
14
|
+
<a href="https://www.npmjs.com/package/@latex-kit/sign-web">
|
|
15
|
+
<img height="20" src="https://img.shields.io/npm/v/@latex-kit/sign-web.svg"/>
|
|
16
|
+
</a>
|
|
17
|
+
</p>
|
|
18
|
+
|
|
19
|
+
<p align="center">The pages @latex-kit/sign serves: signing a PDF, and drawing fields on one.</p>
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
You do not use this package directly. [`@latex-kit/sign`](https://www.npmjs.com/package/@latex-kit/sign) depends on it and serves its built files.
|
|
23
|
+
|
|
24
|
+
| Page | What |
|
|
25
|
+
|---|---|
|
|
26
|
+
| `/sign/<token>` | The signer's page: the real PDF (pdf.js) with a box on each of their spots, a signature pad, the terms popover |
|
|
27
|
+
| `/place/<key>` | Drawing fields on a PDF: drag to draw, click to drop a standard box, a popover on the selected box |
|
|
28
|
+
|
|
29
|
+
## Working on it
|
|
30
|
+
|
|
31
|
+
```sh
|
|
32
|
+
latex-kit-sign serve # the API, on 8787
|
|
33
|
+
pnpm --filter @latex-kit/sign-web dev # the pages, on 5173, passing /api to 8787
|
|
34
|
+
pnpm --filter @latex-kit/sign-web build # what gets published: dist/
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
React, built with Vite. `pnpm test` here is a type check; the behaviour is tested through the API in `@latex-kit/sign`.
|
|
38
|
+
|
|
39
|
+
## Credits
|
|
40
|
+
|
|
41
|
+
**🛠 Built by the [Constructive](https://constructive.io) team — creators of modular Postgres tooling for secure, composable backends. If you like our work, contribute on [GitHub](https://github.com/constructive-io).**
|
|
42
|
+
|
|
43
|
+
## Disclaimer
|
|
44
|
+
|
|
45
|
+
AS DESCRIBED IN THE LICENSES, THE SOFTWARE IS PROVIDED "AS IS", AT YOUR OWN RISK, AND WITHOUT WARRANTIES OF ANY KIND.
|
|
46
|
+
|
|
47
|
+
No developer or entity involved in creating this software will be liable for any claims or damages whatsoever associated with your use, inability to use, or your interaction with other users of the code, including any direct, indirect, incidental, special, exemplary, punitive or consequential damages, or loss of profits, cryptocurrencies, tokens, or anything else of value.
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
:root{--ink: #16181d;--line: #d9dce3;--paper: #f3f4f7;--accent: #1f4fd8;--mark: #ffe066;font-family:system-ui,sans-serif;color:var(--ink)}body{margin:0;background:var(--paper)}.bar{position:sticky;top:0;z-index:2;display:flex;justify-content:space-between;align-items:center;gap:12px;padding:10px 16px;background:#fff;border-bottom:1px solid var(--line)}.who{display:block;font-size:13px;color:#5b6170}.button{border:0;border-radius:6px;padding:9px 14px;background:var(--accent);color:#fff;font:inherit;font-weight:600;cursor:pointer;text-decoration:none;white-space:nowrap}.button:disabled{background:#a9b3cc;cursor:not-allowed}.status{display:block;max-width:968px;margin:12px auto 0;padding:10px 16px;font-size:14px;box-sizing:border-box}.status.ok{background:#e7f6ec;border-radius:6px}.pages{display:flex;flex-direction:column;align-items:center;gap:16px;padding:16px}.page{position:relative;background:#fff;box-shadow:0 1px 4px #0000002e}.box{position:absolute;display:flex;align-items:flex-end;padding:0 4px;border:1.5px solid #c99700;border-radius:3px;background:color-mix(in srgb,var(--mark) 55%,transparent);color:#5c4500;font:600 12px system-ui;cursor:pointer;overflow:hidden}.box.date{cursor:default}.box.filled{background:color-mix(in srgb,var(--mark) 18%,transparent);color:var(--ink);font-weight:400}.box img{height:100%}.note{max-width:520px;margin:80px auto;padding:0 16px}.veil{position:fixed;inset:0;z-index:3;display:grid;place-items:center;background:#00000073}.dialog{width:min(560px,calc(100vw - 32px));padding:16px;border-radius:10px;background:#fff}.tabs{display:flex;gap:6px;margin-bottom:10px}.tabs button,.actions button:not(.button){border:1px solid var(--line);border-radius:6px;padding:7px 12px;background:#fff;font:inherit;cursor:pointer}.tabs .on{border-color:var(--accent);color:var(--accent)}.pad{width:100%;height:180px;border:1px dashed #9aa1b1;border-radius:6px;touch-action:none}.typed{width:100%;height:100px;box-sizing:border-box;border:1px dashed #9aa1b1;border-radius:6px;padding:0 14px;color:#0a2a6b;font:italic 44px Snell Roundhand,Brush Script MT,Segoe Script,cursive}.actions{display:flex;justify-content:flex-end;gap:8px;margin-top:12px}.row{display:flex;gap:8px;align-items:center}.plain{border:1px solid var(--line);border-radius:6px;padding:8px 12px;background:#fff;font:inherit;cursor:pointer;white-space:nowrap}.terms ul{margin:0 0 8px;padding-left:20px}.terms li{margin:2px 0}.hint{margin:6px 0 0;color:#5b6170;font-size:13px}.code{width:9ch;margin-right:8px;padding:8px 10px;border:1px solid #9aa1b1;border-radius:6px;font:600 22px ui-monospace,monospace;letter-spacing:.2em}.bad{color:#b3261e}@media(max-width:640px){.bar{flex-direction:column;align-items:stretch}.row{flex-wrap:wrap}}.terms h2{margin:0 0 8px;font-size:18px}.pick{display:flex;align-items:center;gap:6px;font-size:13px}.pick select,.pick input,.popover select,.popover input{padding:6px 8px;border:1px solid var(--line);border-radius:6px;font:inherit}.page{touch-action:none}.box.placed{align-items:center;cursor:move;user-select:none}.box.selected{border-color:var(--accent);box-shadow:0 0 0 2px color-mix(in srgb,var(--accent) 35%,transparent)}.grip{position:absolute;right:0;bottom:0;width:10px;height:10px;background:var(--accent);cursor:nwse-resize}.popover{position:absolute;z-index:1;display:flex;gap:6px;padding:6px;border:1px solid var(--line);border-radius:8px;background:#fff;box-shadow:0 4px 14px #0000002e;white-space:nowrap}.popover button{border:1px solid var(--line);border-radius:6px;padding:6px 10px;background:#fff;font:inherit;color:#b3261e;cursor:pointer}.box.typed-in{align-items:center;box-sizing:border-box;cursor:text;font-family:inherit;font-weight:400;color:var(--ink)}.box.typed-in.initials{font-style:italic}.box.typed-in::placeholder{color:#5c4500;font-weight:600;font-size:12px}
|