@fkn/lib 0.9.33 → 0.9.35

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.
Files changed (96) hide show
  1. package/account.cjs +1 -1
  2. package/account.d.ts +6 -6
  3. package/account.js +3 -3
  4. package/{api-Cc5qxCHP.d.ts → api-CfmRAze5.d.ts} +3 -1
  5. package/{api-BlAtp6lc.js → api-CtiKFcK3.js} +62 -47
  6. package/api-Djf-XdZ4.cjs +3 -0
  7. package/api.cjs +1 -1
  8. package/api.d.ts +2 -2
  9. package/api.js +1 -1
  10. package/attach-policy.cjs +1 -1
  11. package/attach-policy.d.ts +32 -7
  12. package/attach-policy.js +16 -18
  13. package/cloud/dns.d.ts +1 -1
  14. package/cloud/fetch.cjs +1 -1
  15. package/cloud/fetch.d.ts +1 -1
  16. package/cloud/fetch.js +1 -1
  17. package/cloud/fs/promises.d.ts +3 -4
  18. package/cloud/fs.cjs +1 -1
  19. package/cloud/fs.d.ts +2 -2
  20. package/cloud/fs.js +2 -2
  21. package/cloud/net.d.ts +1 -1
  22. package/cloud-B9Sd7V1g.js +422 -0
  23. package/cloud-DCWD_0sd.cjs +1 -0
  24. package/{cloud-D0Ebu5bX.d.ts → cloud-DxitkM7z.d.ts} +9 -5
  25. package/cloud.cjs +1 -1
  26. package/cloud.d.ts +4 -4
  27. package/cloud.js +2 -2
  28. package/{contract-CahPObYc.d.ts → contract-D37GGkou.d.ts} +146 -1
  29. package/contract.cjs +1 -0
  30. package/contract.d.ts +2 -2
  31. package/contract.js +28 -0
  32. package/desktop.d.ts +7 -7
  33. package/dgram.cjs +1 -1
  34. package/dgram.d.ts +5 -5
  35. package/dgram.js +1 -1
  36. package/dns.cjs +1 -1
  37. package/dns.d.ts +3 -3
  38. package/dns.js +1 -1
  39. package/extension-DJQ0oYdk.js +89 -0
  40. package/extension-DSrUjoLw.cjs +1 -0
  41. package/{extension-DNkuFy1Y.d.ts → extension-TRYu_aG-.d.ts} +36 -157
  42. package/extension.cjs +1 -1
  43. package/extension.d.ts +3 -3
  44. package/extension.js +3 -3
  45. package/fs/promises.cjs +1 -1
  46. package/fs/promises.d.ts +3 -3
  47. package/fs/promises.js +1 -1
  48. package/{fs-CYcErwc4.d.ts → fs--NhtUyYa.d.ts} +1 -1
  49. package/{fs-BSsWw8HM.js → fs-BvNZePtN.js} +4 -4
  50. package/{fs-DxDxbvRS.cjs → fs-D8RCGFNc.cjs} +1 -1
  51. package/fs.cjs +1 -1
  52. package/fs.d.ts +2 -2
  53. package/fs.js +1 -1
  54. package/hosts-C4-8lWwz.js +161 -0
  55. package/hosts-DD4rDeQH.cjs +1 -0
  56. package/http.d.ts +20 -20
  57. package/{index-DH3_12nU.d.ts → index-C_Lqta5o.d.ts} +385 -7
  58. package/{index-Cg6y_FTi.d.ts → index-kuPqkS_-.d.ts} +26 -3
  59. package/index.cjs +1 -1
  60. package/index.d.ts +25 -10
  61. package/index.js +68 -62
  62. package/{lib-duLPF_WZ.js → lib-B-jGWfsv.js} +597 -396
  63. package/lib-Cjd91q7g.cjs +53 -0
  64. package/{net-BXPEJToS.d.ts → net-0SlODFSM.d.ts} +2 -2
  65. package/net.cjs +1 -1
  66. package/net.d.ts +1 -1
  67. package/net.js +1 -1
  68. package/node-fs-BNTPsX5c.cjs +1 -0
  69. package/{node-fs-C9ECR_9H.js → node-fs-BZy9bzKd.js} +2 -2
  70. package/opfs/promises.d.ts +2 -2
  71. package/opfs.cjs +1 -1
  72. package/opfs.d.ts +2 -2
  73. package/opfs.js +1 -1
  74. package/package.json +1 -1
  75. package/packages.cjs +1 -1
  76. package/packages.d.ts +27 -27
  77. package/packages.js +1 -1
  78. package/{proxy-DxiJU5Y_.d.ts → proxy-Bmb2wxG1.d.ts} +2 -2
  79. package/proxy-CYcaW5ew.cjs +1 -0
  80. package/proxy-DDwY3AVG.js +60 -0
  81. package/react.d.ts +3 -3
  82. package/rooms.cjs +1 -1
  83. package/rooms.d.ts +8 -8
  84. package/rooms.js +1 -1
  85. package/{storage-Bo01npo9.js → storage-BbcnDCnc.js} +1 -1
  86. package/{storage-WZEvw3KN.d.ts → storage-ZrY4Y4L5.d.ts} +21 -2
  87. package/{storage-DEjjVCT2.cjs → storage-dSi2dUKx.cjs} +1 -1
  88. package/api-Beky02FK.cjs +0 -3
  89. package/cloud-BZmduWyX.cjs +0 -1
  90. package/cloud-DaVb11IV.js +0 -174
  91. package/extension-D70dtUvW.cjs +0 -1
  92. package/extension-DdXNlt9_.js +0 -84
  93. package/lib-DLM2M3_i.cjs +0 -53
  94. package/node-fs-DZPGCYWg.cjs +0 -1
  95. package/proxy-DexG-Wmk.cjs +0 -1
  96. package/proxy-VY0HRl2E.js +0 -75
