pythinker-code 2.1.0__py3-none-any.whl → 2.2.0__py3-none-any.whl
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.
- pythinker_code/CHANGELOG.md +26 -0
- pythinker_code/auth/oauth.py +2 -2
- pythinker_code/ui/shell/components/render_utils.py +4 -0
- pythinker_code/ui/shell/prompt.py +5 -3
- pythinker_code/utils/logging.py +2 -2
- pythinker_code/web/static/assets/{_baseUniq-WdgkyqbT.js → _baseUniq-3b9Vjh1L.js} +1 -1
- pythinker_code/web/static/assets/{arc-CXmKbmz7.js → arc-DR3CXZeR.js} +1 -1
- pythinker_code/web/static/assets/{architectureDiagram-VXUJARFQ-YDl9Qkda.js → architectureDiagram-VXUJARFQ-BQ0-qSoc.js} +1 -1
- pythinker_code/web/static/assets/{blockDiagram-VD42YOAC-C9ovno3t.js → blockDiagram-VD42YOAC-Kd0tjFCT.js} +1 -1
- pythinker_code/web/static/assets/{c4Diagram-YG6GDRKO-BXr41RkG.js → c4Diagram-YG6GDRKO-Cw4rqOBn.js} +1 -1
- pythinker_code/web/static/assets/channel-CV_6LFjm.js +1 -0
- pythinker_code/web/static/assets/{chunk-4BX2VUAB-DGMZhK43.js → chunk-4BX2VUAB-CrDv9tak.js} +1 -1
- pythinker_code/web/static/assets/{chunk-55IACEB6-B5ry842o.js → chunk-55IACEB6-DmOcpRpp.js} +1 -1
- pythinker_code/web/static/assets/{chunk-B4BG7PRW-BfRKLjSN.js → chunk-B4BG7PRW-ChaFy2yE.js} +1 -1
- pythinker_code/web/static/assets/{chunk-DI55MBZ5-Do9AJtv7.js → chunk-DI55MBZ5-BqW-gG3F.js} +1 -1
- pythinker_code/web/static/assets/{chunk-FMBD7UC4-CgOlE1IE.js → chunk-FMBD7UC4-CubqcuRB.js} +1 -1
- pythinker_code/web/static/assets/{chunk-QN33PNHL-gw_IcalK.js → chunk-QN33PNHL-1SSU3xPb.js} +1 -1
- pythinker_code/web/static/assets/{chunk-QZHKN3VN-VcfL-NQQ.js → chunk-QZHKN3VN-ClwSLfPq.js} +1 -1
- pythinker_code/web/static/assets/{chunk-TZMSLE5B-BMbaKRk3.js → chunk-TZMSLE5B-DUb7Xnze.js} +1 -1
- pythinker_code/web/static/assets/classDiagram-2ON5EDUG-DRifCGzI.js +1 -0
- pythinker_code/web/static/assets/classDiagram-v2-WZHVMYZB-DRifCGzI.js +1 -0
- pythinker_code/web/static/assets/clone-BZw9ajX3.js +1 -0
- pythinker_code/web/static/assets/{code-block-IT6T5CEO-DKwthXRd.js → code-block-IT6T5CEO-CU9M5g3e.js} +1 -1
- pythinker_code/web/static/assets/{cose-bilkent-S5V4N54A-QvhSyJ47.js → cose-bilkent-S5V4N54A-BpIWTq5c.js} +1 -1
- pythinker_code/web/static/assets/{cytoscape.esm-DZwBUI1Q.js → cytoscape.esm-vaP_ZthC.js} +1 -1
- pythinker_code/web/static/assets/{dagre-6UL2VRFP-BDy2l1-g.js → dagre-6UL2VRFP-DCC7bVEs.js} +1 -1
- pythinker_code/web/static/assets/{diagram-PSM6KHXK-BZM3ha9j.js → diagram-PSM6KHXK-DC8NtTl0.js} +1 -1
- pythinker_code/web/static/assets/{diagram-QEK2KX5R-HjR3RK6A.js → diagram-QEK2KX5R-BZIGC5xL.js} +1 -1
- pythinker_code/web/static/assets/{diagram-S2PKOQOG-Mi15ug_w.js → diagram-S2PKOQOG-DgJwjM3h.js} +1 -1
- pythinker_code/web/static/assets/{erDiagram-Q2GNP2WA-jUbIypmc.js → erDiagram-Q2GNP2WA-Cmn41NBD.js} +1 -1
- pythinker_code/web/static/assets/{flowDiagram-NV44I4VS-CrsXaal5.js → flowDiagram-NV44I4VS-D3I6RCYp.js} +1 -1
- pythinker_code/web/static/assets/{ganttDiagram-JELNMOA3-BfyinOz_.js → ganttDiagram-JELNMOA3-CKI2c4nb.js} +1 -1
- pythinker_code/web/static/assets/{gitGraphDiagram-NY62KEGX-SGlWWpCh.js → gitGraphDiagram-NY62KEGX-BC0ty1CW.js} +1 -1
- pythinker_code/web/static/assets/{graph-BbnvRGn-.js → graph-CEqyonfn.js} +1 -1
- pythinker_code/web/static/assets/{index-BtuEmzQY.js → index-B9Mjc3Gm.js} +1 -1
- pythinker_code/web/static/assets/{index-DUqu3OY8.js → index-cEE9hGzb.js} +2 -2
- pythinker_code/web/static/assets/{index-MZ4ra56p.js → index-n9Qz5PAk.js} +1 -1
- pythinker_code/web/static/assets/{infoDiagram-WHAUD3N6-BQw-PXc-.js → infoDiagram-WHAUD3N6-De2sP9Ub.js} +1 -1
- pythinker_code/web/static/assets/{journeyDiagram-XKPGCS4Q-Dgy4RQfB.js → journeyDiagram-XKPGCS4Q-DfKYGnYF.js} +1 -1
- pythinker_code/web/static/assets/{kanban-definition-3W4ZIXB7-BLdG3Mfe.js → kanban-definition-3W4ZIXB7-D3yKysrB.js} +1 -1
- pythinker_code/web/static/assets/{layout-hYKYjJNX.js → layout-DPVEoKKe.js} +1 -1
- pythinker_code/web/static/assets/{linear-DigdNJRJ.js → linear-BEfJdq4v.js} +1 -1
- pythinker_code/web/static/assets/{mermaid-VLURNSYL-DKXTFYtU.js → mermaid-VLURNSYL-BMWN6yQ-.js} +7 -7
- pythinker_code/web/static/assets/{mermaid.core-DHZF5iPm.js → mermaid.core-D1FKNjuC.js} +5 -5
- pythinker_code/web/static/assets/{min-DZVTU06Y.js → min-C_AGskQ6.js} +1 -1
- pythinker_code/web/static/assets/{mindmap-definition-VGOIOE7T-BDReDg-s.js → mindmap-definition-VGOIOE7T-s9jf1xzX.js} +1 -1
- pythinker_code/web/static/assets/{pieDiagram-ADFJNKIX-BTt06Upj.js → pieDiagram-ADFJNKIX-D-oXViLF.js} +1 -1
- pythinker_code/web/static/assets/{quadrantDiagram-AYHSOK5B-DFeziBtO.js → quadrantDiagram-AYHSOK5B-DGUqiK6I.js} +1 -1
- pythinker_code/web/static/assets/{requirementDiagram-UZGBJVZJ-CETXPBHk.js → requirementDiagram-UZGBJVZJ-CVwILSF5.js} +1 -1
- pythinker_code/web/static/assets/{sankeyDiagram-TZEHDZUN-DsLlLqb0.js → sankeyDiagram-TZEHDZUN-D_M1b9Wz.js} +1 -1
- pythinker_code/web/static/assets/{sequenceDiagram-WL72ISMW-BXQGeJH7.js → sequenceDiagram-WL72ISMW-CBLYLJJI.js} +1 -1
- pythinker_code/web/static/assets/{stateDiagram-FKZM4ZOC-D5_fBCG4.js → stateDiagram-FKZM4ZOC-ZZg0Md3N.js} +1 -1
- pythinker_code/web/static/assets/stateDiagram-v2-4FDKWEC3-D1YbdDrw.js +1 -0
- pythinker_code/web/static/assets/{timeline-definition-IT6M3QCI-CYrMqdcr.js → timeline-definition-IT6M3QCI-B7D4eU3W.js} +1 -1
- pythinker_code/web/static/assets/{treemap-KMMF4GRG-DdKzgfwQ.js → treemap-KMMF4GRG-Cy0XtWQy.js} +1 -1
- pythinker_code/web/static/assets/{xychartDiagram-PRI3JC2R-hhd94HEL.js → xychartDiagram-PRI3JC2R-BWl1l11O.js} +1 -1
- pythinker_code/web/static/index.html +1 -1
- {pythinker_code-2.1.0.dist-info → pythinker_code-2.2.0.dist-info}/METADATA +66 -20
- pythinker_code-2.2.0.dist-info/RECORD +774 -0
- {pythinker_code-2.1.0.dist-info → pythinker_code-2.2.0.dist-info}/WHEEL +2 -2
- pythinker_code/web/static/assets/channel-D_ia5WZB.js +0 -1
- pythinker_code/web/static/assets/classDiagram-2ON5EDUG-oflluu9m.js +0 -1
- pythinker_code/web/static/assets/classDiagram-v2-WZHVMYZB-oflluu9m.js +0 -1
- pythinker_code/web/static/assets/clone-CGWjTGh5.js +0 -1
- pythinker_code/web/static/assets/stateDiagram-v2-4FDKWEC3-B4fITG2H.js +0 -1
- pythinker_code-2.1.0.dist-info/RECORD +0 -774
- {pythinker_code-2.1.0.dist-info → pythinker_code-2.2.0.dist-info}/entry_points.txt +0 -0
- {pythinker_code-2.1.0.dist-info → pythinker_code-2.2.0.dist-info}/licenses/LICENSE +0 -0
- {pythinker_code-2.1.0.dist-info → pythinker_code-2.2.0.dist-info}/licenses/NOTICE +0 -0
pythinker_code/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,32 @@
|
|
|
2
2
|
|
|
3
3
|
## Unreleased
|
|
4
4
|
|
|
5
|
+
## 2.2.0 (2026-05-09)
|
|
6
|
+
|
|
7
|
+
Installer UX: animated logo + Windows PATH automation.
|
|
8
|
+
|
|
9
|
+
- `scripts/install.sh`: Tetris-style logo animation. Pieces (walls, bars, eyes, ears, antenna) fall from above the canvas one at a time and settle into the robot head before install proceeds. Static logo remains the fallback for non-TTY / `NO_COLOR` / `TERM=dumb` / `CI=1` / `PYTHINKER_NO_ANIMATION=1`. Tunables: `PYTHINKER_LOGO_FRAME_DELAY` and `PYTHINKER_LOGO_STAGGER_DELAY` (seconds).
|
|
10
|
+
- `scripts/install.ps1`: same animation, PowerShell port. Tunables: `PYTHINKER_LOGO_FRAME_DELAY_MS` and `PYTHINKER_LOGO_STAGGER_DELAY_MS` (milliseconds).
|
|
11
|
+
- `scripts/install.ps1`: idempotently append `$USERPROFILE\.local\bin` to the User PATH via `[Environment]::SetEnvironmentVariable` and broadcast `WM_SETTINGCHANGE` so future shells (and Explorer-spawned children) pick up the new PATH automatically. No-op when the directory is already present.
|
|
12
|
+
- `scripts/install.ps1`: force `[Console]::OutputEncoding = UTF8` so the box-drawing characters render correctly on Windows hosts.
|
|
13
|
+
|
|
14
|
+
## 2.1.2 (2026-05-09)
|
|
15
|
+
|
|
16
|
+
Windows installer fix.
|
|
17
|
+
|
|
18
|
+
- `scripts/install.ps1`: dot-source Astral's `uv` bootstrap inside `& { ... }` instead of spawning `powershell -File`, so `$env:PATH` updates land in the running process.
|
|
19
|
+
- `scripts/install.ps1`: refresh PATH after `uv tool install` and verify `pythinker` resolves before printing success; otherwise emit the absolute shim path.
|
|
20
|
+
- README: invoke the downloaded `install.ps1` with `& $installer` (current shell) instead of a `powershell -NoProfile -File $installer` subprocess. `uv`, `uvx`, and `pythinker` are now usable in the calling shell as soon as the installer exits.
|
|
21
|
+
- `tests/test_installation_docs.py`: lock in current-session invocation in the README and a dot-sourced `uv` bootstrap in `install.ps1`.
|
|
22
|
+
|
|
23
|
+
## 2.1.1 (2026-05-08)
|
|
24
|
+
|
|
25
|
+
Documentation refresh.
|
|
26
|
+
|
|
27
|
+
- README: image and key file links converted to absolute GitHub URLs so the project page on PyPI renders the logo, demo GIFs, and architecture diagram correctly.
|
|
28
|
+
- README: added a "What's New in 2.1.0" section summarising the TUI CLI and slash-command enhancements.
|
|
29
|
+
- README: corrected the License section to Apache-2.0 (matches `pyproject.toml` and the `LICENSE` badge).
|
|
30
|
+
|
|
5
31
|
## 2.1.0 (2026-05-08)
|
|
6
32
|
|
|
7
33
|
TUI CLI design and slash command enhancements.
|
pythinker_code/auth/oauth.py
CHANGED
|
@@ -11,7 +11,7 @@ import tempfile
|
|
|
11
11
|
import time
|
|
12
12
|
import uuid
|
|
13
13
|
import webbrowser
|
|
14
|
-
from collections.abc import AsyncIterator
|
|
14
|
+
from collections.abc import AsyncGenerator, AsyncIterator
|
|
15
15
|
from contextlib import asynccontextmanager, suppress
|
|
16
16
|
from dataclasses import dataclass
|
|
17
17
|
from pathlib import Path
|
|
@@ -921,7 +921,7 @@ class OAuthManager:
|
|
|
921
921
|
await self._refresh_tokens(ref, token, runtime, force=force)
|
|
922
922
|
|
|
923
923
|
@asynccontextmanager
|
|
924
|
-
async def refreshing(self, runtime: Runtime) ->
|
|
924
|
+
async def refreshing(self, runtime: Runtime) -> AsyncGenerator[None]:
|
|
925
925
|
stop_event = asyncio.Event()
|
|
926
926
|
|
|
927
927
|
async def _runner() -> None:
|
|
@@ -134,12 +134,16 @@ def render_plain(renderable: RenderableType, *, width: int = 80) -> str:
|
|
|
134
134
|
Snapshot helper for tests — color codes are stripped so the output is
|
|
135
135
|
a stable, comparable plain-text representation.
|
|
136
136
|
"""
|
|
137
|
+
# Override TERM via _environ so Rich's `is_dumb_terminal` detection
|
|
138
|
+
# doesn't kick in and force size to 80x25 (which silently ignores the
|
|
139
|
+
# explicit `width=` argument). This matters in CI where TERM=dumb is set.
|
|
137
140
|
console = Console(
|
|
138
141
|
width=width,
|
|
139
142
|
record=True,
|
|
140
143
|
force_terminal=True,
|
|
141
144
|
color_system=None,
|
|
142
145
|
legacy_windows=False,
|
|
146
|
+
_environ={"TERM": "xterm-256color"},
|
|
143
147
|
)
|
|
144
148
|
console.print(renderable)
|
|
145
149
|
return console.export_text()
|
|
@@ -349,12 +349,14 @@ def _container_contains(root: object, target: object) -> bool:
|
|
|
349
349
|
for attr in ("children", "content", "floats", "container", "alternative_content"):
|
|
350
350
|
if not hasattr(node, attr):
|
|
351
351
|
continue
|
|
352
|
-
value = getattr(node, attr)
|
|
352
|
+
value: object = getattr(node, attr)
|
|
353
353
|
if attr == "children" and isinstance(value, Sequence):
|
|
354
|
-
|
|
354
|
+
children = cast(Sequence[object], value)
|
|
355
|
+
if any(_walk(child) for child in children):
|
|
355
356
|
return True
|
|
356
357
|
elif attr == "floats" and isinstance(value, Sequence):
|
|
357
|
-
|
|
358
|
+
floats = cast(Sequence[object], value)
|
|
359
|
+
if any(_walk(cast(object, getattr(float_, "content", None))) for float_ in floats):
|
|
358
360
|
return True
|
|
359
361
|
elif value is not None and _walk(value):
|
|
360
362
|
return True
|
pythinker_code/utils/logging.py
CHANGED
|
@@ -6,7 +6,7 @@ import locale
|
|
|
6
6
|
import os
|
|
7
7
|
import sys
|
|
8
8
|
import threading
|
|
9
|
-
from collections.abc import
|
|
9
|
+
from collections.abc import Generator
|
|
10
10
|
from typing import IO, Any, cast
|
|
11
11
|
|
|
12
12
|
|
|
@@ -133,7 +133,7 @@ def restore_stderr() -> None:
|
|
|
133
133
|
|
|
134
134
|
|
|
135
135
|
@contextlib.contextmanager
|
|
136
|
-
def open_original_stderr() ->
|
|
136
|
+
def open_original_stderr() -> Generator[IO[bytes] | None]:
|
|
137
137
|
redirector = _stderr_redirector
|
|
138
138
|
if redirector is None:
|
|
139
139
|
yield None
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{aV as L,bj as ln,aF as A,aT as P,aE as W,bk as gn,bl as dn,bm as hn,bn as z,bo as pn,bp as An,bq as m,aW as N,a$ as U,b2 as T,br as _n,aZ as on,bs as wn,bt as On,aG as V,bu as vn,bv as I}from"./mermaid.core-
|
|
1
|
+
import{aV as L,bj as ln,aF as A,aT as P,aE as W,bk as gn,bl as dn,bm as hn,bn as z,bo as pn,bp as An,bq as m,aW as N,a$ as U,b2 as T,br as _n,aZ as on,bs as wn,bt as On,aG as V,bu as vn,bv as I}from"./mermaid.core-D1FKNjuC.js";var Pn="[object Symbol]";function x(n){return typeof n=="symbol"||L(n)&&ln(n)==Pn}function yn(n,r){for(var e=-1,i=n==null?0:n.length,f=Array(i);++e<i;)f[e]=r(n[e],e,n);return f}var B=P?P.prototype:void 0,K=B?B.toString:void 0;function k(n){if(typeof n=="string")return n;if(A(n))return yn(n,k)+"";if(x(n))return K?K.call(n):"";var r=n+"";return r=="0"&&1/n==-1/0?"-0":r}function En(){}function bn(n,r){for(var e=-1,i=n==null?0:n.length;++e<i&&r(n[e],e,n)!==!1;);return n}function cn(n,r,e,i){for(var f=n.length,t=e+-1;++t<f;)if(r(n[t],t,n))return t;return-1}function Tn(n){return n!==n}function Rn(n,r,e){for(var i=e-1,f=n.length;++i<f;)if(n[i]===r)return i;return-1}function In(n,r,e){return r===r?Rn(n,r,e):cn(n,Tn,e)}function Sn(n,r){var e=n==null?0:n.length;return!!e&&In(n,r,0)>-1}function M(n){return W(n)?gn(n):dn(n)}var Ln=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,xn=/^\w*$/;function $(n,r){if(A(n))return!1;var e=typeof n;return e=="number"||e=="symbol"||e=="boolean"||n==null||x(n)?!0:xn.test(n)||!Ln.test(n)||r!=null&&n in Object(r)}var Mn=500;function $n(n){var r=hn(n,function(i){return e.size===Mn&&e.clear(),i}),e=r.cache;return r}var Cn=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Fn=/\\(\\)?/g,Gn=$n(function(n){var r=[];return n.charCodeAt(0)===46&&r.push(""),n.replace(Cn,function(e,i,f,t){r.push(f?t.replace(Fn,"$1"):i||e)}),r});function Dn(n){return n==null?"":k(n)}function j(n,r){return A(n)?n:$(n,r)?[n]:Gn(Dn(n))}function R(n){if(typeof n=="string"||x(n))return n;var r=n+"";return r=="0"&&1/n==-1/0?"-0":r}function nn(n,r){r=j(r,n);for(var e=0,i=r.length;n!=null&&e<i;)n=n[R(r[e++])];return e&&e==i?n:void 0}function mn(n,r,e){var i=n==null?void 0:nn(n,r);return i===void 0?e:i}function rn(n,r){for(var e=-1,i=r.length,f=n.length;++e<i;)n[f+e]=r[e];return n}var H=P?P.isConcatSpreadable:void 0;function Nn(n){return A(n)||z(n)||!!(H&&n&&n[H])}function Hr(n,r,e,i,f){var t=-1,s=n.length;for(e||(e=Nn),f||(f=[]);++t<s;){var u=n[t];e(u)?rn(f,u):i||(f[f.length]=u)}return f}function Un(n,r,e,i){var f=-1,t=n==null?0:n.length;for(i&&t&&(e=n[++f]);++f<t;)e=r(e,n[f],f,n);return e}function en(n,r){for(var e=-1,i=n==null?0:n.length,f=0,t=[];++e<i;){var s=n[e];r(s,e,n)&&(t[f++]=s)}return t}function Bn(){return[]}var Kn=Object.prototype,Hn=Kn.propertyIsEnumerable,q=Object.getOwnPropertySymbols,qn=q?function(n){return n==null?[]:(n=Object(n),en(q(n),function(r){return Hn.call(n,r)}))}:Bn;function Zn(n,r,e){var i=r(n);return A(n)?i:rn(i,e(n))}function Z(n){return Zn(n,M,qn)}var Yn="__lodash_hash_undefined__";function Xn(n){return this.__data__.set(n,Yn),this}function Jn(n){return this.__data__.has(n)}function y(n){var r=-1,e=n==null?0:n.length;for(this.__data__=new pn;++r<e;)this.add(n[r])}y.prototype.add=y.prototype.push=Xn;y.prototype.has=Jn;function Qn(n,r){for(var e=-1,i=n==null?0:n.length;++e<i;)if(r(n[e],e,n))return!0;return!1}function tn(n,r){return n.has(r)}var Wn=1,zn=2;function fn(n,r,e,i,f,t){var s=e&Wn,u=n.length,a=r.length;if(u!=a&&!(s&&a>u))return!1;var h=t.get(n),g=t.get(r);if(h&&g)return h==r&&g==n;var l=-1,d=!0,o=e&zn?new y:void 0;for(t.set(n,r),t.set(r,n);++l<u;){var p=n[l],_=r[l];if(i)var w=s?i(_,p,l,r,n,t):i(p,_,l,n,r,t);if(w!==void 0){if(w)continue;d=!1;break}if(o){if(!Qn(r,function(O,v){if(!tn(o,v)&&(p===O||f(p,O,e,i,t)))return o.push(v)})){d=!1;break}}else if(!(p===_||f(p,_,e,i,t))){d=!1;break}}return t.delete(n),t.delete(r),d}function Vn(n){var r=-1,e=Array(n.size);return n.forEach(function(i,f){e[++r]=[f,i]}),e}function C(n){var r=-1,e=Array(n.size);return n.forEach(function(i){e[++r]=i}),e}var kn=1,jn=2,nr="[object Boolean]",rr="[object Date]",er="[object Error]",ir="[object Map]",tr="[object Number]",fr="[object RegExp]",sr="[object Set]",ur="[object String]",ar="[object Symbol]",lr="[object ArrayBuffer]",gr="[object DataView]",Y=P?P.prototype:void 0,S=Y?Y.valueOf:void 0;function dr(n,r,e,i,f,t,s){switch(e){case gr:if(n.byteLength!=r.byteLength||n.byteOffset!=r.byteOffset)return!1;n=n.buffer,r=r.buffer;case lr:return!(n.byteLength!=r.byteLength||!t(new m(n),new m(r)));case nr:case rr:case tr:return An(+n,+r);case er:return n.name==r.name&&n.message==r.message;case fr:case ur:return n==r+"";case ir:var u=Vn;case sr:var a=i&kn;if(u||(u=C),n.size!=r.size&&!a)return!1;var h=s.get(n);if(h)return h==r;i|=jn,s.set(n,r);var g=fn(u(n),u(r),i,f,t,s);return s.delete(n),g;case ar:if(S)return S.call(n)==S.call(r)}return!1}var hr=1,pr=Object.prototype,Ar=pr.hasOwnProperty;function _r(n,r,e,i,f,t){var s=e&hr,u=Z(n),a=u.length,h=Z(r),g=h.length;if(a!=g&&!s)return!1;for(var l=a;l--;){var d=u[l];if(!(s?d in r:Ar.call(r,d)))return!1}var o=t.get(n),p=t.get(r);if(o&&p)return o==r&&p==n;var _=!0;t.set(n,r),t.set(r,n);for(var w=s;++l<a;){d=u[l];var O=n[d],v=r[d];if(i)var D=s?i(v,O,d,r,n,t):i(O,v,d,n,r,t);if(!(D===void 0?O===v||f(O,v,e,i,t):D)){_=!1;break}w||(w=d=="constructor")}if(_&&!w){var E=n.constructor,b=r.constructor;E!=b&&"constructor"in n&&"constructor"in r&&!(typeof E=="function"&&E instanceof E&&typeof b=="function"&&b instanceof b)&&(_=!1)}return t.delete(n),t.delete(r),_}var or=1,X="[object Arguments]",J="[object Array]",c="[object Object]",wr=Object.prototype,Q=wr.hasOwnProperty;function Or(n,r,e,i,f,t){var s=A(n),u=A(r),a=s?J:N(n),h=u?J:N(r);a=a==X?c:a,h=h==X?c:h;var g=a==c,l=h==c,d=a==h;if(d&&U(n)){if(!U(r))return!1;s=!0,g=!1}if(d&&!g)return t||(t=new T),s||_n(n)?fn(n,r,e,i,f,t):dr(n,r,a,e,i,f,t);if(!(e&or)){var o=g&&Q.call(n,"__wrapped__"),p=l&&Q.call(r,"__wrapped__");if(o||p){var _=o?n.value():n,w=p?r.value():r;return t||(t=new T),f(_,w,e,i,t)}}return d?(t||(t=new T),_r(n,r,e,i,f,t)):!1}function F(n,r,e,i,f){return n===r?!0:n==null||r==null||!L(n)&&!L(r)?n!==n&&r!==r:Or(n,r,e,i,F,f)}var vr=1,Pr=2;function yr(n,r,e,i){var f=e.length,t=f;if(n==null)return!t;for(n=Object(n);f--;){var s=e[f];if(s[2]?s[1]!==n[s[0]]:!(s[0]in n))return!1}for(;++f<t;){s=e[f];var u=s[0],a=n[u],h=s[1];if(s[2]){if(a===void 0&&!(u in n))return!1}else{var g=new T,l;if(!(l===void 0?F(h,a,vr|Pr,i,g):l))return!1}}return!0}function sn(n){return n===n&&!on(n)}function Er(n){for(var r=M(n),e=r.length;e--;){var i=r[e],f=n[i];r[e]=[i,f,sn(f)]}return r}function un(n,r){return function(e){return e==null?!1:e[n]===r&&(r!==void 0||n in Object(e))}}function br(n){var r=Er(n);return r.length==1&&r[0][2]?un(r[0][0],r[0][1]):function(e){return e===n||yr(e,n,r)}}function cr(n,r){return n!=null&&r in Object(n)}function Tr(n,r,e){r=j(r,n);for(var i=-1,f=r.length,t=!1;++i<f;){var s=R(r[i]);if(!(t=n!=null&&e(n,s)))break;n=n[s]}return t||++i!=f?t:(f=n==null?0:n.length,!!f&&wn(f)&&On(s,f)&&(A(n)||z(n)))}function Rr(n,r){return n!=null&&Tr(n,r,cr)}var Ir=1,Sr=2;function Lr(n,r){return $(n)&&sn(r)?un(R(n),r):function(e){var i=mn(e,n);return i===void 0&&i===r?Rr(e,n):F(r,i,Ir|Sr)}}function xr(n){return function(r){return r?.[n]}}function Mr(n){return function(r){return nn(r,n)}}function $r(n){return $(n)?xr(R(n)):Mr(n)}function an(n){return typeof n=="function"?n:n==null?V:typeof n=="object"?A(n)?Lr(n[0],n[1]):br(n):$r(n)}function Cr(n,r){return n&&vn(n,r,M)}function Fr(n,r){return function(e,i){if(e==null)return e;if(!W(e))return n(e,i);for(var f=e.length,t=-1,s=Object(e);++t<f&&i(s[t],t,s)!==!1;);return e}}var G=Fr(Cr);function Gr(n){return typeof n=="function"?n:V}function qr(n,r){var e=A(n)?bn:G;return e(n,Gr(r))}function Dr(n,r){var e=[];return G(n,function(i,f,t){r(i,f,t)&&e.push(i)}),e}function Zr(n,r){var e=A(n)?en:Dr;return e(n,an(r))}function mr(n,r,e,i,f){return f(n,function(t,s,u){e=i?(i=!1,t):r(e,t,s,u)}),e}function Yr(n,r,e){var i=A(n)?Un:mr,f=arguments.length<3;return i(n,an(r),e,f,G)}var Nr=1/0,Ur=I&&1/C(new I([,-0]))[1]==Nr?function(n){return new I(n)}:En,Br=200;function Xr(n,r,e){var i=-1,f=Sn,t=n.length,s=!0,u=[],a=u;if(t>=Br){var h=r?null:Ur(n);if(h)return C(h);s=!1,f=tn,a=new y}else a=r?[]:u;n:for(;++i<t;){var g=n[i],l=r?r(g):g;if(g=g!==0?g:0,s&&l===l){for(var d=a.length;d--;)if(a[d]===l)continue n;r&&a.push(l),u.push(g)}else f(a,l,e)||(a!==u&&a.push(l),u.push(g))}return u}export{G as a,Hr as b,an as c,yn as d,rn as e,Zn as f,qn as g,bn as h,x as i,Z as j,M as k,Xr as l,Zr as m,qr as n,cn as o,Gr as p,Cr as q,Yr as r,Bn as s,Tr as t,j as u,R as v,nn as w,Rr as x,Dn as y};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{M as ln,N as an,O as Y,P as O,Q,R as un,S as y,T as tn,V as j,W as _,X as rn,Y as o,Z as on,$ as sn,a0 as fn}from"./mermaid.core-
|
|
1
|
+
import{M as ln,N as an,O as Y,P as O,Q,R as un,S as y,T as tn,V as j,W as _,X as rn,Y as o,Z as on,$ as sn,a0 as fn}from"./mermaid.core-D1FKNjuC.js";function cn(l){return l.innerRadius}function yn(l){return l.outerRadius}function gn(l){return l.startAngle}function dn(l){return l.endAngle}function mn(l){return l&&l.padAngle}function pn(l,h,D,S,v,R,V,a){var E=D-l,i=S-h,n=V-v,d=a-R,u=d*E-n*i;if(!(u*u<y))return u=(n*(h-R)-d*(l-v))/u,[l+u*E,h+u*i]}function H(l,h,D,S,v,R,V){var a=l-D,E=h-S,i=(V?R:-R)/j(a*a+E*E),n=i*E,d=-i*a,u=l+n,s=h+d,f=D+n,c=S+d,W=(u+f)/2,t=(s+c)/2,m=f-u,g=c-s,A=m*m+g*g,T=v-R,P=u*c-f*s,I=(g<0?-1:1)*j(on(0,T*T*A-P*P)),M=(P*g-m*I)/A,N=(-P*m-g*I)/A,w=(P*g+m*I)/A,p=(-P*m+g*I)/A,x=M-W,e=N-t,r=w-W,X=p-t;return x*x+e*e>r*r+X*X&&(M=w,N=p),{cx:M,cy:N,x01:-n,y01:-d,x11:M*(v/T-1),y11:N*(v/T-1)}}function hn(){var l=cn,h=yn,D=Q(0),S=null,v=gn,R=dn,V=mn,a=null,E=ln(i);function i(){var n,d,u=+l.apply(this,arguments),s=+h.apply(this,arguments),f=v.apply(this,arguments)-un,c=R.apply(this,arguments)-un,W=rn(c-f),t=c>f;if(a||(a=n=E()),s<u&&(d=s,s=u,u=d),!(s>y))a.moveTo(0,0);else if(W>tn-y)a.moveTo(s*Y(f),s*O(f)),a.arc(0,0,s,f,c,!t),u>y&&(a.moveTo(u*Y(c),u*O(c)),a.arc(0,0,u,c,f,t));else{var m=f,g=c,A=f,T=c,P=W,I=W,M=V.apply(this,arguments)/2,N=M>y&&(S?+S.apply(this,arguments):j(u*u+s*s)),w=_(rn(s-u)/2,+D.apply(this,arguments)),p=w,x=w,e,r;if(N>y){var X=sn(N/u*O(M)),z=sn(N/s*O(M));(P-=X*2)>y?(X*=t?1:-1,A+=X,T-=X):(P=0,A=T=(f+c)/2),(I-=z*2)>y?(z*=t?1:-1,m+=z,g-=z):(I=0,m=g=(f+c)/2)}var Z=s*Y(m),$=s*O(m),B=u*Y(T),C=u*O(T);if(w>y){var F=s*Y(g),G=s*O(g),J=u*Y(A),K=u*O(A),q;if(W<an)if(q=pn(Z,$,J,K,F,G,B,C)){var L=Z-q[0],U=$-q[1],k=F-q[0],b=G-q[1],nn=1/O(fn((L*k+U*b)/(j(L*L+U*U)*j(k*k+b*b)))/2),en=j(q[0]*q[0]+q[1]*q[1]);p=_(w,(u-en)/(nn-1)),x=_(w,(s-en)/(nn+1))}else p=x=0}I>y?x>y?(e=H(J,K,Z,$,s,x,t),r=H(F,G,B,C,s,x,t),a.moveTo(e.cx+e.x01,e.cy+e.y01),x<w?a.arc(e.cx,e.cy,x,o(e.y01,e.x01),o(r.y01,r.x01),!t):(a.arc(e.cx,e.cy,x,o(e.y01,e.x01),o(e.y11,e.x11),!t),a.arc(0,0,s,o(e.cy+e.y11,e.cx+e.x11),o(r.cy+r.y11,r.cx+r.x11),!t),a.arc(r.cx,r.cy,x,o(r.y11,r.x11),o(r.y01,r.x01),!t))):(a.moveTo(Z,$),a.arc(0,0,s,m,g,!t)):a.moveTo(Z,$),!(u>y)||!(P>y)?a.lineTo(B,C):p>y?(e=H(B,C,F,G,u,-p,t),r=H(Z,$,J,K,u,-p,t),a.lineTo(e.cx+e.x01,e.cy+e.y01),p<w?a.arc(e.cx,e.cy,p,o(e.y01,e.x01),o(r.y01,r.x01),!t):(a.arc(e.cx,e.cy,p,o(e.y01,e.x01),o(e.y11,e.x11),!t),a.arc(0,0,u,o(e.cy+e.y11,e.cx+e.x11),o(r.cy+r.y11,r.cx+r.x11),t),a.arc(r.cx,r.cy,p,o(r.y11,r.x11),o(r.y01,r.x01),!t))):a.arc(0,0,u,T,A,t)}if(a.closePath(),n)return a=null,n+""||null}return i.centroid=function(){var n=(+l.apply(this,arguments)+ +h.apply(this,arguments))/2,d=(+v.apply(this,arguments)+ +R.apply(this,arguments))/2-an/2;return[Y(d)*n,O(d)*n]},i.innerRadius=function(n){return arguments.length?(l=typeof n=="function"?n:Q(+n),i):l},i.outerRadius=function(n){return arguments.length?(h=typeof n=="function"?n:Q(+n),i):h},i.cornerRadius=function(n){return arguments.length?(D=typeof n=="function"?n:Q(+n),i):D},i.padRadius=function(n){return arguments.length?(S=n==null?null:typeof n=="function"?n:Q(+n),i):S},i.startAngle=function(n){return arguments.length?(v=typeof n=="function"?n:Q(+n),i):v},i.endAngle=function(n){return arguments.length?(R=typeof n=="function"?n:Q(+n),i):R},i.padAngle=function(n){return arguments.length?(V=typeof n=="function"?n:Q(+n),i):V},i.context=function(n){return arguments.length?(a=n??null,i):a},i}export{hn as d};
|