3import { sqlite } from "https://esm.town/v/std/sqlite";
4
5export default async function(req: Request): Promise<Response> {
6 const TABLE_NAME = "lab_login_users_with_times";
7 const body = await req.json();
3import { sqlite } from "https://esm.town/v/std/sqlite";
4
5export default async function(req: Request): Promise<Response> {
6 const body = await req.json();
7 let { username, password } = body;
10import { basicAuth } from "https://esm.town/v/pomdtr/basicAuth";
11
12function handler(req: Request) {
13 return new Response("You are authenticated!");
14}
23import { verifyToken } from "https://www.val.town/v/pomdtr/verifyToken"
24
25function handler(req: Request) {
26 return new Response("You are authenticated!");
27}
1function extractCredentials(authorization) {
2 const parts = authorization.split(" ");
3 if (parts[0] != "Basic") {
11export type ServeHandler = (req: Request) => Response | Promise<Response>
12
13export function basicAuth(next: ServeHandler, params: {
14 verifyUser: (username: string, password: string) => boolean | Promise<boolean>;
15}): ServeHandler {
8}
9
10export default async function server(request: Request): Promise<Response> {
11 const { sqlite } = await import("https://esm.town/v/stevekrouse/sqlite");
12 const KEY = "delightfulVioletAntlion";
3import { createRoot } from "https://esm.sh/react-dom/client";
4
5function StarRating({ rating, onRate }) {
6 return (
7 <div>
19}
20
21function DetailView({ item, type, onClose }) {
22 const [comments, setComments] = useState([]);
23 const [newComment, setNewComment] = useState('');
93}
94
95function App() {
96 const [page, setPage] = useState("clinics");
97 const [search, setSearch] = useState("");
288}
289
290function client() {
291 createRoot(document.getElementById("root")).render(<App />);
292}
293if (typeof document !== "undefined") { client(); }
294
295export default async function server(request: Request): Promise<Response> {
296 const { sqlite } = await import("https://esm.town/v/stevekrouse/sqlite");
297 const SCHEMA_VERSION = 4
2import { easyAQI } from "https://esm.town/v/stevekrouse/easyAQI?v=5";
3
4export async function aqi(interval: Interval) {
5 const location = "pittsburgh"; // <-- change to place, city, or zip code
6 const data = await easyAQI({ location });
4import Stripe from "https://esm.sh/stripe";
5
6function App() {
7 const [loading, setLoading] = useState(false);
8 const [tipAmount, setTipAmount] = useState(5);
84}
85
86function client() {
87 createRoot(document.getElementById("root")).render(<App />);
88}
89if (typeof document !== "undefined") { client(); }
90
91export default async function server(request: Request): Promise<Response> {
92 const url = new URL(request.url);
93
4import { createRoot } from "https://esm.sh/react-dom/client";
5
6function AlbertiCipherDisk({ outerRotation, innerRotation, onRotate }) {
7 const outerAlphabet = "ABCDEFGHILMNOPQRSTVXZ1234";
8 const innerAlphabet = "gklnprtvz&xysomqihfdbace";
80}
81
82function SecurityLevelPicker({ securityLevel, setSecurityLevel }) {
83 return (
84 <div className="flex justify-center space-x-2 mb-6">
100}
101
102function MinLengthPicker({ minLength, setMinLength }) {
103 const options = [8, 12, 16, 20];
104
122}
123
124function SpecialCharToggle({ allowedSpecial, setAllowedSpecial }) {
125 const specialChars = "!@#$%^&*()_+-=[]{}|;:,.<>?".split("");
126
152}
153
154function App() {
155 const [input, setInput] = useState("password123");
156 const [securityLevel, setSecurityLevel] = useState("medium");
397 <li>Review the generated password and its corresponding secure identifier.</li>
398 <li>
399 Utilize the "Copy" functionality to securely transfer your newly generated password to the system
400 clipboard.
401 </li>
420}
421
422function client() {
423 createRoot(document.getElementById("root")).render(<App />);
424}
428}
429
430async function server(request: Request): Promise<Response> {
431 if (request.method === "POST" && new URL(request.url).pathname === "/generate") {
432 const { input, policy, outerRotation, innerRotation } = await request.json();
506}
507
508function generatePassword(
509 input: string,
510 policy: any,
14const DEFAULT_SERVER = 'https://ntfy.sh/';
15
16export async function sendNtfyNotification(payload: NtfyPayload) {
17 const { server = DEFAULT_SERVER, topic } = payload ?? {};
18