@@ -0,0 +1,161 @@
1
+ //#region ../web-extension/lib/lib/locator-permissions.js
2
+ var e = {
3
+ scope: "read.text",
4
+ category: "storage",
5
+ severity: 1,
6
+ chip: "read text",
7
+ title: "Read text from the page",
8
+ description: "Lets the app see the text shown on this page."
9
+ }, t = {
10
+ scope: "read.info",
11
+ category: "storage",
12
+ severity: 1,
13
+ chip: "read details",
14
+ title: "Read info from the page",
15
+ description: "Lets the app read a detail of a part of the page."
16
+ }, n = {
17
+ scope: "read.visible",
18
+ category: "storage",
19
+ severity: 0,
20
+ title: "See what’s visible on the page",
21
+ description: "Lets the app check which elements are currently on screen."
22
+ }, r = {
23
+ scope: "read.check",
24
+ category: "storage",
25
+ severity: 0,
26
+ title: "Check if something is on the page",
27
+ description: "Lets the app test whether a specific element exists."
28
+ }, i = {
29
+ scope: "read.count",
30
+ category: "storage",
31
+ severity: 0,
32
+ title: "Count items on the page",
33
+ description: "Lets the app count how many matching elements are present."
34
+ }, a = {
35
+ scope: "act.click",
36
+ category: "interaction",
37
+ severity: 3,
38
+ chip: "click",
39
+ title: "Click on the page",
40
+ description: "Lets the app press buttons or links for you."
41
+ }, o = {
42
+ scope: "act.type",
43
+ category: "interaction",
44
+ severity: 1,
45
+ chip: "type",
46
+ title: "Type into a text field",
47
+ description: "Lets the app fill in form fields on your behalf."
48
+ }, s = {
49
+ scope: "act.hover",
50
+ category: "interaction",
51
+ severity: 1,
52
+ chip: "hover",
53
+ title: "Hover over the page",
54
+ description: "Lets the app point at things to reveal menus or tooltips."
55
+ }, c = {
56
+ scope: "media.video",
57
+ category: "interaction",
58
+ severity: 0,
59
+ title: "Control video playback",
60
+ description: "Lets the app play, pause, seek, and read the video on the page."
61
+ }, l = {
62
+ scope: "media.appear",
63
+ category: "interaction",
64
+ severity: 0,
65
+ title: "Change page appearance",
66
+ description: "Lets the app restyle parts of the page (safely filtered)."
67
+ }, u = {
68
+ scope: "media.appearU",
69
+ category: "evaluation",
70
+ severity: 2,
71
+ chip: "unfiltered styles",
72
+ unsafe: !0,
73
+ title: "Change page appearance (unsafe)",
74
+ description: "Lets the app restyle the page WITHOUT safety filtering. Could be used to leak data over the network."
75
+ }, d = (e) => e?.noSanitize ? u : l, f = {
76
+ scope: "frame.fetchRead",
77
+ category: "network",
78
+ severity: 3,
79
+ chip: "load",
80
+ unsafe: !0,
81
+ title: "Read your account data on this site",
82
+ description: "Lets the app read pages and data from this site as you, using the session in the frame."
83
+ }, p = {
84
+ scope: "frame.fetchWrite",
85
+ category: "network",
86
+ severity: 3,
87
+ chip: "send",
88
+ unsafe: !0,
89
+ title: "Change your account data on this site",
90
+ description: "Lets the app send changes to this site as you, using the session in the frame."
91
+ }, m = /* @__PURE__ */ new Set([
92
+ "GET",
93
+ "HEAD",
94
+ "OPTIONS"
95
+ ]), h = (e, t) => m.has((t?.method ?? "GET").toUpperCase()) ? f : p, g = {
96
+ click: a,
97
+ fill: o,
98
+ hover: s,
99
+ textContent: e,
100
+ getAttribute: t,
101
+ isVisible: n,
102
+ count: i,
103
+ exists: r,
104
+ videoElement: c,
105
+ addStyleTag: d,
106
+ fetch: h
107
+ };
108
+ [
109
+ e,
110
+ t,
111
+ n,
112
+ r,
113
+ i,
114
+ a,
115
+ o,
116
+ s,
117
+ c,
118
+ l,
119
+ u,
120
+ f,
121
+ p
122
+ ].map((e) => e.scope);
123
+ var _ = g, v = (e, t) => {
124
+ let n = _[e];
125
+ return n ? (typeof n == "function" ? n(...t) : n).scope : null;
126
+ }, y = (e, t) => {
127
+ try {
128
+ return new URL(e, t);
129
+ } catch {
130
+ return;
131
+ }
132
+ }, b = (e) => {
133
+ let t = y(e, "https://s.invalid/"), n = y(e, "http://s.invalid/");
134
+ if (!t || !n) return { kind: "invalid" };
135
+ let r = y(e);
136
+ return !r || r.href !== t.href || r.href !== n.href ? { kind: "relative" } : r.protocol !== "https:" && r.protocol !== "http:" ? {
137
+ kind: "unsupported",
138
+ protocol: r.protocol
139
+ } : {
140
+ kind: "absolute",
141
+ host: r.hostname,
142
+ protocol: r.protocol
143
+ };
144
+ }, x = /^[a-z0-9]([a-z0-9-]*[a-z0-9])?(\.[a-z0-9]([a-z0-9-]*[a-z0-9])?)*$/, S = /^\[[0-9a-f:.]+\]$/, C = (e) => {
145
+ try {
146
+ return new URL(`http://${e}/`).hostname;
147
+ } catch {
148
+ return;
149
+ }
150
+ }, w = (e, { ipv6: t = !1 } = {}) => {
151
+ let n = [];
152
+ for (let r of e) {
153
+ let e = r.trim().toLowerCase();
154
+ if (!e || e.length > 253) continue;
155
+ let i = x.test(e) ? e : t && S.test(e) ? C(e) : void 0;
156
+ i && !n.includes(i) && n.push(i);
157
+ }
158
+ return n;
159
+ };
160
+ //#endregion
161
+ export { n as _, l as a, b as c, c as d, v as f, e as g, t as h, o as i, f as l, i as m, a as n, u as o, r as p, s as r, h as s, w as t, p as u };
@@ -0,0 +1 @@
1
+ var e={scope:`read.text`,category:`storage`,severity:1,chip:`read text`,title:`Read text from the page`,description:`Lets the app see the text shown on this page.`},t={scope:`read.info`,category:`storage`,severity:1,chip:`read details`,title:`Read info from the page`,description:`Lets the app read a detail of a part of the page.`},n={scope:`read.visible`,category:`storage`,severity:0,title:`See what’s visible on the page`,description:`Lets the app check which elements are currently on screen.`},r={scope:`read.check`,category:`storage`,severity:0,title:`Check if something is on the page`,description:`Lets the app test whether a specific element exists.`},i={scope:`read.count`,category:`storage`,severity:0,title:`Count items on the page`,description:`Lets the app count how many matching elements are present.`},a={scope:`act.click`,category:`interaction`,severity:3,chip:`click`,title:`Click on the page`,description:`Lets the app press buttons or links for you.`},o={scope:`act.type`,category:`interaction`,severity:1,chip:`type`,title:`Type into a text field`,description:`Lets the app fill in form fields on your behalf.`},s={scope:`act.hover`,category:`interaction`,severity:1,chip:`hover`,title:`Hover over the page`,description:`Lets the app point at things to reveal menus or tooltips.`},c={scope:`media.video`,category:`interaction`,severity:0,title:`Control video playback`,description:`Lets the app play, pause, seek, and read the video on the page.`},l={scope:`media.appear`,category:`interaction`,severity:0,title:`Change page appearance`,description:`Lets the app restyle parts of the page (safely filtered).`},u={scope:`media.appearU`,category:`evaluation`,severity:2,chip:`unfiltered styles`,unsafe:!0,title:`Change page appearance (unsafe)`,description:`Lets the app restyle the page WITHOUT safety filtering. Could be used to leak data over the network.`},d=e=>e?.noSanitize?u:l,f={scope:`frame.fetchRead`,category:`network`,severity:3,chip:`load`,unsafe:!0,title:`Read your account data on this site`,description:`Lets the app read pages and data from this site as you, using the session in the frame.`},p={scope:`frame.fetchWrite`,category:`network`,severity:3,chip:`send`,unsafe:!0,title:`Change your account data on this site`,description:`Lets the app send changes to this site as you, using the session in the frame.`},m=new Set([`GET`,`HEAD`,`OPTIONS`]),h=(e,t)=>m.has((t?.method??`GET`).toUpperCase())?f:p,g={click:a,fill:o,hover:s,textContent:e,getAttribute:t,isVisible:n,count:i,exists:r,videoElement:c,addStyleTag:d,fetch:h};[e,t,n,r,i,a,o,s,c,l,u,f,p].map(e=>e.scope);var _=g,v=(e,t)=>{let n=_[e];return n?(typeof n==`function`?n(...t):n).scope:null},y=(e,t)=>{try{return new URL(e,t)}catch{return}},b=e=>{let t=y(e,`https://s.invalid/`),n=y(e,`http://s.invalid/`);if(!t||!n)return{kind:`invalid`};let r=y(e);return!r||r.href!==t.href||r.href!==n.href?{kind:`relative`}:r.protocol!==`https:`&&r.protocol!==`http:`?{kind:`unsupported`,protocol:r.protocol}:{kind:`absolute`,host:r.hostname,protocol:r.protocol}},x=/^[a-z0-9]([a-z0-9-]*[a-z0-9])?(\.[a-z0-9]([a-z0-9-]*[a-z0-9])?)*$/,S=/^\[[0-9a-f:.]+\]$/,C=e=>{try{return new URL(`http://${e}/`).hostname}catch{return}},w=(e,{ipv6:t=!1}={})=>{let n=[];for(let r of e){let e=r.trim().toLowerCase();if(!e||e.length>253)continue;let i=x.test(e)?e:t&&S.test(e)?C(e):void 0;i&&!n.includes(i)&&n.push(i)}return n};Object.defineProperty(exports,"_",{enumerable:!0,get:function(){return n}}),Object.defineProperty(exports,"a",{enumerable:!0,get:function(){return l}}),Object.defineProperty(exports,"c",{enumerable:!0,get:function(){return b}}),Object.defineProperty(exports,"d",{enumerable:!0,get:function(){return c}}),Object.defineProperty(exports,"f",{enumerable:!0,get:function(){return v}}),Object.defineProperty(exports,"g",{enumerable:!0,get:function(){return e}}),Object.defineProperty(exports,"h",{enumerable:!0,get:function(){return t}}),Object.defineProperty(exports,"i",{enumerable:!0,get:function(){return o}}),Object.defineProperty(exports,"l",{enumerable:!0,get:function(){return f}}),Object.defineProperty(exports,"m",{enumerable:!0,get:function(){return i}}),Object.defineProperty(exports,"n",{enumerable:!0,get:function(){return a}}),Object.defineProperty(exports,"o",{enumerable:!0,get:function(){return u}}),Object.defineProperty(exports,"p",{enumerable:!0,get:function(){return r}}),Object.defineProperty(exports,"r",{enumerable:!0,get:function(){return s}}),Object.defineProperty(exports,"s",{enumerable:!0,get:function(){return h}}),Object.defineProperty(exports,"t",{enumerable:!0,get:function(){return w}}),Object.defineProperty(exports,"u",{enumerable:!0,get:function(){return p}});
package/http.d.ts CHANGED
@@ -1,13 +1,13 @@
1
- import { n as Socket, t as Server$1 } from "./net-BXPEJToS.js";
1
+ import { n as Socket, t as Server$1 } from "./net-0SlODFSM.js";
2
2
  import { Buffer } from "buffer";
3
3
  import { Stream } from "stream";
4
4
  import { IncomingHttpHeaders, OutgoingHttpHeaders, RequestOptions } from "http";
5
5
  declare namespace http_d_exports {
6
6
  export { Agent, ClientRequest, ClientRequestArgs, HTTPParser, IncomingMessage, METHODS, ParsedHead, RequestListener, STATUS_CODES, Server, ServerResponse, ServerResponseOptions, _default, createServer, _default as default, get, globalAgent, request };
7
7
  }
8
- declare const METHODS: string[];
9
- declare const STATUS_CODES: Record<number, string>;
10
- interface ParsedHead {
8
+ export declare const METHODS: string[];
9
+ export declare const STATUS_CODES: Record<number, string>;
10
+ export interface ParsedHead {
11
11
  /** request only */
12
12
  method?: string;
13
13
  /** request only */
@@ -27,7 +27,7 @@ interface ParserHandlers {
27
27
  onBody: (chunk: Uint8Array) => void;
28
28
  onComplete: () => void;
29
29
  }
30
- declare class HTTPParser {
30
+ export declare class HTTPParser {
31
31
  private readonly mode;
32
32
  private readonly handlers;
33
33
  private buf;
@@ -47,7 +47,7 @@ declare class HTTPParser {
47
47
  private consumeBody;
48
48
  private consumeChunked;
49
49
  }
50
- declare class IncomingMessage extends Stream.Readable {
50
+ export declare class IncomingMessage extends Stream.Readable {
51
51
  httpVersion: string;
52
52
  httpVersionMajor: number;
53
53
  httpVersionMinor: number;
@@ -95,10 +95,10 @@ declare abstract class OutgoingMessage extends Stream.Writable {
95
95
  end(chunk?: unknown, encoding?: BufferEncoding | (() => void), callback?: () => void): this;
96
96
  protected _headBlock?: string;
97
97
  }
98
- interface ServerResponseOptions {
98
+ export interface ServerResponseOptions {
99
99
  req: IncomingMessage;
100
100
  }
101
- declare class ServerResponse extends OutgoingMessage {
101
+ export declare class ServerResponse extends OutgoingMessage {
102
102
  statusCode: number;
103
103
  statusMessage?: string;
104
104
  private _writeHeadCalled;
@@ -114,13 +114,13 @@ declare class ServerResponse extends OutgoingMessage {
114
114
  writeContinue(): void;
115
115
  setTimeout(msecs: number, callback?: () => void): this;
116
116
  }
117
- interface ClientRequestArgs extends RequestOptions {
117
+ export interface ClientRequestArgs extends RequestOptions {
118
118
  host?: string;
119
119
  hostname?: string;
120
120
  port?: number | string;
121
121
  path?: string;
122
122
  }
123
- declare class ClientRequest extends OutgoingMessage {
123
+ export declare class ClientRequest extends OutgoingMessage {
124
124
  method: string;
125
125
  path: string;
126
126
  host: string;
@@ -143,14 +143,14 @@ declare class ClientRequest extends OutgoingMessage {
143
143
  setNoDelay(noDelay?: boolean): void;
144
144
  setSocketKeepAlive(enable?: boolean, initialDelay?: number): void;
145
145
  }
146
- type RequestListener = (req: IncomingMessage, res: ServerResponse) => void;
146
+ export type RequestListener = (req: IncomingMessage, res: ServerResponse) => void;
147
147
  declare class ServerImpl extends Server$1 {
148
148
  constructor(options?: object | RequestListener, requestListener?: RequestListener);
149
149
  private _handleConnection;
150
150
  }
151
- declare const Server: typeof ServerImpl;
152
- type Server = ServerImpl;
153
- declare class Agent {
151
+ export declare const Server: typeof ServerImpl;
152
+ export type Server = ServerImpl;
153
+ export declare class Agent {
154
154
  maxSockets: number;
155
155
  maxFreeSockets: number;
156
156
  keepAlive: boolean;
@@ -163,11 +163,11 @@ declare class Agent {
163
163
  }): string;
164
164
  destroy(): void;
165
165
  }
166
- declare const globalAgent: Agent;
167
- declare const request: (...args: [options: string | URL | ClientRequestArgs, callback?: (res: IncomingMessage) => void] | [url: string | URL, options: ClientRequestArgs, callback?: (res: IncomingMessage) => void]) => ClientRequest;
168
- declare const get: (...args: [options: string | URL | ClientRequestArgs, callback?: (res: IncomingMessage) => void] | [url: string | URL, options: ClientRequestArgs, callback?: (res: IncomingMessage) => void]) => ClientRequest;
169
- declare const createServer: (options?: object | RequestListener, requestListener?: RequestListener) => Server;
170
- declare const _default: {
166
+ export declare const globalAgent: Agent;
167
+ export declare const request: (...args: [options: string | URL | ClientRequestArgs, callback?: (res: IncomingMessage) => void] | [url: string | URL, options: ClientRequestArgs, callback?: (res: IncomingMessage) => void]) => ClientRequest;
168
+ export declare const get: (...args: [options: string | URL | ClientRequestArgs, callback?: (res: IncomingMessage) => void] | [url: string | URL, options: ClientRequestArgs, callback?: (res: IncomingMessage) => void]) => ClientRequest;
169
+ export declare const createServer: (options?: object | RequestListener, requestListener?: RequestListener) => Server;
170
+ export declare const _default: {
171
171
  METHODS: string[];
172
172
  STATUS_CODES: Record<number, string>;
173
173
  Agent: typeof Agent;
@@ -182,4 +182,4 @@ declare const _default: {
182
182
  get: typeof get;
183
183
  };
184
184
  //#endregion
185
- export { Agent, ClientRequest, ClientRequestArgs, HTTPParser, IncomingMessage, METHODS, ParsedHead, RequestListener, STATUS_CODES, Server, ServerResponse, ServerResponseOptions, _default, _default as default, createServer, get, globalAgent, request, http_d_exports as t };
185
+ export { _default as default, http_d_exports as t };